From 7f045bcf6dc41981d81fe517e1c8df597f025bf7 Mon Sep 17 00:00:00 2001 From: thepaperpilot Date: Mon, 27 Jun 2022 04:44:44 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20profectu?= =?UTF-8?q?s-engine/TMT-Demo@6c9cd0f362e370704500ab05c5c29737781514dc=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Logo.png | Bin 19395 -> 0 bytes assets/index.2bb81304.js | 1620 +++++++++++++++++ assets/index.f4e7ecfe.css | 1 + css/app.ef7fba40.css | 1 - css/chunk-vendors.ae0fafc3.css | 1 - favicon-16x16.png | Bin 442 -> 0 bytes favicon-32x32.png | Bin 873 -> 0 bytes favicon.svg | 24 + index.html | 33 +- js/app-legacy.e1809a3d.js | 2 - js/app-legacy.e1809a3d.js.map | 1 - js/app.33420421.js | 2 - js/app.33420421.js.map | 1 - js/chunk-vendors-legacy.e714a3a2.js | 245 --- js/chunk-vendors-legacy.e714a3a2.js.map | 1 - js/chunk-vendors.354a9a53.js | 245 --- js/chunk-vendors.354a9a53.js.map | 1 - manifest.webmanifest | 1 + android-chrome-192x192.png => pwa-192x192.png | Bin android-chrome-512x512.png => pwa-512x512.png | Bin robots.txt | 2 + site.webmanifest | 1 - sw.js | 1 + workbox-b3e22772.js | 1 + 24 files changed, 1682 insertions(+), 502 deletions(-) delete mode 100644 Logo.png create mode 100644 assets/index.2bb81304.js create mode 100644 assets/index.f4e7ecfe.css delete mode 100644 css/app.ef7fba40.css delete mode 100644 css/chunk-vendors.ae0fafc3.css delete mode 100644 favicon-16x16.png delete mode 100644 favicon-32x32.png create mode 100644 favicon.svg delete mode 100644 js/app-legacy.e1809a3d.js delete mode 100644 js/app-legacy.e1809a3d.js.map delete mode 100644 js/app.33420421.js delete mode 100644 js/app.33420421.js.map delete mode 100644 js/chunk-vendors-legacy.e714a3a2.js delete mode 100644 js/chunk-vendors-legacy.e714a3a2.js.map delete mode 100644 js/chunk-vendors.354a9a53.js delete mode 100644 js/chunk-vendors.354a9a53.js.map create mode 100644 manifest.webmanifest rename android-chrome-192x192.png => pwa-192x192.png (100%) rename android-chrome-512x512.png => pwa-512x512.png (100%) create mode 100644 robots.txt delete mode 100644 site.webmanifest create mode 100644 sw.js create mode 100644 workbox-b3e22772.js diff --git a/Logo.png b/Logo.png deleted file mode 100644 index 53973a75569fb0a946da2fbe3c7063beb265e198..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 19395 zcmb5VcRZDE{6Bu(=Nx;6LX=~#P$;3CqhyEdGAl{Q77^zbiiRzPA|u%&E9;zw?3uj_ zk)1uy`QF~&-{<@IegFLScog09y6@|{U)OV8;RbpdO!UX;0RT)|nremsppajoJz8qy zM^(LOE%JlTP4l`Z01WJhe<6^V%yoE(r=i9rP|(i%7x@q7uIg1)0E#0S_HR-FpkuD3 zrfTd9Esk2aS@ypf*emkNawdstD6pg{dc<3aDy18pE$_$_ zFnjydSMQEQZ2tu{QxDF%G4%{$ zL9lzAhjl8>g0i}e{AHuV=lg&8qo&wwsNdSk zn9DQA?`?6hcsNUC=KNR#0OmhT97p%=)^?ci`KHh9?sOOl=sR(FiHc2+Ogh1!z-Q8X5hZNVb{fJW` zCq!%Uj~e)P)+j9re5Nkr1mgm~OUOaNHH}-5TZ@uD-mNCOm z1@JPSJx>Gndd9Ch>7*L5g9e^`KEvt&*N1!rJqUm%hV9OOA`tQ6a{jpgFjO#?s;3K* z8$P5w9JsbOZp=sqz<5mra=AD2oOrOP+;2j&As#IB<=1qA&4XR8eF%h!4*x#bv)TBe zdp*v_*=cM5gST$GY+IPcb+tu@vM(x({*zo;3a62umE3(VH zx$$$F1;CqAl!@Z3$NzdXIq*Kr_>`fFWq0J9q2K4VMZjJh|Bwjq*`&lDHw7S7DqwFn z<5h$%Scm{MtId++WANnq2{UBR#e%Aay^0PCTS@lPtKh?j54#du35PqR^il*T@7df5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J-!m$_Y1YY(DhABGymGzhN=qqSV?`=V2kr@K0xqF*ZhbO~I)dIG(A<%;jo%uM%< zE;gd8>->#<^^Jeu2>_rm=TIsuQ27~Ba?jY}BRyaUXHYZcH39nczG$gCHyzxunKspb_iLj3Cv4(hrxLn$- z!;)_g6{gB=;VCr zZir9fBb;U(XQpP?Zs|8OnEyX2z;wGgfAWcvi{o^@eKmx5 zTeq@|9wPcl1q^FD6mm%qiK}7?W_|0>El0<<^WqiVquHG%?2=Si7{Cx+E*>ZZa~Wtl zvRwvGge%#lmeT54+B+;rGICSy|HGuzi>qhph1a0gDO(1JG8DljwhlN8>0ASr;Wz85 z5Hztfk;py3e`L&jQ|_B*5HM`^v)YpEnaw7S!VUooNavVtWDbR1K|e^)fw43#a~CD^ zcMk2pi=!&cNt+*kuQ7GyA^QiK8Q;#ujOV;EZ!2JnWby{lpYApE+Pu)yucoqtIJDE- z)q`ko{;D)&eqXq=HE+%mZrgFX!5nozg&ESHQ8~&v@FMkFRdx>v)U=dy!E${9SI&y% y2cV^SZxOIfo@mW*IDC}-3L^fp`+wHaDS*&29JDvf1r~mci{G2LN3i?YkN*Q6s&Byn diff --git a/assets/index.2bb81304.js b/assets/index.2bb81304.js new file mode 100644 index 0000000..d3471d1 --- /dev/null +++ b/assets/index.2bb81304.js @@ -0,0 +1,1620 @@ +const gx=function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function r(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerpolicy&&(o.referrerPolicy=i.referrerpolicy),i.crossorigin==="use-credentials"?o.credentials="include":i.crossorigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(i){if(i.ep)return;i.ep=!0;const o=r(i);fetch(i.href,o)}};gx();const yx="modulepreload",Xp={},bx="/",xu=function(e,r){return!r||r.length===0?e():Promise.all(r.map(n=>{if(n=`${bx}${n}`,n in Xp)return;Xp[n]=!0;const i=n.endsWith(".css"),o=i?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${n}"]${o}`))return;const a=document.createElement("link");if(a.rel=i?"stylesheet":yx,i||(a.as="script",a.crossOrigin=""),a.href=n,document.head.appendChild(a),i)return new Promise((s,l)=>{a.addEventListener("load",s),a.addEventListener("error",()=>l(new Error(`Unable to preload CSS for ${n}`)))})})).then(()=>e())};function Zu(t,e){const r=Object.create(null),n=t.split(",");for(let i=0;i!!r[i.toLowerCase()]:i=>!!r[i]}const _x="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt",xx=Zu(_x),Tx="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",wx=Zu(Tx);function py(t){return!!t||t===""}function ce(t){if(Ct(t)){const e={};for(let r=0;r{if(r){const n=r.split(Ix);n.length>1&&(e[n[0].trim()]=n[1].trim())}}),e}function Qt(t){let e="";if(Ke(t))e=t;else if(Ct(t))for(let r=0;rHi(r,e))}const re=t=>Ke(t)?t:t==null?"":Ct(t)||rr(t)&&(t.toString===gy||!zt(t.toString))?JSON.stringify(t,my,2):String(t),my=(t,e)=>e&&e.__v_isRef?my(t,e.value):ha(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((r,[n,i])=>(r[`${n} =>`]=i,r),{})}:Fo(e)?{[`Set(${e.size})`]:[...e.values()]}:rr(e)&&!Ct(e)&&!yy(e)?String(e):e,Ee={},fa=[],xn=()=>{},Nx=()=>!1,Px=/^on[^a-z]/,qs=t=>Px.test(t),Td=t=>t.startsWith("onUpdate:"),er=Object.assign,wd=(t,e)=>{const r=t.indexOf(e);r>-1&&t.splice(r,1)},Sx=Object.prototype.hasOwnProperty,me=(t,e)=>Sx.call(t,e),Ct=Array.isArray,ha=t=>Js(t)==="[object Map]",Fo=t=>Js(t)==="[object Set]",zp=t=>Js(t)==="[object Date]",zt=t=>typeof t=="function",Ke=t=>typeof t=="string",Es=t=>typeof t=="symbol",rr=t=>t!==null&&typeof t=="object",Ed=t=>rr(t)&&zt(t.then)&&zt(t.catch),gy=Object.prototype.toString,Js=t=>gy.call(t),Ax=t=>Js(t).slice(8,-1),yy=t=>Js(t)==="[object Object]",Id=t=>Ke(t)&&t!=="NaN"&&t[0]!=="-"&&""+parseInt(t,10)===t,as=Zu(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Ju=t=>{const e=Object.create(null);return r=>e[r]||(e[r]=t(r))},Ox=/-(\w)/g,Kr=Ju(t=>t.replace(Ox,(e,r)=>r?r.toUpperCase():"")),Ux=/\B([A-Z])/g,Mn=Ju(t=>t.replace(Ux,"-$1").toLowerCase()),Qs=Ju(t=>t.charAt(0).toUpperCase()+t.slice(1)),ss=Ju(t=>t?`on${Qs(t)}`:""),ba=(t,e)=>!Object.is(t,e),da=(t,e)=>{for(let r=0;r{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:r})},Vi=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let Wp;const Fx=()=>Wp||(Wp=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:{});let Vr;class Cd{constructor(e=!1){this.active=!0,this.effects=[],this.cleanups=[],!e&&Vr&&(this.parent=Vr,this.index=(Vr.scopes||(Vr.scopes=[])).push(this)-1)}run(e){if(this.active){const r=Vr;try{return Vr=this,e()}finally{Vr=r}}}on(){Vr=this}off(){Vr=this.parent}stop(e){if(this.active){let r,n;for(r=0,n=this.effects.length;r{const e=new Set(t);return e.w=0,e.n=0,e},_y=t=>(t.w&$i)>0,xy=t=>(t.n&$i)>0,kx=({deps:t})=>{if(t.length)for(let e=0;e{const{deps:e}=t;if(e.length){let r=0;for(let n=0;n{(u==="length"||u>=n)&&s.push(l)});else switch(r!==void 0&&s.push(a.get(r)),e){case"add":Ct(t)?Id(r)&&s.push(a.get("length")):(s.push(a.get(Eo)),ha(t)&&s.push(a.get(jf)));break;case"delete":Ct(t)||(s.push(a.get(Eo)),ha(t)&&s.push(a.get(jf)));break;case"set":ha(t)&&s.push(a.get(Eo));break}if(s.length===1)s[0]&&Xf(s[0]);else{const l=[];for(const u of s)u&&l.push(...u);Xf(Rd(l))}}function Xf(t,e){const r=Ct(t)?t:[...t];for(const n of r)n.computed&&Kp(n);for(const n of r)n.computed||Kp(n)}function Kp(t,e){(t!==yn||t.allowRecurse)&&(t.scheduler?t.scheduler():t.run())}const Vx=Zu("__proto__,__v_isRef,__isVue"),Ey=new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(Es)),$x=Qu(),jx=Qu(!1,!0),Xx=Qu(!0),zx=Qu(!0,!0),Zp=Wx();function Wx(){const t={};return["includes","indexOf","lastIndexOf"].forEach(e=>{t[e]=function(...r){const n=ue(this);for(let o=0,a=this.length;o{t[e]=function(...r){Lo();const n=ue(this)[e].apply(this,r);return Mo(),n}}),t}function Qu(t=!1,e=!1){return function(n,i,o){if(i==="__v_isReactive")return!t;if(i==="__v_isReadonly")return t;if(i==="__v_isShallow")return e;if(i==="__v_raw"&&o===(t?e?Ay:Sy:e?Py:Ny).get(n))return n;const a=Ct(n);if(!t&&a&&me(Zp,i))return Reflect.get(Zp,i,o);const s=Reflect.get(n,i,o);return(Es(i)?Ey.has(i):Vx(i))||(t||Zr(n,"get",i),e)?s:oe(s)?a&&Id(i)?s:s.value:rr(s)?t?Pd(s):zn(s):s}}const Yx=Iy(),Kx=Iy(!0);function Iy(t=!1){return function(r,n,i,o){let a=r[n];if(_a(a)&&oe(a)&&!oe(i))return!1;if(!t&&!_a(i)&&(wu(i)||(i=ue(i),a=ue(a)),!Ct(r)&&oe(a)&&!oe(i)))return a.value=i,!0;const s=Ct(r)&&Id(n)?Number(n)t,tc=t=>Reflect.getPrototypeOf(t);function vl(t,e,r=!1,n=!1){t=t.__v_raw;const i=ue(t),o=ue(e);r||(e!==o&&Zr(i,"get",e),Zr(i,"get",o));const{has:a}=tc(i),s=n?Nd:r?Od:Is;if(a.call(i,e))return s(t.get(e));if(a.call(i,o))return s(t.get(o));t!==i&&t.get(e)}function ml(t,e=!1){const r=this.__v_raw,n=ue(r),i=ue(t);return e||(t!==i&&Zr(n,"has",t),Zr(n,"has",i)),t===i?r.has(t):r.has(t)||r.has(i)}function gl(t,e=!1){return t=t.__v_raw,!e&&Zr(ue(t),"iterate",Eo),Reflect.get(t,"size",t)}function qp(t){t=ue(t);const e=ue(this);return tc(e).has.call(e,t)||(e.add(t),fi(e,"add",t,t)),this}function Jp(t,e){e=ue(e);const r=ue(this),{has:n,get:i}=tc(r);let o=n.call(r,t);o||(t=ue(t),o=n.call(r,t));const a=i.call(r,t);return r.set(t,e),o?ba(e,a)&&fi(r,"set",t,e):fi(r,"add",t,e),this}function Qp(t){const e=ue(this),{has:r,get:n}=tc(e);let i=r.call(e,t);i||(t=ue(t),i=r.call(e,t)),n&&n.call(e,t);const o=e.delete(t);return i&&fi(e,"delete",t,void 0),o}function tv(){const t=ue(this),e=t.size!==0,r=t.clear();return e&&fi(t,"clear",void 0,void 0),r}function yl(t,e){return function(n,i){const o=this,a=o.__v_raw,s=ue(a),l=e?Nd:t?Od:Is;return!t&&Zr(s,"iterate",Eo),a.forEach((u,c)=>n.call(i,l(u),l(c),o))}}function bl(t,e,r){return function(...n){const i=this.__v_raw,o=ue(i),a=ha(o),s=t==="entries"||t===Symbol.iterator&&a,l=t==="keys"&&a,u=i[t](...n),c=r?Nd:e?Od:Is;return!e&&Zr(o,"iterate",l?jf:Eo),{next(){const{value:f,done:h}=u.next();return h?{value:f,done:h}:{value:s?[c(f[0]),c(f[1])]:c(f),done:h}},[Symbol.iterator](){return this}}}}function xi(t){return function(...e){return t==="delete"?!1:this}}function eT(){const t={get(o){return vl(this,o)},get size(){return gl(this)},has:ml,add:qp,set:Jp,delete:Qp,clear:tv,forEach:yl(!1,!1)},e={get(o){return vl(this,o,!1,!0)},get size(){return gl(this)},has:ml,add:qp,set:Jp,delete:Qp,clear:tv,forEach:yl(!1,!0)},r={get(o){return vl(this,o,!0)},get size(){return gl(this,!0)},has(o){return ml.call(this,o,!0)},add:xi("add"),set:xi("set"),delete:xi("delete"),clear:xi("clear"),forEach:yl(!0,!1)},n={get(o){return vl(this,o,!0,!0)},get size(){return gl(this,!0)},has(o){return ml.call(this,o,!0)},add:xi("add"),set:xi("set"),delete:xi("delete"),clear:xi("clear"),forEach:yl(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(o=>{t[o]=bl(o,!1,!1),r[o]=bl(o,!0,!1),e[o]=bl(o,!1,!0),n[o]=bl(o,!0,!0)}),[t,r,e,n]}const[rT,nT,iT,oT]=eT();function ec(t,e){const r=e?t?oT:iT:t?nT:rT;return(n,i,o)=>i==="__v_isReactive"?!t:i==="__v_isReadonly"?t:i==="__v_raw"?n:Reflect.get(me(r,i)&&i in n?r:n,i,o)}const aT={get:ec(!1,!1)},sT={get:ec(!1,!0)},lT={get:ec(!0,!1)},uT={get:ec(!0,!0)},Ny=new WeakMap,Py=new WeakMap,Sy=new WeakMap,Ay=new WeakMap;function cT(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function fT(t){return t.__v_skip||!Object.isExtensible(t)?0:cT(Ax(t))}function zn(t){return _a(t)?t:rc(t,!1,Cy,aT,Ny)}function Sa(t){return rc(t,!1,Qx,sT,Py)}function Pd(t){return rc(t,!0,Ry,lT,Sy)}function hT(t){return rc(t,!0,tT,uT,Ay)}function rc(t,e,r,n,i){if(!rr(t)||t.__v_raw&&!(e&&t.__v_isReactive))return t;const o=i.get(t);if(o)return o;const a=fT(t);if(a===0)return t;const s=new Proxy(t,a===2?n:r);return i.set(t,s),s}function ki(t){return _a(t)?ki(t.__v_raw):!!(t&&t.__v_isReactive)}function _a(t){return!!(t&&t.__v_isReadonly)}function wu(t){return!!(t&&t.__v_isShallow)}function Sd(t){return ki(t)||_a(t)}function ue(t){const e=t&&t.__v_raw;return e?ue(e):t}function Ad(t){return Tu(t,"__v_skip",!0),t}const Is=t=>rr(t)?zn(t):t,Od=t=>rr(t)?Pd(t):t;function Ud(t){Bi&&yn&&(t=ue(t),wy(t.dep||(t.dep=Rd())))}function nc(t,e){t=ue(t),t.dep&&Xf(t.dep)}function oe(t){return!!(t&&t.__v_isRef===!0)}function It(t){return Oy(t,!1)}function Gr(t){return Oy(t,!0)}function Oy(t,e){return oe(t)?t:new dT(t,e)}class dT{constructor(e,r){this.__v_isShallow=r,this.dep=void 0,this.__v_isRef=!0,this._rawValue=r?e:ue(e),this._value=r?e:Is(e)}get value(){return Ud(this),this._value}set value(e){e=this.__v_isShallow?e:ue(e),ba(e,this._rawValue)&&(this._rawValue=e,this._value=this.__v_isShallow?e:Is(e),nc(this))}}function pT(t){nc(t)}function E(t){return oe(t)?t.value:t}const vT={get:(t,e,r)=>E(Reflect.get(t,e,r)),set:(t,e,r,n)=>{const i=t[e];return oe(i)&&!oe(r)?(i.value=r,!0):Reflect.set(t,e,r,n)}};function Fd(t){return ki(t)?t:new Proxy(t,vT)}class mT{constructor(e){this.dep=void 0,this.__v_isRef=!0;const{get:r,set:n}=e(()=>Ud(this),()=>nc(this));this._get=r,this._set=n}get value(){return this._get()}set value(e){this._set(e)}}function gT(t){return new mT(t)}function Ae(t){const e=Ct(t)?new Array(t.length):{};for(const r in t)e[r]=Mr(t,r);return e}class yT{constructor(e,r,n){this._object=e,this._key=r,this._defaultValue=n,this.__v_isRef=!0}get value(){const e=this._object[this._key];return e===void 0?this._defaultValue:e}set value(e){this._object[this._key]=e}}function Mr(t,e,r){const n=t[e];return oe(n)?n:new yT(t,e,r)}class bT{constructor(e,r,n,i){this._setter=r,this.dep=void 0,this.__v_isRef=!0,this._dirty=!0,this.effect=new tl(e,()=>{this._dirty||(this._dirty=!0,nc(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!i,this.__v_isReadonly=n}get value(){const e=ue(this);return Ud(e),(e._dirty||!e._cacheable)&&(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function _T(t,e,r=!1){let n,i;const o=zt(t);return o?(n=t,i=xn):(n=t.get,i=t.set),new bT(n,i,o||!i,r)}const ls=[];function Uy(t,...e){Lo();const r=ls.length?ls[ls.length-1].component:null,n=r&&r.appContext.config.warnHandler,i=xT();if(n)Bn(n,r,11,[t+e.join(""),r&&r.proxy,i.map(({vnode:o})=>`at <${Ib(r,o.type)}>`).join(` +`),i]);else{const o=[`[Vue warn]: ${t}`,...e];i.length&&o.push(` +`,...TT(i)),console.warn(...o)}Mo()}function xT(){let t=ls[ls.length-1];if(!t)return[];const e=[];for(;t;){const r=e[0];r&&r.vnode===t?r.recurseCount++:e.push({vnode:t,recurseCount:0});const n=t.component&&t.component.parent;t=n&&n.vnode}return e}function TT(t){const e=[];return t.forEach((r,n)=>{e.push(...n===0?[]:[` +`],...wT(r))}),e}function wT({vnode:t,recurseCount:e}){const r=e>0?`... (${e} recursive calls)`:"",n=t.component?t.component.parent==null:!1,i=` at <${Ib(t.component,t.type,n)}`,o=">"+r;return t.props?[i,...ET(t.props),o]:[i+o]}function ET(t){const e=[],r=Object.keys(t);return r.slice(0,3).forEach(n=>{e.push(...Fy(n,t[n]))}),r.length>3&&e.push(" ..."),e}function Fy(t,e,r){return Ke(e)?(e=JSON.stringify(e),r?e:[`${t}=${e}`]):typeof e=="number"||typeof e=="boolean"||e==null?r?e:[`${t}=${e}`]:oe(e)?(e=Fy(t,ue(e.value),!0),r?e:[`${t}=Ref<`,e,">"]):zt(e)?[`${t}=fn${e.name?`<${e.name}>`:""}`]:(e=ue(e),r?e:[`${t}=`,e])}function Bn(t,e,r,n){let i;try{i=n?t(...n):t()}catch(o){Bo(o,e,r)}return i}function Yr(t,e,r,n){if(zt(t)){const o=Bn(t,e,r,n);return o&&Ed(o)&&o.catch(a=>{Bo(a,e,r)}),o}const i=[];for(let o=0;o>>1;Cs(jr[n])ei&&jr.splice(e,1)}function By(t,e,r,n){Ct(t)?r.push(...t):(!e||!e.includes(t,t.allowRecurse?n+1:n))&&r.push(t),My()}function NT(t){By(t,Qa,us,Zo)}function Bd(t){By(t,Ci,cs,qo)}function ic(t,e=null){if(us.length){for(Wf=e,Qa=[...new Set(us)],us.length=0,Zo=0;ZoCs(r)-Cs(n)),qo=0;qot.id==null?1/0:t.id;function ky(t){zf=!1,Eu=!0,ic(t),jr.sort((r,n)=>Cs(r)-Cs(n));const e=xn;try{for(ei=0;eiJo.emit(i,...o)),_l=[]):typeof window!="undefined"&&window.HTMLElement&&!(!((n=(r=window.navigator)===null||r===void 0?void 0:r.userAgent)===null||n===void 0)&&n.includes("jsdom"))?((e.__VUE_DEVTOOLS_HOOK_REPLAY__=e.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{Gy(o,e)}),setTimeout(()=>{Jo||(e.__VUE_DEVTOOLS_HOOK_REPLAY__=null,_l=[])},3e3)):_l=[]}function PT(t,e,...r){if(t.isUnmounted)return;const n=t.vnode.props||Ee;let i=r;const o=e.startsWith("update:"),a=o&&e.slice(7);if(a&&a in n){const c=`${a==="modelValue"?"model":a}Modifiers`,{number:f,trim:h}=n[c]||Ee;h&&(i=r.map(d=>d.trim())),f&&(i=r.map(Vi))}let s,l=n[s=ss(e)]||n[s=ss(Kr(e))];!l&&o&&(l=n[s=ss(Mn(e))]),l&&Yr(l,t,6,i);const u=n[s+"Once"];if(u){if(!t.emitted)t.emitted={};else if(t.emitted[s])return;t.emitted[s]=!0,Yr(u,t,6,i)}}function Dy(t,e,r=!1){const n=e.emitsCache,i=n.get(t);if(i!==void 0)return i;const o=t.emits;let a={},s=!1;if(!zt(t)){const l=u=>{const c=Dy(u,e,!0);c&&(s=!0,er(a,c))};!r&&e.mixins.length&&e.mixins.forEach(l),t.extends&&l(t.extends),t.mixins&&t.mixins.forEach(l)}return!o&&!s?(n.set(t,null),null):(Ct(o)?o.forEach(l=>a[l]=null):er(a,o),n.set(t,a),a)}function oc(t,e){return!t||!qs(e)?!1:(e=e.slice(2).replace(/Once$/,""),me(t,e[0].toLowerCase()+e.slice(1))||me(t,Mn(e))||me(t,e))}let Ir=null,ac=null;function Rs(t){const e=Ir;return Ir=t,ac=t&&t.type.__scopeId||null,e}function Cn(t){ac=t}function Rn(){ac=null}const ST=t=>Bt;function Bt(t,e=Ir,r){if(!e||t._n)return t;const n=(...i)=>{n._d&&th(-1);const o=Rs(e),a=t(...i);return Rs(o),n._d&&th(1),a};return n._n=!0,n._c=!0,n._d=!0,n}function lu(t){const{type:e,vnode:r,proxy:n,withProxy:i,props:o,propsOptions:[a],slots:s,attrs:l,emit:u,render:c,renderCache:f,data:h,setupState:d,ctx:p,inheritAttrs:v}=t;let m,y;const g=Rs(t);try{if(r.shapeFlag&4){const T=i||n;m=$r(c.call(T,T,f,o,d,h,p)),y=l}else{const T=e;m=$r(T.length>1?T(o,{attrs:l,slots:s,emit:u}):T(o,null)),y=e.props?l:OT(l)}}catch(T){hs.length=0,Bo(T,t,1),m=P(Rr)}let b=m;if(y&&v!==!1){const T=Object.keys(y),{shapeFlag:w}=b;T.length&&w&7&&(a&&T.some(Td)&&(y=UT(y,a)),b=Vn(b,y))}return r.dirs&&(b=Vn(b),b.dirs=b.dirs?b.dirs.concat(r.dirs):r.dirs),r.transition&&(b.transition=r.transition),m=b,Rs(g),m}function AT(t){let e;for(let r=0;r{let e;for(const r in t)(r==="class"||r==="style"||qs(r))&&((e||(e={}))[r]=t[r]);return e},UT=(t,e)=>{const r={};for(const n in t)(!Td(n)||!(n.slice(9)in e))&&(r[n]=t[n]);return r};function FT(t,e,r){const{props:n,children:i,component:o}=t,{props:a,children:s,patchFlag:l}=e,u=o.emitsOptions;if(e.dirs||e.transition)return!0;if(r&&l>=0){if(l&1024)return!0;if(l&16)return n?ev(n,a,u):!!a;if(l&8){const c=e.dynamicProps;for(let f=0;ft.__isSuspense,LT={name:"Suspense",__isSuspense:!0,process(t,e,r,n,i,o,a,s,l,u){t==null?BT(e,r,n,i,o,a,s,l,u):kT(t,e,r,n,i,a,s,l,u)},hydrate:GT,create:Gd,normalize:DT},MT=LT;function Ns(t,e){const r=t.props&&t.props[e];zt(r)&&r()}function BT(t,e,r,n,i,o,a,s,l){const{p:u,o:{createElement:c}}=l,f=c("div"),h=t.suspense=Gd(t,i,n,e,f,r,o,a,s,l);u(null,h.pendingBranch=t.ssContent,f,null,n,h,o,a),h.deps>0?(Ns(t,"onPending"),Ns(t,"onFallback"),u(null,t.ssFallback,e,r,n,null,o,a),pa(h,t.ssFallback)):h.resolve()}function kT(t,e,r,n,i,o,a,s,{p:l,um:u,o:{createElement:c}}){const f=e.suspense=t.suspense;f.vnode=e,e.el=t.el;const h=e.ssContent,d=e.ssFallback,{activeBranch:p,pendingBranch:v,isInFallback:m,isHydrating:y}=f;if(v)f.pendingBranch=h,Sn(h,v)?(l(v,h,f.hiddenContainer,null,i,f,o,a,s),f.deps<=0?f.resolve():m&&(l(p,d,r,n,i,null,o,a,s),pa(f,d))):(f.pendingId++,y?(f.isHydrating=!1,f.activeBranch=v):u(v,i,f),f.deps=0,f.effects.length=0,f.hiddenContainer=c("div"),m?(l(null,h,f.hiddenContainer,null,i,f,o,a,s),f.deps<=0?f.resolve():(l(p,d,r,n,i,null,o,a,s),pa(f,d))):p&&Sn(h,p)?(l(p,h,r,n,i,f,o,a,s),f.resolve(!0)):(l(null,h,f.hiddenContainer,null,i,f,o,a,s),f.deps<=0&&f.resolve()));else if(p&&Sn(h,p))l(p,h,r,n,i,f,o,a,s),pa(f,h);else if(Ns(e,"onPending"),f.pendingBranch=h,f.pendingId++,l(null,h,f.hiddenContainer,null,i,f,o,a,s),f.deps<=0)f.resolve();else{const{timeout:g,pendingId:b}=f;g>0?setTimeout(()=>{f.pendingId===b&&f.fallback(d)},g):g===0&&f.fallback(d)}}function Gd(t,e,r,n,i,o,a,s,l,u,c=!1){const{p:f,m:h,um:d,n:p,o:{parentNode:v,remove:m}}=u,y=Vi(t.props&&t.props.timeout),g={vnode:t,parent:e,parentComponent:r,isSVG:a,container:n,hiddenContainer:i,anchor:o,deps:0,pendingId:0,timeout:typeof y=="number"?y:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:c,isUnmounted:!1,effects:[],resolve(b=!1){const{vnode:T,activeBranch:w,pendingBranch:x,pendingId:R,effects:I,parentComponent:C,container:S}=g;if(g.isHydrating)g.isHydrating=!1;else if(!b){const G=w&&x.transition&&x.transition.mode==="out-in";G&&(w.transition.afterLeave=()=>{R===g.pendingId&&h(x,S,k,0)});let{anchor:k}=g;w&&(k=p(w),d(w,C,g,!0)),G||h(x,S,k,0)}pa(g,x),g.pendingBranch=null,g.isInFallback=!1;let L=g.parent,H=!1;for(;L;){if(L.pendingBranch){L.effects.push(...I),H=!0;break}L=L.parent}H||Bd(I),g.effects=[],Ns(T,"onResolve")},fallback(b){if(!g.pendingBranch)return;const{vnode:T,activeBranch:w,parentComponent:x,container:R,isSVG:I}=g;Ns(T,"onFallback");const C=p(w),S=()=>{!g.isInFallback||(f(null,b,R,C,x,null,I,s,l),pa(g,b))},L=b.transition&&b.transition.mode==="out-in";L&&(w.transition.afterLeave=S),g.isInFallback=!0,d(w,x,null,!0),L||S()},move(b,T,w){g.activeBranch&&h(g.activeBranch,b,T,w),g.container=b},next(){return g.activeBranch&&p(g.activeBranch)},registerDep(b,T){const w=!!g.pendingBranch;w&&g.deps++;const x=b.vnode.el;b.asyncDep.catch(R=>{Bo(R,b,0)}).then(R=>{if(b.isUnmounted||g.isUnmounted||g.pendingId!==b.suspenseId)return;b.asyncResolved=!0;const{vnode:I}=b;eh(b,R,!1),x&&(I.el=x);const C=!x&&b.subTree.el;T(b,I,v(x||b.subTree.el),x?null:p(b.subTree),g,a,l),C&&m(C),kd(b,I.el),w&&--g.deps===0&&g.resolve()})},unmount(b,T){g.isUnmounted=!0,g.activeBranch&&d(g.activeBranch,r,b,T),g.pendingBranch&&d(g.pendingBranch,r,b,T)}};return g}function GT(t,e,r,n,i,o,a,s,l){const u=e.suspense=Gd(e,n,r,t.parentNode,document.createElement("div"),null,i,o,a,s,!0),c=l(t,u.pendingBranch=e.ssContent,r,u,o,a);return u.deps===0&&u.resolve(),c}function DT(t){const{shapeFlag:e,children:r}=t,n=e&32;t.ssContent=rv(n?r.default:r),t.ssFallback=n?rv(r.fallback):P(Rr)}function rv(t){let e;if(zt(t)){const r=Ao&&t._c;r&&(t._d=!1,B()),t=t(),r&&(t._d=!0,e=Br,mb())}return Ct(t)&&(t=AT(t)),t=$r(t),e&&!t.dynamicChildren&&(t.dynamicChildren=e.filter(r=>r!==t)),t}function Vy(t,e){e&&e.pendingBranch?Ct(t)?e.effects.push(...t):e.effects.push(t):Bd(t)}function pa(t,e){t.activeBranch=e;const{vnode:r,parentComponent:n}=t,i=r.el=e.el;n&&n.subTree===r&&(n.vnode.el=i,kd(n,i))}function _o(t,e){if(dr){let r=dr.provides;const n=dr.parent&&dr.parent.provides;n===r&&(r=dr.provides=Object.create(n)),r[t]=e}}function en(t,e,r=!1){const n=dr||Ir;if(n){const i=n.parent==null?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides;if(i&&t in i)return i[t];if(arguments.length>1)return r&&zt(e)?e.call(n.proxy):e}}function Xe(t,e){return el(t,null,e)}function $y(t,e){return el(t,null,{flush:"post"})}function HT(t,e){return el(t,null,{flush:"sync"})}const nv={};function ze(t,e,r){return el(t,e,r)}function el(t,e,{immediate:r,deep:n,flush:i,onTrack:o,onTrigger:a}=Ee){const s=dr;let l,u=!1,c=!1;if(oe(t)?(l=()=>t.value,u=wu(t)):ki(t)?(l=()=>t,n=!0):Ct(t)?(c=!0,u=t.some(y=>ki(y)||wu(y)),l=()=>t.map(y=>{if(oe(y))return y.value;if(ki(y))return xo(y);if(zt(y))return Bn(y,s,2)})):zt(t)?e?l=()=>Bn(t,s,2):l=()=>{if(!(s&&s.isUnmounted))return f&&f(),Yr(t,s,3,[h])}:l=xn,e&&n){const y=l;l=()=>xo(y())}let f,h=y=>{f=m.onStop=()=>{Bn(y,s,4)}};if(wa)return h=xn,e?r&&Yr(e,s,3,[l(),c?[]:void 0,h]):l(),xn;let d=c?[]:nv;const p=()=>{if(!!m.active)if(e){const y=m.run();(n||u||(c?y.some((g,b)=>ba(g,d[b])):ba(y,d)))&&(f&&f(),Yr(e,s,3,[y,d===nv?void 0:d,h]),d=y)}else m.run()};p.allowRecurse=!!e;let v;i==="sync"?v=p:i==="post"?v=()=>_r(p,s&&s.suspense):v=()=>NT(p);const m=new tl(l,v);return e?r?p():d=m.run():i==="post"?_r(m.run.bind(m),s&&s.suspense):m.run(),()=>{m.stop(),s&&s.scope&&wd(s.scope.effects,m)}}function VT(t,e,r){const n=this.proxy,i=Ke(t)?t.includes(".")?jy(n,t):()=>n[t]:t.bind(n,n);let o;zt(e)?o=e:(o=e.handler,r=e);const a=dr;ji(this);const s=el(i,o.bind(n),r);return a?ji(a):Gi(),s}function jy(t,e){const r=e.split(".");return()=>{let n=t;for(let i=0;i{xo(r,e)});else if(yy(t))for(const r in t)xo(t[r],e);return t}function Dd(){const t={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Wn(()=>{t.isMounted=!0}),il(()=>{t.isUnmounting=!0}),t}const Jr=[Function,Array],$T={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Jr,onEnter:Jr,onAfterEnter:Jr,onEnterCancelled:Jr,onBeforeLeave:Jr,onLeave:Jr,onAfterLeave:Jr,onLeaveCancelled:Jr,onBeforeAppear:Jr,onAppear:Jr,onAfterAppear:Jr,onAppearCancelled:Jr},setup(t,{slots:e}){const r=Yn(),n=Dd();let i;return()=>{const o=e.default&&sc(e.default(),!0);if(!o||!o.length)return;let a=o[0];if(o.length>1){for(const v of o)if(v.type!==Rr){a=v;break}}const s=ue(t),{mode:l}=s;if(n.isLeaving)return Sc(a);const u=iv(a);if(!u)return Sc(a);const c=xa(u,s,n,r);So(u,c);const f=r.subTree,h=f&&iv(f);let d=!1;const{getTransitionKey:p}=u.type;if(p){const v=p();i===void 0?i=v:v!==i&&(i=v,d=!0)}if(h&&h.type!==Rr&&(!Sn(u,h)||d)){const v=xa(h,s,n,r);if(So(h,v),l==="out-in")return n.isLeaving=!0,v.afterLeave=()=>{n.isLeaving=!1,r.update()},Sc(a);l==="in-out"&&u.type!==Rr&&(v.delayLeave=(m,y,g)=>{const b=Xy(n,h);b[String(h.key)]=h,m._leaveCb=()=>{y(),m._leaveCb=void 0,delete c.delayedLeave},c.delayedLeave=g})}return a}}},Hd=$T;function Xy(t,e){const{leavingVNodes:r}=t;let n=r.get(e.type);return n||(n=Object.create(null),r.set(e.type,n)),n}function xa(t,e,r,n){const{appear:i,mode:o,persisted:a=!1,onBeforeEnter:s,onEnter:l,onAfterEnter:u,onEnterCancelled:c,onBeforeLeave:f,onLeave:h,onAfterLeave:d,onLeaveCancelled:p,onBeforeAppear:v,onAppear:m,onAfterAppear:y,onAppearCancelled:g}=e,b=String(t.key),T=Xy(r,t),w=(I,C)=>{I&&Yr(I,n,9,C)},x=(I,C)=>{const S=C[1];w(I,C),Ct(I)?I.every(L=>L.length<=1)&&S():I.length<=1&&S()},R={mode:o,persisted:a,beforeEnter(I){let C=s;if(!r.isMounted)if(i)C=v||s;else return;I._leaveCb&&I._leaveCb(!0);const S=T[b];S&&Sn(t,S)&&S.el._leaveCb&&S.el._leaveCb(),w(C,[I])},enter(I){let C=l,S=u,L=c;if(!r.isMounted)if(i)C=m||l,S=y||u,L=g||c;else return;let H=!1;const G=I._enterCb=k=>{H||(H=!0,k?w(L,[I]):w(S,[I]),R.delayedLeave&&R.delayedLeave(),I._enterCb=void 0)};C?x(C,[I,G]):G()},leave(I,C){const S=String(t.key);if(I._enterCb&&I._enterCb(!0),r.isUnmounting)return C();w(f,[I]);let L=!1;const H=I._leaveCb=G=>{L||(L=!0,C(),G?w(p,[I]):w(d,[I]),I._leaveCb=void 0,T[S]===t&&delete T[S])};T[S]=t,h?x(h,[I,H]):H()},clone(I){return xa(I,e,r,n)}};return R}function Sc(t){if(rl(t))return t=Vn(t),t.children=null,t}function iv(t){return rl(t)?t.children?t.children[0]:void 0:t}function So(t,e){t.shapeFlag&6&&t.component?So(t.component.subTree,e):t.shapeFlag&128?(t.ssContent.transition=e.clone(t.ssContent),t.ssFallback.transition=e.clone(t.ssFallback)):t.transition=e}function sc(t,e=!1,r){let n=[],i=0;for(let o=0;o1)for(let o=0;o!!t.type.__asyncLoader;function jT(t){zt(t)&&(t={loader:t});const{loader:e,loadingComponent:r,errorComponent:n,delay:i=200,timeout:o,suspensible:a=!0,onError:s}=t;let l=null,u,c=0;const f=()=>(c++,l=null,h()),h=()=>{let d;return l||(d=l=e().catch(p=>{if(p=p instanceof Error?p:new Error(String(p)),s)return new Promise((v,m)=>{s(p,()=>v(f()),()=>m(p),c+1)});throw p}).then(p=>d!==l&&l?l:(p&&(p.__esModule||p[Symbol.toStringTag]==="Module")&&(p=p.default),u=p,p)))};return Pt({name:"AsyncComponentWrapper",__asyncLoader:h,get __asyncResolved(){return u},setup(){const d=dr;if(u)return()=>Ac(u,d);const p=g=>{l=null,Bo(g,d,13,!n)};if(a&&d.suspense||wa)return h().then(g=>()=>Ac(g,d)).catch(g=>(p(g),()=>n?P(n,{error:g}):null));const v=It(!1),m=It(),y=It(!!i);return i&&setTimeout(()=>{y.value=!1},i),o!=null&&setTimeout(()=>{if(!v.value&&!m.value){const g=new Error(`Async component timed out after ${o}ms.`);p(g),m.value=g}},o),h().then(()=>{v.value=!0,d.parent&&rl(d.parent.vnode)&&Md(d.parent.update)}).catch(g=>{p(g),m.value=g}),()=>{if(v.value&&u)return Ac(u,d);if(m.value&&n)return P(n,{error:m.value});if(r&&!y.value)return P(r)}}})}function Ac(t,{vnode:{ref:e,props:r,children:n,shapeFlag:i},parent:o}){const a=P(t,r,n);return a.ref=e,a}const rl=t=>t.type.__isKeepAlive,XT={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(t,{slots:e}){const r=Yn(),n=r.ctx;if(!n.renderer)return()=>{const g=e.default&&e.default();return g&&g.length===1?g[0]:g};const i=new Map,o=new Set;let a=null;const s=r.suspense,{renderer:{p:l,m:u,um:c,o:{createElement:f}}}=n,h=f("div");n.activate=(g,b,T,w,x)=>{const R=g.component;u(g,b,T,0,s),l(R.vnode,g,b,T,R,s,w,g.slotScopeIds,x),_r(()=>{R.isDeactivated=!1,R.a&&da(R.a);const I=g.props&&g.props.onVnodeMounted;I&&Lr(I,R.parent,g)},s)},n.deactivate=g=>{const b=g.component;u(g,h,null,1,s),_r(()=>{b.da&&da(b.da);const T=g.props&&g.props.onVnodeUnmounted;T&&Lr(T,b.parent,g),b.isDeactivated=!0},s)};function d(g){Oc(g),c(g,r,s,!0)}function p(g){i.forEach((b,T)=>{const w=Su(b.type);w&&(!g||!g(w))&&v(T)})}function v(g){const b=i.get(g);!a||b.type!==a.type?d(b):a&&Oc(a),i.delete(g),o.delete(g)}ze(()=>[t.include,t.exclude],([g,b])=>{g&&p(T=>ts(g,T)),b&&p(T=>!ts(b,T))},{flush:"post",deep:!0});let m=null;const y=()=>{m!=null&&i.set(m,Uc(r.subTree))};return Wn(y),nl(y),il(()=>{i.forEach(g=>{const{subTree:b,suspense:T}=r,w=Uc(b);if(g.type===w.type){Oc(w);const x=w.component.da;x&&_r(x,T);return}d(g)})}),()=>{if(m=null,!e.default)return null;const g=e.default(),b=g[0];if(g.length>1)return a=null,g;if(!wn(b)||!(b.shapeFlag&4)&&!(b.shapeFlag&128))return a=null,b;let T=Uc(b);const w=T.type,x=Su(Io(T)?T.type.__asyncResolved||{}:w),{include:R,exclude:I,max:C}=t;if(R&&(!x||!ts(R,x))||I&&x&&ts(I,x))return a=T,b;const S=T.key==null?w:T.key,L=i.get(S);return T.el&&(T=Vn(T),b.shapeFlag&128&&(b.ssContent=T)),m=S,L?(T.el=L.el,T.component=L.component,T.transition&&So(T,T.transition),T.shapeFlag|=512,o.delete(S),o.add(S)):(o.add(S),C&&o.size>parseInt(C,10)&&v(o.values().next().value)),T.shapeFlag|=256,a=T,Hy(b.type)?b:T}}},zT=XT;function ts(t,e){return Ct(t)?t.some(r=>ts(r,e)):Ke(t)?t.split(",").includes(e):t.test?t.test(e):!1}function zy(t,e){Yy(t,"a",e)}function Wy(t,e){Yy(t,"da",e)}function Yy(t,e,r=dr){const n=t.__wdc||(t.__wdc=()=>{let i=r;for(;i;){if(i.isDeactivated)return;i=i.parent}return t()});if(lc(e,n,r),r){let i=r.parent;for(;i&&i.parent;)rl(i.parent.vnode)&&WT(n,e,r,i),i=i.parent}}function WT(t,e,r,n){const i=lc(e,t,n,!0);Aa(()=>{wd(n[e],i)},r)}function Oc(t){let e=t.shapeFlag;e&256&&(e-=256),e&512&&(e-=512),t.shapeFlag=e}function Uc(t){return t.shapeFlag&128?t.ssContent:t}function lc(t,e,r=dr,n=!1){if(r){const i=r[t]||(r[t]=[]),o=e.__weh||(e.__weh=(...a)=>{if(r.isUnmounted)return;Lo(),ji(r);const s=Yr(e,r,t,a);return Gi(),Mo(),s});return n?i.unshift(o):i.push(o),o}}const mi=t=>(e,r=dr)=>(!wa||t==="sp")&&lc(t,e,r),Ky=mi("bm"),Wn=mi("m"),Zy=mi("bu"),nl=mi("u"),il=mi("bum"),Aa=mi("um"),qy=mi("sp"),Jy=mi("rtg"),Qy=mi("rtc");function tb(t,e=dr){lc("ec",t,e)}function Oa(t,e){const r=Ir;if(r===null)return t;const n=cc(r)||r.proxy,i=t.dirs||(t.dirs=[]);for(let o=0;oe(a,s,void 0,o&&o[s]));else{const a=Object.keys(t);i=new Array(a.length);for(let s=0,l=a.length;swn(e)?!(e.type===Rr||e.type===Ot&&!rb(e.children)):!0)?t:null}function nb(t){const e={};for(const r in t)e[ss(r)]=t[r];return e}const Yf=t=>t?xb(t)?cc(t)||t.proxy:Yf(t.parent):null,Cu=er(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>Yf(t.parent),$root:t=>Yf(t.root),$emit:t=>t.emit,$options:t=>ob(t),$forceUpdate:t=>t.f||(t.f=()=>Md(t.update)),$nextTick:t=>t.n||(t.n=cr.bind(t.proxy)),$watch:t=>VT.bind(t)}),Kf={get({_:t},e){const{ctx:r,setupState:n,data:i,props:o,accessCache:a,type:s,appContext:l}=t;let u;if(e[0]!=="$"){const d=a[e];if(d!==void 0)switch(d){case 1:return n[e];case 2:return i[e];case 4:return r[e];case 3:return o[e]}else{if(n!==Ee&&me(n,e))return a[e]=1,n[e];if(i!==Ee&&me(i,e))return a[e]=2,i[e];if((u=t.propsOptions[0])&&me(u,e))return a[e]=3,o[e];if(r!==Ee&&me(r,e))return a[e]=4,r[e];Zf&&(a[e]=0)}}const c=Cu[e];let f,h;if(c)return e==="$attrs"&&Zr(t,"get",e),c(t);if((f=s.__cssModules)&&(f=f[e]))return f;if(r!==Ee&&me(r,e))return a[e]=4,r[e];if(h=l.config.globalProperties,me(h,e))return h[e]},set({_:t},e,r){const{data:n,setupState:i,ctx:o}=t;return i!==Ee&&me(i,e)?(i[e]=r,!0):n!==Ee&&me(n,e)?(n[e]=r,!0):me(t.props,e)||e[0]==="$"&&e.slice(1)in t?!1:(o[e]=r,!0)},has({_:{data:t,setupState:e,accessCache:r,ctx:n,appContext:i,propsOptions:o}},a){let s;return!!r[a]||t!==Ee&&me(t,a)||e!==Ee&&me(e,a)||(s=o[0])&&me(s,a)||me(n,a)||me(Cu,a)||me(i.config.globalProperties,a)},defineProperty(t,e,r){return r.get!=null?t._.accessCache[e]=0:me(r,"value")&&this.set(t,e,r.value,null),Reflect.defineProperty(t,e,r)}},qT=er({},Kf,{get(t,e){if(e!==Symbol.unscopables)return Kf.get(t,e,t)},has(t,e){return e[0]!=="_"&&!xx(e)}});let Zf=!0;function JT(t){const e=ob(t),r=t.proxy,n=t.ctx;Zf=!1,e.beforeCreate&&av(e.beforeCreate,t,"bc");const{data:i,computed:o,methods:a,watch:s,provide:l,inject:u,created:c,beforeMount:f,mounted:h,beforeUpdate:d,updated:p,activated:v,deactivated:m,beforeDestroy:y,beforeUnmount:g,destroyed:b,unmounted:T,render:w,renderTracked:x,renderTriggered:R,errorCaptured:I,serverPrefetch:C,expose:S,inheritAttrs:L,components:H,directives:G,filters:k}=e;if(u&&QT(u,n,null,t.appContext.config.unwrapInjectedRef),a)for(const K in a){const ht=a[K];zt(ht)&&(n[K]=ht.bind(r))}if(i){const K=i.call(r,r);rr(K)&&(t.data=zn(K))}if(Zf=!0,o)for(const K in o){const ht=o[K],bt=zt(ht)?ht.bind(r,r):zt(ht.get)?ht.get.bind(r,r):xn,W=!zt(ht)&&zt(ht.set)?ht.set.bind(r):xn,ft=tt({get:bt,set:W});Object.defineProperty(n,K,{enumerable:!0,configurable:!0,get:()=>ft.value,set:gt=>ft.value=gt})}if(s)for(const K in s)ib(s[K],n,r,K);if(l){const K=zt(l)?l.call(r):l;Reflect.ownKeys(K).forEach(ht=>{_o(ht,K[ht])})}c&&av(c,t,"c");function D(K,ht){Ct(ht)?ht.forEach(bt=>K(bt.bind(r))):ht&&K(ht.bind(r))}if(D(Ky,f),D(Wn,h),D(Zy,d),D(nl,p),D(zy,v),D(Wy,m),D(tb,I),D(Qy,x),D(Jy,R),D(il,g),D(Aa,T),D(qy,C),Ct(S))if(S.length){const K=t.exposed||(t.exposed={});S.forEach(ht=>{Object.defineProperty(K,ht,{get:()=>r[ht],set:bt=>r[ht]=bt})})}else t.exposed||(t.exposed={});w&&t.render===xn&&(t.render=w),L!=null&&(t.inheritAttrs=L),H&&(t.components=H),G&&(t.directives=G)}function QT(t,e,r=xn,n=!1){Ct(t)&&(t=qf(t));for(const i in t){const o=t[i];let a;rr(o)?"default"in o?a=en(o.from||i,o.default,!0):a=en(o.from||i):a=en(o),oe(a)&&n?Object.defineProperty(e,i,{enumerable:!0,configurable:!0,get:()=>a.value,set:s=>a.value=s}):e[i]=a}}function av(t,e,r){Yr(Ct(t)?t.map(n=>n.bind(e.proxy)):t.bind(e.proxy),e,r)}function ib(t,e,r,n){const i=n.includes(".")?jy(r,n):()=>r[n];if(Ke(t)){const o=e[t];zt(o)&&ze(i,o)}else if(zt(t))ze(i,t.bind(r));else if(rr(t))if(Ct(t))t.forEach(o=>ib(o,e,r,n));else{const o=zt(t.handler)?t.handler.bind(r):e[t.handler];zt(o)&&ze(i,o,t)}}function ob(t){const e=t.type,{mixins:r,extends:n}=e,{mixins:i,optionsCache:o,config:{optionMergeStrategies:a}}=t.appContext,s=o.get(e);let l;return s?l=s:!i.length&&!r&&!n?l=e:(l={},i.length&&i.forEach(u=>Ru(l,u,a,!0)),Ru(l,e,a)),o.set(e,l),l}function Ru(t,e,r,n=!1){const{mixins:i,extends:o}=e;o&&Ru(t,o,r,!0),i&&i.forEach(a=>Ru(t,a,r,!0));for(const a in e)if(!(n&&a==="expose")){const s=t2[a]||r&&r[a];t[a]=s?s(t[a],e[a]):e[a]}return t}const t2={data:sv,props:co,emits:co,methods:co,computed:co,beforeCreate:Nr,created:Nr,beforeMount:Nr,mounted:Nr,beforeUpdate:Nr,updated:Nr,beforeDestroy:Nr,beforeUnmount:Nr,destroyed:Nr,unmounted:Nr,activated:Nr,deactivated:Nr,errorCaptured:Nr,serverPrefetch:Nr,components:co,directives:co,watch:r2,provide:sv,inject:e2};function sv(t,e){return e?t?function(){return er(zt(t)?t.call(this,this):t,zt(e)?e.call(this,this):e)}:e:t}function e2(t,e){return co(qf(t),qf(e))}function qf(t){if(Ct(t)){const e={};for(let r=0;r0)&&!(a&16)){if(a&8){const c=t.vnode.dynamicProps;for(let f=0;f{l=!0;const[h,d]=sb(f,e,!0);er(a,h),d&&s.push(...d)};!r&&e.mixins.length&&e.mixins.forEach(c),t.extends&&c(t.extends),t.mixins&&t.mixins.forEach(c)}if(!o&&!l)return n.set(t,fa),fa;if(Ct(o))for(let c=0;c-1,d[1]=v<0||p-1||me(d,"default"))&&s.push(f)}}}const u=[a,s];return n.set(t,u),u}function lv(t){return t[0]!=="$"}function uv(t){const e=t&&t.toString().match(/^\s*function (\w+)/);return e?e[1]:t===null?"null":""}function cv(t,e){return uv(t)===uv(e)}function fv(t,e){return Ct(e)?e.findIndex(r=>cv(r,t)):zt(e)&&cv(e,t)?0:-1}const lb=t=>t[0]==="_"||t==="$stable",jd=t=>Ct(t)?t.map($r):[$r(t)],o2=(t,e,r)=>{if(e._n)return e;const n=Bt((...i)=>jd(e(...i)),r);return n._c=!1,n},ub=(t,e,r)=>{const n=t._ctx;for(const i in t){if(lb(i))continue;const o=t[i];if(zt(o))e[i]=o2(i,o,n);else if(o!=null){const a=jd(o);e[i]=()=>a}}},cb=(t,e)=>{const r=jd(e);t.slots.default=()=>r},a2=(t,e)=>{if(t.vnode.shapeFlag&32){const r=e._;r?(t.slots=ue(e),Tu(e,"_",r)):ub(e,t.slots={})}else t.slots={},e&&cb(t,e);Tu(t.slots,uc,1)},s2=(t,e,r)=>{const{vnode:n,slots:i}=t;let o=!0,a=Ee;if(n.shapeFlag&32){const s=e._;s?r&&s===1?o=!1:(er(i,e),!r&&s===1&&delete i._):(o=!e.$stable,ub(e,i)),a=e}else e&&(cb(t,e),a={default:1});if(o)for(const s in i)!lb(s)&&!(s in a)&&delete i[s]};function fb(){return{app:null,config:{isNativeTag:Nx,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let l2=0;function u2(t,e){return function(n,i=null){zt(n)||(n=Object.assign({},n)),i!=null&&!rr(i)&&(i=null);const o=fb(),a=new Set;let s=!1;const l=o.app={_uid:l2++,_component:n,_props:i,_container:null,_context:o,_instance:null,version:Sb,get config(){return o.config},set config(u){},use(u,...c){return a.has(u)||(u&&zt(u.install)?(a.add(u),u.install(l,...c)):zt(u)&&(a.add(u),u(l,...c))),l},mixin(u){return o.mixins.includes(u)||o.mixins.push(u),l},component(u,c){return c?(o.components[u]=c,l):o.components[u]},directive(u,c){return c?(o.directives[u]=c,l):o.directives[u]},mount(u,c,f){if(!s){const h=P(n,i);return h.appContext=o,c&&e?e(h,u):t(h,u,f),s=!0,l._container=u,u.__vue_app__=l,cc(h.component)||h.component.proxy}},unmount(){s&&(t(null,l._container),delete l._container.__vue_app__)},provide(u,c){return o.provides[u]=c,l}};return l}}function Nu(t,e,r,n,i=!1){if(Ct(t)){t.forEach((h,d)=>Nu(h,e&&(Ct(e)?e[d]:e),r,n,i));return}if(Io(n)&&!i)return;const o=n.shapeFlag&4?cc(n.component)||n.component.proxy:n.el,a=i?null:o,{i:s,r:l}=t,u=e&&e.r,c=s.refs===Ee?s.refs={}:s.refs,f=s.setupState;if(u!=null&&u!==l&&(Ke(u)?(c[u]=null,me(f,u)&&(f[u]=null)):oe(u)&&(u.value=null)),zt(l))Bn(l,s,12,[a,c]);else{const h=Ke(l),d=oe(l);if(h||d){const p=()=>{if(t.f){const v=h?c[l]:l.value;i?Ct(v)&&wd(v,o):Ct(v)?v.includes(o)||v.push(o):h?(c[l]=[o],me(f,l)&&(f[l]=c[l])):(l.value=[o],t.k&&(c[t.k]=l.value))}else h?(c[l]=a,me(f,l)&&(f[l]=a)):d&&(l.value=a,t.k&&(c[t.k]=a))};a?(p.id=-1,_r(p,r)):p()}}}let Ti=!1;const xl=t=>/svg/.test(t.namespaceURI)&&t.tagName!=="foreignObject",Tl=t=>t.nodeType===8;function c2(t){const{mt:e,p:r,o:{patchProp:n,createText:i,nextSibling:o,parentNode:a,remove:s,insert:l,createComment:u}}=t,c=(y,g)=>{if(!g.hasChildNodes()){r(null,y,g),Iu(),g._vnode=y;return}Ti=!1,f(g.firstChild,y,null,null,null),Iu(),g._vnode=y,Ti&&console.error("Hydration completed but contains mismatches.")},f=(y,g,b,T,w,x=!1)=>{const R=Tl(y)&&y.data==="[",I=()=>v(y,g,b,T,w,R),{type:C,ref:S,shapeFlag:L,patchFlag:H}=g,G=y.nodeType;g.el=y,H===-2&&(x=!1,g.dynamicChildren=null);let k=null;switch(C){case Ta:G!==3?g.children===""?(l(g.el=i(""),a(y),y),k=y):k=I():(y.data!==g.children&&(Ti=!0,y.data=g.children),k=o(y));break;case Rr:G!==8||R?k=I():k=o(y);break;case Co:if(G!==1&&G!==3)k=I();else{k=y;const Y=!g.children.length;for(let D=0;D{x=x||!!g.dynamicChildren;const{type:R,props:I,patchFlag:C,shapeFlag:S,dirs:L}=g,H=R==="input"&&L||R==="option";if(H||C!==-1){if(L&&Nn(g,null,b,"created"),I)if(H||!x||C&48)for(const k in I)(H&&k.endsWith("value")||qs(k)&&!as(k))&&n(y,k,null,I[k],!1,void 0,b);else I.onClick&&n(y,"onClick",null,I.onClick,!1,void 0,b);let G;if((G=I&&I.onVnodeBeforeMount)&&Lr(G,b,g),L&&Nn(g,null,b,"beforeMount"),((G=I&&I.onVnodeMounted)||L)&&Vy(()=>{G&&Lr(G,b,g),L&&Nn(g,null,b,"mounted")},T),S&16&&!(I&&(I.innerHTML||I.textContent))){let k=d(y.firstChild,g,y,b,T,w,x);for(;k;){Ti=!0;const Y=k;k=k.nextSibling,s(Y)}}else S&8&&y.textContent!==g.children&&(Ti=!0,y.textContent=g.children)}return y.nextSibling},d=(y,g,b,T,w,x,R)=>{R=R||!!g.dynamicChildren;const I=g.children,C=I.length;for(let S=0;S{const{slotScopeIds:R}=g;R&&(w=w?w.concat(R):R);const I=a(y),C=d(o(y),g,I,b,T,w,x);return C&&Tl(C)&&C.data==="]"?o(g.anchor=C):(Ti=!0,l(g.anchor=u("]"),I,C),C)},v=(y,g,b,T,w,x)=>{if(Ti=!0,g.el=null,x){const C=m(y);for(;;){const S=o(y);if(S&&S!==C)s(S);else break}}const R=o(y),I=a(y);return s(y),r(null,g,I,R,b,T,xl(I),w),R},m=y=>{let g=0;for(;y;)if(y=o(y),y&&Tl(y)&&(y.data==="["&&g++,y.data==="]")){if(g===0)return o(y);g--}return y};return[c,f]}const _r=Vy;function hb(t){return pb(t)}function db(t){return pb(t,c2)}function pb(t,e){const r=Fx();r.__VUE__=!0;const{insert:n,remove:i,patchProp:o,createElement:a,createText:s,createComment:l,setText:u,setElementText:c,parentNode:f,nextSibling:h,setScopeId:d=xn,cloneNode:p,insertStaticContent:v}=t,m=(N,A,$,j=null,q=null,st=null,mt=!1,at=null,ct=!!A.dynamicChildren)=>{if(N===A)return;N&&!Sn(N,A)&&(j=Gt(N),_t(N,q,st,!0),N=null),A.patchFlag===-2&&(ct=!1,A.dynamicChildren=null);const{type:rt,ref:Et,shapeFlag:xt}=A;switch(rt){case Ta:y(N,A,$,j);break;case Rr:g(N,A,$,j);break;case Co:N==null&&b(A,$,j,mt);break;case Ot:G(N,A,$,j,q,st,mt,at,ct);break;default:xt&1?x(N,A,$,j,q,st,mt,at,ct):xt&6?k(N,A,$,j,q,st,mt,at,ct):(xt&64||xt&128)&&rt.process(N,A,$,j,q,st,mt,at,ct,kt)}Et!=null&&q&&Nu(Et,N&&N.ref,st,A||N,!A)},y=(N,A,$,j)=>{if(N==null)n(A.el=s(A.children),$,j);else{const q=A.el=N.el;A.children!==N.children&&u(q,A.children)}},g=(N,A,$,j)=>{N==null?n(A.el=l(A.children||""),$,j):A.el=N.el},b=(N,A,$,j)=>{[N.el,N.anchor]=v(N.children,A,$,j,N.el,N.anchor)},T=({el:N,anchor:A},$,j)=>{let q;for(;N&&N!==A;)q=h(N),n(N,$,j),N=q;n(A,$,j)},w=({el:N,anchor:A})=>{let $;for(;N&&N!==A;)$=h(N),i(N),N=$;i(A)},x=(N,A,$,j,q,st,mt,at,ct)=>{mt=mt||A.type==="svg",N==null?R(A,$,j,q,st,mt,at,ct):S(N,A,q,st,mt,at,ct)},R=(N,A,$,j,q,st,mt,at)=>{let ct,rt;const{type:Et,props:xt,shapeFlag:St,transition:Dt,patchFlag:ie,dirs:ye}=N;if(N.el&&p!==void 0&&ie===-1)ct=N.el=p(N.el);else{if(ct=N.el=a(N.type,st,xt&&xt.is,xt),St&8?c(ct,N.children):St&16&&C(N.children,ct,null,j,q,st&&Et!=="foreignObject",mt,at),ye&&Nn(N,null,j,"created"),xt){for(const M in xt)M!=="value"&&!as(M)&&o(ct,M,null,xt[M],st,N.children,j,q,ut);"value"in xt&&o(ct,"value",null,xt.value),(rt=xt.onVnodeBeforeMount)&&Lr(rt,j,N)}I(ct,N,N.scopeId,mt,j)}ye&&Nn(N,null,j,"beforeMount");const F=(!q||q&&!q.pendingBranch)&&Dt&&!Dt.persisted;F&&Dt.beforeEnter(ct),n(ct,A,$),((rt=xt&&xt.onVnodeMounted)||F||ye)&&_r(()=>{rt&&Lr(rt,j,N),F&&Dt.enter(ct),ye&&Nn(N,null,j,"mounted")},q)},I=(N,A,$,j,q)=>{if($&&d(N,$),j)for(let st=0;st{for(let rt=ct;rt{const at=A.el=N.el;let{patchFlag:ct,dynamicChildren:rt,dirs:Et}=A;ct|=N.patchFlag&16;const xt=N.props||Ee,St=A.props||Ee;let Dt;$&&Ji($,!1),(Dt=St.onVnodeBeforeUpdate)&&Lr(Dt,$,A,N),Et&&Nn(A,N,$,"beforeUpdate"),$&&Ji($,!0);const ie=q&&A.type!=="foreignObject";if(rt?L(N.dynamicChildren,rt,at,$,j,ie,st):mt||bt(N,A,at,null,$,j,ie,st,!1),ct>0){if(ct&16)H(at,A,xt,St,$,j,q);else if(ct&2&&xt.class!==St.class&&o(at,"class",null,St.class,q),ct&4&&o(at,"style",xt.style,St.style,q),ct&8){const ye=A.dynamicProps;for(let F=0;F{Dt&&Lr(Dt,$,A,N),Et&&Nn(A,N,$,"updated")},j)},L=(N,A,$,j,q,st,mt)=>{for(let at=0;at{if($!==j){for(const at in j){if(as(at))continue;const ct=j[at],rt=$[at];ct!==rt&&at!=="value"&&o(N,at,rt,ct,mt,A.children,q,st,ut)}if($!==Ee)for(const at in $)!as(at)&&!(at in j)&&o(N,at,$[at],null,mt,A.children,q,st,ut);"value"in j&&o(N,"value",$.value,j.value)}},G=(N,A,$,j,q,st,mt,at,ct)=>{const rt=A.el=N?N.el:s(""),Et=A.anchor=N?N.anchor:s("");let{patchFlag:xt,dynamicChildren:St,slotScopeIds:Dt}=A;Dt&&(at=at?at.concat(Dt):Dt),N==null?(n(rt,$,j),n(Et,$,j),C(A.children,$,Et,q,st,mt,at,ct)):xt>0&&xt&64&&St&&N.dynamicChildren?(L(N.dynamicChildren,St,$,q,st,mt,at),(A.key!=null||q&&A===q.subTree)&&Xd(N,A,!0)):bt(N,A,$,Et,q,st,mt,at,ct)},k=(N,A,$,j,q,st,mt,at,ct)=>{A.slotScopeIds=at,N==null?A.shapeFlag&512?q.ctx.activate(A,$,j,mt,ct):Y(A,$,j,q,st,mt,ct):D(N,A,ct)},Y=(N,A,$,j,q,st,mt)=>{const at=N.component=_b(N,j,q);if(rl(N)&&(at.ctx.renderer=kt),Tb(at),at.asyncDep){if(q&&q.registerDep(at,K),!N.el){const ct=at.subTree=P(Rr);g(null,ct,A,$)}return}K(at,N,A,$,q,st,mt)},D=(N,A,$)=>{const j=A.component=N.component;if(FT(N,A,$))if(j.asyncDep&&!j.asyncResolved){ht(j,A,$);return}else j.next=A,RT(j.update),j.update();else A.el=N.el,j.vnode=A},K=(N,A,$,j,q,st,mt)=>{const at=()=>{if(N.isMounted){let{next:Et,bu:xt,u:St,parent:Dt,vnode:ie}=N,ye=Et,F;Ji(N,!1),Et?(Et.el=ie.el,ht(N,Et,mt)):Et=ie,xt&&da(xt),(F=Et.props&&Et.props.onVnodeBeforeUpdate)&&Lr(F,Dt,Et,ie),Ji(N,!0);const M=lu(N),z=N.subTree;N.subTree=M,m(z,M,f(z.el),Gt(z),N,q,st),Et.el=M.el,ye===null&&kd(N,M.el),St&&_r(St,q),(F=Et.props&&Et.props.onVnodeUpdated)&&_r(()=>Lr(F,Dt,Et,ie),q)}else{let Et;const{el:xt,props:St}=A,{bm:Dt,m:ie,parent:ye}=N,F=Io(A);if(Ji(N,!1),Dt&&da(Dt),!F&&(Et=St&&St.onVnodeBeforeMount)&&Lr(Et,ye,A),Ji(N,!0),xt&&Xt){const M=()=>{N.subTree=lu(N),Xt(xt,N.subTree,N,q,null)};F?A.type.__asyncLoader().then(()=>!N.isUnmounted&&M()):M()}else{const M=N.subTree=lu(N);m(null,M,$,j,N,q,st),A.el=M.el}if(ie&&_r(ie,q),!F&&(Et=St&&St.onVnodeMounted)){const M=A;_r(()=>Lr(Et,ye,M),q)}(A.shapeFlag&256||ye&&Io(ye.vnode)&&ye.vnode.shapeFlag&256)&&N.a&&_r(N.a,q),N.isMounted=!0,A=$=j=null}},ct=N.effect=new tl(at,()=>Md(rt),N.scope),rt=N.update=()=>ct.run();rt.id=N.uid,Ji(N,!0),rt()},ht=(N,A,$)=>{A.component=N;const j=N.vnode.props;N.vnode=A,N.next=null,i2(N,A.props,j,$),s2(N,A.children,$),Lo(),ic(void 0,N.update),Mo()},bt=(N,A,$,j,q,st,mt,at,ct=!1)=>{const rt=N&&N.children,Et=N?N.shapeFlag:0,xt=A.children,{patchFlag:St,shapeFlag:Dt}=A;if(St>0){if(St&128){ft(rt,xt,$,j,q,st,mt,at,ct);return}else if(St&256){W(rt,xt,$,j,q,st,mt,at,ct);return}}Dt&8?(Et&16&&ut(rt,q,st),xt!==rt&&c($,xt)):Et&16?Dt&16?ft(rt,xt,$,j,q,st,mt,at,ct):ut(rt,q,st,!0):(Et&8&&c($,""),Dt&16&&C(xt,$,j,q,st,mt,at,ct))},W=(N,A,$,j,q,st,mt,at,ct)=>{N=N||fa,A=A||fa;const rt=N.length,Et=A.length,xt=Math.min(rt,Et);let St;for(St=0;StEt?ut(N,q,st,!0,!1,xt):C(A,$,j,q,st,mt,at,ct,xt)},ft=(N,A,$,j,q,st,mt,at,ct)=>{let rt=0;const Et=A.length;let xt=N.length-1,St=Et-1;for(;rt<=xt&&rt<=St;){const Dt=N[rt],ie=A[rt]=ct?Ni(A[rt]):$r(A[rt]);if(Sn(Dt,ie))m(Dt,ie,$,null,q,st,mt,at,ct);else break;rt++}for(;rt<=xt&&rt<=St;){const Dt=N[xt],ie=A[St]=ct?Ni(A[St]):$r(A[St]);if(Sn(Dt,ie))m(Dt,ie,$,null,q,st,mt,at,ct);else break;xt--,St--}if(rt>xt){if(rt<=St){const Dt=St+1,ie=DtSt)for(;rt<=xt;)_t(N[rt],q,st,!0),rt++;else{const Dt=rt,ie=rt,ye=new Map;for(rt=ie;rt<=St;rt++){const Yt=A[rt]=ct?Ni(A[rt]):$r(A[rt]);Yt.key!=null&&ye.set(Yt.key,rt)}let F,M=0;const z=St-ie+1;let ot=!1,Tt=0;const Lt=new Array(z);for(rt=0;rt=z){_t(Yt,q,st,!0);continue}let xe;if(Yt.key!=null)xe=ye.get(Yt.key);else for(F=ie;F<=St;F++)if(Lt[F-ie]===0&&Sn(Yt,A[F])){xe=F;break}xe===void 0?_t(Yt,q,st,!0):(Lt[xe-ie]=rt+1,xe>=Tt?Tt=xe:ot=!0,m(Yt,A[xe],$,null,q,st,mt,at,ct),M++)}const Kt=ot?f2(Lt):fa;for(F=Kt.length-1,rt=z-1;rt>=0;rt--){const Yt=ie+rt,xe=A[Yt],$t=Yt+1{const{el:st,type:mt,transition:at,children:ct,shapeFlag:rt}=N;if(rt&6){gt(N.component.subTree,A,$,j);return}if(rt&128){N.suspense.move(A,$,j);return}if(rt&64){mt.move(N,A,$,kt);return}if(mt===Ot){n(st,A,$);for(let xt=0;xtat.enter(st),q);else{const{leave:xt,delayLeave:St,afterLeave:Dt}=at,ie=()=>n(st,A,$),ye=()=>{xt(st,()=>{ie(),Dt&&Dt()})};St?St(st,ie,ye):ye()}else n(st,A,$)},_t=(N,A,$,j=!1,q=!1)=>{const{type:st,props:mt,ref:at,children:ct,dynamicChildren:rt,shapeFlag:Et,patchFlag:xt,dirs:St}=N;if(at!=null&&Nu(at,null,$,N,!0),Et&256){A.ctx.deactivate(N);return}const Dt=Et&1&&St,ie=!Io(N);let ye;if(ie&&(ye=mt&&mt.onVnodeBeforeUnmount)&&Lr(ye,A,N),Et&6)lt(N.component,$,j);else{if(Et&128){N.suspense.unmount($,j);return}Dt&&Nn(N,null,A,"beforeUnmount"),Et&64?N.type.remove(N,A,$,q,kt,j):rt&&(st!==Ot||xt>0&&xt&64)?ut(rt,A,$,!1,!0):(st===Ot&&xt&384||!q&&Et&16)&&ut(ct,A,$),j&&V(N)}(ie&&(ye=mt&&mt.onVnodeUnmounted)||Dt)&&_r(()=>{ye&&Lr(ye,A,N),Dt&&Nn(N,null,A,"unmounted")},$)},V=N=>{const{type:A,el:$,anchor:j,transition:q}=N;if(A===Ot){Z($,j);return}if(A===Co){w(N);return}const st=()=>{i($),q&&!q.persisted&&q.afterLeave&&q.afterLeave()};if(N.shapeFlag&1&&q&&!q.persisted){const{leave:mt,delayLeave:at}=q,ct=()=>mt($,st);at?at(N.el,st,ct):ct()}else st()},Z=(N,A)=>{let $;for(;N!==A;)$=h(N),i(N),N=$;i(A)},lt=(N,A,$)=>{const{bum:j,scope:q,update:st,subTree:mt,um:at}=N;j&&da(j),q.stop(),st&&(st.active=!1,_t(mt,N,A,$)),at&&_r(at,A),_r(()=>{N.isUnmounted=!0},A),A&&A.pendingBranch&&!A.isUnmounted&&N.asyncDep&&!N.asyncResolved&&N.suspenseId===A.pendingId&&(A.deps--,A.deps===0&&A.resolve())},ut=(N,A,$,j=!1,q=!1,st=0)=>{for(let mt=st;mtN.shapeFlag&6?Gt(N.component.subTree):N.shapeFlag&128?N.suspense.next():h(N.anchor||N.el),it=(N,A,$)=>{N==null?A._vnode&&_t(A._vnode,null,null,!0):m(A._vnode||null,N,A,null,null,null,$),Iu(),A._vnode=N},kt={p:m,um:_t,m:gt,r:V,mt:Y,mc:C,pc:bt,pbc:L,n:Gt,o:t};let Vt,Xt;return e&&([Vt,Xt]=e(kt)),{render:it,hydrate:Vt,createApp:u2(it,Vt)}}function Ji({effect:t,update:e},r){t.allowRecurse=e.allowRecurse=r}function Xd(t,e,r=!1){const n=t.children,i=e.children;if(Ct(n)&&Ct(i))for(let o=0;o>1,t[r[s]]0&&(e[n]=r[o-1]),r[o]=n)}}for(o=r.length,a=r[o-1];o-- >0;)r[o]=a,a=e[a];return r}const h2=t=>t.__isTeleport,fs=t=>t&&(t.disabled||t.disabled===""),hv=t=>typeof SVGElement!="undefined"&&t instanceof SVGElement,Qf=(t,e)=>{const r=t&&t.to;return Ke(r)?e?e(r):null:r},d2={__isTeleport:!0,process(t,e,r,n,i,o,a,s,l,u){const{mc:c,pc:f,pbc:h,o:{insert:d,querySelector:p,createText:v,createComment:m}}=u,y=fs(e.props);let{shapeFlag:g,children:b,dynamicChildren:T}=e;if(t==null){const w=e.el=v(""),x=e.anchor=v("");d(w,r,n),d(x,r,n);const R=e.target=Qf(e.props,p),I=e.targetAnchor=v("");R&&(d(I,R),a=a||hv(R));const C=(S,L)=>{g&16&&c(b,S,L,i,o,a,s,l)};y?C(r,x):R&&C(R,I)}else{e.el=t.el;const w=e.anchor=t.anchor,x=e.target=t.target,R=e.targetAnchor=t.targetAnchor,I=fs(t.props),C=I?r:x,S=I?w:R;if(a=a||hv(x),T?(h(t.dynamicChildren,T,C,i,o,a,s),Xd(t,e,!0)):l||f(t,e,C,S,i,o,a,s,!1),y)I||wl(e,r,w,u,1);else if((e.props&&e.props.to)!==(t.props&&t.props.to)){const L=e.target=Qf(e.props,p);L&&wl(e,L,null,u,0)}else I&&wl(e,x,R,u,1)}},remove(t,e,r,n,{um:i,o:{remove:o}},a){const{shapeFlag:s,children:l,anchor:u,targetAnchor:c,target:f,props:h}=t;if(f&&o(c),(a||!fs(h))&&(o(u),s&16))for(let d=0;d0?Br||fa:null,mb(),Ao>0&&Br&&Br.push(t),t}function Q(t,e,r,n,i,o){return gb(U(t,e,r,n,i,o,!0))}function Rt(t,e,r,n,i){return gb(P(t,e,r,n,i,!0))}function wn(t){return t?t.__v_isVNode===!0:!1}function Sn(t,e){return t.type===e.type&&t.key===e.key}function v2(t){}const uc="__vInternal",yb=({key:t})=>t!=null?t:null,uu=({ref:t,ref_key:e,ref_for:r})=>t!=null?Ke(t)||oe(t)||zt(t)?{i:Ir,r:t,k:e,f:!!r}:t:null;function U(t,e=null,r=null,n=0,i=null,o=t===Ot?0:1,a=!1,s=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&yb(e),ref:e&&uu(e),scopeId:ac,slotScopeIds:null,children:r,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:n,dynamicProps:i,dynamicChildren:null,appContext:null};return s?(zd(l,r),o&128&&t.normalize(l)):r&&(l.shapeFlag|=Ke(r)?8:16),Ao>0&&!a&&Br&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&Br.push(l),l}const P=m2;function m2(t,e=null,r=null,n=0,i=null,o=!1){if((!t||t===eb)&&(t=Rr),wn(t)){const s=Vn(t,e,!0);return r&&zd(s,r),Ao>0&&!o&&Br&&(s.shapeFlag&6?Br[Br.indexOf(t)]=s:Br.push(s)),s.patchFlag|=-2,s}if(C2(t)&&(t=t.__vccOpts),e){e=bb(e);let{class:s,style:l}=e;s&&!Ke(s)&&(e.class=Qt(s)),rr(l)&&(Sd(l)&&!Ct(l)&&(l=er({},l)),e.style=ce(l))}const a=Ke(t)?1:Hy(t)?128:h2(t)?64:rr(t)?4:zt(t)?2:0;return U(t,e,r,n,i,a,o,!0)}function bb(t){return t?Sd(t)||uc in t?er({},t):t:null}function Vn(t,e,r=!1){const{props:n,ref:i,patchFlag:o,children:a}=t,s=e?yr(n||{},e):n;return{__v_isVNode:!0,__v_skip:!0,type:t.type,props:s,key:s&&yb(s),ref:e&&e.ref?r&&i?Ct(i)?i.concat(uu(e)):[i,uu(e)]:uu(e):i,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:a,target:t.target,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==Ot?o===-1?16:o|16:o,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:t.transition,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&Vn(t.ssContent),ssFallback:t.ssFallback&&Vn(t.ssFallback),el:t.el,anchor:t.anchor}}function dt(t=" ",e=0){return P(Ta,null,t,e)}function g2(t,e){const r=P(Co,null,t);return r.staticCount=e,r}function yt(t="",e=!1){return e?(B(),Rt(Rr,null,t)):P(Rr,null,t)}function $r(t){return t==null||typeof t=="boolean"?P(Rr):Ct(t)?P(Ot,null,t.slice()):typeof t=="object"?Ni(t):P(Ta,null,String(t))}function Ni(t){return t.el===null||t.memo?t:Vn(t)}function zd(t,e){let r=0;const{shapeFlag:n}=t;if(e==null)e=null;else if(Ct(e))r=16;else if(typeof e=="object")if(n&65){const i=e.default;i&&(i._c&&(i._d=!1),zd(t,i()),i._c&&(i._d=!0));return}else{r=32;const i=e._;!i&&!(uc in e)?e._ctx=Ir:i===3&&Ir&&(Ir.slots._===1?e._=1:(e._=2,t.patchFlag|=1024))}else zt(e)?(e={default:e,_ctx:Ir},r=32):(e=String(e),n&64?(r=16,e=[dt(e)]):r=8);t.children=e,t.shapeFlag|=r}function yr(...t){const e={};for(let r=0;rdr||Ir,ji=t=>{dr=t,t.scope.on()},Gi=()=>{dr&&dr.scope.off(),dr=null};function xb(t){return t.vnode.shapeFlag&4}let wa=!1;function Tb(t,e=!1){wa=e;const{props:r,children:n}=t.vnode,i=xb(t);n2(t,r,i,e),a2(t,n);const o=i?_2(t,e):void 0;return wa=!1,o}function _2(t,e){const r=t.type;t.accessCache=Object.create(null),t.proxy=Ad(new Proxy(t.ctx,Kf));const{setup:n}=r;if(n){const i=t.setupContext=n.length>1?Eb(t):null;ji(t),Lo();const o=Bn(n,t,0,[t.props,i]);if(Mo(),Gi(),Ed(o)){if(o.then(Gi,Gi),e)return o.then(a=>{eh(t,a,e)}).catch(a=>{Bo(a,t,0)});t.asyncDep=o}else eh(t,o,e)}else wb(t,e)}function eh(t,e,r){zt(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:rr(e)&&(t.setupState=Fd(e)),wb(t,r)}let Pu,rh;function x2(t){Pu=t,rh=e=>{e.render._rc&&(e.withProxy=new Proxy(e.ctx,qT))}}const T2=()=>!Pu;function wb(t,e,r){const n=t.type;if(!t.render){if(!e&&Pu&&!n.render){const i=n.template;if(i){const{isCustomElement:o,compilerOptions:a}=t.appContext.config,{delimiters:s,compilerOptions:l}=n,u=er(er({isCustomElement:o,delimiters:s},a),l);n.render=Pu(i,u)}}t.render=n.render||xn,rh&&rh(t)}ji(t),Lo(),JT(t),Mo(),Gi()}function w2(t){return new Proxy(t.attrs,{get(e,r){return Zr(t,"get","$attrs"),e[r]}})}function Eb(t){const e=n=>{t.exposed=n||{}};let r;return{get attrs(){return r||(r=w2(t))},slots:t.slots,emit:t.emit,expose:e}}function cc(t){if(t.exposed)return t.exposeProxy||(t.exposeProxy=new Proxy(Fd(Ad(t.exposed)),{get(e,r){if(r in e)return e[r];if(r in Cu)return Cu[r](t)}}))}const E2=/(?:^|[-_])(\w)/g,I2=t=>t.replace(E2,e=>e.toUpperCase()).replace(/[-_]/g,"");function Su(t,e=!0){return zt(t)?t.displayName||t.name:t.name||e&&t.__name}function Ib(t,e,r=!1){let n=Su(e);if(!n&&e.__file){const i=e.__file.match(/([^/\\]+)\.\w+$/);i&&(n=i[1])}if(!n&&t&&t.parent){const i=o=>{for(const a in o)if(o[a]===e)return a};n=i(t.components||t.parent.type.components)||i(t.appContext.components)}return n?I2(n):r?"App":"Anonymous"}function C2(t){return zt(t)&&"__vccOpts"in t}const tt=(t,e)=>_T(t,e,wa);function R2(){return null}function N2(){return null}function P2(t){}function S2(t,e){return null}function A2(){return Cb().slots}function O2(){return Cb().attrs}function Cb(){const t=Yn();return t.setupContext||(t.setupContext=Eb(t))}function U2(t,e){const r=Ct(t)?t.reduce((n,i)=>(n[i]={},n),{}):t;for(const n in e){const i=r[n];i?Ct(i)||zt(i)?r[n]={type:i,default:e[n]}:i.default=e[n]:i===null&&(r[n]={default:e[n]})}return r}function F2(t,e){const r={};for(const n in t)e.includes(n)||Object.defineProperty(r,n,{enumerable:!0,get:()=>t[n]});return r}function L2(t){const e=Yn();let r=t();return Gi(),Ed(r)&&(r=r.catch(n=>{throw ji(e),n})),[r,()=>ji(e)]}function Rb(t,e,r){const n=arguments.length;return n===2?rr(e)&&!Ct(e)?wn(e)?P(t,null,[e]):P(t,e):P(t,null,e):(n>3?r=Array.prototype.slice.call(arguments,2):n===3&&wn(r)&&(r=[r]),P(t,e,r))}const Nb=Symbol(""),M2=()=>{{const t=en(Nb);return t||Uy("Server rendering context not provided. Make sure to only call useSSRContext() conditionally in the server build."),t}};function B2(){}function k2(t,e,r,n){const i=r[n];if(i&&Pb(i,t))return i;const o=e();return o.memo=t.slice(),r[n]=o}function Pb(t,e){const r=t.memo;if(r.length!=e.length)return!1;for(let n=0;n0&&Br&&Br.push(t),!0}const Sb="3.2.37",G2={createComponentInstance:_b,setupComponent:Tb,renderComponentRoot:lu,setCurrentRenderingInstance:Rs,isVNode:wn,normalizeVNode:$r},D2=G2,H2=null,V2=null,$2="http://www.w3.org/2000/svg",go=typeof document!="undefined"?document:null,dv=go&&go.createElement("template"),j2={insert:(t,e,r)=>{e.insertBefore(t,r||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,r,n)=>{const i=e?go.createElementNS($2,t):go.createElement(t,r?{is:r}:void 0);return t==="select"&&n&&n.multiple!=null&&i.setAttribute("multiple",n.multiple),i},createText:t=>go.createTextNode(t),createComment:t=>go.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>go.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},cloneNode(t){const e=t.cloneNode(!0);return"_value"in t&&(e._value=t._value),e},insertStaticContent(t,e,r,n,i,o){const a=r?r.previousSibling:e.lastChild;if(i&&(i===o||i.nextSibling))for(;e.insertBefore(i.cloneNode(!0),r),!(i===o||!(i=i.nextSibling)););else{dv.innerHTML=n?`${t}`:t;const s=dv.content;if(n){const l=s.firstChild;for(;l.firstChild;)s.appendChild(l.firstChild);s.removeChild(l)}e.insertBefore(s,r)}return[a?a.nextSibling:e.firstChild,r?r.previousSibling:e.lastChild]}};function X2(t,e,r){const n=t._vtc;n&&(e=(e?[e,...n]:[...n]).join(" ")),e==null?t.removeAttribute("class"):r?t.setAttribute("class",e):t.className=e}function z2(t,e,r){const n=t.style,i=Ke(r);if(r&&!i){for(const o in r)nh(n,o,r[o]);if(e&&!Ke(e))for(const o in e)r[o]==null&&nh(n,o,"")}else{const o=n.display;i?e!==r&&(n.cssText=r):e&&t.removeAttribute("style"),"_vod"in t&&(n.display=o)}}const pv=/\s*!important$/;function nh(t,e,r){if(Ct(r))r.forEach(n=>nh(t,e,n));else if(r==null&&(r=""),e.startsWith("--"))t.setProperty(e,r);else{const n=W2(t,e);pv.test(r)?t.setProperty(Mn(n),r.replace(pv,""),"important"):t[n]=r}}const vv=["Webkit","Moz","ms"],Fc={};function W2(t,e){const r=Fc[e];if(r)return r;let n=Kr(e);if(n!=="filter"&&n in t)return Fc[e]=n;n=Qs(n);for(let i=0;i{let t=Date.now,e=!1;if(typeof window!="undefined"){Date.now()>document.createEvent("Event").timeStamp&&(t=performance.now.bind(performance));const r=navigator.userAgent.match(/firefox\/(\d+)/i);e=!!(r&&Number(r[1])<=53)}return[t,e]})();let ih=0;const q2=Promise.resolve(),J2=()=>{ih=0},Q2=()=>ih||(q2.then(J2),ih=Ab());function ri(t,e,r,n){t.addEventListener(e,r,n)}function tw(t,e,r,n){t.removeEventListener(e,r,n)}function ew(t,e,r,n,i=null){const o=t._vei||(t._vei={}),a=o[e];if(n&&a)a.value=n;else{const[s,l]=rw(e);if(n){const u=o[e]=nw(n,i);ri(t,s,u,l)}else a&&(tw(t,s,a,l),o[e]=void 0)}}const gv=/(?:Once|Passive|Capture)$/;function rw(t){let e;if(gv.test(t)){e={};let r;for(;r=t.match(gv);)t=t.slice(0,t.length-r[0].length),e[r[0].toLowerCase()]=!0}return[Mn(t.slice(2)),e]}function nw(t,e){const r=n=>{const i=n.timeStamp||Ab();(Z2||i>=r.attached-1)&&Yr(iw(n,r.value),e,5,[n])};return r.value=t,r.attached=Q2(),r}function iw(t,e){if(Ct(e)){const r=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{r.call(t),t._stopped=!0},e.map(n=>i=>!i._stopped&&n&&n(i))}else return e}const yv=/^on[a-z]/,ow=(t,e,r,n,i=!1,o,a,s,l)=>{e==="class"?X2(t,n,i):e==="style"?z2(t,r,n):qs(e)?Td(e)||ew(t,e,r,n,a):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):aw(t,e,n,i))?K2(t,e,n,o,a,s,l):(e==="true-value"?t._trueValue=n:e==="false-value"&&(t._falseValue=n),Y2(t,e,n,i))};function aw(t,e,r,n){return n?!!(e==="innerHTML"||e==="textContent"||e in t&&yv.test(e)&&zt(r)):e==="spellcheck"||e==="draggable"||e==="translate"||e==="form"||e==="list"&&t.tagName==="INPUT"||e==="type"&&t.tagName==="TEXTAREA"||yv.test(e)&&Ke(r)?!1:e in t}function Ob(t,e){const r=Pt(t);class n extends fc{constructor(o){super(r,o,e)}}return n.def=r,n}const sw=t=>Ob(t,Wb),lw=typeof HTMLElement!="undefined"?HTMLElement:class{};class fc extends lw{constructor(e,r={},n){super(),this._def=e,this._props=r,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this.shadowRoot&&n?n(this._createVNode(),this.shadowRoot):this.attachShadow({mode:"open"})}connectedCallback(){this._connected=!0,this._instance||this._resolveDef()}disconnectedCallback(){this._connected=!1,cr(()=>{this._connected||(ah(null,this.shadowRoot),this._instance=null)})}_resolveDef(){if(this._resolved)return;this._resolved=!0;for(let n=0;n{for(const i of n)this._setAttr(i.attributeName)}).observe(this,{attributes:!0});const e=n=>{const{props:i,styles:o}=n,a=!Ct(i),s=i?a?Object.keys(i):i:[];let l;if(a)for(const u in this._props){const c=i[u];(c===Number||c&&c.type===Number)&&(this._props[u]=Vi(this._props[u]),(l||(l=Object.create(null)))[u]=!0)}this._numberProps=l;for(const u of Object.keys(this))u[0]!=="_"&&this._setProp(u,this[u],!0,!1);for(const u of s.map(Kr))Object.defineProperty(this,u,{get(){return this._getProp(u)},set(c){this._setProp(u,c)}});this._applyStyles(o),this._update()},r=this._def.__asyncLoader;r?r().then(e):e(this._def)}_setAttr(e){let r=this.getAttribute(e);this._numberProps&&this._numberProps[e]&&(r=Vi(r)),this._setProp(Kr(e),r,!1)}_getProp(e){return this._props[e]}_setProp(e,r,n=!0,i=!0){r!==this._props[e]&&(this._props[e]=r,i&&this._instance&&this._update(),n&&(r===!0?this.setAttribute(Mn(e),""):typeof r=="string"||typeof r=="number"?this.setAttribute(Mn(e),r+""):r||this.removeAttribute(Mn(e))))}_update(){ah(this._createVNode(),this.shadowRoot)}_createVNode(){const e=P(this._def,er({},this._props));return this._instance||(e.ce=r=>{this._instance=r,r.isCE=!0,r.emit=(i,...o)=>{this.dispatchEvent(new CustomEvent(i,{detail:o}))};let n=this;for(;n=n&&(n.parentNode||n.host);)if(n instanceof fc){r.parent=n._instance;break}}),e}_applyStyles(e){e&&e.forEach(r=>{const n=document.createElement("style");n.textContent=r,this.shadowRoot.appendChild(n)})}}function uw(t="$style"){{const e=Yn();if(!e)return Ee;const r=e.type.__cssModules;if(!r)return Ee;const n=r[t];return n||Ee}}function cw(t){const e=Yn();if(!e)return;const r=()=>oh(e.subTree,t(e.proxy));$y(r),Wn(()=>{const n=new MutationObserver(r);n.observe(e.subTree.el.parentNode,{childList:!0}),Aa(()=>n.disconnect())})}function oh(t,e){if(t.shapeFlag&128){const r=t.suspense;t=r.activeBranch,r.pendingBranch&&!r.isHydrating&&r.effects.push(()=>{oh(r.activeBranch,e)})}for(;t.component;)t=t.component.subTree;if(t.shapeFlag&1&&t.el)bv(t.el,e);else if(t.type===Ot)t.children.forEach(r=>oh(r,e));else if(t.type===Co){let{el:r,anchor:n}=t;for(;r&&(bv(r,e),r!==n);)r=r.nextSibling}}function bv(t,e){if(t.nodeType===1){const r=t.style;for(const n in e)r.setProperty(`--${n}`,e[n])}}const wi="transition",Ba="animation",Yi=(t,{slots:e})=>Rb(Hd,Fb(t),e);Yi.displayName="Transition";const Ub={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},fw=Yi.props=er({},Hd.props,Ub),Qi=(t,e=[])=>{Ct(t)?t.forEach(r=>r(...e)):t&&t(...e)},_v=t=>t?Ct(t)?t.some(e=>e.length>1):t.length>1:!1;function Fb(t){const e={};for(const H in t)H in Ub||(e[H]=t[H]);if(t.css===!1)return e;const{name:r="v",type:n,duration:i,enterFromClass:o=`${r}-enter-from`,enterActiveClass:a=`${r}-enter-active`,enterToClass:s=`${r}-enter-to`,appearFromClass:l=o,appearActiveClass:u=a,appearToClass:c=s,leaveFromClass:f=`${r}-leave-from`,leaveActiveClass:h=`${r}-leave-active`,leaveToClass:d=`${r}-leave-to`}=t,p=hw(i),v=p&&p[0],m=p&&p[1],{onBeforeEnter:y,onEnter:g,onEnterCancelled:b,onLeave:T,onLeaveCancelled:w,onBeforeAppear:x=y,onAppear:R=g,onAppearCancelled:I=b}=e,C=(H,G,k)=>{Ri(H,G?c:s),Ri(H,G?u:a),k&&k()},S=(H,G)=>{H._isLeaving=!1,Ri(H,f),Ri(H,d),Ri(H,h),G&&G()},L=H=>(G,k)=>{const Y=H?R:g,D=()=>C(G,H,k);Qi(Y,[G,D]),xv(()=>{Ri(G,H?l:o),Qn(G,H?c:s),_v(Y)||Tv(G,n,v,D)})};return er(e,{onBeforeEnter(H){Qi(y,[H]),Qn(H,o),Qn(H,a)},onBeforeAppear(H){Qi(x,[H]),Qn(H,l),Qn(H,u)},onEnter:L(!1),onAppear:L(!0),onLeave(H,G){H._isLeaving=!0;const k=()=>S(H,G);Qn(H,f),Mb(),Qn(H,h),xv(()=>{!H._isLeaving||(Ri(H,f),Qn(H,d),_v(T)||Tv(H,n,m,k))}),Qi(T,[H,k])},onEnterCancelled(H){C(H,!1),Qi(b,[H])},onAppearCancelled(H){C(H,!0),Qi(I,[H])},onLeaveCancelled(H){S(H),Qi(w,[H])}})}function hw(t){if(t==null)return null;if(rr(t))return[Lc(t.enter),Lc(t.leave)];{const e=Lc(t);return[e,e]}}function Lc(t){return Vi(t)}function Qn(t,e){e.split(/\s+/).forEach(r=>r&&t.classList.add(r)),(t._vtc||(t._vtc=new Set)).add(e)}function Ri(t,e){e.split(/\s+/).forEach(n=>n&&t.classList.remove(n));const{_vtc:r}=t;r&&(r.delete(e),r.size||(t._vtc=void 0))}function xv(t){requestAnimationFrame(()=>{requestAnimationFrame(t)})}let dw=0;function Tv(t,e,r,n){const i=t._endId=++dw,o=()=>{i===t._endId&&n()};if(r)return setTimeout(o,r);const{type:a,timeout:s,propCount:l}=Lb(t,e);if(!a)return n();const u=a+"end";let c=0;const f=()=>{t.removeEventListener(u,h),o()},h=d=>{d.target===t&&++c>=l&&f()};setTimeout(()=>{c(r[p]||"").split(", "),i=n(wi+"Delay"),o=n(wi+"Duration"),a=wv(i,o),s=n(Ba+"Delay"),l=n(Ba+"Duration"),u=wv(s,l);let c=null,f=0,h=0;e===wi?a>0&&(c=wi,f=a,h=o.length):e===Ba?u>0&&(c=Ba,f=u,h=l.length):(f=Math.max(a,u),c=f>0?a>u?wi:Ba:null,h=c?c===wi?o.length:l.length:0);const d=c===wi&&/\b(transform|all)(,|$)/.test(r[wi+"Property"]);return{type:c,timeout:f,propCount:h,hasTransform:d}}function wv(t,e){for(;t.lengthEv(r)+Ev(t[n])))}function Ev(t){return Number(t.slice(0,-1).replace(",","."))*1e3}function Mb(){return document.body.offsetHeight}const Bb=new WeakMap,kb=new WeakMap,pw={name:"TransitionGroup",props:er({},fw,{tag:String,moveClass:String}),setup(t,{slots:e}){const r=Yn(),n=Dd();let i,o;return nl(()=>{if(!i.length)return;const a=t.moveClass||`${t.name||"v"}-move`;if(!yw(i[0].el,r.vnode.el,a))return;i.forEach(vw),i.forEach(mw);const s=i.filter(gw);Mb(),s.forEach(l=>{const u=l.el,c=u.style;Qn(u,a),c.transform=c.webkitTransform=c.transitionDuration="";const f=u._moveCb=h=>{h&&h.target!==u||(!h||/transform$/.test(h.propertyName))&&(u.removeEventListener("transitionend",f),u._moveCb=null,Ri(u,a))};u.addEventListener("transitionend",f)})}),()=>{const a=ue(t),s=Fb(a);let l=a.tag||Ot;i=o,o=e.default?sc(e.default()):[];for(let u=0;u{a.split(/\s+/).forEach(s=>s&&n.classList.remove(s))}),r.split(/\s+/).forEach(a=>a&&n.classList.add(a)),n.style.display="none";const i=e.nodeType===1?e:e.parentNode;i.appendChild(n);const{hasTransform:o}=Lb(n);return i.removeChild(n),o}const Xi=t=>{const e=t.props["onUpdate:modelValue"]||!1;return Ct(e)?r=>da(e,r):e};function bw(t){t.target.composing=!0}function Iv(t){const e=t.target;e.composing&&(e.composing=!1,e.dispatchEvent(new Event("input")))}const Ea={created(t,{modifiers:{lazy:e,trim:r,number:n}},i){t._assign=Xi(i);const o=n||i.props&&i.props.type==="number";ri(t,e?"change":"input",a=>{if(a.target.composing)return;let s=t.value;r&&(s=s.trim()),o&&(s=Vi(s)),t._assign(s)}),r&&ri(t,"change",()=>{t.value=t.value.trim()}),e||(ri(t,"compositionstart",bw),ri(t,"compositionend",Iv),ri(t,"change",Iv))},mounted(t,{value:e}){t.value=e==null?"":e},beforeUpdate(t,{value:e,modifiers:{lazy:r,trim:n,number:i}},o){if(t._assign=Xi(o),t.composing||document.activeElement===t&&t.type!=="range"&&(r||n&&t.value.trim()===e||(i||t.type==="number")&&Vi(t.value)===e))return;const a=e==null?"":e;t.value!==a&&(t.value=a)}},hc={deep:!0,created(t,e,r){t._assign=Xi(r),ri(t,"change",()=>{const n=t._modelValue,i=Ia(t),o=t.checked,a=t._assign;if(Ct(n)){const s=qu(n,i),l=s!==-1;if(o&&!l)a(n.concat(i));else if(!o&&l){const u=[...n];u.splice(s,1),a(u)}}else if(Fo(n)){const s=new Set(n);o?s.add(i):s.delete(i),a(s)}else a(Hb(t,o))})},mounted:Cv,beforeUpdate(t,e,r){t._assign=Xi(r),Cv(t,e,r)}};function Cv(t,{value:e,oldValue:r},n){t._modelValue=e,Ct(e)?t.checked=qu(e,n.props.value)>-1:Fo(e)?t.checked=e.has(n.props.value):e!==r&&(t.checked=Hi(e,Hb(t,!0)))}const Wd={created(t,{value:e},r){t.checked=Hi(e,r.props.value),t._assign=Xi(r),ri(t,"change",()=>{t._assign(Ia(t))})},beforeUpdate(t,{value:e,oldValue:r},n){t._assign=Xi(n),e!==r&&(t.checked=Hi(e,n.props.value))}},Db={deep:!0,created(t,{value:e,modifiers:{number:r}},n){const i=Fo(e);ri(t,"change",()=>{const o=Array.prototype.filter.call(t.options,a=>a.selected).map(a=>r?Vi(Ia(a)):Ia(a));t._assign(t.multiple?i?new Set(o):o:o[0])}),t._assign=Xi(n)},mounted(t,{value:e}){Rv(t,e)},beforeUpdate(t,e,r){t._assign=Xi(r)},updated(t,{value:e}){Rv(t,e)}};function Rv(t,e){const r=t.multiple;if(!(r&&!Ct(e)&&!Fo(e))){for(let n=0,i=t.options.length;n-1:o.selected=e.has(a);else if(Hi(Ia(o),e)){t.selectedIndex!==n&&(t.selectedIndex=n);return}}!r&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}}function Ia(t){return"_value"in t?t._value:t.value}function Hb(t,e){const r=e?"_trueValue":"_falseValue";return r in t?t[r]:e}const Vb={created(t,e,r){El(t,e,r,null,"created")},mounted(t,e,r){El(t,e,r,null,"mounted")},beforeUpdate(t,e,r,n){El(t,e,r,n,"beforeUpdate")},updated(t,e,r,n){El(t,e,r,n,"updated")}};function $b(t,e){switch(t){case"SELECT":return Db;case"TEXTAREA":return Ea;default:switch(e){case"checkbox":return hc;case"radio":return Wd;default:return Ea}}}function El(t,e,r,n,i){const a=$b(t.tagName,r.props&&r.props.type)[i];a&&a(t,e,r,n)}function _w(){Ea.getSSRProps=({value:t})=>({value:t}),Wd.getSSRProps=({value:t},e)=>{if(e.props&&Hi(e.props.value,t))return{checked:!0}},hc.getSSRProps=({value:t},e)=>{if(Ct(t)){if(e.props&&qu(t,e.props.value)>-1)return{checked:!0}}else if(Fo(t)){if(e.props&&t.has(e.props.value))return{checked:!0}}else if(t)return{checked:!0}},Vb.getSSRProps=(t,e)=>{if(typeof e.type!="string")return;const r=$b(e.type.toUpperCase(),e.props&&e.props.type);if(r.getSSRProps)return r.getSSRProps(t,e)}}const xw=["ctrl","shift","alt","meta"],Tw={stop:t=>t.stopPropagation(),prevent:t=>t.preventDefault(),self:t=>t.target!==t.currentTarget,ctrl:t=>!t.ctrlKey,shift:t=>!t.shiftKey,alt:t=>!t.altKey,meta:t=>!t.metaKey,left:t=>"button"in t&&t.button!==0,middle:t=>"button"in t&&t.button!==1,right:t=>"button"in t&&t.button!==2,exact:(t,e)=>xw.some(r=>t[`${r}Key`]&&!e.includes(r))},mr=(t,e)=>(r,...n)=>{for(let i=0;ir=>{if(!("key"in r))return;const n=Mn(r.key);if(e.some(i=>i===n||ww[i]===n))return t(r)},dc={beforeMount(t,{value:e},{transition:r}){t._vod=t.style.display==="none"?"":t.style.display,r&&e?r.beforeEnter(t):ka(t,e)},mounted(t,{value:e},{transition:r}){r&&e&&r.enter(t)},updated(t,{value:e,oldValue:r},{transition:n}){!e!=!r&&(n?e?(n.beforeEnter(t),ka(t,!0),n.enter(t)):n.leave(t,()=>{ka(t,!1)}):ka(t,e))},beforeUnmount(t,{value:e}){ka(t,e)}};function ka(t,e){t.style.display=e?t._vod:"none"}function Ew(){dc.getSSRProps=({value:t})=>{if(!t)return{style:{display:"none"}}}}const jb=er({patchProp:ow},j2);let ds,Nv=!1;function Xb(){return ds||(ds=hb(jb))}function zb(){return ds=Nv?ds:db(jb),Nv=!0,ds}const ah=(...t)=>{Xb().render(...t)},Wb=(...t)=>{zb().hydrate(...t)},Yd=(...t)=>{const e=Xb().createApp(...t),{mount:r}=e;return e.mount=n=>{const i=Yb(n);if(!i)return;const o=e._component;!zt(o)&&!o.render&&!o.template&&(o.template=i.innerHTML),i.innerHTML="";const a=r(i,!1,i instanceof SVGElement);return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),a},e},Iw=(...t)=>{const e=zb().createApp(...t),{mount:r}=e;return e.mount=n=>{const i=Yb(n);if(i)return r(i,!0,i instanceof SVGElement)},e};function Yb(t){return Ke(t)?document.querySelector(t):t}let Pv=!1;const Cw=()=>{Pv||(Pv=!0,_w(),Ew())},Rw=()=>{};var Nw=Object.freeze(Object.defineProperty({__proto__:null,compile:Rw,EffectScope:Cd,ReactiveEffect:tl,customRef:gT,effect:Dx,effectScope:Lx,getCurrentScope:Mx,isProxy:Sd,isReactive:ki,isReadonly:_a,isRef:oe,isShallow:wu,markRaw:Ad,onScopeDispose:Bx,proxyRefs:Fd,reactive:zn,readonly:Pd,ref:It,shallowReactive:Sa,shallowReadonly:hT,shallowRef:Gr,stop:Hx,toRaw:ue,toRef:Mr,toRefs:Ae,triggerRef:pT,unref:E,camelize:Kr,capitalize:Qs,normalizeClass:Qt,normalizeProps:vy,normalizeStyle:ce,toDisplayString:re,toHandlerKey:ss,BaseTransition:Hd,Comment:Rr,Fragment:Ot,KeepAlive:zT,Static:Co,Suspense:MT,Teleport:vb,Text:Ta,callWithAsyncErrorHandling:Yr,callWithErrorHandling:Bn,cloneVNode:Vn,compatUtils:V2,computed:tt,createBlock:Rt,createCommentVNode:yt,createElementBlock:Q,createElementVNode:U,createHydrationRenderer:db,createPropsRestProxy:F2,createRenderer:hb,createSlots:ZT,createStaticVNode:g2,createTextVNode:dt,createVNode:P,defineAsyncComponent:jT,defineComponent:Pt,defineEmits:N2,defineExpose:P2,defineProps:R2,get devtools(){return Jo},getCurrentInstance:Yn,getTransitionRawChildren:sc,guardReactiveProps:bb,h:Rb,handleError:Bo,initCustomFormatter:B2,inject:en,isMemoSame:Pb,isRuntimeOnly:T2,isVNode:wn,mergeDefaults:U2,mergeProps:yr,nextTick:cr,onActivated:zy,onBeforeMount:Ky,onBeforeUnmount:il,onBeforeUpdate:Zy,onDeactivated:Wy,onErrorCaptured:tb,onMounted:Wn,onRenderTracked:Qy,onRenderTriggered:Jy,onServerPrefetch:qy,onUnmounted:Aa,onUpdated:nl,openBlock:B,popScopeId:Rn,provide:_o,pushScopeId:Cn,queuePostFlushCb:Bd,registerRuntimeCompiler:x2,renderList:Hn,renderSlot:He,resolveComponent:Re,resolveDirective:KT,resolveDynamicComponent:Te,resolveFilter:H2,resolveTransitionHooks:xa,setBlockTracking:th,setDevtoolsHook:Gy,setTransitionHooks:So,ssrContextKey:Nb,ssrUtils:D2,toHandlers:nb,transformVNodeArgs:v2,useAttrs:O2,useSSRContext:M2,useSlots:A2,useTransitionState:Dd,version:Sb,warn:Uy,watch:ze,watchEffect:Xe,watchPostEffect:$y,watchSyncEffect:HT,withAsyncContext:L2,withCtx:Bt,withDefaults:S2,withDirectives:Oa,withMemo:k2,withScopeId:ST,Transition:Yi,TransitionGroup:Gb,VueElement:fc,createApp:Yd,createSSRApp:Iw,defineCustomElement:Ob,defineSSRCustomElement:sw,hydrate:Wb,initDirectivesForSSR:Cw,render:ah,useCssModule:uw,useCssVars:cw,vModelCheckbox:hc,vModelDynamic:Vb,vModelRadio:Wd,vModelSelect:Db,vModelText:Ea,vShow:dc,withKeys:yo,withModifiers:mr},Symbol.toStringTag,{value:"Module"}));const Pw="Profectus Demo",Sw="A demo project made in Profectus",Aw="profectus-demo",Ow="",Uw="",Fw="",Lw="0.0",Mw="Initial Commit",Bw=!0,kw=!1,Gw=2,Dw=!0,Hw=null,Vw="Logo.png",$w=["main","c"],jw=3600,Xw=1,zw=!0,Ww="base64";var Ie={title:Pw,description:Sw,id:Aw,author:Ow,discordName:Uw,discordLink:Fw,versionNumber:Lw,versionTitle:Mw,allowGoBack:Bw,defaultShowSmall:kw,defaultDecimalsShown:Gw,useHeader:Dw,banner:Hw,logo:Vw,initialTabs:$w,maxTickLength:jw,offlineLimit:Xw,enablePausing:zw,exportEncoding:Ww};const Mc=17,Yw=9e15,Kw=Math.log10(9e15),Zw=1/9e15,qw=308,Jw=-324,Sv=5,Qw=function(){const t=[];for(let r=Jw+1;r<=qw;r++)t.push(Number("1e"+r));const e=323;return function(r){return t[r+e]}}(),to=[2,Math.E,3,4,5,6,7,8,9,10],tE=[[1,1.0891168053867777,1.1789745164521264,1.2701428397304229,1.3632066654400328,1.4587804913784246,1.557523817412741,1.660158301473385,1.767487542936873,1.8804205225512542,2],[1,1.1121114330934,1.23103892493161,1.35838369631113,1.49605193039935,1.64635423375119,1.81213853570186,1.99697132461829,2.20538955455724,2.44325744833852,Math.E],[1,1.1187738849693603,1.2464963939368214,1.38527004705667,1.5376664685821402,1.7068895236551784,1.897001227148399,2.1132403089001035,2.362480153784171,2.6539010333870774,3],[1,1.1367350847096405,1.2889510672956703,1.4606478703324786,1.6570295196661111,1.8850062585672889,2.1539465047453485,2.476829779693097,2.872061932789197,3.3664204535587183,4],[1,1.1494592900767588,1.319708228183931,1.5166291280087583,1.748171114438024,2.0253263297298045,2.3636668498288547,2.7858359149579424,3.3257226212448145,4.035730287722532,5],[1,1.159225940787673,1.343712473580932,1.5611293155111927,1.8221199554561318,2.14183924486326,2.542468319282638,3.0574682501653316,3.7390572020926873,4.6719550537360774,6],[1,1.1670905356972596,1.3632807444991446,1.5979222279405536,1.8842640123816674,2.2416069644878687,2.69893426559423,3.3012632110403577,4.121250340630164,5.281493033448316,7],[1,1.1736630594087796,1.379783782386201,1.6292821855668218,1.9378971836180754,2.3289975651071977,2.8384347394720835,3.5232708454565906,4.478242031114584,5.868592169644505,8],[1,1.1793017514670474,1.394054150657457,1.65664127441059,1.985170999970283,2.4069682290577457,2.9647310119960752,3.7278665320924946,4.814462547283592,6.436522247411611,9],[1,1.18422737399915,1.4066113788546144,1.680911177655277,2.027492094355525,2.4775152854601967,3.080455730250329,3.918234505962507,5.1332705696484595,6.9878696918072905,10]],eE=[[-1,-.9194161097107025,-.8335625019330468,-.7425599821143978,-.6466611521029437,-.5462617907227869,-.4419033816638769,-.3342645487554494,-.224140440909962,-.11241087890006762,0],[-1,-.90603157029014,-.80786507256596,-.7064666939634,-.60294836853664,-.49849837513117,-.39430303318768,-.29147201034755,-.19097820800866,-.09361896280296,0],[-1,-.9021579584316141,-.8005762598234203,-.6964780623319391,-.5911906810998454,-.486050182576545,-.3823089430815083,-.28106046722897615,-.1831906535795894,-.08935809204418144,0],[-1,-.8917227442365535,-.781258746326964,-.6705130326902455,-.5612813129406509,-.4551067709033134,-.35319256652135966,-.2563741554088552,-.1651412821106526,-.0796919581982668,0],[-1,-.8843387974366064,-.7678744063886243,-.6529563724510552,-.5415870994657841,-.4352842206588936,-.33504449124791424,-.24138853420685147,-.15445285440944467,-.07409659641336663,0],[-1,-.8786709358426346,-.7577735191184886,-.6399546189952064,-.527284921869926,-.4211627631006314,-.3223479611761232,-.23107655627789858,-.1472057700818259,-.07035171210706326,0],[-1,-.8740862815291583,-.7497032990976209,-.6297119746181752,-.5161838335958787,-.41036238255751956,-.31277212146489963,-.2233976621705518,-.1418697367979619,-.06762117662323441,0],[-1,-.8702632331800649,-.7430366914122081,-.6213373075161548,-.5072025698095242,-.40171437727184167,-.30517930701410456,-.21736343968190863,-.137710238299109,-.06550774483471955,0],[-1,-.8670016295947213,-.7373984232432306,-.6143173985094293,-.49973884395492807,-.394584953527678,-.2989649949848695,-.21245647317021688,-.13434688362382652,-.0638072667348083,0],[-1,-.8641642839543857,-.732534623168535,-.6083127477059322,-.4934049257184696,-.3885773075899922,-.29376029055315767,-.2083678561173622,-.13155653399373268,-.062401588652553186,0]],X=function(e){return O.fromValue_noAlloc(e)},qt=function(t,e,r){return O.fromComponents(t,e,r)},he=function(e,r,n){return O.fromComponents_noNormalize(e,r,n)},Ei=function(e,r){const n=r+1,i=Math.ceil(Math.log10(Math.abs(e))),o=Math.round(e*Math.pow(10,n-i))*Math.pow(10,i-n);return parseFloat(o.toFixed(Math.max(n-i,0)))},Bc=function(t){return Math.sign(t)*Math.log10(Math.abs(t))},rE=function(t){if(!isFinite(t))return t;if(t<-50)return t===Math.trunc(t)?Number.NEGATIVE_INFINITY:0;let e=1;for(;t<10;)e=e*t,++t;t-=1;let r=.9189385332046727;r=r+(t+.5)*Math.log(t),r=r-t;const n=t*t;let i=t;return r=r+1/(12*i),i=i*n,r=r+1/(360*i),i=i*n,r=r+1/(1260*i),i=i*n,r=r+1/(1680*i),i=i*n,r=r+1/(1188*i),i=i*n,r=r+691/(360360*i),i=i*n,r=r+7/(1092*i),i=i*n,r=r+3617/(122400*i),Math.exp(r)/e},Kb=.5671432904097838,Av=function(t,e=1e-10){let r,n;if(!Number.isFinite(t)||t===0)return t;if(t===1)return Kb;t<10?r=0:r=Math.log(t)-Math.log(Math.log(t));for(let i=0;i<100;++i){if(n=(t*Math.exp(-r)+r*r)/(r+1),Math.abs(n-r).5?1:-1;if(Math.random()*20<1)return he(e,0,1);const r=Math.floor(Math.random()*(t+1));let n=r===0?Math.random()*616-308:Math.random()*16;Math.random()>.9&&(n=Math.trunc(n));let i=Math.pow(10,n);return Math.random()>.9&&(i=Math.trunc(i)),qt(e,r,i)}static affordGeometricSeries_core(t,e,r,n){const i=e.mul(r.pow(n));return et.floor(t.div(i).mul(r.sub(1)).add(1).log10().div(r.log10()))}static sumGeometricSeries_core(t,e,r,n){return e.mul(r.pow(n)).mul(et.sub(1,r.pow(t))).div(et.sub(1,r))}static affordArithmeticSeries_core(t,e,r,n){const o=e.add(n.mul(r)).sub(r.div(2)),a=o.pow(2);return o.neg().add(a.add(r.mul(t).mul(2)).sqrt()).div(r).floor()}static sumArithmeticSeries_core(t,e,r,n){const i=e.add(n.mul(r));return t.div(2).mul(i.mul(2).plus(t.sub(1).mul(r)))}static efficiencyOfPurchase_core(t,e,r){return t.div(e).add(t.div(r))}normalize(){if(this.sign===0||this.mag===0&&this.layer===0)return this.sign=0,this.mag=0,this.layer=0,this;if(this.layer===0&&this.mag<0&&(this.mag=-this.mag,this.sign=-this.sign),this.layer===0&&this.mag=Yw)return this.layer+=1,this.mag=e*Math.log10(t),this;for(;t0;)this.layer-=1,this.layer===0?this.mag=Math.pow(10,this.mag):(this.mag=e*Math.pow(10,t),t=Math.abs(this.mag),e=Math.sign(this.mag));return this.layer===0&&(this.mag<0?(this.mag=-this.mag,this.sign=-this.sign):this.mag===0&&(this.sign=0)),this}fromComponents(t,e,r){return this.sign=t,this.layer=e,this.mag=r,this.normalize(),this}fromComponents_noNormalize(t,e,r){return this.sign=t,this.layer=e,this.mag=r,this}fromMantissaExponent(t,e){return this.layer=1,this.sign=Math.sign(t),t=Math.abs(t),this.mag=e+Math.log10(t),this.normalize(),this}fromMantissaExponent_noNormalize(t,e){return this.fromMantissaExponent(t,e),this}fromDecimal(t){return this.sign=t.sign,this.layer=t.layer,this.mag=t.mag,this}fromNumber(t){return this.mag=Math.abs(t),this.sign=Math.sign(t),this.layer=0,this.normalize(),this}fromString(t){t=t.replace(",","");const e=t.split("^^^");if(e.length===2){const h=parseFloat(e[0]),d=parseFloat(e[1]),p=e[1].split(";");let v=1;if(p.length===2&&(v=parseFloat(p[1]),isFinite(v)||(v=1)),isFinite(h)&&isFinite(d)){const m=et.pentate(h,d,v);return this.sign=m.sign,this.layer=m.layer,this.mag=m.mag,this}}const r=t.split("^^");if(r.length===2){const h=parseFloat(r[0]),d=parseFloat(r[1]),p=r[1].split(";");let v=1;if(p.length===2&&(v=parseFloat(p[1]),isFinite(v)||(v=1)),isFinite(h)&&isFinite(d)){const m=et.tetrate(h,d,v);return this.sign=m.sign,this.layer=m.layer,this.mag=m.mag,this}}const n=t.split("^");if(n.length===2){const h=parseFloat(n[0]),d=parseFloat(n[1]);if(isFinite(h)&&isFinite(d)){const p=et.pow(h,d);return this.sign=p.sign,this.layer=p.layer,this.mag=p.mag,this}}t=t.trim().toLowerCase();let i,o,a=t.split("pt");if(a.length===2){i=10,o=parseFloat(a[0]),a[1]=a[1].replace("(",""),a[1]=a[1].replace(")","");let h=parseFloat(a[1]);if(isFinite(h)||(h=1),isFinite(i)&&isFinite(o)){const d=et.tetrate(i,o,h);return this.sign=d.sign,this.layer=d.layer,this.mag=d.mag,this}}if(a=t.split("p"),a.length===2){i=10,o=parseFloat(a[0]),a[1]=a[1].replace("(",""),a[1]=a[1].replace(")","");let h=parseFloat(a[1]);if(isFinite(h)||(h=1),isFinite(i)&&isFinite(o)){const d=et.tetrate(i,o,h);return this.sign=d.sign,this.layer=d.layer,this.mag=d.mag,this}}const s=t.split("e"),l=s.length-1;if(l===0){const h=parseFloat(t);if(isFinite(h))return this.fromNumber(h)}else if(l===1){const h=parseFloat(t);if(isFinite(h)&&h!==0)return this.fromNumber(h)}const u=t.split("e^");if(u.length===2){this.sign=1,u[0].charAt(0)=="-"&&(this.sign=-1);let h="";for(let d=0;d=43&&p<=57||p===101)h+=u[1].charAt(d);else return this.layer=parseFloat(h),this.mag=parseFloat(u[1].substr(d+1)),this.normalize(),this}}if(l<1)return this.sign=0,this.layer=0,this.mag=0,this;const c=parseFloat(s[0]);if(c===0)return this.sign=0,this.layer=0,this.mag=0,this;let f=parseFloat(s[s.length-1]);if(l>=2){const h=parseFloat(s[s.length-2]);isFinite(h)&&(f*=Math.sign(h),f+=Bc(h))}if(!isFinite(c))this.sign=s[0]==="-"?-1:1,this.layer=l,this.mag=f;else if(l===1)this.sign=Math.sign(c),this.layer=1,this.mag=f+Math.log10(Math.abs(c));else if(this.sign=Math.sign(c),this.layer=l,l===2){const h=et.mul(qt(1,2,f),X(c));return this.sign=h.sign,this.layer=h.layer,this.mag=h.mag,this}else this.mag=f;return this.normalize(),this}fromValue(t){return t instanceof et||t!=null&&typeof t=="object"&&"sign"in t&&"mag"in t&&"layer"in t?this.fromDecimal(t):typeof t=="number"?this.fromNumber(t):typeof t=="string"?this.fromString(t):(this.sign=0,this.layer=0,this.mag=0,this)}toNumber(){return Number.isFinite(this.layer)?this.layer===0?this.sign*this.mag:this.layer===1?this.sign*Math.pow(10,this.mag):this.mag>0?this.sign>0?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:0:Number.NaN}mantissaWithDecimalPlaces(t){return isNaN(this.m)?Number.NaN:this.m===0?0:Ei(this.m,t)}magnitudeWithDecimalPlaces(t){return isNaN(this.mag)?Number.NaN:this.mag===0?0:Ei(this.mag,t)}toString(){return isNaN(this.layer)||isNaN(this.sign)||isNaN(this.mag)?"NaN":this.mag===Number.POSITIVE_INFINITY||this.layer===Number.POSITIVE_INFINITY?this.sign===1?"Infinity":"-Infinity":this.layer===0?this.mag<1e21&&this.mag>1e-7||this.mag===0?(this.sign*this.mag).toString():this.m+"e"+this.e:this.layer===1?this.m+"e"+this.e:this.layer<=Sv?(this.sign===-1?"-":"")+"e".repeat(this.layer)+this.mag:(this.sign===-1?"-":"")+"(e^"+this.layer+")"+this.mag}toExponential(t){return this.layer===0?(this.sign*this.mag).toExponential(t):this.toStringWithDecimalPlaces(t)}toFixed(t){return this.layer===0?(this.sign*this.mag).toFixed(t):this.toStringWithDecimalPlaces(t)}toPrecision(t){return this.e<=-7?this.toExponential(t-1):t>this.e?this.toFixed(t-this.exponent-1):this.toExponential(t-1)}valueOf(){return this.toString()}toJSON(){return this.toString()}toStringWithDecimalPlaces(t){return this.layer===0?this.mag<1e21&&this.mag>1e-7||this.mag===0?(this.sign*this.mag).toFixed(t):Ei(this.m,t)+"e"+Ei(this.e,t):this.layer===1?Ei(this.m,t)+"e"+Ei(this.e,t):this.layer<=Sv?(this.sign===-1?"-":"")+"e".repeat(this.layer)+Ei(this.mag,t):(this.sign===-1?"-":"")+"(e^"+this.layer+")"+Ei(this.mag,t)}abs(){return he(this.sign===0?0:1,this.layer,this.mag)}neg(){return he(-this.sign,this.layer,this.mag)}negate(){return this.neg()}negated(){return this.neg()}sgn(){return this.sign}round(){return this.mag<0?et.dZero:this.layer===0?qt(this.sign,0,Math.round(this.mag)):this}floor(){return this.mag<0?et.dZero:this.layer===0?qt(this.sign,0,Math.floor(this.mag)):this}ceil(){return this.mag<0?et.dZero:this.layer===0?qt(this.sign,0,Math.ceil(this.mag)):this}trunc(){return this.mag<0?et.dZero:this.layer===0?qt(this.sign,0,Math.trunc(this.mag)):this}add(t){const e=X(t);if(!Number.isFinite(this.layer))return this;if(!Number.isFinite(e.layer)||this.sign===0)return e;if(e.sign===0)return this;if(this.sign===-e.sign&&this.layer===e.layer&&this.mag===e.mag)return he(0,0,0);let r,n;if(this.layer>=2||e.layer>=2)return this.maxabs(e);if(et.cmpabs(this,e)>0?(r=this,n=e):(r=e,n=this),r.layer===0&&n.layer===0)return X(r.sign*r.mag+n.sign*n.mag);const i=r.layer*Math.sign(r.mag),o=n.layer*Math.sign(n.mag);if(i-o>=2)return r;if(i===0&&o===-1){if(Math.abs(n.mag-Math.log10(r.mag))>Mc)return r;{const a=Math.pow(10,Math.log10(r.mag)-n.mag),s=n.sign+r.sign*a;return qt(Math.sign(s),1,n.mag+Math.log10(Math.abs(s)))}}if(i===1&&o===0){if(Math.abs(r.mag-Math.log10(n.mag))>Mc)return r;{const a=Math.pow(10,r.mag-Math.log10(n.mag)),s=n.sign+r.sign*a;return qt(Math.sign(s),1,Math.log10(n.mag)+Math.log10(Math.abs(s)))}}if(Math.abs(r.mag-n.mag)>Mc)return r;{const a=Math.pow(10,r.mag-n.mag),s=n.sign+r.sign*a;return qt(Math.sign(s),1,n.mag+Math.log10(Math.abs(s)))}}plus(t){return this.add(t)}sub(t){return this.add(X(t).neg())}subtract(t){return this.sub(t)}minus(t){return this.sub(t)}mul(t){const e=X(t);if(!Number.isFinite(this.layer))return this;if(!Number.isFinite(e.layer))return e;if(this.sign===0||e.sign===0)return he(0,0,0);if(this.layer===e.layer&&this.mag===-e.mag)return he(this.sign*e.sign,0,1);let r,n;if(this.layer>e.layer||this.layer==e.layer&&Math.abs(this.mag)>Math.abs(e.mag)?(r=this,n=e):(r=e,n=this),r.layer===0&&n.layer===0)return X(r.sign*n.sign*r.mag*n.mag);if(r.layer>=3||r.layer-n.layer>=2)return qt(r.sign*n.sign,r.layer,r.mag);if(r.layer===1&&n.layer===0)return qt(r.sign*n.sign,1,r.mag+Math.log10(n.mag));if(r.layer===1&&n.layer===1)return qt(r.sign*n.sign,1,r.mag+n.mag);if(r.layer===2&&n.layer===1){const i=qt(Math.sign(r.mag),r.layer-1,Math.abs(r.mag)).add(qt(Math.sign(n.mag),n.layer-1,Math.abs(n.mag)));return qt(r.sign*n.sign,i.layer+1,i.sign*i.mag)}if(r.layer===2&&n.layer===2){const i=qt(Math.sign(r.mag),r.layer-1,Math.abs(r.mag)).add(qt(Math.sign(n.mag),n.layer-1,Math.abs(n.mag)));return qt(r.sign*n.sign,i.layer+1,i.sign*i.mag)}throw Error("Bad arguments to mul: "+this+", "+t)}multiply(t){return this.mul(t)}times(t){return this.mul(t)}div(t){const e=X(t);return this.mul(e.recip())}divide(t){return this.div(t)}divideBy(t){return this.div(t)}dividedBy(t){return this.div(t)}recip(){return this.mag===0?et.dNaN:this.layer===0?qt(this.sign,0,1/this.mag):qt(this.sign,this.layer,-this.mag)}reciprocal(){return this.recip()}reciprocate(){return this.recip()}cmp(t){const e=X(t);return this.sign>e.sign?1:this.sign0?this.layer:-this.layer,n=e.mag>0?e.layer:-e.layer;return r>n?1:re.mag?1:this.mag0?e:this}clamp(t,e){return this.max(t).min(e)}clampMin(t){return this.max(t)}clampMax(t){return this.min(t)}cmp_tolerance(t,e){const r=X(t);return this.eq_tolerance(r,e)?0:this.cmp(r)}compare_tolerance(t,e){return this.cmp_tolerance(t,e)}eq_tolerance(t,e){const r=X(t);if(e==null&&(e=1e-7),this.sign!==r.sign||Math.abs(this.layer-r.layer)>1)return!1;let n=this.mag,i=r.mag;return this.layer>r.layer&&(i=Bc(i)),this.layer0?qt(Math.sign(this.mag),this.layer-1,Math.abs(this.mag)):qt(1,0,Math.log10(this.mag))}log10(){return this.sign<=0?et.dNaN:this.layer>0?qt(Math.sign(this.mag),this.layer-1,Math.abs(this.mag)):qt(this.sign,0,Math.log10(this.mag))}log(t){return t=X(t),this.sign<=0||t.sign<=0||t.sign===1&&t.layer===0&&t.mag===1?et.dNaN:this.layer===0&&t.layer===0?qt(this.sign,0,Math.log(this.mag)/Math.log(t.mag)):et.div(this.log10(),t.log10())}log2(){return this.sign<=0?et.dNaN:this.layer===0?qt(this.sign,0,Math.log2(this.mag)):this.layer===1?qt(Math.sign(this.mag),0,Math.abs(this.mag)*3.321928094887362):this.layer===2?qt(Math.sign(this.mag),1,Math.abs(this.mag)+.5213902276543247):qt(Math.sign(this.mag),this.layer-1,Math.abs(this.mag))}ln(){return this.sign<=0?et.dNaN:this.layer===0?qt(this.sign,0,Math.log(this.mag)):this.layer===1?qt(Math.sign(this.mag),0,Math.abs(this.mag)*2.302585092994046):this.layer===2?qt(Math.sign(this.mag),1,Math.abs(this.mag)+.36221568869946325):qt(Math.sign(this.mag),this.layer-1,Math.abs(this.mag))}logarithm(t){return this.log(t)}pow(t){const e=X(t),r=this,n=e;if(r.sign===0)return n.eq(0)?he(1,0,1):r;if(r.sign===1&&r.layer===0&&r.mag===1)return r;if(n.sign===0)return he(1,0,1);if(n.sign===1&&n.layer===0&&n.mag===1)return r;const i=r.absLog10().mul(n).pow10();return this.sign===-1?Math.abs(n.toNumber()%2)%2===1?i.neg():Math.abs(n.toNumber()%2)%2===0?i:et.dNaN:i}pow10(){if(!Number.isFinite(this.layer)||!Number.isFinite(this.mag))return et.dNaN;let t=this;if(t.layer===0){const e=Math.pow(10,t.sign*t.mag);if(Number.isFinite(e)&&Math.abs(e)>=.1)return qt(1,0,e);if(t.sign===0)return et.dOne;t=he(t.sign,t.layer+1,Math.log10(t.mag))}return t.sign>0&&t.mag>=0?qt(t.sign,t.layer+1,t.mag):t.sign<0&&t.mag>=0?qt(-t.sign,t.layer+1,-t.mag):et.dOne}pow_base(t){return X(t).pow(this)}root(t){const e=X(t);return this.pow(e.recip())}factorial(){return this.mag<0?this.add(1).gamma():this.layer===0?this.add(1).gamma():this.layer===1?et.exp(et.mul(this,et.ln(this).sub(1))):et.exp(this)}gamma(){if(this.mag<0)return this.recip();if(this.layer===0){if(this.lt(he(1,0,24)))return X(rE(this.sign*this.mag));const t=this.mag-1;let e=.9189385332046727;e=e+(t+.5)*Math.log(t),e=e-t;const r=t*t;let n=t,i=12*n,o=1/i,a=e+o;if(a===e||(e=a,n=n*r,i=360*n,o=1/i,a=e-o,a===e))return et.exp(e);e=a,n=n*r,i=1260*n;let s=1/i;return e=e+s,n=n*r,i=1680*n,s=1/i,e=e-s,et.exp(e)}else return this.layer===1?et.exp(et.mul(this,et.ln(this).sub(1))):et.exp(this)}lngamma(){return this.gamma().ln()}exp(){return this.mag<0?et.dOne:this.layer===0&&this.mag<=709.7?X(Math.exp(this.sign*this.mag)):this.layer===0?qt(1,1,this.sign*Math.log10(Math.E)*this.mag):this.layer===1?qt(1,2,this.sign*(Math.log10(.4342944819032518)+this.mag)):qt(1,this.layer+1,this.sign*this.mag)}sqr(){return this.pow(2)}sqrt(){if(this.layer===0)return X(Math.sqrt(this.sign*this.mag));if(this.layer===1)return qt(1,2,Math.log10(this.mag)-.3010299956639812);{const t=et.div(he(this.sign,this.layer-1,this.mag),he(1,0,2));return t.layer+=1,t.normalize(),t}}cube(){return this.pow(3)}cbrt(){return this.pow(1/3)}tetrate(t=2,e=he(1,0,1)){if(t===1)return et.pow(this,e);if(t===0)return new et(e);if(this.eq(et.dOne))return et.dOne;if(this.eq(-1))return et.pow(this,e);if(t===Number.POSITIVE_INFINITY){const i=this.toNumber();if(i<=1.444667861009766&&i>=.06598803584531254){if(i>1.444667861009099)return new et(Math.E);const o=et.ln(this).neg();return o.lambertw().div(o)}else return i>1.444667861009766?new et(Number.POSITIVE_INFINITY):et.dNaN}if(this.eq(et.dZero)){let i=Math.abs((t+1)%2);return i>1&&(i=2-i),new et(i)}if(t<0)return et.iteratedlog(e,this,-t);e=X(e);const r=t;t=Math.trunc(t);const n=r-t;if(this.gt(et.dZero)&&this.lte(1.444667861009766)){t=Math.min(1e4,t);for(let i=0;i3)return he(e.sign,e.layer+(t-i-1),e.mag);if(i>1e4)return e}return e}iteratedexp(t=2,e=he(1,0,1)){return this.tetrate(t,e)}iteratedlog(t=10,e=1){if(e<0)return et.tetrate(t,-e,this);t=X(t);let r=X(this);const n=e;e=Math.trunc(e);const i=n-e;if(r.layer-t.layer>3){const o=Math.min(e,r.layer-t.layer-3);e-=o,r.layer-=o}for(let o=0;o1e4)return r}return i>0&&i<1&&(t.eq(10)?r=r.layeradd10(-i):r=r.layeradd(-i,t)),r}slog(t=10){if(t=X(t),t.lte(et.dZero)||t.eq(et.dOne))return et.dNaN;if(t.lt(et.dOne))return this.eq(et.dOne)?et.dZero:this.eq(et.dZero)?et.dNegOne:et.dNaN;if(this.mag<0||this.eq(et.dZero))return et.dNegOne;let e=0,r=X(this);if(r.layer-t.layer>3){const n=r.layer-t.layer-3;e+=n,r.layer-=n}for(let n=0;n<100;++n)if(r.lt(et.dZero))r=et.pow(t,r),e-=1;else{if(r.lte(et.dOne))return X(e+et.slog_critical(t.toNumber(),r.toNumber()));e+=1,r=et.log(r,t)}return X(e)}static slog_critical(t,e){return t>10?e-1:et.critical_section(t,e,eE)}static tetrate_critical(t,e){return et.critical_section(t,e,tE)}static critical_section(t,e,r){e*=10,e<0&&(e=0),e>10&&(e=10),t<2&&(t=2),t>10&&(t=10);let n=0,i=0;for(let s=0;st){const l=(t-to[s])/(to[s+1]-to[s]);n=r[s][Math.floor(e)]*(1-l)+r[s+1][Math.floor(e)]*l,i=r[s][Math.ceil(e)]*(1-l)+r[s+1][Math.ceil(e)]*l;break}const o=e-Math.floor(e);return n*(1-o)+i*o}layeradd10(t){t=et.fromValue_noAlloc(t).toNumber();const e=X(this);if(t>=1){e.mag<0&&e.layer>0?(e.sign=0,e.mag=0,e.layer=0):e.sign===-1&&e.layer==0&&(e.sign=1,e.mag=-e.mag);const r=Math.trunc(t);t-=r,e.layer+=r}if(t<=-1){const r=Math.trunc(t);if(t-=r,e.layer+=r,e.layer<0)for(let n=0;n<100;++n){if(e.layer++,e.mag=Math.log10(e.mag),!isFinite(e.mag))return e.sign===0&&(e.sign=1),e.layer<0&&(e.layer=0),e.normalize();if(e.layer>=0)break}}for(;e.layer<0;)e.layer++,e.mag=Math.log10(e.mag);return e.sign===0&&(e.sign=1,e.mag===0&&e.layer>=1&&(e.layer-=1,e.mag=1)),e.normalize(),t!==0?e.layeradd(t,10):e}layeradd(t,e){const n=this.slog(e).toNumber()+t;return n>=0?et.tetrate(e,n):Number.isFinite(n)?n>=-1?et.log(et.tetrate(e,n+1),e):et.log(et.log(et.tetrate(e,n+2),e),e):et.dNaN}lambertw(){if(this.lt(-.3678794411710499))throw Error("lambertw is unimplemented for results less than -1, sorry!");if(this.mag<0)return X(Av(this.toNumber()));if(this.layer===0)return X(Av(this.sign*this.mag));if(this.layer===1)return Ov(this);if(this.layer===2)return Ov(this);if(this.layer>=3)return he(this.sign,this.layer-1,this.mag);throw"Unhandled behavior in lambertw()"}ssqrt(){if(this.sign==1&&this.layer>=3)return he(this.sign,this.layer-1,this.mag);const t=this.ln();return t.div(t.lambertw())}pentate(t=2,e=he(1,0,1)){e=X(e);const r=t;t=Math.trunc(t);const n=r-t;n!==0&&(e.eq(et.dOne)?(++t,e=new et(n)):this.eq(10)?e=e.layeradd10(n):e=e.layeradd(n,this));for(let i=0;i10)return e}return e}sin(){return this.mag<0?this:this.layer===0?X(Math.sin(this.sign*this.mag)):he(0,0,0)}cos(){return this.mag<0?et.dOne:this.layer===0?X(Math.cos(this.sign*this.mag)):he(0,0,0)}tan(){return this.mag<0?this:this.layer===0?X(Math.tan(this.sign*this.mag)):he(0,0,0)}asin(){return this.mag<0?this:this.layer===0?X(Math.asin(this.sign*this.mag)):he(Number.NaN,Number.NaN,Number.NaN)}acos(){return this.mag<0?X(Math.acos(this.toNumber())):this.layer===0?X(Math.acos(this.sign*this.mag)):he(Number.NaN,Number.NaN,Number.NaN)}atan(){return this.mag<0?this:this.layer===0?X(Math.atan(this.sign*this.mag)):X(Math.atan(this.sign*(1/0)))}sinh(){return this.exp().sub(this.negate().exp()).div(2)}cosh(){return this.exp().add(this.negate().exp()).div(2)}tanh(){return this.sinh().div(this.cosh())}asinh(){return et.ln(this.add(this.sqr().add(1).sqrt()))}acosh(){return et.ln(this.add(this.sqr().sub(1).sqrt()))}atanh(){return this.abs().gte(1)?he(Number.NaN,Number.NaN,Number.NaN):et.ln(this.add(1).div(X(1).sub(this))).div(2)}ascensionPenalty(t){return t===0?this:this.root(et.pow(10,t))}egg(){return this.add(9)}lessThanOrEqualTo(t){return this.cmp(t)<1}lessThan(t){return this.cmp(t)<0}greaterThanOrEqualTo(t){return this.cmp(t)>-1}greaterThan(t){return this.cmp(t)>0}};let O=et;O.dZero=he(0,0,0);O.dOne=he(1,0,1);O.dNegOne=he(-1,0,1);O.dTwo=he(1,0,2);O.dTen=he(1,0,10);O.dNaN=he(Number.NaN,Number.NaN,Number.NaN);O.dInf=he(1,Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY);O.dNegInf=he(-1,Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY);O.dNumberMax=qt(1,0,Number.MAX_VALUE);O.dNumberMin=qt(1,0,Number.MIN_VALUE);const nE=new O(1);function es(t,e,r=!0){let n=O.log10(t).floor(),i=O.div(t,O.pow(10,n));i.toStringWithDecimalPlaces(e)==="10"&&(i=nE,n=n.add(1));const o=n.gte(1e9)?rn(n,Math.max(Math.max(e,3),Ie.defaultDecimalsShown)):n.gte(1e4)?Au(n,0):n.toStringWithDecimalPlaces(0);return r?i.toStringWithDecimalPlaces(e)+"e"+o:"e"+o}function Au(t,e){if(t==null)return"NaN";if(t=new O(t),t.mag<.001)return 0 .toFixed(e);const n=t.toStringWithDecimalPlaces(e).split(".");return n[0]=n[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1,"),n.length==1?n[0]:n[0]+"."+n[1]}function Zb(t,e){return t==null?"NaN":(t=new O(t),t.mag<1e-4?0 .toFixed(e):(t.mag<.1&&e!==0&&(e=Math.max(Math.max(e,t.log10().negate().ceil().toNumber()),Ie.defaultDecimalsShown)),t.toStringWithDecimalPlaces(e)))}const iE=new O("eeee1000"),oE=new O("e100000"),Uv=new O("e1000"),qb=new O(1e9),aE=new O(1e6),sE=new O(1e3),lE=new O(.98),uE=new O(.001),Jb=new O(0);function rn(t,e,r){if(e==null&&(e=Ie.defaultDecimalsShown),r=r!=null?r:Ie.defaultShowSmall,t=new O(t),isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag))return"NaN";if(t.sign<0)return"-"+rn(t.neg(),e);if(t.mag===Number.POSITIVE_INFINITY)return"Infinity";if(t.gte(iE)){const n=t.slog();return n.gte(aE)?"F"+rn(n.floor()):O.pow(10,n.sub(n.floor())).toStringWithDecimalPlaces(3)+"F"+Au(n.floor(),0)}else{if(t.gte(oE))return es(t,0,!1);if(t.gte(Uv))return es(t,0);if(t.gte(qb))return es(t,e);if(t.gte(sE))return Au(t,0);if(t.gte(uE)||!r)return Zb(t,e);if(t.eq(Jb))return 0 .toFixed(e)}return t=t_(t),t.lt(Uv)?es(t,e).replace(/([^(?:e|F)]*)$/,"-$1"):rn(t,e)+"\u207B\xB9"}function tn(t){return t=new O(t),t.sign<0?"-"+tn(t.neg()):t.gte(qb)||t.lte(lE)&&!t.eq(Jb)?rn(t):rn(t,0)}function Qb(t){return O.lt(t,0)?"-"+Qb(O.neg(t)):O.gt(t,2**51)?rn(O.div(t,31536e3))+"y":(t=new O(t).toNumber(),t<60?rn(t)+"s":t<3600?tn(Math.floor(t/60))+"m "+rn(t%60)+"s":t<86400?tn(Math.floor(t/3600))+"h "+tn(Math.floor(t/60)%60)+"m "+tn(t%60)+"s":t<31536e3?tn(Math.floor(t/84600)%365)+"d "+tn(Math.floor(t/3600)%24)+"h "+tn(Math.floor(t/60)%60)+"m":tn(Math.floor(t/31536e3))+"y "+tn(Math.floor(t/84600)%365)+"d "+tn(Math.floor(t/3600)%24)+"h")}function cE(t,e,r){t=new O(t);let n=t.toStringWithDecimalPlaces(e);return new O(n).gte(r)&&(n=O.sub(r,Math.pow(.1,e)).toStringWithDecimalPlaces(e)),n}function fE(t,e){return rn(t,e,!0)}function t_(t){let e=O.log10(t).ceil();const r=O.div(t,O.pow(10,e));return e=e.neg(),t=new O(10).pow(e).times(r),t}var hE=Object.freeze(Object.defineProperty({__proto__:null,default:O,exponentialFormat:es,commaFormat:Au,regularFormat:Zb,format:rn,formatWhole:tn,formatTime:Qb,toPlaces:cE,formatSmall:fE,invertOOM:t_},Symbol.toStringTag,{value:"Module"}));const{exponentialFormat:dE,commaFormat:pE,regularFormat:vE,format:je,formatWhole:Cr,formatTime:pc,toPlaces:mE,formatSmall:gE,invertOOM:yE}=hE;window.Decimal=O;window.exponentialFormat=dE;window.commaFormat=pE;window.regularFormat=vE;window.format=je;window.formatWhole=Cr;window.formatTime=pc;window.toPlaces=mE;window.formatSmall=gE;window.invertOOM=yE;function e_(t){let e=t.replace(/([A-Z])/g," $1");return e=e.charAt(0).toUpperCase()+e.slice(1),e}function na(t){return typeof t=="function"}var Ne=(t=>(t.Up="Up",t.Down="Down",t.Left="Left",t.Right="Right",t.Default="Up",t))(Ne||{});const vc=Symbol("DoNotCache");function J(t,e){const r=t[e];na(r)&&r.length===0&&!r[vc]&&(t[e]=tt(r.bind(t)))}function nn(t){return na(t)&&!t[vc]&&(t=tt(t)),t}const ir=Symbol("Component"),fr=Symbol("GatherProps");let bE=0;function Sr(t="feature-"){return t+bE++}var ae=(t=>(t[t.Visible=0]="Visible",t[t.Hidden=1]="Hidden",t[t.None=2]="None",t))(ae||{});function le(t){return t[vc]=!0,t}function Ga(t,e=2){return t?0:e}function ve(t,e,r){t[e]===void 0&&r!=null&&(t[e]=r)}function r_(t,...e){const r=[],n=i=>{Object.keys(i).forEach(o=>{const a=i[o];a&&typeof a=="object"&&(e.includes(a.type)?r.push(a):!(a instanceof O)&&!oe(a)&&n(a))})};return n(t),r}const eo={variables:{"--foreground":"#dfdfdf","--background":"#0f0f0f","--feature-foreground":"#0f0f0f","--tooltip-background":"rgba(0, 0, 0, 0.75)","--raised-background":"#0f0f0f","--points":"#ffffff","--locked":"#bf8f8f","--highlighted":"#333","--bought":"#77bf5f","--danger":"rgb(220, 53, 69)","--link":"#02f2f2","--outline":"#dfdfdf","--accent1":"#627a82","--accent2":"#658262","--accent3":"#7c6282","--border-radius":"15px","--modal-border":"solid 2px var(--color)","--feature-margin":"0px"},floatingTabs:!0,mergeAdjacent:!0,showPin:!0};var Kd=(t=>(t.Classic="classic",t.Paper="paper",t.Nordic="nordic",t.Aqua="aqua",t))(Kd||{}),gi={classic:eo,paper:{...eo,variables:{...eo.variables,"--background":"#2a323d","--feature-foreground":"#000","--raised-background":"#333c4a","--locked":"#3a3e45","--bought":"#5C8A58","--outline":"#333c4a","--border-radius":"4px","--modal-border":"","--feature-margin":"5px"},floatingTabs:!1},nordic:{...eo,variables:{...eo.variables,"--foreground":"#D8DEE9","--background":"#2E3440","--feature-foreground":"#000","--raised-background":"#3B4252","--points":"#E5E9F0","--locked":"#4c566a","--highlighted":"#434c5e","--bought":"#8FBCBB","--danger":"#D08770","--link":"#88C0D0","--outline":"#3B4252","--accent1":"#B48EAD","--accent2":"#A3BE8C","--accent3":"#EBCB8B","--border-radius":"4px","--modal-border":"solid 2px #3B4252","--feature-margin":"5px"},floatingTabs:!1},aqua:{...eo,variables:{...eo.variables,"--foreground":"#bfdfff","--background":"#001f3f","--tooltip-background":"rgba(0, 15, 31, 0.75)","--raised-background":"#001f3f","--points":"#dfefff","--locked":"#c4a7b3","--outline":"#bfdfff"}}};/*! + * is-plain-object + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */function Fv(t){return Object.prototype.toString.call(t)==="[object Object]"}function _E(t){var e,r;return Fv(t)===!1?!1:(e=t.constructor,e===void 0?!0:(r=e.prototype,!(Fv(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}const lr=Symbol("ProxyState"),Qo=Symbol("ProxyPath");function pr(t,e={}){const r=e;let n=!1;function i(){return n||(Object.assign(r,t(r)),n=!0),r}return new Proxy(r,{get(o,a){return a===lr?i():i()[a]},set(o,a,s){return i()[a]=s,!0},has(o,a){return a===lr?!0:Reflect.has(i(),a)},ownKeys(){return Reflect.ownKeys(i())},getOwnPropertyDescriptor(o,a){return n||(Object.assign(r,t(r)),n=!0),Object.getOwnPropertyDescriptor(o,a)}})}var Le=window.state=Sa({lastTenTicks:[],hasNaN:!1,NaNPath:[]});const n_=zn({id:"",devSpeed:null,name:"",tabs:[],time:-1,autosave:!0,offlineProd:!0,offlineTime:null,timePlayed:0,keepGoing:!1,modID:"",modVersion:"",layers:{}});function i_(t){return JSON.stringify(t,(e,r)=>E(r))}const o_={get(t,e){var n;if(e===lr||e===Qo)return t[e];const r=t[lr][e];if(e!=="value"&&(_E(r)||Array.isArray(r))){if(r!==((n=t[e])==null?void 0:n[lr])){const i=[...t[Qo],e];t[e]=new Proxy({[lr]:r,[Qo]:i},o_)}return t[e]}return r},set(t,e,r,n){if(!Le.hasNaN&&(typeof r=="number"&&isNaN(r)||r instanceof O&&(isNaN(r.sign)||isNaN(r.layer)||isNaN(r.mag)))){const i=t[lr][e];if(!(typeof i=="number"&&isNaN(i)||i instanceof O&&(isNaN(i.sign)||isNaN(i.layer)||isNaN(i.mag))))throw n_.autosave=!1,Le.hasNaN=!0,Le.NaNPath=[...t[Qo],e],Le.NaNReceiver=n,console.error("Attempted to set NaN value",[...t[Qo],e],t[lr]),"Attempted to set NaN value. See above for details"}return t[lr][e]=r,!0},ownKeys(t){return Reflect.ownKeys(t[lr])},has(t,e){return Reflect.has(t[lr],e)},getOwnPropertyDescriptor(t,e){return Object.getOwnPropertyDescriptor(t[lr],e)}};var wt=window.player=new Proxy({[lr]:n_,[Qo]:["player"]},o_);let a_=()=>({events:{},emit(t,...e){(this.events[t]||[]).forEach(r=>r(...e))},on(t,e){return(this.events[t]=this.events[t]||[]).push(e),()=>this.events[t]=(this.events[t]||[]).filter(r=>r!==e)}});const vr=a_();let ta=null,ps=null;function Ou(){const t=Date.now();let e=(t-wt.time)/1e3;wt.time=t;const r=e;if(Le.lastTenTicks.push(r),Le.lastTenTicks.length>10&&(Le.lastTenTicks=Le.lastTenTicks.slice(1)),!((ps==null?void 0:ps.value)&&!wt.keepGoing)&&!Le.hasNaN&&(e=Math.max(e,0),wt.devSpeed!==0)){if(wt.offlineTime!=null){if(O.gt(wt.offlineTime,Ie.offlineLimit*3600)&&(wt.offlineTime=Ie.offlineLimit*3600),O.gt(wt.offlineTime,0)&&wt.devSpeed!==0){const n=Math.max(wt.offlineTime/10,e);wt.offlineTime=wt.offlineTime-n,e+=n}else wt.devSpeed===0&&(wt.offlineTime+=e);(!wt.offlineProd||O.lt(wt.offlineTime,0))&&(wt.offlineTime=null)}e=Math.min(e,Ie.maxTickLength),wt.devSpeed!=null&&(e*=wt.devSpeed),Number.isFinite(e)||(e=1e308),!O.eq(e,0)&&(wt.timePlayed+=e,Number.isFinite(wt.timePlayed)||(wt.timePlayed=1e308),vr.emit("update",e,r),Pe.unthrottled?(requestAnimationFrame(Ou),ta!=null&&(clearInterval(ta),ta=null)):ta==null&&(ta=setInterval(Ou,50)))}}async function xE(){ps=(await xu(()=>Promise.resolve().then(function(){return vx}),void 0)).hasWon,ze(ps,t=>{t&&vr.emit("gameWon")}),Pe.unthrottled?requestAnimationFrame(Ou):ta=setInterval(Ou,50)}var TE=Object.freeze(Object.defineProperty({__proto__:null,globalBus:vr,startGameLoop:xE},Symbol.toStringTag,{value:"Module"})),cu=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function wE(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function s_(t){if(t.__esModule)return t;var e=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(t).forEach(function(r){var n=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,n.get?n:{enumerable:!0,get:function(){return t[r]}})}),e}var l_={exports:{}};(function(t){var e=function(){var r=String.fromCharCode,n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",o={};function a(l,u){if(!o[l]){o[l]={};for(var c=0;c>>8,c[f*2+1]=d%256}return c},decompressFromUint8Array:function(l){if(l==null)return s.decompress(l);for(var u=new Array(l.length/2),c=0,f=u.length;c>1}else{for(h=1,f=0;f>1}g--,g==0&&(g=Math.pow(2,T),T++),delete p[y]}else for(h=d[y],f=0;f>1;g--,g==0&&(g=Math.pow(2,T),T++),d[m]=b++,y=String(v)}if(y!==""){if(Object.prototype.hasOwnProperty.call(p,y)){if(y.charCodeAt(0)<256){for(f=0;f>1}else{for(h=1,f=0;f>1}g--,g==0&&(g=Math.pow(2,T),T++),delete p[y]}else for(h=d[y],f=0;f>1;g--,g==0&&(g=Math.pow(2,T),T++)}for(h=2,f=0;f>1;for(;;)if(x=x<<1,R==u-1){w.push(c(x));break}else R++;return w.join("")},decompress:function(l){return l==null?"":l==""?null:s._decompress(l.length,32768,function(u){return l.charCodeAt(u)})},_decompress:function(l,u,c){var f=[],h=4,d=4,p=3,v="",m=[],y,g,b,T,w,x,R,I={val:c(0),position:u,index:1};for(y=0;y<3;y+=1)f[y]=y;for(b=0,w=Math.pow(2,2),x=1;x!=w;)T=I.val&I.position,I.position>>=1,I.position==0&&(I.position=u,I.val=c(I.index++)),b|=(T>0?1:0)*x,x<<=1;switch(b){case 0:for(b=0,w=Math.pow(2,8),x=1;x!=w;)T=I.val&I.position,I.position>>=1,I.position==0&&(I.position=u,I.val=c(I.index++)),b|=(T>0?1:0)*x,x<<=1;R=r(b);break;case 1:for(b=0,w=Math.pow(2,16),x=1;x!=w;)T=I.val&I.position,I.position>>=1,I.position==0&&(I.position=u,I.val=c(I.index++)),b|=(T>0?1:0)*x,x<<=1;R=r(b);break;case 2:return""}for(f[3]=R,g=R,m.push(R);;){if(I.index>l)return"";for(b=0,w=Math.pow(2,p),x=1;x!=w;)T=I.val&I.position,I.position>>=1,I.position==0&&(I.position=u,I.val=c(I.index++)),b|=(T>0?1:0)*x,x<<=1;switch(R=b){case 0:for(b=0,w=Math.pow(2,8),x=1;x!=w;)T=I.val&I.position,I.position>>=1,I.position==0&&(I.position=u,I.val=c(I.index++)),b|=(T>0?1:0)*x,x<<=1;f[d++]=r(b),R=d-1,h--;break;case 1:for(b=0,w=Math.pow(2,16),x=1;x!=w;)T=I.val&I.position,I.position>>=1,I.position==0&&(I.position=u,I.val=c(I.index++)),b|=(T>0?1:0)*x,x<<=1;f[d++]=r(b),R=d-1,h--;break;case 2:return m.join("")}if(h==0&&(h=Math.pow(2,p),p++),f[R])v=f[R];else if(R===d)v=g+g.charAt(0);else return null;m.push(v),f[d++]=g+v.charAt(0),h--,g=v,h==0&&(h=Math.pow(2,p),p++)}}};return s}();t!=null&&(t.exports=e)})(l_);var Oi=l_.exports;function u_(t={}){return Object.assign({id:`${Ie.id}-0`,name:"Default Save",tabs:Ie.initialTabs.slice(),time:Date.now(),autosave:!0,offlineProd:!0,offlineTime:0,timePlayed:0,keepGoing:!1,modID:Ie.id,modVersion:Ie.versionNumber,layers:{}},t)}function pn(t){const e=Oi.compressToUTF16(i_(t!=null?t:wt[lr]));return localStorage.setItem((t!=null?t:wt[lr]).id,e),e}async function EE(){CE();try{let t=localStorage.getItem(Pe.active);if(t==null){await To(va());return}if(t[0]!=="{")if(t[0]==="e")t=decodeURIComponent(escape(atob(t)));else if(t[0]==="\u1BE1")t=Oi.decompressFromUTF16(t);else throw"Unable to determine save encoding";const e=JSON.parse(t);if(e.modID!==Ie.id){await To(va());return}e.id=Pe.active,await To(e)}catch(t){console.error(`Failed to load save. Falling back to new save. +`,t),await To(va())}}function va(){const t=fu(),e=u_({id:t});return pn(e),Pe.saves.push(t),e}function fu(){let t,e=0;do t=`${Ie.id}-${e++}`;while(localStorage.getItem(t));return t}async function To(t){console.info("Loading save",t);const{layers:e,removeLayer:r,addLayer:n}=await xu(()=>Promise.resolve().then(function(){return zE}),void 0),{fixOldSave:i,getInitialLayers:o}=await xu(()=>Promise.resolve().then(function(){return vx}),void 0);for(const a in e){const s=e[a];s&&r(s)}o(t).forEach(a=>n(a,t)),t=u_(t),t.offlineProd&&t.time&&(t.offlineTime==null&&(t.offlineTime=0),t.offlineTime+=(Date.now()-t.time)/1e3),t.time=Date.now(),t.modVersion!==Ie.versionNumber&&i(t.modVersion,t),Object.assign(wt,t),Pe.active=wt.id}setInterval(()=>{wt.autosave&&pn()},1e3);window.onbeforeunload=()=>{wt.autosave&&pn()};window.save=pn;const IE=window.hardReset=async()=>{await To(va())},Ps=zn({active:"",saves:[],showTPS:!0,theme:Kd.Nordic,unthrottled:!1});ze(Ps,t=>{const e=Oi.compressToUTF16(JSON.stringify(t));localStorage.setItem(Ie.id,e)},{deep:!0});var Pe=window.settings=Ps;function CE(){try{let t=localStorage.getItem(Ie.id);if(t!=null&&t!==""){if(t[0]!=="{")if(t[0]==="e")t=decodeURIComponent(escape(atob(t)));else if(t[0]==="\u1BE1")t=Oi.decompressFromUTF16(t);else{console.warn("Unable to determine settings encoding",t);return}const e=JSON.parse(t);typeof e=="object"&&Object.assign(Ps,e)}vr.emit("loadSettings",Ps)}catch{}}window.hardResetSettings=()=>{const t={active:"",saves:[],showTPS:!0,theme:Kd.Nordic};vr.emit("loadSettings",t),Object.assign(Ps,t),IE()};const c_=zn([]);function f_(t){c_.push(t)}const h_=zn([]);function RE(t){h_.push(t)}const NE=zn([]),PE={class:"table"},hu=Pt({__name:"Column",setup(t){const e=tt(()=>gi[Pe.theme].mergeAdjacent);return(r,n)=>(B(),Q("div",PE,[U("div",{class:Qt(["col",{mergeAdjacent:E(e)}])},[He(r.$slots,"default")],2)]))}}),SE={class:"table"},vs=Pt({__name:"Row",setup(t){const e=tt(()=>gi[Pe.theme].mergeAdjacent);return(r,n)=>(B(),Q("div",SE,[U("div",{class:Qt(["row",{mergeAdjacent:E(e)}])},[He(r.$slots,"default")],2)]))}});function d_(t){return typeof t=="function"||Object.prototype.toString.call(t)==="[object Object]"&&!wn(t)}function te(t,e="span"){return typeof t=="function"?Pt({render:t}):typeof t=="string"?t.length>0?(t=t.trim(),t.charAt(0)!=="<"&&(t=`<${e}>${t}`),Pt({template:t})):Pt({render:()=>({})}):t}function Ge(t){if(on(t))return typeof t=="function"?t():te(t);const e=t[ir];return P(e,t[fr](),null)}function hn(...t){let e;return P(vs,null,d_(e=t.map(Ge))?e:{default:()=>[e]})}function AE(...t){let e;return P(hu,null,d_(e=t.map(Ge))?e:{default:()=>[e]})}function oi(t){if(on(t))return typeof t=="function"?t():typeof t=="string"?P(Ot,null,[t]):P(t,null,null);const e=t[ir];return P(e,t[fr](),null)}function on(t){return typeof t=="string"?!0:typeof t=="object"?t==null?!1:"render"in t||"component"in t:typeof t=="function"&&t[vc]===!0}function Zd(t,e){const r=It(null),n=It(void 0);function i(s){r.value||(r.value=setInterval(a,250)),n.value=s}function o(){r.value&&(clearInterval(r.value),r.value=null)}function a(){e&&e.value?e.value():t&&t.value&&t.value(n.value)}return Aa(o),{start:i,stop:o,handleHolding:a}}function Ca(t,e="div"){const r=Gr();return Xe(()=>{r.value=te(Be(t),e)}),r}function ko(t,e="div"){const r=Gr(null);return Xe(()=>{const n=Be(t);r.value=n==null?null:te(n,e)}),r}function OE(t){return tt(()=>Be(t))}function Be(t){return E(E(t))}function nt(...t){return t.includes(Object)||t.push(Object),t}var ne=(t,e)=>{const r=t.__vccOpts||t;for(const[n,i]of e)r[n]=i;return r};const UE=Pt({__name:"Context",emits:["updateNodes"],setup(t,{emit:e}){var c;const r=It({}),n=new ResizeObserver(s),i=It(null);Wn(()=>{const f=i.value;f!=null&&n.observe(f)});let o=!0,a=It((c=i.value)==null?void 0:c.getBoundingClientRect());function s(){i.value!=null&&o&&(o=!1,cr(()=>{var f;a.value=(f=i.value)==null?void 0:f.getBoundingClientRect(),Object.values(r.value).filter(h=>h).forEach(h=>h.rect=h.element.getBoundingClientRect()),e("updateNodes",r.value),o=!0}))}document.fonts.ready.then(s);const l={attributes:!1,childList:!0,subtree:!1};_o(qd,(f,h)=>{const d=new MutationObserver(()=>u(f));d.observe(h,l),r.value[f]={element:h,observer:d,rect:h.getBoundingClientRect()},e("updateNodes",r.value),cr(()=>u(f))}),_o(Jd,f=>{var h;(h=r.value[f])==null||h.observer.disconnect(),r.value[f]=void 0,e("updateNodes",r.value)}),_o(Qd,r),_o(tp,a);function u(f){const h=r.value[f];h!=null&&(h.rect=h.element.getBoundingClientRect(),e("updateNodes",r.value))}return(f,h)=>(B(),Q(Ot,null,[He(f.$slots,"default",{},void 0,!0),U("div",{ref_key:"resizeListener",ref:i,class:"resize-listener"},null,512)],64))}});var p_=ne(UE,[["__scopeId","data-v-6a08ac80"]]);const FE=["onPointerdown"],LE={class:"modal-wrapper"},ME={class:"modal-container"},BE={class:"modal-header"},kE=dt(" default header "),GE={class:"modal-body"},DE=dt(" default body "),HE={class:"modal-footer"},VE=U("div",{class:"modal-default-flex-grow"},null,-1),Ki=Pt({__name:"Modal",props:{modelValue:{type:Boolean}},emits:["update:modelValue"],setup(t,{expose:e,emit:r}){const i=Ae(t),o=tt(()=>i.modelValue||s.value);function a(){r("update:modelValue",!1)}const s=It(!1),l=It(null),u=tt(()=>{var c,f;return(f=(c=l.value)==null?void 0:c.nodes)!=null?f:null});return e({isOpen:o,nodes:u}),(c,f)=>(B(),Rt(vb,{to:"#modal-root"},[P(Yi,{name:"modal",onBeforeEnter:f[0]||(f[0]=h=>s.value=!0),onAfterLeave:f[1]||(f[1]=h=>s.value=!1)},{default:Bt(()=>[Oa(U("div",yr({class:"modal-mask",onPointerdown:mr(a,["self"])},c.$attrs),[U("div",LE,[U("div",ME,[U("div",BE,[He(c.$slots,"header",{shown:E(o)},()=>[kE])]),U("div",GE,[P(p_,{ref_key:"contextRef",ref:l},{default:Bt(()=>[He(c.$slots,"body",{shown:E(o)},()=>[DE])]),_:3},512)]),U("div",HE,[He(c.$slots,"footer",{shown:E(o)},()=>[U("div",{class:"modal-default-footer"},[VE,U("button",{class:"button modal-default-button",onClick:a}," Close ")])])])])])],16,FE),[[dc,t.modelValue]])]),_:3})]))}}),Ss=Symbol("PersistentState"),As=Symbol("DefaultValue"),Uu=Symbol("StackTrace"),v_=Symbol("Deleted");function $E(){var t;return((t=new Error().stack)==null?void 0:t.split(` +`).slice(3,5).map(e=>e.trim()).join(` +`))||""}function nr(t){const e=oe(t)?t:It(t);return e[Ss]=e,e[As]=oe(t)?t.value:t,e[Uu]=$E(),e[v_]=!1,vn.length===0?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",e,` +Created at: +`+e[Uu]):ma[vn[vn.length-1]].add(e),e}vr.on("addLayer",(t,e)=>{const r=[],n=(i,o=[])=>{let a=!1;return Object.keys(i).forEach(s=>{const l=i[s];if(l&&typeof l=="object")if(Ss in l){if(a=!0,l[v_]){console.warn("Deleted persistent ref present in returned object. Ignoring...",l,` +Created at: +`+l[Uu]);return}ma[t.id].delete(lr in l?l[lr]:l);const u=o.reduce((f,h)=>(h in f||(f[h]={}),f[h]),e),c=u[s];u[s]=l[Ss],ki(u)?c!=null?u[s]=c:u[s]=l[As]:c!=null?u[s].value=c:u[s].value=l[As]}else!(l instanceof O)&&!oe(l)&&!r.includes(l)&&(typeof l.type=="symbol"&&r.push(l),n(l,[...o,s])&&(Ct(l)&&!Ct(i)?console.warn("Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.",lr in i?i[lr]:i,s):a=!0))}),a};n(t),ma[t.id].forEach(i=>{console.error(`Created persistent ref in ${t.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,i,` +Created at: +`+i[Uu])}),ma[t.id].clear()});const qd=Symbol("RegisterNode"),Jd=Symbol("UnregisterNode"),Qd=Symbol("Nodes"),tp=Symbol("Bounds"),kr=Sa({});window.layers=kr;const ma={},vn=[];function ol(t,e){return pr(()=>{const r={},n=r.emitter=a_();if(r.on=n.on.bind(n),r.emit=n.emit.bind(n),r.nodes=It({}),r.id=t,vn.push(t),ma[t]=new Set,r.minimized=nr(!1),Object.assign(r,e.call(r)),vn[vn.length-1]==null||vn[vn.length-1]!==t)throw`Adding layers stack in invalid state. This should not happen +Stack: ${vn} +Trying to pop ${r.id}`;return vn.pop(),J(r,"color"),J(r,"display"),J(r,"name"),ve(r,"name",r.id),J(r,"minWidth"),ve(r,"minWidth",600),J(r,"minimizable"),ve(r,"minimizable",!0),r})}function m_(t,e){if(console.info("Adding layer",t.id),kr[t.id]){console.error("Attempted to add layer with same ID as existing layer",t.id,kr[t.id]);return}ve(e,"layers",{}),e.layers[t.id]==null&&(e.layers[t.id]={}),kr[t.id]=t,vr.emit("addLayer",t,e.layers[t.id])}function jE(t){return kr[t]}function g_(t){console.info("Removing layer",t.id),vr.emit("removeLayer",t),kr[t.id]=void 0}function XE(t){g_(t),m_(t,wt)}function y_(t){const e=It(!1);return{openModal:()=>e.value=!0,modal:le(()=>P(Ki,{modelValue:e.value,"onUpdate:modelValue":r=>e.value=r},{header:()=>P("h2",null,[E(t.name)]),body:E(t.display)}))}}vr.on("update",function(e){Object.values(kr).forEach(r=>{r==null||r.emit("preUpdate",e)}),Object.values(kr).forEach(r=>{r==null||r.emit("update",e)}),Object.values(kr).forEach(r=>{r==null||r.emit("postUpdate",e)})});var zE=Object.freeze(Object.defineProperty({__proto__:null,RegisterNodeInjectionKey:qd,UnregisterNodeInjectionKey:Jd,NodesInjectionKey:Qd,BoundsInjectionKey:tp,layers:kr,persistentRefs:ma,addingLayers:vn,createLayer:ol,addLayer:m_,getLayer:jE,removeLayer:g_,reloadLayer:XE,setupLayerModal:y_},Symbol.toStringTag,{value:"Module"}));const WE=Pt({components:{Context:p_},props:{index:{type:Number,required:!0},tab:{type:Function,required:!0},display:{type:nt(Object,String,Function),required:!0},minimized:{type:Object,required:!0},minWidth:{type:nt(Number,String),required:!0},name:{type:nt(String),required:!0},color:nt(String),minimizable:nt(Boolean),nodes:{type:Object,required:!0}},setup(t){const{display:e,index:r,minimized:n,minWidth:i,tab:o}=Ae(t),a=Ca(e),s=tt(()=>Ie.allowGoBack&&r.value>0&&!n.value);function l(){wt.tabs.splice(E(t.index),1/0)}cr(()=>c(n.value,E(i.value))),ze([n,OE(i)],([f,h])=>c(f,h));function u(f){t.nodes.value=f}function c(f,h){const d=typeof h=="number"||Number.isNaN(parseInt(h))?h+"px":h,p=o.value();p!=null&&(f?(p.style.flexGrow="0",p.style.flexShrink="0",p.style.width="60px",p.style.minWidth=p.style.flexBasis="",p.style.margin="0"):(p.style.flexGrow="",p.style.flexShrink="",p.style.width="",p.style.minWidth=p.style.flexBasis=d,p.style.margin=""))}return{component:a,showGoBack:s,updateNodes:u,unref:E,goBack:l}}});function YE(t,e,r,n,i,o){const a=Re("Context");return B(),Q("div",{class:"layer-container",style:ce({"--layer-color":t.unref(t.color)})},[t.showGoBack?(B(),Q("button",{key:0,class:"goBack",onClick:e[0]||(e[0]=(...s)=>t.goBack&&t.goBack(...s))},"\u2190")):yt("",!0),t.minimized.value?(B(),Q("button",{key:1,class:"layer-tab minimized",onClick:e[1]||(e[1]=s=>t.minimized.value=!1)},[U("div",null,re(t.unref(t.name)),1)])):(B(),Q("div",{key:2,class:Qt(["layer-tab",{showGoBack:t.showGoBack}])},[P(a,{onUpdateNodes:t.updateNodes},{default:Bt(()=>[(B(),Rt(Te(t.component)))]),_:1},8,["onUpdateNodes"])],2)),t.unref(t.minimizable)?(B(),Q("button",{key:3,class:"minimize",onClick:e[2]||(e[2]=s=>t.minimized.value=!0)}," \u25BC ")):yt("",!0)],4)}var KE=ne(WE,[["render",YE],["__scopeId","data-v-34c9d881"]]);const b_=t=>(Cn("data-v-4b4bda40"),t=t(),Rn(),t),ZE=b_(()=>U("h2",null,"Changelog",-1)),qE=b_(()=>U("details",{open:""},[U("summary",null,[dt("v0.0 Initial Commit - "),U("time",null,"2021-09-04")]),dt(" This is the first release :D "),U("ul",null,[U("li",{class:"feature"},"Did everything"),U("li",{class:"fix"},"Had some fun"),U("li",{class:"breaking"},"Removed everything"),U("li",{class:"balancing"},"Created some bugs to fix later")])],-1)),JE=Pt({__name:"Changelog",setup(t,{expose:e}){const r=It(!1);return e({open(){r.value=!0}}),(n,i)=>(B(),Rt(Ki,{modelValue:r.value,"onUpdate:modelValue":i[0]||(i[0]=o=>r.value=o)},{header:Bt(()=>[ZE]),body:Bt(()=>[qE]),_:1},8,["modelValue"]))}});var QE=ne(JE,[["__scopeId","data-v-4b4bda40"]]);const tI=Pt({props:{element:nt(Object),display:{type:nt(Object,String,Function),required:!0},style:nt(Object,String,Array),classes:nt(Object),direction:nt(String),xoffset:nt(String),yoffset:nt(String),pinned:Object},setup(t){const{element:e,display:r,pinned:n}=Ae(t),i=It(!1),o=tt(()=>(Be(n)||i.value)&&a.value),a=ko(r),s=Gr(null);Xe(()=>{const c=Be(e);s.value=c==null?null:te(le(()=>Ge(c)))});function l(c){const f=n;c.shiftKey&&f&&(f.value=!f.value,c.stopPropagation(),c.preventDefault())}const u=tt(()=>Be(n)&&gi[Pe.theme].showPin);return{Direction:Ne,isHovered:i,isShown:o,comp:a,elementComp:s,unref:E,togglePinned:l,showPin:u}}}),eI={key:0,class:"material-icons pinned"};function rI(t,e,r,n,i,o){return B(),Q("div",{class:Qt(["tooltip-container",{shown:t.isShown}]),onMouseenter:e[0]||(e[0]=a=>t.isHovered=!0),onMouseleave:e[1]||(e[1]=a=>t.isHovered=!1),onClickCapture:e[2]||(e[2]=(...a)=>t.togglePinned&&t.togglePinned(...a))},[He(t.$slots,"default",{},void 0,!0),t.elementComp?(B(),Rt(Te(t.elementComp),{key:0})):yt("",!0),P(Yi,{name:"fade"},{default:Bt(()=>{var a;return[t.isShown?(B(),Q("div",{key:0,class:Qt(["tooltip",{top:t.unref(t.direction)===t.Direction.Up,left:t.unref(t.direction)===t.Direction.Left,right:t.unref(t.direction)===t.Direction.Right,bottom:t.unref(t.direction)===t.Direction.Down,...t.unref(t.classes)}]),style:ce([{"--xoffset":t.unref(t.xoffset)||"0px","--yoffset":t.unref(t.yoffset)||"0px"},(a=t.unref(t.style))!=null?a:{}])},[t.showPin?(B(),Q("span",eI,"push_pin")):yt("",!0),t.comp?(B(),Rt(Te(t.comp),{key:1})):yt("",!0)],6)):yt("",!0)]}),_:1})],34)}var Me=ne(tI,[["render",rI],["__scopeId","data-v-5ddf6b77"]]);const Go=t=>(Cn("data-v-7dec2dec"),t=t(),Rn(),t),nI={class:"info-modal-header"},iI=["src","alt"],oI={class:"info-modal-title"},aI={key:0},sI={key:0},lI={key:0},uI=Go(()=>U("div",null," Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb ",-1)),cI=Go(()=>U("br",null,null,-1)),fI=Go(()=>U("br",null,null,-1)),hI=["href"],dI=Go(()=>U("span",{class:"material-icons info-modal-discord"},"discord",-1)),pI=Go(()=>U("div",null,[U("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[U("span",{class:"material-icons info-modal-discord"},"discord"),dt(" The Paper Pilot Community ")])],-1)),vI=Go(()=>U("div",null,[U("a",{href:"https://discord.gg/F3xveHV",class:"info-modal-discord-link"},[U("span",{class:"material-icons info-modal-discord"},"discord"),dt(" The Modding Tree ")])],-1)),mI=Go(()=>U("br",null,null,-1));var gI=Pt({__name:"Info",props:{changelog:null},setup(t,{expose:e}){const r=t,{title:n,logo:i,author:o,discordName:a,discordLink:s,versionNumber:l,versionTitle:u}=Ie,c=Ae(r),f=It(!1),h=tt(()=>pc(wt.timePlayed)),d=tt(()=>te(le(()=>P(Ot,null,[h_.map(Ge)]))));e({open(){f.value=!0}});function p(){var v;(v=E(c.changelog))==null||v.open()}return(v,m)=>(B(),Rt(Ki,{modelValue:f.value,"onUpdate:modelValue":m[0]||(m[0]=y=>f.value=y)},{header:Bt(()=>[U("div",nI,[E(i)?(B(),Q("img",{key:0,class:"info-modal-logo",src:E(i),alt:E(n)},null,8,iI)):yt("",!0),U("div",oI,[U("h2",null,re(E(n)),1),U("h4",null,[dt(" v"+re(E(l)),1),E(u)?(B(),Q("span",aI,": "+re(E(u)),1)):yt("",!0)])])])]),body:Bt(({shown:y})=>[y?(B(),Q("div",sI,[E(o)?(B(),Q("div",lI,"By "+re(E(o)),1)):yt("",!0),uI,cI,U("div",{class:"link",onClick:p},"Changelog"),fI,U("div",null,[E(s)?(B(),Q("a",{key:0,href:E(s),class:"info-modal-discord-link"},[dI,dt(" "+re(E(a)),1)],8,hI)):yt("",!0)]),pI,vI,mI,U("div",null,"Time Played: "+re(E(h)),1),(B(),Rt(Te(E(d))))])):yt("",!0)]),_:1},8,["modelValue"]))}});var yI=ne(gI,[["__scopeId","data-v-7dec2dec"]]);function ep(t){return(ep=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function Lv(t){return function(e){if(Array.isArray(e))return sh(e)}(t)||function(e){if(typeof Symbol!="undefined"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}(t)||__(t)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function __(t,e){if(t){if(typeof t=="string")return sh(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return r==="Object"&&t.constructor&&(r=t.constructor.name),r==="Map"||r==="Set"?Array.from(t):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?sh(t,e):void 0}}function sh(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(l){throw l},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o,a=!0,s=!1;return{s:function(){r=r.call(t)},n:function(){var l=r.next();return a=l.done,l},e:function(l){s=!0,o=l},f:function(){try{a||r.return==null||r.return()}finally{if(s)throw o}}}}var lh={inheritAttrs:!1,name:"vue-input",props:{autocomplete:{required:!1,type:String},modelValue:{required:!0,type:String},placeholder:{required:!0,type:String},disabled:{required:!0,type:Boolean},tabindex:{required:!0,type:Number},autofocus:{required:!0,type:Boolean},comboboxUid:{required:!0,type:Number}},emits:["update:modelValue","input","change","focus","blur","escape"],setup:function(t,e){var r=It(null);return Wn(function(){t.autofocus&&r.value.focus()}),nl(function(){t.autofocus&&r.value.focus()}),{handleInput:function(n){e.emit("input",n),e.emit("update:modelValue",n.target.value)},handleChange:function(n){e.emit("change",n),e.emit("update:modelValue",n.target.value)},handleFocus:function(n){e.emit("focus",n)},handleBlur:function(n){e.emit("blur",n)},input:r,handleEscape:function(n){r.value.blur(),e.emit("escape",n)}}}},bI={class:"vue-input"},_I=["autocomplete","modelValue","placeholder","disabled","tabindex","autofocus","aria-controls","aria-labelledby"];lh.render=function(t,e,r,n,i,o){return B(),Q("div",bI,[He(t.$slots,"prepend"),U("input",{ref:"input",autocomplete:r.autocomplete,modelValue:r.modelValue,placeholder:r.placeholder,disabled:r.disabled,onInput:e[0]||(e[0]=function(){return n.handleInput&&n.handleInput.apply(n,arguments)}),onChange:e[1]||(e[1]=function(){return n.handleChange&&n.handleChange.apply(n,arguments)}),onFocus:e[2]||(e[2]=function(){return n.handleFocus&&n.handleFocus.apply(n,arguments)}),onBlur:e[3]||(e[3]=function(){return n.handleBlur&&n.handleBlur.apply(n,arguments)}),onKeyup:e[4]||(e[4]=yo(mr(function(){return n.handleEscape&&n.handleEscape.apply(n,arguments)},["exact"]),["esc"])),tabindex:r.tabindex,autofocus:r.autofocus,"aria-autocomplete":"list","aria-controls":"vs".concat(r.comboboxUid,"-listbox"),"aria-labelledby":"vs".concat(r.comboboxUid,"-combobox")},null,40,_I),He(t.$slots,"append")])},lh.__file="src/components/input.vue";var uh={inheritAttrs:!1,name:"vue-tags",props:{modelValue:{required:!0,type:Array,validator:function(t){return t.every(function(e){return ep(e.key)!==void 0&&e.label!==void 0&&typeof e.selected=="boolean"})}},collapseTags:{type:Boolean}},emits:["click"],setup:function(t,e){return{dataAttrs:en("dataAttrs"),handleClick:function(r){e.emit("click",r)}}}};uh.render=function(t,e,r,n,i,o){return B(),Q("ul",yr({class:["vue-tags",{collapsed:r.collapseTags}],onMousedown:e[0]||(e[0]=mr(function(){},["prevent"])),tabindex:"-1",onClick:e[1]||(e[1]=function(){return n.handleClick&&n.handleClick.apply(n,arguments)})},n.dataAttrs),[(B(!0),Q(Ot,null,Hn(r.modelValue,function(a){return B(),Q(Ot,{key:a.key},[a.group?yt("v-if",!0):(B(),Q("li",{key:0,class:Qt(["vue-tag",{selected:a.selected}])},[He(t.$slots,"default",{option:a},function(){return[U("span",null,re(a.label),1)]})],2))],64)}),128))],16)},uh.__file="src/components/tags.vue";var ch={inheritAttrs:!1,name:"vue-dropdown",props:{modelValue:{required:!0,type:Array,validator:function(t){return t.every(function(e){return ep(e.key)!==void 0&&e.label!==void 0&&typeof e.selected=="boolean"})}},comboboxUid:{required:!0,type:Number},maxHeight:{required:!0},highlightedOriginalIndex:{required:!0}},emits:["click-item","mouseenter"],setup:function(t,e){return{dataAttrs:en("dataAttrs"),handleClickItem:function(r,n){n.disabled||e.emit("click-item",r,n)},handleMouseenter:function(r,n){e.emit("mouseenter",r,n)}}}},xI=["id","aria-multiselectable","aria-busy","aria-disabled"],TI=["onClick","onMouseenter","id","aria-selected","aria-disabled"];ch.render=function(t,e,r,n,i,o){return B(),Q("ul",yr({class:"vue-dropdown",style:{maxHeight:r.maxHeight+"px"},onMousedown:e[0]||(e[0]=mr(function(){},["prevent"]))},n.dataAttrs,{role:"listbox",id:"vs".concat(r.comboboxUid,"-listbox"),"aria-multiselectable":n.dataAttrs["data-multiple"],"aria-busy":n.dataAttrs["data-loading"],"aria-disabled":n.dataAttrs["data-disabled"]}),[(B(!0),Q(Ot,null,Hn(r.modelValue,function(a,s){return B(),Q(Ot,{key:a.key},[a.visible&&a.hidden===!1?(B(),Q("li",{key:0,onClick:function(l){return n.handleClickItem(l,a)},class:Qt(["vue-dropdown-item",{selected:a.selected,disabled:a.disabled,highlighted:a.originalIndex===r.highlightedOriginalIndex,group:a.group}]),onMouseenter:function(l){return n.handleMouseenter(l,a)},role:"option",id:"vs".concat(r.comboboxUid,"-option-").concat(s),"aria-selected":!!a.selected||!!a.disabled&&void 0,"aria-disabled":a.disabled},[He(t.$slots,"default",{option:a},function(){return[U("span",null,re(a.label),1)]})],42,TI)):yt("v-if",!0)],64)}),128))],16,xI)},ch.__file="src/components/dropdown.vue";var x_=function(t,e,r){var n=r.valueBy;return n(t)===n(e)},ia=function(t,e,r){var n=r.valueBy;return t.some(function(i){return x_(i,e,{valueBy:n})})},ro=function(t,e,r){var n=r.valueBy;return t.find(function(i){return n(i)===e})},kc=function(t,e,r){var n=r.max,i=r.valueBy;return ia(t,e,{valueBy:i})||t.length>=n?t:t.concat(e)},Gc=function(t,e,r){var n=r.min,i=r.valueBy;return ia(t,e,{valueBy:i})===!1||t.length<=n?t:t.filter(function(o){return x_(o,e,{valueBy:i})===!1})},Il=function(t){return tt(function(){return typeof t.value=="function"?t.value:typeof t.value=="string"?function(e){return t.value.split(".").reduce(function(r,n){return r[n]},e)}:function(e){return e}})},wI=function(t,e){var r=tt(function(){return t.value.reduce(function(a,s){return Object.assign(a,(l={},u=s.originalIndex,c=s,u in l?Object.defineProperty(l,u,{value:c,enumerable:!0,configurable:!0,writable:!0}):l[u]=c,l));var l,u,c},{})}),n=function(a){var s=r.value[a];return s!==void 0&&i(s)!==!1&&(e.value=a,!0)},i=function(a){return!a.disabled&&!a.hidden&&a.visible},o=tt(function(){return t.value.some(function(a){return i(a)})});return Xe(function(){if(o.value===!1&&(e.value=null),e.value!==null&&t.value.length<=e.value){var a,s=bo(t.value.reverse());try{for(s.s();!(a=s.n()).done;){var l=a.value;if(n(l.originalIndex))break}}catch(h){s.e(h)}finally{s.f()}}if(e.value===null||i(t.value[e.value])===!1){var u,c=bo(t.value);try{for(c.s();!(u=c.n()).done;){var f=u.value;if(n(f.originalIndex))break}}catch(h){c.e(h)}finally{c.f()}}}),{pointerForward:function(){if(o.value!==!1&&e.value!==null)for(var a=e.value+1,s=0;a!==e.value&&s++a.value.$el.clientHeight+a.value.$el.scrollTop&<++r.min,"data-total-length":r.options.length,"data-multiple":t.multiple,"data-loading":t.loading,"data-disabled":t.disabled}});_o("dataAttrs",bt);var W=tt(function(){return S.value.filter(function(V){return V.selected}).filter(function(V){return!V.group})}),ft=tt(function(){return t.multiple?W.value.length===0?t.placeholder:W.value.length===1?"1 option selected":W.value.length+" options selected":W.value.length===0?t.placeholder:W.value[0].label+""}),gt=tt(function(){var V=W.value.map(function(Z){return Z.originalOption});return t.multiple?V:V[0]||n.value}),_t=It();return ze(function(){return[t.openDirection,u.value]},function(){var V,Z;_t.value=(Z=(V=t.openDirection)!==null&&V!==void 0?V:function(){if(o.value!==void 0&&window!==void 0)return window.innerHeight-o.value.getBoundingClientRect().bottom>=t.maxHeight?"bottom":"top"}())!==null&&Z!==void 0?Z:"bottom"},{immediate:!0}),{instance:i,isFocusing:u,wrapper:o,dropdown:a,input:s,focus:c,blur:f,toggle:function(){u.value?f():c()},searchingInputValue:h,handleInputForInput:function(V){e.emit("search:input",V)},handleChangeForInput:function(V){e.emit("search:change",V)},handleFocusForInput:function(V){c()},handleBlurForInput:function(V){f()},optionsWithInfo:S,addOrRemoveOption:function(V,Z){t.disabled||(Z.group&&t.multiple?T(V,Z):w(V,Z),x(),t.closeOnSelect===!0&&(u.value=!1),t.clearOnSelect===!0&&h.value&&R())},dataAttrs:bt,innerPlaceholder:ft,selected:gt,highlightedOriginalIndex:C,pointerForward:function(){H(),cr(ht)},pointerBackward:function(){G(),cr(ht)},pointerFirst:function(){var V,Z=bo(r.options.keys());try{for(Z.s();!(V=Z.n()).done;){var lt=V.value;if(k(lt))break}}catch(ut){Z.e(ut)}finally{Z.f()}cr(ht)},pointerLast:function(){var V,Z=bo(Lv(r.options.keys()).reverse());try{for(Z.s();!(V=Z.n()).done;){var lt=V.value;if(k(lt))break}}catch(ut){Z.e(ut)}finally{Z.f()}cr(ht)},typeAhead:function(V){var Z,lt;if(!t.searchable){var ut=!1;if(D.test(V.key)?(Y+=V.key.toLowerCase(),ut=!0):V.code==="Space"&&(Y+=" "),ut){var Gt,it=bo(K.value);try{for(it.s();!(Gt=it.n()).done;){var kt=Gt.value;if(((lt=(Z=r.labelBy(r.options[kt]))===null||Z===void 0?void 0:Z.toLowerCase())===null||lt===void 0?void 0:lt.startsWith(Y))===!0&&k(kt))break}}catch(Vt){it.e(Vt)}finally{it.f()}clearTimeout(b),b=setTimeout(function(){Y=""},500)}}},pointerSet:k,direction:_t}},components:{VInput:lh,VTags:uh,VDropdown:ch}});Fu.__VERSION__="2.10.4";var EI=["tabindex","id","role","aria-expanded","aria-owns","aria-activedescendant","aria-busy","aria-disabled"],II={class:"vue-select-header"},CI={key:0,class:"vue-input"},RI=["placeholder","autocomplete"],NI=["onClick"],PI=U("span",{class:"icon loading"},[U("div"),U("div"),U("div")],-1),SI={key:0,class:"vue-select-input-wrapper"},AI=U("span",{class:"icon loading"},[U("div"),U("div"),U("div")],-1);Fu.render=function(t,e,r,n,i,o){var a=Re("v-tags"),s=Re("v-input"),l=Re("v-dropdown");return B(),Q("div",yr({ref:"wrapper",class:["vue-select",["direction-".concat(t.direction)]],tabindex:t.isFocusing?-1:t.tabindex,onFocus:e[9]||(e[9]=function(){return t.focus&&t.focus.apply(t,arguments)}),onBlur:e[10]||(e[10]=function(u){return!t.searchable&&t.blur(u)})},Object.assign({},t.dataAttrs,t.$attrs),{onKeypress:e[11]||(e[11]=yo(mr(function(){return t.highlightedOriginalIndex!==null&&t.addOrRemoveOption(t.$event,t.optionsWithInfo[t.highlightedOriginalIndex])},["prevent","exact"]),["enter"])),onKeydown:[e[12]||(e[12]=yo(mr(function(){return t.pointerForward&&t.pointerForward.apply(t,arguments)},["prevent","exact"]),["down"])),e[13]||(e[13]=yo(mr(function(){return t.pointerBackward&&t.pointerBackward.apply(t,arguments)},["prevent","exact"]),["up"])),e[14]||(e[14]=yo(mr(function(){return t.pointerFirst&&t.pointerFirst.apply(t,arguments)},["prevent","exact"]),["home"])),e[15]||(e[15]=yo(mr(function(){return t.pointerLast&&t.pointerLast.apply(t,arguments)},["prevent","exact"]),["end"])),e[16]||(e[16]=function(){return t.typeAhead&&t.typeAhead.apply(t,arguments)})],id:"vs".concat(t.instance.uid,"-combobox"),role:t.searchable?"combobox":null,"aria-expanded":t.isFocusing,"aria-haspopup":"listbox","aria-owns":"vs".concat(t.instance.uid,"-listbox"),"aria-activedescendant":t.highlightedOriginalIndex===null?null:"vs".concat(t.instance.uid,"-option-").concat(t.highlightedOriginalIndex),"aria-busy":t.loading,"aria-disabled":t.disabled}),[U("div",II,[t.multiple&&t.taggable&&t.modelValue.length===0||t.searchable===!1&&t.taggable===!1?(B(),Q("div",CI,[He(t.$slots,"label",{selected:t.selected},function(){return[U("input",{placeholder:t.innerPlaceholder,autocomplete:t.autocomplete,readonly:"",onClick:e[0]||(e[0]=function(){return t.focus&&t.focus.apply(t,arguments)})},null,8,RI)]})])):yt("v-if",!0),t.multiple&&t.taggable?(B(),Q(Ot,{key:1},[P(a,{modelValue:t.optionsWithInfo,"collapse-tags":t.collapseTags,tabindex:"-1",onClick:t.focus},{default:Bt(function(u){var c=u.option;return[He(t.$slots,"tag",{option:c.originalOption,remove:function(){return t.addOrRemoveOption(t.$event,c)}},function(){return[U("span",null,re(c.label),1),U("img",{src:"data:image/svg+xml;base64,PHN2ZyBpZD0iZGVsZXRlIiBkYXRhLW5hbWU9ImRlbGV0ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNTEyIDUxMiI+PHRpdGxlPmRlbGV0ZTwvdGl0bGU+PHBhdGggZD0iTTI1NiwyNEMzODMuOSwyNCw0ODgsMTI4LjEsNDg4LDI1NlMzODMuOSw0ODgsMjU2LDQ4OCwyNC4wNiwzODMuOSwyNC4wNiwyNTYsMTI4LjEsMjQsMjU2LDI0Wk0wLDI1NkMwLDM5Ny4xNiwxMTQuODQsNTEyLDI1Niw1MTJTNTEyLDM5Ny4xNiw1MTIsMjU2LDM5Ny4xNiwwLDI1NiwwLDAsMTE0Ljg0LDAsMjU2WiIgZmlsbD0iIzViNWI1ZiIvPjxwb2x5Z29uIHBvaW50cz0iMzgyIDE3Mi43MiAzMzkuMjkgMTMwLjAxIDI1NiAyMTMuMjkgMTcyLjcyIDEzMC4wMSAxMzAuMDEgMTcyLjcyIDIxMy4yOSAyNTYgMTMwLjAxIDMzOS4yOCAxNzIuNzIgMzgyIDI1NiAyOTguNzEgMzM5LjI5IDM4MS45OSAzODIgMzM5LjI4IDI5OC43MSAyNTYgMzgyIDE3Mi43MiIgZmlsbD0iIzViNWI1ZiIvPjwvc3ZnPg==",alt:"delete tag",class:"icon delete",onClick:mr(function(){return t.addOrRemoveOption(t.$event,c)},["prevent","stop"])},null,8,NI)]})]}),_:3},8,["modelValue","collapse-tags","onClick"]),He(t.$slots,"toggle",{isFocusing:t.isFocusing,toggle:t.toggle},function(){return[U("span",{class:Qt(["icon arrow-downward",{active:t.isFocusing}]),onClick:e[1]||(e[1]=function(){return t.toggle&&t.toggle.apply(t,arguments)}),onMousedown:e[2]||(e[2]=mr(function(){},["prevent","stop"]))},null,34)]})],64)):(B(),Q(Ot,{key:2},[t.searchable?(B(),Rt(s,{key:0,ref:"input",modelValue:t.searchingInputValue,"onUpdate:modelValue":e[3]||(e[3]=function(u){return t.searchingInputValue=u}),disabled:t.disabled,autocomplete:t.autocomplete,placeholder:t.isFocusing?t.searchPlaceholder:t.innerPlaceholder,onInput:t.handleInputForInput,onChange:t.handleChangeForInput,onFocus:t.handleFocusForInput,onBlur:t.handleBlurForInput,onEscape:t.blur,autofocus:t.autofocus||t.taggable&&t.searchable,tabindex:t.tabindex,comboboxUid:t.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"])):yt("v-if",!0),t.loading?He(t.$slots,"loading",{key:1},function(){return[PI]}):He(t.$slots,"toggle",{key:2,isFocusing:t.isFocusing,toggle:t.toggle},function(){return[U("span",{class:Qt(["icon arrow-downward",{active:t.isFocusing}]),onClick:e[4]||(e[4]=function(){return t.toggle&&t.toggle.apply(t,arguments)}),onMousedown:e[5]||(e[5]=mr(function(){},["prevent","stop"]))},null,34)]})],64))]),t.multiple&&t.taggable&&t.searchable?(B(),Q("div",SI,[Oa(P(s,{ref:"input",modelValue:t.searchingInputValue,"onUpdate:modelValue":e[6]||(e[6]=function(u){return t.searchingInputValue=u}),disabled:t.disabled,autocomplete:t.autocomplete,placeholder:t.isFocusing?t.searchPlaceholder:t.innerPlaceholder,onInput:t.handleInputForInput,onChange:t.handleChangeForInput,onFocus:t.handleFocusForInput,onBlur:t.handleBlurForInput,onEscape:t.blur,autofocus:t.autofocus||t.taggable&&t.searchable,tabindex:t.tabindex,comboboxUid:t.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"]),[[dc,t.isFocusing]]),t.loading?He(t.$slots,"loading",{key:0},function(){return[AI]}):yt("v-if",!0)])):yt("v-if",!0),P(l,{ref:"dropdown",modelValue:t.optionsWithInfo,"onUpdate:modelValue":e[7]||(e[7]=function(u){return t.optionsWithInfo=u}),onClickItem:t.addOrRemoveOption,onMouseenter:e[8]||(e[8]=function(u,c){return t.pointerSet(c.originalIndex)}),comboboxUid:t.instance.uid,maxHeight:t.maxHeight,highlightedOriginalIndex:t.highlightedOriginalIndex},{default:Bt(function(u){var c=u.option;return[He(t.$slots,"dropdown-item",{option:c.originalOption},function(){return[U("span",null,re(c.label),1)]})]}),_:3},8,["modelValue","onClickItem","comboboxUid","maxHeight","highlightedOriginalIndex"])],16,EI)},Fu.__file="src/index.vue";const OI={class:"field"},UI={key:0,class:"field-title"},rp=Pt({__name:"Select",props:{title:null,modelValue:null,options:null,placeholder:null,closeOnSelect:{type:Boolean}},emits:["update:modelValue"],setup(t,{emit:e}){var a;const r=t,n=ko(Mr(r,"title"),"span"),i=It((a=r.options.find(s=>s.value===r.modelValue))!=null?a:null);ze(Mr(r,"modelValue"),s=>{var l;Be(i)!==s&&(i.value=(l=r.options.find(u=>u.value===s))!=null?l:null)});function o(s){e("update:modelValue",s.value)}return(s,l)=>(B(),Q("div",OI,[E(n)?(B(),Q("span",UI,[(B(),Rt(Te(E(n))))])):yt("",!0),P(E(Fu),{options:t.options,modelValue:i.value,"onUpdate:modelValue":[l[0]||(l[0]=u=>i.value=u),o],min:1,"label-by":"label",placeholder:t.placeholder,"close-on-select":t.closeOnSelect},null,8,["options","modelValue","placeholder","close-on-select"])]))}});const FI={class:"field"},LI=Pt({__name:"Toggle",props:{title:null,modelValue:{type:Boolean}},emits:["update:modelValue"],setup(t,{emit:e}){const r=t,n=tt(()=>te(E(r.title)||"","span")),i=tt({get(){return!!r.modelValue},set(o){e("update:modelValue",o)}});return(o,a)=>(B(),Q("label",FI,[Oa(U("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":a[0]||(a[0]=s=>oe(i)?i.value=s:null)},null,512),[[hc,E(i)]]),(B(),Rt(Te(E(n))))]))}});var Xr=ne(LI,[["__scopeId","data-v-2b109500"]]);const T_=t=>(Cn("data-v-bc13791c"),t=t(),Rn(),t),MI=T_(()=>U("div",{class:"header"},[U("h2",null,"Options")],-1)),BI=T_(()=>U("hr",null,null,-1));var kI=Pt({__name:"Options",setup(t,{expose:e}){const r=It(!1);e({open(){r.value=!0}});const n=Object.keys(gi).map(p=>({label:e_(p),value:p})),i=tt(()=>te(le(()=>P(Ot,null,[c_.map(Ge)])))),{showTPS:o,theme:a,unthrottled:s}=Ae(Pe),{autosave:l,offlineProd:u}=Ae(wt),c=tt({get(){return wt.devSpeed===0},set(p){wt.devSpeed=p?0:null}}),f=le(()=>P("span",null,[dt("Offline Production"),P(Me,{display:"Save-specific"},{default:()=>[dt("*")]})])),h=le(()=>P("span",null,[dt("Autosave"),P(Me,{display:"Save-specific"},{default:()=>[dt("*")]})])),d=le(()=>P("span",null,[dt("Pause game"),P(Me,{display:"Save-specific"},{default:()=>[dt("*")]})]));return(p,v)=>(B(),Rt(Ki,{modelValue:r.value,"onUpdate:modelValue":v[6]||(v[6]=m=>r.value=m)},{header:Bt(()=>[MI]),body:Bt(()=>[P(rp,{title:"Theme",options:E(n),modelValue:E(a),"onUpdate:modelValue":v[0]||(v[0]=m=>oe(a)?a.value=m:null)},null,8,["options","modelValue"]),(B(),Rt(Te(E(i)))),P(Xr,{title:"Show TPS",modelValue:E(o),"onUpdate:modelValue":v[1]||(v[1]=m=>oe(o)?o.value=m:null)},null,8,["modelValue"]),BI,P(Xr,{title:"Unthrottled",modelValue:E(s),"onUpdate:modelValue":v[2]||(v[2]=m=>oe(s)?s.value=m:null)},null,8,["modelValue"]),P(Xr,{title:E(f),modelValue:E(u),"onUpdate:modelValue":v[3]||(v[3]=m=>oe(u)?u.value=m:null)},null,8,["title","modelValue"]),P(Xr,{title:E(h),modelValue:E(l),"onUpdate:modelValue":v[4]||(v[4]=m=>oe(l)?l.value=m:null)},null,8,["title","modelValue"]),E(Ie).enablePausing?(B(),Rt(Xr,{key:0,title:E(d),modelValue:E(c),"onUpdate:modelValue":v[5]||(v[5]=m=>oe(c)?c.value=m:null)},null,8,["title","modelValue"])):yt("",!0)]),_:1},8,["modelValue"]))}});var GI=ne(kI,[["__scopeId","data-v-bc13791c"]]),w_={exports:{}},DI=s_(Nw);/**! + * Sortable 1.14.0 + * @author RubaXa + * @author owenm + * @license MIT + */function Mv(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),r.push.apply(r,n)}return r}function $n(t){for(var e=1;e=0)&&(r[i]=t[i]);return r}function $I(t,e){if(t==null)return{};var r=VI(t,e),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(i=0;i=0)&&(!Object.prototype.propertyIsEnumerable.call(t,n)||(r[n]=t[n]))}return r}function jI(t){return XI(t)||zI(t)||WI(t)||YI()}function XI(t){if(Array.isArray(t))return fh(t)}function zI(t){if(typeof Symbol!="undefined"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function WI(t,e){if(!!t){if(typeof t=="string")return fh(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);if(r==="Object"&&t.constructor&&(r=t.constructor.name),r==="Map"||r==="Set")return Array.from(t);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return fh(t,e)}}function fh(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r"&&(e=e.substring(1)),t)try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch{return!1}return!1}}function qI(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function mn(t,e,r,n){if(t){r=r||document;do{if(e!=null&&(e[0]===">"?t.parentNode===r&&Lu(t,e):Lu(t,e))||n&&t===r)return t;if(t===r)break}while(t=qI(t))}return null}var kv=/\s+/g;function $e(t,e,r){if(t&&e)if(t.classList)t.classList[r?"add":"remove"](e);else{var n=(" "+t.className+" ").replace(kv," ").replace(" "+e+" "," ");t.className=(n+(r?" "+e:"")).replace(kv," ")}}function Nt(t,e,r){var n=t&&t.style;if(n){if(r===void 0)return document.defaultView&&document.defaultView.getComputedStyle?r=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(r=t.currentStyle),e===void 0?r:r[e];!(e in n)&&e.indexOf("webkit")===-1&&(e="-webkit-"+e),n[e]=r+(typeof r=="string"?"":"px")}}function Ro(t,e){var r="";if(typeof t=="string")r=t;else do{var n=Nt(t,"transform");n&&n!=="none"&&(r=n+" "+r)}while(!e&&(t=t.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(r)}function C_(t,e,r){if(t){var n=t.getElementsByTagName(e),i=0,o=n.length;if(r)for(;i=o:a=i<=o,!a)return n;if(n===kn())break;n=Ui(n,!1)}return!1}function Ra(t,e,r,n){for(var i=0,o=0,a=t.children;o2&&arguments[2]!==void 0?arguments[2]:{},i=n.evt,o=$I(n,iC);sl.pluginEvent.bind(jt)(e,r,$n({dragEl:vt,parentEl:Ze,ghostEl:Jt,rootEl:ke,nextEl:fo,lastDownEl:pu,cloneEl:qe,cloneHidden:Ai,dragStarted:ns,putSortable:br,activeSortable:jt.active,originalEvent:i,oldIndex:oa,oldDraggableIndex:ys,newIndex:Hr,newDraggableIndex:Pi,hideGhostForTarget:O_,unhideGhostForTarget:U_,cloneNowHidden:function(){Ai=!0},cloneNowShown:function(){Ai=!1},dispatchSortableEvent:function(s){Pr({sortable:r,name:s,originalEvent:i})}},o))};function Pr(t){rs($n({putSortable:br,cloneEl:qe,targetEl:vt,rootEl:ke,oldIndex:oa,oldDraggableIndex:ys,newIndex:Hr,newDraggableIndex:Pi},t))}var vt,Ze,Jt,ke,fo,pu,qe,Ai,oa,Hr,ys,Pi,Cl,br,ea=!1,Mu=!1,Bu=[],no,sn,$c,jc,Vv,$v,ns,Vo,bs,_s=!1,Rl=!1,vu,xr,Xc=[],hh=!1,ku=[],mc=typeof document!="undefined",Nl=E_,jv=al||yi?"cssFloat":"float",oC=mc&&!ZI&&!E_&&"draggable"in document.createElement("div"),P_=function(){if(!!mc){if(yi)return!1;var t=document.createElement("x");return t.style.cssText="pointer-events:auto",t.style.pointerEvents==="auto"}}(),S_=function(e,r){var n=Nt(e),i=parseInt(n.width)-parseInt(n.paddingLeft)-parseInt(n.paddingRight)-parseInt(n.borderLeftWidth)-parseInt(n.borderRightWidth),o=Ra(e,0,r),a=Ra(e,1,r),s=o&&Nt(o),l=a&&Nt(a),u=s&&parseInt(s.marginLeft)+parseInt(s.marginRight)+De(o).width,c=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+De(a).width;if(n.display==="flex")return n.flexDirection==="column"||n.flexDirection==="column-reverse"?"vertical":"horizontal";if(n.display==="grid")return n.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(o&&s.float&&s.float!=="none"){var f=s.float==="left"?"left":"right";return a&&(l.clear==="both"||l.clear===f)?"vertical":"horizontal"}return o&&(s.display==="block"||s.display==="flex"||s.display==="table"||s.display==="grid"||u>=i&&n[jv]==="none"||a&&n[jv]==="none"&&u+c>i)?"vertical":"horizontal"},aC=function(e,r,n){var i=n?e.left:e.top,o=n?e.right:e.bottom,a=n?e.width:e.height,s=n?r.left:r.top,l=n?r.right:r.bottom,u=n?r.width:r.height;return i===s||o===l||i+a/2===s+u/2},sC=function(e,r){var n;return Bu.some(function(i){var o=i[Er].options.emptyInsertThreshold;if(!(!o||np(i))){var a=De(i),s=e>=a.left-o&&e<=a.right+o,l=r>=a.top-o&&r<=a.bottom+o;if(s&&l)return n=i}}),n},A_=function(e){function r(o,a){return function(s,l,u,c){var f=s.options.group.name&&l.options.group.name&&s.options.group.name===l.options.group.name;if(o==null&&(a||f))return!0;if(o==null||o===!1)return!1;if(a&&o==="clone")return o;if(typeof o=="function")return r(o(s,l,u,c),a)(s,l,u,c);var h=(a?s:l).options.group.name;return o===!0||typeof o=="string"&&o===h||o.join&&o.indexOf(h)>-1}}var n={},i=e.group;(!i||du(i)!="object")&&(i={name:i}),n.name=i.name,n.checkPull=r(i.pull,!0),n.checkPut=r(i.put),n.revertClone=i.revertClone,e.group=n},O_=function(){!P_&&Jt&&Nt(Jt,"display","none")},U_=function(){!P_&&Jt&&Nt(Jt,"display","")};mc&&document.addEventListener("click",function(t){if(Mu)return t.preventDefault(),t.stopPropagation&&t.stopPropagation(),t.stopImmediatePropagation&&t.stopImmediatePropagation(),Mu=!1,!1},!0);var io=function(e){if(vt){e=e.touches?e.touches[0]:e;var r=sC(e.clientX,e.clientY);if(r){var n={};for(var i in e)e.hasOwnProperty(i)&&(n[i]=e[i]);n.target=n.rootEl=r,n.preventDefault=void 0,n.stopPropagation=void 0,r[Er]._onDragOver(n)}}},lC=function(e){vt&&vt.parentNode[Er]._isOutsideThisEl(e.target)};function jt(t,e){if(!(t&&t.nodeType&&t.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=e=an({},e),t[Er]=this;var r={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return S_(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(a,s){a.setData("Text",s.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:jt.supportPointer!==!1&&"PointerEvent"in window&&!ms,emptyInsertThreshold:5};sl.initializePlugins(this,t,r);for(var n in r)!(n in e)&&(e[n]=r[n]);A_(e);for(var i in this)i.charAt(0)==="_"&&typeof this[i]=="function"&&(this[i]=this[i].bind(this));this.nativeDraggable=e.forceFallback?!1:oC,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?de(t,"pointerdown",this._onTapStart):(de(t,"mousedown",this._onTapStart),de(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(de(t,"dragover",this),de(t,"dragenter",this)),Bu.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),an(this,eC())}jt.prototype={constructor:jt,_isOutsideThisEl:function(e){!this.el.contains(e)&&e!==this.el&&(Vo=null)},_getDirection:function(e,r){return typeof this.options.direction=="function"?this.options.direction.call(this,e,r,vt):this.options.direction},_onTapStart:function(e){if(!!e.cancelable){var r=this,n=this.el,i=this.options,o=i.preventOnFilter,a=e.type,s=e.touches&&e.touches[0]||e.pointerType&&e.pointerType==="touch"&&e,l=(s||e).target,u=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||l,c=i.filter;if(mC(n),!vt&&!(/mousedown|pointerdown/.test(a)&&e.button!==0||i.disabled)&&!u.isContentEditable&&!(!this.nativeDraggable&&ms&&l&&l.tagName.toUpperCase()==="SELECT")&&(l=mn(l,i.draggable,n,!1),!(l&&l.animated)&&pu!==l)){if(oa=Je(l),ys=Je(l,i.draggable),typeof c=="function"){if(c.call(this,e,l,this)){Pr({sortable:r,rootEl:u,name:"filter",targetEl:l,toEl:n,fromEl:n}),Or("filter",r,{evt:e}),o&&e.cancelable&&e.preventDefault();return}}else if(c&&(c=c.split(",").some(function(f){if(f=mn(u,f.trim(),n,!1),f)return Pr({sortable:r,rootEl:f,name:"filter",targetEl:l,fromEl:n,toEl:n}),Or("filter",r,{evt:e}),!0}),c)){o&&e.cancelable&&e.preventDefault();return}i.handle&&!mn(u,i.handle,n,!1)||this._prepareDragStart(e,s,l)}}},_prepareDragStart:function(e,r,n){var i=this,o=i.el,a=i.options,s=o.ownerDocument,l;if(n&&!vt&&n.parentNode===o){var u=De(n);if(ke=o,vt=n,Ze=vt.parentNode,fo=vt.nextSibling,pu=n,Cl=a.group,jt.dragged=vt,no={target:vt,clientX:(r||e).clientX,clientY:(r||e).clientY},Vv=no.clientX-u.left,$v=no.clientY-u.top,this._lastX=(r||e).clientX,this._lastY=(r||e).clientY,vt.style["will-change"]="all",l=function(){if(Or("delayEnded",i,{evt:e}),jt.eventCanceled){i._onDrop();return}i._disableDelayedDragEvents(),!Bv&&i.nativeDraggable&&(vt.draggable=!0),i._triggerDragStart(e,r),Pr({sortable:i,name:"choose",originalEvent:e}),$e(vt,a.chosenClass,!0)},a.ignore.split(",").forEach(function(c){C_(vt,c.trim(),zc)}),de(s,"dragover",io),de(s,"mousemove",io),de(s,"touchmove",io),de(s,"mouseup",i._onDrop),de(s,"touchend",i._onDrop),de(s,"touchcancel",i._onDrop),Bv&&this.nativeDraggable&&(this.options.touchStartThreshold=4,vt.draggable=!0),Or("delayStart",this,{evt:e}),a.delay&&(!a.delayOnTouchOnly||r)&&(!this.nativeDraggable||!(al||yi))){if(jt.eventCanceled){this._onDrop();return}de(s,"mouseup",i._disableDelayedDrag),de(s,"touchend",i._disableDelayedDrag),de(s,"touchcancel",i._disableDelayedDrag),de(s,"mousemove",i._delayedDragTouchMoveHandler),de(s,"touchmove",i._delayedDragTouchMoveHandler),a.supportPointer&&de(s,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(l,a.delay)}else l()}},_delayedDragTouchMoveHandler:function(e){var r=e.touches?e.touches[0]:e;Math.max(Math.abs(r.clientX-this._lastX),Math.abs(r.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){vt&&zc(vt),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;se(e,"mouseup",this._disableDelayedDrag),se(e,"touchend",this._disableDelayedDrag),se(e,"touchcancel",this._disableDelayedDrag),se(e,"mousemove",this._delayedDragTouchMoveHandler),se(e,"touchmove",this._delayedDragTouchMoveHandler),se(e,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,r){r=r||e.pointerType=="touch"&&e,!this.nativeDraggable||r?this.options.supportPointer?de(document,"pointermove",this._onTouchMove):r?de(document,"touchmove",this._onTouchMove):de(document,"mousemove",this._onTouchMove):(de(vt,"dragend",this),de(ke,"dragstart",this._onDragStart));try{document.selection?mu(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(e,r){if(ea=!1,ke&&vt){Or("dragStarted",this,{evt:r}),this.nativeDraggable&&de(document,"dragover",lC);var n=this.options;!e&&$e(vt,n.dragClass,!1),$e(vt,n.ghostClass,!0),jt.active=this,e&&this._appendGhost(),Pr({sortable:this,name:"start",originalEvent:r})}else this._nulling()},_emulateDragOver:function(){if(sn){this._lastX=sn.clientX,this._lastY=sn.clientY,O_();for(var e=document.elementFromPoint(sn.clientX,sn.clientY),r=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(sn.clientX,sn.clientY),e!==r);)r=e;if(vt.parentNode[Er]._isOutsideThisEl(e),r)do{if(r[Er]){var n=void 0;if(n=r[Er]._onDragOver({clientX:sn.clientX,clientY:sn.clientY,target:e,rootEl:r}),n&&!this.options.dragoverBubble)break}e=r}while(r=r.parentNode);U_()}},_onTouchMove:function(e){if(no){var r=this.options,n=r.fallbackTolerance,i=r.fallbackOffset,o=e.touches?e.touches[0]:e,a=Jt&&Ro(Jt,!0),s=Jt&&a&&a.a,l=Jt&&a&&a.d,u=Nl&&xr&&Dv(xr),c=(o.clientX-no.clientX+i.x)/(s||1)+(u?u[0]-Xc[0]:0)/(s||1),f=(o.clientY-no.clientY+i.y)/(l||1)+(u?u[1]-Xc[1]:0)/(l||1);if(!jt.active&&!ea){if(n&&Math.max(Math.abs(o.clientX-this._lastX),Math.abs(o.clientY-this._lastY))=0&&(Pr({rootEl:Ze,name:"add",toEl:Ze,fromEl:ke,originalEvent:e}),Pr({sortable:this,name:"remove",toEl:Ze,originalEvent:e}),Pr({rootEl:Ze,name:"sort",toEl:Ze,fromEl:ke,originalEvent:e}),Pr({sortable:this,name:"sort",toEl:Ze,originalEvent:e})),br&&br.save()):Hr!==oa&&Hr>=0&&(Pr({sortable:this,name:"update",toEl:Ze,originalEvent:e}),Pr({sortable:this,name:"sort",toEl:Ze,originalEvent:e})),jt.active&&((Hr==null||Hr===-1)&&(Hr=oa,Pi=ys),Pr({sortable:this,name:"end",toEl:Ze,originalEvent:e}),this.save()))),this._nulling()},_nulling:function(){Or("nulling",this),ke=vt=Ze=Jt=fo=qe=pu=Ai=no=sn=ns=Hr=Pi=oa=ys=Vo=bs=br=Cl=jt.dragged=jt.ghost=jt.clone=jt.active=null,ku.forEach(function(e){e.checked=!0}),ku.length=$c=jc=0},handleEvent:function(e){switch(e.type){case"drop":case"dragend":this._onDrop(e);break;case"dragenter":case"dragover":vt&&(this._onDragOver(e),uC(e));break;case"selectstart":e.preventDefault();break}},toArray:function(){for(var e=[],r,n=this.el.children,i=0,o=n.length,a=this.options;in.right+i||t.clientX<=n.right&&t.clientY>n.bottom&&t.clientX>=n.left:t.clientX>n.right&&t.clientY>n.top||t.clientX<=n.right&&t.clientY>n.bottom+i}function dC(t,e,r,n,i,o,a,s){var l=n?t.clientY:t.clientX,u=n?r.height:r.width,c=n?r.top:r.left,f=n?r.bottom:r.right,h=!1;if(!a){if(s&&vuc+u*o/2:lf-vu)return-bs}else if(l>c+u*(1-i)/2&&lf-u*o/2)?l>c+u/2?1:-1:0}function pC(t){return Je(vt)1&&(Zt.forEach(function(s){o.addAnimationState({target:s,rect:Ur?De(s):a}),Hc(s),s.fromRect=a,n.removeAnimationState(s)}),Ur=!1,xC(!this.options.removeCloneOnHide,i))},dragOverCompleted:function(r){var n=r.sortable,i=r.isOwner,o=r.insertion,a=r.activeSortable,s=r.parentEl,l=r.putSortable,u=this.options;if(o){if(i&&a._hideClone(),Ha=!1,u.animation&&Zt.length>1&&(Ur||!i&&!a.options.sort&&!l)){var c=De(Oe,!1,!0,!0);Zt.forEach(function(h){h!==Oe&&(Hv(h,c),s.appendChild(h))}),Ur=!0}if(!i)if(Ur||Al(),Zt.length>1){var f=Sl;a._showClone(n),a.options.animation&&!Sl&&f&&Dr.forEach(function(h){a.addAnimationState({target:h,rect:Va}),h.fromRect=Va,h.thisAnimationDuration=null})}else a._showClone(n)}},dragOverAnimationCapture:function(r){var n=r.dragRect,i=r.isOwner,o=r.activeSortable;if(Zt.forEach(function(s){s.thisAnimationDuration=null}),o.options.animation&&!i&&o.multiDrag.isMultiDrag){Va=an({},n);var a=Ro(Oe,!0);Va.top-=a.f,Va.left-=a.e}},dragOverAnimationComplete:function(){Ur&&(Ur=!1,Al())},drop:function(r){var n=r.originalEvent,i=r.rootEl,o=r.parentEl,a=r.sortable,s=r.dispatchSortableEvent,l=r.oldIndex,u=r.putSortable,c=u||this.sortable;if(!!n){var f=this.options,h=o.children;if(!$o)if(f.multiDragKey&&!this.multiDragKeyDown&&this._deselectMultiDrag(),$e(Oe,f.selectedClass,!~Zt.indexOf(Oe)),~Zt.indexOf(Oe))Zt.splice(Zt.indexOf(Oe),1),Da=null,rs({sortable:a,rootEl:i,name:"deselect",targetEl:Oe,originalEvt:n});else{if(Zt.push(Oe),rs({sortable:a,rootEl:i,name:"select",targetEl:Oe,originalEvt:n}),n.shiftKey&&Da&&a.el.contains(Da)){var d=Je(Da),p=Je(Oe);if(~d&&~p&&d!==p){var v,m;for(p>d?(m=d,v=p):(m=p,v=d+1);m1){var y=De(Oe),g=Je(Oe,":not(."+this.options.selectedClass+")");if(!Ha&&f.animation&&(Oe.thisAnimationDuration=null),c.captureAnimationState(),!Ha&&(f.animation&&(Oe.fromRect=y,Zt.forEach(function(T){if(T.thisAnimationDuration=null,T!==Oe){var w=Ur?De(T):y;T.fromRect=w,c.addAnimationState({target:T,rect:w})}})),Al(),Zt.forEach(function(T){h[g]?o.insertBefore(T,h[g]):o.appendChild(T),g++}),l===Je(Oe))){var b=!1;Zt.forEach(function(T){if(T.sortableIndex!==Je(T)){b=!0;return}}),b&&s("update")}Zt.forEach(function(T){Hc(T)}),c.animateAll()}ln=c}(i===o||u&&u.lastPutMode!=="clone")&&Dr.forEach(function(T){T.parentNode&&T.parentNode.removeChild(T)})}},nullingGlobal:function(){this.isMultiDrag=$o=!1,Dr.length=0},destroyGlobal:function(){this._deselectMultiDrag(),se(document,"pointerup",this._deselectMultiDrag),se(document,"mouseup",this._deselectMultiDrag),se(document,"touchend",this._deselectMultiDrag),se(document,"keydown",this._checkKeyDown),se(document,"keyup",this._checkKeyUp)},_deselectMultiDrag:function(r){if(!(typeof $o!="undefined"&&$o)&&ln===this.sortable&&!(r&&mn(r.target,this.options.draggable,this.sortable.el,!1))&&!(r&&r.button!==0))for(;Zt.length;){var n=Zt[0];$e(n,this.options.selectedClass,!1),Zt.shift(),rs({sortable:this.sortable,rootEl:this.sortable.el,name:"deselect",targetEl:n,originalEvt:r})}},_checkKeyDown:function(r){r.key===this.options.multiDragKey&&(this.multiDragKeyDown=!0)},_checkKeyUp:function(r){r.key===this.options.multiDragKey&&(this.multiDragKeyDown=!1)}},an(t,{pluginName:"multiDrag",utils:{select:function(r){var n=r.parentNode[Er];!n||!n.options.multiDrag||~Zt.indexOf(r)||(ln&&ln!==n&&(ln.multiDrag._deselectMultiDrag(),ln=n),$e(r,n.options.selectedClass,!0),Zt.push(r))},deselect:function(r){var n=r.parentNode[Er],i=Zt.indexOf(r);!n||!n.options.multiDrag||!~i||($e(r,n.options.selectedClass,!1),Zt.splice(i,1))}},eventProperties:function(){var r=this,n=[],i=[];return Zt.forEach(function(o){n.push({multiDragElement:o,index:o.sortableIndex});var a;Ur&&o!==Oe?a=-1:Ur?a=Je(o,":not(."+r.options.selectedClass+")"):a=Je(o),i.push({multiDragElement:o,index:a})}),{items:jI(Zt),clones:[].concat(Dr),oldIndicies:n,newIndicies:i}},optionListeners:{multiDragKey:function(r){return r=r.toLowerCase(),r==="ctrl"?r="Control":r.length>1&&(r=r.charAt(0).toUpperCase()+r.substr(1)),r}}})}function xC(t,e){Zt.forEach(function(r,n){var i=e.children[r.sortableIndex+(t?Number(n):0)];i?e.insertBefore(r,i):e.appendChild(r)})}function zv(t,e){Dr.forEach(function(r,n){var i=e.children[r.sortableIndex+(t?Number(n):0)];i?e.insertBefore(r,i):e.appendChild(r)})}function Al(){Zt.forEach(function(t){t!==Oe&&t.parentNode&&t.parentNode.removeChild(t)})}jt.mount(new gC);jt.mount(ap,op);var TC=Object.freeze(Object.defineProperty({__proto__:null,default:jt,MultiDrag:_C,Sortable:jt,Swap:yC},Symbol.toStringTag,{value:"Module"})),wC=s_(TC);(function(t,e){(function(n,i){t.exports=i(DI,wC)})(typeof self!="undefined"?self:cu,function(r,n){return function(i){var o={};function a(s){if(o[s])return o[s].exports;var l=o[s]={i:s,l:!1,exports:{}};return i[s].call(l.exports,l,l.exports,a),l.l=!0,l.exports}return a.m=i,a.c=o,a.d=function(s,l,u){a.o(s,l)||Object.defineProperty(s,l,{enumerable:!0,get:u})},a.r=function(s){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(s,"__esModule",{value:!0})},a.t=function(s,l){if(l&1&&(s=a(s)),l&8||l&4&&typeof s=="object"&&s&&s.__esModule)return s;var u=Object.create(null);if(a.r(u),Object.defineProperty(u,"default",{enumerable:!0,value:s}),l&2&&typeof s!="string")for(var c in s)a.d(u,c,function(f){return s[f]}.bind(null,c));return u},a.n=function(s){var l=s&&s.__esModule?function(){return s.default}:function(){return s};return a.d(l,"a",l),l},a.o=function(s,l){return Object.prototype.hasOwnProperty.call(s,l)},a.p="",a(a.s="fb15")}({"00ee":function(i,o,a){var s=a("b622"),l=s("toStringTag"),u={};u[l]="z",i.exports=String(u)==="[object z]"},"0366":function(i,o,a){var s=a("1c0b");i.exports=function(l,u,c){if(s(l),u===void 0)return l;switch(c){case 0:return function(){return l.call(u)};case 1:return function(f){return l.call(u,f)};case 2:return function(f,h){return l.call(u,f,h)};case 3:return function(f,h,d){return l.call(u,f,h,d)}}return function(){return l.apply(u,arguments)}}},"057f":function(i,o,a){var s=a("fc6a"),l=a("241c").f,u={}.toString,c=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],f=function(h){try{return l(h)}catch{return c.slice()}};i.exports.f=function(d){return c&&u.call(d)=="[object Window]"?f(d):l(s(d))}},"06cf":function(i,o,a){var s=a("83ab"),l=a("d1e7"),u=a("5c6c"),c=a("fc6a"),f=a("c04e"),h=a("5135"),d=a("0cfb"),p=Object.getOwnPropertyDescriptor;o.f=s?p:function(m,y){if(m=c(m),y=f(y,!0),d)try{return p(m,y)}catch{}if(h(m,y))return u(!l.f.call(m,y),m[y])}},"0cfb":function(i,o,a){var s=a("83ab"),l=a("d039"),u=a("cc12");i.exports=!s&&!l(function(){return Object.defineProperty(u("div"),"a",{get:function(){return 7}}).a!=7})},"13d5":function(i,o,a){var s=a("23e7"),l=a("d58f").left,u=a("a640"),c=a("ae40"),f=u("reduce"),h=c("reduce",{1:0});s({target:"Array",proto:!0,forced:!f||!h},{reduce:function(p){return l(this,p,arguments.length,arguments.length>1?arguments[1]:void 0)}})},"14c3":function(i,o,a){var s=a("c6b6"),l=a("9263");i.exports=function(u,c){var f=u.exec;if(typeof f=="function"){var h=f.call(u,c);if(typeof h!="object")throw TypeError("RegExp exec method returned something other than an Object or null");return h}if(s(u)!=="RegExp")throw TypeError("RegExp#exec called on incompatible receiver");return l.call(u,c)}},"159b":function(i,o,a){var s=a("da84"),l=a("fdbc"),u=a("17c2"),c=a("9112");for(var f in l){var h=s[f],d=h&&h.prototype;if(d&&d.forEach!==u)try{c(d,"forEach",u)}catch{d.forEach=u}}},"17c2":function(i,o,a){var s=a("b727").forEach,l=a("a640"),u=a("ae40"),c=l("forEach"),f=u("forEach");i.exports=!c||!f?function(d){return s(this,d,arguments.length>1?arguments[1]:void 0)}:[].forEach},"1be4":function(i,o,a){var s=a("d066");i.exports=s("document","documentElement")},"1c0b":function(i,o){i.exports=function(a){if(typeof a!="function")throw TypeError(String(a)+" is not a function");return a}},"1c7e":function(i,o,a){var s=a("b622"),l=s("iterator"),u=!1;try{var c=0,f={next:function(){return{done:!!c++}},return:function(){u=!0}};f[l]=function(){return this},Array.from(f,function(){throw 2})}catch{}i.exports=function(h,d){if(!d&&!u)return!1;var p=!1;try{var v={};v[l]=function(){return{next:function(){return{done:p=!0}}}},h(v)}catch{}return p}},"1d80":function(i,o){i.exports=function(a){if(a==null)throw TypeError("Can't call method on "+a);return a}},"1dde":function(i,o,a){var s=a("d039"),l=a("b622"),u=a("2d00"),c=l("species");i.exports=function(f){return u>=51||!s(function(){var h=[],d=h.constructor={};return d[c]=function(){return{foo:1}},h[f](Boolean).foo!==1})}},"23cb":function(i,o,a){var s=a("a691"),l=Math.max,u=Math.min;i.exports=function(c,f){var h=s(c);return h<0?l(h+f,0):u(h,f)}},"23e7":function(i,o,a){var s=a("da84"),l=a("06cf").f,u=a("9112"),c=a("6eeb"),f=a("ce4e"),h=a("e893"),d=a("94ca");i.exports=function(p,v){var m=p.target,y=p.global,g=p.stat,b,T,w,x,R,I;if(y?T=s:g?T=s[m]||f(m,{}):T=(s[m]||{}).prototype,T)for(w in v){if(R=v[w],p.noTargetGet?(I=l(T,w),x=I&&I.value):x=T[w],b=d(y?w:m+(g?".":"#")+w,p.forced),!b&&x!==void 0){if(typeof R==typeof x)continue;h(R,x)}(p.sham||x&&x.sham)&&u(R,"sham",!0),c(T,w,R,p)}}},"241c":function(i,o,a){var s=a("ca84"),l=a("7839"),u=l.concat("length","prototype");o.f=Object.getOwnPropertyNames||function(f){return s(f,u)}},"25f0":function(i,o,a){var s=a("6eeb"),l=a("825a"),u=a("d039"),c=a("ad6d"),f="toString",h=RegExp.prototype,d=h[f],p=u(function(){return d.call({source:"a",flags:"b"})!="/a/b"}),v=d.name!=f;(p||v)&&s(RegExp.prototype,f,function(){var y=l(this),g=String(y.source),b=y.flags,T=String(b===void 0&&y instanceof RegExp&&!("flags"in h)?c.call(y):b);return"/"+g+"/"+T},{unsafe:!0})},"2ca0":function(i,o,a){var s=a("23e7"),l=a("06cf").f,u=a("50c4"),c=a("5a34"),f=a("1d80"),h=a("ab13"),d=a("c430"),p="".startsWith,v=Math.min,m=h("startsWith"),y=!d&&!m&&!!function(){var g=l(String.prototype,"startsWith");return g&&!g.writable}();s({target:"String",proto:!0,forced:!y&&!m},{startsWith:function(b){var T=String(f(this));c(b);var w=u(v(arguments.length>1?arguments[1]:void 0,T.length)),x=String(b);return p?p.call(T,x,w):T.slice(w,w+x.length)===x}})},"2d00":function(i,o,a){var s=a("da84"),l=a("342f"),u=s.process,c=u&&u.versions,f=c&&c.v8,h,d;f?(h=f.split("."),d=h[0]+h[1]):l&&(h=l.match(/Edge\/(\d+)/),(!h||h[1]>=74)&&(h=l.match(/Chrome\/(\d+)/),h&&(d=h[1]))),i.exports=d&&+d},"342f":function(i,o,a){var s=a("d066");i.exports=s("navigator","userAgent")||""},"35a1":function(i,o,a){var s=a("f5df"),l=a("3f8c"),u=a("b622"),c=u("iterator");i.exports=function(f){if(f!=null)return f[c]||f["@@iterator"]||l[s(f)]}},"37e8":function(i,o,a){var s=a("83ab"),l=a("9bf2"),u=a("825a"),c=a("df75");i.exports=s?Object.defineProperties:function(h,d){u(h);for(var p=c(d),v=p.length,m=0,y;v>m;)l.f(h,y=p[m++],d[y]);return h}},"3bbe":function(i,o,a){var s=a("861d");i.exports=function(l){if(!s(l)&&l!==null)throw TypeError("Can't set "+String(l)+" as a prototype");return l}},"3ca3":function(i,o,a){var s=a("6547").charAt,l=a("69f3"),u=a("7dd0"),c="String Iterator",f=l.set,h=l.getterFor(c);u(String,"String",function(d){f(this,{type:c,string:String(d),index:0})},function(){var p=h(this),v=p.string,m=p.index,y;return m>=v.length?{value:void 0,done:!0}:(y=s(v,m),p.index+=y.length,{value:y,done:!1})})},"3f8c":function(i,o){i.exports={}},4160:function(i,o,a){var s=a("23e7"),l=a("17c2");s({target:"Array",proto:!0,forced:[].forEach!=l},{forEach:l})},"428f":function(i,o,a){var s=a("da84");i.exports=s},"44ad":function(i,o,a){var s=a("d039"),l=a("c6b6"),u="".split;i.exports=s(function(){return!Object("z").propertyIsEnumerable(0)})?function(c){return l(c)=="String"?u.call(c,""):Object(c)}:Object},"44d2":function(i,o,a){var s=a("b622"),l=a("7c73"),u=a("9bf2"),c=s("unscopables"),f=Array.prototype;f[c]==null&&u.f(f,c,{configurable:!0,value:l(null)}),i.exports=function(h){f[c][h]=!0}},"44e7":function(i,o,a){var s=a("861d"),l=a("c6b6"),u=a("b622"),c=u("match");i.exports=function(f){var h;return s(f)&&((h=f[c])!==void 0?!!h:l(f)=="RegExp")}},4930:function(i,o,a){var s=a("d039");i.exports=!!Object.getOwnPropertySymbols&&!s(function(){return!String(Symbol())})},"4d64":function(i,o,a){var s=a("fc6a"),l=a("50c4"),u=a("23cb"),c=function(f){return function(h,d,p){var v=s(h),m=l(v.length),y=u(p,m),g;if(f&&d!=d){for(;m>y;)if(g=v[y++],g!=g)return!0}else for(;m>y;y++)if((f||y in v)&&v[y]===d)return f||y||0;return!f&&-1}};i.exports={includes:c(!0),indexOf:c(!1)}},"4de4":function(i,o,a){var s=a("23e7"),l=a("b727").filter,u=a("1dde"),c=a("ae40"),f=u("filter"),h=c("filter");s({target:"Array",proto:!0,forced:!f||!h},{filter:function(p){return l(this,p,arguments.length>1?arguments[1]:void 0)}})},"4df4":function(i,o,a){var s=a("0366"),l=a("7b0b"),u=a("9bdd"),c=a("e95a"),f=a("50c4"),h=a("8418"),d=a("35a1");i.exports=function(v){var m=l(v),y=typeof this=="function"?this:Array,g=arguments.length,b=g>1?arguments[1]:void 0,T=b!==void 0,w=d(m),x=0,R,I,C,S,L,H;if(T&&(b=s(b,g>2?arguments[2]:void 0,2)),w!=null&&!(y==Array&&c(w)))for(S=w.call(m),L=S.next,I=new y;!(C=L.call(S)).done;x++)H=T?u(S,b,[C.value,x],!0):C.value,h(I,x,H);else for(R=f(m.length),I=new y(R);R>x;x++)H=T?b(m[x],x):m[x],h(I,x,H);return I.length=x,I}},"4fad":function(i,o,a){var s=a("23e7"),l=a("6f53").entries;s({target:"Object",stat:!0},{entries:function(c){return l(c)}})},"50c4":function(i,o,a){var s=a("a691"),l=Math.min;i.exports=function(u){return u>0?l(s(u),9007199254740991):0}},5135:function(i,o){var a={}.hasOwnProperty;i.exports=function(s,l){return a.call(s,l)}},5319:function(i,o,a){var s=a("d784"),l=a("825a"),u=a("7b0b"),c=a("50c4"),f=a("a691"),h=a("1d80"),d=a("8aa5"),p=a("14c3"),v=Math.max,m=Math.min,y=Math.floor,g=/\$([$&'`]|\d\d?|<[^>]*>)/g,b=/\$([$&'`]|\d\d?)/g,T=function(w){return w===void 0?w:String(w)};s("replace",2,function(w,x,R,I){var C=I.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE,S=I.REPLACE_KEEPS_$0,L=C?"$":"$0";return[function(k,Y){var D=h(this),K=k==null?void 0:k[w];return K!==void 0?K.call(k,D,Y):x.call(String(D),k,Y)},function(G,k){if(!C&&S||typeof k=="string"&&k.indexOf(L)===-1){var Y=R(x,G,this,k);if(Y.done)return Y.value}var D=l(G),K=String(this),ht=typeof k=="function";ht||(k=String(k));var bt=D.global;if(bt){var W=D.unicode;D.lastIndex=0}for(var ft=[];;){var gt=p(D,K);if(gt===null||(ft.push(gt),!bt))break;var _t=String(gt[0]);_t===""&&(D.lastIndex=d(K,c(D.lastIndex),W))}for(var V="",Z=0,lt=0;lt=Z&&(V+=K.slice(Z,Gt)+N,Z=Gt+ut.length)}return V+K.slice(Z)}];function H(G,k,Y,D,K,ht){var bt=Y+G.length,W=D.length,ft=b;return K!==void 0&&(K=u(K),ft=g),x.call(ht,ft,function(gt,_t){var V;switch(_t.charAt(0)){case"$":return"$";case"&":return G;case"`":return k.slice(0,Y);case"'":return k.slice(bt);case"<":V=K[_t.slice(1,-1)];break;default:var Z=+_t;if(Z===0)return gt;if(Z>W){var lt=y(Z/10);return lt===0?gt:lt<=W?D[lt-1]===void 0?_t.charAt(1):D[lt-1]+_t.charAt(1):gt}V=D[Z-1]}return V===void 0?"":V})}})},5692:function(i,o,a){var s=a("c430"),l=a("c6cd");(i.exports=function(u,c){return l[u]||(l[u]=c!==void 0?c:{})})("versions",[]).push({version:"3.6.5",mode:s?"pure":"global",copyright:"\xA9 2020 Denis Pushkarev (zloirock.ru)"})},"56ef":function(i,o,a){var s=a("d066"),l=a("241c"),u=a("7418"),c=a("825a");i.exports=s("Reflect","ownKeys")||function(h){var d=l.f(c(h)),p=u.f;return p?d.concat(p(h)):d}},"5a34":function(i,o,a){var s=a("44e7");i.exports=function(l){if(s(l))throw TypeError("The method doesn't accept regular expressions");return l}},"5c6c":function(i,o){i.exports=function(a,s){return{enumerable:!(a&1),configurable:!(a&2),writable:!(a&4),value:s}}},"5db7":function(i,o,a){var s=a("23e7"),l=a("a2bf"),u=a("7b0b"),c=a("50c4"),f=a("1c0b"),h=a("65f0");s({target:"Array",proto:!0},{flatMap:function(p){var v=u(this),m=c(v.length),y;return f(p),y=h(v,0),y.length=l(y,v,v,m,0,1,p,arguments.length>1?arguments[1]:void 0),y}})},6547:function(i,o,a){var s=a("a691"),l=a("1d80"),u=function(c){return function(f,h){var d=String(l(f)),p=s(h),v=d.length,m,y;return p<0||p>=v?c?"":void 0:(m=d.charCodeAt(p),m<55296||m>56319||p+1===v||(y=d.charCodeAt(p+1))<56320||y>57343?c?d.charAt(p):m:c?d.slice(p,p+2):(m-55296<<10)+(y-56320)+65536)}};i.exports={codeAt:u(!1),charAt:u(!0)}},"65f0":function(i,o,a){var s=a("861d"),l=a("e8b5"),u=a("b622"),c=u("species");i.exports=function(f,h){var d;return l(f)&&(d=f.constructor,typeof d=="function"&&(d===Array||l(d.prototype))?d=void 0:s(d)&&(d=d[c],d===null&&(d=void 0))),new(d===void 0?Array:d)(h===0?0:h)}},"69f3":function(i,o,a){var s=a("7f9a"),l=a("da84"),u=a("861d"),c=a("9112"),f=a("5135"),h=a("f772"),d=a("d012"),p=l.WeakMap,v,m,y,g=function(C){return y(C)?m(C):v(C,{})},b=function(C){return function(S){var L;if(!u(S)||(L=m(S)).type!==C)throw TypeError("Incompatible receiver, "+C+" required");return L}};if(s){var T=new p,w=T.get,x=T.has,R=T.set;v=function(C,S){return R.call(T,C,S),S},m=function(C){return w.call(T,C)||{}},y=function(C){return x.call(T,C)}}else{var I=h("state");d[I]=!0,v=function(C,S){return c(C,I,S),S},m=function(C){return f(C,I)?C[I]:{}},y=function(C){return f(C,I)}}i.exports={set:v,get:m,has:y,enforce:g,getterFor:b}},"6eeb":function(i,o,a){var s=a("da84"),l=a("9112"),u=a("5135"),c=a("ce4e"),f=a("8925"),h=a("69f3"),d=h.get,p=h.enforce,v=String(String).split("String");(i.exports=function(m,y,g,b){var T=b?!!b.unsafe:!1,w=b?!!b.enumerable:!1,x=b?!!b.noTargetGet:!1;if(typeof g=="function"&&(typeof y=="string"&&!u(g,"name")&&l(g,"name",y),p(g).source=v.join(typeof y=="string"?y:"")),m===s){w?m[y]=g:c(y,g);return}else T?!x&&m[y]&&(w=!0):delete m[y];w?m[y]=g:l(m,y,g)})(Function.prototype,"toString",function(){return typeof this=="function"&&d(this).source||f(this)})},"6f53":function(i,o,a){var s=a("83ab"),l=a("df75"),u=a("fc6a"),c=a("d1e7").f,f=function(h){return function(d){for(var p=u(d),v=l(p),m=v.length,y=0,g=[],b;m>y;)b=v[y++],(!s||c.call(p,b))&&g.push(h?[b,p[b]]:p[b]);return g}};i.exports={entries:f(!0),values:f(!1)}},"73d9":function(i,o,a){var s=a("44d2");s("flatMap")},7418:function(i,o){o.f=Object.getOwnPropertySymbols},"746f":function(i,o,a){var s=a("428f"),l=a("5135"),u=a("e538"),c=a("9bf2").f;i.exports=function(f){var h=s.Symbol||(s.Symbol={});l(h,f)||c(h,f,{value:u.f(f)})}},7839:function(i,o){i.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},"7b0b":function(i,o,a){var s=a("1d80");i.exports=function(l){return Object(s(l))}},"7c73":function(i,o,a){var s=a("825a"),l=a("37e8"),u=a("7839"),c=a("d012"),f=a("1be4"),h=a("cc12"),d=a("f772"),p=">",v="<",m="prototype",y="script",g=d("IE_PROTO"),b=function(){},T=function(C){return v+y+p+C+v+"/"+y+p},w=function(C){C.write(T("")),C.close();var S=C.parentWindow.Object;return C=null,S},x=function(){var C=h("iframe"),S="java"+y+":",L;return C.style.display="none",f.appendChild(C),C.src=String(S),L=C.contentWindow.document,L.open(),L.write(T("document.F=Object")),L.close(),L.F},R,I=function(){try{R=document.domain&&new ActiveXObject("htmlfile")}catch{}I=R?w(R):x();for(var C=u.length;C--;)delete I[m][u[C]];return I()};c[g]=!0,i.exports=Object.create||function(S,L){var H;return S!==null?(b[m]=s(S),H=new b,b[m]=null,H[g]=S):H=I(),L===void 0?H:l(H,L)}},"7dd0":function(i,o,a){var s=a("23e7"),l=a("9ed3"),u=a("e163"),c=a("d2bb"),f=a("d44e"),h=a("9112"),d=a("6eeb"),p=a("b622"),v=a("c430"),m=a("3f8c"),y=a("ae93"),g=y.IteratorPrototype,b=y.BUGGY_SAFARI_ITERATORS,T=p("iterator"),w="keys",x="values",R="entries",I=function(){return this};i.exports=function(C,S,L,H,G,k,Y){l(L,S,H);var D=function(lt){if(lt===G&&ft)return ft;if(!b&< in bt)return bt[lt];switch(lt){case w:return function(){return new L(this,lt)};case x:return function(){return new L(this,lt)};case R:return function(){return new L(this,lt)}}return function(){return new L(this)}},K=S+" Iterator",ht=!1,bt=C.prototype,W=bt[T]||bt["@@iterator"]||G&&bt[G],ft=!b&&W||D(G),gt=S=="Array"&&bt.entries||W,_t,V,Z;if(gt&&(_t=u(gt.call(new C)),g!==Object.prototype&&_t.next&&(!v&&u(_t)!==g&&(c?c(_t,g):typeof _t[T]!="function"&&h(_t,T,I)),f(_t,K,!0,!0),v&&(m[K]=I))),G==x&&W&&W.name!==x&&(ht=!0,ft=function(){return W.call(this)}),(!v||Y)&&bt[T]!==ft&&h(bt,T,ft),m[S]=ft,G)if(V={values:D(x),keys:k?ft:D(w),entries:D(R)},Y)for(Z in V)(b||ht||!(Z in bt))&&d(bt,Z,V[Z]);else s({target:S,proto:!0,forced:b||ht},V);return V}},"7f9a":function(i,o,a){var s=a("da84"),l=a("8925"),u=s.WeakMap;i.exports=typeof u=="function"&&/native code/.test(l(u))},"825a":function(i,o,a){var s=a("861d");i.exports=function(l){if(!s(l))throw TypeError(String(l)+" is not an object");return l}},"83ab":function(i,o,a){var s=a("d039");i.exports=!s(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7})},8418:function(i,o,a){var s=a("c04e"),l=a("9bf2"),u=a("5c6c");i.exports=function(c,f,h){var d=s(f);d in c?l.f(c,d,u(0,h)):c[d]=h}},"861d":function(i,o){i.exports=function(a){return typeof a=="object"?a!==null:typeof a=="function"}},8875:function(i,o,a){var s,l,u;(function(c,f){l=[],s=f,u=typeof s=="function"?s.apply(o,l):s,u!==void 0&&(i.exports=u)})(typeof self!="undefined"?self:this,function(){function c(){var f=Object.getOwnPropertyDescriptor(document,"currentScript");if(!f&&"currentScript"in document&&document.currentScript||f&&f.get!==c&&document.currentScript)return document.currentScript;try{throw new Error}catch(R){var h=/.*at [^(]*\((.*):(.+):(.+)\)$/ig,d=/@([^@]*):(\d+):(\d+)\s*$/ig,p=h.exec(R.stack)||d.exec(R.stack),v=p&&p[1]||!1,m=p&&p[2]||!1,y=document.location.href.replace(document.location.hash,""),g,b,T,w=document.getElementsByTagName("script");v===y&&(g=document.documentElement.outerHTML,b=new RegExp("(?:[^\\n]+?\\n){0,"+(m-2)+"}[^<]*
\ No newline at end of file + + + + + + + + + + + + + + + + + + + Profectus + + + + + + + +
+ + + diff --git a/js/app-legacy.e1809a3d.js b/js/app-legacy.e1809a3d.js deleted file mode 100644 index 67dd571..0000000 --- a/js/app-legacy.e1809a3d.js +++ /dev/null @@ -1,2 +0,0 @@ -(function(){var e={1037:function(e,n,o){"use strict";o.d(n,{b:function(){return r}});var r,t=o(5082),l={variables:{"--foreground":"#dfdfdf","--background":"#0f0f0f","--feature-foreground":"#0f0f0f","--tooltip-background":"rgba(0, 0, 0, 0.75)","--raised-background":"#0f0f0f","--points":"#ffffff","--locked":"#bf8f8f","--highlighted":"#333","--bought":"#77bf5f","--danger":"rgb(220, 53, 69)","--link":"#02f2f2","--outline":"#dfdfdf","--accent1":"#627a82","--accent2":"#658262","--accent3":"#7c6282","--border-radius":"15px","--modal-border":"solid 2px var(--color)","--feature-margin":"0px"},floatingTabs:!0,mergeAdjacent:!0,showPin:!0};(function(e){e["Classic"]="classic",e["Paper"]="paper",e["Nordic"]="nordic",e["Aqua"]="aqua"})(r||(r={})),n["Z"]={classic:l,paper:(0,t.Z)((0,t.Z)({},l),{},{variables:(0,t.Z)((0,t.Z)({},l.variables),{},{"--background":"#2a323d","--feature-foreground":"#000","--raised-background":"#333c4a","--locked":"#3a3e45","--bought":"#5C8A58","--outline":"#333c4a","--border-radius":"4px","--modal-border":"","--feature-margin":"5px"}),floatingTabs:!1}),nordic:(0,t.Z)((0,t.Z)({},l),{},{variables:(0,t.Z)((0,t.Z)({},l.variables),{},{"--foreground":"#D8DEE9","--background":"#2E3440","--feature-foreground":"#000","--raised-background":"#3B4252","--points":"#E5E9F0","--locked":"#4c566a","--highlighted":"#434c5e","--bought":"#8FBCBB","--danger":"#D08770","--link":"#88C0D0","--outline":"#3B4252","--accent1":"#B48EAD","--accent2":"#A3BE8C","--accent3":"#EBCB8B","--border-radius":"4px","--modal-border":"solid 2px #3B4252","--feature-margin":"5px"}),floatingTabs:!1}),aqua:(0,t.Z)((0,t.Z)({},l),{},{variables:(0,t.Z)((0,t.Z)({},l.variables),{},{"--foreground":"#bfdfff","--background":"#001f3f","--tooltip-background":"rgba(0, 15, 31, 0.75)","--raised-background":"#001f3f","--points":"#dfefff","--locked":"#c4a7b3","--outline":"#bfdfff"})})}},6113:function(e,n,o){"use strict";o.d(n,{wA:function(){return a},tj:function(){return f},QI:function(){return s},EE:function(){return r},tZ:function(){return m},Kf:function(){return d},Rh:function(){return y},bD:function(){return v}});var r,t=o(3336),l=(o(2526),o(1817),o(1539),o(4747),o(7941),o(6699),o(2023),o(5613)),i=o(9583),u=o(4865),a=Symbol("Component"),f=Symbol("GatherProps"),c=0;function s(){var e=arguments,n=function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](0):e.length>0}()&&function(){return void 0!==e[0]&&null!==e[0]&&e[0][Symbol.for("!==")]?e[0][Symbol.for("!==")](void 0):void 0!==e[0]}()?arguments[0]:"feature-";return function(){return void 0!==n&&null!==n&&n[Symbol.for("+")]?n[Symbol.for("+")](c++):n+c++}()}function m(e){return e[i.mM]=!0,e}function d(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:r.None;return e?r.Visible:o}function y(e,n,o){void 0===e[n]&&function(){return void 0!==o&&null!==o&&o[Symbol.for("!=")]?o[Symbol.for("!=")](void 0):void 0!=o}()&&(e[n]=o)}function v(e){for(var n=arguments.length,o=new Array(function(){return void 0!==n&&null!==n&&n[Symbol.for(">")]?n[Symbol.for(">")](1):n>1}()?function(){return void 0!==n&&null!==n&&n[Symbol.for("-")]?n[Symbol.for("-")](1):n-1}():0),r=1;function(){return void 0!==r&&null!==r&&r[Symbol.for("<")]?r[Symbol.for("<")](n):r")]?c.Z.lastTenTicks.length[Symbol.for(">")](10):c.Z.lastTenTicks.length>10}()&&(c.Z.lastTenTicks=c.Z.lastTenTicks.slice(1)),!(function(){return void 0!==(e=d)&&null!==(e=d)&&(e=d)[Symbol.for("!==")]?(e=d)[Symbol.for("!==")](null):null!==(e=d)}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()&&e.value&&function(){return void 0!==a.Z.keepGoing&&null!==a.Z.keepGoing&&a.Z.keepGoing[Symbol.for("!")]?a.Z.keepGoing[Symbol.for("!")]():!a.Z.keepGoing}())&&!c.Z.hasNaN&&(o=Math.max(o,0),0!==a.Z.devSpeed)){if(function(){return void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("!=")]?a.Z.offlineTime[Symbol.for("!=")](void 0):void 0!=a.Z.offlineTime}()){if(l.ZP.gt(a.Z.offlineTime,function(){return void 0!==t.offlineLimit&&null!==t.offlineLimit&&t.offlineLimit[Symbol.for("*")]?t.offlineLimit[Symbol.for("*")](3600):3600*t.offlineLimit}())&&(a.Z.offlineTime=function(){return void 0!==t.offlineLimit&&null!==t.offlineLimit&&t.offlineLimit[Symbol.for("*")]?t.offlineLimit[Symbol.for("*")](3600):3600*t.offlineLimit}()),l.ZP.gt(a.Z.offlineTime,0)&&function(){return void 0!==a.Z.devSpeed&&null!==a.Z.devSpeed&&a.Z.devSpeed[Symbol.for("!==")]?a.Z.devSpeed[Symbol.for("!==")](0):0!==a.Z.devSpeed}()){var i=Math.max(function(){return void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("/")]?a.Z.offlineTime[Symbol.for("/")](10):a.Z.offlineTime/10}(),o);a.Z.offlineTime=function(){return void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("-")]?a.Z.offlineTime[Symbol.for("-")](i):a.Z.offlineTime-i}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](i):o+i}()}else 0===a.Z.devSpeed&&(a.Z.offlineTime=function(){return void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("+")]?a.Z.offlineTime[Symbol.for("+")](o):a.Z.offlineTime+o}());(function(){return void 0!==a.Z.offlineProd&&null!==a.Z.offlineProd&&a.Z.offlineProd[Symbol.for("!")]?a.Z.offlineProd[Symbol.for("!")]():!a.Z.offlineProd}()||l.ZP.lt(a.Z.offlineTime,0))&&(a.Z.offlineTime=null)}o=Math.min(o,t.maxTickLength),function(){return void 0!==a.Z.devSpeed&&null!==a.Z.devSpeed&&a.Z.devSpeed[Symbol.for("!=")]?a.Z.devSpeed[Symbol.for("!=")](void 0):void 0!=a.Z.devSpeed}()&&(o=function(){return void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](a.Z.devSpeed):o*a.Z.devSpeed}()),function(){return void 0!==Number.isFinite(o)&&null!==Number.isFinite(o)&&Number.isFinite(o)[Symbol.for("!")]?Number.isFinite(o)[Symbol.for("!")]():!Number.isFinite(o)}()&&(o=1e308),l.ZP.eq(o,0)||(a.Z.timePlayed=function(){return void 0!==a.Z.timePlayed&&null!==a.Z.timePlayed&&a.Z.timePlayed[Symbol.for("+")]?a.Z.timePlayed[Symbol.for("+")](o):a.Z.timePlayed+o}(),function(){return void 0!==Number.isFinite(a.Z.timePlayed)&&null!==Number.isFinite(a.Z.timePlayed)&&Number.isFinite(a.Z.timePlayed)[Symbol.for("!")]?Number.isFinite(a.Z.timePlayed)[Symbol.for("!")]():!Number.isFinite(a.Z.timePlayed)}()&&(a.Z.timePlayed=1e308),s.emit("update",o,r),f.ZP.unthrottled?(requestAnimationFrame(y),function(){return void 0!==m&&null!==m&&m[Symbol.for("!=")]?m[Symbol.for("!=")](null):null!=m}()&&(clearInterval(m),m=null)):function(){return void 0!==m&&null!==m&&m[Symbol.for("==")]?m[Symbol.for("==")](null):null==m}()&&(m=setInterval(y,50)))}}function v(){return b.apply(this,arguments)}function b(){return b=(0,r.Z)(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Promise.resolve().then(o.bind(o,504));case 2:d=e.sent.hasWon,(0,u.watch)(d,(function(e){e&&s.emit("gameWon")})),f.ZP.unthrottled?requestAnimationFrame(y):m=setInterval(y,50);case 5:case"end":return e.stop()}}),e)}))),b.apply(this,arguments)}},4061:function(e,n,o){"use strict";o.d(n,{n9:function(){return s},nY:function(){return m},ax:function(){return b}});var r=o(9584),t=o(3336),l=(o(2526),o(1817),o(1539),o(1703),o(9600),o(1249),o(7042),o(4916),o(3123),o(3210),o(4747),o(7941),o(6699),o(2222),o(7302)),i=o(5613),u=o(3273),a=o(3577),f=o(4865),c=o(9365),s=Symbol("PersistentState"),m=Symbol("DefaultValue"),d=Symbol("StackTrace"),y=Symbol("Deleted");function v(){var e;return(null===(e=(new Error).stack)||void 0===e?void 0:e.split("\n").slice(3,5).map((function(e){return e.trim()})).join("\n"))||""}function b(e){var n=(0,f.isRef)(e)?e:(0,f.ref)(e);return n[s]=n,n[m]=(0,f.isRef)(e)?e.value:e,n[d]=v(),n[y]=!1,0===c.addingLayers.length?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",n,function(){return"\nCreated at:\n"[Symbol.for("+")]?"\nCreated at:\n"[Symbol.for("+")](n[d]):"\nCreated at:\n"+n[d]}()):c.persistentRefs[c.addingLayers[function(){return void 0!==c.addingLayers.length&&null!==c.addingLayers.length&&c.addingLayers.length[Symbol.for("-")]?c.addingLayers.length[Symbol.for("-")](1):c.addingLayers.length-1}()]].add(n),n}l.globalBus.on("addLayer",(function(e,n){var o=[],l=function l(v){var b=arguments,S=function(){return void 0!==b.length&&null!==b.length&&b.length[Symbol.for(">")]?b.length[Symbol.for(">")](1):b.length>1}()&&function(){return void 0!==b[1]&&null!==b[1]&&b[1][Symbol.for("!==")]?b[1][Symbol.for("!==")](void 0):void 0!==b[1]}()?arguments[1]:[],g=!1;return Object.keys(v).forEach((function(b){var p=v[b];if(p&&"object"===(0,t.Z)(p))if(function(){return void 0!==s&&null!==s&&s[Symbol.for("in")]?s[Symbol.for("in")](p):s in p}()){if(g=!0,p[y])return void console.warn("Deleted persistent ref present in returned object. Ignoring...",p,function(){return"\nCreated at:\n"[Symbol.for("+")]?"\nCreated at:\n"[Symbol.for("+")](p[d]):"\nCreated at:\n"+p[d]}());c.persistentRefs[e.id].delete(function(){return void 0!==u.Le&&null!==u.Le&&u.Le[Symbol.for("in")]?u.Le[Symbol.for("in")](p):u.Le in p}()?p[u.Le]:p);var h=S.reduce((function(e,n){return function(){return n in e!==void 0&&n in e!==null&&(n in e)[Symbol.for("!")]?(n in e)[Symbol.for("!")]():!(n in e)}()&&(e[n]={}),e[n]}),n),N=h[b];h[b]=p[s],(0,f.isReactive)(h)?!function(){return void 0!==N&&null!==N&&N[Symbol.for("!=")]?N[Symbol.for("!=")](null):null!=N}()?h[b]=p[m]:h[b]=N:!function(){return void 0!==N&&null!==N&&N[Symbol.for("!=")]?N[Symbol.for("!=")](null):null!=N}()?h[b].value=p[m]:h[b].value=N}else if(function(){return p instanceof i.ZP!==void 0&&p instanceof i.ZP!==null&&(p instanceof i.ZP)[Symbol.for("!")]?(p instanceof i.ZP)[Symbol.for("!")]():!(p instanceof i.ZP)}()&&function(){return void 0!==(0,f.isRef)(p)&&null!==(0,f.isRef)(p)&&(0,f.isRef)(p)[Symbol.for("!")]?(0,f.isRef)(p)[Symbol.for("!")]():!(0,f.isRef)(p)}()&&function(){return void 0!==o.includes(p)&&null!==o.includes(p)&&o.includes(p)[Symbol.for("!")]?o.includes(p)[Symbol.for("!")]():!o.includes(p)}()){"symbol"===(0,t.Z)(p.type)&&o.push(p);var k=l(p,[].concat((0,r.Z)(S),[b]));k&&((0,a.kJ)(p)&&function(){return void 0!==(0,a.kJ)(v)&&null!==(0,a.kJ)(v)&&(0,a.kJ)(v)[Symbol.for("!")]?(0,a.kJ)(v)[Symbol.for("!")]():!(0,a.kJ)(v)}()?console.warn("Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.",function(){return void 0!==u.Le&&null!==u.Le&&u.Le[Symbol.for("in")]?u.Le[Symbol.for("in")](v):u.Le in v}()?v[u.Le]:v,b):g=!0)}})),g};l(e),c.persistentRefs[e.id].forEach((function(n){console.error("Created persistent ref in ".concat(e.id," without registering it to the layer! Make sure to include everything persistent in the returned object"),n,function(){return"\nCreated at:\n"[Symbol.for("+")]?"\nCreated at:\n"[Symbol.for("+")](n[d]):"\nCreated at:\n"+n[d]}())})),c.persistentRefs[e.id].clear()}))},5967:function(e,n,o){"use strict";o.d(n,{U:function(){return m}});var r,t=o(2482),l=o(9584),i=(o(2526),o(1817),o(1539),o(8862),o(2222),o(7556),o(1299),o(4858),o(5003),o(5613)),u=o(1349),a=o(3273),f=o(4865),c=o(3032),s=(0,f.reactive)({id:"",devSpeed:null,name:"",tabs:[],time:function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),autosave:!0,offlineProd:!0,offlineTime:null,timePlayed:0,keepGoing:!1,modID:"",modVersion:"",layers:{}});function m(e){return JSON.stringify(e,(function(e,n){return(0,f.unref)(n)}))}var d={get:function(e,n){if(n===a.Le||n===a.c4)return e[n];var o=e[a.Le][n];if(function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")]("value"):"value"!==n}()&&((0,u.PO)(o)||Array.isArray(o))&&function(){return o instanceof i.ZP!==void 0&&o instanceof i.ZP!==null&&(o instanceof i.ZP)[Symbol.for("!")]?(o instanceof i.ZP)[Symbol.for("!")]():!(o instanceof i.ZP)}()){if(function(){var r,t;return void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](null===(r=e[n])||void 0===r?void 0:r[a.Le]):o!==(null===(t=e[n])||void 0===t?void 0:t[a.Le])}()){var r,f=[].concat((0,l.Z)(e[a.c4]),[n]);e[n]=new Proxy((r={},(0,t.Z)(r,a.Le,o),(0,t.Z)(r,a.c4,f),r),d)}return e[n]}return o},set:function(e,n,o,r){if(function(){return void 0!==c.Z.hasNaN&&null!==c.Z.hasNaN&&c.Z.hasNaN[Symbol.for("!")]?c.Z.hasNaN[Symbol.for("!")]():!c.Z.hasNaN}()&&("number"===typeof o&&isNaN(o)||o instanceof i.ZP&&(isNaN(o.sign)||isNaN(o.layer)||isNaN(o.mag)))){var t=e[a.Le][n];if(function(){return void 0!==("number"===typeof t&&isNaN(t)||t instanceof i.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))&&null!==("number"===typeof t&&isNaN(t)||t instanceof i.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))&&("number"===typeof t&&isNaN(t)||t instanceof i.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))[Symbol.for("!")]?("number"===typeof t&&isNaN(t)||t instanceof i.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))[Symbol.for("!")]():!("number"===typeof t&&isNaN(t)||t instanceof i.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))}())throw s.autosave=!1,c.Z.hasNaN=!0,c.Z.NaNPath=[].concat((0,l.Z)(e[a.c4]),[n]),c.Z.NaNReceiver=r,console.error("Attempted to set NaN value",[].concat((0,l.Z)(e[a.c4]),[n]),e[a.Le]),"Attempted to set NaN value. See above for details"}return e[a.Le][n]=o,!0},ownKeys:function(e){return Reflect.ownKeys(e[a.Le])},has:function(e,n){return Reflect.has(e[a.Le],n)},getOwnPropertyDescriptor:function(e,n){return Object.getOwnPropertyDescriptor(e[a.Le],n)}};n["Z"]=window.player=new Proxy((r={},(0,t.Z)(r,a.Le,s),(0,t.Z)(r,a.c4,["player"]),r),d)},9266:function(e,n,o){"use strict";o.d(n,{ri:function(){return m},V$:function(){return d},QV:function(){return y},II:function(){return v},fw:function(){return b},t:function(){return S}});var r=o(3336),t=(o(8862),o(2526),o(1817),o(1539),o(7714),o(2801),o(1174),o(6453)),l=o(1037),i=o(7302),u=o(6961),a=o.n(u),f=o(463),c=o(4865),s=(0,c.reactive)({active:"",saves:[],showTPS:!0,theme:l.b.Nordic,unthrottled:!1});function m(){try{var e=localStorage.getItem(t.id);if(function(){return void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](""):""!==e}()){if("{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])return void console.warn("Unable to determine settings encoding",e);e=a().decompressFromUTF16(e)}var n=JSON.parse(e);"object"===(0,r.Z)(n)&&Object.assign(s,n)}i.globalBus.emit("loadSettings",s)}catch(o){}}(0,c.watch)(s,(function(e){var n=a().compressToUTF16(JSON.stringify(e));localStorage.setItem(t.id,n)}),{deep:!0}),n["ZP"]=window.settings=s;window.hardResetSettings=function(){var e={active:"",saves:[],showTPS:!0,theme:l.b.Nordic};i.globalBus.emit("loadSettings",e),Object.assign(s,e),(0,f.y6)()};var d=(0,c.reactive)([]);function y(e){d.push(e)}var v=(0,c.reactive)([]);function b(e){v.push(e)}var S=(0,c.reactive)([])},3032:function(e,n,o){"use strict";var r=o(4865);n["Z"]=window.state=(0,r.shallowReactive)({lastTenTicks:[],hasNaN:!1,NaNPath:[]})},7964:function(e,n,o){"use strict";var r=o(8534),t=(o(6992),o(8674),o(9601),o(7727),o(5666),o(4865)),l=(o(1249),o(6113)),i=o(1604),u=(o(7941),o(8309),o(2526),o(1817),o(1539),o(6699),o(2023),o(6453)),a=o(9365),f=o(5967);function c(e,n,o,r,l,i){var u=(0,t.resolveComponent)("Context");return(0,t.openBlock)(),(0,t.createElementBlock)("div",{class:"layer-container",style:(0,t.normalizeStyle)({"--layer-color":e.unref(e.color)})},[e.showGoBack?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:0,class:"goBack",onClick:n[0]||(n[0]=function(){return e.goBack&&e.goBack.apply(e,arguments)})},"←")):(0,t.createCommentVNode)("",!0),e.minimized.value?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:1,class:"layer-tab minimized",onClick:n[1]||(n[1]=function(n){return e.minimized.value=!1})},[(0,t.createElementVNode)("div",null,(0,t.toDisplayString)(e.unref(e.name)),1)])):((0,t.openBlock)(),(0,t.createElementBlock)("div",{key:2,class:(0,t.normalizeClass)(["layer-tab",{showGoBack:e.showGoBack}])},[(0,t.createVNode)(u,{onUpdateNodes:e.updateNodes},{default:(0,t.withCtx)((function(){return[((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)(e.component)))]})),_:1},8,["onUpdateNodes"])],2)),e.unref(e.minimizable)?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:3,class:"minimize",onClick:n[2]||(n[2]=function(n){return e.minimized.value=!0})}," ▼ ")):(0,t.createCommentVNode)("",!0)],4)}var s=o(6084),m=(o(9653),o(561),o(4048),o(3363)),d=(0,t.defineComponent)({components:{Context:m.Z},props:{index:{type:Number,required:!0},tab:{type:Function,required:!0},display:{type:(0,i.P5)(Object,String,Function),required:!0},minimized:{type:Object,required:!0},minWidth:{type:(0,i.P5)(Number,String),required:!0},name:{type:(0,i.P5)(String),required:!0},color:(0,i.P5)(String),minimizable:(0,i.P5)(Boolean),nodes:{type:Object,required:!0}},setup:function(e){var n=(0,t.toRefs)(e),o=n.display,r=n.index,l=n.minimized,a=n.minWidth,c=n.tab,m=(0,i.vq)(o),d=(0,t.computed)((function(){return u.allowGoBack&&function(){return void 0!==r.value&&null!==r.value&&r.value[Symbol.for(">")]?r.value[Symbol.for(">")](0):r.value>0}()&&function(){return void 0!==l.value&&null!==l.value&&l.value[Symbol.for("!")]?l.value[Symbol.for("!")]():!l.value}()}));function y(){f.Z.tabs.splice((0,t.unref)(e.index),1/0)}function v(n){e.nodes.value=n}function b(e,n){var o="number"===typeof n||Number.isNaN(parseInt(n))?function(){return void 0!==n&&null!==n&&n[Symbol.for("+")]?n[Symbol.for("+")]("px"):n+"px"}():n,r=c.value();(function(){return void 0!==r&&null!==r&&r[Symbol.for("!=")]?r[Symbol.for("!=")](void 0):void 0!=r})()&&(e?(r.style.flexGrow="0",r.style.flexShrink="0",r.style.width="60px",r.style.minWidth=r.style.flexBasis="",r.style.margin="0"):(r.style.flexGrow="",r.style.flexShrink="",r.style.width="",r.style.minWidth=r.style.flexBasis=o,r.style.margin=""))}return(0,t.nextTick)((function(){return b(l.value,(0,t.unref)(a.value))})),(0,t.watch)([l,(0,i.o9)(a)],(function(e){var n=(0,s.Z)(e,2),o=n[0],r=n[1];return b(o,r)})),{component:m,showGoBack:d,updateNodes:v,unref:t.unref,goBack:y}}}),y=o(3744);const v=(0,y.Z)(d,[["render",c],["__scopeId","data-v-e18f60b6"]]);var b=v,S=o(6948),g=function(e){return(0,t.pushScopeId)("data-v-5f8298e6"),e=e(),(0,t.popScopeId)(),e},p=g((function(){return(0,t.createElementVNode)("h2",null,"Changelog",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),h=g((function(){return(0,t.createElementVNode)("details",{open:""},[(0,t.createElementVNode)("summary",null,[(0,t.createTextVNode)("v0.0 Initial Commit - "),(0,t.createElementVNode)("time",null,"2021-09-04")]),(0,t.createTextVNode)(" This is the first release :D "),(0,t.createElementVNode)("ul",null,[(0,t.createElementVNode)("li",{class:"feature"},"Did everything"),(0,t.createElementVNode)("li",{class:"fix"},"Had some fun"),(0,t.createElementVNode)("li",{class:"breaking"},"Removed everything"),(0,t.createElementVNode)("li",{class:"balancing"},"Created some bugs to fix later")])],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),N=(0,t.defineComponent)({setup:function(e,n){var o=n.expose,r=(0,t.ref)(!1);return o({open:function(){r.value=!0}}),function(e,n){return(0,t.openBlock)(),(0,t.createBlock)(S.Z,{modelValue:r.value,"onUpdate:modelValue":n[0]||(n[0]=function(e){return r.value=e})},{header:(0,t.withCtx)((function(){return[p]})),body:(0,t.withCtx)((function(){return[h]})),_:1},8,["modelValue"])}}});const k=(0,y.Z)(N,[["__scopeId","data-v-5f8298e6"]]);var V=k,x=o(9266),M=o(5613),C=function(e){return(0,t.pushScopeId)("data-v-3eb46986"),e=e(),(0,t.popScopeId)(),e},Z={class:"info-modal-header"},w=["src","alt"],B={class:"info-modal-title"},P={key:0},E={key:0},F={key:0},T=C((function(){return(0,t.createElementVNode)("div",null," Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb ",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),D=C((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),I=C((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),R=["href"],_=C((function(){return(0,t.createElementVNode)("span",{class:"material-icons info-modal-discord"},"discord",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),O=C((function(){return(0,t.createElementVNode)("div",null,[(0,t.createElementVNode)("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[(0,t.createElementVNode)("span",{class:"material-icons info-modal-discord"},"discord"),(0,t.createTextVNode)(" The Paper Pilot Community ")])],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),U=C((function(){return(0,t.createElementVNode)("div",null,[(0,t.createElementVNode)("a",{href:"https://discord.gg/F3xveHV",class:"info-modal-discord-link"},[(0,t.createElementVNode)("span",{class:"material-icons info-modal-discord"},"discord"),(0,t.createTextVNode)(" The Modding Tree ")])],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),j=C((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),A=(0,t.defineComponent)({props:{changelog:null},setup:function(e,n){var o=n.expose,r=e,a=u.title,c=u.logo,s=u.author,m=u.discordName,d=u.discordLink,y=u.versionNumber,v=u.versionTitle,b=(0,t.toRefs)(r),g=(0,t.ref)(!1),p=(0,t.computed)((function(){return(0,M.mr)(f.Z.timePlayed)})),h=(0,t.computed)((function(){return(0,i.MM)((0,l.tZ)((function(){return(0,t.createVNode)(t.Fragment,null,[x.II.map(i.sY)])})))}));function N(){var e;null===(e=(0,t.unref)(b.changelog))||void 0===e||e.open()}return o({open:function(){g.value=!0}}),function(e,n){return(0,t.openBlock)(),(0,t.createBlock)(S.Z,{modelValue:g.value,"onUpdate:modelValue":n[0]||(n[0]=function(e){return g.value=e})},{header:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("div",Z,[(0,t.unref)(c)?((0,t.openBlock)(),(0,t.createElementBlock)("img",{key:0,class:"info-modal-logo",src:(0,t.unref)(c),alt:(0,t.unref)(a)},null,8,w)):(0,t.createCommentVNode)("",!0),(0,t.createElementVNode)("div",B,[(0,t.createElementVNode)("h2",null,(0,t.toDisplayString)((0,t.unref)(a)),1),(0,t.createElementVNode)("h4",null,[(0,t.createTextVNode)(function(){return" v"[Symbol.for("+")]?" v"[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(y))):" v"+(0,t.toDisplayString)((0,t.unref)(y))}(),1),(0,t.unref)(v)?((0,t.openBlock)(),(0,t.createElementBlock)("span",P,function(){return": "[Symbol.for("+")]?": "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(v))):": "+(0,t.toDisplayString)((0,t.unref)(v))}(),1)):(0,t.createCommentVNode)("",!0)])])])]})),body:(0,t.withCtx)((function(e){var n=e.shown;return[n?((0,t.openBlock)(),(0,t.createElementBlock)("div",E,[(0,t.unref)(s)?((0,t.openBlock)(),(0,t.createElementBlock)("div",F,function(){return"By "[Symbol.for("+")]?"By "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(s))):"By "+(0,t.toDisplayString)((0,t.unref)(s))}(),1)):(0,t.createCommentVNode)("",!0),T,D,(0,t.createElementVNode)("div",{class:"link",onClick:N},"Changelog"),I,(0,t.createElementVNode)("div",null,[function(){return void 0!==(0,t.unref)(d)&&null!==(0,t.unref)(d)&&(0,t.unref)(d)[Symbol.for("!==")]?(0,t.unref)(d)[Symbol.for("!==")]("https://discord.gg/WzejVAx"):"https://discord.gg/WzejVAx"!==(0,t.unref)(d)}()?((0,t.openBlock)(),(0,t.createElementBlock)("a",{key:0,href:(0,t.unref)(d),class:"info-modal-discord-link"},[_,(0,t.createTextVNode)(function(){return" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(m))):" "+(0,t.toDisplayString)((0,t.unref)(m))}(),1)],8,R)):(0,t.createCommentVNode)("",!0)]),O,U,j,(0,t.createElementVNode)("div",null,function(){return"Time Played: "[Symbol.for("+")]?"Time Played: "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(p))):"Time Played: "+(0,t.toDisplayString)((0,t.unref)(p))}(),1),((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)((0,t.unref)(h))))])):(0,t.createCommentVNode)("",!0)]})),_:1},8,["modelValue"])}}});const q=(0,y.Z)(A,[["__scopeId","data-v-3eb46986"]]);var z=q,L=o(1037),G=o(1349),H=o(5418),W=o(9868),Y=o(6055),K=function(e){return(0,t.pushScopeId)("data-v-85d7ae40"),e=e(),(0,t.popScopeId)(),e},Q=K((function(){return(0,t.createElementVNode)("div",{class:"header"},[(0,t.createElementVNode)("h2",null,"Options")],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),J=K((function(){return(0,t.createElementVNode)("hr",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),$=(0,t.defineComponent)({setup:function(e,n){var o=n.expose,r=(0,t.ref)(!1);o({open:function(){r.value=!0}});var a=Object.keys(L.Z).map((function(e){return{label:(0,G.IJ)(e),value:e}})),c=(0,t.computed)((function(){return(0,i.MM)((0,l.tZ)((function(){return(0,t.createVNode)(t.Fragment,null,[x.V$.map(i.sY)])})))})),s=(0,t.toRefs)(x.ZP),m=s.showTPS,d=s.theme,y=s.unthrottled,v=(0,t.toRefs)(f.Z),b=v.autosave,g=v.offlineProd,p=(0,t.computed)({get:function(){return 0===f.Z.devSpeed},set:function(e){f.Z.devSpeed=e?0:null}}),h=(0,l.tZ)((function(){return(0,t.createVNode)("span",null,[(0,t.createTextVNode)("Offline Production"),(0,t.createVNode)(Y.Z,{display:"Save-specific"},{default:function(){return[(0,t.createTextVNode)("*")]}})])})),N=(0,l.tZ)((function(){return(0,t.createVNode)("span",null,[(0,t.createTextVNode)("Autosave"),(0,t.createVNode)(Y.Z,{display:"Save-specific"},{default:function(){return[(0,t.createTextVNode)("*")]}})])})),k=(0,l.tZ)((function(){return(0,t.createVNode)("span",null,[(0,t.createTextVNode)("Pause game"),(0,t.createVNode)(Y.Z,{display:"Save-specific"},{default:function(){return[(0,t.createTextVNode)("*")]}})])}));return function(e,n){return(0,t.openBlock)(),(0,t.createBlock)(S.Z,{modelValue:r.value,"onUpdate:modelValue":n[6]||(n[6]=function(e){return r.value=e})},{header:(0,t.withCtx)((function(){return[Q]})),body:(0,t.withCtx)((function(){return[(0,t.createVNode)(H.Z,{title:"Theme",options:(0,t.unref)(a),modelValue:(0,t.unref)(d),"onUpdate:modelValue":n[0]||(n[0]=function(e){return(0,t.isRef)(d)?d.value=e:null})},null,8,["options","modelValue"]),((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)((0,t.unref)(c)))),(0,t.createVNode)(W.Z,{title:"Show TPS",modelValue:(0,t.unref)(m),"onUpdate:modelValue":n[1]||(n[1]=function(e){return(0,t.isRef)(m)?m.value=e:null})},null,8,["modelValue"]),J,(0,t.createVNode)(W.Z,{title:"Unthrottled",modelValue:(0,t.unref)(y),"onUpdate:modelValue":n[2]||(n[2]=function(e){return(0,t.isRef)(y)?y.value=e:null})},null,8,["modelValue"]),(0,t.createVNode)(W.Z,{title:(0,t.unref)(h),modelValue:(0,t.unref)(g),"onUpdate:modelValue":n[3]||(n[3]=function(e){return(0,t.isRef)(g)?g.value=e:null})},null,8,["title","modelValue"]),(0,t.createVNode)(W.Z,{title:(0,t.unref)(N),modelValue:(0,t.unref)(b),"onUpdate:modelValue":n[4]||(n[4]=function(e){return(0,t.isRef)(b)?b.value=e:null})},null,8,["title","modelValue"]),(0,t.unref)(u).enablePausing?((0,t.openBlock)(),(0,t.createBlock)(W.Z,{key:0,title:(0,t.unref)(k),modelValue:(0,t.unref)(p),"onUpdate:modelValue":n[5]||(n[5]=function(e){return(0,t.isRef)(p)?p.value=e:null})},null,8,["title","modelValue"])):(0,t.createCommentVNode)("",!0)]})),_:1},8,["modelValue"])}}});const X=(0,y.Z)($,[["__scopeId","data-v-85d7ae40"]]);var ee=X,ne=o(5082),oe=o(3336),re=(o(7714),o(2801),o(1174),o(3948),o(7042),o(2222),o(4747),o(8862),o(7327),o(463)),te=o(4520),le={key:0},ie=["onClick","disabled"],ue={key:0},ae=["onClick"],fe=(0,t.defineComponent)({props:{disabled:{type:Boolean},skipConfirm:{type:Boolean}},emits:["click","confirmingChanged"],setup:function(e,n){var o=n.emit,r=e,l=(0,t.toRefs)(r),i=(0,t.ref)(!1);function u(){(0,t.unref)(l.skipConfirm)?o("click"):(i.value&&o("click"),i.value=function(){return void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!")]?i.value[Symbol.for("!")]():!i.value}())}function a(){i.value=!1}return(0,t.watch)(i,(function(e){o("confirmingChanged",e)})),function(n,o){return(0,t.openBlock)(),(0,t.createElementBlock)("span",{class:(0,t.normalizeClass)(["container",{confirming:i.value}])},[i.value?((0,t.openBlock)(),(0,t.createElementBlock)("span",le,"Are you sure?")):(0,t.createCommentVNode)("",!0),(0,t.createElementVNode)("button",{onClick:(0,t.withModifiers)(u,["stop"]),class:"button danger",disabled:e.disabled},[i.value?((0,t.openBlock)(),(0,t.createElementBlock)("span",ue,"Yes")):(0,t.renderSlot)(n.$slots,"default",{key:1})],8,ie),i.value?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:1,class:"button",onClick:(0,t.withModifiers)(a,["stop"])},"No",8,ae)):(0,t.createCommentVNode)("",!0)],2)}}});const ce=(0,y.Z)(fe,[["__scopeId","data-v-bf59fca4"]]);var se=ce,me=["onClick"],de=(0,t.defineComponent)({props:{left:{type:Boolean}},emits:["click"],setup:function(e,n){var o=n.emit,r=(0,t.ref)(!1),l=(0,t.ref)(null);function i(){o("click"),l.value&&clearTimeout(l.value),r.value=!1,(0,t.nextTick)((function(){r.value=!0,l.value=setTimeout((function(){return r.value=!1}),500)}))}return function(n,o){return(0,t.openBlock)(),(0,t.createElementBlock)("button",{onClick:(0,t.withModifiers)(i,["stop"]),class:(0,t.normalizeClass)(["feedback",{activated:r.value,left:e.left}])},[(0,t.renderSlot)(n.$slots,"default")],10,me)}}});const ye=(0,y.Z)(de,[["__scopeId","data-v-5bbcedd3"]]);var ve=ye,be=function(e){return(0,t.pushScopeId)("data-v-335ce270"),e=e(),(0,t.popScopeId)(),e},Se=be((function(){return(0,t.createElementVNode)("div",{class:"handle material-icons"},"drag_handle",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),ge={key:0,class:"actions"},pe=be((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"content_paste",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),he=be((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"content_copy",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Ne=be((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"edit",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),ke=be((function(){return(0,t.createElementVNode)("span",{class:"material-icons",style:{margin:"-2px"}},"delete",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Ve={key:1,class:"actions"},xe=be((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"check",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Me=be((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"close",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Ce={key:2,class:"details"},Ze={class:"save-version"},we=be((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Be={key:0},Pe={key:3,class:"details"},Ee={key:4,class:"details error"},Fe=be((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Te=(0,t.defineComponent)({props:{save:null},emits:["export","open","duplicate","delete","editName"],setup:function(e,n){var o=n.emit,r=e,l=(0,t.toRefs)(r),i=l.save,u=new Intl.DateTimeFormat("en-US",{year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),a=(0,t.ref)(!1),c=(0,t.ref)(!1),s=(0,t.ref)("");(0,t.watch)(a,(function(){return s.value=i.value.name||""}));var m=(0,t.computed)((function(){return i.value&&i.value.id===f.Z.id})),d=(0,t.computed)((function(){return m.value?f.Z.time:i.value&&i.value.time||0}));function y(){o("editName",s.value),a.value=!1}return function(e,n){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{class:(0,t.normalizeClass)(["save",{active:(0,t.unref)(m)}])},[Se,function(){return void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value}()?((0,t.openBlock)(),(0,t.createElementBlock)("div",ge,[function(){return void 0!==(0,t.unref)(i).error&&null!==(0,t.unref)(i).error&&(0,t.unref)(i).error[Symbol.for("==")]?(0,t.unref)(i).error[Symbol.for("==")](void 0):void 0==(0,t.unref)(i).error}()&&function(){return void 0!==c.value&&null!==c.value&&c.value[Symbol.for("!")]?c.value[Symbol.for("!")]():!c.value}()?((0,t.openBlock)(),(0,t.createBlock)(ve,{key:0,onClick:n[0]||(n[0]=function(e){return o("export")}),class:"button",left:""},{default:(0,t.withCtx)((function(){return[(0,t.createVNode)(Y.Z,{display:"Export",direction:(0,t.unref)(G.Nm).Left,class:"info"},{default:(0,t.withCtx)((function(){return[pe]})),_:1},8,["direction"])]})),_:1})):(0,t.createCommentVNode)("",!0),function(){return void 0!==(0,t.unref)(i).error&&null!==(0,t.unref)(i).error&&(0,t.unref)(i).error[Symbol.for("==")]?(0,t.unref)(i).error[Symbol.for("==")](void 0):void 0==(0,t.unref)(i).error}()&&function(){return void 0!==c.value&&null!==c.value&&c.value[Symbol.for("!")]?c.value[Symbol.for("!")]():!c.value}()?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:1,onClick:n[1]||(n[1]=function(e){return o("duplicate")}),class:"button"},[(0,t.createVNode)(Y.Z,{display:"Duplicate",direction:(0,t.unref)(G.Nm).Left,class:"info"},{default:(0,t.withCtx)((function(){return[he]})),_:1},8,["direction"])])):(0,t.createCommentVNode)("",!0),function(){return void 0!==(0,t.unref)(i).error&&null!==(0,t.unref)(i).error&&(0,t.unref)(i).error[Symbol.for("==")]?(0,t.unref)(i).error[Symbol.for("==")](void 0):void 0==(0,t.unref)(i).error}()&&function(){return void 0!==c.value&&null!==c.value&&c.value[Symbol.for("!")]?c.value[Symbol.for("!")]():!c.value}()?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:2,onClick:n[2]||(n[2]=function(e){return a.value=function(){return void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value}()}),class:"button"},[(0,t.createVNode)(Y.Z,{display:"Edit Name",direction:(0,t.unref)(G.Nm).Left,class:"info"},{default:(0,t.withCtx)((function(){return[Ne]})),_:1},8,["direction"])])):(0,t.createCommentVNode)("",!0),(0,t.createVNode)(se,{disabled:(0,t.unref)(m),onClick:n[3]||(n[3]=function(e){return o("delete")}),onConfirmingChanged:n[4]||(n[4]=function(e){return c.value=e})},{default:(0,t.withCtx)((function(){return[(0,t.createVNode)(Y.Z,{display:"Delete",direction:(0,t.unref)(G.Nm).Left,class:"info"},{default:(0,t.withCtx)((function(){return[ke]})),_:1},8,["direction"])]})),_:1},8,["disabled"])])):((0,t.openBlock)(),(0,t.createElementBlock)("div",Ve,[(0,t.createElementVNode)("button",{onClick:y,class:"button"},[(0,t.createVNode)(Y.Z,{display:"Save",direction:(0,t.unref)(G.Nm).Left,class:"info"},{default:(0,t.withCtx)((function(){return[xe]})),_:1},8,["direction"])]),(0,t.createElementVNode)("button",{onClick:n[5]||(n[5]=function(e){return a.value=function(){return void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value}()}),class:"button"},[(0,t.createVNode)(Y.Z,{display:"Cancel",direction:(0,t.unref)(G.Nm).Left,class:"info"},{default:(0,t.withCtx)((function(){return[Me]})),_:1},8,["direction"])])])),function(){return void 0!==(0,t.unref)(i).error&&null!==(0,t.unref)(i).error&&(0,t.unref)(i).error[Symbol.for("==")]?(0,t.unref)(i).error[Symbol.for("==")](void 0):void 0==(0,t.unref)(i).error}()&&function(){return void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value}()?((0,t.openBlock)(),(0,t.createElementBlock)("div",Ce,[(0,t.createElementVNode)("button",{class:"button open",onClick:n[6]||(n[6]=function(e){return o("open")})},[(0,t.createElementVNode)("h3",null,(0,t.toDisplayString)((0,t.unref)(i).name),1)]),(0,t.createElementVNode)("span",Ze,function(){return"v"[Symbol.for("+")]?"v"[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(i).modVersion)):"v"+(0,t.toDisplayString)((0,t.unref)(i).modVersion)}(),1),we,(0,t.unref)(d)?((0,t.openBlock)(),(0,t.createElementBlock)("div",Be,function(){return"Last played "[Symbol.for("+")]?"Last played "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(u).format((0,t.unref)(d)))):"Last played "+(0,t.toDisplayString)((0,t.unref)(u).format((0,t.unref)(d)))}(),1)):(0,t.createCommentVNode)("",!0)])):function(){return void 0!==(0,t.unref)(i).error&&null!==(0,t.unref)(i).error&&(0,t.unref)(i).error[Symbol.for("==")]?(0,t.unref)(i).error[Symbol.for("==")](void 0):void 0==(0,t.unref)(i).error}()&&a.value?((0,t.openBlock)(),(0,t.createElementBlock)("div",Pe,[(0,t.createVNode)(te.Z,{modelValue:s.value,"onUpdate:modelValue":n[7]||(n[7]=function(e){return s.value=e}),class:"editname",onSubmit:y},null,8,["modelValue"])])):((0,t.openBlock)(),(0,t.createElementBlock)("div",Ee,[(0,t.createTextVNode)(function(){return" Error: Failed to load save with id "[Symbol.for("+")]?" Error: Failed to load save with id "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(i).id)):" Error: Failed to load save with id "+(0,t.toDisplayString)((0,t.unref)(i).id)}(),1),Fe,(0,t.createTextVNode)((0,t.toDisplayString)((0,t.unref)(i).error),1)]))],2)}}});const De=(0,y.Z)(Te,[["__scopeId","data-v-335ce270"]]);var Ie=De,Re=o(9980),_e=o.n(Re),Oe=o(6961),Ue=o.n(Oe),je=o(3273),Ae=function(e){return(0,t.pushScopeId)("data-v-2bfdf896"),e=e(),(0,t.popScopeId)(),e},qe=Ae((function(){return(0,t.createElementVNode)("h2",null,"Saves Manager",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),ze={class:"modal-footer"},Le={class:"field"},Ge=Ae((function(){return(0,t.createElementVNode)("span",{class:"field-title"},"Create Save",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),He={class:"field-buttons"},We={class:"footer"},Ye=Ae((function(){return(0,t.createElementVNode)("div",{style:{"flex-grow":"1"}},null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Ke=(0,t.defineComponent)({setup:function(e,n){var r=n.expose,l=(0,t.ref)(!1),i=(0,t.ref)(null);r({open:function(){l.value=!0}});var a=(0,t.ref)(!1),c=(0,t.ref)(""),s=(0,t.ref)(null);(0,t.watch)(c,(function(e){e?(0,t.nextTick)((function(){try{if("{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])return console.warn("Unable to determine preset encoding",e),void(a.value=!0);e=Ue().decompressFromUTF16(e)}var n=JSON.parse(e);if(function(){return void 0!==(0,oe.Z)(n)&&null!==typeof n&&(0,oe.Z)(n)[Symbol.for("!==")]?(0,oe.Z)(n)[Symbol.for("!==")]("object"):"object"!==(0,oe.Z)(n)}())return void(a.value=!0);var o=(0,re.QI)();n.id=o,(0,re.a1)(n),c.value="",a.value=!1,x.ZP.saves.push(o)}catch(r){a.value=!0}})):a.value=!1}));var m=o(7634),d=(0,t.ref)(m.keys().reduce((function(e,n){return e.push({label:n.slice(2,function(){return 4[Symbol.for("minus")]?4[Symbol.for("minus")]():-4}()),value:m(n).default}),e}),[])),y=(0,t.shallowReactive)({});function v(e){if(function(){return void 0!==y[e]&&null!==y[e]&&y[e][Symbol.for("==")]?y[e][Symbol.for("==")](null):null==y[e]}()){var n=localStorage.getItem(e);if(function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}())y[e]={error:"Save doesn't exist in localStorage",id:e};else if("dW5kZWZpbmVk"===n)y[e]={error:"Save is undefined",id:e};else try{if("{"===n[0]);else if("e"===n[0])n=decodeURIComponent(escape(atob(n)));else{if("ᯡ"!==n[0])return console.warn("Unable to determine preset encoding",n),a.value=!0,y[e]={error:"Unable to determine preset encoding",id:e},y[e];n=Ue().decompressFromUTF16(n)}y[e]=(0,ne.Z)((0,ne.Z)({},JSON.parse(n)),{},{id:e})}catch(o){y[e]={error:o,id:e},console.warn("SavesManager: Failed to load info about save with id ".concat(e,":\n").concat(o,"\n").concat(n))}}return y[e]}(0,t.watch)(l,(function(e){e&&Object.keys(y).forEach((function(e){return function(){return void 0!==y&&null!==y&&y[Symbol.for("delete")]?y[Symbol.for("delete")]("key"):delete y.key}()}))}));var b=(0,t.computed)((function(){return x.ZP.saves.reduce((function(e,n){return e[n]=v(n),e}),{})}));function g(e){var n;switch(n=f.Z.id===e?(0,f.U)(f.Z[je.Le]):JSON.stringify(b.value[e]),u.exportEncoding){default:console.warn("Unknown save encoding: ".concat(u.exportEncoding,". Defaulting to lz"));case"lz":n=Ue().compressToUTF16(n);break;case"base64":n=btoa(unescape(encodeURIComponent(n)));break;case"plain":break}var o=document.createElement("textarea");o.value=n,document.body.appendChild(o),o.select(),o.setSelectionRange(0,99999),document.execCommand("copy"),document.body.removeChild(o)}function p(e){f.Z.id===e&&(0,re.a1)();var n=(0,ne.Z)((0,ne.Z)({},b.value[e]),{},{id:(0,re.QI)()});(0,re.a1)(n),x.ZP.saves.push(n.id)}function h(e){x.ZP.saves=x.ZP.saves.filter((function(n){return function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](e):n!==e}()})),localStorage.removeItem(e),y[e]=void 0}function N(e){b.value[f.Z.id].time=f.Z.time,(0,re.a1)(),y[f.Z.id]=void 0,(0,re.uW)(b.value[e]),y[e]=void 0}function k(e){if(s.value=e,(0,t.nextTick)((function(){s.value=null})),"{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])return void console.warn("Unable to determine preset encoding",e);e=Ue().decompressFromUTF16(e)}var n=JSON.parse(e);n.id=(0,re.QI)(),(0,re.a1)(n),x.ZP.saves.push(n.id),N(n.id)}function V(e,n){var o=b.value[e];o&&(o.name=n,f.Z.id===e?(f.Z.name=n,(0,re.a1)()):((0,re.a1)(o),y[e]=void 0))}return function(e,n){return(0,t.openBlock)(),(0,t.createBlock)(S.Z,{modelValue:l.value,"onUpdate:modelValue":n[4]||(n[4]=function(e){return l.value=e}),ref_key:"modal",ref:i},{header:(0,t.withCtx)((function(){return[qe]})),body:(0,t.withCtx)((function(e){var n=e.shown;return[n?((0,t.openBlock)(),(0,t.createBlock)((0,t.unref)(_e()),{key:0,list:(0,t.unref)(x.ZP).saves,handle:".handle",itemKey:function(e){return e}},{item:(0,t.withCtx)((function(e){var n=e.element;return[(0,t.createVNode)(Ie,{save:(0,t.unref)(b)[n],onOpen:function(e){return N(n)},onExport:function(e){return g(n)},onEditName:function(e){return V(n,e)},onDuplicate:function(e){return p(n)},onDelete:function(e){return h(n)}},null,8,["save","onOpen","onExport","onEditName","onDuplicate","onDelete"])]})),_:1},8,["list","itemKey"])):(0,t.createCommentVNode)("",!0)]})),footer:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("div",ze,[(0,t.createVNode)(te.Z,{modelValue:c.value,"onUpdate:modelValue":n[0]||(n[0]=function(e){return c.value=e}),title:"Import Save",placeholder:"Paste your save here!",class:(0,t.normalizeClass)({importingFailed:a.value})},null,8,["modelValue","class"]),(0,t.createElementVNode)("div",Le,[Ge,(0,t.createElementVNode)("div",He,[(0,t.createElementVNode)("button",{class:"button",onClick:n[1]||(n[1]=function(e){return N((0,t.unref)(re.xM)().id)})},"New Game"),function(){return void 0!==Object.keys((0,t.unref)(d)).length&&null!==Object.keys((0,t.unref)(d)).length&&Object.keys((0,t.unref)(d)).length[Symbol.for(">")]?Object.keys((0,t.unref)(d)).length[Symbol.for(">")](0):Object.keys((0,t.unref)(d)).length>0}()?((0,t.openBlock)(),(0,t.createBlock)(H.Z,{key:0,options:(0,t.unref)(d),modelValue:s.value,"onUpdate:modelValue":n[2]||(n[2]=function(e){return k(e)}),closeOnSelect:"",placeholder:"Select preset",class:"presets"},null,8,["options","modelValue"])):(0,t.createCommentVNode)("",!0)])]),(0,t.createElementVNode)("div",We,[Ye,(0,t.createElementVNode)("button",{class:"button modal-default-button",onClick:n[3]||(n[3]=function(e){return l.value=!1})}," Close ")])])]})),_:1},8,["modelValue"])}}});const Qe=(0,y.Z)(Ke,[["__scopeId","data-v-2bfdf896"]]);var Je=Qe,$e=function(e){return(0,t.pushScopeId)("data-v-53a1a91d"),e=e(),(0,t.popScopeId)(),e},Xe=["src","alt"],en={key:1,class:"title"},nn=$e((function(){return(0,t.createElementVNode)("div",{style:{"flex-grow":"1",cursor:"unset"}},null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),on={class:"discord"},rn={class:"discord-links"},tn={key:0},ln=["href"],un=$e((function(){return(0,t.createElementVNode)("li",null,[(0,t.createElementVNode)("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),an=$e((function(){return(0,t.createElementVNode)("li",null,[(0,t.createElementVNode)("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),fn={href:"https://forums.moddingtree.com/",target:"_blank"},cn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"forum",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),sn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"info",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),mn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"library_books",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),dn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"settings",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),yn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"library_books",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),vn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"settings",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),bn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"info",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Sn={href:"https://forums.moddingtree.com/",target:"_blank"},gn=$e((function(){return(0,t.createElementVNode)("span",{class:"material-icons"},"forum",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),pn={class:"discord"},hn={class:"discord-links"},Nn={key:0},kn=["href"],Vn=$e((function(){return(0,t.createElementVNode)("li",null,[(0,t.createElementVNode)("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),xn=$e((function(){return(0,t.createElementVNode)("li",null,[(0,t.createElementVNode)("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Mn=(0,t.defineComponent)({setup:function(e){var n=(0,t.ref)(null),o=(0,t.ref)(null),r=(0,t.ref)(null),l=(0,t.ref)(null),i=u.useHeader,a=u.banner,f=u.title,c=u.discordName,s=u.discordLink,m=u.versionNumber;function d(){window.open(s,"mywindow")}return function(e,u){return(0,t.openBlock)(),(0,t.createElementBlock)(t.Fragment,null,[(0,t.unref)(i)?((0,t.openBlock)(),(0,t.createElementBlock)("div",(0,t.mergeProps)({key:0,class:"nav"},e.$attrs),[(0,t.unref)(a)?((0,t.openBlock)(),(0,t.createElementBlock)("img",{key:0,src:(0,t.unref)(a),class:"banner",alt:(0,t.unref)(f)},null,8,Xe)):((0,t.openBlock)(),(0,t.createElementBlock)("div",en,(0,t.toDisplayString)((0,t.unref)(f)),1)),(0,t.createElementVNode)("div",{onClick:u[0]||(u[0]=function(e){var n;return null===(n=l.value)||void 0===n?void 0:n.open()}),class:"version-container"},[(0,t.createVNode)(Y.Z,{display:"Changelog",direction:(0,t.unref)(G.Nm).Down,class:"version"},{default:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("span",null,function(){return"v"[Symbol.for("+")]?"v"[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(m))):"v"+(0,t.toDisplayString)((0,t.unref)(m))}(),1)]})),_:1},8,["direction"])]),nn,(0,t.createElementVNode)("div",on,[(0,t.createElementVNode)("span",{onClick:d,class:"material-icons"},"discord"),(0,t.createElementVNode)("ul",rn,[function(){return void 0!==(0,t.unref)(s)&&null!==(0,t.unref)(s)&&(0,t.unref)(s)[Symbol.for("!==")]?(0,t.unref)(s)[Symbol.for("!==")]("https://discord.gg/WzejVAx"):"https://discord.gg/WzejVAx"!==(0,t.unref)(s)}()?((0,t.openBlock)(),(0,t.createElementBlock)("li",tn,[(0,t.createElementVNode)("a",{href:(0,t.unref)(s),target:"_blank"},(0,t.toDisplayString)((0,t.unref)(c)),9,ln)])):(0,t.createCommentVNode)("",!0),un,an])]),(0,t.createElementVNode)("div",null,[(0,t.createElementVNode)("a",fn,[(0,t.createVNode)(Y.Z,{display:"Forums",direction:(0,t.unref)(G.Nm).Down,yoffset:"5px"},{default:(0,t.withCtx)((function(){return[cn]})),_:1},8,["direction"])])]),(0,t.createElementVNode)("div",{onClick:u[1]||(u[1]=function(e){var o;return null===(o=n.value)||void 0===o?void 0:o.open()})},[(0,t.createVNode)(Y.Z,{display:"Info",direction:(0,t.unref)(G.Nm).Down,class:"info"},{default:(0,t.withCtx)((function(){return[sn]})),_:1},8,["direction"])]),(0,t.createElementVNode)("div",{onClick:u[2]||(u[2]=function(e){var n;return null===(n=o.value)||void 0===n?void 0:n.open()})},[(0,t.createVNode)(Y.Z,{display:"Saves",direction:(0,t.unref)(G.Nm).Down,xoffset:"-20px"},{default:(0,t.withCtx)((function(){return[mn]})),_:1},8,["direction"])]),(0,t.createElementVNode)("div",{onClick:u[3]||(u[3]=function(e){var n;return null===(n=r.value)||void 0===n?void 0:n.open()})},[(0,t.createVNode)(Y.Z,{display:"Options",direction:(0,t.unref)(G.Nm).Down,xoffset:"-66px"},{default:(0,t.withCtx)((function(){return[dn]})),_:1},8,["direction"])])],16)):((0,t.openBlock)(),(0,t.createElementBlock)("div",(0,t.mergeProps)({key:1,class:"overlay-nav"},e.$attrs),[(0,t.createElementVNode)("div",{onClick:u[4]||(u[4]=function(e){var n;return null===(n=l.value)||void 0===n?void 0:n.open()}),class:"version-container"},[(0,t.createVNode)(Y.Z,{display:"Changelog",direction:(0,t.unref)(G.Nm).Right,xoffset:"25%",class:"version"},{default:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("span",null,function(){return"v"[Symbol.for("+")]?"v"[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(m))):"v"+(0,t.toDisplayString)((0,t.unref)(m))}(),1)]})),_:1},8,["direction"])]),(0,t.createElementVNode)("div",{onClick:u[5]||(u[5]=function(e){var n;return null===(n=o.value)||void 0===n?void 0:n.open()})},[(0,t.createVNode)(Y.Z,{display:"Saves",direction:(0,t.unref)(G.Nm).Right},{default:(0,t.withCtx)((function(){return[yn]})),_:1},8,["direction"])]),(0,t.createElementVNode)("div",{onClick:u[6]||(u[6]=function(e){var n;return null===(n=r.value)||void 0===n?void 0:n.open()})},[(0,t.createVNode)(Y.Z,{display:"Options",direction:(0,t.unref)(G.Nm).Right},{default:(0,t.withCtx)((function(){return[vn]})),_:1},8,["direction"])]),(0,t.createElementVNode)("div",{onClick:u[7]||(u[7]=function(e){var o;return null===(o=n.value)||void 0===o?void 0:o.open()})},[(0,t.createVNode)(Y.Z,{display:"Info",direction:(0,t.unref)(G.Nm).Right},{default:(0,t.withCtx)((function(){return[bn]})),_:1},8,["direction"])]),(0,t.createElementVNode)("div",null,[(0,t.createElementVNode)("a",Sn,[(0,t.createVNode)(Y.Z,{display:"Forums",direction:(0,t.unref)(G.Nm).Right,xoffset:"7px"},{default:(0,t.withCtx)((function(){return[gn]})),_:1},8,["direction"])])]),(0,t.createElementVNode)("div",pn,[(0,t.createElementVNode)("span",{onClick:d,class:"material-icons"},"discord"),(0,t.createElementVNode)("ul",hn,[function(){return void 0!==(0,t.unref)(s)&&null!==(0,t.unref)(s)&&(0,t.unref)(s)[Symbol.for("!==")]?(0,t.unref)(s)[Symbol.for("!==")]("https://discord.gg/WzejVAx"):"https://discord.gg/WzejVAx"!==(0,t.unref)(s)}()?((0,t.openBlock)(),(0,t.createElementBlock)("li",Nn,[(0,t.createElementVNode)("a",{href:(0,t.unref)(s),target:"_blank"},(0,t.toDisplayString)((0,t.unref)(c)),9,kn)])):(0,t.createCommentVNode)("",!0),Vn,xn])])],16)),(0,t.createVNode)(z,{ref_key:"info",ref:n,changelog:l.value},null,8,["changelog"]),(0,t.createVNode)(Je,{ref_key:"savesManager",ref:o},null,512),(0,t.createVNode)(ee,{ref_key:"options",ref:r},null,512),(0,t.createVNode)(V,{ref_key:"changelog",ref:l},null,512)],64)}}});const Cn=(0,y.Z)(Mn,[["__scopeId","data-v-53a1a91d"]]);var Zn=Cn,wn={class:"inner-tab"},Bn=(0,t.defineComponent)({setup:function(e){var n=(0,t.toRef)(f.Z,"tabs"),o=(0,t.computed)((function(){return Object.keys(a.layers)})),r=u.useHeader;function l(e){var n=e.display,o=e.minimized,r=e.minWidth,t=e.name,l=e.color,i=e.minimizable,u=e.nodes;return{display:n,minimized:o,minWidth:r,name:t,color:l,minimizable:i,nodes:u}}return function(e,i){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{class:(0,t.normalizeClass)(["tabs-container",{useHeader:(0,t.unref)(r)}])},[((0,t.openBlock)(!0),(0,t.createElementBlock)(t.Fragment,null,(0,t.renderList)((0,t.unref)(n),(function(n,i){var u,f;return(0,t.openBlock)(),(0,t.createElementBlock)("div",{key:i,class:(0,t.normalizeClass)(["tab",(0,t.unref)(null===(u=(0,t.unref)(a.layers)[n])||void 0===u?void 0:u.classes)]),ref_for:!0,ref:"tab-".concat(i),style:(0,t.normalizeStyle)((0,t.unref)(null===(f=(0,t.unref)(a.layers)[n])||void 0===f?void 0:f.style))},[0===i&&function(){return void 0!==(0,t.unref)(r)&&null!==(0,t.unref)(r)&&(0,t.unref)(r)[Symbol.for("!")]?(0,t.unref)(r)[Symbol.for("!")]():!(0,t.unref)(r)}()?((0,t.openBlock)(),(0,t.createBlock)(Zn,{key:0})):(0,t.createCommentVNode)("",!0),(0,t.createElementVNode)("div",wn,[(0,t.unref)(o).includes(n)?((0,t.openBlock)(),(0,t.createBlock)(b,(0,t.mergeProps)({key:0},l((0,t.unref)(a.layers)[n]),{index:i,tab:function(){var n;return null===(n=e.$refs["tab-".concat(i)])||void 0===n?void 0:n[0]}}),null,16,["index","tab"])):((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)(n),{key:1,index:i},null,8,["index"]))])],6)})),128))],2)}}});const Pn=(0,y.Z)(Bn,[["__scopeId","data-v-7e494d3c"]]);var En=Pn,Fn=o(504),Tn=function(e){return(0,t.pushScopeId)("data-v-06188cc8"),e=e(),(0,t.popScopeId)(),e},Dn={class:"game-over-modal-header"},In=["src","alt"],Rn={class:"game-over-modal-title"},_n=Tn((function(){return(0,t.createElementVNode)("h2",null,"Congratulations!",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),On={key:0},Un=Tn((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),jn=Tn((function(){return(0,t.createElementVNode)("div",null," Please check the Discord to discuss the game or to check for new content updates! ",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),An=Tn((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),qn=["href"],zn=Tn((function(){return(0,t.createElementVNode)("span",{class:"material-icons game-over-modal-discord"},"discord",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Ln=(0,t.defineComponent)({setup:function(e){var n=u.title,o=u.logo,r=u.discordName,l=u.discordLink,i=u.versionNumber,a=u.versionTitle,c=(0,t.computed)((function(){return(0,M.mr)(f.Z.timePlayed)})),s=(0,t.computed)((function(){return Fn.hasWon.value&&function(){return void 0!==f.Z.keepGoing&&null!==f.Z.keepGoing&&f.Z.keepGoing[Symbol.for("!")]?f.Z.keepGoing[Symbol.for("!")]():!f.Z.keepGoing}()})),m=(0,t.toRef)(f.Z,"autosave");function d(){f.Z.keepGoing=!0}function y(){(0,re.uW)((0,re.xM)())}return function(e,u){return(0,t.openBlock)(),(0,t.createBlock)(S.Z,{"model-value":(0,t.unref)(s)},{header:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("div",Dn,[(0,t.unref)(o)?((0,t.openBlock)(),(0,t.createElementBlock)("img",{key:0,class:"game-over-modal-logo",src:(0,t.unref)(o),alt:(0,t.unref)(n)},null,8,In)):(0,t.createCommentVNode)("",!0),(0,t.createElementVNode)("div",Rn,[_n,(0,t.createElementVNode)("h4",null,function(){return"You've beaten "+(0,t.toDisplayString)((0,t.unref)(n))+" v"+(0,t.toDisplayString)((0,t.unref)(i))+": "!==void 0&&"You've beaten "+(0,t.toDisplayString)((0,t.unref)(n))+" v"+(0,t.toDisplayString)((0,t.unref)(i))+": "!==null&&("You've beaten "+(0,t.toDisplayString)((0,t.unref)(n))+" v"+(0,t.toDisplayString)((0,t.unref)(i))+": ")[Symbol.for("+")]?("You've beaten "+(0,t.toDisplayString)((0,t.unref)(n))+" v"+(0,t.toDisplayString)((0,t.unref)(i))+": ")[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(a))):"You've beaten "+(0,t.toDisplayString)((0,t.unref)(n))+" v"+(0,t.toDisplayString)((0,t.unref)(i))+": "+(0,t.toDisplayString)((0,t.unref)(a))}(),1)])])]})),body:(0,t.withCtx)((function(e){var n=e.shown;return[n?((0,t.openBlock)(),(0,t.createElementBlock)("div",On,[(0,t.createElementVNode)("div",null,function(){return"It took you "+(0,t.toDisplayString)((0,t.unref)(c))!==void 0&&"It took you "+(0,t.toDisplayString)((0,t.unref)(c))!==null&&("It took you "+(0,t.toDisplayString)((0,t.unref)(c)))[Symbol.for("+")]?("It took you "+(0,t.toDisplayString)((0,t.unref)(c)))[Symbol.for("+")](" to beat the game."):"It took you "+(0,t.toDisplayString)((0,t.unref)(c))+" to beat the game."}(),1),Un,jn,An,(0,t.createElementVNode)("div",null,[(0,t.createElementVNode)("a",{href:(0,t.unref)(l),class:"game-over-modal-discord-link"},[zn,(0,t.createTextVNode)(function(){return" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(r))):" "+(0,t.toDisplayString)((0,t.unref)(r))}(),1)],8,qn)]),(0,t.createVNode)(W.Z,{title:"Autosave",modelValue:(0,t.unref)(m),"onUpdate:modelValue":u[0]||(u[0]=function(e){return(0,t.isRef)(m)?m.value=e:null})},null,8,["modelValue"])])):(0,t.createCommentVNode)("",!0)]})),footer:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("div",{class:"game-over-footer"},[(0,t.createElementVNode)("button",{onClick:d,class:"button"},"Keep Going"),(0,t.createElementVNode)("button",{onClick:y,class:"button danger"},"Play Again")])]})),_:1},8,["model-value"])}}});const Gn=(0,y.Z)(Ln,[["__scopeId","data-v-06188cc8"]]);var Hn=Gn,Wn=(o(9600),o(3032)),Yn=function(e){return(0,t.pushScopeId)("data-v-5935214c"),e=e(),(0,t.popScopeId)(),e},Kn=Yn((function(){return(0,t.createElementVNode)("div",{class:"nan-modal-header"},[(0,t.createElementVNode)("h2",null,"NaN value detected!")],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),Qn={key:0},Jn=Yn((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),$n=["href"],Xn=Yn((function(){return(0,t.createElementVNode)("span",{class:"material-icons nan-modal-discord"},"discord",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),eo=Yn((function(){return(0,t.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())})),no={class:"nan-footer"},oo=(0,t.defineComponent)({setup:function(e){var n=u.discordName,o=u.discordLink,r=(0,t.toRef)(f.Z,"autosave"),l=(0,t.toRef)(Wn.Z,"hasNaN"),i=(0,t.ref)(null),a=(0,t.computed)((function(){var e;return null===(e=Wn.Z.NaNPath)||void 0===e?void 0:e.join(".")})),c=(0,t.computed)((function(){var e;return null===(e=Wn.Z.NaNPath)||void 0===e?void 0:e.slice(function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())[0]})),s=(0,t.computed)((function(){return Wn.Z.NaNReceiver&&c.value?Wn.Z.NaNReceiver[c.value]:null})),m=(0,t.computed)({get:function(){return 0===f.Z.devSpeed},set:function(e){f.Z.devSpeed=e?null:0}});function d(){Wn.Z.NaNReceiver&&c.value&&(Wn.Z.NaNReceiver[c.value]=new M.ZP(0),Wn.Z.hasNaN=!1)}function y(){Wn.Z.NaNReceiver&&c.value&&(Wn.Z.NaNReceiver[c.value]=new M.ZP(1),Wn.Z.hasNaN=!1)}function v(){Wn.Z.NaNReceiver&&c.value&&(Wn.Z.NaNReceiver[c.value]=new M.ZP(NaN),Wn.Z.hasNaN=!1)}return function(e,f){return(0,t.openBlock)(),(0,t.createElementBlock)(t.Fragment,null,[(0,t.createVNode)(S.Z,(0,t.mergeProps)({modelValue:(0,t.unref)(l),"onUpdate:modelValue":f[4]||(f[4]=function(e){return(0,t.isRef)(l)?l.value=e:null})},e.$attrs),{header:(0,t.withCtx)((function(){return[Kn]})),body:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("div",null,[(0,t.createTextVNode)(function(){return' Attempted to assign "'+(0,t.toDisplayString)((0,t.unref)(a))!==void 0&&' Attempted to assign "'+(0,t.toDisplayString)((0,t.unref)(a))!==null&&(' Attempted to assign "'+(0,t.toDisplayString)((0,t.unref)(a)))[Symbol.for("+")]?(' Attempted to assign "'+(0,t.toDisplayString)((0,t.unref)(a)))[Symbol.for("+")]('" to NaN'):' Attempted to assign "'+(0,t.toDisplayString)((0,t.unref)(a))+'" to NaN'}(),1),(0,t.unref)(s)?((0,t.openBlock)(),(0,t.createElementBlock)("span",Qn,function(){return(0,t.toDisplayString)(" ")+"(previously "+(0,t.toDisplayString)((0,t.unref)(M.WU)((0,t.unref)(s)))!==void 0&&(0,t.toDisplayString)(" ")+"(previously "+(0,t.toDisplayString)((0,t.unref)(M.WU)((0,t.unref)(s)))!==null&&((0,t.toDisplayString)(" ")+"(previously "+(0,t.toDisplayString)((0,t.unref)(M.WU)((0,t.unref)(s))))[Symbol.for("+")]?((0,t.toDisplayString)(" ")+"(previously "+(0,t.toDisplayString)((0,t.unref)(M.WU)((0,t.unref)(s))))[Symbol.for("+")](")"):(0,t.toDisplayString)(" ")+"(previously "+(0,t.toDisplayString)((0,t.unref)(M.WU)((0,t.unref)(s)))+")"}(),1)):(0,t.createCommentVNode)("",!0),(0,t.createTextVNode)(function(){return". Auto-saving has been "+(0,t.toDisplayString)((0,t.unref)(r)?"enabled":"disabled")!==void 0&&". Auto-saving has been "+(0,t.toDisplayString)((0,t.unref)(r)?"enabled":"disabled")!==null&&(". Auto-saving has been "+(0,t.toDisplayString)((0,t.unref)(r)?"enabled":"disabled"))[Symbol.for("+")]?(". Auto-saving has been "+(0,t.toDisplayString)((0,t.unref)(r)?"enabled":"disabled"))[Symbol.for("+")](". Check the console for more details, and consider sharing it with the developers on discord. "):". Auto-saving has been "+(0,t.toDisplayString)((0,t.unref)(r)?"enabled":"disabled")+". Check the console for more details, and consider sharing it with the developers on discord. "}(),1)]),Jn,(0,t.createElementVNode)("div",null,[(0,t.createElementVNode)("a",{href:(0,t.unref)(o),class:"nan-modal-discord-link"},[Xn,(0,t.createTextVNode)(function(){return" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,t.toDisplayString)((0,t.unref)(n))):" "+(0,t.toDisplayString)((0,t.unref)(n))}(),1)],8,$n)]),eo,(0,t.createVNode)(W.Z,{title:"Autosave",modelValue:(0,t.unref)(r),"onUpdate:modelValue":f[0]||(f[0]=function(e){return(0,t.isRef)(r)?r.value=e:null})},null,8,["modelValue"]),(0,t.unref)(u).enablePausing?((0,t.openBlock)(),(0,t.createBlock)(W.Z,{key:0,title:"Pause game",modelValue:(0,t.unref)(m),"onUpdate:modelValue":f[1]||(f[1]=function(e){return(0,t.isRef)(m)?m.value=e:null})},null,8,["modelValue"])):(0,t.createCommentVNode)("",!0)]})),footer:(0,t.withCtx)((function(){return[(0,t.createElementVNode)("div",no,[(0,t.createElementVNode)("button",{onClick:f[2]||(f[2]=function(e){var n;return null===(n=i.value)||void 0===n?void 0:n.open()}),class:"button"},"Open Saves Manager"),(0,t.createElementVNode)("button",{onClick:d,class:"button"},"Set to 0"),(0,t.createElementVNode)("button",{onClick:y,class:"button"},"Set to 1"),(0,t.unref)(s)&&(0,t.unref)(M.ZP).neq((0,t.unref)(s),0)&&(0,t.unref)(M.ZP).neq((0,t.unref)(s),1)?((0,t.openBlock)(),(0,t.createElementBlock)("button",{key:0,onClick:f[3]||(f[3]=function(e){return l.value=!1}),class:"button"}," Set to previous ")):(0,t.createCommentVNode)("",!0),(0,t.createElementVNode)("button",{onClick:v,class:"button danger"},"Ignore")])]})),_:1},16,["modelValue"]),(0,t.createVNode)(Je,{ref_key:"savesManager",ref:i},null,512)],64)}}});const ro=(0,y.Z)(oo,[["__scopeId","data-v-5935214c"]]);var to=ro,lo=(o(86),{key:0,class:"tpsDisplay"}),io={key:0,class:"low"},uo=(0,t.defineComponent)({setup:function(e){var n=(0,t.computed)((function(){return M.ZP.div(Wn.Z.lastTenTicks.length,Wn.Z.lastTenTicks.reduce((function(e,n){return function(){return void 0!==e&&null!==e&&e[Symbol.for("+")]?e[Symbol.for("+")](n):e+n}()}),0))})),o=(0,t.ref)([]);(0,t.watchEffect)((function(){o.value.push(Math.round(n.value.toNumber())),function(){return void 0!==o.value.length&&null!==o.value.length&&o.value.length[Symbol.for(">")]?o.value.length[Symbol.for(">")](10):o.value.length>10}()&&(o.value=o.value.slice(1))}));var r=(0,t.computed)((function(){return o.value.reduce((function(e,n){return M.ZP.max(e,n)}),0)})),l=(0,t.computed)((function(){return M.ZP.sub(n.value,r.value).gt(1)}));return function(e,o){return function(){return void 0!==(0,t.unref)(n).isNan()&&null!==(0,t.unref)(n).isNan()&&(0,t.unref)(n).isNan()[Symbol.for("!")]?(0,t.unref)(n).isNan()[Symbol.for("!")]():!(0,t.unref)(n).isNan()}()?((0,t.openBlock)(),(0,t.createElementBlock)("div",lo,[(0,t.createTextVNode)(function(){return" TPS: "+(0,t.toDisplayString)((0,t.unref)(M.Ht)((0,t.unref)(n)))!==void 0&&" TPS: "+(0,t.toDisplayString)((0,t.unref)(M.Ht)((0,t.unref)(n)))!==null&&(" TPS: "+(0,t.toDisplayString)((0,t.unref)(M.Ht)((0,t.unref)(n))))[Symbol.for("+")]?(" TPS: "+(0,t.toDisplayString)((0,t.unref)(M.Ht)((0,t.unref)(n))))[Symbol.for("+")](" "):" TPS: "+(0,t.toDisplayString)((0,t.unref)(M.Ht)((0,t.unref)(n)))+" "}(),1),(0,t.createVNode)(t.Transition,{name:"fade"},{default:(0,t.withCtx)((function(){return[(0,t.unref)(l)?((0,t.openBlock)(),(0,t.createElementBlock)("span",io,(0,t.toDisplayString)((0,t.unref)(M.Ht)((0,t.unref)(r))),1)):(0,t.createCommentVNode)("",!0)]})),_:1})])):(0,t.createCommentVNode)("",!0)}}});const ao=(0,y.Z)(uo,[["__scopeId","data-v-c0663118"]]);var fo=ao,co=(0,t.defineComponent)({setup:function(e){var n=u.useHeader,o=(0,t.computed)((function(){return L.Z[x.ZP.theme].variables})),r=(0,t.toRef)(x.ZP,"showTPS"),a=(0,t.computed)((function(){return(0,i.MM)((0,l.tZ)((function(){return(0,t.createVNode)(t.Fragment,null,[x.t.map(i.sY)])})))}));return function(e,l){return(0,t.openBlock)(),(0,t.createElementBlock)(t.Fragment,null,[(0,t.createElementVNode)("div",{id:"modal-root",style:(0,t.normalizeStyle)((0,t.unref)(o))},null,4),(0,t.createElementVNode)("div",{class:(0,t.normalizeClass)(["app",{useHeader:(0,t.unref)(n)}]),style:(0,t.normalizeStyle)((0,t.unref)(o))},[(0,t.unref)(n)?((0,t.openBlock)(),(0,t.createBlock)(Zn,{key:0})):(0,t.createCommentVNode)("",!0),(0,t.createVNode)(En),(0,t.unref)((0,t.unref)(r))?((0,t.openBlock)(),(0,t.createBlock)(fo,{key:1})):(0,t.createCommentVNode)("",!0),(0,t.createVNode)(Hn),(0,t.createVNode)(to),((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)((0,t.unref)(a))))],6)],64)}}});const so=(0,y.Z)(co,[["__scopeId","data-v-f13f28b6"]]);var mo=so;if(document.title=u.title,""===u.id)throw"Project ID is empty! Please select a unique ID for this project in /src/data/projInfo.json";requestAnimationFrame((0,r.Z)(regeneratorRuntime.mark((function e(){var n,r,l,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return console.log("%cMade in Profectus%c\nLearn more at www.moddingtree.com","font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;","padding: 4px;"),e.next=3,(0,re.zD)();case 3:return e.next=5,o(7302);case 5:n=e.sent,r=n.globalBus,l=n.startGameLoop,i=window.vue=(0,t.createApp)(mo),r.emit("setupVue",i),i.mount("#app"),l();case 12:case"end":return e.stop()}}),e)})))),window.projInfo=u},5613:function(e,n,o){"use strict";o.d(n,{ZP:function(){return Se},WU:function(){return se},mr:function(){return de},Ht:function(){return me}});o(2526),o(1817),o(1539),o(6977),o(4916),o(3123),o(5306),o(9653),o(86);var r,t,l,i,u,a,f,c,s,m,d,y=o(3087),v=o(2833),b=o(2482),S=o(3336),g=(o(658),o(2420),o(3689),o(5192),o(1703),o(9714),o(3210),o(2481),o(1354),o(4914),17),p=9e15,h=Math.log10(9e15),N=function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](9e15):1/9e15}(),k=308,V=function(){return 324[Symbol.for("minus")]?324[Symbol.for("minus")]():-324}(),x=5,M=!0,C=!1,Z=function(){for(var e=[],n=function(){return void 0!==V&&null!==V&&V[Symbol.for("+")]?V[Symbol.for("+")](1):V+1}();function(){return void 0!==n&&null!==n&&n[Symbol.for("<=")]?n[Symbol.for("<=")](k):n<=k}();function(){return void 0!==n&&null!==n&&"object"===(0,S.Z)(n)&&n[Symbol.for("postfix-increment")]?n[Symbol.for("postfix-increment")]():n++}())e.push(Number(function(){return"1e"[Symbol.for("+")]?"1e"[Symbol.for("+")](n):"1e"+n}()));var o=323;return function(n){return e[function(){return void 0!==n&&null!==n&&n[Symbol.for("+")]?n[Symbol.for("+")](o):n+o}()]}}(),w=[2,Math.E,3,4,5,6,7,8,9,10],B=[[1,1.0891168053867777,1.1789745164521264,1.2701428397304229,1.3632066654400328,1.4587804913784246,1.557523817412741,1.660158301473385,1.767487542936873,1.8804205225512542,2],[1,1.1121114330934,1.23103892493161,1.35838369631113,1.49605193039935,1.64635423375119,1.81213853570186,1.99697132461829,2.20538955455724,2.44325744833852,Math.E],[1,1.1187738849693603,1.2464963939368214,1.38527004705667,1.5376664685821402,1.7068895236551784,1.897001227148399,2.1132403089001035,2.362480153784171,2.6539010333870774,3],[1,1.1367350847096405,1.2889510672956703,1.4606478703324786,1.6570295196661111,1.8850062585672889,2.1539465047453485,2.476829779693097,2.872061932789197,3.3664204535587183,4],[1,1.1494592900767588,1.319708228183931,1.5166291280087583,1.748171114438024,2.0253263297298045,2.3636668498288547,2.7858359149579424,3.3257226212448145,4.035730287722532,5],[1,1.159225940787673,1.343712473580932,1.5611293155111927,1.8221199554561318,2.14183924486326,2.542468319282638,3.0574682501653316,3.7390572020926873,4.6719550537360774,6],[1,1.1670905356972596,1.3632807444991446,1.5979222279405536,1.8842640123816674,2.2416069644878687,2.69893426559423,3.3012632110403577,4.121250340630164,5.281493033448316,7],[1,1.1736630594087796,1.379783782386201,1.6292821855668218,1.9378971836180754,2.3289975651071977,2.8384347394720835,3.5232708454565906,4.478242031114584,5.868592169644505,8],[1,1.1793017514670474,1.394054150657457,1.65664127441059,1.985170999970283,2.4069682290577457,2.9647310119960752,3.7278665320924946,4.814462547283592,6.436522247411611,9],[1,1.18422737399915,1.4066113788546144,1.680911177655277,2.027492094355525,2.4775152854601967,3.080455730250329,3.918234505962507,5.1332705696484595,6.9878696918072905,10]],P=[[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.9194161097107025[Symbol.for("minus")]?.9194161097107025[Symbol.for("minus")]():-.9194161097107025}(),function(){return.8335625019330468[Symbol.for("minus")]?.8335625019330468[Symbol.for("minus")]():-.8335625019330468}(),function(){return.7425599821143978[Symbol.for("minus")]?.7425599821143978[Symbol.for("minus")]():-.7425599821143978}(),function(){return.6466611521029437[Symbol.for("minus")]?.6466611521029437[Symbol.for("minus")]():-.6466611521029437}(),function(){return.5462617907227869[Symbol.for("minus")]?.5462617907227869[Symbol.for("minus")]():-.5462617907227869}(),function(){return.4419033816638769[Symbol.for("minus")]?.4419033816638769[Symbol.for("minus")]():-.4419033816638769}(),function(){return.3342645487554494[Symbol.for("minus")]?.3342645487554494[Symbol.for("minus")]():-.3342645487554494}(),function(){return.224140440909962[Symbol.for("minus")]?.224140440909962[Symbol.for("minus")]():-.224140440909962}(),function(){return.11241087890006762[Symbol.for("minus")]?.11241087890006762[Symbol.for("minus")]():-.11241087890006762}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.90603157029014[Symbol.for("minus")]?.90603157029014[Symbol.for("minus")]():-.90603157029014}(),function(){return.80786507256596[Symbol.for("minus")]?.80786507256596[Symbol.for("minus")]():-.80786507256596}(),function(){return.7064666939634[Symbol.for("minus")]?.7064666939634[Symbol.for("minus")]():-.7064666939634}(),function(){return.60294836853664[Symbol.for("minus")]?.60294836853664[Symbol.for("minus")]():-.60294836853664}(),function(){return.49849837513117[Symbol.for("minus")]?.49849837513117[Symbol.for("minus")]():-.49849837513117}(),function(){return.39430303318768[Symbol.for("minus")]?.39430303318768[Symbol.for("minus")]():-.39430303318768}(),function(){return.29147201034755[Symbol.for("minus")]?.29147201034755[Symbol.for("minus")]():-.29147201034755}(),function(){return.19097820800866[Symbol.for("minus")]?.19097820800866[Symbol.for("minus")]():-.19097820800866}(),function(){return.09361896280296[Symbol.for("minus")]?.09361896280296[Symbol.for("minus")]():-.09361896280296}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.9021579584316141[Symbol.for("minus")]?.9021579584316141[Symbol.for("minus")]():-.9021579584316141}(),function(){return.8005762598234203[Symbol.for("minus")]?.8005762598234203[Symbol.for("minus")]():-.8005762598234203}(),function(){return.6964780623319391[Symbol.for("minus")]?.6964780623319391[Symbol.for("minus")]():-.6964780623319391}(),function(){return.5911906810998454[Symbol.for("minus")]?.5911906810998454[Symbol.for("minus")]():-.5911906810998454}(),function(){return.486050182576545[Symbol.for("minus")]?.486050182576545[Symbol.for("minus")]():-.486050182576545}(),function(){return.3823089430815083[Symbol.for("minus")]?.3823089430815083[Symbol.for("minus")]():-.3823089430815083}(),function(){return.28106046722897615[Symbol.for("minus")]?.28106046722897615[Symbol.for("minus")]():-.28106046722897615}(),function(){return.1831906535795894[Symbol.for("minus")]?.1831906535795894[Symbol.for("minus")]():-.1831906535795894}(),function(){return.08935809204418144[Symbol.for("minus")]?.08935809204418144[Symbol.for("minus")]():-.08935809204418144}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8917227442365535[Symbol.for("minus")]?.8917227442365535[Symbol.for("minus")]():-.8917227442365535}(),function(){return.781258746326964[Symbol.for("minus")]?.781258746326964[Symbol.for("minus")]():-.781258746326964}(),function(){return.6705130326902455[Symbol.for("minus")]?.6705130326902455[Symbol.for("minus")]():-.6705130326902455}(),function(){return.5612813129406509[Symbol.for("minus")]?.5612813129406509[Symbol.for("minus")]():-.5612813129406509}(),function(){return.4551067709033134[Symbol.for("minus")]?.4551067709033134[Symbol.for("minus")]():-.4551067709033134}(),function(){return.35319256652135966[Symbol.for("minus")]?.35319256652135966[Symbol.for("minus")]():-.35319256652135966}(),function(){return.2563741554088552[Symbol.for("minus")]?.2563741554088552[Symbol.for("minus")]():-.2563741554088552}(),function(){return.1651412821106526[Symbol.for("minus")]?.1651412821106526[Symbol.for("minus")]():-.1651412821106526}(),function(){return.0796919581982668[Symbol.for("minus")]?.0796919581982668[Symbol.for("minus")]():-.0796919581982668}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8843387974366064[Symbol.for("minus")]?.8843387974366064[Symbol.for("minus")]():-.8843387974366064}(),function(){return.7678744063886243[Symbol.for("minus")]?.7678744063886243[Symbol.for("minus")]():-.7678744063886243}(),function(){return.6529563724510552[Symbol.for("minus")]?.6529563724510552[Symbol.for("minus")]():-.6529563724510552}(),function(){return.5415870994657841[Symbol.for("minus")]?.5415870994657841[Symbol.for("minus")]():-.5415870994657841}(),function(){return.4352842206588936[Symbol.for("minus")]?.4352842206588936[Symbol.for("minus")]():-.4352842206588936}(),function(){return.33504449124791424[Symbol.for("minus")]?.33504449124791424[Symbol.for("minus")]():-.33504449124791424}(),function(){return.24138853420685147[Symbol.for("minus")]?.24138853420685147[Symbol.for("minus")]():-.24138853420685147}(),function(){return.15445285440944467[Symbol.for("minus")]?.15445285440944467[Symbol.for("minus")]():-.15445285440944467}(),function(){return.07409659641336663[Symbol.for("minus")]?.07409659641336663[Symbol.for("minus")]():-.07409659641336663}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8786709358426346[Symbol.for("minus")]?.8786709358426346[Symbol.for("minus")]():-.8786709358426346}(),function(){return.7577735191184886[Symbol.for("minus")]?.7577735191184886[Symbol.for("minus")]():-.7577735191184886}(),function(){return.6399546189952064[Symbol.for("minus")]?.6399546189952064[Symbol.for("minus")]():-.6399546189952064}(),function(){return.527284921869926[Symbol.for("minus")]?.527284921869926[Symbol.for("minus")]():-.527284921869926}(),function(){return.4211627631006314[Symbol.for("minus")]?.4211627631006314[Symbol.for("minus")]():-.4211627631006314}(),function(){return.3223479611761232[Symbol.for("minus")]?.3223479611761232[Symbol.for("minus")]():-.3223479611761232}(),function(){return.23107655627789858[Symbol.for("minus")]?.23107655627789858[Symbol.for("minus")]():-.23107655627789858}(),function(){return.1472057700818259[Symbol.for("minus")]?.1472057700818259[Symbol.for("minus")]():-.1472057700818259}(),function(){return.07035171210706326[Symbol.for("minus")]?.07035171210706326[Symbol.for("minus")]():-.07035171210706326}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8740862815291583[Symbol.for("minus")]?.8740862815291583[Symbol.for("minus")]():-.8740862815291583}(),function(){return.7497032990976209[Symbol.for("minus")]?.7497032990976209[Symbol.for("minus")]():-.7497032990976209}(),function(){return.6297119746181752[Symbol.for("minus")]?.6297119746181752[Symbol.for("minus")]():-.6297119746181752}(),function(){return.5161838335958787[Symbol.for("minus")]?.5161838335958787[Symbol.for("minus")]():-.5161838335958787}(),function(){return.41036238255751956[Symbol.for("minus")]?.41036238255751956[Symbol.for("minus")]():-.41036238255751956}(),function(){return.31277212146489963[Symbol.for("minus")]?.31277212146489963[Symbol.for("minus")]():-.31277212146489963}(),function(){return.2233976621705518[Symbol.for("minus")]?.2233976621705518[Symbol.for("minus")]():-.2233976621705518}(),function(){return.1418697367979619[Symbol.for("minus")]?.1418697367979619[Symbol.for("minus")]():-.1418697367979619}(),function(){return.06762117662323441[Symbol.for("minus")]?.06762117662323441[Symbol.for("minus")]():-.06762117662323441}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8702632331800649[Symbol.for("minus")]?.8702632331800649[Symbol.for("minus")]():-.8702632331800649}(),function(){return.7430366914122081[Symbol.for("minus")]?.7430366914122081[Symbol.for("minus")]():-.7430366914122081}(),function(){return.6213373075161548[Symbol.for("minus")]?.6213373075161548[Symbol.for("minus")]():-.6213373075161548}(),function(){return.5072025698095242[Symbol.for("minus")]?.5072025698095242[Symbol.for("minus")]():-.5072025698095242}(),function(){return.40171437727184167[Symbol.for("minus")]?.40171437727184167[Symbol.for("minus")]():-.40171437727184167}(),function(){return.30517930701410456[Symbol.for("minus")]?.30517930701410456[Symbol.for("minus")]():-.30517930701410456}(),function(){return.21736343968190863[Symbol.for("minus")]?.21736343968190863[Symbol.for("minus")]():-.21736343968190863}(),function(){return.137710238299109[Symbol.for("minus")]?.137710238299109[Symbol.for("minus")]():-.137710238299109}(),function(){return.06550774483471955[Symbol.for("minus")]?.06550774483471955[Symbol.for("minus")]():-.06550774483471955}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8670016295947213[Symbol.for("minus")]?.8670016295947213[Symbol.for("minus")]():-.8670016295947213}(),function(){return.7373984232432306[Symbol.for("minus")]?.7373984232432306[Symbol.for("minus")]():-.7373984232432306}(),function(){return.6143173985094293[Symbol.for("minus")]?.6143173985094293[Symbol.for("minus")]():-.6143173985094293}(),function(){return.49973884395492807[Symbol.for("minus")]?.49973884395492807[Symbol.for("minus")]():-.49973884395492807}(),function(){return.394584953527678[Symbol.for("minus")]?.394584953527678[Symbol.for("minus")]():-.394584953527678}(),function(){return.2989649949848695[Symbol.for("minus")]?.2989649949848695[Symbol.for("minus")]():-.2989649949848695}(),function(){return.21245647317021688[Symbol.for("minus")]?.21245647317021688[Symbol.for("minus")]():-.21245647317021688}(),function(){return.13434688362382652[Symbol.for("minus")]?.13434688362382652[Symbol.for("minus")]():-.13434688362382652}(),function(){return.0638072667348083[Symbol.for("minus")]?.0638072667348083[Symbol.for("minus")]():-.0638072667348083}(),0],[function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),function(){return.8641642839543857[Symbol.for("minus")]?.8641642839543857[Symbol.for("minus")]():-.8641642839543857}(),function(){return.732534623168535[Symbol.for("minus")]?.732534623168535[Symbol.for("minus")]():-.732534623168535}(),function(){return.6083127477059322[Symbol.for("minus")]?.6083127477059322[Symbol.for("minus")]():-.6083127477059322}(),function(){return.4934049257184696[Symbol.for("minus")]?.4934049257184696[Symbol.for("minus")]():-.4934049257184696}(),function(){return.3885773075899922[Symbol.for("minus")]?.3885773075899922[Symbol.for("minus")]():-.3885773075899922}(),function(){return.29376029055315767[Symbol.for("minus")]?.29376029055315767[Symbol.for("minus")]():-.29376029055315767}(),function(){return.2083678561173622[Symbol.for("minus")]?.2083678561173622[Symbol.for("minus")]():-.2083678561173622}(),function(){return.13155653399373268[Symbol.for("minus")]?.13155653399373268[Symbol.for("minus")]():-.13155653399373268}(),function(){return.062401588652553186[Symbol.for("minus")]?.062401588652553186[Symbol.for("minus")]():-.062401588652553186}(),0]],E=function(e){return j.fromValue_noAlloc(e)},F=function(e,n,o){return j.fromComponents(e,n,o)},T=function(e,n,o){return j.fromComponents_noNormalize(e,n,o)},D=function(e,n){var o=function(){return void 0!==n&&null!==n&&n[Symbol.for("+")]?n[Symbol.for("+")](1):n+1}(),r=Math.ceil(Math.log10(Math.abs(e))),t=function(){return void 0!==Math.round(e*Math.pow(10,o-r))&&null!==Math.round(e*Math.pow(10,o-r))&&Math.round(e*Math.pow(10,o-r))[Symbol.for("*")]?Math.round(e*Math.pow(10,o-r))[Symbol.for("*")](Math.pow(10,r-o)):Math.round(e*Math.pow(10,o-r))*Math.pow(10,r-o)}();return parseFloat(t.toFixed(Math.max(function(){return void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](r):o-r}(),0)))},I=function(e){return function(){return void 0!==Math.sign(e)&&null!==Math.sign(e)&&Math.sign(e)[Symbol.for("*")]?Math.sign(e)[Symbol.for("*")](Math.log10(Math.abs(e))):Math.sign(e)*Math.log10(Math.abs(e))}()},R=function(e){if(function(){return void 0!==isFinite(e)&&null!==isFinite(e)&&isFinite(e)[Symbol.for("!")]?isFinite(e)[Symbol.for("!")]():!isFinite(e)}())return e;if(function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](-50):e<-50}())return e===Math.trunc(e)?Number.NEGATIVE_INFINITY:0;var n=1;while(function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](10):e<10}())n=function(){return void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](e):n*e}(),function(){void 0!==e&&null!==e&&"object"===(0,S.Z)(e)&&e[Symbol.for("prefix-increment")]?e[Symbol.for("prefix-increment")]():++e}();e=function(){return void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](1):e-1}();var o=.9189385332046727;o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")]((e+.5)*Math.log(e)):o+(e+.5)*Math.log(e)}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](e):o-e}();var r=function(){return void 0!==e&&null!==e&&e[Symbol.for("*")]?e[Symbol.for("*")](e):e*e}(),t=e;return o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1/(12*t)):o+1/(12*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1/(360*t)):o+1/(360*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1/(1260*t)):o+1/(1260*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1/(1680*t)):o+1/(1680*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1/(1188*t)):o+1/(1188*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](691/(360360*t)):o+691/(360360*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](7/(1092*t)):o+7/(1092*t)}(),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("*")]?t[Symbol.for("*")](r):t*r}(),o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](3617/(122400*t)):o+3617/(122400*t)}(),function(){return void 0!==Math.exp(o)&&null!==Math.exp(o)&&Math.exp(o)[Symbol.for("/")]?Math.exp(o)[Symbol.for("/")](n):Math.exp(o)/n}()},_=.5671432904097838,O=function(e){var n,o,r=arguments,t=function(){return void 0!==r.length&&null!==r.length&&r.length[Symbol.for(">")]?r.length[Symbol.for(">")](1):r.length>1}()&&function(){return void 0!==r[1]&&null!==r[1]&&r[1][Symbol.for("!==")]?r[1][Symbol.for("!==")](void 0):void 0!==r[1]}()?arguments[1]:1e-10;if(function(){return void 0!==Number.isFinite(e)&&null!==Number.isFinite(e)&&Number.isFinite(e)[Symbol.for("!")]?Number.isFinite(e)[Symbol.for("!")]():!Number.isFinite(e)}())return e;if(0===e)return e;if(1===e)return _;n=function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](10):e<10}()?0:function(){return void 0!==Math.log(e)&&null!==Math.log(e)&&Math.log(e)[Symbol.for("-")]?Math.log(e)[Symbol.for("-")](Math.log(Math.log(e))):Math.log(e)-Math.log(Math.log(e))}();for(var l=0;function(){return void 0!==l&&null!==l&&l[Symbol.for("<")]?l[Symbol.for("<")](100):l<100}();function(){return void 0!==l&&null!==l&&"object"===(0,S.Z)(l)&&l[Symbol.for("prefix-increment")]?l[Symbol.for("prefix-increment")]():++l}()){if(o=function(){return e*Math.exp(-n)+n*n!==void 0&&e*Math.exp(-n)+n*n!==null&&(e*Math.exp(-n)+n*n)[Symbol.for("/")]?(e*Math.exp(-n)+n*n)[Symbol.for("/")](n+1):(e*Math.exp(-n)+n*n)/(n+1)}(),function(){return void 0!==Math.abs(o-n)&&null!==Math.abs(o-n)&&Math.abs(o-n)[Symbol.for("<")]?Math.abs(o-n)[Symbol.for("<")](t*Math.abs(o)):Math.abs(o-n)")]?l.length[Symbol.for(">")](1):l.length>1}()&&function(){return void 0!==l[1]&&null!==l[1]&&l[1][Symbol.for("!==")]?l[1][Symbol.for("!==")](void 0):void 0!==l[1]}()?arguments[1]:1e-10;if(function(){return void 0!==Number.isFinite(e.mag)&&null!==Number.isFinite(e.mag)&&Number.isFinite(e.mag)[Symbol.for("!")]?Number.isFinite(e.mag)[Symbol.for("!")]():!Number.isFinite(e.mag)}())return e;if(e===j.dZero)return e;if(e===j.dOne)return E(_);j.abs(e);n=j.ln(e);for(var u=0;function(){return void 0!==u&&null!==u&&u[Symbol.for("<")]?u[Symbol.for("<")](100):u<100}();function(){return void 0!==u&&null!==u&&"object"===(0,S.Z)(u)&&u[Symbol.for("prefix-increment")]?u[Symbol.for("prefix-increment")]():++u}()){if(o=j.exp(function(){return void 0!==n&&null!==n&&n[Symbol.for("minus")]?n[Symbol.for("minus")]():-n}()),r=n.sub(e.mul(o)),t=n.sub(r.div(n.add(1).sub(n.add(2).mul(r).div(j.mul(2,n).add(2))))),j.abs(t.sub(n)).lt(j.abs(t).mul(i)))return t;n=t}throw Error("Iteration failed to converge: ".concat(e.toString()))}r=Symbol.for("+"),t=Symbol.for("-"),l=Symbol.for("*"),i=Symbol.for("/"),u=Symbol.for("minus"),a=Symbol.for("=="),f=Symbol.for(">"),c=Symbol.for("<"),s=Symbol.for(">="),m=Symbol.for("<="),d=Symbol.for("!=");var j=function(){function e(n){(0,y.Z)(this,e),(0,b.Z)(this,"sign",Number.NaN),(0,b.Z)(this,"mag",Number.NaN),(0,b.Z)(this,"layer",Number.NaN),n instanceof e||function(){return void 0!==n&&null!==n&&n[Symbol.for("!=")]?n[Symbol.for("!=")](null):null!=n}()&&"object"===(0,S.Z)(n)&&function(){return"sign"[Symbol.for("in")]?"sign"[Symbol.for("in")](n):"sign"in n}()&&function(){return"mag"[Symbol.for("in")]?"mag"[Symbol.for("in")](n):"mag"in n}()&&function(){return"layer"[Symbol.for("in")]?"layer"[Symbol.for("in")](n):"layer"in n}()?this.fromDecimal(n):"number"===typeof n?this.fromNumber(n):"string"===typeof n?this.fromString(n):(this.sign=0,this.layer=0,this.mag=0)}return(0,v.Z)(e,[{key:"m",get:function(){var e=this;if(0===this.sign)return 0;if(0===this.layer){var n,o=Math.floor(Math.log10(this.mag));return n=5e-324===this.mag?5:function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("/")]?e.mag[Symbol.for("/")](Z(o)):e.mag/Z(o)}(),function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](n):e.sign*n}()}if(1===this.layer){var r=function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("-")]?e.mag[Symbol.for("-")](Math.floor(e.mag)):e.mag-Math.floor(e.mag)}();return function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](Math.pow(10,r)):e.sign*Math.pow(10,r)}()}return this.sign},set:function(e){var n=this;!function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("<=")]?n.layer[Symbol.for("<=")](2):n.layer<=2}()?(this.sign=Math.sign(e),0===this.sign&&(this.layer,this.exponent)):this.fromMantissaExponent(e,this.e)}},{key:"e",get:function(){var e=this;return 0===this.sign?0:0===this.layer?Math.floor(Math.log10(this.mag)):1===this.layer?Math.floor(this.mag):2===this.layer?Math.floor(function(){return void 0!==Math.sign(e.mag)&&null!==Math.sign(e.mag)&&Math.sign(e.mag)[Symbol.for("*")]?Math.sign(e.mag)[Symbol.for("*")](Math.pow(10,Math.abs(e.mag))):Math.sign(e.mag)*Math.pow(10,Math.abs(e.mag))}()):function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("*")]?e.mag[Symbol.for("*")](Number.POSITIVE_INFINITY):e.mag*Number.POSITIVE_INFINITY}()},set:function(e){this.fromMantissaExponent(this.m,e)}},{key:"s",get:function(){return this.sign},set:function(e){0===e?(this.sign=0,this.layer=0,this.mag=0):this.sign=e}},{key:"mantissa",get:function(){return this.m},set:function(e){this.m=e}},{key:"exponent",get:function(){return this.e},set:function(e){this.e=e}},{key:r,value:function(e){return this.add(e)}},{key:t,value:function(e){return this.sub(e)}},{key:l,value:function(e){return this.times(e)}},{key:i,value:function(e){return this.div(e)}},{key:u,value:function(){return this.neg()}},{key:a,value:function(e){return this.eq(e)}},{key:f,value:function(e){return this.gt(e)}},{key:c,value:function(e){return this.lt(e)}},{key:s,value:function(e){return this.gte(e)}},{key:m,value:function(e){return this.lte(e)}},{key:d,value:function(e){return this.neq(e)}},{key:"normalize",value:function(){var e=this;if(0===this.sign||0===this.mag&&0===this.layer)return this.sign=0,this.mag=0,this.layer=0,this;if(0===this.layer&&function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()&&(this.mag=function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("minus")]?e.mag[Symbol.for("minus")]():-e.mag}(),this.sign=function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("minus")]?e.sign[Symbol.for("minus")]():-e.sign}()),0===this.layer&&function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](N):e.mag=")]?n[Symbol.for(">=")](p):n>=p}())return e.layer=function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1}(),this.mag=function(){return void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](Math.log10(n)):o*Math.log10(n)}(),this;while(function(){return void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](h):n")]?e.layer[Symbol.for(">")](0):e.layer>0}())e.layer=function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("-")]?e.layer[Symbol.for("-")](1):e.layer-1}(),0===this.layer?this.mag=Math.pow(10,this.mag):(this.mag=function(){return void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](Math.pow(10,n)):o*Math.pow(10,n)}(),n=Math.abs(this.mag),o=Math.sign(this.mag));return 0===this.layer&&(!function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()?0===this.mag&&(this.sign=0):(this.mag=function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("minus")]?e.mag[Symbol.for("minus")]():-e.mag}(),this.sign=function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("minus")]?e.sign[Symbol.for("minus")]():-e.sign}())),this}},{key:"fromComponents",value:function(e,n,o){return this.sign=e,this.layer=n,this.mag=o,this.normalize(),this}},{key:"fromComponents_noNormalize",value:function(e,n,o){return this.sign=e,this.layer=n,this.mag=o,this}},{key:"fromMantissaExponent",value:function(e,n){return this.layer=1,this.sign=Math.sign(e),e=Math.abs(e),this.mag=function(){return void 0!==n&&null!==n&&n[Symbol.for("+")]?n[Symbol.for("+")](Math.log10(e)):n+Math.log10(e)}(),this.normalize(),this}},{key:"fromMantissaExponent_noNormalize",value:function(e,n){return this.fromMantissaExponent(e,n),this}},{key:"fromDecimal",value:function(e){return this.sign=e.sign,this.layer=e.layer,this.mag=e.mag,this}},{key:"fromNumber",value:function(e){return this.mag=Math.abs(e),this.sign=Math.sign(e),this.layer=0,this.normalize(),this}},{key:"fromString",value:function(n){M?n=n.replace(",",""):C&&(n=n.replace(",","."));var o=n.split("^^^");if(2===o.length){var r=parseFloat(o[0]),t=parseFloat(o[1]),l=o[1].split(";"),i=1;if(2===l.length&&(i=parseFloat(l[1]),function(){return void 0!==isFinite(i)&&null!==isFinite(i)&&isFinite(i)[Symbol.for("!")]?isFinite(i)[Symbol.for("!")]():!isFinite(i)}()&&(i=1)),isFinite(r)&&isFinite(t)){var u=e.pentate(r,t,i);return this.sign=u.sign,this.layer=u.layer,this.mag=u.mag,this}}var a=n.split("^^");if(2===a.length){var f=parseFloat(a[0]),c=parseFloat(a[1]),s=a[1].split(";"),m=1;if(2===s.length&&(m=parseFloat(s[1]),function(){return void 0!==isFinite(m)&&null!==isFinite(m)&&isFinite(m)[Symbol.for("!")]?isFinite(m)[Symbol.for("!")]():!isFinite(m)}()&&(m=1)),isFinite(f)&&isFinite(c)){var d=e.tetrate(f,c,m);return this.sign=d.sign,this.layer=d.layer,this.mag=d.mag,this}}var y,v,b=n.split("^");if(2===b.length){var g=parseFloat(b[0]),p=parseFloat(b[1]);if(isFinite(g)&&isFinite(p)){var h=e.pow(g,p);return this.sign=h.sign,this.layer=h.layer,this.mag=h.mag,this}}n=n.trim().toLowerCase();var N=n.split("pt");if(2===N.length){y=10,v=parseFloat(N[0]),N[1]=N[1].replace("(",""),N[1]=N[1].replace(")","");var k=parseFloat(N[1]);if(function(){return void 0!==isFinite(k)&&null!==isFinite(k)&&isFinite(k)[Symbol.for("!")]?isFinite(k)[Symbol.for("!")]():!isFinite(k)}()&&(k=1),isFinite(y)&&isFinite(v)){var V=e.tetrate(y,v,k);return this.sign=V.sign,this.layer=V.layer,this.mag=V.mag,this}}if(N=n.split("p"),2===N.length){y=10,v=parseFloat(N[0]),N[1]=N[1].replace("(",""),N[1]=N[1].replace(")","");var x=parseFloat(N[1]);if(function(){return void 0!==isFinite(x)&&null!==isFinite(x)&&isFinite(x)[Symbol.for("!")]?isFinite(x)[Symbol.for("!")]():!isFinite(x)}()&&(x=1),isFinite(y)&&isFinite(v)){var Z=e.tetrate(y,v,x);return this.sign=Z.sign,this.layer=Z.layer,this.mag=Z.mag,this}}var w=n.split("e"),B=function(){return void 0!==w.length&&null!==w.length&&w.length[Symbol.for("-")]?w.length[Symbol.for("-")](1):w.length-1}();if(0===B){var P=parseFloat(n);if(isFinite(P))return this.fromNumber(P)}else if(1===B){var T=parseFloat(n);if(isFinite(T)&&function(){return void 0!==T&&null!==T&&T[Symbol.for("!==")]?T[Symbol.for("!==")](0):0!==T}())return this.fromNumber(T)}var D=n.split("e^");if(2===D.length){this.sign=1,function(){return void 0!==D[0].charAt(0)&&null!==D[0].charAt(0)&&D[0].charAt(0)[Symbol.for("==")]?D[0].charAt(0)[Symbol.for("==")]("-"):"-"==D[0].charAt(0)}()&&(this.sign=function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}());for(var R="",_=0;function(){return void 0!==_&&null!==_&&_[Symbol.for("<")]?_[Symbol.for("<")](D[1].length):_=")]?O[Symbol.for(">=")](43):O>=43}()&&function(){return void 0!==O&&null!==O&&O[Symbol.for("<=")]?O[Symbol.for("<=")](57):O<=57}()||101===O))return this.layer=parseFloat(R),this.mag=parseFloat(D[1].substr(function(){return void 0!==_&&null!==_&&_[Symbol.for("+")]?_[Symbol.for("+")](1):_+1}())),this.normalize(),this;R=function(){return void 0!==R&&null!==R&&R[Symbol.for("+")]?R[Symbol.for("+")](D[1].charAt(_)):R+D[1].charAt(_)}()}}if(function(){return void 0!==B&&null!==B&&B[Symbol.for("<")]?B[Symbol.for("<")](1):B<1}())return this.sign=0,this.layer=0,this.mag=0,this;var U=parseFloat(w[0]);if(0===U)return this.sign=0,this.layer=0,this.mag=0,this;var j=parseFloat(w[function(){return void 0!==w.length&&null!==w.length&&w.length[Symbol.for("-")]?w.length[Symbol.for("-")](1):w.length-1}()]);if(function(){return void 0!==B&&null!==B&&B[Symbol.for(">=")]?B[Symbol.for(">=")](2):B>=2}()){var A=parseFloat(w[function(){return void 0!==w.length&&null!==w.length&&w.length[Symbol.for("-")]?w.length[Symbol.for("-")](2):w.length-2}()]);isFinite(A)&&(j=function(){return void 0!==j&&null!==j&&j[Symbol.for("*")]?j[Symbol.for("*")](Math.sign(A)):j*Math.sign(A)}(),j=function(){return void 0!==j&&null!==j&&j[Symbol.for("+")]?j[Symbol.for("+")](I(A)):j+I(A)}())}if(function(){return void 0!==isFinite(U)&&null!==isFinite(U)&&isFinite(U)[Symbol.for("!")]?isFinite(U)[Symbol.for("!")]():!isFinite(U)}())this.sign="-"===w[0]?function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}():1,this.layer=B,this.mag=j;else if(1===B)this.sign=Math.sign(U),this.layer=1,this.mag=function(){return void 0!==j&&null!==j&&j[Symbol.for("+")]?j[Symbol.for("+")](Math.log10(Math.abs(U))):j+Math.log10(Math.abs(U))}();else{if(this.sign=Math.sign(U),this.layer=B,2===B){var q=e.mul(F(1,2,j),E(U));return this.sign=q.sign,this.layer=q.layer,this.mag=q.mag,this}this.mag=j}return this.normalize(),this}},{key:"fromValue",value:function(n){return n instanceof e||function(){return void 0!==n&&null!==n&&n[Symbol.for("!=")]?n[Symbol.for("!=")](null):null!=n}()&&"object"===(0,S.Z)(n)&&function(){return"sign"[Symbol.for("in")]?"sign"[Symbol.for("in")](n):"sign"in n}()&&function(){return"mag"[Symbol.for("in")]?"mag"[Symbol.for("in")](n):"mag"in n}()&&function(){return"layer"[Symbol.for("in")]?"layer"[Symbol.for("in")](n):"layer"in n}()?this.fromDecimal(n):"number"===typeof n?this.fromNumber(n):"string"===typeof n?this.fromString(n):(this.sign=0,this.layer=0,this.mag=0,this)}},{key:"toNumber",value:function(){var e=this;return function(){return void 0!==Number.isFinite(e.layer)&&null!==Number.isFinite(e.layer)&&Number.isFinite(e.layer)[Symbol.for("!")]?Number.isFinite(e.layer)[Symbol.for("!")]():!Number.isFinite(e.layer)}()?Number.NaN:0===this.layer?function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}():1===this.layer?function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](Math.pow(10,e.mag)):e.sign*Math.pow(10,e.mag)}():function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for(">")]?e.mag[Symbol.for(">")](0):e.mag>0}()?function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for(">")]?e.sign[Symbol.for(">")](0):e.sign>0}()?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:0}},{key:"mantissaWithDecimalPlaces",value:function(e){return isNaN(this.m)?Number.NaN:0===this.m?0:D(this.m,e)}},{key:"magnitudeWithDecimalPlaces",value:function(e){return isNaN(this.mag)?Number.NaN:0===this.mag?0:D(this.mag,e)}},{key:"toString",value:function(){var e=this;return isNaN(this.layer)||isNaN(this.sign)||isNaN(this.mag)?"NaN":this.mag===Number.POSITIVE_INFINITY||this.layer===Number.POSITIVE_INFINITY?1===this.sign?"Infinity":"-Infinity":0===this.layer?function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](1e21):e.mag<1e21}()&&function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for(">")]?e.mag[Symbol.for(">")](1e-7):e.mag>1e-7}()||0===this.mag?function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}().toString():function(){return e.m+"e"!==void 0&&e.m+"e"!==null&&(e.m+"e")[Symbol.for("+")]?(e.m+"e")[Symbol.for("+")](e.e):e.m+"e"+e.e}():1===this.layer?function(){return e.m+"e"!==void 0&&e.m+"e"!==null&&(e.m+"e")[Symbol.for("+")]?(e.m+"e")[Symbol.for("+")](e.e):e.m+"e"+e.e}():function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("<=")]?e.layer[Symbol.for("<=")](x):e.layer<=x}()?function(){return(-1===e.sign?"-":"")+"e".repeat(e.layer)!==void 0&&(-1===e.sign?"-":"")+"e".repeat(e.layer)!==null&&((-1===e.sign?"-":"")+"e".repeat(e.layer))[Symbol.for("+")]?((-1===e.sign?"-":"")+"e".repeat(e.layer))[Symbol.for("+")](e.mag):(-1===e.sign?"-":"")+"e".repeat(e.layer)+e.mag}():function(){return(-1===e.sign?"-":"")+"(e^"+e.layer+")"!==void 0&&(-1===e.sign?"-":"")+"(e^"+e.layer+")"!==null&&((-1===e.sign?"-":"")+"(e^"+e.layer+")")[Symbol.for("+")]?((-1===e.sign?"-":"")+"(e^"+e.layer+")")[Symbol.for("+")](e.mag):(-1===e.sign?"-":"")+"(e^"+e.layer+")"+e.mag}()}},{key:"toExponential",value:function(e){var n=this;return 0===this.layer?function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}().toExponential(e):this.toStringWithDecimalPlaces(e)}},{key:"toFixed",value:function(e){var n=this;return 0===this.layer?function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}().toFixed(e):this.toStringWithDecimalPlaces(e)}},{key:"toPrecision",value:function(e){var n=this;return function(){return void 0!==n.e&&null!==n.e&&n.e[Symbol.for("<=")]?n.e[Symbol.for("<=")](-7):n.e<=-7}()?this.toExponential(function(){return void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](1):e-1}()):function(){return void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](n.e):e>n.e}()?this.toFixed(function(){return e-n.exponent!==void 0&&e-n.exponent!==null&&(e-n.exponent)[Symbol.for("-")]?(e-n.exponent)[Symbol.for("-")](1):e-n.exponent-1}()):this.toExponential(function(){return void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](1):e-1}())}},{key:"valueOf",value:function(){return this.toString()}},{key:"toJSON",value:function(){return this.toString()}},{key:"toStringWithDecimalPlaces",value:function(e){var n=this;return 0===this.layer?function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](1e21):n.mag<1e21}()&&function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for(">")]?n.mag[Symbol.for(">")](1e-7):n.mag>1e-7}()||0===this.mag?function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}().toFixed(e):function(){return D(n.m,e)+"e"!==void 0&&D(n.m,e)+"e"!==null&&(D(n.m,e)+"e")[Symbol.for("+")]?(D(n.m,e)+"e")[Symbol.for("+")](D(n.e,e)):D(n.m,e)+"e"+D(n.e,e)}():1===this.layer?function(){return D(n.m,e)+"e"!==void 0&&D(n.m,e)+"e"!==null&&(D(n.m,e)+"e")[Symbol.for("+")]?(D(n.m,e)+"e")[Symbol.for("+")](D(n.e,e)):D(n.m,e)+"e"+D(n.e,e)}():function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("<=")]?n.layer[Symbol.for("<=")](x):n.layer<=x}()?function(){return(-1===n.sign?"-":"")+"e".repeat(n.layer)!==void 0&&(-1===n.sign?"-":"")+"e".repeat(n.layer)!==null&&((-1===n.sign?"-":"")+"e".repeat(n.layer))[Symbol.for("+")]?((-1===n.sign?"-":"")+"e".repeat(n.layer))[Symbol.for("+")](D(n.mag,e)):(-1===n.sign?"-":"")+"e".repeat(n.layer)+D(n.mag,e)}():function(){return(-1===n.sign?"-":"")+"(e^"+n.layer+")"!==void 0&&(-1===n.sign?"-":"")+"(e^"+n.layer+")"!==null&&((-1===n.sign?"-":"")+"(e^"+n.layer+")")[Symbol.for("+")]?((-1===n.sign?"-":"")+"(e^"+n.layer+")")[Symbol.for("+")](D(n.mag,e)):(-1===n.sign?"-":"")+"(e^"+n.layer+")"+D(n.mag,e)}()}},{key:"abs",value:function(){return T(0===this.sign?0:1,this.layer,this.mag)}},{key:"neg",value:function(){var e=this;return T(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("minus")]?e.sign[Symbol.for("minus")]():-e.sign}(),this.layer,this.mag)}},{key:"negate",value:function(){return this.neg()}},{key:"negated",value:function(){return this.neg()}},{key:"sgn",value:function(){return this.sign}},{key:"round",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()?e.dZero:0===this.layer?F(this.sign,0,Math.round(this.mag)):this}},{key:"floor",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()?e.dZero:0===this.layer?F(this.sign,0,Math.floor(this.mag)):this}},{key:"ceil",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()?e.dZero:0===this.layer?F(this.sign,0,Math.ceil(this.mag)):this}},{key:"trunc",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()?e.dZero:0===this.layer?F(this.sign,0,Math.trunc(this.mag)):this}},{key:"add",value:function(n){var o,r,t=this,l=E(n);if(function(){return void 0!==Number.isFinite(t.layer)&&null!==Number.isFinite(t.layer)&&Number.isFinite(t.layer)[Symbol.for("!")]?Number.isFinite(t.layer)[Symbol.for("!")]():!Number.isFinite(t.layer)}())return this;if(function(){return void 0!==Number.isFinite(l.layer)&&null!==Number.isFinite(l.layer)&&Number.isFinite(l.layer)[Symbol.for("!")]?Number.isFinite(l.layer)[Symbol.for("!")]():!Number.isFinite(l.layer)}())return l;if(0===this.sign)return l;if(0===l.sign)return this;if(this.sign===function(){return void 0!==l.sign&&null!==l.sign&&l.sign[Symbol.for("minus")]?l.sign[Symbol.for("minus")]():-l.sign}()&&this.layer===l.layer&&this.mag===l.mag)return T(0,0,0);if(function(){return void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for(">=")]?t.layer[Symbol.for(">=")](2):t.layer>=2}()||function(){return void 0!==l.layer&&null!==l.layer&&l.layer[Symbol.for(">=")]?l.layer[Symbol.for(">=")](2):l.layer>=2}())return this.maxabs(l);if(!function(){return void 0!==e.cmpabs(t,l)&&null!==e.cmpabs(t,l)&&e.cmpabs(t,l)[Symbol.for(">")]?e.cmpabs(t,l)[Symbol.for(">")](0):e.cmpabs(t,l)>0}()?(o=l,r=this):(o=this,r=l),0===o.layer&&0===r.layer)return E(function(){return o.sign*o.mag!==void 0&&o.sign*o.mag!==null&&(o.sign*o.mag)[Symbol.for("+")]?(o.sign*o.mag)[Symbol.for("+")](r.sign*r.mag):o.sign*o.mag+r.sign*r.mag}());var i=function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("*")]?o.layer[Symbol.for("*")](Math.sign(o.mag)):o.layer*Math.sign(o.mag)}(),u=function(){return void 0!==r.layer&&null!==r.layer&&r.layer[Symbol.for("*")]?r.layer[Symbol.for("*")](Math.sign(r.mag)):r.layer*Math.sign(r.mag)}();if(function(){return i-u!==void 0&&i-u!==null&&(i-u)[Symbol.for(">=")]?(i-u)[Symbol.for(">=")](2):i-u>=2}())return o;if(0===i&&u===function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()){if(function(){return void 0!==Math.abs(r.mag-Math.log10(o.mag))&&null!==Math.abs(r.mag-Math.log10(o.mag))&&Math.abs(r.mag-Math.log10(o.mag))[Symbol.for(">")]?Math.abs(r.mag-Math.log10(o.mag))[Symbol.for(">")](g):Math.abs(r.mag-Math.log10(o.mag))>g}())return o;var a=Math.pow(10,function(){return void 0!==Math.log10(o.mag)&&null!==Math.log10(o.mag)&&Math.log10(o.mag)[Symbol.for("-")]?Math.log10(o.mag)[Symbol.for("-")](r.mag):Math.log10(o.mag)-r.mag}()),f=function(){return void 0!==r.sign&&null!==r.sign&&r.sign[Symbol.for("+")]?r.sign[Symbol.for("+")](o.sign*a):r.sign+o.sign*a}();return F(Math.sign(f),1,function(){return void 0!==r.mag&&null!==r.mag&&r.mag[Symbol.for("+")]?r.mag[Symbol.for("+")](Math.log10(Math.abs(f))):r.mag+Math.log10(Math.abs(f))}())}if(1===i&&0===u){if(function(){return void 0!==Math.abs(o.mag-Math.log10(r.mag))&&null!==Math.abs(o.mag-Math.log10(r.mag))&&Math.abs(o.mag-Math.log10(r.mag))[Symbol.for(">")]?Math.abs(o.mag-Math.log10(r.mag))[Symbol.for(">")](g):Math.abs(o.mag-Math.log10(r.mag))>g}())return o;var c=Math.pow(10,function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("-")]?o.mag[Symbol.for("-")](Math.log10(r.mag)):o.mag-Math.log10(r.mag)}()),s=function(){return void 0!==r.sign&&null!==r.sign&&r.sign[Symbol.for("+")]?r.sign[Symbol.for("+")](o.sign*c):r.sign+o.sign*c}();return F(Math.sign(s),1,function(){return void 0!==Math.log10(r.mag)&&null!==Math.log10(r.mag)&&Math.log10(r.mag)[Symbol.for("+")]?Math.log10(r.mag)[Symbol.for("+")](Math.log10(Math.abs(s))):Math.log10(r.mag)+Math.log10(Math.abs(s))}())}if(function(){return void 0!==Math.abs(o.mag-r.mag)&&null!==Math.abs(o.mag-r.mag)&&Math.abs(o.mag-r.mag)[Symbol.for(">")]?Math.abs(o.mag-r.mag)[Symbol.for(">")](g):Math.abs(o.mag-r.mag)>g}())return o;var m=Math.pow(10,function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("-")]?o.mag[Symbol.for("-")](r.mag):o.mag-r.mag}()),d=function(){return void 0!==r.sign&&null!==r.sign&&r.sign[Symbol.for("+")]?r.sign[Symbol.for("+")](o.sign*m):r.sign+o.sign*m}();return F(Math.sign(d),1,function(){return void 0!==r.mag&&null!==r.mag&&r.mag[Symbol.for("+")]?r.mag[Symbol.for("+")](Math.log10(Math.abs(d))):r.mag+Math.log10(Math.abs(d))}())}},{key:"plus",value:function(e){return this.add(e)}},{key:"sub",value:function(e){return this.add(E(e).neg())}},{key:"subtract",value:function(e){return this.sub(e)}},{key:"minus",value:function(e){return this.sub(e)}},{key:"mul",value:function(e){var n,o,r=this,t=E(e);if(function(){return void 0!==Number.isFinite(r.layer)&&null!==Number.isFinite(r.layer)&&Number.isFinite(r.layer)[Symbol.for("!")]?Number.isFinite(r.layer)[Symbol.for("!")]():!Number.isFinite(r.layer)}())return this;if(function(){return void 0!==Number.isFinite(t.layer)&&null!==Number.isFinite(t.layer)&&Number.isFinite(t.layer)[Symbol.for("!")]?Number.isFinite(t.layer)[Symbol.for("!")]():!Number.isFinite(t.layer)}())return t;if(0===this.sign||0===t.sign)return T(0,0,0);if(this.layer===t.layer&&this.mag===function(){return void 0!==t.mag&&null!==t.mag&&t.mag[Symbol.for("minus")]?t.mag[Symbol.for("minus")]():-t.mag}())return T(function(){return void 0!==r.sign&&null!==r.sign&&r.sign[Symbol.for("*")]?r.sign[Symbol.for("*")](t.sign):r.sign*t.sign}(),0,1);if(function(){return void 0!==r.layer&&null!==r.layer&&r.layer[Symbol.for(">")]?r.layer[Symbol.for(">")](t.layer):r.layer>t.layer}()||function(){return void 0!==r.layer&&null!==r.layer&&r.layer[Symbol.for("==")]?r.layer[Symbol.for("==")](t.layer):r.layer==t.layer}()&&function(){return void 0!==Math.abs(r.mag)&&null!==Math.abs(r.mag)&&Math.abs(r.mag)[Symbol.for(">")]?Math.abs(r.mag)[Symbol.for(">")](Math.abs(t.mag)):Math.abs(r.mag)>Math.abs(t.mag)}()?(n=this,o=t):(n=t,o=this),0===n.layer&&0===o.layer)return E(function(){return n.sign*o.sign*n.mag!==void 0&&n.sign*o.sign*n.mag!==null&&(n.sign*o.sign*n.mag)[Symbol.for("*")]?(n.sign*o.sign*n.mag)[Symbol.for("*")](o.mag):n.sign*o.sign*n.mag*o.mag}());if(function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for(">=")]?n.layer[Symbol.for(">=")](3):n.layer>=3}()||function(){return n.layer-o.layer!==void 0&&n.layer-o.layer!==null&&(n.layer-o.layer)[Symbol.for(">=")]?(n.layer-o.layer)[Symbol.for(">=")](2):n.layer-o.layer>=2}())return F(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](o.sign):n.sign*o.sign}(),n.layer,n.mag);if(1===n.layer&&0===o.layer)return F(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](o.sign):n.sign*o.sign}(),1,function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("+")]?n.mag[Symbol.for("+")](Math.log10(o.mag)):n.mag+Math.log10(o.mag)}());if(1===n.layer&&1===o.layer)return F(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](o.sign):n.sign*o.sign}(),1,function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("+")]?n.mag[Symbol.for("+")](o.mag):n.mag+o.mag}());if(2===n.layer&&1===o.layer){var l=F(Math.sign(n.mag),function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),Math.abs(n.mag)).add(F(Math.sign(o.mag),function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("-")]?o.layer[Symbol.for("-")](1):o.layer-1}(),Math.abs(o.mag)));return F(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](o.sign):n.sign*o.sign}(),function(){return void 0!==l.layer&&null!==l.layer&&l.layer[Symbol.for("+")]?l.layer[Symbol.for("+")](1):l.layer+1}(),function(){return void 0!==l.sign&&null!==l.sign&&l.sign[Symbol.for("*")]?l.sign[Symbol.for("*")](l.mag):l.sign*l.mag}())}if(2===n.layer&&2===o.layer){var i=F(Math.sign(n.mag),function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),Math.abs(n.mag)).add(F(Math.sign(o.mag),function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("-")]?o.layer[Symbol.for("-")](1):o.layer-1}(),Math.abs(o.mag)));return F(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](o.sign):n.sign*o.sign}(),function(){return void 0!==i.layer&&null!==i.layer&&i.layer[Symbol.for("+")]?i.layer[Symbol.for("+")](1):i.layer+1}(),function(){return void 0!==i.sign&&null!==i.sign&&i.sign[Symbol.for("*")]?i.sign[Symbol.for("*")](i.mag):i.sign*i.mag}())}throw Error(function(){return"Bad arguments to mul: "+r+", "!==void 0&&"Bad arguments to mul: "+r+", "!==null&&("Bad arguments to mul: "+r+", ")[Symbol.for("+")]?("Bad arguments to mul: "+r+", ")[Symbol.for("+")](e):"Bad arguments to mul: "+r+", "+e}())}},{key:"multiply",value:function(e){return this.mul(e)}},{key:"times",value:function(e){return this.mul(e)}},{key:"div",value:function(e){var n=E(e);return this.mul(n.recip())}},{key:"divide",value:function(e){return this.div(e)}},{key:"divideBy",value:function(e){return this.div(e)}},{key:"dividedBy",value:function(e){return this.div(e)}},{key:"recip",value:function(){var n=this;return 0===this.mag?e.dNaN:0===this.layer?F(this.sign,0,function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](n.mag):1/n.mag}()):F(this.sign,this.layer,function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("minus")]?n.mag[Symbol.for("minus")]():-n.mag}())}},{key:"reciprocal",value:function(){return this.recip()}},{key:"reciprocate",value:function(){return this.recip()}},{key:"cmp",value:function(e){var n=this,o=E(e);return function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for(">")]?n.sign[Symbol.for(">")](o.sign):n.sign>o.sign}()?1:function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("<")]?n.sign[Symbol.for("<")](o.sign):n.sign")]?n.mag[Symbol.for(">")](0):n.mag>0}()?this.layer:function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("minus")]?n.layer[Symbol.for("minus")]():-n.layer}(),t=function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for(">")]?o.mag[Symbol.for(">")](0):o.mag>0}()?o.layer:function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("minus")]?o.layer[Symbol.for("minus")]():-o.layer}();return function(){return void 0!==r&&null!==r&&r[Symbol.for(">")]?r[Symbol.for(">")](t):r>t}()?1:function(){return void 0!==r&&null!==r&&r[Symbol.for("<")]?r[Symbol.for("<")](t):r")]?n.mag[Symbol.for(">")](o.mag):n.mag>o.mag}()?1:function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](o.mag):n.mag")]?n.cmpabs(o)[Symbol.for(">")](0):n.cmpabs(o)>0}()?o:this}},{key:"clamp",value:function(e,n){return this.max(e).min(n)}},{key:"clampMin",value:function(e){return this.max(e)}},{key:"clampMax",value:function(e){return this.min(e)}},{key:"cmp_tolerance",value:function(e,n){var o=E(e);return this.eq_tolerance(o,n)?0:this.cmp(o)}},{key:"compare_tolerance",value:function(e,n){return this.cmp_tolerance(e,n)}},{key:"eq_tolerance",value:function(e,n){var o=this,r=E(e);if(function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()&&(n=1e-7),function(){return void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for("!==")]?o.sign[Symbol.for("!==")](r.sign):o.sign!==r.sign}())return!1;if(function(){return void 0!==Math.abs(o.layer-r.layer)&&null!==Math.abs(o.layer-r.layer)&&Math.abs(o.layer-r.layer)[Symbol.for(">")]?Math.abs(o.layer-r.layer)[Symbol.for(">")](1):Math.abs(o.layer-r.layer)>1}())return!1;var t=this.mag,l=r.mag;return function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">")]?o.layer[Symbol.for(">")](r.layer):o.layer>r.layer}()&&(l=I(l)),function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](r.layer):o.layer")]?n.layer[Symbol.for(">")](0):n.layer>0}()?F(Math.sign(this.mag),function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),Math.abs(this.mag)):F(1,0,Math.log10(this.mag))}},{key:"log10",value:function(){var n=this;return function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("<=")]?n.sign[Symbol.for("<=")](0):n.sign<=0}()?e.dNaN:function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for(">")]?n.layer[Symbol.for(">")](0):n.layer>0}()?F(Math.sign(this.mag),function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),Math.abs(this.mag)):F(this.sign,0,Math.log10(this.mag))}},{key:"log",value:function(n){var o=this;return n=E(n),function(){return void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for("<=")]?o.sign[Symbol.for("<=")](0):o.sign<=0}()||function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("<=")]?n.sign[Symbol.for("<=")](0):n.sign<=0}()||1===n.sign&&0===n.layer&&1===n.mag?e.dNaN:0===this.layer&&0===n.layer?F(this.sign,0,function(){return void 0!==Math.log(o.mag)&&null!==Math.log(o.mag)&&Math.log(o.mag)[Symbol.for("/")]?Math.log(o.mag)[Symbol.for("/")](Math.log(n.mag)):Math.log(o.mag)/Math.log(n.mag)}()):e.div(this.log10(),n.log10())}},{key:"log2",value:function(){var n=this;return function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("<=")]?n.sign[Symbol.for("<=")](0):n.sign<=0}()?e.dNaN:0===this.layer?F(this.sign,0,Math.log2(this.mag)):1===this.layer?F(Math.sign(this.mag),0,function(){return void 0!==Math.abs(n.mag)&&null!==Math.abs(n.mag)&&Math.abs(n.mag)[Symbol.for("*")]?Math.abs(n.mag)[Symbol.for("*")](3.321928094887362):3.321928094887362*Math.abs(n.mag)}()):2===this.layer?F(Math.sign(this.mag),1,function(){return void 0!==Math.abs(n.mag)&&null!==Math.abs(n.mag)&&Math.abs(n.mag)[Symbol.for("+")]?Math.abs(n.mag)[Symbol.for("+")](.5213902276543247):Math.abs(n.mag)+.5213902276543247}()):F(Math.sign(this.mag),function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),Math.abs(this.mag))}},{key:"ln",value:function(){var n=this;return function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("<=")]?n.sign[Symbol.for("<=")](0):n.sign<=0}()?e.dNaN:0===this.layer?F(this.sign,0,Math.log(this.mag)):1===this.layer?F(Math.sign(this.mag),0,function(){return void 0!==Math.abs(n.mag)&&null!==Math.abs(n.mag)&&Math.abs(n.mag)[Symbol.for("*")]?Math.abs(n.mag)[Symbol.for("*")](2.302585092994046):2.302585092994046*Math.abs(n.mag)}()):2===this.layer?F(Math.sign(this.mag),1,function(){return void 0!==Math.abs(n.mag)&&null!==Math.abs(n.mag)&&Math.abs(n.mag)[Symbol.for("+")]?Math.abs(n.mag)[Symbol.for("+")](.36221568869946325):Math.abs(n.mag)+.36221568869946325}()):F(Math.sign(this.mag),function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),Math.abs(this.mag))}},{key:"logarithm",value:function(e){return this.log(e)}},{key:"pow",value:function(n){var o=E(n),r=this,t=o;if(0===r.sign)return t.eq(0)?T(1,0,1):r;if(1===r.sign&&0===r.layer&&1===r.mag)return r;if(0===t.sign)return T(1,0,1);if(1===t.sign&&0===t.layer&&1===t.mag)return r;var l=r.absLog10().mul(t).pow10();return this.sign===function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()?1===function(){return void 0!==Math.abs(t.toNumber()%2)&&null!==Math.abs(t.toNumber()%2)&&Math.abs(t.toNumber()%2)[Symbol.for("%")]?Math.abs(t.toNumber()%2)[Symbol.for("%")](2):Math.abs(t.toNumber()%2)%2}()?l.neg():0===function(){return void 0!==Math.abs(t.toNumber()%2)&&null!==Math.abs(t.toNumber()%2)&&Math.abs(t.toNumber()%2)[Symbol.for("%")]?Math.abs(t.toNumber()%2)[Symbol.for("%")](2):Math.abs(t.toNumber()%2)%2}()?l:e.dNaN:l}},{key:"pow10",value:function(){var n=this;if(function(){return void 0!==Number.isFinite(n.layer)&&null!==Number.isFinite(n.layer)&&Number.isFinite(n.layer)[Symbol.for("!")]?Number.isFinite(n.layer)[Symbol.for("!")]():!Number.isFinite(n.layer)}()||function(){return void 0!==Number.isFinite(n.mag)&&null!==Number.isFinite(n.mag)&&Number.isFinite(n.mag)[Symbol.for("!")]?Number.isFinite(n.mag)[Symbol.for("!")]():!Number.isFinite(n.mag)}())return e.dNaN;var o=this;if(0===o.layer){var r=Math.pow(10,function(){return void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for("*")]?o.sign[Symbol.for("*")](o.mag):o.sign*o.mag}());if(Number.isFinite(r)&&function(){return void 0!==Math.abs(r)&&null!==Math.abs(r)&&Math.abs(r)[Symbol.for(">=")]?Math.abs(r)[Symbol.for(">=")](.1):Math.abs(r)>=.1}())return F(1,0,r);if(0===o.sign)return e.dOne;o=T(o.sign,function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](1):o.layer+1}(),Math.log10(o.mag))}return function(){return void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for(">")]?o.sign[Symbol.for(">")](0):o.sign>0}()&&function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for(">=")]?o.mag[Symbol.for(">=")](0):o.mag>=0}()?F(o.sign,function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](1):o.layer+1}(),o.mag):function(){return void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for("<")]?o.sign[Symbol.for("<")](0):o.sign<0}()&&function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for(">=")]?o.mag[Symbol.for(">=")](0):o.mag>=0}()?F(function(){return void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for("minus")]?o.sign[Symbol.for("minus")]():-o.sign}(),function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](1):o.layer+1}(),function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("minus")]?o.mag[Symbol.for("minus")]():-o.mag}()):e.dOne}},{key:"pow_base",value:function(e){return E(e).pow(this)}},{key:"root",value:function(e){var n=E(e);return this.pow(n.recip())}},{key:"factorial",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()||0===this.layer?this.add(1).gamma():1===this.layer?e.exp(e.mul(this,e.ln(this).sub(1))):e.exp(this)}},{key:"gamma",value:function(){var n=this;if(function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}())return this.recip();if(0===this.layer){if(this.lt(T(1,0,24)))return E(R(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}()));var o=function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("-")]?n.mag[Symbol.for("-")](1):n.mag-1}(),r=.9189385332046727;r=function(){return void 0!==r&&null!==r&&r[Symbol.for("+")]?r[Symbol.for("+")]((o+.5)*Math.log(o)):r+(o+.5)*Math.log(o)}(),r=function(){return void 0!==r&&null!==r&&r[Symbol.for("-")]?r[Symbol.for("-")](o):r-o}();var t=function(){return void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](o):o*o}(),l=o,i=function(){return 12[Symbol.for("*")]?12[Symbol.for("*")](l):12*l}(),u=function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](i):1/i}(),a=function(){return void 0!==r&&null!==r&&r[Symbol.for("+")]?r[Symbol.for("+")](u):r+u}();if(a===r)return e.exp(r);if(r=a,l=function(){return void 0!==l&&null!==l&&l[Symbol.for("*")]?l[Symbol.for("*")](t):l*t}(),i=function(){return 360[Symbol.for("*")]?360[Symbol.for("*")](l):360*l}(),u=function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](i):1/i}(),a=function(){return void 0!==r&&null!==r&&r[Symbol.for("-")]?r[Symbol.for("-")](u):r-u}(),a===r)return e.exp(r);r=a,l=function(){return void 0!==l&&null!==l&&l[Symbol.for("*")]?l[Symbol.for("*")](t):l*t}(),i=function(){return 1260[Symbol.for("*")]?1260[Symbol.for("*")](l):1260*l}();var f=function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](i):1/i}();return r=function(){return void 0!==r&&null!==r&&r[Symbol.for("+")]?r[Symbol.for("+")](f):r+f}(),l=function(){return void 0!==l&&null!==l&&l[Symbol.for("*")]?l[Symbol.for("*")](t):l*t}(),i=function(){return 1680[Symbol.for("*")]?1680[Symbol.for("*")](l):1680*l}(),f=function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](i):1/i}(),r=function(){return void 0!==r&&null!==r&&r[Symbol.for("-")]?r[Symbol.for("-")](f):r-f}(),e.exp(r)}return 1===this.layer?e.exp(e.mul(this,e.ln(this).sub(1))):e.exp(this)}},{key:"lngamma",value:function(){return this.gamma().ln()}},{key:"exp",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()?e.dOne:0===this.layer&&function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<=")]?n.mag[Symbol.for("<=")](709.7):n.mag<=709.7}()?E(Math.exp(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}())):0===this.layer?F(1,1,function(){return n.sign*Math.log10(Math.E)!==void 0&&n.sign*Math.log10(Math.E)!==null&&(n.sign*Math.log10(Math.E))[Symbol.for("*")]?(n.sign*Math.log10(Math.E))[Symbol.for("*")](n.mag):n.sign*Math.log10(Math.E)*n.mag}()):1===this.layer?F(1,2,function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](Math.log10(.4342944819032518)+n.mag):n.sign*(Math.log10(.4342944819032518)+n.mag)}()):F(1,function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("+")]?n.layer[Symbol.for("+")](1):n.layer+1}(),function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}())}},{key:"sqr",value:function(){return this.pow(2)}},{key:"sqrt",value:function(){var n=this;if(0===this.layer)return E(Math.sqrt(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}()));if(1===this.layer)return F(1,2,function(){return void 0!==Math.log10(n.mag)&&null!==Math.log10(n.mag)&&Math.log10(n.mag)[Symbol.for("-")]?Math.log10(n.mag)[Symbol.for("-")](.3010299956639812):Math.log10(n.mag)-.3010299956639812}());var o=e.div(T(this.sign,function(){return void 0!==n.layer&&null!==n.layer&&n.layer[Symbol.for("-")]?n.layer[Symbol.for("-")](1):n.layer-1}(),this.mag),T(1,0,2));return o.layer=function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](1):o.layer+1}(),o.normalize(),o}},{key:"cube",value:function(){return this.pow(3)}},{key:"cbrt",value:function(){return this.pow(function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](3):1/3}())}},{key:"tetrate",value:function(){var n=arguments,o=this,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](0):n.length>0}()&&function(){return void 0!==n[0]&&null!==n[0]&&n[0][Symbol.for("!==")]?n[0][Symbol.for("!==")](void 0):void 0!==n[0]}()?arguments[0]:2,t=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:T(1,0,1);if(1===r)return e.pow(this,t);if(0===r)return new e(t);if(this.eq(e.dOne))return e.dOne;if(this.eq(function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()))return e.pow(this,t);if(r===Number.POSITIVE_INFINITY){var l=this.toNumber();if(function(){return void 0!==l&&null!==l&&l[Symbol.for("<=")]?l[Symbol.for("<=")](1.444667861009766):l<=1.444667861009766}()&&function(){return void 0!==l&&null!==l&&l[Symbol.for(">=")]?l[Symbol.for(">=")](.06598803584531254):l>=.06598803584531254}()){if(function(){return void 0!==l&&null!==l&&l[Symbol.for(">")]?l[Symbol.for(">")](1.444667861009099):l>1.444667861009099}())return new e(Math.E);var i=e.ln(this).neg();return i.lambertw().div(i)}return function(){return void 0!==l&&null!==l&&l[Symbol.for(">")]?l[Symbol.for(">")](1.444667861009766):l>1.444667861009766}()?new e(Number.POSITIVE_INFINITY):e.dNaN}if(this.eq(e.dZero)){var u=Math.abs(function(){return r+1!==void 0&&r+1!==null&&(r+1)[Symbol.for("%")]?(r+1)[Symbol.for("%")](2):(r+1)%2}());return function(){return void 0!==u&&null!==u&&u[Symbol.for(">")]?u[Symbol.for(">")](1):u>1}()&&(u=function(){return 2[Symbol.for("-")]?2[Symbol.for("-")](u):2-u}()),new e(u)}if(function(){return void 0!==r&&null!==r&&r[Symbol.for("<")]?r[Symbol.for("<")](0):r<0}())return e.iteratedlog(t,this,function(){return void 0!==r&&null!==r&&r[Symbol.for("minus")]?r[Symbol.for("minus")]():-r}());t=E(t);var a=r;r=Math.trunc(r);var f=function(){return void 0!==a&&null!==a&&a[Symbol.for("-")]?a[Symbol.for("-")](r):a-r}();if(this.gt(e.dZero)&&this.lte(1.444667861009766)){r=Math.min(1e4,r);for(var c=0;function(){return void 0!==c&&null!==c&&c[Symbol.for("<")]?c[Symbol.for("<")](r):c")]?(t.layer-o.layer)[Symbol.for(">")](3):t.layer-o.layer>3}())return T(t.sign,function(){return void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("+")]?t.layer[Symbol.for("+")](r-d-1):t.layer+(r-d-1)}(),t.mag);if(function(){return void 0!==d&&null!==d&&d[Symbol.for(">")]?d[Symbol.for(">")](1e4):d>1e4}())return t}return t}},{key:"iteratedexp",value:function(){var e=arguments,n=function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](0):e.length>0}()&&function(){return void 0!==e[0]&&null!==e[0]&&e[0][Symbol.for("!==")]?e[0][Symbol.for("!==")](void 0):void 0!==e[0]}()?arguments[0]:2,o=function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](1):e.length>1}()&&function(){return void 0!==e[1]&&null!==e[1]&&e[1][Symbol.for("!==")]?e[1][Symbol.for("!==")](void 0):void 0!==e[1]}()?arguments[1]:T(1,0,1);return this.tetrate(n,o)}},{key:"iteratedlog",value:function(){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](0):n.length>0}()&&function(){return void 0!==n[0]&&null!==n[0]&&n[0][Symbol.for("!==")]?n[0][Symbol.for("!==")](void 0):void 0!==n[0]}()?arguments[0]:10,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:1;if(function(){return void 0!==r&&null!==r&&r[Symbol.for("<")]?r[Symbol.for("<")](0):r<0}())return e.tetrate(o,function(){return void 0!==r&&null!==r&&r[Symbol.for("minus")]?r[Symbol.for("minus")]():-r}(),this);o=E(o);var t=E(this),l=r;r=Math.trunc(r);var i=function(){return void 0!==l&&null!==l&&l[Symbol.for("-")]?l[Symbol.for("-")](r):l-r}();if(function(){return t.layer-o.layer!==void 0&&t.layer-o.layer!==null&&(t.layer-o.layer)[Symbol.for(">")]?(t.layer-o.layer)[Symbol.for(">")](3):t.layer-o.layer>3}()){var u=Math.min(r,function(){return t.layer-o.layer!==void 0&&t.layer-o.layer!==null&&(t.layer-o.layer)[Symbol.for("-")]?(t.layer-o.layer)[Symbol.for("-")](3):t.layer-o.layer-3}());r=function(){return void 0!==r&&null!==r&&r[Symbol.for("-")]?r[Symbol.for("-")](u):r-u}(),t.layer=function(){return void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("-")]?t.layer[Symbol.for("-")](u):t.layer-u}()}for(var a=0;function(){return void 0!==a&&null!==a&&a[Symbol.for("<")]?a[Symbol.for("<")](r):a")]?a[Symbol.for(">")](1e4):a>1e4}())return t}return function(){return void 0!==i&&null!==i&&i[Symbol.for(">")]?i[Symbol.for(">")](0):i>0}()&&function(){return void 0!==i&&null!==i&&i[Symbol.for("<")]?i[Symbol.for("<")](1):i<1}()&&(t=o.eq(10)?t.layeradd10(function(){return void 0!==i&&null!==i&&i[Symbol.for("minus")]?i[Symbol.for("minus")]():-i}()):t.layeradd(function(){return void 0!==i&&null!==i&&i[Symbol.for("minus")]?i[Symbol.for("minus")]():-i}(),o)),t}},{key:"slog",value:function(){var n=arguments,o=this,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](0):n.length>0}()&&function(){return void 0!==n[0]&&null!==n[0]&&n[0][Symbol.for("!==")]?n[0][Symbol.for("!==")](void 0):void 0!==n[0]}()?arguments[0]:10;if(r=E(r),r.lte(e.dZero))return e.dNaN;if(r.eq(e.dOne))return e.dNaN;if(r.lt(e.dOne))return this.eq(e.dOne)?e.dZero:this.eq(e.dZero)?e.dNegOne:e.dNaN;if(function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("<")]?o.mag[Symbol.for("<")](0):o.mag<0}()||this.eq(e.dZero))return e.dNegOne;var t=0,l=E(this);if(function(){return l.layer-r.layer!==void 0&&l.layer-r.layer!==null&&(l.layer-r.layer)[Symbol.for(">")]?(l.layer-r.layer)[Symbol.for(">")](3):l.layer-r.layer>3}()){var i=function(){return l.layer-r.layer!==void 0&&l.layer-r.layer!==null&&(l.layer-r.layer)[Symbol.for("-")]?(l.layer-r.layer)[Symbol.for("-")](3):l.layer-r.layer-3}();t=function(){return void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](i):t+i}(),l.layer=function(){return void 0!==l.layer&&null!==l.layer&&l.layer[Symbol.for("-")]?l.layer[Symbol.for("-")](i):l.layer-i}()}for(var u=0;function(){return void 0!==u&&null!==u&&u[Symbol.for("<")]?u[Symbol.for("<")](100):u<100}();function(){return void 0!==u&&null!==u&&"object"===(0,S.Z)(u)&&u[Symbol.for("prefix-increment")]?u[Symbol.for("prefix-increment")]():++u}())if(l.lt(e.dZero))l=e.pow(r,l),t=function(){return void 0!==t&&null!==t&&t[Symbol.for("-")]?t[Symbol.for("-")](1):t-1}();else{if(l.lte(e.dOne))return E(function(){return void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](e.slog_critical(r.toNumber(),l.toNumber())):t+e.slog_critical(r.toNumber(),l.toNumber())}());t=function(){return void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1):t+1}(),l=e.log(l,r)}return E(t)}},{key:"layeradd10",value:function(n){n=e.fromValue_noAlloc(n).toNumber();var o=E(this);if(function(){return void 0!==n&&null!==n&&n[Symbol.for(">=")]?n[Symbol.for(">=")](1):n>=1}()){(function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("<")]?o.mag[Symbol.for("<")](0):o.mag<0})()&&function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">")]?o.layer[Symbol.for(">")](0):o.layer>0}()?(o.sign=0,o.mag=0,o.layer=0):o.sign===function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()&&function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("==")]?o.layer[Symbol.for("==")](0):0==o.layer}()&&(o.sign=1,o.mag=function(){return void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("minus")]?o.mag[Symbol.for("minus")]():-o.mag}());var r=Math.trunc(n);n=function(){return void 0!==n&&null!==n&&n[Symbol.for("-")]?n[Symbol.for("-")](r):n-r}(),o.layer=function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](r):o.layer+r}()}if(function(){return void 0!==n&&null!==n&&n[Symbol.for("<=")]?n[Symbol.for("<=")](-1):n<=-1}()){var t=Math.trunc(n);if(n=function(){return void 0!==n&&null!==n&&n[Symbol.for("-")]?n[Symbol.for("-")](t):n-t}(),o.layer=function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](t):o.layer+t}(),function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](0):o.layer<0}())for(var l=0;function(){return void 0!==l&&null!==l&&l[Symbol.for("<")]?l[Symbol.for("<")](100):l<100}();function(){return void 0!==l&&null!==l&&"object"===(0,S.Z)(l)&&l[Symbol.for("prefix-increment")]?l[Symbol.for("prefix-increment")]():++l}()){if(function(){void 0!==o.layer&&null!==o.layer&&"object"===(0,S.Z)(o.layer)&&o.layer[Symbol.for("postfix-increment")]?o.layer[Symbol.for("postfix-increment")]():o.layer++}(),o.mag=Math.log10(o.mag),function(){return void 0!==isFinite(o.mag)&&null!==isFinite(o.mag)&&isFinite(o.mag)[Symbol.for("!")]?isFinite(o.mag)[Symbol.for("!")]():!isFinite(o.mag)}())return 0===o.sign&&(o.sign=1),function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](0):o.layer<0}()&&(o.layer=0),o.normalize();if(function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">=")]?o.layer[Symbol.for(">=")](0):o.layer>=0}())break}}while(function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](0):o.layer<0}())(function(){void 0!==o.layer&&null!==o.layer&&"object"===(0,S.Z)(o.layer)&&o.layer[Symbol.for("postfix-increment")]?o.layer[Symbol.for("postfix-increment")]():o.layer++})(),o.mag=Math.log10(o.mag);return 0===o.sign&&(o.sign=1,0===o.mag&&function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">=")]?o.layer[Symbol.for(">=")](1):o.layer>=1}()&&(o.layer=function(){return void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("-")]?o.layer[Symbol.for("-")](1):o.layer-1}(),o.mag=1)),o.normalize(),function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](0):0!==n}()?o.layeradd(n,10):o}},{key:"layeradd",value:function(n,o){var r=this.slog(o).toNumber(),t=function(){return void 0!==r&&null!==r&&r[Symbol.for("+")]?r[Symbol.for("+")](n):r+n}();return function(){return void 0!==t&&null!==t&&t[Symbol.for(">=")]?t[Symbol.for(">=")](0):t>=0}()?e.tetrate(o,t):function(){return void 0!==Number.isFinite(t)&&null!==Number.isFinite(t)&&Number.isFinite(t)[Symbol.for("!")]?Number.isFinite(t)[Symbol.for("!")]():!Number.isFinite(t)}()?e.dNaN:function(){return void 0!==t&&null!==t&&t[Symbol.for(">=")]?t[Symbol.for(">=")](-1):t>=-1}()?e.log(e.tetrate(o,function(){return void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1):t+1}()),o):e.log(e.log(e.tetrate(o,function(){return void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](2):t+2}()),o),o)}},{key:"lambertw",value:function(){var e=this;if(this.lt(function(){return.3678794411710499[Symbol.for("minus")]?.3678794411710499[Symbol.for("minus")]():-.3678794411710499}()))throw Error("lambertw is unimplemented for results less than -1, sorry!");if(function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}())return E(O(this.toNumber()));if(0===this.layer)return E(O(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}()));if(1===this.layer)return U(this);if(2===this.layer)return U(this);if(function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for(">=")]?e.layer[Symbol.for(">=")](3):e.layer>=3}())return T(this.sign,function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("-")]?e.layer[Symbol.for("-")](1):e.layer-1}(),this.mag);throw"Unhandled behavior in lambertw()"}},{key:"ssqrt",value:function(){var e=this;if(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("==")]?e.sign[Symbol.for("==")](1):1==e.sign}()&&function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for(">=")]?e.layer[Symbol.for(">=")](3):e.layer>=3}())return T(this.sign,function(){return void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("-")]?e.layer[Symbol.for("-")](1):e.layer-1}(),this.mag);var n=this.ln();return n.div(n.lambertw())}},{key:"pentate",value:function(){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](0):n.length>0}()&&function(){return void 0!==n[0]&&null!==n[0]&&n[0][Symbol.for("!==")]?n[0][Symbol.for("!==")](void 0):void 0!==n[0]}()?arguments[0]:2,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:T(1,0,1);r=E(r);var t=o;o=Math.trunc(o);var l=function(){return void 0!==t&&null!==t&&t[Symbol.for("-")]?t[Symbol.for("-")](o):t-o}();(function(){return void 0!==l&&null!==l&&l[Symbol.for("!==")]?l[Symbol.for("!==")](0):0!==l})()&&(r.eq(e.dOne)?(function(){void 0!==o&&null!==o&&"object"===(0,S.Z)(o)&&o[Symbol.for("prefix-increment")]?o[Symbol.for("prefix-increment")]():++o}(),r=new e(l)):r=this.eq(10)?r.layeradd10(l):r.layeradd(l,this));for(var i=0;function(){return void 0!==i&&null!==i&&i[Symbol.for("<")]?i[Symbol.for("<")](o):i")]?i[Symbol.for(">")](10):i>10}())return r}return r}},{key:"sin",value:function(){var e=this;return function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()?this:0===this.layer?E(Math.sin(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}())):T(0,0,0)}},{key:"cos",value:function(){var n=this;return function(){return void 0!==n.mag&&null!==n.mag&&n.mag[Symbol.for("<")]?n.mag[Symbol.for("<")](0):n.mag<0}()?e.dOne:0===this.layer?E(Math.cos(function(){return void 0!==n.sign&&null!==n.sign&&n.sign[Symbol.for("*")]?n.sign[Symbol.for("*")](n.mag):n.sign*n.mag}())):T(0,0,0)}},{key:"tan",value:function(){var e=this;return function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()?this:0===this.layer?E(Math.tan(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}())):T(0,0,0)}},{key:"asin",value:function(){var e=this;return function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()?this:0===this.layer?E(Math.asin(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}())):T(Number.NaN,Number.NaN,Number.NaN)}},{key:"acos",value:function(){var e=this;return function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()?E(Math.acos(this.toNumber())):0===this.layer?E(Math.acos(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}())):T(Number.NaN,Number.NaN,Number.NaN)}},{key:"atan",value:function(){var e=this;return function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](0):e.mag<0}()?this:0===this.layer?E(Math.atan(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag}())):E(Math.atan(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](Infinity):Infinity*e.sign}()))}},{key:"sinh",value:function(){return this.exp().sub(this.negate().exp()).div(2)}},{key:"cosh",value:function(){return this.exp().add(this.negate().exp()).div(2)}},{key:"tanh",value:function(){return this.sinh().div(this.cosh())}},{key:"asinh",value:function(){return e.ln(this.add(this.sqr().add(1).sqrt()))}},{key:"acosh",value:function(){return e.ln(this.add(this.sqr().sub(1).sqrt()))}},{key:"atanh",value:function(){return this.abs().gte(1)?T(Number.NaN,Number.NaN,Number.NaN):e.ln(this.add(1).div(E(1).sub(this))).div(2)}},{key:"ascensionPenalty",value:function(n){return 0===n?this:this.root(e.pow(10,n))}},{key:"egg",value:function(){return this.add(9)}},{key:"lessThanOrEqualTo",value:function(e){var n=this;return function(){return void 0!==n.cmp(e)&&null!==n.cmp(e)&&n.cmp(e)[Symbol.for("<")]?n.cmp(e)[Symbol.for("<")](1):n.cmp(e)<1}()}},{key:"lessThan",value:function(e){var n=this;return function(){return void 0!==n.cmp(e)&&null!==n.cmp(e)&&n.cmp(e)[Symbol.for("<")]?n.cmp(e)[Symbol.for("<")](0):n.cmp(e)<0}()}},{key:"greaterThanOrEqualTo",value:function(e){var n=this;return function(){return void 0!==n.cmp(e)&&null!==n.cmp(e)&&n.cmp(e)[Symbol.for(">")]?n.cmp(e)[Symbol.for(">")](-1):n.cmp(e)>-1}()}},{key:"greaterThan",value:function(e){var n=this;return function(){return void 0!==n.cmp(e)&&null!==n.cmp(e)&&n.cmp(e)[Symbol.for(">")]?n.cmp(e)[Symbol.for(">")](0):n.cmp(e)>0}()}}],[{key:"fromComponents",value:function(n,o,r){return(new e).fromComponents(n,o,r)}},{key:"fromComponents_noNormalize",value:function(n,o,r){return(new e).fromComponents_noNormalize(n,o,r)}},{key:"fromMantissaExponent",value:function(n,o){return(new e).fromMantissaExponent(n,o)}},{key:"fromMantissaExponent_noNormalize",value:function(n,o){return(new e).fromMantissaExponent_noNormalize(n,o)}},{key:"fromDecimal",value:function(n){return(new e).fromDecimal(n)}},{key:"fromNumber",value:function(n){return(new e).fromNumber(n)}},{key:"fromString",value:function(n){return(new e).fromString(n)}},{key:"fromValue",value:function(n){return(new e).fromValue(n)}},{key:"fromValue_noAlloc",value:function(n){return n instanceof e?n:new e(n)}},{key:"abs",value:function(e){return E(e).abs()}},{key:"neg",value:function(e){return E(e).neg()}},{key:"negate",value:function(e){return E(e).neg()}},{key:"negated",value:function(e){return E(e).neg()}},{key:"sign",value:function(e){return E(e).sign}},{key:"sgn",value:function(e){return E(e).sign}},{key:"round",value:function(e){return E(e).round()}},{key:"floor",value:function(e){return E(e).floor()}},{key:"ceil",value:function(e){return E(e).ceil()}},{key:"trunc",value:function(e){return E(e).trunc()}},{key:"add",value:function(e,n){return E(e).add(n)}},{key:"plus",value:function(e,n){return E(e).add(n)}},{key:"sub",value:function(e,n){return E(e).sub(n)}},{key:"subtract",value:function(e,n){return E(e).sub(n)}},{key:"minus",value:function(e,n){return E(e).sub(n)}},{key:"mul",value:function(e,n){return E(e).mul(n)}},{key:"multiply",value:function(e,n){return E(e).mul(n)}},{key:"times",value:function(e,n){return E(e).mul(n)}},{key:"div",value:function(e,n){return E(e).div(n)}},{key:"divide",value:function(e,n){return E(e).div(n)}},{key:"recip",value:function(e){return E(e).recip()}},{key:"reciprocal",value:function(e){return E(e).recip()}},{key:"reciprocate",value:function(e){return E(e).reciprocate()}},{key:"cmp",value:function(e,n){return E(e).cmp(n)}},{key:"cmpabs",value:function(e,n){return E(e).cmpabs(n)}},{key:"compare",value:function(e,n){return E(e).cmp(n)}},{key:"isNaN",value:function(e){function n(n){return e.apply(this,arguments)}return n.toString=function(){return e.toString()},n}((function(e){return e=E(e),isNaN(e.sign)||isNaN(e.layer)||isNaN(e.mag)}))},{key:"isFinite",value:function(e){function n(n){return e.apply(this,arguments)}return n.toString=function(){return e.toString()},n}((function(e){return e=E(e),isFinite(e.sign)&&isFinite(e.layer)&&isFinite(e.mag)}))},{key:"eq",value:function(e,n){return E(e).eq(n)}},{key:"equals",value:function(e,n){return E(e).eq(n)}},{key:"neq",value:function(e,n){return E(e).neq(n)}},{key:"notEquals",value:function(e,n){return E(e).notEquals(n)}},{key:"lt",value:function(e,n){return E(e).lt(n)}},{key:"lte",value:function(e,n){return E(e).lte(n)}},{key:"gt",value:function(e,n){return E(e).gt(n)}},{key:"gte",value:function(e,n){return E(e).gte(n)}},{key:"max",value:function(e,n){return E(e).max(n)}},{key:"min",value:function(e,n){return E(e).min(n)}},{key:"minabs",value:function(e,n){return E(e).minabs(n)}},{key:"maxabs",value:function(e,n){return E(e).maxabs(n)}},{key:"clamp",value:function(e,n,o){return E(e).clamp(n,o)}},{key:"clampMin",value:function(e,n){return E(e).clampMin(n)}},{key:"clampMax",value:function(e,n){return E(e).clampMax(n)}},{key:"cmp_tolerance",value:function(e,n,o){return E(e).cmp_tolerance(n,o)}},{key:"compare_tolerance",value:function(e,n,o){return E(e).cmp_tolerance(n,o)}},{key:"eq_tolerance",value:function(e,n,o){return E(e).eq_tolerance(n,o)}},{key:"equals_tolerance",value:function(e,n,o){return E(e).eq_tolerance(n,o)}},{key:"neq_tolerance",value:function(e,n,o){return E(e).neq_tolerance(n,o)}},{key:"notEquals_tolerance",value:function(e,n,o){return E(e).notEquals_tolerance(n,o)}},{key:"lt_tolerance",value:function(e,n,o){return E(e).lt_tolerance(n,o)}},{key:"lte_tolerance",value:function(e,n,o){return E(e).lte_tolerance(n,o)}},{key:"gt_tolerance",value:function(e,n,o){return E(e).gt_tolerance(n,o)}},{key:"gte_tolerance",value:function(e,n,o){return E(e).gte_tolerance(n,o)}},{key:"pLog10",value:function(e){return E(e).pLog10()}},{key:"absLog10",value:function(e){return E(e).absLog10()}},{key:"log10",value:function(e){return E(e).log10()}},{key:"log",value:function(e,n){return E(e).log(n)}},{key:"log2",value:function(e){return E(e).log2()}},{key:"ln",value:function(e){return E(e).ln()}},{key:"logarithm",value:function(e,n){return E(e).logarithm(n)}},{key:"pow",value:function(e,n){return E(e).pow(n)}},{key:"pow10",value:function(e){return E(e).pow10()}},{key:"root",value:function(e,n){return E(e).root(n)}},{key:"factorial",value:function(e,n){return E(e).factorial()}},{key:"gamma",value:function(e,n){return E(e).gamma()}},{key:"lngamma",value:function(e,n){return E(e).lngamma()}},{key:"exp",value:function(e){return E(e).exp()}},{key:"sqr",value:function(e){return E(e).sqr()}},{key:"sqrt",value:function(e){return E(e).sqrt()}},{key:"cube",value:function(e){return E(e).cube()}},{key:"cbrt",value:function(e){return E(e).cbrt()}},{key:"tetrate",value:function(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:2,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](2):n.length>2}()&&function(){return void 0!==n[2]&&null!==n[2]&&n[2][Symbol.for("!==")]?n[2][Symbol.for("!==")](void 0):void 0!==n[2]}()?arguments[2]:T(1,0,1);return E(e).tetrate(o,r)}},{key:"iteratedexp",value:function(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:2,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](2):n.length>2}()&&function(){return void 0!==n[2]&&null!==n[2]&&n[2][Symbol.for("!==")]?n[2][Symbol.for("!==")](void 0):void 0!==n[2]}()?arguments[2]:T(1,0,1);return E(e).iteratedexp(o,r)}},{key:"iteratedlog",value:function(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:10,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](2):n.length>2}()&&function(){return void 0!==n[2]&&null!==n[2]&&n[2][Symbol.for("!==")]?n[2][Symbol.for("!==")](void 0):void 0!==n[2]}()?arguments[2]:1;return E(e).iteratedlog(o,r)}},{key:"layeradd10",value:function(e,n){return E(e).layeradd10(n)}},{key:"layeradd",value:function(e,n){var o=arguments,r=function(){return void 0!==o.length&&null!==o.length&&o.length[Symbol.for(">")]?o.length[Symbol.for(">")](2):o.length>2}()&&function(){return void 0!==o[2]&&null!==o[2]&&o[2][Symbol.for("!==")]?o[2][Symbol.for("!==")](void 0):void 0!==o[2]}()?arguments[2]:10;return E(e).layeradd(n,r)}},{key:"slog",value:function(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:10;return E(e).slog(o)}},{key:"lambertw",value:function(e){return E(e).lambertw()}},{key:"ssqrt",value:function(e){return E(e).ssqrt()}},{key:"pentate",value:function(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:2,r=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](2):n.length>2}()&&function(){return void 0!==n[2]&&null!==n[2]&&n[2][Symbol.for("!==")]?n[2][Symbol.for("!==")](void 0):void 0!==n[2]}()?arguments[2]:T(1,0,1);return E(e).pentate(o,r)}},{key:"affordGeometricSeries",value:function(e,n,o,r){return this.affordGeometricSeries_core(E(e),E(n),E(o),r)}},{key:"sumGeometricSeries",value:function(e,n,o,r){return this.sumGeometricSeries_core(e,E(n),E(o),r)}},{key:"affordArithmeticSeries",value:function(e,n,o,r){return this.affordArithmeticSeries_core(E(e),E(n),E(o),E(r))}},{key:"sumArithmeticSeries",value:function(e,n,o,r){return this.sumArithmeticSeries_core(E(e),E(n),E(o),E(r))}},{key:"efficiencyOfPurchase",value:function(e,n,o){return this.efficiencyOfPurchase_core(E(e),E(n),E(o))}},{key:"randomDecimalForTesting",value:function(e){if(function(){return 20*Math.random()!==void 0&&20*Math.random()!==null&&(20*Math.random())[Symbol.for("<")]?(20*Math.random())[Symbol.for("<")](1):20*Math.random()<1}())return T(0,0,0);var n=function(){return void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for(">")]?Math.random()[Symbol.for(">")](.5):Math.random()>.5}()?1:function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}();if(function(){return 20*Math.random()!==void 0&&20*Math.random()!==null&&(20*Math.random())[Symbol.for("<")]?(20*Math.random())[Symbol.for("<")](1):20*Math.random()<1}())return T(n,0,1);var o=Math.floor(function(){return void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for("*")]?Math.random()[Symbol.for("*")](e+1):Math.random()*(e+1)}()),r=0===o?function(){return 616*Math.random()!==void 0&&616*Math.random()!==null&&(616*Math.random())[Symbol.for("-")]?(616*Math.random())[Symbol.for("-")](308):616*Math.random()-308}():function(){return void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for("*")]?Math.random()[Symbol.for("*")](16):16*Math.random()}();(function(){return void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for(">")]?Math.random()[Symbol.for(">")](.9):Math.random()>.9})()&&(r=Math.trunc(r));var t=Math.pow(10,r);return function(){return void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for(">")]?Math.random()[Symbol.for(">")](.9):Math.random()>.9}()&&(t=Math.trunc(t)),F(n,o,t)}},{key:"affordGeometricSeries_core",value:function(n,o,r,t){var l=o.mul(r.pow(t));return e.floor(n.div(l).mul(r.sub(1)).add(1).log10().div(r.log10()))}},{key:"sumGeometricSeries_core",value:function(n,o,r,t){return o.mul(r.pow(t)).mul(e.sub(1,r.pow(n))).div(e.sub(1,r))}},{key:"affordArithmeticSeries_core",value:function(e,n,o,r){var t=n.add(r.mul(o)),l=t.sub(o.div(2)),i=l.pow(2);return l.neg().add(i.add(o.mul(e).mul(2)).sqrt()).div(o).floor()}},{key:"sumArithmeticSeries_core",value:function(e,n,o,r){var t=n.add(r.mul(o));return e.div(2).mul(t.mul(2).plus(e.sub(1).mul(o)))}},{key:"efficiencyOfPurchase_core",value:function(e,n,o){return e.div(n).add(e.div(o))}},{key:"slog_critical",value:function(n,o){return function(){return void 0!==n&&null!==n&&n[Symbol.for(">")]?n[Symbol.for(">")](10):n>10}()?function(){return void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](1):o-1}():e.critical_section(n,o,P)}},{key:"tetrate_critical",value:function(n,o){return e.critical_section(n,o,B)}},{key:"critical_section",value:function(e,n,o){n=function(){return void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](10):10*n}(),function(){return void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](0):n<0}()&&(n=0),function(){return void 0!==n&&null!==n&&n[Symbol.for(">")]?n[Symbol.for(">")](10):n>10}()&&(n=10),function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](2):e<2}()&&(e=2),function(){return void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](10):e>10}()&&(e=10);for(var r=0,t=0,l=0;function(){return void 0!==l&&null!==l&&l[Symbol.for("<")]?l[Symbol.for("<")](w.length):l")]?w[l+1][Symbol.for(">")](e):w[l+1]>e}()){var i=function(){return e-w[l]!==void 0&&e-w[l]!==null&&(e-w[l])[Symbol.for("/")]?(e-w[l])[Symbol.for("/")](w[l+1]-w[l]):(e-w[l])/(w[l+1]-w[l])}();r=function(){return o[l][Math.floor(n)]*(1-i)!==void 0&&o[l][Math.floor(n)]*(1-i)!==null&&(o[l][Math.floor(n)]*(1-i))[Symbol.for("+")]?(o[l][Math.floor(n)]*(1-i))[Symbol.for("+")](o[l+1][Math.floor(n)]*i):o[l][Math.floor(n)]*(1-i)+o[l+1][Math.floor(n)]*i}(),t=function(){return o[l][Math.ceil(n)]*(1-i)!==void 0&&o[l][Math.ceil(n)]*(1-i)!==null&&(o[l][Math.ceil(n)]*(1-i))[Symbol.for("+")]?(o[l][Math.ceil(n)]*(1-i))[Symbol.for("+")](o[l+1][Math.ceil(n)]*i):o[l][Math.ceil(n)]*(1-i)+o[l+1][Math.ceil(n)]*i}();break}}var u=function(){return void 0!==n&&null!==n&&n[Symbol.for("-")]?n[Symbol.for("-")](Math.floor(n)):n-Math.floor(n)}(),a=function(){return r*(1-u)!==void 0&&r*(1-u)!==null&&(r*(1-u))[Symbol.for("+")]?(r*(1-u))[Symbol.for("+")](t*u):r*(1-u)+t*u}();return a}}]),e}();(0,b.Z)(j,"dZero",T(0,0,0)),(0,b.Z)(j,"dOne",T(1,0,1)),(0,b.Z)(j,"dNegOne",T(function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),0,1)),(0,b.Z)(j,"dTwo",T(1,0,2)),(0,b.Z)(j,"dTen",T(1,0,10)),(0,b.Z)(j,"dNaN",T(Number.NaN,Number.NaN,Number.NaN)),(0,b.Z)(j,"dInf",T(1,Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY)),(0,b.Z)(j,"dNegInf",T(function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}(),Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY)),(0,b.Z)(j,"dNumberMax",F(1,0,Number.MAX_VALUE)),(0,b.Z)(j,"dNumberMin",F(1,0,Number.MIN_VALUE));var A=o(6453),q=j,z=new j(1);function L(e,n){var o=arguments,r=!function(){return void 0!==o.length&&null!==o.length&&o.length[Symbol.for(">")]?o.length[Symbol.for(">")](2):o.length>2}()||!function(){return void 0!==o[2]&&null!==o[2]&&o[2][Symbol.for("!==")]?o[2][Symbol.for("!==")](void 0):void 0!==o[2]}()||arguments[2],t=j.log10(e).floor(),l=j.div(e,j.pow(10,t));"10"===l.toStringWithDecimalPlaces(n)&&(l=z,t=t.add(1));var i=t.gte(1e9)?oe(t,Math.max(Math.max(n,3),A.defaultDecimalsShown)):t.gte(1e4)?G(t,0):t.toStringWithDecimalPlaces(0);return r?function(){return l.toStringWithDecimalPlaces(n)+"e"!==void 0&&l.toStringWithDecimalPlaces(n)+"e"!==null&&(l.toStringWithDecimalPlaces(n)+"e")[Symbol.for("+")]?(l.toStringWithDecimalPlaces(n)+"e")[Symbol.for("+")](i):l.toStringWithDecimalPlaces(n)+"e"+i}():function(){return"e"[Symbol.for("+")]?"e"[Symbol.for("+")](i):"e"+i}()}function G(e,n){if(null===e||void 0===e)return"NaN";if(e=new j(e),function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](.001):e.mag<.001}())return(0).toFixed(n);var o=e.toStringWithDecimalPlaces(n),r=o.split(".");return r[0]=r[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1,"),function(){return void 0!==r.length&&null!==r.length&&r.length[Symbol.for("==")]?r.length[Symbol.for("==")](1):1==r.length}()?r[0]:function(){return r[0]+"."!==void 0&&r[0]+"."!==null&&(r[0]+".")[Symbol.for("+")]?(r[0]+".")[Symbol.for("+")](r[1]):r[0]+"."+r[1]}()}function H(e,n){return null===e||void 0===e?"NaN":(e=new j(e),function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](1e-4):e.mag<1e-4}()?(0).toFixed(n):(function(){return void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](.1):e.mag<.1}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](0):0!==n}()&&(n=Math.max(Math.max(n,e.log10().negate().ceil().toNumber()),A.defaultDecimalsShown)),e.toStringWithDecimalPlaces(n)))}var W=new j("eeee1000"),Y=new j("e100000"),K=new j("e1000"),Q=new j(1e9),J=new j(1e6),$=new j(1e3),X=new j(.98),ee=new j(.001),ne=new j(0);function oe(e,n,o){var r;if(function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()&&(n=A.defaultDecimalsShown),o=function(){return void 0!==(r=o)&&null!==(r=o)&&(r=o)[Symbol.for("!==")]?(r=o)[Symbol.for("!==")](null):null!==(r=o)}()&&function(){return void 0!==r&&null!==r&&r[Symbol.for("!==")]?r[Symbol.for("!==")](void 0):void 0!==r}()?r:A.defaultShowSmall,e=new j(e),isNaN(e.sign)||isNaN(e.layer)||isNaN(e.mag))return"NaN";if(function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("<")]?e.sign[Symbol.for("<")](0):e.sign<0}())return function(){return"-"[Symbol.for("+")]?"-"[Symbol.for("+")](oe(e.neg(),n)):"-"+oe(e.neg(),n)}();if(e.mag===Number.POSITIVE_INFINITY)return"Infinity";if(e.gte(W)){var t=e.slog();return t.gte(J)?function(){return"F"[Symbol.for("+")]?"F"[Symbol.for("+")](oe(t.floor())):"F"+oe(t.floor())}():function(){return j.pow(10,t.sub(t.floor())).toStringWithDecimalPlaces(3)+"F"!==void 0&&j.pow(10,t.sub(t.floor())).toStringWithDecimalPlaces(3)+"F"!==null&&(j.pow(10,t.sub(t.floor())).toStringWithDecimalPlaces(3)+"F")[Symbol.for("+")]?(j.pow(10,t.sub(t.floor())).toStringWithDecimalPlaces(3)+"F")[Symbol.for("+")](G(t.floor(),0)):j.pow(10,t.sub(t.floor())).toStringWithDecimalPlaces(3)+"F"+G(t.floor(),0)}()}if(e.gte(Y))return L(e,0,!1);if(e.gte(K))return L(e,0);if(e.gte(Q))return L(e,n);if(e.gte($))return G(e,0);if(e.gte(ee)||function(){return void 0!==o&&null!==o&&o[Symbol.for("!")]?o[Symbol.for("!")]():!o}())return H(e,n);if(e.eq(ne))return(0).toFixed(n);if(e=ue(e),e.lt(K)){var l=L(e,n);return l.replace(/([^(?:e|F)]*)$/,"-$1")}return function(){return void 0!==oe(e,n)&&null!==oe(e,n)&&oe(e,n)[Symbol.for("+")]?oe(e,n)[Symbol.for("+")]("⁻¹"):oe(e,n)+"⁻¹"}()}function re(e){return e=new j(e),function(){return void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("<")]?e.sign[Symbol.for("<")](0):e.sign<0}()?function(){return"-"[Symbol.for("+")]?"-"[Symbol.for("+")](re(e.neg())):"-"+re(e.neg())}():e.gte(Q)||e.lte(X)&&function(){return void 0!==e.eq(ne)&&null!==e.eq(ne)&&e.eq(ne)[Symbol.for("!")]?e.eq(ne)[Symbol.for("!")]():!e.eq(ne)}()?oe(e):oe(e,0)}function te(e){return j.lt(e,0)?function(){return"-"[Symbol.for("+")]?"-"[Symbol.for("+")](te(j.neg(e))):"-"+te(j.neg(e))}():j.gt(e,function(){return 2[Symbol.for("**")]?2[Symbol.for("**")](51):Math.pow(2,51)}())?function(){return void 0!==oe(j.div(e,31536e3))&&null!==oe(j.div(e,31536e3))&&oe(j.div(e,31536e3))[Symbol.for("+")]?oe(j.div(e,31536e3))[Symbol.for("+")]("y"):oe(j.div(e,31536e3))+"y"}():(e=new j(e).toNumber(),function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](60):e<60}()?function(){return void 0!==oe(e)&&null!==oe(e)&&oe(e)[Symbol.for("+")]?oe(e)[Symbol.for("+")]("s"):oe(e)+"s"}():function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](3600):e<3600}()?function(){return re(Math.floor(e/60))+"m "+oe(e%60)!==void 0&&re(Math.floor(e/60))+"m "+oe(e%60)!==null&&(re(Math.floor(e/60))+"m "+oe(e%60))[Symbol.for("+")]?(re(Math.floor(e/60))+"m "+oe(e%60))[Symbol.for("+")]("s"):re(Math.floor(e/60))+"m "+oe(e%60)+"s"}():function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](86400):e<86400}()?function(){return re(Math.floor(e/3600))+"h "+re(Math.floor(e/60)%60)+"m "+re(e%60)!==void 0&&re(Math.floor(e/3600))+"h "+re(Math.floor(e/60)%60)+"m "+re(e%60)!==null&&(re(Math.floor(e/3600))+"h "+re(Math.floor(e/60)%60)+"m "+re(e%60))[Symbol.for("+")]?(re(Math.floor(e/3600))+"h "+re(Math.floor(e/60)%60)+"m "+re(e%60))[Symbol.for("+")]("s"):re(Math.floor(e/3600))+"h "+re(Math.floor(e/60)%60)+"m "+re(e%60)+"s"}():function(){return void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](31536e3):e<31536e3}()?function(){return re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)+"h "+re(Math.floor(e/60)%60)!==void 0&&re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)+"h "+re(Math.floor(e/60)%60)!==null&&(re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)+"h "+re(Math.floor(e/60)%60))[Symbol.for("+")]?(re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)+"h "+re(Math.floor(e/60)%60))[Symbol.for("+")]("m"):re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)+"h "+re(Math.floor(e/60)%60)+"m"}():function(){return re(Math.floor(e/31536e3))+"y "+re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)!==void 0&&re(Math.floor(e/31536e3))+"y "+re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)!==null&&(re(Math.floor(e/31536e3))+"y "+re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24))[Symbol.for("+")]?(re(Math.floor(e/31536e3))+"y "+re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24))[Symbol.for("+")]("h"):re(Math.floor(e/31536e3))+"y "+re(Math.floor(e/84600)%365)+"d "+re(Math.floor(e/3600)%24)+"h"}())}function le(e,n,o){e=new j(e);var r=e.toStringWithDecimalPlaces(n);return new j(r).gte(o)&&(r=j.sub(o,Math.pow(.1,n)).toStringWithDecimalPlaces(n)),r}function ie(e,n){return oe(e,n,!0)}function ue(e){var n=j.log10(e).ceil(),o=j.div(e,j.pow(10,n));return n=n.neg(),e=new j(10).pow(n).times(o),e}var ae=L,fe=G,ce=H,se=oe,me=re,de=te,ye=le,ve=ie,be=ue;window.Decimal=q,window.exponentialFormat=ae,window.commaFormat=fe,window.regularFormat=ce,window.format=se,window.formatWhole=me,window.formatTime=de,window.toPlaces=ye,window.formatSmall=ve,window.invertOOM=be;var Se=q},1349:function(e,n,o){"use strict";o.d(n,{IJ:function(){return t},PO:function(){return l},mf:function(){return i},Nm:function(){return r}});var r;o(4916),o(5306),o(2526),o(1817),o(1539),o(7042);function t(e){var n=e.replace(/([A-Z])/g," $1");return n=function(){return void 0!==n.charAt(0).toUpperCase()&&null!==n.charAt(0).toUpperCase()&&n.charAt(0).toUpperCase()[Symbol.for("+")]?n.charAt(0).toUpperCase()[Symbol.for("+")](n.slice(1)):n.charAt(0).toUpperCase()+n.slice(1)}(),n}function l(e){return"[object Object]"===Object.prototype.toString.call(e)}function i(e){return"function"===typeof e}(function(e){e["Up"]="Up",e["Down"]="Down",e["Left"]="Left",e["Right"]="Right",e["Default"]="Up"})(r||(r={}))},9583:function(e,n,o){"use strict";o.d(n,{mM:function(){return l},yB:function(){return i},UI:function(){return u}});o(2526),o(1817),o(1539);var r=o(4865),t=o(1349),l=Symbol("DoNotCache");function i(e,n){var o=e[n];(0,t.mf)(o)&&0===o.length&&function(){return void 0!==o[l]&&null!==o[l]&&o[l][Symbol.for("!")]?o[l][Symbol.for("!")]():!o[l]}()&&(e[n]=(0,r.computed)(o.bind(e)))}function u(e){return(0,t.mf)(e)&&function(){return void 0!==e[l]&&null!==e[l]&&e[l][Symbol.for("!")]?e[l][Symbol.for("!")]():!e[l]}()&&(e=(0,r.computed)(e)),e}},3273:function(e,n,o){"use strict";o.d(n,{Le:function(){return r},c4:function(){return t},z2:function(){return l}});o(2526),o(1817),o(1539),o(4858),o(1299),o(7556),o(5003);var r=Symbol("ProxyState"),t=Symbol("ProxyPath");function l(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:{},t=o,l=!1;function i(){return function(){return void 0!==l&&null!==l&&l[Symbol.for("!")]?l[Symbol.for("!")]():!l}()&&(Object.assign(t,e(t)),l=!0),t}return new Proxy(t,{get:function(e,n){return n===r?i():i()[n]},set:function(e,n,o){return i()[n]=o,!0},has:function(e,n){return n===r||Reflect.has(i(),n)},ownKeys:function(){return Reflect.ownKeys(i())},getOwnPropertyDescriptor:function(n,o){return function(){return void 0!==l&&null!==l&&l[Symbol.for("!")]?l[Symbol.for("!")]():!l}()&&(Object.assign(t,e(t)),l=!0),Object.getOwnPropertyDescriptor(n,o)}})}},463:function(e,n,o){"use strict";o.d(n,{a1:function(){return m},zD:function(){return d},xM:function(){return v},QI:function(){return b},uW:function(){return S},y6:function(){return p}});var r=o(3336),t=o(8534),l=(o(5666),o(2526),o(1817),o(1539),o(7042),o(2222),o(7714),o(2801),o(1174),o(8783),o(3948),o(4747),o(6453)),i=o(5967),u=o(9266),a=o(3273),f=o(6961),c=o.n(f);function s(){var e=arguments,n=function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](0):e.length>0}()&&function(){return void 0!==e[0]&&null!==e[0]&&e[0][Symbol.for("!==")]?e[0][Symbol.for("!==")](void 0):void 0!==e[0]}()?arguments[0]:{};return Object.assign({id:"".concat(l.id,"-0"),name:"Default Save",tabs:l.initialTabs.slice(),time:Date.now(),autosave:!0,offlineProd:!0,offlineTime:0,timePlayed:0,keepGoing:!1,modID:l.id,modVersion:l.versionNumber,layers:{}},n)}function m(e){var n=c().compressToUTF16((0,i.U)(function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](null):null!==e}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()?e:i.Z[a.Le]));return localStorage.setItem((function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](null):null!==e}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()?e:i.Z[a.Le]).id,n),n}function d(){return y.apply(this,arguments)}function y(){return y=(0,t.Z)(regeneratorRuntime.mark((function e(){var n,o;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if((0,u.ri)(),e.prev=1,n=localStorage.getItem(u.ZP.active),function(){return void 0!==function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()&&null!==function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()[Symbol.for("!")]?function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()[Symbol.for("!")]():!function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()}()){e.next=7;break}return e.next=6,S(v());case 6:return e.abrupt("return");case 7:if(function(){return"{"===n[0]!==void 0&&"{"===n[0]!==null&&("{"===n[0])[Symbol.for("!")]?("{"===n[0])[Symbol.for("!")]():!("{"===n[0])}()){e.next=10;break}e.next=19;break;case 10:if(function(){return"e"===n[0]!==void 0&&"e"===n[0]!==null&&("e"===n[0])[Symbol.for("!")]?("e"===n[0])[Symbol.for("!")]():!("e"===n[0])}()){e.next=14;break}n=decodeURIComponent(escape(atob(n))),e.next=19;break;case 14:if(function(){return"ᯡ"===n[0]!==void 0&&"ᯡ"===n[0]!==null&&("ᯡ"===n[0])[Symbol.for("!")]?("ᯡ"===n[0])[Symbol.for("!")]():!("ᯡ"===n[0])}()){e.next=18;break}n=c().decompressFromUTF16(n),e.next=19;break;case 18:throw"Unable to determine save encoding";case 19:if(o=JSON.parse(n),function(){return void 0!==function(){return void 0!==o.modID&&null!==o.modID&&o.modID[Symbol.for("!==")]?o.modID[Symbol.for("!==")](l.id):o.modID!==l.id}()&&null!==function(){return void 0!==o.modID&&null!==o.modID&&o.modID[Symbol.for("!==")]?o.modID[Symbol.for("!==")](l.id):o.modID!==l.id}()&&function(){return void 0!==o.modID&&null!==o.modID&&o.modID[Symbol.for("!==")]?o.modID[Symbol.for("!==")](l.id):o.modID!==l.id}()[Symbol.for("!")]?function(){return void 0!==o.modID&&null!==o.modID&&o.modID[Symbol.for("!==")]?o.modID[Symbol.for("!==")](l.id):o.modID!==l.id}()[Symbol.for("!")]():!function(){return void 0!==o.modID&&null!==o.modID&&o.modID[Symbol.for("!==")]?o.modID[Symbol.for("!==")](l.id):o.modID!==l.id}()}()){e.next=24;break}return e.next=23,S(v());case 23:return e.abrupt("return");case 24:return o.id=u.ZP.active,e.next=27,S(o);case 27:e.next=34;break;case 29:return e.prev=29,e.t0=e["catch"](1),console.error("Failed to load save. Falling back to new save.\n",e.t0),e.next=34,S(v());case 34:case"end":return e.stop()}}),e,null,[[1,29]])}))),y.apply(this,arguments)}function v(){var e=b(),n=s({id:e});return m(n),u.ZP.saves.push(e),n}function b(){var e,n=0;do{e="".concat(l.id,"-").concat(function(){return void 0!==n&&null!==n&&"object"===(0,r.Z)(n)&&n[Symbol.for("postfix-increment")]?n[Symbol.for("postfix-increment")]():n++}())}while(localStorage.getItem(e));return e}function S(e){return g.apply(this,arguments)}function g(){return g=(0,t.Z)(regeneratorRuntime.mark((function e(n){var r,t,a,f,c,m,d,y,v;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return console.info("Loading save",n),e.next=3,Promise.resolve().then(o.bind(o,9365));case 3:return r=e.sent,t=r.layers,a=r.removeLayer,f=r.addLayer,e.next=9,Promise.resolve().then(o.bind(o,504));case 9:for(y in c=e.sent,m=c.fixOldSave,d=c.getInitialLayers,t)v=t[y],v&&a(v);d(n).forEach((function(e){return f(e,n)})),n=s(n),n.offlineProd&&n.time&&(function(){return void 0!==n.offlineTime&&null!==n.offlineTime&&n.offlineTime[Symbol.for("==")]?n.offlineTime[Symbol.for("==")](void 0):void 0==n.offlineTime}()&&(n.offlineTime=0),n.offlineTime=function(){return void 0!==n.offlineTime&&null!==n.offlineTime&&n.offlineTime[Symbol.for("+")]?n.offlineTime[Symbol.for("+")]((Date.now()-n.time)/1e3):n.offlineTime+(Date.now()-n.time)/1e3}()),n.time=Date.now(),function(){return void 0!==n.modVersion&&null!==n.modVersion&&n.modVersion[Symbol.for("!==")]?n.modVersion[Symbol.for("!==")](l.versionNumber):n.modVersion!==l.versionNumber}()&&m(n.modVersion,n),Object.assign(i.Z,n),u.ZP.active=i.Z.id;case 20:case"end":return e.stop()}}),e)}))),g.apply(this,arguments)}setInterval((function(){i.Z.autosave&&m()}),1e3),window.onbeforeunload=function(){i.Z.autosave&&m()},window.save=m;var p=window.hardReset=(0,t.Z)(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,S(v());case 2:case"end":return e.stop()}}),e)})))},504:function(e,n,o){"use strict";o.r(n),o.d(n,{fixOldSave:function(){return yr},getInitialLayers:function(){return mr},hasWon:function(){return dr},main:function(){return sr}});var r=o(4865),t=(o(2526),o(1817),o(1539),function(e){return(0,r.pushScopeId)("data-v-07150322"),e=e(),(0,r.popScopeId)(),e}),l=t((function(){return(0,r.createElementVNode)("svg",{id:"eaRe02fYmMp1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 228 521","shape-rendering":"geometricPrecision","text-rendering":"geometricPrecision"},[(0,r.createElementVNode)("g",{id:"P"},[(0,r.createElementVNode)("path",{d:"m 101,512.877 c -17.547386,-5.3519 -50.794681,-10.26296 -80,0 10.737201,-217.43031 5.7244,-300.999 0,-464.9995 0,0 46.6144,-37.1164 80,-42.00002 33.386,-4.883633 86.025,10.45942 120,50.00002 5,30 -4.353,106.6565 -44,156.0005 -34.149,42.5 -130,38.48 -130,92.999 0,102 54,208 54,208 z",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"10","stroke-linecap":"round","stroke-miterlimit":"16"},id:"trunk",class:"svg-elem-1"}),(0,r.createElementVNode)("path",{d:"M 221,55.8775 C 209.023,126.453 185.39,166.835 158.997,191.5 93.783098,252.444 11.718998,217.436 46.999998,304.877",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"vine2",class:"svg-elem-2"}),(0,r.createElementVNode)("path",{d:"m 194.5,188 c -11.225,4.447 -19.066,5.134 -35.503,3.5",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine4",class:"svg-elem-3"}),(0,r.createElementVNode)("path",{d:"M 73.499996,246.5 C 111.145,245.626 127.011,238.775 156.5,228",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine3",class:"svg-elem-4"}),(0,r.createElementVNode)("path",{d:"M 221,55.8775 C 169.5,17.8262 86.0943,44.9468 47,107 c -4.743,7.528 -7.1041,15.373 -8.326,24 -3.5282,24.91 2.4426,56.34 -12.0011,105.5",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"vine1",class:"svg-elem-5"}),(0,r.createElementVNode)("path",{d:"M 21,47.8775 38.674,131",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine2",class:"svg-elem-6"}),(0,r.createElementVNode)("path",{d:"m 3,326.5 c 13.1783,22.208 16.4863,42.834 21.6997,81",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine1",class:"svg-elem-7"})])],function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())}));function i(e,n){return(0,r.openBlock)(),(0,r.createBlock)(r.Transition,{appear:""},{default:(0,r.withCtx)((function(){return[l]})),_:1})}var u=o(3744);const a={},f=(0,u.Z)(a,[["render",i],["__scopeId","data-v-07150322"]]);var c=f,s=(0,r.defineComponent)({props:{width:{default:"8px"},height:{default:"17px"}},setup:function(e){return function(n,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{style:(0,r.normalizeStyle)({width:e.width,height:e.height})},null,4)}}});const m=s;var d=m,y=o(6113),v=o(3336),b=(o(7268),o(86),o(5613)),S=o(7302),g=o(4061);function p(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:"points",t=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](2):n.length>2}()&&function(){return void 0!==n[2]&&null!==n[2]&&n[2][Symbol.for("!==")]?n[2][Symbol.for("!==")](void 0):void 0!==n[2]}()?arguments[2]:0,l=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](3):n.length>3}()&&function(){return void 0!==n[3]&&null!==n[3]&&n[3][Symbol.for("!==")]?n[3][Symbol.for("!==")](void 0):void 0!==n[3]}()?arguments[3]:void 0,i=(0,r.isRef)(e)?e:(0,g.ax)(e);return i.displayName=o,i.precision=t,i.small=l,i}function h(e){var n=(0,g.ax)(e.value);return(0,r.watch)(e,(function(e){b.ZP.gt(e,n.value)&&(n.value=e)})),n}function N(e){var n=(0,g.ax)(e.value);return(0,r.watch)(e,(function(e,o){b.ZP.gt(e,o)&&(n.value=b.ZP.add(n.value,b.ZP.sub(e,o)))})),n}var k=new b.ZP("10^^8"),V=new b.ZP("1e100");function x(e,n){var o=(0,r.ref)(0),t=(0,r.ref)(0),l=(0,r.ref)(0);S.globalBus.on("update",(function(n){if(t.value=0,b.ZP.lte(e.value,V))l.value=e.value;else{var r=e.value,i=l.value;if(l.value=r,b.ZP.gt(r,i))if(b.ZP.gte(r,k))r=b.ZP.slog(r,1e10),i=b.ZP.slog(i,1e10),o.value=r.sub(i).div(n),t.value=function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}();else while(b.ZP.div(r,i).log(10).div(n).gte("100")&&function(){return void 0!==t.value&&null!==t.value&&t.value[Symbol.for("<=")]?t.value[Symbol.for("<=")](5):t.value<=5}()&&b.ZP.gt(i,0))r=b.ZP.log10(r),i=b.ZP.log10(i),o.value=r.sub(i).div(n),function(){void 0!==t.value&&null!==t.value&&"object"===(0,v.Z)(t.value)&&t.value[Symbol.for("postfix-increment")]?t.value[Symbol.for("postfix-increment")]():t.value++}()}}));var i=(0,r.computed)((function(){return 0===t.value?n?function(){return(0,b.WU)(n.value,e.precision,e.small)+" "+e.displayName!==void 0&&(0,b.WU)(n.value,e.precision,e.small)+" "+e.displayName!==null&&((0,b.WU)(n.value,e.precision,e.small)+" "+e.displayName)[Symbol.for("+")]?((0,b.WU)(n.value,e.precision,e.small)+" "+e.displayName)[Symbol.for("+")]("/s"):(0,b.WU)(n.value,e.precision,e.small)+" "+e.displayName+"/s"}():"":function(){return(0,b.WU)(o.value)+" OOM"+(t.value<0?"^OOM":"^"+t.value)!==void 0&&(0,b.WU)(o.value)+" OOM"+(t.value<0?"^OOM":"^"+t.value)!==null&&((0,b.WU)(o.value)+" OOM"+(t.value<0?"^OOM":"^"+t.value))[Symbol.for("+")]?((0,b.WU)(o.value)+" OOM"+(t.value<0?"^OOM":"^"+t.value))[Symbol.for("+")]("s/sec"):(0,b.WU)(o.value)+" OOM"+(t.value<0?"^OOM":"^"+t.value)+"s/sec"}()}));return i}function M(e,n){var o=function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](null):null!==n}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](void 0):void 0!==n}()?n:e.value;return b.ZP.eq(e.precision,0)?(0,b.Ht)(o):(0,b.WU)(o,e.precision,e.small)}var C=o(9584);o(4553),o(6699),o(2023),o(4747),o(7327),o(1249),o(2222);function Z(e,n,o,t,l,i){var u=(0,r.resolveComponent)("Links");return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,null,[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.nodesComp))),e.leftNodesComp?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.leftNodesComp),{key:0})):(0,r.createCommentVNode)("",!0),e.rightNodesComp?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.rightNodesComp),{key:1})):(0,r.createCommentVNode)("",!0),e.branches?((0,r.openBlock)(),(0,r.createBlock)(u,{key:2,links:e.unref(e.branches)},null,8,["links"])):(0,r.createCommentVNode)("",!0)],64)}var w=o(1604),B=o(9365),P=(o(9254),["x1","y1","x2","y2"]),E=(0,r.defineComponent)({props:{link:null,startNode:null,endNode:null,boundingRect:null},setup:function(e){var n=e,o=(0,r.toRefs)(n),t=(0,r.computed)((function(){var e=o.startNode.value.rect,n=o.boundingRect.value,r=n?{x:function(){return e.x+e.width/2!==void 0&&e.x+e.width/2!==null&&(e.x+e.width/2)[Symbol.for("-")]?(e.x+e.width/2)[Symbol.for("-")](n.x):e.x+e.width/2-n.x}(),y:function(){return e.y+e.height/2!==void 0&&e.y+e.height/2!==null&&(e.y+e.height/2)[Symbol.for("-")]?(e.y+e.height/2)[Symbol.for("-")](n.y):e.y+e.height/2-n.y}()}:{x:0,y:0};return o.link.value.offsetStart&&(r.x=function(){return void 0!==r.x&&null!==r.x&&r.x[Symbol.for("+")]?r.x[Symbol.for("+")](o.link.value.offsetStart.x):r.x+o.link.value.offsetStart.x}(),r.y=function(){return void 0!==r.y&&null!==r.y&&r.y[Symbol.for("+")]?r.y[Symbol.for("+")](o.link.value.offsetStart.y):r.y+o.link.value.offsetStart.y}()),r})),l=(0,r.computed)((function(){var e=o.endNode.value.rect,n=o.boundingRect.value,r=n?{x:function(){return e.x+e.width/2!==void 0&&e.x+e.width/2!==null&&(e.x+e.width/2)[Symbol.for("-")]?(e.x+e.width/2)[Symbol.for("-")](n.x):e.x+e.width/2-n.x}(),y:function(){return e.y+e.height/2!==void 0&&e.y+e.height/2!==null&&(e.y+e.height/2)[Symbol.for("-")]?(e.y+e.height/2)[Symbol.for("-")](n.y):e.y+e.height/2-n.y}()}:{x:0,y:0};return o.link.value.offsetEnd&&(r.x=function(){return void 0!==r.x&&null!==r.x&&r.x[Symbol.for("+")]?r.x[Symbol.for("+")](o.link.value.offsetEnd.x):r.x+o.link.value.offsetEnd.x}(),r.y=function(){return void 0!==r.y&&null!==r.y&&r.y[Symbol.for("+")]?r.y[Symbol.for("+")](o.link.value.offsetEnd.y):r.y+o.link.value.offsetEnd.y}()),r}));return function(n,o){return(0,r.openBlock)(),(0,r.createElementBlock)("line",(0,r.mergeProps)({"stroke-width":"15px",stroke:"white"},e.link,{x1:(0,r.unref)(t).x,y1:(0,r.unref)(t).y,x2:(0,r.unref)(l).x,y2:(0,r.unref)(l).y}),null,16,P)}}});const F=E;var T=F,D=(0,r.defineComponent)({props:{links:null},setup:function(e){var n=e,o=(0,r.toRef)(n,"links"),t=(0,r.ref)(null),l=(0,r.inject)(B.NodesInjectionKey),i=(0,r.inject)(B.BoundsInjectionKey),u=(0,r.ref)(void 0);(0,r.watch)([i],(function(){var e;return u.value=null===(e=t.value)||void 0===e?void 0:e.getBoundingClientRect()}));var a=(0,r.computed)((function(){var e,n=l.value;return function(){var r,t,l,i,u;return void 0!==(e=null===(r=o.value)||void 0===r?void 0:r.filter((function(e){var o,r;return(null===(o=n[e.startNode.id])||void 0===o?void 0:o.rect)&&(null===(r=n[e.startNode.id])||void 0===r?void 0:r.rect)})))&&null!==(e=null===(t=o.value)||void 0===t?void 0:t.filter((function(e){var o,r;return(null===(o=n[e.startNode.id])||void 0===o?void 0:o.rect)&&(null===(r=n[e.startNode.id])||void 0===r?void 0:r.rect)})))&&(e=null===(l=o.value)||void 0===l?void 0:l.filter((function(e){var o,r;return(null===(o=n[e.startNode.id])||void 0===o?void 0:o.rect)&&(null===(r=n[e.startNode.id])||void 0===r?void 0:r.rect)})))[Symbol.for("!==")]?(e=null===(i=o.value)||void 0===i?void 0:i.filter((function(e){var o,r;return(null===(o=n[e.startNode.id])||void 0===o?void 0:o.rect)&&(null===(r=n[e.startNode.id])||void 0===r?void 0:r.rect)})))[Symbol.for("!==")](null):null!==(e=null===(u=o.value)||void 0===u?void 0:u.filter((function(e){var o,r;return(null===(o=n[e.startNode.id])||void 0===o?void 0:o.rect)&&(null===(r=n[e.startNode.id])||void 0===r?void 0:r.rect)})))}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()?e:[]}));return function(e,n){return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,null,[(0,r.unref)(a)?((0,r.openBlock)(),(0,r.createElementBlock)("svg",(0,r.normalizeProps)((0,r.mergeProps)({key:0},e.$attrs)),[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)((0,r.unref)(a),(function(e,n){return(0,r.openBlock)(),(0,r.createBlock)(T,{key:n,link:e,boundingRect:u.value,startNode:(0,r.unref)(l)[e.startNode.id],endNode:(0,r.unref)(l)[e.endNode.id]},null,8,["link","boundingRect","startNode","endNode"])})),128))],16)):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",{ref_key:"resizeListener",ref:t,class:"resize-listener"},null,512)],64)}}});const I=(0,u.Z)(D,[["__scopeId","data-v-2bbc19c2"]]);var R=I,_=(0,r.defineComponent)({props:{nodes:{type:(0,w.P5)(Array),required:!0},leftSideNodes:(0,w.P5)(Array),rightSideNodes:(0,w.P5)(Array),branches:(0,w.P5)(Array)},components:{Links:R},setup:function(e){var n=(0,r.toRefs)(e),o=n.nodes,t=n.leftSideNodes,l=n.rightSideNodes,i=(0,r.shallowRef)();(0,r.watchEffect)((function(){var e=(0,w.Uv)(o);i.value=(0,w.MM)((0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[e.map((function(e){return(0,r.createVNode)("span",{class:"row tree-row",style:"margin: 50px auto;"},[e.map(w.qF)])}))])})))}));var u=(0,r.shallowRef)();(0,r.watchEffect)((function(){var e=(0,w.Uv)(t);u.value=e?(0,w.MM)((0,y.tZ)((function(){return(0,r.createVNode)("span",{class:"left-side-nodes small"},[e.map(w.qF)])}))):""}));var a=(0,r.shallowRef)();return(0,r.watchEffect)((function(){var e=(0,w.Uv)(l);a.value=e?(0,w.MM)((0,y.tZ)((function(){return(0,r.createVNode)("span",{class:"side-nodes small"},[e.map(w.qF)])}))):""})),{unref:r.unref,nodesComp:i,leftNodesComp:u,rightNodesComp:a}}});const O=(0,u.Z)(_,[["render",Z],["__scopeId","data-v-aa87859c"]]);var U=O,j=o(5082);function A(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("MarkNode"),f=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,style:(0,r.normalizeStyle)({visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0}),class:(0,r.normalizeClass)((0,j.Z)({treeNode:!0,can:e.unref(e.canClick)},e.unref(e.classes))),onClick:n[0]||(n[0]=function(){return e.onClick&&e.onClick.apply(e,arguments)}),onMousedown:n[1]||(n[1]=function(){return e.start&&e.start.apply(e,arguments)}),onMouseleave:n[2]||(n[2]=function(){return e.stop&&e.stop.apply(e,arguments)}),onMouseup:n[3]||(n[3]=function(){return e.stop&&e.stop.apply(e,arguments)}),onTouchstartPassive:n[4]||(n[4]=function(){return e.start&&e.start.apply(e,arguments)}),onTouchendPassive:n[5]||(n[5]=function(){return e.stop&&e.stop.apply(e,arguments)}),onTouchcancelPassive:n[6]||(n[6]=function(){return e.stop&&e.stop.apply(e,arguments)})},[(0,r.createElementVNode)("div",{style:(0,r.normalizeStyle)([{backgroundColor:e.unref(e.color),boxShadow:"-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 20px ".concat(e.unref(e.glowColor))},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:[]])},[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.unref(e.comp))))],4),(0,r.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,r.createVNode)(f,{id:e.id},null,8,["id"])],38)):(0,r.createCommentVNode)("",!0)}o(9653);var q=o(6084),z=(0,r.defineComponent)({props:{id:null},setup:function(e){var n=e,o=(0,r.toRefs)(n),t=(0,r.inject)(B.RegisterNodeInjectionKey),l=(0,r.inject)(B.UnregisterNodeInjectionKey),i=(0,r.ref)(null),u=(0,r.computed)((function(){return i.value&&i.value.parentElement}));return t&&l&&((0,r.watch)([u,o.id],(function(e,n){var o=(0,q.Z)(e,2),i=o[0],u=o[1],a=(0,q.Z)(n,2),f=a[0],c=a[1];f&&l((0,r.unref)(c)),i&&t(u,i)})),(0,r.onUnmounted)((function(){return l((0,r.unref)(o.id))}))),function(e,n){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:"node",ref_key:"node",ref:i},null,512)}}});const L=(0,u.Z)(z,[["__scopeId","data-v-63ded336"]]);var G=L,H={key:0},W={key:0,class:"mark star"},Y=["src"],K=(0,r.defineComponent)({props:{mark:{type:[Boolean,String]}},setup:function(e){return function(n,o){return e.mark?((0,r.openBlock)(),(0,r.createElementBlock)("div",H,[!0===e.mark?((0,r.openBlock)(),(0,r.createElementBlock)("div",W)):((0,r.openBlock)(),(0,r.createElementBlock)("img",{key:1,class:"mark",src:e.mark},null,8,Y))])):(0,r.createCommentVNode)("",!0)}}});const Q=(0,u.Z)(K,[["__scopeId","data-v-c476c56a"]]);var J=Q,$=(0,r.defineComponent)({props:{display:(0,w.P5)(Object,String,Function),visibility:{type:(0,w.P5)(Number),required:!0},style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),onClick:Function,onHold:Function,color:(0,w.P5)(String),glowColor:(0,w.P5)(String),canClick:{type:(0,w.P5)(Boolean),required:!0},mark:(0,w.P5)(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:J,Node:G},setup:function(e){var n=(0,r.toRefs)(e),o=n.onClick,t=n.onHold,l=n.display,i=(0,w.KO)(l),u=(0,w.ix)(o,t),a=u.start,f=u.stop;return{start:a,stop:f,comp:i,unref:r.unref,Visibility:y.EE,isCoercableComponent:w.RU}}});const X=(0,u.Z)($,[["render",A],["__scopeId","data-v-094cdcfe"]]);var ee=X,ne=o(9583),oe=o(3273),re=Symbol("TreeNode"),te=Symbol("Tree");function le(e){return(0,oe.z2)((function(){var n,o=function(){return void 0!==(n=null===e||void 0===e?void 0:e())&&null!==(n=null===e||void 0===e?void 0:e())&&(n=null===e||void 0===e?void 0:e())[Symbol.for("!==")]?(n=null===e||void 0===e?void 0:e())[Symbol.for("!==")](null):null!==(n=null===e||void 0===e?void 0:e())}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](void 0):void 0!==n}()?n:{};if(o.id=(0,y.QI)("treeNode-"),o.type=re,o[y.wA]=ee,(0,ne.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,ne.yB)(o,"canClick"),(0,y.Rh)(o,"canClick",!0),(0,ne.yB)(o,"color"),(0,ne.yB)(o,"display"),(0,ne.yB)(o,"glowColor"),(0,ne.yB)(o,"classes"),(0,ne.yB)(o,"style"),(0,ne.yB)(o,"mark"),o.onClick){var t=o.onClick.bind(o);o.onClick=function(){(0,r.unref)(o.canClick)&&t()}}if(o.onHold){var l=o.onHold.bind(o);o.onHold=function(){(0,r.unref)(o.canClick)&&l()}}return o[y.tj]=function(){var e=this.display,n=this.visibility,o=this.style,r=this.classes,t=this.onClick,l=this.onHold,i=this.color,u=this.glowColor,a=this.canClick,f=this.mark,c=this.id;return{display:e,visibility:n,style:o,classes:r,onClick:t,onHold:l,color:i,glowColor:u,canClick:a,mark:f,id:c}},o}))}function ie(e){return(0,oe.z2)((function(){var n=e();return n.id=(0,y.QI)("tree-"),n.type=te,n[y.wA]=U,n.isResetting=(0,r.ref)(!1),n.resettingNode=(0,r.shallowRef)(null),n.reset=function(e){var o,r,t=n;t.isResetting.value=!0,t.resettingNode.value=e,null===(o=t.resetPropagation)||void 0===o||o.call(t,t,e),null===(r=t.onReset)||void 0===r||r.call(t,e),t.isResetting.value=!1,t.resettingNode.value=null},n.links=(0,r.computed)((function(){var e,o=n;return function(){return void 0!==(e=(0,r.unref)(o.branches))&&null!==(e=(0,r.unref)(o.branches))&&(e=(0,r.unref)(o.branches))[Symbol.for("!==")]?(e=(0,r.unref)(o.branches))[Symbol.for("!==")](null):null!==(e=(0,r.unref)(o.branches))}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()?e:[]})),(0,ne.yB)(n,"visibility"),(0,y.Rh)(n,"visibility",y.EE.Visible),(0,ne.yB)(n,"nodes"),(0,ne.yB)(n,"leftSideNodes"),(0,ne.yB)(n,"rightSideNodes"),(0,ne.yB)(n,"branches"),n[y.tj]=function(){var e=this.nodes,n=this.leftSideNodes,o=this.rightSideNodes,r=this.branches;return{nodes:e,leftSideNodes:n,rightSideNodes:o,branches:r}},n}))}var ue=function(e,n){var o=[n],t=[n];(function(){return void 0!==e.branches&&null!==e.branches&&e.branches[Symbol.for("!=")]?e.branches[Symbol.for("!=")](null):null!=e.branches})()&&function(){var n=(0,r.unref)(e.branches),l=function(){var e=[];t.forEach((function(r){n.filter((function(e){return e.startNode===r||e.endNode===r})).map((function(e){return e.startNode===r?e.endNode:e.startNode})).filter((function(e){return function(){return void 0!==o.includes(e)&&null!==o.includes(e)&&o.includes(e)[Symbol.for("!")]?o.includes(e)[Symbol.for("!")]():!o.includes(e)}()})).forEach((function(n){var o;(function(){return void 0!==e.includes(n)&&null!==e.includes(n)&&e.includes(n)[Symbol.for("!")]?e.includes(n)[Symbol.for("!")]():!e.includes(n)})()&&(e.push(n),null===(o=n.reset)||void 0===o||o.reset())}))})),t=e,o.push.apply(o,(0,C.Z)(t))};while(function(){return void 0!==t.length&&null!==t.length&&t.length[Symbol.for(">")]?t.length[Symbol.for(">")](0):t.length>0}())l()}()};function ae(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:null,t=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](2):n.length>2}()&&function(){return void 0!==n[2]&&null!==n[2]&&n[2][Symbol.for("!==")]?n[2][Symbol.for("!==")](void 0):void 0!==n[2]}()?arguments[2]:0,l=(0,ne.UI)(t);return(0,r.computed)((function(){return function(){return void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o}()||b.ZP.gte(e.value,(0,r.unref)(l))?function(){return M(e)+" "!==void 0&&M(e)+" "!==null&&(M(e)+" ")[Symbol.for("+")]?(M(e)+" ")[Symbol.for("+")](e.displayName):M(e)+" "+e.displayName}():"Reach ".concat(b.ZP.eq(o.precision,0)?(0,b.Ht)((0,r.unref)(l)):(0,b.WU)((0,r.unref)(l),o.precision)," ").concat(o.displayName," to unlock (You have ").concat(b.ZP.eq(o.precision,0)?(0,b.Ht)(o.value):(0,b.WU)(o.value,o.precision),")")}))}var fe=o(5967),ce=o(2482),se=(o(8862),o(274)),me=o(6055);function de(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("MarkNode"),f=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0,backgroundImage:e.earned&&e.image&&"url(".concat(e.image,")")||""},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:[]]),class:(0,r.normalizeClass)((0,j.Z)({feature:!0,achievement:!0,locked:function(){return void 0!==e.unref(e.earned)&&null!==e.unref(e.earned)&&e.unref(e.earned)[Symbol.for("!")]?e.unref(e.earned)[Symbol.for("!")]():!e.unref(e.earned)}(),bought:e.unref(e.earned)},e.unref(e.classes)))},[e.component?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component),{key:0})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,r.createVNode)(f,{id:e.id},null,8,["id"])],6)):(0,r.createCommentVNode)("",!0)}var ye=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},display:(0,w.P5)(Object,String,Function),earned:{type:(0,w.P5)(Boolean),required:!0},image:(0,w.P5)(String),style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),mark:(0,w.P5)(Boolean,String),id:{type:String,required:!0}},components:{Node:G,MarkNode:J},setup:function(e){var n=(0,r.toRefs)(e),o=n.display;return{component:(0,w.KO)(o),unref:r.unref,Visibility:y.EE}}});const ve=(0,u.Z)(ye,[["render",de],["__scopeId","data-v-e3f32402"]]);var be=ve,Se=o(3002);o(343);function ge(){var e=arguments,n=function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](0):e.length>0}()&&function(){return void 0!==e[0]&&null!==e[0]&&e[0][Symbol.for("!==")]?e[0][Symbol.for("!==")](void 0):void 0!==e[0]}()?arguments[0]:"white",o=function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](1):e.length>1}()&&function(){return void 0!==e[1]&&null!==e[1]&&e[1][Symbol.for("!==")]?e[1][Symbol.for("!==")](void 0):void 0!==e[1]}()?arguments[1]:"8px";return{transform:"scale(1.05, 1.05)",borderColor:"rgba(0, 0, 0, 0.125)",boxShadow:"-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 ".concat(o," ").concat(n),zIndex:1}}function pe(){return ge("red","20px")}S.globalBus.on("setupVue",(function(e){return e.use(Se.ZP)}));var he=(0,Se.pm)(),Ne=Symbol("Achievement");function ke(e){var n=(0,g.ax)(!1);return(0,oe.z2)((function(){var o,t=function(){return void 0!==(o=null===e||void 0===e?void 0:e())&&null!==(o=null===e||void 0===e?void 0:e())&&(o=null===e||void 0===e?void 0:e())[Symbol.for("!==")]?(o=null===e||void 0===e?void 0:e())[Symbol.for("!==")](null):null!==(o=null===e||void 0===e?void 0:e())}()&&function(){return void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](void 0):void 0!==o}()?o:{};if(t.id=(0,y.QI)("achievement-"),t.type=Ne,t[y.wA]=be,t.earned=n,t.complete=function(){n.value=!0},(0,ne.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,ne.yB)(t,"display"),(0,ne.yB)(t,"mark"),(0,ne.yB)(t,"image"),(0,ne.yB)(t,"style"),(0,ne.yB)(t,"classes"),t[y.tj]=function(){var e=this.visibility,n=this.display,o=this.earned,t=this.image,l=this.style,i=this.classes,u=this.mark,a=this.id;return{visibility:e,display:n,earned:o,image:t,style:(0,r.unref)(l),classes:i,mark:u,id:a}},t.shouldEarn){var l=t;(0,r.watchEffect)((function(){var e,n;if(function(){return void 0!==l.earned.value&&null!==l.earned.value&&l.earned.value[Symbol.for("!")]?l.earned.value[Symbol.for("!")]():!l.earned.value}()&&(0,r.unref)(l.visibility)===y.EE.Visible&&function(){return void 0!==(e=l.shouldEarn)&&null!==(e=l.shouldEarn)&&(e=l.shouldEarn)[Symbol.for("!==")]?(e=l.shouldEarn)[Symbol.for("!==")](null):null!==(e=l.shouldEarn)}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()&&e.call(l)&&(l.earned.value=!0,null===(n=l.onComplete)||void 0===n||n.call(l),l.display)){var o=(0,w.MM)((0,r.unref)(l.display));he.info((0,r.createVNode)("div",null,[(0,r.createVNode)("h3",null,[(0,r.createTextVNode)("Achievement earned!")]),(0,r.createVNode)("div",null,[(0,r.createVNode)(o,null,null)])]))}}))}return t}))}o(9714),o(7042);function Ve(e,n,o,t,l,i){var u=(0,r.resolveComponent)("GridCell");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,style:(0,r.normalizeStyle)({visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0}),class:"table"},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.unref(e.rows),(function(n){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(["row",{mergeAdjacent:e.mergeAdjacent}]),key:n},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.unref(e.cols),(function(o){return(0,r.openBlock)(),(0,r.createBlock)(u,(0,r.mergeProps)({key:o},e.gatherCellProps(e.unref(e.cells)[function(){return 100*n!==void 0&&100*n!==null&&(100*n)[Symbol.for("+")]?(100*n)[Symbol.for("+")](o):100*n+o}()])),null,16)})),128))],2)})),128))],4)):(0,r.createCommentVNode)("",!0)}var xe=o(1037),Me=o(9266),Ce={key:0};function Ze(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,class:(0,r.normalizeClass)({feature:!0,tile:!0,can:e.unref(e.canClick),locked:function(){return void 0!==e.unref(e.canClick)&&null!==e.unref(e.canClick)&&e.unref(e.canClick)[Symbol.for("!")]?e.unref(e.canClick)[Symbol.for("!")]():!e.unref(e.canClick)}()}),style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}]),onClick:n[0]||(n[0]=function(){return e.onClick&&e.onClick.apply(e,arguments)}),onMousedown:n[1]||(n[1]=function(){return e.start&&e.start.apply(e,arguments)}),onMouseleave:n[2]||(n[2]=function(){return e.stop&&e.stop.apply(e,arguments)}),onMouseup:n[3]||(n[3]=function(){return e.stop&&e.stop.apply(e,arguments)}),onTouchstartPassive:n[4]||(n[4]=function(){return e.start&&e.start.apply(e,arguments)}),onTouchendPassive:n[5]||(n[5]=function(){return e.stop&&e.stop.apply(e,arguments)}),onTouchcancelPassive:n[6]||(n[6]=function(){return e.stop&&e.stop.apply(e,arguments)})},[e.title?((0,r.openBlock)(),(0,r.createElementBlock)("div",Ce,[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.titleComponent)))])):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component),{style:{"white-space":"pre-line"}})),(0,r.createVNode)(a,{id:e.id},null,8,["id"])],38)):(0,r.createCommentVNode)("",!0)}var we=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},onClick:Function,onHold:Function,display:{type:(0,w.P5)(Object,String,Function),required:!0},title:(0,w.P5)(Object,String,Function),style:(0,w.P5)(String,Object,Array),canClick:{type:(0,w.P5)(Boolean),required:!0},id:{type:String,required:!0}},components:{Node:G},setup:function(e){var n=(0,r.toRefs)(e),o=n.onClick,t=n.onHold,l=n.title,i=n.display,u=(0,w.ix)(o,t),a=u.start,f=u.stop,c=(0,w.KO)(l),s=(0,w.vq)(i);return{start:a,stop:f,titleComponent:c,component:s,Visibility:y.EE,unref:r.unref}}});const Be=(0,u.Z)(we,[["render",Ze],["__scopeId","data-v-b27416ec"]]);var Pe=Be,Ee=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},rows:{type:(0,w.P5)(Number),required:!0},cols:{type:(0,w.P5)(Number),required:!0},cells:{type:(0,w.P5)(Object),required:!0}},components:{GridCell:Pe},setup:function(){var e=(0,r.computed)((function(){return xe.Z[Me.ZP.theme].mergeAdjacent}));function n(e){var n=e.visibility,o=e.onClick,r=e.onHold,t=e.display,l=e.title,i=e.style,u=e.canClick,a=e.id;return{visibility:n,onClick:o,onHold:r,display:t,title:l,style:i,canClick:u,id:a}}return{unref:r.unref,gatherCellProps:n,Visibility:y.EE,mergeAdjacent:e}}});const Fe=(0,u.Z)(Ee,[["render",Ve]]);var Te=Fe,De=o(1349);Symbol("Grid");function Ie(e){return new Proxy({},Re(e))}function Re(e){var n=(0,r.computed)((function(){for(var n=[],o=1;function(){return void 0!==o&&null!==o&&o[Symbol.for("<=")]?o[Symbol.for("<=")]((0,r.unref)(e.rows)):o<=(0,r.unref)(e.rows)}();function(){return void 0!==o&&null!==o&&"object"===(0,v.Z)(o)&&o[Symbol.for("postfix-increment")]?o[Symbol.for("postfix-increment")]():o++}())for(var t=1;function(){return void 0!==t&&null!==t&&t[Symbol.for("<=")]?t[Symbol.for("<=")]((0,r.unref)(e.cols)):t<=(0,r.unref)(e.cols)}();function(){return void 0!==t&&null!==t&&"object"===(0,v.Z)(t)&&t[Symbol.for("postfix-increment")]?t[Symbol.for("postfix-increment")]():t++}())n.push(function(){return 100*o!==void 0&&100*o!==null&&(100*o)[Symbol.for("+")]?(100*o)[Symbol.for("+")](t):100*o+t}().toString());return n}));return{get:function(o,r){return"isProxy"===r||("symbol"===(0,v.Z)(r)?e[r]:function(){return void 0!==n.value.includes(r.toString())&&null!==n.value.includes(r.toString())&&n.value.includes(r.toString())[Symbol.for("!")]?n.value.includes(r.toString())[Symbol.for("!")]():!n.value.includes(r.toString())}()?void 0:(function(){return void 0!==o[r]&&null!==o[r]&&o[r][Symbol.for("==")]?o[r][Symbol.for("==")](null):null==o[r]}()&&(o[r]=new Proxy(e,_e(r.toString()))),o[r]))},set:function(e,n,o){return console.warn("Cannot set grid cells",e,n,o),!1},ownKeys:function(){return n.value},has:function(e,o){return n.value.includes(o.toString())},getOwnPropertyDescriptor:function(e,o){if(n.value.includes(o.toString()))return{configurable:!0,enumerable:!0,writable:!1}}}}function _e(e){var n=["id","visibility","canClick","startState","state","style","classes","title","display","onClick","onHold"],o={};return{get:function(n,t,l){if("isProxy"===t)return!0;var i=n[t];return(0,De.mf)(i)?function(){return i.call(l,e,n.getState(e))}:function(){return void 0!==i&&null!==i&&i[Symbol.for("!=")]?i[Symbol.for("!=")](void 0):void 0!=i}()||"symbol"===(0,v.Z)(t)?i:(t=function(){return void 0!==t.slice(0,1).toUpperCase()&&null!==t.slice(0,1).toUpperCase()&&t.slice(0,1).toUpperCase()[Symbol.for("+")]?t.slice(0,1).toUpperCase()[Symbol.for("+")](t.slice(1)):t.slice(0,1).toUpperCase()+t.slice(1)}(),"startState"===t?i.call(l,e):(i=n["get".concat(t)],(0,De.mf)(i)?(function(){return t in o!==void 0&&t in o!==null&&(t in o)[Symbol.for("!")]?(t in o)[Symbol.for("!")]():!(t in o)}()&&(o[t]=(0,r.computed)((function(){return i.call(l,e,n.getState(e))}))),o[t].value):function(){return void 0!==i&&null!==i&&i[Symbol.for("!=")]?i[Symbol.for("!=")](void 0):void 0!=i}()?(0,r.unref)(i):(i=n["on".concat(t)],(0,De.mf)(i)?function(){return i.call(l,e,n.getState(e))}:function(){return void 0!==i&&null!==i&&i[Symbol.for("!=")]?i[Symbol.for("!=")](void 0):void 0!=i}()?i:n[t])))},set:function(n,o,r,t){return o="set".concat(function(){return void 0!==o.slice(0,1).toUpperCase()&&null!==o.slice(0,1).toUpperCase()&&o.slice(0,1).toUpperCase()[Symbol.for("+")]?o.slice(0,1).toUpperCase()[Symbol.for("+")](o.slice(1)):o.slice(0,1).toUpperCase()+o.slice(1)}()),function(){return void 0!==o&&null!==o&&o[Symbol.for("in")]?o[Symbol.for("in")](n):o in n}()&&(0,De.mf)(n[o])&&function(){return void 0!==n[o].length&&null!==n[o].length&&n[o].length[Symbol.for("<")]?n[o].length[Symbol.for("<")](3):n[o].length<3}()?(n[o].call(t,e,r),!0):(console.warn('No setter for "'.concat(o,'".'),n),!1)},ownKeys:function(){return n},has:function(e,o){return n.includes(o.toString())},getOwnPropertyDescriptor:function(e,o){if(n.includes(o.toString()))return{configurable:!0,enumerable:!0,writable:!1}}}}function Oe(e){var n=(0,g.ax)({});return(0,oe.z2)((function(){var o=e();if(o.id=(0,y.QI)("grid-"),o[y.wA]=Te,o.cellState=n,o.getID=function(e){return function(){return o.id+"-"!==void 0&&o.id+"-"!==null&&(o.id+"-")[Symbol.for("+")]?(o.id+"-")[Symbol.for("+")](e):o.id+"-"+e}()},o.getState=function(e){var o=this;return function(){return void 0!==o.cellState.value[e]&&null!==o.cellState.value[e]&&o.cellState.value[e][Symbol.for("!=")]?o.cellState.value[e][Symbol.for("!=")](void 0):void 0!=o.cellState.value[e]}()?n.value[e]:this.cells[e].startState},o.setState=function(e,o){n.value[e]=o},o.cells=Ie(o),(0,ne.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,ne.yB)(o,"rows"),(0,ne.yB)(o,"cols"),(0,ne.yB)(o,"getVisibility"),(0,y.Rh)(o,"getVisibility",y.EE.Visible),(0,ne.yB)(o,"getCanClick"),(0,y.Rh)(o,"getCanClick",!0),(0,ne.yB)(o,"getStartState"),(0,ne.yB)(o,"getStyle"),(0,ne.yB)(o,"getClasses"),(0,ne.yB)(o,"getTitle"),(0,ne.yB)(o,"getDisplay"),o.onClick){var t=o.onClick.bind(o);o.onClick=function(e,n){(0,r.unref)(o.cells[e].canClick)&&t(e,n)}}if(o.onHold){var l=o.onHold.bind(o);o.onHold=function(e,n){(0,r.unref)(o.cells[e].canClick)&&l(e,n)}}return o[y.tj]=function(){var e=this.visibility,n=this.rows,o=this.cols,r=this.cells,t=this.id;return{visibility:e,rows:n,cols:o,cells:r,id:t}},o}))}o(561);function Ue(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("MarkNode"),f=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:[]]),onClick:n[0]||(n[0]=function(){return e.onClick&&e.onClick.apply(e,arguments)}),onMousedown:n[1]||(n[1]=function(){return e.start&&e.start.apply(e,arguments)}),onMouseleave:n[2]||(n[2]=function(){return e.stop&&e.stop.apply(e,arguments)}),onMouseup:n[3]||(n[3]=function(){return e.stop&&e.stop.apply(e,arguments)}),onTouchstartPassive:n[4]||(n[4]=function(){return e.start&&e.start.apply(e,arguments)}),onTouchendPassive:n[5]||(n[5]=function(){return e.stop&&e.stop.apply(e,arguments)}),onTouchcancelPassive:n[6]||(n[6]=function(){return e.stop&&e.stop.apply(e,arguments)}),class:(0,r.normalizeClass)((0,j.Z)({feature:!0,clickable:!0,can:e.unref(e.canClick),locked:function(){return void 0!==e.unref(e.canClick)&&null!==e.unref(e.canClick)&&e.unref(e.canClick)[Symbol.for("!")]?e.unref(e.canClick)[Symbol.for("!")]():!e.unref(e.canClick)}(),small:e.small},e.unref(e.classes)))},[e.unref(e.comp)?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.unref(e.comp)),{key:0})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,r.createVNode)(f,{id:e.id},null,8,["id"])],38)):(0,r.createCommentVNode)("",!0)}var je=(0,r.defineComponent)({props:{display:{type:(0,w.P5)(Object,String,Function),required:!0},visibility:{type:(0,w.P5)(Number),required:!0},style:(0,w.P5)(Object,String,Array),classes:(0,w.P5)(Object),onClick:Function,onHold:Function,canClick:{type:(0,w.P5)(Boolean),required:!0},small:Boolean,mark:(0,w.P5)(Boolean,String),id:{type:String,required:!0}},components:{Node:G,MarkNode:J},setup:function(e){var n=(0,r.toRefs)(e),o=n.display,t=n.onClick,l=n.onHold,i=(0,r.shallowRef)("");(0,r.watchEffect)((function(){var e=(0,w.Uv)(o);if(function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e}())i.value="";else if((0,w.RU)(e))i.value=(0,w.MM)(e);else{var n=(0,w.MM)(e.title||"","h3"),t=(0,w.MM)(e.description,"div");i.value=(0,w.MM)((0,y.tZ)((function(){return(0,r.createVNode)("span",null,[e.title?(0,r.createVNode)("div",null,[(0,r.createVNode)(n,null,null)]):null,(0,r.createVNode)(t,null,null)])})))}}));var u=(0,w.ix)(t,l),a=u.start,f=u.stop;return{start:a,stop:f,comp:i,Visibility:y.EE,unref:r.unref}}});const Ae=(0,u.Z)(je,[["render",Ue],["__scopeId","data-v-e4e6b79a"]]);var qe=Ae,ze=Symbol("Clickable");function Le(e){return(0,oe.z2)((function(){var n,o=function(){return void 0!==(n=null===e||void 0===e?void 0:e())&&null!==(n=null===e||void 0===e?void 0:e())&&(n=null===e||void 0===e?void 0:e())[Symbol.for("!==")]?(n=null===e||void 0===e?void 0:e())[Symbol.for("!==")](null):null!==(n=null===e||void 0===e?void 0:e())}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](void 0):void 0!==n}()?n:{};if(o.id=(0,y.QI)("clickable-"),o.type=ze,o[y.wA]=qe,(0,ne.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,ne.yB)(o,"canClick"),(0,y.Rh)(o,"canClick",!0),(0,ne.yB)(o,"classes"),(0,ne.yB)(o,"style"),(0,ne.yB)(o,"mark"),(0,ne.yB)(o,"display"),o.onClick){var t=o.onClick.bind(o);o.onClick=function(e){(0,r.unref)(o.canClick)&&t(e)}}if(o.onHold){var l=o.onHold.bind(o);o.onHold=function(){(0,r.unref)(o.canClick)&&l()}}return o[y.tj]=function(){var e=this.display,n=this.visibility,o=this.style,t=this.classes,l=this.onClick,i=this.onHold,u=this.canClick,a=this.small,f=this.mark,c=this.id;return{display:e,visibility:n,style:(0,r.unref)(o),classes:t,onClick:l,onHold:i,canClick:u,small:a,mark:f,id:c}},o}))}function Ge(e){return Le((function(){var n=e();(0,ne.yB)(n,"showNextAt"),(0,y.Rh)(n,"showNextAt",!0),(0,y.Rh)(n,"minimumGain",1),!function(){return void 0!==n.resetDescription&&null!==n.resetDescription&&n.resetDescription[Symbol.for("==")]?n.resetDescription[Symbol.for("==")](null):null==n.resetDescription}()?(0,ne.yB)(n,"resetDescription"):n.resetDescription=(0,r.computed)((function(){return b.ZP.lt(n.conversion.gainResource.value,1e3)?"Reset for ":""})),function(){return void 0!==n.display&&null!==n.display&&n.display[Symbol.for("==")]?n.display[Symbol.for("==")](null):null==n.display}()&&(n.display=(0,y.tZ)((function(){return(0,r.createVNode)("span",null,[(0,r.unref)(n.resetDescription),(0,r.createVNode)("b",null,[M(n.conversion.gainResource,b.ZP.max((0,r.unref)(n.conversion.actualGain),(0,r.unref)(n.minimumGain)))])," ",n.conversion.gainResource.displayName,(0,r.withDirectives)((0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.unref)(n.conversion.buyMax)?"Next:":"Req:"," ",M(n.conversion.baseResource,(0,r.unref)(n.conversion.buyMax)||b.ZP.floor((0,r.unref)(n.conversion.actualGain)).neq(1)?(0,r.unref)(n.conversion.nextAt):(0,r.unref)(n.conversion.currentAt))," ",n.conversion.baseResource.displayName]),[[r.vShow,(0,r.unref)(n.showNextAt)]])])}))),function(){return void 0!==n.canClick&&null!==n.canClick&&n.canClick[Symbol.for("==")]?n.canClick[Symbol.for("==")](null):null==n.canClick}()&&(n.canClick=(0,r.computed)((function(){return b.ZP.gte((0,r.unref)(n.conversion.actualGain),(0,r.unref)(n.minimumGain))})));var o=n.onClick;return n.onClick=function(){(function(){return void 0!==(0,r.unref)(n.canClick)&&null!==(0,r.unref)(n.canClick)&&(0,r.unref)(n.canClick)[Symbol.for("!")]?(0,r.unref)(n.canClick)[Symbol.for("!")]():!(0,r.unref)(n.canClick)})()||(n.conversion.convert(),n.tree.reset(n.treeNode),null===o||void 0===o||o())},n}))}function He(e){return le((function(){var n=e();return(0,ne.yB)(n,"display"),(0,y.Rh)(n,"display",n.layerID),(0,ne.yB)(n,"append"),(0,j.Z)((0,j.Z)({},n),{},{display:n.display,onClick:(0,r.unref)(n.append)?function(){if(fe.Z.tabs.includes(n.layerID)){var e=fe.Z.tabs.lastIndexOf(n.layerID);fe.Z.tabs.splice(e,1)}else fe.Z.tabs.push(n.layerID)}:function(){fe.Z.tabs.splice(1,1,n.layerID)}})}))}function We(e){return(0,oe.z2)((function(){var n=e();return function(){return void 0!==n.currentGain&&null!==n.currentGain&&n.currentGain[Symbol.for("==")]?n.currentGain[Symbol.for("==")](null):null==n.currentGain}()&&(n.currentGain=(0,r.computed)((function(){var e=n.gainModifier?n.gainModifier.apply(n.scaling.currentGain(n)):n.scaling.currentGain(n);return e=b.ZP.floor(e).max(0),function(){return void 0!==(0,r.unref)(n.buyMax)&&null!==(0,r.unref)(n.buyMax)&&(0,r.unref)(n.buyMax)[Symbol.for("!")]?(0,r.unref)(n.buyMax)[Symbol.for("!")]():!(0,r.unref)(n.buyMax)}()&&(e=e.min(1)),e}))),function(){return void 0!==n.actualGain&&null!==n.actualGain&&n.actualGain[Symbol.for("==")]?n.actualGain[Symbol.for("==")](null):null==n.actualGain}()&&(n.actualGain=n.currentGain),function(){return void 0!==n.currentAt&&null!==n.currentAt&&n.currentAt[Symbol.for("==")]?n.currentAt[Symbol.for("==")](null):null==n.currentAt}()&&(n.currentAt=(0,r.computed)((function(){var e=n.scaling.currentAt(n);return n.roundUpCost&&(e=b.ZP.ceil(e)),e}))),function(){return void 0!==n.nextAt&&null!==n.nextAt&&n.nextAt[Symbol.for("==")]?n.nextAt[Symbol.for("==")](null):null==n.nextAt}()&&(n.nextAt=(0,r.computed)((function(){var e=n.scaling.nextAt(n);return n.roundUpCost&&(e=b.ZP.ceil(e)),e}))),function(){return void 0!==n.convert&&null!==n.convert&&n.convert[Symbol.for("==")]?n.convert[Symbol.for("==")](null):null==n.convert}()&&(n.convert=function(){n.gainResource.value=b.ZP.add(n.gainResource.value,(0,r.unref)(n.currentGain)),n.baseResource.value=0}),(0,ne.yB)(n,"currentGain"),(0,ne.yB)(n,"actualGain"),(0,ne.yB)(n,"currentAt"),(0,ne.yB)(n,"nextAt"),(0,ne.yB)(n,"buyMax"),(0,y.Rh)(n,"buyMax",!0),(0,ne.yB)(n,"roundUpCost"),(0,y.Rh)(n,"roundUpCost",!0),n}))}function Ye(e,n){var o=(0,ne.UI)(e),t=(0,ne.UI)(n);return{currentGain:function(e){if(b.ZP.lt(e.baseResource.value,(0,r.unref)(o)))return 0;var n=b.ZP.div(e.baseResource.value,(0,r.unref)(o)).pow((0,r.unref)(t));return n.isNan()?new b.ZP(0):n},currentAt:function(e){var n=(0,r.unref)(e.currentGain);return e.gainModifier&&(n=e.gainModifier.revert(n)),n=b.ZP.max(0,n),b.ZP.root(n,(0,r.unref)(t)).times((0,r.unref)(o))},nextAt:function(e){var n=b.ZP.add((0,r.unref)(e.currentGain),1);return e.gainModifier&&(n=e.gainModifier.revert(n)),n=b.ZP.max(0,n),b.ZP.root(n,(0,r.unref)(t)).times((0,r.unref)(o)).max((0,r.unref)(o))}}}function Ke(e){return We(e)}function Qe(e){return We((function(){var n=e();return(0,y.Rh)(n,"buyMax",!1),function(){return void 0!==n.currentGain&&null!==n.currentGain&&n.currentGain[Symbol.for("==")]?n.currentGain[Symbol.for("==")](null):null==n.currentGain}()&&(n.currentGain=(0,r.computed)((function(){var e=n.gainModifier?n.gainModifier.apply(n.scaling.currentGain(n)):n.scaling.currentGain(n);return e=b.ZP.floor(e).max(n.gainResource.value),function(){return void 0!==(0,r.unref)(n.buyMax)&&null!==(0,r.unref)(n.buyMax)&&(0,r.unref)(n.buyMax)[Symbol.for("!")]?(0,r.unref)(n.buyMax)[Symbol.for("!")]():!(0,r.unref)(n.buyMax)}()&&(e=e.min(b.ZP.add(n.gainResource.value,1))),e}))),function(){return void 0!==n.actualGain&&null!==n.actualGain&&n.actualGain[Symbol.for("==")]?n.actualGain[Symbol.for("==")](null):null==n.actualGain}()&&(n.actualGain=(0,r.computed)((function(){var e=b.ZP.sub(n.scaling.currentGain(n),n.gainResource.value).max(0);return function(){return void 0!==(0,r.unref)(n.buyMax)&&null!==(0,r.unref)(n.buyMax)&&(0,r.unref)(n.buyMax)[Symbol.for("!")]?(0,r.unref)(n.buyMax)[Symbol.for("!")]():!(0,r.unref)(n.buyMax)}()&&(e=e.min(1)),e}))),(0,y.Rh)(n,"convert",(function(){n.gainResource.value=n.gainModifier?n.gainModifier.apply((0,r.unref)(n.currentGain)):(0,r.unref)(n.currentGain),n.baseResource.value=0})),n}))}function Je(e,n){var o=arguments,r=function(){return void 0!==o.length&&null!==o.length&&o.length[Symbol.for(">")]?o.length[Symbol.for(">")](2):o.length>2}()&&function(){return void 0!==o[2]&&null!==o[2]&&o[2][Symbol.for("!==")]?o[2][Symbol.for("!==")](void 0):void 0!==o[2]}()?arguments[2]:.5;return b.ZP.lte(e,n)?e:b.ZP.pow(e,r).times(b.ZP.pow(n,b.ZP.sub(1,r)))}function $e(e,n){var o=arguments,t=function(){return void 0!==o.length&&null!==o.length&&o.length[Symbol.for(">")]?o.length[Symbol.for(">")](2):o.length>2}()&&function(){return void 0!==o[2]&&null!==o[2]&&o[2][Symbol.for("!==")]?o[2][Symbol.for("!==")](void 0):void 0!==o[2]}()?arguments[2]:.5;return(0,j.Z)((0,j.Z)({},e),{},{currentGain:function(o){return Je(e.currentGain(o),(0,r.unref)(n),(0,r.unref)(t))}})}var Xe=function(e){return(0,r.pushScopeId)("data-v-6447a93e"),e=e(),(0,r.popScopeId)(),e},en=Xe((function(){return(0,r.createElementVNode)("span",{class:"toggle"},"▼",function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}())}));function nn(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("CollapseTransition"),f=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:(0,r.normalizeClass)(["infobox",(0,j.Z)({collapsed:e.unref(e.collapsed),stacked:e.stacked},e.unref(e.classes))]),style:(0,r.normalizeStyle)([{borderColor:e.unref(e.color),visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}])},[(0,r.createElementVNode)("button",{class:"title",style:(0,r.normalizeStyle)([{backgroundColor:e.unref(e.color)},e.unref(e.titleStyle)||[]]),onClick:n[0]||(n[0]=function(n){return e.collapsed.value=function(){return void 0!==e.unref(e.collapsed)&&null!==e.unref(e.collapsed)&&e.unref(e.collapsed)[Symbol.for("!")]?e.unref(e.collapsed)[Symbol.for("!")]():!e.unref(e.collapsed)}()})},[en,((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.titleComponent)))],4),(0,r.createVNode)(a,null,{default:(0,r.withCtx)((function(){return[function(){return void 0!==e.unref(e.collapsed)&&null!==e.unref(e.collapsed)&&e.unref(e.collapsed)[Symbol.for("!")]?e.unref(e.collapsed)[Symbol.for("!")]():!e.unref(e.collapsed)}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:"body",style:(0,r.normalizeStyle)({backgroundColor:e.unref(e.color)})},[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.bodyComponent),{style:(0,r.normalizeStyle)(e.unref(e.bodyStyle))},null,8,["style"]))],4)):(0,r.createCommentVNode)("",!0)]})),_:1}),(0,r.createVNode)(f,{id:e.id},null,8,["id"])],6)):(0,r.createCommentVNode)("",!0)}var on=o(423),rn=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},display:{type:(0,w.P5)(Object,String,Function),required:!0},title:{type:(0,w.P5)(Object,String,Function),required:!0},color:(0,w.P5)(String),collapsed:{type:Object,required:!0},style:(0,w.P5)(Object,String,Array),titleStyle:(0,w.P5)(Object,String,Array),bodyStyle:(0,w.P5)(Object,String,Array),classes:(0,w.P5)(Object),id:{type:String,required:!0}},components:{Node:G,CollapseTransition:on.Z},setup:function(e){var n=(0,r.toRefs)(e),o=n.title,t=n.display,l=(0,w.vq)(o),i=(0,w.vq)(t),u=(0,r.computed)((function(){return xe.Z[Me.ZP.theme].mergeAdjacent}));return{titleComponent:l,bodyComponent:i,stacked:u,unref:r.unref,Visibility:y.EE}}});const tn=(0,u.Z)(rn,[["render",nn],["__scopeId","data-v-6447a93e"]]);var ln=tn,un=Symbol("Infobox");function an(e){var n=(0,g.ax)(!1);return(0,oe.z2)((function(){var o=e();return o.id=(0,y.QI)("infobox-"),o.type=un,o[y.wA]=ln,o.collapsed=n,(0,ne.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,ne.yB)(o,"color"),(0,ne.yB)(o,"style"),(0,ne.yB)(o,"titleStyle"),(0,ne.yB)(o,"bodyStyle"),(0,ne.yB)(o,"classes"),(0,ne.yB)(o,"title"),(0,ne.yB)(o,"display"),o[y.tj]=function(){var e=this.visibility,n=this.display,o=this.title,t=this.color,l=this.collapsed,i=this.style,u=this.titleStyle,a=this.bodyStyle,f=this.classes,c=this.id;return{visibility:e,display:n,title:o,color:t,collapsed:l,style:(0,r.unref)(i),titleStyle:u,bodyStyle:a,classes:f,id:c}},o}))}function fn(e,n,o,t,l,i){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"resizeListener",class:(0,r.normalizeClass)(["resize-listener",e.unref(e.classes)]),style:(0,r.normalizeStyle)(e.unref(e.style))},null,6)}var cn=o(6591),sn=(0,r.defineComponent)({props:{style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),onInit:{type:Function,required:!0},id:{type:String,required:!0},onContainerResized:Function,onHotReload:Function},setup:function(e){var n=(0,r.ref)(null),o=new ResizeObserver(i),t=(0,r.ref)(null);(0,r.onMounted)((function(){var l,u=t.value;(function(){return void 0!==u&&null!==u&&u[Symbol.for("!=")]?u[Symbol.for("!=")](null):null!=u})()&&(o.observe(u),n.value=new cn.MxU({resizeTo:u,backgroundAlpha:0}),null===(l=t.value)||void 0===l||l.appendChild(n.value.view),e.onInit(n.value));i(),e.onHotReload&&(0,r.nextTick)(e.onHotReload)})),(0,r.onBeforeUnmount)((function(){var e;null===(e=n.value)||void 0===e||e.destroy()}));var l=!0;function i(){l&&(l=!1,(0,r.nextTick)((function(){var o;(function(){return void 0!==t.value&&null!==t.value&&t.value[Symbol.for("!=")]?t.value[Symbol.for("!=")](null):null!=t.value})()&&e.onContainerResized&&(e.onContainerResized(t.value.getBoundingClientRect()),null===(o=n.value)||void 0===o||o.resize());l=!0})))}return document.fonts.ready.then(i),{unref:r.unref,resizeListener:t}}});const mn=(0,u.Z)(sn,[["render",fn],["__scopeId","data-v-08c4e343"]]);var dn=mn,yn=o(1845),vn=Symbol("Particles");function bn(e){return(0,oe.z2)((function(){var n,o,t=function(){return void 0!==(n=null===e||void 0===e?void 0:e())&&null!==(n=null===e||void 0===e?void 0:e())&&(n=null===e||void 0===e?void 0:e())[Symbol.for("!==")]?(n=null===e||void 0===e?void 0:e())[Symbol.for("!==")](null):null!==(n=null===e||void 0===e?void 0:e())}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](void 0):void 0!==n}()?n:{};t.id=(0,y.QI)("particles-"),t.type=vn,t[y.wA]=dn,t.app=(0,r.shallowRef)(null),t.addEmitter=function(e){var n=t;return n.app.value?Promise.resolve(new yn.Q5(n.app.value.stage,e)):new Promise((function(n){l.push({resolve:n,config:e})}))};var l=[];function i(e){t.app.value=e,l.forEach((function(n){var o=n.resolve,r=n.config;return o(new yn.Q5(e.stage,r))})),l=[]}return t.onContainerResized=null===(o=t.onContainerResized)||void 0===o?void 0:o.bind(t),t[y.tj]=function(){var e=this.id,n=this.style,o=this.classes,t=this.onContainerResized,l=this.onHotReload;return{id:e,style:(0,r.unref)(n),classes:o,onContainerResized:t,onHotReload:l,onInit:i}},t}))}window.upgradeConfig=yn.oC;o(2479);var Sn=Symbol("Reset");function gn(e){return(0,oe.z2)((function(){var n=e();return n.id=(0,y.QI)("reset-"),n.type=Sn,n.reset=function(){var e,o=function e(n){n&&"object"===(0,v.Z)(n)&&(!function(){return void 0!==g.n9&&null!==g.n9&&g.n9[Symbol.for("in")]?g.n9[Symbol.for("in")](n):g.n9 in n}()?function(){return n instanceof b.ZP!==void 0&&n instanceof b.ZP!==null&&(n instanceof b.ZP)[Symbol.for("!")]?(n instanceof b.ZP)[Symbol.for("!")]():!(n instanceof b.ZP)}()&&function(){return void 0!==(0,r.isRef)(n)&&null!==(0,r.isRef)(n)&&(0,r.isRef)(n)[Symbol.for("!")]?(0,r.isRef)(n)[Symbol.for("!")]():!(0,r.isRef)(n)}()&&Object.values(n).forEach((function(n){return e(n)})):n[g.n9].value=n[g.nY])};(0,r.unref)(n.thingsToReset).forEach(o),S.globalBus.emit("reset",n),null===(e=n.onReset)||void 0===e||e.call(n)},(0,ne.yB)(n,"thingsToReset"),n}))}var pn={};S.globalBus.on("removeLayer",(function(e){var n;null===(n=pn[e.id])||void 0===n||n.call(pn),pn[e.id]=void 0}));var hn=(0,r.defineComponent)({props:{resource:null,color:null},setup:function(e){var n=e,o=(0,r.computed)((function(){return M(n.resource)}));return function(n,t){return(0,r.openBlock)(),(0,r.createElementBlock)("h2",{style:(0,r.normalizeStyle)({color:e.color,"text-shadow":function(){return"0px 0px 10px "[Symbol.for("+")]?"0px 0px 10px "[Symbol.for("+")](e.color):"0px 0px 10px "+e.color}()})},(0,r.toDisplayString)((0,r.unref)(o)),5)}}});const Nn=hn;var kn=Nn,Vn={key:0},xn={key:1},Mn=(0,r.createTextVNode)(", "),Cn=(0,r.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()),Zn=(0,r.createElementVNode)("br",null,null,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()),wn=(0,r.defineComponent)({props:{resource:null,color:null,classes:null,style:null,effectDisplay:null},setup:function(e){var n=e,o=(0,r.toRefs)(n),t=(0,w.KO)(o.effectDisplay),l=(0,r.computed)((function(){return b.ZP.lt(o.resource.value,"1e1000")}));return function(n,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.unref)(l)?((0,r.openBlock)(),(0,r.createElementBlock)("span",Vn,"You have ")):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(kn,{resource:e.resource,color:e.color||"white"},null,8,["resource","color"]),(0,r.createTextVNode)(function(){return" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,r.toDisplayString)(e.resource.displayName)):" "+(0,r.toDisplayString)(e.resource.displayName)}(),1),(0,r.unref)(t)?((0,r.openBlock)(),(0,r.createElementBlock)("span",xn,[Mn,((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)((0,r.unref)(t))))])):(0,r.createCommentVNode)("",!0),Cn,Zn])}}});const Bn=wn;var Pn=Bn;function En(e,n){return(0,ne.yB)(n,"display"),(0,ne.yB)(n,"classes"),(0,ne.yB)(n,"style"),(0,ne.yB)(n,"direction"),(0,y.Rh)(n,"direction",De.Nm.Up),(0,ne.yB)(n,"xoffset"),(0,ne.yB)(n,"yoffset"),(0,r.nextTick)((function(){n.pinnable&&(!function(){return"pinned"[Symbol.for("in")]?"pinned"[Symbol.for("in")](e):"pinned"in e}()?e.pinned=n.pinned=(0,g.ax)(!1):(console.error("Cannot add pinnable tooltip to element that already has a property called 'pinned'"),n.pinnable=!1));var o=e[y.wA];e[y.wA]=me.Z;var t=e[y.tj].bind(e);e[y.tj]=function(){var e,n=this.display,l=this.classes,i=this.style,u=this.direction,a=this.xoffset,f=this.yoffset,c=this.pinned;return{element:(e={},(0,ce.Z)(e,y.wA,o),(0,ce.Z)(e,y.tj,t),e),display:n,classes:l,style:(0,r.unref)(i),direction:u,xoffset:a,yoffset:f,pinned:c}}.bind(n)})),n}function Fn(e,n,o){var t=(0,ne.UI)(e),l=(0,ne.UI)(n),i=function(){return void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o}()?void 0:(0,ne.UI)(o);return{apply:function(e){return b.ZP.add(e,(0,r.unref)(t))},revert:function(e){return b.ZP.sub(e,(0,r.unref)(t))},enabled:i,description:function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()?void 0:(0,y.tZ)((function(){return(0,r.createVNode)("div",{class:"modifier-container"},[(0,r.createVNode)("span",{class:"modifier-amount"},[b.ZP.gte((0,r.unref)(t),0)?"+":"",(0,b.WU)((0,r.unref)(t))]),(0,r.unref)(l)?(0,r.createVNode)("span",{class:"modifier-description"},[(0,w.qF)((0,r.unref)(l))]):null])}))}}function Tn(e,n,o){var t=(0,ne.UI)(e),l=(0,ne.UI)(n),i=function(){return void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o}()?void 0:(0,ne.UI)(o);return{apply:function(e){return b.ZP.times(e,(0,r.unref)(t))},revert:function(e){return b.ZP.div(e,(0,r.unref)(t))},enabled:i,description:function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()?void 0:(0,y.tZ)((function(){return(0,r.createVNode)("div",{class:"modifier-container"},[(0,r.createVNode)("span",{class:"modifier-amount"},[(0,r.createTextVNode)("x"),(0,b.WU)((0,r.unref)(t))]),(0,r.unref)(l)?(0,r.createVNode)("span",{class:"modifier-description"},[(0,w.qF)((0,r.unref)(l))]):null])}))}}function Dn(e,n,o){var t=(0,ne.UI)(e),l=(0,ne.UI)(n),i=function(){return void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o}()?void 0:(0,ne.UI)(o);return{apply:function(e){return b.ZP.pow(e,(0,r.unref)(t))},revert:function(e){return b.ZP.root(e,(0,r.unref)(t))},enabled:i,description:function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()?void 0:(0,y.tZ)((function(){return(0,r.createVNode)("div",{class:"modifier-container"},[(0,r.createVNode)("span",{class:"modifier-amount"},[(0,r.createTextVNode)("^"),(0,b.WU)((0,r.unref)(t))]),(0,r.unref)(l)?(0,r.createVNode)("span",{class:"modifier-description"},[(0,w.qF)((0,r.unref)(l))]):null])}))}}function In(){for(var e=arguments.length,n=new Array(e),o=0;function(){return void 0!==o&&null!==o&&o[Symbol.for("<")]?o[Symbol.for("<")](e):o")]?n.filter((function(e){return!1!==(0,r.unref)(e.enabled)})).length[Symbol.for(">")](0):n.filter((function(e){return!1!==(0,r.unref)(e.enabled)})).length>0}()})),description:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[n.filter((function(e){return function(){return void 0!==(0,r.unref)(e.enabled)&&null!==(0,r.unref)(e.enabled)&&(0,r.unref)(e.enabled)[Symbol.for("!==")]?(0,r.unref)(e.enabled)[Symbol.for("!==")](!1):!1!==(0,r.unref)(e.enabled)}()})).map((function(e){return(0,r.unref)(e.description)})).filter((function(e){return e})).map(w.qF)])}))}}function Rn(e,n,o){var t=arguments,l=function(){return void 0!==t.length&&null!==t.length&&t.length[Symbol.for(">")]?t.length[Symbol.for(">")](3):t.length>3}()&&function(){return void 0!==t[3]&&null!==t[3]&&t[3][Symbol.for("!==")]?t[3][Symbol.for("!==")](void 0):void 0!==t[3]}()?arguments[3]:1,i=function(){return void 0!==t.length&&null!==t.length&&t.length[Symbol.for(">")]?t.length[Symbol.for(">")](4):t.length>4}()&&function(){return void 0!==t[4]&&null!==t[4]&&t[4][Symbol.for("!==")]?t[4][Symbol.for("!==")](void 0):void 0!==t[4]}()?arguments[4]:"",u=function(){return void 0!==t.length&&null!==t.length&&t.length[Symbol.for(">")]?t.length[Symbol.for(">")](5):t.length>5}()&&function(){return void 0!==t[5]&&null!==t[5]&&t[5][Symbol.for("!==")]?t[5][Symbol.for("!==")](void 0):void 0!==t[5]}()?arguments[5]:"Base";return(0,r.createVNode)("div",null,[(0,r.createVNode)("h3",null,[e,n?(0,r.createVNode)("span",{class:"subtitle"},[(0,r.createTextVNode)(" ("),n,(0,r.createTextVNode)(")")]):null]),(0,r.createVNode)("br",null,null),(0,r.createVNode)("div",{class:"modifier-container"},[(0,r.createVNode)("span",{class:"modifier-amount"},[(0,b.WU)(l),i]),(0,r.createVNode)("span",{class:"modifier-description"},[(0,w.qF)(u)])]),(0,w.qF)((0,r.unref)(o.description)),(0,r.createVNode)("hr",null,null),(0,r.createTextVNode)("Total: "),(0,b.WU)(o.apply(l)),i])}var _n={class:"field"},On={key:0,class:"field-title"},Un=["min","max"],jn=(0,r.defineComponent)({props:{title:null,modelValue:null,min:null,max:null},emits:["update:modelValue"],setup:function(e,n){var o=n.emit,t=e,l=(0,r.toRefs)(t),i=(0,r.computed)({get:function(){return String((0,r.unref)(l.modelValue)||0)},set:function(e){o("update:modelValue",Number(e))}});return function(n,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",_n,[e.title?((0,r.openBlock)(),(0,r.createElementBlock)("span",On,(0,r.toDisplayString)(e.title),1)):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(me.Z,{display:"".concat((0,r.unref)(i)),class:(0,r.normalizeClass)({fullWidth:function(){return void 0!==e.title&&null!==e.title&&e.title[Symbol.for("!")]?e.title[Symbol.for("!")]():!e.title}()}),direction:(0,r.unref)(De.Nm).Down},{default:(0,r.withCtx)((function(){return[(0,r.withDirectives)((0,r.createElementVNode)("input",{type:"range","onUpdate:modelValue":o[0]||(o[0]=function(e){return(0,r.isRef)(i)?i.value=e:null}),min:e.min,max:e.max},null,8,Un),[[r.vModelText,(0,r.unref)(i)]])]})),_:1},8,["display","class","direction"])])}}});const An=(0,u.Z)(jn,[["__scopeId","data-v-38661d49"]]);var qn=An,zn=o(4520),Ln=o(9868),Gn=o(9905),Hn=(0,r.defineComponent)({setup:function(e){var n=(0,r.ref)("0"),o=new ResizeObserver(l),t=(0,r.ref)(null);function l(){var e=t.value;if(!function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](void 0):void 0==e}()){var o=0;while(e.previousSibling){var r=e.previousSibling;r.dataset&&function(){return"vSticky"[Symbol.for("in")]?"vSticky"[Symbol.for("in")](r.dataset):"vSticky"in r.dataset}()&&(o=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](r.offsetHeight):o+r.offsetHeight}()),e=r}n.value=function(){return void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")]("px"):o+"px"}()}}return(0,r.nextTick)(l),document.fonts.ready.then(l),(0,r.onMounted)((function(){var e,n=null===(e=t.value)||void 0===e?void 0:e.parentElement;n&&o.observe(n)})),function(e,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:"sticky",style:(0,r.normalizeStyle)({top:n.value}),ref_key:"element",ref:t,"data-v-sticky":""},[(0,r.renderSlot)(e.$slots,"default")],4)}}});const Wn=(0,u.Z)(Hn,[["__scopeId","data-v-77aa21df"]]);var Yn=Wn,Kn=(0,r.defineComponent)({props:{height:null},setup:function(e){return function(n,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:"vr",style:(0,r.normalizeStyle)({height:e.height})},null,4)}}});const Qn=(0,u.Z)(Kn,[["__scopeId","data-v-15f6e746"]]);var Jn=Qn,$n=o(6948);function Xn(e,n,o,t,l,i){var u,a,f,c,s,m,d,y=(0,r.resolveComponent)("MarkNode"),v=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,style:(0,r.normalizeStyle)([{width:function(){return void 0!==e.unref(e.width)&&null!==e.unref(e.width)&&e.unref(e.width)[Symbol.for("+")]?e.unref(e.width)[Symbol.for("+")]("px"):e.unref(e.width)+"px"}(),height:function(){return void 0!==e.unref(e.height)&&null!==e.unref(e.height)&&e.unref(e.height)[Symbol.for("+")]?e.unref(e.height)[Symbol.for("+")]("px"):e.unref(e.height)+"px"}(),visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}]),class:(0,r.normalizeClass)((0,j.Z)({bar:!0},e.unref(e.classes)))},[(0,r.createElementVNode)("div",{class:"overlayTextContainer border",style:(0,r.normalizeStyle)([{width:function(){return void 0!==e.unref(e.width)&&null!==e.unref(e.width)&&e.unref(e.width)[Symbol.for("+")]?e.unref(e.width)[Symbol.for("+")]("px"):e.unref(e.width)+"px"}(),height:function(){return void 0!==e.unref(e.height)&&null!==e.unref(e.height)&&e.unref(e.height)[Symbol.for("+")]?e.unref(e.height)[Symbol.for("+")]("px"):e.unref(e.height)+"px"}()},function(){return void 0!==(a=e.unref(e.borderStyle))&&null!==(a=e.unref(e.borderStyle))&&(a=e.unref(e.borderStyle))[Symbol.for("!==")]?(a=e.unref(e.borderStyle))[Symbol.for("!==")](null):null!==(a=e.unref(e.borderStyle))}()&&function(){return void 0!==a&&null!==a&&a[Symbol.for("!==")]?a[Symbol.for("!==")](void 0):void 0!==a}()?a:{}])},[e.component?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component),{key:0,class:"overlayText",style:(0,r.normalizeStyle)(e.unref(e.textStyle))},null,8,["style"])):(0,r.createCommentVNode)("",!0)],4),(0,r.createElementVNode)("div",{class:"border",style:(0,r.normalizeStyle)([{width:function(){return void 0!==e.unref(e.width)&&null!==e.unref(e.width)&&e.unref(e.width)[Symbol.for("+")]?e.unref(e.width)[Symbol.for("+")]("px"):e.unref(e.width)+"px"}(),height:function(){return void 0!==e.unref(e.height)&&null!==e.unref(e.height)&&e.unref(e.height)[Symbol.for("+")]?e.unref(e.height)[Symbol.for("+")]("px"):e.unref(e.height)+"px"}()},function(){return void 0!==(f=e.unref(e.style))&&null!==(f=e.unref(e.style))&&(f=e.unref(e.style))[Symbol.for("!==")]?(f=e.unref(e.style))[Symbol.for("!==")](null):null!==(f=e.unref(e.style))}()&&function(){return void 0!==f&&null!==f&&f[Symbol.for("!==")]?f[Symbol.for("!==")](void 0):void 0!==f}()?f:{},function(){return void 0!==(c=e.unref(e.baseStyle))&&null!==(c=e.unref(e.baseStyle))&&(c=e.unref(e.baseStyle))[Symbol.for("!==")]?(c=e.unref(e.baseStyle))[Symbol.for("!==")](null):null!==(c=e.unref(e.baseStyle))}()&&function(){return void 0!==c&&null!==c&&c[Symbol.for("!==")]?c[Symbol.for("!==")](void 0):void 0!==c}()?c:{},function(){return void 0!==(s=e.unref(e.borderStyle))&&null!==(s=e.unref(e.borderStyle))&&(s=e.unref(e.borderStyle))[Symbol.for("!==")]?(s=e.unref(e.borderStyle))[Symbol.for("!==")](null):null!==(s=e.unref(e.borderStyle))}()&&function(){return void 0!==s&&null!==s&&s[Symbol.for("!==")]?s[Symbol.for("!==")](void 0):void 0!==s}()?s:{}])},[(0,r.createElementVNode)("div",{class:"fill",style:(0,r.normalizeStyle)([e.barStyle,function(){return void 0!==(m=e.unref(e.style))&&null!==(m=e.unref(e.style))&&(m=e.unref(e.style))[Symbol.for("!==")]?(m=e.unref(e.style))[Symbol.for("!==")](null):null!==(m=e.unref(e.style))}()&&function(){return void 0!==m&&null!==m&&m[Symbol.for("!==")]?m[Symbol.for("!==")](void 0):void 0!==m}()?m:{},function(){return void 0!==(d=e.unref(e.fillStyle))&&null!==(d=e.unref(e.fillStyle))&&(d=e.unref(e.fillStyle))[Symbol.for("!==")]?(d=e.unref(e.fillStyle))[Symbol.for("!==")](null):null!==(d=e.unref(e.fillStyle))}()&&function(){return void 0!==d&&null!==d&&d[Symbol.for("!==")]?d[Symbol.for("!==")](void 0):void 0!==d}()?d:{}])},null,4)],4),(0,r.createVNode)(y,{mark:e.unref(e.mark)},null,8,["mark"]),(0,r.createVNode)(v,{id:e.id},null,8,["id"])],6)):(0,r.createCommentVNode)("",!0)}var eo=(0,r.defineComponent)({props:{progress:{type:(0,w.P5)(String,Object,Number),required:!0},width:{type:(0,w.P5)(Number),required:!0},height:{type:(0,w.P5)(Number),required:!0},direction:{type:(0,w.P5)(String),required:!0},display:(0,w.P5)(Object,String,Function),visibility:{type:(0,w.P5)(Number),required:!0},style:(0,w.P5)(Object,String,Array),classes:(0,w.P5)(Object),borderStyle:(0,w.P5)(Object,String,Array),textStyle:(0,w.P5)(Object,String,Array),baseStyle:(0,w.P5)(Object,String,Array),fillStyle:(0,w.P5)(Object,String,Array),mark:(0,w.P5)(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:J,Node:G},setup:function(e){var n=(0,r.toRefs)(e),o=n.progress,t=n.width,l=n.height,i=n.direction,u=n.display,a=(0,r.computed)((function(){var e=o.value instanceof b.ZP?o.value.toNumber():Number(o.value);return function(){return 1-Math.min(Math.max(e,0),1)!==void 0&&1-Math.min(Math.max(e,0),1)!==null&&(1-Math.min(Math.max(e,0),1))[Symbol.for("*")]?(1-Math.min(Math.max(e,0),1))[Symbol.for("*")](100):100*(1-Math.min(Math.max(e,0),1))}()})),f=(0,r.computed)((function(){var e={width:function(){return(0,w.Uv)(t)+.5!==void 0&&(0,w.Uv)(t)+.5!==null&&((0,w.Uv)(t)+.5)[Symbol.for("+")]?((0,w.Uv)(t)+.5)[Symbol.for("+")]("px"):(0,w.Uv)(t)+.5+"px"}(),height:function(){return(0,w.Uv)(l)+.5!==void 0&&(0,w.Uv)(l)+.5!==null&&((0,w.Uv)(l)+.5)[Symbol.for("+")]?((0,w.Uv)(l)+.5)[Symbol.for("+")]("px"):(0,w.Uv)(l)+.5+"px"}()};switch((0,r.unref)(i)){case De.Nm.Up:e.clipPath="inset(".concat(a.value,"% 0% 0% 0%)"),e.width=function(){return(0,w.Uv)(t)+1!==void 0&&(0,w.Uv)(t)+1!==null&&((0,w.Uv)(t)+1)[Symbol.for("+")]?((0,w.Uv)(t)+1)[Symbol.for("+")]("px"):(0,w.Uv)(t)+1+"px"}();break;case De.Nm.Down:e.clipPath="inset(0% 0% ".concat(a.value,"% 0%)"),e.width=function(){return(0,w.Uv)(t)+1!==void 0&&(0,w.Uv)(t)+1!==null&&((0,w.Uv)(t)+1)[Symbol.for("+")]?((0,w.Uv)(t)+1)[Symbol.for("+")]("px"):(0,w.Uv)(t)+1+"px"}();break;case De.Nm.Right:e.clipPath="inset(0% ".concat(a.value,"% 0% 0%)");break;case De.Nm.Left:e.clipPath="inset(0% 0% 0% ".concat(a.value," + '%)");break;case De.Nm.Default:e.clipPath="inset(0% 50% 0% 0%)";break}return e})),c=(0,w.KO)(u);return{normalizedProgress:a,barStyle:f,component:c,unref:r.unref,Visibility:y.EE}}});const no=(0,u.Z)(eo,[["render",Xn],["__scopeId","data-v-bfa7e8b2"]]);var oo=no,ro=Symbol("Bar");function to(e){return(0,oe.z2)((function(){var n=e();return n.id=(0,y.QI)("bar-"),n.type=ro,n[y.wA]=oo,(0,ne.yB)(n,"visibility"),(0,y.Rh)(n,"visibility",y.EE.Visible),(0,ne.yB)(n,"width"),(0,ne.yB)(n,"height"),(0,ne.yB)(n,"direction"),(0,ne.yB)(n,"style"),(0,ne.yB)(n,"classes"),(0,ne.yB)(n,"borderStyle"),(0,ne.yB)(n,"baseStyle"),(0,ne.yB)(n,"textStyle"),(0,ne.yB)(n,"fillStyle"),(0,ne.yB)(n,"progress"),(0,ne.yB)(n,"display"),(0,ne.yB)(n,"mark"),n[y.tj]=function(){var e=this.progress,n=this.width,o=this.height,t=this.direction,l=this.display,i=this.visibility,u=this.style,a=this.classes,f=this.borderStyle,c=this.textStyle,s=this.baseStyle,m=this.fillStyle,d=this.mark,y=this.id;return{progress:e,width:n,height:o,direction:t,display:l,visibility:i,style:(0,r.unref)(u),classes:a,borderStyle:f,textStyle:c,baseStyle:s,fillStyle:m,mark:d,id:y}},n}))}var lo=Symbol("Buyable");function io(e){var n=(0,g.ax)(0);return(0,oe.z2)((function(){var o,t=e();if(function(){return void 0!==t.canPurchase&&null!==t.canPurchase&&t.canPurchase[Symbol.for("==")]?t.canPurchase[Symbol.for("==")](null):null==t.canPurchase}()&&(function(){return void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("==")]?t.resource[Symbol.for("==")](null):null==t.resource}()||function(){return void 0!==t.cost&&null!==t.cost&&t.cost[Symbol.for("==")]?t.cost[Symbol.for("==")](null):null==t.cost}()))throw console.warn("Cannot create buyable without a canPurchase property or a resource and cost property",t),"Cannot create buyable without a canPurchase property or a resource and cost property";t.id=(0,y.QI)("buyable-"),t.type=lo,t[y.wA]=qe,t.amount=n,t.canAfford=(0,r.computed)((function(){var e=t,n=(0,r.unref)(e.cost);return function(){return void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!=")]?n[Symbol.for("!=")](null):null!=n}()&&b.ZP.gte(e.resource.value,n)})),function(){return void 0!==t.canPurchase&&null!==t.canPurchase&&t.canPurchase[Symbol.for("==")]?t.canPurchase[Symbol.for("==")](null):null==t.canPurchase}()&&(t.canPurchase=(0,r.computed)((function(){return(0,r.unref)(t.visibility)===y.EE.Visible&&(0,r.unref)(t.canAfford)&&b.ZP.lt(t.amount.value,(0,r.unref)(t.purchaseLimit))}))),t.maxed=(0,r.computed)((function(){return b.ZP.gte(t.amount.value,(0,r.unref)(t.purchaseLimit))})),(0,ne.yB)(t,"classes");var l=t.classes;t.classes=(0,r.computed)((function(){var e=(0,r.unref)(l)||{};return t.maxed.value&&(e.bought=!0),e})),(0,ne.yB)(t,"canPurchase"),t.canClick=t.canPurchase,t.onClick=t.purchase=function(){var e,n,r,l,i;return void 0!==(o=null!==(e=t.onClick)&&void 0!==e?e:t.purchase)&&null!==(o=null!==(n=t.onClick)&&void 0!==n?n:t.purchase)&&(o=null!==(r=t.onClick)&&void 0!==r?r:t.purchase)[Symbol.for("!==")]?(o=null!==(l=t.onClick)&&void 0!==l?l:t.purchase)[Symbol.for("!==")](null):null!==(o=null!==(i=t.onClick)&&void 0!==i?i:t.purchase)}()&&function(){return void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](void 0):void 0!==o}()?o:function(){var e,n=t;if(!function(){return void 0!==(0,r.unref)(n.canPurchase)&&null!==(0,r.unref)(n.canPurchase)&&(0,r.unref)(n.canPurchase)[Symbol.for("!")]?(0,r.unref)(n.canPurchase)[Symbol.for("!")]():!(0,r.unref)(n.canPurchase)}()){var o=(0,r.unref)(n.cost);(function(){return void 0!==n.cost&&null!==n.cost&&n.cost[Symbol.for("!=")]?n.cost[Symbol.for("!=")](null):null!=n.cost})()&&function(){return void 0!==n.resource&&null!==n.resource&&n.resource[Symbol.for("!=")]?n.resource[Symbol.for("!=")](null):null!=n.resource}()&&(n.resource.value=b.ZP.sub(n.resource.value,o),n.amount.value=b.ZP.add(n.amount.value,1)),null===(e=n.onPurchase)||void 0===e||e.call(n,o)}},(0,ne.yB)(t,"display");var i=t.display;return t.display=(0,y.tZ)((function(){var e=(0,r.unref)(i);if((0,w.RU)(e)){var n=(0,w.MM)(e);return(0,r.createVNode)(n,null,null)}if(function(){return void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e}()&&function(){return void 0!==t.cost&&null!==t.cost&&t.cost[Symbol.for("!=")]?t.cost[Symbol.for("!=")](null):null!=t.cost}()&&function(){return void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("!=")]?t.resource[Symbol.for("!=")](null):null!=t.resource}()){var o=t,l=(0,w.MM)(e.title||"","h3"),u=(0,w.MM)(e.description),a=(0,w.MM)(e.effectDisplay||""),f=(0,r.unref)(o.purchaseLimit)===b.ZP.dInf?(0,r.createVNode)(r.Fragment,null,[(0,r.createTextVNode)("Amount: "),(0,b.Ht)(o.amount.value)]):(0,r.createVNode)(r.Fragment,null,[(0,r.createTextVNode)("Amount: "),(0,b.Ht)(o.amount.value),(0,r.createTextVNode)(" /")," ",(0,b.Ht)((0,r.unref)(o.purchaseLimit))]);return(0,r.createVNode)("span",null,[e.title?(0,r.createVNode)("div",null,[(0,r.createVNode)(l,null,null)]):null,(0,r.createVNode)(u,null,null),(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),f]),e.effectDisplay?(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.createTextVNode)("Currently: "),(0,r.createVNode)(a,null,null)]):null,o.cost&&function(){return void 0!==o.maxed.value&&null!==o.maxed.value&&o.maxed.value[Symbol.for("!")]?o.maxed.value[Symbol.for("!")]():!o.maxed.value}()?(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.createTextVNode)("Cost: "),(0,b.WU)((0,r.unref)(o.cost)||0)," ",t.resource.displayName]):null])}return""})),(0,ne.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,ne.yB)(t,"cost"),(0,ne.yB)(t,"resource"),(0,ne.yB)(t,"purchaseLimit"),(0,y.Rh)(t,"purchaseLimit",b.ZP.dInf),(0,ne.yB)(t,"style"),(0,ne.yB)(t,"mark"),(0,ne.yB)(t,"small"),t[y.tj]=function(){var e=this.display,n=this.visibility,o=this.style,t=this.classes,l=this.onClick,i=this.canClick,u=this.small,a=this.mark,f=this.id;return{display:e,visibility:n,style:(0,r.unref)(o),classes:t,onClick:l,canClick:i,small:u,mark:a,id:f}},t}))}o(9826),o(3577);var uo=["disabled"];function ao(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("MarkNode"),f=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.notifyStyle,function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}]),class:(0,r.normalizeClass)((0,j.Z)({feature:!0,challenge:!0,done:e.unref(e.completed),canStart:e.unref(e.canStart)&&function(){return void 0!==e.unref(e.maxed)&&null!==e.unref(e.maxed)&&e.unref(e.maxed)[Symbol.for("!")]?e.unref(e.maxed)[Symbol.for("!")]():!e.unref(e.maxed)}(),maxed:e.unref(e.maxed)},e.unref(e.classes)))},[(0,r.createElementVNode)("button",{class:"toggleChallenge",onClick:n[0]||(n[0]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),disabled:function(){return void 0!==e.unref(e.canStart)&&null!==e.unref(e.canStart)&&e.unref(e.canStart)[Symbol.for("!")]?e.unref(e.canStart)[Symbol.for("!")]():!e.unref(e.canStart)}()||e.unref(e.maxed)},(0,r.toDisplayString)(e.buttonText),9,uo),e.unref(e.comp)?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.unref(e.comp)),{key:0})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,r.createVNode)(f,{id:e.id},null,8,["id"])],6)):(0,r.createCommentVNode)("",!0)}var fo=(0,r.defineComponent)({props:{active:{type:(0,w.P5)(Boolean),required:!0},maxed:{type:(0,w.P5)(Boolean),required:!0},canComplete:{type:(0,w.P5)(Boolean),required:!0},display:(0,w.P5)(String,Object,Function),visibility:{type:(0,w.P5)(Number),required:!0},style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),completed:{type:(0,w.P5)(Boolean),required:!0},canStart:{type:(0,w.P5)(Boolean),required:!0},mark:(0,w.P5)(Boolean,String),id:{type:String,required:!0},toggle:{type:Function,required:!0}},components:{MarkNode:J,Node:G},setup:function(e){var n=(0,r.toRefs)(e),o=n.active,t=n.maxed,l=n.canComplete,i=n.display,u=(0,r.computed)((function(){return o.value?l.value?"Finish":"Exit Early":t.value?"Completed":"Start"})),a=(0,r.shallowRef)(""),f=(0,r.computed)((function(){var e=(0,w.Uv)(o),n=(0,w.Uv)(l);return e?n?pe():ge():{}}));return(0,r.watchEffect)((function(){var e=(0,w.Uv)(i);if(function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e}())a.value="";else if((0,w.RU)(e))a.value=(0,w.MM)(e);else{var n=(0,w.MM)(e.title||"","h3"),o=(0,w.MM)(e.description,"div"),t=(0,w.MM)(e.goal||""),l=(0,w.MM)(e.reward||""),u=(0,w.MM)(e.effectDisplay||"");a.value=(0,w.MM)((0,y.tZ)((function(){return(0,r.createVNode)("span",null,[e.title?(0,r.createVNode)("div",null,[(0,r.createVNode)(n,null,null)]):null,(0,r.createVNode)(o,null,null),e.goal?(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.createTextVNode)("Goal: "),(0,r.createVNode)(t,null,null)]):null,e.reward?(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.createTextVNode)("Reward: "),(0,r.createVNode)(l,null,null)]):null,e.effectDisplay?(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Currently: "),(0,r.createVNode)(u,null,null)]):null])})))}})),{buttonText:u,notifyStyle:f,comp:a,Visibility:y.EE,unref:r.unref}}});const co=(0,u.Z)(fo,[["render",ao],["__scopeId","data-v-5e580749"]]);var so=co,mo=Symbol("ChallengeType");function yo(e){var n=(0,g.ax)(0),o=(0,g.ax)(!1);return(0,oe.z2)((function(){var t=e();if(function(){return void 0!==t.canComplete&&null!==t.canComplete&&t.canComplete[Symbol.for("==")]?t.canComplete[Symbol.for("==")](null):null==t.canComplete}()&&(function(){return void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("==")]?t.resource[Symbol.for("==")](null):null==t.resource}()||function(){return void 0!==t.goal&&null!==t.goal&&t.goal[Symbol.for("==")]?t.goal[Symbol.for("==")](null):null==t.goal}()))throw console.warn("Cannot create challenge without a canComplete property or a resource and goal property",t),"Cannot create challenge without a canComplete property or a resource and goal property";t.id=(0,y.QI)("challenge-"),t.type=mo,t[y.wA]=so,t.completions=n,t.active=o,t.completed=(0,r.computed)((function(){return b.ZP.gt(t.completions.value,0)})),t.maxed=(0,r.computed)((function(){return b.ZP.gte(t.completions.value,(0,r.unref)(t.completionLimit))})),t.toggle=function(){var e=t;if(e.active.value){var n,o;if((0,r.unref)(e.canComplete)&&function(){return void 0!==e.maxed.value&&null!==e.maxed.value&&e.maxed.value[Symbol.for("!")]?e.maxed.value[Symbol.for("!")]():!e.maxed.value}()){var l,i=(0,r.unref)(e.canComplete);"boolean"===typeof i&&(i=1),e.completions.value=b.ZP.min(b.ZP.add(e.completions.value,i),(0,r.unref)(e.completionLimit)),null===(l=e.onComplete)||void 0===l||l.call(e)}e.active.value=!1,null===(n=e.onExit)||void 0===n||n.call(e),null===(o=e.reset)||void 0===o||o.reset()}else if((0,r.unref)(e.canStart)&&(0,r.unref)(e.visibility)===y.EE.Visible&&function(){return void 0!==e.maxed.value&&null!==e.maxed.value&&e.maxed.value[Symbol.for("!")]?e.maxed.value[Symbol.for("!")]():!e.maxed.value}()){var u,a;null===(u=e.reset)||void 0===u||u.reset(),e.active.value=!0,null===(a=e.onEnter)||void 0===a||a.call(e)}},t.complete=function(e){var n,o,l,i=t,u=(0,r.unref)(i.canComplete);i.active.value&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](!1):!1!==u}()&&(!0===u||b.ZP.neq(0,u))&&function(){return void 0!==i.maxed.value&&null!==i.maxed.value&&i.maxed.value[Symbol.for("!")]?i.maxed.value[Symbol.for("!")]():!i.maxed.value}()&&("boolean"===typeof u&&(u=1),i.completions.value=b.ZP.min(b.ZP.add(i.completions.value,u),(0,r.unref)(i.completionLimit)),null===(n=i.onComplete)||void 0===n||n.call(i),function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](!0):!0!==e}()&&(i.active.value=!1,null===(o=i.onExit)||void 0===o||o.call(i),null===(l=i.reset)||void 0===l||l.reset()))},(0,ne.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible);var l=t.visibility;return t.visibility=(0,r.computed)((function(){return!0===Me.ZP.hideChallenges&&(0,r.unref)(t.maxed)?y.EE.None:(0,r.unref)(l)})),function(){return void 0!==t.canComplete&&null!==t.canComplete&&t.canComplete[Symbol.for("==")]?t.canComplete[Symbol.for("==")](null):null==t.canComplete}()&&(t.canComplete=(0,r.computed)((function(){var e=t;return!(function(){return void 0!==e.active.value&&null!==e.active.value&&e.active.value[Symbol.for("!")]?e.active.value[Symbol.for("!")]():!e.active.value}()||function(){return void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("==")]?e.resource[Symbol.for("==")](null):null==e.resource}()||function(){return void 0!==e.goal&&null!==e.goal&&e.goal[Symbol.for("==")]?e.goal[Symbol.for("==")](null):null==e.goal}())&&b.ZP.gte(e.resource.value,(0,r.unref)(e.goal))}))),function(){return void 0!==t.mark&&null!==t.mark&&t.mark[Symbol.for("==")]?t.mark[Symbol.for("==")](null):null==t.mark}()&&(t.mark=(0,r.computed)((function(){return b.ZP.gt((0,r.unref)(t.completionLimit),1)&&function(){return void 0!==!(0,r.unref)(t.maxed)&&null!==!(0,r.unref)(t.maxed)&&(!(0,r.unref)(t.maxed))[Symbol.for("!")]?(!(0,r.unref)(t.maxed))[Symbol.for("!")]():!!(0,r.unref)(t.maxed)}()}))),(0,ne.yB)(t,"canStart"),(0,y.Rh)(t,"canStart",!0),(0,ne.yB)(t,"canComplete"),(0,ne.yB)(t,"completionLimit"),(0,y.Rh)(t,"completionLimit",1),(0,ne.yB)(t,"mark"),(0,ne.yB)(t,"goal"),(0,ne.yB)(t,"classes"),(0,ne.yB)(t,"style"),(0,ne.yB)(t,"display"),function(){return void 0!==t.reset&&null!==t.reset&&t.reset[Symbol.for("!=")]?t.reset[Symbol.for("!=")](null):null!=t.reset}()&&S.globalBus.on("reset",(function(e){e===t.reset&&t.active.value&&t.toggle()})),t[y.tj]=function(){var e=this.active,n=this.maxed,o=this.canComplete,t=this.display,l=this.visibility,i=this.style,u=this.classes,a=this.completed,f=this.canStart,c=this.mark,s=this.id,m=this.toggle;return{active:e,maxed:n,canComplete:o,display:t,visibility:l,style:(0,r.unref)(i),classes:u,completed:a,canStart:f,mark:c,id:s,toggle:m}},t}))}S.globalBus.on("loadSettings",(function(e){(0,y.Rh)(e,"hideChallenges",!1)})),(0,Me.QV)((0,y.tZ)((function(){return(0,r.createVNode)(Ln.Z,{title:"Hide Maxed Challenges","onUpdate:modelValue":function(e){return Me.ZP.hideChallenges=e},modelValue:Me.ZP.hideChallenges},null)})));var vo=(0,r.shallowReactive)({}),bo=Symbol("Hotkey");function So(e){return(0,oe.z2)((function(){var n=e();return n.type=bo,(0,ne.yB)(n,"enabled"),(0,y.Rh)(n,"enabled",!0),(0,ne.yB)(n,"description"),n}))}S.globalBus.on("addLayer",(function(e){(0,y.bD)(e,bo).forEach((function(e){vo[e.key]=e}))})),S.globalBus.on("removeLayer",(function(e){(0,y.bD)(e,bo).forEach((function(e){vo[e.key]=void 0}))})),document.onkeydown=function(e){var n;if("INPUT"!==(null===(n=e.target)||void 0===n?void 0:n.tagName)&&(!dr.value||!function(){return void 0!==fe.Z.keepGoing&&null!==fe.Z.keepGoing&&fe.Z.keepGoing[Symbol.for("!")]?fe.Z.keepGoing[Symbol.for("!")]():!fe.Z.keepGoing}())){var o=e.key;e.shiftKey&&(o=function(){return"shift+"[Symbol.for("+")]?"shift+"[Symbol.for("+")](o):"shift+"+o}()),e.ctrlKey&&(o=function(){return"ctrl+"[Symbol.for("+")]?"ctrl+"[Symbol.for("+")](o):"ctrl+"+o}());var t=vo[o];t&&(0,r.unref)(t.enabled)&&(e.preventDefault(),t.onPress())}},(0,Me.fw)((0,y.tZ)((function(){var e=Object.values(vo).filter((function(e){return(0,r.unref)(null===e||void 0===e?void 0:e.enabled)}));return 0===e.length?"":(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.createVNode)("h4",null,[(0,r.createTextVNode)("Hotkeys")]),e.map((function(e){return(0,r.createVNode)("div",null,[null===e||void 0===e?void 0:e.key,(0,r.createTextVNode)(": "),null===e||void 0===e?void 0:e.description])}))])})));var go=Symbol("Links");function po(e){return(0,oe.z2)((function(){var n=e();return n.type=go,n[y.wA]=R,(0,ne.yB)(n,"links"),n[y.tj]=function(){var e=this.links;return{links:e}},n}))}var ho=o(5418);function No(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}]),class:(0,r.normalizeClass)((0,j.Z)({feature:!0,milestone:!0,done:e.unref(e.earned)},e.unref(e.classes)))},[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.unref(e.comp)))),(0,r.createVNode)(a,{id:e.id},null,8,["id"])],6)):(0,r.createCommentVNode)("",!0)}var ko=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},display:{type:(0,w.P5)(String,Object,Function),required:!0},style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),earned:{type:(0,w.P5)(Boolean),required:!0},id:{type:String,required:!0}},components:{Node:G},setup:function(e){var n=(0,r.toRefs)(e),o=n.display,t=(0,r.shallowRef)("");return(0,r.watchEffect)((function(){var e=(0,w.Uv)(o);if(function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e}())t.value="";else if((0,w.RU)(e))t.value=(0,w.MM)(e);else{var n=(0,w.MM)(e.requirement,"h3"),l=(0,w.MM)(e.effectDisplay||"","b"),i=(0,w.MM)(e.optionsDisplay||"","span");t.value=(0,w.MM)((0,y.tZ)((function(){return(0,r.createVNode)("span",null,[(0,r.createVNode)(n,null,null),e.effectDisplay?(0,r.createVNode)("div",null,[(0,r.createVNode)(l,null,null)]):null,e.optionsDisplay?(0,r.createVNode)("div",{class:"equal-spaced"},[(0,r.createVNode)(i,null,null)]):null])})))}})),{comp:t,unref:r.unref,Visibility:y.EE}}});const Vo=(0,u.Z)(ko,[["render",No],["__scopeId","data-v-0b660ac3"]]);var xo,Mo=Vo,Co=(0,Se.pm)(),Zo=Symbol("Milestone");function wo(e){var n=(0,g.ax)(!1);return(0,oe.z2)((function(){var o,t=function(){return void 0!==(o=null===e||void 0===e?void 0:e())&&null!==(o=null===e||void 0===e?void 0:e())&&(o=null===e||void 0===e?void 0:e())[Symbol.for("!==")]?(o=null===e||void 0===e?void 0:e())[Symbol.for("!==")](null):null!==(o=null===e||void 0===e?void 0:e())}()&&function(){return void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](void 0):void 0!==o}()?o:{};t.id=(0,y.QI)("milestone-"),t.type=Zo,t[y.wA]=Mo,t.earned=n,t.complete=function(){n.value=!0},(0,ne.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible);var l=t.visibility;if(t.visibility=(0,r.computed)((function(){var e=(0,r.unref)(t.display);switch(Me.ZP.msDisplay){default:case xo.All:return(0,r.unref)(l);case xo.Configurable:return(0,r.unref)(t.earned)&&function(){return void 0!==(null!=e&&"object"==(0,v.Z)(e)&&"optionsDisplay"in e)&&null!==(null!=e&&"object"==(0,v.Z)(e)&&"optionsDisplay"in e)&&(null!=e&&"object"==(0,v.Z)(e)&&"optionsDisplay"in e)[Symbol.for("!")]?(null!=e&&"object"==(0,v.Z)(e)&&"optionsDisplay"in e)[Symbol.for("!")]():!(null!=e&&"object"==(0,v.Z)(e)&&"optionsDisplay"in e)}()?y.EE.None:(0,r.unref)(l);case xo.Incomplete:return(0,r.unref)(t.earned)?y.EE.None:(0,r.unref)(l);case xo.None:return y.EE.None}})),(0,ne.yB)(t,"style"),(0,ne.yB)(t,"classes"),(0,ne.yB)(t,"display"),t[y.tj]=function(){var e=this.visibility,n=this.display,o=this.style,t=this.classes,l=this.earned,i=this.id;return{visibility:e,display:n,style:(0,r.unref)(o),classes:t,earned:l,id:i}},t.shouldEarn){var i=t;(0,r.watchEffect)((function(){var e,n;if(function(){return void 0!==i.earned.value&&null!==i.earned.value&&i.earned.value[Symbol.for("!")]?i.earned.value[Symbol.for("!")]():!i.earned.value}()&&(0,r.unref)(i.visibility)===y.EE.Visible&&function(){return void 0!==(e=i.shouldEarn)&&null!==(e=i.shouldEarn)&&(e=i.shouldEarn)[Symbol.for("!==")]?(e=i.shouldEarn)[Symbol.for("!==")](null):null!==(e=i.shouldEarn)}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()&&e.call(i)&&(i.earned.value=!0,null===(n=i.onComplete)||void 0===n||n.call(i),i.display)){var o=(0,r.unref)(i.display),t=(0,w.MM)((0,w.RU)(o)?o:o.requirement);Co((0,r.createVNode)(r.Fragment,null,[(0,r.createVNode)("h3",null,[(0,r.createTextVNode)("Milestone earned!")]),(0,r.createVNode)("div",null,[(0,r.createVNode)(t,null,null)])]))}}))}return t}))}(function(e){e["All"]="all",e["Configurable"]="configurable",e["Incomplete"]="incomplete",e["None"]="none"})(xo||(xo={})),S.globalBus.on("loadSettings",(function(e){(0,y.Rh)(e,"msDisplay",xo.All)}));var Bo=Object.values(xo).map((function(e){return{label:(0,De.IJ)(e),value:e}}));(0,Me.QV)((0,y.tZ)((function(){return(0,r.createVNode)(ho.Z,{title:"Show Milestones",options:Bo,"onUpdate:modelValue":function(e){return Me.ZP.msDisplay=e},modelValue:Me.ZP.msDisplay},null)})));var Po=(0,r.defineComponent)({props:{display:null},setup:function(e){var n=e,o=(0,r.toRefs)(n),t=o.display,l=(0,w.vq)(t);return function(e,n){return(0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)((0,r.unref)(l)))}}});const Eo=Po;var Fo=Eo,To=Symbol("Tab");function Do(e){return(0,oe.z2)((function(){var n=e();return n.id=(0,y.QI)("tab-"),n.type=To,n[y.wA]=Fo,n[y.tj]=function(){var e=this.display;return{display:e}},n}))}o(7941);function Io(e,n,o,t,l,i){var u;return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,onClick:n[0]||(n[0]=function(){return e.selectTab&&e.selectTab.apply(e,arguments)}),class:(0,r.normalizeClass)(["tabButton",(0,j.Z)({active:e.active},e.unref(e.classes))]),style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.glowColorStyle,function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}])},[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component)))],6)):(0,r.createCommentVNode)("",!0)}var Ro=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},display:{type:(0,w.P5)(Object,String,Function),required:!0},style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),glowColor:(0,w.P5)(String),active:Boolean,floating:Boolean},emits:["selectTab"],setup:function(e,n){var o=n.emit,t=(0,r.toRefs)(e),l=t.display,i=t.glowColor,u=t.floating,a=(0,w.vq)(l),f=(0,r.computed)((function(){var e=(0,w.Uv)(i);return function(){return void 0!==e&&null!==e&&e[Symbol.for("!")]?e[Symbol.for("!")]():!e}()?{}:(0,r.unref)(u)?ge(e):{boxShadow:"0px 9px 5px -6px ".concat(e)}}));function c(){o("selectTab")}return{selectTab:c,component:a,glowColorStyle:f,unref:r.unref,Visibility:y.EE}}});const _o=(0,u.Z)(Ro,[["render",Io],["__scopeId","data-v-3e3f03f9"]]);var Oo=_o;function Uo(e,n,o,t,l,i){var u,a,f=(0,r.resolveComponent)("TabButton"),c=(0,r.resolveComponent)("Sticky");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:(0,r.normalizeClass)(["tab-family-container",(0,j.Z)((0,j.Z)({},e.unref(e.classes)),e.tabClasses)]),style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:[],function(){return void 0!==(a=e.tabStyle)&&null!==(a=e.tabStyle)&&(a=e.tabStyle)[Symbol.for("!==")]?(a=e.tabStyle)[Symbol.for("!==")](null):null!==(a=e.tabStyle)}()&&function(){return void 0!==a&&null!==a&&a[Symbol.for("!==")]?a[Symbol.for("!==")](void 0):void 0!==a}()?a:[]])},[(0,r.createVNode)(c,{class:"tab-buttons-container"},{default:(0,r.withCtx)((function(){return[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["tab-buttons",{floating:e.floating}])},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.unref(e.tabs),(function(n,o){return(0,r.openBlock)(),(0,r.createBlock)(f,(0,r.mergeProps)({onSelectTab:function(n){return e.selected.value=o},floating:e.floating,key:o,active:e.unref(n.tab)===e.unref(e.activeTab)},e.gatherButtonProps(n)),null,16,["onSelectTab","floating","active"])})),128))],2)]})),_:1}),e.unref(e.activeTab)?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.unref(e.component)),{key:0})):(0,r.createCommentVNode)("",!0)],6)):(0,r.createCommentVNode)("",!0)}var jo=(0,r.defineComponent)({props:{visibility:{type:(0,w.P5)(Number),required:!0},activeTab:{type:(0,w.P5)(Object),required:!0},selected:{type:Object,required:!0},tabs:{type:(0,w.P5)(Object),required:!0},style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object)},components:{Sticky:Yn,TabButton:Oo},setup:function(e){var n=(0,r.toRefs)(e),o=n.activeTab,t=(0,r.computed)((function(){return xe.Z[Me.ZP.theme].floatingTabs})),l=(0,r.shallowRef)("");(0,r.watchEffect)((function(){var e=(0,w.Uv)(o);!function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e}()?(0,w.RU)(e)?l.value=(0,w.MM)(e):l.value=(0,w.MM)((0,r.unref)(e.display)):l.value=""}));var i=(0,r.computed)((function(){var e=(0,w.Uv)(o),n=(0,w.RU)(e)||function(){return void 0!==e&&null!==e&&e[Symbol.for("!")]?e[Symbol.for("!")]():!e}()?void 0:(0,r.unref)(e.classes);return n})),u=(0,r.computed)((function(){var e=(0,w.Uv)(o);return(0,w.RU)(e)||function(){return void 0!==e&&null!==e&&e[Symbol.for("!")]?e[Symbol.for("!")]():!e}()?void 0:(0,r.unref)(e.style)}));function a(e){var n=e.display,o=e.style,t=e.classes,l=e.glowColor,i=e.visibility;return{display:n,style:(0,r.unref)(o),classes:t,glowColor:l,visibility:i}}return{floating:t,tabClasses:i,tabStyle:u,Visibility:y.EE,component:l,gatherButtonProps:a,unref:r.unref}}});const Ao=(0,u.Z)(jo,[["render",Uo],["__scopeId","data-v-46a6b098"]]);var qo=Ao,zo=Symbol("TabButton"),Lo=Symbol("TabFamily");function Go(e,n){if(0===Object.keys(e).length)throw console.warn("Cannot create tab family with 0 tabs"),"Cannot create tab family with 0 tabs";var o=(0,g.ax)(Object.keys(e)[0]);return(0,oe.z2)((function(){var t,l=function(){return void 0!==(t=null===n||void 0===n?void 0:n())&&null!==(t=null===n||void 0===n?void 0:n())&&(t=null===n||void 0===n?void 0:n())[Symbol.for("!==")]?(t=null===n||void 0===n?void 0:n())[Symbol.for("!==")](null):null!==(t=null===n||void 0===n?void 0:n())}()&&function(){return void 0!==t&&null!==t&&t[Symbol.for("!==")]?t[Symbol.for("!==")](void 0):void 0!==t}()?t:{};l.id=(0,y.QI)("tabFamily-"),l.type=Lo,l[y.wA]=qo,l.tabs=Object.keys(e).reduce((function(n,o){var r=e[o]();return r.type=zo,r[y.wA]=Oo,(0,ne.yB)(r,"visibility"),(0,y.Rh)(r,"visibility",y.EE.Visible),(0,ne.yB)(r,"tab"),(0,ne.yB)(r,"display"),(0,ne.yB)(r,"classes"),(0,ne.yB)(r,"style"),(0,ne.yB)(r,"glowColor"),n[o]=r,n}),{}),l.selected=o,l.activeTab=(0,r.computed)((function(){var e=(0,r.unref)(i.tabs);if(function(){return void 0!==o.value&&null!==o.value&&o.value[Symbol.for("in")]?o.value[Symbol.for("in")](e):o.value in e}()&&(0,r.unref)(e[o.value].visibility)===y.EE.Visible)return(0,r.unref)(e[o.value].tab);var n=Object.values(e).find((function(e){return(0,r.unref)(e.visibility)===y.EE.Visible}));return n?(0,r.unref)(n.tab):null})),(0,ne.yB)(l,"visibility"),(0,y.Rh)(l,"visibility",y.EE.Visible),(0,ne.yB)(l,"classes"),(0,ne.yB)(l,"style"),l[y.tj]=function(){var e=this.visibility,n=this.activeTab,o=this.selected,t=this.tabs,l=this.style,i=this.classes;return{visibility:e,activeTab:n,selected:o,tabs:t,style:(0,r.unref)(l),classes:i}};var i=l;return i}))}var Ho=["disabled"];function Wo(e,n,o,t,l,i){var u,a=(0,r.resolveComponent)("MarkNode"),f=(0,r.resolveComponent)("Node");return function(){return void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None}()?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,style:(0,r.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},function(){return void 0!==(u=e.unref(e.style))&&null!==(u=e.unref(e.style))&&(u=e.unref(e.style))[Symbol.for("!==")]?(u=e.unref(e.style))[Symbol.for("!==")](null):null!==(u=e.unref(e.style))}()&&function(){return void 0!==u&&null!==u&&u[Symbol.for("!==")]?u[Symbol.for("!==")](void 0):void 0!==u}()?u:{}]),onClick:n[0]||(n[0]=function(){return e.purchase&&e.purchase.apply(e,arguments)}),class:(0,r.normalizeClass)((0,j.Z)({feature:!0,upgrade:!0,can:e.unref(e.canPurchase),locked:function(){return void 0!==e.unref(e.canPurchase)&&null!==e.unref(e.canPurchase)&&e.unref(e.canPurchase)[Symbol.for("!")]?e.unref(e.canPurchase)[Symbol.for("!")]():!e.unref(e.canPurchase)}(),bought:e.unref(e.bought)},e.unref(e.classes))),disabled:function(){return void 0!==e.unref(e.canPurchase)&&null!==e.unref(e.canPurchase)&&e.unref(e.canPurchase)[Symbol.for("!")]?e.unref(e.canPurchase)[Symbol.for("!")]():!e.unref(e.canPurchase)}()},[e.unref(e.component)?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.unref(e.component)),{key:0})):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,r.createVNode)(f,{id:e.id},null,8,["id"])],14,Ho)):(0,r.createCommentVNode)("",!0)}var Yo=(0,r.defineComponent)({props:{display:{type:(0,w.P5)(String,Object,Function),required:!0},visibility:{type:(0,w.P5)(Number),required:!0},style:(0,w.P5)(String,Object,Array),classes:(0,w.P5)(Object),resource:Object,cost:(0,w.P5)(String,Object,Number),canPurchase:{type:(0,w.P5)(Boolean),required:!0},bought:{type:(0,w.P5)(Boolean),required:!0},mark:(0,w.P5)(Boolean,String),id:{type:String,required:!0},purchase:{type:Function,required:!0}},components:{Node:G,MarkNode:J},setup:function(e){var n=(0,r.toRefs)(e),o=n.display,t=n.cost,l=(0,r.shallowRef)("");return(0,r.watchEffect)((function(){var n=(0,w.Uv)(o);if(function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}())l.value="";else if((0,w.RU)(n))l.value=(0,w.MM)(n);else{var i=(0,w.Uv)(t),u=(0,w.MM)(n.title||"","h3"),a=(0,w.MM)(n.description,"div"),f=(0,w.MM)(n.effectDisplay||"");l.value=(0,w.MM)((0,y.tZ)((function(){var o;return(0,r.createVNode)("span",null,[n.title?(0,r.createVNode)("div",null,[(0,r.createVNode)(u,null,null)]):null,(0,r.createVNode)(a,null,null),n.effectDisplay?(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Currently: "),(0,r.createVNode)(f,null,null)]):null,function(){return void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource}()?(0,r.createVNode)(r.Fragment,null,[(0,r.createVNode)("br",null,null),(0,r.createTextVNode)("Cost: "),e.resource&&M(e.resource,i)," ",null===(o=e.resource)||void 0===o?void 0:o.displayName]):null])})))}})),{component:l,unref:r.unref,Visibility:y.EE}}});const Ko=(0,u.Z)(Yo,[["render",Wo],["__scopeId","data-v-6f164fe2"]]);var Qo=Ko,Jo=Symbol("Upgrade");function $o(e){var n=(0,g.ax)(!1);return(0,oe.z2)((function(){var o=e();return o.id=(0,y.QI)("upgrade-"),o.type=Jo,o[y.wA]=Qo,function(){return void 0!==o.canAfford&&null!==o.canAfford&&o.canAfford[Symbol.for("==")]?o.canAfford[Symbol.for("==")](null):null==o.canAfford}()&&(function(){return void 0!==o.resource&&null!==o.resource&&o.resource[Symbol.for("==")]?o.resource[Symbol.for("==")](null):null==o.resource}()||function(){return void 0!==o.cost&&null!==o.cost&&o.cost[Symbol.for("==")]?o.cost[Symbol.for("==")](null):null==o.cost}())&&console.warn("Error: can't create upgrade without a canAfford property or a resource and cost property",o),o.bought=n,!function(){return void 0!==o.canAfford&&null!==o.canAfford&&o.canAfford[Symbol.for("==")]?o.canAfford[Symbol.for("==")](null):null==o.canAfford}()?(0,ne.yB)(o,"canAfford"):o.canAfford=(0,r.computed)((function(){var e=o;return function(){return void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource}()&&function(){return void 0!==e.cost&&null!==e.cost&&e.cost[Symbol.for("!=")]?e.cost[Symbol.for("!=")](null):null!=e.cost}()&&b.ZP.gte(e.resource.value,(0,r.unref)(e.cost))})),o.canPurchase=(0,r.computed)((function(){return(0,r.unref)(o.visibility)===y.EE.Visible&&(0,r.unref)(o.canAfford)&&function(){return void 0!==(0,r.unref)(o.bought)&&null!==(0,r.unref)(o.bought)&&(0,r.unref)(o.bought)[Symbol.for("!")]?(0,r.unref)(o.bought)[Symbol.for("!")]():!(0,r.unref)(o.bought)}()})),o.purchase=function(){var e,t=o;(function(){return void 0!==(0,r.unref)(t.canPurchase)&&null!==(0,r.unref)(t.canPurchase)&&(0,r.unref)(t.canPurchase)[Symbol.for("!")]?(0,r.unref)(t.canPurchase)[Symbol.for("!")]():!(0,r.unref)(t.canPurchase)})()||(function(){return void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("!=")]?t.resource[Symbol.for("!=")](null):null!=t.resource}()&&function(){return void 0!==t.cost&&null!==t.cost&&t.cost[Symbol.for("!=")]?t.cost[Symbol.for("!=")](null):null!=t.cost}()&&(t.resource.value=b.ZP.sub(t.resource.value,(0,r.unref)(t.cost))),n.value=!0,null===(e=t.onPurchase)||void 0===e||e.call(t))},(0,ne.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,ne.yB)(o,"classes"),(0,ne.yB)(o,"style"),(0,ne.yB)(o,"display"),(0,ne.yB)(o,"mark"),(0,ne.yB)(o,"cost"),(0,ne.yB)(o,"resource"),o[y.tj]=function(){var e=this.display,n=this.visibility,o=this.style,t=this.classes,l=this.resource,i=this.cost,u=this.canPurchase,a=this.bought,f=this.mark,c=this.id,s=this.purchase;return{display:e,visibility:n,style:(0,r.unref)(o),classes:t,resource:l,cost:i,canPurchase:u,bought:a,mark:f,id:c,purchase:s}},o}))}function Xo(e){return"function"===typeof e||"[object Object]"===Object.prototype.toString.call(e)&&function(){return void 0!==(0,r.isVNode)(e)&&null!==(0,r.isVNode)(e)&&(0,r.isVNode)(e)[Symbol.for("!")]?(0,r.isVNode)(e)[Symbol.for("!")]():!(0,r.isVNode)(e)}()}var er="c",nr=(0,B.createLayer)(er,(function(){var e="#4BDC13",n="Candies",o=p(0,"lollipops"),t=h(o),l=(0,g.ax)(!1),i=(0,g.ax)("pointy"),u=(0,g.ax)(10),a=(0,g.ax)(new b.ZP(10)),f=(0,r.computed)((function(){return b.ZP.pow(o.value,.2)})),c=(0,r.computed)((function(){return b.ZP.times(o.value,10)})),s=an((function(){return{title:"Lore",titleStyle:{color:"#FE0000"},display:"DEEP LORE!",bodyStyle:{backgroundColor:"#0000EE"},color:"rgb(75, 220, 19)"}})),m=wo((function(){return{shouldEarn:function(){return b.ZP.gte(t.value,3)},display:{requirement:"3 Lollipops",effectDisplay:"Unlock the next milestone"}}})),v=wo((function(){return{visibility:function(){return(0,y.Kf)(m.earned.value)},shouldEarn:function(){return b.ZP.gte(t.value,4)},display:{requirement:"4 Lollipops",effectDisplay:"You can toggle beep and boop (which do nothing)",optionsDisplay:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[(0,r.createVNode)(Ln.Z,{title:"beep","onUpdate:modelValue":function(e){return l.value=e},modelValue:l.value},null),(0,r.createVNode)(Ln.Z,{title:"boop","onUpdate:modelValue":function(e){return ir.boop.value=e},modelValue:ir.boop.value},null)])}))},style:function(){return this.earned?{backgroundColor:"#1111DD"}:{}}}})),S=[m,v],N=yo((function(){return{title:"Fun",completionLimit:3,display:function(){return{description:"Makes the game 0% harder
".concat((0,b.Ht)(this.completions.value),"/").concat(this.completionLimit," completions"),goal:"Have 20 points I guess",reward:"Says hi",effectDisplay:function(){return void 0!==(0,b.WU)(k.value)&&null!==(0,b.WU)(k.value)&&(0,b.WU)(k.value)[Symbol.for("+")]?(0,b.WU)(k.value)[Symbol.for("+")]("x"):(0,b.WU)(k.value)+"x"}()}},visibility:function(){return(0,y.Kf)(b.ZP.gt(t.value,0))},goal:20,resource:sr.points,onComplete:function(){console.log("hiii")},onEnter:function(){sr.points.value=0,sr.best.value=sr.points.value,sr.total.value=sr.points.value,console.log("So challenging")},onExit:function(){console.log("Sweet freedom!")},style:{height:"200px"}}})),k=(0,r.computed)((function(){return b.ZP.add(o.value,1).tetrate(.02)})),V=$o((function(){return{display:{title:"Generator of Genericness",description:"Gain 1 point every second"},cost:1,resource:o}})),x=$o((function(){return{display:function(){return{description:"Point generation is faster based on your unspent Lollipops",effectDisplay:"".concat((0,b.WU)(C.value),"x")}},cost:1,resource:o,visibility:function(){return(0,y.Kf)(V.bought.value)}}})),C=(0,r.computed)((function(){var e=b.ZP.add(o.value,1).pow(.5);return e.gte("1e20000000")&&(e=e.sqrt().times("1e10000000")),e})),Z=$o((function(){return{visibility:function(){return(0,y.Kf)(x.bought.value)},canAfford:function(){return b.ZP.lt(sr.points.value,7)},onPurchase:function(){sr.points.value=b.ZP.add(sr.points.value,7)},display:"Only buyable with less than 7 points, and gives you 7 more. Unlocks a secret subtab.",style:function(){var e=this;return this.bought?{backgroundColor:"#1111dd"}:function(){return void 0!==e.canAfford&&null!==e.canAfford&&e.canAfford[Symbol.for("!")]?e.canAfford[Symbol.for("!")]():!e.canAfford}()?{backgroundColor:"#dd1111"}:{}}}})),B=$o((function(){return{resource:p(E.amount,"Exhancers",0),cost:3,display:{title:"This upgrade doesn't exist",description:"Or does it?"}}})),P=[V,x,Z],E=io((function(){return{resource:o,cost:function(){var e=new b.ZP(this.amount.value);e.gte(25)&&(e=e.pow(2).div(25));var n=b.ZP.pow(2,e.pow(1.5));return n.floor()},display:function(){return{title:"Exhancers",description:"Adds ".concat((0,b.WU)(F.value)," things and multiplies stuff by ").concat((0,b.WU)(T.value),".")}},onPurchase:function(e){a.value=b.ZP.add(a.value,function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](null):null!==e}()&&function(){return void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](void 0):void 0!==e}()?e:0)},style:{height:"222px"},purchaseLimit:4}})),F=(0,r.computed)((function(){return b.ZP.gte(E.amount.value,0)?b.ZP.pow(25,b.ZP.pow(E.amount.value,1.1)):b.ZP.pow(function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](25):.04}(),b.ZP.times(E.amount.value,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()).pow(1.1))})),T=(0,r.computed)((function(){return b.ZP.gte(E.amount.value,0)?b.ZP.pow(25,b.ZP.pow(E.amount.value,1.1)):b.ZP.pow(function(){return 1[Symbol.for("/")]?1[Symbol.for("/")](25):.04}(),b.ZP.times(E.amount.value,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}()).pow(1.1))})),D=(0,g.ax)(!1),I=(0,r.ref)(!1),R=Le((function(){return{small:!0,display:"Respec Thingies",onClick:function(){D.value&&function(){return void 0!==I.value&&null!==I.value&&I.value[Symbol.for("!")]?I.value[Symbol.for("!")]():!I.value}()?I.value=!0:(o.value=b.ZP.add(o.value,a.value),E.amount.value=0,sr.tree.reset(G))}}})),_=Le((function(){return{small:!0,display:"Sell One",onClick:function(){b.ZP.lte(E.amount.value,0)||(E.amount.value=b.ZP.sub(E.amount.value,1),o.value=b.ZP.add(o.value,E.cost.value),a.value=b.ZP.sub(a.value,E.cost.value))}}})),O=(0,y.tZ)((function(){return(0,r.createVNode)(Gn.Z,null,{default:function(){return[(0,r.createVNode)(se.Z,null,{default:function(){return[(0,r.createVNode)(Ln.Z,{title:"Confirm","onUpdate:modelValue":function(e){return D.value=e},modelValue:D.value},null),(0,w._4)(R)]}}),(0,w._4)(E),(0,w._4)(_),(0,r.createVNode)($n.Z,{modelValue:I.value,"onUpdate:modelValue":function(e){return I.value=e}},{header:function(){return(0,r.createVNode)("h2",null,[(0,r.createTextVNode)("Confirm Respec")])},body:function(){return(0,r.createVNode)(r.Fragment,null,[(0,r.createTextVNode)("Are you sure? Respeccing these doesn't accomplish much")])},footer:function(){return(0,r.createVNode)("div",{class:"modal-default-footer"},[(0,r.createVNode)("div",{class:"modal-default-flex-grow"},null),(0,r.createVNode)("button",{class:"button modal-default-button",onClick:function(){return I.value=!1}},[(0,r.createTextVNode)("Cancel")]),(0,r.createVNode)("button",{class:"button modal-default-button danger",onClick:function(){R.onClick(),I.value=!1}},[(0,r.createTextVNode)("Respec")])])}})]}})})),U=to((function(){return{fillStyle:{backgroundColor:"#FFFFFF"},baseStyle:{backgroundColor:"#696969"},textStyle:{color:"#04e050"},direction:De.Nm.Right,width:300,height:30,progress:function(){return b.ZP.add(sr.points.value,1).log(10).div(10).toNumber()},display:function(){return function(){return void 0!==(0,b.WU)(sr.points.value)&&null!==(0,b.WU)(sr.points.value)&&(0,b.WU)(sr.points.value)[Symbol.for("+")]?(0,b.WU)(sr.points.value)[Symbol.for("+")](" / 1e10 points"):(0,b.WU)(sr.points.value)+" / 1e10 points"}()}}})),j=to((function(){return{fillStyle:{backgroundColor:"#4BEC13"},baseStyle:{backgroundColor:"#000000"},textStyle:{textShadow:"0px 0px 2px #000000"},borderStyle:{borderWidth:"7px"},direction:De.Nm.Up,width:50,height:200,progress:function(){return b.ZP.div(sr.points.value,100)},display:function(){return function(){return void 0!==(0,b.Ht)(b.ZP.div(sr.points.value,1).min(100))&&null!==(0,b.Ht)(b.ZP.div(sr.points.value,1).min(100))&&(0,b.Ht)(b.ZP.div(sr.points.value,1).min(100))[Symbol.for("+")]?(0,b.Ht)(b.ZP.div(sr.points.value,1).min(100))[Symbol.for("+")]("%"):(0,b.Ht)(b.ZP.div(sr.points.value,1).min(100))+"%"}()}}})),A=to((function(){return{fillStyle:{backgroundColor:"#FE0102"},baseStyle:{backgroundColor:"#222222"},textStyle:{textShadow:"0px 0px 2px #000000"},direction:De.Nm.Up,width:100,height:30,progress:function(){return b.ZP.div(o.value,50)}}})),q=Ke((function(){return{scaling:$e(Ye(10,.5),1e100,.5),baseResource:sr.points,gainResource:o,roundUpCost:!0,gainModifier:In(Dn(2,"Because I felt like it"),Fn(1,"Nice modifier"))}})),z=gn((function(){return{thingsToReset:function(){return[nr]}}})),L=[So((function(){return{key:"c",description:"reset for lollipops or whatever",onPress:function(){H.canClick.value&&H.onClick()}}})),So((function(){return{key:"ctrl+c",description:"respec things",onPress:function(){R.onClick()}}}))],G=He((function(){return{layerID:er,color:e,reset:z,mark:"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png",tooltip:function(){var e=M(o);return b.ZP.gt(E.amount.value,0)&&(e=function(){return void 0!==e&&null!==e&&e[Symbol.for("+")]?e[Symbol.for("+")]("



".concat((0,b.Ht)(E.amount.value)," Exhancers
")):e+"



".concat((0,b.Ht)(E.amount.value)," Exhancers
")}()),e},style:{color:"#3325CC",textDecoration:"underline"}}}));En(G,{display:ae(o),pinnable:!0});var H=Ge((function(){return{conversion:q,tree:sr.tree,treeNode:G,style:{color:"#AA66AA"},resetDescription:"Melt your points into "}}));En(H,{display:(0,y.tZ)((function(){return Rn("Modifiers","",q.gainModifier,q.scaling.currentGain(q))})),pinnable:!0,direction:De.Nm.Down,style:"width: 400px; text-align: left"});var W=le((function(){return{display:"TH",color:"#6d3678",canClick:function(){return b.ZP.gte(sr.points.value,10)},tooltip:"Thanos your points",onClick:function(){sr.points.value=b.ZP.div(sr.points.value,2),console.log("Thanos'd")},glowColor:function(){return b.ZP.eq(E.amount.value,1)?"orange":""}}})),Y=le((function(){return{display:"h",color:function(){return xe.Z[Me.ZP.theme].variables["--locked"]},tooltip:{display:(0,r.computed)((function(){return"Restore your points to ".concat((0,b.WU)(u.value))})),right:!0},canClick:function(){return b.ZP.lt(sr.points.value,u.value)},onClick:function(){sr.points.value=u.value}}})),K=le((function(){return{visibility:y.EE.Hidden}})),Q=ie((function(){return{nodes:function(){return[[ir.treeNode,G],[W,K,Y]]},branches:function(){return[{startNode:ir.treeNode,endNode:G,"stroke-width":"25px",stroke:"green",style:{filter:"blur(5px)"}},{startNode:G,endNode:W},{startNode:W,endNode:Y}]}}})),J=po((function(){return{links:[{startNode:Y,endNode:A,"stroke-width":"5px",stroke:"red",offsetEnd:{x:function(){return(-50)[Symbol.for("+")]?(-50)[Symbol.for("+")](100*A.progress.value.toNumber()):100*A.progress.value.toNumber()-50}(),y:0}}]}})),$=Go({first:function(){return{tab:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[w._4.apply(void 0,P),(0,w._4)(B),(0,r.createVNode)("div",null,[(0,r.createTextVNode)("confirmed")])])})),display:"first"}},second:function(){return{tab:ir.display,display:"second"}}},(function(){return{style:{width:"660px",backgroundColor:"brown","--background":"brown",border:"solid white",marginLeft:"auto",marginRight:"auto"}}})),X=Go({mainTab:function(){return{tab:Do((function(){return{display:(0,y.tZ)((function(){var n;return(0,r.createVNode)(r.Fragment,null,[(0,r.createVNode)(Pn,{resource:o,color:e,effectDisplay:"which are boosting waffles by ".concat((0,b.WU)(f.value)," and increasing the Ice Cream cap by ").concat((0,b.WU)(c.value))},null),(0,r.createVNode)(Yn,null,Xo(n=(0,w.sY)(H))?n:{default:function(){return[n]}}),(0,r.createVNode)(kn,{resource:o,color:e},null),(0,r.createVNode)(d,{height:"5px"},null),(0,r.createVNode)("button",{onClick:function(){return console.log("yeet")}},[(0,r.createTextVNode)("'HI'")]),(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Name your points!")]),(0,r.createVNode)(zn.Z,{modelValue:i.value,"onUpdate:modelValue":function(e){return i.value=e}},null),(0,r.createVNode)(Yn,{style:"color: red; font-size: 32px; font-family: Comic Sans MS;"},{default:function(){return[(0,r.createTextVNode)("I have "),M(sr.points),(0,r.createTextVNode)(" "),i.value,(0,r.createTextVNode)(" points!")]}}),(0,r.createVNode)("hr",null,null),w.Dy.apply(void 0,S),(0,r.createVNode)(d,null,null),w._4.apply(void 0,P),(0,w._4)(B),(0,w._4)(N)])}))}})),display:"main tab",glowColor:function(){return V.canPurchase.value||x.canPurchase.value||Z.canPurchase.value||N.canComplete.value?"blue":""},style:{color:"orange"}}},thingies:function(){return{tab:Do((function(){return{style:function(){return{backgroundColor:"#222222","--background":"#222222"}},display:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[(0,w.sY)(O),(0,r.createVNode)(d,null,null),(0,r.createVNode)(se.Z,{style:"width: 600px; height: 350px; background-color: green; border-style: solid;"},{default:function(){return[(0,r.createVNode)(Ln.Z,{"onUpdate:modelValue":function(e){return l.value=e},modelValue:l.value},null),(0,r.createVNode)(d,{width:"30px",height:"10px"},null),(0,r.createVNode)("div",null,[(0,r.createVNode)("span",null,[(0,r.createTextVNode)("Beep")])]),(0,r.createVNode)(d,null,null),(0,r.createVNode)(Jn,{height:"200px"},null)]}}),(0,r.createVNode)(d,null,null),(0,r.createVNode)("img",{src:"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png"},null)])}))}})),glowColor:"white",display:"thingies",style:{borderColor:"orange"}}},jail:function(){return{tab:Do((function(){return{display:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[(0,w.sY)(s),(0,w.sY)(U),(0,r.createVNode)(d,null,null),(0,r.createVNode)(se.Z,null,{default:function(){return[(0,r.createVNode)(Gn.Z,{style:"background-color: #555555; padding: 15px"},{default:function(){return[(0,r.createVNode)("div",{style:"color: teal"},[(0,r.createTextVNode)("Sugar level:")]),(0,r.createVNode)(d,null,null),(0,w.sY)(j)]}}),(0,r.createVNode)(d,null,null),(0,r.createVNode)(Gn.Z,null,{default:function(){return[(0,r.createVNode)("div",null,[(0,r.createTextVNode)("idk")]),(0,r.createVNode)(d,{width:"0",height:"50px"},null),(0,w.sY)(A)]}})]}}),(0,r.createVNode)(d,null,null),(0,r.createVNode)("div",null,[(0,r.createTextVNode)('It\'s jail because "bars"! So funny! Ha ha!')]),(0,w.sY)(Q)])}))}})),display:"jail"}},illuminati:function(){return{tab:Do((function(){return{display:(0,y.tZ)((function(){return(0,r.createVNode)("div",null,[(0,r.createVNode)("h1",null,[(0,r.createTextVNode)(" C O N F I R M E D ")]),(0,r.createVNode)(d,null,null),(0,w.sY)($),(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Adjust how many points H gives you!")]),(0,r.createVNode)(qn,{"onUpdate:modelValue":function(e){return u.value=e},modelValue:u.value,min:1,max:30},null)])})),style:{backgroundColor:"#3325CC"}}})),visibility:function(){return(0,y.Kf)(Z.bought.value)},display:"illuminati"}}});return{id:er,color:e,name:n,points:o,best:t,beep:l,thingy:i,otherThingy:u,spentOnBuyables:a,waffleBoost:f,icecreamCap:c,coolInfo:s,lollipopMilestones:S,funChallenge:N,funEffect:k,generatorUpgrade:V,lollipopMultiplierUpgrade:x,lollipopMultiplierEffect:C,unlockIlluminatiUpgrade:Z,quasiUpgrade:B,exhancers:E,respecBuyables:R,sellExhancer:_,bars:{tallBoi:j,longBoi:U,flatBoi:A},tree:Q,g:W,h:Y,spook:K,conversion:q,reset:z,hotkeys:L,treeNode:G,resetButton:H,confirmRespec:D,minWidth:800,tabs:X,display:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[(0,w.sY)(X),(0,w.sY)(J)])}))}})),or=nr,rr=JSON.parse('{"lifetime":{"min":0.5,"max":1},"ease":[{"s":0,"cp":0.329,"e":0.548},{"s":0.548,"cp":0.767,"e":0.876},{"s":0.876,"cp":0.985,"e":1}],"frequency":0.001,"emitterLifetime":0.1,"maxParticles":100,"addAtBack":true,"pos":{"x":0,"y":0},"emit":false,"behaviors":[{"type":"alpha","config":{"alpha":{"list":[{"time":0,"value":0.74},{"time":1,"value":0}]}}},{"type":"moveSpeed","config":{"speed":{"list":[{"time":0,"value":300},{"time":1,"value":0}]},"minMult":1}},{"type":"scale","config":{"scale":{"list":[{"time":0,"value":1},{"time":1,"value":0.25}]},"minMult":1}},{"type":"color","config":{"color":{"list":[{"time":0,"value":"#ffdfa0"},{"time":1,"value":"#100f0c"}]}}},{"type":"rotation","config":{"accel":0,"minSpeed":0,"maxSpeed":200,"minStart":0,"maxStart":360}},{"type":"textureRandom","config":{"textures":["/particle.png"]}},{"type":"spawnShape","config":{"type":"rect","data":{"x":0,"y":0,"w":0,"h":0}}}]}'),tr="f",lr=(0,B.createLayer)(tr,(function(){var e="#FE0102",n="Farms",o=p(0,"farm points"),t=(0,g.ax)(!1),l=an((function(){return{title:"Lore",titleStyle:{color:"#FE0000"},display:"DEEP LORE!",bodyStyle:{backgroundColor:"#0000EE"}}})),i=(0,g.ax)("Start"),u=Le((function(){return{display:function(){return{title:"Clicky clicky!",description:function(){return"Current state:
"[Symbol.for("+")]?"Current state:
"[Symbol.for("+")](i.value):"Current state:
"+i.value}()}},initialState:"Start",canClick:function(){return function(){return void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!==")]?i.value[Symbol.for("!==")]("Borkened..."):"Borkened..."!==i.value}()},onClick:function(e){switch(i.value){case"Start":i.value="A new state!";break;case"A new state!":i.value="Keep going!";break;case"Keep going!":i.value="Maybe that's a bit too far...";break;case"Maybe that's a bit too far...":var n=function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](void 0):void 0==e}()?void 0:function(){return"touches"[Symbol.for("in")]?"touches"[Symbol.for("in")](e):"touches"in e}()?e.touches[0]:e,o=Object.assign({},rr,{pos:{x:function(){var e,o,r,t,l,i,u,a,f,c,s;return void 0!==(null!==(e=null===n||void 0===n?void 0:n.clientX)&&void 0!==e?e:0)&&null!==(null!==(o=null===n||void 0===n?void 0:n.clientX)&&void 0!==o?o:0)&&(null!==(r=null===n||void 0===n?void 0:n.clientX)&&void 0!==r?r:0)[Symbol.for("-")]?(null!==(t=null===n||void 0===n?void 0:n.clientX)&&void 0!==t?t:0)[Symbol.for("-")](null!==(l=null===(i=v.boundingRect)||void 0===i||null===(u=i.value)||void 0===u?void 0:u.left)&&void 0!==l?l:0):(null!==(a=null===n||void 0===n?void 0:n.clientX)&&void 0!==a?a:0)-(null!==(f=null===(c=v.boundingRect)||void 0===c||null===(s=c.value)||void 0===s?void 0:s.left)&&void 0!==f?f:0)}(),y:function(){var e,o,r,t,l,i,u,a,f,c,s;return void 0!==(null!==(e=null===n||void 0===n?void 0:n.clientY)&&void 0!==e?e:0)&&null!==(null!==(o=null===n||void 0===n?void 0:n.clientY)&&void 0!==o?o:0)&&(null!==(r=null===n||void 0===n?void 0:n.clientY)&&void 0!==r?r:0)[Symbol.for("-")]?(null!==(t=null===n||void 0===n?void 0:n.clientY)&&void 0!==t?t:0)[Symbol.for("-")](null!==(l=null===(i=v.boundingRect)||void 0===i||null===(u=i.value)||void 0===u?void 0:u.top)&&void 0!==l?l:0):(null!==(a=null===n||void 0===n?void 0:n.clientY)&&void 0!==a?a:0)-(null!==(f=null===(c=v.boundingRect)||void 0===c||null===(s=c.value)||void 0===s?void 0:s.top)&&void 0!==f?f:0)}()}});v.addEmitter(o).then((function(e){return e.playOnceAndDestroy()})),i.value="Borkened...";break;default:i.value="Start";break}},onHold:function(){console.log("Clickkkkk...")},style:function(){switch(i.value){case"Start":return{"background-color":"green"};case"A new state!":return{"background-color":"yellow"};case"Keep going!":return{"background-color":"orange"};case"Maybe that's a bit too far...":return{"background-color":"red"};default:return{}}}}})),a=Le((function(){return{onClick:function(){(function(){return void 0!==i.value&&null!==i.value&&i.value[Symbol.for("==")]?i.value[Symbol.for("==")]("Borkened..."):"Borkened..."==i.value})()&&(i.value="Start")},display:function(){return function(){return void 0!==i.value&&null!==i.value&&i.value[Symbol.for("==")]?i.value[Symbol.for("==")]("Borkened..."):"Borkened..."==i.value}()?"Fix the clickable!":"Does nothing"},small:!0}})),f=gn((function(){return{thingsToReset:function(){return[lr]}}})),c=Qe((function(){return{scaling:Ye(10,.5),baseResource:sr.points,gainResource:o,modifyGainAmount:Tn(or.otherThingy)}})),s=He((function(){return{layerID:tr,color:e,reset:f,tooltip:function(){return s.canClick.value?"".concat(M(o)," ").concat(o.displayName):"This weird farmer dinosaur will only see you if you have at least 10 points. You only have ".concat(M(sr.points))},canClick:function(){return b.ZP.gte(sr.points.value,10)}}}));En(s,{display:ae(o),pinnable:!0});var m=Ge((function(){return{conversion:c,tree:sr.tree,treeNode:s,display:(0,y.tZ)((function(){return m.conversion.buyMax?(0,r.createVNode)("span",null,[(0,r.createTextVNode)("Hi! I'm a "),(0,r.createVNode)("u",null,[(0,r.createTextVNode)("weird dinosaur")]),(0,r.createTextVNode)(" and I'll give you")," ",(0,r.createVNode)("b",null,[(0,b.Ht)(m.conversion.currentGain.value)]),(0,r.createTextVNode)(" Farm Points in exchange for all of your points and lollipops! (You'll get another one at")," ",(0,b.Ht)(m.conversion.nextAt.value),(0,r.createTextVNode)(" points)")]):(0,r.createVNode)("span",null,[(0,r.createTextVNode)("Hi! I'm a "),(0,r.createVNode)("u",null,[(0,r.createTextVNode)("weird dinosaur")]),(0,r.createTextVNode)(" and I'll give you a Farm Point in exchange for all of your points and lollipops! (At least")," ",(0,b.Ht)(m.conversion.nextAt.value),(0,r.createTextVNode)(" points)")])}))}})),v=bn((function(){return{boundingRect:(0,r.ref)(null),onContainerResized:function(e){this.boundingRect.value=e},style:"z-index: 2"}})),S=(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[(0,w.sY)(l),(0,r.createVNode)(Pn,{resource:o,color:e},null),(0,w.sY)(m),(0,r.createVNode)("div",null,[(0,r.createTextVNode)("You have "),(0,b.Ht)(c.baseResource.value),(0,r.createTextVNode)(" points")]),(0,r.createVNode)("div",null,[(0,r.createVNode)("br",null,null),(0,r.createVNode)("img",{src:"https://images.beano.com/store/24ab3094eb95e5373bca1ccd6f330d4406db8d1f517fc4170b32e146f80d?auto=compress%2Cformat&dpr=1&w=390"},null),(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Bork Bork!")])]),(0,r.createVNode)(d,null,null),(0,w._4)(a),(0,w._4)(u),(0,w.sY)(v)])}));return{id:tr,color:e,name:n,points:o,boop:t,coolInfo:l,clickable:u,clickableState:i,reset:f,conversion:c,treeNode:s,resetButton:m,minWidth:650,display:S}})),ir=lr;function ur(e){return"function"===typeof e||"[object Object]"===Object.prototype.toString.call(e)&&function(){return void 0!==(0,r.isVNode)(e)&&null!==(0,r.isVNode)(e)&&(0,r.isVNode)(e)[Symbol.for("!")]?(0,r.isVNode)(e)[Symbol.for("!")]():!(0,r.isVNode)(e)}()}var ar="a",fr=(0,B.createLayer)(ar,(function(){var e="yellow",n="Achievements",o=p(0,"achievement power"),t=le((function(){return{display:"A",color:e,tooltip:{display:"Achievements",right:!0},onClick:function(){sr.showAchievements()}}})),l=ke((function(){return{image:"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png",display:"Get me!",tooltip:(0,r.computed)((function(){return l.earned.value?"You did it!":"How did this happen?"})),shouldEarn:function(){return!0}}})),i=ke((function(){return{display:"Impossible!",tooltip:(0,r.computed)((function(){return i.earned.value?"HOW????":"Mwahahaha!"})),style:{color:"#04e050"}}})),u=ke((function(){return{display:"EIEIO",tooltip:"Get a farm point.\n\nReward: The dinosaur is now your friend (you can max Farm Points).",shouldEarn:function(){return b.ZP.gte(ir.points.value,1)},onComplete:function(){console.log("Bork bork bork!")}}})),a=[l,i,u],f=Oe((function(){return{rows:2,cols:2,getStartState:function(e){return e},getStyle:function(e,n){return{backgroundColor:"#".concat(function(){return 1234*Number(n)!==void 0&&1234*Number(n)!==null&&(1234*Number(n))[Symbol.for("%")]?(1234*Number(n))[Symbol.for("%")](999999):1234*Number(n)%999999}())}},getTitle:function(e){var n=this,o="";return"101"===e?o="top":"102"===e?o="bottom":"201"===e?o="left":"202"===e&&(o="right"),(0,y.tZ)((function(){return(0,r.createVNode)(me.Z,(0,r.mergeProps)({display:JSON.stringify(n.cells[e].style)},(0,ce.Z)({},o,!0)),{default:function(){return[(0,r.createVNode)("h3",null,[(0,r.createTextVNode)("Gridable #"),e])]}})}))},getDisplay:function(e,n){return String(n)},getCanClick:function(){return b.ZP.eq(sr.points.value,10)},onClick:function(e,n){this.cells[e].state=function(){return void 0!==Number(n)&&null!==Number(n)&&Number(n)[Symbol.for("+")]?Number(n)[Symbol.for("+")](1):Number(n)+1}()}}})),c=(0,y.tZ)((function(){var e,n,o;return(0,r.createVNode)(r.Fragment,null,[(0,r.createVNode)(se.Z,null,{default:function(){return[(0,r.createVNode)(me.Z,{display:l.tooltip,bottom:!0},ur(e=(0,w.sY)(l))?e:{default:function(){return[e]}}),(0,r.createVNode)(me.Z,{display:i.tooltip,bottom:!0},ur(n=(0,w.sY)(i))?n:{default:function(){return[n]}}),(0,r.createVNode)(me.Z,{display:u.tooltip,bottom:!0},ur(o=(0,w.sY)(u))?o:{default:function(){return[o]}})]}}),(0,w._4)(f)])}));return{id:ar,color:e,name:n,points:o,achievements:a,grid:f,treeNode:t,display:c}})),cr=fr,sr=(0,B.createLayer)("main",(function(){var e=p(10),n=h(e),o=N(e),t=(0,r.computed)((function(){if(function(){return void 0!==or.generatorUpgrade.bought.value&&null!==or.generatorUpgrade.bought.value&&or.generatorUpgrade.bought.value[Symbol.for("!")]?or.generatorUpgrade.bought.value[Symbol.for("!")]():!or.generatorUpgrade.bought.value}())return new b.ZP(0);var e=new b.ZP(3.19);return or.lollipopMultiplierUpgrade.bought.value&&(e=e.times(or.lollipopMultiplierEffect.value)),e}));S.globalBus.on("update",(function(n){e.value=b.ZP.add(e.value,b.ZP.times(t.value,n))}));var l=x(e,t),i=(0,B.setupLayerModal)(cr),u=i.openModal,a=i.modal,f=ie((function(){return{nodes:[[or.treeNode],[ir.treeNode,or.spook]],leftSideNodes:[cr.treeNode,or.h],branches:[{startNode:ir.treeNode,endNode:or.treeNode,stroke:"blue","stroke-width":"25px",style:{filter:"blur(5px)"}}],onReset:function(){e.value=(0,r.toRaw)(this.resettingNode.value)===(0,r.toRaw)(or.treeNode)?0:10,n.value=e.value,o.value=e.value},resetPropagation:ue}}));return{name:"Tree",display:(0,y.tZ)((function(){return(0,r.createVNode)(r.Fragment,null,[0===fe.Z.devSpeed?(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Game Paused")]):null,fe.Z.devSpeed&&function(){return void 0!==fe.Z.devSpeed&&null!==fe.Z.devSpeed&&fe.Z.devSpeed[Symbol.for("!==")]?fe.Z.devSpeed[Symbol.for("!==")](1):1!==fe.Z.devSpeed}()?(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Dev Speed: "),(0,b.WU)(fe.Z.devSpeed),(0,r.createTextVNode)("x")]):null,fe.Z.offlineTime?(0,r.createVNode)("div",null,[(0,r.createTextVNode)("Offline Time: "),(0,b.mr)(fe.Z.offlineTime)]):null,(0,r.createVNode)("div",null,[b.ZP.lt(e.value,"1e1000")?(0,r.createVNode)("span",null,[(0,r.createTextVNode)("You have ")]):null,(0,r.createVNode)("h2",null,[(0,b.WU)(e.value)]),b.ZP.lt(e.value,"1e1e6")?(0,r.createVNode)("span",null,[(0,r.createTextVNode)(" points")]):null]),b.ZP.gt(t.value,0)?(0,r.createVNode)("div",null,[(0,r.createTextVNode)("("),l.value,(0,r.createTextVNode)(")")]):null,(0,r.createVNode)(d,null,null),(0,r.createVNode)("button",{onClick:u},[(0,r.createTextVNode)("open achievements")]),(0,w.sY)(a),(0,w.sY)(f),(0,r.createVNode)(c,{height:"200px",style:"margin: 10px auto; display: block"},null)])})),points:e,best:n,total:o,oomps:l,tree:f,showAchievements:u}})),mr=function(e){return[sr,ir,or,cr]},dr=(0,r.computed)((function(){return b.ZP.gt(sr.points.value,25)}));function yr(e,n){}},9365:function(e,n,o){"use strict";o.r(n),o.d(n,{RegisterNodeInjectionKey:function(){return m},UnregisterNodeInjectionKey:function(){return d},NodesInjectionKey:function(){return y},BoundsInjectionKey:function(){return v},layers:function(){return b},persistentRefs:function(){return S},addingLayers:function(){return g},createLayer:function(){return p},addLayer:function(){return h},getLayer:function(){return N},removeLayer:function(){return k},reloadLayer:function(){return V},setupLayerModal:function(){return x}});var r=o(4865),t=(o(2526),o(1817),o(1539),o(189),o(8783),o(3948),o(8309),o(4747),o(2479),o(6948)),l=o(6113),i=o(9583),u=o(3273),a=o(8111),f=o(7302),c=o(4061),s=o(5967),m=Symbol("RegisterNode"),d=Symbol("UnregisterNode"),y=Symbol("Nodes"),v=Symbol("Bounds"),b=(0,r.shallowReactive)({});window.layers=b;var S={},g=[];function p(e,n){return(0,u.z2)((function(){var o={},t=o.emitter=(0,a.i)();if(o.on=t.on.bind(t),o.emit=t.emit.bind(t),o.nodes=(0,r.ref)({}),o.id=e,g.push(e),S[e]=new Set,o.minimized=(0,c.ax)(!1),Object.assign(o,n.call(o)),function(){return void 0!==g[g.length-1]&&null!==g[g.length-1]&&g[g.length-1][Symbol.for("==")]?g[g.length-1][Symbol.for("==")](null):null==g[g.length-1]}()||function(){return void 0!==g[g.length-1]&&null!==g[g.length-1]&&g[g.length-1][Symbol.for("!==")]?g[g.length-1][Symbol.for("!==")](e):g[g.length-1]!==e}())throw"Adding layers stack in invalid state. This should not happen\nStack: ".concat(g,"\nTrying to pop ").concat(o.id);return g.pop(),(0,i.yB)(o,"color"),(0,i.yB)(o,"display"),(0,i.yB)(o,"name"),(0,l.Rh)(o,"name",o.id),(0,i.yB)(o,"minWidth"),(0,l.Rh)(o,"minWidth",600),(0,i.yB)(o,"minimizable"),(0,l.Rh)(o,"minimizable",!0),o}))}function h(e,n){console.info("Adding layer",e.id),b[e.id]?console.error("Attempted to add layer with same ID as existing layer",e.id,b[e.id]):((0,l.Rh)(n,"layers",{}),function(){return void 0!==n.layers[e.id]&&null!==n.layers[e.id]&&n.layers[e.id][Symbol.for("==")]?n.layers[e.id][Symbol.for("==")](null):null==n.layers[e.id]}()&&(n.layers[e.id]={}),b[e.id]=e,f.globalBus.emit("addLayer",e,n.layers[e.id]))}function N(e){return b[e]}function k(e){console.info("Removing layer",e.id),f.globalBus.emit("removeLayer",e),b[e.id]=void 0}function V(e){k(e),h(e,s.Z)}function x(e){var n=(0,r.ref)(!1);return{openModal:function(){return n.value=!0},modal:(0,l.tZ)((function(){return(0,r.createVNode)(t.Z,{modelValue:n.value,"onUpdate:modelValue":function(e){return n.value=e}},{header:function(){return(0,r.createVNode)("h2",null,[(0,r.unref)(e.name)])},body:(0,r.unref)(e.display)})}))}}f.globalBus.on("update",(function(e){Object.values(b).forEach((function(n){null===n||void 0===n||n.emit("preUpdate",e)})),Object.values(b).forEach((function(n){null===n||void 0===n||n.emit("update",e)})),Object.values(b).forEach((function(n){null===n||void 0===n||n.emit("postUpdate",e)}))}))},1604:function(e,n,o){"use strict";o.d(n,{MM:function(){return c},sY:function(){return s},_4:function(){return m},Dy:function(){return d},qF:function(){return y},RU:function(){return v},ix:function(){return b},vq:function(){return S},KO:function(){return g},o9:function(){return p},Uv:function(){return h},P5:function(){return N}});o(9584);var r=o(3336),t=o(4865),l=(o(2526),o(1817),o(1539),o(3210),o(2222),o(1249),o(7327),o(7042),o(6699),o(2023),o(9905)),i=o(274),u=o(6113),a=o(9583);function f(e){return"function"===typeof e||"[object Object]"===Object.prototype.toString.call(e)&&function(){return void 0!==(0,t.isVNode)(e)&&null!==(0,t.isVNode)(e)&&(0,t.isVNode)(e)[Symbol.for("!")]?(0,t.isVNode)(e)[Symbol.for("!")]():!(0,t.isVNode)(e)}()}function c(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:"span";return"function"===typeof e?(0,t.defineComponent)({render:e}):"string"===typeof e?function(){return void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](0):e.length>0}()?(e=e.trim(),function(){return void 0!==e.charAt(0)&&null!==e.charAt(0)&&e.charAt(0)[Symbol.for("!==")]?e.charAt(0)[Symbol.for("!==")]("<"):"<"!==e.charAt(0)}()&&(e="<".concat(o,">").concat(e,"")),(0,t.defineComponent)({template:e})):(0,t.defineComponent)({render:function(){return{}}}):e}function s(e){if(v(e))return"function"===typeof e?e():c(e);var n=e[u.wA];return(0,t.createVNode)(n,e[u.tj](),null)}function m(){for(var e,n=arguments.length,o=new Array(n),l=0;function(){return void 0!==l&&null!==l&&l[Symbol.for("<")]?l[Symbol.for("<")](n):l")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:"div",r=(0,t.shallowRef)();return(0,t.watchEffect)((function(){r.value=c(h(e),o)})),r}function g(e){var n=arguments,o=function(){return void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](1):n.length>1}()&&function(){return void 0!==n[1]&&null!==n[1]&&n[1][Symbol.for("!==")]?n[1][Symbol.for("!==")](void 0):void 0!==n[1]}()?arguments[1]:"div",r=(0,t.shallowRef)(null);return(0,t.watchEffect)((function(){var n=h(e);r.value=function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()?null:c(n,o)})),r}function p(e){return(0,t.computed)((function(){return h(e)}))}function h(e){return(0,t.unref)((0,t.unref)(e))}function N(){for(var e=arguments.length,n=new Array(e),o=0;function(){return void 0!==o&&null!==o&&o[Symbol.for("<")]?o[Symbol.for("<")](e):o","span")})),a=(0,r.computed)({get:function(){return function(){return void 0!==!i.modelValue&&null!==!i.modelValue&&(!i.modelValue)[Symbol.for("!")]?(!i.modelValue)[Symbol.for("!")]():!!i.modelValue}()},set:function(e){o("update:modelValue",e)}});return function(e,n){return(0,r.openBlock)(),(0,r.createElementBlock)("label",l,[(0,r.withDirectives)((0,r.createElementVNode)("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":n[0]||(n[0]=function(e){return(0,r.isRef)(a)?a.value=e:null})},null,512),[[r.vModelCheckbox,(0,r.unref)(a)]]),((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)((0,r.unref)(u))))])}}}),u=o(3744);const a=(0,u.Z)(i,[["__scopeId","data-v-43cf95d0"]]);var f=a},9905:function(e,n,o){"use strict";o.d(n,{Z:function(){return f}});var r=o(4865),t=o(1037),l=o(9266),i={class:"table"},u=(0,r.defineComponent)({setup:function(e){var n=(0,r.computed)((function(){return t.Z[l.ZP.theme].mergeAdjacent}));return function(e,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["col",{mergeAdjacent:(0,r.unref)(n)}])},[(0,r.renderSlot)(e.$slots,"default")],2)])}}});const a=u;var f=a},274:function(e,n,o){"use strict";o.d(n,{Z:function(){return f}});var r=o(4865),t=o(1037),l=o(9266),i={class:"table"},u=(0,r.defineComponent)({setup:function(e){var n=(0,r.computed)((function(){return t.Z[l.ZP.theme].mergeAdjacent}));return function(e,o){return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["row",{mergeAdjacent:(0,r.unref)(n)}])},[(0,r.renderSlot)(e.$slots,"default")],2)])}}});const a=u;var f=a},6055:function(e,n,o){"use strict";o.d(n,{Z:function(){return v}});var r=o(5082),t=(o(2526),o(1817),o(1539),o(4865)),l={key:0,class:"material-icons pinned"};function i(e,n,o,i,u,a){return(0,t.openBlock)(),(0,t.createElementBlock)("div",{class:(0,t.normalizeClass)(["tooltip-container",{shown:e.isShown}]),onMouseenter:n[0]||(n[0]=function(n){return e.isHovered=!0}),onMouseleave:n[1]||(n[1]=function(n){return e.isHovered=!1}),onClickCapture:n[2]||(n[2]=function(){return e.togglePinned&&e.togglePinned.apply(e,arguments)})},[(0,t.renderSlot)(e.$slots,"default",{},void 0,!0),e.elementComp?((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)(e.elementComp),{key:0})):(0,t.createCommentVNode)("",!0),(0,t.createVNode)(t.Transition,{name:"fade"},{default:(0,t.withCtx)((function(){var n;return[e.isShown?((0,t.openBlock)(),(0,t.createElementBlock)("div",{key:0,class:(0,t.normalizeClass)(["tooltip",(0,r.Z)({top:e.unref(e.direction)===e.Direction.Up,left:e.unref(e.direction)===e.Direction.Left,right:e.unref(e.direction)===e.Direction.Right,bottom:e.unref(e.direction)===e.Direction.Down},e.unref(e.classes))]),style:(0,t.normalizeStyle)([{"--xoffset":e.unref(e.xoffset)||"0px","--yoffset":e.unref(e.yoffset)||"0px"},function(){return void 0!==(n=e.unref(e.style))&&null!==(n=e.unref(e.style))&&(n=e.unref(e.style))[Symbol.for("!==")]?(n=e.unref(e.style))[Symbol.for("!==")](null):null!==(n=e.unref(e.style))}()&&function(){return void 0!==n&&null!==n&&n[Symbol.for("!==")]?n[Symbol.for("!==")](void 0):void 0!==n}()?n:{}])},[e.showPin?((0,t.openBlock)(),(0,t.createElementBlock)("span",l,"push_pin")):(0,t.createCommentVNode)("",!0),e.comp?((0,t.openBlock)(),(0,t.createBlock)((0,t.resolveDynamicComponent)(e.comp),{key:1})):(0,t.createCommentVNode)("",!0)],6)):(0,t.createCommentVNode)("",!0)]})),_:1})],34)}var u=o(1037),a=o(6113),f=o(9266),c=o(1349),s=o(1604),m=(0,t.defineComponent)({props:{element:(0,s.P5)(Object),display:{type:(0,s.P5)(Object,String,Function),required:!0},style:(0,s.P5)(Object,String,Array),classes:(0,s.P5)(Object),direction:(0,s.P5)(String),xoffset:(0,s.P5)(String),yoffset:(0,s.P5)(String),pinned:Object},setup:function(e){var n=(0,t.toRefs)(e),o=n.element,r=n.display,l=n.pinned,i=(0,t.ref)(!1),m=(0,t.computed)((function(){return((0,s.Uv)(l)||i.value)&&d.value})),d=(0,s.KO)(r),y=(0,t.shallowRef)(null);function v(e){var n=l;e.shiftKey&&n&&(n.value=function(){return void 0!==n.value&&null!==n.value&&n.value[Symbol.for("!")]?n.value[Symbol.for("!")]():!n.value}(),e.stopPropagation(),e.preventDefault())}(0,t.watchEffect)((function(){var e=(0,s.Uv)(o);y.value=function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e}()?null:(0,s.MM)((0,a.tZ)((function(){return(0,s.sY)(e)})))}));var b=(0,t.computed)((function(){return(0,s.Uv)(l)&&u.Z[f.ZP.theme].showPin}));return{Direction:c.Nm,isHovered:i,isShown:m,comp:d,elementComp:y,unref:t.unref,togglePinned:v,showPin:b}}}),d=o(3744);const y=(0,d.Z)(m,[["render",i],["__scopeId","data-v-e03bc918"]]);var v=y},7634:function(e){function n(e){var n=new Error("Cannot find module '"+e+"'");throw n.code="MODULE_NOT_FOUND",n}n.keys=function(){return[]},n.resolve=n,n.id=7634,e.exports=n},6453:function(e){"use strict";e.exports=JSON.parse('{"title":"Profectus","id":"profectus-demo","author":"thepaperpilot","discordName":"The Paper Pilot Community","discordLink":"https://discord.gg/WzejVAx","versionNumber":"0.0","versionTitle":"Initial Commit","allowGoBack":true,"defaultShowSmall":false,"defaultDecimalsShown":2,"useHeader":true,"banner":null,"logo":"Logo.png","initialTabs":["main","c"],"maxTickLength":3600,"offlineLimit":1,"enablePausing":true,"exportEncoding":"base64"}')}},n={};function o(r){var t=n[r];if(void 0!==t)return t.exports;var l=n[r]={id:r,loaded:!1,exports:{}};return e[r].call(l.exports,l,l.exports,o),l.loaded=!0,l.exports}o.m=e,function(){var e=[];o.O=function(n,r,t,l){if(!r){var i=1/0;for(c=0;c=l)&&Object.keys(o.O).every((function(e){return o.O[e](r[a])}))?r.splice(a--,1):(u=!1,l0&&e[c-1][2]>l;c--)e[c]=e[c-1];e[c]=[r,t,l]}}(),function(){o.n=function(e){var n=e&&e.__esModule?function(){return e["default"]}:function(){return e};return o.d(n,{a:n}),n}}(),function(){o.d=function(e,n){for(var r in n)o.o(n,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})}}(),function(){o.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}()}(),function(){o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)}}(),function(){o.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}}(),function(){o.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e}}(),function(){var e={143:0};o.O.j=function(n){return 0===e[n]};var n=function(n,r){var t,l,i=r[0],u=r[1],a=r[2],f=0;if(i.some((function(n){return 0!==e[n]}))){for(t in u)o.o(u,t)&&(o.m[t]=u[t]);if(a)var c=a(o)}for(n&&n(r);f {}\n}\n\nconst defaultTheme: Theme = {\n variables: {\n \"--foreground\": \"#dfdfdf\",\n \"--background\": \"#0f0f0f\",\n \"--feature-foreground\": \"#0f0f0f\",\n \"--tooltip-background\": \"rgba(0, 0, 0, 0.75)\",\n \"--raised-background\": \"#0f0f0f\",\n \"--points\": \"#ffffff\",\n \"--locked\": \"#bf8f8f\",\n \"--highlighted\": \"#333\",\n \"--bought\": \"#77bf5f\",\n \"--danger\": \"rgb(220, 53, 69)\",\n \"--link\": \"#02f2f2\",\n \"--outline\": \"#dfdfdf\",\n \"--accent1\": \"#627a82\",\n \"--accent2\": \"#658262\",\n \"--accent3\": \"#7c6282\",\n\n \"--border-radius\": \"15px\",\n \"--modal-border\": \"solid 2px var(--color)\",\n \"--feature-margin\": \"0px\"\n },\n floatingTabs: true,\n mergeAdjacent: true,\n showPin: true\n};\n\nexport enum Themes {\n Classic = \"classic\",\n Paper = \"paper\",\n Nordic = \"nordic\",\n Aqua = \"aqua\"\n}\n\nexport default {\n classic: defaultTheme,\n paper: {\n ...defaultTheme,\n variables: {\n ...defaultTheme.variables,\n \"--background\": \"#2a323d\",\n \"--feature-foreground\": \"#000\",\n \"--raised-background\": \"#333c4a\",\n \"--locked\": \"#3a3e45\",\n \"--bought\": \"#5C8A58\",\n \"--outline\": \"#333c4a\",\n \"--border-radius\": \"4px\",\n \"--modal-border\": \"\",\n \"--feature-margin\": \"5px\"\n },\n floatingTabs: false\n } as Theme,\n // Based on https://www.nordtheme.com\n nordic: {\n ...defaultTheme,\n variables: {\n ...defaultTheme.variables,\n \"--foreground\": \"#D8DEE9\",\n \"--background\": \"#2E3440\",\n \"--feature-foreground\": \"#000\",\n \"--raised-background\": \"#3B4252\",\n \"--points\": \"#E5E9F0\",\n \"--locked\": \"#4c566a\",\n \"--highlighted\": \"#434c5e\",\n \"--bought\": \"#8FBCBB\",\n \"--danger\": \"#D08770\",\n \"--link\": \"#88C0D0\",\n \"--outline\": \"#3B4252\",\n \"--accent1\": \"#B48EAD\",\n \"--accent2\": \"#A3BE8C\",\n \"--accent3\": \"#EBCB8B\",\n \"--border-radius\": \"4px\",\n \"--modal-border\": \"solid 2px #3B4252\",\n \"--feature-margin\": \"5px\"\n },\n floatingTabs: false\n } as Theme,\n aqua: {\n ...defaultTheme,\n variables: {\n ...defaultTheme.variables,\n \"--foreground\": \"#bfdfff\",\n \"--background\": \"#001f3f\",\n \"--tooltip-background\": \"rgba(0, 15, 31, 0.75)\",\n \"--raised-background\": \"#001f3f\",\n \"--points\": \"#dfefff\",\n \"--locked\": \"#c4a7b3\",\n \"--outline\": \"#bfdfff\"\n }\n } as Theme\n} as Record;\n","import Decimal from \"util/bignum\";\nimport { DoNotCache } from \"util/computed\";\nimport { CSSProperties, DefineComponent, isRef } from \"vue\";\n\n/**\n * A symbol to use as a key for a vue component a feature can be rendered with\n * @see {@link VueFeature}\n */\nexport const Component = Symbol(\"Component\");\n/**\n * A symbol to use as a key for a prop gathering function that a feature can use to send to its component\n * @see {@link VueFeature}\n */\nexport const GatherProps = Symbol(\"GatherProps\");\n\n/**\n * A type referring to a function that returns JSX and is marked that it shouldn't be wrapped in a ComputedRef\n * @see {@link jsx}\n */\nexport type JSXFunction = (() => JSX.Element) & { [DoNotCache]: true };\n/**\n * Any value that can be coerced into (or is) a vue component\n */\nexport type CoercableComponent = string | DefineComponent | JSXFunction;\n/**\n * Any value that can be passed into an HTML element's style attribute.\n * Note that Profectus uses its own StyleValue and CSSProperties that are extended,\n * in order to have additional properties added to them, such as variable CSS variables.\n */\nexport type StyleValue = string | CSSProperties | Array;\n\n/** A type that refers to any vue component */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport type GenericComponent = DefineComponent;\n\n/** Utility type that is S, with any properties from T that aren't already present in S */\nexport type Replace = S & Omit;\n\n/**\n * Utility function for a function that returns an object of a given type,\n * with \"this\" bound to what the type will eventually be processed into.\n * Intended for making lazily evaluated objects.\n */\nexport type OptionsFunc> = () => T & ThisType & Partial;\n\nlet id = 0;\n/**\n * Gets a unique ID to give to each feature, used for any sort of system that needs to identify\n * elements in the DOM rather than references to the feature itself. (For example, branches)\n * IDs are guaranteed unique, but _NOT_ persistent - they likely will change between updates.\n * @param prefix A string to prepend to the id to make it more readable in the inspector tools\n */\nexport function getUniqueID(prefix = \"feature-\"): string {\n return prefix + id++;\n}\n\n/** Enum for what the visibility of a feature or component should be */\nexport enum Visibility {\n /** The feature or component should be visible */\n Visible,\n /** The feature or component should not appear but still take up space */\n Hidden,\n /** The feature or component should not appear not take up space */\n None\n}\n\n/**\n * Takes a function and marks it as JSX so it won't get auto-wrapped into a ComputedRef.\n * The function may also return empty string as empty JSX tags cause issues.\n */\nexport function jsx(func: () => JSX.Element | \"\"): JSXFunction {\n (func as Partial)[DoNotCache] = true;\n return func as JSXFunction;\n}\n\n/** Utility function to convert a boolean value into a Visbility value */\nexport function showIf(condition: boolean, otherwise = Visibility.None): Visibility {\n return condition ? Visibility.Visible : otherwise;\n}\n\n/** Utility function to set a property on an object if and only if it doesn't already exist */\nexport function setDefault(\n object: T,\n key: K,\n value: T[K]\n): asserts object is Exclude & Required> {\n if (object[key] === undefined && value != undefined) {\n object[key] = value;\n }\n}\n\n/**\n * Traverses an object and returns all features of the given type(s)\n * @param obj The object to traverse\n * @param types The feature types that will be searched for\n */\nexport function findFeatures(obj: Record, ...types: symbol[]): unknown[] {\n const objects: unknown[] = [];\n const handleObject = (obj: Record) => {\n Object.keys(obj).forEach(key => {\n const value = obj[key];\n if (value && typeof value === \"object\") {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (types.includes((value as Record).type)) {\n objects.push(value);\n } else if (!(value instanceof Decimal) && !isRef(value)) {\n handleObject(value as Record);\n }\n }\n });\n };\n handleObject(obj);\n return objects;\n}\n\n/**\n * Traverses an object and returns all features that are _not_ any of the given types.\n * Features are any object with a \"type\" property that has a symbol value.\n * @param obj The object to traverse\n * @param types The feature types that will be skipped over\n */\nexport function excludeFeatures(obj: Record, ...types: symbol[]): unknown[] {\n const objects: unknown[] = [];\n const handleObject = (obj: Record) => {\n Object.keys(obj).forEach(key => {\n const value = obj[key];\n if (value && typeof value === \"object\") {\n if (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n typeof (value as Record).type == \"symbol\" &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !types.includes((value as Record).type)\n ) {\n objects.push(value);\n } else if (!(value instanceof Decimal) && !isRef(value)) {\n handleObject(value as Record);\n }\n }\n });\n };\n handleObject(obj);\n return objects;\n}\n","import projInfo from \"data/projInfo.json\";\nimport Decimal from \"util/bignum\";\nimport { createNanoEvents } from \"nanoevents\";\nimport { App, Ref, watch } from \"vue\";\nimport { GenericLayer } from \"./layers\";\nimport player from \"./player\";\nimport settings, { Settings } from \"./settings\";\nimport state from \"./state\";\n\nexport interface GlobalEvents {\n addLayer: (layer: GenericLayer, saveData: Record) => void;\n removeLayer: (layer: GenericLayer) => void;\n update: (diff: number, trueDiff: number) => void;\n loadSettings: (settings: Partial) => void;\n gameWon: VoidFunction;\n setupVue: (vue: App) => void;\n}\n\nexport const globalBus = createNanoEvents();\n\nlet intervalID: number | null = null;\n\n// Not imported immediately due to dependency cycles\n// This gets set during startGameLoop(), and will only be used in the update function\nlet hasWon: null | Ref = null;\n\nfunction update() {\n const now = Date.now();\n let diff = (now - player.time) / 1e3;\n player.time = now;\n const trueDiff = diff;\n\n state.lastTenTicks.push(trueDiff);\n if (state.lastTenTicks.length > 10) {\n state.lastTenTicks = state.lastTenTicks.slice(1);\n }\n\n // Stop here if the game is paused on the win screen\n if (hasWon?.value && !player.keepGoing) {\n return;\n }\n // Stop here if the player had a NaN value\n if (state.hasNaN) {\n return;\n }\n\n diff = Math.max(diff, 0);\n\n if (player.devSpeed === 0) {\n return;\n }\n\n // Add offline time if any\n if (player.offlineTime != undefined) {\n if (Decimal.gt(player.offlineTime, projInfo.offlineLimit * 3600)) {\n player.offlineTime = projInfo.offlineLimit * 3600;\n }\n if (Decimal.gt(player.offlineTime, 0) && player.devSpeed !== 0) {\n const offlineDiff = Math.max(player.offlineTime / 10, diff);\n player.offlineTime = player.offlineTime - offlineDiff;\n diff += offlineDiff;\n } else if (player.devSpeed === 0) {\n player.offlineTime += diff;\n }\n if (!player.offlineProd || Decimal.lt(player.offlineTime, 0)) {\n player.offlineTime = null;\n }\n }\n\n // Cap at max tick length\n diff = Math.min(diff, projInfo.maxTickLength);\n\n // Apply dev speed\n if (player.devSpeed != undefined) {\n diff *= player.devSpeed;\n }\n\n if (!Number.isFinite(diff)) {\n diff = 1e308;\n }\n\n // Update\n if (Decimal.eq(diff, 0)) {\n return;\n }\n\n player.timePlayed += diff;\n if (!Number.isFinite(player.timePlayed)) {\n player.timePlayed = 1e308;\n }\n globalBus.emit(\"update\", diff, trueDiff);\n\n if (settings.unthrottled) {\n requestAnimationFrame(update);\n if (intervalID != null) {\n clearInterval(intervalID);\n intervalID = null;\n }\n } else if (intervalID == null) {\n intervalID = setInterval(update, 50);\n }\n}\n\nexport async function startGameLoop() {\n hasWon = (await import(\"data/projEntry\")).hasWon;\n watch(hasWon, hasWon => {\n if (hasWon) {\n globalBus.emit(\"gameWon\");\n }\n });\n if (settings.unthrottled) {\n requestAnimationFrame(update);\n } else {\n intervalID = setInterval(update, 50);\n }\n}\n","import { globalBus } from \"game/events\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { ProxyState } from \"util/proxies\";\nimport { isArray } from \"@vue/shared\";\nimport { isReactive, isRef, Ref, ref } from \"vue\";\nimport { addingLayers, GenericLayer, persistentRefs } from \"./layers\";\n\nexport const PersistentState = Symbol(\"PersistentState\");\nexport const DefaultValue = Symbol(\"DefaultValue\");\nexport const StackTrace = Symbol(\"StackTrace\");\nexport const Deleted = Symbol(\"Deleted\");\n\n// Note: This is a union of things that should be safely stringifiable without needing\n// special processes for knowing what to load them in as\n// - Decimals aren't allowed because we'd need to know to parse them back.\n// - DecimalSources are allowed because the string is a valid value for them\nexport type State =\n | string\n | number\n | boolean\n | DecimalSource\n | { [key: string]: State }\n | { [key: number]: State };\n\nexport type Persistent = Ref & {\n [PersistentState]: Ref;\n [DefaultValue]: T;\n [StackTrace]: string;\n [Deleted]: boolean;\n};\n\nfunction getStackTrace() {\n return (\n new Error().stack\n ?.split(\"\\n\")\n .slice(3, 5)\n .map(line => line.trim())\n .join(\"\\n\") || \"\"\n );\n}\n\nexport function persistent(defaultValue: T | Ref): Persistent {\n const persistent = (\n isRef(defaultValue) ? defaultValue : (ref(defaultValue) as unknown)\n ) as Persistent;\n\n persistent[PersistentState] = persistent;\n persistent[DefaultValue] = isRef(defaultValue) ? defaultValue.value : defaultValue;\n persistent[StackTrace] = getStackTrace();\n persistent[Deleted] = false;\n\n if (addingLayers.length === 0) {\n console.warn(\n \"Creating a persistent ref outside of a layer. This is not officially supported\",\n persistent,\n \"\\nCreated at:\\n\" + persistent[StackTrace]\n );\n } else {\n persistentRefs[addingLayers[addingLayers.length - 1]].add(persistent);\n }\n\n return persistent as Persistent;\n}\n\nexport function deletePersistent(persistent: Persistent) {\n if (addingLayers.length === 0) {\n console.warn(\"Deleting a persistent ref outside of a layer. Ignoring...\", persistent);\n } else {\n persistentRefs[addingLayers[addingLayers.length - 1]].delete(persistent);\n }\n persistent[Deleted] = true;\n}\n\nglobalBus.on(\"addLayer\", (layer: GenericLayer, saveData: Record) => {\n const features: { type: typeof Symbol }[] = [];\n const handleObject = (obj: Record, path: string[] = []): boolean => {\n let foundPersistent = false;\n Object.keys(obj).forEach(key => {\n const value = obj[key];\n if (value && typeof value === \"object\") {\n if (PersistentState in value) {\n foundPersistent = true;\n if ((value as Persistent)[Deleted]) {\n console.warn(\n \"Deleted persistent ref present in returned object. Ignoring...\",\n value,\n \"\\nCreated at:\\n\" + (value as Persistent)[StackTrace]\n );\n return;\n }\n persistentRefs[layer.id].delete(\n ProxyState in value\n ? // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ((value as any)[ProxyState] as Persistent)\n : (value as Persistent)\n );\n\n // Construct save path if it doesn't exist\n const persistentState = path.reduce>((acc, curr) => {\n if (!(curr in acc)) {\n acc[curr] = {};\n }\n return acc[curr] as Record;\n }, saveData);\n\n // Cache currently saved value\n const savedValue = persistentState[key];\n // Add ref to save data\n persistentState[key] = (value as Persistent)[PersistentState];\n // Load previously saved value\n if (isReactive(persistentState)) {\n if (savedValue != null) {\n persistentState[key] = savedValue;\n } else {\n persistentState[key] = (value as Persistent)[DefaultValue];\n }\n } else {\n if (savedValue != null) {\n (persistentState[key] as Ref).value = savedValue;\n } else {\n (persistentState[key] as Ref).value = (value as Persistent)[\n DefaultValue\n ];\n }\n }\n } else if (\n !(value instanceof Decimal) &&\n !isRef(value) &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !features.includes(value as { type: typeof Symbol })\n ) {\n if (typeof (value as { type: typeof Symbol }).type === \"symbol\") {\n features.push(value as { type: typeof Symbol });\n }\n\n // Continue traversing\n const foundPersistentInChild = handleObject(value as Record, [\n ...path,\n key\n ]);\n\n // Show warning for persistent values inside arrays\n // TODO handle arrays better\n if (foundPersistentInChild) {\n if (isArray(value) && !isArray(obj)) {\n console.warn(\n \"Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.\",\n ProxyState in obj\n ? (obj as Record)[ProxyState]\n : obj,\n key\n );\n } else {\n foundPersistent = true;\n }\n }\n }\n }\n });\n return foundPersistent;\n };\n handleObject(layer);\n persistentRefs[layer.id].forEach(persistent => {\n console.error(\n `Created persistent ref in ${layer.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,\n persistent,\n \"\\nCreated at:\\n\" + persistent[StackTrace]\n );\n });\n persistentRefs[layer.id].clear();\n});\n","import Decimal from \"util/bignum\";\nimport { isPlainObject } from \"util/common\";\nimport { ProxiedWithState, ProxyPath, ProxyState } from \"util/proxies\";\nimport { reactive, unref } from \"vue\";\nimport transientState from \"./state\";\n\nexport interface PlayerData {\n id: string;\n devSpeed: number | null;\n name: string;\n tabs: Array;\n time: number;\n autosave: boolean;\n offlineProd: boolean;\n offlineTime: number | null;\n timePlayed: number;\n keepGoing: boolean;\n modID: string;\n modVersion: string;\n layers: Record>;\n}\n\nexport type Player = ProxiedWithState;\n\nconst state = reactive({\n id: \"\",\n devSpeed: null,\n name: \"\",\n tabs: [],\n time: -1,\n autosave: true,\n offlineProd: true,\n offlineTime: null,\n timePlayed: 0,\n keepGoing: false,\n modID: \"\",\n modVersion: \"\",\n layers: {}\n});\n\nexport function stringifySave(player: PlayerData): string {\n return JSON.stringify(player, (key, value) => unref(value));\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst playerHandler: ProxyHandler> = {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get(target: Record, key: PropertyKey): any {\n if (key === ProxyState || key === ProxyPath) {\n return target[key];\n }\n\n const value = target[ProxyState][key];\n if (\n key !== \"value\" &&\n (isPlainObject(value) || Array.isArray(value)) &&\n !(value instanceof Decimal)\n ) {\n if (value !== target[key]?.[ProxyState]) {\n const path = [...target[ProxyPath], key];\n target[key] = new Proxy({ [ProxyState]: value, [ProxyPath]: path }, playerHandler);\n }\n return target[key];\n }\n\n return value;\n },\n set(\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n target: Record,\n property: PropertyKey,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n value: any,\n receiver: ProxyConstructor\n ): boolean {\n if (\n !transientState.hasNaN &&\n ((typeof value === \"number\" && isNaN(value)) ||\n (value instanceof Decimal &&\n (isNaN(value.sign) || isNaN(value.layer) || isNaN(value.mag))))\n ) {\n const currentValue = target[ProxyState][property];\n if (\n !(\n (typeof currentValue === \"number\" && isNaN(currentValue)) ||\n (currentValue instanceof Decimal &&\n (isNaN(currentValue.sign) ||\n isNaN(currentValue.layer) ||\n isNaN(currentValue.mag)))\n )\n ) {\n state.autosave = false;\n transientState.hasNaN = true;\n transientState.NaNPath = [...target[ProxyPath], property];\n transientState.NaNReceiver = receiver as unknown as Record;\n console.error(\n `Attempted to set NaN value`,\n [...target[ProxyPath], property],\n target[ProxyState]\n );\n throw \"Attempted to set NaN value. See above for details\";\n }\n }\n target[ProxyState][property] = value;\n return true;\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ownKeys(target: Record) {\n return Reflect.ownKeys(target[ProxyState]);\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n has(target: Record, key: string) {\n return Reflect.has(target[ProxyState], key);\n },\n getOwnPropertyDescriptor(target, key) {\n return Object.getOwnPropertyDescriptor(target[ProxyState], key);\n }\n};\nexport default window.player = new Proxy(\n { [ProxyState]: state, [ProxyPath]: [\"player\"] },\n playerHandler\n) as Player;\n","import projInfo from \"data/projInfo.json\";\nimport { Themes } from \"data/themes\";\nimport { CoercableComponent } from \"features/feature\";\nimport { globalBus } from \"game/events\";\nimport LZString from \"lz-string\";\nimport { hardReset } from \"util/save\";\nimport { reactive, watch } from \"vue\";\n\nexport interface Settings {\n active: string;\n saves: string[];\n showTPS: boolean;\n theme: Themes;\n unthrottled: boolean;\n}\n\nconst state = reactive>({\n active: \"\",\n saves: [],\n showTPS: true,\n theme: Themes.Nordic,\n unthrottled: false\n});\n\nwatch(\n state,\n state => {\n const stringifiedSettings = LZString.compressToUTF16(JSON.stringify(state));\n localStorage.setItem(projInfo.id, stringifiedSettings);\n },\n { deep: true }\n);\nexport default window.settings = state as Settings;\n\nexport function loadSettings(): void {\n try {\n let item: string | null = localStorage.getItem(projInfo.id);\n if (item != null && item !== \"\") {\n if (item[0] === \"{\") {\n // plaintext. No processing needed\n } else if (item[0] === \"e\") {\n // Assumed to be base64, which starts with e\n item = decodeURIComponent(escape(atob(item)));\n } else if (item[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n item = LZString.decompressFromUTF16(item)!;\n } else {\n console.warn(\"Unable to determine settings encoding\", item);\n return;\n }\n const settings = JSON.parse(item);\n if (typeof settings === \"object\") {\n Object.assign(state, settings);\n }\n }\n globalBus.emit(\"loadSettings\", state);\n // eslint-disable-next-line no-empty\n } catch {}\n}\n\nexport const hardResetSettings = (window.hardResetSettings = () => {\n const settings = {\n active: \"\",\n saves: [],\n showTPS: true,\n theme: Themes.Nordic\n };\n globalBus.emit(\"loadSettings\", settings);\n Object.assign(state, settings);\n hardReset();\n});\n\nexport const settingFields: CoercableComponent[] = reactive([]);\nexport function registerSettingField(component: CoercableComponent) {\n settingFields.push(component);\n}\n\nexport const infoComponents: CoercableComponent[] = reactive([]);\nexport function registerInfoComponent(component: CoercableComponent) {\n infoComponents.push(component);\n}\n\nexport const gameComponents: CoercableComponent[] = reactive([]);\nexport function registerGameComponent(component: CoercableComponent) {\n gameComponents.push(component);\n}\n","import { shallowReactive } from \"vue\";\n\nexport interface Transient {\n lastTenTicks: number[];\n hasNaN: boolean;\n NaNPath?: string[];\n NaNReceiver?: Record;\n}\n\nexport default window.state = shallowReactive({\n lastTenTicks: [],\n hasNaN: false,\n NaNPath: []\n});\n","import { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, resolveComponent as _resolveComponent, withCtx as _withCtx, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Context = _resolveComponent(\"Context\")!\n\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"layer-container\",\n style: _normalizeStyle({ '--layer-color': _ctx.unref(_ctx.color) })\n }, [\n (_ctx.showGoBack)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n class: \"goBack\",\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.goBack && _ctx.goBack(...args)))\n }, \"←\"))\n : _createCommentVNode(\"\", true),\n (_ctx.minimized.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 1,\n class: \"layer-tab minimized\",\n onClick: _cache[1] || (_cache[1] = ($event: any) => (_ctx.minimized.value = false))\n }, [\n _createElementVNode(\"div\", null, _toDisplayString(_ctx.unref(_ctx.name)), 1)\n ]))\n : (_openBlock(), _createElementBlock(\"div\", {\n key: 2,\n class: _normalizeClass([\"layer-tab\", { showGoBack: _ctx.showGoBack }])\n }, [\n _createVNode(_component_Context, { onUpdateNodes: _ctx.updateNodes }, {\n default: _withCtx(() => [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component)))\n ]),\n _: 1\n }, 8, [\"onUpdateNodes\"])\n ], 2)),\n (_ctx.unref(_ctx.minimizable))\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 3,\n class: \"minimize\",\n onClick: _cache[2] || (_cache[2] = ($event: any) => (_ctx.minimized.value = true))\n }, \" ▼ \"))\n : _createCommentVNode(\"\", true)\n ], 4))\n}","\nimport projInfo from \"data/projInfo.json\";\nimport { CoercableComponent } from \"features/feature\";\nimport { FeatureNode } from \"game/layers\";\nimport { Persistent } from \"game/persistence\";\nimport player from \"game/player\";\nimport { computeComponent, processedPropType, wrapRef } from \"util/vue\";\nimport { computed, defineComponent, nextTick, PropType, Ref, toRefs, unref, watch } from \"vue\";\nimport Context from \"./Context.vue\";\n\nexport default defineComponent({\n components: { Context },\n props: {\n index: {\n type: Number,\n required: true\n },\n tab: {\n type: Function as PropType<() => HTMLElement | undefined>,\n required: true\n },\n display: {\n type: processedPropType(Object, String, Function),\n required: true\n },\n minimized: {\n type: Object as PropType>,\n required: true\n },\n minWidth: {\n type: processedPropType(Number, String),\n required: true\n },\n name: {\n type: processedPropType(String),\n required: true\n },\n color: processedPropType(String),\n minimizable: processedPropType(Boolean),\n nodes: {\n type: Object as PropType>>,\n required: true\n }\n },\n setup(props) {\n const { display, index, minimized, minWidth, tab } = toRefs(props);\n\n const component = computeComponent(display);\n const showGoBack = computed(\n () => projInfo.allowGoBack && index.value > 0 && !minimized.value\n );\n\n function goBack() {\n player.tabs.splice(unref(props.index), Infinity);\n }\n\n nextTick(() => updateTab(minimized.value, unref(minWidth.value)));\n watch([minimized, wrapRef(minWidth)], ([minimized, minWidth]) =>\n updateTab(minimized, minWidth)\n );\n\n function updateNodes(nodes: Record) {\n props.nodes.value = nodes;\n }\n\n function updateTab(minimized: boolean, minWidth: number | string) {\n const width =\n typeof minWidth === \"number\" || Number.isNaN(parseInt(minWidth))\n ? minWidth + \"px\"\n : minWidth;\n const tabValue = tab.value();\n if (tabValue != undefined) {\n if (minimized) {\n tabValue.style.flexGrow = \"0\";\n tabValue.style.flexShrink = \"0\";\n tabValue.style.width = \"60px\";\n tabValue.style.minWidth = tabValue.style.flexBasis = \"\";\n tabValue.style.margin = \"0\";\n } else {\n tabValue.style.flexGrow = \"\";\n tabValue.style.flexShrink = \"\";\n tabValue.style.width = \"\";\n tabValue.style.minWidth = tabValue.style.flexBasis = width;\n tabValue.style.margin = \"\";\n }\n }\n }\n\n return {\n component,\n showGoBack,\n updateNodes,\n unref,\n goBack\n };\n }\n});\n","import { render } from \"./Layer.vue?vue&type=template&id=e18f60b6&scoped=true&ts=true\"\nimport script from \"./Layer.vue?vue&type=script&lang=ts\"\nexport * from \"./Layer.vue?vue&type=script&lang=ts\"\n\nimport \"./Layer.vue?vue&type=style&index=0&id=e18f60b6&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e18f60b6\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { createElementVNode as _createElementVNode, createTextVNode as _createTextVNode, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5f8298e6\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"h2\", null, \"Changelog\", -1))\nconst _hoisted_2 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"details\", { open: \"\" }, [\n /*#__PURE__*/_createElementVNode(\"summary\", null, [\n /*#__PURE__*/_createTextVNode(\"v0.0 Initial Commit - \"),\n /*#__PURE__*/_createElementVNode(\"time\", null, \"2021-09-04\")\n ]),\n /*#__PURE__*/_createTextVNode(\" This is the first release :D \"),\n /*#__PURE__*/_createElementVNode(\"ul\", null, [\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"feature\" }, \"Did everything\"),\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"fix\" }, \"Had some fun\"),\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"breaking\" }, \"Removed everything\"),\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"balancing\" }, \"Created some bugs to fix later\")\n ])\n], -1))\n\nimport Modal from \"components/Modal.vue\";\nimport { ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props, { expose }) {\n\nconst isOpen = ref(false);\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((isOpen).value = $event))\n }, {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(() => [\n _hoisted_2\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./Changelog.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Changelog.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Changelog.vue?vue&type=style&index=0&id=5f8298e6&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-5f8298e6\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, createTextVNode as _createTextVNode, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, withCtx as _withCtx, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-3eb46986\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"info-modal-header\" }\nconst _hoisted_2 = [\"src\", \"alt\"]\nconst _hoisted_3 = { class: \"info-modal-title\" }\nconst _hoisted_4 = { key: 0 }\nconst _hoisted_5 = { key: 0 }\nconst _hoisted_6 = { key: 0 }\nconst _hoisted_7 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, \" Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb \", -1))\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_9 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_10 = [\"href\"]\nconst _hoisted_11 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons info-modal-discord\" }, \"discord\", -1))\nconst _hoisted_12 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/WzejVAx\",\n class: \"info-modal-discord-link\"\n }, [\n /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons info-modal-discord\" }, \"discord\"),\n /*#__PURE__*/_createTextVNode(\" The Paper Pilot Community \")\n ])\n], -1))\nconst _hoisted_13 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/F3xveHV\",\n class: \"info-modal-discord-link\"\n }, [\n /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons info-modal-discord\" }, \"discord\"),\n /*#__PURE__*/_createTextVNode(\" The Modding Tree \")\n ])\n], -1))\nconst _hoisted_14 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\n\nimport Modal from \"components/Modal.vue\";\nimport type Changelog from \"data/Changelog.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport { jsx } from \"features/feature\";\nimport player from \"game/player\";\nimport { infoComponents } from \"game/settings\";\nimport { formatTime } from \"util/bignum\";\nimport { coerceComponent, render } from \"util/vue\";\nimport { computed, ref, toRefs, unref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n changelog: null\n },\n setup(__props: any, { expose }) {\n\nconst _props = __props as { changelog: typeof Changelog | null }\n\nconst { title, logo, author, discordName, discordLink, versionNumber, versionTitle } = projInfo;\n\n\nconst props = toRefs(_props);\n\nconst isOpen = ref(false);\n\nconst timePlayed = computed(() => formatTime(player.timePlayed));\n\nconst infoComponent = computed(() => {\n return coerceComponent(jsx(() => <>{infoComponents.map(render)}));\n});\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nfunction openChangelog() {\n unref(props.changelog)?.open();\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((isOpen).value = $event))\n }, {\n header: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_1, [\n (_unref(logo))\n ? (_openBlock(), _createElementBlock(\"img\", {\n key: 0,\n class: \"info-modal-logo\",\n src: _unref(logo),\n alt: _unref(title)\n }, null, 8, _hoisted_2))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_3, [\n _createElementVNode(\"h2\", null, _toDisplayString(_unref(title)), 1),\n _createElementVNode(\"h4\", null, [\n _createTextVNode(\" v\" + _toDisplayString(_unref(versionNumber)), 1),\n (_unref(versionTitle))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_4, \": \" + _toDisplayString(_unref(versionTitle)), 1))\n : _createCommentVNode(\"\", true)\n ])\n ])\n ])\n ]),\n body: _withCtx(({ shown }) => [\n shown\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_5, [\n (_unref(author))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_6, \"By \" + _toDisplayString(_unref(author)), 1))\n : _createCommentVNode(\"\", true),\n _hoisted_7,\n _hoisted_8,\n _createElementVNode(\"div\", {\n class: \"link\",\n onClick: openChangelog\n }, \"Changelog\"),\n _hoisted_9,\n _createElementVNode(\"div\", null, [\n (_unref(discordLink) !== 'https://discord.gg/WzejVAx')\n ? (_openBlock(), _createElementBlock(\"a\", {\n key: 0,\n href: _unref(discordLink),\n class: \"info-modal-discord-link\"\n }, [\n _hoisted_11,\n _createTextVNode(\" \" + _toDisplayString(_unref(discordName)), 1)\n ], 8, _hoisted_10))\n : _createCommentVNode(\"\", true)\n ]),\n _hoisted_12,\n _hoisted_13,\n _hoisted_14,\n _createElementVNode(\"div\", null, \"Time Played: \" + _toDisplayString(_unref(timePlayed)), 1),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(infoComponent))))\n ]))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./Info.vue?vue&type=script&setup=true&lang=tsx\"\nexport * from \"./Info.vue?vue&type=script&setup=true&lang=tsx\"\n\nimport \"./Info.vue?vue&type=style&index=0&id=3eb46986&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-3eb46986\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { createElementVNode as _createElementVNode, unref as _unref, isRef as _isRef, createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, withCtx as _withCtx, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-85d7ae40\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { class: \"header\" }, [\n /*#__PURE__*/_createElementVNode(\"h2\", null, \"Options\")\n], -1))\nconst _hoisted_2 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"hr\", null, null, -1))\n\nimport Modal from \"components/Modal.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport rawThemes from \"data/themes\";\nimport { jsx } from \"features/feature\";\nimport player from \"game/player\";\nimport settings, { settingFields } from \"game/settings\";\nimport { camelToTitle } from \"util/common\";\nimport { coerceComponent, render } from \"util/vue\";\nimport { computed, ref, toRefs } from \"vue\";\nimport Select from \"./fields/Select.vue\";\nimport Toggle from \"./fields/Toggle.vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props, { expose }) {\n\nconst isOpen = ref(false);\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nconst themes = Object.keys(rawThemes).map(theme => ({\n label: camelToTitle(theme),\n value: theme\n}));\n\nconst settingFieldsComponent = computed(() => {\n return coerceComponent(jsx(() => <>{settingFields.map(render)}));\n});\n\nconst { showTPS, theme, unthrottled } = toRefs(settings);\nconst { autosave, offlineProd } = toRefs(player);\nconst isPaused = computed({\n get() {\n return player.devSpeed === 0;\n },\n set(value: boolean) {\n player.devSpeed = value ? 0 : null;\n }\n});\n\nconst offlineProdTitle = jsx(() => (\n \n Offline Production*\n \n));\nconst autosaveTitle = jsx(() => (\n \n Autosave*\n \n));\nconst isPausedTitle = jsx(() => (\n \n Pause game*\n \n));\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[6] || (_cache[6] = ($event: any) => ((isOpen).value = $event))\n }, {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(() => [\n _createVNode(Select, {\n title: \"Theme\",\n options: _unref(themes),\n modelValue: _unref(theme),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(theme) ? (theme).value = $event : null))\n }, null, 8, [\"options\", \"modelValue\"]),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(settingFieldsComponent)))),\n _createVNode(Toggle, {\n title: \"Show TPS\",\n modelValue: _unref(showTPS),\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => (_isRef(showTPS) ? (showTPS).value = $event : null))\n }, null, 8, [\"modelValue\"]),\n _hoisted_2,\n _createVNode(Toggle, {\n title: \"Unthrottled\",\n modelValue: _unref(unthrottled),\n \"onUpdate:modelValue\": _cache[2] || (_cache[2] = ($event: any) => (_isRef(unthrottled) ? (unthrottled).value = $event : null))\n }, null, 8, [\"modelValue\"]),\n _createVNode(Toggle, {\n title: _unref(offlineProdTitle),\n modelValue: _unref(offlineProd),\n \"onUpdate:modelValue\": _cache[3] || (_cache[3] = ($event: any) => (_isRef(offlineProd) ? (offlineProd).value = $event : null))\n }, null, 8, [\"title\", \"modelValue\"]),\n _createVNode(Toggle, {\n title: _unref(autosaveTitle),\n modelValue: _unref(autosave),\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = ($event: any) => (_isRef(autosave) ? (autosave).value = $event : null))\n }, null, 8, [\"title\", \"modelValue\"]),\n (_unref(projInfo).enablePausing)\n ? (_openBlock(), _createBlock(Toggle, {\n key: 0,\n title: _unref(isPausedTitle),\n modelValue: _unref(isPaused),\n \"onUpdate:modelValue\": _cache[5] || (_cache[5] = ($event: any) => (_isRef(isPaused) ? (isPaused).value = $event : null))\n }, null, 8, [\"title\", \"modelValue\"]))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./Options.vue?vue&type=script&setup=true&lang=tsx\"\nexport * from \"./Options.vue?vue&type=script&setup=true&lang=tsx\"\n\nimport \"./Options.vue?vue&type=style&index=0&id=85d7ae40&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-85d7ae40\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, renderSlot as _renderSlot, withModifiers as _withModifiers, createElementVNode as _createElementVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-bf59fca4\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { key: 0 }\nconst _hoisted_2 = [\"onClick\", \"disabled\"]\nconst _hoisted_3 = { key: 0 }\nconst _hoisted_4 = [\"onClick\"]\n\nimport { ref, toRefs, unref, watch } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n disabled: { type: Boolean },\n skipConfirm: { type: Boolean }\n },\n emits: [\"click\", \"confirmingChanged\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"click\"): void;\n (e: \"confirmingChanged\", value: boolean): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n disabled?: boolean;\n skipConfirm?: boolean;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst isConfirming = ref(false);\n\nwatch(isConfirming, isConfirming => {\n emit(\"confirmingChanged\", isConfirming);\n});\n\nfunction click() {\n if (unref(props.skipConfirm)) {\n emit(\"click\");\n return;\n }\n if (isConfirming.value) {\n emit(\"click\");\n }\n isConfirming.value = !isConfirming.value;\n}\n\nfunction cancel() {\n isConfirming.value = false;\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"span\", {\n class: _normalizeClass([\"container\", { confirming: isConfirming.value }])\n }, [\n (isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \"Are you sure?\"))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"button\", {\n onClick: _withModifiers(click, [\"stop\"]),\n class: \"button danger\",\n disabled: __props.disabled\n }, [\n (isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_3, \"Yes\"))\n : _renderSlot(_ctx.$slots, \"default\", { key: 1 })\n ], 8, _hoisted_2),\n (isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 1,\n class: \"button\",\n onClick: _withModifiers(cancel, [\"stop\"])\n }, \"No\", 8, _hoisted_4))\n : _createCommentVNode(\"\", true)\n ], 2))\n}\n}\n\n})","import script from \"./DangerButton.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./DangerButton.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./DangerButton.vue?vue&type=style&index=0&id=bf59fca4&scoped=true&lang=css\"\nimport \"./DangerButton.vue?vue&type=style&index=1&id=bf59fca4&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-bf59fca4\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, withModifiers as _withModifiers, normalizeClass as _normalizeClass, openBlock as _openBlock, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5bbcedd3\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"onClick\"]\n\nimport { nextTick, ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n left: { type: Boolean }\n },\n emits: [\"click\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"click\"): void;\n}), expose: any, slots: any, attrs: any }) {\n\n\n\n\nconst activated = ref(false);\nconst activatedTimeout = ref(null);\n\nfunction click() {\n emit(\"click\");\n\n // Give feedback to user\n if (activatedTimeout.value) {\n clearTimeout(activatedTimeout.value);\n }\n activated.value = false;\n nextTick(() => {\n activated.value = true;\n activatedTimeout.value = setTimeout(() => (activated.value = false), 500);\n });\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"button\", {\n onClick: _withModifiers(click, [\"stop\"]),\n class: _normalizeClass([\"feedback\", { activated: activated.value, left: __props.left }])\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 10, _hoisted_1))\n}\n}\n\n})","import script from \"./FeedbackButton.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./FeedbackButton.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./FeedbackButton.vue?vue&type=style&index=0&id=5bbcedd3&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-5bbcedd3\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementBlock as _createElementBlock, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-335ce270\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { class: \"handle material-icons\" }, \"drag_handle\", -1))\nconst _hoisted_2 = {\n key: 0,\n class: \"actions\"\n}\nconst _hoisted_3 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"content_paste\", -1))\nconst _hoisted_4 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"content_copy\", -1))\nconst _hoisted_5 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"edit\", -1))\nconst _hoisted_6 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", {\n class: \"material-icons\",\n style: {\"margin\":\"-2px\"}\n}, \"delete\", -1))\nconst _hoisted_7 = {\n key: 1,\n class: \"actions\"\n}\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"check\", -1))\nconst _hoisted_9 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"close\", -1))\nconst _hoisted_10 = {\n key: 2,\n class: \"details\"\n}\nconst _hoisted_11 = { class: \"save-version\" }\nconst _hoisted_12 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_13 = { key: 0 }\nconst _hoisted_14 = {\n key: 3,\n class: \"details\"\n}\nconst _hoisted_15 = {\n key: 4,\n class: \"details error\"\n}\nconst _hoisted_16 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\n\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport player from \"game/player\";\nimport { Direction } from \"util/common\";\nimport { computed, ref, toRefs, watch } from \"vue\";\nimport DangerButton from \"./fields/DangerButton.vue\";\nimport FeedbackButton from \"./fields/FeedbackButton.vue\";\nimport Text from \"./fields/Text.vue\";\nimport { LoadablePlayerData } from \"./SavesManager.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n save: null\n },\n emits: [\"export\", \"open\", \"duplicate\", \"delete\", \"editName\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"export\"): void;\n (e: \"open\"): void;\n (e: \"duplicate\"): void;\n (e: \"delete\"): void;\n (e: \"editName\", name: string): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n save: LoadablePlayerData;\n}\n\n\nconst { save } = toRefs(_props);\n\n\nconst dateFormat = new Intl.DateTimeFormat(\"en-US\", {\n year: \"numeric\",\n month: \"numeric\",\n day: \"numeric\",\n hour: \"numeric\",\n minute: \"numeric\",\n second: \"numeric\"\n});\n\nconst isEditing = ref(false);\nconst isConfirming = ref(false);\nconst newName = ref(\"\");\n\nwatch(isEditing, () => (newName.value = save.value.name || \"\"));\n\nconst isActive = computed(() => save.value && save.value.id === player.id);\nconst currentTime = computed(() =>\n isActive.value ? player.time : (save.value && save.value.time) || 0\n);\n\nfunction changeName() {\n emit(\"editName\", newName.value);\n isEditing.value = false;\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"save\", { active: _unref(isActive) }])\n }, [\n _hoisted_1,\n (!isEditing.value)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_2, [\n (_unref(save).error == undefined && !isConfirming.value)\n ? (_openBlock(), _createBlock(FeedbackButton, {\n key: 0,\n onClick: _cache[0] || (_cache[0] = ($event: any) => (emit('export'))),\n class: \"button\",\n left: \"\"\n }, {\n default: _withCtx(() => [\n _createVNode(Tooltip, {\n display: \"Export\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_3\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(save).error == undefined && !isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 1,\n onClick: _cache[1] || (_cache[1] = ($event: any) => (emit('duplicate'))),\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Duplicate\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_4\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]))\n : _createCommentVNode(\"\", true),\n (_unref(save).error == undefined && !isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 2,\n onClick: _cache[2] || (_cache[2] = ($event: any) => (isEditing.value = !isEditing.value)),\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Edit Name\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_5\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]))\n : _createCommentVNode(\"\", true),\n _createVNode(DangerButton, {\n disabled: _unref(isActive),\n onClick: _cache[3] || (_cache[3] = ($event: any) => (emit('delete'))),\n onConfirmingChanged: _cache[4] || (_cache[4] = value => (isConfirming.value = value))\n }, {\n default: _withCtx(() => [\n _createVNode(Tooltip, {\n display: \"Delete\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_6\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _: 1\n }, 8, [\"disabled\"])\n ]))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_7, [\n _createElementVNode(\"button\", {\n onClick: changeName,\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Save\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_8\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"button\", {\n onClick: _cache[5] || (_cache[5] = ($event: any) => (isEditing.value = !isEditing.value)),\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Cancel\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_9\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ])),\n (_unref(save).error == undefined && !isEditing.value)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_10, [\n _createElementVNode(\"button\", {\n class: \"button open\",\n onClick: _cache[6] || (_cache[6] = ($event: any) => (emit('open')))\n }, [\n _createElementVNode(\"h3\", null, _toDisplayString(_unref(save).name), 1)\n ]),\n _createElementVNode(\"span\", _hoisted_11, \"v\" + _toDisplayString(_unref(save).modVersion), 1),\n _hoisted_12,\n (_unref(currentTime))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_13, \"Last played \" + _toDisplayString(_unref(dateFormat).format(_unref(currentTime))), 1))\n : _createCommentVNode(\"\", true)\n ]))\n : (_unref(save).error == undefined && isEditing.value)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_14, [\n _createVNode(Text, {\n modelValue: newName.value,\n \"onUpdate:modelValue\": _cache[7] || (_cache[7] = ($event: any) => ((newName).value = $event)),\n class: \"editname\",\n onSubmit: changeName\n }, null, 8, [\"modelValue\"])\n ]))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_15, [\n _createTextVNode(\" Error: Failed to load save with id \" + _toDisplayString(_unref(save).id), 1),\n _hoisted_16,\n _createTextVNode(_toDisplayString(_unref(save).error), 1)\n ]))\n ], 2))\n}\n}\n\n})","import script from \"./Save.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Save.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Save.vue?vue&type=style&index=0&id=335ce270&scoped=true&lang=css\"\nimport \"./Save.vue?vue&type=style&index=1&id=335ce270&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-335ce270\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { createElementVNode as _createElementVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-2bfdf896\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"h2\", null, \"Saves Manager\", -1))\nconst _hoisted_2 = { class: \"modal-footer\" }\nconst _hoisted_3 = { class: \"field\" }\nconst _hoisted_4 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"field-title\" }, \"Create Save\", -1))\nconst _hoisted_5 = { class: \"field-buttons\" }\nconst _hoisted_6 = { class: \"footer\" }\nconst _hoisted_7 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { style: {\"flex-grow\":\"1\"} }, null, -1))\n\nimport projInfo from \"data/projInfo.json\";\nimport Modal from \"components/Modal.vue\";\nimport player, { PlayerData, stringifySave } from \"game/player\";\nimport settings from \"game/settings\";\nimport { getUniqueID, loadSave, save, newSave } from \"util/save\";\nimport { ComponentPublicInstance, computed, nextTick, ref, shallowReactive, watch } from \"vue\";\nimport Select from \"./fields/Select.vue\";\nimport Text from \"./fields/Text.vue\";\nimport Save from \"./Save.vue\";\nimport Draggable from \"vuedraggable\";\nimport LZString from \"lz-string\";\nimport { ProxyState } from \"util/proxies\";\n\nexport type LoadablePlayerData = Omit, \"id\"> & { id: string; error?: unknown };\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props, { expose }) {\n\nconst isOpen = ref(false);\nconst modal = ref | null>(null);\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nconst importingFailed = ref(false);\nconst saveToImport = ref(\"\");\nconst selectedPreset = ref(null);\n\nwatch(saveToImport, importedSave => {\n if (importedSave) {\n nextTick(() => {\n try {\n if (importedSave[0] === \"{\") {\n // plaintext. No processing needed\n } else if (importedSave[0] === \"e\") {\n // Assumed to be base64, which starts with e\n importedSave = decodeURIComponent(escape(atob(importedSave)));\n } else if (importedSave[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n importedSave = LZString.decompressFromUTF16(importedSave)!;\n } else {\n console.warn(\"Unable to determine preset encoding\", importedSave);\n importingFailed.value = true;\n return;\n }\n const playerData = JSON.parse(importedSave);\n if (typeof playerData !== \"object\") {\n importingFailed.value = true;\n return;\n }\n const id = getUniqueID();\n playerData.id = id;\n save(playerData);\n saveToImport.value = \"\";\n importingFailed.value = false;\n\n settings.saves.push(id);\n } catch (e) {\n importingFailed.value = true;\n }\n });\n } else {\n importingFailed.value = false;\n }\n});\n\nlet bankContext = require.context(\"raw-loader!../../saves\", true, /\\.txt$/);\nlet bank = ref(\n bankContext.keys().reduce((acc: Array<{ label: string; value: string }>, curr) => {\n // .slice(2, -4) strips the leading ./ and the trailing .txt\n acc.push({\n label: curr.slice(2, -4),\n value: bankContext(curr).default\n });\n return acc;\n }, [])\n);\n\nconst cachedSaves = shallowReactive>({});\nfunction getCachedSave(id: string) {\n if (cachedSaves[id] == null) {\n let save = localStorage.getItem(id);\n if (save == null) {\n cachedSaves[id] = { error: `Save doesn't exist in localStorage`, id };\n } else if (save === \"dW5kZWZpbmVk\") {\n cachedSaves[id] = { error: `Save is undefined`, id };\n } else {\n try {\n if (save[0] === \"{\") {\n // plaintext. No processing needed\n } else if (save[0] === \"e\") {\n // Assumed to be base64, which starts with e\n save = decodeURIComponent(escape(atob(save)));\n } else if (save[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n save = LZString.decompressFromUTF16(save)!;\n } else {\n console.warn(\"Unable to determine preset encoding\", save);\n importingFailed.value = true;\n cachedSaves[id] = { error: \"Unable to determine preset encoding\", id };\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n return cachedSaves[id]!;\n }\n cachedSaves[id] = { ...JSON.parse(save), id };\n } catch (error) {\n cachedSaves[id] = { error, id };\n console.warn(\n `SavesManager: Failed to load info about save with id ${id}:\\n${error}\\n${save}`\n );\n }\n }\n }\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n return cachedSaves[id]!;\n}\n// Wipe cache whenever the modal is opened\nwatch(isOpen, isOpen => {\n if (isOpen) {\n Object.keys(cachedSaves).forEach(key => delete cachedSaves[key]);\n }\n});\n\nconst saves = computed(() =>\n settings.saves.reduce((acc: Record, curr: string) => {\n acc[curr] = getCachedSave(curr);\n return acc;\n }, {})\n);\n\nfunction exportSave(id: string) {\n let saveToExport;\n if (player.id === id) {\n saveToExport = stringifySave(player[ProxyState]);\n } else {\n saveToExport = JSON.stringify(saves.value[id]);\n }\n switch (projInfo.exportEncoding) {\n default:\n console.warn(`Unknown save encoding: ${projInfo.exportEncoding}. Defaulting to lz`);\n case \"lz\":\n saveToExport = LZString.compressToUTF16(saveToExport);\n break;\n case \"base64\":\n saveToExport = btoa(unescape(encodeURIComponent(saveToExport)));\n break;\n case \"plain\":\n break;\n }\n\n // Put on clipboard. Using the clipboard API asks for permissions and stuff\n const el = document.createElement(\"textarea\");\n el.value = saveToExport;\n document.body.appendChild(el);\n el.select();\n el.setSelectionRange(0, 99999);\n document.execCommand(\"copy\");\n document.body.removeChild(el);\n}\n\nfunction duplicateSave(id: string) {\n if (player.id === id) {\n save();\n }\n\n const playerData = { ...saves.value[id], id: getUniqueID() };\n save(playerData as PlayerData);\n\n settings.saves.push(playerData.id);\n}\n\nfunction deleteSave(id: string) {\n settings.saves = settings.saves.filter((save: string) => save !== id);\n localStorage.removeItem(id);\n cachedSaves[id] = undefined;\n}\n\nfunction openSave(id: string) {\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n saves.value[player.id]!.time = player.time;\n save();\n cachedSaves[player.id] = undefined;\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n loadSave(saves.value[id]!);\n // Delete cached version in case of opening it again\n cachedSaves[id] = undefined;\n}\n\nfunction newFromPreset(preset: string) {\n // Reset preset dropdown\n selectedPreset.value = preset;\n nextTick(() => {\n selectedPreset.value = null;\n });\n\n if (preset[0] === \"{\") {\n // plaintext. No processing needed\n } else if (preset[0] === \"e\") {\n // Assumed to be base64, which starts with e\n preset = decodeURIComponent(escape(atob(preset)));\n } else if (preset[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n preset = LZString.decompressFromUTF16(preset)!;\n } else {\n console.warn(\"Unable to determine preset encoding\", preset);\n return;\n }\n const playerData = JSON.parse(preset);\n playerData.id = getUniqueID();\n save(playerData as PlayerData);\n\n settings.saves.push(playerData.id);\n\n openSave(playerData.id);\n}\n\nfunction editSave(id: string, newName: string) {\n const currSave = saves.value[id];\n if (currSave) {\n currSave.name = newName;\n if (player.id === id) {\n player.name = newName;\n save();\n } else {\n save(currSave as PlayerData);\n cachedSaves[id] = undefined;\n }\n }\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = ($event: any) => ((isOpen).value = $event)),\n ref_key: \"modal\",\n ref: modal\n }, {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(({ shown }) => [\n shown\n ? (_openBlock(), _createBlock(_unref(Draggable), {\n key: 0,\n list: _unref(settings).saves,\n handle: \".handle\",\n itemKey: (save) => save\n }, {\n item: _withCtx(({ element }) => [\n _createVNode(Save, {\n save: _unref(saves)[element],\n onOpen: ($event: any) => (openSave(element)),\n onExport: ($event: any) => (exportSave(element)),\n onEditName: name => editSave(element, name),\n onDuplicate: ($event: any) => (duplicateSave(element)),\n onDelete: ($event: any) => (deleteSave(element))\n }, null, 8, [\"save\", \"onOpen\", \"onExport\", \"onEditName\", \"onDuplicate\", \"onDelete\"])\n ]),\n _: 1\n }, 8, [\"list\", \"itemKey\"]))\n : _createCommentVNode(\"\", true)\n ]),\n footer: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_2, [\n _createVNode(Text, {\n modelValue: saveToImport.value,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((saveToImport).value = $event)),\n title: \"Import Save\",\n placeholder: \"Paste your save here!\",\n class: _normalizeClass({ importingFailed: importingFailed.value })\n }, null, 8, [\"modelValue\", \"class\"]),\n _createElementVNode(\"div\", _hoisted_3, [\n _hoisted_4,\n _createElementVNode(\"div\", _hoisted_5, [\n _createElementVNode(\"button\", {\n class: \"button\",\n onClick: _cache[1] || (_cache[1] = ($event: any) => (openSave(_unref(newSave)().id)))\n }, \"New Game\"),\n (Object.keys(_unref(bank)).length > 0)\n ? (_openBlock(), _createBlock(Select, {\n key: 0,\n options: _unref(bank),\n modelValue: selectedPreset.value,\n \"onUpdate:modelValue\": _cache[2] || (_cache[2] = preset => newFromPreset(preset as string)),\n closeOnSelect: \"\",\n placeholder: \"Select preset\",\n class: \"presets\"\n }, null, 8, [\"options\", \"modelValue\"]))\n : _createCommentVNode(\"\", true)\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_6, [\n _hoisted_7,\n _createElementVNode(\"button\", {\n class: \"button modal-default-button\",\n onClick: _cache[3] || (_cache[3] = ($event: any) => (isOpen.value = false))\n }, \" Close \")\n ])\n ])\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./SavesManager.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./SavesManager.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./SavesManager.vue?vue&type=style&index=0&id=2bfdf896&scoped=true&lang=css\"\nimport \"./SavesManager.vue?vue&type=style&index=1&id=2bfdf896&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-2bfdf896\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, mergeProps as _mergeProps, Fragment as _Fragment, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-53a1a91d\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"src\", \"alt\"]\nconst _hoisted_2 = {\n key: 1,\n class: \"title\"\n}\nconst _hoisted_3 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { style: {\"flex-grow\":\"1\",\"cursor\":\"unset\"} }, null, -1))\nconst _hoisted_4 = { class: \"discord\" }\nconst _hoisted_5 = { class: \"discord-links\" }\nconst _hoisted_6 = { key: 0 }\nconst _hoisted_7 = [\"href\"]\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/WzejVAx\",\n target: \"_blank\"\n }, \"The Paper Pilot Community\")\n], -1))\nconst _hoisted_9 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/F3xveHV\",\n target: \"_blank\"\n }, \"The Modding Tree\")\n], -1))\nconst _hoisted_10 = {\n href: \"https://forums.moddingtree.com/\",\n target: \"_blank\"\n}\nconst _hoisted_11 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"forum\", -1))\nconst _hoisted_12 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"info\", -1))\nconst _hoisted_13 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"library_books\", -1))\nconst _hoisted_14 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"settings\", -1))\nconst _hoisted_15 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"library_books\", -1))\nconst _hoisted_16 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"settings\", -1))\nconst _hoisted_17 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"info\", -1))\nconst _hoisted_18 = {\n href: \"https://forums.moddingtree.com/\",\n target: \"_blank\"\n}\nconst _hoisted_19 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"forum\", -1))\nconst _hoisted_20 = { class: \"discord\" }\nconst _hoisted_21 = { class: \"discord-links\" }\nconst _hoisted_22 = { key: 0 }\nconst _hoisted_23 = [\"href\"]\nconst _hoisted_24 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/WzejVAx\",\n target: \"_blank\"\n }, \"The Paper Pilot Community\")\n], -1))\nconst _hoisted_25 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/F3xveHV\",\n target: \"_blank\"\n }, \"The Modding Tree\")\n], -1))\n\nimport Changelog from \"data/Changelog.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport { ComponentPublicInstance, ref } from \"vue\";\nimport Info from \"./Info.vue\";\nimport Options from \"./Options.vue\";\nimport SavesManager from \"./SavesManager.vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport { Direction } from \"util/common\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst info = ref | null>(null);\nconst savesManager = ref | null>(null);\nconst options = ref | null>(null);\n// For some reason Info won't accept the changelog unless I do this:\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst changelog = ref | null>(null);\n\nconst { useHeader, banner, title, discordName, discordLink, versionNumber } = projInfo;\n\nfunction openDiscord() {\n window.open(discordLink, \"mywindow\");\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (_unref(useHeader))\n ? (_openBlock(), _createElementBlock(\"div\", _mergeProps({\n key: 0,\n class: \"nav\"\n }, _ctx.$attrs), [\n (_unref(banner))\n ? (_openBlock(), _createElementBlock(\"img\", {\n key: 0,\n src: _unref(banner),\n class: \"banner\",\n alt: _unref(title)\n }, null, 8, _hoisted_1))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_2, _toDisplayString(_unref(title)), 1)),\n _createElementVNode(\"div\", {\n onClick: _cache[0] || (_cache[0] = ($event: any) => (changelog.value?.open())),\n class: \"version-container\"\n }, [\n _createVNode(Tooltip, {\n display: \"Changelog\",\n direction: _unref(Direction).Down,\n class: \"version\"\n }, {\n default: _withCtx(() => [\n _createElementVNode(\"span\", null, \"v\" + _toDisplayString(_unref(versionNumber)), 1)\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _hoisted_3,\n _createElementVNode(\"div\", _hoisted_4, [\n _createElementVNode(\"span\", {\n onClick: openDiscord,\n class: \"material-icons\"\n }, \"discord\"),\n _createElementVNode(\"ul\", _hoisted_5, [\n (_unref(discordLink) !== 'https://discord.gg/WzejVAx')\n ? (_openBlock(), _createElementBlock(\"li\", _hoisted_6, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n target: \"_blank\"\n }, _toDisplayString(_unref(discordName)), 9, _hoisted_7)\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_8,\n _hoisted_9\n ])\n ]),\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", _hoisted_10, [\n _createVNode(Tooltip, {\n display: \"Forums\",\n direction: _unref(Direction).Down,\n yoffset: \"5px\"\n }, {\n default: _withCtx(() => [\n _hoisted_11\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[1] || (_cache[1] = ($event: any) => (info.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Info\",\n direction: _unref(Direction).Down,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_12\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[2] || (_cache[2] = ($event: any) => (savesManager.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Saves\",\n direction: _unref(Direction).Down,\n xoffset: \"-20px\"\n }, {\n default: _withCtx(() => [\n _hoisted_13\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[3] || (_cache[3] = ($event: any) => (options.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Options\",\n direction: _unref(Direction).Down,\n xoffset: \"-66px\"\n }, {\n default: _withCtx(() => [\n _hoisted_14\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ], 16))\n : (_openBlock(), _createElementBlock(\"div\", _mergeProps({\n key: 1,\n class: \"overlay-nav\"\n }, _ctx.$attrs), [\n _createElementVNode(\"div\", {\n onClick: _cache[4] || (_cache[4] = ($event: any) => (changelog.value?.open())),\n class: \"version-container\"\n }, [\n _createVNode(Tooltip, {\n display: \"Changelog\",\n direction: _unref(Direction).Right,\n xoffset: \"25%\",\n class: \"version\"\n }, {\n default: _withCtx(() => [\n _createElementVNode(\"span\", null, \"v\" + _toDisplayString(_unref(versionNumber)), 1)\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[5] || (_cache[5] = ($event: any) => (savesManager.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Saves\",\n direction: _unref(Direction).Right\n }, {\n default: _withCtx(() => [\n _hoisted_15\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[6] || (_cache[6] = ($event: any) => (options.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Options\",\n direction: _unref(Direction).Right\n }, {\n default: _withCtx(() => [\n _hoisted_16\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[7] || (_cache[7] = ($event: any) => (info.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Info\",\n direction: _unref(Direction).Right\n }, {\n default: _withCtx(() => [\n _hoisted_17\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", _hoisted_18, [\n _createVNode(Tooltip, {\n display: \"Forums\",\n direction: _unref(Direction).Right,\n xoffset: \"7px\"\n }, {\n default: _withCtx(() => [\n _hoisted_19\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_20, [\n _createElementVNode(\"span\", {\n onClick: openDiscord,\n class: \"material-icons\"\n }, \"discord\"),\n _createElementVNode(\"ul\", _hoisted_21, [\n (_unref(discordLink) !== 'https://discord.gg/WzejVAx')\n ? (_openBlock(), _createElementBlock(\"li\", _hoisted_22, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n target: \"_blank\"\n }, _toDisplayString(_unref(discordName)), 9, _hoisted_23)\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_24,\n _hoisted_25\n ])\n ])\n ], 16)),\n _createVNode(Info, {\n ref_key: \"info\",\n ref: info,\n changelog: changelog.value\n }, null, 8, [\"changelog\"]),\n _createVNode(SavesManager, {\n ref_key: \"savesManager\",\n ref: savesManager\n }, null, 512),\n _createVNode(Options, {\n ref_key: \"options\",\n ref: options\n }, null, 512),\n _createVNode(Changelog, {\n ref_key: \"changelog\",\n ref: changelog\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./Nav.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Nav.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Nav.vue?vue&type=style&index=0&id=53a1a91d&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-53a1a91d\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, mergeProps as _mergeProps, resolveDynamicComponent as _resolveDynamicComponent, createElementVNode as _createElementVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-7e494d3c\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"inner-tab\" }\n\nimport projInfo from \"data/projInfo.json\";\nimport { GenericLayer, layers } from \"game/layers\";\nimport player from \"game/player\";\nimport { computed, toRef, unref } from \"vue\";\nimport Layer from \"./Layer.vue\";\nimport Nav from \"./Nav.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst tabs = toRef(player, \"tabs\");\nconst layerKeys = computed(() => Object.keys(layers));\nconst useHeader = projInfo.useHeader;\n\nfunction gatherLayerProps(layer: GenericLayer) {\n const { display, minimized, minWidth, name, color, minimizable, nodes } = layer;\n return { display, minimized, minWidth, name, color, minimizable, nodes };\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"tabs-container\", { useHeader: _unref(useHeader) }])\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_unref(tabs), (tab, index) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n key: index,\n class: _normalizeClass([\"tab\", unref(_unref(layers)[tab]?.classes)]),\n ref_for: true,\n ref: `tab-${index}`,\n style: _normalizeStyle(unref(_unref(layers)[tab]?.style))\n }, [\n (index === 0 && !_unref(useHeader))\n ? (_openBlock(), _createBlock(Nav, { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_1, [\n (_unref(layerKeys).includes(tab))\n ? (_openBlock(), _createBlock(Layer, _mergeProps({ key: 0 }, gatherLayerProps(_unref(layers)[tab]!), {\n index: index,\n tab: () => ((_ctx.$refs[`tab-${index}`] as HTMLElement[] | undefined)?.[0])\n }), null, 16, [\"index\", \"tab\"]))\n : (_openBlock(), _createBlock(_resolveDynamicComponent(tab), {\n key: 1,\n index: index\n }, null, 8, [\"index\"]))\n ])\n ], 6))\n }), 128))\n ], 2))\n}\n}\n\n})","import script from \"./Game.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Game.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Game.vue?vue&type=style&index=0&id=7e494d3c&scoped=true&lang=css\"\nimport \"./Game.vue?vue&type=style&index=1&id=7e494d3c&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-7e494d3c\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createElementVNode as _createElementVNode, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, isRef as _isRef, createVNode as _createVNode, withCtx as _withCtx, createBlock as _createBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-06188cc8\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"game-over-modal-header\" }\nconst _hoisted_2 = [\"src\", \"alt\"]\nconst _hoisted_3 = { class: \"game-over-modal-title\" }\nconst _hoisted_4 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"h2\", null, \"Congratulations!\", -1))\nconst _hoisted_5 = { key: 0 }\nconst _hoisted_6 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_7 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, \" Please check the Discord to discuss the game or to check for new content updates! \", -1))\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_9 = [\"href\"]\nconst _hoisted_10 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons game-over-modal-discord\" }, \"discord\", -1))\n\nimport Modal from \"components/Modal.vue\";\nimport { hasWon } from \"data/projEntry\";\nimport projInfo from \"data/projInfo.json\";\nimport player from \"game/player\";\nimport { formatTime } from \"util/bignum\";\nimport { loadSave, newSave } from \"util/save\";\nimport { computed, toRef } from \"vue\";\nimport Toggle from \"./fields/Toggle.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst { title, logo, discordName, discordLink, versionNumber, versionTitle } = projInfo;\n\nconst timePlayed = computed(() => formatTime(player.timePlayed));\nconst isOpen = computed(() => hasWon.value && !player.keepGoing);\nconst autosave = toRef(player, \"autosave\");\n\nfunction keepGoing() {\n player.keepGoing = true;\n}\n\nfunction playAgain() {\n loadSave(newSave());\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, { \"model-value\": _unref(isOpen) }, {\n header: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_1, [\n (_unref(logo))\n ? (_openBlock(), _createElementBlock(\"img\", {\n key: 0,\n class: \"game-over-modal-logo\",\n src: _unref(logo),\n alt: _unref(title)\n }, null, 8, _hoisted_2))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_3, [\n _hoisted_4,\n _createElementVNode(\"h4\", null, \"You've beaten \" + _toDisplayString(_unref(title)) + \" v\" + _toDisplayString(_unref(versionNumber)) + \": \" + _toDisplayString(_unref(versionTitle)), 1)\n ])\n ])\n ]),\n body: _withCtx(({ shown }) => [\n shown\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_5, [\n _createElementVNode(\"div\", null, \"It took you \" + _toDisplayString(_unref(timePlayed)) + \" to beat the game.\", 1),\n _hoisted_6,\n _hoisted_7,\n _hoisted_8,\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n class: \"game-over-modal-discord-link\"\n }, [\n _hoisted_10,\n _createTextVNode(\" \" + _toDisplayString(_unref(discordName)), 1)\n ], 8, _hoisted_9)\n ]),\n _createVNode(Toggle, {\n title: \"Autosave\",\n modelValue: _unref(autosave),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(autosave) ? (autosave).value = $event : null))\n }, null, 8, [\"modelValue\"])\n ]))\n : _createCommentVNode(\"\", true)\n ]),\n footer: _withCtx(() => [\n _createElementVNode(\"div\", { class: \"game-over-footer\" }, [\n _createElementVNode(\"button\", {\n onClick: keepGoing,\n class: \"button\"\n }, \"Keep Going\"),\n _createElementVNode(\"button\", {\n onClick: playAgain,\n class: \"button danger\"\n }, \"Play Again\")\n ])\n ]),\n _: 1\n }, 8, [\"model-value\"]))\n}\n}\n\n})","import script from \"./GameOverScreen.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./GameOverScreen.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./GameOverScreen.vue?vue&type=style&index=0&id=06188cc8&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-06188cc8\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, createElementVNode as _createElementVNode, toDisplayString as _toDisplayString, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createTextVNode as _createTextVNode, isRef as _isRef, createVNode as _createVNode, createBlock as _createBlock, mergeProps as _mergeProps, withCtx as _withCtx, Fragment as _Fragment, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5935214c\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { class: \"nan-modal-header\" }, [\n /*#__PURE__*/_createElementVNode(\"h2\", null, \"NaN value detected!\")\n], -1))\nconst _hoisted_2 = { key: 0 }\nconst _hoisted_3 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_4 = [\"href\"]\nconst _hoisted_5 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons nan-modal-discord\" }, \"discord\", -1))\nconst _hoisted_6 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_7 = { class: \"nan-footer\" }\n\nimport Modal from \"components/Modal.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport player from \"game/player\";\nimport state from \"game/state\";\nimport Decimal, { DecimalSource, format } from \"util/bignum\";\nimport { ComponentPublicInstance, computed, ref, toRef } from \"vue\";\nimport Toggle from \"./fields/Toggle.vue\";\nimport SavesManager from \"./SavesManager.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst { discordName, discordLink } = projInfo;\nconst autosave = toRef(player, \"autosave\");\nconst hasNaN = toRef(state, \"hasNaN\");\nconst savesManager = ref | null>(null);\n\nconst path = computed(() => state.NaNPath?.join(\".\"));\nconst property = computed(() => state.NaNPath?.slice(-1)[0]);\nconst previous = computed(() => {\n if (state.NaNReceiver && property.value) {\n return state.NaNReceiver[property.value] as DecimalSource;\n }\n return null;\n});\nconst isPaused = computed({\n get() {\n return player.devSpeed === 0;\n },\n set(value: boolean) {\n player.devSpeed = value ? null : 0;\n }\n});\n\nfunction setZero() {\n if (state.NaNReceiver && property.value) {\n state.NaNReceiver[property.value] = new Decimal(0);\n state.hasNaN = false;\n }\n}\n\nfunction setOne() {\n if (state.NaNReceiver && property.value) {\n state.NaNReceiver[property.value] = new Decimal(1);\n state.hasNaN = false;\n }\n}\n\nfunction ignore() {\n if (state.NaNReceiver && property.value) {\n state.NaNReceiver[property.value] = new Decimal(NaN);\n state.hasNaN = false;\n }\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n _createVNode(Modal, _mergeProps({\n modelValue: _unref(hasNaN),\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = ($event: any) => (_isRef(hasNaN) ? (hasNaN).value = $event : null))\n }, _ctx.$attrs), {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(() => [\n _createElementVNode(\"div\", null, [\n _createTextVNode(\" Attempted to assign \\\"\" + _toDisplayString(_unref(path)) + \"\\\" to NaN\", 1),\n (_unref(previous))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, _toDisplayString(\" \") + \"(previously \" + _toDisplayString(_unref(format)(_unref(previous))) + \")\", 1))\n : _createCommentVNode(\"\", true),\n _createTextVNode(\". Auto-saving has been \" + _toDisplayString(_unref(autosave) ? \"enabled\" : \"disabled\") + \". Check the console for more details, and consider sharing it with the developers on discord. \", 1)\n ]),\n _hoisted_3,\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n class: \"nan-modal-discord-link\"\n }, [\n _hoisted_5,\n _createTextVNode(\" \" + _toDisplayString(_unref(discordName)), 1)\n ], 8, _hoisted_4)\n ]),\n _hoisted_6,\n _createVNode(Toggle, {\n title: \"Autosave\",\n modelValue: _unref(autosave),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(autosave) ? (autosave).value = $event : null))\n }, null, 8, [\"modelValue\"]),\n (_unref(projInfo).enablePausing)\n ? (_openBlock(), _createBlock(Toggle, {\n key: 0,\n title: \"Pause game\",\n modelValue: _unref(isPaused),\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => (_isRef(isPaused) ? (isPaused).value = $event : null))\n }, null, 8, [\"modelValue\"]))\n : _createCommentVNode(\"\", true)\n ]),\n footer: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_7, [\n _createElementVNode(\"button\", {\n onClick: _cache[2] || (_cache[2] = ($event: any) => (savesManager.value?.open())),\n class: \"button\"\n }, \"Open Saves Manager\"),\n _createElementVNode(\"button\", {\n onClick: setZero,\n class: \"button\"\n }, \"Set to 0\"),\n _createElementVNode(\"button\", {\n onClick: setOne,\n class: \"button\"\n }, \"Set to 1\"),\n (_unref(previous) && _unref(Decimal).neq(_unref(previous), 0) && _unref(Decimal).neq(_unref(previous), 1))\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n onClick: _cache[3] || (_cache[3] = ($event: any) => (hasNaN.value = false)),\n class: \"button\"\n }, \" Set to previous \"))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"button\", {\n onClick: ignore,\n class: \"button danger\"\n }, \"Ignore\")\n ])\n ]),\n _: 1\n }, 16, [\"modelValue\"]),\n _createVNode(SavesManager, {\n ref_key: \"savesManager\",\n ref: savesManager\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./NaNScreen.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./NaNScreen.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./NaNScreen.vue?vue&type=style&index=0&id=5935214c&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-5935214c\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, toDisplayString as _toDisplayString, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, Transition as _Transition, withCtx as _withCtx, createVNode as _createVNode, createTextVNode as _createTextVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-c0663118\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = {\n key: 0,\n class: \"tpsDisplay\"\n}\nconst _hoisted_2 = {\n key: 0,\n class: \"low\"\n}\n\nimport state from \"game/state\";\nimport Decimal, { DecimalSource, formatWhole } from \"util/bignum\";\nimport { computed, ref, watchEffect } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst tps = computed(() =>\n Decimal.div(\n state.lastTenTicks.length,\n state.lastTenTicks.reduce((acc, curr) => acc + curr, 0)\n )\n);\n\nconst lastTenFPS = ref([]);\nwatchEffect(() => {\n lastTenFPS.value.push(Math.round(tps.value.toNumber()));\n if (lastTenFPS.value.length > 10) {\n lastTenFPS.value = lastTenFPS.value.slice(1);\n }\n});\n\nconst low = computed(() =>\n lastTenFPS.value.reduce((acc, curr) => Decimal.max(acc, curr), 0)\n);\n\nconst showLow = computed(() => Decimal.sub(tps.value, low.value).gt(1));\n\nreturn (_ctx: any,_cache: any) => {\n return (!_unref(tps).isNan())\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createTextVNode(\" TPS: \" + _toDisplayString(_unref(formatWhole)(_unref(tps))) + \" \", 1),\n _createVNode(_Transition, { name: \"fade\" }, {\n default: _withCtx(() => [\n (_unref(showLow))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, _toDisplayString(_unref(formatWhole)(_unref(low))), 1))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n })\n ]))\n : _createCommentVNode(\"\", true)\n}\n}\n\n})","import script from \"./TPS.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./TPS.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./TPS.vue?vue&type=style&index=0&id=c0663118&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-c0663118\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, normalizeClass as _normalizeClass, Fragment as _Fragment, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { jsx } from \"features/feature\";\nimport { coerceComponent, render } from \"util/vue\";\nimport { computed, toRef, unref } from \"vue\";\nimport Game from \"./components/Game.vue\";\nimport GameOverScreen from \"./components/GameOverScreen.vue\";\nimport NaNScreen from \"./components/NaNScreen.vue\";\nimport Nav from \"./components/Nav.vue\";\nimport TPS from \"./components/TPS.vue\";\nimport projInfo from \"./data/projInfo.json\";\nimport themes from \"./data/themes\";\nimport settings, { gameComponents } from \"./game/settings\";\nimport \"./main.css\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst useHeader = projInfo.useHeader;\nconst theme = computed(() => themes[settings.theme].variables);\nconst showTPS = toRef(settings, \"showTPS\");\n\nconst gameComponent = computed(() => {\n return coerceComponent(jsx(() => <>{gameComponents.map(render)}));\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n _createElementVNode(\"div\", {\n id: \"modal-root\",\n style: _normalizeStyle(_unref(theme))\n }, null, 4),\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"app\", { useHeader: _unref(useHeader) }]),\n style: _normalizeStyle(_unref(theme))\n }, [\n (_unref(useHeader))\n ? (_openBlock(), _createBlock(Nav, { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(Game),\n (unref(_unref(showTPS)))\n ? (_openBlock(), _createBlock(TPS, { key: 1 }))\n : _createCommentVNode(\"\", true),\n _createVNode(GameOverScreen),\n _createVNode(NaNScreen),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(gameComponent))))\n ], 6)\n ], 64))\n}\n}\n\n})","import script from \"./App.vue?vue&type=script&setup=true&lang=tsx\"\nexport * from \"./App.vue?vue&type=script&setup=true&lang=tsx\"\n\nimport \"./App.vue?vue&type=style&index=0&id=f13f28b6&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-f13f28b6\"]])\n\nexport default __exports__","import { App as VueApp, createApp } from \"vue\";\nimport App from \"./App.vue\";\nimport projInfo from \"./data/projInfo.json\";\nimport { GenericLayer } from \"./game/layers\";\nimport { PlayerData } from \"./game/player\";\nimport { Settings } from \"./game/settings\";\nimport { Transient } from \"./game/state\";\nimport Decimal, { DecimalSource } from \"./util/bignum\";\nimport { load } from \"./util/save\";\n\ndocument.title = projInfo.title;\nif (projInfo.id === \"\") {\n throw \"Project ID is empty! Please select a unique ID for this project in /src/data/projInfo.json\";\n}\n\ndeclare global {\n interface Window {\n vue: VueApp;\n save: VoidFunction;\n hardReset: VoidFunction;\n hardResetSettings: VoidFunction;\n layers: Record | undefined>;\n player: PlayerData;\n state: Transient;\n settings: Settings;\n Decimal: typeof Decimal;\n exponentialFormat: (num: DecimalSource, precision: number, mantissa: boolean) => string;\n commaFormat: (num: DecimalSource, precision: number) => string;\n regularFormat: (num: DecimalSource, precision: number) => string;\n format: (num: DecimalSource, precision?: number, small?: boolean) => string;\n formatWhole: (num: DecimalSource) => string;\n formatTime: (s: number) => string;\n toPlaces: (x: DecimalSource, precision: number, maxAccepted: DecimalSource) => string;\n formatSmall: (x: DecimalSource, precision?: number) => string;\n invertOOM: (x: DecimalSource) => Decimal;\n projInfo: typeof projInfo;\n }\n}\n\nrequestAnimationFrame(async () => {\n console.log(\n \"%cMade in Profectus%c\\nLearn more at www.moddingtree.com\",\n \"font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;\",\n \"padding: 4px;\"\n );\n await load();\n const { globalBus, startGameLoop } = await require(\"./game/events\");\n\n // Create Vue\n const vue = (window.vue = createApp(App));\n globalBus.emit(\"setupVue\", vue);\n vue.mount(\"#app\");\n\n startGameLoop();\n});\n\nwindow.projInfo = projInfo;\n","/* eslint-disable @typescript-eslint/no-this-alias */\nexport type CompareResult = -1 | 0 | 1;\n\nconst MAX_SIGNIFICANT_DIGITS = 17; //Maximum number of digits of precision to assume in Number\n\nconst EXP_LIMIT = 9e15; //If we're ABOVE this value, increase a layer. (9e15 is close to the largest integer that can fit in a Number.)\n\nconst LAYER_DOWN: number = Math.log10(9e15);\n\nconst FIRST_NEG_LAYER = 1 / 9e15; //At layer 0, smaller non-zero numbers than this become layer 1 numbers with negative mag. After that the pattern continues as normal.\n\nconst NUMBER_EXP_MAX = 308; //The largest exponent that can appear in a Number, though not all mantissas are valid here.\n\nconst NUMBER_EXP_MIN = -324; //The smallest exponent that can appear in a Number, though not all mantissas are valid here.\n\nconst MAX_ES_IN_A_ROW = 5; //For default toString behaviour, when to swap from eee... to (e^n) syntax.\n\nconst IGNORE_COMMAS = true;\nconst COMMAS_ARE_DECIMAL_POINTS = false;\n\nconst powerOf10 = (function() {\n // We need this lookup table because Math.pow(10, exponent)\n // when exponent's absolute value is large is slightly inaccurate.\n // You can fix it with the power of math... or just make a lookup table.\n // Faster AND simpler\n const powersOf10: number[] = [];\n\n for (let i = NUMBER_EXP_MIN + 1; i <= NUMBER_EXP_MAX; i++) {\n powersOf10.push(Number(\"1e\" + i));\n }\n\n const indexOf0InPowersOf10 = 323;\n return function(power: number) {\n return powersOf10[power + indexOf0InPowersOf10];\n };\n})();\n\n//tetration/slog to real height stuff\n//background info and tables of values for critical functions taken here: https://github.com/Patashu/break_eternity.js/issues/22\nconst critical_headers = [2, Math.E, 3, 4, 5, 6, 7, 8, 9, 10];\nconst critical_tetr_values = [\n [\n // Base 2\n 1,\n 1.0891168053867777,\n 1.1789745164521264,\n 1.2701428397304229,\n 1.3632066654400328,\n 1.4587804913784246,\n 1.557523817412741,\n 1.660158301473385,\n 1.767487542936873,\n 1.8804205225512542,\n 2\n ],\n [\n // Base E\n 1, //0.0\n 1.1121114330934, //0.1\n 1.23103892493161, //0.2\n 1.35838369631113, //0.3\n 1.49605193039935, //0.4\n 1.64635423375119, //0.5\n 1.81213853570186, //0.6\n 1.99697132461829, //0.7\n 2.20538955455724, //0.8\n 2.44325744833852, //0.9\n Math.E //1.0\n ],\n [\n // Base 3\n 1,\n 1.1187738849693603,\n 1.2464963939368214,\n 1.38527004705667,\n 1.5376664685821402,\n 1.7068895236551784,\n 1.897001227148399,\n 2.1132403089001035,\n 2.362480153784171,\n 2.6539010333870774,\n 3\n ],\n [\n // Base 4\n 1,\n 1.1367350847096405,\n 1.2889510672956703,\n 1.4606478703324786,\n 1.6570295196661111,\n 1.8850062585672889,\n 2.1539465047453485,\n 2.476829779693097,\n 2.872061932789197,\n 3.3664204535587183,\n 4\n ],\n [\n // Base 5\n 1,\n 1.1494592900767588,\n 1.319708228183931,\n 1.5166291280087583,\n 1.748171114438024,\n 2.0253263297298045,\n 2.3636668498288547,\n 2.7858359149579424,\n 3.3257226212448145,\n 4.035730287722532,\n 5\n ],\n [\n // Base 6\n 1,\n 1.159225940787673,\n 1.343712473580932,\n 1.5611293155111927,\n 1.8221199554561318,\n 2.14183924486326,\n 2.542468319282638,\n 3.0574682501653316,\n 3.7390572020926873,\n 4.6719550537360774,\n 6\n ],\n [\n // Base 7\n 1,\n 1.1670905356972596,\n 1.3632807444991446,\n 1.5979222279405536,\n 1.8842640123816674,\n 2.2416069644878687,\n 2.69893426559423,\n 3.3012632110403577,\n 4.121250340630164,\n 5.281493033448316,\n 7\n ],\n [\n // Base 8\n 1,\n 1.1736630594087796,\n 1.379783782386201,\n 1.6292821855668218,\n 1.9378971836180754,\n 2.3289975651071977,\n 2.8384347394720835,\n 3.5232708454565906,\n 4.478242031114584,\n 5.868592169644505,\n 8\n ],\n [\n // Base 9\n 1,\n 1.1793017514670474,\n 1.394054150657457,\n 1.65664127441059,\n 1.985170999970283,\n 2.4069682290577457,\n 2.9647310119960752,\n 3.7278665320924946,\n 4.814462547283592,\n 6.436522247411611,\n 9\n ],\n [\n // Base 10\n 1,\n 1.18422737399915,\n 1.4066113788546144,\n 1.680911177655277,\n 2.027492094355525,\n 2.4775152854601967,\n 3.080455730250329,\n 3.918234505962507,\n 5.1332705696484595,\n 6.9878696918072905,\n 10\n ]\n];\nconst critical_slog_values = [\n [\n // Base 2\n -1,\n -0.9194161097107025,\n -0.8335625019330468,\n -0.7425599821143978,\n -0.6466611521029437,\n -0.5462617907227869,\n -0.4419033816638769,\n -0.3342645487554494,\n -0.224140440909962,\n -0.11241087890006762,\n 0\n ],\n [\n // Base E\n -1, //0.0\n -0.90603157029014, //0.1\n -0.80786507256596, //0.2\n -0.7064666939634, //0.3\n -0.60294836853664, //0.4\n -0.49849837513117, //0.5\n -0.39430303318768, //0.6\n -0.29147201034755, //0.7\n -0.19097820800866, //0.8\n -0.09361896280296, //0.9\n 0 //1.0\n ],\n [\n // Base 3\n -1,\n -0.9021579584316141,\n -0.8005762598234203,\n -0.6964780623319391,\n -0.5911906810998454,\n -0.486050182576545,\n -0.3823089430815083,\n -0.28106046722897615,\n -0.1831906535795894,\n -0.08935809204418144,\n 0\n ],\n [\n // Base 4\n -1,\n -0.8917227442365535,\n -0.781258746326964,\n -0.6705130326902455,\n -0.5612813129406509,\n -0.4551067709033134,\n -0.35319256652135966,\n -0.2563741554088552,\n -0.1651412821106526,\n -0.0796919581982668,\n 0\n ],\n [\n // Base 5\n -1,\n -0.8843387974366064,\n -0.7678744063886243,\n -0.6529563724510552,\n -0.5415870994657841,\n -0.4352842206588936,\n -0.33504449124791424,\n -0.24138853420685147,\n -0.15445285440944467,\n -0.07409659641336663,\n 0\n ],\n [\n // Base 6\n -1,\n -0.8786709358426346,\n -0.7577735191184886,\n -0.6399546189952064,\n -0.527284921869926,\n -0.4211627631006314,\n -0.3223479611761232,\n -0.23107655627789858,\n -0.1472057700818259,\n -0.07035171210706326,\n 0\n ],\n [\n // Base 7\n -1,\n -0.8740862815291583,\n -0.7497032990976209,\n -0.6297119746181752,\n -0.5161838335958787,\n -0.41036238255751956,\n -0.31277212146489963,\n -0.2233976621705518,\n -0.1418697367979619,\n -0.06762117662323441,\n 0\n ],\n [\n // Base 8\n -1,\n -0.8702632331800649,\n -0.7430366914122081,\n -0.6213373075161548,\n -0.5072025698095242,\n -0.40171437727184167,\n -0.30517930701410456,\n -0.21736343968190863,\n -0.137710238299109,\n -0.06550774483471955,\n 0\n ],\n [\n // Base 9\n -1,\n -0.8670016295947213,\n -0.7373984232432306,\n -0.6143173985094293,\n -0.49973884395492807,\n -0.394584953527678,\n -0.2989649949848695,\n -0.21245647317021688,\n -0.13434688362382652,\n -0.0638072667348083,\n 0\n ],\n [\n // Base 10\n -1,\n -0.8641642839543857,\n -0.732534623168535,\n -0.6083127477059322,\n -0.4934049257184696,\n -0.3885773075899922,\n -0.29376029055315767,\n -0.2083678561173622,\n -0.13155653399373268,\n -0.062401588652553186,\n 0\n ]\n];\n\nconst D = function D(value: DecimalSource): Decimal {\n return Decimal.fromValue_noAlloc(value);\n};\n\nconst FC = function(sign: number, layer: number, mag: number) {\n return Decimal.fromComponents(sign, layer, mag);\n};\n\nconst FC_NN = function FC_NN(sign: number, layer: number, mag: number) {\n return Decimal.fromComponents_noNormalize(sign, layer, mag);\n};\n\nconst ME = function ME(mantissa: number, exponent: number) {\n return Decimal.fromMantissaExponent(mantissa, exponent);\n};\n\nconst ME_NN = function ME_NN(mantissa: number, exponent: number) {\n return Decimal.fromMantissaExponent_noNormalize(mantissa, exponent);\n};\n\nconst decimalPlaces = function decimalPlaces(value: number, places: number): number {\n const len = places + 1;\n const numDigits = Math.ceil(Math.log10(Math.abs(value)));\n const rounded =\n Math.round(value * Math.pow(10, len - numDigits)) * Math.pow(10, numDigits - len);\n return parseFloat(rounded.toFixed(Math.max(len - numDigits, 0)));\n};\n\nconst f_maglog10 = function(n: number) {\n return Math.sign(n) * Math.log10(Math.abs(n));\n};\n\n//from HyperCalc source code\nconst f_gamma = function(n: number) {\n if (!isFinite(n)) {\n return n;\n }\n if (n < -50) {\n if (n === Math.trunc(n)) {\n return Number.NEGATIVE_INFINITY;\n }\n return 0;\n }\n\n let scal1 = 1;\n while (n < 10) {\n scal1 = scal1 * n;\n ++n;\n }\n\n n -= 1;\n let l = 0.9189385332046727; //0.5*Math.log(2*Math.PI)\n l = l + (n + 0.5) * Math.log(n);\n l = l - n;\n const n2 = n * n;\n let np = n;\n l = l + 1 / (12 * np);\n np = np * n2;\n l = l + 1 / (360 * np);\n np = np * n2;\n l = l + 1 / (1260 * np);\n np = np * n2;\n l = l + 1 / (1680 * np);\n np = np * n2;\n l = l + 1 / (1188 * np);\n np = np * n2;\n l = l + 691 / (360360 * np);\n np = np * n2;\n l = l + 7 / (1092 * np);\n np = np * n2;\n l = l + 3617 / (122400 * np);\n\n return Math.exp(l) / scal1;\n};\n\nconst _twopi = 6.2831853071795864769252842; // 2*pi\nconst _EXPN1 = 0.36787944117144232159553; // exp(-1)\nconst OMEGA = 0.56714329040978387299997; // W(1, 0)\n//from https://math.stackexchange.com/a/465183\n// The evaluation can become inaccurate very close to the branch point\nconst f_lambertw = function(z: number, tol = 1e-10): number {\n let w;\n let wn;\n\n if (!Number.isFinite(z)) {\n return z;\n }\n if (z === 0) {\n return z;\n }\n if (z === 1) {\n return OMEGA;\n }\n\n if (z < 10) {\n w = 0;\n } else {\n w = Math.log(z) - Math.log(Math.log(z));\n }\n\n for (let i = 0; i < 100; ++i) {\n wn = (z * Math.exp(-w) + w * w) / (w + 1);\n if (Math.abs(wn - w) < tol * Math.abs(wn)) {\n return wn;\n } else {\n w = wn;\n }\n }\n\n throw Error(`Iteration failed to converge: ${z.toString()}`);\n //return Number.NaN;\n};\n\n//from https://github.com/scipy/scipy/blob/8dba340293fe20e62e173bdf2c10ae208286692f/scipy/special/lambertw.pxd\n// The evaluation can become inaccurate very close to the branch point\n// at ``-1/e``. In some corner cases, `lambertw` might currently\n// fail to converge, or can end up on the wrong branch.\nfunction d_lambertw(z: Decimal, tol = 1e-10): Decimal {\n let w;\n let ew, wew, wewz, wn;\n\n if (!Number.isFinite(z.mag)) {\n return z;\n }\n if (z === Decimal.dZero) {\n return z;\n }\n if (z === Decimal.dOne) {\n //Split out this case because the asymptotic series blows up\n return D(OMEGA);\n }\n\n const absz = Decimal.abs(z);\n //Get an initial guess for Halley's method\n w = Decimal.ln(z);\n\n //Halley's method; see 5.9 in [1]\n\n for (let i = 0; i < 100; ++i) {\n ew = Decimal.exp(-w);\n wewz = w.sub(z.mul(ew));\n wn = w.sub(\n wewz.div(\n w.add(1).sub(\n w\n .add(2)\n .mul(wewz)\n .div(Decimal.mul(2, w).add(2))\n )\n )\n );\n if (Decimal.abs(wn.sub(w)).lt(Decimal.abs(wn).mul(tol))) {\n return wn;\n } else {\n w = wn;\n }\n }\n\n throw Error(`Iteration failed to converge: ${z.toString()}`);\n //return Decimal.dNaN;\n}\n\nexport type DecimalSource = Decimal | number | string;\n\n/**\n * The Decimal's value is simply mantissa * 10^exponent.\n */\nexport default class Decimal {\n public static readonly dZero = FC_NN(0, 0, 0);\n public static readonly dOne = FC_NN(1, 0, 1);\n public static readonly dNegOne = FC_NN(-1, 0, 1);\n public static readonly dTwo = FC_NN(1, 0, 2);\n public static readonly dTen = FC_NN(1, 0, 10);\n public static readonly dNaN = FC_NN(Number.NaN, Number.NaN, Number.NaN);\n public static readonly dInf = FC_NN(1, Number.POSITIVE_INFINITY, Number.POSITIVE_INFINITY);\n public static readonly dNegInf = FC_NN(-1, Number.NEGATIVE_INFINITY, Number.NEGATIVE_INFINITY);\n public static readonly dNumberMax = FC(1, 0, Number.MAX_VALUE);\n public static readonly dNumberMin = FC(1, 0, Number.MIN_VALUE);\n\n public sign: number = Number.NaN;\n public mag: number = Number.NaN;\n public layer: number = Number.NaN;\n\n constructor(value?: DecimalSource) {\n if (value instanceof Decimal || (value != null && typeof value === \"object\" && \"sign\" in value && \"mag\" in value && \"layer\" in value)) {\n this.fromDecimal(value);\n } else if (typeof value === \"number\") {\n this.fromNumber(value);\n } else if (typeof value === \"string\") {\n this.fromString(value);\n } else {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n }\n }\n\n get m(): number {\n if (this.sign === 0) {\n return 0;\n } else if (this.layer === 0) {\n const exp = Math.floor(Math.log10(this.mag));\n //handle special case 5e-324\n let man;\n if (this.mag === 5e-324) {\n man = 5;\n } else {\n man = this.mag / powerOf10(exp);\n }\n return this.sign * man;\n } else if (this.layer === 1) {\n const residue = this.mag - Math.floor(this.mag);\n return this.sign * Math.pow(10, residue);\n } else {\n //mantissa stops being relevant past 1e9e15 / ee15.954\n return this.sign;\n }\n }\n\n set m(value: number) {\n if (this.layer <= 2) {\n this.fromMantissaExponent(value, this.e);\n } else {\n //don't even pretend mantissa is meaningful\n this.sign = Math.sign(value);\n if (this.sign === 0) {\n this.layer === 0;\n this.exponent === 0;\n }\n }\n }\n\n get e(): number {\n if (this.sign === 0) {\n return 0;\n } else if (this.layer === 0) {\n return Math.floor(Math.log10(this.mag));\n } else if (this.layer === 1) {\n return Math.floor(this.mag);\n } else if (this.layer === 2) {\n return Math.floor(Math.sign(this.mag) * Math.pow(10, Math.abs(this.mag)));\n } else {\n return this.mag * Number.POSITIVE_INFINITY;\n }\n }\n set e(value: number) {\n this.fromMantissaExponent(this.m, value);\n }\n\n get s(): number {\n return this.sign;\n }\n set s(value: number) {\n if (value === 0) {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n } else {\n this.sign = value;\n }\n }\n\n // Object.defineProperty(Decimal.prototype, \"mantissa\", {\n get mantissa(): number {\n return this.m;\n }\n\n set mantissa(value: number) {\n this.m = value;\n }\n\n get exponent(): number {\n return this.e;\n }\n set exponent(value: number) {\n this.e = value;\n }\n\n public static fromComponents(sign: number, layer: number, mag: number): Decimal {\n return new Decimal().fromComponents(sign, layer, mag);\n }\n\n public static fromComponents_noNormalize(sign: number, layer: number, mag: number): Decimal {\n return new Decimal().fromComponents_noNormalize(sign, layer, mag);\n }\n\n public static fromMantissaExponent(mantissa: number, exponent: number): Decimal {\n return new Decimal().fromMantissaExponent(mantissa, exponent);\n }\n\n public static fromMantissaExponent_noNormalize(mantissa: number, exponent: number): Decimal {\n return new Decimal().fromMantissaExponent_noNormalize(mantissa, exponent);\n }\n\n public static fromDecimal(value: Decimal): Decimal {\n return new Decimal().fromDecimal(value);\n }\n\n public static fromNumber(value: number): Decimal {\n return new Decimal().fromNumber(value);\n }\n\n public static fromString(value: string): Decimal {\n return new Decimal().fromString(value);\n }\n\n public static fromValue(value: DecimalSource): Decimal {\n return new Decimal().fromValue(value);\n }\n\n public static fromValue_noAlloc(value: DecimalSource): Decimal {\n return value instanceof Decimal ? value : new Decimal(value);\n }\n\n public static abs(value: DecimalSource): Decimal {\n return D(value).abs();\n }\n\n public static neg(value: DecimalSource): Decimal {\n return D(value).neg();\n }\n\n public static negate(value: DecimalSource): Decimal {\n return D(value).neg();\n }\n\n public static negated(value: DecimalSource): Decimal {\n return D(value).neg();\n }\n\n public static sign(value: DecimalSource): number {\n return D(value).sign;\n }\n\n public static sgn(value: DecimalSource): number {\n return D(value).sign;\n }\n\n public static round(value: DecimalSource): Decimal {\n return D(value).round();\n }\n\n public static floor(value: DecimalSource): Decimal {\n return D(value).floor();\n }\n\n public static ceil(value: DecimalSource): Decimal {\n return D(value).ceil();\n }\n\n public static trunc(value: DecimalSource): Decimal {\n return D(value).trunc();\n }\n\n public static add(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).add(other);\n }\n\n public static plus(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).add(other);\n }\n\n public static sub(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).sub(other);\n }\n\n public static subtract(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).sub(other);\n }\n\n public static minus(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).sub(other);\n }\n\n public static mul(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).mul(other);\n }\n\n public static multiply(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).mul(other);\n }\n\n public static times(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).mul(other);\n }\n\n public static div(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).div(other);\n }\n\n public static divide(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).div(other);\n }\n\n public static recip(value: DecimalSource): Decimal {\n return D(value).recip();\n }\n\n public static reciprocal(value: DecimalSource): Decimal {\n return D(value).recip();\n }\n\n public static reciprocate(value: DecimalSource): Decimal {\n return D(value).reciprocate();\n }\n\n public static cmp(value: DecimalSource, other: DecimalSource): CompareResult {\n return D(value).cmp(other);\n }\n\n public static cmpabs(value: DecimalSource, other: DecimalSource): CompareResult {\n return D(value).cmpabs(other);\n }\n\n public static compare(value: DecimalSource, other: DecimalSource): CompareResult {\n return D(value).cmp(other);\n }\n\n public static isNaN(value: DecimalSource): boolean {\n value = D(value);\n return isNaN(value.sign) || isNaN(value.layer) || isNaN(value.mag);\n }\n\n public static isFinite(value: DecimalSource): boolean {\n value = D(value);\n return isFinite(value.sign) && isFinite(value.layer) && isFinite(value.mag);\n }\n\n public static eq(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).eq(other);\n }\n\n public static equals(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).eq(other);\n }\n\n public static neq(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).neq(other);\n }\n\n public static notEquals(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).notEquals(other);\n }\n\n public static lt(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).lt(other);\n }\n\n public static lte(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).lte(other);\n }\n\n public static gt(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).gt(other);\n }\n\n public static gte(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).gte(other);\n }\n\n public static max(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).max(other);\n }\n\n public static min(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).min(other);\n }\n\n public static minabs(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).minabs(other);\n }\n\n public static maxabs(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).maxabs(other);\n }\n\n public static clamp(value: DecimalSource, min: DecimalSource, max: DecimalSource): Decimal {\n return D(value).clamp(min, max);\n }\n\n public static clampMin(value: DecimalSource, min: DecimalSource): Decimal {\n return D(value).clampMin(min);\n }\n\n public static clampMax(value: DecimalSource, max: DecimalSource): Decimal {\n return D(value).clampMax(max);\n }\n\n public static cmp_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): CompareResult {\n return D(value).cmp_tolerance(other, tolerance);\n }\n\n public static compare_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): CompareResult {\n return D(value).cmp_tolerance(other, tolerance);\n }\n\n public static eq_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).eq_tolerance(other, tolerance);\n }\n\n public static equals_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).eq_tolerance(other, tolerance);\n }\n\n public static neq_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).neq_tolerance(other, tolerance);\n }\n\n public static notEquals_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).notEquals_tolerance(other, tolerance);\n }\n\n public static lt_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).lt_tolerance(other, tolerance);\n }\n\n public static lte_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).lte_tolerance(other, tolerance);\n }\n\n public static gt_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).gt_tolerance(other, tolerance);\n }\n\n public static gte_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).gte_tolerance(other, tolerance);\n }\n\n public static pLog10(value: DecimalSource): Decimal {\n return D(value).pLog10();\n }\n\n public static absLog10(value: DecimalSource): Decimal {\n return D(value).absLog10();\n }\n\n public static log10(value: DecimalSource): Decimal {\n return D(value).log10();\n }\n\n public static log(value: DecimalSource, base: DecimalSource): Decimal {\n return D(value).log(base);\n }\n\n public static log2(value: DecimalSource): Decimal {\n return D(value).log2();\n }\n\n public static ln(value: DecimalSource): Decimal {\n return D(value).ln();\n }\n\n public static logarithm(value: DecimalSource, base: DecimalSource): Decimal {\n return D(value).logarithm(base);\n }\n\n public static pow(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).pow(other);\n }\n\n public static pow10(value: DecimalSource): Decimal {\n return D(value).pow10();\n }\n\n public static root(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).root(other);\n }\n\n public static factorial(value: DecimalSource, _other?: never): Decimal {\n return D(value).factorial();\n }\n\n public static gamma(value: DecimalSource, _other?: never): Decimal {\n return D(value).gamma();\n }\n\n public static lngamma(value: DecimalSource, _other?: never): Decimal {\n return D(value).lngamma();\n }\n\n public static exp(value: DecimalSource): Decimal {\n return D(value).exp();\n }\n\n public static sqr(value: DecimalSource): Decimal {\n return D(value).sqr();\n }\n\n public static sqrt(value: DecimalSource): Decimal {\n return D(value).sqrt();\n }\n\n public static cube(value: DecimalSource): Decimal {\n return D(value).cube();\n }\n\n public static cbrt(value: DecimalSource): Decimal {\n return D(value).cbrt();\n }\n\n public static tetrate(\n value: DecimalSource,\n height = 2,\n payload: DecimalSource = FC_NN(1, 0, 1)\n ): Decimal {\n return D(value).tetrate(height, payload);\n }\n\n public static iteratedexp(value: DecimalSource, height = 2, payload = FC_NN(1, 0, 1)): Decimal {\n return D(value).iteratedexp(height, payload);\n }\n\n public static iteratedlog(value: DecimalSource, base: DecimalSource = 10, times = 1): Decimal {\n return D(value).iteratedlog(base, times);\n }\n\n public static layeradd10(value: DecimalSource, diff: DecimalSource): Decimal {\n return D(value).layeradd10(diff);\n }\n\n public static layeradd(value: DecimalSource, diff: number, base = 10): Decimal {\n return D(value).layeradd(diff, base);\n }\n\n public static slog(value: DecimalSource, base = 10): Decimal {\n return D(value).slog(base);\n }\n\n public static lambertw(value: DecimalSource): Decimal {\n return D(value).lambertw();\n }\n\n public static ssqrt(value: DecimalSource): Decimal {\n return D(value).ssqrt();\n }\n\n public static pentate(\n value: DecimalSource,\n height = 2,\n payload: DecimalSource = FC_NN(1, 0, 1)\n ): Decimal {\n return D(value).pentate(height, payload);\n }\n\n /**\n * If you're willing to spend 'resourcesAvailable' and want to buy something\n * with exponentially increasing cost each purchase (start at priceStart,\n * multiply by priceRatio, already own currentOwned), how much of it can you buy?\n * Adapted from Trimps source code.\n */\n\n public static affordGeometricSeries(\n resourcesAvailable: DecimalSource,\n priceStart: DecimalSource,\n priceRatio: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.affordGeometricSeries_core(\n D(resourcesAvailable),\n D(priceStart),\n D(priceRatio),\n currentOwned\n );\n }\n /**\n * How much resource would it cost to buy (numItems) items if you already have currentOwned,\n * the initial price is priceStart and it multiplies by priceRatio each purchase?\n */\n\n public static sumGeometricSeries(\n numItems: DecimalSource,\n priceStart: DecimalSource,\n priceRatio: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.sumGeometricSeries_core(numItems, D(priceStart), D(priceRatio), currentOwned);\n }\n /**\n * If you're willing to spend 'resourcesAvailable' and want to buy something with additively\n * increasing cost each purchase (start at priceStart, add by priceAdd, already own currentOwned),\n * how much of it can you buy?\n */\n\n public static affordArithmeticSeries(\n resourcesAvailable: DecimalSource,\n priceStart: DecimalSource,\n priceAdd: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.affordArithmeticSeries_core(\n D(resourcesAvailable),\n D(priceStart),\n D(priceAdd),\n D(currentOwned)\n );\n }\n /**\n * How much resource would it cost to buy (numItems) items if you already have currentOwned,\n * the initial price is priceStart and it adds priceAdd each purchase?\n * Adapted from http://www.mathwords.com/a/arithmetic_series.htm\n */\n\n public static sumArithmeticSeries(\n numItems: DecimalSource,\n priceStart: DecimalSource,\n priceAdd: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.sumArithmeticSeries_core(\n D(numItems),\n D(priceStart),\n D(priceAdd),\n D(currentOwned)\n );\n }\n /**\n * When comparing two purchases that cost (resource) and increase your resource/sec by (deltaRpS),\n * the lowest efficiency score is the better one to purchase.\n * From Frozen Cookies:\n * http://cookieclicker.wikia.com/wiki/Frozen_Cookies_(JavaScript_Add-on)#Efficiency.3F_What.27s_that.3F\n */\n\n public static efficiencyOfPurchase(\n cost: DecimalSource,\n currentRpS: DecimalSource,\n deltaRpS: DecimalSource\n ): Decimal {\n return this.efficiencyOfPurchase_core(D(cost), D(currentRpS), D(deltaRpS));\n }\n\n public static randomDecimalForTesting(maxLayers: number): Decimal {\n // NOTE: This doesn't follow any kind of sane random distribution, so use this for testing purposes only.\n //5% of the time, return 0\n if (Math.random() * 20 < 1) {\n return FC_NN(0, 0, 0);\n }\n\n const randomsign = Math.random() > 0.5 ? 1 : -1;\n\n //5% of the time, return 1 or -1\n if (Math.random() * 20 < 1) {\n return FC_NN(randomsign, 0, 1);\n }\n\n //pick a random layer\n const layer = Math.floor(Math.random() * (maxLayers + 1));\n\n let randomexp = layer === 0 ? Math.random() * 616 - 308 : Math.random() * 16;\n //10% of the time, make it a simple power of 10\n if (Math.random() > 0.9) {\n randomexp = Math.trunc(randomexp);\n }\n let randommag = Math.pow(10, randomexp);\n //10% of the time, trunc mag\n if (Math.random() > 0.9) {\n randommag = Math.trunc(randommag);\n }\n return FC(randomsign, layer, randommag);\n }\n\n public static affordGeometricSeries_core(\n resourcesAvailable: Decimal,\n priceStart: Decimal,\n priceRatio: Decimal,\n currentOwned: DecimalSource\n ): Decimal {\n const actualStart = priceStart.mul(priceRatio.pow(currentOwned));\n return Decimal.floor(\n resourcesAvailable\n .div(actualStart)\n .mul(priceRatio.sub(1))\n .add(1)\n .log10()\n .div(priceRatio.log10())\n );\n }\n\n public static sumGeometricSeries_core(\n numItems: DecimalSource,\n priceStart: Decimal,\n priceRatio: Decimal,\n currentOwned: DecimalSource\n ): Decimal {\n return priceStart\n .mul(priceRatio.pow(currentOwned))\n .mul(Decimal.sub(1, priceRatio.pow(numItems)))\n .div(Decimal.sub(1, priceRatio));\n }\n\n public static affordArithmeticSeries_core(\n resourcesAvailable: Decimal,\n priceStart: Decimal,\n priceAdd: Decimal,\n currentOwned: Decimal\n ): Decimal {\n // n = (-(a-d/2) + sqrt((a-d/2)^2+2dS))/d\n // where a is actualStart, d is priceAdd and S is resourcesAvailable\n // then floor it and you're done!\n const actualStart = priceStart.add(currentOwned.mul(priceAdd));\n const b = actualStart.sub(priceAdd.div(2));\n const b2 = b.pow(2);\n return b\n .neg()\n .add(b2.add(priceAdd.mul(resourcesAvailable).mul(2)).sqrt())\n .div(priceAdd)\n .floor();\n }\n\n public static sumArithmeticSeries_core(\n numItems: Decimal,\n priceStart: Decimal,\n priceAdd: Decimal,\n currentOwned: Decimal\n ): Decimal {\n const actualStart = priceStart.add(currentOwned.mul(priceAdd)); // (n/2)*(2*a+(n-1)*d)\n\n return numItems.div(2).mul(actualStart.mul(2).plus(numItems.sub(1).mul(priceAdd)));\n }\n\n public static efficiencyOfPurchase_core(\n cost: Decimal,\n currentRpS: Decimal,\n deltaRpS: Decimal\n ): Decimal {\n return cost.div(currentRpS).add(cost.div(deltaRpS));\n }\n\n public [Symbol.for(\"+\")](other: DecimalSource): DecimalSource {\n return this.add(other);\n }\n\n public [Symbol.for(\"-\")](other: DecimalSource): DecimalSource {\n return this.sub(other);\n }\n\n public [Symbol.for(\"*\")](other: DecimalSource): DecimalSource {\n return this.times(other);\n }\n\n public [Symbol.for(\"/\")](other: DecimalSource): DecimalSource {\n return this.div(other);\n }\n\n public [Symbol.for(\"minus\")](): DecimalSource {\n return this.neg();\n }\n\n public [Symbol.for(\"==\")](other: DecimalSource): boolean {\n return this.eq(other);\n }\n\n public [Symbol.for(\">\")](other: DecimalSource): boolean {\n return this.gt(other);\n }\n\n public [Symbol.for(\"<\")](other: DecimalSource): boolean {\n return this.lt(other);\n }\n\n public [Symbol.for(\">=\")](other: DecimalSource): boolean {\n return this.gte(other);\n }\n\n public [Symbol.for(\"<=\")](other: DecimalSource): boolean {\n return this.lte(other);\n }\n\n public [Symbol.for(\"!=\")](other: DecimalSource): boolean {\n return this.neq(other);\n }\n\n public normalize(): this {\n /*\n PSEUDOCODE:\n Whenever we are partially 0 (sign is 0 or mag and layer is 0), make it fully 0.\n Whenever we are at or hit layer 0, extract sign from negative mag.\n If layer === 0 and mag < FIRST_NEG_LAYER (1/9e15), shift to 'first negative layer' (add layer, log10 mag).\n While abs(mag) > EXP_LIMIT (9e15), layer += 1, mag = maglog10(mag).\n While abs(mag) < LAYER_DOWN (15.954) and layer > 0, layer -= 1, mag = pow(10, mag).\n\n When we're done, all of the following should be true OR one of the numbers is not IsFinite OR layer is not IsInteger (error state):\n Any 0 is totally zero (0, 0, 0).\n Anything layer 0 has mag 0 OR mag > 1/9e15 and < 9e15.\n Anything layer 1 or higher has abs(mag) >= 15.954 and < 9e15.\n We will assume in calculations that all Decimals are either erroneous or satisfy these criteria. (Otherwise: Garbage in, garbage out.)\n */\n if (this.sign === 0 || (this.mag === 0 && this.layer === 0)) {\n this.sign = 0;\n this.mag = 0;\n this.layer = 0;\n return this;\n }\n\n if (this.layer === 0 && this.mag < 0) {\n //extract sign from negative mag at layer 0\n this.mag = -this.mag;\n this.sign = -this.sign;\n }\n\n //Handle shifting from layer 0 to negative layers.\n if (this.layer === 0 && this.mag < FIRST_NEG_LAYER) {\n this.layer += 1;\n this.mag = Math.log10(this.mag);\n return this;\n }\n\n let absmag = Math.abs(this.mag);\n let signmag = Math.sign(this.mag);\n\n if (absmag >= EXP_LIMIT) {\n this.layer += 1;\n this.mag = signmag * Math.log10(absmag);\n return this;\n } else {\n while (absmag < LAYER_DOWN && this.layer > 0) {\n this.layer -= 1;\n if (this.layer === 0) {\n this.mag = Math.pow(10, this.mag);\n } else {\n this.mag = signmag * Math.pow(10, absmag);\n absmag = Math.abs(this.mag);\n signmag = Math.sign(this.mag);\n }\n }\n if (this.layer === 0) {\n if (this.mag < 0) {\n //extract sign from negative mag at layer 0\n this.mag = -this.mag;\n this.sign = -this.sign;\n } else if (this.mag === 0) {\n //excessive rounding can give us all zeroes\n this.sign = 0;\n }\n }\n }\n\n return this;\n }\n\n public fromComponents(sign: number, layer: number, mag: number): this {\n this.sign = sign;\n this.layer = layer;\n this.mag = mag;\n\n this.normalize();\n return this;\n }\n\n public fromComponents_noNormalize(sign: number, layer: number, mag: number): this {\n this.sign = sign;\n this.layer = layer;\n this.mag = mag;\n return this;\n }\n\n public fromMantissaExponent(mantissa: number, exponent: number): this {\n this.layer = 1;\n this.sign = Math.sign(mantissa);\n mantissa = Math.abs(mantissa);\n this.mag = exponent + Math.log10(mantissa);\n\n this.normalize();\n return this;\n }\n\n public fromMantissaExponent_noNormalize(mantissa: number, exponent: number): this {\n //The idea of 'normalizing' a break_infinity.js style Decimal doesn't really apply. So just do the same thing.\n this.fromMantissaExponent(mantissa, exponent);\n return this;\n }\n\n public fromDecimal(value: Decimal): this {\n this.sign = value.sign;\n this.layer = value.layer;\n this.mag = value.mag;\n return this;\n }\n\n public fromNumber(value: number): this {\n this.mag = Math.abs(value);\n this.sign = Math.sign(value);\n this.layer = 0;\n this.normalize();\n return this;\n }\n\n public fromString(value: string): Decimal {\n if (IGNORE_COMMAS) {\n value = value.replace(\",\", \"\");\n } else if (COMMAS_ARE_DECIMAL_POINTS) {\n value = value.replace(\",\", \".\");\n }\n\n //Handle x^^^y format.\n const pentationparts = value.split(\"^^^\");\n if (pentationparts.length === 2) {\n const base = parseFloat(pentationparts[0]);\n const height = parseFloat(pentationparts[1]);\n const heightparts = pentationparts[1].split(\";\");\n let payload = 1;\n if (heightparts.length === 2) {\n payload = parseFloat(heightparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.pentate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //Handle x^^y format.\n const tetrationparts = value.split(\"^^\");\n if (tetrationparts.length === 2) {\n const base = parseFloat(tetrationparts[0]);\n const height = parseFloat(tetrationparts[1]);\n const heightparts = tetrationparts[1].split(\";\");\n let payload = 1;\n if (heightparts.length === 2) {\n payload = parseFloat(heightparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.tetrate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //Handle x^y format.\n const powparts = value.split(\"^\");\n if (powparts.length === 2) {\n const base = parseFloat(powparts[0]);\n const exponent = parseFloat(powparts[1]);\n if (isFinite(base) && isFinite(exponent)) {\n const result = Decimal.pow(base, exponent);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //Handle various cases involving it being a Big Number.\n value = value.trim().toLowerCase();\n\n //handle X PT Y format.\n let base;\n let height;\n let ptparts = value.split(\"pt\");\n if (ptparts.length === 2) {\n base = 10;\n height = parseFloat(ptparts[0]);\n ptparts[1] = ptparts[1].replace(\"(\", \"\");\n ptparts[1] = ptparts[1].replace(\")\", \"\");\n let payload = parseFloat(ptparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.tetrate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //handle XpY format (it's the same thing just with p).\n ptparts = value.split(\"p\");\n if (ptparts.length === 2) {\n base = 10;\n height = parseFloat(ptparts[0]);\n ptparts[1] = ptparts[1].replace(\"(\", \"\");\n ptparts[1] = ptparts[1].replace(\")\", \"\");\n let payload = parseFloat(ptparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.tetrate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n const parts = value.split(\"e\");\n const ecount = parts.length - 1;\n\n //Handle numbers that are exactly floats (0 or 1 es).\n if (ecount === 0) {\n const numberAttempt = parseFloat(value);\n if (isFinite(numberAttempt)) {\n return this.fromNumber(numberAttempt);\n }\n } else if (ecount === 1) {\n //Very small numbers (\"2e-3000\" and so on) may look like valid floats but round to 0.\n const numberAttempt = parseFloat(value);\n if (isFinite(numberAttempt) && numberAttempt !== 0) {\n return this.fromNumber(numberAttempt);\n }\n }\n\n //Handle new (e^N)X format.\n const newparts = value.split(\"e^\");\n if (newparts.length === 2) {\n this.sign = 1;\n if (newparts[0].charAt(0) == \"-\") {\n this.sign = -1;\n }\n let layerstring = \"\";\n for (let i = 0; i < newparts[1].length; ++i) {\n const chrcode = newparts[1].charCodeAt(i);\n if ((chrcode >= 43 && chrcode <= 57) || chrcode === 101) {\n //is \"0\" to \"9\" or \"+\" or \"-\" or \".\" or \"e\" (or \",\" or \"/\")\n layerstring += newparts[1].charAt(i);\n } //we found the end of the layer count\n else {\n this.layer = parseFloat(layerstring);\n this.mag = parseFloat(newparts[1].substr(i + 1));\n this.normalize();\n return this;\n }\n }\n }\n\n if (ecount < 1) {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n return this;\n }\n const mantissa = parseFloat(parts[0]);\n if (mantissa === 0) {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n return this;\n }\n let exponent = parseFloat(parts[parts.length - 1]);\n //handle numbers like AeBeC and AeeeeBeC\n if (ecount >= 2) {\n const me = parseFloat(parts[parts.length - 2]);\n if (isFinite(me)) {\n exponent *= Math.sign(me);\n exponent += f_maglog10(me);\n }\n }\n\n //Handle numbers written like eee... (N es) X\n if (!isFinite(mantissa)) {\n this.sign = parts[0] === \"-\" ? -1 : 1;\n this.layer = ecount;\n this.mag = exponent;\n }\n //Handle numbers written like XeY\n else if (ecount === 1) {\n this.sign = Math.sign(mantissa);\n this.layer = 1;\n //Example: 2e10 is equal to 10^log10(2e10) which is equal to 10^(10+log10(2))\n this.mag = exponent + Math.log10(Math.abs(mantissa));\n }\n //Handle numbers written like Xeee... (N es) Y\n else {\n this.sign = Math.sign(mantissa);\n this.layer = ecount;\n if (ecount === 2) {\n const result = Decimal.mul(FC(1, 2, exponent), D(mantissa));\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n } else {\n //at eee and above, mantissa is too small to be recognizable!\n this.mag = exponent;\n }\n }\n\n this.normalize();\n return this;\n }\n\n public fromValue(value: DecimalSource): Decimal {\n if (value instanceof Decimal || (value != null && typeof value === \"object\" && \"sign\" in value && \"mag\" in value && \"layer\" in value)) {\n return this.fromDecimal(value);\n }\n\n if (typeof value === \"number\") {\n return this.fromNumber(value);\n }\n\n if (typeof value === \"string\") {\n return this.fromString(value);\n }\n\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n return this;\n }\n\n public toNumber(): number {\n if (!Number.isFinite(this.layer)) {\n return Number.NaN;\n }\n if (this.layer === 0) {\n return this.sign * this.mag;\n } else if (this.layer === 1) {\n return this.sign * Math.pow(10, this.mag);\n } //overflow for any normalized Decimal\n else {\n return this.mag > 0\n ? this.sign > 0\n ? Number.POSITIVE_INFINITY\n : Number.NEGATIVE_INFINITY\n : 0;\n }\n }\n\n public mantissaWithDecimalPlaces(places: number): number {\n // https://stackoverflow.com/a/37425022\n if (isNaN(this.m)) {\n return Number.NaN;\n }\n\n if (this.m === 0) {\n return 0;\n }\n\n return decimalPlaces(this.m, places);\n }\n\n public magnitudeWithDecimalPlaces(places: number): number {\n // https://stackoverflow.com/a/37425022\n if (isNaN(this.mag)) {\n return Number.NaN;\n }\n\n if (this.mag === 0) {\n return 0;\n }\n\n return decimalPlaces(this.mag, places);\n }\n\n public toString(): string {\n if (isNaN(this.layer) || isNaN(this.sign) || isNaN(this.mag)) {\n return \"NaN\";\n }\n if (this.mag === Number.POSITIVE_INFINITY || this.layer === Number.POSITIVE_INFINITY) {\n return this.sign === 1 ? \"Infinity\" : \"-Infinity\";\n }\n\n if (this.layer === 0) {\n if ((this.mag < 1e21 && this.mag > 1e-7) || this.mag === 0) {\n return (this.sign * this.mag).toString();\n }\n return this.m + \"e\" + this.e;\n } else if (this.layer === 1) {\n return this.m + \"e\" + this.e;\n } else {\n //layer 2+\n if (this.layer <= MAX_ES_IN_A_ROW) {\n return (this.sign === -1 ? \"-\" : \"\") + \"e\".repeat(this.layer) + this.mag;\n } else {\n return (this.sign === -1 ? \"-\" : \"\") + \"(e^\" + this.layer + \")\" + this.mag;\n }\n }\n }\n\n public toExponential(places: number): string {\n if (this.layer === 0) {\n return (this.sign * this.mag).toExponential(places);\n }\n return this.toStringWithDecimalPlaces(places);\n }\n\n public toFixed(places: number): string {\n if (this.layer === 0) {\n return (this.sign * this.mag).toFixed(places);\n }\n return this.toStringWithDecimalPlaces(places);\n }\n\n public toPrecision(places: number): string {\n if (this.e <= -7) {\n return this.toExponential(places - 1);\n }\n\n if (places > this.e) {\n return this.toFixed(places - this.exponent - 1);\n }\n\n return this.toExponential(places - 1);\n }\n\n public valueOf(): string {\n return this.toString();\n }\n\n public toJSON(): string {\n return this.toString();\n }\n\n public toStringWithDecimalPlaces(places: number): string {\n if (this.layer === 0) {\n if ((this.mag < 1e21 && this.mag > 1e-7) || this.mag === 0) {\n return (this.sign * this.mag).toFixed(places);\n }\n return decimalPlaces(this.m, places) + \"e\" + decimalPlaces(this.e, places);\n } else if (this.layer === 1) {\n return decimalPlaces(this.m, places) + \"e\" + decimalPlaces(this.e, places);\n } else {\n //layer 2+\n if (this.layer <= MAX_ES_IN_A_ROW) {\n return (\n (this.sign === -1 ? \"-\" : \"\") +\n \"e\".repeat(this.layer) +\n decimalPlaces(this.mag, places)\n );\n } else {\n return (\n (this.sign === -1 ? \"-\" : \"\") +\n \"(e^\" +\n this.layer +\n \")\" +\n decimalPlaces(this.mag, places)\n );\n }\n }\n }\n\n public abs(): Decimal {\n return FC_NN(this.sign === 0 ? 0 : 1, this.layer, this.mag);\n }\n\n public neg(): Decimal {\n return FC_NN(-this.sign, this.layer, this.mag);\n }\n\n public negate(): Decimal {\n return this.neg();\n }\n\n public negated(): Decimal {\n return this.neg();\n }\n\n // public sign () {\n // return this.sign;\n // }\n\n public sgn(): number {\n return this.sign;\n }\n\n public round(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.round(this.mag));\n }\n return this;\n }\n\n public floor(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.floor(this.mag));\n }\n return this;\n }\n\n public ceil(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.ceil(this.mag));\n }\n return this;\n }\n\n public trunc(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.trunc(this.mag));\n }\n return this;\n }\n\n public add(value: DecimalSource): this | Decimal {\n const decimal = D(value);\n\n //inf/nan check\n if (!Number.isFinite(this.layer)) {\n return this;\n }\n if (!Number.isFinite(decimal.layer)) {\n return decimal;\n }\n\n //Special case - if one of the numbers is 0, return the other number.\n if (this.sign === 0) {\n return decimal;\n }\n if (decimal.sign === 0) {\n return this;\n }\n\n //Special case - Adding a number to its negation produces 0, no matter how large.\n if (\n this.sign === -decimal.sign &&\n this.layer === decimal.layer &&\n this.mag === decimal.mag\n ) {\n return FC_NN(0, 0, 0);\n }\n\n let a;\n let b;\n\n //Special case: If one of the numbers is layer 2 or higher, just take the bigger number.\n if (this.layer >= 2 || decimal.layer >= 2) {\n return this.maxabs(decimal);\n }\n\n if (Decimal.cmpabs(this, decimal) > 0) {\n a = this;\n b = decimal;\n } else {\n a = decimal;\n b = this;\n }\n\n if (a.layer === 0 && b.layer === 0) {\n return D(a.sign * a.mag + b.sign * b.mag);\n }\n\n const layera = a.layer * Math.sign(a.mag);\n const layerb = b.layer * Math.sign(b.mag);\n\n //If one of the numbers is 2+ layers higher than the other, just take the bigger number.\n if (layera - layerb >= 2) {\n return a;\n }\n\n if (layera === 0 && layerb === -1) {\n if (Math.abs(b.mag - Math.log10(a.mag)) > MAX_SIGNIFICANT_DIGITS) {\n return a;\n } else {\n const magdiff = Math.pow(10, Math.log10(a.mag) - b.mag);\n const mantissa = b.sign + a.sign * magdiff;\n return FC(Math.sign(mantissa), 1, b.mag + Math.log10(Math.abs(mantissa)));\n }\n }\n\n if (layera === 1 && layerb === 0) {\n if (Math.abs(a.mag - Math.log10(b.mag)) > MAX_SIGNIFICANT_DIGITS) {\n return a;\n } else {\n const magdiff = Math.pow(10, a.mag - Math.log10(b.mag));\n const mantissa = b.sign + a.sign * magdiff;\n return FC(\n Math.sign(mantissa),\n 1,\n Math.log10(b.mag) + Math.log10(Math.abs(mantissa))\n );\n }\n }\n\n if (Math.abs(a.mag - b.mag) > MAX_SIGNIFICANT_DIGITS) {\n return a;\n } else {\n const magdiff = Math.pow(10, a.mag - b.mag);\n const mantissa = b.sign + a.sign * magdiff;\n return FC(Math.sign(mantissa), 1, b.mag + Math.log10(Math.abs(mantissa)));\n }\n\n throw Error(\"Bad arguments to add: \" + this + \", \" + value);\n }\n\n public plus(value: DecimalSource): Decimal {\n return this.add(value);\n }\n\n public sub(value: DecimalSource): Decimal {\n return this.add(D(value).neg());\n }\n\n public subtract(value: DecimalSource): Decimal {\n return this.sub(value);\n }\n\n public minus(value: DecimalSource): Decimal {\n return this.sub(value);\n }\n\n public mul(value: DecimalSource): Decimal {\n const decimal = D(value);\n\n //inf/nan check\n if (!Number.isFinite(this.layer)) {\n return this;\n }\n if (!Number.isFinite(decimal.layer)) {\n return decimal;\n }\n\n //Special case - if one of the numbers is 0, return 0.\n if (this.sign === 0 || decimal.sign === 0) {\n return FC_NN(0, 0, 0);\n }\n\n //Special case - Multiplying a number by its own reciprocal yields +/- 1, no matter how large.\n if (this.layer === decimal.layer && this.mag === -decimal.mag) {\n return FC_NN(this.sign * decimal.sign, 0, 1);\n }\n\n let a;\n let b;\n\n //Which number is bigger in terms of its multiplicative distance from 1?\n if (\n this.layer > decimal.layer ||\n (this.layer == decimal.layer && Math.abs(this.mag) > Math.abs(decimal.mag))\n ) {\n a = this;\n b = decimal;\n } else {\n a = decimal;\n b = this;\n }\n\n if (a.layer === 0 && b.layer === 0) {\n return D(a.sign * b.sign * a.mag * b.mag);\n }\n\n //Special case: If one of the numbers is layer 3 or higher or one of the numbers is 2+ layers bigger than the other, just take the bigger number.\n if (a.layer >= 3 || a.layer - b.layer >= 2) {\n return FC(a.sign * b.sign, a.layer, a.mag);\n }\n\n if (a.layer === 1 && b.layer === 0) {\n return FC(a.sign * b.sign, 1, a.mag + Math.log10(b.mag));\n }\n\n if (a.layer === 1 && b.layer === 1) {\n return FC(a.sign * b.sign, 1, a.mag + b.mag);\n }\n\n if (a.layer === 2 && b.layer === 1) {\n const newmag = FC(Math.sign(a.mag), a.layer - 1, Math.abs(a.mag)).add(\n FC(Math.sign(b.mag), b.layer - 1, Math.abs(b.mag))\n );\n return FC(a.sign * b.sign, newmag.layer + 1, newmag.sign * newmag.mag);\n }\n\n if (a.layer === 2 && b.layer === 2) {\n const newmag = FC(Math.sign(a.mag), a.layer - 1, Math.abs(a.mag)).add(\n FC(Math.sign(b.mag), b.layer - 1, Math.abs(b.mag))\n );\n return FC(a.sign * b.sign, newmag.layer + 1, newmag.sign * newmag.mag);\n }\n\n throw Error(\"Bad arguments to mul: \" + this + \", \" + value);\n }\n\n public multiply(value: DecimalSource): Decimal {\n return this.mul(value);\n }\n\n public times(value: DecimalSource): Decimal {\n return this.mul(value);\n }\n\n public div(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.mul(decimal.recip());\n }\n\n public divide(value: DecimalSource): Decimal {\n return this.div(value);\n }\n\n public divideBy(value: DecimalSource): Decimal {\n return this.div(value);\n }\n\n public dividedBy(value: DecimalSource): Decimal {\n return this.div(value);\n }\n\n public recip(): Decimal {\n if (this.mag === 0) {\n return Decimal.dNaN;\n } else if (this.layer === 0) {\n return FC(this.sign, 0, 1 / this.mag);\n } else {\n return FC(this.sign, this.layer, -this.mag);\n }\n }\n\n public reciprocal(): Decimal {\n return this.recip();\n }\n\n public reciprocate(): Decimal {\n return this.recip();\n }\n\n /**\n * -1 for less than value, 0 for equals value, 1 for greater than value\n */\n public cmp(value: DecimalSource): CompareResult {\n const decimal = D(value);\n if (this.sign > decimal.sign) {\n return 1;\n }\n if (this.sign < decimal.sign) {\n return -1;\n }\n return (this.sign * this.cmpabs(value)) as CompareResult;\n }\n\n public cmpabs(value: DecimalSource): CompareResult {\n const decimal = D(value);\n const layera = this.mag > 0 ? this.layer : -this.layer;\n const layerb = decimal.mag > 0 ? decimal.layer : -decimal.layer;\n if (layera > layerb) {\n return 1;\n }\n if (layera < layerb) {\n return -1;\n }\n if (this.mag > decimal.mag) {\n return 1;\n }\n if (this.mag < decimal.mag) {\n return -1;\n }\n return 0;\n }\n\n public compare(value: DecimalSource): CompareResult {\n return this.cmp(value);\n }\n\n public isNan(): boolean {\n return isNaN(this.sign) || isNaN(this.layer) || isNaN(this.mag);\n }\n\n public isFinite(): boolean {\n return isFinite(this.sign) && isFinite(this.layer) && isFinite(this.mag);\n }\n\n public eq(value: DecimalSource): boolean {\n const decimal = D(value);\n return (\n this.sign === decimal.sign && this.layer === decimal.layer && this.mag === decimal.mag\n );\n }\n\n public equals(value: DecimalSource): boolean {\n return this.eq(value);\n }\n\n public neq(value: DecimalSource): boolean {\n return !this.eq(value);\n }\n\n public notEquals(value: DecimalSource): boolean {\n return this.neq(value);\n }\n\n public lt(value: DecimalSource): boolean {\n return this.cmp(value) === -1;\n }\n\n public lte(value: DecimalSource): boolean {\n return !this.gt(value);\n }\n\n public gt(value: DecimalSource): boolean {\n return this.cmp(value) === 1;\n }\n\n public gte(value: DecimalSource): boolean {\n return !this.lt(value);\n }\n\n public max(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.lt(decimal) ? decimal : this;\n }\n\n public min(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.gt(decimal) ? decimal : this;\n }\n\n public maxabs(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.cmpabs(decimal) < 0 ? decimal : this;\n }\n\n public minabs(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.cmpabs(decimal) > 0 ? decimal : this;\n }\n\n public clamp(min: DecimalSource, max: DecimalSource): Decimal {\n return this.max(min).min(max);\n }\n\n public clampMin(min: DecimalSource): Decimal {\n return this.max(min);\n }\n\n public clampMax(max: DecimalSource): Decimal {\n return this.min(max);\n }\n\n public cmp_tolerance(value: DecimalSource, tolerance: number): CompareResult {\n const decimal = D(value);\n return this.eq_tolerance(decimal, tolerance) ? 0 : this.cmp(decimal);\n }\n\n public compare_tolerance(value: DecimalSource, tolerance: number): CompareResult {\n return this.cmp_tolerance(value, tolerance);\n }\n\n /**\n * Tolerance is a relative tolerance, multiplied by the greater of the magnitudes of the two arguments.\n * For example, if you put in 1e-9, then any number closer to the\n * larger number than (larger number)*1e-9 will be considered equal.\n */\n public eq_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value); // https://stackoverflow.com/a/33024979\n if (tolerance == null) {\n tolerance = 1e-7;\n }\n //Numbers that are too far away are never close.\n if (this.sign !== decimal.sign) {\n return false;\n }\n if (Math.abs(this.layer - decimal.layer) > 1) {\n return false;\n }\n // return abs(a-b) <= tolerance * max(abs(a), abs(b))\n let magA = this.mag;\n let magB = decimal.mag;\n if (this.layer > decimal.layer) {\n magB = f_maglog10(magB);\n }\n if (this.layer < decimal.layer) {\n magA = f_maglog10(magA);\n }\n return Math.abs(magA - magB) <= tolerance * Math.max(Math.abs(magA), Math.abs(magB));\n }\n\n public equals_tolerance(value: DecimalSource, tolerance: number): boolean {\n return this.eq_tolerance(value, tolerance);\n }\n\n public neq_tolerance(value: DecimalSource, tolerance: number): boolean {\n return !this.eq_tolerance(value, tolerance);\n }\n\n public notEquals_tolerance(value: DecimalSource, tolerance: number): boolean {\n return this.neq_tolerance(value, tolerance);\n }\n\n public lt_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return !this.eq_tolerance(decimal, tolerance) && this.lt(decimal);\n }\n\n public lte_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return this.eq_tolerance(decimal, tolerance) || this.lt(decimal);\n }\n\n public gt_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return !this.eq_tolerance(decimal, tolerance) && this.gt(decimal);\n }\n\n public gte_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return this.eq_tolerance(decimal, tolerance) || this.gt(decimal);\n }\n\n public pLog10(): Decimal {\n if (this.lt(Decimal.dZero)) {\n return Decimal.dZero;\n }\n return this.log10();\n }\n\n public absLog10(): Decimal {\n if (this.sign === 0) {\n return Decimal.dNaN;\n } else if (this.layer > 0) {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n } else {\n return FC(1, 0, Math.log10(this.mag));\n }\n }\n\n public log10(): Decimal {\n if (this.sign <= 0) {\n return Decimal.dNaN;\n } else if (this.layer > 0) {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n } else {\n return FC(this.sign, 0, Math.log10(this.mag));\n }\n }\n\n public log(base: DecimalSource): Decimal {\n base = D(base);\n if (this.sign <= 0) {\n return Decimal.dNaN;\n }\n if (base.sign <= 0) {\n return Decimal.dNaN;\n }\n if (base.sign === 1 && base.layer === 0 && base.mag === 1) {\n return Decimal.dNaN;\n } else if (this.layer === 0 && base.layer === 0) {\n return FC(this.sign, 0, Math.log(this.mag) / Math.log(base.mag));\n }\n\n return Decimal.div(this.log10(), base.log10());\n }\n\n public log2(): Decimal {\n if (this.sign <= 0) {\n return Decimal.dNaN;\n } else if (this.layer === 0) {\n return FC(this.sign, 0, Math.log2(this.mag));\n } else if (this.layer === 1) {\n return FC(Math.sign(this.mag), 0, Math.abs(this.mag) * 3.321928094887362); //log2(10)\n } else if (this.layer === 2) {\n return FC(Math.sign(this.mag), 1, Math.abs(this.mag) + 0.5213902276543247); //-log10(log10(2))\n } else {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n }\n }\n\n public ln(): Decimal {\n if (this.sign <= 0) {\n return Decimal.dNaN;\n } else if (this.layer === 0) {\n return FC(this.sign, 0, Math.log(this.mag));\n } else if (this.layer === 1) {\n return FC(Math.sign(this.mag), 0, Math.abs(this.mag) * 2.302585092994046); //ln(10)\n } else if (this.layer === 2) {\n return FC(Math.sign(this.mag), 1, Math.abs(this.mag) + 0.36221568869946325); //log10(log10(e))\n } else {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n }\n }\n\n public logarithm(base: DecimalSource): Decimal {\n return this.log(base);\n }\n\n public pow(value: DecimalSource): Decimal {\n const decimal = D(value);\n const a = this;\n const b = decimal;\n\n //special case: if a is 0, then return 0 (UNLESS b is 0, then return 1)\n if (a.sign === 0) {\n return b.eq(0) ? FC_NN(1, 0, 1) : a;\n }\n //special case: if a is 1, then return 1\n if (a.sign === 1 && a.layer === 0 && a.mag === 1) {\n return a;\n }\n //special case: if b is 0, then return 1\n if (b.sign === 0) {\n return FC_NN(1, 0, 1);\n }\n //special case: if b is 1, then return a\n if (b.sign === 1 && b.layer === 0 && b.mag === 1) {\n return a;\n }\n\n const result = a\n .absLog10()\n .mul(b)\n .pow10();\n\n if (this.sign === -1) {\n if (Math.abs(b.toNumber() % 2) % 2 === 1) {\n return result.neg();\n } else if (Math.abs(b.toNumber() % 2) % 2 === 0) {\n return result;\n }\n return Decimal.dNaN;\n }\n\n return result;\n }\n\n public pow10(): Decimal {\n /*\n There are four cases we need to consider:\n 1) positive sign, positive mag (e15, ee15): +1 layer (e.g. 10^15 becomes e15, 10^e15 becomes ee15)\n 2) negative sign, positive mag (-e15, -ee15): +1 layer but sign and mag sign are flipped (e.g. 10^-15 becomes e-15, 10^-e15 becomes ee-15)\n 3) positive sign, negative mag (e-15, ee-15): layer 0 case would have been handled in the Math.pow check, so just return 1\n 4) negative sign, negative mag (-e-15, -ee-15): layer 0 case would have been handled in the Math.pow check, so just return 1\n */\n\n if (!Number.isFinite(this.layer) || !Number.isFinite(this.mag)) {\n return Decimal.dNaN;\n }\n\n let a = this;\n\n //handle layer 0 case - if no precision is lost just use Math.pow, else promote one layer\n if (a.layer === 0) {\n const newmag = Math.pow(10, a.sign * a.mag);\n if (Number.isFinite(newmag) && Math.abs(newmag) >= 0.1) {\n return FC(1, 0, newmag);\n } else {\n if (a.sign === 0) {\n return Decimal.dOne;\n } else {\n a = FC_NN(a.sign, a.layer + 1, Math.log10(a.mag)) as this;\n }\n }\n }\n\n //handle all 4 layer 1+ cases individually\n if (a.sign > 0 && a.mag >= 0) {\n return FC(a.sign, a.layer + 1, a.mag);\n }\n if (a.sign < 0 && a.mag >= 0) {\n return FC(-a.sign, a.layer + 1, -a.mag);\n }\n //both the negative mag cases are identical: one +/- rounding error\n return Decimal.dOne;\n }\n\n public pow_base(value: DecimalSource): Decimal {\n return D(value).pow(this);\n }\n\n public root(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.pow(decimal.recip());\n }\n\n public factorial(): Decimal {\n if (this.mag < 0) {\n return this.add(1).gamma();\n } else if (this.layer === 0) {\n return this.add(1).gamma();\n } else if (this.layer === 1) {\n return Decimal.exp(Decimal.mul(this, Decimal.ln(this).sub(1)));\n } else {\n return Decimal.exp(this);\n }\n }\n\n //from HyperCalc source code\n public gamma(): Decimal {\n if (this.mag < 0) {\n return this.recip();\n } else if (this.layer === 0) {\n if (this.lt(FC_NN(1, 0, 24))) {\n return D(f_gamma(this.sign * this.mag));\n }\n\n const t = this.mag - 1;\n let l = 0.9189385332046727; //0.5*Math.log(2*Math.PI)\n l = l + (t + 0.5) * Math.log(t);\n l = l - t;\n const n2 = t * t;\n let np = t;\n let lm = 12 * np;\n let adj = 1 / lm;\n let l2 = l + adj;\n if (l2 === l) {\n return Decimal.exp(l);\n }\n\n l = l2;\n np = np * n2;\n lm = 360 * np;\n adj = 1 / lm;\n l2 = l - adj;\n if (l2 === l) {\n return Decimal.exp(l);\n }\n\n l = l2;\n np = np * n2;\n lm = 1260 * np;\n let lt = 1 / lm;\n l = l + lt;\n np = np * n2;\n lm = 1680 * np;\n lt = 1 / lm;\n l = l - lt;\n return Decimal.exp(l);\n } else if (this.layer === 1) {\n return Decimal.exp(Decimal.mul(this, Decimal.ln(this).sub(1)));\n } else {\n return Decimal.exp(this);\n }\n }\n\n public lngamma(): Decimal {\n return this.gamma().ln();\n }\n\n public exp(): Decimal {\n if (this.mag < 0) {\n return Decimal.dOne;\n }\n if (this.layer === 0 && this.mag <= 709.7) {\n return D(Math.exp(this.sign * this.mag));\n } else if (this.layer === 0) {\n return FC(1, 1, this.sign * Math.log10(Math.E) * this.mag);\n } else if (this.layer === 1) {\n return FC(1, 2, this.sign * (Math.log10(0.4342944819032518) + this.mag));\n } else {\n return FC(1, this.layer + 1, this.sign * this.mag);\n }\n }\n\n public sqr(): Decimal {\n return this.pow(2);\n }\n\n public sqrt(): Decimal {\n if (this.layer === 0) {\n return D(Math.sqrt(this.sign * this.mag));\n } else if (this.layer === 1) {\n return FC(1, 2, Math.log10(this.mag) - 0.3010299956639812);\n } else {\n const result = Decimal.div(FC_NN(this.sign, this.layer - 1, this.mag), FC_NN(1, 0, 2));\n result.layer += 1;\n result.normalize();\n return result;\n }\n }\n\n public cube(): Decimal {\n return this.pow(3);\n }\n\n public cbrt(): Decimal {\n return this.pow(1 / 3);\n }\n\n //Tetration/tetrate: The result of exponentiating 'this' to 'this' 'height' times in a row. https://en.wikipedia.org/wiki/Tetration\n //If payload != 1, then this is 'iterated exponentiation', the result of exping (payload) to base (this) (height) times. https://andydude.github.io/tetration/archives/tetration2/ident.html\n //Works with negative and positive real heights.\n public tetrate(height = 2, payload: DecimalSource = FC_NN(1, 0, 1)): Decimal {\n //x^^1 == x\n if (height === 1) {\n return Decimal.pow(this, payload);\n }\n //x^^0 == 1\n if (height === 0) {\n return new Decimal(payload);\n }\n //1^^x == 1\n if (this.eq(Decimal.dOne)) {\n return Decimal.dOne;\n }\n //-1^^x == -1\n if (this.eq(-1)) {\n return Decimal.pow(this, payload);\n }\n\n if (height === Number.POSITIVE_INFINITY) {\n const this_num = this.toNumber();\n //within the convergence range?\n if (this_num <= 1.44466786100976613366 && this_num >= 0.06598803584531253708) {\n //hotfix for the very edge of the number range not being handled properly\n if (this_num > 1.444667861009099) {\n return new Decimal(Math.E);\n }\n //Formula for infinite height power tower.\n const negln = Decimal.ln(this).neg();\n return negln.lambertw().div(negln);\n } else if (this_num > 1.44466786100976613366) {\n //explodes to infinity\n return new Decimal(Number.POSITIVE_INFINITY);\n } else {\n //0.06598803584531253708 > this_num >= 0: never converges\n //this_num < 0: quickly becomes a complex number\n return Decimal.dNaN;\n }\n }\n\n //0^^x oscillates if we define 0^0 == 1 (which in javascript land we do), since then 0^^1 is 0, 0^^2 is 1, 0^^3 is 0, etc. payload is ignored\n //using the linear approximation for height (TODO: don't know a better way to calculate it ATM, but it wouldn't surprise me if it's just NaN)\n if (this.eq(Decimal.dZero)) {\n let result = Math.abs((height + 1) % 2);\n if (result > 1) {\n result = 2 - result;\n }\n return new Decimal(result);\n }\n\n if (height < 0) {\n return Decimal.iteratedlog(payload, this, -height);\n }\n\n payload = D(payload);\n const oldheight = height;\n height = Math.trunc(height);\n const fracheight = oldheight - height;\n\n if (this.gt(Decimal.dZero) && this.lte(1.44466786100976613366)) {\n //similar to 0^^n, flip-flops between two values, converging slowly (or if it's below 0.06598803584531253708, never. so once again, the fractional part at the end will be a linear approximation (TODO: again pending knowledge of how to approximate better, although tbh I think it should in reality just be NaN)\n height = Math.min(10000, height);\n for (let i = 0; i < height; ++i) {\n const old_payload: Decimal = payload;\n payload = this.pow(payload);\n //stop early if we converge\n if (old_payload.eq(payload)) {\n return payload;\n }\n }\n if (fracheight != 0) {\n const next_payload = this.pow(payload);\n return payload.mul(1 - fracheight).add(next_payload.mul(fracheight));\n }\n return payload;\n }\n //TODO: base < 0, but it's hard for me to reason about (probably all non-integer heights are NaN automatically?)\n\n if (fracheight !== 0) {\n if (payload.eq(Decimal.dOne)) {\n //TODO: for bases above 10, revert to old linear approximation until I can think of something better\n if (this.gt(10)) {\n payload = this.pow(fracheight);\n } else {\n payload = D(Decimal.tetrate_critical(this.toNumber(), fracheight));\n //TODO: until the critical section grid can handle numbers below 2, scale them to the base\n //TODO: maybe once the critical section grid has very large bases, this math can be appropriate for them too? I'll think about it\n if (this.lt(2)) {\n payload = payload\n .sub(1)\n .mul(this.minus(1))\n .plus(1);\n }\n }\n } else {\n if (this.eq(10)) {\n payload = payload.layeradd10(fracheight);\n } else {\n payload = payload.layeradd(fracheight, this);\n }\n }\n }\n\n for (let i = 0; i < height; ++i) {\n payload = this.pow(payload);\n //bail if we're NaN\n if (!isFinite(payload.layer) || !isFinite(payload.mag)) {\n return payload.normalize();\n }\n //shortcut\n if (payload.layer - this.layer > 3) {\n return FC_NN(payload.sign, payload.layer + (height - i - 1), payload.mag);\n }\n //give up after 10000 iterations if nothing is happening\n if (i > 10000) {\n return payload;\n }\n }\n return payload;\n }\n\n //iteratedexp/iterated exponentiation: - all cases handled in tetrate, so just call it\n public iteratedexp(height = 2, payload = FC_NN(1, 0, 1)): Decimal {\n return this.tetrate(height, payload);\n }\n\n //iterated log/repeated log: The result of applying log(base) 'times' times in a row. Approximately equal to subtracting (times) from the number's slog representation. Equivalent to tetrating to a negative height.\n //Works with negative and positive real heights.\n public iteratedlog(base: DecimalSource = 10, times = 1): Decimal {\n if (times < 0) {\n return Decimal.tetrate(base, -times, this);\n }\n\n base = D(base);\n let result = D(this);\n const fulltimes = times;\n times = Math.trunc(times);\n const fraction = fulltimes - times;\n if (result.layer - base.layer > 3) {\n const layerloss = Math.min(times, result.layer - base.layer - 3);\n times -= layerloss;\n result.layer -= layerloss;\n }\n\n for (let i = 0; i < times; ++i) {\n result = result.log(base);\n //bail if we're NaN\n if (!isFinite(result.layer) || !isFinite(result.mag)) {\n return result.normalize();\n }\n //give up after 10000 iterations if nothing is happening\n if (i > 10000) {\n return result;\n }\n }\n\n //handle fractional part\n if (fraction > 0 && fraction < 1) {\n if (base.eq(10)) {\n result = result.layeradd10(-fraction);\n } else {\n result = result.layeradd(-fraction, base);\n }\n }\n\n return result;\n }\n\n //Super-logarithm, one of tetration's inverses, tells you what size power tower you'd have to tetrate base to to get number. By definition, will never be higher than 1.8e308 in break_eternity.js, since a power tower 1.8e308 numbers tall is the largest representable number.\n // https://en.wikipedia.org/wiki/Super-logarithm\n public slog(base: DecimalSource = 10): Decimal {\n base = D(base);\n\n //special cases:\n //slog base 0 or lower is NaN\n if (base.lte(Decimal.dZero)) {\n return Decimal.dNaN;\n }\n //slog base 1 is NaN\n if (base.eq(Decimal.dOne)) {\n return Decimal.dNaN;\n }\n //need to handle these small, wobbling bases specially\n if (base.lt(Decimal.dOne)) {\n if (this.eq(Decimal.dOne)) {\n return Decimal.dZero;\n }\n if (this.eq(Decimal.dZero)) {\n return Decimal.dNegOne;\n }\n //0 < this < 1: ambiguous (happens multiple times)\n //this < 0: impossible (as far as I can tell)\n //this > 1: partially complex (http://myweb.astate.edu/wpaulsen/tetcalc/tetcalc.html base 0.25 for proof)\n return Decimal.dNaN;\n }\n //slog_n(0) is -1\n if (this.mag < 0 || this.eq(Decimal.dZero)) {\n return Decimal.dNegOne;\n }\n\n let result = 0;\n let copy = D(this);\n if (copy.layer - base.layer > 3) {\n const layerloss = copy.layer - base.layer - 3;\n result += layerloss;\n copy.layer -= layerloss;\n }\n\n for (let i = 0; i < 100; ++i) {\n if (copy.lt(Decimal.dZero)) {\n copy = Decimal.pow(base, copy);\n result -= 1;\n } else if (copy.lte(Decimal.dOne)) {\n return D(result + Decimal.slog_critical(base.toNumber(), copy.toNumber()));\n } else {\n result += 1;\n copy = Decimal.log(copy, base);\n }\n }\n return D(result);\n }\n\n //background info and tables of values for critical functions taken here: https://github.com/Patashu/break_eternity.js/issues/22\n public static slog_critical(base: number, height: number): number {\n //TODO: for bases above 10, revert to old linear approximation until I can think of something better\n if (base > 10) {\n return height - 1;\n }\n return Decimal.critical_section(base, height, critical_slog_values);\n }\n\n public static tetrate_critical(base: number, height: number): number {\n return Decimal.critical_section(base, height, critical_tetr_values);\n }\n\n public static critical_section(base: number, height: number, grid: number[][]): number {\n //this part is simple at least, since it's just 0.1 to 0.9\n height *= 10;\n if (height < 0) {\n height = 0;\n }\n if (height > 10) {\n height = 10;\n }\n //have to do this complicated song and dance since one of the critical_headers is Math.E, and in the future I'd like 1.5 as well\n if (base < 2) {\n base = 2;\n }\n if (base > 10) {\n base = 10;\n }\n let lower = 0;\n let upper = 0;\n //basically, if we're between bases, we interpolate each bases' relevant values together\n //then we interpolate based on what the fractional height is.\n //accuracy could be improved by doing a non-linear interpolation (maybe), by adding more bases and heights (definitely) but this is AFAIK the best you can get without running some pari.gp or mathematica program to calculate exact values\n for (let i = 0; i < critical_headers.length; ++i) {\n if (critical_headers[i] == base) {\n // exact match\n lower = grid[i][Math.floor(height)];\n upper = grid[i][Math.ceil(height)];\n break;\n } else if (critical_headers[i] < base && critical_headers[i + 1] > base) {\n // interpolate between this and the next\n const basefrac =\n (base - critical_headers[i]) / (critical_headers[i + 1] - critical_headers[i]);\n lower =\n grid[i][Math.floor(height)] * (1 - basefrac) +\n grid[i + 1][Math.floor(height)] * basefrac;\n upper =\n grid[i][Math.ceil(height)] * (1 - basefrac) +\n grid[i + 1][Math.ceil(height)] * basefrac;\n break;\n }\n }\n const frac = height - Math.floor(height);\n const result = lower * (1 - frac) + upper * frac;\n return result;\n }\n\n //Function for adding/removing layers from a Decimal, even fractional layers (e.g. its slog10 representation).\n //Moved this over to use the same critical section as tetrate/slog.\n public layeradd10(diff: DecimalSource): Decimal {\n diff = Decimal.fromValue_noAlloc(diff).toNumber();\n const result = D(this);\n if (diff >= 1) {\n //bug fix: if result is very smol (mag < 0, layer > 0) turn it into 0 first\n if (result.mag < 0 && result.layer > 0) {\n result.sign = 0;\n result.mag = 0;\n result.layer = 0;\n } else if (result.sign === -1 && result.layer == 0) {\n //bug fix - for stuff like -3.layeradd10(1) we need to move the sign to the mag\n result.sign = 1;\n result.mag = -result.mag;\n }\n const layeradd = Math.trunc(diff);\n diff -= layeradd;\n result.layer += layeradd;\n }\n if (diff <= -1) {\n const layeradd = Math.trunc(diff);\n diff -= layeradd;\n result.layer += layeradd;\n if (result.layer < 0) {\n for (let i = 0; i < 100; ++i) {\n result.layer++;\n result.mag = Math.log10(result.mag);\n if (!isFinite(result.mag)) {\n //another bugfix: if we hit -Infinity mag, then we should return negative infinity, not 0. 0.layeradd10(-1) h its this\n if (result.sign === 0) {\n result.sign = 1;\n }\n //also this, for 0.layeradd10(-2)\n if (result.layer < 0) {\n result.layer = 0;\n }\n return result.normalize();\n }\n if (result.layer >= 0) {\n break;\n }\n }\n }\n }\n\n while (result.layer < 0) {\n result.layer++;\n result.mag = Math.log10(result.mag);\n }\n //bugfix: before we normalize: if we started with 0, we now need to manually fix a layer ourselves!\n if (result.sign === 0) {\n result.sign = 1;\n if (result.mag === 0 && result.layer >= 1) {\n result.layer -= 1;\n result.mag = 1;\n }\n }\n result.normalize();\n\n //layeradd10: like adding 'diff' to the number's slog(base) representation. Very similar to tetrate base 10 and iterated log base 10. Also equivalent to adding a fractional amount to the number's layer in its break_eternity.js representation.\n if (diff !== 0) {\n return result.layeradd(diff, 10); //safe, only calls positive height 1 payload tetration, slog and log\n }\n\n return result;\n }\n\n //layeradd: like adding 'diff' to the number's slog(base) representation. Very similar to tetrate base 'base' and iterated log base 'base'.\n public layeradd(diff: number, base: DecimalSource): Decimal {\n const slogthis = this.slog(base).toNumber();\n const slogdest = slogthis + diff;\n if (slogdest >= 0) {\n return Decimal.tetrate(base, slogdest);\n } else if (!Number.isFinite(slogdest)) {\n return Decimal.dNaN;\n } else if (slogdest >= -1) {\n return Decimal.log(Decimal.tetrate(base, slogdest + 1), base);\n } else {\n return Decimal.log(Decimal.log(Decimal.tetrate(base, slogdest + 2), base), base);\n }\n }\n\n //The Lambert W function, also called the omega function or product logarithm, is the solution W(x) === x*e^x.\n // https://en.wikipedia.org/wiki/Lambert_W_function\n //Some special values, for testing: https://en.wikipedia.org/wiki/Lambert_W_function#Special_values\n public lambertw(): Decimal {\n if (this.lt(-0.3678794411710499)) {\n throw Error(\"lambertw is unimplemented for results less than -1, sorry!\");\n } else if (this.mag < 0) {\n return D(f_lambertw(this.toNumber()));\n } else if (this.layer === 0) {\n return D(f_lambertw(this.sign * this.mag));\n } else if (this.layer === 1) {\n return d_lambertw(this);\n } else if (this.layer === 2) {\n return d_lambertw(this);\n }\n if (this.layer >= 3) {\n return FC_NN(this.sign, this.layer - 1, this.mag);\n }\n\n throw \"Unhandled behavior in lambertw()\";\n }\n\n //The super square-root function - what number, tetrated to height 2, equals this?\n //Other sroots are possible to calculate probably through guess and check methods, this one is easy though.\n // https://en.wikipedia.org/wiki/Tetration#Super-root\n public ssqrt(): Decimal {\n if (this.sign == 1 && this.layer >= 3) {\n return FC_NN(this.sign, this.layer - 1, this.mag);\n }\n const lnx = this.ln();\n return lnx.div(lnx.lambertw());\n }\n /*\n\nUnit tests for tetrate/iteratedexp/iteratedlog/layeradd10/layeradd/slog:\n(note: these won't be exactly precise with the new slog implementation, but that's okay)\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n var expected = first+both+1;\n var result = new Decimal(10).layeradd10(first).layeradd10(both).slog();\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n first += both;\n var expected = first-both+1;\n var result = new Decimal(10).layeradd10(first).layeradd10(-both).slog();\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n var base = Math.random()*8+2;\n var expected = first+both+1;\n var result = new Decimal(base).layeradd(first, base).layeradd(both, base).slog(base);\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n var base = Math.random()*8+2;\n first += both;\n var expected = first-both+1;\n var result = new Decimal(base).layeradd(first, base).layeradd(-both, base).slog(base);\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\nvar first = Math.round((Math.random()*30))/10;\nvar both = Math.round((Math.random()*30))/10;\nvar tetrateonly = Decimal.tetrate(10, first);\nvar tetrateandlog = Decimal.tetrate(10, first+both).iteratedlog(10, both);\nif (!Decimal.eq_tolerance(tetrateonly, tetrateandlog))\n{\n console.log(first + \", \" + both);\n}\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\nvar first = Math.round((Math.random()*30))/10;\nvar both = Math.round((Math.random()*30))/10;\nvar base = Math.random()*8+2;\nvar tetrateonly = Decimal.tetrate(base, first);\nvar tetrateandlog = Decimal.tetrate(base, first+both).iteratedlog(base, both);\nif (!Decimal.eq_tolerance(tetrateonly, tetrateandlog))\n{\n console.log(first + \", \" + both);\n}\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\nvar first = Math.round((Math.random()*30))/10;\nvar both = Math.round((Math.random()*30))/10;\nvar base = Math.random()*8+2;\nvar tetrateonly = Decimal.tetrate(base, first, base);\nvar tetrateandlog = Decimal.tetrate(base, first+both, base).iteratedlog(base, both);\nif (!Decimal.eq_tolerance(tetrateonly, tetrateandlog))\n{\n console.log(first + \", \" + both);\n}\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var xex = new Decimal(-0.3678794411710499+Math.random()*100);\n var x = Decimal.lambertw(xex);\n if (!Decimal.eq_tolerance(xex, x.mul(Decimal.exp(x))))\n {\n console.log(xex);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var xex = new Decimal(-0.3678794411710499+Math.exp(Math.random()*100));\n var x = Decimal.lambertw(xex);\n if (!Decimal.eq_tolerance(xex, x.mul(Decimal.exp(x))))\n {\n console.log(xex);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var a = Decimal.randomDecimalForTesting(Math.random() > 0.5 ? 0 : 1);\n var b = Decimal.randomDecimalForTesting(Math.random() > 0.5 ? 0 : 1);\n if (Math.random() > 0.5) { a = a.recip(); }\n if (Math.random() > 0.5) { b = b.recip(); }\n var c = a.add(b).toNumber();\n if (Number.isFinite(c) && !Decimal.eq_tolerance(c, a.toNumber()+b.toNumber()))\n {\n console.log(a + \", \" + b);\n }\n}\n\nfor (var i = 0; i < 100; ++i)\n{\n var a = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n var b = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n if (Math.random() > 0.5) { a = a.recip(); }\n if (Math.random() > 0.5) { b = b.recip(); }\n var c = a.mul(b).toNumber();\n if (Number.isFinite(c) && Number.isFinite(a.toNumber()) && Number.isFinite(b.toNumber()) && a.toNumber() != 0 && b.toNumber() != 0 && c != 0 && !Decimal.eq_tolerance(c, a.toNumber()*b.toNumber()))\n {\n console.log(\"Test 1: \" + a + \", \" + b);\n }\n else if (!Decimal.mul(a.recip(), b.recip()).eq_tolerance(Decimal.mul(a, b).recip()))\n {\n console.log(\"Test 3: \" + a + \", \" + b);\n }\n}\n\nfor (var i = 0; i < 10; ++i)\n{\n var a = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n var b = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n if (Math.random() > 0.5 && a.sign !== 0) { a = a.recip(); }\n if (Math.random() > 0.5 && b.sign !== 0) { b = b.recip(); }\n var c = a.pow(b);\n var d = a.root(b.recip());\n var e = a.pow(b.recip());\n var f = a.root(b);\n\n if (!c.eq_tolerance(d) && a.sign !== 0 && b.sign !== 0)\n {\n console.log(\"Test 1: \" + a + \", \" + b);\n }\n if (!e.eq_tolerance(f) && a.sign !== 0 && b.sign !== 0)\n {\n console.log(\"Test 2: \" + a + \", \" + b);\n }\n}\n\nfor (var i = 0; i < 10; ++i)\n{\n var a = Math.round(Math.random()*18-9);\n var b = Math.round(Math.random()*100-50);\n var c = Math.round(Math.random()*18-9);\n var d = Math.round(Math.random()*100-50);\n console.log(\"Decimal.pow(Decimal.fromMantissaExponent(\" + a + \", \" + b + \"), Decimal.fromMantissaExponent(\" + c + \", \" + d + \")).toString()\");\n}\n\n*/\n\n //Pentation/pentate: The result of tetrating 'height' times in a row. An absurdly strong operator - Decimal.pentate(2, 4.28) and Decimal.pentate(10, 2.37) are already too huge for break_eternity.js!\n // https://en.wikipedia.org/wiki/Pentation\n public pentate(height = 2, payload: DecimalSource = FC_NN(1, 0, 1)): Decimal {\n payload = D(payload);\n const oldheight = height;\n height = Math.trunc(height);\n const fracheight = oldheight - height;\n\n //I have no idea if this is a meaningful approximation for pentation to continuous heights, but it is monotonic and continuous.\n if (fracheight !== 0) {\n if (payload.eq(Decimal.dOne)) {\n ++height;\n payload = new Decimal(fracheight);\n } else {\n if (this.eq(10)) {\n payload = payload.layeradd10(fracheight);\n } else {\n payload = payload.layeradd(fracheight, this);\n }\n }\n }\n\n for (let i = 0; i < height; ++i) {\n payload = this.tetrate(payload.toNumber());\n //bail if we're NaN\n if (!isFinite(payload.layer) || !isFinite(payload.mag)) {\n return payload.normalize();\n }\n //give up after 10 iterations if nothing is happening\n if (i > 10) {\n return payload;\n }\n }\n\n return payload;\n }\n\n // trig functions!\n public sin(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.sin(this.sign * this.mag));\n }\n return FC_NN(0, 0, 0);\n }\n\n public cos(): Decimal {\n if (this.mag < 0) {\n return Decimal.dOne;\n }\n if (this.layer === 0) {\n return D(Math.cos(this.sign * this.mag));\n }\n return FC_NN(0, 0, 0);\n }\n\n public tan(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.tan(this.sign * this.mag));\n }\n return FC_NN(0, 0, 0);\n }\n\n public asin(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.asin(this.sign * this.mag));\n }\n return FC_NN(Number.NaN, Number.NaN, Number.NaN);\n }\n\n public acos(): Decimal {\n if (this.mag < 0) {\n return D(Math.acos(this.toNumber()));\n }\n if (this.layer === 0) {\n return D(Math.acos(this.sign * this.mag));\n }\n return FC_NN(Number.NaN, Number.NaN, Number.NaN);\n }\n\n public atan(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.atan(this.sign * this.mag));\n }\n return D(Math.atan(this.sign * 1.8e308));\n }\n\n public sinh(): Decimal {\n return this.exp()\n .sub(this.negate().exp())\n .div(2);\n }\n\n public cosh(): Decimal {\n return this.exp()\n .add(this.negate().exp())\n .div(2);\n }\n\n public tanh(): Decimal {\n return this.sinh().div(this.cosh());\n }\n\n public asinh(): Decimal {\n return Decimal.ln(\n this.add(\n this.sqr()\n .add(1)\n .sqrt()\n )\n );\n }\n\n public acosh(): Decimal {\n return Decimal.ln(\n this.add(\n this.sqr()\n .sub(1)\n .sqrt()\n )\n );\n }\n\n public atanh(): Decimal {\n if (this.abs().gte(1)) {\n return FC_NN(Number.NaN, Number.NaN, Number.NaN);\n }\n\n return Decimal.ln(this.add(1).div(D(1).sub(this))).div(2);\n }\n\n /**\n * Joke function from Realm Grinder\n */\n public ascensionPenalty(ascensions: DecimalSource): Decimal {\n if (ascensions === 0) {\n return this;\n }\n\n return this.root(Decimal.pow(10, ascensions));\n }\n\n /**\n * Joke function from Cookie Clicker. It's 'egg'\n */\n public egg(): Decimal {\n return this.add(9);\n }\n\n public lessThanOrEqualTo(other: DecimalSource): boolean {\n return this.cmp(other) < 1;\n }\n\n public lessThan(other: DecimalSource): boolean {\n return this.cmp(other) < 0;\n }\n\n public greaterThanOrEqualTo(other: DecimalSource): boolean {\n return this.cmp(other) > -1;\n }\n\n public greaterThan(other: DecimalSource): boolean {\n return this.cmp(other) > 0;\n }\n\n // return Decimal;\n}\n\n// return Decimal;\n","import Decimal, { DecimalSource } from \"lib/break_eternity\";\nimport projInfo from \"data/projInfo.json\";\n\nexport default Decimal;\n\nconst decimalOne = new Decimal(1);\n\nexport function exponentialFormat(num: DecimalSource, precision: number, mantissa = true): string {\n let e = Decimal.log10(num).floor();\n let m = Decimal.div(num, Decimal.pow(10, e));\n if (m.toStringWithDecimalPlaces(precision) === \"10\") {\n m = decimalOne;\n e = e.add(1);\n }\n const eString = e.gte(1e9)\n ? format(e, Math.max(Math.max(precision, 3), projInfo.defaultDecimalsShown))\n : e.gte(10000)\n ? commaFormat(e, 0)\n : e.toStringWithDecimalPlaces(0);\n if (mantissa) {\n return m.toStringWithDecimalPlaces(precision) + \"e\" + eString;\n } else {\n return \"e\" + eString;\n }\n}\n\nexport function commaFormat(num: DecimalSource, precision: number): string {\n if (num === null || num === undefined) {\n return \"NaN\";\n }\n num = new Decimal(num);\n if (num.mag < 0.001) {\n return (0).toFixed(precision);\n }\n const init = num.toStringWithDecimalPlaces(precision);\n const portions = init.split(\".\");\n portions[0] = portions[0].replace(/(\\d)(?=(\\d\\d\\d)+(?!\\d))/g, \"$1,\");\n if (portions.length == 1) return portions[0];\n return portions[0] + \".\" + portions[1];\n}\n\nexport function regularFormat(num: DecimalSource, precision: number): string {\n if (num === null || num === undefined) {\n return \"NaN\";\n }\n num = new Decimal(num);\n if (num.mag < 0.0001) {\n return (0).toFixed(precision);\n }\n if (num.mag < 0.1 && precision !== 0) {\n precision = Math.max(\n Math.max(precision, num.log10().negate().ceil().toNumber()),\n projInfo.defaultDecimalsShown\n );\n }\n return num.toStringWithDecimalPlaces(precision);\n}\n\nconst eeee1000 = new Decimal(\"eeee1000\");\nconst e100000 = new Decimal(\"e100000\");\nconst e1000 = new Decimal(\"e1000\");\nconst e9 = new Decimal(1e9);\nconst e6 = new Decimal(1e6);\nconst e3 = new Decimal(1e3);\nconst nearOne = new Decimal(0.98);\nconst thousandth = new Decimal(0.001);\nconst zero = new Decimal(0);\nexport function format(num: DecimalSource, precision?: number, small?: boolean): string {\n if (precision == null) precision = projInfo.defaultDecimalsShown;\n small = small ?? projInfo.defaultShowSmall;\n num = new Decimal(num);\n if (isNaN(num.sign) || isNaN(num.layer) || isNaN(num.mag)) {\n return \"NaN\";\n }\n if (num.sign < 0) {\n return \"-\" + format(num.neg(), precision);\n }\n if (num.mag === Number.POSITIVE_INFINITY) {\n return \"Infinity\";\n }\n if (num.gte(eeee1000)) {\n const slog = num.slog();\n if (slog.gte(e6)) {\n return \"F\" + format(slog.floor());\n } else {\n return (\n Decimal.pow(10, slog.sub(slog.floor())).toStringWithDecimalPlaces(3) +\n \"F\" +\n commaFormat(slog.floor(), 0)\n );\n }\n } else if (num.gte(e100000)) {\n return exponentialFormat(num, 0, false);\n } else if (num.gte(e1000)) {\n return exponentialFormat(num, 0);\n } else if (num.gte(e9)) {\n return exponentialFormat(num, precision);\n } else if (num.gte(e3)) {\n return commaFormat(num, 0);\n } else if (num.gte(thousandth) || !small) {\n return regularFormat(num, precision);\n } else if (num.eq(zero)) {\n return (0).toFixed(precision);\n }\n\n num = invertOOM(num);\n if (num.lt(e1000)) {\n const val = exponentialFormat(num, precision);\n return val.replace(/([^(?:e|F)]*)$/, \"-$1\");\n } else {\n return format(num, precision) + \"⁻¹\";\n }\n}\n\nexport function formatWhole(num: DecimalSource): string {\n num = new Decimal(num);\n if (num.sign < 0) {\n return \"-\" + formatWhole(num.neg());\n }\n if (num.gte(e9)) {\n return format(num);\n }\n if (num.lte(nearOne) && !num.eq(zero)) {\n return format(num);\n }\n return format(num, 0);\n}\n\nexport function formatTime(seconds: DecimalSource): string {\n if (Decimal.lt(seconds, 0)) {\n return \"-\" + formatTime(Decimal.neg(seconds));\n }\n if (Decimal.gt(seconds, 2 ** 51)) {\n // integer precision limit\n return format(Decimal.div(seconds, 31536000)) + \"y\";\n }\n seconds = new Decimal(seconds).toNumber();\n if (seconds < 60) {\n return format(seconds) + \"s\";\n } else if (seconds < 3600) {\n return formatWhole(Math.floor(seconds / 60)) + \"m \" + format(seconds % 60) + \"s\";\n } else if (seconds < 86400) {\n return (\n formatWhole(Math.floor(seconds / 3600)) +\n \"h \" +\n formatWhole(Math.floor(seconds / 60) % 60) +\n \"m \" +\n formatWhole(seconds % 60) +\n \"s\"\n );\n } else if (seconds < 31536000) {\n return (\n formatWhole(Math.floor(seconds / 84600) % 365) +\n \"d \" +\n formatWhole(Math.floor(seconds / 3600) % 24) +\n \"h \" +\n formatWhole(Math.floor(seconds / 60) % 60) +\n \"m\"\n );\n } else {\n return (\n formatWhole(Math.floor(seconds / 31536000)) +\n \"y \" +\n formatWhole(Math.floor(seconds / 84600) % 365) +\n \"d \" +\n formatWhole(Math.floor(seconds / 3600) % 24) +\n \"h\"\n );\n }\n}\n\nexport function toPlaces(x: DecimalSource, precision: number, maxAccepted: DecimalSource): string {\n x = new Decimal(x);\n let result = x.toStringWithDecimalPlaces(precision);\n if (new Decimal(result).gte(maxAccepted)) {\n result = Decimal.sub(maxAccepted, Math.pow(0.1, precision)).toStringWithDecimalPlaces(\n precision\n );\n }\n return result;\n}\n\n// Will also display very small numbers\nexport function formatSmall(x: DecimalSource, precision?: number): string {\n return format(x, precision, true);\n}\n\nexport function invertOOM(x: DecimalSource): Decimal {\n let e = Decimal.log10(x).ceil();\n const m = Decimal.div(x, Decimal.pow(10, e));\n e = e.neg();\n x = new Decimal(10).pow(e).times(m);\n\n return x;\n}\n","// Import Decimal and numberUtils from a different file to globally change which big num library gets used\n// This way switching out big number libraries just needs to happen here, not every file that needs big numbers\nimport { DecimalSource as RawDecimalSource } from \"lib/break_eternity\";\nimport Decimal, * as numberUtils from \"util/break_eternity\";\n\nexport const {\n exponentialFormat,\n commaFormat,\n regularFormat,\n format,\n formatWhole,\n formatTime,\n toPlaces,\n formatSmall,\n invertOOM\n} = numberUtils;\n\nexport type DecimalSource = RawDecimalSource;\n\nwindow.Decimal = Decimal;\nwindow.exponentialFormat = exponentialFormat;\nwindow.commaFormat = commaFormat;\nwindow.regularFormat = regularFormat;\nwindow.format = format;\nwindow.formatWhole = formatWhole;\nwindow.formatTime = formatTime;\nwindow.toPlaces = toPlaces;\nwindow.formatSmall = formatSmall;\nwindow.invertOOM = invertOOM;\n\nexport default Decimal;\n","export type WithRequired = T & { [P in K]-?: T[P] };\n\n// Reference:\n// https://stackoverflow.com/questions/7225407/convert-camelcasetext-to-sentence-case-text\nexport function camelToTitle(camel: string): string {\n let title = camel.replace(/([A-Z])/g, \" $1\");\n title = title.charAt(0).toUpperCase() + title.slice(1);\n return title;\n}\n\nexport function isPlainObject(object: unknown): boolean {\n return Object.prototype.toString.call(object) === \"[object Object]\";\n}\n\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport function isFunction(func: unknown): func is Function {\n return typeof func === \"function\";\n}\n\nexport enum Direction {\n Up = \"Up\",\n Down = \"Down\",\n Left = \"Left\",\n Right = \"Right\",\n Default = \"Up\"\n}\n","import { computed, Ref } from \"vue\";\nimport { isFunction } from \"./common\";\n\nexport const DoNotCache = Symbol(\"DoNotCache\");\n\nexport type Computable = T | Ref | (() => T);\nexport type ProcessedComputable = T | Ref;\nexport type GetComputableType = T extends { [DoNotCache]: true }\n ? T\n : T extends () => infer S\n ? Ref\n : undefined extends T\n ? undefined\n : T;\nexport type GetComputableTypeWithDefault = undefined extends T\n ? S\n : GetComputableType>;\nexport type UnwrapComputableType = T extends Ref ? S : T extends () => infer S ? S : T;\n\nexport type ComputableKeysOf = Pick<\n T,\n {\n [K in keyof T]: T[K] extends Computable ? K : never;\n }[keyof T]\n>;\n\n// TODO fix the typing of this function, such that casting isn't necessary and can be used to\n// detect if a createX function is validly written\nexport function processComputable>(\n obj: T,\n key: S\n): asserts obj is T & { [K in S]: ProcessedComputable> } {\n const computable = obj[key];\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (isFunction(computable) && computable.length === 0 && !(computable as any)[DoNotCache]) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n obj[key] = computed(computable.bind(obj));\n }\n}\n\nexport function convertComputable(obj: Computable): ProcessedComputable {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (isFunction(obj) && !(obj as any)[DoNotCache]) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n obj = computed(obj);\n }\n return obj as ProcessedComputable;\n}\n","import Decimal from \"./bignum\";\n\nexport const ProxyState = Symbol(\"ProxyState\");\nexport const ProxyPath = Symbol(\"ProxyPath\");\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport type ProxiedWithState = NonNullable extends Record\n ? NonNullable extends Decimal\n ? T\n : {\n [K in keyof T]: ProxiedWithState;\n } & {\n [ProxyState]: T;\n [ProxyPath]: string[];\n }\n : T;\n\n// Takes a function that returns an object and pretends to be that object\n// Note that the object is lazily calculated\nexport function createLazyProxy(\n objectFunc: (baseObject: S) => T & S,\n baseObject: S = {} as S\n): T {\n const obj: S & Partial = baseObject;\n let calculated = false;\n function calculateObj(): T {\n if (!calculated) {\n Object.assign(obj, objectFunc(obj));\n calculated = true;\n }\n return obj as S & T;\n }\n\n return new Proxy(obj, {\n get(target, key) {\n if (key === ProxyState) {\n return calculateObj();\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return (calculateObj() as any)[key];\n },\n set(target, key, value) {\n // TODO give warning about this? It should only be done with caution\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (calculateObj() as any)[key] = value;\n return true;\n },\n has(target, key) {\n if (key === ProxyState) {\n return true;\n }\n return Reflect.has(calculateObj(), key);\n },\n ownKeys() {\n return Reflect.ownKeys(calculateObj());\n },\n getOwnPropertyDescriptor(target, key) {\n if (!calculated) {\n Object.assign(obj, objectFunc(obj));\n calculated = true;\n }\n return Object.getOwnPropertyDescriptor(target, key);\n }\n }) as S & T;\n}\n","import projInfo from \"data/projInfo.json\";\nimport player, { Player, PlayerData, stringifySave } from \"game/player\";\nimport settings, { loadSettings } from \"game/settings\";\nimport { ProxyState } from \"./proxies\";\nimport LZString from \"lz-string\";\n\nexport function setupInitialStore(player: Partial = {}): Player {\n return Object.assign(\n {\n id: `${projInfo.id}-0`,\n name: \"Default Save\",\n tabs: projInfo.initialTabs.slice(),\n time: Date.now(),\n autosave: true,\n offlineProd: true,\n offlineTime: 0,\n timePlayed: 0,\n keepGoing: false,\n modID: projInfo.id,\n modVersion: projInfo.versionNumber,\n layers: {}\n },\n player\n ) as Player;\n}\n\nexport function save(playerData?: PlayerData): string {\n const stringifiedSave = LZString.compressToUTF16(\n stringifySave(playerData ?? player[ProxyState])\n );\n localStorage.setItem((playerData ?? player[ProxyState]).id, stringifiedSave);\n return stringifiedSave;\n}\n\nexport async function load(): Promise {\n // Load global settings\n loadSettings();\n\n try {\n let save = localStorage.getItem(settings.active);\n if (save == null) {\n await loadSave(newSave());\n return;\n }\n if (save[0] === \"{\") {\n // plaintext. No processing needed\n } else if (save[0] === \"e\") {\n // Assumed to be base64, which starts with e\n save = decodeURIComponent(escape(atob(save)));\n } else if (save[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n save = LZString.decompressFromUTF16(save)!;\n } else {\n throw `Unable to determine save encoding`;\n }\n const player = JSON.parse(save);\n if (player.modID !== projInfo.id) {\n await loadSave(newSave());\n return;\n }\n player.id = settings.active;\n await loadSave(player);\n } catch (e) {\n console.error(\"Failed to load save. Falling back to new save.\\n\", e);\n await loadSave(newSave());\n }\n}\n\nexport function newSave(): PlayerData {\n const id = getUniqueID();\n const player = setupInitialStore({ id });\n save(player);\n\n settings.saves.push(id);\n\n return player;\n}\n\nexport function getUniqueID(): string {\n let id,\n i = 0;\n do {\n id = `${projInfo.id}-${i++}`;\n } while (localStorage.getItem(id));\n return id;\n}\n\nexport async function loadSave(playerObj: Partial): Promise {\n console.info(\"Loading save\", playerObj);\n const { layers, removeLayer, addLayer } = await import(\"game/layers\");\n const { fixOldSave, getInitialLayers } = await import(\"data/projEntry\");\n\n for (const layer in layers) {\n const l = layers[layer];\n if (l) {\n removeLayer(l);\n }\n }\n getInitialLayers(playerObj).forEach(layer => addLayer(layer, playerObj));\n\n playerObj = setupInitialStore(playerObj);\n if (playerObj.offlineProd && playerObj.time) {\n if (playerObj.offlineTime == undefined) playerObj.offlineTime = 0;\n playerObj.offlineTime += (Date.now() - playerObj.time) / 1000;\n }\n playerObj.time = Date.now();\n if (playerObj.modVersion !== projInfo.versionNumber) {\n fixOldSave(playerObj.modVersion, playerObj);\n }\n\n Object.assign(player, playerObj);\n settings.active = player.id;\n}\n\nsetInterval(() => {\n if (player.autosave) {\n save();\n }\n}, 1000);\nwindow.onbeforeunload = () => {\n if (player.autosave) {\n save();\n }\n};\nwindow.save = save;\nexport const hardReset = (window.hardReset = async () => {\n await loadSave(newSave());\n});\n","\n\n\n","import { render } from \"./Profectus.vue?vue&type=template&id=07150322&scoped=true\"\nconst script = {}\n\nimport \"./Profectus.vue?vue&type=style&index=0&id=07150322&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-07150322\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n width: { default: \"8px\" },\n height: { default: \"17px\" }\n },\n setup(__props: any) {\n\n\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n style: _normalizeStyle({ width: __props.width, height: __props.height })\n }, null, 4))\n}\n}\n\n})","import script from \"./Spacer.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Spacer.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import Decimal, { DecimalSource, format, formatWhole } from \"util/bignum\";\nimport { computed, ComputedRef, isRef, ref, Ref, watch } from \"vue\";\nimport { globalBus } from \"game/events\";\nimport { State, persistent } from \"game/persistence\";\n\nexport interface Resource extends Ref {\n displayName: string;\n precision: number;\n small?: boolean;\n}\n\nexport function createResource(\n defaultValue: T | Ref,\n displayName = \"points\",\n precision = 0,\n small = undefined\n): Resource {\n const resource: Partial> = isRef(defaultValue)\n ? defaultValue\n : persistent(defaultValue);\n resource.displayName = displayName;\n resource.precision = precision;\n resource.small = small;\n return resource as Resource;\n}\n\nexport function trackBest(resource: Resource): Ref {\n const best = persistent(resource.value);\n watch(resource, amount => {\n if (Decimal.gt(amount, best.value)) {\n best.value = amount;\n }\n });\n return best;\n}\n\nexport function trackTotal(resource: Resource): Ref {\n const total = persistent(resource.value);\n watch(resource, (amount, prevAmount) => {\n if (Decimal.gt(amount, prevAmount)) {\n total.value = Decimal.add(total.value, Decimal.sub(amount, prevAmount));\n }\n });\n return total;\n}\n\nconst tetra8 = new Decimal(\"10^^8\");\nconst e100 = new Decimal(\"1e100\");\nexport function trackOOMPS(\n resource: Resource,\n pointGain?: ComputedRef\n): Ref {\n const oomps = ref(0);\n const oompsMag = ref(0);\n const lastPoints = ref(0);\n\n globalBus.on(\"update\", diff => {\n oompsMag.value = 0;\n if (Decimal.lte(resource.value, e100)) {\n lastPoints.value = resource.value;\n return;\n }\n\n let curr = resource.value;\n let prev = lastPoints.value;\n lastPoints.value = curr;\n if (Decimal.gt(curr, prev)) {\n if (Decimal.gte(curr, tetra8)) {\n curr = Decimal.slog(curr, 1e10);\n prev = Decimal.slog(prev, 1e10);\n oomps.value = curr.sub(prev).div(diff);\n oompsMag.value = -1;\n } else {\n while (\n Decimal.div(curr, prev).log(10).div(diff).gte(\"100\") &&\n oompsMag.value <= 5 &&\n Decimal.gt(prev, 0)\n ) {\n curr = Decimal.log10(curr);\n prev = Decimal.log10(prev);\n oomps.value = curr.sub(prev).div(diff);\n oompsMag.value++;\n }\n }\n }\n });\n\n const oompsString = computed(() => {\n if (oompsMag.value === 0) {\n return pointGain\n ? format(pointGain.value, resource.precision, resource.small) +\n \" \" +\n resource.displayName +\n \"/s\"\n : \"\";\n }\n return (\n format(oomps.value) +\n \" OOM\" +\n (oompsMag.value < 0 ? \"^OOM\" : \"^\" + oompsMag.value) +\n \"s/sec\"\n );\n });\n return oompsString;\n}\n\nexport function displayResource(resource: Resource, overrideAmount?: DecimalSource): string {\n const amount = overrideAmount ?? resource.value;\n if (Decimal.eq(resource.precision, 0)) {\n return formatWhole(amount);\n }\n return format(amount, resource.precision, resource.small);\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, Fragment as _Fragment, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Links = _resolveComponent(\"Links\")!\n\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.nodesComp))),\n (_ctx.leftNodesComp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.leftNodesComp), { key: 0 }))\n : _createCommentVNode(\"\", true),\n (_ctx.rightNodesComp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.rightNodesComp), { key: 1 }))\n : _createCommentVNode(\"\", true),\n (_ctx.branches)\n ? (_openBlock(), _createBlock(_component_Links, {\n key: 2,\n links: _ctx.unref(_ctx.branches)\n }, null, 8, [\"links\"]))\n : _createCommentVNode(\"\", true)\n ], 64))\n}","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, mergeProps as _mergeProps, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = [\"x1\", \"y1\", \"x2\", \"y2\"]\n\nimport { Link } from \"features/links/links\";\nimport { FeatureNode } from \"game/layers\";\nimport { computed, toRefs } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n link: null,\n startNode: null,\n endNode: null,\n boundingRect: null\n },\n setup(__props: any) {\n\nconst _props = __props as {\n link: Link;\n startNode: FeatureNode;\n endNode: FeatureNode;\n boundingRect: DOMRect | undefined;\n}\n\n\nconst props = toRefs(_props);\n\nconst startPosition = computed(() => {\n const rect = props.startNode.value.rect;\n const boundingRect = props.boundingRect.value;\n const position = boundingRect\n ? {\n x: rect.x + rect.width / 2 - boundingRect.x,\n y: rect.y + rect.height / 2 - boundingRect.y\n }\n : { x: 0, y: 0 };\n if (props.link.value.offsetStart) {\n position.x += props.link.value.offsetStart.x;\n position.y += props.link.value.offsetStart.y;\n }\n return position;\n});\n\nconst endPosition = computed(() => {\n const rect = props.endNode.value.rect;\n const boundingRect = props.boundingRect.value;\n const position = boundingRect\n ? {\n x: rect.x + rect.width / 2 - boundingRect.x,\n y: rect.y + rect.height / 2 - boundingRect.y\n }\n : { x: 0, y: 0 };\n if (props.link.value.offsetEnd) {\n position.x += props.link.value.offsetEnd.x;\n position.y += props.link.value.offsetEnd.y;\n }\n return position;\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"line\", _mergeProps({\n \"stroke-width\": \"15px\",\n stroke: \"white\"\n }, __props.link, {\n x1: _unref(startPosition).x,\n y1: _unref(startPosition).y,\n x2: _unref(endPosition).x,\n y2: _unref(endPosition).y\n }), null, 16, _hoisted_1))\n}\n}\n\n})","import script from \"./Link.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Link.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, createBlock as _createBlock, normalizeProps as _normalizeProps, guardReactiveProps as _guardReactiveProps, mergeProps as _mergeProps, createCommentVNode as _createCommentVNode, createElementVNode as _createElementVNode } from \"vue\"\n\nimport { Link } from \"features/links/links\";\nimport { BoundsInjectionKey, NodesInjectionKey } from \"game/layers\";\nimport { computed, inject, ref, toRef, watch } from \"vue\";\nimport LinkVue from \"./Link.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n links: null\n },\n setup(__props: any) {\n\nconst _props = __props as { links?: Link[] }\n\n\nconst links = toRef(_props, \"links\");\n\nconst resizeListener = ref(null);\n\n// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\nconst nodes = inject(NodesInjectionKey)!;\n// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\nconst outerBoundingRect = inject(BoundsInjectionKey)!;\nconst boundingRect = ref(undefined);\nwatch(\n [outerBoundingRect],\n () => (boundingRect.value = resizeListener.value?.getBoundingClientRect())\n);\n\nconst validLinks = computed(() => {\n const n = nodes.value;\n return (\n links.value?.filter(link => n[link.startNode.id]?.rect && n[link.startNode.id]?.rect) ?? []\n );\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (_unref(validLinks))\n ? (_openBlock(), _createElementBlock(\"svg\", _normalizeProps(_mergeProps({ key: 0 }, _ctx.$attrs)), [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_unref(validLinks), (link, index) => {\n return (_openBlock(), _createBlock(LinkVue, {\n key: index,\n link: link,\n boundingRect: boundingRect.value,\n startNode: _unref(nodes)[link.startNode.id]!,\n endNode: _unref(nodes)[link.endNode.id]!\n }, null, 8, [\"link\", \"boundingRect\", \"startNode\", \"endNode\"]))\n }), 128))\n ], 16))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", {\n ref_key: \"resizeListener\",\n ref: resizeListener,\n class: \"resize-listener\"\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./Links.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Links.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Links.vue?vue&type=style&index=0&id=2bbc19c2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-2bbc19c2\"]])\n\nexport default __exports__","\nimport \"components/common/table.css\";\nimport { GenericTreeNode, TreeBranch } from \"features/trees/tree\";\nimport { coerceComponent, processedPropType, renderJSX, unwrapRef } from \"util/vue\";\nimport { Component, defineComponent, shallowRef, toRefs, unref, watchEffect } from \"vue\";\nimport Links from \"features/links/Links.vue\";\nimport { jsx } from \"features/feature\";\n\nexport default defineComponent({\n props: {\n nodes: {\n type: processedPropType(Array),\n required: true\n },\n leftSideNodes: processedPropType(Array),\n rightSideNodes: processedPropType(Array),\n branches: processedPropType(Array)\n },\n components: { Links },\n setup(props) {\n const { nodes, leftSideNodes, rightSideNodes } = toRefs(props);\n\n const nodesComp = shallowRef();\n watchEffect(() => {\n const currNodes = unwrapRef(nodes);\n nodesComp.value = coerceComponent(\n jsx(() => (\n <>\n {currNodes.map(row => (\n \n {row.map(renderJSX)}\n \n ))}\n \n ))\n );\n });\n\n const leftNodesComp = shallowRef();\n watchEffect(() => {\n const currNodes = unwrapRef(leftSideNodes);\n leftNodesComp.value = currNodes\n ? coerceComponent(\n jsx(() => (\n {currNodes.map(renderJSX)}\n ))\n )\n : \"\";\n });\n\n const rightNodesComp = shallowRef();\n watchEffect(() => {\n const currNodes = unwrapRef(rightSideNodes);\n rightNodesComp.value = currNodes\n ? coerceComponent(\n jsx(() => {currNodes.map(renderJSX)})\n )\n : \"\";\n });\n\n return {\n unref,\n nodesComp,\n leftNodesComp,\n rightNodesComp\n };\n }\n});\n","import { render } from \"./Tree.vue?vue&type=template&id=aa87859c&scoped=true&ts=true\"\nimport script from \"./Tree.vue?vue&type=script&lang=tsx\"\nexport * from \"./Tree.vue?vue&type=script&lang=tsx\"\n\nimport \"./Tree.vue?vue&type=style&index=0&id=aa87859c&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-aa87859c\"]])\n\nexport default __exports__","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle({ visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined }),\n class: _normalizeClass({\n treeNode: true,\n can: _ctx.unref(_ctx.canClick),\n ..._ctx.unref(_ctx.classes)\n }),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.onClick && _ctx.onClick(...args))),\n onMousedown: _cache[1] || (_cache[1] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onMouseleave: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onMouseup: _cache[3] || (_cache[3] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchstartPassive: _cache[4] || (_cache[4] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onTouchendPassive: _cache[5] || (_cache[5] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchcancelPassive: _cache[6] || (_cache[6] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args)))\n }, [\n _createElementVNode(\"div\", {\n style: _normalizeStyle([\n {\n backgroundColor: _ctx.unref(_ctx.color),\n boxShadow: `-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 20px ${_ctx.unref(\n _ctx.glowColor\n )}`\n },\n _ctx.unref(_ctx.style) ?? []\n ])\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp))))\n ], 4),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 38))\n : _createCommentVNode(\"\", true)\n}","import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { RegisterNodeInjectionKey, UnregisterNodeInjectionKey } from \"game/layers\";\nimport { computed, inject, onUnmounted, ref, toRefs, unref, watch } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n id: null\n },\n setup(__props: any) {\n\nconst _props = __props as { id: string }\n\n\nconst props = toRefs(_props);\n\nconst register = inject(RegisterNodeInjectionKey);\nconst unregister = inject(UnregisterNodeInjectionKey);\n\nconst node = ref(null);\nconst parentNode = computed(() => node.value && node.value.parentElement);\n\nif (register && unregister) {\n watch([parentNode, props.id], ([newNode, newID], [prevNode, prevID]) => {\n if (prevNode) {\n unregister(unref(prevID));\n }\n if (newNode) {\n register(newID, newNode);\n }\n });\n\n onUnmounted(() => unregister(unref(props.id)));\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"node\",\n ref_key: \"node\",\n ref: node\n }, null, 512))\n}\n}\n\n})","import script from \"./Node.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Node.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Node.vue?vue&type=style&index=0&id=63ded336&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-63ded336\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-c476c56a\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { key: 0 }\nconst _hoisted_2 = {\n key: 0,\n class: \"mark star\"\n}\nconst _hoisted_3 = [\"src\"]\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n mark: { type: [Boolean, String] }\n },\n setup(__props: any) {\n\n\n\nreturn (_ctx: any,_cache: any) => {\n return (__props.mark)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (__props.mark === true)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_2))\n : (_openBlock(), _createElementBlock(\"img\", {\n key: 1,\n class: \"mark\",\n src: __props.mark\n }, null, 8, _hoisted_3))\n ]))\n : _createCommentVNode(\"\", true)\n}\n}\n\n})","import script from \"./MarkNode.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./MarkNode.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./MarkNode.vue?vue&type=style&index=0&id=c476c56a&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-c476c56a\"]])\n\nexport default __exports__","\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport {\n computeOptionalComponent,\n isCoercableComponent,\n processedPropType,\n setupHoldToClick\n} from \"util/vue\";\nimport { defineComponent, PropType, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n display: processedPropType(Object, String, Function),\n visibility: {\n type: processedPropType(Number),\n required: true\n },\n style: processedPropType(String, Object, Array),\n classes: processedPropType>(Object),\n onClick: Function as PropType<(e?: MouseEvent | TouchEvent) => void>,\n onHold: Function as PropType,\n color: processedPropType(String),\n glowColor: processedPropType(String),\n canClick: {\n type: processedPropType(Boolean),\n required: true\n },\n mark: processedPropType(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n MarkNode,\n Node\n },\n setup(props) {\n const { onClick, onHold, display } = toRefs(props);\n\n const comp = computeOptionalComponent(display);\n\n const { start, stop } = setupHoldToClick(onClick, onHold);\n\n return {\n start,\n stop,\n comp,\n unref,\n Visibility,\n isCoercableComponent\n };\n }\n});\n","import { render } from \"./TreeNode.vue?vue&type=template&id=094cdcfe&scoped=true&ts=true\"\nimport script from \"./TreeNode.vue?vue&type=script&lang=ts\"\nexport * from \"./TreeNode.vue?vue&type=script&lang=ts\"\n\nimport \"./TreeNode.vue?vue&type=style&index=0&id=094cdcfe&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-094cdcfe\"]])\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { Link } from \"features/links/links\";\nimport { GenericReset } from \"features/reset\";\nimport { displayResource, Resource } from \"features/resources/resource\";\nimport TreeComponent from \"features/trees/Tree.vue\";\nimport TreeNodeComponent from \"features/trees/TreeNode.vue\";\nimport Decimal, { DecimalSource, format, formatWhole } from \"util/bignum\";\nimport {\n Computable,\n convertComputable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, ref, Ref, shallowRef, unref } from \"vue\";\n\nexport const TreeNodeType = Symbol(\"TreeNode\");\nexport const TreeType = Symbol(\"Tree\");\n\nexport interface TreeNodeOptions {\n visibility?: Computable;\n canClick?: Computable;\n color?: Computable;\n display?: Computable;\n glowColor?: Computable;\n classes?: Computable>;\n style?: Computable;\n mark?: Computable;\n reset?: GenericReset;\n onClick?: (e?: MouseEvent | TouchEvent) => void;\n onHold?: VoidFunction;\n}\n\nexport interface BaseTreeNode {\n id: string;\n type: typeof TreeNodeType;\n [Component]: typeof TreeNodeComponent;\n [GatherProps]: () => Record;\n}\n\nexport type TreeNode = Replace<\n T & BaseTreeNode,\n {\n visibility: GetComputableTypeWithDefault;\n canClick: GetComputableTypeWithDefault;\n color: GetComputableType;\n display: GetComputableType;\n glowColor: GetComputableType;\n classes: GetComputableType;\n style: GetComputableType;\n mark: GetComputableType;\n }\n>;\n\nexport type GenericTreeNode = Replace<\n TreeNode,\n {\n visibility: ProcessedComputable;\n canClick: ProcessedComputable;\n }\n>;\n\nexport function createTreeNode(\n optionsFunc?: OptionsFunc, BaseTreeNode>\n): TreeNode {\n return createLazyProxy(() => {\n const treeNode = optionsFunc?.() ?? ({} as ReturnType>);\n treeNode.id = getUniqueID(\"treeNode-\");\n treeNode.type = TreeNodeType;\n treeNode[Component] = TreeNodeComponent;\n\n processComputable(treeNode as T, \"visibility\");\n setDefault(treeNode, \"visibility\", Visibility.Visible);\n processComputable(treeNode as T, \"canClick\");\n setDefault(treeNode, \"canClick\", true);\n processComputable(treeNode as T, \"color\");\n processComputable(treeNode as T, \"display\");\n processComputable(treeNode as T, \"glowColor\");\n processComputable(treeNode as T, \"classes\");\n processComputable(treeNode as T, \"style\");\n processComputable(treeNode as T, \"mark\");\n\n if (treeNode.onClick) {\n const onClick = treeNode.onClick.bind(treeNode);\n treeNode.onClick = function () {\n if (unref(treeNode.canClick)) {\n onClick();\n }\n };\n }\n if (treeNode.onHold) {\n const onHold = treeNode.onHold.bind(treeNode);\n treeNode.onHold = function () {\n if (unref(treeNode.canClick)) {\n onHold();\n }\n };\n }\n\n treeNode[GatherProps] = function (this: GenericTreeNode) {\n const {\n display,\n visibility,\n style,\n classes,\n onClick,\n onHold,\n color,\n glowColor,\n canClick,\n mark,\n id\n } = this;\n return {\n display,\n visibility,\n style,\n classes,\n onClick,\n onHold,\n color,\n glowColor,\n canClick,\n mark,\n id\n };\n };\n\n return treeNode as unknown as TreeNode;\n });\n}\n\nexport interface TreeBranch extends Omit {\n startNode: GenericTreeNode;\n endNode: GenericTreeNode;\n}\n\nexport interface TreeOptions {\n visibility?: Computable;\n nodes: Computable;\n leftSideNodes?: Computable;\n rightSideNodes?: Computable;\n branches?: Computable;\n resetPropagation?: ResetPropagation;\n onReset?: (node: GenericTreeNode) => void;\n}\n\nexport interface BaseTree {\n id: string;\n links: Ref;\n reset: (node: GenericTreeNode) => void;\n isResetting: Ref;\n resettingNode: Ref;\n type: typeof TreeType;\n [Component]: typeof TreeComponent;\n [GatherProps]: () => Record;\n}\n\nexport type Tree = Replace<\n T & BaseTree,\n {\n visibility: GetComputableTypeWithDefault;\n nodes: GetComputableType;\n leftSideNodes: GetComputableType;\n rightSideNodes: GetComputableType;\n branches: GetComputableType;\n }\n>;\n\nexport type GenericTree = Replace<\n Tree,\n {\n visibility: ProcessedComputable;\n }\n>;\n\nexport function createTree(\n optionsFunc: OptionsFunc, BaseTree>\n): Tree {\n return createLazyProxy(() => {\n const tree = optionsFunc();\n tree.id = getUniqueID(\"tree-\");\n tree.type = TreeType;\n tree[Component] = TreeComponent;\n\n tree.isResetting = ref(false);\n tree.resettingNode = shallowRef(null);\n\n tree.reset = function (node) {\n const genericTree = tree as GenericTree;\n genericTree.isResetting.value = true;\n genericTree.resettingNode.value = node;\n genericTree.resetPropagation?.(genericTree, node);\n genericTree.onReset?.(node);\n genericTree.isResetting.value = false;\n genericTree.resettingNode.value = null;\n };\n tree.links = computed(() => {\n const genericTree = tree as GenericTree;\n return unref(genericTree.branches) ?? [];\n });\n\n processComputable(tree as T, \"visibility\");\n setDefault(tree, \"visibility\", Visibility.Visible);\n processComputable(tree as T, \"nodes\");\n processComputable(tree as T, \"leftSideNodes\");\n processComputable(tree as T, \"rightSideNodes\");\n processComputable(tree as T, \"branches\");\n\n tree[GatherProps] = function (this: GenericTree) {\n const { nodes, leftSideNodes, rightSideNodes, branches } = this;\n return { nodes, leftSideNodes, rightSideNodes, branches };\n };\n\n return tree as unknown as Tree;\n });\n}\n\nexport type ResetPropagation = {\n (tree: GenericTree, resettingNode: GenericTreeNode): void;\n};\n\nexport const defaultResetPropagation = function (\n tree: GenericTree,\n resettingNode: GenericTreeNode\n): void {\n const nodes = unref(tree.nodes);\n const row = nodes.findIndex(nodes => nodes.includes(resettingNode)) - 1;\n for (let x = row; x >= 0; x--) {\n nodes[x].forEach(node => node.reset?.reset());\n }\n};\n\nexport const invertedResetPropagation = function (\n tree: GenericTree,\n resettingNode: GenericTreeNode\n): void {\n const nodes = unref(tree.nodes);\n const row = nodes.findIndex(nodes => nodes.includes(resettingNode)) + 1;\n for (let x = row; x < nodes.length; x++) {\n nodes[x].forEach(node => node.reset?.reset());\n }\n};\n\nexport const branchedResetPropagation = function (\n tree: GenericTree,\n resettingNode: GenericTreeNode\n): void {\n const visitedNodes = [resettingNode];\n let currentNodes = [resettingNode];\n if (tree.branches != null) {\n const branches = unref(tree.branches);\n while (currentNodes.length > 0) {\n const nextNodes: GenericTreeNode[] = [];\n currentNodes.forEach(node => {\n branches\n .filter(branch => branch.startNode === node || branch.endNode === node)\n .map(branch => {\n if (branch.startNode === node) {\n return branch.endNode;\n }\n return branch.startNode;\n })\n .filter(node => !visitedNodes.includes(node))\n .forEach(node => {\n // Check here instead of in the filter because this check's results may\n // change as we go through each node\n if (!nextNodes.includes(node)) {\n nextNodes.push(node);\n node.reset?.reset();\n }\n });\n });\n currentNodes = nextNodes;\n visitedNodes.push(...currentNodes);\n }\n }\n};\n\nexport function createResourceTooltip(\n resource: Resource,\n requiredResource: Resource | null = null,\n requirement: Computable = 0\n): Ref {\n const req = convertComputable(requirement);\n return computed(() => {\n if (requiredResource == null || Decimal.gte(resource.value, unref(req))) {\n return displayResource(resource) + \" \" + resource.displayName;\n }\n return `Reach ${\n Decimal.eq(requiredResource.precision, 0)\n ? formatWhole(unref(req))\n : format(unref(req), requiredResource.precision)\n } ${requiredResource.displayName} to unlock (You have ${\n Decimal.eq(requiredResource.precision, 0)\n ? formatWhole(requiredResource.value)\n : format(requiredResource.value, requiredResource.precision)\n })`;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined,\n backgroundImage: (_ctx.earned && _ctx.image && `url(${_ctx.image})`) || ''\n },\n _ctx.unref(_ctx.style) ?? []\n ]),\n class: _normalizeClass({\n feature: true,\n achievement: true,\n locked: !_ctx.unref(_ctx.earned),\n bought: _ctx.unref(_ctx.earned),\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n (_ctx.component)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport { CoercableComponent, Visibility } from \"features/feature\";\nimport { computeOptionalComponent, processedPropType } from \"util/vue\";\nimport { defineComponent, StyleValue, toRefs, unref } from \"vue\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport \"components/common/features.css\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType(Number),\n required: true\n },\n display: processedPropType(Object, String, Function),\n earned: {\n type: processedPropType(Boolean),\n required: true\n },\n image: processedPropType(String),\n style: processedPropType(String, Object, Array),\n classes: processedPropType>(Object),\n mark: processedPropType(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node,\n MarkNode\n },\n setup(props) {\n const { display } = toRefs(props);\n\n return {\n component: computeOptionalComponent(display),\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Achievement.vue?vue&type=template&id=e3f32402&scoped=true&ts=true\"\nimport script from \"./Achievement.vue?vue&type=script&lang=ts\"\nexport * from \"./Achievement.vue?vue&type=script&lang=ts\"\n\nimport \"./Achievement.vue?vue&type=style&index=0&id=e3f32402&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e3f32402\"]])\n\nexport default __exports__","import { globalBus } from \"game/events\";\nimport Toast from \"vue-toastification\";\nimport \"vue-toastification/dist/index.css\";\n\nglobalBus.on(\"setupVue\", vue => vue.use(Toast));\n\nexport function getNotifyStyle(color = \"white\", strength = \"8px\") {\n return {\n transform: \"scale(1.05, 1.05)\",\n borderColor: \"rgba(0, 0, 0, 0.125)\",\n boxShadow: `-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 ${strength} ${color}`,\n zIndex: 1\n };\n}\n\nexport function getHighNotifyStyle() {\n return getNotifyStyle(\"red\", \"20px\");\n}\n","import AchievementComponent from \"features/achievements/Achievement.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport \"game/notifications\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { coerceComponent } from \"util/vue\";\nimport { unref, watchEffect } from \"vue\";\nimport { useToast } from \"vue-toastification\";\n\nconst toast = useToast();\n\nexport const AchievementType = Symbol(\"Achievement\");\n\nexport interface AchievementOptions {\n visibility?: Computable;\n shouldEarn?: () => boolean;\n display?: Computable;\n mark?: Computable;\n image?: Computable;\n style?: Computable;\n classes?: Computable>;\n onComplete?: VoidFunction;\n}\n\nexport interface BaseAchievement {\n id: string;\n earned: Persistent;\n complete: VoidFunction;\n type: typeof AchievementType;\n [Component]: typeof AchievementComponent;\n [GatherProps]: () => Record;\n}\n\nexport type Achievement = Replace<\n T & BaseAchievement,\n {\n visibility: GetComputableTypeWithDefault;\n display: GetComputableType;\n mark: GetComputableType;\n image: GetComputableType;\n style: GetComputableType;\n classes: GetComputableType;\n }\n>;\n\nexport type GenericAchievement = Replace<\n Achievement,\n {\n visibility: ProcessedComputable;\n }\n>;\n\nexport function createAchievement(\n optionsFunc?: OptionsFunc, BaseAchievement>\n): Achievement {\n const earned = persistent(false);\n return createLazyProxy(() => {\n const achievement = optionsFunc?.() ?? ({} as ReturnType>);\n achievement.id = getUniqueID(\"achievement-\");\n achievement.type = AchievementType;\n achievement[Component] = AchievementComponent;\n\n achievement.earned = earned;\n achievement.complete = function () {\n earned.value = true;\n };\n\n processComputable(achievement as T, \"visibility\");\n setDefault(achievement, \"visibility\", Visibility.Visible);\n processComputable(achievement as T, \"display\");\n processComputable(achievement as T, \"mark\");\n processComputable(achievement as T, \"image\");\n processComputable(achievement as T, \"style\");\n processComputable(achievement as T, \"classes\");\n\n achievement[GatherProps] = function (this: GenericAchievement) {\n const { visibility, display, earned, image, style, classes, mark, id } = this;\n return { visibility, display, earned, image, style: unref(style), classes, mark, id };\n };\n\n if (achievement.shouldEarn) {\n const genericAchievement = achievement as GenericAchievement;\n watchEffect(() => {\n if (\n !genericAchievement.earned.value &&\n unref(genericAchievement.visibility) === Visibility.Visible &&\n genericAchievement.shouldEarn?.()\n ) {\n genericAchievement.earned.value = true;\n genericAchievement.onComplete?.();\n if (genericAchievement.display) {\n const Display = coerceComponent(unref(genericAchievement.display));\n toast.info(\n
\n

Achievement earned!

\n
\n {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}\n {/* @ts-ignore */}\n \n
\n
\n );\n }\n }\n });\n }\n\n return achievement as unknown as Achievement;\n });\n}\n","import { renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, resolveComponent as _resolveComponent, mergeProps as _mergeProps, createBlock as _createBlock, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_GridCell = _resolveComponent(\"GridCell\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle({\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n }),\n class: \"table\"\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.unref(_ctx.rows), (row) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"row\", { mergeAdjacent: _ctx.mergeAdjacent }]),\n key: row\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.unref(_ctx.cols), (col) => {\n return (_openBlock(), _createBlock(_component_GridCell, _mergeProps({ key: col }, _ctx.gatherCellProps(_ctx.unref(_ctx.cells)[row * 100 + col])), null, 16))\n }), 128))\n ], 2))\n }), 128))\n ], 4))\n : _createCommentVNode(\"\", true)\n}","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-b27416ec\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { key: 0 }\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n class: _normalizeClass({ feature: true, tile: true, can: _ctx.unref(_ctx.canClick), locked: !_ctx.unref(_ctx.canClick) }),\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.onClick && _ctx.onClick(...args))),\n onMousedown: _cache[1] || (_cache[1] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onMouseleave: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onMouseup: _cache[3] || (_cache[3] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchstartPassive: _cache[4] || (_cache[4] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onTouchendPassive: _cache[5] || (_cache[5] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchcancelPassive: _cache[6] || (_cache[6] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args)))\n }, [\n (_ctx.title)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.titleComponent)))\n ]))\n : _createCommentVNode(\"\", true),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component), { style: {\"white-space\":\"pre-line\"} })),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 38))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport Node from \"components/Node.vue\";\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport {\n computeComponent,\n computeOptionalComponent,\n processedPropType,\n setupHoldToClick\n} from \"util/vue\";\nimport { defineComponent, PropType, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType(Number),\n required: true\n },\n onClick: Function as PropType<(e?: MouseEvent | TouchEvent) => void>,\n onHold: Function as PropType,\n display: {\n type: processedPropType(Object, String, Function),\n required: true\n },\n title: processedPropType(Object, String, Function),\n style: processedPropType(String, Object, Array),\n canClick: {\n type: processedPropType(Boolean),\n required: true\n },\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node\n },\n setup(props) {\n const { onClick, onHold, title, display } = toRefs(props);\n\n const { start, stop } = setupHoldToClick(onClick, onHold);\n\n const titleComponent = computeOptionalComponent(title);\n const component = computeComponent(display);\n\n return {\n start,\n stop,\n titleComponent,\n component,\n Visibility,\n unref\n };\n }\n});\n","import { render } from \"./GridCell.vue?vue&type=template&id=b27416ec&scoped=true&ts=true\"\nimport script from \"./GridCell.vue?vue&type=script&lang=ts\"\nexport * from \"./GridCell.vue?vue&type=script&lang=ts\"\n\nimport \"./GridCell.vue?vue&type=style&index=0&id=b27416ec&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-b27416ec\"]])\n\nexport default __exports__","\nimport \"components/common/table.css\";\nimport themes from \"data/themes\";\nimport { Visibility } from \"features/feature\";\nimport { GridCell } from \"features/grids/grid\";\nimport settings from \"game/settings\";\nimport { processedPropType } from \"util/vue\";\nimport { computed, defineComponent, unref } from \"vue\";\nimport GridCellVue from \"./GridCell.vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType(Number),\n required: true\n },\n rows: {\n type: processedPropType(Number),\n required: true\n },\n cols: {\n type: processedPropType(Number),\n required: true\n },\n cells: {\n type: processedPropType>(Object),\n required: true\n }\n },\n components: { GridCell: GridCellVue },\n setup() {\n const mergeAdjacent = computed(() => themes[settings.theme].mergeAdjacent);\n\n function gatherCellProps(cell: GridCell) {\n const { visibility, onClick, onHold, display, title, style, canClick, id } = cell;\n return { visibility, onClick, onHold, display, title, style, canClick, id };\n }\n\n return { unref, gatherCellProps, Visibility, mergeAdjacent };\n }\n});\n","import { render } from \"./Grid.vue?vue&type=template&id=4f6b6717&ts=true\"\nimport script from \"./Grid.vue?vue&type=script&lang=ts\"\nexport * from \"./Grid.vue?vue&type=script&lang=ts\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__","import GridComponent from \"features/grids/Grid.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { isFunction } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { State, Persistent, persistent } from \"game/persistence\";\n\nexport const GridType = Symbol(\"Grid\");\n\nexport type CellComputable = Computable | ((id: string | number, state: State) => T);\n\nfunction createGridProxy(grid: GenericGrid): Record {\n return new Proxy({}, getGridHandler(grid)) as Record;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getGridHandler(grid: GenericGrid): ProxyHandler> {\n const keys = computed(() => {\n const keys = [];\n for (let row = 1; row <= unref(grid.rows); row++) {\n for (let col = 1; col <= unref(grid.cols); col++) {\n keys.push((row * 100 + col).toString());\n }\n }\n return keys;\n });\n return {\n get(target: Record, key: PropertyKey) {\n if (key === \"isProxy\") {\n return true;\n }\n\n if (typeof key === \"symbol\") {\n return (grid as never)[key];\n }\n\n if (!keys.value.includes(key.toString())) {\n return undefined;\n }\n\n if (target[key] == null) {\n target[key] = new Proxy(\n grid,\n getCellHandler(key.toString())\n ) as unknown as GridCell;\n }\n\n return target[key];\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n set(target: Record, key: PropertyKey, value: any) {\n console.warn(\"Cannot set grid cells\", target, key, value);\n return false;\n },\n ownKeys() {\n return keys.value;\n },\n has(target: Record, key: PropertyKey) {\n return keys.value.includes(key.toString());\n },\n getOwnPropertyDescriptor(target: Record, key: PropertyKey) {\n if (keys.value.includes(key.toString())) {\n return {\n configurable: true,\n enumerable: true,\n writable: false\n };\n }\n }\n };\n}\n\nfunction getCellHandler(id: string): ProxyHandler {\n const keys = [\n \"id\",\n \"visibility\",\n \"canClick\",\n \"startState\",\n \"state\",\n \"style\",\n \"classes\",\n \"title\",\n \"display\",\n \"onClick\",\n \"onHold\"\n ];\n const cache: Record> = {};\n return {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get(target, key, receiver): any {\n if (key === \"isProxy\") {\n return true;\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let prop = (target as any)[key];\n\n if (isFunction(prop)) {\n return () => prop.call(receiver, id, target.getState(id));\n }\n if (prop != undefined || typeof key === \"symbol\") {\n return prop;\n }\n\n key = key.slice(0, 1).toUpperCase() + key.slice(1);\n\n if (key === \"startState\") {\n return prop.call(receiver, id);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n prop = (target as any)[`get${key}`];\n if (isFunction(prop)) {\n if (!(key in cache)) {\n cache[key] = computed(() => prop.call(receiver, id, target.getState(id)));\n }\n return cache[key].value;\n } else if (prop != undefined) {\n return unref(prop);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n prop = (target as any)[`on${key}`];\n if (isFunction(prop)) {\n return () => prop.call(receiver, id, target.getState(id));\n } else if (prop != undefined) {\n return prop;\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return (target as any)[key];\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n set(target: Record, key: string, value: any, receiver: typeof Proxy): boolean {\n key = `set${key.slice(0, 1).toUpperCase() + key.slice(1)}`;\n if (key in target && isFunction(target[key]) && target[key].length < 3) {\n target[key].call(receiver, id, value);\n return true;\n } else {\n console.warn(`No setter for \"${key}\".`, target);\n return false;\n }\n },\n ownKeys() {\n return keys;\n },\n has(target, key) {\n return keys.includes(key.toString());\n },\n getOwnPropertyDescriptor(target, key) {\n if (keys.includes(key.toString())) {\n return {\n configurable: true,\n enumerable: true,\n writable: false\n };\n }\n }\n };\n}\n\nexport interface GridCell {\n id: string;\n visibility: Visibility;\n canClick: boolean;\n startState: State;\n state: State;\n style?: StyleValue;\n classes?: Record;\n title?: CoercableComponent;\n display: CoercableComponent;\n onClick?: (e?: MouseEvent | TouchEvent) => void;\n onHold?: VoidFunction;\n}\n\nexport interface GridOptions {\n visibility?: Computable;\n rows: Computable;\n cols: Computable;\n getVisibility?: CellComputable;\n getCanClick?: CellComputable;\n getStartState: Computable | ((id: string | number) => State);\n getStyle?: CellComputable;\n getClasses?: CellComputable>;\n getTitle?: CellComputable;\n getDisplay: CellComputable;\n onClick?: (id: string | number, state: State, e?: MouseEvent | TouchEvent) => void;\n onHold?: (id: string | number, state: State) => void;\n}\n\nexport interface BaseGrid {\n id: string;\n getID: (id: string | number, state: State) => string;\n getState: (id: string | number) => State;\n setState: (id: string | number, state: State) => void;\n cells: Record;\n cellState: Persistent>;\n type: typeof GridType;\n [Component]: typeof GridComponent;\n [GatherProps]: () => Record;\n}\n\nexport type Grid = Replace<\n T & BaseGrid,\n {\n visibility: GetComputableTypeWithDefault;\n rows: GetComputableType;\n cols: GetComputableType;\n getVisibility: GetComputableTypeWithDefault;\n getCanClick: GetComputableTypeWithDefault;\n getStartState: GetComputableType;\n getStyle: GetComputableType;\n getClasses: GetComputableType;\n getTitle: GetComputableType;\n getDisplay: GetComputableType;\n }\n>;\n\nexport type GenericGrid = Replace<\n Grid,\n {\n visibility: ProcessedComputable;\n getVisibility: ProcessedComputable;\n getCanClick: ProcessedComputable;\n }\n>;\n\nexport function createGrid(\n optionsFunc: OptionsFunc, BaseGrid>\n): Grid {\n const cellState = persistent>({});\n return createLazyProxy(() => {\n const grid = optionsFunc();\n grid.id = getUniqueID(\"grid-\");\n grid[Component] = GridComponent;\n\n grid.cellState = cellState;\n\n grid.getID = function (this: GenericGrid, cell: string | number) {\n return grid.id + \"-\" + cell;\n };\n grid.getState = function (this: GenericGrid, cell: string | number) {\n if (this.cellState.value[cell] != undefined) {\n return cellState.value[cell];\n }\n return this.cells[cell].startState;\n };\n grid.setState = function (this: GenericGrid, cell: string | number, state: State) {\n cellState.value[cell] = state;\n };\n\n grid.cells = createGridProxy(grid as GenericGrid);\n\n processComputable(grid as T, \"visibility\");\n setDefault(grid, \"visibility\", Visibility.Visible);\n processComputable(grid as T, \"rows\");\n processComputable(grid as T, \"cols\");\n processComputable(grid as T, \"getVisibility\");\n setDefault(grid, \"getVisibility\", Visibility.Visible);\n processComputable(grid as T, \"getCanClick\");\n setDefault(grid, \"getCanClick\", true);\n processComputable(grid as T, \"getStartState\");\n processComputable(grid as T, \"getStyle\");\n processComputable(grid as T, \"getClasses\");\n processComputable(grid as T, \"getTitle\");\n processComputable(grid as T, \"getDisplay\");\n\n if (grid.onClick) {\n const onClick = grid.onClick.bind(grid);\n grid.onClick = function (id, state) {\n if (unref((grid as GenericGrid).cells[id].canClick)) {\n onClick(id, state);\n }\n };\n }\n if (grid.onHold) {\n const onHold = grid.onHold.bind(grid);\n grid.onHold = function (id, state) {\n if (unref((grid as GenericGrid).cells[id].canClick)) {\n onHold(id, state);\n }\n };\n }\n\n grid[GatherProps] = function (this: GenericGrid) {\n const { visibility, rows, cols, cells, id } = this;\n return { visibility, rows, cols, cells, id };\n };\n\n return grid as unknown as Grid;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n style: _normalizeStyle([\n { visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined },\n _ctx.unref(_ctx.style) ?? []\n ]),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.onClick && _ctx.onClick(...args))),\n onMousedown: _cache[1] || (_cache[1] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onMouseleave: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onMouseup: _cache[3] || (_cache[3] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchstartPassive: _cache[4] || (_cache[4] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onTouchendPassive: _cache[5] || (_cache[5] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchcancelPassive: _cache[6] || (_cache[6] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n class: _normalizeClass({\n feature: true,\n clickable: true,\n can: _ctx.unref(_ctx.canClick),\n locked: !_ctx.unref(_ctx.canClick),\n small: _ctx.small,\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n (_ctx.unref(_ctx.comp))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp)), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 38))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { GenericClickable } from \"features/clickables/clickable\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport {\n coerceComponent,\n isCoercableComponent,\n processedPropType,\n setupHoldToClick,\n unwrapRef\n} from \"util/vue\";\nimport {\n Component,\n defineComponent,\n PropType,\n shallowRef,\n toRefs,\n unref,\n UnwrapRef,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n display: {\n type: processedPropType>(\n Object,\n String,\n Function\n ),\n required: true\n },\n visibility: {\n type: processedPropType(Number),\n required: true\n },\n style: processedPropType(Object, String, Array),\n classes: processedPropType>(Object),\n onClick: Function as PropType<(e?: MouseEvent | TouchEvent) => void>,\n onHold: Function as PropType,\n canClick: {\n type: processedPropType(Boolean),\n required: true\n },\n small: Boolean,\n mark: processedPropType(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node,\n MarkNode\n },\n setup(props) {\n const { display, onClick, onHold } = toRefs(props);\n\n const comp = shallowRef(\"\");\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n comp.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n comp.value = coerceComponent(currDisplay);\n return;\n }\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description, \"div\");\n comp.value = coerceComponent(\n jsx(() => (\n \n {currDisplay.title ? (\n
\n \n </div>\n ) : null}\n <Description />\n </span>\n ))\n );\n });\n\n const { start, stop } = setupHoldToClick(onClick, onHold);\n\n return {\n start,\n stop,\n comp,\n Visibility,\n unref\n };\n }\n});\n","import { render } from \"./Clickable.vue?vue&type=template&id=e4e6b79a&scoped=true&ts=true\"\nimport script from \"./Clickable.vue?vue&type=script&lang=tsx\"\nexport * from \"./Clickable.vue?vue&type=script&lang=tsx\"\n\nimport \"./Clickable.vue?vue&type=style&index=0&id=e4e6b79a&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e4e6b79a\"]])\n\nexport default __exports__","import ClickableComponent from \"features/clickables/Clickable.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { GenericLayer } from \"game/layers\";\nimport { Unsubscribe } from \"nanoevents\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, unref } from \"vue\";\n\nexport const ClickableType = Symbol(\"Clickable\");\n\nexport interface ClickableOptions {\n visibility?: Computable<Visibility>;\n canClick?: Computable<boolean>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n mark?: Computable<boolean | string>;\n display?: Computable<\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n }\n >;\n small?: boolean;\n onClick?: (e?: MouseEvent | TouchEvent) => void;\n onHold?: VoidFunction;\n}\n\nexport interface BaseClickable {\n id: string;\n type: typeof ClickableType;\n [Component]: typeof ClickableComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Clickable<T extends ClickableOptions> = Replace<\n T & BaseClickable,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n canClick: GetComputableTypeWithDefault<T[\"canClick\"], true>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericClickable = Replace<\n Clickable<ClickableOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canClick: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createClickable<T extends ClickableOptions>(\n optionsFunc?: OptionsFunc<T, Clickable<T>, BaseClickable>\n): Clickable<T> {\n return createLazyProxy(() => {\n const clickable = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n clickable.id = getUniqueID(\"clickable-\");\n clickable.type = ClickableType;\n clickable[Component] = ClickableComponent;\n\n processComputable(clickable as T, \"visibility\");\n setDefault(clickable, \"visibility\", Visibility.Visible);\n processComputable(clickable as T, \"canClick\");\n setDefault(clickable, \"canClick\", true);\n processComputable(clickable as T, \"classes\");\n processComputable(clickable as T, \"style\");\n processComputable(clickable as T, \"mark\");\n processComputable(clickable as T, \"display\");\n\n if (clickable.onClick) {\n const onClick = clickable.onClick.bind(clickable);\n clickable.onClick = function (e) {\n if (unref(clickable.canClick)) {\n onClick(e);\n }\n };\n }\n if (clickable.onHold) {\n const onHold = clickable.onHold.bind(clickable);\n clickable.onHold = function () {\n if (unref(clickable.canClick)) {\n onHold();\n }\n };\n }\n\n clickable[GatherProps] = function (this: GenericClickable) {\n const {\n display,\n visibility,\n style,\n classes,\n onClick,\n onHold,\n canClick,\n small,\n mark,\n id\n } = this;\n return {\n display,\n visibility,\n style: unref(style),\n classes,\n onClick,\n onHold,\n canClick,\n small,\n mark,\n id\n };\n };\n\n return clickable as unknown as Clickable<T>;\n });\n}\n\nexport function setupAutoClick(\n layer: GenericLayer,\n clickable: GenericClickable,\n autoActive: Computable<boolean> = true\n): Unsubscribe {\n const isActive = typeof autoActive === \"function\" ? computed(autoActive) : autoActive;\n return layer.on(\"update\", () => {\n if (unref(isActive) && unref(clickable.canClick)) {\n clickable.onClick?.();\n }\n });\n}\n","import {\n Clickable,\n ClickableOptions,\n createClickable,\n GenericClickable\n} from \"features/clickables/clickable\";\nimport { GenericConversion } from \"features/conversion\";\nimport {\n CoercableComponent,\n jsx,\n JSXFunction,\n OptionsFunc,\n Replace,\n setDefault\n} from \"features/feature\";\nimport { displayResource } from \"features/resources/resource\";\nimport {\n createTreeNode,\n GenericTree,\n GenericTreeNode,\n TreeNode,\n TreeNodeOptions\n} from \"features/trees/tree\";\nimport { Modifier } from \"game/modifiers\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport player from \"game/player\";\nimport Decimal, { DecimalSource, format } from \"util/bignum\";\nimport { WithRequired } from \"util/common\";\nimport {\n Computable,\n convertComputable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { renderJSX } from \"util/vue\";\nimport { computed, Ref, unref } from \"vue\";\nimport \"./common.css\";\n\nexport interface ResetButtonOptions extends ClickableOptions {\n conversion: GenericConversion;\n tree: GenericTree;\n treeNode: GenericTreeNode;\n resetDescription?: Computable<string>;\n showNextAt?: Computable<boolean>;\n display?: Computable<CoercableComponent>;\n canClick?: Computable<boolean>;\n minimumGain?: Computable<DecimalSource>;\n}\n\nexport type ResetButton<T extends ResetButtonOptions> = Replace<\n Clickable<T>,\n {\n resetDescription: GetComputableTypeWithDefault<T[\"resetDescription\"], Ref<string>>;\n showNextAt: GetComputableTypeWithDefault<T[\"showNextAt\"], true>;\n display: GetComputableTypeWithDefault<T[\"display\"], Ref<JSX.Element>>;\n canClick: GetComputableTypeWithDefault<T[\"canClick\"], Ref<boolean>>;\n minimumGain: GetComputableTypeWithDefault<T[\"minimumGain\"], 1>;\n onClick: VoidFunction;\n }\n>;\n\nexport type GenericResetButton = Replace<\n GenericClickable & ResetButton<ResetButtonOptions>,\n {\n resetDescription: ProcessedComputable<string>;\n showNextAt: ProcessedComputable<boolean>;\n display: ProcessedComputable<CoercableComponent>;\n canClick: ProcessedComputable<boolean>;\n minimumGain: ProcessedComputable<DecimalSource>;\n }\n>;\n\nexport function createResetButton<T extends ClickableOptions & ResetButtonOptions>(\n optionsFunc: OptionsFunc<T>\n): ResetButton<T> {\n return createClickable(() => {\n const resetButton = optionsFunc();\n\n processComputable(resetButton as T, \"showNextAt\");\n setDefault(resetButton, \"showNextAt\", true);\n setDefault(resetButton, \"minimumGain\", 1);\n\n if (resetButton.resetDescription == null) {\n resetButton.resetDescription = computed(() =>\n Decimal.lt(resetButton.conversion.gainResource.value, 1e3) ? \"Reset for \" : \"\"\n );\n } else {\n processComputable(resetButton as T, \"resetDescription\");\n }\n\n if (resetButton.display == null) {\n resetButton.display = jsx(() => (\n <span>\n {unref(resetButton.resetDescription as ProcessedComputable<string>)}\n <b>\n {displayResource(\n resetButton.conversion.gainResource,\n Decimal.max(\n unref(resetButton.conversion.actualGain),\n unref(resetButton.minimumGain as ProcessedComputable<DecimalSource>)\n )\n )}\n </b>{\" \"}\n {resetButton.conversion.gainResource.displayName}\n <div v-show={unref(resetButton.showNextAt)}>\n <br />\n {unref(resetButton.conversion.buyMax) ? \"Next:\" : \"Req:\"}{\" \"}\n {displayResource(\n resetButton.conversion.baseResource,\n unref(resetButton.conversion.buyMax) ||\n Decimal.floor(unref(resetButton.conversion.actualGain)).neq(1)\n ? unref(resetButton.conversion.nextAt)\n : unref(resetButton.conversion.currentAt)\n )}{\" \"}\n {resetButton.conversion.baseResource.displayName}\n </div>\n </span>\n ));\n }\n\n if (resetButton.canClick == null) {\n resetButton.canClick = computed(() =>\n Decimal.gte(\n unref(resetButton.conversion.actualGain),\n unref(resetButton.minimumGain as ProcessedComputable<DecimalSource>)\n )\n );\n }\n\n const onClick = resetButton.onClick;\n resetButton.onClick = function () {\n if (!unref(resetButton.canClick)) {\n return;\n }\n resetButton.conversion.convert();\n resetButton.tree.reset(resetButton.treeNode);\n onClick?.();\n };\n\n return resetButton;\n }) as unknown as ResetButton<T>;\n}\n\nexport interface LayerTreeNodeOptions extends TreeNodeOptions {\n layerID: string;\n color: Computable<string>; // marking as required\n display?: Computable<CoercableComponent>;\n append?: Computable<boolean>;\n}\nexport type LayerTreeNode<T extends LayerTreeNodeOptions> = Replace<\n TreeNode<T>,\n {\n display: GetComputableTypeWithDefault<T[\"display\"], T[\"layerID\"]>;\n append: GetComputableType<T[\"append\"]>;\n }\n>;\nexport type GenericLayerTreeNode = Replace<\n LayerTreeNode<LayerTreeNodeOptions>,\n {\n display: ProcessedComputable<CoercableComponent>;\n append?: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createLayerTreeNode<T extends LayerTreeNodeOptions>(\n optionsFunc: OptionsFunc<T>\n): LayerTreeNode<T> {\n return createTreeNode(() => {\n const options = optionsFunc();\n processComputable(options as T, \"display\");\n setDefault(options, \"display\", options.layerID);\n processComputable(options as T, \"append\");\n return {\n ...options,\n display: options.display,\n onClick: unref((options as unknown as GenericLayerTreeNode).append)\n ? function () {\n if (player.tabs.includes(options.layerID)) {\n const index = player.tabs.lastIndexOf(options.layerID);\n player.tabs.splice(index, 1);\n } else {\n player.tabs.push(options.layerID);\n }\n }\n : function () {\n player.tabs.splice(1, 1, options.layerID);\n }\n };\n }) as unknown as LayerTreeNode<T>;\n}\n\nexport function createCollapsibleModifierSections(\n sections: {\n title: string;\n subtitle?: string;\n modifier: WithRequired<Modifier, \"description\">;\n base?: Computable<DecimalSource>;\n unit?: string;\n baseText?: Computable<CoercableComponent>;\n visible?: Computable<boolean>;\n }[]\n): [JSXFunction, Persistent<boolean>[]] {\n const processedBase = sections.map(s => convertComputable(s.base));\n const processedBaseText = sections.map(s => convertComputable(s.baseText));\n const processedVisible = sections.map(s => convertComputable(s.visible));\n const collapsed = sections.map(() => persistent<boolean>(false));\n const jsxFunc = jsx(() => {\n const sectionJSX = sections.map((s, i) => {\n if (unref(processedVisible[i]) === false) return null;\n const header = (\n <h3\n onClick={() => (collapsed[i].value = !collapsed[i].value)}\n style=\"cursor: pointer\"\n >\n <span class={\"modifier-toggle\" + (unref(collapsed[i]) ? \" collapsed\" : \"\")}>\n ▼\n </span>\n {s.title}\n {s.subtitle ? <span class=\"subtitle\"> ({s.subtitle})</span> : null}\n </h3>\n );\n\n const modifiers = unref(collapsed[i]) ? null : (\n <>\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">\n {format(unref(processedBase[i]) ?? 1)}\n {s.unit}\n </span>\n <span class=\"modifier-description\">\n {renderJSX(unref(processedBaseText[i]) ?? \"Base\")}\n </span>\n </div>\n {renderJSX(unref(s.modifier.description))}\n </>\n );\n\n return (\n <>\n {i === 0 ? null : <br />}\n <div>\n {header}\n <br />\n {modifiers}\n <hr />\n Total: {format(s.modifier.apply(unref(processedBase[i]) ?? 1))}\n {s.unit}\n </div>\n </>\n );\n });\n return <>{sectionJSX}</>;\n });\n return [jsxFunc, collapsed];\n}\n","import { GenericLayer } from \"game/layers\";\nimport { Modifier } from \"game/modifiers\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { WithRequired } from \"util/common\";\nimport {\n Computable,\n convertComputable,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { OptionsFunc, Replace, setDefault } from \"./feature\";\nimport { Resource } from \"./resources/resource\";\n\n/**\n * An object that configures a {@link conversion}.\n */\nexport interface ConversionOptions {\n /**\n * The scaling function that is used to determine the rate of conversion from one {@link resource} to the other.\n */\n scaling: ScalingFunction;\n /**\n * How much of the output resource the conversion can currently convert for.\n * Typically this will be set for you in a conversion constructor.\n */\n currentGain?: Computable<DecimalSource>;\n /**\n * The absolute amount the output resource will be changed by.\n * Typically this will be set for you in a conversion constructor.\n * This will differ from {@link currentGain} in the cases where the conversion isn't just adding the converted amount to the output resource.\n */\n actualGain?: Computable<DecimalSource>;\n /**\n * The amount of the input resource currently being required in order to produce the {@link currentGain}.\n * That is, if it went below this value then {@link currentGain} would decrease.\n * Typically this will be set for you in a conversion constructor.\n */\n currentAt?: Computable<DecimalSource>;\n /**\n * The amount of the input resource required to make {@link currentGain} increase.\n * Typically this will be set for you in a conversion constructor.\n */\n nextAt?: Computable<DecimalSource>;\n /**\n * The input {@link resource} for this conversion.\n */\n baseResource: Resource;\n /**\n * The output {@link resource} for this conversion. i.e. the resource being generated.\n */\n gainResource: Resource;\n /**\n * Whether or not to cap the amount of the output resource gained by converting at 1.\n */\n buyMax?: Computable<boolean>;\n /**\n * Whether or not to round up the cost to generate a given amount of the output resource.\n */\n roundUpCost?: Computable<boolean>;\n /**\n * The function that performs the actual conversion from {@link baseResource} to {@link gainResource}.\n * Typically this will be set for you in a conversion constructor.\n */\n convert?: VoidFunction;\n /**\n * An addition modifier that will be applied to the gain amounts.\n * Must be reversible in order to correctly calculate {@link nextAt}.\n * @see {@link createSequentialModifier} if you want to apply multiple modifiers.\n */\n gainModifier?: WithRequired<Modifier, \"revert\">;\n}\n\n/**\n * The properties that are added onto a processed {@link ConversionOptions} to create a {@link Conversion}.\n */\nexport interface BaseConversion {\n /**\n * The function that performs the actual conversion.\n */\n convert: VoidFunction;\n}\n\n/**\n * An object that converts one {@link resource} into another at a given rate.\n */\nexport type Conversion<T extends ConversionOptions> = Replace<\n T & BaseConversion,\n {\n currentGain: GetComputableTypeWithDefault<T[\"currentGain\"], Ref<DecimalSource>>;\n actualGain: GetComputableTypeWithDefault<T[\"actualGain\"], Ref<DecimalSource>>;\n currentAt: GetComputableTypeWithDefault<T[\"currentAt\"], Ref<DecimalSource>>;\n nextAt: GetComputableTypeWithDefault<T[\"nextAt\"], Ref<DecimalSource>>;\n buyMax: GetComputableTypeWithDefault<T[\"buyMax\"], true>;\n roundUpCost: GetComputableTypeWithDefault<T[\"roundUpCost\"], true>;\n }\n>;\n\n/**\n * A type that matches any {@link conversion} object.\n */\nexport type GenericConversion = Replace<\n Conversion<ConversionOptions>,\n {\n currentGain: ProcessedComputable<DecimalSource>;\n actualGain: ProcessedComputable<DecimalSource>;\n currentAt: ProcessedComputable<DecimalSource>;\n nextAt: ProcessedComputable<DecimalSource>;\n buyMax: ProcessedComputable<boolean>;\n roundUpCost: ProcessedComputable<boolean>;\n }\n>;\n\n/**\n * Lazily creates a conversion with the given options.\n * You typically shouldn't use this function directly. Instead use one of the other conversion constructors, which will then call this.\n * @param optionsFunc Conversion options.\n * @see {@link createCumulativeConversion}.\n * @see {@link createIndependentConversion}.\n */\nexport function createConversion<T extends ConversionOptions>(\n optionsFunc: OptionsFunc<T, Conversion<T>, BaseConversion>\n): Conversion<T> {\n return createLazyProxy(() => {\n const conversion = optionsFunc();\n\n if (conversion.currentGain == null) {\n conversion.currentGain = computed(() => {\n let gain = conversion.gainModifier\n ? conversion.gainModifier.apply(\n conversion.scaling.currentGain(conversion as GenericConversion)\n )\n : conversion.scaling.currentGain(conversion as GenericConversion);\n gain = Decimal.floor(gain).max(0);\n\n if (!unref(conversion.buyMax)) {\n gain = gain.min(1);\n }\n return gain;\n });\n }\n if (conversion.actualGain == null) {\n conversion.actualGain = conversion.currentGain;\n }\n if (conversion.currentAt == null) {\n conversion.currentAt = computed(() => {\n let current = conversion.scaling.currentAt(conversion as GenericConversion);\n if (conversion.roundUpCost) current = Decimal.ceil(current);\n return current;\n });\n }\n if (conversion.nextAt == null) {\n conversion.nextAt = computed(() => {\n let next = conversion.scaling.nextAt(conversion as GenericConversion);\n if (conversion.roundUpCost) next = Decimal.ceil(next);\n return next;\n });\n }\n\n if (conversion.convert == null) {\n conversion.convert = function () {\n conversion.gainResource.value = Decimal.add(\n conversion.gainResource.value,\n unref((conversion as GenericConversion).currentGain)\n );\n // TODO just subtract cost?\n conversion.baseResource.value = 0;\n };\n }\n\n processComputable(conversion as T, \"currentGain\");\n processComputable(conversion as T, \"actualGain\");\n processComputable(conversion as T, \"currentAt\");\n processComputable(conversion as T, \"nextAt\");\n processComputable(conversion as T, \"buyMax\");\n setDefault(conversion, \"buyMax\", true);\n processComputable(conversion as T, \"roundUpCost\");\n setDefault(conversion, \"roundUpCost\", true);\n\n return conversion as unknown as Conversion<T>;\n });\n}\n\n/**\n * A collection of functions that allow a conversion to scale the amount of resources gained based on the input resource.\n * This typically shouldn't be created directly. Instead use one of the scaling function constructors.\n * @see {@link createLinearScaling}.\n * @see {@link createPolynomialScaling}.\n */\nexport interface ScalingFunction {\n /**\n * Calculates the amount of the output resource a conversion should be able to currently produce.\n * This should be based off of `conversion.baseResource.value`.\n * The conversion is responsible for applying the gainModifier, so this function should be un-modified.\n * It does not need to be clamped or rounded.\n */\n currentGain: (conversion: GenericConversion) => DecimalSource;\n /**\n * Calculates the amount of the input resource that is required for the current value of `conversion.currentGain`.\n * Note that `conversion.currentGain` has been modified by `conversion.gainModifier`, so you will need to revert that as appropriate.\n * The conversion is responsible for rounding up the amount as appropriate.\n * The returned value should not be below 0.\n */\n currentAt: (conversion: GenericConversion) => DecimalSource;\n /**\n * Calculates the amount of the input resource that would be required for the current value of `conversion.currentGain` to increase.\n * Note that `conversion.currentGain` has been modified by `conversion.gainModifier`, so you will need to revert that as appropriate.\n * The conversion is responsible for rounding up the amount as appropriate.\n * The returned value should not be below 0.\n */\n nextAt: (conversion: GenericConversion) => DecimalSource;\n}\n\n/**\n * Creates a scaling function based off the formula `(baseResource - base) * coefficient`.\n * If the baseResource value is less than base then the currentGain will be 0.\n * @param base The base variable in the scaling formula.\n * @param coefficient The coefficient variable in the scaling formula.\n * @example\n * A scaling function created via `createLinearScaling(10, 0.5)` would produce the following values:\n * | Base Resource | Current Gain |\n * | ------------- | ------------ |\n * | 10 | 1 |\n * | 12 | 2 |\n * | 20 | 6 |\n */\nexport function createLinearScaling(\n base: Computable<DecimalSource>,\n coefficient: Computable<DecimalSource>\n): ScalingFunction {\n const processedBase = convertComputable(base);\n const processedCoefficient = convertComputable(coefficient);\n return {\n currentGain(conversion) {\n if (Decimal.lt(conversion.baseResource.value, unref(processedBase))) {\n return 0;\n }\n\n return Decimal.sub(conversion.baseResource.value, unref(processedBase))\n .sub(1)\n .times(unref(processedCoefficient))\n .add(1);\n },\n currentAt(conversion) {\n let current: DecimalSource = unref(conversion.currentGain);\n if (conversion.gainModifier) {\n current = conversion.gainModifier.revert(current);\n }\n current = Decimal.max(0, current);\n return Decimal.sub(current, 1)\n .div(unref(processedCoefficient))\n .add(unref(processedBase));\n },\n nextAt(conversion) {\n let next: DecimalSource = Decimal.add(unref(conversion.currentGain), 1);\n if (conversion.gainModifier) {\n next = conversion.gainModifier.revert(next);\n }\n next = Decimal.max(0, next);\n return Decimal.sub(next, 1)\n .div(unref(processedCoefficient))\n .add(unref(processedBase))\n .max(unref(processedBase));\n }\n };\n}\n\n/**\n * Creates a scaling function based off the formula `(baseResource / base) ^ exponent`.\n * If the baseResource value is less than base then the currentGain will be 0.\n * @param base The base variable in the scaling formula.\n * @param exponent The exponent variable in the scaling formula.\n * @example\n * A scaling function created via `createLinearScaling(10, 0.5)` would produce the following values:\n * | Base Resource | Current Gain |\n * | ------------- | ------------ |\n * | 10 | 1 |\n * | 40 | 2 |\n * | 250 | 5 |\n */\nexport function createPolynomialScaling(\n base: Computable<DecimalSource>,\n exponent: Computable<DecimalSource>\n): ScalingFunction {\n const processedBase = convertComputable(base);\n const processedExponent = convertComputable(exponent);\n return {\n currentGain(conversion) {\n if (Decimal.lt(conversion.baseResource.value, unref(processedBase))) {\n return 0;\n }\n\n const gain = Decimal.div(conversion.baseResource.value, unref(processedBase)).pow(\n unref(processedExponent)\n );\n\n if (gain.isNan()) {\n return new Decimal(0);\n }\n return gain;\n },\n currentAt(conversion) {\n let current: DecimalSource = unref(conversion.currentGain);\n if (conversion.gainModifier) {\n current = conversion.gainModifier.revert(current);\n }\n current = Decimal.max(0, current);\n return Decimal.root(current, unref(processedExponent)).times(unref(processedBase));\n },\n nextAt(conversion) {\n let next: DecimalSource = Decimal.add(unref(conversion.currentGain), 1);\n if (conversion.gainModifier) {\n next = conversion.gainModifier.revert(next);\n }\n next = Decimal.max(0, next);\n return Decimal.root(next, unref(processedExponent))\n .times(unref(processedBase))\n .max(unref(processedBase));\n }\n };\n}\n\n/**\n * Creates a conversion that simply adds to the gainResource amount upon converting.\n * This is similar to the behavior of \"normal\" layers in The Modding Tree.\n * This is equivalent to just calling createConversion directly.\n * @param optionsFunc Conversion options.\n */\nexport function createCumulativeConversion<S extends ConversionOptions>(\n optionsFunc: OptionsFunc<S, Conversion<S>>\n): Conversion<S> {\n return createConversion(optionsFunc);\n}\n\n/**\n * Creates a conversion that will replace the gainResource amount with the new amount upon converting.\n * This is similar to the behavior of \"static\" layers in The Modding Tree.\n * @param optionsFunc Converison options.\n */\nexport function createIndependentConversion<S extends ConversionOptions>(\n optionsFunc: OptionsFunc<S, Conversion<S>>\n): Conversion<S> {\n return createConversion(() => {\n const conversion: S = optionsFunc();\n\n setDefault(conversion, \"buyMax\", false);\n\n if (conversion.currentGain == null) {\n conversion.currentGain = computed(() => {\n let gain = conversion.gainModifier\n ? conversion.gainModifier.apply(\n conversion.scaling.currentGain(conversion as GenericConversion)\n )\n : conversion.scaling.currentGain(conversion as GenericConversion);\n gain = Decimal.floor(gain).max(conversion.gainResource.value);\n\n if (!unref(conversion.buyMax)) {\n gain = gain.min(Decimal.add(conversion.gainResource.value, 1));\n }\n return gain;\n });\n }\n if (conversion.actualGain == null) {\n conversion.actualGain = computed(() => {\n let gain = Decimal.sub(\n conversion.scaling.currentGain(conversion as GenericConversion),\n conversion.gainResource.value\n ).max(0);\n\n if (!unref(conversion.buyMax)) {\n gain = gain.min(1);\n }\n return gain;\n });\n }\n setDefault(conversion, \"convert\", function () {\n conversion.gainResource.value = conversion.gainModifier\n ? conversion.gainModifier.apply(\n unref((conversion as GenericConversion).currentGain)\n )\n : unref((conversion as GenericConversion).currentGain);\n // TODO just subtract cost?\n // Maybe by adding a cost function to scaling and nextAt just calls the cost function\n // with 1 + currentGain\n conversion.baseResource.value = 0;\n });\n\n return conversion;\n });\n}\n\n/**\n * This will automatically increase the value of conversion.gainResource without lowering the value of the input resource.\n * It will by default perform 100% of a conversion's currentGain per second.\n * If you use a ref for the rate you can set it's value to 0 when passive generation should be disabled.\n * @param layer The layer this passive generation will be associated with.\n * @param conversion The conversion that will determine how much generation there is.\n * @param rate A multiplier to multiply against the conversion's currentGain.\n */\nexport function setupPassiveGeneration(\n layer: GenericLayer,\n conversion: GenericConversion,\n rate: Computable<DecimalSource> = 1\n): void {\n const processedRate = convertComputable(rate);\n layer.on(\"preUpdate\", diff => {\n const currRate = unref(processedRate);\n if (Decimal.neq(currRate, 0)) {\n conversion.gainResource.value = Decimal.add(\n conversion.gainResource.value,\n Decimal.times(currRate, diff).times(unref(conversion.currentGain))\n );\n }\n });\n}\n\n/**\n * Given a value, this function finds the amount above a certain value and raises it to a power.\n * If the power is <1, this will effectively make the value scale slower after the cap.\n * @param value The raw value.\n * @param cap The value after which the softcap should be applied.\n * @param power The power to raise value above the cap to.\n * @example\n * A softcap added via `addSoftcap(scaling, 100, 0.5)` would produce the following values:\n * | Raw Value | Softcapped Value |\n * | --------- | ---------------- |\n * | 1 | 1 |\n * | 100 | 100 |\n * | 125 | 105 |\n * | 200 | 110 |\n */\nexport function softcap(\n value: DecimalSource,\n cap: DecimalSource,\n power: DecimalSource = 0.5\n): DecimalSource {\n if (Decimal.lte(value, cap)) {\n return value;\n } else {\n return Decimal.pow(value, power).times(Decimal.pow(cap, Decimal.sub(1, power)));\n }\n}\n\n/**\n * Creates a scaling function based off an existing scaling function, with a softcap applied to it.\n * The softcap will take any value above a certain value and raise it to a power.\n * If the power is <1, this will effectively make the value scale slower after the cap.\n * @param scaling The raw scaling function.\n * @param cap The value after which the softcap should be applied.\n * @param power The power to raise value about the cap to.\n * @see {@link softcap}.\n */\nexport function addSoftcap(\n scaling: ScalingFunction,\n cap: ProcessedComputable<DecimalSource>,\n power: ProcessedComputable<DecimalSource> = 0.5\n): ScalingFunction {\n return {\n ...scaling,\n currentGain: conversion =>\n softcap(scaling.currentGain(conversion), unref(cap), unref(power))\n };\n}\n\n/**\n * Creates a scaling function off an existing function, with a hardcap applied to it.\n * The harcap will ensure that the currentGain will stop at a given cap.\n * @param scaling The raw scaling function.\n * @param cap The maximum value the scaling function can output.\n */\nexport function addHardcap(\n scaling: ScalingFunction,\n cap: ProcessedComputable<DecimalSource>\n): ScalingFunction {\n return {\n ...scaling,\n currentGain: conversion => Decimal.min(scaling.currentGain(conversion), unref(cap))\n };\n}\n","import { createElementVNode as _createElementVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, createVNode as _createVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-6447a93e\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"toggle\" }, \"▼\", -1))\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_CollapseTransition = _resolveComponent(\"CollapseTransition\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: _normalizeClass([\"infobox\", { collapsed: _ctx.unref(_ctx.collapsed), stacked: _ctx.stacked, ..._ctx.unref(_ctx.classes) }]),\n style: _normalizeStyle([\n {\n borderColor: _ctx.unref(_ctx.color),\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ])\n }, [\n _createElementVNode(\"button\", {\n class: \"title\",\n style: _normalizeStyle([{ backgroundColor: _ctx.unref(_ctx.color) }, _ctx.unref(_ctx.titleStyle) || []]),\n onClick: _cache[0] || (_cache[0] = ($event: any) => (_ctx.collapsed.value = !_ctx.unref(_ctx.collapsed)))\n }, [\n _hoisted_1,\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.titleComponent)))\n ], 4),\n _createVNode(_component_CollapseTransition, null, {\n default: _withCtx(() => [\n (!_ctx.unref(_ctx.collapsed))\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: \"body\",\n style: _normalizeStyle({ backgroundColor: _ctx.unref(_ctx.color) })\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.bodyComponent), {\n style: _normalizeStyle(_ctx.unref(_ctx.bodyStyle))\n }, null, 8, [\"style\"]))\n ], 4))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n }),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport Node from \"components/Node.vue\";\nimport themes from \"data/themes\";\nimport { CoercableComponent, Visibility } from \"features/feature\";\nimport settings from \"game/settings\";\nimport { computeComponent, processedPropType } from \"util/vue\";\nimport CollapseTransition from \"@ivanv/vue-collapse-transition/src/CollapseTransition.vue\";\nimport { computed, defineComponent, PropType, Ref, StyleValue, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n title: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n color: processedPropType<string>(String),\n collapsed: {\n type: Object as PropType<Ref<boolean>>,\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n titleStyle: processedPropType<StyleValue>(Object, String, Array),\n bodyStyle: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node,\n CollapseTransition\n },\n setup(props) {\n const { title, display } = toRefs(props);\n\n const titleComponent = computeComponent(title);\n const bodyComponent = computeComponent(display);\n const stacked = computed(() => themes[settings.theme].mergeAdjacent);\n\n return {\n titleComponent,\n bodyComponent,\n stacked,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Infobox.vue?vue&type=template&id=6447a93e&scoped=true&ts=true\"\nimport script from \"./Infobox.vue?vue&type=script&lang=ts\"\nexport * from \"./Infobox.vue?vue&type=script&lang=ts\"\n\nimport \"./Infobox.vue?vue&type=style&index=0&id=6447a93e&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-6447a93e\"]])\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n GatherProps,\n getUniqueID,\n OptionsFunc,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport InfoboxComponent from \"features/infoboxes/Infobox.vue\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { unref } from \"vue\";\n\nexport const InfoboxType = Symbol(\"Infobox\");\n\nexport interface InfoboxOptions {\n visibility?: Computable<Visibility>;\n color?: Computable<string>;\n style?: Computable<StyleValue>;\n titleStyle?: Computable<StyleValue>;\n bodyStyle?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n title: Computable<CoercableComponent>;\n display: Computable<CoercableComponent>;\n}\n\nexport interface BaseInfobox {\n id: string;\n collapsed: Persistent<boolean>;\n type: typeof InfoboxType;\n [Component]: typeof InfoboxComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Infobox<T extends InfoboxOptions> = Replace<\n T & BaseInfobox,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n color: GetComputableType<T[\"color\"]>;\n style: GetComputableType<T[\"style\"]>;\n titleStyle: GetComputableType<T[\"titleStyle\"]>;\n bodyStyle: GetComputableType<T[\"bodyStyle\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n title: GetComputableType<T[\"title\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericInfobox = Replace<\n Infobox<InfoboxOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createInfobox<T extends InfoboxOptions>(\n optionsFunc: OptionsFunc<T, Infobox<T>, BaseInfobox>\n): Infobox<T> {\n const collapsed = persistent<boolean>(false);\n return createLazyProxy(() => {\n const infobox = optionsFunc();\n infobox.id = getUniqueID(\"infobox-\");\n infobox.type = InfoboxType;\n infobox[Component] = InfoboxComponent;\n\n infobox.collapsed = collapsed;\n\n processComputable(infobox as T, \"visibility\");\n setDefault(infobox, \"visibility\", Visibility.Visible);\n processComputable(infobox as T, \"color\");\n processComputable(infobox as T, \"style\");\n processComputable(infobox as T, \"titleStyle\");\n processComputable(infobox as T, \"bodyStyle\");\n processComputable(infobox as T, \"classes\");\n processComputable(infobox as T, \"title\");\n processComputable(infobox as T, \"display\");\n\n infobox[GatherProps] = function (this: GenericInfobox) {\n const {\n visibility,\n display,\n title,\n color,\n collapsed,\n style,\n titleStyle,\n bodyStyle,\n classes,\n id\n } = this;\n return {\n visibility,\n display,\n title,\n color,\n collapsed,\n style: unref(style),\n titleStyle,\n bodyStyle,\n classes,\n id\n };\n };\n\n return infobox as unknown as Infobox<T>;\n });\n}\n","import { normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n return (_openBlock(), _createElementBlock(\"div\", {\n ref: \"resizeListener\",\n class: _normalizeClass([\"resize-listener\", _ctx.unref(_ctx.classes)]),\n style: _normalizeStyle(_ctx.unref(_ctx.style))\n }, null, 6))\n}","\nimport { StyleValue } from \"features/feature\";\nimport { Application } from \"pixi.js\";\nimport { processedPropType } from \"util/vue\";\nimport { defineComponent, nextTick, onBeforeUnmount, onMounted, PropType, ref, unref } from \"vue\";\n\n// TODO get typing support on the Particles component\nexport default defineComponent({\n props: {\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n onInit: {\n type: Function as PropType<(app: Application) => void>,\n required: true\n },\n id: {\n type: String,\n required: true\n },\n onContainerResized: Function as PropType<(rect: DOMRect) => void>,\n onHotReload: Function as PropType<VoidFunction>\n },\n setup(props) {\n const app = ref<null | Application>(null);\n\n const resizeObserver = new ResizeObserver(updateBounds);\n const resizeListener = ref<HTMLElement | null>(null);\n\n onMounted(() => {\n // ResizeListener exists because ResizeObserver's don't work when told to observe an SVG element\n const resListener = resizeListener.value;\n if (resListener != null) {\n resizeObserver.observe(resListener);\n app.value = new Application({\n resizeTo: resListener,\n backgroundAlpha: 0\n });\n resizeListener.value?.appendChild(app.value.view);\n props.onInit(app.value as Application);\n }\n updateBounds();\n if (props.onHotReload) {\n nextTick(props.onHotReload);\n }\n });\n onBeforeUnmount(() => {\n app.value?.destroy();\n });\n\n let isDirty = true;\n function updateBounds() {\n if (isDirty) {\n isDirty = false;\n nextTick(() => {\n if (resizeListener.value != null && props.onContainerResized) {\n props.onContainerResized(resizeListener.value.getBoundingClientRect());\n app.value?.resize();\n }\n isDirty = true;\n });\n }\n }\n document.fonts.ready.then(updateBounds);\n\n return {\n unref,\n resizeListener\n };\n }\n});\n","import { render } from \"./Particles.vue?vue&type=template&id=08c4e343&scoped=true&ts=true\"\nimport script from \"./Particles.vue?vue&type=script&lang=tsx\"\nexport * from \"./Particles.vue?vue&type=script&lang=tsx\"\n\nimport \"./Particles.vue?vue&type=style&index=0&id=08c4e343&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-08c4e343\"]])\n\nexport default __exports__","import ParticlesComponent from \"features/particles/Particles.vue\";\nimport { Ref, shallowRef, unref } from \"vue\";\nimport {\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n StyleValue\n} from \"features/feature\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { Application } from \"pixi.js\";\nimport { Emitter, EmitterConfigV3, upgradeConfig } from \"@pixi/particle-emitter\";\nimport { Computable, GetComputableType } from \"util/computed\";\n\nexport const ParticlesType = Symbol(\"Particles\");\n\nexport interface ParticlesOptions {\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n onContainerResized?: (boundingRect: DOMRect) => void;\n onHotReload?: VoidFunction;\n}\n\nexport interface BaseParticles {\n id: string;\n app: Ref<null | Application>;\n addEmitter: (config: EmitterConfigV3) => Promise<Emitter>;\n type: typeof ParticlesType;\n [Component]: typeof ParticlesComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Particles<T extends ParticlesOptions> = Replace<\n T & BaseParticles,\n {\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n }\n>;\n\nexport type GenericParticles = Particles<ParticlesOptions>;\n\nexport function createParticles<T extends ParticlesOptions>(\n optionsFunc?: OptionsFunc<T, Particles<T>, BaseParticles>\n): Particles<T> {\n return createLazyProxy(() => {\n const particles = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n particles.id = getUniqueID(\"particles-\");\n particles.type = ParticlesType;\n particles[Component] = ParticlesComponent;\n\n particles.app = shallowRef(null);\n particles.addEmitter = (config: EmitterConfigV3): Promise<Emitter> => {\n const genericParticles = particles as GenericParticles;\n if (genericParticles.app.value) {\n return Promise.resolve(new Emitter(genericParticles.app.value.stage, config));\n }\n return new Promise<Emitter>(resolve => {\n emittersToAdd.push({ resolve, config });\n });\n };\n\n let emittersToAdd: {\n resolve: (value: Emitter | PromiseLike<Emitter>) => void;\n config: EmitterConfigV3;\n }[] = [];\n\n function onInit(app: Application) {\n (particles as GenericParticles).app.value = app;\n emittersToAdd.forEach(({ resolve, config }) => resolve(new Emitter(app.stage, config)));\n emittersToAdd = [];\n }\n\n particles.onContainerResized = particles.onContainerResized?.bind(particles);\n\n particles[GatherProps] = function (this: GenericParticles) {\n const { id, style, classes, onContainerResized, onHotReload } = this;\n return {\n id,\n style: unref(style),\n classes,\n onContainerResized,\n onHotReload,\n onInit\n };\n };\n\n return particles as unknown as Particles<T>;\n });\n}\n\ndeclare global {\n interface Window {\n upgradeConfig: typeof upgradeConfig;\n }\n}\nwindow.upgradeConfig = upgradeConfig;\n","import { OptionsFunc, getUniqueID, Replace } from \"features/feature\";\nimport { globalBus } from \"game/events\";\nimport { GenericLayer } from \"game/layers\";\nimport { DefaultValue, Persistent, persistent, PersistentState } from \"game/persistence\";\nimport Decimal from \"util/bignum\";\nimport { Computable, GetComputableType, processComputable } from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { Unsubscribe } from \"nanoevents\";\nimport { isRef, unref } from \"vue\";\n\nexport const ResetType = Symbol(\"Reset\");\n\nexport interface ResetOptions {\n thingsToReset: Computable<Record<string, unknown>[]>;\n onReset?: VoidFunction;\n}\n\nexport interface BaseReset {\n id: string;\n reset: VoidFunction;\n type: typeof ResetType;\n}\n\nexport type Reset<T extends ResetOptions> = Replace<\n T & BaseReset,\n {\n thingsToReset: GetComputableType<T[\"thingsToReset\"]>;\n }\n>;\n\nexport type GenericReset = Reset<ResetOptions>;\n\nexport function createReset<T extends ResetOptions>(\n optionsFunc: OptionsFunc<T, Reset<T>, BaseReset>\n): Reset<T> {\n return createLazyProxy(() => {\n const reset = optionsFunc();\n reset.id = getUniqueID(\"reset-\");\n reset.type = ResetType;\n\n reset.reset = function () {\n const handleObject = (obj: unknown) => {\n if (obj && typeof obj === \"object\") {\n if (PersistentState in obj) {\n (obj as Persistent)[PersistentState].value = (obj as Persistent)[\n DefaultValue\n ];\n } else if (!(obj instanceof Decimal) && !isRef(obj)) {\n Object.values(obj).forEach(obj =>\n handleObject(obj as Record<string, unknown>)\n );\n }\n }\n };\n unref((reset as GenericReset).thingsToReset).forEach(handleObject);\n globalBus.emit(\"reset\", reset as GenericReset);\n reset.onReset?.();\n };\n\n processComputable(reset as T, \"thingsToReset\");\n\n return reset as unknown as Reset<T>;\n });\n}\n\nconst listeners: Record<string, Unsubscribe | undefined> = {};\nexport function trackResetTime(layer: GenericLayer, reset: GenericReset): Persistent<Decimal> {\n const resetTime = persistent<Decimal>(new Decimal(0));\n listeners[layer.id] = layer.on(\"preUpdate\", diff => {\n resetTime.value = Decimal.add(resetTime.value, diff);\n });\n globalBus.on(\"reset\", currentReset => {\n if (currentReset === reset) {\n resetTime.value = new Decimal(0);\n }\n });\n return resetTime;\n}\nglobalBus.on(\"removeLayer\", layer => {\n // unsubscribe from preUpdate\n listeners[layer.id]?.();\n listeners[layer.id] = undefined;\n});\n\ndeclare module \"game/events\" {\n interface GlobalEvents {\n reset: (reset: GenericReset) => void;\n }\n}\n","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, toDisplayString as _toDisplayString, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { displayResource, Resource } from \"features/resources/resource\";\nimport { computed } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n resource: null,\n color: null\n },\n setup(__props: any) {\n\nconst props = __props as {\n resource: Resource;\n color: string;\n}\n\n\n\nconst amount = computed(() => displayResource(props.resource));\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"h2\", {\n style: _normalizeStyle({ color: __props.color, 'text-shadow': '0px 0px 10px ' + __props.color })\n }, _toDisplayString(_unref(amount)), 5))\n}\n}\n\n})","import script from \"./Resource.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Resource.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createVNode as _createVNode, toDisplayString as _toDisplayString, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode } from \"vue\"\n\nconst _hoisted_1 = { key: 0 }\nconst _hoisted_2 = { key: 1 }\nconst _hoisted_3 = /*#__PURE__*/_createTextVNode(\", \")\nconst _hoisted_4 = /*#__PURE__*/_createElementVNode(\"br\", null, null, -1)\nconst _hoisted_5 = /*#__PURE__*/_createElementVNode(\"br\", null, null, -1)\n\nimport { CoercableComponent } from \"features/feature\";\nimport { Resource } from \"features/resources/resource\";\nimport Decimal from \"util/bignum\";\nimport { computeOptionalComponent } from \"util/vue\";\nimport { computed, Ref, StyleValue, toRefs } from \"vue\";\nimport ResourceVue from \"features/resources/Resource.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n resource: null,\n color: null,\n classes: null,\n style: null,\n effectDisplay: null\n },\n setup(__props: any) {\n\nconst _props = __props as {\n resource: Resource;\n color?: string;\n classes?: Record<string, boolean>;\n style?: StyleValue;\n effectDisplay?: CoercableComponent;\n}\n\n\nconst props = toRefs(_props);\n\nconst effectComponent = computeOptionalComponent(\n props.effectDisplay as Ref<CoercableComponent | undefined>\n);\n\nconst showPrefix = computed(() => {\n return Decimal.lt(props.resource.value, \"1e1000\");\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", null, [\n (_unref(showPrefix))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \"You have \"))\n : _createCommentVNode(\"\", true),\n _createVNode(ResourceVue, {\n resource: __props.resource,\n color: __props.color || 'white'\n }, null, 8, [\"resource\", \"color\"]),\n _createTextVNode(\" \" + _toDisplayString(__props.resource.displayName), 1),\n (_unref(effectComponent))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, [\n _hoisted_3,\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(effectComponent))))\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_4,\n _hoisted_5\n ]))\n}\n}\n\n})","import script from \"./MainDisplay.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./MainDisplay.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import TooltipComponent from \"./Tooltip.vue\";\nimport {\n CoercableComponent,\n Component,\n GatherProps,\n Replace,\n setDefault,\n StyleValue\n} from \"features/feature\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { VueFeature } from \"util/vue\";\nimport { nextTick, Ref, unref } from \"vue\";\nimport { persistent } from \"game/persistence\";\nimport { Direction } from \"util/common\";\n\ndeclare module \"@vue/runtime-dom\" {\n interface CSSProperties {\n \"--xoffset\"?: string;\n \"--yoffset\"?: string;\n }\n}\n\nexport interface TooltipOptions {\n pinnable?: boolean;\n display: Computable<CoercableComponent>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n direction?: Computable<Direction>;\n xoffset?: Computable<string>;\n yoffset?: Computable<string>;\n}\n\nexport interface BaseTooltip {\n pinned?: Ref<boolean>;\n}\n\nexport type Tooltip<T extends TooltipOptions> = Replace<\n T & BaseTooltip,\n {\n pinnable: T[\"pinnable\"] extends undefined ? false : T[\"pinnable\"];\n pinned: T[\"pinnable\"] extends true ? Ref<boolean> : undefined;\n display: GetComputableType<T[\"display\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n direction: GetComputableTypeWithDefault<T[\"direction\"], Direction.Up>;\n xoffset: GetComputableType<T[\"xoffset\"]>;\n yoffset: GetComputableType<T[\"yoffset\"]>;\n }\n>;\n\nexport type GenericTooltip = Replace<\n Tooltip<TooltipOptions>,\n {\n pinnable: boolean;\n pinned: Ref<boolean> | undefined;\n direction: ProcessedComputable<Direction>;\n }\n>;\n\nexport function addTooltip<T extends TooltipOptions>(\n element: VueFeature,\n options: T & ThisType<Tooltip<T>> & Partial<BaseTooltip>\n): Tooltip<T> {\n processComputable(options as T, \"display\");\n processComputable(options as T, \"classes\");\n processComputable(options as T, \"style\");\n processComputable(options as T, \"direction\");\n setDefault(options, \"direction\", Direction.Up);\n processComputable(options as T, \"xoffset\");\n processComputable(options as T, \"yoffset\");\n\n nextTick(() => {\n if (options.pinnable) {\n if (\"pinned\" in element) {\n console.error(\n \"Cannot add pinnable tooltip to element that already has a property called 'pinned'\"\n );\n options.pinnable = false;\n } else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (element as any).pinned = options.pinned = persistent<boolean>(false);\n }\n }\n\n const elementComponent = element[Component];\n element[Component] = TooltipComponent;\n const elementGratherProps = element[GatherProps].bind(element);\n element[GatherProps] = function gatherTooltipProps(this: GenericTooltip) {\n const { display, classes, style, direction, xoffset, yoffset, pinned } = this;\n return {\n element: {\n [Component]: elementComponent,\n [GatherProps]: elementGratherProps\n },\n display,\n classes,\n style: unref(style),\n direction,\n xoffset,\n yoffset,\n pinned\n };\n }.bind(options as GenericTooltip);\n });\n\n return options as unknown as Tooltip<T>;\n}\n","import \"components/common/modifiers.css\";\nimport { CoercableComponent, jsx } from \"features/feature\";\nimport Decimal, { DecimalSource, format } from \"util/bignum\";\nimport { WithRequired } from \"util/common\";\nimport { Computable, convertComputable, ProcessedComputable } from \"util/computed\";\nimport { renderJSX } from \"util/vue\";\nimport { computed, unref } from \"vue\";\n\n/**\n * An object that can be used to apply or unapply some modification to a number.\n * Being reversible requires the operation being invertible, but some features may rely on that.\n * Descriptions can be optionally included for displaying them to the player.\n * The built-in modifier creators are designed to display the modifiers using.\n * {@link createModifierSection}.\n */\nexport interface Modifier {\n /** Applies some operation on the input and returns the result. */\n apply: (gain: DecimalSource) => DecimalSource;\n /** Reverses the operation applied by the apply property. Required by some features. */\n revert?: (gain: DecimalSource) => DecimalSource;\n /**\n * Whether or not this modifier should be considered enabled.\n * Typically for use with modifiers passed into {@link createSequentialModifier}.\n */\n enabled?: ProcessedComputable<boolean>;\n /**\n * A description of this modifier.\n * @see {@link createModifierSection}.\n */\n description?: ProcessedComputable<CoercableComponent>;\n}\n\n/**\n * Utility type used to narrow down a modifier type that will have a description and/or enabled property based on optional parameters, T and S (respectively).\n */\nexport type ModifierFromOptionalParams<T, S> = T extends undefined\n ? S extends undefined\n ? Omit<WithRequired<Modifier, \"revert\">, \"description\" | \"enabled\">\n : Omit<WithRequired<Modifier, \"revert\" | \"enabled\">, \"description\">\n : S extends undefined\n ? Omit<WithRequired<Modifier, \"revert\" | \"description\">, \"enabled\">\n : WithRequired<Modifier, \"revert\" | \"enabled\" | \"description\">;\n\n/**\n * Create a modifier that adds some value to the input value.\n * @param addend The amount to add to the input value.\n * @param description Description of what this modifier is doing.\n * @param enabled A computable that will be processed and passed directly into the returned modifier.\n */\nexport function createAdditiveModifier<\n T extends Computable<CoercableComponent> | undefined,\n S extends Computable<boolean> | undefined,\n R = ModifierFromOptionalParams<T, S>\n>(addend: Computable<DecimalSource>, description?: T, enabled?: S): R {\n const processedAddend = convertComputable(addend);\n const processedDescription = convertComputable(description);\n const processedEnabled = enabled == null ? undefined : convertComputable(enabled);\n return {\n apply: (gain: DecimalSource) => Decimal.add(gain, unref(processedAddend)),\n revert: (gain: DecimalSource) => Decimal.sub(gain, unref(processedAddend)),\n enabled: processedEnabled,\n description:\n description == null\n ? undefined\n : jsx(() => (\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">\n {Decimal.gte(unref(processedAddend), 0) ? \"+\" : \"\"}\n {format(unref(processedAddend))}\n </span>\n {unref(processedDescription) ? (\n <span class=\"modifier-description\">\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n {renderJSX(unref(processedDescription)!)}\n </span>\n ) : null}\n </div>\n ))\n } as unknown as R;\n}\n\n/**\n * Create a modifier that multiplies the input value by some value.\n * @param multiplier The value to multiply the input value by.\n * @param description Description of what this modifier is doing.\n * @param enabled A computable that will be processed and passed directly into the returned modifier.\n */\nexport function createMultiplicativeModifier<\n T extends Computable<CoercableComponent> | undefined,\n S extends Computable<boolean> | undefined,\n R = ModifierFromOptionalParams<T, S>\n>(multiplier: Computable<DecimalSource>, description?: T, enabled?: S): R {\n const processedMultiplier = convertComputable(multiplier);\n const processedDescription = convertComputable(description);\n const processedEnabled = enabled == null ? undefined : convertComputable(enabled);\n return {\n apply: (gain: DecimalSource) => Decimal.times(gain, unref(processedMultiplier)),\n revert: (gain: DecimalSource) => Decimal.div(gain, unref(processedMultiplier)),\n enabled: processedEnabled,\n description:\n description == null\n ? undefined\n : jsx(() => (\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">x{format(unref(processedMultiplier))}</span>\n {unref(processedDescription) ? (\n <span class=\"modifier-description\">\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n {renderJSX(unref(processedDescription)!)}\n </span>\n ) : null}\n </div>\n ))\n } as unknown as R;\n}\n\n/**\n * Create a modifier that raises the input value to the power of some value.\n * @param exponent The value to raise the input value to the power of.\n * @param description Description of what this modifier is doing.\n * @param enabled A computable that will be processed and passed directly into the returned modifier.\n */\nexport function createExponentialModifier<\n T extends Computable<CoercableComponent> | undefined,\n S extends Computable<boolean> | undefined,\n R = ModifierFromOptionalParams<T, S>\n>(exponent: Computable<DecimalSource>, description?: T, enabled?: S): R {\n const processedExponent = convertComputable(exponent);\n const processedDescription = convertComputable(description);\n const processedEnabled = enabled == null ? undefined : convertComputable(enabled);\n return {\n apply: (gain: DecimalSource) => Decimal.pow(gain, unref(processedExponent)),\n revert: (gain: DecimalSource) => Decimal.root(gain, unref(processedExponent)),\n enabled: processedEnabled,\n description:\n description == null\n ? undefined\n : jsx(() => (\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">^{format(unref(processedExponent))}</span>\n {unref(processedDescription) ? (\n <span class=\"modifier-description\">\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n {renderJSX(unref(processedDescription)!)}\n </span>\n ) : null}\n </div>\n ))\n } as unknown as R;\n}\n\n/**\n * Takes an array of modifiers and applies and reverses them in order.\n * Modifiers that are not enabled will not be applied nor reversed.\n * Also joins their descriptions together.\n * @param modifiers The modifiers to perform sequentially.\n * @see {@link createModifierSection}.\n */\nexport function createSequentialModifier<\n T extends Modifier[],\n S = T extends WithRequired<Modifier, \"revert\">[]\n ? WithRequired<Modifier, \"description\" | \"revert\">\n : Omit<WithRequired<Modifier, \"description\">, \"revert\">\n>(...modifiers: T): S {\n return {\n apply: (gain: DecimalSource) =>\n modifiers\n .filter(m => unref(m.enabled) !== false)\n .reduce((gain, modifier) => modifier.apply(gain), gain),\n revert: modifiers.every(m => m.revert != null)\n ? (gain: DecimalSource) =>\n modifiers\n .filter(m => unref(m.enabled) !== false)\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n .reduceRight((gain, modifier) => modifier.revert!(gain), gain)\n : undefined,\n enabled: computed(() => modifiers.filter(m => unref(m.enabled) !== false).length > 0),\n description: jsx(() => (\n <>\n {(\n modifiers\n .filter(m => unref(m.enabled) !== false)\n .map(m => unref(m.description))\n .filter(d => d) as CoercableComponent[]\n ).map(renderJSX)}\n </>\n ))\n } as unknown as S;\n}\n\n/**\n * Create a JSX element that displays a modifier.\n * Intended to be used with the output from {@link createSequentialModifier}.\n * @param title The header for the section.\n * @param subtitle Smaller text that appears in the header after the title.\n * @param modifier The modifier to render.\n * @param base The base value that'll be passed into the modifier.\n * @param unit The unit of the value being modified, if any.\n * @param baseText The label to use for the base value.\n */\nexport function createModifierSection(\n title: string,\n subtitle: string,\n modifier: WithRequired<Modifier, \"description\">,\n base: DecimalSource = 1,\n unit = \"\",\n baseText: CoercableComponent = \"Base\"\n) {\n return (\n <div>\n <h3>\n {title}\n {subtitle ? <span class=\"subtitle\"> ({subtitle})</span> : null}\n </h3>\n <br />\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">\n {format(base)}\n {unit}\n </span>\n <span class=\"modifier-description\">{renderJSX(baseText)}</span>\n </div>\n {renderJSX(unref(modifier.description))}\n <hr />\n Total: {format(modifier.apply(base))}\n {unit}\n </div>\n );\n}\n","import { defineComponent as _defineComponent } from 'vue'\nimport { toDisplayString as _toDisplayString, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, unref as _unref, isRef as _isRef, vModelText as _vModelText, createElementVNode as _createElementVNode, withDirectives as _withDirectives, normalizeClass as _normalizeClass, withCtx as _withCtx, createVNode as _createVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-38661d49\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"field\" }\nconst _hoisted_2 = {\n key: 0,\n class: \"field-title\"\n}\nconst _hoisted_3 = [\"min\", \"max\"]\n\nimport { computed, toRefs, unref } from \"vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport \"components/common/fields.css\";\nimport { Direction } from \"util/common\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: null,\n min: null,\n max: null\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: number): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n title?: string;\n modelValue?: number;\n min?: number;\n max?: number;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst value = computed({\n get() {\n return String(unref(props.modelValue) || 0);\n },\n set(value: string) {\n emit(\"update:modelValue\", Number(value));\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (__props.title)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, _toDisplayString(__props.title), 1))\n : _createCommentVNode(\"\", true),\n _createVNode(Tooltip, {\n display: `${_unref(value)}`,\n class: _normalizeClass({ fullWidth: !__props.title }),\n direction: _unref(Direction).Down\n }, {\n default: _withCtx(() => [\n _withDirectives(_createElementVNode(\"input\", {\n type: \"range\",\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(value) ? (value).value = $event : null)),\n min: __props.min,\n max: __props.max\n }, null, 8, _hoisted_3), [\n [_vModelText, _unref(value)]\n ])\n ]),\n _: 1\n }, 8, [\"display\", \"class\", \"direction\"])\n ]))\n}\n}\n\n})","import script from \"./Slider.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Slider.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Slider.vue?vue&type=style&index=0&id=38661d49&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-38661d49\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { nextTick, onMounted, ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst top = ref(\"0\");\nconst observer = new ResizeObserver(updateTop);\nconst element = ref<HTMLElement | null>(null);\n\nfunction updateTop() {\n let el = element.value;\n if (el == undefined) {\n return;\n }\n\n let newTop = 0;\n while (el.previousSibling) {\n const sibling = el.previousSibling as HTMLElement;\n if (sibling.dataset && \"vSticky\" in sibling.dataset) {\n newTop += sibling.offsetHeight;\n }\n el = sibling;\n }\n top.value = newTop + \"px\";\n}\n\nnextTick(updateTop);\ndocument.fonts.ready.then(updateTop);\n\nonMounted(() => {\n const el = element.value?.parentElement;\n if (el) {\n observer.observe(el);\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"sticky\",\n style: _normalizeStyle({ top: top.value }),\n ref_key: \"element\",\n ref: element,\n \"data-v-sticky\": \"\"\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 4))\n}\n}\n\n})","import script from \"./Sticky.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Sticky.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Sticky.vue?vue&type=style&index=0&id=77aa21df&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-77aa21df\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n height: null\n },\n setup(__props: any) {\n\n\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"vr\",\n style: _normalizeStyle({ height: __props.height })\n }, null, 4))\n}\n}\n\n})","import script from \"./VerticalRule.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./VerticalRule.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./VerticalRule.vue?vue&type=style&index=0&id=15f6e746&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-15f6e746\"]])\n\nexport default __exports__","import { resolveDynamicComponent as _resolveDynamicComponent, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n width: _ctx.unref(_ctx.width) + 'px',\n height: _ctx.unref(_ctx.height) + 'px',\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n class: _normalizeClass({\n bar: true,\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n _createElementVNode(\"div\", {\n class: \"overlayTextContainer border\",\n style: _normalizeStyle([\n { width: _ctx.unref(_ctx.width) + 'px', height: _ctx.unref(_ctx.height) + 'px' },\n _ctx.unref(_ctx.borderStyle) ?? {}\n ])\n }, [\n (_ctx.component)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component), {\n key: 0,\n class: \"overlayText\",\n style: _normalizeStyle(_ctx.unref(_ctx.textStyle))\n }, null, 8, [\"style\"]))\n : _createCommentVNode(\"\", true)\n ], 4),\n _createElementVNode(\"div\", {\n class: \"border\",\n style: _normalizeStyle([\n { width: _ctx.unref(_ctx.width) + 'px', height: _ctx.unref(_ctx.height) + 'px' },\n _ctx.unref(_ctx.style) ?? {},\n _ctx.unref(_ctx.baseStyle) ?? {},\n _ctx.unref(_ctx.borderStyle) ?? {}\n ])\n }, [\n _createElementVNode(\"div\", {\n class: \"fill\",\n style: _normalizeStyle([_ctx.barStyle, _ctx.unref(_ctx.style) ?? {}, _ctx.unref(_ctx.fillStyle) ?? {}])\n }, null, 4)\n ], 4),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport { CoercableComponent, Visibility } from \"features/feature\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { computeOptionalComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport { computed, CSSProperties, defineComponent, StyleValue, toRefs, unref } from \"vue\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { Direction } from \"util/common\";\n\nexport default defineComponent({\n props: {\n progress: {\n type: processedPropType<DecimalSource>(String, Object, Number),\n required: true\n },\n width: {\n type: processedPropType<number>(Number),\n required: true\n },\n height: {\n type: processedPropType<number>(Number),\n required: true\n },\n direction: {\n type: processedPropType<Direction>(String),\n required: true\n },\n display: processedPropType<CoercableComponent>(Object, String, Function),\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n borderStyle: processedPropType<StyleValue>(Object, String, Array),\n textStyle: processedPropType<StyleValue>(Object, String, Array),\n baseStyle: processedPropType<StyleValue>(Object, String, Array),\n fillStyle: processedPropType<StyleValue>(Object, String, Array),\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n MarkNode,\n Node\n },\n setup(props) {\n const { progress, width, height, direction, display } = toRefs(props);\n\n const normalizedProgress = computed(() => {\n let progressNumber =\n progress.value instanceof Decimal\n ? progress.value.toNumber()\n : Number(progress.value);\n return (1 - Math.min(Math.max(progressNumber, 0), 1)) * 100;\n });\n\n const barStyle = computed(() => {\n const barStyle: Partial<CSSProperties> = {\n width: unwrapRef(width) + 0.5 + \"px\",\n height: unwrapRef(height) + 0.5 + \"px\"\n };\n switch (unref(direction)) {\n case Direction.Up:\n barStyle.clipPath = `inset(${normalizedProgress.value}% 0% 0% 0%)`;\n barStyle.width = unwrapRef(width) + 1 + \"px\";\n break;\n case Direction.Down:\n barStyle.clipPath = `inset(0% 0% ${normalizedProgress.value}% 0%)`;\n barStyle.width = unwrapRef(width) + 1 + \"px\";\n break;\n case Direction.Right:\n barStyle.clipPath = `inset(0% ${normalizedProgress.value}% 0% 0%)`;\n break;\n case Direction.Left:\n barStyle.clipPath = `inset(0% 0% 0% ${normalizedProgress.value} + '%)`;\n break;\n case Direction.Default:\n barStyle.clipPath = \"inset(0% 50% 0% 0%)\";\n break;\n }\n return barStyle;\n });\n\n const component = computeOptionalComponent(display);\n\n return {\n normalizedProgress,\n barStyle,\n component,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Bar.vue?vue&type=template&id=bfa7e8b2&scoped=true&ts=true\"\nimport script from \"./Bar.vue?vue&type=script&lang=ts\"\nexport * from \"./Bar.vue?vue&type=script&lang=ts\"\n\nimport \"./Bar.vue?vue&type=style&index=0&id=bfa7e8b2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-bfa7e8b2\"]])\n\nexport default __exports__","import BarComponent from \"features/bars/Bar.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { DecimalSource } from \"util/bignum\";\nimport { Direction } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { unref } from \"vue\";\n\nexport const BarType = Symbol(\"Bar\");\n\nexport interface BarOptions {\n visibility?: Computable<Visibility>;\n width: Computable<number>;\n height: Computable<number>;\n direction: Computable<Direction>;\n style?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n borderStyle?: Computable<StyleValue>;\n baseStyle?: Computable<StyleValue>;\n textStyle?: Computable<StyleValue>;\n fillStyle?: Computable<StyleValue>;\n progress: Computable<DecimalSource>;\n display?: Computable<CoercableComponent>;\n mark?: Computable<boolean | string>;\n}\n\nexport interface BaseBar {\n id: string;\n type: typeof BarType;\n [Component]: typeof BarComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Bar<T extends BarOptions> = Replace<\n T & BaseBar,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n width: GetComputableType<T[\"width\"]>;\n height: GetComputableType<T[\"height\"]>;\n direction: GetComputableType<T[\"direction\"]>;\n style: GetComputableType<T[\"style\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n borderStyle: GetComputableType<T[\"borderStyle\"]>;\n baseStyle: GetComputableType<T[\"baseStyle\"]>;\n textStyle: GetComputableType<T[\"textStyle\"]>;\n fillStyle: GetComputableType<T[\"fillStyle\"]>;\n progress: GetComputableType<T[\"progress\"]>;\n display: GetComputableType<T[\"display\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n }\n>;\n\nexport type GenericBar = Replace<\n Bar<BarOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createBar<T extends BarOptions>(\n optionsFunc: OptionsFunc<T, Bar<T>, BaseBar>\n): Bar<T> {\n return createLazyProxy(() => {\n const bar = optionsFunc();\n bar.id = getUniqueID(\"bar-\");\n bar.type = BarType;\n bar[Component] = BarComponent;\n\n processComputable(bar as T, \"visibility\");\n setDefault(bar, \"visibility\", Visibility.Visible);\n processComputable(bar as T, \"width\");\n processComputable(bar as T, \"height\");\n processComputable(bar as T, \"direction\");\n processComputable(bar as T, \"style\");\n processComputable(bar as T, \"classes\");\n processComputable(bar as T, \"borderStyle\");\n processComputable(bar as T, \"baseStyle\");\n processComputable(bar as T, \"textStyle\");\n processComputable(bar as T, \"fillStyle\");\n processComputable(bar as T, \"progress\");\n processComputable(bar as T, \"display\");\n processComputable(bar as T, \"mark\");\n\n bar[GatherProps] = function (this: GenericBar) {\n const {\n progress,\n width,\n height,\n direction,\n display,\n visibility,\n style,\n classes,\n borderStyle,\n textStyle,\n baseStyle,\n fillStyle,\n mark,\n id\n } = this;\n return {\n progress,\n width,\n height,\n direction,\n display,\n visibility,\n style: unref(style),\n classes,\n borderStyle,\n textStyle,\n baseStyle,\n fillStyle,\n mark,\n id\n };\n };\n\n return bar as unknown as Bar<T>;\n });\n}\n","import ClickableComponent from \"features/clickables/Clickable.vue\";\nimport { Resource } from \"features/resources/resource\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport Decimal, { DecimalSource, format, formatWhole } from \"util/bignum\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { coerceComponent, isCoercableComponent } from \"util/vue\";\nimport { computed, Ref, unref } from \"vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n jsx,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"./feature\";\n\nexport const BuyableType = Symbol(\"Buyable\");\n\nexport type BuyableDisplay =\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n effectDisplay?: CoercableComponent;\n };\n\nexport interface BuyableOptions {\n visibility?: Computable<Visibility>;\n cost?: Computable<DecimalSource>;\n resource?: Resource;\n canPurchase?: Computable<boolean>;\n purchaseLimit?: Computable<DecimalSource>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n mark?: Computable<boolean | string>;\n small?: Computable<boolean>;\n display?: Computable<BuyableDisplay>;\n onPurchase?: (cost: DecimalSource | undefined) => void;\n}\n\nexport interface BaseBuyable {\n id: string;\n amount: Persistent<DecimalSource>;\n maxed: Ref<boolean>;\n canAfford: Ref<boolean>;\n canClick: ProcessedComputable<boolean>;\n onClick: VoidFunction;\n purchase: VoidFunction;\n type: typeof BuyableType;\n [Component]: typeof ClickableComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Buyable<T extends BuyableOptions> = Replace<\n T & BaseBuyable,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n cost: GetComputableType<T[\"cost\"]>;\n resource: GetComputableType<T[\"resource\"]>;\n canPurchase: GetComputableTypeWithDefault<T[\"canPurchase\"], Ref<boolean>>;\n purchaseLimit: GetComputableTypeWithDefault<T[\"purchaseLimit\"], Decimal>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n small: GetComputableType<T[\"small\"]>;\n display: Ref<CoercableComponent>;\n }\n>;\n\nexport type GenericBuyable = Replace<\n Buyable<BuyableOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canPurchase: ProcessedComputable<boolean>;\n purchaseLimit: ProcessedComputable<DecimalSource>;\n }\n>;\n\nexport function createBuyable<T extends BuyableOptions>(\n optionsFunc: OptionsFunc<T, Buyable<T>, BaseBuyable>\n): Buyable<T> {\n const amount = persistent<DecimalSource>(0);\n return createLazyProxy(() => {\n const buyable = optionsFunc();\n\n if (buyable.canPurchase == null && (buyable.resource == null || buyable.cost == null)) {\n console.warn(\n \"Cannot create buyable without a canPurchase property or a resource and cost property\",\n buyable\n );\n throw \"Cannot create buyable without a canPurchase property or a resource and cost property\";\n }\n\n buyable.id = getUniqueID(\"buyable-\");\n buyable.type = BuyableType;\n buyable[Component] = ClickableComponent;\n\n buyable.amount = amount;\n buyable.canAfford = computed(() => {\n const genericBuyable = buyable as GenericBuyable;\n const cost = unref(genericBuyable.cost);\n return (\n genericBuyable.resource != null &&\n cost != null &&\n Decimal.gte(genericBuyable.resource.value, cost)\n );\n });\n if (buyable.canPurchase == null) {\n buyable.canPurchase = computed(\n () =>\n unref((buyable as GenericBuyable).visibility) === Visibility.Visible &&\n unref((buyable as GenericBuyable).canAfford) &&\n Decimal.lt(\n (buyable as GenericBuyable).amount.value,\n unref((buyable as GenericBuyable).purchaseLimit)\n )\n );\n }\n buyable.maxed = computed(() =>\n Decimal.gte(\n (buyable as GenericBuyable).amount.value,\n unref((buyable as GenericBuyable).purchaseLimit)\n )\n );\n processComputable(buyable as T, \"classes\");\n const classes = buyable.classes as ProcessedComputable<Record<string, boolean>> | undefined;\n buyable.classes = computed(() => {\n const currClasses = unref(classes) || {};\n if ((buyable as GenericBuyable).maxed.value) {\n currClasses.bought = true;\n }\n return currClasses;\n });\n processComputable(buyable as T, \"canPurchase\");\n buyable.canClick = buyable.canPurchase as ProcessedComputable<boolean>;\n buyable.onClick = buyable.purchase =\n buyable.onClick ??\n buyable.purchase ??\n function (this: GenericBuyable) {\n const genericBuyable = buyable as GenericBuyable;\n if (!unref(genericBuyable.canPurchase)) {\n return;\n }\n const cost = unref(genericBuyable.cost);\n if (genericBuyable.cost != null && genericBuyable.resource != null) {\n genericBuyable.resource.value = Decimal.sub(\n genericBuyable.resource.value,\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n cost!\n );\n genericBuyable.amount.value = Decimal.add(genericBuyable.amount.value, 1);\n }\n genericBuyable.onPurchase?.(cost);\n };\n processComputable(buyable as T, \"display\");\n const display = buyable.display;\n buyable.display = jsx(() => {\n // TODO once processComputable types correctly, remove this \"as X\"\n const currDisplay = unref(display) as BuyableDisplay;\n if (isCoercableComponent(currDisplay)) {\n const CurrDisplay = coerceComponent(currDisplay);\n return <CurrDisplay />;\n }\n if (currDisplay != null && buyable.cost != null && buyable.resource != null) {\n const genericBuyable = buyable as GenericBuyable;\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description);\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\");\n const amountDisplay =\n unref(genericBuyable.purchaseLimit) === Decimal.dInf ? (\n <>Amount: {formatWhole(genericBuyable.amount.value)}</>\n ) : (\n <>\n Amount: {formatWhole(genericBuyable.amount.value)} /{\" \"}\n {formatWhole(unref(genericBuyable.purchaseLimit))}\n </>\n );\n\n return (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n <div>\n <br />\n {amountDisplay}\n </div>\n {currDisplay.effectDisplay ? (\n <div>\n <br />\n Currently: <EffectDisplay />\n </div>\n ) : null}\n {genericBuyable.cost && !genericBuyable.maxed.value ? (\n <div>\n <br />\n Cost: {format(unref(genericBuyable.cost) || 0)}{\" \"}\n {buyable.resource.displayName}\n </div>\n ) : null}\n </span>\n );\n }\n return \"\";\n });\n\n processComputable(buyable as T, \"visibility\");\n setDefault(buyable, \"visibility\", Visibility.Visible);\n processComputable(buyable as T, \"cost\");\n processComputable(buyable as T, \"resource\");\n processComputable(buyable as T, \"purchaseLimit\");\n setDefault(buyable, \"purchaseLimit\", Decimal.dInf);\n processComputable(buyable as T, \"style\");\n processComputable(buyable as T, \"mark\");\n processComputable(buyable as T, \"small\");\n\n buyable[GatherProps] = function (this: GenericBuyable) {\n const { display, visibility, style, classes, onClick, canClick, small, mark, id } =\n this;\n return {\n display,\n visibility,\n style: unref(style),\n classes,\n onClick,\n canClick,\n small,\n mark,\n id\n };\n };\n\n return buyable as unknown as Buyable<T>;\n });\n}\n","import { toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5e580749\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"disabled\"]\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.notifyStyle,\n _ctx.unref(_ctx.style) ?? {}\n ]),\n class: _normalizeClass({\n feature: true,\n challenge: true,\n done: _ctx.unref(_ctx.completed),\n canStart: _ctx.unref(_ctx.canStart) && !_ctx.unref(_ctx.maxed),\n maxed: _ctx.unref(_ctx.maxed),\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n _createElementVNode(\"button\", {\n class: \"toggleChallenge\",\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.toggle && _ctx.toggle(...args))),\n disabled: !_ctx.unref(_ctx.canStart) || _ctx.unref(_ctx.maxed)\n }, _toDisplayString(_ctx.buttonText), 9, _hoisted_1),\n (_ctx.unref(_ctx.comp))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp)), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport { GenericChallenge } from \"features/challenges/challenge\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport { getHighNotifyStyle, getNotifyStyle } from \"game/notifications\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport {\n Component,\n computed,\n defineComponent,\n PropType,\n shallowRef,\n toRefs,\n unref,\n UnwrapRef,\n watchEffect\n} from \"vue\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\n\nexport default defineComponent({\n props: {\n active: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n maxed: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n canComplete: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n display: processedPropType<UnwrapRef<GenericChallenge[\"display\"]>>(\n String,\n Object,\n Function\n ),\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n completed: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n canStart: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n },\n toggle: {\n type: Function as PropType<VoidFunction>,\n required: true\n }\n },\n components: {\n MarkNode,\n Node\n },\n setup(props) {\n const { active, maxed, canComplete, display } = toRefs(props);\n\n const buttonText = computed(() => {\n if (active.value) {\n return canComplete.value ? \"Finish\" : \"Exit Early\";\n }\n if (maxed.value) {\n return \"Completed\";\n }\n return \"Start\";\n });\n\n const comp = shallowRef<Component | string>(\"\");\n\n const notifyStyle = computed(() => {\n const currActive = unwrapRef(active);\n const currCanComplete = unwrapRef(canComplete);\n if (currActive) {\n if (currCanComplete) {\n return getHighNotifyStyle();\n }\n return getNotifyStyle();\n }\n return {};\n });\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n comp.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n comp.value = coerceComponent(currDisplay);\n return;\n }\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description, \"div\");\n const Goal = coerceComponent(currDisplay.goal || \"\");\n const Reward = coerceComponent(currDisplay.reward || \"\");\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\");\n comp.value = coerceComponent(\n jsx(() => (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n {currDisplay.goal ? (\n <div>\n <br />\n Goal: <Goal />\n </div>\n ) : null}\n {currDisplay.reward ? (\n <div>\n <br />\n Reward: <Reward />\n </div>\n ) : null}\n {currDisplay.effectDisplay ? (\n <div>\n Currently: <EffectDisplay />\n </div>\n ) : null}\n </span>\n ))\n );\n });\n\n return {\n buttonText,\n notifyStyle,\n comp,\n Visibility,\n unref\n };\n }\n});\n","import { render } from \"./Challenge.vue?vue&type=template&id=5e580749&scoped=true&ts=true\"\nimport script from \"./Challenge.vue?vue&type=script&lang=tsx\"\nexport * from \"./Challenge.vue?vue&type=script&lang=tsx\"\n\nimport \"./Challenge.vue?vue&type=style&index=0&id=5e580749&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-5e580749\"]])\n\nexport default __exports__","import { isArray } from \"@vue/shared\";\nimport Toggle from \"components/fields/Toggle.vue\";\nimport ChallengeComponent from \"features/challenges/Challenge.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n jsx,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { GenericReset } from \"features/reset\";\nimport { Resource } from \"features/resources/resource\";\nimport { globalBus } from \"game/events\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport settings, { registerSettingField } from \"game/settings\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref, watch, WatchStopHandle } from \"vue\";\n\nexport const ChallengeType = Symbol(\"ChallengeType\");\n\nexport interface ChallengeOptions {\n visibility?: Computable<Visibility>;\n canStart?: Computable<boolean>;\n reset?: GenericReset;\n canComplete?: Computable<boolean | DecimalSource>;\n completionLimit?: Computable<DecimalSource>;\n mark?: Computable<boolean | string>;\n resource?: Resource;\n goal?: Computable<DecimalSource>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n display?: Computable<\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n goal?: CoercableComponent;\n reward?: CoercableComponent;\n effectDisplay?: CoercableComponent;\n }\n >;\n onComplete?: VoidFunction;\n onExit?: VoidFunction;\n onEnter?: VoidFunction;\n}\n\nexport interface BaseChallenge {\n id: string;\n completions: Persistent<DecimalSource>;\n completed: Ref<boolean>;\n maxed: Ref<boolean>;\n active: Persistent<boolean>;\n toggle: VoidFunction;\n complete: (remainInChallenge?: boolean) => void;\n type: typeof ChallengeType;\n [Component]: typeof ChallengeComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Challenge<T extends ChallengeOptions> = Replace<\n T & BaseChallenge,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n canStart: GetComputableTypeWithDefault<T[\"canStart\"], true>;\n canComplete: GetComputableTypeWithDefault<T[\"canComplete\"], Ref<boolean>>;\n completionLimit: GetComputableTypeWithDefault<T[\"completionLimit\"], 1>;\n mark: GetComputableTypeWithDefault<T[\"mark\"], Ref<boolean>>;\n goal: GetComputableType<T[\"goal\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericChallenge = Replace<\n Challenge<ChallengeOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canStart: ProcessedComputable<boolean>;\n canComplete: ProcessedComputable<boolean | DecimalSource>;\n completionLimit: ProcessedComputable<DecimalSource>;\n mark: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createChallenge<T extends ChallengeOptions>(\n optionsFunc: OptionsFunc<T, Challenge<T>, BaseChallenge>\n): Challenge<T> {\n const completions = persistent(0);\n const active = persistent(false);\n return createLazyProxy(() => {\n const challenge = optionsFunc();\n\n if (\n challenge.canComplete == null &&\n (challenge.resource == null || challenge.goal == null)\n ) {\n console.warn(\n \"Cannot create challenge without a canComplete property or a resource and goal property\",\n challenge\n );\n throw \"Cannot create challenge without a canComplete property or a resource and goal property\";\n }\n\n challenge.id = getUniqueID(\"challenge-\");\n challenge.type = ChallengeType;\n challenge[Component] = ChallengeComponent;\n\n challenge.completions = completions;\n challenge.active = active;\n challenge.completed = computed(() =>\n Decimal.gt((challenge as GenericChallenge).completions.value, 0)\n );\n challenge.maxed = computed(() =>\n Decimal.gte(\n (challenge as GenericChallenge).completions.value,\n unref((challenge as GenericChallenge).completionLimit)\n )\n );\n challenge.toggle = function () {\n const genericChallenge = challenge as GenericChallenge;\n if (genericChallenge.active.value) {\n if (unref(genericChallenge.canComplete) && !genericChallenge.maxed.value) {\n let completions: boolean | DecimalSource = unref(genericChallenge.canComplete);\n if (typeof completions === \"boolean\") {\n completions = 1;\n }\n genericChallenge.completions.value = Decimal.min(\n Decimal.add(genericChallenge.completions.value, completions),\n unref(genericChallenge.completionLimit)\n );\n genericChallenge.onComplete?.();\n }\n genericChallenge.active.value = false;\n genericChallenge.onExit?.();\n genericChallenge.reset?.reset();\n } else if (\n unref(genericChallenge.canStart) &&\n unref(genericChallenge.visibility) === Visibility.Visible &&\n !genericChallenge.maxed.value\n ) {\n genericChallenge.reset?.reset();\n genericChallenge.active.value = true;\n genericChallenge.onEnter?.();\n }\n };\n challenge.complete = function (remainInChallenge?: boolean) {\n const genericChallenge = challenge as GenericChallenge;\n let completions: boolean | DecimalSource = unref(genericChallenge.canComplete);\n if (\n genericChallenge.active.value &&\n completions !== false &&\n (completions === true || Decimal.neq(0, completions)) &&\n !genericChallenge.maxed.value\n ) {\n if (typeof completions === \"boolean\") {\n completions = 1;\n }\n genericChallenge.completions.value = Decimal.min(\n Decimal.add(genericChallenge.completions.value, completions),\n unref(genericChallenge.completionLimit)\n );\n genericChallenge.onComplete?.();\n if (remainInChallenge !== true) {\n genericChallenge.active.value = false;\n genericChallenge.onExit?.();\n genericChallenge.reset?.reset();\n }\n }\n };\n processComputable(challenge as T, \"visibility\");\n setDefault(challenge, \"visibility\", Visibility.Visible);\n const visibility = challenge.visibility as ProcessedComputable<Visibility>;\n challenge.visibility = computed(() => {\n if (settings.hideChallenges === true && unref(challenge.maxed)) {\n return Visibility.None;\n }\n return unref(visibility);\n });\n if (challenge.canComplete == null) {\n challenge.canComplete = computed(() => {\n const genericChallenge = challenge as GenericChallenge;\n if (\n !genericChallenge.active.value ||\n genericChallenge.resource == null ||\n genericChallenge.goal == null\n ) {\n return false;\n }\n return Decimal.gte(genericChallenge.resource.value, unref(genericChallenge.goal));\n });\n }\n if (challenge.mark == null) {\n challenge.mark = computed(\n () =>\n Decimal.gt(unref((challenge as GenericChallenge).completionLimit), 1) &&\n !!unref(challenge.maxed)\n );\n }\n\n processComputable(challenge as T, \"canStart\");\n setDefault(challenge, \"canStart\", true);\n processComputable(challenge as T, \"canComplete\");\n processComputable(challenge as T, \"completionLimit\");\n setDefault(challenge, \"completionLimit\", 1);\n processComputable(challenge as T, \"mark\");\n processComputable(challenge as T, \"goal\");\n processComputable(challenge as T, \"classes\");\n processComputable(challenge as T, \"style\");\n processComputable(challenge as T, \"display\");\n\n if (challenge.reset != null) {\n globalBus.on(\"reset\", currentReset => {\n if (currentReset === challenge.reset && (challenge.active as Ref<boolean>).value) {\n (challenge.toggle as VoidFunction)();\n }\n });\n }\n\n challenge[GatherProps] = function (this: GenericChallenge) {\n const {\n active,\n maxed,\n canComplete,\n display,\n visibility,\n style,\n classes,\n completed,\n canStart,\n mark,\n id,\n toggle\n } = this;\n return {\n active,\n maxed,\n canComplete,\n display,\n visibility,\n style: unref(style),\n classes,\n completed,\n canStart,\n mark,\n id,\n toggle\n };\n };\n\n return challenge as unknown as Challenge<T>;\n });\n}\n\nexport function setupAutoComplete(\n challenge: GenericChallenge,\n autoActive: Computable<boolean> = true,\n exitOnComplete = true\n): WatchStopHandle {\n const isActive = typeof autoActive === \"function\" ? computed(autoActive) : autoActive;\n return watch([challenge.canComplete, isActive], ([canComplete, isActive]) => {\n if (canComplete && isActive) {\n challenge.complete(!exitOnComplete);\n }\n });\n}\n\nexport function createActiveChallenge(\n challenges: GenericChallenge[]\n): Ref<GenericChallenge | undefined> {\n return computed(() => challenges.find(challenge => challenge.active.value));\n}\n\nexport function isAnyChallengeActive(\n challenges: GenericChallenge[] | Ref<GenericChallenge | undefined>\n): Ref<boolean> {\n if (isArray(challenges)) {\n challenges = createActiveChallenge(challenges);\n }\n return computed(() => (challenges as Ref<GenericChallenge | undefined>).value != null);\n}\n\ndeclare module \"game/settings\" {\n interface Settings {\n hideChallenges: boolean;\n }\n}\n\nglobalBus.on(\"loadSettings\", settings => {\n setDefault(settings, \"hideChallenges\", false);\n});\n\nregisterSettingField(\n jsx(() => (\n <Toggle\n title=\"Hide Maxed Challenges\"\n onUpdate:modelValue={value => (settings.hideChallenges = value)}\n modelValue={settings.hideChallenges}\n />\n ))\n);\n","import { hasWon } from \"data/projEntry\";\nimport { globalBus } from \"game/events\";\nimport player from \"game/player\";\nimport { registerInfoComponent } from \"game/settings\";\nimport {\n Computable,\n GetComputableTypeWithDefault,\n GetComputableType,\n ProcessedComputable,\n processComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { shallowReactive, unref } from \"vue\";\nimport { OptionsFunc, findFeatures, jsx, Replace, setDefault } from \"./feature\";\n\nexport const hotkeys: Record<string, GenericHotkey | undefined> = shallowReactive({});\nexport const HotkeyType = Symbol(\"Hotkey\");\n\nexport interface HotkeyOptions {\n enabled?: Computable<boolean>;\n key: string;\n description: Computable<string>;\n onPress: VoidFunction;\n}\n\nexport interface BaseHotkey {\n type: typeof HotkeyType;\n}\n\nexport type Hotkey<T extends HotkeyOptions> = Replace<\n T & BaseHotkey,\n {\n enabled: GetComputableTypeWithDefault<T[\"enabled\"], true>;\n description: GetComputableType<T[\"description\"]>;\n }\n>;\n\nexport type GenericHotkey = Replace<\n Hotkey<HotkeyOptions>,\n {\n enabled: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createHotkey<T extends HotkeyOptions>(\n optionsFunc: OptionsFunc<T, Hotkey<T>, BaseHotkey>\n): Hotkey<T> {\n return createLazyProxy(() => {\n const hotkey = optionsFunc();\n hotkey.type = HotkeyType;\n\n processComputable(hotkey as T, \"enabled\");\n setDefault(hotkey, \"enabled\", true);\n processComputable(hotkey as T, \"description\");\n\n return hotkey as unknown as Hotkey<T>;\n });\n}\n\nglobalBus.on(\"addLayer\", layer => {\n (findFeatures(layer, HotkeyType) as GenericHotkey[]).forEach(hotkey => {\n hotkeys[hotkey.key] = hotkey;\n });\n});\n\nglobalBus.on(\"removeLayer\", layer => {\n (findFeatures(layer, HotkeyType) as GenericHotkey[]).forEach(hotkey => {\n hotkeys[hotkey.key] = undefined;\n });\n});\n\ndocument.onkeydown = function (e) {\n if ((e.target as HTMLElement | null)?.tagName === \"INPUT\") {\n return;\n }\n if (hasWon.value && !player.keepGoing) {\n return;\n }\n let key = e.key;\n if (e.shiftKey) {\n key = \"shift+\" + key;\n }\n if (e.ctrlKey) {\n key = \"ctrl+\" + key;\n }\n const hotkey = hotkeys[key];\n if (hotkey && unref(hotkey.enabled)) {\n e.preventDefault();\n hotkey.onPress();\n }\n};\n\nregisterInfoComponent(\n jsx(() => {\n const keys = Object.values(hotkeys).filter(hotkey => unref(hotkey?.enabled));\n if (keys.length === 0) {\n return \"\";\n }\n return (\n <div>\n <br />\n <h4>Hotkeys</h4>\n {keys.map(hotkey => (\n <div>\n {hotkey?.key}: {hotkey?.description}\n </div>\n ))}\n </div>\n );\n })\n);\n","import LinksComponent from \"./Links.vue\";\nimport { Component, OptionsFunc, GatherProps, Replace } from \"features/feature\";\nimport { Position } from \"game/layers\";\nimport {\n Computable,\n GetComputableType,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { SVGAttributes } from \"vue\";\n\nexport const LinksType = Symbol(\"Links\");\n\nexport interface Link extends SVGAttributes {\n startNode: { id: string };\n endNode: { id: string };\n offsetStart?: Position;\n offsetEnd?: Position;\n}\n\nexport interface LinksOptions {\n links: Computable<Link[]>;\n}\n\nexport interface BaseLinks {\n type: typeof LinksType;\n [Component]: typeof LinksComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Links<T extends LinksOptions> = Replace<\n T & BaseLinks,\n {\n links: GetComputableType<T[\"links\"]>;\n }\n>;\n\nexport type GenericLinks = Replace<\n Links<LinksOptions>,\n {\n links: ProcessedComputable<Link[]>;\n }\n>;\n\nexport function createLinks<T extends LinksOptions>(\n optionsFunc: OptionsFunc<T, Links<T>, BaseLinks>\n): Links<T> {\n return createLazyProxy(() => {\n const links = optionsFunc();\n links.type = LinksType;\n links[Component] = LinksComponent;\n\n processComputable(links as T, \"links\");\n\n links[GatherProps] = function (this: GenericLinks) {\n const { links } = this;\n return {\n links\n };\n };\n\n return links as unknown as Links<T>;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n class: _normalizeClass({ feature: true, milestone: true, done: _ctx.unref(_ctx.earned), ..._ctx.unref(_ctx.classes) })\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp)))),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport { GenericMilestone } from \"features/milestones/milestone\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport { Component, defineComponent, shallowRef, toRefs, unref, UnwrapRef, watchEffect } from \"vue\";\nimport Node from \"../../components/Node.vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: {\n type: processedPropType<UnwrapRef<GenericMilestone[\"display\"]>>(\n String,\n Object,\n Function\n ),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n earned: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node\n },\n setup(props) {\n const { display } = toRefs(props);\n\n const comp = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n comp.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n comp.value = coerceComponent(currDisplay);\n return;\n }\n const Requirement = coerceComponent(currDisplay.requirement, \"h3\");\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\", \"b\");\n const OptionsDisplay = coerceComponent(currDisplay.optionsDisplay || \"\", \"span\");\n comp.value = coerceComponent(\n jsx(() => (\n <span>\n <Requirement />\n {currDisplay.effectDisplay ? (\n <div>\n <EffectDisplay />\n </div>\n ) : null}\n {currDisplay.optionsDisplay ? (\n <div class=\"equal-spaced\">\n <OptionsDisplay />\n </div>\n ) : null}\n </span>\n ))\n );\n });\n\n return {\n comp,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Milestone.vue?vue&type=template&id=0b660ac3&scoped=true&ts=true\"\nimport script from \"./Milestone.vue?vue&type=script&lang=tsx\"\nexport * from \"./Milestone.vue?vue&type=script&lang=tsx\"\n\nimport \"./Milestone.vue?vue&type=style&index=0&id=0b660ac3&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-0b660ac3\"]])\n\nexport default __exports__","import Select from \"components/fields/Select.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n jsx,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport MilestoneComponent from \"features/milestones/Milestone.vue\";\nimport { globalBus } from \"game/events\";\nimport \"game/notifications\";\nimport { persistent, Persistent } from \"game/persistence\";\nimport settings, { registerSettingField } from \"game/settings\";\nimport { camelToTitle } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { coerceComponent, isCoercableComponent } from \"util/vue\";\nimport { computed, unref, watchEffect } from \"vue\";\nimport { useToast } from \"vue-toastification\";\n\nconst toast = useToast();\n\nexport const MilestoneType = Symbol(\"Milestone\");\n\nexport enum MilestoneDisplay {\n All = \"all\",\n //Last = \"last\",\n Configurable = \"configurable\",\n Incomplete = \"incomplete\",\n None = \"none\"\n}\n\nexport interface MilestoneOptions {\n visibility?: Computable<Visibility>;\n shouldEarn?: () => boolean;\n style?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n display?: Computable<\n | CoercableComponent\n | {\n requirement: CoercableComponent;\n effectDisplay?: CoercableComponent;\n optionsDisplay?: CoercableComponent;\n }\n >;\n onComplete?: VoidFunction;\n}\n\nexport interface BaseMilestone {\n id: string;\n earned: Persistent<boolean>;\n complete: VoidFunction;\n type: typeof MilestoneType;\n [Component]: typeof MilestoneComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Milestone<T extends MilestoneOptions> = Replace<\n T & BaseMilestone,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n style: GetComputableType<T[\"style\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericMilestone = Replace<\n Milestone<MilestoneOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createMilestone<T extends MilestoneOptions>(\n optionsFunc?: OptionsFunc<T, Milestone<T>, BaseMilestone>\n): Milestone<T> {\n const earned = persistent<boolean>(false);\n return createLazyProxy(() => {\n const milestone = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n milestone.id = getUniqueID(\"milestone-\");\n milestone.type = MilestoneType;\n milestone[Component] = MilestoneComponent;\n\n milestone.earned = earned;\n milestone.complete = function () {\n earned.value = true;\n };\n\n processComputable(milestone as T, \"visibility\");\n setDefault(milestone, \"visibility\", Visibility.Visible);\n const visibility = milestone.visibility as ProcessedComputable<Visibility>;\n milestone.visibility = computed(() => {\n const display = unref((milestone as GenericMilestone).display);\n switch (settings.msDisplay) {\n default:\n case MilestoneDisplay.All:\n return unref(visibility);\n case MilestoneDisplay.Configurable:\n if (\n unref(milestone.earned) &&\n !(\n display != null &&\n typeof display == \"object\" &&\n \"optionsDisplay\" in (display as Record<string, unknown>)\n )\n ) {\n return Visibility.None;\n }\n return unref(visibility);\n case MilestoneDisplay.Incomplete:\n if (unref(milestone.earned)) {\n return Visibility.None;\n }\n return unref(visibility);\n case MilestoneDisplay.None:\n return Visibility.None;\n }\n });\n\n processComputable(milestone as T, \"style\");\n processComputable(milestone as T, \"classes\");\n processComputable(milestone as T, \"display\");\n\n milestone[GatherProps] = function (this: GenericMilestone) {\n const { visibility, display, style, classes, earned, id } = this;\n return { visibility, display, style: unref(style), classes, earned, id };\n };\n\n if (milestone.shouldEarn) {\n const genericMilestone = milestone as GenericMilestone;\n watchEffect(() => {\n if (\n !genericMilestone.earned.value &&\n unref(genericMilestone.visibility) === Visibility.Visible &&\n genericMilestone.shouldEarn?.()\n ) {\n genericMilestone.earned.value = true;\n genericMilestone.onComplete?.();\n if (genericMilestone.display) {\n const display = unref(genericMilestone.display);\n const Display = coerceComponent(\n isCoercableComponent(display) ? display : display.requirement\n );\n toast(\n <>\n <h3>Milestone earned!</h3>\n <div>\n {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}\n {/* @ts-ignore */}\n <Display />\n </div>\n </>\n );\n }\n }\n });\n }\n\n return milestone as unknown as Milestone<T>;\n });\n}\n\ndeclare module \"game/settings\" {\n interface Settings {\n msDisplay: MilestoneDisplay;\n }\n}\n\nglobalBus.on(\"loadSettings\", settings => {\n setDefault(settings, \"msDisplay\", MilestoneDisplay.All);\n});\n\nconst msDisplayOptions = Object.values(MilestoneDisplay).map(option => ({\n label: camelToTitle(option),\n value: option\n}));\n\nregisterSettingField(\n jsx(() => (\n <Select\n title=\"Show Milestones\"\n options={msDisplayOptions}\n onUpdate:modelValue={value => (settings.msDisplay = value as MilestoneDisplay)}\n modelValue={settings.msDisplay}\n />\n ))\n);\n","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock } from \"vue\"\n\nimport { CoercableComponent } from \"features/feature\";\nimport { computeComponent } from \"util/vue\";\nimport { toRefs } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n display: null\n },\n setup(__props: any) {\n\nconst _props = __props as { display: CoercableComponent }\n\n\nconst { display } = toRefs(_props);\nconst component = computeComponent(display);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(component))))\n}\n}\n\n})","import script from \"./Tab.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Tab.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n StyleValue\n} from \"features/feature\";\nimport TabComponent from \"features/tabs/Tab.vue\";\nimport { Computable, GetComputableType } from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\n\nexport const TabType = Symbol(\"Tab\");\n\nexport interface TabOptions {\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n display: Computable<CoercableComponent>;\n}\n\nexport interface BaseTab {\n id: string;\n type: typeof TabType;\n [Component]: typeof TabComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Tab<T extends TabOptions> = Replace<\n T & BaseTab,\n {\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericTab = Tab<TabOptions>;\n\nexport function createTab<T extends TabOptions>(\n optionsFunc: OptionsFunc<T, Tab<T>, BaseTab>\n): Tab<T> {\n return createLazyProxy(() => {\n const tab = optionsFunc();\n tab.id = getUniqueID(\"tab-\");\n tab.type = TabType;\n tab[Component] = TabComponent;\n\n tab[GatherProps] = function (this: GenericTab) {\n const { display } = this;\n return { display };\n };\n\n return tab as unknown as Tab<T>;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.selectTab && _ctx.selectTab(...args))),\n class: _normalizeClass([\"tabButton\", {\n active: _ctx.active,\n ..._ctx.unref(_ctx.classes)\n }]),\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.glowColorStyle,\n _ctx.unref(_ctx.style) ?? {}\n ])\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component)))\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport { getNotifyStyle } from \"game/notifications\";\nimport { computeComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport { computed, defineComponent, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n glowColor: processedPropType<string>(String),\n active: Boolean,\n floating: Boolean\n },\n emits: [\"selectTab\"],\n setup(props, { emit }) {\n const { display, glowColor, floating } = toRefs(props);\n\n const component = computeComponent(display);\n\n const glowColorStyle = computed(() => {\n const color = unwrapRef(glowColor);\n if (!color) {\n return {};\n }\n if (unref(floating)) {\n return getNotifyStyle(color);\n }\n return { boxShadow: `0px 9px 5px -6px ${color}` };\n });\n\n function selectTab() {\n emit(\"selectTab\");\n }\n\n return {\n selectTab,\n component,\n glowColorStyle,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./TabButton.vue?vue&type=template&id=3e3f03f9&scoped=true&ts=true\"\nimport script from \"./TabButton.vue?vue&type=script&lang=ts\"\nexport * from \"./TabButton.vue?vue&type=script&lang=ts\"\n\nimport \"./TabButton.vue?vue&type=style&index=0&id=3e3f03f9&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-3e3f03f9\"]])\n\nexport default __exports__","import { renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, resolveComponent as _resolveComponent, mergeProps as _mergeProps, createBlock as _createBlock, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, createCommentVNode as _createCommentVNode, normalizeStyle as _normalizeStyle } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_TabButton = _resolveComponent(\"TabButton\")!\n const _component_Sticky = _resolveComponent(\"Sticky\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: _normalizeClass([\"tab-family-container\", { ..._ctx.unref(_ctx.classes), ..._ctx.tabClasses }]),\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? [],\n _ctx.tabStyle ?? []\n ])\n }, [\n _createVNode(_component_Sticky, { class: \"tab-buttons-container\" }, {\n default: _withCtx(() => [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"tab-buttons\", { floating: _ctx.floating }])\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.unref(_ctx.tabs), (button, id) => {\n return (_openBlock(), _createBlock(_component_TabButton, _mergeProps({\n onSelectTab: ($event: any) => (_ctx.selected.value = id),\n floating: _ctx.floating,\n key: id,\n active: _ctx.unref(button.tab) === _ctx.unref(_ctx.activeTab)\n }, _ctx.gatherButtonProps(button)), null, 16, [\"onSelectTab\", \"floating\", \"active\"]))\n }), 128))\n ], 2)\n ]),\n _: 1\n }),\n (_ctx.unref(_ctx.activeTab))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.component)), { key: 0 }))\n : _createCommentVNode(\"\", true)\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport Sticky from \"components/layout/Sticky.vue\";\nimport themes from \"data/themes\";\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport { GenericTab } from \"features/tabs/tab\";\nimport TabButton from \"features/tabs/TabButton.vue\";\nimport { GenericTabButton } from \"features/tabs/tabFamily\";\nimport settings from \"game/settings\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport {\n Component,\n computed,\n defineComponent,\n PropType,\n Ref,\n shallowRef,\n toRefs,\n unref,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n activeTab: {\n type: processedPropType<GenericTab | CoercableComponent | null>(Object),\n required: true\n },\n selected: {\n type: Object as PropType<Ref<string>>,\n required: true\n },\n tabs: {\n type: processedPropType<Record<string, GenericTabButton>>(Object),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object)\n },\n components: {\n Sticky,\n TabButton\n },\n setup(props) {\n const { activeTab } = toRefs(props);\n\n const floating = computed(() => {\n return themes[settings.theme].floatingTabs;\n });\n\n const component = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currActiveTab = unwrapRef(activeTab);\n if (currActiveTab == null) {\n component.value = \"\";\n return;\n }\n if (isCoercableComponent(currActiveTab)) {\n component.value = coerceComponent(currActiveTab);\n return;\n }\n component.value = coerceComponent(unref(currActiveTab.display));\n });\n\n const tabClasses = computed(() => {\n const currActiveTab = unwrapRef(activeTab);\n const tabClasses =\n isCoercableComponent(currActiveTab) || !currActiveTab\n ? undefined\n : unref(currActiveTab.classes);\n return tabClasses;\n });\n\n const tabStyle = computed(() => {\n const currActiveTab = unwrapRef(activeTab);\n return isCoercableComponent(currActiveTab) || !currActiveTab\n ? undefined\n : unref(currActiveTab.style);\n });\n\n function gatherButtonProps(button: GenericTabButton) {\n const { display, style, classes, glowColor, visibility } = button;\n return { display, style: unref(style), classes, glowColor, visibility };\n }\n\n return {\n floating,\n tabClasses,\n tabStyle,\n Visibility,\n component,\n gatherButtonProps,\n unref\n };\n }\n});\n","import { render } from \"./TabFamily.vue?vue&type=template&id=46a6b098&scoped=true&ts=true\"\nimport script from \"./TabFamily.vue?vue&type=script&lang=ts\"\nexport * from \"./TabFamily.vue?vue&type=script&lang=ts\"\n\nimport \"./TabFamily.vue?vue&type=style&index=0&id=46a6b098&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-46a6b098\"]])\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport TabButtonComponent from \"features/tabs/TabButton.vue\";\nimport TabFamilyComponent from \"features/tabs/TabFamily.vue\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { GenericTab } from \"./tab\";\n\nexport const TabButtonType = Symbol(\"TabButton\");\nexport const TabFamilyType = Symbol(\"TabFamily\");\n\nexport interface TabButtonOptions {\n visibility?: Computable<Visibility>;\n tab: Computable<GenericTab | CoercableComponent>;\n display: Computable<CoercableComponent>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n glowColor?: Computable<string>;\n}\n\nexport interface BaseTabButton {\n type: typeof TabButtonType;\n [Component]: typeof TabButtonComponent;\n}\n\nexport type TabButton<T extends TabButtonOptions> = Replace<\n T & BaseTabButton,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n tab: GetComputableType<T[\"tab\"]>;\n display: GetComputableType<T[\"display\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n glowColor: GetComputableType<T[\"glowColor\"]>;\n }\n>;\n\nexport type GenericTabButton = Replace<\n TabButton<TabButtonOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport interface TabFamilyOptions {\n visibility?: Computable<Visibility>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n}\n\nexport interface BaseTabFamily {\n id: string;\n tabs: Record<string, TabButtonOptions>;\n activeTab: Ref<GenericTab | CoercableComponent | null>;\n selected: Persistent<string>;\n type: typeof TabFamilyType;\n [Component]: typeof TabFamilyComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type TabFamily<T extends TabFamilyOptions> = Replace<\n T & BaseTabFamily,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n tabs: Record<string, GenericTabButton>;\n }\n>;\n\nexport type GenericTabFamily = Replace<\n TabFamily<TabFamilyOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createTabFamily<T extends TabFamilyOptions>(\n tabs: Record<string, () => TabButtonOptions>,\n optionsFunc?: OptionsFunc<T, TabFamily<T>, BaseTabFamily>\n): TabFamily<T> {\n if (Object.keys(tabs).length === 0) {\n console.warn(\"Cannot create tab family with 0 tabs\");\n throw \"Cannot create tab family with 0 tabs\";\n }\n\n const selected = persistent(Object.keys(tabs)[0]);\n return createLazyProxy(() => {\n const tabFamily = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n\n tabFamily.id = getUniqueID(\"tabFamily-\");\n tabFamily.type = TabFamilyType;\n tabFamily[Component] = TabFamilyComponent;\n\n tabFamily.tabs = Object.keys(tabs).reduce<Record<string, GenericTabButton>>(\n (parsedTabs, tab) => {\n const tabButton: TabButtonOptions & Partial<BaseTabButton> = tabs[tab]();\n tabButton.type = TabButtonType;\n tabButton[Component] = TabButtonComponent;\n\n processComputable(tabButton as TabButtonOptions, \"visibility\");\n setDefault(tabButton, \"visibility\", Visibility.Visible);\n processComputable(tabButton as TabButtonOptions, \"tab\");\n processComputable(tabButton as TabButtonOptions, \"display\");\n processComputable(tabButton as TabButtonOptions, \"classes\");\n processComputable(tabButton as TabButtonOptions, \"style\");\n processComputable(tabButton as TabButtonOptions, \"glowColor\");\n parsedTabs[tab] = tabButton as GenericTabButton;\n return parsedTabs;\n },\n {}\n );\n tabFamily.selected = selected;\n tabFamily.activeTab = computed(() => {\n const tabs = unref(processedTabFamily.tabs);\n if (\n selected.value in tabs &&\n unref(tabs[selected.value].visibility) === Visibility.Visible\n ) {\n return unref(tabs[selected.value].tab);\n }\n const firstTab = Object.values(tabs).find(\n tab => unref(tab.visibility) === Visibility.Visible\n );\n if (firstTab) {\n return unref(firstTab.tab);\n }\n return null;\n });\n\n processComputable(tabFamily as T, \"visibility\");\n setDefault(tabFamily, \"visibility\", Visibility.Visible);\n processComputable(tabFamily as T, \"classes\");\n processComputable(tabFamily as T, \"style\");\n\n tabFamily[GatherProps] = function (this: GenericTabFamily) {\n const { visibility, activeTab, selected, tabs, style, classes } = this;\n return { visibility, activeTab, selected, tabs, style: unref(style), classes };\n };\n\n // This is necessary because board.types is different from T and TabFamily\n const processedTabFamily = tabFamily as unknown as TabFamily<T>;\n return processedTabFamily;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-6f164fe2\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"disabled\"]\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.purchase && _ctx.purchase(...args))),\n class: _normalizeClass({\n feature: true,\n upgrade: true,\n can: _ctx.unref(_ctx.canPurchase),\n locked: !_ctx.unref(_ctx.canPurchase),\n bought: _ctx.unref(_ctx.bought),\n ..._ctx.unref(_ctx.classes)\n }),\n disabled: !_ctx.unref(_ctx.canPurchase)\n }, [\n (_ctx.unref(_ctx.component))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.component)), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 14, _hoisted_1))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport { displayResource, Resource } from \"features/resources/resource\";\nimport { GenericUpgrade } from \"features/upgrades/upgrade\";\nimport { DecimalSource } from \"util/bignum\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport {\n Component,\n defineComponent,\n PropType,\n shallowRef,\n toRefs,\n unref,\n UnwrapRef,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n display: {\n type: processedPropType<UnwrapRef<GenericUpgrade[\"display\"]>>(String, Object, Function),\n required: true\n },\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n resource: Object as PropType<Resource>,\n cost: processedPropType<DecimalSource>(String, Object, Number),\n canPurchase: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n bought: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n },\n purchase: {\n type: Function as PropType<VoidFunction>,\n required: true\n }\n },\n components: {\n Node,\n MarkNode\n },\n setup(props) {\n const { display, cost } = toRefs(props);\n\n const component = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n component.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n component.value = coerceComponent(currDisplay);\n return;\n }\n const currCost = unwrapRef(cost);\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description, \"div\");\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\");\n component.value = coerceComponent(\n jsx(() => (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n {currDisplay.effectDisplay ? (\n <div>\n Currently: <EffectDisplay />\n </div>\n ) : null}\n {props.resource != null ? (\n <>\n <br />\n Cost: {props.resource &&\n displayResource(props.resource, currCost)}{\" \"}\n {props.resource?.displayName}\n </>\n ) : null}\n </span>\n ))\n );\n });\n\n return {\n component,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Upgrade.vue?vue&type=template&id=6f164fe2&scoped=true&ts=true\"\nimport script from \"./Upgrade.vue?vue&type=script&lang=tsx\"\nexport * from \"./Upgrade.vue?vue&type=script&lang=tsx\"\n\nimport \"./Upgrade.vue?vue&type=style&index=0&id=6f164fe2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-6f164fe2\"]])\n\nexport default __exports__","import UpgradeComponent from \"features/upgrades/Upgrade.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n findFeatures,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { Resource } from \"features/resources/resource\";\nimport { GenericLayer } from \"game/layers\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { isFunction } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { persistent, Persistent } from \"game/persistence\";\n\nexport const UpgradeType = Symbol(\"Upgrade\");\n\nexport interface UpgradeOptions {\n visibility?: Computable<Visibility>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n display?: Computable<\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n effectDisplay?: CoercableComponent;\n }\n >;\n mark?: Computable<boolean | string>;\n cost?: Computable<DecimalSource>;\n resource?: Resource;\n canAfford?: Computable<boolean>;\n onPurchase?: VoidFunction;\n}\n\nexport interface BaseUpgrade {\n id: string;\n bought: Persistent<boolean>;\n canPurchase: Ref<boolean>;\n purchase: VoidFunction;\n type: typeof UpgradeType;\n [Component]: typeof UpgradeComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Upgrade<T extends UpgradeOptions> = Replace<\n T & BaseUpgrade,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n display: GetComputableType<T[\"display\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n cost: GetComputableType<T[\"cost\"]>;\n canAfford: GetComputableTypeWithDefault<T[\"canAfford\"], Ref<boolean>>;\n }\n>;\n\nexport type GenericUpgrade = Replace<\n Upgrade<UpgradeOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canPurchase: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createUpgrade<T extends UpgradeOptions>(\n optionsFunc: OptionsFunc<T, Upgrade<T>, BaseUpgrade>\n): Upgrade<T> {\n const bought = persistent<boolean>(false);\n return createLazyProxy(() => {\n const upgrade = optionsFunc();\n upgrade.id = getUniqueID(\"upgrade-\");\n upgrade.type = UpgradeType;\n upgrade[Component] = UpgradeComponent;\n\n if (upgrade.canAfford == null && (upgrade.resource == null || upgrade.cost == null)) {\n console.warn(\n \"Error: can't create upgrade without a canAfford property or a resource and cost property\",\n upgrade\n );\n }\n\n upgrade.bought = bought;\n if (upgrade.canAfford == null) {\n upgrade.canAfford = computed(() => {\n const genericUpgrade = upgrade as GenericUpgrade;\n return (\n genericUpgrade.resource != null &&\n genericUpgrade.cost != null &&\n Decimal.gte(genericUpgrade.resource.value, unref(genericUpgrade.cost))\n );\n });\n } else {\n processComputable(upgrade as T, \"canAfford\");\n }\n upgrade.canPurchase = computed(\n () =>\n unref((upgrade as GenericUpgrade).visibility) === Visibility.Visible &&\n unref((upgrade as GenericUpgrade).canAfford) &&\n !unref(upgrade.bought)\n );\n upgrade.purchase = function () {\n const genericUpgrade = upgrade as GenericUpgrade;\n if (!unref(genericUpgrade.canPurchase)) {\n return;\n }\n if (genericUpgrade.resource != null && genericUpgrade.cost != null) {\n genericUpgrade.resource.value = Decimal.sub(\n genericUpgrade.resource.value,\n unref(genericUpgrade.cost)\n );\n }\n bought.value = true;\n genericUpgrade.onPurchase?.();\n };\n\n processComputable(upgrade as T, \"visibility\");\n setDefault(upgrade, \"visibility\", Visibility.Visible);\n processComputable(upgrade as T, \"classes\");\n processComputable(upgrade as T, \"style\");\n processComputable(upgrade as T, \"display\");\n processComputable(upgrade as T, \"mark\");\n processComputable(upgrade as T, \"cost\");\n processComputable(upgrade as T, \"resource\");\n\n upgrade[GatherProps] = function (this: GenericUpgrade) {\n const {\n display,\n visibility,\n style,\n classes,\n resource,\n cost,\n canPurchase,\n bought,\n mark,\n id,\n purchase\n } = this;\n return {\n display,\n visibility,\n style: unref(style),\n classes,\n resource,\n cost,\n canPurchase,\n bought,\n mark,\n id,\n purchase\n };\n };\n\n return upgrade as unknown as Upgrade<T>;\n });\n}\n\nexport function setupAutoPurchase(\n layer: GenericLayer,\n autoActive: Computable<boolean>,\n upgrades: GenericUpgrade[] = []\n): void {\n upgrades = upgrades || findFeatures(layer, UpgradeType);\n const isAutoActive = isFunction(autoActive) ? computed(autoActive) : autoActive;\n layer.on(\"update\", () => {\n if (unref(isAutoActive)) {\n upgrades.forEach(upgrade => upgrade.purchase());\n }\n });\n}\n","import Slider from \"components/fields/Slider.vue\";\nimport Text from \"components/fields/Text.vue\";\nimport Toggle from \"components/fields/Toggle.vue\";\nimport Column from \"components/layout/Column.vue\";\nimport Row from \"components/layout/Row.vue\";\nimport Spacer from \"components/layout/Spacer.vue\";\nimport Sticky from \"components/layout/Sticky.vue\";\nimport VerticalRule from \"components/layout/VerticalRule.vue\";\nimport Modal from \"components/Modal.vue\";\nimport { createLayerTreeNode, createResetButton } from \"data/common\";\nimport { main } from \"data/projEntry\";\nimport themes from \"data/themes\";\nimport { createBar } from \"features/bars/bar\";\nimport { createBuyable } from \"features/buyable\";\nimport { createChallenge } from \"features/challenges/challenge\";\nimport { createClickable } from \"features/clickables/clickable\";\nimport {\n addSoftcap,\n createCumulativeConversion,\n createPolynomialScaling\n} from \"features/conversion\";\nimport { jsx, showIf, Visibility } from \"features/feature\";\nimport { createHotkey } from \"features/hotkey\";\nimport { createInfobox } from \"features/infoboxes/infobox\";\nimport { createLinks } from \"features/links/links\";\nimport { createMilestone } from \"features/milestones/milestone\";\nimport { createReset } from \"features/reset\";\nimport MainDisplay from \"features/resources/MainDisplay.vue\";\nimport { createResource, displayResource, trackBest } from \"features/resources/resource\";\nimport Resource from \"features/resources/Resource.vue\";\nimport { createTab } from \"features/tabs/tab\";\nimport { createTabFamily } from \"features/tabs/tabFamily\";\nimport { addTooltip } from \"features/tooltips/tooltip\";\nimport {\n createResourceTooltip,\n createTree,\n createTreeNode,\n GenericTreeNode,\n TreeBranch\n} from \"features/trees/tree\";\nimport { createUpgrade } from \"features/upgrades/upgrade\";\nimport { createLayer } from \"game/layers\";\nimport {\n createAdditiveModifier,\n createExponentialModifier,\n createModifierSection,\n createSequentialModifier\n} from \"game/modifiers\";\nimport { persistent } from \"game/persistence\";\nimport settings from \"game/settings\";\nimport { DecimalSource } from \"lib/break_eternity\";\nimport Decimal, { format, formatWhole } from \"util/bignum\";\nimport { Direction } from \"util/common\";\nimport { render, renderCol, renderRow } from \"util/vue\";\nimport { computed, ComputedRef, ref } from \"vue\";\nimport f from \"./f\";\n\nconst id = \"c\";\nconst layer = createLayer(id, () => {\n const color = \"#4BDC13\";\n const name = \"Candies\";\n const points = createResource<DecimalSource>(0, \"lollipops\");\n const best = trackBest(points);\n const beep = persistent<boolean>(false);\n const thingy = persistent<string>(\"pointy\");\n const otherThingy = persistent<number>(10);\n const spentOnBuyables = persistent(new Decimal(10));\n\n const waffleBoost = computed(() => Decimal.pow(points.value, 0.2));\n const icecreamCap = computed(() => Decimal.times(points.value, 10));\n\n const coolInfo = createInfobox(() => ({\n title: \"Lore\",\n titleStyle: { color: \"#FE0000\" },\n display: \"DEEP LORE!\",\n bodyStyle: { backgroundColor: \"#0000EE\" },\n color: \"rgb(75, 220, 19)\"\n }));\n\n const lollipopMilestone3 = createMilestone(() => ({\n shouldEarn() {\n return Decimal.gte(best.value, 3);\n },\n display: {\n requirement: \"3 Lollipops\",\n effectDisplay: \"Unlock the next milestone\"\n }\n }));\n const lollipopMilestone4 = createMilestone(() => ({\n visibility() {\n return showIf(lollipopMilestone3.earned.value);\n },\n shouldEarn() {\n return Decimal.gte(best.value, 4);\n },\n display: {\n requirement: \"4 Lollipops\",\n effectDisplay: \"You can toggle beep and boop (which do nothing)\",\n optionsDisplay: jsx(() => (\n <>\n <Toggle\n title=\"beep\"\n onUpdate:modelValue={value => (beep.value = value)}\n modelValue={beep.value}\n />\n <Toggle\n title=\"boop\"\n onUpdate:modelValue={value => (f.boop.value = value)}\n modelValue={f.boop.value}\n />\n </>\n ))\n },\n style() {\n if (this.earned) {\n return { backgroundColor: \"#1111DD\" };\n }\n return {};\n }\n }));\n const lollipopMilestones = [lollipopMilestone3, lollipopMilestone4];\n\n const funChallenge = createChallenge(() => ({\n title: \"Fun\",\n completionLimit: 3,\n display() {\n return {\n description: `Makes the game 0% harder<br>${formatWhole(this.completions.value)}/${\n this.completionLimit\n } completions`,\n goal: \"Have 20 points I guess\",\n reward: \"Says hi\",\n effectDisplay: format(funEffect.value) + \"x\"\n };\n },\n visibility() {\n return showIf(Decimal.gt(best.value, 0));\n },\n goal: 20,\n resource: main.points,\n onComplete() {\n console.log(\"hiii\");\n },\n onEnter() {\n main.points.value = 0;\n main.best.value = main.points.value;\n main.total.value = main.points.value;\n console.log(\"So challenging\");\n },\n onExit() {\n console.log(\"Sweet freedom!\");\n },\n style: {\n height: \"200px\"\n }\n }));\n const funEffect = computed(() => Decimal.add(points.value, 1).tetrate(0.02));\n\n const generatorUpgrade = createUpgrade(() => ({\n display: {\n title: \"Generator of Genericness\",\n description: \"Gain 1 point every second\"\n },\n cost: 1,\n resource: points\n }));\n const lollipopMultiplierUpgrade = createUpgrade(() => ({\n display: () => ({\n description: \"Point generation is faster based on your unspent Lollipops\",\n effectDisplay: `${format(lollipopMultiplierEffect.value)}x`\n }),\n cost: 1,\n resource: points,\n visibility: () => showIf(generatorUpgrade.bought.value)\n }));\n const lollipopMultiplierEffect = computed(() => {\n let ret = Decimal.add(points.value, 1).pow(0.5);\n if (ret.gte(\"1e20000000\")) ret = ret.sqrt().times(\"1e10000000\");\n return ret;\n });\n const unlockIlluminatiUpgrade = createUpgrade(() => ({\n visibility() {\n return showIf(lollipopMultiplierUpgrade.bought.value);\n },\n canAfford() {\n return Decimal.lt(main.points.value, 7);\n },\n onPurchase() {\n main.points.value = Decimal.add(main.points.value, 7);\n },\n display:\n \"Only buyable with less than 7 points, and gives you 7 more. Unlocks a secret subtab.\",\n style() {\n if (this.bought) {\n return { backgroundColor: \"#1111dd\" };\n }\n if (!this.canAfford) {\n return { backgroundColor: \"#dd1111\" };\n }\n return {};\n }\n }));\n const quasiUpgrade = createUpgrade(() => ({\n resource: createResource(exhancers.amount, \"Exhancers\", 0),\n cost: 3,\n display: {\n title: \"This upgrade doesn't exist\",\n description: \"Or does it?\"\n }\n }));\n const upgrades = [generatorUpgrade, lollipopMultiplierUpgrade, unlockIlluminatiUpgrade];\n\n const exhancers = createBuyable(() => ({\n resource: points,\n cost() {\n let x = new Decimal(this.amount.value);\n if (x.gte(25)) {\n x = x.pow(2).div(25);\n }\n const cost = Decimal.pow(2, x.pow(1.5));\n return cost.floor();\n },\n display() {\n return {\n title: \"Exhancers\",\n description: `Adds ${format(\n thingEffect.value\n )} things and multiplies stuff by ${format(stuffEffect.value)}.`\n };\n },\n onPurchase(cost) {\n spentOnBuyables.value = Decimal.add(spentOnBuyables.value, cost ?? 0);\n },\n style: { height: \"222px\" },\n purchaseLimit: 4\n }));\n // The following need redundant ComputedRef<Decimal> type annotations because otherwise the ts\n // interpreter thinks exhancers are cyclically referenced\n const thingEffect: ComputedRef<Decimal> = computed(() => {\n if (Decimal.gte(exhancers.amount.value, 0)) {\n return Decimal.pow(25, Decimal.pow(exhancers.amount.value, 1.1));\n }\n return Decimal.pow(1 / 25, Decimal.times(exhancers.amount.value, -1).pow(1.1));\n });\n const stuffEffect: ComputedRef<Decimal> = computed(() => {\n if (Decimal.gte(exhancers.amount.value, 0)) {\n return Decimal.pow(25, Decimal.pow(exhancers.amount.value, 1.1));\n }\n return Decimal.pow(1 / 25, Decimal.times(exhancers.amount.value, -1).pow(1.1));\n });\n const confirmRespec = persistent<boolean>(false);\n const confirming = ref(false);\n const respecBuyables = createClickable(() => ({\n small: true,\n display: \"Respec Thingies\",\n onClick() {\n if (confirmRespec.value && !confirming.value) {\n confirming.value = true;\n return;\n }\n\n points.value = Decimal.add(points.value, spentOnBuyables.value);\n exhancers.amount.value = 0;\n main.tree.reset(treeNode);\n }\n }));\n const sellExhancer = createClickable(() => ({\n small: true,\n display: \"Sell One\",\n onClick() {\n if (Decimal.lte(exhancers.amount.value, 0)) {\n return;\n }\n exhancers.amount.value = Decimal.sub(exhancers.amount.value, 1);\n points.value = Decimal.add(points.value, exhancers.cost.value);\n spentOnBuyables.value = Decimal.sub(spentOnBuyables.value, exhancers.cost.value);\n }\n }));\n const buyablesDisplay = jsx(() => (\n <Column>\n <Row>\n <Toggle\n title=\"Confirm\"\n onUpdate:modelValue={value => (confirmRespec.value = value)}\n modelValue={confirmRespec.value}\n />\n {renderRow(respecBuyables)}\n </Row>\n {renderRow(exhancers)}\n {renderRow(sellExhancer)}\n <Modal\n modelValue={confirming.value}\n onUpdate:modelValue={value => (confirming.value = value)}\n v-slots={{\n header: () => <h2>Confirm Respec</h2>,\n body: () => <>Are you sure? Respeccing these doesn't accomplish much</>,\n footer: () => (\n <div class=\"modal-default-footer\">\n <div class=\"modal-default-flex-grow\"></div>\n <button\n class=\"button modal-default-button\"\n onClick={() => (confirming.value = false)}\n >\n Cancel\n </button>\n <button\n class=\"button modal-default-button danger\"\n onClick={() => {\n respecBuyables.onClick();\n confirming.value = false;\n }}\n >\n Respec\n </button>\n </div>\n )\n }}\n />\n </Column>\n ));\n\n const longBoi = createBar(() => ({\n fillStyle: { backgroundColor: \"#FFFFFF\" },\n baseStyle: { backgroundColor: \"#696969\" },\n textStyle: { color: \"#04e050\" },\n direction: Direction.Right,\n width: 300,\n height: 30,\n progress() {\n return Decimal.add(main.points.value, 1).log(10).div(10).toNumber();\n },\n display() {\n return format(main.points.value) + \" / 1e10 points\";\n }\n }));\n const tallBoi = createBar(() => ({\n fillStyle: { backgroundColor: \"#4BEC13\" },\n baseStyle: { backgroundColor: \"#000000\" },\n textStyle: { textShadow: \"0px 0px 2px #000000\" },\n borderStyle: { borderWidth: \"7px\" },\n direction: Direction.Up,\n width: 50,\n height: 200,\n progress() {\n return Decimal.div(main.points.value, 100);\n },\n display() {\n return formatWhole(Decimal.div(main.points.value, 1).min(100)) + \"%\";\n }\n }));\n const flatBoi = createBar(() => ({\n fillStyle: { backgroundColor: \"#FE0102\" },\n baseStyle: { backgroundColor: \"#222222\" },\n textStyle: { textShadow: \"0px 0px 2px #000000\" },\n direction: Direction.Up,\n width: 100,\n height: 30,\n progress() {\n return Decimal.div(points.value, 50);\n }\n }));\n\n const conversion = createCumulativeConversion(() => ({\n scaling: addSoftcap(createPolynomialScaling(10, 0.5), 1e100, 0.5),\n baseResource: main.points,\n gainResource: points,\n roundUpCost: true,\n gainModifier: createSequentialModifier(\n createExponentialModifier(2, \"Because I felt like it\"),\n createAdditiveModifier(1, \"Nice modifier\")\n )\n }));\n\n const reset = createReset(() => ({\n thingsToReset: (): Record<string, unknown>[] => [layer]\n }));\n\n const hotkeys = [\n createHotkey(() => ({\n key: \"c\",\n description: \"reset for lollipops or whatever\",\n onPress() {\n if (resetButton.canClick.value) {\n resetButton.onClick();\n }\n }\n })),\n createHotkey(() => ({\n key: \"ctrl+c\",\n description: \"respec things\",\n onPress() {\n respecBuyables.onClick();\n }\n }))\n ];\n\n const treeNode = createLayerTreeNode(() => ({\n layerID: id,\n color,\n reset,\n mark: \"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png\",\n tooltip() {\n let tooltip = displayResource(points);\n if (Decimal.gt(exhancers.amount.value, 0)) {\n tooltip += `<br><i><br><br><br>${formatWhole(\n exhancers.amount.value\n )} Exhancers</i>`;\n }\n return tooltip;\n },\n style: {\n color: \"#3325CC\",\n textDecoration: \"underline\"\n }\n }));\n addTooltip(treeNode, {\n display: createResourceTooltip(points),\n pinnable: true\n });\n\n const resetButton = createResetButton(() => ({\n conversion,\n tree: main.tree,\n treeNode,\n style: {\n color: \"#AA66AA\"\n },\n resetDescription: \"Melt your points into \"\n }));\n addTooltip(resetButton, {\n display: jsx(() =>\n createModifierSection(\n \"Modifiers\",\n \"\",\n conversion.gainModifier,\n conversion.scaling.currentGain(conversion)\n )\n ),\n pinnable: true,\n direction: Direction.Down,\n style: \"width: 400px; text-align: left\"\n });\n\n const g = createTreeNode(() => ({\n display: \"TH\",\n color: \"#6d3678\",\n canClick() {\n return Decimal.gte(main.points.value, 10);\n },\n tooltip: \"Thanos your points\",\n onClick() {\n main.points.value = Decimal.div(main.points.value, 2);\n console.log(\"Thanos'd\");\n },\n glowColor() {\n if (Decimal.eq(exhancers.amount.value, 1)) {\n return \"orange\";\n }\n return \"\";\n }\n }));\n const h = createTreeNode(() => ({\n display: \"h\",\n color() {\n return themes[settings.theme].variables[\"--locked\"];\n },\n tooltip: {\n display: computed(() => `Restore your points to ${format(otherThingy.value)}`),\n right: true\n },\n canClick() {\n return Decimal.lt(main.points.value, otherThingy.value);\n },\n onClick() {\n main.points.value = otherThingy.value;\n }\n }));\n const spook = createTreeNode(() => ({\n visibility: Visibility.Hidden\n }));\n const tree = createTree(() => ({\n nodes(): GenericTreeNode[][] {\n return [\n [f.treeNode, treeNode],\n [g, spook, h]\n ];\n },\n branches(): TreeBranch[] {\n return [\n {\n startNode: f.treeNode,\n endNode: treeNode,\n \"stroke-width\": \"25px\",\n stroke: \"green\",\n style: {\n filter: \"blur(5px)\"\n }\n },\n { startNode: treeNode, endNode: g },\n { startNode: g, endNode: h }\n ];\n }\n }));\n\n const links = createLinks(() => ({\n links: [\n {\n startNode: h,\n endNode: flatBoi,\n \"stroke-width\": \"5px\",\n stroke: \"red\",\n offsetEnd: { x: -50 + 100 * flatBoi.progress.value.toNumber(), y: 0 }\n }\n ]\n }));\n\n const illuminatiTabs = createTabFamily(\n {\n first: () => ({\n tab: jsx(() => (\n <>\n {renderRow(...upgrades)}\n {renderRow(quasiUpgrade)}\n <div>confirmed</div>\n </>\n )),\n display: \"first\"\n }),\n second: () => ({\n tab: f.display,\n display: \"second\"\n })\n },\n () => ({\n style: {\n width: \"660px\",\n backgroundColor: \"brown\",\n \"--background\": \"brown\",\n border: \"solid white\",\n marginLeft: \"auto\",\n marginRight: \"auto\"\n }\n })\n );\n\n const tabs = createTabFamily({\n mainTab: () => ({\n tab: createTab(() => ({\n display: jsx(() => (\n <>\n <MainDisplay\n resource={points}\n color={color}\n effectDisplay={`which are boosting waffles by ${format(\n waffleBoost.value\n )} and increasing the Ice Cream cap by ${format(icecreamCap.value)}`}\n />\n <Sticky>{render(resetButton)}</Sticky>\n <Resource resource={points} color={color} />\n <Spacer height=\"5px\" />\n <button onClick={() => console.log(\"yeet\")}>'HI'</button>\n <div>Name your points!</div>\n <Text\n modelValue={thingy.value}\n onUpdate:modelValue={value => (thingy.value = value)}\n />\n <Sticky style=\"color: red; font-size: 32px; font-family: Comic Sans MS;\">\n I have {displayResource(main.points)} {thingy.value} points!\n </Sticky>\n <hr />\n {renderCol(...lollipopMilestones)}\n <Spacer />\n {renderRow(...upgrades)}\n {renderRow(quasiUpgrade)}\n {renderRow(funChallenge)}\n </>\n ))\n })),\n display: \"main tab\",\n glowColor() {\n if (\n generatorUpgrade.canPurchase.value ||\n lollipopMultiplierUpgrade.canPurchase.value ||\n unlockIlluminatiUpgrade.canPurchase.value ||\n funChallenge.canComplete.value\n ) {\n return \"blue\";\n }\n return \"\";\n },\n style: { color: \"orange\" }\n }),\n thingies: () => ({\n tab: createTab(() => ({\n style() {\n return { backgroundColor: \"#222222\", \"--background\": \"#222222\" };\n },\n display: jsx(() => (\n <>\n {render(buyablesDisplay)}\n <Spacer />\n <Row style=\"width: 600px; height: 350px; background-color: green; border-style: solid;\">\n <Toggle\n onUpdate:modelValue={value => (beep.value = value)}\n modelValue={beep.value}\n />\n <Spacer width=\"30px\" height=\"10px\" />\n <div>\n <span>Beep</span>\n </div>\n <Spacer />\n <VerticalRule height=\"200px\" />\n </Row>\n <Spacer />\n <img src=\"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png\" />\n </>\n ))\n })),\n glowColor: \"white\",\n display: \"thingies\",\n style: { borderColor: \"orange\" }\n }),\n jail: () => ({\n tab: createTab(() => ({\n display: jsx(() => (\n <>\n {render(coolInfo)}\n {render(longBoi)}\n <Spacer />\n <Row>\n <Column style=\"background-color: #555555; padding: 15px\">\n <div style=\"color: teal\">Sugar level:</div>\n <Spacer />\n {render(tallBoi)}\n </Column>\n <Spacer />\n <Column>\n <div>idk</div>\n <Spacer width=\"0\" height=\"50px\" />\n {render(flatBoi)}\n </Column>\n </Row>\n <Spacer />\n <div>It's jail because \"bars\"! So funny! Ha ha!</div>\n {render(tree)}\n </>\n ))\n })),\n display: \"jail\"\n }),\n illuminati: () => ({\n tab: createTab(() => ({\n display: jsx(() => (\n // This should really just be <> and </>, however for some reason the\n // typescript interpreter can't figure out this layer and f.tsx otherwise\n <div>\n <h1> C O N F I R M E D </h1>\n <Spacer />\n {render(illuminatiTabs)}\n <div>Adjust how many points H gives you!</div>\n <Slider\n onUpdate:modelValue={value => (otherThingy.value = value)}\n modelValue={otherThingy.value}\n min={1}\n max={30}\n />\n </div>\n )),\n style: {\n backgroundColor: \"#3325CC\"\n }\n })),\n visibility() {\n return showIf(unlockIlluminatiUpgrade.bought.value);\n },\n display: \"illuminati\"\n })\n });\n\n return {\n id,\n color,\n name,\n points,\n best,\n beep,\n thingy,\n otherThingy,\n spentOnBuyables,\n waffleBoost,\n icecreamCap,\n coolInfo,\n lollipopMilestones,\n funChallenge,\n funEffect,\n generatorUpgrade,\n lollipopMultiplierUpgrade,\n lollipopMultiplierEffect,\n unlockIlluminatiUpgrade,\n quasiUpgrade,\n exhancers,\n respecBuyables,\n sellExhancer,\n bars: { tallBoi, longBoi, flatBoi },\n tree,\n g,\n h,\n spook,\n conversion,\n reset,\n hotkeys,\n treeNode,\n resetButton,\n confirmRespec,\n minWidth: 800,\n tabs,\n display: jsx(() => (\n <>\n {render(tabs)}\n {render(links)}\n </>\n ))\n };\n});\n\nexport default layer;\n","import Spacer from \"components/layout/Spacer.vue\";\nimport { createLayerTreeNode, createResetButton } from \"data/common\";\nimport { main } from \"data/projEntry\";\nimport { createClickable } from \"features/clickables/clickable\";\nimport { createPolynomialScaling, createIndependentConversion } from \"features/conversion\";\nimport { jsx } from \"features/feature\";\nimport { createInfobox } from \"features/infoboxes/infobox\";\nimport { createParticles } from \"features/particles/particles\";\nimport { createReset } from \"features/reset\";\nimport MainDisplay from \"features/resources/MainDisplay.vue\";\nimport { createResource, displayResource } from \"features/resources/resource\";\nimport { addTooltip } from \"features/tooltips/tooltip\";\nimport { createResourceTooltip } from \"features/trees/tree\";\nimport { createLayer } from \"game/layers\";\nimport { createMultiplicativeModifier } from \"game/modifiers\";\nimport { persistent } from \"game/persistence\";\nimport Decimal, { DecimalSource, formatWhole } from \"util/bignum\";\nimport { render, renderRow } from \"util/vue\";\nimport { ref } from \"vue\";\nimport c from \"./c\";\nimport confetti from \"./confetti.json\";\n\nconst id = \"f\";\nconst layer = createLayer(id, () => {\n const color = \"#FE0102\";\n const name = \"Farms\";\n const points = createResource<DecimalSource>(0, \"farm points\");\n const boop = persistent<boolean>(false);\n\n const coolInfo = createInfobox(() => ({\n title: \"Lore\",\n titleStyle: { color: \"#FE0000\" },\n display: \"DEEP LORE!\",\n bodyStyle: { backgroundColor: \"#0000EE\" }\n }));\n\n const clickableState = persistent<string>(\"Start\");\n const clickable = createClickable(() => ({\n display() {\n return {\n title: \"Clicky clicky!\",\n description: \"Current state:<br>\" + clickableState.value\n };\n },\n initialState: \"Start\",\n canClick() {\n return clickableState.value !== \"Borkened...\";\n },\n onClick(e) {\n switch (clickableState.value) {\n case \"Start\":\n clickableState.value = \"A new state!\";\n break;\n case \"A new state!\":\n clickableState.value = \"Keep going!\";\n break;\n case \"Keep going!\":\n clickableState.value = \"Maybe that's a bit too far...\";\n break;\n case \"Maybe that's a bit too far...\":\n const pos = e == undefined ? undefined : \"touches\" in e ? e.touches[0] : e;\n const confettiParticles = Object.assign({}, confetti, {\n pos: {\n x: (pos?.clientX ?? 0) - (particles.boundingRect?.value?.left ?? 0),\n y: (pos?.clientY ?? 0) - (particles.boundingRect?.value?.top ?? 0)\n }\n });\n particles.addEmitter(confettiParticles).then(e => e.playOnceAndDestroy());\n clickableState.value = \"Borkened...\";\n break;\n default:\n clickableState.value = \"Start\";\n break;\n }\n },\n onHold() {\n console.log(\"Clickkkkk...\");\n },\n style() {\n switch (clickableState.value) {\n case \"Start\":\n return { \"background-color\": \"green\" };\n case \"A new state!\":\n return { \"background-color\": \"yellow\" };\n case \"Keep going!\":\n return { \"background-color\": \"orange\" };\n case \"Maybe that's a bit too far...\":\n return { \"background-color\": \"red\" };\n default:\n return {};\n }\n }\n }));\n\n const resetClickable = createClickable(() => ({\n onClick() {\n if (clickableState.value == \"Borkened...\") {\n clickableState.value = \"Start\";\n }\n },\n display() {\n return clickableState.value == \"Borkened...\" ? \"Fix the clickable!\" : \"Does nothing\";\n },\n small: true\n }));\n\n const reset = createReset(() => ({\n thingsToReset: (): Record<string, unknown>[] => [layer]\n }));\n\n const conversion = createIndependentConversion(() => ({\n scaling: createPolynomialScaling(10, 0.5),\n baseResource: main.points,\n gainResource: points,\n modifyGainAmount: createMultiplicativeModifier(c.otherThingy)\n }));\n\n const treeNode = createLayerTreeNode(() => ({\n layerID: id,\n color,\n reset,\n tooltip() {\n if (treeNode.canClick.value) {\n return `${displayResource(points)} ${points.displayName}`;\n }\n return `This weird farmer dinosaur will only see you if you have at least 10 points. You only have ${displayResource(\n main.points\n )}`;\n },\n canClick() {\n return Decimal.gte(main.points.value, 10);\n }\n }));\n addTooltip(treeNode, {\n display: createResourceTooltip(points),\n pinnable: true\n });\n\n const resetButton = createResetButton(() => ({\n conversion,\n tree: main.tree,\n treeNode,\n display: jsx(() => {\n if (resetButton.conversion.buyMax) {\n return (\n <span>\n Hi! I'm a <u>weird dinosaur</u> and I'll give you{\" \"}\n <b>{formatWhole(resetButton.conversion.currentGain.value)}</b> Farm Points\n in exchange for all of your points and lollipops! (You'll get another one at{\" \"}\n {formatWhole(resetButton.conversion.nextAt.value)} points)\n </span>\n );\n } else {\n return (\n <span>\n Hi! I'm a <u>weird dinosaur</u> and I'll give you a Farm Point in exchange\n for all of your points and lollipops! (At least{\" \"}\n {formatWhole(resetButton.conversion.nextAt.value)} points)\n </span>\n );\n }\n })\n }));\n\n const particles = createParticles(() => ({\n boundingRect: ref<null | DOMRect>(null),\n onContainerResized(boundingRect) {\n this.boundingRect.value = boundingRect;\n },\n style: \"z-index: 2\"\n }));\n\n const tab = jsx(() => (\n <>\n {render(coolInfo)}\n <MainDisplay resource={points} color={color} />\n {render(resetButton)}\n <div>You have {formatWhole(conversion.baseResource.value)} points</div>\n <div>\n <br />\n <img src=\"https://images.beano.com/store/24ab3094eb95e5373bca1ccd6f330d4406db8d1f517fc4170b32e146f80d?auto=compress%2Cformat&dpr=1&w=390\" />\n <div>Bork Bork!</div>\n </div>\n <Spacer />\n {renderRow(resetClickable)}\n {renderRow(clickable)}\n {render(particles)}\n </>\n ));\n\n return {\n id,\n color,\n name,\n points,\n boop,\n coolInfo,\n clickable,\n clickableState,\n reset,\n conversion,\n treeNode,\n resetButton,\n minWidth: 650,\n display: tab\n };\n});\n\nexport default layer;\n","import Row from \"components/layout/Row.vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport { main } from \"data/projEntry\";\nimport { createAchievement } from \"features/achievements/achievement\";\nimport { jsx } from \"features/feature\";\nimport { createGrid } from \"features/grids/grid\";\nimport { createResource } from \"features/resources/resource\";\nimport { createTreeNode } from \"features/trees/tree\";\nimport { createLayer } from \"game/layers\";\nimport { DecimalSource } from \"lib/break_eternity\";\nimport Decimal from \"util/bignum\";\nimport { render, renderRow } from \"util/vue\";\nimport { computed } from \"vue\";\nimport f from \"./f\";\n\nconst id = \"a\";\nconst layer = createLayer(id, () => {\n const color = \"yellow\";\n const name = \"Achievements\";\n const points = createResource<DecimalSource>(0, \"achievement power\");\n\n const treeNode = createTreeNode(() => ({\n display: \"A\",\n color,\n tooltip: {\n display: \"Achievements\",\n right: true\n },\n onClick() {\n main.showAchievements();\n }\n }));\n\n const ach1 = createAchievement(() => ({\n image: \"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png\",\n display: \"Get me!\",\n tooltip: computed(() => {\n if (ach1.earned.value) {\n return \"You did it!\";\n }\n return \"How did this happen?\";\n }),\n shouldEarn: () => true\n }));\n const ach2 = createAchievement(() => ({\n display: \"Impossible!\",\n tooltip: computed(() => {\n if (ach2.earned.value) {\n return \"HOW????\";\n }\n return \"Mwahahaha!\";\n }),\n style: { color: \"#04e050\" }\n }));\n const ach3 = createAchievement(() => ({\n display: \"EIEIO\",\n tooltip:\n \"Get a farm point.\\n\\nReward: The dinosaur is now your friend (you can max Farm Points).\",\n shouldEarn: function () {\n return Decimal.gte(f.points.value, 1);\n },\n onComplete() {\n console.log(\"Bork bork bork!\");\n }\n }));\n const achievements = [ach1, ach2, ach3];\n\n const grid = createGrid(() => ({\n rows: 2,\n cols: 2,\n getStartState(id) {\n return id;\n },\n getStyle(id, state) {\n return { backgroundColor: `#${(Number(state) * 1234) % 999999}` };\n },\n // TODO display should return an object\n getTitle(id) {\n let direction = \"\";\n if (id === \"101\") {\n direction = \"top\";\n } else if (id === \"102\") {\n direction = \"bottom\";\n } else if (id === \"201\") {\n direction = \"left\";\n } else if (id === \"202\") {\n direction = \"right\";\n }\n return jsx(() => (\n <Tooltip display={JSON.stringify(this.cells[id].style)} {...{ [direction]: true }}>\n <h3>Gridable #{id}</h3>\n </Tooltip>\n ));\n },\n getDisplay(id, state) {\n return String(state);\n },\n getCanClick() {\n return Decimal.eq(main.points.value, 10);\n },\n onClick(id, state) {\n this.cells[id].state = Number(state) + 1;\n }\n }));\n\n const display = jsx(() => (\n <>\n <Row>\n <Tooltip display={ach1.tooltip} bottom>\n {render(ach1)}\n </Tooltip>\n <Tooltip display={ach2.tooltip} bottom>\n {render(ach2)}\n </Tooltip>\n <Tooltip display={ach3.tooltip} bottom>\n {render(ach3)}\n </Tooltip>\n </Row>\n {renderRow(grid)}\n </>\n ));\n\n return {\n id,\n color,\n name,\n points,\n achievements,\n grid,\n treeNode,\n display\n };\n});\n\nexport default layer;\n","import Profectus from \"components/Profectus.vue\";\nimport Spacer from \"components/layout/Spacer.vue\";\nimport { jsx } from \"features/feature\";\nimport { createResource, trackBest, trackOOMPS, trackTotal } from \"features/resources/resource\";\nimport { branchedResetPropagation, createTree, GenericTree } from \"features/trees/tree\";\nimport { globalBus } from \"game/events\";\nimport { createLayer, GenericLayer, setupLayerModal } from \"game/layers\";\nimport player, { PlayerData } from \"game/player\";\nimport Decimal, { DecimalSource, format, formatTime } from \"util/bignum\";\nimport { render } from \"util/vue\";\nimport { computed, toRaw } from \"vue\";\nimport a from \"./layers/aca/a\";\nimport c from \"./layers/aca/c\";\nimport f from \"./layers/aca/f\";\n\n/**\n * @hidden\n */\nexport const main = createLayer(\"main\", () => {\n const points = createResource<DecimalSource>(10);\n const best = trackBest(points);\n const total = trackTotal(points);\n\n const pointGain = computed(() => {\n if (!c.generatorUpgrade.bought.value) return new Decimal(0);\n let gain = new Decimal(3.19);\n if (c.lollipopMultiplierUpgrade.bought.value)\n gain = gain.times(c.lollipopMultiplierEffect.value);\n return gain;\n });\n globalBus.on(\"update\", diff => {\n points.value = Decimal.add(points.value, Decimal.times(pointGain.value, diff));\n });\n const oomps = trackOOMPS(points, pointGain);\n\n const { openModal, modal } = setupLayerModal(a);\n\n // Note: Casting as generic tree to avoid recursive type definitions\n const tree = createTree(() => ({\n nodes: [[c.treeNode], [f.treeNode, c.spook]],\n leftSideNodes: [a.treeNode, c.h],\n branches: [\n {\n startNode: f.treeNode,\n endNode: c.treeNode,\n stroke: \"blue\",\n \"stroke-width\": \"25px\",\n style: {\n filter: \"blur(5px)\"\n }\n }\n ],\n onReset() {\n points.value = toRaw(this.resettingNode.value) === toRaw(c.treeNode) ? 0 : 10;\n best.value = points.value;\n total.value = points.value;\n },\n resetPropagation: branchedResetPropagation\n })) as GenericTree;\n\n // Note: layers don't _need_ a reference to everything,\n // but I'd recommend it over trying to remember what does and doesn't need to be included.\n // Officially all you need are anything with persistency or that you want to access elsewhere\n return {\n name: \"Tree\",\n display: jsx(() => (\n <>\n {player.devSpeed === 0 ? <div>Game Paused</div> : null}\n {player.devSpeed && player.devSpeed !== 1 ? (\n <div>Dev Speed: {format(player.devSpeed)}x</div>\n ) : null}\n {player.offlineTime ? (\n <div>Offline Time: {formatTime(player.offlineTime)}</div>\n ) : null}\n <div>\n {Decimal.lt(points.value, \"1e1000\") ? <span>You have </span> : null}\n <h2>{format(points.value)}</h2>\n {Decimal.lt(points.value, \"1e1e6\") ? <span> points</span> : null}\n </div>\n {Decimal.gt(pointGain.value, 0) ? <div>({oomps.value})</div> : null}\n <Spacer />\n <button onClick={openModal}>open achievements</button>\n {render(modal)}\n {render(tree)}\n <Profectus height=\"200px\" style=\"margin: 10px auto; display: block\" />\n </>\n )),\n points,\n best,\n total,\n oomps,\n tree,\n showAchievements: openModal\n };\n});\n\nexport const getInitialLayers = (\n /* eslint-disable-next-line @typescript-eslint/no-unused-vars */\n player: Partial<PlayerData>\n): Array<GenericLayer> => [main, f, c, a];\n\nexport const hasWon = computed(() => {\n return Decimal.gt(main.points.value, 25);\n});\n\n/* eslint-disable @typescript-eslint/no-unused-vars */\nexport function fixOldSave(\n oldVersion: string | undefined,\n player: Partial<PlayerData>\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n): void {}\n/* eslint-enable @typescript-eslint/no-unused-vars */\n","import Modal from \"components/Modal.vue\";\nimport {\n CoercableComponent,\n OptionsFunc,\n jsx,\n JSXFunction,\n Replace,\n setDefault,\n StyleValue\n} from \"features/feature\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { createNanoEvents, Emitter } from \"nanoevents\";\nimport { InjectionKey, Ref, ref, shallowReactive, unref } from \"vue\";\nimport { globalBus } from \"./events\";\nimport { Persistent, persistent } from \"./persistence\";\nimport player from \"./player\";\n\nexport interface FeatureNode {\n rect: DOMRect;\n observer: MutationObserver;\n element: HTMLElement;\n}\n\nexport const RegisterNodeInjectionKey: InjectionKey<(id: string, element: HTMLElement) => void> =\n Symbol(\"RegisterNode\");\nexport const UnregisterNodeInjectionKey: InjectionKey<(id: string) => void> =\n Symbol(\"UnregisterNode\");\nexport const NodesInjectionKey: InjectionKey<Ref<Record<string, FeatureNode | undefined>>> =\n Symbol(\"Nodes\");\nexport const BoundsInjectionKey: InjectionKey<Ref<DOMRect | undefined>> = Symbol(\"Bounds\");\n\nexport interface LayerEvents {\n // Generation\n preUpdate: (diff: number) => void;\n // Actions (e.g. automation)\n update: (diff: number) => void;\n // Effects (e.g. milestones)\n postUpdate: (diff: number) => void;\n}\n\nexport const layers: Record<string, Readonly<GenericLayer> | undefined> = shallowReactive({});\nwindow.layers = layers;\n\ndeclare module \"@vue/runtime-dom\" {\n interface CSSProperties {\n \"--layer-color\"?: string;\n }\n}\n\nexport interface Position {\n x: number;\n y: number;\n}\n\nexport interface LayerOptions {\n color?: Computable<string>;\n display: Computable<CoercableComponent>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n name?: Computable<string>;\n minimizable?: Computable<boolean>;\n forceHideGoBack?: Computable<boolean>;\n minWidth?: Computable<number | string>;\n}\n\nexport interface BaseLayer {\n id: string;\n minimized: Persistent<boolean>;\n emitter: Emitter<LayerEvents>;\n on: OmitThisParameter<Emitter<LayerEvents>[\"on\"]>;\n emit: <K extends keyof LayerEvents>(event: K, ...args: Parameters<LayerEvents[K]>) => void;\n nodes: Ref<Record<string, FeatureNode | undefined>>;\n}\n\nexport type Layer<T extends LayerOptions> = Replace<\n T & BaseLayer,\n {\n color: GetComputableType<T[\"color\"]>;\n display: GetComputableType<T[\"display\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n name: GetComputableTypeWithDefault<T[\"name\"], string>;\n minWidth: GetComputableTypeWithDefault<T[\"minWidth\"], 600>;\n minimizable: GetComputableTypeWithDefault<T[\"minimizable\"], true>;\n forceHideGoBack: GetComputableType<T[\"forceHideGoBack\"]>;\n }\n>;\n\nexport type GenericLayer = Replace<\n Layer<LayerOptions>,\n {\n name: ProcessedComputable<string>;\n minWidth: ProcessedComputable<number>;\n minimizable: ProcessedComputable<boolean>;\n }\n>;\n\nexport const persistentRefs: Record<string, Set<Persistent>> = {};\nexport const addingLayers: string[] = [];\nexport function createLayer<T extends LayerOptions>(\n id: string,\n optionsFunc: OptionsFunc<T, BaseLayer, BaseLayer>\n): Layer<T> {\n return createLazyProxy(() => {\n const layer = {} as T & Partial<BaseLayer>;\n const emitter = (layer.emitter = createNanoEvents<LayerEvents>());\n layer.on = emitter.on.bind(emitter);\n layer.emit = emitter.emit.bind(emitter);\n layer.nodes = ref({});\n layer.id = id;\n\n addingLayers.push(id);\n persistentRefs[id] = new Set();\n layer.minimized = persistent(false);\n Object.assign(layer, optionsFunc.call(layer));\n if (\n addingLayers[addingLayers.length - 1] == null ||\n addingLayers[addingLayers.length - 1] !== id\n ) {\n throw `Adding layers stack in invalid state. This should not happen\\nStack: ${addingLayers}\\nTrying to pop ${layer.id}`;\n }\n addingLayers.pop();\n\n processComputable(layer as T, \"color\");\n processComputable(layer as T, \"display\");\n processComputable(layer as T, \"name\");\n setDefault(layer, \"name\", layer.id);\n processComputable(layer as T, \"minWidth\");\n setDefault(layer, \"minWidth\", 600);\n processComputable(layer as T, \"minimizable\");\n setDefault(layer, \"minimizable\", true);\n\n return layer as unknown as Layer<T>;\n });\n}\n\nexport function addLayer(\n layer: GenericLayer,\n player: { layers?: Record<string, Record<string, unknown>> }\n): void {\n console.info(\"Adding layer\", layer.id);\n if (layers[layer.id]) {\n console.error(\n \"Attempted to add layer with same ID as existing layer\",\n layer.id,\n layers[layer.id]\n );\n return;\n }\n\n setDefault(player, \"layers\", {});\n if (player.layers[layer.id] == null) {\n player.layers[layer.id] = {};\n }\n layers[layer.id] = layer;\n\n globalBus.emit(\"addLayer\", layer, player.layers[layer.id]);\n}\n\nexport function getLayer<T extends GenericLayer>(layerID: string): T {\n return layers[layerID] as T;\n}\n\nexport function removeLayer(layer: GenericLayer): void {\n console.info(\"Removing layer\", layer.id);\n globalBus.emit(\"removeLayer\", layer);\n\n layers[layer.id] = undefined;\n}\n\nexport function reloadLayer(layer: GenericLayer): void {\n removeLayer(layer);\n\n // Re-create layer\n addLayer(layer, player);\n}\n\nexport function setupLayerModal(layer: GenericLayer): {\n openModal: VoidFunction;\n modal: JSXFunction;\n} {\n const showModal = ref(false);\n return {\n openModal: () => (showModal.value = true),\n modal: jsx(() => (\n <Modal\n modelValue={showModal.value}\n onUpdate:modelValue={value => (showModal.value = value)}\n v-slots={{\n header: () => <h2>{unref(layer.name)}</h2>,\n body: unref(layer.display)\n }}\n />\n ))\n };\n}\n\nglobalBus.on(\"update\", function updateLayers(diff) {\n Object.values(layers).forEach(layer => {\n layer?.emit(\"preUpdate\", diff);\n });\n Object.values(layers).forEach(layer => {\n layer?.emit(\"update\", diff);\n });\n Object.values(layers).forEach(layer => {\n layer?.emit(\"postUpdate\", diff);\n });\n});\n","import Col from \"components/layout/Column.vue\";\nimport Row from \"components/layout/Row.vue\";\nimport {\n CoercableComponent,\n Component as ComponentKey,\n GatherProps,\n GenericComponent,\n jsx,\n JSXFunction,\n Visibility\n} from \"features/feature\";\nimport {\n Component,\n computed,\n ComputedRef,\n DefineComponent,\n defineComponent,\n isRef,\n onUnmounted,\n PropType,\n ref,\n Ref,\n ShallowRef,\n shallowRef,\n unref,\n watchEffect\n} from \"vue\";\nimport { DoNotCache, ProcessedComputable } from \"./computed\";\n\nexport function coerceComponent(\n component: CoercableComponent,\n defaultWrapper = \"span\"\n): DefineComponent {\n if (typeof component === \"function\") {\n return defineComponent({ render: component });\n }\n if (typeof component === \"string\") {\n if (component.length > 0) {\n component = component.trim();\n if (component.charAt(0) !== \"<\") {\n component = `<${defaultWrapper}>${component}</${defaultWrapper}>`;\n }\n\n return defineComponent({ template: component });\n }\n return defineComponent({ render: () => ({}) });\n }\n return component;\n}\n\nexport type VueFeature = {\n [ComponentKey]: GenericComponent;\n [GatherProps]: () => Record<string, unknown>;\n};\n\nexport function render(object: VueFeature | CoercableComponent): JSX.Element | DefineComponent {\n if (isCoercableComponent(object)) {\n if (typeof object === \"function\") {\n return (object as JSXFunction)();\n }\n return coerceComponent(object);\n }\n const Component = object[ComponentKey];\n return <Component {...object[GatherProps]()} />;\n}\n\nexport function renderRow(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Row>{objects.map(render)}</Row>;\n}\n\nexport function renderCol(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Col>{objects.map(render)}</Col>;\n}\n\nexport function renderJSX(object: VueFeature | CoercableComponent): JSX.Element {\n if (isCoercableComponent(object)) {\n if (typeof object === \"function\") {\n return (object as JSXFunction)();\n }\n if (typeof object === \"string\") {\n return <>{object}</>;\n }\n // TODO why is object typed as never?\n const Comp = object as DefineComponent;\n return <Comp />;\n }\n const Component = object[ComponentKey];\n return <Component {...object[GatherProps]()} />;\n}\n\nexport function renderRowJSX(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Row>{objects.map(renderJSX)}</Row>;\n}\n\nexport function renderColJSX(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Col>{objects.map(renderJSX)}</Col>;\n}\n\nexport function isCoercableComponent(component: unknown): component is CoercableComponent {\n if (typeof component === \"string\") {\n return true;\n } else if (typeof component === \"object\") {\n if (component == null) {\n return false;\n }\n return \"render\" in component || \"component\" in component;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n } else if (typeof component === \"function\" && (component as any)[DoNotCache] === true) {\n return true;\n }\n return false;\n}\n\nexport function setupHoldToClick(\n onClick?: Ref<((e?: MouseEvent | TouchEvent) => void) | undefined>,\n onHold?: Ref<VoidFunction | undefined>\n): {\n start: (e: MouseEvent | TouchEvent) => void;\n stop: VoidFunction;\n handleHolding: VoidFunction;\n} {\n const interval = ref<null | number>(null);\n const event = ref<MouseEvent | TouchEvent | undefined>(undefined);\n\n function start(e: MouseEvent | TouchEvent) {\n if (!interval.value) {\n interval.value = setInterval(handleHolding, 250);\n }\n event.value = e;\n }\n function stop() {\n if (interval.value) {\n clearInterval(interval.value);\n interval.value = null;\n }\n }\n function handleHolding() {\n if (onHold && onHold.value) {\n onHold.value();\n } else if (onClick && onClick.value) {\n onClick.value(event.value);\n }\n }\n\n onUnmounted(stop);\n\n return { start, stop, handleHolding };\n}\n\nexport function getFirstFeature<\n T extends VueFeature & { visibility: ProcessedComputable<Visibility> }\n>(\n features: T[],\n filter: (feature: T) => boolean\n): {\n firstFeature: Ref<T | undefined>;\n collapsedContent: JSXFunction;\n hasCollapsedContent: Ref<boolean>;\n} {\n const filteredFeatures = computed(() =>\n features.filter(\n feature => unref(feature.visibility) === Visibility.Visible && filter(feature)\n )\n );\n return {\n firstFeature: computed(() => filteredFeatures.value[0]),\n collapsedContent: jsx(() => renderCol(...filteredFeatures.value.slice(1))),\n hasCollapsedContent: computed(() => filteredFeatures.value.length > 1)\n };\n}\n\nexport function computeComponent(\n component: Ref<ProcessedComputable<CoercableComponent>>,\n defaultWrapper = \"div\"\n): ShallowRef<Component | \"\"> {\n const comp = shallowRef<Component | \"\">();\n watchEffect(() => {\n comp.value = coerceComponent(unwrapRef(component), defaultWrapper);\n });\n return comp as ShallowRef<Component | \"\">;\n}\nexport function computeOptionalComponent(\n component: Ref<ProcessedComputable<CoercableComponent | undefined> | undefined>,\n defaultWrapper = \"div\"\n): ShallowRef<Component | \"\" | null> {\n const comp = shallowRef<Component | \"\" | null>(null);\n watchEffect(() => {\n const currComponent = unwrapRef(component);\n comp.value = currComponent == null ? null : coerceComponent(currComponent, defaultWrapper);\n });\n return comp;\n}\n\nexport function wrapRef<T>(ref: Ref<ProcessedComputable<T>>): ComputedRef<T> {\n return computed(() => unwrapRef(ref));\n}\n\nexport function unwrapRef<T>(ref: Ref<ProcessedComputable<T>>): T {\n return unref<T>(unref(ref));\n}\n\nexport function setRefValue<T>(ref: Ref<T | Ref<T>>, value: T) {\n if (isRef(ref.value)) {\n ref.value.value = value;\n } else {\n ref.value = value;\n }\n}\n\nexport type PropTypes =\n | typeof Boolean\n | typeof String\n | typeof Number\n | typeof Function\n | typeof Object\n | typeof Array;\n// TODO Unfortunately, the typescript engine gives up on typing completely when you use this method,\n// Even though it has the same typing as when doing it manually\nexport function processedPropType<T>(...types: PropTypes[]): PropType<ProcessedComputable<T>> {\n if (!types.includes(Object)) {\n types.push(Object);\n }\n return types as PropType<ProcessedComputable<T>>;\n}\n","import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, createElementVNode as _createElementVNode, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport {\n RegisterNodeInjectionKey,\n UnregisterNodeInjectionKey,\n NodesInjectionKey,\n FeatureNode,\n BoundsInjectionKey\n} from \"game/layers\";\nimport { nextTick, onMounted, provide, ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n emits: [\"updateNodes\"],\n setup(__props, { emit }: { emit: ({\n (e: \"updateNodes\", nodes: Record<string, FeatureNode | undefined>): void;\n}), expose: any, slots: any, attrs: any }) {\n\n\n\nconst nodes = ref<Record<string, FeatureNode | undefined>>({});\n\nconst resizeObserver = new ResizeObserver(updateBounds);\nconst resizeListener = ref<Element | null>(null);\nonMounted(() => {\n // ResizeListener exists because ResizeObserver's don't work when told to observe an SVG element\n const resListener = resizeListener.value;\n if (resListener != null) {\n resizeObserver.observe(resListener);\n }\n});\nlet isDirty = true;\nlet boundingRect = ref(resizeListener.value?.getBoundingClientRect());\nfunction updateBounds() {\n if (resizeListener.value != null && isDirty) {\n isDirty = false;\n nextTick(() => {\n boundingRect.value = resizeListener.value?.getBoundingClientRect();\n (Object.values(nodes.value) as FeatureNode[])\n .filter(n => n) // Sometimes the values become undefined\n .forEach(node => (node.rect = node.element.getBoundingClientRect()));\n emit(\"updateNodes\", nodes.value);\n isDirty = true;\n });\n }\n}\ndocument.fonts.ready.then(updateBounds);\n\nconst observerOptions = {\n attributes: false,\n childList: true,\n subtree: false\n};\n\nprovide(RegisterNodeInjectionKey, (id, element) => {\n const observer = new MutationObserver(() => updateNode(id));\n observer.observe(element, observerOptions);\n nodes.value[id] = { element, observer, rect: element.getBoundingClientRect() };\n emit(\"updateNodes\", nodes.value);\n nextTick(() => updateNode(id));\n});\nprovide(UnregisterNodeInjectionKey, id => {\n nodes.value[id]?.observer.disconnect();\n nodes.value[id] = undefined;\n emit(\"updateNodes\", nodes.value);\n});\nprovide(NodesInjectionKey, nodes);\nprovide(BoundsInjectionKey, boundingRect);\n\nfunction updateNode(id: string) {\n const node = nodes.value[id];\n if (node == null) {\n return;\n }\n node.rect = node.element.getBoundingClientRect();\n emit(\"updateNodes\", nodes.value);\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n _renderSlot(_ctx.$slots, \"default\"),\n _createElementVNode(\"div\", {\n ref_key: \"resizeListener\",\n ref: resizeListener,\n class: \"resize-listener\"\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./Context.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Context.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Context.vue?vue&type=style&index=0&id=131e64e2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-131e64e2\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderSlot as _renderSlot, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, vShow as _vShow, withModifiers as _withModifiers, mergeProps as _mergeProps, withDirectives as _withDirectives, Transition as _Transition, Teleport as _Teleport, openBlock as _openBlock, createBlock as _createBlock } from \"vue\"\n\nconst _hoisted_1 = [\"onPointerdown\"]\nconst _hoisted_2 = { class: \"modal-wrapper\" }\nconst _hoisted_3 = { class: \"modal-container\" }\nconst _hoisted_4 = { class: \"modal-header\" }\nconst _hoisted_5 = /*#__PURE__*/_createTextVNode(\" default header \")\nconst _hoisted_6 = { class: \"modal-body\" }\nconst _hoisted_7 = /*#__PURE__*/_createTextVNode(\" default body \")\nconst _hoisted_8 = { class: \"modal-footer\" }\nconst _hoisted_9 = /*#__PURE__*/_createElementVNode(\"div\", { class: \"modal-default-flex-grow\" }, null, -1)\n\nimport { FeatureNode } from \"game/layers\";\nimport { computed, ref, toRefs } from \"vue\";\nimport Context from \"./Context.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n modelValue: { type: Boolean }\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { expose, emit }: { emit: ({\n (e: \"update:modelValue\", value: boolean): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n modelValue: boolean;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst isOpen = computed(() => props.modelValue || isAnimating.value);\nfunction close() {\n emit(\"update:modelValue\", false);\n}\n\nconst isAnimating = ref(false);\n\nconst contextRef = ref<typeof Context | null>(null);\nconst nodes = computed<Record<string, FeatureNode | undefined> | null>(\n () => contextRef.value?.nodes ?? null\n);\n\nexpose({ isOpen, nodes });\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(_Teleport, { to: \"#modal-root\" }, [\n _createVNode(_Transition, {\n name: \"modal\",\n onBeforeEnter: _cache[0] || (_cache[0] = ($event: any) => (isAnimating.value = true)),\n onAfterLeave: _cache[1] || (_cache[1] = ($event: any) => (isAnimating.value = false))\n }, {\n default: _withCtx(() => [\n _withDirectives(_createElementVNode(\"div\", _mergeProps({\n class: \"modal-mask\",\n onPointerdown: _withModifiers(close, [\"self\"])\n }, _ctx.$attrs), [\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n _createElementVNode(\"div\", _hoisted_4, [\n _renderSlot(_ctx.$slots, \"header\", { shown: _unref(isOpen) }, () => [\n _hoisted_5\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_6, [\n _createVNode(Context, {\n ref_key: \"contextRef\",\n ref: contextRef\n }, {\n default: _withCtx(() => [\n _renderSlot(_ctx.$slots, \"body\", { shown: _unref(isOpen) }, () => [\n _hoisted_7\n ])\n ]),\n _: 3\n }, 512)\n ]),\n _createElementVNode(\"div\", _hoisted_8, [\n _renderSlot(_ctx.$slots, \"footer\", { shown: _unref(isOpen) }, () => [\n _createElementVNode(\"div\", { class: \"modal-default-footer\" }, [\n _hoisted_9,\n _createElementVNode(\"button\", {\n class: \"button modal-default-button\",\n onClick: close\n }, \" Close \")\n ])\n ])\n ])\n ])\n ])\n ], 16, _hoisted_1), [\n [_vShow, __props.modelValue]\n ])\n ]),\n _: 3\n })\n ]))\n}\n}\n\n})","import script from \"./Modal.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Modal.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Modal.vue?vue&type=style&index=0&id=d02c1f40&lang=css\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createVNode as _createVNode } from \"vue\"\n\nconst _hoisted_1 = { class: \"field\" }\nconst _hoisted_2 = {\n key: 0,\n class: \"field-title\"\n}\n\nimport \"components/common/fields.css\";\nimport { CoercableComponent } from \"features/feature\";\nimport { computeOptionalComponent, unwrapRef } from \"util/vue\";\nimport { ref, toRef, watch } from \"vue\";\nimport VueNextSelect from \"vue-next-select\";\nimport \"vue-next-select/dist/index.css\";\n\nexport type SelectOption = { label: string; value: unknown };\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: null,\n options: null,\n placeholder: null,\n closeOnSelect: { type: Boolean }\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: unknown): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst props = __props as {\n title?: CoercableComponent;\n modelValue?: unknown;\n options: SelectOption[];\n placeholder?: string;\n closeOnSelect?: boolean;\n}\n\n\n\n\nconst titleComponent = computeOptionalComponent(toRef(props, \"title\"), \"span\");\n\nconst value = ref<SelectOption | null>(\n props.options.find(option => option.value === props.modelValue) ?? null\n);\nwatch(toRef(props, \"modelValue\"), modelValue => {\n if (unwrapRef(value) !== modelValue) {\n value.value = props.options.find(option => option.value === modelValue) ?? null;\n }\n});\n\nfunction onUpdate(value: SelectOption) {\n emit(\"update:modelValue\", value.value);\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (_unref(titleComponent))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(titleComponent))))\n ]))\n : _createCommentVNode(\"\", true),\n _createVNode(_unref(VueNextSelect), {\n options: __props.options,\n modelValue: value.value,\n \"onUpdate:modelValue\": [\n _cache[0] || (_cache[0] = ($event: any) => ((value).value = $event)),\n onUpdate\n ],\n min: 1,\n \"label-by\": \"label\",\n placeholder: __props.placeholder,\n \"close-on-select\": __props.closeOnSelect\n }, null, 8, [\"options\", \"modelValue\", \"placeholder\", \"close-on-select\"])\n ]))\n}\n}\n\n})","import script from \"./Select.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Select.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Select.vue?vue&type=style&index=0&id=4c379106&lang=css\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, isRef as _isRef, vModelText as _vModelText, normalizeClass as _normalizeClass, withDirectives as _withDirectives, createElementVNode as _createElementVNode, withModifiers as _withModifiers, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-8bda704a\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"onSubmit\"]\nconst _hoisted_2 = { class: \"field\" }\nconst _hoisted_3 = {\n key: 0,\n class: \"field-title\"\n}\nconst _hoisted_4 = [\"placeholder\"]\n\nimport { CoercableComponent } from \"features/feature\";\nimport { coerceComponent } from \"util/vue\";\nimport { computed, onMounted, ref, toRefs, unref } from \"vue\";\nimport VueTextareaAutosize from \"vue-textarea-autosize\";\nimport \"components/common/fields.css\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: null,\n textArea: { type: Boolean },\n placeholder: null,\n maxHeight: null\n },\n emits: [\"update:modelValue\", \"submit\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: string): void;\n (e: \"submit\"): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n title?: CoercableComponent;\n modelValue?: string;\n textArea?: boolean;\n placeholder?: string;\n maxHeight?: number;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst titleComponent = computed(\n () => props.title?.value && coerceComponent(unref(props.title.value), \"span\")\n);\n\nconst field = ref<HTMLElement | null>(null);\nonMounted(() => {\n field.value?.focus();\n});\n\nconst value = computed({\n get() {\n return unref(props.modelValue) || \"\";\n },\n set(value: string) {\n emit(\"update:modelValue\", value);\n }\n});\n\nfunction submit() {\n emit(\"submit\");\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"form\", {\n onSubmit: _withModifiers(submit, [\"prevent\"])\n }, [\n _createElementVNode(\"div\", _hoisted_2, [\n (_unref(titleComponent))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_3, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(titleComponent))))\n ]))\n : _createCommentVNode(\"\", true),\n (__props.textArea)\n ? (_openBlock(), _createBlock(_unref(VueTextareaAutosize), {\n key: 1,\n modelValue: _unref(value),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(value) ? (value).value = $event : null)),\n placeholder: __props.placeholder,\n maxHeight: __props.maxHeight,\n onBlur: submit,\n ref_key: \"field\",\n ref: field\n }, null, 8, [\"modelValue\", \"placeholder\", \"maxHeight\"]))\n : _withDirectives((_openBlock(), _createElementBlock(\"input\", {\n key: 2,\n type: \"text\",\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => (_isRef(value) ? (value).value = $event : null)),\n placeholder: __props.placeholder,\n class: _normalizeClass({ fullWidth: !__props.title }),\n onBlur: submit,\n ref_key: \"field\",\n ref: field\n }, null, 42, _hoisted_4)), [\n [_vModelText, _unref(value)]\n ])\n ])\n ], 40, _hoisted_1))\n}\n}\n\n})","import script from \"./Text.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Text.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Text.vue?vue&type=style&index=0&id=8bda704a&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-8bda704a\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, isRef as _isRef, vModelCheckbox as _vModelCheckbox, createElementVNode as _createElementVNode, withDirectives as _withDirectives, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-43cf95d0\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"field\" }\n\nimport { CoercableComponent } from \"features/feature\";\nimport { coerceComponent } from \"util/vue\";\nimport { computed, unref } from \"vue\";\nimport \"components/common/fields.css\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: { type: Boolean }\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: boolean): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst props = __props as {\n title?: CoercableComponent;\n modelValue?: boolean;\n}\n\n\n\n\nconst component = computed(() => coerceComponent(unref(props.title) || \"<span></span>\", \"span\"));\n\nconst value = computed({\n get() {\n return !!props.modelValue;\n },\n set(value: boolean) {\n emit(\"update:modelValue\", value);\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"label\", _hoisted_1, [\n _withDirectives(_createElementVNode(\"input\", {\n type: \"checkbox\",\n class: \"toggle\",\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(value) ? (value).value = $event : null))\n }, null, 512), [\n [_vModelCheckbox, _unref(value)]\n ]),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(component))))\n ]))\n}\n}\n\n})","import script from \"./Toggle.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Toggle.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Toggle.vue?vue&type=style&index=0&id=43cf95d0&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-43cf95d0\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderSlot as _renderSlot, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { class: \"table\" }\n\nimport \"components/common/table.css\";\nimport themes from \"data/themes\";\nimport settings from \"game/settings\";\nimport { computed } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst mergeAdjacent = computed(() => themes[settings.theme].mergeAdjacent);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"col\", { mergeAdjacent: _unref(mergeAdjacent) }])\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 2)\n ]))\n}\n}\n\n})","import script from \"./Column.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Column.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderSlot as _renderSlot, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { class: \"table\" }\n\nimport \"components/common/table.css\";\nimport themes from \"data/themes\";\nimport settings from \"game/settings\";\nimport { computed } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst mergeAdjacent = computed(() => themes[settings.theme].mergeAdjacent);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"row\", { mergeAdjacent: _unref(mergeAdjacent) }])\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 2)\n ]))\n}\n}\n\n})","import script from \"./Row.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Row.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { renderSlot as _renderSlot, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementBlock as _createElementBlock, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, Transition as _Transition, withCtx as _withCtx, createVNode as _createVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-e03bc918\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = {\n key: 0,\n class: \"material-icons pinned\"\n}\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"tooltip-container\", { shown: _ctx.isShown }]),\n onMouseenter: _cache[0] || (_cache[0] = ($event: any) => (_ctx.isHovered = true)),\n onMouseleave: _cache[1] || (_cache[1] = ($event: any) => (_ctx.isHovered = false)),\n onClickCapture: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.togglePinned && _ctx.togglePinned(...args)))\n }, [\n _renderSlot(_ctx.$slots, \"default\", {}, undefined, true),\n (_ctx.elementComp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.elementComp), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_Transition, { name: \"fade\" }, {\n default: _withCtx(() => [\n (_ctx.isShown)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: _normalizeClass([\"tooltip\", {\n top: _ctx.unref(_ctx.direction) === _ctx.Direction.Up,\n left: _ctx.unref(_ctx.direction) === _ctx.Direction.Left,\n right: _ctx.unref(_ctx.direction) === _ctx.Direction.Right,\n bottom: _ctx.unref(_ctx.direction) === _ctx.Direction.Down,\n ..._ctx.unref(_ctx.classes)\n }]),\n style: _normalizeStyle([\n {\n '--xoffset': _ctx.unref(_ctx.xoffset) || '0px',\n '--yoffset': _ctx.unref(_ctx.yoffset) || '0px'\n },\n _ctx.unref(_ctx.style) ?? {}\n ])\n }, [\n (_ctx.showPin)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \"push_pin\"))\n : _createCommentVNode(\"\", true),\n (_ctx.comp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.comp), { key: 1 }))\n : _createCommentVNode(\"\", true)\n ], 6))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n })\n ], 34))\n}","\nimport themes from \"data/themes\";\nimport { CoercableComponent, jsx, StyleValue } from \"features/feature\";\nimport { Persistent } from \"game/persistence\";\nimport settings from \"game/settings\";\nimport { Direction } from \"util/common\";\nimport {\n coerceComponent,\n computeOptionalComponent,\n processedPropType,\n render,\n unwrapRef,\n VueFeature\n} from \"util/vue\";\nimport {\n Component,\n computed,\n defineComponent,\n PropType,\n ref,\n shallowRef,\n toRefs,\n unref,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n element: processedPropType<VueFeature>(Object),\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n direction: processedPropType<Direction>(String),\n xoffset: processedPropType<string>(String),\n yoffset: processedPropType<string>(String),\n pinned: Object as PropType<Persistent<boolean>>\n },\n setup(props) {\n const { element, display, pinned } = toRefs(props);\n\n const isHovered = ref(false);\n const isShown = computed(() => (unwrapRef(pinned) || isHovered.value) && comp.value);\n const comp = computeOptionalComponent(display);\n\n const elementComp = shallowRef<Component | \"\" | null>(null);\n watchEffect(() => {\n const currComponent = unwrapRef(element);\n elementComp.value =\n currComponent == null\n ? null\n : coerceComponent(jsx(() => render(currComponent) as JSX.Element));\n });\n\n function togglePinned(e: MouseEvent) {\n const isPinned = pinned as unknown as Persistent<boolean> | undefined; // Vue typing :/\n if (e.shiftKey && isPinned) {\n isPinned.value = !isPinned.value;\n e.stopPropagation();\n e.preventDefault();\n }\n }\n\n const showPin = computed(() => unwrapRef(pinned) && themes[settings.theme].showPin);\n\n return {\n Direction,\n isHovered,\n isShown,\n comp,\n elementComp,\n unref,\n togglePinned,\n showPin\n };\n }\n});\n","import { render } from \"./Tooltip.vue?vue&type=template&id=e03bc918&scoped=true&ts=true\"\nimport script from \"./Tooltip.vue?vue&type=script&lang=ts\"\nexport * from \"./Tooltip.vue?vue&type=script&lang=ts\"\n\nimport \"./Tooltip.vue?vue&type=style&index=0&id=e03bc918&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e03bc918\"]])\n\nexport default __exports__","function webpackEmptyContext(req) {\n\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\te.code = 'MODULE_NOT_FOUND';\n\tthrow e;\n}\nwebpackEmptyContext.keys = function() { return []; };\nwebpackEmptyContext.resolve = webpackEmptyContext;\nwebpackEmptyContext.id = 7634;\nmodule.exports = webpackEmptyContext;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = function(result, chunkIds, fn, priority) {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every(function(key) { return __webpack_require__.O[key](chunkIds[j]); })) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = function(module) {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t143: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; };\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = function(parentChunkLoadingFunction, data) {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some(function(id) { return installedChunks[id] !== 0; })) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunkprofectus\"] = self[\"webpackChunkprofectus\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [998], function() { return __webpack_require__(7964); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["Themes","defaultTheme","variables","floatingTabs","mergeAdjacent","showPin","classic","paper","nordic","aqua","Visibility","Component","Symbol","GatherProps","id","getUniqueID","prefix","jsx","func","showIf","condition","otherwise","None","Visible","setDefault","object","key","value","undefined","findFeatures","obj","types","objects","handleObject","Object","keys","forEach","includes","type","push","isRef","globalBus","intervalID","hasWon","update","now","Date","diff","trueDiff","Math","max","offlineDiff","min","Number","isFinite","emit","requestAnimationFrame","clearInterval","setInterval","startGameLoop","watch","PersistentState","DefaultValue","StackTrace","Deleted","getStackTrace","Error","stack","split","slice","map","line","trim","join","persistent","defaultValue","ref","addingLayers","console","warn","persistentRefs","add","layer","saveData","features","path","foundPersistent","delete","persistentState","reduce","acc","curr","savedValue","isReactive","foundPersistentInChild","error","clear","state","reactive","devSpeed","name","tabs","time","autosave","offlineProd","offlineTime","timePlayed","keepGoing","modID","modVersion","layers","stringifySave","player","JSON","stringify","unref","playerHandler","get","target","Array","isArray","Proxy","set","property","receiver","isNaN","sign","mag","currentValue","ownKeys","Reflect","has","getOwnPropertyDescriptor","window","active","saves","showTPS","theme","unthrottled","loadSettings","item","localStorage","getItem","decodeURIComponent","escape","atob","settings","parse","assign","stringifiedSettings","setItem","deep","hardResetSettings","settingFields","registerSettingField","component","infoComponents","registerInfoComponent","gameComponents","shallowReactive","lastTenTicks","hasNaN","NaNPath","render","_ctx","_cache","$props","$setup","$data","$options","_component_Context","class","style","color","showGoBack","onClick","goBack","minimized","$event","onUpdateNodes","updateNodes","default","_","minimizable","defineComponent","components","Context","props","index","required","tab","Function","display","String","minWidth","Boolean","nodes","setup","toRefs","computed","projInfo","allowGoBack","Infinity","updateTab","width","parseInt","tabValue","flexGrow","flexShrink","flexBasis","margin","nextTick","__exports__","_withScopeId","n","_hoisted_1","_hoisted_2","open","__props","expose","isOpen","Modal","modelValue","header","body","_hoisted_3","_hoisted_4","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_hoisted_9","_hoisted_10","_hoisted_11","_hoisted_12","href","_hoisted_13","_hoisted_14","changelog","_props","title","logo","author","discordName","discordLink","versionNumber","versionTitle","infoComponent","openChangelog","src","alt","shown","themes","label","settingFieldsComponent","isPaused","offlineProdTitle","autosaveTitle","isPausedTitle","Select","options","Toggle","enablePausing","disabled","skipConfirm","emits","isConfirming","click","cancel","confirming","$slots","left","activated","activatedTimeout","clearTimeout","setTimeout","_hoisted_15","_hoisted_16","save","dateFormat","Intl","DateTimeFormat","year","month","day","hour","minute","second","isEditing","newName","isActive","currentTime","changeName","FeedbackButton","Tooltip","direction","Left","DangerButton","onConfirmingChanged","format","Text","onSubmit","modal","importingFailed","saveToImport","selectedPreset","importedSave","playerData","e","bankContext","bank","cachedSaves","getCachedSave","exportSave","saveToExport","exportEncoding","btoa","unescape","encodeURIComponent","el","document","createElement","appendChild","select","setSelectionRange","execCommand","removeChild","duplicateSave","deleteSave","removeItem","openSave","newFromPreset","preset","editSave","currSave","ref_key","list","handle","itemKey","element","Save","onOpen","onExport","onEditName","onDuplicate","onDelete","footer","placeholder","length","closeOnSelect","_hoisted_17","_hoisted_18","_hoisted_19","_hoisted_20","_hoisted_21","_hoisted_22","_hoisted_23","_hoisted_24","_hoisted_25","info","savesManager","useHeader","banner","openDiscord","$attrs","Down","yoffset","xoffset","Right","Info","SavesManager","Options","Changelog","toRef","layerKeys","gatherLayerProps","classes","ref_for","Nav","Layer","$refs","playAgain","previous","setZero","setOne","ignore","NaN","neq","tps","lastTenFPS","watchEffect","round","toNumber","low","showLow","gt","isNan","gameComponent","Game","TPS","GameOverScreen","NaNScreen","log","vue","createApp","App","mount","MAX_SIGNIFICANT_DIGITS","EXP_LIMIT","LAYER_DOWN","log10","FIRST_NEG_LAYER","NUMBER_EXP_MAX","NUMBER_EXP_MIN","MAX_ES_IN_A_ROW","IGNORE_COMMAS","COMMAS_ARE_DECIMAL_POINTS","powerOf10","powersOf10","i","for","indexOf0InPowersOf10","power","critical_headers","E","critical_tetr_values","critical_slog_values","D","Decimal","fromValue_noAlloc","FC","fromComponents","FC_NN","fromComponents_noNormalize","decimalPlaces","places","len","numDigits","ceil","abs","rounded","pow","parseFloat","toFixed","f_maglog10","f_gamma","trunc","NEGATIVE_INFINITY","scal1","l","n2","np","exp","OMEGA","f_lambertw","z","w","wn","tol","toString","d_lambertw","ew","wewz","dZero","dOne","ln","sub","mul","div","lt","this","fromDecimal","fromNumber","fromString","man","floor","residue","exponent","fromMantissaExponent","POSITIVE_INFINITY","m","other","times","neg","eq","gte","lte","absmag","signmag","normalize","mantissa","replace","pentationparts","heightparts","payload","result","pentate","tetrationparts","tetrate","base","height","powparts","toLowerCase","ptparts","parts","ecount","numberAttempt","newparts","charAt","layerstring","chrcode","charCodeAt","substr","me","repeat","toExponential","toStringWithDecimalPlaces","a","b","decimal","maxabs","cmpabs","layera","layerb","magdiff","newmag","recip","dNaN","cmp","tolerance","eq_tolerance","cmp_tolerance","magA","magB","neq_tolerance","log2","absLog10","pow10","gamma","t","lm","adj","l2","sqrt","this_num","negln","lambertw","iteratedlog","oldheight","fracheight","old_payload","next_payload","tetrate_critical","minus","plus","layeradd10","layeradd","fulltimes","fraction","layerloss","dNegOne","copy","slog_critical","slogthis","slog","slogdest","lnx","sin","cos","tan","asin","acos","atan","negate","sinh","cosh","sqr","ascensions","root","fromMantissaExponent_noNormalize","fromValue","reciprocate","notEquals","minabs","clamp","clampMin","clampMax","notEquals_tolerance","lt_tolerance","lte_tolerance","gt_tolerance","gte_tolerance","pLog10","logarithm","_other","factorial","lngamma","cube","cbrt","iteratedexp","ssqrt","resourcesAvailable","priceStart","priceRatio","currentOwned","affordGeometricSeries_core","numItems","sumGeometricSeries_core","priceAdd","affordArithmeticSeries_core","sumArithmeticSeries_core","cost","currentRpS","deltaRpS","efficiencyOfPurchase_core","maxLayers","random","randomsign","randomexp","randommag","actualStart","b2","critical_section","grid","lower","upper","basefrac","frac","MAX_VALUE","MIN_VALUE","decimalOne","exponentialFormat","num","precision","eString","defaultDecimalsShown","commaFormat","init","portions","regularFormat","eeee1000","e100000","e1000","e9","e6","e3","nearOne","thousandth","zero","small","defaultShowSmall","invertOOM","val","formatWhole","formatTime","seconds","toPlaces","x","maxAccepted","formatSmall","Direction","camelToTitle","camel","toUpperCase","isPlainObject","prototype","call","isFunction","DoNotCache","processComputable","computable","bind","convertComputable","ProxyState","ProxyPath","createLazyProxy","objectFunc","baseObject","calculated","calculateObj","setupInitialStore","stringifiedSave","load","loadSave","newSave","playerObj","removeLayer","addLayer","fixOldSave","getInitialLayers","onbeforeunload","hardReset","xmlns","viewBox","d","appear","script","createResource","displayName","resource","trackBest","best","amount","trackTotal","total","prevAmount","tetra8","e100","trackOOMPS","pointGain","oomps","oompsMag","lastPoints","prev","oompsString","displayResource","overrideAmount","_component_Links","nodesComp","leftNodesComp","rightNodesComp","branches","links","link","startNode","endNode","boundingRect","startPosition","rect","position","y","offsetStart","endPosition","offsetEnd","stroke","x1","y1","x2","y2","resizeListener","inject","NodesInjectionKey","outerBoundingRect","BoundsInjectionKey","getBoundingClientRect","validLinks","filter","Link","leftSideNodes","rightSideNodes","Links","shallowRef","currNodes","row","_component_MarkNode","_component_Node","visibility","Hidden","treeNode","can","canClick","onMousedown","start","onMouseleave","stop","onMouseup","onTouchstartPassive","onTouchendPassive","onTouchcancelPassive","backgroundColor","boxShadow","glowColor","comp","mark","register","RegisterNodeInjectionKey","unregister","UnregisterNodeInjectionKey","node","parentNode","parentElement","newNode","newID","prevNode","prevID","onUnmounted","onHold","MarkNode","Node","isCoercableComponent","TreeNodeType","TreeType","createTreeNode","optionsFunc","TreeNode","createTree","tree","Tree","isResetting","resettingNode","reset","genericTree","resetPropagation","onReset","branchedResetPropagation","visitedNodes","currentNodes","nextNodes","branch","createResourceTooltip","requiredResource","requirement","req","backgroundImage","earned","image","feature","achievement","locked","bought","getNotifyStyle","strength","transform","borderColor","zIndex","getHighNotifyStyle","use","toast","AchievementType","createAchievement","Achievement","complete","shouldEarn","genericAchievement","onComplete","Display","_component_GridCell","rows","cols","col","gatherCellProps","cells","tile","titleComponent","GridCell","cell","createGridProxy","getGridHandler","getCellHandler","configurable","enumerable","writable","cache","prop","getState","createGrid","cellState","Grid","getID","startState","setState","clickable","currDisplay","Title","Description","description","ClickableType","createClickable","Clickable","createResetButton","resetButton","resetDescription","conversion","gainResource","actualGain","minimumGain","buyMax","baseResource","nextAt","currentAt","showNextAt","convert","createLayerTreeNode","layerID","append","createConversion","currentGain","gain","gainModifier","apply","scaling","current","roundUpCost","next","createPolynomialScaling","processedBase","processedExponent","revert","createCumulativeConversion","createIndependentConversion","softcap","cap","addSoftcap","_component_CollapseTransition","collapsed","stacked","titleStyle","bodyComponent","bodyStyle","CollapseTransition","InfoboxType","createInfobox","infobox","Infobox","onInit","onContainerResized","onHotReload","app","resizeObserver","ResizeObserver","updateBounds","onMounted","resListener","observe","resizeTo","backgroundAlpha","view","onBeforeUnmount","destroy","isDirty","resize","fonts","ready","then","ParticlesType","createParticles","particles","Particles","addEmitter","config","genericParticles","Promise","resolve","stage","emittersToAdd","upgradeConfig","ResetType","createReset","values","thingsToReset","listeners","effectDisplay","effectComponent","showPrefix","Resource","addTooltip","pinnable","pinned","elementComponent","elementGratherProps","createAdditiveModifier","addend","enabled","processedAddend","processedDescription","processedEnabled","createMultiplicativeModifier","multiplier","processedMultiplier","createExponentialModifier","createSequentialModifier","modifiers","modifier","every","reduceRight","createModifierSection","subtitle","unit","baseText","fullWidth","top","observer","updateTop","newTop","previousSibling","sibling","dataset","offsetHeight","bar","borderStyle","textStyle","baseStyle","barStyle","fillStyle","progress","normalizedProgress","progressNumber","clipPath","BarType","createBar","Bar","BuyableType","createBuyable","buyable","canPurchase","canAfford","genericBuyable","purchaseLimit","maxed","currClasses","purchase","onPurchase","CurrDisplay","EffectDisplay","amountDisplay","notifyStyle","challenge","done","completed","canStart","toggle","buttonText","canComplete","currActive","currCanComplete","Goal","goal","Reward","reward","ChallengeType","createChallenge","completions","Challenge","completionLimit","genericChallenge","onExit","onEnter","remainInChallenge","currentReset","hotkeys","HotkeyType","createHotkey","hotkey","onkeydown","tagName","shiftKey","ctrlKey","preventDefault","onPress","LinksType","createLinks","milestone","Requirement","OptionsDisplay","optionsDisplay","MilestoneDisplay","MilestoneType","createMilestone","Milestone","All","Configurable","Incomplete","genericMilestone","msDisplayOptions","option","TabType","createTab","Tab","selectTab","glowColorStyle","floating","_component_TabButton","_component_Sticky","tabClasses","tabStyle","button","onSelectTab","selected","activeTab","gatherButtonProps","Sticky","TabButton","currActiveTab","TabButtonType","TabFamilyType","createTabFamily","tabFamily","TabFamily","parsedTabs","tabButton","processedTabFamily","firstTab","find","upgrade","currCost","UpgradeType","createUpgrade","Upgrade","genericUpgrade","createLayer","points","beep","thingy","otherThingy","spentOnBuyables","waffleBoost","icecreamCap","coolInfo","lollipopMilestone3","lollipopMilestone4","f","boop","lollipopMilestones","funChallenge","funEffect","main","generatorUpgrade","lollipopMultiplierUpgrade","lollipopMultiplierEffect","ret","unlockIlluminatiUpgrade","quasiUpgrade","exhancers","upgrades","thingEffect","stuffEffect","confirmRespec","respecBuyables","sellExhancer","buyablesDisplay","longBoi","tallBoi","textShadow","borderWidth","flatBoi","tooltip","textDecoration","g","h","right","spook","illuminatiTabs","first","border","marginLeft","marginRight","mainTab","thingies","jail","illuminati","bars","clickableState","initialState","pos","touches","confettiParticles","clientX","clientY","playOnceAndDestroy","resetClickable","modifyGainAmount","c","ach1","ach2","ach3","achievements","getStartState","getStyle","getTitle","getDisplay","getCanClick","setupLayerModal","openModal","toRaw","showAchievements","oldVersion","emitter","on","Set","pop","getLayer","reloadLayer","showModal","coerceComponent","defaultWrapper","template","renderRow","renderCol","renderJSX","Comp","setupHoldToClick","interval","event","handleHolding","computeComponent","unwrapRef","computeOptionalComponent","currComponent","wrapRef","processedPropType","observerOptions","attributes","childList","subtree","updateNode","provide","MutationObserver","disconnect","isAnimating","close","contextRef","to","onBeforeEnter","onAfterLeave","onPointerdown","onUpdate","textArea","maxHeight","field","focus","submit","onBlur","isShown","onMouseenter","isHovered","onClickCapture","togglePinned","elementComp","Up","bottom","isPinned","stopPropagation","webpackEmptyContext","code","module","exports","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","loaded","__webpack_modules__","deferred","O","chunkIds","fn","priority","notFulfilled","fulfilled","j","splice","r","getter","__esModule","definition","o","defineProperty","globalThis","hasOwnProperty","toStringTag","nmd","paths","children","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","data","moreModules","runtime","some","chunkLoadingGlobal","self","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/js/app.33420421.js b/js/app.33420421.js deleted file mode 100644 index 3a8e9ba..0000000 --- a/js/app.33420421.js +++ /dev/null @@ -1,2 +0,0 @@ -(function(){var e={1037:function(e,o,t){"use strict";t.d(o,{b:function(){return n}});const l={variables:{"--foreground":"#dfdfdf","--background":"#0f0f0f","--feature-foreground":"#0f0f0f","--tooltip-background":"rgba(0, 0, 0, 0.75)","--raised-background":"#0f0f0f","--points":"#ffffff","--locked":"#bf8f8f","--highlighted":"#333","--bought":"#77bf5f","--danger":"rgb(220, 53, 69)","--link":"#02f2f2","--outline":"#dfdfdf","--accent1":"#627a82","--accent2":"#658262","--accent3":"#7c6282","--border-radius":"15px","--modal-border":"solid 2px var(--color)","--feature-margin":"0px"},floatingTabs:!0,mergeAdjacent:!0,showPin:!0};var n;(function(e){e["Classic"]="classic",e["Paper"]="paper",e["Nordic"]="nordic",e["Aqua"]="aqua"})(n||(n={})),o["Z"]={classic:l,paper:{...l,variables:{...l.variables,"--background":"#2a323d","--feature-foreground":"#000","--raised-background":"#333c4a","--locked":"#3a3e45","--bought":"#5C8A58","--outline":"#333c4a","--border-radius":"4px","--modal-border":"","--feature-margin":"5px"},floatingTabs:!1},nordic:{...l,variables:{...l.variables,"--foreground":"#D8DEE9","--background":"#2E3440","--feature-foreground":"#000","--raised-background":"#3B4252","--points":"#E5E9F0","--locked":"#4c566a","--highlighted":"#434c5e","--bought":"#8FBCBB","--danger":"#D08770","--link":"#88C0D0","--outline":"#3B4252","--accent1":"#B48EAD","--accent2":"#A3BE8C","--accent3":"#EBCB8B","--border-radius":"4px","--modal-border":"solid 2px #3B4252","--feature-margin":"5px"},floatingTabs:!1},aqua:{...l,variables:{...l.variables,"--foreground":"#bfdfff","--background":"#001f3f","--tooltip-background":"rgba(0, 15, 31, 0.75)","--raised-background":"#001f3f","--points":"#dfefff","--locked":"#c4a7b3","--outline":"#bfdfff"}}}},6113:function(e,o,t){"use strict";t.d(o,{wA:function(){return i},tj:function(){return a},QI:function(){return u},EE:function(){return m},tZ:function(){return c},Kf:function(){return f},Rh:function(){return d},bD:function(){return y}});var l=t(5613),n=t(9583),r=t(4865);const i=Symbol("Component"),a=Symbol("GatherProps");let s=0;function u(e="feature-"){return(()=>void 0!==e&&null!==e&&e[Symbol.for("+")]?e[Symbol.for("+")](s++):e+s++)()}var m;function c(e){return e[n.mM]=!0,e}function f(e,o=m.None){return e?m.Visible:o}function d(e,o,t){void 0===e[o]&&(()=>void 0!==t&&null!==t&&t[Symbol.for("!=")]?t[Symbol.for("!=")](void 0):void 0!=t)()&&(e[o]=t)}function y(e,...o){const t=[],n=e=>{Object.keys(e).forEach((i=>{const a=e[i];a&&"object"===typeof a&&(o.includes(a.type)?t.push(a):(()=>a instanceof l.ZP!==void 0&&a instanceof l.ZP!==null&&(a instanceof l.ZP)[Symbol.for("!")]?(a instanceof l.ZP)[Symbol.for("!")]():!(a instanceof l.ZP))()&&(()=>void 0!==(0,r.isRef)(a)&&null!==(0,r.isRef)(a)&&(0,r.isRef)(a)[Symbol.for("!")]?(0,r.isRef)(a)[Symbol.for("!")]():!(0,r.isRef)(a))()&&n(a))}))};return n(e),t}(function(e){e[e["Visible"]=0]="Visible",e[e["Hidden"]=1]="Hidden",e[e["None"]=2]="None"})(m||(m={}))},7302:function(e,o,t){"use strict";t.r(o),t.d(o,{globalBus:function(){return m},startGameLoop:function(){return y}});var l=t(6453),n=t(5613),r=t(8111),i=t(4865),a=t(5967),s=t(9266),u=t(3032);const m=(0,r.i)();let c=null,f=null;function d(){const e=Date.now();let o=(()=>e-a.Z.time!==void 0&&e-a.Z.time!==null&&(e-a.Z.time)[Symbol.for("/")]?(e-a.Z.time)[Symbol.for("/")](1e3):(e-a.Z.time)/1e3)();a.Z.time=e;const t=o;if(u.Z.lastTenTicks.push(t),(()=>void 0!==u.Z.lastTenTicks.length&&null!==u.Z.lastTenTicks.length&&u.Z.lastTenTicks.length[Symbol.for(">")]?u.Z.lastTenTicks.length[Symbol.for(">")](10):u.Z.lastTenTicks.length>10)()&&(u.Z.lastTenTicks=u.Z.lastTenTicks.slice(1)),(!f?.value||!(()=>void 0!==a.Z.keepGoing&&null!==a.Z.keepGoing&&a.Z.keepGoing[Symbol.for("!")]?a.Z.keepGoing[Symbol.for("!")]():!a.Z.keepGoing)())&&!u.Z.hasNaN&&(o=Math.max(o,0),0!==a.Z.devSpeed)){if((()=>void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("!=")]?a.Z.offlineTime[Symbol.for("!=")](void 0):void 0!=a.Z.offlineTime)()){if(n.ZP.gt(a.Z.offlineTime,(()=>void 0!==l.offlineLimit&&null!==l.offlineLimit&&l.offlineLimit[Symbol.for("*")]?l.offlineLimit[Symbol.for("*")](3600):3600*l.offlineLimit)())&&(a.Z.offlineTime=(()=>void 0!==l.offlineLimit&&null!==l.offlineLimit&&l.offlineLimit[Symbol.for("*")]?l.offlineLimit[Symbol.for("*")](3600):3600*l.offlineLimit)()),n.ZP.gt(a.Z.offlineTime,0)&&(()=>void 0!==a.Z.devSpeed&&null!==a.Z.devSpeed&&a.Z.devSpeed[Symbol.for("!==")]?a.Z.devSpeed[Symbol.for("!==")](0):0!==a.Z.devSpeed)()){const e=Math.max((()=>void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("/")]?a.Z.offlineTime[Symbol.for("/")](10):a.Z.offlineTime/10)(),o);a.Z.offlineTime=(()=>void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("-")]?a.Z.offlineTime[Symbol.for("-")](e):a.Z.offlineTime-e)(),o=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](e):o+e)()}else 0===a.Z.devSpeed&&(a.Z.offlineTime=(()=>void 0!==a.Z.offlineTime&&null!==a.Z.offlineTime&&a.Z.offlineTime[Symbol.for("+")]?a.Z.offlineTime[Symbol.for("+")](o):a.Z.offlineTime+o)());((()=>void 0!==a.Z.offlineProd&&null!==a.Z.offlineProd&&a.Z.offlineProd[Symbol.for("!")]?a.Z.offlineProd[Symbol.for("!")]():!a.Z.offlineProd)()||n.ZP.lt(a.Z.offlineTime,0))&&(a.Z.offlineTime=null)}o=Math.min(o,l.maxTickLength),(()=>void 0!==a.Z.devSpeed&&null!==a.Z.devSpeed&&a.Z.devSpeed[Symbol.for("!=")]?a.Z.devSpeed[Symbol.for("!=")](void 0):void 0!=a.Z.devSpeed)()&&(o=(()=>void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](a.Z.devSpeed):o*a.Z.devSpeed)()),(()=>void 0!==Number.isFinite(o)&&null!==Number.isFinite(o)&&Number.isFinite(o)[Symbol.for("!")]?Number.isFinite(o)[Symbol.for("!")]():!Number.isFinite(o))()&&(o=1e308),n.ZP.eq(o,0)||(a.Z.timePlayed=(()=>void 0!==a.Z.timePlayed&&null!==a.Z.timePlayed&&a.Z.timePlayed[Symbol.for("+")]?a.Z.timePlayed[Symbol.for("+")](o):a.Z.timePlayed+o)(),(()=>void 0!==Number.isFinite(a.Z.timePlayed)&&null!==Number.isFinite(a.Z.timePlayed)&&Number.isFinite(a.Z.timePlayed)[Symbol.for("!")]?Number.isFinite(a.Z.timePlayed)[Symbol.for("!")]():!Number.isFinite(a.Z.timePlayed))()&&(a.Z.timePlayed=1e308),m.emit("update",o,t),s.ZP.unthrottled?(requestAnimationFrame(d),(()=>void 0!==c&&null!==c&&c[Symbol.for("!=")]?c[Symbol.for("!=")](null):null!=c)()&&(clearInterval(c),c=null)):(()=>void 0!==c&&null!==c&&c[Symbol.for("==")]?c[Symbol.for("==")](null):null==c)()&&(c=setInterval(d,50)))}}async function y(){f=(await Promise.resolve().then(t.bind(t,504))).hasWon,(0,i.watch)(f,(e=>{e&&m.emit("gameWon")})),s.ZP.unthrottled?requestAnimationFrame(d):c=setInterval(d,50)}},4061:function(e,o,t){"use strict";t.d(o,{n9:function(){return u},nY:function(){return m},ax:function(){return y}});t(1703);var l=t(7302),n=t(5613),r=t(3273),i=t(3577),a=t(4865),s=t(9365);const u=Symbol("PersistentState"),m=Symbol("DefaultValue"),c=Symbol("StackTrace"),f=Symbol("Deleted");function d(){return(new Error).stack?.split("\n").slice(3,5).map((e=>e.trim())).join("\n")||""}function y(e){const o=(0,a.isRef)(e)?e:(0,a.ref)(e);return o[u]=o,o[m]=(0,a.isRef)(e)?e.value:e,o[c]=d(),o[f]=!1,0===s.addingLayers.length?console.warn("Creating a persistent ref outside of a layer. This is not officially supported",o,(()=>"\nCreated at:\n"[Symbol.for("+")]?"\nCreated at:\n"[Symbol.for("+")](o[c]):"\nCreated at:\n"+o[c])()):s.persistentRefs[s.addingLayers[(()=>void 0!==s.addingLayers.length&&null!==s.addingLayers.length&&s.addingLayers.length[Symbol.for("-")]?s.addingLayers.length[Symbol.for("-")](1):s.addingLayers.length-1)()]].add(o),o}l.globalBus.on("addLayer",((e,o)=>{const t=[],l=(d,y=[])=>{let b=!1;return Object.keys(d).forEach((h=>{const p=d[h];if(p&&"object"===typeof p)if((()=>void 0!==u&&null!==u&&u[Symbol.for("in")]?u[Symbol.for("in")](p):u in p)()){if(b=!0,p[f])return void console.warn("Deleted persistent ref present in returned object. Ignoring...",p,(()=>"\nCreated at:\n"[Symbol.for("+")]?"\nCreated at:\n"[Symbol.for("+")](p[c]):"\nCreated at:\n"+p[c])());s.persistentRefs[e.id].delete((()=>void 0!==r.Le&&null!==r.Le&&r.Le[Symbol.for("in")]?r.Le[Symbol.for("in")](p):r.Le in p)()?p[r.Le]:p);const t=y.reduce(((e,o)=>((()=>o in e!==void 0&&o in e!==null&&(o in e)[Symbol.for("!")]?(o in e)[Symbol.for("!")]():!(o in e))()&&(e[o]={}),e[o])),o),l=t[h];t[h]=p[u],(0,a.isReactive)(t)?(()=>void 0!==l&&null!==l&&l[Symbol.for("!=")]?l[Symbol.for("!=")](null):null!=l)()?t[h]=l:t[h]=p[m]:(()=>void 0!==l&&null!==l&&l[Symbol.for("!=")]?l[Symbol.for("!=")](null):null!=l)()?t[h].value=l:t[h].value=p[m]}else if((()=>p instanceof n.ZP!==void 0&&p instanceof n.ZP!==null&&(p instanceof n.ZP)[Symbol.for("!")]?(p instanceof n.ZP)[Symbol.for("!")]():!(p instanceof n.ZP))()&&(()=>void 0!==(0,a.isRef)(p)&&null!==(0,a.isRef)(p)&&(0,a.isRef)(p)[Symbol.for("!")]?(0,a.isRef)(p)[Symbol.for("!")]():!(0,a.isRef)(p))()&&(()=>void 0!==t.includes(p)&&null!==t.includes(p)&&t.includes(p)[Symbol.for("!")]?t.includes(p)[Symbol.for("!")]():!t.includes(p))()){"symbol"===typeof p.type&&t.push(p);const e=l(p,[...y,h]);e&&((0,i.kJ)(p)&&(()=>void 0!==(0,i.kJ)(d)&&null!==(0,i.kJ)(d)&&(0,i.kJ)(d)[Symbol.for("!")]?(0,i.kJ)(d)[Symbol.for("!")]():!(0,i.kJ)(d))()?console.warn("Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.",(()=>void 0!==r.Le&&null!==r.Le&&r.Le[Symbol.for("in")]?r.Le[Symbol.for("in")](d):r.Le in d)()?d[r.Le]:d,h):b=!0)}})),b};l(e),s.persistentRefs[e.id].forEach((o=>{console.error(`Created persistent ref in ${e.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,o,(()=>"\nCreated at:\n"[Symbol.for("+")]?"\nCreated at:\n"[Symbol.for("+")](o[c]):"\nCreated at:\n"+o[c])())})),s.persistentRefs[e.id].clear()}))},5967:function(e,o,t){"use strict";t.d(o,{U:function(){return u}});var l=t(5613),n=t(1349),r=t(3273),i=t(4865),a=t(3032);const s=(0,i.reactive)({id:"",devSpeed:null,name:"",tabs:[],time:(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),autosave:!0,offlineProd:!0,offlineTime:null,timePlayed:0,keepGoing:!1,modID:"",modVersion:"",layers:{}});function u(e){return JSON.stringify(e,((e,o)=>(0,i.unref)(o)))}const m={get(e,o){if(o===r.Le||o===r.c4)return e[o];const t=e[r.Le][o];if((()=>void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")]("value"):"value"!==o)()&&((0,n.PO)(t)||Array.isArray(t))&&(()=>t instanceof l.ZP!==void 0&&t instanceof l.ZP!==null&&(t instanceof l.ZP)[Symbol.for("!")]?(t instanceof l.ZP)[Symbol.for("!")]():!(t instanceof l.ZP))()){if((()=>void 0!==t&&null!==t&&t[Symbol.for("!==")]?t[Symbol.for("!==")](e[o]?.[r.Le]):t!==e[o]?.[r.Le])()){const l=[...e[r.c4],o];e[o]=new Proxy({[r.Le]:t,[r.c4]:l},m)}return e[o]}return t},set(e,o,t,n){if((()=>void 0!==a.Z.hasNaN&&null!==a.Z.hasNaN&&a.Z.hasNaN[Symbol.for("!")]?a.Z.hasNaN[Symbol.for("!")]():!a.Z.hasNaN)()&&("number"===typeof t&&isNaN(t)||t instanceof l.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))){const t=e[r.Le][o];if((()=>void 0!==("number"===typeof t&&isNaN(t)||t instanceof l.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))&&null!==("number"===typeof t&&isNaN(t)||t instanceof l.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))&&("number"===typeof t&&isNaN(t)||t instanceof l.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))[Symbol.for("!")]?("number"===typeof t&&isNaN(t)||t instanceof l.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag)))[Symbol.for("!")]():!("number"===typeof t&&isNaN(t)||t instanceof l.ZP&&(isNaN(t.sign)||isNaN(t.layer)||isNaN(t.mag))))())throw s.autosave=!1,a.Z.hasNaN=!0,a.Z.NaNPath=[...e[r.c4],o],a.Z.NaNReceiver=n,console.error("Attempted to set NaN value",[...e[r.c4],o],e[r.Le]),"Attempted to set NaN value. See above for details"}return e[r.Le][o]=t,!0},ownKeys(e){return Reflect.ownKeys(e[r.Le])},has(e,o){return Reflect.has(e[r.Le],o)},getOwnPropertyDescriptor(e,o){return Object.getOwnPropertyDescriptor(e[r.Le],o)}};o["Z"]=window.player=new Proxy({[r.Le]:s,[r.c4]:["player"]},m)},9266:function(e,o,t){"use strict";t.d(o,{ri:function(){return c},V$:function(){return f},QV:function(){return d},II:function(){return y},fw:function(){return b},t:function(){return h}});t(2801);var l=t(6453),n=t(1037),r=t(7302),i=t(6961),a=t.n(i),s=t(463),u=t(4865);const m=(0,u.reactive)({active:"",saves:[],showTPS:!0,theme:n.b.Nordic,unthrottled:!1});function c(){try{let e=localStorage.getItem(l.id);if((()=>void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e)()&&(()=>void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](""):""!==e)()){if("{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])return void console.warn("Unable to determine settings encoding",e);e=a().decompressFromUTF16(e)}const o=JSON.parse(e);"object"===typeof o&&Object.assign(m,o)}r.globalBus.emit("loadSettings",m)}catch{}}(0,u.watch)(m,(e=>{const o=a().compressToUTF16(JSON.stringify(e));localStorage.setItem(l.id,o)}),{deep:!0}),o["ZP"]=window.settings=m;window.hardResetSettings=()=>{const e={active:"",saves:[],showTPS:!0,theme:n.b.Nordic};r.globalBus.emit("loadSettings",e),Object.assign(m,e),(0,s.y6)()};const f=(0,u.reactive)([]);function d(e){f.push(e)}const y=(0,u.reactive)([]);function b(e){y.push(e)}const h=(0,u.reactive)([])},3032:function(e,o,t){"use strict";var l=t(4865);o["Z"]=window.state=(0,l.shallowReactive)({lastTenTicks:[],hasNaN:!1,NaNPath:[]})},7964:function(e,o,t){"use strict";var l=t(4865),n=t(6113),r=t(1604),i=t(6453),a=t(9365),s=t(5967);function u(e,o,t,n,r,i){const a=(0,l.resolveComponent)("Context");return(0,l.openBlock)(),(0,l.createElementBlock)("div",{class:"layer-container",style:(0,l.normalizeStyle)({"--layer-color":e.unref(e.color)})},[e.showGoBack?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:0,class:"goBack",onClick:o[0]||(o[0]=(...o)=>e.goBack&&e.goBack(...o))},"←")):(0,l.createCommentVNode)("",!0),e.minimized.value?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:1,class:"layer-tab minimized",onClick:o[1]||(o[1]=o=>e.minimized.value=!1)},[(0,l.createElementVNode)("div",null,(0,l.toDisplayString)(e.unref(e.name)),1)])):((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:2,class:(0,l.normalizeClass)(["layer-tab",{showGoBack:e.showGoBack}])},[(0,l.createVNode)(a,{onUpdateNodes:e.updateNodes},{default:(0,l.withCtx)((()=>[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.component)))])),_:1},8,["onUpdateNodes"])],2)),e.unref(e.minimizable)?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:3,class:"minimize",onClick:o[2]||(o[2]=o=>e.minimized.value=!0)}," ▼ ")):(0,l.createCommentVNode)("",!0)],4)}var m=t(3363),c=(0,l.defineComponent)({components:{Context:m.Z},props:{index:{type:Number,required:!0},tab:{type:Function,required:!0},display:{type:(0,r.P5)(Object,String,Function),required:!0},minimized:{type:Object,required:!0},minWidth:{type:(0,r.P5)(Number,String),required:!0},name:{type:(0,r.P5)(String),required:!0},color:(0,r.P5)(String),minimizable:(0,r.P5)(Boolean),nodes:{type:Object,required:!0}},setup(e){const{display:o,index:t,minimized:n,minWidth:a,tab:u}=(0,l.toRefs)(e),m=(0,r.vq)(o),c=(0,l.computed)((()=>i.allowGoBack&&(()=>void 0!==t.value&&null!==t.value&&t.value[Symbol.for(">")]?t.value[Symbol.for(">")](0):t.value>0)()&&(()=>void 0!==n.value&&null!==n.value&&n.value[Symbol.for("!")]?n.value[Symbol.for("!")]():!n.value)()));function f(){s.Z.tabs.splice((0,l.unref)(e.index),1/0)}function d(o){e.nodes.value=o}function y(e,o){const t="number"===typeof o||Number.isNaN(parseInt(o))?(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")]("px"):o+"px")():o,l=u.value();(()=>void 0!==l&&null!==l&&l[Symbol.for("!=")]?l[Symbol.for("!=")](void 0):void 0!=l)()&&(e?(l.style.flexGrow="0",l.style.flexShrink="0",l.style.width="60px",l.style.minWidth=l.style.flexBasis="",l.style.margin="0"):(l.style.flexGrow="",l.style.flexShrink="",l.style.width="",l.style.minWidth=l.style.flexBasis=t,l.style.margin=""))}return(0,l.nextTick)((()=>y(n.value,(0,l.unref)(a.value)))),(0,l.watch)([n,(0,r.o9)(a)],(([e,o])=>y(e,o))),{component:m,showGoBack:c,updateNodes:d,unref:l.unref,goBack:f}}}),f=t(3744);const d=(0,f.Z)(c,[["render",u],["__scopeId","data-v-e18f60b6"]]);var y=d,b=t(6948);const h=e=>((0,l.pushScopeId)("data-v-5f8298e6"),e=e(),(0,l.popScopeId)(),e),p=h((()=>(0,l.createElementVNode)("h2",null,"Changelog",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),v=h((()=>(0,l.createElementVNode)("details",{open:""},[(0,l.createElementVNode)("summary",null,[(0,l.createTextVNode)("v0.0 Initial Commit - "),(0,l.createElementVNode)("time",null,"2021-09-04")]),(0,l.createTextVNode)(" This is the first release :D "),(0,l.createElementVNode)("ul",null,[(0,l.createElementVNode)("li",{class:"feature"},"Did everything"),(0,l.createElementVNode)("li",{class:"fix"},"Had some fun"),(0,l.createElementVNode)("li",{class:"breaking"},"Removed everything"),(0,l.createElementVNode)("li",{class:"balancing"},"Created some bugs to fix later")])],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var g=(0,l.defineComponent)({setup(e,{expose:o}){const t=(0,l.ref)(!1);return o({open(){t.value=!0}}),(e,o)=>((0,l.openBlock)(),(0,l.createBlock)(b.Z,{modelValue:t.value,"onUpdate:modelValue":o[0]||(o[0]=e=>t.value=e)},{header:(0,l.withCtx)((()=>[p])),body:(0,l.withCtx)((()=>[v])),_:1},8,["modelValue"]))}});const S=(0,f.Z)(g,[["__scopeId","data-v-5f8298e6"]]);var N=S,k=t(9266),V=t(5613);const x=e=>((0,l.pushScopeId)("data-v-3eb46986"),e=e(),(0,l.popScopeId)(),e),M={class:"info-modal-header"},C=["src","alt"],w={class:"info-modal-title"},Z={key:0},B={key:0},P={key:0},E=x((()=>(0,l.createElementVNode)("div",null," Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb ",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),F=x((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),T=x((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),D=["href"],I=x((()=>(0,l.createElementVNode)("span",{class:"material-icons info-modal-discord"},"discord",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),R=x((()=>(0,l.createElementVNode)("div",null,[(0,l.createElementVNode)("a",{href:"https://discord.gg/WzejVAx",class:"info-modal-discord-link"},[(0,l.createElementVNode)("span",{class:"material-icons info-modal-discord"},"discord"),(0,l.createTextVNode)(" The Paper Pilot Community ")])],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),_=x((()=>(0,l.createElementVNode)("div",null,[(0,l.createElementVNode)("a",{href:"https://discord.gg/F3xveHV",class:"info-modal-discord-link"},[(0,l.createElementVNode)("span",{class:"material-icons info-modal-discord"},"discord"),(0,l.createTextVNode)(" The Modding Tree ")])],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),O=x((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var U=(0,l.defineComponent)({props:{changelog:null},setup(e,{expose:o}){const t=e,{title:a,logo:u,author:m,discordName:c,discordLink:f,versionNumber:d,versionTitle:y}=i,h=(0,l.toRefs)(t),p=(0,l.ref)(!1),v=(0,l.computed)((()=>(0,V.mr)(s.Z.timePlayed))),g=(0,l.computed)((()=>(0,r.MM)((0,n.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[k.II.map(r.sY)]))))));function S(){(0,l.unref)(h.changelog)?.open()}return o({open(){p.value=!0}}),(e,o)=>((0,l.openBlock)(),(0,l.createBlock)(b.Z,{modelValue:p.value,"onUpdate:modelValue":o[0]||(o[0]=e=>p.value=e)},{header:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",M,[(0,l.unref)(u)?((0,l.openBlock)(),(0,l.createElementBlock)("img",{key:0,class:"info-modal-logo",src:(0,l.unref)(u),alt:(0,l.unref)(a)},null,8,C)):(0,l.createCommentVNode)("",!0),(0,l.createElementVNode)("div",w,[(0,l.createElementVNode)("h2",null,(0,l.toDisplayString)((0,l.unref)(a)),1),(0,l.createElementVNode)("h4",null,[(0,l.createTextVNode)((()=>" v"[Symbol.for("+")]?" v"[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(d))):" v"+(0,l.toDisplayString)((0,l.unref)(d)))(),1),(0,l.unref)(y)?((0,l.openBlock)(),(0,l.createElementBlock)("span",Z,(()=>": "[Symbol.for("+")]?": "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(y))):": "+(0,l.toDisplayString)((0,l.unref)(y)))(),1)):(0,l.createCommentVNode)("",!0)])])])])),body:(0,l.withCtx)((({shown:e})=>[e?((0,l.openBlock)(),(0,l.createElementBlock)("div",B,[(0,l.unref)(m)?((0,l.openBlock)(),(0,l.createElementBlock)("div",P,(()=>"By "[Symbol.for("+")]?"By "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(m))):"By "+(0,l.toDisplayString)((0,l.unref)(m)))(),1)):(0,l.createCommentVNode)("",!0),E,F,(0,l.createElementVNode)("div",{class:"link",onClick:S},"Changelog"),T,(0,l.createElementVNode)("div",null,[(()=>void 0!==(0,l.unref)(f)&&null!==(0,l.unref)(f)&&(0,l.unref)(f)[Symbol.for("!==")]?(0,l.unref)(f)[Symbol.for("!==")]("https://discord.gg/WzejVAx"):"https://discord.gg/WzejVAx"!==(0,l.unref)(f))()?((0,l.openBlock)(),(0,l.createElementBlock)("a",{key:0,href:(0,l.unref)(f),class:"info-modal-discord-link"},[I,(0,l.createTextVNode)((()=>" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(c))):" "+(0,l.toDisplayString)((0,l.unref)(c)))(),1)],8,D)):(0,l.createCommentVNode)("",!0)]),R,_,O,(0,l.createElementVNode)("div",null,(()=>"Time Played: "[Symbol.for("+")]?"Time Played: "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(v))):"Time Played: "+(0,l.toDisplayString)((0,l.unref)(v)))(),1),((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(g))))])):(0,l.createCommentVNode)("",!0)])),_:1},8,["modelValue"]))}});const j=(0,f.Z)(U,[["__scopeId","data-v-3eb46986"]]);var A=j,q=t(1037),z=t(1349),L=t(5418),G=t(9868),H=t(6055);const W=e=>((0,l.pushScopeId)("data-v-85d7ae40"),e=e(),(0,l.popScopeId)(),e),$=W((()=>(0,l.createElementVNode)("div",{class:"header"},[(0,l.createElementVNode)("h2",null,"Options")],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Y=W((()=>(0,l.createElementVNode)("hr",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var K=(0,l.defineComponent)({setup(e,{expose:o}){const t=(0,l.ref)(!1);o({open(){t.value=!0}});const a=Object.keys(q.Z).map((e=>({label:(0,z.IJ)(e),value:e}))),u=(0,l.computed)((()=>(0,r.MM)((0,n.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[k.V$.map(r.sY)])))))),{showTPS:m,theme:c,unthrottled:f}=(0,l.toRefs)(k.ZP),{autosave:d,offlineProd:y}=(0,l.toRefs)(s.Z),h=(0,l.computed)({get(){return 0===s.Z.devSpeed},set(e){s.Z.devSpeed=e?0:null}}),p=(0,n.tZ)((()=>(0,l.createVNode)("span",null,[(0,l.createTextVNode)("Offline Production"),(0,l.createVNode)(H.Z,{display:"Save-specific"},{default:()=>[(0,l.createTextVNode)("*")]})]))),v=(0,n.tZ)((()=>(0,l.createVNode)("span",null,[(0,l.createTextVNode)("Autosave"),(0,l.createVNode)(H.Z,{display:"Save-specific"},{default:()=>[(0,l.createTextVNode)("*")]})]))),g=(0,n.tZ)((()=>(0,l.createVNode)("span",null,[(0,l.createTextVNode)("Pause game"),(0,l.createVNode)(H.Z,{display:"Save-specific"},{default:()=>[(0,l.createTextVNode)("*")]})])));return(e,o)=>((0,l.openBlock)(),(0,l.createBlock)(b.Z,{modelValue:t.value,"onUpdate:modelValue":o[6]||(o[6]=e=>t.value=e)},{header:(0,l.withCtx)((()=>[$])),body:(0,l.withCtx)((()=>[(0,l.createVNode)(L.Z,{title:"Theme",options:(0,l.unref)(a),modelValue:(0,l.unref)(c),"onUpdate:modelValue":o[0]||(o[0]=e=>(0,l.isRef)(c)?c.value=e:null)},null,8,["options","modelValue"]),((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(u)))),(0,l.createVNode)(G.Z,{title:"Show TPS",modelValue:(0,l.unref)(m),"onUpdate:modelValue":o[1]||(o[1]=e=>(0,l.isRef)(m)?m.value=e:null)},null,8,["modelValue"]),Y,(0,l.createVNode)(G.Z,{title:"Unthrottled",modelValue:(0,l.unref)(f),"onUpdate:modelValue":o[2]||(o[2]=e=>(0,l.isRef)(f)?f.value=e:null)},null,8,["modelValue"]),(0,l.createVNode)(G.Z,{title:(0,l.unref)(p),modelValue:(0,l.unref)(y),"onUpdate:modelValue":o[3]||(o[3]=e=>(0,l.isRef)(y)?y.value=e:null)},null,8,["title","modelValue"]),(0,l.createVNode)(G.Z,{title:(0,l.unref)(v),modelValue:(0,l.unref)(d),"onUpdate:modelValue":o[4]||(o[4]=e=>(0,l.isRef)(d)?d.value=e:null)},null,8,["title","modelValue"]),(0,l.unref)(i).enablePausing?((0,l.openBlock)(),(0,l.createBlock)(G.Z,{key:0,title:(0,l.unref)(g),modelValue:(0,l.unref)(h),"onUpdate:modelValue":o[5]||(o[5]=e=>(0,l.isRef)(h)?h.value=e:null)},null,8,["title","modelValue"])):(0,l.createCommentVNode)("",!0)])),_:1},8,["modelValue"]))}});const Q=(0,f.Z)(K,[["__scopeId","data-v-85d7ae40"]]);var J=Q,X=(t(2801),t(463)),ee=t(4520);const oe={key:0},te=["onClick","disabled"],le={key:0},ne=["onClick"];var re=(0,l.defineComponent)({props:{disabled:{type:Boolean},skipConfirm:{type:Boolean}},emits:["click","confirmingChanged"],setup(e,{emit:o}){const t=e,n=(0,l.toRefs)(t),r=(0,l.ref)(!1);function i(){(0,l.unref)(n.skipConfirm)?o("click"):(r.value&&o("click"),r.value=(()=>void 0!==r.value&&null!==r.value&&r.value[Symbol.for("!")]?r.value[Symbol.for("!")]():!r.value)())}function a(){r.value=!1}return(0,l.watch)(r,(e=>{o("confirmingChanged",e)})),(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("span",{class:(0,l.normalizeClass)(["container",{confirming:r.value}])},[r.value?((0,l.openBlock)(),(0,l.createElementBlock)("span",oe,"Are you sure?")):(0,l.createCommentVNode)("",!0),(0,l.createElementVNode)("button",{onClick:(0,l.withModifiers)(i,["stop"]),class:"button danger",disabled:e.disabled},[r.value?((0,l.openBlock)(),(0,l.createElementBlock)("span",le,"Yes")):(0,l.renderSlot)(o.$slots,"default",{key:1})],8,te),r.value?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:1,class:"button",onClick:(0,l.withModifiers)(a,["stop"])},"No",8,ne)):(0,l.createCommentVNode)("",!0)],2))}});const ie=(0,f.Z)(re,[["__scopeId","data-v-bf59fca4"]]);var ae=ie;const se=["onClick"];var ue=(0,l.defineComponent)({props:{left:{type:Boolean}},emits:["click"],setup(e,{emit:o}){const t=(0,l.ref)(!1),n=(0,l.ref)(null);function r(){o("click"),n.value&&clearTimeout(n.value),t.value=!1,(0,l.nextTick)((()=>{t.value=!0,n.value=setTimeout((()=>t.value=!1),500)}))}return(o,n)=>((0,l.openBlock)(),(0,l.createElementBlock)("button",{onClick:(0,l.withModifiers)(r,["stop"]),class:(0,l.normalizeClass)(["feedback",{activated:t.value,left:e.left}])},[(0,l.renderSlot)(o.$slots,"default")],10,se))}});const me=(0,f.Z)(ue,[["__scopeId","data-v-5bbcedd3"]]);var ce=me;const fe=e=>((0,l.pushScopeId)("data-v-335ce270"),e=e(),(0,l.popScopeId)(),e),de=fe((()=>(0,l.createElementVNode)("div",{class:"handle material-icons"},"drag_handle",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),ye={key:0,class:"actions"},be=fe((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"content_paste",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),he=fe((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"content_copy",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),pe=fe((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"edit",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),ve=fe((()=>(0,l.createElementVNode)("span",{class:"material-icons",style:{margin:"-2px"}},"delete",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),ge={key:1,class:"actions"},Se=fe((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"check",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Ne=fe((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"close",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),ke={key:2,class:"details"},Ve={class:"save-version"},xe=fe((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Me={key:0},Ce={key:3,class:"details"},we={key:4,class:"details error"},Ze=fe((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var Be=(0,l.defineComponent)({props:{save:null},emits:["export","open","duplicate","delete","editName"],setup(e,{emit:o}){const t=e,{save:n}=(0,l.toRefs)(t),r=new Intl.DateTimeFormat("en-US",{year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),i=(0,l.ref)(!1),a=(0,l.ref)(!1),u=(0,l.ref)("");(0,l.watch)(i,(()=>u.value=n.value.name||""));const m=(0,l.computed)((()=>n.value&&n.value.id===s.Z.id)),c=(0,l.computed)((()=>m.value?s.Z.time:n.value&&n.value.time||0));function f(){o("editName",u.value),i.value=!1}return(e,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{class:(0,l.normalizeClass)(["save",{active:(0,l.unref)(m)}])},[de,(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!")]?i.value[Symbol.for("!")]():!i.value)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",ye,[(()=>void 0!==(0,l.unref)(n).error&&null!==(0,l.unref)(n).error&&(0,l.unref)(n).error[Symbol.for("==")]?(0,l.unref)(n).error[Symbol.for("==")](void 0):void 0==(0,l.unref)(n).error)()&&(()=>void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value)()?((0,l.openBlock)(),(0,l.createBlock)(ce,{key:0,onClick:t[0]||(t[0]=e=>o("export")),class:"button",left:""},{default:(0,l.withCtx)((()=>[(0,l.createVNode)(H.Z,{display:"Export",direction:(0,l.unref)(z.Nm).Left,class:"info"},{default:(0,l.withCtx)((()=>[be])),_:1},8,["direction"])])),_:1})):(0,l.createCommentVNode)("",!0),(()=>void 0!==(0,l.unref)(n).error&&null!==(0,l.unref)(n).error&&(0,l.unref)(n).error[Symbol.for("==")]?(0,l.unref)(n).error[Symbol.for("==")](void 0):void 0==(0,l.unref)(n).error)()&&(()=>void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value)()?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:1,onClick:t[1]||(t[1]=e=>o("duplicate")),class:"button"},[(0,l.createVNode)(H.Z,{display:"Duplicate",direction:(0,l.unref)(z.Nm).Left,class:"info"},{default:(0,l.withCtx)((()=>[he])),_:1},8,["direction"])])):(0,l.createCommentVNode)("",!0),(()=>void 0!==(0,l.unref)(n).error&&null!==(0,l.unref)(n).error&&(0,l.unref)(n).error[Symbol.for("==")]?(0,l.unref)(n).error[Symbol.for("==")](void 0):void 0==(0,l.unref)(n).error)()&&(()=>void 0!==a.value&&null!==a.value&&a.value[Symbol.for("!")]?a.value[Symbol.for("!")]():!a.value)()?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:2,onClick:t[2]||(t[2]=e=>i.value=(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!")]?i.value[Symbol.for("!")]():!i.value)()),class:"button"},[(0,l.createVNode)(H.Z,{display:"Edit Name",direction:(0,l.unref)(z.Nm).Left,class:"info"},{default:(0,l.withCtx)((()=>[pe])),_:1},8,["direction"])])):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(ae,{disabled:(0,l.unref)(m),onClick:t[3]||(t[3]=e=>o("delete")),onConfirmingChanged:t[4]||(t[4]=e=>a.value=e)},{default:(0,l.withCtx)((()=>[(0,l.createVNode)(H.Z,{display:"Delete",direction:(0,l.unref)(z.Nm).Left,class:"info"},{default:(0,l.withCtx)((()=>[ve])),_:1},8,["direction"])])),_:1},8,["disabled"])])):((0,l.openBlock)(),(0,l.createElementBlock)("div",ge,[(0,l.createElementVNode)("button",{onClick:f,class:"button"},[(0,l.createVNode)(H.Z,{display:"Save",direction:(0,l.unref)(z.Nm).Left,class:"info"},{default:(0,l.withCtx)((()=>[Se])),_:1},8,["direction"])]),(0,l.createElementVNode)("button",{onClick:t[5]||(t[5]=e=>i.value=(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!")]?i.value[Symbol.for("!")]():!i.value)()),class:"button"},[(0,l.createVNode)(H.Z,{display:"Cancel",direction:(0,l.unref)(z.Nm).Left,class:"info"},{default:(0,l.withCtx)((()=>[Ne])),_:1},8,["direction"])])])),(()=>void 0!==(0,l.unref)(n).error&&null!==(0,l.unref)(n).error&&(0,l.unref)(n).error[Symbol.for("==")]?(0,l.unref)(n).error[Symbol.for("==")](void 0):void 0==(0,l.unref)(n).error)()&&(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!")]?i.value[Symbol.for("!")]():!i.value)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",ke,[(0,l.createElementVNode)("button",{class:"button open",onClick:t[6]||(t[6]=e=>o("open"))},[(0,l.createElementVNode)("h3",null,(0,l.toDisplayString)((0,l.unref)(n).name),1)]),(0,l.createElementVNode)("span",Ve,(()=>"v"[Symbol.for("+")]?"v"[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(n).modVersion)):"v"+(0,l.toDisplayString)((0,l.unref)(n).modVersion))(),1),xe,(0,l.unref)(c)?((0,l.openBlock)(),(0,l.createElementBlock)("div",Me,(()=>"Last played "[Symbol.for("+")]?"Last played "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(r).format((0,l.unref)(c)))):"Last played "+(0,l.toDisplayString)((0,l.unref)(r).format((0,l.unref)(c))))(),1)):(0,l.createCommentVNode)("",!0)])):(()=>void 0!==(0,l.unref)(n).error&&null!==(0,l.unref)(n).error&&(0,l.unref)(n).error[Symbol.for("==")]?(0,l.unref)(n).error[Symbol.for("==")](void 0):void 0==(0,l.unref)(n).error)()&&i.value?((0,l.openBlock)(),(0,l.createElementBlock)("div",Ce,[(0,l.createVNode)(ee.Z,{modelValue:u.value,"onUpdate:modelValue":t[7]||(t[7]=e=>u.value=e),class:"editname",onSubmit:f},null,8,["modelValue"])])):((0,l.openBlock)(),(0,l.createElementBlock)("div",we,[(0,l.createTextVNode)((()=>" Error: Failed to load save with id "[Symbol.for("+")]?" Error: Failed to load save with id "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(n).id)):" Error: Failed to load save with id "+(0,l.toDisplayString)((0,l.unref)(n).id))(),1),Ze,(0,l.createTextVNode)((0,l.toDisplayString)((0,l.unref)(n).error),1)]))],2))}});const Pe=(0,f.Z)(Be,[["__scopeId","data-v-335ce270"]]);var Ee=Pe,Fe=t(9980),Te=t.n(Fe),De=t(6961),Ie=t.n(De),Re=t(3273);const _e=e=>((0,l.pushScopeId)("data-v-2bfdf896"),e=e(),(0,l.popScopeId)(),e),Oe=_e((()=>(0,l.createElementVNode)("h2",null,"Saves Manager",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Ue={class:"modal-footer"},je={class:"field"},Ae=_e((()=>(0,l.createElementVNode)("span",{class:"field-title"},"Create Save",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),qe={class:"field-buttons"},ze={class:"footer"},Le=_e((()=>(0,l.createElementVNode)("div",{style:{"flex-grow":"1"}},null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var Ge=(0,l.defineComponent)({setup(e,{expose:o}){const n=(0,l.ref)(!1),r=(0,l.ref)(null);o({open(){n.value=!0}});const a=(0,l.ref)(!1),u=(0,l.ref)(""),m=(0,l.ref)(null);(0,l.watch)(u,(e=>{e?(0,l.nextTick)((()=>{try{if("{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])return console.warn("Unable to determine preset encoding",e),void(a.value=!0);e=Ie().decompressFromUTF16(e)}const o=JSON.parse(e);if((()=>void 0!==typeof o&&null!==typeof o&&(typeof o)[Symbol.for("!==")]?(typeof o)[Symbol.for("!==")]("object"):"object"!==typeof o)())return void(a.value=!0);const t=(0,X.QI)();o.id=t,(0,X.a1)(o),u.value="",a.value=!1,k.ZP.saves.push(t)}catch(o){a.value=!0}})):a.value=!1}));let c=t(7634),f=(0,l.ref)(c.keys().reduce(((e,o)=>(e.push({label:o.slice(2,(()=>4[Symbol.for("minus")]?4[Symbol.for("minus")]():-4)()),value:c(o).default}),e)),[]));const d=(0,l.shallowReactive)({});function y(e){if((()=>void 0!==d[e]&&null!==d[e]&&d[e][Symbol.for("==")]?d[e][Symbol.for("==")](null):null==d[e])()){let t=localStorage.getItem(e);if((()=>void 0!==t&&null!==t&&t[Symbol.for("==")]?t[Symbol.for("==")](null):null==t)())d[e]={error:"Save doesn't exist in localStorage",id:e};else if("dW5kZWZpbmVk"===t)d[e]={error:"Save is undefined",id:e};else try{if("{"===t[0]);else if("e"===t[0])t=decodeURIComponent(escape(atob(t)));else{if("ᯡ"!==t[0])return console.warn("Unable to determine preset encoding",t),a.value=!0,d[e]={error:"Unable to determine preset encoding",id:e},d[e];t=Ie().decompressFromUTF16(t)}d[e]={...JSON.parse(t),id:e}}catch(o){d[e]={error:o,id:e},console.warn(`SavesManager: Failed to load info about save with id ${e}:\n${o}\n${t}`)}}return d[e]}(0,l.watch)(n,(e=>{e&&Object.keys(d).forEach((e=>(()=>void 0!==d&&null!==d&&d[Symbol.for("delete")]?d[Symbol.for("delete")]("key"):delete d.key)()))}));const h=(0,l.computed)((()=>k.ZP.saves.reduce(((e,o)=>(e[o]=y(o),e)),{})));function p(e){let o;switch(o=s.Z.id===e?(0,s.U)(s.Z[Re.Le]):JSON.stringify(h.value[e]),i.exportEncoding){default:console.warn(`Unknown save encoding: ${i.exportEncoding}. Defaulting to lz`);case"lz":o=Ie().compressToUTF16(o);break;case"base64":o=btoa(unescape(encodeURIComponent(o)));break;case"plain":break}const t=document.createElement("textarea");t.value=o,document.body.appendChild(t),t.select(),t.setSelectionRange(0,99999),document.execCommand("copy"),document.body.removeChild(t)}function v(e){s.Z.id===e&&(0,X.a1)();const o={...h.value[e],id:(0,X.QI)()};(0,X.a1)(o),k.ZP.saves.push(o.id)}function g(e){k.ZP.saves=k.ZP.saves.filter((o=>(()=>void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](e):o!==e)())),localStorage.removeItem(e),d[e]=void 0}function S(e){h.value[s.Z.id].time=s.Z.time,(0,X.a1)(),d[s.Z.id]=void 0,(0,X.uW)(h.value[e]),d[e]=void 0}function N(e){if(m.value=e,(0,l.nextTick)((()=>{m.value=null})),"{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])return void console.warn("Unable to determine preset encoding",e);e=Ie().decompressFromUTF16(e)}const o=JSON.parse(e);o.id=(0,X.QI)(),(0,X.a1)(o),k.ZP.saves.push(o.id),S(o.id)}function V(e,o){const t=h.value[e];t&&(t.name=o,s.Z.id===e?(s.Z.name=o,(0,X.a1)()):((0,X.a1)(t),d[e]=void 0))}return(e,o)=>((0,l.openBlock)(),(0,l.createBlock)(b.Z,{modelValue:n.value,"onUpdate:modelValue":o[4]||(o[4]=e=>n.value=e),ref_key:"modal",ref:r},{header:(0,l.withCtx)((()=>[Oe])),body:(0,l.withCtx)((({shown:e})=>[e?((0,l.openBlock)(),(0,l.createBlock)((0,l.unref)(Te()),{key:0,list:(0,l.unref)(k.ZP).saves,handle:".handle",itemKey:e=>e},{item:(0,l.withCtx)((({element:e})=>[(0,l.createVNode)(Ee,{save:(0,l.unref)(h)[e],onOpen:o=>S(e),onExport:o=>p(e),onEditName:o=>V(e,o),onDuplicate:o=>v(e),onDelete:o=>g(e)},null,8,["save","onOpen","onExport","onEditName","onDuplicate","onDelete"])])),_:1},8,["list","itemKey"])):(0,l.createCommentVNode)("",!0)])),footer:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",Ue,[(0,l.createVNode)(ee.Z,{modelValue:u.value,"onUpdate:modelValue":o[0]||(o[0]=e=>u.value=e),title:"Import Save",placeholder:"Paste your save here!",class:(0,l.normalizeClass)({importingFailed:a.value})},null,8,["modelValue","class"]),(0,l.createElementVNode)("div",je,[Ae,(0,l.createElementVNode)("div",qe,[(0,l.createElementVNode)("button",{class:"button",onClick:o[1]||(o[1]=e=>S((0,l.unref)(X.xM)().id))},"New Game"),(()=>void 0!==Object.keys((0,l.unref)(f)).length&&null!==Object.keys((0,l.unref)(f)).length&&Object.keys((0,l.unref)(f)).length[Symbol.for(">")]?Object.keys((0,l.unref)(f)).length[Symbol.for(">")](0):Object.keys((0,l.unref)(f)).length>0)()?((0,l.openBlock)(),(0,l.createBlock)(L.Z,{key:0,options:(0,l.unref)(f),modelValue:m.value,"onUpdate:modelValue":o[2]||(o[2]=e=>N(e)),closeOnSelect:"",placeholder:"Select preset",class:"presets"},null,8,["options","modelValue"])):(0,l.createCommentVNode)("",!0)])]),(0,l.createElementVNode)("div",ze,[Le,(0,l.createElementVNode)("button",{class:"button modal-default-button",onClick:o[3]||(o[3]=e=>n.value=!1)}," Close ")])])])),_:1},8,["modelValue"]))}});const He=(0,f.Z)(Ge,[["__scopeId","data-v-2bfdf896"]]);var We=He;const $e=e=>((0,l.pushScopeId)("data-v-53a1a91d"),e=e(),(0,l.popScopeId)(),e),Ye=["src","alt"],Ke={key:1,class:"title"},Qe=$e((()=>(0,l.createElementVNode)("div",{style:{"flex-grow":"1",cursor:"unset"}},null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Je={class:"discord"},Xe={class:"discord-links"},eo={key:0},oo=["href"],to=$e((()=>(0,l.createElementVNode)("li",null,[(0,l.createElementVNode)("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),lo=$e((()=>(0,l.createElementVNode)("li",null,[(0,l.createElementVNode)("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),no={href:"https://forums.moddingtree.com/",target:"_blank"},ro=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"forum",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),io=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"info",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),ao=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"library_books",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),so=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"settings",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),uo=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"library_books",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),mo=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"settings",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),co=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"info",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),fo={href:"https://forums.moddingtree.com/",target:"_blank"},yo=$e((()=>(0,l.createElementVNode)("span",{class:"material-icons"},"forum",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),bo={class:"discord"},ho={class:"discord-links"},po={key:0},vo=["href"],go=$e((()=>(0,l.createElementVNode)("li",null,[(0,l.createElementVNode)("a",{href:"https://discord.gg/WzejVAx",target:"_blank"},"The Paper Pilot Community")],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),So=$e((()=>(0,l.createElementVNode)("li",null,[(0,l.createElementVNode)("a",{href:"https://discord.gg/F3xveHV",target:"_blank"},"The Modding Tree")],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var No=(0,l.defineComponent)({setup(e){const o=(0,l.ref)(null),t=(0,l.ref)(null),n=(0,l.ref)(null),r=(0,l.ref)(null),{useHeader:a,banner:s,title:u,discordName:m,discordLink:c,versionNumber:f}=i;function d(){window.open(c,"mywindow")}return(e,i)=>((0,l.openBlock)(),(0,l.createElementBlock)(l.Fragment,null,[(0,l.unref)(a)?((0,l.openBlock)(),(0,l.createElementBlock)("div",(0,l.mergeProps)({key:0,class:"nav"},e.$attrs),[(0,l.unref)(s)?((0,l.openBlock)(),(0,l.createElementBlock)("img",{key:0,src:(0,l.unref)(s),class:"banner",alt:(0,l.unref)(u)},null,8,Ye)):((0,l.openBlock)(),(0,l.createElementBlock)("div",Ke,(0,l.toDisplayString)((0,l.unref)(u)),1)),(0,l.createElementVNode)("div",{onClick:i[0]||(i[0]=e=>r.value?.open()),class:"version-container"},[(0,l.createVNode)(H.Z,{display:"Changelog",direction:(0,l.unref)(z.Nm).Down,class:"version"},{default:(0,l.withCtx)((()=>[(0,l.createElementVNode)("span",null,(()=>"v"[Symbol.for("+")]?"v"[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(f))):"v"+(0,l.toDisplayString)((0,l.unref)(f)))(),1)])),_:1},8,["direction"])]),Qe,(0,l.createElementVNode)("div",Je,[(0,l.createElementVNode)("span",{onClick:d,class:"material-icons"},"discord"),(0,l.createElementVNode)("ul",Xe,[(()=>void 0!==(0,l.unref)(c)&&null!==(0,l.unref)(c)&&(0,l.unref)(c)[Symbol.for("!==")]?(0,l.unref)(c)[Symbol.for("!==")]("https://discord.gg/WzejVAx"):"https://discord.gg/WzejVAx"!==(0,l.unref)(c))()?((0,l.openBlock)(),(0,l.createElementBlock)("li",eo,[(0,l.createElementVNode)("a",{href:(0,l.unref)(c),target:"_blank"},(0,l.toDisplayString)((0,l.unref)(m)),9,oo)])):(0,l.createCommentVNode)("",!0),to,lo])]),(0,l.createElementVNode)("div",null,[(0,l.createElementVNode)("a",no,[(0,l.createVNode)(H.Z,{display:"Forums",direction:(0,l.unref)(z.Nm).Down,yoffset:"5px"},{default:(0,l.withCtx)((()=>[ro])),_:1},8,["direction"])])]),(0,l.createElementVNode)("div",{onClick:i[1]||(i[1]=e=>o.value?.open())},[(0,l.createVNode)(H.Z,{display:"Info",direction:(0,l.unref)(z.Nm).Down,class:"info"},{default:(0,l.withCtx)((()=>[io])),_:1},8,["direction"])]),(0,l.createElementVNode)("div",{onClick:i[2]||(i[2]=e=>t.value?.open())},[(0,l.createVNode)(H.Z,{display:"Saves",direction:(0,l.unref)(z.Nm).Down,xoffset:"-20px"},{default:(0,l.withCtx)((()=>[ao])),_:1},8,["direction"])]),(0,l.createElementVNode)("div",{onClick:i[3]||(i[3]=e=>n.value?.open())},[(0,l.createVNode)(H.Z,{display:"Options",direction:(0,l.unref)(z.Nm).Down,xoffset:"-66px"},{default:(0,l.withCtx)((()=>[so])),_:1},8,["direction"])])],16)):((0,l.openBlock)(),(0,l.createElementBlock)("div",(0,l.mergeProps)({key:1,class:"overlay-nav"},e.$attrs),[(0,l.createElementVNode)("div",{onClick:i[4]||(i[4]=e=>r.value?.open()),class:"version-container"},[(0,l.createVNode)(H.Z,{display:"Changelog",direction:(0,l.unref)(z.Nm).Right,xoffset:"25%",class:"version"},{default:(0,l.withCtx)((()=>[(0,l.createElementVNode)("span",null,(()=>"v"[Symbol.for("+")]?"v"[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(f))):"v"+(0,l.toDisplayString)((0,l.unref)(f)))(),1)])),_:1},8,["direction"])]),(0,l.createElementVNode)("div",{onClick:i[5]||(i[5]=e=>t.value?.open())},[(0,l.createVNode)(H.Z,{display:"Saves",direction:(0,l.unref)(z.Nm).Right},{default:(0,l.withCtx)((()=>[uo])),_:1},8,["direction"])]),(0,l.createElementVNode)("div",{onClick:i[6]||(i[6]=e=>n.value?.open())},[(0,l.createVNode)(H.Z,{display:"Options",direction:(0,l.unref)(z.Nm).Right},{default:(0,l.withCtx)((()=>[mo])),_:1},8,["direction"])]),(0,l.createElementVNode)("div",{onClick:i[7]||(i[7]=e=>o.value?.open())},[(0,l.createVNode)(H.Z,{display:"Info",direction:(0,l.unref)(z.Nm).Right},{default:(0,l.withCtx)((()=>[co])),_:1},8,["direction"])]),(0,l.createElementVNode)("div",null,[(0,l.createElementVNode)("a",fo,[(0,l.createVNode)(H.Z,{display:"Forums",direction:(0,l.unref)(z.Nm).Right,xoffset:"7px"},{default:(0,l.withCtx)((()=>[yo])),_:1},8,["direction"])])]),(0,l.createElementVNode)("div",bo,[(0,l.createElementVNode)("span",{onClick:d,class:"material-icons"},"discord"),(0,l.createElementVNode)("ul",ho,[(()=>void 0!==(0,l.unref)(c)&&null!==(0,l.unref)(c)&&(0,l.unref)(c)[Symbol.for("!==")]?(0,l.unref)(c)[Symbol.for("!==")]("https://discord.gg/WzejVAx"):"https://discord.gg/WzejVAx"!==(0,l.unref)(c))()?((0,l.openBlock)(),(0,l.createElementBlock)("li",po,[(0,l.createElementVNode)("a",{href:(0,l.unref)(c),target:"_blank"},(0,l.toDisplayString)((0,l.unref)(m)),9,vo)])):(0,l.createCommentVNode)("",!0),go,So])])],16)),(0,l.createVNode)(A,{ref_key:"info",ref:o,changelog:r.value},null,8,["changelog"]),(0,l.createVNode)(We,{ref_key:"savesManager",ref:t},null,512),(0,l.createVNode)(J,{ref_key:"options",ref:n},null,512),(0,l.createVNode)(N,{ref_key:"changelog",ref:r},null,512)],64))}});const ko=(0,f.Z)(No,[["__scopeId","data-v-53a1a91d"]]);var Vo=ko;const xo={class:"inner-tab"};var Mo=(0,l.defineComponent)({setup(e){const o=(0,l.toRef)(s.Z,"tabs"),t=(0,l.computed)((()=>Object.keys(a.layers))),n=i.useHeader;function r(e){const{display:o,minimized:t,minWidth:l,name:n,color:r,minimizable:i,nodes:a}=e;return{display:o,minimized:t,minWidth:l,name:n,color:r,minimizable:i,nodes:a}}return(e,i)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{class:(0,l.normalizeClass)(["tabs-container",{useHeader:(0,l.unref)(n)}])},[((0,l.openBlock)(!0),(0,l.createElementBlock)(l.Fragment,null,(0,l.renderList)((0,l.unref)(o),((o,i)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:i,class:(0,l.normalizeClass)(["tab",(0,l.unref)((0,l.unref)(a.layers)[o]?.classes)]),ref_for:!0,ref:`tab-${i}`,style:(0,l.normalizeStyle)((0,l.unref)((0,l.unref)(a.layers)[o]?.style))},[0===i&&(()=>void 0!==(0,l.unref)(n)&&null!==(0,l.unref)(n)&&(0,l.unref)(n)[Symbol.for("!")]?(0,l.unref)(n)[Symbol.for("!")]():!(0,l.unref)(n))()?((0,l.openBlock)(),(0,l.createBlock)(Vo,{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createElementVNode)("div",xo,[(0,l.unref)(t).includes(o)?((0,l.openBlock)(),(0,l.createBlock)(y,(0,l.mergeProps)({key:0},r((0,l.unref)(a.layers)[o]),{index:i,tab:()=>e.$refs[`tab-${i}`]?.[0]}),null,16,["index","tab"])):((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(o),{key:1,index:i},null,8,["index"]))])],6)))),128))],2))}});const Co=(0,f.Z)(Mo,[["__scopeId","data-v-7e494d3c"]]);var wo=Co,Zo=t(504);const Bo=e=>((0,l.pushScopeId)("data-v-06188cc8"),e=e(),(0,l.popScopeId)(),e),Po={class:"game-over-modal-header"},Eo=["src","alt"],Fo={class:"game-over-modal-title"},To=Bo((()=>(0,l.createElementVNode)("h2",null,"Congratulations!",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Do={key:0},Io=Bo((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Ro=Bo((()=>(0,l.createElementVNode)("div",null," Please check the Discord to discuss the game or to check for new content updates! ",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),_o=Bo((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Oo=["href"],Uo=Bo((()=>(0,l.createElementVNode)("span",{class:"material-icons game-over-modal-discord"},"discord",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));var jo=(0,l.defineComponent)({setup(e){const{title:o,logo:t,discordName:n,discordLink:r,versionNumber:a,versionTitle:u}=i,m=(0,l.computed)((()=>(0,V.mr)(s.Z.timePlayed))),c=(0,l.computed)((()=>Zo.hasWon.value&&(()=>void 0!==s.Z.keepGoing&&null!==s.Z.keepGoing&&s.Z.keepGoing[Symbol.for("!")]?s.Z.keepGoing[Symbol.for("!")]():!s.Z.keepGoing)())),f=(0,l.toRef)(s.Z,"autosave");function d(){s.Z.keepGoing=!0}function y(){(0,X.uW)((0,X.xM)())}return(e,i)=>((0,l.openBlock)(),(0,l.createBlock)(b.Z,{"model-value":(0,l.unref)(c)},{header:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",Po,[(0,l.unref)(t)?((0,l.openBlock)(),(0,l.createElementBlock)("img",{key:0,class:"game-over-modal-logo",src:(0,l.unref)(t),alt:(0,l.unref)(o)},null,8,Eo)):(0,l.createCommentVNode)("",!0),(0,l.createElementVNode)("div",Fo,[To,(0,l.createElementVNode)("h4",null,(()=>"You've beaten "+(0,l.toDisplayString)((0,l.unref)(o))+" v"+(0,l.toDisplayString)((0,l.unref)(a))+": "!==void 0&&"You've beaten "+(0,l.toDisplayString)((0,l.unref)(o))+" v"+(0,l.toDisplayString)((0,l.unref)(a))+": "!==null&&("You've beaten "+(0,l.toDisplayString)((0,l.unref)(o))+" v"+(0,l.toDisplayString)((0,l.unref)(a))+": ")[Symbol.for("+")]?("You've beaten "+(0,l.toDisplayString)((0,l.unref)(o))+" v"+(0,l.toDisplayString)((0,l.unref)(a))+": ")[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(u))):"You've beaten "+(0,l.toDisplayString)((0,l.unref)(o))+" v"+(0,l.toDisplayString)((0,l.unref)(a))+": "+(0,l.toDisplayString)((0,l.unref)(u)))(),1)])])])),body:(0,l.withCtx)((({shown:e})=>[e?((0,l.openBlock)(),(0,l.createElementBlock)("div",Do,[(0,l.createElementVNode)("div",null,(()=>"It took you "+(0,l.toDisplayString)((0,l.unref)(m))!==void 0&&"It took you "+(0,l.toDisplayString)((0,l.unref)(m))!==null&&("It took you "+(0,l.toDisplayString)((0,l.unref)(m)))[Symbol.for("+")]?("It took you "+(0,l.toDisplayString)((0,l.unref)(m)))[Symbol.for("+")](" to beat the game."):"It took you "+(0,l.toDisplayString)((0,l.unref)(m))+" to beat the game.")(),1),Io,Ro,_o,(0,l.createElementVNode)("div",null,[(0,l.createElementVNode)("a",{href:(0,l.unref)(r),class:"game-over-modal-discord-link"},[Uo,(0,l.createTextVNode)((()=>" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(n))):" "+(0,l.toDisplayString)((0,l.unref)(n)))(),1)],8,Oo)]),(0,l.createVNode)(G.Z,{title:"Autosave",modelValue:(0,l.unref)(f),"onUpdate:modelValue":i[0]||(i[0]=e=>(0,l.isRef)(f)?f.value=e:null)},null,8,["modelValue"])])):(0,l.createCommentVNode)("",!0)])),footer:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",{class:"game-over-footer"},[(0,l.createElementVNode)("button",{onClick:d,class:"button"},"Keep Going"),(0,l.createElementVNode)("button",{onClick:y,class:"button danger"},"Play Again")])])),_:1},8,["model-value"]))}});const Ao=(0,f.Z)(jo,[["__scopeId","data-v-06188cc8"]]);var qo=Ao,zo=t(3032);const Lo=e=>((0,l.pushScopeId)("data-v-5935214c"),e=e(),(0,l.popScopeId)(),e),Go=Lo((()=>(0,l.createElementVNode)("div",{class:"nan-modal-header"},[(0,l.createElementVNode)("h2",null,"NaN value detected!")],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Ho={key:0},Wo=Lo((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),$o=["href"],Yo=Lo((()=>(0,l.createElementVNode)("span",{class:"material-icons nan-modal-discord"},"discord",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Ko=Lo((()=>(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))),Qo={class:"nan-footer"};var Jo=(0,l.defineComponent)({setup(e){const{discordName:o,discordLink:t}=i,n=(0,l.toRef)(s.Z,"autosave"),r=(0,l.toRef)(zo.Z,"hasNaN"),a=(0,l.ref)(null),u=(0,l.computed)((()=>zo.Z.NaNPath.join("."))),m=(0,l.computed)((()=>zo.Z.NaNPath.slice((()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())[0])),c=(0,l.computed)((()=>zo.Z.NaNReceiver&&m.value?zo.Z.NaNReceiver[m.value]:null)),f=(0,l.computed)({get(){return 0===s.Z.devSpeed},set(e){s.Z.devSpeed=e?null:0}});function d(){zo.Z.NaNReceiver&&m.value&&(zo.Z.NaNReceiver[m.value]=new V.ZP(0),zo.Z.hasNaN=!1)}function y(){zo.Z.NaNReceiver&&m.value&&(zo.Z.NaNReceiver[m.value]=new V.ZP(1),zo.Z.hasNaN=!1)}function h(){zo.Z.NaNReceiver&&m.value&&(zo.Z.NaNReceiver[m.value]=new V.ZP(NaN),zo.Z.hasNaN=!1)}return(e,s)=>((0,l.openBlock)(),(0,l.createElementBlock)(l.Fragment,null,[(0,l.createVNode)(b.Z,(0,l.mergeProps)({modelValue:(0,l.unref)(r),"onUpdate:modelValue":s[4]||(s[4]=e=>(0,l.isRef)(r)?r.value=e:null)},e.$attrs),{header:(0,l.withCtx)((()=>[Go])),body:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",null,[(0,l.createTextVNode)((()=>' Attempted to assign "'+(0,l.toDisplayString)((0,l.unref)(u))!==void 0&&' Attempted to assign "'+(0,l.toDisplayString)((0,l.unref)(u))!==null&&(' Attempted to assign "'+(0,l.toDisplayString)((0,l.unref)(u)))[Symbol.for("+")]?(' Attempted to assign "'+(0,l.toDisplayString)((0,l.unref)(u)))[Symbol.for("+")]('" to NaN'):' Attempted to assign "'+(0,l.toDisplayString)((0,l.unref)(u))+'" to NaN')(),1),(0,l.unref)(c)?((0,l.openBlock)(),(0,l.createElementBlock)("span",Ho,(()=>(0,l.toDisplayString)(" ")+"(previously "+(0,l.toDisplayString)((0,l.unref)(V.WU)((0,l.unref)(c)))!==void 0&&(0,l.toDisplayString)(" ")+"(previously "+(0,l.toDisplayString)((0,l.unref)(V.WU)((0,l.unref)(c)))!==null&&((0,l.toDisplayString)(" ")+"(previously "+(0,l.toDisplayString)((0,l.unref)(V.WU)((0,l.unref)(c))))[Symbol.for("+")]?((0,l.toDisplayString)(" ")+"(previously "+(0,l.toDisplayString)((0,l.unref)(V.WU)((0,l.unref)(c))))[Symbol.for("+")](")"):(0,l.toDisplayString)(" ")+"(previously "+(0,l.toDisplayString)((0,l.unref)(V.WU)((0,l.unref)(c)))+")")(),1)):(0,l.createCommentVNode)("",!0),(0,l.createTextVNode)((()=>". Auto-saving has been "+(0,l.toDisplayString)((0,l.unref)(n)?"enabled":"disabled")!==void 0&&". Auto-saving has been "+(0,l.toDisplayString)((0,l.unref)(n)?"enabled":"disabled")!==null&&(". Auto-saving has been "+(0,l.toDisplayString)((0,l.unref)(n)?"enabled":"disabled"))[Symbol.for("+")]?(". Auto-saving has been "+(0,l.toDisplayString)((0,l.unref)(n)?"enabled":"disabled"))[Symbol.for("+")](". Check the console for more details, and consider sharing it with the developers on discord. "):". Auto-saving has been "+(0,l.toDisplayString)((0,l.unref)(n)?"enabled":"disabled")+". Check the console for more details, and consider sharing it with the developers on discord. ")(),1)]),Wo,(0,l.createElementVNode)("div",null,[(0,l.createElementVNode)("a",{href:(0,l.unref)(t),class:"nan-modal-discord-link"},[Yo,(0,l.createTextVNode)((()=>" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,l.toDisplayString)((0,l.unref)(o))):" "+(0,l.toDisplayString)((0,l.unref)(o)))(),1)],8,$o)]),Ko,(0,l.createVNode)(G.Z,{title:"Autosave",modelValue:(0,l.unref)(n),"onUpdate:modelValue":s[0]||(s[0]=e=>(0,l.isRef)(n)?n.value=e:null)},null,8,["modelValue"]),(0,l.unref)(i).enablePausing?((0,l.openBlock)(),(0,l.createBlock)(G.Z,{key:0,title:"Pause game",modelValue:(0,l.unref)(f),"onUpdate:modelValue":s[1]||(s[1]=e=>(0,l.isRef)(f)?f.value=e:null)},null,8,["modelValue"])):(0,l.createCommentVNode)("",!0)])),footer:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",Qo,[(0,l.createElementVNode)("button",{onClick:s[2]||(s[2]=e=>a.value?.open()),class:"button"},"Open Saves Manager"),(0,l.createElementVNode)("button",{onClick:d,class:"button"},"Set to 0"),(0,l.createElementVNode)("button",{onClick:y,class:"button"},"Set to 1"),(0,l.unref)(c)&&(0,l.unref)(V.ZP).neq((0,l.unref)(c),0)&&(0,l.unref)(V.ZP).neq((0,l.unref)(c),1)?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:0,onClick:s[3]||(s[3]=e=>r.value=!1),class:"button"}," Set to previous ")):(0,l.createCommentVNode)("",!0),(0,l.createElementVNode)("button",{onClick:h,class:"button danger"},"Ignore")])])),_:1},16,["modelValue"]),(0,l.createVNode)(We,{ref_key:"savesManager",ref:a},null,512)],64))}});const Xo=(0,f.Z)(Jo,[["__scopeId","data-v-5935214c"]]);var et=Xo;const ot={key:0,class:"tpsDisplay"},tt={key:0,class:"low"};var lt=(0,l.defineComponent)({setup(e){const o=(0,l.computed)((()=>V.ZP.div(zo.Z.lastTenTicks.length,zo.Z.lastTenTicks.reduce(((e,o)=>(()=>void 0!==e&&null!==e&&e[Symbol.for("+")]?e[Symbol.for("+")](o):e+o)()),0)))),t=(0,l.ref)([]);(0,l.watchEffect)((()=>{t.value.push(Math.round(o.value.toNumber())),(()=>void 0!==t.value.length&&null!==t.value.length&&t.value.length[Symbol.for(">")]?t.value.length[Symbol.for(">")](10):t.value.length>10)()&&(t.value=t.value.slice(1))}));const n=(0,l.computed)((()=>t.value.reduce(((e,o)=>V.ZP.max(e,o)),0))),r=(0,l.computed)((()=>V.ZP.sub(o.value,n.value).gt(1)));return(e,t)=>(()=>void 0!==(0,l.unref)(o).isNan()&&null!==(0,l.unref)(o).isNan()&&(0,l.unref)(o).isNan()[Symbol.for("!")]?(0,l.unref)(o).isNan()[Symbol.for("!")]():!(0,l.unref)(o).isNan())()?((0,l.openBlock)(),(0,l.createElementBlock)("div",ot,[(0,l.createTextVNode)((()=>" TPS: "+(0,l.toDisplayString)((0,l.unref)(V.Ht)((0,l.unref)(o)))!==void 0&&" TPS: "+(0,l.toDisplayString)((0,l.unref)(V.Ht)((0,l.unref)(o)))!==null&&(" TPS: "+(0,l.toDisplayString)((0,l.unref)(V.Ht)((0,l.unref)(o))))[Symbol.for("+")]?(" TPS: "+(0,l.toDisplayString)((0,l.unref)(V.Ht)((0,l.unref)(o))))[Symbol.for("+")](" "):" TPS: "+(0,l.toDisplayString)((0,l.unref)(V.Ht)((0,l.unref)(o)))+" ")(),1),(0,l.createVNode)(l.Transition,{name:"fade"},{default:(0,l.withCtx)((()=>[(0,l.unref)(r)?((0,l.openBlock)(),(0,l.createElementBlock)("span",tt,(0,l.toDisplayString)((0,l.unref)(V.Ht)((0,l.unref)(n))),1)):(0,l.createCommentVNode)("",!0)])),_:1})])):(0,l.createCommentVNode)("",!0)}});const nt=(0,f.Z)(lt,[["__scopeId","data-v-c0663118"]]);var rt=nt,it=(0,l.defineComponent)({setup(e){const o=i.useHeader,t=(0,l.computed)((()=>q.Z[k.ZP.theme].variables)),a=(0,l.toRef)(k.ZP,"showTPS"),s=(0,l.computed)((()=>(0,r.MM)((0,n.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[k.t.map(r.sY)]))))));return(e,n)=>((0,l.openBlock)(),(0,l.createElementBlock)(l.Fragment,null,[(0,l.createElementVNode)("div",{id:"modal-root",style:(0,l.normalizeStyle)((0,l.unref)(t))},null,4),(0,l.createElementVNode)("div",{class:(0,l.normalizeClass)(["app",{useHeader:(0,l.unref)(o)}]),style:(0,l.normalizeStyle)((0,l.unref)(t))},[(0,l.unref)(o)?((0,l.openBlock)(),(0,l.createBlock)(Vo,{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(wo),(0,l.unref)((0,l.unref)(a))?((0,l.openBlock)(),(0,l.createBlock)(rt,{key:1})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(qo),(0,l.createVNode)(et),((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(s))))],6)],64))}});const at=(0,f.Z)(it,[["__scopeId","data-v-f13f28b6"]]);var st=at;if(document.title=i.title,""===i.id)throw"Project ID is empty! Please select a unique ID for this project in /src/data/projInfo.json";requestAnimationFrame((async()=>{console.log("%cMade in Profectus%c\nLearn more at www.moddingtree.com","font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;","padding: 4px;"),await(0,X.zD)();const{globalBus:e,startGameLoop:o}=await t(7302),n=window.vue=(0,l.createApp)(st);e.emit("setupVue",n),n.mount("#app"),o()})),window.projInfo=i},5613:function(e,o,t){"use strict";t.d(o,{ZP:function(){return be},WU:function(){return ue},mr:function(){return ce},Ht:function(){return me}});var l={};t.r(l),t.d(l,{commaFormat:function(){return z},default:function(){return j},exponentialFormat:function(){return q},format:function(){return ee},formatSmall:function(){return ne},formatTime:function(){return te},formatWhole:function(){return oe},invertOOM:function(){return re},regularFormat:function(){return L},toPlaces:function(){return le}});var n=t(2482);t(1703);let r,i,a,s,u,m,c,f,d,y,b;const h=17,p=9e15,v=Math.log10(9e15),g=(()=>1[Symbol.for("/")]?1[Symbol.for("/")](9e15):1/9e15)(),S=308,N=(()=>324[Symbol.for("minus")]?324[Symbol.for("minus")]():-324)(),k=5,V=!0,x=!1,M=function(){const e=[];for(let t=(()=>void 0!==N&&null!==N&&N[Symbol.for("+")]?N[Symbol.for("+")](1):N+1)();(()=>void 0!==t&&null!==t&&t[Symbol.for("<=")]?t[Symbol.for("<=")](S):t<=S)();(()=>void 0!==t&&null!==t&&"object"===typeof t&&t[Symbol.for("postfix-increment")]?t[Symbol.for("postfix-increment")]():t++)())e.push(Number((()=>"1e"[Symbol.for("+")]?"1e"[Symbol.for("+")](t):"1e"+t)()));const o=323;return function(t){return e[(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](o):t+o)()]}}(),C=[2,Math.E,3,4,5,6,7,8,9,10],w=[[1,1.0891168053867777,1.1789745164521264,1.2701428397304229,1.3632066654400328,1.4587804913784246,1.557523817412741,1.660158301473385,1.767487542936873,1.8804205225512542,2],[1,1.1121114330934,1.23103892493161,1.35838369631113,1.49605193039935,1.64635423375119,1.81213853570186,1.99697132461829,2.20538955455724,2.44325744833852,Math.E],[1,1.1187738849693603,1.2464963939368214,1.38527004705667,1.5376664685821402,1.7068895236551784,1.897001227148399,2.1132403089001035,2.362480153784171,2.6539010333870774,3],[1,1.1367350847096405,1.2889510672956703,1.4606478703324786,1.6570295196661111,1.8850062585672889,2.1539465047453485,2.476829779693097,2.872061932789197,3.3664204535587183,4],[1,1.1494592900767588,1.319708228183931,1.5166291280087583,1.748171114438024,2.0253263297298045,2.3636668498288547,2.7858359149579424,3.3257226212448145,4.035730287722532,5],[1,1.159225940787673,1.343712473580932,1.5611293155111927,1.8221199554561318,2.14183924486326,2.542468319282638,3.0574682501653316,3.7390572020926873,4.6719550537360774,6],[1,1.1670905356972596,1.3632807444991446,1.5979222279405536,1.8842640123816674,2.2416069644878687,2.69893426559423,3.3012632110403577,4.121250340630164,5.281493033448316,7],[1,1.1736630594087796,1.379783782386201,1.6292821855668218,1.9378971836180754,2.3289975651071977,2.8384347394720835,3.5232708454565906,4.478242031114584,5.868592169644505,8],[1,1.1793017514670474,1.394054150657457,1.65664127441059,1.985170999970283,2.4069682290577457,2.9647310119960752,3.7278665320924946,4.814462547283592,6.436522247411611,9],[1,1.18422737399915,1.4066113788546144,1.680911177655277,2.027492094355525,2.4775152854601967,3.080455730250329,3.918234505962507,5.1332705696484595,6.9878696918072905,10]],Z=[[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.9194161097107025[Symbol.for("minus")]?.9194161097107025[Symbol.for("minus")]():-.9194161097107025)(),(()=>.8335625019330468[Symbol.for("minus")]?.8335625019330468[Symbol.for("minus")]():-.8335625019330468)(),(()=>.7425599821143978[Symbol.for("minus")]?.7425599821143978[Symbol.for("minus")]():-.7425599821143978)(),(()=>.6466611521029437[Symbol.for("minus")]?.6466611521029437[Symbol.for("minus")]():-.6466611521029437)(),(()=>.5462617907227869[Symbol.for("minus")]?.5462617907227869[Symbol.for("minus")]():-.5462617907227869)(),(()=>.4419033816638769[Symbol.for("minus")]?.4419033816638769[Symbol.for("minus")]():-.4419033816638769)(),(()=>.3342645487554494[Symbol.for("minus")]?.3342645487554494[Symbol.for("minus")]():-.3342645487554494)(),(()=>.224140440909962[Symbol.for("minus")]?.224140440909962[Symbol.for("minus")]():-.224140440909962)(),(()=>.11241087890006762[Symbol.for("minus")]?.11241087890006762[Symbol.for("minus")]():-.11241087890006762)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.90603157029014[Symbol.for("minus")]?.90603157029014[Symbol.for("minus")]():-.90603157029014)(),(()=>.80786507256596[Symbol.for("minus")]?.80786507256596[Symbol.for("minus")]():-.80786507256596)(),(()=>.7064666939634[Symbol.for("minus")]?.7064666939634[Symbol.for("minus")]():-.7064666939634)(),(()=>.60294836853664[Symbol.for("minus")]?.60294836853664[Symbol.for("minus")]():-.60294836853664)(),(()=>.49849837513117[Symbol.for("minus")]?.49849837513117[Symbol.for("minus")]():-.49849837513117)(),(()=>.39430303318768[Symbol.for("minus")]?.39430303318768[Symbol.for("minus")]():-.39430303318768)(),(()=>.29147201034755[Symbol.for("minus")]?.29147201034755[Symbol.for("minus")]():-.29147201034755)(),(()=>.19097820800866[Symbol.for("minus")]?.19097820800866[Symbol.for("minus")]():-.19097820800866)(),(()=>.09361896280296[Symbol.for("minus")]?.09361896280296[Symbol.for("minus")]():-.09361896280296)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.9021579584316141[Symbol.for("minus")]?.9021579584316141[Symbol.for("minus")]():-.9021579584316141)(),(()=>.8005762598234203[Symbol.for("minus")]?.8005762598234203[Symbol.for("minus")]():-.8005762598234203)(),(()=>.6964780623319391[Symbol.for("minus")]?.6964780623319391[Symbol.for("minus")]():-.6964780623319391)(),(()=>.5911906810998454[Symbol.for("minus")]?.5911906810998454[Symbol.for("minus")]():-.5911906810998454)(),(()=>.486050182576545[Symbol.for("minus")]?.486050182576545[Symbol.for("minus")]():-.486050182576545)(),(()=>.3823089430815083[Symbol.for("minus")]?.3823089430815083[Symbol.for("minus")]():-.3823089430815083)(),(()=>.28106046722897615[Symbol.for("minus")]?.28106046722897615[Symbol.for("minus")]():-.28106046722897615)(),(()=>.1831906535795894[Symbol.for("minus")]?.1831906535795894[Symbol.for("minus")]():-.1831906535795894)(),(()=>.08935809204418144[Symbol.for("minus")]?.08935809204418144[Symbol.for("minus")]():-.08935809204418144)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8917227442365535[Symbol.for("minus")]?.8917227442365535[Symbol.for("minus")]():-.8917227442365535)(),(()=>.781258746326964[Symbol.for("minus")]?.781258746326964[Symbol.for("minus")]():-.781258746326964)(),(()=>.6705130326902455[Symbol.for("minus")]?.6705130326902455[Symbol.for("minus")]():-.6705130326902455)(),(()=>.5612813129406509[Symbol.for("minus")]?.5612813129406509[Symbol.for("minus")]():-.5612813129406509)(),(()=>.4551067709033134[Symbol.for("minus")]?.4551067709033134[Symbol.for("minus")]():-.4551067709033134)(),(()=>.35319256652135966[Symbol.for("minus")]?.35319256652135966[Symbol.for("minus")]():-.35319256652135966)(),(()=>.2563741554088552[Symbol.for("minus")]?.2563741554088552[Symbol.for("minus")]():-.2563741554088552)(),(()=>.1651412821106526[Symbol.for("minus")]?.1651412821106526[Symbol.for("minus")]():-.1651412821106526)(),(()=>.0796919581982668[Symbol.for("minus")]?.0796919581982668[Symbol.for("minus")]():-.0796919581982668)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8843387974366064[Symbol.for("minus")]?.8843387974366064[Symbol.for("minus")]():-.8843387974366064)(),(()=>.7678744063886243[Symbol.for("minus")]?.7678744063886243[Symbol.for("minus")]():-.7678744063886243)(),(()=>.6529563724510552[Symbol.for("minus")]?.6529563724510552[Symbol.for("minus")]():-.6529563724510552)(),(()=>.5415870994657841[Symbol.for("minus")]?.5415870994657841[Symbol.for("minus")]():-.5415870994657841)(),(()=>.4352842206588936[Symbol.for("minus")]?.4352842206588936[Symbol.for("minus")]():-.4352842206588936)(),(()=>.33504449124791424[Symbol.for("minus")]?.33504449124791424[Symbol.for("minus")]():-.33504449124791424)(),(()=>.24138853420685147[Symbol.for("minus")]?.24138853420685147[Symbol.for("minus")]():-.24138853420685147)(),(()=>.15445285440944467[Symbol.for("minus")]?.15445285440944467[Symbol.for("minus")]():-.15445285440944467)(),(()=>.07409659641336663[Symbol.for("minus")]?.07409659641336663[Symbol.for("minus")]():-.07409659641336663)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8786709358426346[Symbol.for("minus")]?.8786709358426346[Symbol.for("minus")]():-.8786709358426346)(),(()=>.7577735191184886[Symbol.for("minus")]?.7577735191184886[Symbol.for("minus")]():-.7577735191184886)(),(()=>.6399546189952064[Symbol.for("minus")]?.6399546189952064[Symbol.for("minus")]():-.6399546189952064)(),(()=>.527284921869926[Symbol.for("minus")]?.527284921869926[Symbol.for("minus")]():-.527284921869926)(),(()=>.4211627631006314[Symbol.for("minus")]?.4211627631006314[Symbol.for("minus")]():-.4211627631006314)(),(()=>.3223479611761232[Symbol.for("minus")]?.3223479611761232[Symbol.for("minus")]():-.3223479611761232)(),(()=>.23107655627789858[Symbol.for("minus")]?.23107655627789858[Symbol.for("minus")]():-.23107655627789858)(),(()=>.1472057700818259[Symbol.for("minus")]?.1472057700818259[Symbol.for("minus")]():-.1472057700818259)(),(()=>.07035171210706326[Symbol.for("minus")]?.07035171210706326[Symbol.for("minus")]():-.07035171210706326)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8740862815291583[Symbol.for("minus")]?.8740862815291583[Symbol.for("minus")]():-.8740862815291583)(),(()=>.7497032990976209[Symbol.for("minus")]?.7497032990976209[Symbol.for("minus")]():-.7497032990976209)(),(()=>.6297119746181752[Symbol.for("minus")]?.6297119746181752[Symbol.for("minus")]():-.6297119746181752)(),(()=>.5161838335958787[Symbol.for("minus")]?.5161838335958787[Symbol.for("minus")]():-.5161838335958787)(),(()=>.41036238255751956[Symbol.for("minus")]?.41036238255751956[Symbol.for("minus")]():-.41036238255751956)(),(()=>.31277212146489963[Symbol.for("minus")]?.31277212146489963[Symbol.for("minus")]():-.31277212146489963)(),(()=>.2233976621705518[Symbol.for("minus")]?.2233976621705518[Symbol.for("minus")]():-.2233976621705518)(),(()=>.1418697367979619[Symbol.for("minus")]?.1418697367979619[Symbol.for("minus")]():-.1418697367979619)(),(()=>.06762117662323441[Symbol.for("minus")]?.06762117662323441[Symbol.for("minus")]():-.06762117662323441)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8702632331800649[Symbol.for("minus")]?.8702632331800649[Symbol.for("minus")]():-.8702632331800649)(),(()=>.7430366914122081[Symbol.for("minus")]?.7430366914122081[Symbol.for("minus")]():-.7430366914122081)(),(()=>.6213373075161548[Symbol.for("minus")]?.6213373075161548[Symbol.for("minus")]():-.6213373075161548)(),(()=>.5072025698095242[Symbol.for("minus")]?.5072025698095242[Symbol.for("minus")]():-.5072025698095242)(),(()=>.40171437727184167[Symbol.for("minus")]?.40171437727184167[Symbol.for("minus")]():-.40171437727184167)(),(()=>.30517930701410456[Symbol.for("minus")]?.30517930701410456[Symbol.for("minus")]():-.30517930701410456)(),(()=>.21736343968190863[Symbol.for("minus")]?.21736343968190863[Symbol.for("minus")]():-.21736343968190863)(),(()=>.137710238299109[Symbol.for("minus")]?.137710238299109[Symbol.for("minus")]():-.137710238299109)(),(()=>.06550774483471955[Symbol.for("minus")]?.06550774483471955[Symbol.for("minus")]():-.06550774483471955)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8670016295947213[Symbol.for("minus")]?.8670016295947213[Symbol.for("minus")]():-.8670016295947213)(),(()=>.7373984232432306[Symbol.for("minus")]?.7373984232432306[Symbol.for("minus")]():-.7373984232432306)(),(()=>.6143173985094293[Symbol.for("minus")]?.6143173985094293[Symbol.for("minus")]():-.6143173985094293)(),(()=>.49973884395492807[Symbol.for("minus")]?.49973884395492807[Symbol.for("minus")]():-.49973884395492807)(),(()=>.394584953527678[Symbol.for("minus")]?.394584953527678[Symbol.for("minus")]():-.394584953527678)(),(()=>.2989649949848695[Symbol.for("minus")]?.2989649949848695[Symbol.for("minus")]():-.2989649949848695)(),(()=>.21245647317021688[Symbol.for("minus")]?.21245647317021688[Symbol.for("minus")]():-.21245647317021688)(),(()=>.13434688362382652[Symbol.for("minus")]?.13434688362382652[Symbol.for("minus")]():-.13434688362382652)(),(()=>.0638072667348083[Symbol.for("minus")]?.0638072667348083[Symbol.for("minus")]():-.0638072667348083)(),0],[(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),(()=>.8641642839543857[Symbol.for("minus")]?.8641642839543857[Symbol.for("minus")]():-.8641642839543857)(),(()=>.732534623168535[Symbol.for("minus")]?.732534623168535[Symbol.for("minus")]():-.732534623168535)(),(()=>.6083127477059322[Symbol.for("minus")]?.6083127477059322[Symbol.for("minus")]():-.6083127477059322)(),(()=>.4934049257184696[Symbol.for("minus")]?.4934049257184696[Symbol.for("minus")]():-.4934049257184696)(),(()=>.3885773075899922[Symbol.for("minus")]?.3885773075899922[Symbol.for("minus")]():-.3885773075899922)(),(()=>.29376029055315767[Symbol.for("minus")]?.29376029055315767[Symbol.for("minus")]():-.29376029055315767)(),(()=>.2083678561173622[Symbol.for("minus")]?.2083678561173622[Symbol.for("minus")]():-.2083678561173622)(),(()=>.13155653399373268[Symbol.for("minus")]?.13155653399373268[Symbol.for("minus")]():-.13155653399373268)(),(()=>.062401588652553186[Symbol.for("minus")]?.062401588652553186[Symbol.for("minus")]():-.062401588652553186)(),0]],B=function(e){return O.fromValue_noAlloc(e)},P=function(e,o,t){return O.fromComponents(e,o,t)},E=function(e,o,t){return O.fromComponents_noNormalize(e,o,t)},F=function(e,o){const t=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1):o+1)(),l=Math.ceil(Math.log10(Math.abs(e))),n=(()=>void 0!==Math.round(e*Math.pow(10,t-l))&&null!==Math.round(e*Math.pow(10,t-l))&&Math.round(e*Math.pow(10,t-l))[Symbol.for("*")]?Math.round(e*Math.pow(10,t-l))[Symbol.for("*")](Math.pow(10,l-t)):Math.round(e*Math.pow(10,t-l))*Math.pow(10,l-t))();return parseFloat(n.toFixed(Math.max((()=>void 0!==t&&null!==t&&t[Symbol.for("-")]?t[Symbol.for("-")](l):t-l)(),0)))},T=function(e){return(()=>void 0!==Math.sign(e)&&null!==Math.sign(e)&&Math.sign(e)[Symbol.for("*")]?Math.sign(e)[Symbol.for("*")](Math.log10(Math.abs(e))):Math.sign(e)*Math.log10(Math.abs(e)))()},D=function(e){if((()=>void 0!==isFinite(e)&&null!==isFinite(e)&&isFinite(e)[Symbol.for("!")]?isFinite(e)[Symbol.for("!")]():!isFinite(e))())return e;if((()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](-50):e<-50)())return e===Math.trunc(e)?Number.NEGATIVE_INFINITY:0;let o=1;while((()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](10):e<10)())o=(()=>void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](e):o*e)(),(()=>{void 0!==e&&null!==e&&"object"===typeof e&&e[Symbol.for("prefix-increment")]?e[Symbol.for("prefix-increment")]():++e})();e=(()=>void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](1):e-1)();let t=.9189385332046727;t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")]((e+.5)*Math.log(e)):t+(e+.5)*Math.log(e))(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("-")]?t[Symbol.for("-")](e):t-e)();const l=(()=>void 0!==e&&null!==e&&e[Symbol.for("*")]?e[Symbol.for("*")](e):e*e)();let n=e;return t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1/(12*n)):t+1/(12*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1/(360*n)):t+1/(360*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1/(1260*n)):t+1/(1260*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1/(1680*n)):t+1/(1680*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](1/(1188*n)):t+1/(1188*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](691/(360360*n)):t+691/(360360*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](7/(1092*n)):t+7/(1092*n))(),n=(()=>void 0!==n&&null!==n&&n[Symbol.for("*")]?n[Symbol.for("*")](l):n*l)(),t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](3617/(122400*n)):t+3617/(122400*n))(),(()=>void 0!==Math.exp(t)&&null!==Math.exp(t)&&Math.exp(t)[Symbol.for("/")]?Math.exp(t)[Symbol.for("/")](o):Math.exp(t)/o)()},I=.5671432904097838,R=function(e,o=1e-10){let t,l;if((()=>void 0!==Number.isFinite(e)&&null!==Number.isFinite(e)&&Number.isFinite(e)[Symbol.for("!")]?Number.isFinite(e)[Symbol.for("!")]():!Number.isFinite(e))())return e;if(0===e)return e;if(1===e)return I;t=(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](10):e<10)()?0:(()=>void 0!==Math.log(e)&&null!==Math.log(e)&&Math.log(e)[Symbol.for("-")]?Math.log(e)[Symbol.for("-")](Math.log(Math.log(e))):Math.log(e)-Math.log(Math.log(e)))();for(let n=0;(()=>void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](100):n<100)();(()=>void 0!==n&&null!==n&&"object"===typeof n&&n[Symbol.for("prefix-increment")]?n[Symbol.for("prefix-increment")]():++n)()){if(l=(()=>e*Math.exp(-t)+t*t!==void 0&&e*Math.exp(-t)+t*t!==null&&(e*Math.exp(-t)+t*t)[Symbol.for("/")]?(e*Math.exp(-t)+t*t)[Symbol.for("/")](t+1):(e*Math.exp(-t)+t*t)/(t+1))(),(()=>void 0!==Math.abs(l-t)&&null!==Math.abs(l-t)&&Math.abs(l-t)[Symbol.for("<")]?Math.abs(l-t)[Symbol.for("<")](o*Math.abs(l)):Math.abs(l-t)<o*Math.abs(l))())return l;t=l}throw Error(`Iteration failed to converge: ${e.toString()}`)};function _(e,o=1e-10){let t,l,n,r;if((()=>void 0!==Number.isFinite(e.mag)&&null!==Number.isFinite(e.mag)&&Number.isFinite(e.mag)[Symbol.for("!")]?Number.isFinite(e.mag)[Symbol.for("!")]():!Number.isFinite(e.mag))())return e;if(e===O.dZero)return e;if(e===O.dOne)return B(I);O.abs(e);t=O.ln(e);for(let i=0;(()=>void 0!==i&&null!==i&&i[Symbol.for("<")]?i[Symbol.for("<")](100):i<100)();(()=>void 0!==i&&null!==i&&"object"===typeof i&&i[Symbol.for("prefix-increment")]?i[Symbol.for("prefix-increment")]():++i)()){if(l=O.exp((()=>void 0!==t&&null!==t&&t[Symbol.for("minus")]?t[Symbol.for("minus")]():-t)()),n=t.sub(e.mul(l)),r=t.sub(n.div(t.add(1).sub(t.add(2).mul(n).div(O.mul(2,t).add(2))))),O.abs(r.sub(t)).lt(O.abs(r).mul(o)))return r;t=r}throw Error(`Iteration failed to converge: ${e.toString()}`)}r=Symbol.for("+"),i=Symbol.for("-"),a=Symbol.for("*"),s=Symbol.for("/"),u=Symbol.for("minus"),m=Symbol.for("=="),c=Symbol.for(">"),f=Symbol.for("<"),d=Symbol.for(">="),y=Symbol.for("<="),b=Symbol.for("!=");class O{constructor(e){(0,n.Z)(this,"sign",Number.NaN),(0,n.Z)(this,"mag",Number.NaN),(0,n.Z)(this,"layer",Number.NaN),e instanceof O||(()=>void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e)()&&"object"===typeof e&&(()=>"sign"[Symbol.for("in")]?"sign"[Symbol.for("in")](e):"sign"in e)()&&(()=>"mag"[Symbol.for("in")]?"mag"[Symbol.for("in")](e):"mag"in e)()&&(()=>"layer"[Symbol.for("in")]?"layer"[Symbol.for("in")](e):"layer"in e)()?this.fromDecimal(e):"number"===typeof e?this.fromNumber(e):"string"===typeof e?this.fromString(e):(this.sign=0,this.layer=0,this.mag=0)}get m(){if(0===this.sign)return 0;if(0===this.layer){const e=Math.floor(Math.log10(this.mag));let o;return o=5e-324===this.mag?5:(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("/")]?this.mag[Symbol.for("/")](M(e)):this.mag/M(e))(),(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](o):this.sign*o)()}if(1===this.layer){const e=(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("-")]?this.mag[Symbol.for("-")](Math.floor(this.mag)):this.mag-Math.floor(this.mag))();return(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](Math.pow(10,e)):this.sign*Math.pow(10,e))()}return this.sign}set m(e){(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("<=")]?this.layer[Symbol.for("<=")](2):this.layer<=2)()?this.fromMantissaExponent(e,this.e):(this.sign=Math.sign(e),0===this.sign&&(this.layer,this.exponent))}get e(){return 0===this.sign?0:0===this.layer?Math.floor(Math.log10(this.mag)):1===this.layer?Math.floor(this.mag):2===this.layer?Math.floor((()=>void 0!==Math.sign(this.mag)&&null!==Math.sign(this.mag)&&Math.sign(this.mag)[Symbol.for("*")]?Math.sign(this.mag)[Symbol.for("*")](Math.pow(10,Math.abs(this.mag))):Math.sign(this.mag)*Math.pow(10,Math.abs(this.mag)))()):(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("*")]?this.mag[Symbol.for("*")](Number.POSITIVE_INFINITY):this.mag*Number.POSITIVE_INFINITY)()}set e(e){this.fromMantissaExponent(this.m,e)}get s(){return this.sign}set s(e){0===e?(this.sign=0,this.layer=0,this.mag=0):this.sign=e}get mantissa(){return this.m}set mantissa(e){this.m=e}get exponent(){return this.e}set exponent(e){this.e=e}static fromComponents(e,o,t){return(new O).fromComponents(e,o,t)}static fromComponents_noNormalize(e,o,t){return(new O).fromComponents_noNormalize(e,o,t)}static fromMantissaExponent(e,o){return(new O).fromMantissaExponent(e,o)}static fromMantissaExponent_noNormalize(e,o){return(new O).fromMantissaExponent_noNormalize(e,o)}static fromDecimal(e){return(new O).fromDecimal(e)}static fromNumber(e){return(new O).fromNumber(e)}static fromString(e){return(new O).fromString(e)}static fromValue(e){return(new O).fromValue(e)}static fromValue_noAlloc(e){return e instanceof O?e:new O(e)}static abs(e){return B(e).abs()}static neg(e){return B(e).neg()}static negate(e){return B(e).neg()}static negated(e){return B(e).neg()}static sign(e){return B(e).sign}static sgn(e){return B(e).sign}static round(e){return B(e).round()}static floor(e){return B(e).floor()}static ceil(e){return B(e).ceil()}static trunc(e){return B(e).trunc()}static add(e,o){return B(e).add(o)}static plus(e,o){return B(e).add(o)}static sub(e,o){return B(e).sub(o)}static subtract(e,o){return B(e).sub(o)}static minus(e,o){return B(e).sub(o)}static mul(e,o){return B(e).mul(o)}static multiply(e,o){return B(e).mul(o)}static times(e,o){return B(e).mul(o)}static div(e,o){return B(e).div(o)}static divide(e,o){return B(e).div(o)}static recip(e){return B(e).recip()}static reciprocal(e){return B(e).recip()}static reciprocate(e){return B(e).reciprocate()}static cmp(e,o){return B(e).cmp(o)}static cmpabs(e,o){return B(e).cmpabs(o)}static compare(e,o){return B(e).cmp(o)}static isNaN(e){return e=B(e),isNaN(e.sign)||isNaN(e.layer)||isNaN(e.mag)}static isFinite(e){return e=B(e),isFinite(e.sign)&&isFinite(e.layer)&&isFinite(e.mag)}static eq(e,o){return B(e).eq(o)}static equals(e,o){return B(e).eq(o)}static neq(e,o){return B(e).neq(o)}static notEquals(e,o){return B(e).notEquals(o)}static lt(e,o){return B(e).lt(o)}static lte(e,o){return B(e).lte(o)}static gt(e,o){return B(e).gt(o)}static gte(e,o){return B(e).gte(o)}static max(e,o){return B(e).max(o)}static min(e,o){return B(e).min(o)}static minabs(e,o){return B(e).minabs(o)}static maxabs(e,o){return B(e).maxabs(o)}static clamp(e,o,t){return B(e).clamp(o,t)}static clampMin(e,o){return B(e).clampMin(o)}static clampMax(e,o){return B(e).clampMax(o)}static cmp_tolerance(e,o,t){return B(e).cmp_tolerance(o,t)}static compare_tolerance(e,o,t){return B(e).cmp_tolerance(o,t)}static eq_tolerance(e,o,t){return B(e).eq_tolerance(o,t)}static equals_tolerance(e,o,t){return B(e).eq_tolerance(o,t)}static neq_tolerance(e,o,t){return B(e).neq_tolerance(o,t)}static notEquals_tolerance(e,o,t){return B(e).notEquals_tolerance(o,t)}static lt_tolerance(e,o,t){return B(e).lt_tolerance(o,t)}static lte_tolerance(e,o,t){return B(e).lte_tolerance(o,t)}static gt_tolerance(e,o,t){return B(e).gt_tolerance(o,t)}static gte_tolerance(e,o,t){return B(e).gte_tolerance(o,t)}static pLog10(e){return B(e).pLog10()}static absLog10(e){return B(e).absLog10()}static log10(e){return B(e).log10()}static log(e,o){return B(e).log(o)}static log2(e){return B(e).log2()}static ln(e){return B(e).ln()}static logarithm(e,o){return B(e).logarithm(o)}static pow(e,o){return B(e).pow(o)}static pow10(e){return B(e).pow10()}static root(e,o){return B(e).root(o)}static factorial(e,o){return B(e).factorial()}static gamma(e,o){return B(e).gamma()}static lngamma(e,o){return B(e).lngamma()}static exp(e){return B(e).exp()}static sqr(e){return B(e).sqr()}static sqrt(e){return B(e).sqrt()}static cube(e){return B(e).cube()}static cbrt(e){return B(e).cbrt()}static tetrate(e,o=2,t=E(1,0,1)){return B(e).tetrate(o,t)}static iteratedexp(e,o=2,t=E(1,0,1)){return B(e).iteratedexp(o,t)}static iteratedlog(e,o=10,t=1){return B(e).iteratedlog(o,t)}static layeradd10(e,o){return B(e).layeradd10(o)}static layeradd(e,o,t=10){return B(e).layeradd(o,t)}static slog(e,o=10){return B(e).slog(o)}static lambertw(e){return B(e).lambertw()}static ssqrt(e){return B(e).ssqrt()}static pentate(e,o=2,t=E(1,0,1)){return B(e).pentate(o,t)}static affordGeometricSeries(e,o,t,l){return this.affordGeometricSeries_core(B(e),B(o),B(t),l)}static sumGeometricSeries(e,o,t,l){return this.sumGeometricSeries_core(e,B(o),B(t),l)}static affordArithmeticSeries(e,o,t,l){return this.affordArithmeticSeries_core(B(e),B(o),B(t),B(l))}static sumArithmeticSeries(e,o,t,l){return this.sumArithmeticSeries_core(B(e),B(o),B(t),B(l))}static efficiencyOfPurchase(e,o,t){return this.efficiencyOfPurchase_core(B(e),B(o),B(t))}static randomDecimalForTesting(e){if((()=>20*Math.random()!==void 0&&20*Math.random()!==null&&(20*Math.random())[Symbol.for("<")]?(20*Math.random())[Symbol.for("<")](1):20*Math.random()<1)())return E(0,0,0);const o=(()=>void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for(">")]?Math.random()[Symbol.for(">")](.5):Math.random()>.5)()?1:(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)();if((()=>20*Math.random()!==void 0&&20*Math.random()!==null&&(20*Math.random())[Symbol.for("<")]?(20*Math.random())[Symbol.for("<")](1):20*Math.random()<1)())return E(o,0,1);const t=Math.floor((()=>void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for("*")]?Math.random()[Symbol.for("*")](e+1):Math.random()*(e+1))());let l=0===t?(()=>616*Math.random()!==void 0&&616*Math.random()!==null&&(616*Math.random())[Symbol.for("-")]?(616*Math.random())[Symbol.for("-")](308):616*Math.random()-308)():(()=>void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for("*")]?Math.random()[Symbol.for("*")](16):16*Math.random())();(()=>void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for(">")]?Math.random()[Symbol.for(">")](.9):Math.random()>.9)()&&(l=Math.trunc(l));let n=Math.pow(10,l);return(()=>void 0!==Math.random()&&null!==Math.random()&&Math.random()[Symbol.for(">")]?Math.random()[Symbol.for(">")](.9):Math.random()>.9)()&&(n=Math.trunc(n)),P(o,t,n)}static affordGeometricSeries_core(e,o,t,l){const n=o.mul(t.pow(l));return O.floor(e.div(n).mul(t.sub(1)).add(1).log10().div(t.log10()))}static sumGeometricSeries_core(e,o,t,l){return o.mul(t.pow(l)).mul(O.sub(1,t.pow(e))).div(O.sub(1,t))}static affordArithmeticSeries_core(e,o,t,l){const n=o.add(l.mul(t)),r=n.sub(t.div(2)),i=r.pow(2);return r.neg().add(i.add(t.mul(e).mul(2)).sqrt()).div(t).floor()}static sumArithmeticSeries_core(e,o,t,l){const n=o.add(l.mul(t));return e.div(2).mul(n.mul(2).plus(e.sub(1).mul(t)))}static efficiencyOfPurchase_core(e,o,t){return e.div(o).add(e.div(t))}[r](e){return this.add(e)}[i](e){return this.sub(e)}[a](e){return this.times(e)}[s](e){return this.div(e)}[u](){return this.neg()}[m](e){return this.eq(e)}[c](e){return this.gt(e)}[f](e){return this.lt(e)}[d](e){return this.gte(e)}[y](e){return this.lte(e)}[b](e){return this.neq(e)}normalize(){if(0===this.sign||0===this.mag&&0===this.layer)return this.sign=0,this.mag=0,this.layer=0,this;if(0===this.layer&&(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()&&(this.mag=(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("minus")]?this.mag[Symbol.for("minus")]():-this.mag)(),this.sign=(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("minus")]?this.sign[Symbol.for("minus")]():-this.sign)()),0===this.layer&&(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](g):this.mag<g)())return this.layer=(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("+")]?this.layer[Symbol.for("+")](1):this.layer+1)(),this.mag=Math.log10(this.mag),this;let e=Math.abs(this.mag),o=Math.sign(this.mag);if((()=>void 0!==e&&null!==e&&e[Symbol.for(">=")]?e[Symbol.for(">=")](p):e>=p)())return this.layer=(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("+")]?this.layer[Symbol.for("+")](1):this.layer+1)(),this.mag=(()=>void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](Math.log10(e)):o*Math.log10(e))(),this;while((()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](v):e<v)()&&(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">")]?this.layer[Symbol.for(">")](0):this.layer>0)())this.layer=(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),0===this.layer?this.mag=Math.pow(10,this.mag):(this.mag=(()=>void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](Math.pow(10,e)):o*Math.pow(10,e))(),e=Math.abs(this.mag),o=Math.sign(this.mag));return 0===this.layer&&((()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?(this.mag=(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("minus")]?this.mag[Symbol.for("minus")]():-this.mag)(),this.sign=(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("minus")]?this.sign[Symbol.for("minus")]():-this.sign)()):0===this.mag&&(this.sign=0)),this}fromComponents(e,o,t){return this.sign=e,this.layer=o,this.mag=t,this.normalize(),this}fromComponents_noNormalize(e,o,t){return this.sign=e,this.layer=o,this.mag=t,this}fromMantissaExponent(e,o){return this.layer=1,this.sign=Math.sign(e),e=Math.abs(e),this.mag=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](Math.log10(e)):o+Math.log10(e))(),this.normalize(),this}fromMantissaExponent_noNormalize(e,o){return this.fromMantissaExponent(e,o),this}fromDecimal(e){return this.sign=e.sign,this.layer=e.layer,this.mag=e.mag,this}fromNumber(e){return this.mag=Math.abs(e),this.sign=Math.sign(e),this.layer=0,this.normalize(),this}fromString(e){V?e=e.replace(",",""):x&&(e=e.replace(",","."));const o=e.split("^^^");if(2===o.length){const e=parseFloat(o[0]),t=parseFloat(o[1]),l=o[1].split(";");let n=1;if(2===l.length&&(n=parseFloat(l[1]),(()=>void 0!==isFinite(n)&&null!==isFinite(n)&&isFinite(n)[Symbol.for("!")]?isFinite(n)[Symbol.for("!")]():!isFinite(n))()&&(n=1)),isFinite(e)&&isFinite(t)){const o=O.pentate(e,t,n);return this.sign=o.sign,this.layer=o.layer,this.mag=o.mag,this}}const t=e.split("^^");if(2===t.length){const e=parseFloat(t[0]),o=parseFloat(t[1]),l=t[1].split(";");let n=1;if(2===l.length&&(n=parseFloat(l[1]),(()=>void 0!==isFinite(n)&&null!==isFinite(n)&&isFinite(n)[Symbol.for("!")]?isFinite(n)[Symbol.for("!")]():!isFinite(n))()&&(n=1)),isFinite(e)&&isFinite(o)){const t=O.tetrate(e,o,n);return this.sign=t.sign,this.layer=t.layer,this.mag=t.mag,this}}const l=e.split("^");if(2===l.length){const e=parseFloat(l[0]),o=parseFloat(l[1]);if(isFinite(e)&&isFinite(o)){const t=O.pow(e,o);return this.sign=t.sign,this.layer=t.layer,this.mag=t.mag,this}}let n,r;e=e.trim().toLowerCase();let i=e.split("pt");if(2===i.length){n=10,r=parseFloat(i[0]),i[1]=i[1].replace("(",""),i[1]=i[1].replace(")","");let e=parseFloat(i[1]);if((()=>void 0!==isFinite(e)&&null!==isFinite(e)&&isFinite(e)[Symbol.for("!")]?isFinite(e)[Symbol.for("!")]():!isFinite(e))()&&(e=1),isFinite(n)&&isFinite(r)){const o=O.tetrate(n,r,e);return this.sign=o.sign,this.layer=o.layer,this.mag=o.mag,this}}if(i=e.split("p"),2===i.length){n=10,r=parseFloat(i[0]),i[1]=i[1].replace("(",""),i[1]=i[1].replace(")","");let e=parseFloat(i[1]);if((()=>void 0!==isFinite(e)&&null!==isFinite(e)&&isFinite(e)[Symbol.for("!")]?isFinite(e)[Symbol.for("!")]():!isFinite(e))()&&(e=1),isFinite(n)&&isFinite(r)){const o=O.tetrate(n,r,e);return this.sign=o.sign,this.layer=o.layer,this.mag=o.mag,this}}const a=e.split("e"),s=(()=>void 0!==a.length&&null!==a.length&&a.length[Symbol.for("-")]?a.length[Symbol.for("-")](1):a.length-1)();if(0===s){const o=parseFloat(e);if(isFinite(o))return this.fromNumber(o)}else if(1===s){const o=parseFloat(e);if(isFinite(o)&&(()=>void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](0):0!==o)())return this.fromNumber(o)}const u=e.split("e^");if(2===u.length){this.sign=1,(()=>void 0!==u[0].charAt(0)&&null!==u[0].charAt(0)&&u[0].charAt(0)[Symbol.for("==")]?u[0].charAt(0)[Symbol.for("==")]("-"):"-"==u[0].charAt(0))()&&(this.sign=(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)());let e="";for(let o=0;(()=>void 0!==o&&null!==o&&o[Symbol.for("<")]?o[Symbol.for("<")](u[1].length):o<u[1].length)();(()=>void 0!==o&&null!==o&&"object"===typeof o&&o[Symbol.for("prefix-increment")]?o[Symbol.for("prefix-increment")]():++o)()){const t=u[1].charCodeAt(o);if(!((()=>void 0!==t&&null!==t&&t[Symbol.for(">=")]?t[Symbol.for(">=")](43):t>=43)()&&(()=>void 0!==t&&null!==t&&t[Symbol.for("<=")]?t[Symbol.for("<=")](57):t<=57)()||101===t))return this.layer=parseFloat(e),this.mag=parseFloat(u[1].substr((()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1):o+1)())),this.normalize(),this;e=(()=>void 0!==e&&null!==e&&e[Symbol.for("+")]?e[Symbol.for("+")](u[1].charAt(o)):e+u[1].charAt(o))()}}if((()=>void 0!==s&&null!==s&&s[Symbol.for("<")]?s[Symbol.for("<")](1):s<1)())return this.sign=0,this.layer=0,this.mag=0,this;const m=parseFloat(a[0]);if(0===m)return this.sign=0,this.layer=0,this.mag=0,this;let c=parseFloat(a[(()=>void 0!==a.length&&null!==a.length&&a.length[Symbol.for("-")]?a.length[Symbol.for("-")](1):a.length-1)()]);if((()=>void 0!==s&&null!==s&&s[Symbol.for(">=")]?s[Symbol.for(">=")](2):s>=2)()){const e=parseFloat(a[(()=>void 0!==a.length&&null!==a.length&&a.length[Symbol.for("-")]?a.length[Symbol.for("-")](2):a.length-2)()]);isFinite(e)&&(c=(()=>void 0!==c&&null!==c&&c[Symbol.for("*")]?c[Symbol.for("*")](Math.sign(e)):c*Math.sign(e))(),c=(()=>void 0!==c&&null!==c&&c[Symbol.for("+")]?c[Symbol.for("+")](T(e)):c+T(e))())}if((()=>void 0!==isFinite(m)&&null!==isFinite(m)&&isFinite(m)[Symbol.for("!")]?isFinite(m)[Symbol.for("!")]():!isFinite(m))())this.sign="-"===a[0]?(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)():1,this.layer=s,this.mag=c;else if(1===s)this.sign=Math.sign(m),this.layer=1,this.mag=(()=>void 0!==c&&null!==c&&c[Symbol.for("+")]?c[Symbol.for("+")](Math.log10(Math.abs(m))):c+Math.log10(Math.abs(m)))();else{if(this.sign=Math.sign(m),this.layer=s,2===s){const e=O.mul(P(1,2,c),B(m));return this.sign=e.sign,this.layer=e.layer,this.mag=e.mag,this}this.mag=c}return this.normalize(),this}fromValue(e){return e instanceof O||(()=>void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e)()&&"object"===typeof e&&(()=>"sign"[Symbol.for("in")]?"sign"[Symbol.for("in")](e):"sign"in e)()&&(()=>"mag"[Symbol.for("in")]?"mag"[Symbol.for("in")](e):"mag"in e)()&&(()=>"layer"[Symbol.for("in")]?"layer"[Symbol.for("in")](e):"layer"in e)()?this.fromDecimal(e):"number"===typeof e?this.fromNumber(e):"string"===typeof e?this.fromString(e):(this.sign=0,this.layer=0,this.mag=0,this)}toNumber(){return(()=>void 0!==Number.isFinite(this.layer)&&null!==Number.isFinite(this.layer)&&Number.isFinite(this.layer)[Symbol.for("!")]?Number.isFinite(this.layer)[Symbol.for("!")]():!Number.isFinite(this.layer))()?Number.NaN:0===this.layer?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)():1===this.layer?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](Math.pow(10,this.mag)):this.sign*Math.pow(10,this.mag))():(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for(">")]?this.mag[Symbol.for(">")](0):this.mag>0)()?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for(">")]?this.sign[Symbol.for(">")](0):this.sign>0)()?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:0}mantissaWithDecimalPlaces(e){return isNaN(this.m)?Number.NaN:0===this.m?0:F(this.m,e)}magnitudeWithDecimalPlaces(e){return isNaN(this.mag)?Number.NaN:0===this.mag?0:F(this.mag,e)}toString(){return isNaN(this.layer)||isNaN(this.sign)||isNaN(this.mag)?"NaN":this.mag===Number.POSITIVE_INFINITY||this.layer===Number.POSITIVE_INFINITY?1===this.sign?"Infinity":"-Infinity":0===this.layer?(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](1e21):this.mag<1e21)()&&(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for(">")]?this.mag[Symbol.for(">")](1e-7):this.mag>1e-7)()||0===this.mag?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)().toString():(()=>this.m+"e"!==void 0&&this.m+"e"!==null&&(this.m+"e")[Symbol.for("+")]?(this.m+"e")[Symbol.for("+")](this.e):this.m+"e"+this.e)():1===this.layer?(()=>this.m+"e"!==void 0&&this.m+"e"!==null&&(this.m+"e")[Symbol.for("+")]?(this.m+"e")[Symbol.for("+")](this.e):this.m+"e"+this.e)():(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("<=")]?this.layer[Symbol.for("<=")](k):this.layer<=k)()?(()=>(-1===this.sign?"-":"")+"e".repeat(this.layer)!==void 0&&(-1===this.sign?"-":"")+"e".repeat(this.layer)!==null&&((-1===this.sign?"-":"")+"e".repeat(this.layer))[Symbol.for("+")]?((-1===this.sign?"-":"")+"e".repeat(this.layer))[Symbol.for("+")](this.mag):(-1===this.sign?"-":"")+"e".repeat(this.layer)+this.mag)():(()=>(-1===this.sign?"-":"")+"(e^"+this.layer+")"!==void 0&&(-1===this.sign?"-":"")+"(e^"+this.layer+")"!==null&&((-1===this.sign?"-":"")+"(e^"+this.layer+")")[Symbol.for("+")]?((-1===this.sign?"-":"")+"(e^"+this.layer+")")[Symbol.for("+")](this.mag):(-1===this.sign?"-":"")+"(e^"+this.layer+")"+this.mag)()}toExponential(e){return 0===this.layer?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)().toExponential(e):this.toStringWithDecimalPlaces(e)}toFixed(e){return 0===this.layer?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)().toFixed(e):this.toStringWithDecimalPlaces(e)}toPrecision(e){return(()=>void 0!==this.e&&null!==this.e&&this.e[Symbol.for("<=")]?this.e[Symbol.for("<=")](-7):this.e<=-7)()?this.toExponential((()=>void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](1):e-1)()):(()=>void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](this.e):e>this.e)()?this.toFixed((()=>e-this.exponent!==void 0&&e-this.exponent!==null&&(e-this.exponent)[Symbol.for("-")]?(e-this.exponent)[Symbol.for("-")](1):e-this.exponent-1)()):this.toExponential((()=>void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](1):e-1)())}valueOf(){return this.toString()}toJSON(){return this.toString()}toStringWithDecimalPlaces(e){return 0===this.layer?(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](1e21):this.mag<1e21)()&&(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for(">")]?this.mag[Symbol.for(">")](1e-7):this.mag>1e-7)()||0===this.mag?(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)().toFixed(e):(()=>F(this.m,e)+"e"!==void 0&&F(this.m,e)+"e"!==null&&(F(this.m,e)+"e")[Symbol.for("+")]?(F(this.m,e)+"e")[Symbol.for("+")](F(this.e,e)):F(this.m,e)+"e"+F(this.e,e))():1===this.layer?(()=>F(this.m,e)+"e"!==void 0&&F(this.m,e)+"e"!==null&&(F(this.m,e)+"e")[Symbol.for("+")]?(F(this.m,e)+"e")[Symbol.for("+")](F(this.e,e)):F(this.m,e)+"e"+F(this.e,e))():(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("<=")]?this.layer[Symbol.for("<=")](k):this.layer<=k)()?(()=>(-1===this.sign?"-":"")+"e".repeat(this.layer)!==void 0&&(-1===this.sign?"-":"")+"e".repeat(this.layer)!==null&&((-1===this.sign?"-":"")+"e".repeat(this.layer))[Symbol.for("+")]?((-1===this.sign?"-":"")+"e".repeat(this.layer))[Symbol.for("+")](F(this.mag,e)):(-1===this.sign?"-":"")+"e".repeat(this.layer)+F(this.mag,e))():(()=>(-1===this.sign?"-":"")+"(e^"+this.layer+")"!==void 0&&(-1===this.sign?"-":"")+"(e^"+this.layer+")"!==null&&((-1===this.sign?"-":"")+"(e^"+this.layer+")")[Symbol.for("+")]?((-1===this.sign?"-":"")+"(e^"+this.layer+")")[Symbol.for("+")](F(this.mag,e)):(-1===this.sign?"-":"")+"(e^"+this.layer+")"+F(this.mag,e))()}abs(){return E(0===this.sign?0:1,this.layer,this.mag)}neg(){return E((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("minus")]?this.sign[Symbol.for("minus")]():-this.sign)(),this.layer,this.mag)}negate(){return this.neg()}negated(){return this.neg()}sgn(){return this.sign}round(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?O.dZero:0===this.layer?P(this.sign,0,Math.round(this.mag)):this}floor(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?O.dZero:0===this.layer?P(this.sign,0,Math.floor(this.mag)):this}ceil(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?O.dZero:0===this.layer?P(this.sign,0,Math.ceil(this.mag)):this}trunc(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?O.dZero:0===this.layer?P(this.sign,0,Math.trunc(this.mag)):this}add(e){const o=B(e);if((()=>void 0!==Number.isFinite(this.layer)&&null!==Number.isFinite(this.layer)&&Number.isFinite(this.layer)[Symbol.for("!")]?Number.isFinite(this.layer)[Symbol.for("!")]():!Number.isFinite(this.layer))())return this;if((()=>void 0!==Number.isFinite(o.layer)&&null!==Number.isFinite(o.layer)&&Number.isFinite(o.layer)[Symbol.for("!")]?Number.isFinite(o.layer)[Symbol.for("!")]():!Number.isFinite(o.layer))())return o;if(0===this.sign)return o;if(0===o.sign)return this;if(this.sign===(()=>void 0!==o.sign&&null!==o.sign&&o.sign[Symbol.for("minus")]?o.sign[Symbol.for("minus")]():-o.sign)()&&this.layer===o.layer&&this.mag===o.mag)return E(0,0,0);let t,l;if((()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">=")]?this.layer[Symbol.for(">=")](2):this.layer>=2)()||(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">=")]?o.layer[Symbol.for(">=")](2):o.layer>=2)())return this.maxabs(o);if((()=>void 0!==O.cmpabs(this,o)&&null!==O.cmpabs(this,o)&&O.cmpabs(this,o)[Symbol.for(">")]?O.cmpabs(this,o)[Symbol.for(">")](0):O.cmpabs(this,o)>0)()?(t=this,l=o):(t=o,l=this),0===t.layer&&0===l.layer)return B((()=>t.sign*t.mag!==void 0&&t.sign*t.mag!==null&&(t.sign*t.mag)[Symbol.for("+")]?(t.sign*t.mag)[Symbol.for("+")](l.sign*l.mag):t.sign*t.mag+l.sign*l.mag)());const n=(()=>void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("*")]?t.layer[Symbol.for("*")](Math.sign(t.mag)):t.layer*Math.sign(t.mag))(),r=(()=>void 0!==l.layer&&null!==l.layer&&l.layer[Symbol.for("*")]?l.layer[Symbol.for("*")](Math.sign(l.mag)):l.layer*Math.sign(l.mag))();if((()=>n-r!==void 0&&n-r!==null&&(n-r)[Symbol.for(">=")]?(n-r)[Symbol.for(">=")](2):n-r>=2)())return t;if(0===n&&r===(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()){if((()=>void 0!==Math.abs(l.mag-Math.log10(t.mag))&&null!==Math.abs(l.mag-Math.log10(t.mag))&&Math.abs(l.mag-Math.log10(t.mag))[Symbol.for(">")]?Math.abs(l.mag-Math.log10(t.mag))[Symbol.for(">")](h):Math.abs(l.mag-Math.log10(t.mag))>h)())return t;{const e=Math.pow(10,(()=>void 0!==Math.log10(t.mag)&&null!==Math.log10(t.mag)&&Math.log10(t.mag)[Symbol.for("-")]?Math.log10(t.mag)[Symbol.for("-")](l.mag):Math.log10(t.mag)-l.mag)()),o=(()=>void 0!==l.sign&&null!==l.sign&&l.sign[Symbol.for("+")]?l.sign[Symbol.for("+")](t.sign*e):l.sign+t.sign*e)();return P(Math.sign(o),1,(()=>void 0!==l.mag&&null!==l.mag&&l.mag[Symbol.for("+")]?l.mag[Symbol.for("+")](Math.log10(Math.abs(o))):l.mag+Math.log10(Math.abs(o)))())}}if(1===n&&0===r){if((()=>void 0!==Math.abs(t.mag-Math.log10(l.mag))&&null!==Math.abs(t.mag-Math.log10(l.mag))&&Math.abs(t.mag-Math.log10(l.mag))[Symbol.for(">")]?Math.abs(t.mag-Math.log10(l.mag))[Symbol.for(">")](h):Math.abs(t.mag-Math.log10(l.mag))>h)())return t;{const e=Math.pow(10,(()=>void 0!==t.mag&&null!==t.mag&&t.mag[Symbol.for("-")]?t.mag[Symbol.for("-")](Math.log10(l.mag)):t.mag-Math.log10(l.mag))()),o=(()=>void 0!==l.sign&&null!==l.sign&&l.sign[Symbol.for("+")]?l.sign[Symbol.for("+")](t.sign*e):l.sign+t.sign*e)();return P(Math.sign(o),1,(()=>void 0!==Math.log10(l.mag)&&null!==Math.log10(l.mag)&&Math.log10(l.mag)[Symbol.for("+")]?Math.log10(l.mag)[Symbol.for("+")](Math.log10(Math.abs(o))):Math.log10(l.mag)+Math.log10(Math.abs(o)))())}}if((()=>void 0!==Math.abs(t.mag-l.mag)&&null!==Math.abs(t.mag-l.mag)&&Math.abs(t.mag-l.mag)[Symbol.for(">")]?Math.abs(t.mag-l.mag)[Symbol.for(">")](h):Math.abs(t.mag-l.mag)>h)())return t;{const e=Math.pow(10,(()=>void 0!==t.mag&&null!==t.mag&&t.mag[Symbol.for("-")]?t.mag[Symbol.for("-")](l.mag):t.mag-l.mag)()),o=(()=>void 0!==l.sign&&null!==l.sign&&l.sign[Symbol.for("+")]?l.sign[Symbol.for("+")](t.sign*e):l.sign+t.sign*e)();return P(Math.sign(o),1,(()=>void 0!==l.mag&&null!==l.mag&&l.mag[Symbol.for("+")]?l.mag[Symbol.for("+")](Math.log10(Math.abs(o))):l.mag+Math.log10(Math.abs(o)))())}}plus(e){return this.add(e)}sub(e){return this.add(B(e).neg())}subtract(e){return this.sub(e)}minus(e){return this.sub(e)}mul(e){const o=B(e);if((()=>void 0!==Number.isFinite(this.layer)&&null!==Number.isFinite(this.layer)&&Number.isFinite(this.layer)[Symbol.for("!")]?Number.isFinite(this.layer)[Symbol.for("!")]():!Number.isFinite(this.layer))())return this;if((()=>void 0!==Number.isFinite(o.layer)&&null!==Number.isFinite(o.layer)&&Number.isFinite(o.layer)[Symbol.for("!")]?Number.isFinite(o.layer)[Symbol.for("!")]():!Number.isFinite(o.layer))())return o;if(0===this.sign||0===o.sign)return E(0,0,0);if(this.layer===o.layer&&this.mag===(()=>void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("minus")]?o.mag[Symbol.for("minus")]():-o.mag)())return E((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](o.sign):this.sign*o.sign)(),0,1);let t,l;if((()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">")]?this.layer[Symbol.for(">")](o.layer):this.layer>o.layer)()||(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("==")]?this.layer[Symbol.for("==")](o.layer):this.layer==o.layer)()&&(()=>void 0!==Math.abs(this.mag)&&null!==Math.abs(this.mag)&&Math.abs(this.mag)[Symbol.for(">")]?Math.abs(this.mag)[Symbol.for(">")](Math.abs(o.mag)):Math.abs(this.mag)>Math.abs(o.mag))()?(t=this,l=o):(t=o,l=this),0===t.layer&&0===l.layer)return B((()=>t.sign*l.sign*t.mag!==void 0&&t.sign*l.sign*t.mag!==null&&(t.sign*l.sign*t.mag)[Symbol.for("*")]?(t.sign*l.sign*t.mag)[Symbol.for("*")](l.mag):t.sign*l.sign*t.mag*l.mag)());if((()=>void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for(">=")]?t.layer[Symbol.for(">=")](3):t.layer>=3)()||(()=>t.layer-l.layer!==void 0&&t.layer-l.layer!==null&&(t.layer-l.layer)[Symbol.for(">=")]?(t.layer-l.layer)[Symbol.for(">=")](2):t.layer-l.layer>=2)())return P((()=>void 0!==t.sign&&null!==t.sign&&t.sign[Symbol.for("*")]?t.sign[Symbol.for("*")](l.sign):t.sign*l.sign)(),t.layer,t.mag);if(1===t.layer&&0===l.layer)return P((()=>void 0!==t.sign&&null!==t.sign&&t.sign[Symbol.for("*")]?t.sign[Symbol.for("*")](l.sign):t.sign*l.sign)(),1,(()=>void 0!==t.mag&&null!==t.mag&&t.mag[Symbol.for("+")]?t.mag[Symbol.for("+")](Math.log10(l.mag)):t.mag+Math.log10(l.mag))());if(1===t.layer&&1===l.layer)return P((()=>void 0!==t.sign&&null!==t.sign&&t.sign[Symbol.for("*")]?t.sign[Symbol.for("*")](l.sign):t.sign*l.sign)(),1,(()=>void 0!==t.mag&&null!==t.mag&&t.mag[Symbol.for("+")]?t.mag[Symbol.for("+")](l.mag):t.mag+l.mag)());if(2===t.layer&&1===l.layer){const e=P(Math.sign(t.mag),(()=>void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("-")]?t.layer[Symbol.for("-")](1):t.layer-1)(),Math.abs(t.mag)).add(P(Math.sign(l.mag),(()=>void 0!==l.layer&&null!==l.layer&&l.layer[Symbol.for("-")]?l.layer[Symbol.for("-")](1):l.layer-1)(),Math.abs(l.mag)));return P((()=>void 0!==t.sign&&null!==t.sign&&t.sign[Symbol.for("*")]?t.sign[Symbol.for("*")](l.sign):t.sign*l.sign)(),(()=>void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1)(),(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag)())}if(2===t.layer&&2===l.layer){const e=P(Math.sign(t.mag),(()=>void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("-")]?t.layer[Symbol.for("-")](1):t.layer-1)(),Math.abs(t.mag)).add(P(Math.sign(l.mag),(()=>void 0!==l.layer&&null!==l.layer&&l.layer[Symbol.for("-")]?l.layer[Symbol.for("-")](1):l.layer-1)(),Math.abs(l.mag)));return P((()=>void 0!==t.sign&&null!==t.sign&&t.sign[Symbol.for("*")]?t.sign[Symbol.for("*")](l.sign):t.sign*l.sign)(),(()=>void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1)(),(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag)())}throw Error((()=>"Bad arguments to mul: "+this+", "!==void 0&&"Bad arguments to mul: "+this+", "!==null&&("Bad arguments to mul: "+this+", ")[Symbol.for("+")]?("Bad arguments to mul: "+this+", ")[Symbol.for("+")](e):"Bad arguments to mul: "+this+", "+e)())}multiply(e){return this.mul(e)}times(e){return this.mul(e)}div(e){const o=B(e);return this.mul(o.recip())}divide(e){return this.div(e)}divideBy(e){return this.div(e)}dividedBy(e){return this.div(e)}recip(){return 0===this.mag?O.dNaN:0===this.layer?P(this.sign,0,(()=>1[Symbol.for("/")]?1[Symbol.for("/")](this.mag):1/this.mag)()):P(this.sign,this.layer,(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("minus")]?this.mag[Symbol.for("minus")]():-this.mag)())}reciprocal(){return this.recip()}reciprocate(){return this.recip()}cmp(e){const o=B(e);return(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for(">")]?this.sign[Symbol.for(">")](o.sign):this.sign>o.sign)()?1:(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("<")]?this.sign[Symbol.for("<")](o.sign):this.sign<o.sign)()?(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)():(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.cmpabs(e)):this.sign*this.cmpabs(e))()}cmpabs(e){const o=B(e),t=(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for(">")]?this.mag[Symbol.for(">")](0):this.mag>0)()?this.layer:(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("minus")]?this.layer[Symbol.for("minus")]():-this.layer)(),l=(()=>void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for(">")]?o.mag[Symbol.for(">")](0):o.mag>0)()?o.layer:(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("minus")]?o.layer[Symbol.for("minus")]():-o.layer)();return(()=>void 0!==t&&null!==t&&t[Symbol.for(">")]?t[Symbol.for(">")](l):t>l)()?1:(()=>void 0!==t&&null!==t&&t[Symbol.for("<")]?t[Symbol.for("<")](l):t<l)()?(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)():(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for(">")]?this.mag[Symbol.for(">")](o.mag):this.mag>o.mag)()?1:(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](o.mag):this.mag<o.mag)()?(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)():0}compare(e){return this.cmp(e)}isNan(){return isNaN(this.sign)||isNaN(this.layer)||isNaN(this.mag)}isFinite(){return isFinite(this.sign)&&isFinite(this.layer)&&isFinite(this.mag)}eq(e){const o=B(e);return this.sign===o.sign&&this.layer===o.layer&&this.mag===o.mag}equals(e){return this.eq(e)}neq(e){return(()=>void 0!==this.eq(e)&&null!==this.eq(e)&&this.eq(e)[Symbol.for("!")]?this.eq(e)[Symbol.for("!")]():!this.eq(e))()}notEquals(e){return this.neq(e)}lt(e){return this.cmp(e)===(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()}lte(e){return(()=>void 0!==this.gt(e)&&null!==this.gt(e)&&this.gt(e)[Symbol.for("!")]?this.gt(e)[Symbol.for("!")]():!this.gt(e))()}gt(e){return 1===this.cmp(e)}gte(e){return(()=>void 0!==this.lt(e)&&null!==this.lt(e)&&this.lt(e)[Symbol.for("!")]?this.lt(e)[Symbol.for("!")]():!this.lt(e))()}max(e){const o=B(e);return this.lt(o)?o:this}min(e){const o=B(e);return this.gt(o)?o:this}maxabs(e){const o=B(e);return(()=>void 0!==this.cmpabs(o)&&null!==this.cmpabs(o)&&this.cmpabs(o)[Symbol.for("<")]?this.cmpabs(o)[Symbol.for("<")](0):this.cmpabs(o)<0)()?o:this}minabs(e){const o=B(e);return(()=>void 0!==this.cmpabs(o)&&null!==this.cmpabs(o)&&this.cmpabs(o)[Symbol.for(">")]?this.cmpabs(o)[Symbol.for(">")](0):this.cmpabs(o)>0)()?o:this}clamp(e,o){return this.max(e).min(o)}clampMin(e){return this.max(e)}clampMax(e){return this.min(e)}cmp_tolerance(e,o){const t=B(e);return this.eq_tolerance(t,o)?0:this.cmp(t)}compare_tolerance(e,o){return this.cmp_tolerance(e,o)}eq_tolerance(e,o){const t=B(e);if((()=>void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o)()&&(o=1e-7),(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("!==")]?this.sign[Symbol.for("!==")](t.sign):this.sign!==t.sign)())return!1;if((()=>void 0!==Math.abs(this.layer-t.layer)&&null!==Math.abs(this.layer-t.layer)&&Math.abs(this.layer-t.layer)[Symbol.for(">")]?Math.abs(this.layer-t.layer)[Symbol.for(">")](1):Math.abs(this.layer-t.layer)>1)())return!1;let l=this.mag,n=t.mag;return(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">")]?this.layer[Symbol.for(">")](t.layer):this.layer>t.layer)()&&(n=T(n)),(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("<")]?this.layer[Symbol.for("<")](t.layer):this.layer<t.layer)()&&(l=T(l)),(()=>void 0!==Math.abs(l-n)&&null!==Math.abs(l-n)&&Math.abs(l-n)[Symbol.for("<=")]?Math.abs(l-n)[Symbol.for("<=")](o*Math.max(Math.abs(l),Math.abs(n))):Math.abs(l-n)<=o*Math.max(Math.abs(l),Math.abs(n)))()}equals_tolerance(e,o){return this.eq_tolerance(e,o)}neq_tolerance(e,o){return(()=>void 0!==this.eq_tolerance(e,o)&&null!==this.eq_tolerance(e,o)&&this.eq_tolerance(e,o)[Symbol.for("!")]?this.eq_tolerance(e,o)[Symbol.for("!")]():!this.eq_tolerance(e,o))()}notEquals_tolerance(e,o){return this.neq_tolerance(e,o)}lt_tolerance(e,o){const t=B(e);return(()=>void 0!==this.eq_tolerance(t,o)&&null!==this.eq_tolerance(t,o)&&this.eq_tolerance(t,o)[Symbol.for("!")]?this.eq_tolerance(t,o)[Symbol.for("!")]():!this.eq_tolerance(t,o))()&&this.lt(t)}lte_tolerance(e,o){const t=B(e);return this.eq_tolerance(t,o)||this.lt(t)}gt_tolerance(e,o){const t=B(e);return(()=>void 0!==this.eq_tolerance(t,o)&&null!==this.eq_tolerance(t,o)&&this.eq_tolerance(t,o)[Symbol.for("!")]?this.eq_tolerance(t,o)[Symbol.for("!")]():!this.eq_tolerance(t,o))()&&this.gt(t)}gte_tolerance(e,o){const t=B(e);return this.eq_tolerance(t,o)||this.gt(t)}pLog10(){return this.lt(O.dZero)?O.dZero:this.log10()}absLog10(){return 0===this.sign?O.dNaN:(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">")]?this.layer[Symbol.for(">")](0):this.layer>0)()?P(Math.sign(this.mag),(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),Math.abs(this.mag)):P(1,0,Math.log10(this.mag))}log10(){return(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("<=")]?this.sign[Symbol.for("<=")](0):this.sign<=0)()?O.dNaN:(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">")]?this.layer[Symbol.for(">")](0):this.layer>0)()?P(Math.sign(this.mag),(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),Math.abs(this.mag)):P(this.sign,0,Math.log10(this.mag))}log(e){return e=B(e),(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("<=")]?this.sign[Symbol.for("<=")](0):this.sign<=0)()||(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("<=")]?e.sign[Symbol.for("<=")](0):e.sign<=0)()||1===e.sign&&0===e.layer&&1===e.mag?O.dNaN:0===this.layer&&0===e.layer?P(this.sign,0,(()=>void 0!==Math.log(this.mag)&&null!==Math.log(this.mag)&&Math.log(this.mag)[Symbol.for("/")]?Math.log(this.mag)[Symbol.for("/")](Math.log(e.mag)):Math.log(this.mag)/Math.log(e.mag))()):O.div(this.log10(),e.log10())}log2(){return(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("<=")]?this.sign[Symbol.for("<=")](0):this.sign<=0)()?O.dNaN:0===this.layer?P(this.sign,0,Math.log2(this.mag)):1===this.layer?P(Math.sign(this.mag),0,(()=>void 0!==Math.abs(this.mag)&&null!==Math.abs(this.mag)&&Math.abs(this.mag)[Symbol.for("*")]?Math.abs(this.mag)[Symbol.for("*")](3.321928094887362):3.321928094887362*Math.abs(this.mag))()):2===this.layer?P(Math.sign(this.mag),1,(()=>void 0!==Math.abs(this.mag)&&null!==Math.abs(this.mag)&&Math.abs(this.mag)[Symbol.for("+")]?Math.abs(this.mag)[Symbol.for("+")](.5213902276543247):Math.abs(this.mag)+.5213902276543247)()):P(Math.sign(this.mag),(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),Math.abs(this.mag))}ln(){return(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("<=")]?this.sign[Symbol.for("<=")](0):this.sign<=0)()?O.dNaN:0===this.layer?P(this.sign,0,Math.log(this.mag)):1===this.layer?P(Math.sign(this.mag),0,(()=>void 0!==Math.abs(this.mag)&&null!==Math.abs(this.mag)&&Math.abs(this.mag)[Symbol.for("*")]?Math.abs(this.mag)[Symbol.for("*")](2.302585092994046):2.302585092994046*Math.abs(this.mag))()):2===this.layer?P(Math.sign(this.mag),1,(()=>void 0!==Math.abs(this.mag)&&null!==Math.abs(this.mag)&&Math.abs(this.mag)[Symbol.for("+")]?Math.abs(this.mag)[Symbol.for("+")](.36221568869946325):Math.abs(this.mag)+.36221568869946325)()):P(Math.sign(this.mag),(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),Math.abs(this.mag))}logarithm(e){return this.log(e)}pow(e){const o=B(e),t=this,l=o;if(0===t.sign)return l.eq(0)?E(1,0,1):t;if(1===t.sign&&0===t.layer&&1===t.mag)return t;if(0===l.sign)return E(1,0,1);if(1===l.sign&&0===l.layer&&1===l.mag)return t;const n=t.absLog10().mul(l).pow10();return this.sign===(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()?1===(()=>void 0!==Math.abs(l.toNumber()%2)&&null!==Math.abs(l.toNumber()%2)&&Math.abs(l.toNumber()%2)[Symbol.for("%")]?Math.abs(l.toNumber()%2)[Symbol.for("%")](2):Math.abs(l.toNumber()%2)%2)()?n.neg():0===(()=>void 0!==Math.abs(l.toNumber()%2)&&null!==Math.abs(l.toNumber()%2)&&Math.abs(l.toNumber()%2)[Symbol.for("%")]?Math.abs(l.toNumber()%2)[Symbol.for("%")](2):Math.abs(l.toNumber()%2)%2)()?n:O.dNaN:n}pow10(){if((()=>void 0!==Number.isFinite(this.layer)&&null!==Number.isFinite(this.layer)&&Number.isFinite(this.layer)[Symbol.for("!")]?Number.isFinite(this.layer)[Symbol.for("!")]():!Number.isFinite(this.layer))()||(()=>void 0!==Number.isFinite(this.mag)&&null!==Number.isFinite(this.mag)&&Number.isFinite(this.mag)[Symbol.for("!")]?Number.isFinite(this.mag)[Symbol.for("!")]():!Number.isFinite(this.mag))())return O.dNaN;let e=this;if(0===e.layer){const o=Math.pow(10,(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("*")]?e.sign[Symbol.for("*")](e.mag):e.sign*e.mag)());if(Number.isFinite(o)&&(()=>void 0!==Math.abs(o)&&null!==Math.abs(o)&&Math.abs(o)[Symbol.for(">=")]?Math.abs(o)[Symbol.for(">=")](.1):Math.abs(o)>=.1)())return P(1,0,o);if(0===e.sign)return O.dOne;e=E(e.sign,(()=>void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1)(),Math.log10(e.mag))}return(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for(">")]?e.sign[Symbol.for(">")](0):e.sign>0)()&&(()=>void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for(">=")]?e.mag[Symbol.for(">=")](0):e.mag>=0)()?P(e.sign,(()=>void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1)(),e.mag):(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("<")]?e.sign[Symbol.for("<")](0):e.sign<0)()&&(()=>void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for(">=")]?e.mag[Symbol.for(">=")](0):e.mag>=0)()?P((()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("minus")]?e.sign[Symbol.for("minus")]():-e.sign)(),(()=>void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1)(),(()=>void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("minus")]?e.mag[Symbol.for("minus")]():-e.mag)()):O.dOne}pow_base(e){return B(e).pow(this)}root(e){const o=B(e);return this.pow(o.recip())}factorial(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()||0===this.layer?this.add(1).gamma():1===this.layer?O.exp(O.mul(this,O.ln(this).sub(1))):O.exp(this)}gamma(){if((()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)())return this.recip();if(0===this.layer){if(this.lt(E(1,0,24)))return B(D((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)()));const e=(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("-")]?this.mag[Symbol.for("-")](1):this.mag-1)();let o=.9189385332046727;o=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")]((e+.5)*Math.log(e)):o+(e+.5)*Math.log(e))(),o=(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](e):o-e)();const t=(()=>void 0!==e&&null!==e&&e[Symbol.for("*")]?e[Symbol.for("*")](e):e*e)();let l=e,n=(()=>12[Symbol.for("*")]?12[Symbol.for("*")](l):12*l)(),r=(()=>1[Symbol.for("/")]?1[Symbol.for("/")](n):1/n)(),i=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](r):o+r)();if(i===o)return O.exp(o);if(o=i,l=(()=>void 0!==l&&null!==l&&l[Symbol.for("*")]?l[Symbol.for("*")](t):l*t)(),n=(()=>360[Symbol.for("*")]?360[Symbol.for("*")](l):360*l)(),r=(()=>1[Symbol.for("/")]?1[Symbol.for("/")](n):1/n)(),i=(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](r):o-r)(),i===o)return O.exp(o);o=i,l=(()=>void 0!==l&&null!==l&&l[Symbol.for("*")]?l[Symbol.for("*")](t):l*t)(),n=(()=>1260[Symbol.for("*")]?1260[Symbol.for("*")](l):1260*l)();let a=(()=>1[Symbol.for("/")]?1[Symbol.for("/")](n):1/n)();return o=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](a):o+a)(),l=(()=>void 0!==l&&null!==l&&l[Symbol.for("*")]?l[Symbol.for("*")](t):l*t)(),n=(()=>1680[Symbol.for("*")]?1680[Symbol.for("*")](l):1680*l)(),a=(()=>1[Symbol.for("/")]?1[Symbol.for("/")](n):1/n)(),o=(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](a):o-a)(),O.exp(o)}return 1===this.layer?O.exp(O.mul(this,O.ln(this).sub(1))):O.exp(this)}lngamma(){return this.gamma().ln()}exp(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?O.dOne:0===this.layer&&(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<=")]?this.mag[Symbol.for("<=")](709.7):this.mag<=709.7)()?B(Math.exp((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):0===this.layer?P(1,1,(()=>this.sign*Math.log10(Math.E)!==void 0&&this.sign*Math.log10(Math.E)!==null&&(this.sign*Math.log10(Math.E))[Symbol.for("*")]?(this.sign*Math.log10(Math.E))[Symbol.for("*")](this.mag):this.sign*Math.log10(Math.E)*this.mag)()):1===this.layer?P(1,2,(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](Math.log10(.4342944819032518)+this.mag):this.sign*(Math.log10(.4342944819032518)+this.mag))()):P(1,(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("+")]?this.layer[Symbol.for("+")](1):this.layer+1)(),(()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())}sqr(){return this.pow(2)}sqrt(){if(0===this.layer)return B(Math.sqrt((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)()));if(1===this.layer)return P(1,2,(()=>void 0!==Math.log10(this.mag)&&null!==Math.log10(this.mag)&&Math.log10(this.mag)[Symbol.for("-")]?Math.log10(this.mag)[Symbol.for("-")](.3010299956639812):Math.log10(this.mag)-.3010299956639812)());{const e=O.div(E(this.sign,(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),this.mag),E(1,0,2));return e.layer=(()=>void 0!==e.layer&&null!==e.layer&&e.layer[Symbol.for("+")]?e.layer[Symbol.for("+")](1):e.layer+1)(),e.normalize(),e}}cube(){return this.pow(3)}cbrt(){return this.pow((()=>1[Symbol.for("/")]?1[Symbol.for("/")](3):1/3)())}tetrate(e=2,o=E(1,0,1)){if(1===e)return O.pow(this,o);if(0===e)return new O(o);if(this.eq(O.dOne))return O.dOne;if(this.eq((()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()))return O.pow(this,o);if(e===Number.POSITIVE_INFINITY){const e=this.toNumber();if((()=>void 0!==e&&null!==e&&e[Symbol.for("<=")]?e[Symbol.for("<=")](1.444667861009766):e<=1.444667861009766)()&&(()=>void 0!==e&&null!==e&&e[Symbol.for(">=")]?e[Symbol.for(">=")](.06598803584531254):e>=.06598803584531254)()){if((()=>void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](1.444667861009099):e>1.444667861009099)())return new O(Math.E);const o=O.ln(this).neg();return o.lambertw().div(o)}return(()=>void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](1.444667861009766):e>1.444667861009766)()?new O(Number.POSITIVE_INFINITY):O.dNaN}if(this.eq(O.dZero)){let o=Math.abs((()=>e+1!==void 0&&e+1!==null&&(e+1)[Symbol.for("%")]?(e+1)[Symbol.for("%")](2):(e+1)%2)());return(()=>void 0!==o&&null!==o&&o[Symbol.for(">")]?o[Symbol.for(">")](1):o>1)()&&(o=(()=>2[Symbol.for("-")]?2[Symbol.for("-")](o):2-o)()),new O(o)}if((()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](0):e<0)())return O.iteratedlog(o,this,(()=>void 0!==e&&null!==e&&e[Symbol.for("minus")]?e[Symbol.for("minus")]():-e)());o=B(o);const t=e;e=Math.trunc(e);const l=(()=>void 0!==t&&null!==t&&t[Symbol.for("-")]?t[Symbol.for("-")](e):t-e)();if(this.gt(O.dZero)&&this.lte(1.444667861009766)){e=Math.min(1e4,e);for(let t=0;(()=>void 0!==t&&null!==t&&t[Symbol.for("<")]?t[Symbol.for("<")](e):t<e)();(()=>void 0!==t&&null!==t&&"object"===typeof t&&t[Symbol.for("prefix-increment")]?t[Symbol.for("prefix-increment")]():++t)()){const e=o;if(o=this.pow(o),e.eq(o))return o}if((()=>void 0!==l&&null!==l&&l[Symbol.for("!=")]?l[Symbol.for("!=")](0):0!=l)()){const e=this.pow(o);return o.mul((()=>1[Symbol.for("-")]?1[Symbol.for("-")](l):1-l)()).add(e.mul(l))}return o}(()=>void 0!==l&&null!==l&&l[Symbol.for("!==")]?l[Symbol.for("!==")](0):0!==l)()&&(o.eq(O.dOne)?this.gt(10)?o=this.pow(l):(o=B(O.tetrate_critical(this.toNumber(),l)),this.lt(2)&&(o=o.sub(1).mul(this.minus(1)).plus(1))):o=this.eq(10)?o.layeradd10(l):o.layeradd(l,this));for(let n=0;(()=>void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](e):n<e)();(()=>void 0!==n&&null!==n&&"object"===typeof n&&n[Symbol.for("prefix-increment")]?n[Symbol.for("prefix-increment")]():++n)()){if(o=this.pow(o),(()=>void 0!==isFinite(o.layer)&&null!==isFinite(o.layer)&&isFinite(o.layer)[Symbol.for("!")]?isFinite(o.layer)[Symbol.for("!")]():!isFinite(o.layer))()||(()=>void 0!==isFinite(o.mag)&&null!==isFinite(o.mag)&&isFinite(o.mag)[Symbol.for("!")]?isFinite(o.mag)[Symbol.for("!")]():!isFinite(o.mag))())return o.normalize();if((()=>o.layer-this.layer!==void 0&&o.layer-this.layer!==null&&(o.layer-this.layer)[Symbol.for(">")]?(o.layer-this.layer)[Symbol.for(">")](3):o.layer-this.layer>3)())return E(o.sign,(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](e-n-1):o.layer+(e-n-1))(),o.mag);if((()=>void 0!==n&&null!==n&&n[Symbol.for(">")]?n[Symbol.for(">")](1e4):n>1e4)())return o}return o}iteratedexp(e=2,o=E(1,0,1)){return this.tetrate(e,o)}iteratedlog(e=10,o=1){if((()=>void 0!==o&&null!==o&&o[Symbol.for("<")]?o[Symbol.for("<")](0):o<0)())return O.tetrate(e,(()=>void 0!==o&&null!==o&&o[Symbol.for("minus")]?o[Symbol.for("minus")]():-o)(),this);e=B(e);let t=B(this);const l=o;o=Math.trunc(o);const n=(()=>void 0!==l&&null!==l&&l[Symbol.for("-")]?l[Symbol.for("-")](o):l-o)();if((()=>t.layer-e.layer!==void 0&&t.layer-e.layer!==null&&(t.layer-e.layer)[Symbol.for(">")]?(t.layer-e.layer)[Symbol.for(">")](3):t.layer-e.layer>3)()){const l=Math.min(o,(()=>t.layer-e.layer!==void 0&&t.layer-e.layer!==null&&(t.layer-e.layer)[Symbol.for("-")]?(t.layer-e.layer)[Symbol.for("-")](3):t.layer-e.layer-3)());o=(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](l):o-l)(),t.layer=(()=>void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("-")]?t.layer[Symbol.for("-")](l):t.layer-l)()}for(let r=0;(()=>void 0!==r&&null!==r&&r[Symbol.for("<")]?r[Symbol.for("<")](o):r<o)();(()=>void 0!==r&&null!==r&&"object"===typeof r&&r[Symbol.for("prefix-increment")]?r[Symbol.for("prefix-increment")]():++r)()){if(t=t.log(e),(()=>void 0!==isFinite(t.layer)&&null!==isFinite(t.layer)&&isFinite(t.layer)[Symbol.for("!")]?isFinite(t.layer)[Symbol.for("!")]():!isFinite(t.layer))()||(()=>void 0!==isFinite(t.mag)&&null!==isFinite(t.mag)&&isFinite(t.mag)[Symbol.for("!")]?isFinite(t.mag)[Symbol.for("!")]():!isFinite(t.mag))())return t.normalize();if((()=>void 0!==r&&null!==r&&r[Symbol.for(">")]?r[Symbol.for(">")](1e4):r>1e4)())return t}return(()=>void 0!==n&&null!==n&&n[Symbol.for(">")]?n[Symbol.for(">")](0):n>0)()&&(()=>void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](1):n<1)()&&(t=e.eq(10)?t.layeradd10((()=>void 0!==n&&null!==n&&n[Symbol.for("minus")]?n[Symbol.for("minus")]():-n)()):t.layeradd((()=>void 0!==n&&null!==n&&n[Symbol.for("minus")]?n[Symbol.for("minus")]():-n)(),e)),t}slog(e=10){if(e=B(e),e.lte(O.dZero))return O.dNaN;if(e.eq(O.dOne))return O.dNaN;if(e.lt(O.dOne))return this.eq(O.dOne)?O.dZero:this.eq(O.dZero)?O.dNegOne:O.dNaN;if((()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()||this.eq(O.dZero))return O.dNegOne;let o=0,t=B(this);if((()=>t.layer-e.layer!==void 0&&t.layer-e.layer!==null&&(t.layer-e.layer)[Symbol.for(">")]?(t.layer-e.layer)[Symbol.for(">")](3):t.layer-e.layer>3)()){const l=(()=>t.layer-e.layer!==void 0&&t.layer-e.layer!==null&&(t.layer-e.layer)[Symbol.for("-")]?(t.layer-e.layer)[Symbol.for("-")](3):t.layer-e.layer-3)();o=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](l):o+l)(),t.layer=(()=>void 0!==t.layer&&null!==t.layer&&t.layer[Symbol.for("-")]?t.layer[Symbol.for("-")](l):t.layer-l)()}for(let l=0;(()=>void 0!==l&&null!==l&&l[Symbol.for("<")]?l[Symbol.for("<")](100):l<100)();(()=>void 0!==l&&null!==l&&"object"===typeof l&&l[Symbol.for("prefix-increment")]?l[Symbol.for("prefix-increment")]():++l)())if(t.lt(O.dZero))t=O.pow(e,t),o=(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](1):o-1)();else{if(t.lte(O.dOne))return B((()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](O.slog_critical(e.toNumber(),t.toNumber())):o+O.slog_critical(e.toNumber(),t.toNumber()))());o=(()=>void 0!==o&&null!==o&&o[Symbol.for("+")]?o[Symbol.for("+")](1):o+1)(),t=O.log(t,e)}return B(o)}static slog_critical(e,o){return(()=>void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](10):e>10)()?(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](1):o-1)():O.critical_section(e,o,Z)}static tetrate_critical(e,o){return O.critical_section(e,o,w)}static critical_section(e,o,t){o=(()=>void 0!==o&&null!==o&&o[Symbol.for("*")]?o[Symbol.for("*")](10):10*o)(),(()=>void 0!==o&&null!==o&&o[Symbol.for("<")]?o[Symbol.for("<")](0):o<0)()&&(o=0),(()=>void 0!==o&&null!==o&&o[Symbol.for(">")]?o[Symbol.for(">")](10):o>10)()&&(o=10),(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](2):e<2)()&&(e=2),(()=>void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](10):e>10)()&&(e=10);let l=0,n=0;for(let a=0;(()=>void 0!==a&&null!==a&&a[Symbol.for("<")]?a[Symbol.for("<")](C.length):a<C.length)();(()=>void 0!==a&&null!==a&&"object"===typeof a&&a[Symbol.for("prefix-increment")]?a[Symbol.for("prefix-increment")]():++a)()){if((()=>void 0!==C[a]&&null!==C[a]&&C[a][Symbol.for("==")]?C[a][Symbol.for("==")](e):C[a]==e)()){l=t[a][Math.floor(o)],n=t[a][Math.ceil(o)];break}if((()=>void 0!==C[a]&&null!==C[a]&&C[a][Symbol.for("<")]?C[a][Symbol.for("<")](e):C[a]<e)()&&(()=>void 0!==C[a+1]&&null!==C[a+1]&&C[a+1][Symbol.for(">")]?C[a+1][Symbol.for(">")](e):C[a+1]>e)()){const r=(()=>e-C[a]!==void 0&&e-C[a]!==null&&(e-C[a])[Symbol.for("/")]?(e-C[a])[Symbol.for("/")](C[a+1]-C[a]):(e-C[a])/(C[a+1]-C[a]))();l=(()=>t[a][Math.floor(o)]*(1-r)!==void 0&&t[a][Math.floor(o)]*(1-r)!==null&&(t[a][Math.floor(o)]*(1-r))[Symbol.for("+")]?(t[a][Math.floor(o)]*(1-r))[Symbol.for("+")](t[a+1][Math.floor(o)]*r):t[a][Math.floor(o)]*(1-r)+t[a+1][Math.floor(o)]*r)(),n=(()=>t[a][Math.ceil(o)]*(1-r)!==void 0&&t[a][Math.ceil(o)]*(1-r)!==null&&(t[a][Math.ceil(o)]*(1-r))[Symbol.for("+")]?(t[a][Math.ceil(o)]*(1-r))[Symbol.for("+")](t[a+1][Math.ceil(o)]*r):t[a][Math.ceil(o)]*(1-r)+t[a+1][Math.ceil(o)]*r)();break}}const r=(()=>void 0!==o&&null!==o&&o[Symbol.for("-")]?o[Symbol.for("-")](Math.floor(o)):o-Math.floor(o))(),i=(()=>l*(1-r)!==void 0&&l*(1-r)!==null&&(l*(1-r))[Symbol.for("+")]?(l*(1-r))[Symbol.for("+")](n*r):l*(1-r)+n*r)();return i}layeradd10(e){e=O.fromValue_noAlloc(e).toNumber();const o=B(this);if((()=>void 0!==e&&null!==e&&e[Symbol.for(">=")]?e[Symbol.for(">=")](1):e>=1)()){(()=>void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("<")]?o.mag[Symbol.for("<")](0):o.mag<0)()&&(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">")]?o.layer[Symbol.for(">")](0):o.layer>0)()?(o.sign=0,o.mag=0,o.layer=0):o.sign===(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()&&(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("==")]?o.layer[Symbol.for("==")](0):0==o.layer)()&&(o.sign=1,o.mag=(()=>void 0!==o.mag&&null!==o.mag&&o.mag[Symbol.for("minus")]?o.mag[Symbol.for("minus")]():-o.mag)());const t=Math.trunc(e);e=(()=>void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](t):e-t)(),o.layer=(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](t):o.layer+t)()}if((()=>void 0!==e&&null!==e&&e[Symbol.for("<=")]?e[Symbol.for("<=")](-1):e<=-1)()){const t=Math.trunc(e);if(e=(()=>void 0!==e&&null!==e&&e[Symbol.for("-")]?e[Symbol.for("-")](t):e-t)(),o.layer=(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("+")]?o.layer[Symbol.for("+")](t):o.layer+t)(),(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](0):o.layer<0)())for(let e=0;(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](100):e<100)();(()=>void 0!==e&&null!==e&&"object"===typeof e&&e[Symbol.for("prefix-increment")]?e[Symbol.for("prefix-increment")]():++e)()){if((()=>{void 0!==o.layer&&null!==o.layer&&"object"===typeof o.layer&&o.layer[Symbol.for("postfix-increment")]?o.layer[Symbol.for("postfix-increment")]():o.layer++})(),o.mag=Math.log10(o.mag),(()=>void 0!==isFinite(o.mag)&&null!==isFinite(o.mag)&&isFinite(o.mag)[Symbol.for("!")]?isFinite(o.mag)[Symbol.for("!")]():!isFinite(o.mag))())return 0===o.sign&&(o.sign=1),(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](0):o.layer<0)()&&(o.layer=0),o.normalize();if((()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">=")]?o.layer[Symbol.for(">=")](0):o.layer>=0)())break}}while((()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("<")]?o.layer[Symbol.for("<")](0):o.layer<0)())(()=>{void 0!==o.layer&&null!==o.layer&&"object"===typeof o.layer&&o.layer[Symbol.for("postfix-increment")]?o.layer[Symbol.for("postfix-increment")]():o.layer++})(),o.mag=Math.log10(o.mag);return 0===o.sign&&(o.sign=1,0===o.mag&&(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for(">=")]?o.layer[Symbol.for(">=")](1):o.layer>=1)()&&(o.layer=(()=>void 0!==o.layer&&null!==o.layer&&o.layer[Symbol.for("-")]?o.layer[Symbol.for("-")](1):o.layer-1)(),o.mag=1)),o.normalize(),(()=>void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](0):0!==e)()?o.layeradd(e,10):o}layeradd(e,o){const t=this.slog(o).toNumber(),l=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](e):t+e)();return(()=>void 0!==l&&null!==l&&l[Symbol.for(">=")]?l[Symbol.for(">=")](0):l>=0)()?O.tetrate(o,l):(()=>void 0!==Number.isFinite(l)&&null!==Number.isFinite(l)&&Number.isFinite(l)[Symbol.for("!")]?Number.isFinite(l)[Symbol.for("!")]():!Number.isFinite(l))()?O.dNaN:(()=>void 0!==l&&null!==l&&l[Symbol.for(">=")]?l[Symbol.for(">=")](-1):l>=-1)()?O.log(O.tetrate(o,(()=>void 0!==l&&null!==l&&l[Symbol.for("+")]?l[Symbol.for("+")](1):l+1)()),o):O.log(O.log(O.tetrate(o,(()=>void 0!==l&&null!==l&&l[Symbol.for("+")]?l[Symbol.for("+")](2):l+2)()),o),o)}lambertw(){if(this.lt((()=>.3678794411710499[Symbol.for("minus")]?.3678794411710499[Symbol.for("minus")]():-.3678794411710499)()))throw Error("lambertw is unimplemented for results less than -1, sorry!");if((()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)())return B(R(this.toNumber()));if(0===this.layer)return B(R((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)()));if(1===this.layer)return _(this);if(2===this.layer)return _(this);if((()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">=")]?this.layer[Symbol.for(">=")](3):this.layer>=3)())return E(this.sign,(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),this.mag);throw"Unhandled behavior in lambertw()"}ssqrt(){if((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("==")]?this.sign[Symbol.for("==")](1):1==this.sign)()&&(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for(">=")]?this.layer[Symbol.for(">=")](3):this.layer>=3)())return E(this.sign,(()=>void 0!==this.layer&&null!==this.layer&&this.layer[Symbol.for("-")]?this.layer[Symbol.for("-")](1):this.layer-1)(),this.mag);const e=this.ln();return e.div(e.lambertw())}pentate(e=2,o=E(1,0,1)){o=B(o);const t=e;e=Math.trunc(e);const l=(()=>void 0!==t&&null!==t&&t[Symbol.for("-")]?t[Symbol.for("-")](e):t-e)();(()=>void 0!==l&&null!==l&&l[Symbol.for("!==")]?l[Symbol.for("!==")](0):0!==l)()&&(o.eq(O.dOne)?((()=>{void 0!==e&&null!==e&&"object"===typeof e&&e[Symbol.for("prefix-increment")]?e[Symbol.for("prefix-increment")]():++e})(),o=new O(l)):o=this.eq(10)?o.layeradd10(l):o.layeradd(l,this));for(let n=0;(()=>void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](e):n<e)();(()=>void 0!==n&&null!==n&&"object"===typeof n&&n[Symbol.for("prefix-increment")]?n[Symbol.for("prefix-increment")]():++n)()){if(o=this.tetrate(o.toNumber()),(()=>void 0!==isFinite(o.layer)&&null!==isFinite(o.layer)&&isFinite(o.layer)[Symbol.for("!")]?isFinite(o.layer)[Symbol.for("!")]():!isFinite(o.layer))()||(()=>void 0!==isFinite(o.mag)&&null!==isFinite(o.mag)&&isFinite(o.mag)[Symbol.for("!")]?isFinite(o.mag)[Symbol.for("!")]():!isFinite(o.mag))())return o.normalize();if((()=>void 0!==n&&null!==n&&n[Symbol.for(">")]?n[Symbol.for(">")](10):n>10)())return o}return o}sin(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?this:0===this.layer?B(Math.sin((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):E(0,0,0)}cos(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?O.dOne:0===this.layer?B(Math.cos((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):E(0,0,0)}tan(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?this:0===this.layer?B(Math.tan((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):E(0,0,0)}asin(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?this:0===this.layer?B(Math.asin((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):E(Number.NaN,Number.NaN,Number.NaN)}acos(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?B(Math.acos(this.toNumber())):0===this.layer?B(Math.acos((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):E(Number.NaN,Number.NaN,Number.NaN)}atan(){return(()=>void 0!==this.mag&&null!==this.mag&&this.mag[Symbol.for("<")]?this.mag[Symbol.for("<")](0):this.mag<0)()?this:0===this.layer?B(Math.atan((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](this.mag):this.sign*this.mag)())):B(Math.atan((()=>void 0!==this.sign&&null!==this.sign&&this.sign[Symbol.for("*")]?this.sign[Symbol.for("*")](Infinity):Infinity*this.sign)()))}sinh(){return this.exp().sub(this.negate().exp()).div(2)}cosh(){return this.exp().add(this.negate().exp()).div(2)}tanh(){return this.sinh().div(this.cosh())}asinh(){return O.ln(this.add(this.sqr().add(1).sqrt()))}acosh(){return O.ln(this.add(this.sqr().sub(1).sqrt()))}atanh(){return this.abs().gte(1)?E(Number.NaN,Number.NaN,Number.NaN):O.ln(this.add(1).div(B(1).sub(this))).div(2)}ascensionPenalty(e){return 0===e?this:this.root(O.pow(10,e))}egg(){return this.add(9)}lessThanOrEqualTo(e){return(()=>void 0!==this.cmp(e)&&null!==this.cmp(e)&&this.cmp(e)[Symbol.for("<")]?this.cmp(e)[Symbol.for("<")](1):this.cmp(e)<1)()}lessThan(e){return(()=>void 0!==this.cmp(e)&&null!==this.cmp(e)&&this.cmp(e)[Symbol.for("<")]?this.cmp(e)[Symbol.for("<")](0):this.cmp(e)<0)()}greaterThanOrEqualTo(e){return(()=>void 0!==this.cmp(e)&&null!==this.cmp(e)&&this.cmp(e)[Symbol.for(">")]?this.cmp(e)[Symbol.for(">")](-1):this.cmp(e)>-1)()}greaterThan(e){return(()=>void 0!==this.cmp(e)&&null!==this.cmp(e)&&this.cmp(e)[Symbol.for(">")]?this.cmp(e)[Symbol.for(">")](0):this.cmp(e)>0)()}}(0,n.Z)(O,"dZero",E(0,0,0)),(0,n.Z)(O,"dOne",E(1,0,1)),(0,n.Z)(O,"dNegOne",E((()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),0,1)),(0,n.Z)(O,"dTwo",E(1,0,2)),(0,n.Z)(O,"dTen",E(1,0,10)),(0,n.Z)(O,"dNaN",E(Number.NaN,Number.NaN,Number.NaN)),(0,n.Z)(O,"dInf",E(1,Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY)),(0,n.Z)(O,"dNegInf",E((()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)(),Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY)),(0,n.Z)(O,"dNumberMax",P(1,0,Number.MAX_VALUE)),(0,n.Z)(O,"dNumberMin",P(1,0,Number.MIN_VALUE));var U=t(6453),j=O;const A=new O(1);function q(e,o,t=!0){let l=O.log10(e).floor(),n=O.div(e,O.pow(10,l));"10"===n.toStringWithDecimalPlaces(o)&&(n=A,l=l.add(1));const r=l.gte(1e9)?ee(l,Math.max(Math.max(o,3),U.defaultDecimalsShown)):l.gte(1e4)?z(l,0):l.toStringWithDecimalPlaces(0);return t?(()=>n.toStringWithDecimalPlaces(o)+"e"!==void 0&&n.toStringWithDecimalPlaces(o)+"e"!==null&&(n.toStringWithDecimalPlaces(o)+"e")[Symbol.for("+")]?(n.toStringWithDecimalPlaces(o)+"e")[Symbol.for("+")](r):n.toStringWithDecimalPlaces(o)+"e"+r)():(()=>"e"[Symbol.for("+")]?"e"[Symbol.for("+")](r):"e"+r)()}function z(e,o){if(null===e||void 0===e)return"NaN";if(e=new O(e),(()=>void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](.001):e.mag<.001)())return(0).toFixed(o);const t=e.toStringWithDecimalPlaces(o),l=t.split(".");return l[0]=l[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1,"),(()=>void 0!==l.length&&null!==l.length&&l.length[Symbol.for("==")]?l.length[Symbol.for("==")](1):1==l.length)()?l[0]:(()=>l[0]+"."!==void 0&&l[0]+"."!==null&&(l[0]+".")[Symbol.for("+")]?(l[0]+".")[Symbol.for("+")](l[1]):l[0]+"."+l[1])()}function L(e,o){return null===e||void 0===e?"NaN":(e=new O(e),(()=>void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](1e-4):e.mag<1e-4)()?(0).toFixed(o):((()=>void 0!==e.mag&&null!==e.mag&&e.mag[Symbol.for("<")]?e.mag[Symbol.for("<")](.1):e.mag<.1)()&&(()=>void 0!==o&&null!==o&&o[Symbol.for("!==")]?o[Symbol.for("!==")](0):0!==o)()&&(o=Math.max(Math.max(o,e.log10().negate().ceil().toNumber()),U.defaultDecimalsShown)),e.toStringWithDecimalPlaces(o)))}const G=new O("eeee1000"),H=new O("e100000"),W=new O("e1000"),$=new O(1e9),Y=new O(1e6),K=new O(1e3),Q=new O(.98),J=new O(.001),X=new O(0);function ee(e,o,t){if((()=>void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o)()&&(o=U.defaultDecimalsShown),t=t??U.defaultShowSmall,e=new O(e),isNaN(e.sign)||isNaN(e.layer)||isNaN(e.mag))return"NaN";if((()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("<")]?e.sign[Symbol.for("<")](0):e.sign<0)())return(()=>"-"[Symbol.for("+")]?"-"[Symbol.for("+")](ee(e.neg(),o)):"-"+ee(e.neg(),o))();if(e.mag===Number.POSITIVE_INFINITY)return"Infinity";if(e.gte(G)){const o=e.slog();return o.gte(Y)?(()=>"F"[Symbol.for("+")]?"F"[Symbol.for("+")](ee(o.floor())):"F"+ee(o.floor()))():(()=>O.pow(10,o.sub(o.floor())).toStringWithDecimalPlaces(3)+"F"!==void 0&&O.pow(10,o.sub(o.floor())).toStringWithDecimalPlaces(3)+"F"!==null&&(O.pow(10,o.sub(o.floor())).toStringWithDecimalPlaces(3)+"F")[Symbol.for("+")]?(O.pow(10,o.sub(o.floor())).toStringWithDecimalPlaces(3)+"F")[Symbol.for("+")](z(o.floor(),0)):O.pow(10,o.sub(o.floor())).toStringWithDecimalPlaces(3)+"F"+z(o.floor(),0))()}if(e.gte(H))return q(e,0,!1);if(e.gte(W))return q(e,0);if(e.gte($))return q(e,o);if(e.gte(K))return z(e,0);if(e.gte(J)||(()=>void 0!==t&&null!==t&&t[Symbol.for("!")]?t[Symbol.for("!")]():!t)())return L(e,o);if(e.eq(X))return(0).toFixed(o);if(e=re(e),e.lt(W)){const t=q(e,o);return t.replace(/([^(?:e|F)]*)$/,"-$1")}return(()=>void 0!==ee(e,o)&&null!==ee(e,o)&&ee(e,o)[Symbol.for("+")]?ee(e,o)[Symbol.for("+")]("⁻¹"):ee(e,o)+"⁻¹")()}function oe(e){return e=new O(e),(()=>void 0!==e.sign&&null!==e.sign&&e.sign[Symbol.for("<")]?e.sign[Symbol.for("<")](0):e.sign<0)()?(()=>"-"[Symbol.for("+")]?"-"[Symbol.for("+")](oe(e.neg())):"-"+oe(e.neg()))():e.gte($)||e.lte(Q)&&(()=>void 0!==e.eq(X)&&null!==e.eq(X)&&e.eq(X)[Symbol.for("!")]?e.eq(X)[Symbol.for("!")]():!e.eq(X))()?ee(e):ee(e,0)}function te(e){return O.lt(e,0)?(()=>"-"[Symbol.for("+")]?"-"[Symbol.for("+")](te(O.neg(e))):"-"+te(O.neg(e)))():O.gt(e,(()=>2[Symbol.for("**")]?2[Symbol.for("**")](51):2**51)())?(()=>void 0!==ee(O.div(e,31536e3))&&null!==ee(O.div(e,31536e3))&&ee(O.div(e,31536e3))[Symbol.for("+")]?ee(O.div(e,31536e3))[Symbol.for("+")]("y"):ee(O.div(e,31536e3))+"y")():(e=new O(e).toNumber(),(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](60):e<60)()?(()=>void 0!==ee(e)&&null!==ee(e)&&ee(e)[Symbol.for("+")]?ee(e)[Symbol.for("+")]("s"):ee(e)+"s")():(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](3600):e<3600)()?(()=>oe(Math.floor(e/60))+"m "+ee(e%60)!==void 0&&oe(Math.floor(e/60))+"m "+ee(e%60)!==null&&(oe(Math.floor(e/60))+"m "+ee(e%60))[Symbol.for("+")]?(oe(Math.floor(e/60))+"m "+ee(e%60))[Symbol.for("+")]("s"):oe(Math.floor(e/60))+"m "+ee(e%60)+"s")():(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](86400):e<86400)()?(()=>oe(Math.floor(e/3600))+"h "+oe(Math.floor(e/60)%60)+"m "+oe(e%60)!==void 0&&oe(Math.floor(e/3600))+"h "+oe(Math.floor(e/60)%60)+"m "+oe(e%60)!==null&&(oe(Math.floor(e/3600))+"h "+oe(Math.floor(e/60)%60)+"m "+oe(e%60))[Symbol.for("+")]?(oe(Math.floor(e/3600))+"h "+oe(Math.floor(e/60)%60)+"m "+oe(e%60))[Symbol.for("+")]("s"):oe(Math.floor(e/3600))+"h "+oe(Math.floor(e/60)%60)+"m "+oe(e%60)+"s")():(()=>void 0!==e&&null!==e&&e[Symbol.for("<")]?e[Symbol.for("<")](31536e3):e<31536e3)()?(()=>oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)+"h "+oe(Math.floor(e/60)%60)!==void 0&&oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)+"h "+oe(Math.floor(e/60)%60)!==null&&(oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)+"h "+oe(Math.floor(e/60)%60))[Symbol.for("+")]?(oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)+"h "+oe(Math.floor(e/60)%60))[Symbol.for("+")]("m"):oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)+"h "+oe(Math.floor(e/60)%60)+"m")():(()=>oe(Math.floor(e/31536e3))+"y "+oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)!==void 0&&oe(Math.floor(e/31536e3))+"y "+oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)!==null&&(oe(Math.floor(e/31536e3))+"y "+oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24))[Symbol.for("+")]?(oe(Math.floor(e/31536e3))+"y "+oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24))[Symbol.for("+")]("h"):oe(Math.floor(e/31536e3))+"y "+oe(Math.floor(e/84600)%365)+"d "+oe(Math.floor(e/3600)%24)+"h")())}function le(e,o,t){e=new O(e);let l=e.toStringWithDecimalPlaces(o);return new O(l).gte(t)&&(l=O.sub(t,Math.pow(.1,o)).toStringWithDecimalPlaces(o)),l}function ne(e,o){return ee(e,o,!0)}function re(e){let o=O.log10(e).ceil();const t=O.div(e,O.pow(10,o));return o=o.neg(),e=new O(10).pow(o).times(t),e}const{exponentialFormat:ie,commaFormat:ae,regularFormat:se,format:ue,formatWhole:me,formatTime:ce,toPlaces:fe,formatSmall:de,invertOOM:ye}=l;window.Decimal=j,window.exponentialFormat=ie,window.commaFormat=ae,window.regularFormat=se,window.format=ue,window.formatWhole=me,window.formatTime=ce,window.toPlaces=fe,window.formatSmall=de,window.invertOOM=ye;var be=j},1349:function(e,o,t){"use strict";function l(e){let o=e.replace(/([A-Z])/g," $1");return o=(()=>void 0!==o.charAt(0).toUpperCase()&&null!==o.charAt(0).toUpperCase()&&o.charAt(0).toUpperCase()[Symbol.for("+")]?o.charAt(0).toUpperCase()[Symbol.for("+")](o.slice(1)):o.charAt(0).toUpperCase()+o.slice(1))(),o}function n(e){return"[object Object]"===Object.prototype.toString.call(e)}function r(e){return"function"===typeof e}var i;t.d(o,{IJ:function(){return l},PO:function(){return n},mf:function(){return r},Nm:function(){return i}}),function(e){e["Up"]="Up",e["Down"]="Down",e["Left"]="Left",e["Right"]="Right",e["Default"]="Up"}(i||(i={}))},9583:function(e,o,t){"use strict";t.d(o,{mM:function(){return r},yB:function(){return i},UI:function(){return a}});var l=t(4865),n=t(1349);const r=Symbol("DoNotCache");function i(e,o){const t=e[o];(0,n.mf)(t)&&0===t.length&&(()=>void 0!==t[r]&&null!==t[r]&&t[r][Symbol.for("!")]?t[r][Symbol.for("!")]():!t[r])()&&(e[o]=(0,l.computed)(t.bind(e)))}function a(e){return(0,n.mf)(e)&&(()=>void 0!==e[r]&&null!==e[r]&&e[r][Symbol.for("!")]?e[r][Symbol.for("!")]():!e[r])()&&(e=(0,l.computed)(e)),e}},3273:function(e,o,t){"use strict";t.d(o,{Le:function(){return l},c4:function(){return n},z2:function(){return r}});const l=Symbol("ProxyState"),n=Symbol("ProxyPath");function r(e,o={}){const t=o;let n=!1;function r(){return(()=>void 0!==n&&null!==n&&n[Symbol.for("!")]?n[Symbol.for("!")]():!n)()&&(Object.assign(t,e(t)),n=!0),t}return new Proxy(t,{get(e,o){return o===l?r():r()[o]},set(e,o,t){return r()[o]=t,!0},has(e,o){return o===l||Reflect.has(r(),o)},ownKeys(){return Reflect.ownKeys(r())},getOwnPropertyDescriptor(o,l){return(()=>void 0!==n&&null!==n&&n[Symbol.for("!")]?n[Symbol.for("!")]():!n)()&&(Object.assign(t,e(t)),n=!0),Object.getOwnPropertyDescriptor(o,l)}})}},463:function(e,o,t){"use strict";t.d(o,{a1:function(){return m},zD:function(){return c},xM:function(){return f},QI:function(){return d},uW:function(){return y},y6:function(){return b}});t(2801);var l=t(6453),n=t(5967),r=t(9266),i=t(3273),a=t(6961),s=t.n(a);function u(e={}){return Object.assign({id:`${l.id}-0`,name:"Default Save",tabs:l.initialTabs.slice(),time:Date.now(),autosave:!0,offlineProd:!0,offlineTime:0,timePlayed:0,keepGoing:!1,modID:l.id,modVersion:l.versionNumber,layers:{}},e)}function m(e){const o=s().compressToUTF16((0,n.U)(e??n.Z[i.Le]));return localStorage.setItem((e??n.Z[i.Le]).id,o),o}async function c(){(0,r.ri)();try{let e=localStorage.getItem(r.ZP.active);if((()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)())return void await y(f());if("{"===e[0]);else if("e"===e[0])e=decodeURIComponent(escape(atob(e)));else{if("ᯡ"!==e[0])throw"Unable to determine save encoding";e=s().decompressFromUTF16(e)}const o=JSON.parse(e);if((()=>void 0!==o.modID&&null!==o.modID&&o.modID[Symbol.for("!==")]?o.modID[Symbol.for("!==")](l.id):o.modID!==l.id)())return void await y(f());o.id=r.ZP.active,await y(o)}catch(e){console.error("Failed to load save. Falling back to new save.\n",e),await y(f())}}function f(){const e=d(),o=u({id:e});return m(o),r.ZP.saves.push(e),o}function d(){let e,o=0;do{e=`${l.id}-${(()=>void 0!==o&&null!==o&&"object"===typeof o&&o[Symbol.for("postfix-increment")]?o[Symbol.for("postfix-increment")]():o++)()}`}while(localStorage.getItem(e));return e}async function y(e){console.info("Loading save",e);const{layers:o,removeLayer:i,addLayer:a}=await Promise.resolve().then(t.bind(t,9365)),{fixOldSave:s,getInitialLayers:m}=await Promise.resolve().then(t.bind(t,504));for(const t in o){const e=o[t];e&&i(e)}m(e).forEach((o=>a(o,e))),e=u(e),e.offlineProd&&e.time&&((()=>void 0!==e.offlineTime&&null!==e.offlineTime&&e.offlineTime[Symbol.for("==")]?e.offlineTime[Symbol.for("==")](void 0):void 0==e.offlineTime)()&&(e.offlineTime=0),e.offlineTime=(()=>void 0!==e.offlineTime&&null!==e.offlineTime&&e.offlineTime[Symbol.for("+")]?e.offlineTime[Symbol.for("+")]((Date.now()-e.time)/1e3):e.offlineTime+(Date.now()-e.time)/1e3)()),e.time=Date.now(),(()=>void 0!==e.modVersion&&null!==e.modVersion&&e.modVersion[Symbol.for("!==")]?e.modVersion[Symbol.for("!==")](l.versionNumber):e.modVersion!==l.versionNumber)()&&s(e.modVersion,e),Object.assign(n.Z,e),r.ZP.active=n.Z.id}setInterval((()=>{n.Z.autosave&&m()}),1e3),window.onbeforeunload=()=>{n.Z.autosave&&m()},window.save=m;const b=window.hardReset=async()=>{await y(f())}},504:function(e,o,t){"use strict";t.r(o),t.d(o,{fixOldSave:function(){return sl},getInitialLayers:function(){return il},hasWon:function(){return al},main:function(){return rl}});var l=t(4865);const n=e=>((0,l.pushScopeId)("data-v-07150322"),e=e(),(0,l.popScopeId)(),e),r=n((()=>(0,l.createElementVNode)("svg",{id:"eaRe02fYmMp1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 228 521","shape-rendering":"geometricPrecision","text-rendering":"geometricPrecision"},[(0,l.createElementVNode)("g",{id:"P"},[(0,l.createElementVNode)("path",{d:"m 101,512.877 c -17.547386,-5.3519 -50.794681,-10.26296 -80,0 10.737201,-217.43031 5.7244,-300.999 0,-464.9995 0,0 46.6144,-37.1164 80,-42.00002 33.386,-4.883633 86.025,10.45942 120,50.00002 5,30 -4.353,106.6565 -44,156.0005 -34.149,42.5 -130,38.48 -130,92.999 0,102 54,208 54,208 z",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"10","stroke-linecap":"round","stroke-miterlimit":"16"},id:"trunk",class:"svg-elem-1"}),(0,l.createElementVNode)("path",{d:"M 221,55.8775 C 209.023,126.453 185.39,166.835 158.997,191.5 93.783098,252.444 11.718998,217.436 46.999998,304.877",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"vine2",class:"svg-elem-2"}),(0,l.createElementVNode)("path",{d:"m 194.5,188 c -11.225,4.447 -19.066,5.134 -35.503,3.5",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine4",class:"svg-elem-3"}),(0,l.createElementVNode)("path",{d:"M 73.499996,246.5 C 111.145,245.626 127.011,238.775 156.5,228",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine3",class:"svg-elem-4"}),(0,l.createElementVNode)("path",{d:"M 221,55.8775 C 169.5,17.8262 86.0943,44.9468 47,107 c -4.743,7.528 -7.1041,15.373 -8.326,24 -3.5282,24.91 2.4426,56.34 -12.0011,105.5",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"vine1",class:"svg-elem-5"}),(0,l.createElementVNode)("path",{d:"M 21,47.8775 38.674,131",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine2",class:"svg-elem-6"}),(0,l.createElementVNode)("path",{d:"m 3,326.5 c 13.1783,22.208 16.4863,42.834 21.6997,81",style:{display:"inline",fill:"none",stroke:"rgb(163, 190, 140)","stroke-width":"5","stroke-linecap":"round","stroke-miterlimit":"16"},id:"short_vine1",class:"svg-elem-7"})])],(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));function i(e,o){return(0,l.openBlock)(),(0,l.createBlock)(l.Transition,{appear:""},{default:(0,l.withCtx)((()=>[r])),_:1})}var a=t(3744);const s={},u=(0,a.Z)(s,[["render",i],["__scopeId","data-v-07150322"]]);var m=u,c=(0,l.defineComponent)({props:{width:{default:"8px"},height:{default:"17px"}},setup(e){return(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{style:(0,l.normalizeStyle)({width:e.width,height:e.height})},null,4))}});const f=c;var d=f,y=t(6113),b=t(5613),h=t(7302),p=t(4061);function v(e,o="points",t=0,n){const r=(0,l.isRef)(e)?e:(0,p.ax)(e);return r.displayName=o,r.precision=t,r.small=n,r}function g(e){const o=(0,p.ax)(e.value);return(0,l.watch)(e,(e=>{b.ZP.gt(e,o.value)&&(o.value=e)})),o}function S(e){const o=(0,p.ax)(e.value);return(0,l.watch)(e,((e,t)=>{b.ZP.gt(e,t)&&(o.value=b.ZP.add(o.value,b.ZP.sub(e,t)))})),o}const N=new b.ZP("10^^8"),k=new b.ZP("1e100");function V(e,o){const t=(0,l.ref)(0),n=(0,l.ref)(0),r=(0,l.ref)(0);h.globalBus.on("update",(o=>{if(n.value=0,b.ZP.lte(e.value,k))return void(r.value=e.value);let l=e.value,i=r.value;if(r.value=l,b.ZP.gt(l,i))if(b.ZP.gte(l,N))l=b.ZP.slog(l,1e10),i=b.ZP.slog(i,1e10),t.value=l.sub(i).div(o),n.value=(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)();else while(b.ZP.div(l,i).log(10).div(o).gte("100")&&(()=>void 0!==n.value&&null!==n.value&&n.value[Symbol.for("<=")]?n.value[Symbol.for("<=")](5):n.value<=5)()&&b.ZP.gt(i,0))l=b.ZP.log10(l),i=b.ZP.log10(i),t.value=l.sub(i).div(o),(()=>{void 0!==n.value&&null!==n.value&&"object"===typeof n.value&&n.value[Symbol.for("postfix-increment")]?n.value[Symbol.for("postfix-increment")]():n.value++})()}));const i=(0,l.computed)((()=>0===n.value?o?(()=>(0,b.WU)(o.value,e.precision,e.small)+" "+e.displayName!==void 0&&(0,b.WU)(o.value,e.precision,e.small)+" "+e.displayName!==null&&((0,b.WU)(o.value,e.precision,e.small)+" "+e.displayName)[Symbol.for("+")]?((0,b.WU)(o.value,e.precision,e.small)+" "+e.displayName)[Symbol.for("+")]("/s"):(0,b.WU)(o.value,e.precision,e.small)+" "+e.displayName+"/s")():"":(()=>(0,b.WU)(t.value)+" OOM"+(n.value<0?"^OOM":"^"+n.value)!==void 0&&(0,b.WU)(t.value)+" OOM"+(n.value<0?"^OOM":"^"+n.value)!==null&&((0,b.WU)(t.value)+" OOM"+(n.value<0?"^OOM":"^"+n.value))[Symbol.for("+")]?((0,b.WU)(t.value)+" OOM"+(n.value<0?"^OOM":"^"+n.value))[Symbol.for("+")]("s/sec"):(0,b.WU)(t.value)+" OOM"+(n.value<0?"^OOM":"^"+n.value)+"s/sec")()));return i}function x(e,o){const t=o??e.value;return b.ZP.eq(e.precision,0)?(0,b.Ht)(t):(0,b.WU)(t,e.precision,e.small)}function M(e,o,t,n,r,i){const a=(0,l.resolveComponent)("Links");return(0,l.openBlock)(),(0,l.createElementBlock)(l.Fragment,null,[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.nodesComp))),e.leftNodesComp?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.leftNodesComp),{key:0})):(0,l.createCommentVNode)("",!0),e.rightNodesComp?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.rightNodesComp),{key:1})):(0,l.createCommentVNode)("",!0),e.branches?((0,l.openBlock)(),(0,l.createBlock)(a,{key:2,links:e.unref(e.branches)},null,8,["links"])):(0,l.createCommentVNode)("",!0)],64)}var C=t(1604),w=t(9365);const Z=["x1","y1","x2","y2"];var B=(0,l.defineComponent)({props:{link:null,startNode:null,endNode:null,boundingRect:null},setup(e){const o=e,t=(0,l.toRefs)(o),n=(0,l.computed)((()=>{const e=t.startNode.value.rect,o=t.boundingRect.value,l=o?{x:(()=>e.x+e.width/2!==void 0&&e.x+e.width/2!==null&&(e.x+e.width/2)[Symbol.for("-")]?(e.x+e.width/2)[Symbol.for("-")](o.x):e.x+e.width/2-o.x)(),y:(()=>e.y+e.height/2!==void 0&&e.y+e.height/2!==null&&(e.y+e.height/2)[Symbol.for("-")]?(e.y+e.height/2)[Symbol.for("-")](o.y):e.y+e.height/2-o.y)()}:{x:0,y:0};return t.link.value.offsetStart&&(l.x=(()=>void 0!==l.x&&null!==l.x&&l.x[Symbol.for("+")]?l.x[Symbol.for("+")](t.link.value.offsetStart.x):l.x+t.link.value.offsetStart.x)(),l.y=(()=>void 0!==l.y&&null!==l.y&&l.y[Symbol.for("+")]?l.y[Symbol.for("+")](t.link.value.offsetStart.y):l.y+t.link.value.offsetStart.y)()),l})),r=(0,l.computed)((()=>{const e=t.endNode.value.rect,o=t.boundingRect.value,l=o?{x:(()=>e.x+e.width/2!==void 0&&e.x+e.width/2!==null&&(e.x+e.width/2)[Symbol.for("-")]?(e.x+e.width/2)[Symbol.for("-")](o.x):e.x+e.width/2-o.x)(),y:(()=>e.y+e.height/2!==void 0&&e.y+e.height/2!==null&&(e.y+e.height/2)[Symbol.for("-")]?(e.y+e.height/2)[Symbol.for("-")](o.y):e.y+e.height/2-o.y)()}:{x:0,y:0};return t.link.value.offsetEnd&&(l.x=(()=>void 0!==l.x&&null!==l.x&&l.x[Symbol.for("+")]?l.x[Symbol.for("+")](t.link.value.offsetEnd.x):l.x+t.link.value.offsetEnd.x)(),l.y=(()=>void 0!==l.y&&null!==l.y&&l.y[Symbol.for("+")]?l.y[Symbol.for("+")](t.link.value.offsetEnd.y):l.y+t.link.value.offsetEnd.y)()),l}));return(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("line",(0,l.mergeProps)({"stroke-width":"15px",stroke:"white"},e.link,{x1:(0,l.unref)(n).x,y1:(0,l.unref)(n).y,x2:(0,l.unref)(r).x,y2:(0,l.unref)(r).y}),null,16,Z))}});const P=B;var E=P,F=(0,l.defineComponent)({props:{links:null},setup(e){const o=e,t=(0,l.toRef)(o,"links"),n=(0,l.ref)(null),r=(0,l.inject)(w.NodesInjectionKey),i=(0,l.inject)(w.BoundsInjectionKey),a=(0,l.ref)(void 0);(0,l.watch)([i],(()=>a.value=n.value?.getBoundingClientRect()));const s=(0,l.computed)((()=>{const e=r.value;return t.value?.filter((o=>e[o.startNode.id]?.rect&&e[o.startNode.id]?.rect))??[]}));return(e,o)=>((0,l.openBlock)(),(0,l.createElementBlock)(l.Fragment,null,[(0,l.unref)(s)?((0,l.openBlock)(),(0,l.createElementBlock)("svg",(0,l.normalizeProps)((0,l.mergeProps)({key:0},e.$attrs)),[((0,l.openBlock)(!0),(0,l.createElementBlock)(l.Fragment,null,(0,l.renderList)((0,l.unref)(s),((e,o)=>((0,l.openBlock)(),(0,l.createBlock)(E,{key:o,link:e,boundingRect:a.value,startNode:(0,l.unref)(r)[e.startNode.id],endNode:(0,l.unref)(r)[e.endNode.id]},null,8,["link","boundingRect","startNode","endNode"])))),128))],16)):(0,l.createCommentVNode)("",!0),(0,l.createElementVNode)("div",{ref_key:"resizeListener",ref:n,class:"resize-listener"},null,512)],64))}});const T=(0,a.Z)(F,[["__scopeId","data-v-2bbc19c2"]]);var D=T,I=(0,l.defineComponent)({props:{nodes:{type:(0,C.P5)(Array),required:!0},leftSideNodes:(0,C.P5)(Array),rightSideNodes:(0,C.P5)(Array),branches:(0,C.P5)(Array)},components:{Links:D},setup(e){const{nodes:o,leftSideNodes:t,rightSideNodes:n}=(0,l.toRefs)(e),r=(0,l.shallowRef)();(0,l.watchEffect)((()=>{const e=(0,C.Uv)(o);r.value=(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[e.map((e=>(0,l.createVNode)("span",{class:"row tree-row",style:"margin: 50px auto;"},[e.map(C.qF)])))]))))}));const i=(0,l.shallowRef)();(0,l.watchEffect)((()=>{const e=(0,C.Uv)(t);i.value=e?(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)("span",{class:"left-side-nodes small"},[e.map(C.qF)])))):""}));const a=(0,l.shallowRef)();return(0,l.watchEffect)((()=>{const e=(0,C.Uv)(n);a.value=e?(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)("span",{class:"side-nodes small"},[e.map(C.qF)])))):""})),{unref:l.unref,nodesComp:r,leftNodesComp:i,rightNodesComp:a}}});const R=(0,a.Z)(I,[["render",M],["__scopeId","data-v-aa87859c"]]);var _=R;function O(e,o,t,n,r,i){const a=(0,l.resolveComponent)("MarkNode"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,style:(0,l.normalizeStyle)({visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0}),class:(0,l.normalizeClass)({treeNode:!0,can:e.unref(e.canClick),...e.unref(e.classes)}),onClick:o[0]||(o[0]=(...o)=>e.onClick&&e.onClick(...o)),onMousedown:o[1]||(o[1]=(...o)=>e.start&&e.start(...o)),onMouseleave:o[2]||(o[2]=(...o)=>e.stop&&e.stop(...o)),onMouseup:o[3]||(o[3]=(...o)=>e.stop&&e.stop(...o)),onTouchstartPassive:o[4]||(o[4]=(...o)=>e.start&&e.start(...o)),onTouchendPassive:o[5]||(o[5]=(...o)=>e.stop&&e.stop(...o)),onTouchcancelPassive:o[6]||(o[6]=(...o)=>e.stop&&e.stop(...o))},[(0,l.createElementVNode)("div",{style:(0,l.normalizeStyle)([{backgroundColor:e.unref(e.color),boxShadow:`-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 20px ${e.unref(e.glowColor)}`},e.unref(e.style)??[]])},[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.unref(e.comp))))],4),(0,l.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],38)):(0,l.createCommentVNode)("",!0)}var U=(0,l.defineComponent)({props:{id:null},setup(e){const o=e,t=(0,l.toRefs)(o),n=(0,l.inject)(w.RegisterNodeInjectionKey),r=(0,l.inject)(w.UnregisterNodeInjectionKey),i=(0,l.ref)(null),a=(0,l.computed)((()=>i.value&&i.value.parentElement));return n&&r&&((0,l.watch)([a,t.id],(([e,o],[t,i])=>{t&&r((0,l.unref)(i)),e&&n(o,e)})),(0,l.onUnmounted)((()=>r((0,l.unref)(t.id))))),(e,o)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{class:"node",ref_key:"node",ref:i},null,512))}});const j=(0,a.Z)(U,[["__scopeId","data-v-63ded336"]]);var A=j;const q={key:0},z={key:0,class:"mark star"},L=["src"];var G=(0,l.defineComponent)({props:{mark:{type:[Boolean,String]}},setup(e){return(o,t)=>e.mark?((0,l.openBlock)(),(0,l.createElementBlock)("div",q,[!0===e.mark?((0,l.openBlock)(),(0,l.createElementBlock)("div",z)):((0,l.openBlock)(),(0,l.createElementBlock)("img",{key:1,class:"mark",src:e.mark},null,8,L))])):(0,l.createCommentVNode)("",!0)}});const H=(0,a.Z)(G,[["__scopeId","data-v-c476c56a"]]);var W=H,$=(0,l.defineComponent)({props:{display:(0,C.P5)(Object,String,Function),visibility:{type:(0,C.P5)(Number),required:!0},style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),onClick:Function,onHold:Function,color:(0,C.P5)(String),glowColor:(0,C.P5)(String),canClick:{type:(0,C.P5)(Boolean),required:!0},mark:(0,C.P5)(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:W,Node:A},setup(e){const{onClick:o,onHold:t,display:n}=(0,l.toRefs)(e),r=(0,C.KO)(n),{start:i,stop:a}=(0,C.ix)(o,t);return{start:i,stop:a,comp:r,unref:l.unref,Visibility:y.EE,isCoercableComponent:C.RU}}});const Y=(0,a.Z)($,[["render",O],["__scopeId","data-v-094cdcfe"]]);var K=Y,Q=t(9583),J=t(3273);const X=Symbol("TreeNode"),ee=Symbol("Tree");function oe(e){return(0,J.z2)((()=>{const o=e?.()??{};if(o.id=(0,y.QI)("treeNode-"),o.type=X,o[y.wA]=K,(0,Q.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,Q.yB)(o,"canClick"),(0,y.Rh)(o,"canClick",!0),(0,Q.yB)(o,"color"),(0,Q.yB)(o,"display"),(0,Q.yB)(o,"glowColor"),(0,Q.yB)(o,"classes"),(0,Q.yB)(o,"style"),(0,Q.yB)(o,"mark"),o.onClick){const e=o.onClick.bind(o);o.onClick=function(){(0,l.unref)(o.canClick)&&e()}}if(o.onHold){const e=o.onHold.bind(o);o.onHold=function(){(0,l.unref)(o.canClick)&&e()}}return o[y.tj]=function(){const{display:e,visibility:o,style:t,classes:l,onClick:n,onHold:r,color:i,glowColor:a,canClick:s,mark:u,id:m}=this;return{display:e,visibility:o,style:t,classes:l,onClick:n,onHold:r,color:i,glowColor:a,canClick:s,mark:u,id:m}},o}))}function te(e){return(0,J.z2)((()=>{const o=e();return o.id=(0,y.QI)("tree-"),o.type=ee,o[y.wA]=_,o.isResetting=(0,l.ref)(!1),o.resettingNode=(0,l.shallowRef)(null),o.reset=function(e){const t=o;t.isResetting.value=!0,t.resettingNode.value=e,t.resetPropagation?.(t,e),t.onReset?.(e),t.isResetting.value=!1,t.resettingNode.value=null},o.links=(0,l.computed)((()=>{const e=o;return(0,l.unref)(e.branches)??[]})),(0,Q.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,Q.yB)(o,"nodes"),(0,Q.yB)(o,"leftSideNodes"),(0,Q.yB)(o,"rightSideNodes"),(0,Q.yB)(o,"branches"),o[y.tj]=function(){const{nodes:e,leftSideNodes:o,rightSideNodes:t,branches:l}=this;return{nodes:e,leftSideNodes:o,rightSideNodes:t,branches:l}},o}))}const le=function(e,o){const t=[o];let n=[o];if((()=>void 0!==e.branches&&null!==e.branches&&e.branches[Symbol.for("!=")]?e.branches[Symbol.for("!=")](null):null!=e.branches)()){const o=(0,l.unref)(e.branches);while((()=>void 0!==n.length&&null!==n.length&&n.length[Symbol.for(">")]?n.length[Symbol.for(">")](0):n.length>0)()){const e=[];n.forEach((l=>{o.filter((e=>e.startNode===l||e.endNode===l)).map((e=>e.startNode===l?e.endNode:e.startNode)).filter((e=>(()=>void 0!==t.includes(e)&&null!==t.includes(e)&&t.includes(e)[Symbol.for("!")]?t.includes(e)[Symbol.for("!")]():!t.includes(e))())).forEach((o=>{(()=>void 0!==e.includes(o)&&null!==e.includes(o)&&e.includes(o)[Symbol.for("!")]?e.includes(o)[Symbol.for("!")]():!e.includes(o))()&&(e.push(o),o.reset?.reset())}))})),n=e,t.push(...n)}}};function ne(e,o=null,t=0){const n=(0,Q.UI)(t);return(0,l.computed)((()=>(()=>void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o)()||b.ZP.gte(e.value,(0,l.unref)(n))?(()=>x(e)+" "!==void 0&&x(e)+" "!==null&&(x(e)+" ")[Symbol.for("+")]?(x(e)+" ")[Symbol.for("+")](e.displayName):x(e)+" "+e.displayName)():`Reach ${b.ZP.eq(o.precision,0)?(0,b.Ht)((0,l.unref)(n)):(0,b.WU)((0,l.unref)(n),o.precision)} ${o.displayName} to unlock (You have ${b.ZP.eq(o.precision,0)?(0,b.Ht)(o.value):(0,b.WU)(o.value,o.precision)})`))}var re=t(5967),ie=t(274),ae=t(6055);function se(e,o,t,n,r,i){const a=(0,l.resolveComponent)("MarkNode"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0,backgroundImage:e.earned&&e.image&&`url(${e.image})`||""},e.unref(e.style)??[]]),class:(0,l.normalizeClass)({feature:!0,achievement:!0,locked:(()=>void 0!==e.unref(e.earned)&&null!==e.unref(e.earned)&&e.unref(e.earned)[Symbol.for("!")]?e.unref(e.earned)[Symbol.for("!")]():!e.unref(e.earned))(),bought:e.unref(e.earned),...e.unref(e.classes)})},[e.component?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.component),{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],6)):(0,l.createCommentVNode)("",!0)}var ue=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},display:(0,C.P5)(Object,String,Function),earned:{type:(0,C.P5)(Boolean),required:!0},image:(0,C.P5)(String),style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),mark:(0,C.P5)(Boolean,String),id:{type:String,required:!0}},components:{Node:A,MarkNode:W},setup(e){const{display:o}=(0,l.toRefs)(e);return{component:(0,C.KO)(o),unref:l.unref,Visibility:y.EE}}});const me=(0,a.Z)(ue,[["render",se],["__scopeId","data-v-e3f32402"]]);var ce=me,fe=t(3002);t(343);function de(e="white",o="8px"){return{transform:"scale(1.05, 1.05)",borderColor:"rgba(0, 0, 0, 0.125)",boxShadow:`-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 ${o} ${e}`,zIndex:1}}function ye(){return de("red","20px")}h.globalBus.on("setupVue",(e=>e.use(fe.ZP)));const be=(0,fe.pm)(),he=Symbol("Achievement");function pe(e){const o=(0,p.ax)(!1);return(0,J.z2)((()=>{const t=e?.()??{};if(t.id=(0,y.QI)("achievement-"),t.type=he,t[y.wA]=ce,t.earned=o,t.complete=function(){o.value=!0},(0,Q.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,Q.yB)(t,"display"),(0,Q.yB)(t,"mark"),(0,Q.yB)(t,"image"),(0,Q.yB)(t,"style"),(0,Q.yB)(t,"classes"),t[y.tj]=function(){const{visibility:e,display:o,earned:t,image:n,style:r,classes:i,mark:a,id:s}=this;return{visibility:e,display:o,earned:t,image:n,style:(0,l.unref)(r),classes:i,mark:a,id:s}},t.shouldEarn){const e=t;(0,l.watchEffect)((()=>{if((()=>void 0!==e.earned.value&&null!==e.earned.value&&e.earned.value[Symbol.for("!")]?e.earned.value[Symbol.for("!")]():!e.earned.value)()&&(0,l.unref)(e.visibility)===y.EE.Visible&&e.shouldEarn?.()&&(e.earned.value=!0,e.onComplete?.(),e.display)){const o=(0,C.MM)((0,l.unref)(e.display));be.info((0,l.createVNode)("div",null,[(0,l.createVNode)("h3",null,[(0,l.createTextVNode)("Achievement earned!")]),(0,l.createVNode)("div",null,[(0,l.createVNode)(o,null,null)])]))}}))}return t}))}function ve(e,o,t,n,r,i){const a=(0,l.resolveComponent)("GridCell");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,style:(0,l.normalizeStyle)({visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0}),class:"table"},[((0,l.openBlock)(!0),(0,l.createElementBlock)(l.Fragment,null,(0,l.renderList)(e.unref(e.rows),(o=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{class:(0,l.normalizeClass)(["row",{mergeAdjacent:e.mergeAdjacent}]),key:o},[((0,l.openBlock)(!0),(0,l.createElementBlock)(l.Fragment,null,(0,l.renderList)(e.unref(e.cols),(t=>((0,l.openBlock)(),(0,l.createBlock)(a,(0,l.mergeProps)({key:t},e.gatherCellProps(e.unref(e.cells)[(()=>100*o!==void 0&&100*o!==null&&(100*o)[Symbol.for("+")]?(100*o)[Symbol.for("+")](t):100*o+t)()])),null,16)))),128))],2)))),128))],4)):(0,l.createCommentVNode)("",!0)}var ge=t(1037),Se=t(9266);const Ne={key:0};function ke(e,o,t,n,r,i){const a=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:0,class:(0,l.normalizeClass)({feature:!0,tile:!0,can:e.unref(e.canClick),locked:(()=>void 0!==e.unref(e.canClick)&&null!==e.unref(e.canClick)&&e.unref(e.canClick)[Symbol.for("!")]?e.unref(e.canClick)[Symbol.for("!")]():!e.unref(e.canClick))()}),style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??{}]),onClick:o[0]||(o[0]=(...o)=>e.onClick&&e.onClick(...o)),onMousedown:o[1]||(o[1]=(...o)=>e.start&&e.start(...o)),onMouseleave:o[2]||(o[2]=(...o)=>e.stop&&e.stop(...o)),onMouseup:o[3]||(o[3]=(...o)=>e.stop&&e.stop(...o)),onTouchstartPassive:o[4]||(o[4]=(...o)=>e.start&&e.start(...o)),onTouchendPassive:o[5]||(o[5]=(...o)=>e.stop&&e.stop(...o)),onTouchcancelPassive:o[6]||(o[6]=(...o)=>e.stop&&e.stop(...o))},[e.title?((0,l.openBlock)(),(0,l.createElementBlock)("div",Ne,[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.titleComponent)))])):(0,l.createCommentVNode)("",!0),((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.component),{style:{"white-space":"pre-line"}})),(0,l.createVNode)(a,{id:e.id},null,8,["id"])],38)):(0,l.createCommentVNode)("",!0)}var Ve=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},onClick:Function,onHold:Function,display:{type:(0,C.P5)(Object,String,Function),required:!0},title:(0,C.P5)(Object,String,Function),style:(0,C.P5)(String,Object,Array),canClick:{type:(0,C.P5)(Boolean),required:!0},id:{type:String,required:!0}},components:{Node:A},setup(e){const{onClick:o,onHold:t,title:n,display:r}=(0,l.toRefs)(e),{start:i,stop:a}=(0,C.ix)(o,t),s=(0,C.KO)(n),u=(0,C.vq)(r);return{start:i,stop:a,titleComponent:s,component:u,Visibility:y.EE,unref:l.unref}}});const xe=(0,a.Z)(Ve,[["render",ke],["__scopeId","data-v-b27416ec"]]);var Me=xe,Ce=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},rows:{type:(0,C.P5)(Number),required:!0},cols:{type:(0,C.P5)(Number),required:!0},cells:{type:(0,C.P5)(Object),required:!0}},components:{GridCell:Me},setup(){const e=(0,l.computed)((()=>ge.Z[Se.ZP.theme].mergeAdjacent));function o(e){const{visibility:o,onClick:t,onHold:l,display:n,title:r,style:i,canClick:a,id:s}=e;return{visibility:o,onClick:t,onHold:l,display:n,title:r,style:i,canClick:a,id:s}}return{unref:l.unref,gatherCellProps:o,Visibility:y.EE,mergeAdjacent:e}}});const we=(0,a.Z)(Ce,[["render",ve]]);var Ze=we,Be=t(1349);Symbol("Grid");function Pe(e){return new Proxy({},Ee(e))}function Ee(e){const o=(0,l.computed)((()=>{const o=[];for(let t=1;(()=>void 0!==t&&null!==t&&t[Symbol.for("<=")]?t[Symbol.for("<=")]((0,l.unref)(e.rows)):t<=(0,l.unref)(e.rows))();(()=>void 0!==t&&null!==t&&"object"===typeof t&&t[Symbol.for("postfix-increment")]?t[Symbol.for("postfix-increment")]():t++)())for(let n=1;(()=>void 0!==n&&null!==n&&n[Symbol.for("<=")]?n[Symbol.for("<=")]((0,l.unref)(e.cols)):n<=(0,l.unref)(e.cols))();(()=>void 0!==n&&null!==n&&"object"===typeof n&&n[Symbol.for("postfix-increment")]?n[Symbol.for("postfix-increment")]():n++)())o.push((()=>100*t!==void 0&&100*t!==null&&(100*t)[Symbol.for("+")]?(100*t)[Symbol.for("+")](n):100*t+n)().toString());return o}));return{get(t,l){return"isProxy"===l||("symbol"===typeof l?e[l]:(()=>void 0!==o.value.includes(l.toString())&&null!==o.value.includes(l.toString())&&o.value.includes(l.toString())[Symbol.for("!")]?o.value.includes(l.toString())[Symbol.for("!")]():!o.value.includes(l.toString()))()?void 0:((()=>void 0!==t[l]&&null!==t[l]&&t[l][Symbol.for("==")]?t[l][Symbol.for("==")](null):null==t[l])()&&(t[l]=new Proxy(e,Fe(l.toString()))),t[l]))},set(e,o,t){return console.warn("Cannot set grid cells",e,o,t),!1},ownKeys(){return o.value},has(e,t){return o.value.includes(t.toString())},getOwnPropertyDescriptor(e,t){if(o.value.includes(t.toString()))return{configurable:!0,enumerable:!0,writable:!1}}}}function Fe(e){const o=["id","visibility","canClick","startState","state","style","classes","title","display","onClick","onHold"],t={};return{get(o,n,r){if("isProxy"===n)return!0;let i=o[n];return(0,Be.mf)(i)?()=>i.call(r,e,o.getState(e)):(()=>void 0!==i&&null!==i&&i[Symbol.for("!=")]?i[Symbol.for("!=")](void 0):void 0!=i)()||"symbol"===typeof n?i:(n=(()=>void 0!==n.slice(0,1).toUpperCase()&&null!==n.slice(0,1).toUpperCase()&&n.slice(0,1).toUpperCase()[Symbol.for("+")]?n.slice(0,1).toUpperCase()[Symbol.for("+")](n.slice(1)):n.slice(0,1).toUpperCase()+n.slice(1))(),"startState"===n?i.call(r,e):(i=o[`get${n}`],(0,Be.mf)(i)?((()=>n in t!==void 0&&n in t!==null&&(n in t)[Symbol.for("!")]?(n in t)[Symbol.for("!")]():!(n in t))()&&(t[n]=(0,l.computed)((()=>i.call(r,e,o.getState(e))))),t[n].value):(()=>void 0!==i&&null!==i&&i[Symbol.for("!=")]?i[Symbol.for("!=")](void 0):void 0!=i)()?(0,l.unref)(i):(i=o[`on${n}`],(0,Be.mf)(i)?()=>i.call(r,e,o.getState(e)):(()=>void 0!==i&&null!==i&&i[Symbol.for("!=")]?i[Symbol.for("!=")](void 0):void 0!=i)()?i:o[n])))},set(o,t,l,n){return t=`set${(()=>void 0!==t.slice(0,1).toUpperCase()&&null!==t.slice(0,1).toUpperCase()&&t.slice(0,1).toUpperCase()[Symbol.for("+")]?t.slice(0,1).toUpperCase()[Symbol.for("+")](t.slice(1)):t.slice(0,1).toUpperCase()+t.slice(1))()}`,(()=>void 0!==t&&null!==t&&t[Symbol.for("in")]?t[Symbol.for("in")](o):t in o)()&&(0,Be.mf)(o[t])&&(()=>void 0!==o[t].length&&null!==o[t].length&&o[t].length[Symbol.for("<")]?o[t].length[Symbol.for("<")](3):o[t].length<3)()?(o[t].call(n,e,l),!0):(console.warn(`No setter for "${t}".`,o),!1)},ownKeys(){return o},has(e,t){return o.includes(t.toString())},getOwnPropertyDescriptor(e,t){if(o.includes(t.toString()))return{configurable:!0,enumerable:!0,writable:!1}}}}function Te(e){const o=(0,p.ax)({});return(0,J.z2)((()=>{const t=e();if(t.id=(0,y.QI)("grid-"),t[y.wA]=Ze,t.cellState=o,t.getID=function(e){return(()=>t.id+"-"!==void 0&&t.id+"-"!==null&&(t.id+"-")[Symbol.for("+")]?(t.id+"-")[Symbol.for("+")](e):t.id+"-"+e)()},t.getState=function(e){return(()=>void 0!==this.cellState.value[e]&&null!==this.cellState.value[e]&&this.cellState.value[e][Symbol.for("!=")]?this.cellState.value[e][Symbol.for("!=")](void 0):void 0!=this.cellState.value[e])()?o.value[e]:this.cells[e].startState},t.setState=function(e,t){o.value[e]=t},t.cells=Pe(t),(0,Q.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,Q.yB)(t,"rows"),(0,Q.yB)(t,"cols"),(0,Q.yB)(t,"getVisibility"),(0,y.Rh)(t,"getVisibility",y.EE.Visible),(0,Q.yB)(t,"getCanClick"),(0,y.Rh)(t,"getCanClick",!0),(0,Q.yB)(t,"getStartState"),(0,Q.yB)(t,"getStyle"),(0,Q.yB)(t,"getClasses"),(0,Q.yB)(t,"getTitle"),(0,Q.yB)(t,"getDisplay"),t.onClick){const e=t.onClick.bind(t);t.onClick=function(o,n){(0,l.unref)(t.cells[o].canClick)&&e(o,n)}}if(t.onHold){const e=t.onHold.bind(t);t.onHold=function(o,n){(0,l.unref)(t.cells[o].canClick)&&e(o,n)}}return t[y.tj]=function(){const{visibility:e,rows:o,cols:t,cells:l,id:n}=this;return{visibility:e,rows:o,cols:t,cells:l,id:n}},t}))}function De(e,o,t,n,r,i){const a=(0,l.resolveComponent)("MarkNode"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:0,style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??[]]),onClick:o[0]||(o[0]=(...o)=>e.onClick&&e.onClick(...o)),onMousedown:o[1]||(o[1]=(...o)=>e.start&&e.start(...o)),onMouseleave:o[2]||(o[2]=(...o)=>e.stop&&e.stop(...o)),onMouseup:o[3]||(o[3]=(...o)=>e.stop&&e.stop(...o)),onTouchstartPassive:o[4]||(o[4]=(...o)=>e.start&&e.start(...o)),onTouchendPassive:o[5]||(o[5]=(...o)=>e.stop&&e.stop(...o)),onTouchcancelPassive:o[6]||(o[6]=(...o)=>e.stop&&e.stop(...o)),class:(0,l.normalizeClass)({feature:!0,clickable:!0,can:e.unref(e.canClick),locked:(()=>void 0!==e.unref(e.canClick)&&null!==e.unref(e.canClick)&&e.unref(e.canClick)[Symbol.for("!")]?e.unref(e.canClick)[Symbol.for("!")]():!e.unref(e.canClick))(),small:e.small,...e.unref(e.classes)})},[e.unref(e.comp)?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.unref(e.comp)),{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],38)):(0,l.createCommentVNode)("",!0)}var Ie=(0,l.defineComponent)({props:{display:{type:(0,C.P5)(Object,String,Function),required:!0},visibility:{type:(0,C.P5)(Number),required:!0},style:(0,C.P5)(Object,String,Array),classes:(0,C.P5)(Object),onClick:Function,onHold:Function,canClick:{type:(0,C.P5)(Boolean),required:!0},small:Boolean,mark:(0,C.P5)(Boolean,String),id:{type:String,required:!0}},components:{Node:A,MarkNode:W},setup(e){const{display:o,onClick:t,onHold:n}=(0,l.toRefs)(e),r=(0,l.shallowRef)("");(0,l.watchEffect)((()=>{const e=(0,C.Uv)(o);if((()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)())return void(r.value="");if((0,C.RU)(e))return void(r.value=(0,C.MM)(e));const t=(0,C.MM)(e.title||"","h3"),n=(0,C.MM)(e.description,"div");r.value=(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)("span",null,[e.title?(0,l.createVNode)("div",null,[(0,l.createVNode)(t,null,null)]):null,(0,l.createVNode)(n,null,null)]))))}));const{start:i,stop:a}=(0,C.ix)(t,n);return{start:i,stop:a,comp:r,Visibility:y.EE,unref:l.unref}}});const Re=(0,a.Z)(Ie,[["render",De],["__scopeId","data-v-e4e6b79a"]]);var _e=Re;const Oe=Symbol("Clickable");function Ue(e){return(0,J.z2)((()=>{const o=e?.()??{};if(o.id=(0,y.QI)("clickable-"),o.type=Oe,o[y.wA]=_e,(0,Q.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,Q.yB)(o,"canClick"),(0,y.Rh)(o,"canClick",!0),(0,Q.yB)(o,"classes"),(0,Q.yB)(o,"style"),(0,Q.yB)(o,"mark"),(0,Q.yB)(o,"display"),o.onClick){const e=o.onClick.bind(o);o.onClick=function(t){(0,l.unref)(o.canClick)&&e(t)}}if(o.onHold){const e=o.onHold.bind(o);o.onHold=function(){(0,l.unref)(o.canClick)&&e()}}return o[y.tj]=function(){const{display:e,visibility:o,style:t,classes:n,onClick:r,onHold:i,canClick:a,small:s,mark:u,id:m}=this;return{display:e,visibility:o,style:(0,l.unref)(t),classes:n,onClick:r,onHold:i,canClick:a,small:s,mark:u,id:m}},o}))}function je(e){return Ue((()=>{const o=e();(0,Q.yB)(o,"showNextAt"),(0,y.Rh)(o,"showNextAt",!0),(0,y.Rh)(o,"minimumGain",1),(()=>void 0!==o.resetDescription&&null!==o.resetDescription&&o.resetDescription[Symbol.for("==")]?o.resetDescription[Symbol.for("==")](null):null==o.resetDescription)()?o.resetDescription=(0,l.computed)((()=>b.ZP.lt(o.conversion.gainResource.value,1e3)?"Reset for ":"")):(0,Q.yB)(o,"resetDescription"),(()=>void 0!==o.display&&null!==o.display&&o.display[Symbol.for("==")]?o.display[Symbol.for("==")](null):null==o.display)()&&(o.display=(0,y.tZ)((()=>(0,l.createVNode)("span",null,[(0,l.unref)(o.resetDescription),(0,l.createVNode)("b",null,[x(o.conversion.gainResource,b.ZP.max((0,l.unref)(o.conversion.actualGain),(0,l.unref)(o.minimumGain)))])," ",o.conversion.gainResource.displayName,(0,l.withDirectives)((0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.unref)(o.conversion.buyMax)?"Next:":"Req:"," ",x(o.conversion.baseResource,(0,l.unref)(o.conversion.buyMax)||b.ZP.floor((0,l.unref)(o.conversion.actualGain)).neq(1)?(0,l.unref)(o.conversion.nextAt):(0,l.unref)(o.conversion.currentAt))," ",o.conversion.baseResource.displayName]),[[l.vShow,(0,l.unref)(o.showNextAt)]])])))),(()=>void 0!==o.canClick&&null!==o.canClick&&o.canClick[Symbol.for("==")]?o.canClick[Symbol.for("==")](null):null==o.canClick)()&&(o.canClick=(0,l.computed)((()=>b.ZP.gte((0,l.unref)(o.conversion.actualGain),(0,l.unref)(o.minimumGain)))));const t=o.onClick;return o.onClick=function(){(()=>void 0!==(0,l.unref)(o.canClick)&&null!==(0,l.unref)(o.canClick)&&(0,l.unref)(o.canClick)[Symbol.for("!")]?(0,l.unref)(o.canClick)[Symbol.for("!")]():!(0,l.unref)(o.canClick))()||(o.conversion.convert(),o.tree.reset(o.treeNode),t?.())},o}))}function Ae(e){return oe((()=>{const o=e();return(0,Q.yB)(o,"display"),(0,y.Rh)(o,"display",o.layerID),(0,Q.yB)(o,"append"),{...o,display:o.display,onClick:(0,l.unref)(o.append)?function(){if(re.Z.tabs.includes(o.layerID)){const e=re.Z.tabs.lastIndexOf(o.layerID);re.Z.tabs.splice(e,1)}else re.Z.tabs.push(o.layerID)}:function(){re.Z.tabs.splice(1,1,o.layerID)}}}))}function qe(e){return(0,J.z2)((()=>{const o=e();return(()=>void 0!==o.currentGain&&null!==o.currentGain&&o.currentGain[Symbol.for("==")]?o.currentGain[Symbol.for("==")](null):null==o.currentGain)()&&(o.currentGain=(0,l.computed)((()=>{let e=o.gainModifier?o.gainModifier.apply(o.scaling.currentGain(o)):o.scaling.currentGain(o);return e=b.ZP.floor(e).max(0),(()=>void 0!==(0,l.unref)(o.buyMax)&&null!==(0,l.unref)(o.buyMax)&&(0,l.unref)(o.buyMax)[Symbol.for("!")]?(0,l.unref)(o.buyMax)[Symbol.for("!")]():!(0,l.unref)(o.buyMax))()&&(e=e.min(1)),e}))),(()=>void 0!==o.actualGain&&null!==o.actualGain&&o.actualGain[Symbol.for("==")]?o.actualGain[Symbol.for("==")](null):null==o.actualGain)()&&(o.actualGain=o.currentGain),(()=>void 0!==o.currentAt&&null!==o.currentAt&&o.currentAt[Symbol.for("==")]?o.currentAt[Symbol.for("==")](null):null==o.currentAt)()&&(o.currentAt=(0,l.computed)((()=>{let e=o.scaling.currentAt(o);return o.roundUpCost&&(e=b.ZP.ceil(e)),e}))),(()=>void 0!==o.nextAt&&null!==o.nextAt&&o.nextAt[Symbol.for("==")]?o.nextAt[Symbol.for("==")](null):null==o.nextAt)()&&(o.nextAt=(0,l.computed)((()=>{let e=o.scaling.nextAt(o);return o.roundUpCost&&(e=b.ZP.ceil(e)),e}))),(()=>void 0!==o.convert&&null!==o.convert&&o.convert[Symbol.for("==")]?o.convert[Symbol.for("==")](null):null==o.convert)()&&(o.convert=function(){o.gainResource.value=b.ZP.add(o.gainResource.value,(0,l.unref)(o.currentGain)),o.baseResource.value=0}),(0,Q.yB)(o,"currentGain"),(0,Q.yB)(o,"actualGain"),(0,Q.yB)(o,"currentAt"),(0,Q.yB)(o,"nextAt"),(0,Q.yB)(o,"buyMax"),(0,y.Rh)(o,"buyMax",!0),(0,Q.yB)(o,"roundUpCost"),(0,y.Rh)(o,"roundUpCost",!0),o}))}function ze(e,o){const t=(0,Q.UI)(e),n=(0,Q.UI)(o);return{currentGain(e){if(b.ZP.lt(e.baseResource.value,(0,l.unref)(t)))return 0;const o=b.ZP.div(e.baseResource.value,(0,l.unref)(t)).pow((0,l.unref)(n));return o.isNan()?new b.ZP(0):o},currentAt(e){let o=(0,l.unref)(e.currentGain);return e.gainModifier&&(o=e.gainModifier.revert(o)),o=b.ZP.max(0,o),b.ZP.root(o,(0,l.unref)(n)).times((0,l.unref)(t))},nextAt(e){let o=b.ZP.add((0,l.unref)(e.currentGain),1);return e.gainModifier&&(o=e.gainModifier.revert(o)),o=b.ZP.max(0,o),b.ZP.root(o,(0,l.unref)(n)).times((0,l.unref)(t)).max((0,l.unref)(t))}}}function Le(e){return qe(e)}function Ge(e){return qe((()=>{const o=e();return(0,y.Rh)(o,"buyMax",!1),(()=>void 0!==o.currentGain&&null!==o.currentGain&&o.currentGain[Symbol.for("==")]?o.currentGain[Symbol.for("==")](null):null==o.currentGain)()&&(o.currentGain=(0,l.computed)((()=>{let e=o.gainModifier?o.gainModifier.apply(o.scaling.currentGain(o)):o.scaling.currentGain(o);return e=b.ZP.floor(e).max(o.gainResource.value),(()=>void 0!==(0,l.unref)(o.buyMax)&&null!==(0,l.unref)(o.buyMax)&&(0,l.unref)(o.buyMax)[Symbol.for("!")]?(0,l.unref)(o.buyMax)[Symbol.for("!")]():!(0,l.unref)(o.buyMax))()&&(e=e.min(b.ZP.add(o.gainResource.value,1))),e}))),(()=>void 0!==o.actualGain&&null!==o.actualGain&&o.actualGain[Symbol.for("==")]?o.actualGain[Symbol.for("==")](null):null==o.actualGain)()&&(o.actualGain=(0,l.computed)((()=>{let e=b.ZP.sub(o.scaling.currentGain(o),o.gainResource.value).max(0);return(()=>void 0!==(0,l.unref)(o.buyMax)&&null!==(0,l.unref)(o.buyMax)&&(0,l.unref)(o.buyMax)[Symbol.for("!")]?(0,l.unref)(o.buyMax)[Symbol.for("!")]():!(0,l.unref)(o.buyMax))()&&(e=e.min(1)),e}))),(0,y.Rh)(o,"convert",(function(){o.gainResource.value=o.gainModifier?o.gainModifier.apply((0,l.unref)(o.currentGain)):(0,l.unref)(o.currentGain),o.baseResource.value=0})),o}))}function He(e,o,t=.5){return b.ZP.lte(e,o)?e:b.ZP.pow(e,t).times(b.ZP.pow(o,b.ZP.sub(1,t)))}function We(e,o,t=.5){return{...e,currentGain:n=>He(e.currentGain(n),(0,l.unref)(o),(0,l.unref)(t))}}const $e=e=>((0,l.pushScopeId)("data-v-6447a93e"),e=e(),(0,l.popScopeId)(),e),Ye=$e((()=>(0,l.createElementVNode)("span",{class:"toggle"},"▼",(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)())));function Ke(e,o,t,n,r,i){const a=(0,l.resolveComponent)("CollapseTransition"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,class:(0,l.normalizeClass)(["infobox",{collapsed:e.unref(e.collapsed),stacked:e.stacked,...e.unref(e.classes)}]),style:(0,l.normalizeStyle)([{borderColor:e.unref(e.color),visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??{}])},[(0,l.createElementVNode)("button",{class:"title",style:(0,l.normalizeStyle)([{backgroundColor:e.unref(e.color)},e.unref(e.titleStyle)||[]]),onClick:o[0]||(o[0]=o=>e.collapsed.value=(()=>void 0!==e.unref(e.collapsed)&&null!==e.unref(e.collapsed)&&e.unref(e.collapsed)[Symbol.for("!")]?e.unref(e.collapsed)[Symbol.for("!")]():!e.unref(e.collapsed))())},[Ye,((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.titleComponent)))],4),(0,l.createVNode)(a,null,{default:(0,l.withCtx)((()=>[(()=>void 0!==e.unref(e.collapsed)&&null!==e.unref(e.collapsed)&&e.unref(e.collapsed)[Symbol.for("!")]?e.unref(e.collapsed)[Symbol.for("!")]():!e.unref(e.collapsed))()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,class:"body",style:(0,l.normalizeStyle)({backgroundColor:e.unref(e.color)})},[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.bodyComponent),{style:(0,l.normalizeStyle)(e.unref(e.bodyStyle))},null,8,["style"]))],4)):(0,l.createCommentVNode)("",!0)])),_:1}),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],6)):(0,l.createCommentVNode)("",!0)}var Qe=t(423),Je=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},display:{type:(0,C.P5)(Object,String,Function),required:!0},title:{type:(0,C.P5)(Object,String,Function),required:!0},color:(0,C.P5)(String),collapsed:{type:Object,required:!0},style:(0,C.P5)(Object,String,Array),titleStyle:(0,C.P5)(Object,String,Array),bodyStyle:(0,C.P5)(Object,String,Array),classes:(0,C.P5)(Object),id:{type:String,required:!0}},components:{Node:A,CollapseTransition:Qe.Z},setup(e){const{title:o,display:t}=(0,l.toRefs)(e),n=(0,C.vq)(o),r=(0,C.vq)(t),i=(0,l.computed)((()=>ge.Z[Se.ZP.theme].mergeAdjacent));return{titleComponent:n,bodyComponent:r,stacked:i,unref:l.unref,Visibility:y.EE}}});const Xe=(0,a.Z)(Je,[["render",Ke],["__scopeId","data-v-6447a93e"]]);var eo=Xe;const oo=Symbol("Infobox");function to(e){const o=(0,p.ax)(!1);return(0,J.z2)((()=>{const t=e();return t.id=(0,y.QI)("infobox-"),t.type=oo,t[y.wA]=eo,t.collapsed=o,(0,Q.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,Q.yB)(t,"color"),(0,Q.yB)(t,"style"),(0,Q.yB)(t,"titleStyle"),(0,Q.yB)(t,"bodyStyle"),(0,Q.yB)(t,"classes"),(0,Q.yB)(t,"title"),(0,Q.yB)(t,"display"),t[y.tj]=function(){const{visibility:e,display:o,title:t,color:n,collapsed:r,style:i,titleStyle:a,bodyStyle:s,classes:u,id:m}=this;return{visibility:e,display:o,title:t,color:n,collapsed:r,style:(0,l.unref)(i),titleStyle:a,bodyStyle:s,classes:u,id:m}},t}))}function lo(e,o,t,n,r,i){return(0,l.openBlock)(),(0,l.createElementBlock)("div",{ref:"resizeListener",class:(0,l.normalizeClass)(["resize-listener",e.unref(e.classes)]),style:(0,l.normalizeStyle)(e.unref(e.style))},null,6)}var no=t(6591),ro=(0,l.defineComponent)({props:{style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),onInit:{type:Function,required:!0},id:{type:String,required:!0},onContainerResized:Function,onHotReload:Function},setup(e){const o=(0,l.ref)(null),t=new ResizeObserver(i),n=(0,l.ref)(null);(0,l.onMounted)((()=>{const r=n.value;(()=>void 0!==r&&null!==r&&r[Symbol.for("!=")]?r[Symbol.for("!=")](null):null!=r)()&&(t.observe(r),o.value=new no.MxU({resizeTo:r,backgroundAlpha:0}),n.value?.appendChild(o.value.view),e.onInit(o.value)),i(),e.onHotReload&&(0,l.nextTick)(e.onHotReload)})),(0,l.onBeforeUnmount)((()=>{o.value?.destroy()}));let r=!0;function i(){r&&(r=!1,(0,l.nextTick)((()=>{(()=>void 0!==n.value&&null!==n.value&&n.value[Symbol.for("!=")]?n.value[Symbol.for("!=")](null):null!=n.value)()&&e.onContainerResized&&(e.onContainerResized(n.value.getBoundingClientRect()),o.value?.resize()),r=!0})))}return document.fonts.ready.then(i),{unref:l.unref,resizeListener:n}}});const io=(0,a.Z)(ro,[["render",lo],["__scopeId","data-v-08c4e343"]]);var ao=io,so=t(1845);const uo=Symbol("Particles");function mo(e){return(0,J.z2)((()=>{const o=e?.()??{};o.id=(0,y.QI)("particles-"),o.type=uo,o[y.wA]=ao,o.app=(0,l.shallowRef)(null),o.addEmitter=e=>{const l=o;return l.app.value?Promise.resolve(new so.Q5(l.app.value.stage,e)):new Promise((o=>{t.push({resolve:o,config:e})}))};let t=[];function n(e){o.app.value=e,t.forEach((({resolve:o,config:t})=>o(new so.Q5(e.stage,t)))),t=[]}return o.onContainerResized=o.onContainerResized?.bind(o),o[y.tj]=function(){const{id:e,style:o,classes:t,onContainerResized:r,onHotReload:i}=this;return{id:e,style:(0,l.unref)(o),classes:t,onContainerResized:r,onHotReload:i,onInit:n}},o}))}window.upgradeConfig=so.oC;const co=Symbol("Reset");function fo(e){return(0,J.z2)((()=>{const o=e();return o.id=(0,y.QI)("reset-"),o.type=co,o.reset=function(){const e=o=>{o&&"object"===typeof o&&((()=>void 0!==p.n9&&null!==p.n9&&p.n9[Symbol.for("in")]?p.n9[Symbol.for("in")](o):p.n9 in o)()?o[p.n9].value=o[p.nY]:(()=>o instanceof b.ZP!==void 0&&o instanceof b.ZP!==null&&(o instanceof b.ZP)[Symbol.for("!")]?(o instanceof b.ZP)[Symbol.for("!")]():!(o instanceof b.ZP))()&&(()=>void 0!==(0,l.isRef)(o)&&null!==(0,l.isRef)(o)&&(0,l.isRef)(o)[Symbol.for("!")]?(0,l.isRef)(o)[Symbol.for("!")]():!(0,l.isRef)(o))()&&Object.values(o).forEach((o=>e(o))))};(0,l.unref)(o.thingsToReset).forEach(e),h.globalBus.emit("reset",o),o.onReset?.()},(0,Q.yB)(o,"thingsToReset"),o}))}const yo={};h.globalBus.on("removeLayer",(e=>{yo[e.id]?.(),yo[e.id]=void 0}));var bo=(0,l.defineComponent)({props:{resource:null,color:null},setup(e){const o=e,t=(0,l.computed)((()=>x(o.resource)));return(o,n)=>((0,l.openBlock)(),(0,l.createElementBlock)("h2",{style:(0,l.normalizeStyle)({color:e.color,"text-shadow":(()=>"0px 0px 10px "[Symbol.for("+")]?"0px 0px 10px "[Symbol.for("+")](e.color):"0px 0px 10px "+e.color)()})},(0,l.toDisplayString)((0,l.unref)(t)),5))}});const ho=bo;var po=ho;const vo={key:0},go={key:1},So=(0,l.createTextVNode)(", "),No=(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()),ko=(0,l.createElementVNode)("br",null,null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)());var Vo=(0,l.defineComponent)({props:{resource:null,color:null,classes:null,style:null,effectDisplay:null},setup(e){const o=e,t=(0,l.toRefs)(o),n=(0,C.KO)(t.effectDisplay),r=(0,l.computed)((()=>b.ZP.lt(t.resource.value,"1e1000")));return(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",null,[(0,l.unref)(r)?((0,l.openBlock)(),(0,l.createElementBlock)("span",vo,"You have ")):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(po,{resource:e.resource,color:e.color||"white"},null,8,["resource","color"]),(0,l.createTextVNode)((()=>" "[Symbol.for("+")]?" "[Symbol.for("+")]((0,l.toDisplayString)(e.resource.displayName)):" "+(0,l.toDisplayString)(e.resource.displayName))(),1),(0,l.unref)(n)?((0,l.openBlock)(),(0,l.createElementBlock)("span",go,[So,((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(n))))])):(0,l.createCommentVNode)("",!0),No,ko]))}});const xo=Vo;var Mo=xo;function Co(e,o){return(0,Q.yB)(o,"display"),(0,Q.yB)(o,"classes"),(0,Q.yB)(o,"style"),(0,Q.yB)(o,"direction"),(0,y.Rh)(o,"direction",Be.Nm.Up),(0,Q.yB)(o,"xoffset"),(0,Q.yB)(o,"yoffset"),(0,l.nextTick)((()=>{o.pinnable&&((()=>"pinned"[Symbol.for("in")]?"pinned"[Symbol.for("in")](e):"pinned"in e)()?(console.error("Cannot add pinnable tooltip to element that already has a property called 'pinned'"),o.pinnable=!1):e.pinned=o.pinned=(0,p.ax)(!1));const t=e[y.wA];e[y.wA]=ae.Z;const n=e[y.tj].bind(e);e[y.tj]=function(){const{display:e,classes:o,style:r,direction:i,xoffset:a,yoffset:s,pinned:u}=this;return{element:{[y.wA]:t,[y.tj]:n},display:e,classes:o,style:(0,l.unref)(r),direction:i,xoffset:a,yoffset:s,pinned:u}}.bind(o)})),o}function wo(e,o,t){const n=(0,Q.UI)(e),r=(0,Q.UI)(o),i=(()=>void 0!==t&&null!==t&&t[Symbol.for("==")]?t[Symbol.for("==")](null):null==t)()?void 0:(0,Q.UI)(t);return{apply:e=>b.ZP.add(e,(0,l.unref)(n)),revert:e=>b.ZP.sub(e,(0,l.unref)(n)),enabled:i,description:(()=>void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o)()?void 0:(0,y.tZ)((()=>(0,l.createVNode)("div",{class:"modifier-container"},[(0,l.createVNode)("span",{class:"modifier-amount"},[b.ZP.gte((0,l.unref)(n),0)?"+":"",(0,b.WU)((0,l.unref)(n))]),(0,l.unref)(r)?(0,l.createVNode)("span",{class:"modifier-description"},[(0,C.qF)((0,l.unref)(r))]):null])))}}function Zo(e,o,t){const n=(0,Q.UI)(e),r=(0,Q.UI)(o),i=(()=>void 0!==t&&null!==t&&t[Symbol.for("==")]?t[Symbol.for("==")](null):null==t)()?void 0:(0,Q.UI)(t);return{apply:e=>b.ZP.times(e,(0,l.unref)(n)),revert:e=>b.ZP.div(e,(0,l.unref)(n)),enabled:i,description:(()=>void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o)()?void 0:(0,y.tZ)((()=>(0,l.createVNode)("div",{class:"modifier-container"},[(0,l.createVNode)("span",{class:"modifier-amount"},[(0,l.createTextVNode)("x"),(0,b.WU)((0,l.unref)(n))]),(0,l.unref)(r)?(0,l.createVNode)("span",{class:"modifier-description"},[(0,C.qF)((0,l.unref)(r))]):null])))}}function Bo(e,o,t){const n=(0,Q.UI)(e),r=(0,Q.UI)(o),i=(()=>void 0!==t&&null!==t&&t[Symbol.for("==")]?t[Symbol.for("==")](null):null==t)()?void 0:(0,Q.UI)(t);return{apply:e=>b.ZP.pow(e,(0,l.unref)(n)),revert:e=>b.ZP.root(e,(0,l.unref)(n)),enabled:i,description:(()=>void 0!==o&&null!==o&&o[Symbol.for("==")]?o[Symbol.for("==")](null):null==o)()?void 0:(0,y.tZ)((()=>(0,l.createVNode)("div",{class:"modifier-container"},[(0,l.createVNode)("span",{class:"modifier-amount"},[(0,l.createTextVNode)("^"),(0,b.WU)((0,l.unref)(n))]),(0,l.unref)(r)?(0,l.createVNode)("span",{class:"modifier-description"},[(0,C.qF)((0,l.unref)(r))]):null])))}}function Po(...e){return{apply:o=>e.filter((e=>(()=>void 0!==(0,l.unref)(e.enabled)&&null!==(0,l.unref)(e.enabled)&&(0,l.unref)(e.enabled)[Symbol.for("!==")]?(0,l.unref)(e.enabled)[Symbol.for("!==")](!1):!1!==(0,l.unref)(e.enabled))())).reduce(((e,o)=>o.apply(e)),o),revert:e.every((e=>(()=>void 0!==e.revert&&null!==e.revert&&e.revert[Symbol.for("!=")]?e.revert[Symbol.for("!=")](null):null!=e.revert)()))?o=>e.filter((e=>(()=>void 0!==(0,l.unref)(e.enabled)&&null!==(0,l.unref)(e.enabled)&&(0,l.unref)(e.enabled)[Symbol.for("!==")]?(0,l.unref)(e.enabled)[Symbol.for("!==")](!1):!1!==(0,l.unref)(e.enabled))())).reduceRight(((e,o)=>o.revert(e)),o):void 0,enabled:(0,l.computed)((()=>(()=>void 0!==e.filter((e=>!1!==(0,l.unref)(e.enabled))).length&&null!==e.filter((e=>!1!==(0,l.unref)(e.enabled))).length&&e.filter((e=>!1!==(0,l.unref)(e.enabled))).length[Symbol.for(">")]?e.filter((e=>!1!==(0,l.unref)(e.enabled))).length[Symbol.for(">")](0):e.filter((e=>!1!==(0,l.unref)(e.enabled))).length>0)())),description:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[e.filter((e=>(()=>void 0!==(0,l.unref)(e.enabled)&&null!==(0,l.unref)(e.enabled)&&(0,l.unref)(e.enabled)[Symbol.for("!==")]?(0,l.unref)(e.enabled)[Symbol.for("!==")](!1):!1!==(0,l.unref)(e.enabled))())).map((e=>(0,l.unref)(e.description))).filter((e=>e)).map(C.qF)])))}}function Eo(e,o,t,n=1,r="",i="Base"){return(0,l.createVNode)("div",null,[(0,l.createVNode)("h3",null,[e,o?(0,l.createVNode)("span",{class:"subtitle"},[(0,l.createTextVNode)(" ("),o,(0,l.createTextVNode)(")")]):null]),(0,l.createVNode)("br",null,null),(0,l.createVNode)("div",{class:"modifier-container"},[(0,l.createVNode)("span",{class:"modifier-amount"},[(0,b.WU)(n),r]),(0,l.createVNode)("span",{class:"modifier-description"},[(0,C.qF)(i)])]),(0,C.qF)((0,l.unref)(t.description)),(0,l.createVNode)("hr",null,null),(0,l.createTextVNode)("Total: "),(0,b.WU)(t.apply(n)),r])}const Fo={class:"field"},To={key:0,class:"field-title"},Do=["min","max"];var Io=(0,l.defineComponent)({props:{title:null,modelValue:null,min:null,max:null},emits:["update:modelValue"],setup(e,{emit:o}){const t=e,n=(0,l.toRefs)(t),r=(0,l.computed)({get(){return String((0,l.unref)(n.modelValue)||0)},set(e){o("update:modelValue",Number(e))}});return(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",Fo,[e.title?((0,l.openBlock)(),(0,l.createElementBlock)("span",To,(0,l.toDisplayString)(e.title),1)):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(ae.Z,{display:`${(0,l.unref)(r)}`,class:(0,l.normalizeClass)({fullWidth:(()=>void 0!==e.title&&null!==e.title&&e.title[Symbol.for("!")]?e.title[Symbol.for("!")]():!e.title)()}),direction:(0,l.unref)(Be.Nm).Down},{default:(0,l.withCtx)((()=>[(0,l.withDirectives)((0,l.createElementVNode)("input",{type:"range","onUpdate:modelValue":t[0]||(t[0]=e=>(0,l.isRef)(r)?r.value=e:null),min:e.min,max:e.max},null,8,Do),[[l.vModelText,(0,l.unref)(r)]])])),_:1},8,["display","class","direction"])]))}});const Ro=(0,a.Z)(Io,[["__scopeId","data-v-38661d49"]]);var _o=Ro,Oo=t(4520),Uo=t(9868),jo=t(9905),Ao=(0,l.defineComponent)({setup(e){const o=(0,l.ref)("0"),t=new ResizeObserver(r),n=(0,l.ref)(null);function r(){let e=n.value;if((()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](void 0):void 0==e)())return;let t=0;while(e.previousSibling){const o=e.previousSibling;o.dataset&&(()=>"vSticky"[Symbol.for("in")]?"vSticky"[Symbol.for("in")](o.dataset):"vSticky"in o.dataset)()&&(t=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")](o.offsetHeight):t+o.offsetHeight)()),e=o}o.value=(()=>void 0!==t&&null!==t&&t[Symbol.for("+")]?t[Symbol.for("+")]("px"):t+"px")()}return(0,l.nextTick)(r),document.fonts.ready.then(r),(0,l.onMounted)((()=>{const e=n.value?.parentElement;e&&t.observe(e)})),(e,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{class:"sticky",style:(0,l.normalizeStyle)({top:o.value}),ref_key:"element",ref:n,"data-v-sticky":""},[(0,l.renderSlot)(e.$slots,"default")],4))}});const qo=(0,a.Z)(Ao,[["__scopeId","data-v-77aa21df"]]);var zo=qo,Lo=(0,l.defineComponent)({props:{height:null},setup(e){return(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",{class:"vr",style:(0,l.normalizeStyle)({height:e.height})},null,4))}});const Go=(0,a.Z)(Lo,[["__scopeId","data-v-15f6e746"]]);var Ho=Go,Wo=t(6948);function $o(e,o,t,n,r,i){const a=(0,l.resolveComponent)("MarkNode"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,style:(0,l.normalizeStyle)([{width:(()=>void 0!==e.unref(e.width)&&null!==e.unref(e.width)&&e.unref(e.width)[Symbol.for("+")]?e.unref(e.width)[Symbol.for("+")]("px"):e.unref(e.width)+"px")(),height:(()=>void 0!==e.unref(e.height)&&null!==e.unref(e.height)&&e.unref(e.height)[Symbol.for("+")]?e.unref(e.height)[Symbol.for("+")]("px"):e.unref(e.height)+"px")(),visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??{}]),class:(0,l.normalizeClass)({bar:!0,...e.unref(e.classes)})},[(0,l.createElementVNode)("div",{class:"overlayTextContainer border",style:(0,l.normalizeStyle)([{width:(()=>void 0!==e.unref(e.width)&&null!==e.unref(e.width)&&e.unref(e.width)[Symbol.for("+")]?e.unref(e.width)[Symbol.for("+")]("px"):e.unref(e.width)+"px")(),height:(()=>void 0!==e.unref(e.height)&&null!==e.unref(e.height)&&e.unref(e.height)[Symbol.for("+")]?e.unref(e.height)[Symbol.for("+")]("px"):e.unref(e.height)+"px")()},e.unref(e.borderStyle)??{}])},[e.component?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.component),{key:0,class:"overlayText",style:(0,l.normalizeStyle)(e.unref(e.textStyle))},null,8,["style"])):(0,l.createCommentVNode)("",!0)],4),(0,l.createElementVNode)("div",{class:"border",style:(0,l.normalizeStyle)([{width:(()=>void 0!==e.unref(e.width)&&null!==e.unref(e.width)&&e.unref(e.width)[Symbol.for("+")]?e.unref(e.width)[Symbol.for("+")]("px"):e.unref(e.width)+"px")(),height:(()=>void 0!==e.unref(e.height)&&null!==e.unref(e.height)&&e.unref(e.height)[Symbol.for("+")]?e.unref(e.height)[Symbol.for("+")]("px"):e.unref(e.height)+"px")()},e.unref(e.style)??{},e.unref(e.baseStyle)??{},e.unref(e.borderStyle)??{}])},[(0,l.createElementVNode)("div",{class:"fill",style:(0,l.normalizeStyle)([e.barStyle,e.unref(e.style)??{},e.unref(e.fillStyle)??{}])},null,4)],4),(0,l.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],6)):(0,l.createCommentVNode)("",!0)}var Yo=(0,l.defineComponent)({props:{progress:{type:(0,C.P5)(String,Object,Number),required:!0},width:{type:(0,C.P5)(Number),required:!0},height:{type:(0,C.P5)(Number),required:!0},direction:{type:(0,C.P5)(String),required:!0},display:(0,C.P5)(Object,String,Function),visibility:{type:(0,C.P5)(Number),required:!0},style:(0,C.P5)(Object,String,Array),classes:(0,C.P5)(Object),borderStyle:(0,C.P5)(Object,String,Array),textStyle:(0,C.P5)(Object,String,Array),baseStyle:(0,C.P5)(Object,String,Array),fillStyle:(0,C.P5)(Object,String,Array),mark:(0,C.P5)(Boolean,String),id:{type:String,required:!0}},components:{MarkNode:W,Node:A},setup(e){const{progress:o,width:t,height:n,direction:r,display:i}=(0,l.toRefs)(e),a=(0,l.computed)((()=>{let e=o.value instanceof b.ZP?o.value.toNumber():Number(o.value);return(()=>1-Math.min(Math.max(e,0),1)!==void 0&&1-Math.min(Math.max(e,0),1)!==null&&(1-Math.min(Math.max(e,0),1))[Symbol.for("*")]?(1-Math.min(Math.max(e,0),1))[Symbol.for("*")](100):100*(1-Math.min(Math.max(e,0),1)))()})),s=(0,l.computed)((()=>{const e={width:(()=>(0,C.Uv)(t)+.5!==void 0&&(0,C.Uv)(t)+.5!==null&&((0,C.Uv)(t)+.5)[Symbol.for("+")]?((0,C.Uv)(t)+.5)[Symbol.for("+")]("px"):(0,C.Uv)(t)+.5+"px")(),height:(()=>(0,C.Uv)(n)+.5!==void 0&&(0,C.Uv)(n)+.5!==null&&((0,C.Uv)(n)+.5)[Symbol.for("+")]?((0,C.Uv)(n)+.5)[Symbol.for("+")]("px"):(0,C.Uv)(n)+.5+"px")()};switch((0,l.unref)(r)){case Be.Nm.Up:e.clipPath=`inset(${a.value}% 0% 0% 0%)`,e.width=(()=>(0,C.Uv)(t)+1!==void 0&&(0,C.Uv)(t)+1!==null&&((0,C.Uv)(t)+1)[Symbol.for("+")]?((0,C.Uv)(t)+1)[Symbol.for("+")]("px"):(0,C.Uv)(t)+1+"px")();break;case Be.Nm.Down:e.clipPath=`inset(0% 0% ${a.value}% 0%)`,e.width=(()=>(0,C.Uv)(t)+1!==void 0&&(0,C.Uv)(t)+1!==null&&((0,C.Uv)(t)+1)[Symbol.for("+")]?((0,C.Uv)(t)+1)[Symbol.for("+")]("px"):(0,C.Uv)(t)+1+"px")();break;case Be.Nm.Right:e.clipPath=`inset(0% ${a.value}% 0% 0%)`;break;case Be.Nm.Left:e.clipPath=`inset(0% 0% 0% ${a.value} + '%)`;break;case Be.Nm.Default:e.clipPath="inset(0% 50% 0% 0%)";break}return e})),u=(0,C.KO)(i);return{normalizedProgress:a,barStyle:s,component:u,unref:l.unref,Visibility:y.EE}}});const Ko=(0,a.Z)(Yo,[["render",$o],["__scopeId","data-v-bfa7e8b2"]]);var Qo=Ko;const Jo=Symbol("Bar");function Xo(e){return(0,J.z2)((()=>{const o=e();return o.id=(0,y.QI)("bar-"),o.type=Jo,o[y.wA]=Qo,(0,Q.yB)(o,"visibility"),(0,y.Rh)(o,"visibility",y.EE.Visible),(0,Q.yB)(o,"width"),(0,Q.yB)(o,"height"),(0,Q.yB)(o,"direction"),(0,Q.yB)(o,"style"),(0,Q.yB)(o,"classes"),(0,Q.yB)(o,"borderStyle"),(0,Q.yB)(o,"baseStyle"),(0,Q.yB)(o,"textStyle"),(0,Q.yB)(o,"fillStyle"),(0,Q.yB)(o,"progress"),(0,Q.yB)(o,"display"),(0,Q.yB)(o,"mark"),o[y.tj]=function(){const{progress:e,width:o,height:t,direction:n,display:r,visibility:i,style:a,classes:s,borderStyle:u,textStyle:m,baseStyle:c,fillStyle:f,mark:d,id:y}=this;return{progress:e,width:o,height:t,direction:n,display:r,visibility:i,style:(0,l.unref)(a),classes:s,borderStyle:u,textStyle:m,baseStyle:c,fillStyle:f,mark:d,id:y}},o}))}const et=Symbol("Buyable");function ot(e){const o=(0,p.ax)(0);return(0,J.z2)((()=>{const t=e();if((()=>void 0!==t.canPurchase&&null!==t.canPurchase&&t.canPurchase[Symbol.for("==")]?t.canPurchase[Symbol.for("==")](null):null==t.canPurchase)()&&((()=>void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("==")]?t.resource[Symbol.for("==")](null):null==t.resource)()||(()=>void 0!==t.cost&&null!==t.cost&&t.cost[Symbol.for("==")]?t.cost[Symbol.for("==")](null):null==t.cost)()))throw console.warn("Cannot create buyable without a canPurchase property or a resource and cost property",t),"Cannot create buyable without a canPurchase property or a resource and cost property";t.id=(0,y.QI)("buyable-"),t.type=et,t[y.wA]=_e,t.amount=o,t.canAfford=(0,l.computed)((()=>{const e=t,o=(0,l.unref)(e.cost);return(()=>void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource)()&&(()=>void 0!==o&&null!==o&&o[Symbol.for("!=")]?o[Symbol.for("!=")](null):null!=o)()&&b.ZP.gte(e.resource.value,o)})),(()=>void 0!==t.canPurchase&&null!==t.canPurchase&&t.canPurchase[Symbol.for("==")]?t.canPurchase[Symbol.for("==")](null):null==t.canPurchase)()&&(t.canPurchase=(0,l.computed)((()=>(0,l.unref)(t.visibility)===y.EE.Visible&&(0,l.unref)(t.canAfford)&&b.ZP.lt(t.amount.value,(0,l.unref)(t.purchaseLimit))))),t.maxed=(0,l.computed)((()=>b.ZP.gte(t.amount.value,(0,l.unref)(t.purchaseLimit)))),(0,Q.yB)(t,"classes");const n=t.classes;t.classes=(0,l.computed)((()=>{const e=(0,l.unref)(n)||{};return t.maxed.value&&(e.bought=!0),e})),(0,Q.yB)(t,"canPurchase"),t.canClick=t.canPurchase,t.onClick=t.purchase=t.onClick??t.purchase??function(){const e=t;if((()=>void 0!==(0,l.unref)(e.canPurchase)&&null!==(0,l.unref)(e.canPurchase)&&(0,l.unref)(e.canPurchase)[Symbol.for("!")]?(0,l.unref)(e.canPurchase)[Symbol.for("!")]():!(0,l.unref)(e.canPurchase))())return;const o=(0,l.unref)(e.cost);(()=>void 0!==e.cost&&null!==e.cost&&e.cost[Symbol.for("!=")]?e.cost[Symbol.for("!=")](null):null!=e.cost)()&&(()=>void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource)()&&(e.resource.value=b.ZP.sub(e.resource.value,o),e.amount.value=b.ZP.add(e.amount.value,1)),e.onPurchase?.(o)},(0,Q.yB)(t,"display");const r=t.display;return t.display=(0,y.tZ)((()=>{const e=(0,l.unref)(r);if((0,C.RU)(e)){const o=(0,C.MM)(e);return(0,l.createVNode)(o,null,null)}if((()=>void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e)()&&(()=>void 0!==t.cost&&null!==t.cost&&t.cost[Symbol.for("!=")]?t.cost[Symbol.for("!=")](null):null!=t.cost)()&&(()=>void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("!=")]?t.resource[Symbol.for("!=")](null):null!=t.resource)()){const o=t,n=(0,C.MM)(e.title||"","h3"),r=(0,C.MM)(e.description),i=(0,C.MM)(e.effectDisplay||""),a=(0,l.unref)(o.purchaseLimit)===b.ZP.dInf?(0,l.createVNode)(l.Fragment,null,[(0,l.createTextVNode)("Amount: "),(0,b.Ht)(o.amount.value)]):(0,l.createVNode)(l.Fragment,null,[(0,l.createTextVNode)("Amount: "),(0,b.Ht)(o.amount.value),(0,l.createTextVNode)(" /")," ",(0,b.Ht)((0,l.unref)(o.purchaseLimit))]);return(0,l.createVNode)("span",null,[e.title?(0,l.createVNode)("div",null,[(0,l.createVNode)(n,null,null)]):null,(0,l.createVNode)(r,null,null),(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),a]),e.effectDisplay?(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.createTextVNode)("Currently: "),(0,l.createVNode)(i,null,null)]):null,o.cost&&(()=>void 0!==o.maxed.value&&null!==o.maxed.value&&o.maxed.value[Symbol.for("!")]?o.maxed.value[Symbol.for("!")]():!o.maxed.value)()?(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.createTextVNode)("Cost: "),(0,b.WU)((0,l.unref)(o.cost)||0)," ",t.resource.displayName]):null])}return""})),(0,Q.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,Q.yB)(t,"cost"),(0,Q.yB)(t,"resource"),(0,Q.yB)(t,"purchaseLimit"),(0,y.Rh)(t,"purchaseLimit",b.ZP.dInf),(0,Q.yB)(t,"style"),(0,Q.yB)(t,"mark"),(0,Q.yB)(t,"small"),t[y.tj]=function(){const{display:e,visibility:o,style:t,classes:n,onClick:r,canClick:i,small:a,mark:s,id:u}=this;return{display:e,visibility:o,style:(0,l.unref)(t),classes:n,onClick:r,canClick:i,small:a,mark:s,id:u}},t}))}t(3577);const tt=["disabled"];function lt(e,o,t,n,r,i){const a=(0,l.resolveComponent)("MarkNode"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.notifyStyle,e.unref(e.style)??{}]),class:(0,l.normalizeClass)({feature:!0,challenge:!0,done:e.unref(e.completed),canStart:e.unref(e.canStart)&&(()=>void 0!==e.unref(e.maxed)&&null!==e.unref(e.maxed)&&e.unref(e.maxed)[Symbol.for("!")]?e.unref(e.maxed)[Symbol.for("!")]():!e.unref(e.maxed))(),maxed:e.unref(e.maxed),...e.unref(e.classes)})},[(0,l.createElementVNode)("button",{class:"toggleChallenge",onClick:o[0]||(o[0]=(...o)=>e.toggle&&e.toggle(...o)),disabled:(()=>void 0!==e.unref(e.canStart)&&null!==e.unref(e.canStart)&&e.unref(e.canStart)[Symbol.for("!")]?e.unref(e.canStart)[Symbol.for("!")]():!e.unref(e.canStart))()||e.unref(e.maxed)},(0,l.toDisplayString)(e.buttonText),9,tt),e.unref(e.comp)?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.unref(e.comp)),{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],6)):(0,l.createCommentVNode)("",!0)}var nt=(0,l.defineComponent)({props:{active:{type:(0,C.P5)(Boolean),required:!0},maxed:{type:(0,C.P5)(Boolean),required:!0},canComplete:{type:(0,C.P5)(Boolean),required:!0},display:(0,C.P5)(String,Object,Function),visibility:{type:(0,C.P5)(Number),required:!0},style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),completed:{type:(0,C.P5)(Boolean),required:!0},canStart:{type:(0,C.P5)(Boolean),required:!0},mark:(0,C.P5)(Boolean,String),id:{type:String,required:!0},toggle:{type:Function,required:!0}},components:{MarkNode:W,Node:A},setup(e){const{active:o,maxed:t,canComplete:n,display:r}=(0,l.toRefs)(e),i=(0,l.computed)((()=>o.value?n.value?"Finish":"Exit Early":t.value?"Completed":"Start")),a=(0,l.shallowRef)(""),s=(0,l.computed)((()=>{const e=(0,C.Uv)(o),t=(0,C.Uv)(n);return e?t?ye():de():{}}));return(0,l.watchEffect)((()=>{const e=(0,C.Uv)(r);if((()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)())return void(a.value="");if((0,C.RU)(e))return void(a.value=(0,C.MM)(e));const o=(0,C.MM)(e.title||"","h3"),t=(0,C.MM)(e.description,"div"),n=(0,C.MM)(e.goal||""),i=(0,C.MM)(e.reward||""),s=(0,C.MM)(e.effectDisplay||"");a.value=(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)("span",null,[e.title?(0,l.createVNode)("div",null,[(0,l.createVNode)(o,null,null)]):null,(0,l.createVNode)(t,null,null),e.goal?(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.createTextVNode)("Goal: "),(0,l.createVNode)(n,null,null)]):null,e.reward?(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.createTextVNode)("Reward: "),(0,l.createVNode)(i,null,null)]):null,e.effectDisplay?(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Currently: "),(0,l.createVNode)(s,null,null)]):null]))))})),{buttonText:i,notifyStyle:s,comp:a,Visibility:y.EE,unref:l.unref}}});const rt=(0,a.Z)(nt,[["render",lt],["__scopeId","data-v-5e580749"]]);var it=rt;const at=Symbol("ChallengeType");function st(e){const o=(0,p.ax)(0),t=(0,p.ax)(!1);return(0,J.z2)((()=>{const n=e();if((()=>void 0!==n.canComplete&&null!==n.canComplete&&n.canComplete[Symbol.for("==")]?n.canComplete[Symbol.for("==")](null):null==n.canComplete)()&&((()=>void 0!==n.resource&&null!==n.resource&&n.resource[Symbol.for("==")]?n.resource[Symbol.for("==")](null):null==n.resource)()||(()=>void 0!==n.goal&&null!==n.goal&&n.goal[Symbol.for("==")]?n.goal[Symbol.for("==")](null):null==n.goal)()))throw console.warn("Cannot create challenge without a canComplete property or a resource and goal property",n),"Cannot create challenge without a canComplete property or a resource and goal property";n.id=(0,y.QI)("challenge-"),n.type=at,n[y.wA]=it,n.completions=o,n.active=t,n.completed=(0,l.computed)((()=>b.ZP.gt(n.completions.value,0))),n.maxed=(0,l.computed)((()=>b.ZP.gte(n.completions.value,(0,l.unref)(n.completionLimit)))),n.toggle=function(){const e=n;if(e.active.value){if((0,l.unref)(e.canComplete)&&(()=>void 0!==e.maxed.value&&null!==e.maxed.value&&e.maxed.value[Symbol.for("!")]?e.maxed.value[Symbol.for("!")]():!e.maxed.value)()){let o=(0,l.unref)(e.canComplete);"boolean"===typeof o&&(o=1),e.completions.value=b.ZP.min(b.ZP.add(e.completions.value,o),(0,l.unref)(e.completionLimit)),e.onComplete?.()}e.active.value=!1,e.onExit?.(),e.reset?.reset()}else(0,l.unref)(e.canStart)&&(0,l.unref)(e.visibility)===y.EE.Visible&&(()=>void 0!==e.maxed.value&&null!==e.maxed.value&&e.maxed.value[Symbol.for("!")]?e.maxed.value[Symbol.for("!")]():!e.maxed.value)()&&(e.reset?.reset(),e.active.value=!0,e.onEnter?.())},n.complete=function(e){const o=n;let t=(0,l.unref)(o.canComplete);o.active.value&&(()=>void 0!==t&&null!==t&&t[Symbol.for("!==")]?t[Symbol.for("!==")](!1):!1!==t)()&&(!0===t||b.ZP.neq(0,t))&&(()=>void 0!==o.maxed.value&&null!==o.maxed.value&&o.maxed.value[Symbol.for("!")]?o.maxed.value[Symbol.for("!")]():!o.maxed.value)()&&("boolean"===typeof t&&(t=1),o.completions.value=b.ZP.min(b.ZP.add(o.completions.value,t),(0,l.unref)(o.completionLimit)),o.onComplete?.(),(()=>void 0!==e&&null!==e&&e[Symbol.for("!==")]?e[Symbol.for("!==")](!0):!0!==e)()&&(o.active.value=!1,o.onExit?.(),o.reset?.reset()))},(0,Q.yB)(n,"visibility"),(0,y.Rh)(n,"visibility",y.EE.Visible);const r=n.visibility;return n.visibility=(0,l.computed)((()=>!0===Se.ZP.hideChallenges&&(0,l.unref)(n.maxed)?y.EE.None:(0,l.unref)(r))),(()=>void 0!==n.canComplete&&null!==n.canComplete&&n.canComplete[Symbol.for("==")]?n.canComplete[Symbol.for("==")](null):null==n.canComplete)()&&(n.canComplete=(0,l.computed)((()=>{const e=n;return!((()=>void 0!==e.active.value&&null!==e.active.value&&e.active.value[Symbol.for("!")]?e.active.value[Symbol.for("!")]():!e.active.value)()||(()=>void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("==")]?e.resource[Symbol.for("==")](null):null==e.resource)()||(()=>void 0!==e.goal&&null!==e.goal&&e.goal[Symbol.for("==")]?e.goal[Symbol.for("==")](null):null==e.goal)())&&b.ZP.gte(e.resource.value,(0,l.unref)(e.goal))}))),(()=>void 0!==n.mark&&null!==n.mark&&n.mark[Symbol.for("==")]?n.mark[Symbol.for("==")](null):null==n.mark)()&&(n.mark=(0,l.computed)((()=>b.ZP.gt((0,l.unref)(n.completionLimit),1)&&(()=>void 0!==!(0,l.unref)(n.maxed)&&null!==!(0,l.unref)(n.maxed)&&(!(0,l.unref)(n.maxed))[Symbol.for("!")]?(!(0,l.unref)(n.maxed))[Symbol.for("!")]():!!(0,l.unref)(n.maxed))()))),(0,Q.yB)(n,"canStart"),(0,y.Rh)(n,"canStart",!0),(0,Q.yB)(n,"canComplete"),(0,Q.yB)(n,"completionLimit"),(0,y.Rh)(n,"completionLimit",1),(0,Q.yB)(n,"mark"),(0,Q.yB)(n,"goal"),(0,Q.yB)(n,"classes"),(0,Q.yB)(n,"style"),(0,Q.yB)(n,"display"),(()=>void 0!==n.reset&&null!==n.reset&&n.reset[Symbol.for("!=")]?n.reset[Symbol.for("!=")](null):null!=n.reset)()&&h.globalBus.on("reset",(e=>{e===n.reset&&n.active.value&&n.toggle()})),n[y.tj]=function(){const{active:e,maxed:o,canComplete:t,display:n,visibility:r,style:i,classes:a,completed:s,canStart:u,mark:m,id:c,toggle:f}=this;return{active:e,maxed:o,canComplete:t,display:n,visibility:r,style:(0,l.unref)(i),classes:a,completed:s,canStart:u,mark:m,id:c,toggle:f}},n}))}h.globalBus.on("loadSettings",(e=>{(0,y.Rh)(e,"hideChallenges",!1)})),(0,Se.QV)((0,y.tZ)((()=>(0,l.createVNode)(Uo.Z,{title:"Hide Maxed Challenges","onUpdate:modelValue":e=>Se.ZP.hideChallenges=e,modelValue:Se.ZP.hideChallenges},null))));const ut=(0,l.shallowReactive)({}),mt=Symbol("Hotkey");function ct(e){return(0,J.z2)((()=>{const o=e();return o.type=mt,(0,Q.yB)(o,"enabled"),(0,y.Rh)(o,"enabled",!0),(0,Q.yB)(o,"description"),o}))}h.globalBus.on("addLayer",(e=>{(0,y.bD)(e,mt).forEach((e=>{ut[e.key]=e}))})),h.globalBus.on("removeLayer",(e=>{(0,y.bD)(e,mt).forEach((e=>{ut[e.key]=void 0}))})),document.onkeydown=function(e){if("INPUT"===e.target?.tagName)return;if(al.value&&(()=>void 0!==re.Z.keepGoing&&null!==re.Z.keepGoing&&re.Z.keepGoing[Symbol.for("!")]?re.Z.keepGoing[Symbol.for("!")]():!re.Z.keepGoing)())return;let o=e.key;e.shiftKey&&(o=(()=>"shift+"[Symbol.for("+")]?"shift+"[Symbol.for("+")](o):"shift+"+o)()),e.ctrlKey&&(o=(()=>"ctrl+"[Symbol.for("+")]?"ctrl+"[Symbol.for("+")](o):"ctrl+"+o)());const t=ut[o];t&&(0,l.unref)(t.enabled)&&(e.preventDefault(),t.onPress())},(0,Se.fw)((0,y.tZ)((()=>{const e=Object.values(ut).filter((e=>(0,l.unref)(e?.enabled)));return 0===e.length?"":(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.createVNode)("h4",null,[(0,l.createTextVNode)("Hotkeys")]),e.map((e=>(0,l.createVNode)("div",null,[e?.key,(0,l.createTextVNode)(": "),e?.description])))])})));const ft=Symbol("Links");function dt(e){return(0,J.z2)((()=>{const o=e();return o.type=ft,o[y.wA]=D,(0,Q.yB)(o,"links"),o[y.tj]=function(){const{links:e}=this;return{links:e}},o}))}var yt=t(5418);function bt(e,o,t,n,r,i){const a=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??{}]),class:(0,l.normalizeClass)({feature:!0,milestone:!0,done:e.unref(e.earned),...e.unref(e.classes)})},[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.unref(e.comp)))),(0,l.createVNode)(a,{id:e.id},null,8,["id"])],6)):(0,l.createCommentVNode)("",!0)}var ht=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},display:{type:(0,C.P5)(String,Object,Function),required:!0},style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),earned:{type:(0,C.P5)(Boolean),required:!0},id:{type:String,required:!0}},components:{Node:A},setup(e){const{display:o}=(0,l.toRefs)(e),t=(0,l.shallowRef)("");return(0,l.watchEffect)((()=>{const e=(0,C.Uv)(o);if((()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)())return void(t.value="");if((0,C.RU)(e))return void(t.value=(0,C.MM)(e));const n=(0,C.MM)(e.requirement,"h3"),r=(0,C.MM)(e.effectDisplay||"","b"),i=(0,C.MM)(e.optionsDisplay||"","span");t.value=(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)("span",null,[(0,l.createVNode)(n,null,null),e.effectDisplay?(0,l.createVNode)("div",null,[(0,l.createVNode)(r,null,null)]):null,e.optionsDisplay?(0,l.createVNode)("div",{class:"equal-spaced"},[(0,l.createVNode)(i,null,null)]):null]))))})),{comp:t,unref:l.unref,Visibility:y.EE}}});const pt=(0,a.Z)(ht,[["render",bt],["__scopeId","data-v-0b660ac3"]]);var vt=pt;const gt=(0,fe.pm)(),St=Symbol("Milestone");var Nt;function kt(e){const o=(0,p.ax)(!1);return(0,J.z2)((()=>{const t=e?.()??{};t.id=(0,y.QI)("milestone-"),t.type=St,t[y.wA]=vt,t.earned=o,t.complete=function(){o.value=!0},(0,Q.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible);const n=t.visibility;if(t.visibility=(0,l.computed)((()=>{const e=(0,l.unref)(t.display);switch(Se.ZP.msDisplay){default:case Nt.All:return(0,l.unref)(n);case Nt.Configurable:return(0,l.unref)(t.earned)&&(()=>void 0!==(null!=e&&"object"==typeof e&&"optionsDisplay"in e)&&null!==(null!=e&&"object"==typeof e&&"optionsDisplay"in e)&&(null!=e&&"object"==typeof e&&"optionsDisplay"in e)[Symbol.for("!")]?(null!=e&&"object"==typeof e&&"optionsDisplay"in e)[Symbol.for("!")]():!(null!=e&&"object"==typeof e&&"optionsDisplay"in e))()?y.EE.None:(0,l.unref)(n);case Nt.Incomplete:return(0,l.unref)(t.earned)?y.EE.None:(0,l.unref)(n);case Nt.None:return y.EE.None}})),(0,Q.yB)(t,"style"),(0,Q.yB)(t,"classes"),(0,Q.yB)(t,"display"),t[y.tj]=function(){const{visibility:e,display:o,style:t,classes:n,earned:r,id:i}=this;return{visibility:e,display:o,style:(0,l.unref)(t),classes:n,earned:r,id:i}},t.shouldEarn){const e=t;(0,l.watchEffect)((()=>{if((()=>void 0!==e.earned.value&&null!==e.earned.value&&e.earned.value[Symbol.for("!")]?e.earned.value[Symbol.for("!")]():!e.earned.value)()&&(0,l.unref)(e.visibility)===y.EE.Visible&&e.shouldEarn?.()&&(e.earned.value=!0,e.onComplete?.(),e.display)){const o=(0,l.unref)(e.display),t=(0,C.MM)((0,C.RU)(o)?o:o.requirement);gt((0,l.createVNode)(l.Fragment,null,[(0,l.createVNode)("h3",null,[(0,l.createTextVNode)("Milestone earned!")]),(0,l.createVNode)("div",null,[(0,l.createVNode)(t,null,null)])]))}}))}return t}))}(function(e){e["All"]="all",e["Configurable"]="configurable",e["Incomplete"]="incomplete",e["None"]="none"})(Nt||(Nt={})),h.globalBus.on("loadSettings",(e=>{(0,y.Rh)(e,"msDisplay",Nt.All)}));const Vt=Object.values(Nt).map((e=>({label:(0,Be.IJ)(e),value:e})));(0,Se.QV)((0,y.tZ)((()=>(0,l.createVNode)(yt.Z,{title:"Show Milestones",options:Vt,"onUpdate:modelValue":e=>Se.ZP.msDisplay=e,modelValue:Se.ZP.msDisplay},null))));var xt=(0,l.defineComponent)({props:{display:null},setup(e){const o=e,{display:t}=(0,l.toRefs)(o),n=(0,C.vq)(t);return(e,o)=>((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(n))))}});const Mt=xt;var Ct=Mt;const wt=Symbol("Tab");function Zt(e){return(0,J.z2)((()=>{const o=e();return o.id=(0,y.QI)("tab-"),o.type=wt,o[y.wA]=Ct,o[y.tj]=function(){const{display:e}=this;return{display:e}},o}))}function Bt(e,o,t,n,r,i){return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:0,onClick:o[0]||(o[0]=(...o)=>e.selectTab&&e.selectTab(...o)),class:(0,l.normalizeClass)(["tabButton",{active:e.active,...e.unref(e.classes)}]),style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.glowColorStyle,e.unref(e.style)??{}])},[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.component)))],6)):(0,l.createCommentVNode)("",!0)}var Pt=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},display:{type:(0,C.P5)(Object,String,Function),required:!0},style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),glowColor:(0,C.P5)(String),active:Boolean,floating:Boolean},emits:["selectTab"],setup(e,{emit:o}){const{display:t,glowColor:n,floating:r}=(0,l.toRefs)(e),i=(0,C.vq)(t),a=(0,l.computed)((()=>{const e=(0,C.Uv)(n);return(()=>void 0!==e&&null!==e&&e[Symbol.for("!")]?e[Symbol.for("!")]():!e)()?{}:(0,l.unref)(r)?de(e):{boxShadow:`0px 9px 5px -6px ${e}`}}));function s(){o("selectTab")}return{selectTab:s,component:i,glowColorStyle:a,unref:l.unref,Visibility:y.EE}}});const Et=(0,a.Z)(Pt,[["render",Bt],["__scopeId","data-v-3e3f03f9"]]);var Ft=Et;function Tt(e,o,t,n,r,i){const a=(0,l.resolveComponent)("TabButton"),s=(0,l.resolveComponent)("Sticky");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,class:(0,l.normalizeClass)(["tab-family-container",{...e.unref(e.classes),...e.tabClasses}]),style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??[],e.tabStyle??[]])},[(0,l.createVNode)(s,{class:"tab-buttons-container"},{default:(0,l.withCtx)((()=>[(0,l.createElementVNode)("div",{class:(0,l.normalizeClass)(["tab-buttons",{floating:e.floating}])},[((0,l.openBlock)(!0),(0,l.createElementBlock)(l.Fragment,null,(0,l.renderList)(e.unref(e.tabs),((o,t)=>((0,l.openBlock)(),(0,l.createBlock)(a,(0,l.mergeProps)({onSelectTab:o=>e.selected.value=t,floating:e.floating,key:t,active:e.unref(o.tab)===e.unref(e.activeTab)},e.gatherButtonProps(o)),null,16,["onSelectTab","floating","active"])))),128))],2)])),_:1}),e.unref(e.activeTab)?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.unref(e.component)),{key:0})):(0,l.createCommentVNode)("",!0)],6)):(0,l.createCommentVNode)("",!0)}var Dt=(0,l.defineComponent)({props:{visibility:{type:(0,C.P5)(Number),required:!0},activeTab:{type:(0,C.P5)(Object),required:!0},selected:{type:Object,required:!0},tabs:{type:(0,C.P5)(Object),required:!0},style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object)},components:{Sticky:zo,TabButton:Ft},setup(e){const{activeTab:o}=(0,l.toRefs)(e),t=(0,l.computed)((()=>ge.Z[Se.ZP.theme].floatingTabs)),n=(0,l.shallowRef)("");(0,l.watchEffect)((()=>{const e=(0,C.Uv)(o);(()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)()?n.value="":(0,C.RU)(e)?n.value=(0,C.MM)(e):n.value=(0,C.MM)((0,l.unref)(e.display))}));const r=(0,l.computed)((()=>{const e=(0,C.Uv)(o),t=(0,C.RU)(e)||(()=>void 0!==e&&null!==e&&e[Symbol.for("!")]?e[Symbol.for("!")]():!e)()?void 0:(0,l.unref)(e.classes);return t})),i=(0,l.computed)((()=>{const e=(0,C.Uv)(o);return(0,C.RU)(e)||(()=>void 0!==e&&null!==e&&e[Symbol.for("!")]?e[Symbol.for("!")]():!e)()?void 0:(0,l.unref)(e.style)}));function a(e){const{display:o,style:t,classes:n,glowColor:r,visibility:i}=e;return{display:o,style:(0,l.unref)(t),classes:n,glowColor:r,visibility:i}}return{floating:t,tabClasses:r,tabStyle:i,Visibility:y.EE,component:n,gatherButtonProps:a,unref:l.unref}}});const It=(0,a.Z)(Dt,[["render",Tt],["__scopeId","data-v-46a6b098"]]);var Rt=It;const _t=Symbol("TabButton"),Ot=Symbol("TabFamily");function Ut(e,o){if(0===Object.keys(e).length)throw console.warn("Cannot create tab family with 0 tabs"),"Cannot create tab family with 0 tabs";const t=(0,p.ax)(Object.keys(e)[0]);return(0,J.z2)((()=>{const n=o?.()??{};n.id=(0,y.QI)("tabFamily-"),n.type=Ot,n[y.wA]=Rt,n.tabs=Object.keys(e).reduce(((o,t)=>{const l=e[t]();return l.type=_t,l[y.wA]=Ft,(0,Q.yB)(l,"visibility"),(0,y.Rh)(l,"visibility",y.EE.Visible),(0,Q.yB)(l,"tab"),(0,Q.yB)(l,"display"),(0,Q.yB)(l,"classes"),(0,Q.yB)(l,"style"),(0,Q.yB)(l,"glowColor"),o[t]=l,o}),{}),n.selected=t,n.activeTab=(0,l.computed)((()=>{const e=(0,l.unref)(r.tabs);if((()=>void 0!==t.value&&null!==t.value&&t.value[Symbol.for("in")]?t.value[Symbol.for("in")](e):t.value in e)()&&(0,l.unref)(e[t.value].visibility)===y.EE.Visible)return(0,l.unref)(e[t.value].tab);const o=Object.values(e).find((e=>(0,l.unref)(e.visibility)===y.EE.Visible));return o?(0,l.unref)(o.tab):null})),(0,Q.yB)(n,"visibility"),(0,y.Rh)(n,"visibility",y.EE.Visible),(0,Q.yB)(n,"classes"),(0,Q.yB)(n,"style"),n[y.tj]=function(){const{visibility:e,activeTab:o,selected:t,tabs:n,style:r,classes:i}=this;return{visibility:e,activeTab:o,selected:t,tabs:n,style:(0,l.unref)(r),classes:i}};const r=n;return r}))}const jt=["disabled"];function At(e,o,t,n,r,i){const a=(0,l.resolveComponent)("MarkNode"),s=(0,l.resolveComponent)("Node");return(()=>void 0!==e.unref(e.visibility)&&null!==e.unref(e.visibility)&&e.unref(e.visibility)[Symbol.for("!==")]?e.unref(e.visibility)[Symbol.for("!==")](e.Visibility.None):e.unref(e.visibility)!==e.Visibility.None)()?((0,l.openBlock)(),(0,l.createElementBlock)("button",{key:0,style:(0,l.normalizeStyle)([{visibility:e.unref(e.visibility)===e.Visibility.Hidden?"hidden":void 0},e.unref(e.style)??{}]),onClick:o[0]||(o[0]=(...o)=>e.purchase&&e.purchase(...o)),class:(0,l.normalizeClass)({feature:!0,upgrade:!0,can:e.unref(e.canPurchase),locked:(()=>void 0!==e.unref(e.canPurchase)&&null!==e.unref(e.canPurchase)&&e.unref(e.canPurchase)[Symbol.for("!")]?e.unref(e.canPurchase)[Symbol.for("!")]():!e.unref(e.canPurchase))(),bought:e.unref(e.bought),...e.unref(e.classes)}),disabled:(()=>void 0!==e.unref(e.canPurchase)&&null!==e.unref(e.canPurchase)&&e.unref(e.canPurchase)[Symbol.for("!")]?e.unref(e.canPurchase)[Symbol.for("!")]():!e.unref(e.canPurchase))()},[e.unref(e.component)?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.unref(e.component)),{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(a,{mark:e.unref(e.mark)},null,8,["mark"]),(0,l.createVNode)(s,{id:e.id},null,8,["id"])],14,jt)):(0,l.createCommentVNode)("",!0)}var qt=(0,l.defineComponent)({props:{display:{type:(0,C.P5)(String,Object,Function),required:!0},visibility:{type:(0,C.P5)(Number),required:!0},style:(0,C.P5)(String,Object,Array),classes:(0,C.P5)(Object),resource:Object,cost:(0,C.P5)(String,Object,Number),canPurchase:{type:(0,C.P5)(Boolean),required:!0},bought:{type:(0,C.P5)(Boolean),required:!0},mark:(0,C.P5)(Boolean,String),id:{type:String,required:!0},purchase:{type:Function,required:!0}},components:{Node:A,MarkNode:W},setup(e){const{display:o,cost:t}=(0,l.toRefs)(e),n=(0,l.shallowRef)("");return(0,l.watchEffect)((()=>{const r=(0,C.Uv)(o);if((()=>void 0!==r&&null!==r&&r[Symbol.for("==")]?r[Symbol.for("==")](null):null==r)())return void(n.value="");if((0,C.RU)(r))return void(n.value=(0,C.MM)(r));const i=(0,C.Uv)(t),a=(0,C.MM)(r.title||"","h3"),s=(0,C.MM)(r.description,"div"),u=(0,C.MM)(r.effectDisplay||"");n.value=(0,C.MM)((0,y.tZ)((()=>(0,l.createVNode)("span",null,[r.title?(0,l.createVNode)("div",null,[(0,l.createVNode)(a,null,null)]):null,(0,l.createVNode)(s,null,null),r.effectDisplay?(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Currently: "),(0,l.createVNode)(u,null,null)]):null,(()=>void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource)()?(0,l.createVNode)(l.Fragment,null,[(0,l.createVNode)("br",null,null),(0,l.createTextVNode)("Cost: "),e.resource&&x(e.resource,i)," ",e.resource?.displayName]):null]))))})),{component:n,unref:l.unref,Visibility:y.EE}}});const zt=(0,a.Z)(qt,[["render",At],["__scopeId","data-v-6f164fe2"]]);var Lt=zt;const Gt=Symbol("Upgrade");function Ht(e){const o=(0,p.ax)(!1);return(0,J.z2)((()=>{const t=e();return t.id=(0,y.QI)("upgrade-"),t.type=Gt,t[y.wA]=Lt,(()=>void 0!==t.canAfford&&null!==t.canAfford&&t.canAfford[Symbol.for("==")]?t.canAfford[Symbol.for("==")](null):null==t.canAfford)()&&((()=>void 0!==t.resource&&null!==t.resource&&t.resource[Symbol.for("==")]?t.resource[Symbol.for("==")](null):null==t.resource)()||(()=>void 0!==t.cost&&null!==t.cost&&t.cost[Symbol.for("==")]?t.cost[Symbol.for("==")](null):null==t.cost)())&&console.warn("Error: can't create upgrade without a canAfford property or a resource and cost property",t),t.bought=o,(()=>void 0!==t.canAfford&&null!==t.canAfford&&t.canAfford[Symbol.for("==")]?t.canAfford[Symbol.for("==")](null):null==t.canAfford)()?t.canAfford=(0,l.computed)((()=>{const e=t;return(()=>void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource)()&&(()=>void 0!==e.cost&&null!==e.cost&&e.cost[Symbol.for("!=")]?e.cost[Symbol.for("!=")](null):null!=e.cost)()&&b.ZP.gte(e.resource.value,(0,l.unref)(e.cost))})):(0,Q.yB)(t,"canAfford"),t.canPurchase=(0,l.computed)((()=>(0,l.unref)(t.visibility)===y.EE.Visible&&(0,l.unref)(t.canAfford)&&(()=>void 0!==(0,l.unref)(t.bought)&&null!==(0,l.unref)(t.bought)&&(0,l.unref)(t.bought)[Symbol.for("!")]?(0,l.unref)(t.bought)[Symbol.for("!")]():!(0,l.unref)(t.bought))())),t.purchase=function(){const e=t;(()=>void 0!==(0,l.unref)(e.canPurchase)&&null!==(0,l.unref)(e.canPurchase)&&(0,l.unref)(e.canPurchase)[Symbol.for("!")]?(0,l.unref)(e.canPurchase)[Symbol.for("!")]():!(0,l.unref)(e.canPurchase))()||((()=>void 0!==e.resource&&null!==e.resource&&e.resource[Symbol.for("!=")]?e.resource[Symbol.for("!=")](null):null!=e.resource)()&&(()=>void 0!==e.cost&&null!==e.cost&&e.cost[Symbol.for("!=")]?e.cost[Symbol.for("!=")](null):null!=e.cost)()&&(e.resource.value=b.ZP.sub(e.resource.value,(0,l.unref)(e.cost))),o.value=!0,e.onPurchase?.())},(0,Q.yB)(t,"visibility"),(0,y.Rh)(t,"visibility",y.EE.Visible),(0,Q.yB)(t,"classes"),(0,Q.yB)(t,"style"),(0,Q.yB)(t,"display"),(0,Q.yB)(t,"mark"),(0,Q.yB)(t,"cost"),(0,Q.yB)(t,"resource"),t[y.tj]=function(){const{display:e,visibility:o,style:t,classes:n,resource:r,cost:i,canPurchase:a,bought:s,mark:u,id:m,purchase:c}=this;return{display:e,visibility:o,style:(0,l.unref)(t),classes:n,resource:r,cost:i,canPurchase:a,bought:s,mark:u,id:m,purchase:c}},t}))}function Wt(e){return"function"===typeof e||"[object Object]"===Object.prototype.toString.call(e)&&(()=>void 0!==(0,l.isVNode)(e)&&null!==(0,l.isVNode)(e)&&(0,l.isVNode)(e)[Symbol.for("!")]?(0,l.isVNode)(e)[Symbol.for("!")]():!(0,l.isVNode)(e))()}const $t="c",Yt=(0,w.createLayer)($t,(()=>{const e="#4BDC13",o="Candies",t=v(0,"lollipops"),n=g(t),r=(0,p.ax)(!1),i=(0,p.ax)("pointy"),a=(0,p.ax)(10),s=(0,p.ax)(new b.ZP(10)),u=(0,l.computed)((()=>b.ZP.pow(t.value,.2))),m=(0,l.computed)((()=>b.ZP.times(t.value,10))),c=to((()=>({title:"Lore",titleStyle:{color:"#FE0000"},display:"DEEP LORE!",bodyStyle:{backgroundColor:"#0000EE"},color:"rgb(75, 220, 19)"}))),f=kt((()=>({shouldEarn(){return b.ZP.gte(n.value,3)},display:{requirement:"3 Lollipops",effectDisplay:"Unlock the next milestone"}}))),h=kt((()=>({visibility(){return(0,y.Kf)(f.earned.value)},shouldEarn(){return b.ZP.gte(n.value,4)},display:{requirement:"4 Lollipops",effectDisplay:"You can toggle beep and boop (which do nothing)",optionsDisplay:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[(0,l.createVNode)(Uo.Z,{title:"beep","onUpdate:modelValue":e=>r.value=e,modelValue:r.value},null),(0,l.createVNode)(Uo.Z,{title:"boop","onUpdate:modelValue":e=>el.boop.value=e,modelValue:el.boop.value},null)])))},style(){return this.earned?{backgroundColor:"#1111DD"}:{}}}))),S=[f,h],N=st((()=>({title:"Fun",completionLimit:3,display(){return{description:`Makes the game 0% harder<br>${(0,b.Ht)(this.completions.value)}/${this.completionLimit} completions`,goal:"Have 20 points I guess",reward:"Says hi",effectDisplay:(()=>void 0!==(0,b.WU)(k.value)&&null!==(0,b.WU)(k.value)&&(0,b.WU)(k.value)[Symbol.for("+")]?(0,b.WU)(k.value)[Symbol.for("+")]("x"):(0,b.WU)(k.value)+"x")()}},visibility(){return(0,y.Kf)(b.ZP.gt(n.value,0))},goal:20,resource:rl.points,onComplete(){console.log("hiii")},onEnter(){rl.points.value=0,rl.best.value=rl.points.value,rl.total.value=rl.points.value,console.log("So challenging")},onExit(){console.log("Sweet freedom!")},style:{height:"200px"}}))),k=(0,l.computed)((()=>b.ZP.add(t.value,1).tetrate(.02))),V=Ht((()=>({display:{title:"Generator of Genericness",description:"Gain 1 point every second"},cost:1,resource:t}))),M=Ht((()=>({display:()=>({description:"Point generation is faster based on your unspent Lollipops",effectDisplay:`${(0,b.WU)(w.value)}x`}),cost:1,resource:t,visibility:()=>(0,y.Kf)(V.bought.value)}))),w=(0,l.computed)((()=>{let e=b.ZP.add(t.value,1).pow(.5);return e.gte("1e20000000")&&(e=e.sqrt().times("1e10000000")),e})),Z=Ht((()=>({visibility(){return(0,y.Kf)(M.bought.value)},canAfford(){return b.ZP.lt(rl.points.value,7)},onPurchase(){rl.points.value=b.ZP.add(rl.points.value,7)},display:"Only buyable with less than 7 points, and gives you 7 more. Unlocks a secret subtab.",style(){return this.bought?{backgroundColor:"#1111dd"}:(()=>void 0!==this.canAfford&&null!==this.canAfford&&this.canAfford[Symbol.for("!")]?this.canAfford[Symbol.for("!")]():!this.canAfford)()?{backgroundColor:"#dd1111"}:{}}}))),B=Ht((()=>({resource:v(E.amount,"Exhancers",0),cost:3,display:{title:"This upgrade doesn't exist",description:"Or does it?"}}))),P=[V,M,Z],E=ot((()=>({resource:t,cost(){let e=new b.ZP(this.amount.value);e.gte(25)&&(e=e.pow(2).div(25));const o=b.ZP.pow(2,e.pow(1.5));return o.floor()},display(){return{title:"Exhancers",description:`Adds ${(0,b.WU)(F.value)} things and multiplies stuff by ${(0,b.WU)(T.value)}.`}},onPurchase(e){s.value=b.ZP.add(s.value,e??0)},style:{height:"222px"},purchaseLimit:4}))),F=(0,l.computed)((()=>b.ZP.gte(E.amount.value,0)?b.ZP.pow(25,b.ZP.pow(E.amount.value,1.1)):b.ZP.pow((()=>1[Symbol.for("/")]?1[Symbol.for("/")](25):.04)(),b.ZP.times(E.amount.value,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()).pow(1.1)))),T=(0,l.computed)((()=>b.ZP.gte(E.amount.value,0)?b.ZP.pow(25,b.ZP.pow(E.amount.value,1.1)):b.ZP.pow((()=>1[Symbol.for("/")]?1[Symbol.for("/")](25):.04)(),b.ZP.times(E.amount.value,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)()).pow(1.1)))),D=(0,p.ax)(!1),I=(0,l.ref)(!1),R=Ue((()=>({small:!0,display:"Respec Thingies",onClick(){D.value&&(()=>void 0!==I.value&&null!==I.value&&I.value[Symbol.for("!")]?I.value[Symbol.for("!")]():!I.value)()?I.value=!0:(t.value=b.ZP.add(t.value,s.value),E.amount.value=0,rl.tree.reset(G))}}))),_=Ue((()=>({small:!0,display:"Sell One",onClick(){b.ZP.lte(E.amount.value,0)||(E.amount.value=b.ZP.sub(E.amount.value,1),t.value=b.ZP.add(t.value,E.cost.value),s.value=b.ZP.sub(s.value,E.cost.value))}}))),O=(0,y.tZ)((()=>(0,l.createVNode)(jo.Z,null,{default:()=>[(0,l.createVNode)(ie.Z,null,{default:()=>[(0,l.createVNode)(Uo.Z,{title:"Confirm","onUpdate:modelValue":e=>D.value=e,modelValue:D.value},null),(0,C._4)(R)]}),(0,C._4)(E),(0,C._4)(_),(0,l.createVNode)(Wo.Z,{modelValue:I.value,"onUpdate:modelValue":e=>I.value=e},{header:()=>(0,l.createVNode)("h2",null,[(0,l.createTextVNode)("Confirm Respec")]),body:()=>(0,l.createVNode)(l.Fragment,null,[(0,l.createTextVNode)("Are you sure? Respeccing these doesn't accomplish much")]),footer:()=>(0,l.createVNode)("div",{class:"modal-default-footer"},[(0,l.createVNode)("div",{class:"modal-default-flex-grow"},null),(0,l.createVNode)("button",{class:"button modal-default-button",onClick:()=>I.value=!1},[(0,l.createTextVNode)("Cancel")]),(0,l.createVNode)("button",{class:"button modal-default-button danger",onClick:()=>{R.onClick(),I.value=!1}},[(0,l.createTextVNode)("Respec")])])})]}))),U=Xo((()=>({fillStyle:{backgroundColor:"#FFFFFF"},baseStyle:{backgroundColor:"#696969"},textStyle:{color:"#04e050"},direction:Be.Nm.Right,width:300,height:30,progress(){return b.ZP.add(rl.points.value,1).log(10).div(10).toNumber()},display(){return(()=>void 0!==(0,b.WU)(rl.points.value)&&null!==(0,b.WU)(rl.points.value)&&(0,b.WU)(rl.points.value)[Symbol.for("+")]?(0,b.WU)(rl.points.value)[Symbol.for("+")](" / 1e10 points"):(0,b.WU)(rl.points.value)+" / 1e10 points")()}}))),j=Xo((()=>({fillStyle:{backgroundColor:"#4BEC13"},baseStyle:{backgroundColor:"#000000"},textStyle:{textShadow:"0px 0px 2px #000000"},borderStyle:{borderWidth:"7px"},direction:Be.Nm.Up,width:50,height:200,progress(){return b.ZP.div(rl.points.value,100)},display(){return(()=>void 0!==(0,b.Ht)(b.ZP.div(rl.points.value,1).min(100))&&null!==(0,b.Ht)(b.ZP.div(rl.points.value,1).min(100))&&(0,b.Ht)(b.ZP.div(rl.points.value,1).min(100))[Symbol.for("+")]?(0,b.Ht)(b.ZP.div(rl.points.value,1).min(100))[Symbol.for("+")]("%"):(0,b.Ht)(b.ZP.div(rl.points.value,1).min(100))+"%")()}}))),A=Xo((()=>({fillStyle:{backgroundColor:"#FE0102"},baseStyle:{backgroundColor:"#222222"},textStyle:{textShadow:"0px 0px 2px #000000"},direction:Be.Nm.Up,width:100,height:30,progress(){return b.ZP.div(t.value,50)}}))),q=Le((()=>({scaling:We(ze(10,.5),1e100,.5),baseResource:rl.points,gainResource:t,roundUpCost:!0,gainModifier:Po(Bo(2,"Because I felt like it"),wo(1,"Nice modifier"))}))),z=fo((()=>({thingsToReset:()=>[Yt]}))),L=[ct((()=>({key:"c",description:"reset for lollipops or whatever",onPress(){H.canClick.value&&H.onClick()}}))),ct((()=>({key:"ctrl+c",description:"respec things",onPress(){R.onClick()}})))],G=Ae((()=>({layerID:$t,color:e,reset:z,mark:"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png",tooltip(){let e=x(t);return b.ZP.gt(E.amount.value,0)&&(e=(()=>void 0!==e&&null!==e&&e[Symbol.for("+")]?e[Symbol.for("+")](`<br><i><br><br><br>${(0,b.Ht)(E.amount.value)} Exhancers</i>`):e+`<br><i><br><br><br>${(0,b.Ht)(E.amount.value)} Exhancers</i>`)()),e},style:{color:"#3325CC",textDecoration:"underline"}})));Co(G,{display:ne(t),pinnable:!0});const H=je((()=>({conversion:q,tree:rl.tree,treeNode:G,style:{color:"#AA66AA"},resetDescription:"Melt your points into "})));Co(H,{display:(0,y.tZ)((()=>Eo("Modifiers","",q.gainModifier,q.scaling.currentGain(q)))),pinnable:!0,direction:Be.Nm.Down,style:"width: 400px; text-align: left"});const W=oe((()=>({display:"TH",color:"#6d3678",canClick(){return b.ZP.gte(rl.points.value,10)},tooltip:"Thanos your points",onClick(){rl.points.value=b.ZP.div(rl.points.value,2),console.log("Thanos'd")},glowColor(){return b.ZP.eq(E.amount.value,1)?"orange":""}}))),$=oe((()=>({display:"h",color(){return ge.Z[Se.ZP.theme].variables["--locked"]},tooltip:{display:(0,l.computed)((()=>`Restore your points to ${(0,b.WU)(a.value)}`)),right:!0},canClick(){return b.ZP.lt(rl.points.value,a.value)},onClick(){rl.points.value=a.value}}))),Y=oe((()=>({visibility:y.EE.Hidden}))),K=te((()=>({nodes(){return[[el.treeNode,G],[W,Y,$]]},branches(){return[{startNode:el.treeNode,endNode:G,"stroke-width":"25px",stroke:"green",style:{filter:"blur(5px)"}},{startNode:G,endNode:W},{startNode:W,endNode:$}]}}))),Q=dt((()=>({links:[{startNode:$,endNode:A,"stroke-width":"5px",stroke:"red",offsetEnd:{x:(()=>(-50)[Symbol.for("+")]?(-50)[Symbol.for("+")](100*A.progress.value.toNumber()):100*A.progress.value.toNumber()-50)(),y:0}}]}))),J=Ut({first:()=>({tab:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[(0,C._4)(...P),(0,C._4)(B),(0,l.createVNode)("div",null,[(0,l.createTextVNode)("confirmed")])]))),display:"first"}),second:()=>({tab:el.display,display:"second"})},(()=>({style:{width:"660px",backgroundColor:"brown","--background":"brown",border:"solid white",marginLeft:"auto",marginRight:"auto"}}))),X=Ut({mainTab:()=>({tab:Zt((()=>({display:(0,y.tZ)((()=>{let o;return(0,l.createVNode)(l.Fragment,null,[(0,l.createVNode)(Mo,{resource:t,color:e,effectDisplay:`which are boosting waffles by ${(0,b.WU)(u.value)} and increasing the Ice Cream cap by ${(0,b.WU)(m.value)}`},null),(0,l.createVNode)(zo,null,Wt(o=(0,C.sY)(H))?o:{default:()=>[o]}),(0,l.createVNode)(po,{resource:t,color:e},null),(0,l.createVNode)(d,{height:"5px"},null),(0,l.createVNode)("button",{onClick:()=>console.log("yeet")},[(0,l.createTextVNode)("'HI'")]),(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Name your points!")]),(0,l.createVNode)(Oo.Z,{modelValue:i.value,"onUpdate:modelValue":e=>i.value=e},null),(0,l.createVNode)(zo,{style:"color: red; font-size: 32px; font-family: Comic Sans MS;"},{default:()=>[(0,l.createTextVNode)("I have "),x(rl.points),(0,l.createTextVNode)(" "),i.value,(0,l.createTextVNode)(" points!")]}),(0,l.createVNode)("hr",null,null),(0,C.Dy)(...S),(0,l.createVNode)(d,null,null),(0,C._4)(...P),(0,C._4)(B),(0,C._4)(N)])}))}))),display:"main tab",glowColor(){return V.canPurchase.value||M.canPurchase.value||Z.canPurchase.value||N.canComplete.value?"blue":""},style:{color:"orange"}}),thingies:()=>({tab:Zt((()=>({style(){return{backgroundColor:"#222222","--background":"#222222"}},display:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[(0,C.sY)(O),(0,l.createVNode)(d,null,null),(0,l.createVNode)(ie.Z,{style:"width: 600px; height: 350px; background-color: green; border-style: solid;"},{default:()=>[(0,l.createVNode)(Uo.Z,{"onUpdate:modelValue":e=>r.value=e,modelValue:r.value},null),(0,l.createVNode)(d,{width:"30px",height:"10px"},null),(0,l.createVNode)("div",null,[(0,l.createVNode)("span",null,[(0,l.createTextVNode)("Beep")])]),(0,l.createVNode)(d,null,null),(0,l.createVNode)(Ho,{height:"200px"},null)]}),(0,l.createVNode)(d,null,null),(0,l.createVNode)("img",{src:"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png"},null)])))}))),glowColor:"white",display:"thingies",style:{borderColor:"orange"}}),jail:()=>({tab:Zt((()=>({display:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[(0,C.sY)(c),(0,C.sY)(U),(0,l.createVNode)(d,null,null),(0,l.createVNode)(ie.Z,null,{default:()=>[(0,l.createVNode)(jo.Z,{style:"background-color: #555555; padding: 15px"},{default:()=>[(0,l.createVNode)("div",{style:"color: teal"},[(0,l.createTextVNode)("Sugar level:")]),(0,l.createVNode)(d,null,null),(0,C.sY)(j)]}),(0,l.createVNode)(d,null,null),(0,l.createVNode)(jo.Z,null,{default:()=>[(0,l.createVNode)("div",null,[(0,l.createTextVNode)("idk")]),(0,l.createVNode)(d,{width:"0",height:"50px"},null),(0,C.sY)(A)]})]}),(0,l.createVNode)(d,null,null),(0,l.createVNode)("div",null,[(0,l.createTextVNode)('It\'s jail because "bars"! So funny! Ha ha!')]),(0,C.sY)(K)])))}))),display:"jail"}),illuminati:()=>({tab:Zt((()=>({display:(0,y.tZ)((()=>(0,l.createVNode)("div",null,[(0,l.createVNode)("h1",null,[(0,l.createTextVNode)(" C O N F I R M E D ")]),(0,l.createVNode)(d,null,null),(0,C.sY)(J),(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Adjust how many points H gives you!")]),(0,l.createVNode)(_o,{"onUpdate:modelValue":e=>a.value=e,modelValue:a.value,min:1,max:30},null)]))),style:{backgroundColor:"#3325CC"}}))),visibility(){return(0,y.Kf)(Z.bought.value)},display:"illuminati"})});return{id:$t,color:e,name:o,points:t,best:n,beep:r,thingy:i,otherThingy:a,spentOnBuyables:s,waffleBoost:u,icecreamCap:m,coolInfo:c,lollipopMilestones:S,funChallenge:N,funEffect:k,generatorUpgrade:V,lollipopMultiplierUpgrade:M,lollipopMultiplierEffect:w,unlockIlluminatiUpgrade:Z,quasiUpgrade:B,exhancers:E,respecBuyables:R,sellExhancer:_,bars:{tallBoi:j,longBoi:U,flatBoi:A},tree:K,g:W,h:$,spook:Y,conversion:q,reset:z,hotkeys:L,treeNode:G,resetButton:H,confirmRespec:D,minWidth:800,tabs:X,display:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[(0,C.sY)(X),(0,C.sY)(Q)])))}}));var Kt=Yt,Qt=JSON.parse('{"lifetime":{"min":0.5,"max":1},"ease":[{"s":0,"cp":0.329,"e":0.548},{"s":0.548,"cp":0.767,"e":0.876},{"s":0.876,"cp":0.985,"e":1}],"frequency":0.001,"emitterLifetime":0.1,"maxParticles":100,"addAtBack":true,"pos":{"x":0,"y":0},"emit":false,"behaviors":[{"type":"alpha","config":{"alpha":{"list":[{"time":0,"value":0.74},{"time":1,"value":0}]}}},{"type":"moveSpeed","config":{"speed":{"list":[{"time":0,"value":300},{"time":1,"value":0}]},"minMult":1}},{"type":"scale","config":{"scale":{"list":[{"time":0,"value":1},{"time":1,"value":0.25}]},"minMult":1}},{"type":"color","config":{"color":{"list":[{"time":0,"value":"#ffdfa0"},{"time":1,"value":"#100f0c"}]}}},{"type":"rotation","config":{"accel":0,"minSpeed":0,"maxSpeed":200,"minStart":0,"maxStart":360}},{"type":"textureRandom","config":{"textures":["/particle.png"]}},{"type":"spawnShape","config":{"type":"rect","data":{"x":0,"y":0,"w":0,"h":0}}}]}');const Jt="f",Xt=(0,w.createLayer)(Jt,(()=>{const e="#FE0102",o="Farms",t=v(0,"farm points"),n=(0,p.ax)(!1),r=to((()=>({title:"Lore",titleStyle:{color:"#FE0000"},display:"DEEP LORE!",bodyStyle:{backgroundColor:"#0000EE"}}))),i=(0,p.ax)("Start"),a=Ue((()=>({display(){return{title:"Clicky clicky!",description:(()=>"Current state:<br>"[Symbol.for("+")]?"Current state:<br>"[Symbol.for("+")](i.value):"Current state:<br>"+i.value)()}},initialState:"Start",canClick(){return(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!==")]?i.value[Symbol.for("!==")]("Borkened..."):"Borkened..."!==i.value)()},onClick(e){switch(i.value){case"Start":i.value="A new state!";break;case"A new state!":i.value="Keep going!";break;case"Keep going!":i.value="Maybe that's a bit too far...";break;case"Maybe that's a bit too far...":const o=(()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](void 0):void 0==e)()?void 0:(()=>"touches"[Symbol.for("in")]?"touches"[Symbol.for("in")](e):"touches"in e)()?e.touches[0]:e,t=Object.assign({},Qt,{pos:{x:(()=>void 0!==(o?.clientX??0)&&null!==(o?.clientX??0)&&(o?.clientX??0)[Symbol.for("-")]?(o?.clientX??0)[Symbol.for("-")](h.boundingRect?.value?.left??0):(o?.clientX??0)-(h.boundingRect?.value?.left??0))(),y:(()=>void 0!==(o?.clientY??0)&&null!==(o?.clientY??0)&&(o?.clientY??0)[Symbol.for("-")]?(o?.clientY??0)[Symbol.for("-")](h.boundingRect?.value?.top??0):(o?.clientY??0)-(h.boundingRect?.value?.top??0))()}});h.addEmitter(t).then((e=>e.playOnceAndDestroy())),i.value="Borkened...";break;default:i.value="Start";break}},onHold(){console.log("Clickkkkk...")},style(){switch(i.value){case"Start":return{"background-color":"green"};case"A new state!":return{"background-color":"yellow"};case"Keep going!":return{"background-color":"orange"};case"Maybe that's a bit too far...":return{"background-color":"red"};default:return{}}}}))),s=Ue((()=>({onClick(){(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("==")]?i.value[Symbol.for("==")]("Borkened..."):"Borkened..."==i.value)()&&(i.value="Start")},display(){return(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("==")]?i.value[Symbol.for("==")]("Borkened..."):"Borkened..."==i.value)()?"Fix the clickable!":"Does nothing"},small:!0}))),u=fo((()=>({thingsToReset:()=>[Xt]}))),m=Ge((()=>({scaling:ze(10,.5),baseResource:rl.points,gainResource:t,modifyGainAmount:Zo(Kt.otherThingy)}))),c=Ae((()=>({layerID:Jt,color:e,reset:u,tooltip(){return c.canClick.value?`${x(t)} ${t.displayName}`:`This weird farmer dinosaur will only see you if you have at least 10 points. You only have ${x(rl.points)}`},canClick(){return b.ZP.gte(rl.points.value,10)}})));Co(c,{display:ne(t),pinnable:!0});const f=je((()=>({conversion:m,tree:rl.tree,treeNode:c,display:(0,y.tZ)((()=>f.conversion.buyMax?(0,l.createVNode)("span",null,[(0,l.createTextVNode)("Hi! I'm a "),(0,l.createVNode)("u",null,[(0,l.createTextVNode)("weird dinosaur")]),(0,l.createTextVNode)(" and I'll give you")," ",(0,l.createVNode)("b",null,[(0,b.Ht)(f.conversion.currentGain.value)]),(0,l.createTextVNode)(" Farm Points in exchange for all of your points and lollipops! (You'll get another one at")," ",(0,b.Ht)(f.conversion.nextAt.value),(0,l.createTextVNode)(" points)")]):(0,l.createVNode)("span",null,[(0,l.createTextVNode)("Hi! I'm a "),(0,l.createVNode)("u",null,[(0,l.createTextVNode)("weird dinosaur")]),(0,l.createTextVNode)(" and I'll give you a Farm Point in exchange for all of your points and lollipops! (At least")," ",(0,b.Ht)(f.conversion.nextAt.value),(0,l.createTextVNode)(" points)")])))}))),h=mo((()=>({boundingRect:(0,l.ref)(null),onContainerResized(e){this.boundingRect.value=e},style:"z-index: 2"}))),g=(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[(0,C.sY)(r),(0,l.createVNode)(Mo,{resource:t,color:e},null),(0,C.sY)(f),(0,l.createVNode)("div",null,[(0,l.createTextVNode)("You have "),(0,b.Ht)(m.baseResource.value),(0,l.createTextVNode)(" points")]),(0,l.createVNode)("div",null,[(0,l.createVNode)("br",null,null),(0,l.createVNode)("img",{src:"https://images.beano.com/store/24ab3094eb95e5373bca1ccd6f330d4406db8d1f517fc4170b32e146f80d?auto=compress%2Cformat&dpr=1&w=390"},null),(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Bork Bork!")])]),(0,l.createVNode)(d,null,null),(0,C._4)(s),(0,C._4)(a),(0,C.sY)(h)])));return{id:Jt,color:e,name:o,points:t,boop:n,coolInfo:r,clickable:a,clickableState:i,reset:u,conversion:m,treeNode:c,resetButton:f,minWidth:650,display:g}}));var el=Xt;function ol(e){return"function"===typeof e||"[object Object]"===Object.prototype.toString.call(e)&&(()=>void 0!==(0,l.isVNode)(e)&&null!==(0,l.isVNode)(e)&&(0,l.isVNode)(e)[Symbol.for("!")]?(0,l.isVNode)(e)[Symbol.for("!")]():!(0,l.isVNode)(e))()}const tl="a",ll=(0,w.createLayer)(tl,(()=>{const e="yellow",o="Achievements",t=v(0,"achievement power"),n=oe((()=>({display:"A",color:e,tooltip:{display:"Achievements",right:!0},onClick(){rl.showAchievements()}}))),r=pe((()=>({image:"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png",display:"Get me!",tooltip:(0,l.computed)((()=>r.earned.value?"You did it!":"How did this happen?")),shouldEarn:()=>!0}))),i=pe((()=>({display:"Impossible!",tooltip:(0,l.computed)((()=>i.earned.value?"HOW????":"Mwahahaha!")),style:{color:"#04e050"}}))),a=pe((()=>({display:"EIEIO",tooltip:"Get a farm point.\n\nReward: The dinosaur is now your friend (you can max Farm Points).",shouldEarn:function(){return b.ZP.gte(el.points.value,1)},onComplete(){console.log("Bork bork bork!")}}))),s=[r,i,a],u=Te((()=>({rows:2,cols:2,getStartState(e){return e},getStyle(e,o){return{backgroundColor:`#${(()=>1234*Number(o)!==void 0&&1234*Number(o)!==null&&(1234*Number(o))[Symbol.for("%")]?(1234*Number(o))[Symbol.for("%")](999999):1234*Number(o)%999999)()}`}},getTitle(e){let o="";return"101"===e?o="top":"102"===e?o="bottom":"201"===e?o="left":"202"===e&&(o="right"),(0,y.tZ)((()=>(0,l.createVNode)(ae.Z,(0,l.mergeProps)({display:JSON.stringify(this.cells[e].style)},{[o]:!0}),{default:()=>[(0,l.createVNode)("h3",null,[(0,l.createTextVNode)("Gridable #"),e])]})))},getDisplay(e,o){return String(o)},getCanClick(){return b.ZP.eq(rl.points.value,10)},onClick(e,o){this.cells[e].state=(()=>void 0!==Number(o)&&null!==Number(o)&&Number(o)[Symbol.for("+")]?Number(o)[Symbol.for("+")](1):Number(o)+1)()}}))),m=(0,y.tZ)((()=>{let e,o,t;return(0,l.createVNode)(l.Fragment,null,[(0,l.createVNode)(ie.Z,null,{default:()=>[(0,l.createVNode)(ae.Z,{display:r.tooltip,bottom:!0},ol(e=(0,C.sY)(r))?e:{default:()=>[e]}),(0,l.createVNode)(ae.Z,{display:i.tooltip,bottom:!0},ol(o=(0,C.sY)(i))?o:{default:()=>[o]}),(0,l.createVNode)(ae.Z,{display:a.tooltip,bottom:!0},ol(t=(0,C.sY)(a))?t:{default:()=>[t]})]}),(0,C._4)(u)])}));return{id:tl,color:e,name:o,points:t,achievements:s,grid:u,treeNode:n,display:m}}));var nl=ll;const rl=(0,w.createLayer)("main",(()=>{const e=v(10),o=g(e),t=S(e),n=(0,l.computed)((()=>{if((()=>void 0!==Kt.generatorUpgrade.bought.value&&null!==Kt.generatorUpgrade.bought.value&&Kt.generatorUpgrade.bought.value[Symbol.for("!")]?Kt.generatorUpgrade.bought.value[Symbol.for("!")]():!Kt.generatorUpgrade.bought.value)())return new b.ZP(0);let e=new b.ZP(3.19);return Kt.lollipopMultiplierUpgrade.bought.value&&(e=e.times(Kt.lollipopMultiplierEffect.value)),e}));h.globalBus.on("update",(o=>{e.value=b.ZP.add(e.value,b.ZP.times(n.value,o))}));const r=V(e,n),{openModal:i,modal:a}=(0,w.setupLayerModal)(nl),s=te((()=>({nodes:[[Kt.treeNode],[el.treeNode,Kt.spook]],leftSideNodes:[nl.treeNode,Kt.h],branches:[{startNode:el.treeNode,endNode:Kt.treeNode,stroke:"blue","stroke-width":"25px",style:{filter:"blur(5px)"}}],onReset(){e.value=(0,l.toRaw)(this.resettingNode.value)===(0,l.toRaw)(Kt.treeNode)?0:10,o.value=e.value,t.value=e.value},resetPropagation:le})));return{name:"Tree",display:(0,y.tZ)((()=>(0,l.createVNode)(l.Fragment,null,[0===re.Z.devSpeed?(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Game Paused")]):null,re.Z.devSpeed&&(()=>void 0!==re.Z.devSpeed&&null!==re.Z.devSpeed&&re.Z.devSpeed[Symbol.for("!==")]?re.Z.devSpeed[Symbol.for("!==")](1):1!==re.Z.devSpeed)()?(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Dev Speed: "),(0,b.WU)(re.Z.devSpeed),(0,l.createTextVNode)("x")]):null,re.Z.offlineTime?(0,l.createVNode)("div",null,[(0,l.createTextVNode)("Offline Time: "),(0,b.mr)(re.Z.offlineTime)]):null,(0,l.createVNode)("div",null,[b.ZP.lt(e.value,"1e1000")?(0,l.createVNode)("span",null,[(0,l.createTextVNode)("You have ")]):null,(0,l.createVNode)("h2",null,[(0,b.WU)(e.value)]),b.ZP.lt(e.value,"1e1e6")?(0,l.createVNode)("span",null,[(0,l.createTextVNode)(" points")]):null]),b.ZP.gt(n.value,0)?(0,l.createVNode)("div",null,[(0,l.createTextVNode)("("),r.value,(0,l.createTextVNode)(")")]):null,(0,l.createVNode)(d,null,null),(0,l.createVNode)("button",{onClick:i},[(0,l.createTextVNode)("open achievements")]),(0,C.sY)(a),(0,C.sY)(s),(0,l.createVNode)(m,{height:"200px",style:"margin: 10px auto; display: block"},null)]))),points:e,best:o,total:t,oomps:r,tree:s,showAchievements:i}})),il=e=>[rl,el,Kt,nl],al=(0,l.computed)((()=>b.ZP.gt(rl.points.value,25)));function sl(e,o){}},9365:function(e,o,t){"use strict";t.r(o),t.d(o,{RegisterNodeInjectionKey:function(){return f},UnregisterNodeInjectionKey:function(){return d},NodesInjectionKey:function(){return y},BoundsInjectionKey:function(){return b},layers:function(){return h},persistentRefs:function(){return p},addingLayers:function(){return v},createLayer:function(){return g},addLayer:function(){return S},getLayer:function(){return N},removeLayer:function(){return k},reloadLayer:function(){return V},setupLayerModal:function(){return x}});var l=t(4865),n=t(6948),r=t(6113),i=t(9583),a=t(3273),s=t(8111),u=t(7302),m=t(4061),c=t(5967);const f=Symbol("RegisterNode"),d=Symbol("UnregisterNode"),y=Symbol("Nodes"),b=Symbol("Bounds"),h=(0,l.shallowReactive)({});window.layers=h;const p={},v=[];function g(e,o){return(0,a.z2)((()=>{const t={},n=t.emitter=(0,s.i)();if(t.on=n.on.bind(n),t.emit=n.emit.bind(n),t.nodes=(0,l.ref)({}),t.id=e,v.push(e),p[e]=new Set,t.minimized=(0,m.ax)(!1),Object.assign(t,o.call(t)),(()=>void 0!==v[v.length-1]&&null!==v[v.length-1]&&v[v.length-1][Symbol.for("==")]?v[v.length-1][Symbol.for("==")](null):null==v[v.length-1])()||(()=>void 0!==v[v.length-1]&&null!==v[v.length-1]&&v[v.length-1][Symbol.for("!==")]?v[v.length-1][Symbol.for("!==")](e):v[v.length-1]!==e)())throw`Adding layers stack in invalid state. This should not happen\nStack: ${v}\nTrying to pop ${t.id}`;return v.pop(),(0,i.yB)(t,"color"),(0,i.yB)(t,"display"),(0,i.yB)(t,"name"),(0,r.Rh)(t,"name",t.id),(0,i.yB)(t,"minWidth"),(0,r.Rh)(t,"minWidth",600),(0,i.yB)(t,"minimizable"),(0,r.Rh)(t,"minimizable",!0),t}))}function S(e,o){console.info("Adding layer",e.id),h[e.id]?console.error("Attempted to add layer with same ID as existing layer",e.id,h[e.id]):((0,r.Rh)(o,"layers",{}),(()=>void 0!==o.layers[e.id]&&null!==o.layers[e.id]&&o.layers[e.id][Symbol.for("==")]?o.layers[e.id][Symbol.for("==")](null):null==o.layers[e.id])()&&(o.layers[e.id]={}),h[e.id]=e,u.globalBus.emit("addLayer",e,o.layers[e.id]))}function N(e){return h[e]}function k(e){console.info("Removing layer",e.id),u.globalBus.emit("removeLayer",e),h[e.id]=void 0}function V(e){k(e),S(e,c.Z)}function x(e){const o=(0,l.ref)(!1);return{openModal:()=>o.value=!0,modal:(0,r.tZ)((()=>(0,l.createVNode)(n.Z,{modelValue:o.value,"onUpdate:modelValue":e=>o.value=e},{header:()=>(0,l.createVNode)("h2",null,[(0,l.unref)(e.name)]),body:(0,l.unref)(e.display)})))}}u.globalBus.on("update",(function(e){Object.values(h).forEach((o=>{o?.emit("preUpdate",e)})),Object.values(h).forEach((o=>{o?.emit("update",e)})),Object.values(h).forEach((o=>{o?.emit("postUpdate",e)}))}))},1604:function(e,o,t){"use strict";t.d(o,{MM:function(){return u},sY:function(){return m},_4:function(){return c},Dy:function(){return f},qF:function(){return d},RU:function(){return y},ix:function(){return b},vq:function(){return h},KO:function(){return p},o9:function(){return v},Uv:function(){return g},P5:function(){return S}});var l=t(4865),n=t(9905),r=t(274),i=t(6113),a=t(9583);function s(e){return"function"===typeof e||"[object Object]"===Object.prototype.toString.call(e)&&(()=>void 0!==(0,l.isVNode)(e)&&null!==(0,l.isVNode)(e)&&(0,l.isVNode)(e)[Symbol.for("!")]?(0,l.isVNode)(e)[Symbol.for("!")]():!(0,l.isVNode)(e))()}function u(e,o="span"){return"function"===typeof e?(0,l.defineComponent)({render:e}):"string"===typeof e?(()=>void 0!==e.length&&null!==e.length&&e.length[Symbol.for(">")]?e.length[Symbol.for(">")](0):e.length>0)()?(e=e.trim(),(()=>void 0!==e.charAt(0)&&null!==e.charAt(0)&&e.charAt(0)[Symbol.for("!==")]?e.charAt(0)[Symbol.for("!==")]("<"):"<"!==e.charAt(0))()&&(e=`<${o}>${e}</${o}>`),(0,l.defineComponent)({template:e})):(0,l.defineComponent)({render:()=>({})}):e}function m(e){if(y(e))return"function"===typeof e?e():u(e);const o=e[i.wA];return(0,l.createVNode)(o,e[i.tj](),null)}function c(...e){let o;return(0,l.createVNode)(r.Z,null,s(o=e.map(m))?o:{default:()=>[o]})}function f(...e){let o;return(0,l.createVNode)(n.Z,null,s(o=e.map(m))?o:{default:()=>[o]})}function d(e){if(y(e)){if("function"===typeof e)return e();if("string"===typeof e)return(0,l.createVNode)(l.Fragment,null,[e]);const o=e;return(0,l.createVNode)(o,null,null)}const o=e[i.wA];return(0,l.createVNode)(o,e[i.tj](),null)}function y(e){return"string"===typeof e||("object"===typeof e?!(()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)()&&((()=>"render"[Symbol.for("in")]?"render"[Symbol.for("in")](e):"render"in e)()||(()=>"component"[Symbol.for("in")]?"component"[Symbol.for("in")](e):"component"in e)()):"function"===typeof e&&!0===e[a.mM])}function b(e,o){const t=(0,l.ref)(null),n=(0,l.ref)(void 0);function r(e){(()=>void 0!==t.value&&null!==t.value&&t.value[Symbol.for("!")]?t.value[Symbol.for("!")]():!t.value)()&&(t.value=setInterval(a,250)),n.value=e}function i(){t.value&&(clearInterval(t.value),t.value=null)}function a(){o&&o.value?o.value():e&&e.value&&e.value(n.value)}return(0,l.onUnmounted)(i),{start:r,stop:i,handleHolding:a}}function h(e,o="div"){const t=(0,l.shallowRef)();return(0,l.watchEffect)((()=>{t.value=u(g(e),o)})),t}function p(e,o="div"){const t=(0,l.shallowRef)(null);return(0,l.watchEffect)((()=>{const l=g(e);t.value=(()=>void 0!==l&&null!==l&&l[Symbol.for("==")]?l[Symbol.for("==")](null):null==l)()?null:u(l,o)})),t}function v(e){return(0,l.computed)((()=>g(e)))}function g(e){return(0,l.unref)((0,l.unref)(e))}function S(...e){return(()=>void 0!==e.includes(Object)&&null!==e.includes(Object)&&e.includes(Object)[Symbol.for("!")]?e.includes(Object)[Symbol.for("!")]():!e.includes(Object))()&&e.push(Object),e}},3363:function(e,o,t){"use strict";t.d(o,{Z:function(){return s}});var l=t(4865),n=t(9365),r=(0,l.defineComponent)({emits:["updateNodes"],setup(e,{emit:o}){const t=(0,l.ref)({}),r=new ResizeObserver(u),i=(0,l.ref)(null);(0,l.onMounted)((()=>{const e=i.value;(()=>void 0!==e&&null!==e&&e[Symbol.for("!=")]?e[Symbol.for("!=")](null):null!=e)()&&r.observe(e)}));let a=!0,s=(0,l.ref)(i.value?.getBoundingClientRect());function u(){(()=>void 0!==i.value&&null!==i.value&&i.value[Symbol.for("!=")]?i.value[Symbol.for("!=")](null):null!=i.value)()&&a&&(a=!1,(0,l.nextTick)((()=>{s.value=i.value?.getBoundingClientRect(),Object.values(t.value).filter((e=>e)).forEach((e=>e.rect=e.element.getBoundingClientRect())),o("updateNodes",t.value),a=!0})))}document.fonts.ready.then(u);const m={attributes:!1,childList:!0,subtree:!1};function c(e){const l=t.value[e];(()=>void 0!==l&&null!==l&&l[Symbol.for("==")]?l[Symbol.for("==")](null):null==l)()||(l.rect=l.element.getBoundingClientRect(),o("updateNodes",t.value))}return(0,l.provide)(n.RegisterNodeInjectionKey,((e,n)=>{const r=new MutationObserver((()=>c(e)));r.observe(n,m),t.value[e]={element:n,observer:r,rect:n.getBoundingClientRect()},o("updateNodes",t.value),(0,l.nextTick)((()=>c(e)))})),(0,l.provide)(n.UnregisterNodeInjectionKey,(e=>{t.value[e]?.observer.disconnect(),t.value[e]=void 0,o("updateNodes",t.value)})),(0,l.provide)(n.NodesInjectionKey,t),(0,l.provide)(n.BoundsInjectionKey,s),(e,o)=>((0,l.openBlock)(),(0,l.createElementBlock)(l.Fragment,null,[(0,l.renderSlot)(e.$slots,"default"),(0,l.createElementVNode)("div",{ref_key:"resizeListener",ref:i,class:"resize-listener"},null,512)],64))}}),i=t(3744);const a=(0,i.Z)(r,[["__scopeId","data-v-131e64e2"]]);var s=a},6948:function(e,o,t){"use strict";t.d(o,{Z:function(){return h}});var l=t(4865),n=t(3363);const r=["onPointerdown"],i={class:"modal-wrapper"},a={class:"modal-container"},s={class:"modal-header"},u=(0,l.createTextVNode)(" default header "),m={class:"modal-body"},c=(0,l.createTextVNode)(" default body "),f={class:"modal-footer"},d=(0,l.createElementVNode)("div",{class:"modal-default-flex-grow"},null,(()=>1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1)());var y=(0,l.defineComponent)({props:{modelValue:{type:Boolean}},emits:["update:modelValue"],setup(e,{expose:o,emit:t}){const y=e,b=(0,l.toRefs)(y),h=(0,l.computed)((()=>b.modelValue||v.value));function p(){t("update:modelValue",!1)}const v=(0,l.ref)(!1),g=(0,l.ref)(null),S=(0,l.computed)((()=>g.value?.nodes??null));return o({isOpen:h,nodes:S}),(o,t)=>((0,l.openBlock)(),(0,l.createBlock)(l.Teleport,{to:"#modal-root"},[(0,l.createVNode)(l.Transition,{name:"modal",onBeforeEnter:t[0]||(t[0]=e=>v.value=!0),onAfterLeave:t[1]||(t[1]=e=>v.value=!1)},{default:(0,l.withCtx)((()=>[(0,l.withDirectives)((0,l.createElementVNode)("div",(0,l.mergeProps)({class:"modal-mask",onPointerdown:(0,l.withModifiers)(p,["self"])},o.$attrs),[(0,l.createElementVNode)("div",i,[(0,l.createElementVNode)("div",a,[(0,l.createElementVNode)("div",s,[(0,l.renderSlot)(o.$slots,"header",{shown:(0,l.unref)(h)},(()=>[u]))]),(0,l.createElementVNode)("div",m,[(0,l.createVNode)(n.Z,{ref_key:"contextRef",ref:g},{default:(0,l.withCtx)((()=>[(0,l.renderSlot)(o.$slots,"body",{shown:(0,l.unref)(h)},(()=>[c]))])),_:3},512)]),(0,l.createElementVNode)("div",f,[(0,l.renderSlot)(o.$slots,"footer",{shown:(0,l.unref)(h)},(()=>[(0,l.createElementVNode)("div",{class:"modal-default-footer"},[d,(0,l.createElementVNode)("button",{class:"button modal-default-button",onClick:p}," Close ")])]))])])])],16,r),[[l.vShow,e.modelValue]])])),_:3})]))}});const b=y;var h=b},5418:function(e,o,t){"use strict";t.d(o,{Z:function(){return m}});var l=t(4865),n=t(1604),r=t(9179);const i={class:"field"},a={key:0,class:"field-title"};var s=(0,l.defineComponent)({props:{title:null,modelValue:null,options:null,placeholder:null,closeOnSelect:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:o}){const t=e,s=(0,n.KO)((0,l.toRef)(t,"title"),"span"),u=(0,l.ref)(t.options.find((e=>e.value===t.modelValue))??null);function m(e){o("update:modelValue",e.value)}return(0,l.watch)((0,l.toRef)(t,"modelValue"),(e=>{(()=>void 0!==(0,n.Uv)(u)&&null!==(0,n.Uv)(u)&&(0,n.Uv)(u)[Symbol.for("!==")]?(0,n.Uv)(u)[Symbol.for("!==")](e):(0,n.Uv)(u)!==e)()&&(u.value=t.options.find((o=>o.value===e))??null)})),(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",i,[(0,l.unref)(s)?((0,l.openBlock)(),(0,l.createElementBlock)("span",a,[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(s))))])):(0,l.createCommentVNode)("",!0),(0,l.createVNode)((0,l.unref)(r.Z),{options:e.options,modelValue:u.value,"onUpdate:modelValue":[t[0]||(t[0]=e=>u.value=e),m],min:1,"label-by":"label",placeholder:e.placeholder,"close-on-select":e.closeOnSelect},null,8,["options","modelValue","placeholder","close-on-select"])]))}});const u=s;var m=u},4520:function(e,o,t){"use strict";t.d(o,{Z:function(){return d}});var l=t(4865),n=t(1604),r=t(7197);const i=["onSubmit"],a={class:"field"},s={key:0,class:"field-title"},u=["placeholder"];var m=(0,l.defineComponent)({props:{title:null,modelValue:null,textArea:{type:Boolean},placeholder:null,maxHeight:null},emits:["update:modelValue","submit"],setup(e,{emit:o}){const t=e,m=(0,l.toRefs)(t),c=(0,l.computed)((()=>m.title?.value&&(0,n.MM)((0,l.unref)(m.title.value),"span"))),f=(0,l.ref)(null);(0,l.onMounted)((()=>{f.value?.focus()}));const d=(0,l.computed)({get(){return(0,l.unref)(m.modelValue)||""},set(e){o("update:modelValue",e)}});function y(){o("submit")}return(o,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("form",{onSubmit:(0,l.withModifiers)(y,["prevent"])},[(0,l.createElementVNode)("div",a,[(0,l.unref)(c)?((0,l.openBlock)(),(0,l.createElementBlock)("span",s,[((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(c))))])):(0,l.createCommentVNode)("",!0),e.textArea?((0,l.openBlock)(),(0,l.createBlock)((0,l.unref)(r.Z),{key:1,modelValue:(0,l.unref)(d),"onUpdate:modelValue":t[0]||(t[0]=e=>(0,l.isRef)(d)?d.value=e:null),placeholder:e.placeholder,maxHeight:e.maxHeight,onBlur:y,ref_key:"field",ref:f},null,8,["modelValue","placeholder","maxHeight"])):(0,l.withDirectives)(((0,l.openBlock)(),(0,l.createElementBlock)("input",{key:2,type:"text","onUpdate:modelValue":t[1]||(t[1]=e=>(0,l.isRef)(d)?d.value=e:null),placeholder:e.placeholder,class:(0,l.normalizeClass)({fullWidth:(()=>void 0!==e.title&&null!==e.title&&e.title[Symbol.for("!")]?e.title[Symbol.for("!")]():!e.title)()}),onBlur:y,ref_key:"field",ref:f},null,42,u)),[[l.vModelText,(0,l.unref)(d)]])])],40,i))}}),c=t(3744);const f=(0,c.Z)(m,[["__scopeId","data-v-8bda704a"]]);var d=f},9868:function(e,o,t){"use strict";t.d(o,{Z:function(){return u}});var l=t(4865),n=t(1604);const r={class:"field"};var i=(0,l.defineComponent)({props:{title:null,modelValue:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:o}){const t=e,i=(0,l.computed)((()=>(0,n.MM)((0,l.unref)(t.title)||"<span></span>","span"))),a=(0,l.computed)({get(){return(()=>void 0!==!t.modelValue&&null!==!t.modelValue&&(!t.modelValue)[Symbol.for("!")]?(!t.modelValue)[Symbol.for("!")]():!!t.modelValue)()},set(e){o("update:modelValue",e)}});return(e,o)=>((0,l.openBlock)(),(0,l.createElementBlock)("label",r,[(0,l.withDirectives)((0,l.createElementVNode)("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":o[0]||(o[0]=e=>(0,l.isRef)(a)?a.value=e:null)},null,512),[[l.vModelCheckbox,(0,l.unref)(a)]]),((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)((0,l.unref)(i))))]))}}),a=t(3744);const s=(0,a.Z)(i,[["__scopeId","data-v-43cf95d0"]]);var u=s},9905:function(e,o,t){"use strict";t.d(o,{Z:function(){return u}});var l=t(4865),n=t(1037),r=t(9266);const i={class:"table"};var a=(0,l.defineComponent)({setup(e){const o=(0,l.computed)((()=>n.Z[r.ZP.theme].mergeAdjacent));return(e,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",i,[(0,l.createElementVNode)("div",{class:(0,l.normalizeClass)(["col",{mergeAdjacent:(0,l.unref)(o)}])},[(0,l.renderSlot)(e.$slots,"default")],2)]))}});const s=a;var u=s},274:function(e,o,t){"use strict";t.d(o,{Z:function(){return u}});var l=t(4865),n=t(1037),r=t(9266);const i={class:"table"};var a=(0,l.defineComponent)({setup(e){const o=(0,l.computed)((()=>n.Z[r.ZP.theme].mergeAdjacent));return(e,t)=>((0,l.openBlock)(),(0,l.createElementBlock)("div",i,[(0,l.createElementVNode)("div",{class:(0,l.normalizeClass)(["row",{mergeAdjacent:(0,l.unref)(o)}])},[(0,l.renderSlot)(e.$slots,"default")],2)]))}});const s=a;var u=s},6055:function(e,o,t){"use strict";t.d(o,{Z:function(){return y}});var l=t(4865);const n={key:0,class:"material-icons pinned"};function r(e,o,t,r,i,a){return(0,l.openBlock)(),(0,l.createElementBlock)("div",{class:(0,l.normalizeClass)(["tooltip-container",{shown:e.isShown}]),onMouseenter:o[0]||(o[0]=o=>e.isHovered=!0),onMouseleave:o[1]||(o[1]=o=>e.isHovered=!1),onClickCapture:o[2]||(o[2]=(...o)=>e.togglePinned&&e.togglePinned(...o))},[(0,l.renderSlot)(e.$slots,"default",{},void 0,!0),e.elementComp?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.elementComp),{key:0})):(0,l.createCommentVNode)("",!0),(0,l.createVNode)(l.Transition,{name:"fade"},{default:(0,l.withCtx)((()=>[e.isShown?((0,l.openBlock)(),(0,l.createElementBlock)("div",{key:0,class:(0,l.normalizeClass)(["tooltip",{top:e.unref(e.direction)===e.Direction.Up,left:e.unref(e.direction)===e.Direction.Left,right:e.unref(e.direction)===e.Direction.Right,bottom:e.unref(e.direction)===e.Direction.Down,...e.unref(e.classes)}]),style:(0,l.normalizeStyle)([{"--xoffset":e.unref(e.xoffset)||"0px","--yoffset":e.unref(e.yoffset)||"0px"},e.unref(e.style)??{}])},[e.showPin?((0,l.openBlock)(),(0,l.createElementBlock)("span",n,"push_pin")):(0,l.createCommentVNode)("",!0),e.comp?((0,l.openBlock)(),(0,l.createBlock)((0,l.resolveDynamicComponent)(e.comp),{key:1})):(0,l.createCommentVNode)("",!0)],6)):(0,l.createCommentVNode)("",!0)])),_:1})],34)}var i=t(1037),a=t(6113),s=t(9266),u=t(1349),m=t(1604),c=(0,l.defineComponent)({props:{element:(0,m.P5)(Object),display:{type:(0,m.P5)(Object,String,Function),required:!0},style:(0,m.P5)(Object,String,Array),classes:(0,m.P5)(Object),direction:(0,m.P5)(String),xoffset:(0,m.P5)(String),yoffset:(0,m.P5)(String),pinned:Object},setup(e){const{element:o,display:t,pinned:n}=(0,l.toRefs)(e),r=(0,l.ref)(!1),c=(0,l.computed)((()=>((0,m.Uv)(n)||r.value)&&f.value)),f=(0,m.KO)(t),d=(0,l.shallowRef)(null);function y(e){const o=n;e.shiftKey&&o&&(o.value=(()=>void 0!==o.value&&null!==o.value&&o.value[Symbol.for("!")]?o.value[Symbol.for("!")]():!o.value)(),e.stopPropagation(),e.preventDefault())}(0,l.watchEffect)((()=>{const e=(0,m.Uv)(o);d.value=(()=>void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e)()?null:(0,m.MM)((0,a.tZ)((()=>(0,m.sY)(e))))}));const b=(0,l.computed)((()=>(0,m.Uv)(n)&&i.Z[s.ZP.theme].showPin));return{Direction:u.Nm,isHovered:r,isShown:c,comp:f,elementComp:d,unref:l.unref,togglePinned:y,showPin:b}}}),f=t(3744);const d=(0,f.Z)(c,[["render",r],["__scopeId","data-v-e03bc918"]]);var y=d},7634:function(e){function o(e){var o=new Error("Cannot find module '"+e+"'");throw o.code="MODULE_NOT_FOUND",o}o.keys=function(){return[]},o.resolve=o,o.id=7634,e.exports=o},6453:function(e){"use strict";e.exports=JSON.parse('{"title":"Profectus","id":"profectus-demo","author":"thepaperpilot","discordName":"The Paper Pilot Community","discordLink":"https://discord.gg/WzejVAx","versionNumber":"0.0","versionTitle":"Initial Commit","allowGoBack":true,"defaultShowSmall":false,"defaultDecimalsShown":2,"useHeader":true,"banner":null,"logo":"Logo.png","initialTabs":["main","c"],"maxTickLength":3600,"offlineLimit":1,"enablePausing":true,"exportEncoding":"base64"}')}},o={};function t(l){var n=o[l];if(void 0!==n)return n.exports;var r=o[l]={id:l,loaded:!1,exports:{}};return e[l].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}t.m=e,function(){var e=[];t.O=function(o,l,n,r){if(!l){var i=1/0;for(m=0;m<e.length;m++){l=e[m][0],n=e[m][1],r=e[m][2];for(var a=!0,s=0;s<l.length;s++)(!1&r||i>=r)&&Object.keys(t.O).every((function(e){return t.O[e](l[s])}))?l.splice(s--,1):(a=!1,r<i&&(i=r));if(a){e.splice(m--,1);var u=n();void 0!==u&&(o=u)}}return o}r=r||0;for(var m=e.length;m>0&&e[m-1][2]>r;m--)e[m]=e[m-1];e[m]=[l,n,r]}}(),function(){t.n=function(e){var o=e&&e.__esModule?function(){return e["default"]}:function(){return e};return t.d(o,{a:o}),o}}(),function(){t.d=function(e,o){for(var l in o)t.o(o,l)&&!t.o(e,l)&&Object.defineProperty(e,l,{enumerable:!0,get:o[l]})}}(),function(){t.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}()}(),function(){t.o=function(e,o){return Object.prototype.hasOwnProperty.call(e,o)}}(),function(){t.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}}(),function(){t.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e}}(),function(){var e={143:0};t.O.j=function(o){return 0===e[o]};var o=function(o,l){var n,r,i=l[0],a=l[1],s=l[2],u=0;if(i.some((function(o){return 0!==e[o]}))){for(n in a)t.o(a,n)&&(t.m[n]=a[n]);if(s)var m=s(t)}for(o&&o(l);u<i.length;u++)r=i[u],t.o(e,r)&&e[r]&&e[r][0](),e[r]=0;return t.O(m)},l=self["webpackChunkprofectus"]=self["webpackChunkprofectus"]||[];l.forEach(o.bind(null,0)),l.push=o.bind(null,l.push.bind(l))}();var l=t.O(void 0,[998],(function(){return t(7964)}));l=t.O(l)})(); -//# sourceMappingURL=app.33420421.js.map \ No newline at end of file diff --git a/js/app.33420421.js.map b/js/app.33420421.js.map deleted file mode 100644 index a817fe2..0000000 --- a/js/app.33420421.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"js/app.33420421.js","mappings":"qFAiCA,MAAMA,EAAsB,CACxBC,UAAW,CACP,eAAgB,UAChB,eAAgB,UAChB,uBAAwB,UACxB,uBAAwB,sBACxB,sBAAuB,UACvB,WAAY,UACZ,WAAY,UACZ,gBAAiB,OACjB,WAAY,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kB,CACrB,IAAK,GAaN1B,EAAoBM,EAAEM,EAAI,SAASe,GAAW,OAAoC,IAA7BD,EAAgBC,IAGrE,IAAIC,EAAuB,SAASC,EAA4BC,GAC/D,IAKI7B,EAAU0B,EALVpB,EAAWuB,EAAK,GAChBC,EAAcD,EAAK,GACnBE,EAAUF,EAAK,GAGI92B,EAAI,EAC3B,GAAGu1B,EAAS0B,MAAK,SAASzwC,GAAM,OAA+B,IAAxBkwC,EAAgBlwC,MAAe,CACrE,IAAIyuC,KAAY8B,EACZ/B,EAAoBkB,EAAEa,EAAa9B,KACrCD,EAAoBxxB,EAAEyxB,GAAY8B,EAAY9B,IAGhD,GAAG+B,EAAS,IAAI7tB,EAAS6tB,EAAQhC,GAGlC,IADG6B,GAA4BA,EAA2BC,GACrD92B,EAAIu1B,EAAS95B,OAAQuE,IACzB22B,EAAUpB,EAASv1B,GAChBg1B,EAAoBkB,EAAEQ,EAAiBC,IAAYD,EAAgBC,IACrED,EAAgBC,GAAS,KAE1BD,EAAgBC,GAAW,EAE5B,OAAO3B,EAAoBM,EAAEnsB,IAG1B+tB,EAAqBC,KAAK,yBAA2BA,KAAK,0BAA4B,GAC1FD,EAAmBnvC,QAAQ6uC,EAAqBllB,KAAK,KAAM,IAC3DwlB,EAAmBhvC,KAAO0uC,EAAqBllB,KAAK,KAAMwlB,EAAmBhvC,KAAKwpB,KAAKwlB,I,GC/CvF,IAAIE,EAAsBpC,EAAoBM,OAAE/tC,EAAW,CAAC,MAAM,WAAa,OAAOytC,EAAoB,SAC1GoC,EAAsBpC,EAAoBM,EAAE8B,I","sources":["webpack://profectus/./src/data/themes.ts","webpack://profectus/./src/features/feature.ts","webpack://profectus/./src/game/events.ts","webpack://profectus/./src/game/persistence.ts","webpack://profectus/./src/game/player.ts","webpack://profectus/./src/game/settings.ts","webpack://profectus/./src/game/state.ts","webpack://profectus/./src/components/Layer.vue?d518","webpack://profectus/./src/components/Layer.vue?ea1e","webpack://profectus/./src/components/Layer.vue","webpack://profectus/./src/data/Changelog.vue?6b26","webpack://profectus/./src/data/Changelog.vue","webpack://profectus/./src/components/Info.vue?962a","webpack://profectus/./src/components/Info.vue","webpack://profectus/./src/components/Options.vue?ba84","webpack://profectus/./src/components/Options.vue","webpack://profectus/./src/components/fields/DangerButton.vue?bf6c","webpack://profectus/./src/components/fields/DangerButton.vue","webpack://profectus/./src/components/fields/FeedbackButton.vue?2dba","webpack://profectus/./src/components/fields/FeedbackButton.vue","webpack://profectus/./src/components/Save.vue?548a","webpack://profectus/./src/components/Save.vue","webpack://profectus/./src/components/SavesManager.vue?f8a3","webpack://profectus/./src/components/SavesManager.vue","webpack://profectus/./src/components/Nav.vue?b4a5","webpack://profectus/./src/components/Nav.vue","webpack://profectus/./src/components/Game.vue?fa24","webpack://profectus/./src/components/Game.vue","webpack://profectus/./src/components/GameOverScreen.vue?ee8d","webpack://profectus/./src/components/GameOverScreen.vue","webpack://profectus/./src/components/NaNScreen.vue?4f64","webpack://profectus/./src/components/NaNScreen.vue","webpack://profectus/./src/components/TPS.vue?e36e","webpack://profectus/./src/components/TPS.vue","webpack://profectus/./src/App.vue?94f9","webpack://profectus/./src/App.vue","webpack://profectus/./src/main.ts","webpack://profectus/./src/lib/break_eternity.ts","webpack://profectus/./src/util/break_eternity.ts","webpack://profectus/./src/util/bignum.ts","webpack://profectus/./src/util/common.ts","webpack://profectus/./src/util/computed.ts","webpack://profectus/./src/util/proxies.ts","webpack://profectus/./src/util/save.ts","webpack://profectus/./src/components/Profectus.vue","webpack://profectus/./src/components/Profectus.vue?94a9","webpack://profectus/./src/components/layout/Spacer.vue?e0bd","webpack://profectus/./src/components/layout/Spacer.vue","webpack://profectus/./src/features/resources/resource.ts","webpack://profectus/./src/features/trees/Tree.vue?d078","webpack://profectus/./src/features/links/Link.vue?f30b","webpack://profectus/./src/features/links/Link.vue","webpack://profectus/./src/features/links/Links.vue?7529","webpack://profectus/./src/features/links/Links.vue","webpack://profectus/./src/features/trees/Tree.vue?698b","webpack://profectus/./src/features/trees/Tree.vue","webpack://profectus/./src/features/trees/TreeNode.vue?da84","webpack://profectus/./src/components/Node.vue?6bf5","webpack://profectus/./src/components/Node.vue","webpack://profectus/./src/components/MarkNode.vue?acb3","webpack://profectus/./src/components/MarkNode.vue","webpack://profectus/./src/features/trees/TreeNode.vue?9a03","webpack://profectus/./src/features/trees/TreeNode.vue","webpack://profectus/./src/features/trees/tree.ts","webpack://profectus/./src/features/achievements/Achievement.vue?3070","webpack://profectus/./src/features/achievements/Achievement.vue?dcde","webpack://profectus/./src/features/achievements/Achievement.vue","webpack://profectus/./src/game/notifications.ts","webpack://profectus/./src/features/achievements/achievement.tsx","webpack://profectus/./src/features/grids/Grid.vue?6522","webpack://profectus/./src/features/grids/GridCell.vue?ffc5","webpack://profectus/./src/features/grids/GridCell.vue?58b8","webpack://profectus/./src/features/grids/GridCell.vue","webpack://profectus/./src/features/grids/Grid.vue?3299","webpack://profectus/./src/features/grids/Grid.vue","webpack://profectus/./src/features/grids/grid.ts","webpack://profectus/./src/features/clickables/Clickable.vue?4539","webpack://profectus/./src/features/clickables/Clickable.vue?22aa","webpack://profectus/./src/features/clickables/Clickable.vue","webpack://profectus/./src/features/clickables/clickable.ts","webpack://profectus/./src/data/common.tsx","webpack://profectus/./src/features/conversion.ts","webpack://profectus/./src/features/infoboxes/Infobox.vue?b869","webpack://profectus/./src/features/infoboxes/Infobox.vue?c704","webpack://profectus/./src/features/infoboxes/Infobox.vue","webpack://profectus/./src/features/infoboxes/infobox.ts","webpack://profectus/./src/features/particles/Particles.vue?0a16","webpack://profectus/./src/features/particles/Particles.vue?11ca","webpack://profectus/./src/features/particles/Particles.vue","webpack://profectus/./src/features/particles/particles.tsx","webpack://profectus/./src/features/reset.ts","webpack://profectus/./src/features/resources/Resource.vue?0822","webpack://profectus/./src/features/resources/Resource.vue","webpack://profectus/./src/features/resources/MainDisplay.vue?8bde","webpack://profectus/./src/features/resources/MainDisplay.vue","webpack://profectus/./src/features/tooltips/tooltip.ts","webpack://profectus/./src/game/modifiers.tsx","webpack://profectus/./src/components/fields/Slider.vue?f27e","webpack://profectus/./src/components/fields/Slider.vue","webpack://profectus/./src/components/layout/Sticky.vue?32f6","webpack://profectus/./src/components/layout/Sticky.vue","webpack://profectus/./src/components/layout/VerticalRule.vue?aaf3","webpack://profectus/./src/components/layout/VerticalRule.vue","webpack://profectus/./src/features/bars/Bar.vue?6954","webpack://profectus/./src/features/bars/Bar.vue?da91","webpack://profectus/./src/features/bars/Bar.vue","webpack://profectus/./src/features/bars/bar.ts","webpack://profectus/./src/features/buyable.tsx","webpack://profectus/./src/features/challenges/Challenge.vue?43ae","webpack://profectus/./src/features/challenges/Challenge.vue?5ee1","webpack://profectus/./src/features/challenges/Challenge.vue","webpack://profectus/./src/features/challenges/challenge.tsx","webpack://profectus/./src/features/hotkey.tsx","webpack://profectus/./src/features/links/links.ts","webpack://profectus/./src/features/milestones/Milestone.vue?08ca","webpack://profectus/./src/features/milestones/Milestone.vue?d607","webpack://profectus/./src/features/milestones/Milestone.vue","webpack://profectus/./src/features/milestones/milestone.tsx","webpack://profectus/./src/features/tabs/Tab.vue?50ee","webpack://profectus/./src/features/tabs/Tab.vue","webpack://profectus/./src/features/tabs/tab.ts","webpack://profectus/./src/features/tabs/TabButton.vue?7f39","webpack://profectus/./src/features/tabs/TabButton.vue?a3c5","webpack://profectus/./src/features/tabs/TabButton.vue","webpack://profectus/./src/features/tabs/TabFamily.vue?3794","webpack://profectus/./src/features/tabs/TabFamily.vue?2385","webpack://profectus/./src/features/tabs/TabFamily.vue","webpack://profectus/./src/features/tabs/tabFamily.ts","webpack://profectus/./src/features/upgrades/Upgrade.vue?4ec3","webpack://profectus/./src/features/upgrades/Upgrade.vue?4a14","webpack://profectus/./src/features/upgrades/Upgrade.vue","webpack://profectus/./src/features/upgrades/upgrade.ts","webpack://profectus/./src/data/layers/aca/c.tsx","webpack://profectus/./src/data/layers/aca/f.tsx","webpack://profectus/./src/data/layers/aca/a.tsx","webpack://profectus/./src/data/projEntry.tsx","webpack://profectus/./src/game/layers.tsx","webpack://profectus/./src/util/vue.tsx","webpack://profectus/./src/components/Context.vue?2f6e","webpack://profectus/./src/components/Context.vue","webpack://profectus/./src/components/Modal.vue?1099","webpack://profectus/./src/components/Modal.vue","webpack://profectus/./src/components/fields/Select.vue?c5ab","webpack://profectus/./src/components/fields/Select.vue","webpack://profectus/./src/components/fields/Text.vue?ba89","webpack://profectus/./src/components/fields/Text.vue","webpack://profectus/./src/components/fields/Toggle.vue?20df","webpack://profectus/./src/components/fields/Toggle.vue","webpack://profectus/./src/components/layout/Column.vue?cbbe","webpack://profectus/./src/components/layout/Column.vue","webpack://profectus/./src/components/layout/Row.vue?506d","webpack://profectus/./src/components/layout/Row.vue","webpack://profectus/./src/features/tooltips/Tooltip.vue?1902","webpack://profectus/./src/features/tooltips/Tooltip.vue?9cc7","webpack://profectus/./src/features/tooltips/Tooltip.vue","webpack://profectus/|/\\.txt$/","webpack://profectus/webpack/bootstrap","webpack://profectus/webpack/runtime/chunk loaded","webpack://profectus/webpack/runtime/compat get default export","webpack://profectus/webpack/runtime/define property getters","webpack://profectus/webpack/runtime/global","webpack://profectus/webpack/runtime/hasOwnProperty shorthand","webpack://profectus/webpack/runtime/make namespace object","webpack://profectus/webpack/runtime/node module decorator","webpack://profectus/webpack/runtime/jsonp chunk loading","webpack://profectus/webpack/startup"],"sourcesContent":["export interface ThemeVars {\n \"--foreground\": string;\n \"--background\": string;\n \"--feature-foreground\": string;\n \"--tooltip-background\": string;\n \"--raised-background\": string;\n \"--points\": string;\n \"--locked\": string;\n \"--highlighted\": string;\n \"--bought\": string;\n \"--danger\": string;\n \"--link\": string;\n \"--outline\": string;\n \"--accent1\": string;\n \"--accent2\": string;\n \"--accent3\": string;\n \"--border-radius\": string;\n \"--modal-border\": string;\n \"--feature-margin\": string;\n}\n\nexport interface Theme {\n variables: ThemeVars;\n floatingTabs: boolean;\n mergeAdjacent: boolean;\n showPin: boolean;\n}\n\ndeclare module \"@vue/runtime-dom\" {\n // eslint-disable-next-line @typescript-eslint/no-empty-interface\n interface CSSProperties extends Partial<ThemeVars> {}\n}\n\nconst defaultTheme: Theme = {\n variables: {\n \"--foreground\": \"#dfdfdf\",\n \"--background\": \"#0f0f0f\",\n \"--feature-foreground\": \"#0f0f0f\",\n \"--tooltip-background\": \"rgba(0, 0, 0, 0.75)\",\n \"--raised-background\": \"#0f0f0f\",\n \"--points\": \"#ffffff\",\n \"--locked\": \"#bf8f8f\",\n \"--highlighted\": \"#333\",\n \"--bought\": \"#77bf5f\",\n \"--danger\": \"rgb(220, 53, 69)\",\n \"--link\": \"#02f2f2\",\n \"--outline\": \"#dfdfdf\",\n \"--accent1\": \"#627a82\",\n \"--accent2\": \"#658262\",\n \"--accent3\": \"#7c6282\",\n\n \"--border-radius\": \"15px\",\n \"--modal-border\": \"solid 2px var(--color)\",\n \"--feature-margin\": \"0px\"\n },\n floatingTabs: true,\n mergeAdjacent: true,\n showPin: true\n};\n\nexport enum Themes {\n Classic = \"classic\",\n Paper = \"paper\",\n Nordic = \"nordic\",\n Aqua = \"aqua\"\n}\n\nexport default {\n classic: defaultTheme,\n paper: {\n ...defaultTheme,\n variables: {\n ...defaultTheme.variables,\n \"--background\": \"#2a323d\",\n \"--feature-foreground\": \"#000\",\n \"--raised-background\": \"#333c4a\",\n \"--locked\": \"#3a3e45\",\n \"--bought\": \"#5C8A58\",\n \"--outline\": \"#333c4a\",\n \"--border-radius\": \"4px\",\n \"--modal-border\": \"\",\n \"--feature-margin\": \"5px\"\n },\n floatingTabs: false\n } as Theme,\n // Based on https://www.nordtheme.com\n nordic: {\n ...defaultTheme,\n variables: {\n ...defaultTheme.variables,\n \"--foreground\": \"#D8DEE9\",\n \"--background\": \"#2E3440\",\n \"--feature-foreground\": \"#000\",\n \"--raised-background\": \"#3B4252\",\n \"--points\": \"#E5E9F0\",\n \"--locked\": \"#4c566a\",\n \"--highlighted\": \"#434c5e\",\n \"--bought\": \"#8FBCBB\",\n \"--danger\": \"#D08770\",\n \"--link\": \"#88C0D0\",\n \"--outline\": \"#3B4252\",\n \"--accent1\": \"#B48EAD\",\n \"--accent2\": \"#A3BE8C\",\n \"--accent3\": \"#EBCB8B\",\n \"--border-radius\": \"4px\",\n \"--modal-border\": \"solid 2px #3B4252\",\n \"--feature-margin\": \"5px\"\n },\n floatingTabs: false\n } as Theme,\n aqua: {\n ...defaultTheme,\n variables: {\n ...defaultTheme.variables,\n \"--foreground\": \"#bfdfff\",\n \"--background\": \"#001f3f\",\n \"--tooltip-background\": \"rgba(0, 15, 31, 0.75)\",\n \"--raised-background\": \"#001f3f\",\n \"--points\": \"#dfefff\",\n \"--locked\": \"#c4a7b3\",\n \"--outline\": \"#bfdfff\"\n }\n } as Theme\n} as Record<Themes, Theme>;\n","import Decimal from \"util/bignum\";\nimport { DoNotCache } from \"util/computed\";\nimport { CSSProperties, DefineComponent, isRef } from \"vue\";\n\n/**\n * A symbol to use as a key for a vue component a feature can be rendered with\n * @see {@link VueFeature}\n */\nexport const Component = Symbol(\"Component\");\n/**\n * A symbol to use as a key for a prop gathering function that a feature can use to send to its component\n * @see {@link VueFeature}\n */\nexport const GatherProps = Symbol(\"GatherProps\");\n\n/**\n * A type referring to a function that returns JSX and is marked that it shouldn't be wrapped in a ComputedRef\n * @see {@link jsx}\n */\nexport type JSXFunction = (() => JSX.Element) & { [DoNotCache]: true };\n/**\n * Any value that can be coerced into (or is) a vue component\n */\nexport type CoercableComponent = string | DefineComponent | JSXFunction;\n/**\n * Any value that can be passed into an HTML element's style attribute.\n * Note that Profectus uses its own StyleValue and CSSProperties that are extended,\n * in order to have additional properties added to them, such as variable CSS variables.\n */\nexport type StyleValue = string | CSSProperties | Array<string | CSSProperties>;\n\n/** A type that refers to any vue component */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport type GenericComponent = DefineComponent<any, any, any>;\n\n/** Utility type that is S, with any properties from T that aren't already present in S */\nexport type Replace<T, S> = S & Omit<T, keyof S>;\n\n/**\n * Utility function for a function that returns an object of a given type,\n * with \"this\" bound to what the type will eventually be processed into.\n * Intended for making lazily evaluated objects.\n */\nexport type OptionsFunc<T, S = T, R = Record<string, unknown>> = () => T & ThisType<S> & Partial<R>;\n\nlet id = 0;\n/**\n * Gets a unique ID to give to each feature, used for any sort of system that needs to identify\n * elements in the DOM rather than references to the feature itself. (For example, branches)\n * IDs are guaranteed unique, but _NOT_ persistent - they likely will change between updates.\n * @param prefix A string to prepend to the id to make it more readable in the inspector tools\n */\nexport function getUniqueID(prefix = \"feature-\"): string {\n return prefix + id++;\n}\n\n/** Enum for what the visibility of a feature or component should be */\nexport enum Visibility {\n /** The feature or component should be visible */\n Visible,\n /** The feature or component should not appear but still take up space */\n Hidden,\n /** The feature or component should not appear not take up space */\n None\n}\n\n/**\n * Takes a function and marks it as JSX so it won't get auto-wrapped into a ComputedRef.\n * The function may also return empty string as empty JSX tags cause issues.\n */\nexport function jsx(func: () => JSX.Element | \"\"): JSXFunction {\n (func as Partial<JSXFunction>)[DoNotCache] = true;\n return func as JSXFunction;\n}\n\n/** Utility function to convert a boolean value into a Visbility value */\nexport function showIf(condition: boolean, otherwise = Visibility.None): Visibility {\n return condition ? Visibility.Visible : otherwise;\n}\n\n/** Utility function to set a property on an object if and only if it doesn't already exist */\nexport function setDefault<T, K extends keyof T>(\n object: T,\n key: K,\n value: T[K]\n): asserts object is Exclude<T, K> & Required<Pick<T, K>> {\n if (object[key] === undefined && value != undefined) {\n object[key] = value;\n }\n}\n\n/**\n * Traverses an object and returns all features of the given type(s)\n * @param obj The object to traverse\n * @param types The feature types that will be searched for\n */\nexport function findFeatures(obj: Record<string, unknown>, ...types: symbol[]): unknown[] {\n const objects: unknown[] = [];\n const handleObject = (obj: Record<string, unknown>) => {\n Object.keys(obj).forEach(key => {\n const value = obj[key];\n if (value && typeof value === \"object\") {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (types.includes((value as Record<string, any>).type)) {\n objects.push(value);\n } else if (!(value instanceof Decimal) && !isRef(value)) {\n handleObject(value as Record<string, unknown>);\n }\n }\n });\n };\n handleObject(obj);\n return objects;\n}\n\n/**\n * Traverses an object and returns all features that are _not_ any of the given types.\n * Features are any object with a \"type\" property that has a symbol value.\n * @param obj The object to traverse\n * @param types The feature types that will be skipped over\n */\nexport function excludeFeatures(obj: Record<string, unknown>, ...types: symbol[]): unknown[] {\n const objects: unknown[] = [];\n const handleObject = (obj: Record<string, unknown>) => {\n Object.keys(obj).forEach(key => {\n const value = obj[key];\n if (value && typeof value === \"object\") {\n if (\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n typeof (value as Record<string, any>).type == \"symbol\" &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !types.includes((value as Record<string, any>).type)\n ) {\n objects.push(value);\n } else if (!(value instanceof Decimal) && !isRef(value)) {\n handleObject(value as Record<string, unknown>);\n }\n }\n });\n };\n handleObject(obj);\n return objects;\n}\n","import projInfo from \"data/projInfo.json\";\nimport Decimal from \"util/bignum\";\nimport { createNanoEvents } from \"nanoevents\";\nimport { App, Ref, watch } from \"vue\";\nimport { GenericLayer } from \"./layers\";\nimport player from \"./player\";\nimport settings, { Settings } from \"./settings\";\nimport state from \"./state\";\n\nexport interface GlobalEvents {\n addLayer: (layer: GenericLayer, saveData: Record<string, unknown>) => void;\n removeLayer: (layer: GenericLayer) => void;\n update: (diff: number, trueDiff: number) => void;\n loadSettings: (settings: Partial<Settings>) => void;\n gameWon: VoidFunction;\n setupVue: (vue: App) => void;\n}\n\nexport const globalBus = createNanoEvents<GlobalEvents>();\n\nlet intervalID: number | null = null;\n\n// Not imported immediately due to dependency cycles\n// This gets set during startGameLoop(), and will only be used in the update function\nlet hasWon: null | Ref<boolean> = null;\n\nfunction update() {\n const now = Date.now();\n let diff = (now - player.time) / 1e3;\n player.time = now;\n const trueDiff = diff;\n\n state.lastTenTicks.push(trueDiff);\n if (state.lastTenTicks.length > 10) {\n state.lastTenTicks = state.lastTenTicks.slice(1);\n }\n\n // Stop here if the game is paused on the win screen\n if (hasWon?.value && !player.keepGoing) {\n return;\n }\n // Stop here if the player had a NaN value\n if (state.hasNaN) {\n return;\n }\n\n diff = Math.max(diff, 0);\n\n if (player.devSpeed === 0) {\n return;\n }\n\n // Add offline time if any\n if (player.offlineTime != undefined) {\n if (Decimal.gt(player.offlineTime, projInfo.offlineLimit * 3600)) {\n player.offlineTime = projInfo.offlineLimit * 3600;\n }\n if (Decimal.gt(player.offlineTime, 0) && player.devSpeed !== 0) {\n const offlineDiff = Math.max(player.offlineTime / 10, diff);\n player.offlineTime = player.offlineTime - offlineDiff;\n diff += offlineDiff;\n } else if (player.devSpeed === 0) {\n player.offlineTime += diff;\n }\n if (!player.offlineProd || Decimal.lt(player.offlineTime, 0)) {\n player.offlineTime = null;\n }\n }\n\n // Cap at max tick length\n diff = Math.min(diff, projInfo.maxTickLength);\n\n // Apply dev speed\n if (player.devSpeed != undefined) {\n diff *= player.devSpeed;\n }\n\n if (!Number.isFinite(diff)) {\n diff = 1e308;\n }\n\n // Update\n if (Decimal.eq(diff, 0)) {\n return;\n }\n\n player.timePlayed += diff;\n if (!Number.isFinite(player.timePlayed)) {\n player.timePlayed = 1e308;\n }\n globalBus.emit(\"update\", diff, trueDiff);\n\n if (settings.unthrottled) {\n requestAnimationFrame(update);\n if (intervalID != null) {\n clearInterval(intervalID);\n intervalID = null;\n }\n } else if (intervalID == null) {\n intervalID = setInterval(update, 50);\n }\n}\n\nexport async function startGameLoop() {\n hasWon = (await import(\"data/projEntry\")).hasWon;\n watch(hasWon, hasWon => {\n if (hasWon) {\n globalBus.emit(\"gameWon\");\n }\n });\n if (settings.unthrottled) {\n requestAnimationFrame(update);\n } else {\n intervalID = setInterval(update, 50);\n }\n}\n","import { globalBus } from \"game/events\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { ProxyState } from \"util/proxies\";\nimport { isArray } from \"@vue/shared\";\nimport { isReactive, isRef, Ref, ref } from \"vue\";\nimport { addingLayers, GenericLayer, persistentRefs } from \"./layers\";\n\nexport const PersistentState = Symbol(\"PersistentState\");\nexport const DefaultValue = Symbol(\"DefaultValue\");\nexport const StackTrace = Symbol(\"StackTrace\");\nexport const Deleted = Symbol(\"Deleted\");\n\n// Note: This is a union of things that should be safely stringifiable without needing\n// special processes for knowing what to load them in as\n// - Decimals aren't allowed because we'd need to know to parse them back.\n// - DecimalSources are allowed because the string is a valid value for them\nexport type State =\n | string\n | number\n | boolean\n | DecimalSource\n | { [key: string]: State }\n | { [key: number]: State };\n\nexport type Persistent<T extends State = State> = Ref<T> & {\n [PersistentState]: Ref<T>;\n [DefaultValue]: T;\n [StackTrace]: string;\n [Deleted]: boolean;\n};\n\nfunction getStackTrace() {\n return (\n new Error().stack\n ?.split(\"\\n\")\n .slice(3, 5)\n .map(line => line.trim())\n .join(\"\\n\") || \"\"\n );\n}\n\nexport function persistent<T extends State>(defaultValue: T | Ref<T>): Persistent<T> {\n const persistent = (\n isRef(defaultValue) ? defaultValue : (ref<T>(defaultValue) as unknown)\n ) as Persistent<T>;\n\n persistent[PersistentState] = persistent;\n persistent[DefaultValue] = isRef(defaultValue) ? defaultValue.value : defaultValue;\n persistent[StackTrace] = getStackTrace();\n persistent[Deleted] = false;\n\n if (addingLayers.length === 0) {\n console.warn(\n \"Creating a persistent ref outside of a layer. This is not officially supported\",\n persistent,\n \"\\nCreated at:\\n\" + persistent[StackTrace]\n );\n } else {\n persistentRefs[addingLayers[addingLayers.length - 1]].add(persistent);\n }\n\n return persistent as Persistent<T>;\n}\n\nexport function deletePersistent(persistent: Persistent) {\n if (addingLayers.length === 0) {\n console.warn(\"Deleting a persistent ref outside of a layer. Ignoring...\", persistent);\n } else {\n persistentRefs[addingLayers[addingLayers.length - 1]].delete(persistent);\n }\n persistent[Deleted] = true;\n}\n\nglobalBus.on(\"addLayer\", (layer: GenericLayer, saveData: Record<string, unknown>) => {\n const features: { type: typeof Symbol }[] = [];\n const handleObject = (obj: Record<string, unknown>, path: string[] = []): boolean => {\n let foundPersistent = false;\n Object.keys(obj).forEach(key => {\n const value = obj[key];\n if (value && typeof value === \"object\") {\n if (PersistentState in value) {\n foundPersistent = true;\n if ((value as Persistent)[Deleted]) {\n console.warn(\n \"Deleted persistent ref present in returned object. Ignoring...\",\n value,\n \"\\nCreated at:\\n\" + (value as Persistent)[StackTrace]\n );\n return;\n }\n persistentRefs[layer.id].delete(\n ProxyState in value\n ? // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ((value as any)[ProxyState] as Persistent)\n : (value as Persistent)\n );\n\n // Construct save path if it doesn't exist\n const persistentState = path.reduce<Record<string, unknown>>((acc, curr) => {\n if (!(curr in acc)) {\n acc[curr] = {};\n }\n return acc[curr] as Record<string, unknown>;\n }, saveData);\n\n // Cache currently saved value\n const savedValue = persistentState[key];\n // Add ref to save data\n persistentState[key] = (value as Persistent)[PersistentState];\n // Load previously saved value\n if (isReactive(persistentState)) {\n if (savedValue != null) {\n persistentState[key] = savedValue;\n } else {\n persistentState[key] = (value as Persistent)[DefaultValue];\n }\n } else {\n if (savedValue != null) {\n (persistentState[key] as Ref<unknown>).value = savedValue;\n } else {\n (persistentState[key] as Ref<unknown>).value = (value as Persistent)[\n DefaultValue\n ];\n }\n }\n } else if (\n !(value instanceof Decimal) &&\n !isRef(value) &&\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n !features.includes(value as { type: typeof Symbol })\n ) {\n if (typeof (value as { type: typeof Symbol }).type === \"symbol\") {\n features.push(value as { type: typeof Symbol });\n }\n\n // Continue traversing\n const foundPersistentInChild = handleObject(value as Record<string, unknown>, [\n ...path,\n key\n ]);\n\n // Show warning for persistent values inside arrays\n // TODO handle arrays better\n if (foundPersistentInChild) {\n if (isArray(value) && !isArray(obj)) {\n console.warn(\n \"Found array that contains persistent values when adding layer. Keep in mind changing the order of elements in the array will mess with existing player saves.\",\n ProxyState in obj\n ? (obj as Record<PropertyKey, unknown>)[ProxyState]\n : obj,\n key\n );\n } else {\n foundPersistent = true;\n }\n }\n }\n }\n });\n return foundPersistent;\n };\n handleObject(layer);\n persistentRefs[layer.id].forEach(persistent => {\n console.error(\n `Created persistent ref in ${layer.id} without registering it to the layer! Make sure to include everything persistent in the returned object`,\n persistent,\n \"\\nCreated at:\\n\" + persistent[StackTrace]\n );\n });\n persistentRefs[layer.id].clear();\n});\n","import Decimal from \"util/bignum\";\nimport { isPlainObject } from \"util/common\";\nimport { ProxiedWithState, ProxyPath, ProxyState } from \"util/proxies\";\nimport { reactive, unref } from \"vue\";\nimport transientState from \"./state\";\n\nexport interface PlayerData {\n id: string;\n devSpeed: number | null;\n name: string;\n tabs: Array<string>;\n time: number;\n autosave: boolean;\n offlineProd: boolean;\n offlineTime: number | null;\n timePlayed: number;\n keepGoing: boolean;\n modID: string;\n modVersion: string;\n layers: Record<string, Record<string, unknown>>;\n}\n\nexport type Player = ProxiedWithState<PlayerData>;\n\nconst state = reactive<PlayerData>({\n id: \"\",\n devSpeed: null,\n name: \"\",\n tabs: [],\n time: -1,\n autosave: true,\n offlineProd: true,\n offlineTime: null,\n timePlayed: 0,\n keepGoing: false,\n modID: \"\",\n modVersion: \"\",\n layers: {}\n});\n\nexport function stringifySave(player: PlayerData): string {\n return JSON.stringify(player, (key, value) => unref(value));\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst playerHandler: ProxyHandler<Record<PropertyKey, any>> = {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get(target: Record<PropertyKey, any>, key: PropertyKey): any {\n if (key === ProxyState || key === ProxyPath) {\n return target[key];\n }\n\n const value = target[ProxyState][key];\n if (\n key !== \"value\" &&\n (isPlainObject(value) || Array.isArray(value)) &&\n !(value instanceof Decimal)\n ) {\n if (value !== target[key]?.[ProxyState]) {\n const path = [...target[ProxyPath], key];\n target[key] = new Proxy({ [ProxyState]: value, [ProxyPath]: path }, playerHandler);\n }\n return target[key];\n }\n\n return value;\n },\n set(\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n target: Record<PropertyKey, any>,\n property: PropertyKey,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n value: any,\n receiver: ProxyConstructor\n ): boolean {\n if (\n !transientState.hasNaN &&\n ((typeof value === \"number\" && isNaN(value)) ||\n (value instanceof Decimal &&\n (isNaN(value.sign) || isNaN(value.layer) || isNaN(value.mag))))\n ) {\n const currentValue = target[ProxyState][property];\n if (\n !(\n (typeof currentValue === \"number\" && isNaN(currentValue)) ||\n (currentValue instanceof Decimal &&\n (isNaN(currentValue.sign) ||\n isNaN(currentValue.layer) ||\n isNaN(currentValue.mag)))\n )\n ) {\n state.autosave = false;\n transientState.hasNaN = true;\n transientState.NaNPath = [...target[ProxyPath], property];\n transientState.NaNReceiver = receiver as unknown as Record<string, unknown>;\n console.error(\n `Attempted to set NaN value`,\n [...target[ProxyPath], property],\n target[ProxyState]\n );\n throw \"Attempted to set NaN value. See above for details\";\n }\n }\n target[ProxyState][property] = value;\n return true;\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n ownKeys(target: Record<PropertyKey, any>) {\n return Reflect.ownKeys(target[ProxyState]);\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n has(target: Record<PropertyKey, any>, key: string) {\n return Reflect.has(target[ProxyState], key);\n },\n getOwnPropertyDescriptor(target, key) {\n return Object.getOwnPropertyDescriptor(target[ProxyState], key);\n }\n};\nexport default window.player = new Proxy(\n { [ProxyState]: state, [ProxyPath]: [\"player\"] },\n playerHandler\n) as Player;\n","import projInfo from \"data/projInfo.json\";\nimport { Themes } from \"data/themes\";\nimport { CoercableComponent } from \"features/feature\";\nimport { globalBus } from \"game/events\";\nimport LZString from \"lz-string\";\nimport { hardReset } from \"util/save\";\nimport { reactive, watch } from \"vue\";\n\nexport interface Settings {\n active: string;\n saves: string[];\n showTPS: boolean;\n theme: Themes;\n unthrottled: boolean;\n}\n\nconst state = reactive<Partial<Settings>>({\n active: \"\",\n saves: [],\n showTPS: true,\n theme: Themes.Nordic,\n unthrottled: false\n});\n\nwatch(\n state,\n state => {\n const stringifiedSettings = LZString.compressToUTF16(JSON.stringify(state));\n localStorage.setItem(projInfo.id, stringifiedSettings);\n },\n { deep: true }\n);\nexport default window.settings = state as Settings;\n\nexport function loadSettings(): void {\n try {\n let item: string | null = localStorage.getItem(projInfo.id);\n if (item != null && item !== \"\") {\n if (item[0] === \"{\") {\n // plaintext. No processing needed\n } else if (item[0] === \"e\") {\n // Assumed to be base64, which starts with e\n item = decodeURIComponent(escape(atob(item)));\n } else if (item[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n item = LZString.decompressFromUTF16(item)!;\n } else {\n console.warn(\"Unable to determine settings encoding\", item);\n return;\n }\n const settings = JSON.parse(item);\n if (typeof settings === \"object\") {\n Object.assign(state, settings);\n }\n }\n globalBus.emit(\"loadSettings\", state);\n // eslint-disable-next-line no-empty\n } catch {}\n}\n\nexport const hardResetSettings = (window.hardResetSettings = () => {\n const settings = {\n active: \"\",\n saves: [],\n showTPS: true,\n theme: Themes.Nordic\n };\n globalBus.emit(\"loadSettings\", settings);\n Object.assign(state, settings);\n hardReset();\n});\n\nexport const settingFields: CoercableComponent[] = reactive([]);\nexport function registerSettingField(component: CoercableComponent) {\n settingFields.push(component);\n}\n\nexport const infoComponents: CoercableComponent[] = reactive([]);\nexport function registerInfoComponent(component: CoercableComponent) {\n infoComponents.push(component);\n}\n\nexport const gameComponents: CoercableComponent[] = reactive([]);\nexport function registerGameComponent(component: CoercableComponent) {\n gameComponents.push(component);\n}\n","import { shallowReactive } from \"vue\";\n\nexport interface Transient {\n lastTenTicks: number[];\n hasNaN: boolean;\n NaNPath?: string[];\n NaNReceiver?: Record<string, unknown>;\n}\n\nexport default window.state = shallowReactive<Transient>({\n lastTenTicks: [],\n hasNaN: false,\n NaNPath: []\n});\n","import { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, resolveComponent as _resolveComponent, withCtx as _withCtx, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Context = _resolveComponent(\"Context\")!\n\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"layer-container\",\n style: _normalizeStyle({ '--layer-color': _ctx.unref(_ctx.color) })\n }, [\n (_ctx.showGoBack)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n class: \"goBack\",\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.goBack && _ctx.goBack(...args)))\n }, \"←\"))\n : _createCommentVNode(\"\", true),\n (_ctx.minimized.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 1,\n class: \"layer-tab minimized\",\n onClick: _cache[1] || (_cache[1] = ($event: any) => (_ctx.minimized.value = false))\n }, [\n _createElementVNode(\"div\", null, _toDisplayString(_ctx.unref(_ctx.name)), 1)\n ]))\n : (_openBlock(), _createElementBlock(\"div\", {\n key: 2,\n class: _normalizeClass([\"layer-tab\", { showGoBack: _ctx.showGoBack }])\n }, [\n _createVNode(_component_Context, { onUpdateNodes: _ctx.updateNodes }, {\n default: _withCtx(() => [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component)))\n ]),\n _: 1\n }, 8, [\"onUpdateNodes\"])\n ], 2)),\n (_ctx.unref(_ctx.minimizable))\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 3,\n class: \"minimize\",\n onClick: _cache[2] || (_cache[2] = ($event: any) => (_ctx.minimized.value = true))\n }, \" ▼ \"))\n : _createCommentVNode(\"\", true)\n ], 4))\n}","\nimport projInfo from \"data/projInfo.json\";\nimport { CoercableComponent } from \"features/feature\";\nimport { FeatureNode } from \"game/layers\";\nimport { Persistent } from \"game/persistence\";\nimport player from \"game/player\";\nimport { computeComponent, processedPropType, wrapRef } from \"util/vue\";\nimport { computed, defineComponent, nextTick, PropType, Ref, toRefs, unref, watch } from \"vue\";\nimport Context from \"./Context.vue\";\n\nexport default defineComponent({\n components: { Context },\n props: {\n index: {\n type: Number,\n required: true\n },\n tab: {\n type: Function as PropType<() => HTMLElement | undefined>,\n required: true\n },\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n minimized: {\n type: Object as PropType<Persistent<boolean>>,\n required: true\n },\n minWidth: {\n type: processedPropType<number | string>(Number, String),\n required: true\n },\n name: {\n type: processedPropType<string>(String),\n required: true\n },\n color: processedPropType<string>(String),\n minimizable: processedPropType<boolean>(Boolean),\n nodes: {\n type: Object as PropType<Ref<Record<string, FeatureNode | undefined>>>,\n required: true\n }\n },\n setup(props) {\n const { display, index, minimized, minWidth, tab } = toRefs(props);\n\n const component = computeComponent(display);\n const showGoBack = computed(\n () => projInfo.allowGoBack && index.value > 0 && !minimized.value\n );\n\n function goBack() {\n player.tabs.splice(unref(props.index), Infinity);\n }\n\n nextTick(() => updateTab(minimized.value, unref(minWidth.value)));\n watch([minimized, wrapRef(minWidth)], ([minimized, minWidth]) =>\n updateTab(minimized, minWidth)\n );\n\n function updateNodes(nodes: Record<string, FeatureNode | undefined>) {\n props.nodes.value = nodes;\n }\n\n function updateTab(minimized: boolean, minWidth: number | string) {\n const width =\n typeof minWidth === \"number\" || Number.isNaN(parseInt(minWidth))\n ? minWidth + \"px\"\n : minWidth;\n const tabValue = tab.value();\n if (tabValue != undefined) {\n if (minimized) {\n tabValue.style.flexGrow = \"0\";\n tabValue.style.flexShrink = \"0\";\n tabValue.style.width = \"60px\";\n tabValue.style.minWidth = tabValue.style.flexBasis = \"\";\n tabValue.style.margin = \"0\";\n } else {\n tabValue.style.flexGrow = \"\";\n tabValue.style.flexShrink = \"\";\n tabValue.style.width = \"\";\n tabValue.style.minWidth = tabValue.style.flexBasis = width;\n tabValue.style.margin = \"\";\n }\n }\n }\n\n return {\n component,\n showGoBack,\n updateNodes,\n unref,\n goBack\n };\n }\n});\n","import { render } from \"./Layer.vue?vue&type=template&id=e18f60b6&scoped=true&ts=true\"\nimport script from \"./Layer.vue?vue&type=script&lang=ts\"\nexport * from \"./Layer.vue?vue&type=script&lang=ts\"\n\nimport \"./Layer.vue?vue&type=style&index=0&id=e18f60b6&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e18f60b6\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { createElementVNode as _createElementVNode, createTextVNode as _createTextVNode, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5f8298e6\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"h2\", null, \"Changelog\", -1))\nconst _hoisted_2 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"details\", { open: \"\" }, [\n /*#__PURE__*/_createElementVNode(\"summary\", null, [\n /*#__PURE__*/_createTextVNode(\"v0.0 Initial Commit - \"),\n /*#__PURE__*/_createElementVNode(\"time\", null, \"2021-09-04\")\n ]),\n /*#__PURE__*/_createTextVNode(\" This is the first release :D \"),\n /*#__PURE__*/_createElementVNode(\"ul\", null, [\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"feature\" }, \"Did everything\"),\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"fix\" }, \"Had some fun\"),\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"breaking\" }, \"Removed everything\"),\n /*#__PURE__*/_createElementVNode(\"li\", { class: \"balancing\" }, \"Created some bugs to fix later\")\n ])\n], -1))\n\nimport Modal from \"components/Modal.vue\";\nimport { ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props, { expose }) {\n\nconst isOpen = ref(false);\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((isOpen).value = $event))\n }, {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(() => [\n _hoisted_2\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./Changelog.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Changelog.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Changelog.vue?vue&type=style&index=0&id=5f8298e6&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-5f8298e6\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, createTextVNode as _createTextVNode, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, withCtx as _withCtx, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-3eb46986\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"info-modal-header\" }\nconst _hoisted_2 = [\"src\", \"alt\"]\nconst _hoisted_3 = { class: \"info-modal-title\" }\nconst _hoisted_4 = { key: 0 }\nconst _hoisted_5 = { key: 0 }\nconst _hoisted_6 = { key: 0 }\nconst _hoisted_7 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, \" Made in Profectus, by thepaperpilot with inspiration from Acameada and Jacorb \", -1))\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_9 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_10 = [\"href\"]\nconst _hoisted_11 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons info-modal-discord\" }, \"discord\", -1))\nconst _hoisted_12 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/WzejVAx\",\n class: \"info-modal-discord-link\"\n }, [\n /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons info-modal-discord\" }, \"discord\"),\n /*#__PURE__*/_createTextVNode(\" The Paper Pilot Community \")\n ])\n], -1))\nconst _hoisted_13 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/F3xveHV\",\n class: \"info-modal-discord-link\"\n }, [\n /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons info-modal-discord\" }, \"discord\"),\n /*#__PURE__*/_createTextVNode(\" The Modding Tree \")\n ])\n], -1))\nconst _hoisted_14 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\n\nimport Modal from \"components/Modal.vue\";\nimport type Changelog from \"data/Changelog.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport { jsx } from \"features/feature\";\nimport player from \"game/player\";\nimport { infoComponents } from \"game/settings\";\nimport { formatTime } from \"util/bignum\";\nimport { coerceComponent, render } from \"util/vue\";\nimport { computed, ref, toRefs, unref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n changelog: null\n },\n setup(__props: any, { expose }) {\n\nconst _props = __props as { changelog: typeof Changelog | null }\n\nconst { title, logo, author, discordName, discordLink, versionNumber, versionTitle } = projInfo;\n\n\nconst props = toRefs(_props);\n\nconst isOpen = ref(false);\n\nconst timePlayed = computed(() => formatTime(player.timePlayed));\n\nconst infoComponent = computed(() => {\n return coerceComponent(jsx(() => <>{infoComponents.map(render)}</>));\n});\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nfunction openChangelog() {\n unref(props.changelog)?.open();\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((isOpen).value = $event))\n }, {\n header: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_1, [\n (_unref(logo))\n ? (_openBlock(), _createElementBlock(\"img\", {\n key: 0,\n class: \"info-modal-logo\",\n src: _unref(logo),\n alt: _unref(title)\n }, null, 8, _hoisted_2))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_3, [\n _createElementVNode(\"h2\", null, _toDisplayString(_unref(title)), 1),\n _createElementVNode(\"h4\", null, [\n _createTextVNode(\" v\" + _toDisplayString(_unref(versionNumber)), 1),\n (_unref(versionTitle))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_4, \": \" + _toDisplayString(_unref(versionTitle)), 1))\n : _createCommentVNode(\"\", true)\n ])\n ])\n ])\n ]),\n body: _withCtx(({ shown }) => [\n shown\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_5, [\n (_unref(author))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_6, \"By \" + _toDisplayString(_unref(author)), 1))\n : _createCommentVNode(\"\", true),\n _hoisted_7,\n _hoisted_8,\n _createElementVNode(\"div\", {\n class: \"link\",\n onClick: openChangelog\n }, \"Changelog\"),\n _hoisted_9,\n _createElementVNode(\"div\", null, [\n (_unref(discordLink) !== 'https://discord.gg/WzejVAx')\n ? (_openBlock(), _createElementBlock(\"a\", {\n key: 0,\n href: _unref(discordLink),\n class: \"info-modal-discord-link\"\n }, [\n _hoisted_11,\n _createTextVNode(\" \" + _toDisplayString(_unref(discordName)), 1)\n ], 8, _hoisted_10))\n : _createCommentVNode(\"\", true)\n ]),\n _hoisted_12,\n _hoisted_13,\n _hoisted_14,\n _createElementVNode(\"div\", null, \"Time Played: \" + _toDisplayString(_unref(timePlayed)), 1),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(infoComponent))))\n ]))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./Info.vue?vue&type=script&setup=true&lang=tsx\"\nexport * from \"./Info.vue?vue&type=script&setup=true&lang=tsx\"\n\nimport \"./Info.vue?vue&type=style&index=0&id=3eb46986&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-3eb46986\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { createElementVNode as _createElementVNode, unref as _unref, isRef as _isRef, createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, withCtx as _withCtx, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-85d7ae40\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { class: \"header\" }, [\n /*#__PURE__*/_createElementVNode(\"h2\", null, \"Options\")\n], -1))\nconst _hoisted_2 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"hr\", null, null, -1))\n\nimport Modal from \"components/Modal.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport rawThemes from \"data/themes\";\nimport { jsx } from \"features/feature\";\nimport player from \"game/player\";\nimport settings, { settingFields } from \"game/settings\";\nimport { camelToTitle } from \"util/common\";\nimport { coerceComponent, render } from \"util/vue\";\nimport { computed, ref, toRefs } from \"vue\";\nimport Select from \"./fields/Select.vue\";\nimport Toggle from \"./fields/Toggle.vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props, { expose }) {\n\nconst isOpen = ref(false);\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nconst themes = Object.keys(rawThemes).map(theme => ({\n label: camelToTitle(theme),\n value: theme\n}));\n\nconst settingFieldsComponent = computed(() => {\n return coerceComponent(jsx(() => <>{settingFields.map(render)}</>));\n});\n\nconst { showTPS, theme, unthrottled } = toRefs(settings);\nconst { autosave, offlineProd } = toRefs(player);\nconst isPaused = computed({\n get() {\n return player.devSpeed === 0;\n },\n set(value: boolean) {\n player.devSpeed = value ? 0 : null;\n }\n});\n\nconst offlineProdTitle = jsx(() => (\n <span>\n Offline Production<Tooltip display=\"Save-specific\">*</Tooltip>\n </span>\n));\nconst autosaveTitle = jsx(() => (\n <span>\n Autosave<Tooltip display=\"Save-specific\">*</Tooltip>\n </span>\n));\nconst isPausedTitle = jsx(() => (\n <span>\n Pause game<Tooltip display=\"Save-specific\">*</Tooltip>\n </span>\n));\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[6] || (_cache[6] = ($event: any) => ((isOpen).value = $event))\n }, {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(() => [\n _createVNode(Select, {\n title: \"Theme\",\n options: _unref(themes),\n modelValue: _unref(theme),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(theme) ? (theme).value = $event : null))\n }, null, 8, [\"options\", \"modelValue\"]),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(settingFieldsComponent)))),\n _createVNode(Toggle, {\n title: \"Show TPS\",\n modelValue: _unref(showTPS),\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => (_isRef(showTPS) ? (showTPS).value = $event : null))\n }, null, 8, [\"modelValue\"]),\n _hoisted_2,\n _createVNode(Toggle, {\n title: \"Unthrottled\",\n modelValue: _unref(unthrottled),\n \"onUpdate:modelValue\": _cache[2] || (_cache[2] = ($event: any) => (_isRef(unthrottled) ? (unthrottled).value = $event : null))\n }, null, 8, [\"modelValue\"]),\n _createVNode(Toggle, {\n title: _unref(offlineProdTitle),\n modelValue: _unref(offlineProd),\n \"onUpdate:modelValue\": _cache[3] || (_cache[3] = ($event: any) => (_isRef(offlineProd) ? (offlineProd).value = $event : null))\n }, null, 8, [\"title\", \"modelValue\"]),\n _createVNode(Toggle, {\n title: _unref(autosaveTitle),\n modelValue: _unref(autosave),\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = ($event: any) => (_isRef(autosave) ? (autosave).value = $event : null))\n }, null, 8, [\"title\", \"modelValue\"]),\n (_unref(projInfo).enablePausing)\n ? (_openBlock(), _createBlock(Toggle, {\n key: 0,\n title: _unref(isPausedTitle),\n modelValue: _unref(isPaused),\n \"onUpdate:modelValue\": _cache[5] || (_cache[5] = ($event: any) => (_isRef(isPaused) ? (isPaused).value = $event : null))\n }, null, 8, [\"title\", \"modelValue\"]))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./Options.vue?vue&type=script&setup=true&lang=tsx\"\nexport * from \"./Options.vue?vue&type=script&setup=true&lang=tsx\"\n\nimport \"./Options.vue?vue&type=style&index=0&id=85d7ae40&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-85d7ae40\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, renderSlot as _renderSlot, withModifiers as _withModifiers, createElementVNode as _createElementVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-bf59fca4\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { key: 0 }\nconst _hoisted_2 = [\"onClick\", \"disabled\"]\nconst _hoisted_3 = { key: 0 }\nconst _hoisted_4 = [\"onClick\"]\n\nimport { ref, toRefs, unref, watch } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n disabled: { type: Boolean },\n skipConfirm: { type: Boolean }\n },\n emits: [\"click\", \"confirmingChanged\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"click\"): void;\n (e: \"confirmingChanged\", value: boolean): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n disabled?: boolean;\n skipConfirm?: boolean;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst isConfirming = ref(false);\n\nwatch(isConfirming, isConfirming => {\n emit(\"confirmingChanged\", isConfirming);\n});\n\nfunction click() {\n if (unref(props.skipConfirm)) {\n emit(\"click\");\n return;\n }\n if (isConfirming.value) {\n emit(\"click\");\n }\n isConfirming.value = !isConfirming.value;\n}\n\nfunction cancel() {\n isConfirming.value = false;\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"span\", {\n class: _normalizeClass([\"container\", { confirming: isConfirming.value }])\n }, [\n (isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \"Are you sure?\"))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"button\", {\n onClick: _withModifiers(click, [\"stop\"]),\n class: \"button danger\",\n disabled: __props.disabled\n }, [\n (isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_3, \"Yes\"))\n : _renderSlot(_ctx.$slots, \"default\", { key: 1 })\n ], 8, _hoisted_2),\n (isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 1,\n class: \"button\",\n onClick: _withModifiers(cancel, [\"stop\"])\n }, \"No\", 8, _hoisted_4))\n : _createCommentVNode(\"\", true)\n ], 2))\n}\n}\n\n})","import script from \"./DangerButton.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./DangerButton.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./DangerButton.vue?vue&type=style&index=0&id=bf59fca4&scoped=true&lang=css\"\nimport \"./DangerButton.vue?vue&type=style&index=1&id=bf59fca4&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-bf59fca4\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, withModifiers as _withModifiers, normalizeClass as _normalizeClass, openBlock as _openBlock, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5bbcedd3\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"onClick\"]\n\nimport { nextTick, ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n left: { type: Boolean }\n },\n emits: [\"click\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"click\"): void;\n}), expose: any, slots: any, attrs: any }) {\n\n\n\n\nconst activated = ref(false);\nconst activatedTimeout = ref<number | null>(null);\n\nfunction click() {\n emit(\"click\");\n\n // Give feedback to user\n if (activatedTimeout.value) {\n clearTimeout(activatedTimeout.value);\n }\n activated.value = false;\n nextTick(() => {\n activated.value = true;\n activatedTimeout.value = setTimeout(() => (activated.value = false), 500);\n });\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"button\", {\n onClick: _withModifiers(click, [\"stop\"]),\n class: _normalizeClass([\"feedback\", { activated: activated.value, left: __props.left }])\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 10, _hoisted_1))\n}\n}\n\n})","import script from \"./FeedbackButton.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./FeedbackButton.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./FeedbackButton.vue?vue&type=style&index=0&id=5bbcedd3&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-5bbcedd3\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementBlock as _createElementBlock, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-335ce270\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { class: \"handle material-icons\" }, \"drag_handle\", -1))\nconst _hoisted_2 = {\n key: 0,\n class: \"actions\"\n}\nconst _hoisted_3 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"content_paste\", -1))\nconst _hoisted_4 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"content_copy\", -1))\nconst _hoisted_5 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"edit\", -1))\nconst _hoisted_6 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", {\n class: \"material-icons\",\n style: {\"margin\":\"-2px\"}\n}, \"delete\", -1))\nconst _hoisted_7 = {\n key: 1,\n class: \"actions\"\n}\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"check\", -1))\nconst _hoisted_9 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"close\", -1))\nconst _hoisted_10 = {\n key: 2,\n class: \"details\"\n}\nconst _hoisted_11 = { class: \"save-version\" }\nconst _hoisted_12 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_13 = { key: 0 }\nconst _hoisted_14 = {\n key: 3,\n class: \"details\"\n}\nconst _hoisted_15 = {\n key: 4,\n class: \"details error\"\n}\nconst _hoisted_16 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\n\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport player from \"game/player\";\nimport { Direction } from \"util/common\";\nimport { computed, ref, toRefs, watch } from \"vue\";\nimport DangerButton from \"./fields/DangerButton.vue\";\nimport FeedbackButton from \"./fields/FeedbackButton.vue\";\nimport Text from \"./fields/Text.vue\";\nimport { LoadablePlayerData } from \"./SavesManager.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n save: null\n },\n emits: [\"export\", \"open\", \"duplicate\", \"delete\", \"editName\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"export\"): void;\n (e: \"open\"): void;\n (e: \"duplicate\"): void;\n (e: \"delete\"): void;\n (e: \"editName\", name: string): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n save: LoadablePlayerData;\n}\n\n\nconst { save } = toRefs(_props);\n\n\nconst dateFormat = new Intl.DateTimeFormat(\"en-US\", {\n year: \"numeric\",\n month: \"numeric\",\n day: \"numeric\",\n hour: \"numeric\",\n minute: \"numeric\",\n second: \"numeric\"\n});\n\nconst isEditing = ref(false);\nconst isConfirming = ref(false);\nconst newName = ref(\"\");\n\nwatch(isEditing, () => (newName.value = save.value.name || \"\"));\n\nconst isActive = computed(() => save.value && save.value.id === player.id);\nconst currentTime = computed(() =>\n isActive.value ? player.time : (save.value && save.value.time) || 0\n);\n\nfunction changeName() {\n emit(\"editName\", newName.value);\n isEditing.value = false;\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"save\", { active: _unref(isActive) }])\n }, [\n _hoisted_1,\n (!isEditing.value)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_2, [\n (_unref(save).error == undefined && !isConfirming.value)\n ? (_openBlock(), _createBlock(FeedbackButton, {\n key: 0,\n onClick: _cache[0] || (_cache[0] = ($event: any) => (emit('export'))),\n class: \"button\",\n left: \"\"\n }, {\n default: _withCtx(() => [\n _createVNode(Tooltip, {\n display: \"Export\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_3\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(save).error == undefined && !isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 1,\n onClick: _cache[1] || (_cache[1] = ($event: any) => (emit('duplicate'))),\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Duplicate\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_4\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]))\n : _createCommentVNode(\"\", true),\n (_unref(save).error == undefined && !isConfirming.value)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 2,\n onClick: _cache[2] || (_cache[2] = ($event: any) => (isEditing.value = !isEditing.value)),\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Edit Name\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_5\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]))\n : _createCommentVNode(\"\", true),\n _createVNode(DangerButton, {\n disabled: _unref(isActive),\n onClick: _cache[3] || (_cache[3] = ($event: any) => (emit('delete'))),\n onConfirmingChanged: _cache[4] || (_cache[4] = value => (isConfirming.value = value))\n }, {\n default: _withCtx(() => [\n _createVNode(Tooltip, {\n display: \"Delete\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_6\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _: 1\n }, 8, [\"disabled\"])\n ]))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_7, [\n _createElementVNode(\"button\", {\n onClick: changeName,\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Save\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_8\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"button\", {\n onClick: _cache[5] || (_cache[5] = ($event: any) => (isEditing.value = !isEditing.value)),\n class: \"button\"\n }, [\n _createVNode(Tooltip, {\n display: \"Cancel\",\n direction: _unref(Direction).Left,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_9\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ])),\n (_unref(save).error == undefined && !isEditing.value)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_10, [\n _createElementVNode(\"button\", {\n class: \"button open\",\n onClick: _cache[6] || (_cache[6] = ($event: any) => (emit('open')))\n }, [\n _createElementVNode(\"h3\", null, _toDisplayString(_unref(save).name), 1)\n ]),\n _createElementVNode(\"span\", _hoisted_11, \"v\" + _toDisplayString(_unref(save).modVersion), 1),\n _hoisted_12,\n (_unref(currentTime))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_13, \"Last played \" + _toDisplayString(_unref(dateFormat).format(_unref(currentTime))), 1))\n : _createCommentVNode(\"\", true)\n ]))\n : (_unref(save).error == undefined && isEditing.value)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_14, [\n _createVNode(Text, {\n modelValue: newName.value,\n \"onUpdate:modelValue\": _cache[7] || (_cache[7] = ($event: any) => ((newName).value = $event)),\n class: \"editname\",\n onSubmit: changeName\n }, null, 8, [\"modelValue\"])\n ]))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_15, [\n _createTextVNode(\" Error: Failed to load save with id \" + _toDisplayString(_unref(save).id), 1),\n _hoisted_16,\n _createTextVNode(_toDisplayString(_unref(save).error), 1)\n ]))\n ], 2))\n}\n}\n\n})","import script from \"./Save.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Save.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Save.vue?vue&type=style&index=0&id=335ce270&scoped=true&lang=css\"\nimport \"./Save.vue?vue&type=style&index=1&id=335ce270&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-335ce270\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { createElementVNode as _createElementVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-2bfdf896\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"h2\", null, \"Saves Manager\", -1))\nconst _hoisted_2 = { class: \"modal-footer\" }\nconst _hoisted_3 = { class: \"field\" }\nconst _hoisted_4 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"field-title\" }, \"Create Save\", -1))\nconst _hoisted_5 = { class: \"field-buttons\" }\nconst _hoisted_6 = { class: \"footer\" }\nconst _hoisted_7 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { style: {\"flex-grow\":\"1\"} }, null, -1))\n\nimport projInfo from \"data/projInfo.json\";\nimport Modal from \"components/Modal.vue\";\nimport player, { PlayerData, stringifySave } from \"game/player\";\nimport settings from \"game/settings\";\nimport { getUniqueID, loadSave, save, newSave } from \"util/save\";\nimport { ComponentPublicInstance, computed, nextTick, ref, shallowReactive, watch } from \"vue\";\nimport Select from \"./fields/Select.vue\";\nimport Text from \"./fields/Text.vue\";\nimport Save from \"./Save.vue\";\nimport Draggable from \"vuedraggable\";\nimport LZString from \"lz-string\";\nimport { ProxyState } from \"util/proxies\";\n\nexport type LoadablePlayerData = Omit<Partial<PlayerData>, \"id\"> & { id: string; error?: unknown };\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props, { expose }) {\n\nconst isOpen = ref(false);\nconst modal = ref<ComponentPublicInstance<typeof Modal> | null>(null);\n\nexpose({\n open() {\n isOpen.value = true;\n }\n});\n\nconst importingFailed = ref(false);\nconst saveToImport = ref(\"\");\nconst selectedPreset = ref<string | null>(null);\n\nwatch(saveToImport, importedSave => {\n if (importedSave) {\n nextTick(() => {\n try {\n if (importedSave[0] === \"{\") {\n // plaintext. No processing needed\n } else if (importedSave[0] === \"e\") {\n // Assumed to be base64, which starts with e\n importedSave = decodeURIComponent(escape(atob(importedSave)));\n } else if (importedSave[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n importedSave = LZString.decompressFromUTF16(importedSave)!;\n } else {\n console.warn(\"Unable to determine preset encoding\", importedSave);\n importingFailed.value = true;\n return;\n }\n const playerData = JSON.parse(importedSave);\n if (typeof playerData !== \"object\") {\n importingFailed.value = true;\n return;\n }\n const id = getUniqueID();\n playerData.id = id;\n save(playerData);\n saveToImport.value = \"\";\n importingFailed.value = false;\n\n settings.saves.push(id);\n } catch (e) {\n importingFailed.value = true;\n }\n });\n } else {\n importingFailed.value = false;\n }\n});\n\nlet bankContext = require.context(\"raw-loader!../../saves\", true, /\\.txt$/);\nlet bank = ref(\n bankContext.keys().reduce((acc: Array<{ label: string; value: string }>, curr) => {\n // .slice(2, -4) strips the leading ./ and the trailing .txt\n acc.push({\n label: curr.slice(2, -4),\n value: bankContext(curr).default\n });\n return acc;\n }, [])\n);\n\nconst cachedSaves = shallowReactive<Record<string, LoadablePlayerData | undefined>>({});\nfunction getCachedSave(id: string) {\n if (cachedSaves[id] == null) {\n let save = localStorage.getItem(id);\n if (save == null) {\n cachedSaves[id] = { error: `Save doesn't exist in localStorage`, id };\n } else if (save === \"dW5kZWZpbmVk\") {\n cachedSaves[id] = { error: `Save is undefined`, id };\n } else {\n try {\n if (save[0] === \"{\") {\n // plaintext. No processing needed\n } else if (save[0] === \"e\") {\n // Assumed to be base64, which starts with e\n save = decodeURIComponent(escape(atob(save)));\n } else if (save[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n save = LZString.decompressFromUTF16(save)!;\n } else {\n console.warn(\"Unable to determine preset encoding\", save);\n importingFailed.value = true;\n cachedSaves[id] = { error: \"Unable to determine preset encoding\", id };\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n return cachedSaves[id]!;\n }\n cachedSaves[id] = { ...JSON.parse(save), id };\n } catch (error) {\n cachedSaves[id] = { error, id };\n console.warn(\n `SavesManager: Failed to load info about save with id ${id}:\\n${error}\\n${save}`\n );\n }\n }\n }\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n return cachedSaves[id]!;\n}\n// Wipe cache whenever the modal is opened\nwatch(isOpen, isOpen => {\n if (isOpen) {\n Object.keys(cachedSaves).forEach(key => delete cachedSaves[key]);\n }\n});\n\nconst saves = computed(() =>\n settings.saves.reduce((acc: Record<string, LoadablePlayerData>, curr: string) => {\n acc[curr] = getCachedSave(curr);\n return acc;\n }, {})\n);\n\nfunction exportSave(id: string) {\n let saveToExport;\n if (player.id === id) {\n saveToExport = stringifySave(player[ProxyState]);\n } else {\n saveToExport = JSON.stringify(saves.value[id]);\n }\n switch (projInfo.exportEncoding) {\n default:\n console.warn(`Unknown save encoding: ${projInfo.exportEncoding}. Defaulting to lz`);\n case \"lz\":\n saveToExport = LZString.compressToUTF16(saveToExport);\n break;\n case \"base64\":\n saveToExport = btoa(unescape(encodeURIComponent(saveToExport)));\n break;\n case \"plain\":\n break;\n }\n\n // Put on clipboard. Using the clipboard API asks for permissions and stuff\n const el = document.createElement(\"textarea\");\n el.value = saveToExport;\n document.body.appendChild(el);\n el.select();\n el.setSelectionRange(0, 99999);\n document.execCommand(\"copy\");\n document.body.removeChild(el);\n}\n\nfunction duplicateSave(id: string) {\n if (player.id === id) {\n save();\n }\n\n const playerData = { ...saves.value[id], id: getUniqueID() };\n save(playerData as PlayerData);\n\n settings.saves.push(playerData.id);\n}\n\nfunction deleteSave(id: string) {\n settings.saves = settings.saves.filter((save: string) => save !== id);\n localStorage.removeItem(id);\n cachedSaves[id] = undefined;\n}\n\nfunction openSave(id: string) {\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n saves.value[player.id]!.time = player.time;\n save();\n cachedSaves[player.id] = undefined;\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n loadSave(saves.value[id]!);\n // Delete cached version in case of opening it again\n cachedSaves[id] = undefined;\n}\n\nfunction newFromPreset(preset: string) {\n // Reset preset dropdown\n selectedPreset.value = preset;\n nextTick(() => {\n selectedPreset.value = null;\n });\n\n if (preset[0] === \"{\") {\n // plaintext. No processing needed\n } else if (preset[0] === \"e\") {\n // Assumed to be base64, which starts with e\n preset = decodeURIComponent(escape(atob(preset)));\n } else if (preset[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n preset = LZString.decompressFromUTF16(preset)!;\n } else {\n console.warn(\"Unable to determine preset encoding\", preset);\n return;\n }\n const playerData = JSON.parse(preset);\n playerData.id = getUniqueID();\n save(playerData as PlayerData);\n\n settings.saves.push(playerData.id);\n\n openSave(playerData.id);\n}\n\nfunction editSave(id: string, newName: string) {\n const currSave = saves.value[id];\n if (currSave) {\n currSave.name = newName;\n if (player.id === id) {\n player.name = newName;\n save();\n } else {\n save(currSave as PlayerData);\n cachedSaves[id] = undefined;\n }\n }\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, {\n modelValue: isOpen.value,\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = ($event: any) => ((isOpen).value = $event)),\n ref_key: \"modal\",\n ref: modal\n }, {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(({ shown }) => [\n shown\n ? (_openBlock(), _createBlock(_unref(Draggable), {\n key: 0,\n list: _unref(settings).saves,\n handle: \".handle\",\n itemKey: (save) => save\n }, {\n item: _withCtx(({ element }) => [\n _createVNode(Save, {\n save: _unref(saves)[element],\n onOpen: ($event: any) => (openSave(element)),\n onExport: ($event: any) => (exportSave(element)),\n onEditName: name => editSave(element, name),\n onDuplicate: ($event: any) => (duplicateSave(element)),\n onDelete: ($event: any) => (deleteSave(element))\n }, null, 8, [\"save\", \"onOpen\", \"onExport\", \"onEditName\", \"onDuplicate\", \"onDelete\"])\n ]),\n _: 1\n }, 8, [\"list\", \"itemKey\"]))\n : _createCommentVNode(\"\", true)\n ]),\n footer: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_2, [\n _createVNode(Text, {\n modelValue: saveToImport.value,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((saveToImport).value = $event)),\n title: \"Import Save\",\n placeholder: \"Paste your save here!\",\n class: _normalizeClass({ importingFailed: importingFailed.value })\n }, null, 8, [\"modelValue\", \"class\"]),\n _createElementVNode(\"div\", _hoisted_3, [\n _hoisted_4,\n _createElementVNode(\"div\", _hoisted_5, [\n _createElementVNode(\"button\", {\n class: \"button\",\n onClick: _cache[1] || (_cache[1] = ($event: any) => (openSave(_unref(newSave)().id)))\n }, \"New Game\"),\n (Object.keys(_unref(bank)).length > 0)\n ? (_openBlock(), _createBlock(Select, {\n key: 0,\n options: _unref(bank),\n modelValue: selectedPreset.value,\n \"onUpdate:modelValue\": _cache[2] || (_cache[2] = preset => newFromPreset(preset as string)),\n closeOnSelect: \"\",\n placeholder: \"Select preset\",\n class: \"presets\"\n }, null, 8, [\"options\", \"modelValue\"]))\n : _createCommentVNode(\"\", true)\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_6, [\n _hoisted_7,\n _createElementVNode(\"button\", {\n class: \"button modal-default-button\",\n onClick: _cache[3] || (_cache[3] = ($event: any) => (isOpen.value = false))\n }, \" Close \")\n ])\n ])\n ]),\n _: 1\n }, 8, [\"modelValue\"]))\n}\n}\n\n})","import script from \"./SavesManager.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./SavesManager.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./SavesManager.vue?vue&type=style&index=0&id=2bfdf896&scoped=true&lang=css\"\nimport \"./SavesManager.vue?vue&type=style&index=1&id=2bfdf896&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-2bfdf896\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, mergeProps as _mergeProps, Fragment as _Fragment, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-53a1a91d\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"src\", \"alt\"]\nconst _hoisted_2 = {\n key: 1,\n class: \"title\"\n}\nconst _hoisted_3 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { style: {\"flex-grow\":\"1\",\"cursor\":\"unset\"} }, null, -1))\nconst _hoisted_4 = { class: \"discord\" }\nconst _hoisted_5 = { class: \"discord-links\" }\nconst _hoisted_6 = { key: 0 }\nconst _hoisted_7 = [\"href\"]\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/WzejVAx\",\n target: \"_blank\"\n }, \"The Paper Pilot Community\")\n], -1))\nconst _hoisted_9 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/F3xveHV\",\n target: \"_blank\"\n }, \"The Modding Tree\")\n], -1))\nconst _hoisted_10 = {\n href: \"https://forums.moddingtree.com/\",\n target: \"_blank\"\n}\nconst _hoisted_11 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"forum\", -1))\nconst _hoisted_12 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"info\", -1))\nconst _hoisted_13 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"library_books\", -1))\nconst _hoisted_14 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"settings\", -1))\nconst _hoisted_15 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"library_books\", -1))\nconst _hoisted_16 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"settings\", -1))\nconst _hoisted_17 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"info\", -1))\nconst _hoisted_18 = {\n href: \"https://forums.moddingtree.com/\",\n target: \"_blank\"\n}\nconst _hoisted_19 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons\" }, \"forum\", -1))\nconst _hoisted_20 = { class: \"discord\" }\nconst _hoisted_21 = { class: \"discord-links\" }\nconst _hoisted_22 = { key: 0 }\nconst _hoisted_23 = [\"href\"]\nconst _hoisted_24 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/WzejVAx\",\n target: \"_blank\"\n }, \"The Paper Pilot Community\")\n], -1))\nconst _hoisted_25 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"li\", null, [\n /*#__PURE__*/_createElementVNode(\"a\", {\n href: \"https://discord.gg/F3xveHV\",\n target: \"_blank\"\n }, \"The Modding Tree\")\n], -1))\n\nimport Changelog from \"data/Changelog.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport { ComponentPublicInstance, ref } from \"vue\";\nimport Info from \"./Info.vue\";\nimport Options from \"./Options.vue\";\nimport SavesManager from \"./SavesManager.vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport { Direction } from \"util/common\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst info = ref<ComponentPublicInstance<typeof Info> | null>(null);\nconst savesManager = ref<ComponentPublicInstance<typeof SavesManager> | null>(null);\nconst options = ref<ComponentPublicInstance<typeof Options> | null>(null);\n// For some reason Info won't accept the changelog unless I do this:\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst changelog = ref<ComponentPublicInstance<any> | null>(null);\n\nconst { useHeader, banner, title, discordName, discordLink, versionNumber } = projInfo;\n\nfunction openDiscord() {\n window.open(discordLink, \"mywindow\");\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (_unref(useHeader))\n ? (_openBlock(), _createElementBlock(\"div\", _mergeProps({\n key: 0,\n class: \"nav\"\n }, _ctx.$attrs), [\n (_unref(banner))\n ? (_openBlock(), _createElementBlock(\"img\", {\n key: 0,\n src: _unref(banner),\n class: \"banner\",\n alt: _unref(title)\n }, null, 8, _hoisted_1))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_2, _toDisplayString(_unref(title)), 1)),\n _createElementVNode(\"div\", {\n onClick: _cache[0] || (_cache[0] = ($event: any) => (changelog.value?.open())),\n class: \"version-container\"\n }, [\n _createVNode(Tooltip, {\n display: \"Changelog\",\n direction: _unref(Direction).Down,\n class: \"version\"\n }, {\n default: _withCtx(() => [\n _createElementVNode(\"span\", null, \"v\" + _toDisplayString(_unref(versionNumber)), 1)\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _hoisted_3,\n _createElementVNode(\"div\", _hoisted_4, [\n _createElementVNode(\"span\", {\n onClick: openDiscord,\n class: \"material-icons\"\n }, \"discord\"),\n _createElementVNode(\"ul\", _hoisted_5, [\n (_unref(discordLink) !== 'https://discord.gg/WzejVAx')\n ? (_openBlock(), _createElementBlock(\"li\", _hoisted_6, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n target: \"_blank\"\n }, _toDisplayString(_unref(discordName)), 9, _hoisted_7)\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_8,\n _hoisted_9\n ])\n ]),\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", _hoisted_10, [\n _createVNode(Tooltip, {\n display: \"Forums\",\n direction: _unref(Direction).Down,\n yoffset: \"5px\"\n }, {\n default: _withCtx(() => [\n _hoisted_11\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[1] || (_cache[1] = ($event: any) => (info.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Info\",\n direction: _unref(Direction).Down,\n class: \"info\"\n }, {\n default: _withCtx(() => [\n _hoisted_12\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[2] || (_cache[2] = ($event: any) => (savesManager.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Saves\",\n direction: _unref(Direction).Down,\n xoffset: \"-20px\"\n }, {\n default: _withCtx(() => [\n _hoisted_13\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[3] || (_cache[3] = ($event: any) => (options.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Options\",\n direction: _unref(Direction).Down,\n xoffset: \"-66px\"\n }, {\n default: _withCtx(() => [\n _hoisted_14\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ], 16))\n : (_openBlock(), _createElementBlock(\"div\", _mergeProps({\n key: 1,\n class: \"overlay-nav\"\n }, _ctx.$attrs), [\n _createElementVNode(\"div\", {\n onClick: _cache[4] || (_cache[4] = ($event: any) => (changelog.value?.open())),\n class: \"version-container\"\n }, [\n _createVNode(Tooltip, {\n display: \"Changelog\",\n direction: _unref(Direction).Right,\n xoffset: \"25%\",\n class: \"version\"\n }, {\n default: _withCtx(() => [\n _createElementVNode(\"span\", null, \"v\" + _toDisplayString(_unref(versionNumber)), 1)\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[5] || (_cache[5] = ($event: any) => (savesManager.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Saves\",\n direction: _unref(Direction).Right\n }, {\n default: _withCtx(() => [\n _hoisted_15\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[6] || (_cache[6] = ($event: any) => (options.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Options\",\n direction: _unref(Direction).Right\n }, {\n default: _withCtx(() => [\n _hoisted_16\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", {\n onClick: _cache[7] || (_cache[7] = ($event: any) => (info.value?.open()))\n }, [\n _createVNode(Tooltip, {\n display: \"Info\",\n direction: _unref(Direction).Right\n }, {\n default: _withCtx(() => [\n _hoisted_17\n ]),\n _: 1\n }, 8, [\"direction\"])\n ]),\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", _hoisted_18, [\n _createVNode(Tooltip, {\n display: \"Forums\",\n direction: _unref(Direction).Right,\n xoffset: \"7px\"\n }, {\n default: _withCtx(() => [\n _hoisted_19\n ]),\n _: 1\n }, 8, [\"direction\"])\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_20, [\n _createElementVNode(\"span\", {\n onClick: openDiscord,\n class: \"material-icons\"\n }, \"discord\"),\n _createElementVNode(\"ul\", _hoisted_21, [\n (_unref(discordLink) !== 'https://discord.gg/WzejVAx')\n ? (_openBlock(), _createElementBlock(\"li\", _hoisted_22, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n target: \"_blank\"\n }, _toDisplayString(_unref(discordName)), 9, _hoisted_23)\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_24,\n _hoisted_25\n ])\n ])\n ], 16)),\n _createVNode(Info, {\n ref_key: \"info\",\n ref: info,\n changelog: changelog.value\n }, null, 8, [\"changelog\"]),\n _createVNode(SavesManager, {\n ref_key: \"savesManager\",\n ref: savesManager\n }, null, 512),\n _createVNode(Options, {\n ref_key: \"options\",\n ref: options\n }, null, 512),\n _createVNode(Changelog, {\n ref_key: \"changelog\",\n ref: changelog\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./Nav.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Nav.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Nav.vue?vue&type=style&index=0&id=53a1a91d&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-53a1a91d\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, mergeProps as _mergeProps, resolveDynamicComponent as _resolveDynamicComponent, createElementVNode as _createElementVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-7e494d3c\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"inner-tab\" }\n\nimport projInfo from \"data/projInfo.json\";\nimport { GenericLayer, layers } from \"game/layers\";\nimport player from \"game/player\";\nimport { computed, toRef, unref } from \"vue\";\nimport Layer from \"./Layer.vue\";\nimport Nav from \"./Nav.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst tabs = toRef(player, \"tabs\");\nconst layerKeys = computed(() => Object.keys(layers));\nconst useHeader = projInfo.useHeader;\n\nfunction gatherLayerProps(layer: GenericLayer) {\n const { display, minimized, minWidth, name, color, minimizable, nodes } = layer;\n return { display, minimized, minWidth, name, color, minimizable, nodes };\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"tabs-container\", { useHeader: _unref(useHeader) }])\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_unref(tabs), (tab, index) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n key: index,\n class: _normalizeClass([\"tab\", unref(_unref(layers)[tab]?.classes)]),\n ref_for: true,\n ref: `tab-${index}`,\n style: _normalizeStyle(unref(_unref(layers)[tab]?.style))\n }, [\n (index === 0 && !_unref(useHeader))\n ? (_openBlock(), _createBlock(Nav, { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_1, [\n (_unref(layerKeys).includes(tab))\n ? (_openBlock(), _createBlock(Layer, _mergeProps({ key: 0 }, gatherLayerProps(_unref(layers)[tab]!), {\n index: index,\n tab: () => ((_ctx.$refs[`tab-${index}`] as HTMLElement[] | undefined)?.[0])\n }), null, 16, [\"index\", \"tab\"]))\n : (_openBlock(), _createBlock(_resolveDynamicComponent(tab), {\n key: 1,\n index: index\n }, null, 8, [\"index\"]))\n ])\n ], 6))\n }), 128))\n ], 2))\n}\n}\n\n})","import script from \"./Game.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Game.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Game.vue?vue&type=style&index=0&id=7e494d3c&scoped=true&lang=css\"\nimport \"./Game.vue?vue&type=style&index=1&id=7e494d3c&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-7e494d3c\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createElementVNode as _createElementVNode, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, isRef as _isRef, createVNode as _createVNode, withCtx as _withCtx, createBlock as _createBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-06188cc8\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"game-over-modal-header\" }\nconst _hoisted_2 = [\"src\", \"alt\"]\nconst _hoisted_3 = { class: \"game-over-modal-title\" }\nconst _hoisted_4 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"h2\", null, \"Congratulations!\", -1))\nconst _hoisted_5 = { key: 0 }\nconst _hoisted_6 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_7 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", null, \" Please check the Discord to discuss the game or to check for new content updates! \", -1))\nconst _hoisted_8 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_9 = [\"href\"]\nconst _hoisted_10 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons game-over-modal-discord\" }, \"discord\", -1))\n\nimport Modal from \"components/Modal.vue\";\nimport { hasWon } from \"data/projEntry\";\nimport projInfo from \"data/projInfo.json\";\nimport player from \"game/player\";\nimport { formatTime } from \"util/bignum\";\nimport { loadSave, newSave } from \"util/save\";\nimport { computed, toRef } from \"vue\";\nimport Toggle from \"./fields/Toggle.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst { title, logo, discordName, discordLink, versionNumber, versionTitle } = projInfo;\n\nconst timePlayed = computed(() => formatTime(player.timePlayed));\nconst isOpen = computed(() => hasWon.value && !player.keepGoing);\nconst autosave = toRef(player, \"autosave\");\n\nfunction keepGoing() {\n player.keepGoing = true;\n}\n\nfunction playAgain() {\n loadSave(newSave());\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(Modal, { \"model-value\": _unref(isOpen) }, {\n header: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_1, [\n (_unref(logo))\n ? (_openBlock(), _createElementBlock(\"img\", {\n key: 0,\n class: \"game-over-modal-logo\",\n src: _unref(logo),\n alt: _unref(title)\n }, null, 8, _hoisted_2))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_3, [\n _hoisted_4,\n _createElementVNode(\"h4\", null, \"You've beaten \" + _toDisplayString(_unref(title)) + \" v\" + _toDisplayString(_unref(versionNumber)) + \": \" + _toDisplayString(_unref(versionTitle)), 1)\n ])\n ])\n ]),\n body: _withCtx(({ shown }) => [\n shown\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_5, [\n _createElementVNode(\"div\", null, \"It took you \" + _toDisplayString(_unref(timePlayed)) + \" to beat the game.\", 1),\n _hoisted_6,\n _hoisted_7,\n _hoisted_8,\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n class: \"game-over-modal-discord-link\"\n }, [\n _hoisted_10,\n _createTextVNode(\" \" + _toDisplayString(_unref(discordName)), 1)\n ], 8, _hoisted_9)\n ]),\n _createVNode(Toggle, {\n title: \"Autosave\",\n modelValue: _unref(autosave),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(autosave) ? (autosave).value = $event : null))\n }, null, 8, [\"modelValue\"])\n ]))\n : _createCommentVNode(\"\", true)\n ]),\n footer: _withCtx(() => [\n _createElementVNode(\"div\", { class: \"game-over-footer\" }, [\n _createElementVNode(\"button\", {\n onClick: keepGoing,\n class: \"button\"\n }, \"Keep Going\"),\n _createElementVNode(\"button\", {\n onClick: playAgain,\n class: \"button danger\"\n }, \"Play Again\")\n ])\n ]),\n _: 1\n }, 8, [\"model-value\"]))\n}\n}\n\n})","import script from \"./GameOverScreen.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./GameOverScreen.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./GameOverScreen.vue?vue&type=style&index=0&id=06188cc8&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-06188cc8\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, createElementVNode as _createElementVNode, toDisplayString as _toDisplayString, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createTextVNode as _createTextVNode, isRef as _isRef, createVNode as _createVNode, createBlock as _createBlock, mergeProps as _mergeProps, withCtx as _withCtx, Fragment as _Fragment, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5935214c\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"div\", { class: \"nan-modal-header\" }, [\n /*#__PURE__*/_createElementVNode(\"h2\", null, \"NaN value detected!\")\n], -1))\nconst _hoisted_2 = { key: 0 }\nconst _hoisted_3 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_4 = [\"href\"]\nconst _hoisted_5 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"material-icons nan-modal-discord\" }, \"discord\", -1))\nconst _hoisted_6 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"br\", null, null, -1))\nconst _hoisted_7 = { class: \"nan-footer\" }\n\nimport Modal from \"components/Modal.vue\";\nimport projInfo from \"data/projInfo.json\";\nimport player from \"game/player\";\nimport state from \"game/state\";\nimport Decimal, { DecimalSource, format } from \"util/bignum\";\nimport { ComponentPublicInstance, computed, ref, toRef } from \"vue\";\nimport Toggle from \"./fields/Toggle.vue\";\nimport SavesManager from \"./SavesManager.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst { discordName, discordLink } = projInfo;\nconst autosave = toRef(player, \"autosave\");\nconst hasNaN = toRef(state, \"hasNaN\");\nconst savesManager = ref<ComponentPublicInstance<typeof SavesManager> | null>(null);\n\nconst path = computed(() => state.NaNPath?.join(\".\"));\nconst property = computed(() => state.NaNPath?.slice(-1)[0]);\nconst previous = computed<DecimalSource | null>(() => {\n if (state.NaNReceiver && property.value) {\n return state.NaNReceiver[property.value] as DecimalSource;\n }\n return null;\n});\nconst isPaused = computed({\n get() {\n return player.devSpeed === 0;\n },\n set(value: boolean) {\n player.devSpeed = value ? null : 0;\n }\n});\n\nfunction setZero() {\n if (state.NaNReceiver && property.value) {\n state.NaNReceiver[property.value] = new Decimal(0);\n state.hasNaN = false;\n }\n}\n\nfunction setOne() {\n if (state.NaNReceiver && property.value) {\n state.NaNReceiver[property.value] = new Decimal(1);\n state.hasNaN = false;\n }\n}\n\nfunction ignore() {\n if (state.NaNReceiver && property.value) {\n state.NaNReceiver[property.value] = new Decimal(NaN);\n state.hasNaN = false;\n }\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n _createVNode(Modal, _mergeProps({\n modelValue: _unref(hasNaN),\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = ($event: any) => (_isRef(hasNaN) ? (hasNaN).value = $event : null))\n }, _ctx.$attrs), {\n header: _withCtx(() => [\n _hoisted_1\n ]),\n body: _withCtx(() => [\n _createElementVNode(\"div\", null, [\n _createTextVNode(\" Attempted to assign \\\"\" + _toDisplayString(_unref(path)) + \"\\\" to NaN\", 1),\n (_unref(previous))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, _toDisplayString(\" \") + \"(previously \" + _toDisplayString(_unref(format)(_unref(previous))) + \")\", 1))\n : _createCommentVNode(\"\", true),\n _createTextVNode(\". Auto-saving has been \" + _toDisplayString(_unref(autosave) ? \"enabled\" : \"disabled\") + \". Check the console for more details, and consider sharing it with the developers on discord. \", 1)\n ]),\n _hoisted_3,\n _createElementVNode(\"div\", null, [\n _createElementVNode(\"a\", {\n href: _unref(discordLink),\n class: \"nan-modal-discord-link\"\n }, [\n _hoisted_5,\n _createTextVNode(\" \" + _toDisplayString(_unref(discordName)), 1)\n ], 8, _hoisted_4)\n ]),\n _hoisted_6,\n _createVNode(Toggle, {\n title: \"Autosave\",\n modelValue: _unref(autosave),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(autosave) ? (autosave).value = $event : null))\n }, null, 8, [\"modelValue\"]),\n (_unref(projInfo).enablePausing)\n ? (_openBlock(), _createBlock(Toggle, {\n key: 0,\n title: \"Pause game\",\n modelValue: _unref(isPaused),\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => (_isRef(isPaused) ? (isPaused).value = $event : null))\n }, null, 8, [\"modelValue\"]))\n : _createCommentVNode(\"\", true)\n ]),\n footer: _withCtx(() => [\n _createElementVNode(\"div\", _hoisted_7, [\n _createElementVNode(\"button\", {\n onClick: _cache[2] || (_cache[2] = ($event: any) => (savesManager.value?.open())),\n class: \"button\"\n }, \"Open Saves Manager\"),\n _createElementVNode(\"button\", {\n onClick: setZero,\n class: \"button\"\n }, \"Set to 0\"),\n _createElementVNode(\"button\", {\n onClick: setOne,\n class: \"button\"\n }, \"Set to 1\"),\n (_unref(previous) && _unref(Decimal).neq(_unref(previous), 0) && _unref(Decimal).neq(_unref(previous), 1))\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n onClick: _cache[3] || (_cache[3] = ($event: any) => (hasNaN.value = false)),\n class: \"button\"\n }, \" Set to previous \"))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"button\", {\n onClick: ignore,\n class: \"button danger\"\n }, \"Ignore\")\n ])\n ]),\n _: 1\n }, 16, [\"modelValue\"]),\n _createVNode(SavesManager, {\n ref_key: \"savesManager\",\n ref: savesManager\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./NaNScreen.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./NaNScreen.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./NaNScreen.vue?vue&type=style&index=0&id=5935214c&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-5935214c\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, toDisplayString as _toDisplayString, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, Transition as _Transition, withCtx as _withCtx, createVNode as _createVNode, createTextVNode as _createTextVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-c0663118\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = {\n key: 0,\n class: \"tpsDisplay\"\n}\nconst _hoisted_2 = {\n key: 0,\n class: \"low\"\n}\n\nimport state from \"game/state\";\nimport Decimal, { DecimalSource, formatWhole } from \"util/bignum\";\nimport { computed, ref, watchEffect } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst tps = computed(() =>\n Decimal.div(\n state.lastTenTicks.length,\n state.lastTenTicks.reduce((acc, curr) => acc + curr, 0)\n )\n);\n\nconst lastTenFPS = ref<number[]>([]);\nwatchEffect(() => {\n lastTenFPS.value.push(Math.round(tps.value.toNumber()));\n if (lastTenFPS.value.length > 10) {\n lastTenFPS.value = lastTenFPS.value.slice(1);\n }\n});\n\nconst low = computed(() =>\n lastTenFPS.value.reduce<DecimalSource>((acc, curr) => Decimal.max(acc, curr), 0)\n);\n\nconst showLow = computed(() => Decimal.sub(tps.value, low.value).gt(1));\n\nreturn (_ctx: any,_cache: any) => {\n return (!_unref(tps).isNan())\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createTextVNode(\" TPS: \" + _toDisplayString(_unref(formatWhole)(_unref(tps))) + \" \", 1),\n _createVNode(_Transition, { name: \"fade\" }, {\n default: _withCtx(() => [\n (_unref(showLow))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, _toDisplayString(_unref(formatWhole)(_unref(low))), 1))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n })\n ]))\n : _createCommentVNode(\"\", true)\n}\n}\n\n})","import script from \"./TPS.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./TPS.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./TPS.vue?vue&type=style&index=0&id=c0663118&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-c0663118\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, normalizeClass as _normalizeClass, Fragment as _Fragment, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { jsx } from \"features/feature\";\nimport { coerceComponent, render } from \"util/vue\";\nimport { computed, toRef, unref } from \"vue\";\nimport Game from \"./components/Game.vue\";\nimport GameOverScreen from \"./components/GameOverScreen.vue\";\nimport NaNScreen from \"./components/NaNScreen.vue\";\nimport Nav from \"./components/Nav.vue\";\nimport TPS from \"./components/TPS.vue\";\nimport projInfo from \"./data/projInfo.json\";\nimport themes from \"./data/themes\";\nimport settings, { gameComponents } from \"./game/settings\";\nimport \"./main.css\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst useHeader = projInfo.useHeader;\nconst theme = computed(() => themes[settings.theme].variables);\nconst showTPS = toRef(settings, \"showTPS\");\n\nconst gameComponent = computed(() => {\n return coerceComponent(jsx(() => <>{gameComponents.map(render)}</>));\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n _createElementVNode(\"div\", {\n id: \"modal-root\",\n style: _normalizeStyle(_unref(theme))\n }, null, 4),\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"app\", { useHeader: _unref(useHeader) }]),\n style: _normalizeStyle(_unref(theme))\n }, [\n (_unref(useHeader))\n ? (_openBlock(), _createBlock(Nav, { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(Game),\n (unref(_unref(showTPS)))\n ? (_openBlock(), _createBlock(TPS, { key: 1 }))\n : _createCommentVNode(\"\", true),\n _createVNode(GameOverScreen),\n _createVNode(NaNScreen),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(gameComponent))))\n ], 6)\n ], 64))\n}\n}\n\n})","import script from \"./App.vue?vue&type=script&setup=true&lang=tsx\"\nexport * from \"./App.vue?vue&type=script&setup=true&lang=tsx\"\n\nimport \"./App.vue?vue&type=style&index=0&id=f13f28b6&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-f13f28b6\"]])\n\nexport default __exports__","import { App as VueApp, createApp } from \"vue\";\nimport App from \"./App.vue\";\nimport projInfo from \"./data/projInfo.json\";\nimport { GenericLayer } from \"./game/layers\";\nimport { PlayerData } from \"./game/player\";\nimport { Settings } from \"./game/settings\";\nimport { Transient } from \"./game/state\";\nimport Decimal, { DecimalSource } from \"./util/bignum\";\nimport { load } from \"./util/save\";\n\ndocument.title = projInfo.title;\nif (projInfo.id === \"\") {\n throw \"Project ID is empty! Please select a unique ID for this project in /src/data/projInfo.json\";\n}\n\ndeclare global {\n interface Window {\n vue: VueApp;\n save: VoidFunction;\n hardReset: VoidFunction;\n hardResetSettings: VoidFunction;\n layers: Record<string, Readonly<GenericLayer> | undefined>;\n player: PlayerData;\n state: Transient;\n settings: Settings;\n Decimal: typeof Decimal;\n exponentialFormat: (num: DecimalSource, precision: number, mantissa: boolean) => string;\n commaFormat: (num: DecimalSource, precision: number) => string;\n regularFormat: (num: DecimalSource, precision: number) => string;\n format: (num: DecimalSource, precision?: number, small?: boolean) => string;\n formatWhole: (num: DecimalSource) => string;\n formatTime: (s: number) => string;\n toPlaces: (x: DecimalSource, precision: number, maxAccepted: DecimalSource) => string;\n formatSmall: (x: DecimalSource, precision?: number) => string;\n invertOOM: (x: DecimalSource) => Decimal;\n projInfo: typeof projInfo;\n }\n}\n\nrequestAnimationFrame(async () => {\n console.log(\n \"%cMade in Profectus%c\\nLearn more at www.moddingtree.com\",\n \"font-weight: bold; font-size: 24px; color: #A3BE8C; background: #2E3440; padding: 4px 8px; border-radius: 8px;\",\n \"padding: 4px;\"\n );\n await load();\n const { globalBus, startGameLoop } = await require(\"./game/events\");\n\n // Create Vue\n const vue = (window.vue = createApp(App));\n globalBus.emit(\"setupVue\", vue);\n vue.mount(\"#app\");\n\n startGameLoop();\n});\n\nwindow.projInfo = projInfo;\n","/* eslint-disable @typescript-eslint/no-this-alias */\nexport type CompareResult = -1 | 0 | 1;\n\nconst MAX_SIGNIFICANT_DIGITS = 17; //Maximum number of digits of precision to assume in Number\n\nconst EXP_LIMIT = 9e15; //If we're ABOVE this value, increase a layer. (9e15 is close to the largest integer that can fit in a Number.)\n\nconst LAYER_DOWN: number = Math.log10(9e15);\n\nconst FIRST_NEG_LAYER = 1 / 9e15; //At layer 0, smaller non-zero numbers than this become layer 1 numbers with negative mag. After that the pattern continues as normal.\n\nconst NUMBER_EXP_MAX = 308; //The largest exponent that can appear in a Number, though not all mantissas are valid here.\n\nconst NUMBER_EXP_MIN = -324; //The smallest exponent that can appear in a Number, though not all mantissas are valid here.\n\nconst MAX_ES_IN_A_ROW = 5; //For default toString behaviour, when to swap from eee... to (e^n) syntax.\n\nconst IGNORE_COMMAS = true;\nconst COMMAS_ARE_DECIMAL_POINTS = false;\n\nconst powerOf10 = (function() {\n // We need this lookup table because Math.pow(10, exponent)\n // when exponent's absolute value is large is slightly inaccurate.\n // You can fix it with the power of math... or just make a lookup table.\n // Faster AND simpler\n const powersOf10: number[] = [];\n\n for (let i = NUMBER_EXP_MIN + 1; i <= NUMBER_EXP_MAX; i++) {\n powersOf10.push(Number(\"1e\" + i));\n }\n\n const indexOf0InPowersOf10 = 323;\n return function(power: number) {\n return powersOf10[power + indexOf0InPowersOf10];\n };\n})();\n\n//tetration/slog to real height stuff\n//background info and tables of values for critical functions taken here: https://github.com/Patashu/break_eternity.js/issues/22\nconst critical_headers = [2, Math.E, 3, 4, 5, 6, 7, 8, 9, 10];\nconst critical_tetr_values = [\n [\n // Base 2\n 1,\n 1.0891168053867777,\n 1.1789745164521264,\n 1.2701428397304229,\n 1.3632066654400328,\n 1.4587804913784246,\n 1.557523817412741,\n 1.660158301473385,\n 1.767487542936873,\n 1.8804205225512542,\n 2\n ],\n [\n // Base E\n 1, //0.0\n 1.1121114330934, //0.1\n 1.23103892493161, //0.2\n 1.35838369631113, //0.3\n 1.49605193039935, //0.4\n 1.64635423375119, //0.5\n 1.81213853570186, //0.6\n 1.99697132461829, //0.7\n 2.20538955455724, //0.8\n 2.44325744833852, //0.9\n Math.E //1.0\n ],\n [\n // Base 3\n 1,\n 1.1187738849693603,\n 1.2464963939368214,\n 1.38527004705667,\n 1.5376664685821402,\n 1.7068895236551784,\n 1.897001227148399,\n 2.1132403089001035,\n 2.362480153784171,\n 2.6539010333870774,\n 3\n ],\n [\n // Base 4\n 1,\n 1.1367350847096405,\n 1.2889510672956703,\n 1.4606478703324786,\n 1.6570295196661111,\n 1.8850062585672889,\n 2.1539465047453485,\n 2.476829779693097,\n 2.872061932789197,\n 3.3664204535587183,\n 4\n ],\n [\n // Base 5\n 1,\n 1.1494592900767588,\n 1.319708228183931,\n 1.5166291280087583,\n 1.748171114438024,\n 2.0253263297298045,\n 2.3636668498288547,\n 2.7858359149579424,\n 3.3257226212448145,\n 4.035730287722532,\n 5\n ],\n [\n // Base 6\n 1,\n 1.159225940787673,\n 1.343712473580932,\n 1.5611293155111927,\n 1.8221199554561318,\n 2.14183924486326,\n 2.542468319282638,\n 3.0574682501653316,\n 3.7390572020926873,\n 4.6719550537360774,\n 6\n ],\n [\n // Base 7\n 1,\n 1.1670905356972596,\n 1.3632807444991446,\n 1.5979222279405536,\n 1.8842640123816674,\n 2.2416069644878687,\n 2.69893426559423,\n 3.3012632110403577,\n 4.121250340630164,\n 5.281493033448316,\n 7\n ],\n [\n // Base 8\n 1,\n 1.1736630594087796,\n 1.379783782386201,\n 1.6292821855668218,\n 1.9378971836180754,\n 2.3289975651071977,\n 2.8384347394720835,\n 3.5232708454565906,\n 4.478242031114584,\n 5.868592169644505,\n 8\n ],\n [\n // Base 9\n 1,\n 1.1793017514670474,\n 1.394054150657457,\n 1.65664127441059,\n 1.985170999970283,\n 2.4069682290577457,\n 2.9647310119960752,\n 3.7278665320924946,\n 4.814462547283592,\n 6.436522247411611,\n 9\n ],\n [\n // Base 10\n 1,\n 1.18422737399915,\n 1.4066113788546144,\n 1.680911177655277,\n 2.027492094355525,\n 2.4775152854601967,\n 3.080455730250329,\n 3.918234505962507,\n 5.1332705696484595,\n 6.9878696918072905,\n 10\n ]\n];\nconst critical_slog_values = [\n [\n // Base 2\n -1,\n -0.9194161097107025,\n -0.8335625019330468,\n -0.7425599821143978,\n -0.6466611521029437,\n -0.5462617907227869,\n -0.4419033816638769,\n -0.3342645487554494,\n -0.224140440909962,\n -0.11241087890006762,\n 0\n ],\n [\n // Base E\n -1, //0.0\n -0.90603157029014, //0.1\n -0.80786507256596, //0.2\n -0.7064666939634, //0.3\n -0.60294836853664, //0.4\n -0.49849837513117, //0.5\n -0.39430303318768, //0.6\n -0.29147201034755, //0.7\n -0.19097820800866, //0.8\n -0.09361896280296, //0.9\n 0 //1.0\n ],\n [\n // Base 3\n -1,\n -0.9021579584316141,\n -0.8005762598234203,\n -0.6964780623319391,\n -0.5911906810998454,\n -0.486050182576545,\n -0.3823089430815083,\n -0.28106046722897615,\n -0.1831906535795894,\n -0.08935809204418144,\n 0\n ],\n [\n // Base 4\n -1,\n -0.8917227442365535,\n -0.781258746326964,\n -0.6705130326902455,\n -0.5612813129406509,\n -0.4551067709033134,\n -0.35319256652135966,\n -0.2563741554088552,\n -0.1651412821106526,\n -0.0796919581982668,\n 0\n ],\n [\n // Base 5\n -1,\n -0.8843387974366064,\n -0.7678744063886243,\n -0.6529563724510552,\n -0.5415870994657841,\n -0.4352842206588936,\n -0.33504449124791424,\n -0.24138853420685147,\n -0.15445285440944467,\n -0.07409659641336663,\n 0\n ],\n [\n // Base 6\n -1,\n -0.8786709358426346,\n -0.7577735191184886,\n -0.6399546189952064,\n -0.527284921869926,\n -0.4211627631006314,\n -0.3223479611761232,\n -0.23107655627789858,\n -0.1472057700818259,\n -0.07035171210706326,\n 0\n ],\n [\n // Base 7\n -1,\n -0.8740862815291583,\n -0.7497032990976209,\n -0.6297119746181752,\n -0.5161838335958787,\n -0.41036238255751956,\n -0.31277212146489963,\n -0.2233976621705518,\n -0.1418697367979619,\n -0.06762117662323441,\n 0\n ],\n [\n // Base 8\n -1,\n -0.8702632331800649,\n -0.7430366914122081,\n -0.6213373075161548,\n -0.5072025698095242,\n -0.40171437727184167,\n -0.30517930701410456,\n -0.21736343968190863,\n -0.137710238299109,\n -0.06550774483471955,\n 0\n ],\n [\n // Base 9\n -1,\n -0.8670016295947213,\n -0.7373984232432306,\n -0.6143173985094293,\n -0.49973884395492807,\n -0.394584953527678,\n -0.2989649949848695,\n -0.21245647317021688,\n -0.13434688362382652,\n -0.0638072667348083,\n 0\n ],\n [\n // Base 10\n -1,\n -0.8641642839543857,\n -0.732534623168535,\n -0.6083127477059322,\n -0.4934049257184696,\n -0.3885773075899922,\n -0.29376029055315767,\n -0.2083678561173622,\n -0.13155653399373268,\n -0.062401588652553186,\n 0\n ]\n];\n\nconst D = function D(value: DecimalSource): Decimal {\n return Decimal.fromValue_noAlloc(value);\n};\n\nconst FC = function(sign: number, layer: number, mag: number) {\n return Decimal.fromComponents(sign, layer, mag);\n};\n\nconst FC_NN = function FC_NN(sign: number, layer: number, mag: number) {\n return Decimal.fromComponents_noNormalize(sign, layer, mag);\n};\n\nconst ME = function ME(mantissa: number, exponent: number) {\n return Decimal.fromMantissaExponent(mantissa, exponent);\n};\n\nconst ME_NN = function ME_NN(mantissa: number, exponent: number) {\n return Decimal.fromMantissaExponent_noNormalize(mantissa, exponent);\n};\n\nconst decimalPlaces = function decimalPlaces(value: number, places: number): number {\n const len = places + 1;\n const numDigits = Math.ceil(Math.log10(Math.abs(value)));\n const rounded =\n Math.round(value * Math.pow(10, len - numDigits)) * Math.pow(10, numDigits - len);\n return parseFloat(rounded.toFixed(Math.max(len - numDigits, 0)));\n};\n\nconst f_maglog10 = function(n: number) {\n return Math.sign(n) * Math.log10(Math.abs(n));\n};\n\n//from HyperCalc source code\nconst f_gamma = function(n: number) {\n if (!isFinite(n)) {\n return n;\n }\n if (n < -50) {\n if (n === Math.trunc(n)) {\n return Number.NEGATIVE_INFINITY;\n }\n return 0;\n }\n\n let scal1 = 1;\n while (n < 10) {\n scal1 = scal1 * n;\n ++n;\n }\n\n n -= 1;\n let l = 0.9189385332046727; //0.5*Math.log(2*Math.PI)\n l = l + (n + 0.5) * Math.log(n);\n l = l - n;\n const n2 = n * n;\n let np = n;\n l = l + 1 / (12 * np);\n np = np * n2;\n l = l + 1 / (360 * np);\n np = np * n2;\n l = l + 1 / (1260 * np);\n np = np * n2;\n l = l + 1 / (1680 * np);\n np = np * n2;\n l = l + 1 / (1188 * np);\n np = np * n2;\n l = l + 691 / (360360 * np);\n np = np * n2;\n l = l + 7 / (1092 * np);\n np = np * n2;\n l = l + 3617 / (122400 * np);\n\n return Math.exp(l) / scal1;\n};\n\nconst _twopi = 6.2831853071795864769252842; // 2*pi\nconst _EXPN1 = 0.36787944117144232159553; // exp(-1)\nconst OMEGA = 0.56714329040978387299997; // W(1, 0)\n//from https://math.stackexchange.com/a/465183\n// The evaluation can become inaccurate very close to the branch point\nconst f_lambertw = function(z: number, tol = 1e-10): number {\n let w;\n let wn;\n\n if (!Number.isFinite(z)) {\n return z;\n }\n if (z === 0) {\n return z;\n }\n if (z === 1) {\n return OMEGA;\n }\n\n if (z < 10) {\n w = 0;\n } else {\n w = Math.log(z) - Math.log(Math.log(z));\n }\n\n for (let i = 0; i < 100; ++i) {\n wn = (z * Math.exp(-w) + w * w) / (w + 1);\n if (Math.abs(wn - w) < tol * Math.abs(wn)) {\n return wn;\n } else {\n w = wn;\n }\n }\n\n throw Error(`Iteration failed to converge: ${z.toString()}`);\n //return Number.NaN;\n};\n\n//from https://github.com/scipy/scipy/blob/8dba340293fe20e62e173bdf2c10ae208286692f/scipy/special/lambertw.pxd\n// The evaluation can become inaccurate very close to the branch point\n// at ``-1/e``. In some corner cases, `lambertw` might currently\n// fail to converge, or can end up on the wrong branch.\nfunction d_lambertw(z: Decimal, tol = 1e-10): Decimal {\n let w;\n let ew, wew, wewz, wn;\n\n if (!Number.isFinite(z.mag)) {\n return z;\n }\n if (z === Decimal.dZero) {\n return z;\n }\n if (z === Decimal.dOne) {\n //Split out this case because the asymptotic series blows up\n return D(OMEGA);\n }\n\n const absz = Decimal.abs(z);\n //Get an initial guess for Halley's method\n w = Decimal.ln(z);\n\n //Halley's method; see 5.9 in [1]\n\n for (let i = 0; i < 100; ++i) {\n ew = Decimal.exp(-w);\n wewz = w.sub(z.mul(ew));\n wn = w.sub(\n wewz.div(\n w.add(1).sub(\n w\n .add(2)\n .mul(wewz)\n .div(Decimal.mul(2, w).add(2))\n )\n )\n );\n if (Decimal.abs(wn.sub(w)).lt(Decimal.abs(wn).mul(tol))) {\n return wn;\n } else {\n w = wn;\n }\n }\n\n throw Error(`Iteration failed to converge: ${z.toString()}`);\n //return Decimal.dNaN;\n}\n\nexport type DecimalSource = Decimal | number | string;\n\n/**\n * The Decimal's value is simply mantissa * 10^exponent.\n */\nexport default class Decimal {\n public static readonly dZero = FC_NN(0, 0, 0);\n public static readonly dOne = FC_NN(1, 0, 1);\n public static readonly dNegOne = FC_NN(-1, 0, 1);\n public static readonly dTwo = FC_NN(1, 0, 2);\n public static readonly dTen = FC_NN(1, 0, 10);\n public static readonly dNaN = FC_NN(Number.NaN, Number.NaN, Number.NaN);\n public static readonly dInf = FC_NN(1, Number.POSITIVE_INFINITY, Number.POSITIVE_INFINITY);\n public static readonly dNegInf = FC_NN(-1, Number.NEGATIVE_INFINITY, Number.NEGATIVE_INFINITY);\n public static readonly dNumberMax = FC(1, 0, Number.MAX_VALUE);\n public static readonly dNumberMin = FC(1, 0, Number.MIN_VALUE);\n\n public sign: number = Number.NaN;\n public mag: number = Number.NaN;\n public layer: number = Number.NaN;\n\n constructor(value?: DecimalSource) {\n if (value instanceof Decimal || (value != null && typeof value === \"object\" && \"sign\" in value && \"mag\" in value && \"layer\" in value)) {\n this.fromDecimal(value);\n } else if (typeof value === \"number\") {\n this.fromNumber(value);\n } else if (typeof value === \"string\") {\n this.fromString(value);\n } else {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n }\n }\n\n get m(): number {\n if (this.sign === 0) {\n return 0;\n } else if (this.layer === 0) {\n const exp = Math.floor(Math.log10(this.mag));\n //handle special case 5e-324\n let man;\n if (this.mag === 5e-324) {\n man = 5;\n } else {\n man = this.mag / powerOf10(exp);\n }\n return this.sign * man;\n } else if (this.layer === 1) {\n const residue = this.mag - Math.floor(this.mag);\n return this.sign * Math.pow(10, residue);\n } else {\n //mantissa stops being relevant past 1e9e15 / ee15.954\n return this.sign;\n }\n }\n\n set m(value: number) {\n if (this.layer <= 2) {\n this.fromMantissaExponent(value, this.e);\n } else {\n //don't even pretend mantissa is meaningful\n this.sign = Math.sign(value);\n if (this.sign === 0) {\n this.layer === 0;\n this.exponent === 0;\n }\n }\n }\n\n get e(): number {\n if (this.sign === 0) {\n return 0;\n } else if (this.layer === 0) {\n return Math.floor(Math.log10(this.mag));\n } else if (this.layer === 1) {\n return Math.floor(this.mag);\n } else if (this.layer === 2) {\n return Math.floor(Math.sign(this.mag) * Math.pow(10, Math.abs(this.mag)));\n } else {\n return this.mag * Number.POSITIVE_INFINITY;\n }\n }\n set e(value: number) {\n this.fromMantissaExponent(this.m, value);\n }\n\n get s(): number {\n return this.sign;\n }\n set s(value: number) {\n if (value === 0) {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n } else {\n this.sign = value;\n }\n }\n\n // Object.defineProperty(Decimal.prototype, \"mantissa\", {\n get mantissa(): number {\n return this.m;\n }\n\n set mantissa(value: number) {\n this.m = value;\n }\n\n get exponent(): number {\n return this.e;\n }\n set exponent(value: number) {\n this.e = value;\n }\n\n public static fromComponents(sign: number, layer: number, mag: number): Decimal {\n return new Decimal().fromComponents(sign, layer, mag);\n }\n\n public static fromComponents_noNormalize(sign: number, layer: number, mag: number): Decimal {\n return new Decimal().fromComponents_noNormalize(sign, layer, mag);\n }\n\n public static fromMantissaExponent(mantissa: number, exponent: number): Decimal {\n return new Decimal().fromMantissaExponent(mantissa, exponent);\n }\n\n public static fromMantissaExponent_noNormalize(mantissa: number, exponent: number): Decimal {\n return new Decimal().fromMantissaExponent_noNormalize(mantissa, exponent);\n }\n\n public static fromDecimal(value: Decimal): Decimal {\n return new Decimal().fromDecimal(value);\n }\n\n public static fromNumber(value: number): Decimal {\n return new Decimal().fromNumber(value);\n }\n\n public static fromString(value: string): Decimal {\n return new Decimal().fromString(value);\n }\n\n public static fromValue(value: DecimalSource): Decimal {\n return new Decimal().fromValue(value);\n }\n\n public static fromValue_noAlloc(value: DecimalSource): Decimal {\n return value instanceof Decimal ? value : new Decimal(value);\n }\n\n public static abs(value: DecimalSource): Decimal {\n return D(value).abs();\n }\n\n public static neg(value: DecimalSource): Decimal {\n return D(value).neg();\n }\n\n public static negate(value: DecimalSource): Decimal {\n return D(value).neg();\n }\n\n public static negated(value: DecimalSource): Decimal {\n return D(value).neg();\n }\n\n public static sign(value: DecimalSource): number {\n return D(value).sign;\n }\n\n public static sgn(value: DecimalSource): number {\n return D(value).sign;\n }\n\n public static round(value: DecimalSource): Decimal {\n return D(value).round();\n }\n\n public static floor(value: DecimalSource): Decimal {\n return D(value).floor();\n }\n\n public static ceil(value: DecimalSource): Decimal {\n return D(value).ceil();\n }\n\n public static trunc(value: DecimalSource): Decimal {\n return D(value).trunc();\n }\n\n public static add(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).add(other);\n }\n\n public static plus(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).add(other);\n }\n\n public static sub(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).sub(other);\n }\n\n public static subtract(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).sub(other);\n }\n\n public static minus(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).sub(other);\n }\n\n public static mul(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).mul(other);\n }\n\n public static multiply(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).mul(other);\n }\n\n public static times(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).mul(other);\n }\n\n public static div(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).div(other);\n }\n\n public static divide(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).div(other);\n }\n\n public static recip(value: DecimalSource): Decimal {\n return D(value).recip();\n }\n\n public static reciprocal(value: DecimalSource): Decimal {\n return D(value).recip();\n }\n\n public static reciprocate(value: DecimalSource): Decimal {\n return D(value).reciprocate();\n }\n\n public static cmp(value: DecimalSource, other: DecimalSource): CompareResult {\n return D(value).cmp(other);\n }\n\n public static cmpabs(value: DecimalSource, other: DecimalSource): CompareResult {\n return D(value).cmpabs(other);\n }\n\n public static compare(value: DecimalSource, other: DecimalSource): CompareResult {\n return D(value).cmp(other);\n }\n\n public static isNaN(value: DecimalSource): boolean {\n value = D(value);\n return isNaN(value.sign) || isNaN(value.layer) || isNaN(value.mag);\n }\n\n public static isFinite(value: DecimalSource): boolean {\n value = D(value);\n return isFinite(value.sign) && isFinite(value.layer) && isFinite(value.mag);\n }\n\n public static eq(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).eq(other);\n }\n\n public static equals(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).eq(other);\n }\n\n public static neq(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).neq(other);\n }\n\n public static notEquals(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).notEquals(other);\n }\n\n public static lt(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).lt(other);\n }\n\n public static lte(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).lte(other);\n }\n\n public static gt(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).gt(other);\n }\n\n public static gte(value: DecimalSource, other: DecimalSource): boolean {\n return D(value).gte(other);\n }\n\n public static max(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).max(other);\n }\n\n public static min(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).min(other);\n }\n\n public static minabs(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).minabs(other);\n }\n\n public static maxabs(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).maxabs(other);\n }\n\n public static clamp(value: DecimalSource, min: DecimalSource, max: DecimalSource): Decimal {\n return D(value).clamp(min, max);\n }\n\n public static clampMin(value: DecimalSource, min: DecimalSource): Decimal {\n return D(value).clampMin(min);\n }\n\n public static clampMax(value: DecimalSource, max: DecimalSource): Decimal {\n return D(value).clampMax(max);\n }\n\n public static cmp_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): CompareResult {\n return D(value).cmp_tolerance(other, tolerance);\n }\n\n public static compare_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): CompareResult {\n return D(value).cmp_tolerance(other, tolerance);\n }\n\n public static eq_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).eq_tolerance(other, tolerance);\n }\n\n public static equals_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).eq_tolerance(other, tolerance);\n }\n\n public static neq_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).neq_tolerance(other, tolerance);\n }\n\n public static notEquals_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).notEquals_tolerance(other, tolerance);\n }\n\n public static lt_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).lt_tolerance(other, tolerance);\n }\n\n public static lte_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).lte_tolerance(other, tolerance);\n }\n\n public static gt_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).gt_tolerance(other, tolerance);\n }\n\n public static gte_tolerance(\n value: DecimalSource,\n other: DecimalSource,\n tolerance: number\n ): boolean {\n return D(value).gte_tolerance(other, tolerance);\n }\n\n public static pLog10(value: DecimalSource): Decimal {\n return D(value).pLog10();\n }\n\n public static absLog10(value: DecimalSource): Decimal {\n return D(value).absLog10();\n }\n\n public static log10(value: DecimalSource): Decimal {\n return D(value).log10();\n }\n\n public static log(value: DecimalSource, base: DecimalSource): Decimal {\n return D(value).log(base);\n }\n\n public static log2(value: DecimalSource): Decimal {\n return D(value).log2();\n }\n\n public static ln(value: DecimalSource): Decimal {\n return D(value).ln();\n }\n\n public static logarithm(value: DecimalSource, base: DecimalSource): Decimal {\n return D(value).logarithm(base);\n }\n\n public static pow(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).pow(other);\n }\n\n public static pow10(value: DecimalSource): Decimal {\n return D(value).pow10();\n }\n\n public static root(value: DecimalSource, other: DecimalSource): Decimal {\n return D(value).root(other);\n }\n\n public static factorial(value: DecimalSource, _other?: never): Decimal {\n return D(value).factorial();\n }\n\n public static gamma(value: DecimalSource, _other?: never): Decimal {\n return D(value).gamma();\n }\n\n public static lngamma(value: DecimalSource, _other?: never): Decimal {\n return D(value).lngamma();\n }\n\n public static exp(value: DecimalSource): Decimal {\n return D(value).exp();\n }\n\n public static sqr(value: DecimalSource): Decimal {\n return D(value).sqr();\n }\n\n public static sqrt(value: DecimalSource): Decimal {\n return D(value).sqrt();\n }\n\n public static cube(value: DecimalSource): Decimal {\n return D(value).cube();\n }\n\n public static cbrt(value: DecimalSource): Decimal {\n return D(value).cbrt();\n }\n\n public static tetrate(\n value: DecimalSource,\n height = 2,\n payload: DecimalSource = FC_NN(1, 0, 1)\n ): Decimal {\n return D(value).tetrate(height, payload);\n }\n\n public static iteratedexp(value: DecimalSource, height = 2, payload = FC_NN(1, 0, 1)): Decimal {\n return D(value).iteratedexp(height, payload);\n }\n\n public static iteratedlog(value: DecimalSource, base: DecimalSource = 10, times = 1): Decimal {\n return D(value).iteratedlog(base, times);\n }\n\n public static layeradd10(value: DecimalSource, diff: DecimalSource): Decimal {\n return D(value).layeradd10(diff);\n }\n\n public static layeradd(value: DecimalSource, diff: number, base = 10): Decimal {\n return D(value).layeradd(diff, base);\n }\n\n public static slog(value: DecimalSource, base = 10): Decimal {\n return D(value).slog(base);\n }\n\n public static lambertw(value: DecimalSource): Decimal {\n return D(value).lambertw();\n }\n\n public static ssqrt(value: DecimalSource): Decimal {\n return D(value).ssqrt();\n }\n\n public static pentate(\n value: DecimalSource,\n height = 2,\n payload: DecimalSource = FC_NN(1, 0, 1)\n ): Decimal {\n return D(value).pentate(height, payload);\n }\n\n /**\n * If you're willing to spend 'resourcesAvailable' and want to buy something\n * with exponentially increasing cost each purchase (start at priceStart,\n * multiply by priceRatio, already own currentOwned), how much of it can you buy?\n * Adapted from Trimps source code.\n */\n\n public static affordGeometricSeries(\n resourcesAvailable: DecimalSource,\n priceStart: DecimalSource,\n priceRatio: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.affordGeometricSeries_core(\n D(resourcesAvailable),\n D(priceStart),\n D(priceRatio),\n currentOwned\n );\n }\n /**\n * How much resource would it cost to buy (numItems) items if you already have currentOwned,\n * the initial price is priceStart and it multiplies by priceRatio each purchase?\n */\n\n public static sumGeometricSeries(\n numItems: DecimalSource,\n priceStart: DecimalSource,\n priceRatio: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.sumGeometricSeries_core(numItems, D(priceStart), D(priceRatio), currentOwned);\n }\n /**\n * If you're willing to spend 'resourcesAvailable' and want to buy something with additively\n * increasing cost each purchase (start at priceStart, add by priceAdd, already own currentOwned),\n * how much of it can you buy?\n */\n\n public static affordArithmeticSeries(\n resourcesAvailable: DecimalSource,\n priceStart: DecimalSource,\n priceAdd: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.affordArithmeticSeries_core(\n D(resourcesAvailable),\n D(priceStart),\n D(priceAdd),\n D(currentOwned)\n );\n }\n /**\n * How much resource would it cost to buy (numItems) items if you already have currentOwned,\n * the initial price is priceStart and it adds priceAdd each purchase?\n * Adapted from http://www.mathwords.com/a/arithmetic_series.htm\n */\n\n public static sumArithmeticSeries(\n numItems: DecimalSource,\n priceStart: DecimalSource,\n priceAdd: DecimalSource,\n currentOwned: DecimalSource\n ): Decimal {\n return this.sumArithmeticSeries_core(\n D(numItems),\n D(priceStart),\n D(priceAdd),\n D(currentOwned)\n );\n }\n /**\n * When comparing two purchases that cost (resource) and increase your resource/sec by (deltaRpS),\n * the lowest efficiency score is the better one to purchase.\n * From Frozen Cookies:\n * http://cookieclicker.wikia.com/wiki/Frozen_Cookies_(JavaScript_Add-on)#Efficiency.3F_What.27s_that.3F\n */\n\n public static efficiencyOfPurchase(\n cost: DecimalSource,\n currentRpS: DecimalSource,\n deltaRpS: DecimalSource\n ): Decimal {\n return this.efficiencyOfPurchase_core(D(cost), D(currentRpS), D(deltaRpS));\n }\n\n public static randomDecimalForTesting(maxLayers: number): Decimal {\n // NOTE: This doesn't follow any kind of sane random distribution, so use this for testing purposes only.\n //5% of the time, return 0\n if (Math.random() * 20 < 1) {\n return FC_NN(0, 0, 0);\n }\n\n const randomsign = Math.random() > 0.5 ? 1 : -1;\n\n //5% of the time, return 1 or -1\n if (Math.random() * 20 < 1) {\n return FC_NN(randomsign, 0, 1);\n }\n\n //pick a random layer\n const layer = Math.floor(Math.random() * (maxLayers + 1));\n\n let randomexp = layer === 0 ? Math.random() * 616 - 308 : Math.random() * 16;\n //10% of the time, make it a simple power of 10\n if (Math.random() > 0.9) {\n randomexp = Math.trunc(randomexp);\n }\n let randommag = Math.pow(10, randomexp);\n //10% of the time, trunc mag\n if (Math.random() > 0.9) {\n randommag = Math.trunc(randommag);\n }\n return FC(randomsign, layer, randommag);\n }\n\n public static affordGeometricSeries_core(\n resourcesAvailable: Decimal,\n priceStart: Decimal,\n priceRatio: Decimal,\n currentOwned: DecimalSource\n ): Decimal {\n const actualStart = priceStart.mul(priceRatio.pow(currentOwned));\n return Decimal.floor(\n resourcesAvailable\n .div(actualStart)\n .mul(priceRatio.sub(1))\n .add(1)\n .log10()\n .div(priceRatio.log10())\n );\n }\n\n public static sumGeometricSeries_core(\n numItems: DecimalSource,\n priceStart: Decimal,\n priceRatio: Decimal,\n currentOwned: DecimalSource\n ): Decimal {\n return priceStart\n .mul(priceRatio.pow(currentOwned))\n .mul(Decimal.sub(1, priceRatio.pow(numItems)))\n .div(Decimal.sub(1, priceRatio));\n }\n\n public static affordArithmeticSeries_core(\n resourcesAvailable: Decimal,\n priceStart: Decimal,\n priceAdd: Decimal,\n currentOwned: Decimal\n ): Decimal {\n // n = (-(a-d/2) + sqrt((a-d/2)^2+2dS))/d\n // where a is actualStart, d is priceAdd and S is resourcesAvailable\n // then floor it and you're done!\n const actualStart = priceStart.add(currentOwned.mul(priceAdd));\n const b = actualStart.sub(priceAdd.div(2));\n const b2 = b.pow(2);\n return b\n .neg()\n .add(b2.add(priceAdd.mul(resourcesAvailable).mul(2)).sqrt())\n .div(priceAdd)\n .floor();\n }\n\n public static sumArithmeticSeries_core(\n numItems: Decimal,\n priceStart: Decimal,\n priceAdd: Decimal,\n currentOwned: Decimal\n ): Decimal {\n const actualStart = priceStart.add(currentOwned.mul(priceAdd)); // (n/2)*(2*a+(n-1)*d)\n\n return numItems.div(2).mul(actualStart.mul(2).plus(numItems.sub(1).mul(priceAdd)));\n }\n\n public static efficiencyOfPurchase_core(\n cost: Decimal,\n currentRpS: Decimal,\n deltaRpS: Decimal\n ): Decimal {\n return cost.div(currentRpS).add(cost.div(deltaRpS));\n }\n\n public [Symbol.for(\"+\")](other: DecimalSource): DecimalSource {\n return this.add(other);\n }\n\n public [Symbol.for(\"-\")](other: DecimalSource): DecimalSource {\n return this.sub(other);\n }\n\n public [Symbol.for(\"*\")](other: DecimalSource): DecimalSource {\n return this.times(other);\n }\n\n public [Symbol.for(\"/\")](other: DecimalSource): DecimalSource {\n return this.div(other);\n }\n\n public [Symbol.for(\"minus\")](): DecimalSource {\n return this.neg();\n }\n\n public [Symbol.for(\"==\")](other: DecimalSource): boolean {\n return this.eq(other);\n }\n\n public [Symbol.for(\">\")](other: DecimalSource): boolean {\n return this.gt(other);\n }\n\n public [Symbol.for(\"<\")](other: DecimalSource): boolean {\n return this.lt(other);\n }\n\n public [Symbol.for(\">=\")](other: DecimalSource): boolean {\n return this.gte(other);\n }\n\n public [Symbol.for(\"<=\")](other: DecimalSource): boolean {\n return this.lte(other);\n }\n\n public [Symbol.for(\"!=\")](other: DecimalSource): boolean {\n return this.neq(other);\n }\n\n public normalize(): this {\n /*\n PSEUDOCODE:\n Whenever we are partially 0 (sign is 0 or mag and layer is 0), make it fully 0.\n Whenever we are at or hit layer 0, extract sign from negative mag.\n If layer === 0 and mag < FIRST_NEG_LAYER (1/9e15), shift to 'first negative layer' (add layer, log10 mag).\n While abs(mag) > EXP_LIMIT (9e15), layer += 1, mag = maglog10(mag).\n While abs(mag) < LAYER_DOWN (15.954) and layer > 0, layer -= 1, mag = pow(10, mag).\n\n When we're done, all of the following should be true OR one of the numbers is not IsFinite OR layer is not IsInteger (error state):\n Any 0 is totally zero (0, 0, 0).\n Anything layer 0 has mag 0 OR mag > 1/9e15 and < 9e15.\n Anything layer 1 or higher has abs(mag) >= 15.954 and < 9e15.\n We will assume in calculations that all Decimals are either erroneous or satisfy these criteria. (Otherwise: Garbage in, garbage out.)\n */\n if (this.sign === 0 || (this.mag === 0 && this.layer === 0)) {\n this.sign = 0;\n this.mag = 0;\n this.layer = 0;\n return this;\n }\n\n if (this.layer === 0 && this.mag < 0) {\n //extract sign from negative mag at layer 0\n this.mag = -this.mag;\n this.sign = -this.sign;\n }\n\n //Handle shifting from layer 0 to negative layers.\n if (this.layer === 0 && this.mag < FIRST_NEG_LAYER) {\n this.layer += 1;\n this.mag = Math.log10(this.mag);\n return this;\n }\n\n let absmag = Math.abs(this.mag);\n let signmag = Math.sign(this.mag);\n\n if (absmag >= EXP_LIMIT) {\n this.layer += 1;\n this.mag = signmag * Math.log10(absmag);\n return this;\n } else {\n while (absmag < LAYER_DOWN && this.layer > 0) {\n this.layer -= 1;\n if (this.layer === 0) {\n this.mag = Math.pow(10, this.mag);\n } else {\n this.mag = signmag * Math.pow(10, absmag);\n absmag = Math.abs(this.mag);\n signmag = Math.sign(this.mag);\n }\n }\n if (this.layer === 0) {\n if (this.mag < 0) {\n //extract sign from negative mag at layer 0\n this.mag = -this.mag;\n this.sign = -this.sign;\n } else if (this.mag === 0) {\n //excessive rounding can give us all zeroes\n this.sign = 0;\n }\n }\n }\n\n return this;\n }\n\n public fromComponents(sign: number, layer: number, mag: number): this {\n this.sign = sign;\n this.layer = layer;\n this.mag = mag;\n\n this.normalize();\n return this;\n }\n\n public fromComponents_noNormalize(sign: number, layer: number, mag: number): this {\n this.sign = sign;\n this.layer = layer;\n this.mag = mag;\n return this;\n }\n\n public fromMantissaExponent(mantissa: number, exponent: number): this {\n this.layer = 1;\n this.sign = Math.sign(mantissa);\n mantissa = Math.abs(mantissa);\n this.mag = exponent + Math.log10(mantissa);\n\n this.normalize();\n return this;\n }\n\n public fromMantissaExponent_noNormalize(mantissa: number, exponent: number): this {\n //The idea of 'normalizing' a break_infinity.js style Decimal doesn't really apply. So just do the same thing.\n this.fromMantissaExponent(mantissa, exponent);\n return this;\n }\n\n public fromDecimal(value: Decimal): this {\n this.sign = value.sign;\n this.layer = value.layer;\n this.mag = value.mag;\n return this;\n }\n\n public fromNumber(value: number): this {\n this.mag = Math.abs(value);\n this.sign = Math.sign(value);\n this.layer = 0;\n this.normalize();\n return this;\n }\n\n public fromString(value: string): Decimal {\n if (IGNORE_COMMAS) {\n value = value.replace(\",\", \"\");\n } else if (COMMAS_ARE_DECIMAL_POINTS) {\n value = value.replace(\",\", \".\");\n }\n\n //Handle x^^^y format.\n const pentationparts = value.split(\"^^^\");\n if (pentationparts.length === 2) {\n const base = parseFloat(pentationparts[0]);\n const height = parseFloat(pentationparts[1]);\n const heightparts = pentationparts[1].split(\";\");\n let payload = 1;\n if (heightparts.length === 2) {\n payload = parseFloat(heightparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.pentate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //Handle x^^y format.\n const tetrationparts = value.split(\"^^\");\n if (tetrationparts.length === 2) {\n const base = parseFloat(tetrationparts[0]);\n const height = parseFloat(tetrationparts[1]);\n const heightparts = tetrationparts[1].split(\";\");\n let payload = 1;\n if (heightparts.length === 2) {\n payload = parseFloat(heightparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.tetrate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //Handle x^y format.\n const powparts = value.split(\"^\");\n if (powparts.length === 2) {\n const base = parseFloat(powparts[0]);\n const exponent = parseFloat(powparts[1]);\n if (isFinite(base) && isFinite(exponent)) {\n const result = Decimal.pow(base, exponent);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //Handle various cases involving it being a Big Number.\n value = value.trim().toLowerCase();\n\n //handle X PT Y format.\n let base;\n let height;\n let ptparts = value.split(\"pt\");\n if (ptparts.length === 2) {\n base = 10;\n height = parseFloat(ptparts[0]);\n ptparts[1] = ptparts[1].replace(\"(\", \"\");\n ptparts[1] = ptparts[1].replace(\")\", \"\");\n let payload = parseFloat(ptparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.tetrate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n //handle XpY format (it's the same thing just with p).\n ptparts = value.split(\"p\");\n if (ptparts.length === 2) {\n base = 10;\n height = parseFloat(ptparts[0]);\n ptparts[1] = ptparts[1].replace(\"(\", \"\");\n ptparts[1] = ptparts[1].replace(\")\", \"\");\n let payload = parseFloat(ptparts[1]);\n if (!isFinite(payload)) {\n payload = 1;\n }\n if (isFinite(base) && isFinite(height)) {\n const result = Decimal.tetrate(base, height, payload);\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n }\n }\n\n const parts = value.split(\"e\");\n const ecount = parts.length - 1;\n\n //Handle numbers that are exactly floats (0 or 1 es).\n if (ecount === 0) {\n const numberAttempt = parseFloat(value);\n if (isFinite(numberAttempt)) {\n return this.fromNumber(numberAttempt);\n }\n } else if (ecount === 1) {\n //Very small numbers (\"2e-3000\" and so on) may look like valid floats but round to 0.\n const numberAttempt = parseFloat(value);\n if (isFinite(numberAttempt) && numberAttempt !== 0) {\n return this.fromNumber(numberAttempt);\n }\n }\n\n //Handle new (e^N)X format.\n const newparts = value.split(\"e^\");\n if (newparts.length === 2) {\n this.sign = 1;\n if (newparts[0].charAt(0) == \"-\") {\n this.sign = -1;\n }\n let layerstring = \"\";\n for (let i = 0; i < newparts[1].length; ++i) {\n const chrcode = newparts[1].charCodeAt(i);\n if ((chrcode >= 43 && chrcode <= 57) || chrcode === 101) {\n //is \"0\" to \"9\" or \"+\" or \"-\" or \".\" or \"e\" (or \",\" or \"/\")\n layerstring += newparts[1].charAt(i);\n } //we found the end of the layer count\n else {\n this.layer = parseFloat(layerstring);\n this.mag = parseFloat(newparts[1].substr(i + 1));\n this.normalize();\n return this;\n }\n }\n }\n\n if (ecount < 1) {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n return this;\n }\n const mantissa = parseFloat(parts[0]);\n if (mantissa === 0) {\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n return this;\n }\n let exponent = parseFloat(parts[parts.length - 1]);\n //handle numbers like AeBeC and AeeeeBeC\n if (ecount >= 2) {\n const me = parseFloat(parts[parts.length - 2]);\n if (isFinite(me)) {\n exponent *= Math.sign(me);\n exponent += f_maglog10(me);\n }\n }\n\n //Handle numbers written like eee... (N es) X\n if (!isFinite(mantissa)) {\n this.sign = parts[0] === \"-\" ? -1 : 1;\n this.layer = ecount;\n this.mag = exponent;\n }\n //Handle numbers written like XeY\n else if (ecount === 1) {\n this.sign = Math.sign(mantissa);\n this.layer = 1;\n //Example: 2e10 is equal to 10^log10(2e10) which is equal to 10^(10+log10(2))\n this.mag = exponent + Math.log10(Math.abs(mantissa));\n }\n //Handle numbers written like Xeee... (N es) Y\n else {\n this.sign = Math.sign(mantissa);\n this.layer = ecount;\n if (ecount === 2) {\n const result = Decimal.mul(FC(1, 2, exponent), D(mantissa));\n this.sign = result.sign;\n this.layer = result.layer;\n this.mag = result.mag;\n return this;\n } else {\n //at eee and above, mantissa is too small to be recognizable!\n this.mag = exponent;\n }\n }\n\n this.normalize();\n return this;\n }\n\n public fromValue(value: DecimalSource): Decimal {\n if (value instanceof Decimal || (value != null && typeof value === \"object\" && \"sign\" in value && \"mag\" in value && \"layer\" in value)) {\n return this.fromDecimal(value);\n }\n\n if (typeof value === \"number\") {\n return this.fromNumber(value);\n }\n\n if (typeof value === \"string\") {\n return this.fromString(value);\n }\n\n this.sign = 0;\n this.layer = 0;\n this.mag = 0;\n return this;\n }\n\n public toNumber(): number {\n if (!Number.isFinite(this.layer)) {\n return Number.NaN;\n }\n if (this.layer === 0) {\n return this.sign * this.mag;\n } else if (this.layer === 1) {\n return this.sign * Math.pow(10, this.mag);\n } //overflow for any normalized Decimal\n else {\n return this.mag > 0\n ? this.sign > 0\n ? Number.POSITIVE_INFINITY\n : Number.NEGATIVE_INFINITY\n : 0;\n }\n }\n\n public mantissaWithDecimalPlaces(places: number): number {\n // https://stackoverflow.com/a/37425022\n if (isNaN(this.m)) {\n return Number.NaN;\n }\n\n if (this.m === 0) {\n return 0;\n }\n\n return decimalPlaces(this.m, places);\n }\n\n public magnitudeWithDecimalPlaces(places: number): number {\n // https://stackoverflow.com/a/37425022\n if (isNaN(this.mag)) {\n return Number.NaN;\n }\n\n if (this.mag === 0) {\n return 0;\n }\n\n return decimalPlaces(this.mag, places);\n }\n\n public toString(): string {\n if (isNaN(this.layer) || isNaN(this.sign) || isNaN(this.mag)) {\n return \"NaN\";\n }\n if (this.mag === Number.POSITIVE_INFINITY || this.layer === Number.POSITIVE_INFINITY) {\n return this.sign === 1 ? \"Infinity\" : \"-Infinity\";\n }\n\n if (this.layer === 0) {\n if ((this.mag < 1e21 && this.mag > 1e-7) || this.mag === 0) {\n return (this.sign * this.mag).toString();\n }\n return this.m + \"e\" + this.e;\n } else if (this.layer === 1) {\n return this.m + \"e\" + this.e;\n } else {\n //layer 2+\n if (this.layer <= MAX_ES_IN_A_ROW) {\n return (this.sign === -1 ? \"-\" : \"\") + \"e\".repeat(this.layer) + this.mag;\n } else {\n return (this.sign === -1 ? \"-\" : \"\") + \"(e^\" + this.layer + \")\" + this.mag;\n }\n }\n }\n\n public toExponential(places: number): string {\n if (this.layer === 0) {\n return (this.sign * this.mag).toExponential(places);\n }\n return this.toStringWithDecimalPlaces(places);\n }\n\n public toFixed(places: number): string {\n if (this.layer === 0) {\n return (this.sign * this.mag).toFixed(places);\n }\n return this.toStringWithDecimalPlaces(places);\n }\n\n public toPrecision(places: number): string {\n if (this.e <= -7) {\n return this.toExponential(places - 1);\n }\n\n if (places > this.e) {\n return this.toFixed(places - this.exponent - 1);\n }\n\n return this.toExponential(places - 1);\n }\n\n public valueOf(): string {\n return this.toString();\n }\n\n public toJSON(): string {\n return this.toString();\n }\n\n public toStringWithDecimalPlaces(places: number): string {\n if (this.layer === 0) {\n if ((this.mag < 1e21 && this.mag > 1e-7) || this.mag === 0) {\n return (this.sign * this.mag).toFixed(places);\n }\n return decimalPlaces(this.m, places) + \"e\" + decimalPlaces(this.e, places);\n } else if (this.layer === 1) {\n return decimalPlaces(this.m, places) + \"e\" + decimalPlaces(this.e, places);\n } else {\n //layer 2+\n if (this.layer <= MAX_ES_IN_A_ROW) {\n return (\n (this.sign === -1 ? \"-\" : \"\") +\n \"e\".repeat(this.layer) +\n decimalPlaces(this.mag, places)\n );\n } else {\n return (\n (this.sign === -1 ? \"-\" : \"\") +\n \"(e^\" +\n this.layer +\n \")\" +\n decimalPlaces(this.mag, places)\n );\n }\n }\n }\n\n public abs(): Decimal {\n return FC_NN(this.sign === 0 ? 0 : 1, this.layer, this.mag);\n }\n\n public neg(): Decimal {\n return FC_NN(-this.sign, this.layer, this.mag);\n }\n\n public negate(): Decimal {\n return this.neg();\n }\n\n public negated(): Decimal {\n return this.neg();\n }\n\n // public sign () {\n // return this.sign;\n // }\n\n public sgn(): number {\n return this.sign;\n }\n\n public round(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.round(this.mag));\n }\n return this;\n }\n\n public floor(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.floor(this.mag));\n }\n return this;\n }\n\n public ceil(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.ceil(this.mag));\n }\n return this;\n }\n\n public trunc(): this | Decimal {\n if (this.mag < 0) {\n return Decimal.dZero;\n }\n if (this.layer === 0) {\n return FC(this.sign, 0, Math.trunc(this.mag));\n }\n return this;\n }\n\n public add(value: DecimalSource): this | Decimal {\n const decimal = D(value);\n\n //inf/nan check\n if (!Number.isFinite(this.layer)) {\n return this;\n }\n if (!Number.isFinite(decimal.layer)) {\n return decimal;\n }\n\n //Special case - if one of the numbers is 0, return the other number.\n if (this.sign === 0) {\n return decimal;\n }\n if (decimal.sign === 0) {\n return this;\n }\n\n //Special case - Adding a number to its negation produces 0, no matter how large.\n if (\n this.sign === -decimal.sign &&\n this.layer === decimal.layer &&\n this.mag === decimal.mag\n ) {\n return FC_NN(0, 0, 0);\n }\n\n let a;\n let b;\n\n //Special case: If one of the numbers is layer 2 or higher, just take the bigger number.\n if (this.layer >= 2 || decimal.layer >= 2) {\n return this.maxabs(decimal);\n }\n\n if (Decimal.cmpabs(this, decimal) > 0) {\n a = this;\n b = decimal;\n } else {\n a = decimal;\n b = this;\n }\n\n if (a.layer === 0 && b.layer === 0) {\n return D(a.sign * a.mag + b.sign * b.mag);\n }\n\n const layera = a.layer * Math.sign(a.mag);\n const layerb = b.layer * Math.sign(b.mag);\n\n //If one of the numbers is 2+ layers higher than the other, just take the bigger number.\n if (layera - layerb >= 2) {\n return a;\n }\n\n if (layera === 0 && layerb === -1) {\n if (Math.abs(b.mag - Math.log10(a.mag)) > MAX_SIGNIFICANT_DIGITS) {\n return a;\n } else {\n const magdiff = Math.pow(10, Math.log10(a.mag) - b.mag);\n const mantissa = b.sign + a.sign * magdiff;\n return FC(Math.sign(mantissa), 1, b.mag + Math.log10(Math.abs(mantissa)));\n }\n }\n\n if (layera === 1 && layerb === 0) {\n if (Math.abs(a.mag - Math.log10(b.mag)) > MAX_SIGNIFICANT_DIGITS) {\n return a;\n } else {\n const magdiff = Math.pow(10, a.mag - Math.log10(b.mag));\n const mantissa = b.sign + a.sign * magdiff;\n return FC(\n Math.sign(mantissa),\n 1,\n Math.log10(b.mag) + Math.log10(Math.abs(mantissa))\n );\n }\n }\n\n if (Math.abs(a.mag - b.mag) > MAX_SIGNIFICANT_DIGITS) {\n return a;\n } else {\n const magdiff = Math.pow(10, a.mag - b.mag);\n const mantissa = b.sign + a.sign * magdiff;\n return FC(Math.sign(mantissa), 1, b.mag + Math.log10(Math.abs(mantissa)));\n }\n\n throw Error(\"Bad arguments to add: \" + this + \", \" + value);\n }\n\n public plus(value: DecimalSource): Decimal {\n return this.add(value);\n }\n\n public sub(value: DecimalSource): Decimal {\n return this.add(D(value).neg());\n }\n\n public subtract(value: DecimalSource): Decimal {\n return this.sub(value);\n }\n\n public minus(value: DecimalSource): Decimal {\n return this.sub(value);\n }\n\n public mul(value: DecimalSource): Decimal {\n const decimal = D(value);\n\n //inf/nan check\n if (!Number.isFinite(this.layer)) {\n return this;\n }\n if (!Number.isFinite(decimal.layer)) {\n return decimal;\n }\n\n //Special case - if one of the numbers is 0, return 0.\n if (this.sign === 0 || decimal.sign === 0) {\n return FC_NN(0, 0, 0);\n }\n\n //Special case - Multiplying a number by its own reciprocal yields +/- 1, no matter how large.\n if (this.layer === decimal.layer && this.mag === -decimal.mag) {\n return FC_NN(this.sign * decimal.sign, 0, 1);\n }\n\n let a;\n let b;\n\n //Which number is bigger in terms of its multiplicative distance from 1?\n if (\n this.layer > decimal.layer ||\n (this.layer == decimal.layer && Math.abs(this.mag) > Math.abs(decimal.mag))\n ) {\n a = this;\n b = decimal;\n } else {\n a = decimal;\n b = this;\n }\n\n if (a.layer === 0 && b.layer === 0) {\n return D(a.sign * b.sign * a.mag * b.mag);\n }\n\n //Special case: If one of the numbers is layer 3 or higher or one of the numbers is 2+ layers bigger than the other, just take the bigger number.\n if (a.layer >= 3 || a.layer - b.layer >= 2) {\n return FC(a.sign * b.sign, a.layer, a.mag);\n }\n\n if (a.layer === 1 && b.layer === 0) {\n return FC(a.sign * b.sign, 1, a.mag + Math.log10(b.mag));\n }\n\n if (a.layer === 1 && b.layer === 1) {\n return FC(a.sign * b.sign, 1, a.mag + b.mag);\n }\n\n if (a.layer === 2 && b.layer === 1) {\n const newmag = FC(Math.sign(a.mag), a.layer - 1, Math.abs(a.mag)).add(\n FC(Math.sign(b.mag), b.layer - 1, Math.abs(b.mag))\n );\n return FC(a.sign * b.sign, newmag.layer + 1, newmag.sign * newmag.mag);\n }\n\n if (a.layer === 2 && b.layer === 2) {\n const newmag = FC(Math.sign(a.mag), a.layer - 1, Math.abs(a.mag)).add(\n FC(Math.sign(b.mag), b.layer - 1, Math.abs(b.mag))\n );\n return FC(a.sign * b.sign, newmag.layer + 1, newmag.sign * newmag.mag);\n }\n\n throw Error(\"Bad arguments to mul: \" + this + \", \" + value);\n }\n\n public multiply(value: DecimalSource): Decimal {\n return this.mul(value);\n }\n\n public times(value: DecimalSource): Decimal {\n return this.mul(value);\n }\n\n public div(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.mul(decimal.recip());\n }\n\n public divide(value: DecimalSource): Decimal {\n return this.div(value);\n }\n\n public divideBy(value: DecimalSource): Decimal {\n return this.div(value);\n }\n\n public dividedBy(value: DecimalSource): Decimal {\n return this.div(value);\n }\n\n public recip(): Decimal {\n if (this.mag === 0) {\n return Decimal.dNaN;\n } else if (this.layer === 0) {\n return FC(this.sign, 0, 1 / this.mag);\n } else {\n return FC(this.sign, this.layer, -this.mag);\n }\n }\n\n public reciprocal(): Decimal {\n return this.recip();\n }\n\n public reciprocate(): Decimal {\n return this.recip();\n }\n\n /**\n * -1 for less than value, 0 for equals value, 1 for greater than value\n */\n public cmp(value: DecimalSource): CompareResult {\n const decimal = D(value);\n if (this.sign > decimal.sign) {\n return 1;\n }\n if (this.sign < decimal.sign) {\n return -1;\n }\n return (this.sign * this.cmpabs(value)) as CompareResult;\n }\n\n public cmpabs(value: DecimalSource): CompareResult {\n const decimal = D(value);\n const layera = this.mag > 0 ? this.layer : -this.layer;\n const layerb = decimal.mag > 0 ? decimal.layer : -decimal.layer;\n if (layera > layerb) {\n return 1;\n }\n if (layera < layerb) {\n return -1;\n }\n if (this.mag > decimal.mag) {\n return 1;\n }\n if (this.mag < decimal.mag) {\n return -1;\n }\n return 0;\n }\n\n public compare(value: DecimalSource): CompareResult {\n return this.cmp(value);\n }\n\n public isNan(): boolean {\n return isNaN(this.sign) || isNaN(this.layer) || isNaN(this.mag);\n }\n\n public isFinite(): boolean {\n return isFinite(this.sign) && isFinite(this.layer) && isFinite(this.mag);\n }\n\n public eq(value: DecimalSource): boolean {\n const decimal = D(value);\n return (\n this.sign === decimal.sign && this.layer === decimal.layer && this.mag === decimal.mag\n );\n }\n\n public equals(value: DecimalSource): boolean {\n return this.eq(value);\n }\n\n public neq(value: DecimalSource): boolean {\n return !this.eq(value);\n }\n\n public notEquals(value: DecimalSource): boolean {\n return this.neq(value);\n }\n\n public lt(value: DecimalSource): boolean {\n return this.cmp(value) === -1;\n }\n\n public lte(value: DecimalSource): boolean {\n return !this.gt(value);\n }\n\n public gt(value: DecimalSource): boolean {\n return this.cmp(value) === 1;\n }\n\n public gte(value: DecimalSource): boolean {\n return !this.lt(value);\n }\n\n public max(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.lt(decimal) ? decimal : this;\n }\n\n public min(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.gt(decimal) ? decimal : this;\n }\n\n public maxabs(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.cmpabs(decimal) < 0 ? decimal : this;\n }\n\n public minabs(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.cmpabs(decimal) > 0 ? decimal : this;\n }\n\n public clamp(min: DecimalSource, max: DecimalSource): Decimal {\n return this.max(min).min(max);\n }\n\n public clampMin(min: DecimalSource): Decimal {\n return this.max(min);\n }\n\n public clampMax(max: DecimalSource): Decimal {\n return this.min(max);\n }\n\n public cmp_tolerance(value: DecimalSource, tolerance: number): CompareResult {\n const decimal = D(value);\n return this.eq_tolerance(decimal, tolerance) ? 0 : this.cmp(decimal);\n }\n\n public compare_tolerance(value: DecimalSource, tolerance: number): CompareResult {\n return this.cmp_tolerance(value, tolerance);\n }\n\n /**\n * Tolerance is a relative tolerance, multiplied by the greater of the magnitudes of the two arguments.\n * For example, if you put in 1e-9, then any number closer to the\n * larger number than (larger number)*1e-9 will be considered equal.\n */\n public eq_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value); // https://stackoverflow.com/a/33024979\n if (tolerance == null) {\n tolerance = 1e-7;\n }\n //Numbers that are too far away are never close.\n if (this.sign !== decimal.sign) {\n return false;\n }\n if (Math.abs(this.layer - decimal.layer) > 1) {\n return false;\n }\n // return abs(a-b) <= tolerance * max(abs(a), abs(b))\n let magA = this.mag;\n let magB = decimal.mag;\n if (this.layer > decimal.layer) {\n magB = f_maglog10(magB);\n }\n if (this.layer < decimal.layer) {\n magA = f_maglog10(magA);\n }\n return Math.abs(magA - magB) <= tolerance * Math.max(Math.abs(magA), Math.abs(magB));\n }\n\n public equals_tolerance(value: DecimalSource, tolerance: number): boolean {\n return this.eq_tolerance(value, tolerance);\n }\n\n public neq_tolerance(value: DecimalSource, tolerance: number): boolean {\n return !this.eq_tolerance(value, tolerance);\n }\n\n public notEquals_tolerance(value: DecimalSource, tolerance: number): boolean {\n return this.neq_tolerance(value, tolerance);\n }\n\n public lt_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return !this.eq_tolerance(decimal, tolerance) && this.lt(decimal);\n }\n\n public lte_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return this.eq_tolerance(decimal, tolerance) || this.lt(decimal);\n }\n\n public gt_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return !this.eq_tolerance(decimal, tolerance) && this.gt(decimal);\n }\n\n public gte_tolerance(value: DecimalSource, tolerance: number): boolean {\n const decimal = D(value);\n return this.eq_tolerance(decimal, tolerance) || this.gt(decimal);\n }\n\n public pLog10(): Decimal {\n if (this.lt(Decimal.dZero)) {\n return Decimal.dZero;\n }\n return this.log10();\n }\n\n public absLog10(): Decimal {\n if (this.sign === 0) {\n return Decimal.dNaN;\n } else if (this.layer > 0) {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n } else {\n return FC(1, 0, Math.log10(this.mag));\n }\n }\n\n public log10(): Decimal {\n if (this.sign <= 0) {\n return Decimal.dNaN;\n } else if (this.layer > 0) {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n } else {\n return FC(this.sign, 0, Math.log10(this.mag));\n }\n }\n\n public log(base: DecimalSource): Decimal {\n base = D(base);\n if (this.sign <= 0) {\n return Decimal.dNaN;\n }\n if (base.sign <= 0) {\n return Decimal.dNaN;\n }\n if (base.sign === 1 && base.layer === 0 && base.mag === 1) {\n return Decimal.dNaN;\n } else if (this.layer === 0 && base.layer === 0) {\n return FC(this.sign, 0, Math.log(this.mag) / Math.log(base.mag));\n }\n\n return Decimal.div(this.log10(), base.log10());\n }\n\n public log2(): Decimal {\n if (this.sign <= 0) {\n return Decimal.dNaN;\n } else if (this.layer === 0) {\n return FC(this.sign, 0, Math.log2(this.mag));\n } else if (this.layer === 1) {\n return FC(Math.sign(this.mag), 0, Math.abs(this.mag) * 3.321928094887362); //log2(10)\n } else if (this.layer === 2) {\n return FC(Math.sign(this.mag), 1, Math.abs(this.mag) + 0.5213902276543247); //-log10(log10(2))\n } else {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n }\n }\n\n public ln(): Decimal {\n if (this.sign <= 0) {\n return Decimal.dNaN;\n } else if (this.layer === 0) {\n return FC(this.sign, 0, Math.log(this.mag));\n } else if (this.layer === 1) {\n return FC(Math.sign(this.mag), 0, Math.abs(this.mag) * 2.302585092994046); //ln(10)\n } else if (this.layer === 2) {\n return FC(Math.sign(this.mag), 1, Math.abs(this.mag) + 0.36221568869946325); //log10(log10(e))\n } else {\n return FC(Math.sign(this.mag), this.layer - 1, Math.abs(this.mag));\n }\n }\n\n public logarithm(base: DecimalSource): Decimal {\n return this.log(base);\n }\n\n public pow(value: DecimalSource): Decimal {\n const decimal = D(value);\n const a = this;\n const b = decimal;\n\n //special case: if a is 0, then return 0 (UNLESS b is 0, then return 1)\n if (a.sign === 0) {\n return b.eq(0) ? FC_NN(1, 0, 1) : a;\n }\n //special case: if a is 1, then return 1\n if (a.sign === 1 && a.layer === 0 && a.mag === 1) {\n return a;\n }\n //special case: if b is 0, then return 1\n if (b.sign === 0) {\n return FC_NN(1, 0, 1);\n }\n //special case: if b is 1, then return a\n if (b.sign === 1 && b.layer === 0 && b.mag === 1) {\n return a;\n }\n\n const result = a\n .absLog10()\n .mul(b)\n .pow10();\n\n if (this.sign === -1) {\n if (Math.abs(b.toNumber() % 2) % 2 === 1) {\n return result.neg();\n } else if (Math.abs(b.toNumber() % 2) % 2 === 0) {\n return result;\n }\n return Decimal.dNaN;\n }\n\n return result;\n }\n\n public pow10(): Decimal {\n /*\n There are four cases we need to consider:\n 1) positive sign, positive mag (e15, ee15): +1 layer (e.g. 10^15 becomes e15, 10^e15 becomes ee15)\n 2) negative sign, positive mag (-e15, -ee15): +1 layer but sign and mag sign are flipped (e.g. 10^-15 becomes e-15, 10^-e15 becomes ee-15)\n 3) positive sign, negative mag (e-15, ee-15): layer 0 case would have been handled in the Math.pow check, so just return 1\n 4) negative sign, negative mag (-e-15, -ee-15): layer 0 case would have been handled in the Math.pow check, so just return 1\n */\n\n if (!Number.isFinite(this.layer) || !Number.isFinite(this.mag)) {\n return Decimal.dNaN;\n }\n\n let a = this;\n\n //handle layer 0 case - if no precision is lost just use Math.pow, else promote one layer\n if (a.layer === 0) {\n const newmag = Math.pow(10, a.sign * a.mag);\n if (Number.isFinite(newmag) && Math.abs(newmag) >= 0.1) {\n return FC(1, 0, newmag);\n } else {\n if (a.sign === 0) {\n return Decimal.dOne;\n } else {\n a = FC_NN(a.sign, a.layer + 1, Math.log10(a.mag)) as this;\n }\n }\n }\n\n //handle all 4 layer 1+ cases individually\n if (a.sign > 0 && a.mag >= 0) {\n return FC(a.sign, a.layer + 1, a.mag);\n }\n if (a.sign < 0 && a.mag >= 0) {\n return FC(-a.sign, a.layer + 1, -a.mag);\n }\n //both the negative mag cases are identical: one +/- rounding error\n return Decimal.dOne;\n }\n\n public pow_base(value: DecimalSource): Decimal {\n return D(value).pow(this);\n }\n\n public root(value: DecimalSource): Decimal {\n const decimal = D(value);\n return this.pow(decimal.recip());\n }\n\n public factorial(): Decimal {\n if (this.mag < 0) {\n return this.add(1).gamma();\n } else if (this.layer === 0) {\n return this.add(1).gamma();\n } else if (this.layer === 1) {\n return Decimal.exp(Decimal.mul(this, Decimal.ln(this).sub(1)));\n } else {\n return Decimal.exp(this);\n }\n }\n\n //from HyperCalc source code\n public gamma(): Decimal {\n if (this.mag < 0) {\n return this.recip();\n } else if (this.layer === 0) {\n if (this.lt(FC_NN(1, 0, 24))) {\n return D(f_gamma(this.sign * this.mag));\n }\n\n const t = this.mag - 1;\n let l = 0.9189385332046727; //0.5*Math.log(2*Math.PI)\n l = l + (t + 0.5) * Math.log(t);\n l = l - t;\n const n2 = t * t;\n let np = t;\n let lm = 12 * np;\n let adj = 1 / lm;\n let l2 = l + adj;\n if (l2 === l) {\n return Decimal.exp(l);\n }\n\n l = l2;\n np = np * n2;\n lm = 360 * np;\n adj = 1 / lm;\n l2 = l - adj;\n if (l2 === l) {\n return Decimal.exp(l);\n }\n\n l = l2;\n np = np * n2;\n lm = 1260 * np;\n let lt = 1 / lm;\n l = l + lt;\n np = np * n2;\n lm = 1680 * np;\n lt = 1 / lm;\n l = l - lt;\n return Decimal.exp(l);\n } else if (this.layer === 1) {\n return Decimal.exp(Decimal.mul(this, Decimal.ln(this).sub(1)));\n } else {\n return Decimal.exp(this);\n }\n }\n\n public lngamma(): Decimal {\n return this.gamma().ln();\n }\n\n public exp(): Decimal {\n if (this.mag < 0) {\n return Decimal.dOne;\n }\n if (this.layer === 0 && this.mag <= 709.7) {\n return D(Math.exp(this.sign * this.mag));\n } else if (this.layer === 0) {\n return FC(1, 1, this.sign * Math.log10(Math.E) * this.mag);\n } else if (this.layer === 1) {\n return FC(1, 2, this.sign * (Math.log10(0.4342944819032518) + this.mag));\n } else {\n return FC(1, this.layer + 1, this.sign * this.mag);\n }\n }\n\n public sqr(): Decimal {\n return this.pow(2);\n }\n\n public sqrt(): Decimal {\n if (this.layer === 0) {\n return D(Math.sqrt(this.sign * this.mag));\n } else if (this.layer === 1) {\n return FC(1, 2, Math.log10(this.mag) - 0.3010299956639812);\n } else {\n const result = Decimal.div(FC_NN(this.sign, this.layer - 1, this.mag), FC_NN(1, 0, 2));\n result.layer += 1;\n result.normalize();\n return result;\n }\n }\n\n public cube(): Decimal {\n return this.pow(3);\n }\n\n public cbrt(): Decimal {\n return this.pow(1 / 3);\n }\n\n //Tetration/tetrate: The result of exponentiating 'this' to 'this' 'height' times in a row. https://en.wikipedia.org/wiki/Tetration\n //If payload != 1, then this is 'iterated exponentiation', the result of exping (payload) to base (this) (height) times. https://andydude.github.io/tetration/archives/tetration2/ident.html\n //Works with negative and positive real heights.\n public tetrate(height = 2, payload: DecimalSource = FC_NN(1, 0, 1)): Decimal {\n //x^^1 == x\n if (height === 1) {\n return Decimal.pow(this, payload);\n }\n //x^^0 == 1\n if (height === 0) {\n return new Decimal(payload);\n }\n //1^^x == 1\n if (this.eq(Decimal.dOne)) {\n return Decimal.dOne;\n }\n //-1^^x == -1\n if (this.eq(-1)) {\n return Decimal.pow(this, payload);\n }\n\n if (height === Number.POSITIVE_INFINITY) {\n const this_num = this.toNumber();\n //within the convergence range?\n if (this_num <= 1.44466786100976613366 && this_num >= 0.06598803584531253708) {\n //hotfix for the very edge of the number range not being handled properly\n if (this_num > 1.444667861009099) {\n return new Decimal(Math.E);\n }\n //Formula for infinite height power tower.\n const negln = Decimal.ln(this).neg();\n return negln.lambertw().div(negln);\n } else if (this_num > 1.44466786100976613366) {\n //explodes to infinity\n return new Decimal(Number.POSITIVE_INFINITY);\n } else {\n //0.06598803584531253708 > this_num >= 0: never converges\n //this_num < 0: quickly becomes a complex number\n return Decimal.dNaN;\n }\n }\n\n //0^^x oscillates if we define 0^0 == 1 (which in javascript land we do), since then 0^^1 is 0, 0^^2 is 1, 0^^3 is 0, etc. payload is ignored\n //using the linear approximation for height (TODO: don't know a better way to calculate it ATM, but it wouldn't surprise me if it's just NaN)\n if (this.eq(Decimal.dZero)) {\n let result = Math.abs((height + 1) % 2);\n if (result > 1) {\n result = 2 - result;\n }\n return new Decimal(result);\n }\n\n if (height < 0) {\n return Decimal.iteratedlog(payload, this, -height);\n }\n\n payload = D(payload);\n const oldheight = height;\n height = Math.trunc(height);\n const fracheight = oldheight - height;\n\n if (this.gt(Decimal.dZero) && this.lte(1.44466786100976613366)) {\n //similar to 0^^n, flip-flops between two values, converging slowly (or if it's below 0.06598803584531253708, never. so once again, the fractional part at the end will be a linear approximation (TODO: again pending knowledge of how to approximate better, although tbh I think it should in reality just be NaN)\n height = Math.min(10000, height);\n for (let i = 0; i < height; ++i) {\n const old_payload: Decimal = payload;\n payload = this.pow(payload);\n //stop early if we converge\n if (old_payload.eq(payload)) {\n return payload;\n }\n }\n if (fracheight != 0) {\n const next_payload = this.pow(payload);\n return payload.mul(1 - fracheight).add(next_payload.mul(fracheight));\n }\n return payload;\n }\n //TODO: base < 0, but it's hard for me to reason about (probably all non-integer heights are NaN automatically?)\n\n if (fracheight !== 0) {\n if (payload.eq(Decimal.dOne)) {\n //TODO: for bases above 10, revert to old linear approximation until I can think of something better\n if (this.gt(10)) {\n payload = this.pow(fracheight);\n } else {\n payload = D(Decimal.tetrate_critical(this.toNumber(), fracheight));\n //TODO: until the critical section grid can handle numbers below 2, scale them to the base\n //TODO: maybe once the critical section grid has very large bases, this math can be appropriate for them too? I'll think about it\n if (this.lt(2)) {\n payload = payload\n .sub(1)\n .mul(this.minus(1))\n .plus(1);\n }\n }\n } else {\n if (this.eq(10)) {\n payload = payload.layeradd10(fracheight);\n } else {\n payload = payload.layeradd(fracheight, this);\n }\n }\n }\n\n for (let i = 0; i < height; ++i) {\n payload = this.pow(payload);\n //bail if we're NaN\n if (!isFinite(payload.layer) || !isFinite(payload.mag)) {\n return payload.normalize();\n }\n //shortcut\n if (payload.layer - this.layer > 3) {\n return FC_NN(payload.sign, payload.layer + (height - i - 1), payload.mag);\n }\n //give up after 10000 iterations if nothing is happening\n if (i > 10000) {\n return payload;\n }\n }\n return payload;\n }\n\n //iteratedexp/iterated exponentiation: - all cases handled in tetrate, so just call it\n public iteratedexp(height = 2, payload = FC_NN(1, 0, 1)): Decimal {\n return this.tetrate(height, payload);\n }\n\n //iterated log/repeated log: The result of applying log(base) 'times' times in a row. Approximately equal to subtracting (times) from the number's slog representation. Equivalent to tetrating to a negative height.\n //Works with negative and positive real heights.\n public iteratedlog(base: DecimalSource = 10, times = 1): Decimal {\n if (times < 0) {\n return Decimal.tetrate(base, -times, this);\n }\n\n base = D(base);\n let result = D(this);\n const fulltimes = times;\n times = Math.trunc(times);\n const fraction = fulltimes - times;\n if (result.layer - base.layer > 3) {\n const layerloss = Math.min(times, result.layer - base.layer - 3);\n times -= layerloss;\n result.layer -= layerloss;\n }\n\n for (let i = 0; i < times; ++i) {\n result = result.log(base);\n //bail if we're NaN\n if (!isFinite(result.layer) || !isFinite(result.mag)) {\n return result.normalize();\n }\n //give up after 10000 iterations if nothing is happening\n if (i > 10000) {\n return result;\n }\n }\n\n //handle fractional part\n if (fraction > 0 && fraction < 1) {\n if (base.eq(10)) {\n result = result.layeradd10(-fraction);\n } else {\n result = result.layeradd(-fraction, base);\n }\n }\n\n return result;\n }\n\n //Super-logarithm, one of tetration's inverses, tells you what size power tower you'd have to tetrate base to to get number. By definition, will never be higher than 1.8e308 in break_eternity.js, since a power tower 1.8e308 numbers tall is the largest representable number.\n // https://en.wikipedia.org/wiki/Super-logarithm\n public slog(base: DecimalSource = 10): Decimal {\n base = D(base);\n\n //special cases:\n //slog base 0 or lower is NaN\n if (base.lte(Decimal.dZero)) {\n return Decimal.dNaN;\n }\n //slog base 1 is NaN\n if (base.eq(Decimal.dOne)) {\n return Decimal.dNaN;\n }\n //need to handle these small, wobbling bases specially\n if (base.lt(Decimal.dOne)) {\n if (this.eq(Decimal.dOne)) {\n return Decimal.dZero;\n }\n if (this.eq(Decimal.dZero)) {\n return Decimal.dNegOne;\n }\n //0 < this < 1: ambiguous (happens multiple times)\n //this < 0: impossible (as far as I can tell)\n //this > 1: partially complex (http://myweb.astate.edu/wpaulsen/tetcalc/tetcalc.html base 0.25 for proof)\n return Decimal.dNaN;\n }\n //slog_n(0) is -1\n if (this.mag < 0 || this.eq(Decimal.dZero)) {\n return Decimal.dNegOne;\n }\n\n let result = 0;\n let copy = D(this);\n if (copy.layer - base.layer > 3) {\n const layerloss = copy.layer - base.layer - 3;\n result += layerloss;\n copy.layer -= layerloss;\n }\n\n for (let i = 0; i < 100; ++i) {\n if (copy.lt(Decimal.dZero)) {\n copy = Decimal.pow(base, copy);\n result -= 1;\n } else if (copy.lte(Decimal.dOne)) {\n return D(result + Decimal.slog_critical(base.toNumber(), copy.toNumber()));\n } else {\n result += 1;\n copy = Decimal.log(copy, base);\n }\n }\n return D(result);\n }\n\n //background info and tables of values for critical functions taken here: https://github.com/Patashu/break_eternity.js/issues/22\n public static slog_critical(base: number, height: number): number {\n //TODO: for bases above 10, revert to old linear approximation until I can think of something better\n if (base > 10) {\n return height - 1;\n }\n return Decimal.critical_section(base, height, critical_slog_values);\n }\n\n public static tetrate_critical(base: number, height: number): number {\n return Decimal.critical_section(base, height, critical_tetr_values);\n }\n\n public static critical_section(base: number, height: number, grid: number[][]): number {\n //this part is simple at least, since it's just 0.1 to 0.9\n height *= 10;\n if (height < 0) {\n height = 0;\n }\n if (height > 10) {\n height = 10;\n }\n //have to do this complicated song and dance since one of the critical_headers is Math.E, and in the future I'd like 1.5 as well\n if (base < 2) {\n base = 2;\n }\n if (base > 10) {\n base = 10;\n }\n let lower = 0;\n let upper = 0;\n //basically, if we're between bases, we interpolate each bases' relevant values together\n //then we interpolate based on what the fractional height is.\n //accuracy could be improved by doing a non-linear interpolation (maybe), by adding more bases and heights (definitely) but this is AFAIK the best you can get without running some pari.gp or mathematica program to calculate exact values\n for (let i = 0; i < critical_headers.length; ++i) {\n if (critical_headers[i] == base) {\n // exact match\n lower = grid[i][Math.floor(height)];\n upper = grid[i][Math.ceil(height)];\n break;\n } else if (critical_headers[i] < base && critical_headers[i + 1] > base) {\n // interpolate between this and the next\n const basefrac =\n (base - critical_headers[i]) / (critical_headers[i + 1] - critical_headers[i]);\n lower =\n grid[i][Math.floor(height)] * (1 - basefrac) +\n grid[i + 1][Math.floor(height)] * basefrac;\n upper =\n grid[i][Math.ceil(height)] * (1 - basefrac) +\n grid[i + 1][Math.ceil(height)] * basefrac;\n break;\n }\n }\n const frac = height - Math.floor(height);\n const result = lower * (1 - frac) + upper * frac;\n return result;\n }\n\n //Function for adding/removing layers from a Decimal, even fractional layers (e.g. its slog10 representation).\n //Moved this over to use the same critical section as tetrate/slog.\n public layeradd10(diff: DecimalSource): Decimal {\n diff = Decimal.fromValue_noAlloc(diff).toNumber();\n const result = D(this);\n if (diff >= 1) {\n //bug fix: if result is very smol (mag < 0, layer > 0) turn it into 0 first\n if (result.mag < 0 && result.layer > 0) {\n result.sign = 0;\n result.mag = 0;\n result.layer = 0;\n } else if (result.sign === -1 && result.layer == 0) {\n //bug fix - for stuff like -3.layeradd10(1) we need to move the sign to the mag\n result.sign = 1;\n result.mag = -result.mag;\n }\n const layeradd = Math.trunc(diff);\n diff -= layeradd;\n result.layer += layeradd;\n }\n if (diff <= -1) {\n const layeradd = Math.trunc(diff);\n diff -= layeradd;\n result.layer += layeradd;\n if (result.layer < 0) {\n for (let i = 0; i < 100; ++i) {\n result.layer++;\n result.mag = Math.log10(result.mag);\n if (!isFinite(result.mag)) {\n //another bugfix: if we hit -Infinity mag, then we should return negative infinity, not 0. 0.layeradd10(-1) h its this\n if (result.sign === 0) {\n result.sign = 1;\n }\n //also this, for 0.layeradd10(-2)\n if (result.layer < 0) {\n result.layer = 0;\n }\n return result.normalize();\n }\n if (result.layer >= 0) {\n break;\n }\n }\n }\n }\n\n while (result.layer < 0) {\n result.layer++;\n result.mag = Math.log10(result.mag);\n }\n //bugfix: before we normalize: if we started with 0, we now need to manually fix a layer ourselves!\n if (result.sign === 0) {\n result.sign = 1;\n if (result.mag === 0 && result.layer >= 1) {\n result.layer -= 1;\n result.mag = 1;\n }\n }\n result.normalize();\n\n //layeradd10: like adding 'diff' to the number's slog(base) representation. Very similar to tetrate base 10 and iterated log base 10. Also equivalent to adding a fractional amount to the number's layer in its break_eternity.js representation.\n if (diff !== 0) {\n return result.layeradd(diff, 10); //safe, only calls positive height 1 payload tetration, slog and log\n }\n\n return result;\n }\n\n //layeradd: like adding 'diff' to the number's slog(base) representation. Very similar to tetrate base 'base' and iterated log base 'base'.\n public layeradd(diff: number, base: DecimalSource): Decimal {\n const slogthis = this.slog(base).toNumber();\n const slogdest = slogthis + diff;\n if (slogdest >= 0) {\n return Decimal.tetrate(base, slogdest);\n } else if (!Number.isFinite(slogdest)) {\n return Decimal.dNaN;\n } else if (slogdest >= -1) {\n return Decimal.log(Decimal.tetrate(base, slogdest + 1), base);\n } else {\n return Decimal.log(Decimal.log(Decimal.tetrate(base, slogdest + 2), base), base);\n }\n }\n\n //The Lambert W function, also called the omega function or product logarithm, is the solution W(x) === x*e^x.\n // https://en.wikipedia.org/wiki/Lambert_W_function\n //Some special values, for testing: https://en.wikipedia.org/wiki/Lambert_W_function#Special_values\n public lambertw(): Decimal {\n if (this.lt(-0.3678794411710499)) {\n throw Error(\"lambertw is unimplemented for results less than -1, sorry!\");\n } else if (this.mag < 0) {\n return D(f_lambertw(this.toNumber()));\n } else if (this.layer === 0) {\n return D(f_lambertw(this.sign * this.mag));\n } else if (this.layer === 1) {\n return d_lambertw(this);\n } else if (this.layer === 2) {\n return d_lambertw(this);\n }\n if (this.layer >= 3) {\n return FC_NN(this.sign, this.layer - 1, this.mag);\n }\n\n throw \"Unhandled behavior in lambertw()\";\n }\n\n //The super square-root function - what number, tetrated to height 2, equals this?\n //Other sroots are possible to calculate probably through guess and check methods, this one is easy though.\n // https://en.wikipedia.org/wiki/Tetration#Super-root\n public ssqrt(): Decimal {\n if (this.sign == 1 && this.layer >= 3) {\n return FC_NN(this.sign, this.layer - 1, this.mag);\n }\n const lnx = this.ln();\n return lnx.div(lnx.lambertw());\n }\n /*\n\nUnit tests for tetrate/iteratedexp/iteratedlog/layeradd10/layeradd/slog:\n(note: these won't be exactly precise with the new slog implementation, but that's okay)\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n var expected = first+both+1;\n var result = new Decimal(10).layeradd10(first).layeradd10(both).slog();\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n first += both;\n var expected = first-both+1;\n var result = new Decimal(10).layeradd10(first).layeradd10(-both).slog();\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n var base = Math.random()*8+2;\n var expected = first+both+1;\n var result = new Decimal(base).layeradd(first, base).layeradd(both, base).slog(base);\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var first = Math.random()*100;\n var both = Math.random()*100;\n var base = Math.random()*8+2;\n first += both;\n var expected = first-both+1;\n var result = new Decimal(base).layeradd(first, base).layeradd(-both, base).slog(base);\n if (Number.isFinite(result.mag) && !Decimal.eq_tolerance(expected, result))\n {\n console.log(first + \", \" + both);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\nvar first = Math.round((Math.random()*30))/10;\nvar both = Math.round((Math.random()*30))/10;\nvar tetrateonly = Decimal.tetrate(10, first);\nvar tetrateandlog = Decimal.tetrate(10, first+both).iteratedlog(10, both);\nif (!Decimal.eq_tolerance(tetrateonly, tetrateandlog))\n{\n console.log(first + \", \" + both);\n}\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\nvar first = Math.round((Math.random()*30))/10;\nvar both = Math.round((Math.random()*30))/10;\nvar base = Math.random()*8+2;\nvar tetrateonly = Decimal.tetrate(base, first);\nvar tetrateandlog = Decimal.tetrate(base, first+both).iteratedlog(base, both);\nif (!Decimal.eq_tolerance(tetrateonly, tetrateandlog))\n{\n console.log(first + \", \" + both);\n}\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\nvar first = Math.round((Math.random()*30))/10;\nvar both = Math.round((Math.random()*30))/10;\nvar base = Math.random()*8+2;\nvar tetrateonly = Decimal.tetrate(base, first, base);\nvar tetrateandlog = Decimal.tetrate(base, first+both, base).iteratedlog(base, both);\nif (!Decimal.eq_tolerance(tetrateonly, tetrateandlog))\n{\n console.log(first + \", \" + both);\n}\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var xex = new Decimal(-0.3678794411710499+Math.random()*100);\n var x = Decimal.lambertw(xex);\n if (!Decimal.eq_tolerance(xex, x.mul(Decimal.exp(x))))\n {\n console.log(xex);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var xex = new Decimal(-0.3678794411710499+Math.exp(Math.random()*100));\n var x = Decimal.lambertw(xex);\n if (!Decimal.eq_tolerance(xex, x.mul(Decimal.exp(x))))\n {\n console.log(xex);\n }\n}\n\nfor (var i = 0; i < 1000; ++i)\n{\n var a = Decimal.randomDecimalForTesting(Math.random() > 0.5 ? 0 : 1);\n var b = Decimal.randomDecimalForTesting(Math.random() > 0.5 ? 0 : 1);\n if (Math.random() > 0.5) { a = a.recip(); }\n if (Math.random() > 0.5) { b = b.recip(); }\n var c = a.add(b).toNumber();\n if (Number.isFinite(c) && !Decimal.eq_tolerance(c, a.toNumber()+b.toNumber()))\n {\n console.log(a + \", \" + b);\n }\n}\n\nfor (var i = 0; i < 100; ++i)\n{\n var a = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n var b = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n if (Math.random() > 0.5) { a = a.recip(); }\n if (Math.random() > 0.5) { b = b.recip(); }\n var c = a.mul(b).toNumber();\n if (Number.isFinite(c) && Number.isFinite(a.toNumber()) && Number.isFinite(b.toNumber()) && a.toNumber() != 0 && b.toNumber() != 0 && c != 0 && !Decimal.eq_tolerance(c, a.toNumber()*b.toNumber()))\n {\n console.log(\"Test 1: \" + a + \", \" + b);\n }\n else if (!Decimal.mul(a.recip(), b.recip()).eq_tolerance(Decimal.mul(a, b).recip()))\n {\n console.log(\"Test 3: \" + a + \", \" + b);\n }\n}\n\nfor (var i = 0; i < 10; ++i)\n{\n var a = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n var b = Decimal.randomDecimalForTesting(Math.round(Math.random()*4));\n if (Math.random() > 0.5 && a.sign !== 0) { a = a.recip(); }\n if (Math.random() > 0.5 && b.sign !== 0) { b = b.recip(); }\n var c = a.pow(b);\n var d = a.root(b.recip());\n var e = a.pow(b.recip());\n var f = a.root(b);\n\n if (!c.eq_tolerance(d) && a.sign !== 0 && b.sign !== 0)\n {\n console.log(\"Test 1: \" + a + \", \" + b);\n }\n if (!e.eq_tolerance(f) && a.sign !== 0 && b.sign !== 0)\n {\n console.log(\"Test 2: \" + a + \", \" + b);\n }\n}\n\nfor (var i = 0; i < 10; ++i)\n{\n var a = Math.round(Math.random()*18-9);\n var b = Math.round(Math.random()*100-50);\n var c = Math.round(Math.random()*18-9);\n var d = Math.round(Math.random()*100-50);\n console.log(\"Decimal.pow(Decimal.fromMantissaExponent(\" + a + \", \" + b + \"), Decimal.fromMantissaExponent(\" + c + \", \" + d + \")).toString()\");\n}\n\n*/\n\n //Pentation/pentate: The result of tetrating 'height' times in a row. An absurdly strong operator - Decimal.pentate(2, 4.28) and Decimal.pentate(10, 2.37) are already too huge for break_eternity.js!\n // https://en.wikipedia.org/wiki/Pentation\n public pentate(height = 2, payload: DecimalSource = FC_NN(1, 0, 1)): Decimal {\n payload = D(payload);\n const oldheight = height;\n height = Math.trunc(height);\n const fracheight = oldheight - height;\n\n //I have no idea if this is a meaningful approximation for pentation to continuous heights, but it is monotonic and continuous.\n if (fracheight !== 0) {\n if (payload.eq(Decimal.dOne)) {\n ++height;\n payload = new Decimal(fracheight);\n } else {\n if (this.eq(10)) {\n payload = payload.layeradd10(fracheight);\n } else {\n payload = payload.layeradd(fracheight, this);\n }\n }\n }\n\n for (let i = 0; i < height; ++i) {\n payload = this.tetrate(payload.toNumber());\n //bail if we're NaN\n if (!isFinite(payload.layer) || !isFinite(payload.mag)) {\n return payload.normalize();\n }\n //give up after 10 iterations if nothing is happening\n if (i > 10) {\n return payload;\n }\n }\n\n return payload;\n }\n\n // trig functions!\n public sin(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.sin(this.sign * this.mag));\n }\n return FC_NN(0, 0, 0);\n }\n\n public cos(): Decimal {\n if (this.mag < 0) {\n return Decimal.dOne;\n }\n if (this.layer === 0) {\n return D(Math.cos(this.sign * this.mag));\n }\n return FC_NN(0, 0, 0);\n }\n\n public tan(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.tan(this.sign * this.mag));\n }\n return FC_NN(0, 0, 0);\n }\n\n public asin(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.asin(this.sign * this.mag));\n }\n return FC_NN(Number.NaN, Number.NaN, Number.NaN);\n }\n\n public acos(): Decimal {\n if (this.mag < 0) {\n return D(Math.acos(this.toNumber()));\n }\n if (this.layer === 0) {\n return D(Math.acos(this.sign * this.mag));\n }\n return FC_NN(Number.NaN, Number.NaN, Number.NaN);\n }\n\n public atan(): this | Decimal {\n if (this.mag < 0) {\n return this;\n }\n if (this.layer === 0) {\n return D(Math.atan(this.sign * this.mag));\n }\n return D(Math.atan(this.sign * 1.8e308));\n }\n\n public sinh(): Decimal {\n return this.exp()\n .sub(this.negate().exp())\n .div(2);\n }\n\n public cosh(): Decimal {\n return this.exp()\n .add(this.negate().exp())\n .div(2);\n }\n\n public tanh(): Decimal {\n return this.sinh().div(this.cosh());\n }\n\n public asinh(): Decimal {\n return Decimal.ln(\n this.add(\n this.sqr()\n .add(1)\n .sqrt()\n )\n );\n }\n\n public acosh(): Decimal {\n return Decimal.ln(\n this.add(\n this.sqr()\n .sub(1)\n .sqrt()\n )\n );\n }\n\n public atanh(): Decimal {\n if (this.abs().gte(1)) {\n return FC_NN(Number.NaN, Number.NaN, Number.NaN);\n }\n\n return Decimal.ln(this.add(1).div(D(1).sub(this))).div(2);\n }\n\n /**\n * Joke function from Realm Grinder\n */\n public ascensionPenalty(ascensions: DecimalSource): Decimal {\n if (ascensions === 0) {\n return this;\n }\n\n return this.root(Decimal.pow(10, ascensions));\n }\n\n /**\n * Joke function from Cookie Clicker. It's 'egg'\n */\n public egg(): Decimal {\n return this.add(9);\n }\n\n public lessThanOrEqualTo(other: DecimalSource): boolean {\n return this.cmp(other) < 1;\n }\n\n public lessThan(other: DecimalSource): boolean {\n return this.cmp(other) < 0;\n }\n\n public greaterThanOrEqualTo(other: DecimalSource): boolean {\n return this.cmp(other) > -1;\n }\n\n public greaterThan(other: DecimalSource): boolean {\n return this.cmp(other) > 0;\n }\n\n // return Decimal;\n}\n\n// return Decimal;\n","import Decimal, { DecimalSource } from \"lib/break_eternity\";\nimport projInfo from \"data/projInfo.json\";\n\nexport default Decimal;\n\nconst decimalOne = new Decimal(1);\n\nexport function exponentialFormat(num: DecimalSource, precision: number, mantissa = true): string {\n let e = Decimal.log10(num).floor();\n let m = Decimal.div(num, Decimal.pow(10, e));\n if (m.toStringWithDecimalPlaces(precision) === \"10\") {\n m = decimalOne;\n e = e.add(1);\n }\n const eString = e.gte(1e9)\n ? format(e, Math.max(Math.max(precision, 3), projInfo.defaultDecimalsShown))\n : e.gte(10000)\n ? commaFormat(e, 0)\n : e.toStringWithDecimalPlaces(0);\n if (mantissa) {\n return m.toStringWithDecimalPlaces(precision) + \"e\" + eString;\n } else {\n return \"e\" + eString;\n }\n}\n\nexport function commaFormat(num: DecimalSource, precision: number): string {\n if (num === null || num === undefined) {\n return \"NaN\";\n }\n num = new Decimal(num);\n if (num.mag < 0.001) {\n return (0).toFixed(precision);\n }\n const init = num.toStringWithDecimalPlaces(precision);\n const portions = init.split(\".\");\n portions[0] = portions[0].replace(/(\\d)(?=(\\d\\d\\d)+(?!\\d))/g, \"$1,\");\n if (portions.length == 1) return portions[0];\n return portions[0] + \".\" + portions[1];\n}\n\nexport function regularFormat(num: DecimalSource, precision: number): string {\n if (num === null || num === undefined) {\n return \"NaN\";\n }\n num = new Decimal(num);\n if (num.mag < 0.0001) {\n return (0).toFixed(precision);\n }\n if (num.mag < 0.1 && precision !== 0) {\n precision = Math.max(\n Math.max(precision, num.log10().negate().ceil().toNumber()),\n projInfo.defaultDecimalsShown\n );\n }\n return num.toStringWithDecimalPlaces(precision);\n}\n\nconst eeee1000 = new Decimal(\"eeee1000\");\nconst e100000 = new Decimal(\"e100000\");\nconst e1000 = new Decimal(\"e1000\");\nconst e9 = new Decimal(1e9);\nconst e6 = new Decimal(1e6);\nconst e3 = new Decimal(1e3);\nconst nearOne = new Decimal(0.98);\nconst thousandth = new Decimal(0.001);\nconst zero = new Decimal(0);\nexport function format(num: DecimalSource, precision?: number, small?: boolean): string {\n if (precision == null) precision = projInfo.defaultDecimalsShown;\n small = small ?? projInfo.defaultShowSmall;\n num = new Decimal(num);\n if (isNaN(num.sign) || isNaN(num.layer) || isNaN(num.mag)) {\n return \"NaN\";\n }\n if (num.sign < 0) {\n return \"-\" + format(num.neg(), precision);\n }\n if (num.mag === Number.POSITIVE_INFINITY) {\n return \"Infinity\";\n }\n if (num.gte(eeee1000)) {\n const slog = num.slog();\n if (slog.gte(e6)) {\n return \"F\" + format(slog.floor());\n } else {\n return (\n Decimal.pow(10, slog.sub(slog.floor())).toStringWithDecimalPlaces(3) +\n \"F\" +\n commaFormat(slog.floor(), 0)\n );\n }\n } else if (num.gte(e100000)) {\n return exponentialFormat(num, 0, false);\n } else if (num.gte(e1000)) {\n return exponentialFormat(num, 0);\n } else if (num.gte(e9)) {\n return exponentialFormat(num, precision);\n } else if (num.gte(e3)) {\n return commaFormat(num, 0);\n } else if (num.gte(thousandth) || !small) {\n return regularFormat(num, precision);\n } else if (num.eq(zero)) {\n return (0).toFixed(precision);\n }\n\n num = invertOOM(num);\n if (num.lt(e1000)) {\n const val = exponentialFormat(num, precision);\n return val.replace(/([^(?:e|F)]*)$/, \"-$1\");\n } else {\n return format(num, precision) + \"⁻¹\";\n }\n}\n\nexport function formatWhole(num: DecimalSource): string {\n num = new Decimal(num);\n if (num.sign < 0) {\n return \"-\" + formatWhole(num.neg());\n }\n if (num.gte(e9)) {\n return format(num);\n }\n if (num.lte(nearOne) && !num.eq(zero)) {\n return format(num);\n }\n return format(num, 0);\n}\n\nexport function formatTime(seconds: DecimalSource): string {\n if (Decimal.lt(seconds, 0)) {\n return \"-\" + formatTime(Decimal.neg(seconds));\n }\n if (Decimal.gt(seconds, 2 ** 51)) {\n // integer precision limit\n return format(Decimal.div(seconds, 31536000)) + \"y\";\n }\n seconds = new Decimal(seconds).toNumber();\n if (seconds < 60) {\n return format(seconds) + \"s\";\n } else if (seconds < 3600) {\n return formatWhole(Math.floor(seconds / 60)) + \"m \" + format(seconds % 60) + \"s\";\n } else if (seconds < 86400) {\n return (\n formatWhole(Math.floor(seconds / 3600)) +\n \"h \" +\n formatWhole(Math.floor(seconds / 60) % 60) +\n \"m \" +\n formatWhole(seconds % 60) +\n \"s\"\n );\n } else if (seconds < 31536000) {\n return (\n formatWhole(Math.floor(seconds / 84600) % 365) +\n \"d \" +\n formatWhole(Math.floor(seconds / 3600) % 24) +\n \"h \" +\n formatWhole(Math.floor(seconds / 60) % 60) +\n \"m\"\n );\n } else {\n return (\n formatWhole(Math.floor(seconds / 31536000)) +\n \"y \" +\n formatWhole(Math.floor(seconds / 84600) % 365) +\n \"d \" +\n formatWhole(Math.floor(seconds / 3600) % 24) +\n \"h\"\n );\n }\n}\n\nexport function toPlaces(x: DecimalSource, precision: number, maxAccepted: DecimalSource): string {\n x = new Decimal(x);\n let result = x.toStringWithDecimalPlaces(precision);\n if (new Decimal(result).gte(maxAccepted)) {\n result = Decimal.sub(maxAccepted, Math.pow(0.1, precision)).toStringWithDecimalPlaces(\n precision\n );\n }\n return result;\n}\n\n// Will also display very small numbers\nexport function formatSmall(x: DecimalSource, precision?: number): string {\n return format(x, precision, true);\n}\n\nexport function invertOOM(x: DecimalSource): Decimal {\n let e = Decimal.log10(x).ceil();\n const m = Decimal.div(x, Decimal.pow(10, e));\n e = e.neg();\n x = new Decimal(10).pow(e).times(m);\n\n return x;\n}\n","// Import Decimal and numberUtils from a different file to globally change which big num library gets used\n// This way switching out big number libraries just needs to happen here, not every file that needs big numbers\nimport { DecimalSource as RawDecimalSource } from \"lib/break_eternity\";\nimport Decimal, * as numberUtils from \"util/break_eternity\";\n\nexport const {\n exponentialFormat,\n commaFormat,\n regularFormat,\n format,\n formatWhole,\n formatTime,\n toPlaces,\n formatSmall,\n invertOOM\n} = numberUtils;\n\nexport type DecimalSource = RawDecimalSource;\n\nwindow.Decimal = Decimal;\nwindow.exponentialFormat = exponentialFormat;\nwindow.commaFormat = commaFormat;\nwindow.regularFormat = regularFormat;\nwindow.format = format;\nwindow.formatWhole = formatWhole;\nwindow.formatTime = formatTime;\nwindow.toPlaces = toPlaces;\nwindow.formatSmall = formatSmall;\nwindow.invertOOM = invertOOM;\n\nexport default Decimal;\n","export type WithRequired<T, K extends keyof T> = T & { [P in K]-?: T[P] };\n\n// Reference:\n// https://stackoverflow.com/questions/7225407/convert-camelcasetext-to-sentence-case-text\nexport function camelToTitle(camel: string): string {\n let title = camel.replace(/([A-Z])/g, \" $1\");\n title = title.charAt(0).toUpperCase() + title.slice(1);\n return title;\n}\n\nexport function isPlainObject(object: unknown): boolean {\n return Object.prototype.toString.call(object) === \"[object Object]\";\n}\n\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport function isFunction(func: unknown): func is Function {\n return typeof func === \"function\";\n}\n\nexport enum Direction {\n Up = \"Up\",\n Down = \"Down\",\n Left = \"Left\",\n Right = \"Right\",\n Default = \"Up\"\n}\n","import { computed, Ref } from \"vue\";\nimport { isFunction } from \"./common\";\n\nexport const DoNotCache = Symbol(\"DoNotCache\");\n\nexport type Computable<T> = T | Ref<T> | (() => T);\nexport type ProcessedComputable<T> = T | Ref<T>;\nexport type GetComputableType<T> = T extends { [DoNotCache]: true }\n ? T\n : T extends () => infer S\n ? Ref<S>\n : undefined extends T\n ? undefined\n : T;\nexport type GetComputableTypeWithDefault<T, S> = undefined extends T\n ? S\n : GetComputableType<NonNullable<T>>;\nexport type UnwrapComputableType<T> = T extends Ref<infer S> ? S : T extends () => infer S ? S : T;\n\nexport type ComputableKeysOf<T> = Pick<\n T,\n {\n [K in keyof T]: T[K] extends Computable<unknown> ? K : never;\n }[keyof T]\n>;\n\n// TODO fix the typing of this function, such that casting isn't necessary and can be used to\n// detect if a createX function is validly written\nexport function processComputable<T, S extends keyof ComputableKeysOf<T>>(\n obj: T,\n key: S\n): asserts obj is T & { [K in S]: ProcessedComputable<UnwrapComputableType<T[S]>> } {\n const computable = obj[key];\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (isFunction(computable) && computable.length === 0 && !(computable as any)[DoNotCache]) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n obj[key] = computed(computable.bind(obj));\n }\n}\n\nexport function convertComputable<T>(obj: Computable<T>): ProcessedComputable<T> {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n if (isFunction(obj) && !(obj as any)[DoNotCache]) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n obj = computed(obj);\n }\n return obj as ProcessedComputable<T>;\n}\n","import Decimal from \"./bignum\";\n\nexport const ProxyState = Symbol(\"ProxyState\");\nexport const ProxyPath = Symbol(\"ProxyPath\");\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport type ProxiedWithState<T> = NonNullable<T> extends Record<PropertyKey, any>\n ? NonNullable<T> extends Decimal\n ? T\n : {\n [K in keyof T]: ProxiedWithState<T[K]>;\n } & {\n [ProxyState]: T;\n [ProxyPath]: string[];\n }\n : T;\n\n// Takes a function that returns an object and pretends to be that object\n// Note that the object is lazily calculated\nexport function createLazyProxy<T extends object, S>(\n objectFunc: (baseObject: S) => T & S,\n baseObject: S = {} as S\n): T {\n const obj: S & Partial<T> = baseObject;\n let calculated = false;\n function calculateObj(): T {\n if (!calculated) {\n Object.assign(obj, objectFunc(obj));\n calculated = true;\n }\n return obj as S & T;\n }\n\n return new Proxy(obj, {\n get(target, key) {\n if (key === ProxyState) {\n return calculateObj();\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return (calculateObj() as any)[key];\n },\n set(target, key, value) {\n // TODO give warning about this? It should only be done with caution\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (calculateObj() as any)[key] = value;\n return true;\n },\n has(target, key) {\n if (key === ProxyState) {\n return true;\n }\n return Reflect.has(calculateObj(), key);\n },\n ownKeys() {\n return Reflect.ownKeys(calculateObj());\n },\n getOwnPropertyDescriptor(target, key) {\n if (!calculated) {\n Object.assign(obj, objectFunc(obj));\n calculated = true;\n }\n return Object.getOwnPropertyDescriptor(target, key);\n }\n }) as S & T;\n}\n","import projInfo from \"data/projInfo.json\";\nimport player, { Player, PlayerData, stringifySave } from \"game/player\";\nimport settings, { loadSettings } from \"game/settings\";\nimport { ProxyState } from \"./proxies\";\nimport LZString from \"lz-string\";\n\nexport function setupInitialStore(player: Partial<PlayerData> = {}): Player {\n return Object.assign(\n {\n id: `${projInfo.id}-0`,\n name: \"Default Save\",\n tabs: projInfo.initialTabs.slice(),\n time: Date.now(),\n autosave: true,\n offlineProd: true,\n offlineTime: 0,\n timePlayed: 0,\n keepGoing: false,\n modID: projInfo.id,\n modVersion: projInfo.versionNumber,\n layers: {}\n },\n player\n ) as Player;\n}\n\nexport function save(playerData?: PlayerData): string {\n const stringifiedSave = LZString.compressToUTF16(\n stringifySave(playerData ?? player[ProxyState])\n );\n localStorage.setItem((playerData ?? player[ProxyState]).id, stringifiedSave);\n return stringifiedSave;\n}\n\nexport async function load(): Promise<void> {\n // Load global settings\n loadSettings();\n\n try {\n let save = localStorage.getItem(settings.active);\n if (save == null) {\n await loadSave(newSave());\n return;\n }\n if (save[0] === \"{\") {\n // plaintext. No processing needed\n } else if (save[0] === \"e\") {\n // Assumed to be base64, which starts with e\n save = decodeURIComponent(escape(atob(save)));\n } else if (save[0] === \"ᯡ\") {\n // Assumed to be lz, which starts with ᯡ\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n save = LZString.decompressFromUTF16(save)!;\n } else {\n throw `Unable to determine save encoding`;\n }\n const player = JSON.parse(save);\n if (player.modID !== projInfo.id) {\n await loadSave(newSave());\n return;\n }\n player.id = settings.active;\n await loadSave(player);\n } catch (e) {\n console.error(\"Failed to load save. Falling back to new save.\\n\", e);\n await loadSave(newSave());\n }\n}\n\nexport function newSave(): PlayerData {\n const id = getUniqueID();\n const player = setupInitialStore({ id });\n save(player);\n\n settings.saves.push(id);\n\n return player;\n}\n\nexport function getUniqueID(): string {\n let id,\n i = 0;\n do {\n id = `${projInfo.id}-${i++}`;\n } while (localStorage.getItem(id));\n return id;\n}\n\nexport async function loadSave(playerObj: Partial<PlayerData>): Promise<void> {\n console.info(\"Loading save\", playerObj);\n const { layers, removeLayer, addLayer } = await import(\"game/layers\");\n const { fixOldSave, getInitialLayers } = await import(\"data/projEntry\");\n\n for (const layer in layers) {\n const l = layers[layer];\n if (l) {\n removeLayer(l);\n }\n }\n getInitialLayers(playerObj).forEach(layer => addLayer(layer, playerObj));\n\n playerObj = setupInitialStore(playerObj);\n if (playerObj.offlineProd && playerObj.time) {\n if (playerObj.offlineTime == undefined) playerObj.offlineTime = 0;\n playerObj.offlineTime += (Date.now() - playerObj.time) / 1000;\n }\n playerObj.time = Date.now();\n if (playerObj.modVersion !== projInfo.versionNumber) {\n fixOldSave(playerObj.modVersion, playerObj);\n }\n\n Object.assign(player, playerObj);\n settings.active = player.id;\n}\n\nsetInterval(() => {\n if (player.autosave) {\n save();\n }\n}, 1000);\nwindow.onbeforeunload = () => {\n if (player.autosave) {\n save();\n }\n};\nwindow.save = save;\nexport const hardReset = (window.hardReset = async () => {\n await loadSave(newSave());\n});\n","<template>\n <transition appear>\n <svg\n id=\"eaRe02fYmMp1\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\n viewBox=\"0 0 228 521\"\n shape-rendering=\"geometricPrecision\"\n text-rendering=\"geometricPrecision\"\n >\n <g id=\"P\">\n <path\n d=\"m 101,512.877 c -17.547386,-5.3519 -50.794681,-10.26296 -80,0 10.737201,-217.43031 5.7244,-300.999 0,-464.9995 0,0 46.6144,-37.1164 80,-42.00002 33.386,-4.883633 86.025,10.45942 120,50.00002 5,30 -4.353,106.6565 -44,156.0005 -34.149,42.5 -130,38.48 -130,92.999 0,102 54,208 54,208 z\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 10;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"trunk\"\n class=\"svg-elem-1\"\n ></path>\n <path\n d=\"M 221,55.8775 C 209.023,126.453 185.39,166.835 158.997,191.5 93.783098,252.444 11.718998,217.436 46.999998,304.877\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 5;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"vine2\"\n class=\"svg-elem-2\"\n ></path>\n <path\n d=\"m 194.5,188 c -11.225,4.447 -19.066,5.134 -35.503,3.5\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 5;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"short_vine4\"\n class=\"svg-elem-3\"\n ></path>\n <path\n d=\"M 73.499996,246.5 C 111.145,245.626 127.011,238.775 156.5,228\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 5;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"short_vine3\"\n class=\"svg-elem-4\"\n ></path>\n <path\n d=\"M 221,55.8775 C 169.5,17.8262 86.0943,44.9468 47,107 c -4.743,7.528 -7.1041,15.373 -8.326,24 -3.5282,24.91 2.4426,56.34 -12.0011,105.5\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 5;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"vine1\"\n class=\"svg-elem-5\"\n ></path>\n <path\n d=\"M 21,47.8775 38.674,131\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 5;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"short_vine2\"\n class=\"svg-elem-6\"\n ></path>\n <path\n d=\"m 3,326.5 c 13.1783,22.208 16.4863,42.834 21.6997,81\"\n style=\"\n display: inline;\n fill: none;\n stroke: rgb(163, 190, 140);\n stroke-width: 5;\n stroke-linecap: round;\n stroke-miterlimit: 16;\n \"\n id=\"short_vine1\"\n class=\"svg-elem-7\"\n ></path>\n </g>\n </svg>\n </transition>\n</template>\n\n<style scoped>\nsvg {\n background: #2e3440;\n}\n\n/***************************************************\n * Generated by SVG Artista on 1/7/2022, 4:39:47 PM\n * MIT license (https://opensource.org/licenses/MIT)\n * W. https://svgartista.net\n **************************************************/\n\nsvg .svg-elem-1 {\n stroke-dashoffset: 2648.758056640625px;\n stroke-dasharray: 1324.3790283203125px;\n transition: stroke-dashoffset 1s cubic-bezier(0.47, 0, 0.745, 0.715) 0s;\n}\n\nsvg.v-enter-from .svg-elem-1,\nsvg.v-leave-to .svg-elem-1 {\n stroke-dashoffset: 1324.3790283203125px;\n}\n\nsvg .svg-elem-2 {\n stroke-dashoffset: 680.4000854492188px;\n stroke-dasharray: 340.2000427246094px;\n transition: stroke-dashoffset 1s ease-out 0.4s;\n}\n\nsvg.v-enter-from .svg-elem-2,\nsvg.v-leave-to .svg-elem-2 {\n stroke-dashoffset: 340.2000427246094px;\n}\n\nsvg .svg-elem-3 {\n stroke-dashoffset: 76.21031951904297px;\n stroke-dasharray: 38.105159759521484px;\n transition: stroke-dashoffset 1s ease-out 0.8s;\n}\n\nsvg.v-enter-from .svg-elem-3,\nsvg.v-leave-to .svg-elem-3 {\n stroke-dashoffset: 38.105159759521484px;\n}\n\nsvg .svg-elem-4 {\n stroke-dashoffset: 175.18072509765625px;\n stroke-dasharray: 87.59036254882812px;\n transition: stroke-dashoffset 1s cubic-bezier(0.47, 0, 0.745, 0.715) 0.36s;\n}\n\nsvg.v-enter-from .svg-elem-4,\nsvg.v-leave-to .svg-elem-4 {\n stroke-dashoffset: 87.59036254882812px;\n}\n\nsvg .svg-elem-5 {\n stroke-dashoffset: 671.9447021484375px;\n stroke-dasharray: 335.97235107421875px;\n transition: stroke-dashoffset 1s ease-out 0.8s;\n}\n\nsvg.v-enter-from .svg-elem-5,\nsvg.v-leave-to .svg-elem-5 {\n stroke-dashoffset: 335.97235107421875px;\n}\n\nsvg .svg-elem-6 {\n stroke-dashoffset: 173.96141052246094px;\n stroke-dasharray: 86.98070526123047px;\n transition: stroke-dashoffset 1s ease-out 1s;\n}\n\nsvg.v-enter-from .svg-elem-6,\nsvg.v-leave-to .svg-elem-6 {\n stroke-dashoffset: 86.98070526123047px;\n}\n\nsvg .svg-elem-7 {\n stroke-dashoffset: 172.99151611328125px;\n stroke-dasharray: 86.49575805664062px;\n transition: stroke-dashoffset 1s ease-out 0.85s;\n}\n\nsvg.v-enter-from .svg-elem-7,\nsvg.v-leave-to .svg-elem-7 {\n stroke-dashoffset: 86.49575805664062px;\n}\n</style>\n","import { render } from \"./Profectus.vue?vue&type=template&id=07150322&scoped=true\"\nconst script = {}\n\nimport \"./Profectus.vue?vue&type=style&index=0&id=07150322&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-07150322\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n width: { default: \"8px\" },\n height: { default: \"17px\" }\n },\n setup(__props: any) {\n\n\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n style: _normalizeStyle({ width: __props.width, height: __props.height })\n }, null, 4))\n}\n}\n\n})","import script from \"./Spacer.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Spacer.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import Decimal, { DecimalSource, format, formatWhole } from \"util/bignum\";\nimport { computed, ComputedRef, isRef, ref, Ref, watch } from \"vue\";\nimport { globalBus } from \"game/events\";\nimport { State, persistent } from \"game/persistence\";\n\nexport interface Resource<T = DecimalSource> extends Ref<T> {\n displayName: string;\n precision: number;\n small?: boolean;\n}\n\nexport function createResource<T extends State>(\n defaultValue: T | Ref<T>,\n displayName = \"points\",\n precision = 0,\n small = undefined\n): Resource<T> {\n const resource: Partial<Resource<T>> = isRef(defaultValue)\n ? defaultValue\n : persistent(defaultValue);\n resource.displayName = displayName;\n resource.precision = precision;\n resource.small = small;\n return resource as Resource<T>;\n}\n\nexport function trackBest(resource: Resource): Ref<DecimalSource> {\n const best = persistent(resource.value);\n watch(resource, amount => {\n if (Decimal.gt(amount, best.value)) {\n best.value = amount;\n }\n });\n return best;\n}\n\nexport function trackTotal(resource: Resource): Ref<DecimalSource> {\n const total = persistent(resource.value);\n watch(resource, (amount, prevAmount) => {\n if (Decimal.gt(amount, prevAmount)) {\n total.value = Decimal.add(total.value, Decimal.sub(amount, prevAmount));\n }\n });\n return total;\n}\n\nconst tetra8 = new Decimal(\"10^^8\");\nconst e100 = new Decimal(\"1e100\");\nexport function trackOOMPS(\n resource: Resource,\n pointGain?: ComputedRef<DecimalSource>\n): Ref<string> {\n const oomps = ref<DecimalSource>(0);\n const oompsMag = ref(0);\n const lastPoints = ref<DecimalSource>(0);\n\n globalBus.on(\"update\", diff => {\n oompsMag.value = 0;\n if (Decimal.lte(resource.value, e100)) {\n lastPoints.value = resource.value;\n return;\n }\n\n let curr = resource.value;\n let prev = lastPoints.value;\n lastPoints.value = curr;\n if (Decimal.gt(curr, prev)) {\n if (Decimal.gte(curr, tetra8)) {\n curr = Decimal.slog(curr, 1e10);\n prev = Decimal.slog(prev, 1e10);\n oomps.value = curr.sub(prev).div(diff);\n oompsMag.value = -1;\n } else {\n while (\n Decimal.div(curr, prev).log(10).div(diff).gte(\"100\") &&\n oompsMag.value <= 5 &&\n Decimal.gt(prev, 0)\n ) {\n curr = Decimal.log10(curr);\n prev = Decimal.log10(prev);\n oomps.value = curr.sub(prev).div(diff);\n oompsMag.value++;\n }\n }\n }\n });\n\n const oompsString = computed(() => {\n if (oompsMag.value === 0) {\n return pointGain\n ? format(pointGain.value, resource.precision, resource.small) +\n \" \" +\n resource.displayName +\n \"/s\"\n : \"\";\n }\n return (\n format(oomps.value) +\n \" OOM\" +\n (oompsMag.value < 0 ? \"^OOM\" : \"^\" + oompsMag.value) +\n \"s/sec\"\n );\n });\n return oompsString;\n}\n\nexport function displayResource(resource: Resource, overrideAmount?: DecimalSource): string {\n const amount = overrideAmount ?? resource.value;\n if (Decimal.eq(resource.precision, 0)) {\n return formatWhole(amount);\n }\n return format(amount, resource.precision, resource.small);\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, Fragment as _Fragment, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Links = _resolveComponent(\"Links\")!\n\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.nodesComp))),\n (_ctx.leftNodesComp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.leftNodesComp), { key: 0 }))\n : _createCommentVNode(\"\", true),\n (_ctx.rightNodesComp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.rightNodesComp), { key: 1 }))\n : _createCommentVNode(\"\", true),\n (_ctx.branches)\n ? (_openBlock(), _createBlock(_component_Links, {\n key: 2,\n links: _ctx.unref(_ctx.branches)\n }, null, 8, [\"links\"]))\n : _createCommentVNode(\"\", true)\n ], 64))\n}","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, mergeProps as _mergeProps, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = [\"x1\", \"y1\", \"x2\", \"y2\"]\n\nimport { Link } from \"features/links/links\";\nimport { FeatureNode } from \"game/layers\";\nimport { computed, toRefs } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n link: null,\n startNode: null,\n endNode: null,\n boundingRect: null\n },\n setup(__props: any) {\n\nconst _props = __props as {\n link: Link;\n startNode: FeatureNode;\n endNode: FeatureNode;\n boundingRect: DOMRect | undefined;\n}\n\n\nconst props = toRefs(_props);\n\nconst startPosition = computed(() => {\n const rect = props.startNode.value.rect;\n const boundingRect = props.boundingRect.value;\n const position = boundingRect\n ? {\n x: rect.x + rect.width / 2 - boundingRect.x,\n y: rect.y + rect.height / 2 - boundingRect.y\n }\n : { x: 0, y: 0 };\n if (props.link.value.offsetStart) {\n position.x += props.link.value.offsetStart.x;\n position.y += props.link.value.offsetStart.y;\n }\n return position;\n});\n\nconst endPosition = computed(() => {\n const rect = props.endNode.value.rect;\n const boundingRect = props.boundingRect.value;\n const position = boundingRect\n ? {\n x: rect.x + rect.width / 2 - boundingRect.x,\n y: rect.y + rect.height / 2 - boundingRect.y\n }\n : { x: 0, y: 0 };\n if (props.link.value.offsetEnd) {\n position.x += props.link.value.offsetEnd.x;\n position.y += props.link.value.offsetEnd.y;\n }\n return position;\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"line\", _mergeProps({\n \"stroke-width\": \"15px\",\n stroke: \"white\"\n }, __props.link, {\n x1: _unref(startPosition).x,\n y1: _unref(startPosition).y,\n x2: _unref(endPosition).x,\n y2: _unref(endPosition).y\n }), null, 16, _hoisted_1))\n}\n}\n\n})","import script from \"./Link.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Link.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, createBlock as _createBlock, normalizeProps as _normalizeProps, guardReactiveProps as _guardReactiveProps, mergeProps as _mergeProps, createCommentVNode as _createCommentVNode, createElementVNode as _createElementVNode } from \"vue\"\n\nimport { Link } from \"features/links/links\";\nimport { BoundsInjectionKey, NodesInjectionKey } from \"game/layers\";\nimport { computed, inject, ref, toRef, watch } from \"vue\";\nimport LinkVue from \"./Link.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n links: null\n },\n setup(__props: any) {\n\nconst _props = __props as { links?: Link[] }\n\n\nconst links = toRef(_props, \"links\");\n\nconst resizeListener = ref<Element | null>(null);\n\n// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\nconst nodes = inject(NodesInjectionKey)!;\n// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\nconst outerBoundingRect = inject(BoundsInjectionKey)!;\nconst boundingRect = ref<DOMRect | undefined>(undefined);\nwatch(\n [outerBoundingRect],\n () => (boundingRect.value = resizeListener.value?.getBoundingClientRect())\n);\n\nconst validLinks = computed(() => {\n const n = nodes.value;\n return (\n links.value?.filter(link => n[link.startNode.id]?.rect && n[link.startNode.id]?.rect) ?? []\n );\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (_unref(validLinks))\n ? (_openBlock(), _createElementBlock(\"svg\", _normalizeProps(_mergeProps({ key: 0 }, _ctx.$attrs)), [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_unref(validLinks), (link, index) => {\n return (_openBlock(), _createBlock(LinkVue, {\n key: index,\n link: link,\n boundingRect: boundingRect.value,\n startNode: _unref(nodes)[link.startNode.id]!,\n endNode: _unref(nodes)[link.endNode.id]!\n }, null, 8, [\"link\", \"boundingRect\", \"startNode\", \"endNode\"]))\n }), 128))\n ], 16))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", {\n ref_key: \"resizeListener\",\n ref: resizeListener,\n class: \"resize-listener\"\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./Links.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Links.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Links.vue?vue&type=style&index=0&id=2bbc19c2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-2bbc19c2\"]])\n\nexport default __exports__","\nimport \"components/common/table.css\";\nimport { GenericTreeNode, TreeBranch } from \"features/trees/tree\";\nimport { coerceComponent, processedPropType, renderJSX, unwrapRef } from \"util/vue\";\nimport { Component, defineComponent, shallowRef, toRefs, unref, watchEffect } from \"vue\";\nimport Links from \"features/links/Links.vue\";\nimport { jsx } from \"features/feature\";\n\nexport default defineComponent({\n props: {\n nodes: {\n type: processedPropType<GenericTreeNode[][]>(Array),\n required: true\n },\n leftSideNodes: processedPropType<GenericTreeNode[]>(Array),\n rightSideNodes: processedPropType<GenericTreeNode[]>(Array),\n branches: processedPropType<TreeBranch[]>(Array)\n },\n components: { Links },\n setup(props) {\n const { nodes, leftSideNodes, rightSideNodes } = toRefs(props);\n\n const nodesComp = shallowRef<Component | \"\">();\n watchEffect(() => {\n const currNodes = unwrapRef(nodes);\n nodesComp.value = coerceComponent(\n jsx(() => (\n <>\n {currNodes.map(row => (\n <span class=\"row tree-row\" style=\"margin: 50px auto;\">\n {row.map(renderJSX)}\n </span>\n ))}\n </>\n ))\n );\n });\n\n const leftNodesComp = shallowRef<Component | \"\">();\n watchEffect(() => {\n const currNodes = unwrapRef(leftSideNodes);\n leftNodesComp.value = currNodes\n ? coerceComponent(\n jsx(() => (\n <span class=\"left-side-nodes small\">{currNodes.map(renderJSX)}</span>\n ))\n )\n : \"\";\n });\n\n const rightNodesComp = shallowRef<Component | \"\">();\n watchEffect(() => {\n const currNodes = unwrapRef(rightSideNodes);\n rightNodesComp.value = currNodes\n ? coerceComponent(\n jsx(() => <span class=\"side-nodes small\">{currNodes.map(renderJSX)}</span>)\n )\n : \"\";\n });\n\n return {\n unref,\n nodesComp,\n leftNodesComp,\n rightNodesComp\n };\n }\n});\n","import { render } from \"./Tree.vue?vue&type=template&id=aa87859c&scoped=true&ts=true\"\nimport script from \"./Tree.vue?vue&type=script&lang=tsx\"\nexport * from \"./Tree.vue?vue&type=script&lang=tsx\"\n\nimport \"./Tree.vue?vue&type=style&index=0&id=aa87859c&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-aa87859c\"]])\n\nexport default __exports__","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle({ visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined }),\n class: _normalizeClass({\n treeNode: true,\n can: _ctx.unref(_ctx.canClick),\n ..._ctx.unref(_ctx.classes)\n }),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.onClick && _ctx.onClick(...args))),\n onMousedown: _cache[1] || (_cache[1] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onMouseleave: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onMouseup: _cache[3] || (_cache[3] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchstartPassive: _cache[4] || (_cache[4] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onTouchendPassive: _cache[5] || (_cache[5] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchcancelPassive: _cache[6] || (_cache[6] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args)))\n }, [\n _createElementVNode(\"div\", {\n style: _normalizeStyle([\n {\n backgroundColor: _ctx.unref(_ctx.color),\n boxShadow: `-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 20px ${_ctx.unref(\n _ctx.glowColor\n )}`\n },\n _ctx.unref(_ctx.style) ?? []\n ])\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp))))\n ], 4),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 38))\n : _createCommentVNode(\"\", true)\n}","import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { RegisterNodeInjectionKey, UnregisterNodeInjectionKey } from \"game/layers\";\nimport { computed, inject, onUnmounted, ref, toRefs, unref, watch } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n id: null\n },\n setup(__props: any) {\n\nconst _props = __props as { id: string }\n\n\nconst props = toRefs(_props);\n\nconst register = inject(RegisterNodeInjectionKey);\nconst unregister = inject(UnregisterNodeInjectionKey);\n\nconst node = ref<HTMLElement | null>(null);\nconst parentNode = computed(() => node.value && node.value.parentElement);\n\nif (register && unregister) {\n watch([parentNode, props.id], ([newNode, newID], [prevNode, prevID]) => {\n if (prevNode) {\n unregister(unref(prevID));\n }\n if (newNode) {\n register(newID, newNode);\n }\n });\n\n onUnmounted(() => unregister(unref(props.id)));\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"node\",\n ref_key: \"node\",\n ref: node\n }, null, 512))\n}\n}\n\n})","import script from \"./Node.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Node.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Node.vue?vue&type=style&index=0&id=63ded336&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-63ded336\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-c476c56a\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { key: 0 }\nconst _hoisted_2 = {\n key: 0,\n class: \"mark star\"\n}\nconst _hoisted_3 = [\"src\"]\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n mark: { type: [Boolean, String] }\n },\n setup(__props: any) {\n\n\n\nreturn (_ctx: any,_cache: any) => {\n return (__props.mark)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (__props.mark === true)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_2))\n : (_openBlock(), _createElementBlock(\"img\", {\n key: 1,\n class: \"mark\",\n src: __props.mark\n }, null, 8, _hoisted_3))\n ]))\n : _createCommentVNode(\"\", true)\n}\n}\n\n})","import script from \"./MarkNode.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./MarkNode.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./MarkNode.vue?vue&type=style&index=0&id=c476c56a&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-c476c56a\"]])\n\nexport default __exports__","\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport {\n computeOptionalComponent,\n isCoercableComponent,\n processedPropType,\n setupHoldToClick\n} from \"util/vue\";\nimport { defineComponent, PropType, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n display: processedPropType<CoercableComponent>(Object, String, Function),\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n onClick: Function as PropType<(e?: MouseEvent | TouchEvent) => void>,\n onHold: Function as PropType<VoidFunction>,\n color: processedPropType<string>(String),\n glowColor: processedPropType<string>(String),\n canClick: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n MarkNode,\n Node\n },\n setup(props) {\n const { onClick, onHold, display } = toRefs(props);\n\n const comp = computeOptionalComponent(display);\n\n const { start, stop } = setupHoldToClick(onClick, onHold);\n\n return {\n start,\n stop,\n comp,\n unref,\n Visibility,\n isCoercableComponent\n };\n }\n});\n","import { render } from \"./TreeNode.vue?vue&type=template&id=094cdcfe&scoped=true&ts=true\"\nimport script from \"./TreeNode.vue?vue&type=script&lang=ts\"\nexport * from \"./TreeNode.vue?vue&type=script&lang=ts\"\n\nimport \"./TreeNode.vue?vue&type=style&index=0&id=094cdcfe&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-094cdcfe\"]])\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { Link } from \"features/links/links\";\nimport { GenericReset } from \"features/reset\";\nimport { displayResource, Resource } from \"features/resources/resource\";\nimport TreeComponent from \"features/trees/Tree.vue\";\nimport TreeNodeComponent from \"features/trees/TreeNode.vue\";\nimport Decimal, { DecimalSource, format, formatWhole } from \"util/bignum\";\nimport {\n Computable,\n convertComputable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, ref, Ref, shallowRef, unref } from \"vue\";\n\nexport const TreeNodeType = Symbol(\"TreeNode\");\nexport const TreeType = Symbol(\"Tree\");\n\nexport interface TreeNodeOptions {\n visibility?: Computable<Visibility>;\n canClick?: Computable<boolean>;\n color?: Computable<string>;\n display?: Computable<CoercableComponent>;\n glowColor?: Computable<string>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n mark?: Computable<boolean | string>;\n reset?: GenericReset;\n onClick?: (e?: MouseEvent | TouchEvent) => void;\n onHold?: VoidFunction;\n}\n\nexport interface BaseTreeNode {\n id: string;\n type: typeof TreeNodeType;\n [Component]: typeof TreeNodeComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type TreeNode<T extends TreeNodeOptions> = Replace<\n T & BaseTreeNode,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n canClick: GetComputableTypeWithDefault<T[\"canClick\"], true>;\n color: GetComputableType<T[\"color\"]>;\n display: GetComputableType<T[\"display\"]>;\n glowColor: GetComputableType<T[\"glowColor\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n }\n>;\n\nexport type GenericTreeNode = Replace<\n TreeNode<TreeNodeOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canClick: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createTreeNode<T extends TreeNodeOptions>(\n optionsFunc?: OptionsFunc<T, TreeNode<T>, BaseTreeNode>\n): TreeNode<T> {\n return createLazyProxy(() => {\n const treeNode = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n treeNode.id = getUniqueID(\"treeNode-\");\n treeNode.type = TreeNodeType;\n treeNode[Component] = TreeNodeComponent;\n\n processComputable(treeNode as T, \"visibility\");\n setDefault(treeNode, \"visibility\", Visibility.Visible);\n processComputable(treeNode as T, \"canClick\");\n setDefault(treeNode, \"canClick\", true);\n processComputable(treeNode as T, \"color\");\n processComputable(treeNode as T, \"display\");\n processComputable(treeNode as T, \"glowColor\");\n processComputable(treeNode as T, \"classes\");\n processComputable(treeNode as T, \"style\");\n processComputable(treeNode as T, \"mark\");\n\n if (treeNode.onClick) {\n const onClick = treeNode.onClick.bind(treeNode);\n treeNode.onClick = function () {\n if (unref(treeNode.canClick)) {\n onClick();\n }\n };\n }\n if (treeNode.onHold) {\n const onHold = treeNode.onHold.bind(treeNode);\n treeNode.onHold = function () {\n if (unref(treeNode.canClick)) {\n onHold();\n }\n };\n }\n\n treeNode[GatherProps] = function (this: GenericTreeNode) {\n const {\n display,\n visibility,\n style,\n classes,\n onClick,\n onHold,\n color,\n glowColor,\n canClick,\n mark,\n id\n } = this;\n return {\n display,\n visibility,\n style,\n classes,\n onClick,\n onHold,\n color,\n glowColor,\n canClick,\n mark,\n id\n };\n };\n\n return treeNode as unknown as TreeNode<T>;\n });\n}\n\nexport interface TreeBranch extends Omit<Link, \"startNode\" | \"endNode\"> {\n startNode: GenericTreeNode;\n endNode: GenericTreeNode;\n}\n\nexport interface TreeOptions {\n visibility?: Computable<Visibility>;\n nodes: Computable<GenericTreeNode[][]>;\n leftSideNodes?: Computable<GenericTreeNode[]>;\n rightSideNodes?: Computable<GenericTreeNode[]>;\n branches?: Computable<TreeBranch[]>;\n resetPropagation?: ResetPropagation;\n onReset?: (node: GenericTreeNode) => void;\n}\n\nexport interface BaseTree {\n id: string;\n links: Ref<Link[]>;\n reset: (node: GenericTreeNode) => void;\n isResetting: Ref<boolean>;\n resettingNode: Ref<GenericTreeNode | null>;\n type: typeof TreeType;\n [Component]: typeof TreeComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Tree<T extends TreeOptions> = Replace<\n T & BaseTree,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n nodes: GetComputableType<T[\"nodes\"]>;\n leftSideNodes: GetComputableType<T[\"leftSideNodes\"]>;\n rightSideNodes: GetComputableType<T[\"rightSideNodes\"]>;\n branches: GetComputableType<T[\"branches\"]>;\n }\n>;\n\nexport type GenericTree = Replace<\n Tree<TreeOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createTree<T extends TreeOptions>(\n optionsFunc: OptionsFunc<T, Tree<T>, BaseTree>\n): Tree<T> {\n return createLazyProxy(() => {\n const tree = optionsFunc();\n tree.id = getUniqueID(\"tree-\");\n tree.type = TreeType;\n tree[Component] = TreeComponent;\n\n tree.isResetting = ref(false);\n tree.resettingNode = shallowRef(null);\n\n tree.reset = function (node) {\n const genericTree = tree as GenericTree;\n genericTree.isResetting.value = true;\n genericTree.resettingNode.value = node;\n genericTree.resetPropagation?.(genericTree, node);\n genericTree.onReset?.(node);\n genericTree.isResetting.value = false;\n genericTree.resettingNode.value = null;\n };\n tree.links = computed(() => {\n const genericTree = tree as GenericTree;\n return unref(genericTree.branches) ?? [];\n });\n\n processComputable(tree as T, \"visibility\");\n setDefault(tree, \"visibility\", Visibility.Visible);\n processComputable(tree as T, \"nodes\");\n processComputable(tree as T, \"leftSideNodes\");\n processComputable(tree as T, \"rightSideNodes\");\n processComputable(tree as T, \"branches\");\n\n tree[GatherProps] = function (this: GenericTree) {\n const { nodes, leftSideNodes, rightSideNodes, branches } = this;\n return { nodes, leftSideNodes, rightSideNodes, branches };\n };\n\n return tree as unknown as Tree<T>;\n });\n}\n\nexport type ResetPropagation = {\n (tree: GenericTree, resettingNode: GenericTreeNode): void;\n};\n\nexport const defaultResetPropagation = function (\n tree: GenericTree,\n resettingNode: GenericTreeNode\n): void {\n const nodes = unref(tree.nodes);\n const row = nodes.findIndex(nodes => nodes.includes(resettingNode)) - 1;\n for (let x = row; x >= 0; x--) {\n nodes[x].forEach(node => node.reset?.reset());\n }\n};\n\nexport const invertedResetPropagation = function (\n tree: GenericTree,\n resettingNode: GenericTreeNode\n): void {\n const nodes = unref(tree.nodes);\n const row = nodes.findIndex(nodes => nodes.includes(resettingNode)) + 1;\n for (let x = row; x < nodes.length; x++) {\n nodes[x].forEach(node => node.reset?.reset());\n }\n};\n\nexport const branchedResetPropagation = function (\n tree: GenericTree,\n resettingNode: GenericTreeNode\n): void {\n const visitedNodes = [resettingNode];\n let currentNodes = [resettingNode];\n if (tree.branches != null) {\n const branches = unref(tree.branches);\n while (currentNodes.length > 0) {\n const nextNodes: GenericTreeNode[] = [];\n currentNodes.forEach(node => {\n branches\n .filter(branch => branch.startNode === node || branch.endNode === node)\n .map(branch => {\n if (branch.startNode === node) {\n return branch.endNode;\n }\n return branch.startNode;\n })\n .filter(node => !visitedNodes.includes(node))\n .forEach(node => {\n // Check here instead of in the filter because this check's results may\n // change as we go through each node\n if (!nextNodes.includes(node)) {\n nextNodes.push(node);\n node.reset?.reset();\n }\n });\n });\n currentNodes = nextNodes;\n visitedNodes.push(...currentNodes);\n }\n }\n};\n\nexport function createResourceTooltip(\n resource: Resource,\n requiredResource: Resource | null = null,\n requirement: Computable<DecimalSource> = 0\n): Ref<string> {\n const req = convertComputable(requirement);\n return computed(() => {\n if (requiredResource == null || Decimal.gte(resource.value, unref(req))) {\n return displayResource(resource) + \" \" + resource.displayName;\n }\n return `Reach ${\n Decimal.eq(requiredResource.precision, 0)\n ? formatWhole(unref(req))\n : format(unref(req), requiredResource.precision)\n } ${requiredResource.displayName} to unlock (You have ${\n Decimal.eq(requiredResource.precision, 0)\n ? formatWhole(requiredResource.value)\n : format(requiredResource.value, requiredResource.precision)\n })`;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined,\n backgroundImage: (_ctx.earned && _ctx.image && `url(${_ctx.image})`) || ''\n },\n _ctx.unref(_ctx.style) ?? []\n ]),\n class: _normalizeClass({\n feature: true,\n achievement: true,\n locked: !_ctx.unref(_ctx.earned),\n bought: _ctx.unref(_ctx.earned),\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n (_ctx.component)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport { CoercableComponent, Visibility } from \"features/feature\";\nimport { computeOptionalComponent, processedPropType } from \"util/vue\";\nimport { defineComponent, StyleValue, toRefs, unref } from \"vue\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport \"components/common/features.css\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: processedPropType<CoercableComponent>(Object, String, Function),\n earned: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n image: processedPropType<string>(String),\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node,\n MarkNode\n },\n setup(props) {\n const { display } = toRefs(props);\n\n return {\n component: computeOptionalComponent(display),\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Achievement.vue?vue&type=template&id=e3f32402&scoped=true&ts=true\"\nimport script from \"./Achievement.vue?vue&type=script&lang=ts\"\nexport * from \"./Achievement.vue?vue&type=script&lang=ts\"\n\nimport \"./Achievement.vue?vue&type=style&index=0&id=e3f32402&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e3f32402\"]])\n\nexport default __exports__","import { globalBus } from \"game/events\";\nimport Toast from \"vue-toastification\";\nimport \"vue-toastification/dist/index.css\";\n\nglobalBus.on(\"setupVue\", vue => vue.use(Toast));\n\nexport function getNotifyStyle(color = \"white\", strength = \"8px\") {\n return {\n transform: \"scale(1.05, 1.05)\",\n borderColor: \"rgba(0, 0, 0, 0.125)\",\n boxShadow: `-4px -4px 4px rgba(0, 0, 0, 0.25) inset, 0 0 ${strength} ${color}`,\n zIndex: 1\n };\n}\n\nexport function getHighNotifyStyle() {\n return getNotifyStyle(\"red\", \"20px\");\n}\n","import AchievementComponent from \"features/achievements/Achievement.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport \"game/notifications\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { coerceComponent } from \"util/vue\";\nimport { unref, watchEffect } from \"vue\";\nimport { useToast } from \"vue-toastification\";\n\nconst toast = useToast();\n\nexport const AchievementType = Symbol(\"Achievement\");\n\nexport interface AchievementOptions {\n visibility?: Computable<Visibility>;\n shouldEarn?: () => boolean;\n display?: Computable<CoercableComponent>;\n mark?: Computable<boolean | string>;\n image?: Computable<string>;\n style?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n onComplete?: VoidFunction;\n}\n\nexport interface BaseAchievement {\n id: string;\n earned: Persistent<boolean>;\n complete: VoidFunction;\n type: typeof AchievementType;\n [Component]: typeof AchievementComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Achievement<T extends AchievementOptions> = Replace<\n T & BaseAchievement,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n display: GetComputableType<T[\"display\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n image: GetComputableType<T[\"image\"]>;\n style: GetComputableType<T[\"style\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n }\n>;\n\nexport type GenericAchievement = Replace<\n Achievement<AchievementOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createAchievement<T extends AchievementOptions>(\n optionsFunc?: OptionsFunc<T, Achievement<T>, BaseAchievement>\n): Achievement<T> {\n const earned = persistent<boolean>(false);\n return createLazyProxy(() => {\n const achievement = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n achievement.id = getUniqueID(\"achievement-\");\n achievement.type = AchievementType;\n achievement[Component] = AchievementComponent;\n\n achievement.earned = earned;\n achievement.complete = function () {\n earned.value = true;\n };\n\n processComputable(achievement as T, \"visibility\");\n setDefault(achievement, \"visibility\", Visibility.Visible);\n processComputable(achievement as T, \"display\");\n processComputable(achievement as T, \"mark\");\n processComputable(achievement as T, \"image\");\n processComputable(achievement as T, \"style\");\n processComputable(achievement as T, \"classes\");\n\n achievement[GatherProps] = function (this: GenericAchievement) {\n const { visibility, display, earned, image, style, classes, mark, id } = this;\n return { visibility, display, earned, image, style: unref(style), classes, mark, id };\n };\n\n if (achievement.shouldEarn) {\n const genericAchievement = achievement as GenericAchievement;\n watchEffect(() => {\n if (\n !genericAchievement.earned.value &&\n unref(genericAchievement.visibility) === Visibility.Visible &&\n genericAchievement.shouldEarn?.()\n ) {\n genericAchievement.earned.value = true;\n genericAchievement.onComplete?.();\n if (genericAchievement.display) {\n const Display = coerceComponent(unref(genericAchievement.display));\n toast.info(\n <div>\n <h3>Achievement earned!</h3>\n <div>\n {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}\n {/* @ts-ignore */}\n <Display />\n </div>\n </div>\n );\n }\n }\n });\n }\n\n return achievement as unknown as Achievement<T>;\n });\n}\n","import { renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, resolveComponent as _resolveComponent, mergeProps as _mergeProps, createBlock as _createBlock, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_GridCell = _resolveComponent(\"GridCell\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle({\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n }),\n class: \"table\"\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.unref(_ctx.rows), (row) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"row\", { mergeAdjacent: _ctx.mergeAdjacent }]),\n key: row\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.unref(_ctx.cols), (col) => {\n return (_openBlock(), _createBlock(_component_GridCell, _mergeProps({ key: col }, _ctx.gatherCellProps(_ctx.unref(_ctx.cells)[row * 100 + col])), null, 16))\n }), 128))\n ], 2))\n }), 128))\n ], 4))\n : _createCommentVNode(\"\", true)\n}","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-b27416ec\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { key: 0 }\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n class: _normalizeClass({ feature: true, tile: true, can: _ctx.unref(_ctx.canClick), locked: !_ctx.unref(_ctx.canClick) }),\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.onClick && _ctx.onClick(...args))),\n onMousedown: _cache[1] || (_cache[1] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onMouseleave: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onMouseup: _cache[3] || (_cache[3] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchstartPassive: _cache[4] || (_cache[4] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onTouchendPassive: _cache[5] || (_cache[5] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchcancelPassive: _cache[6] || (_cache[6] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args)))\n }, [\n (_ctx.title)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.titleComponent)))\n ]))\n : _createCommentVNode(\"\", true),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component), { style: {\"white-space\":\"pre-line\"} })),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 38))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport Node from \"components/Node.vue\";\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport {\n computeComponent,\n computeOptionalComponent,\n processedPropType,\n setupHoldToClick\n} from \"util/vue\";\nimport { defineComponent, PropType, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n onClick: Function as PropType<(e?: MouseEvent | TouchEvent) => void>,\n onHold: Function as PropType<VoidFunction>,\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n title: processedPropType<CoercableComponent>(Object, String, Function),\n style: processedPropType<StyleValue>(String, Object, Array),\n canClick: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node\n },\n setup(props) {\n const { onClick, onHold, title, display } = toRefs(props);\n\n const { start, stop } = setupHoldToClick(onClick, onHold);\n\n const titleComponent = computeOptionalComponent(title);\n const component = computeComponent(display);\n\n return {\n start,\n stop,\n titleComponent,\n component,\n Visibility,\n unref\n };\n }\n});\n","import { render } from \"./GridCell.vue?vue&type=template&id=b27416ec&scoped=true&ts=true\"\nimport script from \"./GridCell.vue?vue&type=script&lang=ts\"\nexport * from \"./GridCell.vue?vue&type=script&lang=ts\"\n\nimport \"./GridCell.vue?vue&type=style&index=0&id=b27416ec&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-b27416ec\"]])\n\nexport default __exports__","\nimport \"components/common/table.css\";\nimport themes from \"data/themes\";\nimport { Visibility } from \"features/feature\";\nimport { GridCell } from \"features/grids/grid\";\nimport settings from \"game/settings\";\nimport { processedPropType } from \"util/vue\";\nimport { computed, defineComponent, unref } from \"vue\";\nimport GridCellVue from \"./GridCell.vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n rows: {\n type: processedPropType<number>(Number),\n required: true\n },\n cols: {\n type: processedPropType<number>(Number),\n required: true\n },\n cells: {\n type: processedPropType<Record<string, GridCell>>(Object),\n required: true\n }\n },\n components: { GridCell: GridCellVue },\n setup() {\n const mergeAdjacent = computed(() => themes[settings.theme].mergeAdjacent);\n\n function gatherCellProps(cell: GridCell) {\n const { visibility, onClick, onHold, display, title, style, canClick, id } = cell;\n return { visibility, onClick, onHold, display, title, style, canClick, id };\n }\n\n return { unref, gatherCellProps, Visibility, mergeAdjacent };\n }\n});\n","import { render } from \"./Grid.vue?vue&type=template&id=4f6b6717&ts=true\"\nimport script from \"./Grid.vue?vue&type=script&lang=ts\"\nexport * from \"./Grid.vue?vue&type=script&lang=ts\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__","import GridComponent from \"features/grids/Grid.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { isFunction } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { State, Persistent, persistent } from \"game/persistence\";\n\nexport const GridType = Symbol(\"Grid\");\n\nexport type CellComputable<T> = Computable<T> | ((id: string | number, state: State) => T);\n\nfunction createGridProxy(grid: GenericGrid): Record<string | number, GridCell> {\n return new Proxy({}, getGridHandler(grid)) as Record<string | number, GridCell>;\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getGridHandler(grid: GenericGrid): ProxyHandler<Record<string | number, GridCell>> {\n const keys = computed(() => {\n const keys = [];\n for (let row = 1; row <= unref(grid.rows); row++) {\n for (let col = 1; col <= unref(grid.cols); col++) {\n keys.push((row * 100 + col).toString());\n }\n }\n return keys;\n });\n return {\n get(target: Record<string | number, GridCell>, key: PropertyKey) {\n if (key === \"isProxy\") {\n return true;\n }\n\n if (typeof key === \"symbol\") {\n return (grid as never)[key];\n }\n\n if (!keys.value.includes(key.toString())) {\n return undefined;\n }\n\n if (target[key] == null) {\n target[key] = new Proxy(\n grid,\n getCellHandler(key.toString())\n ) as unknown as GridCell;\n }\n\n return target[key];\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n set(target: Record<string | number, GridCell>, key: PropertyKey, value: any) {\n console.warn(\"Cannot set grid cells\", target, key, value);\n return false;\n },\n ownKeys() {\n return keys.value;\n },\n has(target: Record<string | number, GridCell>, key: PropertyKey) {\n return keys.value.includes(key.toString());\n },\n getOwnPropertyDescriptor(target: Record<string | number, GridCell>, key: PropertyKey) {\n if (keys.value.includes(key.toString())) {\n return {\n configurable: true,\n enumerable: true,\n writable: false\n };\n }\n }\n };\n}\n\nfunction getCellHandler(id: string): ProxyHandler<GenericGrid> {\n const keys = [\n \"id\",\n \"visibility\",\n \"canClick\",\n \"startState\",\n \"state\",\n \"style\",\n \"classes\",\n \"title\",\n \"display\",\n \"onClick\",\n \"onHold\"\n ];\n const cache: Record<string, Ref<unknown>> = {};\n return {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get(target, key, receiver): any {\n if (key === \"isProxy\") {\n return true;\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n let prop = (target as any)[key];\n\n if (isFunction(prop)) {\n return () => prop.call(receiver, id, target.getState(id));\n }\n if (prop != undefined || typeof key === \"symbol\") {\n return prop;\n }\n\n key = key.slice(0, 1).toUpperCase() + key.slice(1);\n\n if (key === \"startState\") {\n return prop.call(receiver, id);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n prop = (target as any)[`get${key}`];\n if (isFunction(prop)) {\n if (!(key in cache)) {\n cache[key] = computed(() => prop.call(receiver, id, target.getState(id)));\n }\n return cache[key].value;\n } else if (prop != undefined) {\n return unref(prop);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n prop = (target as any)[`on${key}`];\n if (isFunction(prop)) {\n return () => prop.call(receiver, id, target.getState(id));\n } else if (prop != undefined) {\n return prop;\n }\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n return (target as any)[key];\n },\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n set(target: Record<string, any>, key: string, value: any, receiver: typeof Proxy): boolean {\n key = `set${key.slice(0, 1).toUpperCase() + key.slice(1)}`;\n if (key in target && isFunction(target[key]) && target[key].length < 3) {\n target[key].call(receiver, id, value);\n return true;\n } else {\n console.warn(`No setter for \"${key}\".`, target);\n return false;\n }\n },\n ownKeys() {\n return keys;\n },\n has(target, key) {\n return keys.includes(key.toString());\n },\n getOwnPropertyDescriptor(target, key) {\n if (keys.includes(key.toString())) {\n return {\n configurable: true,\n enumerable: true,\n writable: false\n };\n }\n }\n };\n}\n\nexport interface GridCell {\n id: string;\n visibility: Visibility;\n canClick: boolean;\n startState: State;\n state: State;\n style?: StyleValue;\n classes?: Record<string, boolean>;\n title?: CoercableComponent;\n display: CoercableComponent;\n onClick?: (e?: MouseEvent | TouchEvent) => void;\n onHold?: VoidFunction;\n}\n\nexport interface GridOptions {\n visibility?: Computable<Visibility>;\n rows: Computable<number>;\n cols: Computable<number>;\n getVisibility?: CellComputable<Visibility>;\n getCanClick?: CellComputable<boolean>;\n getStartState: Computable<State> | ((id: string | number) => State);\n getStyle?: CellComputable<StyleValue>;\n getClasses?: CellComputable<Record<string, boolean>>;\n getTitle?: CellComputable<CoercableComponent>;\n getDisplay: CellComputable<CoercableComponent>;\n onClick?: (id: string | number, state: State, e?: MouseEvent | TouchEvent) => void;\n onHold?: (id: string | number, state: State) => void;\n}\n\nexport interface BaseGrid {\n id: string;\n getID: (id: string | number, state: State) => string;\n getState: (id: string | number) => State;\n setState: (id: string | number, state: State) => void;\n cells: Record<string | number, GridCell>;\n cellState: Persistent<Record<string | number, State>>;\n type: typeof GridType;\n [Component]: typeof GridComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Grid<T extends GridOptions> = Replace<\n T & BaseGrid,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n rows: GetComputableType<T[\"rows\"]>;\n cols: GetComputableType<T[\"cols\"]>;\n getVisibility: GetComputableTypeWithDefault<T[\"getVisibility\"], Visibility.Visible>;\n getCanClick: GetComputableTypeWithDefault<T[\"getCanClick\"], true>;\n getStartState: GetComputableType<T[\"getStartState\"]>;\n getStyle: GetComputableType<T[\"getStyle\"]>;\n getClasses: GetComputableType<T[\"getClasses\"]>;\n getTitle: GetComputableType<T[\"getTitle\"]>;\n getDisplay: GetComputableType<T[\"getDisplay\"]>;\n }\n>;\n\nexport type GenericGrid = Replace<\n Grid<GridOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n getVisibility: ProcessedComputable<Visibility>;\n getCanClick: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createGrid<T extends GridOptions>(\n optionsFunc: OptionsFunc<T, Grid<T>, BaseGrid>\n): Grid<T> {\n const cellState = persistent<Record<string | number, State>>({});\n return createLazyProxy(() => {\n const grid = optionsFunc();\n grid.id = getUniqueID(\"grid-\");\n grid[Component] = GridComponent;\n\n grid.cellState = cellState;\n\n grid.getID = function (this: GenericGrid, cell: string | number) {\n return grid.id + \"-\" + cell;\n };\n grid.getState = function (this: GenericGrid, cell: string | number) {\n if (this.cellState.value[cell] != undefined) {\n return cellState.value[cell];\n }\n return this.cells[cell].startState;\n };\n grid.setState = function (this: GenericGrid, cell: string | number, state: State) {\n cellState.value[cell] = state;\n };\n\n grid.cells = createGridProxy(grid as GenericGrid);\n\n processComputable(grid as T, \"visibility\");\n setDefault(grid, \"visibility\", Visibility.Visible);\n processComputable(grid as T, \"rows\");\n processComputable(grid as T, \"cols\");\n processComputable(grid as T, \"getVisibility\");\n setDefault(grid, \"getVisibility\", Visibility.Visible);\n processComputable(grid as T, \"getCanClick\");\n setDefault(grid, \"getCanClick\", true);\n processComputable(grid as T, \"getStartState\");\n processComputable(grid as T, \"getStyle\");\n processComputable(grid as T, \"getClasses\");\n processComputable(grid as T, \"getTitle\");\n processComputable(grid as T, \"getDisplay\");\n\n if (grid.onClick) {\n const onClick = grid.onClick.bind(grid);\n grid.onClick = function (id, state) {\n if (unref((grid as GenericGrid).cells[id].canClick)) {\n onClick(id, state);\n }\n };\n }\n if (grid.onHold) {\n const onHold = grid.onHold.bind(grid);\n grid.onHold = function (id, state) {\n if (unref((grid as GenericGrid).cells[id].canClick)) {\n onHold(id, state);\n }\n };\n }\n\n grid[GatherProps] = function (this: GenericGrid) {\n const { visibility, rows, cols, cells, id } = this;\n return { visibility, rows, cols, cells, id };\n };\n\n return grid as unknown as Grid<T>;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n style: _normalizeStyle([\n { visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined },\n _ctx.unref(_ctx.style) ?? []\n ]),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.onClick && _ctx.onClick(...args))),\n onMousedown: _cache[1] || (_cache[1] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onMouseleave: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onMouseup: _cache[3] || (_cache[3] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchstartPassive: _cache[4] || (_cache[4] = \n//@ts-ignore\n(...args) => (_ctx.start && _ctx.start(...args))),\n onTouchendPassive: _cache[5] || (_cache[5] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n onTouchcancelPassive: _cache[6] || (_cache[6] = \n//@ts-ignore\n(...args) => (_ctx.stop && _ctx.stop(...args))),\n class: _normalizeClass({\n feature: true,\n clickable: true,\n can: _ctx.unref(_ctx.canClick),\n locked: !_ctx.unref(_ctx.canClick),\n small: _ctx.small,\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n (_ctx.unref(_ctx.comp))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp)), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 38))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { GenericClickable } from \"features/clickables/clickable\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport {\n coerceComponent,\n isCoercableComponent,\n processedPropType,\n setupHoldToClick,\n unwrapRef\n} from \"util/vue\";\nimport {\n Component,\n defineComponent,\n PropType,\n shallowRef,\n toRefs,\n unref,\n UnwrapRef,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n display: {\n type: processedPropType<UnwrapRef<GenericClickable[\"display\"]>>(\n Object,\n String,\n Function\n ),\n required: true\n },\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n onClick: Function as PropType<(e?: MouseEvent | TouchEvent) => void>,\n onHold: Function as PropType<VoidFunction>,\n canClick: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n small: Boolean,\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node,\n MarkNode\n },\n setup(props) {\n const { display, onClick, onHold } = toRefs(props);\n\n const comp = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n comp.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n comp.value = coerceComponent(currDisplay);\n return;\n }\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description, \"div\");\n comp.value = coerceComponent(\n jsx(() => (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n </span>\n ))\n );\n });\n\n const { start, stop } = setupHoldToClick(onClick, onHold);\n\n return {\n start,\n stop,\n comp,\n Visibility,\n unref\n };\n }\n});\n","import { render } from \"./Clickable.vue?vue&type=template&id=e4e6b79a&scoped=true&ts=true\"\nimport script from \"./Clickable.vue?vue&type=script&lang=tsx\"\nexport * from \"./Clickable.vue?vue&type=script&lang=tsx\"\n\nimport \"./Clickable.vue?vue&type=style&index=0&id=e4e6b79a&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e4e6b79a\"]])\n\nexport default __exports__","import ClickableComponent from \"features/clickables/Clickable.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { GenericLayer } from \"game/layers\";\nimport { Unsubscribe } from \"nanoevents\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, unref } from \"vue\";\n\nexport const ClickableType = Symbol(\"Clickable\");\n\nexport interface ClickableOptions {\n visibility?: Computable<Visibility>;\n canClick?: Computable<boolean>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n mark?: Computable<boolean | string>;\n display?: Computable<\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n }\n >;\n small?: boolean;\n onClick?: (e?: MouseEvent | TouchEvent) => void;\n onHold?: VoidFunction;\n}\n\nexport interface BaseClickable {\n id: string;\n type: typeof ClickableType;\n [Component]: typeof ClickableComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Clickable<T extends ClickableOptions> = Replace<\n T & BaseClickable,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n canClick: GetComputableTypeWithDefault<T[\"canClick\"], true>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericClickable = Replace<\n Clickable<ClickableOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canClick: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createClickable<T extends ClickableOptions>(\n optionsFunc?: OptionsFunc<T, Clickable<T>, BaseClickable>\n): Clickable<T> {\n return createLazyProxy(() => {\n const clickable = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n clickable.id = getUniqueID(\"clickable-\");\n clickable.type = ClickableType;\n clickable[Component] = ClickableComponent;\n\n processComputable(clickable as T, \"visibility\");\n setDefault(clickable, \"visibility\", Visibility.Visible);\n processComputable(clickable as T, \"canClick\");\n setDefault(clickable, \"canClick\", true);\n processComputable(clickable as T, \"classes\");\n processComputable(clickable as T, \"style\");\n processComputable(clickable as T, \"mark\");\n processComputable(clickable as T, \"display\");\n\n if (clickable.onClick) {\n const onClick = clickable.onClick.bind(clickable);\n clickable.onClick = function (e) {\n if (unref(clickable.canClick)) {\n onClick(e);\n }\n };\n }\n if (clickable.onHold) {\n const onHold = clickable.onHold.bind(clickable);\n clickable.onHold = function () {\n if (unref(clickable.canClick)) {\n onHold();\n }\n };\n }\n\n clickable[GatherProps] = function (this: GenericClickable) {\n const {\n display,\n visibility,\n style,\n classes,\n onClick,\n onHold,\n canClick,\n small,\n mark,\n id\n } = this;\n return {\n display,\n visibility,\n style: unref(style),\n classes,\n onClick,\n onHold,\n canClick,\n small,\n mark,\n id\n };\n };\n\n return clickable as unknown as Clickable<T>;\n });\n}\n\nexport function setupAutoClick(\n layer: GenericLayer,\n clickable: GenericClickable,\n autoActive: Computable<boolean> = true\n): Unsubscribe {\n const isActive = typeof autoActive === \"function\" ? computed(autoActive) : autoActive;\n return layer.on(\"update\", () => {\n if (unref(isActive) && unref(clickable.canClick)) {\n clickable.onClick?.();\n }\n });\n}\n","import {\n Clickable,\n ClickableOptions,\n createClickable,\n GenericClickable\n} from \"features/clickables/clickable\";\nimport { GenericConversion } from \"features/conversion\";\nimport {\n CoercableComponent,\n jsx,\n JSXFunction,\n OptionsFunc,\n Replace,\n setDefault\n} from \"features/feature\";\nimport { displayResource } from \"features/resources/resource\";\nimport {\n createTreeNode,\n GenericTree,\n GenericTreeNode,\n TreeNode,\n TreeNodeOptions\n} from \"features/trees/tree\";\nimport { Modifier } from \"game/modifiers\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport player from \"game/player\";\nimport Decimal, { DecimalSource, format } from \"util/bignum\";\nimport { WithRequired } from \"util/common\";\nimport {\n Computable,\n convertComputable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { renderJSX } from \"util/vue\";\nimport { computed, Ref, unref } from \"vue\";\nimport \"./common.css\";\n\nexport interface ResetButtonOptions extends ClickableOptions {\n conversion: GenericConversion;\n tree: GenericTree;\n treeNode: GenericTreeNode;\n resetDescription?: Computable<string>;\n showNextAt?: Computable<boolean>;\n display?: Computable<CoercableComponent>;\n canClick?: Computable<boolean>;\n minimumGain?: Computable<DecimalSource>;\n}\n\nexport type ResetButton<T extends ResetButtonOptions> = Replace<\n Clickable<T>,\n {\n resetDescription: GetComputableTypeWithDefault<T[\"resetDescription\"], Ref<string>>;\n showNextAt: GetComputableTypeWithDefault<T[\"showNextAt\"], true>;\n display: GetComputableTypeWithDefault<T[\"display\"], Ref<JSX.Element>>;\n canClick: GetComputableTypeWithDefault<T[\"canClick\"], Ref<boolean>>;\n minimumGain: GetComputableTypeWithDefault<T[\"minimumGain\"], 1>;\n onClick: VoidFunction;\n }\n>;\n\nexport type GenericResetButton = Replace<\n GenericClickable & ResetButton<ResetButtonOptions>,\n {\n resetDescription: ProcessedComputable<string>;\n showNextAt: ProcessedComputable<boolean>;\n display: ProcessedComputable<CoercableComponent>;\n canClick: ProcessedComputable<boolean>;\n minimumGain: ProcessedComputable<DecimalSource>;\n }\n>;\n\nexport function createResetButton<T extends ClickableOptions & ResetButtonOptions>(\n optionsFunc: OptionsFunc<T>\n): ResetButton<T> {\n return createClickable(() => {\n const resetButton = optionsFunc();\n\n processComputable(resetButton as T, \"showNextAt\");\n setDefault(resetButton, \"showNextAt\", true);\n setDefault(resetButton, \"minimumGain\", 1);\n\n if (resetButton.resetDescription == null) {\n resetButton.resetDescription = computed(() =>\n Decimal.lt(resetButton.conversion.gainResource.value, 1e3) ? \"Reset for \" : \"\"\n );\n } else {\n processComputable(resetButton as T, \"resetDescription\");\n }\n\n if (resetButton.display == null) {\n resetButton.display = jsx(() => (\n <span>\n {unref(resetButton.resetDescription as ProcessedComputable<string>)}\n <b>\n {displayResource(\n resetButton.conversion.gainResource,\n Decimal.max(\n unref(resetButton.conversion.actualGain),\n unref(resetButton.minimumGain as ProcessedComputable<DecimalSource>)\n )\n )}\n </b>{\" \"}\n {resetButton.conversion.gainResource.displayName}\n <div v-show={unref(resetButton.showNextAt)}>\n <br />\n {unref(resetButton.conversion.buyMax) ? \"Next:\" : \"Req:\"}{\" \"}\n {displayResource(\n resetButton.conversion.baseResource,\n unref(resetButton.conversion.buyMax) ||\n Decimal.floor(unref(resetButton.conversion.actualGain)).neq(1)\n ? unref(resetButton.conversion.nextAt)\n : unref(resetButton.conversion.currentAt)\n )}{\" \"}\n {resetButton.conversion.baseResource.displayName}\n </div>\n </span>\n ));\n }\n\n if (resetButton.canClick == null) {\n resetButton.canClick = computed(() =>\n Decimal.gte(\n unref(resetButton.conversion.actualGain),\n unref(resetButton.minimumGain as ProcessedComputable<DecimalSource>)\n )\n );\n }\n\n const onClick = resetButton.onClick;\n resetButton.onClick = function () {\n if (!unref(resetButton.canClick)) {\n return;\n }\n resetButton.conversion.convert();\n resetButton.tree.reset(resetButton.treeNode);\n onClick?.();\n };\n\n return resetButton;\n }) as unknown as ResetButton<T>;\n}\n\nexport interface LayerTreeNodeOptions extends TreeNodeOptions {\n layerID: string;\n color: Computable<string>; // marking as required\n display?: Computable<CoercableComponent>;\n append?: Computable<boolean>;\n}\nexport type LayerTreeNode<T extends LayerTreeNodeOptions> = Replace<\n TreeNode<T>,\n {\n display: GetComputableTypeWithDefault<T[\"display\"], T[\"layerID\"]>;\n append: GetComputableType<T[\"append\"]>;\n }\n>;\nexport type GenericLayerTreeNode = Replace<\n LayerTreeNode<LayerTreeNodeOptions>,\n {\n display: ProcessedComputable<CoercableComponent>;\n append?: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createLayerTreeNode<T extends LayerTreeNodeOptions>(\n optionsFunc: OptionsFunc<T>\n): LayerTreeNode<T> {\n return createTreeNode(() => {\n const options = optionsFunc();\n processComputable(options as T, \"display\");\n setDefault(options, \"display\", options.layerID);\n processComputable(options as T, \"append\");\n return {\n ...options,\n display: options.display,\n onClick: unref((options as unknown as GenericLayerTreeNode).append)\n ? function () {\n if (player.tabs.includes(options.layerID)) {\n const index = player.tabs.lastIndexOf(options.layerID);\n player.tabs.splice(index, 1);\n } else {\n player.tabs.push(options.layerID);\n }\n }\n : function () {\n player.tabs.splice(1, 1, options.layerID);\n }\n };\n }) as unknown as LayerTreeNode<T>;\n}\n\nexport function createCollapsibleModifierSections(\n sections: {\n title: string;\n subtitle?: string;\n modifier: WithRequired<Modifier, \"description\">;\n base?: Computable<DecimalSource>;\n unit?: string;\n baseText?: Computable<CoercableComponent>;\n visible?: Computable<boolean>;\n }[]\n): [JSXFunction, Persistent<boolean>[]] {\n const processedBase = sections.map(s => convertComputable(s.base));\n const processedBaseText = sections.map(s => convertComputable(s.baseText));\n const processedVisible = sections.map(s => convertComputable(s.visible));\n const collapsed = sections.map(() => persistent<boolean>(false));\n const jsxFunc = jsx(() => {\n const sectionJSX = sections.map((s, i) => {\n if (unref(processedVisible[i]) === false) return null;\n const header = (\n <h3\n onClick={() => (collapsed[i].value = !collapsed[i].value)}\n style=\"cursor: pointer\"\n >\n <span class={\"modifier-toggle\" + (unref(collapsed[i]) ? \" collapsed\" : \"\")}>\n ▼\n </span>\n {s.title}\n {s.subtitle ? <span class=\"subtitle\"> ({s.subtitle})</span> : null}\n </h3>\n );\n\n const modifiers = unref(collapsed[i]) ? null : (\n <>\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">\n {format(unref(processedBase[i]) ?? 1)}\n {s.unit}\n </span>\n <span class=\"modifier-description\">\n {renderJSX(unref(processedBaseText[i]) ?? \"Base\")}\n </span>\n </div>\n {renderJSX(unref(s.modifier.description))}\n </>\n );\n\n return (\n <>\n {i === 0 ? null : <br />}\n <div>\n {header}\n <br />\n {modifiers}\n <hr />\n Total: {format(s.modifier.apply(unref(processedBase[i]) ?? 1))}\n {s.unit}\n </div>\n </>\n );\n });\n return <>{sectionJSX}</>;\n });\n return [jsxFunc, collapsed];\n}\n","import { GenericLayer } from \"game/layers\";\nimport { Modifier } from \"game/modifiers\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { WithRequired } from \"util/common\";\nimport {\n Computable,\n convertComputable,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { OptionsFunc, Replace, setDefault } from \"./feature\";\nimport { Resource } from \"./resources/resource\";\n\n/**\n * An object that configures a {@link conversion}.\n */\nexport interface ConversionOptions {\n /**\n * The scaling function that is used to determine the rate of conversion from one {@link resource} to the other.\n */\n scaling: ScalingFunction;\n /**\n * How much of the output resource the conversion can currently convert for.\n * Typically this will be set for you in a conversion constructor.\n */\n currentGain?: Computable<DecimalSource>;\n /**\n * The absolute amount the output resource will be changed by.\n * Typically this will be set for you in a conversion constructor.\n * This will differ from {@link currentGain} in the cases where the conversion isn't just adding the converted amount to the output resource.\n */\n actualGain?: Computable<DecimalSource>;\n /**\n * The amount of the input resource currently being required in order to produce the {@link currentGain}.\n * That is, if it went below this value then {@link currentGain} would decrease.\n * Typically this will be set for you in a conversion constructor.\n */\n currentAt?: Computable<DecimalSource>;\n /**\n * The amount of the input resource required to make {@link currentGain} increase.\n * Typically this will be set for you in a conversion constructor.\n */\n nextAt?: Computable<DecimalSource>;\n /**\n * The input {@link resource} for this conversion.\n */\n baseResource: Resource;\n /**\n * The output {@link resource} for this conversion. i.e. the resource being generated.\n */\n gainResource: Resource;\n /**\n * Whether or not to cap the amount of the output resource gained by converting at 1.\n */\n buyMax?: Computable<boolean>;\n /**\n * Whether or not to round up the cost to generate a given amount of the output resource.\n */\n roundUpCost?: Computable<boolean>;\n /**\n * The function that performs the actual conversion from {@link baseResource} to {@link gainResource}.\n * Typically this will be set for you in a conversion constructor.\n */\n convert?: VoidFunction;\n /**\n * An addition modifier that will be applied to the gain amounts.\n * Must be reversible in order to correctly calculate {@link nextAt}.\n * @see {@link createSequentialModifier} if you want to apply multiple modifiers.\n */\n gainModifier?: WithRequired<Modifier, \"revert\">;\n}\n\n/**\n * The properties that are added onto a processed {@link ConversionOptions} to create a {@link Conversion}.\n */\nexport interface BaseConversion {\n /**\n * The function that performs the actual conversion.\n */\n convert: VoidFunction;\n}\n\n/**\n * An object that converts one {@link resource} into another at a given rate.\n */\nexport type Conversion<T extends ConversionOptions> = Replace<\n T & BaseConversion,\n {\n currentGain: GetComputableTypeWithDefault<T[\"currentGain\"], Ref<DecimalSource>>;\n actualGain: GetComputableTypeWithDefault<T[\"actualGain\"], Ref<DecimalSource>>;\n currentAt: GetComputableTypeWithDefault<T[\"currentAt\"], Ref<DecimalSource>>;\n nextAt: GetComputableTypeWithDefault<T[\"nextAt\"], Ref<DecimalSource>>;\n buyMax: GetComputableTypeWithDefault<T[\"buyMax\"], true>;\n roundUpCost: GetComputableTypeWithDefault<T[\"roundUpCost\"], true>;\n }\n>;\n\n/**\n * A type that matches any {@link conversion} object.\n */\nexport type GenericConversion = Replace<\n Conversion<ConversionOptions>,\n {\n currentGain: ProcessedComputable<DecimalSource>;\n actualGain: ProcessedComputable<DecimalSource>;\n currentAt: ProcessedComputable<DecimalSource>;\n nextAt: ProcessedComputable<DecimalSource>;\n buyMax: ProcessedComputable<boolean>;\n roundUpCost: ProcessedComputable<boolean>;\n }\n>;\n\n/**\n * Lazily creates a conversion with the given options.\n * You typically shouldn't use this function directly. Instead use one of the other conversion constructors, which will then call this.\n * @param optionsFunc Conversion options.\n * @see {@link createCumulativeConversion}.\n * @see {@link createIndependentConversion}.\n */\nexport function createConversion<T extends ConversionOptions>(\n optionsFunc: OptionsFunc<T, Conversion<T>, BaseConversion>\n): Conversion<T> {\n return createLazyProxy(() => {\n const conversion = optionsFunc();\n\n if (conversion.currentGain == null) {\n conversion.currentGain = computed(() => {\n let gain = conversion.gainModifier\n ? conversion.gainModifier.apply(\n conversion.scaling.currentGain(conversion as GenericConversion)\n )\n : conversion.scaling.currentGain(conversion as GenericConversion);\n gain = Decimal.floor(gain).max(0);\n\n if (!unref(conversion.buyMax)) {\n gain = gain.min(1);\n }\n return gain;\n });\n }\n if (conversion.actualGain == null) {\n conversion.actualGain = conversion.currentGain;\n }\n if (conversion.currentAt == null) {\n conversion.currentAt = computed(() => {\n let current = conversion.scaling.currentAt(conversion as GenericConversion);\n if (conversion.roundUpCost) current = Decimal.ceil(current);\n return current;\n });\n }\n if (conversion.nextAt == null) {\n conversion.nextAt = computed(() => {\n let next = conversion.scaling.nextAt(conversion as GenericConversion);\n if (conversion.roundUpCost) next = Decimal.ceil(next);\n return next;\n });\n }\n\n if (conversion.convert == null) {\n conversion.convert = function () {\n conversion.gainResource.value = Decimal.add(\n conversion.gainResource.value,\n unref((conversion as GenericConversion).currentGain)\n );\n // TODO just subtract cost?\n conversion.baseResource.value = 0;\n };\n }\n\n processComputable(conversion as T, \"currentGain\");\n processComputable(conversion as T, \"actualGain\");\n processComputable(conversion as T, \"currentAt\");\n processComputable(conversion as T, \"nextAt\");\n processComputable(conversion as T, \"buyMax\");\n setDefault(conversion, \"buyMax\", true);\n processComputable(conversion as T, \"roundUpCost\");\n setDefault(conversion, \"roundUpCost\", true);\n\n return conversion as unknown as Conversion<T>;\n });\n}\n\n/**\n * A collection of functions that allow a conversion to scale the amount of resources gained based on the input resource.\n * This typically shouldn't be created directly. Instead use one of the scaling function constructors.\n * @see {@link createLinearScaling}.\n * @see {@link createPolynomialScaling}.\n */\nexport interface ScalingFunction {\n /**\n * Calculates the amount of the output resource a conversion should be able to currently produce.\n * This should be based off of `conversion.baseResource.value`.\n * The conversion is responsible for applying the gainModifier, so this function should be un-modified.\n * It does not need to be clamped or rounded.\n */\n currentGain: (conversion: GenericConversion) => DecimalSource;\n /**\n * Calculates the amount of the input resource that is required for the current value of `conversion.currentGain`.\n * Note that `conversion.currentGain` has been modified by `conversion.gainModifier`, so you will need to revert that as appropriate.\n * The conversion is responsible for rounding up the amount as appropriate.\n * The returned value should not be below 0.\n */\n currentAt: (conversion: GenericConversion) => DecimalSource;\n /**\n * Calculates the amount of the input resource that would be required for the current value of `conversion.currentGain` to increase.\n * Note that `conversion.currentGain` has been modified by `conversion.gainModifier`, so you will need to revert that as appropriate.\n * The conversion is responsible for rounding up the amount as appropriate.\n * The returned value should not be below 0.\n */\n nextAt: (conversion: GenericConversion) => DecimalSource;\n}\n\n/**\n * Creates a scaling function based off the formula `(baseResource - base) * coefficient`.\n * If the baseResource value is less than base then the currentGain will be 0.\n * @param base The base variable in the scaling formula.\n * @param coefficient The coefficient variable in the scaling formula.\n * @example\n * A scaling function created via `createLinearScaling(10, 0.5)` would produce the following values:\n * | Base Resource | Current Gain |\n * | ------------- | ------------ |\n * | 10 | 1 |\n * | 12 | 2 |\n * | 20 | 6 |\n */\nexport function createLinearScaling(\n base: Computable<DecimalSource>,\n coefficient: Computable<DecimalSource>\n): ScalingFunction {\n const processedBase = convertComputable(base);\n const processedCoefficient = convertComputable(coefficient);\n return {\n currentGain(conversion) {\n if (Decimal.lt(conversion.baseResource.value, unref(processedBase))) {\n return 0;\n }\n\n return Decimal.sub(conversion.baseResource.value, unref(processedBase))\n .sub(1)\n .times(unref(processedCoefficient))\n .add(1);\n },\n currentAt(conversion) {\n let current: DecimalSource = unref(conversion.currentGain);\n if (conversion.gainModifier) {\n current = conversion.gainModifier.revert(current);\n }\n current = Decimal.max(0, current);\n return Decimal.sub(current, 1)\n .div(unref(processedCoefficient))\n .add(unref(processedBase));\n },\n nextAt(conversion) {\n let next: DecimalSource = Decimal.add(unref(conversion.currentGain), 1);\n if (conversion.gainModifier) {\n next = conversion.gainModifier.revert(next);\n }\n next = Decimal.max(0, next);\n return Decimal.sub(next, 1)\n .div(unref(processedCoefficient))\n .add(unref(processedBase))\n .max(unref(processedBase));\n }\n };\n}\n\n/**\n * Creates a scaling function based off the formula `(baseResource / base) ^ exponent`.\n * If the baseResource value is less than base then the currentGain will be 0.\n * @param base The base variable in the scaling formula.\n * @param exponent The exponent variable in the scaling formula.\n * @example\n * A scaling function created via `createLinearScaling(10, 0.5)` would produce the following values:\n * | Base Resource | Current Gain |\n * | ------------- | ------------ |\n * | 10 | 1 |\n * | 40 | 2 |\n * | 250 | 5 |\n */\nexport function createPolynomialScaling(\n base: Computable<DecimalSource>,\n exponent: Computable<DecimalSource>\n): ScalingFunction {\n const processedBase = convertComputable(base);\n const processedExponent = convertComputable(exponent);\n return {\n currentGain(conversion) {\n if (Decimal.lt(conversion.baseResource.value, unref(processedBase))) {\n return 0;\n }\n\n const gain = Decimal.div(conversion.baseResource.value, unref(processedBase)).pow(\n unref(processedExponent)\n );\n\n if (gain.isNan()) {\n return new Decimal(0);\n }\n return gain;\n },\n currentAt(conversion) {\n let current: DecimalSource = unref(conversion.currentGain);\n if (conversion.gainModifier) {\n current = conversion.gainModifier.revert(current);\n }\n current = Decimal.max(0, current);\n return Decimal.root(current, unref(processedExponent)).times(unref(processedBase));\n },\n nextAt(conversion) {\n let next: DecimalSource = Decimal.add(unref(conversion.currentGain), 1);\n if (conversion.gainModifier) {\n next = conversion.gainModifier.revert(next);\n }\n next = Decimal.max(0, next);\n return Decimal.root(next, unref(processedExponent))\n .times(unref(processedBase))\n .max(unref(processedBase));\n }\n };\n}\n\n/**\n * Creates a conversion that simply adds to the gainResource amount upon converting.\n * This is similar to the behavior of \"normal\" layers in The Modding Tree.\n * This is equivalent to just calling createConversion directly.\n * @param optionsFunc Conversion options.\n */\nexport function createCumulativeConversion<S extends ConversionOptions>(\n optionsFunc: OptionsFunc<S, Conversion<S>>\n): Conversion<S> {\n return createConversion(optionsFunc);\n}\n\n/**\n * Creates a conversion that will replace the gainResource amount with the new amount upon converting.\n * This is similar to the behavior of \"static\" layers in The Modding Tree.\n * @param optionsFunc Converison options.\n */\nexport function createIndependentConversion<S extends ConversionOptions>(\n optionsFunc: OptionsFunc<S, Conversion<S>>\n): Conversion<S> {\n return createConversion(() => {\n const conversion: S = optionsFunc();\n\n setDefault(conversion, \"buyMax\", false);\n\n if (conversion.currentGain == null) {\n conversion.currentGain = computed(() => {\n let gain = conversion.gainModifier\n ? conversion.gainModifier.apply(\n conversion.scaling.currentGain(conversion as GenericConversion)\n )\n : conversion.scaling.currentGain(conversion as GenericConversion);\n gain = Decimal.floor(gain).max(conversion.gainResource.value);\n\n if (!unref(conversion.buyMax)) {\n gain = gain.min(Decimal.add(conversion.gainResource.value, 1));\n }\n return gain;\n });\n }\n if (conversion.actualGain == null) {\n conversion.actualGain = computed(() => {\n let gain = Decimal.sub(\n conversion.scaling.currentGain(conversion as GenericConversion),\n conversion.gainResource.value\n ).max(0);\n\n if (!unref(conversion.buyMax)) {\n gain = gain.min(1);\n }\n return gain;\n });\n }\n setDefault(conversion, \"convert\", function () {\n conversion.gainResource.value = conversion.gainModifier\n ? conversion.gainModifier.apply(\n unref((conversion as GenericConversion).currentGain)\n )\n : unref((conversion as GenericConversion).currentGain);\n // TODO just subtract cost?\n // Maybe by adding a cost function to scaling and nextAt just calls the cost function\n // with 1 + currentGain\n conversion.baseResource.value = 0;\n });\n\n return conversion;\n });\n}\n\n/**\n * This will automatically increase the value of conversion.gainResource without lowering the value of the input resource.\n * It will by default perform 100% of a conversion's currentGain per second.\n * If you use a ref for the rate you can set it's value to 0 when passive generation should be disabled.\n * @param layer The layer this passive generation will be associated with.\n * @param conversion The conversion that will determine how much generation there is.\n * @param rate A multiplier to multiply against the conversion's currentGain.\n */\nexport function setupPassiveGeneration(\n layer: GenericLayer,\n conversion: GenericConversion,\n rate: Computable<DecimalSource> = 1\n): void {\n const processedRate = convertComputable(rate);\n layer.on(\"preUpdate\", diff => {\n const currRate = unref(processedRate);\n if (Decimal.neq(currRate, 0)) {\n conversion.gainResource.value = Decimal.add(\n conversion.gainResource.value,\n Decimal.times(currRate, diff).times(unref(conversion.currentGain))\n );\n }\n });\n}\n\n/**\n * Given a value, this function finds the amount above a certain value and raises it to a power.\n * If the power is <1, this will effectively make the value scale slower after the cap.\n * @param value The raw value.\n * @param cap The value after which the softcap should be applied.\n * @param power The power to raise value above the cap to.\n * @example\n * A softcap added via `addSoftcap(scaling, 100, 0.5)` would produce the following values:\n * | Raw Value | Softcapped Value |\n * | --------- | ---------------- |\n * | 1 | 1 |\n * | 100 | 100 |\n * | 125 | 105 |\n * | 200 | 110 |\n */\nexport function softcap(\n value: DecimalSource,\n cap: DecimalSource,\n power: DecimalSource = 0.5\n): DecimalSource {\n if (Decimal.lte(value, cap)) {\n return value;\n } else {\n return Decimal.pow(value, power).times(Decimal.pow(cap, Decimal.sub(1, power)));\n }\n}\n\n/**\n * Creates a scaling function based off an existing scaling function, with a softcap applied to it.\n * The softcap will take any value above a certain value and raise it to a power.\n * If the power is <1, this will effectively make the value scale slower after the cap.\n * @param scaling The raw scaling function.\n * @param cap The value after which the softcap should be applied.\n * @param power The power to raise value about the cap to.\n * @see {@link softcap}.\n */\nexport function addSoftcap(\n scaling: ScalingFunction,\n cap: ProcessedComputable<DecimalSource>,\n power: ProcessedComputable<DecimalSource> = 0.5\n): ScalingFunction {\n return {\n ...scaling,\n currentGain: conversion =>\n softcap(scaling.currentGain(conversion), unref(cap), unref(power))\n };\n}\n\n/**\n * Creates a scaling function off an existing function, with a hardcap applied to it.\n * The harcap will ensure that the currentGain will stop at a given cap.\n * @param scaling The raw scaling function.\n * @param cap The maximum value the scaling function can output.\n */\nexport function addHardcap(\n scaling: ScalingFunction,\n cap: ProcessedComputable<DecimalSource>\n): ScalingFunction {\n return {\n ...scaling,\n currentGain: conversion => Decimal.min(scaling.currentGain(conversion), unref(cap))\n };\n}\n","import { createElementVNode as _createElementVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, withCtx as _withCtx, createVNode as _createVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-6447a93e\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = /*#__PURE__*/ _withScopeId(() => /*#__PURE__*/_createElementVNode(\"span\", { class: \"toggle\" }, \"▼\", -1))\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_CollapseTransition = _resolveComponent(\"CollapseTransition\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: _normalizeClass([\"infobox\", { collapsed: _ctx.unref(_ctx.collapsed), stacked: _ctx.stacked, ..._ctx.unref(_ctx.classes) }]),\n style: _normalizeStyle([\n {\n borderColor: _ctx.unref(_ctx.color),\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ])\n }, [\n _createElementVNode(\"button\", {\n class: \"title\",\n style: _normalizeStyle([{ backgroundColor: _ctx.unref(_ctx.color) }, _ctx.unref(_ctx.titleStyle) || []]),\n onClick: _cache[0] || (_cache[0] = ($event: any) => (_ctx.collapsed.value = !_ctx.unref(_ctx.collapsed)))\n }, [\n _hoisted_1,\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.titleComponent)))\n ], 4),\n _createVNode(_component_CollapseTransition, null, {\n default: _withCtx(() => [\n (!_ctx.unref(_ctx.collapsed))\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: \"body\",\n style: _normalizeStyle({ backgroundColor: _ctx.unref(_ctx.color) })\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.bodyComponent), {\n style: _normalizeStyle(_ctx.unref(_ctx.bodyStyle))\n }, null, 8, [\"style\"]))\n ], 4))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n }),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport Node from \"components/Node.vue\";\nimport themes from \"data/themes\";\nimport { CoercableComponent, Visibility } from \"features/feature\";\nimport settings from \"game/settings\";\nimport { computeComponent, processedPropType } from \"util/vue\";\nimport CollapseTransition from \"@ivanv/vue-collapse-transition/src/CollapseTransition.vue\";\nimport { computed, defineComponent, PropType, Ref, StyleValue, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n title: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n color: processedPropType<string>(String),\n collapsed: {\n type: Object as PropType<Ref<boolean>>,\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n titleStyle: processedPropType<StyleValue>(Object, String, Array),\n bodyStyle: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node,\n CollapseTransition\n },\n setup(props) {\n const { title, display } = toRefs(props);\n\n const titleComponent = computeComponent(title);\n const bodyComponent = computeComponent(display);\n const stacked = computed(() => themes[settings.theme].mergeAdjacent);\n\n return {\n titleComponent,\n bodyComponent,\n stacked,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Infobox.vue?vue&type=template&id=6447a93e&scoped=true&ts=true\"\nimport script from \"./Infobox.vue?vue&type=script&lang=ts\"\nexport * from \"./Infobox.vue?vue&type=script&lang=ts\"\n\nimport \"./Infobox.vue?vue&type=style&index=0&id=6447a93e&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-6447a93e\"]])\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n GatherProps,\n getUniqueID,\n OptionsFunc,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport InfoboxComponent from \"features/infoboxes/Infobox.vue\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { unref } from \"vue\";\n\nexport const InfoboxType = Symbol(\"Infobox\");\n\nexport interface InfoboxOptions {\n visibility?: Computable<Visibility>;\n color?: Computable<string>;\n style?: Computable<StyleValue>;\n titleStyle?: Computable<StyleValue>;\n bodyStyle?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n title: Computable<CoercableComponent>;\n display: Computable<CoercableComponent>;\n}\n\nexport interface BaseInfobox {\n id: string;\n collapsed: Persistent<boolean>;\n type: typeof InfoboxType;\n [Component]: typeof InfoboxComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Infobox<T extends InfoboxOptions> = Replace<\n T & BaseInfobox,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n color: GetComputableType<T[\"color\"]>;\n style: GetComputableType<T[\"style\"]>;\n titleStyle: GetComputableType<T[\"titleStyle\"]>;\n bodyStyle: GetComputableType<T[\"bodyStyle\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n title: GetComputableType<T[\"title\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericInfobox = Replace<\n Infobox<InfoboxOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createInfobox<T extends InfoboxOptions>(\n optionsFunc: OptionsFunc<T, Infobox<T>, BaseInfobox>\n): Infobox<T> {\n const collapsed = persistent<boolean>(false);\n return createLazyProxy(() => {\n const infobox = optionsFunc();\n infobox.id = getUniqueID(\"infobox-\");\n infobox.type = InfoboxType;\n infobox[Component] = InfoboxComponent;\n\n infobox.collapsed = collapsed;\n\n processComputable(infobox as T, \"visibility\");\n setDefault(infobox, \"visibility\", Visibility.Visible);\n processComputable(infobox as T, \"color\");\n processComputable(infobox as T, \"style\");\n processComputable(infobox as T, \"titleStyle\");\n processComputable(infobox as T, \"bodyStyle\");\n processComputable(infobox as T, \"classes\");\n processComputable(infobox as T, \"title\");\n processComputable(infobox as T, \"display\");\n\n infobox[GatherProps] = function (this: GenericInfobox) {\n const {\n visibility,\n display,\n title,\n color,\n collapsed,\n style,\n titleStyle,\n bodyStyle,\n classes,\n id\n } = this;\n return {\n visibility,\n display,\n title,\n color,\n collapsed,\n style: unref(style),\n titleStyle,\n bodyStyle,\n classes,\n id\n };\n };\n\n return infobox as unknown as Infobox<T>;\n });\n}\n","import { normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n return (_openBlock(), _createElementBlock(\"div\", {\n ref: \"resizeListener\",\n class: _normalizeClass([\"resize-listener\", _ctx.unref(_ctx.classes)]),\n style: _normalizeStyle(_ctx.unref(_ctx.style))\n }, null, 6))\n}","\nimport { StyleValue } from \"features/feature\";\nimport { Application } from \"pixi.js\";\nimport { processedPropType } from \"util/vue\";\nimport { defineComponent, nextTick, onBeforeUnmount, onMounted, PropType, ref, unref } from \"vue\";\n\n// TODO get typing support on the Particles component\nexport default defineComponent({\n props: {\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n onInit: {\n type: Function as PropType<(app: Application) => void>,\n required: true\n },\n id: {\n type: String,\n required: true\n },\n onContainerResized: Function as PropType<(rect: DOMRect) => void>,\n onHotReload: Function as PropType<VoidFunction>\n },\n setup(props) {\n const app = ref<null | Application>(null);\n\n const resizeObserver = new ResizeObserver(updateBounds);\n const resizeListener = ref<HTMLElement | null>(null);\n\n onMounted(() => {\n // ResizeListener exists because ResizeObserver's don't work when told to observe an SVG element\n const resListener = resizeListener.value;\n if (resListener != null) {\n resizeObserver.observe(resListener);\n app.value = new Application({\n resizeTo: resListener,\n backgroundAlpha: 0\n });\n resizeListener.value?.appendChild(app.value.view);\n props.onInit(app.value as Application);\n }\n updateBounds();\n if (props.onHotReload) {\n nextTick(props.onHotReload);\n }\n });\n onBeforeUnmount(() => {\n app.value?.destroy();\n });\n\n let isDirty = true;\n function updateBounds() {\n if (isDirty) {\n isDirty = false;\n nextTick(() => {\n if (resizeListener.value != null && props.onContainerResized) {\n props.onContainerResized(resizeListener.value.getBoundingClientRect());\n app.value?.resize();\n }\n isDirty = true;\n });\n }\n }\n document.fonts.ready.then(updateBounds);\n\n return {\n unref,\n resizeListener\n };\n }\n});\n","import { render } from \"./Particles.vue?vue&type=template&id=08c4e343&scoped=true&ts=true\"\nimport script from \"./Particles.vue?vue&type=script&lang=tsx\"\nexport * from \"./Particles.vue?vue&type=script&lang=tsx\"\n\nimport \"./Particles.vue?vue&type=style&index=0&id=08c4e343&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-08c4e343\"]])\n\nexport default __exports__","import ParticlesComponent from \"features/particles/Particles.vue\";\nimport { Ref, shallowRef, unref } from \"vue\";\nimport {\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n StyleValue\n} from \"features/feature\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { Application } from \"pixi.js\";\nimport { Emitter, EmitterConfigV3, upgradeConfig } from \"@pixi/particle-emitter\";\nimport { Computable, GetComputableType } from \"util/computed\";\n\nexport const ParticlesType = Symbol(\"Particles\");\n\nexport interface ParticlesOptions {\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n onContainerResized?: (boundingRect: DOMRect) => void;\n onHotReload?: VoidFunction;\n}\n\nexport interface BaseParticles {\n id: string;\n app: Ref<null | Application>;\n addEmitter: (config: EmitterConfigV3) => Promise<Emitter>;\n type: typeof ParticlesType;\n [Component]: typeof ParticlesComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Particles<T extends ParticlesOptions> = Replace<\n T & BaseParticles,\n {\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n }\n>;\n\nexport type GenericParticles = Particles<ParticlesOptions>;\n\nexport function createParticles<T extends ParticlesOptions>(\n optionsFunc?: OptionsFunc<T, Particles<T>, BaseParticles>\n): Particles<T> {\n return createLazyProxy(() => {\n const particles = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n particles.id = getUniqueID(\"particles-\");\n particles.type = ParticlesType;\n particles[Component] = ParticlesComponent;\n\n particles.app = shallowRef(null);\n particles.addEmitter = (config: EmitterConfigV3): Promise<Emitter> => {\n const genericParticles = particles as GenericParticles;\n if (genericParticles.app.value) {\n return Promise.resolve(new Emitter(genericParticles.app.value.stage, config));\n }\n return new Promise<Emitter>(resolve => {\n emittersToAdd.push({ resolve, config });\n });\n };\n\n let emittersToAdd: {\n resolve: (value: Emitter | PromiseLike<Emitter>) => void;\n config: EmitterConfigV3;\n }[] = [];\n\n function onInit(app: Application) {\n (particles as GenericParticles).app.value = app;\n emittersToAdd.forEach(({ resolve, config }) => resolve(new Emitter(app.stage, config)));\n emittersToAdd = [];\n }\n\n particles.onContainerResized = particles.onContainerResized?.bind(particles);\n\n particles[GatherProps] = function (this: GenericParticles) {\n const { id, style, classes, onContainerResized, onHotReload } = this;\n return {\n id,\n style: unref(style),\n classes,\n onContainerResized,\n onHotReload,\n onInit\n };\n };\n\n return particles as unknown as Particles<T>;\n });\n}\n\ndeclare global {\n interface Window {\n upgradeConfig: typeof upgradeConfig;\n }\n}\nwindow.upgradeConfig = upgradeConfig;\n","import { OptionsFunc, getUniqueID, Replace } from \"features/feature\";\nimport { globalBus } from \"game/events\";\nimport { GenericLayer } from \"game/layers\";\nimport { DefaultValue, Persistent, persistent, PersistentState } from \"game/persistence\";\nimport Decimal from \"util/bignum\";\nimport { Computable, GetComputableType, processComputable } from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { Unsubscribe } from \"nanoevents\";\nimport { isRef, unref } from \"vue\";\n\nexport const ResetType = Symbol(\"Reset\");\n\nexport interface ResetOptions {\n thingsToReset: Computable<Record<string, unknown>[]>;\n onReset?: VoidFunction;\n}\n\nexport interface BaseReset {\n id: string;\n reset: VoidFunction;\n type: typeof ResetType;\n}\n\nexport type Reset<T extends ResetOptions> = Replace<\n T & BaseReset,\n {\n thingsToReset: GetComputableType<T[\"thingsToReset\"]>;\n }\n>;\n\nexport type GenericReset = Reset<ResetOptions>;\n\nexport function createReset<T extends ResetOptions>(\n optionsFunc: OptionsFunc<T, Reset<T>, BaseReset>\n): Reset<T> {\n return createLazyProxy(() => {\n const reset = optionsFunc();\n reset.id = getUniqueID(\"reset-\");\n reset.type = ResetType;\n\n reset.reset = function () {\n const handleObject = (obj: unknown) => {\n if (obj && typeof obj === \"object\") {\n if (PersistentState in obj) {\n (obj as Persistent)[PersistentState].value = (obj as Persistent)[\n DefaultValue\n ];\n } else if (!(obj instanceof Decimal) && !isRef(obj)) {\n Object.values(obj).forEach(obj =>\n handleObject(obj as Record<string, unknown>)\n );\n }\n }\n };\n unref((reset as GenericReset).thingsToReset).forEach(handleObject);\n globalBus.emit(\"reset\", reset as GenericReset);\n reset.onReset?.();\n };\n\n processComputable(reset as T, \"thingsToReset\");\n\n return reset as unknown as Reset<T>;\n });\n}\n\nconst listeners: Record<string, Unsubscribe | undefined> = {};\nexport function trackResetTime(layer: GenericLayer, reset: GenericReset): Persistent<Decimal> {\n const resetTime = persistent<Decimal>(new Decimal(0));\n listeners[layer.id] = layer.on(\"preUpdate\", diff => {\n resetTime.value = Decimal.add(resetTime.value, diff);\n });\n globalBus.on(\"reset\", currentReset => {\n if (currentReset === reset) {\n resetTime.value = new Decimal(0);\n }\n });\n return resetTime;\n}\nglobalBus.on(\"removeLayer\", layer => {\n // unsubscribe from preUpdate\n listeners[layer.id]?.();\n listeners[layer.id] = undefined;\n});\n\ndeclare module \"game/events\" {\n interface GlobalEvents {\n reset: (reset: GenericReset) => void;\n }\n}\n","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, toDisplayString as _toDisplayString, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { displayResource, Resource } from \"features/resources/resource\";\nimport { computed } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n resource: null,\n color: null\n },\n setup(__props: any) {\n\nconst props = __props as {\n resource: Resource;\n color: string;\n}\n\n\n\nconst amount = computed(() => displayResource(props.resource));\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"h2\", {\n style: _normalizeStyle({ color: __props.color, 'text-shadow': '0px 0px 10px ' + __props.color })\n }, _toDisplayString(_unref(amount)), 5))\n}\n}\n\n})","import script from \"./Resource.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Resource.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createVNode as _createVNode, toDisplayString as _toDisplayString, resolveDynamicComponent as _resolveDynamicComponent, createBlock as _createBlock, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode } from \"vue\"\n\nconst _hoisted_1 = { key: 0 }\nconst _hoisted_2 = { key: 1 }\nconst _hoisted_3 = /*#__PURE__*/_createTextVNode(\", \")\nconst _hoisted_4 = /*#__PURE__*/_createElementVNode(\"br\", null, null, -1)\nconst _hoisted_5 = /*#__PURE__*/_createElementVNode(\"br\", null, null, -1)\n\nimport { CoercableComponent } from \"features/feature\";\nimport { Resource } from \"features/resources/resource\";\nimport Decimal from \"util/bignum\";\nimport { computeOptionalComponent } from \"util/vue\";\nimport { computed, Ref, StyleValue, toRefs } from \"vue\";\nimport ResourceVue from \"features/resources/Resource.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n resource: null,\n color: null,\n classes: null,\n style: null,\n effectDisplay: null\n },\n setup(__props: any) {\n\nconst _props = __props as {\n resource: Resource;\n color?: string;\n classes?: Record<string, boolean>;\n style?: StyleValue;\n effectDisplay?: CoercableComponent;\n}\n\n\nconst props = toRefs(_props);\n\nconst effectComponent = computeOptionalComponent(\n props.effectDisplay as Ref<CoercableComponent | undefined>\n);\n\nconst showPrefix = computed(() => {\n return Decimal.lt(props.resource.value, \"1e1000\");\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", null, [\n (_unref(showPrefix))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \"You have \"))\n : _createCommentVNode(\"\", true),\n _createVNode(ResourceVue, {\n resource: __props.resource,\n color: __props.color || 'white'\n }, null, 8, [\"resource\", \"color\"]),\n _createTextVNode(\" \" + _toDisplayString(__props.resource.displayName), 1),\n (_unref(effectComponent))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, [\n _hoisted_3,\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(effectComponent))))\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_4,\n _hoisted_5\n ]))\n}\n}\n\n})","import script from \"./MainDisplay.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./MainDisplay.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import TooltipComponent from \"./Tooltip.vue\";\nimport {\n CoercableComponent,\n Component,\n GatherProps,\n Replace,\n setDefault,\n StyleValue\n} from \"features/feature\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { VueFeature } from \"util/vue\";\nimport { nextTick, Ref, unref } from \"vue\";\nimport { persistent } from \"game/persistence\";\nimport { Direction } from \"util/common\";\n\ndeclare module \"@vue/runtime-dom\" {\n interface CSSProperties {\n \"--xoffset\"?: string;\n \"--yoffset\"?: string;\n }\n}\n\nexport interface TooltipOptions {\n pinnable?: boolean;\n display: Computable<CoercableComponent>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n direction?: Computable<Direction>;\n xoffset?: Computable<string>;\n yoffset?: Computable<string>;\n}\n\nexport interface BaseTooltip {\n pinned?: Ref<boolean>;\n}\n\nexport type Tooltip<T extends TooltipOptions> = Replace<\n T & BaseTooltip,\n {\n pinnable: T[\"pinnable\"] extends undefined ? false : T[\"pinnable\"];\n pinned: T[\"pinnable\"] extends true ? Ref<boolean> : undefined;\n display: GetComputableType<T[\"display\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n direction: GetComputableTypeWithDefault<T[\"direction\"], Direction.Up>;\n xoffset: GetComputableType<T[\"xoffset\"]>;\n yoffset: GetComputableType<T[\"yoffset\"]>;\n }\n>;\n\nexport type GenericTooltip = Replace<\n Tooltip<TooltipOptions>,\n {\n pinnable: boolean;\n pinned: Ref<boolean> | undefined;\n direction: ProcessedComputable<Direction>;\n }\n>;\n\nexport function addTooltip<T extends TooltipOptions>(\n element: VueFeature,\n options: T & ThisType<Tooltip<T>> & Partial<BaseTooltip>\n): Tooltip<T> {\n processComputable(options as T, \"display\");\n processComputable(options as T, \"classes\");\n processComputable(options as T, \"style\");\n processComputable(options as T, \"direction\");\n setDefault(options, \"direction\", Direction.Up);\n processComputable(options as T, \"xoffset\");\n processComputable(options as T, \"yoffset\");\n\n nextTick(() => {\n if (options.pinnable) {\n if (\"pinned\" in element) {\n console.error(\n \"Cannot add pinnable tooltip to element that already has a property called 'pinned'\"\n );\n options.pinnable = false;\n } else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (element as any).pinned = options.pinned = persistent<boolean>(false);\n }\n }\n\n const elementComponent = element[Component];\n element[Component] = TooltipComponent;\n const elementGratherProps = element[GatherProps].bind(element);\n element[GatherProps] = function gatherTooltipProps(this: GenericTooltip) {\n const { display, classes, style, direction, xoffset, yoffset, pinned } = this;\n return {\n element: {\n [Component]: elementComponent,\n [GatherProps]: elementGratherProps\n },\n display,\n classes,\n style: unref(style),\n direction,\n xoffset,\n yoffset,\n pinned\n };\n }.bind(options as GenericTooltip);\n });\n\n return options as unknown as Tooltip<T>;\n}\n","import \"components/common/modifiers.css\";\nimport { CoercableComponent, jsx } from \"features/feature\";\nimport Decimal, { DecimalSource, format } from \"util/bignum\";\nimport { WithRequired } from \"util/common\";\nimport { Computable, convertComputable, ProcessedComputable } from \"util/computed\";\nimport { renderJSX } from \"util/vue\";\nimport { computed, unref } from \"vue\";\n\n/**\n * An object that can be used to apply or unapply some modification to a number.\n * Being reversible requires the operation being invertible, but some features may rely on that.\n * Descriptions can be optionally included for displaying them to the player.\n * The built-in modifier creators are designed to display the modifiers using.\n * {@link createModifierSection}.\n */\nexport interface Modifier {\n /** Applies some operation on the input and returns the result. */\n apply: (gain: DecimalSource) => DecimalSource;\n /** Reverses the operation applied by the apply property. Required by some features. */\n revert?: (gain: DecimalSource) => DecimalSource;\n /**\n * Whether or not this modifier should be considered enabled.\n * Typically for use with modifiers passed into {@link createSequentialModifier}.\n */\n enabled?: ProcessedComputable<boolean>;\n /**\n * A description of this modifier.\n * @see {@link createModifierSection}.\n */\n description?: ProcessedComputable<CoercableComponent>;\n}\n\n/**\n * Utility type used to narrow down a modifier type that will have a description and/or enabled property based on optional parameters, T and S (respectively).\n */\nexport type ModifierFromOptionalParams<T, S> = T extends undefined\n ? S extends undefined\n ? Omit<WithRequired<Modifier, \"revert\">, \"description\" | \"enabled\">\n : Omit<WithRequired<Modifier, \"revert\" | \"enabled\">, \"description\">\n : S extends undefined\n ? Omit<WithRequired<Modifier, \"revert\" | \"description\">, \"enabled\">\n : WithRequired<Modifier, \"revert\" | \"enabled\" | \"description\">;\n\n/**\n * Create a modifier that adds some value to the input value.\n * @param addend The amount to add to the input value.\n * @param description Description of what this modifier is doing.\n * @param enabled A computable that will be processed and passed directly into the returned modifier.\n */\nexport function createAdditiveModifier<\n T extends Computable<CoercableComponent> | undefined,\n S extends Computable<boolean> | undefined,\n R = ModifierFromOptionalParams<T, S>\n>(addend: Computable<DecimalSource>, description?: T, enabled?: S): R {\n const processedAddend = convertComputable(addend);\n const processedDescription = convertComputable(description);\n const processedEnabled = enabled == null ? undefined : convertComputable(enabled);\n return {\n apply: (gain: DecimalSource) => Decimal.add(gain, unref(processedAddend)),\n revert: (gain: DecimalSource) => Decimal.sub(gain, unref(processedAddend)),\n enabled: processedEnabled,\n description:\n description == null\n ? undefined\n : jsx(() => (\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">\n {Decimal.gte(unref(processedAddend), 0) ? \"+\" : \"\"}\n {format(unref(processedAddend))}\n </span>\n {unref(processedDescription) ? (\n <span class=\"modifier-description\">\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n {renderJSX(unref(processedDescription)!)}\n </span>\n ) : null}\n </div>\n ))\n } as unknown as R;\n}\n\n/**\n * Create a modifier that multiplies the input value by some value.\n * @param multiplier The value to multiply the input value by.\n * @param description Description of what this modifier is doing.\n * @param enabled A computable that will be processed and passed directly into the returned modifier.\n */\nexport function createMultiplicativeModifier<\n T extends Computable<CoercableComponent> | undefined,\n S extends Computable<boolean> | undefined,\n R = ModifierFromOptionalParams<T, S>\n>(multiplier: Computable<DecimalSource>, description?: T, enabled?: S): R {\n const processedMultiplier = convertComputable(multiplier);\n const processedDescription = convertComputable(description);\n const processedEnabled = enabled == null ? undefined : convertComputable(enabled);\n return {\n apply: (gain: DecimalSource) => Decimal.times(gain, unref(processedMultiplier)),\n revert: (gain: DecimalSource) => Decimal.div(gain, unref(processedMultiplier)),\n enabled: processedEnabled,\n description:\n description == null\n ? undefined\n : jsx(() => (\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">x{format(unref(processedMultiplier))}</span>\n {unref(processedDescription) ? (\n <span class=\"modifier-description\">\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n {renderJSX(unref(processedDescription)!)}\n </span>\n ) : null}\n </div>\n ))\n } as unknown as R;\n}\n\n/**\n * Create a modifier that raises the input value to the power of some value.\n * @param exponent The value to raise the input value to the power of.\n * @param description Description of what this modifier is doing.\n * @param enabled A computable that will be processed and passed directly into the returned modifier.\n */\nexport function createExponentialModifier<\n T extends Computable<CoercableComponent> | undefined,\n S extends Computable<boolean> | undefined,\n R = ModifierFromOptionalParams<T, S>\n>(exponent: Computable<DecimalSource>, description?: T, enabled?: S): R {\n const processedExponent = convertComputable(exponent);\n const processedDescription = convertComputable(description);\n const processedEnabled = enabled == null ? undefined : convertComputable(enabled);\n return {\n apply: (gain: DecimalSource) => Decimal.pow(gain, unref(processedExponent)),\n revert: (gain: DecimalSource) => Decimal.root(gain, unref(processedExponent)),\n enabled: processedEnabled,\n description:\n description == null\n ? undefined\n : jsx(() => (\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">^{format(unref(processedExponent))}</span>\n {unref(processedDescription) ? (\n <span class=\"modifier-description\">\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n {renderJSX(unref(processedDescription)!)}\n </span>\n ) : null}\n </div>\n ))\n } as unknown as R;\n}\n\n/**\n * Takes an array of modifiers and applies and reverses them in order.\n * Modifiers that are not enabled will not be applied nor reversed.\n * Also joins their descriptions together.\n * @param modifiers The modifiers to perform sequentially.\n * @see {@link createModifierSection}.\n */\nexport function createSequentialModifier<\n T extends Modifier[],\n S = T extends WithRequired<Modifier, \"revert\">[]\n ? WithRequired<Modifier, \"description\" | \"revert\">\n : Omit<WithRequired<Modifier, \"description\">, \"revert\">\n>(...modifiers: T): S {\n return {\n apply: (gain: DecimalSource) =>\n modifiers\n .filter(m => unref(m.enabled) !== false)\n .reduce((gain, modifier) => modifier.apply(gain), gain),\n revert: modifiers.every(m => m.revert != null)\n ? (gain: DecimalSource) =>\n modifiers\n .filter(m => unref(m.enabled) !== false)\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n .reduceRight((gain, modifier) => modifier.revert!(gain), gain)\n : undefined,\n enabled: computed(() => modifiers.filter(m => unref(m.enabled) !== false).length > 0),\n description: jsx(() => (\n <>\n {(\n modifiers\n .filter(m => unref(m.enabled) !== false)\n .map(m => unref(m.description))\n .filter(d => d) as CoercableComponent[]\n ).map(renderJSX)}\n </>\n ))\n } as unknown as S;\n}\n\n/**\n * Create a JSX element that displays a modifier.\n * Intended to be used with the output from {@link createSequentialModifier}.\n * @param title The header for the section.\n * @param subtitle Smaller text that appears in the header after the title.\n * @param modifier The modifier to render.\n * @param base The base value that'll be passed into the modifier.\n * @param unit The unit of the value being modified, if any.\n * @param baseText The label to use for the base value.\n */\nexport function createModifierSection(\n title: string,\n subtitle: string,\n modifier: WithRequired<Modifier, \"description\">,\n base: DecimalSource = 1,\n unit = \"\",\n baseText: CoercableComponent = \"Base\"\n) {\n return (\n <div>\n <h3>\n {title}\n {subtitle ? <span class=\"subtitle\"> ({subtitle})</span> : null}\n </h3>\n <br />\n <div class=\"modifier-container\">\n <span class=\"modifier-amount\">\n {format(base)}\n {unit}\n </span>\n <span class=\"modifier-description\">{renderJSX(baseText)}</span>\n </div>\n {renderJSX(unref(modifier.description))}\n <hr />\n Total: {format(modifier.apply(base))}\n {unit}\n </div>\n );\n}\n","import { defineComponent as _defineComponent } from 'vue'\nimport { toDisplayString as _toDisplayString, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, unref as _unref, isRef as _isRef, vModelText as _vModelText, createElementVNode as _createElementVNode, withDirectives as _withDirectives, normalizeClass as _normalizeClass, withCtx as _withCtx, createVNode as _createVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-38661d49\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"field\" }\nconst _hoisted_2 = {\n key: 0,\n class: \"field-title\"\n}\nconst _hoisted_3 = [\"min\", \"max\"]\n\nimport { computed, toRefs, unref } from \"vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport \"components/common/fields.css\";\nimport { Direction } from \"util/common\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: null,\n min: null,\n max: null\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: number): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n title?: string;\n modelValue?: number;\n min?: number;\n max?: number;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst value = computed({\n get() {\n return String(unref(props.modelValue) || 0);\n },\n set(value: string) {\n emit(\"update:modelValue\", Number(value));\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (__props.title)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, _toDisplayString(__props.title), 1))\n : _createCommentVNode(\"\", true),\n _createVNode(Tooltip, {\n display: `${_unref(value)}`,\n class: _normalizeClass({ fullWidth: !__props.title }),\n direction: _unref(Direction).Down\n }, {\n default: _withCtx(() => [\n _withDirectives(_createElementVNode(\"input\", {\n type: \"range\",\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(value) ? (value).value = $event : null)),\n min: __props.min,\n max: __props.max\n }, null, 8, _hoisted_3), [\n [_vModelText, _unref(value)]\n ])\n ]),\n _: 1\n }, 8, [\"display\", \"class\", \"direction\"])\n ]))\n}\n}\n\n})","import script from \"./Slider.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Slider.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Slider.vue?vue&type=style&index=0&id=38661d49&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-38661d49\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport { nextTick, onMounted, ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst top = ref(\"0\");\nconst observer = new ResizeObserver(updateTop);\nconst element = ref<HTMLElement | null>(null);\n\nfunction updateTop() {\n let el = element.value;\n if (el == undefined) {\n return;\n }\n\n let newTop = 0;\n while (el.previousSibling) {\n const sibling = el.previousSibling as HTMLElement;\n if (sibling.dataset && \"vSticky\" in sibling.dataset) {\n newTop += sibling.offsetHeight;\n }\n el = sibling;\n }\n top.value = newTop + \"px\";\n}\n\nnextTick(updateTop);\ndocument.fonts.ready.then(updateTop);\n\nonMounted(() => {\n const el = element.value?.parentElement;\n if (el) {\n observer.observe(el);\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"sticky\",\n style: _normalizeStyle({ top: top.value }),\n ref_key: \"element\",\n ref: element,\n \"data-v-sticky\": \"\"\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 4))\n}\n}\n\n})","import script from \"./Sticky.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Sticky.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Sticky.vue?vue&type=style&index=0&id=77aa21df&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-77aa21df\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n height: null\n },\n setup(__props: any) {\n\n\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: \"vr\",\n style: _normalizeStyle({ height: __props.height })\n }, null, 4))\n}\n}\n\n})","import script from \"./VerticalRule.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./VerticalRule.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./VerticalRule.vue?vue&type=style&index=0&id=15f6e746&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-15f6e746\"]])\n\nexport default __exports__","import { resolveDynamicComponent as _resolveDynamicComponent, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, createElementBlock as _createElementBlock } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n width: _ctx.unref(_ctx.width) + 'px',\n height: _ctx.unref(_ctx.height) + 'px',\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n class: _normalizeClass({\n bar: true,\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n _createElementVNode(\"div\", {\n class: \"overlayTextContainer border\",\n style: _normalizeStyle([\n { width: _ctx.unref(_ctx.width) + 'px', height: _ctx.unref(_ctx.height) + 'px' },\n _ctx.unref(_ctx.borderStyle) ?? {}\n ])\n }, [\n (_ctx.component)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component), {\n key: 0,\n class: \"overlayText\",\n style: _normalizeStyle(_ctx.unref(_ctx.textStyle))\n }, null, 8, [\"style\"]))\n : _createCommentVNode(\"\", true)\n ], 4),\n _createElementVNode(\"div\", {\n class: \"border\",\n style: _normalizeStyle([\n { width: _ctx.unref(_ctx.width) + 'px', height: _ctx.unref(_ctx.height) + 'px' },\n _ctx.unref(_ctx.style) ?? {},\n _ctx.unref(_ctx.baseStyle) ?? {},\n _ctx.unref(_ctx.borderStyle) ?? {}\n ])\n }, [\n _createElementVNode(\"div\", {\n class: \"fill\",\n style: _normalizeStyle([_ctx.barStyle, _ctx.unref(_ctx.style) ?? {}, _ctx.unref(_ctx.fillStyle) ?? {}])\n }, null, 4)\n ], 4),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport { CoercableComponent, Visibility } from \"features/feature\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { computeOptionalComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport { computed, CSSProperties, defineComponent, StyleValue, toRefs, unref } from \"vue\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { Direction } from \"util/common\";\n\nexport default defineComponent({\n props: {\n progress: {\n type: processedPropType<DecimalSource>(String, Object, Number),\n required: true\n },\n width: {\n type: processedPropType<number>(Number),\n required: true\n },\n height: {\n type: processedPropType<number>(Number),\n required: true\n },\n direction: {\n type: processedPropType<Direction>(String),\n required: true\n },\n display: processedPropType<CoercableComponent>(Object, String, Function),\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n borderStyle: processedPropType<StyleValue>(Object, String, Array),\n textStyle: processedPropType<StyleValue>(Object, String, Array),\n baseStyle: processedPropType<StyleValue>(Object, String, Array),\n fillStyle: processedPropType<StyleValue>(Object, String, Array),\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n }\n },\n components: {\n MarkNode,\n Node\n },\n setup(props) {\n const { progress, width, height, direction, display } = toRefs(props);\n\n const normalizedProgress = computed(() => {\n let progressNumber =\n progress.value instanceof Decimal\n ? progress.value.toNumber()\n : Number(progress.value);\n return (1 - Math.min(Math.max(progressNumber, 0), 1)) * 100;\n });\n\n const barStyle = computed(() => {\n const barStyle: Partial<CSSProperties> = {\n width: unwrapRef(width) + 0.5 + \"px\",\n height: unwrapRef(height) + 0.5 + \"px\"\n };\n switch (unref(direction)) {\n case Direction.Up:\n barStyle.clipPath = `inset(${normalizedProgress.value}% 0% 0% 0%)`;\n barStyle.width = unwrapRef(width) + 1 + \"px\";\n break;\n case Direction.Down:\n barStyle.clipPath = `inset(0% 0% ${normalizedProgress.value}% 0%)`;\n barStyle.width = unwrapRef(width) + 1 + \"px\";\n break;\n case Direction.Right:\n barStyle.clipPath = `inset(0% ${normalizedProgress.value}% 0% 0%)`;\n break;\n case Direction.Left:\n barStyle.clipPath = `inset(0% 0% 0% ${normalizedProgress.value} + '%)`;\n break;\n case Direction.Default:\n barStyle.clipPath = \"inset(0% 50% 0% 0%)\";\n break;\n }\n return barStyle;\n });\n\n const component = computeOptionalComponent(display);\n\n return {\n normalizedProgress,\n barStyle,\n component,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Bar.vue?vue&type=template&id=bfa7e8b2&scoped=true&ts=true\"\nimport script from \"./Bar.vue?vue&type=script&lang=ts\"\nexport * from \"./Bar.vue?vue&type=script&lang=ts\"\n\nimport \"./Bar.vue?vue&type=style&index=0&id=bfa7e8b2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-bfa7e8b2\"]])\n\nexport default __exports__","import BarComponent from \"features/bars/Bar.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { DecimalSource } from \"util/bignum\";\nimport { Direction } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { unref } from \"vue\";\n\nexport const BarType = Symbol(\"Bar\");\n\nexport interface BarOptions {\n visibility?: Computable<Visibility>;\n width: Computable<number>;\n height: Computable<number>;\n direction: Computable<Direction>;\n style?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n borderStyle?: Computable<StyleValue>;\n baseStyle?: Computable<StyleValue>;\n textStyle?: Computable<StyleValue>;\n fillStyle?: Computable<StyleValue>;\n progress: Computable<DecimalSource>;\n display?: Computable<CoercableComponent>;\n mark?: Computable<boolean | string>;\n}\n\nexport interface BaseBar {\n id: string;\n type: typeof BarType;\n [Component]: typeof BarComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Bar<T extends BarOptions> = Replace<\n T & BaseBar,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n width: GetComputableType<T[\"width\"]>;\n height: GetComputableType<T[\"height\"]>;\n direction: GetComputableType<T[\"direction\"]>;\n style: GetComputableType<T[\"style\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n borderStyle: GetComputableType<T[\"borderStyle\"]>;\n baseStyle: GetComputableType<T[\"baseStyle\"]>;\n textStyle: GetComputableType<T[\"textStyle\"]>;\n fillStyle: GetComputableType<T[\"fillStyle\"]>;\n progress: GetComputableType<T[\"progress\"]>;\n display: GetComputableType<T[\"display\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n }\n>;\n\nexport type GenericBar = Replace<\n Bar<BarOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createBar<T extends BarOptions>(\n optionsFunc: OptionsFunc<T, Bar<T>, BaseBar>\n): Bar<T> {\n return createLazyProxy(() => {\n const bar = optionsFunc();\n bar.id = getUniqueID(\"bar-\");\n bar.type = BarType;\n bar[Component] = BarComponent;\n\n processComputable(bar as T, \"visibility\");\n setDefault(bar, \"visibility\", Visibility.Visible);\n processComputable(bar as T, \"width\");\n processComputable(bar as T, \"height\");\n processComputable(bar as T, \"direction\");\n processComputable(bar as T, \"style\");\n processComputable(bar as T, \"classes\");\n processComputable(bar as T, \"borderStyle\");\n processComputable(bar as T, \"baseStyle\");\n processComputable(bar as T, \"textStyle\");\n processComputable(bar as T, \"fillStyle\");\n processComputable(bar as T, \"progress\");\n processComputable(bar as T, \"display\");\n processComputable(bar as T, \"mark\");\n\n bar[GatherProps] = function (this: GenericBar) {\n const {\n progress,\n width,\n height,\n direction,\n display,\n visibility,\n style,\n classes,\n borderStyle,\n textStyle,\n baseStyle,\n fillStyle,\n mark,\n id\n } = this;\n return {\n progress,\n width,\n height,\n direction,\n display,\n visibility,\n style: unref(style),\n classes,\n borderStyle,\n textStyle,\n baseStyle,\n fillStyle,\n mark,\n id\n };\n };\n\n return bar as unknown as Bar<T>;\n });\n}\n","import ClickableComponent from \"features/clickables/Clickable.vue\";\nimport { Resource } from \"features/resources/resource\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport Decimal, { DecimalSource, format, formatWhole } from \"util/bignum\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { coerceComponent, isCoercableComponent } from \"util/vue\";\nimport { computed, Ref, unref } from \"vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n jsx,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"./feature\";\n\nexport const BuyableType = Symbol(\"Buyable\");\n\nexport type BuyableDisplay =\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n effectDisplay?: CoercableComponent;\n };\n\nexport interface BuyableOptions {\n visibility?: Computable<Visibility>;\n cost?: Computable<DecimalSource>;\n resource?: Resource;\n canPurchase?: Computable<boolean>;\n purchaseLimit?: Computable<DecimalSource>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n mark?: Computable<boolean | string>;\n small?: Computable<boolean>;\n display?: Computable<BuyableDisplay>;\n onPurchase?: (cost: DecimalSource | undefined) => void;\n}\n\nexport interface BaseBuyable {\n id: string;\n amount: Persistent<DecimalSource>;\n maxed: Ref<boolean>;\n canAfford: Ref<boolean>;\n canClick: ProcessedComputable<boolean>;\n onClick: VoidFunction;\n purchase: VoidFunction;\n type: typeof BuyableType;\n [Component]: typeof ClickableComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Buyable<T extends BuyableOptions> = Replace<\n T & BaseBuyable,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n cost: GetComputableType<T[\"cost\"]>;\n resource: GetComputableType<T[\"resource\"]>;\n canPurchase: GetComputableTypeWithDefault<T[\"canPurchase\"], Ref<boolean>>;\n purchaseLimit: GetComputableTypeWithDefault<T[\"purchaseLimit\"], Decimal>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n small: GetComputableType<T[\"small\"]>;\n display: Ref<CoercableComponent>;\n }\n>;\n\nexport type GenericBuyable = Replace<\n Buyable<BuyableOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canPurchase: ProcessedComputable<boolean>;\n purchaseLimit: ProcessedComputable<DecimalSource>;\n }\n>;\n\nexport function createBuyable<T extends BuyableOptions>(\n optionsFunc: OptionsFunc<T, Buyable<T>, BaseBuyable>\n): Buyable<T> {\n const amount = persistent<DecimalSource>(0);\n return createLazyProxy(() => {\n const buyable = optionsFunc();\n\n if (buyable.canPurchase == null && (buyable.resource == null || buyable.cost == null)) {\n console.warn(\n \"Cannot create buyable without a canPurchase property or a resource and cost property\",\n buyable\n );\n throw \"Cannot create buyable without a canPurchase property or a resource and cost property\";\n }\n\n buyable.id = getUniqueID(\"buyable-\");\n buyable.type = BuyableType;\n buyable[Component] = ClickableComponent;\n\n buyable.amount = amount;\n buyable.canAfford = computed(() => {\n const genericBuyable = buyable as GenericBuyable;\n const cost = unref(genericBuyable.cost);\n return (\n genericBuyable.resource != null &&\n cost != null &&\n Decimal.gte(genericBuyable.resource.value, cost)\n );\n });\n if (buyable.canPurchase == null) {\n buyable.canPurchase = computed(\n () =>\n unref((buyable as GenericBuyable).visibility) === Visibility.Visible &&\n unref((buyable as GenericBuyable).canAfford) &&\n Decimal.lt(\n (buyable as GenericBuyable).amount.value,\n unref((buyable as GenericBuyable).purchaseLimit)\n )\n );\n }\n buyable.maxed = computed(() =>\n Decimal.gte(\n (buyable as GenericBuyable).amount.value,\n unref((buyable as GenericBuyable).purchaseLimit)\n )\n );\n processComputable(buyable as T, \"classes\");\n const classes = buyable.classes as ProcessedComputable<Record<string, boolean>> | undefined;\n buyable.classes = computed(() => {\n const currClasses = unref(classes) || {};\n if ((buyable as GenericBuyable).maxed.value) {\n currClasses.bought = true;\n }\n return currClasses;\n });\n processComputable(buyable as T, \"canPurchase\");\n buyable.canClick = buyable.canPurchase as ProcessedComputable<boolean>;\n buyable.onClick = buyable.purchase =\n buyable.onClick ??\n buyable.purchase ??\n function (this: GenericBuyable) {\n const genericBuyable = buyable as GenericBuyable;\n if (!unref(genericBuyable.canPurchase)) {\n return;\n }\n const cost = unref(genericBuyable.cost);\n if (genericBuyable.cost != null && genericBuyable.resource != null) {\n genericBuyable.resource.value = Decimal.sub(\n genericBuyable.resource.value,\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n cost!\n );\n genericBuyable.amount.value = Decimal.add(genericBuyable.amount.value, 1);\n }\n genericBuyable.onPurchase?.(cost);\n };\n processComputable(buyable as T, \"display\");\n const display = buyable.display;\n buyable.display = jsx(() => {\n // TODO once processComputable types correctly, remove this \"as X\"\n const currDisplay = unref(display) as BuyableDisplay;\n if (isCoercableComponent(currDisplay)) {\n const CurrDisplay = coerceComponent(currDisplay);\n return <CurrDisplay />;\n }\n if (currDisplay != null && buyable.cost != null && buyable.resource != null) {\n const genericBuyable = buyable as GenericBuyable;\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description);\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\");\n const amountDisplay =\n unref(genericBuyable.purchaseLimit) === Decimal.dInf ? (\n <>Amount: {formatWhole(genericBuyable.amount.value)}</>\n ) : (\n <>\n Amount: {formatWhole(genericBuyable.amount.value)} /{\" \"}\n {formatWhole(unref(genericBuyable.purchaseLimit))}\n </>\n );\n\n return (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n <div>\n <br />\n {amountDisplay}\n </div>\n {currDisplay.effectDisplay ? (\n <div>\n <br />\n Currently: <EffectDisplay />\n </div>\n ) : null}\n {genericBuyable.cost && !genericBuyable.maxed.value ? (\n <div>\n <br />\n Cost: {format(unref(genericBuyable.cost) || 0)}{\" \"}\n {buyable.resource.displayName}\n </div>\n ) : null}\n </span>\n );\n }\n return \"\";\n });\n\n processComputable(buyable as T, \"visibility\");\n setDefault(buyable, \"visibility\", Visibility.Visible);\n processComputable(buyable as T, \"cost\");\n processComputable(buyable as T, \"resource\");\n processComputable(buyable as T, \"purchaseLimit\");\n setDefault(buyable, \"purchaseLimit\", Decimal.dInf);\n processComputable(buyable as T, \"style\");\n processComputable(buyable as T, \"mark\");\n processComputable(buyable as T, \"small\");\n\n buyable[GatherProps] = function (this: GenericBuyable) {\n const { display, visibility, style, classes, onClick, canClick, small, mark, id } =\n this;\n return {\n display,\n visibility,\n style: unref(style),\n classes,\n onClick,\n canClick,\n small,\n mark,\n id\n };\n };\n\n return buyable as unknown as Buyable<T>;\n });\n}\n","import { toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-5e580749\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"disabled\"]\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.notifyStyle,\n _ctx.unref(_ctx.style) ?? {}\n ]),\n class: _normalizeClass({\n feature: true,\n challenge: true,\n done: _ctx.unref(_ctx.completed),\n canStart: _ctx.unref(_ctx.canStart) && !_ctx.unref(_ctx.maxed),\n maxed: _ctx.unref(_ctx.maxed),\n ..._ctx.unref(_ctx.classes)\n })\n }, [\n _createElementVNode(\"button\", {\n class: \"toggleChallenge\",\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.toggle && _ctx.toggle(...args))),\n disabled: !_ctx.unref(_ctx.canStart) || _ctx.unref(_ctx.maxed)\n }, _toDisplayString(_ctx.buttonText), 9, _hoisted_1),\n (_ctx.unref(_ctx.comp))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp)), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport { GenericChallenge } from \"features/challenges/challenge\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport { getHighNotifyStyle, getNotifyStyle } from \"game/notifications\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport {\n Component,\n computed,\n defineComponent,\n PropType,\n shallowRef,\n toRefs,\n unref,\n UnwrapRef,\n watchEffect\n} from \"vue\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\n\nexport default defineComponent({\n props: {\n active: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n maxed: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n canComplete: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n display: processedPropType<UnwrapRef<GenericChallenge[\"display\"]>>(\n String,\n Object,\n Function\n ),\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n completed: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n canStart: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n },\n toggle: {\n type: Function as PropType<VoidFunction>,\n required: true\n }\n },\n components: {\n MarkNode,\n Node\n },\n setup(props) {\n const { active, maxed, canComplete, display } = toRefs(props);\n\n const buttonText = computed(() => {\n if (active.value) {\n return canComplete.value ? \"Finish\" : \"Exit Early\";\n }\n if (maxed.value) {\n return \"Completed\";\n }\n return \"Start\";\n });\n\n const comp = shallowRef<Component | string>(\"\");\n\n const notifyStyle = computed(() => {\n const currActive = unwrapRef(active);\n const currCanComplete = unwrapRef(canComplete);\n if (currActive) {\n if (currCanComplete) {\n return getHighNotifyStyle();\n }\n return getNotifyStyle();\n }\n return {};\n });\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n comp.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n comp.value = coerceComponent(currDisplay);\n return;\n }\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description, \"div\");\n const Goal = coerceComponent(currDisplay.goal || \"\");\n const Reward = coerceComponent(currDisplay.reward || \"\");\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\");\n comp.value = coerceComponent(\n jsx(() => (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n {currDisplay.goal ? (\n <div>\n <br />\n Goal: <Goal />\n </div>\n ) : null}\n {currDisplay.reward ? (\n <div>\n <br />\n Reward: <Reward />\n </div>\n ) : null}\n {currDisplay.effectDisplay ? (\n <div>\n Currently: <EffectDisplay />\n </div>\n ) : null}\n </span>\n ))\n );\n });\n\n return {\n buttonText,\n notifyStyle,\n comp,\n Visibility,\n unref\n };\n }\n});\n","import { render } from \"./Challenge.vue?vue&type=template&id=5e580749&scoped=true&ts=true\"\nimport script from \"./Challenge.vue?vue&type=script&lang=tsx\"\nexport * from \"./Challenge.vue?vue&type=script&lang=tsx\"\n\nimport \"./Challenge.vue?vue&type=style&index=0&id=5e580749&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-5e580749\"]])\n\nexport default __exports__","import { isArray } from \"@vue/shared\";\nimport Toggle from \"components/fields/Toggle.vue\";\nimport ChallengeComponent from \"features/challenges/Challenge.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n jsx,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { GenericReset } from \"features/reset\";\nimport { Resource } from \"features/resources/resource\";\nimport { globalBus } from \"game/events\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport settings, { registerSettingField } from \"game/settings\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref, watch, WatchStopHandle } from \"vue\";\n\nexport const ChallengeType = Symbol(\"ChallengeType\");\n\nexport interface ChallengeOptions {\n visibility?: Computable<Visibility>;\n canStart?: Computable<boolean>;\n reset?: GenericReset;\n canComplete?: Computable<boolean | DecimalSource>;\n completionLimit?: Computable<DecimalSource>;\n mark?: Computable<boolean | string>;\n resource?: Resource;\n goal?: Computable<DecimalSource>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n display?: Computable<\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n goal?: CoercableComponent;\n reward?: CoercableComponent;\n effectDisplay?: CoercableComponent;\n }\n >;\n onComplete?: VoidFunction;\n onExit?: VoidFunction;\n onEnter?: VoidFunction;\n}\n\nexport interface BaseChallenge {\n id: string;\n completions: Persistent<DecimalSource>;\n completed: Ref<boolean>;\n maxed: Ref<boolean>;\n active: Persistent<boolean>;\n toggle: VoidFunction;\n complete: (remainInChallenge?: boolean) => void;\n type: typeof ChallengeType;\n [Component]: typeof ChallengeComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Challenge<T extends ChallengeOptions> = Replace<\n T & BaseChallenge,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n canStart: GetComputableTypeWithDefault<T[\"canStart\"], true>;\n canComplete: GetComputableTypeWithDefault<T[\"canComplete\"], Ref<boolean>>;\n completionLimit: GetComputableTypeWithDefault<T[\"completionLimit\"], 1>;\n mark: GetComputableTypeWithDefault<T[\"mark\"], Ref<boolean>>;\n goal: GetComputableType<T[\"goal\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericChallenge = Replace<\n Challenge<ChallengeOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canStart: ProcessedComputable<boolean>;\n canComplete: ProcessedComputable<boolean | DecimalSource>;\n completionLimit: ProcessedComputable<DecimalSource>;\n mark: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createChallenge<T extends ChallengeOptions>(\n optionsFunc: OptionsFunc<T, Challenge<T>, BaseChallenge>\n): Challenge<T> {\n const completions = persistent(0);\n const active = persistent(false);\n return createLazyProxy(() => {\n const challenge = optionsFunc();\n\n if (\n challenge.canComplete == null &&\n (challenge.resource == null || challenge.goal == null)\n ) {\n console.warn(\n \"Cannot create challenge without a canComplete property or a resource and goal property\",\n challenge\n );\n throw \"Cannot create challenge without a canComplete property or a resource and goal property\";\n }\n\n challenge.id = getUniqueID(\"challenge-\");\n challenge.type = ChallengeType;\n challenge[Component] = ChallengeComponent;\n\n challenge.completions = completions;\n challenge.active = active;\n challenge.completed = computed(() =>\n Decimal.gt((challenge as GenericChallenge).completions.value, 0)\n );\n challenge.maxed = computed(() =>\n Decimal.gte(\n (challenge as GenericChallenge).completions.value,\n unref((challenge as GenericChallenge).completionLimit)\n )\n );\n challenge.toggle = function () {\n const genericChallenge = challenge as GenericChallenge;\n if (genericChallenge.active.value) {\n if (unref(genericChallenge.canComplete) && !genericChallenge.maxed.value) {\n let completions: boolean | DecimalSource = unref(genericChallenge.canComplete);\n if (typeof completions === \"boolean\") {\n completions = 1;\n }\n genericChallenge.completions.value = Decimal.min(\n Decimal.add(genericChallenge.completions.value, completions),\n unref(genericChallenge.completionLimit)\n );\n genericChallenge.onComplete?.();\n }\n genericChallenge.active.value = false;\n genericChallenge.onExit?.();\n genericChallenge.reset?.reset();\n } else if (\n unref(genericChallenge.canStart) &&\n unref(genericChallenge.visibility) === Visibility.Visible &&\n !genericChallenge.maxed.value\n ) {\n genericChallenge.reset?.reset();\n genericChallenge.active.value = true;\n genericChallenge.onEnter?.();\n }\n };\n challenge.complete = function (remainInChallenge?: boolean) {\n const genericChallenge = challenge as GenericChallenge;\n let completions: boolean | DecimalSource = unref(genericChallenge.canComplete);\n if (\n genericChallenge.active.value &&\n completions !== false &&\n (completions === true || Decimal.neq(0, completions)) &&\n !genericChallenge.maxed.value\n ) {\n if (typeof completions === \"boolean\") {\n completions = 1;\n }\n genericChallenge.completions.value = Decimal.min(\n Decimal.add(genericChallenge.completions.value, completions),\n unref(genericChallenge.completionLimit)\n );\n genericChallenge.onComplete?.();\n if (remainInChallenge !== true) {\n genericChallenge.active.value = false;\n genericChallenge.onExit?.();\n genericChallenge.reset?.reset();\n }\n }\n };\n processComputable(challenge as T, \"visibility\");\n setDefault(challenge, \"visibility\", Visibility.Visible);\n const visibility = challenge.visibility as ProcessedComputable<Visibility>;\n challenge.visibility = computed(() => {\n if (settings.hideChallenges === true && unref(challenge.maxed)) {\n return Visibility.None;\n }\n return unref(visibility);\n });\n if (challenge.canComplete == null) {\n challenge.canComplete = computed(() => {\n const genericChallenge = challenge as GenericChallenge;\n if (\n !genericChallenge.active.value ||\n genericChallenge.resource == null ||\n genericChallenge.goal == null\n ) {\n return false;\n }\n return Decimal.gte(genericChallenge.resource.value, unref(genericChallenge.goal));\n });\n }\n if (challenge.mark == null) {\n challenge.mark = computed(\n () =>\n Decimal.gt(unref((challenge as GenericChallenge).completionLimit), 1) &&\n !!unref(challenge.maxed)\n );\n }\n\n processComputable(challenge as T, \"canStart\");\n setDefault(challenge, \"canStart\", true);\n processComputable(challenge as T, \"canComplete\");\n processComputable(challenge as T, \"completionLimit\");\n setDefault(challenge, \"completionLimit\", 1);\n processComputable(challenge as T, \"mark\");\n processComputable(challenge as T, \"goal\");\n processComputable(challenge as T, \"classes\");\n processComputable(challenge as T, \"style\");\n processComputable(challenge as T, \"display\");\n\n if (challenge.reset != null) {\n globalBus.on(\"reset\", currentReset => {\n if (currentReset === challenge.reset && (challenge.active as Ref<boolean>).value) {\n (challenge.toggle as VoidFunction)();\n }\n });\n }\n\n challenge[GatherProps] = function (this: GenericChallenge) {\n const {\n active,\n maxed,\n canComplete,\n display,\n visibility,\n style,\n classes,\n completed,\n canStart,\n mark,\n id,\n toggle\n } = this;\n return {\n active,\n maxed,\n canComplete,\n display,\n visibility,\n style: unref(style),\n classes,\n completed,\n canStart,\n mark,\n id,\n toggle\n };\n };\n\n return challenge as unknown as Challenge<T>;\n });\n}\n\nexport function setupAutoComplete(\n challenge: GenericChallenge,\n autoActive: Computable<boolean> = true,\n exitOnComplete = true\n): WatchStopHandle {\n const isActive = typeof autoActive === \"function\" ? computed(autoActive) : autoActive;\n return watch([challenge.canComplete, isActive], ([canComplete, isActive]) => {\n if (canComplete && isActive) {\n challenge.complete(!exitOnComplete);\n }\n });\n}\n\nexport function createActiveChallenge(\n challenges: GenericChallenge[]\n): Ref<GenericChallenge | undefined> {\n return computed(() => challenges.find(challenge => challenge.active.value));\n}\n\nexport function isAnyChallengeActive(\n challenges: GenericChallenge[] | Ref<GenericChallenge | undefined>\n): Ref<boolean> {\n if (isArray(challenges)) {\n challenges = createActiveChallenge(challenges);\n }\n return computed(() => (challenges as Ref<GenericChallenge | undefined>).value != null);\n}\n\ndeclare module \"game/settings\" {\n interface Settings {\n hideChallenges: boolean;\n }\n}\n\nglobalBus.on(\"loadSettings\", settings => {\n setDefault(settings, \"hideChallenges\", false);\n});\n\nregisterSettingField(\n jsx(() => (\n <Toggle\n title=\"Hide Maxed Challenges\"\n onUpdate:modelValue={value => (settings.hideChallenges = value)}\n modelValue={settings.hideChallenges}\n />\n ))\n);\n","import { hasWon } from \"data/projEntry\";\nimport { globalBus } from \"game/events\";\nimport player from \"game/player\";\nimport { registerInfoComponent } from \"game/settings\";\nimport {\n Computable,\n GetComputableTypeWithDefault,\n GetComputableType,\n ProcessedComputable,\n processComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { shallowReactive, unref } from \"vue\";\nimport { OptionsFunc, findFeatures, jsx, Replace, setDefault } from \"./feature\";\n\nexport const hotkeys: Record<string, GenericHotkey | undefined> = shallowReactive({});\nexport const HotkeyType = Symbol(\"Hotkey\");\n\nexport interface HotkeyOptions {\n enabled?: Computable<boolean>;\n key: string;\n description: Computable<string>;\n onPress: VoidFunction;\n}\n\nexport interface BaseHotkey {\n type: typeof HotkeyType;\n}\n\nexport type Hotkey<T extends HotkeyOptions> = Replace<\n T & BaseHotkey,\n {\n enabled: GetComputableTypeWithDefault<T[\"enabled\"], true>;\n description: GetComputableType<T[\"description\"]>;\n }\n>;\n\nexport type GenericHotkey = Replace<\n Hotkey<HotkeyOptions>,\n {\n enabled: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createHotkey<T extends HotkeyOptions>(\n optionsFunc: OptionsFunc<T, Hotkey<T>, BaseHotkey>\n): Hotkey<T> {\n return createLazyProxy(() => {\n const hotkey = optionsFunc();\n hotkey.type = HotkeyType;\n\n processComputable(hotkey as T, \"enabled\");\n setDefault(hotkey, \"enabled\", true);\n processComputable(hotkey as T, \"description\");\n\n return hotkey as unknown as Hotkey<T>;\n });\n}\n\nglobalBus.on(\"addLayer\", layer => {\n (findFeatures(layer, HotkeyType) as GenericHotkey[]).forEach(hotkey => {\n hotkeys[hotkey.key] = hotkey;\n });\n});\n\nglobalBus.on(\"removeLayer\", layer => {\n (findFeatures(layer, HotkeyType) as GenericHotkey[]).forEach(hotkey => {\n hotkeys[hotkey.key] = undefined;\n });\n});\n\ndocument.onkeydown = function (e) {\n if ((e.target as HTMLElement | null)?.tagName === \"INPUT\") {\n return;\n }\n if (hasWon.value && !player.keepGoing) {\n return;\n }\n let key = e.key;\n if (e.shiftKey) {\n key = \"shift+\" + key;\n }\n if (e.ctrlKey) {\n key = \"ctrl+\" + key;\n }\n const hotkey = hotkeys[key];\n if (hotkey && unref(hotkey.enabled)) {\n e.preventDefault();\n hotkey.onPress();\n }\n};\n\nregisterInfoComponent(\n jsx(() => {\n const keys = Object.values(hotkeys).filter(hotkey => unref(hotkey?.enabled));\n if (keys.length === 0) {\n return \"\";\n }\n return (\n <div>\n <br />\n <h4>Hotkeys</h4>\n {keys.map(hotkey => (\n <div>\n {hotkey?.key}: {hotkey?.description}\n </div>\n ))}\n </div>\n );\n })\n);\n","import LinksComponent from \"./Links.vue\";\nimport { Component, OptionsFunc, GatherProps, Replace } from \"features/feature\";\nimport { Position } from \"game/layers\";\nimport {\n Computable,\n GetComputableType,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { SVGAttributes } from \"vue\";\n\nexport const LinksType = Symbol(\"Links\");\n\nexport interface Link extends SVGAttributes {\n startNode: { id: string };\n endNode: { id: string };\n offsetStart?: Position;\n offsetEnd?: Position;\n}\n\nexport interface LinksOptions {\n links: Computable<Link[]>;\n}\n\nexport interface BaseLinks {\n type: typeof LinksType;\n [Component]: typeof LinksComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Links<T extends LinksOptions> = Replace<\n T & BaseLinks,\n {\n links: GetComputableType<T[\"links\"]>;\n }\n>;\n\nexport type GenericLinks = Replace<\n Links<LinksOptions>,\n {\n links: ProcessedComputable<Link[]>;\n }\n>;\n\nexport function createLinks<T extends LinksOptions>(\n optionsFunc: OptionsFunc<T, Links<T>, BaseLinks>\n): Links<T> {\n return createLazyProxy(() => {\n const links = optionsFunc();\n links.type = LinksType;\n links[Component] = LinksComponent;\n\n processComputable(links as T, \"links\");\n\n links[GatherProps] = function (this: GenericLinks) {\n const { links } = this;\n return {\n links\n };\n };\n\n return links as unknown as Links<T>;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n class: _normalizeClass({ feature: true, milestone: true, done: _ctx.unref(_ctx.earned), ..._ctx.unref(_ctx.classes) })\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.comp)))),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport { GenericMilestone } from \"features/milestones/milestone\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport { Component, defineComponent, shallowRef, toRefs, unref, UnwrapRef, watchEffect } from \"vue\";\nimport Node from \"../../components/Node.vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: {\n type: processedPropType<UnwrapRef<GenericMilestone[\"display\"]>>(\n String,\n Object,\n Function\n ),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n earned: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n id: {\n type: String,\n required: true\n }\n },\n components: {\n Node\n },\n setup(props) {\n const { display } = toRefs(props);\n\n const comp = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n comp.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n comp.value = coerceComponent(currDisplay);\n return;\n }\n const Requirement = coerceComponent(currDisplay.requirement, \"h3\");\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\", \"b\");\n const OptionsDisplay = coerceComponent(currDisplay.optionsDisplay || \"\", \"span\");\n comp.value = coerceComponent(\n jsx(() => (\n <span>\n <Requirement />\n {currDisplay.effectDisplay ? (\n <div>\n <EffectDisplay />\n </div>\n ) : null}\n {currDisplay.optionsDisplay ? (\n <div class=\"equal-spaced\">\n <OptionsDisplay />\n </div>\n ) : null}\n </span>\n ))\n );\n });\n\n return {\n comp,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Milestone.vue?vue&type=template&id=0b660ac3&scoped=true&ts=true\"\nimport script from \"./Milestone.vue?vue&type=script&lang=tsx\"\nexport * from \"./Milestone.vue?vue&type=script&lang=tsx\"\n\nimport \"./Milestone.vue?vue&type=style&index=0&id=0b660ac3&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-0b660ac3\"]])\n\nexport default __exports__","import Select from \"components/fields/Select.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n jsx,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport MilestoneComponent from \"features/milestones/Milestone.vue\";\nimport { globalBus } from \"game/events\";\nimport \"game/notifications\";\nimport { persistent, Persistent } from \"game/persistence\";\nimport settings, { registerSettingField } from \"game/settings\";\nimport { camelToTitle } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { coerceComponent, isCoercableComponent } from \"util/vue\";\nimport { computed, unref, watchEffect } from \"vue\";\nimport { useToast } from \"vue-toastification\";\n\nconst toast = useToast();\n\nexport const MilestoneType = Symbol(\"Milestone\");\n\nexport enum MilestoneDisplay {\n All = \"all\",\n //Last = \"last\",\n Configurable = \"configurable\",\n Incomplete = \"incomplete\",\n None = \"none\"\n}\n\nexport interface MilestoneOptions {\n visibility?: Computable<Visibility>;\n shouldEarn?: () => boolean;\n style?: Computable<StyleValue>;\n classes?: Computable<Record<string, boolean>>;\n display?: Computable<\n | CoercableComponent\n | {\n requirement: CoercableComponent;\n effectDisplay?: CoercableComponent;\n optionsDisplay?: CoercableComponent;\n }\n >;\n onComplete?: VoidFunction;\n}\n\nexport interface BaseMilestone {\n id: string;\n earned: Persistent<boolean>;\n complete: VoidFunction;\n type: typeof MilestoneType;\n [Component]: typeof MilestoneComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Milestone<T extends MilestoneOptions> = Replace<\n T & BaseMilestone,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n style: GetComputableType<T[\"style\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericMilestone = Replace<\n Milestone<MilestoneOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createMilestone<T extends MilestoneOptions>(\n optionsFunc?: OptionsFunc<T, Milestone<T>, BaseMilestone>\n): Milestone<T> {\n const earned = persistent<boolean>(false);\n return createLazyProxy(() => {\n const milestone = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n milestone.id = getUniqueID(\"milestone-\");\n milestone.type = MilestoneType;\n milestone[Component] = MilestoneComponent;\n\n milestone.earned = earned;\n milestone.complete = function () {\n earned.value = true;\n };\n\n processComputable(milestone as T, \"visibility\");\n setDefault(milestone, \"visibility\", Visibility.Visible);\n const visibility = milestone.visibility as ProcessedComputable<Visibility>;\n milestone.visibility = computed(() => {\n const display = unref((milestone as GenericMilestone).display);\n switch (settings.msDisplay) {\n default:\n case MilestoneDisplay.All:\n return unref(visibility);\n case MilestoneDisplay.Configurable:\n if (\n unref(milestone.earned) &&\n !(\n display != null &&\n typeof display == \"object\" &&\n \"optionsDisplay\" in (display as Record<string, unknown>)\n )\n ) {\n return Visibility.None;\n }\n return unref(visibility);\n case MilestoneDisplay.Incomplete:\n if (unref(milestone.earned)) {\n return Visibility.None;\n }\n return unref(visibility);\n case MilestoneDisplay.None:\n return Visibility.None;\n }\n });\n\n processComputable(milestone as T, \"style\");\n processComputable(milestone as T, \"classes\");\n processComputable(milestone as T, \"display\");\n\n milestone[GatherProps] = function (this: GenericMilestone) {\n const { visibility, display, style, classes, earned, id } = this;\n return { visibility, display, style: unref(style), classes, earned, id };\n };\n\n if (milestone.shouldEarn) {\n const genericMilestone = milestone as GenericMilestone;\n watchEffect(() => {\n if (\n !genericMilestone.earned.value &&\n unref(genericMilestone.visibility) === Visibility.Visible &&\n genericMilestone.shouldEarn?.()\n ) {\n genericMilestone.earned.value = true;\n genericMilestone.onComplete?.();\n if (genericMilestone.display) {\n const display = unref(genericMilestone.display);\n const Display = coerceComponent(\n isCoercableComponent(display) ? display : display.requirement\n );\n toast(\n <>\n <h3>Milestone earned!</h3>\n <div>\n {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}\n {/* @ts-ignore */}\n <Display />\n </div>\n </>\n );\n }\n }\n });\n }\n\n return milestone as unknown as Milestone<T>;\n });\n}\n\ndeclare module \"game/settings\" {\n interface Settings {\n msDisplay: MilestoneDisplay;\n }\n}\n\nglobalBus.on(\"loadSettings\", settings => {\n setDefault(settings, \"msDisplay\", MilestoneDisplay.All);\n});\n\nconst msDisplayOptions = Object.values(MilestoneDisplay).map(option => ({\n label: camelToTitle(option),\n value: option\n}));\n\nregisterSettingField(\n jsx(() => (\n <Select\n title=\"Show Milestones\"\n options={msDisplayOptions}\n onUpdate:modelValue={value => (settings.msDisplay = value as MilestoneDisplay)}\n modelValue={settings.msDisplay}\n />\n ))\n);\n","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock } from \"vue\"\n\nimport { CoercableComponent } from \"features/feature\";\nimport { computeComponent } from \"util/vue\";\nimport { toRefs } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n display: null\n },\n setup(__props: any) {\n\nconst _props = __props as { display: CoercableComponent }\n\n\nconst { display } = toRefs(_props);\nconst component = computeComponent(display);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(component))))\n}\n}\n\n})","import script from \"./Tab.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Tab.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n StyleValue\n} from \"features/feature\";\nimport TabComponent from \"features/tabs/Tab.vue\";\nimport { Computable, GetComputableType } from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\n\nexport const TabType = Symbol(\"Tab\");\n\nexport interface TabOptions {\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n display: Computable<CoercableComponent>;\n}\n\nexport interface BaseTab {\n id: string;\n type: typeof TabType;\n [Component]: typeof TabComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Tab<T extends TabOptions> = Replace<\n T & BaseTab,\n {\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n display: GetComputableType<T[\"display\"]>;\n }\n>;\n\nexport type GenericTab = Tab<TabOptions>;\n\nexport function createTab<T extends TabOptions>(\n optionsFunc: OptionsFunc<T, Tab<T>, BaseTab>\n): Tab<T> {\n return createLazyProxy(() => {\n const tab = optionsFunc();\n tab.id = getUniqueID(\"tab-\");\n tab.type = TabType;\n tab[Component] = TabComponent;\n\n tab[GatherProps] = function (this: GenericTab) {\n const { display } = this;\n return { display };\n };\n\n return tab as unknown as Tab<T>;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.selectTab && _ctx.selectTab(...args))),\n class: _normalizeClass([\"tabButton\", {\n active: _ctx.active,\n ..._ctx.unref(_ctx.classes)\n }]),\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.glowColorStyle,\n _ctx.unref(_ctx.style) ?? {}\n ])\n }, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.component)))\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport { getNotifyStyle } from \"game/notifications\";\nimport { computeComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport { computed, defineComponent, toRefs, unref } from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n glowColor: processedPropType<string>(String),\n active: Boolean,\n floating: Boolean\n },\n emits: [\"selectTab\"],\n setup(props, { emit }) {\n const { display, glowColor, floating } = toRefs(props);\n\n const component = computeComponent(display);\n\n const glowColorStyle = computed(() => {\n const color = unwrapRef(glowColor);\n if (!color) {\n return {};\n }\n if (unref(floating)) {\n return getNotifyStyle(color);\n }\n return { boxShadow: `0px 9px 5px -6px ${color}` };\n });\n\n function selectTab() {\n emit(\"selectTab\");\n }\n\n return {\n selectTab,\n component,\n glowColorStyle,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./TabButton.vue?vue&type=template&id=3e3f03f9&scoped=true&ts=true\"\nimport script from \"./TabButton.vue?vue&type=script&lang=ts\"\nexport * from \"./TabButton.vue?vue&type=script&lang=ts\"\n\nimport \"./TabButton.vue?vue&type=style&index=0&id=3e3f03f9&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-3e3f03f9\"]])\n\nexport default __exports__","import { renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, resolveComponent as _resolveComponent, mergeProps as _mergeProps, createBlock as _createBlock, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, createCommentVNode as _createCommentVNode, normalizeStyle as _normalizeStyle } from \"vue\"\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_TabButton = _resolveComponent(\"TabButton\")!\n const _component_Sticky = _resolveComponent(\"Sticky\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: _normalizeClass([\"tab-family-container\", { ..._ctx.unref(_ctx.classes), ..._ctx.tabClasses }]),\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? [],\n _ctx.tabStyle ?? []\n ])\n }, [\n _createVNode(_component_Sticky, { class: \"tab-buttons-container\" }, {\n default: _withCtx(() => [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"tab-buttons\", { floating: _ctx.floating }])\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.unref(_ctx.tabs), (button, id) => {\n return (_openBlock(), _createBlock(_component_TabButton, _mergeProps({\n onSelectTab: ($event: any) => (_ctx.selected.value = id),\n floating: _ctx.floating,\n key: id,\n active: _ctx.unref(button.tab) === _ctx.unref(_ctx.activeTab)\n }, _ctx.gatherButtonProps(button)), null, 16, [\"onSelectTab\", \"floating\", \"active\"]))\n }), 128))\n ], 2)\n ]),\n _: 1\n }),\n (_ctx.unref(_ctx.activeTab))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.component)), { key: 0 }))\n : _createCommentVNode(\"\", true)\n ], 6))\n : _createCommentVNode(\"\", true)\n}","\nimport Sticky from \"components/layout/Sticky.vue\";\nimport themes from \"data/themes\";\nimport { CoercableComponent, StyleValue, Visibility } from \"features/feature\";\nimport { GenericTab } from \"features/tabs/tab\";\nimport TabButton from \"features/tabs/TabButton.vue\";\nimport { GenericTabButton } from \"features/tabs/tabFamily\";\nimport settings from \"game/settings\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport {\n Component,\n computed,\n defineComponent,\n PropType,\n Ref,\n shallowRef,\n toRefs,\n unref,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n activeTab: {\n type: processedPropType<GenericTab | CoercableComponent | null>(Object),\n required: true\n },\n selected: {\n type: Object as PropType<Ref<string>>,\n required: true\n },\n tabs: {\n type: processedPropType<Record<string, GenericTabButton>>(Object),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object)\n },\n components: {\n Sticky,\n TabButton\n },\n setup(props) {\n const { activeTab } = toRefs(props);\n\n const floating = computed(() => {\n return themes[settings.theme].floatingTabs;\n });\n\n const component = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currActiveTab = unwrapRef(activeTab);\n if (currActiveTab == null) {\n component.value = \"\";\n return;\n }\n if (isCoercableComponent(currActiveTab)) {\n component.value = coerceComponent(currActiveTab);\n return;\n }\n component.value = coerceComponent(unref(currActiveTab.display));\n });\n\n const tabClasses = computed(() => {\n const currActiveTab = unwrapRef(activeTab);\n const tabClasses =\n isCoercableComponent(currActiveTab) || !currActiveTab\n ? undefined\n : unref(currActiveTab.classes);\n return tabClasses;\n });\n\n const tabStyle = computed(() => {\n const currActiveTab = unwrapRef(activeTab);\n return isCoercableComponent(currActiveTab) || !currActiveTab\n ? undefined\n : unref(currActiveTab.style);\n });\n\n function gatherButtonProps(button: GenericTabButton) {\n const { display, style, classes, glowColor, visibility } = button;\n return { display, style: unref(style), classes, glowColor, visibility };\n }\n\n return {\n floating,\n tabClasses,\n tabStyle,\n Visibility,\n component,\n gatherButtonProps,\n unref\n };\n }\n});\n","import { render } from \"./TabFamily.vue?vue&type=template&id=46a6b098&scoped=true&ts=true\"\nimport script from \"./TabFamily.vue?vue&type=script&lang=ts\"\nexport * from \"./TabFamily.vue?vue&type=script&lang=ts\"\n\nimport \"./TabFamily.vue?vue&type=style&index=0&id=46a6b098&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-46a6b098\"]])\n\nexport default __exports__","import {\n CoercableComponent,\n Component,\n OptionsFunc,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport TabButtonComponent from \"features/tabs/TabButton.vue\";\nimport TabFamilyComponent from \"features/tabs/TabFamily.vue\";\nimport { Persistent, persistent } from \"game/persistence\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { GenericTab } from \"./tab\";\n\nexport const TabButtonType = Symbol(\"TabButton\");\nexport const TabFamilyType = Symbol(\"TabFamily\");\n\nexport interface TabButtonOptions {\n visibility?: Computable<Visibility>;\n tab: Computable<GenericTab | CoercableComponent>;\n display: Computable<CoercableComponent>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n glowColor?: Computable<string>;\n}\n\nexport interface BaseTabButton {\n type: typeof TabButtonType;\n [Component]: typeof TabButtonComponent;\n}\n\nexport type TabButton<T extends TabButtonOptions> = Replace<\n T & BaseTabButton,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n tab: GetComputableType<T[\"tab\"]>;\n display: GetComputableType<T[\"display\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n glowColor: GetComputableType<T[\"glowColor\"]>;\n }\n>;\n\nexport type GenericTabButton = Replace<\n TabButton<TabButtonOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport interface TabFamilyOptions {\n visibility?: Computable<Visibility>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n}\n\nexport interface BaseTabFamily {\n id: string;\n tabs: Record<string, TabButtonOptions>;\n activeTab: Ref<GenericTab | CoercableComponent | null>;\n selected: Persistent<string>;\n type: typeof TabFamilyType;\n [Component]: typeof TabFamilyComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type TabFamily<T extends TabFamilyOptions> = Replace<\n T & BaseTabFamily,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n tabs: Record<string, GenericTabButton>;\n }\n>;\n\nexport type GenericTabFamily = Replace<\n TabFamily<TabFamilyOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n }\n>;\n\nexport function createTabFamily<T extends TabFamilyOptions>(\n tabs: Record<string, () => TabButtonOptions>,\n optionsFunc?: OptionsFunc<T, TabFamily<T>, BaseTabFamily>\n): TabFamily<T> {\n if (Object.keys(tabs).length === 0) {\n console.warn(\"Cannot create tab family with 0 tabs\");\n throw \"Cannot create tab family with 0 tabs\";\n }\n\n const selected = persistent(Object.keys(tabs)[0]);\n return createLazyProxy(() => {\n const tabFamily = optionsFunc?.() ?? ({} as ReturnType<NonNullable<typeof optionsFunc>>);\n\n tabFamily.id = getUniqueID(\"tabFamily-\");\n tabFamily.type = TabFamilyType;\n tabFamily[Component] = TabFamilyComponent;\n\n tabFamily.tabs = Object.keys(tabs).reduce<Record<string, GenericTabButton>>(\n (parsedTabs, tab) => {\n const tabButton: TabButtonOptions & Partial<BaseTabButton> = tabs[tab]();\n tabButton.type = TabButtonType;\n tabButton[Component] = TabButtonComponent;\n\n processComputable(tabButton as TabButtonOptions, \"visibility\");\n setDefault(tabButton, \"visibility\", Visibility.Visible);\n processComputable(tabButton as TabButtonOptions, \"tab\");\n processComputable(tabButton as TabButtonOptions, \"display\");\n processComputable(tabButton as TabButtonOptions, \"classes\");\n processComputable(tabButton as TabButtonOptions, \"style\");\n processComputable(tabButton as TabButtonOptions, \"glowColor\");\n parsedTabs[tab] = tabButton as GenericTabButton;\n return parsedTabs;\n },\n {}\n );\n tabFamily.selected = selected;\n tabFamily.activeTab = computed(() => {\n const tabs = unref(processedTabFamily.tabs);\n if (\n selected.value in tabs &&\n unref(tabs[selected.value].visibility) === Visibility.Visible\n ) {\n return unref(tabs[selected.value].tab);\n }\n const firstTab = Object.values(tabs).find(\n tab => unref(tab.visibility) === Visibility.Visible\n );\n if (firstTab) {\n return unref(firstTab.tab);\n }\n return null;\n });\n\n processComputable(tabFamily as T, \"visibility\");\n setDefault(tabFamily, \"visibility\", Visibility.Visible);\n processComputable(tabFamily as T, \"classes\");\n processComputable(tabFamily as T, \"style\");\n\n tabFamily[GatherProps] = function (this: GenericTabFamily) {\n const { visibility, activeTab, selected, tabs, style, classes } = this;\n return { visibility, activeTab, selected, tabs, style: unref(style), classes };\n };\n\n // This is necessary because board.types is different from T and TabFamily\n const processedTabFamily = tabFamily as unknown as TabFamily<T>;\n return processedTabFamily;\n });\n}\n","import { resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-6f164fe2\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"disabled\"]\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_MarkNode = _resolveComponent(\"MarkNode\")!\n const _component_Node = _resolveComponent(\"Node\")!\n\n return (_ctx.unref(_ctx.visibility) !== _ctx.Visibility.None)\n ? (_openBlock(), _createElementBlock(\"button\", {\n key: 0,\n style: _normalizeStyle([\n {\n visibility: _ctx.unref(_ctx.visibility) === _ctx.Visibility.Hidden ? 'hidden' : undefined\n },\n _ctx.unref(_ctx.style) ?? {}\n ]),\n onClick: _cache[0] || (_cache[0] = \n//@ts-ignore\n(...args) => (_ctx.purchase && _ctx.purchase(...args))),\n class: _normalizeClass({\n feature: true,\n upgrade: true,\n can: _ctx.unref(_ctx.canPurchase),\n locked: !_ctx.unref(_ctx.canPurchase),\n bought: _ctx.unref(_ctx.bought),\n ..._ctx.unref(_ctx.classes)\n }),\n disabled: !_ctx.unref(_ctx.canPurchase)\n }, [\n (_ctx.unref(_ctx.component))\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.unref(_ctx.component)), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_component_MarkNode, {\n mark: _ctx.unref(_ctx.mark)\n }, null, 8, [\"mark\"]),\n _createVNode(_component_Node, { id: _ctx.id }, null, 8, [\"id\"])\n ], 14, _hoisted_1))\n : _createCommentVNode(\"\", true)\n}","\nimport \"components/common/features.css\";\nimport Node from \"components/Node.vue\";\nimport MarkNode from \"components/MarkNode.vue\";\nimport { jsx, StyleValue, Visibility } from \"features/feature\";\nimport { displayResource, Resource } from \"features/resources/resource\";\nimport { GenericUpgrade } from \"features/upgrades/upgrade\";\nimport { DecimalSource } from \"util/bignum\";\nimport { coerceComponent, isCoercableComponent, processedPropType, unwrapRef } from \"util/vue\";\nimport {\n Component,\n defineComponent,\n PropType,\n shallowRef,\n toRefs,\n unref,\n UnwrapRef,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n display: {\n type: processedPropType<UnwrapRef<GenericUpgrade[\"display\"]>>(String, Object, Function),\n required: true\n },\n visibility: {\n type: processedPropType<Visibility>(Number),\n required: true\n },\n style: processedPropType<StyleValue>(String, Object, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n resource: Object as PropType<Resource>,\n cost: processedPropType<DecimalSource>(String, Object, Number),\n canPurchase: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n bought: {\n type: processedPropType<boolean>(Boolean),\n required: true\n },\n mark: processedPropType<boolean | string>(Boolean, String),\n id: {\n type: String,\n required: true\n },\n purchase: {\n type: Function as PropType<VoidFunction>,\n required: true\n }\n },\n components: {\n Node,\n MarkNode\n },\n setup(props) {\n const { display, cost } = toRefs(props);\n\n const component = shallowRef<Component | string>(\"\");\n\n watchEffect(() => {\n const currDisplay = unwrapRef(display);\n if (currDisplay == null) {\n component.value = \"\";\n return;\n }\n if (isCoercableComponent(currDisplay)) {\n component.value = coerceComponent(currDisplay);\n return;\n }\n const currCost = unwrapRef(cost);\n const Title = coerceComponent(currDisplay.title || \"\", \"h3\");\n const Description = coerceComponent(currDisplay.description, \"div\");\n const EffectDisplay = coerceComponent(currDisplay.effectDisplay || \"\");\n component.value = coerceComponent(\n jsx(() => (\n <span>\n {currDisplay.title ? (\n <div>\n <Title />\n </div>\n ) : null}\n <Description />\n {currDisplay.effectDisplay ? (\n <div>\n Currently: <EffectDisplay />\n </div>\n ) : null}\n {props.resource != null ? (\n <>\n <br />\n Cost: {props.resource &&\n displayResource(props.resource, currCost)}{\" \"}\n {props.resource?.displayName}\n </>\n ) : null}\n </span>\n ))\n );\n });\n\n return {\n component,\n unref,\n Visibility\n };\n }\n});\n","import { render } from \"./Upgrade.vue?vue&type=template&id=6f164fe2&scoped=true&ts=true\"\nimport script from \"./Upgrade.vue?vue&type=script&lang=tsx\"\nexport * from \"./Upgrade.vue?vue&type=script&lang=tsx\"\n\nimport \"./Upgrade.vue?vue&type=style&index=0&id=6f164fe2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-6f164fe2\"]])\n\nexport default __exports__","import UpgradeComponent from \"features/upgrades/Upgrade.vue\";\nimport {\n CoercableComponent,\n Component,\n OptionsFunc,\n findFeatures,\n GatherProps,\n getUniqueID,\n Replace,\n setDefault,\n StyleValue,\n Visibility\n} from \"features/feature\";\nimport { Resource } from \"features/resources/resource\";\nimport { GenericLayer } from \"game/layers\";\nimport Decimal, { DecimalSource } from \"util/bignum\";\nimport { isFunction } from \"util/common\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { computed, Ref, unref } from \"vue\";\nimport { persistent, Persistent } from \"game/persistence\";\n\nexport const UpgradeType = Symbol(\"Upgrade\");\n\nexport interface UpgradeOptions {\n visibility?: Computable<Visibility>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n display?: Computable<\n | CoercableComponent\n | {\n title?: CoercableComponent;\n description: CoercableComponent;\n effectDisplay?: CoercableComponent;\n }\n >;\n mark?: Computable<boolean | string>;\n cost?: Computable<DecimalSource>;\n resource?: Resource;\n canAfford?: Computable<boolean>;\n onPurchase?: VoidFunction;\n}\n\nexport interface BaseUpgrade {\n id: string;\n bought: Persistent<boolean>;\n canPurchase: Ref<boolean>;\n purchase: VoidFunction;\n type: typeof UpgradeType;\n [Component]: typeof UpgradeComponent;\n [GatherProps]: () => Record<string, unknown>;\n}\n\nexport type Upgrade<T extends UpgradeOptions> = Replace<\n T & BaseUpgrade,\n {\n visibility: GetComputableTypeWithDefault<T[\"visibility\"], Visibility.Visible>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n display: GetComputableType<T[\"display\"]>;\n mark: GetComputableType<T[\"mark\"]>;\n cost: GetComputableType<T[\"cost\"]>;\n canAfford: GetComputableTypeWithDefault<T[\"canAfford\"], Ref<boolean>>;\n }\n>;\n\nexport type GenericUpgrade = Replace<\n Upgrade<UpgradeOptions>,\n {\n visibility: ProcessedComputable<Visibility>;\n canPurchase: ProcessedComputable<boolean>;\n }\n>;\n\nexport function createUpgrade<T extends UpgradeOptions>(\n optionsFunc: OptionsFunc<T, Upgrade<T>, BaseUpgrade>\n): Upgrade<T> {\n const bought = persistent<boolean>(false);\n return createLazyProxy(() => {\n const upgrade = optionsFunc();\n upgrade.id = getUniqueID(\"upgrade-\");\n upgrade.type = UpgradeType;\n upgrade[Component] = UpgradeComponent;\n\n if (upgrade.canAfford == null && (upgrade.resource == null || upgrade.cost == null)) {\n console.warn(\n \"Error: can't create upgrade without a canAfford property or a resource and cost property\",\n upgrade\n );\n }\n\n upgrade.bought = bought;\n if (upgrade.canAfford == null) {\n upgrade.canAfford = computed(() => {\n const genericUpgrade = upgrade as GenericUpgrade;\n return (\n genericUpgrade.resource != null &&\n genericUpgrade.cost != null &&\n Decimal.gte(genericUpgrade.resource.value, unref(genericUpgrade.cost))\n );\n });\n } else {\n processComputable(upgrade as T, \"canAfford\");\n }\n upgrade.canPurchase = computed(\n () =>\n unref((upgrade as GenericUpgrade).visibility) === Visibility.Visible &&\n unref((upgrade as GenericUpgrade).canAfford) &&\n !unref(upgrade.bought)\n );\n upgrade.purchase = function () {\n const genericUpgrade = upgrade as GenericUpgrade;\n if (!unref(genericUpgrade.canPurchase)) {\n return;\n }\n if (genericUpgrade.resource != null && genericUpgrade.cost != null) {\n genericUpgrade.resource.value = Decimal.sub(\n genericUpgrade.resource.value,\n unref(genericUpgrade.cost)\n );\n }\n bought.value = true;\n genericUpgrade.onPurchase?.();\n };\n\n processComputable(upgrade as T, \"visibility\");\n setDefault(upgrade, \"visibility\", Visibility.Visible);\n processComputable(upgrade as T, \"classes\");\n processComputable(upgrade as T, \"style\");\n processComputable(upgrade as T, \"display\");\n processComputable(upgrade as T, \"mark\");\n processComputable(upgrade as T, \"cost\");\n processComputable(upgrade as T, \"resource\");\n\n upgrade[GatherProps] = function (this: GenericUpgrade) {\n const {\n display,\n visibility,\n style,\n classes,\n resource,\n cost,\n canPurchase,\n bought,\n mark,\n id,\n purchase\n } = this;\n return {\n display,\n visibility,\n style: unref(style),\n classes,\n resource,\n cost,\n canPurchase,\n bought,\n mark,\n id,\n purchase\n };\n };\n\n return upgrade as unknown as Upgrade<T>;\n });\n}\n\nexport function setupAutoPurchase(\n layer: GenericLayer,\n autoActive: Computable<boolean>,\n upgrades: GenericUpgrade[] = []\n): void {\n upgrades = upgrades || findFeatures(layer, UpgradeType);\n const isAutoActive = isFunction(autoActive) ? computed(autoActive) : autoActive;\n layer.on(\"update\", () => {\n if (unref(isAutoActive)) {\n upgrades.forEach(upgrade => upgrade.purchase());\n }\n });\n}\n","import Slider from \"components/fields/Slider.vue\";\nimport Text from \"components/fields/Text.vue\";\nimport Toggle from \"components/fields/Toggle.vue\";\nimport Column from \"components/layout/Column.vue\";\nimport Row from \"components/layout/Row.vue\";\nimport Spacer from \"components/layout/Spacer.vue\";\nimport Sticky from \"components/layout/Sticky.vue\";\nimport VerticalRule from \"components/layout/VerticalRule.vue\";\nimport Modal from \"components/Modal.vue\";\nimport { createLayerTreeNode, createResetButton } from \"data/common\";\nimport { main } from \"data/projEntry\";\nimport themes from \"data/themes\";\nimport { createBar } from \"features/bars/bar\";\nimport { createBuyable } from \"features/buyable\";\nimport { createChallenge } from \"features/challenges/challenge\";\nimport { createClickable } from \"features/clickables/clickable\";\nimport {\n addSoftcap,\n createCumulativeConversion,\n createPolynomialScaling\n} from \"features/conversion\";\nimport { jsx, showIf, Visibility } from \"features/feature\";\nimport { createHotkey } from \"features/hotkey\";\nimport { createInfobox } from \"features/infoboxes/infobox\";\nimport { createLinks } from \"features/links/links\";\nimport { createMilestone } from \"features/milestones/milestone\";\nimport { createReset } from \"features/reset\";\nimport MainDisplay from \"features/resources/MainDisplay.vue\";\nimport { createResource, displayResource, trackBest } from \"features/resources/resource\";\nimport Resource from \"features/resources/Resource.vue\";\nimport { createTab } from \"features/tabs/tab\";\nimport { createTabFamily } from \"features/tabs/tabFamily\";\nimport { addTooltip } from \"features/tooltips/tooltip\";\nimport {\n createResourceTooltip,\n createTree,\n createTreeNode,\n GenericTreeNode,\n TreeBranch\n} from \"features/trees/tree\";\nimport { createUpgrade } from \"features/upgrades/upgrade\";\nimport { createLayer } from \"game/layers\";\nimport {\n createAdditiveModifier,\n createExponentialModifier,\n createModifierSection,\n createSequentialModifier\n} from \"game/modifiers\";\nimport { persistent } from \"game/persistence\";\nimport settings from \"game/settings\";\nimport { DecimalSource } from \"lib/break_eternity\";\nimport Decimal, { format, formatWhole } from \"util/bignum\";\nimport { Direction } from \"util/common\";\nimport { render, renderCol, renderRow } from \"util/vue\";\nimport { computed, ComputedRef, ref } from \"vue\";\nimport f from \"./f\";\n\nconst id = \"c\";\nconst layer = createLayer(id, () => {\n const color = \"#4BDC13\";\n const name = \"Candies\";\n const points = createResource<DecimalSource>(0, \"lollipops\");\n const best = trackBest(points);\n const beep = persistent<boolean>(false);\n const thingy = persistent<string>(\"pointy\");\n const otherThingy = persistent<number>(10);\n const spentOnBuyables = persistent(new Decimal(10));\n\n const waffleBoost = computed(() => Decimal.pow(points.value, 0.2));\n const icecreamCap = computed(() => Decimal.times(points.value, 10));\n\n const coolInfo = createInfobox(() => ({\n title: \"Lore\",\n titleStyle: { color: \"#FE0000\" },\n display: \"DEEP LORE!\",\n bodyStyle: { backgroundColor: \"#0000EE\" },\n color: \"rgb(75, 220, 19)\"\n }));\n\n const lollipopMilestone3 = createMilestone(() => ({\n shouldEarn() {\n return Decimal.gte(best.value, 3);\n },\n display: {\n requirement: \"3 Lollipops\",\n effectDisplay: \"Unlock the next milestone\"\n }\n }));\n const lollipopMilestone4 = createMilestone(() => ({\n visibility() {\n return showIf(lollipopMilestone3.earned.value);\n },\n shouldEarn() {\n return Decimal.gte(best.value, 4);\n },\n display: {\n requirement: \"4 Lollipops\",\n effectDisplay: \"You can toggle beep and boop (which do nothing)\",\n optionsDisplay: jsx(() => (\n <>\n <Toggle\n title=\"beep\"\n onUpdate:modelValue={value => (beep.value = value)}\n modelValue={beep.value}\n />\n <Toggle\n title=\"boop\"\n onUpdate:modelValue={value => (f.boop.value = value)}\n modelValue={f.boop.value}\n />\n </>\n ))\n },\n style() {\n if (this.earned) {\n return { backgroundColor: \"#1111DD\" };\n }\n return {};\n }\n }));\n const lollipopMilestones = [lollipopMilestone3, lollipopMilestone4];\n\n const funChallenge = createChallenge(() => ({\n title: \"Fun\",\n completionLimit: 3,\n display() {\n return {\n description: `Makes the game 0% harder<br>${formatWhole(this.completions.value)}/${\n this.completionLimit\n } completions`,\n goal: \"Have 20 points I guess\",\n reward: \"Says hi\",\n effectDisplay: format(funEffect.value) + \"x\"\n };\n },\n visibility() {\n return showIf(Decimal.gt(best.value, 0));\n },\n goal: 20,\n resource: main.points,\n onComplete() {\n console.log(\"hiii\");\n },\n onEnter() {\n main.points.value = 0;\n main.best.value = main.points.value;\n main.total.value = main.points.value;\n console.log(\"So challenging\");\n },\n onExit() {\n console.log(\"Sweet freedom!\");\n },\n style: {\n height: \"200px\"\n }\n }));\n const funEffect = computed(() => Decimal.add(points.value, 1).tetrate(0.02));\n\n const generatorUpgrade = createUpgrade(() => ({\n display: {\n title: \"Generator of Genericness\",\n description: \"Gain 1 point every second\"\n },\n cost: 1,\n resource: points\n }));\n const lollipopMultiplierUpgrade = createUpgrade(() => ({\n display: () => ({\n description: \"Point generation is faster based on your unspent Lollipops\",\n effectDisplay: `${format(lollipopMultiplierEffect.value)}x`\n }),\n cost: 1,\n resource: points,\n visibility: () => showIf(generatorUpgrade.bought.value)\n }));\n const lollipopMultiplierEffect = computed(() => {\n let ret = Decimal.add(points.value, 1).pow(0.5);\n if (ret.gte(\"1e20000000\")) ret = ret.sqrt().times(\"1e10000000\");\n return ret;\n });\n const unlockIlluminatiUpgrade = createUpgrade(() => ({\n visibility() {\n return showIf(lollipopMultiplierUpgrade.bought.value);\n },\n canAfford() {\n return Decimal.lt(main.points.value, 7);\n },\n onPurchase() {\n main.points.value = Decimal.add(main.points.value, 7);\n },\n display:\n \"Only buyable with less than 7 points, and gives you 7 more. Unlocks a secret subtab.\",\n style() {\n if (this.bought) {\n return { backgroundColor: \"#1111dd\" };\n }\n if (!this.canAfford) {\n return { backgroundColor: \"#dd1111\" };\n }\n return {};\n }\n }));\n const quasiUpgrade = createUpgrade(() => ({\n resource: createResource(exhancers.amount, \"Exhancers\", 0),\n cost: 3,\n display: {\n title: \"This upgrade doesn't exist\",\n description: \"Or does it?\"\n }\n }));\n const upgrades = [generatorUpgrade, lollipopMultiplierUpgrade, unlockIlluminatiUpgrade];\n\n const exhancers = createBuyable(() => ({\n resource: points,\n cost() {\n let x = new Decimal(this.amount.value);\n if (x.gte(25)) {\n x = x.pow(2).div(25);\n }\n const cost = Decimal.pow(2, x.pow(1.5));\n return cost.floor();\n },\n display() {\n return {\n title: \"Exhancers\",\n description: `Adds ${format(\n thingEffect.value\n )} things and multiplies stuff by ${format(stuffEffect.value)}.`\n };\n },\n onPurchase(cost) {\n spentOnBuyables.value = Decimal.add(spentOnBuyables.value, cost ?? 0);\n },\n style: { height: \"222px\" },\n purchaseLimit: 4\n }));\n // The following need redundant ComputedRef<Decimal> type annotations because otherwise the ts\n // interpreter thinks exhancers are cyclically referenced\n const thingEffect: ComputedRef<Decimal> = computed(() => {\n if (Decimal.gte(exhancers.amount.value, 0)) {\n return Decimal.pow(25, Decimal.pow(exhancers.amount.value, 1.1));\n }\n return Decimal.pow(1 / 25, Decimal.times(exhancers.amount.value, -1).pow(1.1));\n });\n const stuffEffect: ComputedRef<Decimal> = computed(() => {\n if (Decimal.gte(exhancers.amount.value, 0)) {\n return Decimal.pow(25, Decimal.pow(exhancers.amount.value, 1.1));\n }\n return Decimal.pow(1 / 25, Decimal.times(exhancers.amount.value, -1).pow(1.1));\n });\n const confirmRespec = persistent<boolean>(false);\n const confirming = ref(false);\n const respecBuyables = createClickable(() => ({\n small: true,\n display: \"Respec Thingies\",\n onClick() {\n if (confirmRespec.value && !confirming.value) {\n confirming.value = true;\n return;\n }\n\n points.value = Decimal.add(points.value, spentOnBuyables.value);\n exhancers.amount.value = 0;\n main.tree.reset(treeNode);\n }\n }));\n const sellExhancer = createClickable(() => ({\n small: true,\n display: \"Sell One\",\n onClick() {\n if (Decimal.lte(exhancers.amount.value, 0)) {\n return;\n }\n exhancers.amount.value = Decimal.sub(exhancers.amount.value, 1);\n points.value = Decimal.add(points.value, exhancers.cost.value);\n spentOnBuyables.value = Decimal.sub(spentOnBuyables.value, exhancers.cost.value);\n }\n }));\n const buyablesDisplay = jsx(() => (\n <Column>\n <Row>\n <Toggle\n title=\"Confirm\"\n onUpdate:modelValue={value => (confirmRespec.value = value)}\n modelValue={confirmRespec.value}\n />\n {renderRow(respecBuyables)}\n </Row>\n {renderRow(exhancers)}\n {renderRow(sellExhancer)}\n <Modal\n modelValue={confirming.value}\n onUpdate:modelValue={value => (confirming.value = value)}\n v-slots={{\n header: () => <h2>Confirm Respec</h2>,\n body: () => <>Are you sure? Respeccing these doesn't accomplish much</>,\n footer: () => (\n <div class=\"modal-default-footer\">\n <div class=\"modal-default-flex-grow\"></div>\n <button\n class=\"button modal-default-button\"\n onClick={() => (confirming.value = false)}\n >\n Cancel\n </button>\n <button\n class=\"button modal-default-button danger\"\n onClick={() => {\n respecBuyables.onClick();\n confirming.value = false;\n }}\n >\n Respec\n </button>\n </div>\n )\n }}\n />\n </Column>\n ));\n\n const longBoi = createBar(() => ({\n fillStyle: { backgroundColor: \"#FFFFFF\" },\n baseStyle: { backgroundColor: \"#696969\" },\n textStyle: { color: \"#04e050\" },\n direction: Direction.Right,\n width: 300,\n height: 30,\n progress() {\n return Decimal.add(main.points.value, 1).log(10).div(10).toNumber();\n },\n display() {\n return format(main.points.value) + \" / 1e10 points\";\n }\n }));\n const tallBoi = createBar(() => ({\n fillStyle: { backgroundColor: \"#4BEC13\" },\n baseStyle: { backgroundColor: \"#000000\" },\n textStyle: { textShadow: \"0px 0px 2px #000000\" },\n borderStyle: { borderWidth: \"7px\" },\n direction: Direction.Up,\n width: 50,\n height: 200,\n progress() {\n return Decimal.div(main.points.value, 100);\n },\n display() {\n return formatWhole(Decimal.div(main.points.value, 1).min(100)) + \"%\";\n }\n }));\n const flatBoi = createBar(() => ({\n fillStyle: { backgroundColor: \"#FE0102\" },\n baseStyle: { backgroundColor: \"#222222\" },\n textStyle: { textShadow: \"0px 0px 2px #000000\" },\n direction: Direction.Up,\n width: 100,\n height: 30,\n progress() {\n return Decimal.div(points.value, 50);\n }\n }));\n\n const conversion = createCumulativeConversion(() => ({\n scaling: addSoftcap(createPolynomialScaling(10, 0.5), 1e100, 0.5),\n baseResource: main.points,\n gainResource: points,\n roundUpCost: true,\n gainModifier: createSequentialModifier(\n createExponentialModifier(2, \"Because I felt like it\"),\n createAdditiveModifier(1, \"Nice modifier\")\n )\n }));\n\n const reset = createReset(() => ({\n thingsToReset: (): Record<string, unknown>[] => [layer]\n }));\n\n const hotkeys = [\n createHotkey(() => ({\n key: \"c\",\n description: \"reset for lollipops or whatever\",\n onPress() {\n if (resetButton.canClick.value) {\n resetButton.onClick();\n }\n }\n })),\n createHotkey(() => ({\n key: \"ctrl+c\",\n description: \"respec things\",\n onPress() {\n respecBuyables.onClick();\n }\n }))\n ];\n\n const treeNode = createLayerTreeNode(() => ({\n layerID: id,\n color,\n reset,\n mark: \"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png\",\n tooltip() {\n let tooltip = displayResource(points);\n if (Decimal.gt(exhancers.amount.value, 0)) {\n tooltip += `<br><i><br><br><br>${formatWhole(\n exhancers.amount.value\n )} Exhancers</i>`;\n }\n return tooltip;\n },\n style: {\n color: \"#3325CC\",\n textDecoration: \"underline\"\n }\n }));\n addTooltip(treeNode, {\n display: createResourceTooltip(points),\n pinnable: true\n });\n\n const resetButton = createResetButton(() => ({\n conversion,\n tree: main.tree,\n treeNode,\n style: {\n color: \"#AA66AA\"\n },\n resetDescription: \"Melt your points into \"\n }));\n addTooltip(resetButton, {\n display: jsx(() =>\n createModifierSection(\n \"Modifiers\",\n \"\",\n conversion.gainModifier,\n conversion.scaling.currentGain(conversion)\n )\n ),\n pinnable: true,\n direction: Direction.Down,\n style: \"width: 400px; text-align: left\"\n });\n\n const g = createTreeNode(() => ({\n display: \"TH\",\n color: \"#6d3678\",\n canClick() {\n return Decimal.gte(main.points.value, 10);\n },\n tooltip: \"Thanos your points\",\n onClick() {\n main.points.value = Decimal.div(main.points.value, 2);\n console.log(\"Thanos'd\");\n },\n glowColor() {\n if (Decimal.eq(exhancers.amount.value, 1)) {\n return \"orange\";\n }\n return \"\";\n }\n }));\n const h = createTreeNode(() => ({\n display: \"h\",\n color() {\n return themes[settings.theme].variables[\"--locked\"];\n },\n tooltip: {\n display: computed(() => `Restore your points to ${format(otherThingy.value)}`),\n right: true\n },\n canClick() {\n return Decimal.lt(main.points.value, otherThingy.value);\n },\n onClick() {\n main.points.value = otherThingy.value;\n }\n }));\n const spook = createTreeNode(() => ({\n visibility: Visibility.Hidden\n }));\n const tree = createTree(() => ({\n nodes(): GenericTreeNode[][] {\n return [\n [f.treeNode, treeNode],\n [g, spook, h]\n ];\n },\n branches(): TreeBranch[] {\n return [\n {\n startNode: f.treeNode,\n endNode: treeNode,\n \"stroke-width\": \"25px\",\n stroke: \"green\",\n style: {\n filter: \"blur(5px)\"\n }\n },\n { startNode: treeNode, endNode: g },\n { startNode: g, endNode: h }\n ];\n }\n }));\n\n const links = createLinks(() => ({\n links: [\n {\n startNode: h,\n endNode: flatBoi,\n \"stroke-width\": \"5px\",\n stroke: \"red\",\n offsetEnd: { x: -50 + 100 * flatBoi.progress.value.toNumber(), y: 0 }\n }\n ]\n }));\n\n const illuminatiTabs = createTabFamily(\n {\n first: () => ({\n tab: jsx(() => (\n <>\n {renderRow(...upgrades)}\n {renderRow(quasiUpgrade)}\n <div>confirmed</div>\n </>\n )),\n display: \"first\"\n }),\n second: () => ({\n tab: f.display,\n display: \"second\"\n })\n },\n () => ({\n style: {\n width: \"660px\",\n backgroundColor: \"brown\",\n \"--background\": \"brown\",\n border: \"solid white\",\n marginLeft: \"auto\",\n marginRight: \"auto\"\n }\n })\n );\n\n const tabs = createTabFamily({\n mainTab: () => ({\n tab: createTab(() => ({\n display: jsx(() => (\n <>\n <MainDisplay\n resource={points}\n color={color}\n effectDisplay={`which are boosting waffles by ${format(\n waffleBoost.value\n )} and increasing the Ice Cream cap by ${format(icecreamCap.value)}`}\n />\n <Sticky>{render(resetButton)}</Sticky>\n <Resource resource={points} color={color} />\n <Spacer height=\"5px\" />\n <button onClick={() => console.log(\"yeet\")}>'HI'</button>\n <div>Name your points!</div>\n <Text\n modelValue={thingy.value}\n onUpdate:modelValue={value => (thingy.value = value)}\n />\n <Sticky style=\"color: red; font-size: 32px; font-family: Comic Sans MS;\">\n I have {displayResource(main.points)} {thingy.value} points!\n </Sticky>\n <hr />\n {renderCol(...lollipopMilestones)}\n <Spacer />\n {renderRow(...upgrades)}\n {renderRow(quasiUpgrade)}\n {renderRow(funChallenge)}\n </>\n ))\n })),\n display: \"main tab\",\n glowColor() {\n if (\n generatorUpgrade.canPurchase.value ||\n lollipopMultiplierUpgrade.canPurchase.value ||\n unlockIlluminatiUpgrade.canPurchase.value ||\n funChallenge.canComplete.value\n ) {\n return \"blue\";\n }\n return \"\";\n },\n style: { color: \"orange\" }\n }),\n thingies: () => ({\n tab: createTab(() => ({\n style() {\n return { backgroundColor: \"#222222\", \"--background\": \"#222222\" };\n },\n display: jsx(() => (\n <>\n {render(buyablesDisplay)}\n <Spacer />\n <Row style=\"width: 600px; height: 350px; background-color: green; border-style: solid;\">\n <Toggle\n onUpdate:modelValue={value => (beep.value = value)}\n modelValue={beep.value}\n />\n <Spacer width=\"30px\" height=\"10px\" />\n <div>\n <span>Beep</span>\n </div>\n <Spacer />\n <VerticalRule height=\"200px\" />\n </Row>\n <Spacer />\n <img src=\"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png\" />\n </>\n ))\n })),\n glowColor: \"white\",\n display: \"thingies\",\n style: { borderColor: \"orange\" }\n }),\n jail: () => ({\n tab: createTab(() => ({\n display: jsx(() => (\n <>\n {render(coolInfo)}\n {render(longBoi)}\n <Spacer />\n <Row>\n <Column style=\"background-color: #555555; padding: 15px\">\n <div style=\"color: teal\">Sugar level:</div>\n <Spacer />\n {render(tallBoi)}\n </Column>\n <Spacer />\n <Column>\n <div>idk</div>\n <Spacer width=\"0\" height=\"50px\" />\n {render(flatBoi)}\n </Column>\n </Row>\n <Spacer />\n <div>It's jail because \"bars\"! So funny! Ha ha!</div>\n {render(tree)}\n </>\n ))\n })),\n display: \"jail\"\n }),\n illuminati: () => ({\n tab: createTab(() => ({\n display: jsx(() => (\n // This should really just be <> and </>, however for some reason the\n // typescript interpreter can't figure out this layer and f.tsx otherwise\n <div>\n <h1> C O N F I R M E D </h1>\n <Spacer />\n {render(illuminatiTabs)}\n <div>Adjust how many points H gives you!</div>\n <Slider\n onUpdate:modelValue={value => (otherThingy.value = value)}\n modelValue={otherThingy.value}\n min={1}\n max={30}\n />\n </div>\n )),\n style: {\n backgroundColor: \"#3325CC\"\n }\n })),\n visibility() {\n return showIf(unlockIlluminatiUpgrade.bought.value);\n },\n display: \"illuminati\"\n })\n });\n\n return {\n id,\n color,\n name,\n points,\n best,\n beep,\n thingy,\n otherThingy,\n spentOnBuyables,\n waffleBoost,\n icecreamCap,\n coolInfo,\n lollipopMilestones,\n funChallenge,\n funEffect,\n generatorUpgrade,\n lollipopMultiplierUpgrade,\n lollipopMultiplierEffect,\n unlockIlluminatiUpgrade,\n quasiUpgrade,\n exhancers,\n respecBuyables,\n sellExhancer,\n bars: { tallBoi, longBoi, flatBoi },\n tree,\n g,\n h,\n spook,\n conversion,\n reset,\n hotkeys,\n treeNode,\n resetButton,\n confirmRespec,\n minWidth: 800,\n tabs,\n display: jsx(() => (\n <>\n {render(tabs)}\n {render(links)}\n </>\n ))\n };\n});\n\nexport default layer;\n","import Spacer from \"components/layout/Spacer.vue\";\nimport { createLayerTreeNode, createResetButton } from \"data/common\";\nimport { main } from \"data/projEntry\";\nimport { createClickable } from \"features/clickables/clickable\";\nimport { createPolynomialScaling, createIndependentConversion } from \"features/conversion\";\nimport { jsx } from \"features/feature\";\nimport { createInfobox } from \"features/infoboxes/infobox\";\nimport { createParticles } from \"features/particles/particles\";\nimport { createReset } from \"features/reset\";\nimport MainDisplay from \"features/resources/MainDisplay.vue\";\nimport { createResource, displayResource } from \"features/resources/resource\";\nimport { addTooltip } from \"features/tooltips/tooltip\";\nimport { createResourceTooltip } from \"features/trees/tree\";\nimport { createLayer } from \"game/layers\";\nimport { createMultiplicativeModifier } from \"game/modifiers\";\nimport { persistent } from \"game/persistence\";\nimport Decimal, { DecimalSource, formatWhole } from \"util/bignum\";\nimport { render, renderRow } from \"util/vue\";\nimport { ref } from \"vue\";\nimport c from \"./c\";\nimport confetti from \"./confetti.json\";\n\nconst id = \"f\";\nconst layer = createLayer(id, () => {\n const color = \"#FE0102\";\n const name = \"Farms\";\n const points = createResource<DecimalSource>(0, \"farm points\");\n const boop = persistent<boolean>(false);\n\n const coolInfo = createInfobox(() => ({\n title: \"Lore\",\n titleStyle: { color: \"#FE0000\" },\n display: \"DEEP LORE!\",\n bodyStyle: { backgroundColor: \"#0000EE\" }\n }));\n\n const clickableState = persistent<string>(\"Start\");\n const clickable = createClickable(() => ({\n display() {\n return {\n title: \"Clicky clicky!\",\n description: \"Current state:<br>\" + clickableState.value\n };\n },\n initialState: \"Start\",\n canClick() {\n return clickableState.value !== \"Borkened...\";\n },\n onClick(e) {\n switch (clickableState.value) {\n case \"Start\":\n clickableState.value = \"A new state!\";\n break;\n case \"A new state!\":\n clickableState.value = \"Keep going!\";\n break;\n case \"Keep going!\":\n clickableState.value = \"Maybe that's a bit too far...\";\n break;\n case \"Maybe that's a bit too far...\":\n const pos = e == undefined ? undefined : \"touches\" in e ? e.touches[0] : e;\n const confettiParticles = Object.assign({}, confetti, {\n pos: {\n x: (pos?.clientX ?? 0) - (particles.boundingRect?.value?.left ?? 0),\n y: (pos?.clientY ?? 0) - (particles.boundingRect?.value?.top ?? 0)\n }\n });\n particles.addEmitter(confettiParticles).then(e => e.playOnceAndDestroy());\n clickableState.value = \"Borkened...\";\n break;\n default:\n clickableState.value = \"Start\";\n break;\n }\n },\n onHold() {\n console.log(\"Clickkkkk...\");\n },\n style() {\n switch (clickableState.value) {\n case \"Start\":\n return { \"background-color\": \"green\" };\n case \"A new state!\":\n return { \"background-color\": \"yellow\" };\n case \"Keep going!\":\n return { \"background-color\": \"orange\" };\n case \"Maybe that's a bit too far...\":\n return { \"background-color\": \"red\" };\n default:\n return {};\n }\n }\n }));\n\n const resetClickable = createClickable(() => ({\n onClick() {\n if (clickableState.value == \"Borkened...\") {\n clickableState.value = \"Start\";\n }\n },\n display() {\n return clickableState.value == \"Borkened...\" ? \"Fix the clickable!\" : \"Does nothing\";\n },\n small: true\n }));\n\n const reset = createReset(() => ({\n thingsToReset: (): Record<string, unknown>[] => [layer]\n }));\n\n const conversion = createIndependentConversion(() => ({\n scaling: createPolynomialScaling(10, 0.5),\n baseResource: main.points,\n gainResource: points,\n modifyGainAmount: createMultiplicativeModifier(c.otherThingy)\n }));\n\n const treeNode = createLayerTreeNode(() => ({\n layerID: id,\n color,\n reset,\n tooltip() {\n if (treeNode.canClick.value) {\n return `${displayResource(points)} ${points.displayName}`;\n }\n return `This weird farmer dinosaur will only see you if you have at least 10 points. You only have ${displayResource(\n main.points\n )}`;\n },\n canClick() {\n return Decimal.gte(main.points.value, 10);\n }\n }));\n addTooltip(treeNode, {\n display: createResourceTooltip(points),\n pinnable: true\n });\n\n const resetButton = createResetButton(() => ({\n conversion,\n tree: main.tree,\n treeNode,\n display: jsx(() => {\n if (resetButton.conversion.buyMax) {\n return (\n <span>\n Hi! I'm a <u>weird dinosaur</u> and I'll give you{\" \"}\n <b>{formatWhole(resetButton.conversion.currentGain.value)}</b> Farm Points\n in exchange for all of your points and lollipops! (You'll get another one at{\" \"}\n {formatWhole(resetButton.conversion.nextAt.value)} points)\n </span>\n );\n } else {\n return (\n <span>\n Hi! I'm a <u>weird dinosaur</u> and I'll give you a Farm Point in exchange\n for all of your points and lollipops! (At least{\" \"}\n {formatWhole(resetButton.conversion.nextAt.value)} points)\n </span>\n );\n }\n })\n }));\n\n const particles = createParticles(() => ({\n boundingRect: ref<null | DOMRect>(null),\n onContainerResized(boundingRect) {\n this.boundingRect.value = boundingRect;\n },\n style: \"z-index: 2\"\n }));\n\n const tab = jsx(() => (\n <>\n {render(coolInfo)}\n <MainDisplay resource={points} color={color} />\n {render(resetButton)}\n <div>You have {formatWhole(conversion.baseResource.value)} points</div>\n <div>\n <br />\n <img src=\"https://images.beano.com/store/24ab3094eb95e5373bca1ccd6f330d4406db8d1f517fc4170b32e146f80d?auto=compress%2Cformat&dpr=1&w=390\" />\n <div>Bork Bork!</div>\n </div>\n <Spacer />\n {renderRow(resetClickable)}\n {renderRow(clickable)}\n {render(particles)}\n </>\n ));\n\n return {\n id,\n color,\n name,\n points,\n boop,\n coolInfo,\n clickable,\n clickableState,\n reset,\n conversion,\n treeNode,\n resetButton,\n minWidth: 650,\n display: tab\n };\n});\n\nexport default layer;\n","import Row from \"components/layout/Row.vue\";\nimport Tooltip from \"features/tooltips/Tooltip.vue\";\nimport { main } from \"data/projEntry\";\nimport { createAchievement } from \"features/achievements/achievement\";\nimport { jsx } from \"features/feature\";\nimport { createGrid } from \"features/grids/grid\";\nimport { createResource } from \"features/resources/resource\";\nimport { createTreeNode } from \"features/trees/tree\";\nimport { createLayer } from \"game/layers\";\nimport { DecimalSource } from \"lib/break_eternity\";\nimport Decimal from \"util/bignum\";\nimport { render, renderRow } from \"util/vue\";\nimport { computed } from \"vue\";\nimport f from \"./f\";\n\nconst id = \"a\";\nconst layer = createLayer(id, () => {\n const color = \"yellow\";\n const name = \"Achievements\";\n const points = createResource<DecimalSource>(0, \"achievement power\");\n\n const treeNode = createTreeNode(() => ({\n display: \"A\",\n color,\n tooltip: {\n display: \"Achievements\",\n right: true\n },\n onClick() {\n main.showAchievements();\n }\n }));\n\n const ach1 = createAchievement(() => ({\n image: \"https://unsoftcapped2.github.io/The-Modding-Tree-2/discord.png\",\n display: \"Get me!\",\n tooltip: computed(() => {\n if (ach1.earned.value) {\n return \"You did it!\";\n }\n return \"How did this happen?\";\n }),\n shouldEarn: () => true\n }));\n const ach2 = createAchievement(() => ({\n display: \"Impossible!\",\n tooltip: computed(() => {\n if (ach2.earned.value) {\n return \"HOW????\";\n }\n return \"Mwahahaha!\";\n }),\n style: { color: \"#04e050\" }\n }));\n const ach3 = createAchievement(() => ({\n display: \"EIEIO\",\n tooltip:\n \"Get a farm point.\\n\\nReward: The dinosaur is now your friend (you can max Farm Points).\",\n shouldEarn: function () {\n return Decimal.gte(f.points.value, 1);\n },\n onComplete() {\n console.log(\"Bork bork bork!\");\n }\n }));\n const achievements = [ach1, ach2, ach3];\n\n const grid = createGrid(() => ({\n rows: 2,\n cols: 2,\n getStartState(id) {\n return id;\n },\n getStyle(id, state) {\n return { backgroundColor: `#${(Number(state) * 1234) % 999999}` };\n },\n // TODO display should return an object\n getTitle(id) {\n let direction = \"\";\n if (id === \"101\") {\n direction = \"top\";\n } else if (id === \"102\") {\n direction = \"bottom\";\n } else if (id === \"201\") {\n direction = \"left\";\n } else if (id === \"202\") {\n direction = \"right\";\n }\n return jsx(() => (\n <Tooltip display={JSON.stringify(this.cells[id].style)} {...{ [direction]: true }}>\n <h3>Gridable #{id}</h3>\n </Tooltip>\n ));\n },\n getDisplay(id, state) {\n return String(state);\n },\n getCanClick() {\n return Decimal.eq(main.points.value, 10);\n },\n onClick(id, state) {\n this.cells[id].state = Number(state) + 1;\n }\n }));\n\n const display = jsx(() => (\n <>\n <Row>\n <Tooltip display={ach1.tooltip} bottom>\n {render(ach1)}\n </Tooltip>\n <Tooltip display={ach2.tooltip} bottom>\n {render(ach2)}\n </Tooltip>\n <Tooltip display={ach3.tooltip} bottom>\n {render(ach3)}\n </Tooltip>\n </Row>\n {renderRow(grid)}\n </>\n ));\n\n return {\n id,\n color,\n name,\n points,\n achievements,\n grid,\n treeNode,\n display\n };\n});\n\nexport default layer;\n","import Profectus from \"components/Profectus.vue\";\nimport Spacer from \"components/layout/Spacer.vue\";\nimport { jsx } from \"features/feature\";\nimport { createResource, trackBest, trackOOMPS, trackTotal } from \"features/resources/resource\";\nimport { branchedResetPropagation, createTree, GenericTree } from \"features/trees/tree\";\nimport { globalBus } from \"game/events\";\nimport { createLayer, GenericLayer, setupLayerModal } from \"game/layers\";\nimport player, { PlayerData } from \"game/player\";\nimport Decimal, { DecimalSource, format, formatTime } from \"util/bignum\";\nimport { render } from \"util/vue\";\nimport { computed, toRaw } from \"vue\";\nimport a from \"./layers/aca/a\";\nimport c from \"./layers/aca/c\";\nimport f from \"./layers/aca/f\";\n\n/**\n * @hidden\n */\nexport const main = createLayer(\"main\", () => {\n const points = createResource<DecimalSource>(10);\n const best = trackBest(points);\n const total = trackTotal(points);\n\n const pointGain = computed(() => {\n if (!c.generatorUpgrade.bought.value) return new Decimal(0);\n let gain = new Decimal(3.19);\n if (c.lollipopMultiplierUpgrade.bought.value)\n gain = gain.times(c.lollipopMultiplierEffect.value);\n return gain;\n });\n globalBus.on(\"update\", diff => {\n points.value = Decimal.add(points.value, Decimal.times(pointGain.value, diff));\n });\n const oomps = trackOOMPS(points, pointGain);\n\n const { openModal, modal } = setupLayerModal(a);\n\n // Note: Casting as generic tree to avoid recursive type definitions\n const tree = createTree(() => ({\n nodes: [[c.treeNode], [f.treeNode, c.spook]],\n leftSideNodes: [a.treeNode, c.h],\n branches: [\n {\n startNode: f.treeNode,\n endNode: c.treeNode,\n stroke: \"blue\",\n \"stroke-width\": \"25px\",\n style: {\n filter: \"blur(5px)\"\n }\n }\n ],\n onReset() {\n points.value = toRaw(this.resettingNode.value) === toRaw(c.treeNode) ? 0 : 10;\n best.value = points.value;\n total.value = points.value;\n },\n resetPropagation: branchedResetPropagation\n })) as GenericTree;\n\n // Note: layers don't _need_ a reference to everything,\n // but I'd recommend it over trying to remember what does and doesn't need to be included.\n // Officially all you need are anything with persistency or that you want to access elsewhere\n return {\n name: \"Tree\",\n display: jsx(() => (\n <>\n {player.devSpeed === 0 ? <div>Game Paused</div> : null}\n {player.devSpeed && player.devSpeed !== 1 ? (\n <div>Dev Speed: {format(player.devSpeed)}x</div>\n ) : null}\n {player.offlineTime ? (\n <div>Offline Time: {formatTime(player.offlineTime)}</div>\n ) : null}\n <div>\n {Decimal.lt(points.value, \"1e1000\") ? <span>You have </span> : null}\n <h2>{format(points.value)}</h2>\n {Decimal.lt(points.value, \"1e1e6\") ? <span> points</span> : null}\n </div>\n {Decimal.gt(pointGain.value, 0) ? <div>({oomps.value})</div> : null}\n <Spacer />\n <button onClick={openModal}>open achievements</button>\n {render(modal)}\n {render(tree)}\n <Profectus height=\"200px\" style=\"margin: 10px auto; display: block\" />\n </>\n )),\n points,\n best,\n total,\n oomps,\n tree,\n showAchievements: openModal\n };\n});\n\nexport const getInitialLayers = (\n /* eslint-disable-next-line @typescript-eslint/no-unused-vars */\n player: Partial<PlayerData>\n): Array<GenericLayer> => [main, f, c, a];\n\nexport const hasWon = computed(() => {\n return Decimal.gt(main.points.value, 25);\n});\n\n/* eslint-disable @typescript-eslint/no-unused-vars */\nexport function fixOldSave(\n oldVersion: string | undefined,\n player: Partial<PlayerData>\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n): void {}\n/* eslint-enable @typescript-eslint/no-unused-vars */\n","import Modal from \"components/Modal.vue\";\nimport {\n CoercableComponent,\n OptionsFunc,\n jsx,\n JSXFunction,\n Replace,\n setDefault,\n StyleValue\n} from \"features/feature\";\nimport {\n Computable,\n GetComputableType,\n GetComputableTypeWithDefault,\n processComputable,\n ProcessedComputable\n} from \"util/computed\";\nimport { createLazyProxy } from \"util/proxies\";\nimport { createNanoEvents, Emitter } from \"nanoevents\";\nimport { InjectionKey, Ref, ref, shallowReactive, unref } from \"vue\";\nimport { globalBus } from \"./events\";\nimport { Persistent, persistent } from \"./persistence\";\nimport player from \"./player\";\n\nexport interface FeatureNode {\n rect: DOMRect;\n observer: MutationObserver;\n element: HTMLElement;\n}\n\nexport const RegisterNodeInjectionKey: InjectionKey<(id: string, element: HTMLElement) => void> =\n Symbol(\"RegisterNode\");\nexport const UnregisterNodeInjectionKey: InjectionKey<(id: string) => void> =\n Symbol(\"UnregisterNode\");\nexport const NodesInjectionKey: InjectionKey<Ref<Record<string, FeatureNode | undefined>>> =\n Symbol(\"Nodes\");\nexport const BoundsInjectionKey: InjectionKey<Ref<DOMRect | undefined>> = Symbol(\"Bounds\");\n\nexport interface LayerEvents {\n // Generation\n preUpdate: (diff: number) => void;\n // Actions (e.g. automation)\n update: (diff: number) => void;\n // Effects (e.g. milestones)\n postUpdate: (diff: number) => void;\n}\n\nexport const layers: Record<string, Readonly<GenericLayer> | undefined> = shallowReactive({});\nwindow.layers = layers;\n\ndeclare module \"@vue/runtime-dom\" {\n interface CSSProperties {\n \"--layer-color\"?: string;\n }\n}\n\nexport interface Position {\n x: number;\n y: number;\n}\n\nexport interface LayerOptions {\n color?: Computable<string>;\n display: Computable<CoercableComponent>;\n classes?: Computable<Record<string, boolean>>;\n style?: Computable<StyleValue>;\n name?: Computable<string>;\n minimizable?: Computable<boolean>;\n forceHideGoBack?: Computable<boolean>;\n minWidth?: Computable<number | string>;\n}\n\nexport interface BaseLayer {\n id: string;\n minimized: Persistent<boolean>;\n emitter: Emitter<LayerEvents>;\n on: OmitThisParameter<Emitter<LayerEvents>[\"on\"]>;\n emit: <K extends keyof LayerEvents>(event: K, ...args: Parameters<LayerEvents[K]>) => void;\n nodes: Ref<Record<string, FeatureNode | undefined>>;\n}\n\nexport type Layer<T extends LayerOptions> = Replace<\n T & BaseLayer,\n {\n color: GetComputableType<T[\"color\"]>;\n display: GetComputableType<T[\"display\"]>;\n classes: GetComputableType<T[\"classes\"]>;\n style: GetComputableType<T[\"style\"]>;\n name: GetComputableTypeWithDefault<T[\"name\"], string>;\n minWidth: GetComputableTypeWithDefault<T[\"minWidth\"], 600>;\n minimizable: GetComputableTypeWithDefault<T[\"minimizable\"], true>;\n forceHideGoBack: GetComputableType<T[\"forceHideGoBack\"]>;\n }\n>;\n\nexport type GenericLayer = Replace<\n Layer<LayerOptions>,\n {\n name: ProcessedComputable<string>;\n minWidth: ProcessedComputable<number>;\n minimizable: ProcessedComputable<boolean>;\n }\n>;\n\nexport const persistentRefs: Record<string, Set<Persistent>> = {};\nexport const addingLayers: string[] = [];\nexport function createLayer<T extends LayerOptions>(\n id: string,\n optionsFunc: OptionsFunc<T, BaseLayer, BaseLayer>\n): Layer<T> {\n return createLazyProxy(() => {\n const layer = {} as T & Partial<BaseLayer>;\n const emitter = (layer.emitter = createNanoEvents<LayerEvents>());\n layer.on = emitter.on.bind(emitter);\n layer.emit = emitter.emit.bind(emitter);\n layer.nodes = ref({});\n layer.id = id;\n\n addingLayers.push(id);\n persistentRefs[id] = new Set();\n layer.minimized = persistent(false);\n Object.assign(layer, optionsFunc.call(layer));\n if (\n addingLayers[addingLayers.length - 1] == null ||\n addingLayers[addingLayers.length - 1] !== id\n ) {\n throw `Adding layers stack in invalid state. This should not happen\\nStack: ${addingLayers}\\nTrying to pop ${layer.id}`;\n }\n addingLayers.pop();\n\n processComputable(layer as T, \"color\");\n processComputable(layer as T, \"display\");\n processComputable(layer as T, \"name\");\n setDefault(layer, \"name\", layer.id);\n processComputable(layer as T, \"minWidth\");\n setDefault(layer, \"minWidth\", 600);\n processComputable(layer as T, \"minimizable\");\n setDefault(layer, \"minimizable\", true);\n\n return layer as unknown as Layer<T>;\n });\n}\n\nexport function addLayer(\n layer: GenericLayer,\n player: { layers?: Record<string, Record<string, unknown>> }\n): void {\n console.info(\"Adding layer\", layer.id);\n if (layers[layer.id]) {\n console.error(\n \"Attempted to add layer with same ID as existing layer\",\n layer.id,\n layers[layer.id]\n );\n return;\n }\n\n setDefault(player, \"layers\", {});\n if (player.layers[layer.id] == null) {\n player.layers[layer.id] = {};\n }\n layers[layer.id] = layer;\n\n globalBus.emit(\"addLayer\", layer, player.layers[layer.id]);\n}\n\nexport function getLayer<T extends GenericLayer>(layerID: string): T {\n return layers[layerID] as T;\n}\n\nexport function removeLayer(layer: GenericLayer): void {\n console.info(\"Removing layer\", layer.id);\n globalBus.emit(\"removeLayer\", layer);\n\n layers[layer.id] = undefined;\n}\n\nexport function reloadLayer(layer: GenericLayer): void {\n removeLayer(layer);\n\n // Re-create layer\n addLayer(layer, player);\n}\n\nexport function setupLayerModal(layer: GenericLayer): {\n openModal: VoidFunction;\n modal: JSXFunction;\n} {\n const showModal = ref(false);\n return {\n openModal: () => (showModal.value = true),\n modal: jsx(() => (\n <Modal\n modelValue={showModal.value}\n onUpdate:modelValue={value => (showModal.value = value)}\n v-slots={{\n header: () => <h2>{unref(layer.name)}</h2>,\n body: unref(layer.display)\n }}\n />\n ))\n };\n}\n\nglobalBus.on(\"update\", function updateLayers(diff) {\n Object.values(layers).forEach(layer => {\n layer?.emit(\"preUpdate\", diff);\n });\n Object.values(layers).forEach(layer => {\n layer?.emit(\"update\", diff);\n });\n Object.values(layers).forEach(layer => {\n layer?.emit(\"postUpdate\", diff);\n });\n});\n","import Col from \"components/layout/Column.vue\";\nimport Row from \"components/layout/Row.vue\";\nimport {\n CoercableComponent,\n Component as ComponentKey,\n GatherProps,\n GenericComponent,\n jsx,\n JSXFunction,\n Visibility\n} from \"features/feature\";\nimport {\n Component,\n computed,\n ComputedRef,\n DefineComponent,\n defineComponent,\n isRef,\n onUnmounted,\n PropType,\n ref,\n Ref,\n ShallowRef,\n shallowRef,\n unref,\n watchEffect\n} from \"vue\";\nimport { DoNotCache, ProcessedComputable } from \"./computed\";\n\nexport function coerceComponent(\n component: CoercableComponent,\n defaultWrapper = \"span\"\n): DefineComponent {\n if (typeof component === \"function\") {\n return defineComponent({ render: component });\n }\n if (typeof component === \"string\") {\n if (component.length > 0) {\n component = component.trim();\n if (component.charAt(0) !== \"<\") {\n component = `<${defaultWrapper}>${component}</${defaultWrapper}>`;\n }\n\n return defineComponent({ template: component });\n }\n return defineComponent({ render: () => ({}) });\n }\n return component;\n}\n\nexport type VueFeature = {\n [ComponentKey]: GenericComponent;\n [GatherProps]: () => Record<string, unknown>;\n};\n\nexport function render(object: VueFeature | CoercableComponent): JSX.Element | DefineComponent {\n if (isCoercableComponent(object)) {\n if (typeof object === \"function\") {\n return (object as JSXFunction)();\n }\n return coerceComponent(object);\n }\n const Component = object[ComponentKey];\n return <Component {...object[GatherProps]()} />;\n}\n\nexport function renderRow(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Row>{objects.map(render)}</Row>;\n}\n\nexport function renderCol(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Col>{objects.map(render)}</Col>;\n}\n\nexport function renderJSX(object: VueFeature | CoercableComponent): JSX.Element {\n if (isCoercableComponent(object)) {\n if (typeof object === \"function\") {\n return (object as JSXFunction)();\n }\n if (typeof object === \"string\") {\n return <>{object}</>;\n }\n // TODO why is object typed as never?\n const Comp = object as DefineComponent;\n return <Comp />;\n }\n const Component = object[ComponentKey];\n return <Component {...object[GatherProps]()} />;\n}\n\nexport function renderRowJSX(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Row>{objects.map(renderJSX)}</Row>;\n}\n\nexport function renderColJSX(...objects: (VueFeature | CoercableComponent)[]): JSX.Element {\n return <Col>{objects.map(renderJSX)}</Col>;\n}\n\nexport function isCoercableComponent(component: unknown): component is CoercableComponent {\n if (typeof component === \"string\") {\n return true;\n } else if (typeof component === \"object\") {\n if (component == null) {\n return false;\n }\n return \"render\" in component || \"component\" in component;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n } else if (typeof component === \"function\" && (component as any)[DoNotCache] === true) {\n return true;\n }\n return false;\n}\n\nexport function setupHoldToClick(\n onClick?: Ref<((e?: MouseEvent | TouchEvent) => void) | undefined>,\n onHold?: Ref<VoidFunction | undefined>\n): {\n start: (e: MouseEvent | TouchEvent) => void;\n stop: VoidFunction;\n handleHolding: VoidFunction;\n} {\n const interval = ref<null | number>(null);\n const event = ref<MouseEvent | TouchEvent | undefined>(undefined);\n\n function start(e: MouseEvent | TouchEvent) {\n if (!interval.value) {\n interval.value = setInterval(handleHolding, 250);\n }\n event.value = e;\n }\n function stop() {\n if (interval.value) {\n clearInterval(interval.value);\n interval.value = null;\n }\n }\n function handleHolding() {\n if (onHold && onHold.value) {\n onHold.value();\n } else if (onClick && onClick.value) {\n onClick.value(event.value);\n }\n }\n\n onUnmounted(stop);\n\n return { start, stop, handleHolding };\n}\n\nexport function getFirstFeature<\n T extends VueFeature & { visibility: ProcessedComputable<Visibility> }\n>(\n features: T[],\n filter: (feature: T) => boolean\n): {\n firstFeature: Ref<T | undefined>;\n collapsedContent: JSXFunction;\n hasCollapsedContent: Ref<boolean>;\n} {\n const filteredFeatures = computed(() =>\n features.filter(\n feature => unref(feature.visibility) === Visibility.Visible && filter(feature)\n )\n );\n return {\n firstFeature: computed(() => filteredFeatures.value[0]),\n collapsedContent: jsx(() => renderCol(...filteredFeatures.value.slice(1))),\n hasCollapsedContent: computed(() => filteredFeatures.value.length > 1)\n };\n}\n\nexport function computeComponent(\n component: Ref<ProcessedComputable<CoercableComponent>>,\n defaultWrapper = \"div\"\n): ShallowRef<Component | \"\"> {\n const comp = shallowRef<Component | \"\">();\n watchEffect(() => {\n comp.value = coerceComponent(unwrapRef(component), defaultWrapper);\n });\n return comp as ShallowRef<Component | \"\">;\n}\nexport function computeOptionalComponent(\n component: Ref<ProcessedComputable<CoercableComponent | undefined> | undefined>,\n defaultWrapper = \"div\"\n): ShallowRef<Component | \"\" | null> {\n const comp = shallowRef<Component | \"\" | null>(null);\n watchEffect(() => {\n const currComponent = unwrapRef(component);\n comp.value = currComponent == null ? null : coerceComponent(currComponent, defaultWrapper);\n });\n return comp;\n}\n\nexport function wrapRef<T>(ref: Ref<ProcessedComputable<T>>): ComputedRef<T> {\n return computed(() => unwrapRef(ref));\n}\n\nexport function unwrapRef<T>(ref: Ref<ProcessedComputable<T>>): T {\n return unref<T>(unref(ref));\n}\n\nexport function setRefValue<T>(ref: Ref<T | Ref<T>>, value: T) {\n if (isRef(ref.value)) {\n ref.value.value = value;\n } else {\n ref.value = value;\n }\n}\n\nexport type PropTypes =\n | typeof Boolean\n | typeof String\n | typeof Number\n | typeof Function\n | typeof Object\n | typeof Array;\n// TODO Unfortunately, the typescript engine gives up on typing completely when you use this method,\n// Even though it has the same typing as when doing it manually\nexport function processedPropType<T>(...types: PropTypes[]): PropType<ProcessedComputable<T>> {\n if (!types.includes(Object)) {\n types.push(Object);\n }\n return types as PropType<ProcessedComputable<T>>;\n}\n","import { defineComponent as _defineComponent } from 'vue'\nimport { renderSlot as _renderSlot, createElementVNode as _createElementVNode, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nimport {\n RegisterNodeInjectionKey,\n UnregisterNodeInjectionKey,\n NodesInjectionKey,\n FeatureNode,\n BoundsInjectionKey\n} from \"game/layers\";\nimport { nextTick, onMounted, provide, ref } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n emits: [\"updateNodes\"],\n setup(__props, { emit }: { emit: ({\n (e: \"updateNodes\", nodes: Record<string, FeatureNode | undefined>): void;\n}), expose: any, slots: any, attrs: any }) {\n\n\n\nconst nodes = ref<Record<string, FeatureNode | undefined>>({});\n\nconst resizeObserver = new ResizeObserver(updateBounds);\nconst resizeListener = ref<Element | null>(null);\nonMounted(() => {\n // ResizeListener exists because ResizeObserver's don't work when told to observe an SVG element\n const resListener = resizeListener.value;\n if (resListener != null) {\n resizeObserver.observe(resListener);\n }\n});\nlet isDirty = true;\nlet boundingRect = ref(resizeListener.value?.getBoundingClientRect());\nfunction updateBounds() {\n if (resizeListener.value != null && isDirty) {\n isDirty = false;\n nextTick(() => {\n boundingRect.value = resizeListener.value?.getBoundingClientRect();\n (Object.values(nodes.value) as FeatureNode[])\n .filter(n => n) // Sometimes the values become undefined\n .forEach(node => (node.rect = node.element.getBoundingClientRect()));\n emit(\"updateNodes\", nodes.value);\n isDirty = true;\n });\n }\n}\ndocument.fonts.ready.then(updateBounds);\n\nconst observerOptions = {\n attributes: false,\n childList: true,\n subtree: false\n};\n\nprovide(RegisterNodeInjectionKey, (id, element) => {\n const observer = new MutationObserver(() => updateNode(id));\n observer.observe(element, observerOptions);\n nodes.value[id] = { element, observer, rect: element.getBoundingClientRect() };\n emit(\"updateNodes\", nodes.value);\n nextTick(() => updateNode(id));\n});\nprovide(UnregisterNodeInjectionKey, id => {\n nodes.value[id]?.observer.disconnect();\n nodes.value[id] = undefined;\n emit(\"updateNodes\", nodes.value);\n});\nprovide(NodesInjectionKey, nodes);\nprovide(BoundsInjectionKey, boundingRect);\n\nfunction updateNode(id: string) {\n const node = nodes.value[id];\n if (node == null) {\n return;\n }\n node.rect = node.element.getBoundingClientRect();\n emit(\"updateNodes\", nodes.value);\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n _renderSlot(_ctx.$slots, \"default\"),\n _createElementVNode(\"div\", {\n ref_key: \"resizeListener\",\n ref: resizeListener,\n class: \"resize-listener\"\n }, null, 512)\n ], 64))\n}\n}\n\n})","import script from \"./Context.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Context.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Context.vue?vue&type=style&index=0&id=131e64e2&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-131e64e2\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderSlot as _renderSlot, createTextVNode as _createTextVNode, createElementVNode as _createElementVNode, withCtx as _withCtx, createVNode as _createVNode, vShow as _vShow, withModifiers as _withModifiers, mergeProps as _mergeProps, withDirectives as _withDirectives, Transition as _Transition, Teleport as _Teleport, openBlock as _openBlock, createBlock as _createBlock } from \"vue\"\n\nconst _hoisted_1 = [\"onPointerdown\"]\nconst _hoisted_2 = { class: \"modal-wrapper\" }\nconst _hoisted_3 = { class: \"modal-container\" }\nconst _hoisted_4 = { class: \"modal-header\" }\nconst _hoisted_5 = /*#__PURE__*/_createTextVNode(\" default header \")\nconst _hoisted_6 = { class: \"modal-body\" }\nconst _hoisted_7 = /*#__PURE__*/_createTextVNode(\" default body \")\nconst _hoisted_8 = { class: \"modal-footer\" }\nconst _hoisted_9 = /*#__PURE__*/_createElementVNode(\"div\", { class: \"modal-default-flex-grow\" }, null, -1)\n\nimport { FeatureNode } from \"game/layers\";\nimport { computed, ref, toRefs } from \"vue\";\nimport Context from \"./Context.vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n modelValue: { type: Boolean }\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { expose, emit }: { emit: ({\n (e: \"update:modelValue\", value: boolean): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n modelValue: boolean;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst isOpen = computed(() => props.modelValue || isAnimating.value);\nfunction close() {\n emit(\"update:modelValue\", false);\n}\n\nconst isAnimating = ref(false);\n\nconst contextRef = ref<typeof Context | null>(null);\nconst nodes = computed<Record<string, FeatureNode | undefined> | null>(\n () => contextRef.value?.nodes ?? null\n);\n\nexpose({ isOpen, nodes });\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createBlock(_Teleport, { to: \"#modal-root\" }, [\n _createVNode(_Transition, {\n name: \"modal\",\n onBeforeEnter: _cache[0] || (_cache[0] = ($event: any) => (isAnimating.value = true)),\n onAfterLeave: _cache[1] || (_cache[1] = ($event: any) => (isAnimating.value = false))\n }, {\n default: _withCtx(() => [\n _withDirectives(_createElementVNode(\"div\", _mergeProps({\n class: \"modal-mask\",\n onPointerdown: _withModifiers(close, [\"self\"])\n }, _ctx.$attrs), [\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n _createElementVNode(\"div\", _hoisted_4, [\n _renderSlot(_ctx.$slots, \"header\", { shown: _unref(isOpen) }, () => [\n _hoisted_5\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_6, [\n _createVNode(Context, {\n ref_key: \"contextRef\",\n ref: contextRef\n }, {\n default: _withCtx(() => [\n _renderSlot(_ctx.$slots, \"body\", { shown: _unref(isOpen) }, () => [\n _hoisted_7\n ])\n ]),\n _: 3\n }, 512)\n ]),\n _createElementVNode(\"div\", _hoisted_8, [\n _renderSlot(_ctx.$slots, \"footer\", { shown: _unref(isOpen) }, () => [\n _createElementVNode(\"div\", { class: \"modal-default-footer\" }, [\n _hoisted_9,\n _createElementVNode(\"button\", {\n class: \"button modal-default-button\",\n onClick: close\n }, \" Close \")\n ])\n ])\n ])\n ])\n ])\n ], 16, _hoisted_1), [\n [_vShow, __props.modelValue]\n ])\n ]),\n _: 3\n })\n ]))\n}\n}\n\n})","import script from \"./Modal.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Modal.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Modal.vue?vue&type=style&index=0&id=d02c1f40&lang=css\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, createVNode as _createVNode } from \"vue\"\n\nconst _hoisted_1 = { class: \"field\" }\nconst _hoisted_2 = {\n key: 0,\n class: \"field-title\"\n}\n\nimport \"components/common/fields.css\";\nimport { CoercableComponent } from \"features/feature\";\nimport { computeOptionalComponent, unwrapRef } from \"util/vue\";\nimport { ref, toRef, watch } from \"vue\";\nimport VueNextSelect from \"vue-next-select\";\nimport \"vue-next-select/dist/index.css\";\n\nexport type SelectOption = { label: string; value: unknown };\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: null,\n options: null,\n placeholder: null,\n closeOnSelect: { type: Boolean }\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: unknown): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst props = __props as {\n title?: CoercableComponent;\n modelValue?: unknown;\n options: SelectOption[];\n placeholder?: string;\n closeOnSelect?: boolean;\n}\n\n\n\n\nconst titleComponent = computeOptionalComponent(toRef(props, \"title\"), \"span\");\n\nconst value = ref<SelectOption | null>(\n props.options.find(option => option.value === props.modelValue) ?? null\n);\nwatch(toRef(props, \"modelValue\"), modelValue => {\n if (unwrapRef(value) !== modelValue) {\n value.value = props.options.find(option => option.value === modelValue) ?? null;\n }\n});\n\nfunction onUpdate(value: SelectOption) {\n emit(\"update:modelValue\", value.value);\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n (_unref(titleComponent))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_2, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(titleComponent))))\n ]))\n : _createCommentVNode(\"\", true),\n _createVNode(_unref(VueNextSelect), {\n options: __props.options,\n modelValue: value.value,\n \"onUpdate:modelValue\": [\n _cache[0] || (_cache[0] = ($event: any) => ((value).value = $event)),\n onUpdate\n ],\n min: 1,\n \"label-by\": \"label\",\n placeholder: __props.placeholder,\n \"close-on-select\": __props.closeOnSelect\n }, null, 8, [\"options\", \"modelValue\", \"placeholder\", \"close-on-select\"])\n ]))\n}\n}\n\n})","import script from \"./Select.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Select.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Select.vue?vue&type=style&index=0&id=4c379106&lang=css\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, isRef as _isRef, vModelText as _vModelText, normalizeClass as _normalizeClass, withDirectives as _withDirectives, createElementVNode as _createElementVNode, withModifiers as _withModifiers, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-8bda704a\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = [\"onSubmit\"]\nconst _hoisted_2 = { class: \"field\" }\nconst _hoisted_3 = {\n key: 0,\n class: \"field-title\"\n}\nconst _hoisted_4 = [\"placeholder\"]\n\nimport { CoercableComponent } from \"features/feature\";\nimport { coerceComponent } from \"util/vue\";\nimport { computed, onMounted, ref, toRefs, unref } from \"vue\";\nimport VueTextareaAutosize from \"vue-textarea-autosize\";\nimport \"components/common/fields.css\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: null,\n textArea: { type: Boolean },\n placeholder: null,\n maxHeight: null\n },\n emits: [\"update:modelValue\", \"submit\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: string): void;\n (e: \"submit\"): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst _props = __props as {\n title?: CoercableComponent;\n modelValue?: string;\n textArea?: boolean;\n placeholder?: string;\n maxHeight?: number;\n}\n\n\nconst props = toRefs(_props);\n\n\nconst titleComponent = computed(\n () => props.title?.value && coerceComponent(unref(props.title.value), \"span\")\n);\n\nconst field = ref<HTMLElement | null>(null);\nonMounted(() => {\n field.value?.focus();\n});\n\nconst value = computed({\n get() {\n return unref(props.modelValue) || \"\";\n },\n set(value: string) {\n emit(\"update:modelValue\", value);\n }\n});\n\nfunction submit() {\n emit(\"submit\");\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"form\", {\n onSubmit: _withModifiers(submit, [\"prevent\"])\n }, [\n _createElementVNode(\"div\", _hoisted_2, [\n (_unref(titleComponent))\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_3, [\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(titleComponent))))\n ]))\n : _createCommentVNode(\"\", true),\n (__props.textArea)\n ? (_openBlock(), _createBlock(_unref(VueTextareaAutosize), {\n key: 1,\n modelValue: _unref(value),\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(value) ? (value).value = $event : null)),\n placeholder: __props.placeholder,\n maxHeight: __props.maxHeight,\n onBlur: submit,\n ref_key: \"field\",\n ref: field\n }, null, 8, [\"modelValue\", \"placeholder\", \"maxHeight\"]))\n : _withDirectives((_openBlock(), _createElementBlock(\"input\", {\n key: 2,\n type: \"text\",\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => (_isRef(value) ? (value).value = $event : null)),\n placeholder: __props.placeholder,\n class: _normalizeClass({ fullWidth: !__props.title }),\n onBlur: submit,\n ref_key: \"field\",\n ref: field\n }, null, 42, _hoisted_4)), [\n [_vModelText, _unref(value)]\n ])\n ])\n ], 40, _hoisted_1))\n}\n}\n\n})","import script from \"./Text.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Text.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Text.vue?vue&type=style&index=0&id=8bda704a&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-8bda704a\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, isRef as _isRef, vModelCheckbox as _vModelCheckbox, createElementVNode as _createElementVNode, withDirectives as _withDirectives, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-43cf95d0\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = { class: \"field\" }\n\nimport { CoercableComponent } from \"features/feature\";\nimport { coerceComponent } from \"util/vue\";\nimport { computed, unref } from \"vue\";\nimport \"components/common/fields.css\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n props: {\n title: null,\n modelValue: { type: Boolean }\n },\n emits: [\"update:modelValue\"],\n setup(__props: any, { emit }: { emit: ({\n (e: \"update:modelValue\", value: boolean): void;\n}), expose: any, slots: any, attrs: any }) {\n\nconst props = __props as {\n title?: CoercableComponent;\n modelValue?: boolean;\n}\n\n\n\n\nconst component = computed(() => coerceComponent(unref(props.title) || \"<span></span>\", \"span\"));\n\nconst value = computed({\n get() {\n return !!props.modelValue;\n },\n set(value: boolean) {\n emit(\"update:modelValue\", value);\n }\n});\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"label\", _hoisted_1, [\n _withDirectives(_createElementVNode(\"input\", {\n type: \"checkbox\",\n class: \"toggle\",\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => (_isRef(value) ? (value).value = $event : null))\n }, null, 512), [\n [_vModelCheckbox, _unref(value)]\n ]),\n (_openBlock(), _createBlock(_resolveDynamicComponent(_unref(component))))\n ]))\n}\n}\n\n})","import script from \"./Toggle.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Toggle.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./Toggle.vue?vue&type=style&index=0&id=43cf95d0&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-43cf95d0\"]])\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderSlot as _renderSlot, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { class: \"table\" }\n\nimport \"components/common/table.css\";\nimport themes from \"data/themes\";\nimport settings from \"game/settings\";\nimport { computed } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst mergeAdjacent = computed(() => themes[settings.theme].mergeAdjacent);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"col\", { mergeAdjacent: _unref(mergeAdjacent) }])\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 2)\n ]))\n}\n}\n\n})","import script from \"./Column.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Column.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, renderSlot as _renderSlot, normalizeClass as _normalizeClass, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\"\n\nconst _hoisted_1 = { class: \"table\" }\n\nimport \"components/common/table.css\";\nimport themes from \"data/themes\";\nimport settings from \"game/settings\";\nimport { computed } from \"vue\";\n\n\nexport default /*#__PURE__*/_defineComponent({\n setup(__props) {\n\nconst mergeAdjacent = computed(() => themes[settings.theme].mergeAdjacent);\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", {\n class: _normalizeClass([\"row\", { mergeAdjacent: _unref(mergeAdjacent) }])\n }, [\n _renderSlot(_ctx.$slots, \"default\")\n ], 2)\n ]))\n}\n}\n\n})","import script from \"./Row.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./Row.vue?vue&type=script&setup=true&lang=ts\"\n\nconst __exports__ = script;\n\nexport default __exports__","import { renderSlot as _renderSlot, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementBlock as _createElementBlock, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, Transition as _Transition, withCtx as _withCtx, createVNode as _createVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-e03bc918\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = {\n key: 0,\n class: \"material-icons pinned\"\n}\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n return (_openBlock(), _createElementBlock(\"div\", {\n class: _normalizeClass([\"tooltip-container\", { shown: _ctx.isShown }]),\n onMouseenter: _cache[0] || (_cache[0] = ($event: any) => (_ctx.isHovered = true)),\n onMouseleave: _cache[1] || (_cache[1] = ($event: any) => (_ctx.isHovered = false)),\n onClickCapture: _cache[2] || (_cache[2] = \n//@ts-ignore\n(...args) => (_ctx.togglePinned && _ctx.togglePinned(...args)))\n }, [\n _renderSlot(_ctx.$slots, \"default\", {}, undefined, true),\n (_ctx.elementComp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.elementComp), { key: 0 }))\n : _createCommentVNode(\"\", true),\n _createVNode(_Transition, { name: \"fade\" }, {\n default: _withCtx(() => [\n (_ctx.isShown)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n class: _normalizeClass([\"tooltip\", {\n top: _ctx.unref(_ctx.direction) === _ctx.Direction.Up,\n left: _ctx.unref(_ctx.direction) === _ctx.Direction.Left,\n right: _ctx.unref(_ctx.direction) === _ctx.Direction.Right,\n bottom: _ctx.unref(_ctx.direction) === _ctx.Direction.Down,\n ..._ctx.unref(_ctx.classes)\n }]),\n style: _normalizeStyle([\n {\n '--xoffset': _ctx.unref(_ctx.xoffset) || '0px',\n '--yoffset': _ctx.unref(_ctx.yoffset) || '0px'\n },\n _ctx.unref(_ctx.style) ?? {}\n ])\n }, [\n (_ctx.showPin)\n ? (_openBlock(), _createElementBlock(\"span\", _hoisted_1, \"push_pin\"))\n : _createCommentVNode(\"\", true),\n (_ctx.comp)\n ? (_openBlock(), _createBlock(_resolveDynamicComponent(_ctx.comp), { key: 1 }))\n : _createCommentVNode(\"\", true)\n ], 6))\n : _createCommentVNode(\"\", true)\n ]),\n _: 1\n })\n ], 34))\n}","\nimport themes from \"data/themes\";\nimport { CoercableComponent, jsx, StyleValue } from \"features/feature\";\nimport { Persistent } from \"game/persistence\";\nimport settings from \"game/settings\";\nimport { Direction } from \"util/common\";\nimport {\n coerceComponent,\n computeOptionalComponent,\n processedPropType,\n render,\n unwrapRef,\n VueFeature\n} from \"util/vue\";\nimport {\n Component,\n computed,\n defineComponent,\n PropType,\n ref,\n shallowRef,\n toRefs,\n unref,\n watchEffect\n} from \"vue\";\n\nexport default defineComponent({\n props: {\n element: processedPropType<VueFeature>(Object),\n display: {\n type: processedPropType<CoercableComponent>(Object, String, Function),\n required: true\n },\n style: processedPropType<StyleValue>(Object, String, Array),\n classes: processedPropType<Record<string, boolean>>(Object),\n direction: processedPropType<Direction>(String),\n xoffset: processedPropType<string>(String),\n yoffset: processedPropType<string>(String),\n pinned: Object as PropType<Persistent<boolean>>\n },\n setup(props) {\n const { element, display, pinned } = toRefs(props);\n\n const isHovered = ref(false);\n const isShown = computed(() => (unwrapRef(pinned) || isHovered.value) && comp.value);\n const comp = computeOptionalComponent(display);\n\n const elementComp = shallowRef<Component | \"\" | null>(null);\n watchEffect(() => {\n const currComponent = unwrapRef(element);\n elementComp.value =\n currComponent == null\n ? null\n : coerceComponent(jsx(() => render(currComponent) as JSX.Element));\n });\n\n function togglePinned(e: MouseEvent) {\n const isPinned = pinned as unknown as Persistent<boolean> | undefined; // Vue typing :/\n if (e.shiftKey && isPinned) {\n isPinned.value = !isPinned.value;\n e.stopPropagation();\n e.preventDefault();\n }\n }\n\n const showPin = computed(() => unwrapRef(pinned) && themes[settings.theme].showPin);\n\n return {\n Direction,\n isHovered,\n isShown,\n comp,\n elementComp,\n unref,\n togglePinned,\n showPin\n };\n }\n});\n","import { render } from \"./Tooltip.vue?vue&type=template&id=e03bc918&scoped=true&ts=true\"\nimport script from \"./Tooltip.vue?vue&type=script&lang=ts\"\nexport * from \"./Tooltip.vue?vue&type=script&lang=ts\"\n\nimport \"./Tooltip.vue?vue&type=style&index=0&id=e03bc918&scoped=true&lang=css\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-e03bc918\"]])\n\nexport default __exports__","function webpackEmptyContext(req) {\n\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\te.code = 'MODULE_NOT_FOUND';\n\tthrow e;\n}\nwebpackEmptyContext.keys = function() { return []; };\nwebpackEmptyContext.resolve = webpackEmptyContext;\nwebpackEmptyContext.id = 7634;\nmodule.exports = webpackEmptyContext;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = function(result, chunkIds, fn, priority) {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every(function(key) { return __webpack_require__.O[key](chunkIds[j]); })) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = function(module) {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t143: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; };\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = function(parentChunkLoadingFunction, data) {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some(function(id) { return installedChunks[id] !== 0; })) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunkprofectus\"] = self[\"webpackChunkprofectus\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [998], function() { return __webpack_require__(7964); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["defaultTheme","variables","floatingTabs","mergeAdjacent","showPin","Themes","classic","paper","nordic","aqua","Component","Symbol","GatherProps","id","getUniqueID","prefix","Visibility","jsx","func","showIf","condition","otherwise","None","Visible","setDefault","object","key","value","undefined","findFeatures","obj","types","objects","handleObject","Object","keys","forEach","includes","type","push","isRef","globalBus","intervalID","hasWon","update","now","Date","diff","trueDiff","Math","max","offlineDiff","min","Number","isFinite","emit","requestAnimationFrame","clearInterval","setInterval","async","startGameLoop","watch","PersistentState","DefaultValue","StackTrace","Deleted","getStackTrace","Error","stack","split","slice","map","line","trim","join","persistent","defaultValue","ref","addingLayers","console","warn","persistentRefs","add","layer","saveData","features","path","foundPersistent","delete","persistentState","reduce","acc","curr","savedValue","isReactive","foundPersistentInChild","error","clear","state","reactive","devSpeed","name","tabs","time","autosave","offlineProd","offlineTime","timePlayed","keepGoing","modID","modVersion","layers","stringifySave","player","JSON","stringify","unref","playerHandler","get","target","Array","isArray","Proxy","set","property","receiver","isNaN","sign","mag","currentValue","ownKeys","Reflect","has","getOwnPropertyDescriptor","window","active","saves","showTPS","theme","unthrottled","loadSettings","item","localStorage","getItem","decodeURIComponent","escape","atob","settings","parse","assign","stringifiedSettings","setItem","deep","hardResetSettings","settingFields","registerSettingField","component","infoComponents","registerInfoComponent","gameComponents","shallowReactive","lastTenTicks","hasNaN","NaNPath","render","_ctx","_cache","$props","$setup","$data","$options","_component_Context","class","style","color","showGoBack","onClick","args","goBack","minimized","$event","onUpdateNodes","updateNodes","default","_","minimizable","defineComponent","components","Context","props","index","required","tab","Function","display","String","minWidth","Boolean","nodes","setup","toRefs","computed","projInfo","allowGoBack","Infinity","updateTab","width","parseInt","tabValue","flexGrow","flexShrink","flexBasis","margin","nextTick","__exports__","_withScopeId","n","_hoisted_1","_hoisted_2","open","__props","expose","isOpen","Modal","modelValue","header","body","_hoisted_3","_hoisted_4","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_hoisted_9","_hoisted_10","_hoisted_11","_hoisted_12","href","_hoisted_13","_hoisted_14","changelog","_props","title","logo","author","discordName","discordLink","versionNumber","versionTitle","infoComponent","openChangelog","src","alt","shown","themes","label","settingFieldsComponent","isPaused","offlineProdTitle","autosaveTitle","isPausedTitle","Select","options","Toggle","enablePausing","disabled","skipConfirm","emits","isConfirming","click","cancel","confirming","$slots","left","activated","activatedTimeout","clearTimeout","setTimeout","_hoisted_15","_hoisted_16","save","dateFormat","Intl","DateTimeFormat","year","month","day","hour","minute","second","isEditing","newName","isActive","currentTime","changeName","FeedbackButton","Tooltip","direction","Left","DangerButton","onConfirmingChanged","format","Text","onSubmit","modal","importingFailed","saveToImport","selectedPreset","importedSave","playerData","e","bankContext","bank","cachedSaves","getCachedSave","exportSave","saveToExport","exportEncoding","btoa","unescape","encodeURIComponent","el","document","createElement","appendChild","select","setSelectionRange","execCommand","removeChild","duplicateSave","deleteSave","removeItem","openSave","newFromPreset","preset","editSave","currSave","ref_key","list","handle","itemKey","element","Save","onOpen","onExport","onEditName","onDuplicate","onDelete","footer","placeholder","length","closeOnSelect","_hoisted_17","_hoisted_18","_hoisted_19","_hoisted_20","_hoisted_21","_hoisted_22","_hoisted_23","_hoisted_24","_hoisted_25","info","savesManager","useHeader","banner","openDiscord","$attrs","Down","yoffset","xoffset","Right","Info","SavesManager","Options","Changelog","toRef","layerKeys","gatherLayerProps","classes","ref_for","Nav","Layer","$refs","playAgain","previous","setZero","setOne","ignore","NaN","neq","tps","lastTenFPS","watchEffect","round","toNumber","low","showLow","gt","isNan","gameComponent","Game","TPS","GameOverScreen","NaNScreen","log","vue","createApp","App","mount","MAX_SIGNIFICANT_DIGITS","EXP_LIMIT","LAYER_DOWN","log10","FIRST_NEG_LAYER","NUMBER_EXP_MAX","NUMBER_EXP_MIN","MAX_ES_IN_A_ROW","IGNORE_COMMAS","COMMAS_ARE_DECIMAL_POINTS","powerOf10","powersOf10","i","for","indexOf0InPowersOf10","power","critical_headers","E","critical_tetr_values","critical_slog_values","D","Decimal","fromValue_noAlloc","FC","fromComponents","FC_NN","fromComponents_noNormalize","decimalPlaces","places","len","numDigits","ceil","abs","rounded","pow","parseFloat","toFixed","f_maglog10","f_gamma","trunc","NEGATIVE_INFINITY","scal1","l","n2","np","exp","OMEGA","f_lambertw","z","tol","w","wn","toString","d_lambertw","ew","wewz","dZero","dOne","ln","sub","mul","div","lt","constructor","this","fromDecimal","fromNumber","fromString","m","floor","man","residue","fromMantissaExponent","exponent","POSITIVE_INFINITY","s","mantissa","fromMantissaExponent_noNormalize","fromValue","neg","other","recip","reciprocate","cmp","cmpabs","eq","notEquals","lte","gte","minabs","maxabs","clamp","clampMin","clampMax","tolerance","cmp_tolerance","eq_tolerance","neq_tolerance","notEquals_tolerance","lt_tolerance","lte_tolerance","gt_tolerance","gte_tolerance","pLog10","absLog10","base","log2","logarithm","pow10","root","_other","factorial","gamma","lngamma","sqr","sqrt","cube","cbrt","height","payload","tetrate","iteratedexp","times","iteratedlog","layeradd10","layeradd","slog","lambertw","ssqrt","pentate","resourcesAvailable","priceStart","priceRatio","currentOwned","affordGeometricSeries_core","numItems","sumGeometricSeries_core","priceAdd","affordArithmeticSeries_core","sumArithmeticSeries_core","cost","currentRpS","deltaRpS","efficiencyOfPurchase_core","maxLayers","random","randomsign","randomexp","randommag","actualStart","b","b2","plus","normalize","absmag","signmag","replace","pentationparts","heightparts","result","tetrationparts","powparts","toLowerCase","ptparts","parts","ecount","numberAttempt","newparts","charAt","layerstring","chrcode","charCodeAt","substr","me","mantissaWithDecimalPlaces","magnitudeWithDecimalPlaces","repeat","toExponential","toStringWithDecimalPlaces","toPrecision","valueOf","toJSON","negate","negated","sgn","decimal","a","layera","layerb","magdiff","subtract","minus","newmag","multiply","divide","divideBy","dividedBy","dNaN","reciprocal","compare","equals","compare_tolerance","magA","magB","equals_tolerance","pow_base","t","lm","adj","l2","this_num","negln","oldheight","fracheight","old_payload","next_payload","tetrate_critical","fulltimes","fraction","layerloss","dNegOne","copy","slog_critical","critical_section","grid","lower","upper","basefrac","frac","slogthis","slogdest","lnx","sin","cos","tan","asin","acos","atan","sinh","cosh","tanh","asinh","acosh","atanh","ascensionPenalty","ascensions","egg","lessThanOrEqualTo","lessThan","greaterThanOrEqualTo","greaterThan","MAX_VALUE","MIN_VALUE","decimalOne","exponentialFormat","num","precision","eString","defaultDecimalsShown","commaFormat","init","portions","regularFormat","eeee1000","e100000","e1000","e9","e6","e3","nearOne","thousandth","zero","small","defaultShowSmall","invertOOM","val","formatWhole","formatTime","seconds","toPlaces","x","maxAccepted","formatSmall","camelToTitle","camel","toUpperCase","isPlainObject","prototype","call","isFunction","Direction","DoNotCache","processComputable","computable","bind","convertComputable","ProxyState","ProxyPath","createLazyProxy","objectFunc","baseObject","calculated","calculateObj","setupInitialStore","stringifiedSave","load","loadSave","newSave","playerObj","removeLayer","addLayer","fixOldSave","getInitialLayers","onbeforeunload","hardReset","xmlns","viewBox","d","appear","script","createResource","displayName","resource","trackBest","best","amount","trackTotal","total","prevAmount","tetra8","e100","trackOOMPS","pointGain","oomps","oompsMag","lastPoints","prev","oompsString","displayResource","overrideAmount","_component_Links","nodesComp","leftNodesComp","rightNodesComp","branches","links","link","startNode","endNode","boundingRect","startPosition","rect","position","y","offsetStart","endPosition","offsetEnd","stroke","x1","y1","x2","y2","resizeListener","inject","NodesInjectionKey","outerBoundingRect","BoundsInjectionKey","getBoundingClientRect","validLinks","filter","Link","leftSideNodes","rightSideNodes","Links","shallowRef","currNodes","row","_component_MarkNode","_component_Node","visibility","Hidden","treeNode","can","canClick","onMousedown","start","onMouseleave","stop","onMouseup","onTouchstartPassive","onTouchendPassive","onTouchcancelPassive","backgroundColor","boxShadow","glowColor","comp","mark","register","RegisterNodeInjectionKey","unregister","UnregisterNodeInjectionKey","node","parentNode","parentElement","newNode","newID","prevNode","prevID","onUnmounted","onHold","MarkNode","Node","isCoercableComponent","TreeNodeType","TreeType","createTreeNode","optionsFunc","TreeNode","createTree","tree","Tree","isResetting","resettingNode","reset","genericTree","resetPropagation","onReset","branchedResetPropagation","visitedNodes","currentNodes","nextNodes","branch","createResourceTooltip","requiredResource","requirement","req","backgroundImage","earned","image","feature","achievement","locked","bought","getNotifyStyle","strength","transform","borderColor","zIndex","getHighNotifyStyle","use","toast","AchievementType","createAchievement","Achievement","complete","shouldEarn","genericAchievement","onComplete","Display","_component_GridCell","rows","cols","col","gatherCellProps","cells","tile","titleComponent","GridCell","cell","createGridProxy","getGridHandler","getCellHandler","configurable","enumerable","writable","cache","prop","getState","createGrid","cellState","Grid","getID","startState","setState","clickable","currDisplay","Title","Description","description","ClickableType","createClickable","Clickable","createResetButton","resetButton","resetDescription","conversion","gainResource","actualGain","minimumGain","buyMax","baseResource","nextAt","currentAt","showNextAt","convert","createLayerTreeNode","layerID","append","createConversion","currentGain","gain","gainModifier","apply","scaling","current","roundUpCost","next","createPolynomialScaling","processedBase","processedExponent","revert","createCumulativeConversion","createIndependentConversion","softcap","cap","addSoftcap","_component_CollapseTransition","collapsed","stacked","titleStyle","bodyComponent","bodyStyle","CollapseTransition","InfoboxType","createInfobox","infobox","Infobox","onInit","onContainerResized","onHotReload","app","resizeObserver","ResizeObserver","updateBounds","onMounted","resListener","observe","resizeTo","backgroundAlpha","view","onBeforeUnmount","destroy","isDirty","resize","fonts","ready","then","ParticlesType","createParticles","particles","Particles","addEmitter","config","genericParticles","Promise","resolve","stage","emittersToAdd","upgradeConfig","ResetType","createReset","values","thingsToReset","listeners","effectDisplay","effectComponent","showPrefix","Resource","addTooltip","pinnable","pinned","elementComponent","elementGratherProps","createAdditiveModifier","addend","enabled","processedAddend","processedDescription","processedEnabled","createMultiplicativeModifier","multiplier","processedMultiplier","createExponentialModifier","createSequentialModifier","modifiers","modifier","every","reduceRight","createModifierSection","subtitle","unit","baseText","fullWidth","top","observer","updateTop","newTop","previousSibling","sibling","dataset","offsetHeight","bar","borderStyle","textStyle","baseStyle","barStyle","fillStyle","progress","normalizedProgress","progressNumber","clipPath","BarType","createBar","Bar","BuyableType","createBuyable","buyable","canPurchase","canAfford","genericBuyable","purchaseLimit","maxed","currClasses","purchase","onPurchase","CurrDisplay","EffectDisplay","amountDisplay","notifyStyle","challenge","done","completed","canStart","toggle","buttonText","canComplete","currActive","currCanComplete","Goal","goal","Reward","reward","ChallengeType","createChallenge","completions","Challenge","completionLimit","genericChallenge","onExit","onEnter","remainInChallenge","currentReset","hotkeys","HotkeyType","createHotkey","hotkey","onkeydown","tagName","shiftKey","ctrlKey","preventDefault","onPress","LinksType","createLinks","milestone","Requirement","OptionsDisplay","optionsDisplay","MilestoneType","MilestoneDisplay","createMilestone","Milestone","All","Configurable","Incomplete","genericMilestone","msDisplayOptions","option","TabType","createTab","Tab","selectTab","glowColorStyle","floating","_component_TabButton","_component_Sticky","tabClasses","tabStyle","button","onSelectTab","selected","activeTab","gatherButtonProps","Sticky","TabButton","currActiveTab","TabButtonType","TabFamilyType","createTabFamily","tabFamily","TabFamily","parsedTabs","tabButton","processedTabFamily","firstTab","find","upgrade","currCost","UpgradeType","createUpgrade","Upgrade","genericUpgrade","createLayer","points","beep","thingy","otherThingy","spentOnBuyables","waffleBoost","icecreamCap","coolInfo","lollipopMilestone3","lollipopMilestone4","f","boop","lollipopMilestones","funChallenge","funEffect","main","generatorUpgrade","lollipopMultiplierUpgrade","lollipopMultiplierEffect","ret","unlockIlluminatiUpgrade","quasiUpgrade","exhancers","upgrades","thingEffect","stuffEffect","confirmRespec","respecBuyables","sellExhancer","buyablesDisplay","longBoi","tallBoi","textShadow","borderWidth","flatBoi","tooltip","textDecoration","g","h","right","spook","illuminatiTabs","first","border","marginLeft","marginRight","mainTab","thingies","jail","illuminati","bars","clickableState","initialState","pos","touches","confettiParticles","clientX","clientY","playOnceAndDestroy","resetClickable","modifyGainAmount","c","ach1","ach2","ach3","achievements","getStartState","getStyle","getTitle","getDisplay","getCanClick","openModal","setupLayerModal","toRaw","showAchievements","oldVersion","emitter","on","Set","pop","getLayer","reloadLayer","showModal","coerceComponent","defaultWrapper","template","renderRow","renderCol","renderJSX","Comp","setupHoldToClick","interval","event","handleHolding","computeComponent","unwrapRef","computeOptionalComponent","currComponent","wrapRef","processedPropType","observerOptions","attributes","childList","subtree","updateNode","provide","MutationObserver","disconnect","isAnimating","close","contextRef","to","onBeforeEnter","onAfterLeave","onPointerdown","onUpdate","textArea","maxHeight","field","focus","submit","onBlur","isShown","onMouseenter","isHovered","onClickCapture","togglePinned","elementComp","Up","bottom","isPinned","stopPropagation","webpackEmptyContext","code","module","exports","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","loaded","__webpack_modules__","deferred","O","chunkIds","fn","priority","notFulfilled","fulfilled","j","splice","r","getter","__esModule","definition","o","defineProperty","globalThis","hasOwnProperty","toStringTag","nmd","paths","children","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","data","moreModules","runtime","some","chunkLoadingGlobal","self","__webpack_exports__"],"sourceRoot":""} \ No newline at end of file diff --git a/js/chunk-vendors-legacy.e714a3a2.js b/js/chunk-vendors-legacy.e714a3a2.js deleted file mode 100644 index 434e492..0000000 --- a/js/chunk-vendors-legacy.e714a3a2.js +++ /dev/null @@ -1,245 +0,0 @@ -(self["webpackChunkprofectus"]=self["webpackChunkprofectus"]||[]).push([[998],{1680:function(t,e,n){"use strict"; -/*! - * @pixi/constants - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/constants is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var r,i,o,s,a,u,l,c,h,f,d,p,v,m,g,_,y,b,E;n.d(e,{iw:function(){return v},T$:function(){return s},V0:function(){return o},mr:function(){return E},yl:function(){return m},lg:function(){return a},Vi:function(){return r},I2:function(){return u},UN:function(){return g},A7:function(){return y},WB:function(){return p},G5:function(){return b},cB:function(){return _},N3:function(){return i},oT:function(){return h},aH:function(){return f},sp:function(){return l},vK:function(){return c},Nt:function(){return d}}),function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"}(r||(r={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(i||(i={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(o||(o={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(s||(s={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(a||(a={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(u||(u={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(l||(l={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(c||(c={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(h||(h={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(f||(f={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(d||(d={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(p||(p={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(v||(v={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(m||(m={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(g||(g={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(_||(_={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(y||(y={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(b||(b={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(E||(E={}))},2038:function(t,e,n){"use strict";n.d(e,{VL:function(){return _},a$:function(){return qe},JZ:function(){return tn},Bv:function(){return on},Ie:function(){return Ke},lW:function(){return X},qm:function(){return m},wn:function(){return Jt},ZX:function(){return z},bO:function(){return nt},$r:function(){return Xt},ud:function(){return q},TI:function(){return B},Th:function(){return He},ex:function(){return jt},ZM:function(){return qt},xE:function(){return D},UX:function(){return ne},oo:function(){return Z},Rv:function(){return Ze},e6:function(){return Ve},Y9:function(){return $e},kP:function(){return ze}});var r=n(1576),i=n(1680),o=n(8942),s=n(1034),a=n(6679),u=n(9658); -/*! - * @pixi/core - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/core is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -r.X.PREFER_ENV=o.tq.any?i.Vi.WEBGL:i.Vi.WEBGL2,r.X.STRICT_TEXTURE_CACHE=!1;var l=[];function c(t,e){if(!t)return null;var n="";if("string"===typeof t){var r=/\.(\w{3,4})(?:$|\?|#)/i.exec(t);r&&(n=r[1].toLowerCase())}for(var i=l.length-1;i>=0;--i){var o=l[i];if(o.test&&o.test(t,n))return new o(t,e)}throw new Error("Unrecognized source type to auto-detect Resource")} -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */var h=function(t,e){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},h(t,e)};function f(t,e){function n(){this.constructor=t}h(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var d=function(){return d=Object.assign||function(t){for(var e,n=arguments,r=1,i=arguments.length;r<i;r++)for(var o in e=n[r],e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},d.apply(this,arguments)};function p(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&(n[r[i]]=t[r[i]])}return n}var v=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this._width=t,this._height=e,this.destroyed=!1,this.internal=!1,this.onResize=new s.R("setRealSize"),this.onUpdate=new s.R("update"),this.onError=new s.R("onError")}return t.prototype.bind=function(t){this.onResize.add(t),this.onUpdate.add(t),this.onError.add(t),(this._width||this._height)&&this.onResize.emit(this._width,this._height)},t.prototype.unbind=function(t){this.onResize.remove(t),this.onUpdate.remove(t),this.onError.remove(t)},t.prototype.resize=function(t,e){t===this._width&&e===this._height||(this._width=t,this._height=e,this.onResize.emit(t,e))},Object.defineProperty(t.prototype,"valid",{get:function(){return!!this._width&&!!this._height},enumerable:!1,configurable:!0}),t.prototype.update=function(){this.destroyed||this.onUpdate.emit()},t.prototype.load=function(){return Promise.resolve(this)},Object.defineProperty(t.prototype,"width",{get:function(){return this._width},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this._height},enumerable:!1,configurable:!0}),t.prototype.style=function(t,e,n){return!1},t.prototype.dispose=function(){},t.prototype.destroy=function(){this.destroyed||(this.destroyed=!0,this.dispose(),this.onError.removeAll(),this.onError=null,this.onResize.removeAll(),this.onResize=null,this.onUpdate.removeAll(),this.onUpdate=null)},t.test=function(t,e){return!1},t}(),m=function(t){function e(e,n){var r=this,i=n||{},o=i.width,s=i.height;if(!o||!s)throw new Error("BufferResource width or height invalid");return r=t.call(this,o,s)||this,r.data=e,r}return f(e,t),e.prototype.upload=function(t,e,n){var r=t.gl;r.pixelStorei(r.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e.alphaMode===i.iw.UNPACK);var o=e.realWidth,s=e.realHeight;return n.width===o&&n.height===s?r.texSubImage2D(e.target,0,0,0,o,s,e.format,n.type,this.data):(n.width=o,n.height=s,r.texImage2D(e.target,0,n.internalFormat,o,s,0,e.format,n.type,this.data)),!0},e.prototype.dispose=function(){this.data=null},e.test=function(t){return t instanceof Float32Array||t instanceof Uint8Array||t instanceof Uint32Array},e}(v),g={scaleMode:i.aH.NEAREST,format:i.I2.RGBA,alphaMode:i.iw.NPM},_=function(t){function e(e,n){void 0===e&&(e=null),void 0===n&&(n=null);var s=t.call(this)||this;n=n||{};var a=n.alphaMode,u=n.mipmap,l=n.anisotropicLevel,h=n.scaleMode,f=n.width,d=n.height,p=n.wrapMode,m=n.format,g=n.type,_=n.target,y=n.resolution,b=n.resourceOptions;return!e||e instanceof v||(e=c(e,b),e.internal=!0),s.resolution=y||r.X.RESOLUTION,s.width=Math.round((f||0)*s.resolution)/s.resolution,s.height=Math.round((d||0)*s.resolution)/s.resolution,s._mipmap=void 0!==u?u:r.X.MIPMAP_TEXTURES,s.anisotropicLevel=void 0!==l?l:r.X.ANISOTROPIC_LEVEL,s._wrapMode=p||r.X.WRAP_MODE,s._scaleMode=void 0!==h?h:r.X.SCALE_MODE,s.format=m||i.I2.RGBA,s.type=g||i.vK.UNSIGNED_BYTE,s.target=_||i.sp.TEXTURE_2D,s.alphaMode=void 0!==a?a:i.iw.UNPACK,s.uid=(0,o.hQ)(),s.touched=0,s.isPowerOfTwo=!1,s._refreshPOT(),s._glTextures={},s.dirtyId=0,s.dirtyStyleId=0,s.cacheId=null,s.valid=f>0&&d>0,s.textureCacheIds=[],s.destroyed=!1,s.resource=null,s._batchEnabled=0,s._batchLocation=0,s.parentTextureArray=null,s.setResource(e),s}return f(e,t),Object.defineProperty(e.prototype,"realWidth",{get:function(){return Math.round(this.width*this.resolution)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"realHeight",{get:function(){return Math.round(this.height*this.resolution)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"mipmap",{get:function(){return this._mipmap},set:function(t){this._mipmap!==t&&(this._mipmap=t,this.dirtyStyleId++)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"scaleMode",{get:function(){return this._scaleMode},set:function(t){this._scaleMode!==t&&(this._scaleMode=t,this.dirtyStyleId++)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"wrapMode",{get:function(){return this._wrapMode},set:function(t){this._wrapMode!==t&&(this._wrapMode=t,this.dirtyStyleId++)},enumerable:!1,configurable:!0}),e.prototype.setStyle=function(t,e){var n;return void 0!==t&&t!==this.scaleMode&&(this.scaleMode=t,n=!0),void 0!==e&&e!==this.mipmap&&(this.mipmap=e,n=!0),n&&this.dirtyStyleId++,this},e.prototype.setSize=function(t,e,n){return n=n||this.resolution,this.setRealSize(t*n,e*n,n)},e.prototype.setRealSize=function(t,e,n){return this.resolution=n||this.resolution,this.width=Math.round(t)/this.resolution,this.height=Math.round(e)/this.resolution,this._refreshPOT(),this.update(),this},e.prototype._refreshPOT=function(){this.isPowerOfTwo=(0,o.wv)(this.realWidth)&&(0,o.wv)(this.realHeight)},e.prototype.setResolution=function(t){var e=this.resolution;return e===t||(this.resolution=t,this.valid&&(this.width=Math.round(this.width*e)/t,this.height=Math.round(this.height*e)/t,this.emit("update",this)),this._refreshPOT()),this},e.prototype.setResource=function(t){if(this.resource===t)return this;if(this.resource)throw new Error("Resource can be set only once");return t.bind(this),this.resource=t,this},e.prototype.update=function(){this.valid?(this.dirtyId++,this.dirtyStyleId++,this.emit("update",this)):this.width>0&&this.height>0&&(this.valid=!0,this.emit("loaded",this),this.emit("update",this))},e.prototype.onError=function(t){this.emit("error",this,t)},e.prototype.destroy=function(){this.resource&&(this.resource.unbind(this),this.resource.internal&&this.resource.destroy(),this.resource=null),this.cacheId&&(delete o.V8[this.cacheId],delete o.kN[this.cacheId],this.cacheId=null),this.dispose(),e.removeFromCache(this),this.textureCacheIds=null,this.destroyed=!0},e.prototype.dispose=function(){this.emit("dispose",this)},e.prototype.castToBaseTexture=function(){return this},e.from=function(t,n,i){void 0===i&&(i=r.X.STRICT_TEXTURE_CACHE);var s="string"===typeof t,a=null;if(s)a=t;else{if(!t._pixiId){var u=n&&n.pixiIdPrefix||"pixiid";t._pixiId=u+"_"+(0,o.hQ)()}a=t._pixiId}var l=o.V8[a];if(s&&i&&!l)throw new Error('The cacheId "'+a+'" does not exist in BaseTextureCache.');return l||(l=new e(t,n),l.cacheId=a,e.addToCache(l,a)),l},e.fromBuffer=function(t,n,r,o){t=t||new Float32Array(n*r*4);var s=new m(t,{width:n,height:r}),a=t instanceof Float32Array?i.vK.FLOAT:i.vK.UNSIGNED_BYTE;return new e(s,Object.assign(g,o||{width:n,height:r,type:a}))},e.addToCache=function(t,e){e&&(-1===t.textureCacheIds.indexOf(e)&&t.textureCacheIds.push(e),o.V8[e]&&console.warn("BaseTexture added to the cache with an id ["+e+"] that already had an entry"),o.V8[e]=t)},e.removeFromCache=function(t){if("string"===typeof t){var e=o.V8[t];if(e){var n=e.textureCacheIds.indexOf(t);return n>-1&&e.textureCacheIds.splice(n,1),delete o.V8[t],e}}else if(t&&t.textureCacheIds){for(var r=0;r<t.textureCacheIds.length;++r)delete o.V8[t.textureCacheIds[r]];return t.textureCacheIds.length=0,t}return null},e._globalBatch=0,e}(o.vp),y=function(t){function e(e,n){var r=this,i=n||{},o=i.width,s=i.height;r=t.call(this,o,s)||this,r.items=[],r.itemDirtyIds=[];for(var a=0;a<e;a++){var u=new _;r.items.push(u),r.itemDirtyIds.push(-2)}return r.length=e,r._load=null,r.baseTexture=null,r}return f(e,t),e.prototype.initFromArray=function(t,e){for(var n=0;n<this.length;n++)t[n]&&(t[n].castToBaseTexture?this.addBaseTextureAt(t[n].castToBaseTexture(),n):t[n]instanceof v?this.addResourceAt(t[n],n):this.addResourceAt(c(t[n],e),n))},e.prototype.dispose=function(){for(var t=0,e=this.length;t<e;t++)this.items[t].destroy();this.items=null,this.itemDirtyIds=null,this._load=null},e.prototype.addResourceAt=function(t,e){if(!this.items[e])throw new Error("Index "+e+" is out of bounds");return t.valid&&!this.valid&&this.resize(t.width,t.height),this.items[e].setResource(t),this},e.prototype.bind=function(e){if(null!==this.baseTexture)throw new Error("Only one base texture per TextureArray is allowed");t.prototype.bind.call(this,e);for(var n=0;n<this.length;n++)this.items[n].parentTextureArray=e,this.items[n].on("update",e.update,e)},e.prototype.unbind=function(e){t.prototype.unbind.call(this,e);for(var n=0;n<this.length;n++)this.items[n].parentTextureArray=null,this.items[n].off("update",e.update,e)},e.prototype.load=function(){var t=this;if(this._load)return this._load;var e=this.items.map((function(t){return t.resource})).filter((function(t){return t})),n=e.map((function(t){return t.load()}));return this._load=Promise.all(n).then((function(){var e=t.items[0],n=e.realWidth,r=e.realHeight;return t.resize(n,r),Promise.resolve(t)})),this._load},e}(v),b=function(t){function e(e,n){var r,i,o=this,s=n||{},a=s.width,u=s.height;return Array.isArray(e)?(r=e,i=e.length):i=e,o=t.call(this,i,{width:a,height:u})||this,r&&o.initFromArray(r,n),o}return f(e,t),e.prototype.addBaseTextureAt=function(t,e){if(!t.resource)throw new Error("ArrayResource does not support RenderTexture");return this.addResourceAt(t.resource,e),this},e.prototype.bind=function(e){t.prototype.bind.call(this,e),e.target=i.sp.TEXTURE_2D_ARRAY},e.prototype.upload=function(t,e,n){var r=this,i=r.length,o=r.itemDirtyIds,s=r.items,a=t.gl;n.dirtyId<0&&a.texImage3D(a.TEXTURE_2D_ARRAY,0,n.internalFormat,this._width,this._height,i,0,e.format,n.type,null);for(var u=0;u<i;u++){var l=s[u];o[u]<l.dirtyId&&(o[u]=l.dirtyId,l.valid&&a.texSubImage3D(a.TEXTURE_2D_ARRAY,0,0,0,u,l.resource.width,l.resource.height,1,e.format,n.type,l.resource.source))}return!0},e}(y),E=function(t){function e(e){var n=this,r=e,i=r.naturalWidth||r.videoWidth||r.width,o=r.naturalHeight||r.videoHeight||r.height;return n=t.call(this,i,o)||this,n.source=e,n.noSubImage=!1,n}return f(e,t),e.crossOrigin=function(t,e,n){void 0===n&&0!==e.indexOf("data:")?t.crossOrigin=(0,o.Qq)(e):!1!==n&&(t.crossOrigin="string"===typeof n?n:"anonymous")},e.prototype.upload=function(t,e,n,r){var o=t.gl,s=e.realWidth,a=e.realHeight;if(r=r||this.source,r instanceof HTMLImageElement){if(!r.complete||0===r.naturalWidth)return!1}else if(r instanceof HTMLVideoElement&&r.readyState<=1)return!1;return o.pixelStorei(o.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e.alphaMode===i.iw.UNPACK),this.noSubImage||e.target!==o.TEXTURE_2D||n.width!==s||n.height!==a?(n.width=s,n.height=a,o.texImage2D(e.target,0,n.internalFormat,e.format,n.type,r)):o.texSubImage2D(o.TEXTURE_2D,0,0,0,e.format,n.type,r),!0},e.prototype.update=function(){if(!this.destroyed){var e=this.source,n=e.naturalWidth||e.videoWidth||e.width,r=e.naturalHeight||e.videoHeight||e.height;this.resize(n,r),t.prototype.update.call(this)}},e.prototype.dispose=function(){this.source=null},e}(v),x=function(t){function e(e){return t.call(this,e)||this}return f(e,t),e.test=function(t){var e=globalThis.OffscreenCanvas;return!!(e&&t instanceof e)||globalThis.HTMLCanvasElement&&t instanceof HTMLCanvasElement},e}(E),T=function(t){function e(n,r){var o=this,s=r||{},a=s.width,u=s.height,l=s.autoLoad,c=s.linkBaseTexture;if(n&&n.length!==e.SIDES)throw new Error("Invalid length. Got "+n.length+", expected 6");o=t.call(this,6,{width:a,height:u})||this;for(var h=0;h<e.SIDES;h++)o.items[h].target=i.sp.TEXTURE_CUBE_MAP_POSITIVE_X+h;return o.linkBaseTexture=!1!==c,n&&o.initFromArray(n,r),!1!==l&&o.load(),o}return f(e,t),e.prototype.bind=function(e){t.prototype.bind.call(this,e),e.target=i.sp.TEXTURE_CUBE_MAP},e.prototype.addBaseTextureAt=function(t,e,n){if(void 0===n&&(n=this.linkBaseTexture),!this.items[e])throw new Error("Index "+e+" is out of bounds");if(!this.linkBaseTexture||t.parentTextureArray||Object.keys(t._glTextures).length>0){if(!t.resource)throw new Error("CubeResource does not support copying of renderTexture.");this.addResourceAt(t.resource,e)}else t.target=i.sp.TEXTURE_CUBE_MAP_POSITIVE_X+e,t.parentTextureArray=this.baseTexture,this.items[e]=t;return t.valid&&!this.valid&&this.resize(t.realWidth,t.realHeight),this.items[e]=t,this},e.prototype.upload=function(t,n,r){for(var i=this.itemDirtyIds,o=0;o<e.SIDES;o++){var s=this.items[o];i[o]<s.dirtyId&&(s.valid&&s.resource?(s.resource.upload(t,s,r),i[o]=s.dirtyId):i[o]<-1&&(t.gl.texImage2D(s.target,0,r.internalFormat,n.realWidth,n.realHeight,0,n.format,r.type,null),i[o]=-1))}return!0},e.test=function(t){return Array.isArray(t)&&t.length===e.SIDES},e.SIDES=6,e}(y),S=function(t){function e(e,n){var i=this;if(n=n||{},!(e instanceof HTMLImageElement)){var o=new Image;E.crossOrigin(o,e,n.crossorigin),o.src=e,e=o}return i=t.call(this,e)||this,!e.complete&&i._width&&i._height&&(i._width=0,i._height=0),i.url=e.src,i._process=null,i.preserveBitmap=!1,i.createBitmap=(void 0!==n.createBitmap?n.createBitmap:r.X.CREATE_IMAGE_BITMAP)&&!!globalThis.createImageBitmap,i.alphaMode="number"===typeof n.alphaMode?n.alphaMode:null,i.bitmap=null,i._load=null,!1!==n.autoLoad&&i.load(),i}return f(e,t),e.prototype.load=function(t){var e=this;return this._load||(void 0!==t&&(this.createBitmap=t),this._load=new Promise((function(t,n){var r=e.source;e.url=r.src;var i=function(){e.destroyed||(r.onload=null,r.onerror=null,e.resize(r.width,r.height),e._load=null,e.createBitmap?t(e.process()):t(e))};r.complete&&r.src?i():(r.onload=i,r.onerror=function(t){n(t),e.onError.emit(t)})}))),this._load},e.prototype.process=function(){var t=this,e=this.source;if(null!==this._process)return this._process;if(null!==this.bitmap||!globalThis.createImageBitmap)return Promise.resolve(this);var n=globalThis.createImageBitmap,r=!e.crossOrigin||"anonymous"===e.crossOrigin;return this._process=fetch(e.src,{mode:r?"cors":"no-cors"}).then((function(t){return t.blob()})).then((function(r){return n(r,0,0,e.width,e.height,{premultiplyAlpha:t.alphaMode===i.iw.UNPACK?"premultiply":"none"})})).then((function(e){return t.destroyed?Promise.reject():(t.bitmap=e,t.update(),t._process=null,Promise.resolve(t))})),this._process},e.prototype.upload=function(e,n,r){if("number"===typeof this.alphaMode&&(n.alphaMode=this.alphaMode),!this.createBitmap)return t.prototype.upload.call(this,e,n,r);if(!this.bitmap&&(this.process(),!this.bitmap))return!1;if(t.prototype.upload.call(this,e,n,r,this.bitmap),!this.preserveBitmap){var i=!0,o=n._glTextures;for(var s in o){var a=o[s];if(a!==r&&a.dirtyId!==n.dirtyId){i=!1;break}}i&&(this.bitmap.close&&this.bitmap.close(),this.bitmap=null)}return!0},e.prototype.dispose=function(){this.source.onload=null,this.source.onerror=null,t.prototype.dispose.call(this),this.bitmap&&(this.bitmap.close(),this.bitmap=null),this._process=null,this._load=null},e.test=function(t){return"string"===typeof t||t instanceof HTMLImageElement},e}(E),R=function(t){function e(e,n){var r=this;return n=n||{},r=t.call(this,document.createElement("canvas"))||this,r._width=0,r._height=0,r.svg=e,r.scale=n.scale||1,r._overrideWidth=n.width,r._overrideHeight=n.height,r._resolve=null,r._crossorigin=n.crossorigin,r._load=null,!1!==n.autoLoad&&r.load(),r}return f(e,t),e.prototype.load=function(){var t=this;return this._load||(this._load=new Promise((function(n){if(t._resolve=function(){t.resize(t.source.width,t.source.height),n(t)},e.SVG_XML.test(t.svg.trim())){if(!btoa)throw new Error("Your browser doesn't support base64 conversions.");t.svg="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(t.svg)))}t._loadSvg()}))),this._load},e.prototype._loadSvg=function(){var t=this,e=new Image;E.crossOrigin(e,this.svg,this._crossorigin),e.src=this.svg,e.onerror=function(n){t._resolve&&(e.onerror=null,t.onError.emit(n))},e.onload=function(){if(t._resolve){var n=e.width,r=e.height;if(!n||!r)throw new Error("The SVG image must have width and height defined (in pixels), canvas API needs them.");var i=n*t.scale,s=r*t.scale;(t._overrideWidth||t._overrideHeight)&&(i=t._overrideWidth||t._overrideHeight/r*n,s=t._overrideHeight||t._overrideWidth/n*r),i=Math.round(i),s=Math.round(s);var a=t.source;a.width=i,a.height=s,a._pixiId="canvas_"+(0,o.hQ)(),a.getContext("2d").drawImage(e,0,0,n,r,0,0,i,s),t._resolve(),t._resolve=null}}},e.getSize=function(t){var n=e.SVG_SIZE.exec(t),r={};return n&&(r[n[1]]=Math.round(parseFloat(n[3])),r[n[5]]=Math.round(parseFloat(n[7]))),r},e.prototype.dispose=function(){t.prototype.dispose.call(this),this._resolve=null,this._crossorigin=null},e.test=function(t,n){return"svg"===n||"string"===typeof t&&/^data:image\/svg\+xml(;(charset=utf8|utf8))?;base64/.test(t)||"string"===typeof t&&e.SVG_XML.test(t)},e.SVG_XML=/^(<\?xml[^?]+\?>)?\s*(<!--[^(-->)]*-->)?\s*\<svg/m,e.SVG_SIZE=/<svg[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*>/i,e}(E),A=function(t){function e(n,r){var i=this;if(r=r||{},!(n instanceof HTMLVideoElement)){var o=document.createElement("video");o.setAttribute("preload","auto"),o.setAttribute("webkit-playsinline",""),o.setAttribute("playsinline",""),"string"===typeof n&&(n=[n]);var s=n[0].src||n[0];E.crossOrigin(o,s,r.crossorigin);for(var a=0;a<n.length;++a){var u=document.createElement("source"),l=n[a],c=l.src,h=l.mime;c=c||n[a];var f=c.split("?").shift().toLowerCase(),d=f.slice(f.lastIndexOf(".")+1);h=h||e.MIME_TYPES[d]||"video/"+d,u.src=c,u.type=h,o.appendChild(u)}n=o}return i=t.call(this,n)||this,i.noSubImage=!0,i._autoUpdate=!0,i._isConnectedToTicker=!1,i._updateFPS=r.updateFPS||0,i._msToNextUpdate=0,i.autoPlay=!1!==r.autoPlay,i._load=null,i._resolve=null,i._onCanPlay=i._onCanPlay.bind(i),i._onError=i._onError.bind(i),!1!==r.autoLoad&&i.load(),i}return f(e,t),e.prototype.update=function(e){if(!this.destroyed){var n=a.vB.shared.elapsedMS*this.source.playbackRate;this._msToNextUpdate=Math.floor(this._msToNextUpdate-n),(!this._updateFPS||this._msToNextUpdate<=0)&&(t.prototype.update.call(this),this._msToNextUpdate=this._updateFPS?Math.floor(1e3/this._updateFPS):0)}},e.prototype.load=function(){var t=this;if(this._load)return this._load;var e=this.source;return(e.readyState===e.HAVE_ENOUGH_DATA||e.readyState===e.HAVE_FUTURE_DATA)&&e.width&&e.height&&(e.complete=!0),e.addEventListener("play",this._onPlayStart.bind(this)),e.addEventListener("pause",this._onPlayStop.bind(this)),this._isSourceReady()?this._onCanPlay():(e.addEventListener("canplay",this._onCanPlay),e.addEventListener("canplaythrough",this._onCanPlay),e.addEventListener("error",this._onError,!0)),this._load=new Promise((function(n){t.valid?n(t):(t._resolve=n,e.load())})),this._load},e.prototype._onError=function(t){this.source.removeEventListener("error",this._onError,!0),this.onError.emit(t)},e.prototype._isSourcePlaying=function(){var t=this.source;return t.currentTime>0&&!1===t.paused&&!1===t.ended&&t.readyState>2},e.prototype._isSourceReady=function(){var t=this.source;return 3===t.readyState||4===t.readyState},e.prototype._onPlayStart=function(){this.valid||this._onCanPlay(),this.autoUpdate&&!this._isConnectedToTicker&&(a.vB.shared.add(this.update,this),this._isConnectedToTicker=!0)},e.prototype._onPlayStop=function(){this._isConnectedToTicker&&(a.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1)},e.prototype._onCanPlay=function(){var t=this.source;t.removeEventListener("canplay",this._onCanPlay),t.removeEventListener("canplaythrough",this._onCanPlay);var e=this.valid;this.resize(t.videoWidth,t.videoHeight),!e&&this._resolve&&(this._resolve(this),this._resolve=null),this._isSourcePlaying()?this._onPlayStart():this.autoPlay&&t.play()},e.prototype.dispose=function(){this._isConnectedToTicker&&(a.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1);var e=this.source;e&&(e.removeEventListener("error",this._onError,!0),e.pause(),e.src="",e.load()),t.prototype.dispose.call(this)},Object.defineProperty(e.prototype,"autoUpdate",{get:function(){return this._autoUpdate},set:function(t){t!==this._autoUpdate&&(this._autoUpdate=t,!this._autoUpdate&&this._isConnectedToTicker?(a.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1):this._autoUpdate&&!this._isConnectedToTicker&&this._isSourcePlaying()&&(a.vB.shared.add(this.update,this),this._isConnectedToTicker=!0))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"updateFPS",{get:function(){return this._updateFPS},set:function(t){t!==this._updateFPS&&(this._updateFPS=t)},enumerable:!1,configurable:!0}),e.test=function(t,n){return globalThis.HTMLVideoElement&&t instanceof HTMLVideoElement||e.TYPES.indexOf(n)>-1},e.TYPES=["mp4","m4v","webm","ogg","ogv","h264","avi","mov"],e.MIME_TYPES={ogv:"video/ogg",mov:"video/quicktime",m4v:"video/mp4"},e}(E),O=function(t){function e(e){return t.call(this,e)||this}return f(e,t),e.test=function(t){return!!globalThis.createImageBitmap&&t instanceof ImageBitmap},e}(E);l.push(S,O,x,A,R,m,T,b);var w={__proto__:null,Resource:v,BaseImageResource:E,INSTALLED:l,autoDetectResource:c,AbstractMultiResource:y,ArrayResource:b,BufferResource:m,CanvasResource:x,CubeResource:T,ImageResource:S,SVGResource:R,VideoResource:A,ImageBitmapResource:O},I=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return f(e,t),e.prototype.upload=function(t,e,n){var r=t.gl;r.pixelStorei(r.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e.alphaMode===i.iw.UNPACK);var o=e.realWidth,s=e.realHeight;return n.width===o&&n.height===s?r.texSubImage2D(e.target,0,0,0,o,s,e.format,n.type,this.data):(n.width=o,n.height=s,r.texImage2D(e.target,0,n.internalFormat,o,s,0,e.format,n.type,this.data)),!0},e}(m),P=function(){function t(t,e){this.width=Math.round(t||100),this.height=Math.round(e||100),this.stencil=!1,this.depth=!1,this.dirtyId=0,this.dirtyFormat=0,this.dirtySize=0,this.depthTexture=null,this.colorTextures=[],this.glFramebuffers={},this.disposeRunner=new s.R("disposeFramebuffer"),this.multisample=i.G5.NONE}return Object.defineProperty(t.prototype,"colorTexture",{get:function(){return this.colorTextures[0]},enumerable:!1,configurable:!0}),t.prototype.addColorTexture=function(t,e){return void 0===t&&(t=0),this.colorTextures[t]=e||new _(null,{scaleMode:i.aH.NEAREST,resolution:1,mipmap:i.WB.OFF,width:this.width,height:this.height}),this.dirtyId++,this.dirtyFormat++,this},t.prototype.addDepthTexture=function(t){return this.depthTexture=t||new _(new I(null,{width:this.width,height:this.height}),{scaleMode:i.aH.NEAREST,resolution:1,width:this.width,height:this.height,mipmap:i.WB.OFF,format:i.I2.DEPTH_COMPONENT,type:i.vK.UNSIGNED_SHORT}),this.dirtyId++,this.dirtyFormat++,this},t.prototype.enableDepth=function(){return this.depth=!0,this.dirtyId++,this.dirtyFormat++,this},t.prototype.enableStencil=function(){return this.stencil=!0,this.dirtyId++,this.dirtyFormat++,this},t.prototype.resize=function(t,e){if(t=Math.round(t),e=Math.round(e),t!==this.width||e!==this.height){this.width=t,this.height=e,this.dirtyId++,this.dirtySize++;for(var n=0;n<this.colorTextures.length;n++){var r=this.colorTextures[n],i=r.resolution;r.setSize(t/i,e/i)}if(this.depthTexture){i=this.depthTexture.resolution;this.depthTexture.setSize(t/i,e/i)}}},t.prototype.dispose=function(){this.disposeRunner.emit(this,!1)},t.prototype.destroyDepthTexture=function(){this.depthTexture&&(this.depthTexture.destroy(),this.depthTexture=null,++this.dirtyId,++this.dirtyFormat)},t}(),C=function(t){function e(e){void 0===e&&(e={});var n=this;if("number"===typeof e){var r=arguments[0],o=arguments[1],s=arguments[2],a=arguments[3];e={width:r,height:o,scaleMode:s,resolution:a}}return e.width=e.width||100,e.height=e.height||100,e.multisample=void 0!==e.multisample?e.multisample:i.G5.NONE,n=t.call(this,null,e)||this,n.mipmap=i.WB.OFF,n.valid=!0,n.clearColor=[0,0,0,0],n.framebuffer=new P(n.realWidth,n.realHeight).addColorTexture(0,n),n.framebuffer.multisample=e.multisample,n.maskStack=[],n.filterStack=[{}],n}return f(e,t),e.prototype.resize=function(t,e){this.framebuffer.resize(t*this.resolution,e*this.resolution),this.setRealSize(this.framebuffer.width,this.framebuffer.height)},e.prototype.dispose=function(){this.framebuffer.dispose(),t.prototype.dispose.call(this)},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.framebuffer.destroyDepthTexture(),this.framebuffer=null},e}(_),N=function(){function t(){this.x0=0,this.y0=0,this.x1=1,this.y1=0,this.x2=1,this.y2=1,this.x3=0,this.y3=1,this.uvsFloat32=new Float32Array(8)}return t.prototype.set=function(t,e,n){var r=e.width,i=e.height;if(n){var o=t.width/2/r,s=t.height/2/i,a=t.x/r+o,l=t.y/i+s;n=u.Lv.add(n,u.Lv.NW),this.x0=a+o*u.Lv.uX(n),this.y0=l+s*u.Lv.uY(n),n=u.Lv.add(n,2),this.x1=a+o*u.Lv.uX(n),this.y1=l+s*u.Lv.uY(n),n=u.Lv.add(n,2),this.x2=a+o*u.Lv.uX(n),this.y2=l+s*u.Lv.uY(n),n=u.Lv.add(n,2),this.x3=a+o*u.Lv.uX(n),this.y3=l+s*u.Lv.uY(n)}else this.x0=t.x/r,this.y0=t.y/i,this.x1=(t.x+t.width)/r,this.y1=t.y/i,this.x2=(t.x+t.width)/r,this.y2=(t.y+t.height)/i,this.x3=t.x/r,this.y3=(t.y+t.height)/i;this.uvsFloat32[0]=this.x0,this.uvsFloat32[1]=this.y0,this.uvsFloat32[2]=this.x1,this.uvsFloat32[3]=this.y1,this.uvsFloat32[4]=this.x2,this.uvsFloat32[5]=this.y2,this.uvsFloat32[6]=this.x3,this.uvsFloat32[7]=this.y3},t.prototype.toString=function(){return"[@pixi/core:TextureUvs x0="+this.x0+" y0="+this.y0+" x1="+this.x1+" y1="+this.y1+" x2="+this.x2+" y2="+this.y2+" x3="+this.x3+" y3="+this.y3+"]"},t}(),M=new N,D=function(t){function e(n,r,i,o,s,a){var l=t.call(this)||this;if(l.noFrame=!1,r||(l.noFrame=!0,r=new u.Ae(0,0,1,1)),n instanceof e&&(n=n.baseTexture),l.baseTexture=n,l._frame=r,l.trim=o,l.valid=!1,l._uvs=M,l.uvMatrix=null,l.orig=i||r,l._rotate=Number(s||0),!0===s)l._rotate=2;else if(l._rotate%2!==0)throw new Error("attempt to use diamond-shaped UVs. If you are sure, set rotation manually");return l.defaultAnchor=a?new u.E9(a.x,a.y):new u.E9(0,0),l._updateID=0,l.textureCacheIds=[],n.valid?l.noFrame?n.valid&&l.onBaseTextureUpdated(n):l.frame=r:n.once("loaded",l.onBaseTextureUpdated,l),l.noFrame&&n.on("update",l.onBaseTextureUpdated,l),l}return f(e,t),e.prototype.update=function(){this.baseTexture.resource&&this.baseTexture.resource.update()},e.prototype.onBaseTextureUpdated=function(t){if(this.noFrame){if(!this.baseTexture.valid)return;this._frame.width=t.width,this._frame.height=t.height,this.valid=!0,this.updateUvs()}else this.frame=this._frame;this.emit("update",this)},e.prototype.destroy=function(t){if(this.baseTexture){if(t){var n=this.baseTexture.resource;n&&n.url&&o.kN[n.url]&&e.removeFromCache(n.url),this.baseTexture.destroy()}this.baseTexture.off("loaded",this.onBaseTextureUpdated,this),this.baseTexture.off("update",this.onBaseTextureUpdated,this),this.baseTexture=null}this._frame=null,this._uvs=null,this.trim=null,this.orig=null,this.valid=!1,e.removeFromCache(this),this.textureCacheIds=null},e.prototype.clone=function(){var t=this._frame.clone(),n=this._frame===this.orig?t:this.orig.clone(),r=new e(this.baseTexture,!this.noFrame&&t,n,this.trim&&this.trim.clone(),this.rotate,this.defaultAnchor);return this.noFrame&&(r._frame=t),r},e.prototype.updateUvs=function(){this._uvs===M&&(this._uvs=new N),this._uvs.set(this._frame,this.baseTexture,this.rotate),this._updateID++},e.from=function(t,n,i){void 0===n&&(n={}),void 0===i&&(i=r.X.STRICT_TEXTURE_CACHE);var s="string"===typeof t,a=null;if(s)a=t;else if(t instanceof _){if(!t.cacheId){var u=n&&n.pixiIdPrefix||"pixiid";t.cacheId=u+"-"+(0,o.hQ)(),_.addToCache(t,t.cacheId)}a=t.cacheId}else{if(!t._pixiId){u=n&&n.pixiIdPrefix||"pixiid";t._pixiId=u+"_"+(0,o.hQ)()}a=t._pixiId}var l=o.kN[a];if(s&&i&&!l)throw new Error('The cacheId "'+a+'" does not exist in TextureCache.');return l||t instanceof _?!l&&t instanceof _&&(l=new e(t),e.addToCache(l,a)):(n.resolution||(n.resolution=(0,o.fL)(t)),l=new e(new _(t,n)),l.baseTexture.cacheId=a,_.addToCache(l.baseTexture,a),e.addToCache(l,a)),l},e.fromURL=function(t,n){var r=Object.assign({autoLoad:!1},null===n||void 0===n?void 0:n.resourceOptions),i=e.from(t,Object.assign({resourceOptions:r},n),!1),o=i.baseTexture.resource;return i.baseTexture.valid?Promise.resolve(i):o.load().then((function(){return Promise.resolve(i)}))},e.fromBuffer=function(t,n,r,i){return new e(_.fromBuffer(t,n,r,i))},e.fromLoader=function(t,n,i,s){var a=new _(t,Object.assign({scaleMode:r.X.SCALE_MODE,resolution:(0,o.fL)(n)},s)),u=a.resource;u instanceof S&&(u.url=n);var l=new e(a);return i||(i=n),_.addToCache(l.baseTexture,i),e.addToCache(l,i),i!==n&&(_.addToCache(l.baseTexture,n),e.addToCache(l,n)),l.baseTexture.valid?Promise.resolve(l):new Promise((function(t){l.baseTexture.once("loaded",(function(){return t(l)}))}))},e.addToCache=function(t,e){e&&(-1===t.textureCacheIds.indexOf(e)&&t.textureCacheIds.push(e),o.kN[e]&&console.warn("Texture added to the cache with an id ["+e+"] that already had an entry"),o.kN[e]=t)},e.removeFromCache=function(t){if("string"===typeof t){var e=o.kN[t];if(e){var n=e.textureCacheIds.indexOf(t);return n>-1&&e.textureCacheIds.splice(n,1),delete o.kN[t],e}}else if(t&&t.textureCacheIds){for(var r=0;r<t.textureCacheIds.length;++r)o.kN[t.textureCacheIds[r]]===t&&delete o.kN[t.textureCacheIds[r]];return t.textureCacheIds.length=0,t}return null},Object.defineProperty(e.prototype,"resolution",{get:function(){return this.baseTexture.resolution},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"frame",{get:function(){return this._frame},set:function(t){this._frame=t,this.noFrame=!1;var e=t.x,n=t.y,r=t.width,i=t.height,o=e+r>this.baseTexture.width,s=n+i>this.baseTexture.height;if(o||s){var a=o&&s?"and":"or",u="X: "+e+" + "+r+" = "+(e+r)+" > "+this.baseTexture.width,l="Y: "+n+" + "+i+" = "+(n+i)+" > "+this.baseTexture.height;throw new Error("Texture Error: frame does not fit inside the base Texture dimensions: "+u+" "+a+" "+l)}this.valid=r&&i&&this.baseTexture.valid,this.trim||this.rotate||(this.orig=t),this.valid&&this.updateUvs()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rotate",{get:function(){return this._rotate},set:function(t){this._rotate=t,this.valid&&this.updateUvs()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"width",{get:function(){return this.orig.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.orig.height},enumerable:!1,configurable:!0}),e.prototype.castToBaseTexture=function(){return this.baseTexture},e}(o.vp);function L(){var t=document.createElement("canvas");t.width=16,t.height=16;var e=t.getContext("2d");return e.fillStyle="white",e.fillRect(0,0,16,16),new D(new _(new x(t)))}function F(t){t.destroy=function(){},t.on=function(){},t.once=function(){},t.emit=function(){}}D.EMPTY=new D(new _),F(D.EMPTY),F(D.EMPTY.baseTexture),D.WHITE=L(),F(D.WHITE),F(D.WHITE.baseTexture);var B=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.valid=!0,r.filterFrame=null,r.filterPoolKey=null,r.updateUvs(),r}return f(e,t),Object.defineProperty(e.prototype,"framebuffer",{get:function(){return this.baseTexture.framebuffer},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"multisample",{get:function(){return this.framebuffer.multisample},set:function(t){this.framebuffer.multisample=t},enumerable:!1,configurable:!0}),e.prototype.resize=function(t,e,n){void 0===n&&(n=!0);var r=this.baseTexture.resolution,i=Math.round(t*r)/r,o=Math.round(e*r)/r;this.valid=i>0&&o>0,this._frame.width=this.orig.width=i,this._frame.height=this.orig.height=o,n&&this.baseTexture.resize(i,o),this.updateUvs()},e.prototype.setResolution=function(t){var e=this.baseTexture;e.resolution!==t&&(e.setResolution(t),this.resize(e.width,e.height,!1))},e.create=function(t){for(var n=arguments,r=[],i=1;i<arguments.length;i++)r[i-1]=n[i];return"number"===typeof t&&((0,o.a1)("6.0.0","Arguments (width, height, scaleMode, resolution) have been deprecated."),t={width:t,height:r[0],scaleMode:r[1],resolution:r[2]}),new e(new C(t))},e}(D),U=function(){function t(t){this.texturePool={},this.textureOptions=t||{},this.enableFullScreen=!1,this._pixelsWidth=0,this._pixelsHeight=0}return t.prototype.createTexture=function(t,e,n){void 0===n&&(n=i.G5.NONE);var r=new C(Object.assign({width:t,height:e,resolution:1,multisample:n},this.textureOptions));return new B(r)},t.prototype.getOptimalTexture=function(t,e,n,r){var s;void 0===n&&(n=1),void 0===r&&(r=i.G5.NONE),t=Math.ceil(t*n-1e-6),e=Math.ceil(e*n-1e-6),this.enableFullScreen&&t===this._pixelsWidth&&e===this._pixelsHeight?s=r>1?-r:-1:(t=(0,o.a9)(t),e=(0,o.a9)(e),s=((65535&t)<<16|65535&e)>>>0,r>1&&(s+=4294967296*r)),this.texturePool[s]||(this.texturePool[s]=[]);var a=this.texturePool[s].pop();return a||(a=this.createTexture(t,e,r)),a.filterPoolKey=s,a.setResolution(n),a},t.prototype.getFilterTexture=function(t,e,n){var r=this.getOptimalTexture(t.width,t.height,e||t.resolution,n||i.G5.NONE);return r.filterFrame=t.filterFrame,r},t.prototype.returnTexture=function(t){var e=t.filterPoolKey;t.filterFrame=null,this.texturePool[e].push(t)},t.prototype.returnFilterTexture=function(t){this.returnTexture(t)},t.prototype.clear=function(t){if(t=!1!==t,t)for(var e in this.texturePool){var n=this.texturePool[e];if(n)for(var r=0;r<n.length;r++)n[r].destroy(!0)}this.texturePool={}},t.prototype.setScreenSize=function(t){if(t.width!==this._pixelsWidth||t.height!==this._pixelsHeight){for(var e in this.enableFullScreen=t.width>0&&t.height>0,this.texturePool)if(Number(e)<0){var n=this.texturePool[e];if(n)for(var r=0;r<n.length;r++)n[r].destroy(!0);this.texturePool[e]=[]}this._pixelsWidth=t.width,this._pixelsHeight=t.height}},t.SCREEN_KEY=-1,t}(),G=function(){function t(t,e,n,r,o,s,a){void 0===e&&(e=0),void 0===n&&(n=!1),void 0===r&&(r=i.vK.FLOAT),this.buffer=t,this.size=e,this.normalized=n,this.type=r,this.stride=o,this.start=s,this.instance=a}return t.prototype.destroy=function(){this.buffer=null},t.from=function(e,n,r,i,o){return new t(e,n,r,i,o)},t}(),k=0,X=function(){function t(t,e,n){void 0===e&&(e=!0),void 0===n&&(n=!1),this.data=t||new Float32Array(1),this._glBuffers={},this._updateID=0,this.index=n,this.static=e,this.id=k++,this.disposeRunner=new s.R("disposeBuffer")}return t.prototype.update=function(t){t instanceof Array&&(t=new Float32Array(t)),this.data=t||this.data,this._updateID++},t.prototype.dispose=function(){this.disposeRunner.emit(this,!1)},t.prototype.destroy=function(){this.dispose(),this.data=null},Object.defineProperty(t.prototype,"index",{get:function(){return this.type===i.mr.ELEMENT_ARRAY_BUFFER},set:function(t){this.type=t?i.mr.ELEMENT_ARRAY_BUFFER:i.mr.ARRAY_BUFFER},enumerable:!1,configurable:!0}),t.from=function(e){return e instanceof Array&&(e=new Float32Array(e)),new t(e)},t}(),j={Float32Array:Float32Array,Uint32Array:Uint32Array,Int32Array:Int32Array,Uint8Array:Uint8Array};function H(t,e){for(var n=0,r=0,i={},s=0;s<t.length;s++)r+=e[s],n+=t[s].length;var a=new ArrayBuffer(4*n),u=null,l=0;for(s=0;s<t.length;s++){var c=e[s],h=t[s],f=(0,o.u7)(h);i[f]||(i[f]=new j[f](a)),u=i[f];for(var d=0;d<h.length;d++){var p=(d/c|0)*r+l,v=d%c;u[p+v]=h[d]}l+=c}return new Float32Array(a)}var V={5126:4,5123:2,5121:1},Y=0,W={Float32Array:Float32Array,Uint32Array:Uint32Array,Int32Array:Int32Array,Uint8Array:Uint8Array,Uint16Array:Uint16Array},z=function(){function t(t,e){void 0===t&&(t=[]),void 0===e&&(e={}),this.buffers=t,this.indexBuffer=null,this.attributes=e,this.glVertexArrayObjects={},this.id=Y++,this.instanced=!1,this.instanceCount=1,this.disposeRunner=new s.R("disposeGeometry"),this.refCount=0}return t.prototype.addAttribute=function(t,e,n,r,i,o,s,a){if(void 0===n&&(n=0),void 0===r&&(r=!1),void 0===a&&(a=!1),!e)throw new Error("You must pass a buffer when creating an attribute");e instanceof X||(e instanceof Array&&(e=new Float32Array(e)),e=new X(e));var u=t.split("|");if(u.length>1){for(var l=0;l<u.length;l++)this.addAttribute(u[l],e,n,r,i);return this}var c=this.buffers.indexOf(e);return-1===c&&(this.buffers.push(e),c=this.buffers.length-1),this.attributes[t]=new G(c,n,r,i,o,s,a),this.instanced=this.instanced||a,this},t.prototype.getAttribute=function(t){return this.attributes[t]},t.prototype.getBuffer=function(t){return this.buffers[this.getAttribute(t).buffer]},t.prototype.addIndex=function(t){return t instanceof X||(t instanceof Array&&(t=new Uint16Array(t)),t=new X(t)),t.type=i.mr.ELEMENT_ARRAY_BUFFER,this.indexBuffer=t,-1===this.buffers.indexOf(t)&&this.buffers.push(t),this},t.prototype.getIndex=function(){return this.indexBuffer},t.prototype.interleave=function(){if(1===this.buffers.length||2===this.buffers.length&&this.indexBuffer)return this;var t,e=[],n=[],r=new X;for(t in this.attributes){var i=this.attributes[t],o=this.buffers[i.buffer];e.push(o.data),n.push(i.size*V[i.type]/4),i.buffer=0}for(r.data=H(e,n),t=0;t<this.buffers.length;t++)this.buffers[t]!==this.indexBuffer&&this.buffers[t].destroy();return this.buffers=[r],this.indexBuffer&&this.buffers.push(this.indexBuffer),this},t.prototype.getSize=function(){for(var t in this.attributes){var e=this.attributes[t],n=this.buffers[e.buffer];return n.data.length/(e.stride/4||e.size)}return 0},t.prototype.dispose=function(){this.disposeRunner.emit(this,!1)},t.prototype.destroy=function(){this.dispose(),this.buffers=null,this.indexBuffer=null,this.attributes=null},t.prototype.clone=function(){for(var e=new t,n=0;n<this.buffers.length;n++)e.buffers[n]=new X(this.buffers[n].data.slice(0));for(var n in this.attributes){var r=this.attributes[n];e.attributes[n]=new G(r.buffer,r.size,r.normalized,r.type,r.stride,r.start,r.instance)}return this.indexBuffer&&(e.indexBuffer=e.buffers[this.buffers.indexOf(this.indexBuffer)],e.indexBuffer.type=i.mr.ELEMENT_ARRAY_BUFFER),e},t.merge=function(e){for(var n,r=new t,s=[],a=[],u=[],l=0;l<e.length;l++){n=e[l];for(var c=0;c<n.buffers.length;c++)a[c]=a[c]||0,a[c]+=n.buffers[c].data.length,u[c]=0}for(l=0;l<n.buffers.length;l++)s[l]=new(W[(0,o.u7)(n.buffers[l].data)])(a[l]),r.buffers[l]=new X(s[l]);for(l=0;l<e.length;l++){n=e[l];for(c=0;c<n.buffers.length;c++)s[c].set(n.buffers[c].data,u[c]),u[c]+=n.buffers[c].data.length}if(r.attributes=n.attributes,n.indexBuffer){r.indexBuffer=r.buffers[n.buffers.indexOf(n.indexBuffer)],r.indexBuffer.type=i.mr.ELEMENT_ARRAY_BUFFER;var h=0,f=0,d=0,p=0;for(l=0;l<n.buffers.length;l++)if(n.buffers[l]!==n.indexBuffer){p=l;break}for(var l in n.attributes){var v=n.attributes[l];(0|v.buffer)===p&&(f+=v.size*V[v.type]/4)}for(l=0;l<e.length;l++){var m=e[l].indexBuffer.data;for(c=0;c<m.length;c++)r.indexBuffer.data[c+d]+=h;h+=e[l].buffers[p].data.length/f,d+=m.length}}return r},t}(),$=function(t){function e(){var e=t.call(this)||this;return e.addAttribute("aVertexPosition",new Float32Array([0,0,1,0,1,1,0,1])).addIndex([0,1,3,2]),e}return f(e,t),e}(z),q=function(t){function e(){var e=t.call(this)||this;return e.vertices=new Float32Array([-1,-1,1,-1,1,1,-1,1]),e.uvs=new Float32Array([0,0,1,0,1,1,0,1]),e.vertexBuffer=new X(e.vertices),e.uvBuffer=new X(e.uvs),e.addAttribute("aVertexPosition",e.vertexBuffer).addAttribute("aTextureCoord",e.uvBuffer).addIndex([0,1,2,0,2,3]),e}return f(e,t),e.prototype.map=function(t,e){var n=0,r=0;return this.uvs[0]=n,this.uvs[1]=r,this.uvs[2]=n+e.width/t.width,this.uvs[3]=r,this.uvs[4]=n+e.width/t.width,this.uvs[5]=r+e.height/t.height,this.uvs[6]=n,this.uvs[7]=r+e.height/t.height,n=e.x,r=e.y,this.vertices[0]=n,this.vertices[1]=r,this.vertices[2]=n+e.width,this.vertices[3]=r,this.vertices[4]=n+e.width,this.vertices[5]=r+e.height,this.vertices[6]=n,this.vertices[7]=r+e.height,this.invalidate(),this},e.prototype.invalidate=function(){return this.vertexBuffer._updateID++,this.uvBuffer._updateID++,this},e}(z),K=0,Z=function(){function t(t,e,n){this.group=!0,this.syncUniforms={},this.dirtyId=0,this.id=K++,this.static=!!e,this.ubo=!!n,t instanceof X?(this.buffer=t,this.buffer.type=i.mr.UNIFORM_BUFFER,this.autoManage=!1,this.ubo=!0):(this.uniforms=t,this.ubo&&(this.buffer=new X(new Float32Array(1)),this.buffer.type=i.mr.UNIFORM_BUFFER,this.autoManage=!0))}return t.prototype.update=function(){this.dirtyId++,!this.autoManage&&this.buffer&&this.buffer.update()},t.prototype.add=function(e,n,r){if(this.ubo)throw new Error("[UniformGroup] uniform groups in ubo mode cannot be modified, or have uniform groups nested in them");this.uniforms[e]=new t(n,r)},t.from=function(e,n,r){return new t(e,n,r)},t.uboFrom=function(e,n){return new t(e,null===n||void 0===n||n,!0)},t}(),J=function(){function t(){this.renderTexture=null,this.target=null,this.legacy=!1,this.resolution=1,this.multisample=i.G5.NONE,this.sourceFrame=new u.Ae,this.destinationFrame=new u.Ae,this.bindingSourceFrame=new u.Ae,this.bindingDestinationFrame=new u.Ae,this.filters=[],this.transform=null}return t.prototype.clear=function(){this.target=null,this.filters=null,this.renderTexture=null},t}(),Q=[new u.E9,new u.E9,new u.E9,new u.E9],tt=new u.y3,et=function(){function t(t){this.renderer=t,this.defaultFilterStack=[{}],this.texturePool=new U,this.texturePool.setScreenSize(t.view),this.statePool=[],this.quad=new $,this.quadUv=new q,this.tempRect=new u.Ae,this.activeState={},this.globalUniforms=new Z({outputFrame:new u.Ae,inputSize:new Float32Array(4),inputPixel:new Float32Array(4),inputClamp:new Float32Array(4),resolution:1,filterArea:new Float32Array(4),filterClamp:new Float32Array(4)},!0),this.forceClear=!1,this.useMaxPadding=!1}return t.prototype.push=function(t,e){for(var n,r,i=this.renderer,o=this.defaultFilterStack,s=this.statePool.pop()||new J,a=this.renderer.renderTexture,u=e[0].resolution,l=e[0].multisample,c=e[0].padding,h=e[0].autoFit,f=null===(n=e[0].legacy)||void 0===n||n,d=1;d<e.length;d++){var p=e[d];u=Math.min(u,p.resolution),l=Math.min(l,p.multisample),c=this.useMaxPadding?Math.max(c,p.padding):c+p.padding,h=h&&p.autoFit,f=f||null===(r=p.legacy)||void 0===r||r}if(1===o.length&&(this.defaultFilterStack[0].renderTexture=a.current),o.push(s),s.resolution=u,s.multisample=l,s.legacy=f,s.target=t,s.sourceFrame.copyFrom(t.filterArea||t.getBounds(!0)),s.sourceFrame.pad(c),h){var v=this.tempRect.copyFrom(a.sourceFrame);i.projection.transform&&this.transformAABB(tt.copyFrom(i.projection.transform).invert(),v),s.sourceFrame.fit(v)}this.roundFrame(s.sourceFrame,a.current?a.current.resolution:i.resolution,a.sourceFrame,a.destinationFrame,i.projection.transform),s.renderTexture=this.getOptimalFilterTexture(s.sourceFrame.width,s.sourceFrame.height,u,l),s.filters=e,s.destinationFrame.width=s.renderTexture.width,s.destinationFrame.height=s.renderTexture.height;var m=this.tempRect;m.x=0,m.y=0,m.width=s.sourceFrame.width,m.height=s.sourceFrame.height,s.renderTexture.filterFrame=s.sourceFrame,s.bindingSourceFrame.copyFrom(a.sourceFrame),s.bindingDestinationFrame.copyFrom(a.destinationFrame),s.transform=i.projection.transform,i.projection.transform=null,a.bind(s.renderTexture,s.sourceFrame,m),i.framebuffer.clear(0,0,0,0)},t.prototype.pop=function(){var t=this.defaultFilterStack,e=t.pop(),n=e.filters;this.activeState=e;var r=this.globalUniforms.uniforms;r.outputFrame=e.sourceFrame,r.resolution=e.resolution;var o=r.inputSize,s=r.inputPixel,a=r.inputClamp;if(o[0]=e.destinationFrame.width,o[1]=e.destinationFrame.height,o[2]=1/o[0],o[3]=1/o[1],s[0]=Math.round(o[0]*e.resolution),s[1]=Math.round(o[1]*e.resolution),s[2]=1/s[0],s[3]=1/s[1],a[0]=.5*s[2],a[1]=.5*s[3],a[2]=e.sourceFrame.width*o[2]-.5*s[2],a[3]=e.sourceFrame.height*o[3]-.5*s[3],e.legacy){var u=r.filterArea;u[0]=e.destinationFrame.width,u[1]=e.destinationFrame.height,u[2]=e.sourceFrame.x,u[3]=e.sourceFrame.y,r.filterClamp=r.inputClamp}this.globalUniforms.update();var l=t[t.length-1];if(this.renderer.framebuffer.blit(),1===n.length)n[0].apply(this,e.renderTexture,l.renderTexture,i.yl.BLEND,e),this.returnFilterTexture(e.renderTexture);else{var c=e.renderTexture,h=this.getOptimalFilterTexture(c.width,c.height,e.resolution);h.filterFrame=c.filterFrame;var f=0;for(f=0;f<n.length-1;++f){1===f&&e.multisample>1&&(h=this.getOptimalFilterTexture(c.width,c.height,e.resolution),h.filterFrame=c.filterFrame),n[f].apply(this,c,h,i.yl.CLEAR,e);var d=c;c=h,h=d}n[f].apply(this,c,l.renderTexture,i.yl.BLEND,e),f>1&&e.multisample>1&&this.returnFilterTexture(e.renderTexture),this.returnFilterTexture(c),this.returnFilterTexture(h)}e.clear(),this.statePool.push(e)},t.prototype.bindAndClear=function(t,e){void 0===e&&(e=i.yl.CLEAR);var n=this.renderer,r=n.renderTexture,o=n.state;if(t===this.defaultFilterStack[this.defaultFilterStack.length-1].renderTexture?this.renderer.projection.transform=this.activeState.transform:this.renderer.projection.transform=null,t&&t.filterFrame){var s=this.tempRect;s.x=0,s.y=0,s.width=t.filterFrame.width,s.height=t.filterFrame.height,r.bind(t,t.filterFrame,s)}else t!==this.defaultFilterStack[this.defaultFilterStack.length-1].renderTexture?r.bind(t):this.renderer.renderTexture.bind(t,this.activeState.bindingSourceFrame,this.activeState.bindingDestinationFrame);var a=1&o.stateId||this.forceClear;(e===i.yl.CLEAR||e===i.yl.BLIT&&a)&&this.renderer.framebuffer.clear(0,0,0,0)},t.prototype.applyFilter=function(t,e,n,r){var o=this.renderer;o.state.set(t.state),this.bindAndClear(n,r),t.uniforms.uSampler=e,t.uniforms.filterGlobals=this.globalUniforms,o.shader.bind(t),t.legacy=!!t.program.attributeData.aTextureCoord,t.legacy?(this.quadUv.map(e._frame,e.filterFrame),o.geometry.bind(this.quadUv),o.geometry.draw(i.lg.TRIANGLES)):(o.geometry.bind(this.quad),o.geometry.draw(i.lg.TRIANGLE_STRIP))},t.prototype.calculateSpriteMatrix=function(t,e){var n=this.activeState,r=n.sourceFrame,i=n.destinationFrame,o=e._texture.orig,s=t.set(i.width,0,0,i.height,r.x,r.y),a=e.worldTransform.copyTo(u.y3.TEMP_MATRIX);return a.invert(),s.prepend(a),s.scale(1/o.width,1/o.height),s.translate(e.anchor.x,e.anchor.y),s},t.prototype.destroy=function(){this.renderer=null,this.texturePool.clear(!1)},t.prototype.getOptimalFilterTexture=function(t,e,n,r){return void 0===n&&(n=1),void 0===r&&(r=i.G5.NONE),this.texturePool.getOptimalTexture(t,e,n,r)},t.prototype.getFilterTexture=function(t,e,n){if("number"===typeof t){var r=t;t=e,e=r}t=t||this.activeState.renderTexture;var o=this.texturePool.getOptimalTexture(t.width,t.height,e||t.resolution,n||i.G5.NONE);return o.filterFrame=t.filterFrame,o},t.prototype.returnFilterTexture=function(t){this.texturePool.returnTexture(t)},t.prototype.emptyPool=function(){this.texturePool.clear(!0)},t.prototype.resize=function(){this.texturePool.setScreenSize(this.renderer.view)},t.prototype.transformAABB=function(t,e){var n=Q[0],r=Q[1],i=Q[2],o=Q[3];n.set(e.left,e.top),r.set(e.left,e.bottom),i.set(e.right,e.top),o.set(e.right,e.bottom),t.apply(n,n),t.apply(r,r),t.apply(i,i),t.apply(o,o);var s=Math.min(n.x,r.x,i.x,o.x),a=Math.min(n.y,r.y,i.y,o.y),u=Math.max(n.x,r.x,i.x,o.x),l=Math.max(n.y,r.y,i.y,o.y);e.x=s,e.y=a,e.width=u-s,e.height=l-a},t.prototype.roundFrame=function(t,e,n,r,i){if(!(t.width<=0||t.height<=0||n.width<=0||n.height<=0)){if(i){var o=i.a,s=i.b,a=i.c,u=i.d;if((Math.abs(s)>1e-4||Math.abs(a)>1e-4)&&(Math.abs(o)>1e-4||Math.abs(u)>1e-4))return}i=i?tt.copyFrom(i):tt.identity(),i.translate(-n.x,-n.y).scale(r.width/n.width,r.height/n.height).translate(r.x,r.y),this.transformAABB(i,t),t.ceil(e),this.transformAABB(i.invert(),t)}},t}(),nt=function(){function t(t){this.renderer=t}return t.prototype.flush=function(){},t.prototype.destroy=function(){this.renderer=null},t.prototype.start=function(){},t.prototype.stop=function(){this.flush()},t.prototype.render=function(t){},t}(),rt=function(){function t(t){this.renderer=t,this.emptyRenderer=new nt(t),this.currentRenderer=this.emptyRenderer}return t.prototype.setObjectRenderer=function(t){this.currentRenderer!==t&&(this.currentRenderer.stop(),this.currentRenderer=t,this.currentRenderer.start())},t.prototype.flush=function(){this.setObjectRenderer(this.emptyRenderer)},t.prototype.reset=function(){this.setObjectRenderer(this.emptyRenderer)},t.prototype.copyBoundTextures=function(t,e){for(var n=this.renderer.texture.boundTextures,r=e-1;r>=0;--r)t[r]=n[r]||null,t[r]&&(t[r]._batchLocation=r)},t.prototype.boundArray=function(t,e,n,r){for(var i=t.elements,o=t.ids,s=t.count,a=0,u=0;u<s;u++){var l=i[u],c=l._batchLocation;if(c>=0&&c<r&&e[c]===l)o[u]=c;else while(a<r){var h=e[a];if(!h||h._batchEnabled!==n||h._batchLocation!==a){o[u]=a,l._batchLocation=a,e[a]=l;break}a++}}},t.prototype.destroy=function(){this.renderer=null},t}(),it=0,ot=function(){function t(t){this.renderer=t,this.webGLVersion=1,this.extensions={},this.supports={uint32Indices:!1},this.handleContextLost=this.handleContextLost.bind(this),this.handleContextRestored=this.handleContextRestored.bind(this),t.view.addEventListener("webglcontextlost",this.handleContextLost,!1),t.view.addEventListener("webglcontextrestored",this.handleContextRestored,!1)}return Object.defineProperty(t.prototype,"isLost",{get:function(){return!this.gl||this.gl.isContextLost()},enumerable:!1,configurable:!0}),t.prototype.contextChange=function(t){this.gl=t,this.renderer.gl=t,this.renderer.CONTEXT_UID=it++,t.isContextLost()&&t.getExtension("WEBGL_lose_context")&&t.getExtension("WEBGL_lose_context").restoreContext()},t.prototype.initFromContext=function(t){this.gl=t,this.validateContext(t),this.renderer.gl=t,this.renderer.CONTEXT_UID=it++,this.renderer.runners.contextChange.emit(t)},t.prototype.initFromOptions=function(t){var e=this.createContext(this.renderer.view,t);this.initFromContext(e)},t.prototype.createContext=function(t,e){var n;if(r.X.PREFER_ENV>=i.Vi.WEBGL2&&(n=t.getContext("webgl2",e)),n)this.webGLVersion=2;else if(this.webGLVersion=1,n=t.getContext("webgl",e)||t.getContext("experimental-webgl",e),!n)throw new Error("This browser does not support WebGL. Try using the canvas renderer");return this.gl=n,this.getExtensions(),this.gl},t.prototype.getExtensions=function(){var t=this.gl,e={anisotropicFiltering:t.getExtension("EXT_texture_filter_anisotropic"),floatTextureLinear:t.getExtension("OES_texture_float_linear"),s3tc:t.getExtension("WEBGL_compressed_texture_s3tc"),s3tc_sRGB:t.getExtension("WEBGL_compressed_texture_s3tc_srgb"),etc:t.getExtension("WEBGL_compressed_texture_etc"),etc1:t.getExtension("WEBGL_compressed_texture_etc1"),pvrtc:t.getExtension("WEBGL_compressed_texture_pvrtc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc"),atc:t.getExtension("WEBGL_compressed_texture_atc"),astc:t.getExtension("WEBGL_compressed_texture_astc")};1===this.webGLVersion?Object.assign(this.extensions,e,{drawBuffers:t.getExtension("WEBGL_draw_buffers"),depthTexture:t.getExtension("WEBGL_depth_texture"),loseContext:t.getExtension("WEBGL_lose_context"),vertexArrayObject:t.getExtension("OES_vertex_array_object")||t.getExtension("MOZ_OES_vertex_array_object")||t.getExtension("WEBKIT_OES_vertex_array_object"),uint32ElementIndex:t.getExtension("OES_element_index_uint"),floatTexture:t.getExtension("OES_texture_float"),floatTextureLinear:t.getExtension("OES_texture_float_linear"),textureHalfFloat:t.getExtension("OES_texture_half_float"),textureHalfFloatLinear:t.getExtension("OES_texture_half_float_linear")}):2===this.webGLVersion&&Object.assign(this.extensions,e,{colorBufferFloat:t.getExtension("EXT_color_buffer_float")})},t.prototype.handleContextLost=function(t){t.preventDefault()},t.prototype.handleContextRestored=function(){this.renderer.runners.contextChange.emit(this.gl)},t.prototype.destroy=function(){var t=this.renderer.view;this.renderer=null,t.removeEventListener("webglcontextlost",this.handleContextLost),t.removeEventListener("webglcontextrestored",this.handleContextRestored),this.gl.useProgram(null),this.extensions.loseContext&&this.extensions.loseContext.loseContext()},t.prototype.postrender=function(){this.renderer.renderingToScreen&&this.gl.flush()},t.prototype.validateContext=function(t){var e=t.getContextAttributes(),n="WebGL2RenderingContext"in globalThis&&t instanceof globalThis.WebGL2RenderingContext;n&&(this.webGLVersion=2),e.stencil||console.warn("Provided WebGL context does not have a stencil buffer, masks may not render correctly");var r=n||!!t.getExtension("OES_element_index_uint");this.supports.uint32Indices=r,r||console.warn("Provided WebGL context does not support 32 index buffer, complex graphics may not render correctly")},t}(),st=function(){function t(t){this.framebuffer=t,this.stencil=null,this.dirtyId=-1,this.dirtyFormat=-1,this.dirtySize=-1,this.multisample=i.G5.NONE,this.msaaBuffer=null,this.blitFramebuffer=null,this.mipLevel=0}return t}(),at=new u.Ae,ut=function(){function t(t){this.renderer=t,this.managedFramebuffers=[],this.unknownFramebuffer=new P(10,10),this.msaaSamples=null}return t.prototype.contextChange=function(){var t=this.gl=this.renderer.gl;if(this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.current=this.unknownFramebuffer,this.viewport=new u.Ae,this.hasMRT=!0,this.writeDepthTexture=!0,this.disposeAll(!0),1===this.renderer.context.webGLVersion){var e=this.renderer.context.extensions.drawBuffers,n=this.renderer.context.extensions.depthTexture;r.X.PREFER_ENV===i.Vi.WEBGL_LEGACY&&(e=null,n=null),e?t.drawBuffers=function(t){return e.drawBuffersWEBGL(t)}:(this.hasMRT=!1,t.drawBuffers=function(){}),n||(this.writeDepthTexture=!1)}else this.msaaSamples=t.getInternalformatParameter(t.RENDERBUFFER,t.RGBA8,t.SAMPLES)},t.prototype.bind=function(t,e,n){void 0===n&&(n=0);var r=this.gl;if(t){var i=t.glFramebuffers[this.CONTEXT_UID]||this.initFramebuffer(t);this.current!==t&&(this.current=t,r.bindFramebuffer(r.FRAMEBUFFER,i.framebuffer)),i.mipLevel!==n&&(t.dirtyId++,t.dirtyFormat++,i.mipLevel=n),i.dirtyId!==t.dirtyId&&(i.dirtyId=t.dirtyId,i.dirtyFormat!==t.dirtyFormat?(i.dirtyFormat=t.dirtyFormat,i.dirtySize=t.dirtySize,this.updateFramebuffer(t,n)):i.dirtySize!==t.dirtySize&&(i.dirtySize=t.dirtySize,this.resizeFramebuffer(t)));for(var o=0;o<t.colorTextures.length;o++){var s=t.colorTextures[o];this.renderer.texture.unbind(s.parentTextureArray||s)}if(t.depthTexture&&this.renderer.texture.unbind(t.depthTexture),e){var a=e.width>>n,u=e.height>>n,l=a/e.width;this.setViewport(e.x*l,e.y*l,a,u)}else{a=t.width>>n,u=t.height>>n;this.setViewport(0,0,a,u)}}else this.current&&(this.current=null,r.bindFramebuffer(r.FRAMEBUFFER,null)),e?this.setViewport(e.x,e.y,e.width,e.height):this.setViewport(0,0,this.renderer.width,this.renderer.height)},t.prototype.setViewport=function(t,e,n,r){var i=this.viewport;t=Math.round(t),e=Math.round(e),n=Math.round(n),r=Math.round(r),i.width===n&&i.height===r&&i.x===t&&i.y===e||(i.x=t,i.y=e,i.width=n,i.height=r,this.gl.viewport(t,e,n,r))},Object.defineProperty(t.prototype,"size",{get:function(){return this.current?{x:0,y:0,width:this.current.width,height:this.current.height}:{x:0,y:0,width:this.renderer.width,height:this.renderer.height}},enumerable:!1,configurable:!0}),t.prototype.clear=function(t,e,n,r,o){void 0===o&&(o=i.V0.COLOR|i.V0.DEPTH);var s=this.gl;s.clearColor(t,e,n,r),s.clear(o)},t.prototype.initFramebuffer=function(t){var e=this.gl,n=new st(e.createFramebuffer());return n.multisample=this.detectSamples(t.multisample),t.glFramebuffers[this.CONTEXT_UID]=n,this.managedFramebuffers.push(t),t.disposeRunner.add(this),n},t.prototype.resizeFramebuffer=function(t){var e=this.gl,n=t.glFramebuffers[this.CONTEXT_UID];n.msaaBuffer&&(e.bindRenderbuffer(e.RENDERBUFFER,n.msaaBuffer),e.renderbufferStorageMultisample(e.RENDERBUFFER,n.multisample,e.RGBA8,t.width,t.height)),n.stencil&&(e.bindRenderbuffer(e.RENDERBUFFER,n.stencil),n.msaaBuffer?e.renderbufferStorageMultisample(e.RENDERBUFFER,n.multisample,e.DEPTH24_STENCIL8,t.width,t.height):e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_STENCIL,t.width,t.height));var r=t.colorTextures,i=r.length;e.drawBuffers||(i=Math.min(i,1));for(var o=0;o<i;o++){var s=r[o],a=s.parentTextureArray||s;this.renderer.texture.bind(a,0)}t.depthTexture&&this.writeDepthTexture&&this.renderer.texture.bind(t.depthTexture,0)},t.prototype.updateFramebuffer=function(t,e){var n=this.gl,r=t.glFramebuffers[this.CONTEXT_UID],i=t.colorTextures,o=i.length;n.drawBuffers||(o=Math.min(o,1)),r.multisample>1&&this.canMultisampleFramebuffer(t)?(r.msaaBuffer=r.msaaBuffer||n.createRenderbuffer(),n.bindRenderbuffer(n.RENDERBUFFER,r.msaaBuffer),n.renderbufferStorageMultisample(n.RENDERBUFFER,r.multisample,n.RGBA8,t.width,t.height),n.framebufferRenderbuffer(n.FRAMEBUFFER,n.COLOR_ATTACHMENT0,n.RENDERBUFFER,r.msaaBuffer)):r.msaaBuffer&&(n.deleteRenderbuffer(r.msaaBuffer),r.msaaBuffer=null,r.blitFramebuffer&&(r.blitFramebuffer.dispose(),r.blitFramebuffer=null));for(var s=[],a=0;a<o;a++){var u=i[a],l=u.parentTextureArray||u;this.renderer.texture.bind(l,0),0===a&&r.msaaBuffer||(n.framebufferTexture2D(n.FRAMEBUFFER,n.COLOR_ATTACHMENT0+a,u.target,l._glTextures[this.CONTEXT_UID].texture,e),s.push(n.COLOR_ATTACHMENT0+a))}if(s.length>1&&n.drawBuffers(s),t.depthTexture){var c=this.writeDepthTexture;if(c){var h=t.depthTexture;this.renderer.texture.bind(h,0),n.framebufferTexture2D(n.FRAMEBUFFER,n.DEPTH_ATTACHMENT,n.TEXTURE_2D,h._glTextures[this.CONTEXT_UID].texture,e)}}!t.stencil&&!t.depth||t.depthTexture&&this.writeDepthTexture?r.stencil&&(n.deleteRenderbuffer(r.stencil),r.stencil=null):(r.stencil=r.stencil||n.createRenderbuffer(),n.bindRenderbuffer(n.RENDERBUFFER,r.stencil),r.msaaBuffer?n.renderbufferStorageMultisample(n.RENDERBUFFER,r.multisample,n.DEPTH24_STENCIL8,t.width,t.height):n.renderbufferStorage(n.RENDERBUFFER,n.DEPTH_STENCIL,t.width,t.height),n.framebufferRenderbuffer(n.FRAMEBUFFER,n.DEPTH_STENCIL_ATTACHMENT,n.RENDERBUFFER,r.stencil))},t.prototype.canMultisampleFramebuffer=function(t){return 1!==this.renderer.context.webGLVersion&&t.colorTextures.length<=1&&!t.depthTexture},t.prototype.detectSamples=function(t){var e=this.msaaSamples,n=i.G5.NONE;if(t<=1||null===e)return n;for(var r=0;r<e.length;r++)if(e[r]<=t){n=e[r];break}return 1===n&&(n=i.G5.NONE),n},t.prototype.blit=function(t,e,n){var r=this,i=r.current,o=r.renderer,s=r.gl,a=r.CONTEXT_UID;if(2===o.context.webGLVersion&&i){var u=i.glFramebuffers[a];if(u){if(!t){if(!u.msaaBuffer)return;var l=i.colorTextures[0];if(!l)return;u.blitFramebuffer||(u.blitFramebuffer=new P(i.width,i.height),u.blitFramebuffer.addColorTexture(0,l)),t=u.blitFramebuffer,t.colorTextures[0]!==l&&(t.colorTextures[0]=l,t.dirtyId++,t.dirtyFormat++),t.width===i.width&&t.height===i.height||(t.width=i.width,t.height=i.height,t.dirtyId++,t.dirtySize++)}e||(e=at,e.width=i.width,e.height=i.height),n||(n=e);var c=e.width===n.width&&e.height===n.height;this.bind(t),s.bindFramebuffer(s.READ_FRAMEBUFFER,u.framebuffer),s.blitFramebuffer(e.left,e.top,e.right,e.bottom,n.left,n.top,n.right,n.bottom,s.COLOR_BUFFER_BIT,c?s.NEAREST:s.LINEAR)}}},t.prototype.disposeFramebuffer=function(t,e){var n=t.glFramebuffers[this.CONTEXT_UID],r=this.gl;if(n){delete t.glFramebuffers[this.CONTEXT_UID];var i=this.managedFramebuffers.indexOf(t);i>=0&&this.managedFramebuffers.splice(i,1),t.disposeRunner.remove(this),e||(r.deleteFramebuffer(n.framebuffer),n.msaaBuffer&&r.deleteRenderbuffer(n.msaaBuffer),n.stencil&&r.deleteRenderbuffer(n.stencil)),n.blitFramebuffer&&n.blitFramebuffer.dispose()}},t.prototype.disposeAll=function(t){var e=this.managedFramebuffers;this.managedFramebuffers=[];for(var n=0;n<e.length;n++)this.disposeFramebuffer(e[n],t)},t.prototype.forceStencil=function(){var t=this.current;if(t){var e=t.glFramebuffers[this.CONTEXT_UID];if(e&&!e.stencil){t.stencil=!0;var n=t.width,r=t.height,i=this.gl,o=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,o),e.msaaBuffer?i.renderbufferStorageMultisample(i.RENDERBUFFER,e.multisample,i.DEPTH24_STENCIL8,n,r):i.renderbufferStorage(i.RENDERBUFFER,i.DEPTH_STENCIL,n,r),e.stencil=o,i.framebufferRenderbuffer(i.FRAMEBUFFER,i.DEPTH_STENCIL_ATTACHMENT,i.RENDERBUFFER,o)}}},t.prototype.reset=function(){this.current=this.unknownFramebuffer,this.viewport=new u.Ae},t.prototype.destroy=function(){this.renderer=null},t}(),lt={5126:4,5123:2,5121:1},ct=function(){function t(t){this.renderer=t,this._activeGeometry=null,this._activeVao=null,this.hasVao=!0,this.hasInstance=!0,this.canUseUInt32ElementIndex=!1,this.managedGeometries={}}return t.prototype.contextChange=function(){this.disposeAll(!0);var t=this.gl=this.renderer.gl,e=this.renderer.context;if(this.CONTEXT_UID=this.renderer.CONTEXT_UID,2!==e.webGLVersion){var n=this.renderer.context.extensions.vertexArrayObject;r.X.PREFER_ENV===i.Vi.WEBGL_LEGACY&&(n=null),n?(t.createVertexArray=function(){return n.createVertexArrayOES()},t.bindVertexArray=function(t){return n.bindVertexArrayOES(t)},t.deleteVertexArray=function(t){return n.deleteVertexArrayOES(t)}):(this.hasVao=!1,t.createVertexArray=function(){return null},t.bindVertexArray=function(){return null},t.deleteVertexArray=function(){return null})}if(2!==e.webGLVersion){var o=t.getExtension("ANGLE_instanced_arrays");o?(t.vertexAttribDivisor=function(t,e){return o.vertexAttribDivisorANGLE(t,e)},t.drawElementsInstanced=function(t,e,n,r,i){return o.drawElementsInstancedANGLE(t,e,n,r,i)},t.drawArraysInstanced=function(t,e,n,r){return o.drawArraysInstancedANGLE(t,e,n,r)}):this.hasInstance=!1}this.canUseUInt32ElementIndex=2===e.webGLVersion||!!e.extensions.uint32ElementIndex},t.prototype.bind=function(t,e){e=e||this.renderer.shader.shader;var n=this.gl,r=t.glVertexArrayObjects[this.CONTEXT_UID],i=!1;r||(this.managedGeometries[t.id]=t,t.disposeRunner.add(this),t.glVertexArrayObjects[this.CONTEXT_UID]=r={},i=!0);var o=r[e.program.id]||this.initGeometryVao(t,e,i);this._activeGeometry=t,this._activeVao!==o&&(this._activeVao=o,this.hasVao?n.bindVertexArray(o):this.activateVao(t,e.program)),this.updateBuffers()},t.prototype.reset=function(){this.unbind()},t.prototype.updateBuffers=function(){for(var t=this._activeGeometry,e=this.renderer.buffer,n=0;n<t.buffers.length;n++){var r=t.buffers[n];e.update(r)}},t.prototype.checkCompatibility=function(t,e){var n=t.attributes,r=e.attributeData;for(var i in r)if(!n[i])throw new Error('shader and geometry incompatible, geometry missing the "'+i+'" attribute')},t.prototype.getSignature=function(t,e){var n=t.attributes,r=e.attributeData,i=["g",t.id];for(var o in n)r[o]&&i.push(o,r[o].location);return i.join("-")},t.prototype.initGeometryVao=function(t,e,n){void 0===n&&(n=!0);var r=this.gl,i=this.CONTEXT_UID,o=this.renderer.buffer,s=e.program;s.glPrograms[i]||this.renderer.shader.generateProgram(e),this.checkCompatibility(t,s);var a=this.getSignature(t,s),u=t.glVertexArrayObjects[this.CONTEXT_UID],l=u[a];if(l)return u[s.id]=l,l;var c=t.buffers,h=t.attributes,f={},d={};for(var p in c)f[p]=0,d[p]=0;for(var p in h)!h[p].size&&s.attributeData[p]?h[p].size=s.attributeData[p].size:h[p].size||console.warn("PIXI Geometry attribute '"+p+"' size cannot be determined (likely the bound shader does not have the attribute)"),f[h[p].buffer]+=h[p].size*lt[h[p].type];for(var p in h){var v=h[p],m=v.size;void 0===v.stride&&(f[v.buffer]===m*lt[v.type]?v.stride=0:v.stride=f[v.buffer]),void 0===v.start&&(v.start=d[v.buffer],d[v.buffer]+=m*lt[v.type])}l=r.createVertexArray(),r.bindVertexArray(l);for(var g=0;g<c.length;g++){var _=c[g];o.bind(_),n&&_._glBuffers[i].refCount++}return this.activateVao(t,s),this._activeVao=l,u[s.id]=l,u[a]=l,l},t.prototype.disposeGeometry=function(t,e){var n;if(this.managedGeometries[t.id]){delete this.managedGeometries[t.id];var r=t.glVertexArrayObjects[this.CONTEXT_UID],i=this.gl,o=t.buffers,s=null===(n=this.renderer)||void 0===n?void 0:n.buffer;if(t.disposeRunner.remove(this),r){if(s)for(var a=0;a<o.length;a++){var u=o[a]._glBuffers[this.CONTEXT_UID];u&&(u.refCount--,0!==u.refCount||e||s.dispose(o[a],e))}if(!e)for(var l in r)if("g"===l[0]){var c=r[l];this._activeVao===c&&this.unbind(),i.deleteVertexArray(c)}delete t.glVertexArrayObjects[this.CONTEXT_UID]}}},t.prototype.disposeAll=function(t){for(var e=Object.keys(this.managedGeometries),n=0;n<e.length;n++)this.disposeGeometry(this.managedGeometries[e[n]],t)},t.prototype.activateVao=function(t,e){var n=this.gl,r=this.CONTEXT_UID,i=this.renderer.buffer,o=t.buffers,s=t.attributes;t.indexBuffer&&i.bind(t.indexBuffer);var a=null;for(var u in s){var l=s[u],c=o[l.buffer],h=c._glBuffers[r];if(e.attributeData[u]){a!==h&&(i.bind(c),a=h);var f=e.attributeData[u].location;if(n.enableVertexAttribArray(f),n.vertexAttribPointer(f,l.size,l.type||n.FLOAT,l.normalized,l.stride,l.start),l.instance){if(!this.hasInstance)throw new Error("geometry error, GPU Instancing is not supported on this device");n.vertexAttribDivisor(f,1)}}}},t.prototype.draw=function(t,e,n,r){var i=this.gl,o=this._activeGeometry;if(o.indexBuffer){var s=o.indexBuffer.data.BYTES_PER_ELEMENT,a=2===s?i.UNSIGNED_SHORT:i.UNSIGNED_INT;2===s||4===s&&this.canUseUInt32ElementIndex?o.instanced?i.drawElementsInstanced(t,e||o.indexBuffer.data.length,a,(n||0)*s,r||1):i.drawElements(t,e||o.indexBuffer.data.length,a,(n||0)*s):console.warn("unsupported index buffer type: uint32")}else o.instanced?i.drawArraysInstanced(t,n,e||o.getSize(),r||1):i.drawArrays(t,n,e||o.getSize());return this},t.prototype.unbind=function(){this.gl.bindVertexArray(null),this._activeVao=null,this._activeGeometry=null},t.prototype.destroy=function(){this.renderer=null},t}(),ht=function(){function t(t){void 0===t&&(t=null),this.type=i.A7.NONE,this.autoDetect=!0,this.maskObject=t||null,this.pooled=!1,this.isMaskData=!0,this.resolution=null,this.multisample=r.X.FILTER_MULTISAMPLE,this.enabled=!0,this._filters=null,this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null,this._scissorRectLocal=null,this._target=null}return Object.defineProperty(t.prototype,"filter",{get:function(){return this._filters?this._filters[0]:null},set:function(t){t?this._filters?this._filters[0]=t:this._filters=[t]:this._filters=null},enumerable:!1,configurable:!0}),t.prototype.reset=function(){this.pooled&&(this.maskObject=null,this.type=i.A7.NONE,this.autoDetect=!0),this._target=null,this._scissorRectLocal=null},t.prototype.copyCountersOrReset=function(t){t?(this._stencilCounter=t._stencilCounter,this._scissorCounter=t._scissorCounter,this._scissorRect=t._scissorRect):(this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null)},t}();function ft(t,e,n){var r=t.createShader(e);return t.shaderSource(r,n),t.compileShader(r),r}function dt(t,e){var n=t.getShaderSource(e).split("\n").map((function(t,e){return e+": "+t})),r=t.getShaderInfoLog(e),i=r.split("\n"),o={},s=i.map((function(t){return parseFloat(t.replace(/^ERROR\: 0\:([\d]+)\:.*$/,"$1"))})).filter((function(t){return!(!t||o[t])&&(o[t]=!0,!0)})),a=[""];s.forEach((function(t){n[t-1]="%c"+n[t-1]+"%c",a.push("background: #FF0000; color:#FFFFFF; font-size: 10px","font-size: 10px")}));var u=n.join("\n");a[0]=u,console.error(r),console.groupCollapsed("click to view full shader code"),console.warn.apply(console,a),console.groupEnd()}function pt(t,e,n,r){t.getProgramParameter(e,t.LINK_STATUS)||(t.getShaderParameter(n,t.COMPILE_STATUS)||dt(t,n),t.getShaderParameter(r,t.COMPILE_STATUS)||dt(t,r),console.error("PixiJS Error: Could not initialize shader."),""!==t.getProgramInfoLog(e)&&console.warn("PixiJS Warning: gl.getProgramInfoLog()",t.getProgramInfoLog(e)))}function vt(t){for(var e=new Array(t),n=0;n<e.length;n++)e[n]=!1;return e}function mt(t,e){switch(t){case"float":return 0;case"vec2":return new Float32Array(2*e);case"vec3":return new Float32Array(3*e);case"vec4":return new Float32Array(4*e);case"int":case"uint":case"sampler2D":case"sampler2DArray":return 0;case"ivec2":return new Int32Array(2*e);case"ivec3":return new Int32Array(3*e);case"ivec4":return new Int32Array(4*e);case"uvec2":return new Uint32Array(2*e);case"uvec3":return new Uint32Array(3*e);case"uvec4":return new Uint32Array(4*e);case"bool":return!1;case"bvec2":return vt(2*e);case"bvec3":return vt(3*e);case"bvec4":return vt(4*e);case"mat2":return new Float32Array([1,0,0,1]);case"mat3":return new Float32Array([1,0,0,0,1,0,0,0,1]);case"mat4":return new Float32Array([1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1])}return null}var gt,_t={},yt=_t;function bt(){if(yt===_t||yt&&yt.isContextLost()){var t=document.createElement("canvas"),e=void 0;r.X.PREFER_ENV>=i.Vi.WEBGL2&&(e=t.getContext("webgl2",{})),e||(e=t.getContext("webgl",{})||t.getContext("experimental-webgl",{}),e?e.getExtension("WEBGL_draw_buffers"):e=null),yt=e}return yt}function Et(){if(!gt){gt=i.cB.MEDIUM;var t=bt();if(t&&t.getShaderPrecisionFormat){var e=t.getShaderPrecisionFormat(t.FRAGMENT_SHADER,t.HIGH_FLOAT);gt=e.precision?i.cB.HIGH:i.cB.MEDIUM}}return gt}function xt(t,e,n){if("precision"!==t.substring(0,9)){var r=e;return e===i.cB.HIGH&&n!==i.cB.HIGH&&(r=i.cB.MEDIUM),"precision "+r+" float;\n"+t}return n!==i.cB.HIGH&&"precision highp"===t.substring(0,15)?t.replace("precision highp","precision mediump"):t}var Tt={float:1,vec2:2,vec3:3,vec4:4,int:1,ivec2:2,ivec3:3,ivec4:4,uint:1,uvec2:2,uvec3:3,uvec4:4,bool:1,bvec2:2,bvec3:3,bvec4:4,mat2:4,mat3:9,mat4:16,sampler2D:1};function St(t){return Tt[t]}var Rt=null,At={FLOAT:"float",FLOAT_VEC2:"vec2",FLOAT_VEC3:"vec3",FLOAT_VEC4:"vec4",INT:"int",INT_VEC2:"ivec2",INT_VEC3:"ivec3",INT_VEC4:"ivec4",UNSIGNED_INT:"uint",UNSIGNED_INT_VEC2:"uvec2",UNSIGNED_INT_VEC3:"uvec3",UNSIGNED_INT_VEC4:"uvec4",BOOL:"bool",BOOL_VEC2:"bvec2",BOOL_VEC3:"bvec3",BOOL_VEC4:"bvec4",FLOAT_MAT2:"mat2",FLOAT_MAT3:"mat3",FLOAT_MAT4:"mat4",SAMPLER_2D:"sampler2D",INT_SAMPLER_2D:"sampler2D",UNSIGNED_INT_SAMPLER_2D:"sampler2D",SAMPLER_CUBE:"samplerCube",INT_SAMPLER_CUBE:"samplerCube",UNSIGNED_INT_SAMPLER_CUBE:"samplerCube",SAMPLER_2D_ARRAY:"sampler2DArray",INT_SAMPLER_2D_ARRAY:"sampler2DArray",UNSIGNED_INT_SAMPLER_2D_ARRAY:"sampler2DArray"};function Ot(t,e){if(!Rt){var n=Object.keys(At);Rt={};for(var r=0;r<n.length;++r){var i=n[r];Rt[t[i]]=At[i]}}return Rt[e]}var wt=[{test:function(t){return"float"===t.type&&1===t.size},code:function(t){return'\n if(uv["'+t+'"] !== ud["'+t+'"].value)\n {\n ud["'+t+'"].value = uv["'+t+'"]\n gl.uniform1f(ud["'+t+'"].location, uv["'+t+'"])\n }\n '}},{test:function(t){return("sampler2D"===t.type||"samplerCube"===t.type||"sampler2DArray"===t.type)&&1===t.size&&!t.isArray},code:function(t){return't = syncData.textureCount++;\n\n renderer.texture.bind(uv["'+t+'"], t);\n\n if(ud["'+t+'"].value !== t)\n {\n ud["'+t+'"].value = t;\n gl.uniform1i(ud["'+t+'"].location, t);\n; // eslint-disable-line max-len\n }'}},{test:function(t,e){return"mat3"===t.type&&1===t.size&&void 0!==e.a},code:function(t){return'\n gl.uniformMatrix3fv(ud["'+t+'"].location, false, uv["'+t+'"].toArray(true));\n '},codeUbo:function(t){return"\n var "+t+"_matrix = uv."+t+".toArray(true);\n\n data[offset] = "+t+"_matrix[0];\n data[offset+1] = "+t+"_matrix[1];\n data[offset+2] = "+t+"_matrix[2];\n \n data[offset + 4] = "+t+"_matrix[3];\n data[offset + 5] = "+t+"_matrix[4];\n data[offset + 6] = "+t+"_matrix[5];\n \n data[offset + 8] = "+t+"_matrix[6];\n data[offset + 9] = "+t+"_matrix[7];\n data[offset + 10] = "+t+"_matrix[8];\n "}},{test:function(t,e){return"vec2"===t.type&&1===t.size&&void 0!==e.x},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v.x || cv[1] !== v.y)\n {\n cv[0] = v.x;\n cv[1] = v.y;\n gl.uniform2f(ud["'+t+'"].location, v.x, v.y);\n }'},codeUbo:function(t){return"\n v = uv."+t+";\n\n data[offset] = v.x;\n data[offset+1] = v.y;\n "}},{test:function(t){return"vec2"===t.type&&1===t.size},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n gl.uniform2f(ud["'+t+'"].location, v[0], v[1]);\n }\n '}},{test:function(t,e){return"vec4"===t.type&&1===t.size&&void 0!==e.width},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v.x || cv[1] !== v.y || cv[2] !== v.width || cv[3] !== v.height)\n {\n cv[0] = v.x;\n cv[1] = v.y;\n cv[2] = v.width;\n cv[3] = v.height;\n gl.uniform4f(ud["'+t+'"].location, v.x, v.y, v.width, v.height)\n }'},codeUbo:function(t){return"\n v = uv."+t+";\n\n data[offset] = v.x;\n data[offset+1] = v.y;\n data[offset+2] = v.width;\n data[offset+3] = v.height;\n "}},{test:function(t){return"vec4"===t.type&&1===t.size},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4f(ud["'+t+'"].location, v[0], v[1], v[2], v[3])\n }'}}],It={float:"\n if (cv !== v)\n {\n cu.value = v;\n gl.uniform1f(location, v);\n }",vec2:"\n if (cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2f(location, v[0], v[1])\n }",vec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3f(location, v[0], v[1], v[2])\n }",vec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4f(location, v[0], v[1], v[2], v[3]);\n }",int:"\n if (cv !== v)\n {\n cu.value = v;\n\n gl.uniform1i(location, v);\n }",ivec2:"\n if (cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2i(location, v[0], v[1]);\n }",ivec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3i(location, v[0], v[1], v[2]);\n }",ivec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\n }",uint:"\n if (cv !== v)\n {\n cu.value = v;\n\n gl.uniform1ui(location, v);\n }",uvec2:"\n if (cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2ui(location, v[0], v[1]);\n }",uvec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3ui(location, v[0], v[1], v[2]);\n }",uvec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4ui(location, v[0], v[1], v[2], v[3]);\n }",bool:"\n if (cv !== v)\n {\n cu.value = v;\n gl.uniform1i(location, v);\n }",bvec2:"\n if (cv[0] != v[0] || cv[1] != v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2i(location, v[0], v[1]);\n }",bvec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3i(location, v[0], v[1], v[2]);\n }",bvec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\n }",mat2:"gl.uniformMatrix2fv(location, false, v)",mat3:"gl.uniformMatrix3fv(location, false, v)",mat4:"gl.uniformMatrix4fv(location, false, v)",sampler2D:"gl.uniform1i(location, v)",samplerCube:"gl.uniform1i(location, v)",sampler2DArray:"gl.uniform1i(location, v)"},Pt={float:"gl.uniform1fv(location, v)",vec2:"gl.uniform2fv(location, v)",vec3:"gl.uniform3fv(location, v)",vec4:"gl.uniform4fv(location, v)",mat4:"gl.uniformMatrix4fv(location, false, v)",mat3:"gl.uniformMatrix3fv(location, false, v)",mat2:"gl.uniformMatrix2fv(location, false, v)",int:"gl.uniform1iv(location, v)",ivec2:"gl.uniform2iv(location, v)",ivec3:"gl.uniform3iv(location, v)",ivec4:"gl.uniform4iv(location, v)",uint:"gl.uniform1uiv(location, v)",uvec2:"gl.uniform2uiv(location, v)",uvec3:"gl.uniform3uiv(location, v)",uvec4:"gl.uniform4uiv(location, v)",bool:"gl.uniform1iv(location, v)",bvec2:"gl.uniform2iv(location, v)",bvec3:"gl.uniform3iv(location, v)",bvec4:"gl.uniform4iv(location, v)",sampler2D:"gl.uniform1iv(location, v)",samplerCube:"gl.uniform1iv(location, v)",sampler2DArray:"gl.uniform1iv(location, v)"};function Ct(t,e){var n,r=["\n var v = null;\n var cv = null;\n var cu = null;\n var t = 0;\n var gl = renderer.gl;\n "];for(var i in t.uniforms){var o=e[i];if(o){for(var s=t.uniforms[i],a=!1,u=0;u<wt.length;u++)if(wt[u].test(o,s)){r.push(wt[u].code(i,s)),a=!0;break}if(!a){var l=1===o.size?It:Pt,c=l[o.type].replace("location",'ud["'+i+'"].location');r.push('\n cu = ud["'+i+'"];\n cv = cu.value;\n v = uv["'+i+'"];\n '+c+";")}}else(null===(n=t.uniforms[i])||void 0===n?void 0:n.group)&&(t.uniforms[i].ubo?r.push("\n renderer.shader.syncUniformBufferGroup(uv."+i+", '"+i+"');\n "):r.push("\n renderer.shader.syncUniformGroup(uv."+i+", syncData);\n "))}return new Function("ud","uv","renderer","syncData",r.join("\n"))}var Nt,Mt=["precision mediump float;","void main(void){","float test = 0.1;","%forloop%","gl_FragColor = vec4(0.0);","}"].join("\n");function Dt(t){for(var e="",n=0;n<t;++n)n>0&&(e+="\nelse "),n<t-1&&(e+="if(test == "+n+".0){}");return e}function Lt(t,e){if(0===t)throw new Error("Invalid value of `0` passed to `checkMaxIfStatementsInShader`");var n=e.createShader(e.FRAGMENT_SHADER);while(1){var r=Mt.replace(/%forloop%/gi,Dt(t));if(e.shaderSource(n,r),e.compileShader(n),e.getShaderParameter(n,e.COMPILE_STATUS))break;t=t/2|0}return t}function Ft(){if("boolean"===typeof Nt)return Nt;try{var t=new Function("param1","param2","param3","return param1[param2] === param3;");Nt=!0===t({a:"b"},"a","b")}catch(e){Nt=!1}return Nt}var Bt="varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\n\nvoid main(void){\n gl_FragColor *= texture2D(uSampler, vTextureCoord);\n}",Ut="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void){\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}\n",Gt=0,kt={},Xt=function(){function t(e,n,o){void 0===o&&(o="pixi-shader"),this.id=Gt++,this.vertexSrc=e||t.defaultVertexSrc,this.fragmentSrc=n||t.defaultFragmentSrc,this.vertexSrc=this.vertexSrc.trim(),this.fragmentSrc=this.fragmentSrc.trim(),"#version"!==this.vertexSrc.substring(0,8)&&(o=o.replace(/\s+/g,"-"),kt[o]?(kt[o]++,o+="-"+kt[o]):kt[o]=1,this.vertexSrc="#define SHADER_NAME "+o+"\n"+this.vertexSrc,this.fragmentSrc="#define SHADER_NAME "+o+"\n"+this.fragmentSrc,this.vertexSrc=xt(this.vertexSrc,r.X.PRECISION_VERTEX,i.cB.HIGH),this.fragmentSrc=xt(this.fragmentSrc,r.X.PRECISION_FRAGMENT,Et())),this.glPrograms={},this.syncUniforms=null}return Object.defineProperty(t,"defaultVertexSrc",{get:function(){return Ut},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultFragmentSrc",{get:function(){return Bt},enumerable:!1,configurable:!0}),t.from=function(e,n,r){var i=e+n,s=o.GG[i];return s||(o.GG[i]=s=new t(e,n,r)),s},t}(),jt=function(){function t(t,e){this.uniformBindCount=0,this.program=t,this.uniformGroup=e?e instanceof Z?e:new Z(e):new Z({})}return t.prototype.checkUniformExists=function(t,e){if(e.uniforms[t])return!0;for(var n in e.uniforms){var r=e.uniforms[n];if(r.group&&this.checkUniformExists(t,r))return!0}return!1},t.prototype.destroy=function(){this.uniformGroup=null},Object.defineProperty(t.prototype,"uniforms",{get:function(){return this.uniformGroup.uniforms},enumerable:!1,configurable:!0}),t.from=function(e,n,r){var i=Xt.from(e,n);return new t(i,r)},t}(),Ht=0,Vt=1,Yt=2,Wt=3,zt=4,$t=5,qt=function(){function t(){this.data=0,this.blendMode=i.T$.NORMAL,this.polygonOffset=0,this.blend=!0,this.depthMask=!0}return Object.defineProperty(t.prototype,"blend",{get:function(){return!!(this.data&1<<Ht)},set:function(t){!!(this.data&1<<Ht)!==t&&(this.data^=1<<Ht)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"offsets",{get:function(){return!!(this.data&1<<Vt)},set:function(t){!!(this.data&1<<Vt)!==t&&(this.data^=1<<Vt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"culling",{get:function(){return!!(this.data&1<<Yt)},set:function(t){!!(this.data&1<<Yt)!==t&&(this.data^=1<<Yt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"depthTest",{get:function(){return!!(this.data&1<<Wt)},set:function(t){!!(this.data&1<<Wt)!==t&&(this.data^=1<<Wt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"depthMask",{get:function(){return!!(this.data&1<<$t)},set:function(t){!!(this.data&1<<$t)!==t&&(this.data^=1<<$t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"clockwiseFrontFace",{get:function(){return!!(this.data&1<<zt)},set:function(t){!!(this.data&1<<zt)!==t&&(this.data^=1<<zt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"blendMode",{get:function(){return this._blendMode},set:function(t){this.blend=t!==i.T$.NONE,this._blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"polygonOffset",{get:function(){return this._polygonOffset},set:function(t){this.offsets=!!t,this._polygonOffset=t},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"[@pixi/core:State blendMode="+this.blendMode+" clockwiseFrontFace="+this.clockwiseFrontFace+" culling="+this.culling+" depthMask="+this.depthMask+" polygonOffset="+this.polygonOffset+"]"},t.for2d=function(){var e=new t;return e.depthTest=!1,e.blend=!0,e},t}(),Kt="attribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvec2 filterTextureCoord( void )\n{\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n}\n\nvoid main(void)\n{\n gl_Position = filterVertexPosition();\n vTextureCoord = filterTextureCoord();\n}\n",Zt="varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\n\nvoid main(void){\n gl_FragColor = texture2D(uSampler, vTextureCoord);\n}\n",Jt=function(t){function e(n,i,o){var s=this,a=Xt.from(n||e.defaultVertexSrc,i||e.defaultFragmentSrc);return s=t.call(this,a,o)||this,s.padding=0,s.resolution=r.X.FILTER_RESOLUTION,s.multisample=r.X.FILTER_MULTISAMPLE,s.enabled=!0,s.autoFit=!0,s.state=new qt,s}return f(e,t),e.prototype.apply=function(t,e,n,r,i){t.applyFilter(this,e,n,r)},Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.state.blendMode},set:function(t){this.state.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"resolution",{get:function(){return this._resolution},set:function(t){this._resolution=t},enumerable:!1,configurable:!0}),Object.defineProperty(e,"defaultVertexSrc",{get:function(){return Kt},enumerable:!1,configurable:!0}),Object.defineProperty(e,"defaultFragmentSrc",{get:function(){return Zt},enumerable:!1,configurable:!0}),e}(jt),Qt="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 otherMatrix;\n\nvarying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;\n}\n",te="varying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform sampler2D mask;\nuniform float alpha;\nuniform float npmAlpha;\nuniform vec4 maskClamp;\n\nvoid main(void)\n{\n float clip = step(3.5,\n step(maskClamp.x, vMaskCoord.x) +\n step(maskClamp.y, vMaskCoord.y) +\n step(vMaskCoord.x, maskClamp.z) +\n step(vMaskCoord.y, maskClamp.w));\n\n vec4 original = texture2D(uSampler, vTextureCoord);\n vec4 masky = texture2D(mask, vMaskCoord);\n float alphaMul = 1.0 - npmAlpha * (1.0 - masky.a);\n\n original *= (alphaMul * masky.r * alpha * clip);\n\n gl_FragColor = original;\n}\n",ee=new u.y3,ne=function(){function t(t,e){this._texture=t,this.mapCoord=new u.y3,this.uClampFrame=new Float32Array(4),this.uClampOffset=new Float32Array(2),this._textureID=-1,this._updateID=0,this.clampOffset=0,this.clampMargin="undefined"===typeof e?.5:e,this.isSimple=!1}return Object.defineProperty(t.prototype,"texture",{get:function(){return this._texture},set:function(t){this._texture=t,this._textureID=-1},enumerable:!1,configurable:!0}),t.prototype.multiplyUvs=function(t,e){void 0===e&&(e=t);for(var n=this.mapCoord,r=0;r<t.length;r+=2){var i=t[r],o=t[r+1];e[r]=i*n.a+o*n.c+n.tx,e[r+1]=i*n.b+o*n.d+n.ty}return e},t.prototype.update=function(t){var e=this._texture;if(!e||!e.valid)return!1;if(!t&&this._textureID===e._updateID)return!1;this._textureID=e._updateID,this._updateID++;var n=e._uvs;this.mapCoord.set(n.x1-n.x0,n.y1-n.y0,n.x3-n.x0,n.y3-n.y0,n.x0,n.y0);var r=e.orig,i=e.trim;i&&(ee.set(r.width/i.width,0,0,r.height/i.height,-i.x/i.width,-i.y/i.height),this.mapCoord.append(ee));var o=e.baseTexture,s=this.uClampFrame,a=this.clampMargin/o.resolution,u=this.clampOffset;return s[0]=(e._frame.x+a+u)/o.width,s[1]=(e._frame.y+a+u)/o.height,s[2]=(e._frame.x+e._frame.width-a+u)/o.width,s[3]=(e._frame.y+e._frame.height-a+u)/o.height,this.uClampOffset[0]=u/o.realWidth,this.uClampOffset[1]=u/o.realHeight,this.isSimple=e._frame.width===o.width&&e._frame.height===o.height&&0===e.rotate,!0},t}(),re=function(t){function e(e,n,r){var i=this,o=null;return"string"!==typeof e&&void 0===n&&void 0===r&&(o=e,e=void 0,n=void 0,r=void 0),i=t.call(this,e||Qt,n||te,r)||this,i.maskSprite=o,i.maskMatrix=new u.y3,i}return f(e,t),Object.defineProperty(e.prototype,"maskSprite",{get:function(){return this._maskSprite},set:function(t){this._maskSprite=t,this._maskSprite&&(this._maskSprite.renderable=!1)},enumerable:!1,configurable:!0}),e.prototype.apply=function(t,e,n,r){var i=this._maskSprite,o=i._texture;o.valid&&(o.uvMatrix||(o.uvMatrix=new ne(o,0)),o.uvMatrix.update(),this.uniforms.npmAlpha=o.baseTexture.alphaMode?0:1,this.uniforms.mask=o,this.uniforms.otherMatrix=t.calculateSpriteMatrix(this.maskMatrix,i).prepend(o.uvMatrix.mapCoord),this.uniforms.alpha=i.worldAlpha,this.uniforms.maskClamp=o.uvMatrix.uClampFrame,t.applyFilter(this,e,n,r))},e}(Jt),ie=function(){function t(t){this.renderer=t,this.enableScissor=!0,this.alphaMaskPool=[],this.maskDataPool=[],this.maskStack=[],this.alphaMaskIndex=0}return t.prototype.setMaskStack=function(t){this.maskStack=t,this.renderer.scissor.setMaskStack(t),this.renderer.stencil.setMaskStack(t)},t.prototype.push=function(t,e){var n=e;if(!n.isMaskData){var r=this.maskDataPool.pop()||new ht;r.pooled=!0,r.maskObject=e,n=r}var o=0!==this.maskStack.length?this.maskStack[this.maskStack.length-1]:null;if(n.copyCountersOrReset(o),n.autoDetect&&this.detect(n),n._target=t,n.type!==i.A7.SPRITE&&this.maskStack.push(n),n.enabled)switch(n.type){case i.A7.SCISSOR:this.renderer.scissor.push(n);break;case i.A7.STENCIL:this.renderer.stencil.push(n);break;case i.A7.SPRITE:n.copyCountersOrReset(null),this.pushSpriteMask(n);break}n.type===i.A7.SPRITE&&this.maskStack.push(n)},t.prototype.pop=function(t){var e=this.maskStack.pop();if(e&&e._target===t){if(e.enabled)switch(e.type){case i.A7.SCISSOR:this.renderer.scissor.pop();break;case i.A7.STENCIL:this.renderer.stencil.pop(e.maskObject);break;case i.A7.SPRITE:this.popSpriteMask(e);break}if(e.reset(),e.pooled&&this.maskDataPool.push(e),0!==this.maskStack.length){var n=this.maskStack[this.maskStack.length-1];n.type===i.A7.SPRITE&&n._filters&&(n._filters[0].maskSprite=n.maskObject)}}},t.prototype.detect=function(t){var e=t.maskObject;e.isSprite?t.type=i.A7.SPRITE:this.enableScissor&&this.renderer.scissor.testScissor(t)?t.type=i.A7.SCISSOR:t.type=i.A7.STENCIL},t.prototype.pushSpriteMask=function(t){var e,n,r=t.maskObject,i=t._target,o=t._filters;o||(o=this.alphaMaskPool[this.alphaMaskIndex],o||(o=this.alphaMaskPool[this.alphaMaskIndex]=[new re]));var s,a,u=this.renderer,l=u.renderTexture;if(l.current){var c=l.current;s=t.resolution||c.resolution,a=null!==(e=t.multisample)&&void 0!==e?e:c.multisample}else s=t.resolution||u.resolution,a=null!==(n=t.multisample)&&void 0!==n?n:u.multisample;o[0].resolution=s,o[0].multisample=a,o[0].maskSprite=r;var h=i.filterArea;i.filterArea=r.getBounds(!0),u.filter.push(i,o),i.filterArea=h,t._filters||this.alphaMaskIndex++},t.prototype.popSpriteMask=function(t){this.renderer.filter.pop(),t._filters?t._filters[0].maskSprite=null:(this.alphaMaskIndex--,this.alphaMaskPool[this.alphaMaskIndex][0].maskSprite=null)},t.prototype.destroy=function(){this.renderer=null},t}(),oe=function(){function t(t){this.renderer=t,this.maskStack=[],this.glConst=0}return t.prototype.getStackLength=function(){return this.maskStack.length},t.prototype.setMaskStack=function(t){var e=this.renderer.gl,n=this.getStackLength();this.maskStack=t;var r=this.getStackLength();r!==n&&(0===r?e.disable(this.glConst):(e.enable(this.glConst),this._useCurrent()))},t.prototype._useCurrent=function(){},t.prototype.destroy=function(){this.renderer=null,this.maskStack=null},t}(),se=new u.y3,ae=function(t){function e(e){var n=t.call(this,e)||this;return n.glConst=WebGLRenderingContext.SCISSOR_TEST,n}return f(e,t),e.prototype.getStackLength=function(){var t=this.maskStack[this.maskStack.length-1];return t?t._scissorCounter:0},e.prototype.calcScissorRect=function(t){if(!t._scissorRectLocal){var e=t._scissorRect,n=t.maskObject,r=this.renderer,i=r.renderTexture;n.renderable=!0;var o=n.getBounds();this.roundFrameToPixels(o,i.current?i.current.resolution:r.resolution,i.sourceFrame,i.destinationFrame,r.projection.transform),n.renderable=!1,e&&o.fit(e),t._scissorRectLocal=o}},e.isMatrixRotated=function(t){if(!t)return!1;var e=t.a,n=t.b,r=t.c,i=t.d;return(Math.abs(n)>1e-4||Math.abs(r)>1e-4)&&(Math.abs(e)>1e-4||Math.abs(i)>1e-4)},e.prototype.testScissor=function(t){var n=t.maskObject;if(!n.isFastRect||!n.isFastRect())return!1;if(e.isMatrixRotated(n.worldTransform))return!1;if(e.isMatrixRotated(this.renderer.projection.transform))return!1;this.calcScissorRect(t);var r=t._scissorRectLocal;return r.width>0&&r.height>0},e.prototype.roundFrameToPixels=function(t,n,r,i,o){e.isMatrixRotated(o)||(o=o?se.copyFrom(o):se.identity(),o.translate(-r.x,-r.y).scale(i.width/r.width,i.height/r.height).translate(i.x,i.y),this.renderer.filter.transformAABB(o,t),t.fit(i),t.x=Math.round(t.x*n),t.y=Math.round(t.y*n),t.width=Math.round(t.width*n),t.height=Math.round(t.height*n))},e.prototype.push=function(t){t._scissorRectLocal||this.calcScissorRect(t);var e=this.renderer.gl;t._scissorRect||e.enable(e.SCISSOR_TEST),t._scissorCounter++,t._scissorRect=t._scissorRectLocal,this._useCurrent()},e.prototype.pop=function(){var t=this.renderer.gl;this.getStackLength()>0?this._useCurrent():t.disable(t.SCISSOR_TEST)},e.prototype._useCurrent=function(){var t,e=this.maskStack[this.maskStack.length-1]._scissorRect;t=this.renderer.renderTexture.current?e.y:this.renderer.height-e.height-e.y,this.renderer.gl.scissor(e.x,t,e.width,e.height)},e}(oe),ue=function(t){function e(e){var n=t.call(this,e)||this;return n.glConst=WebGLRenderingContext.STENCIL_TEST,n}return f(e,t),e.prototype.getStackLength=function(){var t=this.maskStack[this.maskStack.length-1];return t?t._stencilCounter:0},e.prototype.push=function(t){var e=t.maskObject,n=this.renderer.gl,r=t._stencilCounter;0===r&&(this.renderer.framebuffer.forceStencil(),n.clearStencil(0),n.clear(n.STENCIL_BUFFER_BIT),n.enable(n.STENCIL_TEST)),t._stencilCounter++,n.colorMask(!1,!1,!1,!1),n.stencilFunc(n.EQUAL,r,4294967295),n.stencilOp(n.KEEP,n.KEEP,n.INCR),e.renderable=!0,e.render(this.renderer),this.renderer.batch.flush(),e.renderable=!1,this._useCurrent()},e.prototype.pop=function(t){var e=this.renderer.gl;0===this.getStackLength()?e.disable(e.STENCIL_TEST):(e.colorMask(!1,!1,!1,!1),e.stencilOp(e.KEEP,e.KEEP,e.DECR),t.renderable=!0,t.render(this.renderer),this.renderer.batch.flush(),t.renderable=!1,this._useCurrent())},e.prototype._useCurrent=function(){var t=this.renderer.gl;t.colorMask(!0,!0,!0,!0),t.stencilFunc(t.EQUAL,this.getStackLength(),4294967295),t.stencilOp(t.KEEP,t.KEEP,t.KEEP)},e}(oe),le=function(){function t(t){this.renderer=t,this.destinationFrame=null,this.sourceFrame=null,this.defaultFrame=null,this.projectionMatrix=new u.y3,this.transform=null}return t.prototype.update=function(t,e,n,r){this.destinationFrame=t||this.destinationFrame||this.defaultFrame,this.sourceFrame=e||this.sourceFrame||t,this.calculateProjection(this.destinationFrame,this.sourceFrame,n,r),this.transform&&this.projectionMatrix.append(this.transform);var i=this.renderer;i.globalUniforms.uniforms.projectionMatrix=this.projectionMatrix,i.globalUniforms.update(),i.shader.shader&&i.shader.syncUniformGroup(i.shader.shader.uniforms.globals)},t.prototype.calculateProjection=function(t,e,n,r){var i=this.projectionMatrix,o=r?-1:1;i.identity(),i.a=1/e.width*2,i.d=o*(1/e.height*2),i.tx=-1-e.x*i.a,i.ty=-o-e.y*i.d},t.prototype.setTransform=function(t){},t.prototype.destroy=function(){this.renderer=null},t}(),ce=new u.Ae,he=new u.Ae,fe=function(){function t(t){this.renderer=t,this.clearColor=t._backgroundColorRgba,this.defaultMaskStack=[],this.current=null,this.sourceFrame=new u.Ae,this.destinationFrame=new u.Ae,this.viewportFrame=new u.Ae}return t.prototype.bind=function(t,e,n){void 0===t&&(t=null);var r,i,o,s=this.renderer;this.current=t,t?(r=t.baseTexture,o=r.resolution,e||(ce.width=t.frame.width,ce.height=t.frame.height,e=ce),n||(he.x=t.frame.x,he.y=t.frame.y,he.width=e.width,he.height=e.height,n=he),i=r.framebuffer):(o=s.resolution,e||(ce.width=s.screen.width,ce.height=s.screen.height,e=ce),n||(n=ce,n.width=e.width,n.height=e.height));var a=this.viewportFrame;a.x=n.x*o,a.y=n.y*o,a.width=n.width*o,a.height=n.height*o,t||(a.y=s.view.height-(a.y+a.height)),a.ceil(),this.renderer.framebuffer.bind(i,a),this.renderer.projection.update(n,e,o,!i),t?this.renderer.mask.setMaskStack(r.maskStack):this.renderer.mask.setMaskStack(this.defaultMaskStack),this.sourceFrame.copyFrom(e),this.destinationFrame.copyFrom(n)},t.prototype.clear=function(t,e){t=this.current?t||this.current.baseTexture.clearColor:t||this.clearColor;var n=this.destinationFrame,r=this.current?this.current.baseTexture:this.renderer.screen,i=n.width!==r.width||n.height!==r.height;if(i){var o=this.viewportFrame,s=o.x,a=o.y,u=o.width,l=o.height;s=Math.round(s),a=Math.round(a),u=Math.round(u),l=Math.round(l),this.renderer.gl.enable(this.renderer.gl.SCISSOR_TEST),this.renderer.gl.scissor(s,a,u,l)}this.renderer.framebuffer.clear(t[0],t[1],t[2],t[3],e),i&&this.renderer.scissor.pop()},t.prototype.resize=function(){this.bind(null)},t.prototype.reset=function(){this.bind(null)},t.prototype.destroy=function(){this.renderer=null},t}();function de(t,e,n,r,i){n.buffer.update(i)}var pe={float:"\n data[offset] = v;\n ",vec2:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n ",vec3:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n data[offset+2] = v[2];\n\n ",vec4:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n data[offset+2] = v[2];\n data[offset+3] = v[3];\n ",mat2:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n\n data[offset+4] = v[2];\n data[offset+5] = v[3];\n ",mat3:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n data[offset+2] = v[2];\n\n data[offset + 4] = v[3];\n data[offset + 5] = v[4];\n data[offset + 6] = v[5];\n\n data[offset + 8] = v[6];\n data[offset + 9] = v[7];\n data[offset + 10] = v[8];\n ",mat4:"\n for(var i = 0; i < 16; i++)\n {\n data[offset + i] = v[i];\n }\n "},ve={float:4,vec2:8,vec3:12,vec4:16,int:4,ivec2:8,ivec3:12,ivec4:16,uint:4,uvec2:8,uvec3:12,uvec4:16,bool:4,bvec2:8,bvec3:12,bvec4:16,mat2:32,mat3:48,mat4:64};function me(t){for(var e=t.map((function(t){return{data:t,offset:0,dataLen:0,dirty:0}})),n=0,r=0,i=0,o=0;o<e.length;o++){var s=e[o];if(n=ve[s.data.type],s.data.size>1&&(n=Math.max(n,16)*s.data.size),s.dataLen=n,r%n!==0&&r<16){var a=r%n%16;r+=a,i+=a}r+n>16?(i=16*Math.ceil(i/16),s.offset=i,i+=n,r=n):(s.offset=i,r+=n,i+=n)}return i=16*Math.ceil(i/16),{uboElements:e,size:i}}function ge(t,e){var n=[];for(var r in t)e[r]&&n.push(e[r]);return n.sort((function(t,e){return t.index-e.index})),n}function _e(t,e){if(!t.autoManage)return{size:0,syncFunc:de};for(var n=ge(t.uniforms,e),r=me(n),i=r.uboElements,o=r.size,s=["\n var v = null;\n var v2 = null;\n var cv = null;\n var t = 0;\n var gl = renderer.gl\n var index = 0;\n var data = buffer.data;\n "],a=0;a<i.length;a++){for(var u=i[a],l=t.uniforms[u.data.name],c=u.data.name,h=!1,f=0;f<wt.length;f++){var d=wt[f];if(d.codeUbo&&d.test(u.data,l)){s.push("offset = "+u.offset/4+";",wt[f].codeUbo(u.data.name,l)),h=!0;break}}if(!h)if(u.data.size>1){var p=St(u.data.type),v=Math.max(ve[u.data.type]/16,1),m=p/v,g=(4-m%4)%4;s.push("\n cv = ud."+c+".value;\n v = uv."+c+";\n offset = "+u.offset/4+";\n\n t = 0;\n\n for(var i=0; i < "+u.data.size*v+"; i++)\n {\n for(var j = 0; j < "+m+"; j++)\n {\n data[offset++] = v[t++];\n }\n offset += "+g+";\n }\n\n ")}else{var _=pe[u.data.type];s.push("\n cv = ud."+c+".value;\n v = uv."+c+";\n offset = "+u.offset/4+";\n "+_+";\n ")}}return s.push("\n renderer.buffer.update(buffer);\n "),{size:o,syncFunc:new Function("ud","uv","renderer","syncData","buffer",s.join("\n"))}}(function(){function t(){}})();var ye=function(){function t(t,e){this.program=t,this.uniformData=e,this.uniformGroups={},this.uniformDirtyGroups={},this.uniformBufferBindings={}}return t.prototype.destroy=function(){this.uniformData=null,this.uniformGroups=null,this.uniformDirtyGroups=null,this.uniformBufferBindings=null,this.program=null},t}();function be(t,e){for(var n={},r=e.getProgramParameter(t,e.ACTIVE_ATTRIBUTES),i=0;i<r;i++){var o=e.getActiveAttrib(t,i);if(0!==o.name.indexOf("gl_")){var s=Ot(e,o.type),a={type:s,name:o.name,size:St(s),location:e.getAttribLocation(t,o.name)};n[o.name]=a}}return n}function Ee(t,e){for(var n={},r=e.getProgramParameter(t,e.ACTIVE_UNIFORMS),i=0;i<r;i++){var o=e.getActiveUniform(t,i),s=o.name.replace(/\[.*?\]$/,""),a=!!o.name.match(/\[.*?\]$/),u=Ot(e,o.type);n[s]={name:s,index:i,type:u,size:o.size,isArray:a,value:mt(u,o.size)}}return n}function xe(t,e){var n=ft(t,t.VERTEX_SHADER,e.vertexSrc),r=ft(t,t.FRAGMENT_SHADER,e.fragmentSrc),i=t.createProgram();if(t.attachShader(i,n),t.attachShader(i,r),t.linkProgram(i),t.getProgramParameter(i,t.LINK_STATUS)||pt(t,i,n,r),e.attributeData=be(i,t),e.uniformData=Ee(i,t),!/^[ \t]*#[ \t]*version[ \t]+300[ \t]+es[ \t]*$/m.test(e.vertexSrc)){var o=Object.keys(e.attributeData);o.sort((function(t,e){return t>e?1:-1}));for(var s=0;s<o.length;s++)e.attributeData[o[s]].location=s,t.bindAttribLocation(i,s,o[s]);t.linkProgram(i)}t.deleteShader(n),t.deleteShader(r);var a={};for(var s in e.uniformData){var u=e.uniformData[s];a[s]={location:t.getUniformLocation(i,s),value:mt(u.type,u.size)}}var l=new ye(i,a);return l}var Te=0,Se={textureCount:0,uboCount:0},Re=function(){function t(t){this.destroyed=!1,this.renderer=t,this.systemCheck(),this.gl=null,this.shader=null,this.program=null,this.cache={},this._uboCache={},this.id=Te++}return t.prototype.systemCheck=function(){if(!Ft())throw new Error("Current environment does not allow unsafe-eval, please use @pixi/unsafe-eval module to enable support.")},t.prototype.contextChange=function(t){this.gl=t,this.reset()},t.prototype.bind=function(t,e){t.uniforms.globals=this.renderer.globalUniforms;var n=t.program,r=n.glPrograms[this.renderer.CONTEXT_UID]||this.generateProgram(t);return this.shader=t,this.program!==n&&(this.program=n,this.gl.useProgram(r.program)),e||(Se.textureCount=0,Se.uboCount=0,this.syncUniformGroup(t.uniformGroup,Se)),r},t.prototype.setUniforms=function(t){var e=this.shader.program,n=e.glPrograms[this.renderer.CONTEXT_UID];e.syncUniforms(n.uniformData,t,this.renderer)},t.prototype.syncUniformGroup=function(t,e){var n=this.getGlProgram();t.static&&t.dirtyId===n.uniformDirtyGroups[t.id]||(n.uniformDirtyGroups[t.id]=t.dirtyId,this.syncUniforms(t,n,e))},t.prototype.syncUniforms=function(t,e,n){var r=t.syncUniforms[this.shader.program.id]||this.createSyncGroups(t);r(e.uniformData,t.uniforms,this.renderer,n)},t.prototype.createSyncGroups=function(t){var e=this.getSignature(t,this.shader.program.uniformData,"u");return this.cache[e]||(this.cache[e]=Ct(t,this.shader.program.uniformData)),t.syncUniforms[this.shader.program.id]=this.cache[e],t.syncUniforms[this.shader.program.id]},t.prototype.syncUniformBufferGroup=function(t,e){var n=this.getGlProgram();if(!t.static||0!==t.dirtyId||!n.uniformGroups[t.id]){t.dirtyId=0;var r=n.uniformGroups[t.id]||this.createSyncBufferGroup(t,n,e);t.buffer.update(),r(n.uniformData,t.uniforms,this.renderer,Se,t.buffer)}this.renderer.buffer.bindBufferBase(t.buffer,n.uniformBufferBindings[e])},t.prototype.createSyncBufferGroup=function(t,e,n){var r=this.renderer.gl;this.renderer.buffer.bind(t.buffer);var i=this.gl.getUniformBlockIndex(e.program,n);e.uniformBufferBindings[n]=this.shader.uniformBindCount,r.uniformBlockBinding(e.program,i,this.shader.uniformBindCount),this.shader.uniformBindCount++;var o=this.getSignature(t,this.shader.program.uniformData,"ubo"),s=this._uboCache[o];if(s||(s=this._uboCache[o]=_e(t,this.shader.program.uniformData)),t.autoManage){var a=new Float32Array(s.size/4);t.buffer.update(a)}return e.uniformGroups[t.id]=s.syncFunc,e.uniformGroups[t.id]},t.prototype.getSignature=function(t,e,n){var r=t.uniforms,i=[n+"-"];for(var o in r)i.push(o),e[o]&&i.push(e[o].type);return i.join("-")},t.prototype.getGlProgram=function(){return this.shader?this.shader.program.glPrograms[this.renderer.CONTEXT_UID]:null},t.prototype.generateProgram=function(t){var e=this.gl,n=t.program,r=xe(e,n);return n.glPrograms[this.renderer.CONTEXT_UID]=r,r},t.prototype.reset=function(){this.program=null,this.shader=null},t.prototype.destroy=function(){this.renderer=null,this.destroyed=!0},t}();function Ae(t,e){return void 0===e&&(e=[]),e[i.T$.NORMAL]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.ADD]=[t.ONE,t.ONE],e[i.T$.MULTIPLY]=[t.DST_COLOR,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.SCREEN]=[t.ONE,t.ONE_MINUS_SRC_COLOR,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.OVERLAY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.DARKEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.LIGHTEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.COLOR_DODGE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.COLOR_BURN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.HARD_LIGHT]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.SOFT_LIGHT]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.DIFFERENCE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.EXCLUSION]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.HUE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.SATURATION]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.COLOR]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.LUMINOSITY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.NONE]=[0,0],e[i.T$.NORMAL_NPM]=[t.SRC_ALPHA,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.ADD_NPM]=[t.SRC_ALPHA,t.ONE,t.ONE,t.ONE],e[i.T$.SCREEN_NPM]=[t.SRC_ALPHA,t.ONE_MINUS_SRC_COLOR,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.SRC_IN]=[t.DST_ALPHA,t.ZERO],e[i.T$.SRC_OUT]=[t.ONE_MINUS_DST_ALPHA,t.ZERO],e[i.T$.SRC_ATOP]=[t.DST_ALPHA,t.ONE_MINUS_SRC_ALPHA],e[i.T$.DST_OVER]=[t.ONE_MINUS_DST_ALPHA,t.ONE],e[i.T$.DST_IN]=[t.ZERO,t.SRC_ALPHA],e[i.T$.DST_OUT]=[t.ZERO,t.ONE_MINUS_SRC_ALPHA],e[i.T$.DST_ATOP]=[t.ONE_MINUS_DST_ALPHA,t.SRC_ALPHA],e[i.T$.XOR]=[t.ONE_MINUS_DST_ALPHA,t.ONE_MINUS_SRC_ALPHA],e[i.T$.SUBTRACT]=[t.ONE,t.ONE,t.ONE,t.ONE,t.FUNC_REVERSE_SUBTRACT,t.FUNC_ADD],e}var Oe=0,we=1,Ie=2,Pe=3,Ce=4,Ne=5,Me=function(){function t(){this.gl=null,this.stateId=0,this.polygonOffset=0,this.blendMode=i.T$.NONE,this._blendEq=!1,this.map=[],this.map[Oe]=this.setBlend,this.map[we]=this.setOffset,this.map[Ie]=this.setCullFace,this.map[Pe]=this.setDepthTest,this.map[Ce]=this.setFrontFace,this.map[Ne]=this.setDepthMask,this.checks=[],this.defaultState=new qt,this.defaultState.blend=!0}return t.prototype.contextChange=function(t){this.gl=t,this.blendModes=Ae(t),this.set(this.defaultState),this.reset()},t.prototype.set=function(t){if(t=t||this.defaultState,this.stateId!==t.data){var e=this.stateId^t.data,n=0;while(e)1&e&&this.map[n].call(this,!!(t.data&1<<n)),e>>=1,n++;this.stateId=t.data}for(n=0;n<this.checks.length;n++)this.checks[n](this,t)},t.prototype.forceState=function(t){t=t||this.defaultState;for(var e=0;e<this.map.length;e++)this.map[e].call(this,!!(t.data&1<<e));for(e=0;e<this.checks.length;e++)this.checks[e](this,t);this.stateId=t.data},t.prototype.setBlend=function(e){this.updateCheck(t.checkBlendMode,e),this.gl[e?"enable":"disable"](this.gl.BLEND)},t.prototype.setOffset=function(e){this.updateCheck(t.checkPolygonOffset,e),this.gl[e?"enable":"disable"](this.gl.POLYGON_OFFSET_FILL)},t.prototype.setDepthTest=function(t){this.gl[t?"enable":"disable"](this.gl.DEPTH_TEST)},t.prototype.setDepthMask=function(t){this.gl.depthMask(t)},t.prototype.setCullFace=function(t){this.gl[t?"enable":"disable"](this.gl.CULL_FACE)},t.prototype.setFrontFace=function(t){this.gl.frontFace(this.gl[t?"CW":"CCW"])},t.prototype.setBlendMode=function(t){if(t!==this.blendMode){this.blendMode=t;var e=this.blendModes[t],n=this.gl;2===e.length?n.blendFunc(e[0],e[1]):n.blendFuncSeparate(e[0],e[1],e[2],e[3]),6===e.length?(this._blendEq=!0,n.blendEquationSeparate(e[4],e[5])):this._blendEq&&(this._blendEq=!1,n.blendEquationSeparate(n.FUNC_ADD,n.FUNC_ADD))}},t.prototype.setPolygonOffset=function(t,e){this.gl.polygonOffset(t,e)},t.prototype.reset=function(){this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL,!1),this.forceState(this.defaultState),this._blendEq=!0,this.blendMode=-1,this.setBlendMode(0)},t.prototype.updateCheck=function(t,e){var n=this.checks.indexOf(t);e&&-1===n?this.checks.push(t):e||-1===n||this.checks.splice(n,1)},t.checkBlendMode=function(t,e){t.setBlendMode(e.blendMode)},t.checkPolygonOffset=function(t,e){t.setPolygonOffset(1,e.polygonOffset)},t.prototype.destroy=function(){this.gl=null},t}(),De=function(){function t(t){this.renderer=t,this.count=0,this.checkCount=0,this.maxIdle=r.X.GC_MAX_IDLE,this.checkCountMax=r.X.GC_MAX_CHECK_COUNT,this.mode=r.X.GC_MODE}return t.prototype.postrender=function(){this.renderer.renderingToScreen&&(this.count++,this.mode!==i.UN.MANUAL&&(this.checkCount++,this.checkCount>this.checkCountMax&&(this.checkCount=0,this.run())))},t.prototype.run=function(){for(var t=this.renderer.texture,e=t.managedTextures,n=!1,r=0;r<e.length;r++){var i=e[r];!i.framebuffer&&this.count-i.touched>this.maxIdle&&(t.destroyTexture(i,!0),e[r]=null,n=!0)}if(n){var o=0;for(r=0;r<e.length;r++)null!==e[r]&&(e[o++]=e[r]);e.length=o}},t.prototype.unload=function(t){var e=this.renderer.texture,n=t._texture;n&&!n.framebuffer&&e.destroyTexture(n);for(var r=t.children.length-1;r>=0;r--)this.unload(t.children[r])},t.prototype.destroy=function(){this.renderer=null},t}();function Le(t){var e,n,r,o,s,a,u,l,c,h,f,d,p,v,m,g,_,y,b,E,x,T,S;return"WebGL2RenderingContext"in globalThis&&t instanceof globalThis.WebGL2RenderingContext?(e={},e[i.vK.UNSIGNED_BYTE]=(n={},n[i.I2.RGBA]=t.RGBA8,n[i.I2.RGB]=t.RGB8,n[i.I2.RG]=t.RG8,n[i.I2.RED]=t.R8,n[i.I2.RGBA_INTEGER]=t.RGBA8UI,n[i.I2.RGB_INTEGER]=t.RGB8UI,n[i.I2.RG_INTEGER]=t.RG8UI,n[i.I2.RED_INTEGER]=t.R8UI,n[i.I2.ALPHA]=t.ALPHA,n[i.I2.LUMINANCE]=t.LUMINANCE,n[i.I2.LUMINANCE_ALPHA]=t.LUMINANCE_ALPHA,n),e[i.vK.BYTE]=(r={},r[i.I2.RGBA]=t.RGBA8_SNORM,r[i.I2.RGB]=t.RGB8_SNORM,r[i.I2.RG]=t.RG8_SNORM,r[i.I2.RED]=t.R8_SNORM,r[i.I2.RGBA_INTEGER]=t.RGBA8I,r[i.I2.RGB_INTEGER]=t.RGB8I,r[i.I2.RG_INTEGER]=t.RG8I,r[i.I2.RED_INTEGER]=t.R8I,r),e[i.vK.UNSIGNED_SHORT]=(o={},o[i.I2.RGBA_INTEGER]=t.RGBA16UI,o[i.I2.RGB_INTEGER]=t.RGB16UI,o[i.I2.RG_INTEGER]=t.RG16UI,o[i.I2.RED_INTEGER]=t.R16UI,o[i.I2.DEPTH_COMPONENT]=t.DEPTH_COMPONENT16,o),e[i.vK.SHORT]=(s={},s[i.I2.RGBA_INTEGER]=t.RGBA16I,s[i.I2.RGB_INTEGER]=t.RGB16I,s[i.I2.RG_INTEGER]=t.RG16I,s[i.I2.RED_INTEGER]=t.R16I,s),e[i.vK.UNSIGNED_INT]=(a={},a[i.I2.RGBA_INTEGER]=t.RGBA32UI,a[i.I2.RGB_INTEGER]=t.RGB32UI,a[i.I2.RG_INTEGER]=t.RG32UI,a[i.I2.RED_INTEGER]=t.R32UI,a[i.I2.DEPTH_COMPONENT]=t.DEPTH_COMPONENT24,a),e[i.vK.INT]=(u={},u[i.I2.RGBA_INTEGER]=t.RGBA32I,u[i.I2.RGB_INTEGER]=t.RGB32I,u[i.I2.RG_INTEGER]=t.RG32I,u[i.I2.RED_INTEGER]=t.R32I,u),e[i.vK.FLOAT]=(l={},l[i.I2.RGBA]=t.RGBA32F,l[i.I2.RGB]=t.RGB32F,l[i.I2.RG]=t.RG32F,l[i.I2.RED]=t.R32F,l[i.I2.DEPTH_COMPONENT]=t.DEPTH_COMPONENT32F,l),e[i.vK.HALF_FLOAT]=(c={},c[i.I2.RGBA]=t.RGBA16F,c[i.I2.RGB]=t.RGB16F,c[i.I2.RG]=t.RG16F,c[i.I2.RED]=t.R16F,c),e[i.vK.UNSIGNED_SHORT_5_6_5]=(h={},h[i.I2.RGB]=t.RGB565,h),e[i.vK.UNSIGNED_SHORT_4_4_4_4]=(f={},f[i.I2.RGBA]=t.RGBA4,f),e[i.vK.UNSIGNED_SHORT_5_5_5_1]=(d={},d[i.I2.RGBA]=t.RGB5_A1,d),e[i.vK.UNSIGNED_INT_2_10_10_10_REV]=(p={},p[i.I2.RGBA]=t.RGB10_A2,p[i.I2.RGBA_INTEGER]=t.RGB10_A2UI,p),e[i.vK.UNSIGNED_INT_10F_11F_11F_REV]=(v={},v[i.I2.RGB]=t.R11F_G11F_B10F,v),e[i.vK.UNSIGNED_INT_5_9_9_9_REV]=(m={},m[i.I2.RGB]=t.RGB9_E5,m),e[i.vK.UNSIGNED_INT_24_8]=(g={},g[i.I2.DEPTH_STENCIL]=t.DEPTH24_STENCIL8,g),e[i.vK.FLOAT_32_UNSIGNED_INT_24_8_REV]=(_={},_[i.I2.DEPTH_STENCIL]=t.DEPTH32F_STENCIL8,_),S=e):(y={},y[i.vK.UNSIGNED_BYTE]=(b={},b[i.I2.RGBA]=t.RGBA,b[i.I2.RGB]=t.RGB,b[i.I2.ALPHA]=t.ALPHA,b[i.I2.LUMINANCE]=t.LUMINANCE,b[i.I2.LUMINANCE_ALPHA]=t.LUMINANCE_ALPHA,b),y[i.vK.UNSIGNED_SHORT_5_6_5]=(E={},E[i.I2.RGB]=t.RGB,E),y[i.vK.UNSIGNED_SHORT_4_4_4_4]=(x={},x[i.I2.RGBA]=t.RGBA,x),y[i.vK.UNSIGNED_SHORT_5_5_5_1]=(T={},T[i.I2.RGBA]=t.RGBA,T),S=y),S}var Fe=function(){function t(t){this.texture=t,this.width=-1,this.height=-1,this.dirtyId=-1,this.dirtyStyleId=-1,this.mipmap=!1,this.wrapMode=33071,this.type=i.vK.UNSIGNED_BYTE,this.internalFormat=i.I2.RGBA,this.samplerType=0}return t}(),Be=function(){function t(t){this.renderer=t,this.boundTextures=[],this.currentLocation=-1,this.managedTextures=[],this._unknownBoundTextures=!1,this.unknownTexture=new _,this.hasIntegerTextures=!1}return t.prototype.contextChange=function(){var t=this.gl=this.renderer.gl;this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.webGLVersion=this.renderer.context.webGLVersion,this.internalFormats=Le(t);var e=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS);this.boundTextures.length=e;for(var n=0;n<e;n++)this.boundTextures[n]=null;this.emptyTextures={};var r=new Fe(t.createTexture());t.bindTexture(t.TEXTURE_2D,r.texture),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,1,1,0,t.RGBA,t.UNSIGNED_BYTE,new Uint8Array(4)),this.emptyTextures[t.TEXTURE_2D]=r,this.emptyTextures[t.TEXTURE_CUBE_MAP]=new Fe(t.createTexture()),t.bindTexture(t.TEXTURE_CUBE_MAP,this.emptyTextures[t.TEXTURE_CUBE_MAP].texture);for(n=0;n<6;n++)t.texImage2D(t.TEXTURE_CUBE_MAP_POSITIVE_X+n,0,t.RGBA,1,1,0,t.RGBA,t.UNSIGNED_BYTE,null);t.texParameteri(t.TEXTURE_CUBE_MAP,t.TEXTURE_MAG_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_CUBE_MAP,t.TEXTURE_MIN_FILTER,t.LINEAR);for(n=0;n<this.boundTextures.length;n++)this.bind(null,n)},t.prototype.bind=function(t,e){void 0===e&&(e=0);var n=this.gl;if(t=null===t||void 0===t?void 0:t.castToBaseTexture(),t&&t.valid&&!t.parentTextureArray){t.touched=this.renderer.textureGC.count;var r=t._glTextures[this.CONTEXT_UID]||this.initTexture(t);this.boundTextures[e]!==t&&(this.currentLocation!==e&&(this.currentLocation=e,n.activeTexture(n.TEXTURE0+e)),n.bindTexture(t.target,r.texture)),r.dirtyId!==t.dirtyId&&(this.currentLocation!==e&&(this.currentLocation=e,n.activeTexture(n.TEXTURE0+e)),this.updateTexture(t)),this.boundTextures[e]=t}else this.currentLocation!==e&&(this.currentLocation=e,n.activeTexture(n.TEXTURE0+e)),n.bindTexture(n.TEXTURE_2D,this.emptyTextures[n.TEXTURE_2D].texture),this.boundTextures[e]=null},t.prototype.reset=function(){this._unknownBoundTextures=!0,this.hasIntegerTextures=!1,this.currentLocation=-1;for(var t=0;t<this.boundTextures.length;t++)this.boundTextures[t]=this.unknownTexture},t.prototype.unbind=function(t){var e=this,n=e.gl,r=e.boundTextures;if(this._unknownBoundTextures){this._unknownBoundTextures=!1;for(var i=0;i<r.length;i++)r[i]===this.unknownTexture&&this.bind(null,i)}for(i=0;i<r.length;i++)r[i]===t&&(this.currentLocation!==i&&(n.activeTexture(n.TEXTURE0+i),this.currentLocation=i),n.bindTexture(t.target,this.emptyTextures[t.target].texture),r[i]=null)},t.prototype.ensureSamplerType=function(t){var e=this,n=e.boundTextures,r=e.hasIntegerTextures,o=e.CONTEXT_UID;if(r)for(var s=t-1;s>=0;--s){var a=n[s];if(a){var u=a._glTextures[o];u.samplerType!==i.oT.FLOAT&&this.renderer.texture.unbind(a)}}},t.prototype.initTexture=function(t){var e=new Fe(this.gl.createTexture());return e.dirtyId=-1,t._glTextures[this.CONTEXT_UID]=e,this.managedTextures.push(t),t.on("dispose",this.destroyTexture,this),e},t.prototype.initTextureType=function(t,e){var n,r;e.internalFormat=null!==(r=null===(n=this.internalFormats[t.type])||void 0===n?void 0:n[t.format])&&void 0!==r?r:t.format,2===this.webGLVersion&&t.type===i.vK.HALF_FLOAT?e.type=this.gl.HALF_FLOAT:e.type=t.type},t.prototype.updateTexture=function(t){var e=t._glTextures[this.CONTEXT_UID];if(e){var n=this.renderer;if(this.initTextureType(t,e),t.resource&&t.resource.upload(n,t,e))e.samplerType!==i.oT.FLOAT&&(this.hasIntegerTextures=!0);else{var r=t.realWidth,o=t.realHeight,s=n.gl;(e.width!==r||e.height!==o||e.dirtyId<0)&&(e.width=r,e.height=o,s.texImage2D(t.target,0,e.internalFormat,r,o,0,t.format,e.type,null))}t.dirtyStyleId!==e.dirtyStyleId&&this.updateTextureStyle(t),e.dirtyId=t.dirtyId}},t.prototype.destroyTexture=function(t,e){var n=this.gl;if(t=t.castToBaseTexture(),t._glTextures[this.CONTEXT_UID]&&(this.unbind(t),n.deleteTexture(t._glTextures[this.CONTEXT_UID].texture),t.off("dispose",this.destroyTexture,this),delete t._glTextures[this.CONTEXT_UID],!e)){var r=this.managedTextures.indexOf(t);-1!==r&&(0,o.Er)(this.managedTextures,r,1)}},t.prototype.updateTextureStyle=function(t){var e=t._glTextures[this.CONTEXT_UID];e&&(t.mipmap!==i.WB.POW2&&2===this.webGLVersion||t.isPowerOfTwo?e.mipmap=t.mipmap>=1:e.mipmap=!1,2===this.webGLVersion||t.isPowerOfTwo?e.wrapMode=t.wrapMode:e.wrapMode=i.Nt.CLAMP,t.resource&&t.resource.style(this.renderer,t,e)||this.setStyle(t,e),e.dirtyStyleId=t.dirtyStyleId)},t.prototype.setStyle=function(t,e){var n=this.gl;if(e.mipmap&&t.mipmap!==i.WB.ON_MANUAL&&n.generateMipmap(t.target),n.texParameteri(t.target,n.TEXTURE_WRAP_S,e.wrapMode),n.texParameteri(t.target,n.TEXTURE_WRAP_T,e.wrapMode),e.mipmap){n.texParameteri(t.target,n.TEXTURE_MIN_FILTER,t.scaleMode===i.aH.LINEAR?n.LINEAR_MIPMAP_LINEAR:n.NEAREST_MIPMAP_NEAREST);var r=this.renderer.context.extensions.anisotropicFiltering;if(r&&t.anisotropicLevel>0&&t.scaleMode===i.aH.LINEAR){var o=Math.min(t.anisotropicLevel,n.getParameter(r.MAX_TEXTURE_MAX_ANISOTROPY_EXT));n.texParameterf(t.target,r.TEXTURE_MAX_ANISOTROPY_EXT,o)}}else n.texParameteri(t.target,n.TEXTURE_MIN_FILTER,t.scaleMode===i.aH.LINEAR?n.LINEAR:n.NEAREST);n.texParameteri(t.target,n.TEXTURE_MAG_FILTER,t.scaleMode===i.aH.LINEAR?n.LINEAR:n.NEAREST)},t.prototype.destroy=function(){this.renderer=null},t}(),Ue={__proto__:null,FilterSystem:et,BatchSystem:rt,ContextSystem:ot,FramebufferSystem:ut,GeometrySystem:ct,MaskSystem:ie,ScissorSystem:ae,StencilSystem:ue,ProjectionSystem:le,RenderTextureSystem:fe,ShaderSystem:Re,StateSystem:Me,TextureGCSystem:De,TextureSystem:Be},Ge=new u.y3,ke=function(t){function e(e,n){void 0===e&&(e=i.N3.UNKNOWN);var s=t.call(this)||this;return n=Object.assign({},r.X.RENDER_OPTIONS,n),s.options=n,s.type=e,s.screen=new u.Ae(0,0,n.width,n.height),s.view=n.view||document.createElement("canvas"),s.resolution=n.resolution||r.X.RESOLUTION,s.useContextAlpha=n.useContextAlpha,s.autoDensity=!!n.autoDensity,s.preserveDrawingBuffer=n.preserveDrawingBuffer,s.clearBeforeRender=n.clearBeforeRender,s._backgroundColor=0,s._backgroundColorRgba=[0,0,0,1],s._backgroundColorString="#000000",s.backgroundColor=n.backgroundColor||s._backgroundColor,s.backgroundAlpha=n.backgroundAlpha,void 0!==n.transparent&&((0,o.a1)("6.0.0","Option transparent is deprecated, please use backgroundAlpha instead."),s.useContextAlpha=n.transparent,s.backgroundAlpha=n.transparent?0:1),s._lastObjectRendered=null,s.plugins={},s}return f(e,t),e.prototype.initPlugins=function(t){for(var e in t)this.plugins[e]=new t[e](this)},Object.defineProperty(e.prototype,"width",{get:function(){return this.view.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.view.height},enumerable:!1,configurable:!0}),e.prototype.resize=function(t,e){this.view.width=Math.round(t*this.resolution),this.view.height=Math.round(e*this.resolution);var n=this.view.width/this.resolution,r=this.view.height/this.resolution;this.screen.width=n,this.screen.height=r,this.autoDensity&&(this.view.style.width=n+"px",this.view.style.height=r+"px"),this.emit("resize",n,r)},e.prototype.generateTexture=function(t,e,n,r){void 0===e&&(e={}),"number"===typeof e&&((0,o.a1)("6.1.0","generateTexture options (scaleMode, resolution, region) are now object options."),e={scaleMode:e,resolution:n,region:r});var i=e.region,s=p(e,["region"]);r=i||t.getLocalBounds(null,!0),0===r.width&&(r.width=1),0===r.height&&(r.height=1);var a=B.create(d({width:r.width,height:r.height},s));return Ge.tx=-r.x,Ge.ty=-r.y,this.render(t,{renderTexture:a,clear:!1,transform:Ge,skipUpdateTransform:!!t.parent}),a},e.prototype.destroy=function(t){for(var e in this.plugins)this.plugins[e].destroy(),this.plugins[e]=null;t&&this.view.parentNode&&this.view.parentNode.removeChild(this.view);var n=this;n.plugins=null,n.type=i.N3.UNKNOWN,n.view=null,n.screen=null,n._tempDisplayObjectParent=null,n.options=null,this._backgroundColorRgba=null,this._backgroundColorString=null,this._lastObjectRendered=null},Object.defineProperty(e.prototype,"backgroundColor",{get:function(){return this._backgroundColor},set:function(t){this._backgroundColor=t,this._backgroundColorString=(0,o.XN)(t),(0,o.wK)(t,this._backgroundColorRgba)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"backgroundAlpha",{get:function(){return this._backgroundColorRgba[3]},set:function(t){this._backgroundColorRgba[3]=t},enumerable:!1,configurable:!0}),e}(o.vp),Xe=function(){function t(t){this.buffer=t||null,this.updateID=-1,this.byteLength=-1,this.refCount=0}return t}(),je=function(){function t(t){this.renderer=t,this.managedBuffers={},this.boundBufferBases={}}return t.prototype.destroy=function(){this.renderer=null},t.prototype.contextChange=function(){this.disposeAll(!0),this.gl=this.renderer.gl,this.CONTEXT_UID=this.renderer.CONTEXT_UID},t.prototype.bind=function(t){var e=this,n=e.gl,r=e.CONTEXT_UID,i=t._glBuffers[r]||this.createGLBuffer(t);n.bindBuffer(t.type,i.buffer)},t.prototype.bindBufferBase=function(t,e){var n=this,r=n.gl,i=n.CONTEXT_UID;if(this.boundBufferBases[e]!==t){var o=t._glBuffers[i]||this.createGLBuffer(t);this.boundBufferBases[e]=t,r.bindBufferBase(r.UNIFORM_BUFFER,e,o.buffer)}},t.prototype.bindBufferRange=function(t,e,n){var r=this,i=r.gl,o=r.CONTEXT_UID;n=n||0;var s=t._glBuffers[o]||this.createGLBuffer(t);i.bindBufferRange(i.UNIFORM_BUFFER,e||0,s.buffer,256*n,256)},t.prototype.update=function(t){var e=this,n=e.gl,r=e.CONTEXT_UID,i=t._glBuffers[r];if(t._updateID!==i.updateID)if(i.updateID=t._updateID,n.bindBuffer(t.type,i.buffer),i.byteLength>=t.data.byteLength)n.bufferSubData(t.type,0,t.data);else{var o=t.static?n.STATIC_DRAW:n.DYNAMIC_DRAW;i.byteLength=t.data.byteLength,n.bufferData(t.type,t.data,o)}},t.prototype.dispose=function(t,e){if(this.managedBuffers[t.id]){delete this.managedBuffers[t.id];var n=t._glBuffers[this.CONTEXT_UID],r=this.gl;t.disposeRunner.remove(this),n&&(e||r.deleteBuffer(n.buffer),delete t._glBuffers[this.CONTEXT_UID])}},t.prototype.disposeAll=function(t){for(var e=Object.keys(this.managedBuffers),n=0;n<e.length;n++)this.dispose(this.managedBuffers[e[n]],t)},t.prototype.createGLBuffer=function(t){var e=this,n=e.CONTEXT_UID,r=e.gl;return t._glBuffers[n]=new Xe(r.createBuffer()),this.managedBuffers[t.id]=t,t.disposeRunner.add(this),t._glBuffers[n]},t}(),He=function(t){function e(n){var r=t.call(this,i.N3.WEBGL,n)||this;return n=r.options,r.gl=null,r.CONTEXT_UID=0,r.runners={destroy:new s.R("destroy"),contextChange:new s.R("contextChange"),reset:new s.R("reset"),update:new s.R("update"),postrender:new s.R("postrender"),prerender:new s.R("prerender"),resize:new s.R("resize")},r.runners.contextChange.add(r),r.globalUniforms=new Z({projectionMatrix:new u.y3},!0),r.addSystem(ie,"mask").addSystem(ot,"context").addSystem(Me,"state").addSystem(Re,"shader").addSystem(Be,"texture").addSystem(je,"buffer").addSystem(ct,"geometry").addSystem(ut,"framebuffer").addSystem(ae,"scissor").addSystem(ue,"stencil").addSystem(le,"projection").addSystem(De,"textureGC").addSystem(et,"filter").addSystem(fe,"renderTexture").addSystem(rt,"batch"),r.initPlugins(e.__plugins),r.multisample=void 0,n.context?r.context.initFromContext(n.context):r.context.initFromOptions({alpha:!!r.useContextAlpha,antialias:n.antialias,premultipliedAlpha:r.useContextAlpha&&"notMultiplied"!==r.useContextAlpha,stencil:!0,preserveDrawingBuffer:n.preserveDrawingBuffer,powerPreference:r.options.powerPreference}),r.renderingToScreen=!0,(0,o.DE)(2===r.context.webGLVersion?"WebGL 2":"WebGL 1"),r.resize(r.options.width,r.options.height),r}return f(e,t),e.create=function(t){if((0,o.HR)())return new e(t);throw new Error('WebGL unsupported in this browser, use "pixi.js-legacy" for fallback canvas2d support.')},e.prototype.contextChange=function(){var t,e=this.gl;if(1===this.context.webGLVersion){var n=e.getParameter(e.FRAMEBUFFER_BINDING);e.bindFramebuffer(e.FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.FRAMEBUFFER,n)}else{n=e.getParameter(e.DRAW_FRAMEBUFFER_BINDING);e.bindFramebuffer(e.DRAW_FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.DRAW_FRAMEBUFFER,n)}t>=i.G5.HIGH?this.multisample=i.G5.HIGH:t>=i.G5.MEDIUM?this.multisample=i.G5.MEDIUM:t>=i.G5.LOW?this.multisample=i.G5.LOW:this.multisample=i.G5.NONE},e.prototype.addSystem=function(t,e){var n=new t(this);if(this[e])throw new Error('Whoops! The name "'+e+'" is already in use');for(var r in this[e]=n,this.runners)this.runners[r].add(n);return this},e.prototype.render=function(t,e){var n,r,i,s;if(e&&(e instanceof B?((0,o.a1)("6.0.0","Renderer#render arguments changed, use options instead."),n=e,r=arguments[2],i=arguments[3],s=arguments[4]):(n=e.renderTexture,r=e.clear,i=e.transform,s=e.skipUpdateTransform)),this.renderingToScreen=!n,this.runners.prerender.emit(),this.emit("prerender"),this.projection.transform=i,!this.context.isLost){if(n||(this._lastObjectRendered=t),!s){var a=t.enableTempParent();t.updateTransform(),t.disableTempParent(a)}this.renderTexture.bind(n),this.batch.currentRenderer.start(),(void 0!==r?r:this.clearBeforeRender)&&this.renderTexture.clear(),t.render(this),this.batch.currentRenderer.flush(),n&&n.baseTexture.update(),this.runners.postrender.emit(),this.projection.transform=null,this.emit("postrender")}},e.prototype.generateTexture=function(e,n,r,i){void 0===n&&(n={});var o=t.prototype.generateTexture.call(this,e,n,r,i);return this.framebuffer.blit(),o},e.prototype.resize=function(e,n){t.prototype.resize.call(this,e,n),this.runners.resize.emit(this.screen.height,this.screen.width)},e.prototype.reset=function(){return this.runners.reset.emit(),this},e.prototype.clear=function(){this.renderTexture.bind(),this.renderTexture.clear()},e.prototype.destroy=function(e){for(var n in this.runners.destroy.emit(),this.runners)this.runners[n].destroy();t.prototype.destroy.call(this,e),this.gl=null},Object.defineProperty(e.prototype,"extract",{get:function(){return(0,o.a1)("6.0.0","Renderer#extract has been deprecated, please use Renderer#plugins.extract instead."),this.plugins.extract},enumerable:!1,configurable:!0}),e.registerPlugin=function(t,n){e.__plugins=e.__plugins||{},e.__plugins[t]=n},e}(ke);function Ve(t){return He.create(t)}var Ye="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}",We="attribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvec2 filterTextureCoord( void )\n{\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n}\n\nvoid main(void)\n{\n gl_Position = filterVertexPosition();\n vTextureCoord = filterTextureCoord();\n}\n",ze=Ye,$e=We,qe=(function(){function t(t){(0,o.a1)("6.1.0","System class is deprecated, implemement ISystem interface instead."),this.renderer=t}t.prototype.destroy=function(){this.renderer=null}}(),function(){function t(){this.texArray=null,this.blend=0,this.type=i.lg.TRIANGLES,this.start=0,this.size=0,this.data=null}return t}()),Ke=function(){function t(){this.elements=[],this.ids=[],this.count=0}return t.prototype.clear=function(){for(var t=0;t<this.count;t++)this.elements[t]=null;this.count=0},t}(),Ze=function(){function t(t){"number"===typeof t?this.rawBinaryData=new ArrayBuffer(t):t instanceof Uint8Array?this.rawBinaryData=t.buffer:this.rawBinaryData=t,this.uint32View=new Uint32Array(this.rawBinaryData),this.float32View=new Float32Array(this.rawBinaryData)}return Object.defineProperty(t.prototype,"int8View",{get:function(){return this._int8View||(this._int8View=new Int8Array(this.rawBinaryData)),this._int8View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"uint8View",{get:function(){return this._uint8View||(this._uint8View=new Uint8Array(this.rawBinaryData)),this._uint8View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"int16View",{get:function(){return this._int16View||(this._int16View=new Int16Array(this.rawBinaryData)),this._int16View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"uint16View",{get:function(){return this._uint16View||(this._uint16View=new Uint16Array(this.rawBinaryData)),this._uint16View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"int32View",{get:function(){return this._int32View||(this._int32View=new Int32Array(this.rawBinaryData)),this._int32View},enumerable:!1,configurable:!0}),t.prototype.view=function(t){return this[t+"View"]},t.prototype.destroy=function(){this.rawBinaryData=null,this._int8View=null,this._uint8View=null,this._int16View=null,this._uint16View=null,this._int32View=null,this.uint32View=null,this.float32View=null},t.sizeOf=function(t){switch(t){case"int8":case"uint8":return 1;case"int16":case"uint16":return 2;case"int32":case"uint32":case"float32":return 4;default:throw new Error(t+" isn't a valid view type")}},t}(),Je=function(t){function e(e){var n=t.call(this,e)||this;return n.shaderGenerator=null,n.geometryClass=null,n.vertexSize=null,n.state=qt.for2d(),n.size=4*r.X.SPRITE_BATCH_SIZE,n._vertexCount=0,n._indexCount=0,n._bufferedElements=[],n._bufferedTextures=[],n._bufferSize=0,n._shader=null,n._packedGeometries=[],n._packedGeometryPoolSize=2,n._flushId=0,n._aBuffers={},n._iBuffers={},n.MAX_TEXTURES=1,n.renderer.on("prerender",n.onPrerender,n),e.runners.contextChange.add(n),n._dcIndex=0,n._aIndex=0,n._iIndex=0,n._attributeBuffer=null,n._indexBuffer=null,n._tempBoundTextures=[],n}return f(e,t),e.prototype.contextChange=function(){var t=this.renderer.gl;r.X.PREFER_ENV===i.Vi.WEBGL_LEGACY?this.MAX_TEXTURES=1:(this.MAX_TEXTURES=Math.min(t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS),r.X.SPRITE_MAX_TEXTURES),this.MAX_TEXTURES=Lt(this.MAX_TEXTURES,t)),this._shader=this.shaderGenerator.generateShader(this.MAX_TEXTURES);for(var e=0;e<this._packedGeometryPoolSize;e++)this._packedGeometries[e]=new this.geometryClass;this.initFlushBuffers()},e.prototype.initFlushBuffers=function(){var t=e._drawCallPool,n=e._textureArrayPool,r=this.size/4,i=Math.floor(r/this.MAX_TEXTURES)+1;while(t.length<r)t.push(new qe);while(n.length<i)n.push(new Ke);for(var o=0;o<this.MAX_TEXTURES;o++)this._tempBoundTextures[o]=null},e.prototype.onPrerender=function(){this._flushId=0},e.prototype.render=function(t){t._texture.valid&&(this._vertexCount+t.vertexData.length/2>this.size&&this.flush(),this._vertexCount+=t.vertexData.length/2,this._indexCount+=t.indices.length,this._bufferedTextures[this._bufferSize]=t._texture.baseTexture,this._bufferedElements[this._bufferSize++]=t)},e.prototype.buildTexturesAndDrawCalls=function(){var t=this,n=t._bufferedTextures,r=t.MAX_TEXTURES,i=e._textureArrayPool,o=this.renderer.batch,s=this._tempBoundTextures,a=this.renderer.textureGC.count,u=++_._globalBatch,l=0,c=i[0],h=0;o.copyBoundTextures(s,r);for(var f=0;f<this._bufferSize;++f){var d=n[f];n[f]=null,d._batchEnabled!==u&&(c.count>=r&&(o.boundArray(c,s,u,r),this.buildDrawCalls(c,h,f),h=f,c=i[++l],++u),d._batchEnabled=u,d.touched=a,c.elements[c.count++]=d)}c.count>0&&(o.boundArray(c,s,u,r),this.buildDrawCalls(c,h,this._bufferSize),++l,++u);for(f=0;f<s.length;f++)s[f]=null;_._globalBatch=u},e.prototype.buildDrawCalls=function(t,n,r){var i=this,s=i._bufferedElements,a=i._attributeBuffer,u=i._indexBuffer,l=i.vertexSize,c=e._drawCallPool,h=this._dcIndex,f=this._aIndex,d=this._iIndex,p=c[h];p.start=this._iIndex,p.texArray=t;for(var v=n;v<r;++v){var m=s[v],g=m._texture.baseTexture,_=o.YA[g.alphaMode?1:0][m.blendMode];s[v]=null,n<v&&p.blend!==_&&(p.size=d-p.start,n=v,p=c[++h],p.texArray=t,p.start=d),this.packInterleavedGeometry(m,a,u,f,d),f+=m.vertexData.length/2*l,d+=m.indices.length,p.blend=_}n<r&&(p.size=d-p.start,++h),this._dcIndex=h,this._aIndex=f,this._iIndex=d},e.prototype.bindAndClearTexArray=function(t){for(var e=this.renderer.texture,n=0;n<t.count;n++)e.bind(t.elements[n],t.ids[n]),t.elements[n]=null;t.count=0},e.prototype.updateGeometry=function(){var t=this,e=t._packedGeometries,n=t._attributeBuffer,i=t._indexBuffer;r.X.CAN_UPLOAD_SAME_BUFFER?(e[this._flushId]._buffer.update(n.rawBinaryData),e[this._flushId]._indexBuffer.update(i),this.renderer.geometry.updateBuffers()):(this._packedGeometryPoolSize<=this._flushId&&(this._packedGeometryPoolSize++,e[this._flushId]=new this.geometryClass),e[this._flushId]._buffer.update(n.rawBinaryData),e[this._flushId]._indexBuffer.update(i),this.renderer.geometry.bind(e[this._flushId]),this.renderer.geometry.updateBuffers(),this._flushId++)},e.prototype.drawBatches=function(){for(var t=this._dcIndex,n=this.renderer,r=n.gl,i=n.state,o=e._drawCallPool,s=null,a=0;a<t;a++){var u=o[a],l=u.texArray,c=u.type,h=u.size,f=u.start,d=u.blend;s!==l&&(s=l,this.bindAndClearTexArray(l)),this.state.blendMode=d,i.set(this.state),r.drawElements(c,h,r.UNSIGNED_SHORT,2*f)}},e.prototype.flush=function(){0!==this._vertexCount&&(this._attributeBuffer=this.getAttributeBuffer(this._vertexCount),this._indexBuffer=this.getIndexBuffer(this._indexCount),this._aIndex=0,this._iIndex=0,this._dcIndex=0,this.buildTexturesAndDrawCalls(),this.updateGeometry(),this.drawBatches(),this._bufferSize=0,this._vertexCount=0,this._indexCount=0)},e.prototype.start=function(){this.renderer.state.set(this.state),this.renderer.texture.ensureSamplerType(this.MAX_TEXTURES),this.renderer.shader.bind(this._shader),r.X.CAN_UPLOAD_SAME_BUFFER&&this.renderer.geometry.bind(this._packedGeometries[this._flushId])},e.prototype.stop=function(){this.flush()},e.prototype.destroy=function(){for(var e=0;e<this._packedGeometryPoolSize;e++)this._packedGeometries[e]&&this._packedGeometries[e].destroy();this.renderer.off("prerender",this.onPrerender,this),this._aBuffers=null,this._iBuffers=null,this._packedGeometries=null,this._attributeBuffer=null,this._indexBuffer=null,this._shader&&(this._shader.destroy(),this._shader=null),t.prototype.destroy.call(this)},e.prototype.getAttributeBuffer=function(t){var e=(0,o.a9)(Math.ceil(t/8)),n=(0,o.k3)(e),r=8*e;this._aBuffers.length<=n&&(this._iBuffers.length=n+1);var i=this._aBuffers[r];return i||(this._aBuffers[r]=i=new Ze(r*this.vertexSize*4)),i},e.prototype.getIndexBuffer=function(t){var e=(0,o.a9)(Math.ceil(t/12)),n=(0,o.k3)(e),r=12*e;this._iBuffers.length<=n&&(this._iBuffers.length=n+1);var i=this._iBuffers[n];return i||(this._iBuffers[n]=i=new Uint16Array(r)),i},e.prototype.packInterleavedGeometry=function(t,e,n,r,i){for(var s=e.uint32View,a=e.float32View,u=r/this.vertexSize,l=t.uvs,c=t.indices,h=t.vertexData,f=t._texture.baseTexture._batchLocation,d=Math.min(t.worldAlpha,1),p=d<1&&t._texture.baseTexture.alphaMode?(0,o.rA)(t._tintRGB,d):t._tintRGB+(255*d<<24),v=0;v<h.length;v+=2)a[r++]=h[v],a[r++]=h[v+1],a[r++]=l[v],a[r++]=l[v+1],s[r++]=p,a[r++]=f;for(v=0;v<c.length;v++)n[i++]=u+c[v]},e._drawCallPool=[],e._textureArrayPool=[],e}(nt),Qe=function(){function t(t,e){if(this.vertexSrc=t,this.fragTemplate=e,this.programCache={},this.defaultGroupCache={},e.indexOf("%count%")<0)throw new Error('Fragment template must contain "%count%".');if(e.indexOf("%forloop%")<0)throw new Error('Fragment template must contain "%forloop%".')}return t.prototype.generateShader=function(t){if(!this.programCache[t]){for(var e=new Int32Array(t),n=0;n<t;n++)e[n]=n;this.defaultGroupCache[t]=Z.from({uSamplers:e},!0);var r=this.fragTemplate;r=r.replace(/%count%/gi,""+t),r=r.replace(/%forloop%/gi,this.generateSampleSrc(t)),this.programCache[t]=new Xt(this.vertexSrc,r)}var i={tint:new Float32Array([1,1,1,1]),translationMatrix:new u.y3,default:this.defaultGroupCache[t]};return new jt(this.programCache[t],i)},t.prototype.generateSampleSrc=function(t){var e="";e+="\n",e+="\n";for(var n=0;n<t;n++)n>0&&(e+="\nelse "),n<t-1&&(e+="if(vTextureId < "+n+".5)"),e+="\n{",e+="\n\tcolor = texture2D(uSamplers["+n+"], vTextureCoord);",e+="\n}";return e+="\n",e+="\n",e},t}(),tn=function(t){function e(e){void 0===e&&(e=!1);var n=t.call(this)||this;return n._buffer=new X(null,e,!1),n._indexBuffer=new X(null,e,!0),n.addAttribute("aVertexPosition",n._buffer,2,!1,i.vK.FLOAT).addAttribute("aTextureCoord",n._buffer,2,!1,i.vK.FLOAT).addAttribute("aColor",n._buffer,4,!0,i.vK.UNSIGNED_BYTE).addAttribute("aTextureId",n._buffer,1,!0,i.vK.FLOAT).addIndex(n._indexBuffer),n}return f(e,t),e}(z),en="precision highp float;\nattribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\nattribute vec4 aColor;\nattribute float aTextureId;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform vec4 tint;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\nvarying float vTextureId;\n\nvoid main(void){\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vTextureId = aTextureId;\n vColor = aColor * tint;\n}\n",nn="varying vec2 vTextureCoord;\nvarying vec4 vColor;\nvarying float vTextureId;\nuniform sampler2D uSamplers[%count%];\n\nvoid main(void){\n vec4 color;\n %forloop%\n gl_FragColor = color * vColor;\n}\n",rn=function(){function t(){}return t.create=function(t){var e=Object.assign({vertex:en,fragment:nn,geometryClass:tn,vertexSize:6},t),n=e.vertex,r=e.fragment,i=e.vertexSize,o=e.geometryClass;return function(t){function e(e){var s=t.call(this,e)||this;return s.shaderGenerator=new Qe(n,r),s.geometryClass=o,s.vertexSize=i,s}return f(e,t),e}(Je)},Object.defineProperty(t,"defaultVertexSrc",{get:function(){return en},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultFragmentTemplate",{get:function(){return nn},enumerable:!1,configurable:!0}),t}(),on=rn.create(),sn={},an=function(t){Object.defineProperty(sn,t,{get:function(){return(0,o.a1)("6.0.0","PIXI.systems."+t+" has moved to PIXI."+t),w[t]}})};for(var un in w)an(un);var ln={},cn=function(t){Object.defineProperty(ln,t,{get:function(){return(0,o.a1)("6.0.0","PIXI.resources."+t+" has moved to PIXI."+t),Ue[t]}})};for(var un in Ue)cn(un)},1585:function(t,e,n){"use strict";n.d(e,{YZ:function(){return s},W2:function(){return C},s$:function(){return w},Ql:function(){return I}});var r=n(1576),i=n(9658),o=n(8942); -/*! - * @pixi/display - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/display is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -r.X.SORTABLE_CHILDREN=!1;var s=function(){function t(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0,this.rect=null,this.updateID=-1}return t.prototype.isEmpty=function(){return this.minX>this.maxX||this.minY>this.maxY},t.prototype.clear=function(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0},t.prototype.getRectangle=function(t){return this.minX>this.maxX||this.minY>this.maxY?i.Ae.EMPTY:(t=t||new i.Ae(0,0,1,1),t.x=this.minX,t.y=this.minY,t.width=this.maxX-this.minX,t.height=this.maxY-this.minY,t)},t.prototype.addPoint=function(t){this.minX=Math.min(this.minX,t.x),this.maxX=Math.max(this.maxX,t.x),this.minY=Math.min(this.minY,t.y),this.maxY=Math.max(this.maxY,t.y)},t.prototype.addPointMatrix=function(t,e){var n=t.a,r=t.b,i=t.c,o=t.d,s=t.tx,a=t.ty,u=n*e.x+i*e.y+s,l=r*e.x+o*e.y+a;this.minX=Math.min(this.minX,u),this.maxX=Math.max(this.maxX,u),this.minY=Math.min(this.minY,l),this.maxY=Math.max(this.maxY,l)},t.prototype.addQuad=function(t){var e=this.minX,n=this.minY,r=this.maxX,i=this.maxY,o=t[0],s=t[1];e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,o=t[2],s=t[3],e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,o=t[4],s=t[5],e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,o=t[6],s=t[7],e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,this.minX=e,this.minY=n,this.maxX=r,this.maxY=i},t.prototype.addFrame=function(t,e,n,r,i){this.addFrameMatrix(t.worldTransform,e,n,r,i)},t.prototype.addFrameMatrix=function(t,e,n,r,i){var o=t.a,s=t.b,a=t.c,u=t.d,l=t.tx,c=t.ty,h=this.minX,f=this.minY,d=this.maxX,p=this.maxY,v=o*e+a*n+l,m=s*e+u*n+c;h=v<h?v:h,f=m<f?m:f,d=v>d?v:d,p=m>p?m:p,v=o*r+a*n+l,m=s*r+u*n+c,h=v<h?v:h,f=m<f?m:f,d=v>d?v:d,p=m>p?m:p,v=o*e+a*i+l,m=s*e+u*i+c,h=v<h?v:h,f=m<f?m:f,d=v>d?v:d,p=m>p?m:p,v=o*r+a*i+l,m=s*r+u*i+c,h=v<h?v:h,f=m<f?m:f,d=v>d?v:d,p=m>p?m:p,this.minX=h,this.minY=f,this.maxX=d,this.maxY=p},t.prototype.addVertexData=function(t,e,n){for(var r=this.minX,i=this.minY,o=this.maxX,s=this.maxY,a=e;a<n;a+=2){var u=t[a],l=t[a+1];r=u<r?u:r,i=l<i?l:i,o=u>o?u:o,s=l>s?l:s}this.minX=r,this.minY=i,this.maxX=o,this.maxY=s},t.prototype.addVertices=function(t,e,n,r){this.addVerticesMatrix(t.worldTransform,e,n,r)},t.prototype.addVerticesMatrix=function(t,e,n,r,i,o){void 0===i&&(i=0),void 0===o&&(o=i);for(var s=t.a,a=t.b,u=t.c,l=t.d,c=t.tx,h=t.ty,f=this.minX,d=this.minY,p=this.maxX,v=this.maxY,m=n;m<r;m+=2){var g=e[m],_=e[m+1],y=s*g+u*_+c,b=l*_+a*g+h;f=Math.min(f,y-i),p=Math.max(p,y+i),d=Math.min(d,b-o),v=Math.max(v,b+o)}this.minX=f,this.minY=d,this.maxX=p,this.maxY=v},t.prototype.addBounds=function(t){var e=this.minX,n=this.minY,r=this.maxX,i=this.maxY;this.minX=t.minX<e?t.minX:e,this.minY=t.minY<n?t.minY:n,this.maxX=t.maxX>r?t.maxX:r,this.maxY=t.maxY>i?t.maxY:i},t.prototype.addBoundsMask=function(t,e){var n=t.minX>e.minX?t.minX:e.minX,r=t.minY>e.minY?t.minY:e.minY,i=t.maxX<e.maxX?t.maxX:e.maxX,o=t.maxY<e.maxY?t.maxY:e.maxY;if(n<=i&&r<=o){var s=this.minX,a=this.minY,u=this.maxX,l=this.maxY;this.minX=n<s?n:s,this.minY=r<a?r:a,this.maxX=i>u?i:u,this.maxY=o>l?o:l}},t.prototype.addBoundsMatrix=function(t,e){this.addFrameMatrix(e,t.minX,t.minY,t.maxX,t.maxY)},t.prototype.addBoundsArea=function(t,e){var n=t.minX>e.x?t.minX:e.x,r=t.minY>e.y?t.minY:e.y,i=t.maxX<e.x+e.width?t.maxX:e.x+e.width,o=t.maxY<e.y+e.height?t.maxY:e.y+e.height;if(n<=i&&r<=o){var s=this.minX,a=this.minY,u=this.maxX,l=this.maxY;this.minX=n<s?n:s,this.minY=r<a?r:a,this.maxX=i>u?i:u,this.maxY=o>l?o:l}},t.prototype.pad=function(t,e){void 0===t&&(t=0),void 0===e&&(e=t),this.isEmpty()||(this.minX-=t,this.maxX+=t,this.minY-=e,this.maxY+=e)},t.prototype.addFramePad=function(t,e,n,r,i,o){t-=i,e-=o,n+=i,r+=o,this.minX=this.minX<t?this.minX:t,this.maxX=this.maxX>n?this.maxX:n,this.minY=this.minY<e?this.minY:e,this.maxY=this.maxY>r?this.maxY:r},t}(),a=function(t,e){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},a(t,e)}; -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */function u(t,e){function n(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var l,c,h,f,d,p,v,m,g,_,y,b,E,x,T,S,R,A,O,w=function(t){function e(){var e=t.call(this)||this;return e.tempDisplayObjectParent=null,e.transform=new i.wx,e.alpha=1,e.visible=!0,e.renderable=!0,e.cullable=!1,e.cullArea=null,e.parent=null,e.worldAlpha=1,e._lastSortedIndex=0,e._zIndex=0,e.filterArea=null,e.filters=null,e._enabledFilters=null,e._bounds=new s,e._localBounds=null,e._boundsID=0,e._boundsRect=null,e._localBoundsRect=null,e._mask=null,e._maskRefCount=0,e._destroyed=!1,e.isSprite=!1,e.isMask=!1,e}return u(e,t),e.mixin=function(t){for(var n=Object.keys(t),r=0;r<n.length;++r){var i=n[r];Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t,i))}},Object.defineProperty(e.prototype,"destroyed",{get:function(){return this._destroyed},enumerable:!1,configurable:!0}),e.prototype._recursivePostUpdateTransform=function(){this.parent?(this.parent._recursivePostUpdateTransform(),this.transform.updateTransform(this.parent.transform)):this.transform.updateTransform(this._tempDisplayObjectParent.transform)},e.prototype.updateTransform=function(){this._boundsID++,this.transform.updateTransform(this.parent.transform),this.worldAlpha=this.alpha*this.parent.worldAlpha},e.prototype.getBounds=function(t,e){return t||(this.parent?(this._recursivePostUpdateTransform(),this.updateTransform()):(this.parent=this._tempDisplayObjectParent,this.updateTransform(),this.parent=null)),this._bounds.updateID!==this._boundsID&&(this.calculateBounds(),this._bounds.updateID=this._boundsID),e||(this._boundsRect||(this._boundsRect=new i.Ae),e=this._boundsRect),this._bounds.getRectangle(e)},e.prototype.getLocalBounds=function(t){t||(this._localBoundsRect||(this._localBoundsRect=new i.Ae),t=this._localBoundsRect),this._localBounds||(this._localBounds=new s);var e=this.transform,n=this.parent;this.parent=null,this.transform=this._tempDisplayObjectParent.transform;var r=this._bounds,o=this._boundsID;this._bounds=this._localBounds;var a=this.getBounds(!1,t);return this.parent=n,this.transform=e,this._bounds=r,this._bounds.updateID+=this._boundsID-o,a},e.prototype.toGlobal=function(t,e,n){return void 0===n&&(n=!1),n||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.apply(t,e)},e.prototype.toLocal=function(t,e,n,r){return e&&(t=e.toGlobal(t,n,r)),r||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.applyInverse(t,n)},e.prototype.setParent=function(t){if(!t||!t.addChild)throw new Error("setParent: Argument must be a Container");return t.addChild(this),t},e.prototype.setTransform=function(t,e,n,r,i,o,s,a,u){return void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=1),void 0===r&&(r=1),void 0===i&&(i=0),void 0===o&&(o=0),void 0===s&&(s=0),void 0===a&&(a=0),void 0===u&&(u=0),this.position.x=t,this.position.y=e,this.scale.x=n||1,this.scale.y=r||1,this.rotation=i,this.skew.x=o,this.skew.y=s,this.pivot.x=a,this.pivot.y=u,this},e.prototype.destroy=function(t){this.parent&&this.parent.removeChild(this),this.emit("destroyed"),this.removeAllListeners(),this.transform=null,this.parent=null,this._bounds=null,this.mask=null,this.cullArea=null,this.filters=null,this.filterArea=null,this.hitArea=null,this.interactive=!1,this.interactiveChildren=!1,this._destroyed=!0},Object.defineProperty(e.prototype,"_tempDisplayObjectParent",{get:function(){return null===this.tempDisplayObjectParent&&(this.tempDisplayObjectParent=new I),this.tempDisplayObjectParent},enumerable:!1,configurable:!0}),e.prototype.enableTempParent=function(){var t=this.parent;return this.parent=this._tempDisplayObjectParent,t},e.prototype.disableTempParent=function(t){this.parent=t},Object.defineProperty(e.prototype,"x",{get:function(){return this.position.x},set:function(t){this.transform.position.x=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"y",{get:function(){return this.position.y},set:function(t){this.transform.position.y=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"worldTransform",{get:function(){return this.transform.worldTransform},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"localTransform",{get:function(){return this.transform.localTransform},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"position",{get:function(){return this.transform.position},set:function(t){this.transform.position.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"scale",{get:function(){return this.transform.scale},set:function(t){this.transform.scale.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"pivot",{get:function(){return this.transform.pivot},set:function(t){this.transform.pivot.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"skew",{get:function(){return this.transform.skew},set:function(t){this.transform.skew.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rotation",{get:function(){return this.transform.rotation},set:function(t){this.transform.rotation=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angle",{get:function(){return this.transform.rotation*i.jl},set:function(t){this.transform.rotation=t*i.ZX},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"zIndex",{get:function(){return this._zIndex},set:function(t){this._zIndex=t,this.parent&&(this.parent.sortDirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"worldVisible",{get:function(){var t=this;do{if(!t.visible)return!1;t=t.parent}while(t);return!0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"mask",{get:function(){return this._mask},set:function(t){if(this._mask!==t){if(this._mask){var e=this._mask.maskObject||this._mask;e._maskRefCount--,0===e._maskRefCount&&(e.renderable=!0,e.isMask=!1)}if(this._mask=t,this._mask){e=this._mask.maskObject||this._mask;0===e._maskRefCount&&(e.renderable=!1,e.isMask=!0),e._maskRefCount++}}},enumerable:!1,configurable:!0}),e}(o.vp),I=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.sortDirty=null,e}return u(e,t),e}(w);function P(t,e){return t.zIndex===e.zIndex?t._lastSortedIndex-e._lastSortedIndex:t.zIndex-e.zIndex}w.prototype.displayObjectUpdateTransform=w.prototype.updateTransform,function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"}(l||(l={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(c||(c={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(h||(h={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(f||(f={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(d||(d={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(p||(p={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(v||(v={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(m||(m={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(g||(g={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(_||(_={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(y||(y={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(b||(b={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(E||(E={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(x||(x={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(T||(T={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(S||(S={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(R||(R={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(A||(A={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(O||(O={}));var C=function(t){function e(){var e=t.call(this)||this;return e.children=[],e.sortableChildren=r.X.SORTABLE_CHILDREN,e.sortDirty=!1,e}return u(e,t),e.prototype.onChildrenChange=function(t){},e.prototype.addChild=function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];if(e.length>1)for(var r=0;r<e.length;r++)this.addChild(e[r]);else{var i=e[0];i.parent&&i.parent.removeChild(i),i.parent=this,this.sortDirty=!0,i.transform._parentID=-1,this.children.push(i),this._boundsID++,this.onChildrenChange(this.children.length-1),this.emit("childAdded",i,this,this.children.length-1),i.emit("added",this)}return e[0]},e.prototype.addChildAt=function(t,e){if(e<0||e>this.children.length)throw new Error(t+"addChildAt: The index "+e+" supplied is out of bounds "+this.children.length);return t.parent&&t.parent.removeChild(t),t.parent=this,this.sortDirty=!0,t.transform._parentID=-1,this.children.splice(e,0,t),this._boundsID++,this.onChildrenChange(e),t.emit("added",this),this.emit("childAdded",t,this,e),t},e.prototype.swapChildren=function(t,e){if(t!==e){var n=this.getChildIndex(t),r=this.getChildIndex(e);this.children[n]=e,this.children[r]=t,this.onChildrenChange(n<r?n:r)}},e.prototype.getChildIndex=function(t){var e=this.children.indexOf(t);if(-1===e)throw new Error("The supplied DisplayObject must be a child of the caller");return e},e.prototype.setChildIndex=function(t,e){if(e<0||e>=this.children.length)throw new Error("The index "+e+" supplied is out of bounds "+this.children.length);var n=this.getChildIndex(t);(0,o.Er)(this.children,n,1),this.children.splice(e,0,t),this.onChildrenChange(e)},e.prototype.getChildAt=function(t){if(t<0||t>=this.children.length)throw new Error("getChildAt: Index ("+t+") does not exist.");return this.children[t]},e.prototype.removeChild=function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];if(e.length>1)for(var r=0;r<e.length;r++)this.removeChild(e[r]);else{var i=e[0],s=this.children.indexOf(i);if(-1===s)return null;i.parent=null,i.transform._parentID=-1,(0,o.Er)(this.children,s,1),this._boundsID++,this.onChildrenChange(s),i.emit("removed",this),this.emit("childRemoved",i,this,s)}return e[0]},e.prototype.removeChildAt=function(t){var e=this.getChildAt(t);return e.parent=null,e.transform._parentID=-1,(0,o.Er)(this.children,t,1),this._boundsID++,this.onChildrenChange(t),e.emit("removed",this),this.emit("childRemoved",e,this,t),e},e.prototype.removeChildren=function(t,e){void 0===t&&(t=0),void 0===e&&(e=this.children.length);var n,r=t,i=e,o=i-r;if(o>0&&o<=i){n=this.children.splice(r,o);for(var s=0;s<n.length;++s)n[s].parent=null,n[s].transform&&(n[s].transform._parentID=-1);this._boundsID++,this.onChildrenChange(t);for(s=0;s<n.length;++s)n[s].emit("removed",this),this.emit("childRemoved",n[s],this,s);return n}if(0===o&&0===this.children.length)return[];throw new RangeError("removeChildren: numeric values are outside the acceptable range.")},e.prototype.sortChildren=function(){for(var t=!1,e=0,n=this.children.length;e<n;++e){var r=this.children[e];r._lastSortedIndex=e,t||0===r.zIndex||(t=!0)}t&&this.children.length>1&&this.children.sort(P),this.sortDirty=!1},e.prototype.updateTransform=function(){this.sortableChildren&&this.sortDirty&&this.sortChildren(),this._boundsID++,this.transform.updateTransform(this.parent.transform),this.worldAlpha=this.alpha*this.parent.worldAlpha;for(var t=0,e=this.children.length;t<e;++t){var n=this.children[t];n.visible&&n.updateTransform()}},e.prototype.calculateBounds=function(){this._bounds.clear(),this._calculateBounds();for(var t=0;t<this.children.length;t++){var e=this.children[t];if(e.visible&&e.renderable)if(e.calculateBounds(),e._mask){var n=e._mask.maskObject||e._mask;n.calculateBounds(),this._bounds.addBoundsMask(e._bounds,n._bounds)}else e.filterArea?this._bounds.addBoundsArea(e._bounds,e.filterArea):this._bounds.addBounds(e._bounds)}this._bounds.updateID=this._boundsID},e.prototype.getLocalBounds=function(e,n){void 0===n&&(n=!1);var r=t.prototype.getLocalBounds.call(this,e);if(!n)for(var i=0,o=this.children.length;i<o;++i){var s=this.children[i];s.visible&&s.updateTransform()}return r},e.prototype._calculateBounds=function(){},e.prototype._renderWithCulling=function(t){var n=t.renderTexture.sourceFrame;if(n.width>0&&n.height>0){var r,i;if(this.cullArea?(r=this.cullArea,i=this.worldTransform):this._render!==e.prototype._render&&(r=this.getBounds(!0)),r&&n.intersects(r,i))this._render(t);else if(this.cullArea)return;for(var o=0,s=this.children.length;o<s;++o){var a=this.children[o],u=a.cullable;a.cullable=u||!this.cullArea,a.render(t),a.cullable=u}}},e.prototype.render=function(t){if(this.visible&&!(this.worldAlpha<=0)&&this.renderable)if(this._mask||this.filters&&this.filters.length)this.renderAdvanced(t);else if(this.cullable)this._renderWithCulling(t);else{this._render(t);for(var e=0,n=this.children.length;e<n;++e)this.children[e].render(t)}},e.prototype.renderAdvanced=function(t){var e=this.filters,n=this._mask;if(e){this._enabledFilters||(this._enabledFilters=[]),this._enabledFilters.length=0;for(var r=0;r<e.length;r++)e[r].enabled&&this._enabledFilters.push(e[r])}var i=e&&this._enabledFilters&&this._enabledFilters.length||n&&(!n.isMaskData||n.enabled&&(n.autoDetect||n.type!==R.NONE));if(i&&t.batch.flush(),e&&this._enabledFilters&&this._enabledFilters.length&&t.filter.push(this,this._enabledFilters),n&&t.mask.push(this,this._mask),this.cullable)this._renderWithCulling(t);else{this._render(t);r=0;for(var o=this.children.length;r<o;++r)this.children[r].render(t)}i&&t.batch.flush(),n&&t.mask.pop(this),e&&this._enabledFilters&&this._enabledFilters.length&&t.filter.pop()},e.prototype._render=function(t){},e.prototype.destroy=function(e){t.prototype.destroy.call(this),this.sortDirty=!1;var n="boolean"===typeof e?e:e&&e.children,r=this.removeChildren(0,this.children.length);if(n)for(var i=0;i<r.length;++i)r[i].destroy(e)},Object.defineProperty(e.prototype,"width",{get:function(){return this.scale.x*this.getLocalBounds().width},set:function(t){var e=this.getLocalBounds().width;this.scale.x=0!==e?t/e:1,this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.scale.y*this.getLocalBounds().height},set:function(t){var e=this.getLocalBounds().height;this.scale.y=0!==e?t/e:1,this._height=t},enumerable:!1,configurable:!0}),e}(w);C.prototype.containerUpdateTransform=C.prototype.updateTransform},9658:function(t,e,n){"use strict";n.d(e,{Cd:function(){return c},ZX:function(){return s},Pj:function(){return h},y3:function(){return v},AB:function(){return p},_b:function(){return i},E9:function(){return a},mg:function(){return f},jl:function(){return o},Ae:function(){return l},c9:function(){return d},HS:function(){return r},wx:function(){return R},Lv:function(){return S}}); -/*! - * @pixi/math - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/math is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var r,i=2*Math.PI,o=180/Math.PI,s=Math.PI/180;(function(t){t[t["POLY"]=0]="POLY",t[t["RECT"]=1]="RECT",t[t["CIRC"]=2]="CIRC",t[t["ELIP"]=3]="ELIP",t[t["RREC"]=4]="RREC"})(r||(r={}));var a=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.x=0,this.y=0,this.x=t,this.y=e}return t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.copyFrom=function(t){return this.set(t.x,t.y),this},t.prototype.copyTo=function(t){return t.set(this.x,this.y),t},t.prototype.equals=function(t){return t.x===this.x&&t.y===this.y},t.prototype.set=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=t),this.x=t,this.y=e,this},t.prototype.toString=function(){return"[@pixi/math:Point x="+this.x+" y="+this.y+"]"},t}(),u=[new a,new a,new a,new a],l=function(){function t(t,e,n,i){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=0),this.x=Number(t),this.y=Number(e),this.width=Number(n),this.height=Number(i),this.type=r.RECT}return Object.defineProperty(t.prototype,"left",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"right",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"top",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"bottom",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),Object.defineProperty(t,"EMPTY",{get:function(){return new t(0,0,0,0)},enumerable:!1,configurable:!0}),t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.copyFrom=function(t){return this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height,this},t.prototype.copyTo=function(t){return t.x=this.x,t.y=this.y,t.width=this.width,t.height=this.height,t},t.prototype.contains=function(t,e){return!(this.width<=0||this.height<=0)&&(t>=this.x&&t<this.x+this.width&&e>=this.y&&e<this.y+this.height)},t.prototype.intersects=function(t,e){if(!e){var n=this.x<t.x?t.x:this.x,r=this.right>t.right?t.right:this.right;if(r<=n)return!1;var i=this.y<t.y?t.y:this.y,o=this.bottom>t.bottom?t.bottom:this.bottom;return o>i}var s=this.left,a=this.right,l=this.top,c=this.bottom;if(a<=s||c<=l)return!1;var h=u[0].set(t.left,t.top),f=u[1].set(t.left,t.bottom),d=u[2].set(t.right,t.top),p=u[3].set(t.right,t.bottom);if(d.x<=h.x||f.y<=h.y)return!1;var v=Math.sign(e.a*e.d-e.b*e.c);if(0===v)return!1;if(e.apply(h,h),e.apply(f,f),e.apply(d,d),e.apply(p,p),Math.max(h.x,f.x,d.x,p.x)<=s||Math.min(h.x,f.x,d.x,p.x)>=a||Math.max(h.y,f.y,d.y,p.y)<=l||Math.min(h.y,f.y,d.y,p.y)>=c)return!1;var m=v*(f.y-h.y),g=v*(h.x-f.x),_=m*s+g*l,y=m*a+g*l,b=m*s+g*c,E=m*a+g*c;if(Math.max(_,y,b,E)<=m*h.x+g*h.y||Math.min(_,y,b,E)>=m*p.x+g*p.y)return!1;var x=v*(h.y-d.y),T=v*(d.x-h.x),S=x*s+T*l,R=x*a+T*l,A=x*s+T*c,O=x*a+T*c;return!(Math.max(S,R,A,O)<=x*h.x+T*h.y||Math.min(S,R,A,O)>=x*p.x+T*p.y)},t.prototype.pad=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=t),this.x-=t,this.y-=e,this.width+=2*t,this.height+=2*e,this},t.prototype.fit=function(t){var e=Math.max(this.x,t.x),n=Math.min(this.x+this.width,t.x+t.width),r=Math.max(this.y,t.y),i=Math.min(this.y+this.height,t.y+t.height);return this.x=e,this.width=Math.max(n-e,0),this.y=r,this.height=Math.max(i-r,0),this},t.prototype.ceil=function(t,e){void 0===t&&(t=1),void 0===e&&(e=.001);var n=Math.ceil((this.x+this.width-e)*t)/t,r=Math.ceil((this.y+this.height-e)*t)/t;return this.x=Math.floor((this.x+e)*t)/t,this.y=Math.floor((this.y+e)*t)/t,this.width=n-this.x,this.height=r-this.y,this},t.prototype.enlarge=function(t){var e=Math.min(this.x,t.x),n=Math.max(this.x+this.width,t.x+t.width),r=Math.min(this.y,t.y),i=Math.max(this.y+this.height,t.y+t.height);return this.x=e,this.width=n-e,this.y=r,this.height=i-r,this},t.prototype.toString=function(){return"[@pixi/math:Rectangle x="+this.x+" y="+this.y+" width="+this.width+" height="+this.height+"]"},t}(),c=function(){function t(t,e,n){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),this.x=t,this.y=e,this.radius=n,this.type=r.CIRC}return t.prototype.clone=function(){return new t(this.x,this.y,this.radius)},t.prototype.contains=function(t,e){if(this.radius<=0)return!1;var n=this.radius*this.radius,r=this.x-t,i=this.y-e;return r*=r,i*=i,r+i<=n},t.prototype.getBounds=function(){return new l(this.x-this.radius,this.y-this.radius,2*this.radius,2*this.radius)},t.prototype.toString=function(){return"[@pixi/math:Circle x="+this.x+" y="+this.y+" radius="+this.radius+"]"},t}(),h=function(){function t(t,e,n,i){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=0),this.x=t,this.y=e,this.width=n,this.height=i,this.type=r.ELIP}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;var n=(t-this.x)/this.width,r=(e-this.y)/this.height;return n*=n,r*=r,n+r<=1},t.prototype.getBounds=function(){return new l(this.x-this.width,this.y-this.height,this.width,this.height)},t.prototype.toString=function(){return"[@pixi/math:Ellipse x="+this.x+" y="+this.y+" width="+this.width+" height="+this.height+"]"},t}(),f=function(){function t(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];var i=Array.isArray(e[0])?e[0]:e;if("number"!==typeof i[0]){for(var o=[],s=0,a=i.length;s<a;s++)o.push(i[s].x,i[s].y);i=o}this.points=i,this.type=r.POLY,this.closeStroke=!0}return t.prototype.clone=function(){var e=this.points.slice(),n=new t(e);return n.closeStroke=this.closeStroke,n},t.prototype.contains=function(t,e){for(var n=!1,r=this.points.length/2,i=0,o=r-1;i<r;o=i++){var s=this.points[2*i],a=this.points[2*i+1],u=this.points[2*o],l=this.points[2*o+1],c=a>e!==l>e&&t<(e-a)/(l-a)*(u-s)+s;c&&(n=!n)}return n},t.prototype.toString=function(){return"[@pixi/math:PolygoncloseStroke="+this.closeStroke+"points="+this.points.reduce((function(t,e){return t+", "+e}),"")+"]"},t}(),d=function(){function t(t,e,n,i,o){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=0),void 0===o&&(o=20),this.x=t,this.y=e,this.width=n,this.height=i,this.radius=o,this.type=r.RREC}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height,this.radius)},t.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;if(t>=this.x&&t<=this.x+this.width&&e>=this.y&&e<=this.y+this.height){var n=Math.max(0,Math.min(this.radius,Math.min(this.width,this.height)/2));if(e>=this.y+n&&e<=this.y+this.height-n||t>=this.x+n&&t<=this.x+this.width-n)return!0;var r=t-(this.x+n),i=e-(this.y+n),o=n*n;if(r*r+i*i<=o)return!0;if(r=t-(this.x+this.width-n),r*r+i*i<=o)return!0;if(i=e-(this.y+this.height-n),r*r+i*i<=o)return!0;if(r=t-(this.x+n),r*r+i*i<=o)return!0}return!1},t.prototype.toString=function(){return"[@pixi/math:RoundedRectangle x="+this.x+" y="+this.y+"width="+this.width+" height="+this.height+" radius="+this.radius+"]"},t}(),p=function(){function t(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),this._x=n,this._y=r,this.cb=t,this.scope=e}return t.prototype.clone=function(e,n){return void 0===e&&(e=this.cb),void 0===n&&(n=this.scope),new t(e,n,this._x,this._y)},t.prototype.set=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=t),this._x===t&&this._y===e||(this._x=t,this._y=e,this.cb.call(this.scope)),this},t.prototype.copyFrom=function(t){return this._x===t.x&&this._y===t.y||(this._x=t.x,this._y=t.y,this.cb.call(this.scope)),this},t.prototype.copyTo=function(t){return t.set(this._x,this._y),t},t.prototype.equals=function(t){return t.x===this._x&&t.y===this._y},t.prototype.toString=function(){return"[@pixi/math:ObservablePoint x=0 y=0 scope="+this.scope+"]"},Object.defineProperty(t.prototype,"x",{get:function(){return this._x},set:function(t){this._x!==t&&(this._x=t,this.cb.call(this.scope))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"y",{get:function(){return this._y},set:function(t){this._y!==t&&(this._y=t,this.cb.call(this.scope))},enumerable:!1,configurable:!0}),t}(),v=function(){function t(t,e,n,r,i,o){void 0===t&&(t=1),void 0===e&&(e=0),void 0===n&&(n=0),void 0===r&&(r=1),void 0===i&&(i=0),void 0===o&&(o=0),this.array=null,this.a=t,this.b=e,this.c=n,this.d=r,this.tx=i,this.ty=o}return t.prototype.fromArray=function(t){this.a=t[0],this.b=t[1],this.c=t[3],this.d=t[4],this.tx=t[2],this.ty=t[5]},t.prototype.set=function(t,e,n,r,i,o){return this.a=t,this.b=e,this.c=n,this.d=r,this.tx=i,this.ty=o,this},t.prototype.toArray=function(t,e){this.array||(this.array=new Float32Array(9));var n=e||this.array;return t?(n[0]=this.a,n[1]=this.b,n[2]=0,n[3]=this.c,n[4]=this.d,n[5]=0,n[6]=this.tx,n[7]=this.ty,n[8]=1):(n[0]=this.a,n[1]=this.c,n[2]=this.tx,n[3]=this.b,n[4]=this.d,n[5]=this.ty,n[6]=0,n[7]=0,n[8]=1),n},t.prototype.apply=function(t,e){e=e||new a;var n=t.x,r=t.y;return e.x=this.a*n+this.c*r+this.tx,e.y=this.b*n+this.d*r+this.ty,e},t.prototype.applyInverse=function(t,e){e=e||new a;var n=1/(this.a*this.d+this.c*-this.b),r=t.x,i=t.y;return e.x=this.d*n*r+-this.c*n*i+(this.ty*this.c-this.tx*this.d)*n,e.y=this.a*n*i+-this.b*n*r+(-this.ty*this.a+this.tx*this.b)*n,e},t.prototype.translate=function(t,e){return this.tx+=t,this.ty+=e,this},t.prototype.scale=function(t,e){return this.a*=t,this.d*=e,this.c*=t,this.b*=e,this.tx*=t,this.ty*=e,this},t.prototype.rotate=function(t){var e=Math.cos(t),n=Math.sin(t),r=this.a,i=this.c,o=this.tx;return this.a=r*e-this.b*n,this.b=r*n+this.b*e,this.c=i*e-this.d*n,this.d=i*n+this.d*e,this.tx=o*e-this.ty*n,this.ty=o*n+this.ty*e,this},t.prototype.append=function(t){var e=this.a,n=this.b,r=this.c,i=this.d;return this.a=t.a*e+t.b*r,this.b=t.a*n+t.b*i,this.c=t.c*e+t.d*r,this.d=t.c*n+t.d*i,this.tx=t.tx*e+t.ty*r+this.tx,this.ty=t.tx*n+t.ty*i+this.ty,this},t.prototype.setTransform=function(t,e,n,r,i,o,s,a,u){return this.a=Math.cos(s+u)*i,this.b=Math.sin(s+u)*i,this.c=-Math.sin(s-a)*o,this.d=Math.cos(s-a)*o,this.tx=t-(n*this.a+r*this.c),this.ty=e-(n*this.b+r*this.d),this},t.prototype.prepend=function(t){var e=this.tx;if(1!==t.a||0!==t.b||0!==t.c||1!==t.d){var n=this.a,r=this.c;this.a=n*t.a+this.b*t.c,this.b=n*t.b+this.b*t.d,this.c=r*t.a+this.d*t.c,this.d=r*t.b+this.d*t.d}return this.tx=e*t.a+this.ty*t.c+t.tx,this.ty=e*t.b+this.ty*t.d+t.ty,this},t.prototype.decompose=function(t){var e=this.a,n=this.b,r=this.c,o=this.d,s=t.pivot,a=-Math.atan2(-r,o),u=Math.atan2(n,e),l=Math.abs(a+u);return l<1e-5||Math.abs(i-l)<1e-5?(t.rotation=u,t.skew.x=t.skew.y=0):(t.rotation=0,t.skew.x=a,t.skew.y=u),t.scale.x=Math.sqrt(e*e+n*n),t.scale.y=Math.sqrt(r*r+o*o),t.position.x=this.tx+(s.x*e+s.y*r),t.position.y=this.ty+(s.x*n+s.y*o),t},t.prototype.invert=function(){var t=this.a,e=this.b,n=this.c,r=this.d,i=this.tx,o=t*r-e*n;return this.a=r/o,this.b=-e/o,this.c=-n/o,this.d=t/o,this.tx=(n*this.ty-r*i)/o,this.ty=-(t*this.ty-e*i)/o,this},t.prototype.identity=function(){return this.a=1,this.b=0,this.c=0,this.d=1,this.tx=0,this.ty=0,this},t.prototype.clone=function(){var e=new t;return e.a=this.a,e.b=this.b,e.c=this.c,e.d=this.d,e.tx=this.tx,e.ty=this.ty,e},t.prototype.copyTo=function(t){return t.a=this.a,t.b=this.b,t.c=this.c,t.d=this.d,t.tx=this.tx,t.ty=this.ty,t},t.prototype.copyFrom=function(t){return this.a=t.a,this.b=t.b,this.c=t.c,this.d=t.d,this.tx=t.tx,this.ty=t.ty,this},t.prototype.toString=function(){return"[@pixi/math:Matrix a="+this.a+" b="+this.b+" c="+this.c+" d="+this.d+" tx="+this.tx+" ty="+this.ty+"]"},Object.defineProperty(t,"IDENTITY",{get:function(){return new t},enumerable:!1,configurable:!0}),Object.defineProperty(t,"TEMP_MATRIX",{get:function(){return new t},enumerable:!1,configurable:!0}),t}(),m=[1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1,0,1],g=[0,1,1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1],_=[0,-1,-1,-1,0,1,1,1,0,1,1,1,0,-1,-1,-1],y=[1,1,0,-1,-1,-1,0,1,-1,-1,0,1,1,1,0,-1],b=[],E=[],x=Math.sign;function T(){for(var t=0;t<16;t++){var e=[];b.push(e);for(var n=0;n<16;n++)for(var r=x(m[t]*m[n]+_[t]*g[n]),i=x(g[t]*m[n]+y[t]*g[n]),o=x(m[t]*_[n]+_[t]*y[n]),s=x(g[t]*_[n]+y[t]*y[n]),a=0;a<16;a++)if(m[a]===r&&g[a]===i&&_[a]===o&&y[a]===s){e.push(a);break}}for(t=0;t<16;t++){var u=new v;u.set(m[t],g[t],_[t],y[t],0,0),E.push(u)}}T();var S={E:0,SE:1,S:2,SW:3,W:4,NW:5,N:6,NE:7,MIRROR_VERTICAL:8,MAIN_DIAGONAL:10,MIRROR_HORIZONTAL:12,REVERSE_DIAGONAL:14,uX:function(t){return m[t]},uY:function(t){return g[t]},vX:function(t){return _[t]},vY:function(t){return y[t]},inv:function(t){return 8&t?15&t:7&-t},add:function(t,e){return b[t][e]},sub:function(t,e){return b[t][S.inv(e)]},rotate180:function(t){return 4^t},isVertical:function(t){return 2===(3&t)},byDirection:function(t,e){return 2*Math.abs(t)<=Math.abs(e)?e>=0?S.S:S.N:2*Math.abs(e)<=Math.abs(t)?t>0?S.E:S.W:e>0?t>0?S.SE:S.SW:t>0?S.NE:S.NW},matrixAppendRotationInv:function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0);var i=E[S.inv(e)];i.tx=n,i.ty=r,t.append(i)}},R=function(){function t(){this.worldTransform=new v,this.localTransform=new v,this.position=new p(this.onChange,this,0,0),this.scale=new p(this.onChange,this,1,1),this.pivot=new p(this.onChange,this,0,0),this.skew=new p(this.updateSkew,this,0,0),this._rotation=0,this._cx=1,this._sx=0,this._cy=0,this._sy=1,this._localID=0,this._currentLocalID=0,this._worldID=0,this._parentID=0}return t.prototype.onChange=function(){this._localID++},t.prototype.updateSkew=function(){this._cx=Math.cos(this._rotation+this.skew.y),this._sx=Math.sin(this._rotation+this.skew.y),this._cy=-Math.sin(this._rotation-this.skew.x),this._sy=Math.cos(this._rotation-this.skew.x),this._localID++},t.prototype.toString=function(){return"[@pixi/math:Transform position=("+this.position.x+", "+this.position.y+") rotation="+this.rotation+" scale=("+this.scale.x+", "+this.scale.y+") skew=("+this.skew.x+", "+this.skew.y+") ]"},t.prototype.updateLocalTransform=function(){var t=this.localTransform;this._localID!==this._currentLocalID&&(t.a=this._cx*this.scale.x,t.b=this._sx*this.scale.x,t.c=this._cy*this.scale.y,t.d=this._sy*this.scale.y,t.tx=this.position.x-(this.pivot.x*t.a+this.pivot.y*t.c),t.ty=this.position.y-(this.pivot.x*t.b+this.pivot.y*t.d),this._currentLocalID=this._localID,this._parentID=-1)},t.prototype.updateTransform=function(t){var e=this.localTransform;if(this._localID!==this._currentLocalID&&(e.a=this._cx*this.scale.x,e.b=this._sx*this.scale.x,e.c=this._cy*this.scale.y,e.d=this._sy*this.scale.y,e.tx=this.position.x-(this.pivot.x*e.a+this.pivot.y*e.c),e.ty=this.position.y-(this.pivot.x*e.b+this.pivot.y*e.d),this._currentLocalID=this._localID,this._parentID=-1),this._parentID!==t._worldID){var n=t.worldTransform,r=this.worldTransform;r.a=e.a*n.a+e.b*n.c,r.b=e.a*n.b+e.b*n.d,r.c=e.c*n.a+e.d*n.c,r.d=e.c*n.b+e.d*n.d,r.tx=e.tx*n.a+e.ty*n.c+n.tx,r.ty=e.tx*n.b+e.ty*n.d+n.ty,this._parentID=t._worldID,this._worldID++}},t.prototype.setFromMatrix=function(t){t.decompose(this),this._localID++},Object.defineProperty(t.prototype,"rotation",{get:function(){return this._rotation},set:function(t){this._rotation!==t&&(this._rotation=t,this.updateSkew())},enumerable:!1,configurable:!0}),t.IDENTITY=new t,t}()},1845:function(t,e,n){"use strict";n.d(e,{Q5:function(){return S},oC:function(){return ut}});var r=n(2038),i=n(1680),o=n(8033),s=n(1576),a=n(9658),u=n(6679);n(1585); -/*! - * @pixi/particle-emitter - v5.0.4 - * Compiled Thu, 10 Mar 2022 03:05:06 UTC - * - * @pixi/particle-emitter is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -class l{constructor(t,e,n){this.value=t,this.time=e,this.next=null,this.isStepped=!1,this.ease=n?"function"===typeof n?n:_(n):null}static createList(t){if("list"in t){const e=t.list;let n;const{value:r,time:i}=e[0],o=n=new l("string"===typeof r?g(r):r,i,t.ease);if(e.length>2||2===e.length&&e[1].value!==r)for(let t=1;t<e.length;++t){const{value:r,time:i}=e[t];n.next=new l("string"===typeof r?g(r):r,i),n=n.next}return o.isStepped=!!t.isStepped,o}const e=new l("string"===typeof t.start?g(t.start):t.start,0);return t.end!==t.start&&(e.next=new l("string"===typeof t.end?g(t.end):t.end,1)),e}}let c=r.xE.from;const h=Math.PI/180;function f(t,e){if(!t)return;const n=Math.sin(t),r=Math.cos(t),i=e.x*r-e.y*n,o=e.x*n+e.y*r;e.x=i,e.y=o}function d(t,e,n){return t<<16|e<<8|n}function p(t){return Math.sqrt(t.x*t.x+t.y*t.y)}function v(t){const e=1/p(t);t.x*=e,t.y*=e}function m(t,e){t.x*=e,t.y*=e}function g(t,e){let n;return e||(e={}),"#"===t.charAt(0)?t=t.substr(1):0===t.indexOf("0x")&&(t=t.substr(2)),8===t.length&&(n=t.substr(0,2),t=t.substr(2)),e.r=parseInt(t.substr(0,2),16),e.g=parseInt(t.substr(2,2),16),e.b=parseInt(t.substr(4,2),16),n&&(e.a=parseInt(n,16)),e}function _(t){const e=t.length,n=1/e;return function(r){const i=e*r|0,o=(r-i*n)*e,s=t[i]||t[e-1];return s.s+o*(2*(1-o)*(s.cp-s.s)+o*(s.e-s.s))}}function y(t){return t?(t=t.toUpperCase().replace(/ /g,"_"),i.T$[t]||i.T$.NORMAL):i.T$.NORMAL}var b;class E extends o.j{constructor(t){super(),this.prevChild=this.nextChild=null,this.emitter=t,this.config={},this.anchor.x=this.anchor.y=.5,this.maxLife=0,this.age=0,this.agePercent=0,this.oneOverLife=0,this.next=null,this.prev=null,this.init=this.init,this.kill=this.kill}init(t){this.maxLife=t,this.age=this.agePercent=0,this.rotation=0,this.position.x=this.position.y=0,this.scale.x=this.scale.y=1,this.tint=16777215,this.alpha=1,this.oneOverLife=1/this.maxLife,this.visible=!0}kill(){this.emitter.recycle(this)}destroy(){this.parent&&this.parent.removeChild(this),this.emitter=this.next=this.prev=null,super.destroy()}}(function(t){t[t["Spawn"]=0]="Spawn",t[t["Normal"]=2]="Normal",t[t["Late"]=5]="Late"})(b||(b={}));const x=u.vB.shared,T=Symbol("Position particle per emitter position");class S{constructor(t,e){this.initBehaviors=[],this.updateBehaviors=[],this.recycleBehaviors=[],this.minLifetime=0,this.maxLifetime=0,this.customEase=null,this._frequency=1,this.spawnChance=1,this.maxParticles=1e3,this.emitterLifetime=-1,this.spawnPos=new a.E9,this.particlesPerWave=1,this.rotation=0,this.ownerPos=new a.E9,this._prevEmitterPos=new a.E9,this._prevPosIsValid=!1,this._posChanged=!1,this._parent=null,this.addAtBack=!1,this.particleCount=0,this._emit=!1,this._spawnTimer=0,this._emitterLife=-1,this._activeParticlesFirst=null,this._activeParticlesLast=null,this._poolFirst=null,this._origConfig=null,this._autoUpdate=!1,this._destroyWhenComplete=!1,this._completeCallback=null,this.parent=t,e&&this.init(e),this.recycle=this.recycle,this.update=this.update,this.rotate=this.rotate,this.updateSpawnPos=this.updateSpawnPos,this.updateOwnerPos=this.updateOwnerPos}static registerBehavior(t){S.knownBehaviors[t.type]=t}get frequency(){return this._frequency}set frequency(t){this._frequency="number"===typeof t&&t>0?t:1}get parent(){return this._parent}set parent(t){this.cleanup(),this._parent=t}init(t){if(!t)return;this.cleanup(),this._origConfig=t,this.minLifetime=t.lifetime.min,this.maxLifetime=t.lifetime.max,t.ease?this.customEase="function"===typeof t.ease?t.ease:_(t.ease):this.customEase=null,this.particlesPerWave=1,t.particlesPerWave&&t.particlesPerWave>1&&(this.particlesPerWave=t.particlesPerWave),this.frequency=t.frequency,this.spawnChance="number"===typeof t.spawnChance&&t.spawnChance>0?t.spawnChance:1,this.emitterLifetime=t.emitterLifetime||-1,this.maxParticles=t.maxParticles>0?t.maxParticles:1e3,this.addAtBack=!!t.addAtBack,this.rotation=0,this.ownerPos.set(0),t.pos?this.spawnPos.copyFrom(t.pos):this.spawnPos.set(0),this._prevEmitterPos.copyFrom(this.spawnPos),this._prevPosIsValid=!1,this._spawnTimer=0,this.emit=void 0===t.emit||!!t.emit,this.autoUpdate=!!t.autoUpdate;const e=t.behaviors.map((t=>{const e=S.knownBehaviors[t.type];return e?new e(t.config):(console.error(`Unknown behavior: ${t.type}`),null)})).filter((t=>!!t));e.push(T),e.sort(((t,e)=>t===T?e.order===b.Spawn?1:-1:e===T?t.order===b.Spawn?-1:1:t.order-e.order)),this.initBehaviors=e.slice(),this.updateBehaviors=e.filter((t=>t!==T&&t.updateParticle)),this.recycleBehaviors=e.filter((t=>t!==T&&t.recycleParticle))}getBehavior(t){return S.knownBehaviors[t]&&this.initBehaviors.find((e=>e instanceof S.knownBehaviors[t]))||null}fillPool(t){for(;t>0;--t){const t=new E(this);t.next=this._poolFirst,this._poolFirst=t}}recycle(t,e=!1){for(let n=0;n<this.recycleBehaviors.length;++n)this.recycleBehaviors[n].recycleParticle(t,!e);t.next&&(t.next.prev=t.prev),t.prev&&(t.prev.next=t.next),t===this._activeParticlesLast&&(this._activeParticlesLast=t.prev),t===this._activeParticlesFirst&&(this._activeParticlesFirst=t.next),t.prev=null,t.next=this._poolFirst,this._poolFirst=t,t.parent&&t.parent.removeChild(t),--this.particleCount}rotate(t){if(this.rotation===t)return;const e=t-this.rotation;this.rotation=t,f(e,this.spawnPos),this._posChanged=!0}updateSpawnPos(t,e){this._posChanged=!0,this.spawnPos.x=t,this.spawnPos.y=e}updateOwnerPos(t,e){this._posChanged=!0,this.ownerPos.x=t,this.ownerPos.y=e}resetPositionTracking(){this._prevPosIsValid=!1}get emit(){return this._emit}set emit(t){this._emit=!!t,this._emitterLife=this.emitterLifetime}get autoUpdate(){return this._autoUpdate}set autoUpdate(t){this._autoUpdate&&!t?x.remove(this.update,this):!this._autoUpdate&&t&&x.add(this.update,this),this._autoUpdate=!!t}playOnceAndDestroy(t){this.autoUpdate=!0,this.emit=!0,this._destroyWhenComplete=!0,this._completeCallback=t}playOnce(t){this.emit=!0,this._completeCallback=t}update(t){if(this._autoUpdate&&(t=t/s.X.TARGET_FPMS/1e3),!this._parent)return;for(let o,s=this._activeParticlesFirst;s;s=o)if(o=s.next,s.age+=t,s.age>s.maxLife||s.age<0)this.recycle(s);else{let e=s.age*s.oneOverLife;this.customEase&&(e=4===this.customEase.length?this.customEase(e,0,1,1):this.customEase(e)),s.agePercent=e;for(let n=0;n<this.updateBehaviors.length;++n)if(this.updateBehaviors[n].updateParticle(s,t)){this.recycle(s);break}}let e,n;this._prevPosIsValid&&(e=this._prevEmitterPos.x,n=this._prevEmitterPos.y);const r=this.ownerPos.x+this.spawnPos.x,i=this.ownerPos.y+this.spawnPos.y;if(this._emit){this._spawnTimer-=t<0?0:t;while(this._spawnTimer<=0){if(this._emitterLife>=0&&(this._emitterLife-=this._frequency,this._emitterLife<=0)){this._spawnTimer=0,this._emitterLife=0,this.emit=!1;break}if(this.particleCount>=this.maxParticles){this._spawnTimer+=this._frequency;continue}let o,s;if(this._prevPosIsValid&&this._posChanged){const a=1+this._spawnTimer/t;o=(r-e)*a+e,s=(i-n)*a+n}else o=r,s=i;let a=null,u=null;for(let t=Math.min(this.particlesPerWave,this.maxParticles-this.particleCount),e=0;e<t;++e){if(this.spawnChance<1&&Math.random()>=this.spawnChance)continue;let t,e;(t=this.minLifetime===this.maxLifetime?this.minLifetime:Math.random()*(this.maxLifetime-this.minLifetime)+this.minLifetime,-this._spawnTimer>=t)||(this._poolFirst?(e=this._poolFirst,this._poolFirst=this._poolFirst.next,e.next=null):e=new E(this),e.init(t),this.addAtBack?this._parent.addChildAt(e,0):this._parent.addChild(e),a?(u.next=e,e.prev=u,u=e):u=a=e,++this.particleCount)}if(a){this._activeParticlesLast?(this._activeParticlesLast.next=a,a.prev=this._activeParticlesLast,this._activeParticlesLast=u):(this._activeParticlesFirst=a,this._activeParticlesLast=u);for(let t=0;t<this.initBehaviors.length;++t){const e=this.initBehaviors[t];if(e===T)for(let t,n=a;n;n=t){t=n.next,0!==this.rotation&&(f(this.rotation,n.position),n.rotation+=this.rotation),n.position.x+=o,n.position.y+=s,n.age+=-this._spawnTimer;let e=n.age*n.oneOverLife;this.customEase&&(e=4===this.customEase.length?this.customEase(e,0,1,1):this.customEase(e)),n.agePercent=e}else e.initParticles(a)}for(let t,e=a;e;e=t){t=e.next;for(let t=0;t<this.updateBehaviors.length;++t)if(this.updateBehaviors[t].updateParticle(e,-this._spawnTimer)){this.recycle(e);break}}}this._spawnTimer+=this._frequency}}if(this._posChanged&&(this._prevEmitterPos.x=r,this._prevEmitterPos.y=i,this._prevPosIsValid=!0,this._posChanged=!1),!this._emit&&!this._activeParticlesFirst){if(this._completeCallback){const t=this._completeCallback;this._completeCallback=null,t()}this._destroyWhenComplete&&this.destroy()}}emitNow(){const t=this.ownerPos.x+this.spawnPos.x,e=this.ownerPos.y+this.spawnPos.y;let n=null,r=null;for(let i=Math.min(this.particlesPerWave,this.maxParticles-this.particleCount),o=0;o<i;++o){if(this.spawnChance<1&&Math.random()>=this.spawnChance)continue;let t,e;this._poolFirst?(t=this._poolFirst,this._poolFirst=this._poolFirst.next,t.next=null):t=new E(this),e=this.minLifetime===this.maxLifetime?this.minLifetime:Math.random()*(this.maxLifetime-this.minLifetime)+this.minLifetime,t.init(e),this.addAtBack?this._parent.addChildAt(t,0):this._parent.addChild(t),n?(r.next=t,t.prev=r,r=t):r=n=t,++this.particleCount}if(n){this._activeParticlesLast?(this._activeParticlesLast.next=n,n.prev=this._activeParticlesLast,this._activeParticlesLast=r):(this._activeParticlesFirst=n,this._activeParticlesLast=r);for(let r=0;r<this.initBehaviors.length;++r){const i=this.initBehaviors[r];if(i===T)for(let r,o=n;o;o=r)r=o.next,0!==this.rotation&&(f(this.rotation,o.position),o.rotation+=this.rotation),o.position.x+=t,o.position.y+=e;else i.initParticles(n)}}}cleanup(){let t,e;for(t=this._activeParticlesFirst;t;t=e)e=t.next,this.recycle(t,!0);this._activeParticlesFirst=this._activeParticlesLast=null,this.particleCount=0}get destroyed(){return!(this._parent&&this.initBehaviors.length)}destroy(){let t;this.autoUpdate=!1,this.cleanup();for(let e=this._poolFirst;e;e=t)t=e.next,e.destroy();this._poolFirst=this._parent=this.spawnPos=this.ownerPos=this.customEase=this._completeCallback=null,this.initBehaviors.length=this.updateBehaviors.length=this.recycleBehaviors.length=0}}S.knownBehaviors={};class R{constructor(t){this.x=t.x,this.y=t.y,this.w=t.w,this.h=t.h}getRandPos(t){t.x=Math.random()*this.w+this.x,t.y=Math.random()*this.h+this.y}}R.type="rect",R.editorConfig=null;class A{constructor(t){this.x=t.x||0,this.y=t.y||0,this.radius=t.radius,this.innerRadius=t.innerRadius||0,this.rotation=!!t.affectRotation}getRandPos(t){this.innerRadius!==this.radius?t.x=Math.random()*(this.radius-this.innerRadius)+this.innerRadius:t.x=this.radius,t.y=0;const e=Math.random()*Math.PI*2;this.rotation&&(t.rotation+=e),f(e,t.position),t.position.x+=this.x,t.position.y+=this.y}}A.type="torus",A.editorConfig=null;class O{constructor(t){this.segments=[],this.countingLengths=[],this.totalLength=0,this.init(t)}init(t){if(t&&t.length)if(Array.isArray(t[0]))for(let e=0;e<t.length;++e){const n=t[e];let r=n[0];for(let t=1;t<n.length;++t){const e=n[t];this.segments.push({p1:r,p2:e,l:0}),r=e}}else{let e=t[0];for(let n=1;n<t.length;++n){const r=t[n];this.segments.push({p1:e,p2:r,l:0}),e=r}}else this.segments.push({p1:{x:0,y:0},p2:{x:0,y:0},l:0});for(let e=0;e<this.segments.length;++e){const{p1:t,p2:n}=this.segments[e],r=Math.sqrt((n.x-t.x)*(n.x-t.x)+(n.y-t.y)*(n.y-t.y));this.segments[e].l=r,this.totalLength+=r,this.countingLengths.push(this.totalLength)}}getRandPos(t){const e=Math.random()*this.totalLength;let n,r;if(1===this.segments.length)n=this.segments[0],r=e;else for(let s=0;s<this.countingLengths.length;++s)if(e<this.countingLengths[s]){n=this.segments[s],r=0===s?e:e-this.countingLengths[s-1];break}r/=n.l||1;const{p1:i,p2:o}=n;t.x=i.x+r*(o.x-i.x),t.y=i.y+r*(o.y-i.y)}}O.type="polygonalChain",O.editorConfig=null;class w{constructor(t){var e;this.order=b.Late,this.minStart=t.minStart,this.maxStart=t.maxStart,this.accel=t.accel,this.rotate=!!t.rotate,this.maxSpeed=null!==(e=t.maxSpeed)&&void 0!==e?e:0}initParticles(t){let e=t;while(e){const t=Math.random()*(this.maxStart-this.minStart)+this.minStart;e.config.velocity?e.config.velocity.set(t,0):e.config.velocity=new a.E9(t,0),f(e.rotation,e.config.velocity),e=e.next}}updateParticle(t,e){const n=t.config.velocity,r=n.x,i=n.y;if(n.x+=this.accel.x*e,n.y+=this.accel.y*e,this.maxSpeed){const t=p(n);t>this.maxSpeed&&m(n,this.maxSpeed/t)}t.x+=(r+n.x)/2*e,t.y+=(i+n.y)/2*e,this.rotate&&(t.rotation=Math.atan2(n.y,n.x))}}function I(t){return this.ease&&(t=this.ease(t)),(this.first.next.value-this.first.value)*t+this.first.value}function P(t){this.ease&&(t=this.ease(t));const e=this.first.value,n=this.first.next.value,r=(n.r-e.r)*t+e.r,i=(n.g-e.g)*t+e.g,o=(n.b-e.b)*t+e.b;return d(r,i,o)}function C(t){this.ease&&(t=this.ease(t));let e=this.first,n=e.next;while(t>n.time)e=n,n=n.next;return t=(t-e.time)/(n.time-e.time),(n.value-e.value)*t+e.value}function N(t){this.ease&&(t=this.ease(t));let e=this.first,n=e.next;while(t>n.time)e=n,n=n.next;t=(t-e.time)/(n.time-e.time);const r=e.value,i=n.value,o=(i.r-r.r)*t+r.r,s=(i.g-r.g)*t+r.g,a=(i.b-r.b)*t+r.b;return d(o,s,a)}function M(t){this.ease&&(t=this.ease(t));let e=this.first;while(e.next&&t>e.next.time)e=e.next;return e.value}function D(t){this.ease&&(t=this.ease(t));let e=this.first;while(e.next&&t>e.next.time)e=e.next;const n=e.value;return d(n.r,n.g,n.b)}w.type="moveAcceleration",w.editorConfig=null;class L{constructor(t=!1){this.first=null,this.isColor=!!t,this.interpolate=null,this.ease=null}reset(t){this.first=t;const e=t.next&&t.next.time>=1;e?this.interpolate=this.isColor?P:I:t.isStepped?this.interpolate=this.isColor?D:M:this.interpolate=this.isColor?N:C,this.ease=this.first.ease}}class F{constructor(t){this.order=b.Normal,this.list=new L(!1),this.list.reset(l.createList(t.alpha))}initParticles(t){let e=t;while(e)e.alpha=this.list.first.value,e=e.next}updateParticle(t){t.alpha=this.list.interpolate(t.agePercent)}}F.type="alpha",F.editorConfig=null;class B{constructor(t){this.order=b.Normal,this.value=t.alpha}initParticles(t){let e=t;while(e)e.alpha=this.value,e=e.next}}function U(t){const e=[];for(let n=0;n<t.length;++n){let i=t[n];if("string"===typeof i)e.push(c(i));else if(i instanceof r.xE)e.push(i);else{let t=i.count||1;for(i="string"===typeof i.texture?c(i.texture):i.texture;t>0;--t)e.push(i)}}return e}B.type="alphaStatic",B.editorConfig=null;class G{constructor(t){this.order=b.Normal,this.anims=[];for(let e=0;e<t.anims.length;++e){const n=t.anims[e],r=U(n.textures),i=n.framerate<0?-1:n.framerate>0?n.framerate:60,o={textures:r,duration:i>0?r.length/i:0,framerate:i,loop:i>0&&!!n.loop};this.anims.push(o)}}initParticles(t){let e=t;while(e){const t=Math.floor(Math.random()*this.anims.length),n=e.config.anim=this.anims[t];e.texture=n.textures[0],e.config.animElapsed=0,-1===n.framerate?(e.config.animDuration=e.maxLife,e.config.animFramerate=n.textures.length/e.maxLife):(e.config.animDuration=n.duration,e.config.animFramerate=n.framerate),e=e.next}}updateParticle(t,e){const n=t.config,i=n.anim;n.animElapsed+=e,n.animElapsed>=n.animDuration&&(n.anim.loop?n.animElapsed=n.animElapsed%n.animDuration:n.animElapsed=n.animDuration-1e-6);const o=n.animElapsed*n.animFramerate+1e-7|0;t.texture=i.textures[o]||i.textures[i.textures.length-1]||r.xE.EMPTY}}G.type="animatedRandom",G.editorConfig=null;class k{constructor(t){this.order=b.Normal;const e=t.anim,n=U(e.textures),r=e.framerate<0?-1:e.framerate>0?e.framerate:60;this.anim={textures:n,duration:r>0?n.length/r:0,framerate:r,loop:r>0&&!!e.loop}}initParticles(t){let e=t;const n=this.anim;while(e)e.texture=n.textures[0],e.config.animElapsed=0,-1===n.framerate?(e.config.animDuration=e.maxLife,e.config.animFramerate=n.textures.length/e.maxLife):(e.config.animDuration=n.duration,e.config.animFramerate=n.framerate),e=e.next}updateParticle(t,e){const n=this.anim,i=t.config;i.animElapsed+=e,i.animElapsed>=i.animDuration&&(n.loop?i.animElapsed=i.animElapsed%i.animDuration:i.animElapsed=i.animDuration-1e-6);const o=i.animElapsed*i.animFramerate+1e-7|0;t.texture=n.textures[o]||n.textures[n.textures.length-1]||r.xE.EMPTY}}k.type="animatedSingle",k.editorConfig=null;class X{constructor(t){this.order=b.Normal,this.value=t.blendMode}initParticles(t){let e=t;while(e)e.blendMode=y(this.value),e=e.next}}X.type="blendMode",X.editorConfig=null;class j{constructor(t){this.order=b.Spawn,this.spacing=t.spacing*h,this.start=t.start*h,this.distance=t.distance}initParticles(t){let e=0,n=t;while(n){let t;t=this.spacing?this.start+this.spacing*e:Math.random()*Math.PI*2,n.rotation=t,this.distance&&(n.position.x=this.distance,f(t,n.position)),n=n.next,++e}}}j.type="spawnBurst",j.editorConfig=null;class H{constructor(t){this.order=b.Normal,this.list=new L(!0),this.list.reset(l.createList(t.color))}initParticles(t){let e=t;const n=this.list.first.value,r=d(n.r,n.g,n.b);while(e)e.tint=r,e=e.next}updateParticle(t){t.tint=this.list.interpolate(t.agePercent)}}H.type="color",H.editorConfig=null;class V{constructor(t){this.order=b.Normal;let e=t.color;"#"===e.charAt(0)?e=e.substr(1):0===e.indexOf("0x")&&(e=e.substr(2)),this.value=parseInt(e,16)}initParticles(t){let e=t;while(e)e.tint=this.value,e=e.next}}V.type="colorStatic",V.editorConfig=null;class Y{constructor(t){this.order=b.Normal,this.index=0,this.textures=t.textures.map((t=>"string"===typeof t?c(t):t))}initParticles(t){let e=t;while(e)e.texture=this.textures[this.index],++this.index>=this.textures.length&&(this.index=0),e=e.next}}Y.type="textureOrdered",Y.editorConfig=null;const W=new a.E9,z=["E","LN2","LN10","LOG2E","LOG10E","PI","SQRT1_2","SQRT2","abs","acos","acosh","asin","asinh","atan","atanh","atan2","cbrt","ceil","cos","cosh","exp","expm1","floor","fround","hypot","log","log1p","log10","log2","max","min","pow","random","round","sign","sin","sinh","sqrt","tan","tanh"],$=new RegExp(["[01234567890\\.\\*\\-\\+\\/\\(\\)x ,]"].concat(z).join("|"),"g");function q(t){const e=t.match($);for(let n=e.length-1;n>=0;--n)z.indexOf(e[n])>=0&&(e[n]=`Math.${e[n]}`);return t=e.join(""),new Function("x",`return ${t};`)}class K{constructor(t){var e;if(this.order=b.Late,t.path)if("function"===typeof t.path)this.path=t.path;else try{this.path=q(t.path)}catch(n){this.path=null}else this.path=t=>t;this.list=new L(!1),this.list.reset(l.createList(t.speed)),this.minMult=null!==(e=t.minMult)&&void 0!==e?e:1}initParticles(t){let e=t;while(e){e.config.initRotation=e.rotation,e.config.initPosition?e.config.initPosition.copyFrom(e.position):e.config.initPosition=new a.E9(e.x,e.y),e.config.movement=0;const t=Math.random()*(1-this.minMult)+this.minMult;e.config.speedMult=t,e=e.next}}updateParticle(t,e){const n=this.list.interpolate(t.agePercent)*t.config.speedMult;t.config.movement+=n*e,W.x=t.config.movement,W.y=this.path(W.x),f(t.config.initRotation,W),t.position.x=t.config.initPosition.x+W.x,t.position.y=t.config.initPosition.y+W.y}}K.type="movePath",K.editorConfig=null;class Z{constructor(){this.order=b.Spawn}initParticles(t){}}Z.type="spawnPoint",Z.editorConfig=null;class J{constructor(t){this.order=b.Normal,this.textures=t.textures.map((t=>"string"===typeof t?c(t):t))}initParticles(t){let e=t;while(e){const t=Math.floor(Math.random()*this.textures.length);e.texture=this.textures[t],e=e.next}}}J.type="textureRandom",J.editorConfig=null;class Q{constructor(t){this.order=b.Normal,this.minStart=t.minStart*h,this.maxStart=t.maxStart*h,this.minSpeed=t.minSpeed*h,this.maxSpeed=t.maxSpeed*h,this.accel=t.accel*h}initParticles(t){let e=t;while(e)this.minStart===this.maxStart?e.rotation+=this.maxStart:e.rotation+=Math.random()*(this.maxStart-this.minStart)+this.minStart,e.config.rotSpeed=Math.random()*(this.maxSpeed-this.minSpeed)+this.minSpeed,e=e.next}updateParticle(t,e){if(this.accel){const n=t.config.rotSpeed;t.config.rotSpeed+=this.accel*e,t.rotation+=(t.config.rotSpeed+n)/2*e}else t.rotation+=t.config.rotSpeed*e}}Q.type="rotation",Q.editorConfig=null;class tt{constructor(t){this.order=b.Normal,this.min=t.min*h,this.max=t.max*h}initParticles(t){let e=t;while(e)this.min===this.max?e.rotation+=this.max:e.rotation+=Math.random()*(this.max-this.min)+this.min,e=e.next}}tt.type="rotationStatic",tt.editorConfig=null;class et{constructor(t){this.order=b.Late+1,this.rotation=(t.rotation||0)*h}initParticles(t){let e=t;while(e)e.rotation=this.rotation,e=e.next}}et.type="noRotation",et.editorConfig=null;class nt{constructor(t){var e;this.order=b.Normal,this.list=new L(!1),this.list.reset(l.createList(t.scale)),this.minMult=null!==(e=t.minMult)&&void 0!==e?e:1}initParticles(t){let e=t;while(e){const t=Math.random()*(1-this.minMult)+this.minMult;e.config.scaleMult=t,e.scale.x=e.scale.y=this.list.first.value*t,e=e.next}}updateParticle(t){t.scale.x=t.scale.y=this.list.interpolate(t.agePercent)*t.config.scaleMult}}nt.type="scale",nt.editorConfig=null;class rt{constructor(t){this.order=b.Normal,this.min=t.min,this.max=t.max}initParticles(t){let e=t;while(e){const t=Math.random()*(this.max-this.min)+this.min;e.scale.x=e.scale.y=t,e=e.next}}}rt.type="scaleStatic",rt.editorConfig=null;class it{constructor(t){this.order=b.Spawn;const e=it.shapes[t.type];if(!e)throw new Error(`No shape found with type '${t.type}'`);this.shape=new e(t.data)}static registerShape(t,e){it.shapes[e||t.type]=t}initParticles(t){let e=t;while(e)this.shape.getRandPos(e),e=e.next}}it.type="spawnShape",it.editorConfig=null,it.shapes={},it.registerShape(O),it.registerShape(R),it.registerShape(A),it.registerShape(A,"circle");class ot{constructor(t){this.order=b.Normal,this.texture="string"===typeof t.texture?c(t.texture):t.texture}initParticles(t){let e=t;while(e)e.texture=this.texture,e=e.next}}ot.type="textureSingle",ot.editorConfig=null;class st{constructor(t){var e;this.order=b.Late,this.list=new L(!1),this.list.reset(l.createList(t.speed)),this.minMult=null!==(e=t.minMult)&&void 0!==e?e:1}initParticles(t){let e=t;while(e){const t=Math.random()*(1-this.minMult)+this.minMult;e.config.speedMult=t,e.config.velocity?e.config.velocity.set(this.list.first.value*t,0):e.config.velocity=new a.E9(this.list.first.value*t,0),f(e.rotation,e.config.velocity),e=e.next}}updateParticle(t,e){const n=this.list.interpolate(t.agePercent)*t.config.speedMult,r=t.config.velocity;v(r),m(r,n),t.x+=r.x*e,t.y+=r.y*e}}st.type="moveSpeed",st.editorConfig=null;class at{constructor(t){this.order=b.Late,this.min=t.min,this.max=t.max}initParticles(t){let e=t;while(e){const t=Math.random()*(this.max-this.min)+this.min;e.config.velocity?e.config.velocity.set(t,0):e.config.velocity=new a.E9(t,0),f(e.rotation,e.config.velocity),e=e.next}}updateParticle(t,e){const n=t.config.velocity;t.x+=n.x*e,t.y+=n.y*e}}at.type="moveSpeedStatic",at.editorConfig=null;function ut(t,e){var n,r,i,o,s,a,u,l,c,h,f,d,p,v,m,g,_,y,b,E,x;if("behaviors"in t)return t;const T={lifetime:t.lifetime,ease:t.ease,particlesPerWave:t.particlesPerWave,frequency:t.frequency,spawnChance:t.spawnChance,emitterLifetime:t.emitterLifetime,maxParticles:t.maxParticles,addAtBack:t.addAtBack,pos:t.pos,emit:t.emit,autoUpdate:t.autoUpdate,behaviors:[]};if(t.alpha)if("start"in t.alpha)if(t.alpha.start===t.alpha.end)1!==t.alpha.start&&T.behaviors.push({type:"alphaStatic",config:{alpha:t.alpha.start}});else{const e={list:[{time:0,value:t.alpha.start},{time:1,value:t.alpha.end}]};T.behaviors.push({type:"alpha",config:{alpha:e}})}else 1===t.alpha.list.length?1!==t.alpha.list[0].value&&T.behaviors.push({type:"alphaStatic",config:{alpha:t.alpha.list[0].value}}):T.behaviors.push({type:"alpha",config:{alpha:t.alpha}});if(t.acceleration&&(t.acceleration.x||t.acceleration.y)){let e,i;"start"in t.speed?(e=t.speed.start*(null!==(n=t.speed.minimumSpeedMultiplier)&&void 0!==n?n:1),i=t.speed.start):(e=t.speed.list[0].value*(null!==(r=t.minimumSpeedMultiplier)&&void 0!==r?r:1),i=t.speed.list[0].value),T.behaviors.push({type:"moveAcceleration",config:{accel:t.acceleration,minStart:e,maxStart:i,rotate:!t.noRotation,maxSpeed:t.maxSpeed}})}else if(null===(i=t.extraData)||void 0===i?void 0:i.path){let e,n;"start"in t.speed?(n=null!==(o=t.speed.minimumSpeedMultiplier)&&void 0!==o?o:1,e=t.speed.start===t.speed.end?{list:[{time:0,value:t.speed.start}]}:{list:[{time:0,value:t.speed.start},{time:1,value:t.speed.end}]}):(e=t.speed,n=null!==(s=t.minimumSpeedMultiplier)&&void 0!==s?s:1),T.behaviors.push({type:"movePath",config:{path:t.extraData.path,speed:e,minMult:n}})}else if(t.speed)if("start"in t.speed)if(t.speed.start===t.speed.end)T.behaviors.push({type:"moveSpeedStatic",config:{min:t.speed.start*(null!==(a=t.speed.minimumSpeedMultiplier)&&void 0!==a?a:1),max:t.speed.start}});else{const e={list:[{time:0,value:t.speed.start},{time:1,value:t.speed.end}]};T.behaviors.push({type:"moveSpeed",config:{speed:e,minMult:t.speed.minimumSpeedMultiplier}})}else 1===t.speed.list.length?T.behaviors.push({type:"moveSpeedStatic",config:{min:t.speed.list[0].value*(null!==(u=t.minimumSpeedMultiplier)&&void 0!==u?u:1),max:t.speed.list[0].value}}):T.behaviors.push({type:"moveSpeed",config:{speed:t.speed,minMult:null!==(l=t.minimumSpeedMultiplier)&&void 0!==l?l:1}});if(t.scale)if("start"in t.scale){const e=null!==(c=t.scale.minimumScaleMultiplier)&&void 0!==c?c:1;if(t.scale.start===t.scale.end)T.behaviors.push({type:"scaleStatic",config:{min:t.scale.start*e,max:t.scale.start}});else{const n={list:[{time:0,value:t.scale.start},{time:1,value:t.scale.end}]};T.behaviors.push({type:"scale",config:{scale:n,minMult:e}})}}else if(1===t.scale.list.length){const e=null!==(h=t.minimumScaleMultiplier)&&void 0!==h?h:1,n=t.scale.list[0].value;T.behaviors.push({type:"scaleStatic",config:{min:n*e,max:n}})}else T.behaviors.push({type:"scale",config:{scale:t.scale,minMult:null!==(f=t.minimumScaleMultiplier)&&void 0!==f?f:1}});if(t.color)if("start"in t.color)if(t.color.start===t.color.end)"ffffff"!==t.color.start&&T.behaviors.push({type:"colorStatic",config:{color:t.color.start}});else{const e={list:[{time:0,value:t.color.start},{time:1,value:t.color.end}]};T.behaviors.push({type:"color",config:{color:e}})}else 1===t.color.list.length?"ffffff"!==t.color.list[0].value&&T.behaviors.push({type:"colorStatic",config:{color:t.color.list[0].value}}):T.behaviors.push({type:"color",config:{color:t.color}});if(t.rotationAcceleration||(null===(d=t.rotationSpeed)||void 0===d?void 0:d.min)||(null===(p=t.rotationSpeed)||void 0===p?void 0:p.max)?T.behaviors.push({type:"rotation",config:{accel:t.rotationAcceleration||0,minSpeed:(null===(v=t.rotationSpeed)||void 0===v?void 0:v.min)||0,maxSpeed:(null===(m=t.rotationSpeed)||void 0===m?void 0:m.max)||0,minStart:(null===(g=t.startRotation)||void 0===g?void 0:g.min)||0,maxStart:(null===(_=t.startRotation)||void 0===_?void 0:_.max)||0}}):((null===(y=t.startRotation)||void 0===y?void 0:y.min)||(null===(b=t.startRotation)||void 0===b?void 0:b.max))&&T.behaviors.push({type:"rotationStatic",config:{min:(null===(E=t.startRotation)||void 0===E?void 0:E.min)||0,max:(null===(x=t.startRotation)||void 0===x?void 0:x.max)||0}}),t.noRotation&&T.behaviors.push({type:"noRotation",config:{}}),t.blendMode&&"normal"!==t.blendMode&&T.behaviors.push({type:"blendMode",config:{blendMode:t.blendMode}}),Array.isArray(e)&&"string"!==typeof e[0]&&"framerate"in e[0]){for(let t=0;t<e.length;++t)"matchLife"===e[t].framerate&&(e[t].framerate=-1);T.behaviors.push({type:"animatedRandom",config:{anims:e}})}else"string"!==typeof e&&"framerate"in e?("matchLife"===e.framerate&&(e.framerate=-1),T.behaviors.push({type:"animatedSingle",config:{anim:e}})):t.orderedArt&&Array.isArray(e)?T.behaviors.push({type:"textureOrdered",config:{textures:e}}):Array.isArray(e)?T.behaviors.push({type:"textureRandom",config:{textures:e}}):T.behaviors.push({type:"textureSingle",config:{texture:e}});if("burst"===t.spawnType)T.behaviors.push({type:"spawnBurst",config:{start:t.angleStart||0,spacing:t.particleSpacing,distance:0}});else if("point"===t.spawnType)T.behaviors.push({type:"spawnPoint",config:{}});else{let e;"ring"===t.spawnType?e={type:"torus",data:{x:t.spawnCircle.x,y:t.spawnCircle.y,radius:t.spawnCircle.r,innerRadius:t.spawnCircle.minR,affectRotation:!0}}:"circle"===t.spawnType?e={type:"torus",data:{x:t.spawnCircle.x,y:t.spawnCircle.y,radius:t.spawnCircle.r,innerRadius:0,affectRotation:!1}}:"rect"===t.spawnType?e={type:"rect",data:t.spawnRect}:"polygonalChain"===t.spawnType&&(e={type:"polygonalChain",data:t.spawnPolygon}),e&&T.behaviors.push({type:"spawnShape",config:e})}return T}S.registerBehavior(w),S.registerBehavior(F),S.registerBehavior(B),S.registerBehavior(G),S.registerBehavior(k),S.registerBehavior(X),S.registerBehavior(j),S.registerBehavior(H),S.registerBehavior(V),S.registerBehavior(Y),S.registerBehavior(K),S.registerBehavior(Z),S.registerBehavior(J),S.registerBehavior(Q),S.registerBehavior(tt),S.registerBehavior(et),S.registerBehavior(nt),S.registerBehavior(rt),S.registerBehavior(it),S.registerBehavior(ot),S.registerBehavior(st),S.registerBehavior(at)},1034:function(t,e,n){"use strict";n.d(e,{R:function(){return r}}); -/*! - * @pixi/runner - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/runner is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var r=function(){function t(t){this.items=[],this._name=t,this._aliasCount=0}return t.prototype.emit=function(t,e,n,r,i,o,s,a){if(arguments.length>8)throw new Error("max arguments reached");var u=this,l=u.name,c=u.items;this._aliasCount++;for(var h=0,f=c.length;h<f;h++)c[h][l](t,e,n,r,i,o,s,a);return c===this.items&&this._aliasCount--,this},t.prototype.ensureNonAliasedItems=function(){this._aliasCount>0&&this.items.length>1&&(this._aliasCount=0,this.items=this.items.slice(0))},t.prototype.add=function(t){return t[this._name]&&(this.ensureNonAliasedItems(),this.remove(t),this.items.push(t)),this},t.prototype.remove=function(t){var e=this.items.indexOf(t);return-1!==e&&(this.ensureNonAliasedItems(),this.items.splice(e,1)),this},t.prototype.contains=function(t){return-1!==this.items.indexOf(t)},t.prototype.removeAll=function(){return this.ensureNonAliasedItems(),this.items.length=0,this},t.prototype.destroy=function(){this.removeAll(),this.items=null,this._name=null},Object.defineProperty(t.prototype,"empty",{get:function(){return 0===this.items.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return this._name},enumerable:!1,configurable:!0}),t}();Object.defineProperties(r.prototype,{dispatch:{value:r.prototype.emit},run:{value:r.prototype.emit}})},1576:function(t,e,n){"use strict";n.d(e,{t:function(){return k},X:function(){return H}});var r=/iPhone/i,i=/iPod/i,o=/iPad/i,s=/\biOS-universal(?:.+)Mac\b/i,a=/\bAndroid(?:.+)Mobile\b/i,u=/Android/i,l=/(?:SD4930UR|\bSilk(?:.+)Mobile\b)/i,c=/Silk/i,h=/Windows Phone/i,f=/\bWindows(?:.+)ARM\b/i,d=/BlackBerry/i,p=/BB10/i,v=/Opera Mini/i,m=/\b(CriOS|Chrome)(?:.+)Mobile/i,g=/Mobile(?:.+)Firefox\b/i,_=function(t){return"undefined"!==typeof t&&"MacIntel"===t.platform&&"number"===typeof t.maxTouchPoints&&t.maxTouchPoints>1&&"undefined"===typeof MSStream};function y(t){return function(e){return e.test(t)}}function b(t){var e={userAgent:"",platform:"",maxTouchPoints:0};t||"undefined"===typeof navigator?"string"===typeof t?e.userAgent=t:t&&t.userAgent&&(e={userAgent:t.userAgent,platform:t.platform,maxTouchPoints:t.maxTouchPoints||0}):e={userAgent:navigator.userAgent,platform:navigator.platform,maxTouchPoints:navigator.maxTouchPoints||0};var n=e.userAgent,b=n.split("[FBAN");"undefined"!==typeof b[1]&&(n=b[0]),b=n.split("Twitter"),"undefined"!==typeof b[1]&&(n=b[0]);var E=y(n),x={apple:{phone:E(r)&&!E(h),ipod:E(i),tablet:!E(r)&&(E(o)||_(e))&&!E(h),universal:E(s),device:(E(r)||E(i)||E(o)||E(s)||_(e))&&!E(h)},amazon:{phone:E(l),tablet:!E(l)&&E(c),device:E(l)||E(c)},android:{phone:!E(h)&&E(l)||!E(h)&&E(a),tablet:!E(h)&&!E(l)&&!E(a)&&(E(c)||E(u)),device:!E(h)&&(E(l)||E(c)||E(a)||E(u))||E(/\bokhttp\b/i)},windows:{phone:E(h),tablet:E(f),device:E(h)||E(f)},other:{blackberry:E(d),blackberry10:E(p),opera:E(v),firefox:E(g),chrome:E(m),device:E(d)||E(p)||E(v)||E(g)||E(m)},any:!1,phone:!1,tablet:!1};return x.any=x.apple.device||x.android.device||x.windows.device||x.other.device,x.phone=x.apple.phone||x.android.phone||x.windows.phone,x.tablet=x.apple.tablet||x.android.tablet||x.windows.tablet,x} -/*! - * @pixi/settings - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/settings is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var E,x,T,S,R,A,O,w,I,P,C,N,M,D,L,F,B,U,G,k=b(globalThis.navigator);function X(t){var e=!0;if(k.tablet||k.phone){if(k.apple.device){var n=navigator.userAgent.match(/OS (\d+)_(\d+)?/);if(n){var r=parseInt(n[1],10);r<11&&(e=!1)}}if(k.android.device){n=navigator.userAgent.match(/Android\s([0-9.]*)/);if(n){r=parseInt(n[1],10);r<7&&(e=!1)}}}return e?t:4}function j(){return!k.apple.device} -/*! - * @pixi/constants - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/constants is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */(function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"})(E||(E={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(x||(x={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(T||(T={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(S||(S={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(R||(R={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(A||(A={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(O||(O={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(w||(w={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(I||(I={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(P||(P={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(C||(C={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(N||(N={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(M||(M={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(D||(D={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(L||(L={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(F||(F={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(B||(B={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(U||(U={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(G||(G={}));var H={MIPMAP_TEXTURES:N.POW2,ANISOTROPIC_LEVEL:0,RESOLUTION:1,FILTER_RESOLUTION:1,FILTER_MULTISAMPLE:U.NONE,SPRITE_MAX_TEXTURES:X(32),SPRITE_BATCH_SIZE:4096,RENDER_OPTIONS:{view:null,antialias:!1,autoDensity:!1,backgroundColor:0,backgroundAlpha:1,useContextAlpha:!0,clearBeforeRender:!0,preserveDrawingBuffer:!1,width:800,height:600,legacy:!1},GC_MODE:L.AUTO,GC_MAX_IDLE:3600,GC_MAX_CHECK_COUNT:600,WRAP_MODE:C.CLAMP,SCALE_MODE:P.LINEAR,PRECISION_VERTEX:F.HIGH,PRECISION_FRAGMENT:k.apple.device?F.HIGH:F.MEDIUM,CAN_UPLOAD_SAME_BUFFER:j(),CREATE_IMAGE_BITMAP:!1,ROUND_PIXELS:!1}},8033:function(t,e,n){"use strict";n.d(e,{j:function(){return d}});var r=n(1680),i=n(2038),o=n(1585),s=n(9658),a=n(1576),u=n(8942),l=function(t,e){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},l(t,e)};function c(t,e){function n(){this.constructor=t}l(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var h=new s.E9,f=new Uint16Array([0,1,2,0,2,3]),d=function(t){function e(e){var n=t.call(this)||this;return n._anchor=new s.AB(n._onAnchorUpdate,n,e?e.defaultAnchor.x:0,e?e.defaultAnchor.y:0),n._texture=null,n._width=0,n._height=0,n._tint=null,n._tintRGB=null,n.tint=16777215,n.blendMode=r.T$.NORMAL,n._cachedTint=16777215,n.uvs=null,n.texture=e||i.xE.EMPTY,n.vertexData=new Float32Array(8),n.vertexTrimmedData=null,n._transformID=-1,n._textureID=-1,n._transformTrimmedID=-1,n._textureTrimmedID=-1,n.indices=f,n.pluginName="batch",n.isSprite=!0,n._roundPixels=a.X.ROUND_PIXELS,n}return c(e,t),e.prototype._onTextureUpdate=function(){this._textureID=-1,this._textureTrimmedID=-1,this._cachedTint=16777215,this._width&&(this.scale.x=(0,u.Xx)(this.scale.x)*this._width/this._texture.orig.width),this._height&&(this.scale.y=(0,u.Xx)(this.scale.y)*this._height/this._texture.orig.height)},e.prototype._onAnchorUpdate=function(){this._transformID=-1,this._transformTrimmedID=-1},e.prototype.calculateVertices=function(){var t=this._texture;if(this._transformID!==this.transform._worldID||this._textureID!==t._updateID){this._textureID!==t._updateID&&(this.uvs=this._texture._uvs.uvsFloat32),this._transformID=this.transform._worldID,this._textureID=t._updateID;var e=this.transform.worldTransform,n=e.a,r=e.b,i=e.c,o=e.d,s=e.tx,u=e.ty,l=this.vertexData,c=t.trim,h=t.orig,f=this._anchor,d=0,p=0,v=0,m=0;if(c?(p=c.x-f._x*h.width,d=p+c.width,m=c.y-f._y*h.height,v=m+c.height):(p=-f._x*h.width,d=p+h.width,m=-f._y*h.height,v=m+h.height),l[0]=n*p+i*m+s,l[1]=o*m+r*p+u,l[2]=n*d+i*m+s,l[3]=o*m+r*d+u,l[4]=n*d+i*v+s,l[5]=o*v+r*d+u,l[6]=n*p+i*v+s,l[7]=o*v+r*p+u,this._roundPixels)for(var g=a.X.RESOLUTION,_=0;_<l.length;++_)l[_]=Math.round((l[_]*g|0)/g)}},e.prototype.calculateTrimmedVertices=function(){if(this.vertexTrimmedData){if(this._transformTrimmedID===this.transform._worldID&&this._textureTrimmedID===this._texture._updateID)return}else this.vertexTrimmedData=new Float32Array(8);this._transformTrimmedID=this.transform._worldID,this._textureTrimmedID=this._texture._updateID;var t=this._texture,e=this.vertexTrimmedData,n=t.orig,r=this._anchor,i=this.transform.worldTransform,o=i.a,s=i.b,a=i.c,u=i.d,l=i.tx,c=i.ty,h=-r._x*n.width,f=h+n.width,d=-r._y*n.height,p=d+n.height;e[0]=o*h+a*d+l,e[1]=u*d+s*h+c,e[2]=o*f+a*d+l,e[3]=u*d+s*f+c,e[4]=o*f+a*p+l,e[5]=u*p+s*f+c,e[6]=o*h+a*p+l,e[7]=u*p+s*h+c},e.prototype._render=function(t){this.calculateVertices(),t.batch.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this)},e.prototype._calculateBounds=function(){var t=this._texture.trim,e=this._texture.orig;!t||t.width===e.width&&t.height===e.height?(this.calculateVertices(),this._bounds.addQuad(this.vertexData)):(this.calculateTrimmedVertices(),this._bounds.addQuad(this.vertexTrimmedData))},e.prototype.getLocalBounds=function(e){return 0===this.children.length?(this._localBounds||(this._localBounds=new o.YZ),this._localBounds.minX=this._texture.orig.width*-this._anchor._x,this._localBounds.minY=this._texture.orig.height*-this._anchor._y,this._localBounds.maxX=this._texture.orig.width*(1-this._anchor._x),this._localBounds.maxY=this._texture.orig.height*(1-this._anchor._y),e||(this._localBoundsRect||(this._localBoundsRect=new s.Ae),e=this._localBoundsRect),this._localBounds.getRectangle(e)):t.prototype.getLocalBounds.call(this,e)},e.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,h);var e=this._texture.orig.width,n=this._texture.orig.height,r=-e*this.anchor.x,i=0;return h.x>=r&&h.x<r+e&&(i=-n*this.anchor.y,h.y>=i&&h.y<i+n)},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this._texture.off("update",this._onTextureUpdate,this),this._anchor=null;var n="boolean"===typeof e?e:e&&e.texture;if(n){var r="boolean"===typeof e?e:e&&e.baseTexture;this._texture.destroy(!!r)}this._texture=null},e.from=function(t,n){var r=t instanceof i.xE?t:i.xE.from(t,n);return new e(r)},Object.defineProperty(e.prototype,"roundPixels",{get:function(){return this._roundPixels},set:function(t){this._roundPixels!==t&&(this._transformID=-1),this._roundPixels=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"width",{get:function(){return Math.abs(this.scale.x)*this._texture.orig.width},set:function(t){var e=(0,u.Xx)(this.scale.x)||1;this.scale.x=e*t/this._texture.orig.width,this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return Math.abs(this.scale.y)*this._texture.orig.height},set:function(t){var e=(0,u.Xx)(this.scale.y)||1;this.scale.y=e*t/this._texture.orig.height,this._height=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"anchor",{get:function(){return this._anchor},set:function(t){this._anchor.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){this._tint=t,this._tintRGB=(t>>16)+(65280&t)+((255&t)<<16)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"texture",{get:function(){return this._texture},set:function(t){this._texture!==t&&(this._texture&&this._texture.off("update",this._onTextureUpdate,this),this._texture=t||i.xE.EMPTY,this._cachedTint=16777215,this._textureID=-1,this._textureTrimmedID=-1,t&&(t.baseTexture.valid?this._onTextureUpdate():t.once("update",this._onTextureUpdate,this)))},enumerable:!1,configurable:!0}),e}(o.W2)},6679:function(t,e,n){"use strict";n.d(e,{vB:function(){return s},Sb:function(){return a},uF:function(){return r}});var r,i=n(1576); -/*! - * @pixi/ticker - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/ticker is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */i.X.TARGET_FPMS=.06,function(t){t[t["INTERACTION"]=50]="INTERACTION",t[t["HIGH"]=25]="HIGH",t[t["NORMAL"]=0]="NORMAL",t[t["LOW"]=-25]="LOW",t[t["UTILITY"]=-50]="UTILITY"}(r||(r={}));var o=function(){function t(t,e,n,r){void 0===e&&(e=null),void 0===n&&(n=0),void 0===r&&(r=!1),this.next=null,this.previous=null,this._destroyed=!1,this.fn=t,this.context=e,this.priority=n,this.once=r}return t.prototype.match=function(t,e){return void 0===e&&(e=null),this.fn===t&&this.context===e},t.prototype.emit=function(t){this.fn&&(this.context?this.fn.call(this.context,t):this.fn(t));var e=this.next;return this.once&&this.destroy(!0),this._destroyed&&(this.next=null),e},t.prototype.connect=function(t){this.previous=t,t.next&&(t.next.previous=this),this.next=t.next,t.next=this},t.prototype.destroy=function(t){void 0===t&&(t=!1),this._destroyed=!0,this.fn=null,this.context=null,this.previous&&(this.previous.next=this.next),this.next&&(this.next.previous=this.previous);var e=this.next;return this.next=t?null:e,this.previous=null,e},t}(),s=function(){function t(){var t=this;this.autoStart=!1,this.deltaTime=1,this.lastTime=-1,this.speed=1,this.started=!1,this._requestId=null,this._maxElapsedMS=100,this._minElapsedMS=0,this._protected=!1,this._lastFrame=-1,this._head=new o(null,null,1/0),this.deltaMS=1/i.X.TARGET_FPMS,this.elapsedMS=1/i.X.TARGET_FPMS,this._tick=function(e){t._requestId=null,t.started&&(t.update(e),t.started&&null===t._requestId&&t._head.next&&(t._requestId=requestAnimationFrame(t._tick)))}}return t.prototype._requestIfNeeded=function(){null===this._requestId&&this._head.next&&(this.lastTime=performance.now(),this._lastFrame=this.lastTime,this._requestId=requestAnimationFrame(this._tick))},t.prototype._cancelIfNeeded=function(){null!==this._requestId&&(cancelAnimationFrame(this._requestId),this._requestId=null)},t.prototype._startIfPossible=function(){this.started?this._requestIfNeeded():this.autoStart&&this.start()},t.prototype.add=function(t,e,n){return void 0===n&&(n=r.NORMAL),this._addListener(new o(t,e,n))},t.prototype.addOnce=function(t,e,n){return void 0===n&&(n=r.NORMAL),this._addListener(new o(t,e,n,!0))},t.prototype._addListener=function(t){var e=this._head.next,n=this._head;if(e){while(e){if(t.priority>e.priority){t.connect(n);break}n=e,e=e.next}t.previous||t.connect(n)}else t.connect(n);return this._startIfPossible(),this},t.prototype.remove=function(t,e){var n=this._head.next;while(n)n=n.match(t,e)?n.destroy():n.next;return this._head.next||this._cancelIfNeeded(),this},Object.defineProperty(t.prototype,"count",{get:function(){if(!this._head)return 0;var t=0,e=this._head;while(e=e.next)t++;return t},enumerable:!1,configurable:!0}),t.prototype.start=function(){this.started||(this.started=!0,this._requestIfNeeded())},t.prototype.stop=function(){this.started&&(this.started=!1,this._cancelIfNeeded())},t.prototype.destroy=function(){if(!this._protected){this.stop();var t=this._head.next;while(t)t=t.destroy(!0);this._head.destroy(),this._head=null}},t.prototype.update=function(t){var e;if(void 0===t&&(t=performance.now()),t>this.lastTime){if(e=this.elapsedMS=t-this.lastTime,e>this._maxElapsedMS&&(e=this._maxElapsedMS),e*=this.speed,this._minElapsedMS){var n=t-this._lastFrame|0;if(n<this._minElapsedMS)return;this._lastFrame=t-n%this._minElapsedMS}this.deltaMS=e,this.deltaTime=this.deltaMS*i.X.TARGET_FPMS;var r=this._head,o=r.next;while(o)o=o.emit(this.deltaTime);r.next||this._cancelIfNeeded()}else this.deltaTime=this.deltaMS=this.elapsedMS=0;this.lastTime=t},Object.defineProperty(t.prototype,"FPS",{get:function(){return 1e3/this.elapsedMS},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"minFPS",{get:function(){return 1e3/this._maxElapsedMS},set:function(t){var e=Math.min(this.maxFPS,t),n=Math.min(Math.max(0,e)/1e3,i.X.TARGET_FPMS);this._maxElapsedMS=1/n},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"maxFPS",{get:function(){return this._minElapsedMS?Math.round(1e3/this._minElapsedMS):0},set:function(t){if(0===t)this._minElapsedMS=0;else{var e=Math.max(this.minFPS,t);this._minElapsedMS=1/(e/1e3)}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"shared",{get:function(){if(!t._shared){var e=t._shared=new t;e.autoStart=!0,e._protected=!0}return t._shared},enumerable:!1,configurable:!0}),Object.defineProperty(t,"system",{get:function(){if(!t._system){var e=t._system=new t;e.autoStart=!0,e._protected=!0}return t._system},enumerable:!1,configurable:!0}),t}(),a=function(){function t(){}return t.init=function(t){var e=this;t=Object.assign({autoStart:!0,sharedTicker:!1},t),Object.defineProperty(this,"ticker",{set:function(t){this._ticker&&this._ticker.remove(this.render,this),this._ticker=t,t&&t.add(this.render,this,r.LOW)},get:function(){return this._ticker}}),this.stop=function(){e._ticker.stop()},this.start=function(){e._ticker.start()},this._ticker=null,this.ticker=t.sharedTicker?s.shared:new s,t.autoStart&&this.start()},t.destroy=function(){if(this._ticker){var t=this._ticker;this.ticker=null,t.destroy()}},t}()},8942:function(t,e,n){"use strict";n.d(e,{tq:function(){return r.t},vp:function(){return o.a},OT:function(){return a.a},V8:function(){return An},qU:function(){return On},GG:function(){return Sn},kN:function(){return Rn},D:function(){return ln},fl:function(){return dn},a1:function(){return Tn},Qq:function(){return Pn},u7:function(){return pn},fL:function(){return Cn},wK:function(){return rn},XN:function(){return on},wv:function(){return mn},HR:function(){return v},k3:function(){return gn},a9:function(){return vn},YA:function(){return un},Qt:function(){return cn},rA:function(){return hn},GT:function(){return fn},Er:function(){return _n},DE:function(){return p},Xx:function(){return yn},qm:function(){return sn},yA:function(){return wn},hQ:function(){return En},HQ:function(){return c}});var r=n(1576),i=n(8718),o=n.n(i),s=n(9187),a=n.n(s),u=n(8575),l=n(1680),c={parse:u.Qc,format:u.WU,resolve:u.DB};r.X.RETINA_PREFIX=/@([0-9\.]+)x/,r.X.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT=!1;var h,f=!1,d="6.3.0";function p(t){var e;if(!f){if(navigator.userAgent.toLowerCase().indexOf("chrome")>-1){var n=["\n %c %c %c PixiJS "+d+" - ✰ "+t+" ✰ %c %c http://www.pixijs.com/ %c %c ♥%c♥%c♥ \n\n","background: #ff66a5; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff66a5; background: #030307; padding:5px 0;","background: #ff66a5; padding:5px 0;","background: #ffc3dc; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;"];(e=globalThis.console).log.apply(e,n)}else globalThis.console&&globalThis.console.log("PixiJS "+d+" - "+t+" - http://www.pixijs.com/");f=!0}}function v(){return"undefined"===typeof h&&(h=function(){var t={stencil:!0,failIfMajorPerformanceCaveat:r.X.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT};try{if(!globalThis.WebGLRenderingContext)return!1;var e=document.createElement("canvas"),n=e.getContext("webgl",t)||e.getContext("experimental-webgl",t),i=!(!n||!n.getContextAttributes().stencil);if(n){var o=n.getExtension("WEBGL_lose_context");o&&o.loseContext()}return n=null,i}catch(s){return!1}}()),h}var m="#f0f8ff",g="#faebd7",_="#00ffff",y="#7fffd4",b="#f0ffff",E="#f5f5dc",x="#ffe4c4",T="#000000",S="#ffebcd",R="#0000ff",A="#8a2be2",O="#a52a2a",w="#deb887",I="#5f9ea0",P="#7fff00",C="#d2691e",N="#ff7f50",M="#6495ed",D="#fff8dc",L="#dc143c",F="#00ffff",B="#00008b",U="#008b8b",G="#b8860b",k="#a9a9a9",X="#006400",j="#a9a9a9",H="#bdb76b",V="#8b008b",Y="#556b2f",W="#ff8c00",z="#9932cc",$="#8b0000",q="#e9967a",K="#8fbc8f",Z="#483d8b",J="#2f4f4f",Q="#2f4f4f",tt="#00ced1",et="#9400d3",nt="#ff1493",rt="#00bfff",it="#696969",ot="#696969",st="#1e90ff",at="#b22222",ut="#fffaf0",lt="#228b22",ct="#ff00ff",ht="#dcdcdc",ft="#f8f8ff",dt="#daa520",pt="#ffd700",vt="#808080",mt="#008000",gt="#adff2f",_t="#808080",yt="#f0fff0",bt="#ff69b4",Et="#cd5c5c",xt="#4b0082",Tt="#fffff0",St="#f0e68c",Rt="#fff0f5",At="#e6e6fa",Ot="#7cfc00",wt="#fffacd",It="#add8e6",Pt="#f08080",Ct="#e0ffff",Nt="#fafad2",Mt="#d3d3d3",Dt="#90ee90",Lt="#d3d3d3",Ft="#ffb6c1",Bt="#ffa07a",Ut="#20b2aa",Gt="#87cefa",kt="#778899",Xt="#778899",jt="#b0c4de",Ht="#ffffe0",Vt="#00ff00",Yt="#32cd32",Wt="#faf0e6",zt="#ff00ff",$t="#800000",qt="#66cdaa",Kt="#0000cd",Zt="#ba55d3",Jt="#9370db",Qt="#3cb371",te="#7b68ee",ee="#00fa9a",ne="#48d1cc",re="#c71585",ie="#191970",oe="#f5fffa",se="#ffe4e1",ae="#ffe4b5",ue="#ffdead",le="#000080",ce="#fdf5e6",he="#808000",fe="#6b8e23",de="#ffa500",pe="#ff4500",ve="#da70d6",me="#eee8aa",ge="#98fb98",_e="#afeeee",ye="#db7093",be="#ffefd5",Ee="#ffdab9",xe="#cd853f",Te="#ffc0cb",Se="#dda0dd",Re="#b0e0e6",Ae="#800080",Oe="#663399",we="#ff0000",Ie="#bc8f8f",Pe="#4169e1",Ce="#8b4513",Ne="#fa8072",Me="#f4a460",De="#2e8b57",Le="#fff5ee",Fe="#a0522d",Be="#c0c0c0",Ue="#87ceeb",Ge="#6a5acd",ke="#708090",Xe="#708090",je="#fffafa",He="#00ff7f",Ve="#4682b4",Ye="#d2b48c",We="#008080",ze="#d8bfd8",$e="#ff6347",qe="#40e0d0",Ke="#ee82ee",Ze="#f5deb3",Je="#ffffff",Qe="#f5f5f5",tn="#ffff00",en="#9acd32",nn={aliceblue:m,antiquewhite:g,aqua:_,aquamarine:y,azure:b,beige:E,bisque:x,black:T,blanchedalmond:S,blue:R,blueviolet:A,brown:O,burlywood:w,cadetblue:I,chartreuse:P,chocolate:C,coral:N,cornflowerblue:M,cornsilk:D,crimson:L,cyan:F,darkblue:B,darkcyan:U,darkgoldenrod:G,darkgray:k,darkgreen:X,darkgrey:j,darkkhaki:H,darkmagenta:V,darkolivegreen:Y,darkorange:W,darkorchid:z,darkred:$,darksalmon:q,darkseagreen:K,darkslateblue:Z,darkslategray:J,darkslategrey:Q,darkturquoise:tt,darkviolet:et,deeppink:nt,deepskyblue:rt,dimgray:it,dimgrey:ot,dodgerblue:st,firebrick:at,floralwhite:ut,forestgreen:lt,fuchsia:ct,gainsboro:ht,ghostwhite:ft,goldenrod:dt,gold:pt,gray:vt,green:mt,greenyellow:gt,grey:_t,honeydew:yt,hotpink:bt,indianred:Et,indigo:xt,ivory:Tt,khaki:St,lavenderblush:Rt,lavender:At,lawngreen:Ot,lemonchiffon:wt,lightblue:It,lightcoral:Pt,lightcyan:Ct,lightgoldenrodyellow:Nt,lightgray:Mt,lightgreen:Dt,lightgrey:Lt,lightpink:Ft,lightsalmon:Bt,lightseagreen:Ut,lightskyblue:Gt,lightslategray:kt,lightslategrey:Xt,lightsteelblue:jt,lightyellow:Ht,lime:Vt,limegreen:Yt,linen:Wt,magenta:zt,maroon:$t,mediumaquamarine:qt,mediumblue:Kt,mediumorchid:Zt,mediumpurple:Jt,mediumseagreen:Qt,mediumslateblue:te,mediumspringgreen:ee,mediumturquoise:ne,mediumvioletred:re,midnightblue:ie,mintcream:oe,mistyrose:se,moccasin:ae,navajowhite:ue,navy:le,oldlace:ce,olive:he,olivedrab:fe,orange:de,orangered:pe,orchid:ve,palegoldenrod:me,palegreen:ge,paleturquoise:_e,palevioletred:ye,papayawhip:be,peachpuff:Ee,peru:xe,pink:Te,plum:Se,powderblue:Re,purple:Ae,rebeccapurple:Oe,red:we,rosybrown:Ie,royalblue:Pe,saddlebrown:Ce,salmon:Ne,sandybrown:Me,seagreen:De,seashell:Le,sienna:Fe,silver:Be,skyblue:Ue,slateblue:Ge,slategray:ke,slategrey:Xe,snow:je,springgreen:He,steelblue:Ve,tan:Ye,teal:We,thistle:ze,tomato:$e,turquoise:qe,violet:Ke,wheat:Ze,white:Je,whitesmoke:Qe,yellow:tn,yellowgreen:en};function rn(t,e){return void 0===e&&(e=[]),e[0]=(t>>16&255)/255,e[1]=(t>>8&255)/255,e[2]=(255&t)/255,e}function on(t){var e=t.toString(16);return e="000000".substring(0,6-e.length)+e,"#"+e}function sn(t){return"string"===typeof t&&(t=nn[t.toLowerCase()]||t,"#"===t[0]&&(t=t.slice(1))),parseInt(t,16)}function an(){for(var t=[],e=[],n=0;n<32;n++)t[n]=n,e[n]=n;t[l.T$.NORMAL_NPM]=l.T$.NORMAL,t[l.T$.ADD_NPM]=l.T$.ADD,t[l.T$.SCREEN_NPM]=l.T$.SCREEN,e[l.T$.NORMAL]=l.T$.NORMAL_NPM,e[l.T$.ADD]=l.T$.ADD_NPM,e[l.T$.SCREEN]=l.T$.SCREEN_NPM;var r=[];return r.push(e),r.push(t),r}var un=an();function ln(t,e){return un[e?1:0][t]}function cn(t,e,n,r){return n=n||new Float32Array(4),r||void 0===r?(n[0]=t[0]*e,n[1]=t[1]*e,n[2]=t[2]*e):(n[0]=t[0],n[1]=t[1],n[2]=t[2]),n[3]=e,n}function hn(t,e){if(1===e)return(255*e<<24)+t;if(0===e)return 0;var n=t>>16&255,r=t>>8&255,i=255&t;return n=n*e+.5|0,r=r*e+.5|0,i=i*e+.5|0,(255*e<<24)+(n<<16)+(r<<8)+i}function fn(t,e,n,r){return n=n||new Float32Array(4),n[0]=(t>>16&255)/255,n[1]=(t>>8&255)/255,n[2]=(255&t)/255,(r||void 0===r)&&(n[0]*=e,n[1]*=e,n[2]*=e),n[3]=e,n}function dn(t,e){void 0===e&&(e=null);var n=6*t;if(e=e||new Uint16Array(n),e.length!==n)throw new Error("Out buffer length is incorrect, got "+e.length+" and expected "+n);for(var r=0,i=0;r<n;r+=6,i+=4)e[r+0]=i+0,e[r+1]=i+1,e[r+2]=i+2,e[r+3]=i+0,e[r+4]=i+2,e[r+5]=i+3;return e}function pn(t){if(4===t.BYTES_PER_ELEMENT)return t instanceof Float32Array?"Float32Array":t instanceof Uint32Array?"Uint32Array":"Int32Array";if(2===t.BYTES_PER_ELEMENT){if(t instanceof Uint16Array)return"Uint16Array"}else if(1===t.BYTES_PER_ELEMENT&&t instanceof Uint8Array)return"Uint8Array";return null}Float32Array,Uint32Array,Int32Array,Uint8Array;function vn(t){return t+=0===t?1:0,--t,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t+1}function mn(t){return!(t&t-1)&&!!t}function gn(t){var e=(t>65535?1:0)<<4;t>>>=e;var n=(t>255?1:0)<<3;return t>>>=n,e|=n,n=(t>15?1:0)<<2,t>>>=n,e|=n,n=(t>3?1:0)<<1,t>>>=n,e|=n,e|t>>1}function _n(t,e,n){var r,i=t.length;if(!(e>=i||0===n)){n=e+n>i?i-e:n;var o=i-n;for(r=e;r<o;++r)t[r]=t[r+n];t.length=o}}function yn(t){return 0===t?0:t<0?-1:1}var bn=0;function En(){return++bn}var xn={};function Tn(t,e,n){if(void 0===n&&(n=3),!xn[e]){var r=(new Error).stack;"undefined"===typeof r?console.warn("PixiJS Deprecation Warning: ",e+"\nDeprecated since v"+t):(r=r.split("\n").splice(n).join("\n"),console.groupCollapsed?(console.groupCollapsed("%cPixiJS Deprecation Warning: %c%s","color:#614108;background:#fffbe6","font-weight:normal;color:#614108;background:#fffbe6",e+"\nDeprecated since v"+t),console.warn(r),console.groupEnd()):(console.warn("PixiJS Deprecation Warning: ",e+"\nDeprecated since v"+t),console.warn(r))),xn[e]=!0}}var Sn={},Rn=Object.create(null),An=Object.create(null);var On=function(){function t(t,e,n){this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d"),this.resolution=n||r.X.RESOLUTION,this.resize(t,e)}return t.prototype.clear=function(){this.context.setTransform(1,0,0,1,0,0),this.context.clearRect(0,0,this.canvas.width,this.canvas.height)},t.prototype.resize=function(t,e){this.canvas.width=Math.round(t*this.resolution),this.canvas.height=Math.round(e*this.resolution)},t.prototype.destroy=function(){this.context=null,this.canvas=null},Object.defineProperty(t.prototype,"width",{get:function(){return this.canvas.width},set:function(t){this.canvas.width=Math.round(t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this.canvas.height},set:function(t){this.canvas.height=Math.round(t)},enumerable:!1,configurable:!0}),t}();function wn(t){var e,n,r,i=t.width,o=t.height,s=t.getContext("2d"),a=s.getImageData(0,0,i,o),u=a.data,l=u.length,c={top:null,left:null,right:null,bottom:null},h=null;for(e=0;e<l;e+=4)0!==u[e+3]&&(n=e/4%i,r=~~(e/4/i),null===c.top&&(c.top=r),(null===c.left||n<c.left)&&(c.left=n),(null===c.right||c.right<n)&&(c.right=n+1),(null===c.bottom||c.bottom<r)&&(c.bottom=r));return null!==c.top&&(i=c.right-c.left,o=c.bottom-c.top+1,h=s.getImageData(c.left,c.top,i,o)),{height:o,width:i,data:h}}var In;function Pn(t,e){if(void 0===e&&(e=globalThis.location),0===t.indexOf("data:"))return"";e=e||globalThis.location,In||(In=document.createElement("a")),In.href=t;var n=c.parse(In.href),r=!n.port&&""===e.port||n.port===e.port;return n.hostname===e.hostname&&r&&n.protocol===e.protocol?"":"anonymous"}function Cn(t,e){var n=r.X.RETINA_PREFIX.exec(t);return n?parseFloat(n[1]):void 0!==e?e:1}},8718:function(t){"use strict";var e=Object.prototype.hasOwnProperty,n="~";function r(){}function i(t,e,n){this.fn=t,this.context=e,this.once=n||!1}function o(t,e,r,o,s){if("function"!==typeof r)throw new TypeError("The listener must be a function");var a=new i(r,o||t,s),u=n?n+e:e;return t._events[u]?t._events[u].fn?t._events[u]=[t._events[u],a]:t._events[u].push(a):(t._events[u]=a,t._eventsCount++),t}function s(t,e){0===--t._eventsCount?t._events=new r:delete t._events[e]}function a(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),a.prototype.eventNames=function(){var t,r,i=[];if(0===this._eventsCount)return i;for(r in t=this._events)e.call(t,r)&&i.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(t)):i},a.prototype.listeners=function(t){var e=n?n+t:t,r=this._events[e];if(!r)return[];if(r.fn)return[r.fn];for(var i=0,o=r.length,s=new Array(o);i<o;i++)s[i]=r[i].fn;return s},a.prototype.listenerCount=function(t){var e=n?n+t:t,r=this._events[e];return r?r.fn?1:r.length:0},a.prototype.emit=function(t,e,r,i,o,s){var a=n?n+t:t;if(!this._events[a])return!1;var u,l,c=this._events[a],h=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),h){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,r),!0;case 4:return c.fn.call(c.context,e,r,i),!0;case 5:return c.fn.call(c.context,e,r,i,o),!0;case 6:return c.fn.call(c.context,e,r,i,o,s),!0}for(l=1,u=new Array(h-1);l<h;l++)u[l-1]=arguments[l];c.fn.apply(c.context,u)}else{var f,d=c.length;for(l=0;l<d;l++)switch(c[l].once&&this.removeListener(t,c[l].fn,void 0,!0),h){case 1:c[l].fn.call(c[l].context);break;case 2:c[l].fn.call(c[l].context,e);break;case 3:c[l].fn.call(c[l].context,e,r);break;case 4:c[l].fn.call(c[l].context,e,r,i);break;default:if(!u)for(f=1,u=new Array(h-1);f<h;f++)u[f-1]=arguments[f];c[l].fn.apply(c[l].context,u)}}return!0},a.prototype.on=function(t,e,n){return o(this,t,e,n,!1)},a.prototype.once=function(t,e,n){return o(this,t,e,n,!0)},a.prototype.removeListener=function(t,e,r,i){var o=n?n+t:t;if(!this._events[o])return this;if(!e)return s(this,o),this;var a=this._events[o];if(a.fn)a.fn!==e||i&&!a.once||r&&a.context!==r||s(this,o);else{for(var u=0,l=[],c=a.length;u<c;u++)(a[u].fn!==e||i&&!a[u].once||r&&a[u].context!==r)&&l.push(a[u]);l.length?this._events[o]=1===l.length?l[0]:l:s(this,o)}return this},a.prototype.removeAllListeners=function(t){var e;return t?(e=n?n+t:t,this._events[e]&&s(this,e)):(this._events=new r,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=n,a.EventEmitter=a,t.exports=a},3577:function(t,e,n){"use strict";function r(t,e){const n=Object.create(null),r=t.split(",");for(let i=0;i<r.length;i++)n[r[i]]=!0;return e?t=>!!n[t.toLowerCase()]:t=>!!n[t]}n.d(e,{Z6:function(){return P},kT:function(){return I},NO:function(){return N},dG:function(){return C},m:function(){return i},_A:function(){return rt},kC:function(){return st},Nj:function(){return ct},l7:function(){return F},Kp:function(){return u},E9:function(){return dt},aU:function(){return ut},RI:function(){return G},rs:function(){return ot},yA:function(){return h},ir:function(){return lt},kJ:function(){return k},mf:function(){return V},e1:function(){return s},eS:function(){return E},S0:function(){return Q},_N:function(){return X},tR:function(){return L},Kn:function(){return z},F7:function(){return D},PO:function(){return J},tI:function(){return $},Gg:function(){return tt},aN:function(){return x},DM:function(){return j},Pq:function(){return c},HD:function(){return Y},yk:function(){return W},WB:function(){return T},WV:function(){return R},hq:function(){return A},fY:function(){return r},C_:function(){return m},vs:function(){return g},j5:function(){return f},yL:function(){return v},Od:function(){return B},zw:function(){return O},hR:function(){return at},He:function(){return ht},W7:function(){return Z}});const i={[1]:"TEXT",[2]:"CLASS",[4]:"STYLE",[8]:"PROPS",[16]:"FULL_PROPS",[32]:"HYDRATE_EVENTS",[64]:"STABLE_FRAGMENT",[128]:"KEYED_FRAGMENT",[256]:"UNKEYED_FRAGMENT",[512]:"NEED_PATCH",[1024]:"DYNAMIC_SLOTS",[2048]:"DEV_ROOT_FRAGMENT",[-1]:"HOISTED",[-2]:"BAIL"},o="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt",s=r(o),a=2;function u(t,e=0,n=t.length){let r=t.split(/(\r?\n)/);const i=r.filter(((t,e)=>e%2===1));r=r.filter(((t,e)=>e%2===0));let o=0;const s=[];for(let u=0;u<r.length;u++)if(o+=r[u].length+(i[u]&&i[u].length||0),o>=e){for(let t=u-a;t<=u+a||n>o;t++){if(t<0||t>=r.length)continue;const a=t+1;s.push(`${a}${" ".repeat(Math.max(3-String(a).length,0))}| ${r[t]}`);const l=r[t].length,c=i[t]&&i[t].length||0;if(t===u){const t=e-(o-(l+c)),r=Math.max(1,n>o?l-t:n-e);s.push(" | "+" ".repeat(t)+"^".repeat(r))}else if(t>u){if(n>o){const t=Math.max(Math.min(n-o,l),1);s.push(" | "+"^".repeat(t))}o+=l+c}}break}return s.join("\n")}const l="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",c=r(l);function h(t){return!!t||""===t}function f(t){if(k(t)){const e={};for(let n=0;n<t.length;n++){const r=t[n],i=Y(r)?v(r):f(r);if(i)for(const t in i)e[t]=i[t]}return e}return Y(t)||z(t)?t:void 0}const d=/;(?![^(]*\))/g,p=/:(.+)/;function v(t){const e={};return t.split(d).forEach((t=>{if(t){const n=t.split(p);n.length>1&&(e[n[0].trim()]=n[1].trim())}})),e}function m(t){let e="";if(Y(t))e=t;else if(k(t))for(let n=0;n<t.length;n++){const r=m(t[n]);r&&(e+=r+" ")}else if(z(t))for(const n in t)t[n]&&(e+=n+" ");return e.trim()}function g(t){if(!t)return null;let{class:e,style:n}=t;return e&&!Y(e)&&(t.class=m(e)),n&&(t.style=f(n)),t}const _="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot",y="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",b="area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr",E=r(_),x=r(y),T=r(b);function S(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=R(t[r],e[r]);return n}function R(t,e){if(t===e)return!0;let n=H(t),r=H(e);if(n||r)return!(!n||!r)&&t.getTime()===e.getTime();if(n=k(t),r=k(e),n||r)return!(!n||!r)&&S(t,e);if(n=z(t),r=z(e),n||r){if(!n||!r)return!1;const i=Object.keys(t).length,o=Object.keys(e).length;if(i!==o)return!1;for(const n in t){const r=t.hasOwnProperty(n),i=e.hasOwnProperty(n);if(r&&!i||!r&&i||!R(t[n],e[n]))return!1}}return String(t)===String(e)}function A(t,e){return t.findIndex((t=>R(t,e)))}const O=t=>null==t?"":k(t)||z(t)&&(t.toString===q||!V(t.toString))?JSON.stringify(t,w,2):String(t),w=(t,e)=>e&&e.__v_isRef?w(t,e.value):X(e)?{[`Map(${e.size})`]:[...e.entries()].reduce(((t,[e,n])=>(t[`${e} =>`]=n,t)),{})}:j(e)?{[`Set(${e.size})`]:[...e.values()]}:!z(e)||k(e)||J(e)?e:String(e),I={},P=[],C=()=>{},N=()=>!1,M=/^on[^a-z]/,D=t=>M.test(t),L=t=>t.startsWith("onUpdate:"),F=Object.assign,B=(t,e)=>{const n=t.indexOf(e);n>-1&&t.splice(n,1)},U=Object.prototype.hasOwnProperty,G=(t,e)=>U.call(t,e),k=Array.isArray,X=t=>"[object Map]"===K(t),j=t=>"[object Set]"===K(t),H=t=>t instanceof Date,V=t=>"function"===typeof t,Y=t=>"string"===typeof t,W=t=>"symbol"===typeof t,z=t=>null!==t&&"object"===typeof t,$=t=>z(t)&&V(t.then)&&V(t.catch),q=Object.prototype.toString,K=t=>q.call(t),Z=t=>K(t).slice(8,-1),J=t=>"[object Object]"===K(t),Q=t=>Y(t)&&"NaN"!==t&&"-"!==t[0]&&""+parseInt(t,10)===t,tt=r(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),et=t=>{const e=Object.create(null);return n=>{const r=e[n];return r||(e[n]=t(n))}},nt=/-(\w)/g,rt=et((t=>t.replace(nt,((t,e)=>e?e.toUpperCase():"")))),it=/\B([A-Z])/g,ot=et((t=>t.replace(it,"-$1").toLowerCase())),st=et((t=>t.charAt(0).toUpperCase()+t.slice(1))),at=et((t=>t?`on${st(t)}`:"")),ut=(t,e)=>!Object.is(t,e),lt=(t,e)=>{for(let n=0;n<t.length;n++)t[n](e)},ct=(t,e,n)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:n})},ht=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let ft;const dt=()=>ft||(ft="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof self?self:"undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:{})},423:function(t,e,n){"use strict";n.d(e,{Z:function(){return u}});var r=n(4865);function i(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createBlock)(r.Transition,{name:n.name,onBeforeAppear:s.beforeAppear,onAppear:s.appear,onAfterAppear:s.afterAppear,onAppearCancelled:s.appearCancelled,onBeforeEnter:s.beforeEnter,onEnter:s.enter,onAfterEnter:s.afterEnter,onEnterCancelled:s.enterCancelled,onBeforeLeave:s.beforeLeave,onLeave:s.leave,onAfterLeave:s.afterLeave,onLeaveCancelled:s.leaveCancelled},{default:(0,r.withCtx)((()=>[(0,r.renderSlot)(t.$slots,"default")])),_:3},8,["name","onBeforeAppear","onAppear","onAfterAppear","onAppearCancelled","onBeforeEnter","onEnter","onAfterEnter","onEnterCancelled","onBeforeLeave","onLeave","onAfterLeave","onLeaveCancelled"])}var o={name:"CollapseTransition",props:{name:{type:String,required:!1,default:"collapse"},dimension:{type:String,required:!1,default:"height",validator:t=>["height","width"].includes(t)},duration:{type:Number,required:!1,default:300},easing:{type:String,required:!1,default:"ease-in-out"}},watch:{dimension(){this.clearCachedDimensions()}},data(){return{cachedStyles:null}},computed:{transition(){let t=[];return Object.keys(this.cachedStyles).forEach((e=>{t.push(`${this.convertToCssProperty(e)} ${this.duration}ms ${this.easing}`)})),t.join(", ")}},methods:{beforeAppear(t){this.$emit("before-appear",t)},appear(t){this.$emit("appear",t)},afterAppear(t){this.$emit("after-appear",t)},appearCancelled(t){this.$emit("appear-cancelled",t)},beforeEnter(t){this.$emit("before-enter",t)},enter(t,e){this.detectAndCacheDimensions(t),this.setClosedDimensions(t),this.hideOverflow(t),this.forceRepaint(t),this.setTransition(t),this.setOpenedDimensions(t),this.$emit("enter",t,e),setTimeout(e,this.duration)},afterEnter(t){this.unsetOverflow(t),this.unsetTransition(t),this.unsetDimensions(t),this.clearCachedDimensions(),this.$emit("after-enter",t)},enterCancelled(t){this.$emit("enter-cancelled",t)},beforeLeave(t){this.$emit("before-leave",t)},leave(t,e){this.detectAndCacheDimensions(t),this.setOpenedDimensions(t),this.hideOverflow(t),this.forceRepaint(t),this.setTransition(t),this.setClosedDimensions(t),this.$emit("leave",t,e),setTimeout(e,this.duration)},afterLeave(t){this.unsetOverflow(t),this.unsetTransition(t),this.unsetDimensions(t),this.clearCachedDimensions(),this.$emit("after-leave",t)},leaveCancelled(t){this.$emit("leave-cancelled",t)},detectAndCacheDimensions(t){if(this.cachedStyles)return;const e=t.style.visibility,n=t.style.display;t.style.visibility="hidden",t.style.display="",this.cachedStyles=this.detectRelevantDimensions(t),t.style.visibility=e,t.style.display=n},clearCachedDimensions(){this.cachedStyles=null},detectRelevantDimensions(t){return"height"===this.dimension?{height:t.offsetHeight+"px",paddingTop:t.style.paddingTop||this.getCssValue(t,"padding-top"),paddingBottom:t.style.paddingBottom||this.getCssValue(t,"padding-bottom")}:"width"===this.dimension?{width:t.offsetWidth+"px",paddingLeft:t.style.paddingLeft||this.getCssValue(t,"padding-left"),paddingRight:t.style.paddingRight||this.getCssValue(t,"padding-right")}:{}},setTransition(t){t.style.transition=this.transition},unsetTransition(t){t.style.transition=""},hideOverflow(t){t.style.overflow="hidden"},unsetOverflow(t){t.style.overflow=""},setClosedDimensions(t){Object.keys(this.cachedStyles).forEach((e=>{t.style[e]="0"}))},setOpenedDimensions(t){Object.keys(this.cachedStyles).forEach((e=>{t.style[e]=this.cachedStyles[e]}))},unsetDimensions(t){Object.keys(this.cachedStyles).forEach((e=>{t.style[e]=""}))},forceRepaint(t){getComputedStyle(t)[this.dimension]},getCssValue(t,e){return getComputedStyle(t,null).getPropertyValue(e)},convertToCssProperty(t){const e=t.match(/([A-Z])/g);if(!e)return t;for(let n=0,r=e.length;n<r;n++)t=t.replace(new RegExp(e[n]),"-"+e[n].toLowerCase());return"-"===t.slice(0,1)&&(t=t.slice(1)),t}}},s=n(3744);const a=(0,s.Z)(o,[["render",i]]);var u=a},9662:function(t,e,n){var r=n(7854),i=n(614),o=n(6330),s=r.TypeError;t.exports=function(t){if(i(t))return t;throw s(o(t)+" is not a function")}},9483:function(t,e,n){var r=n(7854),i=n(4411),o=n(6330),s=r.TypeError;t.exports=function(t){if(i(t))return t;throw s(o(t)+" is not a constructor")}},6077:function(t,e,n){var r=n(7854),i=n(614),o=r.String,s=r.TypeError;t.exports=function(t){if("object"==typeof t||i(t))return t;throw s("Can't set "+o(t)+" as a prototype")}},1223:function(t,e,n){var r=n(5112),i=n(30),o=n(3070),s=r("unscopables"),a=Array.prototype;void 0==a[s]&&o.f(a,s,{configurable:!0,value:i(null)}),t.exports=function(t){a[s][t]=!0}},1530:function(t,e,n){"use strict";var r=n(8710).charAt;t.exports=function(t,e,n){return e+(n?r(t,e).length:1)}},5787:function(t,e,n){var r=n(7854),i=n(7976),o=r.TypeError;t.exports=function(t,e){if(i(e,t))return t;throw o("Incorrect invocation")}},9670:function(t,e,n){var r=n(7854),i=n(111),o=r.String,s=r.TypeError;t.exports=function(t){if(i(t))return t;throw s(o(t)+" is not an object")}},2446:function(t,e,n){var r=n(7293);t.exports=r((function(){if("function"==typeof ArrayBuffer){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}}))},8533:function(t,e,n){"use strict";var r=n(2092).forEach,i=n(9341),o=i("forEach");t.exports=o?[].forEach:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}},8457:function(t,e,n){"use strict";var r=n(7854),i=n(9974),o=n(6916),s=n(7908),a=n(3411),u=n(7659),l=n(4411),c=n(6244),h=n(6135),f=n(8554),d=n(1246),p=r.Array;t.exports=function(t){var e=s(t),n=l(this),r=arguments.length,v=r>1?arguments[1]:void 0,m=void 0!==v;m&&(v=i(v,r>2?arguments[2]:void 0));var g,_,y,b,E,x,T=d(e),S=0;if(!T||this==p&&u(T))for(g=c(e),_=n?new this(g):p(g);g>S;S++)x=m?v(e[S],S):e[S],h(_,S,x);else for(b=f(e,T),E=b.next,_=n?new this:[];!(y=o(E,b)).done;S++)x=m?a(b,v,[y.value,S],!0):y.value,h(_,S,x);return _.length=S,_}},1318:function(t,e,n){var r=n(5656),i=n(1400),o=n(6244),s=function(t){return function(e,n,s){var a,u=r(e),l=o(u),c=i(s,l);if(t&&n!=n){while(l>c)if(a=u[c++],a!=a)return!0}else for(;l>c;c++)if((t||c in u)&&u[c]===n)return t||c||0;return!t&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},2092:function(t,e,n){var r=n(9974),i=n(1702),o=n(8361),s=n(7908),a=n(6244),u=n(5417),l=i([].push),c=function(t){var e=1==t,n=2==t,i=3==t,c=4==t,h=6==t,f=7==t,d=5==t||h;return function(p,v,m,g){for(var _,y,b=s(p),E=o(b),x=r(v,m),T=a(E),S=0,R=g||u,A=e?R(p,T):n||f?R(p,0):void 0;T>S;S++)if((d||S in E)&&(_=E[S],y=x(_,S,b),t))if(e)A[S]=y;else if(y)switch(t){case 3:return!0;case 5:return _;case 6:return S;case 2:l(A,_)}else switch(t){case 4:return!1;case 7:l(A,_)}return h?-1:i||c?c:A}};t.exports={forEach:c(0),map:c(1),filter:c(2),some:c(3),every:c(4),find:c(5),findIndex:c(6),filterReject:c(7)}},1194:function(t,e,n){var r=n(7293),i=n(5112),o=n(7392),s=i("species");t.exports=function(t){return o>=51||!r((function(){var e=[],n=e.constructor={};return n[s]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},9341:function(t,e,n){"use strict";var r=n(7293);t.exports=function(t,e){var n=[][t];return!!n&&r((function(){n.call(null,e||function(){throw 1},1)}))}},1589:function(t,e,n){var r=n(7854),i=n(1400),o=n(6244),s=n(6135),a=r.Array,u=Math.max;t.exports=function(t,e,n){for(var r=o(t),l=i(e,r),c=i(void 0===n?r:n,r),h=a(u(c-l,0)),f=0;l<c;l++,f++)s(h,f,t[l]);return h.length=f,h}},206:function(t,e,n){var r=n(1702);t.exports=r([].slice)},7475:function(t,e,n){var r=n(7854),i=n(3157),o=n(4411),s=n(111),a=n(5112),u=a("species"),l=r.Array;t.exports=function(t){var e;return i(t)&&(e=t.constructor,o(e)&&(e===l||i(e.prototype))?e=void 0:s(e)&&(e=e[u],null===e&&(e=void 0))),void 0===e?l:e}},5417:function(t,e,n){var r=n(7475);t.exports=function(t,e){return new(r(t))(0===e?0:e)}},3411:function(t,e,n){var r=n(9670),i=n(9212);t.exports=function(t,e,n,o){try{return o?e(r(n)[0],n[1]):e(n)}catch(s){i(t,"throw",s)}}},7072:function(t,e,n){var r=n(5112),i=r("iterator"),o=!1;try{var s=0,a={next:function(){return{done:!!s++}},return:function(){o=!0}};a[i]=function(){return this},Array.from(a,(function(){throw 2}))}catch(u){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var r={};r[i]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(u){}return n}},4326:function(t,e,n){var r=n(1702),i=r({}.toString),o=r("".slice);t.exports=function(t){return o(i(t),8,-1)}},648:function(t,e,n){var r=n(7854),i=n(1694),o=n(614),s=n(4326),a=n(5112),u=a("toStringTag"),l=r.Object,c="Arguments"==s(function(){return arguments}()),h=function(t,e){try{return t[e]}catch(n){}};t.exports=i?s:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=h(e=l(t),u))?n:c?s(e):"Object"==(r=s(e))&&o(e.callee)?"Arguments":r}},7741:function(t,e,n){var r=n(1702),i=r("".replace),o=function(t){return String(Error(t).stack)}("zxcasd"),s=/\n\s*at [^:]*:[^\n]*/,a=s.test(o);t.exports=function(t,e){if(a&&"string"==typeof t)while(e--)t=i(t,s,"");return t}},5631:function(t,e,n){"use strict";var r=n(3070).f,i=n(30),o=n(2248),s=n(9974),a=n(5787),u=n(408),l=n(654),c=n(6340),h=n(9781),f=n(2423).fastKey,d=n(9909),p=d.set,v=d.getterFor;t.exports={getConstructor:function(t,e,n,l){var c=t((function(t,r){a(t,d),p(t,{type:e,index:i(null),first:void 0,last:void 0,size:0}),h||(t.size=0),void 0!=r&&u(r,t[l],{that:t,AS_ENTRIES:n})})),d=c.prototype,m=v(e),g=function(t,e,n){var r,i,o=m(t),s=_(t,e);return s?s.value=n:(o.last=s={index:i=f(e,!0),key:e,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=s),r&&(r.next=s),h?o.size++:t.size++,"F"!==i&&(o.index[i]=s)),t},_=function(t,e){var n,r=m(t),i=f(e);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==e)return n};return o(d,{clear:function(){var t=this,e=m(t),n=e.index,r=e.first;while(r)r.removed=!0,r.previous&&(r.previous=r.previous.next=void 0),delete n[r.index],r=r.next;e.first=e.last=void 0,h?e.size=0:t.size=0},delete:function(t){var e=this,n=m(e),r=_(e,t);if(r){var i=r.next,o=r.previous;delete n.index[r.index],r.removed=!0,o&&(o.next=i),i&&(i.previous=o),n.first==r&&(n.first=i),n.last==r&&(n.last=o),h?n.size--:e.size--}return!!r},forEach:function(t){var e,n=m(this),r=s(t,arguments.length>1?arguments[1]:void 0);while(e=e?e.next:n.first){r(e.value,e.key,this);while(e&&e.removed)e=e.previous}},has:function(t){return!!_(this,t)}}),o(d,n?{get:function(t){var e=_(this,t);return e&&e.value},set:function(t,e){return g(this,0===t?0:t,e)}}:{add:function(t){return g(this,t=0===t?0:t,t)}}),h&&r(d,"size",{get:function(){return m(this).size}}),c},setStrong:function(t,e,n){var r=e+" Iterator",i=v(e),o=v(r);l(t,e,(function(t,e){p(this,{type:r,target:t,state:i(t),kind:e,last:void 0})}),(function(){var t=o(this),e=t.kind,n=t.last;while(n&&n.removed)n=n.previous;return t.target&&(t.last=n=n?n.next:t.state.first)?"keys"==e?{value:n.key,done:!1}:"values"==e?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(t.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),c(e)}}},7710:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(1702),s=n(4705),a=n(1320),u=n(2423),l=n(408),c=n(5787),h=n(614),f=n(111),d=n(7293),p=n(7072),v=n(8003),m=n(9587);t.exports=function(t,e,n){var g=-1!==t.indexOf("Map"),_=-1!==t.indexOf("Weak"),y=g?"set":"add",b=i[t],E=b&&b.prototype,x=b,T={},S=function(t){var e=o(E[t]);a(E,t,"add"==t?function(t){return e(this,0===t?0:t),this}:"delete"==t?function(t){return!(_&&!f(t))&&e(this,0===t?0:t)}:"get"==t?function(t){return _&&!f(t)?void 0:e(this,0===t?0:t)}:"has"==t?function(t){return!(_&&!f(t))&&e(this,0===t?0:t)}:function(t,n){return e(this,0===t?0:t,n),this})},R=s(t,!h(b)||!(_||E.forEach&&!d((function(){(new b).entries().next()}))));if(R)x=n.getConstructor(e,t,g,y),u.enable();else if(s(t,!0)){var A=new x,O=A[y](_?{}:-0,1)!=A,w=d((function(){A.has(1)})),I=p((function(t){new b(t)})),P=!_&&d((function(){var t=new b,e=5;while(e--)t[y](e,e);return!t.has(-0)}));I||(x=e((function(t,e){c(t,E);var n=m(new b,t,x);return void 0!=e&&l(e,n[y],{that:n,AS_ENTRIES:g}),n})),x.prototype=E,E.constructor=x),(w||P)&&(S("delete"),S("has"),g&&S("get")),(P||O)&&S(y),_&&E.clear&&delete E.clear}return T[t]=x,r({global:!0,forced:x!=b},T),v(x,t),_||n.setStrong(x,t,g),x}},9920:function(t,e,n){var r=n(2597),i=n(3887),o=n(1236),s=n(3070);t.exports=function(t,e,n){for(var a=i(e),u=s.f,l=o.f,c=0;c<a.length;c++){var h=a[c];r(t,h)||n&&r(n,h)||u(t,h,l(e,h))}}},4964:function(t,e,n){var r=n(5112),i=r("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[i]=!1,"/./"[t](e)}catch(r){}}return!1}},8544:function(t,e,n){var r=n(7293);t.exports=!r((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},4230:function(t,e,n){var r=n(1702),i=n(4488),o=n(1340),s=/"/g,a=r("".replace);t.exports=function(t,e,n,r){var u=o(i(t)),l="<"+e;return""!==n&&(l+=" "+n+'="'+a(o(r),s,""")+'"'),l+">"+u+"</"+e+">"}},4994:function(t,e,n){"use strict";var r=n(3383).IteratorPrototype,i=n(30),o=n(9114),s=n(8003),a=n(7497),u=function(){return this};t.exports=function(t,e,n,l){var c=e+" Iterator";return t.prototype=i(r,{next:o(+!l,n)}),s(t,c,!1,!0),a[c]=u,t}},8880:function(t,e,n){var r=n(9781),i=n(3070),o=n(9114);t.exports=r?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},9114:function(t){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},6135:function(t,e,n){"use strict";var r=n(4948),i=n(3070),o=n(9114);t.exports=function(t,e,n){var s=r(e);s in t?i.f(t,s,o(0,n)):t[s]=n}},654:function(t,e,n){"use strict";var r=n(2109),i=n(6916),o=n(1913),s=n(6530),a=n(614),u=n(4994),l=n(9518),c=n(7674),h=n(8003),f=n(8880),d=n(1320),p=n(5112),v=n(7497),m=n(3383),g=s.PROPER,_=s.CONFIGURABLE,y=m.IteratorPrototype,b=m.BUGGY_SAFARI_ITERATORS,E=p("iterator"),x="keys",T="values",S="entries",R=function(){return this};t.exports=function(t,e,n,s,p,m,A){u(n,e,s);var O,w,I,P=function(t){if(t===p&&L)return L;if(!b&&t in M)return M[t];switch(t){case x:return function(){return new n(this,t)};case T:return function(){return new n(this,t)};case S:return function(){return new n(this,t)}}return function(){return new n(this)}},C=e+" Iterator",N=!1,M=t.prototype,D=M[E]||M["@@iterator"]||p&&M[p],L=!b&&D||P(p),F="Array"==e&&M.entries||D;if(F&&(O=l(F.call(new t)),O!==Object.prototype&&O.next&&(o||l(O)===y||(c?c(O,y):a(O[E])||d(O,E,R)),h(O,C,!0,!0),o&&(v[C]=R))),g&&p==T&&D&&D.name!==T&&(!o&&_?f(M,"name",T):(N=!0,L=function(){return i(D,this)})),p)if(w={values:P(T),keys:m?L:P(x),entries:P(S)},A)for(I in w)(b||N||!(I in M))&&d(M,I,w[I]);else r({target:e,proto:!0,forced:b||N},w);return o&&!A||M[E]===L||d(M,E,L,{name:p}),v[e]=L,w}},7235:function(t,e,n){var r=n(857),i=n(2597),o=n(6061),s=n(3070).f;t.exports=function(t){var e=r.Symbol||(r.Symbol={});i(e,t)||s(e,t,{value:o.f(t)})}},9781:function(t,e,n){var r=n(7293);t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},317:function(t,e,n){var r=n(7854),i=n(111),o=r.document,s=i(o)&&i(o.createElement);t.exports=function(t){return s?o.createElement(t):{}}},3678:function(t){t.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}},8324:function(t){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},8509:function(t,e,n){var r=n(317),i=r("span").classList,o=i&&i.constructor&&i.constructor.prototype;t.exports=o===Object.prototype?void 0:o},7871:function(t){t.exports="object"==typeof window},1528:function(t,e,n){var r=n(8113),i=n(7854);t.exports=/ipad|iphone|ipod/i.test(r)&&void 0!==i.Pebble},6833:function(t,e,n){var r=n(8113);t.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(r)},5268:function(t,e,n){var r=n(4326),i=n(7854);t.exports="process"==r(i.process)},1036:function(t,e,n){var r=n(8113);t.exports=/web0s(?!.*chrome)/i.test(r)},8113:function(t,e,n){var r=n(5005);t.exports=r("navigator","userAgent")||""},7392:function(t,e,n){var r,i,o=n(7854),s=n(8113),a=o.process,u=o.Deno,l=a&&a.versions||u&&u.version,c=l&&l.v8;c&&(r=c.split("."),i=r[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&s&&(r=s.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/),r&&(i=+r[1]))),t.exports=i},748:function(t){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},2914:function(t,e,n){var r=n(7293),i=n(9114);t.exports=!r((function(){var t=Error("a");return!("stack"in t)||(Object.defineProperty(t,"stack",i(1,7)),7!==t.stack)}))},7762:function(t,e,n){"use strict";var r=n(9781),i=n(7293),o=n(9670),s=n(30),a=n(6277),u=Error.prototype.toString,l=i((function(){if(r){var t=s(Object.defineProperty({},"name",{get:function(){return this===t}}));if("true"!==u.call(t))return!0}return"2: 1"!==u.call({message:1,name:2})||"Error"!==u.call({})}));t.exports=l?function(){var t=o(this),e=a(t.name,"Error"),n=a(t.message);return e?n?e+": "+n:e:n}:u},2109:function(t,e,n){var r=n(7854),i=n(1236).f,o=n(8880),s=n(1320),a=n(3505),u=n(9920),l=n(4705);t.exports=function(t,e){var n,c,h,f,d,p,v=t.target,m=t.global,g=t.stat;if(c=m?r:g?r[v]||a(v,{}):(r[v]||{}).prototype,c)for(h in e){if(d=e[h],t.noTargetGet?(p=i(c,h),f=p&&p.value):f=c[h],n=l(m?h:v+(g?".":"#")+h,t.forced),!n&&void 0!==f){if(typeof d==typeof f)continue;u(d,f)}(t.sham||f&&f.sham)&&o(d,"sham",!0),s(c,h,d,t)}}},7293:function(t){t.exports=function(t){try{return!!t()}catch(e){return!0}}},7007:function(t,e,n){"use strict";n(4916);var r=n(1702),i=n(1320),o=n(2261),s=n(7293),a=n(5112),u=n(8880),l=a("species"),c=RegExp.prototype;t.exports=function(t,e,n,h){var f=a(t),d=!s((function(){var e={};return e[f]=function(){return 7},7!=""[t](e)})),p=d&&!s((function(){var e=!1,n=/a/;return"split"===t&&(n={},n.constructor={},n.constructor[l]=function(){return n},n.flags="",n[f]=/./[f]),n.exec=function(){return e=!0,null},n[f](""),!e}));if(!d||!p||n){var v=r(/./[f]),m=e(f,""[t],(function(t,e,n,i,s){var a=r(t),u=e.exec;return u===o||u===c.exec?d&&!s?{done:!0,value:v(e,n,i)}:{done:!0,value:a(n,e,i)}:{done:!1}}));i(String.prototype,t,m[0]),i(c,f,m[1])}h&&u(c[f],"sham",!0)}},6677:function(t,e,n){var r=n(7293);t.exports=!r((function(){return Object.isExtensible(Object.preventExtensions({}))}))},2104:function(t){var e=Function.prototype,n=e.apply,r=e.bind,i=e.call;t.exports="object"==typeof Reflect&&Reflect.apply||(r?i.bind(n):function(){return i.apply(n,arguments)})},9974:function(t,e,n){var r=n(1702),i=n(9662),o=r(r.bind);t.exports=function(t,e){return i(t),void 0===e?t:o?o(t,e):function(){return t.apply(e,arguments)}}},6916:function(t){var e=Function.prototype.call;t.exports=e.bind?e.bind(e):function(){return e.apply(e,arguments)}},6530:function(t,e,n){var r=n(9781),i=n(2597),o=Function.prototype,s=r&&Object.getOwnPropertyDescriptor,a=i(o,"name"),u=a&&"something"===function(){}.name,l=a&&(!r||r&&s(o,"name").configurable);t.exports={EXISTS:a,PROPER:u,CONFIGURABLE:l}},1702:function(t){var e=Function.prototype,n=e.bind,r=e.call,i=n&&n.bind(r,r);t.exports=n?function(t){return t&&i(t)}:function(t){return t&&function(){return r.apply(t,arguments)}}},5005:function(t,e,n){var r=n(7854),i=n(614),o=function(t){return i(t)?t:void 0};t.exports=function(t,e){return arguments.length<2?o(r[t]):r[t]&&r[t][e]}},1246:function(t,e,n){var r=n(648),i=n(8173),o=n(7497),s=n(5112),a=s("iterator");t.exports=function(t){if(void 0!=t)return i(t,a)||i(t,"@@iterator")||o[r(t)]}},8554:function(t,e,n){var r=n(7854),i=n(6916),o=n(9662),s=n(9670),a=n(6330),u=n(1246),l=r.TypeError;t.exports=function(t,e){var n=arguments.length<2?u(t):e;if(o(n))return s(i(n,t));throw l(a(t)+" is not iterable")}},8173:function(t,e,n){var r=n(9662);t.exports=function(t,e){var n=t[e];return null==n?void 0:r(n)}},647:function(t,e,n){var r=n(1702),i=n(7908),o=Math.floor,s=r("".charAt),a=r("".replace),u=r("".slice),l=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,c=/\$([$&'`]|\d{1,2})/g;t.exports=function(t,e,n,r,h,f){var d=n+t.length,p=r.length,v=c;return void 0!==h&&(h=i(h),v=l),a(f,v,(function(i,a){var l;switch(s(a,0)){case"$":return"$";case"&":return t;case"`":return u(e,0,n);case"'":return u(e,d);case"<":l=h[u(a,1,-1)];break;default:var c=+a;if(0===c)return i;if(c>p){var f=o(c/10);return 0===f?i:f<=p?void 0===r[f-1]?s(a,1):r[f-1]+s(a,1):i}l=r[c-1]}return void 0===l?"":l}))}},7854:function(t,e,n){var r=function(t){return t&&t.Math==Math&&t};t.exports=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof n.g&&n.g)||function(){return this}()||Function("return this")()},2597:function(t,e,n){var r=n(1702),i=n(7908),o=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(t,e){return o(i(t),e)}},3501:function(t){t.exports={}},842:function(t,e,n){var r=n(7854);t.exports=function(t,e){var n=r.console;n&&n.error&&(1==arguments.length?n.error(t):n.error(t,e))}},490:function(t,e,n){var r=n(5005);t.exports=r("document","documentElement")},4664:function(t,e,n){var r=n(9781),i=n(7293),o=n(317);t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},8361:function(t,e,n){var r=n(7854),i=n(1702),o=n(7293),s=n(4326),a=r.Object,u=i("".split);t.exports=o((function(){return!a("z").propertyIsEnumerable(0)}))?function(t){return"String"==s(t)?u(t,""):a(t)}:a},9587:function(t,e,n){var r=n(614),i=n(111),o=n(7674);t.exports=function(t,e,n){var s,a;return o&&r(s=e.constructor)&&s!==n&&i(a=s.prototype)&&a!==n.prototype&&o(t,a),t}},2788:function(t,e,n){var r=n(1702),i=n(614),o=n(5465),s=r(Function.toString);i(o.inspectSource)||(o.inspectSource=function(t){return s(t)}),t.exports=o.inspectSource},8340:function(t,e,n){var r=n(111),i=n(8880);t.exports=function(t,e){r(e)&&"cause"in e&&i(t,"cause",e.cause)}},2423:function(t,e,n){var r=n(2109),i=n(1702),o=n(3501),s=n(111),a=n(2597),u=n(3070).f,l=n(8006),c=n(1156),h=n(2050),f=n(9711),d=n(6677),p=!1,v=f("meta"),m=0,g=function(t){u(t,v,{value:{objectID:"O"+m++,weakData:{}}})},_=function(t,e){if(!s(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!a(t,v)){if(!h(t))return"F";if(!e)return"E";g(t)}return t[v].objectID},y=function(t,e){if(!a(t,v)){if(!h(t))return!0;if(!e)return!1;g(t)}return t[v].weakData},b=function(t){return d&&p&&h(t)&&!a(t,v)&&g(t),t},E=function(){x.enable=function(){},p=!0;var t=l.f,e=i([].splice),n={};n[v]=1,t(n).length&&(l.f=function(n){for(var r=t(n),i=0,o=r.length;i<o;i++)if(r[i]===v){e(r,i,1);break}return r},r({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:c.f}))},x=t.exports={enable:E,fastKey:_,getWeakData:y,onFreeze:b};o[v]=!0},9909:function(t,e,n){var r,i,o,s=n(8536),a=n(7854),u=n(1702),l=n(111),c=n(8880),h=n(2597),f=n(5465),d=n(6200),p=n(3501),v="Object already initialized",m=a.TypeError,g=a.WeakMap,_=function(t){return o(t)?i(t):r(t,{})},y=function(t){return function(e){var n;if(!l(e)||(n=i(e)).type!==t)throw m("Incompatible receiver, "+t+" required");return n}};if(s||f.state){var b=f.state||(f.state=new g),E=u(b.get),x=u(b.has),T=u(b.set);r=function(t,e){if(x(b,t))throw new m(v);return e.facade=t,T(b,t,e),e},i=function(t){return E(b,t)||{}},o=function(t){return x(b,t)}}else{var S=d("state");p[S]=!0,r=function(t,e){if(h(t,S))throw new m(v);return e.facade=t,c(t,S,e),e},i=function(t){return h(t,S)?t[S]:{}},o=function(t){return h(t,S)}}t.exports={set:r,get:i,has:o,enforce:_,getterFor:y}},7659:function(t,e,n){var r=n(5112),i=n(7497),o=r("iterator"),s=Array.prototype;t.exports=function(t){return void 0!==t&&(i.Array===t||s[o]===t)}},3157:function(t,e,n){var r=n(4326);t.exports=Array.isArray||function(t){return"Array"==r(t)}},614:function(t){t.exports=function(t){return"function"==typeof t}},4411:function(t,e,n){var r=n(1702),i=n(7293),o=n(614),s=n(648),a=n(5005),u=n(2788),l=function(){},c=[],h=a("Reflect","construct"),f=/^\s*(?:class|function)\b/,d=r(f.exec),p=!f.exec(l),v=function(t){if(!o(t))return!1;try{return h(l,c,t),!0}catch(e){return!1}},m=function(t){if(!o(t))return!1;switch(s(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return p||!!d(f,u(t))}catch(e){return!0}};m.sham=!0,t.exports=!h||i((function(){var t;return v(v.call)||!v(Object)||!v((function(){t=!0}))||t}))?m:v},4705:function(t,e,n){var r=n(7293),i=n(614),o=/#|\.prototype\./,s=function(t,e){var n=u[a(t)];return n==c||n!=l&&(i(e)?r(e):!!e)},a=s.normalize=function(t){return String(t).replace(o,".").toLowerCase()},u=s.data={},l=s.NATIVE="N",c=s.POLYFILL="P";t.exports=s},111:function(t,e,n){var r=n(614);t.exports=function(t){return"object"==typeof t?null!==t:r(t)}},1913:function(t){t.exports=!1},7850:function(t,e,n){var r=n(111),i=n(4326),o=n(5112),s=o("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[s])?!!e:"RegExp"==i(t))}},2190:function(t,e,n){var r=n(7854),i=n(5005),o=n(614),s=n(7976),a=n(3307),u=r.Object;t.exports=a?function(t){return"symbol"==typeof t}:function(t){var e=i("Symbol");return o(e)&&s(e.prototype,u(t))}},408:function(t,e,n){var r=n(7854),i=n(9974),o=n(6916),s=n(9670),a=n(6330),u=n(7659),l=n(6244),c=n(7976),h=n(8554),f=n(1246),d=n(9212),p=r.TypeError,v=function(t,e){this.stopped=t,this.result=e},m=v.prototype;t.exports=function(t,e,n){var r,g,_,y,b,E,x,T=n&&n.that,S=!(!n||!n.AS_ENTRIES),R=!(!n||!n.IS_ITERATOR),A=!(!n||!n.INTERRUPTED),O=i(e,T),w=function(t){return r&&d(r,"normal",t),new v(!0,t)},I=function(t){return S?(s(t),A?O(t[0],t[1],w):O(t[0],t[1])):A?O(t,w):O(t)};if(R)r=t;else{if(g=f(t),!g)throw p(a(t)+" is not iterable");if(u(g)){for(_=0,y=l(t);y>_;_++)if(b=I(t[_]),b&&c(m,b))return b;return new v(!1)}r=h(t,g)}E=r.next;while(!(x=o(E,r)).done){try{b=I(x.value)}catch(P){d(r,"throw",P)}if("object"==typeof b&&b&&c(m,b))return b}return new v(!1)}},9212:function(t,e,n){var r=n(6916),i=n(9670),o=n(8173);t.exports=function(t,e,n){var s,a;i(t);try{if(s=o(t,"return"),!s){if("throw"===e)throw n;return n}s=r(s,t)}catch(u){a=!0,s=u}if("throw"===e)throw n;if(a)throw s;return i(s),n}},3383:function(t,e,n){"use strict";var r,i,o,s=n(7293),a=n(614),u=n(30),l=n(9518),c=n(1320),h=n(5112),f=n(1913),d=h("iterator"),p=!1;[].keys&&(o=[].keys(),"next"in o?(i=l(l(o)),i!==Object.prototype&&(r=i)):p=!0);var v=void 0==r||s((function(){var t={};return r[d].call(t)!==t}));v?r={}:f&&(r=u(r)),a(r[d])||c(r,d,(function(){return this})),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:p}},7497:function(t){t.exports={}},6244:function(t,e,n){var r=n(7466);t.exports=function(t){return r(t.length)}},403:function(t){var e=Math.log,n=Math.LOG10E;t.exports=Math.log10||function(t){return e(t)*n}},4310:function(t){t.exports=Math.sign||function(t){return 0==(t=+t)||t!=t?t:t<0?-1:1}},5948:function(t,e,n){var r,i,o,s,a,u,l,c,h=n(7854),f=n(9974),d=n(1236).f,p=n(261).set,v=n(6833),m=n(1528),g=n(1036),_=n(5268),y=h.MutationObserver||h.WebKitMutationObserver,b=h.document,E=h.process,x=h.Promise,T=d(h,"queueMicrotask"),S=T&&T.value;S||(r=function(){var t,e;_&&(t=E.domain)&&t.exit();while(i){e=i.fn,i=i.next;try{e()}catch(n){throw i?s():o=void 0,n}}o=void 0,t&&t.enter()},v||_||g||!y||!b?!m&&x&&x.resolve?(l=x.resolve(void 0),l.constructor=x,c=f(l.then,l),s=function(){c(r)}):_?s=function(){E.nextTick(r)}:(p=f(p,h),s=function(){p(r)}):(a=!0,u=b.createTextNode(""),new y(r).observe(u,{characterData:!0}),s=function(){u.data=a=!a})),t.exports=S||function(t){var e={fn:t,next:void 0};o&&(o.next=e),i||(i=e,s()),o=e}},3366:function(t,e,n){var r=n(7854);t.exports=r.Promise},133:function(t,e,n){var r=n(7392),i=n(7293);t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},8536:function(t,e,n){var r=n(7854),i=n(614),o=n(2788),s=r.WeakMap;t.exports=i(s)&&/native code/.test(o(s))},8523:function(t,e,n){"use strict";var r=n(9662),i=function(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw TypeError("Bad Promise constructor");e=t,n=r})),this.resolve=r(e),this.reject=r(n)};t.exports.f=function(t){return new i(t)}},6277:function(t,e,n){var r=n(1340);t.exports=function(t,e){return void 0===t?arguments.length<2?"":e:r(t)}},3929:function(t,e,n){var r=n(7854),i=n(7850),o=r.TypeError;t.exports=function(t){if(i(t))throw o("The method doesn't accept regular expressions");return t}},7023:function(t,e,n){var r=n(7854),i=r.isFinite;t.exports=Number.isFinite||function(t){return"number"==typeof t&&i(t)}},1574:function(t,e,n){"use strict";var r=n(9781),i=n(1702),o=n(6916),s=n(7293),a=n(1956),u=n(5181),l=n(5296),c=n(7908),h=n(8361),f=Object.assign,d=Object.defineProperty,p=i([].concat);t.exports=!f||s((function(){if(r&&1!==f({b:1},f(d({},"a",{enumerable:!0,get:function(){d(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var t={},e={},n=Symbol(),i="abcdefghijklmnopqrst";return t[n]=7,i.split("").forEach((function(t){e[t]=t})),7!=f({},t)[n]||a(f({},e)).join("")!=i}))?function(t,e){var n=c(t),i=arguments.length,s=1,f=u.f,d=l.f;while(i>s){var v,m=h(arguments[s++]),g=f?p(a(m),f(m)):a(m),_=g.length,y=0;while(_>y)v=g[y++],r&&!o(d,m,v)||(n[v]=m[v])}return n}:f},30:function(t,e,n){var r,i=n(9670),o=n(6048),s=n(748),a=n(3501),u=n(490),l=n(317),c=n(6200),h=">",f="<",d="prototype",p="script",v=c("IE_PROTO"),m=function(){},g=function(t){return f+p+h+t+f+"/"+p+h},_=function(t){t.write(g("")),t.close();var e=t.parentWindow.Object;return t=null,e},y=function(){var t,e=l("iframe"),n="java"+p+":";return e.style.display="none",u.appendChild(e),e.src=String(n),t=e.contentWindow.document,t.open(),t.write(g("document.F=Object")),t.close(),t.F},b=function(){try{r=new ActiveXObject("htmlfile")}catch(e){}b="undefined"!=typeof document?document.domain&&r?_(r):y():_(r);var t=s.length;while(t--)delete b[d][s[t]];return b()};a[v]=!0,t.exports=Object.create||function(t,e){var n;return null!==t?(m[d]=i(t),n=new m,m[d]=null,n[v]=t):n=b(),void 0===e?n:o.f(n,e)}},6048:function(t,e,n){var r=n(9781),i=n(3353),o=n(3070),s=n(9670),a=n(5656),u=n(1956);e.f=r&&!i?Object.defineProperties:function(t,e){s(t);var n,r=a(e),i=u(e),l=i.length,c=0;while(l>c)o.f(t,n=i[c++],r[n]);return t}},3070:function(t,e,n){var r=n(7854),i=n(9781),o=n(4664),s=n(3353),a=n(9670),u=n(4948),l=r.TypeError,c=Object.defineProperty,h=Object.getOwnPropertyDescriptor,f="enumerable",d="configurable",p="writable";e.f=i?s?function(t,e,n){if(a(t),e=u(e),a(n),"function"===typeof t&&"prototype"===e&&"value"in n&&p in n&&!n[p]){var r=h(t,e);r&&r[p]&&(t[e]=n.value,n={configurable:d in n?n[d]:r[d],enumerable:f in n?n[f]:r[f],writable:!1})}return c(t,e,n)}:c:function(t,e,n){if(a(t),e=u(e),a(n),o)try{return c(t,e,n)}catch(r){}if("get"in n||"set"in n)throw l("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},1236:function(t,e,n){var r=n(9781),i=n(6916),o=n(5296),s=n(9114),a=n(5656),u=n(4948),l=n(2597),c=n(4664),h=Object.getOwnPropertyDescriptor;e.f=r?h:function(t,e){if(t=a(t),e=u(e),c)try{return h(t,e)}catch(n){}if(l(t,e))return s(!i(o.f,t,e),t[e])}},1156:function(t,e,n){var r=n(4326),i=n(5656),o=n(8006).f,s=n(1589),a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],u=function(t){try{return o(t)}catch(e){return s(a)}};t.exports.f=function(t){return a&&"Window"==r(t)?u(t):o(i(t))}},8006:function(t,e,n){var r=n(6324),i=n(748),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},5181:function(t,e){e.f=Object.getOwnPropertySymbols},9518:function(t,e,n){var r=n(7854),i=n(2597),o=n(614),s=n(7908),a=n(6200),u=n(8544),l=a("IE_PROTO"),c=r.Object,h=c.prototype;t.exports=u?c.getPrototypeOf:function(t){var e=s(t);if(i(e,l))return e[l];var n=e.constructor;return o(n)&&e instanceof n?n.prototype:e instanceof c?h:null}},2050:function(t,e,n){var r=n(7293),i=n(111),o=n(4326),s=n(2446),a=Object.isExtensible,u=r((function(){a(1)}));t.exports=u||s?function(t){return!!i(t)&&((!s||"ArrayBuffer"!=o(t))&&(!a||a(t)))}:a},7976:function(t,e,n){var r=n(1702);t.exports=r({}.isPrototypeOf)},6324:function(t,e,n){var r=n(1702),i=n(2597),o=n(5656),s=n(1318).indexOf,a=n(3501),u=r([].push);t.exports=function(t,e){var n,r=o(t),l=0,c=[];for(n in r)!i(a,n)&&i(r,n)&&u(c,n);while(e.length>l)i(r,n=e[l++])&&(~s(c,n)||u(c,n));return c}},1956:function(t,e,n){var r=n(6324),i=n(748);t.exports=Object.keys||function(t){return r(t,i)}},5296:function(t,e){"use strict";var n={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,i=r&&!n.call({1:2},1);e.f=i?function(t){var e=r(this,t);return!!e&&e.enumerable}:n},7674:function(t,e,n){var r=n(1702),i=n(9670),o=n(6077);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{t=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set),t(n,[]),e=n instanceof Array}catch(s){}return function(n,r){return i(n),o(r),e?t(n,r):n.__proto__=r,n}}():void 0)},4699:function(t,e,n){var r=n(9781),i=n(1702),o=n(1956),s=n(5656),a=n(5296).f,u=i(a),l=i([].push),c=function(t){return function(e){var n,i=s(e),a=o(i),c=a.length,h=0,f=[];while(c>h)n=a[h++],r&&!u(i,n)||l(f,t?[n,i[n]]:i[n]);return f}};t.exports={entries:c(!0),values:c(!1)}},288:function(t,e,n){"use strict";var r=n(1694),i=n(648);t.exports=r?{}.toString:function(){return"[object "+i(this)+"]"}},2140:function(t,e,n){var r=n(7854),i=n(6916),o=n(614),s=n(111),a=r.TypeError;t.exports=function(t,e){var n,r;if("string"===e&&o(n=t.toString)&&!s(r=i(n,t)))return r;if(o(n=t.valueOf)&&!s(r=i(n,t)))return r;if("string"!==e&&o(n=t.toString)&&!s(r=i(n,t)))return r;throw a("Can't convert object to primitive value")}},3887:function(t,e,n){var r=n(5005),i=n(1702),o=n(8006),s=n(5181),a=n(9670),u=i([].concat);t.exports=r("Reflect","ownKeys")||function(t){var e=o.f(a(t)),n=s.f;return n?u(e,n(t)):e}},857:function(t,e,n){var r=n(7854);t.exports=r},2534:function(t){t.exports=function(t){try{return{error:!1,value:t()}}catch(e){return{error:!0,value:e}}}},9478:function(t,e,n){var r=n(9670),i=n(111),o=n(8523);t.exports=function(t,e){if(r(t),i(e)&&e.constructor===t)return e;var n=o.f(t),s=n.resolve;return s(e),n.promise}},8572:function(t){var e=function(){this.head=null,this.tail=null};e.prototype={add:function(t){var e={item:t,next:null};this.head?this.tail.next=e:this.head=e,this.tail=e},get:function(){var t=this.head;if(t)return this.head=t.next,this.tail===t&&(this.tail=null),t.item}},t.exports=e},2248:function(t,e,n){var r=n(1320);t.exports=function(t,e,n){for(var i in e)r(t,i,e[i],n);return t}},1320:function(t,e,n){var r=n(7854),i=n(614),o=n(2597),s=n(8880),a=n(3505),u=n(2788),l=n(9909),c=n(6530).CONFIGURABLE,h=l.get,f=l.enforce,d=String(String).split("String");(t.exports=function(t,e,n,u){var l,h=!!u&&!!u.unsafe,p=!!u&&!!u.enumerable,v=!!u&&!!u.noTargetGet,m=u&&void 0!==u.name?u.name:e;i(n)&&("Symbol("===String(m).slice(0,7)&&(m="["+String(m).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!o(n,"name")||c&&n.name!==m)&&s(n,"name",m),l=f(n),l.source||(l.source=d.join("string"==typeof m?m:""))),t!==r?(h?!v&&t[e]&&(p=!0):delete t[e],p?t[e]=n:s(t,e,n)):p?t[e]=n:a(e,n)})(Function.prototype,"toString",(function(){return i(this)&&h(this).source||u(this)}))},7651:function(t,e,n){var r=n(7854),i=n(6916),o=n(9670),s=n(614),a=n(4326),u=n(2261),l=r.TypeError;t.exports=function(t,e){var n=t.exec;if(s(n)){var r=i(n,t,e);return null!==r&&o(r),r}if("RegExp"===a(t))return i(u,t,e);throw l("RegExp#exec called on incompatible receiver")}},2261:function(t,e,n){"use strict";var r=n(6916),i=n(1702),o=n(1340),s=n(7066),a=n(2999),u=n(2309),l=n(30),c=n(9909).get,h=n(9441),f=n(7168),d=u("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,v=p,m=i("".charAt),g=i("".indexOf),_=i("".replace),y=i("".slice),b=function(){var t=/a/,e=/b*/g;return r(p,t,"a"),r(p,e,"a"),0!==t.lastIndex||0!==e.lastIndex}(),E=a.BROKEN_CARET,x=void 0!==/()??/.exec("")[1],T=b||x||E||h||f;T&&(v=function(t){var e,n,i,a,u,h,f,T=this,S=c(T),R=o(t),A=S.raw;if(A)return A.lastIndex=T.lastIndex,e=r(v,A,R),T.lastIndex=A.lastIndex,e;var O=S.groups,w=E&&T.sticky,I=r(s,T),P=T.source,C=0,N=R;if(w&&(I=_(I,"y",""),-1===g(I,"g")&&(I+="g"),N=y(R,T.lastIndex),T.lastIndex>0&&(!T.multiline||T.multiline&&"\n"!==m(R,T.lastIndex-1))&&(P="(?: "+P+")",N=" "+N,C++),n=new RegExp("^(?:"+P+")",I)),x&&(n=new RegExp("^"+P+"$(?!\\s)",I)),b&&(i=T.lastIndex),a=r(p,w?n:T,N),w?a?(a.input=y(a.input,C),a[0]=y(a[0],C),a.index=T.lastIndex,T.lastIndex+=a[0].length):T.lastIndex=0:b&&a&&(T.lastIndex=T.global?a.index+a[0].length:i),x&&a&&a.length>1&&r(d,a[0],n,(function(){for(u=1;u<arguments.length-2;u++)void 0===arguments[u]&&(a[u]=void 0)})),a&&O)for(a.groups=h=l(null),u=0;u<O.length;u++)f=O[u],h[f[0]]=a[f[1]];return a}),t.exports=v},7066:function(t,e,n){"use strict";var r=n(9670);t.exports=function(){var t=r(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},2999:function(t,e,n){var r=n(7293),i=n(7854),o=i.RegExp,s=r((function(){var t=o("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),a=s||r((function(){return!o("a","y").sticky})),u=s||r((function(){var t=o("^r","gy");return t.lastIndex=2,null!=t.exec("str")}));t.exports={BROKEN_CARET:u,MISSED_STICKY:a,UNSUPPORTED_Y:s}},9441:function(t,e,n){var r=n(7293),i=n(7854),o=i.RegExp;t.exports=r((function(){var t=o(".","s");return!(t.dotAll&&t.exec("\n")&&"s"===t.flags)}))},7168:function(t,e,n){var r=n(7293),i=n(7854),o=i.RegExp;t.exports=r((function(){var t=o("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")}))},4488:function(t,e,n){var r=n(7854),i=r.TypeError;t.exports=function(t){if(void 0==t)throw i("Can't call method on "+t);return t}},3505:function(t,e,n){var r=n(7854),i=Object.defineProperty;t.exports=function(t,e){try{i(r,t,{value:e,configurable:!0,writable:!0})}catch(n){r[t]=e}return e}},6340:function(t,e,n){"use strict";var r=n(5005),i=n(3070),o=n(5112),s=n(9781),a=o("species");t.exports=function(t){var e=r(t),n=i.f;s&&e&&!e[a]&&n(e,a,{configurable:!0,get:function(){return this}})}},8003:function(t,e,n){var r=n(3070).f,i=n(2597),o=n(5112),s=o("toStringTag");t.exports=function(t,e,n){t&&!n&&(t=t.prototype),t&&!i(t,s)&&r(t,s,{configurable:!0,value:e})}},6200:function(t,e,n){var r=n(2309),i=n(9711),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},5465:function(t,e,n){var r=n(7854),i=n(3505),o="__core-js_shared__",s=r[o]||i(o,{});t.exports=s},2309:function(t,e,n){var r=n(1913),i=n(5465);(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.20.2",mode:r?"pure":"global",copyright:"© 2022 Denis Pushkarev (zloirock.ru)"})},6707:function(t,e,n){var r=n(9670),i=n(9483),o=n(5112),s=o("species");t.exports=function(t,e){var n,o=r(t).constructor;return void 0===o||void 0==(n=r(o)[s])?e:i(n)}},3429:function(t,e,n){var r=n(7293);t.exports=function(t){return r((function(){var e=""[t]('"');return e!==e.toLowerCase()||e.split('"').length>3}))}},8710:function(t,e,n){var r=n(1702),i=n(9303),o=n(1340),s=n(4488),a=r("".charAt),u=r("".charCodeAt),l=r("".slice),c=function(t){return function(e,n){var r,c,h=o(s(e)),f=i(n),d=h.length;return f<0||f>=d?t?"":void 0:(r=u(h,f),r<55296||r>56319||f+1===d||(c=u(h,f+1))<56320||c>57343?t?a(h,f):r:t?l(h,f,f+2):c-56320+(r-55296<<10)+65536)}};t.exports={codeAt:c(!1),charAt:c(!0)}},8415:function(t,e,n){"use strict";var r=n(7854),i=n(9303),o=n(1340),s=n(4488),a=r.RangeError;t.exports=function(t){var e=o(s(this)),n="",r=i(t);if(r<0||r==1/0)throw a("Wrong number of repetitions");for(;r>0;(r>>>=1)&&(e+=e))1&r&&(n+=e);return n}},6091:function(t,e,n){var r=n(6530).PROPER,i=n(7293),o=n(1361),s="​…᠎";t.exports=function(t){return i((function(){return!!o[t]()||s[t]()!==s||r&&o[t].name!==t}))}},3111:function(t,e,n){var r=n(1702),i=n(4488),o=n(1340),s=n(1361),a=r("".replace),u="["+s+"]",l=RegExp("^"+u+u+"*"),c=RegExp(u+u+"*$"),h=function(t){return function(e){var n=o(i(e));return 1&t&&(n=a(n,l,"")),2&t&&(n=a(n,c,"")),n}};t.exports={start:h(1),end:h(2),trim:h(3)}},261:function(t,e,n){var r,i,o,s,a=n(7854),u=n(2104),l=n(9974),c=n(614),h=n(2597),f=n(7293),d=n(490),p=n(206),v=n(317),m=n(6833),g=n(5268),_=a.setImmediate,y=a.clearImmediate,b=a.process,E=a.Dispatch,x=a.Function,T=a.MessageChannel,S=a.String,R=0,A={},O="onreadystatechange";try{r=a.location}catch(N){}var w=function(t){if(h(A,t)){var e=A[t];delete A[t],e()}},I=function(t){return function(){w(t)}},P=function(t){w(t.data)},C=function(t){a.postMessage(S(t),r.protocol+"//"+r.host)};_&&y||(_=function(t){var e=p(arguments,1);return A[++R]=function(){u(c(t)?t:x(t),void 0,e)},i(R),R},y=function(t){delete A[t]},g?i=function(t){b.nextTick(I(t))}:E&&E.now?i=function(t){E.now(I(t))}:T&&!m?(o=new T,s=o.port2,o.port1.onmessage=P,i=l(s.postMessage,s)):a.addEventListener&&c(a.postMessage)&&!a.importScripts&&r&&"file:"!==r.protocol&&!f(C)?(i=C,a.addEventListener("message",P,!1)):i=O in v("script")?function(t){d.appendChild(v("script"))[O]=function(){d.removeChild(this),w(t)}}:function(t){setTimeout(I(t),0)}),t.exports={set:_,clear:y}},863:function(t,e,n){var r=n(1702);t.exports=r(1..valueOf)},1400:function(t,e,n){var r=n(9303),i=Math.max,o=Math.min;t.exports=function(t,e){var n=r(t);return n<0?i(n+e,0):o(n,e)}},5656:function(t,e,n){var r=n(8361),i=n(4488);t.exports=function(t){return r(i(t))}},9303:function(t){var e=Math.ceil,n=Math.floor;t.exports=function(t){var r=+t;return r!==r||0===r?0:(r>0?n:e)(r)}},7466:function(t,e,n){var r=n(9303),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},7908:function(t,e,n){var r=n(7854),i=n(4488),o=r.Object;t.exports=function(t){return o(i(t))}},7593:function(t,e,n){var r=n(7854),i=n(6916),o=n(111),s=n(2190),a=n(8173),u=n(2140),l=n(5112),c=r.TypeError,h=l("toPrimitive");t.exports=function(t,e){if(!o(t)||s(t))return t;var n,r=a(t,h);if(r){if(void 0===e&&(e="default"),n=i(r,t,e),!o(n)||s(n))return n;throw c("Can't convert object to primitive value")}return void 0===e&&(e="number"),u(t,e)}},4948:function(t,e,n){var r=n(7593),i=n(2190);t.exports=function(t){var e=r(t,"string");return i(e)?e:e+""}},1694:function(t,e,n){var r=n(5112),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},1340:function(t,e,n){var r=n(7854),i=n(648),o=r.String;t.exports=function(t){if("Symbol"===i(t))throw TypeError("Cannot convert a Symbol value to a string");return o(t)}},4038:function(t,e,n){var r=n(5268);t.exports=function(t){try{if(r)return Function('return require("'+t+'")')()}catch(e){}}},6330:function(t,e,n){var r=n(7854),i=r.String;t.exports=function(t){try{return i(t)}catch(e){return"Object"}}},9711:function(t,e,n){var r=n(1702),i=0,o=Math.random(),s=r(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+s(++i+o,36)}},3307:function(t,e,n){var r=n(133);t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},3353:function(t,e,n){var r=n(9781),i=n(7293);t.exports=r&&i((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},6061:function(t,e,n){var r=n(5112);e.f=r},5112:function(t,e,n){var r=n(7854),i=n(2309),o=n(2597),s=n(9711),a=n(133),u=n(3307),l=i("wks"),c=r.Symbol,h=c&&c["for"],f=u?c:c&&c.withoutSetter||s;t.exports=function(t){if(!o(l,t)||!a&&"string"!=typeof l[t]){var e="Symbol."+t;a&&o(c,t)?l[t]=c[t]:l[t]=u&&h?h(e):f(e)}return l[t]}},1361:function(t){t.exports="\t\n\v\f\r                 \u2028\u2029\ufeff"},9191:function(t,e,n){"use strict";var r=n(5005),i=n(2597),o=n(8880),s=n(7976),a=n(7674),u=n(9920),l=n(9587),c=n(6277),h=n(8340),f=n(7741),d=n(2914),p=n(1913);t.exports=function(t,e,n,v){var m=v?2:1,g=t.split("."),_=g[g.length-1],y=r.apply(null,g);if(y){var b=y.prototype;if(!p&&i(b,"cause")&&delete b.cause,!n)return y;var E=r("Error"),x=e((function(t,e){var n=c(v?e:t,void 0),r=v?new y(t):new y;return void 0!==n&&o(r,"message",n),d&&o(r,"stack",f(r.stack,2)),this&&s(b,this)&&l(r,this,x),arguments.length>m&&h(r,arguments[m]),r}));if(x.prototype=b,"Error"!==_&&(a?a(x,E):u(x,E,{name:!0})),u(x,y),!p)try{b.name!==_&&o(b,"name",_),b.constructor=x}catch(T){}return x}}},2222:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(7293),s=n(3157),a=n(111),u=n(7908),l=n(6244),c=n(6135),h=n(5417),f=n(1194),d=n(5112),p=n(7392),v=d("isConcatSpreadable"),m=9007199254740991,g="Maximum allowed index exceeded",_=i.TypeError,y=p>=51||!o((function(){var t=[];return t[v]=!1,t.concat()[0]!==t})),b=f("concat"),E=function(t){if(!a(t))return!1;var e=t[v];return void 0!==e?!!e:s(t)},x=!y||!b;r({target:"Array",proto:!0,forced:x},{concat:function(t){var e,n,r,i,o,s=u(this),a=h(s,0),f=0;for(e=-1,r=arguments.length;e<r;e++)if(o=-1===e?s:arguments[e],E(o)){if(i=l(o),f+i>m)throw _(g);for(n=0;n<i;n++,f++)n in o&&c(a,f,o[n])}else{if(f>=m)throw _(g);c(a,f++,o)}return a.length=f,a}})},7327:function(t,e,n){"use strict";var r=n(2109),i=n(2092).filter,o=n(1194),s=o("filter");r({target:"Array",proto:!0,forced:!s},{filter:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},4553:function(t,e,n){"use strict";var r=n(2109),i=n(2092).findIndex,o=n(1223),s="findIndex",a=!0;s in[]&&Array(1)[s]((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{findIndex:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o(s)},9826:function(t,e,n){"use strict";var r=n(2109),i=n(2092).find,o=n(1223),s="find",a=!0;s in[]&&Array(1)[s]((function(){a=!1})),r({target:"Array",proto:!0,forced:a},{find:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o(s)},1038:function(t,e,n){var r=n(2109),i=n(8457),o=n(7072),s=!o((function(t){Array.from(t)}));r({target:"Array",stat:!0,forced:s},{from:i})},6699:function(t,e,n){"use strict";var r=n(2109),i=n(1318).includes,o=n(1223);r({target:"Array",proto:!0},{includes:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o("includes")},6992:function(t,e,n){"use strict";var r=n(5656),i=n(1223),o=n(7497),s=n(9909),a=n(3070).f,u=n(654),l=n(1913),c=n(9781),h="Array Iterator",f=s.set,d=s.getterFor(h);t.exports=u(Array,"Array",(function(t,e){f(this,{type:h,target:r(t),index:0,kind:e})}),(function(){var t=d(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values");var p=o.Arguments=o.Array;if(i("keys"),i("values"),i("entries"),!l&&c&&"values"!==p.name)try{a(p,"name",{value:"values"})}catch(v){}},9600:function(t,e,n){"use strict";var r=n(2109),i=n(1702),o=n(8361),s=n(5656),a=n(9341),u=i([].join),l=o!=Object,c=a("join",",");r({target:"Array",proto:!0,forced:l||!c},{join:function(t){return u(s(this),void 0===t?",":t)}})},1249:function(t,e,n){"use strict";var r=n(2109),i=n(2092).map,o=n(1194),s=o("map");r({target:"Array",proto:!0,forced:!s},{map:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},7042:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(3157),s=n(4411),a=n(111),u=n(1400),l=n(6244),c=n(5656),h=n(6135),f=n(5112),d=n(1194),p=n(206),v=d("slice"),m=f("species"),g=i.Array,_=Math.max;r({target:"Array",proto:!0,forced:!v},{slice:function(t,e){var n,r,i,f=c(this),d=l(f),v=u(t,d),y=u(void 0===e?d:e,d);if(o(f)&&(n=f.constructor,s(n)&&(n===g||o(n.prototype))?n=void 0:a(n)&&(n=n[m],null===n&&(n=void 0)),n===g||void 0===n))return p(f,v,y);for(r=new(void 0===n?g:n)(_(y-v,0)),i=0;v<y;v++,i++)v in f&&h(r,i,f[v]);return r.length=i,r}})},561:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(1400),s=n(9303),a=n(6244),u=n(7908),l=n(5417),c=n(6135),h=n(1194),f=h("splice"),d=i.TypeError,p=Math.max,v=Math.min,m=9007199254740991,g="Maximum allowed length exceeded";r({target:"Array",proto:!0,forced:!f},{splice:function(t,e){var n,r,i,h,f,_,y=u(this),b=a(y),E=o(t,b),x=arguments.length;if(0===x?n=r=0:1===x?(n=0,r=b-E):(n=x-2,r=v(p(s(e),0),b-E)),b+n-r>m)throw d(g);for(i=l(y,r),h=0;h<r;h++)f=E+h,f in y&&c(i,h,y[f]);if(i.length=r,n<r){for(h=E;h<b-r;h++)f=h+r,_=h+n,f in y?y[_]=y[f]:delete y[_];for(h=b;h>b-r+n;h--)delete y[h-1]}else if(n>r)for(h=b-r;h>E;h--)f=h+r-1,_=h+n-1,f in y?y[_]=y[f]:delete y[_];for(h=0;h<n;h++)y[h+E]=arguments[h+2];return y.length=b-r+n,i}})},1703:function(t,e,n){var r=n(2109),i=n(7854),o=n(2104),s=n(9191),a="WebAssembly",u=i[a],l=7!==Error("e",{cause:7}).cause,c=function(t,e){var n={};n[t]=s(t,e,l),r({global:!0,forced:l},n)},h=function(t,e){if(u&&u[t]){var n={};n[t]=s(a+"."+t,e,l),r({target:a,stat:!0,forced:l},n)}};c("Error",(function(t){return function(e){return o(t,this,arguments)}})),c("EvalError",(function(t){return function(e){return o(t,this,arguments)}})),c("RangeError",(function(t){return function(e){return o(t,this,arguments)}})),c("ReferenceError",(function(t){return function(e){return o(t,this,arguments)}})),c("SyntaxError",(function(t){return function(e){return o(t,this,arguments)}})),c("TypeError",(function(t){return function(e){return o(t,this,arguments)}})),c("URIError",(function(t){return function(e){return o(t,this,arguments)}})),h("CompileError",(function(t){return function(e){return o(t,this,arguments)}})),h("LinkError",(function(t){return function(e){return o(t,this,arguments)}})),h("RuntimeError",(function(t){return function(e){return o(t,this,arguments)}}))},8309:function(t,e,n){var r=n(9781),i=n(6530).EXISTS,o=n(1702),s=n(3070).f,a=Function.prototype,u=o(a.toString),l=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,c=o(l.exec),h="name";r&&!i&&s(a,h,{configurable:!0,get:function(){try{return c(l,u(this))[1]}catch(t){return""}}})},8862:function(t,e,n){var r=n(2109),i=n(7854),o=n(5005),s=n(2104),a=n(1702),u=n(7293),l=i.Array,c=o("JSON","stringify"),h=a(/./.exec),f=a("".charAt),d=a("".charCodeAt),p=a("".replace),v=a(1..toString),m=/[\uD800-\uDFFF]/g,g=/^[\uD800-\uDBFF]$/,_=/^[\uDC00-\uDFFF]$/,y=function(t,e,n){var r=f(n,e-1),i=f(n,e+1);return h(g,t)&&!h(_,i)||h(_,t)&&!h(g,r)?"\\u"+v(d(t,0),16):t},b=u((function(){return'"\\udf06\\ud834"'!==c("\udf06\ud834")||'"\\udead"'!==c("\udead")}));c&&r({target:"JSON",stat:!0,forced:b},{stringify:function(t,e,n){for(var r=0,i=arguments.length,o=l(i);r<i;r++)o[r]=arguments[r];var a=s(c,null,o);return"string"==typeof a?p(a,m,y):a}})},658:function(t,e,n){var r=n(2109),i=n(403);r({target:"Math",stat:!0},{log10:i})},4914:function(t,e,n){var r=n(2109),i=Math.log,o=Math.LN2;r({target:"Math",stat:!0},{log2:function(t){return i(t)/o}})},2420:function(t,e,n){var r=n(2109),i=n(4310);r({target:"Math",stat:!0},{sign:i})},3689:function(t,e,n){var r=n(2109),i=Math.ceil,o=Math.floor;r({target:"Math",stat:!0},{trunc:function(t){return(t>0?o:i)(t)}})},9653:function(t,e,n){"use strict";var r=n(9781),i=n(7854),o=n(1702),s=n(4705),a=n(1320),u=n(2597),l=n(9587),c=n(7976),h=n(2190),f=n(7593),d=n(7293),p=n(8006).f,v=n(1236).f,m=n(3070).f,g=n(863),_=n(3111).trim,y="Number",b=i[y],E=b.prototype,x=i.TypeError,T=o("".slice),S=o("".charCodeAt),R=function(t){var e=f(t,"number");return"bigint"==typeof e?e:A(e)},A=function(t){var e,n,r,i,o,s,a,u,l=f(t,"number");if(h(l))throw x("Cannot convert a Symbol value to a number");if("string"==typeof l&&l.length>2)if(l=_(l),e=S(l,0),43===e||45===e){if(n=S(l,2),88===n||120===n)return NaN}else if(48===e){switch(S(l,1)){case 66:case 98:r=2,i=49;break;case 79:case 111:r=8,i=55;break;default:return+l}for(o=T(l,2),s=o.length,a=0;a<s;a++)if(u=S(o,a),u<48||u>i)return NaN;return parseInt(o,r)}return+l};if(s(y,!b(" 0o1")||!b("0b1")||b("+0x1"))){for(var O,w=function(t){var e=arguments.length<1?0:b(R(t)),n=this;return c(E,n)&&d((function(){g(n)}))?l(Object(e),n,w):e},I=r?p(b):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),P=0;I.length>P;P++)u(b,O=I[P])&&!u(w,O)&&m(w,O,v(b,O));w.prototype=E,E.constructor=w,a(i,y,w)}},5192:function(t,e,n){var r=n(2109),i=n(7023);r({target:"Number",stat:!0},{isFinite:i})},4048:function(t,e,n){var r=n(2109);r({target:"Number",stat:!0},{isNaN:function(t){return t!=t}})},1354:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(1702),s=n(9303),a=n(863),u=n(8415),l=n(403),c=n(7293),h=i.RangeError,f=i.String,d=i.isFinite,p=Math.abs,v=Math.floor,m=Math.pow,g=Math.round,_=o(1..toExponential),y=o(u),b=o("".slice),E="-6.9000e-11"===_(-69e-12,4)&&"1.25e+0"===_(1.255,2)&&"1.235e+4"===_(12345,3)&&"3e+1"===_(25,0),x=c((function(){_(1,1/0)}))&&c((function(){_(1,-1/0)})),T=!c((function(){_(1/0,1/0)}))&&!c((function(){_(NaN,1/0)})),S=!E||!x||!T;r({target:"Number",proto:!0,forced:S},{toExponential:function(t){var e=a(this);if(void 0===t)return _(e);var n=s(t);if(!d(e))return f(e);if(n<0||n>20)throw h("Incorrect fraction digits");if(E)return _(e,n);var r="",i="",o=0,u="",c="";if(e<0&&(r="-",e=-e),0===e)o=0,i=y("0",n+1);else{var x=l(e);o=v(x);var T=0,S=m(10,o-n);T=g(e/S),2*e>=(2*T+1)*S&&(T+=1),T>=m(10,n+1)&&(T/=10,o+=1),i=f(T)}return 0!==n&&(i=b(i,0,1)+"."+b(i,1)),0===o?(u="+",c="0"):(u=o>0?"+":"-",c=f(p(o))),i+="e"+u+c,r+i}})},6977:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(1702),s=n(9303),a=n(863),u=n(8415),l=n(7293),c=i.RangeError,h=i.String,f=Math.floor,d=o(u),p=o("".slice),v=o(1..toFixed),m=function(t,e,n){return 0===e?n:e%2===1?m(t,e-1,n*t):m(t*t,e/2,n)},g=function(t){var e=0,n=t;while(n>=4096)e+=12,n/=4096;while(n>=2)e+=1,n/=2;return e},_=function(t,e,n){var r=-1,i=n;while(++r<6)i+=e*t[r],t[r]=i%1e7,i=f(i/1e7)},y=function(t,e){var n=6,r=0;while(--n>=0)r+=t[n],t[n]=f(r/e),r=r%e*1e7},b=function(t){var e=6,n="";while(--e>=0)if(""!==n||0===e||0!==t[e]){var r=h(t[e]);n=""===n?r:n+d("0",7-r.length)+r}return n},E=l((function(){return"0.000"!==v(8e-5,3)||"1"!==v(.9,0)||"1.25"!==v(1.255,2)||"1000000000000000128"!==v(0xde0b6b3a7640080,0)}))||!l((function(){v({})}));r({target:"Number",proto:!0,forced:E},{toFixed:function(t){var e,n,r,i,o=a(this),u=s(t),l=[0,0,0,0,0,0],f="",v="0";if(u<0||u>20)throw c("Incorrect fraction digits");if(o!=o)return"NaN";if(o<=-1e21||o>=1e21)return h(o);if(o<0&&(f="-",o=-o),o>1e-21)if(e=g(o*m(2,69,1))-69,n=e<0?o*m(2,-e,1):o/m(2,e,1),n*=4503599627370496,e=52-e,e>0){_(l,0,n),r=u;while(r>=7)_(l,1e7,0),r-=7;_(l,m(10,r,1),0),r=e-1;while(r>=23)y(l,1<<23),r-=23;y(l,1<<r),_(l,1,1),y(l,2),v=b(l)}else _(l,0,n),_(l,1<<-e,0),v=b(l)+d("0",u);return u>0?(i=v.length,v=f+(i<=u?"0."+d("0",u-i)+v:p(v,0,i-u)+"."+p(v,i-u))):v=f+v,v}})},9601:function(t,e,n){var r=n(2109),i=n(1574);r({target:"Object",stat:!0,forced:Object.assign!==i},{assign:i})},5003:function(t,e,n){var r=n(2109),i=n(7293),o=n(5656),s=n(1236).f,a=n(9781),u=i((function(){s(1)})),l=!a||u;r({target:"Object",stat:!0,forced:l,sham:!a},{getOwnPropertyDescriptor:function(t,e){return s(o(t),e)}})},9337:function(t,e,n){var r=n(2109),i=n(9781),o=n(3887),s=n(5656),a=n(1236),u=n(6135);r({target:"Object",stat:!0,sham:!i},{getOwnPropertyDescriptors:function(t){var e,n,r=s(t),i=a.f,l=o(r),c={},h=0;while(l.length>h)n=i(r,e=l[h++]),void 0!==n&&u(c,e,n);return c}})},7941:function(t,e,n){var r=n(2109),i=n(7908),o=n(1956),s=n(7293),a=s((function(){o(1)}));r({target:"Object",stat:!0,forced:a},{keys:function(t){return o(i(t))}})},1539:function(t,e,n){var r=n(1694),i=n(1320),o=n(288);r||i(Object.prototype,"toString",o,{unsafe:!0})},2479:function(t,e,n){var r=n(2109),i=n(4699).values;r({target:"Object",stat:!0},{values:function(t){return i(t)}})},7727:function(t,e,n){"use strict";var r=n(2109),i=n(1913),o=n(3366),s=n(7293),a=n(5005),u=n(614),l=n(6707),c=n(9478),h=n(1320),f=!!o&&s((function(){o.prototype["finally"].call({then:function(){}},(function(){}))}));if(r({target:"Promise",proto:!0,real:!0,forced:f},{finally:function(t){var e=l(this,a("Promise")),n=u(t);return this.then(n?function(n){return c(e,t()).then((function(){return n}))}:t,n?function(n){return c(e,t()).then((function(){throw n}))}:t)}}),!i&&u(o)){var d=a("Promise").prototype["finally"];o.prototype["finally"]!==d&&h(o.prototype,"finally",d,{unsafe:!0})}},8674:function(t,e,n){"use strict";var r,i,o,s,a=n(2109),u=n(1913),l=n(7854),c=n(5005),h=n(6916),f=n(3366),d=n(1320),p=n(2248),v=n(7674),m=n(8003),g=n(6340),_=n(9662),y=n(614),b=n(111),E=n(5787),x=n(2788),T=n(408),S=n(7072),R=n(6707),A=n(261).set,O=n(5948),w=n(9478),I=n(842),P=n(8523),C=n(2534),N=n(8572),M=n(9909),D=n(4705),L=n(5112),F=n(7871),B=n(5268),U=n(7392),G=L("species"),k="Promise",X=M.getterFor(k),j=M.set,H=M.getterFor(k),V=f&&f.prototype,Y=f,W=V,z=l.TypeError,$=l.document,q=l.process,K=P.f,Z=K,J=!!($&&$.createEvent&&l.dispatchEvent),Q=y(l.PromiseRejectionEvent),tt="unhandledrejection",et="rejectionhandled",nt=0,rt=1,it=2,ot=1,st=2,at=!1,ut=D(k,(function(){var t=x(Y),e=t!==String(Y);if(!e&&66===U)return!0;if(u&&!W["finally"])return!0;if(U>=51&&/native code/.test(t))return!1;var n=new Y((function(t){t(1)})),r=function(t){t((function(){}),(function(){}))},i=n.constructor={};return i[G]=r,at=n.then((function(){}))instanceof r,!at||!e&&F&&!Q})),lt=ut||!S((function(t){Y.all(t)["catch"]((function(){}))})),ct=function(t){var e;return!(!b(t)||!y(e=t.then))&&e},ht=function(t,e){var n,r,i,o=e.value,s=e.state==rt,a=s?t.ok:t.fail,u=t.resolve,l=t.reject,c=t.domain;try{a?(s||(e.rejection===st&&mt(e),e.rejection=ot),!0===a?n=o:(c&&c.enter(),n=a(o),c&&(c.exit(),i=!0)),n===t.promise?l(z("Promise-chain cycle")):(r=ct(n))?h(r,n,u,l):u(n)):l(o)}catch(f){c&&!i&&c.exit(),l(f)}},ft=function(t,e){t.notified||(t.notified=!0,O((function(){var n,r=t.reactions;while(n=r.get())ht(n,t);t.notified=!1,e&&!t.rejection&&pt(t)})))},dt=function(t,e,n){var r,i;J?(r=$.createEvent("Event"),r.promise=e,r.reason=n,r.initEvent(t,!1,!0),l.dispatchEvent(r)):r={promise:e,reason:n},!Q&&(i=l["on"+t])?i(r):t===tt&&I("Unhandled promise rejection",n)},pt=function(t){h(A,l,(function(){var e,n=t.facade,r=t.value,i=vt(t);if(i&&(e=C((function(){B?q.emit("unhandledRejection",r,n):dt(tt,n,r)})),t.rejection=B||vt(t)?st:ot,e.error))throw e.value}))},vt=function(t){return t.rejection!==ot&&!t.parent},mt=function(t){h(A,l,(function(){var e=t.facade;B?q.emit("rejectionHandled",e):dt(et,e,t.value)}))},gt=function(t,e,n){return function(r){t(e,r,n)}},_t=function(t,e,n){t.done||(t.done=!0,n&&(t=n),t.value=e,t.state=it,ft(t,!0))},yt=function(t,e,n){if(!t.done){t.done=!0,n&&(t=n);try{if(t.facade===e)throw z("Promise can't be resolved itself");var r=ct(e);r?O((function(){var n={done:!1};try{h(r,e,gt(yt,n,t),gt(_t,n,t))}catch(i){_t(n,i,t)}})):(t.value=e,t.state=rt,ft(t,!1))}catch(i){_t({done:!1},i,t)}}};if(ut&&(Y=function(t){E(this,W),_(t),h(r,this);var e=X(this);try{t(gt(yt,e),gt(_t,e))}catch(n){_t(e,n)}},W=Y.prototype,r=function(t){j(this,{type:k,done:!1,notified:!1,parent:!1,reactions:new N,rejection:!1,state:nt,value:void 0})},r.prototype=p(W,{then:function(t,e){var n=H(this),r=K(R(this,Y));return n.parent=!0,r.ok=!y(t)||t,r.fail=y(e)&&e,r.domain=B?q.domain:void 0,n.state==nt?n.reactions.add(r):O((function(){ht(r,n)})),r.promise},catch:function(t){return this.then(void 0,t)}}),i=function(){var t=new r,e=X(t);this.promise=t,this.resolve=gt(yt,e),this.reject=gt(_t,e)},P.f=K=function(t){return t===Y||t===o?new i(t):Z(t)},!u&&y(f)&&V!==Object.prototype)){s=V.then,at||(d(V,"then",(function(t,e){var n=this;return new Y((function(t,e){h(s,n,t,e)})).then(t,e)}),{unsafe:!0}),d(V,"catch",W["catch"],{unsafe:!0}));try{delete V.constructor}catch(bt){}v&&v(V,W)}a({global:!0,wrap:!0,forced:ut},{Promise:Y}),m(Y,k,!1,!0),g(k),o=c(k),a({target:k,stat:!0,forced:ut},{reject:function(t){var e=K(this);return h(e.reject,void 0,t),e.promise}}),a({target:k,stat:!0,forced:u||ut},{resolve:function(t){return w(u&&this===o?Y:this,t)}}),a({target:k,stat:!0,forced:lt},{all:function(t){var e=this,n=K(e),r=n.resolve,i=n.reject,o=C((function(){var n=_(e.resolve),o=[],s=0,a=1;T(t,(function(t){var u=s++,l=!1;a++,h(n,e,t).then((function(t){l||(l=!0,o[u]=t,--a||r(o))}),i)})),--a||r(o)}));return o.error&&i(o.value),n.promise},race:function(t){var e=this,n=K(e),r=n.reject,i=C((function(){var i=_(e.resolve);T(t,(function(t){h(i,e,t).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}})},4858:function(t,e,n){var r=n(2109);r({target:"Reflect",stat:!0},{has:function(t,e){return e in t}})},7556:function(t,e,n){var r=n(2109),i=n(3887);r({target:"Reflect",stat:!0},{ownKeys:i})},1299:function(t,e,n){var r=n(2109),i=n(7854),o=n(8003);r({global:!0},{Reflect:{}}),o(i.Reflect,"Reflect",!0)},4916:function(t,e,n){"use strict";var r=n(2109),i=n(2261);r({target:"RegExp",proto:!0,forced:/./.exec!==i},{exec:i})},7601:function(t,e,n){"use strict";n(4916);var r=n(2109),i=n(7854),o=n(6916),s=n(1702),a=n(614),u=n(111),l=function(){var t=!1,e=/[ac]/;return e.exec=function(){return t=!0,/./.exec.apply(this,arguments)},!0===e.test("abc")&&t}(),c=i.Error,h=s(/./.test);r({target:"RegExp",proto:!0,forced:!l},{test:function(t){var e=this.exec;if(!a(e))return h(this,t);var n=o(e,this,t);if(null!==n&&!u(n))throw new c("RegExp exec method returned something other than an Object or null");return!!n}})},9714:function(t,e,n){"use strict";var r=n(1702),i=n(6530).PROPER,o=n(1320),s=n(9670),a=n(7976),u=n(1340),l=n(7293),c=n(7066),h="toString",f=RegExp.prototype,d=f[h],p=r(c),v=l((function(){return"/a/b"!=d.call({source:"a",flags:"b"})})),m=i&&d.name!=h;(v||m)&&o(RegExp.prototype,h,(function(){var t=s(this),e=u(t.source),n=t.flags,r=u(void 0===n&&a(f,t)&&!("flags"in f)?p(t):n);return"/"+e+"/"+r}),{unsafe:!0})},189:function(t,e,n){"use strict";var r=n(7710),i=n(5631);r("Set",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),i)},2023:function(t,e,n){"use strict";var r=n(2109),i=n(1702),o=n(3929),s=n(4488),a=n(1340),u=n(4964),l=i("".indexOf);r({target:"String",proto:!0,forced:!u("includes")},{includes:function(t){return!!~l(a(s(this)),a(o(t)),arguments.length>1?arguments[1]:void 0)}})},8783:function(t,e,n){"use strict";var r=n(8710).charAt,i=n(1340),o=n(9909),s=n(654),a="String Iterator",u=o.set,l=o.getterFor(a);s(String,"String",(function(t){u(this,{type:a,string:i(t),index:0})}),(function(){var t,e=l(this),n=e.string,i=e.index;return i>=n.length?{value:void 0,done:!0}:(t=r(n,i),e.index+=t.length,{value:t,done:!1})}))},9254:function(t,e,n){"use strict";var r=n(2109),i=n(4230),o=n(3429);r({target:"String",proto:!0,forced:o("link")},{link:function(t){return i(this,"a","href",t)}})},2481:function(t,e,n){var r=n(2109),i=n(8415);r({target:"String",proto:!0},{repeat:i})},5306:function(t,e,n){"use strict";var r=n(2104),i=n(6916),o=n(1702),s=n(7007),a=n(7293),u=n(9670),l=n(614),c=n(9303),h=n(7466),f=n(1340),d=n(4488),p=n(1530),v=n(8173),m=n(647),g=n(7651),_=n(5112),y=_("replace"),b=Math.max,E=Math.min,x=o([].concat),T=o([].push),S=o("".indexOf),R=o("".slice),A=function(t){return void 0===t?t:String(t)},O=function(){return"$0"==="a".replace(/./,"$0")}(),w=function(){return!!/./[y]&&""===/./[y]("a","$0")}(),I=!a((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")}));s("replace",(function(t,e,n){var o=w?"$":"$0";return[function(t,n){var r=d(this),o=void 0==t?void 0:v(t,y);return o?i(o,t,r,n):i(e,f(r),t,n)},function(t,i){var s=u(this),a=f(t);if("string"==typeof i&&-1===S(i,o)&&-1===S(i,"$<")){var d=n(e,s,a,i);if(d.done)return d.value}var v=l(i);v||(i=f(i));var _=s.global;if(_){var y=s.unicode;s.lastIndex=0}var O=[];while(1){var w=g(s,a);if(null===w)break;if(T(O,w),!_)break;var I=f(w[0]);""===I&&(s.lastIndex=p(a,h(s.lastIndex),y))}for(var P="",C=0,N=0;N<O.length;N++){w=O[N];for(var M=f(w[0]),D=b(E(c(w.index),a.length),0),L=[],F=1;F<w.length;F++)T(L,A(w[F]));var B=w.groups;if(v){var U=x([M],L,D,a);void 0!==B&&T(U,B);var G=f(r(i,void 0,U))}else G=m(M,a,D,L,B,i);D>=C&&(P+=R(a,C,D)+G,C=D+M.length)}return P+R(a,C)}]}),!I||!O||w)},7268:function(t,e,n){"use strict";var r=n(2109),i=n(4230),o=n(3429);r({target:"String",proto:!0,forced:o("small")},{small:function(){return i(this,"small","","")}})},3123:function(t,e,n){"use strict";var r=n(2104),i=n(6916),o=n(1702),s=n(7007),a=n(7850),u=n(9670),l=n(4488),c=n(6707),h=n(1530),f=n(7466),d=n(1340),p=n(8173),v=n(1589),m=n(7651),g=n(2261),_=n(2999),y=n(7293),b=_.UNSUPPORTED_Y,E=4294967295,x=Math.min,T=[].push,S=o(/./.exec),R=o(T),A=o("".slice),O=!y((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));s("split",(function(t,e,n){var o;return o="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,n){var o=d(l(this)),s=void 0===n?E:n>>>0;if(0===s)return[];if(void 0===t)return[o];if(!a(t))return i(e,o,t,s);var u,c,h,f=[],p=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),m=0,_=new RegExp(t.source,p+"g");while(u=i(g,_,o)){if(c=_.lastIndex,c>m&&(R(f,A(o,m,u.index)),u.length>1&&u.index<o.length&&r(T,f,v(u,1)),h=u[0].length,m=c,f.length>=s))break;_.lastIndex===u.index&&_.lastIndex++}return m===o.length?!h&&S(_,"")||R(f,""):R(f,A(o,m)),f.length>s?v(f,0,s):f}:"0".split(void 0,0).length?function(t,n){return void 0===t&&0===n?[]:i(e,this,t,n)}:e,[function(e,n){var r=l(this),s=void 0==e?void 0:p(e,t);return s?i(s,e,r,n):i(o,d(r),e,n)},function(t,r){var i=u(this),s=d(t),a=n(o,i,s,r,o!==e);if(a.done)return a.value;var l=c(i,RegExp),p=i.unicode,v=(i.ignoreCase?"i":"")+(i.multiline?"m":"")+(i.unicode?"u":"")+(b?"g":"y"),g=new l(b?"^(?:"+i.source+")":i,v),_=void 0===r?E:r>>>0;if(0===_)return[];if(0===s.length)return null===m(g,s)?[s]:[];var y=0,T=0,S=[];while(T<s.length){g.lastIndex=b?0:T;var O,w=m(g,b?A(s,T):s);if(null===w||(O=x(f(g.lastIndex+(b?T:0)),s.length))===y)T=h(s,T,p);else{if(R(S,A(s,y,T)),S.length===_)return S;for(var I=1;I<=w.length-1;I++)if(R(S,w[I]),S.length===_)return S;T=y=O}}return R(S,A(s,y)),S}]}),!O,b)},86:function(t,e,n){"use strict";var r=n(2109),i=n(4230),o=n(3429);r({target:"String",proto:!0,forced:o("sub")},{sub:function(){return i(this,"sub","","")}})},3210:function(t,e,n){"use strict";var r=n(2109),i=n(3111).trim,o=n(6091);r({target:"String",proto:!0,forced:o("trim")},{trim:function(){return i(this)}})},1817:function(t,e,n){"use strict";var r=n(2109),i=n(9781),o=n(7854),s=n(1702),a=n(2597),u=n(614),l=n(7976),c=n(1340),h=n(3070).f,f=n(9920),d=o.Symbol,p=d&&d.prototype;if(i&&u(d)&&(!("description"in p)||void 0!==d().description)){var v={},m=function(){var t=arguments.length<1||void 0===arguments[0]?void 0:c(arguments[0]),e=l(p,this)?new d(t):void 0===t?d():d(t);return""===t&&(v[e]=!0),e};f(m,d),m.prototype=p,p.constructor=m;var g="Symbol(test)"==String(d("test")),_=s(p.toString),y=s(p.valueOf),b=/^Symbol\((.*)\)[^)]+$/,E=s("".replace),x=s("".slice);h(p,"description",{configurable:!0,get:function(){var t=y(this),e=_(t);if(a(v,t))return"";var n=g?x(e,7,-1):E(e,b,"$1");return""===n?void 0:n}}),r({global:!0,forced:!0},{Symbol:m})}},2165:function(t,e,n){var r=n(7235);r("iterator")},2526:function(t,e,n){"use strict";var r=n(2109),i=n(7854),o=n(5005),s=n(2104),a=n(6916),u=n(1702),l=n(1913),c=n(9781),h=n(133),f=n(7293),d=n(2597),p=n(3157),v=n(614),m=n(111),g=n(7976),_=n(2190),y=n(9670),b=n(7908),E=n(5656),x=n(4948),T=n(1340),S=n(9114),R=n(30),A=n(1956),O=n(8006),w=n(1156),I=n(5181),P=n(1236),C=n(3070),N=n(6048),M=n(5296),D=n(206),L=n(1320),F=n(2309),B=n(6200),U=n(3501),G=n(9711),k=n(5112),X=n(6061),j=n(7235),H=n(8003),V=n(9909),Y=n(2092).forEach,W=B("hidden"),z="Symbol",$="prototype",q=k("toPrimitive"),K=V.set,Z=V.getterFor(z),J=Object[$],Q=i.Symbol,tt=Q&&Q[$],et=i.TypeError,nt=i.QObject,rt=o("JSON","stringify"),it=P.f,ot=C.f,st=w.f,at=M.f,ut=u([].push),lt=F("symbols"),ct=F("op-symbols"),ht=F("string-to-symbol-registry"),ft=F("symbol-to-string-registry"),dt=F("wks"),pt=!nt||!nt[$]||!nt[$].findChild,vt=c&&f((function(){return 7!=R(ot({},"a",{get:function(){return ot(this,"a",{value:7}).a}})).a}))?function(t,e,n){var r=it(J,e);r&&delete J[e],ot(t,e,n),r&&t!==J&&ot(J,e,r)}:ot,mt=function(t,e){var n=lt[t]=R(tt);return K(n,{type:z,tag:t,description:e}),c||(n.description=e),n},gt=function(t,e,n){t===J&>(ct,e,n),y(t);var r=x(e);return y(n),d(lt,r)?(n.enumerable?(d(t,W)&&t[W][r]&&(t[W][r]=!1),n=R(n,{enumerable:S(0,!1)})):(d(t,W)||ot(t,W,S(1,{})),t[W][r]=!0),vt(t,r,n)):ot(t,r,n)},_t=function(t,e){y(t);var n=E(e),r=A(n).concat(Tt(n));return Y(r,(function(e){c&&!a(bt,n,e)||gt(t,e,n[e])})),t},yt=function(t,e){return void 0===e?R(t):_t(R(t),e)},bt=function(t){var e=x(t),n=a(at,this,e);return!(this===J&&d(lt,e)&&!d(ct,e))&&(!(n||!d(this,e)||!d(lt,e)||d(this,W)&&this[W][e])||n)},Et=function(t,e){var n=E(t),r=x(e);if(n!==J||!d(lt,r)||d(ct,r)){var i=it(n,r);return!i||!d(lt,r)||d(n,W)&&n[W][r]||(i.enumerable=!0),i}},xt=function(t){var e=st(E(t)),n=[];return Y(e,(function(t){d(lt,t)||d(U,t)||ut(n,t)})),n},Tt=function(t){var e=t===J,n=st(e?ct:E(t)),r=[];return Y(n,(function(t){!d(lt,t)||e&&!d(J,t)||ut(r,lt[t])})),r};if(h||(Q=function(){if(g(tt,this))throw et("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?T(arguments[0]):void 0,e=G(t),n=function(t){this===J&&a(n,ct,t),d(this,W)&&d(this[W],e)&&(this[W][e]=!1),vt(this,e,S(1,t))};return c&&pt&&vt(J,e,{configurable:!0,set:n}),mt(e,t)},tt=Q[$],L(tt,"toString",(function(){return Z(this).tag})),L(Q,"withoutSetter",(function(t){return mt(G(t),t)})),M.f=bt,C.f=gt,N.f=_t,P.f=Et,O.f=w.f=xt,I.f=Tt,X.f=function(t){return mt(k(t),t)},c&&(ot(tt,"description",{configurable:!0,get:function(){return Z(this).description}}),l||L(J,"propertyIsEnumerable",bt,{unsafe:!0}))),r({global:!0,wrap:!0,forced:!h,sham:!h},{Symbol:Q}),Y(A(dt),(function(t){j(t)})),r({target:z,stat:!0,forced:!h},{for:function(t){var e=T(t);if(d(ht,e))return ht[e];var n=Q(e);return ht[e]=n,ft[n]=e,n},keyFor:function(t){if(!_(t))throw et(t+" is not a symbol");if(d(ft,t))return ft[t]},useSetter:function(){pt=!0},useSimple:function(){pt=!1}}),r({target:"Object",stat:!0,forced:!h,sham:!c},{create:yt,defineProperty:gt,defineProperties:_t,getOwnPropertyDescriptor:Et}),r({target:"Object",stat:!0,forced:!h},{getOwnPropertyNames:xt,getOwnPropertySymbols:Tt}),r({target:"Object",stat:!0,forced:f((function(){I.f(1)}))},{getOwnPropertySymbols:function(t){return I.f(b(t))}}),rt){var St=!h||f((function(){var t=Q();return"[null]"!=rt([t])||"{}"!=rt({a:t})||"{}"!=rt(Object(t))}));r({target:"JSON",stat:!0,forced:St},{stringify:function(t,e,n){var r=D(arguments),i=e;if((m(e)||void 0!==t)&&!_(t))return p(e)||(e=function(t,e){if(v(i)&&(e=a(i,this,t,e)),!_(e))return e}),r[1]=e,s(rt,null,r)}})}if(!tt[q]){var Rt=tt.valueOf;L(tt,q,(function(t){return a(Rt,this)}))}H(Q,z),U[W]=!0},4747:function(t,e,n){var r=n(7854),i=n(8324),o=n(8509),s=n(8533),a=n(8880),u=function(t){if(t&&t.forEach!==s)try{a(t,"forEach",s)}catch(e){t.forEach=s}};for(var l in i)i[l]&&u(r[l]&&r[l].prototype);u(o)},3948:function(t,e,n){var r=n(7854),i=n(8324),o=n(8509),s=n(6992),a=n(8880),u=n(5112),l=u("iterator"),c=u("toStringTag"),h=s.values,f=function(t,e){if(t){if(t[l]!==h)try{a(t,l,h)}catch(r){t[l]=h}if(t[c]||a(t,c,e),i[e])for(var n in s)if(t[n]!==s[n])try{a(t,n,s[n])}catch(r){t[n]=s[n]}}};for(var d in i)f(r[d]&&r[d].prototype,d);f(o,"DOMTokenList")},7714:function(t,e,n){"use strict";var r=n(2109),i=n(4038),o=n(5005),s=n(7293),a=n(30),u=n(9114),l=n(3070).f,c=n(6048).f,h=n(1320),f=n(2597),d=n(5787),p=n(9670),v=n(7762),m=n(6277),g=n(3678),_=n(7741),y=n(9909),b=n(9781),E=n(1913),x="DOMException",T="DATA_CLONE_ERR",S=o("Error"),R=o(x)||function(){try{var t=o("MessageChannel")||i("worker_threads").MessageChannel;(new t).port1.postMessage(new WeakMap)}catch(e){if(e.name==T&&25==e.code)return e.constructor}}(),A=R&&R.prototype,O=S.prototype,w=y.set,I=y.getterFor(x),P="stack"in S(x),C=function(t){return f(g,t)&&g[t].m?g[t].c:0},N=function(){d(this,M);var t=arguments.length,e=m(t<1?void 0:arguments[0]),n=m(t<2?void 0:arguments[1],"Error"),r=C(n);if(w(this,{type:x,name:n,message:e,code:r}),b||(this.name=n,this.message=e,this.code=r),P){var i=S(e);i.name=x,l(this,"stack",u(1,_(i.stack,1)))}},M=N.prototype=a(O),D=function(t){return{enumerable:!0,configurable:!0,get:t}},L=function(t){return D((function(){return I(this)[t]}))};b&&c(M,{name:L("name"),message:L("message"),code:L("code")}),l(M,"constructor",u(1,N));var F=s((function(){return!(new R instanceof S)})),B=F||s((function(){return O.toString!==v||"2: 1"!==String(new R(1,2))})),U=F||s((function(){return 25!==new R(1,"DataCloneError").code})),G=F||25!==R[T]||25!==A[T],k=E?B||U||G:F;r({global:!0,forced:k},{DOMException:k?N:R});var X=o(x),j=X.prototype;for(var H in B&&(E||R===X)&&h(j,"toString",v),U&&b&&R===X&&l(j,"code",D((function(){return C(p(this).name)}))),g)if(f(g,H)){var V=g[H],Y=V.s,W=u(6,V.c);f(X,Y)||l(X,Y,W),f(j,Y)||l(j,Y,W)}},2801:function(t,e,n){"use strict";var r=n(2109),i=n(5005),o=n(9114),s=n(3070).f,a=n(2597),u=n(5787),l=n(9587),c=n(6277),h=n(3678),f=n(7741),d=n(1913),p="DOMException",v=i("Error"),m=i(p),g=function(){u(this,_);var t=arguments.length,e=c(t<1?void 0:arguments[0]),n=c(t<2?void 0:arguments[1],"Error"),r=new m(e,n),i=v(e);return i.name=p,s(r,"stack",o(1,f(i.stack,1))),l(r,this,g),r},_=g.prototype=m.prototype,y="stack"in v(p),b="stack"in new m(1,2),E=y&&!b;r({global:!0,forced:d||E},{DOMException:E?g:m});var x=i(p),T=x.prototype;if(T.constructor!==x)for(var S in d||s(T,"constructor",o(1,x)),h)if(a(h,S)){var R=h[S],A=R.s;a(x,A)||s(x,A,o(6,R.c))}},1174:function(t,e,n){var r=n(5005),i=n(8003),o="DOMException";i(r(o),o)},9187:function(t){"use strict";function e(t,e,r){r=r||2;var o,s,a,u,c,h,f,d=e&&e.length,p=d?e[0]*r:t.length,v=n(t,0,p,r,!0),m=[];if(!v||v.next===v.prev)return m;if(d&&(v=l(t,e,v,r)),t.length>80*r){o=a=t[0],s=u=t[1];for(var g=r;g<p;g+=r)c=t[g],h=t[g+1],c<o&&(o=c),h<s&&(s=h),c>a&&(a=c),h>u&&(u=h);f=Math.max(a-o,u-s),f=0!==f?1/f:0}return i(v,m,r,o,s,f),m}function n(t,e,n,r,i){var o,s;if(i===N(t,e,n,r)>0)for(o=e;o<n;o+=r)s=I(o,t[o],t[o+1],s);else for(o=n-r;o>=e;o-=r)s=I(o,t[o],t[o+1],s);return s&&E(s,s.next)&&(P(s),s=s.next),s}function r(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!E(r,r.next)&&0!==b(r.prev,r,r.next))r=r.next;else{if(P(r),r=e=r.prev,r===r.next)break;n=!0}}while(n||r!==e);return e}function i(t,e,n,l,c,h,f){if(t){!f&&h&&p(t,l,c,h);var d,v,m=t;while(t.prev!==t.next)if(d=t.prev,v=t.next,h?s(t,l,c,h):o(t))e.push(d.i/n),e.push(t.i/n),e.push(v.i/n),P(t),t=v.next,m=v.next;else if(t=v,t===m){f?1===f?(t=a(r(t),e,n),i(t,e,n,l,c,h,2)):2===f&&u(t,e,n,l,c,h):i(r(t),e,n,l,c,h,1);break}}}function o(t){var e=t.prev,n=t,r=t.next;if(b(e,n,r)>=0)return!1;var i=t.next.next;while(i!==t.prev){if(_(e.x,e.y,n.x,n.y,r.x,r.y,i.x,i.y)&&b(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function s(t,e,n,r){var i=t.prev,o=t,s=t.next;if(b(i,o,s)>=0)return!1;var a=i.x<o.x?i.x<s.x?i.x:s.x:o.x<s.x?o.x:s.x,u=i.y<o.y?i.y<s.y?i.y:s.y:o.y<s.y?o.y:s.y,l=i.x>o.x?i.x>s.x?i.x:s.x:o.x>s.x?o.x:s.x,c=i.y>o.y?i.y>s.y?i.y:s.y:o.y>s.y?o.y:s.y,h=m(a,u,e,n,r),f=m(l,c,e,n,r),d=t.prevZ,p=t.nextZ;while(d&&d.z>=h&&p&&p.z<=f){if(d!==t.prev&&d!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,d.x,d.y)&&b(d.prev,d,d.next)>=0)return!1;if(d=d.prevZ,p!==t.prev&&p!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&b(p.prev,p,p.next)>=0)return!1;p=p.nextZ}while(d&&d.z>=h){if(d!==t.prev&&d!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,d.x,d.y)&&b(d.prev,d,d.next)>=0)return!1;d=d.prevZ}while(p&&p.z<=f){if(p!==t.prev&&p!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&b(p.prev,p,p.next)>=0)return!1;p=p.nextZ}return!0}function a(t,e,n){var i=t;do{var o=i.prev,s=i.next.next;!E(o,s)&&x(o,i,i.next,s)&&A(o,s)&&A(s,o)&&(e.push(o.i/n),e.push(i.i/n),e.push(s.i/n),P(i),P(i.next),i=t=s),i=i.next}while(i!==t);return r(i)}function u(t,e,n,o,s,a){var u=t;do{var l=u.next.next;while(l!==u.prev){if(u.i!==l.i&&y(u,l)){var c=w(u,l);return u=r(u,u.next),c=r(c,c.next),i(u,e,n,o,s,a),void i(c,e,n,o,s,a)}l=l.next}u=u.next}while(u!==t)}function l(t,e,i,o){var s,a,u,l,f,d=[];for(s=0,a=e.length;s<a;s++)u=e[s]*o,l=s<a-1?e[s+1]*o:t.length,f=n(t,u,l,o,!1),f===f.next&&(f.steiner=!0),d.push(g(f));for(d.sort(c),s=0;s<d.length;s++)i=h(d[s],i),i=r(i,i.next);return i}function c(t,e){return t.x-e.x}function h(t,e){var n=f(t,e);if(!n)return e;var i=w(n,t),o=r(n,n.next);return r(i,i.next),e===n?o:e}function f(t,e){var n,r=e,i=t.x,o=t.y,s=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var a=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(a<=i&&a>s){if(s=a,a===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==e);if(!n)return null;if(i===s)return n;var u,l=n,c=n.x,h=n.y,f=1/0;r=n;do{i>=r.x&&r.x>=c&&i!==r.x&&_(o<h?i:s,o,c,h,o<h?s:i,o,r.x,r.y)&&(u=Math.abs(o-r.y)/(i-r.x),A(r,t)&&(u<f||u===f&&(r.x>n.x||r.x===n.x&&d(n,r)))&&(n=r,f=u)),r=r.next}while(r!==l);return n}function d(t,e){return b(t.prev,t,e.prev)<0&&b(e.next,t,t.next)<0}function p(t,e,n,r){var i=t;do{null===i.z&&(i.z=m(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,v(i)}function v(t){var e,n,r,i,o,s,a,u,l=1;do{n=t,t=null,o=null,s=0;while(n){for(s++,r=n,a=0,e=0;e<l;e++)if(a++,r=r.nextZ,!r)break;u=l;while(a>0||u>0&&r)0!==a&&(0===u||!r||n.z<=r.z)?(i=n,n=n.nextZ,a--):(i=r,r=r.nextZ,u--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;n=r}o.nextZ=null,l*=2}while(s>1);return t}function m(t,e,n,r,i){return t=32767*(t-n)*i,e=32767*(e-r)*i,t=16711935&(t|t<<8),t=252645135&(t|t<<4),t=858993459&(t|t<<2),t=1431655765&(t|t<<1),e=16711935&(e|e<<8),e=252645135&(e|e<<4),e=858993459&(e|e<<2),e=1431655765&(e|e<<1),t|e<<1}function g(t){var e=t,n=t;do{(e.x<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function _(t,e,n,r,i,o,s,a){return(i-s)*(e-a)-(t-s)*(o-a)>=0&&(t-s)*(r-a)-(n-s)*(e-a)>=0&&(n-s)*(o-a)-(i-s)*(r-a)>=0}function y(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!R(t,e)&&(A(t,e)&&A(e,t)&&O(t,e)&&(b(t.prev,t,e.prev)||b(t,e.prev,e))||E(t,e)&&b(t.prev,t,t.next)>0&&b(e.prev,e,e.next)>0)}function b(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function E(t,e){return t.x===e.x&&t.y===e.y}function x(t,e,n,r){var i=S(b(t,e,n)),o=S(b(t,e,r)),s=S(b(n,r,t)),a=S(b(n,r,e));return i!==o&&s!==a||(!(0!==i||!T(t,n,e))||(!(0!==o||!T(t,r,e))||(!(0!==s||!T(n,t,r))||!(0!==a||!T(n,e,r)))))}function T(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function S(t){return t>0?1:t<0?-1:0}function R(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&x(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}function A(t,e){return b(t.prev,t,t.next)<0?b(t,e,t.next)>=0&&b(t,t.prev,e)>=0:b(t,e,t.prev)<0||b(t,t.next,e)<0}function O(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!==n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}function w(t,e){var n=new C(t.i,t.x,t.y),r=new C(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function I(t,e,n,r){var i=new C(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function P(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function C(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function N(t,e,n,r){for(var i=0,o=e,s=n-r;o<n;o+=r)i+=(t[s]-t[o])*(t[o+1]+t[s+1]),s=o;return i}t.exports=e,t.exports["default"]=e,e.deviation=function(t,e,n,r){var i=e&&e.length,o=i?e[0]*n:t.length,s=Math.abs(N(t,0,o,n));if(i)for(var a=0,u=e.length;a<u;a++){var l=e[a]*n,c=a<u-1?e[a+1]*n:t.length;s-=Math.abs(N(t,l,c,n))}var h=0;for(a=0;a<r.length;a+=3){var f=r[a]*n,d=r[a+1]*n,p=r[a+2]*n;h+=Math.abs((t[f]-t[p])*(t[d+1]-t[f+1])-(t[f]-t[d])*(t[p+1]-t[f+1]))}return 0===s&&0===h?0:Math.abs((h-s)/s)},e.flatten=function(t){for(var e=t[0][0].length,n={vertices:[],holes:[],dimensions:e},r=0,i=0;i<t.length;i++){for(var o=0;o<t[i].length;o++)for(var s=0;s<e;s++)n.vertices.push(t[i][o][s]);i>0&&(r+=t[i-1].length,n.holes.push(r))}return n}},6961:function(t,e,n){var r,i=function(){var t=String.fromCharCode,e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",r={};function i(t,e){if(!r[t]){r[t]={};for(var n=0;n<t.length;n++)r[t][t.charAt(n)]=n}return r[t][e]}var o={compressToBase64:function(t){if(null==t)return"";var n=o._compress(t,6,(function(t){return e.charAt(t)}));switch(n.length%4){default:case 0:return n;case 1:return n+"===";case 2:return n+"==";case 3:return n+"="}},decompressFromBase64:function(t){return null==t?"":""==t?null:o._decompress(t.length,32,(function(n){return i(e,t.charAt(n))}))},compressToUTF16:function(e){return null==e?"":o._compress(e,15,(function(e){return t(e+32)}))+" "},decompressFromUTF16:function(t){return null==t?"":""==t?null:o._decompress(t.length,16384,(function(e){return t.charCodeAt(e)-32}))},compressToUint8Array:function(t){for(var e=o.compress(t),n=new Uint8Array(2*e.length),r=0,i=e.length;r<i;r++){var s=e.charCodeAt(r);n[2*r]=s>>>8,n[2*r+1]=s%256}return n},decompressFromUint8Array:function(e){if(null===e||void 0===e)return o.decompress(e);for(var n=new Array(e.length/2),r=0,i=n.length;r<i;r++)n[r]=256*e[2*r]+e[2*r+1];var s=[];return n.forEach((function(e){s.push(t(e))})),o.decompress(s.join(""))},compressToEncodedURIComponent:function(t){return null==t?"":o._compress(t,6,(function(t){return n.charAt(t)}))},decompressFromEncodedURIComponent:function(t){return null==t?"":""==t?null:(t=t.replace(/ /g,"+"),o._decompress(t.length,32,(function(e){return i(n,t.charAt(e))})))},compress:function(e){return o._compress(e,16,(function(e){return t(e)}))},_compress:function(t,e,n){if(null==t)return"";var r,i,o,s={},a={},u="",l="",c="",h=2,f=3,d=2,p=[],v=0,m=0;for(o=0;o<t.length;o+=1)if(u=t.charAt(o),Object.prototype.hasOwnProperty.call(s,u)||(s[u]=f++,a[u]=!0),l=c+u,Object.prototype.hasOwnProperty.call(s,l))c=l;else{if(Object.prototype.hasOwnProperty.call(a,c)){if(c.charCodeAt(0)<256){for(r=0;r<d;r++)v<<=1,m==e-1?(m=0,p.push(n(v)),v=0):m++;for(i=c.charCodeAt(0),r=0;r<8;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1}else{for(i=1,r=0;r<d;r++)v=v<<1|i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i=0;for(i=c.charCodeAt(0),r=0;r<16;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1}h--,0==h&&(h=Math.pow(2,d),d++),delete a[c]}else for(i=s[c],r=0;r<d;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1;h--,0==h&&(h=Math.pow(2,d),d++),s[l]=f++,c=String(u)}if(""!==c){if(Object.prototype.hasOwnProperty.call(a,c)){if(c.charCodeAt(0)<256){for(r=0;r<d;r++)v<<=1,m==e-1?(m=0,p.push(n(v)),v=0):m++;for(i=c.charCodeAt(0),r=0;r<8;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1}else{for(i=1,r=0;r<d;r++)v=v<<1|i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i=0;for(i=c.charCodeAt(0),r=0;r<16;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1}h--,0==h&&(h=Math.pow(2,d),d++),delete a[c]}else for(i=s[c],r=0;r<d;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1;h--,0==h&&(h=Math.pow(2,d),d++)}for(i=2,r=0;r<d;r++)v=v<<1|1&i,m==e-1?(m=0,p.push(n(v)),v=0):m++,i>>=1;while(1){if(v<<=1,m==e-1){p.push(n(v));break}m++}return p.join("")},decompress:function(t){return null==t?"":""==t?null:o._decompress(t.length,32768,(function(e){return t.charCodeAt(e)}))},_decompress:function(e,n,r){var i,o,s,a,u,l,c,h=[],f=4,d=4,p=3,v="",m=[],g={val:r(0),position:n,index:1};for(i=0;i<3;i+=1)h[i]=i;s=0,u=Math.pow(2,2),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;switch(s){case 0:s=0,u=Math.pow(2,8),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;c=t(s);break;case 1:s=0,u=Math.pow(2,16),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;c=t(s);break;case 2:return""}h[3]=c,o=c,m.push(c);while(1){if(g.index>e)return"";s=0,u=Math.pow(2,p),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;switch(c=s){case 0:s=0,u=Math.pow(2,8),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;h[d++]=t(s),c=d-1,f--;break;case 1:s=0,u=Math.pow(2,16),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;h[d++]=t(s),c=d-1,f--;break;case 2:return m.join("")}if(0==f&&(f=Math.pow(2,p),p++),h[c])v=h[c];else{if(c!==d)return null;v=o+o.charAt(0)}m.push(v),h[d++]=o+v.charAt(0),f--,o=v,0==f&&(f=Math.pow(2,p),p++)}}};return o}();r=function(){return i}.call(e,n,e,t),void 0===r||(t.exports=r)},343:function(){},7418:function(t){"use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/var e=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function i(t){if(null===t||void 0===t)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}function o(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de","5"===Object.getOwnPropertyNames(t)[0])return!1;for(var e={},n=0;n<10;n++)e["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(e).map((function(t){return e[t]}));if("0123456789"!==r.join(""))return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach((function(t){i[t]=t})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},i)).join("")}catch(o){return!1}}t.exports=o()?Object.assign:function(t,o){for(var s,a,u=i(t),l=1;l<arguments.length;l++){for(var c in s=Object(arguments[l]),s)n.call(s,c)&&(u[c]=s[c]);if(e){a=e(s);for(var h=0;h<a.length;h++)r.call(s,a[h])&&(u[a[h]]=s[a[h]])}}return u}},6591:function(t,e,n){"use strict";function r(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){return e.reject(n)}))}))}n.d(e,{MxU:function(){return Q}});var i=r;function o(t){var e=this;return new e((function(e,n){if(!t||"undefined"===typeof t.length)return n(new TypeError(typeof t+" "+t+" is not iterable(cannot read property Symbol(Symbol.iterator))"));var r=Array.prototype.slice.call(t);if(0===r.length)return e([]);var i=r.length;function o(t,n){if(n&&("object"===typeof n||"function"===typeof n)){var s=n.then;if("function"===typeof s)return void s.call(n,(function(e){o(t,e)}),(function(n){r[t]={status:"rejected",reason:n},0===--i&&e(r)}))}r[t]={status:"fulfilled",value:n},0===--i&&e(r)}for(var s=0;s<r.length;s++)o(s,r[s])}))}var s=o,a=setTimeout;function u(t){return Boolean(t&&"undefined"!==typeof t.length)}function l(){}function c(t,e){return function(){t.apply(e,arguments)}}function h(t){if(!(this instanceof h))throw new TypeError("Promises must be constructed via new");if("function"!==typeof t)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],g(t,this)}function f(t,e){while(3===t._state)t=t._value;0!==t._state?(t._handled=!0,h._immediateFn((function(){var n=1===t._state?e.onFulfilled:e.onRejected;if(null!==n){var r;try{r=n(t._value)}catch(i){return void p(e.promise,i)}d(e.promise,r)}else(1===t._state?d:p)(e.promise,t._value)}))):t._deferreds.push(e)}function d(t,e){try{if(e===t)throw new TypeError("A promise cannot be resolved with itself.");if(e&&("object"===typeof e||"function"===typeof e)){var n=e.then;if(e instanceof h)return t._state=3,t._value=e,void v(t);if("function"===typeof n)return void g(c(n,e),t)}t._state=1,t._value=e,v(t)}catch(r){p(t,r)}}function p(t,e){t._state=2,t._value=e,v(t)}function v(t){2===t._state&&0===t._deferreds.length&&h._immediateFn((function(){t._handled||h._unhandledRejectionFn(t._value)}));for(var e=0,n=t._deferreds.length;e<n;e++)f(t,t._deferreds[e]);t._deferreds=null}function m(t,e,n){this.onFulfilled="function"===typeof t?t:null,this.onRejected="function"===typeof e?e:null,this.promise=n}function g(t,e){var n=!1;try{t((function(t){n||(n=!0,d(e,t))}),(function(t){n||(n=!0,p(e,t))}))}catch(r){if(n)return;n=!0,p(e,r)}}h.prototype["catch"]=function(t){return this.then(null,t)},h.prototype.then=function(t,e){var n=new this.constructor(l);return f(this,new m(t,e,n)),n},h.prototype["finally"]=i,h.all=function(t){return new h((function(e,n){if(!u(t))return n(new TypeError("Promise.all accepts an array"));var r=Array.prototype.slice.call(t);if(0===r.length)return e([]);var i=r.length;function o(t,s){try{if(s&&("object"===typeof s||"function"===typeof s)){var a=s.then;if("function"===typeof a)return void a.call(s,(function(e){o(t,e)}),n)}r[t]=s,0===--i&&e(r)}catch(u){n(u)}}for(var s=0;s<r.length;s++)o(s,r[s])}))},h.allSettled=s,h.resolve=function(t){return t&&"object"===typeof t&&t.constructor===h?t:new h((function(e){e(t)}))},h.reject=function(t){return new h((function(e,n){n(t)}))},h.race=function(t){return new h((function(e,n){if(!u(t))return n(new TypeError("Promise.race accepts an array"));for(var r=0,i=t.length;r<i;r++)h.resolve(t[r]).then(e,n)}))},h._immediateFn="function"===typeof setImmediate&&function(t){setImmediate(t)}||function(t){a(t,0)},h._unhandledRejectionFn=function(t){"undefined"!==typeof console&&console&&console.warn("Possible Unhandled Promise Rejection:",t)};var _=h,y=n(7418),b=n.n(y); -/*! - * @pixi/polyfill - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/polyfill is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -"undefined"===typeof globalThis&&("undefined"!==typeof self?self.globalThis=self:"undefined"!==typeof n.g&&(n.g.globalThis=n.g)),globalThis.Promise||(globalThis.Promise=_),Object.assign||(Object.assign=b());var E=16;if(Date.now&&Date.prototype.getTime||(Date.now=function(){return(new Date).getTime()}),!globalThis.performance||!globalThis.performance.now){var x=Date.now();globalThis.performance||(globalThis.performance={}),globalThis.performance.now=function(){return Date.now()-x}}for(var T=Date.now(),S=["ms","moz","webkit","o"],R=0;R<S.length&&!globalThis.requestAnimationFrame;++R){var A=S[R];globalThis.requestAnimationFrame=globalThis[A+"RequestAnimationFrame"],globalThis.cancelAnimationFrame=globalThis[A+"CancelAnimationFrame"]||globalThis[A+"CancelRequestAnimationFrame"]}globalThis.requestAnimationFrame||(globalThis.requestAnimationFrame=function(t){if("function"!==typeof t)throw new TypeError(t+"is not a function");var e=Date.now(),n=E+T-e;return n<0&&(n=0),T=e,globalThis.self.setTimeout((function(){T=Date.now(),t(performance.now())}),n)}),globalThis.cancelAnimationFrame||(globalThis.cancelAnimationFrame=function(t){return clearTimeout(t)}),Math.sign||(Math.sign=function(t){return t=Number(t),0===t||isNaN(t)?t:t>0?1:-1}),Number.isInteger||(Number.isInteger=function(t){return"number"===typeof t&&isFinite(t)&&Math.floor(t)===t}),globalThis.ArrayBuffer||(globalThis.ArrayBuffer=Array),globalThis.Float32Array||(globalThis.Float32Array=Array),globalThis.Uint32Array||(globalThis.Uint32Array=Array),globalThis.Uint16Array||(globalThis.Uint16Array=Array),globalThis.Uint8Array||(globalThis.Uint8Array=Array),globalThis.Int32Array||(globalThis.Int32Array=Array);var O=n(8942),w=n(1585),I={accessible:!1,accessibleTitle:null,accessibleHint:null,tabIndex:0,_accessibleActive:!1,_accessibleDiv:null,accessibleType:"button",accessiblePointerEvents:"auto",accessibleChildren:!0,renderId:-1};w.s$.mixin(I);var P=9,C=100,N=0,M=0,D=2,L=1,F=-1e3,B=-1e3,U=2,G=function(){function t(t){this.debug=!1,this._isActive=!1,this._isMobileAccessibility=!1,this.pool=[],this.renderId=0,this.children=[],this.androidUpdateCount=0,this.androidUpdateFrequency=500,this._hookDiv=null,(O.tq.tablet||O.tq.phone)&&this.createTouchHook();var e=document.createElement("div");e.style.width=C+"px",e.style.height=C+"px",e.style.position="absolute",e.style.top=N+"px",e.style.left=M+"px",e.style.zIndex=D.toString(),this.div=e,this.renderer=t,this._onKeyDown=this._onKeyDown.bind(this),this._onMouseMove=this._onMouseMove.bind(this),globalThis.addEventListener("keydown",this._onKeyDown,!1)}return Object.defineProperty(t.prototype,"isActive",{get:function(){return this._isActive},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMobileAccessibility",{get:function(){return this._isMobileAccessibility},enumerable:!1,configurable:!0}),t.prototype.createTouchHook=function(){var t=this,e=document.createElement("button");e.style.width=L+"px",e.style.height=L+"px",e.style.position="absolute",e.style.top=F+"px",e.style.left=B+"px",e.style.zIndex=U.toString(),e.style.backgroundColor="#FF0000",e.title="select to enable accessibility for this content",e.addEventListener("focus",(function(){t._isMobileAccessibility=!0,t.activate(),t.destroyTouchHook()})),document.body.appendChild(e),this._hookDiv=e},t.prototype.destroyTouchHook=function(){this._hookDiv&&(document.body.removeChild(this._hookDiv),this._hookDiv=null)},t.prototype.activate=function(){var t;this._isActive||(this._isActive=!0,globalThis.document.addEventListener("mousemove",this._onMouseMove,!0),globalThis.removeEventListener("keydown",this._onKeyDown,!1),this.renderer.on("postrender",this.update,this),null===(t=this.renderer.view.parentNode)||void 0===t||t.appendChild(this.div))},t.prototype.deactivate=function(){var t;this._isActive&&!this._isMobileAccessibility&&(this._isActive=!1,globalThis.document.removeEventListener("mousemove",this._onMouseMove,!0),globalThis.addEventListener("keydown",this._onKeyDown,!1),this.renderer.off("postrender",this.update),null===(t=this.div.parentNode)||void 0===t||t.removeChild(this.div))},t.prototype.updateAccessibleObjects=function(t){if(t.visible&&t.accessibleChildren){t.accessible&&t.interactive&&(t._accessibleActive||this.addChild(t),t.renderId=this.renderId);var e=t.children;if(e)for(var n=0;n<e.length;n++)this.updateAccessibleObjects(e[n])}},t.prototype.update=function(){var t=performance.now();if(!(O.tq.android.device&&t<this.androidUpdateCount)&&(this.androidUpdateCount=t+this.androidUpdateFrequency,this.renderer.renderingToScreen)){this.renderer._lastObjectRendered&&this.updateAccessibleObjects(this.renderer._lastObjectRendered);var e=this.renderer.view.getBoundingClientRect(),n=e.left,r=e.top,i=e.width,o=e.height,s=this.renderer,a=s.width,u=s.height,l=s.resolution,c=i/a*l,h=o/u*l,f=this.div;f.style.left=n+"px",f.style.top=r+"px",f.style.width=a+"px",f.style.height=u+"px";for(var d=0;d<this.children.length;d++){var p=this.children[d];if(p.renderId!==this.renderId)p._accessibleActive=!1,(0,O.Er)(this.children,d,1),this.div.removeChild(p._accessibleDiv),this.pool.push(p._accessibleDiv),p._accessibleDiv=null,d--;else{f=p._accessibleDiv;var v=p.hitArea,m=p.worldTransform;p.hitArea?(f.style.left=(m.tx+v.x*m.a)*c+"px",f.style.top=(m.ty+v.y*m.d)*h+"px",f.style.width=v.width*m.a*c+"px",f.style.height=v.height*m.d*h+"px"):(v=p.getBounds(),this.capHitArea(v),f.style.left=v.x*c+"px",f.style.top=v.y*h+"px",f.style.width=v.width*c+"px",f.style.height=v.height*h+"px",f.title!==p.accessibleTitle&&null!==p.accessibleTitle&&(f.title=p.accessibleTitle),f.getAttribute("aria-label")!==p.accessibleHint&&null!==p.accessibleHint&&f.setAttribute("aria-label",p.accessibleHint)),p.accessibleTitle===f.title&&p.tabIndex===f.tabIndex||(f.title=p.accessibleTitle,f.tabIndex=p.tabIndex,this.debug&&this.updateDebugHTML(f))}}this.renderId++}},t.prototype.updateDebugHTML=function(t){t.innerHTML="type: "+t.type+"</br> title : "+t.title+"</br> tabIndex: "+t.tabIndex},t.prototype.capHitArea=function(t){t.x<0&&(t.width+=t.x,t.x=0),t.y<0&&(t.height+=t.y,t.y=0);var e=this.renderer,n=e.width,r=e.height;t.x+t.width>n&&(t.width=n-t.x),t.y+t.height>r&&(t.height=r-t.y)},t.prototype.addChild=function(t){var e=this.pool.pop();e||(e=document.createElement("button"),e.style.width=C+"px",e.style.height=C+"px",e.style.backgroundColor=this.debug?"rgba(255,255,255,0.5)":"transparent",e.style.position="absolute",e.style.zIndex=D.toString(),e.style.borderStyle="none",navigator.userAgent.toLowerCase().indexOf("chrome")>-1?e.setAttribute("aria-live","off"):e.setAttribute("aria-live","polite"),navigator.userAgent.match(/rv:.*Gecko\//)?e.setAttribute("aria-relevant","additions"):e.setAttribute("aria-relevant","text"),e.addEventListener("click",this._onClick.bind(this)),e.addEventListener("focus",this._onFocus.bind(this)),e.addEventListener("focusout",this._onFocusOut.bind(this))),e.style.pointerEvents=t.accessiblePointerEvents,e.type=t.accessibleType,t.accessibleTitle&&null!==t.accessibleTitle?e.title=t.accessibleTitle:t.accessibleHint&&null!==t.accessibleHint||(e.title="displayObject "+t.tabIndex),t.accessibleHint&&null!==t.accessibleHint&&e.setAttribute("aria-label",t.accessibleHint),this.debug&&this.updateDebugHTML(e),t._accessibleActive=!0,t._accessibleDiv=e,e.displayObject=t,this.children.push(t),this.div.appendChild(t._accessibleDiv),t._accessibleDiv.tabIndex=t.tabIndex},t.prototype._onClick=function(t){var e=this.renderer.plugins.interaction,n=t.target.displayObject,r=e.eventData;e.dispatchEvent(n,"click",r),e.dispatchEvent(n,"pointertap",r),e.dispatchEvent(n,"tap",r)},t.prototype._onFocus=function(t){t.target.getAttribute("aria-live")||t.target.setAttribute("aria-live","assertive");var e=this.renderer.plugins.interaction,n=t.target.displayObject,r=e.eventData;e.dispatchEvent(n,"mouseover",r)},t.prototype._onFocusOut=function(t){t.target.getAttribute("aria-live")||t.target.setAttribute("aria-live","polite");var e=this.renderer.plugins.interaction,n=t.target.displayObject,r=e.eventData;e.dispatchEvent(n,"mouseout",r)},t.prototype._onKeyDown=function(t){t.keyCode===P&&this.activate()},t.prototype._onMouseMove=function(t){0===t.movementX&&0===t.movementY||this.deactivate()},t.prototype.destroy=function(){this.destroyTouchHook(),this.div=null,globalThis.document.removeEventListener("mousemove",this._onMouseMove,!0),globalThis.removeEventListener("keydown",this._onKeyDown),this.pool=null,this.children=null,this.renderer=null},t}(),k=n(9658),X=n(6679),j=function(){function t(){this.pressure=0,this.rotationAngle=0,this.twist=0,this.tangentialPressure=0,this.global=new k.E9,this.target=null,this.originalEvent=null,this.identifier=null,this.isPrimary=!1,this.button=0,this.buttons=0,this.width=0,this.height=0,this.tiltX=0,this.tiltY=0,this.pointerType=null,this.pressure=0,this.rotationAngle=0,this.twist=0,this.tangentialPressure=0}return Object.defineProperty(t.prototype,"pointerId",{get:function(){return this.identifier},enumerable:!1,configurable:!0}),t.prototype.getLocalPosition=function(t,e,n){return t.worldTransform.applyInverse(n||this.global,e)},t.prototype.copyEvent=function(t){"isPrimary"in t&&t.isPrimary&&(this.isPrimary=!0),this.button="button"in t&&t.button;var e="buttons"in t&&t.buttons;this.buttons=Number.isInteger(e)?e:"which"in t&&t.which,this.width="width"in t&&t.width,this.height="height"in t&&t.height,this.tiltX="tiltX"in t&&t.tiltX,this.tiltY="tiltY"in t&&t.tiltY,this.pointerType="pointerType"in t&&t.pointerType,this.pressure="pressure"in t&&t.pressure,this.rotationAngle="rotationAngle"in t&&t.rotationAngle,this.twist="twist"in t&&t.twist||0,this.tangentialPressure="tangentialPressure"in t&&t.tangentialPressure||0},t.prototype.reset=function(){this.isPrimary=!1},t}(),H=function(t,e){return H=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},H(t,e)};function V(t,e){function n(){this.constructor=t}H(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Y=function(){function t(){this.stopped=!1,this.stopsPropagatingAt=null,this.stopPropagationHint=!1,this.target=null,this.currentTarget=null,this.type=null,this.data=null}return t.prototype.stopPropagation=function(){this.stopped=!0,this.stopPropagationHint=!0,this.stopsPropagatingAt=this.currentTarget},t.prototype.reset=function(){this.stopped=!1,this.stopsPropagatingAt=null,this.stopPropagationHint=!1,this.currentTarget=null,this.target=null},t}(),W=function(){function t(e){this._pointerId=e,this._flags=t.FLAGS.NONE}return t.prototype._doSet=function(t,e){this._flags=e?this._flags|t:this._flags&~t},Object.defineProperty(t.prototype,"pointerId",{get:function(){return this._pointerId},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"flags",{get:function(){return this._flags},set:function(t){this._flags=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"none",{get:function(){return this._flags===t.FLAGS.NONE},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"over",{get:function(){return 0!==(this._flags&t.FLAGS.OVER)},set:function(e){this._doSet(t.FLAGS.OVER,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rightDown",{get:function(){return 0!==(this._flags&t.FLAGS.RIGHT_DOWN)},set:function(e){this._doSet(t.FLAGS.RIGHT_DOWN,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"leftDown",{get:function(){return 0!==(this._flags&t.FLAGS.LEFT_DOWN)},set:function(e){this._doSet(t.FLAGS.LEFT_DOWN,e)},enumerable:!1,configurable:!0}),t.FLAGS=Object.freeze({NONE:0,OVER:1,LEFT_DOWN:2,RIGHT_DOWN:4}),t}(),z=function(){function t(){this._tempPoint=new k.E9}return t.prototype.recursiveFindHit=function(t,e,n,r,i){if(!e||!e.visible)return!1;var o=t.data.global;i=e.interactive||i;var s=!1,a=i,u=!0;if(e.hitArea?(r&&(e.worldTransform.applyInverse(o,this._tempPoint),e.hitArea.contains(this._tempPoint.x,this._tempPoint.y)?s=!0:(r=!1,u=!1)),a=!1):e._mask&&r&&(e._mask.containsPoint&&e._mask.containsPoint(o)||(r=!1)),u&&e.interactiveChildren&&e.children)for(var l=e.children,c=l.length-1;c>=0;c--){var h=l[c],f=this.recursiveFindHit(t,h,n,r,a);if(f){if(!h.parent)continue;a=!1,f&&(t.target&&(r=!1),s=!0)}}return i&&(r&&!t.target&&!e.hitArea&&e.containsPoint&&e.containsPoint(o)&&(s=!0),e.interactive&&(s&&!t.target&&(t.target=e),n&&n(t,e,!!s))),s},t.prototype.findHit=function(t,e,n,r){this.recursiveFindHit(t,e,n,r,!1)},t}(),$={interactive:!1,interactiveChildren:!0,hitArea:null,get buttonMode(){return"pointer"===this.cursor},set buttonMode(t){t?this.cursor="pointer":"pointer"===this.cursor&&(this.cursor=null)},cursor:null,get trackedPointers(){return void 0===this._trackedPointers&&(this._trackedPointers={}),this._trackedPointers},_trackedPointers:void 0};w.s$.mixin($);var q=1,K={target:null,data:{global:null}},Z=function(t){function e(e,n){var r=t.call(this)||this;return n=n||{},r.renderer=e,r.autoPreventDefault=void 0===n.autoPreventDefault||n.autoPreventDefault,r.interactionFrequency=n.interactionFrequency||10,r.mouse=new j,r.mouse.identifier=q,r.mouse.global.set(-999999),r.activeInteractionData={},r.activeInteractionData[q]=r.mouse,r.interactionDataPool=[],r.eventData=new Y,r.interactionDOMElement=null,r.moveWhenInside=!1,r.eventsAdded=!1,r.tickerAdded=!1,r.mouseOverRenderer=!("PointerEvent"in globalThis),r.supportsTouchEvents="ontouchstart"in globalThis,r.supportsPointerEvents=!!globalThis.PointerEvent,r.onPointerUp=r.onPointerUp.bind(r),r.processPointerUp=r.processPointerUp.bind(r),r.onPointerCancel=r.onPointerCancel.bind(r),r.processPointerCancel=r.processPointerCancel.bind(r),r.onPointerDown=r.onPointerDown.bind(r),r.processPointerDown=r.processPointerDown.bind(r),r.onPointerMove=r.onPointerMove.bind(r),r.processPointerMove=r.processPointerMove.bind(r),r.onPointerOut=r.onPointerOut.bind(r),r.processPointerOverOut=r.processPointerOverOut.bind(r),r.onPointerOver=r.onPointerOver.bind(r),r.cursorStyles={default:"inherit",pointer:"pointer"},r.currentCursorMode=null,r.cursor=null,r.resolution=1,r.delayedEvents=[],r.search=new z,r._tempDisplayObject=new w.Ql,r._eventListenerOptions={capture:!0,passive:!1},r._useSystemTicker=void 0===n.useSystemTicker||n.useSystemTicker,r.setTargetElement(r.renderer.view,r.renderer.resolution),r}return V(e,t),Object.defineProperty(e.prototype,"useSystemTicker",{get:function(){return this._useSystemTicker},set:function(t){this._useSystemTicker=t,t?this.addTickerListener():this.removeTickerListener()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastObjectRendered",{get:function(){return this.renderer._lastObjectRendered||this._tempDisplayObject},enumerable:!1,configurable:!0}),e.prototype.hitTest=function(t,e){return K.target=null,K.data.global=t,e||(e=this.lastObjectRendered),this.processInteractive(K,e,null,!0),K.target},e.prototype.setTargetElement=function(t,e){void 0===e&&(e=1),this.removeTickerListener(),this.removeEvents(),this.interactionDOMElement=t,this.resolution=e,this.addEvents(),this.addTickerListener()},e.prototype.addTickerListener=function(){!this.tickerAdded&&this.interactionDOMElement&&this._useSystemTicker&&(X.vB.system.add(this.tickerUpdate,this,X.uF.INTERACTION),this.tickerAdded=!0)},e.prototype.removeTickerListener=function(){this.tickerAdded&&(X.vB.system.remove(this.tickerUpdate,this),this.tickerAdded=!1)},e.prototype.addEvents=function(){if(!this.eventsAdded&&this.interactionDOMElement){var t=this.interactionDOMElement.style;globalThis.navigator.msPointerEnabled?(t.msContentZooming="none",t.msTouchAction="none"):this.supportsPointerEvents&&(t.touchAction="none"),this.supportsPointerEvents?(globalThis.document.addEventListener("pointermove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.addEventListener("pointerdown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.addEventListener("pointerleave",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.addEventListener("pointerover",this.onPointerOver,this._eventListenerOptions),globalThis.addEventListener("pointercancel",this.onPointerCancel,this._eventListenerOptions),globalThis.addEventListener("pointerup",this.onPointerUp,this._eventListenerOptions)):(globalThis.document.addEventListener("mousemove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.addEventListener("mousedown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.addEventListener("mouseout",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.addEventListener("mouseover",this.onPointerOver,this._eventListenerOptions),globalThis.addEventListener("mouseup",this.onPointerUp,this._eventListenerOptions)),this.supportsTouchEvents&&(this.interactionDOMElement.addEventListener("touchstart",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.addEventListener("touchcancel",this.onPointerCancel,this._eventListenerOptions),this.interactionDOMElement.addEventListener("touchend",this.onPointerUp,this._eventListenerOptions),this.interactionDOMElement.addEventListener("touchmove",this.onPointerMove,this._eventListenerOptions)),this.eventsAdded=!0}},e.prototype.removeEvents=function(){if(this.eventsAdded&&this.interactionDOMElement){var t=this.interactionDOMElement.style;globalThis.navigator.msPointerEnabled?(t.msContentZooming="",t.msTouchAction=""):this.supportsPointerEvents&&(t.touchAction=""),this.supportsPointerEvents?(globalThis.document.removeEventListener("pointermove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("pointerdown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("pointerleave",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("pointerover",this.onPointerOver,this._eventListenerOptions),globalThis.removeEventListener("pointercancel",this.onPointerCancel,this._eventListenerOptions),globalThis.removeEventListener("pointerup",this.onPointerUp,this._eventListenerOptions)):(globalThis.document.removeEventListener("mousemove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("mousedown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("mouseout",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("mouseover",this.onPointerOver,this._eventListenerOptions),globalThis.removeEventListener("mouseup",this.onPointerUp,this._eventListenerOptions)),this.supportsTouchEvents&&(this.interactionDOMElement.removeEventListener("touchstart",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("touchcancel",this.onPointerCancel,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("touchend",this.onPointerUp,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("touchmove",this.onPointerMove,this._eventListenerOptions)),this.interactionDOMElement=null,this.eventsAdded=!1}},e.prototype.tickerUpdate=function(t){this._deltaTime+=t,this._deltaTime<this.interactionFrequency||(this._deltaTime=0,this.update())},e.prototype.update=function(){if(this.interactionDOMElement)if(this._didMove)this._didMove=!1;else{for(var t in this.cursor=null,this.activeInteractionData)if(this.activeInteractionData.hasOwnProperty(t)){var e=this.activeInteractionData[t];if(e.originalEvent&&"touch"!==e.pointerType){var n=this.configureInteractionEventForDOMEvent(this.eventData,e.originalEvent,e);this.processInteractive(n,this.lastObjectRendered,this.processPointerOverOut,!0)}}this.setCursorMode(this.cursor)}},e.prototype.setCursorMode=function(t){t=t||"default";var e=!0;if(globalThis.OffscreenCanvas&&this.interactionDOMElement instanceof OffscreenCanvas&&(e=!1),this.currentCursorMode!==t){this.currentCursorMode=t;var n=this.cursorStyles[t];if(n)switch(typeof n){case"string":e&&(this.interactionDOMElement.style.cursor=n);break;case"function":n(t);break;case"object":e&&Object.assign(this.interactionDOMElement.style,n);break}else e&&"string"===typeof t&&!Object.prototype.hasOwnProperty.call(this.cursorStyles,t)&&(this.interactionDOMElement.style.cursor=t)}},e.prototype.dispatchEvent=function(t,e,n){n.stopPropagationHint&&t!==n.stopsPropagatingAt||(n.currentTarget=t,n.type=e,t.emit(e,n),t[e]&&t[e](n))},e.prototype.delayDispatchEvent=function(t,e,n){this.delayedEvents.push({displayObject:t,eventString:e,eventData:n})},e.prototype.mapPositionToPoint=function(t,e,n){var r;r=this.interactionDOMElement.parentElement?this.interactionDOMElement.getBoundingClientRect():{x:0,y:0,width:this.interactionDOMElement.width,height:this.interactionDOMElement.height,left:0,top:0};var i=1/this.resolution;t.x=(e-r.left)*(this.interactionDOMElement.width/r.width)*i,t.y=(n-r.top)*(this.interactionDOMElement.height/r.height)*i},e.prototype.processInteractive=function(t,e,n,r){var i=this.search.findHit(t,e,n,r),o=this.delayedEvents;if(!o.length)return i;t.stopPropagationHint=!1;var s=o.length;this.delayedEvents=[];for(var a=0;a<s;a++){var u=o[a],l=u.displayObject,c=u.eventString,h=u.eventData;h.stopsPropagatingAt===l&&(h.stopPropagationHint=!0),this.dispatchEvent(l,c,h)}return i},e.prototype.onPointerDown=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t);if(this.autoPreventDefault&&e[0].isNormalized){var n=t.cancelable||!("cancelable"in t);n&&t.preventDefault()}for(var r=e.length,i=0;i<r;i++){var o=e[i],s=this.getInteractionDataForPointerId(o),a=this.configureInteractionEventForDOMEvent(this.eventData,o,s);if(a.data.originalEvent=t,this.processInteractive(a,this.lastObjectRendered,this.processPointerDown,!0),this.emit("pointerdown",a),"touch"===o.pointerType)this.emit("touchstart",a);else if("mouse"===o.pointerType||"pen"===o.pointerType){var u=2===o.button;this.emit(u?"rightdown":"mousedown",this.eventData)}}}},e.prototype.processPointerDown=function(t,e,n){var r=t.data,i=t.data.identifier;if(n)if(e.trackedPointers[i]||(e.trackedPointers[i]=new W(i)),this.dispatchEvent(e,"pointerdown",t),"touch"===r.pointerType)this.dispatchEvent(e,"touchstart",t);else if("mouse"===r.pointerType||"pen"===r.pointerType){var o=2===r.button;o?e.trackedPointers[i].rightDown=!0:e.trackedPointers[i].leftDown=!0,this.dispatchEvent(e,o?"rightdown":"mousedown",t)}},e.prototype.onPointerComplete=function(t,e,n){for(var r=this.normalizeToPointerData(t),i=r.length,o=t.target!==this.interactionDOMElement?"outside":"",s=0;s<i;s++){var a=r[s],u=this.getInteractionDataForPointerId(a),l=this.configureInteractionEventForDOMEvent(this.eventData,a,u);if(l.data.originalEvent=t,this.processInteractive(l,this.lastObjectRendered,n,e||!o),this.emit(e?"pointercancel":"pointerup"+o,l),"mouse"===a.pointerType||"pen"===a.pointerType){var c=2===a.button;this.emit(c?"rightup"+o:"mouseup"+o,l)}else"touch"===a.pointerType&&(this.emit(e?"touchcancel":"touchend"+o,l),this.releaseInteractionDataForPointerId(a.pointerId))}},e.prototype.onPointerCancel=function(t){this.supportsTouchEvents&&"touch"===t.pointerType||this.onPointerComplete(t,!0,this.processPointerCancel)},e.prototype.processPointerCancel=function(t,e){var n=t.data,r=t.data.identifier;void 0!==e.trackedPointers[r]&&(delete e.trackedPointers[r],this.dispatchEvent(e,"pointercancel",t),"touch"===n.pointerType&&this.dispatchEvent(e,"touchcancel",t))},e.prototype.onPointerUp=function(t){this.supportsTouchEvents&&"touch"===t.pointerType||this.onPointerComplete(t,!1,this.processPointerUp)},e.prototype.processPointerUp=function(t,e,n){var r=t.data,i=t.data.identifier,o=e.trackedPointers[i],s="touch"===r.pointerType,a="mouse"===r.pointerType||"pen"===r.pointerType,u=!1;if(a){var l=2===r.button,c=W.FLAGS,h=l?c.RIGHT_DOWN:c.LEFT_DOWN,f=void 0!==o&&o.flags&h;n?(this.dispatchEvent(e,l?"rightup":"mouseup",t),f&&(this.dispatchEvent(e,l?"rightclick":"click",t),u=!0)):f&&this.dispatchEvent(e,l?"rightupoutside":"mouseupoutside",t),o&&(l?o.rightDown=!1:o.leftDown=!1)}n?(this.dispatchEvent(e,"pointerup",t),s&&this.dispatchEvent(e,"touchend",t),o&&(a&&!u||this.dispatchEvent(e,"pointertap",t),s&&(this.dispatchEvent(e,"tap",t),o.over=!1))):o&&(this.dispatchEvent(e,"pointerupoutside",t),s&&this.dispatchEvent(e,"touchendoutside",t)),o&&o.none&&delete e.trackedPointers[i]},e.prototype.onPointerMove=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t);"mouse"!==e[0].pointerType&&"pen"!==e[0].pointerType||(this._didMove=!0,this.cursor=null);for(var n=e.length,r=0;r<n;r++){var i=e[r],o=this.getInteractionDataForPointerId(i),s=this.configureInteractionEventForDOMEvent(this.eventData,i,o);s.data.originalEvent=t,this.processInteractive(s,this.lastObjectRendered,this.processPointerMove,!0),this.emit("pointermove",s),"touch"===i.pointerType&&this.emit("touchmove",s),"mouse"!==i.pointerType&&"pen"!==i.pointerType||this.emit("mousemove",s)}"mouse"===e[0].pointerType&&this.setCursorMode(this.cursor)}},e.prototype.processPointerMove=function(t,e,n){var r=t.data,i="touch"===r.pointerType,o="mouse"===r.pointerType||"pen"===r.pointerType;o&&this.processPointerOverOut(t,e,n),this.moveWhenInside&&!n||(this.dispatchEvent(e,"pointermove",t),i&&this.dispatchEvent(e,"touchmove",t),o&&this.dispatchEvent(e,"mousemove",t))},e.prototype.onPointerOut=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t),n=e[0];"mouse"===n.pointerType&&(this.mouseOverRenderer=!1,this.setCursorMode(null));var r=this.getInteractionDataForPointerId(n),i=this.configureInteractionEventForDOMEvent(this.eventData,n,r);i.data.originalEvent=n,this.processInteractive(i,this.lastObjectRendered,this.processPointerOverOut,!1),this.emit("pointerout",i),"mouse"===n.pointerType||"pen"===n.pointerType?this.emit("mouseout",i):this.releaseInteractionDataForPointerId(r.identifier)}},e.prototype.processPointerOverOut=function(t,e,n){var r=t.data,i=t.data.identifier,o="mouse"===r.pointerType||"pen"===r.pointerType,s=e.trackedPointers[i];n&&!s&&(s=e.trackedPointers[i]=new W(i)),void 0!==s&&(n&&this.mouseOverRenderer?(s.over||(s.over=!0,this.delayDispatchEvent(e,"pointerover",t),o&&this.delayDispatchEvent(e,"mouseover",t)),o&&null===this.cursor&&(this.cursor=e.cursor)):s.over&&(s.over=!1,this.dispatchEvent(e,"pointerout",this.eventData),o&&this.dispatchEvent(e,"mouseout",t),s.none&&delete e.trackedPointers[i]))},e.prototype.onPointerOver=function(t){var e=this.normalizeToPointerData(t),n=e[0],r=this.getInteractionDataForPointerId(n),i=this.configureInteractionEventForDOMEvent(this.eventData,n,r);i.data.originalEvent=n,"mouse"===n.pointerType&&(this.mouseOverRenderer=!0),this.emit("pointerover",i),"mouse"!==n.pointerType&&"pen"!==n.pointerType||this.emit("mouseover",i)},e.prototype.getInteractionDataForPointerId=function(t){var e,n=t.pointerId;return n===q||"mouse"===t.pointerType?e=this.mouse:this.activeInteractionData[n]?e=this.activeInteractionData[n]:(e=this.interactionDataPool.pop()||new j,e.identifier=n,this.activeInteractionData[n]=e),e.copyEvent(t),e},e.prototype.releaseInteractionDataForPointerId=function(t){var e=this.activeInteractionData[t];e&&(delete this.activeInteractionData[t],e.reset(),this.interactionDataPool.push(e))},e.prototype.configureInteractionEventForDOMEvent=function(t,e,n){return t.data=n,this.mapPositionToPoint(n.global,e.clientX,e.clientY),"touch"===e.pointerType&&(e.globalX=n.global.x,e.globalY=n.global.y),n.originalEvent=e,t.reset(),t},e.prototype.normalizeToPointerData=function(t){var e=[];if(this.supportsTouchEvents&&t instanceof TouchEvent)for(var n=0,r=t.changedTouches.length;n<r;n++){var i=t.changedTouches[n];"undefined"===typeof i.button&&(i.button=t.touches.length?1:0),"undefined"===typeof i.buttons&&(i.buttons=t.touches.length?1:0),"undefined"===typeof i.isPrimary&&(i.isPrimary=1===t.touches.length&&"touchstart"===t.type),"undefined"===typeof i.width&&(i.width=i.radiusX||1),"undefined"===typeof i.height&&(i.height=i.radiusY||1),"undefined"===typeof i.tiltX&&(i.tiltX=0),"undefined"===typeof i.tiltY&&(i.tiltY=0),"undefined"===typeof i.pointerType&&(i.pointerType="touch"),"undefined"===typeof i.pointerId&&(i.pointerId=i.identifier||0),"undefined"===typeof i.pressure&&(i.pressure=i.force||.5),"undefined"===typeof i.twist&&(i.twist=0),"undefined"===typeof i.tangentialPressure&&(i.tangentialPressure=0),"undefined"===typeof i.layerX&&(i.layerX=i.offsetX=i.clientX),"undefined"===typeof i.layerY&&(i.layerY=i.offsetY=i.clientY),i.isNormalized=!0,e.push(i)}else if(globalThis.MouseEvent&&(!(t instanceof MouseEvent)||this.supportsPointerEvents&&t instanceof globalThis.PointerEvent))e.push(t);else{var o=t;"undefined"===typeof o.isPrimary&&(o.isPrimary=!0),"undefined"===typeof o.width&&(o.width=1),"undefined"===typeof o.height&&(o.height=1),"undefined"===typeof o.tiltX&&(o.tiltX=0),"undefined"===typeof o.tiltY&&(o.tiltY=0),"undefined"===typeof o.pointerType&&(o.pointerType="mouse"),"undefined"===typeof o.pointerId&&(o.pointerId=q),"undefined"===typeof o.pressure&&(o.pressure=.5),"undefined"===typeof o.twist&&(o.twist=0),"undefined"===typeof o.tangentialPressure&&(o.tangentialPressure=0),o.isNormalized=!0,e.push(o)}return e},e.prototype.destroy=function(){this.removeEvents(),this.removeTickerListener(),this.removeAllListeners(),this.renderer=null,this.mouse=null,this.eventData=null,this.interactionDOMElement=null,this.onPointerDown=null,this.processPointerDown=null,this.onPointerUp=null,this.processPointerUp=null,this.onPointerCancel=null,this.processPointerCancel=null,this.onPointerMove=null,this.processPointerMove=null,this.onPointerOut=null,this.processPointerOverOut=null,this.onPointerOver=null,this.search=null},e}(O.vp),J=n(2038),Q=function(){function t(e){var n=this;this.stage=new w.W2,e=Object.assign({forceCanvas:!1},e),this.renderer=(0,J.e6)(e),t._plugins.forEach((function(t){t.init.call(n,e)}))}return t.registerPlugin=function(e){t._plugins.push(e)},t.prototype.render=function(){this.renderer.render(this.stage)},Object.defineProperty(t.prototype,"view",{get:function(){return this.renderer.view},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"screen",{get:function(){return this.renderer.screen},enumerable:!1,configurable:!0}),t.prototype.destroy=function(e,n){var r=this,i=t._plugins.slice(0);i.reverse(),i.forEach((function(t){t.destroy.call(r)})),this.stage.destroy(n),this.stage=null,this.renderer.destroy(e),this.renderer=null},t._plugins=[],t}(),tt=function(){function t(){}return t.init=function(t){var e=this;Object.defineProperty(this,"resizeTo",{set:function(t){globalThis.removeEventListener("resize",this.queueResize),this._resizeTo=t,t&&(globalThis.addEventListener("resize",this.queueResize),this.resize())},get:function(){return this._resizeTo}}),this.queueResize=function(){e._resizeTo&&(e.cancelResize(),e._resizeId=requestAnimationFrame((function(){return e.resize()})))},this.cancelResize=function(){e._resizeId&&(cancelAnimationFrame(e._resizeId),e._resizeId=null)},this.resize=function(){if(e._resizeTo){var t,n;if(e.cancelResize(),e._resizeTo===globalThis.window)t=globalThis.innerWidth,n=globalThis.innerHeight;else{var r=e._resizeTo,i=r.clientWidth,o=r.clientHeight;t=i,n=o}e.renderer.resize(t,n)}},this._resizeId=null,this._resizeTo=null,this.resizeTo=t.resizeTo||null},t.destroy=function(){globalThis.removeEventListener("resize",this.queueResize),this.cancelResize(),this.cancelResize=null,this.queueResize=null,this.resizeTo=null,this.resize=null},t}();Q.registerPlugin(tt); -/*! - * @pixi/extract - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/extract is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var et=new k.Ae,nt=4,rt=function(){function t(t){this.renderer=t}return t.prototype.image=function(t,e,n){var r=new Image;return r.src=this.base64(t,e,n),r},t.prototype.base64=function(t,e,n){return this.canvas(t).toDataURL(e,n)},t.prototype.canvas=function(e){var n,r,i,o=this.renderer,s=!1,a=!1;e&&(e instanceof J.TI?i=e:(i=this.renderer.generateTexture(e),a=!0)),i?(n=i.baseTexture.resolution,r=i.frame,s=!1,o.renderTexture.bind(i)):(n=this.renderer.resolution,s=!0,r=et,r.width=this.renderer.width,r.height=this.renderer.height,o.renderTexture.bind(null));var u=Math.floor(r.width*n+1e-4),l=Math.floor(r.height*n+1e-4),c=new O.qU(u,l,1),h=new Uint8Array(nt*u*l),f=o.gl;f.readPixels(r.x*n,r.y*n,u,l,f.RGBA,f.UNSIGNED_BYTE,h);var d=c.context.getImageData(0,0,u,l);if(t.arrayPostDivide(h,d.data),c.context.putImageData(d,0,0),s){var p=new O.qU(c.width,c.height,1);p.context.scale(1,-1),p.context.drawImage(c.canvas,0,-l),c.destroy(),c=p}return a&&i.destroy(!0),c.canvas},t.prototype.pixels=function(e){var n,r,i,o=this.renderer,s=!1;e&&(e instanceof J.TI?i=e:(i=this.renderer.generateTexture(e),s=!0)),i?(n=i.baseTexture.resolution,r=i.frame,o.renderTexture.bind(i)):(n=o.resolution,r=et,r.width=o.width,r.height=o.height,o.renderTexture.bind(null));var a=r.width*n,u=r.height*n,l=new Uint8Array(nt*a*u),c=o.gl;return c.readPixels(r.x*n,r.y*n,a,u,c.RGBA,c.UNSIGNED_BYTE,l),s&&i.destroy(!0),t.arrayPostDivide(l,l),l},t.prototype.destroy=function(){this.renderer=null},t.arrayPostDivide=function(t,e){for(var n=0;n<t.length;n+=4){var r=e[n+3]=t[n+3];0!==r?(e[n]=Math.round(Math.min(255*t[n]/r,255)),e[n+1]=Math.round(Math.min(255*t[n+1]/r,255)),e[n+2]=Math.round(Math.min(255*t[n+2]/r,255))):(e[n]=t[n],e[n+1]=t[n+1],e[n+2]=t[n+2])}},t}(),it=function(){function t(t,e,n){void 0===e&&(e=!1),this._fn=t,this._once=e,this._thisArg=n,this._next=this._prev=this._owner=null}return t.prototype.detach=function(){return null!==this._owner&&(this._owner.detach(this),!0)},t}();function ot(t,e){return t._head?(t._tail._next=e,e._prev=t._tail,t._tail=e):(t._head=e,t._tail=e),e._owner=t,e}var st=function(){function t(){this._head=this._tail=void 0}return t.prototype.handlers=function(t){void 0===t&&(t=!1);var e=this._head;if(t)return!!e;var n=[];while(e)n.push(e),e=e._next;return n},t.prototype.has=function(t){if(!(t instanceof it))throw new Error("MiniSignal#has(): First arg must be a SignalBinding object.");return t._owner===this},t.prototype.dispatch=function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];var r=this._head;if(!r)return!1;while(r)r._once&&this.detach(r),r._fn.apply(r._thisArg,e),r=r._next;return!0},t.prototype.add=function(t,e){if(void 0===e&&(e=null),"function"!==typeof t)throw new Error("MiniSignal#add(): First arg must be a Function.");return ot(this,new it(t,!1,e))},t.prototype.once=function(t,e){if(void 0===e&&(e=null),"function"!==typeof t)throw new Error("MiniSignal#once(): First arg must be a Function.");return ot(this,new it(t,!0,e))},t.prototype.detach=function(t){if(!(t instanceof it))throw new Error("MiniSignal#detach(): First arg must be a SignalBinding object.");return t._owner!==this||(t._prev&&(t._prev._next=t._next),t._next&&(t._next._prev=t._prev),t===this._head?(this._head=t._next,null===t._next&&(this._tail=null)):t===this._tail&&(this._tail=t._prev,this._tail._next=null),t._owner=null),this},t.prototype.detachAll=function(){var t=this._head;if(!t)return this;this._head=this._tail=null;while(t)t._owner=null,t=t._next;return this},t}();function at(t,e){e=e||{};var n={key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],q:{name:"queryKey",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}},r=n.parser[e.strictMode?"strict":"loose"].exec(t),i={},o=14;while(o--)i[n.key[o]]=r[o]||"";return i[n.q.name]={},i[n.key[12]].replace(n.q.parser,(function(t,e,r){e&&(i[n.q.name][e]=r)})),i}var ut=!(!globalThis.XDomainRequest||"withCredentials"in new XMLHttpRequest),lt=null,ct=0,ht=200,ft=204,dt=1223,pt=2;function vt(){}function mt(t,e,n){e&&0===e.indexOf(".")&&(e=e.substring(1)),e&&(t[e]=n)}function gt(t){return t.toString().replace("object ","")}var _t=function(){function t(e,n,r){if(this._dequeue=vt,this._onLoadBinding=null,this._elementTimer=0,this._boundComplete=null,this._boundOnError=null,this._boundOnProgress=null,this._boundOnTimeout=null,this._boundXhrOnError=null,this._boundXhrOnTimeout=null,this._boundXhrOnAbort=null,this._boundXhrOnLoad=null,"string"!==typeof e||"string"!==typeof n)throw new Error("Both name and url are required for constructing a resource.");r=r||{},this._flags=0,this._setFlag(t.STATUS_FLAGS.DATA_URL,0===n.indexOf("data:")),this.name=e,this.url=n,this.extension=this._getExtension(),this.data=null,this.crossOrigin=!0===r.crossOrigin?"anonymous":r.crossOrigin,this.timeout=r.timeout||0,this.loadType=r.loadType||this._determineLoadType(),this.xhrType=r.xhrType,this.metadata=r.metadata||{},this.error=null,this.xhr=null,this.children=[],this.type=t.TYPE.UNKNOWN,this.progressChunk=0,this._dequeue=vt,this._onLoadBinding=null,this._elementTimer=0,this._boundComplete=this.complete.bind(this),this._boundOnError=this._onError.bind(this),this._boundOnProgress=this._onProgress.bind(this),this._boundOnTimeout=this._onTimeout.bind(this),this._boundXhrOnError=this._xhrOnError.bind(this),this._boundXhrOnTimeout=this._xhrOnTimeout.bind(this),this._boundXhrOnAbort=this._xhrOnAbort.bind(this),this._boundXhrOnLoad=this._xhrOnLoad.bind(this),this.onStart=new st,this.onProgress=new st,this.onComplete=new st,this.onAfterMiddleware=new st}return t.setExtensionLoadType=function(e,n){mt(t._loadTypeMap,e,n)},t.setExtensionXhrType=function(e,n){mt(t._xhrTypeMap,e,n)},Object.defineProperty(t.prototype,"isDataUrl",{get:function(){return this._hasFlag(t.STATUS_FLAGS.DATA_URL)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isComplete",{get:function(){return this._hasFlag(t.STATUS_FLAGS.COMPLETE)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isLoading",{get:function(){return this._hasFlag(t.STATUS_FLAGS.LOADING)},enumerable:!1,configurable:!0}),t.prototype.complete=function(){this._clearEvents(),this._finish()},t.prototype.abort=function(e){if(!this.error){if(this.error=new Error(e),this._clearEvents(),this.xhr)this.xhr.abort();else if(this.xdr)this.xdr.abort();else if(this.data)if(this.data.src)this.data.src=t.EMPTY_GIF;else while(this.data.firstChild)this.data.removeChild(this.data.firstChild);this._finish()}},t.prototype.load=function(e){var n=this;if(!this.isLoading)if(this.isComplete)e&&setTimeout((function(){return e(n)}),1);else switch(e&&this.onComplete.once(e),this._setFlag(t.STATUS_FLAGS.LOADING,!0),this.onStart.dispatch(this),!1!==this.crossOrigin&&"string"===typeof this.crossOrigin||(this.crossOrigin=this._determineCrossOrigin(this.url)),this.loadType){case t.LOAD_TYPE.IMAGE:this.type=t.TYPE.IMAGE,this._loadElement("image");break;case t.LOAD_TYPE.AUDIO:this.type=t.TYPE.AUDIO,this._loadSourceElement("audio");break;case t.LOAD_TYPE.VIDEO:this.type=t.TYPE.VIDEO,this._loadSourceElement("video");break;case t.LOAD_TYPE.XHR:default:ut&&this.crossOrigin?this._loadXdr():this._loadXhr();break}},t.prototype._hasFlag=function(t){return 0!==(this._flags&t)},t.prototype._setFlag=function(t,e){this._flags=e?this._flags|t:this._flags&~t},t.prototype._clearEvents=function(){clearTimeout(this._elementTimer),this.data&&this.data.removeEventListener&&(this.data.removeEventListener("error",this._boundOnError,!1),this.data.removeEventListener("load",this._boundComplete,!1),this.data.removeEventListener("progress",this._boundOnProgress,!1),this.data.removeEventListener("canplaythrough",this._boundComplete,!1)),this.xhr&&(this.xhr.removeEventListener?(this.xhr.removeEventListener("error",this._boundXhrOnError,!1),this.xhr.removeEventListener("timeout",this._boundXhrOnTimeout,!1),this.xhr.removeEventListener("abort",this._boundXhrOnAbort,!1),this.xhr.removeEventListener("progress",this._boundOnProgress,!1),this.xhr.removeEventListener("load",this._boundXhrOnLoad,!1)):(this.xhr.onerror=null,this.xhr.ontimeout=null,this.xhr.onprogress=null,this.xhr.onload=null))},t.prototype._finish=function(){if(this.isComplete)throw new Error("Complete called again for an already completed resource.");this._setFlag(t.STATUS_FLAGS.COMPLETE,!0),this._setFlag(t.STATUS_FLAGS.LOADING,!1),this.onComplete.dispatch(this)},t.prototype._loadElement=function(t){this.metadata.loadElement?this.data=this.metadata.loadElement:"image"===t&&"undefined"!==typeof globalThis.Image?this.data=new Image:this.data=document.createElement(t),this.crossOrigin&&(this.data.crossOrigin=this.crossOrigin),this.metadata.skipSource||(this.data.src=this.url),this.data.addEventListener("error",this._boundOnError,!1),this.data.addEventListener("load",this._boundComplete,!1),this.data.addEventListener("progress",this._boundOnProgress,!1),this.timeout&&(this._elementTimer=setTimeout(this._boundOnTimeout,this.timeout))},t.prototype._loadSourceElement=function(t){if(this.metadata.loadElement?this.data=this.metadata.loadElement:"audio"===t&&"undefined"!==typeof globalThis.Audio?this.data=new Audio:this.data=document.createElement(t),null!==this.data){if(this.crossOrigin&&(this.data.crossOrigin=this.crossOrigin),!this.metadata.skipSource)if(navigator.isCocoonJS)this.data.src=Array.isArray(this.url)?this.url[0]:this.url;else if(Array.isArray(this.url))for(var e=this.metadata.mimeType,n=0;n<this.url.length;++n)this.data.appendChild(this._createSource(t,this.url[n],Array.isArray(e)?e[n]:e));else{e=this.metadata.mimeType;this.data.appendChild(this._createSource(t,this.url,Array.isArray(e)?e[0]:e))}this.data.addEventListener("error",this._boundOnError,!1),this.data.addEventListener("load",this._boundComplete,!1),this.data.addEventListener("progress",this._boundOnProgress,!1),this.data.addEventListener("canplaythrough",this._boundComplete,!1),this.data.load(),this.timeout&&(this._elementTimer=setTimeout(this._boundOnTimeout,this.timeout))}else this.abort("Unsupported element: "+t)},t.prototype._loadXhr=function(){"string"!==typeof this.xhrType&&(this.xhrType=this._determineXhrType());var e=this.xhr=new XMLHttpRequest;"use-credentials"===this.crossOrigin&&(e.withCredentials=!0),e.open("GET",this.url,!0),e.timeout=this.timeout,this.xhrType===t.XHR_RESPONSE_TYPE.JSON||this.xhrType===t.XHR_RESPONSE_TYPE.DOCUMENT?e.responseType=t.XHR_RESPONSE_TYPE.TEXT:e.responseType=this.xhrType,e.addEventListener("error",this._boundXhrOnError,!1),e.addEventListener("timeout",this._boundXhrOnTimeout,!1),e.addEventListener("abort",this._boundXhrOnAbort,!1),e.addEventListener("progress",this._boundOnProgress,!1),e.addEventListener("load",this._boundXhrOnLoad,!1),e.send()},t.prototype._loadXdr=function(){"string"!==typeof this.xhrType&&(this.xhrType=this._determineXhrType());var t=this.xhr=new globalThis.XDomainRequest;t.timeout=this.timeout||5e3,t.onerror=this._boundXhrOnError,t.ontimeout=this._boundXhrOnTimeout,t.onprogress=this._boundOnProgress,t.onload=this._boundXhrOnLoad,t.open("GET",this.url,!0),setTimeout((function(){return t.send()}),1)},t.prototype._createSource=function(t,e,n){n||(n=t+"/"+this._getExtension(e));var r=document.createElement("source");return r.src=e,r.type=n,r},t.prototype._onError=function(t){this.abort("Failed to load element using: "+t.target.nodeName)},t.prototype._onProgress=function(t){t&&t.lengthComputable&&this.onProgress.dispatch(this,t.loaded/t.total)},t.prototype._onTimeout=function(){this.abort("Load timed out.")},t.prototype._xhrOnError=function(){var t=this.xhr;this.abort(gt(t)+" Request failed. Status: "+t.status+', text: "'+t.statusText+'"')},t.prototype._xhrOnTimeout=function(){var t=this.xhr;this.abort(gt(t)+" Request timed out.")},t.prototype._xhrOnAbort=function(){var t=this.xhr;this.abort(gt(t)+" Request was aborted by the user.")},t.prototype._xhrOnLoad=function(){var e=this.xhr,n="",r="undefined"===typeof e.status?ht:e.status;""!==e.responseType&&"text"!==e.responseType&&"undefined"!==typeof e.responseType||(n=e.responseText),r===ct&&(n.length>0||e.responseType===t.XHR_RESPONSE_TYPE.BUFFER)?r=ht:r===dt&&(r=ft);var i=r/100|0;if(i===pt){if(this.xhrType===t.XHR_RESPONSE_TYPE.TEXT)this.data=n,this.type=t.TYPE.TEXT;else if(this.xhrType===t.XHR_RESPONSE_TYPE.JSON)try{this.data=JSON.parse(n),this.type=t.TYPE.JSON}catch(a){return void this.abort("Error trying to parse loaded json: "+a)}else if(this.xhrType===t.XHR_RESPONSE_TYPE.DOCUMENT)try{if(globalThis.DOMParser){var o=new DOMParser;this.data=o.parseFromString(n,"text/xml")}else{var s=document.createElement("div");s.innerHTML=n,this.data=s}this.type=t.TYPE.XML}catch(u){return void this.abort("Error trying to parse loaded xml: "+u)}else this.data=e.response||n;this.complete()}else this.abort("["+e.status+"] "+e.statusText+": "+e.responseURL)},t.prototype._determineCrossOrigin=function(t,e){if(0===t.indexOf("data:"))return"";if(globalThis.origin!==globalThis.location.origin)return"anonymous";e=e||globalThis.location,lt||(lt=document.createElement("a")),lt.href=t;var n=at(lt.href,{strictMode:!0}),r=!n.port&&""===e.port||n.port===e.port,i=n.protocol?n.protocol+":":"";return n.host===e.hostname&&r&&i===e.protocol?"":"anonymous"},t.prototype._determineXhrType=function(){return t._xhrTypeMap[this.extension]||t.XHR_RESPONSE_TYPE.TEXT},t.prototype._determineLoadType=function(){return t._loadTypeMap[this.extension]||t.LOAD_TYPE.XHR},t.prototype._getExtension=function(t){void 0===t&&(t=this.url);var e="";if(this.isDataUrl){var n=t.indexOf("/");e=t.substring(n+1,t.indexOf(";",n))}else{var r=t.indexOf("?"),i=t.indexOf("#"),o=Math.min(r>-1?r:t.length,i>-1?i:t.length);t=t.substring(0,o),e=t.substring(t.lastIndexOf(".")+1)}return e.toLowerCase()},t.prototype._getMimeFromXhrType=function(e){switch(e){case t.XHR_RESPONSE_TYPE.BUFFER:return"application/octet-binary";case t.XHR_RESPONSE_TYPE.BLOB:return"application/blob";case t.XHR_RESPONSE_TYPE.DOCUMENT:return"application/xml";case t.XHR_RESPONSE_TYPE.JSON:return"application/json";case t.XHR_RESPONSE_TYPE.DEFAULT:case t.XHR_RESPONSE_TYPE.TEXT:default:return"text/plain"}},t}();function yt(){}function bt(t){return function(){for(var e=arguments,n=[],r=0;r<arguments.length;r++)n[r]=e[r];if(null===t)throw new Error("Callback was already called.");var i=t;t=null,i.apply(this,n)}}(function(t){(function(t){t[t["NONE"]=0]="NONE",t[t["DATA_URL"]=1]="DATA_URL",t[t["COMPLETE"]=2]="COMPLETE",t[t["LOADING"]=4]="LOADING"})(t.STATUS_FLAGS||(t.STATUS_FLAGS={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["JSON"]=1]="JSON",t[t["XML"]=2]="XML",t[t["IMAGE"]=3]="IMAGE",t[t["AUDIO"]=4]="AUDIO",t[t["VIDEO"]=5]="VIDEO",t[t["TEXT"]=6]="TEXT"}(t.TYPE||(t.TYPE={})),function(t){t[t["XHR"]=1]="XHR",t[t["IMAGE"]=2]="IMAGE",t[t["AUDIO"]=3]="AUDIO",t[t["VIDEO"]=4]="VIDEO"}(t.LOAD_TYPE||(t.LOAD_TYPE={})),function(t){t["DEFAULT"]="text",t["BUFFER"]="arraybuffer",t["BLOB"]="blob",t["DOCUMENT"]="document",t["JSON"]="json",t["TEXT"]="text"}(t.XHR_RESPONSE_TYPE||(t.XHR_RESPONSE_TYPE={})),t._loadTypeMap={gif:t.LOAD_TYPE.IMAGE,png:t.LOAD_TYPE.IMAGE,bmp:t.LOAD_TYPE.IMAGE,jpg:t.LOAD_TYPE.IMAGE,jpeg:t.LOAD_TYPE.IMAGE,tif:t.LOAD_TYPE.IMAGE,tiff:t.LOAD_TYPE.IMAGE,webp:t.LOAD_TYPE.IMAGE,tga:t.LOAD_TYPE.IMAGE,svg:t.LOAD_TYPE.IMAGE,"svg+xml":t.LOAD_TYPE.IMAGE,mp3:t.LOAD_TYPE.AUDIO,ogg:t.LOAD_TYPE.AUDIO,wav:t.LOAD_TYPE.AUDIO,mp4:t.LOAD_TYPE.VIDEO,webm:t.LOAD_TYPE.VIDEO},t._xhrTypeMap={xhtml:t.XHR_RESPONSE_TYPE.DOCUMENT,html:t.XHR_RESPONSE_TYPE.DOCUMENT,htm:t.XHR_RESPONSE_TYPE.DOCUMENT,xml:t.XHR_RESPONSE_TYPE.DOCUMENT,tmx:t.XHR_RESPONSE_TYPE.DOCUMENT,svg:t.XHR_RESPONSE_TYPE.DOCUMENT,tsx:t.XHR_RESPONSE_TYPE.DOCUMENT,gif:t.XHR_RESPONSE_TYPE.BLOB,png:t.XHR_RESPONSE_TYPE.BLOB,bmp:t.XHR_RESPONSE_TYPE.BLOB,jpg:t.XHR_RESPONSE_TYPE.BLOB,jpeg:t.XHR_RESPONSE_TYPE.BLOB,tif:t.XHR_RESPONSE_TYPE.BLOB,tiff:t.XHR_RESPONSE_TYPE.BLOB,webp:t.XHR_RESPONSE_TYPE.BLOB,tga:t.XHR_RESPONSE_TYPE.BLOB,json:t.XHR_RESPONSE_TYPE.JSON,text:t.XHR_RESPONSE_TYPE.TEXT,txt:t.XHR_RESPONSE_TYPE.TEXT,ttf:t.XHR_RESPONSE_TYPE.BUFFER,otf:t.XHR_RESPONSE_TYPE.BUFFER},t.EMPTY_GIF="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=="})(_t||(_t={}));var Et=function(){function t(t,e){this.data=t,this.callback=e}return t}(),xt=function(){function t(t,e){var n=this;if(void 0===e&&(e=1),this.workers=0,this.saturated=yt,this.unsaturated=yt,this.empty=yt,this.drain=yt,this.error=yt,this.started=!1,this.paused=!1,this._tasks=[],this._insert=function(t,e,r){if(r&&"function"!==typeof r)throw new Error("task callback must be a function");if(n.started=!0,null==t&&n.idle())setTimeout((function(){return n.drain()}),1);else{var i=new Et(t,"function"===typeof r?r:yt);e?n._tasks.unshift(i):n._tasks.push(i),setTimeout(n.process,1)}},this.process=function(){while(!n.paused&&n.workers<n.concurrency&&n._tasks.length){var t=n._tasks.shift();0===n._tasks.length&&n.empty(),n.workers+=1,n.workers===n.concurrency&&n.saturated(),n._worker(t.data,bt(n._next(t)))}},this._worker=t,0===e)throw new Error("Concurrency must not be zero");this.concurrency=e,this.buffer=e/4}return t.prototype._next=function(t){var e=this;return function(){for(var n=arguments,r=[],i=0;i<arguments.length;i++)r[i]=n[i];e.workers-=1,t.callback.apply(t,r),null!=r[0]&&e.error(r[0],t.data),e.workers<=e.concurrency-e.buffer&&e.unsaturated(),e.idle()&&e.drain(),e.process()}},t.prototype.push=function(t,e){this._insert(t,!1,e)},t.prototype.kill=function(){this.workers=0,this.drain=yt,this.started=!1,this._tasks=[]},t.prototype.unshift=function(t,e){this._insert(t,!0,e)},t.prototype.length=function(){return this._tasks.length},t.prototype.running=function(){return this.workers},t.prototype.idle=function(){return this._tasks.length+this.workers===0},t.prototype.pause=function(){!0!==this.paused&&(this.paused=!0)},t.prototype.resume=function(){if(!1!==this.paused){this.paused=!1;for(var t=1;t<=this.concurrency;t++)this.process()}},t.eachSeries=function(t,e,n,r){var i=0,o=t.length;function s(a){a||i===o?n&&n(a):r?setTimeout((function(){e(t[i++],s)}),1):e(t[i++],s)}s()},t.queue=function(e,n){return new t(e,n)},t}(),Tt=100,St=/(#[\w-]+)?$/,Rt=function(){function t(e,n){var r=this;void 0===e&&(e=""),void 0===n&&(n=10),this.progress=0,this.loading=!1,this.defaultQueryString="",this._beforeMiddleware=[],this._afterMiddleware=[],this._resourcesParsing=[],this._boundLoadResource=function(t,e){return r._loadResource(t,e)},this.resources={},this.baseUrl=e,this._beforeMiddleware=[],this._afterMiddleware=[],this._resourcesParsing=[],this._boundLoadResource=function(t,e){return r._loadResource(t,e)},this._queue=xt.queue(this._boundLoadResource,n),this._queue.pause(),this.resources={},this.onProgress=new st,this.onError=new st,this.onLoad=new st,this.onStart=new st,this.onComplete=new st;for(var i=0;i<t._plugins.length;++i){var o=t._plugins[i],s=o.pre,a=o.use;s&&this.pre(s),a&&this.use(a)}this._protected=!1}return t.prototype._add=function(t,e,n,r){if(this.loading&&(!n||!n.parentResource))throw new Error("Cannot add resources while the loader is running.");if(this.resources[t])throw new Error('Resource named "'+t+'" already exists.');if(e=this._prepareUrl(e),this.resources[t]=new _t(t,e,n),"function"===typeof r&&this.resources[t].onAfterMiddleware.once(r),this.loading){for(var i=n.parentResource,o=[],s=0;s<i.children.length;++s)i.children[s].isComplete||o.push(i.children[s]);var a=i.progressChunk*(o.length+1),u=a/(o.length+2);i.children.push(this.resources[t]),i.progressChunk=u;for(s=0;s<o.length;++s)o[s].progressChunk=u;this.resources[t].progressChunk=u}return this._queue.push(this.resources[t]),this},t.prototype.pre=function(t){return this._beforeMiddleware.push(t),this},t.prototype.use=function(t){return this._afterMiddleware.push(t),this},t.prototype.reset=function(){for(var t in this.progress=0,this.loading=!1,this._queue.kill(),this._queue.pause(),this.resources){var e=this.resources[t];e._onLoadBinding&&e._onLoadBinding.detach(),e.isLoading&&e.abort("loader reset")}return this.resources={},this},t.prototype.load=function(t){if("function"===typeof t&&this.onComplete.once(t),this.loading)return this;if(this._queue.idle())this._onStart(),this._onComplete();else{for(var e=this._queue._tasks.length,n=Tt/e,r=0;r<this._queue._tasks.length;++r)this._queue._tasks[r].data.progressChunk=n;this._onStart(),this._queue.resume()}return this},Object.defineProperty(t.prototype,"concurrency",{get:function(){return this._queue.concurrency},set:function(t){this._queue.concurrency=t},enumerable:!1,configurable:!0}),t.prototype._prepareUrl=function(t){var e,n=at(t,{strictMode:!0});if(e=n.protocol||!n.path||0===t.indexOf("//")?t:this.baseUrl.length&&this.baseUrl.lastIndexOf("/")!==this.baseUrl.length-1&&"/"!==t.charAt(0)?this.baseUrl+"/"+t:this.baseUrl+t,this.defaultQueryString){var r=St.exec(e)[0];e=e.slice(0,e.length-r.length),-1!==e.indexOf("?")?e+="&"+this.defaultQueryString:e+="?"+this.defaultQueryString,e+=r}return e},t.prototype._loadResource=function(t,e){var n=this;t._dequeue=e,xt.eachSeries(this._beforeMiddleware,(function(e,r){e.call(n,t,(function(){r(t.isComplete?{}:null)}))}),(function(){t.isComplete?n._onLoad(t):(t._onLoadBinding=t.onComplete.once(n._onLoad,n),t.load())}),!0)},t.prototype._onStart=function(){this.progress=0,this.loading=!0,this.onStart.dispatch(this)},t.prototype._onComplete=function(){this.progress=Tt,this.loading=!1,this.onComplete.dispatch(this,this.resources)},t.prototype._onLoad=function(t){var e=this;t._onLoadBinding=null,this._resourcesParsing.push(t),t._dequeue(),xt.eachSeries(this._afterMiddleware,(function(n,r){n.call(e,t,r)}),(function(){t.onAfterMiddleware.dispatch(t),e.progress=Math.min(Tt,e.progress+t.progressChunk),e.onProgress.dispatch(e,t),t.error?e.onError.dispatch(t.error,e,t):e.onLoad.dispatch(e,t),e._resourcesParsing.splice(e._resourcesParsing.indexOf(t),1),e._queue.idle()&&0===e._resourcesParsing.length&&e._onComplete()}),!0)},t.prototype.destroy=function(){this._protected||this.reset()},Object.defineProperty(t,"shared",{get:function(){var e=t._shared;return e||(e=new t,e._protected=!0,t._shared=e),e},enumerable:!1,configurable:!0}),t.registerPlugin=function(e){return t._plugins.push(e),e.add&&e.add(),t},t._plugins=[],t}();Rt.prototype.add=function(t,e,n,r){if(Array.isArray(t)){for(var i=0;i<t.length;++i)this.add(t[i]);return this}if("object"===typeof t&&(n=t,r=e||n.callback||n.onComplete,e=n.url,t=n.name||n.key||n.url),"string"!==typeof e&&(r=n,n=e,e=t),"string"!==typeof e)throw new Error("No url passed to add resource to loader.");return"function"===typeof n&&(r=n,n=null),this._add(t,e,n,r)};var At=function(){function t(){}return t.init=function(t){t=Object.assign({sharedLoader:!1},t),this.loader=t.sharedLoader?Rt.shared:new Rt},t.destroy=function(){this.loader&&(this.loader.destroy(),this.loader=null)},t}(),Ot=function(){function t(){}return t.add=function(){_t.setExtensionLoadType("svg",_t.LOAD_TYPE.XHR),_t.setExtensionXhrType("svg",_t.XHR_RESPONSE_TYPE.TEXT)},t.use=function(t,e){if(!t.data||t.type!==_t.TYPE.IMAGE&&"svg"!==t.extension)e();else{var n=t.data,r=t.url,i=t.name,o=t.metadata;J.xE.fromLoader(n,r,i,o).then((function(n){t.texture=n,e()})).catch(e)}},t}(),wt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function It(t){var e="",n=0;while(n<t.length){for(var r=[0,0,0],i=[0,0,0,0],o=0;o<r.length;++o)n<t.length?r[o]=255&t.charCodeAt(n++):r[o]=0;i[0]=r[0]>>2,i[1]=(3&r[0])<<4|r[1]>>4,i[2]=(15&r[1])<<2|r[2]>>6,i[3]=63&r[2];var s=n-(t.length-1);switch(s){case 2:i[3]=64,i[2]=64;break;case 1:i[3]=64;break}for(o=0;o<i.length;++o)e+=wt.charAt(i[o])}return e}var Pt=self.URL||self.webkitURL;function Ct(t,e){if(t.data){if(t.xhr&&t.xhrType===_t.XHR_RESPONSE_TYPE.BLOB)if(self.Blob&&"string"!==typeof t.data){if(0===t.data.type.indexOf("image")){var n=Pt.createObjectURL(t.data);return t.blob=t.data,t.data=new Image,t.data.src=n,t.type=_t.TYPE.IMAGE,void(t.data.onload=function(){Pt.revokeObjectURL(n),t.data.onload=null,e()})}}else{var r=t.xhr.getResponseHeader("content-type");if(r&&0===r.indexOf("image"))return t.data=new Image,t.data.src="data:"+r+";base64,"+It(t.xhr.responseText),t.type=_t.TYPE.IMAGE,void(t.data.onload=function(){t.data.onload=null,e()})}e()}else e()}Rt.registerPlugin({use:Ct}),Rt.registerPlugin(Ot);var Nt,Mt,Dt=n(1680);(function(t){t[t["COMPRESSED_RGB_S3TC_DXT1_EXT"]=33776]="COMPRESSED_RGB_S3TC_DXT1_EXT",t[t["COMPRESSED_RGBA_S3TC_DXT1_EXT"]=33777]="COMPRESSED_RGBA_S3TC_DXT1_EXT",t[t["COMPRESSED_RGBA_S3TC_DXT3_EXT"]=33778]="COMPRESSED_RGBA_S3TC_DXT3_EXT",t[t["COMPRESSED_RGBA_S3TC_DXT5_EXT"]=33779]="COMPRESSED_RGBA_S3TC_DXT5_EXT",t[t["COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT"]=35917]="COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT",t[t["COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT"]=35918]="COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT",t[t["COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT"]=35919]="COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT",t[t["COMPRESSED_SRGB_S3TC_DXT1_EXT"]=35916]="COMPRESSED_SRGB_S3TC_DXT1_EXT",t[t["COMPRESSED_R11_EAC"]=37488]="COMPRESSED_R11_EAC",t[t["COMPRESSED_SIGNED_R11_EAC"]=37489]="COMPRESSED_SIGNED_R11_EAC",t[t["COMPRESSED_RG11_EAC"]=37490]="COMPRESSED_RG11_EAC",t[t["COMPRESSED_SIGNED_RG11_EAC"]=37491]="COMPRESSED_SIGNED_RG11_EAC",t[t["COMPRESSED_RGB8_ETC2"]=37492]="COMPRESSED_RGB8_ETC2",t[t["COMPRESSED_RGBA8_ETC2_EAC"]=37496]="COMPRESSED_RGBA8_ETC2_EAC",t[t["COMPRESSED_SRGB8_ETC2"]=37493]="COMPRESSED_SRGB8_ETC2",t[t["COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"]=37497]="COMPRESSED_SRGB8_ALPHA8_ETC2_EAC",t[t["COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"]=37494]="COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2",t[t["COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"]=37495]="COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2",t[t["COMPRESSED_RGB_PVRTC_4BPPV1_IMG"]=35840]="COMPRESSED_RGB_PVRTC_4BPPV1_IMG",t[t["COMPRESSED_RGBA_PVRTC_4BPPV1_IMG"]=35842]="COMPRESSED_RGBA_PVRTC_4BPPV1_IMG",t[t["COMPRESSED_RGB_PVRTC_2BPPV1_IMG"]=35841]="COMPRESSED_RGB_PVRTC_2BPPV1_IMG",t[t["COMPRESSED_RGBA_PVRTC_2BPPV1_IMG"]=35843]="COMPRESSED_RGBA_PVRTC_2BPPV1_IMG",t[t["COMPRESSED_RGB_ETC1_WEBGL"]=36196]="COMPRESSED_RGB_ETC1_WEBGL",t[t["COMPRESSED_RGB_ATC_WEBGL"]=35986]="COMPRESSED_RGB_ATC_WEBGL",t[t["COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL"]=35986]="COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL",t[t["COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL"]=34798]="COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL"})(Mt||(Mt={}));var Lt=(Nt={},Nt[Mt.COMPRESSED_RGB_S3TC_DXT1_EXT]=.5,Nt[M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__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Ft(t,e)}; -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */function Bt(t,e){function n(){this.constructor=t}Ft(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function Ut(t,e,n,r){return new(n||(n=Promise))((function(i,o){function s(t){try{u(r.next(t))}catch(e){o(e)}}function a(t){try{u(r["throw"](t))}catch(e){o(e)}}function u(t){t.done?i(t.value):new n((function(e){e(t.value)})).then(s,a)}u((r=r.apply(t,e||[])).next())}))}function Gt(t,e){var n,r,i,o,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"===typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(t){return function(e){return u([t,e])}}function u(o){if(n)throw new TypeError("Generator is already executing.");while(s)try{if(n=1,r&&(i=2&o[0]?r["return"]:o[0]?r["throw"]||((i=r["return"])&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,r=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(i=s.trys,!(i=i.length>0&&i[i.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){s.label=o[1];break}if(6===o[0]&&s.label<i[1]){s.label=i[1],i=o;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(o);break}i[2]&&s.ops.pop(),s.trys.pop();continue}o=e.call(t,s)}catch(a){o=[6,a],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}}var kt,Xt,jt=function(t){function e(e,n){void 0===n&&(n={width:1,height:1,autoLoad:!0});var r,i,o=this;return"string"===typeof e?(r=e,i=new Uint8Array):(r=null,i=e),o=t.call(this,i,n)||this,o.origin=r,o.buffer=i?new J.Rv(i):null,o.origin&&!1!==n.autoLoad&&o.load(),i&&i.length&&(o.loaded=!0,o.onBlobLoaded(o.buffer.rawBinaryData)),o}return Bt(e,t),e.prototype.onBlobLoaded=function(t){},e.prototype.load=function(){return Ut(this,void 0,Promise,(function(){var t,e,n;return Gt(this,(function(r){switch(r.label){case 0:return[4,fetch(this.origin)];case 1:return t=r.sent(),[4,t.blob()];case 2:return e=r.sent(),[4,e.arrayBuffer()];case 3:return n=r.sent(),this.data=new Uint32Array(n),this.buffer=new J.Rv(n),this.loaded=!0,this.onBlobLoaded(n),this.update(),[2,this]}}))}))},e}(J.qm),Ht=function(t){function e(n,r){var i=t.call(this,n,r)||this;return i.format=r.format,i.levels=r.levels||1,i._width=r.width,i._height=r.height,i._extension=e._formatToExtension(i.format),(r.levelBuffers||i.buffer)&&(i._levelBuffers=r.levelBuffers||e._createLevelBuffers(n instanceof Uint8Array?n:i.buffer.uint8View,i.format,i.levels,4,4,i.width,i.height)),i}return Bt(e,t),e.prototype.upload=function(t,e,n){var r=t.gl,i=t.context.extensions[this._extension];if(!i)throw new Error(this._extension+" textures are not supported on the current machine");if(!this._levelBuffers)return!1;for(var o=0,s=this.levels;o<s;o++){var a=this._levelBuffers[o],u=a.levelID,l=a.levelWidth,c=a.levelHeight,h=a.levelBuffer;r.compressedTexImage2D(r.TEXTURE_2D,u,this.format,l,c,0,h)}return!0},e.prototype.onBlobLoaded=function(){this._levelBuffers=e._createLevelBuffers(this.buffer.uint8View,this.format,this.levels,4,4,this.width,this.height)},e._formatToExtension=function(t){if(t>=33776&&t<=33779)return"s3tc";if(t>=37488&&t<=37497)return"etc";if(t>=35840&&t<=35843)return"pvrtc";if(t>=36196)return"etc1";if(t>=35986&&t<=34798)return"atc";throw new Error("Invalid (compressed) texture format given!")},e._createLevelBuffers=function(t,e,n,r,i,o,s){for(var a=new Array(n),u=t.byteOffset,l=o,c=s,h=l+r-1&~(r-1),f=c+i-1&~(i-1),d=h*f*Lt[e],p=0;p<n;p++)a[p]={levelID:p,levelWidth:n>1?l:h,levelHeight:n>1?c:f,levelBuffer:new Uint8Array(t.buffer,u,d)},u+=d,l=l>>1||1,c=c>>1||1,h=l+r-1&~(r-1),f=c+i-1&~(i-1),d=h*f*Lt[e];return a},e}(jt),Vt=function(){function t(){}return t.use=function(e,n){var r=e.data,i=this;if(e.type===_t.TYPE.JSON&&r&&r.cacheID&&r.textures){for(var o=r.textures,s=void 0,a=void 0,u=0,l=o.length;u<l;u++){var c=o[u],h=c.src,f=c.format;if(f||(a=h),t.textureFormats[f]){s=h;break}}if(s=s||a,!s)return void n(new Error("Cannot load compressed-textures in "+e.url+", make sure you provide a fallback"));if(s===e.url)return void n(new Error("URL of compressed texture cannot be the same as the manifest's URL"));var d={crossOrigin:e.crossOrigin,metadata:e.metadata.imageMetadata,parentResource:e},p=O.HQ.resolve(e.url.replace(i.baseUrl,""),s),v=r.cacheID;i.add(v,p,d,(function(t){if(t.error)n(t.error);else{var r=t.texture,i=void 0===r?null:r,o=t.textures,s=void 0===o?{}:o;Object.assign(e,{texture:i,textures:s}),n()}}))}else n()},t.add=function(){var e=document.createElement("canvas"),n=e.getContext("webgl");if(n){var r={s3tc:n.getExtension("WEBGL_compressed_texture_s3tc"),s3tc_sRGB:n.getExtension("WEBGL_compressed_texture_s3tc_srgb"),etc:n.getExtension("WEBGL_compressed_texture_etc"),etc1:n.getExtension("WEBGL_compressed_texture_etc1"),pvrtc:n.getExtension("WEBGL_compressed_texture_pvrtc")||n.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc"),atc:n.getExtension("WEBGL_compressed_texture_atc"),astc:n.getExtension("WEBGL_compressed_texture_astc")};for(var i in t.textureExtensions=r,t.textureFormats={},r){var o=r[i];o&&Object.assign(t.textureFormats,Object.getPrototypeOf(o))}}else console.warn("WebGL not available for compressed textures. Silently failing.")},t}();function Yt(t,e,n){var r={textures:{},texture:null};if(!e)return r;var i=e.map((function(t){return new J.xE(new J.VL(t,Object.assign({mipmap:Dt.WB.OFF,alphaMode:Dt.iw.NO_PREMULTIPLIED_ALPHA},n)))}));return i.forEach((function(e,n){var i=e.baseTexture,o=t+"-"+(n+1);J.VL.addToCache(i,o),J.xE.addToCache(e,o),0===n&&(J.VL.addToCache(i,t),J.xE.addToCache(e,t),r.texture=e),r.textures[o]=e})),r}_t.setExtensionXhrType("dds",_t.XHR_RESPONSE_TYPE.BUFFER);var Wt,zt,$t=4,qt=124,Kt=32,Zt=20,Jt=542327876,Qt={SIZE:1,FLAGS:2,HEIGHT:3,WIDTH:4,MIPMAP_COUNT:7,PIXEL_FORMAT:19},te={SIZE:0,FLAGS:1,FOURCC:2,RGB_BITCOUNT:3,R_BIT_MASK:4,G_BIT_MASK:5,B_BIT_MASK:6,A_BIT_MASK:7},ee={DXGI_FORMAT:0,RESOURCE_DIMENSION:1,MISC_FLAG:2,ARRAY_SIZE:3,MISC_FLAGS2:4};(function(t){t[t["DXGI_FORMAT_UNKNOWN"]=0]="DXGI_FORMAT_UNKNOWN",t[t["DXGI_FORMAT_R32G32B32A32_TYPELESS"]=1]="DXGI_FORMAT_R32G32B32A32_TYPELESS",t[t["DXGI_FORMAT_R32G32B32A32_FLOAT"]=2]="DXGI_FORMAT_R32G32B32A32_FLOAT",t[t["DXGI_FORMAT_R32G32B32A32_UINT"]=3]="DXGI_FORMAT_R32G32B32A32_UINT",t[t["DXGI_FORMAT_R32G32B32A32_SINT"]=4]="DXGI_FORMAT_R32G32B32A32_SINT",t[t["DXGI_FORMAT_R32G32B32_TYPELESS"]=5]="DXGI_FORMAT_R32G32B32_TYPELESS",t[t["DXGI_FORMAT_R32G32B32_FLOAT"]=6]="DXGI_FORMAT_R32G32B32_FLOAT",t[t["DXGI_FORMAT_R32G32B32_UINT"]=7]="DXGI_FORMAT_R32G32B32_UINT",t[t["DXGI_FORMAT_R32G32B32_SINT"]=8]="DXGI_FORMAT_R32G32B32_SINT",t[t["DXGI_FORMAT_R16G16B16A16_TYPELESS"]=9]="DXGI_FORMAT_R16G16B16A16_TYPELESS",t[t["DXGI_FORMAT_R16G16B16A16_FLOAT"]=10]="DXGI_FORMAT_R16G16B16A16_FLOAT",t[t["DXGI_FORMAT_R16G16B16A16_UNORM"]=11]="DXGI_FORMAT_R16G16B16A16_UNORM",t[t["DXGI_FORMAT_R16G16B16A16_UINT"]=12]="DXGI_FORMAT_R16G16B16A16_UINT",t[t["DXGI_FORMAT_R16G16B16A16_SNORM"]=13]="DXGI_FORMAT_R16G16B16A16_SNORM",t[t["DXGI_FORMAT_R16G16B16A16_SINT"]=14]="DXGI_FORMAT_R16G16B16A16_SINT",t[t["DXGI_FORMAT_R32G32_TYPELESS"]=15]="DXGI_FORMAT_R32G32_TYPELESS",t[t["DXGI_FORMAT_R32G32_FLOAT"]=16]="DXGI_FORMAT_R32G32_FLOAT",t[t["DXGI_FORMAT_R32G32_UINT"]=17]="DXGI_FORMAT_R32G32_UINT",t[t["DXGI_FORMAT_R32G32_SINT"]=18]="DXGI_FORMAT_R32G32_SINT",t[t["DXGI_FORMAT_R32G8X24_TYPELESS"]=19]="DXGI_FORMAT_R32G8X24_TYPELESS",t[t["DXGI_FORMAT_D32_FLOAT_S8X24_UINT"]=20]="DXGI_FORMAT_D32_FLOAT_S8X24_UINT",t[t["DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS"]=21]="DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS",t[t["DXGI_FORMAT_X32_TYPELESS_G8X24_UINT"]=22]="DXGI_FORMAT_X32_TYPELESS_G8X24_UINT",t[t["DXGI_FORMAT_R10G10B10A2_TYPELESS"]=23]="DXGI_FORMAT_R10G10B10A2_TYPELESS",t[t["DXGI_FORMAT_R10G10B10A2_UNORM"]=24]="DXGI_FORMAT_R10G10B10A2_UNORM",t[t["DXGI_FORMAT_R10G10B10A2_UINT"]=25]="DXGI_FORMAT_R10G10B10A2_UINT",t[t["DXGI_FORMAT_R11G11B10_FLOAT"]=26]="DXGI_FORMAT_R11G11B10_FLOAT",t[t["DXGI_FORMAT_R8G8B8A8_TYPELESS"]=27]="DXGI_FORMAT_R8G8B8A8_TYPELESS",t[t["DXGI_FORMAT_R8G8B8A8_UNORM"]=28]="DXGI_FORMAT_R8G8B8A8_UNORM",t[t["DXGI_FORMAT_R8G8B8A8_UNORM_SRGB"]=29]="DXGI_FORMAT_R8G8B8A8_UNORM_SRGB",t[t["DXGI_FORMAT_R8G8B8A8_UINT"]=30]="DXGI_FORMAT_R8G8B8A8_UINT",t[t["DXGI_FORMAT_R8G8B8A8_SNORM"]=31]="DXGI_FORMAT_R8G8B8A8_SNORM",t[t["DXGI_FORMAT_R8G8B8A8_SINT"]=32]="DXGI_FORMAT_R8G8B8A8_SINT",t[t["DXGI_FORMAT_R16G16_TYPELESS"]=33]="DXGI_FORMAT_R16G16_TYPELESS",t[t["DXGI_FORMAT_R16G16_FLOAT"]=34]="DXGI_FORMAT_R16G16_FLOAT",t[t["DXGI_FORMAT_R16G16_UNORM"]=35]="DXGI_FORMAT_R16G16_UNORM",t[t["DXGI_FORMAT_R16G16_UINT"]=36]="DXGI_FORMAT_R16G16_UINT",t[t["DXGI_FORMAT_R16G16_SNORM"]=37]="DXGI_FORMAT_R16G16_SNORM",t[t["DXGI_FORMAT_R16G16_SINT"]=38]="DXGI_FORMAT_R16G16_SINT",t[t["DXGI_FORMAT_R32_TYPELESS"]=39]="DXGI_FORMAT_R32_TYPELESS",t[t["DXGI_FORMAT_D32_FLOAT"]=40]="DXGI_FORMAT_D32_FLOAT",t[t["DXGI_FORMAT_R32_FLOAT"]=41]="DXGI_FORMAT_R32_FLOAT",t[t["DXGI_FORMAT_R32_UINT"]=42]="DXGI_FORMAT_R32_UINT",t[t["DXGI_FORMAT_R32_SINT"]=43]="DXGI_FORMAT_R32_SINT",t[t["DXGI_FORMAT_R24G8_TYPELESS"]=44]="DXGI_FORMAT_R24G8_TYPELESS",t[t["DXGI_FORMAT_D24_UNORM_S8_UINT"]=45]="DXGI_FORMAT_D24_UNORM_S8_UINT",t[t["DXGI_FORMAT_R24_UNORM_X8_TYPELESS"]=46]="DXGI_FORMAT_R24_UNORM_X8_TYPELESS",t[t["DXGI_FORMAT_X24_TYPELESS_G8_UINT"]=47]="DXGI_FORMAT_X24_TYPELESS_G8_UINT",t[t["DXGI_FORMAT_R8G8_TYPELESS"]=48]="DXGI_FORMAT_R8G8_TYPELESS",t[t["DXGI_FORMAT_R8G8_UNORM"]=49]="DXGI_FORMAT_R8G8_UNORM",t[t["DXGI_FORMAT_R8G8_UINT"]=50]="DXGI_FORMAT_R8G8_UINT",t[t["DXGI_FORMAT_R8G8_SNORM"]=51]="DXGI_FORMAT_R8G8_SNORM",t[t["DXGI_FORMAT_R8G8_SINT"]=52]="DXGI_FORMAT_R8G8_SINT",t[t["DXGI_FORMAT_R16_TYPELESS"]=53]="DXGI_FORMAT_R16_TYPELESS",t[t["DXGI_FORMAT_R16_FLOAT"]=54]="DXGI_FORMAT_R16_FLOAT",t[t["DXGI_FORMAT_D16_UNORM"]=55]="DXGI_FORMAT_D16_UNORM",t[t["DXGI_FORMAT_R16_UNORM"]=56]="DXGI_FORMAT_R16_UNORM",t[t["DXGI_FORMAT_R16_UINT"]=57]="DXGI_FORMAT_R16_UINT",t[t["DXGI_FORMAT_R16_SNORM"]=58]="DXGI_FORMAT_R16_SNORM",t[t["DXGI_FORMAT_R16_SINT"]=59]="DXGI_FORMAT_R16_SINT",t[t["DXGI_FORMAT_R8_TYPELESS"]=60]="DXGI_FORMAT_R8_TYPELESS",t[t["DXGI_FORMAT_R8_UNORM"]=61]="DXGI_FORMAT_R8_UNORM",t[t["DXGI_FORMAT_R8_UINT"]=62]="DXGI_FORMAT_R8_UINT",t[t["DXGI_FORMAT_R8_SNORM"]=63]="DXGI_FORMAT_R8_SNORM",t[t["DXGI_FORMAT_R8_SINT"]=64]="DXGI_FORMAT_R8_SINT",t[t["DXGI_FORMAT_A8_UNORM"]=65]="DXGI_FORMAT_A8_UNORM",t[t["DXGI_FORMAT_R1_UNORM"]=66]="DXGI_FORMAT_R1_UNORM",t[t["DXGI_FORMAT_R9G9B9E5_SHAREDEXP"]=67]="DXGI_FORMAT_R9G9B9E5_SHAREDEXP",t[t["DXGI_FORMAT_R8G8_B8G8_UNORM"]=68]="DXGI_FORMAT_R8G8_B8G8_UNORM",t[t["DXGI_FORMAT_G8R8_G8B8_UNORM"]=69]="DXGI_FORMAT_G8R8_G8B8_UNORM",t[t["DXGI_FORMAT_BC1_TYPELESS"]=70]="DXGI_FORMAT_BC1_TYPELESS",t[t["DXGI_FORMAT_BC1_UNORM"]=71]="DXGI_FORMAT_BC1_UNORM",t[t["DXGI_FORMAT_BC1_UNORM_SRGB"]=72]="DXGI_FORMAT_BC1_UNORM_SRGB",t[t["DXGI_FORMAT_BC2_TYPELESS"]=73]="DXGI_FORMAT_BC2_TYPELESS",t[t["DXGI_FORMAT_BC2_UNORM"]=74]="DXGI_FORMAT_BC2_UNORM",t[t["DXGI_FORMAT_BC2_UNORM_SRGB"]=75]="DXGI_FORMAT_BC2_UNORM_SRGB",t[t["DXGI_FORMAT_BC3_TYPELESS"]=76]="DXGI_FORMAT_BC3_TYPELESS",t[t["DXGI_FORMAT_BC3_UNORM"]=77]="DXGI_FORMAT_BC3_UNORM",t[t["DXGI_FORMAT_BC3_UNORM_SRGB"]=78]="DXGI_FORMAT_BC3_UNORM_SRGB",t[t["DXGI_FORMAT_BC4_TYPELESS"]=79]="DXGI_FORMAT_BC4_TYPELESS",t[t["DXGI_FORMAT_BC4_UNORM"]=80]="DXGI_FORMAT_BC4_UNORM",t[t["DXGI_FORMAT_BC4_SNORM"]=81]="DXGI_FORMAT_BC4_SNORM",t[t["DXGI_FORMAT_BC5_TYPELESS"]=82]="DXGI_FORMAT_BC5_TYPELESS",t[t["DXGI_FORMAT_BC5_UNORM"]=83]="DXGI_FORMAT_BC5_UNORM",t[t["DXGI_FORMAT_BC5_SNORM"]=84]="DXGI_FORMAT_BC5_SNORM",t[t["DXGI_FORMAT_B5G6R5_UNORM"]=85]="DXGI_FORMAT_B5G6R5_UNORM",t[t["DXGI_FORMAT_B5G5R5A1_UNORM"]=86]="DXGI_FORMAT_B5G5R5A1_UNORM",t[t["DXGI_FORMAT_B8G8R8A8_UNORM"]=87]="DXGI_FORMAT_B8G8R8A8_UNORM",t[t["DXGI_FORMAT_B8G8R8X8_UNORM"]=88]="DXGI_FORMAT_B8G8R8X8_UNORM",t[t["DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM"]=89]="DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM",t[t["DXGI_FORMAT_B8G8R8A8_TYPELESS"]=90]="DXGI_FORMAT_B8G8R8A8_TYPELESS",t[t["DXGI_FORMAT_B8G8R8A8_UNORM_SRGB"]=91]="DXGI_FORMAT_B8G8R8A8_UNORM_SRGB",t[t["DXGI_FORMAT_B8G8R8X8_TYPELESS"]=92]="DXGI_FORMAT_B8G8R8X8_TYPELESS",t[t["DXGI_FORMAT_B8G8R8X8_UNORM_SRGB"]=93]="DXGI_FORMAT_B8G8R8X8_UNORM_SRGB",t[t["DXGI_FORMAT_BC6H_TYPELESS"]=94]="DXGI_FORMAT_BC6H_TYPELESS",t[t["DXGI_FORMAT_BC6H_UF16"]=95]="DXGI_FORMAT_BC6H_UF16",t[t["DXGI_FORMAT_BC6H_SF16"]=96]="DXGI_FORMAT_BC6H_SF16",t[t["DXGI_FORMAT_BC7_TYPELESS"]=97]="DXGI_FORMAT_BC7_TYPELESS",t[t["DXGI_FORMAT_BC7_UNORM"]=98]="DXGI_FORMAT_BC7_UNORM",t[t["DXGI_FORMAT_BC7_UNORM_SRGB"]=99]="DXGI_FORMAT_BC7_UNORM_SRGB",t[t["DXGI_FORMAT_AYUV"]=100]="DXGI_FORMAT_AYUV",t[t["DXGI_FORMAT_Y410"]=101]="DXGI_FORMAT_Y410",t[t["DXGI_FORMAT_Y416"]=102]="DXGI_FORMAT_Y416",t[t["DXGI_FORMAT_NV12"]=103]="DXGI_FORMAT_NV12",t[t["DXGI_FORMAT_P010"]=104]="DXGI_FORMAT_P010",t[t["DXGI_FORMAT_P016"]=105]="DXGI_FORMAT_P016",t[t["DXGI_FORMAT_420_OPAQUE"]=106]="DXGI_FORMAT_420_OPAQUE",t[t["DXGI_FORMAT_YUY2"]=107]="DXGI_FORMAT_YUY2",t[t["DXGI_FORMAT_Y210"]=108]="DXGI_FORMAT_Y210",t[t["DXGI_FORMAT_Y216"]=109]="DXGI_FORMAT_Y216",t[t["DXGI_FORMAT_NV11"]=110]="DXGI_FORMAT_NV11",t[t["DXGI_FORMAT_AI44"]=111]="DXGI_FORMAT_AI44",t[t["DXGI_FORMAT_IA44"]=112]="DXGI_FORMAT_IA44",t[t["DXGI_FORMAT_P8"]=113]="DXGI_FORMAT_P8",t[t["DXGI_FORMAT_A8P8"]=114]="DXGI_FORMAT_A8P8",t[t["DXGI_FORMAT_B4G4R4A4_UNORM"]=115]="DXGI_FORMAT_B4G4R4A4_UNORM",t[t["DXGI_FORMAT_P208"]=116]="DXGI_FORMAT_P208",t[t["DXGI_FORMAT_V208"]=117]="DXGI_FORMAT_V208",t[t["DXGI_FORMAT_V408"]=118]="DXGI_FORMAT_V408",t[t["DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE"]=119]="DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE",t[t["DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE"]=120]="DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE",t[t["DXGI_FORMAT_FORCE_UINT"]=121]="DXGI_FORMAT_FORCE_UINT"})(Wt||(Wt={})),function(t){t[t["DDS_DIMENSION_TEXTURE1D"]=2]="DDS_DIMENSION_TEXTURE1D",t[t["DDS_DIMENSION_TEXTURE2D"]=3]="DDS_DIMENSION_TEXTURE2D",t[t["DDS_DIMENSION_TEXTURE3D"]=6]="DDS_DIMENSION_TEXTURE3D"}(zt||(zt={}));var ne,re,ie,oe=1,se=2,ae=4,ue=64,le=512,ce=131072,he=827611204,fe=861165636,de=894720068,pe=808540228,ve=4,me=(kt={},kt[he]=Mt.COMPRESSED_RGBA_S3TC_DXT1_EXT,kt[fe]=Mt.COMPRESSED_RGBA_S3TC_DXT3_EXT,kt[de]=Mt.COMPRESSED_RGBA_S3TC_DXT5_EXT,kt),ge=(Xt={},Xt[Wt.DXGI_FORMAT_BC1_TYPELESS]=Mt.COMPRESSED_RGBA_S3TC_DXT1_EXT,Xt[Wt.DXGI_FORMAT_BC1_UNORM]=Mt.COMPRESSED_RGBA_S3TC_DXT1_EXT,Xt[Wt.DXGI_FORMAT_BC2_TYPELESS]=Mt.COMPRESSED_RGBA_S3TC_DXT3_EXT,Xt[Wt.DXGI_FORMAT_BC2_UNORM]=Mt.COMPRESSED_RGBA_S3TC_DXT3_EXT,Xt[Wt.DXGI_FORMAT_BC3_TYPELESS]=Mt.COMPRESSED_RGBA_S3TC_DXT5_EXT,Xt[Wt.DXGI_FORMAT_BC3_UNORM]=Mt.COMPRESSED_RGBA_S3TC_DXT5_EXT,Xt[Wt.DXGI_FORMAT_BC1_UNORM_SRGB]=Mt.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT,Xt[Wt.DXGI_FORMAT_BC2_UNORM_SRGB]=Mt.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT,Xt[Wt.DXGI_FORMAT_BC3_UNORM_SRGB]=Mt.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT,Xt),_e=function(){function t(){}return t.use=function(e,n){if("dds"===e.extension&&e.data)try{Object.assign(e,Yt(e.name||e.url,t.parse(e.data),e.metadata))}catch(r){return void n(r)}n()},t.parse=function(t){var e=new Uint32Array(t),n=e[0];if(n!==Jt)throw new Error("Invalid DDS file magic word");var r=new Uint32Array(t,0,qt/Uint32Array.BYTES_PER_ELEMENT),i=r[Qt.HEIGHT],o=r[Qt.WIDTH],s=r[Qt.MIPMAP_COUNT],a=new Uint32Array(t,Qt.PIXEL_FORMAT*Uint32Array.BYTES_PER_ELEMENT,Kt/Uint32Array.BYTES_PER_ELEMENT),u=a[oe];if(u&ae){var l=a[te.FOURCC];if(l!==pe){var c=me[l],h=$t+qt,f=new Uint8Array(t,h),d=new Ht(f,{format:c,width:o,height:i,levels:s});return[d]}var p=$t+qt,v=new Uint32Array(e.buffer,p,Zt/Uint32Array.BYTES_PER_ELEMENT),m=v[ee.DXGI_FORMAT],g=v[ee.RESOURCE_DIMENSION],_=v[ee.MISC_FLAG],y=v[ee.ARRAY_SIZE],b=ge[m];if(void 0===b)throw new Error("DDSLoader cannot parse texture data with DXGI format "+m);if(_===ve)throw new Error("DDSLoader does not support cubemap textures");if(g===zt.DDS_DIMENSION_TEXTURE3D)throw new Error("DDSLoader does not supported 3D texture data");var E=new Array,x=$t+qt+Zt;if(1===y)E.push(new Uint8Array(t,x));else{for(var T=Lt[b],S=0,R=o,A=i,O=0;O<s;O++){var w=Math.max(1,R+3&-4),I=Math.max(1,A+3&-4),P=w*I*T;S+=P,R>>>=1,A>>>=1}var C=x;for(O=0;O<y;O++)E.push(new Uint8Array(t,C,S)),C+=S}return E.map((function(t){return new Ht(t,{format:b,width:o,height:i,levels:s})}))}if(u&ue)throw new Error("DDSLoader does not support uncompressed texture data.");if(u&le)throw new Error("DDSLoader does not supported YUV uncompressed texture data.");if(u&ce)throw new Error("DDSLoader does not support single-channel (lumninance) texture data!");if(u&se)throw new Error("DDSLoader does not support single-channel (alpha) texture data!");throw new Error("DDSLoader failed to load a texture file due to an unknown reason!")},t}();_t.setExtensionXhrType("ktx",_t.XHR_RESPONSE_TYPE.BUFFER);var ye=[171,75,84,88,32,49,49,187,13,10,26,10],be=67305985,Ee={FILE_IDENTIFIER:0,ENDIANNESS:12,GL_TYPE:16,GL_TYPE_SIZE:20,GL_FORMAT:24,GL_INTERNAL_FORMAT:28,GL_BASE_INTERNAL_FORMAT:32,PIXEL_WIDTH:36,PIXEL_HEIGHT:40,PIXEL_DEPTH:44,NUMBER_OF_ARRAY_ELEMENTS:48,NUMBER_OF_FACES:52,NUMBER_OF_MIPMAP_LEVELS:56,BYTES_OF_KEY_VALUE_DATA:60},xe=64,Te=(ne={},ne[Dt.vK.UNSIGNED_BYTE]=1,ne[Dt.vK.UNSIGNED_SHORT]=2,ne[Dt.vK.INT]=4,ne[Dt.vK.UNSIGNED_INT]=4,ne[Dt.vK.FLOAT]=4,ne[Dt.vK.HALF_FLOAT]=8,ne),Se=(re={},re[Dt.I2.RGBA]=4,re[Dt.I2.RGB]=3,re[Dt.I2.RG]=2,re[Dt.I2.RED]=1,re[Dt.I2.LUMINANCE]=1,re[Dt.I2.LUMINANCE_ALPHA]=2,re[Dt.I2.ALPHA]=1,re),Re=(ie={},ie[Dt.vK.UNSIGNED_SHORT_4_4_4_4]=2,ie[Dt.vK.UNSIGNED_SHORT_5_5_5_1]=2,ie[Dt.vK.UNSIGNED_SHORT_5_6_5]=2,ie),Ae=function(){function t(){}return t.use=function(e,n){if("ktx"===e.extension&&e.data)try{var r=e.name||e.url,i=t.parse(r,e.data),o=i.compressed,s=i.uncompressed;if(o)Object.assign(e,Yt(r,o,e.metadata));else if(s){var a={};s.forEach((function(t,e){var n=new J.xE(new J.VL(t.resource,{mipmap:Dt.WB.OFF,alphaMode:Dt.iw.NO_PREMULTIPLIED_ALPHA,type:t.type,format:t.format})),i=r+"-"+(e+1);J.VL.addToCache(n.baseTexture,i),J.xE.addToCache(n,i),0===e&&(a[r]=n,J.VL.addToCache(n.baseTexture,r),J.xE.addToCache(n,r)),a[i]=n})),Object.assign(e,{textures:a})}}catch(u){return void n(u)}n()},t.parse=function(e,n){var r=new DataView(n);if(!t.validate(e,r))return null;var i=r.getUint32(Ee.ENDIANNESS,!0)===be,o=r.getUint32(Ee.GL_TYPE,i),s=r.getUint32(Ee.GL_FORMAT,i),a=r.getUint32(Ee.GL_INTERNAL_FORMAT,i),u=r.getUint32(Ee.PIXEL_WIDTH,i),l=r.getUint32(Ee.PIXEL_HEIGHT,i)||1,c=r.getUint32(Ee.PIXEL_DEPTH,i)||1,h=r.getUint32(Ee.NUMBER_OF_ARRAY_ELEMENTS,i)||1,f=r.getUint32(Ee.NUMBER_OF_FACES,i),d=r.getUint32(Ee.NUMBER_OF_MIPMAP_LEVELS,i),p=r.getUint32(Ee.BYTES_OF_KEY_VALUE_DATA,i);if(0===l||1!==c)throw new Error("Only 2D textures are supported");if(1!==f)throw new Error("CubeTextures are not supported by KTXLoader yet!");if(1!==h)throw new Error("WebGL does not support array textures");var v,m=4,g=4,_=u+3&-4,y=l+3&-4,b=new Array(h),E=u*l;if(0===o&&(E=_*y),v=0!==o?Te[o]?Te[o]*Se[s]:Re[o]:Lt[a],void 0===v)throw new Error("Unable to resolve the pixel format stored in the *.ktx file!");for(var x=E*v,T=x,S=u,R=l,A=_,O=y,w=xe+p,I=0;I<d;I++){for(var P=r.getUint32(w,i),C=w+4,N=0;N<h;N++){var M=b[N];M||(M=b[N]=new Array(d)),M[I]={levelID:I,levelWidth:d>1||0!==o?S:A,levelHeight:d>1||0!==o?R:O,levelBuffer:new Uint8Array(n,C,T)},C+=T}w+=P+4,w=w%4!==0?w+4-w%4:w,S=S>>1||1,R=R>>1||1,A=S+m-1&~(m-1),O=R+g-1&~(g-1),T=A*O*v}return 0!==o?{uncompressed:b.map((function(e){var n=e[0].levelBuffer,r=!1;return o===Dt.vK.FLOAT?n=new Float32Array(e[0].levelBuffer.buffer,e[0].levelBuffer.byteOffset,e[0].levelBuffer.byteLength/4):o===Dt.vK.UNSIGNED_INT?(r=!0,n=new Uint32Array(e[0].levelBuffer.buffer,e[0].levelBuffer.byteOffset,e[0].levelBuffer.byteLength/4)):o===Dt.vK.INT&&(r=!0,n=new Int32Array(e[0].levelBuffer.buffer,e[0].levelBuffer.byteOffset,e[0].levelBuffer.byteLength/4)),{resource:new J.qm(n,{width:e[0].levelWidth,height:e[0].levelHeight}),type:o,format:r?t.convertFormatToInteger(s):s}}))}:{compressed:b.map((function(t){return new Ht(null,{format:a,width:u,height:l,levels:d,levelBuffers:t})}))}},t.validate=function(t,e){for(var n=0;n<ye.length;n++)if(e.getUint8(n)!==ye[n])return console.error(t+" is not a valid *.ktx file!"),!1;return!0},t.convertFormatToInteger=function(t){switch(t){case Dt.I2.RGBA:return Dt.I2.RGBA_INTEGER;case Dt.I2.RGB:return Dt.I2.RGB_INTEGER;case Dt.I2.RG:return Dt.I2.RG_INTEGER;case Dt.I2.RED:return Dt.I2.RED_INTEGER;default:return t}},t}(),Oe=function(t,e){return Oe=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Oe(t,e)};function we(t,e){function n(){this.constructor=t}Oe(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}(function(t){function e(e,n,r,i){void 0===e&&(e=1500),void 0===r&&(r=16384),void 0===i&&(i=!1);var o=t.call(this)||this,s=16384;return r>s&&(r=s),o._properties=[!1,!0,!1,!1,!1],o._maxSize=e,o._batchSize=r,o._buffers=null,o._bufferUpdateIDs=[],o._updateID=0,o.interactiveChildren=!1,o.blendMode=Dt.T$.NORMAL,o.autoResize=i,o.roundPixels=!0,o.baseTexture=null,o.setProperties(n),o._tint=0,o.tintRgb=new Float32Array(4),o.tint=16777215,o}we(e,t),e.prototype.setProperties=function(t){t&&(this._properties[0]="vertices"in t||"scale"in t?!!t.vertices||!!t.scale:this._properties[0],this._properties[1]="position"in t?!!t.position:this._properties[1],this._properties[2]="rotation"in t?!!t.rotation:this._properties[2],this._properties[3]="uvs"in t?!!t.uvs:this._properties[3],this._properties[4]="tint"in t||"alpha"in t?!!t.tint||!!t.alpha:this._properties[4])},e.prototype.updateTransform=function(){this.displayObjectUpdateTransform()},Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){this._tint=t,(0,O.wK)(t,this.tintRgb)},enumerable:!1,configurable:!0}),e.prototype.render=function(t){var e=this;this.visible&&!(this.worldAlpha<=0)&&this.children.length&&this.renderable&&(this.baseTexture||(this.baseTexture=this.children[0]._texture.baseTexture,this.baseTexture.valid||this.baseTexture.once("update",(function(){return e.onChildrenChange(0)}))),t.batch.setObjectRenderer(t.plugins.particle),t.plugins.particle.render(this))},e.prototype.onChildrenChange=function(t){var e=Math.floor(t/this._batchSize);while(this._bufferUpdateIDs.length<e)this._bufferUpdateIDs.push(0);this._bufferUpdateIDs[e]=++this._updateID},e.prototype.dispose=function(){if(this._buffers){for(var t=0;t<this._buffers.length;++t)this._buffers[t].destroy();this._buffers=null}},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this.dispose(),this._properties=null,this._buffers=null,this._bufferUpdateIDs=null}})(w.W2);var Ie,Pe,Ce=function(){function t(t,e,n){this.geometry=new J.ZX,this.indexBuffer=null,this.size=n,this.dynamicProperties=[],this.staticProperties=[];for(var r=0;r<t.length;++r){var i=t[r];i={attributeName:i.attributeName,size:i.size,uploadFunction:i.uploadFunction,type:i.type||Dt.vK.FLOAT,offset:i.offset},e[r]?this.dynamicProperties.push(i):this.staticProperties.push(i)}this.staticStride=0,this.staticBuffer=null,this.staticData=null,this.staticDataUint32=null,this.dynamicStride=0,this.dynamicBuffer=null,this.dynamicData=null,this.dynamicDataUint32=null,this._updateID=0,this.initBuffers()}return t.prototype.initBuffers=function(){var t=this.geometry,e=0;this.indexBuffer=new J.lW((0,O.fl)(this.size),!0,!0),t.addIndex(this.indexBuffer),this.dynamicStride=0;for(var n=0;n<this.dynamicProperties.length;++n){var r=this.dynamicProperties[n];r.offset=e,e+=r.size,this.dynamicStride+=r.size}var i=new ArrayBuffer(this.size*this.dynamicStride*4*4);this.dynamicData=new Float32Array(i),this.dynamicDataUint32=new Uint32Array(i),this.dynamicBuffer=new J.lW(this.dynamicData,!1,!1);var o=0;this.staticStride=0;for(n=0;n<this.staticProperties.length;++n){r=this.staticProperties[n];r.offset=o,o+=r.size,this.staticStride+=r.size}var s=new ArrayBuffer(this.size*this.staticStride*4*4);this.staticData=new Float32Array(s),this.staticDataUint32=new Uint32Array(s),this.staticBuffer=new J.lW(this.staticData,!0,!1);for(n=0;n<this.dynamicProperties.length;++n){r=this.dynamicProperties[n];t.addAttribute(r.attributeName,this.dynamicBuffer,0,r.type===Dt.vK.UNSIGNED_BYTE,r.type,4*this.dynamicStride,4*r.offset)}for(n=0;n<this.staticProperties.length;++n){r=this.staticProperties[n];t.addAttribute(r.attributeName,this.staticBuffer,0,r.type===Dt.vK.UNSIGNED_BYTE,r.type,4*this.staticStride,4*r.offset)}},t.prototype.uploadDynamic=function(t,e,n){for(var r=0;r<this.dynamicProperties.length;r++){var i=this.dynamicProperties[r];i.uploadFunction(t,e,n,i.type===Dt.vK.UNSIGNED_BYTE?this.dynamicDataUint32:this.dynamicData,this.dynamicStride,i.offset)}this.dynamicBuffer._updateID++},t.prototype.uploadStatic=function(t,e,n){for(var r=0;r<this.staticProperties.length;r++){var i=this.staticProperties[r];i.uploadFunction(t,e,n,i.type===Dt.vK.UNSIGNED_BYTE?this.staticDataUint32:this.staticData,this.staticStride,i.offset)}this.staticBuffer._updateID++},t.prototype.destroy=function(){this.indexBuffer=null,this.dynamicProperties=null,this.dynamicBuffer=null,this.dynamicData=null,this.dynamicDataUint32=null,this.staticProperties=null,this.staticBuffer=null,this.staticData=null,this.staticDataUint32=null,this.geometry.destroy()},t}(),Ne="varying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nuniform sampler2D uSampler;\n\nvoid main(void){\n vec4 color = texture2D(uSampler, vTextureCoord) * vColor;\n gl_FragColor = color;\n}",Me="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\nattribute vec4 aColor;\n\nattribute vec2 aPositionCoord;\nattribute float aRotation;\n\nuniform mat3 translationMatrix;\nuniform vec4 uColor;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nvoid main(void){\n float x = (aVertexPosition.x) * cos(aRotation) - (aVertexPosition.y) * sin(aRotation);\n float y = (aVertexPosition.x) * sin(aRotation) + (aVertexPosition.y) * cos(aRotation);\n\n vec2 v = vec2(x, y);\n v = v + aPositionCoord;\n\n gl_Position = vec4((translationMatrix * vec3(v, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vColor = aColor * uColor;\n}\n",De=function(t){function e(e){var n=t.call(this,e)||this;return n.shader=null,n.properties=null,n.tempMatrix=new k.y3,n.properties=[{attributeName:"aVertexPosition",size:2,uploadFunction:n.uploadVertices,offset:0},{attributeName:"aPositionCoord",size:2,uploadFunction:n.uploadPosition,offset:0},{attributeName:"aRotation",size:1,uploadFunction:n.uploadRotation,offset:0},{attributeName:"aTextureCoord",size:2,uploadFunction:n.uploadUvs,offset:0},{attributeName:"aColor",size:1,type:Dt.vK.UNSIGNED_BYTE,uploadFunction:n.uploadTint,offset:0}],n.shader=J.ex.from(Me,Ne,{}),n.state=J.ZM.for2d(),n}return we(e,t),e.prototype.render=function(t){var e=t.children,n=t._maxSize,r=t._batchSize,i=this.renderer,o=e.length;if(0!==o){o>n&&!t.autoResize&&(o=n);var s=t._buffers;s||(s=t._buffers=this.generateBuffers(t));var a=e[0]._texture.baseTexture;this.state.blendMode=(0,O.D)(t.blendMode,a.alphaMode),i.state.set(this.state);var u=i.gl,l=t.worldTransform.copyTo(this.tempMatrix);l.prepend(i.globalUniforms.uniforms.projectionMatrix),this.shader.uniforms.translationMatrix=l.toArray(!0),this.shader.uniforms.uColor=(0,O.Qt)(t.tintRgb,t.worldAlpha,this.shader.uniforms.uColor,a.alphaMode),this.shader.uniforms.uSampler=a,this.renderer.shader.bind(this.shader);for(var c=!1,h=0,f=0;h<o;h+=r,f+=1){var d=o-h;d>r&&(d=r),f>=s.length&&s.push(this._generateOneMoreBuffer(t));var p=s[f];p.uploadDynamic(e,h,d);var v=t._bufferUpdateIDs[f]||0;c=c||p._updateID<v,c&&(p._updateID=t._updateID,p.uploadStatic(e,h,d)),i.geometry.bind(p.geometry),u.drawElements(u.TRIANGLES,6*d,u.UNSIGNED_SHORT,0)}}},e.prototype.generateBuffers=function(t){for(var e=[],n=t._maxSize,r=t._batchSize,i=t._properties,o=0;o<n;o+=r)e.push(new Ce(this.properties,i,r));return e},e.prototype._generateOneMoreBuffer=function(t){var e=t._batchSize,n=t._properties;return new Ce(this.properties,n,e)},e.prototype.uploadVertices=function(t,e,n,r,i,o){for(var s=0,a=0,u=0,l=0,c=0;c<n;++c){var h=t[e+c],f=h._texture,d=h.scale.x,p=h.scale.y,v=f.trim,m=f.orig;v?(a=v.x-h.anchor.x*m.width,s=a+v.width,l=v.y-h.anchor.y*m.height,u=l+v.height):(s=m.width*(1-h.anchor.x),a=m.width*-h.anchor.x,u=m.height*(1-h.anchor.y),l=m.height*-h.anchor.y),r[o]=a*d,r[o+1]=l*p,r[o+i]=s*d,r[o+i+1]=l*p,r[o+2*i]=s*d,r[o+2*i+1]=u*p,r[o+3*i]=a*d,r[o+3*i+1]=u*p,o+=4*i}},e.prototype.uploadPosition=function(t,e,n,r,i,o){for(var s=0;s<n;s++){var a=t[e+s].position;r[o]=a.x,r[o+1]=a.y,r[o+i]=a.x,r[o+i+1]=a.y,r[o+2*i]=a.x,r[o+2*i+1]=a.y,r[o+3*i]=a.x,r[o+3*i+1]=a.y,o+=4*i}},e.prototype.uploadRotation=function(t,e,n,r,i,o){for(var s=0;s<n;s++){var a=t[e+s].rotation;r[o]=a,r[o+i]=a,r[o+2*i]=a,r[o+3*i]=a,o+=4*i}},e.prototype.uploadUvs=function(t,e,n,r,i,o){for(var s=0;s<n;++s){var a=t[e+s]._texture._uvs;a?(r[o]=a.x0,r[o+1]=a.y0,r[o+i]=a.x1,r[o+i+1]=a.y1,r[o+2*i]=a.x2,r[o+2*i+1]=a.y2,r[o+3*i]=a.x3,r[o+3*i+1]=a.y3,o+=4*i):(r[o]=0,r[o+1]=0,r[o+i]=0,r[o+i+1]=0,r[o+2*i]=0,r[o+2*i+1]=0,r[o+3*i]=0,r[o+3*i+1]=0,o+=4*i)}},e.prototype.uploadTint=function(t,e,n,r,i,o){for(var s=0;s<n;++s){var a=t[e+s],u=a._texture.baseTexture.alphaMode>0,l=a.alpha,c=l<1&&u?(0,O.rA)(a._tintRGB,l):a._tintRGB+(255*l<<24);r[o]=c,r[o+i]=c,r[o+2*i]=c,r[o+3*i]=c,o+=4*i}},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.shader&&(this.shader.destroy(),this.shader=null),this.tempMatrix=null},e}(J.bO),Le=n(1576);(function(t){t["MITER"]="miter",t["BEVEL"]="bevel",t["ROUND"]="round"})(Ie||(Ie={})),function(t){t["BUTT"]="butt",t["ROUND"]="round",t["SQUARE"]="square"}(Pe||(Pe={}));var Fe={adaptive:!0,maxLength:10,minSegments:8,maxSegments:2048,epsilon:1e-4,_segmentsCount:function(t,e){if(void 0===e&&(e=20),!this.adaptive||!t||isNaN(t))return e;var n=Math.ceil(t/this.maxLength);return n<this.minSegments?n=this.minSegments:n>this.maxSegments&&(n=this.maxSegments),n}},Be=function(){function t(){this.color=16777215,this.alpha=1,this.texture=J.xE.WHITE,this.matrix=null,this.visible=!1,this.reset()}return t.prototype.clone=function(){var e=new t;return e.color=this.color,e.alpha=this.alpha,e.texture=this.texture,e.matrix=this.matrix,e.visible=this.visible,e},t.prototype.reset=function(){this.color=16777215,this.alpha=1,this.texture=J.xE.WHITE,this.matrix=null,this.visible=!1},t.prototype.destroy=function(){this.texture=null,this.matrix=null},t}(),Ue=function(t,e){return Ue=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Ue(t,e)};function Ge(t,e){function n(){this.constructor=t}Ue(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function ke(t,e){var n,r;void 0===e&&(e=!1);var i=t.length;if(!(i<6)){for(var o=0,s=0,a=t[i-2],u=t[i-1];s<i;s+=2){var l=t[s],c=t[s+1];o+=(l-a)*(c+u),a=l,u=c}if(!e&&o>0||e&&o<=0){var h=i/2;for(s=h+h%2;s<i;s+=2){var f=i-s-2,d=i-s-1,p=s,v=s+1;n=[t[p],t[f]],t[f]=n[0],t[p]=n[1],r=[t[v],t[d]],t[d]=r[0],t[v]=r[1]}}}}var Xe={build:function(t){t.points=t.shape.points.slice()},triangulate:function(t,e){var n=t.points,r=t.holes,i=e.points,o=e.indices;if(n.length>=6){ke(n,!1);for(var s=[],a=0;a<r.length;a++){var u=r[a];ke(u.points,!0),s.push(n.length/2),n=n.concat(u.points)}var l=(0,O.OT)(n,s,2);if(!l)return;var c=i.length/2;for(a=0;a<l.length;a+=3)o.push(l[a]+c),o.push(l[a+1]+c),o.push(l[a+2]+c);for(a=0;a<n.length;a++)i.push(n[a])}}},je={build:function(t){var e,n,r,i,o,s,a=t.points;if(t.type===k.HS.CIRC){var u=t.shape;e=u.x,n=u.y,o=s=u.radius,r=i=0}else if(t.type===k.HS.ELIP){var l=t.shape;e=l.x,n=l.y,o=l.width,s=l.height,r=i=0}else{var c=t.shape,h=c.width/2,f=c.height/2;e=c.x+h,n=c.y+f,o=s=Math.max(0,Math.min(c.radius,Math.min(h,f))),r=h-o,i=f-s}var d=Math.ceil(2.3*Math.sqrt(o+s)),p=8*d+(r?4:0)+(i?4:0);if(a.length=p,0!==p){if(0===d)return a.length=8,a[0]=a[6]=e+r,a[1]=a[3]=n+i,a[2]=a[4]=e-r,void(a[5]=a[7]=n-i);var v=0,m=4*d+(r?2:0)+2,g=m,_=p,y=r+o,b=i,E=e+y,x=e-y,T=n+b;if(a[v++]=E,a[v++]=T,a[--m]=T,a[--m]=x,i){var S=n-b;a[g++]=x,a[g++]=S,a[--_]=S,a[--_]=E}for(var R=1;R<d;R++){var A=Math.PI/2*(R/d);y=r+Math.cos(A)*o,b=i+Math.sin(A)*s,E=e+y,x=e-y,T=n+b,S=n-b;a[v++]=E,a[v++]=T,a[--m]=T,a[--m]=x,a[g++]=x,a[g++]=S,a[--_]=S,a[--_]=E}y=r,b=i+s,E=e+y,x=e-y,T=n+b,S=n-b;a[v++]=E,a[v++]=T,a[--_]=S,a[--_]=E,r&&(a[v++]=x,a[v++]=T,a[--_]=S,a[--_]=x)}},triangulate:function(t,e){var n,r,i=t.points,o=e.points,s=e.indices,a=o.length/2,u=a;if(t.type!==k.HS.RREC){var l=t.shape;n=l.x,r=l.y}else{var c=t.shape;n=c.x+c.width/2,r=c.y+c.height/2}var h=t.matrix;o.push(t.matrix?h.a*n+h.c*r+h.tx:n,t.matrix?h.b*n+h.d*r+h.ty:r),a++,o.push(i[0],i[1]);for(var f=2;f<i.length;f+=2)o.push(i[f],i[f+1]),s.push(a++,u,a);s.push(u+1,u,a)}},He={build:function(t){var e=t.shape,n=e.x,r=e.y,i=e.width,o=e.height,s=t.points;s.length=0,s.push(n,r,n+i,r,n+i,r+o,n,r+o)},triangulate:function(t,e){var n=t.points,r=e.points,i=r.length/2;r.push(n[0],n[1],n[2],n[3],n[6],n[7],n[4],n[5]),e.indices.push(i,i+1,i+2,i+1,i+2,i+3)}};function Ve(t,e,n){var r=e-t;return t+r*n}function Ye(t,e,n,r,i,o,s){void 0===s&&(s=[]);for(var a=20,u=s,l=0,c=0,h=0,f=0,d=0,p=0,v=0,m=0;v<=a;++v)m=v/a,l=Ve(t,n,m),c=Ve(e,r,m),h=Ve(n,i,m),f=Ve(r,o,m),d=Ve(l,h,m),p=Ve(c,f,m),0===v&&u[u.length-2]===d&&u[u.length-1]===p||u.push(d,p);return u}var We={build:function(t){if(vn.nextRoundedRectBehavior)je.build(t);else{var e=t.shape,n=t.points,r=e.x,i=e.y,o=e.width,s=e.height,a=Math.max(0,Math.min(e.radius,Math.min(o,s)/2));n.length=0,a?(Ye(r,i+a,r,i,r+a,i,n),Ye(r+o-a,i,r+o,i,r+o,i+a,n),Ye(r+o,i+s-a,r+o,i+s,r+o-a,i+s,n),Ye(r+a,i+s,r,i+s,r,i+s-a,n)):n.push(r,i,r+o,i,r+o,i+s,r,i+s)}},triangulate:function(t,e){if(vn.nextRoundedRectBehavior)je.triangulate(t,e);else{for(var n=t.points,r=e.points,i=e.indices,o=r.length/2,s=(0,O.OT)(n,null,2),a=0,u=s.length;a<u;a+=3)i.push(s[a]+o),i.push(s[a+1]+o),i.push(s[a+2]+o);for(a=0,u=n.length;a<u;a++)r.push(n[a],n[++a])}}};function ze(t,e,n,r,i,o,s,a){var u,l,c=t-n*i,h=e-r*i,f=t+n*o,d=e+r*o;s?(u=r,l=-n):(u=-r,l=n);var p=c+u,v=h+l,m=f+u,g=d+l;return a.push(p,v),a.push(m,g),2}function $e(t,e,n,r,i,o,s,a){var u=n-t,l=r-e,c=Math.atan2(u,l),h=Math.atan2(i-t,o-e);a&&c<h?c+=2*Math.PI:!a&&c>h&&(h+=2*Math.PI);var f=c,d=h-c,p=Math.abs(d),v=Math.sqrt(u*u+l*l),m=1+(15*p*Math.sqrt(v)/Math.PI>>0),g=d/m;if(f+=g,a){s.push(t,e),s.push(n,r);for(var _=1,y=f;_<m;_++,y+=g)s.push(t,e),s.push(t+Math.sin(y)*v,e+Math.cos(y)*v);s.push(t,e),s.push(i,o)}else{s.push(n,r),s.push(t,e);for(_=1,y=f;_<m;_++,y+=g)s.push(t+Math.sin(y)*v,e+Math.cos(y)*v),s.push(t,e);s.push(i,o),s.push(t,e)}return 2*m}function qe(t,e){var n=t.shape,r=t.points||n.points.slice(),i=e.closePointEps;if(0!==r.length){var o=t.lineStyle,s=new k.E9(r[0],r[1]),a=new k.E9(r[r.length-2],r[r.length-1]),u=n.type!==k.HS.POLY||n.closeStroke,l=Math.abs(s.x-a.x)<i&&Math.abs(s.y-a.y)<i;if(u){r=r.slice(),l&&(r.pop(),r.pop(),a.set(r[r.length-2],r[r.length-1]));var c=.5*(s.x+a.x),h=.5*(a.y+s.y);r.unshift(c,h),r.push(c,h)}var f=e.points,d=r.length/2,p=r.length,v=f.length/2,m=o.width/2,g=m*m,_=o.miterLimit*o.miterLimit,y=r[0],b=r[1],E=r[2],x=r[3],T=0,S=0,R=-(b-x),A=y-E,O=0,w=0,I=Math.sqrt(R*R+A*A);R/=I,A/=I,R*=m,A*=m;var P=o.alignment,C=2*(1-P),N=2*P;u||(o.cap===Pe.ROUND?p+=$e(y-R*(C-N)*.5,b-A*(C-N)*.5,y-R*C,b-A*C,y+R*N,b+A*N,f,!0)+2:o.cap===Pe.SQUARE&&(p+=ze(y,b,R,A,C,N,!0,f))),f.push(y-R*C,b-A*C),f.push(y+R*N,b+A*N);for(var M=1;M<d-1;++M){y=r[2*(M-1)],b=r[2*(M-1)+1],E=r[2*M],x=r[2*M+1],T=r[2*(M+1)],S=r[2*(M+1)+1],R=-(b-x),A=y-E,I=Math.sqrt(R*R+A*A),R/=I,A/=I,R*=m,A*=m,O=-(x-S),w=E-T,I=Math.sqrt(O*O+w*w),O/=I,w/=I,O*=m,w*=m;var D=E-y,L=b-x,F=E-T,B=S-x,U=L*F-B*D,G=U<0;if(Math.abs(U)<.1)f.push(E-R*C,x-A*C),f.push(E+R*N,x+A*N);else{var X=(-R+y)*(-A+x)-(-R+E)*(-A+b),j=(-O+T)*(-w+x)-(-O+E)*(-w+S),H=(D*j-F*X)/U,V=(B*X-L*j)/U,Y=(H-E)*(H-E)+(V-x)*(V-x),W=E+(H-E)*C,z=x+(V-x)*C,$=E-(H-E)*N,q=x-(V-x)*N,K=Math.min(D*D+L*L,F*F+B*B),Z=G?C:N,J=K+Z*Z*g,Q=Y<=J;Q?o.join===Ie.BEVEL||Y/g>_?(G?(f.push(W,z),f.push(E+R*N,x+A*N),f.push(W,z),f.push(E+O*N,x+w*N)):(f.push(E-R*C,x-A*C),f.push($,q),f.push(E-O*C,x-w*C),f.push($,q)),p+=2):o.join===Ie.ROUND?G?(f.push(W,z),f.push(E+R*N,x+A*N),p+=$e(E,x,E+R*N,x+A*N,E+O*N,x+w*N,f,!0)+4,f.push(W,z),f.push(E+O*N,x+w*N)):(f.push(E-R*C,x-A*C),f.push($,q),p+=$e(E,x,E-R*C,x-A*C,E-O*C,x-w*C,f,!1)+4,f.push(E-O*C,x-w*C),f.push($,q)):(f.push(W,z),f.push($,q)):(f.push(E-R*C,x-A*C),f.push(E+R*N,x+A*N),o.join===Ie.BEVEL||Y/g>_||(o.join===Ie.ROUND?p+=G?$e(E,x,E+R*N,x+A*N,E+O*N,x+w*N,f,!0)+2:$e(E,x,E-R*C,x-A*C,E-O*C,x-w*C,f,!1)+2:(G?(f.push($,q),f.push($,q)):(f.push(W,z),f.push(W,z)),p+=2)),f.push(E-O*C,x-w*C),f.push(E+O*N,x+w*N),p+=2)}}y=r[2*(d-2)],b=r[2*(d-2)+1],E=r[2*(d-1)],x=r[2*(d-1)+1],R=-(b-x),A=y-E,I=Math.sqrt(R*R+A*A),R/=I,A/=I,R*=m,A*=m,f.push(E-R*C,x-A*C),f.push(E+R*N,x+A*N),u||(o.cap===Pe.ROUND?p+=$e(E-R*(C-N)*.5,x-A*(C-N)*.5,E-R*C,x-A*C,E+R*N,x+A*N,f,!1)+2:o.cap===Pe.SQUARE&&(p+=ze(E,x,R,A,C,N,!1,f)));var tt=e.indices,et=Fe.epsilon*Fe.epsilon;for(M=v;M<p+v-2;++M)y=f[2*M],b=f[2*M+1],E=f[2*(M+1)],x=f[2*(M+1)+1],T=f[2*(M+2)],S=f[2*(M+2)+1],Math.abs(y*(x-S)+E*(S-b)+T*(b-x))<et||tt.push(M,M+1,M+2)}}function Ke(t,e){var n=0,r=t.shape,i=t.points||r.points,o=r.type!==k.HS.POLY||r.closeStroke;if(0!==i.length){var s=e.points,a=e.indices,u=i.length/2,l=s.length/2,c=l;for(s.push(i[0],i[1]),n=1;n<u;n++)s.push(i[2*n],i[2*n+1]),a.push(c,c+1),c++;o&&a.push(c,l)}}function Ze(t,e){t.lineStyle.native?Ke(t,e):qe(t,e)}var Je,Qe,tn=function(){function t(){}return t.curveTo=function(t,e,n,r,i,o){var s=o[o.length-2],a=o[o.length-1],u=a-e,l=s-t,c=r-e,h=n-t,f=Math.abs(u*h-l*c);if(f<1e-8||0===i)return o[o.length-2]===t&&o[o.length-1]===e||o.push(t,e),null;var d=u*u+l*l,p=c*c+h*h,v=u*c+l*h,m=i*Math.sqrt(d)/f,g=i*Math.sqrt(p)/f,_=m*v/d,y=g*v/p,b=m*h+g*l,E=m*c+g*u,x=l*(g+_),T=u*(g+_),S=h*(m+y),R=c*(m+y),A=Math.atan2(T-E,x-b),O=Math.atan2(R-E,S-b);return{cx:b+t,cy:E+e,radius:i,startAngle:A,endAngle:O,anticlockwise:l*c>h*u}},t.arc=function(t,e,n,r,i,o,s,a,u){for(var l=s-o,c=Fe._segmentsCount(Math.abs(l)*i,40*Math.ceil(Math.abs(l)/k._b)),h=l/(2*c),f=2*h,d=Math.cos(h),p=Math.sin(h),v=c-1,m=v%1/v,g=0;g<=v;++g){var _=g+m*g,y=h+o+f*_,b=Math.cos(y),E=-Math.sin(y);u.push((d*b+p*E)*i+n,(d*-E+p*b)*i+r)}},t}(),en=function(){function t(){}return t.curveLength=function(t,e,n,r,i,o,s,a){for(var u=10,l=0,c=0,h=0,f=0,d=0,p=0,v=0,m=0,g=0,_=0,y=0,b=t,E=e,x=1;x<=u;++x)c=x/u,h=c*c,f=h*c,d=1-c,p=d*d,v=p*d,m=v*t+3*p*c*n+3*d*h*i+f*s,g=v*e+3*p*c*r+3*d*h*o+f*a,_=b-m,y=E-g,b=m,E=g,l+=Math.sqrt(_*_+y*y);return l},t.curveTo=function(e,n,r,i,o,s,a){var u=a[a.length-2],l=a[a.length-1];a.length-=2;var c=Fe._segmentsCount(t.curveLength(u,l,e,n,r,i,o,s)),h=0,f=0,d=0,p=0,v=0;a.push(u,l);for(var m=1,g=0;m<=c;++m)g=m/c,h=1-g,f=h*h,d=f*h,p=g*g,v=p*g,a.push(d*u+3*f*g*e+3*h*p*r+v*o,d*l+3*f*g*n+3*h*p*i+v*s)},t}(),nn=function(){function t(){}return t.curveLength=function(t,e,n,r,i,o){var s=t-2*n+i,a=e-2*r+o,u=2*n-2*t,l=2*r-2*e,c=4*(s*s+a*a),h=4*(s*u+a*l),f=u*u+l*l,d=2*Math.sqrt(c+h+f),p=Math.sqrt(c),v=2*c*p,m=2*Math.sqrt(f),g=h/p;return(v*d+p*h*(d-m)+(4*f*c-h*h)*Math.log((2*p+g+d)/(g+m)))/(4*v)},t.curveTo=function(e,n,r,i,o){for(var s=o[o.length-2],a=o[o.length-1],u=Fe._segmentsCount(t.curveLength(s,a,e,n,r,i)),l=0,c=0,h=1;h<=u;++h){var f=h/u;l=s+(e-s)*f,c=a+(n-a)*f,o.push(l+(e+(r-e)*f-l)*f,c+(n+(i-n)*f-c)*f)}},t}(),rn=function(){function t(){this.reset()}return t.prototype.begin=function(t,e,n){this.reset(),this.style=t,this.start=e,this.attribStart=n},t.prototype.end=function(t,e){this.attribSize=e-this.attribStart,this.size=t-this.start},t.prototype.reset=function(){this.style=null,this.size=0,this.start=0,this.attribStart=0,this.attribSize=0},t}(),on=(Je={},Je[k.HS.POLY]=Xe,Je[k.HS.CIRC]=je,Je[k.HS.ELIP]=je,Je[k.HS.RECT]=He,Je[k.HS.RREC]=We,Je),sn=[],an=[],un=function(){function t(t,e,n,r){void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null),this.points=[],this.holes=[],this.shape=t,this.lineStyle=n,this.fillStyle=e,this.matrix=r,this.type=t.type}return t.prototype.clone=function(){return new t(this.shape,this.fillStyle,this.lineStyle,this.matrix)},t.prototype.destroy=function(){this.shape=null,this.holes.length=0,this.holes=null,this.points.length=0,this.points=null,this.lineStyle=null,this.fillStyle=null},t}(),ln=new k.E9,cn=new w.YZ,hn=function(t){function e(){var e=t.call(this)||this;return e.closePointEps=1e-4,e.boundsPadding=0,e.uvsFloat32=null,e.indicesUint16=null,e.batchable=!1,e.points=[],e.colors=[],e.uvs=[],e.indices=[],e.textureIds=[],e.graphicsData=[],e.drawCalls=[],e.batchDirty=-1,e.batches=[],e.dirty=0,e.cacheDirty=-1,e.clearDirty=0,e.shapeIndex=0,e._bounds=new w.YZ,e.boundsDirty=-1,e}return Ge(e,t),Object.defineProperty(e.prototype,"bounds",{get:function(){return this.boundsDirty!==this.dirty&&(this.boundsDirty=this.dirty,this.calculateBounds()),this._bounds},enumerable:!1,configurable:!0}),e.prototype.invalidate=function(){this.boundsDirty=-1,this.dirty++,this.batchDirty++,this.shapeIndex=0,this.points.length=0,this.colors.length=0,this.uvs.length=0,this.indices.length=0,this.textureIds.length=0;for(var t=0;t<this.drawCalls.length;t++)this.drawCalls[t].texArray.clear(),an.push(this.drawCalls[t]);this.drawCalls.length=0;for(t=0;t<this.batches.length;t++){var e=this.batches[t];e.reset(),sn.push(e)}this.batches.length=0},e.prototype.clear=function(){return this.graphicsData.length>0&&(this.invalidate(),this.clearDirty++,this.graphicsData.length=0),this},e.prototype.drawShape=function(t,e,n,r){void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null);var i=new un(t,e,n,r);return this.graphicsData.push(i),this.dirty++,this},e.prototype.drawHole=function(t,e){if(void 0===e&&(e=null),!this.graphicsData.length)return null;var n=new un(t,null,null,e),r=this.graphicsData[this.graphicsData.length-1];return n.lineStyle=r.lineStyle,r.holes.push(n),this.dirty++,this},e.prototype.destroy=function(){t.prototype.destroy.call(this);for(var e=0;e<this.graphicsData.length;++e)this.graphicsData[e].destroy();this.points.length=0,this.points=null,this.colors.length=0,this.colors=null,this.uvs.length=0,this.uvs=null,this.indices.length=0,this.indices=null,this.indexBuffer.destroy(),this.indexBuffer=null,this.graphicsData.length=0,this.graphicsData=null,this.drawCalls.length=0,this.drawCalls=null,this.batches.length=0,this.batches=null,this._bounds=null},e.prototype.containsPoint=function(t){for(var e=this.graphicsData,n=0;n<e.length;++n){var r=e[n];if(r.fillStyle.visible&&(r.shape&&(r.matrix?r.matrix.applyInverse(t,ln):ln.copyFrom(t),r.shape.contains(ln.x,ln.y)))){var i=!1;if(r.holes)for(var o=0;o<r.holes.length;o++){var s=r.holes[o];if(s.shape.contains(ln.x,ln.y)){i=!0;break}}if(!i)return!0}}return!1},e.prototype.updateBatches=function(t){if(this.graphicsData.length){if(this.validateBatching()){this.cacheDirty=this.dirty;var e=this.uvs,n=this.graphicsData,r=null,i=null;this.batches.length>0&&(r=this.batches[this.batches.length-1],i=r.style);for(var o=this.shapeIndex;o<n.length;o++){this.shapeIndex++;var s=n[o],a=s.fillStyle,u=s.lineStyle,l=on[s.type];l.build(s),s.matrix&&this.transformPoints(s.points,s.matrix),(a.visible||u.visible)&&this.processHoles(s.holes);for(var c=0;c<2;c++){var h=0===c?a:u;if(h.visible){var f=h.texture.baseTexture,d=this.indices.length,p=this.points.length/2;f.wrapMode=Dt.Nt.REPEAT,0===c?this.processFill(s):this.processLine(s);var v=this.points.length/2-p;0!==v&&(r&&!this._compareStyles(i,h)&&(r.end(d,p),r=null),r||(r=sn.pop()||new rn,r.begin(h,d,p),this.batches.push(r),i=h),this.addUvs(this.points,e,h.texture,p,v,h.matrix))}}}var m=this.indices.length,g=this.points.length/2;if(r&&r.end(m,g),0!==this.batches.length){if(this.indicesUint16&&this.indices.length===this.indicesUint16.length)this.indicesUint16.set(this.indices);else{var _=g>65535&&t;this.indicesUint16=_?new Uint32Array(this.indices):new Uint16Array(this.indices)}this.batchable=this.isBatchable(),this.batchable?this.packBatches():this.buildDrawCalls()}else this.batchable=!0}}else this.batchable=!0},e.prototype._compareStyles=function(t,e){return!(!t||!e)&&(t.texture.baseTexture===e.texture.baseTexture&&(t.color+t.alpha===e.color+e.alpha&&!!t.native===!!e.native))},e.prototype.validateBatching=function(){if(this.dirty===this.cacheDirty||!this.graphicsData.length)return!1;for(var t=0,e=this.graphicsData.length;t<e;t++){var n=this.graphicsData[t],r=n.fillStyle,i=n.lineStyle;if(r&&!r.texture.baseTexture.valid)return!1;if(i&&!i.texture.baseTexture.valid)return!1}return!0},e.prototype.packBatches=function(){this.batchDirty++,this.uvsFloat32=new Float32Array(this.uvs);for(var t=this.batches,e=0,n=t.length;e<n;e++)for(var r=t[e],i=0;i<r.size;i++){var o=r.start+i;this.indicesUint16[o]=this.indicesUint16[o]-r.attribStart}},e.prototype.isBatchable=function(){if(this.points.length>131070)return!1;for(var t=this.batches,n=0;n<t.length;n++)if(t[n].style.native)return!1;return this.points.length<2*e.BATCHABLE_SIZE},e.prototype.buildDrawCalls=function(){for(var t=++J.VL._globalBatch,e=0;e<this.drawCalls.length;e++)this.drawCalls[e].texArray.clear(),an.push(this.drawCalls[e]);this.drawCalls.length=0;var n=this.colors,r=this.textureIds,i=an.pop();i||(i=new J.a$,i.texArray=new J.Ie),i.texArray.count=0,i.start=0,i.size=0,i.type=Dt.lg.TRIANGLES;var o=0,s=null,a=0,u=!1,l=Dt.lg.TRIANGLES,c=0;this.drawCalls.push(i);for(e=0;e<this.batches.length;e++){var h=this.batches[e],f=8,d=h.style,p=d.texture.baseTexture;u!==!!d.native&&(u=!!d.native,l=u?Dt.lg.LINES:Dt.lg.TRIANGLES,s=null,o=f,t++),s!==p&&(s=p,p._batchEnabled!==t&&(o===f&&(t++,o=0,i.size>0&&(i=an.pop(),i||(i=new J.a$,i.texArray=new J.Ie),this.drawCalls.push(i)),i.start=c,i.size=0,i.texArray.count=0,i.type=l),p.touched=1,p._batchEnabled=t,p._batchLocation=o,p.wrapMode=Dt.Nt.REPEAT,i.texArray.elements[i.texArray.count++]=p,o++)),i.size+=h.size,c+=h.size,a=p._batchLocation,this.addColors(n,d.color,d.alpha,h.attribSize,h.attribStart),this.addTextureIds(r,a,h.attribSize,h.attribStart)}J.VL._globalBatch=t,this.packAttributes()},e.prototype.packAttributes=function(){for(var t=this.points,e=this.uvs,n=this.colors,r=this.textureIds,i=new ArrayBuffer(3*t.length*4),o=new Float32Array(i),s=new Uint32Array(i),a=0,u=0;u<t.length/2;u++)o[a++]=t[2*u],o[a++]=t[2*u+1],o[a++]=e[2*u],o[a++]=e[2*u+1],s[a++]=n[u],o[a++]=r[u];this._buffer.update(i),this._indexBuffer.update(this.indicesUint16)},e.prototype.processFill=function(t){if(t.holes.length)Xe.triangulate(t,this);else{var e=on[t.type];e.triangulate(t,this)}},e.prototype.processLine=function(t){Ze(t,this);for(var e=0;e<t.holes.length;e++)Ze(t.holes[e],this)},e.prototype.processHoles=function(t){for(var e=0;e<t.length;e++){var n=t[e],r=on[n.type];r.build(n),n.matrix&&this.transformPoints(n.points,n.matrix)}},e.prototype.calculateBounds=function(){var t=this._bounds,e=cn,n=k.y3.IDENTITY;this._bounds.clear(),e.clear();for(var r=0;r<this.graphicsData.length;r++){var i=this.graphicsData[r],o=i.shape,s=i.type,a=i.lineStyle,u=i.matrix||k.y3.IDENTITY,l=0;if(a&&a.visible&&(l=a.width*Math.max(0,a.alignment)),n!==u&&(e.isEmpty()||(t.addBoundsMatrix(e,n),e.clear()),n=u),s===k.HS.RECT||s===k.HS.RREC){var c=o;e.addFramePad(c.x,c.y,c.x+c.width,c.y+c.height,l,l)}else if(s===k.HS.CIRC){var h=o;e.addFramePad(h.x,h.y,h.x,h.y,h.radius+l,h.radius+l)}else if(s===k.HS.ELIP){var f=o;e.addFramePad(f.x,f.y,f.x,f.y,f.width+l,f.height+l)}else{var d=o;t.addVerticesMatrix(n,d.points,0,d.points.length,l,l)}}e.isEmpty()||t.addBoundsMatrix(e,n),t.pad(this.boundsPadding,this.boundsPadding)},e.prototype.transformPoints=function(t,e){for(var n=0;n<t.length/2;n++){var r=t[2*n],i=t[2*n+1];t[2*n]=e.a*r+e.c*i+e.tx,t[2*n+1]=e.b*r+e.d*i+e.ty}},e.prototype.addColors=function(t,e,n,r,i){void 0===i&&(i=0);var o=(e>>16)+(65280&e)+((255&e)<<16),s=(0,O.rA)(o,n);t.length=Math.max(t.length,i+r);for(var a=0;a<r;a++)t[i+a]=s},e.prototype.addTextureIds=function(t,e,n,r){void 0===r&&(r=0),t.length=Math.max(t.length,r+n);for(var i=0;i<n;i++)t[r+i]=e},e.prototype.addUvs=function(t,e,n,r,i,o){void 0===o&&(o=null);var s=0,a=e.length,u=n.frame;while(s<i){var l=t[2*(r+s)],c=t[2*(r+s)+1];if(o){var h=o.a*l+o.c*c+o.tx;c=o.b*l+o.d*c+o.ty,l=h}s++,e.push(l/u.width,c/u.height)}var f=n.baseTexture;(u.width<f.width||u.height<f.height)&&this.adjustUvs(e,n,a,i)},e.prototype.adjustUvs=function(t,e,n,r){for(var i=e.baseTexture,o=1e-6,s=n+2*r,a=e.frame,u=a.width/i.width,l=a.height/i.height,c=a.x/a.width,h=a.y/a.height,f=Math.floor(t[n]+o),d=Math.floor(t[n+1]+o),p=n+2;p<s;p+=2)f=Math.min(f,Math.floor(t[p]+o)),d=Math.min(d,Math.floor(t[p+1]+o));c-=f,h-=d;for(p=n;p<s;p+=2)t[p]=(t[p]+c)*u,t[p+1]=(t[p+1]+h)*l},e.BATCHABLE_SIZE=100,e}(J.JZ),fn=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.width=0,e.alignment=.5,e.native=!1,e.cap=Pe.BUTT,e.join=Ie.MITER,e.miterLimit=10,e}return Ge(e,t),e.prototype.clone=function(){var t=new e;return t.color=this.color,t.alpha=this.alpha,t.texture=this.texture,t.matrix=this.matrix,t.visible=this.visible,t.width=this.width,t.alignment=this.alignment,t.native=this.native,t.cap=this.cap,t.join=this.join,t.miterLimit=this.miterLimit,t},e.prototype.reset=function(){t.prototype.reset.call(this),this.color=0,this.alignment=.5,this.width=0,this.native=!1},e}(Be),dn=new Float32Array(3),pn={},vn=function(t){function e(e){void 0===e&&(e=null);var n=t.call(this)||this;return n.shader=null,n.pluginName="batch",n.currentPath=null,n.batches=[],n.batchTint=-1,n.batchDirty=-1,n.vertexData=null,n._fillStyle=new Be,n._lineStyle=new fn,n._matrix=null,n._holeMode=!1,n.state=J.ZM.for2d(),n._geometry=e||new hn,n._geometry.refCount++,n._transformID=-1,n.tint=16777215,n.blendMode=Dt.T$.NORMAL,n}return Ge(e,t),Object.defineProperty(e.prototype,"geometry",{get:function(){return this._geometry},enumerable:!1,configurable:!0}),e.prototype.clone=function(){return this.finishPoly(),new e(this._geometry)},Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.state.blendMode},set:function(t){this.state.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){this._tint=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fill",{get:function(){return this._fillStyle},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"line",{get:function(){return this._lineStyle},enumerable:!1,configurable:!0}),e.prototype.lineStyle=function(t,e,n,r,i){return void 0===t&&(t=null),void 0===e&&(e=0),void 0===n&&(n=1),void 0===r&&(r=.5),void 0===i&&(i=!1),"number"===typeof t&&(t={width:t,color:e,alpha:n,alignment:r,native:i}),this.lineTextureStyle(t)},e.prototype.lineTextureStyle=function(t){t=Object.assign({width:0,texture:J.xE.WHITE,color:t&&t.texture?16777215:0,alpha:1,matrix:null,alignment:.5,native:!1,cap:Pe.BUTT,join:Ie.MITER,miterLimit:10},t),this.currentPath&&this.startPoly();var e=t.width>0&&t.alpha>0;return e?(t.matrix&&(t.matrix=t.matrix.clone(),t.matrix.invert()),Object.assign(this._lineStyle,{visible:e},t)):this._lineStyle.reset(),this},e.prototype.startPoly=function(){if(this.currentPath){var t=this.currentPath.points,e=this.currentPath.points.length;e>2&&(this.drawShape(this.currentPath),this.currentPath=new k.mg,this.currentPath.closeStroke=!1,this.currentPath.points.push(t[e-2],t[e-1]))}else this.currentPath=new k.mg,this.currentPath.closeStroke=!1},e.prototype.finishPoly=function(){this.currentPath&&(this.currentPath.points.length>2?(this.drawShape(this.currentPath),this.currentPath=null):this.currentPath.points.length=0)},e.prototype.moveTo=function(t,e){return this.startPoly(),this.currentPath.points[0]=t,this.currentPath.points[1]=e,this},e.prototype.lineTo=function(t,e){this.currentPath||this.moveTo(0,0);var n=this.currentPath.points,r=n[n.length-2],i=n[n.length-1];return r===t&&i===e||n.push(t,e),this},e.prototype._initCurve=function(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.currentPath?0===this.currentPath.points.length&&(this.currentPath.points=[t,e]):this.moveTo(t,e)},e.prototype.quadraticCurveTo=function(t,e,n,r){this._initCurve();var i=this.currentPath.points;return 0===i.length&&this.moveTo(0,0),nn.curveTo(t,e,n,r,i),this},e.prototype.bezierCurveTo=function(t,e,n,r,i,o){return this._initCurve(),en.curveTo(t,e,n,r,i,o,this.currentPath.points),this},e.prototype.arcTo=function(t,e,n,r,i){this._initCurve(t,e);var o=this.currentPath.points,s=tn.curveTo(t,e,n,r,i,o);if(s){var a=s.cx,u=s.cy,l=s.radius,c=s.startAngle,h=s.endAngle,f=s.anticlockwise;this.arc(a,u,l,c,h,f)}return this},e.prototype.arc=function(t,e,n,r,i,o){if(void 0===o&&(o=!1),r===i)return this;!o&&i<=r?i+=k._b:o&&r<=i&&(r+=k._b);var s=i-r;if(0===s)return this;var a=t+Math.cos(r)*n,u=e+Math.sin(r)*n,l=this._geometry.closePointEps,c=this.currentPath?this.currentPath.points:null;if(c){var h=Math.abs(c[c.length-2]-a),f=Math.abs(c[c.length-1]-u);h<l&&f<l||c.push(a,u)}else this.moveTo(a,u),c=this.currentPath.points;return tn.arc(a,u,t,e,n,r,i,o,c),this},e.prototype.beginFill=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=1),this.beginTextureFill({texture:J.xE.WHITE,color:t,alpha:e})},e.prototype.beginTextureFill=function(t){t=Object.assign({texture:J.xE.WHITE,color:16777215,alpha:1,matrix:null},t),this.currentPath&&this.startPoly();var e=t.alpha>0;return e?(t.matrix&&(t.matrix=t.matrix.clone(),t.matrix.invert()),Object.assign(this._fillStyle,{visible:e},t)):this._fillStyle.reset(),this},e.prototype.endFill=function(){return this.finishPoly(),this._fillStyle.reset(),this},e.prototype.drawRect=function(t,e,n,r){return this.drawShape(new k.Ae(t,e,n,r))},e.prototype.drawRoundedRect=function(t,e,n,r,i){return this.drawShape(new k.c9(t,e,n,r,i))},e.prototype.drawCircle=function(t,e,n){return this.drawShape(new k.Cd(t,e,n))},e.prototype.drawEllipse=function(t,e,n,r){return this.drawShape(new k.Pj(t,e,n,r))},e.prototype.drawPolygon=function(){for(var t,e=arguments,n=[],r=0;r<arguments.length;r++)n[r]=e[r];var i=!0,o=n[0];o.points?(i=o.closeStroke,t=o.points):t=Array.isArray(n[0])?n[0]:n;var s=new k.mg(t);return s.closeStroke=i,this.drawShape(s),this},e.prototype.drawShape=function(t){return this._holeMode?this._geometry.drawHole(t,this._matrix):this._geometry.drawShape(t,this._fillStyle.clone(),this._lineStyle.clone(),this._matrix),this},e.prototype.clear=function(){return this._geometry.clear(),this._lineStyle.reset(),this._fillStyle.reset(),this._boundsID++,this._matrix=null,this._holeMode=!1,this.currentPath=null,this},e.prototype.isFastRect=function(){var t=this._geometry.graphicsData;return 1===t.length&&t[0].shape.type===k.HS.RECT&&!t[0].matrix&&!t[0].holes.length&&!(t[0].lineStyle.visible&&t[0].lineStyle.width)},e.prototype._render=function(t){this.finishPoly();var e=this._geometry,n=t.context.supports.uint32Indices;e.updateBatches(n),e.batchable?(this.batchDirty!==e.batchDirty&&this._populateBatches(),this._renderBatched(t)):(t.batch.flush(),this._renderDirect(t))},e.prototype._populateBatches=function(){var t=this._geometry,e=this.blendMode,n=t.batches.length;this.batchTint=-1,this._transformID=-1,this.batchDirty=t.batchDirty,this.batches.length=n,this.vertexData=new Float32Array(t.points);for(var r=0;r<n;r++){var i=t.batches[r],o=i.style.color,s=new Float32Array(this.vertexData.buffer,4*i.attribStart*2,2*i.attribSize),a=new Float32Array(t.uvsFloat32.buffer,4*i.attribStart*2,2*i.attribSize),u=new Uint16Array(t.indicesUint16.buffer,2*i.start,i.size),l={vertexData:s,blendMode:e,indices:u,uvs:a,_batchRGB:(0,O.wK)(o),_tintRGB:o,_texture:i.style.texture,alpha:i.style.alpha,worldAlpha:1};this.batches[r]=l}},e.prototype._renderBatched=function(t){if(this.batches.length){t.batch.setObjectRenderer(t.plugins[this.pluginName]),this.calculateVertices(),this.calculateTints();for(var e=0,n=this.batches.length;e<n;e++){var r=this.batches[e];r.worldAlpha=this.worldAlpha*r.alpha,t.plugins[this.pluginName].render(r)}}},e.prototype._renderDirect=function(t){var e=this._resolveDirectShader(t),n=this._geometry,r=this.tint,i=this.worldAlpha,o=e.uniforms,s=n.drawCalls;o.translationMatrix=this.transform.worldTransform,o.tint[0]=(r>>16&255)/255*i,o.tint[1]=(r>>8&255)/255*i,o.tint[2]=(255&r)/255*i,o.tint[3]=i,t.shader.bind(e),t.geometry.bind(n,e),t.state.set(this.state);for(var a=0,u=s.length;a<u;a++)this._renderDrawCallDirect(t,n.drawCalls[a])},e.prototype._renderDrawCallDirect=function(t,e){for(var n=e.texArray,r=e.type,i=e.size,o=e.start,s=n.count,a=0;a<s;a++)t.texture.bind(n.elements[a],a);t.geometry.draw(r,i,o)},e.prototype._resolveDirectShader=function(t){var e=this.shader,n=this.pluginName;if(!e){if(!pn[n]){for(var r=t.plugins.batch.MAX_TEXTURES,i=new Int32Array(r),o=0;o<r;o++)i[o]=o;var s={tint:new Float32Array([1,1,1,1]),translationMatrix:new k.y3,default:J.oo.from({uSamplers:i},!0)},a=t.plugins[n]._shader.program;pn[n]=new J.ex(a,s)}e=pn[n]}return e},e.prototype._calculateBounds=function(){this.finishPoly();var t=this._geometry;if(t.graphicsData.length){var e=t.bounds,n=e.minX,r=e.minY,i=e.maxX,o=e.maxY;this._bounds.addFrame(this.transform,n,r,i,o)}},e.prototype.containsPoint=function(t){return this.worldTransform.applyInverse(t,e._TEMP_POINT),this._geometry.containsPoint(e._TEMP_POINT)},e.prototype.calculateTints=function(){if(this.batchTint!==this.tint){this.batchTint=this.tint;for(var t=(0,O.wK)(this.tint,dn),e=0;e<this.batches.length;e++){var n=this.batches[e],r=n._batchRGB,i=t[0]*r[0]*255,o=t[1]*r[1]*255,s=t[2]*r[2]*255,a=(i<<16)+(o<<8)+(0|s);n._tintRGB=(a>>16)+(65280&a)+((255&a)<<16)}}},e.prototype.calculateVertices=function(){var t=this.transform._worldID;if(this._transformID!==t){this._transformID=t;for(var e=this.transform.worldTransform,n=e.a,r=e.b,i=e.c,o=e.d,s=e.tx,a=e.ty,u=this._geometry.points,l=this.vertexData,c=0,h=0;h<u.length;h+=2){var f=u[h],d=u[h+1];l[c++]=n*f+i*d+s,l[c++]=o*d+r*f+a}}},e.prototype.closePath=function(){var t=this.currentPath;return t&&(t.closeStroke=!0,this.finishPoly()),this},e.prototype.setMatrix=function(t){return this._matrix=t,this},e.prototype.beginHole=function(){return this.finishPoly(),this._holeMode=!0,this},e.prototype.endHole=function(){return this.finishPoly(),this._holeMode=!1,this},e.prototype.destroy=function(e){this._geometry.refCount--,0===this._geometry.refCount&&this._geometry.dispose(),this._matrix=null,this.currentPath=null,this._lineStyle.destroy(),this._lineStyle=null,this._fillStyle.destroy(),this._fillStyle=null,this._geometry=null,this.shader=null,this.vertexData=null,this.batches.length=0,this.batches=null,t.prototype.destroy.call(this,e)},e.nextRoundedRectBehavior=!1,e._TEMP_POINT=new k.E9,e}(w.W2),mn=n(8033),gn=function(t,e){return gn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},gn(t,e)};function _n(t,e){function n(){this.constructor=t}gn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}(function(t){t[t["LINEAR_VERTICAL"]=0]="LINEAR_VERTICAL",t[t["LINEAR_HORIZONTAL"]=1]="LINEAR_HORIZONTAL"})(Qe||(Qe={}));var yn={align:"left",breakWords:!1,dropShadow:!1,dropShadowAlpha:1,dropShadowAngle:Math.PI/6,dropShadowBlur:0,dropShadowColor:"black",dropShadowDistance:5,fill:"black",fillGradientType:Qe.LINEAR_VERTICAL,fillGradientStops:[],fontFamily:"Arial",fontSize:26,fontStyle:"normal",fontVariant:"normal",fontWeight:"normal",letterSpacing:0,lineHeight:0,lineJoin:"miter",miterLimit:10,padding:0,stroke:"black",strokeThickness:0,textBaseline:"alphabetic",trim:!1,whiteSpace:"pre",wordWrap:!1,wordWrapWidth:100,leading:0},bn=["serif","sans-serif","monospace","cursive","fantasy","system-ui"],En=function(){function t(t){this.styleID=0,this.reset(),Rn(this,t,t)}return t.prototype.clone=function(){var e={};return Rn(e,this,yn),new t(e)},t.prototype.reset=function(){Rn(this,yn,yn)},Object.defineProperty(t.prototype,"align",{get:function(){return this._align},set:function(t){this._align!==t&&(this._align=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"breakWords",{get:function(){return this._breakWords},set:function(t){this._breakWords!==t&&(this._breakWords=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadow",{get:function(){return this._dropShadow},set:function(t){this._dropShadow!==t&&(this._dropShadow=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowAlpha",{get:function(){return this._dropShadowAlpha},set:function(t){this._dropShadowAlpha!==t&&(this._dropShadowAlpha=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowAngle",{get:function(){return this._dropShadowAngle},set:function(t){this._dropShadowAngle!==t&&(this._dropShadowAngle=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowBlur",{get:function(){return this._dropShadowBlur},set:function(t){this._dropShadowBlur!==t&&(this._dropShadowBlur=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowColor",{get:function(){return this._dropShadowColor},set:function(t){var e=Tn(t);this._dropShadowColor!==e&&(this._dropShadowColor=e,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowDistance",{get:function(){return this._dropShadowDistance},set:function(t){this._dropShadowDistance!==t&&(this._dropShadowDistance=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fill",{get:function(){return this._fill},set:function(t){var e=Tn(t);this._fill!==e&&(this._fill=e,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fillGradientType",{get:function(){return this._fillGradientType},set:function(t){this._fillGradientType!==t&&(this._fillGradientType=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fillGradientStops",{get:function(){return this._fillGradientStops},set:function(t){Sn(this._fillGradientStops,t)||(this._fillGradientStops=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontFamily",{get:function(){return this._fontFamily},set:function(t){this.fontFamily!==t&&(this._fontFamily=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontSize",{get:function(){return this._fontSize},set:function(t){this._fontSize!==t&&(this._fontSize=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontStyle",{get:function(){return this._fontStyle},set:function(t){this._fontStyle!==t&&(this._fontStyle=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontVariant",{get:function(){return this._fontVariant},set:function(t){this._fontVariant!==t&&(this._fontVariant=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontWeight",{get:function(){return this._fontWeight},set:function(t){this._fontWeight!==t&&(this._fontWeight=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"letterSpacing",{get:function(){return this._letterSpacing},set:function(t){this._letterSpacing!==t&&(this._letterSpacing=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lineHeight",{get:function(){return this._lineHeight},set:function(t){this._lineHeight!==t&&(this._lineHeight=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"leading",{get:function(){return this._leading},set:function(t){this._leading!==t&&(this._leading=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lineJoin",{get:function(){return this._lineJoin},set:function(t){this._lineJoin!==t&&(this._lineJoin=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"miterLimit",{get:function(){return this._miterLimit},set:function(t){this._miterLimit!==t&&(this._miterLimit=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"padding",{get:function(){return this._padding},set:function(t){this._padding!==t&&(this._padding=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke",{get:function(){return this._stroke},set:function(t){var e=Tn(t);this._stroke!==e&&(this._stroke=e,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"strokeThickness",{get:function(){return this._strokeThickness},set:function(t){this._strokeThickness!==t&&(this._strokeThickness=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textBaseline",{get:function(){return this._textBaseline},set:function(t){this._textBaseline!==t&&(this._textBaseline=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"trim",{get:function(){return this._trim},set:function(t){this._trim!==t&&(this._trim=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"whiteSpace",{get:function(){return this._whiteSpace},set:function(t){this._whiteSpace!==t&&(this._whiteSpace=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"wordWrap",{get:function(){return this._wordWrap},set:function(t){this._wordWrap!==t&&(this._wordWrap=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"wordWrapWidth",{get:function(){return this._wordWrapWidth},set:function(t){this._wordWrapWidth!==t&&(this._wordWrapWidth=t,this.styleID++)},enumerable:!1,configurable:!0}),t.prototype.toFontString=function(){var t="number"===typeof this.fontSize?this.fontSize+"px":this.fontSize,e=this.fontFamily;Array.isArray(this.fontFamily)||(e=this.fontFamily.split(","));for(var n=e.length-1;n>=0;n--){var r=e[n].trim();!/([\"\'])[^\'\"]+\1/.test(r)&&bn.indexOf(r)<0&&(r='"'+r+'"'),e[n]=r}return this.fontStyle+" "+this.fontVariant+" "+this.fontWeight+" "+t+" "+e.join(",")},t}();function xn(t){return"number"===typeof t?(0,O.XN)(t):("string"===typeof t&&0===t.indexOf("0x")&&(t=t.replace("0x","#")),t)}function Tn(t){if(Array.isArray(t)){for(var e=0;e<t.length;++e)t[e]=xn(t[e]);return t}return xn(t)}function Sn(t,e){if(!Array.isArray(t)||!Array.isArray(e))return!1;if(t.length!==e.length)return!1;for(var n=0;n<t.length;++n)if(t[n]!==e[n])return!1;return!0}function Rn(t,e,n){for(var r in n)Array.isArray(e[r])?t[r]=e[r].slice():t[r]=e[r]}var An=function(){function t(t,e,n,r,i,o,s,a,u){this.text=t,this.style=e,this.width=n,this.height=r,this.lines=i,this.lineWidths=o,this.lineHeight=s,this.maxLineWidth=a,this.fontProperties=u}return t.measureText=function(e,n,r,i){void 0===i&&(i=t._canvas),r=void 0===r||null===r?n.wordWrap:r;var o=n.toFontString(),s=t.measureFont(o);0===s.fontSize&&(s.fontSize=n.fontSize,s.ascent=n.fontSize);var a=i.getContext("2d");a.font=o;for(var u=r?t.wordWrap(e,n,i):e,l=u.split(/(?:\r\n|\r|\n)/),c=new Array(l.length),h=0,f=0;f<l.length;f++){var d=a.measureText(l[f]).width+(l[f].length-1)*n.letterSpacing;c[f]=d,h=Math.max(h,d)}var p=h+n.strokeThickness;n.dropShadow&&(p+=n.dropShadowDistance);var v=n.lineHeight||s.fontSize+n.strokeThickness,m=Math.max(v,s.fontSize+n.strokeThickness)+(l.length-1)*(v+n.leading);return n.dropShadow&&(m+=n.dropShadowDistance),new t(e,n,p,m,l,c,v+n.leading,h,s)},t.wordWrap=function(e,n,r){void 0===r&&(r=t._canvas);for(var i=r.getContext("2d"),o=0,s="",a="",u=Object.create(null),l=n.letterSpacing,c=n.whiteSpace,h=t.collapseSpaces(c),f=t.collapseNewlines(c),d=!h,p=n.wordWrapWidth+l,v=t.tokenize(e),m=0;m<v.length;m++){var g=v[m];if(t.isNewline(g)){if(!f){a+=t.addLine(s),d=!h,s="",o=0;continue}g=" "}if(h){var _=t.isBreakingSpace(g),y=t.isBreakingSpace(s[s.length-1]);if(_&&y)continue}var b=t.getFromCache(g,l,u,i);if(b>p)if(""!==s&&(a+=t.addLine(s),s="",o=0),t.canBreakWords(g,n.breakWords))for(var E=t.wordWrapSplit(g),x=0;x<E.length;x++){var T=E[x],S=1;while(E[x+S]){var R=E[x+S],A=T[T.length-1];if(t.canBreakChars(A,R,g,x,n.breakWords))break;T+=R,S++}x+=T.length-1;var O=t.getFromCache(T,l,u,i);O+o>p&&(a+=t.addLine(s),d=!1,s="",o=0),s+=T,o+=O}else{s.length>0&&(a+=t.addLine(s),s="",o=0);var w=m===v.length-1;a+=t.addLine(g,!w),d=!1,s="",o=0}else b+o>p&&(d=!1,a+=t.addLine(s),s="",o=0),(s.length>0||!t.isBreakingSpace(g)||d)&&(s+=g,o+=b)}return a+=t.addLine(s,!1),a},t.addLine=function(e,n){return void 0===n&&(n=!0),e=t.trimRight(e),e=n?e+"\n":e,e},t.getFromCache=function(t,e,n,r){var i=n[t];if("number"!==typeof i){var o=t.length*e;i=r.measureText(t).width+o,n[t]=i}return i},t.collapseSpaces=function(t){return"normal"===t||"pre-line"===t},t.collapseNewlines=function(t){return"normal"===t},t.trimRight=function(e){if("string"!==typeof e)return"";for(var n=e.length-1;n>=0;n--){var r=e[n];if(!t.isBreakingSpace(r))break;e=e.slice(0,-1)}return e},t.isNewline=function(e){return"string"===typeof e&&t._newlines.indexOf(e.charCodeAt(0))>=0},t.isBreakingSpace=function(e,n){return"string"===typeof e&&t._breakingSpaces.indexOf(e.charCodeAt(0))>=0},t.tokenize=function(e){var n=[],r="";if("string"!==typeof e)return n;for(var i=0;i<e.length;i++){var o=e[i],s=e[i+1];t.isBreakingSpace(o,s)||t.isNewline(o)?(""!==r&&(n.push(r),r=""),n.push(o)):r+=o}return""!==r&&n.push(r),n},t.canBreakWords=function(t,e){return e},t.canBreakChars=function(t,e,n,r,i){return!0},t.wordWrapSplit=function(t){return t.split("")},t.measureFont=function(e){if(t._fonts[e])return t._fonts[e];var n={ascent:0,descent:0,fontSize:0},r=t._canvas,i=t._context;i.font=e;var o=t.METRICS_STRING+t.BASELINE_SYMBOL,s=Math.ceil(i.measureText(o).width),a=Math.ceil(i.measureText(t.BASELINE_SYMBOL).width),u=Math.ceil(t.HEIGHT_MULTIPLIER*a);a=a*t.BASELINE_MULTIPLIER|0,r.width=s,r.height=u,i.fillStyle="#f00",i.fillRect(0,0,s,u),i.font=e,i.textBaseline="alphabetic",i.fillStyle="#000",i.fillText(o,0,a);var l=i.getImageData(0,0,s,u).data,c=l.length,h=4*s,f=0,d=0,p=!1;for(f=0;f<a;++f){for(var v=0;v<h;v+=4)if(255!==l[d+v]){p=!0;break}if(p)break;d+=h}for(n.ascent=a-f,d=c-h,p=!1,f=u;f>a;--f){for(v=0;v<h;v+=4)if(255!==l[d+v]){p=!0;break}if(p)break;d-=h}return n.descent=f-a,n.fontSize=n.ascent+n.descent,t._fonts[e]=n,n},t.clearMetrics=function(e){void 0===e&&(e=""),e?delete t._fonts[e]:t._fonts={}},t}(),On=function(){try{var t=new OffscreenCanvas(0,0),e=t.getContext("2d");return e&&e.measureText?t:document.createElement("canvas")}catch(n){return document.createElement("canvas")}}();On.width=On.height=10,An._canvas=On,An._context=On.getContext("2d"),An._fonts={},An.METRICS_STRING="|ÉqÅ",An.BASELINE_SYMBOL="M",An.BASELINE_MULTIPLIER=1.4,An.HEIGHT_MULTIPLIER=2,An._newlines=[10,13],An._breakingSpaces=[9,32,8192,8193,8194,8195,8196,8197,8198,8200,8201,8202,8287,12288];var wn={texture:!0,children:!1,baseTexture:!0},In=function(t){function e(e,n,r){var i=this,o=!1;r||(r=document.createElement("canvas"),o=!0),r.width=3,r.height=3;var s=J.xE.from(r);return s.orig=new k.Ae,s.trim=new k.Ae,i=t.call(this,s)||this,i._ownCanvas=o,i.canvas=r,i.context=i.canvas.getContext("2d"),i._resolution=Le.X.RESOLUTION,i._autoResolution=!0,i._text=null,i._style=null,i._styleListener=null,i._font="",i.text=e,i.style=n,i.localStyleID=-1,i}return _n(e,t),e.prototype.updateText=function(t){var n=this._style;if(this.localStyleID!==n.styleID&&(this.dirty=!0,this.localStyleID=n.styleID),this.dirty||!t){this._font=this._style.toFontString();var r,i,o=this.context,s=An.measureText(this._text||" ",this._style,this._style.wordWrap,this.canvas),a=s.width,u=s.height,l=s.lines,c=s.lineHeight,h=s.lineWidths,f=s.maxLineWidth,d=s.fontProperties;this.canvas.width=Math.ceil(Math.ceil(Math.max(1,a)+2*n.padding)*this._resolution),this.canvas.height=Math.ceil(Math.ceil(Math.max(1,u)+2*n.padding)*this._resolution),o.scale(this._resolution,this._resolution),o.clearRect(0,0,this.canvas.width,this.canvas.height),o.font=this._font,o.lineWidth=n.strokeThickness,o.textBaseline=n.textBaseline,o.lineJoin=n.lineJoin,o.miterLimit=n.miterLimit;for(var p=n.dropShadow?2:1,v=0;v<p;++v){var m=n.dropShadow&&0===v,g=m?Math.ceil(Math.max(1,u)+2*n.padding):0,_=g*this._resolution;if(m){o.fillStyle="black",o.strokeStyle="black";var y=n.dropShadowColor,b=(0,O.wK)("number"===typeof y?y:(0,O.qm)(y)),E=n.dropShadowBlur*this._resolution,x=n.dropShadowDistance*this._resolution;o.shadowColor="rgba("+255*b[0]+","+255*b[1]+","+255*b[2]+","+n.dropShadowAlpha+")",o.shadowBlur=E,o.shadowOffsetX=Math.cos(n.dropShadowAngle)*x,o.shadowOffsetY=Math.sin(n.dropShadowAngle)*x+_}else o.fillStyle=this._generateFillStyle(n,l,s),o.strokeStyle=n.stroke,o.shadowColor="black",o.shadowBlur=0,o.shadowOffsetX=0,o.shadowOffsetY=0;var T=(c-d.fontSize)/2;(!e.nextLineHeightBehavior||c-d.fontSize<0)&&(T=0);for(var S=0;S<l.length;S++)r=n.strokeThickness/2,i=n.strokeThickness/2+S*c+d.ascent+T,"right"===n.align?r+=f-h[S]:"center"===n.align&&(r+=(f-h[S])/2),n.stroke&&n.strokeThickness&&this.drawLetterSpacing(l[S],r+n.padding,i+n.padding-g,!0),n.fill&&this.drawLetterSpacing(l[S],r+n.padding,i+n.padding-g)}this.updateTexture()}},e.prototype.drawLetterSpacing=function(t,n,r,i){void 0===i&&(i=!1);var o=this._style,s=o.letterSpacing,a=e.experimentalLetterSpacing&&("letterSpacing"in CanvasRenderingContext2D.prototype||"textLetterSpacing"in CanvasRenderingContext2D.prototype);if(0===s||a)return a&&(this.context.letterSpacing=s,this.context.textLetterSpacing=s),void(i?this.context.strokeText(t,n,r):this.context.fillText(t,n,r));for(var u=n,l=Array.from?Array.from(t):t.split(""),c=this.context.measureText(t).width,h=0,f=0;f<l.length;++f){var d=l[f];i?this.context.strokeText(d,u,r):this.context.fillText(d,u,r);for(var p="",v=f+1;v<l.length;++v)p+=l[v];h=this.context.measureText(p).width,u+=c-h+s,c=h}},e.prototype.updateTexture=function(){var t=this.canvas;if(this._style.trim){var e=(0,O.yA)(t);e.data&&(t.width=e.width,t.height=e.height,this.context.putImageData(e.data,0,0))}var n=this._texture,r=this._style,i=r.trim?0:r.padding,o=n.baseTexture;n.trim.width=n._frame.width=t.width/this._resolution,n.trim.height=n._frame.height=t.height/this._resolution,n.trim.x=-i,n.trim.y=-i,n.orig.width=n._frame.width-2*i,n.orig.height=n._frame.height-2*i,this._onTextureUpdate(),o.setRealSize(t.width,t.height,this._resolution),n.updateUvs(),this._recursivePostUpdateTransform(),this.dirty=!1},e.prototype._render=function(e){this._autoResolution&&this._resolution!==e.resolution&&(this._resolution=e.resolution,this.dirty=!0),this.updateText(!0),t.prototype._render.call(this,e)},e.prototype.getLocalBounds=function(e){return this.updateText(!0),t.prototype.getLocalBounds.call(this,e)},e.prototype._calculateBounds=function(){this.updateText(!0),this.calculateVertices(),this._bounds.addQuad(this.vertexData)},e.prototype._generateFillStyle=function(t,e,n){var r,i=t.fill;if(!Array.isArray(i))return i;if(1===i.length)return i[0];var o=t.dropShadow?t.dropShadowDistance:0,s=t.padding||0,a=this.canvas.width/this._resolution-o-2*s,u=this.canvas.height/this._resolution-o-2*s,l=i.slice(),c=t.fillGradientStops.slice();if(!c.length)for(var h=l.length+1,f=1;f<h;++f)c.push(f/h);if(l.unshift(i[0]),c.unshift(0),l.push(i[i.length-1]),c.push(1),t.fillGradientType===Qe.LINEAR_VERTICAL){r=this.context.createLinearGradient(a/2,s,a/2,u+s);var d=n.fontProperties.fontSize+t.strokeThickness;for(f=0;f<e.length;f++){var p=n.lineHeight*(f-1)+d,v=n.lineHeight*f,m=v;f>0&&p>v&&(m=(v+p)/2);var g=v+d,_=n.lineHeight*(f+1),y=g;f+1<e.length&&_<g&&(y=(g+_)/2);for(var b=(y-m)/u,E=0;E<l.length;E++){var x=0;x="number"===typeof c[E]?c[E]:E/l.length;var T=Math.min(1,Math.max(0,m/u+x*b));T=Number(T.toFixed(5)),r.addColorStop(T,l[E])}}}else{r=this.context.createLinearGradient(s,u/2,a+s,u/2);var S=l.length+1,R=1;for(f=0;f<l.length;f++){var A=void 0;A="number"===typeof c[f]?c[f]:R/S,r.addColorStop(A,l[f]),R++}}return r},e.prototype.destroy=function(e){"boolean"===typeof e&&(e={children:e}),e=Object.assign({},wn,e),t.prototype.destroy.call(this,e),this._ownCanvas&&(this.canvas.height=this.canvas.width=0),this.context=null,this.canvas=null,this._style=null},Object.defineProperty(e.prototype,"width",{get:function(){return this.updateText(!0),Math.abs(this.scale.x)*this._texture.orig.width},set:function(t){this.updateText(!0);var e=(0,O.Xx)(this.scale.x)||1;this.scale.x=e*t/this._texture.orig.width,this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.updateText(!0),Math.abs(this.scale.y)*this._texture.orig.height},set:function(t){this.updateText(!0);var e=(0,O.Xx)(this.scale.y)||1;this.scale.y=e*t/this._texture.orig.height,this._height=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"style",{get:function(){return this._style},set:function(t){t=t||{},this._style=t instanceof En?t:new En(t),this.localStyleID=-1,this.dirty=!0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this._text},set:function(t){t=String(null===t||void 0===t?"":t),this._text!==t&&(this._text=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"resolution",{get:function(){return this._resolution},set:function(t){this._autoResolution=!1,this._resolution!==t&&(this._resolution=t,this.dirty=!0)},enumerable:!1,configurable:!0}),e.nextLineHeightBehavior=!1,e.experimentalLetterSpacing=!1,e}(mn.j); -/*! - * @pixi/prepare - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/prepare is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -Le.X.UPLOADS_PER_FRAME=4; -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ -var Pn=function(t,e){return Pn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Pn(t,e)};function Cn(t,e){function n(){this.constructor=t}Pn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Nn=function(){function t(t){this.maxItemsPerFrame=t,this.itemsLeft=0}return t.prototype.beginFrame=function(){this.itemsLeft=this.maxItemsPerFrame},t.prototype.allowedToUpload=function(){return this.itemsLeft-- >0},t}();function Mn(t,e){var n=!1;if(t&&t._textures&&t._textures.length)for(var r=0;r<t._textures.length;r++)if(t._textures[r]instanceof J.xE){var i=t._textures[r].baseTexture;-1===e.indexOf(i)&&(e.push(i),n=!0)}return n}function Dn(t,e){if(t.baseTexture instanceof J.VL){var n=t.baseTexture;return-1===e.indexOf(n)&&e.push(n),!0}return!1}function Ln(t,e){if(t._texture&&t._texture instanceof J.xE){var n=t._texture.baseTexture;return-1===e.indexOf(n)&&e.push(n),!0}return!1}function Fn(t,e){return e instanceof In&&(e.updateText(!0),!0)}function Bn(t,e){if(e instanceof En){var n=e.toFontString();return An.measureFont(n),!0}return!1}function Un(t,e){if(t instanceof In){-1===e.indexOf(t.style)&&e.push(t.style),-1===e.indexOf(t)&&e.push(t);var n=t._texture.baseTexture;return-1===e.indexOf(n)&&e.push(n),!0}return!1}function Gn(t,e){return t instanceof En&&(-1===e.indexOf(t)&&e.push(t),!0)}var kn=function(){function t(t){var e=this;this.limiter=new Nn(Le.X.UPLOADS_PER_FRAME),this.renderer=t,this.uploadHookHelper=null,this.queue=[],this.addHooks=[],this.uploadHooks=[],this.completes=[],this.ticking=!1,this.delayedTick=function(){e.queue&&e.prepareItems()},this.registerFindHook(Un),this.registerFindHook(Gn),this.registerFindHook(Mn),this.registerFindHook(Dn),this.registerFindHook(Ln),this.registerUploadHook(Fn),this.registerUploadHook(Bn)}return t.prototype.upload=function(t,e){"function"===typeof t&&(e=t,t=null),t&&this.add(t),this.queue.length?(e&&this.completes.push(e),this.ticking||(this.ticking=!0,X.vB.system.addOnce(this.tick,this,X.uF.UTILITY))):e&&e()},t.prototype.tick=function(){setTimeout(this.delayedTick,0)},t.prototype.prepareItems=function(){this.limiter.beginFrame();while(this.queue.length&&this.limiter.allowedToUpload()){var t=this.queue[0],e=!1;if(t&&!t._destroyed)for(var n=0,r=this.uploadHooks.length;n<r;n++)if(this.uploadHooks[n](this.uploadHookHelper,t)){this.queue.shift(),e=!0;break}e||this.queue.shift()}if(this.queue.length)X.vB.system.addOnce(this.tick,this,X.uF.UTILITY);else{this.ticking=!1;var i=this.completes.slice(0);this.completes.length=0;for(n=0,r=i.length;n<r;n++)i[n]()}},t.prototype.registerFindHook=function(t){return t&&this.addHooks.push(t),this},t.prototype.registerUploadHook=function(t){return t&&this.uploadHooks.push(t),this},t.prototype.add=function(t){for(var e=0,n=this.addHooks.length;e<n;e++)if(this.addHooks[e](t,this.queue))break;if(t instanceof w.W2)for(e=t.children.length-1;e>=0;e--)this.add(t.children[e]);return this},t.prototype.destroy=function(){this.ticking&&X.vB.system.remove(this.tick,this),this.ticking=!1,this.addHooks=null,this.uploadHooks=null,this.renderer=null,this.completes=null,this.queue=null,this.limiter=null,this.uploadHookHelper=null},t}();function Xn(t,e){return e instanceof J.VL&&(e._glTextures[t.CONTEXT_UID]||t.texture.bind(e),!0)}function jn(t,e){if(!(e instanceof vn))return!1;var n=e.geometry;e.finishPoly(),n.updateBatches();for(var r=n.batches,i=0;i<r.length;i++){var o=r[i].style.texture;o&&Xn(t,o.baseTexture)}return n.batchable||t.geometry.bind(n,e._resolveDirectShader(t)),!0}function Hn(t,e){return t instanceof vn&&(e.push(t),!0)}var Vn=function(t){function e(e){var n=t.call(this,e)||this;return n.uploadHookHelper=n.renderer,n.registerFindHook(Hn),n.registerUploadHook(Xn),n.registerUploadHook(jn),n}return Cn(e,t),e}(kn),Yn=(function(){function t(t){this.maxMilliseconds=t,this.frameStart=0}t.prototype.beginFrame=function(){this.frameStart=Date.now()},t.prototype.allowedToUpload=function(){return Date.now()-this.frameStart<this.maxMilliseconds}}(),function(){function t(t,e,n){void 0===n&&(n=null),this._texture=t instanceof J.xE?t:null,this.baseTexture=t instanceof J.VL?t:this._texture.baseTexture,this.textures={},this.animations={},this.data=e;var r=this.baseTexture.resource;this.resolution=this._updateResolution(n||(r?r.url:null)),this._frames=this.data.frames,this._frameKeys=Object.keys(this._frames),this._batchIndex=0,this._callback=null}return t.prototype._updateResolution=function(t){void 0===t&&(t=null);var e=this.data.meta.scale,n=(0,O.fL)(t,null);return null===n&&(n=void 0!==e?parseFloat(e):1),1!==n&&this.baseTexture.setResolution(n),n},t.prototype.parse=function(e){this._batchIndex=0,this._callback=e,this._frameKeys.length<=t.BATCH_SIZE?(this._processFrames(0),this._processAnimations(),this._parseComplete()):this._nextBatch()},t.prototype._processFrames=function(e){var n=e,r=t.BATCH_SIZE;while(n-e<r&&n<this._frameKeys.length){var i=this._frameKeys[n],o=this._frames[i],s=o.frame;if(s){var a=null,u=null,l=!1!==o.trimmed&&o.sourceSize?o.sourceSize:o.frame,c=new k.Ae(0,0,Math.floor(l.w)/this.resolution,Math.floor(l.h)/this.resolution);a=o.rotated?new k.Ae(Math.floor(s.x)/this.resolution,Math.floor(s.y)/this.resolution,Math.floor(s.h)/this.resolution,Math.floor(s.w)/this.resolution):new k.Ae(Math.floor(s.x)/this.resolution,Math.floor(s.y)/this.resolution,Math.floor(s.w)/this.resolution,Math.floor(s.h)/this.resolution),!1!==o.trimmed&&o.spriteSourceSize&&(u=new k.Ae(Math.floor(o.spriteSourceSize.x)/this.resolution,Math.floor(o.spriteSourceSize.y)/this.resolution,Math.floor(s.w)/this.resolution,Math.floor(s.h)/this.resolution)),this.textures[i]=new J.xE(this.baseTexture,a,c,u,o.rotated?2:0,o.anchor),J.xE.addToCache(this.textures[i],i)}n++}},t.prototype._processAnimations=function(){var t=this.data.animations||{};for(var e in t){this.animations[e]=[];for(var n=0;n<t[e].length;n++){var r=t[e][n];this.animations[e].push(this.textures[r])}}},t.prototype._parseComplete=function(){var t=this._callback;this._callback=null,this._batchIndex=0,t.call(this,this.textures)},t.prototype._nextBatch=function(){var e=this;this._processFrames(this._batchIndex*t.BATCH_SIZE),this._batchIndex++,setTimeout((function(){e._batchIndex*t.BATCH_SIZE<e._frameKeys.length?e._nextBatch():(e._processAnimations(),e._parseComplete())}),0)},t.prototype.destroy=function(t){var e;for(var n in void 0===t&&(t=!1),this.textures)this.textures[n].destroy();this._frames=null,this._frameKeys=null,this.data=null,this.textures=null,t&&(null===(e=this._texture)||void 0===e||e.destroy(),this.baseTexture.destroy()),this._texture=null,this.baseTexture=null},t.BATCH_SIZE=1e3,t}()),Wn=function(){function t(){}return t.use=function(e,n){var r,i,o=this,s=e.name+"_image";if(e.data&&e.type===_t.TYPE.JSON&&e.data.frames&&!o.resources[s]){var a=null===(i=null===(r=e.data)||void 0===r?void 0:r.meta)||void 0===i?void 0:i.related_multi_packs;if(Array.isArray(a))for(var u=function(t){if("string"!==typeof t)return"continue";var n=t.replace(".json",""),r=O.HQ.resolve(e.url.replace(o.baseUrl,""),t);if(o.resources[n]||Object.values(o.resources).some((function(t){return O.HQ.format(O.HQ.parse(t.url))===r})))return"continue";var i={crossOrigin:e.crossOrigin,loadType:_t.LOAD_TYPE.XHR,xhrType:_t.XHR_RESPONSE_TYPE.JSON,parentResource:e,metadata:e.metadata};o.add(n,r,i)},l=0,c=a;l<c.length;l++){var h=c[l];u(h)}var f={crossOrigin:e.crossOrigin,metadata:e.metadata.imageMetadata,parentResource:e},d=t.getResourcePath(e,o.baseUrl);o.add(s,d,f,(function(t){if(t.error)n(t.error);else{var r=new Yn(t.texture,e.data,e.url);r.parse((function(){e.spritesheet=r,e.textures=r.textures,n()}))}}))}else n()},t.getResourcePath=function(t,e){return t.isDataUrl?t.data.meta.image:O.HQ.resolve(t.url.replace(e,""),t.data.meta.image)},t}(),zn=function(t,e){return zn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},zn(t,e)};function $n(t,e){function n(){this.constructor=t}zn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var qn=new k.E9,Kn=(function(t){function e(e,n,r){void 0===n&&(n=100),void 0===r&&(r=100);var i=t.call(this,e)||this;return i.tileTransform=new k.wx,i._width=n,i._height=r,i.uvMatrix=i.texture.uvMatrix||new J.UX(e),i.pluginName="tilingSprite",i.uvRespectAnchor=!1,i}$n(e,t),Object.defineProperty(e.prototype,"clampMargin",{get:function(){return this.uvMatrix.clampMargin},set:function(t){this.uvMatrix.clampMargin=t,this.uvMatrix.update(!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tileScale",{get:function(){return this.tileTransform.scale},set:function(t){this.tileTransform.scale.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tilePosition",{get:function(){return this.tileTransform.position},set:function(t){this.tileTransform.position.copyFrom(t)},enumerable:!1,configurable:!0}),e.prototype._onTextureUpdate=function(){this.uvMatrix&&(this.uvMatrix.texture=this._texture),this._cachedTint=16777215},e.prototype._render=function(t){var e=this._texture;e&&e.valid&&(this.tileTransform.updateLocalTransform(),this.uvMatrix.update(),t.batch.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this))},e.prototype._calculateBounds=function(){var t=this._width*-this._anchor._x,e=this._height*-this._anchor._y,n=this._width*(1-this._anchor._x),r=this._height*(1-this._anchor._y);this._bounds.addFrame(this.transform,t,e,n,r)},e.prototype.getLocalBounds=function(e){return 0===this.children.length?(this._bounds.minX=this._width*-this._anchor._x,this._bounds.minY=this._height*-this._anchor._y,this._bounds.maxX=this._width*(1-this._anchor._x),this._bounds.maxY=this._height*(1-this._anchor._y),e||(this._localBoundsRect||(this._localBoundsRect=new k.Ae),e=this._localBoundsRect),this._bounds.getRectangle(e)):t.prototype.getLocalBounds.call(this,e)},e.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,qn);var e=this._width,n=this._height,r=-e*this.anchor._x;if(qn.x>=r&&qn.x<r+e){var i=-n*this.anchor._y;if(qn.y>=i&&qn.y<i+n)return!0}return!1},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this.tileTransform=null,this.uvMatrix=null},e.from=function(t,n){var r=t instanceof J.xE?t:J.xE.from(t,n);return new e(r,n.width,n.height)},Object.defineProperty(e.prototype,"width",{get:function(){return this._width},set:function(t){this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this._height},set:function(t){this._height=t},enumerable:!1,configurable:!0})}(mn.j),"#version 100\n#define SHADER_NAME Tiling-Sprite-Simple-100\n\nprecision lowp float;\n\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\n\nvoid main(void)\n{\n vec4 texSample = texture2D(uSampler, vTextureCoord);\n gl_FragColor = texSample * uColor;\n}\n"),Zn="#version 100\n#define SHADER_NAME Tiling-Sprite-100\n\nprecision lowp float;\n\nattribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n",Jn="#version 100\n#ifdef GL_EXT_shader_texture_lod\n #extension GL_EXT_shader_texture_lod : enable\n#endif\n#define SHADER_NAME Tiling-Sprite-100\n\nprecision lowp float;\n\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\nuniform mat3 uMapCoord;\nuniform vec4 uClampFrame;\nuniform vec2 uClampOffset;\n\nvoid main(void)\n{\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\n vec2 unclamped = coord;\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\n\n #ifdef GL_EXT_shader_texture_lod\n vec4 texSample = unclamped == coord\n ? texture2D(uSampler, coord) \n : texture2DLodEXT(uSampler, coord, 0);\n #else\n vec4 texSample = texture2D(uSampler, coord);\n #endif\n\n gl_FragColor = texSample * uColor;\n}\n",Qn="#version 300 es\n#define SHADER_NAME Tiling-Sprite-300\n\nprecision lowp float;\n\nin vec2 aVertexPosition;\nin vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nout vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n",tr="#version 300 es\n#define SHADER_NAME Tiling-Sprite-100\n\nprecision lowp float;\n\nin vec2 vTextureCoord;\n\nout vec4 fragmentColor;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\nuniform mat3 uMapCoord;\nuniform vec4 uClampFrame;\nuniform vec2 uClampOffset;\n\nvoid main(void)\n{\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\n vec2 unclamped = coord;\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\n\n vec4 texSample = texture(uSampler, coord, unclamped == coord ? 0.0f : -32.0f);// lod-bias very negative to force lod 0\n\n fragmentColor = texSample * uColor;\n}\n",er=new k.y3,nr=function(t){function e(e){var n=t.call(this,e)||this;return e.runners.contextChange.add(n),n.quad=new J.ud,n.state=J.ZM.for2d(),n}return $n(e,t),e.prototype.contextChange=function(){var t=this.renderer,e={globals:t.globalUniforms};this.simpleShader=J.ex.from(Zn,Kn,e),this.shader=t.context.webGLVersion>1?J.ex.from(Qn,tr,e):J.ex.from(Zn,Jn,e)},e.prototype.render=function(t){var e=this.renderer,n=this.quad,r=n.vertices;r[0]=r[6]=t._width*-t.anchor.x,r[1]=r[3]=t._height*-t.anchor.y,r[2]=r[4]=t._width*(1-t.anchor.x),r[5]=r[7]=t._height*(1-t.anchor.y);var i=t.uvRespectAnchor?t.anchor.x:0,o=t.uvRespectAnchor?t.anchor.y:0;r=n.uvs,r[0]=r[6]=-i,r[1]=r[3]=-o,r[2]=r[4]=1-i,r[5]=r[7]=1-o,n.invalidate();var s=t._texture,a=s.baseTexture,u=t.tileTransform.localTransform,l=t.uvMatrix,c=a.isPowerOfTwo&&s.frame.width===a.width&&s.frame.height===a.height;c&&(a._glTextures[e.CONTEXT_UID]?c=a.wrapMode!==Dt.Nt.CLAMP:a.wrapMode===Dt.Nt.CLAMP&&(a.wrapMode=Dt.Nt.REPEAT));var h=c?this.simpleShader:this.shader,f=s.width,d=s.height,p=t._width,v=t._height;er.set(u.a*f/p,u.b*f/v,u.c*d/p,u.d*d/v,u.tx/p,u.ty/v),er.invert(),c?er.prepend(l.mapCoord):(h.uniforms.uMapCoord=l.mapCoord.toArray(!0),h.uniforms.uClampFrame=l.uClampFrame,h.uniforms.uClampOffset=l.uClampOffset),h.uniforms.uTransform=er.toArray(!0),h.uniforms.uColor=(0,O.GT)(t.tint,t.worldAlpha,h.uniforms.uColor,a.alphaMode),h.uniforms.translationMatrix=t.transform.worldTransform.toArray(!0),h.uniforms.uSampler=s,e.shader.bind(h),e.geometry.bind(n),this.state.blendMode=(0,O.D)(t.blendMode,a.alphaMode),e.state.set(this.state),e.geometry.draw(this.renderer.gl.TRIANGLES,6,0)},e}(J.bO),rr=function(t,e){return rr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},rr(t,e)};function ir(t,e){function n(){this.constructor=t}rr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var or=function(){function t(t,e){this.uvBuffer=t,this.uvMatrix=e,this.data=null,this._bufferUpdateId=-1,this._textureUpdateId=-1,this._updateID=0}return t.prototype.update=function(t){if(t||this._bufferUpdateId!==this.uvBuffer._updateID||this._textureUpdateId!==this.uvMatrix._updateID){this._bufferUpdateId=this.uvBuffer._updateID,this._textureUpdateId=this.uvMatrix._updateID;var e=this.uvBuffer.data;this.data&&this.data.length===e.length||(this.data=new Float32Array(e.length)),this.uvMatrix.multiplyUvs(e,this.data),this._updateID++}},t}(),sr=new k.E9,ar=new k.mg,ur=function(t){function e(e,n,r,i){void 0===i&&(i=Dt.lg.TRIANGLES);var o=t.call(this)||this;return o.geometry=e,o.shader=n,o.state=r||J.ZM.for2d(),o.drawMode=i,o.start=0,o.size=0,o.uvs=null,o.indices=null,o.vertexData=new Float32Array(1),o.vertexDirty=-1,o._transformID=-1,o._roundPixels=Le.X.ROUND_PIXELS,o.batchUvs=null,o}return ir(e,t),Object.defineProperty(e.prototype,"geometry",{get:function(){return this._geometry},set:function(t){this._geometry!==t&&(this._geometry&&(this._geometry.refCount--,0===this._geometry.refCount&&this._geometry.dispose()),this._geometry=t,this._geometry&&this._geometry.refCount++,this.vertexDirty=-1)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"uvBuffer",{get:function(){return this.geometry.buffers[1]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"verticesBuffer",{get:function(){return this.geometry.buffers[0]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"material",{get:function(){return this.shader},set:function(t){this.shader=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.state.blendMode},set:function(t){this.state.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"roundPixels",{get:function(){return this._roundPixels},set:function(t){this._roundPixels!==t&&(this._transformID=-1),this._roundPixels=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return"tint"in this.shader?this.shader.tint:null},set:function(t){this.shader.tint=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"texture",{get:function(){return"texture"in this.shader?this.shader.texture:null},set:function(t){this.shader.texture=t},enumerable:!1,configurable:!0}),e.prototype._render=function(t){var n=this.geometry.buffers[0].data,r=this.shader;r.batchable&&this.drawMode===Dt.lg.TRIANGLES&&n.length<2*e.BATCHABLE_SIZE?this._renderToBatch(t):this._renderDefault(t)},e.prototype._renderDefault=function(t){var e=this.shader;e.alpha=this.worldAlpha,e.update&&e.update(),t.batch.flush(),e.uniforms.translationMatrix=this.transform.worldTransform.toArray(!0),t.shader.bind(e),t.state.set(this.state),t.geometry.bind(this.geometry,e),t.geometry.draw(this.drawMode,this.size,this.start,this.geometry.instanceCount)},e.prototype._renderToBatch=function(t){var e=this.geometry,n=this.shader;n.uvMatrix&&(n.uvMatrix.update(),this.calculateUvs()),this.calculateVertices(),this.indices=e.indexBuffer.data,this._tintRGB=n._tintRGB,this._texture=n.texture;var r=this.material.pluginName;t.batch.setObjectRenderer(t.plugins[r]),t.plugins[r].render(this)},e.prototype.calculateVertices=function(){var t=this.geometry,e=t.buffers[0],n=e.data,r=e._updateID;if(r!==this.vertexDirty||this._transformID!==this.transform._worldID){this._transformID=this.transform._worldID,this.vertexData.length!==n.length&&(this.vertexData=new Float32Array(n.length));for(var i=this.transform.worldTransform,o=i.a,s=i.b,a=i.c,u=i.d,l=i.tx,c=i.ty,h=this.vertexData,f=0;f<h.length/2;f++){var d=n[2*f],p=n[2*f+1];h[2*f]=o*d+a*p+l,h[2*f+1]=s*d+u*p+c}if(this._roundPixels){var v=Le.X.RESOLUTION;for(f=0;f<h.length;++f)h[f]=Math.round((h[f]*v|0)/v)}this.vertexDirty=r}},e.prototype.calculateUvs=function(){var t=this.geometry.buffers[1],e=this.shader;e.uvMatrix.isSimple?this.uvs=t.data:(this.batchUvs||(this.batchUvs=new or(t,e.uvMatrix)),this.batchUvs.update(),this.uvs=this.batchUvs.data)},e.prototype._calculateBounds=function(){this.calculateVertices(),this._bounds.addVertexData(this.vertexData,0,this.vertexData.length)},e.prototype.containsPoint=function(t){if(!this.getBounds().contains(t.x,t.y))return!1;this.worldTransform.applyInverse(t,sr);for(var e=this.geometry.getBuffer("aVertexPosition").data,n=ar.points,r=this.geometry.getIndex().data,i=r.length,o=4===this.drawMode?3:1,s=0;s+2<i;s+=o){var a=2*r[s],u=2*r[s+1],l=2*r[s+2];if(n[0]=e[a],n[1]=e[a+1],n[2]=e[u],n[3]=e[u+1],n[4]=e[l],n[5]=e[l+1],ar.contains(sr.x,sr.y))return!0}return!1},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this._cachedTexture&&(this._cachedTexture.destroy(),this._cachedTexture=null),this.geometry=null,this.shader=null,this.state=null,this.uvs=null,this.indices=null,this.vertexData=null},e.BATCHABLE_SIZE=100,e}(w.W2),lr="varying vec2 vTextureCoord;\nuniform vec4 uColor;\n\nuniform sampler2D uSampler;\n\nvoid main(void)\n{\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uColor;\n}\n",cr="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTextureMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\n}\n",hr=function(t){function e(e,n){var r=this,i={uSampler:e,alpha:1,uTextureMatrix:k.y3.IDENTITY,uColor:new Float32Array([1,1,1,1])};return n=Object.assign({tint:16777215,alpha:1,pluginName:"batch"},n),n.uniforms&&Object.assign(i,n.uniforms),r=t.call(this,n.program||J.$r.from(cr,lr),i)||this,r._colorDirty=!1,r.uvMatrix=new J.UX(e),r.batchable=void 0===n.program,r.pluginName=n.pluginName,r.tint=n.tint,r.alpha=n.alpha,r}return ir(e,t),Object.defineProperty(e.prototype,"texture",{get:function(){return this.uniforms.uSampler},set:function(t){this.uniforms.uSampler!==t&&(this.uniforms.uSampler=t,this.uvMatrix.texture=t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alpha",{get:function(){return this._alpha},set:function(t){t!==this._alpha&&(this._alpha=t,this._colorDirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){t!==this._tint&&(this._tint=t,this._tintRGB=(t>>16)+(65280&t)+((255&t)<<16),this._colorDirty=!0)},enumerable:!1,configurable:!0}),e.prototype.update=function(){if(this._colorDirty){this._colorDirty=!1;var t=this.texture.baseTexture;(0,O.GT)(this._tint,this._alpha,this.uniforms.uColor,t.alphaMode)}this.uvMatrix.update()&&(this.uniforms.uTextureMatrix=this.uvMatrix.mapCoord)},e}(J.ex),fr=function(t){function e(e,n,r){var i=t.call(this)||this,o=new J.lW(e),s=new J.lW(n,!0),a=new J.lW(r,!0,!0);return i.addAttribute("aVertexPosition",o,2,!1,Dt.vK.FLOAT).addAttribute("aTextureCoord",s,2,!1,Dt.vK.FLOAT).addIndex(a),i._updateId=-1,i}return ir(e,t),Object.defineProperty(e.prototype,"vertexDirtyId",{get:function(){return this.buffers[0]._updateID},enumerable:!1,configurable:!0}),e}(J.ZX),dr=function(t,e){return dr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},dr(t,e)};function pr(t,e){function n(){this.constructor=t}dr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var vr=function(){function t(){this.info=[],this.common=[],this.page=[],this.char=[],this.kerning=[],this.distanceField=[]}return t}(),mr=function(){function t(){}return t.test=function(t){return"string"===typeof t&&0===t.indexOf("info face=")},t.parse=function(t){var e=t.match(/^[a-z]+\s+.+$/gm),n={info:[],common:[],page:[],char:[],chars:[],kerning:[],kernings:[],distanceField:[]};for(var r in e){var i=e[r].match(/^[a-z]+/gm)[0],o=e[r].match(/[a-zA-Z]+=([^\s"']+|"([^"]*)")/gm),s={};for(var a in o){var u=o[a].split("="),l=u[0],c=u[1].replace(/"/gm,""),h=parseFloat(c),f=isNaN(h)?c:h;s[l]=f}n[i].push(s)}var d=new vr;return n.info.forEach((function(t){return d.info.push({face:t.face,size:parseInt(t.size,10)})})),n.common.forEach((function(t){return d.common.push({lineHeight:parseInt(t.lineHeight,10)})})),n.page.forEach((function(t){return d.page.push({id:parseInt(t.id,10),file:t.file})})),n.char.forEach((function(t){return d.char.push({id:parseInt(t.id,10),page:parseInt(t.page,10),x:parseInt(t.x,10),y:parseInt(t.y,10),width:parseInt(t.width,10),height:parseInt(t.height,10),xoffset:parseInt(t.xoffset,10),yoffset:parseInt(t.yoffset,10),xadvance:parseInt(t.xadvance,10)})})),n.kerning.forEach((function(t){return d.kerning.push({first:parseInt(t.first,10),second:parseInt(t.second,10),amount:parseInt(t.amount,10)})})),n.distanceField.forEach((function(t){return d.distanceField.push({distanceRange:parseInt(t.distanceRange,10),fieldType:t.fieldType})})),d},t}(),gr=function(){function t(){}return t.test=function(t){return t instanceof XMLDocument&&t.getElementsByTagName("page").length&&null!==t.getElementsByTagName("info")[0].getAttribute("face")},t.parse=function(t){for(var e=new vr,n=t.getElementsByTagName("info"),r=t.getElementsByTagName("common"),i=t.getElementsByTagName("page"),o=t.getElementsByTagName("char"),s=t.getElementsByTagName("kerning"),a=t.getElementsByTagName("distanceField"),u=0;u<n.length;u++)e.info.push({face:n[u].getAttribute("face"),size:parseInt(n[u].getAttribute("size"),10)});for(u=0;u<r.length;u++)e.common.push({lineHeight:parseInt(r[u].getAttribute("lineHeight"),10)});for(u=0;u<i.length;u++)e.page.push({id:parseInt(i[u].getAttribute("id"),10)||0,file:i[u].getAttribute("file")});for(u=0;u<o.length;u++){var l=o[u];e.char.push({id:parseInt(l.getAttribute("id"),10),page:parseInt(l.getAttribute("page"),10)||0,x:parseInt(l.getAttribute("x"),10),y:parseInt(l.getAttribute("y"),10),width:parseInt(l.getAttribute("width"),10),height:parseInt(l.getAttribute("height"),10),xoffset:parseInt(l.getAttribute("xoffset"),10),yoffset:parseInt(l.getAttribute("yoffset"),10),xadvance:parseInt(l.getAttribute("xadvance"),10)})}for(u=0;u<s.length;u++)e.kerning.push({first:parseInt(s[u].getAttribute("first"),10),second:parseInt(s[u].getAttribute("second"),10),amount:parseInt(s[u].getAttribute("amount"),10)});for(u=0;u<a.length;u++)e.distanceField.push({fieldType:a[u].getAttribute("fieldType"),distanceRange:parseInt(a[u].getAttribute("distanceRange"),10)});return e},t}(),_r=function(){function t(){}return t.test=function(t){if("string"===typeof t&&t.indexOf("<font>")>-1){var e=(new globalThis.DOMParser).parseFromString(t,"text/xml");return gr.test(e)}return!1},t.parse=function(t){var e=(new globalThis.DOMParser).parseFromString(t,"text/xml");return gr.parse(e)},t}(),yr=[mr,gr,_r];function br(t){for(var e=0;e<yr.length;e++)if(yr[e].test(t))return yr[e];return null}function Er(t,e,n,r,i,o){var s,a=n.fill;if(!Array.isArray(a))return a;if(1===a.length)return a[0];var u=n.dropShadow?n.dropShadowDistance:0,l=n.padding||0,c=t.width/r-u-2*l,h=t.height/r-u-2*l,f=a.slice(),d=n.fillGradientStops.slice();if(!d.length)for(var p=f.length+1,v=1;v<p;++v)d.push(v/p);if(f.unshift(a[0]),d.unshift(0),f.push(a[a.length-1]),d.push(1),n.fillGradientType===Qe.LINEAR_VERTICAL){s=e.createLinearGradient(c/2,l,c/2,h+l);var m=0,g=o.fontProperties.fontSize+n.strokeThickness,_=g/h;for(v=0;v<i.length;v++)for(var y=o.lineHeight*v,b=0;b<f.length;b++){var E=0;E="number"===typeof d[b]?d[b]:b/f.length;var x=y/h+E*_,T=Math.max(m,x);T=Math.min(T,1),s.addColorStop(T,f[b]),m=T}}else{s=e.createLinearGradient(l,h/2,c+l,h/2);var S=f.length+1,R=1;for(v=0;v<f.length;v++){var A=void 0;A="number"===typeof d[v]?d[v]:R/S,s.addColorStop(A,f[v]),R++}}return s}function xr(t,e,n,r,i,o,s){var a=n.text,u=n.fontProperties;e.translate(r,i),e.scale(o,o);var l=s.strokeThickness/2,c=-s.strokeThickness/2;if(e.font=s.toFontString(),e.lineWidth=s.strokeThickness,e.textBaseline=s.textBaseline,e.lineJoin=s.lineJoin,e.miterLimit=s.miterLimit,e.fillStyle=Er(t,e,s,o,[a],n),e.strokeStyle=s.stroke,s.dropShadow){var h=s.dropShadowColor,f=(0,O.wK)("number"===typeof h?h:(0,O.qm)(h)),d=s.dropShadowBlur*o,p=s.dropShadowDistance*o;e.shadowColor="rgba("+255*f[0]+","+255*f[1]+","+255*f[2]+","+s.dropShadowAlpha+")",e.shadowBlur=d,e.shadowOffsetX=Math.cos(s.dropShadowAngle)*p,e.shadowOffsetY=Math.sin(s.dropShadowAngle)*p}else e.shadowColor="black",e.shadowBlur=0,e.shadowOffsetX=0,e.shadowOffsetY=0;s.stroke&&s.strokeThickness&&e.strokeText(a,l,c+n.lineHeight-u.descent),s.fill&&e.fillText(a,l,c+n.lineHeight-u.descent),e.setTransform(1,0,0,1,0,0),e.fillStyle="rgba(0, 0, 0, 0)"}function Tr(t){return Array.from?Array.from(t):t.split("")}function Sr(t){"string"===typeof t&&(t=[t]);for(var e=[],n=0,r=t.length;n<r;n++){var i=t[n];if(Array.isArray(i)){if(2!==i.length)throw new Error("[BitmapFont]: Invalid character range length, expecting 2 got "+i.length+".");var o=i[0].charCodeAt(0),s=i[1].charCodeAt(0);if(s<o)throw new Error("[BitmapFont]: Invalid character range.");for(var a=o,u=s;a<=u;a++)e.push(String.fromCharCode(a))}else e.push.apply(e,Tr(i))}if(0===e.length)throw new Error("[BitmapFont]: Empty set when resolving characters.");return e}function Rr(t){return t.codePointAt?t.codePointAt(0):t.charCodeAt(0)}var Ar=function(){function t(t,e,n){var r,i,o=t.info[0],s=t.common[0],a=t.page[0],u=t.distanceField[0],l=(0,O.fL)(a.file),c={};this._ownsTextures=n,this.font=o.face,this.size=o.size,this.lineHeight=s.lineHeight/l,this.chars={},this.pageTextures=c;for(var h=0;h<t.page.length;h++){var f=t.page[h],d=f.id,p=f.file;c[d]=e instanceof Array?e[h]:e[p],(null===u||void 0===u?void 0:u.fieldType)&&"none"!==u.fieldType&&(c[d].baseTexture.alphaMode=Dt.iw.NO_PREMULTIPLIED_ALPHA)}for(h=0;h<t.char.length;h++){var v=t.char[h],m=(d=v.id,v.page),g=t.char[h],_=g.x,y=g.y,b=g.width,E=g.height,x=g.xoffset,T=g.yoffset,S=g.xadvance;_/=l,y/=l,b/=l,E/=l,x/=l,T/=l,S/=l;var R=new k.Ae(_+c[m].frame.x/l,y+c[m].frame.y/l,b,E);this.chars[d]={xOffset:x,yOffset:T,xAdvance:S,kerning:{},texture:new J.xE(c[m].baseTexture,R),page:m}}for(h=0;h<t.kerning.length;h++){var A=t.kerning[h],w=A.first,I=A.second,P=A.amount;w/=l,I/=l,P/=l,this.chars[I]&&(this.chars[I].kerning[w]=P)}this.distanceFieldRange=null===u||void 0===u?void 0:u.distanceRange,this.distanceFieldType=null!==(i=null===(r=null===u||void 0===u?void 0:u.fieldType)||void 0===r?void 0:r.toLowerCase())&&void 0!==i?i:"none"}return t.prototype.destroy=function(){for(var t in this.chars)this.chars[t].texture.destroy(),this.chars[t].texture=null;for(var t in this.pageTextures)this._ownsTextures&&this.pageTextures[t].destroy(!0),this.pageTextures[t]=null;this.chars=null,this.pageTextures=null},t.install=function(e,n,r){var i;if(e instanceof vr)i=e;else{var o=br(e);if(!o)throw new Error("Unrecognized data format for font.");i=o.parse(e)}n instanceof J.xE&&(n=[n]);var s=new t(i,n,r);return t.available[s.font]=s,s},t.uninstall=function(e){var n=t.available[e];if(!n)throw new Error("No font found named '"+e+"'");n.destroy(),delete t.available[e]},t.from=function(e,n,r){if(!e)throw new Error("[BitmapFont] Property `name` is required.");var i=Object.assign({},t.defaultOptions,r),o=i.chars,s=i.padding,a=i.resolution,u=i.textureWidth,l=i.textureHeight,c=Sr(o),h=n instanceof En?n:new En(n),f=u,d=new vr;d.info[0]={face:h.fontFamily,size:h.fontSize},d.common[0]={lineHeight:h.fontSize};for(var p,v,m,g=0,_=0,y=0,b=[],E=0;E<c.length;E++){p||(p=document.createElement("canvas"),p.width=u,p.height=l,v=p.getContext("2d"),m=new J.VL(p,{resolution:a}),b.push(new J.xE(m)),d.page.push({id:b.length-1,file:""}));var x=An.measureText(c[E],h,!1,p),T=x.width,S=Math.ceil(x.height),R=Math.ceil(("italic"===h.fontStyle?2:1)*T);if(_>=l-S*a){if(0===_)throw new Error("[BitmapFont] textureHeight "+l+"px is too small for "+h.fontSize+"px fonts");--E,p=null,v=null,m=null,_=0,g=0,y=0}else if(y=Math.max(S+x.fontProperties.descent,y),R*a+g>=f)--E,_+=y*a,_=Math.ceil(_),g=0,y=0;else{xr(p,v,x,g,_,a,h);var A=Rr(x.text);d.char.push({id:A,page:b.length-1,x:g/a,y:_/a,width:R,height:S,xoffset:0,yoffset:0,xadvance:Math.ceil(T-(h.dropShadow?h.dropShadowDistance:0)-(h.stroke?h.strokeThickness:0))}),g+=(R+2*s)*a,g=Math.ceil(g)}}E=0;for(var O=c.length;E<O;E++)for(var w=c[E],I=0;I<O;I++){var P=c[I],C=v.measureText(w).width,N=v.measureText(P).width,M=v.measureText(w+P).width,D=M-(C+N);D&&d.kerning.push({first:Rr(w),second:Rr(P),amount:D})}var L=new t(d,b,!0);return void 0!==t.available[e]&&t.uninstall(e),t.available[e]=L,L},t.ALPHA=[["a","z"],["A","Z"]," "],t.NUMERIC=[["0","9"]],t.ALPHANUMERIC=[["a","z"],["A","Z"],["0","9"]," "],t.ASCII=[[" ","~"]],t.defaultOptions={resolution:1,textureWidth:512,textureHeight:512,padding:4,chars:t.ALPHANUMERIC},t.available={},t}(),Or="// Pixi texture info\r\nvarying vec2 vTextureCoord;\r\nuniform sampler2D uSampler;\r\n\r\n// Tint\r\nuniform vec4 uColor;\r\n\r\n// on 2D applications fwidth is screenScale / glyphAtlasScale * distanceFieldRange\r\nuniform float uFWidth;\r\n\r\nvoid main(void) {\r\n\r\n // To stack MSDF and SDF we need a non-pre-multiplied-alpha texture.\r\n vec4 texColor = texture2D(uSampler, vTextureCoord);\r\n\r\n // MSDF\r\n float median = texColor.r + texColor.g + texColor.b -\r\n min(texColor.r, min(texColor.g, texColor.b)) -\r\n max(texColor.r, max(texColor.g, texColor.b));\r\n // SDF\r\n median = min(median, texColor.a);\r\n\r\n float screenPxDistance = uFWidth * (median - 0.5);\r\n float alpha = clamp(screenPxDistance + 0.5, 0.0, 1.0);\r\n\r\n // NPM Textures, NPM outputs\r\n gl_FragColor = vec4(uColor.rgb, uColor.a * alpha);\r\n\r\n}\r\n",wr="// Mesh material default fragment\r\nattribute vec2 aVertexPosition;\r\nattribute vec2 aTextureCoord;\r\n\r\nuniform mat3 projectionMatrix;\r\nuniform mat3 translationMatrix;\r\nuniform mat3 uTextureMatrix;\r\n\r\nvarying vec2 vTextureCoord;\r\n\r\nvoid main(void)\r\n{\r\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\r\n\r\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\r\n}\r\n",Ir=[],Pr=[],Cr=[],Nr=(function(t){function e(n,r){void 0===r&&(r={});var i=t.call(this)||this;i._tint=16777215;var o=Object.assign({},e.styleDefaults,r),s=o.align,a=o.tint,u=o.maxWidth,l=o.letterSpacing,c=o.fontName,h=o.fontSize;if(!Ar.available[c])throw new Error('Missing BitmapFont "'+c+'"');return i._activePagesMeshData=[],i._textWidth=0,i._textHeight=0,i._align=s,i._tint=a,i._fontName=c,i._fontSize=h||Ar.available[c].size,i._text=n,i._maxWidth=u,i._maxLineHeight=0,i._letterSpacing=l,i._anchor=new k.AB((function(){i.dirty=!0}),i,0,0),i._roundPixels=Le.X.ROUND_PIXELS,i.dirty=!0,i._textureCache={},i}pr(e,t),e.prototype.updateText=function(){for(var t,e=Ar.available[this._fontName],n=this._fontSize/e.size,r=new k.E9,i=[],o=[],s=[],a=this._text.replace(/(?:\r\n|\r)/g,"\n")||" ",u=Tr(a),l=this._maxWidth*e.size/this._fontSize,c="none"===e.distanceFieldType?Ir:Pr,h=null,f=0,d=0,p=0,v=-1,m=0,g=0,_=0,y=0,b=0;b<u.length;b++){var E=u[b],x=Rr(E);if(/(?:\s)/.test(E)&&(v=b,m=f,y++),"\r"!==E&&"\n"!==E){var T=e.chars[x];if(T){h&&T.kerning[h]&&(r.x+=T.kerning[h]);var S=Cr.pop()||{texture:J.xE.EMPTY,line:0,charCode:0,prevSpaces:0,position:new k.E9};S.texture=T.texture,S.line=p,S.charCode=x,S.position.x=r.x+T.xOffset+this._letterSpacing/2,S.position.y=r.y+T.yOffset,S.prevSpaces=y,i.push(S),f=S.position.x+Math.max(T.xAdvance,T.texture.orig.width),r.x+=T.xAdvance+this._letterSpacing,_=Math.max(_,T.yOffset+T.texture.height),h=x,-1!==v&&l>0&&r.x>l&&(++g,(0,O.Er)(i,1+v-g,1+b-v),b=v,v=-1,o.push(m),s.push(i.length>0?i[i.length-1].prevSpaces:0),d=Math.max(d,m),p++,r.x=0,r.y+=e.lineHeight,h=null,y=0)}}else o.push(f),s.push(-1),d=Math.max(d,f),++p,++g,r.x=0,r.y+=e.lineHeight,h=null,y=0}var R=u[u.length-1];"\r"!==R&&"\n"!==R&&(/(?:\s)/.test(R)&&(f=m),o.push(f),d=Math.max(d,f),s.push(-1));var A=[];for(b=0;b<=p;b++){var w=0;"right"===this._align?w=d-o[b]:"center"===this._align?w=(d-o[b])/2:"justify"===this._align&&(w=s[b]<0?0:(d-o[b])/s[b]),A.push(w)}var I=i.length,P={},C=[],N=this._activePagesMeshData;for(b=0;b<N.length;b++)c.push(N[b]);for(b=0;b<I;b++){var M=i[b].texture,D=M.baseTexture.uid;if(!P[D]){var L=c.pop();if(!L){var F=new fr,B=void 0,U=void 0;"none"===e.distanceFieldType?(B=new hr(J.xE.EMPTY),U=Dt.T$.NORMAL):(B=new hr(J.xE.EMPTY,{program:J.$r.from(wr,Or),uniforms:{uFWidth:0}}),U=Dt.T$.NORMAL_NPM);var G=new ur(F,B);G.blendMode=U,L={index:0,indexCount:0,vertexCount:0,uvsCount:0,total:0,mesh:G,vertices:null,uvs:null,indices:null}}L.index=0,L.indexCount=0,L.vertexCount=0,L.uvsCount=0,L.total=0;var X=this._textureCache;X[D]=X[D]||new J.xE(M.baseTexture),L.mesh.texture=X[D],L.mesh.tint=this._tint,C.push(L),P[D]=L}P[D].total++}for(b=0;b<N.length;b++)-1===C.indexOf(N[b])&&this.removeChild(N[b].mesh);for(b=0;b<C.length;b++)C[b].mesh.parent!==this&&this.addChild(C[b].mesh);for(var b in this._activePagesMeshData=C,P){L=P[b];var j=L.total;if(!((null===(t=L.indices)||void 0===t?void 0:t.length)>6*j)||L.vertices.length<2*ur.BATCHABLE_SIZE)L.vertices=new Float32Array(8*j),L.uvs=new Float32Array(8*j),L.indices=new Uint16Array(6*j);else for(var H=L.total,V=L.vertices,Y=4*H*2;Y<V.length;Y++)V[Y]=0;L.mesh.size=6*j}for(b=0;b<I;b++){E=i[b];var W=E.position.x+A[E.line]*("justify"===this._align?E.prevSpaces:1);this._roundPixels&&(W=Math.round(W));var z=W*n,$=E.position.y*n,q=(M=E.texture,P[M.baseTexture.uid]),K=M.frame,Z=M._uvs,Q=q.index++;q.indices[6*Q+0]=0+4*Q,q.indices[6*Q+1]=1+4*Q,q.indices[6*Q+2]=2+4*Q,q.indices[6*Q+3]=0+4*Q,q.indices[6*Q+4]=2+4*Q,q.indices[6*Q+5]=3+4*Q,q.vertices[8*Q+0]=z,q.vertices[8*Q+1]=$,q.vertices[8*Q+2]=z+K.width*n,q.vertices[8*Q+3]=$,q.vertices[8*Q+4]=z+K.width*n,q.vertices[8*Q+5]=$+K.height*n,q.vertices[8*Q+6]=z,q.vertices[8*Q+7]=$+K.height*n,q.uvs[8*Q+0]=Z.x0,q.uvs[8*Q+1]=Z.y0,q.uvs[8*Q+2]=Z.x1,q.uvs[8*Q+3]=Z.y1,q.uvs[8*Q+4]=Z.x2,q.uvs[8*Q+5]=Z.y2,q.uvs[8*Q+6]=Z.x3,q.uvs[8*Q+7]=Z.y3}for(var b in this._textWidth=d*n,this._textHeight=(r.y+e.lineHeight)*n,P){L=P[b];if(0!==this.anchor.x||0!==this.anchor.y)for(var tt=0,et=this._textWidth*this.anchor.x,nt=this._textHeight*this.anchor.y,rt=0;rt<L.total;rt++)L.vertices[tt++]-=et,L.vertices[tt++]-=nt,L.vertices[tt++]-=et,L.vertices[tt++]-=nt,L.vertices[tt++]-=et,L.vertices[tt++]-=nt,L.vertices[tt++]-=et,L.vertices[tt++]-=nt;this._maxLineHeight=_*n;var it=L.mesh.geometry.getBuffer("aVertexPosition"),ot=L.mesh.geometry.getBuffer("aTextureCoord"),st=L.mesh.geometry.getIndex();it.data=L.vertices,ot.data=L.uvs,st.data=L.indices,it.update(),ot.update(),st.update()}for(b=0;b<i.length;b++)Cr.push(i[b])},e.prototype.updateTransform=function(){this.validate(),this.containerUpdateTransform()},e.prototype._render=function(e){var n=Ar.available[this._fontName],r=n.distanceFieldRange,i=n.distanceFieldType,o=n.size;if("none"!==i)for(var s=this.worldTransform,a=s.a,u=s.b,l=s.c,c=s.d,h=Math.sqrt(a*a+u*u),f=Math.sqrt(l*l+c*c),d=(Math.abs(h)+Math.abs(f))/2,p=this._fontSize/o,v=0,m=this._activePagesMeshData;v<m.length;v++){var g=m[v];g.mesh.shader.uniforms.uFWidth=d*r*p*e.resolution}t.prototype._render.call(this,e)},e.prototype.getLocalBounds=function(){return this.validate(),t.prototype.getLocalBounds.call(this)},e.prototype.validate=function(){this.dirty&&(this.updateText(),this.dirty=!1)},Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){if(this._tint!==t){this._tint=t;for(var e=0;e<this._activePagesMeshData.length;e++)this._activePagesMeshData[e].mesh.tint=t}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"align",{get:function(){return this._align},set:function(t){this._align!==t&&(this._align=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fontName",{get:function(){return this._fontName},set:function(t){if(!Ar.available[t])throw new Error('Missing BitmapFont "'+t+'"');this._fontName!==t&&(this._fontName=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fontSize",{get:function(){return this._fontSize},set:function(t){this._fontSize!==t&&(this._fontSize=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"anchor",{get:function(){return this._anchor},set:function(t){"number"===typeof t?this._anchor.set(t):this._anchor.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this._text},set:function(t){t=String(null===t||void 0===t?"":t),this._text!==t&&(this._text=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxWidth",{get:function(){return this._maxWidth},set:function(t){this._maxWidth!==t&&(this._maxWidth=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxLineHeight",{get:function(){return this.validate(),this._maxLineHeight},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textWidth",{get:function(){return this.validate(),this._textWidth},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"letterSpacing",{get:function(){return this._letterSpacing},set:function(t){this._letterSpacing!==t&&(this._letterSpacing=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"roundPixels",{get:function(){return this._roundPixels},set:function(t){t!==this._roundPixels&&(this._roundPixels=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textHeight",{get:function(){return this.validate(),this._textHeight},enumerable:!1,configurable:!0}),e.prototype.destroy=function(e){var n=this._textureCache;for(var r in n){var i=n[r];i.destroy(),delete n[r]}this._textureCache=null,t.prototype.destroy.call(this,e)},e.styleDefaults={align:"left",tint:16777215,maxWidth:0,letterSpacing:0}}(w.W2),function(){function t(){}return t.add=function(){_t.setExtensionXhrType("fnt",_t.XHR_RESPONSE_TYPE.TEXT)},t.use=function(e,n){var r=br(e.data);if(r)for(var i=t.getBaseUrl(this,e),o=r.parse(e.data),s={},a=function(t){s[t.metadata.pageFile]=t.texture,Object.keys(s).length===o.page.length&&(e.bitmapFont=Ar.install(o,s,!0),n())},u=0;u<o.page.length;++u){var l=o.page[u].file,c=i+l,h=!1;for(var f in this.resources){var d=this.resources[f];if(d.url===c){d.metadata.pageFile=l,d.texture?a(d):d.onAfterMiddleware.add(a),h=!0;break}}if(!h){var p={crossOrigin:e.crossOrigin,loadType:_t.LOAD_TYPE.IMAGE,metadata:Object.assign({pageFile:l},e.metadata.imageMetadata),parentResource:e};this.add(c,p,a)}}else n()},t.getBaseUrl=function(e,n){var r=n.isDataUrl?"":t.dirname(n.url);return n.isDataUrl&&("."===r&&(r=""),e.baseUrl&&r&&"/"===e.baseUrl.charAt(e.baseUrl.length-1)&&(r+="/")),r=r.replace(e.baseUrl,""),r&&"/"!==r.charAt(r.length-1)&&(r+="/"),r},t.dirname=function(t){var e=t.replace(/\\/g,"/").replace(/\/$/,"").replace(/\/[^\/]*$/,"");return e===t?".":""===e?"/":e},t}()),Mr=function(t,e){return Mr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Mr(t,e)};function Dr(t,e){function n(){this.constructor=t}Mr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Lr="varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform float uAlpha;\n\nvoid main(void)\n{\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uAlpha;\n}\n",Fr=(function(t){function e(e){void 0===e&&(e=1);var n=t.call(this,J.kP,Lr,{uAlpha:1})||this;return n.alpha=e,n}Dr(e,t),Object.defineProperty(e.prototype,"alpha",{get:function(){return this.uniforms.uAlpha},set:function(t){this.uniforms.uAlpha=t},enumerable:!1,configurable:!0})}(J.wn),function(t,e){return Fr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Fr(t,e)});function Br(t,e){function n(){this.constructor=t}Fr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Ur="\n attribute vec2 aVertexPosition;\n\n uniform mat3 projectionMatrix;\n\n uniform float strength;\n\n varying vec2 vBlurTexCoords[%size%];\n\n uniform vec4 inputSize;\n uniform vec4 outputFrame;\n\n vec4 filterVertexPosition( void )\n {\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n }\n\n vec2 filterTextureCoord( void )\n {\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n }\n\n void main(void)\n {\n gl_Position = filterVertexPosition();\n\n vec2 textureCoord = filterTextureCoord();\n %blur%\n }";function Gr(t,e){var n,r=Math.ceil(t/2),i=Ur,o="";n=e?"vBlurTexCoords[%index%] = textureCoord + vec2(%sampleIndex% * strength, 0.0);":"vBlurTexCoords[%index%] = textureCoord + vec2(0.0, %sampleIndex% * strength);";for(var s=0;s<t;s++){var a=n.replace("%index%",s.toString());a=a.replace("%sampleIndex%",s-(r-1)+".0"),o+=a,o+="\n"}return i=i.replace("%blur%",o),i=i.replace("%size%",t.toString()),i}var kr,Xr,jr,Hr,Vr,Yr,Wr,zr,$r,qr,Kr,Zr,Jr,Qr,ti,ei,ni,ri,ii,oi={5:[.153388,.221461,.250301],7:[.071303,.131514,.189879,.214607],9:[.028532,.067234,.124009,.179044,.20236],11:[.0093,.028002,.065984,.121703,.175713,.198596],13:[.002406,.009255,.027867,.065666,.121117,.174868,.197641],15:[489e-6,.002403,.009246,.02784,.065602,.120999,.174697,.197448]},si=["varying vec2 vBlurTexCoords[%size%];","uniform sampler2D uSampler;","void main(void)","{"," gl_FragColor = vec4(0.0);"," %blur%","}"].join("\n");function ai(t){for(var e,n=oi[t],r=n.length,i=si,o="",s="gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;",a=0;a<t;a++){var u=s.replace("%index%",a.toString());e=a,a>=r&&(e=t-a-1),u=u.replace("%value%",n[e].toString()),o+=u,o+="\n"}return i=i.replace("%blur%",o),i=i.replace("%size%",t.toString()),i} -/*! - * @pixi/constants - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/constants is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */(function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"})(kr||(kr={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(Xr||(Xr={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(jr||(jr={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(Hr||(Hr={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(Vr||(Vr={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(Yr||(Yr={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(Wr||(Wr={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(zr||(zr={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}($r||($r={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(qr||(qr={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(Kr||(Kr={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(Zr||(Zr={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(Jr||(Jr={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(Qr||(Qr={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(ti||(ti={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(ei||(ei={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(ni||(ni={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(ri||(ri={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(ii||(ii={}));var ui=function(t){function e(e,n,r,i,o){void 0===n&&(n=8),void 0===r&&(r=4),void 0===i&&(i=Le.X.FILTER_RESOLUTION),void 0===o&&(o=5);var s=this,a=Gr(o,e),u=ai(o);return s=t.call(this,a,u)||this,s.horizontal=e,s.resolution=i,s._quality=0,s.quality=r,s.blur=n,s}return Br(e,t),e.prototype.apply=function(t,e,n,r){if(n?this.horizontal?this.uniforms.strength=1/n.width*(n.width/e.width):this.uniforms.strength=1/n.height*(n.height/e.height):this.horizontal?this.uniforms.strength=1/t.renderer.width*(t.renderer.width/e.width):this.uniforms.strength=1/t.renderer.height*(t.renderer.height/e.height),this.uniforms.strength*=this.strength,this.uniforms.strength/=this.passes,1===this.passes)t.applyFilter(this,e,n,r);else{var i=t.getFilterTexture(),o=t.renderer,s=e,a=i;this.state.blend=!1,t.applyFilter(this,s,a,Qr.CLEAR);for(var u=1;u<this.passes-1;u++){t.bindAndClear(s,Qr.BLIT),this.uniforms.uSampler=a;var l=a;a=s,s=l,o.shader.bind(this),o.geometry.draw(5)}this.state.blend=!0,t.applyFilter(this,a,n,r),t.returnFilterTexture(i)}},Object.defineProperty(e.prototype,"blur",{get:function(){return this.strength},set:function(t){this.padding=1+2*Math.abs(t),this.strength=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"quality",{get:function(){return this._quality},set:function(t){this._quality=t,this.passes=t},enumerable:!1,configurable:!0}),e}(J.wn),li=(function(t){function e(e,n,r,i){void 0===e&&(e=8),void 0===n&&(n=4),void 0===r&&(r=Le.X.FILTER_RESOLUTION),void 0===i&&(i=5);var o=t.call(this)||this;return o.blurXFilter=new ui(!0,e,n,r,i),o.blurYFilter=new ui(!1,e,n,r,i),o.resolution=r,o.quality=n,o.blur=e,o.repeatEdgePixels=!1,o}Br(e,t),e.prototype.apply=function(t,e,n,r){var i=Math.abs(this.blurXFilter.strength),o=Math.abs(this.blurYFilter.strength);if(i&&o){var s=t.getFilterTexture();this.blurXFilter.apply(t,e,s,Qr.CLEAR),this.blurYFilter.apply(t,s,n,r),t.returnFilterTexture(s)}else o?this.blurYFilter.apply(t,e,n,r):this.blurXFilter.apply(t,e,n,r)},e.prototype.updatePadding=function(){this._repeatEdgePixels?this.padding=0:this.padding=2*Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))},Object.defineProperty(e.prototype,"blur",{get:function(){return this.blurXFilter.blur},set:function(t){this.blurXFilter.blur=this.blurYFilter.blur=t,this.updatePadding()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"quality",{get:function(){return this.blurXFilter.quality},set:function(t){this.blurXFilter.quality=this.blurYFilter.quality=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blurX",{get:function(){return this.blurXFilter.blur},set:function(t){this.blurXFilter.blur=t,this.updatePadding()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blurY",{get:function(){return this.blurYFilter.blur},set:function(t){this.blurYFilter.blur=t,this.updatePadding()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.blurYFilter.blendMode},set:function(t){this.blurYFilter.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"repeatEdgePixels",{get:function(){return this._repeatEdgePixels},set:function(t){this._repeatEdgePixels=t,this.updatePadding()},enumerable:!1,configurable:!0})}(J.wn),function(t,e){return li=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},li(t,e)});function ci(t,e){function n(){this.constructor=t}li(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var hi="varying vec2 vTextureCoord;\nuniform sampler2D uSampler;\nuniform float m[20];\nuniform float uAlpha;\n\nvoid main(void)\n{\n vec4 c = texture2D(uSampler, vTextureCoord);\n\n if (uAlpha == 0.0) {\n gl_FragColor = c;\n return;\n }\n\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\n if (c.a > 0.0) {\n c.rgb /= c.a;\n }\n\n vec4 result;\n\n result.r = (m[0] * c.r);\n result.r += (m[1] * c.g);\n result.r += (m[2] * c.b);\n result.r += (m[3] * c.a);\n result.r += m[4];\n\n result.g = (m[5] * c.r);\n result.g += (m[6] * c.g);\n result.g += (m[7] * c.b);\n result.g += (m[8] * c.a);\n result.g += m[9];\n\n result.b = (m[10] * c.r);\n result.b += (m[11] * c.g);\n result.b += (m[12] * c.b);\n result.b += (m[13] * c.a);\n result.b += m[14];\n\n result.a = (m[15] * c.r);\n result.a += (m[16] * c.g);\n result.a += (m[17] * c.b);\n result.a += (m[18] * c.a);\n result.a += m[19];\n\n vec3 rgb = mix(c.rgb, result.rgb, uAlpha);\n\n // Premultiply alpha again.\n rgb *= result.a;\n\n gl_FragColor = vec4(rgb, result.a);\n}\n",fi=function(t){function e(){var e=this,n={m:new Float32Array([1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0]),uAlpha:1};return e=t.call(this,J.Y9,hi,n)||this,e.alpha=1,e}return ci(e,t),e.prototype._loadMatrix=function(t,e){void 0===e&&(e=!1);var n=t;e&&(this._multiply(n,this.uniforms.m,t),n=this._colorMatrix(n)),this.uniforms.m=n},e.prototype._multiply=function(t,e,n){return t[0]=e[0]*n[0]+e[1]*n[5]+e[2]*n[10]+e[3]*n[15],t[1]=e[0]*n[1]+e[1]*n[6]+e[2]*n[11]+e[3]*n[16],t[2]=e[0]*n[2]+e[1]*n[7]+e[2]*n[12]+e[3]*n[17],t[3]=e[0]*n[3]+e[1]*n[8]+e[2]*n[13]+e[3]*n[18],t[4]=e[0]*n[4]+e[1]*n[9]+e[2]*n[14]+e[3]*n[19]+e[4],t[5]=e[5]*n[0]+e[6]*n[5]+e[7]*n[10]+e[8]*n[15],t[6]=e[5]*n[1]+e[6]*n[6]+e[7]*n[11]+e[8]*n[16],t[7]=e[5]*n[2]+e[6]*n[7]+e[7]*n[12]+e[8]*n[17],t[8]=e[5]*n[3]+e[6]*n[8]+e[7]*n[13]+e[8]*n[18],t[9]=e[5]*n[4]+e[6]*n[9]+e[7]*n[14]+e[8]*n[19]+e[9],t[10]=e[10]*n[0]+e[11]*n[5]+e[12]*n[10]+e[13]*n[15],t[11]=e[10]*n[1]+e[11]*n[6]+e[12]*n[11]+e[13]*n[16],t[12]=e[10]*n[2]+e[11]*n[7]+e[12]*n[12]+e[13]*n[17],t[13]=e[10]*n[3]+e[11]*n[8]+e[12]*n[13]+e[13]*n[18],t[14]=e[10]*n[4]+e[11]*n[9]+e[12]*n[14]+e[13]*n[19]+e[14],t[15]=e[15]*n[0]+e[16]*n[5]+e[17]*n[10]+e[18]*n[15],t[16]=e[15]*n[1]+e[16]*n[6]+e[17]*n[11]+e[18]*n[16],t[17]=e[15]*n[2]+e[16]*n[7]+e[17]*n[12]+e[18]*n[17],t[18]=e[15]*n[3]+e[16]*n[8]+e[17]*n[13]+e[18]*n[18],t[19]=e[15]*n[4]+e[16]*n[9]+e[17]*n[14]+e[18]*n[19]+e[19],t},e.prototype._colorMatrix=function(t){var e=new Float32Array(t);return e[4]/=255,e[9]/=255,e[14]/=255,e[19]/=255,e},e.prototype.brightness=function(t,e){var n=[t,0,0,0,0,0,t,0,0,0,0,0,t,0,0,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.tint=function(t,e){var n=t>>16&255,r=t>>8&255,i=255&t,o=[n/255,0,0,0,0,0,r/255,0,0,0,0,0,i/255,0,0,0,0,0,1,0];this._loadMatrix(o,e)},e.prototype.greyscale=function(t,e){var n=[t,t,t,0,0,t,t,t,0,0,t,t,t,0,0,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.blackAndWhite=function(t){var e=[.3,.6,.1,0,0,.3,.6,.1,0,0,.3,.6,.1,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.hue=function(t,e){t=(t||0)/180*Math.PI;var n=Math.cos(t),r=Math.sin(t),i=Math.sqrt,o=1/3,s=i(o),a=n+(1-n)*o,u=o*(1-n)-s*r,l=o*(1-n)+s*r,c=o*(1-n)+s*r,h=n+o*(1-n),f=o*(1-n)-s*r,d=o*(1-n)-s*r,p=o*(1-n)+s*r,v=n+o*(1-n),m=[a,u,l,0,0,c,h,f,0,0,d,p,v,0,0,0,0,0,1,0];this._loadMatrix(m,e)},e.prototype.contrast=function(t,e){var n=(t||0)+1,r=-.5*(n-1),i=[n,0,0,0,r,0,n,0,0,r,0,0,n,0,r,0,0,0,1,0];this._loadMatrix(i,e)},e.prototype.saturate=function(t,e){void 0===t&&(t=0);var n=2*t/3+1,r=-.5*(n-1),i=[n,r,r,0,0,r,n,r,0,0,r,r,n,0,0,0,0,0,1,0];this._loadMatrix(i,e)},e.prototype.desaturate=function(){this.saturate(-1)},e.prototype.negative=function(t){var e=[-1,0,0,1,0,0,-1,0,1,0,0,0,-1,1,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.sepia=function(t){var e=[.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.technicolor=function(t){var e=[1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.polaroid=function(t){var e=[1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.toBGR=function(t){var e=[0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.kodachrome=function(t){var e=[1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.browni=function(t){var e=[.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.vintage=function(t){var e=[.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.colorTone=function(t,e,n,r,i){t=t||.2,e=e||.15,n=n||16770432,r=r||3375104;var o=(n>>16&255)/255,s=(n>>8&255)/255,a=(255&n)/255,u=(r>>16&255)/255,l=(r>>8&255)/255,c=(255&r)/255,h=[.3,.59,.11,0,0,o,s,a,t,0,u,l,c,e,0,o-u,s-l,a-c,0,0];this._loadMatrix(h,i)},e.prototype.night=function(t,e){t=t||.1;var n=[-2*t,-t,0,0,0,-t,0,t,0,0,0,t,2*t,0,0,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.predator=function(t,e){var n=[11.224130630493164*t,-4.794486999511719*t,-2.8746118545532227*t,0*t,.40342438220977783*t,-3.6330697536468506*t,9.193157196044922*t,-2.951810836791992*t,0*t,-1.316135048866272*t,-3.2184197902679443*t,-4.2375030517578125*t,7.476448059082031*t,0*t,.8044459223747253*t,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.lsd=function(t){var e=[2,-.4,.5,0,0,-.5,2,-.4,0,0,-.4,-.5,3,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.reset=function(){var t=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0];this._loadMatrix(t,!1)},Object.defineProperty(e.prototype,"matrix",{get:function(){return this.uniforms.m},set:function(t){this.uniforms.m=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alpha",{get:function(){return this.uniforms.uAlpha},set:function(t){this.uniforms.uAlpha=t},enumerable:!1,configurable:!0}),e}(J.wn);fi.prototype.grayscale=fi.prototype.greyscale; -/*! - * @pixi/filter-displacement - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/filter-displacement is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ -var di=function(t,e){return di=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},di(t,e)};function pi(t,e){function n(){this.constructor=t}di(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var vi="varying vec2 vFilterCoord;\nvarying vec2 vTextureCoord;\n\nuniform vec2 scale;\nuniform mat2 rotation;\nuniform sampler2D uSampler;\nuniform sampler2D mapSampler;\n\nuniform highp vec4 inputSize;\nuniform vec4 inputClamp;\n\nvoid main(void)\n{\n vec4 map = texture2D(mapSampler, vFilterCoord);\n\n map -= 0.5;\n map.xy = scale * inputSize.zw * (rotation * map.xy);\n\n gl_FragColor = texture2D(uSampler, clamp(vec2(vTextureCoord.x + map.x, vTextureCoord.y + map.y), inputClamp.xy, inputClamp.zw));\n}\n",mi="attribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\nuniform mat3 filterMatrix;\n\nvarying vec2 vTextureCoord;\nvarying vec2 vFilterCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvec2 filterTextureCoord( void )\n{\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n}\n\nvoid main(void)\n{\n\tgl_Position = filterVertexPosition();\n\tvTextureCoord = filterTextureCoord();\n\tvFilterCoord = ( filterMatrix * vec3( vTextureCoord, 1.0) ).xy;\n}\n",gi=(function(t){function e(e,n){var r=this,i=new k.y3;return e.renderable=!1,r=t.call(this,mi,vi,{mapSampler:e._texture,filterMatrix:i,scale:{x:1,y:1},rotation:new Float32Array([1,0,0,1])})||this,r.maskSprite=e,r.maskMatrix=i,null!==n&&void 0!==n||(n=20),r.scale=new k.E9(n,n),r}pi(e,t),e.prototype.apply=function(t,e,n,r){this.uniforms.filterMatrix=t.calculateSpriteMatrix(this.maskMatrix,this.maskSprite),this.uniforms.scale.x=this.scale.x,this.uniforms.scale.y=this.scale.y;var i=this.maskSprite.worldTransform,o=Math.sqrt(i.a*i.a+i.b*i.b),s=Math.sqrt(i.c*i.c+i.d*i.d);0!==o&&0!==s&&(this.uniforms.rotation[0]=i.a/o,this.uniforms.rotation[1]=i.b/o,this.uniforms.rotation[2]=i.c/s,this.uniforms.rotation[3]=i.d/s),t.applyFilter(this,e,n,r)},Object.defineProperty(e.prototype,"map",{get:function(){return this.uniforms.mapSampler},set:function(t){this.uniforms.mapSampler=t},enumerable:!1,configurable:!0})}(J.wn),function(t,e){return gi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},gi(t,e)});function _i(t,e){function n(){this.constructor=t}gi(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var yi="\nattribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 v_rgbNW;\nvarying vec2 v_rgbNE;\nvarying vec2 v_rgbSW;\nvarying vec2 v_rgbSE;\nvarying vec2 v_rgbM;\n\nvarying vec2 vFragCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvoid texcoords(vec2 fragCoord, vec2 inverseVP,\n out vec2 v_rgbNW, out vec2 v_rgbNE,\n out vec2 v_rgbSW, out vec2 v_rgbSE,\n out vec2 v_rgbM) {\n v_rgbNW = (fragCoord + vec2(-1.0, -1.0)) * inverseVP;\n v_rgbNE = (fragCoord + vec2(1.0, -1.0)) * inverseVP;\n v_rgbSW = (fragCoord + vec2(-1.0, 1.0)) * inverseVP;\n v_rgbSE = (fragCoord + vec2(1.0, 1.0)) * inverseVP;\n v_rgbM = vec2(fragCoord * inverseVP);\n}\n\nvoid main(void) {\n\n gl_Position = filterVertexPosition();\n\n vFragCoord = aVertexPosition * outputFrame.zw;\n\n texcoords(vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n}\n",bi='varying vec2 v_rgbNW;\nvarying vec2 v_rgbNE;\nvarying vec2 v_rgbSW;\nvarying vec2 v_rgbSE;\nvarying vec2 v_rgbM;\n\nvarying vec2 vFragCoord;\nuniform sampler2D uSampler;\nuniform highp vec4 inputSize;\n\n\n/**\n Basic FXAA implementation based on the code on geeks3d.com with the\n modification that the texture2DLod stuff was removed since it\'s\n unsupported by WebGL.\n\n --\n\n From:\n https://github.com/mitsuhiko/webgl-meincraft\n\n Copyright (c) 2011 by Armin Ronacher.\n\n Some rights reserved.\n\n Redistribution and use in source and binary forms, with or without\n modification, are permitted provided that the following conditions are\n met:\n\n * Redistributions of source code must retain the above copyright\n notice, this list of conditions and the following disclaimer.\n\n * Redistributions in binary form must reproduce the above\n copyright notice, this list of conditions and the following\n disclaimer in the documentation and/or other materials provided\n with the distribution.\n\n * The names of the contributors may not be used to endorse or\n promote products derived from this software without specific\n prior written permission.\n\n THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\n#ifndef FXAA_REDUCE_MIN\n#define FXAA_REDUCE_MIN (1.0/ 128.0)\n#endif\n#ifndef FXAA_REDUCE_MUL\n#define FXAA_REDUCE_MUL (1.0 / 8.0)\n#endif\n#ifndef FXAA_SPAN_MAX\n#define FXAA_SPAN_MAX 8.0\n#endif\n\n//optimized version for mobile, where dependent\n//texture reads can be a bottleneck\nvec4 fxaa(sampler2D tex, vec2 fragCoord, vec2 inverseVP,\n vec2 v_rgbNW, vec2 v_rgbNE,\n vec2 v_rgbSW, vec2 v_rgbSE,\n vec2 v_rgbM) {\n vec4 color;\n vec3 rgbNW = texture2D(tex, v_rgbNW).xyz;\n vec3 rgbNE = texture2D(tex, v_rgbNE).xyz;\n vec3 rgbSW = texture2D(tex, v_rgbSW).xyz;\n vec3 rgbSE = texture2D(tex, v_rgbSE).xyz;\n vec4 texColor = texture2D(tex, v_rgbM);\n vec3 rgbM = texColor.xyz;\n vec3 luma = vec3(0.299, 0.587, 0.114);\n float lumaNW = dot(rgbNW, luma);\n float lumaNE = dot(rgbNE, luma);\n float lumaSW = dot(rgbSW, luma);\n float lumaSE = dot(rgbSE, luma);\n float lumaM = dot(rgbM, luma);\n float lumaMin = min(lumaM, min(min(lumaNW, lumaNE), min(lumaSW, lumaSE)));\n float lumaMax = max(lumaM, max(max(lumaNW, lumaNE), max(lumaSW, lumaSE)));\n\n mediump vec2 dir;\n dir.x = -((lumaNW + lumaNE) - (lumaSW + lumaSE));\n dir.y = ((lumaNW + lumaSW) - (lumaNE + lumaSE));\n\n float dirReduce = max((lumaNW + lumaNE + lumaSW + lumaSE) *\n (0.25 * FXAA_REDUCE_MUL), FXAA_REDUCE_MIN);\n\n float rcpDirMin = 1.0 / (min(abs(dir.x), abs(dir.y)) + dirReduce);\n dir = min(vec2(FXAA_SPAN_MAX, FXAA_SPAN_MAX),\n max(vec2(-FXAA_SPAN_MAX, -FXAA_SPAN_MAX),\n dir * rcpDirMin)) * inverseVP;\n\n vec3 rgbA = 0.5 * (\n texture2D(tex, fragCoord * inverseVP + dir * (1.0 / 3.0 - 0.5)).xyz +\n texture2D(tex, fragCoord * inverseVP + dir * (2.0 / 3.0 - 0.5)).xyz);\n vec3 rgbB = rgbA * 0.5 + 0.25 * (\n texture2D(tex, fragCoord * inverseVP + dir * -0.5).xyz +\n texture2D(tex, fragCoord * inverseVP + dir * 0.5).xyz);\n\n float lumaB = dot(rgbB, luma);\n if ((lumaB < lumaMin) || (lumaB > lumaMax))\n color = vec4(rgbA, texColor.a);\n else\n color = vec4(rgbB, texColor.a);\n return color;\n}\n\nvoid main() {\n\n vec4 color;\n\n color = fxaa(uSampler, vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n\n gl_FragColor = color;\n}\n',Ei=(function(t){function e(){return t.call(this,yi,bi)||this}_i(e,t)}(J.wn),function(t,e){return Ei=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Ei(t,e)});function xi(t,e){function n(){this.constructor=t}Ei(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Ti,Si,Ri,Ai,Oi,wi,Ii,Pi,Ci,Ni,Mi,Di,Li,Fi,Bi,Ui,Gi,ki,Xi,ji="precision highp float;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nuniform float uNoise;\nuniform float uSeed;\nuniform sampler2D uSampler;\n\nfloat rand(vec2 co)\n{\n return fract(sin(dot(co.xy, vec2(12.9898, 78.233))) * 43758.5453);\n}\n\nvoid main()\n{\n vec4 color = texture2D(uSampler, vTextureCoord);\n float randomValue = rand(gl_FragCoord.xy * uSeed);\n float diff = (randomValue - 0.5) * uNoise;\n\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\n if (color.a > 0.0) {\n color.rgb /= color.a;\n }\n\n color.r += diff;\n color.g += diff;\n color.b += diff;\n\n // Premultiply alpha again.\n color.rgb *= color.a;\n\n gl_FragColor = color;\n}\n";(function(t){function e(e,n){void 0===e&&(e=.5),void 0===n&&(n=Math.random());var r=t.call(this,J.Y9,ji,{uNoise:0,uSeed:0})||this;return r.noise=e,r.seed=n,r}xi(e,t),Object.defineProperty(e.prototype,"noise",{get:function(){return this.uniforms.uNoise},set:function(t){this.uniforms.uNoise=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"seed",{get:function(){return this.uniforms.uSeed},set:function(t){this.uniforms.uSeed=t},enumerable:!1,configurable:!0})})(J.wn);(function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"})(Ti||(Ti={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(Si||(Si={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(Ri||(Ri={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(Ai||(Ai={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(Oi||(Oi={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(wi||(wi={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(Ii||(Ii={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(Pi||(Pi={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(Ci||(Ci={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(Ni||(Ni={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(Mi||(Mi={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(Di||(Di={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(Li||(Li={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(Fi||(Fi={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(Bi||(Bi={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(Ui||(Ui={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(Gi||(Gi={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(ki||(ki={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(Xi||(Xi={}));var Hi=new k.y3;w.s$.prototype._cacheAsBitmap=!1,w.s$.prototype._cacheData=null,w.s$.prototype._cacheAsBitmapResolution=null,w.s$.prototype._cacheAsBitmapMultisample=ki.NONE;var Vi=function(){function t(){this.textureCacheId=null,this.originalRender=null,this.originalRenderCanvas=null,this.originalCalculateBounds=null,this.originalGetLocalBounds=null,this.originalUpdateTransform=null,this.originalDestroy=null,this.originalMask=null,this.originalFilterArea=null,this.originalContainsPoint=null,this.sprite=null}return t}();Object.defineProperties(w.s$.prototype,{cacheAsBitmapResolution:{get:function(){return this._cacheAsBitmapResolution},set:function(t){t!==this._cacheAsBitmapResolution&&(this._cacheAsBitmapResolution=t,this.cacheAsBitmap&&(this.cacheAsBitmap=!1,this.cacheAsBitmap=!0))}},cacheAsBitmapMultisample:{get:function(){return this._cacheAsBitmapMultisample},set:function(t){t!==this._cacheAsBitmapMultisample&&(this._cacheAsBitmapMultisample=t,this.cacheAsBitmap&&(this.cacheAsBitmap=!1,this.cacheAsBitmap=!0))}},cacheAsBitmap:{get:function(){return this._cacheAsBitmap},set:function(t){var e;this._cacheAsBitmap!==t&&(this._cacheAsBitmap=t,t?(this._cacheData||(this._cacheData=new Vi),e=this._cacheData,e.originalRender=this.render,e.originalRenderCanvas=this.renderCanvas,e.originalUpdateTransform=this.updateTransform,e.originalCalculateBounds=this.calculateBounds,e.originalGetLocalBounds=this.getLocalBounds,e.originalDestroy=this.destroy,e.originalContainsPoint=this.containsPoint,e.originalMask=this._mask,e.originalFilterArea=this.filterArea,this.render=this._renderCached,this.renderCanvas=this._renderCachedCanvas,this.destroy=this._cacheAsBitmapDestroy):(e=this._cacheData,e.sprite&&this._destroyCachedDisplayObject(),this.render=e.originalRender,this.renderCanvas=e.originalRenderCanvas,this.calculateBounds=e.originalCalculateBounds,this.getLocalBounds=e.originalGetLocalBounds,this.destroy=e.originalDestroy,this.updateTransform=e.originalUpdateTransform,this.containsPoint=e.originalContainsPoint,this._mask=e.originalMask,this.filterArea=e.originalFilterArea))}}}),w.s$.prototype._renderCached=function(t){!this.visible||this.worldAlpha<=0||!this.renderable||(this._initCachedDisplayObject(t),this._cacheData.sprite.transform._worldID=this.transform._worldID,this._cacheData.sprite.worldAlpha=this.worldAlpha,this._cacheData.sprite._render(t))},w.s$.prototype._initCachedDisplayObject=function(t){var e;if(!this._cacheData||!this._cacheData.sprite){var n=this.alpha;this.alpha=1,t.batch.flush();var r=this.getLocalBounds(null,!0).clone();if(this.filters&&this.filters.length){var i=this.filters[0].padding;r.pad(i)}r.ceil(Le.X.RESOLUTION);var o=t.renderTexture.current,s=t.renderTexture.sourceFrame.clone(),a=t.renderTexture.destinationFrame.clone(),u=t.projection.transform,l=J.TI.create({width:r.width,height:r.height,resolution:this.cacheAsBitmapResolution||t.resolution,multisample:null!==(e=this.cacheAsBitmapMultisample)&&void 0!==e?e:t.multisample}),c="cacheAsBitmap_"+(0,O.hQ)();this._cacheData.textureCacheId=c,J.VL.addToCache(l.baseTexture,c),J.xE.addToCache(l,c);var h=this.transform.localTransform.copyTo(Hi).invert().translate(-r.x,-r.y);this.render=this._cacheData.originalRender,t.render(this,{renderTexture:l,clear:!0,transform:h,skipUpdateTransform:!1}),t.framebuffer.blit(),t.projection.transform=u,t.renderTexture.bind(o,s,a),this.render=this._renderCached,this.updateTransform=this.displayObjectUpdateTransform,this.calculateBounds=this._calculateCachedBounds,this.getLocalBounds=this._getCachedLocalBounds,this._mask=null,this.filterArea=null,this.alpha=n;var f=new mn.j(l);f.transform.worldTransform=this.transform.worldTransform,f.anchor.x=-r.x/r.width,f.anchor.y=-r.y/r.height,f.alpha=n,f._bounds=this._bounds,this._cacheData.sprite=f,this.transform._parentID=-1,this.parent?this.updateTransform():(this.enableTempParent(),this.updateTransform(),this.disableTempParent(null)),this.containsPoint=f.containsPoint.bind(f)}},w.s$.prototype._renderCachedCanvas=function(t){!this.visible||this.worldAlpha<=0||!this.renderable||(this._initCachedDisplayObjectCanvas(t),this._cacheData.sprite.worldAlpha=this.worldAlpha,this._cacheData.sprite._renderCanvas(t))},w.s$.prototype._initCachedDisplayObjectCanvas=function(t){if(!this._cacheData||!this._cacheData.sprite){var e=this.getLocalBounds(null,!0),n=this.alpha;this.alpha=1;var r=t.context,i=t._projTransform;e.ceil(Le.X.RESOLUTION);var o=J.TI.create({width:e.width,height:e.height}),s="cacheAsBitmap_"+(0,O.hQ)();this._cacheData.textureCacheId=s,J.VL.addToCache(o.baseTexture,s),J.xE.addToCache(o,s);var a=Hi;this.transform.localTransform.copyTo(a),a.invert(),a.tx-=e.x,a.ty-=e.y,this.renderCanvas=this._cacheData.originalRenderCanvas,t.render(this,{renderTexture:o,clear:!0,transform:a,skipUpdateTransform:!1}),t.context=r,t._projTransform=i,this.renderCanvas=this._renderCachedCanvas,this.updateTransform=this.displayObjectUpdateTransform,this.calculateBounds=this._calculateCachedBounds,this.getLocalBounds=this._getCachedLocalBounds,this._mask=null,this.filterArea=null,this.alpha=n;var u=new mn.j(o);u.transform.worldTransform=this.transform.worldTransform,u.anchor.x=-e.x/e.width,u.anchor.y=-e.y/e.height,u.alpha=n,u._bounds=this._bounds,this._cacheData.sprite=u,this.transform._parentID=-1,this.parent?this.updateTransform():(this.parent=t._tempDisplayObjectParent,this.updateTransform(),this.parent=null),this.containsPoint=u.containsPoint.bind(u)}},w.s$.prototype._calculateCachedBounds=function(){this._bounds.clear(),this._cacheData.sprite.transform._worldID=this.transform._worldID,this._cacheData.sprite._calculateBounds(),this._bounds.updateID=this._boundsID},w.s$.prototype._getCachedLocalBounds=function(){return this._cacheData.sprite.getLocalBounds(null)},w.s$.prototype._destroyCachedDisplayObject=function(){this._cacheData.sprite._texture.destroy(!0),this._cacheData.sprite=null,J.VL.removeFromCache(this._cacheData.textureCacheId),J.xE.removeFromCache(this._cacheData.textureCacheId),this._cacheData.textureCacheId=null},w.s$.prototype._cacheAsBitmapDestroy=function(t){this.cacheAsBitmap=!1,this.destroy(t)}, -/*! - * @pixi/mixin-get-child-by-name - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/mixin-get-child-by-name is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -w.s$.prototype.name=null,w.W2.prototype.getChildByName=function(t,e){for(var n=0,r=this.children.length;n<r;n++)if(this.children[n].name===t)return this.children[n];if(e)for(n=0,r=this.children.length;n<r;n++){var i=this.children[n];if(i.getChildByName){var o=this.children[n].getChildByName(t,!0);if(o)return o}}return null}, -/*! - * @pixi/mixin-get-global-position - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/mixin-get-global-position is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -w.s$.prototype.getGlobalPosition=function(t,e){return void 0===t&&(t=new k.E9),void 0===e&&(e=!1),this.parent?this.parent.toGlobal(this.position,t,e):(t.x=this.position.x,t.y=this.position.y),t}; -/*! - * @pixi/mesh-extras - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/mesh-extras is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ -var Yi=function(t,e){return Yi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Yi(t,e)};function Wi(t,e){function n(){this.constructor=t}Yi(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var zi=function(t){function e(e,n,r,i){void 0===e&&(e=100),void 0===n&&(n=100),void 0===r&&(r=10),void 0===i&&(i=10);var o=t.call(this)||this;return o.segWidth=r,o.segHeight=i,o.width=e,o.height=n,o.build(),o}return Wi(e,t),e.prototype.build=function(){for(var t=this.segWidth*this.segHeight,e=[],n=[],r=[],i=this.segWidth-1,o=this.segHeight-1,s=this.width/i,a=this.height/o,u=0;u<t;u++){var l=u%this.segWidth,c=u/this.segWidth|0;e.push(l*s,c*a),n.push(l/i,c/o)}var h=i*o;for(u=0;u<h;u++){var f=u%i,d=u/i|0,p=d*this.segWidth+f,v=d*this.segWidth+f+1,m=(d+1)*this.segWidth+f,g=(d+1)*this.segWidth+f+1;r.push(p,v,m,v,g,m)}this.buffers[0].data=new Float32Array(e),this.buffers[1].data=new Float32Array(n),this.indexBuffer.data=new Uint16Array(r),this.buffers[0].update(),this.buffers[1].update(),this.indexBuffer.update()},e}(fr),$i=function(t){function e(e,n,r){void 0===e&&(e=200),void 0===r&&(r=0);var i=t.call(this,new Float32Array(4*n.length),new Float32Array(4*n.length),new Uint16Array(6*(n.length-1)))||this;return i.points=n,i._width=e,i.textureScale=r,i.build(),i}return Wi(e,t),Object.defineProperty(e.prototype,"width",{get:function(){return this._width},enumerable:!1,configurable:!0}),e.prototype.build=function(){var t=this.points;if(t){var e=this.getBuffer("aVertexPosition"),n=this.getBuffer("aTextureCoord"),r=this.getIndex();if(!(t.length<1)){e.data.length/4!==t.length&&(e.data=new Float32Array(4*t.length),n.data=new Float32Array(4*t.length),r.data=new Uint16Array(6*(t.length-1)));var i=n.data,o=r.data;i[0]=0,i[1]=0,i[2]=0,i[3]=1;for(var s=0,a=t[0],u=this._width*this.textureScale,l=t.length,c=0;c<l;c++){var h=4*c;if(this.textureScale>0){var f=a.x-t[c].x,d=a.y-t[c].y,p=Math.sqrt(f*f+d*d);a=t[c],s+=p/u}else s=c/(l-1);i[h]=s,i[h+1]=0,i[h+2]=s,i[h+3]=1}var v=0;for(c=0;c<l-1;c++){h=2*c;o[v++]=h,o[v++]=h+1,o[v++]=h+2,o[v++]=h+2,o[v++]=h+1,o[v++]=h+3}n.update(),r.update(),this.updateVertices()}}},e.prototype.updateVertices=function(){var t=this.points;if(!(t.length<1)){for(var e,n=t[0],r=0,i=0,o=this.buffers[0].data,s=t.length,a=0;a<s;a++){var u=t[a],l=4*a;e=a<t.length-1?t[a+1]:u,i=-(e.x-n.x),r=e.y-n.y;var c=Math.sqrt(r*r+i*i),h=this.textureScale>0?this.textureScale*this._width/2:this._width/2;r/=c,i/=c,r*=h,i*=h,o[l]=u.x+r,o[l+1]=u.y+i,o[l+2]=u.x-r,o[l+3]=u.y-i,n=u}this.buffers[0].update()}},e.prototype.update=function(){this.textureScale>0?this.build():this.updateVertices()},e}(fr),qi=(function(t){function e(e,n,r){void 0===r&&(r=0);var i=this,o=new $i(e.height,n,r),s=new hr(e);return r>0&&(e.baseTexture.wrapMode=Dt.Nt.REPEAT),i=t.call(this,o,s)||this,i.autoUpdate=!0,i}Wi(e,t),e.prototype._render=function(e){var n=this.geometry;(this.autoUpdate||n._width!==this.shader.texture.height)&&(n._width=this.shader.texture.height,n.update()),t.prototype._render.call(this,e)}}(ur),function(t){function e(e,n,r){var i=this,o=new zi(e.width,e.height,n,r),s=new hr(J.xE.WHITE);return i=t.call(this,o,s)||this,i.texture=e,i.autoResize=!0,i}return Wi(e,t),e.prototype.textureUpdated=function(){this._textureID=this.shader.texture._updateID;var t=this.geometry,e=this.shader.texture,n=e.width,r=e.height;!this.autoResize||t.width===n&&t.height===r||(t.width=this.shader.texture.width,t.height=this.shader.texture.height,t.build())},Object.defineProperty(e.prototype,"texture",{get:function(){return this.shader.texture},set:function(t){this.shader.texture!==t&&(this.shader.texture=t,this._textureID=-1,t.baseTexture.valid?this.textureUpdated():t.once("update",this.textureUpdated,this))},enumerable:!1,configurable:!0}),e.prototype._render=function(e){this._textureID!==this.shader.texture._updateID&&this.textureUpdated(),t.prototype._render.call(this,e)},e.prototype.destroy=function(e){this.shader.texture.off("update",this.textureUpdated,this),t.prototype.destroy.call(this,e)},e}(ur)),Ki=(function(t){function e(e,n,r,i,o){void 0===e&&(e=J.xE.EMPTY);var s=this,a=new fr(n,r,i);a.getBuffer("aVertexPosition").static=!1;var u=new hr(e);return s=t.call(this,a,u,null,o)||this,s.autoUpdate=!0,s}Wi(e,t),Object.defineProperty(e.prototype,"vertices",{get:function(){return this.geometry.getBuffer("aVertexPosition").data},set:function(t){this.geometry.getBuffer("aVertexPosition").data=t},enumerable:!1,configurable:!0}),e.prototype._render=function(e){this.autoUpdate&&this.geometry.getBuffer("aVertexPosition").update(),t.prototype._render.call(this,e)}}(ur),10),Zi=(function(t){function e(e,n,r,i,o){void 0===n&&(n=Ki),void 0===r&&(r=Ki),void 0===i&&(i=Ki),void 0===o&&(o=Ki);var s=t.call(this,J.xE.WHITE,4,4)||this;return s._origWidth=e.orig.width,s._origHeight=e.orig.height,s._width=s._origWidth,s._height=s._origHeight,s._leftWidth=n,s._rightWidth=i,s._topHeight=r,s._bottomHeight=o,s.texture=e,s}Wi(e,t),e.prototype.textureUpdated=function(){this._textureID=this.shader.texture._updateID,this._refresh()},Object.defineProperty(e.prototype,"vertices",{get:function(){return this.geometry.getBuffer("aVertexPosition").data},set:function(t){this.geometry.getBuffer("aVertexPosition").data=t},enumerable:!1,configurable:!0}),e.prototype.updateHorizontalVertices=function(){var t=this.vertices,e=this._getMinScale();t[9]=t[11]=t[13]=t[15]=this._topHeight*e,t[17]=t[19]=t[21]=t[23]=this._height-this._bottomHeight*e,t[25]=t[27]=t[29]=t[31]=this._height},e.prototype.updateVerticalVertices=function(){var t=this.vertices,e=this._getMinScale();t[2]=t[10]=t[18]=t[26]=this._leftWidth*e,t[4]=t[12]=t[20]=t[28]=this._width-this._rightWidth*e,t[6]=t[14]=t[22]=t[30]=this._width},e.prototype._getMinScale=function(){var t=this._leftWidth+this._rightWidth,e=this._width>t?1:this._width/t,n=this._topHeight+this._bottomHeight,r=this._height>n?1:this._height/n,i=Math.min(e,r);return i},Object.defineProperty(e.prototype,"width",{get:function(){return this._width},set:function(t){this._width=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this._height},set:function(t){this._height=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"leftWidth",{get:function(){return this._leftWidth},set:function(t){this._leftWidth=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rightWidth",{get:function(){return this._rightWidth},set:function(t){this._rightWidth=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"topHeight",{get:function(){return this._topHeight},set:function(t){this._topHeight=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottomHeight",{get:function(){return this._bottomHeight},set:function(t){this._bottomHeight=t,this._refresh()},enumerable:!1,configurable:!0}),e.prototype._refresh=function(){var t=this.texture,e=this.geometry.buffers[1].data;this._origWidth=t.orig.width,this._origHeight=t.orig.height;var n=1/this._origWidth,r=1/this._origHeight;e[0]=e[8]=e[16]=e[24]=0,e[1]=e[3]=e[5]=e[7]=0,e[6]=e[14]=e[22]=e[30]=1,e[25]=e[27]=e[29]=e[31]=1,e[2]=e[10]=e[18]=e[26]=n*this._leftWidth,e[4]=e[12]=e[20]=e[28]=1-n*this._rightWidth,e[9]=e[11]=e[13]=e[15]=r*this._topHeight,e[17]=e[19]=e[21]=e[23]=1-r*this._bottomHeight,this.updateHorizontalVertices(),this.updateVerticalVertices(),this.geometry.buffers[0].update(),this.geometry.buffers[1].update()}}(qi),n(1034),function(t,e){return Zi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Zi(t,e)});function Ji(t,e){function n(){this.constructor=t}Zi(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}(function(t){function e(e,n){void 0===n&&(n=!0);var r=t.call(this,e[0]instanceof J.xE?e[0]:e[0].texture)||this;return r._textures=null,r._durations=null,r._autoUpdate=n,r._isConnectedToTicker=!1,r.animationSpeed=1,r.loop=!0,r.updateAnchor=!1,r.onComplete=null,r.onFrameChange=null,r.onLoop=null,r._currentTime=0,r._playing=!1,r._previousFrame=null,r.textures=e,r}Ji(e,t),e.prototype.stop=function(){this._playing&&(this._playing=!1,this._autoUpdate&&this._isConnectedToTicker&&(X.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1))},e.prototype.play=function(){this._playing||(this._playing=!0,this._autoUpdate&&!this._isConnectedToTicker&&(X.vB.shared.add(this.update,this,X.uF.HIGH),this._isConnectedToTicker=!0))},e.prototype.gotoAndStop=function(t){this.stop();var e=this.currentFrame;this._currentTime=t,e!==this.currentFrame&&this.updateTexture()},e.prototype.gotoAndPlay=function(t){var e=this.currentFrame;this._currentTime=t,e!==this.currentFrame&&this.updateTexture(),this.play()},e.prototype.update=function(t){if(this._playing){var e=this.animationSpeed*t,n=this.currentFrame;if(null!==this._durations){var r=this._currentTime%1*this._durations[this.currentFrame];r+=e/60*1e3;while(r<0)this._currentTime--,r+=this._durations[this.currentFrame];var i=Math.sign(this.animationSpeed*t);this._currentTime=Math.floor(this._currentTime);while(r>=this._durations[this.currentFrame])r-=this._durations[this.currentFrame]*i,this._currentTime+=i;this._currentTime+=r/this._durations[this.currentFrame]}else this._currentTime+=e;this._currentTime<0&&!this.loop?(this.gotoAndStop(0),this.onComplete&&this.onComplete()):this._currentTime>=this._textures.length&&!this.loop?(this.gotoAndStop(this._textures.length-1),this.onComplete&&this.onComplete()):n!==this.currentFrame&&(this.loop&&this.onLoop&&(this.animationSpeed>0&&this.currentFrame<n||this.animationSpeed<0&&this.currentFrame>n)&&this.onLoop(),this.updateTexture())}},e.prototype.updateTexture=function(){var t=this.currentFrame;this._previousFrame!==t&&(this._previousFrame=t,this._texture=this._textures[t],this._textureID=-1,this._textureTrimmedID=-1,this._cachedTint=16777215,this.uvs=this._texture._uvs.uvsFloat32,this.updateAnchor&&this._anchor.copyFrom(this._texture.defaultAnchor),this.onFrameChange&&this.onFrameChange(this.currentFrame))},e.prototype.destroy=function(e){this.stop(),t.prototype.destroy.call(this,e),this.onComplete=null,this.onFrameChange=null,this.onLoop=null},e.fromFrames=function(t){for(var n=[],r=0;r<t.length;++r)n.push(J.xE.from(t[r]));return new e(n)},e.fromImages=function(t){for(var n=[],r=0;r<t.length;++r)n.push(J.xE.from(t[r]));return new e(n)},Object.defineProperty(e.prototype,"totalFrames",{get:function(){return this._textures.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textures",{get:function(){return this._textures},set:function(t){if(t[0]instanceof J.xE)this._textures=t,this._durations=null;else{this._textures=[],this._durations=[];for(var e=0;e<t.length;e++)this._textures.push(t[e].texture),this._durations.push(t[e].time)}this._previousFrame=null,this.gotoAndStop(0),this.updateTexture()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentFrame",{get:function(){var t=Math.floor(this._currentTime)%this._textures.length;return t<0&&(t+=this._textures.length),t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"playing",{get:function(){return this._playing},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"autoUpdate",{get:function(){return this._autoUpdate},set:function(t){t!==this._autoUpdate&&(this._autoUpdate=t,!this._autoUpdate&&this._isConnectedToTicker?(X.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1):this._autoUpdate&&!this._isConnectedToTicker&&this._playing&&(X.vB.shared.add(this.update,this),this._isConnectedToTicker=!0))},enumerable:!1,configurable:!0})})(mn.j); -/*! - * pixi.js - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * pixi.js is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -J.Th.registerPlugin("accessibility",G),J.Th.registerPlugin("extract",rt),J.Th.registerPlugin("interaction",Z),J.Th.registerPlugin("particle",De),J.Th.registerPlugin("prepare",Vn),J.Th.registerPlugin("batch",J.Bv),J.Th.registerPlugin("tilingSprite",nr),Rt.registerPlugin(Nr),Rt.registerPlugin(Vt),Rt.registerPlugin(_e),Rt.registerPlugin(Ae),Rt.registerPlugin(Wn),Q.registerPlugin(X.Sb),Q.registerPlugin(At)},2587:function(t){"use strict";function e(t,e){return Object.prototype.hasOwnProperty.call(t,e)}t.exports=function(t,n,r,i){n=n||"&",r=r||"=";var o={};if("string"!==typeof t||0===t.length)return o;var s=/\+/g;t=t.split(n);var a=1e3;i&&"number"===typeof i.maxKeys&&(a=i.maxKeys);var u=t.length;a>0&&u>a&&(u=a);for(var l=0;l<u;++l){var c,h,f,d,p=t[l].replace(s,"%20"),v=p.indexOf(r);v>=0?(c=p.substr(0,v),h=p.substr(v+1)):(c=p,h=""),f=decodeURIComponent(c),d=decodeURIComponent(h),e(o,f)?Array.isArray(o[f])?o[f].push(d):o[f]=[o[f],d]:o[f]=d}return o}},2361:function(t){"use strict";var e=function(t){switch(typeof t){case"string":return t;case"boolean":return t?"true":"false";case"number":return isFinite(t)?t:"";default:return""}};t.exports=function(t,n,r,i){return n=n||"&",r=r||"=",null===t&&(t=void 0),"object"===typeof t?Object.keys(t).map((function(i){var o=encodeURIComponent(e(i))+r;return Array.isArray(t[i])?t[i].map((function(t){return o+encodeURIComponent(e(t))})).join(n):o+encodeURIComponent(e(t[i]))})).join(n):i?encodeURIComponent(e(i))+r+encodeURIComponent(e(t)):""}},7673:function(t,e,n){"use strict";e.decode=e.parse=n(2587),e.encode=e.stringify=n(2361)},5666:function(t){var e=function(t){"use strict";var e,n=Object.prototype,r=n.hasOwnProperty,i="function"===typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",s=i.asyncIterator||"@@asyncIterator",a=i.toStringTag||"@@toStringTag";function u(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(N){u=function(t,e,n){return t[e]=n}}function l(t,e,n,r){var i=e&&e.prototype instanceof m?e:m,o=Object.create(i.prototype),s=new I(r||[]);return o._invoke=R(t,n,s),o}function c(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(N){return{type:"throw",arg:N}}}t.wrap=l;var h="suspendedStart",f="suspendedYield",d="executing",p="completed",v={};function m(){}function g(){}function _(){}var y={};u(y,o,(function(){return this}));var b=Object.getPrototypeOf,E=b&&b(b(P([])));E&&E!==n&&r.call(E,o)&&(y=E);var x=_.prototype=m.prototype=Object.create(y);function T(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function S(t,e){function n(i,o,s,a){var u=c(t[i],t,o);if("throw"!==u.type){var l=u.arg,h=l.value;return h&&"object"===typeof h&&r.call(h,"__await")?e.resolve(h.__await).then((function(t){n("next",t,s,a)}),(function(t){n("throw",t,s,a)})):e.resolve(h).then((function(t){l.value=t,s(l)}),(function(t){return n("throw",t,s,a)}))}a(u.arg)}var i;function o(t,r){function o(){return new e((function(e,i){n(t,r,e,i)}))}return i=i?i.then(o,o):o()}this._invoke=o}function R(t,e,n){var r=h;return function(i,o){if(r===d)throw new Error("Generator is already running");if(r===p){if("throw"===i)throw o;return C()}n.method=i,n.arg=o;while(1){var s=n.delegate;if(s){var a=A(s,n);if(a){if(a===v)continue;return a}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===h)throw r=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=d;var u=c(t,e,n);if("normal"===u.type){if(r=n.done?p:f,u.arg===v)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r=p,n.method="throw",n.arg=u.arg)}}}function A(t,n){var r=t.iterator[n.method];if(r===e){if(n.delegate=null,"throw"===n.method){if(t.iterator["return"]&&(n.method="return",n.arg=e,A(t,n),"throw"===n.method))return v;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var i=c(r,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,v;var o=i.arg;return o?o.done?(n[t.resultName]=o.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,v):o:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,v)}function O(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function w(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function I(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(O,this),this.reset(!0)}function P(t){if(t){var n=t[o];if(n)return n.call(t);if("function"===typeof t.next)return t;if(!isNaN(t.length)){var i=-1,s=function n(){while(++i<t.length)if(r.call(t,i))return n.value=t[i],n.done=!1,n;return n.value=e,n.done=!0,n};return s.next=s}}return{next:C}}function C(){return{value:e,done:!0}}return g.prototype=_,u(x,"constructor",_),u(_,"constructor",g),g.displayName=u(_,a,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"===typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,_):(t.__proto__=_,u(t,a,"GeneratorFunction")),t.prototype=Object.create(x),t},t.awrap=function(t){return{__await:t}},T(S.prototype),u(S.prototype,s,(function(){return this})),t.AsyncIterator=S,t.async=function(e,n,r,i,o){void 0===o&&(o=Promise);var s=new S(l(e,n,r,i),o);return t.isGeneratorFunction(n)?s:s.next().then((function(t){return t.done?t.value:s.next()}))},T(x),u(x,a,"Generator"),u(x,o,(function(){return this})),u(x,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=[];for(var n in t)e.push(n);return e.reverse(),function n(){while(e.length){var r=e.pop();if(r in t)return n.value=r,n.done=!1,n}return n.done=!0,n}},t.values=P,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(w),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0],e=t.completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function i(r,i){return a.type="throw",a.arg=t,n.next=r,i&&(n.method="next",n.arg=e),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],a=s.completion;if("root"===s.tryLoc)return i("end");if(s.tryLoc<=this.prev){var u=r.call(s,"catchLoc"),l=r.call(s,"finallyLoc");if(u&&l){if(this.prev<s.catchLoc)return i(s.catchLoc,!0);if(this.prev<s.finallyLoc)return i(s.finallyLoc)}else if(u){if(this.prev<s.catchLoc)return i(s.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return i(s.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=t,s.arg=e,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(s)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),v},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),w(n),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;w(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:P(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),v}},t}(t.exports);try{regeneratorRuntime=e}catch(n){"object"===typeof globalThis?globalThis.regeneratorRuntime=e:Function("r","regeneratorRuntime = r")(e)}},1474:function(t,e,n){"use strict"; -/**! - * Sortable 1.14.0 - * @author RubaXa <trash@rubaxa.org> - * @author owenm <owen23355@gmail.com> - * @license MIT - */ -function r(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function i(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?r(Object(n),!0).forEach((function(e){s(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function o(t){return o="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o(t)}function s(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function a(){return a=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},a.apply(this,arguments)}function u(t,e){if(null==t)return{};var n,r,i={},o=Object.keys(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||(i[n]=t[n]);return i}function l(t,e){if(null==t)return{};var n,r,i=u(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function c(t){return h(t)||f(t)||d(t)||v()}function h(t){if(Array.isArray(t))return p(t)}function f(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function d(t,e){if(t){if("string"===typeof t)return p(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(t,e):void 0}}function p(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function v(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}n.r(e),n.d(e,{MultiDrag:function(){return He},Sortable:function(){return ne},Swap:function(){return Ce}});var m="1.14.0";function g(t){if("undefined"!==typeof window&&window.navigator)return!!navigator.userAgent.match(t)}var _=g(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),y=g(/Edge/i),b=g(/firefox/i),E=g(/safari/i)&&!g(/chrome/i)&&!g(/android/i),x=g(/iP(ad|od|hone)/i),T=g(/chrome/i)&&g(/android/i),S={capture:!1,passive:!1};function R(t,e,n){t.addEventListener(e,n,!_&&S)}function A(t,e,n){t.removeEventListener(e,n,!_&&S)}function O(t,e){if(e){if(">"===e[0]&&(e=e.substring(1)),t)try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch(n){return!1}return!1}}function w(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function I(t,e,n,r){if(t){n=n||document;do{if(null!=e&&(">"===e[0]?t.parentNode===n&&O(t,e):O(t,e))||r&&t===n)return t;if(t===n)break}while(t=w(t))}return null}var P,C=/\s+/g;function N(t,e,n){if(t&&e)if(t.classList)t.classList[n?"add":"remove"](e);else{var r=(" "+t.className+" ").replace(C," ").replace(" "+e+" "," ");t.className=(r+(n?" "+e:"")).replace(C," ")}}function M(t,e,n){var r=t&&t.style;if(r){if(void 0===n)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(n=t.currentStyle),void 0===e?n:n[e];e in r||-1!==e.indexOf("webkit")||(e="-webkit-"+e),r[e]=n+("string"===typeof n?"":"px")}}function D(t,e){var n="";if("string"===typeof t)n=t;else do{var r=M(t,"transform");r&&"none"!==r&&(n=r+" "+n)}while(!e&&(t=t.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function L(t,e,n){if(t){var r=t.getElementsByTagName(e),i=0,o=r.length;if(n)for(;i<o;i++)n(r[i],i);return r}return[]}function F(){var t=document.scrollingElement;return t||document.documentElement}function B(t,e,n,r,i){if(t.getBoundingClientRect||t===window){var o,s,a,u,l,c,h;if(t!==window&&t.parentNode&&t!==F()?(o=t.getBoundingClientRect(),s=o.top,a=o.left,u=o.bottom,l=o.right,c=o.height,h=o.width):(s=0,a=0,u=window.innerHeight,l=window.innerWidth,c=window.innerHeight,h=window.innerWidth),(e||n)&&t!==window&&(i=i||t.parentNode,!_))do{if(i&&i.getBoundingClientRect&&("none"!==M(i,"transform")||n&&"static"!==M(i,"position"))){var f=i.getBoundingClientRect();s-=f.top+parseInt(M(i,"border-top-width")),a-=f.left+parseInt(M(i,"border-left-width")),u=s+o.height,l=a+o.width;break}}while(i=i.parentNode);if(r&&t!==window){var d=D(i||t),p=d&&d.a,v=d&&d.d;d&&(s/=v,a/=p,h/=p,c/=v,u=s+c,l=a+h)}return{top:s,left:a,bottom:u,right:l,width:h,height:c}}}function U(t,e,n){var r=V(t,!0),i=B(t)[e];while(r){var o=B(r)[n],s=void 0;if(s="top"===n||"left"===n?i>=o:i<=o,!s)return r;if(r===F())break;r=V(r,!1)}return!1}function G(t,e,n,r){var i=0,o=0,s=t.children;while(o<s.length){if("none"!==s[o].style.display&&s[o]!==ne.ghost&&(r||s[o]!==ne.dragged)&&I(s[o],n.draggable,t,!1)){if(i===e)return s[o];i++}o++}return null}function k(t,e){var n=t.lastElementChild;while(n&&(n===ne.ghost||"none"===M(n,"display")||e&&!O(n,e)))n=n.previousElementSibling;return n||null}function X(t,e){var n=0;if(!t||!t.parentNode)return-1;while(t=t.previousElementSibling)"TEMPLATE"===t.nodeName.toUpperCase()||t===ne.clone||e&&!O(t,e)||n++;return n}function j(t){var e=0,n=0,r=F();if(t)do{var i=D(t),o=i.a,s=i.d;e+=t.scrollLeft*o,n+=t.scrollTop*s}while(t!==r&&(t=t.parentNode));return[e,n]}function H(t,e){for(var n in t)if(t.hasOwnProperty(n))for(var r in e)if(e.hasOwnProperty(r)&&e[r]===t[n][r])return Number(n);return-1}function V(t,e){if(!t||!t.getBoundingClientRect)return F();var n=t,r=!1;do{if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var i=M(n);if(n.clientWidth<n.scrollWidth&&("auto"==i.overflowX||"scroll"==i.overflowX)||n.clientHeight<n.scrollHeight&&("auto"==i.overflowY||"scroll"==i.overflowY)){if(!n.getBoundingClientRect||n===document.body)return F();if(r||e)return n;r=!0}}}while(n=n.parentNode);return F()}function Y(t,e){if(t&&e)for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function W(t,e){return Math.round(t.top)===Math.round(e.top)&&Math.round(t.left)===Math.round(e.left)&&Math.round(t.height)===Math.round(e.height)&&Math.round(t.width)===Math.round(e.width)}function z(t,e){return function(){if(!P){var n=arguments,r=this;1===n.length?t.call(r,n[0]):t.apply(r,n),P=setTimeout((function(){P=void 0}),e)}}}function $(){clearTimeout(P),P=void 0}function q(t,e,n){t.scrollLeft+=e,t.scrollTop+=n}function K(t){var e=window.Polymer,n=window.jQuery||window.Zepto;return e&&e.dom?e.dom(t).cloneNode(!0):n?n(t).clone(!0)[0]:t.cloneNode(!0)}function Z(t,e){M(t,"position","absolute"),M(t,"top",e.top),M(t,"left",e.left),M(t,"width",e.width),M(t,"height",e.height)}function J(t){M(t,"position",""),M(t,"top",""),M(t,"left",""),M(t,"width",""),M(t,"height","")}var Q="Sortable"+(new Date).getTime();function tt(){var t,e=[];return{captureAnimationState:function(){if(e=[],this.options.animation){var t=[].slice.call(this.el.children);t.forEach((function(t){if("none"!==M(t,"display")&&t!==ne.ghost){e.push({target:t,rect:B(t)});var n=i({},e[e.length-1].rect);if(t.thisAnimationDuration){var r=D(t,!0);r&&(n.top-=r.f,n.left-=r.e)}t.fromRect=n}}))}},addAnimationState:function(t){e.push(t)},removeAnimationState:function(t){e.splice(H(e,{target:t}),1)},animateAll:function(n){var r=this;if(!this.options.animation)return clearTimeout(t),void("function"===typeof n&&n());var i=!1,o=0;e.forEach((function(t){var e=0,n=t.target,s=n.fromRect,a=B(n),u=n.prevFromRect,l=n.prevToRect,c=t.rect,h=D(n,!0);h&&(a.top-=h.f,a.left-=h.e),n.toRect=a,n.thisAnimationDuration&&W(u,a)&&!W(s,a)&&(c.top-a.top)/(c.left-a.left)===(s.top-a.top)/(s.left-a.left)&&(e=nt(c,u,l,r.options)),W(a,s)||(n.prevFromRect=s,n.prevToRect=a,e||(e=r.options.animation),r.animate(n,c,a,e)),e&&(i=!0,o=Math.max(o,e),clearTimeout(n.animationResetTimer),n.animationResetTimer=setTimeout((function(){n.animationTime=0,n.prevFromRect=null,n.fromRect=null,n.prevToRect=null,n.thisAnimationDuration=null}),e),n.thisAnimationDuration=e)})),clearTimeout(t),i?t=setTimeout((function(){"function"===typeof n&&n()}),o):"function"===typeof n&&n(),e=[]},animate:function(t,e,n,r){if(r){M(t,"transition",""),M(t,"transform","");var i=D(this.el),o=i&&i.a,s=i&&i.d,a=(e.left-n.left)/(o||1),u=(e.top-n.top)/(s||1);t.animatingX=!!a,t.animatingY=!!u,M(t,"transform","translate3d("+a+"px,"+u+"px,0)"),this.forRepaintDummy=et(t),M(t,"transition","transform "+r+"ms"+(this.options.easing?" "+this.options.easing:"")),M(t,"transform","translate3d(0,0,0)"),"number"===typeof t.animated&&clearTimeout(t.animated),t.animated=setTimeout((function(){M(t,"transition",""),M(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1}),r)}}}}function et(t){return t.offsetWidth}function nt(t,e,n,r){return Math.sqrt(Math.pow(e.top-t.top,2)+Math.pow(e.left-t.left,2))/Math.sqrt(Math.pow(e.top-n.top,2)+Math.pow(e.left-n.left,2))*r.animation}var rt=[],it={initializeByDefault:!0},ot={mount:function(t){for(var e in it)it.hasOwnProperty(e)&&!(e in t)&&(t[e]=it[e]);rt.forEach((function(e){if(e.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")})),rt.push(t)},pluginEvent:function(t,e,n){var r=this;this.eventCanceled=!1,n.cancel=function(){r.eventCanceled=!0};var o=t+"Global";rt.forEach((function(r){e[r.pluginName]&&(e[r.pluginName][o]&&e[r.pluginName][o](i({sortable:e},n)),e.options[r.pluginName]&&e[r.pluginName][t]&&e[r.pluginName][t](i({sortable:e},n)))}))},initializePlugins:function(t,e,n,r){for(var i in rt.forEach((function(r){var i=r.pluginName;if(t.options[i]||r.initializeByDefault){var o=new r(t,e,t.options);o.sortable=t,o.options=t.options,t[i]=o,a(n,o.defaults)}})),t.options)if(t.options.hasOwnProperty(i)){var o=this.modifyOption(t,i,t.options[i]);"undefined"!==typeof o&&(t.options[i]=o)}},getEventProperties:function(t,e){var n={};return rt.forEach((function(r){"function"===typeof r.eventProperties&&a(n,r.eventProperties.call(e[r.pluginName],t))})),n},modifyOption:function(t,e,n){var r;return rt.forEach((function(i){t[i.pluginName]&&i.optionListeners&&"function"===typeof i.optionListeners[e]&&(r=i.optionListeners[e].call(t[i.pluginName],n))})),r}};function st(t){var e=t.sortable,n=t.rootEl,r=t.name,o=t.targetEl,s=t.cloneEl,a=t.toEl,u=t.fromEl,l=t.oldIndex,c=t.newIndex,h=t.oldDraggableIndex,f=t.newDraggableIndex,d=t.originalEvent,p=t.putSortable,v=t.extraEventProperties;if(e=e||n&&n[Q],e){var m,g=e.options,b="on"+r.charAt(0).toUpperCase()+r.substr(1);!window.CustomEvent||_||y?(m=document.createEvent("Event"),m.initEvent(r,!0,!0)):m=new CustomEvent(r,{bubbles:!0,cancelable:!0}),m.to=a||n,m.from=u||n,m.item=o||n,m.clone=s,m.oldIndex=l,m.newIndex=c,m.oldDraggableIndex=h,m.newDraggableIndex=f,m.originalEvent=d,m.pullMode=p?p.lastPutMode:void 0;var E=i(i({},v),ot.getEventProperties(r,e));for(var x in E)m[x]=E[x];n&&n.dispatchEvent(m),g[b]&&g[b].call(e,m)}}var at=["evt"],ut=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.evt,o=l(n,at);ot.pluginEvent.bind(ne)(t,e,i({dragEl:ct,parentEl:ht,ghostEl:ft,rootEl:dt,nextEl:pt,lastDownEl:vt,cloneEl:mt,cloneHidden:gt,dragStarted:Pt,putSortable:Tt,activeSortable:ne.active,originalEvent:r,oldIndex:_t,oldDraggableIndex:bt,newIndex:yt,newDraggableIndex:Et,hideGhostForTarget:Jt,unhideGhostForTarget:Qt,cloneNowHidden:function(){gt=!0},cloneNowShown:function(){gt=!1},dispatchSortableEvent:function(t){lt({sortable:e,name:t,originalEvent:r})}},o))};function lt(t){st(i({putSortable:Tt,cloneEl:mt,targetEl:ct,rootEl:dt,oldIndex:_t,oldDraggableIndex:bt,newIndex:yt,newDraggableIndex:Et},t))}var ct,ht,ft,dt,pt,vt,mt,gt,_t,yt,bt,Et,xt,Tt,St,Rt,At,Ot,wt,It,Pt,Ct,Nt,Mt,Dt,Lt=!1,Ft=!1,Bt=[],Ut=!1,Gt=!1,kt=[],Xt=!1,jt=[],Ht="undefined"!==typeof document,Vt=x,Yt=y||_?"cssFloat":"float",Wt=Ht&&!T&&!x&&"draggable"in document.createElement("div"),zt=function(){if(Ht){if(_)return!1;var t=document.createElement("x");return t.style.cssText="pointer-events:auto","auto"===t.style.pointerEvents}}(),$t=function(t,e){var n=M(t),r=parseInt(n.width)-parseInt(n.paddingLeft)-parseInt(n.paddingRight)-parseInt(n.borderLeftWidth)-parseInt(n.borderRightWidth),i=G(t,0,e),o=G(t,1,e),s=i&&M(i),a=o&&M(o),u=s&&parseInt(s.marginLeft)+parseInt(s.marginRight)+B(i).width,l=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+B(o).width;if("flex"===n.display)return"column"===n.flexDirection||"column-reverse"===n.flexDirection?"vertical":"horizontal";if("grid"===n.display)return n.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(i&&s["float"]&&"none"!==s["float"]){var c="left"===s["float"]?"left":"right";return!o||"both"!==a.clear&&a.clear!==c?"horizontal":"vertical"}return i&&("block"===s.display||"flex"===s.display||"table"===s.display||"grid"===s.display||u>=r&&"none"===n[Yt]||o&&"none"===n[Yt]&&u+l>r)?"vertical":"horizontal"},qt=function(t,e,n){var r=n?t.left:t.top,i=n?t.right:t.bottom,o=n?t.width:t.height,s=n?e.left:e.top,a=n?e.right:e.bottom,u=n?e.width:e.height;return r===s||i===a||r+o/2===s+u/2},Kt=function(t,e){var n;return Bt.some((function(r){var i=r[Q].options.emptyInsertThreshold;if(i&&!k(r)){var o=B(r),s=t>=o.left-i&&t<=o.right+i,a=e>=o.top-i&&e<=o.bottom+i;return s&&a?n=r:void 0}})),n},Zt=function(t){function e(t,n){return function(r,i,o,s){var a=r.options.group.name&&i.options.group.name&&r.options.group.name===i.options.group.name;if(null==t&&(n||a))return!0;if(null==t||!1===t)return!1;if(n&&"clone"===t)return t;if("function"===typeof t)return e(t(r,i,o,s),n)(r,i,o,s);var u=(n?r:i).options.group.name;return!0===t||"string"===typeof t&&t===u||t.join&&t.indexOf(u)>-1}}var n={},r=t.group;r&&"object"==o(r)||(r={name:r}),n.name=r.name,n.checkPull=e(r.pull,!0),n.checkPut=e(r.put),n.revertClone=r.revertClone,t.group=n},Jt=function(){!zt&&ft&&M(ft,"display","none")},Qt=function(){!zt&&ft&&M(ft,"display","")};Ht&&document.addEventListener("click",(function(t){if(Ft)return t.preventDefault(),t.stopPropagation&&t.stopPropagation(),t.stopImmediatePropagation&&t.stopImmediatePropagation(),Ft=!1,!1}),!0);var te=function(t){if(ct){t=t.touches?t.touches[0]:t;var e=Kt(t.clientX,t.clientY);if(e){var n={};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);n.target=n.rootEl=e,n.preventDefault=void 0,n.stopPropagation=void 0,e[Q]._onDragOver(n)}}},ee=function(t){ct&&ct.parentNode[Q]._isOutsideThisEl(t.target)};function ne(t,e){if(!t||!t.nodeType||1!==t.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=e=a({},e),t[Q]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return $t(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(t,e){t.setData("Text",e.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==ne.supportPointer&&"PointerEvent"in window&&!E,emptyInsertThreshold:5};for(var r in ot.initializePlugins(this,t,n),n)!(r in e)&&(e[r]=n[r]);for(var i in Zt(e),this)"_"===i.charAt(0)&&"function"===typeof this[i]&&(this[i]=this[i].bind(this));this.nativeDraggable=!e.forceFallback&&Wt,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?R(t,"pointerdown",this._onTapStart):(R(t,"mousedown",this._onTapStart),R(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(R(t,"dragover",this),R(t,"dragenter",this)),Bt.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),a(this,tt())}function re(t){t.dataTransfer&&(t.dataTransfer.dropEffect="move"),t.cancelable&&t.preventDefault()}function ie(t,e,n,r,i,o,s,a){var u,l,c=t[Q],h=c.options.onMove;return!window.CustomEvent||_||y?(u=document.createEvent("Event"),u.initEvent("move",!0,!0)):u=new CustomEvent("move",{bubbles:!0,cancelable:!0}),u.to=e,u.from=t,u.dragged=n,u.draggedRect=r,u.related=i||e,u.relatedRect=o||B(e),u.willInsertAfter=a,u.originalEvent=s,t.dispatchEvent(u),h&&(l=h.call(c,u,s)),l}function oe(t){t.draggable=!1}function se(){Xt=!1}function ae(t,e,n){var r=B(G(n.el,0,n.options,!0)),i=10;return e?t.clientX<r.left-i||t.clientY<r.top&&t.clientX<r.right:t.clientY<r.top-i||t.clientY<r.bottom&&t.clientX<r.left}function ue(t,e,n){var r=B(k(n.el,n.options.draggable)),i=10;return e?t.clientX>r.right+i||t.clientX<=r.right&&t.clientY>r.bottom&&t.clientX>=r.left:t.clientX>r.right&&t.clientY>r.top||t.clientX<=r.right&&t.clientY>r.bottom+i}function le(t,e,n,r,i,o,s,a){var u=r?t.clientY:t.clientX,l=r?n.height:n.width,c=r?n.top:n.left,h=r?n.bottom:n.right,f=!1;if(!s)if(a&&Mt<l*i){if(!Ut&&(1===Nt?u>c+l*o/2:u<h-l*o/2)&&(Ut=!0),Ut)f=!0;else if(1===Nt?u<c+Mt:u>h-Mt)return-Nt}else if(u>c+l*(1-i)/2&&u<h-l*(1-i)/2)return ce(e);return f=f||s,f&&(u<c+l*o/2||u>h-l*o/2)?u>c+l/2?1:-1:0}function ce(t){return X(ct)<X(t)?1:-1}function he(t){var e=t.tagName+t.className+t.src+t.href+t.textContent,n=e.length,r=0;while(n--)r+=e.charCodeAt(n);return r.toString(36)}function fe(t){jt.length=0;var e=t.getElementsByTagName("input"),n=e.length;while(n--){var r=e[n];r.checked&&jt.push(r)}}function de(t){return setTimeout(t,0)}function pe(t){return clearTimeout(t)}ne.prototype={constructor:ne,_isOutsideThisEl:function(t){this.el.contains(t)||t===this.el||(Ct=null)},_getDirection:function(t,e){return"function"===typeof this.options.direction?this.options.direction.call(this,t,e,ct):this.options.direction},_onTapStart:function(t){if(t.cancelable){var e=this,n=this.el,r=this.options,i=r.preventOnFilter,o=t.type,s=t.touches&&t.touches[0]||t.pointerType&&"touch"===t.pointerType&&t,a=(s||t).target,u=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||a,l=r.filter;if(fe(n),!ct&&!(/mousedown|pointerdown/.test(o)&&0!==t.button||r.disabled)&&!u.isContentEditable&&(this.nativeDraggable||!E||!a||"SELECT"!==a.tagName.toUpperCase())&&(a=I(a,r.draggable,n,!1),(!a||!a.animated)&&vt!==a)){if(_t=X(a),bt=X(a,r.draggable),"function"===typeof l){if(l.call(this,t,a,this))return lt({sortable:e,rootEl:u,name:"filter",targetEl:a,toEl:n,fromEl:n}),ut("filter",e,{evt:t}),void(i&&t.cancelable&&t.preventDefault())}else if(l&&(l=l.split(",").some((function(r){if(r=I(u,r.trim(),n,!1),r)return lt({sortable:e,rootEl:r,name:"filter",targetEl:a,fromEl:n,toEl:n}),ut("filter",e,{evt:t}),!0})),l))return void(i&&t.cancelable&&t.preventDefault());r.handle&&!I(u,r.handle,n,!1)||this._prepareDragStart(t,s,a)}}},_prepareDragStart:function(t,e,n){var r,i=this,o=i.el,s=i.options,a=o.ownerDocument;if(n&&!ct&&n.parentNode===o){var u=B(n);if(dt=o,ct=n,ht=ct.parentNode,pt=ct.nextSibling,vt=n,xt=s.group,ne.dragged=ct,St={target:ct,clientX:(e||t).clientX,clientY:(e||t).clientY},wt=St.clientX-u.left,It=St.clientY-u.top,this._lastX=(e||t).clientX,this._lastY=(e||t).clientY,ct.style["will-change"]="all",r=function(){ut("delayEnded",i,{evt:t}),ne.eventCanceled?i._onDrop():(i._disableDelayedDragEvents(),!b&&i.nativeDraggable&&(ct.draggable=!0),i._triggerDragStart(t,e),lt({sortable:i,name:"choose",originalEvent:t}),N(ct,s.chosenClass,!0))},s.ignore.split(",").forEach((function(t){L(ct,t.trim(),oe)})),R(a,"dragover",te),R(a,"mousemove",te),R(a,"touchmove",te),R(a,"mouseup",i._onDrop),R(a,"touchend",i._onDrop),R(a,"touchcancel",i._onDrop),b&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ct.draggable=!0),ut("delayStart",this,{evt:t}),!s.delay||s.delayOnTouchOnly&&!e||this.nativeDraggable&&(y||_))r();else{if(ne.eventCanceled)return void this._onDrop();R(a,"mouseup",i._disableDelayedDrag),R(a,"touchend",i._disableDelayedDrag),R(a,"touchcancel",i._disableDelayedDrag),R(a,"mousemove",i._delayedDragTouchMoveHandler),R(a,"touchmove",i._delayedDragTouchMoveHandler),s.supportPointer&&R(a,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(r,s.delay)}}},_delayedDragTouchMoveHandler:function(t){var e=t.touches?t.touches[0]:t;Math.max(Math.abs(e.clientX-this._lastX),Math.abs(e.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ct&&oe(ct),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;A(t,"mouseup",this._disableDelayedDrag),A(t,"touchend",this._disableDelayedDrag),A(t,"touchcancel",this._disableDelayedDrag),A(t,"mousemove",this._delayedDragTouchMoveHandler),A(t,"touchmove",this._delayedDragTouchMoveHandler),A(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,e){e=e||"touch"==t.pointerType&&t,!this.nativeDraggable||e?this.options.supportPointer?R(document,"pointermove",this._onTouchMove):R(document,e?"touchmove":"mousemove",this._onTouchMove):(R(ct,"dragend",this),R(dt,"dragstart",this._onDragStart));try{document.selection?de((function(){document.selection.empty()})):window.getSelection().removeAllRanges()}catch(n){}},_dragStarted:function(t,e){if(Lt=!1,dt&&ct){ut("dragStarted",this,{evt:e}),this.nativeDraggable&&R(document,"dragover",ee);var n=this.options;!t&&N(ct,n.dragClass,!1),N(ct,n.ghostClass,!0),ne.active=this,t&&this._appendGhost(),lt({sortable:this,name:"start",originalEvent:e})}else this._nulling()},_emulateDragOver:function(){if(Rt){this._lastX=Rt.clientX,this._lastY=Rt.clientY,Jt();var t=document.elementFromPoint(Rt.clientX,Rt.clientY),e=t;while(t&&t.shadowRoot){if(t=t.shadowRoot.elementFromPoint(Rt.clientX,Rt.clientY),t===e)break;e=t}if(ct.parentNode[Q]._isOutsideThisEl(t),e)do{if(e[Q]){var n=void 0;if(n=e[Q]._onDragOver({clientX:Rt.clientX,clientY:Rt.clientY,target:t,rootEl:e}),n&&!this.options.dragoverBubble)break}t=e}while(e=e.parentNode);Qt()}},_onTouchMove:function(t){if(St){var e=this.options,n=e.fallbackTolerance,r=e.fallbackOffset,i=t.touches?t.touches[0]:t,o=ft&&D(ft,!0),s=ft&&o&&o.a,a=ft&&o&&o.d,u=Vt&&Dt&&j(Dt),l=(i.clientX-St.clientX+r.x)/(s||1)+(u?u[0]-kt[0]:0)/(s||1),c=(i.clientY-St.clientY+r.y)/(a||1)+(u?u[1]-kt[1]:0)/(a||1);if(!ne.active&&!Lt){if(n&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))<n)return;this._onDragStart(t,!0)}if(ft){o?(o.e+=l-(At||0),o.f+=c-(Ot||0)):o={a:1,b:0,c:0,d:1,e:l,f:c};var h="matrix(".concat(o.a,",").concat(o.b,",").concat(o.c,",").concat(o.d,",").concat(o.e,",").concat(o.f,")");M(ft,"webkitTransform",h),M(ft,"mozTransform",h),M(ft,"msTransform",h),M(ft,"transform",h),At=l,Ot=c,Rt=i}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!ft){var t=this.options.fallbackOnBody?document.body:dt,e=B(ct,!0,Vt,!0,t),n=this.options;if(Vt){Dt=t;while("static"===M(Dt,"position")&&"none"===M(Dt,"transform")&&Dt!==document)Dt=Dt.parentNode;Dt!==document.body&&Dt!==document.documentElement?(Dt===document&&(Dt=F()),e.top+=Dt.scrollTop,e.left+=Dt.scrollLeft):Dt=F(),kt=j(Dt)}ft=ct.cloneNode(!0),N(ft,n.ghostClass,!1),N(ft,n.fallbackClass,!0),N(ft,n.dragClass,!0),M(ft,"transition",""),M(ft,"transform",""),M(ft,"box-sizing","border-box"),M(ft,"margin",0),M(ft,"top",e.top),M(ft,"left",e.left),M(ft,"width",e.width),M(ft,"height",e.height),M(ft,"opacity","0.8"),M(ft,"position",Vt?"absolute":"fixed"),M(ft,"zIndex","100000"),M(ft,"pointerEvents","none"),ne.ghost=ft,t.appendChild(ft),M(ft,"transform-origin",wt/parseInt(ft.style.width)*100+"% "+It/parseInt(ft.style.height)*100+"%")}},_onDragStart:function(t,e){var n=this,r=t.dataTransfer,i=n.options;ut("dragStart",this,{evt:t}),ne.eventCanceled?this._onDrop():(ut("setupClone",this),ne.eventCanceled||(mt=K(ct),mt.draggable=!1,mt.style["will-change"]="",this._hideClone(),N(mt,this.options.chosenClass,!1),ne.clone=mt),n.cloneId=de((function(){ut("clone",n),ne.eventCanceled||(n.options.removeCloneOnHide||dt.insertBefore(mt,ct),n._hideClone(),lt({sortable:n,name:"clone"}))})),!e&&N(ct,i.dragClass,!0),e?(Ft=!0,n._loopId=setInterval(n._emulateDragOver,50)):(A(document,"mouseup",n._onDrop),A(document,"touchend",n._onDrop),A(document,"touchcancel",n._onDrop),r&&(r.effectAllowed="move",i.setData&&i.setData.call(n,r,ct)),R(document,"drop",n),M(ct,"transform","translateZ(0)")),Lt=!0,n._dragStartId=de(n._dragStarted.bind(n,e,t)),R(document,"selectstart",n),Pt=!0,E&&M(document.body,"user-select","none"))},_onDragOver:function(t){var e,n,r,o,s=this.el,a=t.target,u=this.options,l=u.group,c=ne.active,h=xt===l,f=u.sort,d=Tt||c,p=this,v=!1;if(!Xt){if(void 0!==t.preventDefault&&t.cancelable&&t.preventDefault(),a=I(a,u.draggable,s,!0),C("dragOver"),ne.eventCanceled)return v;if(ct.contains(t.target)||a.animated&&a.animatingX&&a.animatingY||p._ignoreWhileAnimating===a)return L(!1);if(Ft=!1,c&&!u.disabled&&(h?f||(r=ht!==dt):Tt===this||(this.lastPutMode=xt.checkPull(this,c,ct,t))&&l.checkPut(this,c,ct,t))){if(o="vertical"===this._getDirection(t,a),e=B(ct),C("dragOverValid"),ne.eventCanceled)return v;if(r)return ht=dt,D(),this._hideClone(),C("revert"),ne.eventCanceled||(pt?dt.insertBefore(ct,pt):dt.appendChild(ct)),L(!0);var m=k(s,u.draggable);if(!m||ue(t,o,this)&&!m.animated){if(m===ct)return L(!1);if(m&&s===t.target&&(a=m),a&&(n=B(a)),!1!==ie(dt,s,ct,e,a,n,t,!!a))return D(),s.appendChild(ct),ht=s,F(),L(!0)}else if(m&&ae(t,o,this)){var g=G(s,0,u,!0);if(g===ct)return L(!1);if(a=g,n=B(a),!1!==ie(dt,s,ct,e,a,n,t,!1))return D(),s.insertBefore(ct,g),ht=s,F(),L(!0)}else if(a.parentNode===s){n=B(a);var _,y,b=0,E=ct.parentNode!==s,x=!qt(ct.animated&&ct.toRect||e,a.animated&&a.toRect||n,o),T=o?"top":"left",S=U(a,"top","top")||U(ct,"top","top"),R=S?S.scrollTop:void 0;if(Ct!==a&&(_=n[T],Ut=!1,Gt=!x&&u.invertSwap||E),b=le(t,a,n,o,x?1:u.swapThreshold,null==u.invertedSwapThreshold?u.swapThreshold:u.invertedSwapThreshold,Gt,Ct===a),0!==b){var A=X(ct);do{A-=b,y=ht.children[A]}while(y&&("none"===M(y,"display")||y===ft))}if(0===b||y===a)return L(!1);Ct=a,Nt=b;var O=a.nextElementSibling,w=!1;w=1===b;var P=ie(dt,s,ct,e,a,n,t,w);if(!1!==P)return 1!==P&&-1!==P||(w=1===P),Xt=!0,setTimeout(se,30),D(),w&&!O?s.appendChild(ct):a.parentNode.insertBefore(ct,w?O:a),S&&q(S,0,R-S.scrollTop),ht=ct.parentNode,void 0===_||Gt||(Mt=Math.abs(_-B(a)[T])),F(),L(!0)}if(s.contains(ct))return L(!1)}return!1}function C(u,l){ut(u,p,i({evt:t,isOwner:h,axis:o?"vertical":"horizontal",revert:r,dragRect:e,targetRect:n,canSort:f,fromSortable:d,target:a,completed:L,onMove:function(n,r){return ie(dt,s,ct,e,n,B(n),t,r)},changed:F},l))}function D(){C("dragOverAnimationCapture"),p.captureAnimationState(),p!==d&&d.captureAnimationState()}function L(e){return C("dragOverCompleted",{insertion:e}),e&&(h?c._hideClone():c._showClone(p),p!==d&&(N(ct,Tt?Tt.options.ghostClass:c.options.ghostClass,!1),N(ct,u.ghostClass,!0)),Tt!==p&&p!==ne.active?Tt=p:p===ne.active&&Tt&&(Tt=null),d===p&&(p._ignoreWhileAnimating=a),p.animateAll((function(){C("dragOverAnimationComplete"),p._ignoreWhileAnimating=null})),p!==d&&(d.animateAll(),d._ignoreWhileAnimating=null)),(a===ct&&!ct.animated||a===s&&!a.animated)&&(Ct=null),u.dragoverBubble||t.rootEl||a===document||(ct.parentNode[Q]._isOutsideThisEl(t.target),!e&&te(t)),!u.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),v=!0}function F(){yt=X(ct),Et=X(ct,u.draggable),lt({sortable:p,name:"change",toEl:s,newIndex:yt,newDraggableIndex:Et,originalEvent:t})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){A(document,"mousemove",this._onTouchMove),A(document,"touchmove",this._onTouchMove),A(document,"pointermove",this._onTouchMove),A(document,"dragover",te),A(document,"mousemove",te),A(document,"touchmove",te)},_offUpEvents:function(){var t=this.el.ownerDocument;A(t,"mouseup",this._onDrop),A(t,"touchend",this._onDrop),A(t,"pointerup",this._onDrop),A(t,"touchcancel",this._onDrop),A(document,"selectstart",this)},_onDrop:function(t){var e=this.el,n=this.options;yt=X(ct),Et=X(ct,n.draggable),ut("drop",this,{evt:t}),ht=ct&&ct.parentNode,yt=X(ct),Et=X(ct,n.draggable),ne.eventCanceled||(Lt=!1,Gt=!1,Ut=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),pe(this.cloneId),pe(this._dragStartId),this.nativeDraggable&&(A(document,"drop",this),A(e,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),E&&M(document.body,"user-select",""),M(ct,"transform",""),t&&(Pt&&(t.cancelable&&t.preventDefault(),!n.dropBubble&&t.stopPropagation()),ft&&ft.parentNode&&ft.parentNode.removeChild(ft),(dt===ht||Tt&&"clone"!==Tt.lastPutMode)&&mt&&mt.parentNode&&mt.parentNode.removeChild(mt),ct&&(this.nativeDraggable&&A(ct,"dragend",this),oe(ct),ct.style["will-change"]="",Pt&&!Lt&&N(ct,Tt?Tt.options.ghostClass:this.options.ghostClass,!1),N(ct,this.options.chosenClass,!1),lt({sortable:this,name:"unchoose",toEl:ht,newIndex:null,newDraggableIndex:null,originalEvent:t}),dt!==ht?(yt>=0&&(lt({rootEl:ht,name:"add",toEl:ht,fromEl:dt,originalEvent:t}),lt({sortable:this,name:"remove",toEl:ht,originalEvent:t}),lt({rootEl:ht,name:"sort",toEl:ht,fromEl:dt,originalEvent:t}),lt({sortable:this,name:"sort",toEl:ht,originalEvent:t})),Tt&&Tt.save()):yt!==_t&&yt>=0&&(lt({sortable:this,name:"update",toEl:ht,originalEvent:t}),lt({sortable:this,name:"sort",toEl:ht,originalEvent:t})),ne.active&&(null!=yt&&-1!==yt||(yt=_t,Et=bt),lt({sortable:this,name:"end",toEl:ht,originalEvent:t}),this.save())))),this._nulling()},_nulling:function(){ut("nulling",this),dt=ct=ht=ft=pt=mt=vt=gt=St=Rt=Pt=yt=Et=_t=bt=Ct=Nt=Tt=xt=ne.dragged=ne.ghost=ne.clone=ne.active=null,jt.forEach((function(t){t.checked=!0})),jt.length=At=Ot=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":ct&&(this._onDragOver(t),re(t));break;case"selectstart":t.preventDefault();break}},toArray:function(){for(var t,e=[],n=this.el.children,r=0,i=n.length,o=this.options;r<i;r++)t=n[r],I(t,o.draggable,this.el,!1)&&e.push(t.getAttribute(o.dataIdAttr)||he(t));return e},sort:function(t,e){var n={},r=this.el;this.toArray().forEach((function(t,e){var i=r.children[e];I(i,this.options.draggable,r,!1)&&(n[t]=i)}),this),e&&this.captureAnimationState(),t.forEach((function(t){n[t]&&(r.removeChild(n[t]),r.appendChild(n[t]))})),e&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,e){return I(t,e||this.options.draggable,this.el,!1)},option:function(t,e){var n=this.options;if(void 0===e)return n[t];var r=ot.modifyOption(this,t,e);n[t]="undefined"!==typeof r?r:e,"group"===t&&Zt(n)},destroy:function(){ut("destroy",this);var t=this.el;t[Q]=null,A(t,"mousedown",this._onTapStart),A(t,"touchstart",this._onTapStart),A(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(A(t,"dragover",this),A(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),(function(t){t.removeAttribute("draggable")})),this._onDrop(),this._disableDelayedDragEvents(),Bt.splice(Bt.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!gt){if(ut("hideClone",this),ne.eventCanceled)return;M(mt,"display","none"),this.options.removeCloneOnHide&&mt.parentNode&&mt.parentNode.removeChild(mt),gt=!0}},_showClone:function(t){if("clone"===t.lastPutMode){if(gt){if(ut("showClone",this),ne.eventCanceled)return;ct.parentNode!=dt||this.options.group.revertClone?pt?dt.insertBefore(mt,pt):dt.appendChild(mt):dt.insertBefore(mt,ct),this.options.group.revertClone&&this.animate(ct,mt),M(mt,"display",""),gt=!1}}else this._hideClone()}},Ht&&R(document,"touchmove",(function(t){(ne.active||Lt)&&t.cancelable&&t.preventDefault()})),ne.utils={on:R,off:A,css:M,find:L,is:function(t,e){return!!I(t,e,t,!1)},extend:Y,throttle:z,closest:I,toggleClass:N,clone:K,index:X,nextTick:de,cancelNextTick:pe,detectDirection:$t,getChild:G},ne.get=function(t){return t[Q]},ne.mount=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];e[0].constructor===Array&&(e=e[0]),e.forEach((function(t){if(!t.prototype||!t.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(t));t.utils&&(ne.utils=i(i({},ne.utils),t.utils)),ot.mount(t)}))},ne.create=function(t,e){return new ne(t,e)},ne.version=m;var ve,me,ge,_e,ye,be,Ee=[],xe=!1;function Te(){function t(){for(var t in this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0},this)"_"===t.charAt(0)&&"function"===typeof this[t]&&(this[t]=this[t].bind(this))}return t.prototype={dragStarted:function(t){var e=t.originalEvent;this.sortable.nativeDraggable?R(document,"dragover",this._handleAutoScroll):this.options.supportPointer?R(document,"pointermove",this._handleFallbackAutoScroll):e.touches?R(document,"touchmove",this._handleFallbackAutoScroll):R(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var e=t.originalEvent;this.options.dragOverBubble||e.rootEl||this._handleAutoScroll(e)},drop:function(){this.sortable.nativeDraggable?A(document,"dragover",this._handleAutoScroll):(A(document,"pointermove",this._handleFallbackAutoScroll),A(document,"touchmove",this._handleFallbackAutoScroll),A(document,"mousemove",this._handleFallbackAutoScroll)),Re(),Se(),$()},nulling:function(){ye=me=ve=xe=be=ge=_e=null,Ee.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(t,e){var n=this,r=(t.touches?t.touches[0]:t).clientX,i=(t.touches?t.touches[0]:t).clientY,o=document.elementFromPoint(r,i);if(ye=t,e||this.options.forceAutoScrollFallback||y||_||E){Oe(t,this.options,o,e);var s=V(o,!0);!xe||be&&r===ge&&i===_e||(be&&Re(),be=setInterval((function(){var o=V(document.elementFromPoint(r,i),!0);o!==s&&(s=o,Se()),Oe(t,n.options,o,e)}),10),ge=r,_e=i)}else{if(!this.options.bubbleScroll||V(o,!0)===F())return void Se();Oe(t,this.options,V(o,!1),!1)}}},a(t,{pluginName:"scroll",initializeByDefault:!0})}function Se(){Ee.forEach((function(t){clearInterval(t.pid)})),Ee=[]}function Re(){clearInterval(be)}var Ae,Oe=z((function(t,e,n,r){if(e.scroll){var i,o=(t.touches?t.touches[0]:t).clientX,s=(t.touches?t.touches[0]:t).clientY,a=e.scrollSensitivity,u=e.scrollSpeed,l=F(),c=!1;me!==n&&(me=n,Se(),ve=e.scroll,i=e.scrollFn,!0===ve&&(ve=V(n,!0)));var h=0,f=ve;do{var d=f,p=B(d),v=p.top,m=p.bottom,g=p.left,_=p.right,y=p.width,b=p.height,E=void 0,x=void 0,T=d.scrollWidth,S=d.scrollHeight,R=M(d),A=d.scrollLeft,O=d.scrollTop;d===l?(E=y<T&&("auto"===R.overflowX||"scroll"===R.overflowX||"visible"===R.overflowX),x=b<S&&("auto"===R.overflowY||"scroll"===R.overflowY||"visible"===R.overflowY)):(E=y<T&&("auto"===R.overflowX||"scroll"===R.overflowX),x=b<S&&("auto"===R.overflowY||"scroll"===R.overflowY));var w=E&&(Math.abs(_-o)<=a&&A+y<T)-(Math.abs(g-o)<=a&&!!A),I=x&&(Math.abs(m-s)<=a&&O+b<S)-(Math.abs(v-s)<=a&&!!O);if(!Ee[h])for(var P=0;P<=h;P++)Ee[P]||(Ee[P]={});Ee[h].vx==w&&Ee[h].vy==I&&Ee[h].el===d||(Ee[h].el=d,Ee[h].vx=w,Ee[h].vy=I,clearInterval(Ee[h].pid),0==w&&0==I||(c=!0,Ee[h].pid=setInterval(function(){r&&0===this.layer&&ne.active._onTouchMove(ye);var e=Ee[this.layer].vy?Ee[this.layer].vy*u:0,n=Ee[this.layer].vx?Ee[this.layer].vx*u:0;"function"===typeof i&&"continue"!==i.call(ne.dragged.parentNode[Q],n,e,t,ye,Ee[this.layer].el)||q(Ee[this.layer].el,n,e)}.bind({layer:h}),24))),h++}while(e.bubbleScroll&&f!==l&&(f=V(f,!1)));xe=c}}),30),we=function(t){var e=t.originalEvent,n=t.putSortable,r=t.dragEl,i=t.activeSortable,o=t.dispatchSortableEvent,s=t.hideGhostForTarget,a=t.unhideGhostForTarget;if(e){var u=n||i;s();var l=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e,c=document.elementFromPoint(l.clientX,l.clientY);a(),u&&!u.el.contains(c)&&(o("spill"),this.onSpill({dragEl:r,putSortable:n}))}};function Ie(){}function Pe(){}function Ce(){function t(){this.defaults={swapClass:"sortable-swap-highlight"}}return t.prototype={dragStart:function(t){var e=t.dragEl;Ae=e},dragOverValid:function(t){var e=t.completed,n=t.target,r=t.onMove,i=t.activeSortable,o=t.changed,s=t.cancel;if(i.options.swap){var a=this.sortable.el,u=this.options;if(n&&n!==a){var l=Ae;!1!==r(n)?(N(n,u.swapClass,!0),Ae=n):Ae=null,l&&l!==Ae&&N(l,u.swapClass,!1)}o(),e(!0),s()}},drop:function(t){var e=t.activeSortable,n=t.putSortable,r=t.dragEl,i=n||this.sortable,o=this.options;Ae&&N(Ae,o.swapClass,!1),Ae&&(o.swap||n&&n.options.swap)&&r!==Ae&&(i.captureAnimationState(),i!==e&&e.captureAnimationState(),Ne(r,Ae),i.animateAll(),i!==e&&e.animateAll())},nulling:function(){Ae=null}},a(t,{pluginName:"swap",eventProperties:function(){return{swapItem:Ae}}})}function Ne(t,e){var n,r,i=t.parentNode,o=e.parentNode;i&&o&&!i.isEqualNode(e)&&!o.isEqualNode(t)&&(n=X(t),r=X(e),i.isEqualNode(o)&&n<r&&r++,i.insertBefore(e,i.children[n]),o.insertBefore(t,o.children[r]))}Ie.prototype={startIndex:null,dragStart:function(t){var e=t.oldDraggableIndex;this.startIndex=e},onSpill:function(t){var e=t.dragEl,n=t.putSortable;this.sortable.captureAnimationState(),n&&n.captureAnimationState();var r=G(this.sortable.el,this.startIndex,this.options);r?this.sortable.el.insertBefore(e,r):this.sortable.el.appendChild(e),this.sortable.animateAll(),n&&n.animateAll()},drop:we},a(Ie,{pluginName:"revertOnSpill"}),Pe.prototype={onSpill:function(t){var e=t.dragEl,n=t.putSortable,r=n||this.sortable;r.captureAnimationState(),e.parentNode&&e.parentNode.removeChild(e),r.animateAll()},drop:we},a(Pe,{pluginName:"removeOnSpill"});var Me,De,Le,Fe,Be,Ue=[],Ge=[],ke=!1,Xe=!1,je=!1;function He(){function t(t){for(var e in this)"_"===e.charAt(0)&&"function"===typeof this[e]&&(this[e]=this[e].bind(this));t.options.supportPointer?R(document,"pointerup",this._deselectMultiDrag):(R(document,"mouseup",this._deselectMultiDrag),R(document,"touchend",this._deselectMultiDrag)),R(document,"keydown",this._checkKeyDown),R(document,"keyup",this._checkKeyUp),this.defaults={selectedClass:"sortable-selected",multiDragKey:null,setData:function(e,n){var r="";Ue.length&&De===t?Ue.forEach((function(t,e){r+=(e?", ":"")+t.textContent})):r=n.textContent,e.setData("Text",r)}}}return t.prototype={multiDragKeyDown:!1,isMultiDrag:!1,delayStartGlobal:function(t){var e=t.dragEl;Le=e},delayEnded:function(){this.isMultiDrag=~Ue.indexOf(Le)},setupClone:function(t){var e=t.sortable,n=t.cancel;if(this.isMultiDrag){for(var r=0;r<Ue.length;r++)Ge.push(K(Ue[r])),Ge[r].sortableIndex=Ue[r].sortableIndex,Ge[r].draggable=!1,Ge[r].style["will-change"]="",N(Ge[r],this.options.selectedClass,!1),Ue[r]===Le&&N(Ge[r],this.options.chosenClass,!1);e._hideClone(),n()}},clone:function(t){var e=t.sortable,n=t.rootEl,r=t.dispatchSortableEvent,i=t.cancel;this.isMultiDrag&&(this.options.removeCloneOnHide||Ue.length&&De===e&&(Ye(!0,n),r("clone"),i()))},showClone:function(t){var e=t.cloneNowShown,n=t.rootEl,r=t.cancel;this.isMultiDrag&&(Ye(!1,n),Ge.forEach((function(t){M(t,"display","")})),e(),Be=!1,r())},hideClone:function(t){var e=this,n=(t.sortable,t.cloneNowHidden),r=t.cancel;this.isMultiDrag&&(Ge.forEach((function(t){M(t,"display","none"),e.options.removeCloneOnHide&&t.parentNode&&t.parentNode.removeChild(t)})),n(),Be=!0,r())},dragStartGlobal:function(t){t.sortable;!this.isMultiDrag&&De&&De.multiDrag._deselectMultiDrag(),Ue.forEach((function(t){t.sortableIndex=X(t)})),Ue=Ue.sort((function(t,e){return t.sortableIndex-e.sortableIndex})),je=!0},dragStarted:function(t){var e=this,n=t.sortable;if(this.isMultiDrag){if(this.options.sort&&(n.captureAnimationState(),this.options.animation)){Ue.forEach((function(t){t!==Le&&M(t,"position","absolute")}));var r=B(Le,!1,!0,!0);Ue.forEach((function(t){t!==Le&&Z(t,r)})),Xe=!0,ke=!0}n.animateAll((function(){Xe=!1,ke=!1,e.options.animation&&Ue.forEach((function(t){J(t)})),e.options.sort&&We()}))}},dragOver:function(t){var e=t.target,n=t.completed,r=t.cancel;Xe&&~Ue.indexOf(e)&&(n(!1),r())},revert:function(t){var e=t.fromSortable,n=t.rootEl,r=t.sortable,i=t.dragRect;Ue.length>1&&(Ue.forEach((function(t){r.addAnimationState({target:t,rect:Xe?B(t):i}),J(t),t.fromRect=i,e.removeAnimationState(t)})),Xe=!1,Ve(!this.options.removeCloneOnHide,n))},dragOverCompleted:function(t){var e=t.sortable,n=t.isOwner,r=t.insertion,i=t.activeSortable,o=t.parentEl,s=t.putSortable,a=this.options;if(r){if(n&&i._hideClone(),ke=!1,a.animation&&Ue.length>1&&(Xe||!n&&!i.options.sort&&!s)){var u=B(Le,!1,!0,!0);Ue.forEach((function(t){t!==Le&&(Z(t,u),o.appendChild(t))})),Xe=!0}if(!n)if(Xe||We(),Ue.length>1){var l=Be;i._showClone(e),i.options.animation&&!Be&&l&&Ge.forEach((function(t){i.addAnimationState({target:t,rect:Fe}),t.fromRect=Fe,t.thisAnimationDuration=null}))}else i._showClone(e)}},dragOverAnimationCapture:function(t){var e=t.dragRect,n=t.isOwner,r=t.activeSortable;if(Ue.forEach((function(t){t.thisAnimationDuration=null})),r.options.animation&&!n&&r.multiDrag.isMultiDrag){Fe=a({},e);var i=D(Le,!0);Fe.top-=i.f,Fe.left-=i.e}},dragOverAnimationComplete:function(){Xe&&(Xe=!1,We())},drop:function(t){var e=t.originalEvent,n=t.rootEl,r=t.parentEl,i=t.sortable,o=t.dispatchSortableEvent,s=t.oldIndex,a=t.putSortable,u=a||this.sortable;if(e){var l=this.options,c=r.children;if(!je)if(l.multiDragKey&&!this.multiDragKeyDown&&this._deselectMultiDrag(),N(Le,l.selectedClass,!~Ue.indexOf(Le)),~Ue.indexOf(Le))Ue.splice(Ue.indexOf(Le),1),Me=null,st({sortable:i,rootEl:n,name:"deselect",targetEl:Le,originalEvt:e});else{if(Ue.push(Le),st({sortable:i,rootEl:n,name:"select",targetEl:Le,originalEvt:e}),e.shiftKey&&Me&&i.el.contains(Me)){var h,f,d=X(Me),p=X(Le);if(~d&&~p&&d!==p)for(p>d?(f=d,h=p):(f=p,h=d+1);f<h;f++)~Ue.indexOf(c[f])||(N(c[f],l.selectedClass,!0),Ue.push(c[f]),st({sortable:i,rootEl:n,name:"select",targetEl:c[f],originalEvt:e}))}else Me=Le;De=u}if(je&&this.isMultiDrag){if(Xe=!1,(r[Q].options.sort||r!==n)&&Ue.length>1){var v=B(Le),m=X(Le,":not(."+this.options.selectedClass+")");if(!ke&&l.animation&&(Le.thisAnimationDuration=null),u.captureAnimationState(),!ke&&(l.animation&&(Le.fromRect=v,Ue.forEach((function(t){if(t.thisAnimationDuration=null,t!==Le){var e=Xe?B(t):v;t.fromRect=e,u.addAnimationState({target:t,rect:e})}}))),We(),Ue.forEach((function(t){c[m]?r.insertBefore(t,c[m]):r.appendChild(t),m++})),s===X(Le))){var g=!1;Ue.forEach((function(t){t.sortableIndex===X(t)||(g=!0)})),g&&o("update")}Ue.forEach((function(t){J(t)})),u.animateAll()}De=u}(n===r||a&&"clone"!==a.lastPutMode)&&Ge.forEach((function(t){t.parentNode&&t.parentNode.removeChild(t)}))}},nullingGlobal:function(){this.isMultiDrag=je=!1,Ge.length=0},destroyGlobal:function(){this._deselectMultiDrag(),A(document,"pointerup",this._deselectMultiDrag),A(document,"mouseup",this._deselectMultiDrag),A(document,"touchend",this._deselectMultiDrag),A(document,"keydown",this._checkKeyDown),A(document,"keyup",this._checkKeyUp)},_deselectMultiDrag:function(t){if(("undefined"===typeof je||!je)&&De===this.sortable&&(!t||!I(t.target,this.options.draggable,this.sortable.el,!1))&&(!t||0===t.button))while(Ue.length){var e=Ue[0];N(e,this.options.selectedClass,!1),Ue.shift(),st({sortable:this.sortable,rootEl:this.sortable.el,name:"deselect",targetEl:e,originalEvt:t})}},_checkKeyDown:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!0)},_checkKeyUp:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!1)}},a(t,{pluginName:"multiDrag",utils:{select:function(t){var e=t.parentNode[Q];e&&e.options.multiDrag&&!~Ue.indexOf(t)&&(De&&De!==e&&(De.multiDrag._deselectMultiDrag(),De=e),N(t,e.options.selectedClass,!0),Ue.push(t))},deselect:function(t){var e=t.parentNode[Q],n=Ue.indexOf(t);e&&e.options.multiDrag&&~n&&(N(t,e.options.selectedClass,!1),Ue.splice(n,1))}},eventProperties:function(){var t=this,e=[],n=[];return Ue.forEach((function(r){var i;e.push({multiDragElement:r,index:r.sortableIndex}),i=Xe&&r!==Le?-1:Xe?X(r,":not(."+t.options.selectedClass+")"):X(r),n.push({multiDragElement:r,index:i})})),{items:c(Ue),clones:[].concat(Ge),oldIndicies:e,newIndicies:n}},optionListeners:{multiDragKey:function(t){return t=t.toLowerCase(),"ctrl"===t?t="Control":t.length>1&&(t=t.charAt(0).toUpperCase()+t.substr(1)),t}}})}function Ve(t,e){Ue.forEach((function(n,r){var i=e.children[n.sortableIndex+(t?Number(r):0)];i?e.insertBefore(n,i):e.appendChild(n)}))}function Ye(t,e){Ge.forEach((function(n,r){var i=e.children[n.sortableIndex+(t?Number(r):0)];i?e.insertBefore(n,i):e.appendChild(n)}))}function We(){Ue.forEach((function(t){t!==Le&&t.parentNode&&t.parentNode.removeChild(t)}))}ne.mount(new Te),ne.mount(Pe,Ie),e["default"]=ne},2511:function(t,e,n){var r;/*! https://mths.be/punycode v1.3.2 by @mathias */t=n.nmd(t),function(i){e&&e.nodeType,t&&t.nodeType;var o="object"==typeof n.g&&n.g;o.global!==o&&o.window!==o&&o.self;var s,a=2147483647,u=36,l=1,c=26,h=38,f=700,d=72,p=128,v="-",m=/^xn--/,g=/[^\x20-\x7E]/,_=/[\x2E\u3002\uFF0E\uFF61]/g,y={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},b=u-l,E=Math.floor,x=String.fromCharCode;function T(t){throw RangeError(y[t])}function S(t,e){var n=t.length,r=[];while(n--)r[n]=e(t[n]);return r}function R(t,e){var n=t.split("@"),r="";n.length>1&&(r=n[0]+"@",t=n[1]),t=t.replace(_,".");var i=t.split("."),o=S(i,e).join(".");return r+o}function A(t){var e,n,r=[],i=0,o=t.length;while(i<o)e=t.charCodeAt(i++),e>=55296&&e<=56319&&i<o?(n=t.charCodeAt(i++),56320==(64512&n)?r.push(((1023&e)<<10)+(1023&n)+65536):(r.push(e),i--)):r.push(e);return r}function O(t){return S(t,(function(t){var e="";return t>65535&&(t-=65536,e+=x(t>>>10&1023|55296),t=56320|1023&t),e+=x(t),e})).join("")}function w(t){return t-48<10?t-22:t-65<26?t-65:t-97<26?t-97:u}function I(t,e){return t+22+75*(t<26)-((0!=e)<<5)}function P(t,e,n){var r=0;for(t=n?E(t/f):t>>1,t+=E(t/e);t>b*c>>1;r+=u)t=E(t/b);return E(r+(b+1)*t/(t+h))}function C(t){var e,n,r,i,o,s,h,f,m,g,_=[],y=t.length,b=0,x=p,S=d;for(n=t.lastIndexOf(v),n<0&&(n=0),r=0;r<n;++r)t.charCodeAt(r)>=128&&T("not-basic"),_.push(t.charCodeAt(r));for(i=n>0?n+1:0;i<y;){for(o=b,s=1,h=u;;h+=u){if(i>=y&&T("invalid-input"),f=w(t.charCodeAt(i++)),(f>=u||f>E((a-b)/s))&&T("overflow"),b+=f*s,m=h<=S?l:h>=S+c?c:h-S,f<m)break;g=u-m,s>E(a/g)&&T("overflow"),s*=g}e=_.length+1,S=P(b-o,e,0==o),E(b/e)>a-x&&T("overflow"),x+=E(b/e),b%=e,_.splice(b++,0,x)}return O(_)}function N(t){var e,n,r,i,o,s,h,f,m,g,_,y,b,S,R,O=[];for(t=A(t),y=t.length,e=p,n=0,o=d,s=0;s<y;++s)_=t[s],_<128&&O.push(x(_));r=i=O.length,i&&O.push(v);while(r<y){for(h=a,s=0;s<y;++s)_=t[s],_>=e&&_<h&&(h=_);for(b=r+1,h-e>E((a-n)/b)&&T("overflow"),n+=(h-e)*b,e=h,s=0;s<y;++s)if(_=t[s],_<e&&++n>a&&T("overflow"),_==e){for(f=n,m=u;;m+=u){if(g=m<=o?l:m>=o+c?c:m-o,f<g)break;R=f-g,S=u-g,O.push(x(I(g+R%S,0))),f=E(R/S)}O.push(x(I(f,0))),o=P(n,b,r==i),n=0,++r}++n,++e}return O.join("")}function M(t){return R(t,(function(t){return m.test(t)?C(t.slice(4).toLowerCase()):t}))}function D(t){return R(t,(function(t){return g.test(t)?"xn--"+N(t):t}))}s={version:"1.3.2",ucs2:{decode:A,encode:O},decode:C,encode:N,toASCII:D,toUnicode:M},r=function(){return s}.call(e,n,e,t),void 0===r||(t.exports=r)}()},8575:function(t,e,n){"use strict";var r=n(2511),i=n(2502);function o(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}e.Qc=E,e.DB=T,e.WU=x;var s=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,u=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,l=["<",">",'"',"`"," ","\r","\n","\t"],c=["{","}","|","\\","^","`"].concat(l),h=["'"].concat(c),f=["%","/","?",";","#"].concat(h),d=["/","?","#"],p=255,v=/^[+a-z0-9A-Z_-]{0,63}$/,m=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,g={javascript:!0,"javascript:":!0},_={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},b=n(7673);function E(t,e,n){if(t&&i.isObject(t)&&t instanceof o)return t;var r=new o;return r.parse(t,e,n),r}function x(t){return i.isString(t)&&(t=E(t)),t instanceof o?t.format():o.prototype.format.call(t)}function T(t,e){return E(t,!1,!0).resolve(e)}function S(t,e){return t?E(t,!1,!0).resolveObject(e):e}o.prototype.parse=function(t,e,n){if(!i.isString(t))throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var o=t.indexOf("?"),a=-1!==o&&o<t.indexOf("#")?"?":"#",l=t.split(a),c=/\\/g;l[0]=l[0].replace(c,"/"),t=l.join(a);var E=t;if(E=E.trim(),!n&&1===t.split("#").length){var x=u.exec(E);if(x)return this.path=E,this.href=E,this.pathname=x[1],x[2]?(this.search=x[2],this.query=e?b.parse(this.search.substr(1)):this.search.substr(1)):e&&(this.search="",this.query={}),this}var T=s.exec(E);if(T){T=T[0];var S=T.toLowerCase();this.protocol=S,E=E.substr(T.length)}if(n||T||E.match(/^\/\/[^@\/]+@[^@\/]+/)){var R="//"===E.substr(0,2);!R||T&&_[T]||(E=E.substr(2),this.slashes=!0)}if(!_[T]&&(R||T&&!y[T])){for(var A,O,w=-1,I=0;I<d.length;I++){var P=E.indexOf(d[I]);-1!==P&&(-1===w||P<w)&&(w=P)}O=-1===w?E.lastIndexOf("@"):E.lastIndexOf("@",w),-1!==O&&(A=E.slice(0,O),E=E.slice(O+1),this.auth=decodeURIComponent(A)),w=-1;for(I=0;I<f.length;I++){P=E.indexOf(f[I]);-1!==P&&(-1===w||P<w)&&(w=P)}-1===w&&(w=E.length),this.host=E.slice(0,w),E=E.slice(w),this.parseHost(),this.hostname=this.hostname||"";var C="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!C)for(var N=this.hostname.split(/\./),M=(I=0,N.length);I<M;I++){var D=N[I];if(D&&!D.match(v)){for(var L="",F=0,B=D.length;F<B;F++)D.charCodeAt(F)>127?L+="x":L+=D[F];if(!L.match(v)){var U=N.slice(0,I),G=N.slice(I+1),k=D.match(m);k&&(U.push(k[1]),G.unshift(k[2])),G.length&&(E="/"+G.join(".")+E),this.hostname=U.join(".");break}}}this.hostname.length>p?this.hostname="":this.hostname=this.hostname.toLowerCase(),C||(this.hostname=r.toASCII(this.hostname));var X=this.port?":"+this.port:"",j=this.hostname||"";this.host=j+X,this.href+=this.host,C&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==E[0]&&(E="/"+E))}if(!g[S])for(I=0,M=h.length;I<M;I++){var H=h[I];if(-1!==E.indexOf(H)){var V=encodeURIComponent(H);V===H&&(V=escape(H)),E=E.split(H).join(V)}}var Y=E.indexOf("#");-1!==Y&&(this.hash=E.substr(Y),E=E.slice(0,Y));var W=E.indexOf("?");if(-1!==W?(this.search=E.substr(W),this.query=E.substr(W+1),e&&(this.query=b.parse(this.query)),E=E.slice(0,W)):e&&(this.search="",this.query={}),E&&(this.pathname=E),y[S]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){X=this.pathname||"";var z=this.search||"";this.path=X+z}return this.href=this.format(),this},o.prototype.format=function(){var t=this.auth||"";t&&(t=encodeURIComponent(t),t=t.replace(/%3A/i,":"),t+="@");var e=this.protocol||"",n=this.pathname||"",r=this.hash||"",o=!1,s="";this.host?o=t+this.host:this.hostname&&(o=t+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(o+=":"+this.port)),this.query&&i.isObject(this.query)&&Object.keys(this.query).length&&(s=b.stringify(this.query));var a=this.search||s&&"?"+s||"";return e&&":"!==e.substr(-1)&&(e+=":"),this.slashes||(!e||y[e])&&!1!==o?(o="//"+(o||""),n&&"/"!==n.charAt(0)&&(n="/"+n)):o||(o=""),r&&"#"!==r.charAt(0)&&(r="#"+r),a&&"?"!==a.charAt(0)&&(a="?"+a),n=n.replace(/[?#]/g,(function(t){return encodeURIComponent(t)})),a=a.replace("#","%23"),e+o+n+a+r},o.prototype.resolve=function(t){return this.resolveObject(E(t,!1,!0)).format()},o.prototype.resolveObject=function(t){if(i.isString(t)){var e=new o;e.parse(t,!1,!0),t=e}for(var n=new o,r=Object.keys(this),s=0;s<r.length;s++){var a=r[s];n[a]=this[a]}if(n.hash=t.hash,""===t.href)return n.href=n.format(),n;if(t.slashes&&!t.protocol){for(var u=Object.keys(t),l=0;l<u.length;l++){var c=u[l];"protocol"!==c&&(n[c]=t[c])}return y[n.protocol]&&n.hostname&&!n.pathname&&(n.path=n.pathname="/"),n.href=n.format(),n}if(t.protocol&&t.protocol!==n.protocol){if(!y[t.protocol]){for(var h=Object.keys(t),f=0;f<h.length;f++){var d=h[f];n[d]=t[d]}return n.href=n.format(),n}if(n.protocol=t.protocol,t.host||_[t.protocol])n.pathname=t.pathname;else{var p=(t.pathname||"").split("/");while(p.length&&!(t.host=p.shift()));t.host||(t.host=""),t.hostname||(t.hostname=""),""!==p[0]&&p.unshift(""),p.length<2&&p.unshift(""),n.pathname=p.join("/")}if(n.search=t.search,n.query=t.query,n.host=t.host||"",n.auth=t.auth,n.hostname=t.hostname||t.host,n.port=t.port,n.pathname||n.search){var v=n.pathname||"",m=n.search||"";n.path=v+m}return n.slashes=n.slashes||t.slashes,n.href=n.format(),n}var g=n.pathname&&"/"===n.pathname.charAt(0),b=t.host||t.pathname&&"/"===t.pathname.charAt(0),E=b||g||n.host&&t.pathname,x=E,T=n.pathname&&n.pathname.split("/")||[],S=(p=t.pathname&&t.pathname.split("/")||[],n.protocol&&!y[n.protocol]);if(S&&(n.hostname="",n.port=null,n.host&&(""===T[0]?T[0]=n.host:T.unshift(n.host)),n.host="",t.protocol&&(t.hostname=null,t.port=null,t.host&&(""===p[0]?p[0]=t.host:p.unshift(t.host)),t.host=null),E=E&&(""===p[0]||""===T[0])),b)n.host=t.host||""===t.host?t.host:n.host,n.hostname=t.hostname||""===t.hostname?t.hostname:n.hostname,n.search=t.search,n.query=t.query,T=p;else if(p.length)T||(T=[]),T.pop(),T=T.concat(p),n.search=t.search,n.query=t.query;else if(!i.isNullOrUndefined(t.search)){if(S){n.hostname=n.host=T.shift();var R=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");R&&(n.auth=R.shift(),n.host=n.hostname=R.shift())}return n.search=t.search,n.query=t.query,i.isNull(n.pathname)&&i.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!T.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var A=T.slice(-1)[0],O=(n.host||t.host||T.length>1)&&("."===A||".."===A)||""===A,w=0,I=T.length;I>=0;I--)A=T[I],"."===A?T.splice(I,1):".."===A?(T.splice(I,1),w++):w&&(T.splice(I,1),w--);if(!E&&!x)for(;w--;w)T.unshift("..");!E||""===T[0]||T[0]&&"/"===T[0].charAt(0)||T.unshift(""),O&&"/"!==T.join("/").substr(-1)&&T.push("");var P=""===T[0]||T[0]&&"/"===T[0].charAt(0);if(S){n.hostname=n.host=P?"":T.length?T.shift():"";R=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");R&&(n.auth=R.shift(),n.host=n.hostname=R.shift())}return E=E||n.host&&T.length,E&&!P&&T.unshift(""),T.length?n.pathname=T.join("/"):(n.pathname=null,n.path=null),i.isNull(n.pathname)&&i.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=t.auth||n.auth,n.slashes=n.slashes||t.slashes,n.href=n.format(),n},o.prototype.parseHost=function(){var t=this.host,e=a.exec(t);e&&(e=e[0],":"!==e&&(this.port=e.substr(1)),t=t.substr(0,t.length-e.length)),t&&(this.hostname=t)}},2502:function(t){"use strict";t.exports={isString:function(t){return"string"===typeof t},isObject:function(t){return"object"===typeof t&&null!==t},isNull:function(t){return null===t},isNullOrUndefined:function(t){return null==t}}},3744:function(t,e){"use strict";e.Z=(t,e)=>{const n=t.__vccOpts||t;for(const[r,i]of e)n[r]=i;return n}},9179:function(t,e,n){"use strict";n.d(e,{Z:function(){return T}});var r=n(4865);function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t){return function(t){if(Array.isArray(t))return a(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||s(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(t,e){if(t){if("string"==typeof t)return a(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(t,e):void 0}}function a(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function u(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=s(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){u=!0,o=t},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw o}}}}var l={inheritAttrs:!1,name:"vue-input",props:{autocomplete:{required:!1,type:String},modelValue:{required:!0,type:String},placeholder:{required:!0,type:String},disabled:{required:!0,type:Boolean},tabindex:{required:!0,type:Number},autofocus:{required:!0,type:Boolean},comboboxUid:{required:!0,type:Number}},emits:["update:modelValue","input","change","focus","blur","escape"],setup:function(t,e){var n=(0,r.ref)(null);return(0,r.onMounted)((function(){t.autofocus&&n.value.focus()})),(0,r.onUpdated)((function(){t.autofocus&&n.value.focus()})),{handleInput:function(t){e.emit("input",t),e.emit("update:modelValue",t.target.value)},handleChange:function(t){e.emit("change",t),e.emit("update:modelValue",t.target.value)},handleFocus:function(t){e.emit("focus",t)},handleBlur:function(t){e.emit("blur",t)},input:n,handleEscape:function(t){n.value.blur(),e.emit("escape",t)}}}},c={class:"vue-input"},h=["autocomplete","modelValue","placeholder","disabled","tabindex","autofocus","aria-controls","aria-labelledby"];l.render=function(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createElementBlock)("div",c,[(0,r.renderSlot)(t.$slots,"prepend"),(0,r.createElementVNode)("input",{ref:"input",autocomplete:n.autocomplete,modelValue:n.modelValue,placeholder:n.placeholder,disabled:n.disabled,onInput:e[0]||(e[0]=function(){return i.handleInput&&i.handleInput.apply(i,arguments)}),onChange:e[1]||(e[1]=function(){return i.handleChange&&i.handleChange.apply(i,arguments)}),onFocus:e[2]||(e[2]=function(){return i.handleFocus&&i.handleFocus.apply(i,arguments)}),onBlur:e[3]||(e[3]=function(){return i.handleBlur&&i.handleBlur.apply(i,arguments)}),onKeyup:e[4]||(e[4]=(0,r.withKeys)((0,r.withModifiers)((function(){return i.handleEscape&&i.handleEscape.apply(i,arguments)}),["exact"]),["esc"])),tabindex:n.tabindex,autofocus:n.autofocus,"aria-autocomplete":"list","aria-controls":"vs".concat(n.comboboxUid,"-listbox"),"aria-labelledby":"vs".concat(n.comboboxUid,"-combobox")},null,40,h),(0,r.renderSlot)(t.$slots,"append")])},l.__file="src/components/input.vue";var f={inheritAttrs:!1,name:"vue-tags",props:{modelValue:{required:!0,type:Array,validator:function(t){return t.every((function(t){return void 0!==i(t.key)&&void 0!==t.label&&"boolean"==typeof t.selected}))}},collapseTags:{type:Boolean}},emits:["click"],setup:function(t,e){return{dataAttrs:(0,r.inject)("dataAttrs"),handleClick:function(t){e.emit("click",t)}}},render:function(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createElementBlock)("ul",(0,r.mergeProps)({class:["vue-tags",{collapsed:n.collapseTags}],onMousedown:e[0]||(e[0]=(0,r.withModifiers)((function(){}),["prevent"])),tabindex:"-1",onClick:e[1]||(e[1]=function(){return i.handleClick&&i.handleClick.apply(i,arguments)})},i.dataAttrs),[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.modelValue,(function(e){return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:e.key},[e.group?(0,r.createCommentVNode)("v-if",!0):((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:0,class:(0,r.normalizeClass)(["vue-tag",{selected:e.selected}])},[(0,r.renderSlot)(t.$slots,"default",{option:e},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.label),1)]}))],2))],64)})),128))],16)},__file:"src/components/tags.vue"},d={inheritAttrs:!1,name:"vue-dropdown",props:{modelValue:{required:!0,type:Array,validator:function(t){return t.every((function(t){return void 0!==i(t.key)&&void 0!==t.label&&"boolean"==typeof t.selected}))}},comboboxUid:{required:!0,type:Number},maxHeight:{required:!0},highlightedOriginalIndex:{required:!0}},emits:["click-item","mouseenter"],setup:function(t,e){return{dataAttrs:(0,r.inject)("dataAttrs"),handleClickItem:function(t,n){n.disabled||e.emit("click-item",t,n)},handleMouseenter:function(t,n){e.emit("mouseenter",t,n)}}}},p=["id","aria-multiselectable","aria-busy","aria-disabled"],v=["onClick","onMouseenter","id","aria-selected","aria-disabled"];d.render=function(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createElementBlock)("ul",(0,r.mergeProps)({class:"vue-dropdown",style:{maxHeight:n.maxHeight+"px"},onMousedown:e[0]||(e[0]=(0,r.withModifiers)((function(){}),["prevent"]))},i.dataAttrs,{role:"listbox",id:"vs".concat(n.comboboxUid,"-listbox"),"aria-multiselectable":i.dataAttrs["data-multiple"],"aria-busy":i.dataAttrs["data-loading"],"aria-disabled":i.dataAttrs["data-disabled"]}),[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.modelValue,(function(e,o){return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:e.key},[e.visible&&!1===e.hidden?((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:0,onClick:function(t){return i.handleClickItem(t,e)},class:(0,r.normalizeClass)(["vue-dropdown-item",{selected:e.selected,disabled:e.disabled,highlighted:e.originalIndex===n.highlightedOriginalIndex,group:e.group}]),onMouseenter:function(t){return i.handleMouseenter(t,e)},role:"option",id:"vs".concat(n.comboboxUid,"-option-").concat(o),"aria-selected":!!e.selected||!!e.disabled&&void 0,"aria-disabled":e.disabled},[(0,r.renderSlot)(t.$slots,"default",{option:e},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.label),1)]}))],42,v)):(0,r.createCommentVNode)("v-if",!0)],64)})),128))],16,p)},d.__file="src/components/dropdown.vue";var m=function(t,e,n){var r=n.valueBy;return r(t)===r(e)},g=function(t,e,n){var r=n.valueBy;return t.some((function(t){return m(t,e,{valueBy:r})}))},_=function(t,e,n){var r=n.valueBy;return t.find((function(t){return r(t)===e}))},y=function(t,e,n){var r=n.max,i=n.valueBy;return g(t,e,{valueBy:i})||t.length>=r?t:t.concat(e)},b=function(t,e,n){var r=n.min,i=n.valueBy;return!1===g(t,e,{valueBy:i})||t.length<=r?t:t.filter((function(t){return!1===m(t,e,{valueBy:i})}))},E=function(t){return(0,r.computed)((function(){return"function"==typeof t.value?t.value:"string"==typeof t.value?function(e){return t.value.split(".").reduce((function(t,e){return t[e]}),e)}:function(t){return t}}))},x=function(t,e){var n=(0,r.computed)((function(){return t.value.reduce((function(t,e){return Object.assign(t,(n={},r=e.originalIndex,i=e,r in n?Object.defineProperty(n,r,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[r]=i,n));var n,r,i}),{})})),i=function(t){var r=n.value[t];return void 0!==r&&!1!==o(r)&&(e.value=t,!0)},o=function(t){return!t.disabled&&!t.hidden&&t.visible},s=(0,r.computed)((function(){return t.value.some((function(t){return o(t)}))}));return(0,r.watchEffect)((function(){if(!1===s.value&&(e.value=null),null!==e.value&&t.value.length<=e.value){var n,r=u(t.value.reverse());try{for(r.s();!(n=r.n()).done;){var a=n.value;if(i(a.originalIndex))break}}catch(t){r.e(t)}finally{r.f()}}if(null===e.value||!1===o(t.value[e.value])){var l,c=u(t.value);try{for(c.s();!(l=c.n()).done;){var h=l.value;if(i(h.originalIndex))break}}catch(t){c.e(t)}finally{c.f()}}})),{pointerForward:function(){if(!1!==s.value&&null!==e.value)for(var n=e.value+1,r=0;n!==e.value&&r++<t.value.length&&(t.value.length<=n&&(n=0),!i(n));)++n},pointerBackward:function(){if(!1!==s.value&&null!==e.value)for(var n=e.value-1,r=0;n!==e.value&&r++<t.value.length&&(n<0&&(n=t.value.length-1),!i(n));)--n},pointerSet:i}},T=(0,r.defineComponent)({name:"vue-select",inheritAttrs:!1,props:{modelValue:{required:!0},emptyModelValue:{},options:{required:!0,type:Array},labelBy:{type:[String,Function]},valueBy:{type:[String,Function]},disabledBy:{default:"disabled",type:[String,Function]},groupBy:{default:"group",type:[String,Function]},visibleOptions:{type:Array,default:null},multiple:{default:!1,type:Boolean},min:{default:0,type:Number},max:{default:1/0,type:Number},searchable:{default:!1,type:Boolean},searchPlaceholder:{default:"Type to search",type:String},clearOnSelect:{default:!1,type:Boolean},clearOnClose:{default:!1,type:Boolean},taggable:{default:!1,type:Boolean},collapseTags:{default:!1,type:Boolean},autocomplete:{default:"off",type:String},disabled:{default:!1,type:Boolean},loading:{default:!1,type:Boolean},closeOnSelect:{default:!1,type:Boolean},hideSelected:{default:!1,type:Boolean},placeholder:{default:"Select option",type:String},tabindex:{default:0,type:Number},autofocus:{default:!1,type:Boolean},maxHeight:{default:300,type:Number},openDirection:{type:String,validator:function(t){return["top","bottom"].includes(t)}}},emits:["selected","removed","update:modelValue","focus","blur","toggle","opened","closed","search:input","search:change","search:focus","search:blur"],setup:function(t,e){var n=function(t){var e=(0,r.reactive)({}),n=E((0,r.toRef)(t,"labelBy"));(0,r.watchEffect)((function(){return e.labelBy=n.value}));var i=E((0,r.toRef)(t,"valueBy"));(0,r.watchEffect)((function(){return e.valueBy=i.value}));var o=E((0,r.toRef)(t,"disabledBy"));(0,r.watchEffect)((function(){return e.disabledBy=o.value}));var s=E((0,r.toRef)(t,"groupBy"));(0,r.watchEffect)((function(){return e.groupBy=s.value}));var a=(0,r.computed)((function(){return t.multiple?t.min:Math.min(1,t.min)}));(0,r.watchEffect)((function(){return e.min=a.value}));var u=(0,r.computed)((function(){return t.multiple?t.max:1}));return(0,r.watchEffect)((function(){return e.max=u.value})),(0,r.watchEffect)((function(){return e.options=t.options})),e}(t),i=(0,r.computed)((function(){var e;return null!==(e=t.emptyModelValue)&&void 0!==e?e:null})),s=(0,r.getCurrentInstance)(),a=(0,r.ref)(),l=(0,r.ref)(),c=(0,r.ref)(),h=(0,r.computed)((function(){var t;return null===(t=c.value)||void 0===t?void 0:t._.refs.input})),f=(0,r.ref)(!1);(0,r.watch)((function(){return f.value}),(function(){f.value?(e.emit("opened"),e.emit("focus"),t.searchable?(h.value!==document.activeElement&&h.value.focus(),e.emit("search:focus")):a.value.focus()):(t.searchable?(h.value===document.activeElement&&h.value.blur(),t.clearOnClose&&N(),e.emit("search:blur")):a.value.blur(),e.emit("closed"),e.emit("blur")),e.emit("toggle")}));var d=function(){t.disabled||(f.value=!0)},p=function(t){a.value.contains(null==t?void 0:t.relatedTarget)?setTimeout((function(){a.value.focus()})):f.value=!1};(0,r.watch)((function(){return t.disabled}),(function(){return p()}));var v=(0,r.ref)(""),m=(0,r.computed)((function(){return new RegExp(v.value.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"i")})),T=(0,r.computed)((function(){return v.value?n.options.filter((function(t){return m.value.test(n.labelBy(t))})):void 0})),S=(0,r.ref)([]),R=(0,r.computed)((function(){return new Set(S.value.map((function(t){return n.valueBy(t)})))})),A=function(){if(t.multiple){if(!1===Array.isArray(t.modelValue))return!1;if(S.value.length!==t.modelValue.length)return!1;if(Object.keys(S.value).some((function(e){return S.value[e]!==_(n.options,t.modelValue[e],{valueBy:n.valueBy})})))return!1}else{if(0===S.value.length&&t.modelValue!==i.value)return!1;if(1===S.value.length&&t.modelValue===i.value)return!1;if(S.value[0]!==_(n.options,t.modelValue,{valueBy:n.valueBy}))return!1}return!0},O=function(){if(!A()){S.value=[];var e,r=u(t.multiple?t.modelValue:t.modelValue===i.value?[]:[t.modelValue]);try{for(r.s();!(e=r.n()).done;){var o=e.value,s=_(n.options,o,{valueBy:n.valueBy});!1!==g(n.options,s,{valueBy:n.valueBy})&&(S.value=y(S.value,s,{max:1/0,valueBy:n.valueBy}))}}catch(e){r.e(e)}finally{r.f()}}};O(),(0,r.watch)((function(){return t.modelValue}),(function(){return O()}),{deep:!0}),(0,r.watch)((function(){return n.options}),(function(){S.value=n.options.filter((function(t){return R.value.has(n.valueBy(t))}))}),{deep:!0});var w,I=function(t,r){(r=r.originalOption).value.every((function(t){var e=_(n.options,t,{valueBy:n.valueBy});return g(S.value,e,{valueBy:n.valueBy})}))?r.value.forEach((function(t){var r=_(n.options,t,{valueBy:n.valueBy});S.value=b(S.value,r,{min:n.min,valueBy:n.valueBy}),e.emit("removed",r)})):r.value.forEach((function(t){var r=_(n.options,t,{valueBy:n.valueBy});g(S.value,r,{valueBy:n.valueBy})||(S.value=y(S.value,r,{max:n.max,valueBy:n.valueBy}),e.emit("selected",r))}))},P=function(r,i){if(i=i.originalOption,g(S.value,i,{valueBy:n.valueBy}))S.value=b(S.value,i,{min:n.min,valueBy:n.valueBy}),e.emit("removed",i);else{if(!t.multiple&&1===S.value.length){var o=S.value[0];S.value=b(S.value,S.value[0],{min:0,valueBy:n.valueBy}),e.emit("removed",o)}S.value=y(S.value,i,{max:n.max,valueBy:n.valueBy}),e.emit("selected",i)}},C=function(){if(!A()){var r=S.value.map((function(t){return n.valueBy(t)}));t.multiple?e.emit("update:modelValue",r):r.length?e.emit("update:modelValue",r[0]):e.emit("update:modelValue",i.value)}},N=function(){h.value.value="",h.value.dispatchEvent(new Event("input")),h.value.dispatchEvent(new Event("change"))},M=(0,r.computed)((function(){var e,r;return null!==(r=null!==(e=t.visibleOptions)&&void 0!==e?e:T.value)&&void 0!==r?r:n.options})),D=(0,r.ref)(0),L=(0,r.computed)((function(){var e,r=new Set(M.value.map((function(t){return n.valueBy(t)}))),i=n.options.map((function(e,i){var o,s={key:n.valueBy(e),label:n.labelBy(e),group:null!==(o=n.groupBy(e))&&void 0!==o&&o,originalIndex:i,originalOption:e};return s.selected=s.group?e.value.every((function(t){return R.value.has(t)})):R.value.has(n.valueBy(e)),s.disabled=s.group?n.disabledBy(e)||e.value.every((function(t){var e=_(n.options,t,{valueBy:n.valueBy});return n.disabledBy(e)})):n.disabledBy(e),s.visible=s.group?e.value.some((function(t){return r.has(t)})):r.has(n.valueBy(e)),s.hidden=!!t.hideSelected&&(s.group?e.value.every((function(t){return R.value.has(t)})):R.value.has(n.valueBy(e))),s})),o=u(i);try{for(o.s();!(e=o.n()).done;){var s=e.value;!1!==s.group&&s.disabled&&function(){var t=new Set(s.originalOption.value);i.filter((function(e){return t.has(n.valueBy(e.originalOption))})).forEach((function(t){return t.disabled=!0}))}()}}catch(e){o.e(e)}finally{o.f()}return i})),F=x(L,D),B=F.pointerForward,U=F.pointerBackward,G=F.pointerSet,k="",X=/^[\w]$/,j=(0,r.computed)((function(){var t=o(n.options.keys());return t.slice(D.value).concat(t.slice(0,D.value))})),H=function(){var t,e=null===(t=a.value)||void 0===t?void 0:t.querySelector(".highlighted");if(e&&l.value){var n,r=getComputedStyle(e);for(n=0;e.offsetTop+parseFloat(r.height)+parseFloat(r.paddingTop)+parseFloat(r.paddingBottom)>l.value.$el.clientHeight+l.value.$el.scrollTop&&n++<L.value.length;)l.value.$el.scrollTop=l.value.$el.scrollTop+parseFloat(r.height)+parseFloat(r.paddingTop)+parseFloat(r.paddingBottom);for(n=0;e.offsetTop<l.value.$el.scrollTop&&n++<L.value.length;)l.value.$el.scrollTop=l.value.$el.scrollTop-parseFloat(r.height)-parseFloat(r.paddingTop)-parseFloat(r.paddingBottom)}};(0,r.watch)((function(){return[f.value,n.options,R.value]}),(function(t,e){!0!==(null==e?void 0:e[0])&&!1!==f.value&&0!==S.value.length&&(G(n.options.findIndex((function(t){return R.value.has(n.valueBy(t))}))),(0,r.nextTick)(H))}),{deep:!0,immediate:!0});var V=(0,r.computed)((function(){return{"data-is-focusing":f.value,"data-visible-length":L.value.filter((function(t){return t.visible&&!1===t.hidden})).length,"data-not-selected-length":n.options.length-L.value.filter((function(t){return t.selected})).length,"data-selected-length":L.value.filter((function(t){return t.selected})).length,"data-addable":L.value.filter((function(t){return t.selected})).length<n.max,"data-removable":L.value.filter((function(t){return t.selected})).length>n.min,"data-total-length":n.options.length,"data-multiple":t.multiple,"data-loading":t.loading,"data-disabled":t.disabled}}));(0,r.provide)("dataAttrs",V);var Y=(0,r.computed)((function(){return L.value.filter((function(t){return t.selected})).filter((function(t){return!t.group}))})),W=(0,r.computed)((function(){return t.multiple?0===Y.value.length?t.placeholder:1===Y.value.length?"1 option selected":Y.value.length+" options selected":0===Y.value.length?t.placeholder:Y.value[0].label+""})),z=(0,r.computed)((function(){var e=Y.value.map((function(t){return t.originalOption}));return t.multiple?e:e[0]||i.value})),$=(0,r.ref)();return(0,r.watch)((function(){return[t.openDirection,f.value]}),(function(){var e,n;$.value=null!==(n=null!==(e=t.openDirection)&&void 0!==e?e:function(){if(void 0!==a.value&&void 0!==window)return window.innerHeight-a.value.getBoundingClientRect().bottom>=t.maxHeight?"bottom":"top"}())&&void 0!==n?n:"bottom"}),{immediate:!0}),{instance:s,isFocusing:f,wrapper:a,dropdown:l,input:c,focus:d,blur:p,toggle:function(){f.value?p():d()},searchingInputValue:v,handleInputForInput:function(t){e.emit("search:input",t)},handleChangeForInput:function(t){e.emit("search:change",t)},handleFocusForInput:function(t){d()},handleBlurForInput:function(t){p()},optionsWithInfo:L,addOrRemoveOption:function(e,n){t.disabled||(n.group&&t.multiple?I(e,n):P(e,n),C(),!0===t.closeOnSelect&&(f.value=!1),!0===t.clearOnSelect&&v.value&&N())},dataAttrs:V,innerPlaceholder:W,selected:z,highlightedOriginalIndex:D,pointerForward:function(){B(),(0,r.nextTick)(H)},pointerBackward:function(){U(),(0,r.nextTick)(H)},pointerFirst:function(){var t,e=u(n.options.keys());try{for(e.s();!(t=e.n()).done;){var i=t.value;if(G(i))break}}catch(t){e.e(t)}finally{e.f()}(0,r.nextTick)(H)},pointerLast:function(){var t,e=u(o(n.options.keys()).reverse());try{for(e.s();!(t=e.n()).done;){var i=t.value;if(G(i))break}}catch(t){e.e(t)}finally{e.f()}(0,r.nextTick)(H)},typeAhead:function(e){var r,i;if(!t.searchable){var o=!1;if(X.test(e.key)?(k+=e.key.toLowerCase(),o=!0):"Space"===e.code&&(k+=" "),o){var s,a=u(j.value);try{for(a.s();!(s=a.n()).done;){var l=s.value;if(!0===(null===(i=null===(r=n.labelBy(n.options[l]))||void 0===r?void 0:r.toLowerCase())||void 0===i?void 0:i.startsWith(k))&&G(l))break}}catch(e){a.e(e)}finally{a.f()}clearTimeout(w),w=setTimeout((function(){k=""}),500)}}},pointerSet:G,direction:$}},components:{VInput:l,VTags:f,VDropdown:d}});T.__VERSION__="2.10.2";var S=["tabindex","id","role","aria-expanded","aria-owns","aria-activedescendant","aria-busy","aria-disabled"],R={ref:"header",class:"vue-select-header"},A={key:0,class:"vue-input"},O=["placeholder","autocomplete"],w=["onClick"],I=(0,r.createElementVNode)("span",{class:"icon loading"},[(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div")],-1),P={key:0,class:"vue-select-input-wrapper"},C=(0,r.createElementVNode)("span",{class:"icon loading"},[(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div")],-1);T.render=function(t,e,n,i,o,s){var a=(0,r.resolveComponent)("v-tags"),u=(0,r.resolveComponent)("v-input"),l=(0,r.resolveComponent)("v-dropdown");return(0,r.openBlock)(),(0,r.createElementBlock)("div",(0,r.mergeProps)({ref:"wrapper",class:["vue-select",["direction-".concat(t.direction)]],tabindex:t.isFocusing?-1:t.tabindex,onFocus:e[9]||(e[9]=function(){return t.focus&&t.focus.apply(t,arguments)}),onBlur:e[10]||(e[10]=function(e){return!t.searchable&&t.blur(e)})},Object.assign({},t.dataAttrs,t.$attrs),{onKeypress:e[11]||(e[11]=(0,r.withKeys)((0,r.withModifiers)((function(){return null!==t.highlightedOriginalIndex&&t.addOrRemoveOption(t.$event,t.optionsWithInfo[t.highlightedOriginalIndex])}),["prevent","exact"]),["enter"])),onKeydown:[e[12]||(e[12]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerForward&&t.pointerForward.apply(t,arguments)}),["prevent","exact"]),["down"])),e[13]||(e[13]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerBackward&&t.pointerBackward.apply(t,arguments)}),["prevent","exact"]),["up"])),e[14]||(e[14]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerFirst&&t.pointerFirst.apply(t,arguments)}),["prevent","exact"]),["home"])),e[15]||(e[15]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerLast&&t.pointerLast.apply(t,arguments)}),["prevent","exact"]),["end"])),e[16]||(e[16]=function(){return t.typeAhead&&t.typeAhead.apply(t,arguments)})],id:"vs".concat(t.instance.uid,"-combobox"),role:t.searchable?"combobox":null,"aria-expanded":t.isFocusing,"aria-haspopup":"listbox","aria-owns":"vs".concat(t.instance.uid,"-listbox"),"aria-activedescendant":null===t.highlightedOriginalIndex?null:"vs".concat(t.instance.uid,"-option-").concat(t.highlightedOriginalIndex),"aria-busy":t.loading,"aria-disabled":t.disabled}),[(0,r.createElementVNode)("div",R,[t.multiple&&t.taggable&&0===t.modelValue.length||!1===t.searchable&&!1===t.taggable?((0,r.openBlock)(),(0,r.createElementBlock)("div",A,[(0,r.renderSlot)(t.$slots,"label",{selected:t.selected},(function(){return[(0,r.createElementVNode)("input",{placeholder:t.innerPlaceholder,autocomplete:t.autocomplete,readonly:"",onClick:e[0]||(e[0]=function(){return t.focus&&t.focus.apply(t,arguments)})},null,8,O)]}))])):(0,r.createCommentVNode)("v-if",!0),t.multiple&&t.taggable?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createVNode)(a,{modelValue:t.optionsWithInfo,"collapse-tags":t.collapseTags,tabindex:"-1",onClick:t.focus},{default:(0,r.withCtx)((function(e){var n=e.option;return[(0,r.renderSlot)(t.$slots,"tag",{option:n.originalOption,remove:function(){return t.addOrRemoveOption(t.$event,n)}},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(n.label),1),(0,r.createElementVNode)("img",{src:"data:image/svg+xml;base64,PHN2ZyBpZD0iZGVsZXRlIiBkYXRhLW5hbWU9ImRlbGV0ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNTEyIDUxMiI+PHRpdGxlPmRlbGV0ZTwvdGl0bGU+PHBhdGggZD0iTTI1NiwyNEMzODMuOSwyNCw0ODgsMTI4LjEsNDg4LDI1NlMzODMuOSw0ODgsMjU2LDQ4OCwyNC4wNiwzODMuOSwyNC4wNiwyNTYsMTI4LjEsMjQsMjU2LDI0Wk0wLDI1NkMwLDM5Ny4xNiwxMTQuODQsNTEyLDI1Niw1MTJTNTEyLDM5Ny4xNiw1MTIsMjU2LDM5Ny4xNiwwLDI1NiwwLDAsMTE0Ljg0LDAsMjU2WiIgZmlsbD0iIzViNWI1ZiIvPjxwb2x5Z29uIHBvaW50cz0iMzgyIDE3Mi43MiAzMzkuMjkgMTMwLjAxIDI1NiAyMTMuMjkgMTcyLjcyIDEzMC4wMSAxMzAuMDEgMTcyLjcyIDIxMy4yOSAyNTYgMTMwLjAxIDMzOS4yOCAxNzIuNzIgMzgyIDI1NiAyOTguNzEgMzM5LjI5IDM4MS45OSAzODIgMzM5LjI4IDI5OC43MSAyNTYgMzgyIDE3Mi43MiIgZmlsbD0iIzViNWI1ZiIvPjwvc3ZnPg==",alt:"delete tag",class:"icon delete",onClick:(0,r.withModifiers)((function(){return t.addOrRemoveOption(t.$event,n)}),["prevent","stop"])},null,8,w)]}))]})),_:3},8,["modelValue","collapse-tags","onClick"]),(0,r.renderSlot)(t.$slots,"toggle",{isFocusing:t.isFocusing,toggle:t.toggle},(function(){return[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["icon arrow-downward",{active:t.isFocusing}]),onClick:e[1]||(e[1]=function(){return t.toggle&&t.toggle.apply(t,arguments)}),onMousedown:e[2]||(e[2]=(0,r.withModifiers)((function(){}),["prevent","stop"]))},null,34)]}))],64)):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:2},[t.searchable?((0,r.openBlock)(),(0,r.createBlock)(u,{key:0,ref:"input",modelValue:t.searchingInputValue,"onUpdate:modelValue":e[3]||(e[3]=function(e){return t.searchingInputValue=e}),disabled:t.disabled,autocomplete:t.autocomplete,placeholder:t.isFocusing?t.searchPlaceholder:t.innerPlaceholder,onInput:t.handleInputForInput,onChange:t.handleChangeForInput,onFocus:t.handleFocusForInput,onBlur:t.handleBlurForInput,onEscape:t.blur,autofocus:t.autofocus||t.taggable&&t.searchable,tabindex:t.tabindex,comboboxUid:t.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"])):(0,r.createCommentVNode)("v-if",!0),t.loading?(0,r.renderSlot)(t.$slots,"loading",{key:1},(function(){return[I]})):(0,r.renderSlot)(t.$slots,"toggle",{key:2,isFocusing:t.isFocusing,toggle:t.toggle},(function(){return[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["icon arrow-downward",{active:t.isFocusing}]),onClick:e[4]||(e[4]=function(){return t.toggle&&t.toggle.apply(t,arguments)}),onMousedown:e[5]||(e[5]=(0,r.withModifiers)((function(){}),["prevent","stop"]))},null,34)]}))],64))],512),t.multiple&&t.taggable&&t.searchable?((0,r.openBlock)(),(0,r.createElementBlock)("div",P,[(0,r.withDirectives)((0,r.createVNode)(u,{ref:"input",modelValue:t.searchingInputValue,"onUpdate:modelValue":e[6]||(e[6]=function(e){return t.searchingInputValue=e}),disabled:t.disabled,autocomplete:t.autocomplete,placeholder:t.isFocusing?t.searchPlaceholder:t.innerPlaceholder,onInput:t.handleInputForInput,onChange:t.handleChangeForInput,onFocus:t.handleFocusForInput,onBlur:t.handleBlurForInput,onEscape:t.blur,autofocus:t.autofocus||t.taggable&&t.searchable,tabindex:t.tabindex,comboboxUid:t.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"]),[[r.vShow,t.isFocusing]]),t.loading?(0,r.renderSlot)(t.$slots,"loading",{key:0},(function(){return[C]})):(0,r.createCommentVNode)("v-if",!0)])):(0,r.createCommentVNode)("v-if",!0),(0,r.createVNode)(l,{ref:"dropdown",modelValue:t.optionsWithInfo,"onUpdate:modelValue":e[7]||(e[7]=function(e){return t.optionsWithInfo=e}),onClickItem:t.addOrRemoveOption,onMouseenter:e[8]||(e[8]=function(e,n){return t.pointerSet(n.originalIndex)}),comboboxUid:t.instance.uid,maxHeight:t.maxHeight,highlightedOriginalIndex:t.highlightedOriginalIndex},{default:(0,r.withCtx)((function(e){var n=e.option;return[(0,r.renderSlot)(t.$slots,"dropdown-item",{option:n.originalOption},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(n.label),1)]}))]})),_:3},8,["modelValue","onClickItem","comboboxUid","maxHeight","highlightedOriginalIndex"])],16,S)},T.__file="src/index.vue"},7197:function(t,e){"use strict"; -/*! - * vue-textarea-autosize v1.1.1 - * (c) 2019 Saymon - * Released under the MIT License. - */var n={name:"TextareaAutosize",props:{value:{type:[String,Number],default:""},autosize:{type:Boolean,default:!0},minHeight:{type:[Number],default:null},maxHeight:{type:[Number],default:null},important:{type:[Boolean,Array],default:!1}},data:function(){return{val:null,maxHeightScroll:!1,height:"auto"}},computed:{computedStyles:function(){return this.autosize?{resize:this.isResizeImportant?"none !important":"none",height:this.height,overflow:this.maxHeightScroll?"auto":this.isOverflowImportant?"hidden !important":"hidden"}:{}},isResizeImportant:function(){var t=this.important;return!0===t||Array.isArray(t)&&t.includes("resize")},isOverflowImportant:function(){var t=this.important;return!0===t||Array.isArray(t)&&t.includes("overflow")},isHeightImportant:function(){var t=this.important;return!0===t||Array.isArray(t)&&t.includes("height")}},watch:{value:function(t){this.val=t},val:function(t){this.$nextTick(this.resize),this.$emit("input",t)},minHeight:function(){this.$nextTick(this.resize)},maxHeight:function(){this.$nextTick(this.resize)},autosize:function(t){t&&this.resize()}},methods:{resize:function(){var t=this,e=this.isHeightImportant?"important":"";return this.height="auto".concat(e?" !important":""),this.$nextTick((function(){var n=t.$el.scrollHeight+1;t.minHeight&&(n=n<t.minHeight?t.minHeight:n),t.maxHeight&&(n>t.maxHeight?(n=t.maxHeight,t.maxHeightScroll=!0):t.maxHeightScroll=!1);var r=n+"px";t.height="".concat(r).concat(e?" !important":"")})),this}},created:function(){this.val=this.value},mounted:function(){this.resize()}};function r(t,e,n,r,i,o,s,a,u,l){"boolean"!==typeof s&&(u=a,a=s,s=!1);var c,h="function"===typeof n?n.options:n;if(t&&t.render&&(h.render=t.render,h.staticRenderFns=t.staticRenderFns,h._compiled=!0,i&&(h.functional=!0)),r&&(h._scopeId=r),o?(c=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),e&&e.call(this,u(t)),t&&t._registeredComponents&&t._registeredComponents.add(o)},h._ssrRegister=c):e&&(c=s?function(){e.call(this,l(this.$root.$options.shadowRoot))}:function(t){e.call(this,a(t))}),c)if(h.functional){var f=h.render;h.render=function(t,e){return c.call(e),f(t,e)}}else{var d=h.beforeCreate;h.beforeCreate=d?[].concat(d,c):[c]}return n}var i=r;const o=n;var s=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.val,expression:"val"}],style:t.computedStyles,domProps:{value:t.val},on:{focus:t.resize,input:function(e){e.target.composing||(t.val=e.target.value)}}})},a=[];const u=void 0,l=void 0,c=void 0,h=!1;var f=i({render:s,staticRenderFns:a},u,o,l,h,c,void 0,void 0),d="1.1.1",p=function(t){t.component("TextareaAutosize",f)},v={install:p,version:d};"undefined"!==typeof window&&window.Vue&&window.Vue.use(v),e["Z"]=v},4865:function(t,e,n){"use strict";n.r(e),n.d(e,{BaseTransition:function(){return We},Comment:function(){return Ur},EffectScope:function(){return a},Fragment:function(){return Fr},KeepAlive:function(){return sn},ReactiveEffect:function(){return R},Static:function(){return Gr},Suspense:function(){return Ce},Teleport:function(){return Or},Text:function(){return Br},Transition:function(){return $s},TransitionGroup:function(){return pa},VueElement:function(){return Xs},callWithAsyncErrorHandling:function(){return ro},callWithErrorHandling:function(){return no},camelize:function(){return i._A},capitalize:function(){return i.kC},cloneVNode:function(){return si},compatUtils:function(){return as},compile:function(){return Pf},computed:function(){return ae},createApp:function(){return qa},createBlock:function(){return qr},createCommentVNode:function(){return li},createElementBlock:function(){return $r},createElementVNode:function(){return ni},createHydrationRenderer:function(){return vr},createPropsRestProxy:function(){return qo},createRenderer:function(){return pr},createSSRApp:function(){return Ka},createSlots:function(){return mi},createStaticVNode:function(){return ui},createTextVNode:function(){return ai},createVNode:function(){return ri},customRef:function(){return ne},defineAsyncComponent:function(){return en},defineComponent:function(){return Qe},defineCustomElement:function(){return Us},defineEmits:function(){return jo},defineExpose:function(){return Ho},defineProps:function(){return Xo},defineSSRCustomElement:function(){return Gs},devtools:function(){return ue},effect:function(){return O},effectScope:function(){return u},getCurrentInstance:function(){return wi},getCurrentScope:function(){return c},getTransitionRawChildren:function(){return Je},guardReactiveProps:function(){return oi},h:function(){return Zo},handleError:function(){return io},hydrate:function(){return $a},initCustomFormatter:function(){return ts},initDirectivesForSSR:function(){return Qa},inject:function(){return je},isMemoSame:function(){return ns},isProxy:function(){return Gt},isReactive:function(){return Bt},isReadonly:function(){return Ut},isRef:function(){return Wt},isRuntimeOnly:function(){return Gi},isVNode:function(){return Kr},markRaw:function(){return Xt},mergeDefaults:function(){return $o},mergeProps:function(){return di},nextTick:function(){return bo},normalizeClass:function(){return i.C_},normalizeProps:function(){return i.vs},normalizeStyle:function(){return i.j5},onActivated:function(){return un},onBeforeMount:function(){return mn},onBeforeUnmount:function(){return bn},onBeforeUpdate:function(){return _n},onDeactivated:function(){return ln},onErrorCaptured:function(){return Rn},onMounted:function(){return gn},onRenderTracked:function(){return Sn},onRenderTriggered:function(){return Tn},onScopeDispose:function(){return h},onServerPrefetch:function(){return xn},onUnmounted:function(){return En},onUpdated:function(){return yn},openBlock:function(){return jr},popScopeId:function(){return ye},provide:function(){return Xe},proxyRefs:function(){return te},pushScopeId:function(){return _e},queuePostFlushCb:function(){return Oo},reactive:function(){return Nt},readonly:function(){return Dt},ref:function(){return zt},registerRuntimeCompiler:function(){return Ui},render:function(){return za},renderList:function(){return vi},renderSlot:function(){return gi},resolveComponent:function(){return Pr},resolveDirective:function(){return Mr},resolveDynamicComponent:function(){return Nr},resolveFilter:function(){return ss},resolveTransitionHooks:function(){return $e},setBlockTracking:function(){return Wr},setDevtoolsHook:function(){return he},setTransitionHooks:function(){return Ze},shallowReactive:function(){return Mt},shallowReadonly:function(){return Lt},shallowRef:function(){return $t},ssrContextKey:function(){return Jo},ssrUtils:function(){return os},stop:function(){return w},toDisplayString:function(){return i.zw},toHandlerKey:function(){return i.hR},toHandlers:function(){return yi},toRaw:function(){return kt},toRef:function(){return oe},toRefs:function(){return re},transformVNodeArgs:function(){return Jr},triggerRef:function(){return Zt},unref:function(){return Jt},useAttrs:function(){return Wo},useCssModule:function(){return js},useCssVars:function(){return Hs},useSSRContext:function(){return Qo},useSlots:function(){return Yo},useTransitionState:function(){return He},vModelCheckbox:function(){return Sa},vModelDynamic:function(){return Ca},vModelRadio:function(){return Aa},vModelSelect:function(){return Oa},vModelText:function(){return Ta},vShow:function(){return Ga},version:function(){return rs},warn:function(){return Ki},watch:function(){return Fo},watchEffect:function(){return No},watchPostEffect:function(){return Mo},watchSyncEffect:function(){return Do},withAsyncContext:function(){return Ko},withCtx:function(){return Ee},withDefaults:function(){return Vo},withDirectives:function(){return nr},withKeys:function(){return Ua},withMemo:function(){return es},withModifiers:function(){return Fa},withScopeId:function(){return be}});var r={};n.r(r),n.d(r,{BaseTransition:function(){return We},Comment:function(){return Ur},EffectScope:function(){return a},Fragment:function(){return Fr},KeepAlive:function(){return sn},ReactiveEffect:function(){return R},Static:function(){return Gr},Suspense:function(){return Ce},Teleport:function(){return Or},Text:function(){return Br},Transition:function(){return $s},TransitionGroup:function(){return pa},VueElement:function(){return Xs},callWithAsyncErrorHandling:function(){return ro},callWithErrorHandling:function(){return no},camelize:function(){return i._A},capitalize:function(){return i.kC},cloneVNode:function(){return si},compatUtils:function(){return as},computed:function(){return ae},createApp:function(){return qa},createBlock:function(){return qr},createCommentVNode:function(){return li},createElementBlock:function(){return $r},createElementVNode:function(){return ni},createHydrationRenderer:function(){return vr},createPropsRestProxy:function(){return qo},createRenderer:function(){return pr},createSSRApp:function(){return Ka},createSlots:function(){return mi},createStaticVNode:function(){return ui},createTextVNode:function(){return ai},createVNode:function(){return ri},customRef:function(){return ne},defineAsyncComponent:function(){return en},defineComponent:function(){return Qe},defineCustomElement:function(){return Us},defineEmits:function(){return jo},defineExpose:function(){return Ho},defineProps:function(){return Xo},defineSSRCustomElement:function(){return Gs},devtools:function(){return ue},effect:function(){return O},effectScope:function(){return u},getCurrentInstance:function(){return wi},getCurrentScope:function(){return c},getTransitionRawChildren:function(){return Je},guardReactiveProps:function(){return oi},h:function(){return Zo},handleError:function(){return io},hydrate:function(){return $a},initCustomFormatter:function(){return ts},initDirectivesForSSR:function(){return Qa},inject:function(){return je},isMemoSame:function(){return ns},isProxy:function(){return Gt},isReactive:function(){return Bt},isReadonly:function(){return Ut},isRef:function(){return Wt},isRuntimeOnly:function(){return Gi},isVNode:function(){return Kr},markRaw:function(){return Xt},mergeDefaults:function(){return $o},mergeProps:function(){return di},nextTick:function(){return bo},normalizeClass:function(){return i.C_},normalizeProps:function(){return i.vs},normalizeStyle:function(){return i.j5},onActivated:function(){return un},onBeforeMount:function(){return mn},onBeforeUnmount:function(){return bn},onBeforeUpdate:function(){return _n},onDeactivated:function(){return ln},onErrorCaptured:function(){return Rn},onMounted:function(){return gn},onRenderTracked:function(){return Sn},onRenderTriggered:function(){return Tn},onScopeDispose:function(){return h},onServerPrefetch:function(){return xn},onUnmounted:function(){return En},onUpdated:function(){return yn},openBlock:function(){return jr},popScopeId:function(){return ye},provide:function(){return Xe},proxyRefs:function(){return te},pushScopeId:function(){return _e},queuePostFlushCb:function(){return Oo},reactive:function(){return Nt},readonly:function(){return Dt},ref:function(){return zt},registerRuntimeCompiler:function(){return Ui},render:function(){return za},renderList:function(){return vi},renderSlot:function(){return gi},resolveComponent:function(){return Pr},resolveDirective:function(){return Mr},resolveDynamicComponent:function(){return Nr},resolveFilter:function(){return ss},resolveTransitionHooks:function(){return $e},setBlockTracking:function(){return Wr},setDevtoolsHook:function(){return he},setTransitionHooks:function(){return Ze},shallowReactive:function(){return Mt},shallowReadonly:function(){return Lt},shallowRef:function(){return $t},ssrContextKey:function(){return Jo},ssrUtils:function(){return os},stop:function(){return w},toDisplayString:function(){return i.zw},toHandlerKey:function(){return i.hR},toHandlers:function(){return yi},toRaw:function(){return kt},toRef:function(){return oe},toRefs:function(){return re},transformVNodeArgs:function(){return Jr},triggerRef:function(){return Zt},unref:function(){return Jt},useAttrs:function(){return Wo},useCssModule:function(){return js},useCssVars:function(){return Hs},useSSRContext:function(){return Qo},useSlots:function(){return Yo},useTransitionState:function(){return He},vModelCheckbox:function(){return Sa},vModelDynamic:function(){return Ca},vModelRadio:function(){return Aa},vModelSelect:function(){return Oa},vModelText:function(){return Ta},vShow:function(){return Ga},version:function(){return rs},warn:function(){return Ki},watch:function(){return Fo},watchEffect:function(){return No},watchPostEffect:function(){return Mo},watchSyncEffect:function(){return Do},withAsyncContext:function(){return Ko},withCtx:function(){return Ee},withDefaults:function(){return Vo},withDirectives:function(){return nr},withKeys:function(){return Ua},withMemo:function(){return es},withModifiers:function(){return Fa},withScopeId:function(){return be}});var i=n(3577);let o;const s=[];class a{constructor(t=!1){this.active=!0,this.effects=[],this.cleanups=[],!t&&o&&(this.parent=o,this.index=(o.scopes||(o.scopes=[])).push(this)-1)}run(t){if(this.active)try{return this.on(),t()}finally{this.off()}else 0}on(){this.active&&(s.push(this),o=this)}off(){this.active&&(s.pop(),o=s[s.length-1])}stop(t){if(this.active){if(this.effects.forEach((t=>t.stop())),this.cleanups.forEach((t=>t())),this.scopes&&this.scopes.forEach((t=>t.stop(!0))),this.parent&&!t){const t=this.parent.scopes.pop();t&&t!==this&&(this.parent.scopes[this.index]=t,t.index=this.index)}this.active=!1}}}function u(t){return new a(t)}function l(t,e){e=e||o,e&&e.active&&e.effects.push(t)}function c(){return o}function h(t){o&&o.cleanups.push(t)}const f=t=>{const e=new Set(t);return e.w=0,e.n=0,e},d=t=>(t.w&y)>0,p=t=>(t.n&y)>0,v=({deps:t})=>{if(t.length)for(let e=0;e<t.length;e++)t[e].w|=y},m=t=>{const{deps:e}=t;if(e.length){let n=0;for(let r=0;r<e.length;r++){const i=e[r];d(i)&&!p(i)?i.delete(t):e[n++]=i,i.w&=~y,i.n&=~y}e.length=n}},g=new WeakMap;let _=0,y=1;const b=30,E=[];let x;const T=Symbol(""),S=Symbol("");class R{constructor(t,e=null,n){this.fn=t,this.scheduler=e,this.active=!0,this.deps=[],l(this,n)}run(){if(!this.active)return this.fn();if(!E.includes(this))try{return E.push(x=this),N(),y=1<<++_,_<=b?v(this):A(this),this.fn()}finally{_<=b&&m(this),y=1<<--_,M(),E.pop();const t=E.length;x=t>0?E[t-1]:void 0}}stop(){this.active&&(A(this),this.onStop&&this.onStop(),this.active=!1)}}function A(t){const{deps:e}=t;if(e.length){for(let n=0;n<e.length;n++)e[n].delete(t);e.length=0}}function O(t,e){t.effect&&(t=t.effect.fn);const n=new R(t);e&&((0,i.l7)(n,e),e.scope&&l(n,e.scope)),e&&e.lazy||n.run();const r=n.run.bind(n);return r.effect=n,r}function w(t){t.effect.stop()}let I=!0;const P=[];function C(){P.push(I),I=!1}function N(){P.push(I),I=!0}function M(){const t=P.pop();I=void 0===t||t}function D(t,e,n){if(!L())return;let r=g.get(t);r||g.set(t,r=new Map);let i=r.get(n);i||r.set(n,i=f());const o=void 0;F(i,o)}function L(){return I&&void 0!==x}function F(t,e){let n=!1;_<=b?p(t)||(t.n|=y,n=!d(t)):n=!t.has(x),n&&(t.add(x),x.deps.push(t))}function B(t,e,n,r,o,s){const a=g.get(t);if(!a)return;let u=[];if("clear"===e)u=[...a.values()];else if("length"===n&&(0,i.kJ)(t))a.forEach(((t,e)=>{("length"===e||e>=r)&&u.push(t)}));else switch(void 0!==n&&u.push(a.get(n)),e){case"add":(0,i.kJ)(t)?(0,i.S0)(n)&&u.push(a.get("length")):(u.push(a.get(T)),(0,i._N)(t)&&u.push(a.get(S)));break;case"delete":(0,i.kJ)(t)||(u.push(a.get(T)),(0,i._N)(t)&&u.push(a.get(S)));break;case"set":(0,i._N)(t)&&u.push(a.get(T));break}if(1===u.length)u[0]&&U(u[0]);else{const t=[];for(const e of u)e&&t.push(...e);U(f(t))}}function U(t,e){for(const n of(0,i.kJ)(t)?t:[...t])(n!==x||n.allowRecurse)&&(n.scheduler?n.scheduler():n.run())}const G=(0,i.fY)("__proto__,__v_isRef,__isVue"),k=new Set(Object.getOwnPropertyNames(Symbol).map((t=>Symbol[t])).filter(i.yk)),X=z(),j=z(!1,!0),H=z(!0),V=z(!0,!0),Y=W();function W(){const t={};return["includes","indexOf","lastIndexOf"].forEach((e=>{t[e]=function(...t){const n=kt(this);for(let e=0,i=this.length;e<i;e++)D(n,"get",e+"");const r=n[e](...t);return-1===r||!1===r?n[e](...t.map(kt)):r}})),["push","pop","shift","unshift","splice"].forEach((e=>{t[e]=function(...t){C();const n=kt(this)[e].apply(this,t);return M(),n}})),t}function z(t=!1,e=!1){return function(n,r,o){if("__v_isReactive"===r)return!t;if("__v_isReadonly"===r)return t;if("__v_raw"===r&&o===(t?e?It:wt:e?Ot:At).get(n))return n;const s=(0,i.kJ)(n);if(!t&&s&&(0,i.RI)(Y,r))return Reflect.get(Y,r,o);const a=Reflect.get(n,r,o);if((0,i.yk)(r)?k.has(r):G(r))return a;if(t||D(n,"get",r),e)return a;if(Wt(a)){const t=!s||!(0,i.S0)(r);return t?a.value:a}return(0,i.Kn)(a)?t?Dt(a):Nt(a):a}}const $=K(),q=K(!0);function K(t=!1){return function(e,n,r,o){let s=e[n];if(!t&&!Ut(r)&&(r=kt(r),s=kt(s),!(0,i.kJ)(e)&&Wt(s)&&!Wt(r)))return s.value=r,!0;const a=(0,i.kJ)(e)&&(0,i.S0)(n)?Number(n)<e.length:(0,i.RI)(e,n),u=Reflect.set(e,n,r,o);return e===kt(o)&&(a?(0,i.aU)(r,s)&&B(e,"set",n,r,s):B(e,"add",n,r)),u}}function Z(t,e){const n=(0,i.RI)(t,e),r=t[e],o=Reflect.deleteProperty(t,e);return o&&n&&B(t,"delete",e,void 0,r),o}function J(t,e){const n=Reflect.has(t,e);return(0,i.yk)(e)&&k.has(e)||D(t,"has",e),n}function Q(t){return D(t,"iterate",(0,i.kJ)(t)?"length":T),Reflect.ownKeys(t)}const tt={get:X,set:$,deleteProperty:Z,has:J,ownKeys:Q},et={get:H,set(t,e){return!0},deleteProperty(t,e){return!0}},nt=(0,i.l7)({},tt,{get:j,set:q}),rt=(0,i.l7)({},et,{get:V}),it=t=>t,ot=t=>Reflect.getPrototypeOf(t);function st(t,e,n=!1,r=!1){t=t["__v_raw"];const i=kt(t),o=kt(e);e!==o&&!n&&D(i,"get",e),!n&&D(i,"get",o);const{has:s}=ot(i),a=r?it:n?Ht:jt;return s.call(i,e)?a(t.get(e)):s.call(i,o)?a(t.get(o)):void(t!==i&&t.get(e))}function at(t,e=!1){const n=this["__v_raw"],r=kt(n),i=kt(t);return t!==i&&!e&&D(r,"has",t),!e&&D(r,"has",i),t===i?n.has(t):n.has(t)||n.has(i)}function ut(t,e=!1){return t=t["__v_raw"],!e&&D(kt(t),"iterate",T),Reflect.get(t,"size",t)}function lt(t){t=kt(t);const e=kt(this),n=ot(e),r=n.has.call(e,t);return r||(e.add(t),B(e,"add",t,t)),this}function ct(t,e){e=kt(e);const n=kt(this),{has:r,get:o}=ot(n);let s=r.call(n,t);s||(t=kt(t),s=r.call(n,t));const a=o.call(n,t);return n.set(t,e),s?(0,i.aU)(e,a)&&B(n,"set",t,e,a):B(n,"add",t,e),this}function ht(t){const e=kt(this),{has:n,get:r}=ot(e);let i=n.call(e,t);i||(t=kt(t),i=n.call(e,t));const o=r?r.call(e,t):void 0,s=e.delete(t);return i&&B(e,"delete",t,void 0,o),s}function ft(){const t=kt(this),e=0!==t.size,n=void 0,r=t.clear();return e&&B(t,"clear",void 0,void 0,n),r}function dt(t,e){return function(n,r){const i=this,o=i["__v_raw"],s=kt(o),a=e?it:t?Ht:jt;return!t&&D(s,"iterate",T),o.forEach(((t,e)=>n.call(r,a(t),a(e),i)))}}function pt(t,e,n){return function(...r){const o=this["__v_raw"],s=kt(o),a=(0,i._N)(s),u="entries"===t||t===Symbol.iterator&&a,l="keys"===t&&a,c=o[t](...r),h=n?it:e?Ht:jt;return!e&&D(s,"iterate",l?S:T),{next(){const{value:t,done:e}=c.next();return e?{value:t,done:e}:{value:u?[h(t[0]),h(t[1])]:h(t),done:e}},[Symbol.iterator](){return this}}}}function vt(t){return function(...e){return"delete"!==t&&this}}function mt(){const t={get(t){return st(this,t)},get size(){return ut(this)},has:at,add:lt,set:ct,delete:ht,clear:ft,forEach:dt(!1,!1)},e={get(t){return st(this,t,!1,!0)},get size(){return ut(this)},has:at,add:lt,set:ct,delete:ht,clear:ft,forEach:dt(!1,!0)},n={get(t){return st(this,t,!0)},get size(){return ut(this,!0)},has(t){return at.call(this,t,!0)},add:vt("add"),set:vt("set"),delete:vt("delete"),clear:vt("clear"),forEach:dt(!0,!1)},r={get(t){return st(this,t,!0,!0)},get size(){return ut(this,!0)},has(t){return at.call(this,t,!0)},add:vt("add"),set:vt("set"),delete:vt("delete"),clear:vt("clear"),forEach:dt(!0,!0)},i=["keys","values","entries",Symbol.iterator];return i.forEach((i=>{t[i]=pt(i,!1,!1),n[i]=pt(i,!0,!1),e[i]=pt(i,!1,!0),r[i]=pt(i,!0,!0)})),[t,n,e,r]}const[gt,_t,yt,bt]=mt();function Et(t,e){const n=e?t?bt:yt:t?_t:gt;return(e,r,o)=>"__v_isReactive"===r?!t:"__v_isReadonly"===r?t:"__v_raw"===r?e:Reflect.get((0,i.RI)(n,r)&&r in e?n:e,r,o)}const xt={get:Et(!1,!1)},Tt={get:Et(!1,!0)},St={get:Et(!0,!1)},Rt={get:Et(!0,!0)};const At=new WeakMap,Ot=new WeakMap,wt=new WeakMap,It=new WeakMap;function Pt(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Ct(t){return t["__v_skip"]||!Object.isExtensible(t)?0:Pt((0,i.W7)(t))}function Nt(t){return t&&t["__v_isReadonly"]?t:Ft(t,!1,tt,xt,At)}function Mt(t){return Ft(t,!1,nt,Tt,Ot)}function Dt(t){return Ft(t,!0,et,St,wt)}function Lt(t){return Ft(t,!0,rt,Rt,It)}function Ft(t,e,n,r,o){if(!(0,i.Kn)(t))return t;if(t["__v_raw"]&&(!e||!t["__v_isReactive"]))return t;const s=o.get(t);if(s)return s;const a=Ct(t);if(0===a)return t;const u=new Proxy(t,2===a?r:n);return o.set(t,u),u}function Bt(t){return Ut(t)?Bt(t["__v_raw"]):!(!t||!t["__v_isReactive"])}function Ut(t){return!(!t||!t["__v_isReadonly"])}function Gt(t){return Bt(t)||Ut(t)}function kt(t){const e=t&&t["__v_raw"];return e?kt(e):t}function Xt(t){return(0,i.Nj)(t,"__v_skip",!0),t}const jt=t=>(0,i.Kn)(t)?Nt(t):t,Ht=t=>(0,i.Kn)(t)?Dt(t):t;function Vt(t){L()&&(t=kt(t),t.dep||(t.dep=f()),F(t.dep))}function Yt(t,e){t=kt(t),t.dep&&U(t.dep)}function Wt(t){return Boolean(t&&!0===t.__v_isRef)}function zt(t){return qt(t,!1)}function $t(t){return qt(t,!0)}function qt(t,e){return Wt(t)?t:new Kt(t,e)}class Kt{constructor(t,e){this._shallow=e,this.dep=void 0,this.__v_isRef=!0,this._rawValue=e?t:kt(t),this._value=e?t:jt(t)}get value(){return Vt(this),this._value}set value(t){t=this._shallow?t:kt(t),(0,i.aU)(t,this._rawValue)&&(this._rawValue=t,this._value=this._shallow?t:jt(t),Yt(this,t))}}function Zt(t){Yt(t,void 0)}function Jt(t){return Wt(t)?t.value:t}const Qt={get:(t,e,n)=>Jt(Reflect.get(t,e,n)),set:(t,e,n,r)=>{const i=t[e];return Wt(i)&&!Wt(n)?(i.value=n,!0):Reflect.set(t,e,n,r)}};function te(t){return Bt(t)?t:new Proxy(t,Qt)}class ee{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:e,set:n}=t((()=>Vt(this)),(()=>Yt(this)));this._get=e,this._set=n}get value(){return this._get()}set value(t){this._set(t)}}function ne(t){return new ee(t)}function re(t){const e=(0,i.kJ)(t)?new Array(t.length):{};for(const n in t)e[n]=oe(t,n);return e}class ie{constructor(t,e,n){this._object=t,this._key=e,this._defaultValue=n,this.__v_isRef=!0}get value(){const t=this._object[this._key];return void 0===t?this._defaultValue:t}set value(t){this._object[this._key]=t}}function oe(t,e,n){const r=t[e];return Wt(r)?r:new ie(t,e,n)}class se{constructor(t,e,n){this._setter=e,this.dep=void 0,this._dirty=!0,this.__v_isRef=!0,this.effect=new R(t,(()=>{this._dirty||(this._dirty=!0,Yt(this))})),this["__v_isReadonly"]=n}get value(){const t=kt(this);return Vt(t),t._dirty&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function ae(t,e){let n,r;const o=(0,i.mf)(t);o?(n=t,r=i.dG):(n=t.get,r=t.set);const s=new se(n,r,o||!r);return s}Promise.resolve();new Set;new Map;let ue,le=[],ce=!1;function he(t,e){var n,r;if(ue=t,ue)ue.enabled=!0,le.forEach((({event:t,args:e})=>ue.emit(t,...e))),le=[];else if("undefined"!==typeof window&&window.HTMLElement&&!(null===(r=null===(n=window.navigator)||void 0===n?void 0:n.userAgent)||void 0===r?void 0:r.includes("jsdom"))){const t=e.__VUE_DEVTOOLS_HOOK_REPLAY__=e.__VUE_DEVTOOLS_HOOK_REPLAY__||[];t.push((t=>{he(t,e)})),setTimeout((()=>{ue||(e.__VUE_DEVTOOLS_HOOK_REPLAY__=null,ce=!0,le=[])}),3e3)}else ce=!0,le=[]}function fe(t,e,...n){const r=t.vnode.props||i.kT;let o=n;const s=e.startsWith("update:"),a=s&&e.slice(7);if(a&&a in r){const t=`${"modelValue"===a?"model":a}Modifiers`,{number:e,trim:s}=r[t]||i.kT;s?o=n.map((t=>t.trim())):e&&(o=n.map(i.He))}let u;let l=r[u=(0,i.hR)(e)]||r[u=(0,i.hR)((0,i._A)(e))];!l&&s&&(l=r[u=(0,i.hR)((0,i.rs)(e))]),l&&ro(l,t,6,o);const c=r[u+"Once"];if(c){if(t.emitted){if(t.emitted[u])return}else t.emitted={};t.emitted[u]=!0,ro(c,t,6,o)}}function de(t,e,n=!1){const r=e.emitsCache,o=r.get(t);if(void 0!==o)return o;const s=t.emits;let a={},u=!1;if(!(0,i.mf)(t)){const r=t=>{const n=de(t,e,!0);n&&(u=!0,(0,i.l7)(a,n))};!n&&e.mixins.length&&e.mixins.forEach(r),t.extends&&r(t.extends),t.mixins&&t.mixins.forEach(r)}return s||u?((0,i.kJ)(s)?s.forEach((t=>a[t]=null)):(0,i.l7)(a,s),r.set(t,a),a):(r.set(t,null),null)}function pe(t,e){return!(!t||!(0,i.F7)(e))&&(e=e.slice(2).replace(/Once$/,""),(0,i.RI)(t,e[0].toLowerCase()+e.slice(1))||(0,i.RI)(t,(0,i.rs)(e))||(0,i.RI)(t,e))}let ve=null,me=null;function ge(t){const e=ve;return ve=t,me=t&&t.type.__scopeId||null,e}function _e(t){me=t}function ye(){me=null}const be=t=>Ee;function Ee(t,e=ve,n){if(!e)return t;if(t._n)return t;const r=(...n)=>{r._d&&Wr(-1);const i=ge(e),o=t(...n);return ge(i),r._d&&Wr(1),o};return r._n=!0,r._c=!0,r._d=!0,r}function xe(t){const{type:e,vnode:n,proxy:r,withProxy:o,props:s,propsOptions:[a],slots:u,attrs:l,emit:c,render:h,renderCache:f,data:d,setupState:p,ctx:v,inheritAttrs:m}=t;let g,_;const y=ge(t);try{if(4&n.shapeFlag){const t=o||r;g=ci(h.call(t,t,f,s,p,d,v)),_=l}else{const t=e;0,g=ci(t.length>1?t(s,{attrs:l,slots:u,emit:c}):t(s,null)),_=e.props?l:Se(l)}}catch(E){kr.length=0,io(E,t,1),g=ri(Ur)}let b=g;if(_&&!1!==m){const t=Object.keys(_),{shapeFlag:e}=b;t.length&&7&e&&(a&&t.some(i.tR)&&(_=Re(_,a)),b=si(b,_))}return n.dirs&&(b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&(b.transition=n.transition),g=b,ge(y),g}function Te(t){let e;for(let n=0;n<t.length;n++){const r=t[n];if(!Kr(r))return;if(r.type!==Ur||"v-if"===r.children){if(e)return;e=r}}return e}const Se=t=>{let e;for(const n in t)("class"===n||"style"===n||(0,i.F7)(n))&&((e||(e={}))[n]=t[n]);return e},Re=(t,e)=>{const n={};for(const r in t)(0,i.tR)(r)&&r.slice(9)in e||(n[r]=t[r]);return n};function Ae(t,e,n){const{props:r,children:i,component:o}=t,{props:s,children:a,patchFlag:u}=e,l=o.emitsOptions;if(e.dirs||e.transition)return!0;if(!(n&&u>=0))return!(!i&&!a||a&&a.$stable)||r!==s&&(r?!s||Oe(r,s,l):!!s);if(1024&u)return!0;if(16&u)return r?Oe(r,s,l):!!s;if(8&u){const t=e.dynamicProps;for(let e=0;e<t.length;e++){const n=t[e];if(s[n]!==r[n]&&!pe(l,n))return!0}}return!1}function Oe(t,e,n){const r=Object.keys(e);if(r.length!==Object.keys(t).length)return!0;for(let i=0;i<r.length;i++){const o=r[i];if(e[o]!==t[o]&&!pe(n,o))return!0}return!1}function we({vnode:t,parent:e},n){while(e&&e.subTree===t)(t=e.vnode).el=n,e=e.parent}const Ie=t=>t.__isSuspense,Pe={name:"Suspense",__isSuspense:!0,process(t,e,n,r,i,o,s,a,u,l){null==t?Me(e,n,r,i,o,s,a,u,l):De(t,e,n,r,i,s,a,u,l)},hydrate:Fe,create:Le,normalize:Be},Ce=Pe;function Ne(t,e){const n=t.props&&t.props[e];(0,i.mf)(n)&&n()}function Me(t,e,n,r,i,o,s,a,u){const{p:l,o:{createElement:c}}=u,h=c("div"),f=t.suspense=Le(t,i,r,e,h,n,o,s,a,u);l(null,f.pendingBranch=t.ssContent,h,null,r,f,o,s),f.deps>0?(Ne(t,"onPending"),Ne(t,"onFallback"),l(null,t.ssFallback,e,n,r,null,o,s),ke(f,t.ssFallback)):f.resolve()}function De(t,e,n,r,i,o,s,a,{p:u,um:l,o:{createElement:c}}){const h=e.suspense=t.suspense;h.vnode=e,e.el=t.el;const f=e.ssContent,d=e.ssFallback,{activeBranch:p,pendingBranch:v,isInFallback:m,isHydrating:g}=h;if(v)h.pendingBranch=f,Zr(f,v)?(u(v,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0?h.resolve():m&&(u(p,d,n,r,i,null,o,s,a),ke(h,d))):(h.pendingId++,g?(h.isHydrating=!1,h.activeBranch=v):l(v,i,h),h.deps=0,h.effects.length=0,h.hiddenContainer=c("div"),m?(u(null,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0?h.resolve():(u(p,d,n,r,i,null,o,s,a),ke(h,d))):p&&Zr(f,p)?(u(p,f,n,r,i,h,o,s,a),h.resolve(!0)):(u(null,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0&&h.resolve()));else if(p&&Zr(f,p))u(p,f,n,r,i,h,o,s,a),ke(h,f);else if(Ne(e,"onPending"),h.pendingBranch=f,h.pendingId++,u(null,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0)h.resolve();else{const{timeout:t,pendingId:e}=h;t>0?setTimeout((()=>{h.pendingId===e&&h.fallback(d)}),t):0===t&&h.fallback(d)}}function Le(t,e,n,r,o,s,a,u,l,c,h=!1){const{p:f,m:d,um:p,n:v,o:{parentNode:m,remove:g}}=c,_=(0,i.He)(t.props&&t.props.timeout),y={vnode:t,parent:e,parentComponent:n,isSVG:a,container:r,hiddenContainer:o,anchor:s,deps:0,pendingId:0,timeout:"number"===typeof _?_:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:h,isUnmounted:!1,effects:[],resolve(t=!1){const{vnode:e,activeBranch:n,pendingBranch:r,pendingId:i,effects:o,parentComponent:s,container:a}=y;if(y.isHydrating)y.isHydrating=!1;else if(!t){const t=n&&r.transition&&"out-in"===r.transition.mode;t&&(n.transition.afterLeave=()=>{i===y.pendingId&&d(r,a,e,0)});let{anchor:e}=y;n&&(e=v(n),p(n,s,y,!0)),t||d(r,a,e,0)}ke(y,r),y.pendingBranch=null,y.isInFallback=!1;let u=y.parent,l=!1;while(u){if(u.pendingBranch){u.effects.push(...o),l=!0;break}u=u.parent}l||Oo(o),y.effects=[],Ne(e,"onResolve")},fallback(t){if(!y.pendingBranch)return;const{vnode:e,activeBranch:n,parentComponent:r,container:i,isSVG:o}=y;Ne(e,"onFallback");const s=v(n),a=()=>{y.isInFallback&&(f(null,t,i,s,r,null,o,u,l),ke(y,t))},c=t.transition&&"out-in"===t.transition.mode;c&&(n.transition.afterLeave=a),y.isInFallback=!0,p(n,r,null,!0),c||a()},move(t,e,n){y.activeBranch&&d(y.activeBranch,t,e,n),y.container=t},next(){return y.activeBranch&&v(y.activeBranch)},registerDep(t,e){const n=!!y.pendingBranch;n&&y.deps++;const r=t.vnode.el;t.asyncDep.catch((e=>{io(e,t,0)})).then((i=>{if(t.isUnmounted||y.isUnmounted||y.pendingId!==t.suspenseId)return;t.asyncResolved=!0;const{vnode:o}=t;Bi(t,i,!1),r&&(o.el=r);const s=!r&&t.subTree.el;e(t,o,m(r||t.subTree.el),r?null:v(t.subTree),y,a,l),s&&g(s),we(t,o.el),n&&0===--y.deps&&y.resolve()}))},unmount(t,e){y.isUnmounted=!0,y.activeBranch&&p(y.activeBranch,n,t,e),y.pendingBranch&&p(y.pendingBranch,n,t,e)}};return y}function Fe(t,e,n,r,i,o,s,a,u){const l=e.suspense=Le(e,r,n,t.parentNode,document.createElement("div"),null,i,o,s,a,!0),c=u(t,l.pendingBranch=e.ssContent,n,l,o,s);return 0===l.deps&&l.resolve(),c}function Be(t){const{shapeFlag:e,children:n}=t,r=32&e;t.ssContent=Ue(r?n.default:n),t.ssFallback=r?Ue(n.fallback):ri(Ur)}function Ue(t){let e;if((0,i.mf)(t)){const n=Yr&&t._c;n&&(t._d=!1,jr()),t=t(),n&&(t._d=!0,e=Xr,Hr())}if((0,i.kJ)(t)){const e=Te(t);0,t=e}return t=ci(t),e&&!t.dynamicChildren&&(t.dynamicChildren=e.filter((e=>e!==t))),t}function Ge(t,e){e&&e.pendingBranch?(0,i.kJ)(t)?e.effects.push(...t):e.effects.push(t):Oo(t)}function ke(t,e){t.activeBranch=e;const{vnode:n,parentComponent:r}=t,i=n.el=e.el;r&&r.subTree===n&&(r.vnode.el=i,we(r,i))}function Xe(t,e){if(Oi){let n=Oi.provides;const r=Oi.parent&&Oi.parent.provides;r===n&&(n=Oi.provides=Object.create(r)),n[t]=e}else 0}function je(t,e,n=!1){const r=Oi||ve;if(r){const o=null==r.parent?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides;if(o&&t in o)return o[t];if(arguments.length>1)return n&&(0,i.mf)(e)?e.call(r.proxy):e}else 0}function He(){const t={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return gn((()=>{t.isMounted=!0})),bn((()=>{t.isUnmounting=!0})),t}const Ve=[Function,Array],Ye={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Ve,onEnter:Ve,onAfterEnter:Ve,onEnterCancelled:Ve,onBeforeLeave:Ve,onLeave:Ve,onAfterLeave:Ve,onLeaveCancelled:Ve,onBeforeAppear:Ve,onAppear:Ve,onAfterAppear:Ve,onAppearCancelled:Ve},setup(t,{slots:e}){const n=wi(),r=He();let i;return()=>{const o=e.default&&Je(e.default(),!0);if(!o||!o.length)return;const s=kt(t),{mode:a}=s;const u=o[0];if(r.isLeaving)return qe(u);const l=Ke(u);if(!l)return qe(u);const c=$e(l,s,r,n);Ze(l,c);const h=n.subTree,f=h&&Ke(h);let d=!1;const{getTransitionKey:p}=l.type;if(p){const t=p();void 0===i?i=t:t!==i&&(i=t,d=!0)}if(f&&f.type!==Ur&&(!Zr(l,f)||d)){const t=$e(f,s,r,n);if(Ze(f,t),"out-in"===a)return r.isLeaving=!0,t.afterLeave=()=>{r.isLeaving=!1,n.update()},qe(u);"in-out"===a&&l.type!==Ur&&(t.delayLeave=(t,e,n)=>{const i=ze(r,f);i[String(f.key)]=f,t._leaveCb=()=>{e(),t._leaveCb=void 0,delete c.delayedLeave},c.delayedLeave=n})}return u}}},We=Ye;function ze(t,e){const{leavingVNodes:n}=t;let r=n.get(e.type);return r||(r=Object.create(null),n.set(e.type,r)),r}function $e(t,e,n,r){const{appear:i,mode:o,persisted:s=!1,onBeforeEnter:a,onEnter:u,onAfterEnter:l,onEnterCancelled:c,onBeforeLeave:h,onLeave:f,onAfterLeave:d,onLeaveCancelled:p,onBeforeAppear:v,onAppear:m,onAfterAppear:g,onAppearCancelled:_}=e,y=String(t.key),b=ze(n,t),E=(t,e)=>{t&&ro(t,r,9,e)},x={mode:o,persisted:s,beforeEnter(e){let r=a;if(!n.isMounted){if(!i)return;r=v||a}e._leaveCb&&e._leaveCb(!0);const o=b[y];o&&Zr(t,o)&&o.el._leaveCb&&o.el._leaveCb(),E(r,[e])},enter(t){let e=u,r=l,o=c;if(!n.isMounted){if(!i)return;e=m||u,r=g||l,o=_||c}let s=!1;const a=t._enterCb=e=>{s||(s=!0,E(e?o:r,[t]),x.delayedLeave&&x.delayedLeave(),t._enterCb=void 0)};e?(e(t,a),e.length<=1&&a()):a()},leave(e,r){const i=String(t.key);if(e._enterCb&&e._enterCb(!0),n.isUnmounting)return r();E(h,[e]);let o=!1;const s=e._leaveCb=n=>{o||(o=!0,r(),E(n?p:d,[e]),e._leaveCb=void 0,b[i]===t&&delete b[i])};b[i]=t,f?(f(e,s),f.length<=1&&s()):s()},clone(t){return $e(t,e,n,r)}};return x}function qe(t){if(rn(t))return t=si(t),t.children=null,t}function Ke(t){return rn(t)?t.children?t.children[0]:void 0:t}function Ze(t,e){6&t.shapeFlag&&t.component?Ze(t.component.subTree,e):128&t.shapeFlag?(t.ssContent.transition=e.clone(t.ssContent),t.ssFallback.transition=e.clone(t.ssFallback)):t.transition=e}function Je(t,e=!1){let n=[],r=0;for(let i=0;i<t.length;i++){const o=t[i];o.type===Fr?(128&o.patchFlag&&r++,n=n.concat(Je(o.children,e))):(e||o.type!==Ur)&&n.push(o)}if(r>1)for(let i=0;i<n.length;i++)n[i].patchFlag=-2;return n}function Qe(t){return(0,i.mf)(t)?{setup:t,name:t.name}:t}const tn=t=>!!t.type.__asyncLoader;function en(t){(0,i.mf)(t)&&(t={loader:t});const{loader:e,loadingComponent:n,errorComponent:r,delay:o=200,timeout:s,suspensible:a=!0,onError:u}=t;let l,c=null,h=0;const f=()=>(h++,c=null,d()),d=()=>{let t;return c||(t=c=e().catch((t=>{if(t=t instanceof Error?t:new Error(String(t)),u)return new Promise(((e,n)=>{const r=()=>e(f()),i=()=>n(t);u(t,r,i,h+1)}));throw t})).then((e=>t!==c&&c?c:(e&&(e.__esModule||"Module"===e[Symbol.toStringTag])&&(e=e.default),l=e,e))))};return Qe({name:"AsyncComponentWrapper",__asyncLoader:d,get __asyncResolved(){return l},setup(){const t=Oi;if(l)return()=>nn(l,t);const e=e=>{c=null,io(e,t,13,!r)};if(a&&t.suspense||Di)return d().then((e=>()=>nn(e,t))).catch((t=>(e(t),()=>r?ri(r,{error:t}):null)));const i=zt(!1),u=zt(),h=zt(!!o);return o&&setTimeout((()=>{h.value=!1}),o),null!=s&&setTimeout((()=>{if(!i.value&&!u.value){const t=new Error(`Async component timed out after ${s}ms.`);e(t),u.value=t}}),s),d().then((()=>{i.value=!0,t.parent&&rn(t.parent.vnode)&&xo(t.parent.update)})).catch((t=>{e(t),u.value=t})),()=>i.value&&l?nn(l,t):u.value&&r?ri(r,{error:u.value}):n&&!h.value?ri(n):void 0}})}function nn(t,{vnode:{ref:e,props:n,children:r}}){const i=ri(t,n,r);return i.ref=e,i}const rn=t=>t.type.__isKeepAlive,on={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(t,{slots:e}){const n=wi(),r=n.ctx;if(!r.renderer)return e.default;const o=new Map,s=new Set;let a=null;const u=n.suspense,{renderer:{p:l,m:c,um:h,o:{createElement:f}}}=r,d=f("div");function p(t){fn(t),h(t,n,u)}function v(t){o.forEach(((e,n)=>{const r=Wi(e.type);!r||t&&t(r)||m(n)}))}function m(t){const e=o.get(t);a&&e.type===a.type?a&&fn(a):p(e),o.delete(t),s.delete(t)}r.activate=(t,e,n,r,o)=>{const s=t.component;c(t,e,n,0,u),l(s.vnode,t,e,n,s,u,r,t.slotScopeIds,o),dr((()=>{s.isDeactivated=!1,s.a&&(0,i.ir)(s.a);const e=t.props&&t.props.onVnodeMounted;e&&pi(e,s.parent,t)}),u)},r.deactivate=t=>{const e=t.component;c(t,d,null,1,u),dr((()=>{e.da&&(0,i.ir)(e.da);const n=t.props&&t.props.onVnodeUnmounted;n&&pi(n,e.parent,t),e.isDeactivated=!0}),u)},Fo((()=>[t.include,t.exclude]),(([t,e])=>{t&&v((e=>an(t,e))),e&&v((t=>!an(e,t)))}),{flush:"post",deep:!0});let g=null;const _=()=>{null!=g&&o.set(g,dn(n.subTree))};return gn(_),yn(_),bn((()=>{o.forEach((t=>{const{subTree:e,suspense:r}=n,i=dn(e);if(t.type!==i.type)p(t);else{fn(i);const t=i.component.da;t&&dr(t,r)}}))})),()=>{if(g=null,!e.default)return null;const n=e.default(),r=n[0];if(n.length>1)return a=null,n;if(!Kr(r)||!(4&r.shapeFlag)&&!(128&r.shapeFlag))return a=null,r;let i=dn(r);const u=i.type,l=Wi(tn(i)?i.type.__asyncResolved||{}:u),{include:c,exclude:h,max:f}=t;if(c&&(!l||!an(c,l))||h&&l&&an(h,l))return a=i,r;const d=null==i.key?u:i.key,p=o.get(d);return i.el&&(i=si(i),128&r.shapeFlag&&(r.ssContent=i)),g=d,p?(i.el=p.el,i.component=p.component,i.transition&&Ze(i,i.transition),i.shapeFlag|=512,s.delete(d),s.add(d)):(s.add(d),f&&s.size>parseInt(f,10)&&m(s.values().next().value)),i.shapeFlag|=256,a=i,r}}},sn=on;function an(t,e){return(0,i.kJ)(t)?t.some((t=>an(t,e))):(0,i.HD)(t)?t.split(",").indexOf(e)>-1:!!t.test&&t.test(e)}function un(t,e){cn(t,"a",e)}function ln(t,e){cn(t,"da",e)}function cn(t,e,n=Oi){const r=t.__wdc||(t.__wdc=()=>{let e=n;while(e){if(e.isDeactivated)return;e=e.parent}return t()});if(pn(e,r,n),n){let t=n.parent;while(t&&t.parent)rn(t.parent.vnode)&&hn(r,e,n,t),t=t.parent}}function hn(t,e,n,r){const o=pn(e,t,r,!0);En((()=>{(0,i.Od)(r[e],o)}),n)}function fn(t){let e=t.shapeFlag;256&e&&(e-=256),512&e&&(e-=512),t.shapeFlag=e}function dn(t){return 128&t.shapeFlag?t.ssContent:t}function pn(t,e,n=Oi,r=!1){if(n){const i=n[t]||(n[t]=[]),o=e.__weh||(e.__weh=(...r)=>{if(n.isUnmounted)return;C(),Ii(n);const i=ro(e,n,t,r);return Pi(),M(),i});return r?i.unshift(o):i.push(o),o}}const vn=t=>(e,n=Oi)=>(!Di||"sp"===t)&&pn(t,e,n),mn=vn("bm"),gn=vn("m"),_n=vn("bu"),yn=vn("u"),bn=vn("bum"),En=vn("um"),xn=vn("sp"),Tn=vn("rtg"),Sn=vn("rtc");function Rn(t,e=Oi){pn("ec",t,e)}let An=!0;function On(t){const e=Cn(t),n=t.proxy,r=t.ctx;An=!1,e.beforeCreate&&In(e.beforeCreate,t,"bc");const{data:o,computed:s,methods:a,watch:u,provide:l,inject:c,created:h,beforeMount:f,mounted:d,beforeUpdate:p,updated:v,activated:m,deactivated:g,beforeDestroy:_,beforeUnmount:y,destroyed:b,unmounted:E,render:x,renderTracked:T,renderTriggered:S,errorCaptured:R,serverPrefetch:A,expose:O,inheritAttrs:w,components:I,directives:P,filters:C}=e,N=null;if(c&&wn(c,r,N,t.appContext.config.unwrapInjectedRef),a)for(const D in a){const t=a[D];(0,i.mf)(t)&&(r[D]=t.bind(n))}if(o){0;const e=o.call(n,n);0,(0,i.Kn)(e)&&(t.data=Nt(e))}if(An=!0,s)for(const D in s){const t=s[D],e=(0,i.mf)(t)?t.bind(n,n):(0,i.mf)(t.get)?t.get.bind(n,n):i.dG;0;const o=!(0,i.mf)(t)&&(0,i.mf)(t.set)?t.set.bind(n):i.dG,a=ae({get:e,set:o});Object.defineProperty(r,D,{enumerable:!0,configurable:!0,get:()=>a.value,set:t=>a.value=t})}if(u)for(const i in u)Pn(u[i],r,n,i);if(l){const t=(0,i.mf)(l)?l.call(n):l;Reflect.ownKeys(t).forEach((e=>{Xe(e,t[e])}))}function M(t,e){(0,i.kJ)(e)?e.forEach((e=>t(e.bind(n)))):e&&t(e.bind(n))}if(h&&In(h,t,"c"),M(mn,f),M(gn,d),M(_n,p),M(yn,v),M(un,m),M(ln,g),M(Rn,R),M(Sn,T),M(Tn,S),M(bn,y),M(En,E),M(xn,A),(0,i.kJ)(O))if(O.length){const e=t.exposed||(t.exposed={});O.forEach((t=>{Object.defineProperty(e,t,{get:()=>n[t],set:e=>n[t]=e})}))}else t.exposed||(t.exposed={});x&&t.render===i.dG&&(t.render=x),null!=w&&(t.inheritAttrs=w),I&&(t.components=I),P&&(t.directives=P)}function wn(t,e,n=i.dG,r=!1){(0,i.kJ)(t)&&(t=Fn(t));for(const o in t){const n=t[o];let s;s=(0,i.Kn)(n)?"default"in n?je(n.from||o,n.default,!0):je(n.from||o):je(n),Wt(s)&&r?Object.defineProperty(e,o,{enumerable:!0,configurable:!0,get:()=>s.value,set:t=>s.value=t}):e[o]=s}}function In(t,e,n){ro((0,i.kJ)(t)?t.map((t=>t.bind(e.proxy))):t.bind(e.proxy),e,n)}function Pn(t,e,n,r){const o=r.includes(".")?Go(n,r):()=>n[r];if((0,i.HD)(t)){const n=e[t];(0,i.mf)(n)&&Fo(o,n)}else if((0,i.mf)(t))Fo(o,t.bind(n));else if((0,i.Kn)(t))if((0,i.kJ)(t))t.forEach((t=>Pn(t,e,n,r)));else{const r=(0,i.mf)(t.handler)?t.handler.bind(n):e[t.handler];(0,i.mf)(r)&&Fo(o,r,t)}else 0}function Cn(t){const e=t.type,{mixins:n,extends:r}=e,{mixins:i,optionsCache:o,config:{optionMergeStrategies:s}}=t.appContext,a=o.get(e);let u;return a?u=a:i.length||n||r?(u={},i.length&&i.forEach((t=>Nn(u,t,s,!0))),Nn(u,e,s)):u=e,o.set(e,u),u}function Nn(t,e,n,r=!1){const{mixins:i,extends:o}=e;o&&Nn(t,o,n,!0),i&&i.forEach((e=>Nn(t,e,n,!0)));for(const s in e)if(r&&"expose"===s);else{const r=Mn[s]||n&&n[s];t[s]=r?r(t[s],e[s]):e[s]}return t}const Mn={data:Dn,props:Un,emits:Un,methods:Un,computed:Un,beforeCreate:Bn,created:Bn,beforeMount:Bn,mounted:Bn,beforeUpdate:Bn,updated:Bn,beforeDestroy:Bn,beforeUnmount:Bn,destroyed:Bn,unmounted:Bn,activated:Bn,deactivated:Bn,errorCaptured:Bn,serverPrefetch:Bn,components:Un,directives:Un,watch:Gn,provide:Dn,inject:Ln};function Dn(t,e){return e?t?function(){return(0,i.l7)((0,i.mf)(t)?t.call(this,this):t,(0,i.mf)(e)?e.call(this,this):e)}:e:t}function Ln(t,e){return Un(Fn(t),Fn(e))}function Fn(t){if((0,i.kJ)(t)){const e={};for(let n=0;n<t.length;n++)e[t[n]]=t[n];return e}return t}function Bn(t,e){return t?[...new Set([].concat(t,e))]:e}function Un(t,e){return t?(0,i.l7)((0,i.l7)(Object.create(null),t),e):e}function Gn(t,e){if(!t)return e;if(!e)return t;const n=(0,i.l7)(Object.create(null),t);for(const r in e)n[r]=Bn(t[r],e[r]);return n}function kn(t,e,n,r=!1){const o={},s={};(0,i.Nj)(s,Qr,1),t.propsDefaults=Object.create(null),jn(t,e,o,s);for(const i in t.propsOptions[0])i in o||(o[i]=void 0);n?t.props=r?o:Mt(o):t.type.props?t.props=o:t.props=s,t.attrs=s}function Xn(t,e,n,r){const{props:o,attrs:s,vnode:{patchFlag:a}}=t,u=kt(o),[l]=t.propsOptions;let c=!1;if(!(r||a>0)||16&a){let r;jn(t,e,o,s)&&(c=!0);for(const s in u)e&&((0,i.RI)(e,s)||(r=(0,i.rs)(s))!==s&&(0,i.RI)(e,r))||(l?!n||void 0===n[s]&&void 0===n[r]||(o[s]=Hn(l,u,s,void 0,t,!0)):delete o[s]);if(s!==u)for(const t in s)e&&(0,i.RI)(e,t)||(delete s[t],c=!0)}else if(8&a){const n=t.vnode.dynamicProps;for(let r=0;r<n.length;r++){let a=n[r];const h=e[a];if(l)if((0,i.RI)(s,a))h!==s[a]&&(s[a]=h,c=!0);else{const e=(0,i._A)(a);o[e]=Hn(l,u,e,h,t,!1)}else h!==s[a]&&(s[a]=h,c=!0)}}c&&B(t,"set","$attrs")}function jn(t,e,n,r){const[o,s]=t.propsOptions;let a,u=!1;if(e)for(let l in e){if((0,i.Gg)(l))continue;const c=e[l];let h;o&&(0,i.RI)(o,h=(0,i._A)(l))?s&&s.includes(h)?(a||(a={}))[h]=c:n[h]=c:pe(t.emitsOptions,l)||l in r&&c===r[l]||(r[l]=c,u=!0)}if(s){const e=kt(n),r=a||i.kT;for(let a=0;a<s.length;a++){const u=s[a];n[u]=Hn(o,e,u,r[u],t,!(0,i.RI)(r,u))}}return u}function Hn(t,e,n,r,o,s){const a=t[n];if(null!=a){const t=(0,i.RI)(a,"default");if(t&&void 0===r){const t=a.default;if(a.type!==Function&&(0,i.mf)(t)){const{propsDefaults:i}=o;n in i?r=i[n]:(Ii(o),r=i[n]=t.call(null,e),Pi())}else r=t}a[0]&&(s&&!t?r=!1:!a[1]||""!==r&&r!==(0,i.rs)(n)||(r=!0))}return r}function Vn(t,e,n=!1){const r=e.propsCache,o=r.get(t);if(o)return o;const s=t.props,a={},u=[];let l=!1;if(!(0,i.mf)(t)){const r=t=>{l=!0;const[n,r]=Vn(t,e,!0);(0,i.l7)(a,n),r&&u.push(...r)};!n&&e.mixins.length&&e.mixins.forEach(r),t.extends&&r(t.extends),t.mixins&&t.mixins.forEach(r)}if(!s&&!l)return r.set(t,i.Z6),i.Z6;if((0,i.kJ)(s))for(let h=0;h<s.length;h++){0;const t=(0,i._A)(s[h]);Yn(t)&&(a[t]=i.kT)}else if(s){0;for(const t in s){const e=(0,i._A)(t);if(Yn(e)){const n=s[t],r=a[e]=(0,i.kJ)(n)||(0,i.mf)(n)?{type:n}:n;if(r){const t=$n(Boolean,r.type),n=$n(String,r.type);r[0]=t>-1,r[1]=n<0||t<n,(t>-1||(0,i.RI)(r,"default"))&&u.push(e)}}}}const c=[a,u];return r.set(t,c),c}function Yn(t){return"$"!==t[0]}function Wn(t){const e=t&&t.toString().match(/^\s*function (\w+)/);return e?e[1]:null===t?"null":""}function zn(t,e){return Wn(t)===Wn(e)}function $n(t,e){return(0,i.kJ)(e)?e.findIndex((e=>zn(e,t))):(0,i.mf)(e)&&zn(e,t)?0:-1}const qn=t=>"_"===t[0]||"$stable"===t,Kn=t=>(0,i.kJ)(t)?t.map(ci):[ci(t)],Zn=(t,e,n)=>{const r=Ee(((...t)=>Kn(e(...t))),n);return r._c=!1,r},Jn=(t,e,n)=>{const r=t._ctx;for(const o in t){if(qn(o))continue;const n=t[o];if((0,i.mf)(n))e[o]=Zn(o,n,r);else if(null!=n){0;const t=Kn(n);e[o]=()=>t}}},Qn=(t,e)=>{const n=Kn(e);t.slots.default=()=>n},tr=(t,e)=>{if(32&t.vnode.shapeFlag){const n=e._;n?(t.slots=kt(e),(0,i.Nj)(e,"_",n)):Jn(e,t.slots={})}else t.slots={},e&&Qn(t,e);(0,i.Nj)(t.slots,Qr,1)},er=(t,e,n)=>{const{vnode:r,slots:o}=t;let s=!0,a=i.kT;if(32&r.shapeFlag){const t=e._;t?n&&1===t?s=!1:((0,i.l7)(o,e),n||1!==t||delete o._):(s=!e.$stable,Jn(e,o)),a=e}else e&&(Qn(t,e),a={default:1});if(s)for(const i in o)qn(i)||i in a||delete o[i]};function nr(t,e){const n=ve;if(null===n)return t;const r=n.proxy,o=t.dirs||(t.dirs=[]);for(let s=0;s<e.length;s++){let[t,n,a,u=i.kT]=e[s];(0,i.mf)(t)&&(t={mounted:t,updated:t}),t.deep&&ko(n),o.push({dir:t,instance:r,value:n,oldValue:void 0,arg:a,modifiers:u})}return t}function rr(t,e,n,r){const i=t.dirs,o=e&&e.dirs;for(let s=0;s<i.length;s++){const a=i[s];o&&(a.oldValue=o[s].value);let u=a.dir[r];u&&(C(),ro(u,n,8,[t.el,a,t,e]),M())}}function ir(){return{app:null,config:{isNativeTag:i.NO,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let or=0;function sr(t,e){return function(n,r=null){null==r||(0,i.Kn)(r)||(r=null);const o=ir(),s=new Set;let a=!1;const u=o.app={_uid:or++,_component:n,_props:r,_container:null,_context:o,_instance:null,version:rs,get config(){return o.config},set config(t){0},use(t,...e){return s.has(t)||(t&&(0,i.mf)(t.install)?(s.add(t),t.install(u,...e)):(0,i.mf)(t)&&(s.add(t),t(u,...e))),u},mixin(t){return o.mixins.includes(t)||o.mixins.push(t),u},component(t,e){return e?(o.components[t]=e,u):o.components[t]},directive(t,e){return e?(o.directives[t]=e,u):o.directives[t]},mount(i,s,l){if(!a){const c=ri(n,r);return c.appContext=o,s&&e?e(c,i):t(c,i,l),a=!0,u._container=i,i.__vue_app__=u,Hi(c.component)||c.component.proxy}},unmount(){a&&(t(null,u._container),delete u._container.__vue_app__)},provide(t,e){return o.provides[t]=e,u}};return u}}function ar(t,e,n,r,o=!1){if((0,i.kJ)(t))return void t.forEach(((t,s)=>ar(t,e&&((0,i.kJ)(e)?e[s]:e),n,r,o)));if(tn(r)&&!o)return;const s=4&r.shapeFlag?Hi(r.component)||r.component.proxy:r.el,a=o?null:s,{i:u,r:l}=t;const c=e&&e.r,h=u.refs===i.kT?u.refs={}:u.refs,f=u.setupState;if(null!=c&&c!==l&&((0,i.HD)(c)?(h[c]=null,(0,i.RI)(f,c)&&(f[c]=null)):Wt(c)&&(c.value=null)),(0,i.mf)(l))no(l,u,12,[a,h]);else{const e=(0,i.HD)(l),r=Wt(l);if(e||r){const r=()=>{if(t.f){const n=e?h[l]:l.value;o?(0,i.kJ)(n)&&(0,i.Od)(n,s):(0,i.kJ)(n)?n.includes(s)||n.push(s):e?h[l]=[s]:(l.value=[s],t.k&&(h[t.k]=l.value))}else e?(h[l]=a,(0,i.RI)(f,l)&&(f[l]=a)):Wt(l)&&(l.value=a,t.k&&(h[t.k]=a))};a?(r.id=-1,dr(r,n)):r()}else 0}}let ur=!1;const lr=t=>/svg/.test(t.namespaceURI)&&"foreignObject"!==t.tagName,cr=t=>8===t.nodeType;function hr(t){const{mt:e,p:n,o:{patchProp:r,nextSibling:o,parentNode:s,remove:a,insert:u,createComment:l}}=t,c=(t,e)=>{if(!e.hasChildNodes())return n(null,t,e),void Io();ur=!1,h(e.firstChild,t,null,null,null),Io(),ur&&console.error("Hydration completed but contains mismatches.")},h=(n,r,i,a,u,l=!1)=>{const c=cr(n)&&"["===n.data,g=()=>v(n,r,i,a,u,c),{type:_,ref:y,shapeFlag:b}=r,E=n.nodeType;r.el=n;let x=null;switch(_){case Br:3!==E?x=g():(n.data!==r.children&&(ur=!0,n.data=r.children),x=o(n));break;case Ur:x=8!==E||c?g():o(n);break;case Gr:if(1===E){x=n;const t=!r.children.length;for(let e=0;e<r.staticCount;e++)t&&(r.children+=x.outerHTML),e===r.staticCount-1&&(r.anchor=x),x=o(x);return x}x=g();break;case Fr:x=c?p(n,r,i,a,u,l):g();break;default:if(1&b)x=1!==E||r.type.toLowerCase()!==n.tagName.toLowerCase()?g():f(n,r,i,a,u,l);else if(6&b){r.slotScopeIds=u;const t=s(n);if(e(r,t,null,i,a,lr(t),l),x=c?m(n):o(n),tn(r)){let e;c?(e=ri(Fr),e.anchor=x?x.previousSibling:t.lastChild):e=3===n.nodeType?ai(""):ri("div"),e.el=n,r.component.subTree=e}}else 64&b?x=8!==E?g():r.type.hydrate(n,r,i,a,u,l,t,d):128&b&&(x=r.type.hydrate(n,r,i,a,lr(s(n)),u,l,t,h))}return null!=y&&ar(y,null,a,r),x},f=(t,e,n,o,s,u)=>{u=u||!!e.dynamicChildren;const{type:l,props:c,patchFlag:h,shapeFlag:f,dirs:p}=e,v="input"===l&&p||"option"===l;if(v||-1!==h){if(p&&rr(e,null,n,"created"),c)if(v||!u||48&h)for(const e in c)(v&&e.endsWith("value")||(0,i.F7)(e)&&!(0,i.Gg)(e))&&r(t,e,null,c[e],!1,void 0,n);else c.onClick&&r(t,"onClick",null,c.onClick,!1,void 0,n);let l;if((l=c&&c.onVnodeBeforeMount)&&pi(l,n,e),p&&rr(e,null,n,"beforeMount"),((l=c&&c.onVnodeMounted)||p)&&Ge((()=>{l&&pi(l,n,e),p&&rr(e,null,n,"mounted")}),o),16&f&&(!c||!c.innerHTML&&!c.textContent)){let r=d(t.firstChild,e,t,n,o,s,u);while(r){ur=!0;const t=r;r=r.nextSibling,a(t)}}else 8&f&&t.textContent!==e.children&&(ur=!0,t.textContent=e.children)}return t.nextSibling},d=(t,e,r,i,o,s,a)=>{a=a||!!e.dynamicChildren;const u=e.children,l=u.length;for(let c=0;c<l;c++){const e=a?u[c]:u[c]=ci(u[c]);if(t)t=h(t,e,i,o,s,a);else{if(e.type===Br&&!e.children)continue;ur=!0,n(null,e,r,null,i,o,lr(r),s)}}return t},p=(t,e,n,r,i,a)=>{const{slotScopeIds:c}=e;c&&(i=i?i.concat(c):c);const h=s(t),f=d(o(t),e,h,n,r,i,a);return f&&cr(f)&&"]"===f.data?o(e.anchor=f):(ur=!0,u(e.anchor=l("]"),h,f),f)},v=(t,e,r,i,u,l)=>{if(ur=!0,e.el=null,l){const e=m(t);while(1){const n=o(t);if(!n||n===e)break;a(n)}}const c=o(t),h=s(t);return a(t),n(null,e,h,c,r,i,lr(h),u),c},m=t=>{let e=0;while(t)if(t=o(t),t&&cr(t)&&("["===t.data&&e++,"]"===t.data)){if(0===e)return o(t);e--}return t};return[c,h]}function fr(){}const dr=Ge;function pr(t){return mr(t)}function vr(t){return mr(t,hr)}function mr(t,e){fr();const n=(0,i.E9)();n.__VUE__=!0;const{insert:r,remove:o,patchProp:s,createElement:a,createText:u,createComment:l,setText:c,setElementText:h,parentNode:f,nextSibling:d,setScopeId:p=i.dG,cloneNode:v,insertStaticContent:m}=t,g=(t,e,n,r=null,i=null,o=null,s=!1,a=null,u=!!e.dynamicChildren)=>{if(t===e)return;t&&!Zr(t,e)&&(r=$(t),H(t,i,o,!0),t=null),-2===e.patchFlag&&(u=!1,e.dynamicChildren=null);const{type:l,ref:c,shapeFlag:h}=e;switch(l){case Br:_(t,e,n,r);break;case Ur:y(t,e,n,r);break;case Gr:null==t&&b(e,n,r,s);break;case Fr:N(t,e,n,r,i,o,s,a,u);break;default:1&h?T(t,e,n,r,i,o,s,a,u):6&h?D(t,e,n,r,i,o,s,a,u):(64&h||128&h)&&l.process(t,e,n,r,i,o,s,a,u,K)}null!=c&&i&&ar(c,t&&t.ref,o,e||t,!e)},_=(t,e,n,i)=>{if(null==t)r(e.el=u(e.children),n,i);else{const n=e.el=t.el;e.children!==t.children&&c(n,e.children)}},y=(t,e,n,i)=>{null==t?r(e.el=l(e.children||""),n,i):e.el=t.el},b=(t,e,n,r)=>{[t.el,t.anchor]=m(t.children,e,n,r)},E=({el:t,anchor:e},n,i)=>{let o;while(t&&t!==e)o=d(t),r(t,n,i),t=o;r(e,n,i)},x=({el:t,anchor:e})=>{let n;while(t&&t!==e)n=d(t),o(t),t=n;o(e)},T=(t,e,n,r,i,o,s,a,u)=>{s=s||"svg"===e.type,null==t?S(e,n,r,i,o,s,a,u):w(t,e,i,o,s,a,u)},S=(t,e,n,o,u,l,c,f)=>{let d,p;const{type:m,props:g,shapeFlag:_,transition:y,patchFlag:b,dirs:E}=t;if(t.el&&void 0!==v&&-1===b)d=t.el=v(t.el);else{if(d=t.el=a(t.type,l,g&&g.is,g),8&_?h(d,t.children):16&_&&O(t.children,d,null,o,u,l&&"foreignObject"!==m,c,f),E&&rr(t,null,o,"created"),g){for(const e in g)"value"===e||(0,i.Gg)(e)||s(d,e,null,g[e],l,t.children,o,u,z);"value"in g&&s(d,"value",null,g.value),(p=g.onVnodeBeforeMount)&&pi(p,o,t)}A(d,t,t.scopeId,c,o)}E&&rr(t,null,o,"beforeMount");const x=(!u||u&&!u.pendingBranch)&&y&&!y.persisted;x&&y.beforeEnter(d),r(d,e,n),((p=g&&g.onVnodeMounted)||x||E)&&dr((()=>{p&&pi(p,o,t),x&&y.enter(d),E&&rr(t,null,o,"mounted")}),u)},A=(t,e,n,r,i)=>{if(n&&p(t,n),r)for(let o=0;o<r.length;o++)p(t,r[o]);if(i){let n=i.subTree;if(e===n){const e=i.vnode;A(t,e,e.scopeId,e.slotScopeIds,i.parent)}}},O=(t,e,n,r,i,o,s,a,u=0)=>{for(let l=u;l<t.length;l++){const u=t[l]=a?hi(t[l]):ci(t[l]);g(null,u,e,n,r,i,o,s,a)}},w=(t,e,n,r,o,a,u)=>{const l=e.el=t.el;let{patchFlag:c,dynamicChildren:f,dirs:d}=e;c|=16&t.patchFlag;const p=t.props||i.kT,v=e.props||i.kT;let m;n&&gr(n,!1),(m=v.onVnodeBeforeUpdate)&&pi(m,n,e,t),d&&rr(e,t,n,"beforeUpdate"),n&&gr(n,!0);const g=o&&"foreignObject"!==e.type;if(f?I(t.dynamicChildren,f,l,n,r,g,a):u||G(t,e,l,null,n,r,g,a,!1),c>0){if(16&c)P(l,e,p,v,n,r,o);else if(2&c&&p.class!==v.class&&s(l,"class",null,v.class,o),4&c&&s(l,"style",p.style,v.style,o),8&c){const i=e.dynamicProps;for(let e=0;e<i.length;e++){const a=i[e],u=p[a],c=v[a];c===u&&"value"!==a||s(l,a,u,c,o,t.children,n,r,z)}}1&c&&t.children!==e.children&&h(l,e.children)}else u||null!=f||P(l,e,p,v,n,r,o);((m=v.onVnodeUpdated)||d)&&dr((()=>{m&&pi(m,n,e,t),d&&rr(e,t,n,"updated")}),r)},I=(t,e,n,r,i,o,s)=>{for(let a=0;a<e.length;a++){const u=t[a],l=e[a],c=u.el&&(u.type===Fr||!Zr(u,l)||70&u.shapeFlag)?f(u.el):n;g(u,l,c,null,r,i,o,s,!0)}},P=(t,e,n,r,o,a,u)=>{if(n!==r){for(const l in r){if((0,i.Gg)(l))continue;const c=r[l],h=n[l];c!==h&&"value"!==l&&s(t,l,h,c,u,e.children,o,a,z)}if(n!==i.kT)for(const l in n)(0,i.Gg)(l)||l in r||s(t,l,n[l],null,u,e.children,o,a,z);"value"in r&&s(t,"value",n.value,r.value)}},N=(t,e,n,i,o,s,a,l,c)=>{const h=e.el=t?t.el:u(""),f=e.anchor=t?t.anchor:u("");let{patchFlag:d,dynamicChildren:p,slotScopeIds:v}=e;v&&(l=l?l.concat(v):v),null==t?(r(h,n,i),r(f,n,i),O(e.children,n,f,o,s,a,l,c)):d>0&&64&d&&p&&t.dynamicChildren?(I(t.dynamicChildren,p,n,o,s,a,l),(null!=e.key||o&&e===o.subTree)&&_r(t,e,!0)):G(t,e,n,f,o,s,a,l,c)},D=(t,e,n,r,i,o,s,a,u)=>{e.slotScopeIds=a,null==t?512&e.shapeFlag?i.ctx.activate(e,n,r,s,u):L(e,n,r,i,o,s,u):F(t,e,u)},L=(t,e,n,r,i,o,s)=>{const a=t.component=Ai(t,r,i);if(rn(t)&&(a.ctx.renderer=K),Li(a),a.asyncDep){if(i&&i.registerDep(a,B),!t.el){const t=a.subTree=ri(Ur);y(null,t,e,n)}}else B(a,t,e,n,i,o,s)},F=(t,e,n)=>{const r=e.component=t.component;if(Ae(t,e,n)){if(r.asyncDep&&!r.asyncResolved)return void U(r,e,n);r.next=e,So(r.update),r.update()}else e.component=t.component,e.el=t.el,r.vnode=e},B=(t,e,n,r,o,s,a)=>{const u=()=>{if(t.isMounted){let e,{next:n,bu:r,u:u,parent:l,vnode:c}=t,h=n;0,gr(t,!1),n?(n.el=c.el,U(t,n,a)):n=c,r&&(0,i.ir)(r),(e=n.props&&n.props.onVnodeBeforeUpdate)&&pi(e,l,n,c),gr(t,!0);const d=xe(t);0;const p=t.subTree;t.subTree=d,g(p,d,f(p.el),$(p),t,o,s),n.el=d.el,null===h&&we(t,d.el),u&&dr(u,o),(e=n.props&&n.props.onVnodeUpdated)&&dr((()=>pi(e,l,n,c)),o)}else{let a;const{el:u,props:l}=e,{bm:c,m:h,parent:f}=t,d=tn(e);if(gr(t,!1),c&&(0,i.ir)(c),!d&&(a=l&&l.onVnodeBeforeMount)&&pi(a,f,e),gr(t,!0),u&&J){const n=()=>{t.subTree=xe(t),J(u,t.subTree,t,o,null)};d?e.type.__asyncLoader().then((()=>!t.isUnmounted&&n())):n()}else{0;const i=t.subTree=xe(t);0,g(null,i,n,r,t,o,s),e.el=i.el}if(h&&dr(h,o),!d&&(a=l&&l.onVnodeMounted)){const t=e;dr((()=>pi(a,f,t)),o)}256&e.shapeFlag&&t.a&&dr(t.a,o),t.isMounted=!0,e=n=r=null}},l=t.effect=new R(u,(()=>xo(t.update)),t.scope),c=t.update=l.run.bind(l);c.id=t.uid,gr(t,!0),c()},U=(t,e,n)=>{e.component=t;const r=t.vnode.props;t.vnode=e,t.next=null,Xn(t,e.props,r,n),er(t,e.children,n),C(),wo(void 0,t.update),M()},G=(t,e,n,r,i,o,s,a,u=!1)=>{const l=t&&t.children,c=t?t.shapeFlag:0,f=e.children,{patchFlag:d,shapeFlag:p}=e;if(d>0){if(128&d)return void X(l,f,n,r,i,o,s,a,u);if(256&d)return void k(l,f,n,r,i,o,s,a,u)}8&p?(16&c&&z(l,i,o),f!==l&&h(n,f)):16&c?16&p?X(l,f,n,r,i,o,s,a,u):z(l,i,o,!0):(8&c&&h(n,""),16&p&&O(f,n,r,i,o,s,a,u))},k=(t,e,n,r,o,s,a,u,l)=>{t=t||i.Z6,e=e||i.Z6;const c=t.length,h=e.length,f=Math.min(c,h);let d;for(d=0;d<f;d++){const r=e[d]=l?hi(e[d]):ci(e[d]);g(t[d],r,n,null,o,s,a,u,l)}c>h?z(t,o,s,!0,!1,f):O(e,n,r,o,s,a,u,l,f)},X=(t,e,n,r,o,s,a,u,l)=>{let c=0;const h=e.length;let f=t.length-1,d=h-1;while(c<=f&&c<=d){const r=t[c],i=e[c]=l?hi(e[c]):ci(e[c]);if(!Zr(r,i))break;g(r,i,n,null,o,s,a,u,l),c++}while(c<=f&&c<=d){const r=t[f],i=e[d]=l?hi(e[d]):ci(e[d]);if(!Zr(r,i))break;g(r,i,n,null,o,s,a,u,l),f--,d--}if(c>f){if(c<=d){const t=d+1,i=t<h?e[t].el:r;while(c<=d)g(null,e[c]=l?hi(e[c]):ci(e[c]),n,i,o,s,a,u,l),c++}}else if(c>d)while(c<=f)H(t[c],o,s,!0),c++;else{const p=c,v=c,m=new Map;for(c=v;c<=d;c++){const t=e[c]=l?hi(e[c]):ci(e[c]);null!=t.key&&m.set(t.key,c)}let _,y=0;const b=d-v+1;let E=!1,x=0;const T=new Array(b);for(c=0;c<b;c++)T[c]=0;for(c=p;c<=f;c++){const r=t[c];if(y>=b){H(r,o,s,!0);continue}let i;if(null!=r.key)i=m.get(r.key);else for(_=v;_<=d;_++)if(0===T[_-v]&&Zr(r,e[_])){i=_;break}void 0===i?H(r,o,s,!0):(T[i-v]=c+1,i>=x?x=i:E=!0,g(r,e[i],n,null,o,s,a,u,l),y++)}const S=E?yr(T):i.Z6;for(_=S.length-1,c=b-1;c>=0;c--){const t=v+c,i=e[t],f=t+1<h?e[t+1].el:r;0===T[c]?g(null,i,n,f,o,s,a,u,l):E&&(_<0||c!==S[_]?j(i,n,f,2):_--)}}},j=(t,e,n,i,o=null)=>{const{el:s,type:a,transition:u,children:l,shapeFlag:c}=t;if(6&c)return void j(t.component.subTree,e,n,i);if(128&c)return void t.suspense.move(e,n,i);if(64&c)return void a.move(t,e,n,K);if(a===Fr){r(s,e,n);for(let t=0;t<l.length;t++)j(l[t],e,n,i);return void r(t.anchor,e,n)}if(a===Gr)return void E(t,e,n);const h=2!==i&&1&c&&u;if(h)if(0===i)u.beforeEnter(s),r(s,e,n),dr((()=>u.enter(s)),o);else{const{leave:t,delayLeave:i,afterLeave:o}=u,a=()=>r(s,e,n),l=()=>{t(s,(()=>{a(),o&&o()}))};i?i(s,a,l):l()}else r(s,e,n)},H=(t,e,n,r=!1,i=!1)=>{const{type:o,props:s,ref:a,children:u,dynamicChildren:l,shapeFlag:c,patchFlag:h,dirs:f}=t;if(null!=a&&ar(a,null,n,t,!0),256&c)return void e.ctx.deactivate(t);const d=1&c&&f,p=!tn(t);let v;if(p&&(v=s&&s.onVnodeBeforeUnmount)&&pi(v,e,t),6&c)W(t.component,n,r);else{if(128&c)return void t.suspense.unmount(n,r);d&&rr(t,null,e,"beforeUnmount"),64&c?t.type.remove(t,e,n,i,K,r):l&&(o!==Fr||h>0&&64&h)?z(l,e,n,!1,!0):(o===Fr&&384&h||!i&&16&c)&&z(u,e,n),r&&V(t)}(p&&(v=s&&s.onVnodeUnmounted)||d)&&dr((()=>{v&&pi(v,e,t),d&&rr(t,null,e,"unmounted")}),n)},V=t=>{const{type:e,el:n,anchor:r,transition:i}=t;if(e===Fr)return void Y(n,r);if(e===Gr)return void x(t);const s=()=>{o(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(1&t.shapeFlag&&i&&!i.persisted){const{leave:e,delayLeave:r}=i,o=()=>e(n,s);r?r(t.el,s,o):o()}else s()},Y=(t,e)=>{let n;while(t!==e)n=d(t),o(t),t=n;o(e)},W=(t,e,n)=>{const{bum:r,scope:o,update:s,subTree:a,um:u}=t;r&&(0,i.ir)(r),o.stop(),s&&(s.active=!1,H(a,t,e,n)),u&&dr(u,e),dr((()=>{t.isUnmounted=!0}),e),e&&e.pendingBranch&&!e.isUnmounted&&t.asyncDep&&!t.asyncResolved&&t.suspenseId===e.pendingId&&(e.deps--,0===e.deps&&e.resolve())},z=(t,e,n,r=!1,i=!1,o=0)=>{for(let s=o;s<t.length;s++)H(t[s],e,n,r,i)},$=t=>6&t.shapeFlag?$(t.component.subTree):128&t.shapeFlag?t.suspense.next():d(t.anchor||t.el),q=(t,e,n)=>{null==t?e._vnode&&H(e._vnode,null,null,!0):g(e._vnode||null,t,e,null,null,null,n),Io(),e._vnode=t},K={p:g,um:H,m:j,r:V,mt:L,mc:O,pc:G,pbc:I,n:$,o:t};let Z,J;return e&&([Z,J]=e(K)),{render:q,hydrate:Z,createApp:sr(q,Z)}}function gr({effect:t,update:e},n){t.allowRecurse=e.allowRecurse=n}function _r(t,e,n=!1){const r=t.children,o=e.children;if((0,i.kJ)(r)&&(0,i.kJ)(o))for(let i=0;i<r.length;i++){const t=r[i];let e=o[i];1&e.shapeFlag&&!e.dynamicChildren&&((e.patchFlag<=0||32===e.patchFlag)&&(e=o[i]=hi(o[i]),e.el=t.el),n||_r(t,e))}}function yr(t){const e=t.slice(),n=[0];let r,i,o,s,a;const u=t.length;for(r=0;r<u;r++){const u=t[r];if(0!==u){if(i=n[n.length-1],t[i]<u){e[r]=i,n.push(r);continue}o=0,s=n.length-1;while(o<s)a=o+s>>1,t[n[a]]<u?o=a+1:s=a;u<t[n[o]]&&(o>0&&(e[r]=n[o-1]),n[o]=r)}}o=n.length,s=n[o-1];while(o-- >0)n[o]=s,s=e[s];return n}const br=t=>t.__isTeleport,Er=t=>t&&(t.disabled||""===t.disabled),xr=t=>"undefined"!==typeof SVGElement&&t instanceof SVGElement,Tr=(t,e)=>{const n=t&&t.to;if((0,i.HD)(n)){if(e){const t=e(n);return t}return null}return n},Sr={__isTeleport:!0,process(t,e,n,r,i,o,s,a,u,l){const{mc:c,pc:h,pbc:f,o:{insert:d,querySelector:p,createText:v,createComment:m}}=l,g=Er(e.props);let{shapeFlag:_,children:y,dynamicChildren:b}=e;if(null==t){const t=e.el=v(""),l=e.anchor=v("");d(t,n,r),d(l,n,r);const h=e.target=Tr(e.props,p),f=e.targetAnchor=v("");h&&(d(f,h),s=s||xr(h));const m=(t,e)=>{16&_&&c(y,t,e,i,o,s,a,u)};g?m(n,l):h&&m(h,f)}else{e.el=t.el;const r=e.anchor=t.anchor,c=e.target=t.target,d=e.targetAnchor=t.targetAnchor,v=Er(t.props),m=v?n:c,_=v?r:d;if(s=s||xr(c),b?(f(t.dynamicChildren,b,m,i,o,s,a),_r(t,e,!0)):u||h(t,e,m,_,i,o,s,a,!1),g)v||Rr(e,n,r,l,1);else if((e.props&&e.props.to)!==(t.props&&t.props.to)){const t=e.target=Tr(e.props,p);t&&Rr(e,t,null,l,0)}else v&&Rr(e,c,d,l,1)}},remove(t,e,n,r,{um:i,o:{remove:o}},s){const{shapeFlag:a,children:u,anchor:l,targetAnchor:c,target:h,props:f}=t;if(h&&o(c),(s||!Er(f))&&(o(l),16&a))for(let d=0;d<u.length;d++){const t=u[d];i(t,e,n,!0,!!t.dynamicChildren)}},move:Rr,hydrate:Ar};function Rr(t,e,n,{o:{insert:r},m:i},o=2){0===o&&r(t.targetAnchor,e,n);const{el:s,anchor:a,shapeFlag:u,children:l,props:c}=t,h=2===o;if(h&&r(s,e,n),(!h||Er(c))&&16&u)for(let f=0;f<l.length;f++)i(l[f],e,n,2);h&&r(a,e,n)}function Ar(t,e,n,r,i,o,{o:{nextSibling:s,parentNode:a,querySelector:u}},l){const c=e.target=Tr(e.props,u);if(c){const u=c._lpa||c.firstChild;16&e.shapeFlag&&(Er(e.props)?(e.anchor=l(s(t),e,a(t),n,r,i,o),e.targetAnchor=u):(e.anchor=s(t),e.targetAnchor=l(u,e,c,n,r,i,o)),c._lpa=e.targetAnchor&&s(e.targetAnchor))}return e.anchor&&s(e.anchor)}const Or=Sr,wr="components",Ir="directives";function Pr(t,e){return Dr(wr,t,!0,e)||t}const Cr=Symbol();function Nr(t){return(0,i.HD)(t)?Dr(wr,t,!1)||t:t||Cr}function Mr(t){return Dr(Ir,t)}function Dr(t,e,n=!0,r=!1){const o=ve||Oi;if(o){const n=o.type;if(t===wr){const t=Wi(n);if(t&&(t===e||t===(0,i._A)(e)||t===(0,i.kC)((0,i._A)(e))))return n}const s=Lr(o[t]||n[t],e)||Lr(o.appContext[t],e);return!s&&r?n:s}}function Lr(t,e){return t&&(t[e]||t[(0,i._A)(e)]||t[(0,i.kC)((0,i._A)(e))])}const Fr=Symbol(void 0),Br=Symbol(void 0),Ur=Symbol(void 0),Gr=Symbol(void 0),kr=[];let Xr=null;function jr(t=!1){kr.push(Xr=t?null:[])}function Hr(){kr.pop(),Xr=kr[kr.length-1]||null}let Vr,Yr=1;function Wr(t){Yr+=t}function zr(t){return t.dynamicChildren=Yr>0?Xr||i.Z6:null,Hr(),Yr>0&&Xr&&Xr.push(t),t}function $r(t,e,n,r,i,o){return zr(ni(t,e,n,r,i,o,!0))}function qr(t,e,n,r,i){return zr(ri(t,e,n,r,i,!0))}function Kr(t){return!!t&&!0===t.__v_isVNode}function Zr(t,e){return t.type===e.type&&t.key===e.key}function Jr(t){Vr=t}const Qr="__vInternal",ti=({key:t})=>null!=t?t:null,ei=({ref:t,ref_key:e,ref_for:n})=>null!=t?(0,i.HD)(t)||Wt(t)||(0,i.mf)(t)?{i:ve,r:t,k:e,f:!!n}:t:null;function ni(t,e=null,n=null,r=0,o=null,s=(t===Fr?0:1),a=!1,u=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&ti(e),ref:e&&ei(e),scopeId:me,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:r,dynamicProps:o,dynamicChildren:null,appContext:null};return u?(fi(l,n),128&s&&t.normalize(l)):n&&(l.shapeFlag|=(0,i.HD)(n)?8:16),Yr>0&&!a&&Xr&&(l.patchFlag>0||6&s)&&32!==l.patchFlag&&Xr.push(l),l}const ri=ii;function ii(t,e=null,n=null,r=0,o=null,s=!1){if(t&&t!==Cr||(t=Ur),Kr(t)){const r=si(t,e,!0);return n&&fi(r,n),r}if($i(t)&&(t=t.__vccOpts),e){e=oi(e);let{class:t,style:n}=e;t&&!(0,i.HD)(t)&&(e.class=(0,i.C_)(t)),(0,i.Kn)(n)&&(Gt(n)&&!(0,i.kJ)(n)&&(n=(0,i.l7)({},n)),e.style=(0,i.j5)(n))}const a=(0,i.HD)(t)?1:Ie(t)?128:br(t)?64:(0,i.Kn)(t)?4:(0,i.mf)(t)?2:0;return ni(t,e,n,r,o,a,s,!0)}function oi(t){return t?Gt(t)||Qr in t?(0,i.l7)({},t):t:null}function si(t,e,n=!1){const{props:r,ref:o,patchFlag:s,children:a}=t,u=e?di(r||{},e):r,l={__v_isVNode:!0,__v_skip:!0,type:t.type,props:u,key:u&&ti(u),ref:e&&e.ref?n&&o?(0,i.kJ)(o)?o.concat(ei(e)):[o,ei(e)]:ei(e):o,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:a,target:t.target,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==Fr?-1===s?16:16|s:s,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:t.transition,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&si(t.ssContent),ssFallback:t.ssFallback&&si(t.ssFallback),el:t.el,anchor:t.anchor};return l}function ai(t=" ",e=0){return ri(Br,null,t,e)}function ui(t,e){const n=ri(Gr,null,t);return n.staticCount=e,n}function li(t="",e=!1){return e?(jr(),qr(Ur,null,t)):ri(Ur,null,t)}function ci(t){return null==t||"boolean"===typeof t?ri(Ur):(0,i.kJ)(t)?ri(Fr,null,t.slice()):"object"===typeof t?hi(t):ri(Br,null,String(t))}function hi(t){return null===t.el||t.memo?t:si(t)}function fi(t,e){let n=0;const{shapeFlag:r}=t;if(null==e)e=null;else if((0,i.kJ)(e))n=16;else if("object"===typeof e){if(65&r){const n=e.default;return void(n&&(n._c&&(n._d=!1),fi(t,n()),n._c&&(n._d=!0)))}{n=32;const r=e._;r||Qr in e?3===r&&ve&&(1===ve.slots._?e._=1:(e._=2,t.patchFlag|=1024)):e._ctx=ve}}else(0,i.mf)(e)?(e={default:e,_ctx:ve},n=32):(e=String(e),64&r?(n=16,e=[ai(e)]):n=8);t.children=e,t.shapeFlag|=n}function di(...t){const e={};for(let n=0;n<t.length;n++){const r=t[n];for(const t in r)if("class"===t)e.class!==r.class&&(e.class=(0,i.C_)([e.class,r.class]));else if("style"===t)e.style=(0,i.j5)([e.style,r.style]);else if((0,i.F7)(t)){const n=e[t],o=r[t];n===o||(0,i.kJ)(n)&&n.includes(o)||(e[t]=n?[].concat(n,o):o)}else""!==t&&(e[t]=r[t])}return e}function pi(t,e,n,r=null){ro(t,e,7,[n,r])}function vi(t,e,n,r){let o;const s=n&&n[r];if((0,i.kJ)(t)||(0,i.HD)(t)){o=new Array(t.length);for(let n=0,r=t.length;n<r;n++)o[n]=e(t[n],n,void 0,s&&s[n])}else if("number"===typeof t){0,o=new Array(t);for(let n=0;n<t;n++)o[n]=e(n+1,n,void 0,s&&s[n])}else if((0,i.Kn)(t))if(t[Symbol.iterator])o=Array.from(t,((t,n)=>e(t,n,void 0,s&&s[n])));else{const n=Object.keys(t);o=new Array(n.length);for(let r=0,i=n.length;r<i;r++){const i=n[r];o[r]=e(t[i],i,r,s&&s[r])}}else o=[];return n&&(n[r]=o),o}function mi(t,e){for(let n=0;n<e.length;n++){const r=e[n];if((0,i.kJ)(r))for(let e=0;e<r.length;e++)t[r[e].name]=r[e].fn;else r&&(t[r.name]=r.fn)}return t}function gi(t,e,n={},r,i){if(ve.isCE)return ri("slot","default"===e?null:{name:e},r&&r());let o=t[e];o&&o._c&&(o._d=!1),jr();const s=o&&_i(o(n)),a=qr(Fr,{key:n.key||`_${e}`},s||(r?r():[]),s&&1===t._?64:-2);return!i&&a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),o&&o._c&&(o._d=!0),a}function _i(t){return t.some((t=>!Kr(t)||t.type!==Ur&&!(t.type===Fr&&!_i(t.children))))?t:null}function yi(t){const e={};for(const n in t)e[(0,i.hR)(n)]=t[n];return e}const bi=t=>t?Ci(t)?Hi(t)||t.proxy:bi(t.parent):null,Ei=(0,i.l7)(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>bi(t.parent),$root:t=>bi(t.root),$emit:t=>t.emit,$options:t=>Cn(t),$forceUpdate:t=>()=>xo(t.update),$nextTick:t=>bo.bind(t.proxy),$watch:t=>Uo.bind(t)}),xi={get({_:t},e){const{ctx:n,setupState:r,data:o,props:s,accessCache:a,type:u,appContext:l}=t;let c;if("$"!==e[0]){const u=a[e];if(void 0!==u)switch(u){case 1:return r[e];case 2:return o[e];case 4:return n[e];case 3:return s[e]}else{if(r!==i.kT&&(0,i.RI)(r,e))return a[e]=1,r[e];if(o!==i.kT&&(0,i.RI)(o,e))return a[e]=2,o[e];if((c=t.propsOptions[0])&&(0,i.RI)(c,e))return a[e]=3,s[e];if(n!==i.kT&&(0,i.RI)(n,e))return a[e]=4,n[e];An&&(a[e]=0)}}const h=Ei[e];let f,d;return h?("$attrs"===e&&D(t,"get",e),h(t)):(f=u.__cssModules)&&(f=f[e])?f:n!==i.kT&&(0,i.RI)(n,e)?(a[e]=4,n[e]):(d=l.config.globalProperties,(0,i.RI)(d,e)?d[e]:void 0)},set({_:t},e,n){const{data:r,setupState:o,ctx:s}=t;if(o!==i.kT&&(0,i.RI)(o,e))o[e]=n;else if(r!==i.kT&&(0,i.RI)(r,e))r[e]=n;else if((0,i.RI)(t.props,e))return!1;return("$"!==e[0]||!(e.slice(1)in t))&&(s[e]=n,!0)},has({_:{data:t,setupState:e,accessCache:n,ctx:r,appContext:o,propsOptions:s}},a){let u;return!!n[a]||t!==i.kT&&(0,i.RI)(t,a)||e!==i.kT&&(0,i.RI)(e,a)||(u=s[0])&&(0,i.RI)(u,a)||(0,i.RI)(r,a)||(0,i.RI)(Ei,a)||(0,i.RI)(o.config.globalProperties,a)}};const Ti=(0,i.l7)({},xi,{get(t,e){if(e!==Symbol.unscopables)return xi.get(t,e,t)},has(t,e){const n="_"!==e[0]&&!(0,i.e1)(e);return n}});const Si=ir();let Ri=0;function Ai(t,e,n){const r=t.type,o=(e?e.appContext:t.appContext)||Si,s={uid:Ri++,vnode:t,type:r,parent:e,appContext:o,root:null,next:null,subTree:null,effect:null,update:null,scope:new a(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:e?e.provides:Object.create(o.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Vn(r,o),emitsOptions:de(r,o),emit:null,emitted:null,propsDefaults:i.kT,inheritAttrs:r.inheritAttrs,ctx:i.kT,data:i.kT,props:i.kT,attrs:i.kT,slots:i.kT,refs:i.kT,setupState:i.kT,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return s.ctx={_:s},s.root=e?e.root:s,s.emit=fe.bind(null,s),t.ce&&t.ce(s),s}let Oi=null;const wi=()=>Oi||ve,Ii=t=>{Oi=t,t.scope.on()},Pi=()=>{Oi&&Oi.scope.off(),Oi=null};function Ci(t){return 4&t.vnode.shapeFlag}let Ni,Mi,Di=!1;function Li(t,e=!1){Di=e;const{props:n,children:r}=t.vnode,i=Ci(t);kn(t,n,i,e),tr(t,r);const o=i?Fi(t,e):void 0;return Di=!1,o}function Fi(t,e){const n=t.type;t.accessCache=Object.create(null),t.proxy=Xt(new Proxy(t.ctx,xi));const{setup:r}=n;if(r){const n=t.setupContext=r.length>1?ji(t):null;Ii(t),C();const o=no(r,t,0,[t.props,n]);if(M(),Pi(),(0,i.tI)(o)){if(o.then(Pi,Pi),e)return o.then((n=>{Bi(t,n,e)})).catch((e=>{io(e,t,0)}));t.asyncDep=o}else Bi(t,o,e)}else ki(t,e)}function Bi(t,e,n){(0,i.mf)(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:(0,i.Kn)(e)&&(t.setupState=te(e)),ki(t,n)}function Ui(t){Ni=t,Mi=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,Ti))}}const Gi=()=>!Ni;function ki(t,e,n){const r=t.type;if(!t.render){if(!e&&Ni&&!r.render){const e=r.template;if(e){0;const{isCustomElement:n,compilerOptions:o}=t.appContext.config,{delimiters:s,compilerOptions:a}=r,u=(0,i.l7)((0,i.l7)({isCustomElement:n,delimiters:s},o),a);r.render=Ni(e,u)}}t.render=r.render||i.dG,Mi&&Mi(t)}Ii(t),C(),On(t),M(),Pi()}function Xi(t){return new Proxy(t.attrs,{get(e,n){return D(t,"get","$attrs"),e[n]}})}function ji(t){const e=e=>{t.exposed=e||{}};let n;return{get attrs(){return n||(n=Xi(t))},slots:t.slots,emit:t.emit,expose:e}}function Hi(t){if(t.exposed)return t.exposeProxy||(t.exposeProxy=new Proxy(te(Xt(t.exposed)),{get(e,n){return n in e?e[n]:n in Ei?Ei[n](t):void 0}}))}const Vi=/(?:^|[-_])(\w)/g,Yi=t=>t.replace(Vi,(t=>t.toUpperCase())).replace(/[-_]/g,"");function Wi(t){return(0,i.mf)(t)&&t.displayName||t.name}function zi(t,e,n=!1){let r=Wi(e);if(!r&&e.__file){const t=e.__file.match(/([^/\\]+)\.\w+$/);t&&(r=t[1])}if(!r&&t&&t.parent){const n=t=>{for(const n in t)if(t[n]===e)return n};r=n(t.components||t.parent.type.components)||n(t.appContext.components)}return r?Yi(r):n?"App":"Anonymous"}function $i(t){return(0,i.mf)(t)&&"__vccOpts"in t}const qi=[];function Ki(t,...e){C();const n=qi.length?qi[qi.length-1].component:null,r=n&&n.appContext.config.warnHandler,i=Zi();if(r)no(r,n,11,[t+e.join(""),n&&n.proxy,i.map((({vnode:t})=>`at <${zi(n,t.type)}>`)).join("\n"),i]);else{const n=[`[Vue warn]: ${t}`,...e];i.length&&n.push("\n",...Ji(i)),console.warn(...n)}M()}function Zi(){let t=qi[qi.length-1];if(!t)return[];const e=[];while(t){const n=e[0];n&&n.vnode===t?n.recurseCount++:e.push({vnode:t,recurseCount:0});const r=t.component&&t.component.parent;t=r&&r.vnode}return e}function Ji(t){const e=[];return t.forEach(((t,n)=>{e.push(...0===n?[]:["\n"],...Qi(t))})),e}function Qi({vnode:t,recurseCount:e}){const n=e>0?`... (${e} recursive calls)`:"",r=!!t.component&&null==t.component.parent,i=` at <${zi(t.component,t.type,r)}`,o=">"+n;return t.props?[i,...to(t.props),o]:[i+o]}function to(t){const e=[],n=Object.keys(t);return n.slice(0,3).forEach((n=>{e.push(...eo(n,t[n]))})),n.length>3&&e.push(" ..."),e}function eo(t,e,n){return(0,i.HD)(e)?(e=JSON.stringify(e),n?e:[`${t}=${e}`]):"number"===typeof e||"boolean"===typeof e||null==e?n?e:[`${t}=${e}`]:Wt(e)?(e=eo(t,kt(e.value),!0),n?e:[`${t}=Ref<`,e,">"]):(0,i.mf)(e)?[`${t}=fn${e.name?`<${e.name}>`:""}`]:(e=kt(e),n?e:[`${t}=`,e])}function no(t,e,n,r){let i;try{i=r?t(...r):t()}catch(o){io(o,e,n)}return i}function ro(t,e,n,r){if((0,i.mf)(t)){const o=no(t,e,n,r);return o&&(0,i.tI)(o)&&o.catch((t=>{io(t,e,n)})),o}const o=[];for(let i=0;i<t.length;i++)o.push(ro(t[i],e,n,r));return o}function io(t,e,n,r=!0){const i=e?e.vnode:null;if(e){let r=e.parent;const i=e.proxy,o=n;while(r){const e=r.ec;if(e)for(let n=0;n<e.length;n++)if(!1===e[n](t,i,o))return;r=r.parent}const s=e.appContext.config.errorHandler;if(s)return void no(s,null,10,[t,i,o])}oo(t,n,i,r)}function oo(t,e,n,r=!0){console.error(t)}let so=!1,ao=!1;const uo=[];let lo=0;const co=[];let ho=null,fo=0;const po=[];let vo=null,mo=0;const go=Promise.resolve();let _o=null,yo=null;function bo(t){const e=_o||go;return t?e.then(this?t.bind(this):t):e}function Eo(t){let e=lo+1,n=uo.length;while(e<n){const r=e+n>>>1,i=Po(uo[r]);i<t?e=r+1:n=r}return e}function xo(t){uo.length&&uo.includes(t,so&&t.allowRecurse?lo+1:lo)||t===yo||(null==t.id?uo.push(t):uo.splice(Eo(t.id),0,t),To())}function To(){so||ao||(ao=!0,_o=go.then(Co))}function So(t){const e=uo.indexOf(t);e>lo&&uo.splice(e,1)}function Ro(t,e,n,r){(0,i.kJ)(t)?n.push(...t):e&&e.includes(t,t.allowRecurse?r+1:r)||n.push(t),To()}function Ao(t){Ro(t,ho,co,fo)}function Oo(t){Ro(t,vo,po,mo)}function wo(t,e=null){if(co.length){for(yo=e,ho=[...new Set(co)],co.length=0,fo=0;fo<ho.length;fo++)ho[fo]();ho=null,fo=0,yo=null,wo(t,e)}}function Io(t){if(po.length){const t=[...new Set(po)];if(po.length=0,vo)return void vo.push(...t);for(vo=t,vo.sort(((t,e)=>Po(t)-Po(e))),mo=0;mo<vo.length;mo++)vo[mo]();vo=null,mo=0}}const Po=t=>null==t.id?1/0:t.id;function Co(t){ao=!1,so=!0,wo(t),uo.sort(((t,e)=>Po(t)-Po(e)));i.dG;try{for(lo=0;lo<uo.length;lo++){const t=uo[lo];t&&!1!==t.active&&no(t,null,14)}}finally{lo=0,uo.length=0,Io(t),so=!1,_o=null,(uo.length||co.length||po.length)&&Co(t)}}function No(t,e){return Bo(t,null,e)}function Mo(t,e){return Bo(t,null,{flush:"post"})}function Do(t,e){return Bo(t,null,{flush:"sync"})}const Lo={};function Fo(t,e,n){return Bo(t,e,n)}function Bo(t,e,{immediate:n,deep:r,flush:o,onTrack:s,onTrigger:a}=i.kT){const u=Oi;let l,c,h=!1,f=!1;if(Wt(t)?(l=()=>t.value,h=!!t._shallow):Bt(t)?(l=()=>t,r=!0):(0,i.kJ)(t)?(f=!0,h=t.some(Bt),l=()=>t.map((t=>Wt(t)?t.value:Bt(t)?ko(t):(0,i.mf)(t)?no(t,u,2):void 0))):l=(0,i.mf)(t)?e?()=>no(t,u,2):()=>{if(!u||!u.isUnmounted)return c&&c(),ro(t,u,3,[d])}:i.dG,e&&r){const t=l;l=()=>ko(t())}let d=t=>{c=g.onStop=()=>{no(t,u,4)}};if(Di)return d=i.dG,e?n&&ro(e,u,3,[l(),f?[]:void 0,d]):l(),i.dG;let p=f?[]:Lo;const v=()=>{if(g.active)if(e){const t=g.run();(r||h||(f?t.some(((t,e)=>(0,i.aU)(t,p[e]))):(0,i.aU)(t,p)))&&(c&&c(),ro(e,u,3,[t,p===Lo?void 0:p,d]),p=t)}else g.run()};let m;v.allowRecurse=!!e,m="sync"===o?v:"post"===o?()=>dr(v,u&&u.suspense):()=>{!u||u.isMounted?Ao(v):v()};const g=new R(l,m);return e?n?v():p=g.run():"post"===o?dr(g.run.bind(g),u&&u.suspense):g.run(),()=>{g.stop(),u&&u.scope&&(0,i.Od)(u.scope.effects,g)}}function Uo(t,e,n){const r=this.proxy,o=(0,i.HD)(t)?t.includes(".")?Go(r,t):()=>r[t]:t.bind(r,r);let s;(0,i.mf)(e)?s=e:(s=e.handler,n=e);const a=Oi;Ii(this);const u=Bo(o,s.bind(r),n);return a?Ii(a):Pi(),u}function Go(t,e){const n=e.split(".");return()=>{let e=t;for(let t=0;t<n.length&&e;t++)e=e[n[t]];return e}}function ko(t,e){if(!(0,i.Kn)(t)||t["__v_skip"])return t;if(e=e||new Set,e.has(t))return t;if(e.add(t),Wt(t))ko(t.value,e);else if((0,i.kJ)(t))for(let n=0;n<t.length;n++)ko(t[n],e);else if((0,i.DM)(t)||(0,i._N)(t))t.forEach((t=>{ko(t,e)}));else if((0,i.PO)(t))for(const n in t)ko(t[n],e);return t}function Xo(){return null}function jo(){return null}function Ho(t){0}function Vo(t,e){return null}function Yo(){return zo().slots}function Wo(){return zo().attrs}function zo(){const t=wi();return t.setupContext||(t.setupContext=ji(t))}function $o(t,e){const n=(0,i.kJ)(t)?t.reduce(((t,e)=>(t[e]={},t)),{}):t;for(const r in e){const t=n[r];t?(0,i.kJ)(t)||(0,i.mf)(t)?n[r]={type:t,default:e[r]}:t.default=e[r]:null===t&&(n[r]={default:e[r]})}return n}function qo(t,e){const n={};for(const r in t)e.includes(r)||Object.defineProperty(n,r,{enumerable:!0,get:()=>t[r]});return n}function Ko(t){const e=wi();let n=t();return Pi(),(0,i.tI)(n)&&(n=n.catch((t=>{throw Ii(e),t}))),[n,()=>Ii(e)]}function Zo(t,e,n){const r=arguments.length;return 2===r?(0,i.Kn)(e)&&!(0,i.kJ)(e)?Kr(e)?ri(t,null,[e]):ri(t,e):ri(t,null,e):(r>3?n=Array.prototype.slice.call(arguments,2):3===r&&Kr(n)&&(n=[n]),ri(t,e,n))}const Jo=Symbol(""),Qo=()=>{{const t=je(Jo);return t||Ki("Server rendering context not provided. Make sure to only call useSSRContext() conditionally in the server build."),t}};function ts(){return void 0}function es(t,e,n,r){const i=n[r];if(i&&ns(i,t))return i;const o=e();return o.memo=t.slice(),n[r]=o}function ns(t,e){const n=t.memo;if(n.length!=e.length)return!1;for(let r=0;r<n.length;r++)if(n[r]!==e[r])return!1;return Yr>0&&Xr&&Xr.push(t),!0}const rs="3.2.26",is={createComponentInstance:Ai,setupComponent:Li,renderComponentRoot:xe,setCurrentRenderingInstance:ge,isVNode:Kr,normalizeVNode:ci},os=is,ss=null,as=null,us="http://www.w3.org/2000/svg",ls="undefined"!==typeof document?document:null,cs=new Map,hs={insert:(t,e,n)=>{e.insertBefore(t,n||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,n,r)=>{const i=e?ls.createElementNS(us,t):ls.createElement(t,n?{is:n}:void 0);return"select"===t&&r&&null!=r.multiple&&i.setAttribute("multiple",r.multiple),i},createText:t=>ls.createTextNode(t),createComment:t=>ls.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>ls.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},cloneNode(t){const e=t.cloneNode(!0);return"_value"in t&&(e._value=t._value),e},insertStaticContent(t,e,n,r){const i=n?n.previousSibling:e.lastChild;let o=cs.get(t);if(!o){const e=ls.createElement("template");if(e.innerHTML=r?`<svg>${t}</svg>`:t,o=e.content,r){const t=o.firstChild;while(t.firstChild)o.appendChild(t.firstChild);o.removeChild(t)}cs.set(t,o)}return e.insertBefore(o.cloneNode(!0),n),[i?i.nextSibling:e.firstChild,n?n.previousSibling:e.lastChild]}};function fs(t,e,n){const r=t._vtc;r&&(e=(e?[e,...r]:[...r]).join(" ")),null==e?t.removeAttribute("class"):n?t.setAttribute("class",e):t.className=e}function ds(t,e,n){const r=t.style,o=(0,i.HD)(n);if(n&&!o){for(const t in n)vs(r,t,n[t]);if(e&&!(0,i.HD)(e))for(const t in e)null==n[t]&&vs(r,t,"")}else{const i=r.display;o?e!==n&&(r.cssText=n):e&&t.removeAttribute("style"),"_vod"in t&&(r.display=i)}}const ps=/\s*!important$/;function vs(t,e,n){if((0,i.kJ)(n))n.forEach((n=>vs(t,e,n)));else if(e.startsWith("--"))t.setProperty(e,n);else{const r=_s(t,e);ps.test(n)?t.setProperty((0,i.rs)(r),n.replace(ps,""),"important"):t[r]=n}}const ms=["Webkit","Moz","ms"],gs={};function _s(t,e){const n=gs[e];if(n)return n;let r=(0,i._A)(e);if("filter"!==r&&r in t)return gs[e]=r;r=(0,i.kC)(r);for(let i=0;i<ms.length;i++){const n=ms[i]+r;if(n in t)return gs[e]=n}return e}const ys="http://www.w3.org/1999/xlink";function bs(t,e,n,r,o){if(r&&e.startsWith("xlink:"))null==n?t.removeAttributeNS(ys,e.slice(6,e.length)):t.setAttributeNS(ys,e,n);else{const r=(0,i.Pq)(e);null==n||r&&!(0,i.yA)(n)?t.removeAttribute(e):t.setAttribute(e,r?"":n)}}function Es(t,e,n,r,o,s,a){if("innerHTML"===e||"textContent"===e)return r&&a(r,o,s),void(t[e]=null==n?"":n);if("value"===e&&"PROGRESS"!==t.tagName&&!t.tagName.includes("-")){t._value=n;const r=null==n?"":n;return t.value===r&&"OPTION"!==t.tagName||(t.value=r),void(null==n&&t.removeAttribute(e))}if(""===n||null==n){const r=typeof t[e];if("boolean"===r)return void(t[e]=(0,i.yA)(n));if(null==n&&"string"===r)return t[e]="",void t.removeAttribute(e);if("number"===r){try{t[e]=0}catch(u){}return void t.removeAttribute(e)}}try{t[e]=n}catch(l){0}}let xs=Date.now,Ts=!1;if("undefined"!==typeof window){xs()>document.createEvent("Event").timeStamp&&(xs=()=>performance.now());const t=navigator.userAgent.match(/firefox\/(\d+)/i);Ts=!!(t&&Number(t[1])<=53)}let Ss=0;const Rs=Promise.resolve(),As=()=>{Ss=0},Os=()=>Ss||(Rs.then(As),Ss=xs());function ws(t,e,n,r){t.addEventListener(e,n,r)}function Is(t,e,n,r){t.removeEventListener(e,n,r)}function Ps(t,e,n,r,i=null){const o=t._vei||(t._vei={}),s=o[e];if(r&&s)s.value=r;else{const[n,a]=Ns(e);if(r){const s=o[e]=Ms(r,i);ws(t,n,s,a)}else s&&(Is(t,n,s,a),o[e]=void 0)}}const Cs=/(?:Once|Passive|Capture)$/;function Ns(t){let e;if(Cs.test(t)){let n;e={};while(n=t.match(Cs))t=t.slice(0,t.length-n[0].length),e[n[0].toLowerCase()]=!0}return[(0,i.rs)(t.slice(2)),e]}function Ms(t,e){const n=t=>{const r=t.timeStamp||xs();(Ts||r>=n.attached-1)&&ro(Ds(t,n.value),e,5,[t])};return n.value=t,n.attached=Os(),n}function Ds(t,e){if((0,i.kJ)(e)){const n=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{n.call(t),t._stopped=!0},e.map((t=>e=>!e._stopped&&t(e)))}return e}const Ls=/^on[a-z]/,Fs=(t,e,n,r,o=!1,s,a,u,l)=>{"class"===e?fs(t,r,o):"style"===e?ds(t,n,r):(0,i.F7)(e)?(0,i.tR)(e)||Ps(t,e,n,r,a):("."===e[0]?(e=e.slice(1),1):"^"===e[0]?(e=e.slice(1),0):Bs(t,e,r,o))?Es(t,e,r,s,a,u,l):("true-value"===e?t._trueValue=r:"false-value"===e&&(t._falseValue=r),bs(t,e,r,o))};function Bs(t,e,n,r){return r?"innerHTML"===e||"textContent"===e||!!(e in t&&Ls.test(e)&&(0,i.mf)(n)):"spellcheck"!==e&&"draggable"!==e&&("form"!==e&&(("list"!==e||"INPUT"!==t.tagName)&&(("type"!==e||"TEXTAREA"!==t.tagName)&&((!Ls.test(e)||!(0,i.HD)(n))&&e in t))))}function Us(t,e){const n=Qe(t);class r extends Xs{constructor(t){super(n,t,e)}}return r.def=n,r}const Gs=t=>Us(t,$a),ks="undefined"!==typeof HTMLElement?HTMLElement:class{};class Xs extends ks{constructor(t,e={},n){super(),this._def=t,this._props=e,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this.shadowRoot&&n?n(this._createVNode(),this.shadowRoot):this.attachShadow({mode:"open"})}connectedCallback(){this._connected=!0,this._instance||this._resolveDef()}disconnectedCallback(){this._connected=!1,bo((()=>{this._connected||(za(null,this.shadowRoot),this._instance=null)}))}_resolveDef(){if(this._resolved)return;this._resolved=!0;for(let n=0;n<this.attributes.length;n++)this._setAttr(this.attributes[n].name);new MutationObserver((t=>{for(const e of t)this._setAttr(e.attributeName)})).observe(this,{attributes:!0});const t=t=>{const{props:e,styles:n}=t,r=!(0,i.kJ)(e),o=e?r?Object.keys(e):e:[];let s;if(r)for(const a in this._props){const t=e[a];(t===Number||t&&t.type===Number)&&(this._props[a]=(0,i.He)(this._props[a]),(s||(s=Object.create(null)))[a]=!0)}this._numberProps=s;for(const i of Object.keys(this))"_"!==i[0]&&this._setProp(i,this[i],!0,!1);for(const a of o.map(i._A))Object.defineProperty(this,a,{get(){return this._getProp(a)},set(t){this._setProp(a,t)}});this._applyStyles(n),this._update()},e=this._def.__asyncLoader;e?e().then(t):t(this._def)}_setAttr(t){let e=this.getAttribute(t);this._numberProps&&this._numberProps[t]&&(e=(0,i.He)(e)),this._setProp((0,i._A)(t),e,!1)}_getProp(t){return this._props[t]}_setProp(t,e,n=!0,r=!0){e!==this._props[t]&&(this._props[t]=e,r&&this._instance&&this._update(),n&&(!0===e?this.setAttribute((0,i.rs)(t),""):"string"===typeof e||"number"===typeof e?this.setAttribute((0,i.rs)(t),e+""):e||this.removeAttribute((0,i.rs)(t))))}_update(){za(this._createVNode(),this.shadowRoot)}_createVNode(){const t=ri(this._def,(0,i.l7)({},this._props));return this._instance||(t.ce=t=>{this._instance=t,t.isCE=!0,t.emit=(t,...e)=>{this.dispatchEvent(new CustomEvent(t,{detail:e}))};let e=this;while(e=e&&(e.parentNode||e.host))if(e instanceof Xs){t.parent=e._instance;break}}),t}_applyStyles(t){t&&t.forEach((t=>{const e=document.createElement("style");e.textContent=t,this.shadowRoot.appendChild(e)}))}}function js(t="$style"){{const e=wi();if(!e)return i.kT;const n=e.type.__cssModules;if(!n)return i.kT;const r=n[t];return r||i.kT}}function Hs(t){const e=wi();if(!e)return;const n=()=>Vs(e.subTree,t(e.proxy));Mo(n),gn((()=>{const t=new MutationObserver(n);t.observe(e.subTree.el.parentNode,{childList:!0}),En((()=>t.disconnect()))}))}function Vs(t,e){if(128&t.shapeFlag){const n=t.suspense;t=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{Vs(n.activeBranch,e)}))}while(t.component)t=t.component.subTree;if(1&t.shapeFlag&&t.el)Ys(t.el,e);else if(t.type===Fr)t.children.forEach((t=>Vs(t,e)));else if(t.type===Gr){let{el:n,anchor:r}=t;while(n){if(Ys(n,e),n===r)break;n=n.nextSibling}}}function Ys(t,e){if(1===t.nodeType){const n=t.style;for(const t in e)n.setProperty(`--${t}`,e[t])}}const Ws="transition",zs="animation",$s=(t,{slots:e})=>Zo(We,Qs(t),e);$s.displayName="Transition";const qs={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Ks=$s.props=(0,i.l7)({},We.props,qs),Zs=(t,e=[])=>{(0,i.kJ)(t)?t.forEach((t=>t(...e))):t&&t(...e)},Js=t=>!!t&&((0,i.kJ)(t)?t.some((t=>t.length>1)):t.length>1);function Qs(t){const e={};for(const i in t)i in qs||(e[i]=t[i]);if(!1===t.css)return e;const{name:n="v",type:r,duration:o,enterFromClass:s=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:u=`${n}-enter-to`,appearFromClass:l=s,appearActiveClass:c=a,appearToClass:h=u,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:d=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=t,v=ta(o),m=v&&v[0],g=v&&v[1],{onBeforeEnter:_,onEnter:y,onEnterCancelled:b,onLeave:E,onLeaveCancelled:x,onBeforeAppear:T=_,onAppear:S=y,onAppearCancelled:R=b}=e,A=(t,e,n)=>{ra(t,e?h:u),ra(t,e?c:a),n&&n()},O=(t,e)=>{ra(t,p),ra(t,d),e&&e()},w=t=>(e,n)=>{const i=t?S:y,o=()=>A(e,t,n);Zs(i,[e,o]),ia((()=>{ra(e,t?l:s),na(e,t?h:u),Js(i)||sa(e,r,m,o)}))};return(0,i.l7)(e,{onBeforeEnter(t){Zs(_,[t]),na(t,s),na(t,a)},onBeforeAppear(t){Zs(T,[t]),na(t,l),na(t,c)},onEnter:w(!1),onAppear:w(!0),onLeave(t,e){const n=()=>O(t,e);na(t,f),ca(),na(t,d),ia((()=>{ra(t,f),na(t,p),Js(E)||sa(t,r,g,n)})),Zs(E,[t,n])},onEnterCancelled(t){A(t,!1),Zs(b,[t])},onAppearCancelled(t){A(t,!0),Zs(R,[t])},onLeaveCancelled(t){O(t),Zs(x,[t])}})}function ta(t){if(null==t)return null;if((0,i.Kn)(t))return[ea(t.enter),ea(t.leave)];{const e=ea(t);return[e,e]}}function ea(t){const e=(0,i.He)(t);return e}function na(t,e){e.split(/\s+/).forEach((e=>e&&t.classList.add(e))),(t._vtc||(t._vtc=new Set)).add(e)}function ra(t,e){e.split(/\s+/).forEach((e=>e&&t.classList.remove(e)));const{_vtc:n}=t;n&&(n.delete(e),n.size||(t._vtc=void 0))}function ia(t){requestAnimationFrame((()=>{requestAnimationFrame(t)}))}let oa=0;function sa(t,e,n,r){const i=t._endId=++oa,o=()=>{i===t._endId&&r()};if(n)return setTimeout(o,n);const{type:s,timeout:a,propCount:u}=aa(t,e);if(!s)return r();const l=s+"end";let c=0;const h=()=>{t.removeEventListener(l,f),o()},f=e=>{e.target===t&&++c>=u&&h()};setTimeout((()=>{c<u&&h()}),a+1),t.addEventListener(l,f)}function aa(t,e){const n=window.getComputedStyle(t),r=t=>(n[t]||"").split(", "),i=r(Ws+"Delay"),o=r(Ws+"Duration"),s=ua(i,o),a=r(zs+"Delay"),u=r(zs+"Duration"),l=ua(a,u);let c=null,h=0,f=0;e===Ws?s>0&&(c=Ws,h=s,f=o.length):e===zs?l>0&&(c=zs,h=l,f=u.length):(h=Math.max(s,l),c=h>0?s>l?Ws:zs:null,f=c?c===Ws?o.length:u.length:0);const d=c===Ws&&/\b(transform|all)(,|$)/.test(n[Ws+"Property"]);return{type:c,timeout:h,propCount:f,hasTransform:d}}function ua(t,e){while(t.length<e.length)t=t.concat(t);return Math.max(...e.map(((e,n)=>la(e)+la(t[n]))))}function la(t){return 1e3*Number(t.slice(0,-1).replace(",","."))}function ca(){return document.body.offsetHeight}const ha=new WeakMap,fa=new WeakMap,da={name:"TransitionGroup",props:(0,i.l7)({},Ks,{tag:String,moveClass:String}),setup(t,{slots:e}){const n=wi(),r=He();let i,o;return yn((()=>{if(!i.length)return;const e=t.moveClass||`${t.name||"v"}-move`;if(!_a(i[0].el,n.vnode.el,e))return;i.forEach(va),i.forEach(ma);const r=i.filter(ga);ca(),r.forEach((t=>{const n=t.el,r=n.style;na(n,e),r.transform=r.webkitTransform=r.transitionDuration="";const i=n._moveCb=t=>{t&&t.target!==n||t&&!/transform$/.test(t.propertyName)||(n.removeEventListener("transitionend",i),n._moveCb=null,ra(n,e))};n.addEventListener("transitionend",i)}))})),()=>{const s=kt(t),a=Qs(s);let u=s.tag||Fr;i=o,o=e.default?Je(e.default()):[];for(let t=0;t<o.length;t++){const e=o[t];null!=e.key&&Ze(e,$e(e,a,r,n))}if(i)for(let t=0;t<i.length;t++){const e=i[t];Ze(e,$e(e,a,r,n)),ha.set(e,e.el.getBoundingClientRect())}return ri(u,null,o)}}},pa=da;function va(t){const e=t.el;e._moveCb&&e._moveCb(),e._enterCb&&e._enterCb()}function ma(t){fa.set(t,t.el.getBoundingClientRect())}function ga(t){const e=ha.get(t),n=fa.get(t),r=e.left-n.left,i=e.top-n.top;if(r||i){const e=t.el.style;return e.transform=e.webkitTransform=`translate(${r}px,${i}px)`,e.transitionDuration="0s",t}}function _a(t,e,n){const r=t.cloneNode();t._vtc&&t._vtc.forEach((t=>{t.split(/\s+/).forEach((t=>t&&r.classList.remove(t)))})),n.split(/\s+/).forEach((t=>t&&r.classList.add(t))),r.style.display="none";const i=1===e.nodeType?e:e.parentNode;i.appendChild(r);const{hasTransform:o}=aa(r);return i.removeChild(r),o}const ya=t=>{const e=t.props["onUpdate:modelValue"];return(0,i.kJ)(e)?t=>(0,i.ir)(e,t):e};function ba(t){t.target.composing=!0}function Ea(t){const e=t.target;e.composing&&(e.composing=!1,xa(e,"input"))}function xa(t,e){const n=document.createEvent("HTMLEvents");n.initEvent(e,!0,!0),t.dispatchEvent(n)}const Ta={created(t,{modifiers:{lazy:e,trim:n,number:r}},o){t._assign=ya(o);const s=r||o.props&&"number"===o.props.type;ws(t,e?"change":"input",(e=>{if(e.target.composing)return;let r=t.value;n?r=r.trim():s&&(r=(0,i.He)(r)),t._assign(r)})),n&&ws(t,"change",(()=>{t.value=t.value.trim()})),e||(ws(t,"compositionstart",ba),ws(t,"compositionend",Ea),ws(t,"change",Ea))},mounted(t,{value:e}){t.value=null==e?"":e},beforeUpdate(t,{value:e,modifiers:{lazy:n,trim:r,number:o}},s){if(t._assign=ya(s),t.composing)return;if(document.activeElement===t){if(n)return;if(r&&t.value.trim()===e)return;if((o||"number"===t.type)&&(0,i.He)(t.value)===e)return}const a=null==e?"":e;t.value!==a&&(t.value=a)}},Sa={deep:!0,created(t,e,n){t._assign=ya(n),ws(t,"change",(()=>{const e=t._modelValue,n=Ia(t),r=t.checked,o=t._assign;if((0,i.kJ)(e)){const t=(0,i.hq)(e,n),s=-1!==t;if(r&&!s)o(e.concat(n));else if(!r&&s){const n=[...e];n.splice(t,1),o(n)}}else if((0,i.DM)(e)){const t=new Set(e);r?t.add(n):t.delete(n),o(t)}else o(Pa(t,r))}))},mounted:Ra,beforeUpdate(t,e,n){t._assign=ya(n),Ra(t,e,n)}};function Ra(t,{value:e,oldValue:n},r){t._modelValue=e,(0,i.kJ)(e)?t.checked=(0,i.hq)(e,r.props.value)>-1:(0,i.DM)(e)?t.checked=e.has(r.props.value):e!==n&&(t.checked=(0,i.WV)(e,Pa(t,!0)))}const Aa={created(t,{value:e},n){t.checked=(0,i.WV)(e,n.props.value),t._assign=ya(n),ws(t,"change",(()=>{t._assign(Ia(t))}))},beforeUpdate(t,{value:e,oldValue:n},r){t._assign=ya(r),e!==n&&(t.checked=(0,i.WV)(e,r.props.value))}},Oa={deep:!0,created(t,{value:e,modifiers:{number:n}},r){const o=(0,i.DM)(e);ws(t,"change",(()=>{const e=Array.prototype.filter.call(t.options,(t=>t.selected)).map((t=>n?(0,i.He)(Ia(t)):Ia(t)));t._assign(t.multiple?o?new Set(e):e:e[0])})),t._assign=ya(r)},mounted(t,{value:e}){wa(t,e)},beforeUpdate(t,e,n){t._assign=ya(n)},updated(t,{value:e}){wa(t,e)}};function wa(t,e){const n=t.multiple;if(!n||(0,i.kJ)(e)||(0,i.DM)(e)){for(let r=0,o=t.options.length;r<o;r++){const o=t.options[r],s=Ia(o);if(n)(0,i.kJ)(e)?o.selected=(0,i.hq)(e,s)>-1:o.selected=e.has(s);else if((0,i.WV)(Ia(o),e))return void(t.selectedIndex!==r&&(t.selectedIndex=r))}n||-1===t.selectedIndex||(t.selectedIndex=-1)}}function Ia(t){return"_value"in t?t._value:t.value}function Pa(t,e){const n=e?"_trueValue":"_falseValue";return n in t?t[n]:e}const Ca={created(t,e,n){Na(t,e,n,null,"created")},mounted(t,e,n){Na(t,e,n,null,"mounted")},beforeUpdate(t,e,n,r){Na(t,e,n,r,"beforeUpdate")},updated(t,e,n,r){Na(t,e,n,r,"updated")}};function Na(t,e,n,r,i){let o;switch(t.tagName){case"SELECT":o=Oa;break;case"TEXTAREA":o=Ta;break;default:switch(n.props&&n.props.type){case"checkbox":o=Sa;break;case"radio":o=Aa;break;default:o=Ta}}const s=o[i];s&&s(t,e,n,r)}function Ma(){Ta.getSSRProps=({value:t})=>({value:t}),Aa.getSSRProps=({value:t},e)=>{if(e.props&&(0,i.WV)(e.props.value,t))return{checked:!0}},Sa.getSSRProps=({value:t},e)=>{if((0,i.kJ)(t)){if(e.props&&(0,i.hq)(t,e.props.value)>-1)return{checked:!0}}else if((0,i.DM)(t)){if(e.props&&t.has(e.props.value))return{checked:!0}}else if(t)return{checked:!0}}}const Da=["ctrl","shift","alt","meta"],La={stop:t=>t.stopPropagation(),prevent:t=>t.preventDefault(),self:t=>t.target!==t.currentTarget,ctrl:t=>!t.ctrlKey,shift:t=>!t.shiftKey,alt:t=>!t.altKey,meta:t=>!t.metaKey,left:t=>"button"in t&&0!==t.button,middle:t=>"button"in t&&1!==t.button,right:t=>"button"in t&&2!==t.button,exact:(t,e)=>Da.some((n=>t[`${n}Key`]&&!e.includes(n)))},Fa=(t,e)=>(n,...r)=>{for(let t=0;t<e.length;t++){const r=La[e[t]];if(r&&r(n,e))return}return t(n,...r)},Ba={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Ua=(t,e)=>n=>{if(!("key"in n))return;const r=(0,i.rs)(n.key);return e.some((t=>t===r||Ba[t]===r))?t(n):void 0},Ga={beforeMount(t,{value:e},{transition:n}){t._vod="none"===t.style.display?"":t.style.display,n&&e?n.beforeEnter(t):ka(t,e)},mounted(t,{value:e},{transition:n}){n&&e&&n.enter(t)},updated(t,{value:e,oldValue:n},{transition:r}){!e!==!n&&(r?e?(r.beforeEnter(t),ka(t,!0),r.enter(t)):r.leave(t,(()=>{ka(t,!1)})):ka(t,e))},beforeUnmount(t,{value:e}){ka(t,e)}};function ka(t,e){t.style.display=e?t._vod:"none"}function Xa(){Ga.getSSRProps=({value:t})=>{if(!t)return{style:{display:"none"}}}}const ja=(0,i.l7)({patchProp:Fs},hs);let Ha,Va=!1;function Ya(){return Ha||(Ha=pr(ja))}function Wa(){return Ha=Va?Ha:vr(ja),Va=!0,Ha}const za=(...t)=>{Ya().render(...t)},$a=(...t)=>{Wa().hydrate(...t)},qa=(...t)=>{const e=Ya().createApp(...t);const{mount:n}=e;return e.mount=t=>{const r=Za(t);if(!r)return;const o=e._component;(0,i.mf)(o)||o.render||o.template||(o.template=r.innerHTML),r.innerHTML="";const s=n(r,!1,r instanceof SVGElement);return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),s},e},Ka=(...t)=>{const e=Wa().createApp(...t);const{mount:n}=e;return e.mount=t=>{const e=Za(t);if(e)return n(e,!0,e instanceof SVGElement)},e};function Za(t){if((0,i.HD)(t)){const e=document.querySelector(t);return e}return t}let Ja=!1;const Qa=()=>{Ja||(Ja=!0,Ma(),Xa())};function tu(t){throw t}function eu(t){}function nu(t,e,n,r){const i=t,o=new SyntaxError(String(i));return o.code=t,o.loc=e,o}const ru=Symbol(""),iu=Symbol(""),ou=Symbol(""),su=Symbol(""),au=Symbol(""),uu=Symbol(""),lu=Symbol(""),cu=Symbol(""),hu=Symbol(""),fu=Symbol(""),du=Symbol(""),pu=Symbol(""),vu=Symbol(""),mu=Symbol(""),gu=Symbol(""),_u=Symbol(""),yu=Symbol(""),bu=Symbol(""),Eu=Symbol(""),xu=Symbol(""),Tu=Symbol(""),Su=Symbol(""),Ru=Symbol(""),Au=Symbol(""),Ou=Symbol(""),wu=Symbol(""),Iu=Symbol(""),Pu=Symbol(""),Cu=Symbol(""),Nu=Symbol(""),Mu=Symbol(""),Du=Symbol(""),Lu=Symbol(""),Fu=Symbol(""),Bu=Symbol(""),Uu=Symbol(""),Gu=Symbol(""),ku=Symbol(""),Xu=Symbol(""),ju={[ru]:"Fragment",[iu]:"Teleport",[ou]:"Suspense",[su]:"KeepAlive",[au]:"BaseTransition",[uu]:"openBlock",[lu]:"createBlock",[cu]:"createElementBlock",[hu]:"createVNode",[fu]:"createElementVNode",[du]:"createCommentVNode",[pu]:"createTextVNode",[vu]:"createStaticVNode",[mu]:"resolveComponent",[gu]:"resolveDynamicComponent",[_u]:"resolveDirective",[yu]:"resolveFilter",[bu]:"withDirectives",[Eu]:"renderList",[xu]:"renderSlot",[Tu]:"createSlots",[Su]:"toDisplayString",[Ru]:"mergeProps",[Au]:"normalizeClass",[Ou]:"normalizeStyle",[wu]:"normalizeProps",[Iu]:"guardReactiveProps",[Pu]:"toHandlers",[Cu]:"camelize",[Nu]:"capitalize",[Mu]:"toHandlerKey",[Du]:"setBlockTracking",[Lu]:"pushScopeId",[Fu]:"popScopeId",[Bu]:"withCtx",[Uu]:"unref",[Gu]:"isRef",[ku]:"withMemo",[Xu]:"isMemoSame"};function Hu(t){Object.getOwnPropertySymbols(t).forEach((e=>{ju[e]=t[e]}))}const Vu={source:"",start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0}};function Yu(t,e=Vu){return{type:0,children:t,helpers:[],components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:e}}function Wu(t,e,n,r,i,o,s,a=!1,u=!1,l=!1,c=Vu){return t&&(a?(t.helper(uu),t.helper(Rl(t.inSSR,l))):t.helper(Sl(t.inSSR,l)),s&&t.helper(bu)),{type:13,tag:e,props:n,children:r,patchFlag:i,dynamicProps:o,directives:s,isBlock:a,disableTracking:u,isComponent:l,loc:c}}function zu(t,e=Vu){return{type:17,loc:e,elements:t}}function $u(t,e=Vu){return{type:15,loc:e,properties:t}}function qu(t,e){return{type:16,loc:Vu,key:(0,i.HD)(t)?Ku(t,!0):t,value:e}}function Ku(t,e=!1,n=Vu,r=0){return{type:4,loc:n,content:t,isStatic:e,constType:e?3:r}}function Zu(t,e=Vu){return{type:8,loc:e,children:t}}function Ju(t,e=[],n=Vu){return{type:14,loc:n,callee:t,arguments:e}}function Qu(t,e,n=!1,r=!1,i=Vu){return{type:18,params:t,returns:e,newline:n,isSlot:r,loc:i}}function tl(t,e,n,r=!0){return{type:19,test:t,consequent:e,alternate:n,newline:r,loc:Vu}}function el(t,e,n=!1){return{type:20,index:t,value:e,isVNode:n,loc:Vu}}function nl(t){return{type:21,body:t,loc:Vu}}const rl=t=>4===t.type&&t.isStatic,il=(t,e)=>t===e||t===(0,i.rs)(e);function ol(t){return il(t,"Teleport")?iu:il(t,"Suspense")?ou:il(t,"KeepAlive")?su:il(t,"BaseTransition")?au:void 0}const sl=/^\d|[^\$\w]/,al=t=>!sl.test(t),ul=/[A-Za-z_$\xA0-\uFFFF]/,ll=/[\.\?\w$\xA0-\uFFFF]/,cl=/\s+[.[]\s*|\s*[.[]\s+/g,hl=t=>{t=t.trim().replace(cl,(t=>t.trim()));let e=0,n=[],r=0,i=0,o=null;for(let s=0;s<t.length;s++){const a=t.charAt(s);switch(e){case 0:if("["===a)n.push(e),e=1,r++;else if("("===a)n.push(e),e=2,i++;else if(!(0===s?ul:ll).test(a))return!1;break;case 1:"'"===a||'"'===a||"`"===a?(n.push(e),e=3,o=a):"["===a?r++:"]"===a&&(--r||(e=n.pop()));break;case 2:if("'"===a||'"'===a||"`"===a)n.push(e),e=3,o=a;else if("("===a)i++;else if(")"===a){if(s===t.length-1)return!1;--i||(e=n.pop())}break;case 3:a===o&&(e=n.pop(),o=null);break}}return!r&&!i},fl=hl;function dl(t,e,n){const r=t.source.slice(e,e+n),i={source:r,start:pl(t.start,t.source,e),end:t.end};return null!=n&&(i.end=pl(t.start,t.source,e+n)),i}function pl(t,e,n=e.length){return vl((0,i.l7)({},t),e,n)}function vl(t,e,n=e.length){let r=0,i=-1;for(let o=0;o<n;o++)10===e.charCodeAt(o)&&(r++,i=o);return t.offset+=n,t.line+=r,t.column=-1===i?t.column+n:n-i,t}function ml(t,e,n=!1){for(let r=0;r<t.props.length;r++){const o=t.props[r];if(7===o.type&&(n||o.exp)&&((0,i.HD)(e)?o.name===e:e.test(o.name)))return o}}function gl(t,e,n=!1,r=!1){for(let i=0;i<t.props.length;i++){const o=t.props[i];if(6===o.type){if(n)continue;if(o.name===e&&(o.value||r))return o}else if("bind"===o.name&&(o.exp||r)&&_l(o.arg,e))return o}}function _l(t,e){return!(!t||!rl(t)||t.content!==e)}function yl(t){return t.props.some((t=>7===t.type&&"bind"===t.name&&(!t.arg||4!==t.arg.type||!t.arg.isStatic)))}function bl(t){return 5===t.type||2===t.type}function El(t){return 7===t.type&&"slot"===t.name}function xl(t){return 1===t.type&&3===t.tagType}function Tl(t){return 1===t.type&&2===t.tagType}function Sl(t,e){return t||e?hu:fu}function Rl(t,e){return t||e?lu:cu}const Al=new Set([wu,Iu]);function Ol(t,e=[]){if(t&&!(0,i.HD)(t)&&14===t.type){const n=t.callee;if(!(0,i.HD)(n)&&Al.has(n))return Ol(t.arguments[0],e.concat(t))}return[t,e]}function wl(t,e,n){let r,o,s=13===t.type?t.props:t.arguments[2],a=[];if(s&&!(0,i.HD)(s)&&14===s.type){const t=Ol(s);s=t[0],a=t[1],o=a[a.length-1]}if(null==s||(0,i.HD)(s))r=$u([e]);else if(14===s.type){const t=s.arguments[0];(0,i.HD)(t)||15!==t.type?s.callee===Pu?r=Ju(n.helper(Ru),[$u([e]),s]):s.arguments.unshift($u([e])):t.properties.unshift(e),!r&&(r=s)}else if(15===s.type){let t=!1;if(4===e.key.type){const n=e.key.content;t=s.properties.some((t=>4===t.key.type&&t.key.content===n))}t||s.properties.unshift(e),r=s}else r=Ju(n.helper(Ru),[$u([e]),s]),o&&o.callee===Iu&&(o=a[a.length-2]);13===t.type?o?o.arguments[0]=r:t.props=r:o?o.arguments[0]=r:t.arguments[2]=r}function Il(t,e){return`_${e}_${t.replace(/[^\w]/g,((e,n)=>"-"===e?"_":t.charCodeAt(n).toString()))}`}function Pl(t){return 14===t.type&&t.callee===ku?t.arguments[1].returns:t}function Cl(t,{helper:e,removeHelper:n,inSSR:r}){t.isBlock||(t.isBlock=!0,n(Sl(r,t.isComponent)),e(uu),e(Rl(r,t.isComponent)))}function Nl(t,e){const n=e.options?e.options.compatConfig:e.compatConfig,r=n&&n[t];return"MODE"===t?r||3:r}function Ml(t,e){const n=Nl("MODE",e),r=Nl(t,e);return 3===n?!0===r:!1!==r}function Dl(t,e,n,...r){const i=Ml(t,e);return i}const Ll=/&(gt|lt|amp|apos|quot);/g,Fl={gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},Bl={delimiters:["{{","}}"],getNamespace:()=>0,getTextMode:()=>0,isVoidTag:i.NO,isPreTag:i.NO,isCustomElement:i.NO,decodeEntities:t=>t.replace(Ll,((t,e)=>Fl[e])),onError:tu,onWarn:eu,comments:!1};function Ul(t,e={}){const n=Gl(t,e),r=ec(n);return Yu(kl(n,0,[]),nc(n,r))}function Gl(t,e){const n=(0,i.l7)({},Bl);let r;for(r in e)n[r]=void 0===e[r]?Bl[r]:e[r];return{options:n,column:1,line:1,offset:0,originalSource:t,source:t,inPre:!1,inVPre:!1,onWarn:n.onWarn}}function kl(t,e,n){const r=rc(n),o=r?r.ns:0,s=[];while(!lc(t,e,n)){const a=t.source;let u;if(0===e||1===e)if(!t.inVPre&&ic(a,t.options.delimiters[0]))u=Jl(t,e);else if(0===e&&"<"===a[0])if(1===a.length)uc(t,5,1);else if("!"===a[1])ic(a,"\x3c!--")?u=Hl(t):ic(a,"<!DOCTYPE")?u=Vl(t):ic(a,"<![CDATA[")?0!==o?u=jl(t,n):(uc(t,1),u=Vl(t)):(uc(t,11),u=Vl(t));else if("/"===a[1])if(2===a.length)uc(t,5,2);else{if(">"===a[2]){uc(t,14,2),oc(t,3);continue}if(/[a-z]/i.test(a[2])){uc(t,23),zl(t,1,r);continue}uc(t,12,2),u=Vl(t)}else/[a-z]/i.test(a[1])?(u=Yl(t,n),Ml("COMPILER_NATIVE_TEMPLATE",t)&&u&&"template"===u.tag&&!u.props.some((t=>7===t.type&&Wl(t.name)))&&(u=u.children)):"?"===a[1]?(uc(t,21,1),u=Vl(t)):uc(t,12,1);if(u||(u=Ql(t,e)),(0,i.kJ)(u))for(let t=0;t<u.length;t++)Xl(s,u[t]);else Xl(s,u)}let a=!1;if(2!==e&&1!==e){const e="preserve"!==t.options.whitespace;for(let n=0;n<s.length;n++){const r=s[n];if(t.inPre||2!==r.type)3!==r.type||t.options.comments||(a=!0,s[n]=null);else if(/[^\t\r\n\f ]/.test(r.content))e&&(r.content=r.content.replace(/[\t\r\n\f ]+/g," "));else{const t=s[n-1],i=s[n+1];!t||!i||e&&(3===t.type||3===i.type||1===t.type&&1===i.type&&/[\r\n]/.test(r.content))?(a=!0,s[n]=null):r.content=" "}}if(t.inPre&&r&&t.options.isPreTag(r.tag)){const t=s[0];t&&2===t.type&&(t.content=t.content.replace(/^\r?\n/,""))}}return a?s.filter(Boolean):s}function Xl(t,e){if(2===e.type){const n=rc(t);if(n&&2===n.type&&n.loc.end.offset===e.loc.start.offset)return n.content+=e.content,n.loc.end=e.loc.end,void(n.loc.source+=e.loc.source)}t.push(e)}function jl(t,e){oc(t,9);const n=kl(t,3,e);return 0===t.source.length?uc(t,6):oc(t,3),n}function Hl(t){const e=ec(t);let n;const r=/--(\!)?>/.exec(t.source);if(r){r.index<=3&&uc(t,0),r[1]&&uc(t,10),n=t.source.slice(4,r.index);const e=t.source.slice(0,r.index);let i=1,o=0;while(-1!==(o=e.indexOf("\x3c!--",i)))oc(t,o-i+1),o+4<e.length&&uc(t,16),i=o+1;oc(t,r.index+r[0].length-i+1)}else n=t.source.slice(4),oc(t,t.source.length),uc(t,7);return{type:3,content:n,loc:nc(t,e)}}function Vl(t){const e=ec(t),n="?"===t.source[1]?1:2;let r;const i=t.source.indexOf(">");return-1===i?(r=t.source.slice(n),oc(t,t.source.length)):(r=t.source.slice(n,i),oc(t,i+1)),{type:3,content:r,loc:nc(t,e)}}function Yl(t,e){const n=t.inPre,r=t.inVPre,i=rc(e),o=zl(t,0,i),s=t.inPre&&!n,a=t.inVPre&&!r;if(o.isSelfClosing||t.options.isVoidTag(o.tag))return s&&(t.inPre=!1),a&&(t.inVPre=!1),o;e.push(o);const u=t.options.getTextMode(o,i),l=kl(t,u,e);e.pop();{const e=o.props.find((t=>6===t.type&&"inline-template"===t.name));if(e&&Dl("COMPILER_INLINE_TEMPLATE",t,e.loc)){const n=nc(t,o.loc.end);e.value={type:2,content:n.source,loc:n}}}if(o.children=l,cc(t.source,o.tag))zl(t,1,i);else if(uc(t,24,0,o.loc.start),0===t.source.length&&"script"===o.tag.toLowerCase()){const e=l[0];e&&ic(e.loc.source,"\x3c!--")&&uc(t,8)}return o.loc=nc(t,o.loc.start),s&&(t.inPre=!1),a&&(t.inVPre=!1),o}const Wl=(0,i.fY)("if,else,else-if,for,slot");function zl(t,e,n){const r=ec(t),o=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(t.source),s=o[1],a=t.options.getNamespace(s,n);oc(t,o[0].length),sc(t);const u=ec(t),l=t.source;t.options.isPreTag(s)&&(t.inPre=!0);let c=ql(t,e);0===e&&!t.inVPre&&c.some((t=>7===t.type&&"pre"===t.name))&&(t.inVPre=!0,(0,i.l7)(t,u),t.source=l,c=ql(t,e).filter((t=>"v-pre"!==t.name)));let h=!1;if(0===t.source.length?uc(t,9):(h=ic(t.source,"/>"),1===e&&h&&uc(t,4),oc(t,h?2:1)),1===e)return;let f=0;return t.inVPre||("slot"===s?f=2:"template"===s?c.some((t=>7===t.type&&Wl(t.name)))&&(f=3):$l(s,c,t)&&(f=1)),{type:1,ns:a,tag:s,tagType:f,props:c,isSelfClosing:h,children:[],loc:nc(t,r),codegenNode:void 0}}function $l(t,e,n){const r=n.options;if(r.isCustomElement(t))return!1;if("component"===t||/^[A-Z]/.test(t)||ol(t)||r.isBuiltInComponent&&r.isBuiltInComponent(t)||r.isNativeTag&&!r.isNativeTag(t))return!0;for(let i=0;i<e.length;i++){const t=e[i];if(6===t.type){if("is"===t.name&&t.value){if(t.value.content.startsWith("vue:"))return!0;if(Dl("COMPILER_IS_ON_ELEMENT",n,t.loc))return!0}}else{if("is"===t.name)return!0;if("bind"===t.name&&_l(t.arg,"is")&&Dl("COMPILER_IS_ON_ELEMENT",n,t.loc))return!0}}}function ql(t,e){const n=[],r=new Set;while(t.source.length>0&&!ic(t.source,">")&&!ic(t.source,"/>")){if(ic(t.source,"/")){uc(t,22),oc(t,1),sc(t);continue}1===e&&uc(t,3);const i=Kl(t,r);6===i.type&&i.value&&"class"===i.name&&(i.value.content=i.value.content.replace(/\s+/g," ").trim()),0===e&&n.push(i),/^[^\t\r\n\f />]/.test(t.source)&&uc(t,15),sc(t)}return n}function Kl(t,e){const n=ec(t),r=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(t.source),i=r[0];e.has(i)&&uc(t,2),e.add(i),"="===i[0]&&uc(t,19);{const e=/["'<]/g;let n;while(n=e.exec(i))uc(t,17,n.index)}let o;oc(t,i.length),/^[\t\r\n\f ]*=/.test(t.source)&&(sc(t),oc(t,1),sc(t),o=Zl(t),o||uc(t,13));const s=nc(t,n);if(!t.inVPre&&/^(v-[A-Za-z0-9-]|:|\.|@|#)/.test(i)){const e=/(?:^v-([a-z0-9-]+))?(?:(?::|^\.|^@|^#)(\[[^\]]+\]|[^\.]+))?(.+)?$/i.exec(i);let r,a=ic(i,"."),u=e[1]||(a||ic(i,":")?"bind":ic(i,"@")?"on":"slot");if(e[2]){const o="slot"===u,s=i.lastIndexOf(e[2]),a=nc(t,ac(t,n,s),ac(t,n,s+e[2].length+(o&&e[3]||"").length));let l=e[2],c=!0;l.startsWith("[")?(c=!1,l.endsWith("]")?l=l.slice(1,l.length-1):(uc(t,27),l=l.slice(1))):o&&(l+=e[3]||""),r={type:4,content:l,isStatic:c,constType:c?3:0,loc:a}}if(o&&o.isQuoted){const t=o.loc;t.start.offset++,t.start.column++,t.end=pl(t.start,o.content),t.source=t.source.slice(1,-1)}const l=e[3]?e[3].slice(1).split("."):[];return a&&l.push("prop"),"bind"===u&&r&&l.includes("sync")&&Dl("COMPILER_V_BIND_SYNC",t,s,r.loc.source)&&(u="model",l.splice(l.indexOf("sync"),1)),{type:7,name:u,exp:o&&{type:4,content:o.content,isStatic:!1,constType:0,loc:o.loc},arg:r,modifiers:l,loc:s}}return!t.inVPre&&ic(i,"v-")&&uc(t,26),{type:6,name:i,value:o&&{type:2,content:o.content,loc:o.loc},loc:s}}function Zl(t){const e=ec(t);let n;const r=t.source[0],i='"'===r||"'"===r;if(i){oc(t,1);const e=t.source.indexOf(r);-1===e?n=tc(t,t.source.length,4):(n=tc(t,e,4),oc(t,1))}else{const e=/^[^\t\r\n\f >]+/.exec(t.source);if(!e)return;const r=/["'<=`]/g;let i;while(i=r.exec(e[0]))uc(t,18,i.index);n=tc(t,e[0].length,4)}return{content:n,isQuoted:i,loc:nc(t,e)}}function Jl(t,e){const[n,r]=t.options.delimiters,i=t.source.indexOf(r,n.length);if(-1===i)return void uc(t,25);const o=ec(t);oc(t,n.length);const s=ec(t),a=ec(t),u=i-n.length,l=t.source.slice(0,u),c=tc(t,u,e),h=c.trim(),f=c.indexOf(h);f>0&&vl(s,l,f);const d=u-(c.length-h.length-f);return vl(a,l,d),oc(t,r.length),{type:5,content:{type:4,isStatic:!1,constType:0,content:h,loc:nc(t,s,a)},loc:nc(t,o)}}function Ql(t,e){const n=3===e?["]]>"]:["<",t.options.delimiters[0]];let r=t.source.length;for(let s=0;s<n.length;s++){const e=t.source.indexOf(n[s],1);-1!==e&&r>e&&(r=e)}const i=ec(t),o=tc(t,r,e);return{type:2,content:o,loc:nc(t,i)}}function tc(t,e,n){const r=t.source.slice(0,e);return oc(t,e),2===n||3===n||-1===r.indexOf("&")?r:t.options.decodeEntities(r,4===n)}function ec(t){const{column:e,line:n,offset:r}=t;return{column:e,line:n,offset:r}}function nc(t,e,n){return n=n||ec(t),{start:e,end:n,source:t.originalSource.slice(e.offset,n.offset)}}function rc(t){return t[t.length-1]}function ic(t,e){return t.startsWith(e)}function oc(t,e){const{source:n}=t;vl(t,n,e),t.source=n.slice(e)}function sc(t){const e=/^[\t\r\n\f ]+/.exec(t.source);e&&oc(t,e[0].length)}function ac(t,e,n){return pl(e,t.originalSource.slice(e.offset,n),n)}function uc(t,e,n,r=ec(t)){n&&(r.offset+=n,r.column+=n),t.options.onError(nu(e,{start:r,end:r,source:""}))}function lc(t,e,n){const r=t.source;switch(e){case 0:if(ic(r,"</"))for(let t=n.length-1;t>=0;--t)if(cc(r,n[t].tag))return!0;break;case 1:case 2:{const t=rc(n);if(t&&cc(r,t.tag))return!0;break}case 3:if(ic(r,"]]>"))return!0;break}return!r}function cc(t,e){return ic(t,"</")&&t.slice(2,2+e.length).toLowerCase()===e.toLowerCase()&&/[\t\r\n\f />]/.test(t[2+e.length]||">")}function hc(t,e){dc(t,e,fc(t,t.children[0]))}function fc(t,e){const{children:n}=t;return 1===n.length&&1===e.type&&!Tl(e)}function dc(t,e,n=!1){const{children:r}=t,o=r.length;let s=0;for(let i=0;i<r.length;i++){const t=r[i];if(1===t.type&&0===t.tagType){const r=n?0:pc(t,e);if(r>0){if(r>=2){t.codegenNode.patchFlag="-1",t.codegenNode=e.hoist(t.codegenNode),s++;continue}}else{const n=t.codegenNode;if(13===n.type){const r=yc(n);if((!r||512===r||1===r)&&gc(t,e)>=2){const r=_c(t);r&&(n.props=e.hoist(r))}n.dynamicProps&&(n.dynamicProps=e.hoist(n.dynamicProps))}}}else 12===t.type&&pc(t.content,e)>=2&&(t.codegenNode=e.hoist(t.codegenNode),s++);if(1===t.type){const n=1===t.tagType;n&&e.scopes.vSlot++,dc(t,e),n&&e.scopes.vSlot--}else if(11===t.type)dc(t,e,1===t.children.length);else if(9===t.type)for(let n=0;n<t.branches.length;n++)dc(t.branches[n],e,1===t.branches[n].children.length)}s&&e.transformHoist&&e.transformHoist(r,e,t),s&&s===o&&1===t.type&&0===t.tagType&&t.codegenNode&&13===t.codegenNode.type&&(0,i.kJ)(t.codegenNode.children)&&(t.codegenNode.children=e.hoist(zu(t.codegenNode.children)))}function pc(t,e){const{constantCache:n}=e;switch(t.type){case 1:if(0!==t.tagType)return 0;const r=n.get(t);if(void 0!==r)return r;const o=t.codegenNode;if(13!==o.type)return 0;if(o.isBlock&&"svg"!==t.tag&&"foreignObject"!==t.tag)return 0;const s=yc(o);if(s)return n.set(t,0),0;{let r=3;const i=gc(t,e);if(0===i)return n.set(t,0),0;i<r&&(r=i);for(let o=0;o<t.children.length;o++){const i=pc(t.children[o],e);if(0===i)return n.set(t,0),0;i<r&&(r=i)}if(r>1)for(let o=0;o<t.props.length;o++){const i=t.props[o];if(7===i.type&&"bind"===i.name&&i.exp){const o=pc(i.exp,e);if(0===o)return n.set(t,0),0;o<r&&(r=o)}}return o.isBlock&&(e.removeHelper(uu),e.removeHelper(Rl(e.inSSR,o.isComponent)),o.isBlock=!1,e.helper(Sl(e.inSSR,o.isComponent))),n.set(t,r),r}case 2:case 3:return 3;case 9:case 11:case 10:return 0;case 5:case 12:return pc(t.content,e);case 4:return t.constType;case 8:let a=3;for(let n=0;n<t.children.length;n++){const r=t.children[n];if((0,i.HD)(r)||(0,i.yk)(r))continue;const o=pc(r,e);if(0===o)return 0;o<a&&(a=o)}return a;default:return 0}}const vc=new Set([Au,Ou,wu,Iu]);function mc(t,e){if(14===t.type&&!(0,i.HD)(t.callee)&&vc.has(t.callee)){const n=t.arguments[0];if(4===n.type)return pc(n,e);if(14===n.type)return mc(n,e)}return 0}function gc(t,e){let n=3;const r=_c(t);if(r&&15===r.type){const{properties:t}=r;for(let r=0;r<t.length;r++){const{key:i,value:o}=t[r],s=pc(i,e);if(0===s)return s;let a;if(s<n&&(n=s),a=4===o.type?pc(o,e):14===o.type?mc(o,e):0,0===a)return a;a<n&&(n=a)}}return n}function _c(t){const e=t.codegenNode;if(13===e.type)return e.props}function yc(t){const e=t.patchFlag;return e?parseInt(e,10):void 0}function bc(t,{filename:e="",prefixIdentifiers:n=!1,hoistStatic:r=!1,cacheHandlers:o=!1,nodeTransforms:s=[],directiveTransforms:a={},transformHoist:u=null,isBuiltInComponent:l=i.dG,isCustomElement:c=i.dG,expressionPlugins:h=[],scopeId:f=null,slotted:d=!0,ssr:p=!1,inSSR:v=!1,ssrCssVars:m="",bindingMetadata:g=i.kT,inline:_=!1,isTS:y=!1,onError:b=tu,onWarn:E=eu,compatConfig:x}){const T=e.replace(/\?.*$/,"").match(/([^/\\]+)\.\w+$/),S={selfName:T&&(0,i.kC)((0,i._A)(T[1])),prefixIdentifiers:n,hoistStatic:r,cacheHandlers:o,nodeTransforms:s,directiveTransforms:a,transformHoist:u,isBuiltInComponent:l,isCustomElement:c,expressionPlugins:h,scopeId:f,slotted:d,ssr:p,inSSR:v,ssrCssVars:m,bindingMetadata:g,inline:_,isTS:y,onError:b,onWarn:E,compatConfig:x,root:t,helpers:new Map,components:new Set,directives:new Set,hoists:[],imports:[],constantCache:new Map,temps:0,cached:0,identifiers:Object.create(null),scopes:{vFor:0,vSlot:0,vPre:0,vOnce:0},parent:null,currentNode:t,childIndex:0,inVOnce:!1,helper(t){const e=S.helpers.get(t)||0;return S.helpers.set(t,e+1),t},removeHelper(t){const e=S.helpers.get(t);if(e){const n=e-1;n?S.helpers.set(t,n):S.helpers.delete(t)}},helperString(t){return`_${ju[S.helper(t)]}`},replaceNode(t){S.parent.children[S.childIndex]=S.currentNode=t},removeNode(t){const e=S.parent.children,n=t?e.indexOf(t):S.currentNode?S.childIndex:-1;t&&t!==S.currentNode?S.childIndex>n&&(S.childIndex--,S.onNodeRemoved()):(S.currentNode=null,S.onNodeRemoved()),S.parent.children.splice(n,1)},onNodeRemoved:()=>{},addIdentifiers(t){},removeIdentifiers(t){},hoist(t){(0,i.HD)(t)&&(t=Ku(t)),S.hoists.push(t);const e=Ku(`_hoisted_${S.hoists.length}`,!1,t.loc,2);return e.hoisted=t,e},cache(t,e=!1){return el(S.cached++,t,e)}};return S.filters=new Set,S}function Ec(t,e){const n=bc(t,e);Sc(t,n),e.hoistStatic&&hc(t,n),e.ssr||xc(t,n),t.helpers=[...n.helpers.keys()],t.components=[...n.components],t.directives=[...n.directives],t.imports=n.imports,t.hoists=n.hoists,t.temps=n.temps,t.cached=n.cached,t.filters=[...n.filters]}function xc(t,e){const{helper:n}=e,{children:r}=t;if(1===r.length){const n=r[0];if(fc(t,n)&&n.codegenNode){const r=n.codegenNode;13===r.type&&Cl(r,e),t.codegenNode=r}else t.codegenNode=n}else if(r.length>1){let r=64;i.m[64];0,t.codegenNode=Wu(e,n(ru),void 0,t.children,r+"",void 0,void 0,!0,void 0,!1)}}function Tc(t,e){let n=0;const r=()=>{n--};for(;n<t.children.length;n++){const o=t.children[n];(0,i.HD)(o)||(e.parent=t,e.childIndex=n,e.onNodeRemoved=r,Sc(o,e))}}function Sc(t,e){e.currentNode=t;const{nodeTransforms:n}=e,r=[];for(let s=0;s<n.length;s++){const o=n[s](t,e);if(o&&((0,i.kJ)(o)?r.push(...o):r.push(o)),!e.currentNode)return;t=e.currentNode}switch(t.type){case 3:e.ssr||e.helper(du);break;case 5:e.ssr||e.helper(Su);break;case 9:for(let n=0;n<t.branches.length;n++)Sc(t.branches[n],e);break;case 10:case 11:case 1:case 0:Tc(t,e);break}e.currentNode=t;let o=r.length;while(o--)r[o]()}function Rc(t,e){const n=(0,i.HD)(t)?e=>e===t:e=>t.test(e);return(t,r)=>{if(1===t.type){const{props:i}=t;if(3===t.tagType&&i.some(El))return;const o=[];for(let s=0;s<i.length;s++){const a=i[s];if(7===a.type&&n(a.name)){i.splice(s,1),s--;const n=e(t,a,r);n&&o.push(n)}}return o}}}const Ac="/*#__PURE__*/";function Oc(t,{mode:e="function",prefixIdentifiers:n="module"===e,sourceMap:r=!1,filename:i="template.vue.html",scopeId:o=null,optimizeImports:s=!1,runtimeGlobalName:a="Vue",runtimeModuleName:u="vue",ssrRuntimeModuleName:l="vue/server-renderer",ssr:c=!1,isTS:h=!1,inSSR:f=!1}){const d={mode:e,prefixIdentifiers:n,sourceMap:r,filename:i,scopeId:o,optimizeImports:s,runtimeGlobalName:a,runtimeModuleName:u,ssrRuntimeModuleName:l,ssr:c,isTS:h,inSSR:f,source:t.loc.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(t){return`_${ju[t]}`},push(t,e){d.code+=t},indent(){p(++d.indentLevel)},deindent(t=!1){t?--d.indentLevel:p(--d.indentLevel)},newline(){p(d.indentLevel)}};function p(t){d.push("\n"+" ".repeat(t))}return d}function wc(t,e={}){const n=Oc(t,e);e.onContextCreated&&e.onContextCreated(n);const{mode:r,push:i,prefixIdentifiers:o,indent:s,deindent:a,newline:u,scopeId:l,ssr:c}=n,h=t.helpers.length>0,f=!o&&"module"!==r,d=n;Ic(t,d);const p=c?"ssrRender":"render",v=c?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"],m=v.join(", ");if(i(`function ${p}(${m}) {`),s(),f&&(i("with (_ctx) {"),s(),h&&(i(`const { ${t.helpers.map((t=>`${ju[t]}: _${ju[t]}`)).join(", ")} } = _Vue`),i("\n"),u())),t.components.length&&(Pc(t.components,"component",n),(t.directives.length||t.temps>0)&&u()),t.directives.length&&(Pc(t.directives,"directive",n),t.temps>0&&u()),t.filters&&t.filters.length&&(u(),Pc(t.filters,"filter",n),u()),t.temps>0){i("let ");for(let e=0;e<t.temps;e++)i(`${e>0?", ":""}_temp${e}`)}return(t.components.length||t.directives.length||t.temps)&&(i("\n"),u()),c||i("return "),t.codegenNode?Dc(t.codegenNode,n):i("null"),f&&(a(),i("}")),a(),i("}"),{ast:t,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function Ic(t,e){const{ssr:n,prefixIdentifiers:r,push:i,newline:o,runtimeModuleName:s,runtimeGlobalName:a,ssrRuntimeModuleName:u}=e,l=a,c=t=>`${ju[t]}: _${ju[t]}`;if(t.helpers.length>0&&(i(`const _Vue = ${l}\n`),t.hoists.length)){const e=[hu,fu,du,pu,vu].filter((e=>t.helpers.includes(e))).map(c).join(", ");i(`const { ${e} } = _Vue\n`)}Cc(t.hoists,e),o(),i("return ")}function Pc(t,e,{helper:n,push:r,newline:i,isTS:o}){const s=n("filter"===e?yu:"component"===e?mu:_u);for(let a=0;a<t.length;a++){let n=t[a];const u=n.endsWith("__self");u&&(n=n.slice(0,-6)),r(`const ${Il(n,e)} = ${s}(${JSON.stringify(n)}${u?", true":""})${o?"!":""}`),a<t.length-1&&i()}}function Cc(t,e){if(!t.length)return;e.pure=!0;const{push:n,newline:r,helper:i,scopeId:o,mode:s}=e;r();for(let a=0;a<t.length;a++){const i=t[a];i&&(n(`const _hoisted_${a+1} = `),Dc(i,e),r())}e.pure=!1}function Nc(t,e){const n=t.length>3||!1;e.push("["),n&&e.indent(),Mc(t,e,n),n&&e.deindent(),e.push("]")}function Mc(t,e,n=!1,r=!0){const{push:o,newline:s}=e;for(let a=0;a<t.length;a++){const u=t[a];(0,i.HD)(u)?o(u):(0,i.kJ)(u)?Nc(u,e):Dc(u,e),a<t.length-1&&(n?(r&&o(","),s()):r&&o(", "))}}function Dc(t,e){if((0,i.HD)(t))e.push(t);else if((0,i.yk)(t))e.push(e.helper(t));else switch(t.type){case 1:case 9:case 11:Dc(t.codegenNode,e);break;case 2:Lc(t,e);break;case 4:Fc(t,e);break;case 5:Bc(t,e);break;case 12:Dc(t.codegenNode,e);break;case 8:Uc(t,e);break;case 3:kc(t,e);break;case 13:Xc(t,e);break;case 14:Hc(t,e);break;case 15:Vc(t,e);break;case 17:Yc(t,e);break;case 18:Wc(t,e);break;case 19:zc(t,e);break;case 20:$c(t,e);break;case 21:Mc(t.body,e,!0,!1);break;case 22:break;case 23:break;case 24:break;case 25:break;case 26:break;case 10:break;default:0}}function Lc(t,e){e.push(JSON.stringify(t.content),t)}function Fc(t,e){const{content:n,isStatic:r}=t;e.push(r?JSON.stringify(n):n,t)}function Bc(t,e){const{push:n,helper:r,pure:i}=e;i&&n(Ac),n(`${r(Su)}(`),Dc(t.content,e),n(")")}function Uc(t,e){for(let n=0;n<t.children.length;n++){const r=t.children[n];(0,i.HD)(r)?e.push(r):Dc(r,e)}}function Gc(t,e){const{push:n}=e;if(8===t.type)n("["),Uc(t,e),n("]");else if(t.isStatic){const e=al(t.content)?t.content:JSON.stringify(t.content);n(e,t)}else n(`[${t.content}]`,t)}function kc(t,e){const{push:n,helper:r,pure:i}=e;i&&n(Ac),n(`${r(du)}(${JSON.stringify(t.content)})`,t)}function Xc(t,e){const{push:n,helper:r,pure:i}=e,{tag:o,props:s,children:a,patchFlag:u,dynamicProps:l,directives:c,isBlock:h,disableTracking:f,isComponent:d}=t;c&&n(r(bu)+"("),h&&n(`(${r(uu)}(${f?"true":""}), `),i&&n(Ac);const p=h?Rl(e.inSSR,d):Sl(e.inSSR,d);n(r(p)+"(",t),Mc(jc([o,s,a,u,l]),e),n(")"),h&&n(")"),c&&(n(", "),Dc(c,e),n(")"))}function jc(t){let e=t.length;while(e--)if(null!=t[e])break;return t.slice(0,e+1).map((t=>t||"null"))}function Hc(t,e){const{push:n,helper:r,pure:o}=e,s=(0,i.HD)(t.callee)?t.callee:r(t.callee);o&&n(Ac),n(s+"(",t),Mc(t.arguments,e),n(")")}function Vc(t,e){const{push:n,indent:r,deindent:i,newline:o}=e,{properties:s}=t;if(!s.length)return void n("{}",t);const a=s.length>1||!1;n(a?"{":"{ "),a&&r();for(let u=0;u<s.length;u++){const{key:t,value:r}=s[u];Gc(t,e),n(": "),Dc(r,e),u<s.length-1&&(n(","),o())}a&&i(),n(a?"}":" }")}function Yc(t,e){Nc(t.elements,e)}function Wc(t,e){const{push:n,indent:r,deindent:o}=e,{params:s,returns:a,body:u,newline:l,isSlot:c}=t;c&&n(`_${ju[Bu]}(`),n("(",t),(0,i.kJ)(s)?Mc(s,e):s&&Dc(s,e),n(") => "),(l||u)&&(n("{"),r()),a?(l&&n("return "),(0,i.kJ)(a)?Nc(a,e):Dc(a,e)):u&&Dc(u,e),(l||u)&&(o(),n("}")),c&&(t.isNonScopedSlot&&n(", undefined, true"),n(")"))}function zc(t,e){const{test:n,consequent:r,alternate:i,newline:o}=t,{push:s,indent:a,deindent:u,newline:l}=e;if(4===n.type){const t=!al(n.content);t&&s("("),Fc(n,e),t&&s(")")}else s("("),Dc(n,e),s(")");o&&a(),e.indentLevel++,o||s(" "),s("? "),Dc(r,e),e.indentLevel--,o&&l(),o||s(" "),s(": ");const c=19===i.type;c||e.indentLevel++,Dc(i,e),c||e.indentLevel--,o&&u(!0)}function $c(t,e){const{push:n,helper:r,indent:i,deindent:o,newline:s}=e;n(`_cache[${t.index}] || (`),t.isVNode&&(i(),n(`${r(Du)}(-1),`),s()),n(`_cache[${t.index}] = `),Dc(t.value,e),t.isVNode&&(n(","),s(),n(`${r(Du)}(1),`),s(),n(`_cache[${t.index}]`),o()),n(")")}new RegExp("\\b"+"do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments,typeof,void".split(",").join("\\b|\\b")+"\\b");const qc=Rc(/^(if|else|else-if)$/,((t,e,n)=>Kc(t,e,n,((t,e,r)=>{const i=n.parent.children;let o=i.indexOf(t),s=0;while(o-- >=0){const t=i[o];t&&9===t.type&&(s+=t.branches.length)}return()=>{if(r)t.codegenNode=Jc(e,s,n);else{const r=th(t.codegenNode);r.alternate=Jc(e,s+t.branches.length-1,n)}}}))));function Kc(t,e,n,r){if("else"!==e.name&&(!e.exp||!e.exp.content.trim())){const r=e.exp?e.exp.loc:t.loc;n.onError(nu(28,e.loc)),e.exp=Ku("true",!1,r)}if("if"===e.name){const i=Zc(t,e),o={type:9,loc:t.loc,branches:[i]};if(n.replaceNode(o),r)return r(o,i,!0)}else{const i=n.parent.children;let o=i.indexOf(t);while(o-- >=-1){const s=i[o];if(!s||2!==s.type||s.content.trim().length){if(s&&9===s.type){"else-if"===e.name&&void 0===s.branches[s.branches.length-1].condition&&n.onError(nu(30,t.loc)),n.removeNode();const i=Zc(t,e);0,s.branches.push(i);const o=r&&r(s,i,!1);Sc(i,n),o&&o(),n.currentNode=null}else n.onError(nu(30,t.loc));break}n.removeNode(s)}}}function Zc(t,e){return{type:10,loc:t.loc,condition:"else"===e.name?void 0:e.exp,children:3!==t.tagType||ml(t,"for")?[t]:t.children,userKey:gl(t,"key")}}function Jc(t,e,n){return t.condition?tl(t.condition,Qc(t,e,n),Ju(n.helper(du),['""',"true"])):Qc(t,e,n)}function Qc(t,e,n){const{helper:r}=n,o=qu("key",Ku(`${e}`,!1,Vu,2)),{children:s}=t,a=s[0],u=1!==s.length||1!==a.type;if(u){if(1===s.length&&11===a.type){const t=a.codegenNode;return wl(t,o,n),t}{let e=64;i.m[64];return Wu(n,r(ru),$u([o]),s,e+"",void 0,void 0,!0,!1,!1,t.loc)}}{const t=a.codegenNode,e=Pl(t);return 13===e.type&&Cl(e,n),wl(e,o,n),t}}function th(t){while(1)if(19===t.type){if(19!==t.alternate.type)return t;t=t.alternate}else 20===t.type&&(t=t.value)}const eh=Rc("for",((t,e,n)=>{const{helper:r,removeHelper:i}=n;return nh(t,e,n,(e=>{const o=Ju(r(Eu),[e.source]),s=ml(t,"memo"),a=gl(t,"key"),u=a&&(6===a.type?Ku(a.value.content,!0):a.exp),l=a?qu("key",u):null,c=4===e.source.type&&e.source.constType>0,h=c?64:a?128:256;return e.codegenNode=Wu(n,r(ru),void 0,o,h+"",void 0,void 0,!0,!c,!1,t.loc),()=>{let a;const h=xl(t),{children:f}=e;const d=1!==f.length||1!==f[0].type,p=Tl(t)?t:h&&1===t.children.length&&Tl(t.children[0])?t.children[0]:null;if(p?(a=p.codegenNode,h&&l&&wl(a,l,n)):d?a=Wu(n,r(ru),l?$u([l]):void 0,t.children,"64",void 0,void 0,!0,void 0,!1):(a=f[0].codegenNode,h&&l&&wl(a,l,n),a.isBlock!==!c&&(a.isBlock?(i(uu),i(Rl(n.inSSR,a.isComponent))):i(Sl(n.inSSR,a.isComponent))),a.isBlock=!c,a.isBlock?(r(uu),r(Rl(n.inSSR,a.isComponent))):r(Sl(n.inSSR,a.isComponent))),s){const t=Qu(uh(e.parseResult,[Ku("_cached")]));t.body=nl([Zu(["const _memo = (",s.exp,")"]),Zu(["if (_cached",...u?[" && _cached.key === ",u]:[],` && ${n.helperString(Xu)}(_cached, _memo)) return _cached`]),Zu(["const _item = ",a]),Ku("_item.memo = _memo"),Ku("return _item")]),o.arguments.push(t,Ku("_cache"),Ku(String(n.cached++)))}else o.arguments.push(Qu(uh(e.parseResult),a,!0))}}))}));function nh(t,e,n,r){if(!e.exp)return void n.onError(nu(31,e.loc));const i=sh(e.exp,n);if(!i)return void n.onError(nu(32,e.loc));const{addIdentifiers:o,removeIdentifiers:s,scopes:a}=n,{source:u,value:l,key:c,index:h}=i,f={type:11,loc:e.loc,source:u,valueAlias:l,keyAlias:c,objectIndexAlias:h,parseResult:i,children:xl(t)?t.children:[t]};n.replaceNode(f),a.vFor++;const d=r&&r(f);return()=>{a.vFor--,d&&d()}}const rh=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,ih=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,oh=/^\(|\)$/g;function sh(t,e){const n=t.loc,r=t.content,i=r.match(rh);if(!i)return;const[,o,s]=i,a={source:ah(n,s.trim(),r.indexOf(s,o.length)),value:void 0,key:void 0,index:void 0};let u=o.trim().replace(oh,"").trim();const l=o.indexOf(u),c=u.match(ih);if(c){u=u.replace(ih,"").trim();const t=c[1].trim();let e;if(t&&(e=r.indexOf(t,l+u.length),a.key=ah(n,t,e)),c[2]){const i=c[2].trim();i&&(a.index=ah(n,i,r.indexOf(i,a.key?e+t.length:l+u.length)))}}return u&&(a.value=ah(n,u,l)),a}function ah(t,e,n){return Ku(e,!1,dl(t,n,e.length))}function uh({value:t,key:e,index:n},r=[]){return lh([t,e,n,...r])}function lh(t){let e=t.length;while(e--)if(t[e])break;return t.slice(0,e+1).map(((t,e)=>t||Ku("_".repeat(e+1),!1)))}const ch=Ku("undefined",!1),hh=(t,e)=>{if(1===t.type&&(1===t.tagType||3===t.tagType)){const n=ml(t,"slot");if(n)return n.exp,e.scopes.vSlot++,()=>{e.scopes.vSlot--}}},fh=(t,e,n)=>Qu(t,e,!1,!0,e.length?e[0].loc:n);function dh(t,e,n=fh){e.helper(Bu);const{children:r,loc:i}=t,o=[],s=[];let a=e.scopes.vSlot>0||e.scopes.vFor>0;const u=ml(t,"slot",!0);if(u){const{arg:t,exp:e}=u;t&&!rl(t)&&(a=!0),o.push(qu(t||Ku("default",!0),n(e,r,i)))}let l=!1,c=!1;const h=[],f=new Set;for(let v=0;v<r.length;v++){const t=r[v];let i;if(!xl(t)||!(i=ml(t,"slot",!0))){3!==t.type&&h.push(t);continue}if(u){e.onError(nu(37,i.loc));break}l=!0;const{children:d,loc:p}=t,{arg:m=Ku("default",!0),exp:g,loc:_}=i;let y;rl(m)?y=m?m.content:"default":a=!0;const b=n(g,d,p);let E,x,T;if(E=ml(t,"if"))a=!0,s.push(tl(E.exp,ph(m,b),ch));else if(x=ml(t,/^else(-if)?$/,!0)){let t,n=v;while(n--)if(t=r[n],3!==t.type)break;if(t&&xl(t)&&ml(t,"if")){r.splice(v,1),v--;let t=s[s.length-1];while(19===t.alternate.type)t=t.alternate;t.alternate=x.exp?tl(x.exp,ph(m,b),ch):ph(m,b)}else e.onError(nu(30,x.loc))}else if(T=ml(t,"for")){a=!0;const t=T.parseResult||sh(T.exp,e);t?s.push(Ju(e.helper(Eu),[t.source,Qu(uh(t),ph(m,b),!0)])):e.onError(nu(32,T.loc))}else{if(y){if(f.has(y)){e.onError(nu(38,_));continue}f.add(y),"default"===y&&(c=!0)}o.push(qu(m,b))}}if(!u){const t=(t,r)=>{const o=n(t,r,i);return e.compatConfig&&(o.isNonScopedSlot=!0),qu("default",o)};l?h.length&&h.some((t=>mh(t)))&&(c?e.onError(nu(39,h[0].loc)):o.push(t(void 0,h))):o.push(t(void 0,r))}const d=a?2:vh(t.children)?3:1;let p=$u(o.concat(qu("_",Ku(d+"",!1))),i);return s.length&&(p=Ju(e.helper(Tu),[p,zu(s)])),{slots:p,hasDynamicSlots:a}}function ph(t,e){return $u([qu("name",t),qu("fn",e)])}function vh(t){for(let e=0;e<t.length;e++){const n=t[e];switch(n.type){case 1:if(2===n.tagType||vh(n.children))return!0;break;case 9:if(vh(n.branches))return!0;break;case 10:case 11:if(vh(n.children))return!0;break}}return!1}function mh(t){return 2!==t.type&&12!==t.type||(2===t.type?!!t.content.trim():mh(t.content))}const gh=new WeakMap,_h=(t,e)=>function(){if(t=e.currentNode,1!==t.type||0!==t.tagType&&1!==t.tagType)return;const{tag:n,props:r}=t,o=1===t.tagType;let s=o?yh(t,e):`"${n}"`;const a=(0,i.Kn)(s)&&s.callee===gu;let u,l,c,h,f,d,p=0,v=a||s===iu||s===ou||!o&&("svg"===n||"foreignObject"===n);if(r.length>0){const n=bh(t,e);u=n.props,p=n.patchFlag,f=n.dynamicPropNames;const r=n.directives;d=r&&r.length?zu(r.map((t=>Th(t,e)))):void 0,n.shouldUseBlock&&(v=!0)}if(t.children.length>0){s===su&&(v=!0,p|=1024);const n=o&&s!==iu&&s!==su;if(n){const{slots:n,hasDynamicSlots:r}=dh(t,e);l=n,r&&(p|=1024)}else if(1===t.children.length&&s!==iu){const n=t.children[0],r=n.type,i=5===r||8===r;i&&0===pc(n,e)&&(p|=1),l=i||2===r?n:t.children}else l=t.children}0!==p&&(c=String(p),f&&f.length&&(h=Sh(f))),t.codegenNode=Wu(e,s,u,l,c,h,d,!!v,!1,o,t.loc)};function yh(t,e,n=!1){let{tag:r}=t;const i=Rh(r),o=gl(t,"is");if(o)if(i||Ml("COMPILER_IS_ON_ELEMENT",e)){const t=6===o.type?o.value&&Ku(o.value.content,!0):o.exp;if(t)return Ju(e.helper(gu),[t])}else 6===o.type&&o.value.content.startsWith("vue:")&&(r=o.value.content.slice(4));const s=!i&&ml(t,"is");if(s&&s.exp)return Ju(e.helper(gu),[s.exp]);const a=ol(r)||e.isBuiltInComponent(r);return a?(n||e.helper(a),a):(e.helper(mu),e.components.add(r),Il(r,"component"))}function bh(t,e,n=t.props,r=!1){const{tag:o,loc:s,children:a}=t,u=1===t.tagType;let l=[];const c=[],h=[],f=a.length>0;let d=!1,p=0,v=!1,m=!1,g=!1,_=!1,y=!1,b=!1;const E=[],x=({key:t,value:n})=>{if(rl(t)){const r=t.content,o=(0,i.F7)(r);if(u||!o||"onclick"===r.toLowerCase()||"onUpdate:modelValue"===r||(0,i.Gg)(r)||(_=!0),o&&(0,i.Gg)(r)&&(b=!0),20===n.type||(4===n.type||8===n.type)&&pc(n,e)>0)return;"ref"===r?v=!0:"class"===r?m=!0:"style"===r?g=!0:"key"===r||E.includes(r)||E.push(r),!u||"class"!==r&&"style"!==r||E.includes(r)||E.push(r)}else y=!0};for(let S=0;S<n.length;S++){const a=n[S];if(6===a.type){const{loc:t,name:n,value:r}=a;let i=!0;if("ref"===n&&(v=!0,e.scopes.vFor>0&&l.push(qu(Ku("ref_for",!0),Ku("true")))),"is"===n&&(Rh(o)||r&&r.content.startsWith("vue:")||Ml("COMPILER_IS_ON_ELEMENT",e)))continue;l.push(qu(Ku(n,!0,dl(t,0,n.length)),Ku(r?r.content:"",i,r?r.loc:t)))}else{const{name:n,arg:p,exp:v,loc:m}=a,g="bind"===n,_="on"===n;if("slot"===n){u||e.onError(nu(40,m));continue}if("once"===n||"memo"===n)continue;if("is"===n||g&&_l(p,"is")&&(Rh(o)||Ml("COMPILER_IS_ON_ELEMENT",e)))continue;if(_&&r)continue;if((g&&_l(p,"key")||_&&f&&_l(p,"vue:before-update"))&&(d=!0),g&&_l(p,"ref")&&e.scopes.vFor>0&&l.push(qu(Ku("ref_for",!0),Ku("true"))),!p&&(g||_)){if(y=!0,v)if(l.length&&(c.push($u(Eh(l),s)),l=[]),g){if(Ml("COMPILER_V_BIND_OBJECT_ORDER",e)){c.unshift(v);continue}c.push(v)}else c.push({type:14,loc:m,callee:e.helper(Pu),arguments:[v]});else e.onError(nu(g?34:35,m));continue}const b=e.directiveTransforms[n];if(b){const{props:n,needRuntime:o}=b(a,t,e);!r&&n.forEach(x),l.push(...n),o&&(h.push(a),(0,i.yk)(o)&&gh.set(a,o))}else h.push(a),f&&(d=!0)}}let T;if(c.length?(l.length&&c.push($u(Eh(l),s)),T=c.length>1?Ju(e.helper(Ru),c,s):c[0]):l.length&&(T=$u(Eh(l),s)),y?p|=16:(m&&!u&&(p|=2),g&&!u&&(p|=4),E.length&&(p|=8),_&&(p|=32)),d||0!==p&&32!==p||!(v||b||h.length>0)||(p|=512),!e.inSSR&&T)switch(T.type){case 15:let t=-1,n=-1,r=!1;for(let e=0;e<T.properties.length;e++){const i=T.properties[e].key;rl(i)?"class"===i.content?t=e:"style"===i.content&&(n=e):i.isHandlerKey||(r=!0)}const i=T.properties[t],o=T.properties[n];r?T=Ju(e.helper(wu),[T]):(i&&!rl(i.value)&&(i.value=Ju(e.helper(Au),[i.value])),!o||rl(o.value)||!g&&17!==o.value.type||(o.value=Ju(e.helper(Ou),[o.value])));break;case 14:break;default:T=Ju(e.helper(wu),[Ju(e.helper(Iu),[T])]);break}return{props:T,directives:h,patchFlag:p,dynamicPropNames:E,shouldUseBlock:d}}function Eh(t){const e=new Map,n=[];for(let r=0;r<t.length;r++){const o=t[r];if(8===o.key.type||!o.key.isStatic){n.push(o);continue}const s=o.key.content,a=e.get(s);a?("style"===s||"class"===s||(0,i.F7)(s))&&xh(a,o):(e.set(s,o),n.push(o))}return n}function xh(t,e){17===t.value.type?t.value.elements.push(e.value):t.value=zu([t.value,e.value],t.loc)}function Th(t,e){const n=[],r=gh.get(t);r?n.push(e.helperString(r)):(e.helper(_u),e.directives.add(t.name),n.push(Il(t.name,"directive")));const{loc:i}=t;if(t.exp&&n.push(t.exp),t.arg&&(t.exp||n.push("void 0"),n.push(t.arg)),Object.keys(t.modifiers).length){t.arg||(t.exp||n.push("void 0"),n.push("void 0"));const e=Ku("true",!1,i);n.push($u(t.modifiers.map((t=>qu(t,e))),i))}return zu(n,t.loc)}function Sh(t){let e="[";for(let n=0,r=t.length;n<r;n++)e+=JSON.stringify(t[n]),n<r-1&&(e+=", ");return e+"]"}function Rh(t){return"component"===t||"Component"===t}const Ah=t=>{const e=Object.create(null);return n=>{const r=e[n];return r||(e[n]=t(n))}},Oh=/-(\w)/g,wh=Ah((t=>t.replace(Oh,((t,e)=>e?e.toUpperCase():"")))),Ih=(t,e)=>{if(Tl(t)){const{children:n,loc:r}=t,{slotName:i,slotProps:o}=Ph(t,e),s=[e.prefixIdentifiers?"_ctx.$slots":"$slots",i,"{}","undefined","true"];let a=2;o&&(s[2]=o,a=3),n.length&&(s[3]=Qu([],n,!1,!1,r),a=4),e.scopeId&&!e.slotted&&(a=5),s.splice(a),t.codegenNode=Ju(e.helper(xu),s,r)}};function Ph(t,e){let n,r='"default"';const i=[];for(let o=0;o<t.props.length;o++){const e=t.props[o];6===e.type?e.value&&("name"===e.name?r=JSON.stringify(e.value.content):(e.name=wh(e.name),i.push(e))):"bind"===e.name&&_l(e.arg,"name")?e.exp&&(r=e.exp):("bind"===e.name&&e.arg&&rl(e.arg)&&(e.arg.content=wh(e.arg.content)),i.push(e))}if(i.length>0){const{props:r,directives:o}=bh(t,e,i);n=r,o.length&&e.onError(nu(36,o[0].loc))}return{slotName:r,slotProps:n}}const Ch=/^\s*([\w$_]+|(async\s*)?\([^)]*?\))\s*=>|^\s*(async\s+)?function(?:\s+[\w$]+)?\s*\(/,Nh=(t,e,n,r)=>{const{loc:o,modifiers:s,arg:a}=t;let u;if(t.exp||s.length||n.onError(nu(35,o)),4===a.type)if(a.isStatic){let t=a.content;t.startsWith("vue:")&&(t=`vnode-${t.slice(4)}`),u=Ku((0,i.hR)((0,i._A)(t)),!0,a.loc)}else u=Zu([`${n.helperString(Mu)}(`,a,")"]);else u=a,u.children.unshift(`${n.helperString(Mu)}(`),u.children.push(")");let l=t.exp;l&&!l.content.trim()&&(l=void 0);let c=n.cacheHandlers&&!l&&!n.inVOnce;if(l){const t=fl(l.content),e=!(t||Ch.test(l.content)),n=l.content.includes(";");0,(e||c&&t)&&(l=Zu([`${e?"$event":"(...args)"} => ${n?"{":"("}`,l,n?"}":")"]))}let h={props:[qu(u,l||Ku("() => {}",!1,o))]};return r&&(h=r(h)),c&&(h.props[0].value=n.cache(h.props[0].value)),h.props.forEach((t=>t.key.isHandlerKey=!0)),h},Mh=(t,e,n)=>{const{exp:r,modifiers:o,loc:s}=t,a=t.arg;return 4!==a.type?(a.children.unshift("("),a.children.push(') || ""')):a.isStatic||(a.content=`${a.content} || ""`),o.includes("camel")&&(4===a.type?a.isStatic?a.content=(0,i._A)(a.content):a.content=`${n.helperString(Cu)}(${a.content})`:(a.children.unshift(`${n.helperString(Cu)}(`),a.children.push(")"))),n.inSSR||(o.includes("prop")&&Dh(a,"."),o.includes("attr")&&Dh(a,"^")),!r||4===r.type&&!r.content.trim()?(n.onError(nu(34,s)),{props:[qu(a,Ku("",!0,s))]}):{props:[qu(a,r)]}},Dh=(t,e)=>{4===t.type?t.isStatic?t.content=e+t.content:t.content=`\`${e}\${${t.content}}\``:(t.children.unshift(`'${e}' + (`),t.children.push(")"))},Lh=(t,e)=>{if(0===t.type||1===t.type||11===t.type||10===t.type)return()=>{const n=t.children;let r,i=!1;for(let t=0;t<n.length;t++){const e=n[t];if(bl(e)){i=!0;for(let i=t+1;i<n.length;i++){const o=n[i];if(!bl(o)){r=void 0;break}r||(r=n[t]={type:8,loc:e.loc,children:[e]}),r.children.push(" + ",o),n.splice(i,1),i--}}}if(i&&(1!==n.length||0!==t.type&&(1!==t.type||0!==t.tagType||t.props.find((t=>7===t.type&&!e.directiveTransforms[t.name]))||"template"===t.tag)))for(let t=0;t<n.length;t++){const r=n[t];if(bl(r)||8===r.type){const i=[];2===r.type&&" "===r.content||i.push(r),e.ssr||0!==pc(r,e)||i.push("1"),n[t]={type:12,content:r,loc:r.loc,codegenNode:Ju(e.helper(pu),i)}}}}},Fh=new WeakSet,Bh=(t,e)=>{if(1===t.type&&ml(t,"once",!0)){if(Fh.has(t)||e.inVOnce)return;return Fh.add(t),e.inVOnce=!0,e.helper(Du),()=>{e.inVOnce=!1;const t=e.currentNode;t.codegenNode&&(t.codegenNode=e.cache(t.codegenNode,!0))}}},Uh=(t,e,n)=>{const{exp:r,arg:i}=t;if(!r)return n.onError(nu(41,t.loc)),Gh();const o=r.loc.source,s=4===r.type?r.content:o;n.bindingMetadata[o];const a=!1;if(!s.trim()||!fl(s)&&!a)return n.onError(nu(42,r.loc)),Gh();const u=i||Ku("modelValue",!0),l=i?rl(i)?`onUpdate:${i.content}`:Zu(['"onUpdate:" + ',i]):"onUpdate:modelValue";let c;const h=n.isTS?"($event: any)":"$event";c=Zu([`${h} => ((`,r,") = $event)"]);const f=[qu(u,t.exp),qu(l,c)];if(t.modifiers.length&&1===e.tagType){const e=t.modifiers.map((t=>(al(t)?t:JSON.stringify(t))+": true")).join(", "),n=i?rl(i)?`${i.content}Modifiers`:Zu([i,' + "Modifiers"']):"modelModifiers";f.push(qu(n,Ku(`{ ${e} }`,!1,t.loc,2)))}return Gh(f)};function Gh(t=[]){return{props:t}}const kh=/[\w).+\-_$\]]/,Xh=(t,e)=>{Ml("COMPILER_FILTER",e)&&(5===t.type&&jh(t.content,e),1===t.type&&t.props.forEach((t=>{7===t.type&&"for"!==t.name&&t.exp&&jh(t.exp,e)})))};function jh(t,e){if(4===t.type)Hh(t,e);else for(let n=0;n<t.children.length;n++){const r=t.children[n];"object"===typeof r&&(4===r.type?Hh(r,e):8===r.type?jh(t,e):5===r.type&&jh(r.content,e))}}function Hh(t,e){const n=t.content;let r,i,o,s,a=!1,u=!1,l=!1,c=!1,h=0,f=0,d=0,p=0,v=[];for(o=0;o<n.length;o++)if(i=r,r=n.charCodeAt(o),a)39===r&&92!==i&&(a=!1);else if(u)34===r&&92!==i&&(u=!1);else if(l)96===r&&92!==i&&(l=!1);else if(c)47===r&&92!==i&&(c=!1);else if(124!==r||124===n.charCodeAt(o+1)||124===n.charCodeAt(o-1)||h||f||d){switch(r){case 34:u=!0;break;case 39:a=!0;break;case 96:l=!0;break;case 40:d++;break;case 41:d--;break;case 91:f++;break;case 93:f--;break;case 123:h++;break;case 125:h--;break}if(47===r){let t,e=o-1;for(;e>=0;e--)if(t=n.charAt(e)," "!==t)break;t&&kh.test(t)||(c=!0)}}else void 0===s?(p=o+1,s=n.slice(0,o).trim()):m();function m(){v.push(n.slice(p,o).trim()),p=o+1}if(void 0===s?s=n.slice(0,o).trim():0!==p&&m(),v.length){for(o=0;o<v.length;o++)s=Vh(s,v[o],e);t.content=s}}function Vh(t,e,n){n.helper(yu);const r=e.indexOf("(");if(r<0)return n.filters.add(e),`${Il(e,"filter")}(${t})`;{const i=e.slice(0,r),o=e.slice(r+1);return n.filters.add(i),`${Il(i,"filter")}(${t}${")"!==o?","+o:o}`}}const Yh=new WeakSet,Wh=(t,e)=>{if(1===t.type){const n=ml(t,"memo");if(!n||Yh.has(t))return;return Yh.add(t),()=>{const r=t.codegenNode||e.currentNode.codegenNode;r&&13===r.type&&(1!==t.tagType&&Cl(r,e),t.codegenNode=Ju(e.helper(ku),[n.exp,Qu(void 0,r),"_cache",String(e.cached++)]))}}};function zh(t){return[[Bh,qc,Wh,eh,Xh,Ih,_h,hh,Lh],{on:Nh,bind:Mh,model:Uh}]}function $h(t,e={}){const n=e.onError||tu,r="module"===e.mode;!0===e.prefixIdentifiers?n(nu(46)):r&&n(nu(47));const o=!1;e.cacheHandlers&&n(nu(48)),e.scopeId&&!r&&n(nu(49));const s=(0,i.HD)(t)?Ul(t,e):t,[a,u]=zh();return Ec(s,(0,i.l7)({},e,{prefixIdentifiers:o,nodeTransforms:[...a,...e.nodeTransforms||[]],directiveTransforms:(0,i.l7)({},u,e.directiveTransforms||{})})),wc(s,(0,i.l7)({},e,{prefixIdentifiers:o}))}const qh=()=>({props:[]}),Kh=Symbol(""),Zh=Symbol(""),Jh=Symbol(""),Qh=Symbol(""),tf=Symbol(""),ef=Symbol(""),nf=Symbol(""),rf=Symbol(""),of=Symbol(""),sf=Symbol("");let af;function uf(t,e=!1){return af||(af=document.createElement("div")),e?(af.innerHTML=`<div foo="${t.replace(/"/g,""")}">`,af.children[0].getAttribute("foo")):(af.innerHTML=t,af.textContent)}Hu({[Kh]:"vModelRadio",[Zh]:"vModelCheckbox",[Jh]:"vModelText",[Qh]:"vModelSelect",[tf]:"vModelDynamic",[ef]:"withModifiers",[nf]:"withKeys",[rf]:"vShow",[of]:"Transition",[sf]:"TransitionGroup"});const lf=(0,i.fY)("style,iframe,script,noscript",!0),cf={isVoidTag:i.WB,isNativeTag:t=>(0,i.eS)(t)||(0,i.aN)(t),isPreTag:t=>"pre"===t,decodeEntities:uf,isBuiltInComponent:t=>il(t,"Transition")?of:il(t,"TransitionGroup")?sf:void 0,getNamespace(t,e){let n=e?e.ns:0;if(e&&2===n)if("annotation-xml"===e.tag){if("svg"===t)return 1;e.props.some((t=>6===t.type&&"encoding"===t.name&&null!=t.value&&("text/html"===t.value.content||"application/xhtml+xml"===t.value.content)))&&(n=0)}else/^m(?:[ions]|text)$/.test(e.tag)&&"mglyph"!==t&&"malignmark"!==t&&(n=0);else e&&1===n&&("foreignObject"!==e.tag&&"desc"!==e.tag&&"title"!==e.tag||(n=0));if(0===n){if("svg"===t)return 1;if("math"===t)return 2}return n},getTextMode({tag:t,ns:e}){if(0===e){if("textarea"===t||"title"===t)return 1;if(lf(t))return 2}return 0}},hf=t=>{1===t.type&&t.props.forEach(((e,n)=>{6===e.type&&"style"===e.name&&e.value&&(t.props[n]={type:7,name:"bind",arg:Ku("style",!0,e.loc),exp:ff(e.value.content,e.loc),modifiers:[],loc:e.loc})}))},ff=(t,e)=>{const n=(0,i.yL)(t);return Ku(JSON.stringify(n),!1,e,3)};function df(t,e){return nu(t,e,void 0)}const pf=(t,e,n)=>{const{exp:r,loc:i}=t;return r||n.onError(df(50,i)),e.children.length&&(n.onError(df(51,i)),e.children.length=0),{props:[qu(Ku("innerHTML",!0,i),r||Ku("",!0))]}},vf=(t,e,n)=>{const{exp:r,loc:i}=t;return r||n.onError(df(52,i)),e.children.length&&(n.onError(df(53,i)),e.children.length=0),{props:[qu(Ku("textContent",!0),r?Ju(n.helperString(Su),[r],i):Ku("",!0))]}},mf=(t,e,n)=>{const r=Uh(t,e,n);if(!r.props.length||1===e.tagType)return r;t.arg&&n.onError(df(55,t.arg.loc));const{tag:i}=e,o=n.isCustomElement(i);if("input"===i||"textarea"===i||"select"===i||o){let s=Jh,a=!1;if("input"===i||o){const r=gl(e,"type");if(r){if(7===r.type)s=tf;else if(r.value)switch(r.value.content){case"radio":s=Kh;break;case"checkbox":s=Zh;break;case"file":a=!0,n.onError(df(56,t.loc));break;default:break}}else yl(e)&&(s=tf)}else"select"===i&&(s=Qh);a||(r.needRuntime=n.helper(s))}else n.onError(df(54,t.loc));return r.props=r.props.filter((t=>!(4===t.key.type&&"modelValue"===t.key.content))),r},gf=(0,i.fY)("passive,once,capture"),_f=(0,i.fY)("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),yf=(0,i.fY)("left,right"),bf=(0,i.fY)("onkeyup,onkeydown,onkeypress",!0),Ef=(t,e,n,r)=>{const i=[],o=[],s=[];for(let a=0;a<e.length;a++){const u=e[a];"native"===u&&Dl("COMPILER_V_ON_NATIVE",n,r)||gf(u)?s.push(u):yf(u)?rl(t)?bf(t.content)?i.push(u):o.push(u):(i.push(u),o.push(u)):_f(u)?o.push(u):i.push(u)}return{keyModifiers:i,nonKeyModifiers:o,eventOptionModifiers:s}},xf=(t,e)=>{const n=rl(t)&&"onclick"===t.content.toLowerCase();return n?Ku(e,!0):4!==t.type?Zu(["(",t,`) === "onClick" ? "${e}" : (`,t,")"]):t},Tf=(t,e,n)=>Nh(t,e,n,(e=>{const{modifiers:r}=t;if(!r.length)return e;let{key:o,value:s}=e.props[0];const{keyModifiers:a,nonKeyModifiers:u,eventOptionModifiers:l}=Ef(o,r,n,t.loc);if(u.includes("right")&&(o=xf(o,"onContextmenu")),u.includes("middle")&&(o=xf(o,"onMouseup")),u.length&&(s=Ju(n.helper(ef),[s,JSON.stringify(u)])),!a.length||rl(o)&&!bf(o.content)||(s=Ju(n.helper(nf),[s,JSON.stringify(a)])),l.length){const t=l.map(i.kC).join("");o=rl(o)?Ku(`${o.content}${t}`,!0):Zu(["(",o,`) + "${t}"`])}return{props:[qu(o,s)]}})),Sf=(t,e,n)=>{const{exp:r,loc:i}=t;return r||n.onError(df(58,i)),{props:[],needRuntime:n.helper(rf)}};const Rf=(t,e)=>{1!==t.type||0!==t.tagType||"script"!==t.tag&&"style"!==t.tag||(e.onError(df(60,t.loc)),e.removeNode())},Af=[hf],Of={cloak:qh,html:pf,text:vf,model:mf,on:Tf,show:Sf};function wf(t,e={}){return $h(t,(0,i.l7)({},cf,e,{nodeTransforms:[Rf,...Af,...e.nodeTransforms||[]],directiveTransforms:(0,i.l7)({},Of,e.directiveTransforms||{}),transformHoist:null}))}const If=Object.create(null);function Pf(t,e){if(!(0,i.HD)(t)){if(!t.nodeType)return i.dG;t=t.innerHTML}const n=t,o=If[n];if(o)return o;if("#"===t[0]){const e=document.querySelector(t);0,t=e?e.innerHTML:""}const{code:s}=wf(t,(0,i.l7)({hoistStatic:!0,onError:void 0,onWarn:i.dG},e));const a=new Function("Vue",s)(r);return a._rc=!0,If[n]=a}Ui(Pf)},9980:function(t,e,n){(function(e,r){t.exports=r(n(4865),n(1474))})("undefined"!==typeof self&&self,(function(t,e){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="fb15")}({"00ee":function(t,e,n){var r=n("b622"),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},"0366":function(t,e,n){var r=n("1c0b");t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},"057f":function(t,e,n){var r=n("fc6a"),i=n("241c").f,o={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],a=function(t){try{return i(t)}catch(e){return s.slice()}};t.exports.f=function(t){return s&&"[object Window]"==o.call(t)?a(t):i(r(t))}},"06cf":function(t,e,n){var r=n("83ab"),i=n("d1e7"),o=n("5c6c"),s=n("fc6a"),a=n("c04e"),u=n("5135"),l=n("0cfb"),c=Object.getOwnPropertyDescriptor;e.f=r?c:function(t,e){if(t=s(t),e=a(e,!0),l)try{return c(t,e)}catch(n){}if(u(t,e))return o(!i.f.call(t,e),t[e])}},"0cfb":function(t,e,n){var r=n("83ab"),i=n("d039"),o=n("cc12");t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},"13d5":function(t,e,n){"use strict";var r=n("23e7"),i=n("d58f").left,o=n("a640"),s=n("ae40"),a=o("reduce"),u=s("reduce",{1:0});r({target:"Array",proto:!0,forced:!a||!u},{reduce:function(t){return i(this,t,arguments.length,arguments.length>1?arguments[1]:void 0)}})},"14c3":function(t,e,n){var r=n("c6b6"),i=n("9263");t.exports=function(t,e){var n=t.exec;if("function"===typeof n){var o=n.call(t,e);if("object"!==typeof o)throw TypeError("RegExp exec method returned something other than an Object or null");return o}if("RegExp"!==r(t))throw TypeError("RegExp#exec called on incompatible receiver");return i.call(t,e)}},"159b":function(t,e,n){var r=n("da84"),i=n("fdbc"),o=n("17c2"),s=n("9112");for(var a in i){var u=r[a],l=u&&u.prototype;if(l&&l.forEach!==o)try{s(l,"forEach",o)}catch(c){l.forEach=o}}},"17c2":function(t,e,n){"use strict";var r=n("b727").forEach,i=n("a640"),o=n("ae40"),s=i("forEach"),a=o("forEach");t.exports=s&&a?[].forEach:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}},"1be4":function(t,e,n){var r=n("d066");t.exports=r("document","documentElement")},"1c0b":function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},"1c7e":function(t,e,n){var r=n("b622"),i=r("iterator"),o=!1;try{var s=0,a={next:function(){return{done:!!s++}},return:function(){o=!0}};a[i]=function(){return this},Array.from(a,(function(){throw 2}))}catch(u){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var r={};r[i]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(u){}return n}},"1d80":function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},"1dde":function(t,e,n){var r=n("d039"),i=n("b622"),o=n("2d00"),s=i("species");t.exports=function(t){return o>=51||!r((function(){var e=[],n=e.constructor={};return n[s]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},"23cb":function(t,e,n){var r=n("a691"),i=Math.max,o=Math.min;t.exports=function(t,e){var n=r(t);return n<0?i(n+e,0):o(n,e)}},"23e7":function(t,e,n){var r=n("da84"),i=n("06cf").f,o=n("9112"),s=n("6eeb"),a=n("ce4e"),u=n("e893"),l=n("94ca");t.exports=function(t,e){var n,c,h,f,d,p,v=t.target,m=t.global,g=t.stat;if(c=m?r:g?r[v]||a(v,{}):(r[v]||{}).prototype,c)for(h in e){if(d=e[h],t.noTargetGet?(p=i(c,h),f=p&&p.value):f=c[h],n=l(m?h:v+(g?".":"#")+h,t.forced),!n&&void 0!==f){if(typeof d===typeof f)continue;u(d,f)}(t.sham||f&&f.sham)&&o(d,"sham",!0),s(c,h,d,t)}}},"241c":function(t,e,n){var r=n("ca84"),i=n("7839"),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},"25f0":function(t,e,n){"use strict";var r=n("6eeb"),i=n("825a"),o=n("d039"),s=n("ad6d"),a="toString",u=RegExp.prototype,l=u[a],c=o((function(){return"/a/b"!=l.call({source:"a",flags:"b"})})),h=l.name!=a;(c||h)&&r(RegExp.prototype,a,(function(){var t=i(this),e=String(t.source),n=t.flags,r=String(void 0===n&&t instanceof RegExp&&!("flags"in u)?s.call(t):n);return"/"+e+"/"+r}),{unsafe:!0})},"2ca0":function(t,e,n){"use strict";var r=n("23e7"),i=n("06cf").f,o=n("50c4"),s=n("5a34"),a=n("1d80"),u=n("ab13"),l=n("c430"),c="".startsWith,h=Math.min,f=u("startsWith"),d=!l&&!f&&!!function(){var t=i(String.prototype,"startsWith");return t&&!t.writable}();r({target:"String",proto:!0,forced:!d&&!f},{startsWith:function(t){var e=String(a(this));s(t);var n=o(h(arguments.length>1?arguments[1]:void 0,e.length)),r=String(t);return c?c.call(e,r,n):e.slice(n,n+r.length)===r}})},"2d00":function(t,e,n){var r,i,o=n("da84"),s=n("342f"),a=o.process,u=a&&a.versions,l=u&&u.v8;l?(r=l.split("."),i=r[0]+r[1]):s&&(r=s.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/),r&&(i=r[1]))),t.exports=i&&+i},"342f":function(t,e,n){var r=n("d066");t.exports=r("navigator","userAgent")||""},"35a1":function(t,e,n){var r=n("f5df"),i=n("3f8c"),o=n("b622"),s=o("iterator");t.exports=function(t){if(void 0!=t)return t[s]||t["@@iterator"]||i[r(t)]}},"37e8":function(t,e,n){var r=n("83ab"),i=n("9bf2"),o=n("825a"),s=n("df75");t.exports=r?Object.defineProperties:function(t,e){o(t);var n,r=s(e),a=r.length,u=0;while(a>u)i.f(t,n=r[u++],e[n]);return t}},"3bbe":function(t,e,n){var r=n("861d");t.exports=function(t){if(!r(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t}},"3ca3":function(t,e,n){"use strict";var r=n("6547").charAt,i=n("69f3"),o=n("7dd0"),s="String Iterator",a=i.set,u=i.getterFor(s);o(String,"String",(function(t){a(this,{type:s,string:String(t),index:0})}),(function(){var t,e=u(this),n=e.string,i=e.index;return i>=n.length?{value:void 0,done:!0}:(t=r(n,i),e.index+=t.length,{value:t,done:!1})}))},"3f8c":function(t,e){t.exports={}},4160:function(t,e,n){"use strict";var r=n("23e7"),i=n("17c2");r({target:"Array",proto:!0,forced:[].forEach!=i},{forEach:i})},"428f":function(t,e,n){var r=n("da84");t.exports=r},"44ad":function(t,e,n){var r=n("d039"),i=n("c6b6"),o="".split;t.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==i(t)?o.call(t,""):Object(t)}:Object},"44d2":function(t,e,n){var r=n("b622"),i=n("7c73"),o=n("9bf2"),s=r("unscopables"),a=Array.prototype;void 0==a[s]&&o.f(a,s,{configurable:!0,value:i(null)}),t.exports=function(t){a[s][t]=!0}},"44e7":function(t,e,n){var r=n("861d"),i=n("c6b6"),o=n("b622"),s=o("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[s])?!!e:"RegExp"==i(t))}},4930:function(t,e,n){var r=n("d039");t.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},"4d64":function(t,e,n){var r=n("fc6a"),i=n("50c4"),o=n("23cb"),s=function(t){return function(e,n,s){var a,u=r(e),l=i(u.length),c=o(s,l);if(t&&n!=n){while(l>c)if(a=u[c++],a!=a)return!0}else for(;l>c;c++)if((t||c in u)&&u[c]===n)return t||c||0;return!t&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},"4de4":function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").filter,o=n("1dde"),s=n("ae40"),a=o("filter"),u=s("filter");r({target:"Array",proto:!0,forced:!a||!u},{filter:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"4df4":function(t,e,n){"use strict";var r=n("0366"),i=n("7b0b"),o=n("9bdd"),s=n("e95a"),a=n("50c4"),u=n("8418"),l=n("35a1");t.exports=function(t){var e,n,c,h,f,d,p=i(t),v="function"==typeof this?this:Array,m=arguments.length,g=m>1?arguments[1]:void 0,_=void 0!==g,y=l(p),b=0;if(_&&(g=r(g,m>2?arguments[2]:void 0,2)),void 0==y||v==Array&&s(y))for(e=a(p.length),n=new v(e);e>b;b++)d=_?g(p[b],b):p[b],u(n,b,d);else for(h=y.call(p),f=h.next,n=new v;!(c=f.call(h)).done;b++)d=_?o(h,g,[c.value,b],!0):c.value,u(n,b,d);return n.length=b,n}},"4fad":function(t,e,n){var r=n("23e7"),i=n("6f53").entries;r({target:"Object",stat:!0},{entries:function(t){return i(t)}})},"50c4":function(t,e,n){var r=n("a691"),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},5135:function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},5319:function(t,e,n){"use strict";var r=n("d784"),i=n("825a"),o=n("7b0b"),s=n("50c4"),a=n("a691"),u=n("1d80"),l=n("8aa5"),c=n("14c3"),h=Math.max,f=Math.min,d=Math.floor,p=/\$([$&'`]|\d\d?|<[^>]*>)/g,v=/\$([$&'`]|\d\d?)/g,m=function(t){return void 0===t?t:String(t)};r("replace",2,(function(t,e,n,r){var g=r.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE,_=r.REPLACE_KEEPS_$0,y=g?"$":"$0";return[function(n,r){var i=u(this),o=void 0==n?void 0:n[t];return void 0!==o?o.call(n,i,r):e.call(String(i),n,r)},function(t,r){if(!g&&_||"string"===typeof r&&-1===r.indexOf(y)){var o=n(e,t,this,r);if(o.done)return o.value}var u=i(t),d=String(this),p="function"===typeof r;p||(r=String(r));var v=u.global;if(v){var E=u.unicode;u.lastIndex=0}var x=[];while(1){var T=c(u,d);if(null===T)break;if(x.push(T),!v)break;var S=String(T[0]);""===S&&(u.lastIndex=l(d,s(u.lastIndex),E))}for(var R="",A=0,O=0;O<x.length;O++){T=x[O];for(var w=String(T[0]),I=h(f(a(T.index),d.length),0),P=[],C=1;C<T.length;C++)P.push(m(T[C]));var N=T.groups;if(p){var M=[w].concat(P,I,d);void 0!==N&&M.push(N);var D=String(r.apply(void 0,M))}else D=b(w,d,I,P,N,r);I>=A&&(R+=d.slice(A,I)+D,A=I+w.length)}return R+d.slice(A)}];function b(t,n,r,i,s,a){var u=r+t.length,l=i.length,c=v;return void 0!==s&&(s=o(s),c=p),e.call(a,c,(function(e,o){var a;switch(o.charAt(0)){case"$":return"$";case"&":return t;case"`":return n.slice(0,r);case"'":return n.slice(u);case"<":a=s[o.slice(1,-1)];break;default:var c=+o;if(0===c)return e;if(c>l){var h=d(c/10);return 0===h?e:h<=l?void 0===i[h-1]?o.charAt(1):i[h-1]+o.charAt(1):e}a=i[c-1]}return void 0===a?"":a}))}}))},5692:function(t,e,n){var r=n("c430"),i=n("c6cd");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.6.5",mode:r?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},"56ef":function(t,e,n){var r=n("d066"),i=n("241c"),o=n("7418"),s=n("825a");t.exports=r("Reflect","ownKeys")||function(t){var e=i.f(s(t)),n=o.f;return n?e.concat(n(t)):e}},"5a34":function(t,e,n){var r=n("44e7");t.exports=function(t){if(r(t))throw TypeError("The method doesn't accept regular expressions");return t}},"5c6c":function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},"5db7":function(t,e,n){"use strict";var r=n("23e7"),i=n("a2bf"),o=n("7b0b"),s=n("50c4"),a=n("1c0b"),u=n("65f0");r({target:"Array",proto:!0},{flatMap:function(t){var e,n=o(this),r=s(n.length);return a(t),e=u(n,0),e.length=i(e,n,n,r,0,1,t,arguments.length>1?arguments[1]:void 0),e}})},6547:function(t,e,n){var r=n("a691"),i=n("1d80"),o=function(t){return function(e,n){var o,s,a=String(i(e)),u=r(n),l=a.length;return u<0||u>=l?t?"":void 0:(o=a.charCodeAt(u),o<55296||o>56319||u+1===l||(s=a.charCodeAt(u+1))<56320||s>57343?t?a.charAt(u):o:t?a.slice(u,u+2):s-56320+(o-55296<<10)+65536)}};t.exports={codeAt:o(!1),charAt:o(!0)}},"65f0":function(t,e,n){var r=n("861d"),i=n("e8b5"),o=n("b622"),s=o("species");t.exports=function(t,e){var n;return i(t)&&(n=t.constructor,"function"!=typeof n||n!==Array&&!i(n.prototype)?r(n)&&(n=n[s],null===n&&(n=void 0)):n=void 0),new(void 0===n?Array:n)(0===e?0:e)}},"69f3":function(t,e,n){var r,i,o,s=n("7f9a"),a=n("da84"),u=n("861d"),l=n("9112"),c=n("5135"),h=n("f772"),f=n("d012"),d=a.WeakMap,p=function(t){return o(t)?i(t):r(t,{})},v=function(t){return function(e){var n;if(!u(e)||(n=i(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}};if(s){var m=new d,g=m.get,_=m.has,y=m.set;r=function(t,e){return y.call(m,t,e),e},i=function(t){return g.call(m,t)||{}},o=function(t){return _.call(m,t)}}else{var b=h("state");f[b]=!0,r=function(t,e){return l(t,b,e),e},i=function(t){return c(t,b)?t[b]:{}},o=function(t){return c(t,b)}}t.exports={set:r,get:i,has:o,enforce:p,getterFor:v}},"6eeb":function(t,e,n){var r=n("da84"),i=n("9112"),o=n("5135"),s=n("ce4e"),a=n("8925"),u=n("69f3"),l=u.get,c=u.enforce,h=String(String).split("String");(t.exports=function(t,e,n,a){var u=!!a&&!!a.unsafe,l=!!a&&!!a.enumerable,f=!!a&&!!a.noTargetGet;"function"==typeof n&&("string"!=typeof e||o(n,"name")||i(n,"name",e),c(n).source=h.join("string"==typeof e?e:"")),t!==r?(u?!f&&t[e]&&(l=!0):delete t[e],l?t[e]=n:i(t,e,n)):l?t[e]=n:s(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&l(this).source||a(this)}))},"6f53":function(t,e,n){var r=n("83ab"),i=n("df75"),o=n("fc6a"),s=n("d1e7").f,a=function(t){return function(e){var n,a=o(e),u=i(a),l=u.length,c=0,h=[];while(l>c)n=u[c++],r&&!s.call(a,n)||h.push(t?[n,a[n]]:a[n]);return h}};t.exports={entries:a(!0),values:a(!1)}},"73d9":function(t,e,n){var r=n("44d2");r("flatMap")},7418:function(t,e){e.f=Object.getOwnPropertySymbols},"746f":function(t,e,n){var r=n("428f"),i=n("5135"),o=n("e538"),s=n("9bf2").f;t.exports=function(t){var e=r.Symbol||(r.Symbol={});i(e,t)||s(e,t,{value:o.f(t)})}},7839:function(t,e){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},"7b0b":function(t,e,n){var r=n("1d80");t.exports=function(t){return Object(r(t))}},"7c73":function(t,e,n){var r,i=n("825a"),o=n("37e8"),s=n("7839"),a=n("d012"),u=n("1be4"),l=n("cc12"),c=n("f772"),h=">",f="<",d="prototype",p="script",v=c("IE_PROTO"),m=function(){},g=function(t){return f+p+h+t+f+"/"+p+h},_=function(t){t.write(g("")),t.close();var e=t.parentWindow.Object;return t=null,e},y=function(){var t,e=l("iframe"),n="java"+p+":";return e.style.display="none",u.appendChild(e),e.src=String(n),t=e.contentWindow.document,t.open(),t.write(g("document.F=Object")),t.close(),t.F},b=function(){try{r=document.domain&&new ActiveXObject("htmlfile")}catch(e){}b=r?_(r):y();var t=s.length;while(t--)delete b[d][s[t]];return b()};a[v]=!0,t.exports=Object.create||function(t,e){var n;return null!==t?(m[d]=i(t),n=new m,m[d]=null,n[v]=t):n=b(),void 0===e?n:o(n,e)}},"7dd0":function(t,e,n){"use strict";var r=n("23e7"),i=n("9ed3"),o=n("e163"),s=n("d2bb"),a=n("d44e"),u=n("9112"),l=n("6eeb"),c=n("b622"),h=n("c430"),f=n("3f8c"),d=n("ae93"),p=d.IteratorPrototype,v=d.BUGGY_SAFARI_ITERATORS,m=c("iterator"),g="keys",_="values",y="entries",b=function(){return this};t.exports=function(t,e,n,c,d,E,x){i(n,e,c);var T,S,R,A=function(t){if(t===d&&C)return C;if(!v&&t in I)return I[t];switch(t){case g:return function(){return new n(this,t)};case _:return function(){return new n(this,t)};case y:return function(){return new n(this,t)}}return function(){return new n(this)}},O=e+" Iterator",w=!1,I=t.prototype,P=I[m]||I["@@iterator"]||d&&I[d],C=!v&&P||A(d),N="Array"==e&&I.entries||P;if(N&&(T=o(N.call(new t)),p!==Object.prototype&&T.next&&(h||o(T)===p||(s?s(T,p):"function"!=typeof T[m]&&u(T,m,b)),a(T,O,!0,!0),h&&(f[O]=b))),d==_&&P&&P.name!==_&&(w=!0,C=function(){return P.call(this)}),h&&!x||I[m]===C||u(I,m,C),f[e]=C,d)if(S={values:A(_),keys:E?C:A(g),entries:A(y)},x)for(R in S)(v||w||!(R in I))&&l(I,R,S[R]);else r({target:e,proto:!0,forced:v||w},S);return S}},"7f9a":function(t,e,n){var r=n("da84"),i=n("8925"),o=r.WeakMap;t.exports="function"===typeof o&&/native code/.test(i(o))},"825a":function(t,e,n){var r=n("861d");t.exports=function(t){if(!r(t))throw TypeError(String(t)+" is not an object");return t}},"83ab":function(t,e,n){var r=n("d039");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},8418:function(t,e,n){"use strict";var r=n("c04e"),i=n("9bf2"),o=n("5c6c");t.exports=function(t,e,n){var s=r(e);s in t?i.f(t,s,o(0,n)):t[s]=n}},"861d":function(t,e){t.exports=function(t){return"object"===typeof t?null!==t:"function"===typeof t}},8875:function(t,e,n){var r,i,o;(function(n,s){i=[],r=s,o="function"===typeof r?r.apply(e,i):r,void 0===o||(t.exports=o)})("undefined"!==typeof self&&self,(function(){function t(){var e=Object.getOwnPropertyDescriptor(document,"currentScript");if(!e&&"currentScript"in document&&document.currentScript)return document.currentScript;if(e&&e.get!==t&&document.currentScript)return document.currentScript;try{throw new Error}catch(d){var n,r,i,o=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,s=/@([^@]*):(\d+):(\d+)\s*$/gi,a=o.exec(d.stack)||s.exec(d.stack),u=a&&a[1]||!1,l=a&&a[2]||!1,c=document.location.href.replace(document.location.hash,""),h=document.getElementsByTagName("script");u===c&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(l-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),i=n.replace(r,"$1").trim());for(var f=0;f<h.length;f++){if("interactive"===h[f].readyState)return h[f];if(h[f].src===u)return h[f];if(u===c&&h[f].innerHTML&&h[f].innerHTML.trim()===i)return h[f]}return null}}return t}))},8925:function(t,e,n){var r=n("c6cd"),i=Function.toString;"function"!=typeof r.inspectSource&&(r.inspectSource=function(t){return i.call(t)}),t.exports=r.inspectSource},"8aa5":function(t,e,n){"use strict";var r=n("6547").charAt;t.exports=function(t,e,n){return e+(n?r(t,e).length:1)}},"8bbf":function(e,n){e.exports=t},"90e3":function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++n+r).toString(36)}},9112:function(t,e,n){var r=n("83ab"),i=n("9bf2"),o=n("5c6c");t.exports=r?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},9263:function(t,e,n){"use strict";var r=n("ad6d"),i=n("9f7f"),o=RegExp.prototype.exec,s=String.prototype.replace,a=o,u=function(){var t=/a/,e=/b*/g;return o.call(t,"a"),o.call(e,"a"),0!==t.lastIndex||0!==e.lastIndex}(),l=i.UNSUPPORTED_Y||i.BROKEN_CARET,c=void 0!==/()??/.exec("")[1],h=u||c||l;h&&(a=function(t){var e,n,i,a,h=this,f=l&&h.sticky,d=r.call(h),p=h.source,v=0,m=t;return f&&(d=d.replace("y",""),-1===d.indexOf("g")&&(d+="g"),m=String(t).slice(h.lastIndex),h.lastIndex>0&&(!h.multiline||h.multiline&&"\n"!==t[h.lastIndex-1])&&(p="(?: "+p+")",m=" "+m,v++),n=new RegExp("^(?:"+p+")",d)),c&&(n=new RegExp("^"+p+"$(?!\\s)",d)),u&&(e=h.lastIndex),i=o.call(f?n:h,m),f?i?(i.input=i.input.slice(v),i[0]=i[0].slice(v),i.index=h.lastIndex,h.lastIndex+=i[0].length):h.lastIndex=0:u&&i&&(h.lastIndex=h.global?i.index+i[0].length:e),c&&i&&i.length>1&&s.call(i[0],n,(function(){for(a=1;a<arguments.length-2;a++)void 0===arguments[a]&&(i[a]=void 0)})),i}),t.exports=a},"94ca":function(t,e,n){var r=n("d039"),i=/#|\.prototype\./,o=function(t,e){var n=a[s(t)];return n==l||n!=u&&("function"==typeof e?r(e):!!e)},s=o.normalize=function(t){return String(t).replace(i,".").toLowerCase()},a=o.data={},u=o.NATIVE="N",l=o.POLYFILL="P";t.exports=o},"99af":function(t,e,n){"use strict";var r=n("23e7"),i=n("d039"),o=n("e8b5"),s=n("861d"),a=n("7b0b"),u=n("50c4"),l=n("8418"),c=n("65f0"),h=n("1dde"),f=n("b622"),d=n("2d00"),p=f("isConcatSpreadable"),v=9007199254740991,m="Maximum allowed index exceeded",g=d>=51||!i((function(){var t=[];return t[p]=!1,t.concat()[0]!==t})),_=h("concat"),y=function(t){if(!s(t))return!1;var e=t[p];return void 0!==e?!!e:o(t)},b=!g||!_;r({target:"Array",proto:!0,forced:b},{concat:function(t){var e,n,r,i,o,s=a(this),h=c(s,0),f=0;for(e=-1,r=arguments.length;e<r;e++)if(o=-1===e?s:arguments[e],y(o)){if(i=u(o.length),f+i>v)throw TypeError(m);for(n=0;n<i;n++,f++)n in o&&l(h,f,o[n])}else{if(f>=v)throw TypeError(m);l(h,f++,o)}return h.length=f,h}})},"9bdd":function(t,e,n){var r=n("825a");t.exports=function(t,e,n,i){try{return i?e(r(n)[0],n[1]):e(n)}catch(s){var o=t["return"];throw void 0!==o&&r(o.call(t)),s}}},"9bf2":function(t,e,n){var r=n("83ab"),i=n("0cfb"),o=n("825a"),s=n("c04e"),a=Object.defineProperty;e.f=r?a:function(t,e,n){if(o(t),e=s(e,!0),o(n),i)try{return a(t,e,n)}catch(r){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},"9ed3":function(t,e,n){"use strict";var r=n("ae93").IteratorPrototype,i=n("7c73"),o=n("5c6c"),s=n("d44e"),a=n("3f8c"),u=function(){return this};t.exports=function(t,e,n){var l=e+" Iterator";return t.prototype=i(r,{next:o(1,n)}),s(t,l,!1,!0),a[l]=u,t}},"9f7f":function(t,e,n){"use strict";var r=n("d039");function i(t,e){return RegExp(t,e)}e.UNSUPPORTED_Y=r((function(){var t=i("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),e.BROKEN_CARET=r((function(){var t=i("^r","gy");return t.lastIndex=2,null!=t.exec("str")}))},a2bf:function(t,e,n){"use strict";var r=n("e8b5"),i=n("50c4"),o=n("0366"),s=function(t,e,n,a,u,l,c,h){var f,d=u,p=0,v=!!c&&o(c,h,3);while(p<a){if(p in n){if(f=v?v(n[p],p,e):n[p],l>0&&r(f))d=s(t,e,f,i(f.length),d,l-1)-1;else{if(d>=9007199254740991)throw TypeError("Exceed the acceptable array length");t[d]=f}d++}p++}return d};t.exports=s},a352:function(t,n){t.exports=e},a434:function(t,e,n){"use strict";var r=n("23e7"),i=n("23cb"),o=n("a691"),s=n("50c4"),a=n("7b0b"),u=n("65f0"),l=n("8418"),c=n("1dde"),h=n("ae40"),f=c("splice"),d=h("splice",{ACCESSORS:!0,0:0,1:2}),p=Math.max,v=Math.min,m=9007199254740991,g="Maximum allowed length exceeded";r({target:"Array",proto:!0,forced:!f||!d},{splice:function(t,e){var n,r,c,h,f,d,_=a(this),y=s(_.length),b=i(t,y),E=arguments.length;if(0===E?n=r=0:1===E?(n=0,r=y-b):(n=E-2,r=v(p(o(e),0),y-b)),y+n-r>m)throw TypeError(g);for(c=u(_,r),h=0;h<r;h++)f=b+h,f in _&&l(c,h,_[f]);if(c.length=r,n<r){for(h=b;h<y-r;h++)f=h+r,d=h+n,f in _?_[d]=_[f]:delete _[d];for(h=y;h>y-r+n;h--)delete _[h-1]}else if(n>r)for(h=y-r;h>b;h--)f=h+r-1,d=h+n-1,f in _?_[d]=_[f]:delete _[d];for(h=0;h<n;h++)_[h+b]=arguments[h+2];return _.length=y-r+n,c}})},a4d3:function(t,e,n){"use strict";var r=n("23e7"),i=n("da84"),o=n("d066"),s=n("c430"),a=n("83ab"),u=n("4930"),l=n("fdbf"),c=n("d039"),h=n("5135"),f=n("e8b5"),d=n("861d"),p=n("825a"),v=n("7b0b"),m=n("fc6a"),g=n("c04e"),_=n("5c6c"),y=n("7c73"),b=n("df75"),E=n("241c"),x=n("057f"),T=n("7418"),S=n("06cf"),R=n("9bf2"),A=n("d1e7"),O=n("9112"),w=n("6eeb"),I=n("5692"),P=n("f772"),C=n("d012"),N=n("90e3"),M=n("b622"),D=n("e538"),L=n("746f"),F=n("d44e"),B=n("69f3"),U=n("b727").forEach,G=P("hidden"),k="Symbol",X="prototype",j=M("toPrimitive"),H=B.set,V=B.getterFor(k),Y=Object[X],W=i.Symbol,z=o("JSON","stringify"),$=S.f,q=R.f,K=x.f,Z=A.f,J=I("symbols"),Q=I("op-symbols"),tt=I("string-to-symbol-registry"),et=I("symbol-to-string-registry"),nt=I("wks"),rt=i.QObject,it=!rt||!rt[X]||!rt[X].findChild,ot=a&&c((function(){return 7!=y(q({},"a",{get:function(){return q(this,"a",{value:7}).a}})).a}))?function(t,e,n){var r=$(Y,e);r&&delete Y[e],q(t,e,n),r&&t!==Y&&q(Y,e,r)}:q,st=function(t,e){var n=J[t]=y(W[X]);return H(n,{type:k,tag:t,description:e}),a||(n.description=e),n},at=l?function(t){return"symbol"==typeof t}:function(t){return Object(t)instanceof W},ut=function(t,e,n){t===Y&&ut(Q,e,n),p(t);var r=g(e,!0);return p(n),h(J,r)?(n.enumerable?(h(t,G)&&t[G][r]&&(t[G][r]=!1),n=y(n,{enumerable:_(0,!1)})):(h(t,G)||q(t,G,_(1,{})),t[G][r]=!0),ot(t,r,n)):q(t,r,n)},lt=function(t,e){p(t);var n=m(e),r=b(n).concat(pt(n));return U(r,(function(e){a&&!ht.call(n,e)||ut(t,e,n[e])})),t},ct=function(t,e){return void 0===e?y(t):lt(y(t),e)},ht=function(t){var e=g(t,!0),n=Z.call(this,e);return!(this===Y&&h(J,e)&&!h(Q,e))&&(!(n||!h(this,e)||!h(J,e)||h(this,G)&&this[G][e])||n)},ft=function(t,e){var n=m(t),r=g(e,!0);if(n!==Y||!h(J,r)||h(Q,r)){var i=$(n,r);return!i||!h(J,r)||h(n,G)&&n[G][r]||(i.enumerable=!0),i}},dt=function(t){var e=K(m(t)),n=[];return U(e,(function(t){h(J,t)||h(C,t)||n.push(t)})),n},pt=function(t){var e=t===Y,n=K(e?Q:m(t)),r=[];return U(n,(function(t){!h(J,t)||e&&!h(Y,t)||r.push(J[t])})),r};if(u||(W=function(){if(this instanceof W)throw TypeError("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,e=N(t),n=function(t){this===Y&&n.call(Q,t),h(this,G)&&h(this[G],e)&&(this[G][e]=!1),ot(this,e,_(1,t))};return a&&it&&ot(Y,e,{configurable:!0,set:n}),st(e,t)},w(W[X],"toString",(function(){return V(this).tag})),w(W,"withoutSetter",(function(t){return st(N(t),t)})),A.f=ht,R.f=ut,S.f=ft,E.f=x.f=dt,T.f=pt,D.f=function(t){return st(M(t),t)},a&&(q(W[X],"description",{configurable:!0,get:function(){return V(this).description}}),s||w(Y,"propertyIsEnumerable",ht,{unsafe:!0}))),r({global:!0,wrap:!0,forced:!u,sham:!u},{Symbol:W}),U(b(nt),(function(t){L(t)})),r({target:k,stat:!0,forced:!u},{for:function(t){var e=String(t);if(h(tt,e))return tt[e];var n=W(e);return tt[e]=n,et[n]=e,n},keyFor:function(t){if(!at(t))throw TypeError(t+" is not a symbol");if(h(et,t))return et[t]},useSetter:function(){it=!0},useSimple:function(){it=!1}}),r({target:"Object",stat:!0,forced:!u,sham:!a},{create:ct,defineProperty:ut,defineProperties:lt,getOwnPropertyDescriptor:ft}),r({target:"Object",stat:!0,forced:!u},{getOwnPropertyNames:dt,getOwnPropertySymbols:pt}),r({target:"Object",stat:!0,forced:c((function(){T.f(1)}))},{getOwnPropertySymbols:function(t){return T.f(v(t))}}),z){var vt=!u||c((function(){var t=W();return"[null]"!=z([t])||"{}"!=z({a:t})||"{}"!=z(Object(t))}));r({target:"JSON",stat:!0,forced:vt},{stringify:function(t,e,n){var r,i=[t],o=1;while(arguments.length>o)i.push(arguments[o++]);if(r=e,(d(e)||void 0!==t)&&!at(t))return f(e)||(e=function(t,e){if("function"==typeof r&&(e=r.call(this,t,e)),!at(e))return e}),i[1]=e,z.apply(null,i)}})}W[X][j]||O(W[X],j,W[X].valueOf),F(W,k),C[G]=!0},a630:function(t,e,n){var r=n("23e7"),i=n("4df4"),o=n("1c7e"),s=!o((function(t){Array.from(t)}));r({target:"Array",stat:!0,forced:s},{from:i})},a640:function(t,e,n){"use strict";var r=n("d039");t.exports=function(t,e){var n=[][t];return!!n&&r((function(){n.call(null,e||function(){throw 1},1)}))}},a691:function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},ab13:function(t,e,n){var r=n("b622"),i=r("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[i]=!1,"/./"[t](e)}catch(r){}}return!1}},ac1f:function(t,e,n){"use strict";var r=n("23e7"),i=n("9263");r({target:"RegExp",proto:!0,forced:/./.exec!==i},{exec:i})},ad6d:function(t,e,n){"use strict";var r=n("825a");t.exports=function(){var t=r(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},ae40:function(t,e,n){var r=n("83ab"),i=n("d039"),o=n("5135"),s=Object.defineProperty,a={},u=function(t){throw t};t.exports=function(t,e){if(o(a,t))return a[t];e||(e={});var n=[][t],l=!!o(e,"ACCESSORS")&&e.ACCESSORS,c=o(e,0)?e[0]:u,h=o(e,1)?e[1]:void 0;return a[t]=!!n&&!i((function(){if(l&&!r)return!0;var t={length:-1};l?s(t,1,{enumerable:!0,get:u}):t[1]=1,n.call(t,c,h)}))}},ae93:function(t,e,n){"use strict";var r,i,o,s=n("e163"),a=n("9112"),u=n("5135"),l=n("b622"),c=n("c430"),h=l("iterator"),f=!1,d=function(){return this};[].keys&&(o=[].keys(),"next"in o?(i=s(s(o)),i!==Object.prototype&&(r=i)):f=!0),void 0==r&&(r={}),c||u(r,h)||a(r,h,d),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:f}},b041:function(t,e,n){"use strict";var r=n("00ee"),i=n("f5df");t.exports=r?{}.toString:function(){return"[object "+i(this)+"]"}},b0c0:function(t,e,n){var r=n("83ab"),i=n("9bf2").f,o=Function.prototype,s=o.toString,a=/^\s*function ([^ (]*)/,u="name";r&&!(u in o)&&i(o,u,{configurable:!0,get:function(){try{return s.call(this).match(a)[1]}catch(t){return""}}})},b622:function(t,e,n){var r=n("da84"),i=n("5692"),o=n("5135"),s=n("90e3"),a=n("4930"),u=n("fdbf"),l=i("wks"),c=r.Symbol,h=u?c:c&&c.withoutSetter||s;t.exports=function(t){return o(l,t)||(a&&o(c,t)?l[t]=c[t]:l[t]=h("Symbol."+t)),l[t]}},b64b:function(t,e,n){var r=n("23e7"),i=n("7b0b"),o=n("df75"),s=n("d039"),a=s((function(){o(1)}));r({target:"Object",stat:!0,forced:a},{keys:function(t){return o(i(t))}})},b727:function(t,e,n){var r=n("0366"),i=n("44ad"),o=n("7b0b"),s=n("50c4"),a=n("65f0"),u=[].push,l=function(t){var e=1==t,n=2==t,l=3==t,c=4==t,h=6==t,f=5==t||h;return function(d,p,v,m){for(var g,_,y=o(d),b=i(y),E=r(p,v,3),x=s(b.length),T=0,S=m||a,R=e?S(d,x):n?S(d,0):void 0;x>T;T++)if((f||T in b)&&(g=b[T],_=E(g,T,y),t))if(e)R[T]=_;else if(_)switch(t){case 3:return!0;case 5:return g;case 6:return T;case 2:u.call(R,g)}else if(c)return!1;return h?-1:l||c?c:R}};t.exports={forEach:l(0),map:l(1),filter:l(2),some:l(3),every:l(4),find:l(5),findIndex:l(6)}},c04e:function(t,e,n){var r=n("861d");t.exports=function(t,e){if(!r(t))return t;var n,i;if(e&&"function"==typeof(n=t.toString)&&!r(i=n.call(t)))return i;if("function"==typeof(n=t.valueOf)&&!r(i=n.call(t)))return i;if(!e&&"function"==typeof(n=t.toString)&&!r(i=n.call(t)))return i;throw TypeError("Can't convert object to primitive value")}},c430:function(t,e){t.exports=!1},c6b6:function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},c6cd:function(t,e,n){var r=n("da84"),i=n("ce4e"),o="__core-js_shared__",s=r[o]||i(o,{});t.exports=s},c740:function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").findIndex,o=n("44d2"),s=n("ae40"),a="findIndex",u=!0,l=s(a);a in[]&&Array(1)[a]((function(){u=!1})),r({target:"Array",proto:!0,forced:u||!l},{findIndex:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o(a)},c8ba:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}t.exports=n},c975:function(t,e,n){"use strict";var r=n("23e7"),i=n("4d64").indexOf,o=n("a640"),s=n("ae40"),a=[].indexOf,u=!!a&&1/[1].indexOf(1,-0)<0,l=o("indexOf"),c=s("indexOf",{ACCESSORS:!0,1:0});r({target:"Array",proto:!0,forced:u||!l||!c},{indexOf:function(t){return u?a.apply(this,arguments)||0:i(this,t,arguments.length>1?arguments[1]:void 0)}})},ca84:function(t,e,n){var r=n("5135"),i=n("fc6a"),o=n("4d64").indexOf,s=n("d012");t.exports=function(t,e){var n,a=i(t),u=0,l=[];for(n in a)!r(s,n)&&r(a,n)&&l.push(n);while(e.length>u)r(a,n=e[u++])&&(~o(l,n)||l.push(n));return l}},caad:function(t,e,n){"use strict";var r=n("23e7"),i=n("4d64").includes,o=n("44d2"),s=n("ae40"),a=s("indexOf",{ACCESSORS:!0,1:0});r({target:"Array",proto:!0,forced:!a},{includes:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o("includes")},cc12:function(t,e,n){var r=n("da84"),i=n("861d"),o=r.document,s=i(o)&&i(o.createElement);t.exports=function(t){return s?o.createElement(t):{}}},ce4e:function(t,e,n){var r=n("da84"),i=n("9112");t.exports=function(t,e){try{i(r,t,e)}catch(n){r[t]=e}return e}},d012:function(t,e){t.exports={}},d039:function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},d066:function(t,e,n){var r=n("428f"),i=n("da84"),o=function(t){return"function"==typeof t?t:void 0};t.exports=function(t,e){return arguments.length<2?o(r[t])||o(i[t]):r[t]&&r[t][e]||i[t]&&i[t][e]}},d1e7:function(t,e,n){"use strict";var r={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,o=i&&!r.call({1:2},1);e.f=o?function(t){var e=i(this,t);return!!e&&e.enumerable}:r},d28b:function(t,e,n){var r=n("746f");r("iterator")},d2bb:function(t,e,n){var r=n("825a"),i=n("3bbe");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set,t.call(n,[]),e=n instanceof Array}catch(o){}return function(n,o){return r(n),i(o),e?t.call(n,o):n.__proto__=o,n}}():void 0)},d3b7:function(t,e,n){var r=n("00ee"),i=n("6eeb"),o=n("b041");r||i(Object.prototype,"toString",o,{unsafe:!0})},d44e:function(t,e,n){var r=n("9bf2").f,i=n("5135"),o=n("b622"),s=o("toStringTag");t.exports=function(t,e,n){t&&!i(t=n?t:t.prototype,s)&&r(t,s,{configurable:!0,value:e})}},d58f:function(t,e,n){var r=n("1c0b"),i=n("7b0b"),o=n("44ad"),s=n("50c4"),a=function(t){return function(e,n,a,u){r(n);var l=i(e),c=o(l),h=s(l.length),f=t?h-1:0,d=t?-1:1;if(a<2)while(1){if(f in c){u=c[f],f+=d;break}if(f+=d,t?f<0:h<=f)throw TypeError("Reduce of empty array with no initial value")}for(;t?f>=0:h>f;f+=d)f in c&&(u=n(u,c[f],f,l));return u}};t.exports={left:a(!1),right:a(!0)}},d784:function(t,e,n){"use strict";n("ac1f");var r=n("6eeb"),i=n("d039"),o=n("b622"),s=n("9263"),a=n("9112"),u=o("species"),l=!i((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")})),c=function(){return"$0"==="a".replace(/./,"$0")}(),h=o("replace"),f=function(){return!!/./[h]&&""===/./[h]("a","$0")}(),d=!i((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));t.exports=function(t,e,n,h){var p=o(t),v=!i((function(){var e={};return e[p]=function(){return 7},7!=""[t](e)})),m=v&&!i((function(){var e=!1,n=/a/;return"split"===t&&(n={},n.constructor={},n.constructor[u]=function(){return n},n.flags="",n[p]=/./[p]),n.exec=function(){return e=!0,null},n[p](""),!e}));if(!v||!m||"replace"===t&&(!l||!c||f)||"split"===t&&!d){var g=/./[p],_=n(p,""[t],(function(t,e,n,r,i){return e.exec===s?v&&!i?{done:!0,value:g.call(e,n,r)}:{done:!0,value:t.call(n,e,r)}:{done:!1}}),{REPLACE_KEEPS_$0:c,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:f}),y=_[0],b=_[1];r(String.prototype,t,y),r(RegExp.prototype,p,2==e?function(t,e){return b.call(t,this,e)}:function(t){return b.call(t,this)})}h&&a(RegExp.prototype[p],"sham",!0)}},d81d:function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").map,o=n("1dde"),s=n("ae40"),a=o("map"),u=s("map");r({target:"Array",proto:!0,forced:!a||!u},{map:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},da84:function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")()}).call(this,n("c8ba"))},dbb4:function(t,e,n){var r=n("23e7"),i=n("83ab"),o=n("56ef"),s=n("fc6a"),a=n("06cf"),u=n("8418");r({target:"Object",stat:!0,sham:!i},{getOwnPropertyDescriptors:function(t){var e,n,r=s(t),i=a.f,l=o(r),c={},h=0;while(l.length>h)n=i(r,e=l[h++]),void 0!==n&&u(c,e,n);return c}})},dbf1:function(t,e,n){"use strict";(function(t){function r(){return"undefined"!==typeof window?window.console:t.console}n.d(e,"a",(function(){return i}));var i=r()}).call(this,n("c8ba"))},ddb0:function(t,e,n){var r=n("da84"),i=n("fdbc"),o=n("e260"),s=n("9112"),a=n("b622"),u=a("iterator"),l=a("toStringTag"),c=o.values;for(var h in i){var f=r[h],d=f&&f.prototype;if(d){if(d[u]!==c)try{s(d,u,c)}catch(v){d[u]=c}if(d[l]||s(d,l,h),i[h])for(var p in o)if(d[p]!==o[p])try{s(d,p,o[p])}catch(v){d[p]=o[p]}}}},df75:function(t,e,n){var r=n("ca84"),i=n("7839");t.exports=Object.keys||function(t){return r(t,i)}},e01a:function(t,e,n){"use strict";var r=n("23e7"),i=n("83ab"),o=n("da84"),s=n("5135"),a=n("861d"),u=n("9bf2").f,l=n("e893"),c=o.Symbol;if(i&&"function"==typeof c&&(!("description"in c.prototype)||void 0!==c().description)){var h={},f=function(){var t=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),e=this instanceof f?new c(t):void 0===t?c():c(t);return""===t&&(h[e]=!0),e};l(f,c);var d=f.prototype=c.prototype;d.constructor=f;var p=d.toString,v="Symbol(test)"==String(c("test")),m=/^Symbol\((.*)\)[^)]+$/;u(d,"description",{configurable:!0,get:function(){var t=a(this)?this.valueOf():this,e=p.call(t);if(s(h,t))return"";var n=v?e.slice(7,-1):e.replace(m,"$1");return""===n?void 0:n}}),r({global:!0,forced:!0},{Symbol:f})}},e163:function(t,e,n){var r=n("5135"),i=n("7b0b"),o=n("f772"),s=n("e177"),a=o("IE_PROTO"),u=Object.prototype;t.exports=s?Object.getPrototypeOf:function(t){return t=i(t),r(t,a)?t[a]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?u:null}},e177:function(t,e,n){var r=n("d039");t.exports=!r((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},e260:function(t,e,n){"use strict";var r=n("fc6a"),i=n("44d2"),o=n("3f8c"),s=n("69f3"),a=n("7dd0"),u="Array Iterator",l=s.set,c=s.getterFor(u);t.exports=a(Array,"Array",(function(t,e){l(this,{type:u,target:r(t),index:0,kind:e})}),(function(){var t=c(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values"),o.Arguments=o.Array,i("keys"),i("values"),i("entries")},e439:function(t,e,n){var r=n("23e7"),i=n("d039"),o=n("fc6a"),s=n("06cf").f,a=n("83ab"),u=i((function(){s(1)})),l=!a||u;r({target:"Object",stat:!0,forced:l,sham:!a},{getOwnPropertyDescriptor:function(t,e){return s(o(t),e)}})},e538:function(t,e,n){var r=n("b622");e.f=r},e893:function(t,e,n){var r=n("5135"),i=n("56ef"),o=n("06cf"),s=n("9bf2");t.exports=function(t,e){for(var n=i(e),a=s.f,u=o.f,l=0;l<n.length;l++){var c=n[l];r(t,c)||a(t,c,u(e,c))}}},e8b5:function(t,e,n){var r=n("c6b6");t.exports=Array.isArray||function(t){return"Array"==r(t)}},e95a:function(t,e,n){var r=n("b622"),i=n("3f8c"),o=r("iterator"),s=Array.prototype;t.exports=function(t){return void 0!==t&&(i.Array===t||s[o]===t)}},f5df:function(t,e,n){var r=n("00ee"),i=n("c6b6"),o=n("b622"),s=o("toStringTag"),a="Arguments"==i(function(){return arguments}()),u=function(t,e){try{return t[e]}catch(n){}};t.exports=r?i:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=u(e=Object(t),s))?n:a?i(e):"Object"==(r=i(e))&&"function"==typeof e.callee?"Arguments":r}},f772:function(t,e,n){var r=n("5692"),i=n("90e3"),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},fb15:function(t,e,n){"use strict";if(n.r(e),"undefined"!==typeof window){var r=window.document.currentScript,i=n("8875");r=i(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:i});var o=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);o&&(n.p=o[1])}n("99af"),n("4de4"),n("4160"),n("c975"),n("d81d"),n("a434"),n("159b"),n("a4d3"),n("e439"),n("dbb4"),n("b64b");function s(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function u(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){s(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function l(t){if(Array.isArray(t))return t}n("e01a"),n("d28b"),n("e260"),n("d3b7"),n("3ca3"),n("ddb0");function c(t,e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(t)){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done);r=!0)if(n.push(s.value),e&&n.length===e)break}catch(u){i=!0,o=u}finally{try{r||null==a["return"]||a["return"]()}finally{if(i)throw o}}return n}}n("a630"),n("fb6a"),n("b0c0"),n("25f0");function h(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function f(t,e){if(t){if("string"===typeof t)return h(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?h(t,e):void 0}}function d(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function p(t,e){return l(t)||c(t,e)||f(t,e)||d()}function v(t){if(Array.isArray(t))return h(t)}function m(t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}function g(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _(t){return v(t)||m(t)||f(t)||g()}var y=n("a352"),b=n.n(y);function E(t){null!==t.parentElement&&t.parentElement.removeChild(t)}function x(t,e,n){var r=0===n?t.children[0]:t.children[n-1].nextSibling;t.insertBefore(e,r)}var T=n("dbf1");n("13d5"),n("4fad"),n("ac1f"),n("5319");function S(t){var e=Object.create(null);return function(n){var r=e[n];return r||(e[n]=t(n))}}var R=/-(\w)/g,A=S((function(t){return t.replace(R,(function(t,e){return e.toUpperCase()}))})),O=(n("5db7"),n("73d9"),["Start","Add","Remove","Update","End"]),w=["Choose","Unchoose","Sort","Filter","Clone"],I=["Move"],P=[I,O,w].flatMap((function(t){return t})).map((function(t){return"on".concat(t)})),C={manage:I,manageAndEmit:O,emit:w};function N(t){return-1!==P.indexOf(t)}n("caad"),n("2ca0");var M=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","math","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rb","rp","rt","rtc","ruby","s","samp","script","section","select","slot","small","source","span","strong","style","sub","summary","sup","svg","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr"];function D(t){return M.includes(t)}function L(t){return["transition-group","TransitionGroup"].includes(t)}function F(t){return["id","class","role","style"].includes(t)||t.startsWith("data-")||t.startsWith("aria-")||t.startsWith("on")}function B(t){return t.reduce((function(t,e){var n=p(e,2),r=n[0],i=n[1];return t[r]=i,t}),{})}function U(t){var e=t.$attrs,n=t.componentData,r=void 0===n?{}:n,i=B(Object.entries(e).filter((function(t){var e=p(t,2),n=e[0];e[1];return F(n)})));return u(u({},i),r)}function G(t){var e=t.$attrs,n=t.callBackBuilder,r=B(k(e));Object.entries(n).forEach((function(t){var e=p(t,2),n=e[0],i=e[1];C[n].forEach((function(t){r["on".concat(t)]=i(t)}))}));var i="[data-draggable]".concat(r.draggable||"");return u(u({},r),{},{draggable:i})}function k(t){return Object.entries(t).filter((function(t){var e=p(t,2),n=e[0];e[1];return!F(n)})).map((function(t){var e=p(t,2),n=e[0],r=e[1];return[A(n),r]})).filter((function(t){var e=p(t,2),n=e[0];e[1];return!N(n)}))}n("c740");function X(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function j(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function H(t,e,n){return e&&j(t.prototype,e),n&&j(t,n),t}var V=function(t){var e=t.el;return e},Y=function(t,e){return t.__draggable_context=e},W=function(t){return t.__draggable_context},z=function(){function t(e){var n=e.nodes,r=n.header,i=n.default,o=n.footer,s=e.root,a=e.realList;X(this,t),this.defaultNodes=i,this.children=[].concat(_(r),_(i),_(o)),this.externalComponent=s.externalComponent,this.rootTransition=s.transition,this.tag=s.tag,this.realList=a}return H(t,[{key:"render",value:function(t,e){var n=this.tag,r=this.children,i=this._isRootComponent,o=i?{default:function(){return r}}:r;return t(n,e,o)}},{key:"updated",value:function(){var t=this.defaultNodes,e=this.realList;t.forEach((function(t,n){Y(V(t),{element:e[n],index:n})}))}},{key:"getUnderlyingVm",value:function(t){return W(t)}},{key:"getVmIndexFromDomIndex",value:function(t,e){var n=this.defaultNodes,r=n.length,i=e.children,o=i.item(t);if(null===o)return r;var s=W(o);if(s)return s.index;if(0===r)return 0;var a=V(n[0]),u=_(i).findIndex((function(t){return t===a}));return t<u?0:r}},{key:"_isRootComponent",get:function(){return this.externalComponent||this.rootTransition}}]),t}(),$=n("8bbf");function q(t,e){var n=t[e];return n?n():[]}function K(t){var e=t.$slots,n=t.realList,r=t.getKey,i=n||[],o=["header","footer"].map((function(t){return q(e,t)})),s=p(o,2),a=s[0],l=s[1],c=e.item;if(!c)throw new Error("draggable element must have an item slot");var h=i.flatMap((function(t,e){return c({element:t,index:e}).map((function(e){return e.key=r(t),e.props=u(u({},e.props||{}),{},{"data-draggable":!0}),e}))}));if(h.length!==i.length)throw new Error("Item slot must have only one child");return{header:a,footer:l,default:h}}function Z(t){var e=L(t),n=!D(t)&&!e;return{transition:e,externalComponent:n,tag:n?Object($["resolveComponent"])(t):e?$["TransitionGroup"]:t}}function J(t){var e=t.$slots,n=t.tag,r=t.realList,i=t.getKey,o=K({$slots:e,realList:r,getKey:i}),s=Z(n);return new z({nodes:o,root:s,realList:r})}function Q(t,e){var n=this;Object($["nextTick"])((function(){return n.$emit(t.toLowerCase(),e)}))}function tt(t){var e=this;return function(n,r){if(null!==e.realList)return e["onDrag".concat(t)](n,r)}}function et(t){var e=this,n=tt.call(this,t);return function(r,i){n.call(e,r,i),Q.call(e,t,r)}}var nt=null,rt={list:{type:Array,required:!1,default:null},modelValue:{type:Array,required:!1,default:null},itemKey:{type:[String,Function],required:!0},clone:{type:Function,default:function(t){return t}},tag:{type:String,default:"div"},move:{type:Function,default:null},componentData:{type:Object,required:!1,default:null}},it=["update:modelValue","change"].concat(_([].concat(_(C.manageAndEmit),_(C.emit)).map((function(t){return t.toLowerCase()})))),ot=Object($["defineComponent"])({name:"draggable",inheritAttrs:!1,props:rt,emits:it,data:function(){return{error:!1}},render:function(){try{this.error=!1;var t=this.$slots,e=this.$attrs,n=this.tag,r=this.componentData,i=this.realList,o=this.getKey,s=J({$slots:t,tag:n,realList:i,getKey:o});this.componentStructure=s;var a=U({$attrs:e,componentData:r});return s.render($["h"],a)}catch(u){return this.error=!0,Object($["h"])("pre",{style:{color:"red"}},u.stack)}},created:function(){null!==this.list&&null!==this.modelValue&&T["a"].error("modelValue and list props are mutually exclusive! Please set one or another.")},mounted:function(){var t=this;if(!this.error){var e=this.$attrs,n=this.$el,r=this.componentStructure;r.updated();var i=G({$attrs:e,callBackBuilder:{manageAndEmit:function(e){return et.call(t,e)},emit:function(e){return Q.bind(t,e)},manage:function(e){return tt.call(t,e)}}}),o=1===n.nodeType?n:n.parentElement;this._sortable=new b.a(o,i),this.targetDomElement=o,o.__draggable_component__=this}},updated:function(){this.componentStructure.updated()},beforeUnmount:function(){void 0!==this._sortable&&this._sortable.destroy()},computed:{realList:function(){var t=this.list;return t||this.modelValue},getKey:function(){var t=this.itemKey;return"function"===typeof t?t:function(e){return e[t]}}},watch:{$attrs:{handler:function(t){var e=this._sortable;e&&k(t).forEach((function(t){var n=p(t,2),r=n[0],i=n[1];e.option(r,i)}))},deep:!0}},methods:{getUnderlyingVm:function(t){return this.componentStructure.getUnderlyingVm(t)||null},getUnderlyingPotencialDraggableComponent:function(t){return t.__draggable_component__},emitChanges:function(t){var e=this;Object($["nextTick"])((function(){return e.$emit("change",t)}))},alterList:function(t){if(this.list)t(this.list);else{var e=_(this.modelValue);t(e),this.$emit("update:modelValue",e)}},spliceList:function(){var t=arguments,e=function(e){return e.splice.apply(e,_(t))};this.alterList(e)},updatePosition:function(t,e){var n=function(n){return n.splice(e,0,n.splice(t,1)[0])};this.alterList(n)},getRelatedContextFromMoveEvent:function(t){var e=t.to,n=t.related,r=this.getUnderlyingPotencialDraggableComponent(e);if(!r)return{component:r};var i=r.realList,o={list:i,component:r};if(e!==n&&i){var s=r.getUnderlyingVm(n)||{};return u(u({},s),o)}return o},getVmIndexFromDomIndex:function(t){return this.componentStructure.getVmIndexFromDomIndex(t,this.targetDomElement)},onDragStart:function(t){this.context=this.getUnderlyingVm(t.item),t.item._underlying_vm_=this.clone(this.context.element),nt=t.item},onDragAdd:function(t){var e=t.item._underlying_vm_;if(void 0!==e){E(t.item);var n=this.getVmIndexFromDomIndex(t.newIndex);this.spliceList(n,0,e);var r={element:e,newIndex:n};this.emitChanges({added:r})}},onDragRemove:function(t){if(x(this.$el,t.item,t.oldIndex),"clone"!==t.pullMode){var e=this.context,n=e.index,r=e.element;this.spliceList(n,1);var i={element:r,oldIndex:n};this.emitChanges({removed:i})}else E(t.clone)},onDragUpdate:function(t){E(t.item),x(t.from,t.item,t.oldIndex);var e=this.context.index,n=this.getVmIndexFromDomIndex(t.newIndex);this.updatePosition(e,n);var r={element:this.context.element,oldIndex:e,newIndex:n};this.emitChanges({moved:r})},computeFutureIndex:function(t,e){if(!t.element)return 0;var n=_(e.to.children).filter((function(t){return"none"!==t.style["display"]})),r=n.indexOf(e.related),i=t.component.getVmIndexFromDomIndex(r),o=-1!==n.indexOf(nt);return o||!e.willInsertAfter?i:i+1},onDragMove:function(t,e){var n=this.move,r=this.realList;if(!n||!r)return!0;var i=this.getRelatedContextFromMoveEvent(t),o=this.computeFutureIndex(i,t),s=u(u({},this.context),{},{futureIndex:o}),a=u(u({},t),{},{relatedContext:i,draggedContext:s});return n(a,e)},onDragEnd:function(){nt=null}}}),st=ot;e["default"]=st},fb6a:function(t,e,n){"use strict";var r=n("23e7"),i=n("861d"),o=n("e8b5"),s=n("23cb"),a=n("50c4"),u=n("fc6a"),l=n("8418"),c=n("b622"),h=n("1dde"),f=n("ae40"),d=h("slice"),p=f("slice",{ACCESSORS:!0,0:0,1:2}),v=c("species"),m=[].slice,g=Math.max;r({target:"Array",proto:!0,forced:!d||!p},{slice:function(t,e){var n,r,c,h=u(this),f=a(h.length),d=s(t,f),p=s(void 0===e?f:e,f);if(o(h)&&(n=h.constructor,"function"!=typeof n||n!==Array&&!o(n.prototype)?i(n)&&(n=n[v],null===n&&(n=void 0)):n=void 0,n===Array||void 0===n))return m.call(h,d,p);for(r=new(void 0===n?Array:n)(g(p-d,0)),c=0;d<p;d++,c++)d in h&&l(r,c,h[d]);return r.length=c,r}})},fc6a:function(t,e,n){var r=n("44ad"),i=n("1d80");t.exports=function(t){return r(i(t))}},fdbc:function(t,e){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},fdbf:function(t,e,n){var r=n("4930");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}})["default"]}))},8111:function(t,e,n){"use strict";n.d(e,{i:function(){return r}});let r=()=>({events:{},emit(t,...e){(this.events[t]||[]).forEach((t=>t(...e)))},on(t,e){return(this.events[t]=this.events[t]||[]).push(e),()=>this.events[t]=(this.events[t]||[]).filter((t=>t!==e))}})},9227:function(t,e,n){"use strict";n.d(e,{Z:function(){return i}});n(2526),n(1817),n(1539),n(2165),n(8783),n(3948);function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function i(t,e){(function(){return void 0!==e&&null!==e&&e[Symbol.for("==")]?e[Symbol.for("==")](null):null==e}()||function(){return void 0!==e&&null!==e&&e[Symbol.for(">")]?e[Symbol.for(">")](t.length):e>t.length}())&&(e=t.length);for(var n=0,i=new Array(e);function(){return void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](e):n<e}();function(){return void 0!==n&&null!==n&&"object"===r(n)&&n[Symbol.for("postfix-increment")]?n[Symbol.for("postfix-increment")]():n++}())i[n]=t[n];return i}},8534:function(t,e,n){"use strict";n.d(e,{Z:function(){return i}});n(1539);function r(t,e,n,r,i,o,s){try{var a=t[o](s),u=a.value}catch(l){return void n(l)}a.done?e(u):Promise.resolve(u).then(r,i)}function i(t){return function(){var e=this,n=arguments;return new Promise((function(i,o){var s=t.apply(e,n);function a(t){r(s,i,o,a,u,"next",t)}function u(t){r(s,i,o,a,u,"throw",t)}a(void 0)}))}}},3087:function(t,e,n){"use strict";n.d(e,{Z:function(){return r}});n(2526),n(1817),n(1539),n(1703);function r(t,e){if(function(){return t instanceof e!==void 0&&t instanceof e!==null&&(t instanceof e)[Symbol.for("!")]?(t instanceof e)[Symbol.for("!")]():!(t instanceof e)}())throw new TypeError("Cannot call a class as a function")}},2833:function(t,e,n){"use strict";n.d(e,{Z:function(){return o}});n(2526),n(1817),n(1539),n(2165),n(8783),n(3948);function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function i(t,e){for(var n=0;function(){return void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](e.length):n<e.length}();function(){return void 0!==n&&null!==n&&"object"===r(n)&&n[Symbol.for("postfix-increment")]?n[Symbol.for("postfix-increment")]():n++}()){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,function(){return"value"[Symbol.for("in")]?"value"[Symbol.for("in")](i):"value"in i}()&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function o(t,e,n){return e&&i(t.prototype,e),n&&i(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}},2482:function(t,e,n){"use strict";n.d(e,{Z:function(){return r}});n(2526),n(1817),n(1539);function r(t,e,n){return!function(){return void 0!==e&&null!==e&&e[Symbol.for("in")]?e[Symbol.for("in")](t):e in t}()?t[e]=n:Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t}},5082:function(t,e,n){"use strict";n.d(e,{Z:function(){return s}});n(7941),n(2526),n(7327),n(1539),n(5003),n(1817),n(4747),n(9337),n(2165),n(8783),n(3948);var r=n(2482);function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function o(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function s(t){for(var e=arguments,n=1;function(){return void 0!==n&&null!==n&&n[Symbol.for("<")]?n[Symbol.for("<")](e.length):n<e.length}();function(){return void 0!==n&&null!==n&&"object"===i(n)&&n[Symbol.for("postfix-increment")]?n[Symbol.for("postfix-increment")]():n++}()){var s=function(){return null!=e[n]}()?arguments[n]:{};!function(){return void 0!==n&&null!==n&&n[Symbol.for("%")]?n[Symbol.for("%")](2):n%2}()?Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(s)):o(Object(s)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(s,e))})):o(Object(s),function(){return!(0)[Symbol.for("!")]||(0)[Symbol.for("!")]()}()).forEach((function(e){(0,r.Z)(t,e,s[e])}))}return t}},6084:function(t,e,n){"use strict";function r(t){if(Array.isArray(t))return t}n.d(e,{Z:function(){return u}});n(2526),n(1817),n(1539),n(2165),n(8783),n(3948);function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function o(t,e){var n=function(){return void 0!==t&&null!==t&&t[Symbol.for("==")]?t[Symbol.for("==")](null):null==t}()?null:function(){return void 0!==("undefined"===typeof Symbol?"undefined":i(Symbol))&&null!==typeof Symbol&&("undefined"===typeof Symbol?"undefined":i(Symbol))[Symbol.for("!==")]?("undefined"===typeof Symbol?"undefined":i(Symbol))[Symbol.for("!==")]("undefined"):"undefined"!==typeof Symbol}()&&t[Symbol.iterator]||t["@@iterator"];if(!function(){return void 0!==n&&null!==n&&n[Symbol.for("==")]?n[Symbol.for("==")](null):null==n}()){var r,o,s=[],a=!0,u=!1;try{for(n=n.call(t);function(){return void 0!==(a=(r=n.next()).done)&&null!==(a=(r=n.next()).done)&&(a=(r=n.next()).done)[Symbol.for("!")]?(a=(r=n.next()).done)[Symbol.for("!")]():!(a=(r=n.next()).done)}();a=!0)if(s.push(r.value),e&&s.length===e)break}catch(l){u=!0,o=l}finally{try{(function(){return void 0!==a&&null!==a&&a[Symbol.for("!")]?a[Symbol.for("!")]():!a})()&&function(){return void 0!==n["return"]&&null!==n["return"]&&n["return"][Symbol.for("!=")]?n["return"][Symbol.for("!=")](null):null!=n["return"]}()&&n["return"]()}finally{if(u)throw o}}return s}}var s=n(2780);n(1703);function a(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function u(t,e){return r(t)||o(t,e)||(0,s.Z)(t,e)||a()}},9584:function(t,e,n){"use strict";n.d(e,{Z:function(){return l}});var r=n(9227);function i(t){if(Array.isArray(t))return(0,r.Z)(t)}n(2526),n(1817),n(1539),n(2165),n(8783),n(3948),n(1038);function o(t){return o=function(){return"function"[Symbol.for("==")]?"function"[Symbol.for("==")](typeof Symbol):"function"==typeof Symbol}()&&function(){return"symbol"[Symbol.for("==")]?"symbol"[Symbol.for("==")](typeof Symbol.iterator):"symbol"==typeof Symbol.iterator}()?function(t){return typeof t}:function(t){return t&&function(){return"function"[Symbol.for("==")]?"function"[Symbol.for("==")](typeof Symbol):"function"==typeof Symbol}()&&t.constructor===Symbol&&function(){return void 0!==t&&null!==t&&t[Symbol.for("!==")]?t[Symbol.for("!==")](Symbol.prototype):t!==Symbol.prototype}()?"symbol":typeof t},o(t)}function s(t){if(function(){return void 0!==("undefined"===typeof Symbol?"undefined":o(Symbol))&&null!==typeof Symbol&&("undefined"===typeof Symbol?"undefined":o(Symbol))[Symbol.for("!==")]?("undefined"===typeof Symbol?"undefined":o(Symbol))[Symbol.for("!==")]("undefined"):"undefined"!==typeof Symbol}()&&function(){return void 0!==t[Symbol.iterator]&&null!==t[Symbol.iterator]&&t[Symbol.iterator][Symbol.for("!=")]?t[Symbol.iterator][Symbol.for("!=")](null):null!=t[Symbol.iterator]}()||function(){return void 0!==t["@@iterator"]&&null!==t["@@iterator"]&&t["@@iterator"][Symbol.for("!=")]?t["@@iterator"][Symbol.for("!=")](null):null!=t["@@iterator"]}())return Array.from(t)}var a=n(2780);n(1703);function u(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function l(t){return i(t)||s(t)||(0,a.Z)(t)||u()}},3336:function(t,e,n){"use strict";n.d(e,{Z:function(){return r}});n(2526),n(1817),n(1539),n(2165),n(8783),n(3948);function r(t){return r=function(){return"function"[Symbol.for("==")]?"function"[Symbol.for("==")](typeof Symbol):"function"==typeof Symbol}()&&function(){return"symbol"[Symbol.for("==")]?"symbol"[Symbol.for("==")](typeof Symbol.iterator):"symbol"==typeof Symbol.iterator}()?function(t){return typeof t}:function(t){return t&&function(){return"function"[Symbol.for("==")]?"function"[Symbol.for("==")](typeof Symbol):"function"==typeof Symbol}()&&t.constructor===Symbol&&function(){return void 0!==t&&null!==t&&t[Symbol.for("!==")]?t[Symbol.for("!==")](Symbol.prototype):t!==Symbol.prototype}()?"symbol":typeof t},r(t)}},2780:function(t,e,n){"use strict";n.d(e,{Z:function(){return i}});n(2526),n(1817),n(1539),n(7042),n(8309),n(1038),n(8783),n(4916),n(7601);var r=n(9227);function i(t,e){if(!function(){return void 0!==t&&null!==t&&t[Symbol.for("!")]?t[Symbol.for("!")]():!t}()){if("string"===typeof t)return(0,r.Z)(t,e);var n=Object.prototype.toString.call(t).slice(8,function(){return 1[Symbol.for("minus")]?1[Symbol.for("minus")]():-1}());return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?(0,r.Z)(t,e):void 0}}},3002:function(t,e,n){"use strict";n.d(e,{ZP:function(){return jt},pm:function(){return Xt}});var r=n(4865),i=Object.defineProperty,o=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable,u=(t,e,n)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,l=(t,e)=>{for(var n in e||(e={}))s.call(e,n)&&u(t,n,e[n]);if(o)for(var n of o(e))a.call(e,n)&&u(t,n,e[n]);return t},c=t=>"function"===typeof t,h=t=>"string"===typeof t,f=t=>h(t)&&t.trim().length>0,d=t=>"number"===typeof t,p=t=>"undefined"===typeof t,v=t=>"object"===typeof t&&null!==t,m=t=>x(t,"tag")&&f(t.tag),g=t=>window.TouchEvent&&t instanceof TouchEvent,_=t=>x(t,"component")&&b(t.component),y=t=>c(t)||v(t),b=t=>!p(t)&&(h(t)||y(t)||_(t)),E=t=>v(t)&&["height","width","right","left","top","bottom"].every((e=>d(t[e]))),x=(t,e)=>(v(t)||c(t))&&e in t,T=(t=>()=>t++)(0);function S(t){return g(t)?t.targetTouches[0].clientX:t.clientX}function R(t){return g(t)?t.targetTouches[0].clientY:t.clientY}var A,O,w,I=t=>{p(t.remove)?t.parentNode&&t.parentNode.removeChild(t):t.remove()},P=t=>_(t)?P(t.component):m(t)?(0,r.defineComponent)({render(){return t}}):"string"===typeof t?t:(0,r.toRaw)((0,r.unref)(t)),C=t=>{if("string"===typeof t)return t;const e=x(t,"props")&&v(t.props)?t.props:{},n=x(t,"listeners")&&v(t.listeners)?t.listeners:{};return{component:P(t),props:e,listeners:n}},N=()=>"undefined"!==typeof window,M=class{constructor(){this.allHandlers={}}getHandlers(t){return this.allHandlers[t]||[]}on(t,e){const n=this.getHandlers(t);n.push(e),this.allHandlers[t]=n}off(t,e){const n=this.getHandlers(t);n.splice(n.indexOf(e)>>>0,1)}emit(t,e){const n=this.getHandlers(t);n.forEach((t=>t(e)))}},D=t=>["on","off","emit"].every((e=>x(t,e)&&c(t[e])));(function(t){t["SUCCESS"]="success",t["ERROR"]="error",t["WARNING"]="warning",t["INFO"]="info",t["DEFAULT"]="default"})(A||(A={})),function(t){t["TOP_LEFT"]="top-left",t["TOP_CENTER"]="top-center",t["TOP_RIGHT"]="top-right",t["BOTTOM_LEFT"]="bottom-left",t["BOTTOM_CENTER"]="bottom-center",t["BOTTOM_RIGHT"]="bottom-right"}(O||(O={})),function(t){t["ADD"]="add",t["DISMISS"]="dismiss",t["UPDATE"]="update",t["CLEAR"]="clear",t["UPDATE_DEFAULTS"]="update_defaults"}(w||(w={}));var L="Vue-Toastification",F={type:{type:String,default:A.DEFAULT},classNames:{type:[String,Array],default:()=>[]},trueBoolean:{type:Boolean,default:!0}},B={type:F.type,customIcon:{type:[String,Boolean,Object,Function],default:!0}},U={component:{type:[String,Object,Function,Boolean],default:"button"},classNames:F.classNames,showOnHover:{type:Boolean,default:!1},ariaLabel:{type:String,default:"close"}},G={timeout:{type:[Number,Boolean],default:5e3},hideProgressBar:{type:Boolean,default:!1},isRunning:{type:Boolean,default:!1}},k={transition:{type:[Object,String],default:`${L}__bounce`}},X={position:{type:String,default:O.TOP_RIGHT},draggable:F.trueBoolean,draggablePercent:{type:Number,default:.6},pauseOnFocusLoss:F.trueBoolean,pauseOnHover:F.trueBoolean,closeOnClick:F.trueBoolean,timeout:G.timeout,hideProgressBar:G.hideProgressBar,toastClassName:F.classNames,bodyClassName:F.classNames,icon:B.customIcon,closeButton:U.component,closeButtonClassName:U.classNames,showCloseButtonOnHover:U.showOnHover,accessibility:{type:Object,default:()=>({toastRole:"alert",closeButtonLabel:"close"})},rtl:{type:Boolean,default:!1},eventBus:{type:Object,required:!1,default:()=>new M}},j={id:{type:[String,Number],required:!0,default:0},type:F.type,content:{type:[String,Object,Function],required:!0,default:""},onClick:{type:Function,default:void 0},onClose:{type:Function,default:void 0}},H={container:{type:[Object,Function],default:()=>document.body},newestOnTop:F.trueBoolean,maxToasts:{type:Number,default:20},transition:k.transition,toastDefaults:Object,filterBeforeCreate:{type:Function,default:t=>t},filterToasts:{type:Function,default:t=>t},containerClassName:F.classNames,onMounted:Function,shareAppContext:[Boolean,Object]},V={CORE_TOAST:X,TOAST:j,CONTAINER:H,PROGRESS_BAR:G,ICON:B,TRANSITION:k,CLOSE_BUTTON:U},Y=(0,r.defineComponent)({name:"VtProgressBar",props:V.PROGRESS_BAR,data(){return{hasClass:!0}},computed:{style(){return{animationDuration:`${this.timeout}ms`,animationPlayState:this.isRunning?"running":"paused",opacity:this.hideProgressBar?0:1}},cpClass(){return this.hasClass?`${L}__progress-bar`:""}},watch:{timeout(){this.hasClass=!1,this.$nextTick((()=>this.hasClass=!0))}},mounted(){this.$el.addEventListener("animationend",this.animationEnded)},beforeUnmount(){this.$el.removeEventListener("animationend",this.animationEnded)},methods:{animationEnded(){this.$emit("close-toast")}}});function W(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{style:(0,r.normalizeStyle)(t.style),class:(0,r.normalizeClass)(t.cpClass)},null,6)}Y.render=W;var z=Y,$=(0,r.defineComponent)({name:"VtCloseButton",props:V.CLOSE_BUTTON,computed:{buttonComponent(){return!1!==this.component?P(this.component):"button"},classes(){const t=[`${L}__close-button`];return this.showOnHover&&t.push("show-on-hover"),t.concat(this.classNames)}}}),q=(0,r.createTextVNode)(" × ");function K(t,e){return(0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.buttonComponent),(0,r.mergeProps)({"aria-label":t.ariaLabel,class:t.classes},t.$attrs),{default:(0,r.withCtx)((()=>[q])),_:1},16,["aria-label","class"])}$.render=K;var Z=$,J={},Q={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"check-circle",class:"svg-inline--fa fa-check-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},tt=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z"},null,-1),et=[tt];function nt(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",Q,et)}J.render=nt;var rt=J,it={},ot={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"info-circle",class:"svg-inline--fa fa-info-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},st=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z"},null,-1),at=[st];function ut(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",ot,at)}it.render=ut;var lt=it,ct={},ht={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"exclamation-circle",class:"svg-inline--fa fa-exclamation-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},ft=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1),dt=[ft];function pt(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",ht,dt)}ct.render=pt;var vt=ct,mt={},gt={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"exclamation-triangle",class:"svg-inline--fa fa-exclamation-triangle fa-w-18",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512"},_t=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1),yt=[_t];function bt(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",gt,yt)}mt.render=bt;var Et=mt,xt=(0,r.defineComponent)({name:"VtIcon",props:V.ICON,computed:{customIconChildren(){return x(this.customIcon,"iconChildren")?this.trimValue(this.customIcon.iconChildren):""},customIconClass(){return h(this.customIcon)?this.trimValue(this.customIcon):x(this.customIcon,"iconClass")?this.trimValue(this.customIcon.iconClass):""},customIconTag(){return x(this.customIcon,"iconTag")?this.trimValue(this.customIcon.iconTag,"i"):"i"},hasCustomIcon(){return this.customIconClass.length>0},component(){return this.hasCustomIcon?this.customIconTag:b(this.customIcon)?P(this.customIcon):this.iconTypeComponent},iconTypeComponent(){const t={[A.DEFAULT]:lt,[A.INFO]:lt,[A.SUCCESS]:rt,[A.ERROR]:Et,[A.WARNING]:vt};return t[this.type]},iconClasses(){const t=[`${L}__icon`];return this.hasCustomIcon?t.concat(this.customIconClass):t}},methods:{trimValue(t,e=""){return f(t)?t.trim():e}}});function Tt(t,e){return(0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.component),{class:(0,r.normalizeClass)(t.iconClasses)},{default:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(t.customIconChildren),1)])),_:1},8,["class"])}xt.render=Tt;var St=xt,Rt=(0,r.defineComponent)({name:"VtToast",components:{ProgressBar:z,CloseButton:Z,Icon:St},inheritAttrs:!1,props:Object.assign({},V.CORE_TOAST,V.TOAST),data(){const t={isRunning:!0,disableTransitions:!1,beingDragged:!1,dragStart:0,dragPos:{x:0,y:0},dragRect:{}};return t},computed:{classes(){const t=[`${L}__toast`,`${L}__toast--${this.type}`,`${this.position}`].concat(this.toastClassName);return this.disableTransitions&&t.push("disable-transition"),this.rtl&&t.push(`${L}__toast--rtl`),t},bodyClasses(){const t=[`${L}__toast-${h(this.content)?"body":"component-body"}`].concat(this.bodyClassName);return t},draggableStyle(){return this.dragStart===this.dragPos.x?{}:this.beingDragged?{transform:`translateX(${this.dragDelta}px)`,opacity:1-Math.abs(this.dragDelta/this.removalDistance)}:{transition:"transform 0.2s, opacity 0.2s",transform:"translateX(0)",opacity:1}},dragDelta(){return this.beingDragged?this.dragPos.x-this.dragStart:0},removalDistance(){return E(this.dragRect)?(this.dragRect.right-this.dragRect.left)*this.draggablePercent:0}},mounted(){this.draggable&&this.draggableSetup(),this.pauseOnFocusLoss&&this.focusSetup()},beforeUnmount(){this.draggable&&this.draggableCleanup(),this.pauseOnFocusLoss&&this.focusCleanup()},methods:{hasProp:x,getVueComponentFromObj:P,closeToast(){this.eventBus.emit(w.DISMISS,this.id)},clickHandler(){this.onClick&&this.onClick(this.closeToast),this.closeOnClick&&(this.beingDragged&&this.dragStart!==this.dragPos.x||this.closeToast())},timeoutHandler(){this.closeToast()},hoverPause(){this.pauseOnHover&&(this.isRunning=!1)},hoverPlay(){this.pauseOnHover&&(this.isRunning=!0)},focusPause(){this.isRunning=!1},focusPlay(){this.isRunning=!0},focusSetup(){addEventListener("blur",this.focusPause),addEventListener("focus",this.focusPlay)},focusCleanup(){removeEventListener("blur",this.focusPause),removeEventListener("focus",this.focusPlay)},draggableSetup(){const t=this.$el;t.addEventListener("touchstart",this.onDragStart,{passive:!0}),t.addEventListener("mousedown",this.onDragStart),addEventListener("touchmove",this.onDragMove,{passive:!1}),addEventListener("mousemove",this.onDragMove),addEventListener("touchend",this.onDragEnd),addEventListener("mouseup",this.onDragEnd)},draggableCleanup(){const t=this.$el;t.removeEventListener("touchstart",this.onDragStart),t.removeEventListener("mousedown",this.onDragStart),removeEventListener("touchmove",this.onDragMove),removeEventListener("mousemove",this.onDragMove),removeEventListener("touchend",this.onDragEnd),removeEventListener("mouseup",this.onDragEnd)},onDragStart(t){this.beingDragged=!0,this.dragPos={x:S(t),y:R(t)},this.dragStart=S(t),this.dragRect=this.$el.getBoundingClientRect()},onDragMove(t){this.beingDragged&&(t.preventDefault(),this.isRunning&&(this.isRunning=!1),this.dragPos={x:S(t),y:R(t)})},onDragEnd(){this.beingDragged&&(Math.abs(this.dragDelta)>=this.removalDistance?(this.disableTransitions=!0,this.$nextTick((()=>this.closeToast()))):setTimeout((()=>{this.beingDragged=!1,E(this.dragRect)&&this.pauseOnHover&&this.dragRect.bottom>=this.dragPos.y&&this.dragPos.y>=this.dragRect.top&&this.dragRect.left<=this.dragPos.x&&this.dragPos.x<=this.dragRect.right?this.isRunning=!1:this.isRunning=!0})))}}}),At=["role"];function Ot(t,e){const n=(0,r.resolveComponent)("Icon"),i=(0,r.resolveComponent)("CloseButton"),o=(0,r.resolveComponent)("ProgressBar");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(t.classes),style:(0,r.normalizeStyle)(t.draggableStyle),onClick:e[0]||(e[0]=(...e)=>t.clickHandler&&t.clickHandler(...e)),onMouseenter:e[1]||(e[1]=(...e)=>t.hoverPause&&t.hoverPause(...e)),onMouseleave:e[2]||(e[2]=(...e)=>t.hoverPlay&&t.hoverPlay(...e))},[t.icon?((0,r.openBlock)(),(0,r.createBlock)(n,{key:0,"custom-icon":t.icon,type:t.type},null,8,["custom-icon","type"])):(0,r.createCommentVNode)("v-if",!0),(0,r.createElementVNode)("div",{role:t.accessibility.toastRole||"alert",class:(0,r.normalizeClass)(t.bodyClasses)},["string"===typeof t.content?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.createTextVNode)((0,r.toDisplayString)(t.content),1)],2112)):((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.getVueComponentFromObj(t.content)),(0,r.mergeProps)({key:1,"toast-id":t.id},t.hasProp(t.content,"props")?t.content.props:{},(0,r.toHandlers)(t.hasProp(t.content,"listeners")?t.content.listeners:{}),{onCloseToast:t.closeToast}),null,16,["toast-id","onCloseToast"]))],10,At),t.closeButton?((0,r.openBlock)(),(0,r.createBlock)(i,{key:1,component:t.closeButton,"class-names":t.closeButtonClassName,"show-on-hover":t.showCloseButtonOnHover,"aria-label":t.accessibility.closeButtonLabel,onClick:(0,r.withModifiers)(t.closeToast,["stop"])},null,8,["component","class-names","show-on-hover","aria-label","onClick"])):(0,r.createCommentVNode)("v-if",!0),t.timeout?((0,r.openBlock)(),(0,r.createBlock)(o,{key:2,"is-running":t.isRunning,"hide-progress-bar":t.hideProgressBar,timeout:t.timeout,onCloseToast:t.timeoutHandler},null,8,["is-running","hide-progress-bar","timeout","onCloseToast"])):(0,r.createCommentVNode)("v-if",!0)],38)}Rt.render=Ot;var wt=Rt,It=(0,r.defineComponent)({name:"VtTransition",props:V.TRANSITION,emits:["leave"],methods:{hasProp:x,leave(t){t instanceof HTMLElement&&(t.style.left=t.offsetLeft+"px",t.style.top=t.offsetTop+"px",t.style.width=getComputedStyle(t).width,t.style.position="absolute")}}});function Pt(t,e){return(0,r.openBlock)(),(0,r.createBlock)(r.TransitionGroup,{tag:"div","enter-active-class":t.transition.enter?t.transition.enter:`${t.transition}-enter-active`,"move-class":t.transition.move?t.transition.move:`${t.transition}-move`,"leave-active-class":t.transition.leave?t.transition.leave:`${t.transition}-leave-active`,onLeave:t.leave},{default:(0,r.withCtx)((()=>[(0,r.renderSlot)(t.$slots,"default")])),_:3},8,["enter-active-class","move-class","leave-active-class","onLeave"])}It.render=Pt;var Ct=It,Nt=(0,r.defineComponent)({name:"VueToastification",devtools:{hide:!0},components:{Toast:wt,VtTransition:Ct},props:Object.assign({},V.CORE_TOAST,V.CONTAINER,V.TRANSITION),data(){const t={count:0,positions:Object.values(O),toasts:{},defaults:{}};return t},computed:{toastArray(){return Object.values(this.toasts)},filteredToasts(){return this.defaults.filterToasts(this.toastArray)}},beforeMount(){const t=this.eventBus;t.on(w.ADD,this.addToast),t.on(w.CLEAR,this.clearToasts),t.on(w.DISMISS,this.dismissToast),t.on(w.UPDATE,this.updateToast),t.on(w.UPDATE_DEFAULTS,this.updateDefaults),this.defaults=this.$props},mounted(){this.setup(this.container)},methods:{async setup(t){c(t)&&(t=await t()),I(this.$el),t.appendChild(this.$el)},setToast(t){p(t.id)||(this.toasts[t.id]=t)},addToast(t){t.content=C(t.content);const e=Object.assign({},this.defaults,t.type&&this.defaults.toastDefaults&&this.defaults.toastDefaults[t.type],t),n=this.defaults.filterBeforeCreate(e,this.toastArray);n&&this.setToast(n)},dismissToast(t){const e=this.toasts[t];p(e)||p(e.onClose)||e.onClose(),delete this.toasts[t]},clearToasts(){Object.keys(this.toasts).forEach((t=>{this.dismissToast(t)}))},getPositionToasts(t){const e=this.filteredToasts.filter((e=>e.position===t)).slice(0,this.defaults.maxToasts);return this.defaults.newestOnTop?e.reverse():e},updateDefaults(t){p(t.container)||this.setup(t.container),this.defaults=Object.assign({},this.defaults,t)},updateToast({id:t,options:e,create:n}){this.toasts[t]?(e.timeout&&e.timeout===this.toasts[t].timeout&&e.timeout++,this.setToast(Object.assign({},this.toasts[t],e))):n&&this.addToast(Object.assign({},{id:t},e))},getClasses(t){const e=[`${L}__container`,t];return e.concat(this.defaults.containerClassName)}}});function Mt(t,e){const n=(0,r.resolveComponent)("Toast"),i=(0,r.resolveComponent)("VtTransition");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(t.positions,(e=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:e},[(0,r.createVNode)(i,{transition:t.defaults.transition,class:(0,r.normalizeClass)(t.getClasses(e))},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(t.getPositionToasts(e),(t=>((0,r.openBlock)(),(0,r.createBlock)(n,(0,r.mergeProps)({key:t.id},t),null,16)))),128))])),_:2},1032,["transition","class"])])))),128))])}Nt.render=Mt;var Dt=Nt,Lt=(t={},e=!0)=>{const n=t.eventBus=t.eventBus||new M;e&&(0,r.nextTick)((()=>{const e=(0,r.createApp)(Dt,l({},t)),n=e.mount(document.createElement("div")),i=t.onMounted;if(p(i)||i(n,e),t.shareAppContext){const n=t.shareAppContext;!0===n?console.warn(`[${L}] App to share context with was not provided.`):(e._context.components=n._context.components,e._context.directives=n._context.directives,e._context.mixins=n._context.mixins,e._context.provides=n._context.provides,e.config.globalProperties=n.config.globalProperties)}}));const i=(t,e)=>{const r=Object.assign({},{id:T(),type:A.DEFAULT},e,{content:t});return n.emit(w.ADD,r),r.id};function o(t,{content:e,options:r},i=!1){const o=Object.assign({},r,{content:e});n.emit(w.UPDATE,{id:t,options:o,create:i})}return i.clear=()=>n.emit(w.CLEAR,void 0),i.updateDefaults=t=>{n.emit(w.UPDATE_DEFAULTS,t)},i.dismiss=t=>{n.emit(w.DISMISS,t)},i.update=o,i.success=(t,e)=>i(t,Object.assign({},e,{type:A.SUCCESS})),i.info=(t,e)=>i(t,Object.assign({},e,{type:A.INFO})),i.error=(t,e)=>i(t,Object.assign({},e,{type:A.ERROR})),i.warning=(t,e)=>i(t,Object.assign({},e,{type:A.WARNING})),i},Ft=()=>{const t=()=>console.warn(`[${L}] This plugin does not support SSR!`);return new Proxy(t,{get(){return t}})};function Bt(t){return N()?D(t)?Lt({eventBus:t},!1):Lt(t,!0):Ft()}var Ut=Symbol("VueToastification"),Gt=new M,kt=(t,e)=>{!0===(null==e?void 0:e.shareAppContext)&&(e.shareAppContext=t);const n=Bt(l({eventBus:Gt},e));t.provide(Ut,n)},Xt=t=>{if(t)return Bt(t);const e=(0,r.getCurrentInstance)()?(0,r.inject)(Ut,void 0):void 0;return e||Bt(Gt)},jt=kt}}]); -//# sourceMappingURL=chunk-vendors-legacy.e714a3a2.js.map \ No newline at end of file diff --git a/js/chunk-vendors-legacy.e714a3a2.js.map b/js/chunk-vendors-legacy.e714a3a2.js.map deleted file mode 100644 index e781dce..0000000 --- a/js/chunk-vendors-legacy.e714a3a2.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"js/chunk-vendors-legacy.e714a3a2.js","mappings":";;;;;;;;AAmBA,IAAIA,EAiBAC,EAiBAC,EAgDAC,EAmDAC,EA+BAC,EAiCAC,EAoCAC,EA+BAC,EAmBAC,EAuBAC,EA0BAC,EAwBAC,EA2BAC,EA4BAC,EAiBAC,EAmBAC,EAqBAC,EAoBAC,E,idAveJ,SAAWlB,GACPA,EAAIA,EAAI,gBAAkB,GAAK,eAC/BA,EAAIA,EAAI,SAAW,GAAK,QACxBA,EAAIA,EAAI,UAAY,GAAK,SAH7B,CAIGA,IAAQA,EAAM,KAajB,SAAWC,GACPA,EAAcA,EAAc,WAAa,GAAK,UAC9CA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ules/@pixi/constants/dist/esm/constants.js","webpack://profectus/./node_modules/@pixi/core/dist/esm/core.js","webpack://profectus/./node_modules/@pixi/display/dist/esm/display.js","webpack://profectus/./node_modules/@pixi/math/dist/esm/math.js","webpack://profectus/./node_modules/@pixi/particle-emitter/lib/particle-emitter.es.js","webpack://profectus/./node_modules/@pixi/runner/dist/esm/runner.js","webpack://profectus/./node_modules/ismobilejs/esm/isMobile.js","webpack://profectus/./node_modules/@pixi/settings/dist/esm/settings.js","webpack://profectus/./node_modules/@pixi/sprite/dist/esm/sprite.js","webpack://profectus/./node_modules/@pixi/ticker/dist/esm/ticker.js","webpack://profectus/./node_modules/@pixi/utils/dist/esm/utils.js","webpack://profectus/./node_modules/@pixi/utils/node_modules/eventemitter3/index.js","webpack://profectus/./node_modules/@vue/shared/dist/shared.esm-bundler.js","webpack://profectus/./node_modules/@ivanv/vue-collapse-transition/src/CollapseTransition.vue","webpack://profectus/./node_modules/@ivanv/vue-collapse-transition/src/CollapseTransition.vue?7164","webpack://profectus/./node_modules/core-js/internals/a-callable.js","webpack://profectus/./node_modules/core-js/internals/a-constructor.js","webpack://profectus/./node_modules/core-js/internals/a-possible-prototype.js","webpack://profectus/./node_modules/core-js/internals/add-to-unscopables.js","webpack://profectus/./node_modules/core-js/internals/advance-string-index.js","webpack://profectus/./node_modules/core-js/internals/an-instance.js","webpack://profectus/./node_modules/core-js/internals/an-object.js","webpack://profectus/./node_modules/core-js/internals/array-buffer-non-extensible.js","webpack://profectus/./node_modules/core-js/internals/array-for-each.js","webpack://profectus/./node_modules/core-js/internals/array-from.js","webpack://profectus/./node_modules/core-js/internals/array-includes.js","webpack://profectus/./node_modules/core-js/internals/array-iteration.js","webpack://profectus/./node_modules/core-js/internals/array-method-has-species-support.js","webpack://profectus/./node_modules/core-js/internals/array-method-is-strict.js","webpack://profectus/./node_modules/core-js/internals/array-slice-simple.js","webpack://profectus/./node_modules/core-js/internals/array-slice.js","webpack://profectus/./node_modules/core-js/internals/array-species-constructor.js","webpack://profectus/./node_modules/core-js/internals/array-species-create.js","webpack://profectus/./node_modules/core-js/internals/call-with-safe-iteration-closing.js","webpack://profectus/./node_modules/core-js/internals/check-correctness-of-iteration.js","webpack://profectus/./node_modules/core-js/internals/classof-raw.js","webpack://profectus/./node_modules/core-js/internals/classof.js","webpack://profectus/./node_modules/core-js/internals/clear-error-stack.js","webpack://profectus/./node_modules/core-js/internals/collection-strong.js","webpack://profectus/./node_modules/core-js/internals/collection.js","webpack://profectus/./node_modules/core-js/internals/copy-constructor-properties.js","webpack://profectus/./node_modules/core-js/internals/correct-is-regexp-logic.js","webpack://profectus/./node_modules/core-js/internals/correct-prototype-getter.js","webpack://profectus/./node_modules/core-js/internals/create-html.js","webpack://profectus/./node_modules/core-js/internals/create-iterator-constructor.js","webpack://profectus/./node_modules/core-js/internals/create-non-enumerable-property.js","webpack://profectus/./node_modules/core-js/internals/create-property-descriptor.js","webpack://profectus/./node_modules/core-js/internals/create-property.js","webpack://profectus/./node_modules/core-js/internals/define-iterator.js","webpack://profectus/./node_modules/core-js/internals/define-well-known-symbol.js","webpack://profectus/./node_modules/core-js/internals/descriptors.js","webpack://profectus/./node_modules/core-js/internals/document-create-element.js","webpack://profectus/./node_modules/core-js/internals/dom-exception-constants.js","webpack://profectus/./node_modules/core-js/internals/dom-iterables.js","webpack://profectus/./node_modules/core-js/internals/dom-token-list-prototype.js","webpack://profectus/./node_modules/core-js/internals/engine-is-browser.js","webpack://profectus/./node_modules/core-js/internals/engine-is-ios-pebble.js","webpack://profectus/./node_modules/core-js/internals/engine-is-ios.js","webpack://profectus/./node_modules/core-js/internals/engine-is-node.js","webpack://profectus/./node_modules/core-js/internals/engine-is-webos-webkit.js","webpack://profectus/./node_modules/core-js/internals/engine-user-agent.js","webpack://profectus/./node_modules/core-js/internals/engine-v8-version.js","webpack://profectus/./node_modules/core-js/internals/enum-bug-keys.js","webpack://profectus/./node_modules/core-js/internals/error-stack-installable.js","webpack://profectus/./node_modules/core-js/internals/error-to-string.js","webpack://profectus/./node_modules/core-js/internals/export.js","webpack://profectus/./node_modules/core-js/internals/fails.js","webpack://profectus/./node_modules/core-js/internals/fix-regexp-well-known-symbol-logic.js","webpack://profectus/./node_modules/core-js/internals/freezing.js","webpack://profectus/./node_modules/core-js/internals/function-apply.js","webpack://profectus/./node_modules/core-js/internals/function-bind-context.js","webpack://profectus/./node_modules/core-js/internals/function-call.js","webpack://profectus/./node_modules/core-js/internals/function-name.js","webpack://profectus/./node_modules/core-js/internals/function-uncurry-this.js","webpack://profectus/./node_modules/core-js/internals/get-built-in.js","webpack://profectus/./node_modules/core-js/internals/get-iterator-method.js","webpack://profectus/./node_modules/core-js/internals/get-iterator.js","webpack://profectus/./node_modules/core-js/internals/get-method.js","webpack://profectus/./node_modules/core-js/internals/get-substitution.js","webpack://profectus/./node_modules/core-js/internals/global.js","webpack://profectus/./node_modules/core-js/internals/has-own-property.js","webpack://profectus/./node_modules/core-js/internals/hidden-keys.js","webpack://profectus/./node_modules/core-js/internals/host-report-errors.js","webpack://profectus/./node_modules/core-js/internals/html.js","webpack://profectus/./node_modules/core-js/internals/ie8-dom-define.js","webpack://profectus/./node_modules/core-js/internals/indexed-object.js","webpack://profectus/./node_modules/core-js/internals/inherit-if-required.js","webpack://profectus/./node_modules/core-js/internals/inspect-source.js","webpack://profectus/./node_modules/core-js/internals/install-error-cause.js","webpack://profectus/./node_modules/core-js/internals/internal-metadata.js","webpack://profectus/./node_modules/core-js/internals/internal-state.js","webpack://profectus/./node_modules/core-js/internals/is-array-iterator-method.js","webpack://profectus/./node_modules/core-js/internals/is-array.js","webpack://profectus/./node_modules/core-js/internals/is-callable.js","webpack://profectus/./node_modules/core-js/internals/is-constructor.js","webpack://profectus/./node_modules/core-js/internals/is-forced.js","webpack://profectus/./node_modules/core-js/internals/is-object.js","webpack://profectus/./node_modules/core-js/internals/is-pure.js","webpack://profectus/./node_modules/core-js/internals/is-regexp.js","webpack://profectus/./node_modules/core-js/internals/is-symbol.js","webpack://profectus/./node_modules/core-js/internals/iterate.js","webpack://profectus/./node_modules/core-js/internals/iterator-close.js","webpack://profectus/./node_modules/core-js/internals/iterators-core.js","webpack://profectus/./node_modules/core-js/internals/iterators.js","webpack://profectus/./node_modules/core-js/internals/length-of-array-like.js","webpack://profectus/./node_modules/core-js/internals/math-log10.js","webpack://profectus/./node_modules/core-js/internals/math-sign.js","webpack://profectus/./node_modules/core-js/internals/microtask.js","webpack://profectus/./node_modules/core-js/internals/native-promise-constructor.js","webpack://profectus/./node_modules/core-js/internals/native-symbol.js","webpack://profectus/./node_modules/core-js/internals/native-weak-map.js","webpack://profectus/./node_modules/core-js/internals/new-promise-capability.js","webpack://profectus/./node_modules/core-js/internals/normalize-string-argument.js","webpack://profectus/./node_modules/core-js/internals/not-a-regexp.js","webpack://profectus/./node_modules/core-js/internals/number-is-finite.js","webpack://profectus/./node_modules/core-js/internals/object-assign.js","webpack://profectus/./node_modules/core-js/internals/object-create.js","webpack://profectus/./node_modules/core-js/internals/object-define-properties.js","webpack://profectus/./node_modules/core-js/internals/object-define-property.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-descriptor.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-names-external.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-names.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-symbols.js","webpack://profectus/./node_modules/core-js/internals/object-get-prototype-of.js","webpack://profectus/./node_modules/core-js/internals/object-is-extensible.js","webpack://profectus/./node_modules/core-js/internals/object-is-prototype-of.js","webpack://profectus/./node_modules/core-js/internals/object-keys-internal.js","webpack://profectus/./node_modules/core-js/internals/object-keys.js","webpack://profectus/./node_modules/core-js/internals/object-property-is-enumerable.js","webpack://profectus/./node_modules/core-js/internals/object-set-prototype-of.js","webpack://profectus/./node_modules/core-js/internals/object-to-array.js","webpack://profectus/./node_modules/core-js/internals/object-to-string.js","webpack://profectus/./node_modules/core-js/internals/ordinary-to-primitive.js","webpack://profectus/./node_modules/core-js/internals/own-keys.js","webpack://profectus/./node_modules/core-js/internals/path.js","webpack://profectus/./node_modules/core-js/internals/perform.js","webpack://profectus/./node_modules/core-js/internals/promise-resolve.js","webpack://profectus/./node_modules/core-js/internals/queue.js","webpack://profectus/./node_modules/core-js/internals/redefine-all.js","webpack://profectus/./node_modules/core-js/internals/redefine.js","webpack://profectus/./node_modules/core-js/internals/regexp-exec-abstract.js","webpack://profectus/./node_modules/core-js/internals/regexp-exec.js","webpack://profectus/./node_modules/core-js/internals/regexp-flags.js","webpack://profectus/./node_modules/core-js/internals/regexp-sticky-helpers.js","webpack://profectus/./node_modules/core-js/internals/regexp-unsupported-dot-all.js","webpack://profectus/./node_modules/core-js/internals/regexp-unsupported-ncg.js","webpack://profectus/./node_modules/core-js/internals/require-object-coercible.js","webpack://profectus/./node_modules/core-js/internals/set-global.js","webpack://profectus/./node_modules/core-js/internals/set-species.js","webpack://profectus/./node_modules/core-js/internals/set-to-string-tag.js","webpack://profectus/./node_modules/core-js/internals/shared-key.js","webpack://profectus/./node_modules/core-js/internals/shared-store.js","webpack://profectus/./node_modules/core-js/internals/shared.js","webpack://profectus/./node_modules/core-js/internals/species-constructor.js","webpack://profectus/./node_modules/core-js/internals/string-html-forced.js","webpack://profectus/./node_modules/core-js/internals/string-multibyte.js","webpack://profectus/./node_modules/core-js/internals/string-repeat.js","webpack://profectus/./node_modules/core-js/internals/string-trim-forced.js","webpack://profectus/./node_modules/core-js/internals/string-trim.js","webpack://profectus/./node_modules/core-js/internals/task.js","webpack://profectus/./node_modules/core-js/internals/this-number-value.js","webpack://profectus/./node_modules/core-js/internals/to-absolute-index.js","webpack://profectus/./node_modules/core-js/internals/to-indexed-object.js","webpack://profectus/./node_modules/core-js/internals/to-integer-or-infinity.js","webpack://profectus/./node_modules/core-js/internals/to-length.js","webpack://profectus/./node_modules/core-js/internals/to-object.js","webpack://profectus/./node_modules/core-js/internals/to-primitive.js","webpack://profectus/./node_modules/core-js/internals/to-property-key.js","webpack://profectus/./node_modules/core-js/internals/to-string-tag-support.js","webpack://profectus/./node_modules/core-js/internals/to-string.js","webpack://profectus/./node_modules/core-js/internals/try-node-require.js","webpack://profectus/./node_modules/core-js/internals/try-to-string.js","webpack://profectus/./node_modules/core-js/internals/uid.js","webpack://profectus/./node_modules/core-js/internals/use-symbol-as-uid.js","webpack://profectus/./node_modules/core-js/internals/v8-prototype-define-bug.js","webpack://profectus/./node_modules/core-js/internals/well-known-symbol-wrapped.js","webpack://profectus/./node_modules/core-js/internals/well-known-symbol.js","webpack://profectus/./node_modules/core-js/internals/whitespaces.js","webpack://profectus/./node_modules/core-js/internals/wrap-error-constructor-with-cause.js","webpack://profectus/./node_modules/core-js/modules/es.array.concat.js","webpack://profectus/./node_modules/core-js/modules/es.array.filter.js","webpack://profectus/./node_modules/core-js/modules/es.array.find-index.js","webpack://profectus/./node_modules/core-js/modules/es.array.find.js","webpack://profectus/./node_modules/core-js/modules/es.array.from.js","webpack://profectus/./node_modules/core-js/modules/es.array.includes.js","webpack://profectus/./node_modules/core-js/modules/es.array.iterator.js","webpack://profectus/./node_modules/core-js/modules/es.array.join.js","webpack://profectus/./node_modules/core-js/modules/es.array.map.js","webpack://profectus/./node_modules/core-js/modules/es.array.slice.js","webpack://profectus/./node_modules/core-js/modules/es.array.splice.js","webpack://profectus/./node_modules/core-js/modules/es.error.cause.js","webpack://profectus/./node_modules/core-js/modules/es.function.name.js","webpack://profectus/./node_modules/core-js/modules/es.json.stringify.js","webpack://profectus/./node_modules/core-js/modules/es.math.log10.js","webpack://profectus/./node_modules/core-js/modules/es.math.log2.js","webpack://profectus/./node_modules/core-js/modules/es.math.sign.js","webpack://profectus/./node_modules/core-js/modules/es.math.trunc.js","webpack://profectus/./node_modules/core-js/modules/es.number.constructor.js","webpack://profectus/./node_modules/core-js/modules/es.number.is-finite.js","webpack://profectus/./node_modules/core-js/modules/es.number.is-nan.js","webpack://profectus/./node_modules/core-js/modules/es.number.to-exponential.js","webpack://profectus/./node_modules/core-js/modules/es.number.to-fixed.js","webpack://profectus/./node_modules/core-js/modules/es.object.assign.js","webpack://profectus/./node_modules/core-js/modules/es.object.get-own-property-descriptor.js","webpack://profectus/./node_modules/core-js/modules/es.object.get-own-property-descriptors.js","webpack://profectus/./node_modules/core-js/modules/es.object.keys.js","webpack://profectus/./node_modules/core-js/modules/es.object.to-string.js","webpack://profectus/./node_modules/core-js/modules/es.object.values.js","webpack://profectus/./node_modules/core-js/modules/es.promise.finally.js","webpack://profectus/./node_modules/core-js/modules/es.promise.js","webpack://profectus/./node_modules/core-js/modules/es.reflect.has.js","webpack://profectus/./node_modules/core-js/modules/es.reflect.own-keys.js","webpack://profectus/./node_modules/core-js/modules/es.reflect.to-string-tag.js","webpack://profectus/./node_modules/core-js/modules/es.regexp.exec.js","webpack://profectus/./node_modules/core-js/modules/es.regexp.test.js","webpack://profectus/./node_modules/core-js/modules/es.regexp.to-string.js","webpack://profectus/./node_modules/core-js/modules/es.set.js","webpack://profectus/./node_modules/core-js/modules/es.string.includes.js","webpack://profectus/./node_modules/core-js/modules/es.string.iterator.js","webpack://profectus/./node_modules/core-js/modules/es.string.link.js","webpack://profectus/./node_modules/core-js/modules/es.string.repeat.js","webpack://profectus/./node_modules/core-js/modules/es.string.replace.js","webpack://profectus/./node_modules/core-js/modules/es.string.small.js","webpack://profectus/./node_modules/core-js/modules/es.string.split.js","webpack://profectus/./node_modules/core-js/modules/es.string.sub.js","webpack://profectus/./node_modules/core-js/modules/es.string.trim.js","webpack://profectus/./node_modules/core-js/modules/es.symbol.description.js","webpack://profectus/./node_modules/core-js/modules/es.symbol.iterator.js","webpack://profectus/./node_modules/core-js/modules/es.symbol.js","webpack://profectus/./node_modules/core-js/modules/web.dom-collections.for-each.js","webpack://profectus/./node_modules/core-js/modules/web.dom-collections.iterator.js","webpack://profectus/./node_modules/core-js/modules/web.dom-exception.constructor.js","webpack://profectus/./node_modules/core-js/modules/web.dom-exception.stack.js","webpack://profectus/./node_modules/core-js/modules/web.dom-exception.to-string-tag.js","webpack://profectus/./node_modules/earcut/src/earcut.js","webpack://profectus/./node_modules/lz-string/libs/lz-string.js","webpack://profectus/./node_modules/object-assign/index.js","webpack://profectus/./node_modules/promise-polyfill/src/finally.js","webpack://profectus/./node_modules/promise-polyfill/src/allSettled.js","webpack://profectus/./node_modules/promise-polyfill/src/index.js","webpack://profectus/./node_modules/@pixi/polyfill/dist/esm/polyfill.js","webpack://profectus/./node_modules/@pixi/accessibility/dist/esm/accessibility.js","webpack://profectus/./node_modules/@pixi/interaction/dist/esm/interaction.js","webpack://profectus/./node_modules/@pixi/app/dist/esm/app.js","webpack://profectus/./node_modules/@pixi/extract/dist/esm/extract.js","webpack://profectus/./node_modules/@pixi/loaders/dist/esm/loaders.js","webpack://profectus/./node_modules/@pixi/compressed-textures/dist/esm/compressed-textures.js","webpack://profectus/./node_modules/@pixi/particle-container/dist/esm/particle-container.js","webpack://profectus/./node_modules/@pixi/graphics/dist/esm/graphics.js","webpack://profectus/./node_modules/@pixi/text/dist/esm/text.js","webpack://profectus/./node_modules/@pixi/prepare/dist/esm/prepare.js","webpack://profectus/./node_modules/@pixi/spritesheet/dist/esm/spritesheet.js","webpack://profectus/./node_modules/@pixi/sprite-tiling/dist/esm/sprite-tiling.js","webpack://profectus/./node_modules/@pixi/mesh/dist/esm/mesh.js","webpack://profectus/./node_modules/@pixi/text-bitmap/dist/esm/text-bitmap.js","webpack://profectus/./node_modules/@pixi/filter-alpha/dist/esm/filter-alpha.js","webpack://profectus/./node_modules/@pixi/filter-blur/dist/esm/filter-blur.js","webpack://profectus/./node_modules/@pixi/filter-color-matrix/dist/esm/filter-color-matrix.js","webpack://profectus/./node_modules/@pixi/filter-displacement/dist/esm/filter-displacement.js","webpack://profectus/./node_modules/@pixi/filter-fxaa/dist/esm/filter-fxaa.js","webpack://profectus/./node_modules/@pixi/filter-noise/dist/esm/filter-noise.js","webpack://profectus/./node_modules/@pixi/mixin-cache-as-bitmap/dist/esm/mixin-cache-as-bitmap.js","webpack://profectus/./node_modules/@pixi/mixin-get-child-by-name/dist/esm/mixin-get-child-by-name.js","webpack://profectus/./node_modules/@pixi/mixin-get-global-position/dist/esm/mixin-get-global-position.js","webpack://profectus/./node_modules/@pixi/mesh-extras/dist/esm/mesh-extras.js","webpack://profectus/./node_modules/@pixi/sprite-animated/dist/esm/sprite-animated.js","webpack://profectus/./node_modules/pixi.js/dist/esm/pixi.js","webpack://profectus/./node_modules/querystring/decode.js","webpack://profectus/./node_modules/querystring/encode.js","webpack://profectus/./node_modules/querystring/index.js","webpack://profectus/./node_modules/regenerator-runtime/runtime.js","webpack://profectus/./node_modules/sortablejs/modular/sortable.esm.js","webpack://profectus/./node_modules/url/node_modules/punycode/punycode.js","webpack://profectus/./node_modules/url/url.js","webpack://profectus/./node_modules/url/util.js","webpack://profectus/./node_modules/vue-loader/dist/exportHelper.js","webpack://profectus/./node_modules/vue-next-select/dist/vue-next-select.es.prod.js","webpack://profectus/./node_modules/vue-textarea-autosize/dist/vue-textarea-autosize.esm.js","webpack://profectus/./node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js","webpack://profectus/./node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js","webpack://profectus/./node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js","webpack://profectus/./node_modules/@vue/compiler-core/dist/compiler-core.esm-bundler.js","webpack://profectus/./node_modules/@vue/compiler-dom/dist/compiler-dom.esm-bundler.js","webpack://profectus/./node_modules/vue/dist/vue.esm-bundler.js","webpack://profectus/./node_modules/vuedraggable/dist/vuedraggable.umd.js","webpack://profectus/./node_modules/nanoevents/index.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/classCallCheck.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/createClass.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/defineProperty.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/objectSpread2.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/slicedToArray.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/iterableToArray.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/typeof.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","webpack://profectus/./node_modules/vue-toastification/dist/index.mjs"],"sourcesContent":["/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\nexport { ALPHA_MODES, BLEND_MODES, BUFFER_BITS, BUFFER_TYPE, CLEAR_MODES, DRAW_MODES, ENV, FORMATS, GC_MODES, MASK_TYPES, MIPMAP_MODES, MSAA_QUALITY, PRECISION, RENDERER_TYPE, SAMPLER_TYPES, SCALE_MODES, TARGETS, TYPES, WRAP_MODES };\n//# sourceMappingURL=constants.js.map\n","/*!\n * @pixi/core - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/core is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nimport { ENV, ALPHA_MODES, SCALE_MODES, FORMATS, TYPES, TARGETS, MIPMAP_MODES, MSAA_QUALITY, BUFFER_TYPE, CLEAR_MODES, DRAW_MODES, BUFFER_BITS, MASK_TYPES, PRECISION, BLEND_MODES, GC_MODES, SAMPLER_TYPES, WRAP_MODES, RENDERER_TYPE } from '@pixi/constants';\nimport { isMobile, isPow2, BaseTextureCache, TextureCache, uid, EventEmitter, determineCrossOrigin, getResolutionOfUrl, deprecation, nextPow2, getBufferType, ProgramCache, removeItems, hex2string, hex2rgb, sayHello, isWebGLSupported, premultiplyBlendMode, log2, premultiplyTint } from '@pixi/utils';\nimport { Runner } from '@pixi/runner';\nimport { Ticker } from '@pixi/ticker';\nimport { groupD8, Rectangle, Point, Matrix } from '@pixi/math';\n\n/**\n * The maximum support for using WebGL. If a device does not\n * support WebGL version, for instance WebGL 2, it will still\n * attempt to fallback support to WebGL 1. If you want to\n * explicitly remove feature support to target a more stable\n * baseline, prefer a lower environment.\n *\n * Due to {@link https://bugs.chromium.org/p/chromium/issues/detail?id=934823|bug in chromium}\n * we disable webgl2 by default for all non-apple mobile devices.\n *\n * @static\n * @name PREFER_ENV\n * @memberof PIXI.settings\n * @type {number}\n * @default PIXI.ENV.WEBGL2\n */\nsettings.PREFER_ENV = isMobile.any ? ENV.WEBGL : ENV.WEBGL2;\n/**\n * If set to `true`, *only* Textures and BaseTexture objects stored\n * in the caches ({@link PIXI.utils.TextureCache TextureCache} and\n * {@link PIXI.utils.BaseTextureCache BaseTextureCache}) can be\n * used when calling {@link PIXI.Texture.from Texture.from} or\n * {@link PIXI.BaseTexture.from BaseTexture.from}.\n * Otherwise, these `from` calls throw an exception. Using this property\n * can be useful if you want to enforce preloading all assets with\n * {@link PIXI.Loader Loader}.\n *\n * @static\n * @name STRICT_TEXTURE_CACHE\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\nsettings.STRICT_TEXTURE_CACHE = false;\n\n/**\n * Collection of installed resource types, class must extend {@link PIXI.Resource}.\n * @example\n * class CustomResource extends PIXI.Resource {\n * // MUST have source, options constructor signature\n * // for auto-detected resources to be created.\n * constructor(source, options) {\n * super();\n * }\n * upload(renderer, baseTexture, glTexture) {\n * // upload with GL\n * return true;\n * }\n * // used to auto-detect resource\n * static test(source, extension) {\n * return extension === 'xyz'|| source instanceof SomeClass;\n * }\n * }\n * // Install the new resource type\n * PIXI.INSTALLED.push(CustomResource);\n *\n * @memberof PIXI\n * @type {Array<PIXI.IResourcePlugin>}\n * @static\n * @readonly\n */\nvar INSTALLED = [];\n/**\n * Create a resource element from a single source element. This\n * auto-detects which type of resource to create. All resources that\n * are auto-detectable must have a static `test` method and a constructor\n * with the arguments `(source, options?)`. Currently, the supported\n * resources for auto-detection include:\n * - {@link PIXI.ImageResource}\n * - {@link PIXI.CanvasResource}\n * - {@link PIXI.VideoResource}\n * - {@link PIXI.SVGResource}\n * - {@link PIXI.BufferResource}\n * @static\n * @memberof PIXI\n * @function autoDetectResource\n * @param {string|*} source - Resource source, this can be the URL to the resource,\n * a typed-array (for BufferResource), HTMLVideoElement, SVG data-uri\n * or any other resource that can be auto-detected. If not resource is\n * detected, it's assumed to be an ImageResource.\n * @param {object} [options] - Pass-through options to use for Resource\n * @param {number} [options.width] - Width of BufferResource or SVG rasterization\n * @param {number} [options.height] - Height of BufferResource or SVG rasterization\n * @param {boolean} [options.autoLoad=true] - Image, SVG and Video flag to start loading\n * @param {number} [options.scale=1] - SVG source scale. Overridden by width, height\n * @param {boolean} [options.createBitmap=PIXI.settings.CREATE_IMAGE_BITMAP] - Image option to create Bitmap object\n * @param {boolean} [options.crossorigin=true] - Image and Video option to set crossOrigin\n * @param {boolean} [options.autoPlay=true] - Video option to start playing video immediately\n * @param {number} [options.updateFPS=0] - Video option to update how many times a second the\n * texture should be updated from the video. Leave at 0 to update at every render\n * @return {PIXI.Resource} The created resource.\n */\nfunction autoDetectResource(source, options) {\n if (!source) {\n return null;\n }\n var extension = '';\n if (typeof source === 'string') {\n // search for file extension: period, 3-4 chars, then ?, # or EOL\n var result = (/\\.(\\w{3,4})(?:$|\\?|#)/i).exec(source);\n if (result) {\n extension = result[1].toLowerCase();\n }\n }\n for (var i = INSTALLED.length - 1; i >= 0; --i) {\n var ResourcePlugin = INSTALLED[i];\n if (ResourcePlugin.test && ResourcePlugin.test(source, extension)) {\n return new ResourcePlugin(source, options);\n }\n }\n throw new Error('Unrecognized source type to auto-detect Resource');\n}\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nvar __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\n var arguments$1 = arguments;\n\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments$1[i];\r\n for (var p in s) { if (Object.prototype.hasOwnProperty.call(s, p)) { t[p] = s[p]; } }\r\n }\r\n return t;\r\n };\r\n return __assign.apply(this, arguments);\r\n};\r\n\r\nfunction __rest(s, e) {\r\n var t = {};\r\n for (var p in s) { if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n { t[p] = s[p]; } }\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n { for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { if (e.indexOf(p[i]) < 0)\r\n { t[p[i]] = s[p[i]]; } } }\r\n return t;\r\n}\n\n/**\n * Base resource class for textures that manages validation and uploading, depending on its type.\n *\n * Uploading of a base texture to the GPU is required.\n *\n * @memberof PIXI\n */\nvar Resource = /** @class */ (function () {\n /**\n * @param width - Width of the resource\n * @param height - Height of the resource\n */\n function Resource(width, height) {\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n this._width = width;\n this._height = height;\n this.destroyed = false;\n this.internal = false;\n this.onResize = new Runner('setRealSize');\n this.onUpdate = new Runner('update');\n this.onError = new Runner('onError');\n }\n /**\n * Bind to a parent BaseTexture\n *\n * @param baseTexture - Parent texture\n */\n Resource.prototype.bind = function (baseTexture) {\n this.onResize.add(baseTexture);\n this.onUpdate.add(baseTexture);\n this.onError.add(baseTexture);\n // Call a resize immediate if we already\n // have the width and height of the resource\n if (this._width || this._height) {\n this.onResize.emit(this._width, this._height);\n }\n };\n /**\n * Unbind to a parent BaseTexture\n *\n * @param baseTexture - Parent texture\n */\n Resource.prototype.unbind = function (baseTexture) {\n this.onResize.remove(baseTexture);\n this.onUpdate.remove(baseTexture);\n this.onError.remove(baseTexture);\n };\n /**\n * Trigger a resize event\n *\n * @param width - X dimension\n * @param height - Y dimension\n */\n Resource.prototype.resize = function (width, height) {\n if (width !== this._width || height !== this._height) {\n this._width = width;\n this._height = height;\n this.onResize.emit(width, height);\n }\n };\n Object.defineProperty(Resource.prototype, \"valid\", {\n /**\n * Has been validated\n *\n * @readonly\n */\n get: function () {\n return !!this._width && !!this._height;\n },\n enumerable: false,\n configurable: true\n });\n /** Has been updated trigger event. */\n Resource.prototype.update = function () {\n if (!this.destroyed) {\n this.onUpdate.emit();\n }\n };\n /**\n * This can be overridden to start preloading a resource\n * or do any other prepare step.\n *\n * @protected\n * @return Handle the validate event\n */\n Resource.prototype.load = function () {\n return Promise.resolve(this);\n };\n Object.defineProperty(Resource.prototype, \"width\", {\n /**\n * The width of the resource.\n *\n * @readonly\n */\n get: function () {\n return this._width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Resource.prototype, \"height\", {\n /**\n * The height of the resource.\n *\n * @readonly\n */\n get: function () {\n return this._height;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Set the style, optional to override\n *\n * @param renderer - yeah, renderer!\n * @param baseTexture - the texture\n * @param glTexture - texture instance for this webgl context\n * @returns - `true` is success\n */\n Resource.prototype.style = function (_renderer, _baseTexture, _glTexture) {\n return false;\n };\n /** Clean up anything, this happens when destroying is ready. */\n Resource.prototype.dispose = function () {\n // override\n };\n /**\n * Call when destroying resource, unbind any BaseTexture object\n * before calling this method, as reference counts are maintained\n * internally.\n */\n Resource.prototype.destroy = function () {\n if (!this.destroyed) {\n this.destroyed = true;\n this.dispose();\n this.onError.removeAll();\n this.onError = null;\n this.onResize.removeAll();\n this.onResize = null;\n this.onUpdate.removeAll();\n this.onUpdate = null;\n }\n };\n /**\n * Abstract, used to auto-detect resource type.\n *\n * @param {*} source - The source object\n * @param {string} extension - The extension of source, if set\n */\n Resource.test = function (_source, _extension) {\n return false;\n };\n return Resource;\n}());\n\n/**\n * @interface SharedArrayBuffer\n */\n/**\n * Buffer resource with data of typed array.\n *\n * @memberof PIXI\n */\nvar BufferResource = /** @class */ (function (_super) {\n __extends(BufferResource, _super);\n /**\n * @param source - Source buffer\n * @param options - Options\n * @param {number} options.width - Width of the texture\n * @param {number} options.height - Height of the texture\n */\n function BufferResource(source, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height;\n if (!width || !height) {\n throw new Error('BufferResource width or height invalid');\n }\n _this = _super.call(this, width, height) || this;\n _this.data = source;\n return _this;\n }\n /**\n * Upload the texture to the GPU.\n *\n * @param renderer - Upload to the renderer\n * @param baseTexture - Reference to parent texture\n * @param glTexture - glTexture\n * @returns - true is success\n */\n BufferResource.prototype.upload = function (renderer, baseTexture, glTexture) {\n var gl = renderer.gl;\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, baseTexture.alphaMode === ALPHA_MODES.UNPACK);\n var width = baseTexture.realWidth;\n var height = baseTexture.realHeight;\n if (glTexture.width === width && glTexture.height === height) {\n gl.texSubImage2D(baseTexture.target, 0, 0, 0, width, height, baseTexture.format, glTexture.type, this.data);\n }\n else {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(baseTexture.target, 0, glTexture.internalFormat, width, height, 0, baseTexture.format, glTexture.type, this.data);\n }\n return true;\n };\n /** Destroy and don't use after this. */\n BufferResource.prototype.dispose = function () {\n this.data = null;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if <canvas>\n */\n BufferResource.test = function (source) {\n return source instanceof Float32Array\n || source instanceof Uint8Array\n || source instanceof Uint32Array;\n };\n return BufferResource;\n}(Resource));\n\nvar defaultBufferOptions = {\n scaleMode: SCALE_MODES.NEAREST,\n format: FORMATS.RGBA,\n alphaMode: ALPHA_MODES.NPM,\n};\n/**\n * A Texture stores the information that represents an image.\n * All textures have a base texture, which contains information about the source.\n * Therefore you can have many textures all using a single BaseTexture\n *\n * @memberof PIXI\n * @typeParam R - The BaseTexture's Resource type.\n * @typeParam RO - The options for constructing resource.\n */\nvar BaseTexture = /** @class */ (function (_super) {\n __extends(BaseTexture, _super);\n /**\n * @param {PIXI.Resource|string|HTMLImageElement|HTMLCanvasElement|HTMLVideoElement} [resource=null] -\n * The current resource to use, for things that aren't Resource objects, will be converted\n * into a Resource.\n * @param options - Collection of options\n * @param {PIXI.MIPMAP_MODES} [options.mipmap=PIXI.settings.MIPMAP_TEXTURES] - If mipmapping is enabled for texture\n * @param {number} [options.anisotropicLevel=PIXI.settings.ANISOTROPIC_LEVEL] - Anisotropic filtering level of texture\n * @param {PIXI.WRAP_MODES} [options.wrapMode=PIXI.settings.WRAP_MODE] - Wrap mode for textures\n * @param {PIXI.SCALE_MODES} [options.scaleMode=PIXI.settings.SCALE_MODE] - Default scale mode, linear, nearest\n * @param {PIXI.FORMATS} [options.format=PIXI.FORMATS.RGBA] - GL format type\n * @param {PIXI.TYPES} [options.type=PIXI.TYPES.UNSIGNED_BYTE] - GL data type\n * @param {PIXI.TARGETS} [options.target=PIXI.TARGETS.TEXTURE_2D] - GL texture target\n * @param {PIXI.ALPHA_MODES} [options.alphaMode=PIXI.ALPHA_MODES.UNPACK] - Pre multiply the image alpha\n * @param {number} [options.width=0] - Width of the texture\n * @param {number} [options.height=0] - Height of the texture\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - Resolution of the base texture\n * @param {object} [options.resourceOptions] - Optional resource options,\n * see {@link PIXI.autoDetectResource autoDetectResource}\n */\n function BaseTexture(resource, options) {\n if (resource === void 0) { resource = null; }\n if (options === void 0) { options = null; }\n var _this = _super.call(this) || this;\n options = options || {};\n var alphaMode = options.alphaMode, mipmap = options.mipmap, anisotropicLevel = options.anisotropicLevel, scaleMode = options.scaleMode, width = options.width, height = options.height, wrapMode = options.wrapMode, format = options.format, type = options.type, target = options.target, resolution = options.resolution, resourceOptions = options.resourceOptions;\n // Convert the resource to a Resource object\n if (resource && !(resource instanceof Resource)) {\n resource = autoDetectResource(resource, resourceOptions);\n resource.internal = true;\n }\n _this.resolution = resolution || settings.RESOLUTION;\n _this.width = Math.round((width || 0) * _this.resolution) / _this.resolution;\n _this.height = Math.round((height || 0) * _this.resolution) / _this.resolution;\n _this._mipmap = mipmap !== undefined ? mipmap : settings.MIPMAP_TEXTURES;\n _this.anisotropicLevel = anisotropicLevel !== undefined ? anisotropicLevel : settings.ANISOTROPIC_LEVEL;\n _this._wrapMode = wrapMode || settings.WRAP_MODE;\n _this._scaleMode = scaleMode !== undefined ? scaleMode : settings.SCALE_MODE;\n _this.format = format || FORMATS.RGBA;\n _this.type = type || TYPES.UNSIGNED_BYTE;\n _this.target = target || TARGETS.TEXTURE_2D;\n _this.alphaMode = alphaMode !== undefined ? alphaMode : ALPHA_MODES.UNPACK;\n _this.uid = uid();\n _this.touched = 0;\n _this.isPowerOfTwo = false;\n _this._refreshPOT();\n _this._glTextures = {};\n _this.dirtyId = 0;\n _this.dirtyStyleId = 0;\n _this.cacheId = null;\n _this.valid = width > 0 && height > 0;\n _this.textureCacheIds = [];\n _this.destroyed = false;\n _this.resource = null;\n _this._batchEnabled = 0;\n _this._batchLocation = 0;\n _this.parentTextureArray = null;\n /**\n * Fired when a not-immediately-available source finishes loading.\n *\n * @protected\n * @event PIXI.BaseTexture#loaded\n * @param {PIXI.BaseTexture} baseTexture - Resource loaded.\n */\n /**\n * Fired when a not-immediately-available source fails to load.\n *\n * @protected\n * @event PIXI.BaseTexture#error\n * @param {PIXI.BaseTexture} baseTexture - Resource errored.\n * @param {ErrorEvent} event - Load error event.\n */\n /**\n * Fired when BaseTexture is updated.\n *\n * @protected\n * @event PIXI.BaseTexture#loaded\n * @param {PIXI.BaseTexture} baseTexture - Resource loaded.\n */\n /**\n * Fired when BaseTexture is updated.\n *\n * @protected\n * @event PIXI.BaseTexture#update\n * @param {PIXI.BaseTexture} baseTexture - Instance of texture being updated.\n */\n /**\n * Fired when BaseTexture is destroyed.\n *\n * @protected\n * @event PIXI.BaseTexture#dispose\n * @param {PIXI.BaseTexture} baseTexture - Instance of texture being destroyed.\n */\n // Set the resource\n _this.setResource(resource);\n return _this;\n }\n Object.defineProperty(BaseTexture.prototype, \"realWidth\", {\n /**\n * Pixel width of the source of this texture\n *\n * @readonly\n */\n get: function () {\n return Math.round(this.width * this.resolution);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"realHeight\", {\n /**\n * Pixel height of the source of this texture\n *\n * @readonly\n */\n get: function () {\n return Math.round(this.height * this.resolution);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"mipmap\", {\n /**\n * Mipmap mode of the texture, affects downscaled images\n *\n * @default PIXI.settings.MIPMAP_TEXTURES\n */\n get: function () {\n return this._mipmap;\n },\n set: function (value) {\n if (this._mipmap !== value) {\n this._mipmap = value;\n this.dirtyStyleId++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"scaleMode\", {\n /**\n * The scale mode to apply when scaling this texture\n *\n * @default PIXI.settings.SCALE_MODE\n */\n get: function () {\n return this._scaleMode;\n },\n set: function (value) {\n if (this._scaleMode !== value) {\n this._scaleMode = value;\n this.dirtyStyleId++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"wrapMode\", {\n /**\n * How the texture wraps\n *\n * @default PIXI.settings.WRAP_MODE\n */\n get: function () {\n return this._wrapMode;\n },\n set: function (value) {\n if (this._wrapMode !== value) {\n this._wrapMode = value;\n this.dirtyStyleId++;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Changes style options of BaseTexture\n *\n * @param scaleMode - Pixi scalemode\n * @param mipmap - enable mipmaps\n * @returns - this\n */\n BaseTexture.prototype.setStyle = function (scaleMode, mipmap) {\n var dirty;\n if (scaleMode !== undefined && scaleMode !== this.scaleMode) {\n this.scaleMode = scaleMode;\n dirty = true;\n }\n if (mipmap !== undefined && mipmap !== this.mipmap) {\n this.mipmap = mipmap;\n dirty = true;\n }\n if (dirty) {\n this.dirtyStyleId++;\n }\n return this;\n };\n /**\n * Changes w/h/resolution. Texture becomes valid if width and height are greater than zero.\n *\n * @param desiredWidth - Desired visual width\n * @param desiredHeight - Desired visual height\n * @param resolution - Optionally set resolution\n * @returns - this\n */\n BaseTexture.prototype.setSize = function (desiredWidth, desiredHeight, resolution) {\n resolution = resolution || this.resolution;\n return this.setRealSize(desiredWidth * resolution, desiredHeight * resolution, resolution);\n };\n /**\n * Sets real size of baseTexture, preserves current resolution.\n *\n * @param realWidth - Full rendered width\n * @param realHeight - Full rendered height\n * @param resolution - Optionally set resolution\n * @returns - this\n */\n BaseTexture.prototype.setRealSize = function (realWidth, realHeight, resolution) {\n this.resolution = resolution || this.resolution;\n this.width = Math.round(realWidth) / this.resolution;\n this.height = Math.round(realHeight) / this.resolution;\n this._refreshPOT();\n this.update();\n return this;\n };\n /**\n * Refresh check for isPowerOfTwo texture based on size\n *\n * @private\n */\n BaseTexture.prototype._refreshPOT = function () {\n this.isPowerOfTwo = isPow2(this.realWidth) && isPow2(this.realHeight);\n };\n /**\n * Changes resolution\n *\n * @param resolution - res\n * @returns - this\n */\n BaseTexture.prototype.setResolution = function (resolution) {\n var oldResolution = this.resolution;\n if (oldResolution === resolution) {\n return this;\n }\n this.resolution = resolution;\n if (this.valid) {\n this.width = Math.round(this.width * oldResolution) / resolution;\n this.height = Math.round(this.height * oldResolution) / resolution;\n this.emit('update', this);\n }\n this._refreshPOT();\n return this;\n };\n /**\n * Sets the resource if it wasn't set. Throws error if resource already present\n *\n * @param resource - that is managing this BaseTexture\n * @returns - this\n */\n BaseTexture.prototype.setResource = function (resource) {\n if (this.resource === resource) {\n return this;\n }\n if (this.resource) {\n throw new Error('Resource can be set only once');\n }\n resource.bind(this);\n this.resource = resource;\n return this;\n };\n /** Invalidates the object. Texture becomes valid if width and height are greater than zero. */\n BaseTexture.prototype.update = function () {\n if (!this.valid) {\n if (this.width > 0 && this.height > 0) {\n this.valid = true;\n this.emit('loaded', this);\n this.emit('update', this);\n }\n }\n else {\n this.dirtyId++;\n this.dirtyStyleId++;\n this.emit('update', this);\n }\n };\n /**\n * Handle errors with resources.\n *\n * @private\n * @param event - Error event emitted.\n */\n BaseTexture.prototype.onError = function (event) {\n this.emit('error', this, event);\n };\n /**\n * Destroys this base texture.\n * The method stops if resource doesn't want this texture to be destroyed.\n * Removes texture from all caches.\n */\n BaseTexture.prototype.destroy = function () {\n // remove and destroy the resource\n if (this.resource) {\n this.resource.unbind(this);\n // only destroy resourced created internally\n if (this.resource.internal) {\n this.resource.destroy();\n }\n this.resource = null;\n }\n if (this.cacheId) {\n delete BaseTextureCache[this.cacheId];\n delete TextureCache[this.cacheId];\n this.cacheId = null;\n }\n // finally let the WebGL renderer know..\n this.dispose();\n BaseTexture.removeFromCache(this);\n this.textureCacheIds = null;\n this.destroyed = true;\n };\n /**\n * Frees the texture from WebGL memory without destroying this texture object.\n * This means you can still use the texture later which will upload it to GPU\n * memory again.\n *\n * @fires PIXI.BaseTexture#dispose\n */\n BaseTexture.prototype.dispose = function () {\n this.emit('dispose', this);\n };\n /** Utility function for BaseTexture|Texture cast. */\n BaseTexture.prototype.castToBaseTexture = function () {\n return this;\n };\n /**\n * Helper function that creates a base texture based on the source you provide.\n * The source can be - image url, image element, canvas element. If the\n * source is an image url or an image element and not in the base texture\n * cache, it will be created and loaded.\n *\n * @static\n * @param {string|HTMLImageElement|HTMLCanvasElement|SVGElement|HTMLVideoElement} source - The\n * source to create base texture from.\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @param {string} [options.pixiIdPrefix=pixiid] - If a source has no id, this is the prefix of the generated id\n * @param {boolean} [strict] - Enforce strict-mode, see {@link PIXI.settings.STRICT_TEXTURE_CACHE}.\n * @returns {PIXI.BaseTexture} The new base texture.\n */\n BaseTexture.from = function (source, options, strict) {\n if (strict === void 0) { strict = settings.STRICT_TEXTURE_CACHE; }\n var isFrame = typeof source === 'string';\n var cacheId = null;\n if (isFrame) {\n cacheId = source;\n }\n else {\n if (!source._pixiId) {\n var prefix = (options && options.pixiIdPrefix) || 'pixiid';\n source._pixiId = prefix + \"_\" + uid();\n }\n cacheId = source._pixiId;\n }\n var baseTexture = BaseTextureCache[cacheId];\n // Strict-mode rejects invalid cacheIds\n if (isFrame && strict && !baseTexture) {\n throw new Error(\"The cacheId \\\"\" + cacheId + \"\\\" does not exist in BaseTextureCache.\");\n }\n if (!baseTexture) {\n baseTexture = new BaseTexture(source, options);\n baseTexture.cacheId = cacheId;\n BaseTexture.addToCache(baseTexture, cacheId);\n }\n return baseTexture;\n };\n /**\n * Create a new BaseTexture with a BufferResource from a Float32Array.\n * RGBA values are floats from 0 to 1.\n *\n * @param {Float32Array|Uint8Array} buffer - The optional array to use, if no data\n * is provided, a new Float32Array is created.\n * @param width - Width of the resource\n * @param height - Height of the resource\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @return - The resulting new BaseTexture\n */\n BaseTexture.fromBuffer = function (buffer, width, height, options) {\n buffer = buffer || new Float32Array(width * height * 4);\n var resource = new BufferResource(buffer, { width: width, height: height });\n var type = buffer instanceof Float32Array ? TYPES.FLOAT : TYPES.UNSIGNED_BYTE;\n return new BaseTexture(resource, Object.assign(defaultBufferOptions, options || { width: width, height: height, type: type }));\n };\n /**\n * Adds a BaseTexture to the global BaseTextureCache. This cache is shared across the whole PIXI object.\n *\n *\n * @param {PIXI.BaseTexture} baseTexture - The BaseTexture to add to the cache.\n * @param {string} id - The id that the BaseTexture will be stored against.\n */\n BaseTexture.addToCache = function (baseTexture, id) {\n if (id) {\n if (baseTexture.textureCacheIds.indexOf(id) === -1) {\n baseTexture.textureCacheIds.push(id);\n }\n if (BaseTextureCache[id]) {\n // eslint-disable-next-line no-console\n console.warn(\"BaseTexture added to the cache with an id [\" + id + \"] that already had an entry\");\n }\n BaseTextureCache[id] = baseTexture;\n }\n };\n /**\n * Remove a BaseTexture from the global BaseTextureCache.\n *\n * @param {string|PIXI.BaseTexture} baseTexture - id of a BaseTexture to be removed, or a BaseTexture instance itself.\n * @return {PIXI.BaseTexture|null} The BaseTexture that was removed.\n */\n BaseTexture.removeFromCache = function (baseTexture) {\n if (typeof baseTexture === 'string') {\n var baseTextureFromCache = BaseTextureCache[baseTexture];\n if (baseTextureFromCache) {\n var index = baseTextureFromCache.textureCacheIds.indexOf(baseTexture);\n if (index > -1) {\n baseTextureFromCache.textureCacheIds.splice(index, 1);\n }\n delete BaseTextureCache[baseTexture];\n return baseTextureFromCache;\n }\n }\n else if (baseTexture && baseTexture.textureCacheIds) {\n for (var i = 0; i < baseTexture.textureCacheIds.length; ++i) {\n delete BaseTextureCache[baseTexture.textureCacheIds[i]];\n }\n baseTexture.textureCacheIds.length = 0;\n return baseTexture;\n }\n return null;\n };\n /** Global number of the texture batch, used by multi-texture renderers. */\n BaseTexture._globalBatch = 0;\n return BaseTexture;\n}(EventEmitter));\n\n/**\n * Resource that can manage several resource (items) inside.\n * All resources need to have the same pixel size.\n * Parent class for CubeResource and ArrayResource\n *\n * @memberof PIXI\n */\nvar AbstractMultiResource = /** @class */ (function (_super) {\n __extends(AbstractMultiResource, _super);\n /**\n * @param length\n * @param options - Options to for Resource constructor\n * @param {number} [options.width] - Width of the resource\n * @param {number} [options.height] - Height of the resource\n */\n function AbstractMultiResource(length, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height;\n _this = _super.call(this, width, height) || this;\n _this.items = [];\n _this.itemDirtyIds = [];\n for (var i = 0; i < length; i++) {\n var partTexture = new BaseTexture();\n _this.items.push(partTexture);\n // -2 - first run of texture array upload\n // -1 - texture item was allocated\n // >=0 - texture item uploaded , in sync with items[i].dirtyId\n _this.itemDirtyIds.push(-2);\n }\n _this.length = length;\n _this._load = null;\n _this.baseTexture = null;\n return _this;\n }\n /**\n * Used from ArrayResource and CubeResource constructors.\n *\n * @param resources - Can be resources, image elements, canvas, etc. ,\n * length should be same as constructor length\n * @param options - Detect options for resources\n */\n AbstractMultiResource.prototype.initFromArray = function (resources, options) {\n for (var i = 0; i < this.length; i++) {\n if (!resources[i]) {\n continue;\n }\n if (resources[i].castToBaseTexture) {\n this.addBaseTextureAt(resources[i].castToBaseTexture(), i);\n }\n else if (resources[i] instanceof Resource) {\n this.addResourceAt(resources[i], i);\n }\n else {\n this.addResourceAt(autoDetectResource(resources[i], options), i);\n }\n }\n };\n /** Destroy this BaseImageResource. */\n AbstractMultiResource.prototype.dispose = function () {\n for (var i = 0, len = this.length; i < len; i++) {\n this.items[i].destroy();\n }\n this.items = null;\n this.itemDirtyIds = null;\n this._load = null;\n };\n /**\n * Set a resource by ID\n *\n * @param resource\n * @param index - Zero-based index of resource to set\n * @return - Instance for chaining\n */\n AbstractMultiResource.prototype.addResourceAt = function (resource, index) {\n if (!this.items[index]) {\n throw new Error(\"Index \" + index + \" is out of bounds\");\n }\n // Inherit the first resource dimensions\n if (resource.valid && !this.valid) {\n this.resize(resource.width, resource.height);\n }\n this.items[index].setResource(resource);\n return this;\n };\n /** Set the parent base texture. */\n AbstractMultiResource.prototype.bind = function (baseTexture) {\n if (this.baseTexture !== null) {\n throw new Error('Only one base texture per TextureArray is allowed');\n }\n _super.prototype.bind.call(this, baseTexture);\n for (var i = 0; i < this.length; i++) {\n this.items[i].parentTextureArray = baseTexture;\n this.items[i].on('update', baseTexture.update, baseTexture);\n }\n };\n /** Unset the parent base texture. */\n AbstractMultiResource.prototype.unbind = function (baseTexture) {\n _super.prototype.unbind.call(this, baseTexture);\n for (var i = 0; i < this.length; i++) {\n this.items[i].parentTextureArray = null;\n this.items[i].off('update', baseTexture.update, baseTexture);\n }\n };\n /**\n * Load all the resources simultaneously\n *\n * @return - When load is resolved\n */\n AbstractMultiResource.prototype.load = function () {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n var resources = this.items.map(function (item) { return item.resource; }).filter(function (item) { return item; });\n // TODO: also implement load part-by-part strategy\n var promises = resources.map(function (item) { return item.load(); });\n this._load = Promise.all(promises)\n .then(function () {\n var _a = _this.items[0], realWidth = _a.realWidth, realHeight = _a.realHeight;\n _this.resize(realWidth, realHeight);\n return Promise.resolve(_this);\n });\n return this._load;\n };\n return AbstractMultiResource;\n}(Resource));\n\n/**\n * A resource that contains a number of sources.\n *\n * @memberof PIXI\n */\nvar ArrayResource = /** @class */ (function (_super) {\n __extends(ArrayResource, _super);\n /**\n * @param source - Number of items in array or the collection\n * of image URLs to use. Can also be resources, image elements, canvas, etc.\n * @param options - Options to apply to {@link PIXI.autoDetectResource}\n * @param {number} [options.width] - Width of the resource\n * @param {number} [options.height] - Height of the resource\n */\n function ArrayResource(source, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height;\n var urls;\n var length;\n if (Array.isArray(source)) {\n urls = source;\n length = source.length;\n }\n else {\n length = source;\n }\n _this = _super.call(this, length, { width: width, height: height }) || this;\n if (urls) {\n _this.initFromArray(urls, options);\n }\n return _this;\n }\n /**\n * Set a baseTexture by ID,\n * ArrayResource just takes resource from it, nothing more\n *\n * @param baseTexture\n * @param index - Zero-based index of resource to set\n * @return - Instance for chaining\n */\n ArrayResource.prototype.addBaseTextureAt = function (baseTexture, index) {\n if (baseTexture.resource) {\n this.addResourceAt(baseTexture.resource, index);\n }\n else {\n throw new Error('ArrayResource does not support RenderTexture');\n }\n return this;\n };\n /** Add binding */\n ArrayResource.prototype.bind = function (baseTexture) {\n _super.prototype.bind.call(this, baseTexture);\n baseTexture.target = TARGETS.TEXTURE_2D_ARRAY;\n };\n /**\n * Upload the resources to the GPU.\n *\n * @param renderer\n * @param texture\n * @param glTexture\n * @returns - whether texture was uploaded\n */\n ArrayResource.prototype.upload = function (renderer, texture, glTexture) {\n var _a = this, length = _a.length, itemDirtyIds = _a.itemDirtyIds, items = _a.items;\n var gl = renderer.gl;\n if (glTexture.dirtyId < 0) {\n gl.texImage3D(gl.TEXTURE_2D_ARRAY, 0, glTexture.internalFormat, this._width, this._height, length, 0, texture.format, glTexture.type, null);\n }\n for (var i = 0; i < length; i++) {\n var item = items[i];\n if (itemDirtyIds[i] < item.dirtyId) {\n itemDirtyIds[i] = item.dirtyId;\n if (item.valid) {\n gl.texSubImage3D(gl.TEXTURE_2D_ARRAY, 0, 0, // xoffset\n 0, // yoffset\n i, // zoffset\n item.resource.width, item.resource.height, 1, texture.format, glTexture.type, item.resource.source);\n }\n }\n }\n return true;\n };\n return ArrayResource;\n}(AbstractMultiResource));\n\n/**\n * Base for all the image/canvas resources.\n *\n * @memberof PIXI\n */\nvar BaseImageResource = /** @class */ (function (_super) {\n __extends(BaseImageResource, _super);\n /**\n * @param {HTMLImageElement|HTMLCanvasElement|HTMLVideoElement|SVGElement} source\n */\n function BaseImageResource(source) {\n var _this = this;\n var sourceAny = source;\n var width = sourceAny.naturalWidth || sourceAny.videoWidth || sourceAny.width;\n var height = sourceAny.naturalHeight || sourceAny.videoHeight || sourceAny.height;\n _this = _super.call(this, width, height) || this;\n _this.source = source;\n _this.noSubImage = false;\n return _this;\n }\n /**\n * Set cross origin based detecting the url and the crossorigin\n *\n * @param element - Element to apply crossOrigin\n * @param url - URL to check\n * @param crossorigin - Cross origin value to use\n */\n BaseImageResource.crossOrigin = function (element, url, crossorigin) {\n if (crossorigin === undefined && url.indexOf('data:') !== 0) {\n element.crossOrigin = determineCrossOrigin(url);\n }\n else if (crossorigin !== false) {\n element.crossOrigin = typeof crossorigin === 'string' ? crossorigin : 'anonymous';\n }\n };\n /**\n * Upload the texture to the GPU.\n *\n * @param renderer - Upload to the renderer\n * @param baseTexture - Reference to parent texture\n * @param glTexture\n * @param {HTMLImageElement|HTMLCanvasElement|HTMLVideoElement|SVGElement} [source] - (optional)\n * @returns - true is success\n */\n BaseImageResource.prototype.upload = function (renderer, baseTexture, glTexture, source) {\n var gl = renderer.gl;\n var width = baseTexture.realWidth;\n var height = baseTexture.realHeight;\n source = source || this.source;\n if (source instanceof HTMLImageElement) {\n if (!source.complete || source.naturalWidth === 0) {\n return false;\n }\n }\n else if (source instanceof HTMLVideoElement) {\n if (source.readyState <= 1) {\n return false;\n }\n }\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, baseTexture.alphaMode === ALPHA_MODES.UNPACK);\n if (!this.noSubImage\n && baseTexture.target === gl.TEXTURE_2D\n && glTexture.width === width\n && glTexture.height === height) {\n gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, baseTexture.format, glTexture.type, source);\n }\n else {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(baseTexture.target, 0, glTexture.internalFormat, baseTexture.format, glTexture.type, source);\n }\n return true;\n };\n /**\n * Checks if source width/height was changed, resize can cause extra baseTexture update.\n * Triggers one update in any case.\n */\n BaseImageResource.prototype.update = function () {\n if (this.destroyed) {\n return;\n }\n var source = this.source;\n var width = source.naturalWidth || source.videoWidth || source.width;\n var height = source.naturalHeight || source.videoHeight || source.height;\n this.resize(width, height);\n _super.prototype.update.call(this);\n };\n /** Destroy this {@link BaseImageResource} */\n BaseImageResource.prototype.dispose = function () {\n this.source = null;\n };\n return BaseImageResource;\n}(Resource));\n\n/**\n * @interface OffscreenCanvas\n */\n/**\n * Resource type for HTMLCanvasElement.\n *\n * @memberof PIXI\n */\nvar CanvasResource = /** @class */ (function (_super) {\n __extends(CanvasResource, _super);\n /**\n * @param source - Canvas element to use\n */\n // eslint-disable-next-line @typescript-eslint/no-useless-constructor\n function CanvasResource(source) {\n return _super.call(this, source) || this;\n }\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is HTMLCanvasElement or OffscreenCanvas\n */\n CanvasResource.test = function (source) {\n var OffscreenCanvas = globalThis.OffscreenCanvas;\n // Check for browsers that don't yet support OffscreenCanvas\n if (OffscreenCanvas && source instanceof OffscreenCanvas) {\n return true;\n }\n return globalThis.HTMLCanvasElement && source instanceof HTMLCanvasElement;\n };\n return CanvasResource;\n}(BaseImageResource));\n\n/**\n * Resource for a CubeTexture which contains six resources.\n *\n * @memberof PIXI\n */\nvar CubeResource = /** @class */ (function (_super) {\n __extends(CubeResource, _super);\n /**\n * @param {Array<string|PIXI.Resource>} [source] - Collection of URLs or resources\n * to use as the sides of the cube.\n * @param options - ImageResource options\n * @param {number} [options.width] - Width of resource\n * @param {number} [options.height] - Height of resource\n * @param {number} [options.autoLoad=true] - Whether to auto-load resources\n * @param {number} [options.linkBaseTexture=true] - In case BaseTextures are supplied,\n * whether to copy them or use\n */\n function CubeResource(source, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height, autoLoad = _a.autoLoad, linkBaseTexture = _a.linkBaseTexture;\n if (source && source.length !== CubeResource.SIDES) {\n throw new Error(\"Invalid length. Got \" + source.length + \", expected 6\");\n }\n _this = _super.call(this, 6, { width: width, height: height }) || this;\n for (var i = 0; i < CubeResource.SIDES; i++) {\n _this.items[i].target = TARGETS.TEXTURE_CUBE_MAP_POSITIVE_X + i;\n }\n _this.linkBaseTexture = linkBaseTexture !== false;\n if (source) {\n _this.initFromArray(source, options);\n }\n if (autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n /**\n * Add binding.\n *\n * @param baseTexture - parent base texture\n */\n CubeResource.prototype.bind = function (baseTexture) {\n _super.prototype.bind.call(this, baseTexture);\n baseTexture.target = TARGETS.TEXTURE_CUBE_MAP;\n };\n CubeResource.prototype.addBaseTextureAt = function (baseTexture, index, linkBaseTexture) {\n if (linkBaseTexture === undefined) {\n linkBaseTexture = this.linkBaseTexture;\n }\n if (!this.items[index]) {\n throw new Error(\"Index \" + index + \" is out of bounds\");\n }\n if (!this.linkBaseTexture\n || baseTexture.parentTextureArray\n || Object.keys(baseTexture._glTextures).length > 0) {\n // copy mode\n if (baseTexture.resource) {\n this.addResourceAt(baseTexture.resource, index);\n }\n else {\n throw new Error(\"CubeResource does not support copying of renderTexture.\");\n }\n }\n else {\n // link mode, the difficult one!\n baseTexture.target = TARGETS.TEXTURE_CUBE_MAP_POSITIVE_X + index;\n baseTexture.parentTextureArray = this.baseTexture;\n this.items[index] = baseTexture;\n }\n if (baseTexture.valid && !this.valid) {\n this.resize(baseTexture.realWidth, baseTexture.realHeight);\n }\n this.items[index] = baseTexture;\n return this;\n };\n /**\n * Upload the resource\n *\n * @returns {boolean} true is success\n */\n CubeResource.prototype.upload = function (renderer, _baseTexture, glTexture) {\n var dirty = this.itemDirtyIds;\n for (var i = 0; i < CubeResource.SIDES; i++) {\n var side = this.items[i];\n if (dirty[i] < side.dirtyId) {\n if (side.valid && side.resource) {\n side.resource.upload(renderer, side, glTexture);\n dirty[i] = side.dirtyId;\n }\n else if (dirty[i] < -1) {\n // either item is not valid yet, either its a renderTexture\n // allocate the memory\n renderer.gl.texImage2D(side.target, 0, glTexture.internalFormat, _baseTexture.realWidth, _baseTexture.realHeight, 0, _baseTexture.format, glTexture.type, null);\n dirty[i] = -1;\n }\n }\n }\n return true;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is an array of 6 elements\n */\n CubeResource.test = function (source) {\n return Array.isArray(source) && source.length === CubeResource.SIDES;\n };\n /** Number of texture sides to store for CubeResources. */\n CubeResource.SIDES = 6;\n return CubeResource;\n}(AbstractMultiResource));\n\n/**\n * Resource type for HTMLImageElement.\n *\n * @memberof PIXI\n */\nvar ImageResource = /** @class */ (function (_super) {\n __extends(ImageResource, _super);\n /**\n * @param source - image source or URL\n * @param options\n * @param {boolean} [options.autoLoad=true] - start loading process\n * @param {boolean} [options.createBitmap=PIXI.settings.CREATE_IMAGE_BITMAP] - whether its required to create\n * a bitmap before upload\n * @param {boolean} [options.crossorigin=true] - Load image using cross origin\n * @param {PIXI.ALPHA_MODES} [options.alphaMode=PIXI.ALPHA_MODES.UNPACK] - Premultiply image alpha in bitmap\n */\n function ImageResource(source, options) {\n var _this = this;\n options = options || {};\n if (!(source instanceof HTMLImageElement)) {\n var imageElement = new Image();\n BaseImageResource.crossOrigin(imageElement, source, options.crossorigin);\n imageElement.src = source;\n source = imageElement;\n }\n _this = _super.call(this, source) || this;\n // FireFox 68, and possibly other versions, seems like setting the HTMLImageElement#width and #height\n // to non-zero values before its loading completes if images are in a cache.\n // Because of this, need to set the `_width` and the `_height` to zero to avoid uploading incomplete images.\n // Please refer to the issue #5968 (https://github.com/pixijs/pixi.js/issues/5968).\n if (!source.complete && !!_this._width && !!_this._height) {\n _this._width = 0;\n _this._height = 0;\n }\n _this.url = source.src;\n _this._process = null;\n _this.preserveBitmap = false;\n _this.createBitmap = (options.createBitmap !== undefined\n ? options.createBitmap : settings.CREATE_IMAGE_BITMAP) && !!globalThis.createImageBitmap;\n _this.alphaMode = typeof options.alphaMode === 'number' ? options.alphaMode : null;\n _this.bitmap = null;\n _this._load = null;\n if (options.autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n /**\n * Returns a promise when image will be loaded and processed.\n *\n * @param createBitmap - whether process image into bitmap\n */\n ImageResource.prototype.load = function (createBitmap) {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n if (createBitmap !== undefined) {\n this.createBitmap = createBitmap;\n }\n this._load = new Promise(function (resolve, reject) {\n var source = _this.source;\n _this.url = source.src;\n var completed = function () {\n if (_this.destroyed) {\n return;\n }\n source.onload = null;\n source.onerror = null;\n _this.resize(source.width, source.height);\n _this._load = null;\n if (_this.createBitmap) {\n resolve(_this.process());\n }\n else {\n resolve(_this);\n }\n };\n if (source.complete && source.src) {\n completed();\n }\n else {\n source.onload = completed;\n source.onerror = function (event) {\n // Avoids Promise freezing when resource broken\n reject(event);\n _this.onError.emit(event);\n };\n }\n });\n return this._load;\n };\n /**\n * Called when we need to convert image into BitmapImage.\n * Can be called multiple times, real promise is cached inside.\n *\n * @return - Cached promise to fill that bitmap\n */\n ImageResource.prototype.process = function () {\n var _this = this;\n var source = this.source;\n if (this._process !== null) {\n return this._process;\n }\n if (this.bitmap !== null || !globalThis.createImageBitmap) {\n return Promise.resolve(this);\n }\n var createImageBitmap = globalThis.createImageBitmap;\n var cors = !source.crossOrigin || source.crossOrigin === 'anonymous';\n this._process = fetch(source.src, {\n mode: cors ? 'cors' : 'no-cors'\n })\n .then(function (r) { return r.blob(); })\n .then(function (blob) { return createImageBitmap(blob, 0, 0, source.width, source.height, {\n premultiplyAlpha: _this.alphaMode === ALPHA_MODES.UNPACK ? 'premultiply' : 'none',\n }); })\n .then(function (bitmap) {\n if (_this.destroyed) {\n return Promise.reject();\n }\n _this.bitmap = bitmap;\n _this.update();\n _this._process = null;\n return Promise.resolve(_this);\n });\n return this._process;\n };\n /**\n * Upload the image resource to GPU.\n *\n * @param renderer - Renderer to upload to\n * @param baseTexture - BaseTexture for this resource\n * @param glTexture - GLTexture to use\n * @returns {boolean} true is success\n */\n ImageResource.prototype.upload = function (renderer, baseTexture, glTexture) {\n if (typeof this.alphaMode === 'number') {\n // bitmap stores unpack premultiply flag, we dont have to notify texImage2D about it\n baseTexture.alphaMode = this.alphaMode;\n }\n if (!this.createBitmap) {\n return _super.prototype.upload.call(this, renderer, baseTexture, glTexture);\n }\n if (!this.bitmap) {\n // yeah, ignore the output\n this.process();\n if (!this.bitmap) {\n return false;\n }\n }\n _super.prototype.upload.call(this, renderer, baseTexture, glTexture, this.bitmap);\n if (!this.preserveBitmap) {\n // checks if there are other renderers that possibly need this bitmap\n var flag = true;\n var glTextures = baseTexture._glTextures;\n for (var key in glTextures) {\n var otherTex = glTextures[key];\n if (otherTex !== glTexture && otherTex.dirtyId !== baseTexture.dirtyId) {\n flag = false;\n break;\n }\n }\n if (flag) {\n if (this.bitmap.close) {\n this.bitmap.close();\n }\n this.bitmap = null;\n }\n }\n return true;\n };\n /** Destroys this resource. */\n ImageResource.prototype.dispose = function () {\n this.source.onload = null;\n this.source.onerror = null;\n _super.prototype.dispose.call(this);\n if (this.bitmap) {\n this.bitmap.close();\n this.bitmap = null;\n }\n this._process = null;\n this._load = null;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is string or HTMLImageElement\n */\n ImageResource.test = function (source) {\n return typeof source === 'string' || source instanceof HTMLImageElement;\n };\n return ImageResource;\n}(BaseImageResource));\n\n/**\n * Resource type for SVG elements and graphics.\n *\n * @memberof PIXI\n */\nvar SVGResource = /** @class */ (function (_super) {\n __extends(SVGResource, _super);\n /**\n * @param sourceBase64 - Base64 encoded SVG element or URL for SVG file.\n * @param {object} [options] - Options to use\n * @param {number} [options.scale=1] - Scale to apply to SVG. Overridden by...\n * @param {number} [options.width] - Rasterize SVG this wide. Aspect ratio preserved if height not specified.\n * @param {number} [options.height] - Rasterize SVG this high. Aspect ratio preserved if width not specified.\n * @param {boolean} [options.autoLoad=true] - Start loading right away.\n */\n function SVGResource(sourceBase64, options) {\n var _this = this;\n options = options || {};\n _this = _super.call(this, document.createElement('canvas')) || this;\n _this._width = 0;\n _this._height = 0;\n _this.svg = sourceBase64;\n _this.scale = options.scale || 1;\n _this._overrideWidth = options.width;\n _this._overrideHeight = options.height;\n _this._resolve = null;\n _this._crossorigin = options.crossorigin;\n _this._load = null;\n if (options.autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n SVGResource.prototype.load = function () {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n this._load = new Promise(function (resolve) {\n // Save this until after load is finished\n _this._resolve = function () {\n _this.resize(_this.source.width, _this.source.height);\n resolve(_this);\n };\n // Convert SVG inline string to data-uri\n if (SVGResource.SVG_XML.test(_this.svg.trim())) {\n if (!btoa) {\n throw new Error('Your browser doesn\\'t support base64 conversions.');\n }\n _this.svg = \"data:image/svg+xml;base64,\" + btoa(unescape(encodeURIComponent(_this.svg)));\n }\n _this._loadSvg();\n });\n return this._load;\n };\n /** Loads an SVG image from `imageUrl` or `data URL`. */\n SVGResource.prototype._loadSvg = function () {\n var _this = this;\n var tempImage = new Image();\n BaseImageResource.crossOrigin(tempImage, this.svg, this._crossorigin);\n tempImage.src = this.svg;\n tempImage.onerror = function (event) {\n if (!_this._resolve) {\n return;\n }\n tempImage.onerror = null;\n _this.onError.emit(event);\n };\n tempImage.onload = function () {\n if (!_this._resolve) {\n return;\n }\n var svgWidth = tempImage.width;\n var svgHeight = tempImage.height;\n if (!svgWidth || !svgHeight) {\n throw new Error('The SVG image must have width and height defined (in pixels), canvas API needs them.');\n }\n // Set render size\n var width = svgWidth * _this.scale;\n var height = svgHeight * _this.scale;\n if (_this._overrideWidth || _this._overrideHeight) {\n width = _this._overrideWidth || _this._overrideHeight / svgHeight * svgWidth;\n height = _this._overrideHeight || _this._overrideWidth / svgWidth * svgHeight;\n }\n width = Math.round(width);\n height = Math.round(height);\n // Create a canvas element\n var canvas = _this.source;\n canvas.width = width;\n canvas.height = height;\n canvas._pixiId = \"canvas_\" + uid();\n // Draw the Svg to the canvas\n canvas\n .getContext('2d')\n .drawImage(tempImage, 0, 0, svgWidth, svgHeight, 0, 0, width, height);\n _this._resolve();\n _this._resolve = null;\n };\n };\n /**\n * Get size from an svg string using a regular expression.\n *\n * @param svgString - a serialized svg element\n * @return - image extension\n */\n SVGResource.getSize = function (svgString) {\n var sizeMatch = SVGResource.SVG_SIZE.exec(svgString);\n var size = {};\n if (sizeMatch) {\n size[sizeMatch[1]] = Math.round(parseFloat(sizeMatch[3]));\n size[sizeMatch[5]] = Math.round(parseFloat(sizeMatch[7]));\n }\n return size;\n };\n /** Destroys this texture. */\n SVGResource.prototype.dispose = function () {\n _super.prototype.dispose.call(this);\n this._resolve = null;\n this._crossorigin = null;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @param {string} extension - The extension of source, if set\n * @return {boolean} - If the source is a SVG source or data file\n */\n SVGResource.test = function (source, extension) {\n // url file extension is SVG\n return extension === 'svg'\n // source is SVG data-uri\n || (typeof source === 'string' && (/^data:image\\/svg\\+xml(;(charset=utf8|utf8))?;base64/).test(source))\n // source is SVG inline\n || (typeof source === 'string' && SVGResource.SVG_XML.test(source));\n };\n /**\n * Regular expression for SVG XML document.\n *\n * @example <?xml version=\"1.0\" encoding=\"utf-8\" ?><!-- image/svg --><svg\n * @readonly\n */\n SVGResource.SVG_XML = /^(<\\?xml[^?]+\\?>)?\\s*(<!--[^(-->)]*-->)?\\s*\\<svg/m;\n /**\n * Regular expression for SVG size.\n *\n * @example <svg width=\"100\" height=\"100\"></svg>\n * @readonly\n */\n SVGResource.SVG_SIZE = /<svg[^>]*(?:\\s(width|height)=('|\")(\\d*(?:\\.\\d+)?)(?:px)?('|\"))[^>]*(?:\\s(width|height)=('|\")(\\d*(?:\\.\\d+)?)(?:px)?('|\"))[^>]*>/i; // eslint-disable-line max-len\n return SVGResource;\n}(BaseImageResource));\n\n/**\n * Resource type for {@code HTMLVideoElement}.\n *\n * @memberof PIXI\n */\nvar VideoResource = /** @class */ (function (_super) {\n __extends(VideoResource, _super);\n /**\n * @param {HTMLVideoElement|object|string|Array<string|object>} source - Video element to use.\n * @param {object} [options] - Options to use\n * @param {boolean} [options.autoLoad=true] - Start loading the video immediately\n * @param {boolean} [options.autoPlay=true] - Start playing video immediately\n * @param {number} [options.updateFPS=0] - How many times a second to update the texture from the video.\n * Leave at 0 to update at every render.\n * @param {boolean} [options.crossorigin=true] - Load image using cross origin\n */\n function VideoResource(source, options) {\n var _this = this;\n options = options || {};\n if (!(source instanceof HTMLVideoElement)) {\n var videoElement = document.createElement('video');\n // workaround for https://github.com/pixijs/pixi.js/issues/5996\n videoElement.setAttribute('preload', 'auto');\n videoElement.setAttribute('webkit-playsinline', '');\n videoElement.setAttribute('playsinline', '');\n if (typeof source === 'string') {\n source = [source];\n }\n var firstSrc = source[0].src || source[0];\n BaseImageResource.crossOrigin(videoElement, firstSrc, options.crossorigin);\n // array of objects or strings\n for (var i = 0; i < source.length; ++i) {\n var sourceElement = document.createElement('source');\n var _a = source[i], src = _a.src, mime = _a.mime;\n src = src || source[i];\n var baseSrc = src.split('?').shift().toLowerCase();\n var ext = baseSrc.slice(baseSrc.lastIndexOf('.') + 1);\n mime = mime || VideoResource.MIME_TYPES[ext] || \"video/\" + ext;\n sourceElement.src = src;\n sourceElement.type = mime;\n videoElement.appendChild(sourceElement);\n }\n // Override the source\n source = videoElement;\n }\n _this = _super.call(this, source) || this;\n _this.noSubImage = true;\n _this._autoUpdate = true;\n _this._isConnectedToTicker = false;\n _this._updateFPS = options.updateFPS || 0;\n _this._msToNextUpdate = 0;\n _this.autoPlay = options.autoPlay !== false;\n _this._load = null;\n _this._resolve = null;\n // Bind for listeners\n _this._onCanPlay = _this._onCanPlay.bind(_this);\n _this._onError = _this._onError.bind(_this);\n if (options.autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n /**\n * Trigger updating of the texture.\n *\n * @param deltaTime - time delta since last tick\n */\n VideoResource.prototype.update = function (_deltaTime) {\n if (!this.destroyed) {\n // account for if video has had its playbackRate changed\n var elapsedMS = Ticker.shared.elapsedMS * this.source.playbackRate;\n this._msToNextUpdate = Math.floor(this._msToNextUpdate - elapsedMS);\n if (!this._updateFPS || this._msToNextUpdate <= 0) {\n _super.prototype.update.call(this);\n this._msToNextUpdate = this._updateFPS ? Math.floor(1000 / this._updateFPS) : 0;\n }\n }\n };\n /**\n * Start preloading the video resource.\n *\n * @return {Promise<void>} Handle the validate event\n */\n VideoResource.prototype.load = function () {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n var source = this.source;\n if ((source.readyState === source.HAVE_ENOUGH_DATA || source.readyState === source.HAVE_FUTURE_DATA)\n && source.width && source.height) {\n source.complete = true;\n }\n source.addEventListener('play', this._onPlayStart.bind(this));\n source.addEventListener('pause', this._onPlayStop.bind(this));\n if (!this._isSourceReady()) {\n source.addEventListener('canplay', this._onCanPlay);\n source.addEventListener('canplaythrough', this._onCanPlay);\n source.addEventListener('error', this._onError, true);\n }\n else {\n this._onCanPlay();\n }\n this._load = new Promise(function (resolve) {\n if (_this.valid) {\n resolve(_this);\n }\n else {\n _this._resolve = resolve;\n source.load();\n }\n });\n return this._load;\n };\n /** Handle video error events. */\n VideoResource.prototype._onError = function (event) {\n this.source.removeEventListener('error', this._onError, true);\n this.onError.emit(event);\n };\n /**\n * Returns true if the underlying source is playing.\n *\n * @return - True if playing.\n */\n VideoResource.prototype._isSourcePlaying = function () {\n var source = this.source;\n return (source.currentTime > 0 && source.paused === false && source.ended === false && source.readyState > 2);\n };\n /**\n * Returns true if the underlying source is ready for playing.\n *\n * @return - True if ready.\n */\n VideoResource.prototype._isSourceReady = function () {\n var source = this.source;\n return source.readyState === 3 || source.readyState === 4;\n };\n /** Runs the update loop when the video is ready to play. */\n VideoResource.prototype._onPlayStart = function () {\n // Just in case the video has not received its can play even yet..\n if (!this.valid) {\n this._onCanPlay();\n }\n if (this.autoUpdate && !this._isConnectedToTicker) {\n Ticker.shared.add(this.update, this);\n this._isConnectedToTicker = true;\n }\n };\n /** Fired when a pause event is triggered, stops the update loop. */\n VideoResource.prototype._onPlayStop = function () {\n if (this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n };\n /** Fired when the video is loaded and ready to play. */\n VideoResource.prototype._onCanPlay = function () {\n var source = this.source;\n source.removeEventListener('canplay', this._onCanPlay);\n source.removeEventListener('canplaythrough', this._onCanPlay);\n var valid = this.valid;\n this.resize(source.videoWidth, source.videoHeight);\n // prevent multiple loaded dispatches..\n if (!valid && this._resolve) {\n this._resolve(this);\n this._resolve = null;\n }\n if (this._isSourcePlaying()) {\n this._onPlayStart();\n }\n else if (this.autoPlay) {\n source.play();\n }\n };\n /** Destroys this texture. */\n VideoResource.prototype.dispose = function () {\n if (this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n var source = this.source;\n if (source) {\n source.removeEventListener('error', this._onError, true);\n source.pause();\n source.src = '';\n source.load();\n }\n _super.prototype.dispose.call(this);\n };\n Object.defineProperty(VideoResource.prototype, \"autoUpdate\", {\n /** Should the base texture automatically update itself, set to true by default. */\n get: function () {\n return this._autoUpdate;\n },\n set: function (value) {\n if (value !== this._autoUpdate) {\n this._autoUpdate = value;\n if (!this._autoUpdate && this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n else if (this._autoUpdate && !this._isConnectedToTicker && this._isSourcePlaying()) {\n Ticker.shared.add(this.update, this);\n this._isConnectedToTicker = true;\n }\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(VideoResource.prototype, \"updateFPS\", {\n /**\n * How many times a second to update the texture from the video. Leave at 0 to update at every render.\n * A lower fps can help performance, as updating the texture at 60fps on a 30ps video may not be efficient.\n */\n get: function () {\n return this._updateFPS;\n },\n set: function (value) {\n if (value !== this._updateFPS) {\n this._updateFPS = value;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @param {string} extension - The extension of source, if set\n * @return {boolean} `true` if video source\n */\n VideoResource.test = function (source, extension) {\n return (globalThis.HTMLVideoElement && source instanceof HTMLVideoElement)\n || VideoResource.TYPES.indexOf(extension) > -1;\n };\n /**\n * List of common video file extensions supported by VideoResource.\n *\n * @readonly\n */\n VideoResource.TYPES = ['mp4', 'm4v', 'webm', 'ogg', 'ogv', 'h264', 'avi', 'mov'];\n /**\n * Map of video MIME types that can't be directly derived from file extensions.\n *\n * @readonly\n */\n VideoResource.MIME_TYPES = {\n ogv: 'video/ogg',\n mov: 'video/quicktime',\n m4v: 'video/mp4',\n };\n return VideoResource;\n}(BaseImageResource));\n\n/**\n * Resource type for ImageBitmap.\n *\n * @memberof PIXI\n */\nvar ImageBitmapResource = /** @class */ (function (_super) {\n __extends(ImageBitmapResource, _super);\n /**\n * @param source - Image element to use\n */\n // eslint-disable-next-line @typescript-eslint/no-useless-constructor\n function ImageBitmapResource(source) {\n return _super.call(this, source) || this;\n }\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is an ImageBitmap\n */\n ImageBitmapResource.test = function (source) {\n return !!globalThis.createImageBitmap && source instanceof ImageBitmap;\n };\n return ImageBitmapResource;\n}(BaseImageResource));\n\nINSTALLED.push(ImageResource, ImageBitmapResource, CanvasResource, VideoResource, SVGResource, BufferResource, CubeResource, ArrayResource);\n\nvar _resources = {\n __proto__: null,\n Resource: Resource,\n BaseImageResource: BaseImageResource,\n INSTALLED: INSTALLED,\n autoDetectResource: autoDetectResource,\n AbstractMultiResource: AbstractMultiResource,\n ArrayResource: ArrayResource,\n BufferResource: BufferResource,\n CanvasResource: CanvasResource,\n CubeResource: CubeResource,\n ImageResource: ImageResource,\n SVGResource: SVGResource,\n VideoResource: VideoResource,\n ImageBitmapResource: ImageBitmapResource\n};\n\n/**\n * Resource type for DepthTexture.\n *\n * @memberof PIXI\n */\nvar DepthResource = /** @class */ (function (_super) {\n __extends(DepthResource, _super);\n function DepthResource() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * Upload the texture to the GPU.\n *\n * @param renderer - Upload to the renderer\n * @param baseTexture - Reference to parent texture\n * @param glTexture - glTexture\n * @return - true is success\n */\n DepthResource.prototype.upload = function (renderer, baseTexture, glTexture) {\n var gl = renderer.gl;\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, baseTexture.alphaMode === ALPHA_MODES.UNPACK);\n var width = baseTexture.realWidth;\n var height = baseTexture.realHeight;\n if (glTexture.width === width && glTexture.height === height) {\n gl.texSubImage2D(baseTexture.target, 0, 0, 0, width, height, baseTexture.format, glTexture.type, this.data);\n }\n else {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(baseTexture.target, 0, glTexture.internalFormat, width, height, 0, baseTexture.format, glTexture.type, this.data);\n }\n return true;\n };\n return DepthResource;\n}(BufferResource));\n\n/**\n * A framebuffer can be used to render contents off of the screen. {@link PIXI.BaseRenderTexture} uses\n * one internally to render into itself. You can attach a depth or stencil buffer to a framebuffer.\n *\n * On WebGL 2 machines, shaders can output to multiple textures simultaneously with GLSL 300 ES.\n *\n * @memberof PIXI\n */\nvar Framebuffer = /** @class */ (function () {\n /**\n * @param width - Width of the frame buffer\n * @param height - Height of the frame buffer\n */\n function Framebuffer(width, height) {\n this.width = Math.round(width || 100);\n this.height = Math.round(height || 100);\n this.stencil = false;\n this.depth = false;\n this.dirtyId = 0;\n this.dirtyFormat = 0;\n this.dirtySize = 0;\n this.depthTexture = null;\n this.colorTextures = [];\n this.glFramebuffers = {};\n this.disposeRunner = new Runner('disposeFramebuffer');\n this.multisample = MSAA_QUALITY.NONE;\n }\n Object.defineProperty(Framebuffer.prototype, \"colorTexture\", {\n /**\n * Reference to the colorTexture.\n *\n * @readonly\n */\n get: function () {\n return this.colorTextures[0];\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Add texture to the colorTexture array.\n *\n * @param index - Index of the array to add the texture to\n * @param texture - Texture to add to the array\n */\n Framebuffer.prototype.addColorTexture = function (index, texture) {\n if (index === void 0) { index = 0; }\n // TODO add some validation to the texture - same width / height etc?\n this.colorTextures[index] = texture || new BaseTexture(null, {\n scaleMode: SCALE_MODES.NEAREST,\n resolution: 1,\n mipmap: MIPMAP_MODES.OFF,\n width: this.width,\n height: this.height,\n });\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /**\n * Add a depth texture to the frame buffer.\n *\n * @param texture - Texture to add.\n */\n Framebuffer.prototype.addDepthTexture = function (texture) {\n /* eslint-disable max-len */\n this.depthTexture = texture || new BaseTexture(new DepthResource(null, { width: this.width, height: this.height }), {\n scaleMode: SCALE_MODES.NEAREST,\n resolution: 1,\n width: this.width,\n height: this.height,\n mipmap: MIPMAP_MODES.OFF,\n format: FORMATS.DEPTH_COMPONENT,\n type: TYPES.UNSIGNED_SHORT,\n });\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /** Enable depth on the frame buffer. */\n Framebuffer.prototype.enableDepth = function () {\n this.depth = true;\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /** Enable stencil on the frame buffer. */\n Framebuffer.prototype.enableStencil = function () {\n this.stencil = true;\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /**\n * Resize the frame buffer\n *\n * @param width - Width of the frame buffer to resize to\n * @param height - Height of the frame buffer to resize to\n */\n Framebuffer.prototype.resize = function (width, height) {\n width = Math.round(width);\n height = Math.round(height);\n if (width === this.width && height === this.height)\n { return; }\n this.width = width;\n this.height = height;\n this.dirtyId++;\n this.dirtySize++;\n for (var i = 0; i < this.colorTextures.length; i++) {\n var texture = this.colorTextures[i];\n var resolution = texture.resolution;\n // take into account the fact the texture may have a different resolution..\n texture.setSize(width / resolution, height / resolution);\n }\n if (this.depthTexture) {\n var resolution = this.depthTexture.resolution;\n this.depthTexture.setSize(width / resolution, height / resolution);\n }\n };\n /** Disposes WebGL resources that are connected to this geometry. */\n Framebuffer.prototype.dispose = function () {\n this.disposeRunner.emit(this, false);\n };\n /** Destroys and removes the depth texture added to this framebuffer. */\n Framebuffer.prototype.destroyDepthTexture = function () {\n if (this.depthTexture) {\n this.depthTexture.destroy();\n this.depthTexture = null;\n ++this.dirtyId;\n ++this.dirtyFormat;\n }\n };\n return Framebuffer;\n}());\n\n/**\n * A BaseRenderTexture is a special texture that allows any PixiJS display object to be rendered to it.\n *\n * __Hint__: All DisplayObjects (i.e. Sprites) that render to a BaseRenderTexture should be preloaded\n * otherwise black rectangles will be drawn instead.\n *\n * A BaseRenderTexture takes a snapshot of any Display Object given to its render method. The position\n * and rotation of the given Display Objects is ignored. For example:\n *\n * ```js\n * let renderer = PIXI.autoDetectRenderer();\n * let baseRenderTexture = new PIXI.BaseRenderTexture({ width: 800, height: 600 });\n * let renderTexture = new PIXI.RenderTexture(baseRenderTexture);\n * let sprite = PIXI.Sprite.from(\"spinObj_01.png\");\n *\n * sprite.position.x = 800/2;\n * sprite.position.y = 600/2;\n * sprite.anchor.x = 0.5;\n * sprite.anchor.y = 0.5;\n *\n * renderer.render(sprite, {renderTexture});\n * ```\n *\n * The Sprite in this case will be rendered using its local transform. To render this sprite at 0,0\n * you can clear the transform\n *\n * ```js\n *\n * sprite.setTransform()\n *\n * let baseRenderTexture = new PIXI.BaseRenderTexture({ width: 100, height: 100 });\n * let renderTexture = new PIXI.RenderTexture(baseRenderTexture);\n *\n * renderer.render(sprite, {renderTexture}); // Renders to center of RenderTexture\n * ```\n *\n * @memberof PIXI\n */\nvar BaseRenderTexture = /** @class */ (function (_super) {\n __extends(BaseRenderTexture, _super);\n /**\n * @param options\n * @param {number} [options.width=100] - The width of the base render texture.\n * @param {number} [options.height=100] - The height of the base render texture.\n * @param {PIXI.SCALE_MODES} [options.scaleMode=PIXI.settings.SCALE_MODE] - See {@link PIXI.SCALE_MODES}\n * for possible values.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio\n * of the texture being generated.\n * @param {PIXI.MSAA_QUALITY} [options.multisample=PIXI.MSAA_QUALITY.NONE] - The number of samples of the frame buffer.\n */\n function BaseRenderTexture(options) {\n if (options === void 0) { options = {}; }\n var _this = this;\n if (typeof options === 'number') {\n /* eslint-disable prefer-rest-params */\n // Backward compatibility of signature\n var width = arguments[0];\n var height = arguments[1];\n var scaleMode = arguments[2];\n var resolution = arguments[3];\n options = { width: width, height: height, scaleMode: scaleMode, resolution: resolution };\n /* eslint-enable prefer-rest-params */\n }\n options.width = options.width || 100;\n options.height = options.height || 100;\n options.multisample = options.multisample !== undefined ? options.multisample : MSAA_QUALITY.NONE;\n _this = _super.call(this, null, options) || this;\n // Set defaults\n _this.mipmap = MIPMAP_MODES.OFF;\n _this.valid = true;\n _this.clearColor = [0, 0, 0, 0];\n _this.framebuffer = new Framebuffer(_this.realWidth, _this.realHeight)\n .addColorTexture(0, _this);\n _this.framebuffer.multisample = options.multisample;\n // TODO - could this be added the systems?\n _this.maskStack = [];\n _this.filterStack = [{}];\n return _this;\n }\n /**\n * Resizes the BaseRenderTexture.\n *\n * @param desiredWidth - The desired width to resize to.\n * @param desiredHeight - The desired height to resize to.\n */\n BaseRenderTexture.prototype.resize = function (desiredWidth, desiredHeight) {\n this.framebuffer.resize(desiredWidth * this.resolution, desiredHeight * this.resolution);\n this.setRealSize(this.framebuffer.width, this.framebuffer.height);\n };\n /**\n * Frees the texture and framebuffer from WebGL memory without destroying this texture object.\n * This means you can still use the texture later which will upload it to GPU\n * memory again.\n *\n * @fires PIXI.BaseTexture#dispose\n */\n BaseRenderTexture.prototype.dispose = function () {\n this.framebuffer.dispose();\n _super.prototype.dispose.call(this);\n };\n /** Destroys this texture. */\n BaseRenderTexture.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n this.framebuffer.destroyDepthTexture();\n this.framebuffer = null;\n };\n return BaseRenderTexture;\n}(BaseTexture));\n\n/**\n * Stores a texture's frame in UV coordinates, in\n * which everything lies in the rectangle `[(0,0), (1,0),\n * (1,1), (0,1)]`.\n *\n * | Corner | Coordinates |\n * |--------------|-------------|\n * | Top-Left | `(x0,y0)` |\n * | Top-Right | `(x1,y1)` |\n * | Bottom-Right | `(x2,y2)` |\n * | Bottom-Left | `(x3,y3)` |\n *\n * @protected\n * @memberof PIXI\n */\nvar TextureUvs = /** @class */ (function () {\n function TextureUvs() {\n this.x0 = 0;\n this.y0 = 0;\n this.x1 = 1;\n this.y1 = 0;\n this.x2 = 1;\n this.y2 = 1;\n this.x3 = 0;\n this.y3 = 1;\n this.uvsFloat32 = new Float32Array(8);\n }\n /**\n * Sets the texture Uvs based on the given frame information.\n *\n * @protected\n * @param frame - The frame of the texture\n * @param baseFrame - The base frame of the texture\n * @param rotate - Rotation of frame, see {@link PIXI.groupD8}\n */\n TextureUvs.prototype.set = function (frame, baseFrame, rotate) {\n var tw = baseFrame.width;\n var th = baseFrame.height;\n if (rotate) {\n // width and height div 2 div baseFrame size\n var w2 = frame.width / 2 / tw;\n var h2 = frame.height / 2 / th;\n // coordinates of center\n var cX = (frame.x / tw) + w2;\n var cY = (frame.y / th) + h2;\n rotate = groupD8.add(rotate, groupD8.NW); // NW is top-left corner\n this.x0 = cX + (w2 * groupD8.uX(rotate));\n this.y0 = cY + (h2 * groupD8.uY(rotate));\n rotate = groupD8.add(rotate, 2); // rotate 90 degrees clockwise\n this.x1 = cX + (w2 * groupD8.uX(rotate));\n this.y1 = cY + (h2 * groupD8.uY(rotate));\n rotate = groupD8.add(rotate, 2);\n this.x2 = cX + (w2 * groupD8.uX(rotate));\n this.y2 = cY + (h2 * groupD8.uY(rotate));\n rotate = groupD8.add(rotate, 2);\n this.x3 = cX + (w2 * groupD8.uX(rotate));\n this.y3 = cY + (h2 * groupD8.uY(rotate));\n }\n else {\n this.x0 = frame.x / tw;\n this.y0 = frame.y / th;\n this.x1 = (frame.x + frame.width) / tw;\n this.y1 = frame.y / th;\n this.x2 = (frame.x + frame.width) / tw;\n this.y2 = (frame.y + frame.height) / th;\n this.x3 = frame.x / tw;\n this.y3 = (frame.y + frame.height) / th;\n }\n this.uvsFloat32[0] = this.x0;\n this.uvsFloat32[1] = this.y0;\n this.uvsFloat32[2] = this.x1;\n this.uvsFloat32[3] = this.y1;\n this.uvsFloat32[4] = this.x2;\n this.uvsFloat32[5] = this.y2;\n this.uvsFloat32[6] = this.x3;\n this.uvsFloat32[7] = this.y3;\n };\n TextureUvs.prototype.toString = function () {\n return \"[@pixi/core:TextureUvs \"\n + (\"x0=\" + this.x0 + \" y0=\" + this.y0 + \" \")\n + (\"x1=\" + this.x1 + \" y1=\" + this.y1 + \" x2=\" + this.x2 + \" \")\n + (\"y2=\" + this.y2 + \" x3=\" + this.x3 + \" y3=\" + this.y3)\n + \"]\";\n };\n return TextureUvs;\n}());\n\nvar DEFAULT_UVS = new TextureUvs();\n/**\n * A texture stores the information that represents an image or part of an image.\n *\n * It cannot be added to the display list directly; instead use it as the texture for a Sprite.\n * If no frame is provided for a texture, then the whole image is used.\n *\n * You can directly create a texture from an image and then reuse it multiple times like this :\n *\n * ```js\n * let texture = PIXI.Texture.from('assets/image.png');\n * let sprite1 = new PIXI.Sprite(texture);\n * let sprite2 = new PIXI.Sprite(texture);\n * ```\n *\n * If you didnt pass the texture frame to constructor, it enables `noFrame` mode:\n * it subscribes on baseTexture events, it automatically resizes at the same time as baseTexture.\n *\n * Textures made from SVGs, loaded or not, cannot be used before the file finishes processing.\n * You can check for this by checking the sprite's _textureID property.\n * ```js\n * var texture = PIXI.Texture.from('assets/image.svg');\n * var sprite1 = new PIXI.Sprite(texture);\n * //sprite1._textureID should not be undefined if the texture has finished processing the SVG file\n * ```\n * You can use a ticker or rAF to ensure your sprites load the finished textures after processing. See issue #3068.\n *\n * @memberof PIXI\n * @typeParam R - The BaseTexture's Resource type.\n */\nvar Texture = /** @class */ (function (_super) {\n __extends(Texture, _super);\n /**\n * @param baseTexture - The base texture source to create the texture from\n * @param frame - The rectangle frame of the texture to show\n * @param orig - The area of original texture\n * @param trim - Trimmed rectangle of original texture\n * @param rotate - indicates how the texture was rotated by texture packer. See {@link PIXI.groupD8}\n * @param anchor - Default anchor point used for sprite placement / rotation\n */\n function Texture(baseTexture, frame, orig, trim, rotate, anchor) {\n var _this = _super.call(this) || this;\n _this.noFrame = false;\n if (!frame) {\n _this.noFrame = true;\n frame = new Rectangle(0, 0, 1, 1);\n }\n if (baseTexture instanceof Texture) {\n baseTexture = baseTexture.baseTexture;\n }\n _this.baseTexture = baseTexture;\n _this._frame = frame;\n _this.trim = trim;\n _this.valid = false;\n _this._uvs = DEFAULT_UVS;\n _this.uvMatrix = null;\n _this.orig = orig || frame; // new Rectangle(0, 0, 1, 1);\n _this._rotate = Number(rotate || 0);\n if (rotate === true) {\n // this is old texturepacker legacy, some games/libraries are passing \"true\" for rotated textures\n _this._rotate = 2;\n }\n else if (_this._rotate % 2 !== 0) {\n throw new Error('attempt to use diamond-shaped UVs. If you are sure, set rotation manually');\n }\n _this.defaultAnchor = anchor ? new Point(anchor.x, anchor.y) : new Point(0, 0);\n _this._updateID = 0;\n _this.textureCacheIds = [];\n if (!baseTexture.valid) {\n baseTexture.once('loaded', _this.onBaseTextureUpdated, _this);\n }\n else if (_this.noFrame) {\n // if there is no frame we should monitor for any base texture changes..\n if (baseTexture.valid) {\n _this.onBaseTextureUpdated(baseTexture);\n }\n }\n else {\n _this.frame = frame;\n }\n if (_this.noFrame) {\n baseTexture.on('update', _this.onBaseTextureUpdated, _this);\n }\n return _this;\n }\n /**\n * Updates this texture on the gpu.\n *\n * Calls the TextureResource update.\n *\n * If you adjusted `frame` manually, please call `updateUvs()` instead.\n */\n Texture.prototype.update = function () {\n if (this.baseTexture.resource) {\n this.baseTexture.resource.update();\n }\n };\n /**\n * Called when the base texture is updated\n *\n * @protected\n * @param baseTexture - The base texture.\n */\n Texture.prototype.onBaseTextureUpdated = function (baseTexture) {\n if (this.noFrame) {\n if (!this.baseTexture.valid) {\n return;\n }\n this._frame.width = baseTexture.width;\n this._frame.height = baseTexture.height;\n this.valid = true;\n this.updateUvs();\n }\n else {\n // TODO this code looks confusing.. boo to abusing getters and setters!\n // if user gave us frame that has bigger size than resized texture it can be a problem\n this.frame = this._frame;\n }\n this.emit('update', this);\n };\n /**\n * Destroys this texture\n *\n * @param [destroyBase=false] - Whether to destroy the base texture as well\n */\n Texture.prototype.destroy = function (destroyBase) {\n if (this.baseTexture) {\n if (destroyBase) {\n var resource = this.baseTexture.resource;\n // delete the texture if it exists in the texture cache..\n // this only needs to be removed if the base texture is actually destroyed too..\n if (resource && resource.url && TextureCache[resource.url]) {\n Texture.removeFromCache(resource.url);\n }\n this.baseTexture.destroy();\n }\n this.baseTexture.off('loaded', this.onBaseTextureUpdated, this);\n this.baseTexture.off('update', this.onBaseTextureUpdated, this);\n this.baseTexture = null;\n }\n this._frame = null;\n this._uvs = null;\n this.trim = null;\n this.orig = null;\n this.valid = false;\n Texture.removeFromCache(this);\n this.textureCacheIds = null;\n };\n /**\n * Creates a new texture object that acts the same as this one.\n *\n * @return - The new texture\n */\n Texture.prototype.clone = function () {\n var clonedFrame = this._frame.clone();\n var clonedOrig = this._frame === this.orig ? clonedFrame : this.orig.clone();\n var clonedTexture = new Texture(this.baseTexture, !this.noFrame && clonedFrame, clonedOrig, this.trim && this.trim.clone(), this.rotate, this.defaultAnchor);\n if (this.noFrame) {\n clonedTexture._frame = clonedFrame;\n }\n return clonedTexture;\n };\n /**\n * Updates the internal WebGL UV cache. Use it after you change `frame` or `trim` of the texture.\n * Call it after changing the frame\n */\n Texture.prototype.updateUvs = function () {\n if (this._uvs === DEFAULT_UVS) {\n this._uvs = new TextureUvs();\n }\n this._uvs.set(this._frame, this.baseTexture, this.rotate);\n this._updateID++;\n };\n /**\n * Helper function that creates a new Texture based on the source you provide.\n * The source can be - frame id, image url, video url, canvas element, video element, base texture\n *\n * @param {string|HTMLImageElement|HTMLCanvasElement|HTMLVideoElement|PIXI.BaseTexture} source -\n * Source to create texture from\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @param {string} [options.pixiIdPrefix=pixiid] - If a source has no id, this is the prefix of the generated id\n * @param {boolean} [strict] - Enforce strict-mode, see {@link PIXI.settings.STRICT_TEXTURE_CACHE}.\n * @return {PIXI.Texture} The newly created texture\n */\n Texture.from = function (source, options, strict) {\n if (options === void 0) { options = {}; }\n if (strict === void 0) { strict = settings.STRICT_TEXTURE_CACHE; }\n var isFrame = typeof source === 'string';\n var cacheId = null;\n if (isFrame) {\n cacheId = source;\n }\n else if (source instanceof BaseTexture) {\n if (!source.cacheId) {\n var prefix = (options && options.pixiIdPrefix) || 'pixiid';\n source.cacheId = prefix + \"-\" + uid();\n BaseTexture.addToCache(source, source.cacheId);\n }\n cacheId = source.cacheId;\n }\n else {\n if (!source._pixiId) {\n var prefix = (options && options.pixiIdPrefix) || 'pixiid';\n source._pixiId = prefix + \"_\" + uid();\n }\n cacheId = source._pixiId;\n }\n var texture = TextureCache[cacheId];\n // Strict-mode rejects invalid cacheIds\n if (isFrame && strict && !texture) {\n throw new Error(\"The cacheId \\\"\" + cacheId + \"\\\" does not exist in TextureCache.\");\n }\n if (!texture && !(source instanceof BaseTexture)) {\n if (!options.resolution) {\n options.resolution = getResolutionOfUrl(source);\n }\n texture = new Texture(new BaseTexture(source, options));\n texture.baseTexture.cacheId = cacheId;\n BaseTexture.addToCache(texture.baseTexture, cacheId);\n Texture.addToCache(texture, cacheId);\n }\n else if (!texture && (source instanceof BaseTexture)) {\n texture = new Texture(source);\n Texture.addToCache(texture, cacheId);\n }\n // lets assume its a base texture!\n return texture;\n };\n /**\n * Useful for loading textures via URLs. Use instead of `Texture.from` because\n * it does a better job of handling failed URLs more effectively. This also ignores\n * `PIXI.settings.STRICT_TEXTURE_CACHE`. Works for Videos, SVGs, Images.\n *\n * @param url - The remote URL to load.\n * @param options - Optional options to include\n * @return - A Promise that resolves to a Texture.\n */\n Texture.fromURL = function (url, options) {\n var resourceOptions = Object.assign({ autoLoad: false }, options === null || options === void 0 ? void 0 : options.resourceOptions);\n var texture = Texture.from(url, Object.assign({ resourceOptions: resourceOptions }, options), false);\n var resource = texture.baseTexture.resource;\n // The texture was already loaded\n if (texture.baseTexture.valid) {\n return Promise.resolve(texture);\n }\n // Manually load the texture, this should allow users to handle load errors\n return resource.load().then(function () { return Promise.resolve(texture); });\n };\n /**\n * Create a new Texture with a BufferResource from a Float32Array.\n * RGBA values are floats from 0 to 1.\n *\n * @param {Float32Array|Uint8Array} buffer - The optional array to use, if no data\n * is provided, a new Float32Array is created.\n * @param width - Width of the resource\n * @param height - Height of the resource\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @return - The resulting new BaseTexture\n */\n Texture.fromBuffer = function (buffer, width, height, options) {\n return new Texture(BaseTexture.fromBuffer(buffer, width, height, options));\n };\n /**\n * Create a texture from a source and add to the cache.\n *\n * @param {HTMLImageElement|HTMLCanvasElement|string} source - The input source.\n * @param imageUrl - File name of texture, for cache and resolving resolution.\n * @param name - Human readable name for the texture cache. If no name is\n * specified, only `imageUrl` will be used as the cache ID.\n * @return - Output texture\n */\n Texture.fromLoader = function (source, imageUrl, name, options) {\n var baseTexture = new BaseTexture(source, Object.assign({\n scaleMode: settings.SCALE_MODE,\n resolution: getResolutionOfUrl(imageUrl),\n }, options));\n var resource = baseTexture.resource;\n if (resource instanceof ImageResource) {\n resource.url = imageUrl;\n }\n var texture = new Texture(baseTexture);\n // No name, use imageUrl instead\n if (!name) {\n name = imageUrl;\n }\n // lets also add the frame to pixi's global cache for 'fromLoader' function\n BaseTexture.addToCache(texture.baseTexture, name);\n Texture.addToCache(texture, name);\n // also add references by url if they are different.\n if (name !== imageUrl) {\n BaseTexture.addToCache(texture.baseTexture, imageUrl);\n Texture.addToCache(texture, imageUrl);\n }\n // Generally images are valid right away\n if (texture.baseTexture.valid) {\n return Promise.resolve(texture);\n }\n // SVG assets need to be parsed async, let's wait\n return new Promise(function (resolve) {\n texture.baseTexture.once('loaded', function () { return resolve(texture); });\n });\n };\n /**\n * Adds a Texture to the global TextureCache. This cache is shared across the whole PIXI object.\n *\n * @param texture - The Texture to add to the cache.\n * @param id - The id that the Texture will be stored against.\n */\n Texture.addToCache = function (texture, id) {\n if (id) {\n if (texture.textureCacheIds.indexOf(id) === -1) {\n texture.textureCacheIds.push(id);\n }\n if (TextureCache[id]) {\n // eslint-disable-next-line no-console\n console.warn(\"Texture added to the cache with an id [\" + id + \"] that already had an entry\");\n }\n TextureCache[id] = texture;\n }\n };\n /**\n * Remove a Texture from the global TextureCache.\n *\n * @param texture - id of a Texture to be removed, or a Texture instance itself\n * @return - The Texture that was removed\n */\n Texture.removeFromCache = function (texture) {\n if (typeof texture === 'string') {\n var textureFromCache = TextureCache[texture];\n if (textureFromCache) {\n var index = textureFromCache.textureCacheIds.indexOf(texture);\n if (index > -1) {\n textureFromCache.textureCacheIds.splice(index, 1);\n }\n delete TextureCache[texture];\n return textureFromCache;\n }\n }\n else if (texture && texture.textureCacheIds) {\n for (var i = 0; i < texture.textureCacheIds.length; ++i) {\n // Check that texture matches the one being passed in before deleting it from the cache.\n if (TextureCache[texture.textureCacheIds[i]] === texture) {\n delete TextureCache[texture.textureCacheIds[i]];\n }\n }\n texture.textureCacheIds.length = 0;\n return texture;\n }\n return null;\n };\n Object.defineProperty(Texture.prototype, \"resolution\", {\n /**\n * Returns resolution of baseTexture\n *\n * @readonly\n */\n get: function () {\n return this.baseTexture.resolution;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"frame\", {\n /**\n * The frame specifies the region of the base texture that this texture uses.\n * Please call `updateUvs()` after you change coordinates of `frame` manually.\n */\n get: function () {\n return this._frame;\n },\n set: function (frame) {\n this._frame = frame;\n this.noFrame = false;\n var x = frame.x, y = frame.y, width = frame.width, height = frame.height;\n var xNotFit = x + width > this.baseTexture.width;\n var yNotFit = y + height > this.baseTexture.height;\n if (xNotFit || yNotFit) {\n var relationship = xNotFit && yNotFit ? 'and' : 'or';\n var errorX = \"X: \" + x + \" + \" + width + \" = \" + (x + width) + \" > \" + this.baseTexture.width;\n var errorY = \"Y: \" + y + \" + \" + height + \" = \" + (y + height) + \" > \" + this.baseTexture.height;\n throw new Error('Texture Error: frame does not fit inside the base Texture dimensions: '\n + (errorX + \" \" + relationship + \" \" + errorY));\n }\n this.valid = width && height && this.baseTexture.valid;\n if (!this.trim && !this.rotate) {\n this.orig = frame;\n }\n if (this.valid) {\n this.updateUvs();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"rotate\", {\n /**\n * Indicates whether the texture is rotated inside the atlas\n * set to 2 to compensate for texture packer rotation\n * set to 6 to compensate for spine packer rotation\n * can be used to rotate or mirror sprites\n * See {@link PIXI.groupD8} for explanation\n */\n get: function () {\n return this._rotate;\n },\n set: function (rotate) {\n this._rotate = rotate;\n if (this.valid) {\n this.updateUvs();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"width\", {\n /** The width of the Texture in pixels. */\n get: function () {\n return this.orig.width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"height\", {\n /** The height of the Texture in pixels. */\n get: function () {\n return this.orig.height;\n },\n enumerable: false,\n configurable: true\n });\n /** Utility function for BaseTexture|Texture cast. */\n Texture.prototype.castToBaseTexture = function () {\n return this.baseTexture;\n };\n return Texture;\n}(EventEmitter));\nfunction createWhiteTexture() {\n var canvas = document.createElement('canvas');\n canvas.width = 16;\n canvas.height = 16;\n var context = canvas.getContext('2d');\n context.fillStyle = 'white';\n context.fillRect(0, 0, 16, 16);\n return new Texture(new BaseTexture(new CanvasResource(canvas)));\n}\nfunction removeAllHandlers(tex) {\n tex.destroy = function _emptyDestroy() { };\n tex.on = function _emptyOn() { };\n tex.once = function _emptyOnce() { };\n tex.emit = function _emptyEmit() { };\n}\n/**\n * An empty texture, used often to not have to create multiple empty textures.\n * Can not be destroyed.\n *\n * @static\n * @constant\n * @member {PIXI.Texture}\n */\nTexture.EMPTY = new Texture(new BaseTexture());\nremoveAllHandlers(Texture.EMPTY);\nremoveAllHandlers(Texture.EMPTY.baseTexture);\n/**\n * A white texture of 16x16 size, used for graphics and other things\n * Can not be destroyed.\n *\n * @static\n * @constant\n * @member {PIXI.Texture}\n */\nTexture.WHITE = createWhiteTexture();\nremoveAllHandlers(Texture.WHITE);\nremoveAllHandlers(Texture.WHITE.baseTexture);\n\n/**\n * A RenderTexture is a special texture that allows any PixiJS display object to be rendered to it.\n *\n * __Hint__: All DisplayObjects (i.e. Sprites) that render to a RenderTexture should be preloaded\n * otherwise black rectangles will be drawn instead.\n *\n * __Hint-2__: The actual memory allocation will happen on first render.\n * You shouldn't create renderTextures each frame just to delete them after, try to reuse them.\n *\n * A RenderTexture takes a snapshot of any Display Object given to its render method. For example:\n *\n * ```js\n * let renderer = PIXI.autoDetectRenderer();\n * let renderTexture = PIXI.RenderTexture.create({ width: 800, height: 600 });\n * let sprite = PIXI.Sprite.from(\"spinObj_01.png\");\n *\n * sprite.position.x = 800/2;\n * sprite.position.y = 600/2;\n * sprite.anchor.x = 0.5;\n * sprite.anchor.y = 0.5;\n *\n * renderer.render(sprite, {renderTexture});\n * ```\n * Note that you should not create a new renderer, but reuse the same one as the rest of the application.\n *\n * The Sprite in this case will be rendered using its local transform. To render this sprite at 0,0\n * you can clear the transform\n *\n * ```js\n *\n * sprite.setTransform()\n *\n * let renderTexture = new PIXI.RenderTexture.create({ width: 100, height: 100 });\n *\n * renderer.render(sprite, {renderTexture}); // Renders to center of RenderTexture\n * ```\n *\n * @memberof PIXI\n */\nvar RenderTexture = /** @class */ (function (_super) {\n __extends(RenderTexture, _super);\n /**\n * @param baseRenderTexture - The base texture object that this texture uses.\n * @param frame - The rectangle frame of the texture to show.\n */\n function RenderTexture(baseRenderTexture, frame) {\n var _this = _super.call(this, baseRenderTexture, frame) || this;\n _this.valid = true;\n _this.filterFrame = null;\n _this.filterPoolKey = null;\n _this.updateUvs();\n return _this;\n }\n Object.defineProperty(RenderTexture.prototype, \"framebuffer\", {\n /**\n * Shortcut to `this.baseTexture.framebuffer`, saves baseTexture cast.\n *\n * @readonly\n */\n get: function () {\n return this.baseTexture.framebuffer;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(RenderTexture.prototype, \"multisample\", {\n /**\n * Shortcut to `this.framebuffer.multisample`.\n *\n * @default PIXI.MSAA_QUALITY.NONE\n */\n get: function () {\n return this.framebuffer.multisample;\n },\n set: function (value) {\n this.framebuffer.multisample = value;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Resizes the RenderTexture.\n *\n * @param desiredWidth - The desired width to resize to.\n * @param desiredHeight - The desired height to resize to.\n * @param resizeBaseTexture - Should the baseTexture.width and height values be resized as well?\n */\n RenderTexture.prototype.resize = function (desiredWidth, desiredHeight, resizeBaseTexture) {\n if (resizeBaseTexture === void 0) { resizeBaseTexture = true; }\n var resolution = this.baseTexture.resolution;\n var width = Math.round(desiredWidth * resolution) / resolution;\n var height = Math.round(desiredHeight * resolution) / resolution;\n // TODO - could be not required..\n this.valid = (width > 0 && height > 0);\n this._frame.width = this.orig.width = width;\n this._frame.height = this.orig.height = height;\n if (resizeBaseTexture) {\n this.baseTexture.resize(width, height);\n }\n this.updateUvs();\n };\n /**\n * Changes the resolution of baseTexture, but does not change framebuffer size.\n *\n * @param resolution - The new resolution to apply to RenderTexture\n */\n RenderTexture.prototype.setResolution = function (resolution) {\n var baseTexture = this.baseTexture;\n if (baseTexture.resolution === resolution) {\n return;\n }\n baseTexture.setResolution(resolution);\n this.resize(baseTexture.width, baseTexture.height, false);\n };\n RenderTexture.create = function (options) {\n var arguments$1 = arguments;\n\n var rest = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n rest[_i - 1] = arguments$1[_i];\n }\n // @deprecated fallback, old-style: create(width, height, scaleMode, resolution)\n if (typeof options === 'number') {\n deprecation('6.0.0', 'Arguments (width, height, scaleMode, resolution) have been deprecated.');\n /* eslint-disable prefer-rest-params */\n options = {\n width: options,\n height: rest[0],\n scaleMode: rest[1],\n resolution: rest[2],\n };\n /* eslint-enable prefer-rest-params */\n }\n return new RenderTexture(new BaseRenderTexture(options));\n };\n return RenderTexture;\n}(Texture));\n\n/**\n * Texture pool, used by FilterSystem and plugins.\n *\n * Stores collection of temporary pow2 or screen-sized renderTextures\n *\n * If you use custom RenderTexturePool for your filters, you can use methods\n * `getFilterTexture` and `returnFilterTexture` same as in\n *\n * @memberof PIXI\n */\nvar RenderTexturePool = /** @class */ (function () {\n /**\n * @param textureOptions - options that will be passed to BaseRenderTexture constructor\n * @param {PIXI.SCALE_MODES} [textureOptions.scaleMode] - See {@link PIXI.SCALE_MODES} for possible values.\n */\n function RenderTexturePool(textureOptions) {\n this.texturePool = {};\n this.textureOptions = textureOptions || {};\n this.enableFullScreen = false;\n this._pixelsWidth = 0;\n this._pixelsHeight = 0;\n }\n /**\n * Creates texture with params that were specified in pool constructor.\n *\n * @param realWidth - Width of texture in pixels.\n * @param realHeight - Height of texture in pixels.\n * @param multisample - Number of samples of the framebuffer.\n */\n RenderTexturePool.prototype.createTexture = function (realWidth, realHeight, multisample) {\n if (multisample === void 0) { multisample = MSAA_QUALITY.NONE; }\n var baseRenderTexture = new BaseRenderTexture(Object.assign({\n width: realWidth,\n height: realHeight,\n resolution: 1,\n multisample: multisample,\n }, this.textureOptions));\n return new RenderTexture(baseRenderTexture);\n };\n /**\n * Gets a Power-of-Two render texture or fullScreen texture\n *\n * @param minWidth - The minimum width of the render texture.\n * @param minHeight - The minimum height of the render texture.\n * @param resolution - The resolution of the render texture.\n * @param multisample - Number of samples of the render texture.\n * @return The new render texture.\n */\n RenderTexturePool.prototype.getOptimalTexture = function (minWidth, minHeight, resolution, multisample) {\n if (resolution === void 0) { resolution = 1; }\n if (multisample === void 0) { multisample = MSAA_QUALITY.NONE; }\n var key;\n minWidth = Math.ceil((minWidth * resolution) - 1e-6);\n minHeight = Math.ceil((minHeight * resolution) - 1e-6);\n if (!this.enableFullScreen || minWidth !== this._pixelsWidth || minHeight !== this._pixelsHeight) {\n minWidth = nextPow2(minWidth);\n minHeight = nextPow2(minHeight);\n key = (((minWidth & 0xFFFF) << 16) | (minHeight & 0xFFFF)) >>> 0;\n if (multisample > 1) {\n key += multisample * 0x100000000;\n }\n }\n else {\n key = multisample > 1 ? -multisample : -1;\n }\n if (!this.texturePool[key]) {\n this.texturePool[key] = [];\n }\n var renderTexture = this.texturePool[key].pop();\n if (!renderTexture) {\n renderTexture = this.createTexture(minWidth, minHeight, multisample);\n }\n renderTexture.filterPoolKey = key;\n renderTexture.setResolution(resolution);\n return renderTexture;\n };\n /**\n * Gets extra texture of the same size as input renderTexture\n *\n * `getFilterTexture(input, 0.5)` or `getFilterTexture(0.5, input)`\n *\n * @param input - renderTexture from which size and resolution will be copied\n * @param resolution - override resolution of the renderTexture\n * It overrides, it does not multiply\n * @param multisample - number of samples of the renderTexture\n * @returns\n */\n RenderTexturePool.prototype.getFilterTexture = function (input, resolution, multisample) {\n var filterTexture = this.getOptimalTexture(input.width, input.height, resolution || input.resolution, multisample || MSAA_QUALITY.NONE);\n filterTexture.filterFrame = input.filterFrame;\n return filterTexture;\n };\n /**\n * Place a render texture back into the pool.\n *\n * @param renderTexture - The renderTexture to free\n */\n RenderTexturePool.prototype.returnTexture = function (renderTexture) {\n var key = renderTexture.filterPoolKey;\n renderTexture.filterFrame = null;\n this.texturePool[key].push(renderTexture);\n };\n /**\n * Alias for returnTexture, to be compliant with FilterSystem interface.\n *\n * @param renderTexture - The renderTexture to free\n */\n RenderTexturePool.prototype.returnFilterTexture = function (renderTexture) {\n this.returnTexture(renderTexture);\n };\n /**\n * Clears the pool.\n *\n * @param destroyTextures - Destroy all stored textures.\n */\n RenderTexturePool.prototype.clear = function (destroyTextures) {\n destroyTextures = destroyTextures !== false;\n if (destroyTextures) {\n for (var i in this.texturePool) {\n var textures = this.texturePool[i];\n if (textures) {\n for (var j = 0; j < textures.length; j++) {\n textures[j].destroy(true);\n }\n }\n }\n }\n this.texturePool = {};\n };\n /**\n * If screen size was changed, drops all screen-sized textures,\n * sets new screen size, sets `enableFullScreen` to true\n *\n * Size is measured in pixels, `renderer.view` can be passed here, not `renderer.screen`\n *\n * @param size - Initial size of screen.\n */\n RenderTexturePool.prototype.setScreenSize = function (size) {\n if (size.width === this._pixelsWidth\n && size.height === this._pixelsHeight) {\n return;\n }\n this.enableFullScreen = size.width > 0 && size.height > 0;\n for (var i in this.texturePool) {\n if (!(Number(i) < 0)) {\n continue;\n }\n var textures = this.texturePool[i];\n if (textures) {\n for (var j = 0; j < textures.length; j++) {\n textures[j].destroy(true);\n }\n }\n this.texturePool[i] = [];\n }\n this._pixelsWidth = size.width;\n this._pixelsHeight = size.height;\n };\n /**\n * Key that is used to store fullscreen renderTextures in a pool\n *\n * @constant\n */\n RenderTexturePool.SCREEN_KEY = -1;\n return RenderTexturePool;\n}());\n\n/* eslint-disable max-len */\n/**\n * Holds the information for a single attribute structure required to render geometry.\n *\n * This does not contain the actual data, but instead has a buffer id that maps to a {@link PIXI.Buffer}\n * This can include anything from positions, uvs, normals, colors etc.\n *\n * @memberof PIXI\n */\nvar Attribute = /** @class */ (function () {\n /**\n * @param buffer - the id of the buffer that this attribute will look for\n * @param size - the size of the attribute. If you have 2 floats per vertex (eg position x and y) this would be 2.\n * @param normalized - should the data be normalized.\n * @param {PIXI.TYPES} [type=PIXI.TYPES.FLOAT] - what type of number is the attribute. Check {@link PIXI.TYPES} to see the ones available\n * @param [stride=0] - How far apart, in bytes, the start of each value is. (used for interleaving data)\n * @param [start=0] - How far into the array to start reading values (used for interleaving data)\n * @param [instance=false] - Whether the geometry is instanced.\n */\n function Attribute(buffer, size, normalized, type, stride, start, instance) {\n if (size === void 0) { size = 0; }\n if (normalized === void 0) { normalized = false; }\n if (type === void 0) { type = TYPES.FLOAT; }\n this.buffer = buffer;\n this.size = size;\n this.normalized = normalized;\n this.type = type;\n this.stride = stride;\n this.start = start;\n this.instance = instance;\n }\n /** Destroys the Attribute. */\n Attribute.prototype.destroy = function () {\n this.buffer = null;\n };\n /**\n * Helper function that creates an Attribute based on the information provided\n *\n * @param buffer - the id of the buffer that this attribute will look for\n * @param [size=0] - the size of the attribute. If you have 2 floats per vertex (eg position x and y) this would be 2\n * @param [normalized=false] - should the data be normalized.\n * @param [type=PIXI.TYPES.FLOAT] - what type of number is the attribute. Check {@link PIXI.TYPES} to see the ones available\n * @param [stride=0] - How far apart, in bytes, the start of each value is. (used for interleaving data)\n * @returns - A new {@link PIXI.Attribute} based on the information provided\n */\n Attribute.from = function (buffer, size, normalized, type, stride) {\n return new Attribute(buffer, size, normalized, type, stride);\n };\n return Attribute;\n}());\n\nvar UID = 0;\n/**\n * A wrapper for data so that it can be used and uploaded by WebGL\n *\n * @memberof PIXI\n */\nvar Buffer = /** @class */ (function () {\n /**\n * @param {ArrayBuffer| SharedArrayBuffer|ArrayBufferView} data - the data to store in the buffer.\n * @param _static - `true` for static buffer\n * @param index - `true` for index buffer\n */\n function Buffer(data, _static, index) {\n if (_static === void 0) { _static = true; }\n if (index === void 0) { index = false; }\n this.data = (data || new Float32Array(1));\n this._glBuffers = {};\n this._updateID = 0;\n this.index = index;\n this.static = _static;\n this.id = UID++;\n this.disposeRunner = new Runner('disposeBuffer');\n }\n // TODO could explore flagging only a partial upload?\n /**\n * Flags this buffer as requiring an upload to the GPU.\n * @param {ArrayBuffer|SharedArrayBuffer|ArrayBufferView|number[]} [data] - the data to update in the buffer.\n */\n Buffer.prototype.update = function (data) {\n if (data instanceof Array) {\n data = new Float32Array(data);\n }\n this.data = data || this.data;\n this._updateID++;\n };\n /** Disposes WebGL resources that are connected to this geometry. */\n Buffer.prototype.dispose = function () {\n this.disposeRunner.emit(this, false);\n };\n /** Destroys the buffer. */\n Buffer.prototype.destroy = function () {\n this.dispose();\n this.data = null;\n };\n Object.defineProperty(Buffer.prototype, \"index\", {\n get: function () {\n return this.type === BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n },\n /**\n * Flags whether this is an index buffer.\n *\n * Index buffers are of type `ELEMENT_ARRAY_BUFFER`. Note that setting this property to false will make\n * the buffer of type `ARRAY_BUFFER`.\n *\n * For backwards compatibility.\n */\n set: function (value) {\n this.type = value ? BUFFER_TYPE.ELEMENT_ARRAY_BUFFER : BUFFER_TYPE.ARRAY_BUFFER;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Helper function that creates a buffer based on an array or TypedArray\n *\n * @param {ArrayBufferView | number[]} data - the TypedArray that the buffer will store. If this is a regular Array it will be converted to a Float32Array.\n * @return - A new Buffer based on the data provided.\n */\n Buffer.from = function (data) {\n if (data instanceof Array) {\n data = new Float32Array(data);\n }\n return new Buffer(data);\n };\n return Buffer;\n}());\n\n/* eslint-disable object-shorthand */\nvar map = {\n Float32Array: Float32Array,\n Uint32Array: Uint32Array,\n Int32Array: Int32Array,\n Uint8Array: Uint8Array,\n};\nfunction interleaveTypedArrays(arrays, sizes) {\n var outSize = 0;\n var stride = 0;\n var views = {};\n for (var i = 0; i < arrays.length; i++) {\n stride += sizes[i];\n outSize += arrays[i].length;\n }\n var buffer = new ArrayBuffer(outSize * 4);\n var out = null;\n var littleOffset = 0;\n for (var i = 0; i < arrays.length; i++) {\n var size = sizes[i];\n var array = arrays[i];\n var type = getBufferType(array);\n if (!views[type]) {\n views[type] = new map[type](buffer);\n }\n out = views[type];\n for (var j = 0; j < array.length; j++) {\n var indexStart = ((j / size | 0) * stride) + littleOffset;\n var index = j % size;\n out[indexStart + index] = array[j];\n }\n littleOffset += size;\n }\n return new Float32Array(buffer);\n}\n\nvar byteSizeMap = { 5126: 4, 5123: 2, 5121: 1 };\nvar UID$1 = 0;\n/* eslint-disable object-shorthand */\nvar map$1 = {\n Float32Array: Float32Array,\n Uint32Array: Uint32Array,\n Int32Array: Int32Array,\n Uint8Array: Uint8Array,\n Uint16Array: Uint16Array,\n};\n/* eslint-disable max-len */\n/**\n * The Geometry represents a model. It consists of two components:\n * - GeometryStyle - The structure of the model such as the attributes layout\n * - GeometryData - the data of the model - this consists of buffers.\n * This can include anything from positions, uvs, normals, colors etc.\n *\n * Geometry can be defined without passing in a style or data if required (thats how I prefer!)\n *\n * ```js\n * let geometry = new PIXI.Geometry();\n *\n * geometry.addAttribute('positions', [0, 0, 100, 0, 100, 100, 0, 100], 2);\n * geometry.addAttribute('uvs', [0,0,1,0,1,1,0,1],2)\n * geometry.addIndex([0,1,2,1,3,2])\n * ```\n *\n * @memberof PIXI\n */\nvar Geometry = /** @class */ (function () {\n /**\n * @param buffers - An array of buffers. optional.\n * @param attributes - Of the geometry, optional structure of the attributes layout\n */\n function Geometry(buffers, attributes) {\n if (buffers === void 0) { buffers = []; }\n if (attributes === void 0) { attributes = {}; }\n this.buffers = buffers;\n this.indexBuffer = null;\n this.attributes = attributes;\n this.glVertexArrayObjects = {};\n this.id = UID$1++;\n this.instanced = false;\n this.instanceCount = 1;\n this.disposeRunner = new Runner('disposeGeometry');\n this.refCount = 0;\n }\n /**\n *\n * Adds an attribute to the geometry\n * Note: `stride` and `start` should be `undefined` if you dont know them, not 0!\n *\n * @param id - the name of the attribute (matching up to a shader)\n * @param {PIXI.Buffer|number[]} buffer - the buffer that holds the data of the attribute . You can also provide an Array and a buffer will be created from it.\n * @param size - the size of the attribute. If you have 2 floats per vertex (eg position x and y) this would be 2\n * @param normalized - should the data be normalized.\n * @param [type=PIXI.TYPES.FLOAT] - what type of number is the attribute. Check {PIXI.TYPES} to see the ones available\n * @param [stride=0] - How far apart, in bytes, the start of each value is. (used for interleaving data)\n * @param [start=0] - How far into the array to start reading values (used for interleaving data)\n * @param instance - Instancing flag\n * @return - Returns self, useful for chaining.\n */\n Geometry.prototype.addAttribute = function (id, buffer, size, normalized, type, stride, start, instance) {\n if (size === void 0) { size = 0; }\n if (normalized === void 0) { normalized = false; }\n if (instance === void 0) { instance = false; }\n if (!buffer) {\n throw new Error('You must pass a buffer when creating an attribute');\n }\n // check if this is a buffer!\n if (!(buffer instanceof Buffer)) {\n // its an array!\n if (buffer instanceof Array) {\n buffer = new Float32Array(buffer);\n }\n buffer = new Buffer(buffer);\n }\n var ids = id.split('|');\n if (ids.length > 1) {\n for (var i = 0; i < ids.length; i++) {\n this.addAttribute(ids[i], buffer, size, normalized, type);\n }\n return this;\n }\n var bufferIndex = this.buffers.indexOf(buffer);\n if (bufferIndex === -1) {\n this.buffers.push(buffer);\n bufferIndex = this.buffers.length - 1;\n }\n this.attributes[id] = new Attribute(bufferIndex, size, normalized, type, stride, start, instance);\n // assuming that if there is instanced data then this will be drawn with instancing!\n this.instanced = this.instanced || instance;\n return this;\n };\n /**\n * Returns the requested attribute.\n *\n * @param id - The name of the attribute required\n * @return - The attribute requested.\n */\n Geometry.prototype.getAttribute = function (id) {\n return this.attributes[id];\n };\n /**\n * Returns the requested buffer.\n *\n * @param id - The name of the buffer required.\n * @return - The buffer requested.\n */\n Geometry.prototype.getBuffer = function (id) {\n return this.buffers[this.getAttribute(id).buffer];\n };\n /**\n *\n * Adds an index buffer to the geometry\n * The index buffer contains integers, three for each triangle in the geometry, which reference the various attribute buffers (position, colour, UV coordinates, other UV coordinates, normal, …). There is only ONE index buffer.\n *\n * @param {PIXI.Buffer|number[]} [buffer] - The buffer that holds the data of the index buffer. You can also provide an Array and a buffer will be created from it.\n * @return - Returns self, useful for chaining.\n */\n Geometry.prototype.addIndex = function (buffer) {\n if (!(buffer instanceof Buffer)) {\n // its an array!\n if (buffer instanceof Array) {\n buffer = new Uint16Array(buffer);\n }\n buffer = new Buffer(buffer);\n }\n buffer.type = BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n this.indexBuffer = buffer;\n if (this.buffers.indexOf(buffer) === -1) {\n this.buffers.push(buffer);\n }\n return this;\n };\n /**\n * Returns the index buffer\n *\n * @return - The index buffer.\n */\n Geometry.prototype.getIndex = function () {\n return this.indexBuffer;\n };\n /**\n * This function modifies the structure so that all current attributes become interleaved into a single buffer\n * This can be useful if your model remains static as it offers a little performance boost\n *\n * @return - Returns self, useful for chaining.\n */\n Geometry.prototype.interleave = function () {\n // a simple check to see if buffers are already interleaved..\n if (this.buffers.length === 1 || (this.buffers.length === 2 && this.indexBuffer))\n { return this; }\n // assume already that no buffers are interleaved\n var arrays = [];\n var sizes = [];\n var interleavedBuffer = new Buffer();\n var i;\n for (i in this.attributes) {\n var attribute = this.attributes[i];\n var buffer = this.buffers[attribute.buffer];\n arrays.push(buffer.data);\n sizes.push((attribute.size * byteSizeMap[attribute.type]) / 4);\n attribute.buffer = 0;\n }\n interleavedBuffer.data = interleaveTypedArrays(arrays, sizes);\n for (i = 0; i < this.buffers.length; i++) {\n if (this.buffers[i] !== this.indexBuffer) {\n this.buffers[i].destroy();\n }\n }\n this.buffers = [interleavedBuffer];\n if (this.indexBuffer) {\n this.buffers.push(this.indexBuffer);\n }\n return this;\n };\n /** Get the size of the geometries, in vertices. */\n Geometry.prototype.getSize = function () {\n for (var i in this.attributes) {\n var attribute = this.attributes[i];\n var buffer = this.buffers[attribute.buffer];\n return buffer.data.length / ((attribute.stride / 4) || attribute.size);\n }\n return 0;\n };\n /** Disposes WebGL resources that are connected to this geometry. */\n Geometry.prototype.dispose = function () {\n this.disposeRunner.emit(this, false);\n };\n /** Destroys the geometry. */\n Geometry.prototype.destroy = function () {\n this.dispose();\n this.buffers = null;\n this.indexBuffer = null;\n this.attributes = null;\n };\n /**\n * Returns a clone of the geometry.\n *\n * @returns - A new clone of this geometry.\n */\n Geometry.prototype.clone = function () {\n var geometry = new Geometry();\n for (var i = 0; i < this.buffers.length; i++) {\n geometry.buffers[i] = new Buffer(this.buffers[i].data.slice(0));\n }\n for (var i in this.attributes) {\n var attrib = this.attributes[i];\n geometry.attributes[i] = new Attribute(attrib.buffer, attrib.size, attrib.normalized, attrib.type, attrib.stride, attrib.start, attrib.instance);\n }\n if (this.indexBuffer) {\n geometry.indexBuffer = geometry.buffers[this.buffers.indexOf(this.indexBuffer)];\n geometry.indexBuffer.type = BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n }\n return geometry;\n };\n /**\n * Merges an array of geometries into a new single one.\n *\n * Geometry attribute styles must match for this operation to work.\n *\n * @param geometries - array of geometries to merge\n * @return - Shiny new geometry!\n */\n Geometry.merge = function (geometries) {\n // todo add a geometry check!\n // also a size check.. cant be too big!]\n var geometryOut = new Geometry();\n var arrays = [];\n var sizes = [];\n var offsets = [];\n var geometry;\n // pass one.. get sizes..\n for (var i = 0; i < geometries.length; i++) {\n geometry = geometries[i];\n for (var j = 0; j < geometry.buffers.length; j++) {\n sizes[j] = sizes[j] || 0;\n sizes[j] += geometry.buffers[j].data.length;\n offsets[j] = 0;\n }\n }\n // build the correct size arrays..\n for (var i = 0; i < geometry.buffers.length; i++) {\n // TODO types!\n arrays[i] = new map$1[getBufferType(geometry.buffers[i].data)](sizes[i]);\n geometryOut.buffers[i] = new Buffer(arrays[i]);\n }\n // pass to set data..\n for (var i = 0; i < geometries.length; i++) {\n geometry = geometries[i];\n for (var j = 0; j < geometry.buffers.length; j++) {\n arrays[j].set(geometry.buffers[j].data, offsets[j]);\n offsets[j] += geometry.buffers[j].data.length;\n }\n }\n geometryOut.attributes = geometry.attributes;\n if (geometry.indexBuffer) {\n geometryOut.indexBuffer = geometryOut.buffers[geometry.buffers.indexOf(geometry.indexBuffer)];\n geometryOut.indexBuffer.type = BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n var offset = 0;\n var stride = 0;\n var offset2 = 0;\n var bufferIndexToCount = 0;\n // get a buffer\n for (var i = 0; i < geometry.buffers.length; i++) {\n if (geometry.buffers[i] !== geometry.indexBuffer) {\n bufferIndexToCount = i;\n break;\n }\n }\n // figure out the stride of one buffer..\n for (var i in geometry.attributes) {\n var attribute = geometry.attributes[i];\n if ((attribute.buffer | 0) === bufferIndexToCount) {\n stride += ((attribute.size * byteSizeMap[attribute.type]) / 4);\n }\n }\n // time to off set all indexes..\n for (var i = 0; i < geometries.length; i++) {\n var indexBufferData = geometries[i].indexBuffer.data;\n for (var j = 0; j < indexBufferData.length; j++) {\n geometryOut.indexBuffer.data[j + offset2] += offset;\n }\n offset += geometries[i].buffers[bufferIndexToCount].data.length / (stride);\n offset2 += indexBufferData.length;\n }\n }\n return geometryOut;\n };\n return Geometry;\n}());\n\n/**\n * Helper class to create a quad\n *\n * @memberof PIXI\n */\nvar Quad = /** @class */ (function (_super) {\n __extends(Quad, _super);\n function Quad() {\n var _this = _super.call(this) || this;\n _this.addAttribute('aVertexPosition', new Float32Array([\n 0, 0,\n 1, 0,\n 1, 1,\n 0, 1 ]))\n .addIndex([0, 1, 3, 2]);\n return _this;\n }\n return Quad;\n}(Geometry));\n\n/**\n * Helper class to create a quad with uvs like in v4\n *\n * @memberof PIXI\n */\nvar QuadUv = /** @class */ (function (_super) {\n __extends(QuadUv, _super);\n function QuadUv() {\n var _this = _super.call(this) || this;\n _this.vertices = new Float32Array([\n -1, -1,\n 1, -1,\n 1, 1,\n -1, 1 ]);\n _this.uvs = new Float32Array([\n 0, 0,\n 1, 0,\n 1, 1,\n 0, 1 ]);\n _this.vertexBuffer = new Buffer(_this.vertices);\n _this.uvBuffer = new Buffer(_this.uvs);\n _this.addAttribute('aVertexPosition', _this.vertexBuffer)\n .addAttribute('aTextureCoord', _this.uvBuffer)\n .addIndex([0, 1, 2, 0, 2, 3]);\n return _this;\n }\n /**\n * Maps two Rectangle to the quad.\n *\n * @param targetTextureFrame - The first rectangle\n * @param destinationFrame - The second rectangle\n * @return - Returns itself.\n */\n QuadUv.prototype.map = function (targetTextureFrame, destinationFrame) {\n var x = 0; // destinationFrame.x / targetTextureFrame.width;\n var y = 0; // destinationFrame.y / targetTextureFrame.height;\n this.uvs[0] = x;\n this.uvs[1] = y;\n this.uvs[2] = x + (destinationFrame.width / targetTextureFrame.width);\n this.uvs[3] = y;\n this.uvs[4] = x + (destinationFrame.width / targetTextureFrame.width);\n this.uvs[5] = y + (destinationFrame.height / targetTextureFrame.height);\n this.uvs[6] = x;\n this.uvs[7] = y + (destinationFrame.height / targetTextureFrame.height);\n x = destinationFrame.x;\n y = destinationFrame.y;\n this.vertices[0] = x;\n this.vertices[1] = y;\n this.vertices[2] = x + destinationFrame.width;\n this.vertices[3] = y;\n this.vertices[4] = x + destinationFrame.width;\n this.vertices[5] = y + destinationFrame.height;\n this.vertices[6] = x;\n this.vertices[7] = y + destinationFrame.height;\n this.invalidate();\n return this;\n };\n /**\n * Legacy upload method, just marks buffers dirty.\n *\n * @returns - Returns itself.\n */\n QuadUv.prototype.invalidate = function () {\n this.vertexBuffer._updateID++;\n this.uvBuffer._updateID++;\n return this;\n };\n return QuadUv;\n}(Geometry));\n\nvar UID$2 = 0;\n/**\n * Uniform group holds uniform map and some ID's for work\n *\n * `UniformGroup` has two modes:\n *\n * 1: Normal mode\n * Normal mode will upload the uniforms with individual function calls as required\n *\n * 2: Uniform buffer mode\n * This mode will treat the uniforms as a uniform buffer. You can pass in either a buffer that you manually handle, or\n * or a generic object that PixiJS will automatically map to a buffer for you.\n * For maximum benefits, make Ubo UniformGroups static, and only update them each frame.\n *\n * Rules of UBOs:\n * - UBOs only work with WebGL2, so make sure you have a fallback!\n * - Only floats are supported (including vec[2,3,4], mat[2,3,4])\n * - Samplers cannot be used in ubo's (a GPU limitation)\n * - You must ensure that the object you pass in exactly matches in the shader ubo structure.\n * Otherwise, weirdness will ensue!\n * - The name of the ubo object added to the group must match exactly the name of the ubo in the shader.\n *\n * ```\n * // ubo in shader:\n * uniform myCoolData { // declaring a ubo..\n * mat4 uCoolMatrix;\n * float uFloatyMcFloatFace\n *\n *\n * // a new uniform buffer object..\n * const myCoolData = new UniformBufferGroup({\n * uCoolMatrix: new Matrix(),\n * uFloatyMcFloatFace: 23,\n * }}\n *\n * // build a shader...\n * const shader = Shader.from(srcVert, srcFrag, {\n * myCoolData // name matches the ubo name in the shader. will be processed accordingly.\n * })\n *\n * ```\n *\n * @memberof PIXI\n */\nvar UniformGroup = /** @class */ (function () {\n /**\n * @param {object | Buffer} [uniforms] - Custom uniforms to use to augment the built-in ones. Or a pixi buffer.\n * @param isStatic - Uniforms wont be changed after creation.\n * @param isUbo - If true, will treat this uniform group as a uniform buffer object.\n */\n function UniformGroup(uniforms, isStatic, isUbo) {\n this.group = true;\n // lets generate this when the shader ?\n this.syncUniforms = {};\n this.dirtyId = 0;\n this.id = UID$2++;\n this.static = !!isStatic;\n this.ubo = !!isUbo;\n if (uniforms instanceof Buffer) {\n this.buffer = uniforms;\n this.buffer.type = BUFFER_TYPE.UNIFORM_BUFFER;\n this.autoManage = false;\n this.ubo = true;\n }\n else {\n this.uniforms = uniforms;\n if (this.ubo) {\n this.buffer = new Buffer(new Float32Array(1));\n this.buffer.type = BUFFER_TYPE.UNIFORM_BUFFER;\n this.autoManage = true;\n }\n }\n }\n UniformGroup.prototype.update = function () {\n this.dirtyId++;\n if (!this.autoManage && this.buffer) {\n this.buffer.update();\n }\n };\n UniformGroup.prototype.add = function (name, uniforms, _static) {\n if (!this.ubo) {\n this.uniforms[name] = new UniformGroup(uniforms, _static);\n }\n else {\n // eslint-disable-next-line max-len\n throw new Error('[UniformGroup] uniform groups in ubo mode cannot be modified, or have uniform groups nested in them');\n }\n };\n UniformGroup.from = function (uniforms, _static, _ubo) {\n return new UniformGroup(uniforms, _static, _ubo);\n };\n /**\n * A short hand function for creating a static UBO UniformGroup.\n *\n * @param uniforms - the ubo item\n * @param _static - should this be updated each time it is used? defaults to true here!\n */\n UniformGroup.uboFrom = function (uniforms, _static) {\n return new UniformGroup(uniforms, _static !== null && _static !== void 0 ? _static : true, true);\n };\n return UniformGroup;\n}());\n\n/**\n * System plugin to the renderer to manage filter states.\n *\n * @ignore\n */\nvar FilterState = /** @class */ (function () {\n function FilterState() {\n this.renderTexture = null;\n this.target = null;\n this.legacy = false;\n this.resolution = 1;\n this.multisample = MSAA_QUALITY.NONE;\n // next three fields are created only for root\n // re-assigned for everything else\n this.sourceFrame = new Rectangle();\n this.destinationFrame = new Rectangle();\n this.bindingSourceFrame = new Rectangle();\n this.bindingDestinationFrame = new Rectangle();\n this.filters = [];\n this.transform = null;\n }\n /** Clears the state */\n FilterState.prototype.clear = function () {\n this.target = null;\n this.filters = null;\n this.renderTexture = null;\n };\n return FilterState;\n}());\n\nvar tempPoints = [new Point(), new Point(), new Point(), new Point()];\nvar tempMatrix = new Matrix();\n/**\n * System plugin to the renderer to manage filters.\n *\n * ## Pipeline\n *\n * The FilterSystem executes the filtering pipeline by rendering the display-object into a texture, applying its\n * [filters]{@link PIXI.Filter} in series, and the last filter outputs into the final render-target.\n *\n * The filter-frame is the rectangle in world space being filtered, and those contents are mapped into\n * `(0, 0, filterFrame.width, filterFrame.height)` into the filter render-texture. The filter-frame is also called\n * the source-frame, as it is used to bind the filter render-textures. The last filter outputs to the `filterFrame`\n * in the final render-target.\n *\n * ## Usage\n *\n * {@link PIXI.Container#renderAdvanced} is an example of how to use the filter system. It is a 3 step process:\n *\n * * **push**: Use {@link PIXI.FilterSystem#push} to push the set of filters to be applied on a filter-target.\n * * **render**: Render the contents to be filtered using the renderer. The filter-system will only capture the contents\n * inside the bounds of the filter-target. NOTE: Using {@link PIXI.Renderer#render} is\n * illegal during an existing render cycle, and it may reset the filter system.\n * * **pop**: Use {@link PIXI.FilterSystem#pop} to pop & execute the filters you initially pushed. It will apply them\n * serially and output to the bounds of the filter-target.\n *\n * @memberof PIXI\n */\nvar FilterSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function FilterSystem(renderer) {\n this.renderer = renderer;\n this.defaultFilterStack = [{}];\n this.texturePool = new RenderTexturePool();\n this.texturePool.setScreenSize(renderer.view);\n this.statePool = [];\n this.quad = new Quad();\n this.quadUv = new QuadUv();\n this.tempRect = new Rectangle();\n this.activeState = {};\n this.globalUniforms = new UniformGroup({\n outputFrame: new Rectangle(),\n inputSize: new Float32Array(4),\n inputPixel: new Float32Array(4),\n inputClamp: new Float32Array(4),\n resolution: 1,\n // legacy variables\n filterArea: new Float32Array(4),\n filterClamp: new Float32Array(4),\n }, true);\n this.forceClear = false;\n this.useMaxPadding = false;\n }\n /**\n * Pushes a set of filters to be applied later to the system. This will redirect further rendering into an\n * input render-texture for the rest of the filtering pipeline.\n *\n * @param {PIXI.DisplayObject} target - The target of the filter to render.\n * @param filters - The filters to apply.\n */\n FilterSystem.prototype.push = function (target, filters) {\n var _a, _b;\n var renderer = this.renderer;\n var filterStack = this.defaultFilterStack;\n var state = this.statePool.pop() || new FilterState();\n var renderTextureSystem = this.renderer.renderTexture;\n var resolution = filters[0].resolution;\n var multisample = filters[0].multisample;\n var padding = filters[0].padding;\n var autoFit = filters[0].autoFit;\n // We don't know whether it's a legacy filter until it was bound for the first time,\n // therefore we have to assume that it is if legacy is undefined.\n var legacy = (_a = filters[0].legacy) !== null && _a !== void 0 ? _a : true;\n for (var i = 1; i < filters.length; i++) {\n var filter = filters[i];\n // let's use the lowest resolution\n resolution = Math.min(resolution, filter.resolution);\n // let's use the lowest number of samples\n multisample = Math.min(multisample, filter.multisample);\n // figure out the padding required for filters\n padding = this.useMaxPadding\n // old behavior: use largest amount of padding!\n ? Math.max(padding, filter.padding)\n // new behavior: sum the padding\n : padding + filter.padding;\n // only auto fit if all filters are autofit\n autoFit = autoFit && filter.autoFit;\n legacy = legacy || ((_b = filter.legacy) !== null && _b !== void 0 ? _b : true);\n }\n if (filterStack.length === 1) {\n this.defaultFilterStack[0].renderTexture = renderTextureSystem.current;\n }\n filterStack.push(state);\n state.resolution = resolution;\n state.multisample = multisample;\n state.legacy = legacy;\n state.target = target;\n state.sourceFrame.copyFrom(target.filterArea || target.getBounds(true));\n state.sourceFrame.pad(padding);\n if (autoFit) {\n var sourceFrameProjected = this.tempRect.copyFrom(renderTextureSystem.sourceFrame);\n // Project source frame into world space (if projection is applied)\n if (renderer.projection.transform) {\n this.transformAABB(tempMatrix.copyFrom(renderer.projection.transform).invert(), sourceFrameProjected);\n }\n state.sourceFrame.fit(sourceFrameProjected);\n }\n // Round sourceFrame in screen space based on render-texture.\n this.roundFrame(state.sourceFrame, renderTextureSystem.current ? renderTextureSystem.current.resolution : renderer.resolution, renderTextureSystem.sourceFrame, renderTextureSystem.destinationFrame, renderer.projection.transform);\n state.renderTexture = this.getOptimalFilterTexture(state.sourceFrame.width, state.sourceFrame.height, resolution, multisample);\n state.filters = filters;\n state.destinationFrame.width = state.renderTexture.width;\n state.destinationFrame.height = state.renderTexture.height;\n var destinationFrame = this.tempRect;\n destinationFrame.x = 0;\n destinationFrame.y = 0;\n destinationFrame.width = state.sourceFrame.width;\n destinationFrame.height = state.sourceFrame.height;\n state.renderTexture.filterFrame = state.sourceFrame;\n state.bindingSourceFrame.copyFrom(renderTextureSystem.sourceFrame);\n state.bindingDestinationFrame.copyFrom(renderTextureSystem.destinationFrame);\n state.transform = renderer.projection.transform;\n renderer.projection.transform = null;\n renderTextureSystem.bind(state.renderTexture, state.sourceFrame, destinationFrame);\n renderer.framebuffer.clear(0, 0, 0, 0);\n };\n /** Pops off the filter and applies it. */\n FilterSystem.prototype.pop = function () {\n var filterStack = this.defaultFilterStack;\n var state = filterStack.pop();\n var filters = state.filters;\n this.activeState = state;\n var globalUniforms = this.globalUniforms.uniforms;\n globalUniforms.outputFrame = state.sourceFrame;\n globalUniforms.resolution = state.resolution;\n var inputSize = globalUniforms.inputSize;\n var inputPixel = globalUniforms.inputPixel;\n var inputClamp = globalUniforms.inputClamp;\n inputSize[0] = state.destinationFrame.width;\n inputSize[1] = state.destinationFrame.height;\n inputSize[2] = 1.0 / inputSize[0];\n inputSize[3] = 1.0 / inputSize[1];\n inputPixel[0] = Math.round(inputSize[0] * state.resolution);\n inputPixel[1] = Math.round(inputSize[1] * state.resolution);\n inputPixel[2] = 1.0 / inputPixel[0];\n inputPixel[3] = 1.0 / inputPixel[1];\n inputClamp[0] = 0.5 * inputPixel[2];\n inputClamp[1] = 0.5 * inputPixel[3];\n inputClamp[2] = (state.sourceFrame.width * inputSize[2]) - (0.5 * inputPixel[2]);\n inputClamp[3] = (state.sourceFrame.height * inputSize[3]) - (0.5 * inputPixel[3]);\n // only update the rect if its legacy..\n if (state.legacy) {\n var filterArea = globalUniforms.filterArea;\n filterArea[0] = state.destinationFrame.width;\n filterArea[1] = state.destinationFrame.height;\n filterArea[2] = state.sourceFrame.x;\n filterArea[3] = state.sourceFrame.y;\n globalUniforms.filterClamp = globalUniforms.inputClamp;\n }\n this.globalUniforms.update();\n var lastState = filterStack[filterStack.length - 1];\n this.renderer.framebuffer.blit();\n if (filters.length === 1) {\n filters[0].apply(this, state.renderTexture, lastState.renderTexture, CLEAR_MODES.BLEND, state);\n this.returnFilterTexture(state.renderTexture);\n }\n else {\n var flip = state.renderTexture;\n var flop = this.getOptimalFilterTexture(flip.width, flip.height, state.resolution);\n flop.filterFrame = flip.filterFrame;\n var i = 0;\n for (i = 0; i < filters.length - 1; ++i) {\n if (i === 1 && state.multisample > 1) {\n flop = this.getOptimalFilterTexture(flip.width, flip.height, state.resolution);\n flop.filterFrame = flip.filterFrame;\n }\n filters[i].apply(this, flip, flop, CLEAR_MODES.CLEAR, state);\n var t = flip;\n flip = flop;\n flop = t;\n }\n filters[i].apply(this, flip, lastState.renderTexture, CLEAR_MODES.BLEND, state);\n if (i > 1 && state.multisample > 1) {\n this.returnFilterTexture(state.renderTexture);\n }\n this.returnFilterTexture(flip);\n this.returnFilterTexture(flop);\n }\n // lastState.renderTexture is blitted when lastState is popped\n state.clear();\n this.statePool.push(state);\n };\n /**\n * Binds a renderTexture with corresponding `filterFrame`, clears it if mode corresponds.\n *\n * @param filterTexture - renderTexture to bind, should belong to filter pool or filter stack\n * @param clearMode - clearMode, by default its CLEAR/YES. See {@link PIXI.CLEAR_MODES}\n */\n FilterSystem.prototype.bindAndClear = function (filterTexture, clearMode) {\n if (clearMode === void 0) { clearMode = CLEAR_MODES.CLEAR; }\n var _a = this.renderer, renderTextureSystem = _a.renderTexture, stateSystem = _a.state;\n if (filterTexture === this.defaultFilterStack[this.defaultFilterStack.length - 1].renderTexture) {\n // Restore projection transform if rendering into the output render-target.\n this.renderer.projection.transform = this.activeState.transform;\n }\n else {\n // Prevent projection within filtering pipeline.\n this.renderer.projection.transform = null;\n }\n if (filterTexture && filterTexture.filterFrame) {\n var destinationFrame = this.tempRect;\n destinationFrame.x = 0;\n destinationFrame.y = 0;\n destinationFrame.width = filterTexture.filterFrame.width;\n destinationFrame.height = filterTexture.filterFrame.height;\n renderTextureSystem.bind(filterTexture, filterTexture.filterFrame, destinationFrame);\n }\n else if (filterTexture !== this.defaultFilterStack[this.defaultFilterStack.length - 1].renderTexture) {\n renderTextureSystem.bind(filterTexture);\n }\n else {\n // Restore binding for output render-target.\n this.renderer.renderTexture.bind(filterTexture, this.activeState.bindingSourceFrame, this.activeState.bindingDestinationFrame);\n }\n // Clear the texture in BLIT mode if blending is disabled or the forceClear flag is set. The blending\n // is stored in the 0th bit of the state.\n var autoClear = (stateSystem.stateId & 1) || this.forceClear;\n if (clearMode === CLEAR_MODES.CLEAR\n || (clearMode === CLEAR_MODES.BLIT && autoClear)) {\n // Use framebuffer.clear because we want to clear the whole filter texture, not just the filtering\n // area over which the shaders are run. This is because filters may sampling outside of it (e.g. blur)\n // instead of clamping their arithmetic.\n this.renderer.framebuffer.clear(0, 0, 0, 0);\n }\n };\n /**\n * Draws a filter using the default rendering process.\n *\n * This should be called only by {@link Filter#apply}.\n *\n * @param filter - The filter to draw.\n * @param input - The input render target.\n * @param output - The target to output to.\n * @param clearMode - Should the output be cleared before rendering to it\n */\n FilterSystem.prototype.applyFilter = function (filter, input, output, clearMode) {\n var renderer = this.renderer;\n // Set state before binding, so bindAndClear gets the blend mode.\n renderer.state.set(filter.state);\n this.bindAndClear(output, clearMode);\n // set the uniforms..\n filter.uniforms.uSampler = input;\n filter.uniforms.filterGlobals = this.globalUniforms;\n // TODO make it so that the order of this does not matter..\n // because it does at the moment cos of global uniforms.\n // they need to get resynced\n renderer.shader.bind(filter);\n // check to see if the filter is a legacy one..\n filter.legacy = !!filter.program.attributeData.aTextureCoord;\n if (filter.legacy) {\n this.quadUv.map(input._frame, input.filterFrame);\n renderer.geometry.bind(this.quadUv);\n renderer.geometry.draw(DRAW_MODES.TRIANGLES);\n }\n else {\n renderer.geometry.bind(this.quad);\n renderer.geometry.draw(DRAW_MODES.TRIANGLE_STRIP);\n }\n };\n /**\n * Multiply _input normalized coordinates_ to this matrix to get _sprite texture normalized coordinates_.\n *\n * Use `outputMatrix * vTextureCoord` in the shader.\n *\n * @param outputMatrix - The matrix to output to.\n * @param {PIXI.Sprite} sprite - The sprite to map to.\n * @return The mapped matrix.\n */\n FilterSystem.prototype.calculateSpriteMatrix = function (outputMatrix, sprite) {\n var _a = this.activeState, sourceFrame = _a.sourceFrame, destinationFrame = _a.destinationFrame;\n var orig = sprite._texture.orig;\n var mappedMatrix = outputMatrix.set(destinationFrame.width, 0, 0, destinationFrame.height, sourceFrame.x, sourceFrame.y);\n var worldTransform = sprite.worldTransform.copyTo(Matrix.TEMP_MATRIX);\n worldTransform.invert();\n mappedMatrix.prepend(worldTransform);\n mappedMatrix.scale(1.0 / orig.width, 1.0 / orig.height);\n mappedMatrix.translate(sprite.anchor.x, sprite.anchor.y);\n return mappedMatrix;\n };\n /** Destroys this Filter System. */\n FilterSystem.prototype.destroy = function () {\n this.renderer = null;\n // Those textures has to be destroyed by RenderTextureSystem or FramebufferSystem\n this.texturePool.clear(false);\n };\n /**\n * Gets a Power-of-Two render texture or fullScreen texture\n *\n * @param minWidth - The minimum width of the render texture in real pixels.\n * @param minHeight - The minimum height of the render texture in real pixels.\n * @param resolution - The resolution of the render texture.\n * @param multisample - Number of samples of the render texture.\n * @return - The new render texture.\n */\n FilterSystem.prototype.getOptimalFilterTexture = function (minWidth, minHeight, resolution, multisample) {\n if (resolution === void 0) { resolution = 1; }\n if (multisample === void 0) { multisample = MSAA_QUALITY.NONE; }\n return this.texturePool.getOptimalTexture(minWidth, minHeight, resolution, multisample);\n };\n /**\n * Gets extra render texture to use inside current filter\n * To be compliant with older filters, you can use params in any order\n *\n * @param input - renderTexture from which size and resolution will be copied\n * @param resolution - override resolution of the renderTexture\n * @param multisample - number of samples of the renderTexture\n */\n FilterSystem.prototype.getFilterTexture = function (input, resolution, multisample) {\n if (typeof input === 'number') {\n var swap = input;\n input = resolution;\n resolution = swap;\n }\n input = input || this.activeState.renderTexture;\n var filterTexture = this.texturePool.getOptimalTexture(input.width, input.height, resolution || input.resolution, multisample || MSAA_QUALITY.NONE);\n filterTexture.filterFrame = input.filterFrame;\n return filterTexture;\n };\n /**\n * Frees a render texture back into the pool.\n *\n * @param renderTexture - The renderTarget to free\n */\n FilterSystem.prototype.returnFilterTexture = function (renderTexture) {\n this.texturePool.returnTexture(renderTexture);\n };\n /** Empties the texture pool. */\n FilterSystem.prototype.emptyPool = function () {\n this.texturePool.clear(true);\n };\n /** Calls `texturePool.resize()`, affects fullScreen renderTextures. */\n FilterSystem.prototype.resize = function () {\n this.texturePool.setScreenSize(this.renderer.view);\n };\n /**\n * @param matrix - first param\n * @param rect - second param\n */\n FilterSystem.prototype.transformAABB = function (matrix, rect) {\n var lt = tempPoints[0];\n var lb = tempPoints[1];\n var rt = tempPoints[2];\n var rb = tempPoints[3];\n lt.set(rect.left, rect.top);\n lb.set(rect.left, rect.bottom);\n rt.set(rect.right, rect.top);\n rb.set(rect.right, rect.bottom);\n matrix.apply(lt, lt);\n matrix.apply(lb, lb);\n matrix.apply(rt, rt);\n matrix.apply(rb, rb);\n var x0 = Math.min(lt.x, lb.x, rt.x, rb.x);\n var y0 = Math.min(lt.y, lb.y, rt.y, rb.y);\n var x1 = Math.max(lt.x, lb.x, rt.x, rb.x);\n var y1 = Math.max(lt.y, lb.y, rt.y, rb.y);\n rect.x = x0;\n rect.y = y0;\n rect.width = x1 - x0;\n rect.height = y1 - y0;\n };\n FilterSystem.prototype.roundFrame = function (frame, resolution, bindingSourceFrame, bindingDestinationFrame, transform) {\n if (frame.width <= 0 || frame.height <= 0 || bindingSourceFrame.width <= 0 || bindingSourceFrame.height <= 0) {\n return;\n }\n if (transform) {\n var a = transform.a, b = transform.b, c = transform.c, d = transform.d;\n // Skip if skew/rotation present in matrix, except for multiple of 90° rotation. If rotation\n // is a multiple of 90°, then either pair of (b,c) or (a,d) will be (0,0).\n if ((Math.abs(b) > 1e-4 || Math.abs(c) > 1e-4)\n && (Math.abs(a) > 1e-4 || Math.abs(d) > 1e-4)) {\n return;\n }\n }\n transform = transform ? tempMatrix.copyFrom(transform) : tempMatrix.identity();\n // Get forward transform from world space to screen space\n transform\n .translate(-bindingSourceFrame.x, -bindingSourceFrame.y)\n .scale(bindingDestinationFrame.width / bindingSourceFrame.width, bindingDestinationFrame.height / bindingSourceFrame.height)\n .translate(bindingDestinationFrame.x, bindingDestinationFrame.y);\n // Convert frame to screen space\n this.transformAABB(transform, frame);\n // Round frame in screen space\n frame.ceil(resolution);\n // Project back into world space.\n this.transformAABB(transform.invert(), frame);\n };\n return FilterSystem;\n}());\n\n/**\n * Base for a common object renderer that can be used as a\n * system renderer plugin.\n *\n * @memberof PIXI\n */\nvar ObjectRenderer = /** @class */ (function () {\n /**\n * @param renderer - The renderer this manager works for.\n */\n function ObjectRenderer(renderer) {\n this.renderer = renderer;\n }\n /**\n * Stub method that should be used to empty the current\n * batch by rendering objects now.\n */\n ObjectRenderer.prototype.flush = function () {\n // flush!\n };\n /**\n * Generic destruction method that frees all resources. This\n * should be called by subclasses.\n */\n ObjectRenderer.prototype.destroy = function () {\n this.renderer = null;\n };\n /**\n * Stub method that initializes any state required before\n * rendering starts. It is different from the `prerender`\n * signal, which occurs every frame, in that it is called\n * whenever an object requests _this_ renderer specifically.\n */\n ObjectRenderer.prototype.start = function () {\n // set the shader..\n };\n /**\n * Stops the renderer. It should free up any state and\n * become dormant.\n */\n ObjectRenderer.prototype.stop = function () {\n this.flush();\n };\n /**\n * Keeps the object to render. It doesn't have to be\n * rendered immediately.\n *\n * @param {PIXI.DisplayObject} object - The object to render.\n */\n ObjectRenderer.prototype.render = function (_object) {\n // render the object\n };\n return ObjectRenderer;\n}());\n\n/**\n * System plugin to the renderer to manage batching.\n *\n * @memberof PIXI\n */\nvar BatchSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function BatchSystem(renderer) {\n this.renderer = renderer;\n this.emptyRenderer = new ObjectRenderer(renderer);\n this.currentRenderer = this.emptyRenderer;\n }\n /**\n * Changes the current renderer to the one given in parameter\n *\n * @param objectRenderer - The object renderer to use.\n */\n BatchSystem.prototype.setObjectRenderer = function (objectRenderer) {\n if (this.currentRenderer === objectRenderer) {\n return;\n }\n this.currentRenderer.stop();\n this.currentRenderer = objectRenderer;\n this.currentRenderer.start();\n };\n /**\n * This should be called if you wish to do some custom rendering\n * It will basically render anything that may be batched up such as sprites\n */\n BatchSystem.prototype.flush = function () {\n this.setObjectRenderer(this.emptyRenderer);\n };\n /**\n * Reset the system to an empty renderer\n */\n BatchSystem.prototype.reset = function () {\n this.setObjectRenderer(this.emptyRenderer);\n };\n /**\n * Handy function for batch renderers: copies bound textures in first maxTextures locations to array\n * sets actual _batchLocation for them\n *\n * @param arr - arr copy destination\n * @param maxTextures - number of copied elements\n */\n BatchSystem.prototype.copyBoundTextures = function (arr, maxTextures) {\n var boundTextures = this.renderer.texture.boundTextures;\n for (var i = maxTextures - 1; i >= 0; --i) {\n arr[i] = boundTextures[i] || null;\n if (arr[i]) {\n arr[i]._batchLocation = i;\n }\n }\n };\n /**\n * Assigns batch locations to textures in array based on boundTextures state.\n * All textures in texArray should have `_batchEnabled = _batchId`,\n * and their count should be less than `maxTextures`.\n *\n * @param texArray - textures to bound\n * @param boundTextures - current state of bound textures\n * @param batchId - marker for _batchEnabled param of textures in texArray\n * @param maxTextures - number of texture locations to manipulate\n */\n BatchSystem.prototype.boundArray = function (texArray, boundTextures, batchId, maxTextures) {\n var elements = texArray.elements, ids = texArray.ids, count = texArray.count;\n var j = 0;\n for (var i = 0; i < count; i++) {\n var tex = elements[i];\n var loc = tex._batchLocation;\n if (loc >= 0 && loc < maxTextures\n && boundTextures[loc] === tex) {\n ids[i] = loc;\n continue;\n }\n while (j < maxTextures) {\n var bound = boundTextures[j];\n if (bound && bound._batchEnabled === batchId\n && bound._batchLocation === j) {\n j++;\n continue;\n }\n ids[i] = j;\n tex._batchLocation = j;\n boundTextures[j] = tex;\n break;\n }\n }\n };\n /**\n * @ignore\n */\n BatchSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return BatchSystem;\n}());\n\nvar CONTEXT_UID_COUNTER = 0;\n/**\n * System plugin to the renderer to manage the context.\n *\n * @memberof PIXI\n */\nvar ContextSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function ContextSystem(renderer) {\n this.renderer = renderer;\n this.webGLVersion = 1;\n this.extensions = {};\n this.supports = {\n uint32Indices: false,\n };\n // Bind functions\n this.handleContextLost = this.handleContextLost.bind(this);\n this.handleContextRestored = this.handleContextRestored.bind(this);\n renderer.view.addEventListener('webglcontextlost', this.handleContextLost, false);\n renderer.view.addEventListener('webglcontextrestored', this.handleContextRestored, false);\n }\n Object.defineProperty(ContextSystem.prototype, \"isLost\", {\n /**\n * `true` if the context is lost\n *\n * @readonly\n */\n get: function () {\n return (!this.gl || this.gl.isContextLost());\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Handles the context change event.\n *\n * @param {WebGLRenderingContext} gl - New WebGL context.\n */\n ContextSystem.prototype.contextChange = function (gl) {\n this.gl = gl;\n this.renderer.gl = gl;\n this.renderer.CONTEXT_UID = CONTEXT_UID_COUNTER++;\n // restore a context if it was previously lost\n if (gl.isContextLost() && gl.getExtension('WEBGL_lose_context')) {\n gl.getExtension('WEBGL_lose_context').restoreContext();\n }\n };\n /**\n * Initializes the context.\n *\n * @protected\n * @param {WebGLRenderingContext} gl - WebGL context\n */\n ContextSystem.prototype.initFromContext = function (gl) {\n this.gl = gl;\n this.validateContext(gl);\n this.renderer.gl = gl;\n this.renderer.CONTEXT_UID = CONTEXT_UID_COUNTER++;\n this.renderer.runners.contextChange.emit(gl);\n };\n /**\n * Initialize from context options\n *\n * @protected\n * @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/getContext\n * @param {object} options - context attributes\n */\n ContextSystem.prototype.initFromOptions = function (options) {\n var gl = this.createContext(this.renderer.view, options);\n this.initFromContext(gl);\n };\n /**\n * Helper class to create a WebGL Context\n *\n * @param canvas - the canvas element that we will get the context from\n * @param options - An options object that gets passed in to the canvas element containing the\n * context attributes\n * @see https://developer.mozilla.org/en/docs/Web/API/HTMLCanvasElement/getContext\n * @return {WebGLRenderingContext} the WebGL context\n */\n ContextSystem.prototype.createContext = function (canvas, options) {\n var gl;\n if (settings.PREFER_ENV >= ENV.WEBGL2) {\n gl = canvas.getContext('webgl2', options);\n }\n if (gl) {\n this.webGLVersion = 2;\n }\n else {\n this.webGLVersion = 1;\n gl = canvas.getContext('webgl', options)\n || canvas.getContext('experimental-webgl', options);\n if (!gl) {\n // fail, not able to get a context\n throw new Error('This browser does not support WebGL. Try using the canvas renderer');\n }\n }\n this.gl = gl;\n this.getExtensions();\n return this.gl;\n };\n /** Auto-populate the {@link PIXI.ContextSystem.extensions extensions}. */\n ContextSystem.prototype.getExtensions = function () {\n // time to set up default extensions that Pixi uses.\n var gl = this.gl;\n var common = {\n anisotropicFiltering: gl.getExtension('EXT_texture_filter_anisotropic'),\n floatTextureLinear: gl.getExtension('OES_texture_float_linear'),\n s3tc: gl.getExtension('WEBGL_compressed_texture_s3tc'),\n s3tc_sRGB: gl.getExtension('WEBGL_compressed_texture_s3tc_srgb'),\n etc: gl.getExtension('WEBGL_compressed_texture_etc'),\n etc1: gl.getExtension('WEBGL_compressed_texture_etc1'),\n pvrtc: gl.getExtension('WEBGL_compressed_texture_pvrtc')\n || gl.getExtension('WEBKIT_WEBGL_compressed_texture_pvrtc'),\n atc: gl.getExtension('WEBGL_compressed_texture_atc'),\n astc: gl.getExtension('WEBGL_compressed_texture_astc')\n };\n if (this.webGLVersion === 1) {\n Object.assign(this.extensions, common, {\n drawBuffers: gl.getExtension('WEBGL_draw_buffers'),\n depthTexture: gl.getExtension('WEBGL_depth_texture'),\n loseContext: gl.getExtension('WEBGL_lose_context'),\n vertexArrayObject: gl.getExtension('OES_vertex_array_object')\n || gl.getExtension('MOZ_OES_vertex_array_object')\n || gl.getExtension('WEBKIT_OES_vertex_array_object'),\n uint32ElementIndex: gl.getExtension('OES_element_index_uint'),\n // Floats and half-floats\n floatTexture: gl.getExtension('OES_texture_float'),\n floatTextureLinear: gl.getExtension('OES_texture_float_linear'),\n textureHalfFloat: gl.getExtension('OES_texture_half_float'),\n textureHalfFloatLinear: gl.getExtension('OES_texture_half_float_linear'),\n });\n }\n else if (this.webGLVersion === 2) {\n Object.assign(this.extensions, common, {\n // Floats and half-floats\n colorBufferFloat: gl.getExtension('EXT_color_buffer_float')\n });\n }\n };\n /**\n * Handles a lost webgl context\n *\n * @param {WebGLContextEvent} event - The context lost event.\n */\n ContextSystem.prototype.handleContextLost = function (event) {\n event.preventDefault();\n };\n /** Handles a restored webgl context. */\n ContextSystem.prototype.handleContextRestored = function () {\n this.renderer.runners.contextChange.emit(this.gl);\n };\n ContextSystem.prototype.destroy = function () {\n var view = this.renderer.view;\n this.renderer = null;\n // remove listeners\n view.removeEventListener('webglcontextlost', this.handleContextLost);\n view.removeEventListener('webglcontextrestored', this.handleContextRestored);\n this.gl.useProgram(null);\n if (this.extensions.loseContext) {\n this.extensions.loseContext.loseContext();\n }\n };\n /** Handle the post-render runner event. */\n ContextSystem.prototype.postrender = function () {\n if (this.renderer.renderingToScreen) {\n this.gl.flush();\n }\n };\n /**\n * Validate context.\n *\n * @param {WebGLRenderingContext} gl - Render context.\n */\n ContextSystem.prototype.validateContext = function (gl) {\n var attributes = gl.getContextAttributes();\n var isWebGl2 = 'WebGL2RenderingContext' in globalThis && gl instanceof globalThis.WebGL2RenderingContext;\n if (isWebGl2) {\n this.webGLVersion = 2;\n }\n // this is going to be fairly simple for now.. but at least we have room to grow!\n if (!attributes.stencil) {\n /* eslint-disable max-len, no-console */\n console.warn('Provided WebGL context does not have a stencil buffer, masks may not render correctly');\n /* eslint-enable max-len, no-console */\n }\n var hasuint32 = isWebGl2 || !!gl.getExtension('OES_element_index_uint');\n this.supports.uint32Indices = hasuint32;\n if (!hasuint32) {\n /* eslint-disable max-len, no-console */\n console.warn('Provided WebGL context does not support 32 index buffer, complex graphics may not render correctly');\n /* eslint-enable max-len, no-console */\n }\n };\n return ContextSystem;\n}());\n\n/**\n * Internal framebuffer for WebGL context.\n *\n * @memberof PIXI\n */\nvar GLFramebuffer = /** @class */ (function () {\n function GLFramebuffer(framebuffer) {\n this.framebuffer = framebuffer;\n this.stencil = null;\n this.dirtyId = -1;\n this.dirtyFormat = -1;\n this.dirtySize = -1;\n this.multisample = MSAA_QUALITY.NONE;\n this.msaaBuffer = null;\n this.blitFramebuffer = null;\n this.mipLevel = 0;\n }\n return GLFramebuffer;\n}());\n\nvar tempRectangle = new Rectangle();\n/**\n * System plugin to the renderer to manage framebuffers.\n *\n * @memberof PIXI\n */\nvar FramebufferSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function FramebufferSystem(renderer) {\n this.renderer = renderer;\n this.managedFramebuffers = [];\n this.unknownFramebuffer = new Framebuffer(10, 10);\n this.msaaSamples = null;\n }\n /** Sets up the renderer context and necessary buffers. */\n FramebufferSystem.prototype.contextChange = function () {\n var gl = this.gl = this.renderer.gl;\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n this.current = this.unknownFramebuffer;\n this.viewport = new Rectangle();\n this.hasMRT = true;\n this.writeDepthTexture = true;\n this.disposeAll(true);\n // webgl2\n if (this.renderer.context.webGLVersion === 1) {\n // webgl 1!\n var nativeDrawBuffersExtension_1 = this.renderer.context.extensions.drawBuffers;\n var nativeDepthTextureExtension = this.renderer.context.extensions.depthTexture;\n if (settings.PREFER_ENV === ENV.WEBGL_LEGACY) {\n nativeDrawBuffersExtension_1 = null;\n nativeDepthTextureExtension = null;\n }\n if (nativeDrawBuffersExtension_1) {\n gl.drawBuffers = function (activeTextures) {\n return nativeDrawBuffersExtension_1.drawBuffersWEBGL(activeTextures);\n };\n }\n else {\n this.hasMRT = false;\n gl.drawBuffers = function () {\n // empty\n };\n }\n if (!nativeDepthTextureExtension) {\n this.writeDepthTexture = false;\n }\n }\n else {\n // WebGL2\n // cache possible MSAA samples\n this.msaaSamples = gl.getInternalformatParameter(gl.RENDERBUFFER, gl.RGBA8, gl.SAMPLES);\n }\n };\n /**\n * Bind a framebuffer.\n *\n * @param framebuffer\n * @param frame - frame, default is framebuffer size\n * @param mipLevel - optional mip level to set on the framebuffer - defaults to 0\n */\n FramebufferSystem.prototype.bind = function (framebuffer, frame, mipLevel) {\n if (mipLevel === void 0) { mipLevel = 0; }\n var gl = this.gl;\n if (framebuffer) {\n // TODO caching layer!\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID] || this.initFramebuffer(framebuffer);\n if (this.current !== framebuffer) {\n this.current = framebuffer;\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo.framebuffer);\n }\n // make sure all textures are unbound..\n if (fbo.mipLevel !== mipLevel) {\n framebuffer.dirtyId++;\n framebuffer.dirtyFormat++;\n fbo.mipLevel = mipLevel;\n }\n // now check for updates...\n if (fbo.dirtyId !== framebuffer.dirtyId) {\n fbo.dirtyId = framebuffer.dirtyId;\n if (fbo.dirtyFormat !== framebuffer.dirtyFormat) {\n fbo.dirtyFormat = framebuffer.dirtyFormat;\n fbo.dirtySize = framebuffer.dirtySize;\n this.updateFramebuffer(framebuffer, mipLevel);\n }\n else if (fbo.dirtySize !== framebuffer.dirtySize) {\n fbo.dirtySize = framebuffer.dirtySize;\n this.resizeFramebuffer(framebuffer);\n }\n }\n for (var i = 0; i < framebuffer.colorTextures.length; i++) {\n var tex = framebuffer.colorTextures[i];\n this.renderer.texture.unbind(tex.parentTextureArray || tex);\n }\n if (framebuffer.depthTexture) {\n this.renderer.texture.unbind(framebuffer.depthTexture);\n }\n if (frame) {\n var mipWidth = (frame.width >> mipLevel);\n var mipHeight = (frame.height >> mipLevel);\n var scale = mipWidth / frame.width;\n this.setViewport(frame.x * scale, frame.y * scale, mipWidth, mipHeight);\n }\n else {\n var mipWidth = (framebuffer.width >> mipLevel);\n var mipHeight = (framebuffer.height >> mipLevel);\n this.setViewport(0, 0, mipWidth, mipHeight);\n }\n }\n else {\n if (this.current) {\n this.current = null;\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n }\n if (frame) {\n this.setViewport(frame.x, frame.y, frame.width, frame.height);\n }\n else {\n this.setViewport(0, 0, this.renderer.width, this.renderer.height);\n }\n }\n };\n /**\n * Set the WebGLRenderingContext's viewport.\n *\n * @param x - X position of viewport\n * @param y - Y position of viewport\n * @param width - Width of viewport\n * @param height - Height of viewport\n */\n FramebufferSystem.prototype.setViewport = function (x, y, width, height) {\n var v = this.viewport;\n x = Math.round(x);\n y = Math.round(y);\n width = Math.round(width);\n height = Math.round(height);\n if (v.width !== width || v.height !== height || v.x !== x || v.y !== y) {\n v.x = x;\n v.y = y;\n v.width = width;\n v.height = height;\n this.gl.viewport(x, y, width, height);\n }\n };\n Object.defineProperty(FramebufferSystem.prototype, \"size\", {\n /**\n * Get the size of the current width and height. Returns object with `width` and `height` values.\n *\n * @readonly\n */\n get: function () {\n if (this.current) {\n // TODO store temp\n return { x: 0, y: 0, width: this.current.width, height: this.current.height };\n }\n return { x: 0, y: 0, width: this.renderer.width, height: this.renderer.height };\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Clear the color of the context\n *\n * @param r - Red value from 0 to 1\n * @param g - Green value from 0 to 1\n * @param b - Blue value from 0 to 1\n * @param a - Alpha value from 0 to 1\n * @param {PIXI.BUFFER_BITS} [mask=BUFFER_BITS.COLOR | BUFFER_BITS.DEPTH] - Bitwise OR of masks\n * that indicate the buffers to be cleared, by default COLOR and DEPTH buffers.\n */\n FramebufferSystem.prototype.clear = function (r, g, b, a, mask) {\n if (mask === void 0) { mask = BUFFER_BITS.COLOR | BUFFER_BITS.DEPTH; }\n var gl = this.gl;\n // TODO clear color can be set only one right?\n gl.clearColor(r, g, b, a);\n gl.clear(mask);\n };\n /**\n * Initialize framebuffer for this context\n *\n * @protected\n * @param framebuffer\n * @returns - created GLFramebuffer\n */\n FramebufferSystem.prototype.initFramebuffer = function (framebuffer) {\n var gl = this.gl;\n var fbo = new GLFramebuffer(gl.createFramebuffer());\n fbo.multisample = this.detectSamples(framebuffer.multisample);\n framebuffer.glFramebuffers[this.CONTEXT_UID] = fbo;\n this.managedFramebuffers.push(framebuffer);\n framebuffer.disposeRunner.add(this);\n return fbo;\n };\n /**\n * Resize the framebuffer\n *\n * @protected\n */\n FramebufferSystem.prototype.resizeFramebuffer = function (framebuffer) {\n var gl = this.gl;\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n if (fbo.msaaBuffer) {\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.msaaBuffer);\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.RGBA8, framebuffer.width, framebuffer.height);\n }\n if (fbo.stencil) {\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.stencil);\n if (fbo.msaaBuffer) {\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.DEPTH24_STENCIL8, framebuffer.width, framebuffer.height);\n }\n else {\n gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_STENCIL, framebuffer.width, framebuffer.height);\n }\n }\n var colorTextures = framebuffer.colorTextures;\n var count = colorTextures.length;\n if (!gl.drawBuffers) {\n count = Math.min(count, 1);\n }\n for (var i = 0; i < count; i++) {\n var texture = colorTextures[i];\n var parentTexture = texture.parentTextureArray || texture;\n this.renderer.texture.bind(parentTexture, 0);\n }\n if (framebuffer.depthTexture && this.writeDepthTexture) {\n this.renderer.texture.bind(framebuffer.depthTexture, 0);\n }\n };\n /**\n * Update the framebuffer\n *\n * @protected\n */\n FramebufferSystem.prototype.updateFramebuffer = function (framebuffer, mipLevel) {\n var gl = this.gl;\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n // bind the color texture\n var colorTextures = framebuffer.colorTextures;\n var count = colorTextures.length;\n if (!gl.drawBuffers) {\n count = Math.min(count, 1);\n }\n if (fbo.multisample > 1 && this.canMultisampleFramebuffer(framebuffer)) {\n fbo.msaaBuffer = fbo.msaaBuffer || gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.msaaBuffer);\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.RGBA8, framebuffer.width, framebuffer.height);\n gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.RENDERBUFFER, fbo.msaaBuffer);\n }\n else if (fbo.msaaBuffer) {\n gl.deleteRenderbuffer(fbo.msaaBuffer);\n fbo.msaaBuffer = null;\n if (fbo.blitFramebuffer) {\n fbo.blitFramebuffer.dispose();\n fbo.blitFramebuffer = null;\n }\n }\n var activeTextures = [];\n for (var i = 0; i < count; i++) {\n var texture = colorTextures[i];\n var parentTexture = texture.parentTextureArray || texture;\n this.renderer.texture.bind(parentTexture, 0);\n if (i === 0 && fbo.msaaBuffer) {\n continue;\n }\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + i, texture.target, parentTexture._glTextures[this.CONTEXT_UID].texture, mipLevel);\n activeTextures.push(gl.COLOR_ATTACHMENT0 + i);\n }\n if (activeTextures.length > 1) {\n gl.drawBuffers(activeTextures);\n }\n if (framebuffer.depthTexture) {\n var writeDepthTexture = this.writeDepthTexture;\n if (writeDepthTexture) {\n var depthTexture = framebuffer.depthTexture;\n this.renderer.texture.bind(depthTexture, 0);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.TEXTURE_2D, depthTexture._glTextures[this.CONTEXT_UID].texture, mipLevel);\n }\n }\n if ((framebuffer.stencil || framebuffer.depth) && !(framebuffer.depthTexture && this.writeDepthTexture)) {\n fbo.stencil = fbo.stencil || gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.stencil);\n if (fbo.msaaBuffer) {\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.DEPTH24_STENCIL8, framebuffer.width, framebuffer.height);\n }\n else {\n gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_STENCIL, framebuffer.width, framebuffer.height);\n }\n gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.RENDERBUFFER, fbo.stencil);\n }\n else if (fbo.stencil) {\n gl.deleteRenderbuffer(fbo.stencil);\n fbo.stencil = null;\n }\n };\n /** Returns true if the frame buffer can be multisampled. */\n FramebufferSystem.prototype.canMultisampleFramebuffer = function (framebuffer) {\n return this.renderer.context.webGLVersion !== 1\n && framebuffer.colorTextures.length <= 1 && !framebuffer.depthTexture;\n };\n /**\n * Detects number of samples that is not more than a param but as close to it as possible\n *\n * @param samples - number of samples\n * @returns - recommended number of samples\n */\n FramebufferSystem.prototype.detectSamples = function (samples) {\n var msaaSamples = this.msaaSamples;\n var res = MSAA_QUALITY.NONE;\n if (samples <= 1 || msaaSamples === null) {\n return res;\n }\n for (var i = 0; i < msaaSamples.length; i++) {\n if (msaaSamples[i] <= samples) {\n res = msaaSamples[i];\n break;\n }\n }\n if (res === 1) {\n res = MSAA_QUALITY.NONE;\n }\n return res;\n };\n /**\n * Only works with WebGL2\n *\n * blits framebuffer to another of the same or bigger size\n * after that target framebuffer is bound\n *\n * Fails with WebGL warning if blits multisample framebuffer to different size\n *\n * @param framebuffer - by default it blits \"into itself\", from renderBuffer to texture.\n * @param sourcePixels - source rectangle in pixels\n * @param destPixels - dest rectangle in pixels, assumed to be the same as sourcePixels\n */\n FramebufferSystem.prototype.blit = function (framebuffer, sourcePixels, destPixels) {\n var _a = this, current = _a.current, renderer = _a.renderer, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n if (renderer.context.webGLVersion !== 2) {\n return;\n }\n if (!current) {\n return;\n }\n var fbo = current.glFramebuffers[CONTEXT_UID];\n if (!fbo) {\n return;\n }\n if (!framebuffer) {\n if (!fbo.msaaBuffer) {\n return;\n }\n var colorTexture = current.colorTextures[0];\n if (!colorTexture) {\n return;\n }\n if (!fbo.blitFramebuffer) {\n fbo.blitFramebuffer = new Framebuffer(current.width, current.height);\n fbo.blitFramebuffer.addColorTexture(0, colorTexture);\n }\n framebuffer = fbo.blitFramebuffer;\n if (framebuffer.colorTextures[0] !== colorTexture) {\n framebuffer.colorTextures[0] = colorTexture;\n framebuffer.dirtyId++;\n framebuffer.dirtyFormat++;\n }\n if (framebuffer.width !== current.width || framebuffer.height !== current.height) {\n framebuffer.width = current.width;\n framebuffer.height = current.height;\n framebuffer.dirtyId++;\n framebuffer.dirtySize++;\n }\n }\n if (!sourcePixels) {\n sourcePixels = tempRectangle;\n sourcePixels.width = current.width;\n sourcePixels.height = current.height;\n }\n if (!destPixels) {\n destPixels = sourcePixels;\n }\n var sameSize = sourcePixels.width === destPixels.width && sourcePixels.height === destPixels.height;\n this.bind(framebuffer);\n gl.bindFramebuffer(gl.READ_FRAMEBUFFER, fbo.framebuffer);\n gl.blitFramebuffer(sourcePixels.left, sourcePixels.top, sourcePixels.right, sourcePixels.bottom, destPixels.left, destPixels.top, destPixels.right, destPixels.bottom, gl.COLOR_BUFFER_BIT, sameSize ? gl.NEAREST : gl.LINEAR);\n };\n /**\n * Disposes framebuffer.\n *\n * @param framebuffer - framebuffer that has to be disposed of\n * @param contextLost - If context was lost, we suppress all delete function calls\n */\n FramebufferSystem.prototype.disposeFramebuffer = function (framebuffer, contextLost) {\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n var gl = this.gl;\n if (!fbo) {\n return;\n }\n delete framebuffer.glFramebuffers[this.CONTEXT_UID];\n var index = this.managedFramebuffers.indexOf(framebuffer);\n if (index >= 0) {\n this.managedFramebuffers.splice(index, 1);\n }\n framebuffer.disposeRunner.remove(this);\n if (!contextLost) {\n gl.deleteFramebuffer(fbo.framebuffer);\n if (fbo.msaaBuffer) {\n gl.deleteRenderbuffer(fbo.msaaBuffer);\n }\n if (fbo.stencil) {\n gl.deleteRenderbuffer(fbo.stencil);\n }\n }\n if (fbo.blitFramebuffer) {\n fbo.blitFramebuffer.dispose();\n }\n };\n /**\n * Disposes all framebuffers, but not textures bound to them.\n *\n * @param [contextLost=false] - If context was lost, we suppress all delete function calls\n */\n FramebufferSystem.prototype.disposeAll = function (contextLost) {\n var list = this.managedFramebuffers;\n this.managedFramebuffers = [];\n for (var i = 0; i < list.length; i++) {\n this.disposeFramebuffer(list[i], contextLost);\n }\n };\n /**\n * Forcing creation of stencil buffer for current framebuffer, if it wasn't done before.\n * Used by MaskSystem, when its time to use stencil mask for Graphics element.\n *\n * Its an alternative for public lazy `framebuffer.enableStencil`, in case we need stencil without rebind.\n *\n * @private\n */\n FramebufferSystem.prototype.forceStencil = function () {\n var framebuffer = this.current;\n if (!framebuffer) {\n return;\n }\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n if (!fbo || fbo.stencil) {\n return;\n }\n framebuffer.stencil = true;\n var w = framebuffer.width;\n var h = framebuffer.height;\n var gl = this.gl;\n var stencil = gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, stencil);\n if (fbo.msaaBuffer) {\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.DEPTH24_STENCIL8, w, h);\n }\n else {\n gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_STENCIL, w, h);\n }\n fbo.stencil = stencil;\n gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.RENDERBUFFER, stencil);\n };\n /**\n * Resets framebuffer stored state, binds screen framebuffer.\n *\n * Should be called before renderTexture reset().\n */\n FramebufferSystem.prototype.reset = function () {\n this.current = this.unknownFramebuffer;\n this.viewport = new Rectangle();\n };\n FramebufferSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return FramebufferSystem;\n}());\n\nvar byteSizeMap$1 = { 5126: 4, 5123: 2, 5121: 1 };\n/**\n * System plugin to the renderer to manage geometry.\n *\n * @memberof PIXI\n */\nvar GeometrySystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function GeometrySystem(renderer) {\n this.renderer = renderer;\n this._activeGeometry = null;\n this._activeVao = null;\n this.hasVao = true;\n this.hasInstance = true;\n this.canUseUInt32ElementIndex = false;\n this.managedGeometries = {};\n }\n /** Sets up the renderer context and necessary buffers. */\n GeometrySystem.prototype.contextChange = function () {\n this.disposeAll(true);\n var gl = this.gl = this.renderer.gl;\n var context = this.renderer.context;\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n // webgl2\n if (context.webGLVersion !== 2) {\n // webgl 1!\n var nativeVaoExtension_1 = this.renderer.context.extensions.vertexArrayObject;\n if (settings.PREFER_ENV === ENV.WEBGL_LEGACY) {\n nativeVaoExtension_1 = null;\n }\n if (nativeVaoExtension_1) {\n gl.createVertexArray = function () {\n return nativeVaoExtension_1.createVertexArrayOES();\n };\n gl.bindVertexArray = function (vao) {\n return nativeVaoExtension_1.bindVertexArrayOES(vao);\n };\n gl.deleteVertexArray = function (vao) {\n return nativeVaoExtension_1.deleteVertexArrayOES(vao);\n };\n }\n else {\n this.hasVao = false;\n gl.createVertexArray = function () {\n return null;\n };\n gl.bindVertexArray = function () {\n return null;\n };\n gl.deleteVertexArray = function () {\n return null;\n };\n }\n }\n if (context.webGLVersion !== 2) {\n var instanceExt_1 = gl.getExtension('ANGLE_instanced_arrays');\n if (instanceExt_1) {\n gl.vertexAttribDivisor = function (a, b) {\n return instanceExt_1.vertexAttribDivisorANGLE(a, b);\n };\n gl.drawElementsInstanced = function (a, b, c, d, e) {\n return instanceExt_1.drawElementsInstancedANGLE(a, b, c, d, e);\n };\n gl.drawArraysInstanced = function (a, b, c, d) {\n return instanceExt_1.drawArraysInstancedANGLE(a, b, c, d);\n };\n }\n else {\n this.hasInstance = false;\n }\n }\n this.canUseUInt32ElementIndex = context.webGLVersion === 2 || !!context.extensions.uint32ElementIndex;\n };\n /**\n * Binds geometry so that is can be drawn. Creating a Vao if required\n *\n * @param geometry - Instance of geometry to bind.\n * @param shader - Instance of shader to use vao for.\n */\n GeometrySystem.prototype.bind = function (geometry, shader) {\n shader = shader || this.renderer.shader.shader;\n var gl = this.gl;\n // not sure the best way to address this..\n // currently different shaders require different VAOs for the same geometry\n // Still mulling over the best way to solve this one..\n // will likely need to modify the shader attribute locations at run time!\n var vaos = geometry.glVertexArrayObjects[this.CONTEXT_UID];\n var incRefCount = false;\n if (!vaos) {\n this.managedGeometries[geometry.id] = geometry;\n geometry.disposeRunner.add(this);\n geometry.glVertexArrayObjects[this.CONTEXT_UID] = vaos = {};\n incRefCount = true;\n }\n var vao = vaos[shader.program.id] || this.initGeometryVao(geometry, shader, incRefCount);\n this._activeGeometry = geometry;\n if (this._activeVao !== vao) {\n this._activeVao = vao;\n if (this.hasVao) {\n gl.bindVertexArray(vao);\n }\n else {\n this.activateVao(geometry, shader.program);\n }\n }\n // TODO - optimise later!\n // don't need to loop through if nothing changed!\n // maybe look to add an 'autoupdate' to geometry?\n this.updateBuffers();\n };\n /** Reset and unbind any active VAO and geometry. */\n GeometrySystem.prototype.reset = function () {\n this.unbind();\n };\n /** Update buffers of the currently bound geometry. */\n GeometrySystem.prototype.updateBuffers = function () {\n var geometry = this._activeGeometry;\n var bufferSystem = this.renderer.buffer;\n for (var i = 0; i < geometry.buffers.length; i++) {\n var buffer = geometry.buffers[i];\n bufferSystem.update(buffer);\n }\n };\n /**\n * Check compatibility between a geometry and a program\n *\n * @param geometry - Geometry instance.\n * @param program - Program instance.\n */\n GeometrySystem.prototype.checkCompatibility = function (geometry, program) {\n // geometry must have at least all the attributes that the shader requires.\n var geometryAttributes = geometry.attributes;\n var shaderAttributes = program.attributeData;\n for (var j in shaderAttributes) {\n if (!geometryAttributes[j]) {\n throw new Error(\"shader and geometry incompatible, geometry missing the \\\"\" + j + \"\\\" attribute\");\n }\n }\n };\n /**\n * Takes a geometry and program and generates a unique signature for them.\n *\n * @param geometry - To get signature from.\n * @param program - To test geometry against.\n * @return - Unique signature of the geometry and program\n */\n GeometrySystem.prototype.getSignature = function (geometry, program) {\n var attribs = geometry.attributes;\n var shaderAttributes = program.attributeData;\n var strings = ['g', geometry.id];\n for (var i in attribs) {\n if (shaderAttributes[i]) {\n strings.push(i, shaderAttributes[i].location);\n }\n }\n return strings.join('-');\n };\n /**\n * Creates or gets Vao with the same structure as the geometry and stores it on the geometry.\n * If vao is created, it is bound automatically. We use a shader to infer what and how to set up the\n * attribute locations.\n *\n * @param geometry - Instance of geometry to to generate Vao for.\n * @param shader - Instance of the shader.\n * @param incRefCount - Increment refCount of all geometry buffers.\n */\n GeometrySystem.prototype.initGeometryVao = function (geometry, shader, incRefCount) {\n if (incRefCount === void 0) { incRefCount = true; }\n var gl = this.gl;\n var CONTEXT_UID = this.CONTEXT_UID;\n var bufferSystem = this.renderer.buffer;\n var program = shader.program;\n if (!program.glPrograms[CONTEXT_UID]) {\n this.renderer.shader.generateProgram(shader);\n }\n this.checkCompatibility(geometry, program);\n var signature = this.getSignature(geometry, program);\n var vaoObjectHash = geometry.glVertexArrayObjects[this.CONTEXT_UID];\n var vao = vaoObjectHash[signature];\n if (vao) {\n // this will give us easy access to the vao\n vaoObjectHash[program.id] = vao;\n return vao;\n }\n var buffers = geometry.buffers;\n var attributes = geometry.attributes;\n var tempStride = {};\n var tempStart = {};\n for (var j in buffers) {\n tempStride[j] = 0;\n tempStart[j] = 0;\n }\n for (var j in attributes) {\n if (!attributes[j].size && program.attributeData[j]) {\n attributes[j].size = program.attributeData[j].size;\n }\n else if (!attributes[j].size) {\n console.warn(\"PIXI Geometry attribute '\" + j + \"' size cannot be determined (likely the bound shader does not have the attribute)\"); // eslint-disable-line\n }\n tempStride[attributes[j].buffer] += attributes[j].size * byteSizeMap$1[attributes[j].type];\n }\n for (var j in attributes) {\n var attribute = attributes[j];\n var attribSize = attribute.size;\n if (attribute.stride === undefined) {\n if (tempStride[attribute.buffer] === attribSize * byteSizeMap$1[attribute.type]) {\n attribute.stride = 0;\n }\n else {\n attribute.stride = tempStride[attribute.buffer];\n }\n }\n if (attribute.start === undefined) {\n attribute.start = tempStart[attribute.buffer];\n tempStart[attribute.buffer] += attribSize * byteSizeMap$1[attribute.type];\n }\n }\n vao = gl.createVertexArray();\n gl.bindVertexArray(vao);\n // first update - and create the buffers!\n // only create a gl buffer if it actually gets\n for (var i = 0; i < buffers.length; i++) {\n var buffer = buffers[i];\n bufferSystem.bind(buffer);\n if (incRefCount) {\n buffer._glBuffers[CONTEXT_UID].refCount++;\n }\n }\n // TODO - maybe make this a data object?\n // lets wait to see if we need to first!\n this.activateVao(geometry, program);\n this._activeVao = vao;\n // add it to the cache!\n vaoObjectHash[program.id] = vao;\n vaoObjectHash[signature] = vao;\n return vao;\n };\n /**\n * Disposes geometry.\n *\n * @param geometry - Geometry with buffers. Only VAO will be disposed\n * @param [contextLost=false] - If context was lost, we suppress deleteVertexArray\n */\n GeometrySystem.prototype.disposeGeometry = function (geometry, contextLost) {\n var _a;\n if (!this.managedGeometries[geometry.id]) {\n return;\n }\n delete this.managedGeometries[geometry.id];\n var vaos = geometry.glVertexArrayObjects[this.CONTEXT_UID];\n var gl = this.gl;\n var buffers = geometry.buffers;\n var bufferSystem = (_a = this.renderer) === null || _a === void 0 ? void 0 : _a.buffer;\n geometry.disposeRunner.remove(this);\n if (!vaos) {\n return;\n }\n // bufferSystem may have already been destroyed..\n // if this is the case, there is no need to destroy the geometry buffers...\n // they already have been!\n if (bufferSystem) {\n for (var i = 0; i < buffers.length; i++) {\n var buf = buffers[i]._glBuffers[this.CONTEXT_UID];\n // my be null as context may have changed right before the dispose is called\n if (buf) {\n buf.refCount--;\n if (buf.refCount === 0 && !contextLost) {\n bufferSystem.dispose(buffers[i], contextLost);\n }\n }\n }\n }\n if (!contextLost) {\n for (var vaoId in vaos) {\n // delete only signatures, everything else are copies\n if (vaoId[0] === 'g') {\n var vao = vaos[vaoId];\n if (this._activeVao === vao) {\n this.unbind();\n }\n gl.deleteVertexArray(vao);\n }\n }\n }\n delete geometry.glVertexArrayObjects[this.CONTEXT_UID];\n };\n /**\n * Dispose all WebGL resources of all managed geometries.\n *\n * @param [contextLost=false] - If context was lost, we suppress `gl.delete` calls\n */\n GeometrySystem.prototype.disposeAll = function (contextLost) {\n var all = Object.keys(this.managedGeometries);\n for (var i = 0; i < all.length; i++) {\n this.disposeGeometry(this.managedGeometries[all[i]], contextLost);\n }\n };\n /**\n * Activate vertex array object.\n *\n * @param geometry - Geometry instance.\n * @param program - Shader program instance.\n */\n GeometrySystem.prototype.activateVao = function (geometry, program) {\n var gl = this.gl;\n var CONTEXT_UID = this.CONTEXT_UID;\n var bufferSystem = this.renderer.buffer;\n var buffers = geometry.buffers;\n var attributes = geometry.attributes;\n if (geometry.indexBuffer) {\n // first update the index buffer if we have one..\n bufferSystem.bind(geometry.indexBuffer);\n }\n var lastBuffer = null;\n // add a new one!\n for (var j in attributes) {\n var attribute = attributes[j];\n var buffer = buffers[attribute.buffer];\n var glBuffer = buffer._glBuffers[CONTEXT_UID];\n if (program.attributeData[j]) {\n if (lastBuffer !== glBuffer) {\n bufferSystem.bind(buffer);\n lastBuffer = glBuffer;\n }\n var location = program.attributeData[j].location;\n // TODO introduce state again\n // we can optimise this for older devices that have no VAOs\n gl.enableVertexAttribArray(location);\n gl.vertexAttribPointer(location, attribute.size, attribute.type || gl.FLOAT, attribute.normalized, attribute.stride, attribute.start);\n if (attribute.instance) {\n // TODO calculate instance count based of this...\n if (this.hasInstance) {\n gl.vertexAttribDivisor(location, 1);\n }\n else {\n throw new Error('geometry error, GPU Instancing is not supported on this device');\n }\n }\n }\n }\n };\n /**\n * Draws the currently bound geometry.\n *\n * @param type - The type primitive to render.\n * @param size - The number of elements to be rendered. If not specified, all vertices after the\n * starting vertex will be drawn.\n * @param start - The starting vertex in the geometry to start drawing from. If not specified,\n * drawing will start from the first vertex.\n * @param instanceCount - The number of instances of the set of elements to execute. If not specified,\n * all instances will be drawn.\n */\n GeometrySystem.prototype.draw = function (type, size, start, instanceCount) {\n var gl = this.gl;\n var geometry = this._activeGeometry;\n // TODO.. this should not change so maybe cache the function?\n if (geometry.indexBuffer) {\n var byteSize = geometry.indexBuffer.data.BYTES_PER_ELEMENT;\n var glType = byteSize === 2 ? gl.UNSIGNED_SHORT : gl.UNSIGNED_INT;\n if (byteSize === 2 || (byteSize === 4 && this.canUseUInt32ElementIndex)) {\n if (geometry.instanced) {\n /* eslint-disable max-len */\n gl.drawElementsInstanced(type, size || geometry.indexBuffer.data.length, glType, (start || 0) * byteSize, instanceCount || 1);\n /* eslint-enable max-len */\n }\n else {\n /* eslint-disable max-len */\n gl.drawElements(type, size || geometry.indexBuffer.data.length, glType, (start || 0) * byteSize);\n /* eslint-enable max-len */\n }\n }\n else {\n console.warn('unsupported index buffer type: uint32');\n }\n }\n else if (geometry.instanced) {\n // TODO need a better way to calculate size..\n gl.drawArraysInstanced(type, start, size || geometry.getSize(), instanceCount || 1);\n }\n else {\n gl.drawArrays(type, start, size || geometry.getSize());\n }\n return this;\n };\n /** Unbind/reset everything. */\n GeometrySystem.prototype.unbind = function () {\n this.gl.bindVertexArray(null);\n this._activeVao = null;\n this._activeGeometry = null;\n };\n GeometrySystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return GeometrySystem;\n}());\n\n/**\n * Component for masked elements.\n *\n * Holds mask mode and temporary data about current mask.\n *\n * @memberof PIXI\n */\nvar MaskData = /** @class */ (function () {\n /**\n * Create MaskData\n *\n * @param {PIXI.DisplayObject} [maskObject=null] - object that describes the mask\n */\n function MaskData(maskObject) {\n if (maskObject === void 0) { maskObject = null; }\n this.type = MASK_TYPES.NONE;\n this.autoDetect = true;\n this.maskObject = maskObject || null;\n this.pooled = false;\n this.isMaskData = true;\n this.resolution = null;\n this.multisample = settings.FILTER_MULTISAMPLE;\n this.enabled = true;\n this._filters = null;\n this._stencilCounter = 0;\n this._scissorCounter = 0;\n this._scissorRect = null;\n this._scissorRectLocal = null;\n this._target = null;\n }\n Object.defineProperty(MaskData.prototype, \"filter\", {\n /**\n * The sprite mask filter.\n * If set to `null`, the default sprite mask filter is used.\n * @default null\n */\n get: function () {\n return this._filters ? this._filters[0] : null;\n },\n set: function (value) {\n if (value) {\n if (this._filters) {\n this._filters[0] = value;\n }\n else {\n this._filters = [value];\n }\n }\n else {\n this._filters = null;\n }\n },\n enumerable: false,\n configurable: true\n });\n /** Resets the mask data after popMask(). */\n MaskData.prototype.reset = function () {\n if (this.pooled) {\n this.maskObject = null;\n this.type = MASK_TYPES.NONE;\n this.autoDetect = true;\n }\n this._target = null;\n this._scissorRectLocal = null;\n };\n /** Copies counters from maskData above, called from pushMask(). */\n MaskData.prototype.copyCountersOrReset = function (maskAbove) {\n if (maskAbove) {\n this._stencilCounter = maskAbove._stencilCounter;\n this._scissorCounter = maskAbove._scissorCounter;\n this._scissorRect = maskAbove._scissorRect;\n }\n else {\n this._stencilCounter = 0;\n this._scissorCounter = 0;\n this._scissorRect = null;\n }\n };\n return MaskData;\n}());\n\n/**\n * @private\n * @param {WebGLRenderingContext} gl - The current WebGL context {WebGLProgram}\n * @param {Number} type - the type, can be either VERTEX_SHADER or FRAGMENT_SHADER\n * @param {string} src - The vertex shader source as an array of strings.\n * @return {WebGLShader} the shader\n */\nfunction compileShader(gl, type, src) {\n var shader = gl.createShader(type);\n gl.shaderSource(shader, src);\n gl.compileShader(shader);\n return shader;\n}\n\n/**\n * will log a shader error highlighting the lines with the error\n * also will add numbers along the side.\n *\n * @param gl - the WebGLContext\n * @param shader - the shader to log errors for\n */\nfunction logPrettyShaderError(gl, shader) {\n var shaderSrc = gl.getShaderSource(shader)\n .split('\\n')\n .map(function (line, index) { return index + \": \" + line; });\n var shaderLog = gl.getShaderInfoLog(shader);\n var splitShader = shaderLog.split('\\n');\n var dedupe = {};\n var lineNumbers = splitShader.map(function (line) { return parseFloat(line.replace(/^ERROR\\: 0\\:([\\d]+)\\:.*$/, '$1')); })\n .filter(function (n) {\n if (n && !dedupe[n]) {\n dedupe[n] = true;\n return true;\n }\n return false;\n });\n var logArgs = [''];\n lineNumbers.forEach(function (number) {\n shaderSrc[number - 1] = \"%c\" + shaderSrc[number - 1] + \"%c\";\n logArgs.push('background: #FF0000; color:#FFFFFF; font-size: 10px', 'font-size: 10px');\n });\n var fragmentSourceToLog = shaderSrc\n .join('\\n');\n logArgs[0] = fragmentSourceToLog;\n console.error(shaderLog);\n // eslint-disable-next-line no-console\n console.groupCollapsed('click to view full shader code');\n console.warn.apply(console, logArgs);\n // eslint-disable-next-line no-console\n console.groupEnd();\n}\n/**\n *\n * logs out any program errors\n *\n * @param gl - The current WebGL context\n * @param program - the WebGL program to display errors for\n * @param vertexShader - the fragment WebGL shader program\n * @param fragmentShader - the vertex WebGL shader program\n */\nfunction logProgramError(gl, program, vertexShader, fragmentShader) {\n // if linking fails, then log and cleanup\n if (!gl.getProgramParameter(program, gl.LINK_STATUS)) {\n if (!gl.getShaderParameter(vertexShader, gl.COMPILE_STATUS)) {\n logPrettyShaderError(gl, vertexShader);\n }\n if (!gl.getShaderParameter(fragmentShader, gl.COMPILE_STATUS)) {\n logPrettyShaderError(gl, fragmentShader);\n }\n console.error('PixiJS Error: Could not initialize shader.');\n // if there is a program info log, log it\n if (gl.getProgramInfoLog(program) !== '') {\n console.warn('PixiJS Warning: gl.getProgramInfoLog()', gl.getProgramInfoLog(program));\n }\n }\n}\n\nfunction booleanArray(size) {\n var array = new Array(size);\n for (var i = 0; i < array.length; i++) {\n array[i] = false;\n }\n return array;\n}\n/**\n * @method defaultValue\n * @memberof PIXI.glCore.shader\n * @param {string} type - Type of value\n * @param {number} size\n * @private\n */\nfunction defaultValue(type, size) {\n switch (type) {\n case 'float':\n return 0;\n case 'vec2':\n return new Float32Array(2 * size);\n case 'vec3':\n return new Float32Array(3 * size);\n case 'vec4':\n return new Float32Array(4 * size);\n case 'int':\n case 'uint':\n case 'sampler2D':\n case 'sampler2DArray':\n return 0;\n case 'ivec2':\n return new Int32Array(2 * size);\n case 'ivec3':\n return new Int32Array(3 * size);\n case 'ivec4':\n return new Int32Array(4 * size);\n case 'uvec2':\n return new Uint32Array(2 * size);\n case 'uvec3':\n return new Uint32Array(3 * size);\n case 'uvec4':\n return new Uint32Array(4 * size);\n case 'bool':\n return false;\n case 'bvec2':\n return booleanArray(2 * size);\n case 'bvec3':\n return booleanArray(3 * size);\n case 'bvec4':\n return booleanArray(4 * size);\n case 'mat2':\n return new Float32Array([1, 0,\n 0, 1]);\n case 'mat3':\n return new Float32Array([1, 0, 0,\n 0, 1, 0,\n 0, 0, 1]);\n case 'mat4':\n return new Float32Array([1, 0, 0, 0,\n 0, 1, 0, 0,\n 0, 0, 1, 0,\n 0, 0, 0, 1]);\n }\n return null;\n}\n\nvar unknownContext = {};\nvar context = unknownContext;\n/**\n * returns a little WebGL context to use for program inspection.\n *\n * @static\n * @private\n * @returns {WebGLRenderingContext} a gl context to test with\n */\nfunction getTestContext() {\n if (context === unknownContext || (context && context.isContextLost())) {\n var canvas = document.createElement('canvas');\n var gl = void 0;\n if (settings.PREFER_ENV >= ENV.WEBGL2) {\n gl = canvas.getContext('webgl2', {});\n }\n if (!gl) {\n gl = canvas.getContext('webgl', {})\n || canvas.getContext('experimental-webgl', {});\n if (!gl) {\n // fail, not able to get a context\n gl = null;\n }\n else {\n // for shader testing..\n gl.getExtension('WEBGL_draw_buffers');\n }\n }\n context = gl;\n }\n return context;\n}\n\nvar maxFragmentPrecision;\nfunction getMaxFragmentPrecision() {\n if (!maxFragmentPrecision) {\n maxFragmentPrecision = PRECISION.MEDIUM;\n var gl = getTestContext();\n if (gl) {\n if (gl.getShaderPrecisionFormat) {\n var shaderFragment = gl.getShaderPrecisionFormat(gl.FRAGMENT_SHADER, gl.HIGH_FLOAT);\n maxFragmentPrecision = shaderFragment.precision ? PRECISION.HIGH : PRECISION.MEDIUM;\n }\n }\n }\n return maxFragmentPrecision;\n}\n\n/**\n * Sets the float precision on the shader, ensuring the device supports the request precision.\n * If the precision is already present, it just ensures that the device is able to handle it.\n *\n * @private\n * @param {string} src - The shader source\n * @param {PIXI.PRECISION} requestedPrecision - The request float precision of the shader.\n * @param {PIXI.PRECISION} maxSupportedPrecision - The maximum precision the shader supports.\n *\n * @return {string} modified shader source\n */\nfunction setPrecision(src, requestedPrecision, maxSupportedPrecision) {\n if (src.substring(0, 9) !== 'precision') {\n // no precision supplied, so PixiJS will add the requested level.\n var precision = requestedPrecision;\n // If highp is requested but not supported, downgrade precision to a level all devices support.\n if (requestedPrecision === PRECISION.HIGH && maxSupportedPrecision !== PRECISION.HIGH) {\n precision = PRECISION.MEDIUM;\n }\n return \"precision \" + precision + \" float;\\n\" + src;\n }\n else if (maxSupportedPrecision !== PRECISION.HIGH && src.substring(0, 15) === 'precision highp') {\n // precision was supplied, but at a level this device does not support, so downgrading to mediump.\n return src.replace('precision highp', 'precision mediump');\n }\n return src;\n}\n\nvar GLSL_TO_SIZE = {\n float: 1,\n vec2: 2,\n vec3: 3,\n vec4: 4,\n int: 1,\n ivec2: 2,\n ivec3: 3,\n ivec4: 4,\n uint: 1,\n uvec2: 2,\n uvec3: 3,\n uvec4: 4,\n bool: 1,\n bvec2: 2,\n bvec3: 3,\n bvec4: 4,\n mat2: 4,\n mat3: 9,\n mat4: 16,\n sampler2D: 1,\n};\n/**\n * @private\n * @method mapSize\n * @memberof PIXI.glCore.shader\n * @param {String} type\n * @return {Number}\n */\nfunction mapSize(type) {\n return GLSL_TO_SIZE[type];\n}\n\nvar GL_TABLE = null;\nvar GL_TO_GLSL_TYPES = {\n FLOAT: 'float',\n FLOAT_VEC2: 'vec2',\n FLOAT_VEC3: 'vec3',\n FLOAT_VEC4: 'vec4',\n INT: 'int',\n INT_VEC2: 'ivec2',\n INT_VEC3: 'ivec3',\n INT_VEC4: 'ivec4',\n UNSIGNED_INT: 'uint',\n UNSIGNED_INT_VEC2: 'uvec2',\n UNSIGNED_INT_VEC3: 'uvec3',\n UNSIGNED_INT_VEC4: 'uvec4',\n BOOL: 'bool',\n BOOL_VEC2: 'bvec2',\n BOOL_VEC3: 'bvec3',\n BOOL_VEC4: 'bvec4',\n FLOAT_MAT2: 'mat2',\n FLOAT_MAT3: 'mat3',\n FLOAT_MAT4: 'mat4',\n SAMPLER_2D: 'sampler2D',\n INT_SAMPLER_2D: 'sampler2D',\n UNSIGNED_INT_SAMPLER_2D: 'sampler2D',\n SAMPLER_CUBE: 'samplerCube',\n INT_SAMPLER_CUBE: 'samplerCube',\n UNSIGNED_INT_SAMPLER_CUBE: 'samplerCube',\n SAMPLER_2D_ARRAY: 'sampler2DArray',\n INT_SAMPLER_2D_ARRAY: 'sampler2DArray',\n UNSIGNED_INT_SAMPLER_2D_ARRAY: 'sampler2DArray',\n};\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\nfunction mapType(gl, type) {\n if (!GL_TABLE) {\n var typeNames = Object.keys(GL_TO_GLSL_TYPES);\n GL_TABLE = {};\n for (var i = 0; i < typeNames.length; ++i) {\n var tn = typeNames[i];\n GL_TABLE[gl[tn]] = GL_TO_GLSL_TYPES[tn];\n }\n }\n return GL_TABLE[type];\n}\n\n/* eslint-disable @typescript-eslint/explicit-module-boundary-types */\n// Parsers, each one of these will take a look at the type of shader property and uniform.\n// if they pass the test function then the code function is called that returns a the shader upload code for that uniform.\n// Shader upload code is automagically generated with these parsers.\n// If no parser is valid then the default upload functions are used.\n// exposing Parsers means that custom upload logic can be added to pixi's shaders.\n// A good example would be a pixi rectangle can be directly set on a uniform.\n// If the shader sees it it knows how to upload the rectangle structure as a vec4\n// format is as follows:\n//\n// {\n// test: (data, uniform) => {} <--- test is this code should be used for this uniform\n// code: (name, uniform) => {} <--- returns the string of the piece of code that uploads the uniform\n// codeUbo: (name, uniform) => {} <--- returns the string of the piece of code that uploads the\n// uniform to a uniform buffer\n// }\nvar uniformParsers = [\n // a float cache layer\n {\n test: function (data) {\n return data.type === 'float' && data.size === 1;\n },\n code: function (name) {\n return \"\\n if(uv[\\\"\" + name + \"\\\"] !== ud[\\\"\" + name + \"\\\"].value)\\n {\\n ud[\\\"\" + name + \"\\\"].value = uv[\\\"\" + name + \"\\\"]\\n gl.uniform1f(ud[\\\"\" + name + \"\\\"].location, uv[\\\"\" + name + \"\\\"])\\n }\\n \";\n },\n },\n // handling samplers\n {\n test: function (data) {\n // eslint-disable-next-line max-len\n return (data.type === 'sampler2D' || data.type === 'samplerCube' || data.type === 'sampler2DArray') && data.size === 1 && !data.isArray;\n },\n code: function (name) { return \"t = syncData.textureCount++;\\n\\n renderer.texture.bind(uv[\\\"\" + name + \"\\\"], t);\\n\\n if(ud[\\\"\" + name + \"\\\"].value !== t)\\n {\\n ud[\\\"\" + name + \"\\\"].value = t;\\n gl.uniform1i(ud[\\\"\" + name + \"\\\"].location, t);\\n; // eslint-disable-line max-len\\n }\"; },\n },\n // uploading pixi matrix object to mat3\n {\n test: function (data, uniform) {\n return data.type === 'mat3' && data.size === 1 && uniform.a !== undefined;\n },\n code: function (name) {\n // TODO and some smart caching dirty ids here!\n return \"\\n gl.uniformMatrix3fv(ud[\\\"\" + name + \"\\\"].location, false, uv[\\\"\" + name + \"\\\"].toArray(true));\\n \";\n },\n codeUbo: function (name) {\n return \"\\n var \" + name + \"_matrix = uv.\" + name + \".toArray(true);\\n\\n data[offset] = \" + name + \"_matrix[0];\\n data[offset+1] = \" + name + \"_matrix[1];\\n data[offset+2] = \" + name + \"_matrix[2];\\n \\n data[offset + 4] = \" + name + \"_matrix[3];\\n data[offset + 5] = \" + name + \"_matrix[4];\\n data[offset + 6] = \" + name + \"_matrix[5];\\n \\n data[offset + 8] = \" + name + \"_matrix[6];\\n data[offset + 9] = \" + name + \"_matrix[7];\\n data[offset + 10] = \" + name + \"_matrix[8];\\n \";\n },\n },\n // uploading a pixi point as a vec2 with caching layer\n {\n test: function (data, uniform) {\n return data.type === 'vec2' && data.size === 1 && uniform.x !== undefined;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v.x || cv[1] !== v.y)\\n {\\n cv[0] = v.x;\\n cv[1] = v.y;\\n gl.uniform2f(ud[\\\"\" + name + \"\\\"].location, v.x, v.y);\\n }\";\n },\n codeUbo: function (name) {\n return \"\\n v = uv.\" + name + \";\\n\\n data[offset] = v.x;\\n data[offset+1] = v.y;\\n \";\n }\n },\n // caching layer for a vec2\n {\n test: function (data) {\n return data.type === 'vec2' && data.size === 1;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n gl.uniform2f(ud[\\\"\" + name + \"\\\"].location, v[0], v[1]);\\n }\\n \";\n },\n },\n // upload a pixi rectangle as a vec4 with caching layer\n {\n test: function (data, uniform) {\n return data.type === 'vec4' && data.size === 1 && uniform.width !== undefined;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v.x || cv[1] !== v.y || cv[2] !== v.width || cv[3] !== v.height)\\n {\\n cv[0] = v.x;\\n cv[1] = v.y;\\n cv[2] = v.width;\\n cv[3] = v.height;\\n gl.uniform4f(ud[\\\"\" + name + \"\\\"].location, v.x, v.y, v.width, v.height)\\n }\";\n },\n codeUbo: function (name) {\n return \"\\n v = uv.\" + name + \";\\n\\n data[offset] = v.x;\\n data[offset+1] = v.y;\\n data[offset+2] = v.width;\\n data[offset+3] = v.height;\\n \";\n }\n },\n // a caching layer for vec4 uploading\n {\n test: function (data) {\n return data.type === 'vec4' && data.size === 1;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4f(ud[\\\"\" + name + \"\\\"].location, v[0], v[1], v[2], v[3])\\n }\";\n },\n } ];\n\n// cu = Cached value's uniform data field\n// cv = Cached value\n// v = value to upload\n// ud = uniformData\n// uv = uniformValue\n// l = location\nvar GLSL_TO_SINGLE_SETTERS_CACHED = {\n float: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n gl.uniform1f(location, v);\\n }\",\n vec2: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2f(location, v[0], v[1])\\n }\",\n vec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3f(location, v[0], v[1], v[2])\\n }\",\n vec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4f(location, v[0], v[1], v[2], v[3]);\\n }\",\n int: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n\\n gl.uniform1i(location, v);\\n }\",\n ivec2: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2i(location, v[0], v[1]);\\n }\",\n ivec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3i(location, v[0], v[1], v[2]);\\n }\",\n ivec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\\n }\",\n uint: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n\\n gl.uniform1ui(location, v);\\n }\",\n uvec2: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2ui(location, v[0], v[1]);\\n }\",\n uvec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3ui(location, v[0], v[1], v[2]);\\n }\",\n uvec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4ui(location, v[0], v[1], v[2], v[3]);\\n }\",\n bool: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n gl.uniform1i(location, v);\\n }\",\n bvec2: \"\\n if (cv[0] != v[0] || cv[1] != v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2i(location, v[0], v[1]);\\n }\",\n bvec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3i(location, v[0], v[1], v[2]);\\n }\",\n bvec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\\n }\",\n mat2: 'gl.uniformMatrix2fv(location, false, v)',\n mat3: 'gl.uniformMatrix3fv(location, false, v)',\n mat4: 'gl.uniformMatrix4fv(location, false, v)',\n sampler2D: 'gl.uniform1i(location, v)',\n samplerCube: 'gl.uniform1i(location, v)',\n sampler2DArray: 'gl.uniform1i(location, v)',\n};\nvar GLSL_TO_ARRAY_SETTERS = {\n float: \"gl.uniform1fv(location, v)\",\n vec2: \"gl.uniform2fv(location, v)\",\n vec3: \"gl.uniform3fv(location, v)\",\n vec4: 'gl.uniform4fv(location, v)',\n mat4: 'gl.uniformMatrix4fv(location, false, v)',\n mat3: 'gl.uniformMatrix3fv(location, false, v)',\n mat2: 'gl.uniformMatrix2fv(location, false, v)',\n int: 'gl.uniform1iv(location, v)',\n ivec2: 'gl.uniform2iv(location, v)',\n ivec3: 'gl.uniform3iv(location, v)',\n ivec4: 'gl.uniform4iv(location, v)',\n uint: 'gl.uniform1uiv(location, v)',\n uvec2: 'gl.uniform2uiv(location, v)',\n uvec3: 'gl.uniform3uiv(location, v)',\n uvec4: 'gl.uniform4uiv(location, v)',\n bool: 'gl.uniform1iv(location, v)',\n bvec2: 'gl.uniform2iv(location, v)',\n bvec3: 'gl.uniform3iv(location, v)',\n bvec4: 'gl.uniform4iv(location, v)',\n sampler2D: 'gl.uniform1iv(location, v)',\n samplerCube: 'gl.uniform1iv(location, v)',\n sampler2DArray: 'gl.uniform1iv(location, v)',\n};\nfunction generateUniformsSync(group, uniformData) {\n var _a;\n var funcFragments = [\"\\n var v = null;\\n var cv = null;\\n var cu = null;\\n var t = 0;\\n var gl = renderer.gl;\\n \"];\n for (var i in group.uniforms) {\n var data = uniformData[i];\n if (!data) {\n if ((_a = group.uniforms[i]) === null || _a === void 0 ? void 0 : _a.group) {\n if (group.uniforms[i].ubo) {\n funcFragments.push(\"\\n renderer.shader.syncUniformBufferGroup(uv.\" + i + \", '\" + i + \"');\\n \");\n }\n else {\n funcFragments.push(\"\\n renderer.shader.syncUniformGroup(uv.\" + i + \", syncData);\\n \");\n }\n }\n continue;\n }\n var uniform = group.uniforms[i];\n var parsed = false;\n for (var j = 0; j < uniformParsers.length; j++) {\n if (uniformParsers[j].test(data, uniform)) {\n funcFragments.push(uniformParsers[j].code(i, uniform));\n parsed = true;\n break;\n }\n }\n if (!parsed) {\n var templateType = (data.size === 1) ? GLSL_TO_SINGLE_SETTERS_CACHED : GLSL_TO_ARRAY_SETTERS;\n var template = templateType[data.type].replace('location', \"ud[\\\"\" + i + \"\\\"].location\");\n funcFragments.push(\"\\n cu = ud[\\\"\" + i + \"\\\"];\\n cv = cu.value;\\n v = uv[\\\"\" + i + \"\\\"];\\n \" + template + \";\");\n }\n }\n /*\n * the introduction of syncData is to solve an issue where textures in uniform groups are not set correctly\n * the texture count was always starting from 0 in each group. This needs to increment each time a texture is used\n * no matter which group is being used\n *\n */\n // eslint-disable-next-line no-new-func\n return new Function('ud', 'uv', 'renderer', 'syncData', funcFragments.join('\\n'));\n}\n\nvar fragTemplate = [\n 'precision mediump float;',\n 'void main(void){',\n 'float test = 0.1;',\n '%forloop%',\n 'gl_FragColor = vec4(0.0);',\n '}' ].join('\\n');\nfunction generateIfTestSrc(maxIfs) {\n var src = '';\n for (var i = 0; i < maxIfs; ++i) {\n if (i > 0) {\n src += '\\nelse ';\n }\n if (i < maxIfs - 1) {\n src += \"if(test == \" + i + \".0){}\";\n }\n }\n return src;\n}\nfunction checkMaxIfStatementsInShader(maxIfs, gl) {\n if (maxIfs === 0) {\n throw new Error('Invalid value of `0` passed to `checkMaxIfStatementsInShader`');\n }\n var shader = gl.createShader(gl.FRAGMENT_SHADER);\n while (true) // eslint-disable-line no-constant-condition\n {\n var fragmentSrc = fragTemplate.replace(/%forloop%/gi, generateIfTestSrc(maxIfs));\n gl.shaderSource(shader, fragmentSrc);\n gl.compileShader(shader);\n if (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {\n maxIfs = (maxIfs / 2) | 0;\n }\n else {\n // valid!\n break;\n }\n }\n return maxIfs;\n}\n\n// Cache the result to prevent running this over and over\nvar unsafeEval;\n/**\n * Not all platforms allow to generate function code (e.g., `new Function`).\n * this provides the platform-level detection.\n *\n * @private\n * @returns {boolean}\n */\nfunction unsafeEvalSupported() {\n if (typeof unsafeEval === 'boolean') {\n return unsafeEval;\n }\n try {\n /* eslint-disable no-new-func */\n var func = new Function('param1', 'param2', 'param3', 'return param1[param2] === param3;');\n /* eslint-enable no-new-func */\n unsafeEval = func({ a: 'b' }, 'a', 'b') === true;\n }\n catch (e) {\n unsafeEval = false;\n }\n return unsafeEval;\n}\n\nvar defaultFragment = \"varying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void){\\n gl_FragColor *= texture2D(uSampler, vTextureCoord);\\n}\";\n\nvar defaultVertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void){\\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n vTextureCoord = aTextureCoord;\\n}\\n\";\n\nvar UID$3 = 0;\nvar nameCache = {};\n/**\n * Helper class to create a shader program.\n *\n * @memberof PIXI\n */\nvar Program = /** @class */ (function () {\n /**\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param name - Name for shader\n */\n function Program(vertexSrc, fragmentSrc, name) {\n if (name === void 0) { name = 'pixi-shader'; }\n this.id = UID$3++;\n this.vertexSrc = vertexSrc || Program.defaultVertexSrc;\n this.fragmentSrc = fragmentSrc || Program.defaultFragmentSrc;\n this.vertexSrc = this.vertexSrc.trim();\n this.fragmentSrc = this.fragmentSrc.trim();\n if (this.vertexSrc.substring(0, 8) !== '#version') {\n name = name.replace(/\\s+/g, '-');\n if (nameCache[name]) {\n nameCache[name]++;\n name += \"-\" + nameCache[name];\n }\n else {\n nameCache[name] = 1;\n }\n this.vertexSrc = \"#define SHADER_NAME \" + name + \"\\n\" + this.vertexSrc;\n this.fragmentSrc = \"#define SHADER_NAME \" + name + \"\\n\" + this.fragmentSrc;\n this.vertexSrc = setPrecision(this.vertexSrc, settings.PRECISION_VERTEX, PRECISION.HIGH);\n this.fragmentSrc = setPrecision(this.fragmentSrc, settings.PRECISION_FRAGMENT, getMaxFragmentPrecision());\n }\n // currently this does not extract structs only default types\n // this is where we store shader references..\n this.glPrograms = {};\n this.syncUniforms = null;\n }\n Object.defineProperty(Program, \"defaultVertexSrc\", {\n /**\n * The default vertex shader source.\n *\n * @constant\n */\n get: function () {\n return defaultVertex;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Program, \"defaultFragmentSrc\", {\n /**\n * The default fragment shader source.\n *\n * @constant\n */\n get: function () {\n return defaultFragment;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * A short hand function to create a program based of a vertex and fragment shader.\n *\n * This method will also check to see if there is a cached program.\n *\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param name - Name for shader\n * @returns A shiny new PixiJS shader program!\n */\n Program.from = function (vertexSrc, fragmentSrc, name) {\n var key = vertexSrc + fragmentSrc;\n var program = ProgramCache[key];\n if (!program) {\n ProgramCache[key] = program = new Program(vertexSrc, fragmentSrc, name);\n }\n return program;\n };\n return Program;\n}());\n\n/**\n * A helper class for shaders.\n *\n * @memberof PIXI\n */\nvar Shader = /** @class */ (function () {\n /**\n * @param program - The program the shader will use.\n * @param uniforms - Custom uniforms to use to augment the built-in ones.\n */\n function Shader(program, uniforms) {\n /**\n * Used internally to bind uniform buffer objects.\n * @ignore\n */\n this.uniformBindCount = 0;\n this.program = program;\n // lets see whats been passed in\n // uniforms should be converted to a uniform group\n if (uniforms) {\n if (uniforms instanceof UniformGroup) {\n this.uniformGroup = uniforms;\n }\n else {\n this.uniformGroup = new UniformGroup(uniforms);\n }\n }\n else {\n this.uniformGroup = new UniformGroup({});\n }\n }\n // TODO move to shader system..\n Shader.prototype.checkUniformExists = function (name, group) {\n if (group.uniforms[name]) {\n return true;\n }\n for (var i in group.uniforms) {\n var uniform = group.uniforms[i];\n if (uniform.group) {\n if (this.checkUniformExists(name, uniform)) {\n return true;\n }\n }\n }\n return false;\n };\n Shader.prototype.destroy = function () {\n // usage count on programs?\n // remove if not used!\n this.uniformGroup = null;\n };\n Object.defineProperty(Shader.prototype, \"uniforms\", {\n /**\n * Shader uniform values, shortcut for `uniformGroup.uniforms`.\n *\n * @readonly\n */\n get: function () {\n return this.uniformGroup.uniforms;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * A short hand function to create a shader based of a vertex and fragment shader.\n *\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param uniforms - Custom uniforms to use to augment the built-in ones.\n * @returns A shiny new PixiJS shader!\n */\n Shader.from = function (vertexSrc, fragmentSrc, uniforms) {\n var program = Program.from(vertexSrc, fragmentSrc);\n return new Shader(program, uniforms);\n };\n return Shader;\n}());\n\n/* eslint-disable max-len */\nvar BLEND = 0;\nvar OFFSET = 1;\nvar CULLING = 2;\nvar DEPTH_TEST = 3;\nvar WINDING = 4;\nvar DEPTH_MASK = 5;\n/**\n * This is a WebGL state, and is is passed to {@link PIXI.StateSystem}.\n *\n * Each mesh rendered may require WebGL to be in a different state.\n * For example you may want different blend mode or to enable polygon offsets\n *\n * @memberof PIXI\n */\nvar State = /** @class */ (function () {\n function State() {\n this.data = 0;\n this.blendMode = BLEND_MODES.NORMAL;\n this.polygonOffset = 0;\n this.blend = true;\n this.depthMask = true;\n // this.depthTest = true;\n }\n Object.defineProperty(State.prototype, \"blend\", {\n /**\n * Activates blending of the computed fragment color values.\n *\n * @default true\n */\n get: function () {\n return !!(this.data & (1 << BLEND));\n },\n set: function (value) {\n if (!!(this.data & (1 << BLEND)) !== value) {\n this.data ^= (1 << BLEND);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"offsets\", {\n /**\n * Activates adding an offset to depth values of polygon's fragments\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << OFFSET));\n },\n set: function (value) {\n if (!!(this.data & (1 << OFFSET)) !== value) {\n this.data ^= (1 << OFFSET);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"culling\", {\n /**\n * Activates culling of polygons.\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << CULLING));\n },\n set: function (value) {\n if (!!(this.data & (1 << CULLING)) !== value) {\n this.data ^= (1 << CULLING);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"depthTest\", {\n /**\n * Activates depth comparisons and updates to the depth buffer.\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << DEPTH_TEST));\n },\n set: function (value) {\n if (!!(this.data & (1 << DEPTH_TEST)) !== value) {\n this.data ^= (1 << DEPTH_TEST);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"depthMask\", {\n /**\n * Enables or disables writing to the depth buffer.\n *\n * @default true\n */\n get: function () {\n return !!(this.data & (1 << DEPTH_MASK));\n },\n set: function (value) {\n if (!!(this.data & (1 << DEPTH_MASK)) !== value) {\n this.data ^= (1 << DEPTH_MASK);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"clockwiseFrontFace\", {\n /**\n * Specifies whether or not front or back-facing polygons can be culled.\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << WINDING));\n },\n set: function (value) {\n if (!!(this.data & (1 << WINDING)) !== value) {\n this.data ^= (1 << WINDING);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"blendMode\", {\n /**\n * The blend mode to be applied when this state is set. Apply a value of `PIXI.BLEND_MODES.NORMAL` to reset the blend mode.\n * Setting this mode to anything other than NO_BLEND will automatically switch blending on.\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n get: function () {\n return this._blendMode;\n },\n set: function (value) {\n this.blend = (value !== BLEND_MODES.NONE);\n this._blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"polygonOffset\", {\n /**\n * The polygon offset. Setting this property to anything other than 0 will automatically enable polygon offset fill.\n *\n * @default 0\n */\n get: function () {\n return this._polygonOffset;\n },\n set: function (value) {\n this.offsets = !!value;\n this._polygonOffset = value;\n },\n enumerable: false,\n configurable: true\n });\n State.prototype.toString = function () {\n return \"[@pixi/core:State \"\n + (\"blendMode=\" + this.blendMode + \" \")\n + (\"clockwiseFrontFace=\" + this.clockwiseFrontFace + \" \")\n + (\"culling=\" + this.culling + \" \")\n + (\"depthMask=\" + this.depthMask + \" \")\n + (\"polygonOffset=\" + this.polygonOffset)\n + \"]\";\n };\n State.for2d = function () {\n var state = new State();\n state.depthTest = false;\n state.blend = true;\n return state;\n };\n return State;\n}());\n\nvar defaultVertex$1 = \"attribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvec2 filterTextureCoord( void )\\n{\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n}\\n\\nvoid main(void)\\n{\\n gl_Position = filterVertexPosition();\\n vTextureCoord = filterTextureCoord();\\n}\\n\";\n\nvar defaultFragment$1 = \"varying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void){\\n gl_FragColor = texture2D(uSampler, vTextureCoord);\\n}\\n\";\n\n/**\n * A filter is a special shader that applies post-processing effects to an input texture and writes into an output\n * render-target.\n *\n * {@link http://pixijs.io/examples/#/filters/blur-filter.js Example} of the\n * {@link PIXI.filters.BlurFilter BlurFilter}.\n *\n * ### Usage\n * Filters can be applied to any DisplayObject or Container.\n * PixiJS' `FilterSystem` renders the container into temporary Framebuffer,\n * then filter renders it to the screen.\n * Multiple filters can be added to the `filters` array property and stacked on each other.\n *\n * ```\n * const filter = new PIXI.Filter(myShaderVert, myShaderFrag, { myUniform: 0.5 });\n * const container = new PIXI.Container();\n * container.filters = [filter];\n * ```\n *\n * ### Previous Version Differences\n *\n * In PixiJS **v3**, a filter was always applied to _whole screen_.\n *\n * In PixiJS **v4**, a filter can be applied _only part of the screen_.\n * Developers had to create a set of uniforms to deal with coordinates.\n *\n * In PixiJS **v5** combines _both approaches_.\n * Developers can use normal coordinates of v3 and then allow filter to use partial Framebuffers,\n * bringing those extra uniforms into account.\n *\n * Also be aware that we have changed default vertex shader, please consult\n * {@link https://github.com/pixijs/pixi.js/wiki/v5-Creating-filters Wiki}.\n *\n * ### Frames\n *\n * The following table summarizes the coordinate spaces used in the filtering pipeline:\n *\n * <table>\n * <thead>\n * <tr>\n * <th>Coordinate Space</th>\n * <th>Description</th>\n * </tr>\n * </thead>\n * <tbody>\n * <tr>\n * <td>Texture Coordinates</td>\n * <td>\n * The texture (or UV) coordinates in the input base-texture's space. These are normalized into the (0,1) range along\n * both axes.\n * </td>\n * </tr>\n * <tr>\n * <td>World Space</td>\n * <td>\n * A point in the same space as the world bounds of any display-object (i.e. in the scene graph's space).\n * </td>\n * </tr>\n * <tr>\n * <td>Physical Pixels</td>\n * <td>\n * This is base-texture's space with the origin on the top-left. You can calculate these by multiplying the texture\n * coordinates by the dimensions of the texture.\n * </td>\n * </tr>\n * </tbody>\n * </table>\n *\n * ### Built-in Uniforms\n *\n * PixiJS viewport uses screen (CSS) coordinates, `(0, 0, renderer.screen.width, renderer.screen.height)`,\n * and `projectionMatrix` uniform maps it to the gl viewport.\n *\n * **uSampler**\n *\n * The most important uniform is the input texture that container was rendered into.\n * _Important note: as with all Framebuffers in PixiJS, both input and output are\n * premultiplied by alpha._\n *\n * By default, input normalized coordinates are passed to fragment shader with `vTextureCoord`.\n * Use it to sample the input.\n *\n * ```\n * const fragment = `\n * varying vec2 vTextureCoord;\n * uniform sampler2D uSampler;\n * void main(void)\n * {\n * gl_FragColor = texture2D(uSampler, vTextureCoord);\n * }\n * `;\n *\n * const myFilter = new PIXI.Filter(null, fragment);\n * ```\n *\n * This filter is just one uniform less than {@link PIXI.filters.AlphaFilter AlphaFilter}.\n *\n * **outputFrame**\n *\n * The `outputFrame` holds the rectangle where filter is applied in screen (CSS) coordinates.\n * It's the same as `renderer.screen` for a fullscreen filter.\n * Only a part of `outputFrame.zw` size of temporary Framebuffer is used,\n * `(0, 0, outputFrame.width, outputFrame.height)`,\n *\n * Filters uses this quad to normalized (0-1) space, its passed into `aVertexPosition` attribute.\n * To calculate vertex position in screen space using normalized (0-1) space:\n *\n * ```\n * vec4 filterVertexPosition( void )\n * {\n * vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n * return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n * }\n * ```\n *\n * **inputSize**\n *\n * Temporary framebuffer is different, it can be either the size of screen, either power-of-two.\n * The `inputSize.xy` are size of temporary framebuffer that holds input.\n * The `inputSize.zw` is inverted, it's a shortcut to evade division inside the shader.\n *\n * Set `inputSize.xy = outputFrame.zw` for a fullscreen filter.\n *\n * To calculate input normalized coordinate, you have to map it to filter normalized space.\n * Multiply by `outputFrame.zw` to get input coordinate.\n * Divide by `inputSize.xy` to get input normalized coordinate.\n *\n * ```\n * vec2 filterTextureCoord( void )\n * {\n * return aVertexPosition * (outputFrame.zw * inputSize.zw); // same as /inputSize.xy\n * }\n * ```\n * **resolution**\n *\n * The `resolution` is the ratio of screen (CSS) pixels to real pixels.\n *\n * **inputPixel**\n *\n * `inputPixel.xy` is the size of framebuffer in real pixels, same as `inputSize.xy * resolution`\n * `inputPixel.zw` is inverted `inputPixel.xy`.\n *\n * It's handy for filters that use neighbour pixels, like {@link PIXI.filters.FXAAFilter FXAAFilter}.\n *\n * **inputClamp**\n *\n * If you try to get info from outside of used part of Framebuffer - you'll get undefined behaviour.\n * For displacements, coordinates has to be clamped.\n *\n * The `inputClamp.xy` is left-top pixel center, you may ignore it, because we use left-top part of Framebuffer\n * `inputClamp.zw` is bottom-right pixel center.\n *\n * ```\n * vec4 color = texture2D(uSampler, clamp(modifiedTextureCoord, inputClamp.xy, inputClamp.zw))\n * ```\n * OR\n * ```\n * vec4 color = texture2D(uSampler, min(modifigedTextureCoord, inputClamp.zw))\n * ```\n *\n * ### Additional Information\n *\n * Complete documentation on Filter usage is located in the\n * {@link https://github.com/pixijs/pixi.js/wiki/v5-Creating-filters Wiki}.\n *\n * Since PixiJS only had a handful of built-in filters, additional filters can be downloaded\n * {@link https://github.com/pixijs/pixi-filters here} from the PixiJS Filters repository.\n *\n * @memberof PIXI\n */\nvar Filter = /** @class */ (function (_super) {\n __extends(Filter, _super);\n /**\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param uniforms - Custom uniforms to use to augment the built-in ones.\n */\n function Filter(vertexSrc, fragmentSrc, uniforms) {\n var _this = this;\n var program = Program.from(vertexSrc || Filter.defaultVertexSrc, fragmentSrc || Filter.defaultFragmentSrc);\n _this = _super.call(this, program, uniforms) || this;\n _this.padding = 0;\n _this.resolution = settings.FILTER_RESOLUTION;\n _this.multisample = settings.FILTER_MULTISAMPLE;\n _this.enabled = true;\n _this.autoFit = true;\n _this.state = new State();\n return _this;\n }\n /**\n * Applies the filter\n *\n * @param {PIXI.FilterSystem} filterManager - The renderer to retrieve the filter from\n * @param {PIXI.RenderTexture} input - The input render target.\n * @param {PIXI.RenderTexture} output - The target to output to.\n * @param {PIXI.CLEAR_MODES} [clearMode] - Should the output be cleared before rendering to it.\n * @param {object} [currentState] - It's current state of filter.\n * There are some useful properties in the currentState :\n * target, filters, sourceFrame, destinationFrame, renderTarget, resolution\n */\n Filter.prototype.apply = function (filterManager, input, output, clearMode, _currentState) {\n // do as you please!\n filterManager.applyFilter(this, input, output, clearMode);\n // or just do a regular render..\n };\n Object.defineProperty(Filter.prototype, \"blendMode\", {\n /**\n * Sets the blend mode of the filter.\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n get: function () {\n return this.state.blendMode;\n },\n set: function (value) {\n this.state.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Filter.prototype, \"resolution\", {\n /**\n * The resolution of the filter. Setting this to be lower will lower the quality but\n * increase the performance of the filter.\n */\n get: function () {\n return this._resolution;\n },\n set: function (value) {\n this._resolution = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Filter, \"defaultVertexSrc\", {\n /**\n * The default vertex shader source\n *\n * @constant\n */\n get: function () {\n return defaultVertex$1;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Filter, \"defaultFragmentSrc\", {\n /**\n * The default fragment shader source\n *\n * @constant\n */\n get: function () {\n return defaultFragment$1;\n },\n enumerable: false,\n configurable: true\n });\n return Filter;\n}(Shader));\n\nvar vertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 otherMatrix;\\n\\nvarying vec2 vMaskCoord;\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = aTextureCoord;\\n vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;\\n}\\n\";\n\nvar fragment = \"varying vec2 vMaskCoord;\\nvarying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform sampler2D mask;\\nuniform float alpha;\\nuniform float npmAlpha;\\nuniform vec4 maskClamp;\\n\\nvoid main(void)\\n{\\n float clip = step(3.5,\\n step(maskClamp.x, vMaskCoord.x) +\\n step(maskClamp.y, vMaskCoord.y) +\\n step(vMaskCoord.x, maskClamp.z) +\\n step(vMaskCoord.y, maskClamp.w));\\n\\n vec4 original = texture2D(uSampler, vTextureCoord);\\n vec4 masky = texture2D(mask, vMaskCoord);\\n float alphaMul = 1.0 - npmAlpha * (1.0 - masky.a);\\n\\n original *= (alphaMul * masky.r * alpha * clip);\\n\\n gl_FragColor = original;\\n}\\n\";\n\nvar tempMat = new Matrix();\n/**\n * Class controls uv mapping from Texture normal space to BaseTexture normal space.\n *\n * Takes `trim` and `rotate` into account. May contain clamp settings for Meshes and TilingSprite.\n *\n * Can be used in Texture `uvMatrix` field, or separately, you can use different clamp settings on the same texture.\n * If you want to add support for texture region of certain feature or filter, that's what you're looking for.\n *\n * Takes track of Texture changes through `_lastTextureID` private field.\n * Use `update()` method call to track it from outside.\n *\n * @see PIXI.Texture\n * @see PIXI.Mesh\n * @see PIXI.TilingSprite\n * @memberof PIXI\n */\nvar TextureMatrix = /** @class */ (function () {\n /**\n * @param texture - observed texture\n * @param clampMargin - Changes frame clamping, 0.5 by default. Use -0.5 for extra border.\n */\n function TextureMatrix(texture, clampMargin) {\n this._texture = texture;\n this.mapCoord = new Matrix();\n this.uClampFrame = new Float32Array(4);\n this.uClampOffset = new Float32Array(2);\n this._textureID = -1;\n this._updateID = 0;\n this.clampOffset = 0;\n this.clampMargin = (typeof clampMargin === 'undefined') ? 0.5 : clampMargin;\n this.isSimple = false;\n }\n Object.defineProperty(TextureMatrix.prototype, \"texture\", {\n /** Texture property. */\n get: function () {\n return this._texture;\n },\n set: function (value) {\n this._texture = value;\n this._textureID = -1;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Multiplies uvs array to transform\n *\n * @param uvs - mesh uvs\n * @param [out=uvs] - output\n * @returns - output\n */\n TextureMatrix.prototype.multiplyUvs = function (uvs, out) {\n if (out === undefined) {\n out = uvs;\n }\n var mat = this.mapCoord;\n for (var i = 0; i < uvs.length; i += 2) {\n var x = uvs[i];\n var y = uvs[i + 1];\n out[i] = (x * mat.a) + (y * mat.c) + mat.tx;\n out[i + 1] = (x * mat.b) + (y * mat.d) + mat.ty;\n }\n return out;\n };\n /**\n * Updates matrices if texture was changed.\n *\n * @param [forceUpdate=false] - if true, matrices will be updated any case\n * @returns - Whether or not it was updated\n */\n TextureMatrix.prototype.update = function (forceUpdate) {\n var tex = this._texture;\n if (!tex || !tex.valid) {\n return false;\n }\n if (!forceUpdate\n && this._textureID === tex._updateID) {\n return false;\n }\n this._textureID = tex._updateID;\n this._updateID++;\n var uvs = tex._uvs;\n this.mapCoord.set(uvs.x1 - uvs.x0, uvs.y1 - uvs.y0, uvs.x3 - uvs.x0, uvs.y3 - uvs.y0, uvs.x0, uvs.y0);\n var orig = tex.orig;\n var trim = tex.trim;\n if (trim) {\n tempMat.set(orig.width / trim.width, 0, 0, orig.height / trim.height, -trim.x / trim.width, -trim.y / trim.height);\n this.mapCoord.append(tempMat);\n }\n var texBase = tex.baseTexture;\n var frame = this.uClampFrame;\n var margin = this.clampMargin / texBase.resolution;\n var offset = this.clampOffset;\n frame[0] = (tex._frame.x + margin + offset) / texBase.width;\n frame[1] = (tex._frame.y + margin + offset) / texBase.height;\n frame[2] = (tex._frame.x + tex._frame.width - margin + offset) / texBase.width;\n frame[3] = (tex._frame.y + tex._frame.height - margin + offset) / texBase.height;\n this.uClampOffset[0] = offset / texBase.realWidth;\n this.uClampOffset[1] = offset / texBase.realHeight;\n this.isSimple = tex._frame.width === texBase.width\n && tex._frame.height === texBase.height\n && tex.rotate === 0;\n return true;\n };\n return TextureMatrix;\n}());\n\n/**\n * This handles a Sprite acting as a mask, as opposed to a Graphic.\n *\n * WebGL only.\n *\n * @memberof PIXI\n */\nvar SpriteMaskFilter = /** @class */ (function (_super) {\n __extends(SpriteMaskFilter, _super);\n /** @ignore */\n function SpriteMaskFilter(vertexSrc, fragmentSrc, uniforms) {\n var _this = this;\n var sprite = null;\n if (typeof vertexSrc !== 'string' && fragmentSrc === undefined && uniforms === undefined) {\n sprite = vertexSrc;\n vertexSrc = undefined;\n fragmentSrc = undefined;\n uniforms = undefined;\n }\n _this = _super.call(this, vertexSrc || vertex, fragmentSrc || fragment, uniforms) || this;\n _this.maskSprite = sprite;\n _this.maskMatrix = new Matrix();\n return _this;\n }\n Object.defineProperty(SpriteMaskFilter.prototype, \"maskSprite\", {\n /**\n * Sprite mask\n *\n * @type {PIXI.DisplayObject}\n */\n get: function () {\n return this._maskSprite;\n },\n set: function (value) {\n this._maskSprite = value;\n if (this._maskSprite) {\n this._maskSprite.renderable = false;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Applies the filter\n *\n * @param filterManager - The renderer to retrieve the filter from\n * @param input - The input render target.\n * @param output - The target to output to.\n * @param clearMode - Should the output be cleared before rendering to it.\n */\n SpriteMaskFilter.prototype.apply = function (filterManager, input, output, clearMode) {\n var maskSprite = this._maskSprite;\n var tex = maskSprite._texture;\n if (!tex.valid) {\n return;\n }\n if (!tex.uvMatrix) {\n // margin = 0.0, let it bleed a bit, shader code becomes easier\n // assuming that atlas textures were made with 1-pixel padding\n tex.uvMatrix = new TextureMatrix(tex, 0.0);\n }\n tex.uvMatrix.update();\n this.uniforms.npmAlpha = tex.baseTexture.alphaMode ? 0.0 : 1.0;\n this.uniforms.mask = tex;\n // get _normalized sprite texture coords_ and convert them to _normalized atlas texture coords_ with `prepend`\n this.uniforms.otherMatrix = filterManager.calculateSpriteMatrix(this.maskMatrix, maskSprite)\n .prepend(tex.uvMatrix.mapCoord);\n this.uniforms.alpha = maskSprite.worldAlpha;\n this.uniforms.maskClamp = tex.uvMatrix.uClampFrame;\n filterManager.applyFilter(this, input, output, clearMode);\n };\n return SpriteMaskFilter;\n}(Filter));\n\n/**\n * System plugin to the renderer to manage masks.\n *\n * There are three built-in types of masking:\n * * **Scissor Masking**: Scissor masking discards pixels that are outside of a rectangle called the scissor box. It is\n * the most performant as the scissor test is inexpensive. However, it can only be used when the mask is rectangular.\n * * **Stencil Masking**: Stencil masking discards pixels that don't overlap with the pixels rendered into the stencil\n * buffer. It is the next fastest option as it does not require rendering into a separate framebuffer. However, it does\n * cause the mask to be rendered **twice** for each masking operation; hence, minimize the rendering cost of your masks.\n * * **Sprite Mask Filtering**: Sprite mask filtering discards pixels based on the red channel of the sprite-mask's\n * texture. (Generally, the masking texture is grayscale). Using advanced techniques, you might be able to embed this\n * type of masking in a custom shader - and hence, bypassing the masking system fully for performance wins.\n *\n * The best type of masking is auto-detected when you `push` one. To use scissor masking, you must pass in a `Graphics`\n * object with just a rectangle drawn.\n *\n * ## Mask Stacks\n *\n * In the scene graph, masks can be applied recursively, i.e. a mask can be applied during a masking operation. The mask\n * stack stores the currently applied masks in order. Each {@link PIXI.BaseRenderTexture} holds its own mask stack, i.e.\n * when you switch render-textures, the old masks only applied when you switch back to rendering to the old render-target.\n *\n * @memberof PIXI\n */\nvar MaskSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function MaskSystem(renderer) {\n this.renderer = renderer;\n this.enableScissor = true;\n this.alphaMaskPool = [];\n this.maskDataPool = [];\n this.maskStack = [];\n this.alphaMaskIndex = 0;\n }\n /**\n * Changes the mask stack that is used by this System.\n *\n * @param maskStack - The mask stack\n */\n MaskSystem.prototype.setMaskStack = function (maskStack) {\n this.maskStack = maskStack;\n this.renderer.scissor.setMaskStack(maskStack);\n this.renderer.stencil.setMaskStack(maskStack);\n };\n /**\n * Enables the mask and appends it to the current mask stack.\n *\n * NOTE: The batch renderer should be flushed beforehand to prevent pending renders from being masked.\n *\n * @param {PIXI.DisplayObject} target - Display Object to push the mask to\n * @param {PIXI.MaskData|PIXI.Sprite|PIXI.Graphics|PIXI.DisplayObject} maskData - The masking data.\n */\n MaskSystem.prototype.push = function (target, maskDataOrTarget) {\n var maskData = maskDataOrTarget;\n if (!maskData.isMaskData) {\n var d = this.maskDataPool.pop() || new MaskData();\n d.pooled = true;\n d.maskObject = maskDataOrTarget;\n maskData = d;\n }\n var maskAbove = this.maskStack.length !== 0 ? this.maskStack[this.maskStack.length - 1] : null;\n maskData.copyCountersOrReset(maskAbove);\n if (maskData.autoDetect) {\n this.detect(maskData);\n }\n maskData._target = target;\n if (maskData.type !== MASK_TYPES.SPRITE) {\n this.maskStack.push(maskData);\n }\n if (maskData.enabled) {\n switch (maskData.type) {\n case MASK_TYPES.SCISSOR:\n this.renderer.scissor.push(maskData);\n break;\n case MASK_TYPES.STENCIL:\n this.renderer.stencil.push(maskData);\n break;\n case MASK_TYPES.SPRITE:\n maskData.copyCountersOrReset(null);\n this.pushSpriteMask(maskData);\n break;\n }\n }\n if (maskData.type === MASK_TYPES.SPRITE) {\n this.maskStack.push(maskData);\n }\n };\n /**\n * Removes the last mask from the mask stack and doesn't return it.\n *\n * NOTE: The batch renderer should be flushed beforehand to render the masked contents before the mask is removed.\n *\n * @param {PIXI.DisplayObject} target - Display Object to pop the mask from\n */\n MaskSystem.prototype.pop = function (target) {\n var maskData = this.maskStack.pop();\n if (!maskData || maskData._target !== target) {\n // TODO: add an assert when we have it\n return;\n }\n if (maskData.enabled) {\n switch (maskData.type) {\n case MASK_TYPES.SCISSOR:\n this.renderer.scissor.pop();\n break;\n case MASK_TYPES.STENCIL:\n this.renderer.stencil.pop(maskData.maskObject);\n break;\n case MASK_TYPES.SPRITE:\n this.popSpriteMask(maskData);\n break;\n }\n }\n maskData.reset();\n if (maskData.pooled) {\n this.maskDataPool.push(maskData);\n }\n if (this.maskStack.length !== 0) {\n var maskCurrent = this.maskStack[this.maskStack.length - 1];\n if (maskCurrent.type === MASK_TYPES.SPRITE && maskCurrent._filters) {\n maskCurrent._filters[0].maskSprite = maskCurrent.maskObject;\n }\n }\n };\n /** Sets type of MaskData based on its maskObject. */\n MaskSystem.prototype.detect = function (maskData) {\n var maskObject = maskData.maskObject;\n if (maskObject.isSprite) {\n maskData.type = MASK_TYPES.SPRITE;\n }\n else if (this.enableScissor && this.renderer.scissor.testScissor(maskData)) {\n maskData.type = MASK_TYPES.SCISSOR;\n }\n else {\n maskData.type = MASK_TYPES.STENCIL;\n }\n };\n /**\n * Applies the Mask and adds it to the current filter stack.\n *\n * @param maskData - Sprite to be used as the mask.\n */\n MaskSystem.prototype.pushSpriteMask = function (maskData) {\n var _a, _b;\n var maskObject = maskData.maskObject;\n var target = maskData._target;\n var alphaMaskFilter = maskData._filters;\n if (!alphaMaskFilter) {\n alphaMaskFilter = this.alphaMaskPool[this.alphaMaskIndex];\n if (!alphaMaskFilter) {\n alphaMaskFilter = this.alphaMaskPool[this.alphaMaskIndex] = [new SpriteMaskFilter()];\n }\n }\n var renderer = this.renderer;\n var renderTextureSystem = renderer.renderTexture;\n var resolution;\n var multisample;\n if (renderTextureSystem.current) {\n var renderTexture = renderTextureSystem.current;\n resolution = maskData.resolution || renderTexture.resolution;\n multisample = (_a = maskData.multisample) !== null && _a !== void 0 ? _a : renderTexture.multisample;\n }\n else {\n resolution = maskData.resolution || renderer.resolution;\n multisample = (_b = maskData.multisample) !== null && _b !== void 0 ? _b : renderer.multisample;\n }\n alphaMaskFilter[0].resolution = resolution;\n alphaMaskFilter[0].multisample = multisample;\n alphaMaskFilter[0].maskSprite = maskObject;\n var stashFilterArea = target.filterArea;\n target.filterArea = maskObject.getBounds(true);\n renderer.filter.push(target, alphaMaskFilter);\n target.filterArea = stashFilterArea;\n if (!maskData._filters) {\n this.alphaMaskIndex++;\n }\n };\n /**\n * Removes the last filter from the filter stack and doesn't return it.\n *\n * @param maskData - Sprite to be used as the mask.\n */\n MaskSystem.prototype.popSpriteMask = function (maskData) {\n this.renderer.filter.pop();\n if (maskData._filters) {\n maskData._filters[0].maskSprite = null;\n }\n else {\n this.alphaMaskIndex--;\n this.alphaMaskPool[this.alphaMaskIndex][0].maskSprite = null;\n }\n };\n MaskSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return MaskSystem;\n}());\n\n/**\n * System plugin to the renderer to manage specific types of masking operations.\n *\n * @memberof PIXI\n */\nvar AbstractMaskSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function AbstractMaskSystem(renderer) {\n this.renderer = renderer;\n this.maskStack = [];\n this.glConst = 0;\n }\n /** Gets count of masks of certain type. */\n AbstractMaskSystem.prototype.getStackLength = function () {\n return this.maskStack.length;\n };\n /**\n * Changes the mask stack that is used by this System.\n *\n * @param {PIXI.MaskData[]} maskStack - The mask stack\n */\n AbstractMaskSystem.prototype.setMaskStack = function (maskStack) {\n var gl = this.renderer.gl;\n var curStackLen = this.getStackLength();\n this.maskStack = maskStack;\n var newStackLen = this.getStackLength();\n if (newStackLen !== curStackLen) {\n if (newStackLen === 0) {\n gl.disable(this.glConst);\n }\n else {\n gl.enable(this.glConst);\n this._useCurrent();\n }\n }\n };\n /**\n * Setup renderer to use the current mask data.\n * @private\n */\n AbstractMaskSystem.prototype._useCurrent = function () {\n // OVERWRITE;\n };\n /** Destroys the mask stack. */\n AbstractMaskSystem.prototype.destroy = function () {\n this.renderer = null;\n this.maskStack = null;\n };\n return AbstractMaskSystem;\n}());\n\nvar tempMatrix$1 = new Matrix();\n/**\n * System plugin to the renderer to manage scissor masking.\n *\n * Scissor masking discards pixels outside of a rectangle called the scissor box. The scissor box is in the framebuffer\n * viewport's space; however, the mask's rectangle is projected from world-space to viewport space automatically\n * by this system.\n *\n * @memberof PIXI\n */\nvar ScissorSystem = /** @class */ (function (_super) {\n __extends(ScissorSystem, _super);\n /**\n * @param {PIXI.Renderer} renderer - The renderer this System works for.\n */\n function ScissorSystem(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.glConst = WebGLRenderingContext.SCISSOR_TEST;\n return _this;\n }\n ScissorSystem.prototype.getStackLength = function () {\n var maskData = this.maskStack[this.maskStack.length - 1];\n if (maskData) {\n return maskData._scissorCounter;\n }\n return 0;\n };\n /**\n * evaluates _boundsTransformed, _scissorRect for MaskData\n * @param maskData\n */\n ScissorSystem.prototype.calcScissorRect = function (maskData) {\n if (maskData._scissorRectLocal) {\n return;\n }\n var prevData = maskData._scissorRect;\n var maskObject = maskData.maskObject;\n var renderer = this.renderer;\n var renderTextureSystem = renderer.renderTexture;\n maskObject.renderable = true;\n var rect = maskObject.getBounds();\n this.roundFrameToPixels(rect, renderTextureSystem.current ? renderTextureSystem.current.resolution : renderer.resolution, renderTextureSystem.sourceFrame, renderTextureSystem.destinationFrame, renderer.projection.transform);\n maskObject.renderable = false;\n if (prevData) {\n rect.fit(prevData);\n }\n maskData._scissorRectLocal = rect;\n };\n ScissorSystem.isMatrixRotated = function (matrix) {\n if (!matrix) {\n return false;\n }\n var a = matrix.a, b = matrix.b, c = matrix.c, d = matrix.d;\n // Skip if skew/rotation present in matrix, except for multiple of 90° rotation. If rotation\n // is a multiple of 90°, then either pair of (b,c) or (a,d) will be (0,0).\n return ((Math.abs(b) > 1e-4 || Math.abs(c) > 1e-4)\n && (Math.abs(a) > 1e-4 || Math.abs(d) > 1e-4));\n };\n /**\n * Test, whether the object can be scissor mask with current renderer projection.\n * Calls \"calcScissorRect()\" if its true.\n * @param maskData mask data\n * @returns whether Whether the object can be scissor mask\n */\n ScissorSystem.prototype.testScissor = function (maskData) {\n var maskObject = maskData.maskObject;\n if (!maskObject.isFastRect || !maskObject.isFastRect()) {\n return false;\n }\n if (ScissorSystem.isMatrixRotated(maskObject.worldTransform)) {\n return false;\n }\n if (ScissorSystem.isMatrixRotated(this.renderer.projection.transform)) {\n return false;\n }\n this.calcScissorRect(maskData);\n var rect = maskData._scissorRectLocal;\n return rect.width > 0 && rect.height > 0;\n };\n ScissorSystem.prototype.roundFrameToPixels = function (frame, resolution, bindingSourceFrame, bindingDestinationFrame, transform) {\n if (ScissorSystem.isMatrixRotated(transform)) {\n return;\n }\n transform = transform ? tempMatrix$1.copyFrom(transform) : tempMatrix$1.identity();\n // Get forward transform from world space to screen space\n transform\n .translate(-bindingSourceFrame.x, -bindingSourceFrame.y)\n .scale(bindingDestinationFrame.width / bindingSourceFrame.width, bindingDestinationFrame.height / bindingSourceFrame.height)\n .translate(bindingDestinationFrame.x, bindingDestinationFrame.y);\n // Convert frame to screen space\n this.renderer.filter.transformAABB(transform, frame);\n frame.fit(bindingDestinationFrame);\n frame.x = Math.round(frame.x * resolution);\n frame.y = Math.round(frame.y * resolution);\n frame.width = Math.round(frame.width * resolution);\n frame.height = Math.round(frame.height * resolution);\n };\n /**\n * Applies the Mask and adds it to the current stencil stack.\n *\n * @author alvin\n * @param maskData - The mask data.\n */\n ScissorSystem.prototype.push = function (maskData) {\n if (!maskData._scissorRectLocal) {\n this.calcScissorRect(maskData);\n }\n var gl = this.renderer.gl;\n if (!maskData._scissorRect) {\n gl.enable(gl.SCISSOR_TEST);\n }\n maskData._scissorCounter++;\n maskData._scissorRect = maskData._scissorRectLocal;\n this._useCurrent();\n };\n /**\n * This should be called after a mask is popped off the mask stack. It will rebind the scissor box to be latest with the\n * last mask in the stack.\n *\n * This can also be called when you directly modify the scissor box and want to restore PixiJS state.\n */\n ScissorSystem.prototype.pop = function () {\n var gl = this.renderer.gl;\n if (this.getStackLength() > 0) {\n this._useCurrent();\n }\n else {\n gl.disable(gl.SCISSOR_TEST);\n }\n };\n /**\n * Setup renderer to use the current scissor data.\n * @private\n */\n ScissorSystem.prototype._useCurrent = function () {\n var rect = this.maskStack[this.maskStack.length - 1]._scissorRect;\n var y;\n if (this.renderer.renderTexture.current) {\n y = rect.y;\n }\n else {\n // flipY. In future we'll have it over renderTextures as an option\n y = this.renderer.height - rect.height - rect.y;\n }\n this.renderer.gl.scissor(rect.x, y, rect.width, rect.height);\n };\n return ScissorSystem;\n}(AbstractMaskSystem));\n\n/**\n * System plugin to the renderer to manage stencils (used for masks).\n *\n * @memberof PIXI\n */\nvar StencilSystem = /** @class */ (function (_super) {\n __extends(StencilSystem, _super);\n /**\n * @param renderer - The renderer this System works for.\n */\n function StencilSystem(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.glConst = WebGLRenderingContext.STENCIL_TEST;\n return _this;\n }\n StencilSystem.prototype.getStackLength = function () {\n var maskData = this.maskStack[this.maskStack.length - 1];\n if (maskData) {\n return maskData._stencilCounter;\n }\n return 0;\n };\n /**\n * Applies the Mask and adds it to the current stencil stack.\n *\n * @param maskData - The mask data\n */\n StencilSystem.prototype.push = function (maskData) {\n var maskObject = maskData.maskObject;\n var gl = this.renderer.gl;\n var prevMaskCount = maskData._stencilCounter;\n if (prevMaskCount === 0) {\n // force use stencil texture in current framebuffer\n this.renderer.framebuffer.forceStencil();\n gl.clearStencil(0);\n gl.clear(gl.STENCIL_BUFFER_BIT);\n gl.enable(gl.STENCIL_TEST);\n }\n maskData._stencilCounter++;\n // Increment the reference stencil value where the new mask overlaps with the old ones.\n gl.colorMask(false, false, false, false);\n gl.stencilFunc(gl.EQUAL, prevMaskCount, 0xFFFFFFFF);\n gl.stencilOp(gl.KEEP, gl.KEEP, gl.INCR);\n maskObject.renderable = true;\n maskObject.render(this.renderer);\n this.renderer.batch.flush();\n maskObject.renderable = false;\n this._useCurrent();\n };\n /**\n * Pops stencil mask. MaskData is already removed from stack\n *\n * @param {PIXI.DisplayObject} maskObject - object of popped mask data\n */\n StencilSystem.prototype.pop = function (maskObject) {\n var gl = this.renderer.gl;\n if (this.getStackLength() === 0) {\n // the stack is empty!\n gl.disable(gl.STENCIL_TEST);\n }\n else {\n // Decrement the reference stencil value where the popped mask overlaps with the other ones\n gl.colorMask(false, false, false, false);\n gl.stencilOp(gl.KEEP, gl.KEEP, gl.DECR);\n maskObject.renderable = true;\n maskObject.render(this.renderer);\n this.renderer.batch.flush();\n maskObject.renderable = false;\n this._useCurrent();\n }\n };\n /**\n * Setup renderer to use the current stencil data.\n * @private\n */\n StencilSystem.prototype._useCurrent = function () {\n var gl = this.renderer.gl;\n gl.colorMask(true, true, true, true);\n gl.stencilFunc(gl.EQUAL, this.getStackLength(), 0xFFFFFFFF);\n gl.stencilOp(gl.KEEP, gl.KEEP, gl.KEEP);\n };\n return StencilSystem;\n}(AbstractMaskSystem));\n\n/**\n * System plugin to the renderer to manage the projection matrix.\n *\n * The `projectionMatrix` is a global uniform provided to all shaders. It is used to transform points in world space to\n * normalized device coordinates.\n *\n * @memberof PIXI\n */\nvar ProjectionSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function ProjectionSystem(renderer) {\n this.renderer = renderer;\n this.destinationFrame = null;\n this.sourceFrame = null;\n this.defaultFrame = null;\n this.projectionMatrix = new Matrix();\n this.transform = null;\n }\n /**\n * Updates the projection-matrix based on the sourceFrame → destinationFrame mapping provided.\n *\n * NOTE: It is expected you call `renderer.framebuffer.setViewport(destinationFrame)` after this. This is because\n * the framebuffer viewport converts shader vertex output in normalized device coordinates to window coordinates.\n *\n * NOTE-2: {@link RenderTextureSystem#bind} updates the projection-matrix when you bind a render-texture. It is expected\n * that you dirty the current bindings when calling this manually.\n *\n * @param destinationFrame - The rectangle in the render-target to render the contents into. If rendering to the canvas,\n * the origin is on the top-left; if rendering to a render-texture, the origin is on the bottom-left.\n * @param sourceFrame - The rectangle in world space that contains the contents being rendered.\n * @param resolution - The resolution of the render-target, which is the ratio of\n * world-space (or CSS) pixels to physical pixels.\n * @param root - Whether the render-target is the screen. This is required because rendering to textures\n * is y-flipped (i.e. upside down relative to the screen).\n */\n ProjectionSystem.prototype.update = function (destinationFrame, sourceFrame, resolution, root) {\n this.destinationFrame = destinationFrame || this.destinationFrame || this.defaultFrame;\n this.sourceFrame = sourceFrame || this.sourceFrame || destinationFrame;\n // Calculate object-space to clip-space projection\n this.calculateProjection(this.destinationFrame, this.sourceFrame, resolution, root);\n if (this.transform) {\n this.projectionMatrix.append(this.transform);\n }\n var renderer = this.renderer;\n renderer.globalUniforms.uniforms.projectionMatrix = this.projectionMatrix;\n renderer.globalUniforms.update();\n // this will work for now\n // but would be sweet to stick and even on the global uniforms..\n if (renderer.shader.shader) {\n renderer.shader.syncUniformGroup(renderer.shader.shader.uniforms.globals);\n }\n };\n /**\n * Calculates the `projectionMatrix` to map points inside `sourceFrame` to inside `destinationFrame`.\n *\n * @param destinationFrame - The destination frame in the render-target.\n * @param sourceFrame - The source frame in world space.\n * @param resolution - The render-target's resolution, i.e. ratio of CSS to physical pixels.\n * @param root - Whether rendering into the screen. Otherwise, if rendering to a framebuffer, the projection\n * is y-flipped.\n */\n ProjectionSystem.prototype.calculateProjection = function (_destinationFrame, sourceFrame, _resolution, root) {\n var pm = this.projectionMatrix;\n var sign = !root ? 1 : -1;\n pm.identity();\n pm.a = (1 / sourceFrame.width * 2);\n pm.d = sign * (1 / sourceFrame.height * 2);\n pm.tx = -1 - (sourceFrame.x * pm.a);\n pm.ty = -sign - (sourceFrame.y * pm.d);\n };\n /**\n * Sets the transform of the active render target to the given matrix.\n *\n * @param matrix - The transformation matrix\n */\n ProjectionSystem.prototype.setTransform = function (_matrix) {\n // this._activeRenderTarget.transform = matrix;\n };\n ProjectionSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return ProjectionSystem;\n}());\n\n// Temporary rectangle for assigned sourceFrame or destinationFrame\nvar tempRect = new Rectangle();\n// Temporary rectangle for renderTexture destinationFrame\nvar tempRect2 = new Rectangle();\n/* eslint-disable max-len */\n/**\n * System plugin to the renderer to manage render textures.\n *\n * Should be added after FramebufferSystem\n *\n * ### Frames\n *\n * The `RenderTextureSystem` holds a sourceFrame → destinationFrame projection. The following table explains the different\n * coordinate spaces used:\n *\n * | Frame | Description | Coordinate System |\n * | ---------------------- | ---------------------------------------------------------------- | ------------------------------------------------------- |\n * | sourceFrame | The rectangle inside of which display-objects are being rendered | **World Space**: The origin on the top-left |\n * | destinationFrame | The rectangle in the render-target (canvas or texture) into which contents should be rendered | If rendering to the canvas, this is in screen space and the origin is on the top-left. If rendering to a render-texture, this is in its base-texture's space with the origin on the bottom-left. |\n * | viewportFrame | The framebuffer viewport corresponding to the destination-frame | **Window Coordinates**: The origin is always on the bottom-left. |\n *\n * @memberof PIXI\n */\nvar RenderTextureSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function RenderTextureSystem(renderer) {\n this.renderer = renderer;\n this.clearColor = renderer._backgroundColorRgba;\n this.defaultMaskStack = [];\n this.current = null;\n this.sourceFrame = new Rectangle();\n this.destinationFrame = new Rectangle();\n this.viewportFrame = new Rectangle();\n }\n /**\n * Bind the current render texture.\n *\n * @param renderTexture - RenderTexture to bind, by default its `null` - the screen.\n * @param sourceFrame - Part of world that is mapped to the renderTexture.\n * @param destinationFrame - Part of renderTexture, by default it has the same size as sourceFrame.\n */\n RenderTextureSystem.prototype.bind = function (renderTexture, sourceFrame, destinationFrame) {\n if (renderTexture === void 0) { renderTexture = null; }\n var renderer = this.renderer;\n this.current = renderTexture;\n var baseTexture;\n var framebuffer;\n var resolution;\n if (renderTexture) {\n baseTexture = renderTexture.baseTexture;\n resolution = baseTexture.resolution;\n if (!sourceFrame) {\n tempRect.width = renderTexture.frame.width;\n tempRect.height = renderTexture.frame.height;\n sourceFrame = tempRect;\n }\n if (!destinationFrame) {\n tempRect2.x = renderTexture.frame.x;\n tempRect2.y = renderTexture.frame.y;\n tempRect2.width = sourceFrame.width;\n tempRect2.height = sourceFrame.height;\n destinationFrame = tempRect2;\n }\n framebuffer = baseTexture.framebuffer;\n }\n else {\n resolution = renderer.resolution;\n if (!sourceFrame) {\n tempRect.width = renderer.screen.width;\n tempRect.height = renderer.screen.height;\n sourceFrame = tempRect;\n }\n if (!destinationFrame) {\n destinationFrame = tempRect;\n destinationFrame.width = sourceFrame.width;\n destinationFrame.height = sourceFrame.height;\n }\n }\n var viewportFrame = this.viewportFrame;\n viewportFrame.x = destinationFrame.x * resolution;\n viewportFrame.y = destinationFrame.y * resolution;\n viewportFrame.width = destinationFrame.width * resolution;\n viewportFrame.height = destinationFrame.height * resolution;\n if (!renderTexture) {\n viewportFrame.y = renderer.view.height - (viewportFrame.y + viewportFrame.height);\n }\n viewportFrame.ceil();\n this.renderer.framebuffer.bind(framebuffer, viewportFrame);\n this.renderer.projection.update(destinationFrame, sourceFrame, resolution, !framebuffer);\n if (renderTexture) {\n this.renderer.mask.setMaskStack(baseTexture.maskStack);\n }\n else {\n this.renderer.mask.setMaskStack(this.defaultMaskStack);\n }\n this.sourceFrame.copyFrom(sourceFrame);\n this.destinationFrame.copyFrom(destinationFrame);\n };\n /**\n * Erases the render texture and fills the drawing area with a colour.\n *\n * @param clearColor - The color as rgba, default to use the renderer backgroundColor\n * @param [mask=BUFFER_BITS.COLOR | BUFFER_BITS.DEPTH] - Bitwise OR of masks\n * that indicate the buffers to be cleared, by default COLOR and DEPTH buffers.\n */\n RenderTextureSystem.prototype.clear = function (clearColor, mask) {\n if (this.current) {\n clearColor = clearColor || this.current.baseTexture.clearColor;\n }\n else {\n clearColor = clearColor || this.clearColor;\n }\n var destinationFrame = this.destinationFrame;\n var baseFrame = this.current ? this.current.baseTexture : this.renderer.screen;\n var clearMask = destinationFrame.width !== baseFrame.width || destinationFrame.height !== baseFrame.height;\n if (clearMask) {\n var _a = this.viewportFrame, x = _a.x, y = _a.y, width = _a.width, height = _a.height;\n x = Math.round(x);\n y = Math.round(y);\n width = Math.round(width);\n height = Math.round(height);\n // TODO: ScissorSystem should cache whether the scissor test is enabled or not.\n this.renderer.gl.enable(this.renderer.gl.SCISSOR_TEST);\n this.renderer.gl.scissor(x, y, width, height);\n }\n this.renderer.framebuffer.clear(clearColor[0], clearColor[1], clearColor[2], clearColor[3], mask);\n if (clearMask) {\n // Restore the scissor box\n this.renderer.scissor.pop();\n }\n };\n RenderTextureSystem.prototype.resize = function () {\n // resize the root only!\n this.bind(null);\n };\n /** Resets render-texture state. */\n RenderTextureSystem.prototype.reset = function () {\n this.bind(null);\n };\n RenderTextureSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return RenderTextureSystem;\n}());\n\nfunction uboUpdate(_ud, _uv, _renderer, _syncData, buffer) {\n _renderer.buffer.update(buffer);\n}\n// cv = CachedValue\n// v = value\n// ud = uniformData\n// uv = uniformValue\n// l = location\nvar UBO_TO_SINGLE_SETTERS = {\n float: \"\\n data[offset] = v;\\n \",\n vec2: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n \",\n vec3: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n data[offset+2] = v[2];\\n\\n \",\n vec4: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n data[offset+2] = v[2];\\n data[offset+3] = v[3];\\n \",\n mat2: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n\\n data[offset+4] = v[2];\\n data[offset+5] = v[3];\\n \",\n mat3: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n data[offset+2] = v[2];\\n\\n data[offset + 4] = v[3];\\n data[offset + 5] = v[4];\\n data[offset + 6] = v[5];\\n\\n data[offset + 8] = v[6];\\n data[offset + 9] = v[7];\\n data[offset + 10] = v[8];\\n \",\n mat4: \"\\n for(var i = 0; i < 16; i++)\\n {\\n data[offset + i] = v[i];\\n }\\n \"\n};\nvar GLSL_TO_STD40_SIZE = {\n float: 4,\n vec2: 8,\n vec3: 12,\n vec4: 16,\n int: 4,\n ivec2: 8,\n ivec3: 12,\n ivec4: 16,\n uint: 4,\n uvec2: 8,\n uvec3: 12,\n uvec4: 16,\n bool: 4,\n bvec2: 8,\n bvec3: 12,\n bvec4: 16,\n mat2: 16 * 2,\n mat3: 16 * 3,\n mat4: 16 * 4,\n};\n/**\n * @ignore\n *\n * logic originally from here: https://github.com/sketchpunk/FunWithWebGL2/blob/master/lesson_022/Shaders.js\n * rewrote it, but this was a great starting point to get a solid understanding of whats going on :)\n *\n * @param uniformData\n */\nfunction createUBOElements(uniformData) {\n var uboElements = uniformData.map(function (data) {\n return ({\n data: data,\n offset: 0,\n dataLen: 0,\n dirty: 0\n });\n });\n var size = 0;\n var chunkSize = 0;\n var offset = 0;\n for (var i = 0; i < uboElements.length; i++) {\n var uboElement = uboElements[i];\n size = GLSL_TO_STD40_SIZE[uboElement.data.type];\n if (uboElement.data.size > 1) {\n size = Math.max(size, 16) * uboElement.data.size;\n }\n uboElement.dataLen = size;\n // add some size offset..\n // must align to the nearest 16 bytes or internally nearest round size\n if (chunkSize % size !== 0 && chunkSize < 16) {\n // diff required to line up..\n var lineUpValue = (chunkSize % size) % 16;\n chunkSize += lineUpValue;\n offset += lineUpValue;\n }\n if ((chunkSize + size) > 16) {\n offset = Math.ceil(offset / 16) * 16;\n uboElement.offset = offset;\n offset += size;\n chunkSize = size;\n }\n else {\n uboElement.offset = offset;\n chunkSize += size;\n offset += size;\n }\n }\n offset = Math.ceil(offset / 16) * 16;\n return { uboElements: uboElements, size: offset };\n}\nfunction getUBOData(uniforms, uniformData) {\n var usedUniformDatas = [];\n // build..\n for (var i in uniforms) {\n if (uniformData[i]) {\n usedUniformDatas.push(uniformData[i]);\n }\n }\n // sort them out by index!\n usedUniformDatas.sort(function (a, b) { return a.index - b.index; });\n return usedUniformDatas;\n}\nfunction generateUniformBufferSync(group, uniformData) {\n if (!group.autoManage) {\n // if the group is nott automatically managed, we don't need to generate a special function for it...\n return { size: 0, syncFunc: uboUpdate };\n }\n var usedUniformDatas = getUBOData(group.uniforms, uniformData);\n var _a = createUBOElements(usedUniformDatas), uboElements = _a.uboElements, size = _a.size;\n var funcFragments = [\"\\n var v = null;\\n var v2 = null;\\n var cv = null;\\n var t = 0;\\n var gl = renderer.gl\\n var index = 0;\\n var data = buffer.data;\\n \"];\n for (var i = 0; i < uboElements.length; i++) {\n var uboElement = uboElements[i];\n var uniform = group.uniforms[uboElement.data.name];\n var name = uboElement.data.name;\n var parsed = false;\n for (var j = 0; j < uniformParsers.length; j++) {\n var uniformParser = uniformParsers[j];\n if (uniformParser.codeUbo && uniformParser.test(uboElement.data, uniform)) {\n funcFragments.push(\"offset = \" + uboElement.offset / 4 + \";\", uniformParsers[j].codeUbo(uboElement.data.name, uniform));\n parsed = true;\n break;\n }\n }\n if (!parsed) {\n if (uboElement.data.size > 1) {\n var size_1 = mapSize(uboElement.data.type);\n var rowSize = Math.max(GLSL_TO_STD40_SIZE[uboElement.data.type] / 16, 1);\n var elementSize = size_1 / rowSize;\n var remainder = (4 - (elementSize % 4)) % 4;\n funcFragments.push(\"\\n cv = ud.\" + name + \".value;\\n v = uv.\" + name + \";\\n offset = \" + uboElement.offset / 4 + \";\\n\\n t = 0;\\n\\n for(var i=0; i < \" + uboElement.data.size * rowSize + \"; i++)\\n {\\n for(var j = 0; j < \" + elementSize + \"; j++)\\n {\\n data[offset++] = v[t++];\\n }\\n offset += \" + remainder + \";\\n }\\n\\n \");\n }\n else {\n var template = UBO_TO_SINGLE_SETTERS[uboElement.data.type];\n funcFragments.push(\"\\n cv = ud.\" + name + \".value;\\n v = uv.\" + name + \";\\n offset = \" + uboElement.offset / 4 + \";\\n \" + template + \";\\n \");\n }\n }\n }\n funcFragments.push(\"\\n renderer.buffer.update(buffer);\\n \");\n return {\n size: size,\n // eslint-disable-next-line no-new-func\n syncFunc: new Function('ud', 'uv', 'renderer', 'syncData', 'buffer', funcFragments.join('\\n'))\n };\n}\n\n/**\n * @private\n */\nvar IGLUniformData = /** @class */ (function () {\n function IGLUniformData() {\n }\n return IGLUniformData;\n}());\n/**\n * Helper class to create a WebGL Program\n *\n * @memberof PIXI\n */\nvar GLProgram = /** @class */ (function () {\n /**\n * Makes a new Pixi program.\n *\n * @param program - webgl program\n * @param uniformData - uniforms\n */\n function GLProgram(program, uniformData) {\n this.program = program;\n this.uniformData = uniformData;\n this.uniformGroups = {};\n this.uniformDirtyGroups = {};\n this.uniformBufferBindings = {};\n }\n /** Destroys this program. */\n GLProgram.prototype.destroy = function () {\n this.uniformData = null;\n this.uniformGroups = null;\n this.uniformDirtyGroups = null;\n this.uniformBufferBindings = null;\n this.program = null;\n };\n return GLProgram;\n}());\n\n/**\n * returns the attribute data from the program\n * @private\n *\n * @param {WebGLProgram} [program] - the WebGL program\n * @param {WebGLRenderingContext} [gl] - the WebGL context\n *\n * @returns {object} the attribute data for this program\n */\nfunction getAttributeData(program, gl) {\n var attributes = {};\n var totalAttributes = gl.getProgramParameter(program, gl.ACTIVE_ATTRIBUTES);\n for (var i = 0; i < totalAttributes; i++) {\n var attribData = gl.getActiveAttrib(program, i);\n if (attribData.name.indexOf('gl_') === 0) {\n continue;\n }\n var type = mapType(gl, attribData.type);\n var data = {\n type: type,\n name: attribData.name,\n size: mapSize(type),\n location: gl.getAttribLocation(program, attribData.name),\n };\n attributes[attribData.name] = data;\n }\n return attributes;\n}\n\n/**\n * returns the uniform data from the program\n * @private\n *\n * @param program - the webgl program\n * @param gl - the WebGL context\n *\n * @returns {object} the uniform data for this program\n */\nfunction getUniformData(program, gl) {\n var uniforms = {};\n var totalUniforms = gl.getProgramParameter(program, gl.ACTIVE_UNIFORMS);\n for (var i = 0; i < totalUniforms; i++) {\n var uniformData = gl.getActiveUniform(program, i);\n var name = uniformData.name.replace(/\\[.*?\\]$/, '');\n var isArray = !!(uniformData.name.match(/\\[.*?\\]$/));\n var type = mapType(gl, uniformData.type);\n uniforms[name] = {\n name: name,\n index: i,\n type: type,\n size: uniformData.size,\n isArray: isArray,\n value: defaultValue(type, uniformData.size),\n };\n }\n return uniforms;\n}\n\n/**\n * generates a WebGL Program object from a high level Pixi Program.\n *\n * @param gl - a rendering context on which to generate the program\n * @param program - the high level Pixi Program.\n */\nfunction generateProgram(gl, program) {\n var glVertShader = compileShader(gl, gl.VERTEX_SHADER, program.vertexSrc);\n var glFragShader = compileShader(gl, gl.FRAGMENT_SHADER, program.fragmentSrc);\n var webGLProgram = gl.createProgram();\n gl.attachShader(webGLProgram, glVertShader);\n gl.attachShader(webGLProgram, glFragShader);\n gl.linkProgram(webGLProgram);\n if (!gl.getProgramParameter(webGLProgram, gl.LINK_STATUS)) {\n logProgramError(gl, webGLProgram, glVertShader, glFragShader);\n }\n program.attributeData = getAttributeData(webGLProgram, gl);\n program.uniformData = getUniformData(webGLProgram, gl);\n // GLSL 1.00: bind attributes sorted by name in ascending order\n // GLSL 3.00: don't change the attribute locations that where chosen by the compiler\n // or assigned by the layout specifier in the shader source code\n if (!(/^[ \\t]*#[ \\t]*version[ \\t]+300[ \\t]+es[ \\t]*$/m).test(program.vertexSrc)) {\n var keys = Object.keys(program.attributeData);\n keys.sort(function (a, b) { return (a > b) ? 1 : -1; }); // eslint-disable-line no-confusing-arrow\n for (var i = 0; i < keys.length; i++) {\n program.attributeData[keys[i]].location = i;\n gl.bindAttribLocation(webGLProgram, i, keys[i]);\n }\n gl.linkProgram(webGLProgram);\n }\n gl.deleteShader(glVertShader);\n gl.deleteShader(glFragShader);\n var uniformData = {};\n for (var i in program.uniformData) {\n var data = program.uniformData[i];\n uniformData[i] = {\n location: gl.getUniformLocation(webGLProgram, i),\n value: defaultValue(data.type, data.size),\n };\n }\n var glProgram = new GLProgram(webGLProgram, uniformData);\n return glProgram;\n}\n\nvar UID$4 = 0;\n// default sync data so we don't create a new one each time!\nvar defaultSyncData = { textureCount: 0, uboCount: 0 };\n/**\n * System plugin to the renderer to manage shaders.\n *\n * @memberof PIXI\n */\nvar ShaderSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function ShaderSystem(renderer) {\n this.destroyed = false;\n this.renderer = renderer;\n // Validation check that this environment support `new Function`\n this.systemCheck();\n this.gl = null;\n this.shader = null;\n this.program = null;\n this.cache = {};\n this._uboCache = {};\n this.id = UID$4++;\n }\n /**\n * Overrideable function by `@pixi/unsafe-eval` to silence\n * throwing an error if platform doesn't support unsafe-evals.\n *\n * @private\n */\n ShaderSystem.prototype.systemCheck = function () {\n if (!unsafeEvalSupported()) {\n throw new Error('Current environment does not allow unsafe-eval, '\n + 'please use @pixi/unsafe-eval module to enable support.');\n }\n };\n ShaderSystem.prototype.contextChange = function (gl) {\n this.gl = gl;\n this.reset();\n };\n /**\n * Changes the current shader to the one given in parameter.\n *\n * @param shader - the new shader\n * @param dontSync - false if the shader should automatically sync its uniforms.\n * @returns the glProgram that belongs to the shader.\n */\n ShaderSystem.prototype.bind = function (shader, dontSync) {\n shader.uniforms.globals = this.renderer.globalUniforms;\n var program = shader.program;\n var glProgram = program.glPrograms[this.renderer.CONTEXT_UID] || this.generateProgram(shader);\n this.shader = shader;\n // TODO - some current Pixi plugins bypass this.. so it not safe to use yet..\n if (this.program !== program) {\n this.program = program;\n this.gl.useProgram(glProgram.program);\n }\n if (!dontSync) {\n defaultSyncData.textureCount = 0;\n defaultSyncData.uboCount = 0;\n this.syncUniformGroup(shader.uniformGroup, defaultSyncData);\n }\n return glProgram;\n };\n /**\n * Uploads the uniforms values to the currently bound shader.\n *\n * @param uniforms - the uniforms values that be applied to the current shader\n */\n ShaderSystem.prototype.setUniforms = function (uniforms) {\n var shader = this.shader.program;\n var glProgram = shader.glPrograms[this.renderer.CONTEXT_UID];\n shader.syncUniforms(glProgram.uniformData, uniforms, this.renderer);\n };\n /* eslint-disable @typescript-eslint/explicit-module-boundary-types */\n /**\n * Syncs uniforms on the group\n *\n * @param group - the uniform group to sync\n * @param syncData - this is data that is passed to the sync function and any nested sync functions\n */\n ShaderSystem.prototype.syncUniformGroup = function (group, syncData) {\n var glProgram = this.getGlProgram();\n if (!group.static || group.dirtyId !== glProgram.uniformDirtyGroups[group.id]) {\n glProgram.uniformDirtyGroups[group.id] = group.dirtyId;\n this.syncUniforms(group, glProgram, syncData);\n }\n };\n /**\n * Overrideable by the @pixi/unsafe-eval package to use static syncUniforms instead.\n */\n ShaderSystem.prototype.syncUniforms = function (group, glProgram, syncData) {\n var syncFunc = group.syncUniforms[this.shader.program.id] || this.createSyncGroups(group);\n syncFunc(glProgram.uniformData, group.uniforms, this.renderer, syncData);\n };\n ShaderSystem.prototype.createSyncGroups = function (group) {\n var id = this.getSignature(group, this.shader.program.uniformData, 'u');\n if (!this.cache[id]) {\n this.cache[id] = generateUniformsSync(group, this.shader.program.uniformData);\n }\n group.syncUniforms[this.shader.program.id] = this.cache[id];\n return group.syncUniforms[this.shader.program.id];\n };\n /**\n * Syncs uniform buffers\n *\n * @param group - the uniform buffer group to sync\n * @param name - the name of the uniform buffer\n */\n ShaderSystem.prototype.syncUniformBufferGroup = function (group, name) {\n var glProgram = this.getGlProgram();\n if (!group.static || group.dirtyId !== 0 || !glProgram.uniformGroups[group.id]) {\n group.dirtyId = 0;\n var syncFunc = glProgram.uniformGroups[group.id]\n || this.createSyncBufferGroup(group, glProgram, name);\n // TODO wrap update in a cache??\n group.buffer.update();\n syncFunc(glProgram.uniformData, group.uniforms, this.renderer, defaultSyncData, group.buffer);\n }\n this.renderer.buffer.bindBufferBase(group.buffer, glProgram.uniformBufferBindings[name]);\n };\n /**\n * Will create a function that uploads a uniform buffer using the STD140 standard.\n * The upload function will then be cached for future calls\n * If a group is manually managed, then a simple upload function is generated\n *\n * @param group - the uniform buffer group to sync\n * @param glProgram - the gl program to attach the uniform bindings to\n * @param name - the name of the uniform buffer (must exist on the shader)\n */\n ShaderSystem.prototype.createSyncBufferGroup = function (group, glProgram, name) {\n var gl = this.renderer.gl;\n this.renderer.buffer.bind(group.buffer);\n // bind them...\n var uniformBlockIndex = this.gl.getUniformBlockIndex(glProgram.program, name);\n glProgram.uniformBufferBindings[name] = this.shader.uniformBindCount;\n gl.uniformBlockBinding(glProgram.program, uniformBlockIndex, this.shader.uniformBindCount);\n this.shader.uniformBindCount++;\n var id = this.getSignature(group, this.shader.program.uniformData, 'ubo');\n var uboData = this._uboCache[id];\n if (!uboData) {\n uboData = this._uboCache[id] = generateUniformBufferSync(group, this.shader.program.uniformData);\n }\n if (group.autoManage) {\n var data = new Float32Array(uboData.size / 4);\n group.buffer.update(data);\n }\n glProgram.uniformGroups[group.id] = uboData.syncFunc;\n return glProgram.uniformGroups[group.id];\n };\n /**\n * Takes a uniform group and data and generates a unique signature for them.\n *\n * @param group - The uniform group to get signature of\n * @param uniformData - Uniform information generated by the shader\n * @returns Unique signature of the uniform group\n */\n ShaderSystem.prototype.getSignature = function (group, uniformData, preFix) {\n var uniforms = group.uniforms;\n var strings = [preFix + \"-\"];\n for (var i in uniforms) {\n strings.push(i);\n if (uniformData[i]) {\n strings.push(uniformData[i].type);\n }\n }\n return strings.join('-');\n };\n /**\n * Returns the underlying GLShade rof the currently bound shader.\n *\n * This can be handy for when you to have a little more control over the setting of your uniforms.\n *\n * @return The glProgram for the currently bound Shader for this context\n */\n ShaderSystem.prototype.getGlProgram = function () {\n if (this.shader) {\n return this.shader.program.glPrograms[this.renderer.CONTEXT_UID];\n }\n return null;\n };\n /**\n * Generates a glProgram version of the Shader provided.\n *\n * @param shader - The shader that the glProgram will be based on.\n * @return A shiny new glProgram!\n */\n ShaderSystem.prototype.generateProgram = function (shader) {\n var gl = this.gl;\n var program = shader.program;\n var glProgram = generateProgram(gl, program);\n program.glPrograms[this.renderer.CONTEXT_UID] = glProgram;\n return glProgram;\n };\n /** Resets ShaderSystem state, does not affect WebGL state. */\n ShaderSystem.prototype.reset = function () {\n this.program = null;\n this.shader = null;\n };\n /** Destroys this System and removes all its textures. */\n ShaderSystem.prototype.destroy = function () {\n this.renderer = null;\n // TODO implement destroy method for ShaderSystem\n this.destroyed = true;\n };\n return ShaderSystem;\n}());\n\n/**\n * Maps gl blend combinations to WebGL.\n *\n * @memberof PIXI\n * @function mapWebGLBlendModesToPixi\n * @private\n * @param {WebGLRenderingContext} gl - The rendering context.\n * @param {number[][]} [array=[]] - The array to output into.\n * @return {number[][]} Mapped modes.\n */\nfunction mapWebGLBlendModesToPixi(gl, array) {\n if (array === void 0) { array = []; }\n // TODO - premultiply alpha would be different.\n // add a boolean for that!\n array[BLEND_MODES.NORMAL] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.ADD] = [gl.ONE, gl.ONE];\n array[BLEND_MODES.MULTIPLY] = [gl.DST_COLOR, gl.ONE_MINUS_SRC_ALPHA, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.SCREEN] = [gl.ONE, gl.ONE_MINUS_SRC_COLOR, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.OVERLAY] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DARKEN] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.LIGHTEN] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.COLOR_DODGE] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.COLOR_BURN] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.HARD_LIGHT] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.SOFT_LIGHT] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DIFFERENCE] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.EXCLUSION] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.HUE] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.SATURATION] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.COLOR] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.LUMINOSITY] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.NONE] = [0, 0];\n // not-premultiplied blend modes\n array[BLEND_MODES.NORMAL_NPM] = [gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.ADD_NPM] = [gl.SRC_ALPHA, gl.ONE, gl.ONE, gl.ONE];\n array[BLEND_MODES.SCREEN_NPM] = [gl.SRC_ALPHA, gl.ONE_MINUS_SRC_COLOR, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n // composite operations\n array[BLEND_MODES.SRC_IN] = [gl.DST_ALPHA, gl.ZERO];\n array[BLEND_MODES.SRC_OUT] = [gl.ONE_MINUS_DST_ALPHA, gl.ZERO];\n array[BLEND_MODES.SRC_ATOP] = [gl.DST_ALPHA, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DST_OVER] = [gl.ONE_MINUS_DST_ALPHA, gl.ONE];\n array[BLEND_MODES.DST_IN] = [gl.ZERO, gl.SRC_ALPHA];\n array[BLEND_MODES.DST_OUT] = [gl.ZERO, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DST_ATOP] = [gl.ONE_MINUS_DST_ALPHA, gl.SRC_ALPHA];\n array[BLEND_MODES.XOR] = [gl.ONE_MINUS_DST_ALPHA, gl.ONE_MINUS_SRC_ALPHA];\n // SUBTRACT from flash\n array[BLEND_MODES.SUBTRACT] = [gl.ONE, gl.ONE, gl.ONE, gl.ONE, gl.FUNC_REVERSE_SUBTRACT, gl.FUNC_ADD];\n return array;\n}\n\nvar BLEND$1 = 0;\nvar OFFSET$1 = 1;\nvar CULLING$1 = 2;\nvar DEPTH_TEST$1 = 3;\nvar WINDING$1 = 4;\nvar DEPTH_MASK$1 = 5;\n/**\n * System plugin to the renderer to manage WebGL state machines.\n *\n * @memberof PIXI\n */\nvar StateSystem = /** @class */ (function () {\n function StateSystem() {\n this.gl = null;\n this.stateId = 0;\n this.polygonOffset = 0;\n this.blendMode = BLEND_MODES.NONE;\n this._blendEq = false;\n // map functions for when we set state..\n this.map = [];\n this.map[BLEND$1] = this.setBlend;\n this.map[OFFSET$1] = this.setOffset;\n this.map[CULLING$1] = this.setCullFace;\n this.map[DEPTH_TEST$1] = this.setDepthTest;\n this.map[WINDING$1] = this.setFrontFace;\n this.map[DEPTH_MASK$1] = this.setDepthMask;\n this.checks = [];\n this.defaultState = new State();\n this.defaultState.blend = true;\n }\n StateSystem.prototype.contextChange = function (gl) {\n this.gl = gl;\n this.blendModes = mapWebGLBlendModesToPixi(gl);\n this.set(this.defaultState);\n this.reset();\n };\n /**\n * Sets the current state\n *\n * @param {*} state - The state to set.\n */\n StateSystem.prototype.set = function (state) {\n state = state || this.defaultState;\n // TODO maybe to an object check? ( this.state === state )?\n if (this.stateId !== state.data) {\n var diff = this.stateId ^ state.data;\n var i = 0;\n // order from least to most common\n while (diff) {\n if (diff & 1) {\n // state change!\n this.map[i].call(this, !!(state.data & (1 << i)));\n }\n diff = diff >> 1;\n i++;\n }\n this.stateId = state.data;\n }\n // based on the above settings we check for specific modes..\n // for example if blend is active we check and set the blend modes\n // or of polygon offset is active we check the poly depth.\n for (var i = 0; i < this.checks.length; i++) {\n this.checks[i](this, state);\n }\n };\n /**\n * Sets the state, when previous state is unknown.\n *\n * @param {*} state - The state to set\n */\n StateSystem.prototype.forceState = function (state) {\n state = state || this.defaultState;\n for (var i = 0; i < this.map.length; i++) {\n this.map[i].call(this, !!(state.data & (1 << i)));\n }\n for (var i = 0; i < this.checks.length; i++) {\n this.checks[i](this, state);\n }\n this.stateId = state.data;\n };\n /**\n * Sets whether to enable or disable blending.\n *\n * @param value - Turn on or off WebGl blending.\n */\n StateSystem.prototype.setBlend = function (value) {\n this.updateCheck(StateSystem.checkBlendMode, value);\n this.gl[value ? 'enable' : 'disable'](this.gl.BLEND);\n };\n /**\n * Sets whether to enable or disable polygon offset fill.\n *\n * @param value - Turn on or off webgl polygon offset testing.\n */\n StateSystem.prototype.setOffset = function (value) {\n this.updateCheck(StateSystem.checkPolygonOffset, value);\n this.gl[value ? 'enable' : 'disable'](this.gl.POLYGON_OFFSET_FILL);\n };\n /**\n * Sets whether to enable or disable depth test.\n *\n * @param value - Turn on or off webgl depth testing.\n */\n StateSystem.prototype.setDepthTest = function (value) {\n this.gl[value ? 'enable' : 'disable'](this.gl.DEPTH_TEST);\n };\n /**\n * Sets whether to enable or disable depth mask.\n *\n * @param value - Turn on or off webgl depth mask.\n */\n StateSystem.prototype.setDepthMask = function (value) {\n this.gl.depthMask(value);\n };\n /**\n * Sets whether to enable or disable cull face.\n *\n * @param {boolean} value - Turn on or off webgl cull face.\n */\n StateSystem.prototype.setCullFace = function (value) {\n this.gl[value ? 'enable' : 'disable'](this.gl.CULL_FACE);\n };\n /**\n * Sets the gl front face.\n *\n * @param {boolean} value - true is clockwise and false is counter-clockwise\n */\n StateSystem.prototype.setFrontFace = function (value) {\n this.gl.frontFace(this.gl[value ? 'CW' : 'CCW']);\n };\n /**\n * Sets the blend mode.\n *\n * @param {number} value - The blend mode to set to.\n */\n StateSystem.prototype.setBlendMode = function (value) {\n if (value === this.blendMode) {\n return;\n }\n this.blendMode = value;\n var mode = this.blendModes[value];\n var gl = this.gl;\n if (mode.length === 2) {\n gl.blendFunc(mode[0], mode[1]);\n }\n else {\n gl.blendFuncSeparate(mode[0], mode[1], mode[2], mode[3]);\n }\n if (mode.length === 6) {\n this._blendEq = true;\n gl.blendEquationSeparate(mode[4], mode[5]);\n }\n else if (this._blendEq) {\n this._blendEq = false;\n gl.blendEquationSeparate(gl.FUNC_ADD, gl.FUNC_ADD);\n }\n };\n /**\n * Sets the polygon offset.\n *\n * @param {number} value - the polygon offset\n * @param {number} scale - the polygon offset scale\n */\n StateSystem.prototype.setPolygonOffset = function (value, scale) {\n this.gl.polygonOffset(value, scale);\n };\n // used\n /** Resets all the logic and disables the VAOs. */\n StateSystem.prototype.reset = function () {\n this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL, false);\n this.forceState(this.defaultState);\n this._blendEq = true;\n this.blendMode = -1;\n this.setBlendMode(0);\n };\n /**\n * Checks to see which updates should be checked based on which settings have been activated.\n *\n * For example, if blend is enabled then we should check the blend modes each time the state is changed\n * or if polygon fill is activated then we need to check if the polygon offset changes.\n * The idea is that we only check what we have too.\n *\n * @param func - the checking function to add or remove\n * @param value - should the check function be added or removed.\n */\n StateSystem.prototype.updateCheck = function (func, value) {\n var index = this.checks.indexOf(func);\n if (value && index === -1) {\n this.checks.push(func);\n }\n else if (!value && index !== -1) {\n this.checks.splice(index, 1);\n }\n };\n /**\n * A private little wrapper function that we call to check the blend mode.\n *\n * @param System - the System to perform the state check on\n * @param state - the state that the blendMode will pulled from\n */\n StateSystem.checkBlendMode = function (system, state) {\n system.setBlendMode(state.blendMode);\n };\n /**\n * A private little wrapper function that we call to check the polygon offset.\n *\n * @param System - the System to perform the state check on\n * @param state - the state that the blendMode will pulled from\n */\n StateSystem.checkPolygonOffset = function (system, state) {\n system.setPolygonOffset(1, state.polygonOffset);\n };\n /**\n * @ignore\n */\n StateSystem.prototype.destroy = function () {\n this.gl = null;\n };\n return StateSystem;\n}());\n\n/**\n * System plugin to the renderer to manage texture garbage collection on the GPU,\n * ensuring that it does not get clogged up with textures that are no longer being used.\n *\n * @memberof PIXI\n */\nvar TextureGCSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function TextureGCSystem(renderer) {\n this.renderer = renderer;\n this.count = 0;\n this.checkCount = 0;\n this.maxIdle = settings.GC_MAX_IDLE;\n this.checkCountMax = settings.GC_MAX_CHECK_COUNT;\n this.mode = settings.GC_MODE;\n }\n /**\n * Checks to see when the last time a texture was used\n * if the texture has not been used for a specified amount of time it will be removed from the GPU\n */\n TextureGCSystem.prototype.postrender = function () {\n if (!this.renderer.renderingToScreen) {\n return;\n }\n this.count++;\n if (this.mode === GC_MODES.MANUAL) {\n return;\n }\n this.checkCount++;\n if (this.checkCount > this.checkCountMax) {\n this.checkCount = 0;\n this.run();\n }\n };\n /**\n * Checks to see when the last time a texture was used\n * if the texture has not been used for a specified amount of time it will be removed from the GPU\n */\n TextureGCSystem.prototype.run = function () {\n var tm = this.renderer.texture;\n var managedTextures = tm.managedTextures;\n var wasRemoved = false;\n for (var i = 0; i < managedTextures.length; i++) {\n var texture = managedTextures[i];\n // only supports non generated textures at the moment!\n if (!texture.framebuffer && this.count - texture.touched > this.maxIdle) {\n tm.destroyTexture(texture, true);\n managedTextures[i] = null;\n wasRemoved = true;\n }\n }\n if (wasRemoved) {\n var j = 0;\n for (var i = 0; i < managedTextures.length; i++) {\n if (managedTextures[i] !== null) {\n managedTextures[j++] = managedTextures[i];\n }\n }\n managedTextures.length = j;\n }\n };\n /**\n * Removes all the textures within the specified displayObject and its children from the GPU\n *\n * @param {PIXI.DisplayObject} displayObject - the displayObject to remove the textures from.\n */\n TextureGCSystem.prototype.unload = function (displayObject) {\n var tm = this.renderer.texture;\n var texture = displayObject._texture;\n // only destroy non generated textures\n if (texture && !texture.framebuffer) {\n tm.destroyTexture(texture);\n }\n for (var i = displayObject.children.length - 1; i >= 0; i--) {\n this.unload(displayObject.children[i]);\n }\n };\n TextureGCSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return TextureGCSystem;\n}());\n\n/**\n * Returns a lookup table that maps each type-format pair to a compatible internal format.\n *\n * @memberof PIXI\n * @function mapTypeAndFormatToInternalFormat\n * @private\n * @param {WebGLRenderingContext} gl - The rendering context.\n * @return {{ [type: number]: { [format: number]: number } }} Lookup table.\n */\nfunction mapTypeAndFormatToInternalFormat(gl) {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x;\n var table;\n if ('WebGL2RenderingContext' in globalThis && gl instanceof globalThis.WebGL2RenderingContext) {\n table = (_a = {},\n _a[TYPES.UNSIGNED_BYTE] = (_b = {},\n _b[FORMATS.RGBA] = gl.RGBA8,\n _b[FORMATS.RGB] = gl.RGB8,\n _b[FORMATS.RG] = gl.RG8,\n _b[FORMATS.RED] = gl.R8,\n _b[FORMATS.RGBA_INTEGER] = gl.RGBA8UI,\n _b[FORMATS.RGB_INTEGER] = gl.RGB8UI,\n _b[FORMATS.RG_INTEGER] = gl.RG8UI,\n _b[FORMATS.RED_INTEGER] = gl.R8UI,\n _b[FORMATS.ALPHA] = gl.ALPHA,\n _b[FORMATS.LUMINANCE] = gl.LUMINANCE,\n _b[FORMATS.LUMINANCE_ALPHA] = gl.LUMINANCE_ALPHA,\n _b),\n _a[TYPES.BYTE] = (_c = {},\n _c[FORMATS.RGBA] = gl.RGBA8_SNORM,\n _c[FORMATS.RGB] = gl.RGB8_SNORM,\n _c[FORMATS.RG] = gl.RG8_SNORM,\n _c[FORMATS.RED] = gl.R8_SNORM,\n _c[FORMATS.RGBA_INTEGER] = gl.RGBA8I,\n _c[FORMATS.RGB_INTEGER] = gl.RGB8I,\n _c[FORMATS.RG_INTEGER] = gl.RG8I,\n _c[FORMATS.RED_INTEGER] = gl.R8I,\n _c),\n _a[TYPES.UNSIGNED_SHORT] = (_d = {},\n _d[FORMATS.RGBA_INTEGER] = gl.RGBA16UI,\n _d[FORMATS.RGB_INTEGER] = gl.RGB16UI,\n _d[FORMATS.RG_INTEGER] = gl.RG16UI,\n _d[FORMATS.RED_INTEGER] = gl.R16UI,\n _d[FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT16,\n _d),\n _a[TYPES.SHORT] = (_e = {},\n _e[FORMATS.RGBA_INTEGER] = gl.RGBA16I,\n _e[FORMATS.RGB_INTEGER] = gl.RGB16I,\n _e[FORMATS.RG_INTEGER] = gl.RG16I,\n _e[FORMATS.RED_INTEGER] = gl.R16I,\n _e),\n _a[TYPES.UNSIGNED_INT] = (_f = {},\n _f[FORMATS.RGBA_INTEGER] = gl.RGBA32UI,\n _f[FORMATS.RGB_INTEGER] = gl.RGB32UI,\n _f[FORMATS.RG_INTEGER] = gl.RG32UI,\n _f[FORMATS.RED_INTEGER] = gl.R32UI,\n _f[FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT24,\n _f),\n _a[TYPES.INT] = (_g = {},\n _g[FORMATS.RGBA_INTEGER] = gl.RGBA32I,\n _g[FORMATS.RGB_INTEGER] = gl.RGB32I,\n _g[FORMATS.RG_INTEGER] = gl.RG32I,\n _g[FORMATS.RED_INTEGER] = gl.R32I,\n _g),\n _a[TYPES.FLOAT] = (_h = {},\n _h[FORMATS.RGBA] = gl.RGBA32F,\n _h[FORMATS.RGB] = gl.RGB32F,\n _h[FORMATS.RG] = gl.RG32F,\n _h[FORMATS.RED] = gl.R32F,\n _h[FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT32F,\n _h),\n _a[TYPES.HALF_FLOAT] = (_j = {},\n _j[FORMATS.RGBA] = gl.RGBA16F,\n _j[FORMATS.RGB] = gl.RGB16F,\n _j[FORMATS.RG] = gl.RG16F,\n _j[FORMATS.RED] = gl.R16F,\n _j),\n _a[TYPES.UNSIGNED_SHORT_5_6_5] = (_k = {},\n _k[FORMATS.RGB] = gl.RGB565,\n _k),\n _a[TYPES.UNSIGNED_SHORT_4_4_4_4] = (_l = {},\n _l[FORMATS.RGBA] = gl.RGBA4,\n _l),\n _a[TYPES.UNSIGNED_SHORT_5_5_5_1] = (_m = {},\n _m[FORMATS.RGBA] = gl.RGB5_A1,\n _m),\n _a[TYPES.UNSIGNED_INT_2_10_10_10_REV] = (_o = {},\n _o[FORMATS.RGBA] = gl.RGB10_A2,\n _o[FORMATS.RGBA_INTEGER] = gl.RGB10_A2UI,\n _o),\n _a[TYPES.UNSIGNED_INT_10F_11F_11F_REV] = (_p = {},\n _p[FORMATS.RGB] = gl.R11F_G11F_B10F,\n _p),\n _a[TYPES.UNSIGNED_INT_5_9_9_9_REV] = (_q = {},\n _q[FORMATS.RGB] = gl.RGB9_E5,\n _q),\n _a[TYPES.UNSIGNED_INT_24_8] = (_r = {},\n _r[FORMATS.DEPTH_STENCIL] = gl.DEPTH24_STENCIL8,\n _r),\n _a[TYPES.FLOAT_32_UNSIGNED_INT_24_8_REV] = (_s = {},\n _s[FORMATS.DEPTH_STENCIL] = gl.DEPTH32F_STENCIL8,\n _s),\n _a);\n }\n else {\n table = (_t = {},\n _t[TYPES.UNSIGNED_BYTE] = (_u = {},\n _u[FORMATS.RGBA] = gl.RGBA,\n _u[FORMATS.RGB] = gl.RGB,\n _u[FORMATS.ALPHA] = gl.ALPHA,\n _u[FORMATS.LUMINANCE] = gl.LUMINANCE,\n _u[FORMATS.LUMINANCE_ALPHA] = gl.LUMINANCE_ALPHA,\n _u),\n _t[TYPES.UNSIGNED_SHORT_5_6_5] = (_v = {},\n _v[FORMATS.RGB] = gl.RGB,\n _v),\n _t[TYPES.UNSIGNED_SHORT_4_4_4_4] = (_w = {},\n _w[FORMATS.RGBA] = gl.RGBA,\n _w),\n _t[TYPES.UNSIGNED_SHORT_5_5_5_1] = (_x = {},\n _x[FORMATS.RGBA] = gl.RGBA,\n _x),\n _t);\n }\n return table;\n}\n\n/**\n * Internal texture for WebGL context.\n *\n * @memberof PIXI\n */\nvar GLTexture = /** @class */ (function () {\n function GLTexture(texture) {\n this.texture = texture;\n this.width = -1;\n this.height = -1;\n this.dirtyId = -1;\n this.dirtyStyleId = -1;\n this.mipmap = false;\n this.wrapMode = 33071;\n this.type = TYPES.UNSIGNED_BYTE;\n this.internalFormat = FORMATS.RGBA;\n this.samplerType = 0;\n }\n return GLTexture;\n}());\n\n/**\n * System plugin to the renderer to manage textures.\n *\n * @memberof PIXI\n */\nvar TextureSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this system works for.\n */\n function TextureSystem(renderer) {\n this.renderer = renderer;\n // TODO set to max textures...\n this.boundTextures = [];\n this.currentLocation = -1;\n this.managedTextures = [];\n this._unknownBoundTextures = false;\n this.unknownTexture = new BaseTexture();\n this.hasIntegerTextures = false;\n }\n /** Sets up the renderer context and necessary buffers. */\n TextureSystem.prototype.contextChange = function () {\n var gl = this.gl = this.renderer.gl;\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n this.webGLVersion = this.renderer.context.webGLVersion;\n this.internalFormats = mapTypeAndFormatToInternalFormat(gl);\n var maxTextures = gl.getParameter(gl.MAX_TEXTURE_IMAGE_UNITS);\n this.boundTextures.length = maxTextures;\n for (var i = 0; i < maxTextures; i++) {\n this.boundTextures[i] = null;\n }\n // TODO move this.. to a nice make empty textures class..\n this.emptyTextures = {};\n var emptyTexture2D = new GLTexture(gl.createTexture());\n gl.bindTexture(gl.TEXTURE_2D, emptyTexture2D.texture);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, new Uint8Array(4));\n this.emptyTextures[gl.TEXTURE_2D] = emptyTexture2D;\n this.emptyTextures[gl.TEXTURE_CUBE_MAP] = new GLTexture(gl.createTexture());\n gl.bindTexture(gl.TEXTURE_CUBE_MAP, this.emptyTextures[gl.TEXTURE_CUBE_MAP].texture);\n for (var i = 0; i < 6; i++) {\n gl.texImage2D(gl.TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);\n }\n gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MAG_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n for (var i = 0; i < this.boundTextures.length; i++) {\n this.bind(null, i);\n }\n };\n /**\n * Bind a texture to a specific location\n *\n * If you want to unbind something, please use `unbind(texture)` instead of `bind(null, textureLocation)`\n *\n * @param texture_ - Texture to bind\n * @param [location=0] - Location to bind at\n */\n TextureSystem.prototype.bind = function (texture, location) {\n if (location === void 0) { location = 0; }\n var gl = this.gl;\n texture = texture === null || texture === void 0 ? void 0 : texture.castToBaseTexture();\n // cannot bind partial texture\n // TODO: report a warning\n if (texture && texture.valid && !texture.parentTextureArray) {\n texture.touched = this.renderer.textureGC.count;\n var glTexture = texture._glTextures[this.CONTEXT_UID] || this.initTexture(texture);\n if (this.boundTextures[location] !== texture) {\n if (this.currentLocation !== location) {\n this.currentLocation = location;\n gl.activeTexture(gl.TEXTURE0 + location);\n }\n gl.bindTexture(texture.target, glTexture.texture);\n }\n if (glTexture.dirtyId !== texture.dirtyId) {\n if (this.currentLocation !== location) {\n this.currentLocation = location;\n gl.activeTexture(gl.TEXTURE0 + location);\n }\n this.updateTexture(texture);\n }\n this.boundTextures[location] = texture;\n }\n else {\n if (this.currentLocation !== location) {\n this.currentLocation = location;\n gl.activeTexture(gl.TEXTURE0 + location);\n }\n gl.bindTexture(gl.TEXTURE_2D, this.emptyTextures[gl.TEXTURE_2D].texture);\n this.boundTextures[location] = null;\n }\n };\n /**\n * Resets texture location and bound textures\n *\n * Actual `bind(null, i)` calls will be performed at next `unbind()` call\n */\n TextureSystem.prototype.reset = function () {\n this._unknownBoundTextures = true;\n this.hasIntegerTextures = false;\n this.currentLocation = -1;\n for (var i = 0; i < this.boundTextures.length; i++) {\n this.boundTextures[i] = this.unknownTexture;\n }\n };\n /**\n * Unbind a texture.\n *\n * @param texture - Texture to bind\n */\n TextureSystem.prototype.unbind = function (texture) {\n var _a = this, gl = _a.gl, boundTextures = _a.boundTextures;\n if (this._unknownBoundTextures) {\n this._unknownBoundTextures = false;\n // someone changed webGL state,\n // we have to be sure that our texture does not appear in multi-texture renderer samplers\n for (var i = 0; i < boundTextures.length; i++) {\n if (boundTextures[i] === this.unknownTexture) {\n this.bind(null, i);\n }\n }\n }\n for (var i = 0; i < boundTextures.length; i++) {\n if (boundTextures[i] === texture) {\n if (this.currentLocation !== i) {\n gl.activeTexture(gl.TEXTURE0 + i);\n this.currentLocation = i;\n }\n gl.bindTexture(texture.target, this.emptyTextures[texture.target].texture);\n boundTextures[i] = null;\n }\n }\n };\n /**\n * Ensures that current boundTextures all have FLOAT sampler type,\n * see {@link PIXI.SAMPLER_TYPES} for explanation.\n *\n * @param maxTextures - number of locations to check\n */\n TextureSystem.prototype.ensureSamplerType = function (maxTextures) {\n var _a = this, boundTextures = _a.boundTextures, hasIntegerTextures = _a.hasIntegerTextures, CONTEXT_UID = _a.CONTEXT_UID;\n if (!hasIntegerTextures) {\n return;\n }\n for (var i = maxTextures - 1; i >= 0; --i) {\n var tex = boundTextures[i];\n if (tex) {\n var glTexture = tex._glTextures[CONTEXT_UID];\n if (glTexture.samplerType !== SAMPLER_TYPES.FLOAT) {\n this.renderer.texture.unbind(tex);\n }\n }\n }\n };\n /**\n * Initialize a texture\n *\n * @private\n * @param texture - Texture to initialize\n */\n TextureSystem.prototype.initTexture = function (texture) {\n var glTexture = new GLTexture(this.gl.createTexture());\n // guarantee an update..\n glTexture.dirtyId = -1;\n texture._glTextures[this.CONTEXT_UID] = glTexture;\n this.managedTextures.push(texture);\n texture.on('dispose', this.destroyTexture, this);\n return glTexture;\n };\n TextureSystem.prototype.initTextureType = function (texture, glTexture) {\n var _a, _b;\n glTexture.internalFormat = (_b = (_a = this.internalFormats[texture.type]) === null || _a === void 0 ? void 0 : _a[texture.format]) !== null && _b !== void 0 ? _b : texture.format;\n if (this.webGLVersion === 2 && texture.type === TYPES.HALF_FLOAT) {\n // TYPES.HALF_FLOAT is WebGL1 HALF_FLOAT_OES\n // we have to convert it to WebGL HALF_FLOAT\n glTexture.type = this.gl.HALF_FLOAT;\n }\n else {\n glTexture.type = texture.type;\n }\n };\n /**\n * Update a texture\n *\n * @private\n * @param {PIXI.BaseTexture} texture - Texture to initialize\n */\n TextureSystem.prototype.updateTexture = function (texture) {\n var glTexture = texture._glTextures[this.CONTEXT_UID];\n if (!glTexture) {\n return;\n }\n var renderer = this.renderer;\n this.initTextureType(texture, glTexture);\n if (texture.resource && texture.resource.upload(renderer, texture, glTexture)) {\n // texture is uploaded, dont do anything!\n if (glTexture.samplerType !== SAMPLER_TYPES.FLOAT) {\n this.hasIntegerTextures = true;\n }\n }\n else {\n // default, renderTexture-like logic\n var width = texture.realWidth;\n var height = texture.realHeight;\n var gl = renderer.gl;\n if (glTexture.width !== width\n || glTexture.height !== height\n || glTexture.dirtyId < 0) {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(texture.target, 0, glTexture.internalFormat, width, height, 0, texture.format, glTexture.type, null);\n }\n }\n // lets only update what changes..\n if (texture.dirtyStyleId !== glTexture.dirtyStyleId) {\n this.updateTextureStyle(texture);\n }\n glTexture.dirtyId = texture.dirtyId;\n };\n /**\n * Deletes the texture from WebGL\n *\n * @private\n * @param texture_ - the texture to destroy\n * @param [skipRemove=false] - Whether to skip removing the texture from the TextureManager.\n */\n TextureSystem.prototype.destroyTexture = function (texture, skipRemove) {\n var gl = this.gl;\n texture = texture.castToBaseTexture();\n if (texture._glTextures[this.CONTEXT_UID]) {\n this.unbind(texture);\n gl.deleteTexture(texture._glTextures[this.CONTEXT_UID].texture);\n texture.off('dispose', this.destroyTexture, this);\n delete texture._glTextures[this.CONTEXT_UID];\n if (!skipRemove) {\n var i = this.managedTextures.indexOf(texture);\n if (i !== -1) {\n removeItems(this.managedTextures, i, 1);\n }\n }\n }\n };\n /**\n * Update texture style such as mipmap flag\n *\n * @private\n * @param {PIXI.BaseTexture} texture - Texture to update\n */\n TextureSystem.prototype.updateTextureStyle = function (texture) {\n var glTexture = texture._glTextures[this.CONTEXT_UID];\n if (!glTexture) {\n return;\n }\n if ((texture.mipmap === MIPMAP_MODES.POW2 || this.webGLVersion !== 2) && !texture.isPowerOfTwo) {\n glTexture.mipmap = false;\n }\n else {\n glTexture.mipmap = texture.mipmap >= 1;\n }\n if (this.webGLVersion !== 2 && !texture.isPowerOfTwo) {\n glTexture.wrapMode = WRAP_MODES.CLAMP;\n }\n else {\n glTexture.wrapMode = texture.wrapMode;\n }\n if (texture.resource && texture.resource.style(this.renderer, texture, glTexture)) ;\n else {\n this.setStyle(texture, glTexture);\n }\n glTexture.dirtyStyleId = texture.dirtyStyleId;\n };\n /**\n * Set style for texture\n *\n * @private\n * @param texture - Texture to update\n * @param glTexture\n */\n TextureSystem.prototype.setStyle = function (texture, glTexture) {\n var gl = this.gl;\n if (glTexture.mipmap && texture.mipmap !== MIPMAP_MODES.ON_MANUAL) {\n gl.generateMipmap(texture.target);\n }\n gl.texParameteri(texture.target, gl.TEXTURE_WRAP_S, glTexture.wrapMode);\n gl.texParameteri(texture.target, gl.TEXTURE_WRAP_T, glTexture.wrapMode);\n if (glTexture.mipmap) {\n /* eslint-disable max-len */\n gl.texParameteri(texture.target, gl.TEXTURE_MIN_FILTER, texture.scaleMode === SCALE_MODES.LINEAR ? gl.LINEAR_MIPMAP_LINEAR : gl.NEAREST_MIPMAP_NEAREST);\n /* eslint-disable max-len */\n var anisotropicExt = this.renderer.context.extensions.anisotropicFiltering;\n if (anisotropicExt && texture.anisotropicLevel > 0 && texture.scaleMode === SCALE_MODES.LINEAR) {\n var level = Math.min(texture.anisotropicLevel, gl.getParameter(anisotropicExt.MAX_TEXTURE_MAX_ANISOTROPY_EXT));\n gl.texParameterf(texture.target, anisotropicExt.TEXTURE_MAX_ANISOTROPY_EXT, level);\n }\n }\n else {\n gl.texParameteri(texture.target, gl.TEXTURE_MIN_FILTER, texture.scaleMode === SCALE_MODES.LINEAR ? gl.LINEAR : gl.NEAREST);\n }\n gl.texParameteri(texture.target, gl.TEXTURE_MAG_FILTER, texture.scaleMode === SCALE_MODES.LINEAR ? gl.LINEAR : gl.NEAREST);\n };\n TextureSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return TextureSystem;\n}());\n\n\n\nvar _systems = {\n __proto__: null,\n FilterSystem: FilterSystem,\n BatchSystem: BatchSystem,\n ContextSystem: ContextSystem,\n FramebufferSystem: FramebufferSystem,\n GeometrySystem: GeometrySystem,\n MaskSystem: MaskSystem,\n ScissorSystem: ScissorSystem,\n StencilSystem: StencilSystem,\n ProjectionSystem: ProjectionSystem,\n RenderTextureSystem: RenderTextureSystem,\n ShaderSystem: ShaderSystem,\n StateSystem: StateSystem,\n TextureGCSystem: TextureGCSystem,\n TextureSystem: TextureSystem\n};\n\nvar tempMatrix$2 = new Matrix();\n/**\n * The AbstractRenderer is the base for a PixiJS Renderer. It is extended by the {@link PIXI.CanvasRenderer}\n * and {@link PIXI.Renderer} which can be used for rendering a PixiJS scene.\n *\n * @abstract\n * @class\n * @extends PIXI.utils.EventEmitter\n * @memberof PIXI\n */\nvar AbstractRenderer = /** @class */ (function (_super) {\n __extends(AbstractRenderer, _super);\n /**\n * @param system - The name of the system this renderer is for.\n * @param [options] - The optional renderer parameters.\n * @param {number} [options.width=800] - The width of the screen.\n * @param {number} [options.height=600] - The height of the screen.\n * @param {HTMLCanvasElement} [options.view] - The canvas to use as a view, optional.\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1.\n * @param {boolean} [options.antialias=false] - Sets antialias\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.preserveDrawingBuffer=false] - Enables drawing buffer preservation,\n * enable this if you need to call toDataUrl on the WebGL context.\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear the canvas or\n * not before the new render pass.\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n */\n function AbstractRenderer(type, options) {\n if (type === void 0) { type = RENDERER_TYPE.UNKNOWN; }\n var _this = _super.call(this) || this;\n // Add the default render options\n options = Object.assign({}, settings.RENDER_OPTIONS, options);\n /**\n * The supplied constructor options.\n *\n * @member {Object}\n * @readOnly\n */\n _this.options = options;\n /**\n * The type of the renderer.\n *\n * @member {number}\n * @default PIXI.RENDERER_TYPE.UNKNOWN\n * @see PIXI.RENDERER_TYPE\n */\n _this.type = type;\n /**\n * Measurements of the screen. (0, 0, screenWidth, screenHeight).\n *\n * Its safe to use as filterArea or hitArea for the whole stage.\n *\n * @member {PIXI.Rectangle}\n */\n _this.screen = new Rectangle(0, 0, options.width, options.height);\n /**\n * The canvas element that everything is drawn to.\n *\n * @member {HTMLCanvasElement}\n */\n _this.view = options.view || document.createElement('canvas');\n /**\n * The resolution / device pixel ratio of the renderer.\n *\n * @member {number}\n * @default PIXI.settings.RESOLUTION\n */\n _this.resolution = options.resolution || settings.RESOLUTION;\n /**\n * Pass-thru setting for the canvas' context `alpha` property. This is typically\n * not something you need to fiddle with. If you want transparency, use `backgroundAlpha`.\n *\n * @member {boolean}\n */\n _this.useContextAlpha = options.useContextAlpha;\n /**\n * Whether CSS dimensions of canvas view should be resized to screen dimensions automatically.\n *\n * @member {boolean}\n */\n _this.autoDensity = !!options.autoDensity;\n /**\n * The value of the preserveDrawingBuffer flag affects whether or not the contents of\n * the stencil buffer is retained after rendering.\n *\n * @member {boolean}\n */\n _this.preserveDrawingBuffer = options.preserveDrawingBuffer;\n /**\n * This sets if the CanvasRenderer will clear the canvas or not before the new render pass.\n * If the scene is NOT transparent PixiJS will use a canvas sized fillRect operation every\n * frame to set the canvas background color. If the scene is transparent PixiJS will use clearRect\n * to clear the canvas every frame. Disable this by setting this to false. For example, if\n * your game has a canvas filling background image you often don't need this set.\n *\n * @member {boolean}\n * @default\n */\n _this.clearBeforeRender = options.clearBeforeRender;\n /**\n * The background color as a number.\n *\n * @member {number}\n * @protected\n */\n _this._backgroundColor = 0x000000;\n /**\n * The background color as an [R, G, B, A] array.\n *\n * @member {number[]}\n * @protected\n */\n _this._backgroundColorRgba = [0, 0, 0, 1];\n /**\n * The background color as a string.\n *\n * @member {string}\n * @protected\n */\n _this._backgroundColorString = '#000000';\n _this.backgroundColor = options.backgroundColor || _this._backgroundColor; // run bg color setter\n _this.backgroundAlpha = options.backgroundAlpha;\n // @deprecated\n if (options.transparent !== undefined) {\n deprecation('6.0.0', 'Option transparent is deprecated, please use backgroundAlpha instead.');\n _this.useContextAlpha = options.transparent;\n _this.backgroundAlpha = options.transparent ? 0 : 1;\n }\n /**\n * The last root object that the renderer tried to render.\n *\n * @member {PIXI.DisplayObject}\n * @protected\n */\n _this._lastObjectRendered = null;\n /**\n * Collection of plugins.\n * @readonly\n * @member {object}\n */\n _this.plugins = {};\n return _this;\n }\n /**\n * Initialize the plugins.\n *\n * @protected\n * @param {object} staticMap - The dictionary of statically saved plugins.\n */\n AbstractRenderer.prototype.initPlugins = function (staticMap) {\n for (var o in staticMap) {\n this.plugins[o] = new (staticMap[o])(this);\n }\n };\n Object.defineProperty(AbstractRenderer.prototype, \"width\", {\n /**\n * Same as view.width, actual number of pixels in the canvas by horizontal.\n *\n * @member {number}\n * @readonly\n * @default 800\n */\n get: function () {\n return this.view.width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AbstractRenderer.prototype, \"height\", {\n /**\n * Same as view.height, actual number of pixels in the canvas by vertical.\n *\n * @member {number}\n * @readonly\n * @default 600\n */\n get: function () {\n return this.view.height;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Resizes the screen and canvas as close as possible to the specified width and height.\n * Canvas dimensions are multiplied by resolution and rounded to the nearest integers.\n * The new canvas dimensions divided by the resolution become the new screen dimensions.\n *\n * @param desiredScreenWidth - The desired width of the screen.\n * @param desiredScreenHeight - The desired height of the screen.\n */\n AbstractRenderer.prototype.resize = function (desiredScreenWidth, desiredScreenHeight) {\n this.view.width = Math.round(desiredScreenWidth * this.resolution);\n this.view.height = Math.round(desiredScreenHeight * this.resolution);\n var screenWidth = this.view.width / this.resolution;\n var screenHeight = this.view.height / this.resolution;\n this.screen.width = screenWidth;\n this.screen.height = screenHeight;\n if (this.autoDensity) {\n this.view.style.width = screenWidth + \"px\";\n this.view.style.height = screenHeight + \"px\";\n }\n /**\n * Fired after view has been resized.\n *\n * @event PIXI.Renderer#resize\n * @param {number} screenWidth - The new width of the screen.\n * @param {number} screenHeight - The new height of the screen.\n */\n this.emit('resize', screenWidth, screenHeight);\n };\n /**\n * @ignore\n */\n AbstractRenderer.prototype.generateTexture = function (displayObject, options, resolution, region) {\n if (options === void 0) { options = {}; }\n // @deprecated parameters spread, use options instead\n if (typeof options === 'number') {\n deprecation('6.1.0', 'generateTexture options (scaleMode, resolution, region) are now object options.');\n options = { scaleMode: options, resolution: resolution, region: region };\n }\n var manualRegion = options.region, textureOptions = __rest(options, [\"region\"]);\n region = manualRegion || displayObject.getLocalBounds(null, true);\n // minimum texture size is 1x1, 0x0 will throw an error\n if (region.width === 0)\n { region.width = 1; }\n if (region.height === 0)\n { region.height = 1; }\n var renderTexture = RenderTexture.create(__assign({ width: region.width, height: region.height }, textureOptions));\n tempMatrix$2.tx = -region.x;\n tempMatrix$2.ty = -region.y;\n this.render(displayObject, {\n renderTexture: renderTexture,\n clear: false,\n transform: tempMatrix$2,\n skipUpdateTransform: !!displayObject.parent\n });\n return renderTexture;\n };\n /**\n * Removes everything from the renderer and optionally removes the Canvas DOM element.\n *\n * @param [removeView=false] - Removes the Canvas element from the DOM.\n */\n AbstractRenderer.prototype.destroy = function (removeView) {\n for (var o in this.plugins) {\n this.plugins[o].destroy();\n this.plugins[o] = null;\n }\n if (removeView && this.view.parentNode) {\n this.view.parentNode.removeChild(this.view);\n }\n var thisAny = this;\n // null-ing all objects, that's a tradition!\n thisAny.plugins = null;\n thisAny.type = RENDERER_TYPE.UNKNOWN;\n thisAny.view = null;\n thisAny.screen = null;\n thisAny._tempDisplayObjectParent = null;\n thisAny.options = null;\n this._backgroundColorRgba = null;\n this._backgroundColorString = null;\n this._lastObjectRendered = null;\n };\n Object.defineProperty(AbstractRenderer.prototype, \"backgroundColor\", {\n /**\n * The background color to fill if not transparent\n *\n * @member {number}\n */\n get: function () {\n return this._backgroundColor;\n },\n set: function (value) {\n this._backgroundColor = value;\n this._backgroundColorString = hex2string(value);\n hex2rgb(value, this._backgroundColorRgba);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AbstractRenderer.prototype, \"backgroundAlpha\", {\n /**\n * The background color alpha. Setting this to 0 will make the canvas transparent.\n *\n * @member {number}\n */\n get: function () {\n return this._backgroundColorRgba[3];\n },\n set: function (value) {\n this._backgroundColorRgba[3] = value;\n },\n enumerable: false,\n configurable: true\n });\n return AbstractRenderer;\n}(EventEmitter));\n\nvar GLBuffer = /** @class */ (function () {\n function GLBuffer(buffer) {\n this.buffer = buffer || null;\n this.updateID = -1;\n this.byteLength = -1;\n this.refCount = 0;\n }\n return GLBuffer;\n}());\n\n/**\n * System plugin to the renderer to manage buffers.\n *\n * WebGL uses Buffers as a way to store objects to the GPU.\n * This system makes working with them a lot easier.\n *\n * Buffers are used in three main places in WebGL\n * - geometry information\n * - Uniform information (via uniform buffer objects - a WebGL 2 only feature)\n * - Transform feedback information. (WebGL 2 only feature)\n *\n * This system will handle the binding of buffers to the GPU as well as uploading\n * them. With this system, you never need to work directly with GPU buffers, but instead work with\n * the PIXI.Buffer class.\n *\n *\n * @class\n * @memberof PIXI\n */\nvar BufferSystem = /** @class */ (function () {\n /**\n * @param {PIXI.Renderer} renderer - The renderer this System works for.\n */\n function BufferSystem(renderer) {\n this.renderer = renderer;\n this.managedBuffers = {};\n this.boundBufferBases = {};\n }\n /**\n * @ignore\n */\n BufferSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n /**\n * Sets up the renderer context and necessary buffers.\n */\n BufferSystem.prototype.contextChange = function () {\n this.disposeAll(true);\n this.gl = this.renderer.gl;\n // TODO fill out...\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n };\n /**\n * This binds specified buffer. On first run, it will create the webGL buffers for the context too\n *\n * @param buffer - the buffer to bind to the renderer\n */\n BufferSystem.prototype.bind = function (buffer) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n var glBuffer = buffer._glBuffers[CONTEXT_UID] || this.createGLBuffer(buffer);\n gl.bindBuffer(buffer.type, glBuffer.buffer);\n };\n /**\n * Binds an uniform buffer to at the given index.\n *\n * A cache is used so a buffer will not be bound again if already bound.\n *\n * @param buffer - the buffer to bind\n * @param index - the base index to bind it to.\n */\n BufferSystem.prototype.bindBufferBase = function (buffer, index) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n if (this.boundBufferBases[index] !== buffer) {\n var glBuffer = buffer._glBuffers[CONTEXT_UID] || this.createGLBuffer(buffer);\n this.boundBufferBases[index] = buffer;\n gl.bindBufferBase(gl.UNIFORM_BUFFER, index, glBuffer.buffer);\n }\n };\n /**\n * Binds a buffer whilst also binding its range.\n * This will make the buffer start from the offset supplied rather than 0 when it is read.\n *\n * @param buffer - the buffer to bind\n * @param index - the base index to bind at, defaults to 0\n * @param offset - the offset to bind at (this is blocks of 256). 0 = 0, 1 = 256, 2 = 512 etc\n */\n BufferSystem.prototype.bindBufferRange = function (buffer, index, offset) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n offset = offset || 0;\n var glBuffer = buffer._glBuffers[CONTEXT_UID] || this.createGLBuffer(buffer);\n gl.bindBufferRange(gl.UNIFORM_BUFFER, index || 0, glBuffer.buffer, offset * 256, 256);\n };\n /**\n * Will ensure the data in the buffer is uploaded to the GPU.\n *\n * @param {PIXI.Buffer} buffer - the buffer to update\n */\n BufferSystem.prototype.update = function (buffer) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n var glBuffer = buffer._glBuffers[CONTEXT_UID];\n if (buffer._updateID === glBuffer.updateID) {\n return;\n }\n glBuffer.updateID = buffer._updateID;\n gl.bindBuffer(buffer.type, glBuffer.buffer);\n if (glBuffer.byteLength >= buffer.data.byteLength) {\n // offset is always zero for now!\n gl.bufferSubData(buffer.type, 0, buffer.data);\n }\n else {\n var drawType = buffer.static ? gl.STATIC_DRAW : gl.DYNAMIC_DRAW;\n glBuffer.byteLength = buffer.data.byteLength;\n gl.bufferData(buffer.type, buffer.data, drawType);\n }\n };\n /**\n * Disposes buffer\n * @param {PIXI.Buffer} buffer - buffer with data\n * @param {boolean} [contextLost=false] - If context was lost, we suppress deleteVertexArray\n */\n BufferSystem.prototype.dispose = function (buffer, contextLost) {\n if (!this.managedBuffers[buffer.id]) {\n return;\n }\n delete this.managedBuffers[buffer.id];\n var glBuffer = buffer._glBuffers[this.CONTEXT_UID];\n var gl = this.gl;\n buffer.disposeRunner.remove(this);\n if (!glBuffer) {\n return;\n }\n if (!contextLost) {\n gl.deleteBuffer(glBuffer.buffer);\n }\n delete buffer._glBuffers[this.CONTEXT_UID];\n };\n /**\n * dispose all WebGL resources of all managed buffers\n * @param {boolean} [contextLost=false] - If context was lost, we suppress `gl.delete` calls\n */\n BufferSystem.prototype.disposeAll = function (contextLost) {\n var all = Object.keys(this.managedBuffers);\n for (var i = 0; i < all.length; i++) {\n this.dispose(this.managedBuffers[all[i]], contextLost);\n }\n };\n /**\n * creates and attaches a GLBuffer object tied to the current context.\n * @protected\n */\n BufferSystem.prototype.createGLBuffer = function (buffer) {\n var _a = this, CONTEXT_UID = _a.CONTEXT_UID, gl = _a.gl;\n buffer._glBuffers[CONTEXT_UID] = new GLBuffer(gl.createBuffer());\n this.managedBuffers[buffer.id] = buffer;\n buffer.disposeRunner.add(this);\n return buffer._glBuffers[CONTEXT_UID];\n };\n return BufferSystem;\n}());\n\n/**\n * The Renderer draws the scene and all its content onto a WebGL enabled canvas.\n *\n * This renderer should be used for browsers that support WebGL.\n *\n * This renderer works by automatically managing WebGLBatchesm, so no need for Sprite Batches or Sprite Clouds.\n * Don't forget to add the view to your DOM or you will not see anything!\n *\n * Renderer is composed of systems that manage specific tasks. The following systems are added by default\n * whenever you create a renderer:\n *\n * | System | Description |\n * | ------------------------------------ | ----------------------------------------------------------------------------- |\n * | {@link PIXI.BatchSystem} | This manages object renderers that defer rendering until a flush. |\n * | {@link PIXI.ContextSystem} | This manages the WebGL context and extensions. |\n * | {@link PIXI.EventSystem} | This manages UI events. |\n * | {@link PIXI.FilterSystem} | This manages the filtering pipeline for post-processing effects. |\n * | {@link PIXI.FramebufferSystem} | This manages framebuffers, which are used for offscreen rendering. |\n * | {@link PIXI.GeometrySystem} | This manages geometries & buffers, which are used to draw object meshes. |\n * | {@link PIXI.MaskSystem} | This manages masking operations. |\n * | {@link PIXI.ProjectionSystem} | This manages the `projectionMatrix`, used by shaders to get NDC coordinates. |\n * | {@link PIXI.RenderTextureSystem} | This manages render-textures, which are an abstraction over framebuffers. |\n * | {@link PIXI.ScissorSystem} | This handles scissor masking, and is used internally by {@link MaskSystem} |\n * | {@link PIXI.ShaderSystem} | This manages shaders, programs that run on the GPU to calculate 'em pixels. |\n * | {@link PIXI.StateSystem} | This manages the WebGL state variables like blend mode, depth testing, etc. |\n * | {@link PIXI.StencilSystem} | This handles stencil masking, and is used internally by {@link MaskSystem} |\n * | {@link PIXI.TextureSystem} | This manages textures and their resources on the GPU. |\n * | {@link PIXI.TextureGCSystem} | This will automatically remove textures from the GPU if they are not used. |\n *\n * The breadth of the API surface provided by the renderer is contained within these systems.\n *\n * @memberof PIXI\n */\nvar Renderer = /** @class */ (function (_super) {\n __extends(Renderer, _super);\n /**\n * @param [options] - The optional renderer parameters.\n * @param {number} [options.width=800] - The width of the screen.\n * @param {number} [options.height=600] - The height of the screen.\n * @param {HTMLCanvasElement} [options.view] - The canvas to use as a view, optional.\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1.\n * @param {boolean} [options.antialias=false] - Sets antialias. If not available natively then FXAA\n * antialiasing is used.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear\n * the canvas or not before the new render pass. If you wish to set this to false, you *must* set\n * preserveDrawingBuffer to `true`.\n * @param {boolean} [options.preserveDrawingBuffer=false] - Enables drawing buffer preservation,\n * enable this if you need to call toDataUrl on the WebGL context.\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n * @param {string} [options.powerPreference] - Parameter passed to WebGL context, set to \"high-performance\"\n * for devices with dual graphics card.\n * @param {object} [options.context] - If WebGL context already exists, all parameters must be taken from it.\n */\n function Renderer(options) {\n var _this = _super.call(this, RENDERER_TYPE.WEBGL, options) || this;\n // the options will have been modified here in the super constructor with pixi's default settings..\n options = _this.options;\n _this.gl = null;\n _this.CONTEXT_UID = 0;\n _this.runners = {\n destroy: new Runner('destroy'),\n contextChange: new Runner('contextChange'),\n reset: new Runner('reset'),\n update: new Runner('update'),\n postrender: new Runner('postrender'),\n prerender: new Runner('prerender'),\n resize: new Runner('resize'),\n };\n _this.runners.contextChange.add(_this);\n _this.globalUniforms = new UniformGroup({\n projectionMatrix: new Matrix(),\n }, true);\n _this.addSystem(MaskSystem, 'mask')\n .addSystem(ContextSystem, 'context')\n .addSystem(StateSystem, 'state')\n .addSystem(ShaderSystem, 'shader')\n .addSystem(TextureSystem, 'texture')\n .addSystem(BufferSystem, 'buffer')\n .addSystem(GeometrySystem, 'geometry')\n .addSystem(FramebufferSystem, 'framebuffer')\n .addSystem(ScissorSystem, 'scissor')\n .addSystem(StencilSystem, 'stencil')\n .addSystem(ProjectionSystem, 'projection')\n .addSystem(TextureGCSystem, 'textureGC')\n .addSystem(FilterSystem, 'filter')\n .addSystem(RenderTextureSystem, 'renderTexture')\n .addSystem(BatchSystem, 'batch');\n _this.initPlugins(Renderer.__plugins);\n _this.multisample = undefined;\n /*\n * The options passed in to create a new WebGL context.\n */\n if (options.context) {\n _this.context.initFromContext(options.context);\n }\n else {\n _this.context.initFromOptions({\n alpha: !!_this.useContextAlpha,\n antialias: options.antialias,\n premultipliedAlpha: _this.useContextAlpha && _this.useContextAlpha !== 'notMultiplied',\n stencil: true,\n preserveDrawingBuffer: options.preserveDrawingBuffer,\n powerPreference: _this.options.powerPreference,\n });\n }\n _this.renderingToScreen = true;\n sayHello(_this.context.webGLVersion === 2 ? 'WebGL 2' : 'WebGL 1');\n _this.resize(_this.options.width, _this.options.height);\n return _this;\n }\n /**\n * Create renderer if WebGL is available. Overrideable\n * by the **@pixi/canvas-renderer** package to allow fallback.\n * throws error if WebGL is not available.\n *\n * @private\n */\n Renderer.create = function (options) {\n if (isWebGLSupported()) {\n return new Renderer(options);\n }\n throw new Error('WebGL unsupported in this browser, use \"pixi.js-legacy\" for fallback canvas2d support.');\n };\n Renderer.prototype.contextChange = function () {\n var gl = this.gl;\n var samples;\n if (this.context.webGLVersion === 1) {\n var framebuffer = gl.getParameter(gl.FRAMEBUFFER_BINDING);\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n samples = gl.getParameter(gl.SAMPLES);\n gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);\n }\n else {\n var framebuffer = gl.getParameter(gl.DRAW_FRAMEBUFFER_BINDING);\n gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, null);\n samples = gl.getParameter(gl.SAMPLES);\n gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, framebuffer);\n }\n if (samples >= MSAA_QUALITY.HIGH) {\n this.multisample = MSAA_QUALITY.HIGH;\n }\n else if (samples >= MSAA_QUALITY.MEDIUM) {\n this.multisample = MSAA_QUALITY.MEDIUM;\n }\n else if (samples >= MSAA_QUALITY.LOW) {\n this.multisample = MSAA_QUALITY.LOW;\n }\n else {\n this.multisample = MSAA_QUALITY.NONE;\n }\n };\n /**\n * Add a new system to the renderer.\n *\n * @param ClassRef - Class reference\n * @param name - Property name for system, if not specified\n * will use a static `name` property on the class itself. This\n * name will be assigned as s property on the Renderer so make\n * sure it doesn't collide with properties on Renderer.\n * @return Return instance of renderer\n */\n Renderer.prototype.addSystem = function (ClassRef, name) {\n var system = new ClassRef(this);\n if (this[name]) {\n throw new Error(\"Whoops! The name \\\"\" + name + \"\\\" is already in use\");\n }\n this[name] = system;\n for (var i in this.runners) {\n this.runners[i].add(system);\n }\n /**\n * Fired after rendering finishes.\n *\n * @event PIXI.Renderer#postrender\n */\n /**\n * Fired before rendering starts.\n *\n * @event PIXI.Renderer#prerender\n */\n /**\n * Fired when the WebGL context is set.\n *\n * @event PIXI.Renderer#context\n * @param {WebGLRenderingContext} gl - WebGL context.\n */\n return this;\n };\n /**\n * @ignore\n */\n Renderer.prototype.render = function (displayObject, options) {\n var renderTexture;\n var clear;\n var transform;\n var skipUpdateTransform;\n if (options) {\n if (options instanceof RenderTexture) {\n deprecation('6.0.0', 'Renderer#render arguments changed, use options instead.');\n /* eslint-disable prefer-rest-params */\n renderTexture = options;\n clear = arguments[2];\n transform = arguments[3];\n skipUpdateTransform = arguments[4];\n /* eslint-enable prefer-rest-params */\n }\n else {\n renderTexture = options.renderTexture;\n clear = options.clear;\n transform = options.transform;\n skipUpdateTransform = options.skipUpdateTransform;\n }\n }\n // can be handy to know!\n this.renderingToScreen = !renderTexture;\n this.runners.prerender.emit();\n this.emit('prerender');\n // apply a transform at a GPU level\n this.projection.transform = transform;\n // no point rendering if our context has been blown up!\n if (this.context.isLost) {\n return;\n }\n if (!renderTexture) {\n this._lastObjectRendered = displayObject;\n }\n if (!skipUpdateTransform) {\n // update the scene graph\n var cacheParent = displayObject.enableTempParent();\n displayObject.updateTransform();\n displayObject.disableTempParent(cacheParent);\n // displayObject.hitArea = //TODO add a temp hit area\n }\n this.renderTexture.bind(renderTexture);\n this.batch.currentRenderer.start();\n if (clear !== undefined ? clear : this.clearBeforeRender) {\n this.renderTexture.clear();\n }\n displayObject.render(this);\n // apply transform..\n this.batch.currentRenderer.flush();\n if (renderTexture) {\n renderTexture.baseTexture.update();\n }\n this.runners.postrender.emit();\n // reset transform after render\n this.projection.transform = null;\n this.emit('postrender');\n };\n /**\n * @override\n * @ignore\n */\n Renderer.prototype.generateTexture = function (displayObject, options, resolution, region) {\n if (options === void 0) { options = {}; }\n var renderTexture = _super.prototype.generateTexture.call(this, displayObject, options, resolution, region);\n this.framebuffer.blit();\n return renderTexture;\n };\n /**\n * Resizes the WebGL view to the specified width and height.\n *\n * @param desiredScreenWidth - The desired width of the screen.\n * @param desiredScreenHeight - The desired height of the screen.\n */\n Renderer.prototype.resize = function (desiredScreenWidth, desiredScreenHeight) {\n _super.prototype.resize.call(this, desiredScreenWidth, desiredScreenHeight);\n this.runners.resize.emit(this.screen.height, this.screen.width);\n };\n /**\n * Resets the WebGL state so you can render things however you fancy!\n *\n * @return Returns itself.\n */\n Renderer.prototype.reset = function () {\n this.runners.reset.emit();\n return this;\n };\n /** Clear the frame buffer. */\n Renderer.prototype.clear = function () {\n this.renderTexture.bind();\n this.renderTexture.clear();\n };\n /**\n * Removes everything from the renderer (event listeners, spritebatch, etc...)\n *\n * @param [removeView=false] - Removes the Canvas element from the DOM.\n * See: https://github.com/pixijs/pixi.js/issues/2233\n */\n Renderer.prototype.destroy = function (removeView) {\n this.runners.destroy.emit();\n for (var r in this.runners) {\n this.runners[r].destroy();\n }\n // call base destroy\n _super.prototype.destroy.call(this, removeView);\n // TODO nullify all the managers..\n this.gl = null;\n };\n Object.defineProperty(Renderer.prototype, \"extract\", {\n /**\n * Please use `plugins.extract` instead.\n * @member {PIXI.Extract} extract\n * @deprecated since 6.0.0\n * @readonly\n */\n get: function () {\n deprecation('6.0.0', 'Renderer#extract has been deprecated, please use Renderer#plugins.extract instead.');\n return this.plugins.extract;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Adds a plugin to the renderer.\n *\n * @param pluginName - The name of the plugin.\n * @param ctor - The constructor function or class for the plugin.\n */\n Renderer.registerPlugin = function (pluginName, ctor) {\n Renderer.__plugins = Renderer.__plugins || {};\n Renderer.__plugins[pluginName] = ctor;\n };\n return Renderer;\n}(AbstractRenderer));\n\n/**\n * This helper function will automatically detect which renderer you should be using.\n * WebGL is the preferred renderer as it is a lot faster. If WebGL is not supported by\n * the browser then this function will return a canvas renderer\n *\n * @memberof PIXI\n * @function autoDetectRenderer\n * @param {object} [options] - The optional renderer parameters\n * @param {number} [options.width=800] - the width of the renderers view\n * @param {number} [options.height=600] - the height of the renderers view\n * @param {HTMLCanvasElement} [options.view] - the canvas to use as a view, optional\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1\n * @param {boolean} [options.antialias=false] - sets antialias\n * @param {boolean} [options.preserveDrawingBuffer=false] - enables drawing buffer preservation, enable this if you\n * need to call toDataUrl on the webgl context\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear the canvas or\n * not before the new render pass.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.forceCanvas=false] - prevents selection of WebGL renderer, even if such is present, this\n * option only is available when using **pixi.js-legacy** or **@pixi/canvas-renderer** modules, otherwise\n * it is ignored.\n * @param {string} [options.powerPreference] - Parameter passed to webgl context, set to \"high-performance\"\n * for devices with dual graphics card **webgl only**\n * @return {PIXI.Renderer|PIXI.CanvasRenderer} Returns WebGL renderer if available, otherwise CanvasRenderer\n */\nfunction autoDetectRenderer(options) {\n return Renderer.create(options);\n}\n\nvar $defaultVertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n vTextureCoord = aTextureCoord;\\n}\";\n\nvar $defaultFilterVertex = \"attribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvec2 filterTextureCoord( void )\\n{\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n}\\n\\nvoid main(void)\\n{\\n gl_Position = filterVertexPosition();\\n vTextureCoord = filterTextureCoord();\\n}\\n\";\n\n/**\n * Default vertex shader\n * @memberof PIXI\n * @member {string} defaultVertex\n */\n/**\n * Default filter vertex shader\n * @memberof PIXI\n * @member {string} defaultFilterVertex\n */\n// NOTE: This black magic is so that @microsoft/api-extractor does not complain! This explicitly specifies the types\n// of defaultVertex, defaultFilterVertex.\nvar defaultVertex$2 = $defaultVertex;\nvar defaultFilterVertex = $defaultFilterVertex;\n\n/**\n * Use the ISystem interface instead.\n * @deprecated since 6.1.0\n * @memberof PIXI\n */\nvar System = /** @class */ (function () {\n /**\n * @param renderer - Reference to Renderer\n */\n function System(renderer) {\n deprecation('6.1.0', 'System class is deprecated, implemement ISystem interface instead.');\n this.renderer = renderer;\n }\n /** Destroy and don't use after this. */\n System.prototype.destroy = function () {\n this.renderer = null;\n };\n return System;\n}());\n\n/**\n * Used by the batcher to draw batches.\n * Each one of these contains all information required to draw a bound geometry.\n *\n * @memberof PIXI\n */\nvar BatchDrawCall = /** @class */ (function () {\n function BatchDrawCall() {\n this.texArray = null;\n this.blend = 0;\n this.type = DRAW_MODES.TRIANGLES;\n this.start = 0;\n this.size = 0;\n this.data = null;\n }\n return BatchDrawCall;\n}());\n\n/**\n * Used by the batcher to build texture batches.\n * Holds list of textures and their respective locations.\n *\n * @memberof PIXI\n */\nvar BatchTextureArray = /** @class */ (function () {\n function BatchTextureArray() {\n this.elements = [];\n this.ids = [];\n this.count = 0;\n }\n BatchTextureArray.prototype.clear = function () {\n for (var i = 0; i < this.count; i++) {\n this.elements[i] = null;\n }\n this.count = 0;\n };\n return BatchTextureArray;\n}());\n\n/**\n * Flexible wrapper around `ArrayBuffer` that also provides typed array views on demand.\n *\n * @memberof PIXI\n */\nvar ViewableBuffer = /** @class */ (function () {\n function ViewableBuffer(sizeOrBuffer) {\n if (typeof sizeOrBuffer === 'number') {\n this.rawBinaryData = new ArrayBuffer(sizeOrBuffer);\n }\n else if (sizeOrBuffer instanceof Uint8Array) {\n this.rawBinaryData = sizeOrBuffer.buffer;\n }\n else {\n this.rawBinaryData = sizeOrBuffer;\n }\n this.uint32View = new Uint32Array(this.rawBinaryData);\n this.float32View = new Float32Array(this.rawBinaryData);\n }\n Object.defineProperty(ViewableBuffer.prototype, \"int8View\", {\n /** View on the raw binary data as a `Int8Array`. */\n get: function () {\n if (!this._int8View) {\n this._int8View = new Int8Array(this.rawBinaryData);\n }\n return this._int8View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"uint8View\", {\n /** View on the raw binary data as a `Uint8Array`. */\n get: function () {\n if (!this._uint8View) {\n this._uint8View = new Uint8Array(this.rawBinaryData);\n }\n return this._uint8View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"int16View\", {\n /** View on the raw binary data as a `Int16Array`. */\n get: function () {\n if (!this._int16View) {\n this._int16View = new Int16Array(this.rawBinaryData);\n }\n return this._int16View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"uint16View\", {\n /** View on the raw binary data as a `Uint16Array`. */\n get: function () {\n if (!this._uint16View) {\n this._uint16View = new Uint16Array(this.rawBinaryData);\n }\n return this._uint16View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"int32View\", {\n /** View on the raw binary data as a `Int32Array`. */\n get: function () {\n if (!this._int32View) {\n this._int32View = new Int32Array(this.rawBinaryData);\n }\n return this._int32View;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Returns the view of the given type.\n *\n * @param type - One of `int8`, `uint8`, `int16`,\n * `uint16`, `int32`, `uint32`, and `float32`.\n * @return - typed array of given type\n */\n ViewableBuffer.prototype.view = function (type) {\n return this[type + \"View\"];\n };\n /** Destroys all buffer references. Do not use after calling this. */\n ViewableBuffer.prototype.destroy = function () {\n this.rawBinaryData = null;\n this._int8View = null;\n this._uint8View = null;\n this._int16View = null;\n this._uint16View = null;\n this._int32View = null;\n this.uint32View = null;\n this.float32View = null;\n };\n ViewableBuffer.sizeOf = function (type) {\n switch (type) {\n case 'int8':\n case 'uint8':\n return 1;\n case 'int16':\n case 'uint16':\n return 2;\n case 'int32':\n case 'uint32':\n case 'float32':\n return 4;\n default:\n throw new Error(type + \" isn't a valid view type\");\n }\n };\n return ViewableBuffer;\n}());\n\n/**\n * Renderer dedicated to drawing and batching sprites.\n *\n * This is the default batch renderer. It buffers objects\n * with texture-based geometries and renders them in\n * batches. It uploads multiple textures to the GPU to\n * reduce to the number of draw calls.\n *\n * @memberof PIXI\n */\nvar AbstractBatchRenderer = /** @class */ (function (_super) {\n __extends(AbstractBatchRenderer, _super);\n /**\n * This will hook onto the renderer's `contextChange`\n * and `prerender` signals.\n *\n * @param {PIXI.Renderer} renderer - The renderer this works for.\n */\n function AbstractBatchRenderer(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.shaderGenerator = null;\n _this.geometryClass = null;\n _this.vertexSize = null;\n _this.state = State.for2d();\n _this.size = settings.SPRITE_BATCH_SIZE * 4;\n _this._vertexCount = 0;\n _this._indexCount = 0;\n _this._bufferedElements = [];\n _this._bufferedTextures = [];\n _this._bufferSize = 0;\n _this._shader = null;\n _this._packedGeometries = [];\n _this._packedGeometryPoolSize = 2;\n _this._flushId = 0;\n _this._aBuffers = {};\n _this._iBuffers = {};\n _this.MAX_TEXTURES = 1;\n _this.renderer.on('prerender', _this.onPrerender, _this);\n renderer.runners.contextChange.add(_this);\n _this._dcIndex = 0;\n _this._aIndex = 0;\n _this._iIndex = 0;\n _this._attributeBuffer = null;\n _this._indexBuffer = null;\n _this._tempBoundTextures = [];\n return _this;\n }\n /**\n * Handles the `contextChange` signal.\n *\n * It calculates `this.MAX_TEXTURES` and allocating the packed-geometry object pool.\n */\n AbstractBatchRenderer.prototype.contextChange = function () {\n var gl = this.renderer.gl;\n if (settings.PREFER_ENV === ENV.WEBGL_LEGACY) {\n this.MAX_TEXTURES = 1;\n }\n else {\n // step 1: first check max textures the GPU can handle.\n this.MAX_TEXTURES = Math.min(gl.getParameter(gl.MAX_TEXTURE_IMAGE_UNITS), settings.SPRITE_MAX_TEXTURES);\n // step 2: check the maximum number of if statements the shader can have too..\n this.MAX_TEXTURES = checkMaxIfStatementsInShader(this.MAX_TEXTURES, gl);\n }\n this._shader = this.shaderGenerator.generateShader(this.MAX_TEXTURES);\n // we use the second shader as the first one depending on your browser\n // may omit aTextureId as it is not used by the shader so is optimized out.\n for (var i = 0; i < this._packedGeometryPoolSize; i++) {\n /* eslint-disable max-len */\n this._packedGeometries[i] = new (this.geometryClass)();\n }\n this.initFlushBuffers();\n };\n /** Makes sure that static and dynamic flush pooled objects have correct dimensions. */\n AbstractBatchRenderer.prototype.initFlushBuffers = function () {\n var _drawCallPool = AbstractBatchRenderer._drawCallPool, _textureArrayPool = AbstractBatchRenderer._textureArrayPool;\n // max draw calls\n var MAX_SPRITES = this.size / 4;\n // max texture arrays\n var MAX_TA = Math.floor(MAX_SPRITES / this.MAX_TEXTURES) + 1;\n while (_drawCallPool.length < MAX_SPRITES) {\n _drawCallPool.push(new BatchDrawCall());\n }\n while (_textureArrayPool.length < MAX_TA) {\n _textureArrayPool.push(new BatchTextureArray());\n }\n for (var i = 0; i < this.MAX_TEXTURES; i++) {\n this._tempBoundTextures[i] = null;\n }\n };\n /**\n * Handles the `prerender` signal.\n *\n * It ensures that flushes start from the first geometry object again.\n */\n AbstractBatchRenderer.prototype.onPrerender = function () {\n this._flushId = 0;\n };\n /**\n * Buffers the \"batchable\" object. It need not be rendered immediately.\n *\n * @param {PIXI.DisplayObject} element - the element to render when\n * using this renderer\n */\n AbstractBatchRenderer.prototype.render = function (element) {\n if (!element._texture.valid) {\n return;\n }\n if (this._vertexCount + (element.vertexData.length / 2) > this.size) {\n this.flush();\n }\n this._vertexCount += element.vertexData.length / 2;\n this._indexCount += element.indices.length;\n this._bufferedTextures[this._bufferSize] = element._texture.baseTexture;\n this._bufferedElements[this._bufferSize++] = element;\n };\n AbstractBatchRenderer.prototype.buildTexturesAndDrawCalls = function () {\n var _a = this, textures = _a._bufferedTextures, MAX_TEXTURES = _a.MAX_TEXTURES;\n var textureArrays = AbstractBatchRenderer._textureArrayPool;\n var batch = this.renderer.batch;\n var boundTextures = this._tempBoundTextures;\n var touch = this.renderer.textureGC.count;\n var TICK = ++BaseTexture._globalBatch;\n var countTexArrays = 0;\n var texArray = textureArrays[0];\n var start = 0;\n batch.copyBoundTextures(boundTextures, MAX_TEXTURES);\n for (var i = 0; i < this._bufferSize; ++i) {\n var tex = textures[i];\n textures[i] = null;\n if (tex._batchEnabled === TICK) {\n continue;\n }\n if (texArray.count >= MAX_TEXTURES) {\n batch.boundArray(texArray, boundTextures, TICK, MAX_TEXTURES);\n this.buildDrawCalls(texArray, start, i);\n start = i;\n texArray = textureArrays[++countTexArrays];\n ++TICK;\n }\n tex._batchEnabled = TICK;\n tex.touched = touch;\n texArray.elements[texArray.count++] = tex;\n }\n if (texArray.count > 0) {\n batch.boundArray(texArray, boundTextures, TICK, MAX_TEXTURES);\n this.buildDrawCalls(texArray, start, this._bufferSize);\n ++countTexArrays;\n ++TICK;\n }\n // Clean-up\n for (var i = 0; i < boundTextures.length; i++) {\n boundTextures[i] = null;\n }\n BaseTexture._globalBatch = TICK;\n };\n /** Populating drawcalls for rendering */\n AbstractBatchRenderer.prototype.buildDrawCalls = function (texArray, start, finish) {\n var _a = this, elements = _a._bufferedElements, _attributeBuffer = _a._attributeBuffer, _indexBuffer = _a._indexBuffer, vertexSize = _a.vertexSize;\n var drawCalls = AbstractBatchRenderer._drawCallPool;\n var dcIndex = this._dcIndex;\n var aIndex = this._aIndex;\n var iIndex = this._iIndex;\n var drawCall = drawCalls[dcIndex];\n drawCall.start = this._iIndex;\n drawCall.texArray = texArray;\n for (var i = start; i < finish; ++i) {\n var sprite = elements[i];\n var tex = sprite._texture.baseTexture;\n var spriteBlendMode = premultiplyBlendMode[tex.alphaMode ? 1 : 0][sprite.blendMode];\n elements[i] = null;\n if (start < i && drawCall.blend !== spriteBlendMode) {\n drawCall.size = iIndex - drawCall.start;\n start = i;\n drawCall = drawCalls[++dcIndex];\n drawCall.texArray = texArray;\n drawCall.start = iIndex;\n }\n this.packInterleavedGeometry(sprite, _attributeBuffer, _indexBuffer, aIndex, iIndex);\n aIndex += sprite.vertexData.length / 2 * vertexSize;\n iIndex += sprite.indices.length;\n drawCall.blend = spriteBlendMode;\n }\n if (start < finish) {\n drawCall.size = iIndex - drawCall.start;\n ++dcIndex;\n }\n this._dcIndex = dcIndex;\n this._aIndex = aIndex;\n this._iIndex = iIndex;\n };\n /** Bind textures for current rendering */\n AbstractBatchRenderer.prototype.bindAndClearTexArray = function (texArray) {\n var textureSystem = this.renderer.texture;\n for (var j = 0; j < texArray.count; j++) {\n textureSystem.bind(texArray.elements[j], texArray.ids[j]);\n texArray.elements[j] = null;\n }\n texArray.count = 0;\n };\n AbstractBatchRenderer.prototype.updateGeometry = function () {\n var _a = this, packedGeometries = _a._packedGeometries, attributeBuffer = _a._attributeBuffer, indexBuffer = _a._indexBuffer;\n if (!settings.CAN_UPLOAD_SAME_BUFFER) { /* Usually on iOS devices, where the browser doesn't\n like uploads to the same buffer in a single frame. */\n if (this._packedGeometryPoolSize <= this._flushId) {\n this._packedGeometryPoolSize++;\n packedGeometries[this._flushId] = new (this.geometryClass)();\n }\n packedGeometries[this._flushId]._buffer.update(attributeBuffer.rawBinaryData);\n packedGeometries[this._flushId]._indexBuffer.update(indexBuffer);\n this.renderer.geometry.bind(packedGeometries[this._flushId]);\n this.renderer.geometry.updateBuffers();\n this._flushId++;\n }\n else {\n // lets use the faster option, always use buffer number 0\n packedGeometries[this._flushId]._buffer.update(attributeBuffer.rawBinaryData);\n packedGeometries[this._flushId]._indexBuffer.update(indexBuffer);\n this.renderer.geometry.updateBuffers();\n }\n };\n AbstractBatchRenderer.prototype.drawBatches = function () {\n var dcCount = this._dcIndex;\n var _a = this.renderer, gl = _a.gl, stateSystem = _a.state;\n var drawCalls = AbstractBatchRenderer._drawCallPool;\n var curTexArray = null;\n // Upload textures and do the draw calls\n for (var i = 0; i < dcCount; i++) {\n var _b = drawCalls[i], texArray = _b.texArray, type = _b.type, size = _b.size, start = _b.start, blend = _b.blend;\n if (curTexArray !== texArray) {\n curTexArray = texArray;\n this.bindAndClearTexArray(texArray);\n }\n this.state.blendMode = blend;\n stateSystem.set(this.state);\n gl.drawElements(type, size, gl.UNSIGNED_SHORT, start * 2);\n }\n };\n /** Renders the content _now_ and empties the current batch. */\n AbstractBatchRenderer.prototype.flush = function () {\n if (this._vertexCount === 0) {\n return;\n }\n this._attributeBuffer = this.getAttributeBuffer(this._vertexCount);\n this._indexBuffer = this.getIndexBuffer(this._indexCount);\n this._aIndex = 0;\n this._iIndex = 0;\n this._dcIndex = 0;\n this.buildTexturesAndDrawCalls();\n this.updateGeometry();\n this.drawBatches();\n // reset elements buffer for the next flush\n this._bufferSize = 0;\n this._vertexCount = 0;\n this._indexCount = 0;\n };\n /** Starts a new sprite batch. */\n AbstractBatchRenderer.prototype.start = function () {\n this.renderer.state.set(this.state);\n this.renderer.texture.ensureSamplerType(this.MAX_TEXTURES);\n this.renderer.shader.bind(this._shader);\n if (settings.CAN_UPLOAD_SAME_BUFFER) {\n // bind buffer #0, we don't need others\n this.renderer.geometry.bind(this._packedGeometries[this._flushId]);\n }\n };\n /** Stops and flushes the current batch. */\n AbstractBatchRenderer.prototype.stop = function () {\n this.flush();\n };\n /** Destroys this `AbstractBatchRenderer`. It cannot be used again. */\n AbstractBatchRenderer.prototype.destroy = function () {\n for (var i = 0; i < this._packedGeometryPoolSize; i++) {\n if (this._packedGeometries[i]) {\n this._packedGeometries[i].destroy();\n }\n }\n this.renderer.off('prerender', this.onPrerender, this);\n this._aBuffers = null;\n this._iBuffers = null;\n this._packedGeometries = null;\n this._attributeBuffer = null;\n this._indexBuffer = null;\n if (this._shader) {\n this._shader.destroy();\n this._shader = null;\n }\n _super.prototype.destroy.call(this);\n };\n /**\n * Fetches an attribute buffer from `this._aBuffers` that can hold atleast `size` floats.\n *\n * @param size - minimum capacity required\n * @return - buffer than can hold atleast `size` floats\n */\n AbstractBatchRenderer.prototype.getAttributeBuffer = function (size) {\n // 8 vertices is enough for 2 quads\n var roundedP2 = nextPow2(Math.ceil(size / 8));\n var roundedSizeIndex = log2(roundedP2);\n var roundedSize = roundedP2 * 8;\n if (this._aBuffers.length <= roundedSizeIndex) {\n this._iBuffers.length = roundedSizeIndex + 1;\n }\n var buffer = this._aBuffers[roundedSize];\n if (!buffer) {\n this._aBuffers[roundedSize] = buffer = new ViewableBuffer(roundedSize * this.vertexSize * 4);\n }\n return buffer;\n };\n /**\n * Fetches an index buffer from `this._iBuffers` that can\n * have at least `size` capacity.\n *\n * @param size - minimum required capacity\n * @return - buffer that can fit `size` indices.\n */\n AbstractBatchRenderer.prototype.getIndexBuffer = function (size) {\n // 12 indices is enough for 2 quads\n var roundedP2 = nextPow2(Math.ceil(size / 12));\n var roundedSizeIndex = log2(roundedP2);\n var roundedSize = roundedP2 * 12;\n if (this._iBuffers.length <= roundedSizeIndex) {\n this._iBuffers.length = roundedSizeIndex + 1;\n }\n var buffer = this._iBuffers[roundedSizeIndex];\n if (!buffer) {\n this._iBuffers[roundedSizeIndex] = buffer = new Uint16Array(roundedSize);\n }\n return buffer;\n };\n /**\n * Takes the four batching parameters of `element`, interleaves\n * and pushes them into the batching attribute/index buffers given.\n *\n * It uses these properties: `vertexData` `uvs`, `textureId` and\n * `indicies`. It also uses the \"tint\" of the base-texture, if\n * present.\n *\n * @param {PIXI.DisplayObject} element - element being rendered\n * @param attributeBuffer - attribute buffer.\n * @param indexBuffer - index buffer\n * @param aIndex - number of floats already in the attribute buffer\n * @param iIndex - number of indices already in `indexBuffer`\n */\n AbstractBatchRenderer.prototype.packInterleavedGeometry = function (element, attributeBuffer, indexBuffer, aIndex, iIndex) {\n var uint32View = attributeBuffer.uint32View, float32View = attributeBuffer.float32View;\n var packedVertices = aIndex / this.vertexSize;\n var uvs = element.uvs;\n var indicies = element.indices;\n var vertexData = element.vertexData;\n var textureId = element._texture.baseTexture._batchLocation;\n var alpha = Math.min(element.worldAlpha, 1.0);\n var argb = (alpha < 1.0\n && element._texture.baseTexture.alphaMode)\n ? premultiplyTint(element._tintRGB, alpha)\n : element._tintRGB + (alpha * 255 << 24);\n // lets not worry about tint! for now..\n for (var i = 0; i < vertexData.length; i += 2) {\n float32View[aIndex++] = vertexData[i];\n float32View[aIndex++] = vertexData[i + 1];\n float32View[aIndex++] = uvs[i];\n float32View[aIndex++] = uvs[i + 1];\n uint32View[aIndex++] = argb;\n float32View[aIndex++] = textureId;\n }\n for (var i = 0; i < indicies.length; i++) {\n indexBuffer[iIndex++] = packedVertices + indicies[i];\n }\n };\n /**\n * Pool of `BatchDrawCall` objects that `flush` used\n * to create \"batches\" of the objects being rendered.\n *\n * These are never re-allocated again.\n * Shared between all batch renderers because it can be only one \"flush\" working at the moment.\n *\n * @member {PIXI.BatchDrawCall[]}\n */\n AbstractBatchRenderer._drawCallPool = [];\n /**\n * Pool of `BatchDrawCall` objects that `flush` used\n * to create \"batches\" of the objects being rendered.\n *\n * These are never re-allocated again.\n * Shared between all batch renderers because it can be only one \"flush\" working at the moment.\n *\n * @member {PIXI.BatchTextureArray[]}\n */\n AbstractBatchRenderer._textureArrayPool = [];\n return AbstractBatchRenderer;\n}(ObjectRenderer));\n\n/**\n * Helper that generates batching multi-texture shader. Use it with your new BatchRenderer\n *\n * @memberof PIXI\n */\nvar BatchShaderGenerator = /** @class */ (function () {\n /**\n * @param vertexSrc - Vertex shader\n * @param fragTemplate - Fragment shader template\n */\n function BatchShaderGenerator(vertexSrc, fragTemplate) {\n this.vertexSrc = vertexSrc;\n this.fragTemplate = fragTemplate;\n this.programCache = {};\n this.defaultGroupCache = {};\n if (fragTemplate.indexOf('%count%') < 0) {\n throw new Error('Fragment template must contain \"%count%\".');\n }\n if (fragTemplate.indexOf('%forloop%') < 0) {\n throw new Error('Fragment template must contain \"%forloop%\".');\n }\n }\n BatchShaderGenerator.prototype.generateShader = function (maxTextures) {\n if (!this.programCache[maxTextures]) {\n var sampleValues = new Int32Array(maxTextures);\n for (var i = 0; i < maxTextures; i++) {\n sampleValues[i] = i;\n }\n this.defaultGroupCache[maxTextures] = UniformGroup.from({ uSamplers: sampleValues }, true);\n var fragmentSrc = this.fragTemplate;\n fragmentSrc = fragmentSrc.replace(/%count%/gi, \"\" + maxTextures);\n fragmentSrc = fragmentSrc.replace(/%forloop%/gi, this.generateSampleSrc(maxTextures));\n this.programCache[maxTextures] = new Program(this.vertexSrc, fragmentSrc);\n }\n var uniforms = {\n tint: new Float32Array([1, 1, 1, 1]),\n translationMatrix: new Matrix(),\n default: this.defaultGroupCache[maxTextures],\n };\n return new Shader(this.programCache[maxTextures], uniforms);\n };\n BatchShaderGenerator.prototype.generateSampleSrc = function (maxTextures) {\n var src = '';\n src += '\\n';\n src += '\\n';\n for (var i = 0; i < maxTextures; i++) {\n if (i > 0) {\n src += '\\nelse ';\n }\n if (i < maxTextures - 1) {\n src += \"if(vTextureId < \" + i + \".5)\";\n }\n src += '\\n{';\n src += \"\\n\\tcolor = texture2D(uSamplers[\" + i + \"], vTextureCoord);\";\n src += '\\n}';\n }\n src += '\\n';\n src += '\\n';\n return src;\n };\n return BatchShaderGenerator;\n}());\n\n/**\n * Geometry used to batch standard PIXI content (e.g. Mesh, Sprite, Graphics objects).\n *\n * @memberof PIXI\n */\nvar BatchGeometry = /** @class */ (function (_super) {\n __extends(BatchGeometry, _super);\n /**\n * @param {boolean} [_static=false] - Optimization flag, where `false`\n * is updated every frame, `true` doesn't change frame-to-frame.\n */\n function BatchGeometry(_static) {\n if (_static === void 0) { _static = false; }\n var _this = _super.call(this) || this;\n _this._buffer = new Buffer(null, _static, false);\n _this._indexBuffer = new Buffer(null, _static, true);\n _this.addAttribute('aVertexPosition', _this._buffer, 2, false, TYPES.FLOAT)\n .addAttribute('aTextureCoord', _this._buffer, 2, false, TYPES.FLOAT)\n .addAttribute('aColor', _this._buffer, 4, true, TYPES.UNSIGNED_BYTE)\n .addAttribute('aTextureId', _this._buffer, 1, true, TYPES.FLOAT)\n .addIndex(_this._indexBuffer);\n return _this;\n }\n return BatchGeometry;\n}(Geometry));\n\nvar defaultVertex$3 = \"precision highp float;\\nattribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\nattribute vec4 aColor;\\nattribute float aTextureId;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform vec4 tint;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec4 vColor;\\nvarying float vTextureId;\\n\\nvoid main(void){\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = aTextureCoord;\\n vTextureId = aTextureId;\\n vColor = aColor * tint;\\n}\\n\";\n\nvar defaultFragment$2 = \"varying vec2 vTextureCoord;\\nvarying vec4 vColor;\\nvarying float vTextureId;\\nuniform sampler2D uSamplers[%count%];\\n\\nvoid main(void){\\n vec4 color;\\n %forloop%\\n gl_FragColor = color * vColor;\\n}\\n\";\n\n/** @memberof PIXI */\nvar BatchPluginFactory = /** @class */ (function () {\n function BatchPluginFactory() {\n }\n /**\n * Create a new BatchRenderer plugin for Renderer. this convenience can provide an easy way\n * to extend BatchRenderer with all the necessary pieces.\n * @example\n * const fragment = `\n * varying vec2 vTextureCoord;\n * varying vec4 vColor;\n * varying float vTextureId;\n * uniform sampler2D uSamplers[%count%];\n *\n * void main(void){\n * vec4 color;\n * %forloop%\n * gl_FragColor = vColor * vec4(color.a - color.rgb, color.a);\n * }\n * `;\n * const InvertBatchRenderer = PIXI.BatchPluginFactory.create({ fragment });\n * PIXI.Renderer.registerPlugin('invert', InvertBatchRenderer);\n * const sprite = new PIXI.Sprite();\n * sprite.pluginName = 'invert';\n *\n * @param {object} [options]\n * @param {string} [options.vertex=PIXI.BatchPluginFactory.defaultVertexSrc] - Vertex shader source\n * @param {string} [options.fragment=PIXI.BatchPluginFactory.defaultFragmentTemplate] - Fragment shader template\n * @param {number} [options.vertexSize=6] - Vertex size\n * @param {object} [options.geometryClass=PIXI.BatchGeometry]\n * @return {*} New batch renderer plugin\n */\n BatchPluginFactory.create = function (options) {\n var _a = Object.assign({\n vertex: defaultVertex$3,\n fragment: defaultFragment$2,\n geometryClass: BatchGeometry,\n vertexSize: 6,\n }, options), vertex = _a.vertex, fragment = _a.fragment, vertexSize = _a.vertexSize, geometryClass = _a.geometryClass;\n return /** @class */ (function (_super) {\n __extends(BatchPlugin, _super);\n function BatchPlugin(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.shaderGenerator = new BatchShaderGenerator(vertex, fragment);\n _this.geometryClass = geometryClass;\n _this.vertexSize = vertexSize;\n return _this;\n }\n return BatchPlugin;\n }(AbstractBatchRenderer));\n };\n Object.defineProperty(BatchPluginFactory, \"defaultVertexSrc\", {\n /**\n * The default vertex shader source\n *\n * @readonly\n */\n get: function () {\n return defaultVertex$3;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BatchPluginFactory, \"defaultFragmentTemplate\", {\n /**\n * The default fragment shader source\n *\n * @readonly\n */\n get: function () {\n return defaultFragment$2;\n },\n enumerable: false,\n configurable: true\n });\n return BatchPluginFactory;\n}());\n// Setup the default BatchRenderer plugin, this is what\n// we'll actually export at the root level\nvar BatchRenderer = BatchPluginFactory.create();\n\n/**\n * @memberof PIXI\n * @namespace resources\n * @see PIXI\n * @deprecated since 6.0.0\n */\nvar resources = {};\nvar _loop_1 = function (name) {\n Object.defineProperty(resources, name, {\n get: function () {\n deprecation('6.0.0', \"PIXI.systems.\" + name + \" has moved to PIXI.\" + name);\n return _resources[name];\n },\n });\n};\nfor (var name in _resources) {\n _loop_1(name);\n}\n/**\n * @memberof PIXI\n * @namespace systems\n * @see PIXI\n * @deprecated since 6.0.0\n */\nvar systems = {};\nvar _loop_2 = function (name) {\n Object.defineProperty(systems, name, {\n get: function () {\n deprecation('6.0.0', \"PIXI.resources.\" + name + \" has moved to PIXI.\" + name);\n return _systems[name];\n },\n });\n};\nfor (var name in _systems) {\n _loop_2(name);\n}\n\nexport { AbstractBatchRenderer, AbstractMultiResource, AbstractRenderer, ArrayResource, Attribute, BaseImageResource, BaseRenderTexture, BaseTexture, BatchDrawCall, BatchGeometry, BatchPluginFactory, BatchRenderer, BatchShaderGenerator, BatchSystem, BatchTextureArray, Buffer, BufferResource, CanvasResource, ContextSystem, CubeResource, Filter, FilterState, FilterSystem, Framebuffer, FramebufferSystem, GLFramebuffer, GLProgram, GLTexture, Geometry, GeometrySystem, IGLUniformData, INSTALLED, ImageBitmapResource, ImageResource, MaskData, MaskSystem, ObjectRenderer, Program, ProjectionSystem, Quad, QuadUv, RenderTexture, RenderTexturePool, RenderTextureSystem, Renderer, Resource, SVGResource, ScissorSystem, Shader, ShaderSystem, SpriteMaskFilter, State, StateSystem, StencilSystem, System, Texture, TextureGCSystem, TextureMatrix, TextureSystem, TextureUvs, UniformGroup, VideoResource, ViewableBuffer, autoDetectRenderer, autoDetectResource, checkMaxIfStatementsInShader, createUBOElements, defaultFilterVertex, defaultVertex$2 as defaultVertex, generateProgram, generateUniformBufferSync, getTestContext, getUBOData, resources, systems, uniformParsers };\n//# sourceMappingURL=core.js.map\n","/*!\n * @pixi/display - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/display is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nimport { Rectangle, RAD_TO_DEG, DEG_TO_RAD, Transform } from '@pixi/math';\nimport { EventEmitter, removeItems } from '@pixi/utils';\n\n/**\n * Sets the default value for the container property 'sortableChildren'.\n * If set to true, the container will sort its children by zIndex value\n * when updateTransform() is called, or manually if sortChildren() is called.\n *\n * This actually changes the order of elements in the array, so should be treated\n * as a basic solution that is not performant compared to other solutions,\n * such as @link https://github.com/pixijs/pixi-display\n *\n * Also be aware of that this may not work nicely with the addChildAt() function,\n * as the zIndex sorting may cause the child to automatically sorted to another position.\n *\n * @static\n * @constant\n * @name SORTABLE_CHILDREN\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\nsettings.SORTABLE_CHILDREN = false;\n\n/**\n * 'Builder' pattern for bounds rectangles.\n *\n * This could be called an Axis-Aligned Bounding Box.\n * It is not an actual shape. It is a mutable thing; no 'EMPTY' or those kind of problems.\n *\n * @memberof PIXI\n */\nvar Bounds = /** @class */ (function () {\n function Bounds() {\n this.minX = Infinity;\n this.minY = Infinity;\n this.maxX = -Infinity;\n this.maxY = -Infinity;\n this.rect = null;\n this.updateID = -1;\n }\n /**\n * Checks if bounds are empty.\n *\n * @return - True if empty.\n */\n Bounds.prototype.isEmpty = function () {\n return this.minX > this.maxX || this.minY > this.maxY;\n };\n /** Clears the bounds and resets. */\n Bounds.prototype.clear = function () {\n this.minX = Infinity;\n this.minY = Infinity;\n this.maxX = -Infinity;\n this.maxY = -Infinity;\n };\n /**\n * Can return Rectangle.EMPTY constant, either construct new rectangle, either use your rectangle\n * It is not guaranteed that it will return tempRect\n *\n * @param rect - Temporary object will be used if AABB is not empty\n * @returns - A rectangle of the bounds\n */\n Bounds.prototype.getRectangle = function (rect) {\n if (this.minX > this.maxX || this.minY > this.maxY) {\n return Rectangle.EMPTY;\n }\n rect = rect || new Rectangle(0, 0, 1, 1);\n rect.x = this.minX;\n rect.y = this.minY;\n rect.width = this.maxX - this.minX;\n rect.height = this.maxY - this.minY;\n return rect;\n };\n /**\n * This function should be inlined when its possible.\n *\n * @param point - The point to add.\n */\n Bounds.prototype.addPoint = function (point) {\n this.minX = Math.min(this.minX, point.x);\n this.maxX = Math.max(this.maxX, point.x);\n this.minY = Math.min(this.minY, point.y);\n this.maxY = Math.max(this.maxY, point.y);\n };\n /** Adds a point, after transformed. This should be inlined when its possible. */\n Bounds.prototype.addPointMatrix = function (matrix, point) {\n var a = matrix.a, b = matrix.b, c = matrix.c, d = matrix.d, tx = matrix.tx, ty = matrix.ty;\n var x = (a * point.x) + (c * point.y) + tx;\n var y = (b * point.x) + (d * point.y) + ty;\n this.minX = Math.min(this.minX, x);\n this.maxX = Math.max(this.maxX, x);\n this.minY = Math.min(this.minY, y);\n this.maxY = Math.max(this.maxY, y);\n };\n /**\n * Adds a quad, not transformed\n *\n * @param vertices - The verts to add.\n */\n Bounds.prototype.addQuad = function (vertices) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n var x = vertices[0];\n var y = vertices[1];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = vertices[2];\n y = vertices[3];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = vertices[4];\n y = vertices[5];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = vertices[6];\n y = vertices[7];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Adds sprite frame, transformed.\n *\n * @param transform - transform to apply\n * @param x0 - left X of frame\n * @param y0 - top Y of frame\n * @param x1 - right X of frame\n * @param y1 - bottom Y of frame\n */\n Bounds.prototype.addFrame = function (transform, x0, y0, x1, y1) {\n this.addFrameMatrix(transform.worldTransform, x0, y0, x1, y1);\n };\n /**\n * Adds sprite frame, multiplied by matrix\n *\n * @param matrix - matrix to apply\n * @param x0 - left X of frame\n * @param y0 - top Y of frame\n * @param x1 - right X of frame\n * @param y1 - bottom Y of frame\n */\n Bounds.prototype.addFrameMatrix = function (matrix, x0, y0, x1, y1) {\n var a = matrix.a;\n var b = matrix.b;\n var c = matrix.c;\n var d = matrix.d;\n var tx = matrix.tx;\n var ty = matrix.ty;\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n var x = (a * x0) + (c * y0) + tx;\n var y = (b * x0) + (d * y0) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = (a * x1) + (c * y0) + tx;\n y = (b * x1) + (d * y0) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = (a * x0) + (c * y1) + tx;\n y = (b * x0) + (d * y1) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = (a * x1) + (c * y1) + tx;\n y = (b * x1) + (d * y1) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Adds screen vertices from array\n *\n * @param vertexData - calculated vertices\n * @param beginOffset - begin offset\n * @param endOffset - end offset, excluded\n */\n Bounds.prototype.addVertexData = function (vertexData, beginOffset, endOffset) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n for (var i = beginOffset; i < endOffset; i += 2) {\n var x = vertexData[i];\n var y = vertexData[i + 1];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n }\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Add an array of mesh vertices\n *\n * @param transform - mesh transform\n * @param vertices - mesh coordinates in array\n * @param beginOffset - begin offset\n * @param endOffset - end offset, excluded\n */\n Bounds.prototype.addVertices = function (transform, vertices, beginOffset, endOffset) {\n this.addVerticesMatrix(transform.worldTransform, vertices, beginOffset, endOffset);\n };\n /**\n * Add an array of mesh vertices.\n *\n * @param matrix - mesh matrix\n * @param vertices - mesh coordinates in array\n * @param beginOffset - begin offset\n * @param endOffset - end offset, excluded\n * @param padX - x padding\n * @param padY - y padding\n */\n Bounds.prototype.addVerticesMatrix = function (matrix, vertices, beginOffset, endOffset, padX, padY) {\n if (padX === void 0) { padX = 0; }\n if (padY === void 0) { padY = padX; }\n var a = matrix.a;\n var b = matrix.b;\n var c = matrix.c;\n var d = matrix.d;\n var tx = matrix.tx;\n var ty = matrix.ty;\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n for (var i = beginOffset; i < endOffset; i += 2) {\n var rawX = vertices[i];\n var rawY = vertices[i + 1];\n var x = (a * rawX) + (c * rawY) + tx;\n var y = (d * rawY) + (b * rawX) + ty;\n minX = Math.min(minX, x - padX);\n maxX = Math.max(maxX, x + padX);\n minY = Math.min(minY, y - padY);\n maxY = Math.max(maxY, y + padY);\n }\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Adds other {@link Bounds}.\n *\n * @param bounds - The Bounds to be added\n */\n Bounds.prototype.addBounds = function (bounds) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n this.minX = bounds.minX < minX ? bounds.minX : minX;\n this.minY = bounds.minY < minY ? bounds.minY : minY;\n this.maxX = bounds.maxX > maxX ? bounds.maxX : maxX;\n this.maxY = bounds.maxY > maxY ? bounds.maxY : maxY;\n };\n /**\n * Adds other Bounds, masked with Bounds.\n *\n * @param bounds - The Bounds to be added.\n * @param mask - TODO\n */\n Bounds.prototype.addBoundsMask = function (bounds, mask) {\n var _minX = bounds.minX > mask.minX ? bounds.minX : mask.minX;\n var _minY = bounds.minY > mask.minY ? bounds.minY : mask.minY;\n var _maxX = bounds.maxX < mask.maxX ? bounds.maxX : mask.maxX;\n var _maxY = bounds.maxY < mask.maxY ? bounds.maxY : mask.maxY;\n if (_minX <= _maxX && _minY <= _maxY) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n this.minX = _minX < minX ? _minX : minX;\n this.minY = _minY < minY ? _minY : minY;\n this.maxX = _maxX > maxX ? _maxX : maxX;\n this.maxY = _maxY > maxY ? _maxY : maxY;\n }\n };\n /**\n * Adds other Bounds, multiplied by matrix. Bounds shouldn't be empty.\n *\n * @param bounds - other bounds\n * @param matrix - multiplicator\n */\n Bounds.prototype.addBoundsMatrix = function (bounds, matrix) {\n this.addFrameMatrix(matrix, bounds.minX, bounds.minY, bounds.maxX, bounds.maxY);\n };\n /**\n * Adds other Bounds, masked with Rectangle.\n *\n * @param bounds - TODO\n * @param area - TODO\n */\n Bounds.prototype.addBoundsArea = function (bounds, area) {\n var _minX = bounds.minX > area.x ? bounds.minX : area.x;\n var _minY = bounds.minY > area.y ? bounds.minY : area.y;\n var _maxX = bounds.maxX < area.x + area.width ? bounds.maxX : (area.x + area.width);\n var _maxY = bounds.maxY < area.y + area.height ? bounds.maxY : (area.y + area.height);\n if (_minX <= _maxX && _minY <= _maxY) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n this.minX = _minX < minX ? _minX : minX;\n this.minY = _minY < minY ? _minY : minY;\n this.maxX = _maxX > maxX ? _maxX : maxX;\n this.maxY = _maxY > maxY ? _maxY : maxY;\n }\n };\n /**\n * Pads bounds object, making it grow in all directions.\n * If paddingY is omitted, both paddingX and paddingY will be set to paddingX.\n *\n * @param paddingX - The horizontal padding amount.\n * @param paddingY - The vertical padding amount.\n */\n Bounds.prototype.pad = function (paddingX, paddingY) {\n if (paddingX === void 0) { paddingX = 0; }\n if (paddingY === void 0) { paddingY = paddingX; }\n if (!this.isEmpty()) {\n this.minX -= paddingX;\n this.maxX += paddingX;\n this.minY -= paddingY;\n this.maxY += paddingY;\n }\n };\n /**\n * Adds padded frame. (x0, y0) should be strictly less than (x1, y1)\n *\n * @param x0 - left X of frame\n * @param y0 - top Y of frame\n * @param x1 - right X of frame\n * @param y1 - bottom Y of frame\n * @param padX - padding X\n * @param padY - padding Y\n */\n Bounds.prototype.addFramePad = function (x0, y0, x1, y1, padX, padY) {\n x0 -= padX;\n y0 -= padY;\n x1 += padX;\n y1 += padY;\n this.minX = this.minX < x0 ? this.minX : x0;\n this.maxX = this.maxX > x1 ? this.maxX : x1;\n this.minY = this.minY < y0 ? this.minY : y0;\n this.maxY = this.maxY > y1 ? this.maxY : y1;\n };\n return Bounds;\n}());\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * The base class for all objects that are rendered on the screen.\n *\n * This is an abstract class and can not be used on its own; rather it should be extended.\n *\n * ## Display objects implemented in PixiJS\n *\n * | Display Object | Description |\n * | ------------------------------- | --------------------------------------------------------------------- |\n * | {@link PIXI.Container} | Adds support for `children` to DisplayObject |\n * | {@link PIXI.Graphics} | Shape-drawing display object similar to the Canvas API |\n * | {@link PIXI.Sprite} | Draws textures (i.e. images) |\n * | {@link PIXI.Text} | Draws text using the Canvas API internally |\n * | {@link PIXI.BitmapText} | More scaleable solution for text rendering, reusing glyph textures |\n * | {@link PIXI.TilingSprite} | Draws textures/images in a tiled fashion |\n * | {@link PIXI.AnimatedSprite} | Draws an animation of multiple images |\n * | {@link PIXI.Mesh} | Provides a lower-level API for drawing meshes with custom data |\n * | {@link PIXI.NineSlicePlane} | Mesh-related |\n * | {@link PIXI.SimpleMesh} | v4-compatible mesh |\n * | {@link PIXI.SimplePlane} | Mesh-related |\n * | {@link PIXI.SimpleRope} | Mesh-related |\n *\n * ## Transforms\n *\n * The [transform]{@link DisplayObject#transform} of a display object describes the projection from its\n * local coordinate space to its parent's local coordinate space. The following properties are derived\n * from the transform:\n *\n * <table>\n * <thead>\n * <tr>\n * <th>Property</th>\n * <th>Description</th>\n * </tr>\n * </thead>\n * <tbody>\n * <tr>\n * <td>[pivot]{@link PIXI.DisplayObject#pivot}</td>\n * <td>\n * Invariant under rotation, scaling, and skewing. The projection of into the parent's space of the pivot\n * is equal to position, regardless of the other three transformations. In other words, It is the center of\n * rotation, scaling, and skewing.\n * </td>\n * </tr>\n * <tr>\n * <td>[position]{@link PIXI.DisplayObject#position}</td>\n * <td>\n * Translation. This is the position of the [pivot]{@link PIXI.DisplayObject#pivot} in the parent's local\n * space. The default value of the pivot is the origin (0,0). If the top-left corner of your display object\n * is (0,0) in its local space, then the position will be its top-left corner in the parent's local space.\n * </td>\n * </tr>\n * <tr>\n * <td>[scale]{@link PIXI.DisplayObject#scale}</td>\n * <td>\n * Scaling. This will stretch (or compress) the display object's projection. The scale factors are along the\n * local coordinate axes. In other words, the display object is scaled before rotated or skewed. The center\n * of scaling is the [pivot]{@link PIXI.DisplayObject#pivot}.\n * </td>\n * </tr>\n * <tr>\n * <td>[rotation]{@link PIXI.DisplayObject#rotation}</td>\n * <td>\n * Rotation. This will rotate the display object's projection by this angle (in radians).\n * </td>\n * </tr>\n * <tr>\n * <td>[skew]{@link PIXI.DisplayObject#skew}</td>\n * <td>\n * <p>Skewing. This can be used to deform a rectangular display object into a parallelogram.</p>\n * <p>\n * In PixiJS, skew has a slightly different behaviour than the conventional meaning. It can be\n * thought of the net rotation applied to the coordinate axes (separately). For example, if \"skew.x\" is\n * ⍺ and \"skew.y\" is β, then the line x = 0 will be rotated by ⍺ (y = -x*cot⍺) and the line y = 0 will be\n * rotated by β (y = x*tanβ). A line y = x*tanϴ (i.e. a line at angle ϴ to the x-axis in local-space) will\n * be rotated by an angle between ⍺ and β.\n * </p>\n * <p>\n * It can be observed that if skew is applied equally to both axes, then it will be equivalent to applying\n * a rotation. Indeed, if \"skew.x\" = -ϴ and \"skew.y\" = ϴ, it will produce an equivalent of \"rotation\" = ϴ.\n * </p>\n * <p>\n * Another quite interesting observation is that \"skew.x\", \"skew.y\", rotation are communtative operations. Indeed,\n * because rotation is essentially a careful combination of the two.\n * </p>\n * </td>\n * </tr>\n * <tr>\n * <td>angle</td>\n * <td>Rotation. This is an alias for [rotation]{@link PIXI.DisplayObject#rotation}, but in degrees.</td>\n * </tr>\n * <tr>\n * <td>x</td>\n * <td>Translation. This is an alias for position.x!</td>\n * </tr>\n * <tr>\n * <td>y</td>\n * <td>Translation. This is an alias for position.y!</td>\n * </tr>\n * <tr>\n * <td>width</td>\n * <td>\n * Implemented in [Container]{@link PIXI.Container}. Scaling. The width property calculates scale.x by dividing\n * the \"requested\" width by the local bounding box width. It is indirectly an abstraction over scale.x, and there\n * is no concept of user-defined width.\n * </td>\n * </tr>\n * <tr>\n * <td>height</td>\n * <td>\n * Implemented in [Container]{@link PIXI.Container}. Scaling. The height property calculates scale.y by dividing\n * the \"requested\" height by the local bounding box height. It is indirectly an abstraction over scale.y, and there\n * is no concept of user-defined height.\n * </td>\n * </tr>\n * </tbody>\n * </table>\n *\n * ## Bounds\n *\n * The bounds of a display object is defined by the minimum axis-aligned rectangle in world space that can fit\n * around it. The abstract `calculateBounds` method is responsible for providing it (and it should use the\n * `worldTransform` to calculate in world space).\n *\n * There are a few additional types of bounding boxes:\n *\n * | Bounds | Description |\n * | --------------------- | ---------------------------------------------------------------------------------------- |\n * | World Bounds | This is synonymous is the regular bounds described above. See `getBounds()`. |\n * | Local Bounds | This the axis-aligned bounding box in the parent's local space. See `getLocalBounds()`. |\n * | Render Bounds | The bounds, but including extra rendering effects like filter padding. |\n * | Projected Bounds | The bounds of the projected display object onto the screen. Usually equals world bounds. |\n * | Relative Bounds | The bounds of a display object when projected onto a ancestor's (or parent's) space. |\n * | Natural Bounds | The bounds of an object in its own local space (not parent's space, like in local bounds)|\n * | Content Bounds | The natural bounds when excluding all children of a `Container`. |\n *\n * ### calculateBounds\n *\n * [Container]{@link Container} already implements `calculateBounds` in a manner that includes children.\n *\n * But for a non-Container display object, the `calculateBounds` method must be overridden in order for `getBounds` and\n * `getLocalBounds` to work. This method must write the bounds into `this._bounds`.\n *\n * Generally, the following technique works for most simple cases: take the list of points\n * forming the \"hull\" of the object (i.e. outline of the object's shape), and then add them\n * using {@link PIXI.Bounds#addPointMatrix}.\n *\n * ```js\n * calculateBounds(): void\n * {\n * const points = [...];\n *\n * for (let i = 0, j = points.length; i < j; i++)\n * {\n * this._bounds.addPointMatrix(this.worldTransform, points[i]);\n * }\n * }\n * ```\n *\n * You can optimize this for a large number of points by using {@link PIXI.Bounds#addVerticesMatrix} to pass them\n * in one array together.\n *\n * ## Alpha\n *\n * This alpha sets a display object's **relative opacity** w.r.t its parent. For example, if the alpha of a display\n * object is 0.5 and its parent's alpha is 0.5, then it will be rendered with 25% opacity (assuming alpha is not\n * applied on any ancestor further up the chain).\n *\n * The alpha with which the display object will be rendered is called the [worldAlpha]{@link PIXI.DisplayObject#worldAlpha}.\n *\n * ## Renderable vs Visible\n *\n * The `renderable` and `visible` properties can be used to prevent a display object from being rendered to the\n * screen. However, there is a subtle difference between the two. When using `renderable`, the transforms of the display\n * object (and its children subtree) will continue to be calculated. When using `visible`, the transforms will not\n * be calculated.\n *\n * It is recommended that applications use the `renderable` property for culling. See\n * [@pixi-essentials/cull]{@link https://www.npmjs.com/package/@pixi-essentials/cull} or\n * [pixi-cull]{@link https://www.npmjs.com/package/pixi-cull} for more details.\n *\n * Otherwise, to prevent an object from rendering in the general-purpose sense - `visible` is the property to use. This\n * one is also better in terms of performance.\n *\n * @memberof PIXI\n */\nvar DisplayObject = /** @class */ (function (_super) {\n __extends(DisplayObject, _super);\n function DisplayObject() {\n var _this = _super.call(this) || this;\n _this.tempDisplayObjectParent = null;\n // TODO: need to create Transform from factory\n _this.transform = new Transform();\n _this.alpha = 1;\n _this.visible = true;\n _this.renderable = true;\n _this.cullable = false;\n _this.cullArea = null;\n _this.parent = null;\n _this.worldAlpha = 1;\n _this._lastSortedIndex = 0;\n _this._zIndex = 0;\n _this.filterArea = null;\n _this.filters = null;\n _this._enabledFilters = null;\n _this._bounds = new Bounds();\n _this._localBounds = null;\n _this._boundsID = 0;\n _this._boundsRect = null;\n _this._localBoundsRect = null;\n _this._mask = null;\n _this._maskRefCount = 0;\n _this._destroyed = false;\n _this.isSprite = false;\n _this.isMask = false;\n return _this;\n }\n /**\n * Mixes all enumerable properties and methods from a source object to DisplayObject.\n *\n * @param source - The source of properties and methods to mix in.\n */\n DisplayObject.mixin = function (source) {\n // in ES8/ES2017, this would be really easy:\n // Object.defineProperties(DisplayObject.prototype, Object.getOwnPropertyDescriptors(source));\n // get all the enumerable property keys\n var keys = Object.keys(source);\n // loop through properties\n for (var i = 0; i < keys.length; ++i) {\n var propertyName = keys[i];\n // Set the property using the property descriptor - this works for accessors and normal value properties\n Object.defineProperty(DisplayObject.prototype, propertyName, Object.getOwnPropertyDescriptor(source, propertyName));\n }\n };\n Object.defineProperty(DisplayObject.prototype, \"destroyed\", {\n /**\n * Fired when this DisplayObject is added to a Container.\n *\n * @instance\n * @event added\n * @param {PIXI.Container} container - The container added to.\n */\n /**\n * Fired when this DisplayObject is removed from a Container.\n *\n * @instance\n * @event removed\n * @param {PIXI.Container} container - The container removed from.\n */\n /**\n * Fired when this DisplayObject is destroyed.\n *\n * @instance\n * @event destroyed\n */\n /** Readonly flag for destroyed display objects. */\n get: function () {\n return this._destroyed;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Recursively updates transform of all objects from the root to this one\n * internal function for toLocal()\n */\n DisplayObject.prototype._recursivePostUpdateTransform = function () {\n if (this.parent) {\n this.parent._recursivePostUpdateTransform();\n this.transform.updateTransform(this.parent.transform);\n }\n else {\n this.transform.updateTransform(this._tempDisplayObjectParent.transform);\n }\n };\n /**\n * Updates the object transform for rendering.\n *\n * TODO - Optimization pass!\n */\n DisplayObject.prototype.updateTransform = function () {\n this._boundsID++;\n this.transform.updateTransform(this.parent.transform);\n // multiply the alphas..\n this.worldAlpha = this.alpha * this.parent.worldAlpha;\n };\n /**\n * Calculates and returns the (world) bounds of the display object as a [Rectangle]{@link PIXI.Rectangle}.\n *\n * This method is expensive on containers with a large subtree (like the stage). This is because the bounds\n * of a container depend on its children's bounds, which recursively causes all bounds in the subtree to\n * be recalculated. The upside, however, is that calling `getBounds` once on a container will indeed update\n * the bounds of all children (the whole subtree, in fact). This side effect should be exploited by using\n * `displayObject._bounds.getRectangle()` when traversing through all the bounds in a scene graph. Otherwise,\n * calling `getBounds` on each object in a subtree will cause the total cost to increase quadratically as\n * its height increases.\n *\n * * The transforms of all objects in a container's **subtree** and of all **ancestors** are updated.\n * * The world bounds of all display objects in a container's **subtree** will also be recalculated.\n *\n * The `_bounds` object stores the last calculation of the bounds. You can use to entirely skip bounds\n * calculation if needed.\n *\n * ```js\n * const lastCalculatedBounds = displayObject._bounds.getRectangle(optionalRect);\n * ```\n *\n * Do know that usage of `getLocalBounds` can corrupt the `_bounds` of children (the whole subtree, actually). This\n * is a known issue that has not been solved. See [getLocalBounds]{@link PIXI.DisplayObject#getLocalBounds} for more\n * details.\n *\n * `getBounds` should be called with `skipUpdate` equal to `true` in a render() call. This is because the transforms\n * are guaranteed to be update-to-date. In fact, recalculating inside a render() call may cause corruption in certain\n * cases.\n *\n * @param skipUpdate - Setting to `true` will stop the transforms of the scene graph from\n * being updated. This means the calculation returned MAY be out of date BUT will give you a\n * nice performance boost.\n * @param rect - Optional rectangle to store the result of the bounds calculation.\n * @return - The minimum axis-aligned rectangle in world space that fits around this object.\n */\n DisplayObject.prototype.getBounds = function (skipUpdate, rect) {\n if (!skipUpdate) {\n if (!this.parent) {\n this.parent = this._tempDisplayObjectParent;\n this.updateTransform();\n this.parent = null;\n }\n else {\n this._recursivePostUpdateTransform();\n this.updateTransform();\n }\n }\n if (this._bounds.updateID !== this._boundsID) {\n this.calculateBounds();\n this._bounds.updateID = this._boundsID;\n }\n if (!rect) {\n if (!this._boundsRect) {\n this._boundsRect = new Rectangle();\n }\n rect = this._boundsRect;\n }\n return this._bounds.getRectangle(rect);\n };\n /**\n * Retrieves the local bounds of the displayObject as a rectangle object.\n *\n * @param rect - Optional rectangle to store the result of the bounds calculation.\n * @return - The rectangular bounding area.\n */\n DisplayObject.prototype.getLocalBounds = function (rect) {\n if (!rect) {\n if (!this._localBoundsRect) {\n this._localBoundsRect = new Rectangle();\n }\n rect = this._localBoundsRect;\n }\n if (!this._localBounds) {\n this._localBounds = new Bounds();\n }\n var transformRef = this.transform;\n var parentRef = this.parent;\n this.parent = null;\n this.transform = this._tempDisplayObjectParent.transform;\n var worldBounds = this._bounds;\n var worldBoundsID = this._boundsID;\n this._bounds = this._localBounds;\n var bounds = this.getBounds(false, rect);\n this.parent = parentRef;\n this.transform = transformRef;\n this._bounds = worldBounds;\n this._bounds.updateID += this._boundsID - worldBoundsID; // reflect side-effects\n return bounds;\n };\n /**\n * Calculates the global position of the display object.\n *\n * @param position - The world origin to calculate from.\n * @param point - A Point object in which to store the value, optional\n * (otherwise will create a new Point).\n * @param skipUpdate - Should we skip the update transform.\n * @return - A point object representing the position of this object.\n */\n DisplayObject.prototype.toGlobal = function (position, point, skipUpdate) {\n if (skipUpdate === void 0) { skipUpdate = false; }\n if (!skipUpdate) {\n this._recursivePostUpdateTransform();\n // this parent check is for just in case the item is a root object.\n // If it is we need to give it a temporary parent so that displayObjectUpdateTransform works correctly\n // this is mainly to avoid a parent check in the main loop. Every little helps for performance :)\n if (!this.parent) {\n this.parent = this._tempDisplayObjectParent;\n this.displayObjectUpdateTransform();\n this.parent = null;\n }\n else {\n this.displayObjectUpdateTransform();\n }\n }\n // don't need to update the lot\n return this.worldTransform.apply(position, point);\n };\n /**\n * Calculates the local position of the display object relative to another point.\n *\n * @param position - The world origin to calculate from.\n * @param from - The DisplayObject to calculate the global position from.\n * @param point - A Point object in which to store the value, optional\n * (otherwise will create a new Point).\n * @param skipUpdate - Should we skip the update transform\n * @return - A point object representing the position of this object\n */\n DisplayObject.prototype.toLocal = function (position, from, point, skipUpdate) {\n if (from) {\n position = from.toGlobal(position, point, skipUpdate);\n }\n if (!skipUpdate) {\n this._recursivePostUpdateTransform();\n // this parent check is for just in case the item is a root object.\n // If it is we need to give it a temporary parent so that displayObjectUpdateTransform works correctly\n // this is mainly to avoid a parent check in the main loop. Every little helps for performance :)\n if (!this.parent) {\n this.parent = this._tempDisplayObjectParent;\n this.displayObjectUpdateTransform();\n this.parent = null;\n }\n else {\n this.displayObjectUpdateTransform();\n }\n }\n // simply apply the matrix..\n return this.worldTransform.applyInverse(position, point);\n };\n /**\n * Set the parent Container of this DisplayObject.\n *\n * @param container - The Container to add this DisplayObject to.\n * @return - The Container that this DisplayObject was added to.\n */\n DisplayObject.prototype.setParent = function (container) {\n if (!container || !container.addChild) {\n throw new Error('setParent: Argument must be a Container');\n }\n container.addChild(this);\n return container;\n };\n /**\n * Convenience function to set the position, scale, skew and pivot at once.\n *\n * @param x - The X position\n * @param y - The Y position\n * @param scaleX - The X scale value\n * @param scaleY - The Y scale value\n * @param rotation - The rotation\n * @param skewX - The X skew value\n * @param skewY - The Y skew value\n * @param pivotX - The X pivot value\n * @param pivotY - The Y pivot value\n * @return - The DisplayObject instance\n */\n DisplayObject.prototype.setTransform = function (x, y, scaleX, scaleY, rotation, skewX, skewY, pivotX, pivotY) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (scaleX === void 0) { scaleX = 1; }\n if (scaleY === void 0) { scaleY = 1; }\n if (rotation === void 0) { rotation = 0; }\n if (skewX === void 0) { skewX = 0; }\n if (skewY === void 0) { skewY = 0; }\n if (pivotX === void 0) { pivotX = 0; }\n if (pivotY === void 0) { pivotY = 0; }\n this.position.x = x;\n this.position.y = y;\n this.scale.x = !scaleX ? 1 : scaleX;\n this.scale.y = !scaleY ? 1 : scaleY;\n this.rotation = rotation;\n this.skew.x = skewX;\n this.skew.y = skewY;\n this.pivot.x = pivotX;\n this.pivot.y = pivotY;\n return this;\n };\n /**\n * Base destroy method for generic display objects. This will automatically\n * remove the display object from its parent Container as well as remove\n * all current event listeners and internal references. Do not use a DisplayObject\n * after calling `destroy()`.\n */\n DisplayObject.prototype.destroy = function (_options) {\n if (this.parent) {\n this.parent.removeChild(this);\n }\n this.emit('destroyed');\n this.removeAllListeners();\n this.transform = null;\n this.parent = null;\n this._bounds = null;\n this.mask = null;\n this.cullArea = null;\n this.filters = null;\n this.filterArea = null;\n this.hitArea = null;\n this.interactive = false;\n this.interactiveChildren = false;\n this._destroyed = true;\n };\n Object.defineProperty(DisplayObject.prototype, \"_tempDisplayObjectParent\", {\n /**\n * @protected\n * @member {PIXI.Container}\n */\n get: function () {\n if (this.tempDisplayObjectParent === null) {\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n this.tempDisplayObjectParent = new TemporaryDisplayObject();\n }\n return this.tempDisplayObjectParent;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Used in Renderer, cacheAsBitmap and other places where you call an `updateTransform` on root\n *\n * ```\n * const cacheParent = elem.enableTempParent();\n * elem.updateTransform();\n * elem.disableTempParent(cacheParent);\n * ```\n *\n * @returns - current parent\n */\n DisplayObject.prototype.enableTempParent = function () {\n var myParent = this.parent;\n this.parent = this._tempDisplayObjectParent;\n return myParent;\n };\n /**\n * Pair method for `enableTempParent`\n *\n * @param cacheParent - Actual parent of element\n */\n DisplayObject.prototype.disableTempParent = function (cacheParent) {\n this.parent = cacheParent;\n };\n Object.defineProperty(DisplayObject.prototype, \"x\", {\n /**\n * The position of the displayObject on the x axis relative to the local coordinates of the parent.\n * An alias to position.x\n */\n get: function () {\n return this.position.x;\n },\n set: function (value) {\n this.transform.position.x = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"y\", {\n /**\n * The position of the displayObject on the y axis relative to the local coordinates of the parent.\n * An alias to position.y\n */\n get: function () {\n return this.position.y;\n },\n set: function (value) {\n this.transform.position.y = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"worldTransform\", {\n /**\n * Current transform of the object based on world (parent) factors.\n *\n * @readonly\n */\n get: function () {\n return this.transform.worldTransform;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"localTransform\", {\n /**\n * Current transform of the object based on local factors: position, scale, other stuff.\n *\n * @readonly\n */\n get: function () {\n return this.transform.localTransform;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"position\", {\n /**\n * The coordinate of the object relative to the local coordinates of the parent.\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.position;\n },\n set: function (value) {\n this.transform.position.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"scale\", {\n /**\n * The scale factors of this object along the local coordinate axes.\n *\n * The default scale is (1, 1).\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.scale;\n },\n set: function (value) {\n this.transform.scale.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"pivot\", {\n /**\n * The center of rotation, scaling, and skewing for this display object in its local space. The `position`\n * is the projection of `pivot` in the parent's local space.\n *\n * By default, the pivot is the origin (0, 0).\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.pivot;\n },\n set: function (value) {\n this.transform.pivot.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"skew\", {\n /**\n * The skew factor for the object in radians.\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.skew;\n },\n set: function (value) {\n this.transform.skew.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"rotation\", {\n /**\n * The rotation of the object in radians.\n * 'rotation' and 'angle' have the same effect on a display object; rotation is in radians, angle is in degrees.\n */\n get: function () {\n return this.transform.rotation;\n },\n set: function (value) {\n this.transform.rotation = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"angle\", {\n /**\n * The angle of the object in degrees.\n * 'rotation' and 'angle' have the same effect on a display object; rotation is in radians, angle is in degrees.\n */\n get: function () {\n return this.transform.rotation * RAD_TO_DEG;\n },\n set: function (value) {\n this.transform.rotation = value * DEG_TO_RAD;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"zIndex\", {\n /**\n * The zIndex of the displayObject.\n *\n * If a container has the sortableChildren property set to true, children will be automatically\n * sorted by zIndex value; a higher value will mean it will be moved towards the end of the array,\n * and thus rendered on top of other display objects within the same container.\n *\n * @see PIXI.Container#sortableChildren\n */\n get: function () {\n return this._zIndex;\n },\n set: function (value) {\n this._zIndex = value;\n if (this.parent) {\n this.parent.sortDirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"worldVisible\", {\n /**\n * Indicates if the object is globally visible.\n *\n * @readonly\n */\n get: function () {\n var item = this;\n do {\n if (!item.visible) {\n return false;\n }\n item = item.parent;\n } while (item);\n return true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"mask\", {\n /**\n * Sets a mask for the displayObject. A mask is an object that limits the visibility of an\n * object to the shape of the mask applied to it. In PixiJS a regular mask must be a\n * {@link PIXI.Graphics} or a {@link PIXI.Sprite} object. This allows for much faster masking in canvas as it\n * utilities shape clipping. To remove a mask, set this property to `null`.\n *\n * For sprite mask both alpha and red channel are used. Black mask is the same as transparent mask.\n *\n * @example\n * const graphics = new PIXI.Graphics();\n * graphics.beginFill(0xFF3300);\n * graphics.drawRect(50, 250, 100, 100);\n * graphics.endFill();\n *\n * const sprite = new PIXI.Sprite(texture);\n * sprite.mask = graphics;\n *\n * @todo At the moment, PIXI.CanvasRenderer doesn't support PIXI.Sprite as mask.\n */\n get: function () {\n return this._mask;\n },\n set: function (value) {\n if (this._mask === value) {\n return;\n }\n if (this._mask) {\n var maskObject = (this._mask.maskObject || this._mask);\n maskObject._maskRefCount--;\n if (maskObject._maskRefCount === 0) {\n maskObject.renderable = true;\n maskObject.isMask = false;\n }\n }\n this._mask = value;\n if (this._mask) {\n var maskObject = (this._mask.maskObject || this._mask);\n if (maskObject._maskRefCount === 0) {\n maskObject.renderable = false;\n maskObject.isMask = true;\n }\n maskObject._maskRefCount++;\n }\n },\n enumerable: false,\n configurable: true\n });\n return DisplayObject;\n}(EventEmitter));\n/**\n * @private\n */\nvar TemporaryDisplayObject = /** @class */ (function (_super) {\n __extends(TemporaryDisplayObject, _super);\n function TemporaryDisplayObject() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.sortDirty = null;\n return _this;\n }\n return TemporaryDisplayObject;\n}(DisplayObject));\n/**\n * DisplayObject default updateTransform, does not update children of container.\n * Will crash if there's no parent element.\n *\n * @memberof PIXI.DisplayObject#\n * @method displayObjectUpdateTransform\n */\nDisplayObject.prototype.displayObjectUpdateTransform = DisplayObject.prototype.updateTransform;\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\nfunction sortChildren(a, b) {\n if (a.zIndex === b.zIndex) {\n return a._lastSortedIndex - b._lastSortedIndex;\n }\n return a.zIndex - b.zIndex;\n}\n/**\n * Container is a general-purpose display object that holds children. It also adds built-in support for advanced\n * rendering features like masking and filtering.\n *\n * It is the base class of all display objects that act as a container for other objects, including Graphics\n * and Sprite.\n *\n * ```js\n * import { BlurFilter } from '@pixi/filter-blur';\n * import { Container } from '@pixi/display';\n * import { Graphics } from '@pixi/graphics';\n * import { Sprite } from '@pixi/sprite';\n *\n * let container = new Container();\n * let sprite = Sprite.from(\"https://s3-us-west-2.amazonaws.com/s.cdpn.io/693612/IaUrttj.png\");\n *\n * sprite.width = 512;\n * sprite.height = 512;\n *\n * // Adds a sprite as a child to this container. As a result, the sprite will be rendered whenever the container\n * // is rendered.\n * container.addChild(sprite);\n *\n * // Blurs whatever is rendered by the container\n * container.filters = [new BlurFilter()];\n *\n * // Only the contents within a circle at the center should be rendered onto the screen.\n * container.mask = new Graphics()\n * .beginFill(0xffffff)\n * .drawCircle(sprite.width / 2, sprite.height / 2, Math.min(sprite.width, sprite.height) / 2)\n * .endFill();\n * ```\n *\n * @memberof PIXI\n */\nvar Container = /** @class */ (function (_super) {\n __extends(Container, _super);\n function Container() {\n var _this = _super.call(this) || this;\n _this.children = [];\n _this.sortableChildren = settings.SORTABLE_CHILDREN;\n _this.sortDirty = false;\n return _this;\n /**\n * Fired when a DisplayObject is added to this Container.\n *\n * @event PIXI.Container#childAdded\n * @param {PIXI.DisplayObject} child - The child added to the Container.\n * @param {PIXI.Container} container - The container that added the child.\n * @param {number} index - The children's index of the added child.\n */\n /**\n * Fired when a DisplayObject is removed from this Container.\n *\n * @event PIXI.DisplayObject#removedFrom\n * @param {PIXI.DisplayObject} child - The child removed from the Container.\n * @param {PIXI.Container} container - The container that removed removed the child.\n * @param {number} index - The former children's index of the removed child\n */\n }\n /** Overridable method that can be used by Container subclasses whenever the children array is modified. */\n Container.prototype.onChildrenChange = function (_length) {\n /* empty */\n };\n /**\n * Adds one or more children to the container.\n *\n * Multiple items can be added like so: `myContainer.addChild(thingOne, thingTwo, thingThree)`\n *\n * @param {...PIXI.DisplayObject} children - The DisplayObject(s) to add to the container\n * @return {PIXI.DisplayObject} - The first child that was added.\n */\n Container.prototype.addChild = function () {\n var arguments$1 = arguments;\n\n var children = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n children[_i] = arguments$1[_i];\n }\n // if there is only one argument we can bypass looping through the them\n if (children.length > 1) {\n // loop through the array and add all children\n for (var i = 0; i < children.length; i++) {\n // eslint-disable-next-line prefer-rest-params\n this.addChild(children[i]);\n }\n }\n else {\n var child = children[0];\n // if the child has a parent then lets remove it as PixiJS objects can only exist in one place\n if (child.parent) {\n child.parent.removeChild(child);\n }\n child.parent = this;\n this.sortDirty = true;\n // ensure child transform will be recalculated\n child.transform._parentID = -1;\n this.children.push(child);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(this.children.length - 1);\n this.emit('childAdded', child, this, this.children.length - 1);\n child.emit('added', this);\n }\n return children[0];\n };\n /**\n * Adds a child to the container at a specified index. If the index is out of bounds an error will be thrown\n *\n * @param {PIXI.DisplayObject} child - The child to add\n * @param {number} index - The index to place the child in\n * @return {PIXI.DisplayObject} The child that was added.\n */\n Container.prototype.addChildAt = function (child, index) {\n if (index < 0 || index > this.children.length) {\n throw new Error(child + \"addChildAt: The index \" + index + \" supplied is out of bounds \" + this.children.length);\n }\n if (child.parent) {\n child.parent.removeChild(child);\n }\n child.parent = this;\n this.sortDirty = true;\n // ensure child transform will be recalculated\n child.transform._parentID = -1;\n this.children.splice(index, 0, child);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(index);\n child.emit('added', this);\n this.emit('childAdded', child, this, index);\n return child;\n };\n /**\n * Swaps the position of 2 Display Objects within this container.\n *\n * @param child - First display object to swap\n * @param child2 - Second display object to swap\n */\n Container.prototype.swapChildren = function (child, child2) {\n if (child === child2) {\n return;\n }\n var index1 = this.getChildIndex(child);\n var index2 = this.getChildIndex(child2);\n this.children[index1] = child2;\n this.children[index2] = child;\n this.onChildrenChange(index1 < index2 ? index1 : index2);\n };\n /**\n * Returns the index position of a child DisplayObject instance\n *\n * @param child - The DisplayObject instance to identify\n * @return - The index position of the child display object to identify\n */\n Container.prototype.getChildIndex = function (child) {\n var index = this.children.indexOf(child);\n if (index === -1) {\n throw new Error('The supplied DisplayObject must be a child of the caller');\n }\n return index;\n };\n /**\n * Changes the position of an existing child in the display object container\n *\n * @param child - The child DisplayObject instance for which you want to change the index number\n * @param index - The resulting index number for the child display object\n */\n Container.prototype.setChildIndex = function (child, index) {\n if (index < 0 || index >= this.children.length) {\n throw new Error(\"The index \" + index + \" supplied is out of bounds \" + this.children.length);\n }\n var currentIndex = this.getChildIndex(child);\n removeItems(this.children, currentIndex, 1); // remove from old position\n this.children.splice(index, 0, child); // add at new position\n this.onChildrenChange(index);\n };\n /**\n * Returns the child at the specified index\n *\n * @param index - The index to get the child at\n * @return - The child at the given index, if any.\n */\n Container.prototype.getChildAt = function (index) {\n if (index < 0 || index >= this.children.length) {\n throw new Error(\"getChildAt: Index (\" + index + \") does not exist.\");\n }\n return this.children[index];\n };\n /**\n * Removes one or more children from the container.\n *\n * @param {...PIXI.DisplayObject} children - The DisplayObject(s) to remove\n * @return {PIXI.DisplayObject} The first child that was removed.\n */\n Container.prototype.removeChild = function () {\n var arguments$1 = arguments;\n\n var children = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n children[_i] = arguments$1[_i];\n }\n // if there is only one argument we can bypass looping through the them\n if (children.length > 1) {\n // loop through the arguments property and remove all children\n for (var i = 0; i < children.length; i++) {\n this.removeChild(children[i]);\n }\n }\n else {\n var child = children[0];\n var index = this.children.indexOf(child);\n if (index === -1)\n { return null; }\n child.parent = null;\n // ensure child transform will be recalculated\n child.transform._parentID = -1;\n removeItems(this.children, index, 1);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(index);\n child.emit('removed', this);\n this.emit('childRemoved', child, this, index);\n }\n return children[0];\n };\n /**\n * Removes a child from the specified index position.\n *\n * @param index - The index to get the child from\n * @return The child that was removed.\n */\n Container.prototype.removeChildAt = function (index) {\n var child = this.getChildAt(index);\n // ensure child transform will be recalculated..\n child.parent = null;\n child.transform._parentID = -1;\n removeItems(this.children, index, 1);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(index);\n child.emit('removed', this);\n this.emit('childRemoved', child, this, index);\n return child;\n };\n /**\n * Removes all children from this container that are within the begin and end indexes.\n *\n * @param beginIndex - The beginning position.\n * @param endIndex - The ending position. Default value is size of the container.\n * @returns - List of removed children\n */\n Container.prototype.removeChildren = function (beginIndex, endIndex) {\n if (beginIndex === void 0) { beginIndex = 0; }\n if (endIndex === void 0) { endIndex = this.children.length; }\n var begin = beginIndex;\n var end = endIndex;\n var range = end - begin;\n var removed;\n if (range > 0 && range <= end) {\n removed = this.children.splice(begin, range);\n for (var i = 0; i < removed.length; ++i) {\n removed[i].parent = null;\n if (removed[i].transform) {\n removed[i].transform._parentID = -1;\n }\n }\n this._boundsID++;\n this.onChildrenChange(beginIndex);\n for (var i = 0; i < removed.length; ++i) {\n removed[i].emit('removed', this);\n this.emit('childRemoved', removed[i], this, i);\n }\n return removed;\n }\n else if (range === 0 && this.children.length === 0) {\n return [];\n }\n throw new RangeError('removeChildren: numeric values are outside the acceptable range.');\n };\n /** Sorts children by zIndex. Previous order is maintained for 2 children with the same zIndex. */\n Container.prototype.sortChildren = function () {\n var sortRequired = false;\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n child._lastSortedIndex = i;\n if (!sortRequired && child.zIndex !== 0) {\n sortRequired = true;\n }\n }\n if (sortRequired && this.children.length > 1) {\n this.children.sort(sortChildren);\n }\n this.sortDirty = false;\n };\n /** Updates the transform on all children of this container for rendering. */\n Container.prototype.updateTransform = function () {\n if (this.sortableChildren && this.sortDirty) {\n this.sortChildren();\n }\n this._boundsID++;\n this.transform.updateTransform(this.parent.transform);\n // TODO: check render flags, how to process stuff here\n this.worldAlpha = this.alpha * this.parent.worldAlpha;\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n if (child.visible) {\n child.updateTransform();\n }\n }\n };\n /**\n * Recalculates the bounds of the container.\n *\n * This implementation will automatically fit the children's bounds into the calculation. Each child's bounds\n * is limited to its mask's bounds or filterArea, if any is applied.\n */\n Container.prototype.calculateBounds = function () {\n this._bounds.clear();\n this._calculateBounds();\n for (var i = 0; i < this.children.length; i++) {\n var child = this.children[i];\n if (!child.visible || !child.renderable) {\n continue;\n }\n child.calculateBounds();\n // TODO: filter+mask, need to mask both somehow\n if (child._mask) {\n var maskObject = (child._mask.maskObject || child._mask);\n maskObject.calculateBounds();\n this._bounds.addBoundsMask(child._bounds, maskObject._bounds);\n }\n else if (child.filterArea) {\n this._bounds.addBoundsArea(child._bounds, child.filterArea);\n }\n else {\n this._bounds.addBounds(child._bounds);\n }\n }\n this._bounds.updateID = this._boundsID;\n };\n /**\n * Retrieves the local bounds of the displayObject as a rectangle object.\n *\n * Calling `getLocalBounds` may invalidate the `_bounds` of the whole subtree below. If using it inside a render()\n * call, it is advised to call `getBounds()` immediately after to recalculate the world bounds of the subtree.\n *\n * @param rect - Optional rectangle to store the result of the bounds calculation.\n * @param skipChildrenUpdate - Setting to `true` will stop re-calculation of children transforms,\n * it was default behaviour of pixi 4.0-5.2 and caused many problems to users.\n * @return - The rectangular bounding area.\n */\n Container.prototype.getLocalBounds = function (rect, skipChildrenUpdate) {\n if (skipChildrenUpdate === void 0) { skipChildrenUpdate = false; }\n var result = _super.prototype.getLocalBounds.call(this, rect);\n if (!skipChildrenUpdate) {\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n if (child.visible) {\n child.updateTransform();\n }\n }\n }\n return result;\n };\n /**\n * Recalculates the content bounds of this object. This should be overriden to\n * calculate the bounds of this specific object (not including children).\n *\n * @protected\n */\n Container.prototype._calculateBounds = function () {\n // FILL IN//\n };\n /**\n * Renders this object and its children with culling.\n *\n * @protected\n * @param {PIXI.Renderer} renderer - The renderer\n */\n Container.prototype._renderWithCulling = function (renderer) {\n var sourceFrame = renderer.renderTexture.sourceFrame;\n // If the source frame is empty, stop rendering.\n if (!(sourceFrame.width > 0 && sourceFrame.height > 0)) {\n return;\n }\n // Render the content of the container only if its bounds intersect with the source frame.\n // All filters are on the stack at this point, and the filter source frame is bound:\n // therefore, even if the bounds to non intersect the filter frame, the filter\n // is still applied and any filter padding that is in the frame is rendered correctly.\n var bounds;\n var transform;\n // If cullArea is set, we use this rectangle instead of the bounds of the object. The cullArea\n // rectangle must completely contain the container and its children including filter padding.\n if (this.cullArea) {\n bounds = this.cullArea;\n transform = this.worldTransform;\n }\n // If the container doesn't override _render, we can skip the bounds calculation and intersection test.\n else if (this._render !== Container.prototype._render) {\n bounds = this.getBounds(true);\n }\n // Render the container if the source frame intersects the bounds.\n if (bounds && sourceFrame.intersects(bounds, transform)) {\n this._render(renderer);\n }\n // If the bounds are defined by cullArea and do not intersect with the source frame, stop rendering.\n else if (this.cullArea) {\n return;\n }\n // Unless cullArea is set, we cannot skip the children if the bounds of the container do not intersect\n // the source frame, because the children might have filters with nonzero padding, which may intersect\n // with the source frame while the bounds do not: filter padding is not included in the bounds.\n // If cullArea is not set, render the children with culling temporarily enabled so that they are not rendered\n // if they are out of frame; otherwise, render the children normally.\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n var childCullable = child.cullable;\n child.cullable = childCullable || !this.cullArea;\n child.render(renderer);\n child.cullable = childCullable;\n }\n };\n /**\n * Renders the object using the WebGL renderer.\n *\n * The [_render]{@link PIXI.Container#_render} method is be overriden for rendering the contents of the\n * container itself. This `render` method will invoke it, and also invoke the `render` methods of all\n * children afterward.\n *\n * If `renderable` or `visible` is false or if `worldAlpha` is not positive or if `cullable` is true and\n * the bounds of this object are out of frame, this implementation will entirely skip rendering.\n * See {@link PIXI.DisplayObject} for choosing between `renderable` or `visible`. Generally,\n * setting alpha to zero is not recommended for purely skipping rendering.\n *\n * When your scene becomes large (especially when it is larger than can be viewed in a single screen), it is\n * advised to employ **culling** to automatically skip rendering objects outside of the current screen.\n * See [cullable]{@link PIXI.DisplayObject#cullable} and [cullArea]{@link PIXI.DisplayObject#cullArea}.\n * Other culling methods might be better suited for a large number static objects; see\n * [@pixi-essentials/cull]{@link https://www.npmjs.com/package/@pixi-essentials/cull} and\n * [pixi-cull]{@link https://www.npmjs.com/package/pixi-cull}.\n *\n * The [renderAdvanced]{@link PIXI.Container#renderAdvanced} method is internally used when when masking or\n * filtering is applied on a container. This does, however, break batching and can affect performance when\n * masking and filtering is applied extensively throughout the scene graph.\n *\n * @param renderer - The renderer\n */\n Container.prototype.render = function (renderer) {\n // if the object is not visible or the alpha is 0 then no need to render this element\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\n return;\n }\n // do a quick check to see if this element has a mask or a filter.\n if (this._mask || (this.filters && this.filters.length)) {\n this.renderAdvanced(renderer);\n }\n else if (this.cullable) {\n this._renderWithCulling(renderer);\n }\n else {\n this._render(renderer);\n for (var i = 0, j = this.children.length; i < j; ++i) {\n this.children[i].render(renderer);\n }\n }\n };\n /**\n * Render the object using the WebGL renderer and advanced features.\n *\n * @param renderer - The renderer\n */\n Container.prototype.renderAdvanced = function (renderer) {\n var filters = this.filters;\n var mask = this._mask;\n // push filter first as we need to ensure the stencil buffer is correct for any masking\n if (filters) {\n if (!this._enabledFilters) {\n this._enabledFilters = [];\n }\n this._enabledFilters.length = 0;\n for (var i = 0; i < filters.length; i++) {\n if (filters[i].enabled) {\n this._enabledFilters.push(filters[i]);\n }\n }\n }\n var flush = (filters && this._enabledFilters && this._enabledFilters.length)\n || (mask && (!mask.isMaskData\n || (mask.enabled && (mask.autoDetect || mask.type !== MASK_TYPES.NONE))));\n if (flush) {\n renderer.batch.flush();\n }\n if (filters && this._enabledFilters && this._enabledFilters.length) {\n renderer.filter.push(this, this._enabledFilters);\n }\n if (mask) {\n renderer.mask.push(this, this._mask);\n }\n if (this.cullable) {\n this._renderWithCulling(renderer);\n }\n else {\n this._render(renderer);\n for (var i = 0, j = this.children.length; i < j; ++i) {\n this.children[i].render(renderer);\n }\n }\n if (flush) {\n renderer.batch.flush();\n }\n if (mask) {\n renderer.mask.pop(this);\n }\n if (filters && this._enabledFilters && this._enabledFilters.length) {\n renderer.filter.pop();\n }\n };\n /**\n * To be overridden by the subclasses.\n *\n * @param renderer - The renderer\n */\n Container.prototype._render = function (_renderer) {\n // this is where content itself gets rendered...\n };\n /**\n * Removes all internal references and listeners as well as removes children from the display list.\n * Do not use a Container after calling `destroy`.\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the texture of the child sprite\n * @param {boolean} [options.baseTexture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the base texture of the child sprite\n */\n Container.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this);\n this.sortDirty = false;\n var destroyChildren = typeof options === 'boolean' ? options : options && options.children;\n var oldChildren = this.removeChildren(0, this.children.length);\n if (destroyChildren) {\n for (var i = 0; i < oldChildren.length; ++i) {\n oldChildren[i].destroy(options);\n }\n }\n };\n Object.defineProperty(Container.prototype, \"width\", {\n /** The width of the Container, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this.scale.x * this.getLocalBounds().width;\n },\n set: function (value) {\n var width = this.getLocalBounds().width;\n if (width !== 0) {\n this.scale.x = value / width;\n }\n else {\n this.scale.x = 1;\n }\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Container.prototype, \"height\", {\n /** The height of the Container, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this.scale.y * this.getLocalBounds().height;\n },\n set: function (value) {\n var height = this.getLocalBounds().height;\n if (height !== 0) {\n this.scale.y = value / height;\n }\n else {\n this.scale.y = 1;\n }\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n return Container;\n}(DisplayObject));\n/**\n * Container default updateTransform, does update children of container.\n * Will crash if there's no parent element.\n *\n * @memberof PIXI.Container#\n * @method containerUpdateTransform\n */\nContainer.prototype.containerUpdateTransform = Container.prototype.updateTransform;\n\nexport { Bounds, Container, DisplayObject, TemporaryDisplayObject };\n//# sourceMappingURL=display.js.map\n","/*!\n * @pixi/math - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/math is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Two Pi.\n *\n * @static\n * @member {number}\n * @memberof PIXI\n */\nvar PI_2 = Math.PI * 2;\n/**\n * Conversion factor for converting radians to degrees.\n *\n * @static\n * @member {number} RAD_TO_DEG\n * @memberof PIXI\n */\nvar RAD_TO_DEG = 180 / Math.PI;\n/**\n * Conversion factor for converting degrees to radians.\n *\n * @static\n * @member {number}\n * @memberof PIXI\n */\nvar DEG_TO_RAD = Math.PI / 180;\n/**\n * Constants that identify shapes, mainly to prevent `instanceof` calls.\n *\n * @static\n * @memberof PIXI\n * @enum {number}\n * @property {number} POLY Polygon\n * @property {number} RECT Rectangle\n * @property {number} CIRC Circle\n * @property {number} ELIP Ellipse\n * @property {number} RREC Rounded Rectangle\n */\nvar SHAPES;\n(function (SHAPES) {\n SHAPES[SHAPES[\"POLY\"] = 0] = \"POLY\";\n SHAPES[SHAPES[\"RECT\"] = 1] = \"RECT\";\n SHAPES[SHAPES[\"CIRC\"] = 2] = \"CIRC\";\n SHAPES[SHAPES[\"ELIP\"] = 3] = \"ELIP\";\n SHAPES[SHAPES[\"RREC\"] = 4] = \"RREC\";\n})(SHAPES || (SHAPES = {}));\n\n/**\n * The Point object represents a location in a two-dimensional coordinate system, where `x` represents\n * the position on the horizontal axis and `y` represents the position on the vertical axis\n *\n * @class\n * @memberof PIXI\n * @implements IPoint\n */\nvar Point = /** @class */ (function () {\n /** Creates a new `Point`\n * @param {number} [x=0] - position of the point on the x axis\n * @param {number} [y=0] - position of the point on the y axis\n */\n function Point(x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n /** Position of the point on the x axis */\n this.x = 0;\n /** Position of the point on the y axis */\n this.y = 0;\n this.x = x;\n this.y = y;\n }\n /** Creates a clone of this point\n * @returns A clone of this point\n */\n Point.prototype.clone = function () {\n return new Point(this.x, this.y);\n };\n /**\n * Copies `x` and `y` from the given point into this point\n *\n * @param p - The point to copy from\n * @returns The point instance itself\n */\n Point.prototype.copyFrom = function (p) {\n this.set(p.x, p.y);\n return this;\n };\n /**\n * Copies this point's x and y into the given point (`p`).\n *\n * @param p - The point to copy to. Can be any of type that is or extends `IPointData`\n * @returns The point (`p`) with values updated\n */\n Point.prototype.copyTo = function (p) {\n p.set(this.x, this.y);\n return p;\n };\n /**\n * Accepts another point (`p`) and returns `true` if the given point is equal to this point\n *\n * @param p - The point to check\n * @returns Returns `true` if both `x` and `y` are equal\n */\n Point.prototype.equals = function (p) {\n return (p.x === this.x) && (p.y === this.y);\n };\n /**\n * Sets the point to a new `x` and `y` position.\n * If `y` is omitted, both `x` and `y` will be set to `x`.\n *\n * @param {number} [x=0] - position of the point on the `x` axis\n * @param {number} [y=x] - position of the point on the `y` axis\n * @returns The point instance itself\n */\n Point.prototype.set = function (x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = x; }\n this.x = x;\n this.y = y;\n return this;\n };\n Point.prototype.toString = function () {\n return \"[@pixi/math:Point x=\" + this.x + \" y=\" + this.y + \"]\";\n };\n return Point;\n}());\n\nvar tempPoints = [new Point(), new Point(), new Point(), new Point()];\n/**\n * Size object, contains width and height\n *\n * @memberof PIXI\n * @typedef {object} ISize\n */\n/**\n * Rectangle object is an area defined by its position, as indicated by its top-left corner\n * point (x, y) and by its width and its height.\n *\n * @memberof PIXI\n */\nvar Rectangle = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the upper-left corner of the rectangle\n * @param y - The Y coordinate of the upper-left corner of the rectangle\n * @param width - The overall width of the rectangle\n * @param height - The overall height of the rectangle\n */\n function Rectangle(x, y, width, height) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n this.x = Number(x);\n this.y = Number(y);\n this.width = Number(width);\n this.height = Number(height);\n this.type = SHAPES.RECT;\n }\n Object.defineProperty(Rectangle.prototype, \"left\", {\n /** Returns the left edge of the rectangle. */\n get: function () {\n return this.x;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle.prototype, \"right\", {\n /** Returns the right edge of the rectangle. */\n get: function () {\n return this.x + this.width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle.prototype, \"top\", {\n /** Returns the top edge of the rectangle. */\n get: function () {\n return this.y;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle.prototype, \"bottom\", {\n /** Returns the bottom edge of the rectangle. */\n get: function () {\n return this.y + this.height;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle, \"EMPTY\", {\n /** A constant empty rectangle. */\n get: function () {\n return new Rectangle(0, 0, 0, 0);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Creates a clone of this Rectangle\n *\n * @return a copy of the rectangle\n */\n Rectangle.prototype.clone = function () {\n return new Rectangle(this.x, this.y, this.width, this.height);\n };\n /**\n * Copies another rectangle to this one.\n *\n * @param rectangle - The rectangle to copy from.\n * @return Returns itself.\n */\n Rectangle.prototype.copyFrom = function (rectangle) {\n this.x = rectangle.x;\n this.y = rectangle.y;\n this.width = rectangle.width;\n this.height = rectangle.height;\n return this;\n };\n /**\n * Copies this rectangle to another one.\n *\n * @param rectangle - The rectangle to copy to.\n * @return Returns given parameter.\n */\n Rectangle.prototype.copyTo = function (rectangle) {\n rectangle.x = this.x;\n rectangle.y = this.y;\n rectangle.width = this.width;\n rectangle.height = this.height;\n return rectangle;\n };\n /**\n * Checks whether the x and y coordinates given are contained within this Rectangle\n *\n * @param x - The X coordinate of the point to test\n * @param y - The Y coordinate of the point to test\n * @return Whether the x/y coordinates are within this Rectangle\n */\n Rectangle.prototype.contains = function (x, y) {\n if (this.width <= 0 || this.height <= 0) {\n return false;\n }\n if (x >= this.x && x < this.x + this.width) {\n if (y >= this.y && y < this.y + this.height) {\n return true;\n }\n }\n return false;\n };\n /**\n * Determines whether the `other` Rectangle transformed by `transform` intersects with `this` Rectangle object.\n * Returns true only if the area of the intersection is >0, this means that Rectangles\n * sharing a side are not overlapping. Another side effect is that an arealess rectangle\n * (width or height equal to zero) can't intersect any other rectangle.\n *\n * @param {Rectangle} other - The Rectangle to intersect with `this`.\n * @param {Matrix} transform - The transformation matrix of `other`.\n * @returns {boolean} A value of `true` if the transformed `other` Rectangle intersects with `this`; otherwise `false`.\n */\n Rectangle.prototype.intersects = function (other, transform) {\n if (!transform) {\n var x0_1 = this.x < other.x ? other.x : this.x;\n var x1_1 = this.right > other.right ? other.right : this.right;\n if (x1_1 <= x0_1) {\n return false;\n }\n var y0_1 = this.y < other.y ? other.y : this.y;\n var y1_1 = this.bottom > other.bottom ? other.bottom : this.bottom;\n return y1_1 > y0_1;\n }\n var x0 = this.left;\n var x1 = this.right;\n var y0 = this.top;\n var y1 = this.bottom;\n if (x1 <= x0 || y1 <= y0) {\n return false;\n }\n var lt = tempPoints[0].set(other.left, other.top);\n var lb = tempPoints[1].set(other.left, other.bottom);\n var rt = tempPoints[2].set(other.right, other.top);\n var rb = tempPoints[3].set(other.right, other.bottom);\n if (rt.x <= lt.x || lb.y <= lt.y) {\n return false;\n }\n var s = Math.sign((transform.a * transform.d) - (transform.b * transform.c));\n if (s === 0) {\n return false;\n }\n transform.apply(lt, lt);\n transform.apply(lb, lb);\n transform.apply(rt, rt);\n transform.apply(rb, rb);\n if (Math.max(lt.x, lb.x, rt.x, rb.x) <= x0\n || Math.min(lt.x, lb.x, rt.x, rb.x) >= x1\n || Math.max(lt.y, lb.y, rt.y, rb.y) <= y0\n || Math.min(lt.y, lb.y, rt.y, rb.y) >= y1) {\n return false;\n }\n var nx = s * (lb.y - lt.y);\n var ny = s * (lt.x - lb.x);\n var n00 = (nx * x0) + (ny * y0);\n var n10 = (nx * x1) + (ny * y0);\n var n01 = (nx * x0) + (ny * y1);\n var n11 = (nx * x1) + (ny * y1);\n if (Math.max(n00, n10, n01, n11) <= (nx * lt.x) + (ny * lt.y)\n || Math.min(n00, n10, n01, n11) >= (nx * rb.x) + (ny * rb.y)) {\n return false;\n }\n var mx = s * (lt.y - rt.y);\n var my = s * (rt.x - lt.x);\n var m00 = (mx * x0) + (my * y0);\n var m10 = (mx * x1) + (my * y0);\n var m01 = (mx * x0) + (my * y1);\n var m11 = (mx * x1) + (my * y1);\n if (Math.max(m00, m10, m01, m11) <= (mx * lt.x) + (my * lt.y)\n || Math.min(m00, m10, m01, m11) >= (mx * rb.x) + (my * rb.y)) {\n return false;\n }\n return true;\n };\n /**\n * Pads the rectangle making it grow in all directions.\n * If paddingY is omitted, both paddingX and paddingY will be set to paddingX.\n *\n * @param paddingX - The horizontal padding amount.\n * @param paddingY - The vertical padding amount.\n * @return Returns itself.\n */\n Rectangle.prototype.pad = function (paddingX, paddingY) {\n if (paddingX === void 0) { paddingX = 0; }\n if (paddingY === void 0) { paddingY = paddingX; }\n this.x -= paddingX;\n this.y -= paddingY;\n this.width += paddingX * 2;\n this.height += paddingY * 2;\n return this;\n };\n /**\n * Fits this rectangle around the passed one.\n *\n * @param rectangle - The rectangle to fit.\n * @return Returns itself.\n */\n Rectangle.prototype.fit = function (rectangle) {\n var x1 = Math.max(this.x, rectangle.x);\n var x2 = Math.min(this.x + this.width, rectangle.x + rectangle.width);\n var y1 = Math.max(this.y, rectangle.y);\n var y2 = Math.min(this.y + this.height, rectangle.y + rectangle.height);\n this.x = x1;\n this.width = Math.max(x2 - x1, 0);\n this.y = y1;\n this.height = Math.max(y2 - y1, 0);\n return this;\n };\n /**\n * Enlarges rectangle that way its corners lie on grid\n *\n * @param resolution - resolution\n * @param eps - precision\n * @return Returns itself.\n */\n Rectangle.prototype.ceil = function (resolution, eps) {\n if (resolution === void 0) { resolution = 1; }\n if (eps === void 0) { eps = 0.001; }\n var x2 = Math.ceil((this.x + this.width - eps) * resolution) / resolution;\n var y2 = Math.ceil((this.y + this.height - eps) * resolution) / resolution;\n this.x = Math.floor((this.x + eps) * resolution) / resolution;\n this.y = Math.floor((this.y + eps) * resolution) / resolution;\n this.width = x2 - this.x;\n this.height = y2 - this.y;\n return this;\n };\n /**\n * Enlarges this rectangle to include the passed rectangle.\n *\n * @param rectangle - The rectangle to include.\n * @return Returns itself.\n */\n Rectangle.prototype.enlarge = function (rectangle) {\n var x1 = Math.min(this.x, rectangle.x);\n var x2 = Math.max(this.x + this.width, rectangle.x + rectangle.width);\n var y1 = Math.min(this.y, rectangle.y);\n var y2 = Math.max(this.y + this.height, rectangle.y + rectangle.height);\n this.x = x1;\n this.width = x2 - x1;\n this.y = y1;\n this.height = y2 - y1;\n return this;\n };\n Rectangle.prototype.toString = function () {\n return \"[@pixi/math:Rectangle x=\" + this.x + \" y=\" + this.y + \" width=\" + this.width + \" height=\" + this.height + \"]\";\n };\n return Rectangle;\n}());\n\n/**\n * The Circle object is used to help draw graphics and can also be used to specify a hit area for displayObjects.\n *\n * @memberof PIXI\n */\nvar Circle = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the center of this circle\n * @param y - The Y coordinate of the center of this circle\n * @param radius - The radius of the circle\n */\n function Circle(x, y, radius) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (radius === void 0) { radius = 0; }\n this.x = x;\n this.y = y;\n this.radius = radius;\n this.type = SHAPES.CIRC;\n }\n /**\n * Creates a clone of this Circle instance\n *\n * @return A copy of the Circle\n */\n Circle.prototype.clone = function () {\n return new Circle(this.x, this.y, this.radius);\n };\n /**\n * Checks whether the x and y coordinates given are contained within this circle\n *\n * @param x - The X coordinate of the point to test\n * @param y - The Y coordinate of the point to test\n * @return Whether the x/y coordinates are within this Circle\n */\n Circle.prototype.contains = function (x, y) {\n if (this.radius <= 0) {\n return false;\n }\n var r2 = this.radius * this.radius;\n var dx = (this.x - x);\n var dy = (this.y - y);\n dx *= dx;\n dy *= dy;\n return (dx + dy <= r2);\n };\n /**\n * Returns the framing rectangle of the circle as a Rectangle object\n *\n * @return The framing rectangle\n */\n Circle.prototype.getBounds = function () {\n return new Rectangle(this.x - this.radius, this.y - this.radius, this.radius * 2, this.radius * 2);\n };\n Circle.prototype.toString = function () {\n return \"[@pixi/math:Circle x=\" + this.x + \" y=\" + this.y + \" radius=\" + this.radius + \"]\";\n };\n return Circle;\n}());\n\n/**\n * The Ellipse object is used to help draw graphics and can also be used to specify a hit area for displayObjects.\n *\n * @memberof PIXI\n */\nvar Ellipse = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the center of this ellipse\n * @param y - The Y coordinate of the center of this ellipse\n * @param halfWidth - The half width of this ellipse\n * @param halfHeight - The half height of this ellipse\n */\n function Ellipse(x, y, halfWidth, halfHeight) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (halfWidth === void 0) { halfWidth = 0; }\n if (halfHeight === void 0) { halfHeight = 0; }\n this.x = x;\n this.y = y;\n this.width = halfWidth;\n this.height = halfHeight;\n this.type = SHAPES.ELIP;\n }\n /**\n * Creates a clone of this Ellipse instance\n *\n * @return {PIXI.Ellipse} A copy of the ellipse\n */\n Ellipse.prototype.clone = function () {\n return new Ellipse(this.x, this.y, this.width, this.height);\n };\n /**\n * Checks whether the x and y coordinates given are contained within this ellipse\n *\n * @param x - The X coordinate of the point to test\n * @param y - The Y coordinate of the point to test\n * @return Whether the x/y coords are within this ellipse\n */\n Ellipse.prototype.contains = function (x, y) {\n if (this.width <= 0 || this.height <= 0) {\n return false;\n }\n // normalize the coords to an ellipse with center 0,0\n var normx = ((x - this.x) / this.width);\n var normy = ((y - this.y) / this.height);\n normx *= normx;\n normy *= normy;\n return (normx + normy <= 1);\n };\n /**\n * Returns the framing rectangle of the ellipse as a Rectangle object\n *\n * @return The framing rectangle\n */\n Ellipse.prototype.getBounds = function () {\n return new Rectangle(this.x - this.width, this.y - this.height, this.width, this.height);\n };\n Ellipse.prototype.toString = function () {\n return \"[@pixi/math:Ellipse x=\" + this.x + \" y=\" + this.y + \" width=\" + this.width + \" height=\" + this.height + \"]\";\n };\n return Ellipse;\n}());\n\n/**\n * A class to define a shape via user defined coordinates.\n *\n * @memberof PIXI\n */\nvar Polygon = /** @class */ (function () {\n /**\n * @param {PIXI.IPointData[]|number[]} points - This can be an array of Points\n * that form the polygon, a flat array of numbers that will be interpreted as [x,y, x,y, ...], or\n * the arguments passed can be all the points of the polygon e.g.\n * `new PIXI.Polygon(new PIXI.Point(), new PIXI.Point(), ...)`, or the arguments passed can be flat\n * x,y values e.g. `new Polygon(x,y, x,y, x,y, ...)` where `x` and `y` are Numbers.\n */\n function Polygon() {\n var arguments$1 = arguments;\n\n var points = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n points[_i] = arguments$1[_i];\n }\n var flat = Array.isArray(points[0]) ? points[0] : points;\n // if this is an array of points, convert it to a flat array of numbers\n if (typeof flat[0] !== 'number') {\n var p = [];\n for (var i = 0, il = flat.length; i < il; i++) {\n p.push(flat[i].x, flat[i].y);\n }\n flat = p;\n }\n this.points = flat;\n this.type = SHAPES.POLY;\n this.closeStroke = true;\n }\n /**\n * Creates a clone of this polygon.\n *\n * @return - A copy of the polygon.\n */\n Polygon.prototype.clone = function () {\n var points = this.points.slice();\n var polygon = new Polygon(points);\n polygon.closeStroke = this.closeStroke;\n return polygon;\n };\n /**\n * Checks whether the x and y coordinates passed to this function are contained within this polygon.\n *\n * @param x - The X coordinate of the point to test.\n * @param y - The Y coordinate of the point to test.\n * @return - Whether the x/y coordinates are within this polygon.\n */\n Polygon.prototype.contains = function (x, y) {\n var inside = false;\n // use some raycasting to test hits\n // https://github.com/substack/point-in-polygon/blob/master/index.js\n var length = this.points.length / 2;\n for (var i = 0, j = length - 1; i < length; j = i++) {\n var xi = this.points[i * 2];\n var yi = this.points[(i * 2) + 1];\n var xj = this.points[j * 2];\n var yj = this.points[(j * 2) + 1];\n var intersect = ((yi > y) !== (yj > y)) && (x < ((xj - xi) * ((y - yi) / (yj - yi))) + xi);\n if (intersect) {\n inside = !inside;\n }\n }\n return inside;\n };\n Polygon.prototype.toString = function () {\n return \"[@pixi/math:Polygon\"\n + (\"closeStroke=\" + this.closeStroke)\n + (\"points=\" + this.points.reduce(function (pointsDesc, currentPoint) { return pointsDesc + \", \" + currentPoint; }, '') + \"]\");\n };\n return Polygon;\n}());\n\n/**\n * The Rounded Rectangle object is an area that has nice rounded corners, as indicated by its\n * top-left corner point (x, y) and by its width and its height and its radius.\n *\n * @memberof PIXI\n */\nvar RoundedRectangle = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the upper-left corner of the rounded rectangle\n * @param y - The Y coordinate of the upper-left corner of the rounded rectangle\n * @param width - The overall width of this rounded rectangle\n * @param height - The overall height of this rounded rectangle\n * @param radius - Controls the radius of the rounded corners\n */\n function RoundedRectangle(x, y, width, height, radius) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n if (radius === void 0) { radius = 20; }\n this.x = x;\n this.y = y;\n this.width = width;\n this.height = height;\n this.radius = radius;\n this.type = SHAPES.RREC;\n }\n /**\n * Creates a clone of this Rounded Rectangle.\n *\n * @return - A copy of the rounded rectangle.\n */\n RoundedRectangle.prototype.clone = function () {\n return new RoundedRectangle(this.x, this.y, this.width, this.height, this.radius);\n };\n /**\n * Checks whether the x and y coordinates given are contained within this Rounded Rectangle\n *\n * @param x - The X coordinate of the point to test.\n * @param y - The Y coordinate of the point to test.\n * @return - Whether the x/y coordinates are within this Rounded Rectangle.\n */\n RoundedRectangle.prototype.contains = function (x, y) {\n if (this.width <= 0 || this.height <= 0) {\n return false;\n }\n if (x >= this.x && x <= this.x + this.width) {\n if (y >= this.y && y <= this.y + this.height) {\n var radius = Math.max(0, Math.min(this.radius, Math.min(this.width, this.height) / 2));\n if ((y >= this.y + radius && y <= this.y + this.height - radius)\n || (x >= this.x + radius && x <= this.x + this.width - radius)) {\n return true;\n }\n var dx = x - (this.x + radius);\n var dy = y - (this.y + radius);\n var radius2 = radius * radius;\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n dx = x - (this.x + this.width - radius);\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n dy = y - (this.y + this.height - radius);\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n dx = x - (this.x + radius);\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n }\n }\n return false;\n };\n RoundedRectangle.prototype.toString = function () {\n return \"[@pixi/math:RoundedRectangle x=\" + this.x + \" y=\" + this.y\n + (\"width=\" + this.width + \" height=\" + this.height + \" radius=\" + this.radius + \"]\");\n };\n return RoundedRectangle;\n}());\n\n/**\n * The ObservablePoint object represents a location in a two-dimensional coordinate system, where `x` represents\n * the position on the horizontal axis and `y` represents the position on the vertical axis.\n *\n * An `ObservablePoint` is a point that triggers a callback when the point's position is changed.\n *\n * @memberof PIXI\n */\nvar ObservablePoint = /** @class */ (function () {\n /**\n * Creates a new `ObservablePoint`\n *\n * @param cb - callback function triggered when `x` and/or `y` are changed\n * @param scope - owner of callback\n * @param {number} [x=0] - position of the point on the x axis\n * @param {number} [y=0] - position of the point on the y axis\n */\n function ObservablePoint(cb, scope, x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n this._x = x;\n this._y = y;\n this.cb = cb;\n this.scope = scope;\n }\n /**\n * Creates a clone of this point.\n * The callback and scope params can be overridden otherwise they will default\n * to the clone object's values.\n *\n * @override\n * @param cb - The callback function triggered when `x` and/or `y` are changed\n * @param scope - The owner of the callback\n * @return a copy of this observable point\n */\n ObservablePoint.prototype.clone = function (cb, scope) {\n if (cb === void 0) { cb = this.cb; }\n if (scope === void 0) { scope = this.scope; }\n return new ObservablePoint(cb, scope, this._x, this._y);\n };\n /**\n * Sets the point to a new `x` and `y` position.\n * If `y` is omitted, both `x` and `y` will be set to `x`.\n *\n * @param {number} [x=0] - position of the point on the x axis\n * @param {number} [y=x] - position of the point on the y axis\n * @returns The observable point instance itself\n */\n ObservablePoint.prototype.set = function (x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = x; }\n if (this._x !== x || this._y !== y) {\n this._x = x;\n this._y = y;\n this.cb.call(this.scope);\n }\n return this;\n };\n /**\n * Copies x and y from the given point (`p`)\n *\n * @param p - The point to copy from. Can be any of type that is or extends `IPointData`\n * @returns The observable point instance itself\n */\n ObservablePoint.prototype.copyFrom = function (p) {\n if (this._x !== p.x || this._y !== p.y) {\n this._x = p.x;\n this._y = p.y;\n this.cb.call(this.scope);\n }\n return this;\n };\n /**\n * Copies this point's x and y into that of the given point (`p`)\n *\n * @param p - The point to copy to. Can be any of type that is or extends `IPointData`\n * @returns The point (`p`) with values updated\n */\n ObservablePoint.prototype.copyTo = function (p) {\n p.set(this._x, this._y);\n return p;\n };\n /**\n * Accepts another point (`p`) and returns `true` if the given point is equal to this point\n *\n * @param p - The point to check\n * @returns Returns `true` if both `x` and `y` are equal\n */\n ObservablePoint.prototype.equals = function (p) {\n return (p.x === this._x) && (p.y === this._y);\n };\n ObservablePoint.prototype.toString = function () {\n return \"[@pixi/math:ObservablePoint x=\" + 0 + \" y=\" + 0 + \" scope=\" + this.scope + \"]\";\n };\n Object.defineProperty(ObservablePoint.prototype, \"x\", {\n /** Position of the observable point on the x axis. */\n get: function () {\n return this._x;\n },\n set: function (value) {\n if (this._x !== value) {\n this._x = value;\n this.cb.call(this.scope);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ObservablePoint.prototype, \"y\", {\n /** Position of the observable point on the y axis. */\n get: function () {\n return this._y;\n },\n set: function (value) {\n if (this._y !== value) {\n this._y = value;\n this.cb.call(this.scope);\n }\n },\n enumerable: false,\n configurable: true\n });\n return ObservablePoint;\n}());\n\n/**\n * The PixiJS Matrix as a class makes it a lot faster.\n *\n * Here is a representation of it:\n * ```js\n * | a | c | tx|\n * | b | d | ty|\n * | 0 | 0 | 1 |\n * ```\n *\n * @memberof PIXI\n */\nvar Matrix = /** @class */ (function () {\n /**\n * @param a - x scale\n * @param b - y skew\n * @param c - x skew\n * @param d - y scale\n * @param tx - x translation\n * @param ty - y translation\n */\n function Matrix(a, b, c, d, tx, ty) {\n if (a === void 0) { a = 1; }\n if (b === void 0) { b = 0; }\n if (c === void 0) { c = 0; }\n if (d === void 0) { d = 1; }\n if (tx === void 0) { tx = 0; }\n if (ty === void 0) { ty = 0; }\n this.array = null;\n this.a = a;\n this.b = b;\n this.c = c;\n this.d = d;\n this.tx = tx;\n this.ty = ty;\n }\n /**\n * Creates a Matrix object based on the given array. The Element to Matrix mapping order is as follows:\n *\n * a = array[0]\n * b = array[1]\n * c = array[3]\n * d = array[4]\n * tx = array[2]\n * ty = array[5]\n *\n * @param array - The array that the matrix will be populated from.\n */\n Matrix.prototype.fromArray = function (array) {\n this.a = array[0];\n this.b = array[1];\n this.c = array[3];\n this.d = array[4];\n this.tx = array[2];\n this.ty = array[5];\n };\n /**\n * Sets the matrix properties.\n *\n * @param a - Matrix component\n * @param b - Matrix component\n * @param c - Matrix component\n * @param d - Matrix component\n * @param tx - Matrix component\n * @param ty - Matrix component\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.set = function (a, b, c, d, tx, ty) {\n this.a = a;\n this.b = b;\n this.c = c;\n this.d = d;\n this.tx = tx;\n this.ty = ty;\n return this;\n };\n /**\n * Creates an array from the current Matrix object.\n *\n * @param transpose - Whether we need to transpose the matrix or not\n * @param [out=new Float32Array(9)] - If provided the array will be assigned to out\n * @return The newly created array which contains the matrix\n */\n Matrix.prototype.toArray = function (transpose, out) {\n if (!this.array) {\n this.array = new Float32Array(9);\n }\n var array = out || this.array;\n if (transpose) {\n array[0] = this.a;\n array[1] = this.b;\n array[2] = 0;\n array[3] = this.c;\n array[4] = this.d;\n array[5] = 0;\n array[6] = this.tx;\n array[7] = this.ty;\n array[8] = 1;\n }\n else {\n array[0] = this.a;\n array[1] = this.c;\n array[2] = this.tx;\n array[3] = this.b;\n array[4] = this.d;\n array[5] = this.ty;\n array[6] = 0;\n array[7] = 0;\n array[8] = 1;\n }\n return array;\n };\n /**\n * Get a new position with the current transformation applied.\n * Can be used to go from a child's coordinate space to the world coordinate space. (e.g. rendering)\n *\n * @param pos - The origin\n * @param {PIXI.Point} [newPos] - The point that the new position is assigned to (allowed to be same as input)\n * @return {PIXI.Point} The new point, transformed through this matrix\n */\n Matrix.prototype.apply = function (pos, newPos) {\n newPos = (newPos || new Point());\n var x = pos.x;\n var y = pos.y;\n newPos.x = (this.a * x) + (this.c * y) + this.tx;\n newPos.y = (this.b * x) + (this.d * y) + this.ty;\n return newPos;\n };\n /**\n * Get a new position with the inverse of the current transformation applied.\n * Can be used to go from the world coordinate space to a child's coordinate space. (e.g. input)\n *\n * @param pos - The origin\n * @param {PIXI.Point} [newPos] - The point that the new position is assigned to (allowed to be same as input)\n * @return {PIXI.Point} The new point, inverse-transformed through this matrix\n */\n Matrix.prototype.applyInverse = function (pos, newPos) {\n newPos = (newPos || new Point());\n var id = 1 / ((this.a * this.d) + (this.c * -this.b));\n var x = pos.x;\n var y = pos.y;\n newPos.x = (this.d * id * x) + (-this.c * id * y) + (((this.ty * this.c) - (this.tx * this.d)) * id);\n newPos.y = (this.a * id * y) + (-this.b * id * x) + (((-this.ty * this.a) + (this.tx * this.b)) * id);\n return newPos;\n };\n /**\n * Translates the matrix on the x and y.\n *\n * @param x - How much to translate x by\n * @param y - How much to translate y by\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.translate = function (x, y) {\n this.tx += x;\n this.ty += y;\n return this;\n };\n /**\n * Applies a scale transformation to the matrix.\n *\n * @param x - The amount to scale horizontally\n * @param y - The amount to scale vertically\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.scale = function (x, y) {\n this.a *= x;\n this.d *= y;\n this.c *= x;\n this.b *= y;\n this.tx *= x;\n this.ty *= y;\n return this;\n };\n /**\n * Applies a rotation transformation to the matrix.\n *\n * @param angle - The angle in radians.\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.rotate = function (angle) {\n var cos = Math.cos(angle);\n var sin = Math.sin(angle);\n var a1 = this.a;\n var c1 = this.c;\n var tx1 = this.tx;\n this.a = (a1 * cos) - (this.b * sin);\n this.b = (a1 * sin) + (this.b * cos);\n this.c = (c1 * cos) - (this.d * sin);\n this.d = (c1 * sin) + (this.d * cos);\n this.tx = (tx1 * cos) - (this.ty * sin);\n this.ty = (tx1 * sin) + (this.ty * cos);\n return this;\n };\n /**\n * Appends the given Matrix to this Matrix.\n *\n * @param matrix - The matrix to append.\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.append = function (matrix) {\n var a1 = this.a;\n var b1 = this.b;\n var c1 = this.c;\n var d1 = this.d;\n this.a = (matrix.a * a1) + (matrix.b * c1);\n this.b = (matrix.a * b1) + (matrix.b * d1);\n this.c = (matrix.c * a1) + (matrix.d * c1);\n this.d = (matrix.c * b1) + (matrix.d * d1);\n this.tx = (matrix.tx * a1) + (matrix.ty * c1) + this.tx;\n this.ty = (matrix.tx * b1) + (matrix.ty * d1) + this.ty;\n return this;\n };\n /**\n * Sets the matrix based on all the available properties\n *\n * @param x - Position on the x axis\n * @param y - Position on the y axis\n * @param pivotX - Pivot on the x axis\n * @param pivotY - Pivot on the y axis\n * @param scaleX - Scale on the x axis\n * @param scaleY - Scale on the y axis\n * @param rotation - Rotation in radians\n * @param skewX - Skew on the x axis\n * @param skewY - Skew on the y axis\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.setTransform = function (x, y, pivotX, pivotY, scaleX, scaleY, rotation, skewX, skewY) {\n this.a = Math.cos(rotation + skewY) * scaleX;\n this.b = Math.sin(rotation + skewY) * scaleX;\n this.c = -Math.sin(rotation - skewX) * scaleY;\n this.d = Math.cos(rotation - skewX) * scaleY;\n this.tx = x - ((pivotX * this.a) + (pivotY * this.c));\n this.ty = y - ((pivotX * this.b) + (pivotY * this.d));\n return this;\n };\n /**\n * Prepends the given Matrix to this Matrix.\n *\n * @param matrix - The matrix to prepend\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.prepend = function (matrix) {\n var tx1 = this.tx;\n if (matrix.a !== 1 || matrix.b !== 0 || matrix.c !== 0 || matrix.d !== 1) {\n var a1 = this.a;\n var c1 = this.c;\n this.a = (a1 * matrix.a) + (this.b * matrix.c);\n this.b = (a1 * matrix.b) + (this.b * matrix.d);\n this.c = (c1 * matrix.a) + (this.d * matrix.c);\n this.d = (c1 * matrix.b) + (this.d * matrix.d);\n }\n this.tx = (tx1 * matrix.a) + (this.ty * matrix.c) + matrix.tx;\n this.ty = (tx1 * matrix.b) + (this.ty * matrix.d) + matrix.ty;\n return this;\n };\n /**\n * Decomposes the matrix (x, y, scaleX, scaleY, and rotation) and sets the properties on to a transform.\n *\n * @param transform - The transform to apply the properties to.\n * @return The transform with the newly applied properties\n */\n Matrix.prototype.decompose = function (transform) {\n // sort out rotation / skew..\n var a = this.a;\n var b = this.b;\n var c = this.c;\n var d = this.d;\n var pivot = transform.pivot;\n var skewX = -Math.atan2(-c, d);\n var skewY = Math.atan2(b, a);\n var delta = Math.abs(skewX + skewY);\n if (delta < 0.00001 || Math.abs(PI_2 - delta) < 0.00001) {\n transform.rotation = skewY;\n transform.skew.x = transform.skew.y = 0;\n }\n else {\n transform.rotation = 0;\n transform.skew.x = skewX;\n transform.skew.y = skewY;\n }\n // next set scale\n transform.scale.x = Math.sqrt((a * a) + (b * b));\n transform.scale.y = Math.sqrt((c * c) + (d * d));\n // next set position\n transform.position.x = this.tx + ((pivot.x * a) + (pivot.y * c));\n transform.position.y = this.ty + ((pivot.x * b) + (pivot.y * d));\n return transform;\n };\n /**\n * Inverts this matrix\n *\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.invert = function () {\n var a1 = this.a;\n var b1 = this.b;\n var c1 = this.c;\n var d1 = this.d;\n var tx1 = this.tx;\n var n = (a1 * d1) - (b1 * c1);\n this.a = d1 / n;\n this.b = -b1 / n;\n this.c = -c1 / n;\n this.d = a1 / n;\n this.tx = ((c1 * this.ty) - (d1 * tx1)) / n;\n this.ty = -((a1 * this.ty) - (b1 * tx1)) / n;\n return this;\n };\n /**\n * Resets this Matrix to an identity (default) matrix.\n *\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.identity = function () {\n this.a = 1;\n this.b = 0;\n this.c = 0;\n this.d = 1;\n this.tx = 0;\n this.ty = 0;\n return this;\n };\n /**\n * Creates a new Matrix object with the same values as this one.\n *\n * @return A copy of this matrix. Good for chaining method calls.\n */\n Matrix.prototype.clone = function () {\n var matrix = new Matrix();\n matrix.a = this.a;\n matrix.b = this.b;\n matrix.c = this.c;\n matrix.d = this.d;\n matrix.tx = this.tx;\n matrix.ty = this.ty;\n return matrix;\n };\n /**\n * Changes the values of the given matrix to be the same as the ones in this matrix\n *\n * @param matrix - The matrix to copy to.\n * @return The matrix given in parameter with its values updated.\n */\n Matrix.prototype.copyTo = function (matrix) {\n matrix.a = this.a;\n matrix.b = this.b;\n matrix.c = this.c;\n matrix.d = this.d;\n matrix.tx = this.tx;\n matrix.ty = this.ty;\n return matrix;\n };\n /**\n * Changes the values of the matrix to be the same as the ones in given matrix\n *\n * @param {PIXI.Matrix} matrix - The matrix to copy from.\n * @return {PIXI.Matrix} this\n */\n Matrix.prototype.copyFrom = function (matrix) {\n this.a = matrix.a;\n this.b = matrix.b;\n this.c = matrix.c;\n this.d = matrix.d;\n this.tx = matrix.tx;\n this.ty = matrix.ty;\n return this;\n };\n Matrix.prototype.toString = function () {\n return \"[@pixi/math:Matrix a=\" + this.a + \" b=\" + this.b + \" c=\" + this.c + \" d=\" + this.d + \" tx=\" + this.tx + \" ty=\" + this.ty + \"]\";\n };\n Object.defineProperty(Matrix, \"IDENTITY\", {\n /**\n * A default (identity) matrix\n *\n * @readonly\n */\n get: function () {\n return new Matrix();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Matrix, \"TEMP_MATRIX\", {\n /**\n * A temp matrix\n *\n * @readonly\n */\n get: function () {\n return new Matrix();\n },\n enumerable: false,\n configurable: true\n });\n return Matrix;\n}());\n\n// Your friendly neighbour https://en.wikipedia.org/wiki/Dihedral_group\n/*\n * Transform matrix for operation n is:\n * | ux | vx |\n * | uy | vy |\n */\nvar ux = [1, 1, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, -1, -1, 0, 1];\nvar uy = [0, 1, 1, 1, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, -1, -1];\nvar vx = [0, -1, -1, -1, 0, 1, 1, 1, 0, 1, 1, 1, 0, -1, -1, -1];\nvar vy = [1, 1, 0, -1, -1, -1, 0, 1, -1, -1, 0, 1, 1, 1, 0, -1];\n/**\n * [Cayley Table]{@link https://en.wikipedia.org/wiki/Cayley_table}\n * for the composition of each rotation in the dihederal group D8.\n *\n * @type number[][]\n * @private\n */\nvar rotationCayley = [];\n/**\n * Matrices for each `GD8Symmetry` rotation.\n *\n * @type Matrix[]\n * @private\n */\nvar rotationMatrices = [];\n/*\n * Alias for {@code Math.sign}.\n */\nvar signum = Math.sign;\n/*\n * Initializes `rotationCayley` and `rotationMatrices`. It is called\n * only once below.\n */\nfunction init() {\n for (var i = 0; i < 16; i++) {\n var row = [];\n rotationCayley.push(row);\n for (var j = 0; j < 16; j++) {\n /* Multiplies rotation matrices i and j. */\n var _ux = signum((ux[i] * ux[j]) + (vx[i] * uy[j]));\n var _uy = signum((uy[i] * ux[j]) + (vy[i] * uy[j]));\n var _vx = signum((ux[i] * vx[j]) + (vx[i] * vy[j]));\n var _vy = signum((uy[i] * vx[j]) + (vy[i] * vy[j]));\n /* Finds rotation matrix matching the product and pushes it. */\n for (var k = 0; k < 16; k++) {\n if (ux[k] === _ux && uy[k] === _uy\n && vx[k] === _vx && vy[k] === _vy) {\n row.push(k);\n break;\n }\n }\n }\n }\n for (var i = 0; i < 16; i++) {\n var mat = new Matrix();\n mat.set(ux[i], uy[i], vx[i], vy[i], 0, 0);\n rotationMatrices.push(mat);\n }\n}\ninit();\n/**\n * @memberof PIXI\n * @typedef {number} GD8Symmetry\n * @see PIXI.groupD8\n */\n/**\n * Implements the dihedral group D8, which is similar to\n * [group D4]{@link http://mathworld.wolfram.com/DihedralGroupD4.html};\n * D8 is the same but with diagonals, and it is used for texture\n * rotations.\n *\n * The directions the U- and V- axes after rotation\n * of an angle of `a: GD8Constant` are the vectors `(uX(a), uY(a))`\n * and `(vX(a), vY(a))`. These aren't necessarily unit vectors.\n *\n * **Origin:**<br>\n * This is the small part of gameofbombs.com portal system. It works.\n *\n * @see PIXI.groupD8.E\n * @see PIXI.groupD8.SE\n * @see PIXI.groupD8.S\n * @see PIXI.groupD8.SW\n * @see PIXI.groupD8.W\n * @see PIXI.groupD8.NW\n * @see PIXI.groupD8.N\n * @see PIXI.groupD8.NE\n * @author Ivan @ivanpopelyshev\n * @namespace PIXI.groupD8\n * @memberof PIXI\n */\nvar groupD8 = {\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 0° | East |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n E: 0,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 45°↻ | Southeast |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n SE: 1,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 90°↻ | South |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n S: 2,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 135°↻ | Southwest |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n SW: 3,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 180° | West |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n W: 4,\n /**\n * | Rotation | Direction |\n * |-------------|--------------|\n * | -135°/225°↻ | Northwest |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n NW: 5,\n /**\n * | Rotation | Direction |\n * |-------------|--------------|\n * | -90°/270°↻ | North |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n N: 6,\n /**\n * | Rotation | Direction |\n * |-------------|--------------|\n * | -45°/315°↻ | Northeast |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n NE: 7,\n /**\n * Reflection about Y-axis.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n MIRROR_VERTICAL: 8,\n /**\n * Reflection about the main diagonal.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n MAIN_DIAGONAL: 10,\n /**\n * Reflection about X-axis.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n MIRROR_HORIZONTAL: 12,\n /**\n * Reflection about reverse diagonal.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n REVERSE_DIAGONAL: 14,\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The X-component of the U-axis\n * after rotating the axes.\n */\n uX: function (ind) { return ux[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The Y-component of the U-axis\n * after rotating the axes.\n */\n uY: function (ind) { return uy[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The X-component of the V-axis\n * after rotating the axes.\n */\n vX: function (ind) { return vx[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The Y-component of the V-axis\n * after rotating the axes.\n */\n vY: function (ind) { return vy[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotation - symmetry whose opposite\n * is needed. Only rotations have opposite symmetries while\n * reflections don't.\n * @return {PIXI.GD8Symmetry} The opposite symmetry of `rotation`\n */\n inv: function (rotation) {\n if (rotation & 8) // true only if between 8 & 15 (reflections)\n {\n return rotation & 15; // or rotation % 16\n }\n return (-rotation) & 7; // or (8 - rotation) % 8\n },\n /**\n * Composes the two D8 operations.\n *\n * Taking `^` as reflection:\n *\n * | | E=0 | S=2 | W=4 | N=6 | E^=8 | S^=10 | W^=12 | N^=14 |\n * |-------|-----|-----|-----|-----|------|-------|-------|-------|\n * | E=0 | E | S | W | N | E^ | S^ | W^ | N^ |\n * | S=2 | S | W | N | E | S^ | W^ | N^ | E^ |\n * | W=4 | W | N | E | S | W^ | N^ | E^ | S^ |\n * | N=6 | N | E | S | W | N^ | E^ | S^ | W^ |\n * | E^=8 | E^ | N^ | W^ | S^ | E | N | W | S |\n * | S^=10 | S^ | E^ | N^ | W^ | S | E | N | W |\n * | W^=12 | W^ | S^ | E^ | N^ | W | S | E | N |\n * | N^=14 | N^ | W^ | S^ | E^ | N | W | S | E |\n *\n * [This is a Cayley table]{@link https://en.wikipedia.org/wiki/Cayley_table}\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotationSecond - Second operation, which\n * is the row in the above cayley table.\n * @param {PIXI.GD8Symmetry} rotationFirst - First operation, which\n * is the column in the above cayley table.\n * @return {PIXI.GD8Symmetry} Composed operation\n */\n add: function (rotationSecond, rotationFirst) { return (rotationCayley[rotationSecond][rotationFirst]); },\n /**\n * Reverse of `add`.\n *\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotationSecond - Second operation\n * @param {PIXI.GD8Symmetry} rotationFirst - First operation\n * @return {PIXI.GD8Symmetry} Result\n */\n sub: function (rotationSecond, rotationFirst) { return (rotationCayley[rotationSecond][groupD8.inv(rotationFirst)]); },\n /**\n * Adds 180 degrees to rotation, which is a commutative\n * operation.\n *\n * @memberof PIXI.groupD8\n * @param {number} rotation - The number to rotate.\n * @returns {number} Rotated number\n */\n rotate180: function (rotation) { return rotation ^ 4; },\n /**\n * Checks if the rotation angle is vertical, i.e. south\n * or north. It doesn't work for reflections.\n *\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotation - The number to check.\n * @returns {boolean} Whether or not the direction is vertical\n */\n isVertical: function (rotation) { return (rotation & 3) === 2; },\n /**\n * Approximates the vector `V(dx,dy)` into one of the\n * eight directions provided by `groupD8`.\n *\n * @memberof PIXI.groupD8\n * @param {number} dx - X-component of the vector\n * @param {number} dy - Y-component of the vector\n * @return {PIXI.GD8Symmetry} Approximation of the vector into\n * one of the eight symmetries.\n */\n byDirection: function (dx, dy) {\n if (Math.abs(dx) * 2 <= Math.abs(dy)) {\n if (dy >= 0) {\n return groupD8.S;\n }\n return groupD8.N;\n }\n else if (Math.abs(dy) * 2 <= Math.abs(dx)) {\n if (dx > 0) {\n return groupD8.E;\n }\n return groupD8.W;\n }\n else if (dy > 0) {\n if (dx > 0) {\n return groupD8.SE;\n }\n return groupD8.SW;\n }\n else if (dx > 0) {\n return groupD8.NE;\n }\n return groupD8.NW;\n },\n /**\n * Helps sprite to compensate texture packer rotation.\n *\n * @memberof PIXI.groupD8\n * @param {PIXI.Matrix} matrix - sprite world matrix\n * @param {PIXI.GD8Symmetry} rotation - The rotation factor to use.\n * @param {number} tx - sprite anchoring\n * @param {number} ty - sprite anchoring\n */\n matrixAppendRotationInv: function (matrix, rotation, tx, ty) {\n if (tx === void 0) { tx = 0; }\n if (ty === void 0) { ty = 0; }\n // Packer used \"rotation\", we use \"inv(rotation)\"\n var mat = rotationMatrices[groupD8.inv(rotation)];\n mat.tx = tx;\n mat.ty = ty;\n matrix.append(mat);\n },\n};\n\n/**\n * Transform that takes care about its versions.\n *\n * @memberof PIXI\n */\nvar Transform = /** @class */ (function () {\n function Transform() {\n this.worldTransform = new Matrix();\n this.localTransform = new Matrix();\n this.position = new ObservablePoint(this.onChange, this, 0, 0);\n this.scale = new ObservablePoint(this.onChange, this, 1, 1);\n this.pivot = new ObservablePoint(this.onChange, this, 0, 0);\n this.skew = new ObservablePoint(this.updateSkew, this, 0, 0);\n this._rotation = 0;\n this._cx = 1;\n this._sx = 0;\n this._cy = 0;\n this._sy = 1;\n this._localID = 0;\n this._currentLocalID = 0;\n this._worldID = 0;\n this._parentID = 0;\n }\n /** Called when a value changes. */\n Transform.prototype.onChange = function () {\n this._localID++;\n };\n /** Called when the skew or the rotation changes. */\n Transform.prototype.updateSkew = function () {\n this._cx = Math.cos(this._rotation + this.skew.y);\n this._sx = Math.sin(this._rotation + this.skew.y);\n this._cy = -Math.sin(this._rotation - this.skew.x); // cos, added PI/2\n this._sy = Math.cos(this._rotation - this.skew.x); // sin, added PI/2\n this._localID++;\n };\n Transform.prototype.toString = function () {\n return \"[@pixi/math:Transform \"\n + (\"position=(\" + this.position.x + \", \" + this.position.y + \") \")\n + (\"rotation=\" + this.rotation + \" \")\n + (\"scale=(\" + this.scale.x + \", \" + this.scale.y + \") \")\n + (\"skew=(\" + this.skew.x + \", \" + this.skew.y + \") \")\n + \"]\";\n };\n /** Updates the local transformation matrix. */\n Transform.prototype.updateLocalTransform = function () {\n var lt = this.localTransform;\n if (this._localID !== this._currentLocalID) {\n // get the matrix values of the displayobject based on its transform properties..\n lt.a = this._cx * this.scale.x;\n lt.b = this._sx * this.scale.x;\n lt.c = this._cy * this.scale.y;\n lt.d = this._sy * this.scale.y;\n lt.tx = this.position.x - ((this.pivot.x * lt.a) + (this.pivot.y * lt.c));\n lt.ty = this.position.y - ((this.pivot.x * lt.b) + (this.pivot.y * lt.d));\n this._currentLocalID = this._localID;\n // force an update..\n this._parentID = -1;\n }\n };\n /**\n * Updates the local and the world transformation matrices.\n *\n * @param parentTransform - The parent transform\n */\n Transform.prototype.updateTransform = function (parentTransform) {\n var lt = this.localTransform;\n if (this._localID !== this._currentLocalID) {\n // get the matrix values of the displayobject based on its transform properties..\n lt.a = this._cx * this.scale.x;\n lt.b = this._sx * this.scale.x;\n lt.c = this._cy * this.scale.y;\n lt.d = this._sy * this.scale.y;\n lt.tx = this.position.x - ((this.pivot.x * lt.a) + (this.pivot.y * lt.c));\n lt.ty = this.position.y - ((this.pivot.x * lt.b) + (this.pivot.y * lt.d));\n this._currentLocalID = this._localID;\n // force an update..\n this._parentID = -1;\n }\n if (this._parentID !== parentTransform._worldID) {\n // concat the parent matrix with the objects transform.\n var pt = parentTransform.worldTransform;\n var wt = this.worldTransform;\n wt.a = (lt.a * pt.a) + (lt.b * pt.c);\n wt.b = (lt.a * pt.b) + (lt.b * pt.d);\n wt.c = (lt.c * pt.a) + (lt.d * pt.c);\n wt.d = (lt.c * pt.b) + (lt.d * pt.d);\n wt.tx = (lt.tx * pt.a) + (lt.ty * pt.c) + pt.tx;\n wt.ty = (lt.tx * pt.b) + (lt.ty * pt.d) + pt.ty;\n this._parentID = parentTransform._worldID;\n // update the id of the transform..\n this._worldID++;\n }\n };\n /**\n * Decomposes a matrix and sets the transforms properties based on it.\n *\n * @param matrix - The matrix to decompose\n */\n Transform.prototype.setFromMatrix = function (matrix) {\n matrix.decompose(this);\n this._localID++;\n };\n Object.defineProperty(Transform.prototype, \"rotation\", {\n /** The rotation of the object in radians. */\n get: function () {\n return this._rotation;\n },\n set: function (value) {\n if (this._rotation !== value) {\n this._rotation = value;\n this.updateSkew();\n }\n },\n enumerable: false,\n configurable: true\n });\n /** A default (identity) transform. */\n Transform.IDENTITY = new Transform();\n return Transform;\n}());\n\nexport { Circle, DEG_TO_RAD, Ellipse, Matrix, ObservablePoint, PI_2, Point, Polygon, RAD_TO_DEG, Rectangle, RoundedRectangle, SHAPES, Transform, groupD8 };\n//# sourceMappingURL=math.js.map\n","/*!\n * @pixi/particle-emitter - v5.0.4\n * Compiled Thu, 10 Mar 2022 03:05:06 UTC\n *\n * @pixi/particle-emitter is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture } from '@pixi/core';\nimport { BLEND_MODES } from '@pixi/constants';\nimport { Sprite } from '@pixi/sprite';\nimport { settings } from '@pixi/settings';\nimport { Point } from '@pixi/math';\nimport { Ticker } from '@pixi/ticker';\nimport { Container, DisplayObject } from '@pixi/display';\n\n/**\r\n * A single node in a PropertyList.\r\n */\r\nclass PropertyNode {\r\n /**\r\n * @param value The value for this node\r\n * @param time The time for this node, between 0-1\r\n * @param [ease] Custom ease for this list. Only relevant for the first node.\r\n */\r\n constructor(value, time, ease) {\r\n this.value = value;\r\n this.time = time;\r\n this.next = null;\r\n this.isStepped = false;\r\n if (ease) {\r\n this.ease = typeof ease === 'function' ? ease : generateEase(ease);\r\n }\r\n else {\r\n this.ease = null;\r\n }\r\n }\r\n /**\r\n * Creates a list of property values from a data object {list, isStepped} with a list of objects in\r\n * the form {value, time}. Alternatively, the data object can be in the deprecated form of\r\n * {start, end}.\r\n * @param data The data for the list.\r\n * @param data.list The array of value and time objects.\r\n * @param data.isStepped If the list is stepped rather than interpolated.\r\n * @param data.ease Custom ease for this list.\r\n * @return The first node in the list\r\n */\r\n // eslint-disable-next-line max-len\r\n static createList(data) {\r\n if ('list' in data) {\r\n const array = data.list;\r\n let node;\r\n const { value, time } = array[0];\r\n // eslint-disable-next-line max-len\r\n const first = node = new PropertyNode(typeof value === 'string' ? hexToRGB(value) : value, time, data.ease);\r\n // only set up subsequent nodes if there are a bunch or the 2nd one is different from the first\r\n if (array.length > 2 || (array.length === 2 && array[1].value !== value)) {\r\n for (let i = 1; i < array.length; ++i) {\r\n const { value, time } = array[i];\r\n node.next = new PropertyNode(typeof value === 'string' ? hexToRGB(value) : value, time);\r\n node = node.next;\r\n }\r\n }\r\n first.isStepped = !!data.isStepped;\r\n return first;\r\n }\r\n // Handle deprecated version here\r\n const start = new PropertyNode(typeof data.start === 'string' ? hexToRGB(data.start) : data.start, 0);\r\n // only set up a next value if it is different from the starting value\r\n if (data.end !== data.start) {\r\n start.next = new PropertyNode(typeof data.end === 'string' ? hexToRGB(data.end) : data.end, 1);\r\n }\r\n return start;\r\n }\r\n}\n\n/**\r\n * The method used by behaviors to fetch textures. Defaults to Texture.from.\r\n */\r\n// get Texture.from(), only supports V5 and V6 with individual packages\r\n// eslint-disable-next-line prefer-const\r\nlet GetTextureFromString = Texture.from;\r\n/**\r\n * If errors and warnings should be logged within the library.\r\n */\r\nconst verbose = false;\r\nconst DEG_TO_RADS = Math.PI / 180;\r\n/**\r\n * Rotates a point by a given angle.\r\n * @param angle The angle to rotate by in radians\r\n * @param p The point to rotate around 0,0.\r\n */\r\nfunction rotatePoint(angle, p) {\r\n if (!angle)\r\n return;\r\n const s = Math.sin(angle);\r\n const c = Math.cos(angle);\r\n const xnew = (p.x * c) - (p.y * s);\r\n const ynew = (p.x * s) + (p.y * c);\r\n p.x = xnew;\r\n p.y = ynew;\r\n}\r\n/**\r\n * Combines separate color components (0-255) into a single uint color.\r\n * @param r The red value of the color\r\n * @param g The green value of the color\r\n * @param b The blue value of the color\r\n * @return The color in the form of 0xRRGGBB\r\n */\r\nfunction combineRGBComponents(r, g, b /* , a*/) {\r\n return /* a << 24 |*/ (r << 16) | (g << 8) | b;\r\n}\r\n/**\r\n * Returns the length (or magnitude) of this point.\r\n * @param point The point to measure length\r\n * @return The length of this point.\r\n */\r\nfunction length(point) {\r\n return Math.sqrt((point.x * point.x) + (point.y * point.y));\r\n}\r\n/**\r\n * Reduces the point to a length of 1.\r\n * @param point The point to normalize\r\n */\r\nfunction normalize(point) {\r\n const oneOverLen = 1 / length(point);\r\n point.x *= oneOverLen;\r\n point.y *= oneOverLen;\r\n}\r\n/**\r\n * Multiplies the x and y values of this point by a value.\r\n * @param point The point to scaleBy\r\n * @param value The value to scale by.\r\n */\r\nfunction scaleBy(point, value) {\r\n point.x *= value;\r\n point.y *= value;\r\n}\r\n/**\r\n * Converts a hex string from \"#AARRGGBB\", \"#RRGGBB\", \"0xAARRGGBB\", \"0xRRGGBB\",\r\n * \"AARRGGBB\", or \"RRGGBB\" to an object of ints of 0-255, as\r\n * {r, g, b, (a)}.\r\n * @param color The input color string.\r\n * @param output An object to put the output in. If omitted, a new object is created.\r\n * @return The object with r, g, and b properties, possibly with an a property.\r\n */\r\nfunction hexToRGB(color, output) {\r\n if (!output) {\r\n output = {};\r\n }\r\n if (color.charAt(0) === '#') {\r\n color = color.substr(1);\r\n }\r\n else if (color.indexOf('0x') === 0) {\r\n color = color.substr(2);\r\n }\r\n let alpha;\r\n if (color.length === 8) {\r\n alpha = color.substr(0, 2);\r\n color = color.substr(2);\r\n }\r\n output.r = parseInt(color.substr(0, 2), 16); // Red\r\n output.g = parseInt(color.substr(2, 2), 16); // Green\r\n output.b = parseInt(color.substr(4, 2), 16); // Blue\r\n if (alpha) {\r\n output.a = parseInt(alpha, 16);\r\n }\r\n return output;\r\n}\r\n/**\r\n * Generates a custom ease function, based on the GreenSock custom ease, as demonstrated\r\n * by the related tool at http://www.greensock.com/customease/.\r\n * @param segments An array of segments, as created by\r\n * http://www.greensock.com/customease/.\r\n * @return A function that calculates the percentage of change at\r\n * a given point in time (0-1 inclusive).\r\n */\r\nfunction generateEase(segments) {\r\n const qty = segments.length;\r\n const oneOverQty = 1 / qty;\r\n /*\r\n * Calculates the percentage of change at a given point in time (0-1 inclusive).\r\n * @param {Number} time The time of the ease, 0-1 inclusive.\r\n * @return {Number} The percentage of the change, 0-1 inclusive (unless your\r\n * ease goes outside those bounds).\r\n */\r\n // eslint-disable-next-line func-names\r\n return function (time) {\r\n const i = (qty * time) | 0; // do a quick floor operation\r\n const t = (time - (i * oneOverQty)) * qty;\r\n const s = segments[i] || segments[qty - 1];\r\n return (s.s + (t * ((2 * (1 - t) * (s.cp - s.s)) + (t * (s.e - s.s)))));\r\n };\r\n}\r\n/**\r\n * Gets a blend mode, ensuring that it is valid.\r\n * @param name The name of the blend mode to get.\r\n * @return The blend mode as specified in the PIXI.BLEND_MODES enumeration.\r\n */\r\nfunction getBlendMode(name) {\r\n if (!name)\r\n return BLEND_MODES.NORMAL;\r\n name = name.toUpperCase().replace(/ /g, '_');\r\n return BLEND_MODES[name] || BLEND_MODES.NORMAL;\r\n}\r\n/**\r\n * Converts a list of {value, time} objects starting at time 0 and ending at time 1 into an evenly\r\n * spaced stepped list of PropertyNodes for color values. This is primarily to handle conversion of\r\n * linear gradients to fewer colors, allowing for some optimization for Canvas2d fallbacks.\r\n * @param list The list of data to convert.\r\n * @param [numSteps=10] The number of steps to use.\r\n * @return The blend mode as specified in the PIXI.blendModes enumeration.\r\n */\r\nfunction createSteppedGradient(list, numSteps = 10) {\r\n if (typeof numSteps !== 'number' || numSteps <= 0) {\r\n numSteps = 10;\r\n }\r\n const first = new PropertyNode(hexToRGB(list[0].value), list[0].time);\r\n first.isStepped = true;\r\n let currentNode = first;\r\n let current = list[0];\r\n let nextIndex = 1;\r\n let next = list[nextIndex];\r\n for (let i = 1; i < numSteps; ++i) {\r\n let lerp = i / numSteps;\r\n // ensure we are on the right segment, if multiple\r\n while (lerp > next.time) {\r\n current = next;\r\n next = list[++nextIndex];\r\n }\r\n // convert the lerp value to the segment range\r\n lerp = (lerp - current.time) / (next.time - current.time);\r\n const curVal = hexToRGB(current.value);\r\n const nextVal = hexToRGB(next.value);\r\n const output = {\r\n r: ((nextVal.r - curVal.r) * lerp) + curVal.r,\r\n g: ((nextVal.g - curVal.g) * lerp) + curVal.g,\r\n b: ((nextVal.b - curVal.b) * lerp) + curVal.b,\r\n };\r\n currentNode.next = new PropertyNode(output, i / numSteps);\r\n currentNode = currentNode.next;\r\n }\r\n // we don't need to have a PropertyNode for time of 1, because in a stepped version at that point\r\n // the particle has died of old age\r\n return first;\r\n}\n\nvar ParticleUtils = {\n __proto__: null,\n GetTextureFromString: GetTextureFromString,\n verbose: verbose,\n DEG_TO_RADS: DEG_TO_RADS,\n rotatePoint: rotatePoint,\n combineRGBComponents: combineRGBComponents,\n length: length,\n normalize: normalize,\n scaleBy: scaleBy,\n hexToRGB: hexToRGB,\n generateEase: generateEase,\n getBlendMode: getBlendMode,\n createSteppedGradient: createSteppedGradient\n};\n\n/**\r\n * An individual particle image. You shouldn't have to deal with these.\r\n */\r\nclass Particle extends Sprite {\r\n /**\r\n * @param emitter The emitter that controls this particle.\r\n */\r\n constructor(emitter) {\r\n // start off the sprite with a blank texture, since we are going to replace it\r\n // later when the particle is initialized.\r\n super();\r\n // initialize LinkedListChild props so they are included in underlying JS class definition\r\n this.prevChild = this.nextChild = null;\r\n this.emitter = emitter;\r\n this.config = {};\r\n // particles should be centered\r\n this.anchor.x = this.anchor.y = 0.5;\r\n this.maxLife = 0;\r\n this.age = 0;\r\n this.agePercent = 0;\r\n this.oneOverLife = 0;\r\n this.next = null;\r\n this.prev = null;\r\n // save often used functions on the instance instead of the prototype for better speed\r\n this.init = this.init;\r\n this.kill = this.kill;\r\n }\r\n /**\r\n * Initializes the particle for use, based on the properties that have to\r\n * have been set already on the particle.\r\n */\r\n init(maxLife) {\r\n this.maxLife = maxLife;\r\n // reset the age\r\n this.age = this.agePercent = 0;\r\n // reset the sprite props\r\n this.rotation = 0;\r\n this.position.x = this.position.y = 0;\r\n this.scale.x = this.scale.y = 1;\r\n this.tint = 0xffffff;\r\n this.alpha = 1;\r\n // save our lerp helper\r\n this.oneOverLife = 1 / this.maxLife;\r\n // ensure visibility\r\n this.visible = true;\r\n }\r\n /**\r\n * Kills the particle, removing it from the display list\r\n * and telling the emitter to recycle it.\r\n */\r\n kill() {\r\n this.emitter.recycle(this);\r\n }\r\n /**\r\n * Destroys the particle, removing references and preventing future use.\r\n */\r\n destroy() {\r\n if (this.parent) {\r\n this.parent.removeChild(this);\r\n }\r\n this.emitter = this.next = this.prev = null;\r\n super.destroy();\r\n }\r\n}\n\n/**\r\n * Standard behavior order values, specifying when/how they are used. Other numeric values can be used,\r\n * but only the Spawn value will be handled in a special way. All other values will be sorted numerically.\r\n * Behaviors with the same value will not be given any specific sort order, as they are assumed to not\r\n * interfere with each other.\r\n */\r\nvar BehaviorOrder;\r\n(function (BehaviorOrder) {\r\n /**\r\n * Spawn - initial placement and/or rotation. This happens before rotation/translation due to\r\n * emitter rotation/position is applied.\r\n */\r\n BehaviorOrder[BehaviorOrder[\"Spawn\"] = 0] = \"Spawn\";\r\n /**\r\n * Normal priority, for things that don't matter when they are applied.\r\n */\r\n BehaviorOrder[BehaviorOrder[\"Normal\"] = 2] = \"Normal\";\r\n /**\r\n * Delayed priority, for things that need to read other values in order to act correctly.\r\n */\r\n BehaviorOrder[BehaviorOrder[\"Late\"] = 5] = \"Late\";\r\n})(BehaviorOrder || (BehaviorOrder = {}));\n\n// get the shared ticker, only supports V5 and V6 with individual packages\r\n/**\r\n * @hidden\r\n */\r\nconst ticker = Ticker.shared;\r\n/**\r\n * Key used in sorted order to determine when to set particle position from the emitter position\r\n * and rotation.\r\n */\r\nconst PositionParticle = Symbol('Position particle per emitter position');\r\n/**\r\n * A particle emitter.\r\n */\r\nclass Emitter {\r\n /**\r\n * @param particleParent The container to add the particles to.\r\n * @param particleImages A texture or array of textures to use\r\n * for the particles. Strings will be turned\r\n * into textures via Texture.from().\r\n * @param config A configuration object containing settings for the emitter.\r\n * @param config.emit If config.emit is explicitly passed as false, the\r\n * Emitter will start disabled.\r\n * @param config.autoUpdate If config.autoUpdate is explicitly passed as\r\n * true, the Emitter will automatically call\r\n * update via the PIXI shared ticker.\r\n */\r\n constructor(particleParent, config) {\r\n this.initBehaviors = [];\r\n this.updateBehaviors = [];\r\n this.recycleBehaviors = [];\r\n // properties for individual particles\r\n this.minLifetime = 0;\r\n this.maxLifetime = 0;\r\n this.customEase = null;\r\n // properties for spawning particles\r\n this._frequency = 1;\r\n this.spawnChance = 1;\r\n this.maxParticles = 1000;\r\n this.emitterLifetime = -1;\r\n this.spawnPos = new Point();\r\n this.particlesPerWave = 1;\r\n // emitter properties\r\n this.rotation = 0;\r\n this.ownerPos = new Point();\r\n this._prevEmitterPos = new Point();\r\n this._prevPosIsValid = false;\r\n this._posChanged = false;\r\n this._parent = null;\r\n this.addAtBack = false;\r\n this.particleCount = 0;\r\n this._emit = false;\r\n this._spawnTimer = 0;\r\n this._emitterLife = -1;\r\n this._activeParticlesFirst = null;\r\n this._activeParticlesLast = null;\r\n this._poolFirst = null;\r\n this._origConfig = null;\r\n this._autoUpdate = false;\r\n this._destroyWhenComplete = false;\r\n this._completeCallback = null;\r\n // set the initial parent\r\n this.parent = particleParent;\r\n if (config) {\r\n this.init(config);\r\n }\r\n // save often used functions on the instance instead of the prototype for better speed\r\n this.recycle = this.recycle;\r\n this.update = this.update;\r\n this.rotate = this.rotate;\r\n this.updateSpawnPos = this.updateSpawnPos;\r\n this.updateOwnerPos = this.updateOwnerPos;\r\n }\r\n /**\r\n * Registers a new behavior, so that it will be recognized when initializing emitters.\r\n * Behaviors registered later with duplicate types will override older ones, although there is no limit on\r\n * the allowed types.\r\n * @param constructor The behavior class to register.\r\n */\r\n static registerBehavior(constructor) {\r\n Emitter.knownBehaviors[constructor.type] = constructor;\r\n }\r\n /**\r\n * Time between particle spawns in seconds. If this value is not a number greater than 0,\r\n * it will be set to 1 (particle per second) to prevent infinite loops.\r\n */\r\n get frequency() { return this._frequency; }\r\n set frequency(value) {\r\n // do some error checking to prevent infinite loops\r\n if (typeof value === 'number' && value > 0) {\r\n this._frequency = value;\r\n }\r\n else {\r\n this._frequency = 1;\r\n }\r\n }\r\n /**\r\n * The container to add particles to. Settings this will dump any active particles.\r\n */\r\n get parent() { return this._parent; }\r\n set parent(value) {\r\n this.cleanup();\r\n this._parent = value;\r\n }\r\n /**\r\n * Sets up the emitter based on the config settings.\r\n * @param config A configuration object containing settings for the emitter.\r\n */\r\n init(config) {\r\n if (!config) {\r\n return;\r\n }\r\n // clean up any existing particles\r\n this.cleanup();\r\n // store the original config and particle images, in case we need to re-initialize\r\n // when the particle constructor is changed\r\n this._origConfig = config;\r\n // /////////////////////////\r\n // Particle Properties //\r\n // /////////////////////////\r\n // set up the lifetime\r\n this.minLifetime = config.lifetime.min;\r\n this.maxLifetime = config.lifetime.max;\r\n // use the custom ease if provided\r\n if (config.ease) {\r\n this.customEase = typeof config.ease === 'function'\r\n ? config.ease : generateEase(config.ease);\r\n }\r\n else {\r\n this.customEase = null;\r\n }\r\n // ////////////////////////\r\n // Emitter Properties //\r\n // ////////////////////////\r\n // reset spawn type specific settings\r\n this.particlesPerWave = 1;\r\n if (config.particlesPerWave && config.particlesPerWave > 1) {\r\n this.particlesPerWave = config.particlesPerWave;\r\n }\r\n // set the spawning frequency\r\n this.frequency = config.frequency;\r\n this.spawnChance = (typeof config.spawnChance === 'number' && config.spawnChance > 0) ? config.spawnChance : 1;\r\n // set the emitter lifetime\r\n this.emitterLifetime = config.emitterLifetime || -1;\r\n // set the max particles\r\n this.maxParticles = config.maxParticles > 0 ? config.maxParticles : 1000;\r\n // determine if we should add the particle at the back of the list or not\r\n this.addAtBack = !!config.addAtBack;\r\n // reset the emitter position and rotation variables\r\n this.rotation = 0;\r\n this.ownerPos.set(0);\r\n if (config.pos) {\r\n this.spawnPos.copyFrom(config.pos);\r\n }\r\n else {\r\n this.spawnPos.set(0);\r\n }\r\n this._prevEmitterPos.copyFrom(this.spawnPos);\r\n // previous emitter position is invalid and should not be used for interpolation\r\n this._prevPosIsValid = false;\r\n // start emitting\r\n this._spawnTimer = 0;\r\n this.emit = config.emit === undefined ? true : !!config.emit;\r\n this.autoUpdate = !!config.autoUpdate;\r\n // ////////////////////////\r\n // Behaviors //\r\n // ////////////////////////\r\n const behaviors = config.behaviors.map((data) => {\r\n const constructor = Emitter.knownBehaviors[data.type];\r\n if (!constructor) {\r\n console.error(`Unknown behavior: ${data.type}`);\r\n return null;\r\n }\r\n return new constructor(data.config);\r\n })\r\n .filter((b) => !!b);\r\n behaviors.push(PositionParticle);\r\n behaviors.sort((a, b) => {\r\n if (a === PositionParticle) {\r\n return b.order === BehaviorOrder.Spawn ? 1 : -1;\r\n }\r\n else if (b === PositionParticle) {\r\n return a.order === BehaviorOrder.Spawn ? -1 : 1;\r\n }\r\n return a.order - b.order;\r\n });\r\n this.initBehaviors = behaviors.slice();\r\n this.updateBehaviors = behaviors.filter((b) => b !== PositionParticle && b.updateParticle);\r\n this.recycleBehaviors = behaviors.filter((b) => b !== PositionParticle && b.recycleParticle);\r\n }\r\n /**\r\n * Gets the instantiated behavior of the specified type, if it is present on this emitter.\r\n * @param type The behavior type to find.\r\n */\r\n getBehavior(type) {\r\n // bail if we don't know about such an emitter\r\n if (!Emitter.knownBehaviors[type])\r\n return null;\r\n // find one that is an instance of the specified type\r\n return this.initBehaviors.find((b) => b instanceof Emitter.knownBehaviors[type]) || null;\r\n }\r\n /**\r\n * Fills the pool with the specified number of particles, so that they don't have to be instantiated later.\r\n * @param count The number of particles to create.\r\n */\r\n fillPool(count) {\r\n for (; count > 0; --count) {\r\n const p = new Particle(this);\r\n p.next = this._poolFirst;\r\n this._poolFirst = p;\r\n }\r\n }\r\n /**\r\n * Recycles an individual particle. For internal use only.\r\n * @param particle The particle to recycle.\r\n * @param fromCleanup If this is being called to manually clean up all particles.\r\n * @internal\r\n */\r\n recycle(particle, fromCleanup = false) {\r\n for (let i = 0; i < this.recycleBehaviors.length; ++i) {\r\n this.recycleBehaviors[i].recycleParticle(particle, !fromCleanup);\r\n }\r\n if (particle.next) {\r\n particle.next.prev = particle.prev;\r\n }\r\n if (particle.prev) {\r\n particle.prev.next = particle.next;\r\n }\r\n if (particle === this._activeParticlesLast) {\r\n this._activeParticlesLast = particle.prev;\r\n }\r\n if (particle === this._activeParticlesFirst) {\r\n this._activeParticlesFirst = particle.next;\r\n }\r\n // add to pool\r\n particle.prev = null;\r\n particle.next = this._poolFirst;\r\n this._poolFirst = particle;\r\n // remove child from display, or make it invisible if it is in a ParticleContainer\r\n if (particle.parent) {\r\n particle.parent.removeChild(particle);\r\n }\r\n // decrease count\r\n --this.particleCount;\r\n }\r\n /**\r\n * Sets the rotation of the emitter to a new value. This rotates the spawn position in addition\r\n * to particle direction.\r\n * @param newRot The new rotation, in degrees.\r\n */\r\n rotate(newRot) {\r\n if (this.rotation === newRot)\r\n return;\r\n // caclulate the difference in rotation for rotating spawnPos\r\n const diff = newRot - this.rotation;\r\n this.rotation = newRot;\r\n // rotate spawnPos\r\n rotatePoint(diff, this.spawnPos);\r\n // mark the position as having changed\r\n this._posChanged = true;\r\n }\r\n /**\r\n * Changes the spawn position of the emitter.\r\n * @param x The new x value of the spawn position for the emitter.\r\n * @param y The new y value of the spawn position for the emitter.\r\n */\r\n updateSpawnPos(x, y) {\r\n this._posChanged = true;\r\n this.spawnPos.x = x;\r\n this.spawnPos.y = y;\r\n }\r\n /**\r\n * Changes the position of the emitter's owner. You should call this if you are adding\r\n * particles to the world container that your emitter's owner is moving around in.\r\n * @param x The new x value of the emitter's owner.\r\n * @param y The new y value of the emitter's owner.\r\n */\r\n updateOwnerPos(x, y) {\r\n this._posChanged = true;\r\n this.ownerPos.x = x;\r\n this.ownerPos.y = y;\r\n }\r\n /**\r\n * Prevents emitter position interpolation in the next update.\r\n * This should be used if you made a major position change of your emitter's owner\r\n * that was not normal movement.\r\n */\r\n resetPositionTracking() {\r\n this._prevPosIsValid = false;\r\n }\r\n /**\r\n * If particles should be emitted during update() calls. Setting this to false\r\n * stops new particles from being created, but allows existing ones to die out.\r\n */\r\n get emit() { return this._emit; }\r\n set emit(value) {\r\n this._emit = !!value;\r\n this._emitterLife = this.emitterLifetime;\r\n }\r\n /**\r\n * If the update function is called automatically from the shared ticker.\r\n * Setting this to false requires calling the update function manually.\r\n */\r\n get autoUpdate() { return this._autoUpdate; }\r\n set autoUpdate(value) {\r\n if (this._autoUpdate && !value) {\r\n ticker.remove(this.update, this);\r\n }\r\n else if (!this._autoUpdate && value) {\r\n ticker.add(this.update, this);\r\n }\r\n this._autoUpdate = !!value;\r\n }\r\n /**\r\n * Starts emitting particles, sets autoUpdate to true, and sets up the Emitter to destroy itself\r\n * when particle emission is complete.\r\n * @param callback Callback for when emission is complete (all particles have died off)\r\n */\r\n playOnceAndDestroy(callback) {\r\n this.autoUpdate = true;\r\n this.emit = true;\r\n this._destroyWhenComplete = true;\r\n this._completeCallback = callback;\r\n }\r\n /**\r\n * Starts emitting particles and optionally calls a callback when particle emission is complete.\r\n * @param callback Callback for when emission is complete (all particles have died off)\r\n */\r\n playOnce(callback) {\r\n this.emit = true;\r\n this._completeCallback = callback;\r\n }\r\n /**\r\n * Updates all particles spawned by this emitter and emits new ones.\r\n * @param delta Time elapsed since the previous frame, in __seconds__.\r\n */\r\n update(delta) {\r\n if (this._autoUpdate) {\r\n delta = delta / settings.TARGET_FPMS / 1000;\r\n }\r\n // if we don't have a parent to add particles to, then don't do anything.\r\n // this also works as a isDestroyed check\r\n if (!this._parent)\r\n return;\r\n // == update existing particles ==\r\n // update all particle lifetimes before turning them over to behaviors\r\n for (let particle = this._activeParticlesFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // increase age\r\n particle.age += delta;\r\n // recycle particle if it is too old\r\n if (particle.age > particle.maxLife || particle.age < 0) {\r\n this.recycle(particle);\r\n }\r\n else {\r\n // determine our interpolation value\r\n let lerp = particle.age * particle.oneOverLife; // lifetime / maxLife;\r\n // global ease affects all interpolation calculations\r\n if (this.customEase) {\r\n if (this.customEase.length === 4) {\r\n // the t, b, c, d parameters that some tween libraries use\r\n // (time, initial value, end value, duration)\r\n lerp = this.customEase(lerp, 0, 1, 1);\r\n }\r\n else {\r\n // the simplified version that we like that takes\r\n // one parameter, time from 0-1. TweenJS eases provide this usage.\r\n lerp = this.customEase(lerp);\r\n }\r\n }\r\n // set age percent for all interpolation calculations\r\n particle.agePercent = lerp;\r\n // let each behavior run wild on the active particles\r\n for (let i = 0; i < this.updateBehaviors.length; ++i) {\r\n if (this.updateBehaviors[i].updateParticle(particle, delta)) {\r\n this.recycle(particle);\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n let prevX;\r\n let prevY;\r\n // if the previous position is valid, store these for later interpolation\r\n if (this._prevPosIsValid) {\r\n prevX = this._prevEmitterPos.x;\r\n prevY = this._prevEmitterPos.y;\r\n }\r\n // store current position of the emitter as local variables\r\n const curX = this.ownerPos.x + this.spawnPos.x;\r\n const curY = this.ownerPos.y + this.spawnPos.y;\r\n // spawn new particles\r\n if (this._emit) {\r\n // decrease spawn timer\r\n this._spawnTimer -= delta < 0 ? 0 : delta;\r\n // while _spawnTimer < 0, we have particles to spawn\r\n while (this._spawnTimer <= 0) {\r\n // determine if the emitter should stop spawning\r\n if (this._emitterLife >= 0) {\r\n this._emitterLife -= this._frequency;\r\n if (this._emitterLife <= 0) {\r\n this._spawnTimer = 0;\r\n this._emitterLife = 0;\r\n this.emit = false;\r\n break;\r\n }\r\n }\r\n // determine if we have hit the particle limit\r\n if (this.particleCount >= this.maxParticles) {\r\n this._spawnTimer += this._frequency;\r\n continue;\r\n }\r\n let emitPosX;\r\n let emitPosY;\r\n // If the position has changed and this isn't the first spawn,\r\n // interpolate the spawn position\r\n if (this._prevPosIsValid && this._posChanged) {\r\n // 1 - _spawnTimer / delta, but _spawnTimer is negative\r\n const lerp = 1 + (this._spawnTimer / delta);\r\n emitPosX = ((curX - prevX) * lerp) + prevX;\r\n emitPosY = ((curY - prevY) * lerp) + prevY;\r\n }\r\n // otherwise just set to the spawn position\r\n else {\r\n emitPosX = curX;\r\n emitPosY = curY;\r\n }\r\n let waveFirst = null;\r\n let waveLast = null;\r\n // create enough particles to fill the wave\r\n for (let len = Math.min(this.particlesPerWave, this.maxParticles - this.particleCount), i = 0; i < len; ++i) {\r\n // see if we actually spawn one\r\n if (this.spawnChance < 1 && Math.random() >= this.spawnChance) {\r\n continue;\r\n }\r\n // determine the particle lifetime\r\n let lifetime;\r\n if (this.minLifetime === this.maxLifetime) {\r\n lifetime = this.minLifetime;\r\n }\r\n else {\r\n lifetime = (Math.random() * (this.maxLifetime - this.minLifetime)) + this.minLifetime;\r\n }\r\n // only make the particle if it wouldn't immediately destroy itself\r\n if (-this._spawnTimer >= lifetime) {\r\n continue;\r\n }\r\n // create particle\r\n let p;\r\n if (this._poolFirst) {\r\n p = this._poolFirst;\r\n this._poolFirst = this._poolFirst.next;\r\n p.next = null;\r\n }\r\n else {\r\n p = new Particle(this);\r\n }\r\n // initialize particle\r\n p.init(lifetime);\r\n // add the particle to the display list\r\n if (this.addAtBack) {\r\n this._parent.addChildAt(p, 0);\r\n }\r\n else {\r\n this._parent.addChild(p);\r\n }\r\n // add particles to list of ones in this wave\r\n if (waveFirst) {\r\n waveLast.next = p;\r\n p.prev = waveLast;\r\n waveLast = p;\r\n }\r\n else {\r\n waveLast = waveFirst = p;\r\n }\r\n // increase our particle count\r\n ++this.particleCount;\r\n }\r\n if (waveFirst) {\r\n // add particle to list of active particles\r\n if (this._activeParticlesLast) {\r\n this._activeParticlesLast.next = waveFirst;\r\n waveFirst.prev = this._activeParticlesLast;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n else {\r\n this._activeParticlesFirst = waveFirst;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n // run behavior init on particles\r\n for (let i = 0; i < this.initBehaviors.length; ++i) {\r\n const behavior = this.initBehaviors[i];\r\n // if we hit our special key, interrupt behaviors to apply\r\n // emitter position/rotation\r\n if (behavior === PositionParticle) {\r\n for (let particle = waveFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // rotate the particle's position by the emitter's rotation\r\n if (this.rotation !== 0) {\r\n rotatePoint(this.rotation, particle.position);\r\n particle.rotation += this.rotation;\r\n }\r\n // offset by the emitter's position\r\n particle.position.x += emitPosX;\r\n particle.position.y += emitPosY;\r\n // also, just update the particle's age properties while we are looping through\r\n particle.age += -this._spawnTimer;\r\n // determine our interpolation value\r\n let lerp = particle.age * particle.oneOverLife; // lifetime / maxLife;\r\n // global ease affects all interpolation calculations\r\n if (this.customEase) {\r\n if (this.customEase.length === 4) {\r\n // the t, b, c, d parameters that some tween libraries use\r\n // (time, initial value, end value, duration)\r\n lerp = this.customEase(lerp, 0, 1, 1);\r\n }\r\n else {\r\n // the simplified version that we like that takes\r\n // one parameter, time from 0-1. TweenJS eases provide this usage.\r\n lerp = this.customEase(lerp);\r\n }\r\n }\r\n // set age percent for all interpolation calculations\r\n particle.agePercent = lerp;\r\n }\r\n }\r\n else {\r\n behavior.initParticles(waveFirst);\r\n }\r\n }\r\n for (let particle = waveFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // now update the particles by the time passed, so the particles are spread out properly\r\n for (let i = 0; i < this.updateBehaviors.length; ++i) {\r\n // we want a positive delta, because a negative delta messes things up\r\n if (this.updateBehaviors[i].updateParticle(particle, -this._spawnTimer)) {\r\n // bail if the particle got reycled\r\n this.recycle(particle);\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n // increase timer and continue on to any other particles that need to be created\r\n this._spawnTimer += this._frequency;\r\n }\r\n }\r\n // if the position changed before this update, then keep track of that\r\n if (this._posChanged) {\r\n this._prevEmitterPos.x = curX;\r\n this._prevEmitterPos.y = curY;\r\n this._prevPosIsValid = true;\r\n this._posChanged = false;\r\n }\r\n // if we are all done and should destroy ourselves, take care of that\r\n if (!this._emit && !this._activeParticlesFirst) {\r\n if (this._completeCallback) {\r\n const cb = this._completeCallback;\r\n this._completeCallback = null;\r\n cb();\r\n }\r\n if (this._destroyWhenComplete) {\r\n this.destroy();\r\n }\r\n }\r\n }\r\n /**\r\n * Emits a single wave of particles, using standard spawnChance & particlesPerWave settings. Does not affect\r\n * regular spawning through the frequency, and ignores the emit property. The max particle count is respected, however,\r\n * so if there are already too many particles then nothing will happen.\r\n */\r\n emitNow() {\r\n const emitPosX = this.ownerPos.x + this.spawnPos.x;\r\n const emitPosY = this.ownerPos.y + this.spawnPos.y;\r\n let waveFirst = null;\r\n let waveLast = null;\r\n // create enough particles to fill the wave\r\n for (let len = Math.min(this.particlesPerWave, this.maxParticles - this.particleCount), i = 0; i < len; ++i) {\r\n // see if we actually spawn one\r\n if (this.spawnChance < 1 && Math.random() >= this.spawnChance) {\r\n continue;\r\n }\r\n // create particle\r\n let p;\r\n if (this._poolFirst) {\r\n p = this._poolFirst;\r\n this._poolFirst = this._poolFirst.next;\r\n p.next = null;\r\n }\r\n else {\r\n p = new Particle(this);\r\n }\r\n let lifetime;\r\n if (this.minLifetime === this.maxLifetime) {\r\n lifetime = this.minLifetime;\r\n }\r\n else {\r\n lifetime = (Math.random() * (this.maxLifetime - this.minLifetime)) + this.minLifetime;\r\n }\r\n // initialize particle\r\n p.init(lifetime);\r\n // add the particle to the display list\r\n if (this.addAtBack) {\r\n this._parent.addChildAt(p, 0);\r\n }\r\n else {\r\n this._parent.addChild(p);\r\n }\r\n // add particles to list of ones in this wave\r\n if (waveFirst) {\r\n waveLast.next = p;\r\n p.prev = waveLast;\r\n waveLast = p;\r\n }\r\n else {\r\n waveLast = waveFirst = p;\r\n }\r\n // increase our particle count\r\n ++this.particleCount;\r\n }\r\n if (waveFirst) {\r\n // add particle to list of active particles\r\n if (this._activeParticlesLast) {\r\n this._activeParticlesLast.next = waveFirst;\r\n waveFirst.prev = this._activeParticlesLast;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n else {\r\n this._activeParticlesFirst = waveFirst;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n // run behavior init on particles\r\n for (let i = 0; i < this.initBehaviors.length; ++i) {\r\n const behavior = this.initBehaviors[i];\r\n // if we hit our special key, interrupt behaviors to apply\r\n // emitter position/rotation\r\n if (behavior === PositionParticle) {\r\n for (let particle = waveFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // rotate the particle's position by the emitter's rotation\r\n if (this.rotation !== 0) {\r\n rotatePoint(this.rotation, particle.position);\r\n particle.rotation += this.rotation;\r\n }\r\n // offset by the emitter's position\r\n particle.position.x += emitPosX;\r\n particle.position.y += emitPosY;\r\n }\r\n }\r\n else {\r\n behavior.initParticles(waveFirst);\r\n }\r\n }\r\n }\r\n }\r\n /**\r\n * Kills all active particles immediately.\r\n */\r\n cleanup() {\r\n let particle;\r\n let next;\r\n for (particle = this._activeParticlesFirst; particle; particle = next) {\r\n next = particle.next;\r\n this.recycle(particle, true);\r\n }\r\n this._activeParticlesFirst = this._activeParticlesLast = null;\r\n this.particleCount = 0;\r\n }\r\n /**\r\n * If this emitter has been destroyed. Note that a destroyed emitter can still be reused, after\r\n * having a new parent set and being reinitialized.\r\n */\r\n get destroyed() {\r\n return !(this._parent && this.initBehaviors.length);\r\n }\r\n /**\r\n * Destroys the emitter and all of its particles.\r\n */\r\n destroy() {\r\n // make sure we aren't still listening to any tickers\r\n this.autoUpdate = false;\r\n // puts all active particles in the pool, and removes them from the particle parent\r\n this.cleanup();\r\n // wipe the pool clean\r\n let next;\r\n for (let particle = this._poolFirst; particle; particle = next) {\r\n // store next value so we don't lose it in our destroy call\r\n next = particle.next;\r\n particle.destroy();\r\n }\r\n this._poolFirst = this._parent = this.spawnPos = this.ownerPos\r\n = this.customEase = this._completeCallback = null;\r\n this.initBehaviors.length = this.updateBehaviors.length = this.recycleBehaviors.length = 0;\r\n }\r\n}\r\nEmitter.knownBehaviors = {};\n\n/**\r\n * A SpawnShape that randomly picks locations inside a rectangle.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'rect',\r\n * data: {\r\n * x: 0,\r\n * y: 0,\r\n * w: 10,\r\n * h: 100\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass Rectangle {\r\n constructor(config) {\r\n this.x = config.x;\r\n this.y = config.y;\r\n this.w = config.w;\r\n this.h = config.h;\r\n }\r\n getRandPos(particle) {\r\n // place the particle at a random point in the rectangle\r\n particle.x = (Math.random() * this.w) + this.x;\r\n particle.y = (Math.random() * this.h) + this.y;\r\n }\r\n}\r\nRectangle.type = 'rect';\r\nRectangle.editorConfig = null;\n\n/**\r\n * A class for spawning particles in a circle or ring.\r\n * Can optionally apply rotation to particles so that they are aimed away from the center of the circle.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'torus',\r\n * data: {\r\n * radius: 30,\r\n * x: 0,\r\n * y: 0,\r\n * innerRadius: 10,\r\n * rotation: true\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass Torus {\r\n constructor(config) {\r\n this.x = config.x || 0;\r\n this.y = config.y || 0;\r\n this.radius = config.radius;\r\n this.innerRadius = config.innerRadius || 0;\r\n this.rotation = !!config.affectRotation;\r\n }\r\n getRandPos(particle) {\r\n // place the particle at a random radius in the ring\r\n if (this.innerRadius !== this.radius) {\r\n particle.x = (Math.random() * (this.radius - this.innerRadius)) + this.innerRadius;\r\n }\r\n else {\r\n particle.x = this.radius;\r\n }\r\n particle.y = 0;\r\n // rotate the point to a random angle in the circle\r\n const angle = Math.random() * Math.PI * 2;\r\n if (this.rotation) {\r\n particle.rotation += angle;\r\n }\r\n rotatePoint(angle, particle.position);\r\n // now add in the center of the torus\r\n particle.position.x += this.x;\r\n particle.position.y += this.y;\r\n }\r\n}\r\nTorus.type = 'torus';\r\nTorus.editorConfig = null;\n\n/**\r\n * A spawn shape that picks a random position along a series of line segments. If those\r\n * line segments form a polygon, particles will only be placed on the perimeter of that polygon.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'polygonalChain',\r\n * data: [\r\n * [{x: 0, y: 0}, {x: 10, y: 10}, {x: 20, y: 0}],\r\n * [{x: 0, y, -10}, {x: 10, y: 0}, {x: 20, y: -10}]\r\n * ]\r\n * }\r\n * ```\r\n */\r\nclass PolygonalChain {\r\n /**\r\n * @param data Point data for polygon chains. Either a list of points for a single chain, or a list of chains.\r\n */\r\n constructor(data) {\r\n this.segments = [];\r\n this.countingLengths = [];\r\n this.totalLength = 0;\r\n this.init(data);\r\n }\r\n /**\r\n * @param data Point data for polygon chains. Either a list of points for a single chain, or a list of chains.\r\n */\r\n init(data) {\r\n // if data is not present, set up a segment of length 0\r\n if (!data || !data.length) {\r\n this.segments.push({ p1: { x: 0, y: 0 }, p2: { x: 0, y: 0 }, l: 0 });\r\n }\r\n else if (Array.isArray(data[0])) {\r\n // list of segment chains, each defined as a list of points\r\n for (let i = 0; i < data.length; ++i) {\r\n // loop through the chain, connecting points\r\n const chain = data[i];\r\n let prevPoint = chain[0];\r\n for (let j = 1; j < chain.length; ++j) {\r\n const second = chain[j];\r\n this.segments.push({ p1: prevPoint, p2: second, l: 0 });\r\n prevPoint = second;\r\n }\r\n }\r\n }\r\n else {\r\n let prevPoint = data[0];\r\n // list of points\r\n for (let i = 1; i < data.length; ++i) {\r\n const second = data[i];\r\n this.segments.push({ p1: prevPoint, p2: second, l: 0 });\r\n prevPoint = second;\r\n }\r\n }\r\n // now go through our segments to calculate the lengths so that we\r\n // can set up a nice weighted random distribution\r\n for (let i = 0; i < this.segments.length; ++i) {\r\n const { p1, p2 } = this.segments[i];\r\n const segLength = Math.sqrt(((p2.x - p1.x) * (p2.x - p1.x)) + ((p2.y - p1.y) * (p2.y - p1.y)));\r\n // save length so we can turn a random number into a 0-1 interpolation value later\r\n this.segments[i].l = segLength;\r\n this.totalLength += segLength;\r\n // keep track of the length so far, counting up\r\n this.countingLengths.push(this.totalLength);\r\n }\r\n }\r\n /**\r\n * Gets a random point in the chain.\r\n * @param out The point to store the selected position in.\r\n */\r\n getRandPos(out) {\r\n // select a random spot in the length of the chain\r\n const rand = Math.random() * this.totalLength;\r\n let chosenSeg;\r\n let lerp;\r\n // if only one segment, it wins\r\n if (this.segments.length === 1) {\r\n chosenSeg = this.segments[0];\r\n lerp = rand;\r\n }\r\n else {\r\n // otherwise, go through countingLengths until we have determined\r\n // which segment we chose\r\n for (let i = 0; i < this.countingLengths.length; ++i) {\r\n if (rand < this.countingLengths[i]) {\r\n chosenSeg = this.segments[i];\r\n // set lerp equal to the length into that segment\r\n // (i.e. the remainder after subtracting all the segments before it)\r\n lerp = i === 0 ? rand : rand - this.countingLengths[i - 1];\r\n break;\r\n }\r\n }\r\n }\r\n // divide lerp by the segment length, to result in a 0-1 number.\r\n lerp /= chosenSeg.l || 1;\r\n const { p1, p2 } = chosenSeg;\r\n // now calculate the position in the segment that the lerp value represents\r\n out.x = p1.x + (lerp * (p2.x - p1.x));\r\n out.y = p1.y + (lerp * (p2.y - p1.y));\r\n }\r\n}\r\nPolygonalChain.type = 'polygonalChain';\r\nPolygonalChain.editorConfig = null;\n\nvar index = {\n __proto__: null,\n Rectangle: Rectangle,\n Torus: Torus,\n PolygonalChain: PolygonalChain\n};\n\nvar Types = {\n __proto__: null\n};\n\n/**\r\n * A Movement behavior that handles movement by applying a constant acceleration to all particles.\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"moveAcceleration\",\r\n * \"config\": {\r\n * \"accel\": {\r\n * \"x\": 0,\r\n * \"y\": 2000\r\n * },\r\n * \"minStart\": 600,\r\n * \"maxStart\": 600,\r\n * \"rotate\": true\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass AccelerationBehavior {\r\n constructor(config) {\r\n var _a;\r\n // doesn't _really_ need to be late, but doing so ensures that we can override any\r\n // rotation behavior that is mistakenly added\r\n this.order = BehaviorOrder.Late;\r\n this.minStart = config.minStart;\r\n this.maxStart = config.maxStart;\r\n this.accel = config.accel;\r\n this.rotate = !!config.rotate;\r\n this.maxSpeed = (_a = config.maxSpeed) !== null && _a !== void 0 ? _a : 0;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const speed = (Math.random() * (this.maxStart - this.minStart)) + this.minStart;\r\n if (!next.config.velocity) {\r\n next.config.velocity = new Point(speed, 0);\r\n }\r\n else {\r\n next.config.velocity.set(speed, 0);\r\n }\r\n rotatePoint(next.rotation, next.config.velocity);\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const vel = particle.config.velocity;\r\n const oldVX = vel.x;\r\n const oldVY = vel.y;\r\n vel.x += this.accel.x * deltaSec;\r\n vel.y += this.accel.y * deltaSec;\r\n if (this.maxSpeed) {\r\n const currentSpeed = length(vel);\r\n // if we are going faster than we should, clamp at the max speed\r\n // DO NOT recalculate vector length\r\n if (currentSpeed > this.maxSpeed) {\r\n scaleBy(vel, this.maxSpeed / currentSpeed);\r\n }\r\n }\r\n // calculate position delta by the midpoint between our old velocity and our new velocity\r\n particle.x += (oldVX + vel.x) / 2 * deltaSec;\r\n particle.y += (oldVY + vel.y) / 2 * deltaSec;\r\n if (this.rotate) {\r\n particle.rotation = Math.atan2(vel.y, vel.x);\r\n }\r\n }\r\n}\r\nAccelerationBehavior.type = 'moveAcceleration';\r\nAccelerationBehavior.editorConfig = null;\n\nfunction intValueSimple(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n return ((this.first.next.value - this.first.value) * lerp) + this.first.value;\r\n}\r\nfunction intColorSimple(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n const curVal = this.first.value;\r\n const nextVal = this.first.next.value;\r\n const r = ((nextVal.r - curVal.r) * lerp) + curVal.r;\r\n const g = ((nextVal.g - curVal.g) * lerp) + curVal.g;\r\n const b = ((nextVal.b - curVal.b) * lerp) + curVal.b;\r\n return combineRGBComponents(r, g, b);\r\n}\r\nfunction intValueComplex(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n let next = current.next;\r\n while (lerp > next.time) {\r\n current = next;\r\n next = next.next;\r\n }\r\n // convert the lerp value to the segment range\r\n lerp = (lerp - current.time) / (next.time - current.time);\r\n return ((next.value - current.value) * lerp) + current.value;\r\n}\r\nfunction intColorComplex(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n let next = current.next;\r\n while (lerp > next.time) {\r\n current = next;\r\n next = next.next;\r\n }\r\n // convert the lerp value to the segment range\r\n lerp = (lerp - current.time) / (next.time - current.time);\r\n const curVal = current.value;\r\n const nextVal = next.value;\r\n const r = ((nextVal.r - curVal.r) * lerp) + curVal.r;\r\n const g = ((nextVal.g - curVal.g) * lerp) + curVal.g;\r\n const b = ((nextVal.b - curVal.b) * lerp) + curVal.b;\r\n return combineRGBComponents(r, g, b);\r\n}\r\nfunction intValueStepped(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n while (current.next && lerp > current.next.time) {\r\n current = current.next;\r\n }\r\n return current.value;\r\n}\r\nfunction intColorStepped(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n while (current.next && lerp > current.next.time) {\r\n current = current.next;\r\n }\r\n const curVal = current.value;\r\n return combineRGBComponents(curVal.r, curVal.g, curVal.b);\r\n}\r\n/**\r\n * Singly linked list container for keeping track of interpolated properties for particles.\r\n * Each Particle will have one of these for each interpolated property.\r\n */\r\nclass PropertyList {\r\n /**\r\n * @param isColor If this list handles color values\r\n */\r\n constructor(isColor = false) {\r\n this.first = null;\r\n this.isColor = !!isColor;\r\n this.interpolate = null;\r\n this.ease = null;\r\n }\r\n /**\r\n * Resets the list for use.\r\n * @param first The first node in the list.\r\n * @param first.isStepped If the values should be stepped instead of interpolated linearly.\r\n */\r\n reset(first) {\r\n this.first = first;\r\n const isSimple = first.next && first.next.time >= 1;\r\n if (isSimple) {\r\n this.interpolate = this.isColor ? intColorSimple : intValueSimple;\r\n }\r\n else if (first.isStepped) {\r\n this.interpolate = this.isColor ? intColorStepped : intValueStepped;\r\n }\r\n else {\r\n this.interpolate = this.isColor ? intColorComplex : intValueComplex;\r\n }\r\n this.ease = this.first.ease;\r\n }\r\n}\n\n/**\r\n * An Alpha behavior that applies an interpolated or stepped list of values to the particle's opacity.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'alpha',\r\n * config: {\r\n * alpha: {\r\n * list: [{value: 0, time: 0}, {value: 1, time: 0.25}, {value: 0, time: 1}]\r\n * },\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass AlphaBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.alpha));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.alpha = this.list.first.value;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle) {\r\n particle.alpha = this.list.interpolate(particle.agePercent);\r\n }\r\n}\r\nAlphaBehavior.type = 'alpha';\r\nAlphaBehavior.editorConfig = null;\r\n/**\r\n * An Alpha behavior that applies a static value to the particle's opacity at particle initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'alphaStatic',\r\n * config: {\r\n * alpha: 0.75,\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticAlphaBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.value = config.alpha;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.alpha = this.value;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticAlphaBehavior.type = 'alphaStatic';\r\nStaticAlphaBehavior.editorConfig = null;\n\nfunction getTextures(textures) {\r\n const outTextures = [];\r\n for (let j = 0; j < textures.length; ++j) {\r\n let tex = textures[j];\r\n if (typeof tex === 'string') {\r\n outTextures.push(GetTextureFromString(tex));\r\n }\r\n else if (tex instanceof Texture) {\r\n outTextures.push(tex);\r\n }\r\n // assume an object with extra data determining duplicate frame data\r\n else {\r\n let dupe = tex.count || 1;\r\n if (typeof tex.texture === 'string') {\r\n tex = GetTextureFromString(tex.texture);\r\n }\r\n else // if(tex.texture instanceof Texture)\r\n {\r\n tex = tex.texture;\r\n }\r\n for (; dupe > 0; --dupe) {\r\n outTextures.push(tex);\r\n }\r\n }\r\n }\r\n return outTextures;\r\n}\r\n/**\r\n * A Texture behavior that picks a random animation for each particle to play.\r\n * See {@link AnimatedParticleArt} for detailed configuration info.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'animatedRandom',\r\n * config: {\r\n * anims: [\r\n * {\r\n * framerate: 25,\r\n * loop: true,\r\n * textures: ['frame1', 'frame2', 'frame3']\r\n * },\r\n * {\r\n * framerate: 25,\r\n * loop: true,\r\n * textures: ['frame3', 'frame2', 'frame1']\r\n * }\r\n * ],\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass RandomAnimatedTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.anims = [];\r\n for (let i = 0; i < config.anims.length; ++i) {\r\n const anim = config.anims[i];\r\n const textures = getTextures(anim.textures);\r\n // eslint-disable-next-line no-nested-ternary\r\n const framerate = anim.framerate < 0 ? -1 : (anim.framerate > 0 ? anim.framerate : 60);\r\n const parsedAnim = {\r\n textures,\r\n duration: framerate > 0 ? textures.length / framerate : 0,\r\n framerate,\r\n loop: framerate > 0 ? !!anim.loop : false,\r\n };\r\n this.anims.push(parsedAnim);\r\n }\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const index = Math.floor(Math.random() * this.anims.length);\r\n const anim = next.config.anim = this.anims[index];\r\n next.texture = anim.textures[0];\r\n next.config.animElapsed = 0;\r\n // if anim should match particle life exactly\r\n if (anim.framerate === -1) {\r\n next.config.animDuration = next.maxLife;\r\n next.config.animFramerate = anim.textures.length / next.maxLife;\r\n }\r\n else {\r\n next.config.animDuration = anim.duration;\r\n next.config.animFramerate = anim.framerate;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const config = particle.config;\r\n const anim = config.anim;\r\n config.animElapsed += deltaSec;\r\n if (config.animElapsed >= config.animDuration) {\r\n // loop elapsed back around\r\n if (config.anim.loop) {\r\n config.animElapsed = config.animElapsed % config.animDuration;\r\n }\r\n // subtract a small amount to prevent attempting to go past the end of the animation\r\n else {\r\n config.animElapsed = config.animDuration - 0.000001;\r\n }\r\n }\r\n // add a very small number to the frame and then floor it to avoid\r\n // the frame being one short due to floating point errors.\r\n const frame = ((config.animElapsed * config.animFramerate) + 0.0000001) | 0;\r\n // in the very rare case that framerate * elapsed math ends up going past the end, use the last texture\r\n particle.texture = anim.textures[frame] || anim.textures[anim.textures.length - 1] || Texture.EMPTY;\r\n }\r\n}\r\nRandomAnimatedTextureBehavior.type = 'animatedRandom';\r\nRandomAnimatedTextureBehavior.editorConfig = null;\r\n/**\r\n * A Texture behavior that uses a single animation for each particle to play.\r\n * See {@link AnimatedParticleArt} for detailed configuration info.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'animatedSingle',\r\n * config: {\r\n * anim: {\r\n * framerate: 25,\r\n * loop: true,\r\n * textures: ['frame1', 'frame2', 'frame3']\r\n * }\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass SingleAnimatedTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n const anim = config.anim;\r\n const textures = getTextures(anim.textures);\r\n // eslint-disable-next-line no-nested-ternary\r\n const framerate = anim.framerate < 0 ? -1 : (anim.framerate > 0 ? anim.framerate : 60);\r\n this.anim = {\r\n textures,\r\n duration: framerate > 0 ? textures.length / framerate : 0,\r\n framerate,\r\n loop: framerate > 0 ? !!anim.loop : false,\r\n };\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n const anim = this.anim;\r\n while (next) {\r\n next.texture = anim.textures[0];\r\n next.config.animElapsed = 0;\r\n // if anim should match particle life exactly\r\n if (anim.framerate === -1) {\r\n next.config.animDuration = next.maxLife;\r\n next.config.animFramerate = anim.textures.length / next.maxLife;\r\n }\r\n else {\r\n next.config.animDuration = anim.duration;\r\n next.config.animFramerate = anim.framerate;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const anim = this.anim;\r\n const config = particle.config;\r\n config.animElapsed += deltaSec;\r\n if (config.animElapsed >= config.animDuration) {\r\n // loop elapsed back around\r\n if (anim.loop) {\r\n config.animElapsed = config.animElapsed % config.animDuration;\r\n }\r\n // subtract a small amount to prevent attempting to go past the end of the animation\r\n else {\r\n config.animElapsed = config.animDuration - 0.000001;\r\n }\r\n }\r\n // add a very small number to the frame and then floor it to avoid\r\n // the frame being one short due to floating point errors.\r\n const frame = ((config.animElapsed * config.animFramerate) + 0.0000001) | 0;\r\n // in the very rare case that framerate * elapsed math ends up going past the end, use the last texture\r\n particle.texture = anim.textures[frame] || anim.textures[anim.textures.length - 1] || Texture.EMPTY;\r\n }\r\n}\r\nSingleAnimatedTextureBehavior.type = 'animatedSingle';\r\nSingleAnimatedTextureBehavior.editorConfig = null;\n\n/**\r\n * A Blend Mode behavior that applies a blend mode value to the particle at initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'blendMode',\r\n * config: {\r\n * blendMode: 'multiply',\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass BlendModeBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.value = config.blendMode;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.blendMode = getBlendMode(this.value);\r\n next = next.next;\r\n }\r\n }\r\n}\r\nBlendModeBehavior.type = 'blendMode';\r\nBlendModeBehavior.editorConfig = null;\n\n/**\r\n * A Spawn behavior that sends particles out from a single point or ring, and is capable of evenly spacing\r\n * the particle's starting angles.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'spawnBurst',\r\n * config: {\r\n * spacing: 90,\r\n * start: 0,\r\n * distance: 40,\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass BurstSpawnBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Spawn;\r\n this.spacing = config.spacing * DEG_TO_RADS;\r\n this.start = config.start * DEG_TO_RADS;\r\n this.distance = config.distance;\r\n }\r\n initParticles(first) {\r\n let count = 0;\r\n let next = first;\r\n while (next) {\r\n let angle;\r\n if (this.spacing) {\r\n angle = this.start + (this.spacing * count);\r\n }\r\n else {\r\n angle = Math.random() * Math.PI * 2;\r\n }\r\n next.rotation = angle;\r\n if (this.distance) {\r\n next.position.x = this.distance;\r\n rotatePoint(angle, next.position);\r\n }\r\n next = next.next;\r\n ++count;\r\n }\r\n }\r\n}\r\nBurstSpawnBehavior.type = 'spawnBurst';\r\nBurstSpawnBehavior.editorConfig = null;\n\n/**\r\n * A Color behavior that applies an interpolated or stepped list of values to the particle's tint property.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'color',\r\n * config: {\r\n * color: {\r\n * list: [{value: '#ff0000' time: 0}, {value: '#00ff00', time: 0.5}, {value: '#0000ff', time: 1}]\r\n * },\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass ColorBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.list = new PropertyList(true);\r\n this.list.reset(PropertyNode.createList(config.color));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n const color = this.list.first.value;\r\n const tint = combineRGBComponents(color.r, color.g, color.b);\r\n while (next) {\r\n next.tint = tint;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle) {\r\n particle.tint = this.list.interpolate(particle.agePercent);\r\n }\r\n}\r\nColorBehavior.type = 'color';\r\nColorBehavior.editorConfig = null;\r\n/**\r\n * A Color behavior that applies a single color to the particle's tint property at initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'colorStatic',\r\n * config: {\r\n * color: '#ffff00',\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticColorBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n let color = config.color;\r\n if (color.charAt(0) === '#') {\r\n color = color.substr(1);\r\n }\r\n else if (color.indexOf('0x') === 0) {\r\n color = color.substr(2);\r\n }\r\n this.value = parseInt(color, 16);\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.tint = this.value;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticColorBehavior.type = 'colorStatic';\r\nStaticColorBehavior.editorConfig = null;\n\n/**\r\n * A Texture behavior that assigns a texture to each particle from its list, in order, before looping around to the first\r\n * texture again. String values will be converted to textures with {@link ParticleUtils.GetTextureFromString}.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'textureOrdered',\r\n * config: {\r\n * textures: [\"myTex1Id\", \"myTex2Id\", \"myTex3Id\", \"myTex4Id\"],\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass OrderedTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.index = 0;\r\n this.textures = config.textures.map((tex) => (typeof tex === 'string' ? GetTextureFromString(tex) : tex));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.texture = this.textures[this.index];\r\n if (++this.index >= this.textures.length) {\r\n this.index = 0;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n}\r\nOrderedTextureBehavior.type = 'textureOrdered';\r\nOrderedTextureBehavior.editorConfig = null;\n\n/**\r\n * A helper point for math things.\r\n * @hidden\r\n */\r\nconst helperPoint = new Point();\r\n/**\r\n * A hand picked list of Math functions (and a couple properties) that are\r\n * allowable. They should be used without the preceding \"Math.\"\r\n * @hidden\r\n */\r\nconst MATH_FUNCS = [\r\n 'E',\r\n 'LN2',\r\n 'LN10',\r\n 'LOG2E',\r\n 'LOG10E',\r\n 'PI',\r\n 'SQRT1_2',\r\n 'SQRT2',\r\n 'abs',\r\n 'acos',\r\n 'acosh',\r\n 'asin',\r\n 'asinh',\r\n 'atan',\r\n 'atanh',\r\n 'atan2',\r\n 'cbrt',\r\n 'ceil',\r\n 'cos',\r\n 'cosh',\r\n 'exp',\r\n 'expm1',\r\n 'floor',\r\n 'fround',\r\n 'hypot',\r\n 'log',\r\n 'log1p',\r\n 'log10',\r\n 'log2',\r\n 'max',\r\n 'min',\r\n 'pow',\r\n 'random',\r\n 'round',\r\n 'sign',\r\n 'sin',\r\n 'sinh',\r\n 'sqrt',\r\n 'tan',\r\n 'tanh',\r\n];\r\n/**\r\n * create an actual regular expression object from the string\r\n * @hidden\r\n */\r\nconst WHITELISTER = new RegExp([\r\n // Allow the 4 basic operations, parentheses and all numbers/decimals, as well\r\n // as 'x', for the variable usage.\r\n '[01234567890\\\\.\\\\*\\\\-\\\\+\\\\/\\\\(\\\\)x ,]',\r\n].concat(MATH_FUNCS).join('|'), 'g');\r\n/**\r\n * Parses a string into a function for path following.\r\n * This involves whitelisting the string for safety, inserting \"Math.\" to math function\r\n * names, and using `new Function()` to generate a function.\r\n * @hidden\r\n * @param pathString The string to parse.\r\n * @return The path function - takes x, outputs y.\r\n */\r\nfunction parsePath(pathString) {\r\n const matches = pathString.match(WHITELISTER);\r\n for (let i = matches.length - 1; i >= 0; --i) {\r\n if (MATH_FUNCS.indexOf(matches[i]) >= 0) {\r\n matches[i] = `Math.${matches[i]}`;\r\n }\r\n }\r\n pathString = matches.join('');\r\n // eslint-disable-next-line no-new-func\r\n return new Function('x', `return ${pathString};`);\r\n}\r\n/**\r\n * A particle that follows a path defined by an algebraic expression, e.g. \"sin(x)\" or\r\n * \"5x + 3\".\r\n * To use this class, the behavior config must have a \"path\" string or function.\r\n *\r\n * A string should have \"x\" in it to represent movement (from the\r\n * speed settings of the behavior). It may have numbers, parentheses, the four basic\r\n * operations, and any Math functions or properties (without the preceding \"Math.\").\r\n * The overall movement of the particle and the expression value become x and y positions for\r\n * the particle, respectively. The final position is rotated by the spawn rotation/angle of\r\n * the particle.\r\n *\r\n * A function merely needs to accept the \"x\" argument and output the a corresponding \"y\" value.\r\n *\r\n * Some example paths:\r\n *\r\n * * `\"sin(x/10) * 20\"` A sine wave path.\r\n * * `\"cos(x/100) * 30\"` Particles curve counterclockwise (for medium speed/low lifetime particles)\r\n * * `\"pow(x/10, 2) / 2\"` Particles curve clockwise (remember, +y is down).\r\n * * `(x) => Math.floor(x) * 3` Supplying an existing function should look like this\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"movePath\",\r\n * \"config\": {\r\n * \"path\": \"round(sin(x) * 2\",\r\n * \"speed\": {\r\n * \"list\": [{value: 10, time: 0}, {value: 100, time: 0.25}, {value: 0, time: 1}],\r\n * },\r\n * \"minMult\": 0.8\r\n * }\r\n *}\r\n */\r\nclass PathBehavior {\r\n constructor(config) {\r\n var _a;\r\n // *MUST* happen after other behaviors do initialization so that we can read initial transformations\r\n this.order = BehaviorOrder.Late;\r\n if (config.path) {\r\n if (typeof config.path === 'function') {\r\n this.path = config.path;\r\n }\r\n else {\r\n try {\r\n this.path = parsePath(config.path);\r\n }\r\n catch (e) {\r\n this.path = null;\r\n }\r\n }\r\n }\r\n else {\r\n // eslint-disable-next-line @typescript-eslint/explicit-function-return-type\r\n this.path = (x) => x;\r\n }\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.speed));\r\n this.minMult = (_a = config.minMult) !== null && _a !== void 0 ? _a : 1;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n /*\r\n * The initial rotation in degrees of the particle, because the direction of the path\r\n * is based on that.\r\n */\r\n next.config.initRotation = next.rotation;\r\n /* The initial position of the particle, as all path movement is added to that. */\r\n if (!next.config.initPosition) {\r\n next.config.initPosition = new Point(next.x, next.y);\r\n }\r\n else {\r\n next.config.initPosition.copyFrom(next.position);\r\n }\r\n /* Total single directional movement, due to speed. */\r\n next.config.movement = 0;\r\n // also do speed multiplier, since this includes basic speed movement\r\n const mult = (Math.random() * (1 - this.minMult)) + this.minMult;\r\n next.config.speedMult = mult;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n // increase linear movement based on speed\r\n const speed = this.list.interpolate(particle.agePercent) * particle.config.speedMult;\r\n particle.config.movement += speed * deltaSec;\r\n // set up the helper point for rotation\r\n helperPoint.x = particle.config.movement;\r\n helperPoint.y = this.path(helperPoint.x);\r\n rotatePoint(particle.config.initRotation, helperPoint);\r\n particle.position.x = particle.config.initPosition.x + helperPoint.x;\r\n particle.position.y = particle.config.initPosition.y + helperPoint.y;\r\n }\r\n}\r\nPathBehavior.type = 'movePath';\r\nPathBehavior.editorConfig = null;\n\n/**\r\n * A Spawn behavior that sends particles out from a single point at the emitter's position.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'spawnPoint',\r\n * config: {}\r\n * }\r\n * ```\r\n */\r\nclass PointSpawnBehavior {\r\n constructor() {\r\n this.order = BehaviorOrder.Spawn;\r\n }\r\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\r\n initParticles(_first) {\r\n // really just a no-op\r\n }\r\n}\r\nPointSpawnBehavior.type = 'spawnPoint';\r\nPointSpawnBehavior.editorConfig = null;\n\n/**\r\n * A Texture behavior that assigns a random texture to each particle from its list.\r\n * String values will be converted to textures with {@link ParticleUtils.GetTextureFromString}.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'textureRandom',\r\n * config: {\r\n * textures: [\"myTex1Id\", \"myTex2Id\", \"myTex3Id\", \"myTex4Id\"],\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass RandomTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.textures = config.textures.map((tex) => (typeof tex === 'string' ? GetTextureFromString(tex) : tex));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const index = Math.floor(Math.random() * this.textures.length);\r\n next.texture = this.textures[index];\r\n next = next.next;\r\n }\r\n }\r\n}\r\nRandomTextureBehavior.type = 'textureRandom';\r\nRandomTextureBehavior.editorConfig = null;\n\n/**\r\n * A Rotation behavior that handles starting rotation, rotation speed, and rotational acceleration.\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"rotation\",\r\n * \"config\": {\r\n * \"minStart\": 0,\r\n * \"maxStart\": 180,\r\n * \"minSpeed\": 30,\r\n * \"maxSpeed\": 45,\r\n * \"accel\": 20\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass RotationBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.minStart = config.minStart * DEG_TO_RADS;\r\n this.maxStart = config.maxStart * DEG_TO_RADS;\r\n this.minSpeed = config.minSpeed * DEG_TO_RADS;\r\n this.maxSpeed = config.maxSpeed * DEG_TO_RADS;\r\n this.accel = config.accel * DEG_TO_RADS;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n if (this.minStart === this.maxStart) {\r\n next.rotation += this.maxStart;\r\n }\r\n else {\r\n next.rotation += (Math.random() * (this.maxStart - this.minStart)) + this.minStart;\r\n }\r\n next.config.rotSpeed = (Math.random() * (this.maxSpeed - this.minSpeed)) + this.minSpeed;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n if (this.accel) {\r\n const oldSpeed = particle.config.rotSpeed;\r\n particle.config.rotSpeed += this.accel * deltaSec;\r\n particle.rotation += (particle.config.rotSpeed + oldSpeed) / 2 * deltaSec;\r\n }\r\n else {\r\n particle.rotation += particle.config.rotSpeed * deltaSec;\r\n }\r\n }\r\n}\r\nRotationBehavior.type = 'rotation';\r\nRotationBehavior.editorConfig = null;\r\n/**\r\n * A Rotation behavior that handles starting rotation.\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"rotationStatic\",\r\n * \"config\": {\r\n * \"min\": 0,\r\n * \"max\": 180,\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass StaticRotationBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.min = config.min * DEG_TO_RADS;\r\n this.max = config.max * DEG_TO_RADS;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n if (this.min === this.max) {\r\n next.rotation += this.max;\r\n }\r\n else {\r\n next.rotation += (Math.random() * (this.max - this.min)) + this.min;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticRotationBehavior.type = 'rotationStatic';\r\nStaticRotationBehavior.editorConfig = null;\r\n/**\r\n * A Rotation behavior that blocks all rotation caused by spawn settings,\r\n * by resetting it to the specified rotation (or 0).\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"noRotation\",\r\n * \"config\": {\r\n * \"rotation\": 0\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass NoRotationBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Late + 1;\r\n this.rotation = (config.rotation || 0) * DEG_TO_RADS;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.rotation = this.rotation;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nNoRotationBehavior.type = 'noRotation';\r\nNoRotationBehavior.editorConfig = null;\n\n/**\r\n * A Scale behavior that applies an interpolated or stepped list of values to the particle's x & y scale.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'scale',\r\n * config: {\r\n * scale: {\r\n * list: [{value: 0, time: 0}, {value: 1, time: 0.25}, {value: 0, time: 1}],\r\n * isStepped: true\r\n * },\r\n * minMult: 0.5\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass ScaleBehavior {\r\n constructor(config) {\r\n var _a;\r\n this.order = BehaviorOrder.Normal;\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.scale));\r\n this.minMult = (_a = config.minMult) !== null && _a !== void 0 ? _a : 1;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const mult = (Math.random() * (1 - this.minMult)) + this.minMult;\r\n next.config.scaleMult = mult;\r\n next.scale.x = next.scale.y = this.list.first.value * mult;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle) {\r\n particle.scale.x = particle.scale.y = this.list.interpolate(particle.agePercent) * particle.config.scaleMult;\r\n }\r\n}\r\nScaleBehavior.type = 'scale';\r\nScaleBehavior.editorConfig = null;\r\n/**\r\n * A Scale behavior that applies a randomly picked value to the particle's x & y scale at initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'scaleStatic',\r\n * config: {\r\n * min: 0.25,\r\n * max: 0.75,\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticScaleBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.min = config.min;\r\n this.max = config.max;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const scale = (Math.random() * (this.max - this.min)) + this.min;\r\n next.scale.x = next.scale.y = scale;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticScaleBehavior.type = 'scaleStatic';\r\nStaticScaleBehavior.editorConfig = null;\n\n/**\r\n * A Spawn behavior that places (and optionally rotates) particles according to a\r\n * specified shape. Additional shapes can be registered with {@link registerShape | SpawnShape.registerShape()}.\r\n * Additional shapes must implement the {@link SpawnShape} interface, and their class must match the\r\n * {@link SpawnShapeClass} interface.\r\n * Shapes included by default are:\r\n * * {@link Rectangle}\r\n * * {@link Torus}\r\n * * {@link PolygonalChain}\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'spawnShape',\r\n * config: {\r\n * type: 'rect',\r\n * data: {\r\n * x: 0,\r\n * y: 0,\r\n * width: 20,\r\n * height: 300,\r\n * }\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass ShapeSpawnBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Spawn;\r\n const ShapeClass = ShapeSpawnBehavior.shapes[config.type];\r\n if (!ShapeClass) {\r\n throw new Error(`No shape found with type '${config.type}'`);\r\n }\r\n this.shape = new ShapeClass(config.data);\r\n }\r\n /**\r\n * Registers a shape to be used by the ShapeSpawn behavior.\r\n * @param constructor The shape class constructor to use, with a static `type` property to reference it by.\r\n * @param typeOverride An optional type override, primarily for registering a shape under multiple names.\r\n */\r\n static registerShape(constructor, typeOverride) {\r\n ShapeSpawnBehavior.shapes[typeOverride || constructor.type] = constructor;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n this.shape.getRandPos(next);\r\n next = next.next;\r\n }\r\n }\r\n}\r\nShapeSpawnBehavior.type = 'spawnShape';\r\nShapeSpawnBehavior.editorConfig = null;\r\n/**\r\n * Dictionary of all registered shape classes.\r\n */\r\nShapeSpawnBehavior.shapes = {};\r\nShapeSpawnBehavior.registerShape(PolygonalChain);\r\nShapeSpawnBehavior.registerShape(Rectangle);\r\nShapeSpawnBehavior.registerShape(Torus);\r\nShapeSpawnBehavior.registerShape(Torus, 'circle');\n\n/**\r\n * A Textuure behavior that assigns a single texture to each particle.\r\n * String values will be converted to textures with {@link ParticleUtils.GetTextureFromString}.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'textureSingle',\r\n * config: {\r\n * texture: Texture.from('myTexId'),\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass SingleTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.texture = typeof config.texture === 'string' ? GetTextureFromString(config.texture) : config.texture;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.texture = this.texture;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nSingleTextureBehavior.type = 'textureSingle';\r\nSingleTextureBehavior.editorConfig = null;\n\n/**\r\n * A Movement behavior that uses an interpolated or stepped list of values for a particles speed at any given moment.\r\n * Movement direction is controlled by the particle's starting rotation.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'moveSpeed',\r\n * config: {\r\n * speed: {\r\n * list: [{value: 10, time: 0}, {value: 100, time: 0.25}, {value: 0, time: 1}],\r\n * },\r\n * minMult: 0.8\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass SpeedBehavior {\r\n constructor(config) {\r\n var _a;\r\n this.order = BehaviorOrder.Late;\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.speed));\r\n this.minMult = (_a = config.minMult) !== null && _a !== void 0 ? _a : 1;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const mult = (Math.random() * (1 - this.minMult)) + this.minMult;\r\n next.config.speedMult = mult;\r\n if (!next.config.velocity) {\r\n next.config.velocity = new Point(this.list.first.value * mult, 0);\r\n }\r\n else {\r\n next.config.velocity.set(this.list.first.value * mult, 0);\r\n }\r\n rotatePoint(next.rotation, next.config.velocity);\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const speed = this.list.interpolate(particle.agePercent) * particle.config.speedMult;\r\n const vel = particle.config.velocity;\r\n normalize(vel);\r\n scaleBy(vel, speed);\r\n particle.x += vel.x * deltaSec;\r\n particle.y += vel.y * deltaSec;\r\n }\r\n}\r\nSpeedBehavior.type = 'moveSpeed';\r\nSpeedBehavior.editorConfig = null;\r\n/**\r\n * A Movement behavior that uses a randomly picked constant speed throughout a particle's lifetime.\r\n * Movement direction is controlled by the particle's starting rotation.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'moveSpeedStatic',\r\n * config: {\r\n * min: 100,\r\n * max: 150\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticSpeedBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Late;\r\n this.min = config.min;\r\n this.max = config.max;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const speed = (Math.random() * (this.max - this.min)) + this.min;\r\n if (!next.config.velocity) {\r\n next.config.velocity = new Point(speed, 0);\r\n }\r\n else {\r\n next.config.velocity.set(speed, 0);\r\n }\r\n rotatePoint(next.rotation, next.config.velocity);\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const velocity = particle.config.velocity;\r\n particle.x += velocity.x * deltaSec;\r\n particle.y += velocity.y * deltaSec;\r\n }\r\n}\r\nStaticSpeedBehavior.type = 'moveSpeedStatic';\r\nStaticSpeedBehavior.editorConfig = null;\n\n// export support types for external use\n\nvar index$1 = {\n __proto__: null,\n spawnShapes: index,\n editor: Types,\n get BehaviorOrder () { return BehaviorOrder; },\n AccelerationBehavior: AccelerationBehavior,\n AlphaBehavior: AlphaBehavior,\n StaticAlphaBehavior: StaticAlphaBehavior,\n RandomAnimatedTextureBehavior: RandomAnimatedTextureBehavior,\n SingleAnimatedTextureBehavior: SingleAnimatedTextureBehavior,\n BlendModeBehavior: BlendModeBehavior,\n BurstSpawnBehavior: BurstSpawnBehavior,\n ColorBehavior: ColorBehavior,\n StaticColorBehavior: StaticColorBehavior,\n OrderedTextureBehavior: OrderedTextureBehavior,\n PathBehavior: PathBehavior,\n PointSpawnBehavior: PointSpawnBehavior,\n RandomTextureBehavior: RandomTextureBehavior,\n RotationBehavior: RotationBehavior,\n StaticRotationBehavior: StaticRotationBehavior,\n NoRotationBehavior: NoRotationBehavior,\n ScaleBehavior: ScaleBehavior,\n StaticScaleBehavior: StaticScaleBehavior,\n ShapeSpawnBehavior: ShapeSpawnBehavior,\n SingleTextureBehavior: SingleTextureBehavior,\n SpeedBehavior: SpeedBehavior,\n StaticSpeedBehavior: StaticSpeedBehavior\n};\n\n/**\r\n * Converts emitter configuration from pre-5.0.0 library values into the current version.\r\n *\r\n * Example usage:\r\n * ```javascript\r\n * const emitter = new Emitter(myContainer, upgradeConfig(myOldConfig, [myTexture, myOtherTexture]));\r\n * ```\r\n * @param config The old emitter config to upgrade.\r\n * @param art The old art values as would have been passed into the Emitter constructor or `Emitter.init()`\r\n */\r\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\r\nfunction upgradeConfig(config, art) {\r\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w;\r\n // just ensure we aren't given any V3 config data\r\n if ('behaviors' in config) {\r\n return config;\r\n }\r\n const out = {\r\n lifetime: config.lifetime,\r\n ease: config.ease,\r\n particlesPerWave: config.particlesPerWave,\r\n frequency: config.frequency,\r\n spawnChance: config.spawnChance,\r\n emitterLifetime: config.emitterLifetime,\r\n maxParticles: config.maxParticles,\r\n addAtBack: config.addAtBack,\r\n pos: config.pos,\r\n emit: config.emit,\r\n autoUpdate: config.autoUpdate,\r\n behaviors: [],\r\n };\r\n // set up the alpha\r\n if (config.alpha) {\r\n if ('start' in config.alpha) {\r\n if (config.alpha.start === config.alpha.end) {\r\n if (config.alpha.start !== 1) {\r\n out.behaviors.push({\r\n type: 'alphaStatic',\r\n config: { alpha: config.alpha.start },\r\n });\r\n }\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.alpha.start },\r\n { time: 1, value: config.alpha.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'alpha',\r\n config: { alpha: list },\r\n });\r\n }\r\n }\r\n else if (config.alpha.list.length === 1) {\r\n if (config.alpha.list[0].value !== 1) {\r\n out.behaviors.push({\r\n type: 'alphaStatic',\r\n config: { alpha: config.alpha.list[0].value },\r\n });\r\n }\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'alpha',\r\n config: { alpha: config.alpha },\r\n });\r\n }\r\n }\r\n // acceleration movement\r\n if (config.acceleration && (config.acceleration.x || config.acceleration.y)) {\r\n let minStart;\r\n let maxStart;\r\n if ('start' in config.speed) {\r\n minStart = config.speed.start * ((_a = config.speed.minimumSpeedMultiplier) !== null && _a !== void 0 ? _a : 1);\r\n maxStart = config.speed.start;\r\n }\r\n else {\r\n minStart = config.speed.list[0].value * ((_b = config.minimumSpeedMultiplier) !== null && _b !== void 0 ? _b : 1);\r\n maxStart = config.speed.list[0].value;\r\n }\r\n out.behaviors.push({\r\n type: 'moveAcceleration',\r\n config: {\r\n accel: config.acceleration,\r\n minStart,\r\n maxStart,\r\n rotate: !config.noRotation,\r\n maxSpeed: config.maxSpeed,\r\n },\r\n });\r\n }\r\n // path movement\r\n else if ((_c = config.extraData) === null || _c === void 0 ? void 0 : _c.path) {\r\n let list;\r\n let mult;\r\n if ('start' in config.speed) {\r\n mult = (_d = config.speed.minimumSpeedMultiplier) !== null && _d !== void 0 ? _d : 1;\r\n if (config.speed.start === config.speed.end) {\r\n list = {\r\n list: [{ time: 0, value: config.speed.start }],\r\n };\r\n }\r\n else {\r\n list = {\r\n list: [\r\n { time: 0, value: config.speed.start },\r\n { time: 1, value: config.speed.end },\r\n ],\r\n };\r\n }\r\n }\r\n else {\r\n list = config.speed;\r\n mult = ((_e = config.minimumSpeedMultiplier) !== null && _e !== void 0 ? _e : 1);\r\n }\r\n out.behaviors.push({\r\n type: 'movePath',\r\n config: {\r\n path: config.extraData.path,\r\n speed: list,\r\n minMult: mult,\r\n },\r\n });\r\n }\r\n // normal speed movement\r\n else {\r\n if (config.speed) {\r\n if ('start' in config.speed) {\r\n if (config.speed.start === config.speed.end) {\r\n out.behaviors.push({\r\n type: 'moveSpeedStatic',\r\n config: {\r\n min: config.speed.start * ((_f = config.speed.minimumSpeedMultiplier) !== null && _f !== void 0 ? _f : 1),\r\n max: config.speed.start,\r\n },\r\n });\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.speed.start },\r\n { time: 1, value: config.speed.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'moveSpeed',\r\n config: { speed: list, minMult: config.speed.minimumSpeedMultiplier },\r\n });\r\n }\r\n }\r\n else if (config.speed.list.length === 1) {\r\n out.behaviors.push({\r\n type: 'moveSpeedStatic',\r\n config: {\r\n min: config.speed.list[0].value * ((_g = config.minimumSpeedMultiplier) !== null && _g !== void 0 ? _g : 1),\r\n max: config.speed.list[0].value,\r\n },\r\n });\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'moveSpeed',\r\n config: { speed: config.speed, minMult: ((_h = config.minimumSpeedMultiplier) !== null && _h !== void 0 ? _h : 1) },\r\n });\r\n }\r\n }\r\n }\r\n // scale\r\n if (config.scale) {\r\n if ('start' in config.scale) {\r\n const mult = (_j = config.scale.minimumScaleMultiplier) !== null && _j !== void 0 ? _j : 1;\r\n if (config.scale.start === config.scale.end) {\r\n out.behaviors.push({\r\n type: 'scaleStatic',\r\n config: {\r\n min: config.scale.start * mult,\r\n max: config.scale.start,\r\n },\r\n });\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.scale.start },\r\n { time: 1, value: config.scale.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'scale',\r\n config: { scale: list, minMult: mult },\r\n });\r\n }\r\n }\r\n else if (config.scale.list.length === 1) {\r\n const mult = (_k = config.minimumScaleMultiplier) !== null && _k !== void 0 ? _k : 1;\r\n const scale = config.scale.list[0].value;\r\n out.behaviors.push({\r\n type: 'scaleStatic',\r\n config: { min: scale * mult, max: scale },\r\n });\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'scale',\r\n config: { scale: config.scale, minMult: (_l = config.minimumScaleMultiplier) !== null && _l !== void 0 ? _l : 1 },\r\n });\r\n }\r\n }\r\n // color\r\n if (config.color) {\r\n if ('start' in config.color) {\r\n if (config.color.start === config.color.end) {\r\n if (config.color.start !== 'ffffff') {\r\n out.behaviors.push({\r\n type: 'colorStatic',\r\n config: { color: config.color.start },\r\n });\r\n }\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.color.start },\r\n { time: 1, value: config.color.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'color',\r\n config: { color: list },\r\n });\r\n }\r\n }\r\n else if (config.color.list.length === 1) {\r\n if (config.color.list[0].value !== 'ffffff') {\r\n out.behaviors.push({\r\n type: 'colorStatic',\r\n config: { color: config.color.list[0].value },\r\n });\r\n }\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'color',\r\n config: { color: config.color },\r\n });\r\n }\r\n }\r\n // rotation\r\n if (config.rotationAcceleration || ((_m = config.rotationSpeed) === null || _m === void 0 ? void 0 : _m.min) || ((_o = config.rotationSpeed) === null || _o === void 0 ? void 0 : _o.max)) {\r\n out.behaviors.push({\r\n type: 'rotation',\r\n config: {\r\n accel: config.rotationAcceleration || 0,\r\n minSpeed: ((_p = config.rotationSpeed) === null || _p === void 0 ? void 0 : _p.min) || 0,\r\n maxSpeed: ((_q = config.rotationSpeed) === null || _q === void 0 ? void 0 : _q.max) || 0,\r\n minStart: ((_r = config.startRotation) === null || _r === void 0 ? void 0 : _r.min) || 0,\r\n maxStart: ((_s = config.startRotation) === null || _s === void 0 ? void 0 : _s.max) || 0,\r\n },\r\n });\r\n }\r\n else if (((_t = config.startRotation) === null || _t === void 0 ? void 0 : _t.min) || ((_u = config.startRotation) === null || _u === void 0 ? void 0 : _u.max)) {\r\n out.behaviors.push({\r\n type: 'rotationStatic',\r\n config: {\r\n min: ((_v = config.startRotation) === null || _v === void 0 ? void 0 : _v.min) || 0,\r\n max: ((_w = config.startRotation) === null || _w === void 0 ? void 0 : _w.max) || 0,\r\n },\r\n });\r\n }\r\n if (config.noRotation) {\r\n out.behaviors.push({\r\n type: 'noRotation',\r\n config: {},\r\n });\r\n }\r\n // blend mode\r\n if (config.blendMode && config.blendMode !== 'normal') {\r\n out.behaviors.push({\r\n type: 'blendMode',\r\n config: {\r\n blendMode: config.blendMode,\r\n },\r\n });\r\n }\r\n // animated\r\n if (Array.isArray(art) && typeof art[0] !== 'string' && 'framerate' in art[0]) {\r\n for (let i = 0; i < art.length; ++i) {\r\n if (art[i].framerate === 'matchLife') {\r\n art[i].framerate = -1;\r\n }\r\n }\r\n out.behaviors.push({\r\n type: 'animatedRandom',\r\n config: {\r\n anims: art,\r\n },\r\n });\r\n }\r\n else if (typeof art !== 'string' && 'framerate' in art) {\r\n if (art.framerate === 'matchLife') {\r\n art.framerate = -1;\r\n }\r\n out.behaviors.push({\r\n type: 'animatedSingle',\r\n config: {\r\n anim: art,\r\n },\r\n });\r\n }\r\n // ordered art\r\n else if (config.orderedArt && Array.isArray(art)) {\r\n out.behaviors.push({\r\n type: 'textureOrdered',\r\n config: {\r\n textures: art,\r\n },\r\n });\r\n }\r\n // random texture\r\n else if (Array.isArray(art)) {\r\n out.behaviors.push({\r\n type: 'textureRandom',\r\n config: {\r\n textures: art,\r\n },\r\n });\r\n }\r\n // single texture\r\n else {\r\n out.behaviors.push({\r\n type: 'textureSingle',\r\n config: {\r\n texture: art,\r\n },\r\n });\r\n }\r\n // spawn burst\r\n if (config.spawnType === 'burst') {\r\n out.behaviors.push({\r\n type: 'spawnBurst',\r\n config: {\r\n start: config.angleStart || 0,\r\n spacing: config.particleSpacing,\r\n // older formats bursted from a single point\r\n distance: 0,\r\n },\r\n });\r\n }\r\n // spawn point\r\n else if (config.spawnType === 'point') {\r\n out.behaviors.push({\r\n type: 'spawnPoint',\r\n config: {},\r\n });\r\n }\r\n // spawn shape\r\n else {\r\n let shape;\r\n if (config.spawnType === 'ring') {\r\n shape = {\r\n type: 'torus',\r\n data: {\r\n x: config.spawnCircle.x,\r\n y: config.spawnCircle.y,\r\n radius: config.spawnCircle.r,\r\n innerRadius: config.spawnCircle.minR,\r\n affectRotation: true,\r\n },\r\n };\r\n }\r\n else if (config.spawnType === 'circle') {\r\n shape = {\r\n type: 'torus',\r\n data: {\r\n x: config.spawnCircle.x,\r\n y: config.spawnCircle.y,\r\n radius: config.spawnCircle.r,\r\n innerRadius: 0,\r\n affectRotation: false,\r\n },\r\n };\r\n }\r\n else if (config.spawnType === 'rect') {\r\n shape = {\r\n type: 'rect',\r\n data: config.spawnRect,\r\n };\r\n }\r\n else if (config.spawnType === 'polygonalChain') {\r\n shape = {\r\n type: 'polygonalChain',\r\n data: config.spawnPolygon,\r\n };\r\n }\r\n if (shape) {\r\n out.behaviors.push({\r\n type: 'spawnShape',\r\n config: shape,\r\n });\r\n }\r\n }\r\n return out;\r\n}\n\n/**\r\n * A semi-experimental Container that uses a doubly linked list to manage children instead of an\r\n * array. This means that adding/removing children often is not the same performance hit that\r\n * it would to be continually pushing/splicing.\r\n * However, this is primarily intended to be used for heavy particle usage, and may not handle\r\n * edge cases well if used as a complete Container replacement.\r\n */\r\nclass LinkedListContainer extends Container {\r\n constructor() {\r\n super(...arguments);\r\n this._firstChild = null;\r\n this._lastChild = null;\r\n this._childCount = 0;\r\n }\r\n get firstChild() {\r\n return this._firstChild;\r\n }\r\n get lastChild() {\r\n return this._lastChild;\r\n }\r\n get childCount() {\r\n return this._childCount;\r\n }\r\n addChild(...children) {\r\n // if there is only one argument we can bypass looping through the them\r\n if (children.length > 1) {\r\n // loop through the array and add all children\r\n for (let i = 0; i < children.length; i++) {\r\n // eslint-disable-next-line prefer-rest-params\r\n this.addChild(children[i]);\r\n }\r\n }\r\n else {\r\n const child = children[0];\r\n // if the child has a parent then lets remove it as PixiJS objects can only exist in one place\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // add to list if we have a list\r\n if (this._lastChild) {\r\n this._lastChild.nextChild = child;\r\n child.prevChild = this._lastChild;\r\n this._lastChild = child;\r\n }\r\n // otherwise initialize the list\r\n else {\r\n this._firstChild = this._lastChild = child;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n this.emit('childAdded', child, this, this._childCount);\r\n child.emit('added', this);\r\n }\r\n return children[0];\r\n }\r\n addChildAt(child, index) {\r\n if (index < 0 || index > this._childCount) {\r\n throw new Error(`addChildAt: The index ${index} supplied is out of bounds ${this._childCount}`);\r\n }\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n const c = child;\r\n // if no children, do basic initialization\r\n if (!this._firstChild) {\r\n this._firstChild = this._lastChild = c;\r\n }\r\n // add at beginning (back)\r\n else if (index === 0) {\r\n this._firstChild.prevChild = c;\r\n c.nextChild = this._firstChild;\r\n this._firstChild = c;\r\n }\r\n // add at end (front)\r\n else if (index === this._childCount) {\r\n this._lastChild.nextChild = c;\r\n c.prevChild = this._lastChild;\r\n this._lastChild = c;\r\n }\r\n // otherwise we have to start counting through the children to find the right one\r\n // - SLOW, only provided to fully support the possibility of use\r\n else {\r\n let i = 0;\r\n let target = this._firstChild;\r\n while (i < index) {\r\n target = target.nextChild;\r\n ++i;\r\n }\r\n // insert before the target that we found at the specified index\r\n target.prevChild.nextChild = c;\r\n c.prevChild = target.prevChild;\r\n c.nextChild = target;\r\n target.prevChild = c;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange(index);\r\n child.emit('added', this);\r\n this.emit('childAdded', child, this, index);\r\n return child;\r\n }\r\n /**\r\n * Adds a child to the container to be rendered below another child.\r\n *\r\n * @param child The child to add\r\n * @param relative - The current child to add the new child relative to.\r\n * @return The child that was added.\r\n */\r\n addChildBelow(child, relative) {\r\n if (relative.parent !== this) {\r\n throw new Error(`addChildBelow: The relative target must be a child of this parent`);\r\n }\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // insert before the target that we were given\r\n relative.prevChild.nextChild = child;\r\n child.prevChild = relative.prevChild;\r\n child.nextChild = relative;\r\n relative.prevChild = child;\r\n if (this._firstChild === relative) {\r\n this._firstChild = child;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n this.emit('childAdded', child, this, this._childCount);\r\n child.emit('added', this);\r\n return child;\r\n }\r\n /**\r\n * Adds a child to the container to be rendered above another child.\r\n *\r\n * @param child The child to add\r\n * @param relative - The current child to add the new child relative to.\r\n * @return The child that was added.\r\n */\r\n addChildAbove(child, relative) {\r\n if (relative.parent !== this) {\r\n throw new Error(`addChildBelow: The relative target must be a child of this parent`);\r\n }\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // insert after the target that we were given\r\n relative.nextChild.prevChild = child;\r\n child.nextChild = relative.nextChild;\r\n child.prevChild = relative;\r\n relative.nextChild = child;\r\n if (this._lastChild === relative) {\r\n this._lastChild = child;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n this.emit('childAdded', child, this, this._childCount);\r\n child.emit('added', this);\r\n return child;\r\n }\r\n swapChildren(child, child2) {\r\n if (child === child2 || child.parent !== this || child2.parent !== this) {\r\n return;\r\n }\r\n const { prevChild, nextChild } = child;\r\n child.prevChild = child2.prevChild;\r\n child.nextChild = child2.nextChild;\r\n child2.prevChild = prevChild;\r\n child2.nextChild = nextChild;\r\n if (this._firstChild === child) {\r\n this._firstChild = child2;\r\n }\r\n else if (this._firstChild === child2) {\r\n this._firstChild = child;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child2;\r\n }\r\n else if (this._lastChild === child2) {\r\n this._lastChild = child;\r\n }\r\n this.onChildrenChange();\r\n }\r\n getChildIndex(child) {\r\n let index = 0;\r\n let test = this._firstChild;\r\n while (test) {\r\n if (test === child) {\r\n break;\r\n }\r\n test = test.nextChild;\r\n ++index;\r\n }\r\n if (!test) {\r\n throw new Error('The supplied DisplayObject must be a child of the caller');\r\n }\r\n return index;\r\n }\r\n setChildIndex(child, index) {\r\n if (index < 0 || index >= this._childCount) {\r\n throw new Error(`The index ${index} supplied is out of bounds ${this._childCount}`);\r\n }\r\n if (child.parent !== this) {\r\n throw new Error('The supplied DisplayObject must be a child of the caller');\r\n }\r\n // remove child\r\n if (child.nextChild) {\r\n child.nextChild.prevChild = child.prevChild;\r\n }\r\n if (child.prevChild) {\r\n child.prevChild.nextChild = child.nextChild;\r\n }\r\n if (this._firstChild === child) {\r\n this._firstChild = child.nextChild;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child.prevChild;\r\n }\r\n child.nextChild = null;\r\n child.prevChild = null;\r\n // do addChildAt\r\n if (!this._firstChild) {\r\n this._firstChild = this._lastChild = child;\r\n }\r\n else if (index === 0) {\r\n this._firstChild.prevChild = child;\r\n child.nextChild = this._firstChild;\r\n this._firstChild = child;\r\n }\r\n else if (index === this._childCount) {\r\n this._lastChild.nextChild = child;\r\n child.prevChild = this._lastChild;\r\n this._lastChild = child;\r\n }\r\n else {\r\n let i = 0;\r\n let target = this._firstChild;\r\n while (i < index) {\r\n target = target.nextChild;\r\n ++i;\r\n }\r\n target.prevChild.nextChild = child;\r\n child.prevChild = target.prevChild;\r\n child.nextChild = target;\r\n target.prevChild = child;\r\n }\r\n this.onChildrenChange(index);\r\n }\r\n removeChild(...children) {\r\n // if there is only one argument we can bypass looping through the them\r\n if (children.length > 1) {\r\n // loop through the arguments property and remove all children\r\n for (let i = 0; i < children.length; i++) {\r\n this.removeChild(children[i]);\r\n }\r\n }\r\n else {\r\n const child = children[0];\r\n // bail if not actually our child\r\n if (child.parent !== this)\r\n return null;\r\n child.parent = null;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // swap out child references\r\n if (child.nextChild) {\r\n child.nextChild.prevChild = child.prevChild;\r\n }\r\n if (child.prevChild) {\r\n child.prevChild.nextChild = child.nextChild;\r\n }\r\n if (this._firstChild === child) {\r\n this._firstChild = child.nextChild;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child.prevChild;\r\n }\r\n // clear sibling references\r\n child.nextChild = null;\r\n child.prevChild = null;\r\n // update child count\r\n --this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n child.emit('removed', this);\r\n this.emit('childRemoved', child, this);\r\n }\r\n return children[0];\r\n }\r\n getChildAt(index) {\r\n if (index < 0 || index >= this._childCount) {\r\n throw new Error(`getChildAt: Index (${index}) does not exist.`);\r\n }\r\n if (index === 0) {\r\n return this._firstChild;\r\n }\r\n // add at end (front)\r\n else if (index === this._childCount) {\r\n return this._lastChild;\r\n }\r\n // otherwise we have to start counting through the children to find the right one\r\n // - SLOW, only provided to fully support the possibility of use\r\n let i = 0;\r\n let target = this._firstChild;\r\n while (i < index) {\r\n target = target.nextChild;\r\n ++i;\r\n }\r\n return target;\r\n }\r\n removeChildAt(index) {\r\n const child = this.getChildAt(index);\r\n // ensure child transform will be recalculated..\r\n child.parent = null;\r\n child.transform._parentID = -1;\r\n // swap out child references\r\n if (child.nextChild) {\r\n child.nextChild.prevChild = child.prevChild;\r\n }\r\n if (child.prevChild) {\r\n child.prevChild.nextChild = child.nextChild;\r\n }\r\n if (this._firstChild === child) {\r\n this._firstChild = child.nextChild;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child.prevChild;\r\n }\r\n // clear sibling references\r\n child.nextChild = null;\r\n child.prevChild = null;\r\n // update child count\r\n --this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange(index);\r\n child.emit('removed', this);\r\n this.emit('childRemoved', child, this, index);\r\n return child;\r\n }\r\n removeChildren(beginIndex = 0, endIndex = this._childCount) {\r\n const begin = beginIndex;\r\n const end = endIndex;\r\n const range = end - begin;\r\n if (range > 0 && range <= end) {\r\n const removed = [];\r\n let child = this._firstChild;\r\n for (let i = 0; i <= end && child; ++i, child = child.nextChild) {\r\n if (i >= begin) {\r\n removed.push(child);\r\n }\r\n }\r\n // child before removed section\r\n const prevChild = removed[0].prevChild;\r\n // child after removed section\r\n const nextChild = removed[removed.length - 1].nextChild;\r\n if (!nextChild) {\r\n // if we removed the last child, then the new last child is the one before\r\n // the removed section\r\n this._lastChild = prevChild;\r\n }\r\n else {\r\n // otherwise, stitch the child before the section to the child after\r\n nextChild.prevChild = prevChild;\r\n }\r\n if (!prevChild) {\r\n // if we removed the first child, then the new first child is the one after\r\n // the removed section\r\n this._firstChild = nextChild;\r\n }\r\n else {\r\n // otherwise stich the child after the section to the one before\r\n prevChild.nextChild = nextChild;\r\n }\r\n for (let i = 0; i < removed.length; ++i) {\r\n // clear parenting and sibling references for all removed children\r\n removed[i].parent = null;\r\n if (removed[i].transform) {\r\n removed[i].transform._parentID = -1;\r\n }\r\n removed[i].nextChild = null;\r\n removed[i].prevChild = null;\r\n }\r\n this._boundsID++;\r\n this.onChildrenChange(beginIndex);\r\n for (let i = 0; i < removed.length; ++i) {\r\n removed[i].emit('removed', this);\r\n this.emit('childRemoved', removed[i], this, i);\r\n }\r\n return removed;\r\n }\r\n else if (range === 0 && this._childCount === 0) {\r\n return [];\r\n }\r\n throw new RangeError('removeChildren: numeric values are outside the acceptable range.');\r\n }\r\n /**\r\n * Updates the transform on all children of this container for rendering.\r\n * Copied from and overrides PixiJS v5 method (v4 method is identical)\r\n */\r\n updateTransform() {\r\n this._boundsID++;\r\n this.transform.updateTransform(this.parent.transform);\r\n // TODO: check render flags, how to process stuff here\r\n this.worldAlpha = this.alpha * this.parent.worldAlpha;\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n if (child.visible) {\r\n child.updateTransform();\r\n }\r\n }\r\n }\r\n /**\r\n * Recalculates the bounds of the container.\r\n * Copied from and overrides PixiJS v5 method (v4 method is identical)\r\n */\r\n calculateBounds() {\r\n this._bounds.clear();\r\n this._calculateBounds();\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n if (!child.visible || !child.renderable) {\r\n continue;\r\n }\r\n child.calculateBounds();\r\n // TODO: filter+mask, need to mask both somehow\r\n if (child._mask) {\r\n const maskObject = (child._mask.maskObject || child._mask);\r\n maskObject.calculateBounds();\r\n this._bounds.addBoundsMask(child._bounds, maskObject._bounds);\r\n }\r\n else if (child.filterArea) {\r\n this._bounds.addBoundsArea(child._bounds, child.filterArea);\r\n }\r\n else {\r\n this._bounds.addBounds(child._bounds);\r\n }\r\n }\r\n this._bounds.updateID = this._boundsID;\r\n }\r\n /**\r\n * Retrieves the local bounds of the displayObject as a rectangle object. Copied from and overrides PixiJS v5 method\r\n */\r\n getLocalBounds(rect, skipChildrenUpdate = false) {\r\n // skip Container's getLocalBounds, go directly to DisplayObject\r\n const result = DisplayObject.prototype.getLocalBounds.call(this, rect);\r\n if (!skipChildrenUpdate) {\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n if (child.visible) {\r\n child.updateTransform();\r\n }\r\n }\r\n }\r\n return result;\r\n }\r\n /**\r\n * Renders the object using the WebGL renderer. Copied from and overrides PixiJS v5 method\r\n */\r\n render(renderer) {\r\n // if the object is not visible or the alpha is 0 then no need to render this element\r\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\r\n return;\r\n }\r\n // do a quick check to see if this element has a mask or a filter.\r\n if (this._mask || (this.filters && this.filters.length)) {\r\n this.renderAdvanced(renderer);\r\n }\r\n else {\r\n this._render(renderer);\r\n let child;\r\n let next;\r\n // simple render children!\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n child.render(renderer);\r\n }\r\n }\r\n }\r\n /**\r\n * Render the object using the WebGL renderer and advanced features. Copied from and overrides PixiJS v5 method\r\n */\r\n renderAdvanced(renderer) {\r\n renderer.batch.flush();\r\n const filters = this.filters;\r\n const mask = this._mask;\r\n // _enabledFilters note: As of development, _enabledFilters is not documented in pixi.js\r\n // types but is in code of current release (5.2.4).\r\n // push filter first as we need to ensure the stencil buffer is correct for any masking\r\n if (filters) {\r\n if (!this._enabledFilters) {\r\n this._enabledFilters = [];\r\n }\r\n this._enabledFilters.length = 0;\r\n for (let i = 0; i < filters.length; i++) {\r\n if (filters[i].enabled) {\r\n this._enabledFilters.push(filters[i]);\r\n }\r\n }\r\n if (this._enabledFilters.length) {\r\n renderer.filter.push(this, this._enabledFilters);\r\n }\r\n }\r\n if (mask) {\r\n renderer.mask.push(this, this._mask);\r\n }\r\n // add this object to the batch, only rendered if it has a texture.\r\n this._render(renderer);\r\n let child;\r\n let next;\r\n // now loop through the children and make sure they get rendered\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n child.render(renderer);\r\n }\r\n renderer.batch.flush();\r\n if (mask) {\r\n renderer.mask.pop(this);\r\n }\r\n if (filters && this._enabledFilters && this._enabledFilters.length) {\r\n renderer.filter.pop();\r\n }\r\n }\r\n /**\r\n * Renders the object using the Canvas renderer. Copied from and overrides PixiJS Canvas mixin in V5 and V6.\r\n */\r\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\r\n renderCanvas(renderer) {\r\n // if not visible or the alpha is 0 then no need to render this\r\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\r\n return;\r\n }\r\n if (this._mask) {\r\n renderer.maskManager.pushMask(this._mask);\r\n }\r\n this._renderCanvas(renderer);\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n child.renderCanvas(renderer);\r\n }\r\n if (this._mask) {\r\n renderer.maskManager.popMask(renderer);\r\n }\r\n }\r\n}\n\nEmitter.registerBehavior(AccelerationBehavior);\r\nEmitter.registerBehavior(AlphaBehavior);\r\nEmitter.registerBehavior(StaticAlphaBehavior);\r\nEmitter.registerBehavior(RandomAnimatedTextureBehavior);\r\nEmitter.registerBehavior(SingleAnimatedTextureBehavior);\r\nEmitter.registerBehavior(BlendModeBehavior);\r\nEmitter.registerBehavior(BurstSpawnBehavior);\r\nEmitter.registerBehavior(ColorBehavior);\r\nEmitter.registerBehavior(StaticColorBehavior);\r\nEmitter.registerBehavior(OrderedTextureBehavior);\r\nEmitter.registerBehavior(PathBehavior);\r\nEmitter.registerBehavior(PointSpawnBehavior);\r\nEmitter.registerBehavior(RandomTextureBehavior);\r\nEmitter.registerBehavior(RotationBehavior);\r\nEmitter.registerBehavior(StaticRotationBehavior);\r\nEmitter.registerBehavior(NoRotationBehavior);\r\nEmitter.registerBehavior(ScaleBehavior);\r\nEmitter.registerBehavior(StaticScaleBehavior);\r\nEmitter.registerBehavior(ShapeSpawnBehavior);\r\nEmitter.registerBehavior(SingleTextureBehavior);\r\nEmitter.registerBehavior(SpeedBehavior);\r\nEmitter.registerBehavior(StaticSpeedBehavior);\n\nexport { Emitter, LinkedListContainer, Particle, ParticleUtils, PropertyList, PropertyNode, index$1 as behaviors, upgradeConfig };\n//# sourceMappingURL=particle-emitter.es.js.map\n","/*!\n * @pixi/runner - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/runner is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * A Runner is a highly performant and simple alternative to signals. Best used in situations\n * where events are dispatched to many objects at high frequency (say every frame!)\n *\n *\n * like a signal..\n * ```\n * import { Runner } from '@pixi/runner';\n *\n * const myObject = {\n * loaded: new Runner('loaded')\n * }\n *\n * const listener = {\n * loaded: function(){\n * // thin\n * }\n * }\n *\n * myObject.loaded.add(listener);\n *\n * myObject.loaded.emit();\n * ```\n *\n * Or for handling calling the same function on many items\n * ```\n * import { Runner } from '@pixi/runner';\n *\n * const myGame = {\n * update: new Runner('update')\n * }\n *\n * const gameObject = {\n * update: function(time){\n * // update my gamey state\n * }\n * }\n *\n * myGame.update.add(gameObject);\n *\n * myGame.update.emit(time);\n * ```\n *\n * @memberof PIXI\n */\nvar Runner = /** @class */ (function () {\n /**\n * @param name - The function name that will be executed on the listeners added to this Runner.\n */\n function Runner(name) {\n this.items = [];\n this._name = name;\n this._aliasCount = 0;\n }\n /**\n * Dispatch/Broadcast Runner to all listeners added to the queue.\n *\n * @param {...any} params - (optional) parameters to pass to each listener\n */\n Runner.prototype.emit = function (a0, a1, a2, a3, a4, a5, a6, a7) {\n if (arguments.length > 8) {\n throw new Error('max arguments reached');\n }\n var _a = this, name = _a.name, items = _a.items;\n this._aliasCount++;\n for (var i = 0, len = items.length; i < len; i++) {\n items[i][name](a0, a1, a2, a3, a4, a5, a6, a7);\n }\n if (items === this.items) {\n this._aliasCount--;\n }\n return this;\n };\n Runner.prototype.ensureNonAliasedItems = function () {\n if (this._aliasCount > 0 && this.items.length > 1) {\n this._aliasCount = 0;\n this.items = this.items.slice(0);\n }\n };\n /**\n * Add a listener to the Runner\n *\n * Runners do not need to have scope or functions passed to them.\n * All that is required is to pass the listening object and ensure that it has contains a function that has the same name\n * as the name provided to the Runner when it was created.\n *\n * Eg A listener passed to this Runner will require a 'complete' function.\n *\n * ```\n * import { Runner } from '@pixi/runner';\n *\n * const complete = new Runner('complete');\n * ```\n *\n * The scope used will be the object itself.\n *\n * @param {any} item - The object that will be listening.\n */\n Runner.prototype.add = function (item) {\n if (item[this._name]) {\n this.ensureNonAliasedItems();\n this.remove(item);\n this.items.push(item);\n }\n return this;\n };\n /**\n * Remove a single listener from the dispatch queue.\n *\n * @param {any} item - The listener that you would like to remove.\n */\n Runner.prototype.remove = function (item) {\n var index = this.items.indexOf(item);\n if (index !== -1) {\n this.ensureNonAliasedItems();\n this.items.splice(index, 1);\n }\n return this;\n };\n /**\n * Check to see if the listener is already in the Runner\n *\n * @param {any} item - The listener that you would like to check.\n */\n Runner.prototype.contains = function (item) {\n return this.items.indexOf(item) !== -1;\n };\n /** Remove all listeners from the Runner */\n Runner.prototype.removeAll = function () {\n this.ensureNonAliasedItems();\n this.items.length = 0;\n return this;\n };\n /** Remove all references, don't use after this. */\n Runner.prototype.destroy = function () {\n this.removeAll();\n this.items = null;\n this._name = null;\n };\n Object.defineProperty(Runner.prototype, \"empty\", {\n /**\n * `true` if there are no this Runner contains no listeners\n *\n * @readonly\n */\n get: function () {\n return this.items.length === 0;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Runner.prototype, \"name\", {\n /**\n * The name of the runner.\n *\n * @readonly\n */\n get: function () {\n return this._name;\n },\n enumerable: false,\n configurable: true\n });\n return Runner;\n}());\nObject.defineProperties(Runner.prototype, {\n /**\n * Alias for `emit`\n * @memberof PIXI.Runner#\n * @method dispatch\n * @see PIXI.Runner#emit\n */\n dispatch: { value: Runner.prototype.emit },\n /**\n * Alias for `emit`\n * @memberof PIXI.Runner#\n * @method run\n * @see PIXI.Runner#emit\n */\n run: { value: Runner.prototype.emit },\n});\n\nexport { Runner };\n//# sourceMappingURL=runner.js.map\n","var appleIphone = /iPhone/i;\nvar appleIpod = /iPod/i;\nvar appleTablet = /iPad/i;\nvar appleUniversal = /\\biOS-universal(?:.+)Mac\\b/i;\nvar androidPhone = /\\bAndroid(?:.+)Mobile\\b/i;\nvar androidTablet = /Android/i;\nvar amazonPhone = /(?:SD4930UR|\\bSilk(?:.+)Mobile\\b)/i;\nvar amazonTablet = /Silk/i;\nvar windowsPhone = /Windows Phone/i;\nvar windowsTablet = /\\bWindows(?:.+)ARM\\b/i;\nvar otherBlackBerry = /BlackBerry/i;\nvar otherBlackBerry10 = /BB10/i;\nvar otherOpera = /Opera Mini/i;\nvar otherChrome = /\\b(CriOS|Chrome)(?:.+)Mobile/i;\nvar otherFirefox = /Mobile(?:.+)Firefox\\b/i;\nvar isAppleTabletOnIos13 = function (navigator) {\n return (typeof navigator !== 'undefined' &&\n navigator.platform === 'MacIntel' &&\n typeof navigator.maxTouchPoints === 'number' &&\n navigator.maxTouchPoints > 1 &&\n typeof MSStream === 'undefined');\n};\nfunction createMatch(userAgent) {\n return function (regex) { return regex.test(userAgent); };\n}\nexport default function isMobile(param) {\n var nav = {\n userAgent: '',\n platform: '',\n maxTouchPoints: 0\n };\n if (!param && typeof navigator !== 'undefined') {\n nav = {\n userAgent: navigator.userAgent,\n platform: navigator.platform,\n maxTouchPoints: navigator.maxTouchPoints || 0\n };\n }\n else if (typeof param === 'string') {\n nav.userAgent = param;\n }\n else if (param && param.userAgent) {\n nav = {\n userAgent: param.userAgent,\n platform: param.platform,\n maxTouchPoints: param.maxTouchPoints || 0\n };\n }\n var userAgent = nav.userAgent;\n var tmp = userAgent.split('[FBAN');\n if (typeof tmp[1] !== 'undefined') {\n userAgent = tmp[0];\n }\n tmp = userAgent.split('Twitter');\n if (typeof tmp[1] !== 'undefined') {\n userAgent = tmp[0];\n }\n var match = createMatch(userAgent);\n var result = {\n apple: {\n phone: match(appleIphone) && !match(windowsPhone),\n ipod: match(appleIpod),\n tablet: !match(appleIphone) &&\n (match(appleTablet) || isAppleTabletOnIos13(nav)) &&\n !match(windowsPhone),\n universal: match(appleUniversal),\n device: (match(appleIphone) ||\n match(appleIpod) ||\n match(appleTablet) ||\n match(appleUniversal) ||\n isAppleTabletOnIos13(nav)) &&\n !match(windowsPhone)\n },\n amazon: {\n phone: match(amazonPhone),\n tablet: !match(amazonPhone) && match(amazonTablet),\n device: match(amazonPhone) || match(amazonTablet)\n },\n android: {\n phone: (!match(windowsPhone) && match(amazonPhone)) ||\n (!match(windowsPhone) && match(androidPhone)),\n tablet: !match(windowsPhone) &&\n !match(amazonPhone) &&\n !match(androidPhone) &&\n (match(amazonTablet) || match(androidTablet)),\n device: (!match(windowsPhone) &&\n (match(amazonPhone) ||\n match(amazonTablet) ||\n match(androidPhone) ||\n match(androidTablet))) ||\n match(/\\bokhttp\\b/i)\n },\n windows: {\n phone: match(windowsPhone),\n tablet: match(windowsTablet),\n device: match(windowsPhone) || match(windowsTablet)\n },\n other: {\n blackberry: match(otherBlackBerry),\n blackberry10: match(otherBlackBerry10),\n opera: match(otherOpera),\n firefox: match(otherFirefox),\n chrome: match(otherChrome),\n device: match(otherBlackBerry) ||\n match(otherBlackBerry10) ||\n match(otherOpera) ||\n match(otherFirefox) ||\n match(otherChrome)\n },\n any: false,\n phone: false,\n tablet: false\n };\n result.any =\n result.apple.device ||\n result.android.device ||\n result.windows.device ||\n result.other.device;\n result.phone =\n result.apple.phone || result.android.phone || result.windows.phone;\n result.tablet =\n result.apple.tablet || result.android.tablet || result.windows.tablet;\n return result;\n}\n//# sourceMappingURL=isMobile.js.map","/*!\n * @pixi/settings - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/settings is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport isMobileCall from 'ismobilejs';\n\n// The ESM/CJS versions of ismobilejs only\nvar isMobile = isMobileCall(globalThis.navigator);\n\n/**\n * The maximum recommended texture units to use.\n * In theory the bigger the better, and for desktop we'll use as many as we can.\n * But some mobile devices slow down if there is to many branches in the shader.\n * So in practice there seems to be a sweet spot size that varies depending on the device.\n *\n * In v4, all mobile devices were limited to 4 texture units because for this.\n * In v5, we allow all texture units to be used on modern Apple or Android devices.\n *\n * @private\n * @param {number} max\n * @returns {number}\n */\nfunction maxRecommendedTextures(max) {\n var allowMax = true;\n if (isMobile.tablet || isMobile.phone) {\n if (isMobile.apple.device) {\n var match = (navigator.userAgent).match(/OS (\\d+)_(\\d+)?/);\n if (match) {\n var majorVersion = parseInt(match[1], 10);\n // Limit texture units on devices below iOS 11, which will be older hardware\n if (majorVersion < 11) {\n allowMax = false;\n }\n }\n }\n if (isMobile.android.device) {\n var match = (navigator.userAgent).match(/Android\\s([0-9.]*)/);\n if (match) {\n var majorVersion = parseInt(match[1], 10);\n // Limit texture units on devices below Android 7 (Nougat), which will be older hardware\n if (majorVersion < 7) {\n allowMax = false;\n }\n }\n }\n }\n return allowMax ? max : 4;\n}\n\n/**\n * Uploading the same buffer multiple times in a single frame can cause performance issues.\n * Apparent on iOS so only check for that at the moment\n * This check may become more complex if this issue pops up elsewhere.\n *\n * @private\n * @returns {boolean}\n */\nfunction canUploadSameBuffer() {\n return !isMobile.apple.device;\n}\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\n/**\n * User's customizable globals for overriding the default PIXI settings, such\n * as a renderer's default resolution, framerate, float precision, etc.\n * @example\n * // Use the native window resolution as the default resolution\n * // will support high-density displays when rendering\n * PIXI.settings.RESOLUTION = window.devicePixelRatio;\n *\n * // Disable interpolation when scaling, will make texture be pixelated\n * PIXI.settings.SCALE_MODE = PIXI.SCALE_MODES.NEAREST;\n * @namespace PIXI.settings\n */\nvar settings = {\n /**\n * If set to true WebGL will attempt make textures mimpaped by default.\n * Mipmapping will only succeed if the base texture uploaded has power of two dimensions.\n *\n * @static\n * @name MIPMAP_TEXTURES\n * @memberof PIXI.settings\n * @type {PIXI.MIPMAP_MODES}\n * @default PIXI.MIPMAP_MODES.POW2\n */\n MIPMAP_TEXTURES: MIPMAP_MODES.POW2,\n /**\n * Default anisotropic filtering level of textures.\n * Usually from 0 to 16\n *\n * @static\n * @name ANISOTROPIC_LEVEL\n * @memberof PIXI.settings\n * @type {number}\n * @default 0\n */\n ANISOTROPIC_LEVEL: 0,\n /**\n * Default resolution / device pixel ratio of the renderer.\n *\n * @static\n * @name RESOLUTION\n * @memberof PIXI.settings\n * @type {number}\n * @default 1\n */\n RESOLUTION: 1,\n /**\n * Default filter resolution.\n *\n * @static\n * @name FILTER_RESOLUTION\n * @memberof PIXI.settings\n * @type {number}\n * @default 1\n */\n FILTER_RESOLUTION: 1,\n /**\n * Default filter samples.\n *\n * @static\n * @name FILTER_MULTISAMPLE\n * @memberof PIXI.settings\n * @type {PIXI.MSAA_QUALITY}\n * @default PIXI.MSAA_QUALITY.NONE\n */\n FILTER_MULTISAMPLE: MSAA_QUALITY.NONE,\n /**\n * The maximum textures that this device supports.\n *\n * @static\n * @name SPRITE_MAX_TEXTURES\n * @memberof PIXI.settings\n * @type {number}\n * @default 32\n */\n SPRITE_MAX_TEXTURES: maxRecommendedTextures(32),\n // TODO: maybe change to SPRITE.BATCH_SIZE: 2000\n // TODO: maybe add PARTICLE.BATCH_SIZE: 15000\n /**\n * The default sprite batch size.\n *\n * The default aims to balance desktop and mobile devices.\n *\n * @static\n * @name SPRITE_BATCH_SIZE\n * @memberof PIXI.settings\n * @type {number}\n * @default 4096\n */\n SPRITE_BATCH_SIZE: 4096,\n /**\n * The default render options if none are supplied to {@link PIXI.Renderer}\n * or {@link PIXI.CanvasRenderer}.\n *\n * @static\n * @name RENDER_OPTIONS\n * @memberof PIXI.settings\n * @type {object}\n * @property {HTMLCanvasElement} view=null\n * @property {boolean} antialias=false\n * @property {boolean} autoDensity=false\n * @property {boolean} useContextAlpha=true\n * @property {number} backgroundColor=0x000000\n * @property {number} backgroundAlpha=1\n * @property {boolean} clearBeforeRender=true\n * @property {boolean} preserveDrawingBuffer=false\n * @property {number} width=800\n * @property {number} height=600\n * @property {boolean} legacy=false\n */\n RENDER_OPTIONS: {\n view: null,\n antialias: false,\n autoDensity: false,\n backgroundColor: 0x000000,\n backgroundAlpha: 1,\n useContextAlpha: true,\n clearBeforeRender: true,\n preserveDrawingBuffer: false,\n width: 800,\n height: 600,\n legacy: false,\n },\n /**\n * Default Garbage Collection mode.\n *\n * @static\n * @name GC_MODE\n * @memberof PIXI.settings\n * @type {PIXI.GC_MODES}\n * @default PIXI.GC_MODES.AUTO\n */\n GC_MODE: GC_MODES.AUTO,\n /**\n * Default Garbage Collection max idle.\n *\n * @static\n * @name GC_MAX_IDLE\n * @memberof PIXI.settings\n * @type {number}\n * @default 3600\n */\n GC_MAX_IDLE: 60 * 60,\n /**\n * Default Garbage Collection maximum check count.\n *\n * @static\n * @name GC_MAX_CHECK_COUNT\n * @memberof PIXI.settings\n * @type {number}\n * @default 600\n */\n GC_MAX_CHECK_COUNT: 60 * 10,\n /**\n * Default wrap modes that are supported by pixi.\n *\n * @static\n * @name WRAP_MODE\n * @memberof PIXI.settings\n * @type {PIXI.WRAP_MODES}\n * @default PIXI.WRAP_MODES.CLAMP\n */\n WRAP_MODE: WRAP_MODES.CLAMP,\n /**\n * Default scale mode for textures.\n *\n * @static\n * @name SCALE_MODE\n * @memberof PIXI.settings\n * @type {PIXI.SCALE_MODES}\n * @default PIXI.SCALE_MODES.LINEAR\n */\n SCALE_MODE: SCALE_MODES.LINEAR,\n /**\n * Default specify float precision in vertex shader.\n *\n * @static\n * @name PRECISION_VERTEX\n * @memberof PIXI.settings\n * @type {PIXI.PRECISION}\n * @default PIXI.PRECISION.HIGH\n */\n PRECISION_VERTEX: PRECISION.HIGH,\n /**\n * Default specify float precision in fragment shader.\n * iOS is best set at highp due to https://github.com/pixijs/pixi.js/issues/3742\n *\n * @static\n * @name PRECISION_FRAGMENT\n * @memberof PIXI.settings\n * @type {PIXI.PRECISION}\n * @default PIXI.PRECISION.MEDIUM\n */\n PRECISION_FRAGMENT: isMobile.apple.device ? PRECISION.HIGH : PRECISION.MEDIUM,\n /**\n * Can we upload the same buffer in a single frame?\n *\n * @static\n * @name CAN_UPLOAD_SAME_BUFFER\n * @memberof PIXI.settings\n * @type {boolean}\n */\n CAN_UPLOAD_SAME_BUFFER: canUploadSameBuffer(),\n /**\n * Enables bitmap creation before image load. This feature is experimental.\n *\n * @static\n * @name CREATE_IMAGE_BITMAP\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\n CREATE_IMAGE_BITMAP: false,\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n *\n * @static\n * @constant\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\n ROUND_PIXELS: false,\n};\n\nexport { isMobile, settings };\n//# sourceMappingURL=settings.js.map\n","/*!\n * @pixi/sprite - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/sprite is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { BLEND_MODES } from '@pixi/constants';\nimport { Texture } from '@pixi/core';\nimport { Bounds, Container } from '@pixi/display';\nimport { Point, Rectangle, ObservablePoint } from '@pixi/math';\nimport { settings } from '@pixi/settings';\nimport { sign } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar tempPoint = new Point();\nvar indices = new Uint16Array([0, 1, 2, 0, 2, 3]);\n/**\n * The Sprite object is the base for all textured objects that are rendered to the screen\n*\n * A sprite can be created directly from an image like this:\n *\n * ```js\n * let sprite = PIXI.Sprite.from('assets/image.png');\n * ```\n *\n * The more efficient way to create sprites is using a {@link PIXI.Spritesheet},\n * as swapping base textures when rendering to the screen is inefficient.\n *\n * ```js\n * PIXI.Loader.shared.add(\"assets/spritesheet.json\").load(setup);\n *\n * function setup() {\n * let sheet = PIXI.Loader.shared.resources[\"assets/spritesheet.json\"].spritesheet;\n * let sprite = new PIXI.Sprite(sheet.textures[\"image.png\"]);\n * ...\n * }\n * ```\n *\n * @memberof PIXI\n */\nvar Sprite = /** @class */ (function (_super) {\n __extends(Sprite, _super);\n /** @param texture - The texture for this sprite. */\n function Sprite(texture) {\n var _this = _super.call(this) || this;\n _this._anchor = new ObservablePoint(_this._onAnchorUpdate, _this, (texture ? texture.defaultAnchor.x : 0), (texture ? texture.defaultAnchor.y : 0));\n _this._texture = null;\n _this._width = 0;\n _this._height = 0;\n _this._tint = null;\n _this._tintRGB = null;\n _this.tint = 0xFFFFFF;\n _this.blendMode = BLEND_MODES.NORMAL;\n _this._cachedTint = 0xFFFFFF;\n _this.uvs = null;\n // call texture setter\n _this.texture = texture || Texture.EMPTY;\n _this.vertexData = new Float32Array(8);\n _this.vertexTrimmedData = null;\n _this._transformID = -1;\n _this._textureID = -1;\n _this._transformTrimmedID = -1;\n _this._textureTrimmedID = -1;\n // Batchable stuff..\n // TODO could make this a mixin?\n _this.indices = indices;\n _this.pluginName = 'batch';\n /**\n * Used to fast check if a sprite is.. a sprite!\n * @member {boolean}\n */\n _this.isSprite = true;\n _this._roundPixels = settings.ROUND_PIXELS;\n return _this;\n }\n /** When the texture is updated, this event will fire to update the scale and frame. */\n Sprite.prototype._onTextureUpdate = function () {\n this._textureID = -1;\n this._textureTrimmedID = -1;\n this._cachedTint = 0xFFFFFF;\n // so if _width is 0 then width was not set..\n if (this._width) {\n this.scale.x = sign(this.scale.x) * this._width / this._texture.orig.width;\n }\n if (this._height) {\n this.scale.y = sign(this.scale.y) * this._height / this._texture.orig.height;\n }\n };\n /** Called when the anchor position updates. */\n Sprite.prototype._onAnchorUpdate = function () {\n this._transformID = -1;\n this._transformTrimmedID = -1;\n };\n /** Calculates worldTransform * vertices, store it in vertexData. */\n Sprite.prototype.calculateVertices = function () {\n var texture = this._texture;\n if (this._transformID === this.transform._worldID && this._textureID === texture._updateID) {\n return;\n }\n // update texture UV here, because base texture can be changed without calling `_onTextureUpdate`\n if (this._textureID !== texture._updateID) {\n this.uvs = this._texture._uvs.uvsFloat32;\n }\n this._transformID = this.transform._worldID;\n this._textureID = texture._updateID;\n // set the vertex data\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var vertexData = this.vertexData;\n var trim = texture.trim;\n var orig = texture.orig;\n var anchor = this._anchor;\n var w0 = 0;\n var w1 = 0;\n var h0 = 0;\n var h1 = 0;\n if (trim) {\n // if the sprite is trimmed and is not a tilingsprite then we need to add the extra\n // space before transforming the sprite coords.\n w1 = trim.x - (anchor._x * orig.width);\n w0 = w1 + trim.width;\n h1 = trim.y - (anchor._y * orig.height);\n h0 = h1 + trim.height;\n }\n else {\n w1 = -anchor._x * orig.width;\n w0 = w1 + orig.width;\n h1 = -anchor._y * orig.height;\n h0 = h1 + orig.height;\n }\n // xy\n vertexData[0] = (a * w1) + (c * h1) + tx;\n vertexData[1] = (d * h1) + (b * w1) + ty;\n // xy\n vertexData[2] = (a * w0) + (c * h1) + tx;\n vertexData[3] = (d * h1) + (b * w0) + ty;\n // xy\n vertexData[4] = (a * w0) + (c * h0) + tx;\n vertexData[5] = (d * h0) + (b * w0) + ty;\n // xy\n vertexData[6] = (a * w1) + (c * h0) + tx;\n vertexData[7] = (d * h0) + (b * w1) + ty;\n if (this._roundPixels) {\n var resolution = settings.RESOLUTION;\n for (var i = 0; i < vertexData.length; ++i) {\n vertexData[i] = Math.round((vertexData[i] * resolution | 0) / resolution);\n }\n }\n };\n /**\n * Calculates worldTransform * vertices for a non texture with a trim. store it in vertexTrimmedData.\n *\n * This is used to ensure that the true width and height of a trimmed texture is respected.\n */\n Sprite.prototype.calculateTrimmedVertices = function () {\n if (!this.vertexTrimmedData) {\n this.vertexTrimmedData = new Float32Array(8);\n }\n else if (this._transformTrimmedID === this.transform._worldID && this._textureTrimmedID === this._texture._updateID) {\n return;\n }\n this._transformTrimmedID = this.transform._worldID;\n this._textureTrimmedID = this._texture._updateID;\n // lets do some special trim code!\n var texture = this._texture;\n var vertexData = this.vertexTrimmedData;\n var orig = texture.orig;\n var anchor = this._anchor;\n // lets calculate the new untrimmed bounds..\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var w1 = -anchor._x * orig.width;\n var w0 = w1 + orig.width;\n var h1 = -anchor._y * orig.height;\n var h0 = h1 + orig.height;\n // xy\n vertexData[0] = (a * w1) + (c * h1) + tx;\n vertexData[1] = (d * h1) + (b * w1) + ty;\n // xy\n vertexData[2] = (a * w0) + (c * h1) + tx;\n vertexData[3] = (d * h1) + (b * w0) + ty;\n // xy\n vertexData[4] = (a * w0) + (c * h0) + tx;\n vertexData[5] = (d * h0) + (b * w0) + ty;\n // xy\n vertexData[6] = (a * w1) + (c * h0) + tx;\n vertexData[7] = (d * h0) + (b * w1) + ty;\n };\n /**\n *\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The webgl renderer to use.\n */\n Sprite.prototype._render = function (renderer) {\n this.calculateVertices();\n renderer.batch.setObjectRenderer(renderer.plugins[this.pluginName]);\n renderer.plugins[this.pluginName].render(this);\n };\n /** Updates the bounds of the sprite. */\n Sprite.prototype._calculateBounds = function () {\n var trim = this._texture.trim;\n var orig = this._texture.orig;\n // First lets check to see if the current texture has a trim..\n if (!trim || (trim.width === orig.width && trim.height === orig.height)) {\n // no trim! lets use the usual calculations..\n this.calculateVertices();\n this._bounds.addQuad(this.vertexData);\n }\n else {\n // lets calculate a special trimmed bounds...\n this.calculateTrimmedVertices();\n this._bounds.addQuad(this.vertexTrimmedData);\n }\n };\n /**\n * Gets the local bounds of the sprite object.\n *\n * @param rect - Optional output rectangle.\n * @return The bounds.\n */\n Sprite.prototype.getLocalBounds = function (rect) {\n // we can do a fast local bounds if the sprite has no children!\n if (this.children.length === 0) {\n if (!this._localBounds) {\n this._localBounds = new Bounds();\n }\n this._localBounds.minX = this._texture.orig.width * -this._anchor._x;\n this._localBounds.minY = this._texture.orig.height * -this._anchor._y;\n this._localBounds.maxX = this._texture.orig.width * (1 - this._anchor._x);\n this._localBounds.maxY = this._texture.orig.height * (1 - this._anchor._y);\n if (!rect) {\n if (!this._localBoundsRect) {\n this._localBoundsRect = new Rectangle();\n }\n rect = this._localBoundsRect;\n }\n return this._localBounds.getRectangle(rect);\n }\n return _super.prototype.getLocalBounds.call(this, rect);\n };\n /**\n * Tests if a point is inside this sprite\n *\n * @param point - the point to test\n * @return The result of the test\n */\n Sprite.prototype.containsPoint = function (point) {\n this.worldTransform.applyInverse(point, tempPoint);\n var width = this._texture.orig.width;\n var height = this._texture.orig.height;\n var x1 = -width * this.anchor.x;\n var y1 = 0;\n if (tempPoint.x >= x1 && tempPoint.x < x1 + width) {\n y1 = -height * this.anchor.y;\n if (tempPoint.y >= y1 && tempPoint.y < y1 + height) {\n return true;\n }\n }\n return false;\n };\n /**\n * Destroys this sprite and optionally its texture and children.\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param [options.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param [options.texture=false] - Should it destroy the current texture of the sprite as well\n * @param [options.baseTexture=false] - Should it destroy the base texture of the sprite as well\n */\n Sprite.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n this._texture.off('update', this._onTextureUpdate, this);\n this._anchor = null;\n var destroyTexture = typeof options === 'boolean' ? options : options && options.texture;\n if (destroyTexture) {\n var destroyBaseTexture = typeof options === 'boolean' ? options : options && options.baseTexture;\n this._texture.destroy(!!destroyBaseTexture);\n }\n this._texture = null;\n };\n // some helper functions..\n /**\n * Helper function that creates a new sprite based on the source you provide.\n * The source can be - frame id, image url, video url, canvas element, video element, base texture\n *\n * @param {string|PIXI.Texture|HTMLCanvasElement|HTMLVideoElement} source - Source to create texture from\n * @param {object} [options] - See {@link PIXI.BaseTexture}'s constructor for options.\n * @return The newly created sprite\n */\n Sprite.from = function (source, options) {\n var texture = (source instanceof Texture)\n ? source\n : Texture.from(source, options);\n return new Sprite(texture);\n };\n Object.defineProperty(Sprite.prototype, \"roundPixels\", {\n get: function () {\n return this._roundPixels;\n },\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n *\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n *\n * To set the global default, change {@link PIXI.settings.ROUND_PIXELS}.\n *\n * @default false\n */\n set: function (value) {\n if (this._roundPixels !== value) {\n this._transformID = -1;\n }\n this._roundPixels = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"width\", {\n /** The width of the sprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return Math.abs(this.scale.x) * this._texture.orig.width;\n },\n set: function (value) {\n var s = sign(this.scale.x) || 1;\n this.scale.x = s * value / this._texture.orig.width;\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"height\", {\n /** The height of the sprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return Math.abs(this.scale.y) * this._texture.orig.height;\n },\n set: function (value) {\n var s = sign(this.scale.y) || 1;\n this.scale.y = s * value / this._texture.orig.height;\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"anchor\", {\n /**\n * The anchor sets the origin point of the sprite. The default value is taken from the {@link PIXI.Texture|Texture}\n * and passed to the constructor.\n *\n * The default is `(0,0)`, this means the sprite's origin is the top left.\n *\n * Setting the anchor to `(0.5,0.5)` means the sprite's origin is centered.\n *\n * Setting the anchor to `(1,1)` would mean the sprite's origin point will be the bottom right corner.\n *\n * If you pass only single parameter, it will set both x and y to the same value as shown in the example below.\n *\n * @example\n * const sprite = new PIXI.Sprite(texture);\n * sprite.anchor.set(0.5); // This will set the origin to center. (0.5) is same as (0.5, 0.5).\n */\n get: function () {\n return this._anchor;\n },\n set: function (value) {\n this._anchor.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"tint\", {\n /**\n * The tint applied to the sprite. This is a hex value.\n *\n * A value of 0xFFFFFF will remove any tint effect.\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n this._tint = value;\n this._tintRGB = (value >> 16) + (value & 0xff00) + ((value & 0xff) << 16);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"texture\", {\n /** The texture that the sprite is using. */\n get: function () {\n return this._texture;\n },\n set: function (value) {\n if (this._texture === value) {\n return;\n }\n if (this._texture) {\n this._texture.off('update', this._onTextureUpdate, this);\n }\n this._texture = value || Texture.EMPTY;\n this._cachedTint = 0xFFFFFF;\n this._textureID = -1;\n this._textureTrimmedID = -1;\n if (value) {\n // wait for the texture to load\n if (value.baseTexture.valid) {\n this._onTextureUpdate();\n }\n else {\n value.once('update', this._onTextureUpdate, this);\n }\n }\n },\n enumerable: false,\n configurable: true\n });\n return Sprite;\n}(Container));\n\nexport { Sprite };\n//# sourceMappingURL=sprite.js.map\n","/*!\n * @pixi/ticker - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/ticker is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\n\n/**\n * Target frames per millisecond.\n *\n * @static\n * @name TARGET_FPMS\n * @memberof PIXI.settings\n * @type {number}\n * @default 0.06\n */\nsettings.TARGET_FPMS = 0.06;\n\n/**\n * Represents the update priorities used by internal PIXI classes when registered with\n * the {@link PIXI.Ticker} object. Higher priority items are updated first and lower\n * priority items, such as render, should go later.\n *\n * @static\n * @constant\n * @name UPDATE_PRIORITY\n * @memberof PIXI\n * @enum {number}\n * @property {number} INTERACTION=50 Highest priority, used for {@link PIXI.InteractionManager}\n * @property {number} HIGH=25 High priority updating, {@link PIXI.VideoBaseTexture} and {@link PIXI.AnimatedSprite}\n * @property {number} NORMAL=0 Default priority for ticker events, see {@link PIXI.Ticker#add}.\n * @property {number} LOW=-25 Low priority used for {@link PIXI.Application} rendering.\n * @property {number} UTILITY=-50 Lowest priority used for {@link PIXI.BasePrepare} utility.\n */\nvar UPDATE_PRIORITY;\n(function (UPDATE_PRIORITY) {\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"INTERACTION\"] = 50] = \"INTERACTION\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"HIGH\"] = 25] = \"HIGH\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"NORMAL\"] = 0] = \"NORMAL\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"LOW\"] = -25] = \"LOW\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"UTILITY\"] = -50] = \"UTILITY\";\n})(UPDATE_PRIORITY || (UPDATE_PRIORITY = {}));\n\n/**\n * Internal class for handling the priority sorting of ticker handlers.\n *\n * @private\n * @class\n * @memberof PIXI\n */\nvar TickerListener = /** @class */ (function () {\n /**\n * Constructor\n * @private\n * @param fn - The listener function to be added for one update\n * @param context - The listener context\n * @param priority - The priority for emitting\n * @param once - If the handler should fire once\n */\n function TickerListener(fn, context, priority, once) {\n if (context === void 0) { context = null; }\n if (priority === void 0) { priority = 0; }\n if (once === void 0) { once = false; }\n /** The next item in chain. */\n this.next = null;\n /** The previous item in chain. */\n this.previous = null;\n /** `true` if this listener has been destroyed already. */\n this._destroyed = false;\n this.fn = fn;\n this.context = context;\n this.priority = priority;\n this.once = once;\n }\n /**\n * Simple compare function to figure out if a function and context match.\n * @private\n * @param fn - The listener function to be added for one update\n * @param context - The listener context\n * @return `true` if the listener match the arguments\n */\n TickerListener.prototype.match = function (fn, context) {\n if (context === void 0) { context = null; }\n return this.fn === fn && this.context === context;\n };\n /**\n * Emit by calling the current function.\n * @private\n * @param deltaTime - time since the last emit.\n * @return Next ticker\n */\n TickerListener.prototype.emit = function (deltaTime) {\n if (this.fn) {\n if (this.context) {\n this.fn.call(this.context, deltaTime);\n }\n else {\n this.fn(deltaTime);\n }\n }\n var redirect = this.next;\n if (this.once) {\n this.destroy(true);\n }\n // Soft-destroying should remove\n // the next reference\n if (this._destroyed) {\n this.next = null;\n }\n return redirect;\n };\n /**\n * Connect to the list.\n * @private\n * @param previous - Input node, previous listener\n */\n TickerListener.prototype.connect = function (previous) {\n this.previous = previous;\n if (previous.next) {\n previous.next.previous = this;\n }\n this.next = previous.next;\n previous.next = this;\n };\n /**\n * Destroy and don't use after this.\n * @private\n * @param hard - `true` to remove the `next` reference, this\n * is considered a hard destroy. Soft destroy maintains the next reference.\n * @return The listener to redirect while emitting or removing.\n */\n TickerListener.prototype.destroy = function (hard) {\n if (hard === void 0) { hard = false; }\n this._destroyed = true;\n this.fn = null;\n this.context = null;\n // Disconnect, hook up next and previous\n if (this.previous) {\n this.previous.next = this.next;\n }\n if (this.next) {\n this.next.previous = this.previous;\n }\n // Redirect to the next item\n var redirect = this.next;\n // Remove references\n this.next = hard ? null : redirect;\n this.previous = null;\n return redirect;\n };\n return TickerListener;\n}());\n\n/**\n * A Ticker class that runs an update loop that other objects listen to.\n *\n * This class is composed around listeners meant for execution on the next requested animation frame.\n * Animation frames are requested only when necessary, e.g. When the ticker is started and the emitter has listeners.\n *\n * @class\n * @memberof PIXI\n */\nvar Ticker = /** @class */ (function () {\n function Ticker() {\n var _this = this;\n /**\n * Whether or not this ticker should invoke the method\n * {@link PIXI.Ticker#start} automatically\n * when a listener is added.\n */\n this.autoStart = false;\n /**\n * Scalar time value from last frame to this frame.\n * This value is capped by setting {@link PIXI.Ticker#minFPS}\n * and is scaled with {@link PIXI.Ticker#speed}.\n * **Note:** The cap may be exceeded by scaling.\n */\n this.deltaTime = 1;\n /**\n * The last time {@link PIXI.Ticker#update} was invoked.\n * This value is also reset internally outside of invoking\n * update, but only when a new animation frame is requested.\n * If the platform supports DOMHighResTimeStamp,\n * this value will have a precision of 1 µs.\n */\n this.lastTime = -1;\n /**\n * Factor of current {@link PIXI.Ticker#deltaTime}.\n * @example\n * // Scales ticker.deltaTime to what would be\n * // the equivalent of approximately 120 FPS\n * ticker.speed = 2;\n */\n this.speed = 1;\n /**\n * Whether or not this ticker has been started.\n * `true` if {@link PIXI.Ticker#start} has been called.\n * `false` if {@link PIXI.Ticker#stop} has been called.\n * While `false`, this value may change to `true` in the\n * event of {@link PIXI.Ticker#autoStart} being `true`\n * and a listener is added.\n */\n this.started = false;\n /** Internal current frame request ID */\n this._requestId = null;\n /**\n * Internal value managed by minFPS property setter and getter.\n * This is the maximum allowed milliseconds between updates.\n */\n this._maxElapsedMS = 100;\n /**\n * Internal value managed by minFPS property setter and getter.\n * This is the minimum allowed milliseconds between updates.\n */\n this._minElapsedMS = 0;\n /** If enabled, deleting is disabled.*/\n this._protected = false;\n /**\n * The last time keyframe was executed.\n * Maintains a relatively fixed interval with the previous value.\n */\n this._lastFrame = -1;\n this._head = new TickerListener(null, null, Infinity);\n this.deltaMS = 1 / settings.TARGET_FPMS;\n this.elapsedMS = 1 / settings.TARGET_FPMS;\n this._tick = function (time) {\n _this._requestId = null;\n if (_this.started) {\n // Invoke listeners now\n _this.update(time);\n // Listener side effects may have modified ticker state.\n if (_this.started && _this._requestId === null && _this._head.next) {\n _this._requestId = requestAnimationFrame(_this._tick);\n }\n }\n };\n }\n /**\n * Conditionally requests a new animation frame.\n * If a frame has not already been requested, and if the internal\n * emitter has listeners, a new frame is requested.\n *\n * @private\n */\n Ticker.prototype._requestIfNeeded = function () {\n if (this._requestId === null && this._head.next) {\n // ensure callbacks get correct delta\n this.lastTime = performance.now();\n this._lastFrame = this.lastTime;\n this._requestId = requestAnimationFrame(this._tick);\n }\n };\n /**\n * Conditionally cancels a pending animation frame.\n * @private\n */\n Ticker.prototype._cancelIfNeeded = function () {\n if (this._requestId !== null) {\n cancelAnimationFrame(this._requestId);\n this._requestId = null;\n }\n };\n /**\n * Conditionally requests a new animation frame.\n * If the ticker has been started it checks if a frame has not already\n * been requested, and if the internal emitter has listeners. If these\n * conditions are met, a new frame is requested. If the ticker has not\n * been started, but autoStart is `true`, then the ticker starts now,\n * and continues with the previous conditions to request a new frame.\n *\n * @private\n */\n Ticker.prototype._startIfPossible = function () {\n if (this.started) {\n this._requestIfNeeded();\n }\n else if (this.autoStart) {\n this.start();\n }\n };\n /**\n * Register a handler for tick events. Calls continuously unless\n * it is removed or the ticker is stopped.\n *\n * @param fn - The listener function to be added for updates\n * @param context - The listener context\n * @param {number} [priority=PIXI.UPDATE_PRIORITY.NORMAL] - The priority for emitting\n * @returns This instance of a ticker\n */\n Ticker.prototype.add = function (fn, context, priority) {\n if (priority === void 0) { priority = UPDATE_PRIORITY.NORMAL; }\n return this._addListener(new TickerListener(fn, context, priority));\n };\n /**\n * Add a handler for the tick event which is only execute once.\n *\n * @param fn - The listener function to be added for one update\n * @param context - The listener context\n * @param {number} [priority=PIXI.UPDATE_PRIORITY.NORMAL] - The priority for emitting\n * @returns This instance of a ticker\n */\n Ticker.prototype.addOnce = function (fn, context, priority) {\n if (priority === void 0) { priority = UPDATE_PRIORITY.NORMAL; }\n return this._addListener(new TickerListener(fn, context, priority, true));\n };\n /**\n * Internally adds the event handler so that it can be sorted by priority.\n * Priority allows certain handler (user, AnimatedSprite, Interaction) to be run\n * before the rendering.\n *\n * @private\n * @param listener - Current listener being added.\n * @returns This instance of a ticker\n */\n Ticker.prototype._addListener = function (listener) {\n // For attaching to head\n var current = this._head.next;\n var previous = this._head;\n // Add the first item\n if (!current) {\n listener.connect(previous);\n }\n else {\n // Go from highest to lowest priority\n while (current) {\n if (listener.priority > current.priority) {\n listener.connect(previous);\n break;\n }\n previous = current;\n current = current.next;\n }\n // Not yet connected\n if (!listener.previous) {\n listener.connect(previous);\n }\n }\n this._startIfPossible();\n return this;\n };\n /**\n * Removes any handlers matching the function and context parameters.\n * If no handlers are left after removing, then it cancels the animation frame.\n *\n * @param fn - The listener function to be removed\n * @param context - The listener context to be removed\n * @returns This instance of a ticker\n */\n Ticker.prototype.remove = function (fn, context) {\n var listener = this._head.next;\n while (listener) {\n // We found a match, lets remove it\n // no break to delete all possible matches\n // incase a listener was added 2+ times\n if (listener.match(fn, context)) {\n listener = listener.destroy();\n }\n else {\n listener = listener.next;\n }\n }\n if (!this._head.next) {\n this._cancelIfNeeded();\n }\n return this;\n };\n Object.defineProperty(Ticker.prototype, \"count\", {\n /**\n * The number of listeners on this ticker, calculated by walking through linked list\n *\n * @readonly\n * @member {number}\n */\n get: function () {\n if (!this._head) {\n return 0;\n }\n var count = 0;\n var current = this._head;\n while ((current = current.next)) {\n count++;\n }\n return count;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Starts the ticker. If the ticker has listeners\n * a new animation frame is requested at this point.\n */\n Ticker.prototype.start = function () {\n if (!this.started) {\n this.started = true;\n this._requestIfNeeded();\n }\n };\n /**\n * Stops the ticker. If the ticker has requested\n * an animation frame it is canceled at this point.\n */\n Ticker.prototype.stop = function () {\n if (this.started) {\n this.started = false;\n this._cancelIfNeeded();\n }\n };\n /**\n * Destroy the ticker and don't use after this. Calling\n * this method removes all references to internal events.\n */\n Ticker.prototype.destroy = function () {\n if (!this._protected) {\n this.stop();\n var listener = this._head.next;\n while (listener) {\n listener = listener.destroy(true);\n }\n this._head.destroy();\n this._head = null;\n }\n };\n /**\n * Triggers an update. An update entails setting the\n * current {@link PIXI.Ticker#elapsedMS},\n * the current {@link PIXI.Ticker#deltaTime},\n * invoking all listeners with current deltaTime,\n * and then finally setting {@link PIXI.Ticker#lastTime}\n * with the value of currentTime that was provided.\n * This method will be called automatically by animation\n * frame callbacks if the ticker instance has been started\n * and listeners are added.\n *\n * @param {number} [currentTime=performance.now()] - the current time of execution\n */\n Ticker.prototype.update = function (currentTime) {\n if (currentTime === void 0) { currentTime = performance.now(); }\n var elapsedMS;\n // If the difference in time is zero or negative, we ignore most of the work done here.\n // If there is no valid difference, then should be no reason to let anyone know about it.\n // A zero delta, is exactly that, nothing should update.\n //\n // The difference in time can be negative, and no this does not mean time traveling.\n // This can be the result of a race condition between when an animation frame is requested\n // on the current JavaScript engine event loop, and when the ticker's start method is invoked\n // (which invokes the internal _requestIfNeeded method). If a frame is requested before\n // _requestIfNeeded is invoked, then the callback for the animation frame the ticker requests,\n // can receive a time argument that can be less than the lastTime value that was set within\n // _requestIfNeeded. This difference is in microseconds, but this is enough to cause problems.\n //\n // This check covers this browser engine timing issue, as well as if consumers pass an invalid\n // currentTime value. This may happen if consumers opt-out of the autoStart, and update themselves.\n if (currentTime > this.lastTime) {\n // Save uncapped elapsedMS for measurement\n elapsedMS = this.elapsedMS = currentTime - this.lastTime;\n // cap the milliseconds elapsed used for deltaTime\n if (elapsedMS > this._maxElapsedMS) {\n elapsedMS = this._maxElapsedMS;\n }\n elapsedMS *= this.speed;\n // If not enough time has passed, exit the function.\n // Get ready for next frame by setting _lastFrame, but based on _minElapsedMS\n // adjustment to ensure a relatively stable interval.\n if (this._minElapsedMS) {\n var delta = currentTime - this._lastFrame | 0;\n if (delta < this._minElapsedMS) {\n return;\n }\n this._lastFrame = currentTime - (delta % this._minElapsedMS);\n }\n this.deltaMS = elapsedMS;\n this.deltaTime = this.deltaMS * settings.TARGET_FPMS;\n // Cache a local reference, in-case ticker is destroyed\n // during the emit, we can still check for head.next\n var head = this._head;\n // Invoke listeners added to internal emitter\n var listener = head.next;\n while (listener) {\n listener = listener.emit(this.deltaTime);\n }\n if (!head.next) {\n this._cancelIfNeeded();\n }\n }\n else {\n this.deltaTime = this.deltaMS = this.elapsedMS = 0;\n }\n this.lastTime = currentTime;\n };\n Object.defineProperty(Ticker.prototype, \"FPS\", {\n /**\n * The frames per second at which this ticker is running.\n * The default is approximately 60 in most modern browsers.\n * **Note:** This does not factor in the value of\n * {@link PIXI.Ticker#speed}, which is specific\n * to scaling {@link PIXI.Ticker#deltaTime}.\n *\n * @member {number}\n * @readonly\n */\n get: function () {\n return 1000 / this.elapsedMS;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker.prototype, \"minFPS\", {\n /**\n * Manages the maximum amount of milliseconds allowed to\n * elapse between invoking {@link PIXI.Ticker#update}.\n * This value is used to cap {@link PIXI.Ticker#deltaTime},\n * but does not effect the measured value of {@link PIXI.Ticker#FPS}.\n * When setting this property it is clamped to a value between\n * `0` and `PIXI.settings.TARGET_FPMS * 1000`.\n *\n * @member {number}\n * @default 10\n */\n get: function () {\n return 1000 / this._maxElapsedMS;\n },\n set: function (fps) {\n // Minimum must be below the maxFPS\n var minFPS = Math.min(this.maxFPS, fps);\n // Must be at least 0, but below 1 / settings.TARGET_FPMS\n var minFPMS = Math.min(Math.max(0, minFPS) / 1000, settings.TARGET_FPMS);\n this._maxElapsedMS = 1 / minFPMS;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker.prototype, \"maxFPS\", {\n /**\n * Manages the minimum amount of milliseconds required to\n * elapse between invoking {@link PIXI.Ticker#update}.\n * This will effect the measured value of {@link PIXI.Ticker#FPS}.\n * If it is set to `0`, then there is no limit; PixiJS will render as many frames as it can.\n * Otherwise it will be at least `minFPS`\n *\n * @member {number}\n * @default 0\n */\n get: function () {\n if (this._minElapsedMS) {\n return Math.round(1000 / this._minElapsedMS);\n }\n return 0;\n },\n set: function (fps) {\n if (fps === 0) {\n this._minElapsedMS = 0;\n }\n else {\n // Max must be at least the minFPS\n var maxFPS = Math.max(this.minFPS, fps);\n this._minElapsedMS = 1 / (maxFPS / 1000);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker, \"shared\", {\n /**\n * The shared ticker instance used by {@link PIXI.AnimatedSprite} and by\n * {@link PIXI.VideoResource} to update animation frames / video textures.\n *\n * It may also be used by {@link PIXI.Application} if created with the `sharedTicker` option property set to true.\n *\n * The property {@link PIXI.Ticker#autoStart} is set to `true` for this instance.\n * Please follow the examples for usage, including how to opt-out of auto-starting the shared ticker.\n *\n * @example\n * let ticker = PIXI.Ticker.shared;\n * // Set this to prevent starting this ticker when listeners are added.\n * // By default this is true only for the PIXI.Ticker.shared instance.\n * ticker.autoStart = false;\n * // FYI, call this to ensure the ticker is stopped. It should be stopped\n * // if you have not attempted to render anything yet.\n * ticker.stop();\n * // Call this when you are ready for a running shared ticker.\n * ticker.start();\n *\n * @example\n * // You may use the shared ticker to render...\n * let renderer = PIXI.autoDetectRenderer();\n * let stage = new PIXI.Container();\n * document.body.appendChild(renderer.view);\n * ticker.add(function (time) {\n * renderer.render(stage);\n * });\n *\n * @example\n * // Or you can just update it manually.\n * ticker.autoStart = false;\n * ticker.stop();\n * function animate(time) {\n * ticker.update(time);\n * renderer.render(stage);\n * requestAnimationFrame(animate);\n * }\n * animate(performance.now());\n *\n * @member {PIXI.Ticker}\n * @static\n */\n get: function () {\n if (!Ticker._shared) {\n var shared = Ticker._shared = new Ticker();\n shared.autoStart = true;\n shared._protected = true;\n }\n return Ticker._shared;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker, \"system\", {\n /**\n * The system ticker instance used by {@link PIXI.InteractionManager} and by\n * {@link PIXI.BasePrepare} for core timing functionality that shouldn't usually need to be paused,\n * unlike the `shared` ticker which drives visual animations and rendering which may want to be paused.\n *\n * The property {@link PIXI.Ticker#autoStart} is set to `true` for this instance.\n *\n * @member {PIXI.Ticker}\n * @static\n */\n get: function () {\n if (!Ticker._system) {\n var system = Ticker._system = new Ticker();\n system.autoStart = true;\n system._protected = true;\n }\n return Ticker._system;\n },\n enumerable: false,\n configurable: true\n });\n return Ticker;\n}());\n\n/**\n * Middleware for for Application Ticker.\n *\n * @example\n * import {TickerPlugin} from '@pixi/ticker';\n * import {Application} from '@pixi/app';\n * Application.registerPlugin(TickerPlugin);\n *\n * @class\n * @memberof PIXI\n */\nvar TickerPlugin = /** @class */ (function () {\n function TickerPlugin() {\n }\n /**\n * Initialize the plugin with scope of application instance\n *\n * @static\n * @private\n * @param {object} [options] - See application options\n */\n TickerPlugin.init = function (options) {\n var _this = this;\n // Set default\n options = Object.assign({\n autoStart: true,\n sharedTicker: false,\n }, options);\n // Create ticker setter\n Object.defineProperty(this, 'ticker', {\n set: function (ticker) {\n if (this._ticker) {\n this._ticker.remove(this.render, this);\n }\n this._ticker = ticker;\n if (ticker) {\n ticker.add(this.render, this, UPDATE_PRIORITY.LOW);\n }\n },\n get: function () {\n return this._ticker;\n },\n });\n /**\n * Convenience method for stopping the render.\n *\n * @method\n * @memberof PIXI.Application\n * @instance\n */\n this.stop = function () {\n _this._ticker.stop();\n };\n /**\n * Convenience method for starting the render.\n *\n * @method\n * @memberof PIXI.Application\n * @instance\n */\n this.start = function () {\n _this._ticker.start();\n };\n /**\n * Internal reference to the ticker.\n *\n * @type {PIXI.Ticker}\n * @name _ticker\n * @memberof PIXI.Application#\n * @private\n */\n this._ticker = null;\n /**\n * Ticker for doing render updates.\n *\n * @type {PIXI.Ticker}\n * @name ticker\n * @memberof PIXI.Application#\n * @default PIXI.Ticker.shared\n */\n this.ticker = options.sharedTicker ? Ticker.shared : new Ticker();\n // Start the rendering\n if (options.autoStart) {\n this.start();\n }\n };\n /**\n * Clean up the ticker, scoped to application.\n *\n * @static\n * @private\n */\n TickerPlugin.destroy = function () {\n if (this._ticker) {\n var oldTicker = this._ticker;\n this.ticker = null;\n oldTicker.destroy();\n }\n };\n return TickerPlugin;\n}());\n\nexport { Ticker, TickerPlugin, UPDATE_PRIORITY };\n//# sourceMappingURL=ticker.js.map\n","/*!\n * @pixi/utils - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/utils is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nexport { isMobile } from '@pixi/settings';\nexport { default as EventEmitter } from 'eventemitter3';\nexport { default as earcut } from 'earcut';\nimport { parse, format, resolve } from 'url';\nimport { BLEND_MODES } from '@pixi/constants';\n\n/**\n * This file contains redeclared types for Node `url` and `querystring` modules. These modules\n * don't provide their own typings but instead are a part of the full Node typings. The purpose of\n * this file is to redeclare the required types to avoid having the whole Node types as a\n * dependency.\n */\nvar url = {\n parse: parse,\n format: format,\n resolve: resolve,\n};\n\n/**\n * The prefix that denotes a URL is for a retina asset.\n *\n * @static\n * @name RETINA_PREFIX\n * @memberof PIXI.settings\n * @type {RegExp}\n * @default /@([0-9\\.]+)x/\n * @example `@2x`\n */\nsettings.RETINA_PREFIX = /@([0-9\\.]+)x/;\n/**\n * Should the `failIfMajorPerformanceCaveat` flag be enabled as a context option used in the `isWebGLSupported` function.\n * If set to true, a WebGL renderer can fail to be created if the browser thinks there could be performance issues when\n * using WebGL.\n *\n * In PixiJS v6 this has changed from true to false by default, to allow WebGL to work in as many scenarios as possible.\n * However, some users may have a poor experience, for example, if a user has a gpu or driver version blacklisted by the\n * browser.\n *\n * If your application requires high performance rendering, you may wish to set this to false.\n * We recommend one of two options if you decide to set this flag to false:\n *\n * 1: Use the `pixi.js-legacy` package, which includes a Canvas renderer as a fallback in case high performance WebGL is\n * not supported.\n *\n * 2: Call `isWebGLSupported` (which if found in the PIXI.utils package) in your code before attempting to create a PixiJS\n * renderer, and show an error message to the user if the function returns false, explaining that their device & browser\n * combination does not support high performance WebGL.\n * This is a much better strategy than trying to create a PixiJS renderer and finding it then fails.\n *\n * @static\n * @name FAIL_IF_MAJOR_PERFORMANCE_CAVEAT\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\nsettings.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT = false;\n\nvar saidHello = false;\nvar VERSION = '6.3.0';\n/**\n * Skips the hello message of renderers that are created after this is run.\n *\n * @function skipHello\n * @memberof PIXI.utils\n */\nfunction skipHello() {\n saidHello = true;\n}\n/**\n * Logs out the version and renderer information for this running instance of PIXI.\n * If you don't want to see this message you can run `PIXI.utils.skipHello()` before\n * creating your renderer. Keep in mind that doing that will forever make you a jerk face.\n *\n * @static\n * @function sayHello\n * @memberof PIXI.utils\n * @param {string} type - The string renderer type to log.\n */\nfunction sayHello(type) {\n var _a;\n if (saidHello) {\n return;\n }\n if (navigator.userAgent.toLowerCase().indexOf('chrome') > -1) {\n var args = [\n \"\\n %c %c %c PixiJS \" + VERSION + \" - \\u2730 \" + type + \" \\u2730 %c %c http://www.pixijs.com/ %c %c \\u2665%c\\u2665%c\\u2665 \\n\\n\",\n 'background: #ff66a5; padding:5px 0;',\n 'background: #ff66a5; padding:5px 0;',\n 'color: #ff66a5; background: #030307; padding:5px 0;',\n 'background: #ff66a5; padding:5px 0;',\n 'background: #ffc3dc; padding:5px 0;',\n 'background: #ff66a5; padding:5px 0;',\n 'color: #ff2424; background: #fff; padding:5px 0;',\n 'color: #ff2424; background: #fff; padding:5px 0;',\n 'color: #ff2424; background: #fff; padding:5px 0;' ];\n (_a = globalThis.console).log.apply(_a, args);\n }\n else if (globalThis.console) {\n globalThis.console.log(\"PixiJS \" + VERSION + \" - \" + type + \" - http://www.pixijs.com/\");\n }\n saidHello = true;\n}\n\nvar supported;\n/**\n * Helper for checking for WebGL support.\n *\n * @memberof PIXI.utils\n * @function isWebGLSupported\n * @return {boolean} Is WebGL supported.\n */\nfunction isWebGLSupported() {\n if (typeof supported === 'undefined') {\n supported = (function supported() {\n var contextOptions = {\n stencil: true,\n failIfMajorPerformanceCaveat: settings.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT,\n };\n try {\n if (!globalThis.WebGLRenderingContext) {\n return false;\n }\n var canvas = document.createElement('canvas');\n var gl = (canvas.getContext('webgl', contextOptions)\n || canvas.getContext('experimental-webgl', contextOptions));\n var success = !!(gl && gl.getContextAttributes().stencil);\n if (gl) {\n var loseContext = gl.getExtension('WEBGL_lose_context');\n if (loseContext) {\n loseContext.loseContext();\n }\n }\n gl = null;\n return success;\n }\n catch (e) {\n return false;\n }\n })();\n }\n return supported;\n}\n\nvar aliceblue = \"#f0f8ff\";\nvar antiquewhite = \"#faebd7\";\nvar aqua = \"#00ffff\";\nvar aquamarine = \"#7fffd4\";\nvar azure = \"#f0ffff\";\nvar beige = \"#f5f5dc\";\nvar bisque = \"#ffe4c4\";\nvar black = \"#000000\";\nvar blanchedalmond = \"#ffebcd\";\nvar blue = \"#0000ff\";\nvar blueviolet = \"#8a2be2\";\nvar brown = \"#a52a2a\";\nvar burlywood = \"#deb887\";\nvar cadetblue = \"#5f9ea0\";\nvar chartreuse = \"#7fff00\";\nvar chocolate = \"#d2691e\";\nvar coral = \"#ff7f50\";\nvar cornflowerblue = \"#6495ed\";\nvar cornsilk = \"#fff8dc\";\nvar crimson = \"#dc143c\";\nvar cyan = \"#00ffff\";\nvar darkblue = \"#00008b\";\nvar darkcyan = \"#008b8b\";\nvar darkgoldenrod = \"#b8860b\";\nvar darkgray = \"#a9a9a9\";\nvar darkgreen = \"#006400\";\nvar darkgrey = \"#a9a9a9\";\nvar darkkhaki = \"#bdb76b\";\nvar darkmagenta = \"#8b008b\";\nvar darkolivegreen = \"#556b2f\";\nvar darkorange = \"#ff8c00\";\nvar darkorchid = \"#9932cc\";\nvar darkred = \"#8b0000\";\nvar darksalmon = \"#e9967a\";\nvar darkseagreen = \"#8fbc8f\";\nvar darkslateblue = \"#483d8b\";\nvar darkslategray = \"#2f4f4f\";\nvar darkslategrey = \"#2f4f4f\";\nvar darkturquoise = \"#00ced1\";\nvar darkviolet = \"#9400d3\";\nvar deeppink = \"#ff1493\";\nvar deepskyblue = \"#00bfff\";\nvar dimgray = \"#696969\";\nvar dimgrey = \"#696969\";\nvar dodgerblue = \"#1e90ff\";\nvar firebrick = \"#b22222\";\nvar floralwhite = \"#fffaf0\";\nvar forestgreen = \"#228b22\";\nvar fuchsia = \"#ff00ff\";\nvar gainsboro = \"#dcdcdc\";\nvar ghostwhite = \"#f8f8ff\";\nvar goldenrod = \"#daa520\";\nvar gold = \"#ffd700\";\nvar gray = \"#808080\";\nvar green = \"#008000\";\nvar greenyellow = \"#adff2f\";\nvar grey = \"#808080\";\nvar honeydew = \"#f0fff0\";\nvar hotpink = \"#ff69b4\";\nvar indianred = \"#cd5c5c\";\nvar indigo = \"#4b0082\";\nvar ivory = \"#fffff0\";\nvar khaki = \"#f0e68c\";\nvar lavenderblush = \"#fff0f5\";\nvar lavender = \"#e6e6fa\";\nvar lawngreen = \"#7cfc00\";\nvar lemonchiffon = \"#fffacd\";\nvar lightblue = \"#add8e6\";\nvar lightcoral = \"#f08080\";\nvar lightcyan = \"#e0ffff\";\nvar lightgoldenrodyellow = \"#fafad2\";\nvar lightgray = \"#d3d3d3\";\nvar lightgreen = \"#90ee90\";\nvar lightgrey = \"#d3d3d3\";\nvar lightpink = \"#ffb6c1\";\nvar lightsalmon = \"#ffa07a\";\nvar lightseagreen = \"#20b2aa\";\nvar lightskyblue = \"#87cefa\";\nvar lightslategray = \"#778899\";\nvar lightslategrey = \"#778899\";\nvar lightsteelblue = \"#b0c4de\";\nvar lightyellow = \"#ffffe0\";\nvar lime = \"#00ff00\";\nvar limegreen = \"#32cd32\";\nvar linen = \"#faf0e6\";\nvar magenta = \"#ff00ff\";\nvar maroon = \"#800000\";\nvar mediumaquamarine = \"#66cdaa\";\nvar mediumblue = \"#0000cd\";\nvar mediumorchid = \"#ba55d3\";\nvar mediumpurple = \"#9370db\";\nvar mediumseagreen = \"#3cb371\";\nvar mediumslateblue = \"#7b68ee\";\nvar mediumspringgreen = \"#00fa9a\";\nvar mediumturquoise = \"#48d1cc\";\nvar mediumvioletred = \"#c71585\";\nvar midnightblue = \"#191970\";\nvar mintcream = \"#f5fffa\";\nvar mistyrose = \"#ffe4e1\";\nvar moccasin = \"#ffe4b5\";\nvar navajowhite = \"#ffdead\";\nvar navy = \"#000080\";\nvar oldlace = \"#fdf5e6\";\nvar olive = \"#808000\";\nvar olivedrab = \"#6b8e23\";\nvar orange = \"#ffa500\";\nvar orangered = \"#ff4500\";\nvar orchid = \"#da70d6\";\nvar palegoldenrod = \"#eee8aa\";\nvar palegreen = \"#98fb98\";\nvar paleturquoise = \"#afeeee\";\nvar palevioletred = \"#db7093\";\nvar papayawhip = \"#ffefd5\";\nvar peachpuff = \"#ffdab9\";\nvar peru = \"#cd853f\";\nvar pink = \"#ffc0cb\";\nvar plum = \"#dda0dd\";\nvar powderblue = \"#b0e0e6\";\nvar purple = \"#800080\";\nvar rebeccapurple = \"#663399\";\nvar red = \"#ff0000\";\nvar rosybrown = \"#bc8f8f\";\nvar royalblue = \"#4169e1\";\nvar saddlebrown = \"#8b4513\";\nvar salmon = \"#fa8072\";\nvar sandybrown = \"#f4a460\";\nvar seagreen = \"#2e8b57\";\nvar seashell = \"#fff5ee\";\nvar sienna = \"#a0522d\";\nvar silver = \"#c0c0c0\";\nvar skyblue = \"#87ceeb\";\nvar slateblue = \"#6a5acd\";\nvar slategray = \"#708090\";\nvar slategrey = \"#708090\";\nvar snow = \"#fffafa\";\nvar springgreen = \"#00ff7f\";\nvar steelblue = \"#4682b4\";\nvar tan = \"#d2b48c\";\nvar teal = \"#008080\";\nvar thistle = \"#d8bfd8\";\nvar tomato = \"#ff6347\";\nvar turquoise = \"#40e0d0\";\nvar violet = \"#ee82ee\";\nvar wheat = \"#f5deb3\";\nvar white = \"#ffffff\";\nvar whitesmoke = \"#f5f5f5\";\nvar yellow = \"#ffff00\";\nvar yellowgreen = \"#9acd32\";\nvar cssColorNames = {\n\taliceblue: aliceblue,\n\tantiquewhite: antiquewhite,\n\taqua: aqua,\n\taquamarine: aquamarine,\n\tazure: azure,\n\tbeige: beige,\n\tbisque: bisque,\n\tblack: black,\n\tblanchedalmond: blanchedalmond,\n\tblue: blue,\n\tblueviolet: blueviolet,\n\tbrown: brown,\n\tburlywood: burlywood,\n\tcadetblue: cadetblue,\n\tchartreuse: chartreuse,\n\tchocolate: chocolate,\n\tcoral: coral,\n\tcornflowerblue: cornflowerblue,\n\tcornsilk: cornsilk,\n\tcrimson: crimson,\n\tcyan: cyan,\n\tdarkblue: darkblue,\n\tdarkcyan: darkcyan,\n\tdarkgoldenrod: darkgoldenrod,\n\tdarkgray: darkgray,\n\tdarkgreen: darkgreen,\n\tdarkgrey: darkgrey,\n\tdarkkhaki: darkkhaki,\n\tdarkmagenta: darkmagenta,\n\tdarkolivegreen: darkolivegreen,\n\tdarkorange: darkorange,\n\tdarkorchid: darkorchid,\n\tdarkred: darkred,\n\tdarksalmon: darksalmon,\n\tdarkseagreen: darkseagreen,\n\tdarkslateblue: darkslateblue,\n\tdarkslategray: darkslategray,\n\tdarkslategrey: darkslategrey,\n\tdarkturquoise: darkturquoise,\n\tdarkviolet: darkviolet,\n\tdeeppink: deeppink,\n\tdeepskyblue: deepskyblue,\n\tdimgray: dimgray,\n\tdimgrey: dimgrey,\n\tdodgerblue: dodgerblue,\n\tfirebrick: firebrick,\n\tfloralwhite: floralwhite,\n\tforestgreen: forestgreen,\n\tfuchsia: fuchsia,\n\tgainsboro: gainsboro,\n\tghostwhite: ghostwhite,\n\tgoldenrod: goldenrod,\n\tgold: gold,\n\tgray: gray,\n\tgreen: green,\n\tgreenyellow: greenyellow,\n\tgrey: grey,\n\thoneydew: honeydew,\n\thotpink: hotpink,\n\tindianred: indianred,\n\tindigo: indigo,\n\tivory: ivory,\n\tkhaki: khaki,\n\tlavenderblush: lavenderblush,\n\tlavender: lavender,\n\tlawngreen: lawngreen,\n\tlemonchiffon: lemonchiffon,\n\tlightblue: lightblue,\n\tlightcoral: lightcoral,\n\tlightcyan: lightcyan,\n\tlightgoldenrodyellow: lightgoldenrodyellow,\n\tlightgray: lightgray,\n\tlightgreen: lightgreen,\n\tlightgrey: lightgrey,\n\tlightpink: lightpink,\n\tlightsalmon: lightsalmon,\n\tlightseagreen: lightseagreen,\n\tlightskyblue: lightskyblue,\n\tlightslategray: lightslategray,\n\tlightslategrey: lightslategrey,\n\tlightsteelblue: lightsteelblue,\n\tlightyellow: lightyellow,\n\tlime: lime,\n\tlimegreen: limegreen,\n\tlinen: linen,\n\tmagenta: magenta,\n\tmaroon: maroon,\n\tmediumaquamarine: mediumaquamarine,\n\tmediumblue: mediumblue,\n\tmediumorchid: mediumorchid,\n\tmediumpurple: mediumpurple,\n\tmediumseagreen: mediumseagreen,\n\tmediumslateblue: mediumslateblue,\n\tmediumspringgreen: mediumspringgreen,\n\tmediumturquoise: mediumturquoise,\n\tmediumvioletred: mediumvioletred,\n\tmidnightblue: midnightblue,\n\tmintcream: mintcream,\n\tmistyrose: mistyrose,\n\tmoccasin: moccasin,\n\tnavajowhite: navajowhite,\n\tnavy: navy,\n\toldlace: oldlace,\n\tolive: olive,\n\tolivedrab: olivedrab,\n\torange: orange,\n\torangered: orangered,\n\torchid: orchid,\n\tpalegoldenrod: palegoldenrod,\n\tpalegreen: palegreen,\n\tpaleturquoise: paleturquoise,\n\tpalevioletred: palevioletred,\n\tpapayawhip: papayawhip,\n\tpeachpuff: peachpuff,\n\tperu: peru,\n\tpink: pink,\n\tplum: plum,\n\tpowderblue: powderblue,\n\tpurple: purple,\n\trebeccapurple: rebeccapurple,\n\tred: red,\n\trosybrown: rosybrown,\n\troyalblue: royalblue,\n\tsaddlebrown: saddlebrown,\n\tsalmon: salmon,\n\tsandybrown: sandybrown,\n\tseagreen: seagreen,\n\tseashell: seashell,\n\tsienna: sienna,\n\tsilver: silver,\n\tskyblue: skyblue,\n\tslateblue: slateblue,\n\tslategray: slategray,\n\tslategrey: slategrey,\n\tsnow: snow,\n\tspringgreen: springgreen,\n\tsteelblue: steelblue,\n\ttan: tan,\n\tteal: teal,\n\tthistle: thistle,\n\ttomato: tomato,\n\tturquoise: turquoise,\n\tviolet: violet,\n\twheat: wheat,\n\twhite: white,\n\twhitesmoke: whitesmoke,\n\tyellow: yellow,\n\tyellowgreen: yellowgreen\n};\n\n/**\n * Converts a hexadecimal color number to an [R, G, B] array of normalized floats (numbers from 0.0 to 1.0).\n *\n * @example\n * PIXI.utils.hex2rgb(0xffffff); // returns [1, 1, 1]\n * @memberof PIXI.utils\n * @function hex2rgb\n * @param {number} hex - The hexadecimal number to convert\n * @param {number[]} [out=[]] - If supplied, this array will be used rather than returning a new one\n * @return {number[]} An array representing the [R, G, B] of the color where all values are floats.\n */\nfunction hex2rgb(hex, out) {\n if (out === void 0) { out = []; }\n out[0] = ((hex >> 16) & 0xFF) / 255;\n out[1] = ((hex >> 8) & 0xFF) / 255;\n out[2] = (hex & 0xFF) / 255;\n return out;\n}\n/**\n * Converts a hexadecimal color number to a string.\n *\n * @example\n * PIXI.utils.hex2string(0xffffff); // returns \"#ffffff\"\n * @memberof PIXI.utils\n * @function hex2string\n * @param {number} hex - Number in hex (e.g., `0xffffff`)\n * @return {string} The string color (e.g., `\"#ffffff\"`).\n */\nfunction hex2string(hex) {\n var hexString = hex.toString(16);\n hexString = '000000'.substring(0, 6 - hexString.length) + hexString;\n return \"#\" + hexString;\n}\n/**\n * Converts a string to a hexadecimal color number.\n * It can handle:\n * hex strings starting with #: \"#ffffff\"\n * hex strings starting with 0x: \"0xffffff\"\n * hex strings without prefix: \"ffffff\"\n * css colors: \"black\"\n *\n * @example\n * PIXI.utils.string2hex(\"#ffffff\"); // returns 0xffffff\n * @memberof PIXI.utils\n * @function string2hex\n * @param {string} string - The string color (e.g., `\"#ffffff\"`)\n * @return {number} Number in hexadecimal.\n */\nfunction string2hex(string) {\n if (typeof string === 'string') {\n string = cssColorNames[string.toLowerCase()] || string;\n if (string[0] === '#') {\n string = string.slice(1);\n }\n }\n return parseInt(string, 16);\n}\n/**\n * Converts a color as an [R, G, B] array of normalized floats to a hexadecimal number.\n *\n * @example\n * PIXI.utils.rgb2hex([1, 1, 1]); // returns 0xffffff\n * @memberof PIXI.utils\n * @function rgb2hex\n * @param {number[]} rgb - Array of numbers where all values are normalized floats from 0.0 to 1.0.\n * @return {number} Number in hexadecimal.\n */\nfunction rgb2hex(rgb) {\n return (((rgb[0] * 255) << 16) + ((rgb[1] * 255) << 8) + (rgb[2] * 255 | 0));\n}\n\n/**\n * Corrects PixiJS blend, takes premultiplied alpha into account\n *\n * @memberof PIXI.utils\n * @function mapPremultipliedBlendModes\n * @private\n * @return {Array<number[]>} Mapped modes.\n */\nfunction mapPremultipliedBlendModes() {\n var pm = [];\n var npm = [];\n for (var i = 0; i < 32; i++) {\n pm[i] = i;\n npm[i] = i;\n }\n pm[BLEND_MODES.NORMAL_NPM] = BLEND_MODES.NORMAL;\n pm[BLEND_MODES.ADD_NPM] = BLEND_MODES.ADD;\n pm[BLEND_MODES.SCREEN_NPM] = BLEND_MODES.SCREEN;\n npm[BLEND_MODES.NORMAL] = BLEND_MODES.NORMAL_NPM;\n npm[BLEND_MODES.ADD] = BLEND_MODES.ADD_NPM;\n npm[BLEND_MODES.SCREEN] = BLEND_MODES.SCREEN_NPM;\n var array = [];\n array.push(npm);\n array.push(pm);\n return array;\n}\n/**\n * maps premultiply flag and blendMode to adjusted blendMode\n * @memberof PIXI.utils\n * @const premultiplyBlendMode\n * @type {Array<number[]>}\n */\nvar premultiplyBlendMode = mapPremultipliedBlendModes();\n/**\n * changes blendMode according to texture format\n *\n * @memberof PIXI.utils\n * @function correctBlendMode\n * @param {number} blendMode - supposed blend mode\n * @param {boolean} premultiplied - whether source is premultiplied\n * @returns {number} true blend mode for this texture\n */\nfunction correctBlendMode(blendMode, premultiplied) {\n return premultiplyBlendMode[premultiplied ? 1 : 0][blendMode];\n}\n/**\n * combines rgb and alpha to out array\n *\n * @memberof PIXI.utils\n * @function premultiplyRgba\n * @param {Float32Array|number[]} rgb - input rgb\n * @param {number} alpha - alpha param\n * @param {Float32Array} [out] - output\n * @param {boolean} [premultiply=true] - do premultiply it\n * @returns {Float32Array} vec4 rgba\n */\nfunction premultiplyRgba(rgb, alpha, out, premultiply) {\n out = out || new Float32Array(4);\n if (premultiply || premultiply === undefined) {\n out[0] = rgb[0] * alpha;\n out[1] = rgb[1] * alpha;\n out[2] = rgb[2] * alpha;\n }\n else {\n out[0] = rgb[0];\n out[1] = rgb[1];\n out[2] = rgb[2];\n }\n out[3] = alpha;\n return out;\n}\n/**\n * premultiplies tint\n *\n * @memberof PIXI.utils\n * @function premultiplyTint\n * @param {number} tint - integer RGB\n * @param {number} alpha - floating point alpha (0.0-1.0)\n * @returns {number} tint multiplied by alpha\n */\nfunction premultiplyTint(tint, alpha) {\n if (alpha === 1.0) {\n return (alpha * 255 << 24) + tint;\n }\n if (alpha === 0.0) {\n return 0;\n }\n var R = ((tint >> 16) & 0xFF);\n var G = ((tint >> 8) & 0xFF);\n var B = (tint & 0xFF);\n R = ((R * alpha) + 0.5) | 0;\n G = ((G * alpha) + 0.5) | 0;\n B = ((B * alpha) + 0.5) | 0;\n return (alpha * 255 << 24) + (R << 16) + (G << 8) + B;\n}\n/**\n * converts integer tint and float alpha to vec4 form, premultiplies by default\n *\n * @memberof PIXI.utils\n * @function premultiplyTintToRgba\n * @param {number} tint - input tint\n * @param {number} alpha - alpha param\n * @param {Float32Array} [out] - output\n * @param {boolean} [premultiply=true] - do premultiply it\n * @returns {Float32Array} vec4 rgba\n */\nfunction premultiplyTintToRgba(tint, alpha, out, premultiply) {\n out = out || new Float32Array(4);\n out[0] = ((tint >> 16) & 0xFF) / 255.0;\n out[1] = ((tint >> 8) & 0xFF) / 255.0;\n out[2] = (tint & 0xFF) / 255.0;\n if (premultiply || premultiply === undefined) {\n out[0] *= alpha;\n out[1] *= alpha;\n out[2] *= alpha;\n }\n out[3] = alpha;\n return out;\n}\n\n/**\n * Generic Mask Stack data structure\n *\n * @memberof PIXI.utils\n * @function createIndicesForQuads\n * @param {number} size - Number of quads\n * @param {Uint16Array|Uint32Array} [outBuffer] - Buffer for output, length has to be `6 * size`\n * @return {Uint16Array|Uint32Array} - Resulting index buffer\n */\nfunction createIndicesForQuads(size, outBuffer) {\n if (outBuffer === void 0) { outBuffer = null; }\n // the total number of indices in our array, there are 6 points per quad.\n var totalIndices = size * 6;\n outBuffer = outBuffer || new Uint16Array(totalIndices);\n if (outBuffer.length !== totalIndices) {\n throw new Error(\"Out buffer length is incorrect, got \" + outBuffer.length + \" and expected \" + totalIndices);\n }\n // fill the indices with the quads to draw\n for (var i = 0, j = 0; i < totalIndices; i += 6, j += 4) {\n outBuffer[i + 0] = j + 0;\n outBuffer[i + 1] = j + 1;\n outBuffer[i + 2] = j + 2;\n outBuffer[i + 3] = j + 0;\n outBuffer[i + 4] = j + 2;\n outBuffer[i + 5] = j + 3;\n }\n return outBuffer;\n}\n\nfunction getBufferType(array) {\n if (array.BYTES_PER_ELEMENT === 4) {\n if (array instanceof Float32Array) {\n return 'Float32Array';\n }\n else if (array instanceof Uint32Array) {\n return 'Uint32Array';\n }\n return 'Int32Array';\n }\n else if (array.BYTES_PER_ELEMENT === 2) {\n if (array instanceof Uint16Array) {\n return 'Uint16Array';\n }\n }\n else if (array.BYTES_PER_ELEMENT === 1) {\n if (array instanceof Uint8Array) {\n return 'Uint8Array';\n }\n }\n // TODO map out the rest of the array elements!\n return null;\n}\n\n/* eslint-disable object-shorthand */\nvar map = { Float32Array: Float32Array, Uint32Array: Uint32Array, Int32Array: Int32Array, Uint8Array: Uint8Array };\nfunction interleaveTypedArrays(arrays, sizes) {\n var outSize = 0;\n var stride = 0;\n var views = {};\n for (var i = 0; i < arrays.length; i++) {\n stride += sizes[i];\n outSize += arrays[i].length;\n }\n var buffer = new ArrayBuffer(outSize * 4);\n var out = null;\n var littleOffset = 0;\n for (var i = 0; i < arrays.length; i++) {\n var size = sizes[i];\n var array = arrays[i];\n /*\n @todo This is unsafe casting but consistent with how the code worked previously. Should it stay this way\n or should and `getBufferTypeUnsafe` function be exposed that throws an Error if unsupported type is passed?\n */\n var type = getBufferType(array);\n if (!views[type]) {\n views[type] = new map[type](buffer);\n }\n out = views[type];\n for (var j = 0; j < array.length; j++) {\n var indexStart = ((j / size | 0) * stride) + littleOffset;\n var index = j % size;\n out[indexStart + index] = array[j];\n }\n littleOffset += size;\n }\n return new Float32Array(buffer);\n}\n\n// Taken from the bit-twiddle package\n/**\n * Rounds to next power of two.\n *\n * @function nextPow2\n * @memberof PIXI.utils\n * @param {number} v - input value\n * @return {number}\n */\nfunction nextPow2(v) {\n v += v === 0 ? 1 : 0;\n --v;\n v |= v >>> 1;\n v |= v >>> 2;\n v |= v >>> 4;\n v |= v >>> 8;\n v |= v >>> 16;\n return v + 1;\n}\n/**\n * Checks if a number is a power of two.\n *\n * @function isPow2\n * @memberof PIXI.utils\n * @param {number} v - input value\n * @return {boolean} `true` if value is power of two\n */\nfunction isPow2(v) {\n return !(v & (v - 1)) && (!!v);\n}\n/**\n * Computes ceil of log base 2\n *\n * @function log2\n * @memberof PIXI.utils\n * @param {number} v - input value\n * @return {number} logarithm base 2\n */\nfunction log2(v) {\n var r = (v > 0xFFFF ? 1 : 0) << 4;\n v >>>= r;\n var shift = (v > 0xFF ? 1 : 0) << 3;\n v >>>= shift;\n r |= shift;\n shift = (v > 0xF ? 1 : 0) << 2;\n v >>>= shift;\n r |= shift;\n shift = (v > 0x3 ? 1 : 0) << 1;\n v >>>= shift;\n r |= shift;\n return r | (v >> 1);\n}\n\n/**\n * Remove items from a javascript array without generating garbage\n *\n * @function removeItems\n * @memberof PIXI.utils\n * @param {Array<any>} arr - Array to remove elements from\n * @param {number} startIdx - starting index\n * @param {number} removeCount - how many to remove\n */\nfunction removeItems(arr, startIdx, removeCount) {\n var length = arr.length;\n var i;\n if (startIdx >= length || removeCount === 0) {\n return;\n }\n removeCount = (startIdx + removeCount > length ? length - startIdx : removeCount);\n var len = length - removeCount;\n for (i = startIdx; i < len; ++i) {\n arr[i] = arr[i + removeCount];\n }\n arr.length = len;\n}\n\n/**\n * Returns sign of number\n *\n * @memberof PIXI.utils\n * @function sign\n * @param {number} n - the number to check the sign of\n * @returns {number} 0 if `n` is 0, -1 if `n` is negative, 1 if `n` is positive\n */\nfunction sign(n) {\n if (n === 0)\n { return 0; }\n return n < 0 ? -1 : 1;\n}\n\nvar nextUid = 0;\n/**\n * Gets the next unique identifier\n *\n * @memberof PIXI.utils\n * @function uid\n * @return {number} The next unique identifier to use.\n */\nfunction uid() {\n return ++nextUid;\n}\n\n// A map of warning messages already fired\nvar warnings = {};\n/**\n * Helper for warning developers about deprecated features & settings.\n * A stack track for warnings is given; useful for tracking-down where\n * deprecated methods/properties/classes are being used within the code.\n *\n * @memberof PIXI.utils\n * @function deprecation\n * @param {string} version - The version where the feature became deprecated\n * @param {string} message - Message should include what is deprecated, where, and the new solution\n * @param {number} [ignoreDepth=3] - The number of steps to ignore at the top of the error stack\n * this is mostly to ignore internal deprecation calls.\n */\nfunction deprecation(version, message, ignoreDepth) {\n if (ignoreDepth === void 0) { ignoreDepth = 3; }\n // Ignore duplicat\n if (warnings[message]) {\n return;\n }\n /* eslint-disable no-console */\n var stack = new Error().stack;\n // Handle IE < 10 and Safari < 6\n if (typeof stack === 'undefined') {\n console.warn('PixiJS Deprecation Warning: ', message + \"\\nDeprecated since v\" + version);\n }\n else {\n // chop off the stack trace which includes PixiJS internal calls\n stack = stack.split('\\n').splice(ignoreDepth).join('\\n');\n if (console.groupCollapsed) {\n console.groupCollapsed('%cPixiJS Deprecation Warning: %c%s', 'color:#614108;background:#fffbe6', 'font-weight:normal;color:#614108;background:#fffbe6', message + \"\\nDeprecated since v\" + version);\n console.warn(stack);\n console.groupEnd();\n }\n else {\n console.warn('PixiJS Deprecation Warning: ', message + \"\\nDeprecated since v\" + version);\n console.warn(stack);\n }\n }\n /* eslint-enable no-console */\n warnings[message] = true;\n}\n\n/**\n * @todo Describe property usage\n *\n * @static\n * @name ProgramCache\n * @memberof PIXI.utils\n * @type {Object}\n */\nvar ProgramCache = {};\n/**\n * @todo Describe property usage\n *\n * @static\n * @name TextureCache\n * @memberof PIXI.utils\n * @type {Object}\n */\nvar TextureCache = Object.create(null);\n/**\n * @todo Describe property usage\n *\n * @static\n * @name BaseTextureCache\n * @memberof PIXI.utils\n * @type {Object}\n */\nvar BaseTextureCache = Object.create(null);\n/**\n * Destroys all texture in the cache\n *\n * @memberof PIXI.utils\n * @function destroyTextureCache\n */\nfunction destroyTextureCache() {\n var key;\n for (key in TextureCache) {\n TextureCache[key].destroy();\n }\n for (key in BaseTextureCache) {\n BaseTextureCache[key].destroy();\n }\n}\n/**\n * Removes all textures from cache, but does not destroy them\n *\n * @memberof PIXI.utils\n * @function clearTextureCache\n */\nfunction clearTextureCache() {\n var key;\n for (key in TextureCache) {\n delete TextureCache[key];\n }\n for (key in BaseTextureCache) {\n delete BaseTextureCache[key];\n }\n}\n\n/**\n * Creates a Canvas element of the given size to be used as a target for rendering to.\n *\n * @class\n * @memberof PIXI.utils\n */\nvar CanvasRenderTarget = /** @class */ (function () {\n /**\n * @param width - the width for the newly created canvas\n * @param height - the height for the newly created canvas\n * @param {number} [resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the canvas\n */\n function CanvasRenderTarget(width, height, resolution) {\n this.canvas = document.createElement('canvas');\n this.context = this.canvas.getContext('2d');\n this.resolution = resolution || settings.RESOLUTION;\n this.resize(width, height);\n }\n /**\n * Clears the canvas that was created by the CanvasRenderTarget class.\n *\n * @private\n */\n CanvasRenderTarget.prototype.clear = function () {\n this.context.setTransform(1, 0, 0, 1, 0, 0);\n this.context.clearRect(0, 0, this.canvas.width, this.canvas.height);\n };\n /**\n * Resizes the canvas to the specified width and height.\n *\n * @param desiredWidth - the desired width of the canvas\n * @param desiredHeight - the desired height of the canvas\n */\n CanvasRenderTarget.prototype.resize = function (desiredWidth, desiredHeight) {\n this.canvas.width = Math.round(desiredWidth * this.resolution);\n this.canvas.height = Math.round(desiredHeight * this.resolution);\n };\n /** Destroys this canvas. */\n CanvasRenderTarget.prototype.destroy = function () {\n this.context = null;\n this.canvas = null;\n };\n Object.defineProperty(CanvasRenderTarget.prototype, \"width\", {\n /**\n * The width of the canvas buffer in pixels.\n *\n * @member {number}\n */\n get: function () {\n return this.canvas.width;\n },\n set: function (val) {\n this.canvas.width = Math.round(val);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(CanvasRenderTarget.prototype, \"height\", {\n /**\n * The height of the canvas buffer in pixels.\n *\n * @member {number}\n */\n get: function () {\n return this.canvas.height;\n },\n set: function (val) {\n this.canvas.height = Math.round(val);\n },\n enumerable: false,\n configurable: true\n });\n return CanvasRenderTarget;\n}());\n\n/**\n * Trim transparent borders from a canvas\n *\n * @memberof PIXI.utils\n * @function trimCanvas\n * @param {HTMLCanvasElement} canvas - the canvas to trim\n * @returns {object} Trim data\n */\nfunction trimCanvas(canvas) {\n // https://gist.github.com/remy/784508\n var width = canvas.width;\n var height = canvas.height;\n var context = canvas.getContext('2d');\n var imageData = context.getImageData(0, 0, width, height);\n var pixels = imageData.data;\n var len = pixels.length;\n var bound = {\n top: null,\n left: null,\n right: null,\n bottom: null,\n };\n var data = null;\n var i;\n var x;\n var y;\n for (i = 0; i < len; i += 4) {\n if (pixels[i + 3] !== 0) {\n x = (i / 4) % width;\n y = ~~((i / 4) / width);\n if (bound.top === null) {\n bound.top = y;\n }\n if (bound.left === null) {\n bound.left = x;\n }\n else if (x < bound.left) {\n bound.left = x;\n }\n if (bound.right === null) {\n bound.right = x + 1;\n }\n else if (bound.right < x) {\n bound.right = x + 1;\n }\n if (bound.bottom === null) {\n bound.bottom = y;\n }\n else if (bound.bottom < y) {\n bound.bottom = y;\n }\n }\n }\n if (bound.top !== null) {\n width = bound.right - bound.left;\n height = bound.bottom - bound.top + 1;\n data = context.getImageData(bound.left, bound.top, width, height);\n }\n return {\n height: height,\n width: width,\n data: data,\n };\n}\n\n/**\n * Regexp for data URI.\n * Based on: {@link https://github.com/ragingwind/data-uri-regex}\n *\n * @static\n * @constant {RegExp|string} DATA_URI\n * @memberof PIXI\n * @example data:image/png;base64\n */\nvar DATA_URI = /^\\s*data:(?:([\\w-]+)\\/([\\w+.-]+))?(?:;charset=([\\w-]+))?(?:;(base64))?,(.*)/i;\n\n/**\n * @memberof PIXI.utils\n * @interface DecomposedDataUri\n */\n/**\n * type, eg. `image`\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} mediaType\n */\n/**\n * Sub type, eg. `png`\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} subType\n */\n/**\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} charset\n */\n/**\n * Data encoding, eg. `base64`\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} encoding\n */\n/**\n * The actual data\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} data\n */\n/**\n * Split a data URI into components. Returns undefined if\n * parameter `dataUri` is not a valid data URI.\n *\n * @memberof PIXI.utils\n * @function decomposeDataUri\n * @param {string} dataUri - the data URI to check\n * @return {PIXI.utils.DecomposedDataUri|undefined} The decomposed data uri or undefined\n */\nfunction decomposeDataUri(dataUri) {\n var dataUriMatch = DATA_URI.exec(dataUri);\n if (dataUriMatch) {\n return {\n mediaType: dataUriMatch[1] ? dataUriMatch[1].toLowerCase() : undefined,\n subType: dataUriMatch[2] ? dataUriMatch[2].toLowerCase() : undefined,\n charset: dataUriMatch[3] ? dataUriMatch[3].toLowerCase() : undefined,\n encoding: dataUriMatch[4] ? dataUriMatch[4].toLowerCase() : undefined,\n data: dataUriMatch[5],\n };\n }\n return undefined;\n}\n\nvar tempAnchor;\n/**\n * Sets the `crossOrigin` property for this resource based on if the url\n * for this resource is cross-origin. If crossOrigin was manually set, this\n * function does nothing.\n * Nipped from the resource loader!\n *\n * @ignore\n * @param {string} url - The url to test.\n * @param {object} [loc=window.location] - The location object to test against.\n * @return {string} The crossOrigin value to use (or empty string for none).\n */\nfunction determineCrossOrigin(url$1, loc) {\n if (loc === void 0) { loc = globalThis.location; }\n // data: and javascript: urls are considered same-origin\n if (url$1.indexOf('data:') === 0) {\n return '';\n }\n // default is window.location\n loc = loc || globalThis.location;\n if (!tempAnchor) {\n tempAnchor = document.createElement('a');\n }\n // let the browser determine the full href for the url of this resource and then\n // parse with the node url lib, we can't use the properties of the anchor element\n // because they don't work in IE9 :(\n tempAnchor.href = url$1;\n var parsedUrl = url.parse(tempAnchor.href);\n var samePort = (!parsedUrl.port && loc.port === '') || (parsedUrl.port === loc.port);\n // if cross origin\n if (parsedUrl.hostname !== loc.hostname || !samePort || parsedUrl.protocol !== loc.protocol) {\n return 'anonymous';\n }\n return '';\n}\n\n/**\n * get the resolution / device pixel ratio of an asset by looking for the prefix\n * used by spritesheets and image urls\n *\n * @memberof PIXI.utils\n * @function getResolutionOfUrl\n * @param {string} url - the image path\n * @param {number} [defaultValue=1] - the defaultValue if no filename prefix is set.\n * @return {number} resolution / device pixel ratio of an asset\n */\nfunction getResolutionOfUrl(url, defaultValue) {\n var resolution = settings.RETINA_PREFIX.exec(url);\n if (resolution) {\n return parseFloat(resolution[1]);\n }\n return defaultValue !== undefined ? defaultValue : 1;\n}\n\nexport { BaseTextureCache, CanvasRenderTarget, DATA_URI, ProgramCache, TextureCache, clearTextureCache, correctBlendMode, createIndicesForQuads, decomposeDataUri, deprecation, destroyTextureCache, determineCrossOrigin, getBufferType, getResolutionOfUrl, hex2rgb, hex2string, interleaveTypedArrays, isPow2, isWebGLSupported, log2, nextPow2, premultiplyBlendMode, premultiplyRgba, premultiplyTint, premultiplyTintToRgba, removeItems, rgb2hex, sayHello, sign, skipHello, string2hex, trimCanvas, uid, url };\n//# sourceMappingURL=utils.js.map\n","'use strict';\n\nvar has = Object.prototype.hasOwnProperty\n , prefix = '~';\n\n/**\n * Constructor to create a storage for our `EE` objects.\n * An `Events` instance is a plain object whose properties are event names.\n *\n * @constructor\n * @private\n */\nfunction Events() {}\n\n//\n// We try to not inherit from `Object.prototype`. In some engines creating an\n// instance in this way is faster than calling `Object.create(null)` directly.\n// If `Object.create(null)` is not supported we prefix the event names with a\n// character to make sure that the built-in object properties are not\n// overridden or used as an attack vector.\n//\nif (Object.create) {\n Events.prototype = Object.create(null);\n\n //\n // This hack is needed because the `__proto__` property is still inherited in\n // some old browsers like Android 4, iPhone 5.1, Opera 11 and Safari 5.\n //\n if (!new Events().__proto__) prefix = false;\n}\n\n/**\n * Representation of a single event listener.\n *\n * @param {Function} fn The listener function.\n * @param {*} context The context to invoke the listener with.\n * @param {Boolean} [once=false] Specify if the listener is a one-time listener.\n * @constructor\n * @private\n */\nfunction EE(fn, context, once) {\n this.fn = fn;\n this.context = context;\n this.once = once || false;\n}\n\n/**\n * Add a listener for a given event.\n *\n * @param {EventEmitter} emitter Reference to the `EventEmitter` instance.\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} context The context to invoke the listener with.\n * @param {Boolean} once Specify if the listener is a one-time listener.\n * @returns {EventEmitter}\n * @private\n */\nfunction addListener(emitter, event, fn, context, once) {\n if (typeof fn !== 'function') {\n throw new TypeError('The listener must be a function');\n }\n\n var listener = new EE(fn, context || emitter, once)\n , evt = prefix ? prefix + event : event;\n\n if (!emitter._events[evt]) emitter._events[evt] = listener, emitter._eventsCount++;\n else if (!emitter._events[evt].fn) emitter._events[evt].push(listener);\n else emitter._events[evt] = [emitter._events[evt], listener];\n\n return emitter;\n}\n\n/**\n * Clear event by name.\n *\n * @param {EventEmitter} emitter Reference to the `EventEmitter` instance.\n * @param {(String|Symbol)} evt The Event name.\n * @private\n */\nfunction clearEvent(emitter, evt) {\n if (--emitter._eventsCount === 0) emitter._events = new Events();\n else delete emitter._events[evt];\n}\n\n/**\n * Minimal `EventEmitter` interface that is molded against the Node.js\n * `EventEmitter` interface.\n *\n * @constructor\n * @public\n */\nfunction EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}\n\n/**\n * Return an array listing the events for which the emitter has registered\n * listeners.\n *\n * @returns {Array}\n * @public\n */\nEventEmitter.prototype.eventNames = function eventNames() {\n var names = []\n , events\n , name;\n\n if (this._eventsCount === 0) return names;\n\n for (name in (events = this._events)) {\n if (has.call(events, name)) names.push(prefix ? name.slice(1) : name);\n }\n\n if (Object.getOwnPropertySymbols) {\n return names.concat(Object.getOwnPropertySymbols(events));\n }\n\n return names;\n};\n\n/**\n * Return the listeners registered for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Array} The registered listeners.\n * @public\n */\nEventEmitter.prototype.listeners = function listeners(event) {\n var evt = prefix ? prefix + event : event\n , handlers = this._events[evt];\n\n if (!handlers) return [];\n if (handlers.fn) return [handlers.fn];\n\n for (var i = 0, l = handlers.length, ee = new Array(l); i < l; i++) {\n ee[i] = handlers[i].fn;\n }\n\n return ee;\n};\n\n/**\n * Return the number of listeners listening to a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Number} The number of listeners.\n * @public\n */\nEventEmitter.prototype.listenerCount = function listenerCount(event) {\n var evt = prefix ? prefix + event : event\n , listeners = this._events[evt];\n\n if (!listeners) return 0;\n if (listeners.fn) return 1;\n return listeners.length;\n};\n\n/**\n * Calls each of the listeners registered for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Boolean} `true` if the event had listeners, else `false`.\n * @public\n */\nEventEmitter.prototype.emit = function emit(event, a1, a2, a3, a4, a5) {\n var evt = prefix ? prefix + event : event;\n\n if (!this._events[evt]) return false;\n\n var listeners = this._events[evt]\n , len = arguments.length\n , args\n , i;\n\n if (listeners.fn) {\n if (listeners.once) this.removeListener(event, listeners.fn, undefined, true);\n\n switch (len) {\n case 1: return listeners.fn.call(listeners.context), true;\n case 2: return listeners.fn.call(listeners.context, a1), true;\n case 3: return listeners.fn.call(listeners.context, a1, a2), true;\n case 4: return listeners.fn.call(listeners.context, a1, a2, a3), true;\n case 5: return listeners.fn.call(listeners.context, a1, a2, a3, a4), true;\n case 6: return listeners.fn.call(listeners.context, a1, a2, a3, a4, a5), true;\n }\n\n for (i = 1, args = new Array(len -1); i < len; i++) {\n args[i - 1] = arguments[i];\n }\n\n listeners.fn.apply(listeners.context, args);\n } else {\n var length = listeners.length\n , j;\n\n for (i = 0; i < length; i++) {\n if (listeners[i].once) this.removeListener(event, listeners[i].fn, undefined, true);\n\n switch (len) {\n case 1: listeners[i].fn.call(listeners[i].context); break;\n case 2: listeners[i].fn.call(listeners[i].context, a1); break;\n case 3: listeners[i].fn.call(listeners[i].context, a1, a2); break;\n case 4: listeners[i].fn.call(listeners[i].context, a1, a2, a3); break;\n default:\n if (!args) for (j = 1, args = new Array(len -1); j < len; j++) {\n args[j - 1] = arguments[j];\n }\n\n listeners[i].fn.apply(listeners[i].context, args);\n }\n }\n }\n\n return true;\n};\n\n/**\n * Add a listener for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} [context=this] The context to invoke the listener with.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.on = function on(event, fn, context) {\n return addListener(this, event, fn, context, false);\n};\n\n/**\n * Add a one-time listener for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} [context=this] The context to invoke the listener with.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.once = function once(event, fn, context) {\n return addListener(this, event, fn, context, true);\n};\n\n/**\n * Remove the listeners of a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn Only remove the listeners that match this function.\n * @param {*} context Only remove the listeners that have this context.\n * @param {Boolean} once Only remove one-time listeners.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.removeListener = function removeListener(event, fn, context, once) {\n var evt = prefix ? prefix + event : event;\n\n if (!this._events[evt]) return this;\n if (!fn) {\n clearEvent(this, evt);\n return this;\n }\n\n var listeners = this._events[evt];\n\n if (listeners.fn) {\n if (\n listeners.fn === fn &&\n (!once || listeners.once) &&\n (!context || listeners.context === context)\n ) {\n clearEvent(this, evt);\n }\n } else {\n for (var i = 0, events = [], length = listeners.length; i < length; i++) {\n if (\n listeners[i].fn !== fn ||\n (once && !listeners[i].once) ||\n (context && listeners[i].context !== context)\n ) {\n events.push(listeners[i]);\n }\n }\n\n //\n // Reset the array, or remove it completely if we have no more listeners.\n //\n if (events.length) this._events[evt] = events.length === 1 ? events[0] : events;\n else clearEvent(this, evt);\n }\n\n return this;\n};\n\n/**\n * Remove all listeners, or those of the specified event.\n *\n * @param {(String|Symbol)} [event] The event name.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.removeAllListeners = function removeAllListeners(event) {\n var evt;\n\n if (event) {\n evt = prefix ? prefix + event : event;\n if (this._events[evt]) clearEvent(this, evt);\n } else {\n this._events = new Events();\n this._eventsCount = 0;\n }\n\n return this;\n};\n\n//\n// Alias methods names because people roll like that.\n//\nEventEmitter.prototype.off = EventEmitter.prototype.removeListener;\nEventEmitter.prototype.addListener = EventEmitter.prototype.on;\n\n//\n// Expose the prefix.\n//\nEventEmitter.prefixed = prefix;\n\n//\n// Allow `EventEmitter` to be imported as module namespace.\n//\nEventEmitter.EventEmitter = EventEmitter;\n\n//\n// Expose the module.\n//\nif ('undefined' !== typeof module) {\n module.exports = EventEmitter;\n}\n","/**\r\n * Make a map and return a function for checking if a key\r\n * is in that map.\r\n * IMPORTANT: all calls of this function must be prefixed with\r\n * \\/\\*#\\_\\_PURE\\_\\_\\*\\/\r\n * So that rollup can tree-shake them if necessary.\r\n */\r\nfunction makeMap(str, expectsLowerCase) {\r\n const map = Object.create(null);\r\n const list = str.split(',');\r\n for (let i = 0; i < list.length; i++) {\r\n map[list[i]] = true;\r\n }\r\n return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];\r\n}\n\n/**\r\n * dev only flag -> name mapping\r\n */\r\nconst PatchFlagNames = {\r\n [1 /* TEXT */]: `TEXT`,\r\n [2 /* CLASS */]: `CLASS`,\r\n [4 /* STYLE */]: `STYLE`,\r\n [8 /* PROPS */]: `PROPS`,\r\n [16 /* FULL_PROPS */]: `FULL_PROPS`,\r\n [32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,\r\n [64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,\r\n [128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,\r\n [256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,\r\n [512 /* NEED_PATCH */]: `NEED_PATCH`,\r\n [1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,\r\n [2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,\r\n [-1 /* HOISTED */]: `HOISTED`,\r\n [-2 /* BAIL */]: `BAIL`\r\n};\n\n/**\r\n * Dev only\r\n */\r\nconst slotFlagsText = {\r\n [1 /* STABLE */]: 'STABLE',\r\n [2 /* DYNAMIC */]: 'DYNAMIC',\r\n [3 /* FORWARDED */]: 'FORWARDED'\r\n};\n\nconst GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +\r\n 'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +\r\n 'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';\r\nconst isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);\n\nconst range = 2;\r\nfunction generateCodeFrame(source, start = 0, end = source.length) {\r\n // Split the content into individual lines but capture the newline sequence\r\n // that separated each line. This is important because the actual sequence is\r\n // needed to properly take into account the full line length for offset\r\n // comparison\r\n let lines = source.split(/(\\r?\\n)/);\r\n // Separate the lines and newline sequences into separate arrays for easier referencing\r\n const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);\r\n lines = lines.filter((_, idx) => idx % 2 === 0);\r\n let count = 0;\r\n const res = [];\r\n for (let i = 0; i < lines.length; i++) {\r\n count +=\r\n lines[i].length +\r\n ((newlineSequences[i] && newlineSequences[i].length) || 0);\r\n if (count >= start) {\r\n for (let j = i - range; j <= i + range || end > count; j++) {\r\n if (j < 0 || j >= lines.length)\r\n continue;\r\n const line = j + 1;\r\n res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);\r\n const lineLength = lines[j].length;\r\n const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;\r\n if (j === i) {\r\n // push underline\r\n const pad = start - (count - (lineLength + newLineSeqLength));\r\n const length = Math.max(1, end > count ? lineLength - pad : end - start);\r\n res.push(` | ` + ' '.repeat(pad) + '^'.repeat(length));\r\n }\r\n else if (j > i) {\r\n if (end > count) {\r\n const length = Math.max(Math.min(end - count, lineLength), 1);\r\n res.push(` | ` + '^'.repeat(length));\r\n }\r\n count += lineLength + newLineSeqLength;\r\n }\r\n }\r\n break;\r\n }\r\n }\r\n return res.join('\\n');\r\n}\n\n/**\r\n * On the client we only need to offer special cases for boolean attributes that\r\n * have different names from their corresponding dom properties:\r\n * - itemscope -> N/A\r\n * - allowfullscreen -> allowFullscreen\r\n * - formnovalidate -> formNoValidate\r\n * - ismap -> isMap\r\n * - nomodule -> noModule\r\n * - novalidate -> noValidate\r\n * - readonly -> readOnly\r\n */\r\nconst specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;\r\nconst isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);\r\n/**\r\n * The full list is needed during SSR to produce the correct initial markup.\r\n */\r\nconst isBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs +\r\n `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,` +\r\n `loop,open,required,reversed,scoped,seamless,` +\r\n `checked,muted,multiple,selected`);\r\n/**\r\n * Boolean attributes should be included if the value is truthy or ''.\r\n * e.g. `<select multiple>` compiles to `{ multiple: '' }`\r\n */\r\nfunction includeBooleanAttr(value) {\r\n return !!value || value === '';\r\n}\r\nconst unsafeAttrCharRE = /[>/=\"'\\u0009\\u000a\\u000c\\u0020]/;\r\nconst attrValidationCache = {};\r\nfunction isSSRSafeAttrName(name) {\r\n if (attrValidationCache.hasOwnProperty(name)) {\r\n return attrValidationCache[name];\r\n }\r\n const isUnsafe = unsafeAttrCharRE.test(name);\r\n if (isUnsafe) {\r\n console.error(`unsafe attribute name: ${name}`);\r\n }\r\n return (attrValidationCache[name] = !isUnsafe);\r\n}\r\nconst propsToAttrMap = {\r\n acceptCharset: 'accept-charset',\r\n className: 'class',\r\n htmlFor: 'for',\r\n httpEquiv: 'http-equiv'\r\n};\r\n/**\r\n * CSS properties that accept plain numbers\r\n */\r\nconst isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +\r\n `border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +\r\n `columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +\r\n `grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +\r\n `grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +\r\n `line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +\r\n // SVG\r\n `fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +\r\n `stroke-miterlimit,stroke-opacity,stroke-width`);\r\n/**\r\n * Known attributes, this is used for stringification of runtime static nodes\r\n * so that we don't stringify bindings that cannot be set from HTML.\r\n * Don't also forget to allow `data-*` and `aria-*`!\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes\r\n */\r\nconst isKnownHtmlAttr = /*#__PURE__*/ makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,` +\r\n `autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,` +\r\n `border,buffered,capture,challenge,charset,checked,cite,class,code,` +\r\n `codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,` +\r\n `coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,` +\r\n `disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,` +\r\n `formaction,formenctype,formmethod,formnovalidate,formtarget,headers,` +\r\n `height,hidden,high,href,hreflang,http-equiv,icon,id,importance,integrity,` +\r\n `ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,` +\r\n `manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,` +\r\n `open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,` +\r\n `referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,` +\r\n `selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,` +\r\n `start,step,style,summary,tabindex,target,title,translate,type,usemap,` +\r\n `value,width,wrap`);\r\n/**\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\r\n */\r\nconst isKnownSvgAttr = /*#__PURE__*/ makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,` +\r\n `arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,` +\r\n `baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,` +\r\n `clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,` +\r\n `color-interpolation-filters,color-profile,color-rendering,` +\r\n `contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,` +\r\n `descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,` +\r\n `dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,` +\r\n `fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,` +\r\n `font-family,font-size,font-size-adjust,font-stretch,font-style,` +\r\n `font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,` +\r\n `glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,` +\r\n `gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,` +\r\n `horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,` +\r\n `k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,` +\r\n `lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,` +\r\n `marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,` +\r\n `mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,` +\r\n `name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,` +\r\n `overflow,overline-position,overline-thickness,panose-1,paint-order,path,` +\r\n `pathLength,patternContentUnits,patternTransform,patternUnits,ping,` +\r\n `pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,` +\r\n `preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,` +\r\n `rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,` +\r\n `restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,` +\r\n `specularConstant,specularExponent,speed,spreadMethod,startOffset,` +\r\n `stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,` +\r\n `strikethrough-position,strikethrough-thickness,string,stroke,` +\r\n `stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,` +\r\n `stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,` +\r\n `systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,` +\r\n `text-decoration,text-rendering,textLength,to,transform,transform-origin,` +\r\n `type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,` +\r\n `unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,` +\r\n `v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,` +\r\n `vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,` +\r\n `writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,` +\r\n `xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,` +\r\n `xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);\n\nfunction normalizeStyle(value) {\r\n if (isArray(value)) {\r\n const res = {};\r\n for (let i = 0; i < value.length; i++) {\r\n const item = value[i];\r\n const normalized = isString(item)\r\n ? parseStringStyle(item)\r\n : normalizeStyle(item);\r\n if (normalized) {\r\n for (const key in normalized) {\r\n res[key] = normalized[key];\r\n }\r\n }\r\n }\r\n return res;\r\n }\r\n else if (isString(value)) {\r\n return value;\r\n }\r\n else if (isObject(value)) {\r\n return value;\r\n }\r\n}\r\nconst listDelimiterRE = /;(?![^(]*\\))/g;\r\nconst propertyDelimiterRE = /:(.+)/;\r\nfunction parseStringStyle(cssText) {\r\n const ret = {};\r\n cssText.split(listDelimiterRE).forEach(item => {\r\n if (item) {\r\n const tmp = item.split(propertyDelimiterRE);\r\n tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());\r\n }\r\n });\r\n return ret;\r\n}\r\nfunction stringifyStyle(styles) {\r\n let ret = '';\r\n if (!styles || isString(styles)) {\r\n return ret;\r\n }\r\n for (const key in styles) {\r\n const value = styles[key];\r\n const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);\r\n if (isString(value) ||\r\n (typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {\r\n // only render valid values\r\n ret += `${normalizedKey}:${value};`;\r\n }\r\n }\r\n return ret;\r\n}\r\nfunction normalizeClass(value) {\r\n let res = '';\r\n if (isString(value)) {\r\n res = value;\r\n }\r\n else if (isArray(value)) {\r\n for (let i = 0; i < value.length; i++) {\r\n const normalized = normalizeClass(value[i]);\r\n if (normalized) {\r\n res += normalized + ' ';\r\n }\r\n }\r\n }\r\n else if (isObject(value)) {\r\n for (const name in value) {\r\n if (value[name]) {\r\n res += name + ' ';\r\n }\r\n }\r\n }\r\n return res.trim();\r\n}\r\nfunction normalizeProps(props) {\r\n if (!props)\r\n return null;\r\n let { class: klass, style } = props;\r\n if (klass && !isString(klass)) {\r\n props.class = normalizeClass(klass);\r\n }\r\n if (style) {\r\n props.style = normalizeStyle(style);\r\n }\r\n return props;\r\n}\n\n// These tag configs are shared between compiler-dom and runtime-dom, so they\r\n// https://developer.mozilla.org/en-US/docs/Web/HTML/Element\r\nconst HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +\r\n 'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +\r\n 'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +\r\n 'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +\r\n 'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +\r\n 'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +\r\n 'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +\r\n 'option,output,progress,select,textarea,details,dialog,menu,' +\r\n 'summary,template,blockquote,iframe,tfoot';\r\n// https://developer.mozilla.org/en-US/docs/Web/SVG/Element\r\nconst SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +\r\n 'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +\r\n 'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +\r\n 'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +\r\n 'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +\r\n 'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +\r\n 'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +\r\n 'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +\r\n 'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +\r\n 'text,textPath,title,tspan,unknown,use,view';\r\nconst VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';\r\nconst isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);\r\nconst isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);\r\nconst isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);\n\nconst escapeRE = /[\"'&<>]/;\r\nfunction escapeHtml(string) {\r\n const str = '' + string;\r\n const match = escapeRE.exec(str);\r\n if (!match) {\r\n return str;\r\n }\r\n let html = '';\r\n let escaped;\r\n let index;\r\n let lastIndex = 0;\r\n for (index = match.index; index < str.length; index++) {\r\n switch (str.charCodeAt(index)) {\r\n case 34: // \"\r\n escaped = '"';\r\n break;\r\n case 38: // &\r\n escaped = '&';\r\n break;\r\n case 39: // '\r\n escaped = ''';\r\n break;\r\n case 60: // <\r\n escaped = '<';\r\n break;\r\n case 62: // >\r\n escaped = '>';\r\n break;\r\n default:\r\n continue;\r\n }\r\n if (lastIndex !== index) {\r\n html += str.slice(lastIndex, index);\r\n }\r\n lastIndex = index + 1;\r\n html += escaped;\r\n }\r\n return lastIndex !== index ? html + str.slice(lastIndex, index) : html;\r\n}\r\n// https://www.w3.org/TR/html52/syntax.html#comments\r\nconst commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;\r\nfunction escapeHtmlComment(src) {\r\n return src.replace(commentStripRE, '');\r\n}\n\nfunction looseCompareArrays(a, b) {\r\n if (a.length !== b.length)\r\n return false;\r\n let equal = true;\r\n for (let i = 0; equal && i < a.length; i++) {\r\n equal = looseEqual(a[i], b[i]);\r\n }\r\n return equal;\r\n}\r\nfunction looseEqual(a, b) {\r\n if (a === b)\r\n return true;\r\n let aValidType = isDate(a);\r\n let bValidType = isDate(b);\r\n if (aValidType || bValidType) {\r\n return aValidType && bValidType ? a.getTime() === b.getTime() : false;\r\n }\r\n aValidType = isArray(a);\r\n bValidType = isArray(b);\r\n if (aValidType || bValidType) {\r\n return aValidType && bValidType ? looseCompareArrays(a, b) : false;\r\n }\r\n aValidType = isObject(a);\r\n bValidType = isObject(b);\r\n if (aValidType || bValidType) {\r\n /* istanbul ignore if: this if will probably never be called */\r\n if (!aValidType || !bValidType) {\r\n return false;\r\n }\r\n const aKeysCount = Object.keys(a).length;\r\n const bKeysCount = Object.keys(b).length;\r\n if (aKeysCount !== bKeysCount) {\r\n return false;\r\n }\r\n for (const key in a) {\r\n const aHasKey = a.hasOwnProperty(key);\r\n const bHasKey = b.hasOwnProperty(key);\r\n if ((aHasKey && !bHasKey) ||\r\n (!aHasKey && bHasKey) ||\r\n !looseEqual(a[key], b[key])) {\r\n return false;\r\n }\r\n }\r\n }\r\n return String(a) === String(b);\r\n}\r\nfunction looseIndexOf(arr, val) {\r\n return arr.findIndex(item => looseEqual(item, val));\r\n}\n\n/**\r\n * For converting {{ interpolation }} values to displayed strings.\r\n * @private\r\n */\r\nconst toDisplayString = (val) => {\r\n return val == null\r\n ? ''\r\n : isArray(val) ||\r\n (isObject(val) &&\r\n (val.toString === objectToString || !isFunction(val.toString)))\r\n ? JSON.stringify(val, replacer, 2)\r\n : String(val);\r\n};\r\nconst replacer = (_key, val) => {\r\n // can't use isRef here since @vue/shared has no deps\r\n if (val && val.__v_isRef) {\r\n return replacer(_key, val.value);\r\n }\r\n else if (isMap(val)) {\r\n return {\r\n [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {\r\n entries[`${key} =>`] = val;\r\n return entries;\r\n }, {})\r\n };\r\n }\r\n else if (isSet(val)) {\r\n return {\r\n [`Set(${val.size})`]: [...val.values()]\r\n };\r\n }\r\n else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {\r\n return String(val);\r\n }\r\n return val;\r\n};\n\nconst EMPTY_OBJ = (process.env.NODE_ENV !== 'production')\r\n ? Object.freeze({})\r\n : {};\r\nconst EMPTY_ARR = (process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst NOOP = () => { };\r\n/**\r\n * Always return false.\r\n */\r\nconst NO = () => false;\r\nconst onRE = /^on[^a-z]/;\r\nconst isOn = (key) => onRE.test(key);\r\nconst isModelListener = (key) => key.startsWith('onUpdate:');\r\nconst extend = Object.assign;\r\nconst remove = (arr, el) => {\r\n const i = arr.indexOf(el);\r\n if (i > -1) {\r\n arr.splice(i, 1);\r\n }\r\n};\r\nconst hasOwnProperty = Object.prototype.hasOwnProperty;\r\nconst hasOwn = (val, key) => hasOwnProperty.call(val, key);\r\nconst isArray = Array.isArray;\r\nconst isMap = (val) => toTypeString(val) === '[object Map]';\r\nconst isSet = (val) => toTypeString(val) === '[object Set]';\r\nconst isDate = (val) => val instanceof Date;\r\nconst isFunction = (val) => typeof val === 'function';\r\nconst isString = (val) => typeof val === 'string';\r\nconst isSymbol = (val) => typeof val === 'symbol';\r\nconst isObject = (val) => val !== null && typeof val === 'object';\r\nconst isPromise = (val) => {\r\n return isObject(val) && isFunction(val.then) && isFunction(val.catch);\r\n};\r\nconst objectToString = Object.prototype.toString;\r\nconst toTypeString = (value) => objectToString.call(value);\r\nconst toRawType = (value) => {\r\n // extract \"RawType\" from strings like \"[object RawType]\"\r\n return toTypeString(value).slice(8, -1);\r\n};\r\nconst isPlainObject = (val) => toTypeString(val) === '[object Object]';\r\nconst isIntegerKey = (key) => isString(key) &&\r\n key !== 'NaN' &&\r\n key[0] !== '-' &&\r\n '' + parseInt(key, 10) === key;\r\nconst isReservedProp = /*#__PURE__*/ makeMap(\r\n// the leading comma is intentional so empty string \"\" is also included\r\n',key,ref,ref_for,ref_key,' +\r\n 'onVnodeBeforeMount,onVnodeMounted,' +\r\n 'onVnodeBeforeUpdate,onVnodeUpdated,' +\r\n 'onVnodeBeforeUnmount,onVnodeUnmounted');\r\nconst cacheStringFunction = (fn) => {\r\n const cache = Object.create(null);\r\n return ((str) => {\r\n const hit = cache[str];\r\n return hit || (cache[str] = fn(str));\r\n });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\r\nconst hyphenateRE = /\\B([A-Z])/g;\r\n/**\r\n * @private\r\n */\r\nconst hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());\r\n/**\r\n * @private\r\n */\r\nconst capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));\r\n/**\r\n * @private\r\n */\r\nconst toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);\r\n// compare whether a value has changed, accounting for NaN.\r\nconst hasChanged = (value, oldValue) => !Object.is(value, oldValue);\r\nconst invokeArrayFns = (fns, arg) => {\r\n for (let i = 0; i < fns.length; i++) {\r\n fns[i](arg);\r\n }\r\n};\r\nconst def = (obj, key, value) => {\r\n Object.defineProperty(obj, key, {\r\n configurable: true,\r\n enumerable: false,\r\n value\r\n });\r\n};\r\nconst toNumber = (val) => {\r\n const n = parseFloat(val);\r\n return isNaN(n) ? val : n;\r\n};\r\nlet _globalThis;\r\nconst getGlobalThis = () => {\r\n return (_globalThis ||\r\n (_globalThis =\r\n typeof globalThis !== 'undefined'\r\n ? globalThis\r\n : typeof self !== 'undefined'\r\n ? self\r\n : typeof window !== 'undefined'\r\n ? window\r\n : typeof global !== 'undefined'\r\n ? global\r\n : {}));\r\n};\n\nexport { EMPTY_ARR, EMPTY_OBJ, NO, NOOP, PatchFlagNames, camelize, capitalize, def, escapeHtml, escapeHtmlComment, extend, generateCodeFrame, getGlobalThis, hasChanged, hasOwn, hyphenate, includeBooleanAttr, invokeArrayFns, isArray, isBooleanAttr, isDate, isFunction, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownSvgAttr, isMap, isModelListener, isNoUnitNumericStyleProp, isObject, isOn, isPlainObject, isPromise, isReservedProp, isSSRSafeAttrName, isSVGTag, isSet, isSpecialBooleanAttr, isString, isSymbol, isVoidTag, looseEqual, looseIndexOf, makeMap, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, remove, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toNumber, toRawType, toTypeString };\n","<template>\n <transition :name=\"name\"\n @before-appear=\"beforeAppear\"\n @appear=\"appear\"\n @after-appear=\"afterAppear\"\n @appear-cancelled=\"appearCancelled\"\n @before-enter=\"beforeEnter\"\n @enter=\"enter\"\n @after-enter=\"afterEnter\"\n @enter-cancelled=\"enterCancelled\"\n @before-leave=\"beforeLeave\"\n @leave=\"leave\"\n @after-leave=\"afterLeave\"\n @leave-cancelled=\"leaveCancelled\"\n >\n <slot></slot>\n </transition>\n</template>\n\n<script>\n export default {\n name: \"CollapseTransition\",\n\n props: {\n name: {\n type: String,\n required: false,\n default: 'collapse'\n },\n dimension: {\n type: String,\n required: false,\n default: 'height',\n validator: (value) => {\n return ['height', 'width'].includes(value)\n }\n },\n duration: {\n type: Number,\n required: false,\n default: 300\n },\n easing: {\n type: String,\n required: false,\n default: 'ease-in-out'\n },\n },\n\n watch: {\n dimension() {\n this.clearCachedDimensions()\n }\n },\n\n data() {\n return {\n cachedStyles: null,\n }\n },\n\n computed: {\n transition() {\n let transitions = []\n\n Object.keys(this.cachedStyles).forEach((key) => {\n transitions.push(`${this.convertToCssProperty(key)} ${this.duration}ms ${this.easing}`)\n })\n\n return transitions.join(', ')\n }\n },\n\n methods: {\n beforeAppear(el) {\n // Emit the event to the parent\n this.$emit('before-appear', el)\n },\n\n appear(el) {\n // Emit the event to the parent\n this.$emit('appear', el)\n },\n\n afterAppear(el) {\n // Emit the event to the parent\n this.$emit('after-appear', el)\n },\n\n appearCancelled(el) {\n // Emit the event to the parent\n this.$emit('appear-cancelled', el)\n },\n\n beforeEnter(el) {\n // Emit the event to the parent\n this.$emit('before-enter', el)\n },\n\n enter(el, done) {\n // Because width and height may be 'auto',\n // first detect and cache the dimensions\n this.detectAndCacheDimensions(el)\n\n // The order of applying styles is important:\n // - 1. Set styles for state before transition\n // - 2. Force repaint\n // - 3. Add transition style\n // - 4. Set styles for state after transition\n // If the order is not right and you open any 2nd level submenu\n // for the first time, the transition will not work.\n this.setClosedDimensions(el)\n this.hideOverflow(el)\n this.forceRepaint(el)\n this.setTransition(el)\n this.setOpenedDimensions(el)\n\n // Emit the event to the parent\n this.$emit('enter', el, done)\n\n // Call done() when the transition ends\n // to trigger the @after-enter event.\n setTimeout(done, this.duration)\n },\n\n afterEnter(el) {\n // Clean up inline styles\n this.unsetOverflow(el)\n this.unsetTransition(el)\n this.unsetDimensions(el)\n this.clearCachedDimensions()\n\n // Emit the event to the parent\n this.$emit('after-enter', el)\n },\n\n enterCancelled(el) {\n // Emit the event to the parent\n this.$emit('enter-cancelled', el)\n },\n\n beforeLeave(el) {\n // Emit the event to the parent\n this.$emit('before-leave', el)\n },\n\n leave(el, done) {\n // For some reason, @leave triggered when starting\n // from open state on page load. So for safety,\n // check if the dimensions have been cached.\n this.detectAndCacheDimensions(el)\n\n // The order of applying styles is less important\n // than in the enter phase, as long as we repaint\n // before setting the closed dimensions.\n // But it is probably best to use the same\n // order as the enter phase.\n this.setOpenedDimensions(el)\n this.hideOverflow(el)\n this.forceRepaint(el)\n this.setTransition(el)\n this.setClosedDimensions(el)\n\n // Emit the event to the parent\n this.$emit('leave', el, done)\n\n // Call done() when the transition ends\n // to trigger the @after-leave event.\n // This will also cause v-show\n // to reapply 'display: none'.\n setTimeout(done, this.duration)\n },\n\n afterLeave(el) {\n // Clean up inline styles\n this.unsetOverflow(el)\n this.unsetTransition(el)\n this.unsetDimensions(el)\n this.clearCachedDimensions()\n\n // Emit the event to the parent\n this.$emit('after-leave', el)\n },\n\n leaveCancelled(el) {\n // Emit the event to the parent\n this.$emit('leave-cancelled', el)\n },\n\n detectAndCacheDimensions(el) {\n // Cache actual dimensions\n // only once to void invalid values when\n // triggering during a transition\n if (this.cachedStyles) return\n\n const visibility = el.style.visibility\n const display = el.style.display\n\n // Trick to get the width and\n // height of a hidden element\n el.style.visibility = 'hidden'\n el.style.display = ''\n\n this.cachedStyles = this.detectRelevantDimensions(el)\n\n // Restore any original styling\n el.style.visibility = visibility\n el.style.display = display\n },\n\n clearCachedDimensions() {\n this.cachedStyles = null\n },\n\n detectRelevantDimensions(el) {\n // These properties will be transitioned\n if (this.dimension === 'height') {\n return {\n 'height': el.offsetHeight + 'px',\n 'paddingTop': el.style.paddingTop || this.getCssValue(el, 'padding-top'),\n 'paddingBottom': el.style.paddingBottom || this.getCssValue(el, 'padding-bottom'),\n }\n }\n\n if (this.dimension === 'width') {\n return {\n 'width': el.offsetWidth + 'px',\n 'paddingLeft': el.style.paddingLeft || this.getCssValue(el, 'padding-left'),\n 'paddingRight': el.style.paddingRight || this.getCssValue(el, 'padding-right'),\n }\n }\n\n return {}\n },\n\n setTransition(el) {\n el.style.transition = this.transition\n },\n\n unsetTransition(el) {\n el.style.transition = ''\n },\n\n hideOverflow(el) {\n el.style.overflow = 'hidden'\n },\n\n unsetOverflow(el) {\n el.style.overflow = ''\n },\n\n setClosedDimensions(el) {\n Object.keys(this.cachedStyles).forEach(key => {\n el.style[key] = '0'\n })\n },\n\n setOpenedDimensions(el) {\n Object.keys(this.cachedStyles).forEach((key) => {\n el.style[key] = this.cachedStyles[key]\n })\n },\n\n unsetDimensions(el) {\n Object.keys(this.cachedStyles).forEach((key) => {\n el.style[key] = ''\n })\n },\n\n forceRepaint(el) {\n // Force repaint to make sure the animation is triggered correctly.\n // Thanks: https://markus.oberlehner.net/blog/transition-to-height-auto-with-vue/\n getComputedStyle(el)[this.dimension]\n },\n\n getCssValue(el, style) {\n return getComputedStyle(el, null).getPropertyValue(style)\n },\n\n convertToCssProperty(style) {\n // Example: convert 'paddingTop' to 'padding-top'\n // Thanks: https://gist.github.com/tan-yuki/3450323\n const upperChars = style.match(/([A-Z])/g)\n\n if ( ! upperChars) {\n return style\n }\n\n for (let i = 0, n = upperChars.length; i < n; i++) {\n style = style.replace(new RegExp(upperChars[i]), '-' + upperChars[i].toLowerCase())\n }\n\n if (style.slice(0, 1) === '-') {\n style = style.slice(1)\n }\n\n return style\n }\n }\n }\n</script>\n","import { render } from \"./CollapseTransition.vue?vue&type=template&id=0f6a5689\"\nimport script from \"./CollapseTransition.vue?vue&type=script&lang=js\"\nexport * from \"./CollapseTransition.vue?vue&type=script&lang=js\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar tryToString = require('../internals/try-to-string');\n\nvar TypeError = global.TypeError;\n\n// `Assert: IsCallable(argument) is true`\nmodule.exports = function (argument) {\n if (isCallable(argument)) return argument;\n throw TypeError(tryToString(argument) + ' is not a function');\n};\n","var global = require('../internals/global');\nvar isConstructor = require('../internals/is-constructor');\nvar tryToString = require('../internals/try-to-string');\n\nvar TypeError = global.TypeError;\n\n// `Assert: IsConstructor(argument) is true`\nmodule.exports = function (argument) {\n if (isConstructor(argument)) return argument;\n throw TypeError(tryToString(argument) + ' is not a constructor');\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar String = global.String;\nvar TypeError = global.TypeError;\n\nmodule.exports = function (argument) {\n if (typeof argument == 'object' || isCallable(argument)) return argument;\n throw TypeError(\"Can't set \" + String(argument) + ' as a prototype');\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\nvar create = require('../internals/object-create');\nvar definePropertyModule = require('../internals/object-define-property');\n\nvar UNSCOPABLES = wellKnownSymbol('unscopables');\nvar ArrayPrototype = Array.prototype;\n\n// Array.prototype[@@unscopables]\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\nif (ArrayPrototype[UNSCOPABLES] == undefined) {\n definePropertyModule.f(ArrayPrototype, UNSCOPABLES, {\n configurable: true,\n value: create(null)\n });\n}\n\n// add a key to Array.prototype[@@unscopables]\nmodule.exports = function (key) {\n ArrayPrototype[UNSCOPABLES][key] = true;\n};\n","'use strict';\nvar charAt = require('../internals/string-multibyte').charAt;\n\n// `AdvanceStringIndex` abstract operation\n// https://tc39.es/ecma262/#sec-advancestringindex\nmodule.exports = function (S, index, unicode) {\n return index + (unicode ? charAt(S, index).length : 1);\n};\n","var global = require('../internals/global');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\n\nvar TypeError = global.TypeError;\n\nmodule.exports = function (it, Prototype) {\n if (isPrototypeOf(Prototype, it)) return it;\n throw TypeError('Incorrect invocation');\n};\n","var global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar String = global.String;\nvar TypeError = global.TypeError;\n\n// `Assert: Type(argument) is Object`\nmodule.exports = function (argument) {\n if (isObject(argument)) return argument;\n throw TypeError(String(argument) + ' is not an object');\n};\n","// FF26- bug: ArrayBuffers are non-extensible, but Object.isExtensible does not report it\nvar fails = require('../internals/fails');\n\nmodule.exports = fails(function () {\n if (typeof ArrayBuffer == 'function') {\n var buffer = new ArrayBuffer(8);\n // eslint-disable-next-line es/no-object-isextensible, es/no-object-defineproperty -- safe\n if (Object.isExtensible(buffer)) Object.defineProperty(buffer, 'a', { value: 8 });\n }\n});\n","'use strict';\nvar $forEach = require('../internals/array-iteration').forEach;\nvar arrayMethodIsStrict = require('../internals/array-method-is-strict');\n\nvar STRICT_METHOD = arrayMethodIsStrict('forEach');\n\n// `Array.prototype.forEach` method implementation\n// https://tc39.es/ecma262/#sec-array.prototype.foreach\nmodule.exports = !STRICT_METHOD ? function forEach(callbackfn /* , thisArg */) {\n return $forEach(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n// eslint-disable-next-line es/no-array-prototype-foreach -- safe\n} : [].forEach;\n","'use strict';\nvar global = require('../internals/global');\nvar bind = require('../internals/function-bind-context');\nvar call = require('../internals/function-call');\nvar toObject = require('../internals/to-object');\nvar callWithSafeIterationClosing = require('../internals/call-with-safe-iteration-closing');\nvar isArrayIteratorMethod = require('../internals/is-array-iterator-method');\nvar isConstructor = require('../internals/is-constructor');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar createProperty = require('../internals/create-property');\nvar getIterator = require('../internals/get-iterator');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nvar Array = global.Array;\n\n// `Array.from` method implementation\n// https://tc39.es/ecma262/#sec-array.from\nmodule.exports = function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {\n var O = toObject(arrayLike);\n var IS_CONSTRUCTOR = isConstructor(this);\n var argumentsLength = arguments.length;\n var mapfn = argumentsLength > 1 ? arguments[1] : undefined;\n var mapping = mapfn !== undefined;\n if (mapping) mapfn = bind(mapfn, argumentsLength > 2 ? arguments[2] : undefined);\n var iteratorMethod = getIteratorMethod(O);\n var index = 0;\n var length, result, step, iterator, next, value;\n // if the target is not iterable or it's an array with the default iterator - use a simple case\n if (iteratorMethod && !(this == Array && isArrayIteratorMethod(iteratorMethod))) {\n iterator = getIterator(O, iteratorMethod);\n next = iterator.next;\n result = IS_CONSTRUCTOR ? new this() : [];\n for (;!(step = call(next, iterator)).done; index++) {\n value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value;\n createProperty(result, index, value);\n }\n } else {\n length = lengthOfArrayLike(O);\n result = IS_CONSTRUCTOR ? new this(length) : Array(length);\n for (;length > index; index++) {\n value = mapping ? mapfn(O[index], index) : O[index];\n createProperty(result, index, value);\n }\n }\n result.length = index;\n return result;\n};\n","var toIndexedObject = require('../internals/to-indexed-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = lengthOfArrayLike(O);\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare -- NaN check\n if (IS_INCLUDES && el != el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare -- NaN check\n if (value != value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.es/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.es/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n","var bind = require('../internals/function-bind-context');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IndexedObject = require('../internals/indexed-object');\nvar toObject = require('../internals/to-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar arraySpeciesCreate = require('../internals/array-species-create');\n\nvar push = uncurryThis([].push);\n\n// `Array.prototype.{ forEach, map, filter, some, every, find, findIndex, filterReject }` methods implementation\nvar createMethod = function (TYPE) {\n var IS_MAP = TYPE == 1;\n var IS_FILTER = TYPE == 2;\n var IS_SOME = TYPE == 3;\n var IS_EVERY = TYPE == 4;\n var IS_FIND_INDEX = TYPE == 6;\n var IS_FILTER_REJECT = TYPE == 7;\n var NO_HOLES = TYPE == 5 || IS_FIND_INDEX;\n return function ($this, callbackfn, that, specificCreate) {\n var O = toObject($this);\n var self = IndexedObject(O);\n var boundFunction = bind(callbackfn, that);\n var length = lengthOfArrayLike(self);\n var index = 0;\n var create = specificCreate || arraySpeciesCreate;\n var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_REJECT ? create($this, 0) : undefined;\n var value, result;\n for (;length > index; index++) if (NO_HOLES || index in self) {\n value = self[index];\n result = boundFunction(value, index, O);\n if (TYPE) {\n if (IS_MAP) target[index] = result; // map\n else if (result) switch (TYPE) {\n case 3: return true; // some\n case 5: return value; // find\n case 6: return index; // findIndex\n case 2: push(target, value); // filter\n } else switch (TYPE) {\n case 4: return false; // every\n case 7: push(target, value); // filterReject\n }\n }\n }\n return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.forEach` method\n // https://tc39.es/ecma262/#sec-array.prototype.foreach\n forEach: createMethod(0),\n // `Array.prototype.map` method\n // https://tc39.es/ecma262/#sec-array.prototype.map\n map: createMethod(1),\n // `Array.prototype.filter` method\n // https://tc39.es/ecma262/#sec-array.prototype.filter\n filter: createMethod(2),\n // `Array.prototype.some` method\n // https://tc39.es/ecma262/#sec-array.prototype.some\n some: createMethod(3),\n // `Array.prototype.every` method\n // https://tc39.es/ecma262/#sec-array.prototype.every\n every: createMethod(4),\n // `Array.prototype.find` method\n // https://tc39.es/ecma262/#sec-array.prototype.find\n find: createMethod(5),\n // `Array.prototype.findIndex` method\n // https://tc39.es/ecma262/#sec-array.prototype.findIndex\n findIndex: createMethod(6),\n // `Array.prototype.filterReject` method\n // https://github.com/tc39/proposal-array-filtering\n filterReject: createMethod(7)\n};\n","var fails = require('../internals/fails');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (METHOD_NAME) {\n // We can't use this feature detection in V8 since it causes\n // deoptimization and serious performance degradation\n // https://github.com/zloirock/core-js/issues/677\n return V8_VERSION >= 51 || !fails(function () {\n var array = [];\n var constructor = array.constructor = {};\n constructor[SPECIES] = function () {\n return { foo: 1 };\n };\n return array[METHOD_NAME](Boolean).foo !== 1;\n });\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\nmodule.exports = function (METHOD_NAME, argument) {\n var method = [][METHOD_NAME];\n return !!method && fails(function () {\n // eslint-disable-next-line no-useless-call,no-throw-literal -- required for testing\n method.call(null, argument || function () { throw 1; }, 1);\n });\n};\n","var global = require('../internals/global');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar createProperty = require('../internals/create-property');\n\nvar Array = global.Array;\nvar max = Math.max;\n\nmodule.exports = function (O, start, end) {\n var length = lengthOfArrayLike(O);\n var k = toAbsoluteIndex(start, length);\n var fin = toAbsoluteIndex(end === undefined ? length : end, length);\n var result = Array(max(fin - k, 0));\n for (var n = 0; k < fin; k++, n++) createProperty(result, n, O[k]);\n result.length = n;\n return result;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis([].slice);\n","var global = require('../internals/global');\nvar isArray = require('../internals/is-array');\nvar isConstructor = require('../internals/is-constructor');\nvar isObject = require('../internals/is-object');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar SPECIES = wellKnownSymbol('species');\nvar Array = global.Array;\n\n// a part of `ArraySpeciesCreate` abstract operation\n// https://tc39.es/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray) {\n var C;\n if (isArray(originalArray)) {\n C = originalArray.constructor;\n // cross-realm fallback\n if (isConstructor(C) && (C === Array || isArray(C.prototype))) C = undefined;\n else if (isObject(C)) {\n C = C[SPECIES];\n if (C === null) C = undefined;\n }\n } return C === undefined ? Array : C;\n};\n","var arraySpeciesConstructor = require('../internals/array-species-constructor');\n\n// `ArraySpeciesCreate` abstract operation\n// https://tc39.es/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray, length) {\n return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);\n};\n","var anObject = require('../internals/an-object');\nvar iteratorClose = require('../internals/iterator-close');\n\n// call something on iterator step with safe closing on error\nmodule.exports = function (iterator, fn, value, ENTRIES) {\n try {\n return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);\n } catch (error) {\n iteratorClose(iterator, 'throw', error);\n }\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar SAFE_CLOSING = false;\n\ntry {\n var called = 0;\n var iteratorWithReturn = {\n next: function () {\n return { done: !!called++ };\n },\n 'return': function () {\n SAFE_CLOSING = true;\n }\n };\n iteratorWithReturn[ITERATOR] = function () {\n return this;\n };\n // eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing\n Array.from(iteratorWithReturn, function () { throw 2; });\n} catch (error) { /* empty */ }\n\nmodule.exports = function (exec, SKIP_CLOSING) {\n if (!SKIP_CLOSING && !SAFE_CLOSING) return false;\n var ITERATION_SUPPORT = false;\n try {\n var object = {};\n object[ITERATOR] = function () {\n return {\n next: function () {\n return { done: ITERATION_SUPPORT = true };\n }\n };\n };\n exec(object);\n } catch (error) { /* empty */ }\n return ITERATION_SUPPORT;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar toString = uncurryThis({}.toString);\nvar stringSlice = uncurryThis(''.slice);\n\nmodule.exports = function (it) {\n return stringSlice(toString(it), 8, -1);\n};\n","var global = require('../internals/global');\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar isCallable = require('../internals/is-callable');\nvar classofRaw = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar Object = global.Object;\n\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) == 'Object' && isCallable(O.callee) ? 'Arguments' : result;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar replace = uncurryThis(''.replace);\n\nvar TEST = (function (arg) { return String(Error(arg).stack); })('zxcasd');\nvar V8_OR_CHAKRA_STACK_ENTRY = /\\n\\s*at [^:]*:[^\\n]*/;\nvar IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);\n\nmodule.exports = function (stack, dropEntries) {\n if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string') {\n while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');\n } return stack;\n};\n","'use strict';\nvar defineProperty = require('../internals/object-define-property').f;\nvar create = require('../internals/object-create');\nvar redefineAll = require('../internals/redefine-all');\nvar bind = require('../internals/function-bind-context');\nvar anInstance = require('../internals/an-instance');\nvar iterate = require('../internals/iterate');\nvar defineIterator = require('../internals/define-iterator');\nvar setSpecies = require('../internals/set-species');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar fastKey = require('../internals/internal-metadata').fastKey;\nvar InternalStateModule = require('../internals/internal-state');\n\nvar setInternalState = InternalStateModule.set;\nvar internalStateGetterFor = InternalStateModule.getterFor;\n\nmodule.exports = {\n getConstructor: function (wrapper, CONSTRUCTOR_NAME, IS_MAP, ADDER) {\n var Constructor = wrapper(function (that, iterable) {\n anInstance(that, Prototype);\n setInternalState(that, {\n type: CONSTRUCTOR_NAME,\n index: create(null),\n first: undefined,\n last: undefined,\n size: 0\n });\n if (!DESCRIPTORS) that.size = 0;\n if (iterable != undefined) iterate(iterable, that[ADDER], { that: that, AS_ENTRIES: IS_MAP });\n });\n\n var Prototype = Constructor.prototype;\n\n var getInternalState = internalStateGetterFor(CONSTRUCTOR_NAME);\n\n var define = function (that, key, value) {\n var state = getInternalState(that);\n var entry = getEntry(that, key);\n var previous, index;\n // change existing entry\n if (entry) {\n entry.value = value;\n // create new entry\n } else {\n state.last = entry = {\n index: index = fastKey(key, true),\n key: key,\n value: value,\n previous: previous = state.last,\n next: undefined,\n removed: false\n };\n if (!state.first) state.first = entry;\n if (previous) previous.next = entry;\n if (DESCRIPTORS) state.size++;\n else that.size++;\n // add to index\n if (index !== 'F') state.index[index] = entry;\n } return that;\n };\n\n var getEntry = function (that, key) {\n var state = getInternalState(that);\n // fast case\n var index = fastKey(key);\n var entry;\n if (index !== 'F') return state.index[index];\n // frozen object case\n for (entry = state.first; entry; entry = entry.next) {\n if (entry.key == key) return entry;\n }\n };\n\n redefineAll(Prototype, {\n // `{ Map, Set }.prototype.clear()` methods\n // https://tc39.es/ecma262/#sec-map.prototype.clear\n // https://tc39.es/ecma262/#sec-set.prototype.clear\n clear: function clear() {\n var that = this;\n var state = getInternalState(that);\n var data = state.index;\n var entry = state.first;\n while (entry) {\n entry.removed = true;\n if (entry.previous) entry.previous = entry.previous.next = undefined;\n delete data[entry.index];\n entry = entry.next;\n }\n state.first = state.last = undefined;\n if (DESCRIPTORS) state.size = 0;\n else that.size = 0;\n },\n // `{ Map, Set }.prototype.delete(key)` methods\n // https://tc39.es/ecma262/#sec-map.prototype.delete\n // https://tc39.es/ecma262/#sec-set.prototype.delete\n 'delete': function (key) {\n var that = this;\n var state = getInternalState(that);\n var entry = getEntry(that, key);\n if (entry) {\n var next = entry.next;\n var prev = entry.previous;\n delete state.index[entry.index];\n entry.removed = true;\n if (prev) prev.next = next;\n if (next) next.previous = prev;\n if (state.first == entry) state.first = next;\n if (state.last == entry) state.last = prev;\n if (DESCRIPTORS) state.size--;\n else that.size--;\n } return !!entry;\n },\n // `{ Map, Set }.prototype.forEach(callbackfn, thisArg = undefined)` methods\n // https://tc39.es/ecma262/#sec-map.prototype.foreach\n // https://tc39.es/ecma262/#sec-set.prototype.foreach\n forEach: function forEach(callbackfn /* , that = undefined */) {\n var state = getInternalState(this);\n var boundFunction = bind(callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n var entry;\n while (entry = entry ? entry.next : state.first) {\n boundFunction(entry.value, entry.key, this);\n // revert to the last existing entry\n while (entry && entry.removed) entry = entry.previous;\n }\n },\n // `{ Map, Set}.prototype.has(key)` methods\n // https://tc39.es/ecma262/#sec-map.prototype.has\n // https://tc39.es/ecma262/#sec-set.prototype.has\n has: function has(key) {\n return !!getEntry(this, key);\n }\n });\n\n redefineAll(Prototype, IS_MAP ? {\n // `Map.prototype.get(key)` method\n // https://tc39.es/ecma262/#sec-map.prototype.get\n get: function get(key) {\n var entry = getEntry(this, key);\n return entry && entry.value;\n },\n // `Map.prototype.set(key, value)` method\n // https://tc39.es/ecma262/#sec-map.prototype.set\n set: function set(key, value) {\n return define(this, key === 0 ? 0 : key, value);\n }\n } : {\n // `Set.prototype.add(value)` method\n // https://tc39.es/ecma262/#sec-set.prototype.add\n add: function add(value) {\n return define(this, value = value === 0 ? 0 : value, value);\n }\n });\n if (DESCRIPTORS) defineProperty(Prototype, 'size', {\n get: function () {\n return getInternalState(this).size;\n }\n });\n return Constructor;\n },\n setStrong: function (Constructor, CONSTRUCTOR_NAME, IS_MAP) {\n var ITERATOR_NAME = CONSTRUCTOR_NAME + ' Iterator';\n var getInternalCollectionState = internalStateGetterFor(CONSTRUCTOR_NAME);\n var getInternalIteratorState = internalStateGetterFor(ITERATOR_NAME);\n // `{ Map, Set }.prototype.{ keys, values, entries, @@iterator }()` methods\n // https://tc39.es/ecma262/#sec-map.prototype.entries\n // https://tc39.es/ecma262/#sec-map.prototype.keys\n // https://tc39.es/ecma262/#sec-map.prototype.values\n // https://tc39.es/ecma262/#sec-map.prototype-@@iterator\n // https://tc39.es/ecma262/#sec-set.prototype.entries\n // https://tc39.es/ecma262/#sec-set.prototype.keys\n // https://tc39.es/ecma262/#sec-set.prototype.values\n // https://tc39.es/ecma262/#sec-set.prototype-@@iterator\n defineIterator(Constructor, CONSTRUCTOR_NAME, function (iterated, kind) {\n setInternalState(this, {\n type: ITERATOR_NAME,\n target: iterated,\n state: getInternalCollectionState(iterated),\n kind: kind,\n last: undefined\n });\n }, function () {\n var state = getInternalIteratorState(this);\n var kind = state.kind;\n var entry = state.last;\n // revert to the last existing entry\n while (entry && entry.removed) entry = entry.previous;\n // get next entry\n if (!state.target || !(state.last = entry = entry ? entry.next : state.state.first)) {\n // or finish the iteration\n state.target = undefined;\n return { value: undefined, done: true };\n }\n // return step by kind\n if (kind == 'keys') return { value: entry.key, done: false };\n if (kind == 'values') return { value: entry.value, done: false };\n return { value: [entry.key, entry.value], done: false };\n }, IS_MAP ? 'entries' : 'values', !IS_MAP, true);\n\n // `{ Map, Set }.prototype[@@species]` accessors\n // https://tc39.es/ecma262/#sec-get-map-@@species\n // https://tc39.es/ecma262/#sec-get-set-@@species\n setSpecies(CONSTRUCTOR_NAME);\n }\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isForced = require('../internals/is-forced');\nvar redefine = require('../internals/redefine');\nvar InternalMetadataModule = require('../internals/internal-metadata');\nvar iterate = require('../internals/iterate');\nvar anInstance = require('../internals/an-instance');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar fails = require('../internals/fails');\nvar checkCorrectnessOfIteration = require('../internals/check-correctness-of-iteration');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar inheritIfRequired = require('../internals/inherit-if-required');\n\nmodule.exports = function (CONSTRUCTOR_NAME, wrapper, common) {\n var IS_MAP = CONSTRUCTOR_NAME.indexOf('Map') !== -1;\n var IS_WEAK = CONSTRUCTOR_NAME.indexOf('Weak') !== -1;\n var ADDER = IS_MAP ? 'set' : 'add';\n var NativeConstructor = global[CONSTRUCTOR_NAME];\n var NativePrototype = NativeConstructor && NativeConstructor.prototype;\n var Constructor = NativeConstructor;\n var exported = {};\n\n var fixMethod = function (KEY) {\n var uncurriedNativeMethod = uncurryThis(NativePrototype[KEY]);\n redefine(NativePrototype, KEY,\n KEY == 'add' ? function add(value) {\n uncurriedNativeMethod(this, value === 0 ? 0 : value);\n return this;\n } : KEY == 'delete' ? function (key) {\n return IS_WEAK && !isObject(key) ? false : uncurriedNativeMethod(this, key === 0 ? 0 : key);\n } : KEY == 'get' ? function get(key) {\n return IS_WEAK && !isObject(key) ? undefined : uncurriedNativeMethod(this, key === 0 ? 0 : key);\n } : KEY == 'has' ? function has(key) {\n return IS_WEAK && !isObject(key) ? false : uncurriedNativeMethod(this, key === 0 ? 0 : key);\n } : function set(key, value) {\n uncurriedNativeMethod(this, key === 0 ? 0 : key, value);\n return this;\n }\n );\n };\n\n var REPLACE = isForced(\n CONSTRUCTOR_NAME,\n !isCallable(NativeConstructor) || !(IS_WEAK || NativePrototype.forEach && !fails(function () {\n new NativeConstructor().entries().next();\n }))\n );\n\n if (REPLACE) {\n // create collection constructor\n Constructor = common.getConstructor(wrapper, CONSTRUCTOR_NAME, IS_MAP, ADDER);\n InternalMetadataModule.enable();\n } else if (isForced(CONSTRUCTOR_NAME, true)) {\n var instance = new Constructor();\n // early implementations not supports chaining\n var HASNT_CHAINING = instance[ADDER](IS_WEAK ? {} : -0, 1) != instance;\n // V8 ~ Chromium 40- weak-collections throws on primitives, but should return false\n var THROWS_ON_PRIMITIVES = fails(function () { instance.has(1); });\n // most early implementations doesn't supports iterables, most modern - not close it correctly\n // eslint-disable-next-line no-new -- required for testing\n var ACCEPT_ITERABLES = checkCorrectnessOfIteration(function (iterable) { new NativeConstructor(iterable); });\n // for early implementations -0 and +0 not the same\n var BUGGY_ZERO = !IS_WEAK && fails(function () {\n // V8 ~ Chromium 42- fails only with 5+ elements\n var $instance = new NativeConstructor();\n var index = 5;\n while (index--) $instance[ADDER](index, index);\n return !$instance.has(-0);\n });\n\n if (!ACCEPT_ITERABLES) {\n Constructor = wrapper(function (dummy, iterable) {\n anInstance(dummy, NativePrototype);\n var that = inheritIfRequired(new NativeConstructor(), dummy, Constructor);\n if (iterable != undefined) iterate(iterable, that[ADDER], { that: that, AS_ENTRIES: IS_MAP });\n return that;\n });\n Constructor.prototype = NativePrototype;\n NativePrototype.constructor = Constructor;\n }\n\n if (THROWS_ON_PRIMITIVES || BUGGY_ZERO) {\n fixMethod('delete');\n fixMethod('has');\n IS_MAP && fixMethod('get');\n }\n\n if (BUGGY_ZERO || HASNT_CHAINING) fixMethod(ADDER);\n\n // weak collections should not contains .clear method\n if (IS_WEAK && NativePrototype.clear) delete NativePrototype.clear;\n }\n\n exported[CONSTRUCTOR_NAME] = Constructor;\n $({ global: true, forced: Constructor != NativeConstructor }, exported);\n\n setToStringTag(Constructor, CONSTRUCTOR_NAME);\n\n if (!IS_WEAK) common.setStrong(Constructor, CONSTRUCTOR_NAME, IS_MAP);\n\n return Constructor;\n};\n","var hasOwn = require('../internals/has-own-property');\nvar ownKeys = require('../internals/own-keys');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\n\nmodule.exports = function (target, source, exceptions) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {\n defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n }\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar MATCH = wellKnownSymbol('match');\n\nmodule.exports = function (METHOD_NAME) {\n var regexp = /./;\n try {\n '/./'[METHOD_NAME](regexp);\n } catch (error1) {\n try {\n regexp[MATCH] = false;\n return '/./'[METHOD_NAME](regexp);\n } catch (error2) { /* empty */ }\n } return false;\n};\n","var fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n // eslint-disable-next-line es/no-object-getprototypeof -- required for testing\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar toString = require('../internals/to-string');\n\nvar quot = /\"/g;\nvar replace = uncurryThis(''.replace);\n\n// `CreateHTML` abstract operation\n// https://tc39.es/ecma262/#sec-createhtml\nmodule.exports = function (string, tag, attribute, value) {\n var S = toString(requireObjectCoercible(string));\n var p1 = '<' + tag;\n if (attribute !== '') p1 += ' ' + attribute + '=\"' + replace(toString(value), quot, '"') + '\"';\n return p1 + '>' + S + '</' + tag + '>';\n};\n","'use strict';\nvar IteratorPrototype = require('../internals/iterators-core').IteratorPrototype;\nvar create = require('../internals/object-create');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar Iterators = require('../internals/iterators');\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {\n var TO_STRING_TAG = NAME + ' Iterator';\n IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });\n setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);\n Iterators[TO_STRING_TAG] = returnThis;\n return IteratorConstructor;\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n","module.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n","'use strict';\nvar toPropertyKey = require('../internals/to-property-key');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = function (object, key, value) {\n var propertyKey = toPropertyKey(key);\n if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));\n else object[propertyKey] = value;\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar call = require('../internals/function-call');\nvar IS_PURE = require('../internals/is-pure');\nvar FunctionName = require('../internals/function-name');\nvar isCallable = require('../internals/is-callable');\nvar createIteratorConstructor = require('../internals/create-iterator-constructor');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar redefine = require('../internals/redefine');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\nvar IteratorsCore = require('../internals/iterators-core');\n\nvar PROPER_FUNCTION_NAME = FunctionName.PROPER;\nvar CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;\nvar IteratorPrototype = IteratorsCore.IteratorPrototype;\nvar BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;\nvar ITERATOR = wellKnownSymbol('iterator');\nvar KEYS = 'keys';\nvar VALUES = 'values';\nvar ENTRIES = 'entries';\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {\n createIteratorConstructor(IteratorConstructor, NAME, next);\n\n var getIterationMethod = function (KIND) {\n if (KIND === DEFAULT && defaultIterator) return defaultIterator;\n if (!BUGGY_SAFARI_ITERATORS && KIND in IterablePrototype) return IterablePrototype[KIND];\n switch (KIND) {\n case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };\n case VALUES: return function values() { return new IteratorConstructor(this, KIND); };\n case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };\n } return function () { return new IteratorConstructor(this); };\n };\n\n var TO_STRING_TAG = NAME + ' Iterator';\n var INCORRECT_VALUES_NAME = false;\n var IterablePrototype = Iterable.prototype;\n var nativeIterator = IterablePrototype[ITERATOR]\n || IterablePrototype['@@iterator']\n || DEFAULT && IterablePrototype[DEFAULT];\n var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);\n var anyNativeIterator = NAME == 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;\n var CurrentIteratorPrototype, methods, KEY;\n\n // fix native\n if (anyNativeIterator) {\n CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));\n if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {\n if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {\n if (setPrototypeOf) {\n setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);\n } else if (!isCallable(CurrentIteratorPrototype[ITERATOR])) {\n redefine(CurrentIteratorPrototype, ITERATOR, returnThis);\n }\n }\n // Set @@toStringTag to native iterators\n setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);\n if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;\n }\n }\n\n // fix Array.prototype.{ values, @@iterator }.name in V8 / FF\n if (PROPER_FUNCTION_NAME && DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) {\n if (!IS_PURE && CONFIGURABLE_FUNCTION_NAME) {\n createNonEnumerableProperty(IterablePrototype, 'name', VALUES);\n } else {\n INCORRECT_VALUES_NAME = true;\n defaultIterator = function values() { return call(nativeIterator, this); };\n }\n }\n\n // export additional methods\n if (DEFAULT) {\n methods = {\n values: getIterationMethod(VALUES),\n keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),\n entries: getIterationMethod(ENTRIES)\n };\n if (FORCED) for (KEY in methods) {\n if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {\n redefine(IterablePrototype, KEY, methods[KEY]);\n }\n } else $({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);\n }\n\n // define iterator\n if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {\n redefine(IterablePrototype, ITERATOR, defaultIterator, { name: DEFAULT });\n }\n Iterators[NAME] = defaultIterator;\n\n return methods;\n};\n","var path = require('../internals/path');\nvar hasOwn = require('../internals/has-own-property');\nvar wrappedWellKnownSymbolModule = require('../internals/well-known-symbol-wrapped');\nvar defineProperty = require('../internals/object-define-property').f;\n\nmodule.exports = function (NAME) {\n var Symbol = path.Symbol || (path.Symbol = {});\n if (!hasOwn(Symbol, NAME)) defineProperty(Symbol, NAME, {\n value: wrappedWellKnownSymbolModule.f(NAME)\n });\n};\n","var fails = require('../internals/fails');\n\n// Detect IE8's incomplete defineProperty implementation\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;\n});\n","var global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n","module.exports = {\n IndexSizeError: { s: 'INDEX_SIZE_ERR', c: 1, m: 1 },\n DOMStringSizeError: { s: 'DOMSTRING_SIZE_ERR', c: 2, m: 0 },\n HierarchyRequestError: { s: 'HIERARCHY_REQUEST_ERR', c: 3, m: 1 },\n WrongDocumentError: { s: 'WRONG_DOCUMENT_ERR', c: 4, m: 1 },\n InvalidCharacterError: { s: 'INVALID_CHARACTER_ERR', c: 5, m: 1 },\n NoDataAllowedError: { s: 'NO_DATA_ALLOWED_ERR', c: 6, m: 0 },\n NoModificationAllowedError: { s: 'NO_MODIFICATION_ALLOWED_ERR', c: 7, m: 1 },\n NotFoundError: { s: 'NOT_FOUND_ERR', c: 8, m: 1 },\n NotSupportedError: { s: 'NOT_SUPPORTED_ERR', c: 9, m: 1 },\n InUseAttributeError: { s: 'INUSE_ATTRIBUTE_ERR', c: 10, m: 1 },\n InvalidStateError: { s: 'INVALID_STATE_ERR', c: 11, m: 1 },\n SyntaxError: { s: 'SYNTAX_ERR', c: 12, m: 1 },\n InvalidModificationError: { s: 'INVALID_MODIFICATION_ERR', c: 13, m: 1 },\n NamespaceError: { s: 'NAMESPACE_ERR', c: 14, m: 1 },\n InvalidAccessError: { s: 'INVALID_ACCESS_ERR', c: 15, m: 1 },\n ValidationError: { s: 'VALIDATION_ERR', c: 16, m: 0 },\n TypeMismatchError: { s: 'TYPE_MISMATCH_ERR', c: 17, m: 1 },\n SecurityError: { s: 'SECURITY_ERR', c: 18, m: 1 },\n NetworkError: { s: 'NETWORK_ERR', c: 19, m: 1 },\n AbortError: { s: 'ABORT_ERR', c: 20, m: 1 },\n URLMismatchError: { s: 'URL_MISMATCH_ERR', c: 21, m: 1 },\n QuotaExceededError: { s: 'QUOTA_EXCEEDED_ERR', c: 22, m: 1 },\n TimeoutError: { s: 'TIMEOUT_ERR', c: 23, m: 1 },\n InvalidNodeTypeError: { s: 'INVALID_NODE_TYPE_ERR', c: 24, m: 1 },\n DataCloneError: { s: 'DATA_CLONE_ERR', c: 25, m: 1 }\n};\n","// iterable DOM collections\n// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods\nmodule.exports = {\n CSSRuleList: 0,\n CSSStyleDeclaration: 0,\n CSSValueList: 0,\n ClientRectList: 0,\n DOMRectList: 0,\n DOMStringList: 0,\n DOMTokenList: 1,\n DataTransferItemList: 0,\n FileList: 0,\n HTMLAllCollection: 0,\n HTMLCollection: 0,\n HTMLFormElement: 0,\n HTMLSelectElement: 0,\n MediaList: 0,\n MimeTypeArray: 0,\n NamedNodeMap: 0,\n NodeList: 1,\n PaintRequestList: 0,\n Plugin: 0,\n PluginArray: 0,\n SVGLengthList: 0,\n SVGNumberList: 0,\n SVGPathSegList: 0,\n SVGPointList: 0,\n SVGStringList: 0,\n SVGTransformList: 0,\n SourceBufferList: 0,\n StyleSheetList: 0,\n TextTrackCueList: 0,\n TextTrackList: 0,\n TouchList: 0\n};\n","// in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`\nvar documentCreateElement = require('../internals/document-create-element');\n\nvar classList = documentCreateElement('span').classList;\nvar DOMTokenListPrototype = classList && classList.constructor && classList.constructor.prototype;\n\nmodule.exports = DOMTokenListPrototype === Object.prototype ? undefined : DOMTokenListPrototype;\n","module.exports = typeof window == 'object';\n","var userAgent = require('../internals/engine-user-agent');\nvar global = require('../internals/global');\n\nmodule.exports = /ipad|iphone|ipod/i.test(userAgent) && global.Pebble !== undefined;\n","var userAgent = require('../internals/engine-user-agent');\n\nmodule.exports = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent);\n","var classof = require('../internals/classof-raw');\nvar global = require('../internals/global');\n\nmodule.exports = classof(global.process) == 'process';\n","var userAgent = require('../internals/engine-user-agent');\n\nmodule.exports = /web0s(?!.*chrome)/i.test(userAgent);\n","var getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('navigator', 'userAgent') || '';\n","var global = require('../internals/global');\nvar userAgent = require('../internals/engine-user-agent');\n\nvar process = global.process;\nvar Deno = global.Deno;\nvar versions = process && process.versions || Deno && Deno.version;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n // in old Chrome, versions of V8 isn't V8 = Chrome / 10\n // but their correct versions are not interesting for us\n version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);\n}\n\n// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`\n// so check `userAgent` even if `.v8` exists, but 0\nif (!version && userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = +match[1];\n }\n}\n\nmodule.exports = version;\n","// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n","var fails = require('../internals/fails');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = !fails(function () {\n var error = Error('a');\n if (!('stack' in error)) return true;\n // eslint-disable-next-line es/no-object-defineproperty -- safe\n Object.defineProperty(error, 'stack', createPropertyDescriptor(1, 7));\n return error.stack !== 7;\n});\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\nvar anObject = require('../internals/an-object');\nvar create = require('../internals/object-create');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\n\nvar nativeErrorToString = Error.prototype.toString;\n\nvar INCORRECT_TO_STRING = fails(function () {\n if (DESCRIPTORS) {\n // Chrome 32- incorrectly call accessor\n // eslint-disable-next-line es/no-object-defineproperty -- safe\n var object = create(Object.defineProperty({}, 'name', { get: function () {\n return this === object;\n } }));\n if (nativeErrorToString.call(object) !== 'true') return true;\n }\n // FF10- does not properly handle non-strings\n return nativeErrorToString.call({ message: 1, name: 2 }) !== '2: 1'\n // IE8 does not properly handle defaults\n || nativeErrorToString.call({}) !== 'Error';\n});\n\nmodule.exports = INCORRECT_TO_STRING ? function toString() {\n var O = anObject(this);\n var name = normalizeStringArgument(O.name, 'Error');\n var message = normalizeStringArgument(O.message);\n return !name ? message : !message ? name : name + ': ' + message;\n} : nativeErrorToString;\n","var global = require('../internals/global');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar redefine = require('../internals/redefine');\nvar setGlobal = require('../internals/set-global');\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\nvar isForced = require('../internals/is-forced');\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.noTargetGet - prevent calling a getter on target\n options.name - the .name of the function if it does not match the key\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var FORCED, target, key, targetProperty, sourceProperty, descriptor;\n if (GLOBAL) {\n target = global;\n } else if (STATIC) {\n target = global[TARGET] || setGlobal(TARGET, {});\n } else {\n target = (global[TARGET] || {}).prototype;\n }\n if (target) for (key in source) {\n sourceProperty = source[key];\n if (options.noTargetGet) {\n descriptor = getOwnPropertyDescriptor(target, key);\n targetProperty = descriptor && descriptor.value;\n } else targetProperty = target[key];\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contained in target\n if (!FORCED && targetProperty !== undefined) {\n if (typeof sourceProperty == typeof targetProperty) continue;\n copyConstructorProperties(sourceProperty, targetProperty);\n }\n // add a flag to not completely full polyfills\n if (options.sham || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(sourceProperty, 'sham', true);\n }\n // extend global\n redefine(target, key, sourceProperty, options);\n }\n};\n","module.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n","'use strict';\n// TODO: Remove from `core-js@4` since it's moved to entry points\nrequire('../modules/es.regexp.exec');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar redefine = require('../internals/redefine');\nvar regexpExec = require('../internals/regexp-exec');\nvar fails = require('../internals/fails');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\nvar SPECIES = wellKnownSymbol('species');\nvar RegExpPrototype = RegExp.prototype;\n\nmodule.exports = function (KEY, exec, FORCED, SHAM) {\n var SYMBOL = wellKnownSymbol(KEY);\n\n var DELEGATES_TO_SYMBOL = !fails(function () {\n // String methods call symbol-named RegEp methods\n var O = {};\n O[SYMBOL] = function () { return 7; };\n return ''[KEY](O) != 7;\n });\n\n var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {\n // Symbol-named RegExp methods call .exec\n var execCalled = false;\n var re = /a/;\n\n if (KEY === 'split') {\n // We can't use real regex here since it causes deoptimization\n // and serious performance degradation in V8\n // https://github.com/zloirock/core-js/issues/306\n re = {};\n // RegExp[@@split] doesn't call the regex's exec method, but first creates\n // a new one. We need to return the patched regex when creating the new one.\n re.constructor = {};\n re.constructor[SPECIES] = function () { return re; };\n re.flags = '';\n re[SYMBOL] = /./[SYMBOL];\n }\n\n re.exec = function () { execCalled = true; return null; };\n\n re[SYMBOL]('');\n return !execCalled;\n });\n\n if (\n !DELEGATES_TO_SYMBOL ||\n !DELEGATES_TO_EXEC ||\n FORCED\n ) {\n var uncurriedNativeRegExpMethod = uncurryThis(/./[SYMBOL]);\n var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {\n var uncurriedNativeMethod = uncurryThis(nativeMethod);\n var $exec = regexp.exec;\n if ($exec === regexpExec || $exec === RegExpPrototype.exec) {\n if (DELEGATES_TO_SYMBOL && !forceStringMethod) {\n // The native String method already delegates to @@method (this\n // polyfilled function), leasing to infinite recursion.\n // We avoid it by directly calling the native @@method method.\n return { done: true, value: uncurriedNativeRegExpMethod(regexp, str, arg2) };\n }\n return { done: true, value: uncurriedNativeMethod(str, regexp, arg2) };\n }\n return { done: false };\n });\n\n redefine(String.prototype, KEY, methods[0]);\n redefine(RegExpPrototype, SYMBOL, methods[1]);\n }\n\n if (SHAM) createNonEnumerableProperty(RegExpPrototype[SYMBOL], 'sham', true);\n};\n","var fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-object-isextensible, es/no-object-preventextensions -- required for testing\n return Object.isExtensible(Object.preventExtensions({}));\n});\n","var FunctionPrototype = Function.prototype;\nvar apply = FunctionPrototype.apply;\nvar bind = FunctionPrototype.bind;\nvar call = FunctionPrototype.call;\n\n// eslint-disable-next-line es/no-reflect -- safe\nmodule.exports = typeof Reflect == 'object' && Reflect.apply || (bind ? call.bind(apply) : function () {\n return call.apply(apply, arguments);\n});\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar aCallable = require('../internals/a-callable');\n\nvar bind = uncurryThis(uncurryThis.bind);\n\n// optional / simple context binding\nmodule.exports = function (fn, that) {\n aCallable(fn);\n return that === undefined ? fn : bind ? bind(fn, that) : function (/* ...args */) {\n return fn.apply(that, arguments);\n };\n};\n","var call = Function.prototype.call;\n\nmodule.exports = call.bind ? call.bind(call) : function () {\n return call.apply(call, arguments);\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar hasOwn = require('../internals/has-own-property');\n\nvar FunctionPrototype = Function.prototype;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;\n\nvar EXISTS = hasOwn(FunctionPrototype, 'name');\n// additional protection from minified / mangled / dropped function names\nvar PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';\nvar CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));\n\nmodule.exports = {\n EXISTS: EXISTS,\n PROPER: PROPER,\n CONFIGURABLE: CONFIGURABLE\n};\n","var FunctionPrototype = Function.prototype;\nvar bind = FunctionPrototype.bind;\nvar call = FunctionPrototype.call;\nvar uncurryThis = bind && bind.bind(call, call);\n\nmodule.exports = bind ? function (fn) {\n return fn && uncurryThis(fn);\n} : function (fn) {\n return fn && function () {\n return call.apply(fn, arguments);\n };\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar aFunction = function (argument) {\n return isCallable(argument) ? argument : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method];\n};\n","var classof = require('../internals/classof');\nvar getMethod = require('../internals/get-method');\nvar Iterators = require('../internals/iterators');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\n\nmodule.exports = function (it) {\n if (it != undefined) return getMethod(it, ITERATOR)\n || getMethod(it, '@@iterator')\n || Iterators[classof(it)];\n};\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nvar TypeError = global.TypeError;\n\nmodule.exports = function (argument, usingIterator) {\n var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;\n if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument));\n throw TypeError(tryToString(argument) + ' is not iterable');\n};\n","var aCallable = require('../internals/a-callable');\n\n// `GetMethod` abstract operation\n// https://tc39.es/ecma262/#sec-getmethod\nmodule.exports = function (V, P) {\n var func = V[P];\n return func == null ? undefined : aCallable(func);\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar floor = Math.floor;\nvar charAt = uncurryThis(''.charAt);\nvar replace = uncurryThis(''.replace);\nvar stringSlice = uncurryThis(''.slice);\nvar SUBSTITUTION_SYMBOLS = /\\$([$&'`]|\\d{1,2}|<[^>]*>)/g;\nvar SUBSTITUTION_SYMBOLS_NO_NAMED = /\\$([$&'`]|\\d{1,2})/g;\n\n// `GetSubstitution` abstract operation\n// https://tc39.es/ecma262/#sec-getsubstitution\nmodule.exports = function (matched, str, position, captures, namedCaptures, replacement) {\n var tailPos = position + matched.length;\n var m = captures.length;\n var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;\n if (namedCaptures !== undefined) {\n namedCaptures = toObject(namedCaptures);\n symbols = SUBSTITUTION_SYMBOLS;\n }\n return replace(replacement, symbols, function (match, ch) {\n var capture;\n switch (charAt(ch, 0)) {\n case '$': return '$';\n case '&': return matched;\n case '`': return stringSlice(str, 0, position);\n case \"'\": return stringSlice(str, tailPos);\n case '<':\n capture = namedCaptures[stringSlice(ch, 1, -1)];\n break;\n default: // \\d\\d?\n var n = +ch;\n if (n === 0) return match;\n if (n > m) {\n var f = floor(n / 10);\n if (f === 0) return match;\n if (f <= m) return captures[f - 1] === undefined ? charAt(ch, 1) : captures[f - 1] + charAt(ch, 1);\n return match;\n }\n capture = captures[n - 1];\n }\n return capture === undefined ? '' : capture;\n });\n};\n","var check = function (it) {\n return it && it.Math == Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line es/no-global-this -- safe\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n // eslint-disable-next-line no-restricted-globals -- safe\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n // eslint-disable-next-line no-new-func -- fallback\n (function () { return this; })() || Function('return this')();\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar hasOwnProperty = uncurryThis({}.hasOwnProperty);\n\n// `HasOwnProperty` abstract operation\n// https://tc39.es/ecma262/#sec-hasownproperty\nmodule.exports = Object.hasOwn || function hasOwn(it, key) {\n return hasOwnProperty(toObject(it), key);\n};\n","module.exports = {};\n","var global = require('../internals/global');\n\nmodule.exports = function (a, b) {\n var console = global.console;\n if (console && console.error) {\n arguments.length == 1 ? console.error(a) : console.error(a, b);\n }\n};\n","var getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('document', 'documentElement');\n","var DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\nvar createElement = require('../internals/document-create-element');\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a != 7;\n});\n","var global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar classof = require('../internals/classof-raw');\n\nvar Object = global.Object;\nvar split = uncurryThis(''.split);\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins -- safe\n return !Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) == 'String' ? split(it, '') : Object(it);\n} : Object;\n","var isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\n\n// makes subclassing work correct for wrapped built-ins\nmodule.exports = function ($this, dummy, Wrapper) {\n var NewTarget, NewTargetPrototype;\n if (\n // it can work only with native `setPrototypeOf`\n setPrototypeOf &&\n // we haven't completely correct pre-ES6 way for getting `new.target`, so use this\n isCallable(NewTarget = dummy.constructor) &&\n NewTarget !== Wrapper &&\n isObject(NewTargetPrototype = NewTarget.prototype) &&\n NewTargetPrototype !== Wrapper.prototype\n ) setPrototypeOf($this, NewTargetPrototype);\n return $this;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar isCallable = require('../internals/is-callable');\nvar store = require('../internals/shared-store');\n\nvar functionToString = uncurryThis(Function.toString);\n\n// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper\nif (!isCallable(store.inspectSource)) {\n store.inspectSource = function (it) {\n return functionToString(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n","var isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\n// `InstallErrorCause` abstract operation\n// https://tc39.es/proposal-error-cause/#sec-errorobjects-install-error-cause\nmodule.exports = function (O, options) {\n if (isObject(options) && 'cause' in options) {\n createNonEnumerableProperty(O, 'cause', options.cause);\n }\n};\n","var $ = require('../internals/export');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar isObject = require('../internals/is-object');\nvar hasOwn = require('../internals/has-own-property');\nvar defineProperty = require('../internals/object-define-property').f;\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertyNamesExternalModule = require('../internals/object-get-own-property-names-external');\nvar isExtensible = require('../internals/object-is-extensible');\nvar uid = require('../internals/uid');\nvar FREEZING = require('../internals/freezing');\n\nvar REQUIRED = false;\nvar METADATA = uid('meta');\nvar id = 0;\n\nvar setMetadata = function (it) {\n defineProperty(it, METADATA, { value: {\n objectID: 'O' + id++, // object ID\n weakData: {} // weak collections IDs\n } });\n};\n\nvar fastKey = function (it, create) {\n // return a primitive with prefix\n if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;\n if (!hasOwn(it, METADATA)) {\n // can't set metadata to uncaught frozen object\n if (!isExtensible(it)) return 'F';\n // not necessary to add metadata\n if (!create) return 'E';\n // add missing metadata\n setMetadata(it);\n // return object ID\n } return it[METADATA].objectID;\n};\n\nvar getWeakData = function (it, create) {\n if (!hasOwn(it, METADATA)) {\n // can't set metadata to uncaught frozen object\n if (!isExtensible(it)) return true;\n // not necessary to add metadata\n if (!create) return false;\n // add missing metadata\n setMetadata(it);\n // return the store of weak collections IDs\n } return it[METADATA].weakData;\n};\n\n// add metadata on freeze-family methods calling\nvar onFreeze = function (it) {\n if (FREEZING && REQUIRED && isExtensible(it) && !hasOwn(it, METADATA)) setMetadata(it);\n return it;\n};\n\nvar enable = function () {\n meta.enable = function () { /* empty */ };\n REQUIRED = true;\n var getOwnPropertyNames = getOwnPropertyNamesModule.f;\n var splice = uncurryThis([].splice);\n var test = {};\n test[METADATA] = 1;\n\n // prevent exposing of metadata key\n if (getOwnPropertyNames(test).length) {\n getOwnPropertyNamesModule.f = function (it) {\n var result = getOwnPropertyNames(it);\n for (var i = 0, length = result.length; i < length; i++) {\n if (result[i] === METADATA) {\n splice(result, i, 1);\n break;\n }\n } return result;\n };\n\n $({ target: 'Object', stat: true, forced: true }, {\n getOwnPropertyNames: getOwnPropertyNamesExternalModule.f\n });\n }\n};\n\nvar meta = module.exports = {\n enable: enable,\n fastKey: fastKey,\n getWeakData: getWeakData,\n onFreeze: onFreeze\n};\n\nhiddenKeys[METADATA] = true;\n","var NATIVE_WEAK_MAP = require('../internals/native-weak-map');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\nvar shared = require('../internals/shared-store');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar OBJECT_ALREADY_INITIALIZED = 'Object already initialized';\nvar TypeError = global.TypeError;\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP || shared.state) {\n var store = shared.state || (shared.state = new WeakMap());\n var wmget = uncurryThis(store.get);\n var wmhas = uncurryThis(store.has);\n var wmset = uncurryThis(store.set);\n set = function (it, metadata) {\n if (wmhas(store, it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n wmset(store, it, metadata);\n return metadata;\n };\n get = function (it) {\n return wmget(store, it) || {};\n };\n has = function (it) {\n return wmhas(store, it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return hasOwn(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return hasOwn(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar ArrayPrototype = Array.prototype;\n\n// check on default Array iterator\nmodule.exports = function (it) {\n return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);\n};\n","var classof = require('../internals/classof-raw');\n\n// `IsArray` abstract operation\n// https://tc39.es/ecma262/#sec-isarray\n// eslint-disable-next-line es/no-array-isarray -- safe\nmodule.exports = Array.isArray || function isArray(argument) {\n return classof(argument) == 'Array';\n};\n","// `IsCallable` abstract operation\n// https://tc39.es/ecma262/#sec-iscallable\nmodule.exports = function (argument) {\n return typeof argument == 'function';\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar classof = require('../internals/classof');\nvar getBuiltIn = require('../internals/get-built-in');\nvar inspectSource = require('../internals/inspect-source');\n\nvar noop = function () { /* empty */ };\nvar empty = [];\nvar construct = getBuiltIn('Reflect', 'construct');\nvar constructorRegExp = /^\\s*(?:class|function)\\b/;\nvar exec = uncurryThis(constructorRegExp.exec);\nvar INCORRECT_TO_STRING = !constructorRegExp.exec(noop);\n\nvar isConstructorModern = function isConstructor(argument) {\n if (!isCallable(argument)) return false;\n try {\n construct(noop, empty, argument);\n return true;\n } catch (error) {\n return false;\n }\n};\n\nvar isConstructorLegacy = function isConstructor(argument) {\n if (!isCallable(argument)) return false;\n switch (classof(argument)) {\n case 'AsyncFunction':\n case 'GeneratorFunction':\n case 'AsyncGeneratorFunction': return false;\n }\n try {\n // we can't check .prototype since constructors produced by .bind haven't it\n // `Function#toString` throws on some built-it function in some legacy engines\n // (for example, `DOMQuad` and similar in FF41-)\n return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource(argument));\n } catch (error) {\n return true;\n }\n};\n\nisConstructorLegacy.sham = true;\n\n// `IsConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-isconstructor\nmodule.exports = !construct || fails(function () {\n var called;\n return isConstructorModern(isConstructorModern.call)\n || !isConstructorModern(Object)\n || !isConstructorModern(function () { called = true; })\n || called;\n}) ? isConstructorLegacy : isConstructorModern;\n","var fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value == POLYFILL ? true\n : value == NATIVE ? false\n : isCallable(detection) ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n","var isCallable = require('../internals/is-callable');\n\nmodule.exports = function (it) {\n return typeof it == 'object' ? it !== null : isCallable(it);\n};\n","module.exports = false;\n","var isObject = require('../internals/is-object');\nvar classof = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar MATCH = wellKnownSymbol('match');\n\n// `IsRegExp` abstract operation\n// https://tc39.es/ecma262/#sec-isregexp\nmodule.exports = function (it) {\n var isRegExp;\n return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classof(it) == 'RegExp');\n};\n","var global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar Object = global.Object;\n\nmodule.exports = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n var $Symbol = getBuiltIn('Symbol');\n return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, Object(it));\n};\n","var global = require('../internals/global');\nvar bind = require('../internals/function-bind-context');\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar isArrayIteratorMethod = require('../internals/is-array-iterator-method');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar getIterator = require('../internals/get-iterator');\nvar getIteratorMethod = require('../internals/get-iterator-method');\nvar iteratorClose = require('../internals/iterator-close');\n\nvar TypeError = global.TypeError;\n\nvar Result = function (stopped, result) {\n this.stopped = stopped;\n this.result = result;\n};\n\nvar ResultPrototype = Result.prototype;\n\nmodule.exports = function (iterable, unboundFunction, options) {\n var that = options && options.that;\n var AS_ENTRIES = !!(options && options.AS_ENTRIES);\n var IS_ITERATOR = !!(options && options.IS_ITERATOR);\n var INTERRUPTED = !!(options && options.INTERRUPTED);\n var fn = bind(unboundFunction, that);\n var iterator, iterFn, index, length, result, next, step;\n\n var stop = function (condition) {\n if (iterator) iteratorClose(iterator, 'normal', condition);\n return new Result(true, condition);\n };\n\n var callFn = function (value) {\n if (AS_ENTRIES) {\n anObject(value);\n return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);\n } return INTERRUPTED ? fn(value, stop) : fn(value);\n };\n\n if (IS_ITERATOR) {\n iterator = iterable;\n } else {\n iterFn = getIteratorMethod(iterable);\n if (!iterFn) throw TypeError(tryToString(iterable) + ' is not iterable');\n // optimisation for array iterators\n if (isArrayIteratorMethod(iterFn)) {\n for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {\n result = callFn(iterable[index]);\n if (result && isPrototypeOf(ResultPrototype, result)) return result;\n } return new Result(false);\n }\n iterator = getIterator(iterable, iterFn);\n }\n\n next = iterator.next;\n while (!(step = call(next, iterator)).done) {\n try {\n result = callFn(step.value);\n } catch (error) {\n iteratorClose(iterator, 'throw', error);\n }\n if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;\n } return new Result(false);\n};\n","var call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar getMethod = require('../internals/get-method');\n\nmodule.exports = function (iterator, kind, value) {\n var innerResult, innerError;\n anObject(iterator);\n try {\n innerResult = getMethod(iterator, 'return');\n if (!innerResult) {\n if (kind === 'throw') throw value;\n return value;\n }\n innerResult = call(innerResult, iterator);\n } catch (error) {\n innerError = true;\n innerResult = error;\n }\n if (kind === 'throw') throw value;\n if (innerError) throw innerResult;\n anObject(innerResult);\n return value;\n};\n","'use strict';\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar create = require('../internals/object-create');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar redefine = require('../internals/redefine');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IS_PURE = require('../internals/is-pure');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false;\n\n// `%IteratorPrototype%` object\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-object\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n\n/* eslint-disable es/no-array-prototype-keys -- safe */\nif ([].keys) {\n arrayIterator = [].keys();\n // Safari 8 has buggy iterators w/o `next`\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;\n else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nvar NEW_ITERATOR_PROTOTYPE = IteratorPrototype == undefined || fails(function () {\n var test = {};\n // FF44- legacy iterators case\n return IteratorPrototype[ITERATOR].call(test) !== test;\n});\n\nif (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};\nelse if (IS_PURE) IteratorPrototype = create(IteratorPrototype);\n\n// `%IteratorPrototype%[@@iterator]()` method\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator\nif (!isCallable(IteratorPrototype[ITERATOR])) {\n redefine(IteratorPrototype, ITERATOR, function () {\n return this;\n });\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};\n","module.exports = {};\n","var toLength = require('../internals/to-length');\n\n// `LengthOfArrayLike` abstract operation\n// https://tc39.es/ecma262/#sec-lengthofarraylike\nmodule.exports = function (obj) {\n return toLength(obj.length);\n};\n","var log = Math.log;\nvar LOG10E = Math.LOG10E;\n\n// eslint-disable-next-line es/no-math-log10 -- safe\nmodule.exports = Math.log10 || function log10(x) {\n return log(x) * LOG10E;\n};\n","// `Math.sign` method implementation\n// https://tc39.es/ecma262/#sec-math.sign\n// eslint-disable-next-line es/no-math-sign -- safe\nmodule.exports = Math.sign || function sign(x) {\n // eslint-disable-next-line no-self-compare -- NaN check\n return (x = +x) == 0 || x != x ? x : x < 0 ? -1 : 1;\n};\n","var global = require('../internals/global');\nvar bind = require('../internals/function-bind-context');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar macrotask = require('../internals/task').set;\nvar IS_IOS = require('../internals/engine-is-ios');\nvar IS_IOS_PEBBLE = require('../internals/engine-is-ios-pebble');\nvar IS_WEBOS_WEBKIT = require('../internals/engine-is-webos-webkit');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar MutationObserver = global.MutationObserver || global.WebKitMutationObserver;\nvar document = global.document;\nvar process = global.process;\nvar Promise = global.Promise;\n// Node.js 11 shows ExperimentalWarning on getting `queueMicrotask`\nvar queueMicrotaskDescriptor = getOwnPropertyDescriptor(global, 'queueMicrotask');\nvar queueMicrotask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;\n\nvar flush, head, last, notify, toggle, node, promise, then;\n\n// modern engines have queueMicrotask method\nif (!queueMicrotask) {\n flush = function () {\n var parent, fn;\n if (IS_NODE && (parent = process.domain)) parent.exit();\n while (head) {\n fn = head.fn;\n head = head.next;\n try {\n fn();\n } catch (error) {\n if (head) notify();\n else last = undefined;\n throw error;\n }\n } last = undefined;\n if (parent) parent.enter();\n };\n\n // browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339\n // also except WebOS Webkit https://github.com/zloirock/core-js/issues/898\n if (!IS_IOS && !IS_NODE && !IS_WEBOS_WEBKIT && MutationObserver && document) {\n toggle = true;\n node = document.createTextNode('');\n new MutationObserver(flush).observe(node, { characterData: true });\n notify = function () {\n node.data = toggle = !toggle;\n };\n // environments with maybe non-completely correct, but existent Promise\n } else if (!IS_IOS_PEBBLE && Promise && Promise.resolve) {\n // Promise.resolve without an argument throws an error in LG WebOS 2\n promise = Promise.resolve(undefined);\n // workaround of WebKit ~ iOS Safari 10.1 bug\n promise.constructor = Promise;\n then = bind(promise.then, promise);\n notify = function () {\n then(flush);\n };\n // Node.js without promises\n } else if (IS_NODE) {\n notify = function () {\n process.nextTick(flush);\n };\n // for other environments - macrotask based on:\n // - setImmediate\n // - MessageChannel\n // - window.postMessag\n // - onreadystatechange\n // - setTimeout\n } else {\n // strange IE + webpack dev server bug - use .bind(global)\n macrotask = bind(macrotask, global);\n notify = function () {\n macrotask(flush);\n };\n }\n}\n\nmodule.exports = queueMicrotask || function (fn) {\n var task = { fn: fn, next: undefined };\n if (last) last.next = task;\n if (!head) {\n head = task;\n notify();\n } last = task;\n};\n","var global = require('../internals/global');\n\nmodule.exports = global.Promise;\n","/* eslint-disable es/no-symbol -- required for testing */\nvar V8_VERSION = require('../internals/engine-v8-version');\nvar fails = require('../internals/fails');\n\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n var symbol = Symbol();\n // Chrome 38 Symbol has incorrect toString conversion\n // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances\n return !String(symbol) || !(Object(symbol) instanceof Symbol) ||\n // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances\n !Symbol.sham && V8_VERSION && V8_VERSION < 41;\n});\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar inspectSource = require('../internals/inspect-source');\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = isCallable(WeakMap) && /native code/.test(inspectSource(WeakMap));\n","'use strict';\nvar aCallable = require('../internals/a-callable');\n\nvar PromiseCapability = function (C) {\n var resolve, reject;\n this.promise = new C(function ($$resolve, $$reject) {\n if (resolve !== undefined || reject !== undefined) throw TypeError('Bad Promise constructor');\n resolve = $$resolve;\n reject = $$reject;\n });\n this.resolve = aCallable(resolve);\n this.reject = aCallable(reject);\n};\n\n// `NewPromiseCapability` abstract operation\n// https://tc39.es/ecma262/#sec-newpromisecapability\nmodule.exports.f = function (C) {\n return new PromiseCapability(C);\n};\n","var toString = require('../internals/to-string');\n\nmodule.exports = function (argument, $default) {\n return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);\n};\n","var global = require('../internals/global');\nvar isRegExp = require('../internals/is-regexp');\n\nvar TypeError = global.TypeError;\n\nmodule.exports = function (it) {\n if (isRegExp(it)) {\n throw TypeError(\"The method doesn't accept regular expressions\");\n } return it;\n};\n","var global = require('../internals/global');\n\nvar globalIsFinite = global.isFinite;\n\n// `Number.isFinite` method\n// https://tc39.es/ecma262/#sec-number.isfinite\n// eslint-disable-next-line es/no-number-isfinite -- safe\nmodule.exports = Number.isFinite || function isFinite(it) {\n return typeof it == 'number' && globalIsFinite(it);\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar call = require('../internals/function-call');\nvar fails = require('../internals/fails');\nvar objectKeys = require('../internals/object-keys');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar toObject = require('../internals/to-object');\nvar IndexedObject = require('../internals/indexed-object');\n\n// eslint-disable-next-line es/no-object-assign -- safe\nvar $assign = Object.assign;\n// eslint-disable-next-line es/no-object-defineproperty -- required for testing\nvar defineProperty = Object.defineProperty;\nvar concat = uncurryThis([].concat);\n\n// `Object.assign` method\n// https://tc39.es/ecma262/#sec-object.assign\nmodule.exports = !$assign || fails(function () {\n // should have correct order of operations (Edge bug)\n if (DESCRIPTORS && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {\n enumerable: true,\n get: function () {\n defineProperty(this, 'b', {\n value: 3,\n enumerable: false\n });\n }\n }), { b: 2 })).b !== 1) return true;\n // should work with symbols and should have deterministic property order (V8 bug)\n var A = {};\n var B = {};\n // eslint-disable-next-line es/no-symbol -- safe\n var symbol = Symbol();\n var alphabet = 'abcdefghijklmnopqrst';\n A[symbol] = 7;\n alphabet.split('').forEach(function (chr) { B[chr] = chr; });\n return $assign({}, A)[symbol] != 7 || objectKeys($assign({}, B)).join('') != alphabet;\n}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`\n var T = toObject(target);\n var argumentsLength = arguments.length;\n var index = 1;\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n var propertyIsEnumerable = propertyIsEnumerableModule.f;\n while (argumentsLength > index) {\n var S = IndexedObject(arguments[index++]);\n var keys = getOwnPropertySymbols ? concat(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);\n var length = keys.length;\n var j = 0;\n var key;\n while (length > j) {\n key = keys[j++];\n if (!DESCRIPTORS || call(propertyIsEnumerable, S, key)) T[key] = S[key];\n }\n } return T;\n} : $assign;\n","/* global ActiveXObject -- old IE, WSH */\nvar anObject = require('../internals/an-object');\nvar definePropertiesModule = require('../internals/object-define-properties');\nvar enumBugKeys = require('../internals/enum-bug-keys');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar html = require('../internals/html');\nvar documentCreateElement = require('../internals/document-create-element');\nvar sharedKey = require('../internals/shared-key');\n\nvar GT = '>';\nvar LT = '<';\nvar PROTOTYPE = 'prototype';\nvar SCRIPT = 'script';\nvar IE_PROTO = sharedKey('IE_PROTO');\n\nvar EmptyConstructor = function () { /* empty */ };\n\nvar scriptTag = function (content) {\n return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;\n};\n\n// Create object with fake `null` prototype: use ActiveX Object with cleared prototype\nvar NullProtoObjectViaActiveX = function (activeXDocument) {\n activeXDocument.write(scriptTag(''));\n activeXDocument.close();\n var temp = activeXDocument.parentWindow.Object;\n activeXDocument = null; // avoid memory leak\n return temp;\n};\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar NullProtoObjectViaIFrame = function () {\n // Thrash, waste and sodomy: IE GC bug\n var iframe = documentCreateElement('iframe');\n var JS = 'java' + SCRIPT + ':';\n var iframeDocument;\n iframe.style.display = 'none';\n html.appendChild(iframe);\n // https://github.com/zloirock/core-js/issues/475\n iframe.src = String(JS);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(scriptTag('document.F=Object'));\n iframeDocument.close();\n return iframeDocument.F;\n};\n\n// Check for document.domain and active x support\n// No need to use active x approach when document.domain is not set\n// see https://github.com/es-shims/es5-shim/issues/150\n// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346\n// avoid IE GC bug\nvar activeXDocument;\nvar NullProtoObject = function () {\n try {\n activeXDocument = new ActiveXObject('htmlfile');\n } catch (error) { /* ignore */ }\n NullProtoObject = typeof document != 'undefined'\n ? document.domain && activeXDocument\n ? NullProtoObjectViaActiveX(activeXDocument) // old IE\n : NullProtoObjectViaIFrame()\n : NullProtoObjectViaActiveX(activeXDocument); // WSH\n var length = enumBugKeys.length;\n while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];\n return NullProtoObject();\n};\n\nhiddenKeys[IE_PROTO] = true;\n\n// `Object.create` method\n// https://tc39.es/ecma262/#sec-object.create\nmodule.exports = Object.create || function create(O, Properties) {\n var result;\n if (O !== null) {\n EmptyConstructor[PROTOTYPE] = anObject(O);\n result = new EmptyConstructor();\n EmptyConstructor[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = NullProtoObject();\n return Properties === undefined ? result : definePropertiesModule.f(result, Properties);\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar definePropertyModule = require('../internals/object-define-property');\nvar anObject = require('../internals/an-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar objectKeys = require('../internals/object-keys');\n\n// `Object.defineProperties` method\n// https://tc39.es/ecma262/#sec-object.defineproperties\n// eslint-disable-next-line es/no-object-defineproperties -- safe\nexports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var props = toIndexedObject(Properties);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);\n return O;\n};\n","var global = require('../internals/global');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar anObject = require('../internals/an-object');\nvar toPropertyKey = require('../internals/to-property-key');\n\nvar TypeError = global.TypeError;\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar $defineProperty = Object.defineProperty;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar ENUMERABLE = 'enumerable';\nvar CONFIGURABLE = 'configurable';\nvar WRITABLE = 'writable';\n\n// `Object.defineProperty` method\n// https://tc39.es/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {\n var current = $getOwnPropertyDescriptor(O, P);\n if (current && current[WRITABLE]) {\n O[P] = Attributes.value;\n Attributes = {\n configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],\n enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],\n writable: false\n };\n }\n } return $defineProperty(O, P, Attributes);\n} : $defineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return $defineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar call = require('../internals/function-call');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar hasOwn = require('../internals/has-own-property');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\n\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPropertyKey(P);\n if (IE8_DOM_DEFINE) try {\n return $getOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);\n};\n","/* eslint-disable es/no-object-getownpropertynames -- safe */\nvar classof = require('../internals/classof-raw');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar $getOwnPropertyNames = require('../internals/object-get-own-property-names').f;\nvar arraySlice = require('../internals/array-slice-simple');\n\nvar windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames\n ? Object.getOwnPropertyNames(window) : [];\n\nvar getWindowNames = function (it) {\n try {\n return $getOwnPropertyNames(it);\n } catch (error) {\n return arraySlice(windowNames);\n }\n};\n\n// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window\nmodule.exports.f = function getOwnPropertyNames(it) {\n return windowNames && classof(it) == 'Window'\n ? getWindowNames(it)\n : $getOwnPropertyNames(toIndexedObject(it));\n};\n","var internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.es/ecma262/#sec-object.getownpropertynames\n// eslint-disable-next-line es/no-object-getownpropertynames -- safe\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n","// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe\nexports.f = Object.getOwnPropertySymbols;\n","var global = require('../internals/global');\nvar hasOwn = require('../internals/has-own-property');\nvar isCallable = require('../internals/is-callable');\nvar toObject = require('../internals/to-object');\nvar sharedKey = require('../internals/shared-key');\nvar CORRECT_PROTOTYPE_GETTER = require('../internals/correct-prototype-getter');\n\nvar IE_PROTO = sharedKey('IE_PROTO');\nvar Object = global.Object;\nvar ObjectPrototype = Object.prototype;\n\n// `Object.getPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.getprototypeof\nmodule.exports = CORRECT_PROTOTYPE_GETTER ? Object.getPrototypeOf : function (O) {\n var object = toObject(O);\n if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];\n var constructor = object.constructor;\n if (isCallable(constructor) && object instanceof constructor) {\n return constructor.prototype;\n } return object instanceof Object ? ObjectPrototype : null;\n};\n","var fails = require('../internals/fails');\nvar isObject = require('../internals/is-object');\nvar classof = require('../internals/classof-raw');\nvar ARRAY_BUFFER_NON_EXTENSIBLE = require('../internals/array-buffer-non-extensible');\n\n// eslint-disable-next-line es/no-object-isextensible -- safe\nvar $isExtensible = Object.isExtensible;\nvar FAILS_ON_PRIMITIVES = fails(function () { $isExtensible(1); });\n\n// `Object.isExtensible` method\n// https://tc39.es/ecma262/#sec-object.isextensible\nmodule.exports = (FAILS_ON_PRIMITIVES || ARRAY_BUFFER_NON_EXTENSIBLE) ? function isExtensible(it) {\n if (!isObject(it)) return false;\n if (ARRAY_BUFFER_NON_EXTENSIBLE && classof(it) == 'ArrayBuffer') return false;\n return $isExtensible ? $isExtensible(it) : true;\n} : $isExtensible;\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis({}.isPrototypeOf);\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar indexOf = require('../internals/array-includes').indexOf;\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (hasOwn(O, key = names[i++])) {\n ~indexOf(result, key) || push(result, key);\n }\n return result;\n};\n","var internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\n// `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n// eslint-disable-next-line es/no-object-keys -- safe\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};\n","'use strict';\nvar $propertyIsEnumerable = {}.propertyIsEnumerable;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : $propertyIsEnumerable;\n","/* eslint-disable no-proto -- safe */\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar anObject = require('../internals/an-object');\nvar aPossiblePrototype = require('../internals/a-possible-prototype');\n\n// `Object.setPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n// eslint-disable-next-line es/no-object-setprototypeof -- safe\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n setter = uncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n","var DESCRIPTORS = require('../internals/descriptors');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar objectKeys = require('../internals/object-keys');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar $propertyIsEnumerable = require('../internals/object-property-is-enumerable').f;\n\nvar propertyIsEnumerable = uncurryThis($propertyIsEnumerable);\nvar push = uncurryThis([].push);\n\n// `Object.{ entries, values }` methods implementation\nvar createMethod = function (TO_ENTRIES) {\n return function (it) {\n var O = toIndexedObject(it);\n var keys = objectKeys(O);\n var length = keys.length;\n var i = 0;\n var result = [];\n var key;\n while (length > i) {\n key = keys[i++];\n if (!DESCRIPTORS || propertyIsEnumerable(O, key)) {\n push(result, TO_ENTRIES ? [key, O[key]] : O[key]);\n }\n }\n return result;\n };\n};\n\nmodule.exports = {\n // `Object.entries` method\n // https://tc39.es/ecma262/#sec-object.entries\n entries: createMethod(true),\n // `Object.values` method\n // https://tc39.es/ecma262/#sec-object.values\n values: createMethod(false)\n};\n","'use strict';\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar classof = require('../internals/classof');\n\n// `Object.prototype.toString` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.tostring\nmodule.exports = TO_STRING_TAG_SUPPORT ? {}.toString : function toString() {\n return '[object ' + classof(this) + ']';\n};\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\n\nvar TypeError = global.TypeError;\n\n// `OrdinaryToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-ordinarytoprimitive\nmodule.exports = function (input, pref) {\n var fn, val;\n if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;\n if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n throw TypeError(\"Can't convert object to primitive value\");\n};\n","var getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar anObject = require('../internals/an-object');\n\nvar concat = uncurryThis([].concat);\n\n// all object keys, includes non-enumerable and symbols\nmodule.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {\n var keys = getOwnPropertyNamesModule.f(anObject(it));\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;\n};\n","var global = require('../internals/global');\n\nmodule.exports = global;\n","module.exports = function (exec) {\n try {\n return { error: false, value: exec() };\n } catch (error) {\n return { error: true, value: error };\n }\n};\n","var anObject = require('../internals/an-object');\nvar isObject = require('../internals/is-object');\nvar newPromiseCapability = require('../internals/new-promise-capability');\n\nmodule.exports = function (C, x) {\n anObject(C);\n if (isObject(x) && x.constructor === C) return x;\n var promiseCapability = newPromiseCapability.f(C);\n var resolve = promiseCapability.resolve;\n resolve(x);\n return promiseCapability.promise;\n};\n","var Queue = function () {\n this.head = null;\n this.tail = null;\n};\n\nQueue.prototype = {\n add: function (item) {\n var entry = { item: item, next: null };\n if (this.head) this.tail.next = entry;\n else this.head = entry;\n this.tail = entry;\n },\n get: function () {\n var entry = this.head;\n if (entry) {\n this.head = entry.next;\n if (this.tail === entry) this.tail = null;\n return entry.item;\n }\n }\n};\n\nmodule.exports = Queue;\n","var redefine = require('../internals/redefine');\n\nmodule.exports = function (target, src, options) {\n for (var key in src) redefine(target, key, src[key], options);\n return target;\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar hasOwn = require('../internals/has-own-property');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar setGlobal = require('../internals/set-global');\nvar inspectSource = require('../internals/inspect-source');\nvar InternalStateModule = require('../internals/internal-state');\nvar CONFIGURABLE_FUNCTION_NAME = require('../internals/function-name').CONFIGURABLE;\n\nvar getInternalState = InternalStateModule.get;\nvar enforceInternalState = InternalStateModule.enforce;\nvar TEMPLATE = String(String).split('String');\n\n(module.exports = function (O, key, value, options) {\n var unsafe = options ? !!options.unsafe : false;\n var simple = options ? !!options.enumerable : false;\n var noTargetGet = options ? !!options.noTargetGet : false;\n var name = options && options.name !== undefined ? options.name : key;\n var state;\n if (isCallable(value)) {\n if (String(name).slice(0, 7) === 'Symbol(') {\n name = '[' + String(name).replace(/^Symbol\\(([^)]*)\\)/, '$1') + ']';\n }\n if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {\n createNonEnumerableProperty(value, 'name', name);\n }\n state = enforceInternalState(value);\n if (!state.source) {\n state.source = TEMPLATE.join(typeof name == 'string' ? name : '');\n }\n }\n if (O === global) {\n if (simple) O[key] = value;\n else setGlobal(key, value);\n return;\n } else if (!unsafe) {\n delete O[key];\n } else if (!noTargetGet && O[key]) {\n simple = true;\n }\n if (simple) O[key] = value;\n else createNonEnumerableProperty(O, key, value);\n// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n})(Function.prototype, 'toString', function toString() {\n return isCallable(this) && getInternalState(this).source || inspectSource(this);\n});\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar isCallable = require('../internals/is-callable');\nvar classof = require('../internals/classof-raw');\nvar regexpExec = require('../internals/regexp-exec');\n\nvar TypeError = global.TypeError;\n\n// `RegExpExec` abstract operation\n// https://tc39.es/ecma262/#sec-regexpexec\nmodule.exports = function (R, S) {\n var exec = R.exec;\n if (isCallable(exec)) {\n var result = call(exec, R, S);\n if (result !== null) anObject(result);\n return result;\n }\n if (classof(R) === 'RegExp') return call(regexpExec, R, S);\n throw TypeError('RegExp#exec called on incompatible receiver');\n};\n","'use strict';\n/* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */\n/* eslint-disable regexp/no-useless-quantifier -- testing */\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toString = require('../internals/to-string');\nvar regexpFlags = require('../internals/regexp-flags');\nvar stickyHelpers = require('../internals/regexp-sticky-helpers');\nvar shared = require('../internals/shared');\nvar create = require('../internals/object-create');\nvar getInternalState = require('../internals/internal-state').get;\nvar UNSUPPORTED_DOT_ALL = require('../internals/regexp-unsupported-dot-all');\nvar UNSUPPORTED_NCG = require('../internals/regexp-unsupported-ncg');\n\nvar nativeReplace = shared('native-string-replace', String.prototype.replace);\nvar nativeExec = RegExp.prototype.exec;\nvar patchedExec = nativeExec;\nvar charAt = uncurryThis(''.charAt);\nvar indexOf = uncurryThis(''.indexOf);\nvar replace = uncurryThis(''.replace);\nvar stringSlice = uncurryThis(''.slice);\n\nvar UPDATES_LAST_INDEX_WRONG = (function () {\n var re1 = /a/;\n var re2 = /b*/g;\n call(nativeExec, re1, 'a');\n call(nativeExec, re2, 'a');\n return re1.lastIndex !== 0 || re2.lastIndex !== 0;\n})();\n\nvar UNSUPPORTED_Y = stickyHelpers.BROKEN_CARET;\n\n// nonparticipating capturing group, copied from es5-shim's String#split patch.\nvar NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;\n\nvar PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;\n\nif (PATCH) {\n patchedExec = function exec(string) {\n var re = this;\n var state = getInternalState(re);\n var str = toString(string);\n var raw = state.raw;\n var result, reCopy, lastIndex, match, i, object, group;\n\n if (raw) {\n raw.lastIndex = re.lastIndex;\n result = call(patchedExec, raw, str);\n re.lastIndex = raw.lastIndex;\n return result;\n }\n\n var groups = state.groups;\n var sticky = UNSUPPORTED_Y && re.sticky;\n var flags = call(regexpFlags, re);\n var source = re.source;\n var charsAdded = 0;\n var strCopy = str;\n\n if (sticky) {\n flags = replace(flags, 'y', '');\n if (indexOf(flags, 'g') === -1) {\n flags += 'g';\n }\n\n strCopy = stringSlice(str, re.lastIndex);\n // Support anchored sticky behavior.\n if (re.lastIndex > 0 && (!re.multiline || re.multiline && charAt(str, re.lastIndex - 1) !== '\\n')) {\n source = '(?: ' + source + ')';\n strCopy = ' ' + strCopy;\n charsAdded++;\n }\n // ^(? + rx + ) is needed, in combination with some str slicing, to\n // simulate the 'y' flag.\n reCopy = new RegExp('^(?:' + source + ')', flags);\n }\n\n if (NPCG_INCLUDED) {\n reCopy = new RegExp('^' + source + '$(?!\\\\s)', flags);\n }\n if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;\n\n match = call(nativeExec, sticky ? reCopy : re, strCopy);\n\n if (sticky) {\n if (match) {\n match.input = stringSlice(match.input, charsAdded);\n match[0] = stringSlice(match[0], charsAdded);\n match.index = re.lastIndex;\n re.lastIndex += match[0].length;\n } else re.lastIndex = 0;\n } else if (UPDATES_LAST_INDEX_WRONG && match) {\n re.lastIndex = re.global ? match.index + match[0].length : lastIndex;\n }\n if (NPCG_INCLUDED && match && match.length > 1) {\n // Fix browsers whose `exec` methods don't consistently return `undefined`\n // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/\n call(nativeReplace, match[0], reCopy, function () {\n for (i = 1; i < arguments.length - 2; i++) {\n if (arguments[i] === undefined) match[i] = undefined;\n }\n });\n }\n\n if (match && groups) {\n match.groups = object = create(null);\n for (i = 0; i < groups.length; i++) {\n group = groups[i];\n object[group[0]] = match[group[1]];\n }\n }\n\n return match;\n };\n}\n\nmodule.exports = patchedExec;\n","'use strict';\nvar anObject = require('../internals/an-object');\n\n// `RegExp.prototype.flags` getter implementation\n// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags\nmodule.exports = function () {\n var that = anObject(this);\n var result = '';\n if (that.global) result += 'g';\n if (that.ignoreCase) result += 'i';\n if (that.multiline) result += 'm';\n if (that.dotAll) result += 's';\n if (that.unicode) result += 'u';\n if (that.sticky) result += 'y';\n return result;\n};\n","var fails = require('../internals/fails');\nvar global = require('../internals/global');\n\n// babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError\nvar $RegExp = global.RegExp;\n\nvar UNSUPPORTED_Y = fails(function () {\n var re = $RegExp('a', 'y');\n re.lastIndex = 2;\n return re.exec('abcd') != null;\n});\n\n// UC Browser bug\n// https://github.com/zloirock/core-js/issues/1008\nvar MISSED_STICKY = UNSUPPORTED_Y || fails(function () {\n return !$RegExp('a', 'y').sticky;\n});\n\nvar BROKEN_CARET = UNSUPPORTED_Y || fails(function () {\n // https://bugzilla.mozilla.org/show_bug.cgi?id=773687\n var re = $RegExp('^r', 'gy');\n re.lastIndex = 2;\n return re.exec('str') != null;\n});\n\nmodule.exports = {\n BROKEN_CARET: BROKEN_CARET,\n MISSED_STICKY: MISSED_STICKY,\n UNSUPPORTED_Y: UNSUPPORTED_Y\n};\n","var fails = require('../internals/fails');\nvar global = require('../internals/global');\n\n// babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError\nvar $RegExp = global.RegExp;\n\nmodule.exports = fails(function () {\n var re = $RegExp('.', 's');\n return !(re.dotAll && re.exec('\\n') && re.flags === 's');\n});\n","var fails = require('../internals/fails');\nvar global = require('../internals/global');\n\n// babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError\nvar $RegExp = global.RegExp;\n\nmodule.exports = fails(function () {\n var re = $RegExp('(?<a>b)', 'g');\n return re.exec('b').groups.a !== 'b' ||\n 'b'.replace(re, '$<a>c') !== 'bc';\n});\n","var global = require('../internals/global');\n\nvar TypeError = global.TypeError;\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.es/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (it == undefined) throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n","var global = require('../internals/global');\n\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar defineProperty = Object.defineProperty;\n\nmodule.exports = function (key, value) {\n try {\n defineProperty(global, key, { value: value, configurable: true, writable: true });\n } catch (error) {\n global[key] = value;\n } return value;\n};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar definePropertyModule = require('../internals/object-define-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (CONSTRUCTOR_NAME) {\n var Constructor = getBuiltIn(CONSTRUCTOR_NAME);\n var defineProperty = definePropertyModule.f;\n\n if (DESCRIPTORS && Constructor && !Constructor[SPECIES]) {\n defineProperty(Constructor, SPECIES, {\n configurable: true,\n get: function () { return this; }\n });\n }\n};\n","var defineProperty = require('../internals/object-define-property').f;\nvar hasOwn = require('../internals/has-own-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n\nmodule.exports = function (target, TAG, STATIC) {\n if (target && !STATIC) target = target.prototype;\n if (target && !hasOwn(target, TO_STRING_TAG)) {\n defineProperty(target, TO_STRING_TAG, { configurable: true, value: TAG });\n }\n};\n","var shared = require('../internals/shared');\nvar uid = require('../internals/uid');\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n","var global = require('../internals/global');\nvar setGlobal = require('../internals/set-global');\n\nvar SHARED = '__core-js_shared__';\nvar store = global[SHARED] || setGlobal(SHARED, {});\n\nmodule.exports = store;\n","var IS_PURE = require('../internals/is-pure');\nvar store = require('../internals/shared-store');\n\n(module.exports = function (key, value) {\n return store[key] || (store[key] = value !== undefined ? value : {});\n})('versions', []).push({\n version: '3.20.2',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2022 Denis Pushkarev (zloirock.ru)'\n});\n","var anObject = require('../internals/an-object');\nvar aConstructor = require('../internals/a-constructor');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar SPECIES = wellKnownSymbol('species');\n\n// `SpeciesConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-speciesconstructor\nmodule.exports = function (O, defaultConstructor) {\n var C = anObject(O).constructor;\n var S;\n return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? defaultConstructor : aConstructor(S);\n};\n","var fails = require('../internals/fails');\n\n// check the existence of a method, lowercase\n// of a tag and escaping quotes in arguments\nmodule.exports = function (METHOD_NAME) {\n return fails(function () {\n var test = ''[METHOD_NAME]('\"');\n return test !== test.toLowerCase() || test.split('\"').length > 3;\n });\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toString = require('../internals/to-string');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar stringSlice = uncurryThis(''.slice);\n\nvar createMethod = function (CONVERT_TO_STRING) {\n return function ($this, pos) {\n var S = toString(requireObjectCoercible($this));\n var position = toIntegerOrInfinity(pos);\n var size = S.length;\n var first, second;\n if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;\n first = charCodeAt(S, position);\n return first < 0xD800 || first > 0xDBFF || position + 1 === size\n || (second = charCodeAt(S, position + 1)) < 0xDC00 || second > 0xDFFF\n ? CONVERT_TO_STRING\n ? charAt(S, position)\n : first\n : CONVERT_TO_STRING\n ? stringSlice(S, position, position + 2)\n : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;\n };\n};\n\nmodule.exports = {\n // `String.prototype.codePointAt` method\n // https://tc39.es/ecma262/#sec-string.prototype.codepointat\n codeAt: createMethod(false),\n // `String.prototype.at` method\n // https://github.com/mathiasbynens/String.prototype.at\n charAt: createMethod(true)\n};\n","'use strict';\nvar global = require('../internals/global');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toString = require('../internals/to-string');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar RangeError = global.RangeError;\n\n// `String.prototype.repeat` method implementation\n// https://tc39.es/ecma262/#sec-string.prototype.repeat\nmodule.exports = function repeat(count) {\n var str = toString(requireObjectCoercible(this));\n var result = '';\n var n = toIntegerOrInfinity(count);\n if (n < 0 || n == Infinity) throw RangeError('Wrong number of repetitions');\n for (;n > 0; (n >>>= 1) && (str += str)) if (n & 1) result += str;\n return result;\n};\n","var PROPER_FUNCTION_NAME = require('../internals/function-name').PROPER;\nvar fails = require('../internals/fails');\nvar whitespaces = require('../internals/whitespaces');\n\nvar non = '\\u200B\\u0085\\u180E';\n\n// check that a method works with the correct list\n// of whitespaces and has a correct name\nmodule.exports = function (METHOD_NAME) {\n return fails(function () {\n return !!whitespaces[METHOD_NAME]()\n || non[METHOD_NAME]() !== non\n || (PROPER_FUNCTION_NAME && whitespaces[METHOD_NAME].name !== METHOD_NAME);\n });\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar toString = require('../internals/to-string');\nvar whitespaces = require('../internals/whitespaces');\n\nvar replace = uncurryThis(''.replace);\nvar whitespace = '[' + whitespaces + ']';\nvar ltrim = RegExp('^' + whitespace + whitespace + '*');\nvar rtrim = RegExp(whitespace + whitespace + '*$');\n\n// `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation\nvar createMethod = function (TYPE) {\n return function ($this) {\n var string = toString(requireObjectCoercible($this));\n if (TYPE & 1) string = replace(string, ltrim, '');\n if (TYPE & 2) string = replace(string, rtrim, '');\n return string;\n };\n};\n\nmodule.exports = {\n // `String.prototype.{ trimLeft, trimStart }` methods\n // https://tc39.es/ecma262/#sec-string.prototype.trimstart\n start: createMethod(1),\n // `String.prototype.{ trimRight, trimEnd }` methods\n // https://tc39.es/ecma262/#sec-string.prototype.trimend\n end: createMethod(2),\n // `String.prototype.trim` method\n // https://tc39.es/ecma262/#sec-string.prototype.trim\n trim: createMethod(3)\n};\n","var global = require('../internals/global');\nvar apply = require('../internals/function-apply');\nvar bind = require('../internals/function-bind-context');\nvar isCallable = require('../internals/is-callable');\nvar hasOwn = require('../internals/has-own-property');\nvar fails = require('../internals/fails');\nvar html = require('../internals/html');\nvar arraySlice = require('../internals/array-slice');\nvar createElement = require('../internals/document-create-element');\nvar IS_IOS = require('../internals/engine-is-ios');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar set = global.setImmediate;\nvar clear = global.clearImmediate;\nvar process = global.process;\nvar Dispatch = global.Dispatch;\nvar Function = global.Function;\nvar MessageChannel = global.MessageChannel;\nvar String = global.String;\nvar counter = 0;\nvar queue = {};\nvar ONREADYSTATECHANGE = 'onreadystatechange';\nvar location, defer, channel, port;\n\ntry {\n // Deno throws a ReferenceError on `location` access without `--location` flag\n location = global.location;\n} catch (error) { /* empty */ }\n\nvar run = function (id) {\n if (hasOwn(queue, id)) {\n var fn = queue[id];\n delete queue[id];\n fn();\n }\n};\n\nvar runner = function (id) {\n return function () {\n run(id);\n };\n};\n\nvar listener = function (event) {\n run(event.data);\n};\n\nvar post = function (id) {\n // old engines have not location.origin\n global.postMessage(String(id), location.protocol + '//' + location.host);\n};\n\n// Node.js 0.9+ & IE10+ has setImmediate, otherwise:\nif (!set || !clear) {\n set = function setImmediate(fn) {\n var args = arraySlice(arguments, 1);\n queue[++counter] = function () {\n apply(isCallable(fn) ? fn : Function(fn), undefined, args);\n };\n defer(counter);\n return counter;\n };\n clear = function clearImmediate(id) {\n delete queue[id];\n };\n // Node.js 0.8-\n if (IS_NODE) {\n defer = function (id) {\n process.nextTick(runner(id));\n };\n // Sphere (JS game engine) Dispatch API\n } else if (Dispatch && Dispatch.now) {\n defer = function (id) {\n Dispatch.now(runner(id));\n };\n // Browsers with MessageChannel, includes WebWorkers\n // except iOS - https://github.com/zloirock/core-js/issues/624\n } else if (MessageChannel && !IS_IOS) {\n channel = new MessageChannel();\n port = channel.port2;\n channel.port1.onmessage = listener;\n defer = bind(port.postMessage, port);\n // Browsers with postMessage, skip WebWorkers\n // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'\n } else if (\n global.addEventListener &&\n isCallable(global.postMessage) &&\n !global.importScripts &&\n location && location.protocol !== 'file:' &&\n !fails(post)\n ) {\n defer = post;\n global.addEventListener('message', listener, false);\n // IE8-\n } else if (ONREADYSTATECHANGE in createElement('script')) {\n defer = function (id) {\n html.appendChild(createElement('script'))[ONREADYSTATECHANGE] = function () {\n html.removeChild(this);\n run(id);\n };\n };\n // Rest old browsers\n } else {\n defer = function (id) {\n setTimeout(runner(id), 0);\n };\n }\n}\n\nmodule.exports = {\n set: set,\n clear: clear\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\n// `thisNumberValue` abstract operation\n// https://tc39.es/ecma262/#sec-thisnumbervalue\nmodule.exports = uncurryThis(1.0.valueOf);\n","var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toIntegerOrInfinity(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n","// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = require('../internals/indexed-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n","var ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `ToIntegerOrInfinity` abstract operation\n// https://tc39.es/ecma262/#sec-tointegerorinfinity\nmodule.exports = function (argument) {\n var number = +argument;\n // eslint-disable-next-line no-self-compare -- safe\n return number !== number || number === 0 ? 0 : (number > 0 ? floor : ceil)(number);\n};\n","var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.es/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n return argument > 0 ? min(toIntegerOrInfinity(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n","var global = require('../internals/global');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar Object = global.Object;\n\n// `ToObject` abstract operation\n// https://tc39.es/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return Object(requireObjectCoercible(argument));\n};\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar isObject = require('../internals/is-object');\nvar isSymbol = require('../internals/is-symbol');\nvar getMethod = require('../internals/get-method');\nvar ordinaryToPrimitive = require('../internals/ordinary-to-primitive');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TypeError = global.TypeError;\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n// `ToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-toprimitive\nmodule.exports = function (input, pref) {\n if (!isObject(input) || isSymbol(input)) return input;\n var exoticToPrim = getMethod(input, TO_PRIMITIVE);\n var result;\n if (exoticToPrim) {\n if (pref === undefined) pref = 'default';\n result = call(exoticToPrim, input, pref);\n if (!isObject(result) || isSymbol(result)) return result;\n throw TypeError(\"Can't convert object to primitive value\");\n }\n if (pref === undefined) pref = 'number';\n return ordinaryToPrimitive(input, pref);\n};\n","var toPrimitive = require('../internals/to-primitive');\nvar isSymbol = require('../internals/is-symbol');\n\n// `ToPropertyKey` abstract operation\n// https://tc39.es/ecma262/#sec-topropertykey\nmodule.exports = function (argument) {\n var key = toPrimitive(argument, 'string');\n return isSymbol(key) ? key : key + '';\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n","var global = require('../internals/global');\nvar classof = require('../internals/classof');\n\nvar String = global.String;\n\nmodule.exports = function (argument) {\n if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');\n return String(argument);\n};\n","var IS_NODE = require('../internals/engine-is-node');\n\nmodule.exports = function (name) {\n try {\n // eslint-disable-next-line no-new-func -- safe\n if (IS_NODE) return Function('return require(\"' + name + '\")')();\n } catch (error) { /* empty */ }\n};\n","var global = require('../internals/global');\n\nvar String = global.String;\n\nmodule.exports = function (argument) {\n try {\n return String(argument);\n } catch (error) {\n return 'Object';\n }\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar id = 0;\nvar postfix = Math.random();\nvar toString = uncurryThis(1.0.toString);\n\nmodule.exports = function (key) {\n return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);\n};\n","/* eslint-disable es/no-symbol -- required for testing */\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\n\nmodule.exports = NATIVE_SYMBOL\n && !Symbol.sham\n && typeof Symbol.iterator == 'symbol';\n","var DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\n\n// V8 ~ Chrome 36-\n// https://bugs.chromium.org/p/v8/issues/detail?id=3334\nmodule.exports = DESCRIPTORS && fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(function () { /* empty */ }, 'prototype', {\n value: 42,\n writable: false\n }).prototype != 42;\n});\n","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nexports.f = wellKnownSymbol;\n","var global = require('../internals/global');\nvar shared = require('../internals/shared');\nvar hasOwn = require('../internals/has-own-property');\nvar uid = require('../internals/uid');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar WellKnownSymbolsStore = shared('wks');\nvar Symbol = global.Symbol;\nvar symbolFor = Symbol && Symbol['for'];\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!hasOwn(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {\n var description = 'Symbol.' + name;\n if (NATIVE_SYMBOL && hasOwn(Symbol, name)) {\n WellKnownSymbolsStore[name] = Symbol[name];\n } else if (USE_SYMBOL_AS_UID && symbolFor) {\n WellKnownSymbolsStore[name] = symbolFor(description);\n } else {\n WellKnownSymbolsStore[name] = createWellKnownSymbol(description);\n }\n } return WellKnownSymbolsStore[name];\n};\n","// a string of all valid unicode whitespaces\nmodule.exports = '\\u0009\\u000A\\u000B\\u000C\\u000D\\u0020\\u00A0\\u1680\\u2000\\u2001\\u2002' +\n '\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200A\\u202F\\u205F\\u3000\\u2028\\u2029\\uFEFF';\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar hasOwn = require('../internals/has-own-property');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\nvar inheritIfRequired = require('../internals/inherit-if-required');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\nvar installErrorCause = require('../internals/install-error-cause');\nvar clearErrorStack = require('../internals/clear-error-stack');\nvar ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable');\nvar IS_PURE = require('../internals/is-pure');\n\nmodule.exports = function (FULL_NAME, wrapper, FORCED, IS_AGGREGATE_ERROR) {\n var OPTIONS_POSITION = IS_AGGREGATE_ERROR ? 2 : 1;\n var path = FULL_NAME.split('.');\n var ERROR_NAME = path[path.length - 1];\n var OriginalError = getBuiltIn.apply(null, path);\n\n if (!OriginalError) return;\n\n var OriginalErrorPrototype = OriginalError.prototype;\n\n // V8 9.3- bug https://bugs.chromium.org/p/v8/issues/detail?id=12006\n if (!IS_PURE && hasOwn(OriginalErrorPrototype, 'cause')) delete OriginalErrorPrototype.cause;\n\n if (!FORCED) return OriginalError;\n\n var BaseError = getBuiltIn('Error');\n\n var WrappedError = wrapper(function (a, b) {\n var message = normalizeStringArgument(IS_AGGREGATE_ERROR ? b : a, undefined);\n var result = IS_AGGREGATE_ERROR ? new OriginalError(a) : new OriginalError();\n if (message !== undefined) createNonEnumerableProperty(result, 'message', message);\n if (ERROR_STACK_INSTALLABLE) createNonEnumerableProperty(result, 'stack', clearErrorStack(result.stack, 2));\n if (this && isPrototypeOf(OriginalErrorPrototype, this)) inheritIfRequired(result, this, WrappedError);\n if (arguments.length > OPTIONS_POSITION) installErrorCause(result, arguments[OPTIONS_POSITION]);\n return result;\n });\n\n WrappedError.prototype = OriginalErrorPrototype;\n\n if (ERROR_NAME !== 'Error') {\n if (setPrototypeOf) setPrototypeOf(WrappedError, BaseError);\n else copyConstructorProperties(WrappedError, BaseError, { name: true });\n }\n\n copyConstructorProperties(WrappedError, OriginalError);\n\n if (!IS_PURE) try {\n // Safari 13- bug: WebAssembly errors does not have a proper `.name`\n if (OriginalErrorPrototype.name !== ERROR_NAME) {\n createNonEnumerableProperty(OriginalErrorPrototype, 'name', ERROR_NAME);\n }\n OriginalErrorPrototype.constructor = WrappedError;\n } catch (error) { /* empty */ }\n\n return WrappedError;\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar fails = require('../internals/fails');\nvar isArray = require('../internals/is-array');\nvar isObject = require('../internals/is-object');\nvar toObject = require('../internals/to-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar createProperty = require('../internals/create-property');\nvar arraySpeciesCreate = require('../internals/array-species-create');\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_INDEX_EXCEEDED = 'Maximum allowed index exceeded';\nvar TypeError = global.TypeError;\n\n// We can't use this feature detection in V8 since it causes\n// deoptimization and serious performance degradation\n// https://github.com/zloirock/core-js/issues/679\nvar IS_CONCAT_SPREADABLE_SUPPORT = V8_VERSION >= 51 || !fails(function () {\n var array = [];\n array[IS_CONCAT_SPREADABLE] = false;\n return array.concat()[0] !== array;\n});\n\nvar SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('concat');\n\nvar isConcatSpreadable = function (O) {\n if (!isObject(O)) return false;\n var spreadable = O[IS_CONCAT_SPREADABLE];\n return spreadable !== undefined ? !!spreadable : isArray(O);\n};\n\nvar FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !SPECIES_SUPPORT;\n\n// `Array.prototype.concat` method\n// https://tc39.es/ecma262/#sec-array.prototype.concat\n// with adding support of @@isConcatSpreadable and @@species\n$({ target: 'Array', proto: true, forced: FORCED }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n concat: function concat(arg) {\n var O = toObject(this);\n var A = arraySpeciesCreate(O, 0);\n var n = 0;\n var i, k, length, len, E;\n for (i = -1, length = arguments.length; i < length; i++) {\n E = i === -1 ? O : arguments[i];\n if (isConcatSpreadable(E)) {\n len = lengthOfArrayLike(E);\n if (n + len > MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);\n } else {\n if (n >= MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n createProperty(A, n++, E);\n }\n }\n A.length = n;\n return A;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar $filter = require('../internals/array-iteration').filter;\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('filter');\n\n// `Array.prototype.filter` method\n// https://tc39.es/ecma262/#sec-array.prototype.filter\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {\n filter: function filter(callbackfn /* , thisArg */) {\n return $filter(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar $findIndex = require('../internals/array-iteration').findIndex;\nvar addToUnscopables = require('../internals/add-to-unscopables');\n\nvar FIND_INDEX = 'findIndex';\nvar SKIPS_HOLES = true;\n\n// Shouldn't skip holes\nif (FIND_INDEX in []) Array(1)[FIND_INDEX](function () { SKIPS_HOLES = false; });\n\n// `Array.prototype.findIndex` method\n// https://tc39.es/ecma262/#sec-array.prototype.findindex\n$({ target: 'Array', proto: true, forced: SKIPS_HOLES }, {\n findIndex: function findIndex(callbackfn /* , that = undefined */) {\n return $findIndex(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables(FIND_INDEX);\n","'use strict';\nvar $ = require('../internals/export');\nvar $find = require('../internals/array-iteration').find;\nvar addToUnscopables = require('../internals/add-to-unscopables');\n\nvar FIND = 'find';\nvar SKIPS_HOLES = true;\n\n// Shouldn't skip holes\nif (FIND in []) Array(1)[FIND](function () { SKIPS_HOLES = false; });\n\n// `Array.prototype.find` method\n// https://tc39.es/ecma262/#sec-array.prototype.find\n$({ target: 'Array', proto: true, forced: SKIPS_HOLES }, {\n find: function find(callbackfn /* , that = undefined */) {\n return $find(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables(FIND);\n","var $ = require('../internals/export');\nvar from = require('../internals/array-from');\nvar checkCorrectnessOfIteration = require('../internals/check-correctness-of-iteration');\n\nvar INCORRECT_ITERATION = !checkCorrectnessOfIteration(function (iterable) {\n // eslint-disable-next-line es/no-array-from -- required for testing\n Array.from(iterable);\n});\n\n// `Array.from` method\n// https://tc39.es/ecma262/#sec-array.from\n$({ target: 'Array', stat: true, forced: INCORRECT_ITERATION }, {\n from: from\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar $includes = require('../internals/array-includes').includes;\nvar addToUnscopables = require('../internals/add-to-unscopables');\n\n// `Array.prototype.includes` method\n// https://tc39.es/ecma262/#sec-array.prototype.includes\n$({ target: 'Array', proto: true }, {\n includes: function includes(el /* , fromIndex = 0 */) {\n return $includes(this, el, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('includes');\n","'use strict';\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar addToUnscopables = require('../internals/add-to-unscopables');\nvar Iterators = require('../internals/iterators');\nvar InternalStateModule = require('../internals/internal-state');\nvar defineProperty = require('../internals/object-define-property').f;\nvar defineIterator = require('../internals/define-iterator');\nvar IS_PURE = require('../internals/is-pure');\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar ARRAY_ITERATOR = 'Array Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);\n\n// `Array.prototype.entries` method\n// https://tc39.es/ecma262/#sec-array.prototype.entries\n// `Array.prototype.keys` method\n// https://tc39.es/ecma262/#sec-array.prototype.keys\n// `Array.prototype.values` method\n// https://tc39.es/ecma262/#sec-array.prototype.values\n// `Array.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-array.prototype-@@iterator\n// `CreateArrayIterator` internal method\n// https://tc39.es/ecma262/#sec-createarrayiterator\nmodule.exports = defineIterator(Array, 'Array', function (iterated, kind) {\n setInternalState(this, {\n type: ARRAY_ITERATOR,\n target: toIndexedObject(iterated), // target\n index: 0, // next index\n kind: kind // kind\n });\n// `%ArrayIteratorPrototype%.next` method\n// https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next\n}, function () {\n var state = getInternalState(this);\n var target = state.target;\n var kind = state.kind;\n var index = state.index++;\n if (!target || index >= target.length) {\n state.target = undefined;\n return { value: undefined, done: true };\n }\n if (kind == 'keys') return { value: index, done: false };\n if (kind == 'values') return { value: target[index], done: false };\n return { value: [index, target[index]], done: false };\n}, 'values');\n\n// argumentsList[@@iterator] is %ArrayProto_values%\n// https://tc39.es/ecma262/#sec-createunmappedargumentsobject\n// https://tc39.es/ecma262/#sec-createmappedargumentsobject\nvar values = Iterators.Arguments = Iterators.Array;\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries');\n\n// V8 ~ Chrome 45- bug\nif (!IS_PURE && DESCRIPTORS && values.name !== 'values') try {\n defineProperty(values, 'name', { value: 'values' });\n} catch (error) { /* empty */ }\n","'use strict';\nvar $ = require('../internals/export');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IndexedObject = require('../internals/indexed-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar arrayMethodIsStrict = require('../internals/array-method-is-strict');\n\nvar un$Join = uncurryThis([].join);\n\nvar ES3_STRINGS = IndexedObject != Object;\nvar STRICT_METHOD = arrayMethodIsStrict('join', ',');\n\n// `Array.prototype.join` method\n// https://tc39.es/ecma262/#sec-array.prototype.join\n$({ target: 'Array', proto: true, forced: ES3_STRINGS || !STRICT_METHOD }, {\n join: function join(separator) {\n return un$Join(toIndexedObject(this), separator === undefined ? ',' : separator);\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar $map = require('../internals/array-iteration').map;\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('map');\n\n// `Array.prototype.map` method\n// https://tc39.es/ecma262/#sec-array.prototype.map\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {\n map: function map(callbackfn /* , thisArg */) {\n return $map(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar isArray = require('../internals/is-array');\nvar isConstructor = require('../internals/is-constructor');\nvar isObject = require('../internals/is-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar createProperty = require('../internals/create-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\nvar un$Slice = require('../internals/array-slice');\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('slice');\n\nvar SPECIES = wellKnownSymbol('species');\nvar Array = global.Array;\nvar max = Math.max;\n\n// `Array.prototype.slice` method\n// https://tc39.es/ecma262/#sec-array.prototype.slice\n// fallback for not array-like ES3 strings and DOM objects\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {\n slice: function slice(start, end) {\n var O = toIndexedObject(this);\n var length = lengthOfArrayLike(O);\n var k = toAbsoluteIndex(start, length);\n var fin = toAbsoluteIndex(end === undefined ? length : end, length);\n // inline `ArraySpeciesCreate` for usage native `Array#slice` where it's possible\n var Constructor, result, n;\n if (isArray(O)) {\n Constructor = O.constructor;\n // cross-realm fallback\n if (isConstructor(Constructor) && (Constructor === Array || isArray(Constructor.prototype))) {\n Constructor = undefined;\n } else if (isObject(Constructor)) {\n Constructor = Constructor[SPECIES];\n if (Constructor === null) Constructor = undefined;\n }\n if (Constructor === Array || Constructor === undefined) {\n return un$Slice(O, k, fin);\n }\n }\n result = new (Constructor === undefined ? Array : Constructor)(max(fin - k, 0));\n for (n = 0; k < fin; k++, n++) if (k in O) createProperty(result, n, O[k]);\n result.length = n;\n return result;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar toObject = require('../internals/to-object');\nvar arraySpeciesCreate = require('../internals/array-species-create');\nvar createProperty = require('../internals/create-property');\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('splice');\n\nvar TypeError = global.TypeError;\nvar max = Math.max;\nvar min = Math.min;\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_LENGTH_EXCEEDED = 'Maximum allowed length exceeded';\n\n// `Array.prototype.splice` method\n// https://tc39.es/ecma262/#sec-array.prototype.splice\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {\n splice: function splice(start, deleteCount /* , ...items */) {\n var O = toObject(this);\n var len = lengthOfArrayLike(O);\n var actualStart = toAbsoluteIndex(start, len);\n var argumentsLength = arguments.length;\n var insertCount, actualDeleteCount, A, k, from, to;\n if (argumentsLength === 0) {\n insertCount = actualDeleteCount = 0;\n } else if (argumentsLength === 1) {\n insertCount = 0;\n actualDeleteCount = len - actualStart;\n } else {\n insertCount = argumentsLength - 2;\n actualDeleteCount = min(max(toIntegerOrInfinity(deleteCount), 0), len - actualStart);\n }\n if (len + insertCount - actualDeleteCount > MAX_SAFE_INTEGER) {\n throw TypeError(MAXIMUM_ALLOWED_LENGTH_EXCEEDED);\n }\n A = arraySpeciesCreate(O, actualDeleteCount);\n for (k = 0; k < actualDeleteCount; k++) {\n from = actualStart + k;\n if (from in O) createProperty(A, k, O[from]);\n }\n A.length = actualDeleteCount;\n if (insertCount < actualDeleteCount) {\n for (k = actualStart; k < len - actualDeleteCount; k++) {\n from = k + actualDeleteCount;\n to = k + insertCount;\n if (from in O) O[to] = O[from];\n else delete O[to];\n }\n for (k = len; k > len - actualDeleteCount + insertCount; k--) delete O[k - 1];\n } else if (insertCount > actualDeleteCount) {\n for (k = len - actualDeleteCount; k > actualStart; k--) {\n from = k + actualDeleteCount - 1;\n to = k + insertCount - 1;\n if (from in O) O[to] = O[from];\n else delete O[to];\n }\n }\n for (k = 0; k < insertCount; k++) {\n O[k + actualStart] = arguments[k + 2];\n }\n O.length = len - actualDeleteCount + insertCount;\n return A;\n }\n});\n","/* eslint-disable no-unused-vars -- required for functions `.length` */\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar apply = require('../internals/function-apply');\nvar wrapErrorConstructorWithCause = require('../internals/wrap-error-constructor-with-cause');\n\nvar WEB_ASSEMBLY = 'WebAssembly';\nvar WebAssembly = global[WEB_ASSEMBLY];\n\nvar FORCED = Error('e', { cause: 7 }).cause !== 7;\n\nvar exportGlobalErrorCauseWrapper = function (ERROR_NAME, wrapper) {\n var O = {};\n O[ERROR_NAME] = wrapErrorConstructorWithCause(ERROR_NAME, wrapper, FORCED);\n $({ global: true, forced: FORCED }, O);\n};\n\nvar exportWebAssemblyErrorCauseWrapper = function (ERROR_NAME, wrapper) {\n if (WebAssembly && WebAssembly[ERROR_NAME]) {\n var O = {};\n O[ERROR_NAME] = wrapErrorConstructorWithCause(WEB_ASSEMBLY + '.' + ERROR_NAME, wrapper, FORCED);\n $({ target: WEB_ASSEMBLY, stat: true, forced: FORCED }, O);\n }\n};\n\n// https://github.com/tc39/proposal-error-cause\nexportGlobalErrorCauseWrapper('Error', function (init) {\n return function Error(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('EvalError', function (init) {\n return function EvalError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('RangeError', function (init) {\n return function RangeError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('ReferenceError', function (init) {\n return function ReferenceError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('SyntaxError', function (init) {\n return function SyntaxError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('TypeError', function (init) {\n return function TypeError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('URIError', function (init) {\n return function URIError(message) { return apply(init, this, arguments); };\n});\nexportWebAssemblyErrorCauseWrapper('CompileError', function (init) {\n return function CompileError(message) { return apply(init, this, arguments); };\n});\nexportWebAssemblyErrorCauseWrapper('LinkError', function (init) {\n return function LinkError(message) { return apply(init, this, arguments); };\n});\nexportWebAssemblyErrorCauseWrapper('RuntimeError', function (init) {\n return function RuntimeError(message) { return apply(init, this, arguments); };\n});\n","var DESCRIPTORS = require('../internals/descriptors');\nvar FUNCTION_NAME_EXISTS = require('../internals/function-name').EXISTS;\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar defineProperty = require('../internals/object-define-property').f;\n\nvar FunctionPrototype = Function.prototype;\nvar functionToString = uncurryThis(FunctionPrototype.toString);\nvar nameRE = /function\\b(?:\\s|\\/\\*[\\S\\s]*?\\*\\/|\\/\\/[^\\n\\r]*[\\n\\r]+)*([^\\s(/]*)/;\nvar regExpExec = uncurryThis(nameRE.exec);\nvar NAME = 'name';\n\n// Function instances `.name` property\n// https://tc39.es/ecma262/#sec-function-instances-name\nif (DESCRIPTORS && !FUNCTION_NAME_EXISTS) {\n defineProperty(FunctionPrototype, NAME, {\n configurable: true,\n get: function () {\n try {\n return regExpExec(nameRE, functionToString(this))[1];\n } catch (error) {\n return '';\n }\n }\n });\n}\n","var $ = require('../internals/export');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar apply = require('../internals/function-apply');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\n\nvar Array = global.Array;\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar exec = uncurryThis(/./.exec);\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar replace = uncurryThis(''.replace);\nvar numberToString = uncurryThis(1.0.toString);\n\nvar tester = /[\\uD800-\\uDFFF]/g;\nvar low = /^[\\uD800-\\uDBFF]$/;\nvar hi = /^[\\uDC00-\\uDFFF]$/;\n\nvar fix = function (match, offset, string) {\n var prev = charAt(string, offset - 1);\n var next = charAt(string, offset + 1);\n if ((exec(low, match) && !exec(hi, next)) || (exec(hi, match) && !exec(low, prev))) {\n return '\\\\u' + numberToString(charCodeAt(match, 0), 16);\n } return match;\n};\n\nvar FORCED = fails(function () {\n return $stringify('\\uDF06\\uD834') !== '\"\\\\udf06\\\\ud834\"'\n || $stringify('\\uDEAD') !== '\"\\\\udead\"';\n});\n\nif ($stringify) {\n // `JSON.stringify` method\n // https://tc39.es/ecma262/#sec-json.stringify\n // https://github.com/tc39/proposal-well-formed-stringify\n $({ target: 'JSON', stat: true, forced: FORCED }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n stringify: function stringify(it, replacer, space) {\n for (var i = 0, l = arguments.length, args = Array(l); i < l; i++) args[i] = arguments[i];\n var result = apply($stringify, null, args);\n return typeof result == 'string' ? replace(result, tester, fix) : result;\n }\n });\n}\n","var $ = require('../internals/export');\nvar log10 = require('../internals/math-log10');\n\n// `Math.log10` method\n// https://tc39.es/ecma262/#sec-math.log10\n$({ target: 'Math', stat: true }, {\n log10: log10\n});\n","var $ = require('../internals/export');\n\nvar log = Math.log;\nvar LN2 = Math.LN2;\n\n// `Math.log2` method\n// https://tc39.es/ecma262/#sec-math.log2\n$({ target: 'Math', stat: true }, {\n log2: function log2(x) {\n return log(x) / LN2;\n }\n});\n","var $ = require('../internals/export');\nvar sign = require('../internals/math-sign');\n\n// `Math.sign` method\n// https://tc39.es/ecma262/#sec-math.sign\n$({ target: 'Math', stat: true }, {\n sign: sign\n});\n","var $ = require('../internals/export');\n\nvar ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `Math.trunc` method\n// https://tc39.es/ecma262/#sec-math.trunc\n$({ target: 'Math', stat: true }, {\n trunc: function trunc(it) {\n return (it > 0 ? floor : ceil)(it);\n }\n});\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isForced = require('../internals/is-forced');\nvar redefine = require('../internals/redefine');\nvar hasOwn = require('../internals/has-own-property');\nvar inheritIfRequired = require('../internals/inherit-if-required');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar isSymbol = require('../internals/is-symbol');\nvar toPrimitive = require('../internals/to-primitive');\nvar fails = require('../internals/fails');\nvar getOwnPropertyNames = require('../internals/object-get-own-property-names').f;\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar defineProperty = require('../internals/object-define-property').f;\nvar thisNumberValue = require('../internals/this-number-value');\nvar trim = require('../internals/string-trim').trim;\n\nvar NUMBER = 'Number';\nvar NativeNumber = global[NUMBER];\nvar NumberPrototype = NativeNumber.prototype;\nvar TypeError = global.TypeError;\nvar arraySlice = uncurryThis(''.slice);\nvar charCodeAt = uncurryThis(''.charCodeAt);\n\n// `ToNumeric` abstract operation\n// https://tc39.es/ecma262/#sec-tonumeric\nvar toNumeric = function (value) {\n var primValue = toPrimitive(value, 'number');\n return typeof primValue == 'bigint' ? primValue : toNumber(primValue);\n};\n\n// `ToNumber` abstract operation\n// https://tc39.es/ecma262/#sec-tonumber\nvar toNumber = function (argument) {\n var it = toPrimitive(argument, 'number');\n var first, third, radix, maxCode, digits, length, index, code;\n if (isSymbol(it)) throw TypeError('Cannot convert a Symbol value to a number');\n if (typeof it == 'string' && it.length > 2) {\n it = trim(it);\n first = charCodeAt(it, 0);\n if (first === 43 || first === 45) {\n third = charCodeAt(it, 2);\n if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix\n } else if (first === 48) {\n switch (charCodeAt(it, 1)) {\n case 66: case 98: radix = 2; maxCode = 49; break; // fast equal of /^0b[01]+$/i\n case 79: case 111: radix = 8; maxCode = 55; break; // fast equal of /^0o[0-7]+$/i\n default: return +it;\n }\n digits = arraySlice(it, 2);\n length = digits.length;\n for (index = 0; index < length; index++) {\n code = charCodeAt(digits, index);\n // parseInt parses a string to a first unavailable symbol\n // but ToNumber should return NaN if a string contains unavailable symbols\n if (code < 48 || code > maxCode) return NaN;\n } return parseInt(digits, radix);\n }\n } return +it;\n};\n\n// `Number` constructor\n// https://tc39.es/ecma262/#sec-number-constructor\nif (isForced(NUMBER, !NativeNumber(' 0o1') || !NativeNumber('0b1') || NativeNumber('+0x1'))) {\n var NumberWrapper = function Number(value) {\n var n = arguments.length < 1 ? 0 : NativeNumber(toNumeric(value));\n var dummy = this;\n // check on 1..constructor(foo) case\n return isPrototypeOf(NumberPrototype, dummy) && fails(function () { thisNumberValue(dummy); })\n ? inheritIfRequired(Object(n), dummy, NumberWrapper) : n;\n };\n for (var keys = DESCRIPTORS ? getOwnPropertyNames(NativeNumber) : (\n // ES3:\n 'MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,' +\n // ES2015 (in case, if modules with ES2015 Number statics required before):\n 'EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,' +\n // ESNext\n 'fromString,range'\n ).split(','), j = 0, key; keys.length > j; j++) {\n if (hasOwn(NativeNumber, key = keys[j]) && !hasOwn(NumberWrapper, key)) {\n defineProperty(NumberWrapper, key, getOwnPropertyDescriptor(NativeNumber, key));\n }\n }\n NumberWrapper.prototype = NumberPrototype;\n NumberPrototype.constructor = NumberWrapper;\n redefine(global, NUMBER, NumberWrapper);\n}\n","var $ = require('../internals/export');\nvar numberIsFinite = require('../internals/number-is-finite');\n\n// `Number.isFinite` method\n// https://tc39.es/ecma262/#sec-number.isfinite\n$({ target: 'Number', stat: true }, { isFinite: numberIsFinite });\n","var $ = require('../internals/export');\n\n// `Number.isNaN` method\n// https://tc39.es/ecma262/#sec-number.isnan\n$({ target: 'Number', stat: true }, {\n isNaN: function isNaN(number) {\n // eslint-disable-next-line no-self-compare -- NaN check\n return number != number;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar thisNumberValue = require('../internals/this-number-value');\nvar $repeat = require('../internals/string-repeat');\nvar log10 = require('../internals/math-log10');\nvar fails = require('../internals/fails');\n\nvar RangeError = global.RangeError;\nvar String = global.String;\nvar isFinite = global.isFinite;\nvar abs = Math.abs;\nvar floor = Math.floor;\nvar pow = Math.pow;\nvar round = Math.round;\nvar un$ToExponential = uncurryThis(1.0.toExponential);\nvar repeat = uncurryThis($repeat);\nvar stringSlice = uncurryThis(''.slice);\n\n// Edge 17-\nvar ROUNDS_PROPERLY = un$ToExponential(-6.9e-11, 4) === '-6.9000e-11'\n // IE11- && Edge 14-\n && un$ToExponential(1.255, 2) === '1.25e+0'\n // FF86-, V8 ~ Chrome 49-50\n && un$ToExponential(12345, 3) === '1.235e+4'\n // FF86-, V8 ~ Chrome 49-50\n && un$ToExponential(25, 0) === '3e+1';\n\n// IE8-\nvar THROWS_ON_INFINITY_FRACTION = fails(function () {\n un$ToExponential(1, Infinity);\n}) && fails(function () {\n un$ToExponential(1, -Infinity);\n});\n\n// Safari <11 && FF <50\nvar PROPER_NON_FINITE_THIS_CHECK = !fails(function () {\n un$ToExponential(Infinity, Infinity);\n}) && !fails(function () {\n un$ToExponential(NaN, Infinity);\n});\n\nvar FORCED = !ROUNDS_PROPERLY || !THROWS_ON_INFINITY_FRACTION || !PROPER_NON_FINITE_THIS_CHECK;\n\n// `Number.prototype.toExponential` method\n// https://tc39.es/ecma262/#sec-number.prototype.toexponential\n$({ target: 'Number', proto: true, forced: FORCED }, {\n toExponential: function toExponential(fractionDigits) {\n var x = thisNumberValue(this);\n if (fractionDigits === undefined) return un$ToExponential(x);\n var f = toIntegerOrInfinity(fractionDigits);\n if (!isFinite(x)) return String(x);\n // TODO: ES2018 increased the maximum number of fraction digits to 100, need to improve the implementation\n if (f < 0 || f > 20) throw RangeError('Incorrect fraction digits');\n if (ROUNDS_PROPERLY) return un$ToExponential(x, f);\n var s = '';\n var m = '';\n var e = 0;\n var c = '';\n var d = '';\n if (x < 0) {\n s = '-';\n x = -x;\n }\n if (x === 0) {\n e = 0;\n m = repeat('0', f + 1);\n } else {\n // this block is based on https://gist.github.com/SheetJSDev/1100ad56b9f856c95299ed0e068eea08\n // TODO: improve accuracy with big fraction digits\n var l = log10(x);\n e = floor(l);\n var n = 0;\n var w = pow(10, e - f);\n n = round(x / w);\n if (2 * x >= (2 * n + 1) * w) {\n n += 1;\n }\n if (n >= pow(10, f + 1)) {\n n /= 10;\n e += 1;\n }\n m = String(n);\n }\n if (f !== 0) {\n m = stringSlice(m, 0, 1) + '.' + stringSlice(m, 1);\n }\n if (e === 0) {\n c = '+';\n d = '0';\n } else {\n c = e > 0 ? '+' : '-';\n d = String(abs(e));\n }\n m += 'e' + c + d;\n return s + m;\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar thisNumberValue = require('../internals/this-number-value');\nvar $repeat = require('../internals/string-repeat');\nvar fails = require('../internals/fails');\n\nvar RangeError = global.RangeError;\nvar String = global.String;\nvar floor = Math.floor;\nvar repeat = uncurryThis($repeat);\nvar stringSlice = uncurryThis(''.slice);\nvar un$ToFixed = uncurryThis(1.0.toFixed);\n\nvar pow = function (x, n, acc) {\n return n === 0 ? acc : n % 2 === 1 ? pow(x, n - 1, acc * x) : pow(x * x, n / 2, acc);\n};\n\nvar log = function (x) {\n var n = 0;\n var x2 = x;\n while (x2 >= 4096) {\n n += 12;\n x2 /= 4096;\n }\n while (x2 >= 2) {\n n += 1;\n x2 /= 2;\n } return n;\n};\n\nvar multiply = function (data, n, c) {\n var index = -1;\n var c2 = c;\n while (++index < 6) {\n c2 += n * data[index];\n data[index] = c2 % 1e7;\n c2 = floor(c2 / 1e7);\n }\n};\n\nvar divide = function (data, n) {\n var index = 6;\n var c = 0;\n while (--index >= 0) {\n c += data[index];\n data[index] = floor(c / n);\n c = (c % n) * 1e7;\n }\n};\n\nvar dataToString = function (data) {\n var index = 6;\n var s = '';\n while (--index >= 0) {\n if (s !== '' || index === 0 || data[index] !== 0) {\n var t = String(data[index]);\n s = s === '' ? t : s + repeat('0', 7 - t.length) + t;\n }\n } return s;\n};\n\nvar FORCED = fails(function () {\n return un$ToFixed(0.00008, 3) !== '0.000' ||\n un$ToFixed(0.9, 0) !== '1' ||\n un$ToFixed(1.255, 2) !== '1.25' ||\n un$ToFixed(1000000000000000128.0, 0) !== '1000000000000000128';\n}) || !fails(function () {\n // V8 ~ Android 4.3-\n un$ToFixed({});\n});\n\n// `Number.prototype.toFixed` method\n// https://tc39.es/ecma262/#sec-number.prototype.tofixed\n$({ target: 'Number', proto: true, forced: FORCED }, {\n toFixed: function toFixed(fractionDigits) {\n var number = thisNumberValue(this);\n var fractDigits = toIntegerOrInfinity(fractionDigits);\n var data = [0, 0, 0, 0, 0, 0];\n var sign = '';\n var result = '0';\n var e, z, j, k;\n\n // TODO: ES2018 increased the maximum number of fraction digits to 100, need to improve the implementation\n if (fractDigits < 0 || fractDigits > 20) throw RangeError('Incorrect fraction digits');\n // eslint-disable-next-line no-self-compare -- NaN check\n if (number != number) return 'NaN';\n if (number <= -1e21 || number >= 1e21) return String(number);\n if (number < 0) {\n sign = '-';\n number = -number;\n }\n if (number > 1e-21) {\n e = log(number * pow(2, 69, 1)) - 69;\n z = e < 0 ? number * pow(2, -e, 1) : number / pow(2, e, 1);\n z *= 0x10000000000000;\n e = 52 - e;\n if (e > 0) {\n multiply(data, 0, z);\n j = fractDigits;\n while (j >= 7) {\n multiply(data, 1e7, 0);\n j -= 7;\n }\n multiply(data, pow(10, j, 1), 0);\n j = e - 1;\n while (j >= 23) {\n divide(data, 1 << 23);\n j -= 23;\n }\n divide(data, 1 << j);\n multiply(data, 1, 1);\n divide(data, 2);\n result = dataToString(data);\n } else {\n multiply(data, 0, z);\n multiply(data, 1 << -e, 0);\n result = dataToString(data) + repeat('0', fractDigits);\n }\n }\n if (fractDigits > 0) {\n k = result.length;\n result = sign + (k <= fractDigits\n ? '0.' + repeat('0', fractDigits - k) + result\n : stringSlice(result, 0, k - fractDigits) + '.' + stringSlice(result, k - fractDigits));\n } else {\n result = sign + result;\n } return result;\n }\n});\n","var $ = require('../internals/export');\nvar assign = require('../internals/object-assign');\n\n// `Object.assign` method\n// https://tc39.es/ecma262/#sec-object.assign\n// eslint-disable-next-line es/no-object-assign -- required for testing\n$({ target: 'Object', stat: true, forced: Object.assign !== assign }, {\n assign: assign\n});\n","var $ = require('../internals/export');\nvar fails = require('../internals/fails');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar nativeGetOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeGetOwnPropertyDescriptor(1); });\nvar FORCED = !DESCRIPTORS || FAILS_ON_PRIMITIVES;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor\n$({ target: 'Object', stat: true, forced: FORCED, sham: !DESCRIPTORS }, {\n getOwnPropertyDescriptor: function getOwnPropertyDescriptor(it, key) {\n return nativeGetOwnPropertyDescriptor(toIndexedObject(it), key);\n }\n});\n","var $ = require('../internals/export');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar ownKeys = require('../internals/own-keys');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar createProperty = require('../internals/create-property');\n\n// `Object.getOwnPropertyDescriptors` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptors\n$({ target: 'Object', stat: true, sham: !DESCRIPTORS }, {\n getOwnPropertyDescriptors: function getOwnPropertyDescriptors(object) {\n var O = toIndexedObject(object);\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n var keys = ownKeys(O);\n var result = {};\n var index = 0;\n var key, descriptor;\n while (keys.length > index) {\n descriptor = getOwnPropertyDescriptor(O, key = keys[index++]);\n if (descriptor !== undefined) createProperty(result, key, descriptor);\n }\n return result;\n }\n});\n","var $ = require('../internals/export');\nvar toObject = require('../internals/to-object');\nvar nativeKeys = require('../internals/object-keys');\nvar fails = require('../internals/fails');\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeKeys(1); });\n\n// `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES }, {\n keys: function keys(it) {\n return nativeKeys(toObject(it));\n }\n});\n","var TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar redefine = require('../internals/redefine');\nvar toString = require('../internals/object-to-string');\n\n// `Object.prototype.toString` method\n// https://tc39.es/ecma262/#sec-object.prototype.tostring\nif (!TO_STRING_TAG_SUPPORT) {\n redefine(Object.prototype, 'toString', toString, { unsafe: true });\n}\n","var $ = require('../internals/export');\nvar $values = require('../internals/object-to-array').values;\n\n// `Object.values` method\n// https://tc39.es/ecma262/#sec-object.values\n$({ target: 'Object', stat: true }, {\n values: function values(O) {\n return $values(O);\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar IS_PURE = require('../internals/is-pure');\nvar NativePromise = require('../internals/native-promise-constructor');\nvar fails = require('../internals/fails');\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar speciesConstructor = require('../internals/species-constructor');\nvar promiseResolve = require('../internals/promise-resolve');\nvar redefine = require('../internals/redefine');\n\n// Safari bug https://bugs.webkit.org/show_bug.cgi?id=200829\nvar NON_GENERIC = !!NativePromise && fails(function () {\n // eslint-disable-next-line unicorn/no-thenable -- required for testing\n NativePromise.prototype['finally'].call({ then: function () { /* empty */ } }, function () { /* empty */ });\n});\n\n// `Promise.prototype.finally` method\n// https://tc39.es/ecma262/#sec-promise.prototype.finally\n$({ target: 'Promise', proto: true, real: true, forced: NON_GENERIC }, {\n 'finally': function (onFinally) {\n var C = speciesConstructor(this, getBuiltIn('Promise'));\n var isFunction = isCallable(onFinally);\n return this.then(\n isFunction ? function (x) {\n return promiseResolve(C, onFinally()).then(function () { return x; });\n } : onFinally,\n isFunction ? function (e) {\n return promiseResolve(C, onFinally()).then(function () { throw e; });\n } : onFinally\n );\n }\n});\n\n// makes sure that native promise-based APIs `Promise#finally` properly works with patched `Promise#then`\nif (!IS_PURE && isCallable(NativePromise)) {\n var method = getBuiltIn('Promise').prototype['finally'];\n if (NativePromise.prototype['finally'] !== method) {\n redefine(NativePromise.prototype, 'finally', method, { unsafe: true });\n }\n}\n","'use strict';\nvar $ = require('../internals/export');\nvar IS_PURE = require('../internals/is-pure');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar call = require('../internals/function-call');\nvar NativePromise = require('../internals/native-promise-constructor');\nvar redefine = require('../internals/redefine');\nvar redefineAll = require('../internals/redefine-all');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar setSpecies = require('../internals/set-species');\nvar aCallable = require('../internals/a-callable');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar anInstance = require('../internals/an-instance');\nvar inspectSource = require('../internals/inspect-source');\nvar iterate = require('../internals/iterate');\nvar checkCorrectnessOfIteration = require('../internals/check-correctness-of-iteration');\nvar speciesConstructor = require('../internals/species-constructor');\nvar task = require('../internals/task').set;\nvar microtask = require('../internals/microtask');\nvar promiseResolve = require('../internals/promise-resolve');\nvar hostReportErrors = require('../internals/host-report-errors');\nvar newPromiseCapabilityModule = require('../internals/new-promise-capability');\nvar perform = require('../internals/perform');\nvar Queue = require('../internals/queue');\nvar InternalStateModule = require('../internals/internal-state');\nvar isForced = require('../internals/is-forced');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IS_BROWSER = require('../internals/engine-is-browser');\nvar IS_NODE = require('../internals/engine-is-node');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar SPECIES = wellKnownSymbol('species');\nvar PROMISE = 'Promise';\n\nvar getInternalState = InternalStateModule.getterFor(PROMISE);\nvar setInternalState = InternalStateModule.set;\nvar getInternalPromiseState = InternalStateModule.getterFor(PROMISE);\nvar NativePromisePrototype = NativePromise && NativePromise.prototype;\nvar PromiseConstructor = NativePromise;\nvar PromisePrototype = NativePromisePrototype;\nvar TypeError = global.TypeError;\nvar document = global.document;\nvar process = global.process;\nvar newPromiseCapability = newPromiseCapabilityModule.f;\nvar newGenericPromiseCapability = newPromiseCapability;\n\nvar DISPATCH_EVENT = !!(document && document.createEvent && global.dispatchEvent);\nvar NATIVE_REJECTION_EVENT = isCallable(global.PromiseRejectionEvent);\nvar UNHANDLED_REJECTION = 'unhandledrejection';\nvar REJECTION_HANDLED = 'rejectionhandled';\nvar PENDING = 0;\nvar FULFILLED = 1;\nvar REJECTED = 2;\nvar HANDLED = 1;\nvar UNHANDLED = 2;\nvar SUBCLASSING = false;\n\nvar Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;\n\nvar FORCED = isForced(PROMISE, function () {\n var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(PromiseConstructor);\n var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(PromiseConstructor);\n // V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables\n // https://bugs.chromium.org/p/chromium/issues/detail?id=830565\n // We can't detect it synchronously, so just check versions\n if (!GLOBAL_CORE_JS_PROMISE && V8_VERSION === 66) return true;\n // We need Promise#finally in the pure version for preventing prototype pollution\n if (IS_PURE && !PromisePrototype['finally']) return true;\n // We can't use @@species feature detection in V8 since it causes\n // deoptimization and performance degradation\n // https://github.com/zloirock/core-js/issues/679\n if (V8_VERSION >= 51 && /native code/.test(PROMISE_CONSTRUCTOR_SOURCE)) return false;\n // Detect correctness of subclassing with @@species support\n var promise = new PromiseConstructor(function (resolve) { resolve(1); });\n var FakePromise = function (exec) {\n exec(function () { /* empty */ }, function () { /* empty */ });\n };\n var constructor = promise.constructor = {};\n constructor[SPECIES] = FakePromise;\n SUBCLASSING = promise.then(function () { /* empty */ }) instanceof FakePromise;\n if (!SUBCLASSING) return true;\n // Unhandled rejections tracking support, NodeJS Promise without it fails @@species test\n return !GLOBAL_CORE_JS_PROMISE && IS_BROWSER && !NATIVE_REJECTION_EVENT;\n});\n\nvar INCORRECT_ITERATION = FORCED || !checkCorrectnessOfIteration(function (iterable) {\n PromiseConstructor.all(iterable)['catch'](function () { /* empty */ });\n});\n\n// helpers\nvar isThenable = function (it) {\n var then;\n return isObject(it) && isCallable(then = it.then) ? then : false;\n};\n\nvar callReaction = function (reaction, state) {\n var value = state.value;\n var ok = state.state == FULFILLED;\n var handler = ok ? reaction.ok : reaction.fail;\n var resolve = reaction.resolve;\n var reject = reaction.reject;\n var domain = reaction.domain;\n var result, then, exited;\n try {\n if (handler) {\n if (!ok) {\n if (state.rejection === UNHANDLED) onHandleUnhandled(state);\n state.rejection = HANDLED;\n }\n if (handler === true) result = value;\n else {\n if (domain) domain.enter();\n result = handler(value); // can throw\n if (domain) {\n domain.exit();\n exited = true;\n }\n }\n if (result === reaction.promise) {\n reject(TypeError('Promise-chain cycle'));\n } else if (then = isThenable(result)) {\n call(then, result, resolve, reject);\n } else resolve(result);\n } else reject(value);\n } catch (error) {\n if (domain && !exited) domain.exit();\n reject(error);\n }\n};\n\nvar notify = function (state, isReject) {\n if (state.notified) return;\n state.notified = true;\n microtask(function () {\n var reactions = state.reactions;\n var reaction;\n while (reaction = reactions.get()) {\n callReaction(reaction, state);\n }\n state.notified = false;\n if (isReject && !state.rejection) onUnhandled(state);\n });\n};\n\nvar dispatchEvent = function (name, promise, reason) {\n var event, handler;\n if (DISPATCH_EVENT) {\n event = document.createEvent('Event');\n event.promise = promise;\n event.reason = reason;\n event.initEvent(name, false, true);\n global.dispatchEvent(event);\n } else event = { promise: promise, reason: reason };\n if (!NATIVE_REJECTION_EVENT && (handler = global['on' + name])) handler(event);\n else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);\n};\n\nvar onUnhandled = function (state) {\n call(task, global, function () {\n var promise = state.facade;\n var value = state.value;\n var IS_UNHANDLED = isUnhandled(state);\n var result;\n if (IS_UNHANDLED) {\n result = perform(function () {\n if (IS_NODE) {\n process.emit('unhandledRejection', value, promise);\n } else dispatchEvent(UNHANDLED_REJECTION, promise, value);\n });\n // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should\n state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;\n if (result.error) throw result.value;\n }\n });\n};\n\nvar isUnhandled = function (state) {\n return state.rejection !== HANDLED && !state.parent;\n};\n\nvar onHandleUnhandled = function (state) {\n call(task, global, function () {\n var promise = state.facade;\n if (IS_NODE) {\n process.emit('rejectionHandled', promise);\n } else dispatchEvent(REJECTION_HANDLED, promise, state.value);\n });\n};\n\nvar bind = function (fn, state, unwrap) {\n return function (value) {\n fn(state, value, unwrap);\n };\n};\n\nvar internalReject = function (state, value, unwrap) {\n if (state.done) return;\n state.done = true;\n if (unwrap) state = unwrap;\n state.value = value;\n state.state = REJECTED;\n notify(state, true);\n};\n\nvar internalResolve = function (state, value, unwrap) {\n if (state.done) return;\n state.done = true;\n if (unwrap) state = unwrap;\n try {\n if (state.facade === value) throw TypeError(\"Promise can't be resolved itself\");\n var then = isThenable(value);\n if (then) {\n microtask(function () {\n var wrapper = { done: false };\n try {\n call(then, value,\n bind(internalResolve, wrapper, state),\n bind(internalReject, wrapper, state)\n );\n } catch (error) {\n internalReject(wrapper, error, state);\n }\n });\n } else {\n state.value = value;\n state.state = FULFILLED;\n notify(state, false);\n }\n } catch (error) {\n internalReject({ done: false }, error, state);\n }\n};\n\n// constructor polyfill\nif (FORCED) {\n // 25.4.3.1 Promise(executor)\n PromiseConstructor = function Promise(executor) {\n anInstance(this, PromisePrototype);\n aCallable(executor);\n call(Internal, this);\n var state = getInternalState(this);\n try {\n executor(bind(internalResolve, state), bind(internalReject, state));\n } catch (error) {\n internalReject(state, error);\n }\n };\n PromisePrototype = PromiseConstructor.prototype;\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n Internal = function Promise(executor) {\n setInternalState(this, {\n type: PROMISE,\n done: false,\n notified: false,\n parent: false,\n reactions: new Queue(),\n rejection: false,\n state: PENDING,\n value: undefined\n });\n };\n Internal.prototype = redefineAll(PromisePrototype, {\n // `Promise.prototype.then` method\n // https://tc39.es/ecma262/#sec-promise.prototype.then\n // eslint-disable-next-line unicorn/no-thenable -- safe\n then: function then(onFulfilled, onRejected) {\n var state = getInternalPromiseState(this);\n var reaction = newPromiseCapability(speciesConstructor(this, PromiseConstructor));\n state.parent = true;\n reaction.ok = isCallable(onFulfilled) ? onFulfilled : true;\n reaction.fail = isCallable(onRejected) && onRejected;\n reaction.domain = IS_NODE ? process.domain : undefined;\n if (state.state == PENDING) state.reactions.add(reaction);\n else microtask(function () {\n callReaction(reaction, state);\n });\n return reaction.promise;\n },\n // `Promise.prototype.catch` method\n // https://tc39.es/ecma262/#sec-promise.prototype.catch\n 'catch': function (onRejected) {\n return this.then(undefined, onRejected);\n }\n });\n OwnPromiseCapability = function () {\n var promise = new Internal();\n var state = getInternalState(promise);\n this.promise = promise;\n this.resolve = bind(internalResolve, state);\n this.reject = bind(internalReject, state);\n };\n newPromiseCapabilityModule.f = newPromiseCapability = function (C) {\n return C === PromiseConstructor || C === PromiseWrapper\n ? new OwnPromiseCapability(C)\n : newGenericPromiseCapability(C);\n };\n\n if (!IS_PURE && isCallable(NativePromise) && NativePromisePrototype !== Object.prototype) {\n nativeThen = NativePromisePrototype.then;\n\n if (!SUBCLASSING) {\n // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs\n redefine(NativePromisePrototype, 'then', function then(onFulfilled, onRejected) {\n var that = this;\n return new PromiseConstructor(function (resolve, reject) {\n call(nativeThen, that, resolve, reject);\n }).then(onFulfilled, onRejected);\n // https://github.com/zloirock/core-js/issues/640\n }, { unsafe: true });\n\n // makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`\n redefine(NativePromisePrototype, 'catch', PromisePrototype['catch'], { unsafe: true });\n }\n\n // make `.constructor === Promise` work for native promise-based APIs\n try {\n delete NativePromisePrototype.constructor;\n } catch (error) { /* empty */ }\n\n // make `instanceof Promise` work for native promise-based APIs\n if (setPrototypeOf) {\n setPrototypeOf(NativePromisePrototype, PromisePrototype);\n }\n }\n}\n\n$({ global: true, wrap: true, forced: FORCED }, {\n Promise: PromiseConstructor\n});\n\nsetToStringTag(PromiseConstructor, PROMISE, false, true);\nsetSpecies(PROMISE);\n\nPromiseWrapper = getBuiltIn(PROMISE);\n\n// statics\n$({ target: PROMISE, stat: true, forced: FORCED }, {\n // `Promise.reject` method\n // https://tc39.es/ecma262/#sec-promise.reject\n reject: function reject(r) {\n var capability = newPromiseCapability(this);\n call(capability.reject, undefined, r);\n return capability.promise;\n }\n});\n\n$({ target: PROMISE, stat: true, forced: IS_PURE || FORCED }, {\n // `Promise.resolve` method\n // https://tc39.es/ecma262/#sec-promise.resolve\n resolve: function resolve(x) {\n return promiseResolve(IS_PURE && this === PromiseWrapper ? PromiseConstructor : this, x);\n }\n});\n\n$({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {\n // `Promise.all` method\n // https://tc39.es/ecma262/#sec-promise.all\n all: function all(iterable) {\n var C = this;\n var capability = newPromiseCapability(C);\n var resolve = capability.resolve;\n var reject = capability.reject;\n var result = perform(function () {\n var $promiseResolve = aCallable(C.resolve);\n var values = [];\n var counter = 0;\n var remaining = 1;\n iterate(iterable, function (promise) {\n var index = counter++;\n var alreadyCalled = false;\n remaining++;\n call($promiseResolve, C, promise).then(function (value) {\n if (alreadyCalled) return;\n alreadyCalled = true;\n values[index] = value;\n --remaining || resolve(values);\n }, reject);\n });\n --remaining || resolve(values);\n });\n if (result.error) reject(result.value);\n return capability.promise;\n },\n // `Promise.race` method\n // https://tc39.es/ecma262/#sec-promise.race\n race: function race(iterable) {\n var C = this;\n var capability = newPromiseCapability(C);\n var reject = capability.reject;\n var result = perform(function () {\n var $promiseResolve = aCallable(C.resolve);\n iterate(iterable, function (promise) {\n call($promiseResolve, C, promise).then(capability.resolve, reject);\n });\n });\n if (result.error) reject(result.value);\n return capability.promise;\n }\n});\n","var $ = require('../internals/export');\n\n// `Reflect.has` method\n// https://tc39.es/ecma262/#sec-reflect.has\n$({ target: 'Reflect', stat: true }, {\n has: function has(target, propertyKey) {\n return propertyKey in target;\n }\n});\n","var $ = require('../internals/export');\nvar ownKeys = require('../internals/own-keys');\n\n// `Reflect.ownKeys` method\n// https://tc39.es/ecma262/#sec-reflect.ownkeys\n$({ target: 'Reflect', stat: true }, {\n ownKeys: ownKeys\n});\n","var $ = require('../internals/export');\nvar global = require('../internals/global');\nvar setToStringTag = require('../internals/set-to-string-tag');\n\n$({ global: true }, { Reflect: {} });\n\n// Reflect[@@toStringTag] property\n// https://tc39.es/ecma262/#sec-reflect-@@tostringtag\nsetToStringTag(global.Reflect, 'Reflect', true);\n","'use strict';\nvar $ = require('../internals/export');\nvar exec = require('../internals/regexp-exec');\n\n// `RegExp.prototype.exec` method\n// https://tc39.es/ecma262/#sec-regexp.prototype.exec\n$({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {\n exec: exec\n});\n","'use strict';\n// TODO: Remove from `core-js@4` since it's moved to entry points\nrequire('../modules/es.regexp.exec');\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\n\nvar DELEGATES_TO_EXEC = function () {\n var execCalled = false;\n var re = /[ac]/;\n re.exec = function () {\n execCalled = true;\n return /./.exec.apply(this, arguments);\n };\n return re.test('abc') === true && execCalled;\n}();\n\nvar Error = global.Error;\nvar un$Test = uncurryThis(/./.test);\n\n// `RegExp.prototype.test` method\n// https://tc39.es/ecma262/#sec-regexp.prototype.test\n$({ target: 'RegExp', proto: true, forced: !DELEGATES_TO_EXEC }, {\n test: function (str) {\n var exec = this.exec;\n if (!isCallable(exec)) return un$Test(this, str);\n var result = call(exec, this, str);\n if (result !== null && !isObject(result)) {\n throw new Error('RegExp exec method returned something other than an Object or null');\n }\n return !!result;\n }\n});\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar PROPER_FUNCTION_NAME = require('../internals/function-name').PROPER;\nvar redefine = require('../internals/redefine');\nvar anObject = require('../internals/an-object');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar $toString = require('../internals/to-string');\nvar fails = require('../internals/fails');\nvar regExpFlags = require('../internals/regexp-flags');\n\nvar TO_STRING = 'toString';\nvar RegExpPrototype = RegExp.prototype;\nvar n$ToString = RegExpPrototype[TO_STRING];\nvar getFlags = uncurryThis(regExpFlags);\n\nvar NOT_GENERIC = fails(function () { return n$ToString.call({ source: 'a', flags: 'b' }) != '/a/b'; });\n// FF44- RegExp#toString has a wrong name\nvar INCORRECT_NAME = PROPER_FUNCTION_NAME && n$ToString.name != TO_STRING;\n\n// `RegExp.prototype.toString` method\n// https://tc39.es/ecma262/#sec-regexp.prototype.tostring\nif (NOT_GENERIC || INCORRECT_NAME) {\n redefine(RegExp.prototype, TO_STRING, function toString() {\n var R = anObject(this);\n var p = $toString(R.source);\n var rf = R.flags;\n var f = $toString(rf === undefined && isPrototypeOf(RegExpPrototype, R) && !('flags' in RegExpPrototype) ? getFlags(R) : rf);\n return '/' + p + '/' + f;\n }, { unsafe: true });\n}\n","'use strict';\nvar collection = require('../internals/collection');\nvar collectionStrong = require('../internals/collection-strong');\n\n// `Set` constructor\n// https://tc39.es/ecma262/#sec-set-objects\ncollection('Set', function (init) {\n return function Set() { return init(this, arguments.length ? arguments[0] : undefined); };\n}, collectionStrong);\n","'use strict';\nvar $ = require('../internals/export');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar notARegExp = require('../internals/not-a-regexp');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar toString = require('../internals/to-string');\nvar correctIsRegExpLogic = require('../internals/correct-is-regexp-logic');\n\nvar stringIndexOf = uncurryThis(''.indexOf);\n\n// `String.prototype.includes` method\n// https://tc39.es/ecma262/#sec-string.prototype.includes\n$({ target: 'String', proto: true, forced: !correctIsRegExpLogic('includes') }, {\n includes: function includes(searchString /* , position = 0 */) {\n return !!~stringIndexOf(\n toString(requireObjectCoercible(this)),\n toString(notARegExp(searchString)),\n arguments.length > 1 ? arguments[1] : undefined\n );\n }\n});\n","'use strict';\nvar charAt = require('../internals/string-multibyte').charAt;\nvar toString = require('../internals/to-string');\nvar InternalStateModule = require('../internals/internal-state');\nvar defineIterator = require('../internals/define-iterator');\n\nvar STRING_ITERATOR = 'String Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);\n\n// `String.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-string.prototype-@@iterator\ndefineIterator(String, 'String', function (iterated) {\n setInternalState(this, {\n type: STRING_ITERATOR,\n string: toString(iterated),\n index: 0\n });\n// `%StringIteratorPrototype%.next` method\n// https://tc39.es/ecma262/#sec-%stringiteratorprototype%.next\n}, function next() {\n var state = getInternalState(this);\n var string = state.string;\n var index = state.index;\n var point;\n if (index >= string.length) return { value: undefined, done: true };\n point = charAt(string, index);\n state.index += point.length;\n return { value: point, done: false };\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar createHTML = require('../internals/create-html');\nvar forcedStringHTMLMethod = require('../internals/string-html-forced');\n\n// `String.prototype.link` method\n// https://tc39.es/ecma262/#sec-string.prototype.link\n$({ target: 'String', proto: true, forced: forcedStringHTMLMethod('link') }, {\n link: function link(url) {\n return createHTML(this, 'a', 'href', url);\n }\n});\n","var $ = require('../internals/export');\nvar repeat = require('../internals/string-repeat');\n\n// `String.prototype.repeat` method\n// https://tc39.es/ecma262/#sec-string.prototype.repeat\n$({ target: 'String', proto: true }, {\n repeat: repeat\n});\n","'use strict';\nvar apply = require('../internals/function-apply');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fixRegExpWellKnownSymbolLogic = require('../internals/fix-regexp-well-known-symbol-logic');\nvar fails = require('../internals/fails');\nvar anObject = require('../internals/an-object');\nvar isCallable = require('../internals/is-callable');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toLength = require('../internals/to-length');\nvar toString = require('../internals/to-string');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar advanceStringIndex = require('../internals/advance-string-index');\nvar getMethod = require('../internals/get-method');\nvar getSubstitution = require('../internals/get-substitution');\nvar regExpExec = require('../internals/regexp-exec-abstract');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar REPLACE = wellKnownSymbol('replace');\nvar max = Math.max;\nvar min = Math.min;\nvar concat = uncurryThis([].concat);\nvar push = uncurryThis([].push);\nvar stringIndexOf = uncurryThis(''.indexOf);\nvar stringSlice = uncurryThis(''.slice);\n\nvar maybeToString = function (it) {\n return it === undefined ? it : String(it);\n};\n\n// IE <= 11 replaces $0 with the whole match, as if it was $&\n// https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0\nvar REPLACE_KEEPS_$0 = (function () {\n // eslint-disable-next-line regexp/prefer-escape-replacement-dollar-char -- required for testing\n return 'a'.replace(/./, '$0') === '$0';\n})();\n\n// Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string\nvar REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {\n if (/./[REPLACE]) {\n return /./[REPLACE]('a', '$0') === '';\n }\n return false;\n})();\n\nvar REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {\n var re = /./;\n re.exec = function () {\n var result = [];\n result.groups = { a: '7' };\n return result;\n };\n // eslint-disable-next-line regexp/no-useless-dollar-replacements -- false positive\n return ''.replace(re, '$<a>') !== '7';\n});\n\n// @@replace logic\nfixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNative) {\n var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';\n\n return [\n // `String.prototype.replace` method\n // https://tc39.es/ecma262/#sec-string.prototype.replace\n function replace(searchValue, replaceValue) {\n var O = requireObjectCoercible(this);\n var replacer = searchValue == undefined ? undefined : getMethod(searchValue, REPLACE);\n return replacer\n ? call(replacer, searchValue, O, replaceValue)\n : call(nativeReplace, toString(O), searchValue, replaceValue);\n },\n // `RegExp.prototype[@@replace]` method\n // https://tc39.es/ecma262/#sec-regexp.prototype-@@replace\n function (string, replaceValue) {\n var rx = anObject(this);\n var S = toString(string);\n\n if (\n typeof replaceValue == 'string' &&\n stringIndexOf(replaceValue, UNSAFE_SUBSTITUTE) === -1 &&\n stringIndexOf(replaceValue, '$<') === -1\n ) {\n var res = maybeCallNative(nativeReplace, rx, S, replaceValue);\n if (res.done) return res.value;\n }\n\n var functionalReplace = isCallable(replaceValue);\n if (!functionalReplace) replaceValue = toString(replaceValue);\n\n var global = rx.global;\n if (global) {\n var fullUnicode = rx.unicode;\n rx.lastIndex = 0;\n }\n var results = [];\n while (true) {\n var result = regExpExec(rx, S);\n if (result === null) break;\n\n push(results, result);\n if (!global) break;\n\n var matchStr = toString(result[0]);\n if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);\n }\n\n var accumulatedResult = '';\n var nextSourcePosition = 0;\n for (var i = 0; i < results.length; i++) {\n result = results[i];\n\n var matched = toString(result[0]);\n var position = max(min(toIntegerOrInfinity(result.index), S.length), 0);\n var captures = [];\n // NOTE: This is equivalent to\n // captures = result.slice(1).map(maybeToString)\n // but for some reason `nativeSlice.call(result, 1, result.length)` (called in\n // the slice polyfill when slicing native arrays) \"doesn't work\" in safari 9 and\n // causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.\n for (var j = 1; j < result.length; j++) push(captures, maybeToString(result[j]));\n var namedCaptures = result.groups;\n if (functionalReplace) {\n var replacerArgs = concat([matched], captures, position, S);\n if (namedCaptures !== undefined) push(replacerArgs, namedCaptures);\n var replacement = toString(apply(replaceValue, undefined, replacerArgs));\n } else {\n replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);\n }\n if (position >= nextSourcePosition) {\n accumulatedResult += stringSlice(S, nextSourcePosition, position) + replacement;\n nextSourcePosition = position + matched.length;\n }\n }\n return accumulatedResult + stringSlice(S, nextSourcePosition);\n }\n ];\n}, !REPLACE_SUPPORTS_NAMED_GROUPS || !REPLACE_KEEPS_$0 || REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE);\n","'use strict';\nvar $ = require('../internals/export');\nvar createHTML = require('../internals/create-html');\nvar forcedStringHTMLMethod = require('../internals/string-html-forced');\n\n// `String.prototype.small` method\n// https://tc39.es/ecma262/#sec-string.prototype.small\n$({ target: 'String', proto: true, forced: forcedStringHTMLMethod('small') }, {\n small: function small() {\n return createHTML(this, 'small', '', '');\n }\n});\n","'use strict';\nvar apply = require('../internals/function-apply');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fixRegExpWellKnownSymbolLogic = require('../internals/fix-regexp-well-known-symbol-logic');\nvar isRegExp = require('../internals/is-regexp');\nvar anObject = require('../internals/an-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar speciesConstructor = require('../internals/species-constructor');\nvar advanceStringIndex = require('../internals/advance-string-index');\nvar toLength = require('../internals/to-length');\nvar toString = require('../internals/to-string');\nvar getMethod = require('../internals/get-method');\nvar arraySlice = require('../internals/array-slice-simple');\nvar callRegExpExec = require('../internals/regexp-exec-abstract');\nvar regexpExec = require('../internals/regexp-exec');\nvar stickyHelpers = require('../internals/regexp-sticky-helpers');\nvar fails = require('../internals/fails');\n\nvar UNSUPPORTED_Y = stickyHelpers.UNSUPPORTED_Y;\nvar MAX_UINT32 = 0xFFFFFFFF;\nvar min = Math.min;\nvar $push = [].push;\nvar exec = uncurryThis(/./.exec);\nvar push = uncurryThis($push);\nvar stringSlice = uncurryThis(''.slice);\n\n// Chrome 51 has a buggy \"split\" implementation when RegExp#exec !== nativeExec\n// Weex JS has frozen built-in prototypes, so use try / catch wrapper\nvar SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails(function () {\n // eslint-disable-next-line regexp/no-empty-group -- required for testing\n var re = /(?:)/;\n var originalExec = re.exec;\n re.exec = function () { return originalExec.apply(this, arguments); };\n var result = 'ab'.split(re);\n return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';\n});\n\n// @@split logic\nfixRegExpWellKnownSymbolLogic('split', function (SPLIT, nativeSplit, maybeCallNative) {\n var internalSplit;\n if (\n 'abbc'.split(/(b)*/)[1] == 'c' ||\n // eslint-disable-next-line regexp/no-empty-group -- required for testing\n 'test'.split(/(?:)/, -1).length != 4 ||\n 'ab'.split(/(?:ab)*/).length != 2 ||\n '.'.split(/(.?)(.?)/).length != 4 ||\n // eslint-disable-next-line regexp/no-empty-capturing-group, regexp/no-empty-group -- required for testing\n '.'.split(/()()/).length > 1 ||\n ''.split(/.?/).length\n ) {\n // based on es5-shim implementation, need to rework it\n internalSplit = function (separator, limit) {\n var string = toString(requireObjectCoercible(this));\n var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;\n if (lim === 0) return [];\n if (separator === undefined) return [string];\n // If `separator` is not a regex, use native split\n if (!isRegExp(separator)) {\n return call(nativeSplit, string, separator, lim);\n }\n var output = [];\n var flags = (separator.ignoreCase ? 'i' : '') +\n (separator.multiline ? 'm' : '') +\n (separator.unicode ? 'u' : '') +\n (separator.sticky ? 'y' : '');\n var lastLastIndex = 0;\n // Make `global` and avoid `lastIndex` issues by working with a copy\n var separatorCopy = new RegExp(separator.source, flags + 'g');\n var match, lastIndex, lastLength;\n while (match = call(regexpExec, separatorCopy, string)) {\n lastIndex = separatorCopy.lastIndex;\n if (lastIndex > lastLastIndex) {\n push(output, stringSlice(string, lastLastIndex, match.index));\n if (match.length > 1 && match.index < string.length) apply($push, output, arraySlice(match, 1));\n lastLength = match[0].length;\n lastLastIndex = lastIndex;\n if (output.length >= lim) break;\n }\n if (separatorCopy.lastIndex === match.index) separatorCopy.lastIndex++; // Avoid an infinite loop\n }\n if (lastLastIndex === string.length) {\n if (lastLength || !exec(separatorCopy, '')) push(output, '');\n } else push(output, stringSlice(string, lastLastIndex));\n return output.length > lim ? arraySlice(output, 0, lim) : output;\n };\n // Chakra, V8\n } else if ('0'.split(undefined, 0).length) {\n internalSplit = function (separator, limit) {\n return separator === undefined && limit === 0 ? [] : call(nativeSplit, this, separator, limit);\n };\n } else internalSplit = nativeSplit;\n\n return [\n // `String.prototype.split` method\n // https://tc39.es/ecma262/#sec-string.prototype.split\n function split(separator, limit) {\n var O = requireObjectCoercible(this);\n var splitter = separator == undefined ? undefined : getMethod(separator, SPLIT);\n return splitter\n ? call(splitter, separator, O, limit)\n : call(internalSplit, toString(O), separator, limit);\n },\n // `RegExp.prototype[@@split]` method\n // https://tc39.es/ecma262/#sec-regexp.prototype-@@split\n //\n // NOTE: This cannot be properly polyfilled in engines that don't support\n // the 'y' flag.\n function (string, limit) {\n var rx = anObject(this);\n var S = toString(string);\n var res = maybeCallNative(internalSplit, rx, S, limit, internalSplit !== nativeSplit);\n\n if (res.done) return res.value;\n\n var C = speciesConstructor(rx, RegExp);\n\n var unicodeMatching = rx.unicode;\n var flags = (rx.ignoreCase ? 'i' : '') +\n (rx.multiline ? 'm' : '') +\n (rx.unicode ? 'u' : '') +\n (UNSUPPORTED_Y ? 'g' : 'y');\n\n // ^(? + rx + ) is needed, in combination with some S slicing, to\n // simulate the 'y' flag.\n var splitter = new C(UNSUPPORTED_Y ? '^(?:' + rx.source + ')' : rx, flags);\n var lim = limit === undefined ? MAX_UINT32 : limit >>> 0;\n if (lim === 0) return [];\n if (S.length === 0) return callRegExpExec(splitter, S) === null ? [S] : [];\n var p = 0;\n var q = 0;\n var A = [];\n while (q < S.length) {\n splitter.lastIndex = UNSUPPORTED_Y ? 0 : q;\n var z = callRegExpExec(splitter, UNSUPPORTED_Y ? stringSlice(S, q) : S);\n var e;\n if (\n z === null ||\n (e = min(toLength(splitter.lastIndex + (UNSUPPORTED_Y ? q : 0)), S.length)) === p\n ) {\n q = advanceStringIndex(S, q, unicodeMatching);\n } else {\n push(A, stringSlice(S, p, q));\n if (A.length === lim) return A;\n for (var i = 1; i <= z.length - 1; i++) {\n push(A, z[i]);\n if (A.length === lim) return A;\n }\n q = p = e;\n }\n }\n push(A, stringSlice(S, p));\n return A;\n }\n ];\n}, !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC, UNSUPPORTED_Y);\n","'use strict';\nvar $ = require('../internals/export');\nvar createHTML = require('../internals/create-html');\nvar forcedStringHTMLMethod = require('../internals/string-html-forced');\n\n// `String.prototype.sub` method\n// https://tc39.es/ecma262/#sec-string.prototype.sub\n$({ target: 'String', proto: true, forced: forcedStringHTMLMethod('sub') }, {\n sub: function sub() {\n return createHTML(this, 'sub', '', '');\n }\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar $trim = require('../internals/string-trim').trim;\nvar forcedStringTrimMethod = require('../internals/string-trim-forced');\n\n// `String.prototype.trim` method\n// https://tc39.es/ecma262/#sec-string.prototype.trim\n$({ target: 'String', proto: true, forced: forcedStringTrimMethod('trim') }, {\n trim: function trim() {\n return $trim(this);\n }\n});\n","// `Symbol.prototype.description` getter\n// https://tc39.es/ecma262/#sec-symbol.prototype.description\n'use strict';\nvar $ = require('../internals/export');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\nvar isCallable = require('../internals/is-callable');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar toString = require('../internals/to-string');\nvar defineProperty = require('../internals/object-define-property').f;\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\n\nvar NativeSymbol = global.Symbol;\nvar SymbolPrototype = NativeSymbol && NativeSymbol.prototype;\n\nif (DESCRIPTORS && isCallable(NativeSymbol) && (!('description' in SymbolPrototype) ||\n // Safari 12 bug\n NativeSymbol().description !== undefined\n)) {\n var EmptyStringDescriptionStore = {};\n // wrap Symbol constructor for correct work with undefined description\n var SymbolWrapper = function Symbol() {\n var description = arguments.length < 1 || arguments[0] === undefined ? undefined : toString(arguments[0]);\n var result = isPrototypeOf(SymbolPrototype, this)\n ? new NativeSymbol(description)\n // in Edge 13, String(Symbol(undefined)) === 'Symbol(undefined)'\n : description === undefined ? NativeSymbol() : NativeSymbol(description);\n if (description === '') EmptyStringDescriptionStore[result] = true;\n return result;\n };\n\n copyConstructorProperties(SymbolWrapper, NativeSymbol);\n SymbolWrapper.prototype = SymbolPrototype;\n SymbolPrototype.constructor = SymbolWrapper;\n\n var NATIVE_SYMBOL = String(NativeSymbol('test')) == 'Symbol(test)';\n var symbolToString = uncurryThis(SymbolPrototype.toString);\n var symbolValueOf = uncurryThis(SymbolPrototype.valueOf);\n var regexp = /^Symbol\\((.*)\\)[^)]+$/;\n var replace = uncurryThis(''.replace);\n var stringSlice = uncurryThis(''.slice);\n\n defineProperty(SymbolPrototype, 'description', {\n configurable: true,\n get: function description() {\n var symbol = symbolValueOf(this);\n var string = symbolToString(symbol);\n if (hasOwn(EmptyStringDescriptionStore, symbol)) return '';\n var desc = NATIVE_SYMBOL ? stringSlice(string, 7, -1) : replace(string, regexp, '$1');\n return desc === '' ? undefined : desc;\n }\n });\n\n $({ global: true, forced: true }, {\n Symbol: SymbolWrapper\n });\n}\n","var defineWellKnownSymbol = require('../internals/define-well-known-symbol');\n\n// `Symbol.iterator` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.iterator\ndefineWellKnownSymbol('iterator');\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar apply = require('../internals/function-apply');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IS_PURE = require('../internals/is-pure');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\nvar fails = require('../internals/fails');\nvar hasOwn = require('../internals/has-own-property');\nvar isArray = require('../internals/is-array');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar isSymbol = require('../internals/is-symbol');\nvar anObject = require('../internals/an-object');\nvar toObject = require('../internals/to-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar $toString = require('../internals/to-string');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar nativeObjectCreate = require('../internals/object-create');\nvar objectKeys = require('../internals/object-keys');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertyNamesExternal = require('../internals/object-get-own-property-names-external');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\nvar definePropertiesModule = require('../internals/object-define-properties');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar arraySlice = require('../internals/array-slice');\nvar redefine = require('../internals/redefine');\nvar shared = require('../internals/shared');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar uid = require('../internals/uid');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar wrappedWellKnownSymbolModule = require('../internals/well-known-symbol-wrapped');\nvar defineWellKnownSymbol = require('../internals/define-well-known-symbol');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar InternalStateModule = require('../internals/internal-state');\nvar $forEach = require('../internals/array-iteration').forEach;\n\nvar HIDDEN = sharedKey('hidden');\nvar SYMBOL = 'Symbol';\nvar PROTOTYPE = 'prototype';\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(SYMBOL);\n\nvar ObjectPrototype = Object[PROTOTYPE];\nvar $Symbol = global.Symbol;\nvar SymbolPrototype = $Symbol && $Symbol[PROTOTYPE];\nvar TypeError = global.TypeError;\nvar QObject = global.QObject;\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\nvar nativeDefineProperty = definePropertyModule.f;\nvar nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f;\nvar nativePropertyIsEnumerable = propertyIsEnumerableModule.f;\nvar push = uncurryThis([].push);\n\nvar AllSymbols = shared('symbols');\nvar ObjectPrototypeSymbols = shared('op-symbols');\nvar StringToSymbolRegistry = shared('string-to-symbol-registry');\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\nvar WellKnownSymbolsStore = shared('wks');\n\n// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173\nvar USE_SETTER = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;\n\n// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687\nvar setSymbolDescriptor = DESCRIPTORS && fails(function () {\n return nativeObjectCreate(nativeDefineProperty({}, 'a', {\n get: function () { return nativeDefineProperty(this, 'a', { value: 7 }).a; }\n })).a != 7;\n}) ? function (O, P, Attributes) {\n var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor(ObjectPrototype, P);\n if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];\n nativeDefineProperty(O, P, Attributes);\n if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {\n nativeDefineProperty(ObjectPrototype, P, ObjectPrototypeDescriptor);\n }\n} : nativeDefineProperty;\n\nvar wrap = function (tag, description) {\n var symbol = AllSymbols[tag] = nativeObjectCreate(SymbolPrototype);\n setInternalState(symbol, {\n type: SYMBOL,\n tag: tag,\n description: description\n });\n if (!DESCRIPTORS) symbol.description = description;\n return symbol;\n};\n\nvar $defineProperty = function defineProperty(O, P, Attributes) {\n if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);\n anObject(O);\n var key = toPropertyKey(P);\n anObject(Attributes);\n if (hasOwn(AllSymbols, key)) {\n if (!Attributes.enumerable) {\n if (!hasOwn(O, HIDDEN)) nativeDefineProperty(O, HIDDEN, createPropertyDescriptor(1, {}));\n O[HIDDEN][key] = true;\n } else {\n if (hasOwn(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;\n Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });\n } return setSymbolDescriptor(O, key, Attributes);\n } return nativeDefineProperty(O, key, Attributes);\n};\n\nvar $defineProperties = function defineProperties(O, Properties) {\n anObject(O);\n var properties = toIndexedObject(Properties);\n var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));\n $forEach(keys, function (key) {\n if (!DESCRIPTORS || call($propertyIsEnumerable, properties, key)) $defineProperty(O, key, properties[key]);\n });\n return O;\n};\n\nvar $create = function create(O, Properties) {\n return Properties === undefined ? nativeObjectCreate(O) : $defineProperties(nativeObjectCreate(O), Properties);\n};\n\nvar $propertyIsEnumerable = function propertyIsEnumerable(V) {\n var P = toPropertyKey(V);\n var enumerable = call(nativePropertyIsEnumerable, this, P);\n if (this === ObjectPrototype && hasOwn(AllSymbols, P) && !hasOwn(ObjectPrototypeSymbols, P)) return false;\n return enumerable || !hasOwn(this, P) || !hasOwn(AllSymbols, P) || hasOwn(this, HIDDEN) && this[HIDDEN][P]\n ? enumerable : true;\n};\n\nvar $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {\n var it = toIndexedObject(O);\n var key = toPropertyKey(P);\n if (it === ObjectPrototype && hasOwn(AllSymbols, key) && !hasOwn(ObjectPrototypeSymbols, key)) return;\n var descriptor = nativeGetOwnPropertyDescriptor(it, key);\n if (descriptor && hasOwn(AllSymbols, key) && !(hasOwn(it, HIDDEN) && it[HIDDEN][key])) {\n descriptor.enumerable = true;\n }\n return descriptor;\n};\n\nvar $getOwnPropertyNames = function getOwnPropertyNames(O) {\n var names = nativeGetOwnPropertyNames(toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (!hasOwn(AllSymbols, key) && !hasOwn(hiddenKeys, key)) push(result, key);\n });\n return result;\n};\n\nvar $getOwnPropertySymbols = function getOwnPropertySymbols(O) {\n var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;\n var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (hasOwn(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || hasOwn(ObjectPrototype, key))) {\n push(result, AllSymbols[key]);\n }\n });\n return result;\n};\n\n// `Symbol` constructor\n// https://tc39.es/ecma262/#sec-symbol-constructor\nif (!NATIVE_SYMBOL) {\n $Symbol = function Symbol() {\n if (isPrototypeOf(SymbolPrototype, this)) throw TypeError('Symbol is not a constructor');\n var description = !arguments.length || arguments[0] === undefined ? undefined : $toString(arguments[0]);\n var tag = uid(description);\n var setter = function (value) {\n if (this === ObjectPrototype) call(setter, ObjectPrototypeSymbols, value);\n if (hasOwn(this, HIDDEN) && hasOwn(this[HIDDEN], tag)) this[HIDDEN][tag] = false;\n setSymbolDescriptor(this, tag, createPropertyDescriptor(1, value));\n };\n if (DESCRIPTORS && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });\n return wrap(tag, description);\n };\n\n SymbolPrototype = $Symbol[PROTOTYPE];\n\n redefine(SymbolPrototype, 'toString', function toString() {\n return getInternalState(this).tag;\n });\n\n redefine($Symbol, 'withoutSetter', function (description) {\n return wrap(uid(description), description);\n });\n\n propertyIsEnumerableModule.f = $propertyIsEnumerable;\n definePropertyModule.f = $defineProperty;\n definePropertiesModule.f = $defineProperties;\n getOwnPropertyDescriptorModule.f = $getOwnPropertyDescriptor;\n getOwnPropertyNamesModule.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames;\n getOwnPropertySymbolsModule.f = $getOwnPropertySymbols;\n\n wrappedWellKnownSymbolModule.f = function (name) {\n return wrap(wellKnownSymbol(name), name);\n };\n\n if (DESCRIPTORS) {\n // https://github.com/tc39/proposal-Symbol-description\n nativeDefineProperty(SymbolPrototype, 'description', {\n configurable: true,\n get: function description() {\n return getInternalState(this).description;\n }\n });\n if (!IS_PURE) {\n redefine(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });\n }\n }\n}\n\n$({ global: true, wrap: true, forced: !NATIVE_SYMBOL, sham: !NATIVE_SYMBOL }, {\n Symbol: $Symbol\n});\n\n$forEach(objectKeys(WellKnownSymbolsStore), function (name) {\n defineWellKnownSymbol(name);\n});\n\n$({ target: SYMBOL, stat: true, forced: !NATIVE_SYMBOL }, {\n // `Symbol.for` method\n // https://tc39.es/ecma262/#sec-symbol.for\n 'for': function (key) {\n var string = $toString(key);\n if (hasOwn(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];\n var symbol = $Symbol(string);\n StringToSymbolRegistry[string] = symbol;\n SymbolToStringRegistry[symbol] = string;\n return symbol;\n },\n // `Symbol.keyFor` method\n // https://tc39.es/ecma262/#sec-symbol.keyfor\n keyFor: function keyFor(sym) {\n if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol');\n if (hasOwn(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];\n },\n useSetter: function () { USE_SETTER = true; },\n useSimple: function () { USE_SETTER = false; }\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL, sham: !DESCRIPTORS }, {\n // `Object.create` method\n // https://tc39.es/ecma262/#sec-object.create\n create: $create,\n // `Object.defineProperty` method\n // https://tc39.es/ecma262/#sec-object.defineproperty\n defineProperty: $defineProperty,\n // `Object.defineProperties` method\n // https://tc39.es/ecma262/#sec-object.defineproperties\n defineProperties: $defineProperties,\n // `Object.getOwnPropertyDescriptor` method\n // https://tc39.es/ecma262/#sec-object.getownpropertydescriptors\n getOwnPropertyDescriptor: $getOwnPropertyDescriptor\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL }, {\n // `Object.getOwnPropertyNames` method\n // https://tc39.es/ecma262/#sec-object.getownpropertynames\n getOwnPropertyNames: $getOwnPropertyNames,\n // `Object.getOwnPropertySymbols` method\n // https://tc39.es/ecma262/#sec-object.getownpropertysymbols\n getOwnPropertySymbols: $getOwnPropertySymbols\n});\n\n// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives\n// https://bugs.chromium.org/p/v8/issues/detail?id=3443\n$({ target: 'Object', stat: true, forced: fails(function () { getOwnPropertySymbolsModule.f(1); }) }, {\n getOwnPropertySymbols: function getOwnPropertySymbols(it) {\n return getOwnPropertySymbolsModule.f(toObject(it));\n }\n});\n\n// `JSON.stringify` method behavior with symbols\n// https://tc39.es/ecma262/#sec-json.stringify\nif ($stringify) {\n var FORCED_JSON_STRINGIFY = !NATIVE_SYMBOL || fails(function () {\n var symbol = $Symbol();\n // MS Edge converts symbol values to JSON as {}\n return $stringify([symbol]) != '[null]'\n // WebKit converts symbol values to JSON as null\n || $stringify({ a: symbol }) != '{}'\n // V8 throws on boxed symbols\n || $stringify(Object(symbol)) != '{}';\n });\n\n $({ target: 'JSON', stat: true, forced: FORCED_JSON_STRINGIFY }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n stringify: function stringify(it, replacer, space) {\n var args = arraySlice(arguments);\n var $replacer = replacer;\n if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined\n if (!isArray(replacer)) replacer = function (key, value) {\n if (isCallable($replacer)) value = call($replacer, this, key, value);\n if (!isSymbol(value)) return value;\n };\n args[1] = replacer;\n return apply($stringify, null, args);\n }\n });\n}\n\n// `Symbol.prototype[@@toPrimitive]` method\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive\nif (!SymbolPrototype[TO_PRIMITIVE]) {\n var valueOf = SymbolPrototype.valueOf;\n // eslint-disable-next-line no-unused-vars -- required for .length\n redefine(SymbolPrototype, TO_PRIMITIVE, function (hint) {\n // TODO: improve hint logic\n return call(valueOf, this);\n });\n}\n// `Symbol.prototype[@@toStringTag]` property\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@tostringtag\nsetToStringTag($Symbol, SYMBOL);\n\nhiddenKeys[HIDDEN] = true;\n","var global = require('../internals/global');\nvar DOMIterables = require('../internals/dom-iterables');\nvar DOMTokenListPrototype = require('../internals/dom-token-list-prototype');\nvar forEach = require('../internals/array-for-each');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\nvar handlePrototype = function (CollectionPrototype) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype && CollectionPrototype.forEach !== forEach) try {\n createNonEnumerableProperty(CollectionPrototype, 'forEach', forEach);\n } catch (error) {\n CollectionPrototype.forEach = forEach;\n }\n};\n\nfor (var COLLECTION_NAME in DOMIterables) {\n if (DOMIterables[COLLECTION_NAME]) {\n handlePrototype(global[COLLECTION_NAME] && global[COLLECTION_NAME].prototype);\n }\n}\n\nhandlePrototype(DOMTokenListPrototype);\n","var global = require('../internals/global');\nvar DOMIterables = require('../internals/dom-iterables');\nvar DOMTokenListPrototype = require('../internals/dom-token-list-prototype');\nvar ArrayIteratorMethods = require('../modules/es.array.iterator');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar ArrayValues = ArrayIteratorMethods.values;\n\nvar handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {\n if (CollectionPrototype) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[ITERATOR] !== ArrayValues) try {\n createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);\n } catch (error) {\n CollectionPrototype[ITERATOR] = ArrayValues;\n }\n if (!CollectionPrototype[TO_STRING_TAG]) {\n createNonEnumerableProperty(CollectionPrototype, TO_STRING_TAG, COLLECTION_NAME);\n }\n if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {\n createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);\n } catch (error) {\n CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];\n }\n }\n }\n};\n\nfor (var COLLECTION_NAME in DOMIterables) {\n handlePrototype(global[COLLECTION_NAME] && global[COLLECTION_NAME].prototype, COLLECTION_NAME);\n}\n\nhandlePrototype(DOMTokenListPrototype, 'DOMTokenList');\n","'use strict';\nvar $ = require('../internals/export');\nvar tryNodeRequire = require('../internals/try-node-require');\nvar getBuiltIn = require('../internals/get-built-in');\nvar fails = require('../internals/fails');\nvar create = require('../internals/object-create');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar defineProperty = require('../internals/object-define-property').f;\nvar defineProperties = require('../internals/object-define-properties').f;\nvar redefine = require('../internals/redefine');\nvar hasOwn = require('../internals/has-own-property');\nvar anInstance = require('../internals/an-instance');\nvar anObject = require('../internals/an-object');\nvar errorToString = require('../internals/error-to-string');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\nvar DOMExceptionConstants = require('../internals/dom-exception-constants');\nvar clearErrorStack = require('../internals/clear-error-stack');\nvar InternalStateModule = require('../internals/internal-state');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IS_PURE = require('../internals/is-pure');\n\nvar DOM_EXCEPTION = 'DOMException';\nvar DATA_CLONE_ERR = 'DATA_CLONE_ERR';\nvar Error = getBuiltIn('Error');\n// NodeJS < 17.0 does not expose `DOMException` to global\nvar NativeDOMException = getBuiltIn(DOM_EXCEPTION) || (function () {\n try {\n // NodeJS < 15.0 does not expose `MessageChannel` to global\n var MessageChannel = getBuiltIn('MessageChannel') || tryNodeRequire('worker_threads').MessageChannel;\n // eslint-disable-next-line es/no-weak-map, unicorn/require-post-message-target-origin -- safe\n new MessageChannel().port1.postMessage(new WeakMap());\n } catch (error) {\n if (error.name == DATA_CLONE_ERR && error.code == 25) return error.constructor;\n }\n})();\nvar NativeDOMExceptionPrototype = NativeDOMException && NativeDOMException.prototype;\nvar ErrorPrototype = Error.prototype;\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(DOM_EXCEPTION);\nvar HAS_STACK = 'stack' in Error(DOM_EXCEPTION);\n\nvar codeFor = function (name) {\n return hasOwn(DOMExceptionConstants, name) && DOMExceptionConstants[name].m ? DOMExceptionConstants[name].c : 0;\n};\n\nvar $DOMException = function DOMException() {\n anInstance(this, DOMExceptionPrototype);\n var argumentsLength = arguments.length;\n var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]);\n var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error');\n var code = codeFor(name);\n setInternalState(this, {\n type: DOM_EXCEPTION,\n name: name,\n message: message,\n code: code\n });\n if (!DESCRIPTORS) {\n this.name = name;\n this.message = message;\n this.code = code;\n }\n if (HAS_STACK) {\n var error = Error(message);\n error.name = DOM_EXCEPTION;\n defineProperty(this, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1)));\n }\n};\n\nvar DOMExceptionPrototype = $DOMException.prototype = create(ErrorPrototype);\n\nvar createGetterDescriptor = function (get) {\n return { enumerable: true, configurable: true, get: get };\n};\n\nvar getterFor = function (key) {\n return createGetterDescriptor(function () {\n return getInternalState(this)[key];\n });\n};\n\nif (DESCRIPTORS) defineProperties(DOMExceptionPrototype, {\n name: getterFor('name'),\n message: getterFor('message'),\n code: getterFor('code')\n});\n\ndefineProperty(DOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, $DOMException));\n\n// FF36- DOMException is a function, but can't be constructed\nvar INCORRECT_CONSTRUCTOR = fails(function () {\n return !(new NativeDOMException() instanceof Error);\n});\n\n// Safari 10.1 / Chrome 32- / IE8- DOMException.prototype.toString bugs\nvar INCORRECT_TO_STRING = INCORRECT_CONSTRUCTOR || fails(function () {\n return ErrorPrototype.toString !== errorToString || String(new NativeDOMException(1, 2)) !== '2: 1';\n});\n\n// Deno 1.6.3- DOMException.prototype.code just missed\nvar INCORRECT_CODE = INCORRECT_CONSTRUCTOR || fails(function () {\n return new NativeDOMException(1, 'DataCloneError').code !== 25;\n});\n\n// Deno 1.6.3- DOMException constants just missed\nvar MISSED_CONSTANTS = INCORRECT_CONSTRUCTOR\n || NativeDOMException[DATA_CLONE_ERR] !== 25\n || NativeDOMExceptionPrototype[DATA_CLONE_ERR] !== 25;\n\nvar FORCED_CONSTRUCTOR = IS_PURE ? INCORRECT_TO_STRING || INCORRECT_CODE || MISSED_CONSTANTS : INCORRECT_CONSTRUCTOR;\n\n// `DOMException` constructor\n// https://webidl.spec.whatwg.org/#idl-DOMException\n$({ global: true, forced: FORCED_CONSTRUCTOR }, {\n DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException\n});\n\nvar PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION);\nvar PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype;\n\nif (INCORRECT_TO_STRING && (IS_PURE || NativeDOMException === PolyfilledDOMException)) {\n redefine(PolyfilledDOMExceptionPrototype, 'toString', errorToString);\n}\n\nif (INCORRECT_CODE && DESCRIPTORS && NativeDOMException === PolyfilledDOMException) {\n defineProperty(PolyfilledDOMExceptionPrototype, 'code', createGetterDescriptor(function () {\n return codeFor(anObject(this).name);\n }));\n}\n\nfor (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) {\n var constant = DOMExceptionConstants[key];\n var constantName = constant.s;\n var descriptor = createPropertyDescriptor(6, constant.c);\n if (!hasOwn(PolyfilledDOMException, constantName)) {\n defineProperty(PolyfilledDOMException, constantName, descriptor);\n }\n if (!hasOwn(PolyfilledDOMExceptionPrototype, constantName)) {\n defineProperty(PolyfilledDOMExceptionPrototype, constantName, descriptor);\n }\n}\n","'use strict';\nvar $ = require('../internals/export');\nvar getBuiltIn = require('../internals/get-built-in');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar defineProperty = require('../internals/object-define-property').f;\nvar hasOwn = require('../internals/has-own-property');\nvar anInstance = require('../internals/an-instance');\nvar inheritIfRequired = require('../internals/inherit-if-required');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\nvar DOMExceptionConstants = require('../internals/dom-exception-constants');\nvar clearErrorStack = require('../internals/clear-error-stack');\nvar IS_PURE = require('../internals/is-pure');\n\nvar DOM_EXCEPTION = 'DOMException';\nvar Error = getBuiltIn('Error');\nvar NativeDOMException = getBuiltIn(DOM_EXCEPTION);\n\nvar $DOMException = function DOMException() {\n anInstance(this, DOMExceptionPrototype);\n var argumentsLength = arguments.length;\n var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]);\n var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error');\n var that = new NativeDOMException(message, name);\n var error = Error(message);\n error.name = DOM_EXCEPTION;\n defineProperty(that, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1)));\n inheritIfRequired(that, this, $DOMException);\n return that;\n};\n\nvar DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototype;\n\nvar ERROR_HAS_STACK = 'stack' in Error(DOM_EXCEPTION);\nvar DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2);\nvar FORCED_CONSTRUCTOR = ERROR_HAS_STACK && !DOM_EXCEPTION_HAS_STACK;\n\n// `DOMException` constructor patch for `.stack` where it's required\n// https://webidl.spec.whatwg.org/#es-DOMException-specialness\n$({ global: true, forced: IS_PURE || FORCED_CONSTRUCTOR }, { // TODO: fix export logic\n DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException\n});\n\nvar PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION);\nvar PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype;\n\nif (PolyfilledDOMExceptionPrototype.constructor !== PolyfilledDOMException) {\n if (!IS_PURE) {\n defineProperty(PolyfilledDOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, PolyfilledDOMException));\n }\n\n for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) {\n var constant = DOMExceptionConstants[key];\n var constantName = constant.s;\n if (!hasOwn(PolyfilledDOMException, constantName)) {\n defineProperty(PolyfilledDOMException, constantName, createPropertyDescriptor(6, constant.c));\n }\n }\n}\n","var getBuiltIn = require('../internals/get-built-in');\nvar setToStringTag = require('../internals/set-to-string-tag');\n\nvar DOM_EXCEPTION = 'DOMException';\n\nsetToStringTag(getBuiltIn(DOM_EXCEPTION), DOM_EXCEPTION);\n","'use strict';\n\nmodule.exports = earcut;\nmodule.exports.default = earcut;\n\nfunction earcut(data, holeIndices, dim) {\n\n dim = dim || 2;\n\n var hasHoles = holeIndices && holeIndices.length,\n outerLen = hasHoles ? holeIndices[0] * dim : data.length,\n outerNode = linkedList(data, 0, outerLen, dim, true),\n triangles = [];\n\n if (!outerNode || outerNode.next === outerNode.prev) return triangles;\n\n var minX, minY, maxX, maxY, x, y, invSize;\n\n if (hasHoles) outerNode = eliminateHoles(data, holeIndices, outerNode, dim);\n\n // if the shape is not too simple, we'll use z-order curve hash later; calculate polygon bbox\n if (data.length > 80 * dim) {\n minX = maxX = data[0];\n minY = maxY = data[1];\n\n for (var i = dim; i < outerLen; i += dim) {\n x = data[i];\n y = data[i + 1];\n if (x < minX) minX = x;\n if (y < minY) minY = y;\n if (x > maxX) maxX = x;\n if (y > maxY) maxY = y;\n }\n\n // minX, minY and invSize are later used to transform coords into integers for z-order calculation\n invSize = Math.max(maxX - minX, maxY - minY);\n invSize = invSize !== 0 ? 1 / invSize : 0;\n }\n\n earcutLinked(outerNode, triangles, dim, minX, minY, invSize);\n\n return triangles;\n}\n\n// create a circular doubly linked list from polygon points in the specified winding order\nfunction linkedList(data, start, end, dim, clockwise) {\n var i, last;\n\n if (clockwise === (signedArea(data, start, end, dim) > 0)) {\n for (i = start; i < end; i += dim) last = insertNode(i, data[i], data[i + 1], last);\n } else {\n for (i = end - dim; i >= start; i -= dim) last = insertNode(i, data[i], data[i + 1], last);\n }\n\n if (last && equals(last, last.next)) {\n removeNode(last);\n last = last.next;\n }\n\n return last;\n}\n\n// eliminate colinear or duplicate points\nfunction filterPoints(start, end) {\n if (!start) return start;\n if (!end) end = start;\n\n var p = start,\n again;\n do {\n again = false;\n\n if (!p.steiner && (equals(p, p.next) || area(p.prev, p, p.next) === 0)) {\n removeNode(p);\n p = end = p.prev;\n if (p === p.next) break;\n again = true;\n\n } else {\n p = p.next;\n }\n } while (again || p !== end);\n\n return end;\n}\n\n// main ear slicing loop which triangulates a polygon (given as a linked list)\nfunction earcutLinked(ear, triangles, dim, minX, minY, invSize, pass) {\n if (!ear) return;\n\n // interlink polygon nodes in z-order\n if (!pass && invSize) indexCurve(ear, minX, minY, invSize);\n\n var stop = ear,\n prev, next;\n\n // iterate through ears, slicing them one by one\n while (ear.prev !== ear.next) {\n prev = ear.prev;\n next = ear.next;\n\n if (invSize ? isEarHashed(ear, minX, minY, invSize) : isEar(ear)) {\n // cut off the triangle\n triangles.push(prev.i / dim);\n triangles.push(ear.i / dim);\n triangles.push(next.i / dim);\n\n removeNode(ear);\n\n // skipping the next vertex leads to less sliver triangles\n ear = next.next;\n stop = next.next;\n\n continue;\n }\n\n ear = next;\n\n // if we looped through the whole remaining polygon and can't find any more ears\n if (ear === stop) {\n // try filtering points and slicing again\n if (!pass) {\n earcutLinked(filterPoints(ear), triangles, dim, minX, minY, invSize, 1);\n\n // if this didn't work, try curing all small self-intersections locally\n } else if (pass === 1) {\n ear = cureLocalIntersections(filterPoints(ear), triangles, dim);\n earcutLinked(ear, triangles, dim, minX, minY, invSize, 2);\n\n // as a last resort, try splitting the remaining polygon into two\n } else if (pass === 2) {\n splitEarcut(ear, triangles, dim, minX, minY, invSize);\n }\n\n break;\n }\n }\n}\n\n// check whether a polygon node forms a valid ear with adjacent nodes\nfunction isEar(ear) {\n var a = ear.prev,\n b = ear,\n c = ear.next;\n\n if (area(a, b, c) >= 0) return false; // reflex, can't be an ear\n\n // now make sure we don't have other points inside the potential ear\n var p = ear.next.next;\n\n while (p !== ear.prev) {\n if (pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) &&\n area(p.prev, p, p.next) >= 0) return false;\n p = p.next;\n }\n\n return true;\n}\n\nfunction isEarHashed(ear, minX, minY, invSize) {\n var a = ear.prev,\n b = ear,\n c = ear.next;\n\n if (area(a, b, c) >= 0) return false; // reflex, can't be an ear\n\n // triangle bbox; min & max are calculated like this for speed\n var minTX = a.x < b.x ? (a.x < c.x ? a.x : c.x) : (b.x < c.x ? b.x : c.x),\n minTY = a.y < b.y ? (a.y < c.y ? a.y : c.y) : (b.y < c.y ? b.y : c.y),\n maxTX = a.x > b.x ? (a.x > c.x ? a.x : c.x) : (b.x > c.x ? b.x : c.x),\n maxTY = a.y > b.y ? (a.y > c.y ? a.y : c.y) : (b.y > c.y ? b.y : c.y);\n\n // z-order range for the current triangle bbox;\n var minZ = zOrder(minTX, minTY, minX, minY, invSize),\n maxZ = zOrder(maxTX, maxTY, minX, minY, invSize);\n\n var p = ear.prevZ,\n n = ear.nextZ;\n\n // look for points inside the triangle in both directions\n while (p && p.z >= minZ && n && n.z <= maxZ) {\n if (p !== ear.prev && p !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) &&\n area(p.prev, p, p.next) >= 0) return false;\n p = p.prevZ;\n\n if (n !== ear.prev && n !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, n.x, n.y) &&\n area(n.prev, n, n.next) >= 0) return false;\n n = n.nextZ;\n }\n\n // look for remaining points in decreasing z-order\n while (p && p.z >= minZ) {\n if (p !== ear.prev && p !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) &&\n area(p.prev, p, p.next) >= 0) return false;\n p = p.prevZ;\n }\n\n // look for remaining points in increasing z-order\n while (n && n.z <= maxZ) {\n if (n !== ear.prev && n !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, n.x, n.y) &&\n area(n.prev, n, n.next) >= 0) return false;\n n = n.nextZ;\n }\n\n return true;\n}\n\n// go through all polygon nodes and cure small local self-intersections\nfunction cureLocalIntersections(start, triangles, dim) {\n var p = start;\n do {\n var a = p.prev,\n b = p.next.next;\n\n if (!equals(a, b) && intersects(a, p, p.next, b) && locallyInside(a, b) && locallyInside(b, a)) {\n\n triangles.push(a.i / dim);\n triangles.push(p.i / dim);\n triangles.push(b.i / dim);\n\n // remove two nodes involved\n removeNode(p);\n removeNode(p.next);\n\n p = start = b;\n }\n p = p.next;\n } while (p !== start);\n\n return filterPoints(p);\n}\n\n// try splitting polygon into two and triangulate them independently\nfunction splitEarcut(start, triangles, dim, minX, minY, invSize) {\n // look for a valid diagonal that divides the polygon into two\n var a = start;\n do {\n var b = a.next.next;\n while (b !== a.prev) {\n if (a.i !== b.i && isValidDiagonal(a, b)) {\n // split the polygon in two by the diagonal\n var c = splitPolygon(a, b);\n\n // filter colinear points around the cuts\n a = filterPoints(a, a.next);\n c = filterPoints(c, c.next);\n\n // run earcut on each half\n earcutLinked(a, triangles, dim, minX, minY, invSize);\n earcutLinked(c, triangles, dim, minX, minY, invSize);\n return;\n }\n b = b.next;\n }\n a = a.next;\n } while (a !== start);\n}\n\n// link every hole into the outer loop, producing a single-ring polygon without holes\nfunction eliminateHoles(data, holeIndices, outerNode, dim) {\n var queue = [],\n i, len, start, end, list;\n\n for (i = 0, len = holeIndices.length; i < len; i++) {\n start = holeIndices[i] * dim;\n end = i < len - 1 ? holeIndices[i + 1] * dim : data.length;\n list = linkedList(data, start, end, dim, false);\n if (list === list.next) list.steiner = true;\n queue.push(getLeftmost(list));\n }\n\n queue.sort(compareX);\n\n // process holes from left to right\n for (i = 0; i < queue.length; i++) {\n outerNode = eliminateHole(queue[i], outerNode);\n outerNode = filterPoints(outerNode, outerNode.next);\n }\n\n return outerNode;\n}\n\nfunction compareX(a, b) {\n return a.x - b.x;\n}\n\n// find a bridge between vertices that connects hole with an outer ring and and link it\nfunction eliminateHole(hole, outerNode) {\n var bridge = findHoleBridge(hole, outerNode);\n if (!bridge) {\n return outerNode;\n }\n\n var bridgeReverse = splitPolygon(bridge, hole);\n\n // filter collinear points around the cuts\n var filteredBridge = filterPoints(bridge, bridge.next);\n filterPoints(bridgeReverse, bridgeReverse.next);\n\n // Check if input node was removed by the filtering\n return outerNode === bridge ? filteredBridge : outerNode;\n}\n\n// David Eberly's algorithm for finding a bridge between hole and outer polygon\nfunction findHoleBridge(hole, outerNode) {\n var p = outerNode,\n hx = hole.x,\n hy = hole.y,\n qx = -Infinity,\n m;\n\n // find a segment intersected by a ray from the hole's leftmost point to the left;\n // segment's endpoint with lesser x will be potential connection point\n do {\n if (hy <= p.y && hy >= p.next.y && p.next.y !== p.y) {\n var x = p.x + (hy - p.y) * (p.next.x - p.x) / (p.next.y - p.y);\n if (x <= hx && x > qx) {\n qx = x;\n if (x === hx) {\n if (hy === p.y) return p;\n if (hy === p.next.y) return p.next;\n }\n m = p.x < p.next.x ? p : p.next;\n }\n }\n p = p.next;\n } while (p !== outerNode);\n\n if (!m) return null;\n\n if (hx === qx) return m; // hole touches outer segment; pick leftmost endpoint\n\n // look for points inside the triangle of hole point, segment intersection and endpoint;\n // if there are no points found, we have a valid connection;\n // otherwise choose the point of the minimum angle with the ray as connection point\n\n var stop = m,\n mx = m.x,\n my = m.y,\n tanMin = Infinity,\n tan;\n\n p = m;\n\n do {\n if (hx >= p.x && p.x >= mx && hx !== p.x &&\n pointInTriangle(hy < my ? hx : qx, hy, mx, my, hy < my ? qx : hx, hy, p.x, p.y)) {\n\n tan = Math.abs(hy - p.y) / (hx - p.x); // tangential\n\n if (locallyInside(p, hole) &&\n (tan < tanMin || (tan === tanMin && (p.x > m.x || (p.x === m.x && sectorContainsSector(m, p)))))) {\n m = p;\n tanMin = tan;\n }\n }\n\n p = p.next;\n } while (p !== stop);\n\n return m;\n}\n\n// whether sector in vertex m contains sector in vertex p in the same coordinates\nfunction sectorContainsSector(m, p) {\n return area(m.prev, m, p.prev) < 0 && area(p.next, m, m.next) < 0;\n}\n\n// interlink polygon nodes in z-order\nfunction indexCurve(start, minX, minY, invSize) {\n var p = start;\n do {\n if (p.z === null) p.z = zOrder(p.x, p.y, minX, minY, invSize);\n p.prevZ = p.prev;\n p.nextZ = p.next;\n p = p.next;\n } while (p !== start);\n\n p.prevZ.nextZ = null;\n p.prevZ = null;\n\n sortLinked(p);\n}\n\n// Simon Tatham's linked list merge sort algorithm\n// http://www.chiark.greenend.org.uk/~sgtatham/algorithms/listsort.html\nfunction sortLinked(list) {\n var i, p, q, e, tail, numMerges, pSize, qSize,\n inSize = 1;\n\n do {\n p = list;\n list = null;\n tail = null;\n numMerges = 0;\n\n while (p) {\n numMerges++;\n q = p;\n pSize = 0;\n for (i = 0; i < inSize; i++) {\n pSize++;\n q = q.nextZ;\n if (!q) break;\n }\n qSize = inSize;\n\n while (pSize > 0 || (qSize > 0 && q)) {\n\n if (pSize !== 0 && (qSize === 0 || !q || p.z <= q.z)) {\n e = p;\n p = p.nextZ;\n pSize--;\n } else {\n e = q;\n q = q.nextZ;\n qSize--;\n }\n\n if (tail) tail.nextZ = e;\n else list = e;\n\n e.prevZ = tail;\n tail = e;\n }\n\n p = q;\n }\n\n tail.nextZ = null;\n inSize *= 2;\n\n } while (numMerges > 1);\n\n return list;\n}\n\n// z-order of a point given coords and inverse of the longer side of data bbox\nfunction zOrder(x, y, minX, minY, invSize) {\n // coords are transformed into non-negative 15-bit integer range\n x = 32767 * (x - minX) * invSize;\n y = 32767 * (y - minY) * invSize;\n\n x = (x | (x << 8)) & 0x00FF00FF;\n x = (x | (x << 4)) & 0x0F0F0F0F;\n x = (x | (x << 2)) & 0x33333333;\n x = (x | (x << 1)) & 0x55555555;\n\n y = (y | (y << 8)) & 0x00FF00FF;\n y = (y | (y << 4)) & 0x0F0F0F0F;\n y = (y | (y << 2)) & 0x33333333;\n y = (y | (y << 1)) & 0x55555555;\n\n return x | (y << 1);\n}\n\n// find the leftmost node of a polygon ring\nfunction getLeftmost(start) {\n var p = start,\n leftmost = start;\n do {\n if (p.x < leftmost.x || (p.x === leftmost.x && p.y < leftmost.y)) leftmost = p;\n p = p.next;\n } while (p !== start);\n\n return leftmost;\n}\n\n// check if a point lies within a convex triangle\nfunction pointInTriangle(ax, ay, bx, by, cx, cy, px, py) {\n return (cx - px) * (ay - py) - (ax - px) * (cy - py) >= 0 &&\n (ax - px) * (by - py) - (bx - px) * (ay - py) >= 0 &&\n (bx - px) * (cy - py) - (cx - px) * (by - py) >= 0;\n}\n\n// check if a diagonal between two polygon nodes is valid (lies in polygon interior)\nfunction isValidDiagonal(a, b) {\n return a.next.i !== b.i && a.prev.i !== b.i && !intersectsPolygon(a, b) && // dones't intersect other edges\n (locallyInside(a, b) && locallyInside(b, a) && middleInside(a, b) && // locally visible\n (area(a.prev, a, b.prev) || area(a, b.prev, b)) || // does not create opposite-facing sectors\n equals(a, b) && area(a.prev, a, a.next) > 0 && area(b.prev, b, b.next) > 0); // special zero-length case\n}\n\n// signed area of a triangle\nfunction area(p, q, r) {\n return (q.y - p.y) * (r.x - q.x) - (q.x - p.x) * (r.y - q.y);\n}\n\n// check if two points are equal\nfunction equals(p1, p2) {\n return p1.x === p2.x && p1.y === p2.y;\n}\n\n// check if two segments intersect\nfunction intersects(p1, q1, p2, q2) {\n var o1 = sign(area(p1, q1, p2));\n var o2 = sign(area(p1, q1, q2));\n var o3 = sign(area(p2, q2, p1));\n var o4 = sign(area(p2, q2, q1));\n\n if (o1 !== o2 && o3 !== o4) return true; // general case\n\n if (o1 === 0 && onSegment(p1, p2, q1)) return true; // p1, q1 and p2 are collinear and p2 lies on p1q1\n if (o2 === 0 && onSegment(p1, q2, q1)) return true; // p1, q1 and q2 are collinear and q2 lies on p1q1\n if (o3 === 0 && onSegment(p2, p1, q2)) return true; // p2, q2 and p1 are collinear and p1 lies on p2q2\n if (o4 === 0 && onSegment(p2, q1, q2)) return true; // p2, q2 and q1 are collinear and q1 lies on p2q2\n\n return false;\n}\n\n// for collinear points p, q, r, check if point q lies on segment pr\nfunction onSegment(p, q, r) {\n return q.x <= Math.max(p.x, r.x) && q.x >= Math.min(p.x, r.x) && q.y <= Math.max(p.y, r.y) && q.y >= Math.min(p.y, r.y);\n}\n\nfunction sign(num) {\n return num > 0 ? 1 : num < 0 ? -1 : 0;\n}\n\n// check if a polygon diagonal intersects any polygon segments\nfunction intersectsPolygon(a, b) {\n var p = a;\n do {\n if (p.i !== a.i && p.next.i !== a.i && p.i !== b.i && p.next.i !== b.i &&\n intersects(p, p.next, a, b)) return true;\n p = p.next;\n } while (p !== a);\n\n return false;\n}\n\n// check if a polygon diagonal is locally inside the polygon\nfunction locallyInside(a, b) {\n return area(a.prev, a, a.next) < 0 ?\n area(a, b, a.next) >= 0 && area(a, a.prev, b) >= 0 :\n area(a, b, a.prev) < 0 || area(a, a.next, b) < 0;\n}\n\n// check if the middle point of a polygon diagonal is inside the polygon\nfunction middleInside(a, b) {\n var p = a,\n inside = false,\n px = (a.x + b.x) / 2,\n py = (a.y + b.y) / 2;\n do {\n if (((p.y > py) !== (p.next.y > py)) && p.next.y !== p.y &&\n (px < (p.next.x - p.x) * (py - p.y) / (p.next.y - p.y) + p.x))\n inside = !inside;\n p = p.next;\n } while (p !== a);\n\n return inside;\n}\n\n// link two polygon vertices with a bridge; if the vertices belong to the same ring, it splits polygon into two;\n// if one belongs to the outer ring and another to a hole, it merges it into a single ring\nfunction splitPolygon(a, b) {\n var a2 = new Node(a.i, a.x, a.y),\n b2 = new Node(b.i, b.x, b.y),\n an = a.next,\n bp = b.prev;\n\n a.next = b;\n b.prev = a;\n\n a2.next = an;\n an.prev = a2;\n\n b2.next = a2;\n a2.prev = b2;\n\n bp.next = b2;\n b2.prev = bp;\n\n return b2;\n}\n\n// create a node and optionally link it with previous one (in a circular doubly linked list)\nfunction insertNode(i, x, y, last) {\n var p = new Node(i, x, y);\n\n if (!last) {\n p.prev = p;\n p.next = p;\n\n } else {\n p.next = last.next;\n p.prev = last;\n last.next.prev = p;\n last.next = p;\n }\n return p;\n}\n\nfunction removeNode(p) {\n p.next.prev = p.prev;\n p.prev.next = p.next;\n\n if (p.prevZ) p.prevZ.nextZ = p.nextZ;\n if (p.nextZ) p.nextZ.prevZ = p.prevZ;\n}\n\nfunction Node(i, x, y) {\n // vertex index in coordinates array\n this.i = i;\n\n // vertex coordinates\n this.x = x;\n this.y = y;\n\n // previous and next vertex nodes in a polygon ring\n this.prev = null;\n this.next = null;\n\n // z-order curve value\n this.z = null;\n\n // previous and next nodes in z-order\n this.prevZ = null;\n this.nextZ = null;\n\n // indicates whether this is a steiner point\n this.steiner = false;\n}\n\n// return a percentage difference between the polygon area and its triangulation area;\n// used to verify correctness of triangulation\nearcut.deviation = function (data, holeIndices, dim, triangles) {\n var hasHoles = holeIndices && holeIndices.length;\n var outerLen = hasHoles ? holeIndices[0] * dim : data.length;\n\n var polygonArea = Math.abs(signedArea(data, 0, outerLen, dim));\n if (hasHoles) {\n for (var i = 0, len = holeIndices.length; i < len; i++) {\n var start = holeIndices[i] * dim;\n var end = i < len - 1 ? holeIndices[i + 1] * dim : data.length;\n polygonArea -= Math.abs(signedArea(data, start, end, dim));\n }\n }\n\n var trianglesArea = 0;\n for (i = 0; i < triangles.length; i += 3) {\n var a = triangles[i] * dim;\n var b = triangles[i + 1] * dim;\n var c = triangles[i + 2] * dim;\n trianglesArea += Math.abs(\n (data[a] - data[c]) * (data[b + 1] - data[a + 1]) -\n (data[a] - data[b]) * (data[c + 1] - data[a + 1]));\n }\n\n return polygonArea === 0 && trianglesArea === 0 ? 0 :\n Math.abs((trianglesArea - polygonArea) / polygonArea);\n};\n\nfunction signedArea(data, start, end, dim) {\n var sum = 0;\n for (var i = start, j = end - dim; i < end; i += dim) {\n sum += (data[j] - data[i]) * (data[i + 1] + data[j + 1]);\n j = i;\n }\n return sum;\n}\n\n// turn a polygon in a multi-dimensional array form (e.g. as in GeoJSON) into a form Earcut accepts\nearcut.flatten = function (data) {\n var dim = data[0][0].length,\n result = {vertices: [], holes: [], dimensions: dim},\n holeIndex = 0;\n\n for (var i = 0; i < data.length; i++) {\n for (var j = 0; j < data[i].length; j++) {\n for (var d = 0; d < dim; d++) result.vertices.push(data[i][j][d]);\n }\n if (i > 0) {\n holeIndex += data[i - 1].length;\n result.holes.push(holeIndex);\n }\n }\n return result;\n};\n","// Copyright (c) 2013 Pieroxy <pieroxy@pieroxy.net>\n// This work is free. You can redistribute it and/or modify it\n// under the terms of the WTFPL, Version 2\n// For more information see LICENSE.txt or http://www.wtfpl.net/\n//\n// For more information, the home page:\n// http://pieroxy.net/blog/pages/lz-string/testing.html\n//\n// LZ-based compression algorithm, version 1.4.4\nvar LZString = (function() {\n\n// private property\nvar f = String.fromCharCode;\nvar keyStrBase64 = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\";\nvar keyStrUriSafe = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$\";\nvar baseReverseDic = {};\n\nfunction getBaseValue(alphabet, character) {\n if (!baseReverseDic[alphabet]) {\n baseReverseDic[alphabet] = {};\n for (var i=0 ; i<alphabet.length ; i++) {\n baseReverseDic[alphabet][alphabet.charAt(i)] = i;\n }\n }\n return baseReverseDic[alphabet][character];\n}\n\nvar LZString = {\n compressToBase64 : function (input) {\n if (input == null) return \"\";\n var res = LZString._compress(input, 6, function(a){return keyStrBase64.charAt(a);});\n switch (res.length % 4) { // To produce valid Base64\n default: // When could this happen ?\n case 0 : return res;\n case 1 : return res+\"===\";\n case 2 : return res+\"==\";\n case 3 : return res+\"=\";\n }\n },\n\n decompressFromBase64 : function (input) {\n if (input == null) return \"\";\n if (input == \"\") return null;\n return LZString._decompress(input.length, 32, function(index) { return getBaseValue(keyStrBase64, input.charAt(index)); });\n },\n\n compressToUTF16 : function (input) {\n if (input == null) return \"\";\n return LZString._compress(input, 15, function(a){return f(a+32);}) + \" \";\n },\n\n decompressFromUTF16: function (compressed) {\n if (compressed == null) return \"\";\n if (compressed == \"\") return null;\n return LZString._decompress(compressed.length, 16384, function(index) { return compressed.charCodeAt(index) - 32; });\n },\n\n //compress into uint8array (UCS-2 big endian format)\n compressToUint8Array: function (uncompressed) {\n var compressed = LZString.compress(uncompressed);\n var buf=new Uint8Array(compressed.length*2); // 2 bytes per character\n\n for (var i=0, TotalLen=compressed.length; i<TotalLen; i++) {\n var current_value = compressed.charCodeAt(i);\n buf[i*2] = current_value >>> 8;\n buf[i*2+1] = current_value % 256;\n }\n return buf;\n },\n\n //decompress from uint8array (UCS-2 big endian format)\n decompressFromUint8Array:function (compressed) {\n if (compressed===null || compressed===undefined){\n return LZString.decompress(compressed);\n } else {\n var buf=new Array(compressed.length/2); // 2 bytes per character\n for (var i=0, TotalLen=buf.length; i<TotalLen; i++) {\n buf[i]=compressed[i*2]*256+compressed[i*2+1];\n }\n\n var result = [];\n buf.forEach(function (c) {\n result.push(f(c));\n });\n return LZString.decompress(result.join(''));\n\n }\n\n },\n\n\n //compress into a string that is already URI encoded\n compressToEncodedURIComponent: function (input) {\n if (input == null) return \"\";\n return LZString._compress(input, 6, function(a){return keyStrUriSafe.charAt(a);});\n },\n\n //decompress from an output of compressToEncodedURIComponent\n decompressFromEncodedURIComponent:function (input) {\n if (input == null) return \"\";\n if (input == \"\") return null;\n input = input.replace(/ /g, \"+\");\n return LZString._decompress(input.length, 32, function(index) { return getBaseValue(keyStrUriSafe, input.charAt(index)); });\n },\n\n compress: function (uncompressed) {\n return LZString._compress(uncompressed, 16, function(a){return f(a);});\n },\n _compress: function (uncompressed, bitsPerChar, getCharFromInt) {\n if (uncompressed == null) return \"\";\n var i, value,\n context_dictionary= {},\n context_dictionaryToCreate= {},\n context_c=\"\",\n context_wc=\"\",\n context_w=\"\",\n context_enlargeIn= 2, // Compensate for the first entry which should not count\n context_dictSize= 3,\n context_numBits= 2,\n context_data=[],\n context_data_val=0,\n context_data_position=0,\n ii;\n\n for (ii = 0; ii < uncompressed.length; ii += 1) {\n context_c = uncompressed.charAt(ii);\n if (!Object.prototype.hasOwnProperty.call(context_dictionary,context_c)) {\n context_dictionary[context_c] = context_dictSize++;\n context_dictionaryToCreate[context_c] = true;\n }\n\n context_wc = context_w + context_c;\n if (Object.prototype.hasOwnProperty.call(context_dictionary,context_wc)) {\n context_w = context_wc;\n } else {\n if (Object.prototype.hasOwnProperty.call(context_dictionaryToCreate,context_w)) {\n if (context_w.charCodeAt(0)<256) {\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<8 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n } else {\n value = 1;\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | value;\n if (context_data_position ==bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = 0;\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<16 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n delete context_dictionaryToCreate[context_w];\n } else {\n value = context_dictionary[context_w];\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n\n\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n // Add wc to the dictionary.\n context_dictionary[context_wc] = context_dictSize++;\n context_w = String(context_c);\n }\n }\n\n // Output the code for w.\n if (context_w !== \"\") {\n if (Object.prototype.hasOwnProperty.call(context_dictionaryToCreate,context_w)) {\n if (context_w.charCodeAt(0)<256) {\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<8 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n } else {\n value = 1;\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | value;\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = 0;\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<16 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n delete context_dictionaryToCreate[context_w];\n } else {\n value = context_dictionary[context_w];\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n\n\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n }\n\n // Mark the end of the stream\n value = 2;\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n\n // Flush the last char\n while (true) {\n context_data_val = (context_data_val << 1);\n if (context_data_position == bitsPerChar-1) {\n context_data.push(getCharFromInt(context_data_val));\n break;\n }\n else context_data_position++;\n }\n return context_data.join('');\n },\n\n decompress: function (compressed) {\n if (compressed == null) return \"\";\n if (compressed == \"\") return null;\n return LZString._decompress(compressed.length, 32768, function(index) { return compressed.charCodeAt(index); });\n },\n\n _decompress: function (length, resetValue, getNextValue) {\n var dictionary = [],\n next,\n enlargeIn = 4,\n dictSize = 4,\n numBits = 3,\n entry = \"\",\n result = [],\n i,\n w,\n bits, resb, maxpower, power,\n c,\n data = {val:getNextValue(0), position:resetValue, index:1};\n\n for (i = 0; i < 3; i += 1) {\n dictionary[i] = i;\n }\n\n bits = 0;\n maxpower = Math.pow(2,2);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n\n switch (next = bits) {\n case 0:\n bits = 0;\n maxpower = Math.pow(2,8);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n c = f(bits);\n break;\n case 1:\n bits = 0;\n maxpower = Math.pow(2,16);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n c = f(bits);\n break;\n case 2:\n return \"\";\n }\n dictionary[3] = c;\n w = c;\n result.push(c);\n while (true) {\n if (data.index > length) {\n return \"\";\n }\n\n bits = 0;\n maxpower = Math.pow(2,numBits);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n\n switch (c = bits) {\n case 0:\n bits = 0;\n maxpower = Math.pow(2,8);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n\n dictionary[dictSize++] = f(bits);\n c = dictSize-1;\n enlargeIn--;\n break;\n case 1:\n bits = 0;\n maxpower = Math.pow(2,16);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n dictionary[dictSize++] = f(bits);\n c = dictSize-1;\n enlargeIn--;\n break;\n case 2:\n return result.join('');\n }\n\n if (enlargeIn == 0) {\n enlargeIn = Math.pow(2, numBits);\n numBits++;\n }\n\n if (dictionary[c]) {\n entry = dictionary[c];\n } else {\n if (c === dictSize) {\n entry = w + w.charAt(0);\n } else {\n return null;\n }\n }\n result.push(entry);\n\n // Add w+entry[0] to the dictionary.\n dictionary[dictSize++] = w + entry.charAt(0);\n enlargeIn--;\n\n w = entry;\n\n if (enlargeIn == 0) {\n enlargeIn = Math.pow(2, numBits);\n numBits++;\n }\n\n }\n }\n};\n return LZString;\n})();\n\nif (typeof define === 'function' && define.amd) {\n define(function () { return LZString; });\n} else if( typeof module !== 'undefined' && module != null ) {\n module.exports = LZString\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * @this {Promise}\n */\nfunction finallyConstructor(callback) {\n var constructor = this.constructor;\n return this.then(\n function(value) {\n // @ts-ignore\n return constructor.resolve(callback()).then(function() {\n return value;\n });\n },\n function(reason) {\n // @ts-ignore\n return constructor.resolve(callback()).then(function() {\n // @ts-ignore\n return constructor.reject(reason);\n });\n }\n );\n}\n\nexport default finallyConstructor;\n","function allSettled(arr) {\n var P = this;\n return new P(function(resolve, reject) {\n if (!(arr && typeof arr.length !== 'undefined')) {\n return reject(\n new TypeError(\n typeof arr +\n ' ' +\n arr +\n ' is not iterable(cannot read property Symbol(Symbol.iterator))'\n )\n );\n }\n var args = Array.prototype.slice.call(arr);\n if (args.length === 0) return resolve([]);\n var remaining = args.length;\n\n function res(i, val) {\n if (val && (typeof val === 'object' || typeof val === 'function')) {\n var then = val.then;\n if (typeof then === 'function') {\n then.call(\n val,\n function(val) {\n res(i, val);\n },\n function(e) {\n args[i] = { status: 'rejected', reason: e };\n if (--remaining === 0) {\n resolve(args);\n }\n }\n );\n return;\n }\n }\n args[i] = { status: 'fulfilled', value: val };\n if (--remaining === 0) {\n resolve(args);\n }\n }\n\n for (var i = 0; i < args.length; i++) {\n res(i, args[i]);\n }\n });\n}\n\nexport default allSettled;\n","import promiseFinally from './finally';\nimport allSettled from './allSettled';\n\n// Store setTimeout reference so promise-polyfill will be unaffected by\n// other code modifying setTimeout (like sinon.useFakeTimers())\nvar setTimeoutFunc = setTimeout;\n\nfunction isArray(x) {\n return Boolean(x && typeof x.length !== 'undefined');\n}\n\nfunction noop() {}\n\n// Polyfill for Function.prototype.bind\nfunction bind(fn, thisArg) {\n return function() {\n fn.apply(thisArg, arguments);\n };\n}\n\n/**\n * @constructor\n * @param {Function} fn\n */\nfunction Promise(fn) {\n if (!(this instanceof Promise))\n throw new TypeError('Promises must be constructed via new');\n if (typeof fn !== 'function') throw new TypeError('not a function');\n /** @type {!number} */\n this._state = 0;\n /** @type {!boolean} */\n this._handled = false;\n /** @type {Promise|undefined} */\n this._value = undefined;\n /** @type {!Array<!Function>} */\n this._deferreds = [];\n\n doResolve(fn, this);\n}\n\nfunction handle(self, deferred) {\n while (self._state === 3) {\n self = self._value;\n }\n if (self._state === 0) {\n self._deferreds.push(deferred);\n return;\n }\n self._handled = true;\n Promise._immediateFn(function() {\n var cb = self._state === 1 ? deferred.onFulfilled : deferred.onRejected;\n if (cb === null) {\n (self._state === 1 ? resolve : reject)(deferred.promise, self._value);\n return;\n }\n var ret;\n try {\n ret = cb(self._value);\n } catch (e) {\n reject(deferred.promise, e);\n return;\n }\n resolve(deferred.promise, ret);\n });\n}\n\nfunction resolve(self, newValue) {\n try {\n // Promise Resolution Procedure: https://github.com/promises-aplus/promises-spec#the-promise-resolution-procedure\n if (newValue === self)\n throw new TypeError('A promise cannot be resolved with itself.');\n if (\n newValue &&\n (typeof newValue === 'object' || typeof newValue === 'function')\n ) {\n var then = newValue.then;\n if (newValue instanceof Promise) {\n self._state = 3;\n self._value = newValue;\n finale(self);\n return;\n } else if (typeof then === 'function') {\n doResolve(bind(then, newValue), self);\n return;\n }\n }\n self._state = 1;\n self._value = newValue;\n finale(self);\n } catch (e) {\n reject(self, e);\n }\n}\n\nfunction reject(self, newValue) {\n self._state = 2;\n self._value = newValue;\n finale(self);\n}\n\nfunction finale(self) {\n if (self._state === 2 && self._deferreds.length === 0) {\n Promise._immediateFn(function() {\n if (!self._handled) {\n Promise._unhandledRejectionFn(self._value);\n }\n });\n }\n\n for (var i = 0, len = self._deferreds.length; i < len; i++) {\n handle(self, self._deferreds[i]);\n }\n self._deferreds = null;\n}\n\n/**\n * @constructor\n */\nfunction Handler(onFulfilled, onRejected, promise) {\n this.onFulfilled = typeof onFulfilled === 'function' ? onFulfilled : null;\n this.onRejected = typeof onRejected === 'function' ? onRejected : null;\n this.promise = promise;\n}\n\n/**\n * Take a potentially misbehaving resolver function and make sure\n * onFulfilled and onRejected are only called once.\n *\n * Makes no guarantees about asynchrony.\n */\nfunction doResolve(fn, self) {\n var done = false;\n try {\n fn(\n function(value) {\n if (done) return;\n done = true;\n resolve(self, value);\n },\n function(reason) {\n if (done) return;\n done = true;\n reject(self, reason);\n }\n );\n } catch (ex) {\n if (done) return;\n done = true;\n reject(self, ex);\n }\n}\n\nPromise.prototype['catch'] = function(onRejected) {\n return this.then(null, onRejected);\n};\n\nPromise.prototype.then = function(onFulfilled, onRejected) {\n // @ts-ignore\n var prom = new this.constructor(noop);\n\n handle(this, new Handler(onFulfilled, onRejected, prom));\n return prom;\n};\n\nPromise.prototype['finally'] = promiseFinally;\n\nPromise.all = function(arr) {\n return new Promise(function(resolve, reject) {\n if (!isArray(arr)) {\n return reject(new TypeError('Promise.all accepts an array'));\n }\n\n var args = Array.prototype.slice.call(arr);\n if (args.length === 0) return resolve([]);\n var remaining = args.length;\n\n function res(i, val) {\n try {\n if (val && (typeof val === 'object' || typeof val === 'function')) {\n var then = val.then;\n if (typeof then === 'function') {\n then.call(\n val,\n function(val) {\n res(i, val);\n },\n reject\n );\n return;\n }\n }\n args[i] = val;\n if (--remaining === 0) {\n resolve(args);\n }\n } catch (ex) {\n reject(ex);\n }\n }\n\n for (var i = 0; i < args.length; i++) {\n res(i, args[i]);\n }\n });\n};\n\nPromise.allSettled = allSettled;\n\nPromise.resolve = function(value) {\n if (value && typeof value === 'object' && value.constructor === Promise) {\n return value;\n }\n\n return new Promise(function(resolve) {\n resolve(value);\n });\n};\n\nPromise.reject = function(value) {\n return new Promise(function(resolve, reject) {\n reject(value);\n });\n};\n\nPromise.race = function(arr) {\n return new Promise(function(resolve, reject) {\n if (!isArray(arr)) {\n return reject(new TypeError('Promise.race accepts an array'));\n }\n\n for (var i = 0, len = arr.length; i < len; i++) {\n Promise.resolve(arr[i]).then(resolve, reject);\n }\n });\n};\n\n// Use polyfill for setImmediate for performance gains\nPromise._immediateFn =\n // @ts-ignore\n (typeof setImmediate === 'function' &&\n function(fn) {\n // @ts-ignore\n setImmediate(fn);\n }) ||\n function(fn) {\n setTimeoutFunc(fn, 0);\n };\n\nPromise._unhandledRejectionFn = function _unhandledRejectionFn(err) {\n if (typeof console !== 'undefined' && console) {\n console.warn('Possible Unhandled Promise Rejection:', err); // eslint-disable-line no-console\n }\n};\n\nexport default Promise;\n","/*!\n * @pixi/polyfill - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/polyfill is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport Polyfill from 'promise-polyfill';\nimport objectAssign from 'object-assign';\n\nif (typeof globalThis === 'undefined') {\n if (typeof self !== 'undefined') {\n // covers browsers\n // @ts-expect-error not-writable ts(2540) error only on node\n self.globalThis = self;\n }\n else if (typeof global !== 'undefined') {\n // covers versions of Node < 12\n // @ts-expect-error not-writable ts(2540) error only on node\n global.globalThis = global;\n }\n}\n\n// Support for IE 9 - 11 which does not include Promises\nif (!globalThis.Promise) {\n globalThis.Promise = Polyfill;\n}\n\n// References:\nif (!Object.assign) {\n Object.assign = objectAssign;\n}\n\n// References:\n// http://paulirish.com/2011/requestanimationframe-for-smart-animating/\n// https://gist.github.com/1579671\n// http://updates.html5rocks.com/2012/05/requestAnimationFrame-API-now-with-sub-millisecond-precision\n// https://gist.github.com/timhall/4078614\n// https://github.com/Financial-Times/polyfill-service/tree/master/polyfills/requestAnimationFrame\n// Expected to be used with Browserfiy\n// Browserify automatically detects the use of `global` and passes the\n// correct reference of `global`, `globalThis`, and finally `window`\nvar ONE_FRAME_TIME = 16;\n// Date.now\nif (!(Date.now && Date.prototype.getTime)) {\n Date.now = function now() {\n return new Date().getTime();\n };\n}\n// performance.now\nif (!(globalThis.performance && globalThis.performance.now)) {\n var startTime_1 = Date.now();\n if (!globalThis.performance) {\n globalThis.performance = {};\n }\n globalThis.performance.now = function () { return Date.now() - startTime_1; };\n}\n// requestAnimationFrame\nvar lastTime = Date.now();\nvar vendors = ['ms', 'moz', 'webkit', 'o'];\nfor (var x = 0; x < vendors.length && !globalThis.requestAnimationFrame; ++x) {\n var p = vendors[x];\n globalThis.requestAnimationFrame = globalThis[p + \"RequestAnimationFrame\"];\n globalThis.cancelAnimationFrame = globalThis[p + \"CancelAnimationFrame\"]\n || globalThis[p + \"CancelRequestAnimationFrame\"];\n}\nif (!globalThis.requestAnimationFrame) {\n globalThis.requestAnimationFrame = function (callback) {\n if (typeof callback !== 'function') {\n throw new TypeError(callback + \"is not a function\");\n }\n var currentTime = Date.now();\n var delay = ONE_FRAME_TIME + lastTime - currentTime;\n if (delay < 0) {\n delay = 0;\n }\n lastTime = currentTime;\n return globalThis.self.setTimeout(function () {\n lastTime = Date.now();\n callback(performance.now());\n }, delay);\n };\n}\nif (!globalThis.cancelAnimationFrame) {\n globalThis.cancelAnimationFrame = function (id) { return clearTimeout(id); };\n}\n\n// References:\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/sign\nif (!Math.sign) {\n Math.sign = function mathSign(x) {\n x = Number(x);\n if (x === 0 || isNaN(x)) {\n return x;\n }\n return x > 0 ? 1 : -1;\n };\n}\n\n// References:\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isInteger\nif (!Number.isInteger) {\n Number.isInteger = function numberIsInteger(value) {\n return typeof value === 'number' && isFinite(value) && Math.floor(value) === value;\n };\n}\n\nif (!globalThis.ArrayBuffer) {\n globalThis.ArrayBuffer = Array;\n}\nif (!globalThis.Float32Array) {\n globalThis.Float32Array = Array;\n}\nif (!globalThis.Uint32Array) {\n globalThis.Uint32Array = Array;\n}\nif (!globalThis.Uint16Array) {\n globalThis.Uint16Array = Array;\n}\nif (!globalThis.Uint8Array) {\n globalThis.Uint8Array = Array;\n}\nif (!globalThis.Int32Array) {\n globalThis.Int32Array = Array;\n}\n//# sourceMappingURL=polyfill.js.map\n","/*!\n * @pixi/accessibility - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/accessibility is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { DisplayObject } from '@pixi/display';\nimport { isMobile, removeItems } from '@pixi/utils';\n\n/**\n * Default property values of accessible objects\n * used by {@link PIXI.AccessibilityManager}.\n *\n * @private\n * @function accessibleTarget\n * @memberof PIXI\n * @type {Object}\n * @example\n * function MyObject() {}\n *\n * Object.assign(\n * MyObject.prototype,\n * PIXI.accessibleTarget\n * );\n */\nvar accessibleTarget = {\n /**\n * Flag for if the object is accessible. If true AccessibilityManager will overlay a\n * shadow div with attributes set\n *\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n */\n accessible: false,\n /**\n * Sets the title attribute of the shadow div\n * If accessibleTitle AND accessibleHint has not been this will default to 'displayObject [tabIndex]'\n *\n * @member {?string}\n * @memberof PIXI.DisplayObject#\n */\n accessibleTitle: null,\n /**\n * Sets the aria-label attribute of the shadow div\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n */\n accessibleHint: null,\n /**\n * @member {number}\n * @memberof PIXI.DisplayObject#\n * @private\n * @todo Needs docs.\n */\n tabIndex: 0,\n /**\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n * @todo Needs docs.\n */\n _accessibleActive: false,\n /**\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n * @todo Needs docs.\n */\n _accessibleDiv: null,\n /**\n * Specify the type of div the accessible layer is. Screen readers treat the element differently\n * depending on this type. Defaults to button.\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n * @default 'button'\n */\n accessibleType: 'button',\n /**\n * Specify the pointer-events the accessible div will use\n * Defaults to auto.\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n * @default 'auto'\n */\n accessiblePointerEvents: 'auto',\n /**\n * Setting to false will prevent any children inside this container to\n * be accessible. Defaults to true.\n *\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n * @default true\n */\n accessibleChildren: true,\n renderId: -1,\n};\n\n// add some extra variables to the container..\nDisplayObject.mixin(accessibleTarget);\nvar KEY_CODE_TAB = 9;\nvar DIV_TOUCH_SIZE = 100;\nvar DIV_TOUCH_POS_X = 0;\nvar DIV_TOUCH_POS_Y = 0;\nvar DIV_TOUCH_ZINDEX = 2;\nvar DIV_HOOK_SIZE = 1;\nvar DIV_HOOK_POS_X = -1000;\nvar DIV_HOOK_POS_Y = -1000;\nvar DIV_HOOK_ZINDEX = 2;\n/**\n * The Accessibility manager recreates the ability to tab and have content read by screen readers.\n * This is very important as it can possibly help people with disabilities access PixiJS content.\n *\n * A DisplayObject can be made accessible just like it can be made interactive. This manager will map the\n * events as if the mouse was being used, minimizing the effort required to implement.\n *\n * An instance of this class is automatically created by default, and can be found at `renderer.plugins.accessibility`\n *\n * @class\n * @memberof PIXI\n */\nvar AccessibilityManager = /** @class */ (function () {\n /**\n * @param {PIXI.CanvasRenderer|PIXI.Renderer} renderer - A reference to the current renderer\n */\n function AccessibilityManager(renderer) {\n /** Setting this to true will visually show the divs. */\n this.debug = false;\n /** Internal variable, see isActive getter. */\n this._isActive = false;\n /** Internal variable, see isMobileAccessibility getter. */\n this._isMobileAccessibility = false;\n /** A simple pool for storing divs. */\n this.pool = [];\n /** This is a tick used to check if an object is no longer being rendered. */\n this.renderId = 0;\n /** The array of currently active accessible items. */\n this.children = [];\n /** Count to throttle div updates on android devices. */\n this.androidUpdateCount = 0;\n /** The frequency to update the div elements. */\n this.androidUpdateFrequency = 500; // 2fps\n this._hookDiv = null;\n if (isMobile.tablet || isMobile.phone) {\n this.createTouchHook();\n }\n // first we create a div that will sit over the PixiJS element. This is where the div overlays will go.\n var div = document.createElement('div');\n div.style.width = DIV_TOUCH_SIZE + \"px\";\n div.style.height = DIV_TOUCH_SIZE + \"px\";\n div.style.position = 'absolute';\n div.style.top = DIV_TOUCH_POS_X + \"px\";\n div.style.left = DIV_TOUCH_POS_Y + \"px\";\n div.style.zIndex = DIV_TOUCH_ZINDEX.toString();\n this.div = div;\n this.renderer = renderer;\n /**\n * pre-bind the functions\n *\n * @type {Function}\n * @private\n */\n this._onKeyDown = this._onKeyDown.bind(this);\n /**\n * pre-bind the functions\n *\n * @type {Function}\n * @private\n */\n this._onMouseMove = this._onMouseMove.bind(this);\n // let listen for tab.. once pressed we can fire up and show the accessibility layer\n globalThis.addEventListener('keydown', this._onKeyDown, false);\n }\n Object.defineProperty(AccessibilityManager.prototype, \"isActive\", {\n /**\n * Value of `true` if accessibility is currently active and accessibility layers are showing.\n * @member {boolean}\n * @readonly\n */\n get: function () {\n return this._isActive;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AccessibilityManager.prototype, \"isMobileAccessibility\", {\n /**\n * Value of `true` if accessibility is enabled for touch devices.\n * @member {boolean}\n * @readonly\n */\n get: function () {\n return this._isMobileAccessibility;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Creates the touch hooks.\n *\n * @private\n */\n AccessibilityManager.prototype.createTouchHook = function () {\n var _this = this;\n var hookDiv = document.createElement('button');\n hookDiv.style.width = DIV_HOOK_SIZE + \"px\";\n hookDiv.style.height = DIV_HOOK_SIZE + \"px\";\n hookDiv.style.position = 'absolute';\n hookDiv.style.top = DIV_HOOK_POS_X + \"px\";\n hookDiv.style.left = DIV_HOOK_POS_Y + \"px\";\n hookDiv.style.zIndex = DIV_HOOK_ZINDEX.toString();\n hookDiv.style.backgroundColor = '#FF0000';\n hookDiv.title = 'select to enable accessibility for this content';\n hookDiv.addEventListener('focus', function () {\n _this._isMobileAccessibility = true;\n _this.activate();\n _this.destroyTouchHook();\n });\n document.body.appendChild(hookDiv);\n this._hookDiv = hookDiv;\n };\n /**\n * Destroys the touch hooks.\n *\n * @private\n */\n AccessibilityManager.prototype.destroyTouchHook = function () {\n if (!this._hookDiv) {\n return;\n }\n document.body.removeChild(this._hookDiv);\n this._hookDiv = null;\n };\n /**\n * Activating will cause the Accessibility layer to be shown.\n * This is called when a user presses the tab key.\n *\n * @private\n */\n AccessibilityManager.prototype.activate = function () {\n var _a;\n if (this._isActive) {\n return;\n }\n this._isActive = true;\n globalThis.document.addEventListener('mousemove', this._onMouseMove, true);\n globalThis.removeEventListener('keydown', this._onKeyDown, false);\n this.renderer.on('postrender', this.update, this);\n (_a = this.renderer.view.parentNode) === null || _a === void 0 ? void 0 : _a.appendChild(this.div);\n };\n /**\n * Deactivating will cause the Accessibility layer to be hidden.\n * This is called when a user moves the mouse.\n *\n * @private\n */\n AccessibilityManager.prototype.deactivate = function () {\n var _a;\n if (!this._isActive || this._isMobileAccessibility) {\n return;\n }\n this._isActive = false;\n globalThis.document.removeEventListener('mousemove', this._onMouseMove, true);\n globalThis.addEventListener('keydown', this._onKeyDown, false);\n this.renderer.off('postrender', this.update);\n (_a = this.div.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(this.div);\n };\n /**\n * This recursive function will run through the scene graph and add any new accessible objects to the DOM layer.\n *\n * @private\n * @param {PIXI.Container} displayObject - The DisplayObject to check.\n */\n AccessibilityManager.prototype.updateAccessibleObjects = function (displayObject) {\n if (!displayObject.visible || !displayObject.accessibleChildren) {\n return;\n }\n if (displayObject.accessible && displayObject.interactive) {\n if (!displayObject._accessibleActive) {\n this.addChild(displayObject);\n }\n displayObject.renderId = this.renderId;\n }\n var children = displayObject.children;\n if (children) {\n for (var i = 0; i < children.length; i++) {\n this.updateAccessibleObjects(children[i]);\n }\n }\n };\n /**\n * Before each render this function will ensure that all divs are mapped correctly to their DisplayObjects.\n *\n * @private\n */\n AccessibilityManager.prototype.update = function () {\n /* On Android default web browser, tab order seems to be calculated by position rather than tabIndex,\n * moving buttons can cause focus to flicker between two buttons making it hard/impossible to navigate,\n * so I am just running update every half a second, seems to fix it.\n */\n var now = performance.now();\n if (isMobile.android.device && now < this.androidUpdateCount) {\n return;\n }\n this.androidUpdateCount = now + this.androidUpdateFrequency;\n if (!this.renderer.renderingToScreen) {\n return;\n }\n // update children...\n if (this.renderer._lastObjectRendered) {\n this.updateAccessibleObjects(this.renderer._lastObjectRendered);\n }\n var _a = this.renderer.view.getBoundingClientRect(), left = _a.left, top = _a.top, width = _a.width, height = _a.height;\n var _b = this.renderer, viewWidth = _b.width, viewHeight = _b.height, resolution = _b.resolution;\n var sx = (width / viewWidth) * resolution;\n var sy = (height / viewHeight) * resolution;\n var div = this.div;\n div.style.left = left + \"px\";\n div.style.top = top + \"px\";\n div.style.width = viewWidth + \"px\";\n div.style.height = viewHeight + \"px\";\n for (var i = 0; i < this.children.length; i++) {\n var child = this.children[i];\n if (child.renderId !== this.renderId) {\n child._accessibleActive = false;\n removeItems(this.children, i, 1);\n this.div.removeChild(child._accessibleDiv);\n this.pool.push(child._accessibleDiv);\n child._accessibleDiv = null;\n i--;\n }\n else {\n // map div to display..\n div = child._accessibleDiv;\n var hitArea = child.hitArea;\n var wt = child.worldTransform;\n if (child.hitArea) {\n div.style.left = (wt.tx + (hitArea.x * wt.a)) * sx + \"px\";\n div.style.top = (wt.ty + (hitArea.y * wt.d)) * sy + \"px\";\n div.style.width = hitArea.width * wt.a * sx + \"px\";\n div.style.height = hitArea.height * wt.d * sy + \"px\";\n }\n else {\n hitArea = child.getBounds();\n this.capHitArea(hitArea);\n div.style.left = hitArea.x * sx + \"px\";\n div.style.top = hitArea.y * sy + \"px\";\n div.style.width = hitArea.width * sx + \"px\";\n div.style.height = hitArea.height * sy + \"px\";\n // update button titles and hints if they exist and they've changed\n if (div.title !== child.accessibleTitle && child.accessibleTitle !== null) {\n div.title = child.accessibleTitle;\n }\n if (div.getAttribute('aria-label') !== child.accessibleHint\n && child.accessibleHint !== null) {\n div.setAttribute('aria-label', child.accessibleHint);\n }\n }\n // the title or index may have changed, if so lets update it!\n if (child.accessibleTitle !== div.title || child.tabIndex !== div.tabIndex) {\n div.title = child.accessibleTitle;\n div.tabIndex = child.tabIndex;\n if (this.debug)\n { this.updateDebugHTML(div); }\n }\n }\n }\n // increment the render id..\n this.renderId++;\n };\n /**\n * private function that will visually add the information to the\n * accessability div\n *\n * @param {HTMLElement} div\n */\n AccessibilityManager.prototype.updateDebugHTML = function (div) {\n div.innerHTML = \"type: \" + div.type + \"</br> title : \" + div.title + \"</br> tabIndex: \" + div.tabIndex;\n };\n /**\n * Adjust the hit area based on the bounds of a display object\n *\n * @param {PIXI.Rectangle} hitArea - Bounds of the child\n */\n AccessibilityManager.prototype.capHitArea = function (hitArea) {\n if (hitArea.x < 0) {\n hitArea.width += hitArea.x;\n hitArea.x = 0;\n }\n if (hitArea.y < 0) {\n hitArea.height += hitArea.y;\n hitArea.y = 0;\n }\n var _a = this.renderer, viewWidth = _a.width, viewHeight = _a.height;\n if (hitArea.x + hitArea.width > viewWidth) {\n hitArea.width = viewWidth - hitArea.x;\n }\n if (hitArea.y + hitArea.height > viewHeight) {\n hitArea.height = viewHeight - hitArea.y;\n }\n };\n /**\n * Adds a DisplayObject to the accessibility manager\n *\n * @private\n * @param {PIXI.DisplayObject} displayObject - The child to make accessible.\n */\n AccessibilityManager.prototype.addChild = function (displayObject) {\n // this.activate();\n var div = this.pool.pop();\n if (!div) {\n div = document.createElement('button');\n div.style.width = DIV_TOUCH_SIZE + \"px\";\n div.style.height = DIV_TOUCH_SIZE + \"px\";\n div.style.backgroundColor = this.debug ? 'rgba(255,255,255,0.5)' : 'transparent';\n div.style.position = 'absolute';\n div.style.zIndex = DIV_TOUCH_ZINDEX.toString();\n div.style.borderStyle = 'none';\n // ARIA attributes ensure that button title and hint updates are announced properly\n if (navigator.userAgent.toLowerCase().indexOf('chrome') > -1) {\n // Chrome doesn't need aria-live to work as intended; in fact it just gets more confused.\n div.setAttribute('aria-live', 'off');\n }\n else {\n div.setAttribute('aria-live', 'polite');\n }\n if (navigator.userAgent.match(/rv:.*Gecko\\//)) {\n // FireFox needs this to announce only the new button name\n div.setAttribute('aria-relevant', 'additions');\n }\n else {\n // required by IE, other browsers don't much care\n div.setAttribute('aria-relevant', 'text');\n }\n div.addEventListener('click', this._onClick.bind(this));\n div.addEventListener('focus', this._onFocus.bind(this));\n div.addEventListener('focusout', this._onFocusOut.bind(this));\n }\n // set pointer events\n div.style.pointerEvents = displayObject.accessiblePointerEvents;\n // set the type, this defaults to button!\n div.type = displayObject.accessibleType;\n if (displayObject.accessibleTitle && displayObject.accessibleTitle !== null) {\n div.title = displayObject.accessibleTitle;\n }\n else if (!displayObject.accessibleHint\n || displayObject.accessibleHint === null) {\n div.title = \"displayObject \" + displayObject.tabIndex;\n }\n if (displayObject.accessibleHint\n && displayObject.accessibleHint !== null) {\n div.setAttribute('aria-label', displayObject.accessibleHint);\n }\n if (this.debug)\n { this.updateDebugHTML(div); }\n displayObject._accessibleActive = true;\n displayObject._accessibleDiv = div;\n div.displayObject = displayObject;\n this.children.push(displayObject);\n this.div.appendChild(displayObject._accessibleDiv);\n displayObject._accessibleDiv.tabIndex = displayObject.tabIndex;\n };\n /**\n * Maps the div button press to pixi's InteractionManager (click)\n *\n * @private\n * @param {MouseEvent} e - The click event.\n */\n AccessibilityManager.prototype._onClick = function (e) {\n var interactionManager = this.renderer.plugins.interaction;\n var displayObject = e.target.displayObject;\n var eventData = interactionManager.eventData;\n interactionManager.dispatchEvent(displayObject, 'click', eventData);\n interactionManager.dispatchEvent(displayObject, 'pointertap', eventData);\n interactionManager.dispatchEvent(displayObject, 'tap', eventData);\n };\n /**\n * Maps the div focus events to pixi's InteractionManager (mouseover)\n *\n * @private\n * @param {FocusEvent} e - The focus event.\n */\n AccessibilityManager.prototype._onFocus = function (e) {\n if (!e.target.getAttribute('aria-live')) {\n e.target.setAttribute('aria-live', 'assertive');\n }\n var interactionManager = this.renderer.plugins.interaction;\n var displayObject = e.target.displayObject;\n var eventData = interactionManager.eventData;\n interactionManager.dispatchEvent(displayObject, 'mouseover', eventData);\n };\n /**\n * Maps the div focus events to pixi's InteractionManager (mouseout)\n *\n * @private\n * @param {FocusEvent} e - The focusout event.\n */\n AccessibilityManager.prototype._onFocusOut = function (e) {\n if (!e.target.getAttribute('aria-live')) {\n e.target.setAttribute('aria-live', 'polite');\n }\n var interactionManager = this.renderer.plugins.interaction;\n var displayObject = e.target.displayObject;\n var eventData = interactionManager.eventData;\n interactionManager.dispatchEvent(displayObject, 'mouseout', eventData);\n };\n /**\n * Is called when a key is pressed\n *\n * @private\n * @param {KeyboardEvent} e - The keydown event.\n */\n AccessibilityManager.prototype._onKeyDown = function (e) {\n if (e.keyCode !== KEY_CODE_TAB) {\n return;\n }\n this.activate();\n };\n /**\n * Is called when the mouse moves across the renderer element\n *\n * @private\n * @param {MouseEvent} e - The mouse event.\n */\n AccessibilityManager.prototype._onMouseMove = function (e) {\n if (e.movementX === 0 && e.movementY === 0) {\n return;\n }\n this.deactivate();\n };\n /**\n * Destroys the accessibility manager\n *\n */\n AccessibilityManager.prototype.destroy = function () {\n this.destroyTouchHook();\n this.div = null;\n globalThis.document.removeEventListener('mousemove', this._onMouseMove, true);\n globalThis.removeEventListener('keydown', this._onKeyDown);\n this.pool = null;\n this.children = null;\n this.renderer = null;\n };\n return AccessibilityManager;\n}());\n\nexport { AccessibilityManager, accessibleTarget };\n//# sourceMappingURL=accessibility.js.map\n","/*!\n * @pixi/interaction - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/interaction is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Point } from '@pixi/math';\nimport { Ticker, UPDATE_PRIORITY } from '@pixi/ticker';\nimport { DisplayObject, TemporaryDisplayObject } from '@pixi/display';\nimport { EventEmitter } from '@pixi/utils';\n\n/**\n * Holds all information related to an Interaction event\n *\n * @memberof PIXI\n */\nvar InteractionData = /** @class */ (function () {\n function InteractionData() {\n /**\n * Pressure applied by the pointing device during the event. A Touch's force property\n * will be represented by this value.\n *\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pressure\n */\n this.pressure = 0;\n /**\n * From TouchEvents (not PointerEvents triggered by touches), the rotationAngle of the Touch.\n *\n * @see https://developer.mozilla.org/en-US/docs/Web/API/Touch/rotationAngle\n */\n this.rotationAngle = 0;\n /**\n * Twist of a stylus pointer.\n *\n * @see https://w3c.github.io/pointerevents/#pointerevent-interface\n */\n this.twist = 0;\n /**\n * Barrel pressure on a stylus pointer.\n *\n * @see https://w3c.github.io/pointerevents/#pointerevent-interface\n */\n this.tangentialPressure = 0;\n this.global = new Point();\n this.target = null;\n this.originalEvent = null;\n this.identifier = null;\n this.isPrimary = false;\n this.button = 0;\n this.buttons = 0;\n this.width = 0;\n this.height = 0;\n this.tiltX = 0;\n this.tiltY = 0;\n this.pointerType = null;\n this.pressure = 0;\n this.rotationAngle = 0;\n this.twist = 0;\n this.tangentialPressure = 0;\n }\n Object.defineProperty(InteractionData.prototype, \"pointerId\", {\n /**\n * The unique identifier of the pointer. It will be the same as `identifier`.\n *\n * @readonly\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pointerId\n */\n get: function () {\n return this.identifier;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * This will return the local coordinates of the specified displayObject for this InteractionData\n *\n * @param displayObject - The DisplayObject that you would like the local\n * coords off\n * @param point - A Point object in which to store the value, optional (otherwise\n * will create a new point)\n * @param globalPos - A Point object containing your custom global coords, optional\n * (otherwise will use the current global coords)\n * @return - A point containing the coordinates of the InteractionData position relative\n * to the DisplayObject\n */\n InteractionData.prototype.getLocalPosition = function (displayObject, point, globalPos) {\n return displayObject.worldTransform.applyInverse(globalPos || this.global, point);\n };\n /**\n * Copies properties from normalized event data.\n *\n * @param {Touch|MouseEvent|PointerEvent} event - The normalized event data\n */\n InteractionData.prototype.copyEvent = function (event) {\n // isPrimary should only change on touchstart/pointerdown, so we don't want to overwrite\n // it with \"false\" on later events when our shim for it on touch events might not be\n // accurate\n if ('isPrimary' in event && event.isPrimary) {\n this.isPrimary = true;\n }\n this.button = 'button' in event && event.button;\n // event.buttons is not available in all browsers (ie. Safari), but it does have a non-standard\n // event.which property instead, which conveys the same information.\n var buttons = 'buttons' in event && event.buttons;\n this.buttons = Number.isInteger(buttons) ? buttons : 'which' in event && event.which;\n this.width = 'width' in event && event.width;\n this.height = 'height' in event && event.height;\n this.tiltX = 'tiltX' in event && event.tiltX;\n this.tiltY = 'tiltY' in event && event.tiltY;\n this.pointerType = 'pointerType' in event && event.pointerType;\n this.pressure = 'pressure' in event && event.pressure;\n this.rotationAngle = 'rotationAngle' in event && event.rotationAngle;\n this.twist = ('twist' in event && event.twist) || 0;\n this.tangentialPressure = ('tangentialPressure' in event && event.tangentialPressure) || 0;\n };\n /** Resets the data for pooling. */\n InteractionData.prototype.reset = function () {\n // isPrimary is the only property that we really need to reset - everything else is\n // guaranteed to be overwritten\n this.isPrimary = false;\n };\n return InteractionData;\n}());\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * Event class that mimics native DOM events.\n *\n * @memberof PIXI\n */\nvar InteractionEvent = /** @class */ (function () {\n function InteractionEvent() {\n this.stopped = false;\n this.stopsPropagatingAt = null;\n this.stopPropagationHint = false;\n this.target = null;\n this.currentTarget = null;\n this.type = null;\n this.data = null;\n }\n /** Prevents event from reaching any objects other than the current object. */\n InteractionEvent.prototype.stopPropagation = function () {\n this.stopped = true;\n this.stopPropagationHint = true;\n this.stopsPropagatingAt = this.currentTarget;\n };\n /** Resets the event. */\n InteractionEvent.prototype.reset = function () {\n this.stopped = false;\n this.stopsPropagatingAt = null;\n this.stopPropagationHint = false;\n this.currentTarget = null;\n this.target = null;\n };\n return InteractionEvent;\n}());\n\n/**\n * DisplayObjects with the {@link PIXI.interactiveTarget} mixin use this class to track interactions\n *\n * @class\n * @private\n * @memberof PIXI\n */\nvar InteractionTrackingData = /** @class */ (function () {\n /**\n * @param {number} pointerId - Unique pointer id of the event\n * @private\n */\n function InteractionTrackingData(pointerId) {\n this._pointerId = pointerId;\n this._flags = InteractionTrackingData.FLAGS.NONE;\n }\n /**\n *\n * @private\n * @param {number} flag - The interaction flag to set\n * @param {boolean} yn - Should the flag be set or unset\n */\n InteractionTrackingData.prototype._doSet = function (flag, yn) {\n if (yn) {\n this._flags = this._flags | flag;\n }\n else {\n this._flags = this._flags & (~flag);\n }\n };\n Object.defineProperty(InteractionTrackingData.prototype, \"pointerId\", {\n /**\n * Unique pointer id of the event\n *\n * @readonly\n * @private\n * @member {number}\n */\n get: function () {\n return this._pointerId;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"flags\", {\n /**\n * State of the tracking data, expressed as bit flags\n *\n * @private\n * @member {number}\n */\n get: function () {\n return this._flags;\n },\n set: function (flags) {\n this._flags = flags;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"none\", {\n /**\n * Is the tracked event inactive (not over or down)?\n *\n * @private\n * @member {number}\n */\n get: function () {\n return this._flags === InteractionTrackingData.FLAGS.NONE;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"over\", {\n /**\n * Is the tracked event over the DisplayObject?\n *\n * @private\n * @member {boolean}\n */\n get: function () {\n return (this._flags & InteractionTrackingData.FLAGS.OVER) !== 0;\n },\n set: function (yn) {\n this._doSet(InteractionTrackingData.FLAGS.OVER, yn);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"rightDown\", {\n /**\n * Did the right mouse button come down in the DisplayObject?\n *\n * @private\n * @member {boolean}\n */\n get: function () {\n return (this._flags & InteractionTrackingData.FLAGS.RIGHT_DOWN) !== 0;\n },\n set: function (yn) {\n this._doSet(InteractionTrackingData.FLAGS.RIGHT_DOWN, yn);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"leftDown\", {\n /**\n * Did the left mouse button come down in the DisplayObject?\n *\n * @private\n * @member {boolean}\n */\n get: function () {\n return (this._flags & InteractionTrackingData.FLAGS.LEFT_DOWN) !== 0;\n },\n set: function (yn) {\n this._doSet(InteractionTrackingData.FLAGS.LEFT_DOWN, yn);\n },\n enumerable: false,\n configurable: true\n });\n InteractionTrackingData.FLAGS = Object.freeze({\n NONE: 0,\n OVER: 1 << 0,\n LEFT_DOWN: 1 << 1,\n RIGHT_DOWN: 1 << 2,\n });\n return InteractionTrackingData;\n}());\n\n/**\n * Strategy how to search through stage tree for interactive objects\n *\n * @memberof PIXI\n */\nvar TreeSearch = /** @class */ (function () {\n function TreeSearch() {\n this._tempPoint = new Point();\n }\n /**\n * Recursive implementation for findHit\n *\n * @private\n * @param interactionEvent - event containing the point that\n * is tested for collision\n * @param displayObject - the displayObject\n * that will be hit test (recursively crawls its children)\n * @param func - the function that will be called on each interactive object. The\n * interactionEvent, displayObject and hit will be passed to the function\n * @param hitTest - this indicates if the objects inside should be hit test against the point\n * @param interactive - Whether the displayObject is interactive\n * @return - Returns true if the displayObject hit the point\n */\n TreeSearch.prototype.recursiveFindHit = function (interactionEvent, displayObject, func, hitTest, interactive) {\n if (!displayObject || !displayObject.visible) {\n return false;\n }\n var point = interactionEvent.data.global;\n // Took a little while to rework this function correctly! But now it is done and nice and optimized! ^_^\n //\n // This function will now loop through all objects and then only hit test the objects it HAS\n // to, not all of them. MUCH faster..\n // An object will be hit test if the following is true:\n //\n // 1: It is interactive.\n // 2: It belongs to a parent that is interactive AND one of the parents children have not already been hit.\n //\n // As another little optimization once an interactive object has been hit we can carry on\n // through the scenegraph, but we know that there will be no more hits! So we can avoid extra hit tests\n // A final optimization is that an object is not hit test directly if a child has already been hit.\n interactive = displayObject.interactive || interactive;\n var hit = false;\n var interactiveParent = interactive;\n // Flag here can set to false if the event is outside the parents hitArea or mask\n var hitTestChildren = true;\n // If there is a hitArea, no need to test against anything else if the pointer is not within the hitArea\n // There is also no longer a need to hitTest children.\n if (displayObject.hitArea) {\n if (hitTest) {\n displayObject.worldTransform.applyInverse(point, this._tempPoint);\n if (!displayObject.hitArea.contains(this._tempPoint.x, this._tempPoint.y)) {\n hitTest = false;\n hitTestChildren = false;\n }\n else {\n hit = true;\n }\n }\n interactiveParent = false;\n }\n // If there is a mask, no need to hitTest against anything else if the pointer is not within the mask.\n // We still want to hitTestChildren, however, to ensure a mouseout can still be generated.\n // https://github.com/pixijs/pixi.js/issues/5135\n else if (displayObject._mask) {\n if (hitTest) {\n if (!(displayObject._mask.containsPoint && displayObject._mask.containsPoint(point))) {\n hitTest = false;\n }\n }\n }\n // ** FREE TIP **! If an object is not interactive or has no buttons in it\n // (such as a game scene!) set interactiveChildren to false for that displayObject.\n // This will allow PixiJS to completely ignore and bypass checking the displayObjects children.\n if (hitTestChildren && displayObject.interactiveChildren && displayObject.children) {\n var children = displayObject.children;\n for (var i = children.length - 1; i >= 0; i--) {\n var child = children[i];\n // time to get recursive.. if this function will return if something is hit..\n var childHit = this.recursiveFindHit(interactionEvent, child, func, hitTest, interactiveParent);\n if (childHit) {\n // its a good idea to check if a child has lost its parent.\n // this means it has been removed whilst looping so its best\n if (!child.parent) {\n continue;\n }\n // we no longer need to hit test any more objects in this container as we we\n // now know the parent has been hit\n interactiveParent = false;\n // If the child is interactive , that means that the object hit was actually\n // interactive and not just the child of an interactive object.\n // This means we no longer need to hit test anything else. We still need to run\n // through all objects, but we don't need to perform any hit tests.\n if (childHit) {\n if (interactionEvent.target) {\n hitTest = false;\n }\n hit = true;\n }\n }\n }\n }\n // no point running this if the item is not interactive or does not have an interactive parent.\n if (interactive) {\n // if we are hit testing (as in we have no hit any objects yet)\n // We also don't need to worry about hit testing if once of the displayObjects children\n // has already been hit - but only if it was interactive, otherwise we need to keep\n // looking for an interactive child, just in case we hit one\n if (hitTest && !interactionEvent.target) {\n // already tested against hitArea if it is defined\n if (!displayObject.hitArea && displayObject.containsPoint) {\n if (displayObject.containsPoint(point)) {\n hit = true;\n }\n }\n }\n if (displayObject.interactive) {\n if (hit && !interactionEvent.target) {\n interactionEvent.target = displayObject;\n }\n if (func) {\n func(interactionEvent, displayObject, !!hit);\n }\n }\n }\n return hit;\n };\n /**\n * This function is provides a neat way of crawling through the scene graph and running a\n * specified function on all interactive objects it finds. It will also take care of hit\n * testing the interactive objects and passes the hit across in the function.\n *\n * @private\n * @param interactionEvent - event containing the point that\n * is tested for collision\n * @param displayObject - the displayObject\n * that will be hit test (recursively crawls its children)\n * @param func - the function that will be called on each interactive object. The\n * interactionEvent, displayObject and hit will be passed to the function\n * @param hitTest - this indicates if the objects inside should be hit test against the point\n * @return - Returns true if the displayObject hit the point\n */\n TreeSearch.prototype.findHit = function (interactionEvent, displayObject, func, hitTest) {\n this.recursiveFindHit(interactionEvent, displayObject, func, hitTest, false);\n };\n return TreeSearch;\n}());\n\n/**\n * Interface for classes that represent a hit area.\n *\n * It is implemented by the following classes:\n * - {@link PIXI.Circle}\n * - {@link PIXI.Ellipse}\n * - {@link PIXI.Polygon}\n * - {@link PIXI.RoundedRectangle}\n *\n * @interface IHitArea\n * @memberof PIXI\n */\n/**\n * Checks whether the x and y coordinates given are contained within this area\n *\n * @method\n * @name contains\n * @memberof PIXI.IHitArea#\n * @param {number} x - The X coordinate of the point to test\n * @param {number} y - The Y coordinate of the point to test\n * @return {boolean} Whether the x/y coordinates are within this area\n */\n/**\n * Default property values of interactive objects\n * Used by {@link PIXI.InteractionManager} to automatically give all DisplayObjects these properties\n *\n * @private\n * @name interactiveTarget\n * @type {Object}\n * @memberof PIXI\n * @example\n * function MyObject() {}\n *\n * Object.assign(\n * DisplayObject.prototype,\n * PIXI.interactiveTarget\n * );\n */\nvar interactiveTarget = {\n interactive: false,\n interactiveChildren: true,\n hitArea: null,\n /**\n * If enabled, the mouse cursor use the pointer behavior when hovered over the displayObject if it is interactive\n * Setting this changes the 'cursor' property to `'pointer'`.\n *\n * @example\n * const sprite = new PIXI.Sprite(texture);\n * sprite.interactive = true;\n * sprite.buttonMode = true;\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n */\n get buttonMode() {\n return this.cursor === 'pointer';\n },\n set buttonMode(value) {\n if (value) {\n this.cursor = 'pointer';\n }\n else if (this.cursor === 'pointer') {\n this.cursor = null;\n }\n },\n /**\n * This defines what cursor mode is used when the mouse cursor\n * is hovered over the displayObject.\n *\n * @example\n * const sprite = new PIXI.Sprite(texture);\n * sprite.interactive = true;\n * sprite.cursor = 'wait';\n * @see https://developer.mozilla.org/en/docs/Web/CSS/cursor\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n */\n cursor: null,\n /**\n * Internal set of all active pointers, by identifier\n *\n * @member {Map<number, InteractionTrackingData>}\n * @memberof PIXI.DisplayObject#\n * @private\n */\n get trackedPointers() {\n if (this._trackedPointers === undefined)\n { this._trackedPointers = {}; }\n return this._trackedPointers;\n },\n /**\n * Map of all tracked pointers, by identifier. Use trackedPointers to access.\n *\n * @private\n * @type {Map<number, InteractionTrackingData>}\n */\n _trackedPointers: undefined,\n};\n\n// Mix interactiveTarget into DisplayObject.prototype\nDisplayObject.mixin(interactiveTarget);\nvar MOUSE_POINTER_ID = 1;\n// helpers for hitTest() - only used inside hitTest()\nvar hitTestEvent = {\n target: null,\n data: {\n global: null,\n },\n};\n/**\n * The interaction manager deals with mouse, touch and pointer events.\n *\n * Any DisplayObject can be interactive if its `interactive` property is set to true.\n *\n * This manager also supports multitouch.\n *\n * An instance of this class is automatically created by default, and can be found at `renderer.plugins.interaction`\n *\n * @memberof PIXI\n */\nvar InteractionManager = /** @class */ (function (_super) {\n __extends(InteractionManager, _super);\n /**\n * @param {PIXI.CanvasRenderer|PIXI.Renderer} renderer - A reference to the current renderer\n * @param options - The options for the manager.\n * @param {boolean} [options.autoPreventDefault=true] - Should the manager automatically prevent default browser actions.\n * @param {number} [options.interactionFrequency=10] - Maximum frequency (ms) at pointer over/out states will be checked.\n * @param {number} [options.useSystemTicker=true] - Whether to add {@link tickerUpdate} to {@link PIXI.Ticker.system}.\n */\n function InteractionManager(renderer, options) {\n var _this = _super.call(this) || this;\n options = options || {};\n _this.renderer = renderer;\n _this.autoPreventDefault = options.autoPreventDefault !== undefined ? options.autoPreventDefault : true;\n _this.interactionFrequency = options.interactionFrequency || 10;\n _this.mouse = new InteractionData();\n _this.mouse.identifier = MOUSE_POINTER_ID;\n // setting the mouse to start off far off screen will mean that mouse over does\n // not get called before we even move the mouse.\n _this.mouse.global.set(-999999);\n _this.activeInteractionData = {};\n _this.activeInteractionData[MOUSE_POINTER_ID] = _this.mouse;\n _this.interactionDataPool = [];\n _this.eventData = new InteractionEvent();\n _this.interactionDOMElement = null;\n _this.moveWhenInside = false;\n _this.eventsAdded = false;\n _this.tickerAdded = false;\n _this.mouseOverRenderer = !('PointerEvent' in globalThis);\n _this.supportsTouchEvents = 'ontouchstart' in globalThis;\n _this.supportsPointerEvents = !!globalThis.PointerEvent;\n // this will make it so that you don't have to call bind all the time\n _this.onPointerUp = _this.onPointerUp.bind(_this);\n _this.processPointerUp = _this.processPointerUp.bind(_this);\n _this.onPointerCancel = _this.onPointerCancel.bind(_this);\n _this.processPointerCancel = _this.processPointerCancel.bind(_this);\n _this.onPointerDown = _this.onPointerDown.bind(_this);\n _this.processPointerDown = _this.processPointerDown.bind(_this);\n _this.onPointerMove = _this.onPointerMove.bind(_this);\n _this.processPointerMove = _this.processPointerMove.bind(_this);\n _this.onPointerOut = _this.onPointerOut.bind(_this);\n _this.processPointerOverOut = _this.processPointerOverOut.bind(_this);\n _this.onPointerOver = _this.onPointerOver.bind(_this);\n _this.cursorStyles = {\n default: 'inherit',\n pointer: 'pointer',\n };\n _this.currentCursorMode = null;\n _this.cursor = null;\n _this.resolution = 1;\n _this.delayedEvents = [];\n _this.search = new TreeSearch();\n _this._tempDisplayObject = new TemporaryDisplayObject();\n _this._eventListenerOptions = { capture: true, passive: false };\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed on the display\n * object.\n *\n * @event PIXI.InteractionManager#mousedown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * on the display object.\n *\n * @event PIXI.InteractionManager#rightdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released over the display\n * object.\n *\n * @event PIXI.InteractionManager#mouseup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * over the display object.\n *\n * @event PIXI.InteractionManager#rightup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed and released on\n * the display object.\n *\n * @event PIXI.InteractionManager#click\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * and released on the display object.\n *\n * @event PIXI.InteractionManager#rightclick\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released outside the\n * display object that initially registered a\n * [mousedown]{@link PIXI.InteractionManager#event:mousedown}.\n *\n * @event PIXI.InteractionManager#mouseupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * outside the display object that initially registered a\n * [rightdown]{@link PIXI.InteractionManager#event:rightdown}.\n *\n * @event PIXI.InteractionManager#rightupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved while over the display object\n *\n * @event PIXI.InteractionManager#mousemove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved onto the display object\n *\n * @event PIXI.InteractionManager#mouseover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved off the display object\n *\n * @event PIXI.InteractionManager#mouseout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed on the display object.\n *\n * @event PIXI.InteractionManager#pointerdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released over the display object.\n * Not always fired when some buttons are held down while others are released. In those cases,\n * use [mousedown]{@link PIXI.InteractionManager#event:mousedown} and\n * [mouseup]{@link PIXI.InteractionManager#event:mouseup} instead.\n *\n * @event PIXI.InteractionManager#pointerup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a pointer event\n *\n * @event PIXI.InteractionManager#pointercancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed and released on the display object.\n *\n * @event PIXI.InteractionManager#pointertap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released outside the display object that initially\n * registered a [pointerdown]{@link PIXI.InteractionManager#event:pointerdown}.\n *\n * @event PIXI.InteractionManager#pointerupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved while over the display object\n *\n * @event PIXI.InteractionManager#pointermove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved onto the display object\n *\n * @event PIXI.InteractionManager#pointerover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved off the display object\n *\n * @event PIXI.InteractionManager#pointerout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed on the display object.\n *\n * @event PIXI.InteractionManager#touchstart\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed from the display object.\n *\n * @event PIXI.InteractionManager#touchend\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a touch\n *\n * @event PIXI.InteractionManager#touchcancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed and removed from the display object.\n *\n * @event PIXI.InteractionManager#tap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed outside of the display object that initially\n * registered a [touchstart]{@link PIXI.InteractionManager#event:touchstart}.\n *\n * @event PIXI.InteractionManager#touchendoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is moved along the display object.\n *\n * @event PIXI.InteractionManager#touchmove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed on the display.\n * object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mousedown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * on the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released over the display\n * object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * over the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed and released on\n * the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#click\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * and released on the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightclick\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released outside the\n * display object that initially registered a\n * [mousedown]{@link PIXI.DisplayObject#event:mousedown}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * outside the display object that initially registered a\n * [rightdown]{@link PIXI.DisplayObject#event:rightdown}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved while over the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mousemove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved onto the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved off the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed on the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released over the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a pointer event.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointercancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed and released on the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointertap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released outside the display object that initially\n * registered a [pointerdown]{@link PIXI.DisplayObject#event:pointerdown}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved while over the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointermove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved onto the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved off the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed on the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchstart\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed from the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchend\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a touch.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchcancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed and removed from the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#tap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed outside of the display object that initially\n * registered a [touchstart]{@link PIXI.DisplayObject#event:touchstart}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchendoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is moved along the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchmove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n _this._useSystemTicker = options.useSystemTicker !== undefined ? options.useSystemTicker : true;\n _this.setTargetElement(_this.renderer.view, _this.renderer.resolution);\n return _this;\n }\n Object.defineProperty(InteractionManager.prototype, \"useSystemTicker\", {\n /**\n * Should the InteractionManager automatically add {@link tickerUpdate} to {@link PIXI.Ticker.system}.\n *\n * @default true\n */\n get: function () {\n return this._useSystemTicker;\n },\n set: function (useSystemTicker) {\n this._useSystemTicker = useSystemTicker;\n if (useSystemTicker) {\n this.addTickerListener();\n }\n else {\n this.removeTickerListener();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionManager.prototype, \"lastObjectRendered\", {\n /**\n * Last rendered object or temp object.\n *\n * @readonly\n * @protected\n */\n get: function () {\n return this.renderer._lastObjectRendered || this._tempDisplayObject;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Hit tests a point against the display tree, returning the first interactive object that is hit.\n *\n * @param globalPoint - A point to hit test with, in global space.\n * @param root - The root display object to start from. If omitted, defaults\n * to the last rendered root of the associated renderer.\n * @return - The hit display object, if any.\n */\n InteractionManager.prototype.hitTest = function (globalPoint, root) {\n // clear the target for our hit test\n hitTestEvent.target = null;\n // assign the global point\n hitTestEvent.data.global = globalPoint;\n // ensure safety of the root\n if (!root) {\n root = this.lastObjectRendered;\n }\n // run the hit test\n this.processInteractive(hitTestEvent, root, null, true);\n // return our found object - it'll be null if we didn't hit anything\n return hitTestEvent.target;\n };\n /**\n * Sets the DOM element which will receive mouse/touch events. This is useful for when you have\n * other DOM elements on top of the renderers Canvas element. With this you'll be bale to delegate\n * another DOM element to receive those events.\n *\n * @param element - the DOM element which will receive mouse and touch events.\n * @param resolution - The resolution / device pixel ratio of the new element (relative to the canvas).\n */\n InteractionManager.prototype.setTargetElement = function (element, resolution) {\n if (resolution === void 0) { resolution = 1; }\n this.removeTickerListener();\n this.removeEvents();\n this.interactionDOMElement = element;\n this.resolution = resolution;\n this.addEvents();\n this.addTickerListener();\n };\n /** Adds the ticker listener. */\n InteractionManager.prototype.addTickerListener = function () {\n if (this.tickerAdded || !this.interactionDOMElement || !this._useSystemTicker) {\n return;\n }\n Ticker.system.add(this.tickerUpdate, this, UPDATE_PRIORITY.INTERACTION);\n this.tickerAdded = true;\n };\n /** Removes the ticker listener. */\n InteractionManager.prototype.removeTickerListener = function () {\n if (!this.tickerAdded) {\n return;\n }\n Ticker.system.remove(this.tickerUpdate, this);\n this.tickerAdded = false;\n };\n /** Registers all the DOM events. */\n InteractionManager.prototype.addEvents = function () {\n if (this.eventsAdded || !this.interactionDOMElement) {\n return;\n }\n var style = this.interactionDOMElement.style;\n if (globalThis.navigator.msPointerEnabled) {\n style.msContentZooming = 'none';\n style.msTouchAction = 'none';\n }\n else if (this.supportsPointerEvents) {\n style.touchAction = 'none';\n }\n /*\n * These events are added first, so that if pointer events are normalized, they are fired\n * in the same order as non-normalized events. ie. pointer event 1st, mouse / touch 2nd\n */\n if (this.supportsPointerEvents) {\n globalThis.document.addEventListener('pointermove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('pointerdown', this.onPointerDown, this._eventListenerOptions);\n // pointerout is fired in addition to pointerup (for touch events) and pointercancel\n // we already handle those, so for the purposes of what we do in onPointerOut, we only\n // care about the pointerleave event\n this.interactionDOMElement.addEventListener('pointerleave', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('pointerover', this.onPointerOver, this._eventListenerOptions);\n globalThis.addEventListener('pointercancel', this.onPointerCancel, this._eventListenerOptions);\n globalThis.addEventListener('pointerup', this.onPointerUp, this._eventListenerOptions);\n }\n else {\n globalThis.document.addEventListener('mousemove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('mousedown', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('mouseout', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('mouseover', this.onPointerOver, this._eventListenerOptions);\n globalThis.addEventListener('mouseup', this.onPointerUp, this._eventListenerOptions);\n }\n // always look directly for touch events so that we can provide original data\n // In a future version we should change this to being just a fallback and rely solely on\n // PointerEvents whenever available\n if (this.supportsTouchEvents) {\n this.interactionDOMElement.addEventListener('touchstart', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('touchcancel', this.onPointerCancel, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('touchend', this.onPointerUp, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('touchmove', this.onPointerMove, this._eventListenerOptions);\n }\n this.eventsAdded = true;\n };\n /** Removes all the DOM events that were previously registered. */\n InteractionManager.prototype.removeEvents = function () {\n if (!this.eventsAdded || !this.interactionDOMElement) {\n return;\n }\n var style = this.interactionDOMElement.style;\n if (globalThis.navigator.msPointerEnabled) {\n style.msContentZooming = '';\n style.msTouchAction = '';\n }\n else if (this.supportsPointerEvents) {\n style.touchAction = '';\n }\n if (this.supportsPointerEvents) {\n globalThis.document.removeEventListener('pointermove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('pointerdown', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('pointerleave', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('pointerover', this.onPointerOver, this._eventListenerOptions);\n globalThis.removeEventListener('pointercancel', this.onPointerCancel, this._eventListenerOptions);\n globalThis.removeEventListener('pointerup', this.onPointerUp, this._eventListenerOptions);\n }\n else {\n globalThis.document.removeEventListener('mousemove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('mousedown', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('mouseout', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('mouseover', this.onPointerOver, this._eventListenerOptions);\n globalThis.removeEventListener('mouseup', this.onPointerUp, this._eventListenerOptions);\n }\n if (this.supportsTouchEvents) {\n this.interactionDOMElement.removeEventListener('touchstart', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('touchcancel', this.onPointerCancel, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('touchend', this.onPointerUp, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('touchmove', this.onPointerMove, this._eventListenerOptions);\n }\n this.interactionDOMElement = null;\n this.eventsAdded = false;\n };\n /**\n * Updates the state of interactive objects if at least {@link interactionFrequency}\n * milliseconds have passed since the last invocation.\n *\n * Invoked by a throttled ticker update from {@link PIXI.Ticker.system}.\n *\n * @param deltaTime - time delta since the last call\n */\n InteractionManager.prototype.tickerUpdate = function (deltaTime) {\n this._deltaTime += deltaTime;\n if (this._deltaTime < this.interactionFrequency) {\n return;\n }\n this._deltaTime = 0;\n this.update();\n };\n /** Updates the state of interactive objects. */\n InteractionManager.prototype.update = function () {\n if (!this.interactionDOMElement) {\n return;\n }\n // if the user move the mouse this check has already been done using the mouse move!\n if (this._didMove) {\n this._didMove = false;\n return;\n }\n this.cursor = null;\n // Resets the flag as set by a stopPropagation call. This flag is usually reset by a user interaction of any kind,\n // but there was a scenario of a display object moving under a static mouse cursor.\n // In this case, mouseover and mouseevents would not pass the flag test in dispatchEvent function\n for (var k in this.activeInteractionData) {\n // eslint-disable-next-line no-prototype-builtins\n if (this.activeInteractionData.hasOwnProperty(k)) {\n var interactionData = this.activeInteractionData[k];\n if (interactionData.originalEvent && interactionData.pointerType !== 'touch') {\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, interactionData.originalEvent, interactionData);\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerOverOut, true);\n }\n }\n }\n this.setCursorMode(this.cursor);\n };\n /**\n * Sets the current cursor mode, handling any callbacks or CSS style changes.\n *\n * @param mode - cursor mode, a key from the cursorStyles dictionary\n */\n InteractionManager.prototype.setCursorMode = function (mode) {\n mode = mode || 'default';\n var applyStyles = true;\n // offscreen canvas does not support setting styles, but cursor modes can be functions,\n // in order to handle pixi rendered cursors, so we can't bail\n if (globalThis.OffscreenCanvas && this.interactionDOMElement instanceof OffscreenCanvas) {\n applyStyles = false;\n }\n // if the mode didn't actually change, bail early\n if (this.currentCursorMode === mode) {\n return;\n }\n this.currentCursorMode = mode;\n var style = this.cursorStyles[mode];\n // only do things if there is a cursor style for it\n if (style) {\n switch (typeof style) {\n case 'string':\n // string styles are handled as cursor CSS\n if (applyStyles) {\n this.interactionDOMElement.style.cursor = style;\n }\n break;\n case 'function':\n // functions are just called, and passed the cursor mode\n style(mode);\n break;\n case 'object':\n // if it is an object, assume that it is a dictionary of CSS styles,\n // apply it to the interactionDOMElement\n if (applyStyles) {\n Object.assign(this.interactionDOMElement.style, style);\n }\n break;\n }\n }\n else if (applyStyles && typeof mode === 'string' && !Object.prototype.hasOwnProperty.call(this.cursorStyles, mode)) {\n // if it mode is a string (not a Symbol) and cursorStyles doesn't have any entry\n // for the mode, then assume that the dev wants it to be CSS for the cursor.\n this.interactionDOMElement.style.cursor = mode;\n }\n };\n /**\n * Dispatches an event on the display object that was interacted with.\n *\n * @param displayObject - the display object in question\n * @param eventString - the name of the event (e.g, mousedown)\n * @param eventData - the event data object\n */\n InteractionManager.prototype.dispatchEvent = function (displayObject, eventString, eventData) {\n // Even if the event was stopped, at least dispatch any remaining events\n // for the same display object.\n if (!eventData.stopPropagationHint || displayObject === eventData.stopsPropagatingAt) {\n eventData.currentTarget = displayObject;\n eventData.type = eventString;\n displayObject.emit(eventString, eventData);\n if (displayObject[eventString]) {\n displayObject[eventString](eventData);\n }\n }\n };\n /**\n * Puts a event on a queue to be dispatched later. This is used to guarantee correct\n * ordering of over/out events.\n *\n * @param displayObject - the display object in question\n * @param eventString - the name of the event (e.g, mousedown)\n * @param eventData - the event data object\n */\n InteractionManager.prototype.delayDispatchEvent = function (displayObject, eventString, eventData) {\n this.delayedEvents.push({ displayObject: displayObject, eventString: eventString, eventData: eventData });\n };\n /**\n * Maps x and y coords from a DOM object and maps them correctly to the PixiJS view. The\n * resulting value is stored in the point. This takes into account the fact that the DOM\n * element could be scaled and positioned anywhere on the screen.\n *\n * @param point - the point that the result will be stored in\n * @param x - the x coord of the position to map\n * @param y - the y coord of the position to map\n */\n InteractionManager.prototype.mapPositionToPoint = function (point, x, y) {\n var rect;\n // IE 11 fix\n if (!this.interactionDOMElement.parentElement) {\n rect = {\n x: 0,\n y: 0,\n width: this.interactionDOMElement.width,\n height: this.interactionDOMElement.height,\n left: 0,\n top: 0\n };\n }\n else {\n rect = this.interactionDOMElement.getBoundingClientRect();\n }\n var resolutionMultiplier = 1.0 / this.resolution;\n point.x = ((x - rect.left) * (this.interactionDOMElement.width / rect.width)) * resolutionMultiplier;\n point.y = ((y - rect.top) * (this.interactionDOMElement.height / rect.height)) * resolutionMultiplier;\n };\n /**\n * This function is provides a neat way of crawling through the scene graph and running a\n * specified function on all interactive objects it finds. It will also take care of hit\n * testing the interactive objects and passes the hit across in the function.\n *\n * @protected\n * @param interactionEvent - event containing the point that\n * is tested for collision\n * @param displayObject - the displayObject\n * that will be hit test (recursively crawls its children)\n * @param func - the function that will be called on each interactive object. The\n * interactionEvent, displayObject and hit will be passed to the function\n * @param hitTest - indicates whether we want to calculate hits\n * or just iterate through all interactive objects\n */\n InteractionManager.prototype.processInteractive = function (interactionEvent, displayObject, func, hitTest) {\n var hit = this.search.findHit(interactionEvent, displayObject, func, hitTest);\n var delayedEvents = this.delayedEvents;\n if (!delayedEvents.length) {\n return hit;\n }\n // Reset the propagation hint, because we start deeper in the tree again.\n interactionEvent.stopPropagationHint = false;\n var delayedLen = delayedEvents.length;\n this.delayedEvents = [];\n for (var i = 0; i < delayedLen; i++) {\n var _a = delayedEvents[i], displayObject_1 = _a.displayObject, eventString = _a.eventString, eventData = _a.eventData;\n // When we reach the object we wanted to stop propagating at,\n // set the propagation hint.\n if (eventData.stopsPropagatingAt === displayObject_1) {\n eventData.stopPropagationHint = true;\n }\n this.dispatchEvent(displayObject_1, eventString, eventData);\n }\n return hit;\n };\n /**\n * Is called when the pointer button is pressed down on the renderer element\n *\n * @param originalEvent - The DOM event of a pointer button being pressed down\n */\n InteractionManager.prototype.onPointerDown = function (originalEvent) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && originalEvent.pointerType === 'touch')\n { return; }\n var events = this.normalizeToPointerData(originalEvent);\n /*\n * No need to prevent default on natural pointer events, as there are no side effects\n * Normalized events, however, may have the double mousedown/touchstart issue on the native android browser,\n * so still need to be prevented.\n */\n // Guaranteed that there will be at least one event in events, and all events must have the same pointer type\n if (this.autoPreventDefault && events[0].isNormalized) {\n var cancelable = originalEvent.cancelable || !('cancelable' in originalEvent);\n if (cancelable) {\n originalEvent.preventDefault();\n }\n }\n var eventLen = events.length;\n for (var i = 0; i < eventLen; i++) {\n var event = events[i];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = originalEvent;\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerDown, true);\n this.emit('pointerdown', interactionEvent);\n if (event.pointerType === 'touch') {\n this.emit('touchstart', interactionEvent);\n }\n // emit a mouse event for \"pen\" pointers, the way a browser would emit a fallback event\n else if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n var isRightButton = event.button === 2;\n this.emit(isRightButton ? 'rightdown' : 'mousedown', this.eventData);\n }\n }\n };\n /**\n * Processes the result of the pointer down check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerDown = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n if (hit) {\n if (!displayObject.trackedPointers[id]) {\n displayObject.trackedPointers[id] = new InteractionTrackingData(id);\n }\n this.dispatchEvent(displayObject, 'pointerdown', interactionEvent);\n if (data.pointerType === 'touch') {\n this.dispatchEvent(displayObject, 'touchstart', interactionEvent);\n }\n else if (data.pointerType === 'mouse' || data.pointerType === 'pen') {\n var isRightButton = data.button === 2;\n if (isRightButton) {\n displayObject.trackedPointers[id].rightDown = true;\n }\n else {\n displayObject.trackedPointers[id].leftDown = true;\n }\n this.dispatchEvent(displayObject, isRightButton ? 'rightdown' : 'mousedown', interactionEvent);\n }\n }\n };\n /**\n * Is called when the pointer button is released on the renderer element\n *\n * @param originalEvent - The DOM event of a pointer button being released\n * @param cancelled - true if the pointer is cancelled\n * @param func - Function passed to {@link processInteractive}\n */\n InteractionManager.prototype.onPointerComplete = function (originalEvent, cancelled, func) {\n var events = this.normalizeToPointerData(originalEvent);\n var eventLen = events.length;\n // if the event wasn't targeting our canvas, then consider it to be pointerupoutside\n // in all cases (unless it was a pointercancel)\n var eventAppend = originalEvent.target !== this.interactionDOMElement ? 'outside' : '';\n for (var i = 0; i < eventLen; i++) {\n var event = events[i];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = originalEvent;\n // perform hit testing for events targeting our canvas or cancel events\n this.processInteractive(interactionEvent, this.lastObjectRendered, func, cancelled || !eventAppend);\n this.emit(cancelled ? 'pointercancel' : \"pointerup\" + eventAppend, interactionEvent);\n if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n var isRightButton = event.button === 2;\n this.emit(isRightButton ? \"rightup\" + eventAppend : \"mouseup\" + eventAppend, interactionEvent);\n }\n else if (event.pointerType === 'touch') {\n this.emit(cancelled ? 'touchcancel' : \"touchend\" + eventAppend, interactionEvent);\n this.releaseInteractionDataForPointerId(event.pointerId);\n }\n }\n };\n /**\n * Is called when the pointer button is cancelled\n *\n * @param event - The DOM event of a pointer button being released\n */\n InteractionManager.prototype.onPointerCancel = function (event) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && event.pointerType === 'touch')\n { return; }\n this.onPointerComplete(event, true, this.processPointerCancel);\n };\n /**\n * Processes the result of the pointer cancel check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n */\n InteractionManager.prototype.processPointerCancel = function (interactionEvent, displayObject) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n if (displayObject.trackedPointers[id] !== undefined) {\n delete displayObject.trackedPointers[id];\n this.dispatchEvent(displayObject, 'pointercancel', interactionEvent);\n if (data.pointerType === 'touch') {\n this.dispatchEvent(displayObject, 'touchcancel', interactionEvent);\n }\n }\n };\n /**\n * Is called when the pointer button is released on the renderer element\n *\n * @param event - The DOM event of a pointer button being released\n */\n InteractionManager.prototype.onPointerUp = function (event) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && event.pointerType === 'touch')\n { return; }\n this.onPointerComplete(event, false, this.processPointerUp);\n };\n /**\n * Processes the result of the pointer up check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerUp = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n var trackingData = displayObject.trackedPointers[id];\n var isTouch = data.pointerType === 'touch';\n var isMouse = (data.pointerType === 'mouse' || data.pointerType === 'pen');\n // need to track mouse down status in the mouse block so that we can emit\n // event in a later block\n var isMouseTap = false;\n // Mouse only\n if (isMouse) {\n var isRightButton = data.button === 2;\n var flags = InteractionTrackingData.FLAGS;\n var test = isRightButton ? flags.RIGHT_DOWN : flags.LEFT_DOWN;\n var isDown = trackingData !== undefined && (trackingData.flags & test);\n if (hit) {\n this.dispatchEvent(displayObject, isRightButton ? 'rightup' : 'mouseup', interactionEvent);\n if (isDown) {\n this.dispatchEvent(displayObject, isRightButton ? 'rightclick' : 'click', interactionEvent);\n // because we can confirm that the mousedown happened on this object, flag for later emit of pointertap\n isMouseTap = true;\n }\n }\n else if (isDown) {\n this.dispatchEvent(displayObject, isRightButton ? 'rightupoutside' : 'mouseupoutside', interactionEvent);\n }\n // update the down state of the tracking data\n if (trackingData) {\n if (isRightButton) {\n trackingData.rightDown = false;\n }\n else {\n trackingData.leftDown = false;\n }\n }\n }\n // Pointers and Touches, and Mouse\n if (hit) {\n this.dispatchEvent(displayObject, 'pointerup', interactionEvent);\n if (isTouch)\n { this.dispatchEvent(displayObject, 'touchend', interactionEvent); }\n if (trackingData) {\n // emit pointertap if not a mouse, or if the mouse block decided it was a tap\n if (!isMouse || isMouseTap) {\n this.dispatchEvent(displayObject, 'pointertap', interactionEvent);\n }\n if (isTouch) {\n this.dispatchEvent(displayObject, 'tap', interactionEvent);\n // touches are no longer over (if they ever were) when we get the touchend\n // so we should ensure that we don't keep pretending that they are\n trackingData.over = false;\n }\n }\n }\n else if (trackingData) {\n this.dispatchEvent(displayObject, 'pointerupoutside', interactionEvent);\n if (isTouch)\n { this.dispatchEvent(displayObject, 'touchendoutside', interactionEvent); }\n }\n // Only remove the tracking data if there is no over/down state still associated with it\n if (trackingData && trackingData.none) {\n delete displayObject.trackedPointers[id];\n }\n };\n /**\n * Is called when the pointer moves across the renderer element\n *\n * @param originalEvent - The DOM event of a pointer moving\n */\n InteractionManager.prototype.onPointerMove = function (originalEvent) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && originalEvent.pointerType === 'touch')\n { return; }\n var events = this.normalizeToPointerData(originalEvent);\n if (events[0].pointerType === 'mouse' || events[0].pointerType === 'pen') {\n this._didMove = true;\n this.cursor = null;\n }\n var eventLen = events.length;\n for (var i = 0; i < eventLen; i++) {\n var event = events[i];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = originalEvent;\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerMove, true);\n this.emit('pointermove', interactionEvent);\n if (event.pointerType === 'touch')\n { this.emit('touchmove', interactionEvent); }\n if (event.pointerType === 'mouse' || event.pointerType === 'pen')\n { this.emit('mousemove', interactionEvent); }\n }\n if (events[0].pointerType === 'mouse') {\n this.setCursorMode(this.cursor);\n // TODO BUG for parents interactive object (border order issue)\n }\n };\n /**\n * Processes the result of the pointer move check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerMove = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var isTouch = data.pointerType === 'touch';\n var isMouse = (data.pointerType === 'mouse' || data.pointerType === 'pen');\n if (isMouse) {\n this.processPointerOverOut(interactionEvent, displayObject, hit);\n }\n if (!this.moveWhenInside || hit) {\n this.dispatchEvent(displayObject, 'pointermove', interactionEvent);\n if (isTouch)\n { this.dispatchEvent(displayObject, 'touchmove', interactionEvent); }\n if (isMouse)\n { this.dispatchEvent(displayObject, 'mousemove', interactionEvent); }\n }\n };\n /**\n * Is called when the pointer is moved out of the renderer element\n *\n * @private\n * @param {PointerEvent} originalEvent - The DOM event of a pointer being moved out\n */\n InteractionManager.prototype.onPointerOut = function (originalEvent) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && originalEvent.pointerType === 'touch')\n { return; }\n var events = this.normalizeToPointerData(originalEvent);\n // Only mouse and pointer can call onPointerOut, so events will always be length 1\n var event = events[0];\n if (event.pointerType === 'mouse') {\n this.mouseOverRenderer = false;\n this.setCursorMode(null);\n }\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = event;\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerOverOut, false);\n this.emit('pointerout', interactionEvent);\n if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n this.emit('mouseout', interactionEvent);\n }\n else {\n // we can get touchleave events after touchend, so we want to make sure we don't\n // introduce memory leaks\n this.releaseInteractionDataForPointerId(interactionData.identifier);\n }\n };\n /**\n * Processes the result of the pointer over/out check and dispatches the event if need be.\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerOverOut = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n var isMouse = (data.pointerType === 'mouse' || data.pointerType === 'pen');\n var trackingData = displayObject.trackedPointers[id];\n // if we just moused over the display object, then we need to track that state\n if (hit && !trackingData) {\n trackingData = displayObject.trackedPointers[id] = new InteractionTrackingData(id);\n }\n if (trackingData === undefined)\n { return; }\n if (hit && this.mouseOverRenderer) {\n if (!trackingData.over) {\n trackingData.over = true;\n this.delayDispatchEvent(displayObject, 'pointerover', interactionEvent);\n if (isMouse) {\n this.delayDispatchEvent(displayObject, 'mouseover', interactionEvent);\n }\n }\n // only change the cursor if it has not already been changed (by something deeper in the\n // display tree)\n if (isMouse && this.cursor === null) {\n this.cursor = displayObject.cursor;\n }\n }\n else if (trackingData.over) {\n trackingData.over = false;\n this.dispatchEvent(displayObject, 'pointerout', this.eventData);\n if (isMouse) {\n this.dispatchEvent(displayObject, 'mouseout', interactionEvent);\n }\n // if there is no mouse down information for the pointer, then it is safe to delete\n if (trackingData.none) {\n delete displayObject.trackedPointers[id];\n }\n }\n };\n /**\n * Is called when the pointer is moved into the renderer element.\n *\n * @param originalEvent - The DOM event of a pointer button being moved into the renderer view.\n */\n InteractionManager.prototype.onPointerOver = function (originalEvent) {\n var events = this.normalizeToPointerData(originalEvent);\n // Only mouse and pointer can call onPointerOver, so events will always be length 1\n var event = events[0];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = event;\n if (event.pointerType === 'mouse') {\n this.mouseOverRenderer = true;\n }\n this.emit('pointerover', interactionEvent);\n if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n this.emit('mouseover', interactionEvent);\n }\n };\n /**\n * Get InteractionData for a given pointerId. Store that data as well.\n *\n * @param event - Normalized pointer event, output from normalizeToPointerData.\n * @return - Interaction data for the given pointer identifier.\n */\n InteractionManager.prototype.getInteractionDataForPointerId = function (event) {\n var pointerId = event.pointerId;\n var interactionData;\n if (pointerId === MOUSE_POINTER_ID || event.pointerType === 'mouse') {\n interactionData = this.mouse;\n }\n else if (this.activeInteractionData[pointerId]) {\n interactionData = this.activeInteractionData[pointerId];\n }\n else {\n interactionData = this.interactionDataPool.pop() || new InteractionData();\n interactionData.identifier = pointerId;\n this.activeInteractionData[pointerId] = interactionData;\n }\n // copy properties from the event, so that we can make sure that touch/pointer specific\n // data is available\n interactionData.copyEvent(event);\n return interactionData;\n };\n /**\n * Return unused InteractionData to the pool, for a given pointerId\n *\n * @param pointerId - Identifier from a pointer event\n */\n InteractionManager.prototype.releaseInteractionDataForPointerId = function (pointerId) {\n var interactionData = this.activeInteractionData[pointerId];\n if (interactionData) {\n delete this.activeInteractionData[pointerId];\n interactionData.reset();\n this.interactionDataPool.push(interactionData);\n }\n };\n /**\n * Configure an InteractionEvent to wrap a DOM PointerEvent and InteractionData\n *\n * @param interactionEvent - The event to be configured\n * @param pointerEvent - The DOM event that will be paired with the InteractionEvent\n * @param interactionData - The InteractionData that will be paired\n * with the InteractionEvent\n * @return - the interaction event that was passed in\n */\n InteractionManager.prototype.configureInteractionEventForDOMEvent = function (interactionEvent, pointerEvent, interactionData) {\n interactionEvent.data = interactionData;\n this.mapPositionToPoint(interactionData.global, pointerEvent.clientX, pointerEvent.clientY);\n // Not really sure why this is happening, but it's how a previous version handled things\n if (pointerEvent.pointerType === 'touch') {\n pointerEvent.globalX = interactionData.global.x;\n pointerEvent.globalY = interactionData.global.y;\n }\n interactionData.originalEvent = pointerEvent;\n interactionEvent.reset();\n return interactionEvent;\n };\n /**\n * Ensures that the original event object contains all data that a regular pointer event would have\n *\n * @param {TouchEvent|MouseEvent|PointerEvent} event - The original event data from a touch or mouse event\n * @return - An array containing a single normalized pointer event, in the case of a pointer\n * or mouse event, or a multiple normalized pointer events if there are multiple changed touches\n */\n InteractionManager.prototype.normalizeToPointerData = function (event) {\n var normalizedEvents = [];\n if (this.supportsTouchEvents && event instanceof TouchEvent) {\n for (var i = 0, li = event.changedTouches.length; i < li; i++) {\n var touch = event.changedTouches[i];\n if (typeof touch.button === 'undefined')\n { touch.button = event.touches.length ? 1 : 0; }\n if (typeof touch.buttons === 'undefined')\n { touch.buttons = event.touches.length ? 1 : 0; }\n if (typeof touch.isPrimary === 'undefined') {\n touch.isPrimary = event.touches.length === 1 && event.type === 'touchstart';\n }\n if (typeof touch.width === 'undefined')\n { touch.width = touch.radiusX || 1; }\n if (typeof touch.height === 'undefined')\n { touch.height = touch.radiusY || 1; }\n if (typeof touch.tiltX === 'undefined')\n { touch.tiltX = 0; }\n if (typeof touch.tiltY === 'undefined')\n { touch.tiltY = 0; }\n if (typeof touch.pointerType === 'undefined')\n { touch.pointerType = 'touch'; }\n if (typeof touch.pointerId === 'undefined')\n { touch.pointerId = touch.identifier || 0; }\n if (typeof touch.pressure === 'undefined')\n { touch.pressure = touch.force || 0.5; }\n if (typeof touch.twist === 'undefined')\n { touch.twist = 0; }\n if (typeof touch.tangentialPressure === 'undefined')\n { touch.tangentialPressure = 0; }\n // TODO: Remove these, as layerX/Y is not a standard, is deprecated, has uneven\n // support, and the fill ins are not quite the same\n // offsetX/Y might be okay, but is not the same as clientX/Y when the canvas's top\n // left is not 0,0 on the page\n if (typeof touch.layerX === 'undefined')\n { touch.layerX = touch.offsetX = touch.clientX; }\n if (typeof touch.layerY === 'undefined')\n { touch.layerY = touch.offsetY = touch.clientY; }\n // mark the touch as normalized, just so that we know we did it\n touch.isNormalized = true;\n normalizedEvents.push(touch);\n }\n }\n // apparently PointerEvent subclasses MouseEvent, so yay\n else if (!globalThis.MouseEvent\n || (event instanceof MouseEvent && (!this.supportsPointerEvents || !(event instanceof globalThis.PointerEvent)))) {\n var tempEvent = event;\n if (typeof tempEvent.isPrimary === 'undefined')\n { tempEvent.isPrimary = true; }\n if (typeof tempEvent.width === 'undefined')\n { tempEvent.width = 1; }\n if (typeof tempEvent.height === 'undefined')\n { tempEvent.height = 1; }\n if (typeof tempEvent.tiltX === 'undefined')\n { tempEvent.tiltX = 0; }\n if (typeof tempEvent.tiltY === 'undefined')\n { tempEvent.tiltY = 0; }\n if (typeof tempEvent.pointerType === 'undefined')\n { tempEvent.pointerType = 'mouse'; }\n if (typeof tempEvent.pointerId === 'undefined')\n { tempEvent.pointerId = MOUSE_POINTER_ID; }\n if (typeof tempEvent.pressure === 'undefined')\n { tempEvent.pressure = 0.5; }\n if (typeof tempEvent.twist === 'undefined')\n { tempEvent.twist = 0; }\n if (typeof tempEvent.tangentialPressure === 'undefined')\n { tempEvent.tangentialPressure = 0; }\n // mark the mouse event as normalized, just so that we know we did it\n tempEvent.isNormalized = true;\n normalizedEvents.push(tempEvent);\n }\n else {\n normalizedEvents.push(event);\n }\n return normalizedEvents;\n };\n /** Destroys the interaction manager. */\n InteractionManager.prototype.destroy = function () {\n this.removeEvents();\n this.removeTickerListener();\n this.removeAllListeners();\n this.renderer = null;\n this.mouse = null;\n this.eventData = null;\n this.interactionDOMElement = null;\n this.onPointerDown = null;\n this.processPointerDown = null;\n this.onPointerUp = null;\n this.processPointerUp = null;\n this.onPointerCancel = null;\n this.processPointerCancel = null;\n this.onPointerMove = null;\n this.processPointerMove = null;\n this.onPointerOut = null;\n this.processPointerOverOut = null;\n this.onPointerOver = null;\n this.search = null;\n };\n return InteractionManager;\n}(EventEmitter));\n\nexport { InteractionData, InteractionEvent, InteractionManager, InteractionTrackingData, interactiveTarget };\n//# sourceMappingURL=interaction.js.map\n","/*!\n * @pixi/app - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/app is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Container } from '@pixi/display';\nimport { autoDetectRenderer } from '@pixi/core';\n\n/**\n * Convenience class to create a new PIXI application.\n *\n * This class automatically creates the renderer, ticker and root container.\n *\n * @example\n * // Create the application\n * const app = new PIXI.Application();\n *\n * // Add the view to the DOM\n * document.body.appendChild(app.view);\n *\n * // ex, add display objects\n * app.stage.addChild(PIXI.Sprite.from('something.png'));\n *\n * @class\n * @memberof PIXI\n */\nvar Application = /** @class */ (function () {\n /**\n * @param {object} [options] - The optional renderer parameters.\n * @param {boolean} [options.autoStart=true] - Automatically starts the rendering after the construction.\n * **Note**: Setting this parameter to false does NOT stop the shared ticker even if you set\n * options.sharedTicker to true in case that it is already started. Stop it by your own.\n * @param {number} [options.width=800] - The width of the renderers view.\n * @param {number} [options.height=600] - The height of the renderers view.\n * @param {HTMLCanvasElement} [options.view] - The canvas to use as a view, optional.\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1.\n * @param {boolean} [options.antialias=false] - Sets antialias\n * @param {boolean} [options.preserveDrawingBuffer=false] - Enables drawing buffer preservation, enable this if you\n * need to call toDataUrl on the WebGL context.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.forceCanvas=false] - prevents selection of WebGL renderer, even if such is present, this\n * option only is available when using **pixi.js-legacy** or **@pixi/canvas-renderer** modules, otherwise\n * it is ignored.\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear the canvas or\n * not before the new render pass.\n * @param {string} [options.powerPreference] - Parameter passed to webgl context, set to \"high-performance\"\n * for devices with dual graphics card. **(WebGL only)**.\n * @param {boolean} [options.sharedTicker=false] - `true` to use PIXI.Ticker.shared, `false` to create new ticker.\n * If set to false, you cannot register a handler to occur before anything that runs on the shared ticker.\n * The system ticker will always run before both the shared ticker and the app ticker.\n * @param {boolean} [options.sharedLoader=false] - `true` to use PIXI.Loader.shared, `false` to create new Loader.\n * @param {Window|HTMLElement} [options.resizeTo] - Element to automatically resize stage to.\n */\n function Application(options) {\n var _this = this;\n /**\n * The root display container that's rendered.\n * @member {PIXI.Container}\n */\n this.stage = new Container();\n // The default options\n options = Object.assign({\n forceCanvas: false,\n }, options);\n this.renderer = autoDetectRenderer(options);\n // install plugins here\n Application._plugins.forEach(function (plugin) {\n plugin.init.call(_this, options);\n });\n }\n /**\n * Register a middleware plugin for the application\n * @static\n * @param {PIXI.IApplicationPlugin} plugin - Plugin being installed\n */\n Application.registerPlugin = function (plugin) {\n Application._plugins.push(plugin);\n };\n /**\n * Render the current stage.\n */\n Application.prototype.render = function () {\n this.renderer.render(this.stage);\n };\n Object.defineProperty(Application.prototype, \"view\", {\n /**\n * Reference to the renderer's canvas element.\n * @member {HTMLCanvasElement}\n * @readonly\n */\n get: function () {\n return this.renderer.view;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Application.prototype, \"screen\", {\n /**\n * Reference to the renderer's screen rectangle. Its safe to use as `filterArea` or `hitArea` for the whole screen.\n * @member {PIXI.Rectangle}\n * @readonly\n */\n get: function () {\n return this.renderer.screen;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Destroy and don't use after this.\n * @param {Boolean} [removeView=false] - Automatically remove canvas from DOM.\n * @param {object|boolean} [stageOptions] - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [stageOptions.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'stageOptions' will be passed on to those calls.\n * @param {boolean} [stageOptions.texture=false] - Only used for child Sprites if stageOptions.children is set\n * to true. Should it destroy the texture of the child sprite\n * @param {boolean} [stageOptions.baseTexture=false] - Only used for child Sprites if stageOptions.children is set\n * to true. Should it destroy the base texture of the child sprite\n */\n Application.prototype.destroy = function (removeView, stageOptions) {\n var _this = this;\n // Destroy plugins in the opposite order\n // which they were constructed\n var plugins = Application._plugins.slice(0);\n plugins.reverse();\n plugins.forEach(function (plugin) {\n plugin.destroy.call(_this);\n });\n this.stage.destroy(stageOptions);\n this.stage = null;\n this.renderer.destroy(removeView);\n this.renderer = null;\n };\n /** Collection of installed plugins. */\n Application._plugins = [];\n return Application;\n}());\n\n/**\n * Middleware for for Application's resize functionality\n * @private\n * @class\n */\nvar ResizePlugin = /** @class */ (function () {\n function ResizePlugin() {\n }\n /**\n * Initialize the plugin with scope of application instance\n * @static\n * @private\n * @param {object} [options] - See application options\n */\n ResizePlugin.init = function (options) {\n var _this = this;\n Object.defineProperty(this, 'resizeTo', \n /**\n * The HTML element or window to automatically resize the\n * renderer's view element to match width and height.\n * @member {Window|HTMLElement}\n * @name resizeTo\n * @memberof PIXI.Application#\n */\n {\n set: function (dom) {\n globalThis.removeEventListener('resize', this.queueResize);\n this._resizeTo = dom;\n if (dom) {\n globalThis.addEventListener('resize', this.queueResize);\n this.resize();\n }\n },\n get: function () {\n return this._resizeTo;\n },\n });\n /**\n * Resize is throttled, so it's safe to call this multiple times per frame and it'll\n * only be called once.\n *\n * @memberof PIXI.Application#\n * @method queueResize\n * @private\n */\n this.queueResize = function () {\n if (!_this._resizeTo) {\n return;\n }\n _this.cancelResize();\n // // Throttle resize events per raf\n _this._resizeId = requestAnimationFrame(function () { return _this.resize(); });\n };\n /**\n * Cancel the resize queue.\n *\n * @memberof PIXI.Application#\n * @method cancelResize\n * @private\n */\n this.cancelResize = function () {\n if (_this._resizeId) {\n cancelAnimationFrame(_this._resizeId);\n _this._resizeId = null;\n }\n };\n /**\n * Execute an immediate resize on the renderer, this is not\n * throttled and can be expensive to call many times in a row.\n * Will resize only if `resizeTo` property is set.\n *\n * @memberof PIXI.Application#\n * @method resize\n */\n this.resize = function () {\n if (!_this._resizeTo) {\n return;\n }\n // clear queue resize\n _this.cancelResize();\n var width;\n var height;\n // Resize to the window\n if (_this._resizeTo === globalThis.window) {\n width = globalThis.innerWidth;\n height = globalThis.innerHeight;\n }\n // Resize to other HTML entities\n else {\n var _a = _this._resizeTo, clientWidth = _a.clientWidth, clientHeight = _a.clientHeight;\n width = clientWidth;\n height = clientHeight;\n }\n _this.renderer.resize(width, height);\n };\n // On resize\n this._resizeId = null;\n this._resizeTo = null;\n this.resizeTo = options.resizeTo || null;\n };\n /**\n * Clean up the ticker, scoped to application\n *\n * @static\n * @private\n */\n ResizePlugin.destroy = function () {\n globalThis.removeEventListener('resize', this.queueResize);\n this.cancelResize();\n this.cancelResize = null;\n this.queueResize = null;\n this.resizeTo = null;\n this.resize = null;\n };\n return ResizePlugin;\n}());\n\nApplication.registerPlugin(ResizePlugin);\n\nexport { Application };\n//# sourceMappingURL=app.js.map\n","/*!\n * @pixi/extract - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/extract is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { CanvasRenderTarget } from '@pixi/utils';\nimport { Rectangle } from '@pixi/math';\nimport { RenderTexture } from '@pixi/core';\n\nvar TEMP_RECT = new Rectangle();\nvar BYTES_PER_PIXEL = 4;\n/**\n * This class provides renderer-specific plugins for exporting content from a renderer.\n * For instance, these plugins can be used for saving an Image, Canvas element or for exporting the raw image data (pixels).\n *\n * Do not instantiate these plugins directly. It is available from the `renderer.plugins` property.\n * See {@link PIXI.CanvasRenderer#plugins} or {@link PIXI.Renderer#plugins}.\n *\n * @example\n * // Create a new app (will auto-add extract plugin to renderer)\n * const app = new PIXI.Application();\n *\n * // Draw a red circle\n * const graphics = new PIXI.Graphics()\n * .beginFill(0xFF0000)\n * .drawCircle(0, 0, 50);\n *\n * // Render the graphics as an HTMLImageElement\n * const image = app.renderer.plugins.extract.image(graphics);\n * document.body.appendChild(image);\n *\n * @memberof PIXI\n */\nvar Extract = /** @class */ (function () {\n /**\n * @param renderer - A reference to the current renderer\n */\n function Extract(renderer) {\n this.renderer = renderer;\n }\n /**\n * Will return a HTML Image of the target\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @param format - Image format, e.g. \"image/jpeg\" or \"image/webp\".\n * @param quality - JPEG or Webp compression from 0 to 1. Default is 0.92.\n * @return - HTML Image of the target\n */\n Extract.prototype.image = function (target, format, quality) {\n var image = new Image();\n image.src = this.base64(target, format, quality);\n return image;\n };\n /**\n * Will return a base64 encoded string of this target. It works by calling\n * `Extract.getCanvas` and then running toDataURL on that.\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @param format - Image format, e.g. \"image/jpeg\" or \"image/webp\".\n * @param quality - JPEG or Webp compression from 0 to 1. Default is 0.92.\n * @return - A base64 encoded string of the texture.\n */\n Extract.prototype.base64 = function (target, format, quality) {\n return this.canvas(target).toDataURL(format, quality);\n };\n /**\n * Creates a Canvas element, renders this target to it and then returns it.\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @return - A Canvas element with the texture rendered on.\n */\n Extract.prototype.canvas = function (target) {\n var renderer = this.renderer;\n var resolution;\n var frame;\n var flipY = false;\n var renderTexture;\n var generated = false;\n if (target) {\n if (target instanceof RenderTexture) {\n renderTexture = target;\n }\n else {\n renderTexture = this.renderer.generateTexture(target);\n generated = true;\n }\n }\n if (renderTexture) {\n resolution = renderTexture.baseTexture.resolution;\n frame = renderTexture.frame;\n flipY = false;\n renderer.renderTexture.bind(renderTexture);\n }\n else {\n resolution = this.renderer.resolution;\n flipY = true;\n frame = TEMP_RECT;\n frame.width = this.renderer.width;\n frame.height = this.renderer.height;\n renderer.renderTexture.bind(null);\n }\n var width = Math.floor((frame.width * resolution) + 1e-4);\n var height = Math.floor((frame.height * resolution) + 1e-4);\n var canvasBuffer = new CanvasRenderTarget(width, height, 1);\n var webglPixels = new Uint8Array(BYTES_PER_PIXEL * width * height);\n // read pixels to the array\n var gl = renderer.gl;\n gl.readPixels(frame.x * resolution, frame.y * resolution, width, height, gl.RGBA, gl.UNSIGNED_BYTE, webglPixels);\n // add the pixels to the canvas\n var canvasData = canvasBuffer.context.getImageData(0, 0, width, height);\n Extract.arrayPostDivide(webglPixels, canvasData.data);\n canvasBuffer.context.putImageData(canvasData, 0, 0);\n // pulling pixels\n if (flipY) {\n var target_1 = new CanvasRenderTarget(canvasBuffer.width, canvasBuffer.height, 1);\n target_1.context.scale(1, -1);\n // we can't render to itself because we should be empty before render.\n target_1.context.drawImage(canvasBuffer.canvas, 0, -height);\n canvasBuffer.destroy();\n canvasBuffer = target_1;\n }\n if (generated) {\n renderTexture.destroy(true);\n }\n // send the canvas back..\n return canvasBuffer.canvas;\n };\n /**\n * Will return a one-dimensional array containing the pixel data of the entire texture in RGBA\n * order, with integer values between 0 and 255 (included).\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @return - One-dimensional array containing the pixel data of the entire texture\n */\n Extract.prototype.pixels = function (target) {\n var renderer = this.renderer;\n var resolution;\n var frame;\n var renderTexture;\n var generated = false;\n if (target) {\n if (target instanceof RenderTexture) {\n renderTexture = target;\n }\n else {\n renderTexture = this.renderer.generateTexture(target);\n generated = true;\n }\n }\n if (renderTexture) {\n resolution = renderTexture.baseTexture.resolution;\n frame = renderTexture.frame;\n // bind the buffer\n renderer.renderTexture.bind(renderTexture);\n }\n else {\n resolution = renderer.resolution;\n frame = TEMP_RECT;\n frame.width = renderer.width;\n frame.height = renderer.height;\n renderer.renderTexture.bind(null);\n }\n var width = frame.width * resolution;\n var height = frame.height * resolution;\n var webglPixels = new Uint8Array(BYTES_PER_PIXEL * width * height);\n // read pixels to the array\n var gl = renderer.gl;\n gl.readPixels(frame.x * resolution, frame.y * resolution, width, height, gl.RGBA, gl.UNSIGNED_BYTE, webglPixels);\n if (generated) {\n renderTexture.destroy(true);\n }\n Extract.arrayPostDivide(webglPixels, webglPixels);\n return webglPixels;\n };\n /** Destroys the extract. */\n Extract.prototype.destroy = function () {\n this.renderer = null;\n };\n /**\n * Takes premultiplied pixel data and produces regular pixel data\n *\n * @private\n * @param pixels - array of pixel data\n * @param out - output array\n */\n Extract.arrayPostDivide = function (pixels, out) {\n for (var i = 0; i < pixels.length; i += 4) {\n var alpha = out[i + 3] = pixels[i + 3];\n if (alpha !== 0) {\n out[i] = Math.round(Math.min(pixels[i] * 255.0 / alpha, 255.0));\n out[i + 1] = Math.round(Math.min(pixels[i + 1] * 255.0 / alpha, 255.0));\n out[i + 2] = Math.round(Math.min(pixels[i + 2] * 255.0 / alpha, 255.0));\n }\n else {\n out[i] = pixels[i];\n out[i + 1] = pixels[i + 1];\n out[i + 2] = pixels[i + 2];\n }\n }\n };\n return Extract;\n}());\n\nexport { Extract };\n//# sourceMappingURL=extract.js.map\n","/*!\n * @pixi/loaders - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/loaders is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture } from '@pixi/core';\n\n/* jshint -W097 */\n/**\n * @memberof PIXI\n */\nvar SignalBinding = /** @class */ (function () {\n /**\n * SignalBinding constructor.\n * @constructs SignalBinding\n * @param {Function} fn - Event handler to be called.\n * @param {Boolean} [once=false] - Should this listener be removed after dispatch\n * @param {object} [thisArg] - The context of the callback function.\n * @api private\n */\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n function SignalBinding(fn, once, thisArg) {\n if (once === void 0) { once = false; }\n this._fn = fn;\n this._once = once;\n this._thisArg = thisArg;\n this._next = this._prev = this._owner = null;\n }\n SignalBinding.prototype.detach = function () {\n if (this._owner === null)\n { return false; }\n this._owner.detach(this);\n return true;\n };\n return SignalBinding;\n}());\n/**\n * @private\n */\nfunction _addSignalBinding(self, node) {\n if (!self._head) {\n self._head = node;\n self._tail = node;\n }\n else {\n self._tail._next = node;\n node._prev = self._tail;\n self._tail = node;\n }\n node._owner = self;\n return node;\n}\n/**\n * @memberof PIXI\n */\nvar Signal = /** @class */ (function () {\n /**\n * MiniSignal constructor.\n * @example\n * let mySignal = new Signal();\n * let binding = mySignal.add(onSignal);\n * mySignal.dispatch('foo', 'bar');\n * mySignal.detach(binding);\n */\n function Signal() {\n this._head = this._tail = undefined;\n }\n /**\n * Return an array of attached SignalBinding.\n *\n * @param {Boolean} [exists=false] - We only need to know if there are handlers.\n * @returns {PIXI.SignalBinding[]|Boolean} Array of attached SignalBinding or Boolean if called with exists = true\n * @api public\n */\n Signal.prototype.handlers = function (exists) {\n if (exists === void 0) { exists = false; }\n var node = this._head;\n if (exists)\n { return !!node; }\n var ee = [];\n while (node) {\n ee.push(node);\n node = node._next;\n }\n return ee;\n };\n /**\n * Return true if node is a SignalBinding attached to this MiniSignal\n *\n * @param {PIXI.SignalBinding} node - Node to check.\n * @returns {Boolean} True if node is attache to mini-signal\n */\n Signal.prototype.has = function (node) {\n if (!(node instanceof SignalBinding)) {\n throw new Error('MiniSignal#has(): First arg must be a SignalBinding object.');\n }\n return node._owner === this;\n };\n /**\n * Dispaches a signal to all registered listeners.\n *\n * @returns {Boolean} Indication if we've emitted an event.\n */\n Signal.prototype.dispatch = function () {\n var arguments$1 = arguments;\n\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments$1[_i];\n }\n var node = this._head;\n if (!node)\n { return false; }\n while (node) {\n if (node._once)\n { this.detach(node); }\n node._fn.apply(node._thisArg, args);\n node = node._next;\n }\n return true;\n };\n /**\n * Register a new listener.\n *\n * @param {Function} fn - Callback function.\n * @param {object} [thisArg] - The context of the callback function.\n * @returns {PIXI.SignalBinding} The SignalBinding node that was added.\n */\n Signal.prototype.add = function (fn, thisArg) {\n if (thisArg === void 0) { thisArg = null; }\n if (typeof fn !== 'function') {\n throw new Error('MiniSignal#add(): First arg must be a Function.');\n }\n return _addSignalBinding(this, new SignalBinding(fn, false, thisArg));\n };\n /**\n * Register a new listener that will be executed only once.\n *\n * @param {Function} fn - Callback function.\n * @param {object} [thisArg] - The context of the callback function.\n * @returns {PIXI.SignalBinding} The SignalBinding node that was added.\n */\n Signal.prototype.once = function (fn, thisArg) {\n if (thisArg === void 0) { thisArg = null; }\n if (typeof fn !== 'function') {\n throw new Error('MiniSignal#once(): First arg must be a Function.');\n }\n return _addSignalBinding(this, new SignalBinding(fn, true, thisArg));\n };\n /**\n * Remove binding object.\n *\n * @param {PIXI.SignalBinding} node - The binding node that will be removed.\n * @returns {Signal} The instance on which this method was called.\n * @api public */\n Signal.prototype.detach = function (node) {\n if (!(node instanceof SignalBinding)) {\n throw new Error('MiniSignal#detach(): First arg must be a SignalBinding object.');\n }\n if (node._owner !== this)\n { return this; } // todo: or error?\n if (node._prev)\n { node._prev._next = node._next; }\n if (node._next)\n { node._next._prev = node._prev; }\n if (node === this._head) { // first node\n this._head = node._next;\n if (node._next === null) {\n this._tail = null;\n }\n }\n else if (node === this._tail) { // last node\n this._tail = node._prev;\n this._tail._next = null;\n }\n node._owner = null;\n return this;\n };\n /**\n * Detach all listeners.\n *\n * @returns {Signal} The instance on which this method was called.\n */\n Signal.prototype.detachAll = function () {\n var node = this._head;\n if (!node)\n { return this; }\n this._head = this._tail = null;\n while (node) {\n node._owner = null;\n node = node._next;\n }\n return this;\n };\n return Signal;\n}());\n\n/**\n * function from npm package `parseUri`, converted to TS to avoid leftpad incident\n * @param {string} str\n * @param [opts] - options\n * @param {boolean} [opts.strictMode] - type of parser\n */\nfunction parseUri(str, opts) {\n opts = opts || {};\n var o = {\n // eslint-disable-next-line max-len\n key: ['source', 'protocol', 'authority', 'userInfo', 'user', 'password', 'host', 'port', 'relative', 'path', 'directory', 'file', 'query', 'anchor'],\n q: {\n name: 'queryKey',\n parser: /(?:^|&)([^&=]*)=?([^&]*)/g\n },\n parser: {\n // eslint-disable-next-line max-len\n strict: /^(?:([^:\\/?#]+):)?(?:\\/\\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\\/?#]*)(?::(\\d*))?))?((((?:[^?#\\/]*\\/)*)([^?#]*))(?:\\?([^#]*))?(?:#(.*))?)/,\n // eslint-disable-next-line max-len\n loose: /^(?:(?![^:@]+:[^:@\\/]*@)([^:\\/?#.]+):)?(?:\\/\\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\\/?#]*)(?::(\\d*))?)(((\\/(?:[^?#](?![^?#\\/]*\\.[^?#\\/.]+(?:[?#]|$)))*\\/?)?([^?#\\/]*))(?:\\?([^#]*))?(?:#(.*))?)/\n }\n };\n var m = o.parser[opts.strictMode ? 'strict' : 'loose'].exec(str);\n var uri = {};\n var i = 14;\n while (i--)\n { uri[o.key[i]] = m[i] || ''; }\n uri[o.q.name] = {};\n uri[o.key[12]].replace(o.q.parser, function (_t0, t1, t2) {\n if (t1)\n { uri[o.q.name][t1] = t2; }\n });\n return uri;\n}\n\n// tests if CORS is supported in XHR, if not we need to use XDR\nvar useXdr = !!(globalThis.XDomainRequest && !('withCredentials' in (new XMLHttpRequest())));\nvar tempAnchor = null;\n// some status constants\nvar STATUS_NONE = 0;\nvar STATUS_OK = 200;\nvar STATUS_EMPTY = 204;\nvar STATUS_IE_BUG_EMPTY = 1223;\nvar STATUS_TYPE_OK = 2;\n// noop\nfunction _noop() { }\n/**\n * Quick helper to set a value on one of the extension maps. Ensures there is no\n * dot at the start of the extension.\n *\n * @ignore\n * @param map - The map to set on.\n * @param extname - The extension (or key) to set.\n * @param val - The value to set.\n */\nfunction setExtMap(map, extname, val) {\n if (extname && extname.indexOf('.') === 0) {\n extname = extname.substring(1);\n }\n if (!extname) {\n return;\n }\n map[extname] = val;\n}\n/**\n * Quick helper to get string xhr type.\n *\n * @ignore\n * @param xhr - The request to check.\n * @return The type.\n */\nfunction reqType(xhr) {\n return xhr.toString().replace('object ', '');\n}\n/**\n * Manages the state and loading of a resource and all child resources.\n *\n * Can be extended in `GlobalMixins.LoaderResource`.\n *\n * @memberof PIXI\n */\nvar LoaderResource = /** @class */ (function () {\n /**\n * @param {string} name - The name of the resource to load.\n * @param {string|string[]} url - The url for this resource, for audio/video loads you can pass\n * an array of sources.\n * @param {object} [options] - The options for the load.\n * @param {string|boolean} [options.crossOrigin] - Is this request cross-origin? Default is to\n * determine automatically.\n * @param {number} [options.timeout=0] - A timeout in milliseconds for the load. If the load takes\n * longer than this time it is cancelled and the load is considered a failure. If this value is\n * set to `0` then there is no explicit timeout.\n * @param {PIXI.LoaderResource.LOAD_TYPE} [options.loadType=LOAD_TYPE.XHR] - How should this resource\n * be loaded?\n * @param {PIXI.LoaderResource.XHR_RESPONSE_TYPE} [options.xhrType=XHR_RESPONSE_TYPE.DEFAULT] - How\n * should the data being loaded be interpreted when using XHR?\n * @param {PIXI.LoaderResource.IMetadata} [options.metadata] - Extra configuration for middleware\n * and the Resource object.\n */\n function LoaderResource(name, url, options) {\n /**\n * The `dequeue` method that will be used a storage place for the async queue dequeue method\n * used privately by the loader.\n *\n * @private\n * @member {function}\n */\n this._dequeue = _noop;\n /**\n * Used a storage place for the on load binding used privately by the loader.\n *\n * @private\n * @member {function}\n */\n this._onLoadBinding = null;\n /**\n * The timer for element loads to check if they timeout.\n *\n * @private\n */\n this._elementTimer = 0;\n /**\n * The `complete` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundComplete = null;\n /**\n * The `_onError` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundOnError = null;\n /**\n * The `_onProgress` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundOnProgress = null;\n /**\n * The `_onTimeout` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundOnTimeout = null;\n this._boundXhrOnError = null;\n this._boundXhrOnTimeout = null;\n this._boundXhrOnAbort = null;\n this._boundXhrOnLoad = null;\n if (typeof name !== 'string' || typeof url !== 'string') {\n throw new Error('Both name and url are required for constructing a resource.');\n }\n options = options || {};\n this._flags = 0;\n // set data url flag, needs to be set early for some _determineX checks to work.\n this._setFlag(LoaderResource.STATUS_FLAGS.DATA_URL, url.indexOf('data:') === 0);\n this.name = name;\n this.url = url;\n this.extension = this._getExtension();\n this.data = null;\n this.crossOrigin = options.crossOrigin === true ? 'anonymous' : options.crossOrigin;\n this.timeout = options.timeout || 0;\n this.loadType = options.loadType || this._determineLoadType();\n // The type used to load the resource via XHR. If unset, determined automatically.\n this.xhrType = options.xhrType;\n // Extra info for middleware, and controlling specifics about how the resource loads.\n // Note that if you pass in a `loadElement`, the Resource class takes ownership of it.\n // Meaning it will modify it as it sees fit.\n this.metadata = options.metadata || {};\n // The error that occurred while loading (if any).\n this.error = null;\n // The XHR object that was used to load this resource. This is only set\n // when `loadType` is `LoaderResource.LOAD_TYPE.XHR`.\n this.xhr = null;\n // The child resources this resource owns.\n this.children = [];\n // The resource type.\n this.type = LoaderResource.TYPE.UNKNOWN;\n // The progress chunk owned by this resource.\n this.progressChunk = 0;\n // The `dequeue` method that will be used a storage place for the async queue dequeue method\n // used privately by the loader.\n this._dequeue = _noop;\n // Used a storage place for the on load binding used privately by the loader.\n this._onLoadBinding = null;\n // The timer for element loads to check if they timeout.\n this._elementTimer = 0;\n this._boundComplete = this.complete.bind(this);\n this._boundOnError = this._onError.bind(this);\n this._boundOnProgress = this._onProgress.bind(this);\n this._boundOnTimeout = this._onTimeout.bind(this);\n // xhr callbacks\n this._boundXhrOnError = this._xhrOnError.bind(this);\n this._boundXhrOnTimeout = this._xhrOnTimeout.bind(this);\n this._boundXhrOnAbort = this._xhrOnAbort.bind(this);\n this._boundXhrOnLoad = this._xhrOnLoad.bind(this);\n // Dispatched when the resource beings to load.\n this.onStart = new Signal();\n // Dispatched each time progress of this resource load updates.\n // Not all resources types and loader systems can support this event\n // so sometimes it may not be available. If the resource\n // is being loaded on a modern browser, using XHR, and the remote server\n // properly sets Content-Length headers, then this will be available.\n this.onProgress = new Signal();\n // Dispatched once this resource has loaded, if there was an error it will\n // be in the `error` property.\n this.onComplete = new Signal();\n // Dispatched after this resource has had all the *after* middleware run on it.\n this.onAfterMiddleware = new Signal();\n }\n /**\n * Sets the load type to be used for a specific extension.\n *\n * @static\n * @param {string} extname - The extension to set the type for, e.g. \"png\" or \"fnt\"\n * @param {PIXI.LoaderResource.LOAD_TYPE} loadType - The load type to set it to.\n */\n LoaderResource.setExtensionLoadType = function (extname, loadType) {\n setExtMap(LoaderResource._loadTypeMap, extname, loadType);\n };\n /**\n * Sets the load type to be used for a specific extension.\n *\n * @static\n * @param {string} extname - The extension to set the type for, e.g. \"png\" or \"fnt\"\n * @param {PIXI.LoaderResource.XHR_RESPONSE_TYPE} xhrType - The xhr type to set it to.\n */\n LoaderResource.setExtensionXhrType = function (extname, xhrType) {\n setExtMap(LoaderResource._xhrTypeMap, extname, xhrType);\n };\n Object.defineProperty(LoaderResource.prototype, \"isDataUrl\", {\n /**\n * When the resource starts to load.\n *\n * @memberof PIXI.LoaderResource\n * @callback OnStartSignal\n * @param {Resource} resource - The resource that the event happened on.\n */\n /**\n * When the resource reports loading progress.\n *\n * @memberof PIXI.LoaderResource\n * @callback OnProgressSignal\n * @param {Resource} resource - The resource that the event happened on.\n * @param {number} percentage - The progress of the load in the range [0, 1].\n */\n /**\n * When the resource finishes loading.\n *\n * @memberof PIXI.LoaderResource\n * @callback OnCompleteSignal\n * @param {Resource} resource - The resource that the event happened on.\n */\n /**\n * @memberof PIXI.LoaderResource\n * @typedef {object} IMetadata\n * @property {HTMLImageElement|HTMLAudioElement|HTMLVideoElement} [loadElement=null] - The\n * element to use for loading, instead of creating one.\n * @property {boolean} [skipSource=false] - Skips adding source(s) to the load element. This\n * is useful if you want to pass in a `loadElement` that you already added load sources to.\n * @property {string|string[]} [mimeType] - The mime type to use for the source element\n * of a video/audio elment. If the urls are an array, you can pass this as an array as well\n * where each index is the mime type to use for the corresponding url index.\n */\n /**\n * Stores whether or not this url is a data url.\n *\n * @readonly\n * @member {boolean}\n */\n get: function () {\n return this._hasFlag(LoaderResource.STATUS_FLAGS.DATA_URL);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(LoaderResource.prototype, \"isComplete\", {\n /**\n * Describes if this resource has finished loading. Is true when the resource has completely\n * loaded.\n *\n * @readonly\n * @member {boolean}\n */\n get: function () {\n return this._hasFlag(LoaderResource.STATUS_FLAGS.COMPLETE);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(LoaderResource.prototype, \"isLoading\", {\n /**\n * Describes if this resource is currently loading. Is true when the resource starts loading,\n * and is false again when complete.\n *\n * @readonly\n * @member {boolean}\n */\n get: function () {\n return this._hasFlag(LoaderResource.STATUS_FLAGS.LOADING);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Marks the resource as complete.\n *\n */\n LoaderResource.prototype.complete = function () {\n this._clearEvents();\n this._finish();\n };\n /**\n * Aborts the loading of this resource, with an optional message.\n *\n * @param {string} message - The message to use for the error\n */\n LoaderResource.prototype.abort = function (message) {\n // abort can be called multiple times, ignore subsequent calls.\n if (this.error) {\n return;\n }\n // store error\n this.error = new Error(message);\n // clear events before calling aborts\n this._clearEvents();\n // abort the actual loading\n if (this.xhr) {\n this.xhr.abort();\n }\n else if (this.xdr) {\n this.xdr.abort();\n }\n else if (this.data) {\n // single source\n if (this.data.src) {\n this.data.src = LoaderResource.EMPTY_GIF;\n }\n // multi-source\n else {\n while (this.data.firstChild) {\n this.data.removeChild(this.data.firstChild);\n }\n }\n }\n // done now.\n this._finish();\n };\n /**\n * Kicks off loading of this resource. This method is asynchronous.\n *\n * @param {PIXI.LoaderResource.OnCompleteSignal} [cb] - Optional callback to call once the resource is loaded.\n */\n LoaderResource.prototype.load = function (cb) {\n var _this = this;\n if (this.isLoading) {\n return;\n }\n if (this.isComplete) {\n if (cb) {\n setTimeout(function () { return cb(_this); }, 1);\n }\n return;\n }\n else if (cb) {\n this.onComplete.once(cb);\n }\n this._setFlag(LoaderResource.STATUS_FLAGS.LOADING, true);\n this.onStart.dispatch(this);\n // if unset, determine the value\n if (this.crossOrigin === false || typeof this.crossOrigin !== 'string') {\n this.crossOrigin = this._determineCrossOrigin(this.url);\n }\n switch (this.loadType) {\n case LoaderResource.LOAD_TYPE.IMAGE:\n this.type = LoaderResource.TYPE.IMAGE;\n this._loadElement('image');\n break;\n case LoaderResource.LOAD_TYPE.AUDIO:\n this.type = LoaderResource.TYPE.AUDIO;\n this._loadSourceElement('audio');\n break;\n case LoaderResource.LOAD_TYPE.VIDEO:\n this.type = LoaderResource.TYPE.VIDEO;\n this._loadSourceElement('video');\n break;\n case LoaderResource.LOAD_TYPE.XHR:\n /* falls through */\n default:\n if (useXdr && this.crossOrigin) {\n this._loadXdr();\n }\n else {\n this._loadXhr();\n }\n break;\n }\n };\n /**\n * Checks if the flag is set.\n *\n * @param flag - The flag to check.\n * @return True if the flag is set.\n */\n LoaderResource.prototype._hasFlag = function (flag) {\n return (this._flags & flag) !== 0;\n };\n /**\n * (Un)Sets the flag.\n *\n * @param flag - The flag to (un)set.\n * @param value - Whether to set or (un)set the flag.\n */\n LoaderResource.prototype._setFlag = function (flag, value) {\n this._flags = value ? (this._flags | flag) : (this._flags & ~flag);\n };\n /**\n * Clears all the events from the underlying loading source.\n */\n LoaderResource.prototype._clearEvents = function () {\n clearTimeout(this._elementTimer);\n if (this.data && this.data.removeEventListener) {\n this.data.removeEventListener('error', this._boundOnError, false);\n this.data.removeEventListener('load', this._boundComplete, false);\n this.data.removeEventListener('progress', this._boundOnProgress, false);\n this.data.removeEventListener('canplaythrough', this._boundComplete, false);\n }\n if (this.xhr) {\n if (this.xhr.removeEventListener) {\n this.xhr.removeEventListener('error', this._boundXhrOnError, false);\n this.xhr.removeEventListener('timeout', this._boundXhrOnTimeout, false);\n this.xhr.removeEventListener('abort', this._boundXhrOnAbort, false);\n this.xhr.removeEventListener('progress', this._boundOnProgress, false);\n this.xhr.removeEventListener('load', this._boundXhrOnLoad, false);\n }\n else {\n this.xhr.onerror = null;\n this.xhr.ontimeout = null;\n this.xhr.onprogress = null;\n this.xhr.onload = null;\n }\n }\n };\n /**\n * Finalizes the load.\n */\n LoaderResource.prototype._finish = function () {\n if (this.isComplete) {\n throw new Error('Complete called again for an already completed resource.');\n }\n this._setFlag(LoaderResource.STATUS_FLAGS.COMPLETE, true);\n this._setFlag(LoaderResource.STATUS_FLAGS.LOADING, false);\n this.onComplete.dispatch(this);\n };\n /**\n * Loads this resources using an element that has a single source,\n * like an HTMLImageElement.\n * @private\n * @param type - The type of element to use.\n */\n LoaderResource.prototype._loadElement = function (type) {\n if (this.metadata.loadElement) {\n this.data = this.metadata.loadElement;\n }\n else if (type === 'image' && typeof globalThis.Image !== 'undefined') {\n this.data = new Image();\n }\n else {\n this.data = document.createElement(type);\n }\n if (this.crossOrigin) {\n this.data.crossOrigin = this.crossOrigin;\n }\n if (!this.metadata.skipSource) {\n this.data.src = this.url;\n }\n this.data.addEventListener('error', this._boundOnError, false);\n this.data.addEventListener('load', this._boundComplete, false);\n this.data.addEventListener('progress', this._boundOnProgress, false);\n if (this.timeout) {\n this._elementTimer = setTimeout(this._boundOnTimeout, this.timeout);\n }\n };\n /**\n * Loads this resources using an element that has multiple sources,\n * like an HTMLAudioElement or HTMLVideoElement.\n * @param type - The type of element to use.\n */\n LoaderResource.prototype._loadSourceElement = function (type) {\n if (this.metadata.loadElement) {\n this.data = this.metadata.loadElement;\n }\n else if (type === 'audio' && typeof globalThis.Audio !== 'undefined') {\n this.data = new Audio();\n }\n else {\n this.data = document.createElement(type);\n }\n if (this.data === null) {\n this.abort(\"Unsupported element: \" + type);\n return;\n }\n if (this.crossOrigin) {\n this.data.crossOrigin = this.crossOrigin;\n }\n if (!this.metadata.skipSource) {\n // support for CocoonJS Canvas+ runtime, lacks document.createElement('source')\n if (navigator.isCocoonJS) {\n this.data.src = Array.isArray(this.url) ? this.url[0] : this.url;\n }\n else if (Array.isArray(this.url)) {\n var mimeTypes = this.metadata.mimeType;\n for (var i = 0; i < this.url.length; ++i) {\n this.data.appendChild(this._createSource(type, this.url[i], Array.isArray(mimeTypes) ? mimeTypes[i] : mimeTypes));\n }\n }\n else {\n var mimeTypes = this.metadata.mimeType;\n this.data.appendChild(this._createSource(type, this.url, Array.isArray(mimeTypes) ? mimeTypes[0] : mimeTypes));\n }\n }\n this.data.addEventListener('error', this._boundOnError, false);\n this.data.addEventListener('load', this._boundComplete, false);\n this.data.addEventListener('progress', this._boundOnProgress, false);\n this.data.addEventListener('canplaythrough', this._boundComplete, false);\n this.data.load();\n if (this.timeout) {\n this._elementTimer = setTimeout(this._boundOnTimeout, this.timeout);\n }\n };\n /**\n * Loads this resources using an XMLHttpRequest.\n */\n LoaderResource.prototype._loadXhr = function () {\n // if unset, determine the value\n if (typeof this.xhrType !== 'string') {\n this.xhrType = this._determineXhrType();\n }\n var xhr = this.xhr = new XMLHttpRequest();\n // send credentials when crossOrigin with credentials requested\n if (this.crossOrigin === 'use-credentials') {\n xhr.withCredentials = true;\n }\n // set the request type and url\n xhr.open('GET', this.url, true);\n xhr.timeout = this.timeout;\n // load json as text and parse it ourselves. We do this because some browsers\n // *cough* safari *cough* can't deal with it.\n if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.JSON\n || this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT) {\n xhr.responseType = LoaderResource.XHR_RESPONSE_TYPE.TEXT;\n }\n else {\n xhr.responseType = this.xhrType;\n }\n xhr.addEventListener('error', this._boundXhrOnError, false);\n xhr.addEventListener('timeout', this._boundXhrOnTimeout, false);\n xhr.addEventListener('abort', this._boundXhrOnAbort, false);\n xhr.addEventListener('progress', this._boundOnProgress, false);\n xhr.addEventListener('load', this._boundXhrOnLoad, false);\n xhr.send();\n };\n /**\n * Loads this resources using an XDomainRequest. This is here because we need to support IE9 (gross).\n */\n LoaderResource.prototype._loadXdr = function () {\n // if unset, determine the value\n if (typeof this.xhrType !== 'string') {\n this.xhrType = this._determineXhrType();\n }\n var xdr = this.xhr = new globalThis.XDomainRequest(); // eslint-disable-line no-undef\n // XDomainRequest has a few quirks. Occasionally it will abort requests\n // A way to avoid this is to make sure ALL callbacks are set even if not used\n // More info here: http://stackoverflow.com/questions/15786966/xdomainrequest-aborts-post-on-ie-9\n xdr.timeout = this.timeout || 5000; // XDR needs a timeout value or it breaks in IE9\n xdr.onerror = this._boundXhrOnError;\n xdr.ontimeout = this._boundXhrOnTimeout;\n xdr.onprogress = this._boundOnProgress;\n xdr.onload = this._boundXhrOnLoad;\n xdr.open('GET', this.url, true);\n // Note: The xdr.send() call is wrapped in a timeout to prevent an\n // issue with the interface where some requests are lost if multiple\n // XDomainRequests are being sent at the same time.\n // Some info here: https://github.com/photonstorm/phaser/issues/1248\n setTimeout(function () { return xdr.send(); }, 1);\n };\n /**\n * Creates a source used in loading via an element.\n * @param type - The element type (video or audio).\n * @param url - The source URL to load from.\n * @param [mime] - The mime type of the video\n * @return The source element.\n */\n LoaderResource.prototype._createSource = function (type, url, mime) {\n if (!mime) {\n mime = type + \"/\" + this._getExtension(url);\n }\n var source = document.createElement('source');\n source.src = url;\n source.type = mime;\n return source;\n };\n /**\n * Called if a load errors out.\n *\n * @param event - The error event from the element that emits it.\n */\n LoaderResource.prototype._onError = function (event) {\n this.abort(\"Failed to load element using: \" + event.target.nodeName);\n };\n /**\n * Called if a load progress event fires for an element or xhr/xdr.\n * @param event - Progress event.\n */\n LoaderResource.prototype._onProgress = function (event) {\n if (event && event.lengthComputable) {\n this.onProgress.dispatch(this, event.loaded / event.total);\n }\n };\n /**\n * Called if a timeout event fires for an element.\n */\n LoaderResource.prototype._onTimeout = function () {\n this.abort(\"Load timed out.\");\n };\n /**\n * Called if an error event fires for xhr/xdr.\n */\n LoaderResource.prototype._xhrOnError = function () {\n var xhr = this.xhr;\n this.abort(reqType(xhr) + \" Request failed. Status: \" + xhr.status + \", text: \\\"\" + xhr.statusText + \"\\\"\");\n };\n /**\n * Called if an error event fires for xhr/xdr.\n */\n LoaderResource.prototype._xhrOnTimeout = function () {\n var xhr = this.xhr;\n this.abort(reqType(xhr) + \" Request timed out.\");\n };\n /**\n * Called if an abort event fires for xhr/xdr.\n */\n LoaderResource.prototype._xhrOnAbort = function () {\n var xhr = this.xhr;\n this.abort(reqType(xhr) + \" Request was aborted by the user.\");\n };\n /**\n * Called when data successfully loads from an xhr/xdr request.\n */\n LoaderResource.prototype._xhrOnLoad = function () {\n var xhr = this.xhr;\n var text = '';\n var status = typeof xhr.status === 'undefined' ? STATUS_OK : xhr.status; // XDR has no `.status`, assume 200.\n // responseText is accessible only if responseType is '' or 'text' and on older browsers\n if (xhr.responseType === '' || xhr.responseType === 'text' || typeof xhr.responseType === 'undefined') {\n text = xhr.responseText;\n }\n // status can be 0 when using the `file://` protocol so we also check if a response is set.\n // If it has a response, we assume 200; otherwise a 0 status code with no contents is an aborted request.\n if (status === STATUS_NONE && (text.length > 0 || xhr.responseType === LoaderResource.XHR_RESPONSE_TYPE.BUFFER)) {\n status = STATUS_OK;\n }\n // handle IE9 bug: http://stackoverflow.com/questions/10046972/msie-returns-status-code-of-1223-for-ajax-request\n else if (status === STATUS_IE_BUG_EMPTY) {\n status = STATUS_EMPTY;\n }\n var statusType = (status / 100) | 0;\n if (statusType === STATUS_TYPE_OK) {\n // if text, just return it\n if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.TEXT) {\n this.data = text;\n this.type = LoaderResource.TYPE.TEXT;\n }\n // if json, parse into json object\n else if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.JSON) {\n try {\n this.data = JSON.parse(text);\n this.type = LoaderResource.TYPE.JSON;\n }\n catch (e) {\n this.abort(\"Error trying to parse loaded json: \" + e);\n return;\n }\n }\n // if xml, parse into an xml document or div element\n else if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT) {\n try {\n if (globalThis.DOMParser) {\n var domparser = new DOMParser();\n this.data = domparser.parseFromString(text, 'text/xml');\n }\n else {\n var div = document.createElement('div');\n div.innerHTML = text;\n this.data = div;\n }\n this.type = LoaderResource.TYPE.XML;\n }\n catch (e$1) {\n this.abort(\"Error trying to parse loaded xml: \" + e$1);\n return;\n }\n }\n // other types just return the response\n else {\n this.data = xhr.response || text;\n }\n }\n else {\n this.abort(\"[\" + xhr.status + \"] \" + xhr.statusText + \": \" + xhr.responseURL);\n return;\n }\n this.complete();\n };\n /**\n * Sets the `crossOrigin` property for this resource based on if the url\n * for this resource is cross-origin. If crossOrigin was manually set, this\n * function does nothing.\n * @private\n * @param url - The url to test.\n * @param [loc=globalThis.location] - The location object to test against.\n * @return The crossOrigin value to use (or empty string for none).\n */\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n LoaderResource.prototype._determineCrossOrigin = function (url, loc) {\n // data: and javascript: urls are considered same-origin\n if (url.indexOf('data:') === 0) {\n return '';\n }\n // A sandboxed iframe without the 'allow-same-origin' attribute will have a special\n // origin designed not to match globalThis.location.origin, and will always require\n // crossOrigin requests regardless of whether the location matches.\n if (globalThis.origin !== globalThis.location.origin) {\n return 'anonymous';\n }\n // default is globalThis.location\n loc = loc || globalThis.location;\n if (!tempAnchor) {\n tempAnchor = document.createElement('a');\n }\n // let the browser determine the full href for the url of this resource and then\n // parse with the node url lib, we can't use the properties of the anchor element\n // because they don't work in IE9 :(\n tempAnchor.href = url;\n var parsedUrl = parseUri(tempAnchor.href, { strictMode: true });\n var samePort = (!parsedUrl.port && loc.port === '') || (parsedUrl.port === loc.port);\n var protocol = parsedUrl.protocol ? parsedUrl.protocol + \":\" : '';\n // if cross origin\n if (parsedUrl.host !== loc.hostname || !samePort || protocol !== loc.protocol) {\n return 'anonymous';\n }\n return '';\n };\n /**\n * Determines the responseType of an XHR request based on the extension of the\n * resource being loaded.\n *\n * @private\n * @return {PIXI.LoaderResource.XHR_RESPONSE_TYPE} The responseType to use.\n */\n LoaderResource.prototype._determineXhrType = function () {\n return LoaderResource._xhrTypeMap[this.extension] || LoaderResource.XHR_RESPONSE_TYPE.TEXT;\n };\n /**\n * Determines the loadType of a resource based on the extension of the\n * resource being loaded.\n *\n * @private\n * @return {PIXI.LoaderResource.LOAD_TYPE} The loadType to use.\n */\n LoaderResource.prototype._determineLoadType = function () {\n return LoaderResource._loadTypeMap[this.extension] || LoaderResource.LOAD_TYPE.XHR;\n };\n /**\n * Extracts the extension (sans '.') of the file being loaded by the resource.\n *\n * @param [url] - url to parse, `this.url` by default.\n * @return The extension.\n */\n LoaderResource.prototype._getExtension = function (url) {\n if (url === void 0) { url = this.url; }\n var ext = '';\n if (this.isDataUrl) {\n var slashIndex = url.indexOf('/');\n ext = url.substring(slashIndex + 1, url.indexOf(';', slashIndex));\n }\n else {\n var queryStart = url.indexOf('?');\n var hashStart = url.indexOf('#');\n var index = Math.min(queryStart > -1 ? queryStart : url.length, hashStart > -1 ? hashStart : url.length);\n url = url.substring(0, index);\n ext = url.substring(url.lastIndexOf('.') + 1);\n }\n return ext.toLowerCase();\n };\n /**\n * Determines the mime type of an XHR request based on the responseType of\n * resource being loaded.\n *\n * @param type - The type to get a mime type for.\n * @private\n * @return The mime type to use.\n */\n LoaderResource.prototype._getMimeFromXhrType = function (type) {\n switch (type) {\n case LoaderResource.XHR_RESPONSE_TYPE.BUFFER:\n return 'application/octet-binary';\n case LoaderResource.XHR_RESPONSE_TYPE.BLOB:\n return 'application/blob';\n case LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT:\n return 'application/xml';\n case LoaderResource.XHR_RESPONSE_TYPE.JSON:\n return 'application/json';\n case LoaderResource.XHR_RESPONSE_TYPE.DEFAULT:\n case LoaderResource.XHR_RESPONSE_TYPE.TEXT:\n /* falls through */\n default:\n return 'text/plain';\n }\n };\n return LoaderResource;\n}());\n// eslint-disable-next-line @typescript-eslint/no-namespace\n(function (LoaderResource) {\n /**\n * The types of resources a resource could represent.\n *\n * @static\n * @readonly\n * @enum {number}\n * @memberof PIXI.LoaderResource\n */\n var STATUS_FLAGS;\n (function (STATUS_FLAGS) {\n /** None */\n STATUS_FLAGS[STATUS_FLAGS[\"NONE\"] = 0] = \"NONE\";\n /** Data URL */\n STATUS_FLAGS[STATUS_FLAGS[\"DATA_URL\"] = 1] = \"DATA_URL\";\n /** Complete */\n STATUS_FLAGS[STATUS_FLAGS[\"COMPLETE\"] = 2] = \"COMPLETE\";\n /** Loading */\n STATUS_FLAGS[STATUS_FLAGS[\"LOADING\"] = 4] = \"LOADING\";\n })(STATUS_FLAGS = LoaderResource.STATUS_FLAGS || (LoaderResource.STATUS_FLAGS = {}));\n /**\n * The types of resources a resource could represent.\n *\n * @static\n * @readonly\n * @enum {number}\n * @memberof PIXI.LoaderResource\n */\n var TYPE;\n (function (TYPE) {\n /** Unknown */\n TYPE[TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n /** JSON */\n TYPE[TYPE[\"JSON\"] = 1] = \"JSON\";\n /** XML */\n TYPE[TYPE[\"XML\"] = 2] = \"XML\";\n /** Image */\n TYPE[TYPE[\"IMAGE\"] = 3] = \"IMAGE\";\n /** Audio */\n TYPE[TYPE[\"AUDIO\"] = 4] = \"AUDIO\";\n /** Video */\n TYPE[TYPE[\"VIDEO\"] = 5] = \"VIDEO\";\n /** Plain text */\n TYPE[TYPE[\"TEXT\"] = 6] = \"TEXT\";\n })(TYPE = LoaderResource.TYPE || (LoaderResource.TYPE = {}));\n /**\n * The types of loading a resource can use.\n *\n * @static\n * @readonly\n * @enum {number}\n * @memberof PIXI.LoaderResource\n */\n var LOAD_TYPE;\n (function (LOAD_TYPE) {\n /** Uses XMLHttpRequest to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"XHR\"] = 1] = \"XHR\";\n /** Uses an `Image` object to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"IMAGE\"] = 2] = \"IMAGE\";\n /** Uses an `Audio` object to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"AUDIO\"] = 3] = \"AUDIO\";\n /** Uses a `Video` object to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"VIDEO\"] = 4] = \"VIDEO\";\n })(LOAD_TYPE = LoaderResource.LOAD_TYPE || (LoaderResource.LOAD_TYPE = {}));\n /**\n * The XHR ready states, used internally.\n *\n * @static\n * @readonly\n * @enum {string}\n * @memberof PIXI.LoaderResource\n */\n var XHR_RESPONSE_TYPE;\n (function (XHR_RESPONSE_TYPE) {\n /** string */\n XHR_RESPONSE_TYPE[\"DEFAULT\"] = \"text\";\n /** ArrayBuffer */\n XHR_RESPONSE_TYPE[\"BUFFER\"] = \"arraybuffer\";\n /** Blob */\n XHR_RESPONSE_TYPE[\"BLOB\"] = \"blob\";\n /** Document */\n XHR_RESPONSE_TYPE[\"DOCUMENT\"] = \"document\";\n /** Object */\n XHR_RESPONSE_TYPE[\"JSON\"] = \"json\";\n /** String */\n XHR_RESPONSE_TYPE[\"TEXT\"] = \"text\";\n })(XHR_RESPONSE_TYPE = LoaderResource.XHR_RESPONSE_TYPE || (LoaderResource.XHR_RESPONSE_TYPE = {}));\n LoaderResource._loadTypeMap = {\n // images\n gif: LoaderResource.LOAD_TYPE.IMAGE,\n png: LoaderResource.LOAD_TYPE.IMAGE,\n bmp: LoaderResource.LOAD_TYPE.IMAGE,\n jpg: LoaderResource.LOAD_TYPE.IMAGE,\n jpeg: LoaderResource.LOAD_TYPE.IMAGE,\n tif: LoaderResource.LOAD_TYPE.IMAGE,\n tiff: LoaderResource.LOAD_TYPE.IMAGE,\n webp: LoaderResource.LOAD_TYPE.IMAGE,\n tga: LoaderResource.LOAD_TYPE.IMAGE,\n svg: LoaderResource.LOAD_TYPE.IMAGE,\n 'svg+xml': LoaderResource.LOAD_TYPE.IMAGE,\n // audio\n mp3: LoaderResource.LOAD_TYPE.AUDIO,\n ogg: LoaderResource.LOAD_TYPE.AUDIO,\n wav: LoaderResource.LOAD_TYPE.AUDIO,\n // videos\n mp4: LoaderResource.LOAD_TYPE.VIDEO,\n webm: LoaderResource.LOAD_TYPE.VIDEO,\n };\n LoaderResource._xhrTypeMap = {\n // xml\n xhtml: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n html: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n htm: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n xml: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n tmx: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n svg: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n // This was added to handle Tiled Tileset XML, but .tsx is also a TypeScript React Component.\n // Since it is way less likely for people to be loading TypeScript files instead of Tiled files,\n // this should probably be fine.\n tsx: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n // images\n gif: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n png: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n bmp: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n jpg: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n jpeg: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n tif: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n tiff: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n webp: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n tga: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n // json\n json: LoaderResource.XHR_RESPONSE_TYPE.JSON,\n // text\n text: LoaderResource.XHR_RESPONSE_TYPE.TEXT,\n txt: LoaderResource.XHR_RESPONSE_TYPE.TEXT,\n // fonts\n ttf: LoaderResource.XHR_RESPONSE_TYPE.BUFFER,\n otf: LoaderResource.XHR_RESPONSE_TYPE.BUFFER,\n };\n // We can't set the `src` attribute to empty string, so on abort we set it to this 1px transparent gif\n LoaderResource.EMPTY_GIF = 'data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==';\n})(LoaderResource || (LoaderResource = {}));\n\n/**\n * Smaller version of the async library constructs.\n * @ignore\n */\nfunction _noop$1() {\n}\n/**\n * Ensures a function is only called once.\n * @ignore\n * @param {function} fn - The function to wrap.\n * @return {function} The wrapping function.\n */\nfunction onlyOnce(fn) {\n return function onceWrapper() {\n var arguments$1 = arguments;\n\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments$1[_i];\n }\n if (fn === null) {\n throw new Error('Callback was already called.');\n }\n var callFn = fn;\n fn = null;\n callFn.apply(this, args);\n };\n}\n/**\n * @private\n * @memberof PIXI\n */\nvar AsyncQueueItem = /** @class */ (function () {\n /**\n * @private\n */\n function AsyncQueueItem(data, callback) {\n this.data = data;\n this.callback = callback;\n }\n return AsyncQueueItem;\n}());\n/**\n * @private\n * @memberof PIXI\n */\nvar AsyncQueue = /** @class */ (function () {\n /**\n * @private\n */\n function AsyncQueue(worker, concurrency) {\n var _this = this;\n if (concurrency === void 0) { concurrency = 1; }\n this.workers = 0;\n this.saturated = _noop$1;\n this.unsaturated = _noop$1;\n this.empty = _noop$1;\n this.drain = _noop$1;\n this.error = _noop$1;\n this.started = false;\n this.paused = false;\n this._tasks = [];\n this._insert = function (data, insertAtFront, callback) {\n if (callback && typeof callback !== 'function') {\n throw new Error('task callback must be a function');\n }\n _this.started = true;\n // eslint-disable-next-line no-eq-null,eqeqeq\n if (data == null && _this.idle()) {\n // call drain immediately if there are no tasks\n setTimeout(function () { return _this.drain(); }, 1);\n return;\n }\n var item = new AsyncQueueItem(data, typeof callback === 'function' ? callback : _noop$1);\n if (insertAtFront) {\n _this._tasks.unshift(item);\n }\n else {\n _this._tasks.push(item);\n }\n setTimeout(_this.process, 1);\n };\n this.process = function () {\n while (!_this.paused && _this.workers < _this.concurrency && _this._tasks.length) {\n var task = _this._tasks.shift();\n if (_this._tasks.length === 0) {\n _this.empty();\n }\n _this.workers += 1;\n if (_this.workers === _this.concurrency) {\n _this.saturated();\n }\n _this._worker(task.data, onlyOnce(_this._next(task)));\n }\n };\n this._worker = worker;\n if (concurrency === 0) {\n throw new Error('Concurrency must not be zero');\n }\n this.concurrency = concurrency;\n this.buffer = concurrency / 4.0;\n }\n /**\n * @private\n */\n AsyncQueue.prototype._next = function (task) {\n var _this = this;\n return function () {\n var arguments$1 = arguments;\n\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments$1[_i];\n }\n _this.workers -= 1;\n task.callback.apply(task, args);\n // eslint-disable-next-line no-eq-null,eqeqeq\n if (args[0] != null) {\n _this.error(args[0], task.data);\n }\n if (_this.workers <= (_this.concurrency - _this.buffer)) {\n _this.unsaturated();\n }\n if (_this.idle()) {\n _this.drain();\n }\n _this.process();\n };\n };\n // That was in object\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n AsyncQueue.prototype.push = function (data, callback) {\n this._insert(data, false, callback);\n };\n AsyncQueue.prototype.kill = function () {\n this.workers = 0;\n this.drain = _noop$1;\n this.started = false;\n this._tasks = [];\n };\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n AsyncQueue.prototype.unshift = function (data, callback) {\n this._insert(data, true, callback);\n };\n AsyncQueue.prototype.length = function () {\n return this._tasks.length;\n };\n AsyncQueue.prototype.running = function () {\n return this.workers;\n };\n AsyncQueue.prototype.idle = function () {\n return this._tasks.length + this.workers === 0;\n };\n AsyncQueue.prototype.pause = function () {\n if (this.paused === true) {\n return;\n }\n this.paused = true;\n };\n AsyncQueue.prototype.resume = function () {\n if (this.paused === false) {\n return;\n }\n this.paused = false;\n // Need to call this.process once per concurrent\n // worker to preserve full concurrency after pause\n for (var w = 1; w <= this.concurrency; w++) {\n this.process();\n }\n };\n /**\n * Iterates an array in series.\n *\n * @param {Array.<*>} array - Array to iterate.\n * @param {function} iterator - Function to call for each element.\n * @param {function} callback - Function to call when done, or on error.\n * @param {boolean} [deferNext=false] - Break synchronous each loop by calling next with a setTimeout of 1.\n */\n AsyncQueue.eachSeries = function (array, iterator, callback, deferNext) {\n var i = 0;\n var len = array.length;\n function next(err) {\n if (err || i === len) {\n if (callback) {\n callback(err);\n }\n return;\n }\n if (deferNext) {\n setTimeout(function () {\n iterator(array[i++], next);\n }, 1);\n }\n else {\n iterator(array[i++], next);\n }\n }\n next();\n };\n /**\n * Async queue implementation,\n *\n * @param {function} worker - The worker function to call for each task.\n * @param {number} concurrency - How many workers to run in parrallel.\n * @return {*} The async queue object.\n */\n AsyncQueue.queue = function (worker, concurrency) {\n return new AsyncQueue(worker, concurrency);\n };\n return AsyncQueue;\n}());\n\n// some constants\nvar MAX_PROGRESS = 100;\nvar rgxExtractUrlHash = /(#[\\w-]+)?$/;\n/**\n * The new loader, forked from Resource Loader by Chad Engler: https://github.com/englercj/resource-loader\n *\n * ```js\n * const loader = PIXI.Loader.shared; // PixiJS exposes a premade instance for you to use.\n * // or\n * const loader = new PIXI.Loader(); // You can also create your own if you want\n *\n * const sprites = {};\n *\n * // Chainable `add` to enqueue a resource\n * loader.add('bunny', 'data/bunny.png')\n * .add('spaceship', 'assets/spritesheet.json');\n * loader.add('scoreFont', 'assets/score.fnt');\n *\n * // Chainable `pre` to add a middleware that runs for each resource, *before* loading that resource.\n * // This is useful to implement custom caching modules (using filesystem, indexeddb, memory, etc).\n * loader.pre(cachingMiddleware);\n *\n * // Chainable `use` to add a middleware that runs for each resource, *after* loading that resource.\n * // This is useful to implement custom parsing modules (like spritesheet parsers, spine parser, etc).\n * loader.use(parsingMiddleware);\n *\n * // The `load` method loads the queue of resources, and calls the passed in callback called once all\n * // resources have loaded.\n * loader.load((loader, resources) => {\n * // resources is an object where the key is the name of the resource loaded and the value is the resource object.\n * // They have a couple default properties:\n * // - `url`: The URL that the resource was loaded from\n * // - `error`: The error that happened when trying to load (if any)\n * // - `data`: The raw data that was loaded\n * // also may contain other properties based on the middleware that runs.\n * sprites.bunny = new PIXI.TilingSprite(resources.bunny.texture);\n * sprites.spaceship = new PIXI.TilingSprite(resources.spaceship.texture);\n * sprites.scoreFont = new PIXI.TilingSprite(resources.scoreFont.texture);\n * });\n *\n * // throughout the process multiple signals can be dispatched.\n * loader.onProgress.add(() => {}); // called once per loaded/errored file\n * loader.onError.add(() => {}); // called once per errored file\n * loader.onLoad.add(() => {}); // called once per loaded file\n * loader.onComplete.add(() => {}); // called once when the queued resources all load.\n * ```\n *\n * @memberof PIXI\n */\nvar Loader = /** @class */ (function () {\n /**\n * @param baseUrl - The base url for all resources loaded by this loader.\n * @param concurrency - The number of resources to load concurrently.\n */\n function Loader(baseUrl, concurrency) {\n var _this = this;\n if (baseUrl === void 0) { baseUrl = ''; }\n if (concurrency === void 0) { concurrency = 10; }\n /**\n * The progress percent of the loader going through the queue.\n */\n this.progress = 0;\n /**\n * Loading state of the loader, true if it is currently loading resources.\n */\n this.loading = false;\n /**\n * A querystring to append to every URL added to the loader.\n *\n * This should be a valid query string *without* the question-mark (`?`). The loader will\n * also *not* escape values for you. Make sure to escape your parameters with\n * [`encodeURIComponent`](https://mdn.io/encodeURIComponent) before assigning this property.\n *\n * @example\n * const loader = new Loader();\n *\n * loader.defaultQueryString = 'user=me&password=secret';\n *\n * // This will request 'image.png?user=me&password=secret'\n * loader.add('image.png').load();\n *\n * loader.reset();\n *\n * // This will request 'image.png?v=1&user=me&password=secret'\n * loader.add('iamge.png?v=1').load();\n */\n this.defaultQueryString = '';\n /**\n * The middleware to run before loading each resource.\n */\n this._beforeMiddleware = [];\n /**\n * The middleware to run after loading each resource.\n */\n this._afterMiddleware = [];\n /**\n * The tracks the resources we are currently completing parsing for.\n */\n this._resourcesParsing = [];\n /**\n * The `_loadResource` function bound with this object context.\n *\n * @param r - The resource to load\n * @param d - The dequeue function\n */\n this._boundLoadResource = function (r, d) { return _this._loadResource(r, d); };\n /**\n * All the resources for this loader keyed by name.\n */\n this.resources = {};\n this.baseUrl = baseUrl;\n this._beforeMiddleware = [];\n this._afterMiddleware = [];\n this._resourcesParsing = [];\n this._boundLoadResource = function (r, d) { return _this._loadResource(r, d); };\n this._queue = AsyncQueue.queue(this._boundLoadResource, concurrency);\n this._queue.pause();\n this.resources = {};\n this.onProgress = new Signal();\n this.onError = new Signal();\n this.onLoad = new Signal();\n this.onStart = new Signal();\n this.onComplete = new Signal();\n for (var i = 0; i < Loader._plugins.length; ++i) {\n var plugin = Loader._plugins[i];\n var pre = plugin.pre, use = plugin.use;\n if (pre) {\n this.pre(pre);\n }\n if (use) {\n this.use(use);\n }\n }\n this._protected = false;\n }\n /**\n * Same as add, params have strict order\n *\n * @private\n * @param name - The name of the resource to load.\n * @param url - The url for this resource, relative to the baseUrl of this loader.\n * @param options - The options for the load.\n * @param callback - Function to call when this specific resource completes loading.\n * @return The loader itself.\n */\n Loader.prototype._add = function (name, url, options, callback) {\n // if loading already you can only add resources that have a parent.\n if (this.loading && (!options || !options.parentResource)) {\n throw new Error('Cannot add resources while the loader is running.');\n }\n // check if resource already exists.\n if (this.resources[name]) {\n throw new Error(\"Resource named \\\"\" + name + \"\\\" already exists.\");\n }\n // add base url if this isn't an absolute url\n url = this._prepareUrl(url);\n // create the store the resource\n this.resources[name] = new LoaderResource(name, url, options);\n if (typeof callback === 'function') {\n this.resources[name].onAfterMiddleware.once(callback);\n }\n // if actively loading, make sure to adjust progress chunks for that parent and its children\n if (this.loading) {\n var parent = options.parentResource;\n var incompleteChildren = [];\n for (var i = 0; i < parent.children.length; ++i) {\n if (!parent.children[i].isComplete) {\n incompleteChildren.push(parent.children[i]);\n }\n }\n var fullChunk = parent.progressChunk * (incompleteChildren.length + 1); // +1 for parent\n var eachChunk = fullChunk / (incompleteChildren.length + 2); // +2 for parent & new child\n parent.children.push(this.resources[name]);\n parent.progressChunk = eachChunk;\n for (var i = 0; i < incompleteChildren.length; ++i) {\n incompleteChildren[i].progressChunk = eachChunk;\n }\n this.resources[name].progressChunk = eachChunk;\n }\n // add the resource to the queue\n this._queue.push(this.resources[name]);\n return this;\n };\n /* eslint-enable require-jsdoc,valid-jsdoc */\n /**\n * Sets up a middleware function that will run *before* the\n * resource is loaded.\n *\n * @param fn - The middleware function to register.\n * @return The loader itself.\n */\n Loader.prototype.pre = function (fn) {\n this._beforeMiddleware.push(fn);\n return this;\n };\n /**\n * Sets up a middleware function that will run *after* the\n * resource is loaded.\n *\n * @param fn - The middleware function to register.\n * @return The loader itself.\n */\n Loader.prototype.use = function (fn) {\n this._afterMiddleware.push(fn);\n return this;\n };\n /**\n * Resets the queue of the loader to prepare for a new load.\n *\n * @return The loader itself.\n */\n Loader.prototype.reset = function () {\n this.progress = 0;\n this.loading = false;\n this._queue.kill();\n this._queue.pause();\n // abort all resource loads\n for (var k in this.resources) {\n var res = this.resources[k];\n if (res._onLoadBinding) {\n res._onLoadBinding.detach();\n }\n if (res.isLoading) {\n res.abort('loader reset');\n }\n }\n this.resources = {};\n return this;\n };\n /**\n * Starts loading the queued resources.\n * @param cb - Optional callback that will be bound to the `complete` event.\n * @return The loader itself.\n */\n Loader.prototype.load = function (cb) {\n // register complete callback if they pass one\n if (typeof cb === 'function') {\n this.onComplete.once(cb);\n }\n // if the queue has already started we are done here\n if (this.loading) {\n return this;\n }\n if (this._queue.idle()) {\n this._onStart();\n this._onComplete();\n }\n else {\n // distribute progress chunks\n var numTasks = this._queue._tasks.length;\n var chunk = MAX_PROGRESS / numTasks;\n for (var i = 0; i < this._queue._tasks.length; ++i) {\n this._queue._tasks[i].data.progressChunk = chunk;\n }\n // notify we are starting\n this._onStart();\n // start loading\n this._queue.resume();\n }\n return this;\n };\n Object.defineProperty(Loader.prototype, \"concurrency\", {\n /**\n * The number of resources to load concurrently.\n *\n * @default 10\n */\n get: function () {\n return this._queue.concurrency;\n },\n set: function (concurrency) {\n this._queue.concurrency = concurrency;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Prepares a url for usage based on the configuration of this object\n * @param url - The url to prepare.\n * @return The prepared url.\n */\n Loader.prototype._prepareUrl = function (url) {\n var parsedUrl = parseUri(url, { strictMode: true });\n var result;\n // absolute url, just use it as is.\n if (parsedUrl.protocol || !parsedUrl.path || url.indexOf('//') === 0) {\n result = url;\n }\n // if baseUrl doesn't end in slash and url doesn't start with slash, then add a slash inbetween\n else if (this.baseUrl.length\n && this.baseUrl.lastIndexOf('/') !== this.baseUrl.length - 1\n && url.charAt(0) !== '/') {\n result = this.baseUrl + \"/\" + url;\n }\n else {\n result = this.baseUrl + url;\n }\n // if we need to add a default querystring, there is a bit more work\n if (this.defaultQueryString) {\n var hash = rgxExtractUrlHash.exec(result)[0];\n result = result.slice(0, result.length - hash.length);\n if (result.indexOf('?') !== -1) {\n result += \"&\" + this.defaultQueryString;\n }\n else {\n result += \"?\" + this.defaultQueryString;\n }\n result += hash;\n }\n return result;\n };\n /**\n * Loads a single resource.\n *\n * @param resource - The resource to load.\n * @param dequeue - The function to call when we need to dequeue this item.\n */\n Loader.prototype._loadResource = function (resource, dequeue) {\n var _this = this;\n resource._dequeue = dequeue;\n // run before middleware\n AsyncQueue.eachSeries(this._beforeMiddleware, function (fn, next) {\n fn.call(_this, resource, function () {\n // if the before middleware marks the resource as complete,\n // break and don't process any more before middleware\n next(resource.isComplete ? {} : null);\n });\n }, function () {\n if (resource.isComplete) {\n _this._onLoad(resource);\n }\n else {\n resource._onLoadBinding = resource.onComplete.once(_this._onLoad, _this);\n resource.load();\n }\n }, true);\n };\n /**\n * Called once loading has started.\n */\n Loader.prototype._onStart = function () {\n this.progress = 0;\n this.loading = true;\n this.onStart.dispatch(this);\n };\n /**\n * Called once each resource has loaded.\n */\n Loader.prototype._onComplete = function () {\n this.progress = MAX_PROGRESS;\n this.loading = false;\n this.onComplete.dispatch(this, this.resources);\n };\n /**\n * Called each time a resources is loaded.\n * @param resource - The resource that was loaded\n */\n Loader.prototype._onLoad = function (resource) {\n var _this = this;\n resource._onLoadBinding = null;\n // remove this resource from the async queue, and add it to our list of resources that are being parsed\n this._resourcesParsing.push(resource);\n resource._dequeue();\n // run all the after middleware for this resource\n AsyncQueue.eachSeries(this._afterMiddleware, function (fn, next) {\n fn.call(_this, resource, next);\n }, function () {\n resource.onAfterMiddleware.dispatch(resource);\n _this.progress = Math.min(MAX_PROGRESS, _this.progress + resource.progressChunk);\n _this.onProgress.dispatch(_this, resource);\n if (resource.error) {\n _this.onError.dispatch(resource.error, _this, resource);\n }\n else {\n _this.onLoad.dispatch(_this, resource);\n }\n _this._resourcesParsing.splice(_this._resourcesParsing.indexOf(resource), 1);\n // do completion check\n if (_this._queue.idle() && _this._resourcesParsing.length === 0) {\n _this._onComplete();\n }\n }, true);\n };\n /**\n * Destroy the loader, removes references.\n */\n Loader.prototype.destroy = function () {\n if (!this._protected) {\n this.reset();\n }\n };\n Object.defineProperty(Loader, \"shared\", {\n /**\n * A premade instance of the loader that can be used to load resources.\n */\n get: function () {\n var shared = Loader._shared;\n if (!shared) {\n shared = new Loader();\n shared._protected = true;\n Loader._shared = shared;\n }\n return shared;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Adds a Loader plugin for the global shared loader and all\n * new Loader instances created.\n *\n * @param plugin - The plugin to add\n * @return Reference to PIXI.Loader for chaining\n */\n Loader.registerPlugin = function (plugin) {\n Loader._plugins.push(plugin);\n if (plugin.add) {\n plugin.add();\n }\n return Loader;\n };\n Loader._plugins = [];\n return Loader;\n}());\nLoader.prototype.add = function add(name, url, options, callback) {\n // special case of an array of objects or urls\n if (Array.isArray(name)) {\n for (var i = 0; i < name.length; ++i) {\n this.add(name[i]);\n }\n return this;\n }\n // if an object is passed instead of params\n if (typeof name === 'object') {\n options = name;\n callback = url || options.callback || options.onComplete;\n url = options.url;\n name = options.name || options.key || options.url;\n }\n // case where no name is passed shift all args over by one.\n if (typeof url !== 'string') {\n callback = options;\n options = url;\n url = name;\n }\n // now that we shifted make sure we have a proper url.\n if (typeof url !== 'string') {\n throw new Error('No url passed to add resource to loader.');\n }\n // options are optional so people might pass a function and no options\n if (typeof options === 'function') {\n callback = options;\n options = null;\n }\n return this._add(name, url, options, callback);\n};\n\n/**\n * Application plugin for supporting loader option. Installing the LoaderPlugin\n * is not necessary if using **pixi.js** or **pixi.js-legacy**.\n * @example\n * import {AppLoaderPlugin} from '@pixi/loaders';\n * import {Application} from '@pixi/app';\n * Application.registerPlugin(AppLoaderPlugin);\n * @memberof PIXI\n */\nvar AppLoaderPlugin = /** @class */ (function () {\n function AppLoaderPlugin() {\n }\n /**\n * Called on application constructor\n *\n * @private\n */\n AppLoaderPlugin.init = function (options) {\n options = Object.assign({\n sharedLoader: false,\n }, options);\n this.loader = options.sharedLoader ? Loader.shared : new Loader();\n };\n /**\n * Called when application destroyed\n *\n * @private\n */\n AppLoaderPlugin.destroy = function () {\n if (this.loader) {\n this.loader.destroy();\n this.loader = null;\n }\n };\n return AppLoaderPlugin;\n}());\n\n/**\n * Loader plugin for handling Texture resources.\n *\n * @memberof PIXI\n */\nvar TextureLoader = /** @class */ (function () {\n function TextureLoader() {\n }\n /**\n * Handle SVG elements a text, render with SVGResource.\n */\n TextureLoader.add = function () {\n LoaderResource.setExtensionLoadType('svg', LoaderResource.LOAD_TYPE.XHR);\n LoaderResource.setExtensionXhrType('svg', LoaderResource.XHR_RESPONSE_TYPE.TEXT);\n };\n /**\n * Called after a resource is loaded.\n * @see PIXI.Loader.loaderMiddleware\n * @param resource\n * @param {function} next\n */\n TextureLoader.use = function (resource, next) {\n // create a new texture if the data is an Image object\n if (resource.data && (resource.type === LoaderResource.TYPE.IMAGE || resource.extension === 'svg')) {\n var data = resource.data, url = resource.url, name = resource.name, metadata = resource.metadata;\n Texture.fromLoader(data, url, name, metadata).then(function (texture) {\n resource.texture = texture;\n next();\n })\n // TODO: handle errors in Texture.fromLoader\n // so we can pass them to the Loader\n .catch(next);\n }\n else {\n next();\n }\n };\n return TextureLoader;\n}());\n\nvar _keyStr = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\n/**\n * Encodes binary into base64.\n *\n * @function encodeBinary\n * @param {string} input - The input data to encode.\n * @returns {string} The encoded base64 string\n */\nfunction encodeBinary(input) {\n var output = '';\n var inx = 0;\n while (inx < input.length) {\n // Fill byte buffer array\n var bytebuffer = [0, 0, 0];\n var encodedCharIndexes = [0, 0, 0, 0];\n for (var jnx = 0; jnx < bytebuffer.length; ++jnx) {\n if (inx < input.length) {\n // throw away high-order byte, as documented at:\n // https://developer.mozilla.org/En/Using_XMLHttpRequest#Handling_binary_data\n bytebuffer[jnx] = input.charCodeAt(inx++) & 0xff;\n }\n else {\n bytebuffer[jnx] = 0;\n }\n }\n // Get each encoded character, 6 bits at a time\n // index 1: first 6 bits\n encodedCharIndexes[0] = bytebuffer[0] >> 2;\n // index 2: second 6 bits (2 least significant bits from input byte 1 + 4 most significant bits from byte 2)\n encodedCharIndexes[1] = ((bytebuffer[0] & 0x3) << 4) | (bytebuffer[1] >> 4);\n // index 3: third 6 bits (4 least significant bits from input byte 2 + 2 most significant bits from byte 3)\n encodedCharIndexes[2] = ((bytebuffer[1] & 0x0f) << 2) | (bytebuffer[2] >> 6);\n // index 3: forth 6 bits (6 least significant bits from input byte 3)\n encodedCharIndexes[3] = bytebuffer[2] & 0x3f;\n // Determine whether padding happened, and adjust accordingly\n var paddingBytes = inx - (input.length - 1);\n switch (paddingBytes) {\n case 2:\n // Set last 2 characters to padding char\n encodedCharIndexes[3] = 64;\n encodedCharIndexes[2] = 64;\n break;\n case 1:\n // Set last character to padding char\n encodedCharIndexes[3] = 64;\n break;\n }\n // Now we will grab each appropriate character out of our keystring\n // based on our index array and append it to the output string\n for (var jnx = 0; jnx < encodedCharIndexes.length; ++jnx) {\n output += _keyStr.charAt(encodedCharIndexes[jnx]);\n }\n }\n return output;\n}\n\nvar Url = self.URL || self.webkitURL;\n/**\n * A middleware for transforming XHR loaded Blobs into more useful objects\n *\n * @ignore\n * @function parsing\n * @example\n * import { Loader, middleware } from 'resource-loader';\n * const loader = new Loader();\n * loader.use(middleware.parsing);\n * @param resource - Current Resource\n * @param next - Callback when complete\n */\nfunction parsing(resource, next) {\n if (!resource.data) {\n next();\n return;\n }\n // if this was an XHR load of a blob\n if (resource.xhr && resource.xhrType === LoaderResource.XHR_RESPONSE_TYPE.BLOB) {\n // if there is no blob support we probably got a binary string back\n if (!self.Blob || typeof resource.data === 'string') {\n var type = resource.xhr.getResponseHeader('content-type');\n // this is an image, convert the binary string into a data url\n if (type && type.indexOf('image') === 0) {\n resource.data = new Image();\n resource.data.src = \"data:\" + type + \";base64,\" + encodeBinary(resource.xhr.responseText);\n resource.type = LoaderResource.TYPE.IMAGE;\n // wait until the image loads and then callback\n resource.data.onload = function () {\n resource.data.onload = null;\n next();\n };\n // next will be called on load\n return;\n }\n }\n // if content type says this is an image, then we should transform the blob into an Image object\n else if (resource.data.type.indexOf('image') === 0) {\n var src_1 = Url.createObjectURL(resource.data);\n resource.blob = resource.data;\n resource.data = new Image();\n resource.data.src = src_1;\n resource.type = LoaderResource.TYPE.IMAGE;\n // cleanup the no longer used blob after the image loads\n // TODO: Is this correct? Will the image be invalid after revoking?\n resource.data.onload = function () {\n Url.revokeObjectURL(src_1);\n resource.data.onload = null;\n next();\n };\n // next will be called on load.\n return;\n }\n }\n next();\n}\n\n// parse any blob into more usable objects (e.g. Image)\nLoader.registerPlugin({ use: parsing });\n// parse any Image objects into textures\nLoader.registerPlugin(TextureLoader);\n\nexport { AppLoaderPlugin, Loader, LoaderResource, TextureLoader };\n//# sourceMappingURL=loaders.js.map\n","/*!\n * @pixi/compressed-textures - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/compressed-textures is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { ViewableBuffer, BufferResource, Texture, BaseTexture } from '@pixi/core';\nimport { LoaderResource } from '@pixi/loaders';\nimport { url } from '@pixi/utils';\nimport { MIPMAP_MODES, ALPHA_MODES, TYPES, FORMATS } from '@pixi/constants';\n\nvar _a;\n/**\n * WebGL internal formats, including compressed texture formats provided by extensions\n *\n * @memberof PIXI\n * @static\n * @name INTERNAL_FORMATS\n * @enum {number}\n * @property {number} COMPRESSED_RGB_S3TC_DXT1_EXT=0x83F0\n * @property {number} COMPRESSED_RGBA_S3TC_DXT1_EXT=0x83F1\n * @property {number} COMPRESSED_RGBA_S3TC_DXT3_EXT=0x83F2\n * @property {number} COMPRESSED_RGBA_S3TC_DXT5_EXT=0x83F3\n * @property {number} COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT=35917\n * @property {number} COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT=35918\n * @property {number} COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT=35919\n * @property {number} COMPRESSED_SRGB_S3TC_DXT1_EXT=35916\n * @property {number} COMPRESSED_R11_EAC=0x9270\n * @property {number} COMPRESSED_SIGNED_R11_EAC=0x9271\n * @property {number} COMPRESSED_RG11_EAC=0x9272\n * @property {number} COMPRESSED_SIGNED_RG11_EAC=0x9273\n * @property {number} COMPRESSED_RGB8_ETC2=0x9274\n * @property {number} COMPRESSED_RGBA8_ETC2_EAC=0x9278\n * @property {number} COMPRESSED_SRGB8_ETC2=0x9275\n * @property {number} COMPRESSED_SRGB8_ALPHA8_ETC2_EAC=0x9279\n * @property {number} COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2=0x9276\n * @property {number} COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2=0x9277\n * @property {number} COMPRESSED_RGB_PVRTC_4BPPV1_IMG=0x8C00\n * @property {number} COMPRESSED_RGBA_PVRTC_4BPPV1_IMG=0x8C02\n * @property {number} COMPRESSED_RGB_PVRTC_2BPPV1_IMG=0x8C01\n * @property {number} COMPRESSED_RGBA_PVRTC_2BPPV1_IMG=0x8C03\n * @property {number} COMPRESSED_RGB_ETC1_WEBGL=0x8D64\n * @property {number} COMPRESSED_RGB_ATC_WEBGL=0x8C92\n * @property {number} COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL=0x8C92\n * @property {number} COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL=0x87EE\n */\nvar INTERNAL_FORMATS;\n(function (INTERNAL_FORMATS) {\n // WEBGL_compressed_texture_s3tc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_S3TC_DXT1_EXT\"] = 33776] = \"COMPRESSED_RGB_S3TC_DXT1_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_S3TC_DXT1_EXT\"] = 33777] = \"COMPRESSED_RGBA_S3TC_DXT1_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_S3TC_DXT3_EXT\"] = 33778] = \"COMPRESSED_RGBA_S3TC_DXT3_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_S3TC_DXT5_EXT\"] = 33779] = \"COMPRESSED_RGBA_S3TC_DXT5_EXT\";\n // WEBGL_compressed_texture_s3tc_srgb\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT\"] = 35917] = \"COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT\"] = 35918] = \"COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT\"] = 35919] = \"COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_S3TC_DXT1_EXT\"] = 35916] = \"COMPRESSED_SRGB_S3TC_DXT1_EXT\";\n // WEBGL_compressed_texture_etc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_R11_EAC\"] = 37488] = \"COMPRESSED_R11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SIGNED_R11_EAC\"] = 37489] = \"COMPRESSED_SIGNED_R11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RG11_EAC\"] = 37490] = \"COMPRESSED_RG11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SIGNED_RG11_EAC\"] = 37491] = \"COMPRESSED_SIGNED_RG11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB8_ETC2\"] = 37492] = \"COMPRESSED_RGB8_ETC2\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA8_ETC2_EAC\"] = 37496] = \"COMPRESSED_RGBA8_ETC2_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB8_ETC2\"] = 37493] = \"COMPRESSED_SRGB8_ETC2\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB8_ALPHA8_ETC2_EAC\"] = 37497] = \"COMPRESSED_SRGB8_ALPHA8_ETC2_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2\"] = 37494] = \"COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2\"] = 37495] = \"COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2\";\n // WEBGL_compressed_texture_pvrtc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_PVRTC_4BPPV1_IMG\"] = 35840] = \"COMPRESSED_RGB_PVRTC_4BPPV1_IMG\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_PVRTC_4BPPV1_IMG\"] = 35842] = \"COMPRESSED_RGBA_PVRTC_4BPPV1_IMG\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_PVRTC_2BPPV1_IMG\"] = 35841] = \"COMPRESSED_RGB_PVRTC_2BPPV1_IMG\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_PVRTC_2BPPV1_IMG\"] = 35843] = \"COMPRESSED_RGBA_PVRTC_2BPPV1_IMG\";\n // WEBGL_compressed_texture_etc1\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_ETC1_WEBGL\"] = 36196] = \"COMPRESSED_RGB_ETC1_WEBGL\";\n // WEBGL_compressed_texture_atc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_ATC_WEBGL\"] = 35986] = \"COMPRESSED_RGB_ATC_WEBGL\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL\"] = 35986] = \"COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL\"] = 34798] = \"COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL\";\n})(INTERNAL_FORMATS || (INTERNAL_FORMATS = {}));\n/**\n * Maps the compressed texture formats in {@link PIXI.INTERNAL_FORMATS} to the number of bytes taken by\n * each texel.\n *\n * @memberof PIXI\n * @static\n * @ignore\n */\nvar INTERNAL_FORMAT_TO_BYTES_PER_PIXEL = (_a = {},\n // WEBGL_compressed_texture_s3tc\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT] = 1,\n // WEBGL_compressed_texture_s3tc\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT] = 1,\n // WEBGL_compressed_texture_etc\n _a[INTERNAL_FORMATS.COMPRESSED_R11_EAC] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SIGNED_R11_EAC] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RG11_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_SIGNED_RG11_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGB8_ETC2] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA8_ETC2_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB8_ETC2] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2] = 0.5,\n // WEBGL_compressed_texture_pvrtc\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_PVRTC_4BPPV1_IMG] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_PVRTC_2BPPV1_IMG] = 0.25,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG] = 0.25,\n // WEBGL_compressed_texture_etc1\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_ETC1_WEBGL] = 0.5,\n // @see https://www.khronos.org/registry/OpenGL/extensions/AMD/AMD_compressed_ATC_texture.txt\n // WEBGL_compressed_texture_atc\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_ATC_WEBGL] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL] = 1,\n _a);\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nfunction __awaiter(thisArg, _arguments, P, generator) {\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nfunction __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) { throw t[1]; } return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) { throw new TypeError(\"Generator is already executing.\"); }\r\n while (_) { try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) { return t; }\r\n if (y = 0, t) { op = [op[0] & 2, t.value]; }\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) { _.ops.pop(); }\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } }\r\n if (op[0] & 5) { throw op[1]; } return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\n\n/**\n * Resource that fetches texture data over the network and stores it in a buffer.\n *\n * @class\n * @extends PIXI.Resource\n * @memberof PIXI\n */\nvar BlobResource = /** @class */ (function (_super) {\n __extends(BlobResource, _super);\n /**\n * @param {string} url - the URL of the texture file\n * @param {boolean}[autoLoad] - whether to fetch the data immediately;\n * you can fetch it later via {@link BlobResource#load}\n */\n function BlobResource(source, options) {\n if (options === void 0) { options = { width: 1, height: 1, autoLoad: true }; }\n var _this = this;\n var origin;\n var data;\n if (typeof source === 'string') {\n origin = source;\n data = new Uint8Array();\n }\n else {\n origin = null;\n data = source;\n }\n _this = _super.call(this, data, options) || this;\n /**\n * The URL of the texture file\n * @member {string}\n */\n _this.origin = origin;\n /**\n * The viewable buffer on the data\n * @member {ViewableBuffer}\n */\n // HINT: BlobResource allows \"null\" sources, assuming the child class provides an alternative\n _this.buffer = data ? new ViewableBuffer(data) : null;\n // Allow autoLoad = \"undefined\" still load the resource by default\n if (_this.origin && options.autoLoad !== false) {\n _this.load();\n }\n if (data && data.length) {\n _this.loaded = true;\n _this.onBlobLoaded(_this.buffer.rawBinaryData);\n }\n return _this;\n }\n BlobResource.prototype.onBlobLoaded = function (_data) {\n // TODO: Override this method\n };\n /**\n * Loads the blob\n */\n BlobResource.prototype.load = function () {\n return __awaiter(this, void 0, Promise, function () {\n var response, blob, arrayBuffer;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4 /*yield*/, fetch(this.origin)];\n case 1:\n response = _a.sent();\n return [4 /*yield*/, response.blob()];\n case 2:\n blob = _a.sent();\n return [4 /*yield*/, blob.arrayBuffer()];\n case 3:\n arrayBuffer = _a.sent();\n this.data = new Uint32Array(arrayBuffer);\n this.buffer = new ViewableBuffer(arrayBuffer);\n this.loaded = true;\n this.onBlobLoaded(arrayBuffer);\n this.update();\n return [2 /*return*/, this];\n }\n });\n });\n };\n return BlobResource;\n}(BufferResource));\n\n/**\n * Resource for compressed texture formats, as follows: S3TC/DXTn (& their sRGB formats), ATC, ASTC, ETC 1/2, PVRTC.\n *\n * Compressed textures improve performance when rendering is texture-bound. The texture data stays compressed in\n * graphics memory, increasing memory locality and speeding up texture fetches. These formats can also be used to store\n * more detail in the same amount of memory.\n *\n * For most developers, container file formats are a better abstraction instead of directly handling raw texture\n * data. PixiJS provides native support for the following texture file formats (via {@link PIXI.Loader}):\n *\n * * **.dds** - the DirectDraw Surface file format stores DXTn (DXT-1,3,5) data. See {@link PIXI.DDSLoader}\n * * **.ktx** - the Khronos Texture Container file format supports storing all the supported WebGL compression formats.\n * See {@link PIXI.KTXLoader}.\n * * **.basis** - the BASIS supercompressed file format stores texture data in an internal format that is transcoded\n * to the compression format supported on the device at _runtime_. It also supports transcoding into a uncompressed\n * format as a fallback; you must install the `@pixi/basis-loader`, `@pixi/basis-transcoder` packages separately to\n * use these files. See {@link PIXI.BasisLoader}.\n *\n * The loaders for the aforementioned formats use `CompressedTextureResource` internally. It is strongly suggested that\n * they be used instead.\n *\n * ## Working directly with CompressedTextureResource\n *\n * Since `CompressedTextureResource` inherits `BlobResource`, you can provide it a URL pointing to a file containing\n * the raw texture data (with no file headers!):\n *\n * ```js\n * // The resource backing the texture data for your textures.\n * // NOTE: You can also provide a ArrayBufferView instead of a URL. This is used when loading data from a container file\n * // format such as KTX, DDS, or BASIS.\n * const compressedResource = new PIXI.CompressedTextureResource(\"bunny.dxt5\", {\n * format: PIXI.INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n * width: 256,\n * height: 256\n * });\n *\n * // You can create a base-texture to the cache, so that future `Texture`s can be created using the `Texture.from` API.\n * const baseTexture = new PIXI.BaseTexture(compressedResource, { pmaMode: PIXI.ALPHA_MODES.NPM });\n *\n * // Create a Texture to add to the TextureCache\n * const texture = new PIXI.Texture(baseTexture);\n *\n * // Add baseTexture & texture to the global texture cache\n * PIXI.BaseTexture.addToCache(baseTexture, \"bunny.dxt5\");\n * PIXI.Texture.addToCache(texture, \"bunny.dxt5\");\n * ```\n *\n * @memberof PIXI\n */\nvar CompressedTextureResource = /** @class */ (function (_super) {\n __extends(CompressedTextureResource, _super);\n /**\n * @param source - the buffer/URL holding the compressed texture data\n * @param options\n * @param {PIXI.INTERNAL_FORMATS} options.format - the compression format\n * @param {number} options.width - the image width in pixels.\n * @param {number} options.height - the image height in pixels.\n * @param {number} [options.level=1] - the mipmap levels stored in the compressed texture, including level 0.\n * @param {number} [options.levelBuffers] - the buffers for each mipmap level. `CompressedTextureResource` can allows you\n * to pass `null` for `source`, for cases where each level is stored in non-contiguous memory.\n */\n function CompressedTextureResource(source, options) {\n var _this = _super.call(this, source, options) || this;\n _this.format = options.format;\n _this.levels = options.levels || 1;\n _this._width = options.width;\n _this._height = options.height;\n _this._extension = CompressedTextureResource._formatToExtension(_this.format);\n if (options.levelBuffers || _this.buffer) {\n // ViewableBuffer doesn't support byteOffset :-( so allow source to be Uint8Array\n _this._levelBuffers = options.levelBuffers\n || CompressedTextureResource._createLevelBuffers(source instanceof Uint8Array ? source : _this.buffer.uint8View, _this.format, _this.levels, 4, 4, // PVRTC has 8x4 blocks in 2bpp mode\n _this.width, _this.height);\n }\n return _this;\n }\n /**\n * @override\n * @param renderer - A reference to the current renderer\n * @param _texture - the texture\n * @param _glTexture - texture instance for this webgl context\n */\n CompressedTextureResource.prototype.upload = function (renderer, _texture, _glTexture) {\n var gl = renderer.gl;\n var extension = renderer.context.extensions[this._extension];\n if (!extension) {\n throw new Error(this._extension + \" textures are not supported on the current machine\");\n }\n if (!this._levelBuffers) {\n // Do not try to upload data before BlobResource loads, unless the levelBuffers were provided directly!\n return false;\n }\n for (var i = 0, j = this.levels; i < j; i++) {\n var _a = this._levelBuffers[i], levelID = _a.levelID, levelWidth = _a.levelWidth, levelHeight = _a.levelHeight, levelBuffer = _a.levelBuffer;\n gl.compressedTexImage2D(gl.TEXTURE_2D, levelID, this.format, levelWidth, levelHeight, 0, levelBuffer);\n }\n return true;\n };\n /** @protected */\n CompressedTextureResource.prototype.onBlobLoaded = function () {\n this._levelBuffers = CompressedTextureResource._createLevelBuffers(this.buffer.uint8View, this.format, this.levels, 4, 4, // PVRTC has 8x4 blocks in 2bpp mode\n this.width, this.height);\n };\n /**\n * Returns the key (to ContextSystem#extensions) for the WebGL extension supporting the compression format\n *\n * @private\n * @param format - the compression format to get the extension for.\n */\n CompressedTextureResource._formatToExtension = function (format) {\n if (format >= 0x83F0 && format <= 0x83F3) {\n return 's3tc';\n }\n else if (format >= 0x9270 && format <= 0x9279) {\n return 'etc';\n }\n else if (format >= 0x8C00 && format <= 0x8C03) {\n return 'pvrtc';\n }\n else if (format >= 0x8D64) {\n return 'etc1';\n }\n else if (format >= 0x8C92 && format <= 0x87EE) {\n return 'atc';\n }\n throw new Error('Invalid (compressed) texture format given!');\n };\n /**\n * Pre-creates buffer views for each mipmap level\n *\n * @private\n * @param buffer -\n * @param format - compression formats\n * @param levels - mipmap levels\n * @param blockWidth -\n * @param blockHeight -\n * @param imageWidth - width of the image in pixels\n * @param imageHeight - height of the image in pixels\n */\n CompressedTextureResource._createLevelBuffers = function (buffer, format, levels, blockWidth, blockHeight, imageWidth, imageHeight) {\n // The byte-size of the first level buffer\n var buffers = new Array(levels);\n var offset = buffer.byteOffset;\n var levelWidth = imageWidth;\n var levelHeight = imageHeight;\n var alignedLevelWidth = (levelWidth + blockWidth - 1) & ~(blockWidth - 1);\n var alignedLevelHeight = (levelHeight + blockHeight - 1) & ~(blockHeight - 1);\n var levelSize = alignedLevelWidth * alignedLevelHeight * INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[format];\n for (var i = 0; i < levels; i++) {\n buffers[i] = {\n levelID: i,\n levelWidth: levels > 1 ? levelWidth : alignedLevelWidth,\n levelHeight: levels > 1 ? levelHeight : alignedLevelHeight,\n levelBuffer: new Uint8Array(buffer.buffer, offset, levelSize)\n };\n offset += levelSize;\n // Calculate levelBuffer dimensions for next iteration\n levelWidth = (levelWidth >> 1) || 1;\n levelHeight = (levelHeight >> 1) || 1;\n alignedLevelWidth = (levelWidth + blockWidth - 1) & ~(blockWidth - 1);\n alignedLevelHeight = (levelHeight + blockHeight - 1) & ~(blockHeight - 1);\n levelSize = alignedLevelWidth * alignedLevelHeight * INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[format];\n }\n return buffers;\n };\n return CompressedTextureResource;\n}(BlobResource));\n\n/* eslint-enable camelcase */\n/**\n * Loader plugin for handling compressed textures for all platforms.\n *\n * @class\n * @memberof PIXI\n * @implements PIXI.ILoaderPlugin\n */\nvar CompressedTextureLoader = /** @class */ (function () {\n function CompressedTextureLoader() {\n }\n /**\n * Called after a compressed-textures manifest is loaded.\n *\n * This will then load the correct compression format for the device. Your manifest should adhere\n * to the following schema:\n *\n * ```js\n * import { INTERNAL_FORMATS } from '@pixi/constants';\n *\n * type CompressedTextureManifest = {\n * textures: Array<{ src: string, format?: keyof INTERNAL_FORMATS}>,\n * cacheID: string;\n * };\n * ```\n *\n * This is an example of a .json manifest file\n *\n * ```json\n * {\n * \"cacheID\":\"asset\",\n * \"textures\":[\n * { \"src\":\"asset.fallback.png\" },\n * { \"format\":\"COMPRESSED_RGBA_S3TC_DXT5_EXT\", \"src\":\"asset.s3tc.ktx\" },\n * { \"format\":\"COMPRESSED_RGBA8_ETC2_EAC\", \"src\":\"asset.etc.ktx\" },\n * { \"format\":\"RGBA_PVRTC_4BPPV1_IMG\", \"src\":\"asset.pvrtc.ktx\" }\n * ]\n * }\n * ```\n */\n CompressedTextureLoader.use = function (resource, next) {\n var data = resource.data;\n var loader = this;\n if (resource.type === LoaderResource.TYPE.JSON\n && data\n && data.cacheID\n && data.textures) {\n var textures = data.textures;\n var textureURL = void 0;\n var fallbackURL = void 0;\n // Search for an extension that holds one the formats\n for (var i = 0, j = textures.length; i < j; i++) {\n var texture = textures[i];\n var url_1 = texture.src;\n var format = texture.format;\n if (!format) {\n fallbackURL = url_1;\n }\n if (CompressedTextureLoader.textureFormats[format]) {\n textureURL = url_1;\n break;\n }\n }\n textureURL = textureURL || fallbackURL;\n // Make sure we have a URL\n if (!textureURL) {\n next(new Error(\"Cannot load compressed-textures in \" + resource.url + \", make sure you provide a fallback\"));\n return;\n }\n if (textureURL === resource.url) {\n // Prevent infinite loops\n next(new Error('URL of compressed texture cannot be the same as the manifest\\'s URL'));\n return;\n }\n var loadOptions = {\n crossOrigin: resource.crossOrigin,\n metadata: resource.metadata.imageMetadata,\n parentResource: resource\n };\n var resourcePath = url.resolve(resource.url.replace(loader.baseUrl, ''), textureURL);\n var resourceName = data.cacheID;\n // The appropriate loader should register the texture\n loader.add(resourceName, resourcePath, loadOptions, function (res) {\n if (res.error) {\n next(res.error);\n return;\n }\n var _a = res.texture, texture = _a === void 0 ? null : _a, _b = res.textures, textures = _b === void 0 ? {} : _b;\n // Make sure texture/textures is assigned to parent resource\n Object.assign(resource, { texture: texture, textures: textures });\n // Pass along any error\n next();\n });\n }\n else {\n next();\n }\n };\n /**\n * Detects the available compressed texture extensions on the device.\n * @ignore\n */\n CompressedTextureLoader.add = function () {\n // Auto-detect WebGL compressed-texture extensions\n var canvas = document.createElement('canvas');\n var gl = canvas.getContext('webgl');\n if (!gl) {\n console.warn('WebGL not available for compressed textures. Silently failing.');\n return;\n }\n var extensions = {\n s3tc: gl.getExtension('WEBGL_compressed_texture_s3tc'),\n s3tc_sRGB: gl.getExtension('WEBGL_compressed_texture_s3tc_srgb'),\n etc: gl.getExtension('WEBGL_compressed_texture_etc'),\n etc1: gl.getExtension('WEBGL_compressed_texture_etc1'),\n pvrtc: gl.getExtension('WEBGL_compressed_texture_pvrtc')\n || gl.getExtension('WEBKIT_WEBGL_compressed_texture_pvrtc'),\n atc: gl.getExtension('WEBGL_compressed_texture_atc'),\n astc: gl.getExtension('WEBGL_compressed_texture_astc')\n };\n CompressedTextureLoader.textureExtensions = extensions;\n CompressedTextureLoader.textureFormats = {};\n // Assign all available compressed-texture formats\n for (var extensionName in extensions) {\n var extension = extensions[extensionName];\n if (!extension) {\n continue;\n }\n Object.assign(CompressedTextureLoader.textureFormats, Object.getPrototypeOf(extension));\n }\n };\n return CompressedTextureLoader;\n}());\n\n/**\n * Creates base-textures and textures for each compressed-texture resource and adds them into the global\n * texture cache. The first texture has two IDs - `${url}`, `${url}-1`; while the rest have an ID of the\n * form `${url}-i`.\n *\n * @param url - the original address of the resources\n * @param resources - the resources backing texture data\n * @ignore\n */\nfunction registerCompressedTextures(url, resources, metadata) {\n var result = {\n textures: {},\n texture: null,\n };\n if (!resources) {\n return result;\n }\n var textures = resources.map(function (resource) {\n return (new Texture(new BaseTexture(resource, Object.assign({\n mipmap: MIPMAP_MODES.OFF,\n alphaMode: ALPHA_MODES.NO_PREMULTIPLIED_ALPHA\n }, metadata))));\n });\n textures.forEach(function (texture, i) {\n var baseTexture = texture.baseTexture;\n var cacheID = url + \"-\" + (i + 1);\n BaseTexture.addToCache(baseTexture, cacheID);\n Texture.addToCache(texture, cacheID);\n if (i === 0) {\n BaseTexture.addToCache(baseTexture, url);\n Texture.addToCache(texture, url);\n result.texture = texture;\n }\n result.textures[cacheID] = texture;\n });\n return result;\n}\n\nvar _a$1, _b;\n// Set DDS files to be loaded as an ArrayBuffer\nLoaderResource.setExtensionXhrType('dds', LoaderResource.XHR_RESPONSE_TYPE.BUFFER);\nvar DDS_MAGIC_SIZE = 4;\nvar DDS_HEADER_SIZE = 124;\nvar DDS_HEADER_PF_SIZE = 32;\nvar DDS_HEADER_DX10_SIZE = 20;\n// DDS file format magic word\nvar DDS_MAGIC = 0x20534444;\n/**\n * DWORD offsets of the DDS file header fields (relative to file start).\n *\n * @ignore\n */\nvar DDS_FIELDS = {\n SIZE: 1,\n FLAGS: 2,\n HEIGHT: 3,\n WIDTH: 4,\n MIPMAP_COUNT: 7,\n PIXEL_FORMAT: 19,\n};\n/**\n * DWORD offsets of the DDS PIXEL_FORMAT fields.\n *\n * @ignore\n */\nvar DDS_PF_FIELDS = {\n SIZE: 0,\n FLAGS: 1,\n FOURCC: 2,\n RGB_BITCOUNT: 3,\n R_BIT_MASK: 4,\n G_BIT_MASK: 5,\n B_BIT_MASK: 6,\n A_BIT_MASK: 7\n};\n/**\n * DWORD offsets of the DDS_HEADER_DX10 fields.\n *\n * @ignore\n */\nvar DDS_DX10_FIELDS = {\n DXGI_FORMAT: 0,\n RESOURCE_DIMENSION: 1,\n MISC_FLAG: 2,\n ARRAY_SIZE: 3,\n MISC_FLAGS2: 4\n};\n/**\n * @see https://docs.microsoft.com/en-us/windows/win32/api/dxgiformat/ne-dxgiformat-dxgi_format\n * @ignore\n */\n// This is way over-blown for us! Lend us a hand, and remove the ones that aren't used (but set the remaining\n// ones to their correct value)\nvar DXGI_FORMAT;\n(function (DXGI_FORMAT) {\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_UNKNOWN\"] = 0] = \"DXGI_FORMAT_UNKNOWN\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_TYPELESS\"] = 1] = \"DXGI_FORMAT_R32G32B32A32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_FLOAT\"] = 2] = \"DXGI_FORMAT_R32G32B32A32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_UINT\"] = 3] = \"DXGI_FORMAT_R32G32B32A32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_SINT\"] = 4] = \"DXGI_FORMAT_R32G32B32A32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_TYPELESS\"] = 5] = \"DXGI_FORMAT_R32G32B32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_FLOAT\"] = 6] = \"DXGI_FORMAT_R32G32B32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_UINT\"] = 7] = \"DXGI_FORMAT_R32G32B32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_SINT\"] = 8] = \"DXGI_FORMAT_R32G32B32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_TYPELESS\"] = 9] = \"DXGI_FORMAT_R16G16B16A16_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_FLOAT\"] = 10] = \"DXGI_FORMAT_R16G16B16A16_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_UNORM\"] = 11] = \"DXGI_FORMAT_R16G16B16A16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_UINT\"] = 12] = \"DXGI_FORMAT_R16G16B16A16_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_SNORM\"] = 13] = \"DXGI_FORMAT_R16G16B16A16_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_SINT\"] = 14] = \"DXGI_FORMAT_R16G16B16A16_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_TYPELESS\"] = 15] = \"DXGI_FORMAT_R32G32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_FLOAT\"] = 16] = \"DXGI_FORMAT_R32G32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_UINT\"] = 17] = \"DXGI_FORMAT_R32G32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_SINT\"] = 18] = \"DXGI_FORMAT_R32G32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G8X24_TYPELESS\"] = 19] = \"DXGI_FORMAT_R32G8X24_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D32_FLOAT_S8X24_UINT\"] = 20] = \"DXGI_FORMAT_D32_FLOAT_S8X24_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS\"] = 21] = \"DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_X32_TYPELESS_G8X24_UINT\"] = 22] = \"DXGI_FORMAT_X32_TYPELESS_G8X24_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10A2_TYPELESS\"] = 23] = \"DXGI_FORMAT_R10G10B10A2_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10A2_UNORM\"] = 24] = \"DXGI_FORMAT_R10G10B10A2_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10A2_UINT\"] = 25] = \"DXGI_FORMAT_R10G10B10A2_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R11G11B10_FLOAT\"] = 26] = \"DXGI_FORMAT_R11G11B10_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_TYPELESS\"] = 27] = \"DXGI_FORMAT_R8G8B8A8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_UNORM\"] = 28] = \"DXGI_FORMAT_R8G8B8A8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_UNORM_SRGB\"] = 29] = \"DXGI_FORMAT_R8G8B8A8_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_UINT\"] = 30] = \"DXGI_FORMAT_R8G8B8A8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_SNORM\"] = 31] = \"DXGI_FORMAT_R8G8B8A8_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_SINT\"] = 32] = \"DXGI_FORMAT_R8G8B8A8_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_TYPELESS\"] = 33] = \"DXGI_FORMAT_R16G16_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_FLOAT\"] = 34] = \"DXGI_FORMAT_R16G16_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_UNORM\"] = 35] = \"DXGI_FORMAT_R16G16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_UINT\"] = 36] = \"DXGI_FORMAT_R16G16_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_SNORM\"] = 37] = \"DXGI_FORMAT_R16G16_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_SINT\"] = 38] = \"DXGI_FORMAT_R16G16_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_TYPELESS\"] = 39] = \"DXGI_FORMAT_R32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D32_FLOAT\"] = 40] = \"DXGI_FORMAT_D32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_FLOAT\"] = 41] = \"DXGI_FORMAT_R32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_UINT\"] = 42] = \"DXGI_FORMAT_R32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_SINT\"] = 43] = \"DXGI_FORMAT_R32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R24G8_TYPELESS\"] = 44] = \"DXGI_FORMAT_R24G8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D24_UNORM_S8_UINT\"] = 45] = \"DXGI_FORMAT_D24_UNORM_S8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R24_UNORM_X8_TYPELESS\"] = 46] = \"DXGI_FORMAT_R24_UNORM_X8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_X24_TYPELESS_G8_UINT\"] = 47] = \"DXGI_FORMAT_X24_TYPELESS_G8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_TYPELESS\"] = 48] = \"DXGI_FORMAT_R8G8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_UNORM\"] = 49] = \"DXGI_FORMAT_R8G8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_UINT\"] = 50] = \"DXGI_FORMAT_R8G8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_SNORM\"] = 51] = \"DXGI_FORMAT_R8G8_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_SINT\"] = 52] = \"DXGI_FORMAT_R8G8_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_TYPELESS\"] = 53] = \"DXGI_FORMAT_R16_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_FLOAT\"] = 54] = \"DXGI_FORMAT_R16_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D16_UNORM\"] = 55] = \"DXGI_FORMAT_D16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_UNORM\"] = 56] = \"DXGI_FORMAT_R16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_UINT\"] = 57] = \"DXGI_FORMAT_R16_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_SNORM\"] = 58] = \"DXGI_FORMAT_R16_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_SINT\"] = 59] = \"DXGI_FORMAT_R16_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_TYPELESS\"] = 60] = \"DXGI_FORMAT_R8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_UNORM\"] = 61] = \"DXGI_FORMAT_R8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_UINT\"] = 62] = \"DXGI_FORMAT_R8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_SNORM\"] = 63] = \"DXGI_FORMAT_R8_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_SINT\"] = 64] = \"DXGI_FORMAT_R8_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_A8_UNORM\"] = 65] = \"DXGI_FORMAT_A8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R1_UNORM\"] = 66] = \"DXGI_FORMAT_R1_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R9G9B9E5_SHAREDEXP\"] = 67] = \"DXGI_FORMAT_R9G9B9E5_SHAREDEXP\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_B8G8_UNORM\"] = 68] = \"DXGI_FORMAT_R8G8_B8G8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_G8R8_G8B8_UNORM\"] = 69] = \"DXGI_FORMAT_G8R8_G8B8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC1_TYPELESS\"] = 70] = \"DXGI_FORMAT_BC1_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC1_UNORM\"] = 71] = \"DXGI_FORMAT_BC1_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC1_UNORM_SRGB\"] = 72] = \"DXGI_FORMAT_BC1_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC2_TYPELESS\"] = 73] = \"DXGI_FORMAT_BC2_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC2_UNORM\"] = 74] = \"DXGI_FORMAT_BC2_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC2_UNORM_SRGB\"] = 75] = \"DXGI_FORMAT_BC2_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC3_TYPELESS\"] = 76] = \"DXGI_FORMAT_BC3_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC3_UNORM\"] = 77] = \"DXGI_FORMAT_BC3_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC3_UNORM_SRGB\"] = 78] = \"DXGI_FORMAT_BC3_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC4_TYPELESS\"] = 79] = \"DXGI_FORMAT_BC4_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC4_UNORM\"] = 80] = \"DXGI_FORMAT_BC4_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC4_SNORM\"] = 81] = \"DXGI_FORMAT_BC4_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC5_TYPELESS\"] = 82] = \"DXGI_FORMAT_BC5_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC5_UNORM\"] = 83] = \"DXGI_FORMAT_BC5_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC5_SNORM\"] = 84] = \"DXGI_FORMAT_BC5_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B5G6R5_UNORM\"] = 85] = \"DXGI_FORMAT_B5G6R5_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B5G5R5A1_UNORM\"] = 86] = \"DXGI_FORMAT_B5G5R5A1_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8A8_UNORM\"] = 87] = \"DXGI_FORMAT_B8G8R8A8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8X8_UNORM\"] = 88] = \"DXGI_FORMAT_B8G8R8X8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM\"] = 89] = \"DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8A8_TYPELESS\"] = 90] = \"DXGI_FORMAT_B8G8R8A8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8A8_UNORM_SRGB\"] = 91] = \"DXGI_FORMAT_B8G8R8A8_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8X8_TYPELESS\"] = 92] = \"DXGI_FORMAT_B8G8R8X8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8X8_UNORM_SRGB\"] = 93] = \"DXGI_FORMAT_B8G8R8X8_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC6H_TYPELESS\"] = 94] = \"DXGI_FORMAT_BC6H_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC6H_UF16\"] = 95] = \"DXGI_FORMAT_BC6H_UF16\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC6H_SF16\"] = 96] = \"DXGI_FORMAT_BC6H_SF16\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC7_TYPELESS\"] = 97] = \"DXGI_FORMAT_BC7_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC7_UNORM\"] = 98] = \"DXGI_FORMAT_BC7_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC7_UNORM_SRGB\"] = 99] = \"DXGI_FORMAT_BC7_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_AYUV\"] = 100] = \"DXGI_FORMAT_AYUV\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y410\"] = 101] = \"DXGI_FORMAT_Y410\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y416\"] = 102] = \"DXGI_FORMAT_Y416\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_NV12\"] = 103] = \"DXGI_FORMAT_NV12\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P010\"] = 104] = \"DXGI_FORMAT_P010\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P016\"] = 105] = \"DXGI_FORMAT_P016\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_420_OPAQUE\"] = 106] = \"DXGI_FORMAT_420_OPAQUE\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_YUY2\"] = 107] = \"DXGI_FORMAT_YUY2\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y210\"] = 108] = \"DXGI_FORMAT_Y210\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y216\"] = 109] = \"DXGI_FORMAT_Y216\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_NV11\"] = 110] = \"DXGI_FORMAT_NV11\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_AI44\"] = 111] = \"DXGI_FORMAT_AI44\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_IA44\"] = 112] = \"DXGI_FORMAT_IA44\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P8\"] = 113] = \"DXGI_FORMAT_P8\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_A8P8\"] = 114] = \"DXGI_FORMAT_A8P8\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B4G4R4A4_UNORM\"] = 115] = \"DXGI_FORMAT_B4G4R4A4_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P208\"] = 116] = \"DXGI_FORMAT_P208\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_V208\"] = 117] = \"DXGI_FORMAT_V208\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_V408\"] = 118] = \"DXGI_FORMAT_V408\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE\"] = 119] = \"DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE\"] = 120] = \"DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_FORCE_UINT\"] = 121] = \"DXGI_FORMAT_FORCE_UINT\";\n})(DXGI_FORMAT || (DXGI_FORMAT = {}));\n/**\n * Possible values of the field {@link DDS_DX10_FIELDS.RESOURCE_DIMENSION}\n *\n * @ignore\n */\nvar D3D10_RESOURCE_DIMENSION;\n(function (D3D10_RESOURCE_DIMENSION) {\n D3D10_RESOURCE_DIMENSION[D3D10_RESOURCE_DIMENSION[\"DDS_DIMENSION_TEXTURE1D\"] = 2] = \"DDS_DIMENSION_TEXTURE1D\";\n D3D10_RESOURCE_DIMENSION[D3D10_RESOURCE_DIMENSION[\"DDS_DIMENSION_TEXTURE2D\"] = 3] = \"DDS_DIMENSION_TEXTURE2D\";\n D3D10_RESOURCE_DIMENSION[D3D10_RESOURCE_DIMENSION[\"DDS_DIMENSION_TEXTURE3D\"] = 6] = \"DDS_DIMENSION_TEXTURE3D\";\n})(D3D10_RESOURCE_DIMENSION || (D3D10_RESOURCE_DIMENSION = {}));\nvar PF_FLAGS = 1;\n// PIXEL_FORMAT flags\nvar DDPF_ALPHA = 0x2;\nvar DDPF_FOURCC = 0x4;\nvar DDPF_RGB = 0x40;\nvar DDPF_YUV = 0x200;\nvar DDPF_LUMINANCE = 0x20000;\n// Four character codes for DXTn formats\nvar FOURCC_DXT1 = 0x31545844;\nvar FOURCC_DXT3 = 0x33545844;\nvar FOURCC_DXT5 = 0x35545844;\nvar FOURCC_DX10 = 0x30315844;\n// Cubemap texture flag (for DDS_DX10_FIELDS.MISC_FLAG)\nvar DDS_RESOURCE_MISC_TEXTURECUBE = 0x4;\n/**\n * Maps `FOURCC_*` formats to internal formats (see {@link PIXI.INTERNAL_FORMATS}).\n *\n * @ignore\n */\nvar FOURCC_TO_FORMAT = (_a$1 = {},\n _a$1[FOURCC_DXT1] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT,\n _a$1[FOURCC_DXT3] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT,\n _a$1[FOURCC_DXT5] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n _a$1);\n/**\n * Maps {@link DXGI_FORMAT} to types/internal-formats (see {@link PIXI.TYPES}, {@link PIXI.INTERNAL_FORMATS})\n *\n * @ignore\n */\nvar DXGI_TO_FORMAT = (_b = {},\n // WEBGL_compressed_texture_s3tc\n _b[DXGI_FORMAT.DXGI_FORMAT_BC1_TYPELESS] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC1_UNORM] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC2_TYPELESS] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC2_UNORM] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC3_TYPELESS] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC3_UNORM] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n // WEBGL_compressed_texture_s3tc_srgb\n _b[DXGI_FORMAT.DXGI_FORMAT_BC1_UNORM_SRGB] = INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC2_UNORM_SRGB] = INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC3_UNORM_SRGB] = INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT,\n _b);\n/**\n * @class\n * @memberof PIXI\n * @implements PIXI.ILoaderPlugin\n * @see https://docs.microsoft.com/en-us/windows/win32/direct3ddds/dx-graphics-dds-pguide\n */\nvar DDSLoader = /** @class */ (function () {\n function DDSLoader() {\n }\n /**\n * Registers a DDS compressed texture\n * @see PIXI.Loader.loaderMiddleware\n * @param resource - loader resource that is checked to see if it is a DDS file\n * @param next - callback Function to call when done\n */\n DDSLoader.use = function (resource, next) {\n if (resource.extension === 'dds' && resource.data) {\n try {\n Object.assign(resource, registerCompressedTextures(resource.name || resource.url, DDSLoader.parse(resource.data), resource.metadata));\n }\n catch (err) {\n next(err);\n return;\n }\n }\n next();\n };\n /** Parses the DDS file header, generates base-textures, and puts them into the texture cache. */\n DDSLoader.parse = function (arrayBuffer) {\n var data = new Uint32Array(arrayBuffer);\n var magicWord = data[0];\n if (magicWord !== DDS_MAGIC) {\n throw new Error('Invalid DDS file magic word');\n }\n var header = new Uint32Array(arrayBuffer, 0, DDS_HEADER_SIZE / Uint32Array.BYTES_PER_ELEMENT);\n // DDS header fields\n var height = header[DDS_FIELDS.HEIGHT];\n var width = header[DDS_FIELDS.WIDTH];\n var mipmapCount = header[DDS_FIELDS.MIPMAP_COUNT];\n // PIXEL_FORMAT fields\n var pixelFormat = new Uint32Array(arrayBuffer, DDS_FIELDS.PIXEL_FORMAT * Uint32Array.BYTES_PER_ELEMENT, DDS_HEADER_PF_SIZE / Uint32Array.BYTES_PER_ELEMENT);\n var formatFlags = pixelFormat[PF_FLAGS];\n // File contains compressed texture(s)\n if (formatFlags & DDPF_FOURCC) {\n var fourCC = pixelFormat[DDS_PF_FIELDS.FOURCC];\n // File contains one DXTn compressed texture\n if (fourCC !== FOURCC_DX10) {\n var internalFormat_1 = FOURCC_TO_FORMAT[fourCC];\n var dataOffset_1 = DDS_MAGIC_SIZE + DDS_HEADER_SIZE;\n var texData = new Uint8Array(arrayBuffer, dataOffset_1);\n var resource = new CompressedTextureResource(texData, {\n format: internalFormat_1,\n width: width,\n height: height,\n levels: mipmapCount // CompressedTextureResource will separate the levelBuffers for us!\n });\n return [resource];\n }\n // FOURCC_DX10 indicates there is a 20-byte DDS_HEADER_DX10 after DDS_HEADER\n var dx10Offset = DDS_MAGIC_SIZE + DDS_HEADER_SIZE;\n var dx10Header = new Uint32Array(data.buffer, dx10Offset, DDS_HEADER_DX10_SIZE / Uint32Array.BYTES_PER_ELEMENT);\n var dxgiFormat = dx10Header[DDS_DX10_FIELDS.DXGI_FORMAT];\n var resourceDimension = dx10Header[DDS_DX10_FIELDS.RESOURCE_DIMENSION];\n var miscFlag = dx10Header[DDS_DX10_FIELDS.MISC_FLAG];\n var arraySize = dx10Header[DDS_DX10_FIELDS.ARRAY_SIZE];\n // Map dxgiFormat to PIXI.INTERNAL_FORMATS\n var internalFormat_2 = DXGI_TO_FORMAT[dxgiFormat];\n if (internalFormat_2 === undefined) {\n throw new Error(\"DDSLoader cannot parse texture data with DXGI format \" + dxgiFormat);\n }\n if (miscFlag === DDS_RESOURCE_MISC_TEXTURECUBE) {\n // FIXME: Anybody excited about cubemap compressed textures?\n throw new Error('DDSLoader does not support cubemap textures');\n }\n if (resourceDimension === D3D10_RESOURCE_DIMENSION.DDS_DIMENSION_TEXTURE3D) {\n // FIXME: Anybody excited about 3D compressed textures?\n throw new Error('DDSLoader does not supported 3D texture data');\n }\n // Uint8Array buffers of image data, including all mipmap levels in each image\n var imageBuffers = new Array();\n var dataOffset = DDS_MAGIC_SIZE\n + DDS_HEADER_SIZE\n + DDS_HEADER_DX10_SIZE;\n if (arraySize === 1) {\n // No need bothering with the imageSize calculation!\n imageBuffers.push(new Uint8Array(arrayBuffer, dataOffset));\n }\n else {\n // Calculate imageSize for each texture, and then locate each image's texture data\n var pixelSize = INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[internalFormat_2];\n var imageSize = 0;\n var levelWidth = width;\n var levelHeight = height;\n for (var i = 0; i < mipmapCount; i++) {\n var alignedLevelWidth = Math.max(1, (levelWidth + 3) & ~3);\n var alignedLevelHeight = Math.max(1, (levelHeight + 3) & ~3);\n var levelSize = alignedLevelWidth * alignedLevelHeight * pixelSize;\n imageSize += levelSize;\n levelWidth = levelWidth >>> 1;\n levelHeight = levelHeight >>> 1;\n }\n var imageOffset = dataOffset;\n // NOTE: Cubemaps have 6-images per texture (but they aren't supported so ^_^)\n for (var i = 0; i < arraySize; i++) {\n imageBuffers.push(new Uint8Array(arrayBuffer, imageOffset, imageSize));\n imageOffset += imageSize;\n }\n }\n // Uint8Array -> CompressedTextureResource, and we're done!\n return imageBuffers.map(function (buffer) { return new CompressedTextureResource(buffer, {\n format: internalFormat_2,\n width: width,\n height: height,\n levels: mipmapCount\n }); });\n }\n if (formatFlags & DDPF_RGB) {\n // FIXME: We might want to allow uncompressed *.dds files?\n throw new Error('DDSLoader does not support uncompressed texture data.');\n }\n if (formatFlags & DDPF_YUV) {\n // FIXME: Does anybody need this feature?\n throw new Error('DDSLoader does not supported YUV uncompressed texture data.');\n }\n if (formatFlags & DDPF_LUMINANCE) {\n // FIXME: Microsoft says older DDS filers use this feature! Probably not worth the effort!\n throw new Error('DDSLoader does not support single-channel (lumninance) texture data!');\n }\n if (formatFlags & DDPF_ALPHA) {\n // FIXME: I'm tired! See above =)\n throw new Error('DDSLoader does not support single-channel (alpha) texture data!');\n }\n throw new Error('DDSLoader failed to load a texture file due to an unknown reason!');\n };\n return DDSLoader;\n}());\n\nvar _a$2, _b$1, _c;\n// Set KTX files to be loaded as an ArrayBuffer\nLoaderResource.setExtensionXhrType('ktx', LoaderResource.XHR_RESPONSE_TYPE.BUFFER);\n/**\n * The 12-byte KTX file identifier\n *\n * @see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/#2.1\n * @ignore\n */\nvar FILE_IDENTIFIER = [0xAB, 0x4B, 0x54, 0x58, 0x20, 0x31, 0x31, 0xBB, 0x0D, 0x0A, 0x1A, 0x0A];\n/**\n * The value stored in the \"endianness\" field.\n *\n * @see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/#2.2\n * @ignore\n */\nvar ENDIANNESS = 0x04030201;\n/**\n * Byte offsets of the KTX file header fields\n *\n * @ignore\n */\nvar KTX_FIELDS = {\n FILE_IDENTIFIER: 0,\n ENDIANNESS: 12,\n GL_TYPE: 16,\n GL_TYPE_SIZE: 20,\n GL_FORMAT: 24,\n GL_INTERNAL_FORMAT: 28,\n GL_BASE_INTERNAL_FORMAT: 32,\n PIXEL_WIDTH: 36,\n PIXEL_HEIGHT: 40,\n PIXEL_DEPTH: 44,\n NUMBER_OF_ARRAY_ELEMENTS: 48,\n NUMBER_OF_FACES: 52,\n NUMBER_OF_MIPMAP_LEVELS: 56,\n BYTES_OF_KEY_VALUE_DATA: 60\n};\n/**\n * Byte size of the file header fields in {@code KTX_FIELDS}\n *\n * @ignore\n */\nvar FILE_HEADER_SIZE = 64;\n/**\n * Maps {@link PIXI.TYPES} to the bytes taken per component, excluding those ones that are bit-fields.\n *\n * @ignore\n */\nvar TYPES_TO_BYTES_PER_COMPONENT = (_a$2 = {},\n _a$2[TYPES.UNSIGNED_BYTE] = 1,\n _a$2[TYPES.UNSIGNED_SHORT] = 2,\n _a$2[TYPES.INT] = 4,\n _a$2[TYPES.UNSIGNED_INT] = 4,\n _a$2[TYPES.FLOAT] = 4,\n _a$2[TYPES.HALF_FLOAT] = 8,\n _a$2);\n/**\n * Number of components in each {@link PIXI.FORMATS}\n *\n * @ignore\n */\nvar FORMATS_TO_COMPONENTS = (_b$1 = {},\n _b$1[FORMATS.RGBA] = 4,\n _b$1[FORMATS.RGB] = 3,\n _b$1[FORMATS.RG] = 2,\n _b$1[FORMATS.RED] = 1,\n _b$1[FORMATS.LUMINANCE] = 1,\n _b$1[FORMATS.LUMINANCE_ALPHA] = 2,\n _b$1[FORMATS.ALPHA] = 1,\n _b$1);\n/**\n * Number of bytes per pixel in bit-field types in {@link PIXI.TYPES}\n *\n * @ignore\n */\nvar TYPES_TO_BYTES_PER_PIXEL = (_c = {},\n _c[TYPES.UNSIGNED_SHORT_4_4_4_4] = 2,\n _c[TYPES.UNSIGNED_SHORT_5_5_5_1] = 2,\n _c[TYPES.UNSIGNED_SHORT_5_6_5] = 2,\n _c);\n/**\n * Loader plugin for handling KTX texture container files.\n *\n * This KTX loader does not currently support the following features:\n * * cube textures\n * * 3D textures\n * * vendor-specific key/value data parsing\n * * endianness conversion for big-endian machines\n * * embedded *.basis files\n *\n * It does supports the following features:\n * * multiple textures per file\n * * mipmapping (only for compressed formats)\n *\n * @class\n * @memberof PIXI\n * @implements PIXI.ILoaderPlugin\n */\nvar KTXLoader = /** @class */ (function () {\n function KTXLoader() {\n }\n /**\n * Called after a KTX file is loaded.\n *\n * This will parse the KTX file header and add a {@code BaseTexture} to the texture\n * cache.\n *\n * @see PIXI.Loader.loaderMiddleware\n * @param resource - loader resource that is checked to see if it is a KTX file\n * @param next - callback Function to call when done\n */\n KTXLoader.use = function (resource, next) {\n if (resource.extension === 'ktx' && resource.data) {\n try {\n var url_1 = resource.name || resource.url;\n var _a = KTXLoader.parse(url_1, resource.data), compressed = _a.compressed, uncompressed = _a.uncompressed;\n if (compressed) {\n Object.assign(resource, registerCompressedTextures(url_1, compressed, resource.metadata));\n }\n else if (uncompressed) {\n var textures_1 = {};\n uncompressed.forEach(function (image, i) {\n var texture = new Texture(new BaseTexture(image.resource, {\n mipmap: MIPMAP_MODES.OFF,\n alphaMode: ALPHA_MODES.NO_PREMULTIPLIED_ALPHA,\n type: image.type,\n format: image.format,\n }));\n var cacheID = url_1 + \"-\" + (i + 1);\n BaseTexture.addToCache(texture.baseTexture, cacheID);\n Texture.addToCache(texture, cacheID);\n if (i === 0) {\n textures_1[url_1] = texture;\n BaseTexture.addToCache(texture.baseTexture, url_1);\n Texture.addToCache(texture, url_1);\n }\n textures_1[cacheID] = texture;\n });\n Object.assign(resource, { textures: textures_1 });\n }\n }\n catch (err) {\n next(err);\n return;\n }\n }\n next();\n };\n /** Parses the KTX file header, generates base-textures, and puts them into the texture cache. */\n KTXLoader.parse = function (url, arrayBuffer) {\n var dataView = new DataView(arrayBuffer);\n if (!KTXLoader.validate(url, dataView)) {\n return null;\n }\n var littleEndian = dataView.getUint32(KTX_FIELDS.ENDIANNESS, true) === ENDIANNESS;\n var glType = dataView.getUint32(KTX_FIELDS.GL_TYPE, littleEndian);\n // const glTypeSize = dataView.getUint32(KTX_FIELDS.GL_TYPE_SIZE, littleEndian);\n var glFormat = dataView.getUint32(KTX_FIELDS.GL_FORMAT, littleEndian);\n var glInternalFormat = dataView.getUint32(KTX_FIELDS.GL_INTERNAL_FORMAT, littleEndian);\n var pixelWidth = dataView.getUint32(KTX_FIELDS.PIXEL_WIDTH, littleEndian);\n var pixelHeight = dataView.getUint32(KTX_FIELDS.PIXEL_HEIGHT, littleEndian) || 1; // \"pixelHeight = 0\" -> \"1\"\n var pixelDepth = dataView.getUint32(KTX_FIELDS.PIXEL_DEPTH, littleEndian) || 1; // ^^\n var numberOfArrayElements = dataView.getUint32(KTX_FIELDS.NUMBER_OF_ARRAY_ELEMENTS, littleEndian) || 1; // ^^\n var numberOfFaces = dataView.getUint32(KTX_FIELDS.NUMBER_OF_FACES, littleEndian);\n var numberOfMipmapLevels = dataView.getUint32(KTX_FIELDS.NUMBER_OF_MIPMAP_LEVELS, littleEndian);\n var bytesOfKeyValueData = dataView.getUint32(KTX_FIELDS.BYTES_OF_KEY_VALUE_DATA, littleEndian);\n // Whether the platform architecture is little endian. If littleEndian !== platformLittleEndian, then the\n // file contents must be endian-converted!\n // TODO: Endianness conversion\n // const platformLittleEndian = new Uint8Array((new Uint32Array([ENDIANNESS])).buffer)[0] === 0x01;\n if (pixelHeight === 0 || pixelDepth !== 1) {\n throw new Error('Only 2D textures are supported');\n }\n if (numberOfFaces !== 1) {\n throw new Error('CubeTextures are not supported by KTXLoader yet!');\n }\n if (numberOfArrayElements !== 1) {\n // TODO: Support splitting array-textures into multiple BaseTextures\n throw new Error('WebGL does not support array textures');\n }\n // TODO: 8x4 blocks for 2bpp pvrtc\n var blockWidth = 4;\n var blockHeight = 4;\n var alignedWidth = (pixelWidth + 3) & ~3;\n var alignedHeight = (pixelHeight + 3) & ~3;\n var imageBuffers = new Array(numberOfArrayElements);\n var imagePixels = pixelWidth * pixelHeight;\n if (glType === 0) {\n // Align to 16 pixels (4x4 blocks)\n imagePixels = alignedWidth * alignedHeight;\n }\n var imagePixelByteSize;\n if (glType !== 0) {\n // Uncompressed texture format\n if (TYPES_TO_BYTES_PER_COMPONENT[glType]) {\n imagePixelByteSize = TYPES_TO_BYTES_PER_COMPONENT[glType] * FORMATS_TO_COMPONENTS[glFormat];\n }\n else {\n imagePixelByteSize = TYPES_TO_BYTES_PER_PIXEL[glType];\n }\n }\n else {\n imagePixelByteSize = INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[glInternalFormat];\n }\n if (imagePixelByteSize === undefined) {\n throw new Error('Unable to resolve the pixel format stored in the *.ktx file!');\n }\n var imageByteSize = imagePixels * imagePixelByteSize;\n var mipByteSize = imageByteSize;\n var mipWidth = pixelWidth;\n var mipHeight = pixelHeight;\n var alignedMipWidth = alignedWidth;\n var alignedMipHeight = alignedHeight;\n var imageOffset = FILE_HEADER_SIZE + bytesOfKeyValueData;\n for (var mipmapLevel = 0; mipmapLevel < numberOfMipmapLevels; mipmapLevel++) {\n var imageSize = dataView.getUint32(imageOffset, littleEndian);\n var elementOffset = imageOffset + 4;\n for (var arrayElement = 0; arrayElement < numberOfArrayElements; arrayElement++) {\n // TODO: Maybe support 3D textures? :-)\n // for (let zSlice = 0; zSlice < pixelDepth; zSlice)\n var mips = imageBuffers[arrayElement];\n if (!mips) {\n mips = imageBuffers[arrayElement] = new Array(numberOfMipmapLevels);\n }\n mips[mipmapLevel] = {\n levelID: mipmapLevel,\n // don't align mipWidth when texture not compressed! (glType not zero)\n levelWidth: numberOfMipmapLevels > 1 || glType !== 0 ? mipWidth : alignedMipWidth,\n levelHeight: numberOfMipmapLevels > 1 || glType !== 0 ? mipHeight : alignedMipHeight,\n levelBuffer: new Uint8Array(arrayBuffer, elementOffset, mipByteSize)\n };\n elementOffset += mipByteSize;\n }\n // HINT: Aligns to 4-byte boundary after jumping imageSize (in lieu of mipPadding)\n imageOffset += imageSize + 4; // (+4 to jump the imageSize field itself)\n imageOffset = imageOffset % 4 !== 0 ? imageOffset + 4 - (imageOffset % 4) : imageOffset;\n // Calculate mipWidth, mipHeight for _next_ iteration\n mipWidth = (mipWidth >> 1) || 1;\n mipHeight = (mipHeight >> 1) || 1;\n alignedMipWidth = (mipWidth + blockWidth - 1) & ~(blockWidth - 1);\n alignedMipHeight = (mipHeight + blockHeight - 1) & ~(blockHeight - 1);\n // Each mipmap level is 4-times smaller?\n mipByteSize = alignedMipWidth * alignedMipHeight * imagePixelByteSize;\n }\n // We use the levelBuffers feature of CompressedTextureResource b/c texture data is image-major, not level-major.\n if (glType !== 0) {\n return {\n uncompressed: imageBuffers.map(function (levelBuffers) {\n var buffer = levelBuffers[0].levelBuffer;\n var convertToInt = false;\n if (glType === TYPES.FLOAT) {\n buffer = new Float32Array(levelBuffers[0].levelBuffer.buffer, levelBuffers[0].levelBuffer.byteOffset, levelBuffers[0].levelBuffer.byteLength / 4);\n }\n else if (glType === TYPES.UNSIGNED_INT) {\n convertToInt = true;\n buffer = new Uint32Array(levelBuffers[0].levelBuffer.buffer, levelBuffers[0].levelBuffer.byteOffset, levelBuffers[0].levelBuffer.byteLength / 4);\n }\n else if (glType === TYPES.INT) {\n convertToInt = true;\n buffer = new Int32Array(levelBuffers[0].levelBuffer.buffer, levelBuffers[0].levelBuffer.byteOffset, levelBuffers[0].levelBuffer.byteLength / 4);\n }\n return {\n resource: new BufferResource(buffer, {\n width: levelBuffers[0].levelWidth,\n height: levelBuffers[0].levelHeight,\n }),\n type: glType,\n format: convertToInt ? KTXLoader.convertFormatToInteger(glFormat) : glFormat,\n };\n })\n };\n }\n return {\n compressed: imageBuffers.map(function (levelBuffers) { return new CompressedTextureResource(null, {\n format: glInternalFormat,\n width: pixelWidth,\n height: pixelHeight,\n levels: numberOfMipmapLevels,\n levelBuffers: levelBuffers,\n }); })\n };\n };\n /** Checks whether the arrayBuffer contains a valid *.ktx file. */\n KTXLoader.validate = function (url, dataView) {\n // NOTE: Do not optimize this into 3 32-bit integer comparison because the endianness\n // of the data is not specified.\n for (var i = 0; i < FILE_IDENTIFIER.length; i++) {\n if (dataView.getUint8(i) !== FILE_IDENTIFIER[i]) {\n console.error(url + \" is not a valid *.ktx file!\");\n return false;\n }\n }\n return true;\n };\n KTXLoader.convertFormatToInteger = function (format) {\n switch (format) {\n case FORMATS.RGBA: return FORMATS.RGBA_INTEGER;\n case FORMATS.RGB: return FORMATS.RGB_INTEGER;\n case FORMATS.RG: return FORMATS.RG_INTEGER;\n case FORMATS.RED: return FORMATS.RED_INTEGER;\n default: return format;\n }\n };\n return KTXLoader;\n}());\n\nexport { BlobResource, CompressedTextureLoader, CompressedTextureResource, DDSLoader, FORMATS_TO_COMPONENTS, INTERNAL_FORMATS, INTERNAL_FORMAT_TO_BYTES_PER_PIXEL, KTXLoader, TYPES_TO_BYTES_PER_COMPONENT, TYPES_TO_BYTES_PER_PIXEL };\n//# sourceMappingURL=compressed-textures.js.map\n","/*!\n * @pixi/particle-container - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/particle-container is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { BLEND_MODES, TYPES } from '@pixi/constants';\nimport { Container } from '@pixi/display';\nimport { hex2rgb, createIndicesForQuads, correctBlendMode, premultiplyRgba, premultiplyTint } from '@pixi/utils';\nimport { Geometry, Buffer, ObjectRenderer, Shader, State } from '@pixi/core';\nimport { Matrix } from '@pixi/math';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * The ParticleContainer class is a really fast version of the Container built solely for speed,\n * so use when you need a lot of sprites or particles.\n *\n * The tradeoff of the ParticleContainer is that most advanced functionality will not work.\n * ParticleContainer implements the basic object transform (position, scale, rotation)\n * and some advanced functionality like tint (as of v4.5.6).\n *\n * Other more advanced functionality like masking, children, filters, etc will not work on sprites in this batch.\n *\n * It's extremely easy to use:\n * ```js\n * let container = new ParticleContainer();\n *\n * for (let i = 0; i < 100; ++i)\n * {\n * let sprite = PIXI.Sprite.from(\"myImage.png\");\n * container.addChild(sprite);\n * }\n * ```\n *\n * And here you have a hundred sprites that will be rendered at the speed of light.\n *\n * @memberof PIXI\n */\nvar ParticleContainer = /** @class */ (function (_super) {\n __extends(ParticleContainer, _super);\n /**\n * @param maxSize - The maximum number of particles that can be rendered by the container.\n * Affects size of allocated buffers.\n * @param properties - The properties of children that should be uploaded to the gpu and applied.\n * @param {boolean} [properties.vertices=false] - When true, vertices be uploaded and applied.\n * if sprite's ` scale/anchor/trim/frame/orig` is dynamic, please set `true`.\n * @param {boolean} [properties.position=true] - When true, position be uploaded and applied.\n * @param {boolean} [properties.rotation=false] - When true, rotation be uploaded and applied.\n * @param {boolean} [properties.uvs=false] - When true, uvs be uploaded and applied.\n * @param {boolean} [properties.tint=false] - When true, alpha and tint be uploaded and applied.\n * @param {number} [batchSize=16384] - Number of particles per batch. If less than maxSize, it uses maxSize instead.\n * @param {boolean} [autoResize=false] - If true, container allocates more batches in case\n * there are more than `maxSize` particles.\n */\n function ParticleContainer(maxSize, properties, batchSize, autoResize) {\n if (maxSize === void 0) { maxSize = 1500; }\n if (batchSize === void 0) { batchSize = 16384; }\n if (autoResize === void 0) { autoResize = false; }\n var _this = _super.call(this) || this;\n // Making sure the batch size is valid\n // 65535 is max vertex index in the index buffer (see ParticleRenderer)\n // so max number of particles is 65536 / 4 = 16384\n var maxBatchSize = 16384;\n if (batchSize > maxBatchSize) {\n batchSize = maxBatchSize;\n }\n _this._properties = [false, true, false, false, false];\n _this._maxSize = maxSize;\n _this._batchSize = batchSize;\n _this._buffers = null;\n _this._bufferUpdateIDs = [];\n _this._updateID = 0;\n _this.interactiveChildren = false;\n _this.blendMode = BLEND_MODES.NORMAL;\n _this.autoResize = autoResize;\n _this.roundPixels = true;\n _this.baseTexture = null;\n _this.setProperties(properties);\n _this._tint = 0;\n _this.tintRgb = new Float32Array(4);\n _this.tint = 0xFFFFFF;\n return _this;\n }\n /**\n * Sets the private properties array to dynamic / static based on the passed properties object\n *\n * @param properties - The properties to be uploaded\n */\n ParticleContainer.prototype.setProperties = function (properties) {\n if (properties) {\n this._properties[0] = 'vertices' in properties || 'scale' in properties\n ? !!properties.vertices || !!properties.scale : this._properties[0];\n this._properties[1] = 'position' in properties ? !!properties.position : this._properties[1];\n this._properties[2] = 'rotation' in properties ? !!properties.rotation : this._properties[2];\n this._properties[3] = 'uvs' in properties ? !!properties.uvs : this._properties[3];\n this._properties[4] = 'tint' in properties || 'alpha' in properties\n ? !!properties.tint || !!properties.alpha : this._properties[4];\n }\n };\n ParticleContainer.prototype.updateTransform = function () {\n // TODO don't need to!\n this.displayObjectUpdateTransform();\n };\n Object.defineProperty(ParticleContainer.prototype, \"tint\", {\n /**\n * The tint applied to the container. This is a hex value.\n * A value of 0xFFFFFF will remove any tint effect.\n * IMPORTANT: This is a WebGL only feature and will be ignored by the canvas renderer.\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n this._tint = value;\n hex2rgb(value, this.tintRgb);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Renders the container using the WebGL renderer.\n *\n * @param renderer - The WebGL renderer.\n */\n ParticleContainer.prototype.render = function (renderer) {\n var _this = this;\n if (!this.visible || this.worldAlpha <= 0 || !this.children.length || !this.renderable) {\n return;\n }\n if (!this.baseTexture) {\n this.baseTexture = this.children[0]._texture.baseTexture;\n if (!this.baseTexture.valid) {\n this.baseTexture.once('update', function () { return _this.onChildrenChange(0); });\n }\n }\n renderer.batch.setObjectRenderer(renderer.plugins.particle);\n renderer.plugins.particle.render(this);\n };\n /**\n * Set the flag that static data should be updated to true\n *\n * @param smallestChildIndex - The smallest child index.\n */\n ParticleContainer.prototype.onChildrenChange = function (smallestChildIndex) {\n var bufferIndex = Math.floor(smallestChildIndex / this._batchSize);\n while (this._bufferUpdateIDs.length < bufferIndex) {\n this._bufferUpdateIDs.push(0);\n }\n this._bufferUpdateIDs[bufferIndex] = ++this._updateID;\n };\n ParticleContainer.prototype.dispose = function () {\n if (this._buffers) {\n for (var i = 0; i < this._buffers.length; ++i) {\n this._buffers[i].destroy();\n }\n this._buffers = null;\n }\n };\n /**\n * Destroys the container\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their\n * destroy method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the texture of the child sprite\n * @param {boolean} [options.baseTexture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the base texture of the child sprite\n */\n ParticleContainer.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n this.dispose();\n this._properties = null;\n this._buffers = null;\n this._bufferUpdateIDs = null;\n };\n return ParticleContainer;\n}(Container));\n\n/*\n * @author Mat Groves\n *\n * Big thanks to the very clever Matt DesLauriers <mattdesl> https://github.com/mattdesl/\n * for creating the original PixiJS version!\n * Also a thanks to https://github.com/bchevalier for tweaking the tint and alpha so that\n * they now share 4 bytes on the vertex buffer\n *\n * Heavily inspired by LibGDX's ParticleBuffer:\n * https://github.com/libgdx/libgdx/blob/master/gdx/src/com/badlogic/gdx/graphics/g2d/ParticleBuffer.java\n */\n/**\n * The particle buffer manages the static and dynamic buffers for a particle container.\n *\n * @private\n * @memberof PIXI\n */\nvar ParticleBuffer = /** @class */ (function () {\n /**\n * @param {object} properties - The properties to upload.\n * @param {boolean[]} dynamicPropertyFlags - Flags for which properties are dynamic.\n * @param {number} size - The size of the batch.\n */\n function ParticleBuffer(properties, dynamicPropertyFlags, size) {\n this.geometry = new Geometry();\n this.indexBuffer = null;\n this.size = size;\n this.dynamicProperties = [];\n this.staticProperties = [];\n for (var i = 0; i < properties.length; ++i) {\n var property = properties[i];\n // Make copy of properties object so that when we edit the offset it doesn't\n // change all other instances of the object literal\n property = {\n attributeName: property.attributeName,\n size: property.size,\n uploadFunction: property.uploadFunction,\n type: property.type || TYPES.FLOAT,\n offset: property.offset,\n };\n if (dynamicPropertyFlags[i]) {\n this.dynamicProperties.push(property);\n }\n else {\n this.staticProperties.push(property);\n }\n }\n this.staticStride = 0;\n this.staticBuffer = null;\n this.staticData = null;\n this.staticDataUint32 = null;\n this.dynamicStride = 0;\n this.dynamicBuffer = null;\n this.dynamicData = null;\n this.dynamicDataUint32 = null;\n this._updateID = 0;\n this.initBuffers();\n }\n /** Sets up the renderer context and necessary buffers. */\n ParticleBuffer.prototype.initBuffers = function () {\n var geometry = this.geometry;\n var dynamicOffset = 0;\n this.indexBuffer = new Buffer(createIndicesForQuads(this.size), true, true);\n geometry.addIndex(this.indexBuffer);\n this.dynamicStride = 0;\n for (var i = 0; i < this.dynamicProperties.length; ++i) {\n var property = this.dynamicProperties[i];\n property.offset = dynamicOffset;\n dynamicOffset += property.size;\n this.dynamicStride += property.size;\n }\n var dynBuffer = new ArrayBuffer(this.size * this.dynamicStride * 4 * 4);\n this.dynamicData = new Float32Array(dynBuffer);\n this.dynamicDataUint32 = new Uint32Array(dynBuffer);\n this.dynamicBuffer = new Buffer(this.dynamicData, false, false);\n // static //\n var staticOffset = 0;\n this.staticStride = 0;\n for (var i = 0; i < this.staticProperties.length; ++i) {\n var property = this.staticProperties[i];\n property.offset = staticOffset;\n staticOffset += property.size;\n this.staticStride += property.size;\n }\n var statBuffer = new ArrayBuffer(this.size * this.staticStride * 4 * 4);\n this.staticData = new Float32Array(statBuffer);\n this.staticDataUint32 = new Uint32Array(statBuffer);\n this.staticBuffer = new Buffer(this.staticData, true, false);\n for (var i = 0; i < this.dynamicProperties.length; ++i) {\n var property = this.dynamicProperties[i];\n geometry.addAttribute(property.attributeName, this.dynamicBuffer, 0, property.type === TYPES.UNSIGNED_BYTE, property.type, this.dynamicStride * 4, property.offset * 4);\n }\n for (var i = 0; i < this.staticProperties.length; ++i) {\n var property = this.staticProperties[i];\n geometry.addAttribute(property.attributeName, this.staticBuffer, 0, property.type === TYPES.UNSIGNED_BYTE, property.type, this.staticStride * 4, property.offset * 4);\n }\n };\n /**\n * Uploads the dynamic properties.\n *\n * @param children - The children to upload.\n * @param startIndex - The index to start at.\n * @param amount - The number to upload.\n */\n ParticleBuffer.prototype.uploadDynamic = function (children, startIndex, amount) {\n for (var i = 0; i < this.dynamicProperties.length; i++) {\n var property = this.dynamicProperties[i];\n property.uploadFunction(children, startIndex, amount, property.type === TYPES.UNSIGNED_BYTE ? this.dynamicDataUint32 : this.dynamicData, this.dynamicStride, property.offset);\n }\n this.dynamicBuffer._updateID++;\n };\n /**\n * Uploads the static properties.\n *\n * @param children - The children to upload.\n * @param startIndex - The index to start at.\n * @param amount - The number to upload.\n */\n ParticleBuffer.prototype.uploadStatic = function (children, startIndex, amount) {\n for (var i = 0; i < this.staticProperties.length; i++) {\n var property = this.staticProperties[i];\n property.uploadFunction(children, startIndex, amount, property.type === TYPES.UNSIGNED_BYTE ? this.staticDataUint32 : this.staticData, this.staticStride, property.offset);\n }\n this.staticBuffer._updateID++;\n };\n /** Destroys the ParticleBuffer. */\n ParticleBuffer.prototype.destroy = function () {\n this.indexBuffer = null;\n this.dynamicProperties = null;\n this.dynamicBuffer = null;\n this.dynamicData = null;\n this.dynamicDataUint32 = null;\n this.staticProperties = null;\n this.staticBuffer = null;\n this.staticData = null;\n this.staticDataUint32 = null;\n // all buffers are destroyed inside geometry\n this.geometry.destroy();\n };\n return ParticleBuffer;\n}());\n\nvar fragment = \"varying vec2 vTextureCoord;\\nvarying vec4 vColor;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void){\\n vec4 color = texture2D(uSampler, vTextureCoord) * vColor;\\n gl_FragColor = color;\\n}\";\n\nvar vertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\nattribute vec4 aColor;\\n\\nattribute vec2 aPositionCoord;\\nattribute float aRotation;\\n\\nuniform mat3 translationMatrix;\\nuniform vec4 uColor;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec4 vColor;\\n\\nvoid main(void){\\n float x = (aVertexPosition.x) * cos(aRotation) - (aVertexPosition.y) * sin(aRotation);\\n float y = (aVertexPosition.x) * sin(aRotation) + (aVertexPosition.y) * cos(aRotation);\\n\\n vec2 v = vec2(x, y);\\n v = v + aPositionCoord;\\n\\n gl_Position = vec4((translationMatrix * vec3(v, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = aTextureCoord;\\n vColor = aColor * uColor;\\n}\\n\";\n\n/*\n * @author Mat Groves\n *\n * Big thanks to the very clever Matt DesLauriers <mattdesl> https://github.com/mattdesl/\n * for creating the original PixiJS version!\n * Also a thanks to https://github.com/bchevalier for tweaking the tint and alpha so that they now\n * share 4 bytes on the vertex buffer\n *\n * Heavily inspired by LibGDX's ParticleRenderer:\n * https://github.com/libgdx/libgdx/blob/master/gdx/src/com/badlogic/gdx/graphics/g2d/ParticleRenderer.java\n */\n/**\n * Renderer for Particles that is designer for speed over feature set.\n *\n * @memberof PIXI\n */\nvar ParticleRenderer = /** @class */ (function (_super) {\n __extends(ParticleRenderer, _super);\n /**\n * @param renderer - The renderer this sprite batch works for.\n */\n function ParticleRenderer(renderer) {\n var _this = _super.call(this, renderer) || this;\n // 65535 is max vertex index in the index buffer (see ParticleRenderer)\n // so max number of particles is 65536 / 4 = 16384\n // and max number of element in the index buffer is 16384 * 6 = 98304\n // Creating a full index buffer, overhead is 98304 * 2 = 196Ko\n // let numIndices = 98304;\n _this.shader = null;\n _this.properties = null;\n _this.tempMatrix = new Matrix();\n _this.properties = [\n // verticesData\n {\n attributeName: 'aVertexPosition',\n size: 2,\n uploadFunction: _this.uploadVertices,\n offset: 0,\n },\n // positionData\n {\n attributeName: 'aPositionCoord',\n size: 2,\n uploadFunction: _this.uploadPosition,\n offset: 0,\n },\n // rotationData\n {\n attributeName: 'aRotation',\n size: 1,\n uploadFunction: _this.uploadRotation,\n offset: 0,\n },\n // uvsData\n {\n attributeName: 'aTextureCoord',\n size: 2,\n uploadFunction: _this.uploadUvs,\n offset: 0,\n },\n // tintData\n {\n attributeName: 'aColor',\n size: 1,\n type: TYPES.UNSIGNED_BYTE,\n uploadFunction: _this.uploadTint,\n offset: 0,\n } ];\n _this.shader = Shader.from(vertex, fragment, {});\n _this.state = State.for2d();\n return _this;\n }\n /**\n * Renders the particle container object.\n *\n * @param container - The container to render using this ParticleRenderer.\n */\n ParticleRenderer.prototype.render = function (container) {\n var children = container.children;\n var maxSize = container._maxSize;\n var batchSize = container._batchSize;\n var renderer = this.renderer;\n var totalChildren = children.length;\n if (totalChildren === 0) {\n return;\n }\n else if (totalChildren > maxSize && !container.autoResize) {\n totalChildren = maxSize;\n }\n var buffers = container._buffers;\n if (!buffers) {\n buffers = container._buffers = this.generateBuffers(container);\n }\n var baseTexture = children[0]._texture.baseTexture;\n // if the uvs have not updated then no point rendering just yet!\n this.state.blendMode = correctBlendMode(container.blendMode, baseTexture.alphaMode);\n renderer.state.set(this.state);\n var gl = renderer.gl;\n var m = container.worldTransform.copyTo(this.tempMatrix);\n m.prepend(renderer.globalUniforms.uniforms.projectionMatrix);\n this.shader.uniforms.translationMatrix = m.toArray(true);\n this.shader.uniforms.uColor = premultiplyRgba(container.tintRgb, container.worldAlpha, this.shader.uniforms.uColor, baseTexture.alphaMode);\n this.shader.uniforms.uSampler = baseTexture;\n this.renderer.shader.bind(this.shader);\n var updateStatic = false;\n // now lets upload and render the buffers..\n for (var i = 0, j = 0; i < totalChildren; i += batchSize, j += 1) {\n var amount = (totalChildren - i);\n if (amount > batchSize) {\n amount = batchSize;\n }\n if (j >= buffers.length) {\n buffers.push(this._generateOneMoreBuffer(container));\n }\n var buffer = buffers[j];\n // we always upload the dynamic\n buffer.uploadDynamic(children, i, amount);\n var bid = container._bufferUpdateIDs[j] || 0;\n updateStatic = updateStatic || (buffer._updateID < bid);\n // we only upload the static content when we have to!\n if (updateStatic) {\n buffer._updateID = container._updateID;\n buffer.uploadStatic(children, i, amount);\n }\n // bind the buffer\n renderer.geometry.bind(buffer.geometry);\n gl.drawElements(gl.TRIANGLES, amount * 6, gl.UNSIGNED_SHORT, 0);\n }\n };\n /**\n * Creates one particle buffer for each child in the container we want to render and updates internal properties.\n *\n * @param container - The container to render using this ParticleRenderer\n * @return - The buffers\n */\n ParticleRenderer.prototype.generateBuffers = function (container) {\n var buffers = [];\n var size = container._maxSize;\n var batchSize = container._batchSize;\n var dynamicPropertyFlags = container._properties;\n for (var i = 0; i < size; i += batchSize) {\n buffers.push(new ParticleBuffer(this.properties, dynamicPropertyFlags, batchSize));\n }\n return buffers;\n };\n /**\n * Creates one more particle buffer, because container has autoResize feature.\n *\n * @param container - The container to render using this ParticleRenderer\n * @return - The generated buffer\n */\n ParticleRenderer.prototype._generateOneMoreBuffer = function (container) {\n var batchSize = container._batchSize;\n var dynamicPropertyFlags = container._properties;\n return new ParticleBuffer(this.properties, dynamicPropertyFlags, batchSize);\n };\n /**\n * Uploads the vertices.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their vertices uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadVertices = function (children, startIndex, amount, array, stride, offset) {\n var w0 = 0;\n var w1 = 0;\n var h0 = 0;\n var h1 = 0;\n for (var i = 0; i < amount; ++i) {\n var sprite = children[startIndex + i];\n var texture = sprite._texture;\n var sx = sprite.scale.x;\n var sy = sprite.scale.y;\n var trim = texture.trim;\n var orig = texture.orig;\n if (trim) {\n // if the sprite is trimmed and is not a tilingsprite then we need to add the\n // extra space before transforming the sprite coords..\n w1 = trim.x - (sprite.anchor.x * orig.width);\n w0 = w1 + trim.width;\n h1 = trim.y - (sprite.anchor.y * orig.height);\n h0 = h1 + trim.height;\n }\n else {\n w0 = (orig.width) * (1 - sprite.anchor.x);\n w1 = (orig.width) * -sprite.anchor.x;\n h0 = orig.height * (1 - sprite.anchor.y);\n h1 = orig.height * -sprite.anchor.y;\n }\n array[offset] = w1 * sx;\n array[offset + 1] = h1 * sy;\n array[offset + stride] = w0 * sx;\n array[offset + stride + 1] = h1 * sy;\n array[offset + (stride * 2)] = w0 * sx;\n array[offset + (stride * 2) + 1] = h0 * sy;\n array[offset + (stride * 3)] = w1 * sx;\n array[offset + (stride * 3) + 1] = h0 * sy;\n offset += stride * 4;\n }\n };\n /**\n * Uploads the position.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their positions uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadPosition = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; i++) {\n var spritePosition = children[startIndex + i].position;\n array[offset] = spritePosition.x;\n array[offset + 1] = spritePosition.y;\n array[offset + stride] = spritePosition.x;\n array[offset + stride + 1] = spritePosition.y;\n array[offset + (stride * 2)] = spritePosition.x;\n array[offset + (stride * 2) + 1] = spritePosition.y;\n array[offset + (stride * 3)] = spritePosition.x;\n array[offset + (stride * 3) + 1] = spritePosition.y;\n offset += stride * 4;\n }\n };\n /**\n * Uploads the rotation.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their rotation uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadRotation = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; i++) {\n var spriteRotation = children[startIndex + i].rotation;\n array[offset] = spriteRotation;\n array[offset + stride] = spriteRotation;\n array[offset + (stride * 2)] = spriteRotation;\n array[offset + (stride * 3)] = spriteRotation;\n offset += stride * 4;\n }\n };\n /**\n * Uploads the UVs.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their rotation uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadUvs = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; ++i) {\n var textureUvs = children[startIndex + i]._texture._uvs;\n if (textureUvs) {\n array[offset] = textureUvs.x0;\n array[offset + 1] = textureUvs.y0;\n array[offset + stride] = textureUvs.x1;\n array[offset + stride + 1] = textureUvs.y1;\n array[offset + (stride * 2)] = textureUvs.x2;\n array[offset + (stride * 2) + 1] = textureUvs.y2;\n array[offset + (stride * 3)] = textureUvs.x3;\n array[offset + (stride * 3) + 1] = textureUvs.y3;\n offset += stride * 4;\n }\n else {\n // TODO you know this can be easier!\n array[offset] = 0;\n array[offset + 1] = 0;\n array[offset + stride] = 0;\n array[offset + stride + 1] = 0;\n array[offset + (stride * 2)] = 0;\n array[offset + (stride * 2) + 1] = 0;\n array[offset + (stride * 3)] = 0;\n array[offset + (stride * 3) + 1] = 0;\n offset += stride * 4;\n }\n }\n };\n /**\n * Uploads the tint.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their rotation uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadTint = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; ++i) {\n var sprite = children[startIndex + i];\n var premultiplied = sprite._texture.baseTexture.alphaMode > 0;\n var alpha = sprite.alpha;\n // we dont call extra function if alpha is 1.0, that's faster\n var argb = alpha < 1.0 && premultiplied\n ? premultiplyTint(sprite._tintRGB, alpha) : sprite._tintRGB + (alpha * 255 << 24);\n array[offset] = argb;\n array[offset + stride] = argb;\n array[offset + (stride * 2)] = argb;\n array[offset + (stride * 3)] = argb;\n offset += stride * 4;\n }\n };\n /** Destroys the ParticleRenderer. */\n ParticleRenderer.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n if (this.shader) {\n this.shader.destroy();\n this.shader = null;\n }\n this.tempMatrix = null;\n };\n return ParticleRenderer;\n}(ObjectRenderer));\n\nexport { ParticleContainer, ParticleRenderer };\n//# sourceMappingURL=particle-container.js.map\n","/*!\n * @pixi/graphics - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/graphics is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture, BaseTexture, BatchDrawCall, BatchTextureArray, BatchGeometry, UniformGroup, Shader, State } from '@pixi/core';\nimport { SHAPES, Point, PI_2, Matrix, Polygon, Rectangle, RoundedRectangle, Circle, Ellipse } from '@pixi/math';\nimport { earcut, premultiplyTint, hex2rgb } from '@pixi/utils';\nimport { WRAP_MODES, DRAW_MODES, BLEND_MODES } from '@pixi/constants';\nimport { Bounds, Container } from '@pixi/display';\n\n/**\n * Supported line joints in `PIXI.LineStyle` for graphics.\n *\n * @see PIXI.Graphics#lineStyle\n * @see https://graphicdesign.stackexchange.com/questions/59018/what-is-a-bevel-join-of-two-lines-exactly-illustrator\n *\n * @name LINE_JOIN\n * @memberof PIXI\n * @static\n * @enum {string}\n * @property {string} MITER - 'miter': make a sharp corner where outer part of lines meet\n * @property {string} BEVEL - 'bevel': add a square butt at each end of line segment and fill the triangle at turn\n * @property {string} ROUND - 'round': add an arc at the joint\n */\nvar LINE_JOIN;\n(function (LINE_JOIN) {\n LINE_JOIN[\"MITER\"] = \"miter\";\n LINE_JOIN[\"BEVEL\"] = \"bevel\";\n LINE_JOIN[\"ROUND\"] = \"round\";\n})(LINE_JOIN || (LINE_JOIN = {}));\n/**\n * Support line caps in `PIXI.LineStyle` for graphics.\n *\n * @see PIXI.Graphics#lineStyle\n *\n * @name LINE_CAP\n * @memberof PIXI\n * @static\n * @enum {string}\n * @property {string} BUTT - 'butt': don't add any cap at line ends (leaves orthogonal edges)\n * @property {string} ROUND - 'round': add semicircle at ends\n * @property {string} SQUARE - 'square': add square at end (like `BUTT` except more length at end)\n */\nvar LINE_CAP;\n(function (LINE_CAP) {\n LINE_CAP[\"BUTT\"] = \"butt\";\n LINE_CAP[\"ROUND\"] = \"round\";\n LINE_CAP[\"SQUARE\"] = \"square\";\n})(LINE_CAP || (LINE_CAP = {}));\n/**\n * Graphics curves resolution settings. If `adaptive` flag is set to `true`,\n * the resolution is calculated based on the curve's length to ensure better visual quality.\n * Adaptive draw works with `bezierCurveTo` and `quadraticCurveTo`.\n *\n * @static\n * @constant\n * @memberof PIXI\n * @name GRAPHICS_CURVES\n * @type {object}\n * @property {boolean} adaptive=true - flag indicating if the resolution should be adaptive\n * @property {number} maxLength=10 - maximal length of a single segment of the curve (if adaptive = false, ignored)\n * @property {number} minSegments=8 - minimal number of segments in the curve (if adaptive = false, ignored)\n * @property {number} maxSegments=2048 - maximal number of segments in the curve (if adaptive = false, ignored)\n */\nvar GRAPHICS_CURVES = {\n adaptive: true,\n maxLength: 10,\n minSegments: 8,\n maxSegments: 2048,\n epsilon: 0.0001,\n _segmentsCount: function (length, defaultSegments) {\n if (defaultSegments === void 0) { defaultSegments = 20; }\n if (!this.adaptive || !length || isNaN(length)) {\n return defaultSegments;\n }\n var result = Math.ceil(length / this.maxLength);\n if (result < this.minSegments) {\n result = this.minSegments;\n }\n else if (result > this.maxSegments) {\n result = this.maxSegments;\n }\n return result;\n },\n};\n\n/**\n * Fill style object for Graphics.\n *\n * @memberof PIXI\n */\nvar FillStyle = /** @class */ (function () {\n function FillStyle() {\n /**\n * The hex color value used when coloring the Graphics object.\n *\n * @default 0xFFFFFF\n */\n this.color = 0xFFFFFF;\n /** The alpha value used when filling the Graphics object. */\n this.alpha = 1.0;\n /**\n * The texture to be used for the fill.\n *\n * @default 0\n */\n this.texture = Texture.WHITE;\n /**\n * The transform applied to the texture.\n *\n * @default null\n */\n this.matrix = null;\n /** If the current fill is visible. */\n this.visible = false;\n this.reset();\n }\n /** Clones the object */\n FillStyle.prototype.clone = function () {\n var obj = new FillStyle();\n obj.color = this.color;\n obj.alpha = this.alpha;\n obj.texture = this.texture;\n obj.matrix = this.matrix;\n obj.visible = this.visible;\n return obj;\n };\n /** Reset */\n FillStyle.prototype.reset = function () {\n this.color = 0xFFFFFF;\n this.alpha = 1;\n this.texture = Texture.WHITE;\n this.matrix = null;\n this.visible = false;\n };\n /** Destroy and don't use after this. */\n FillStyle.prototype.destroy = function () {\n this.texture = null;\n this.matrix = null;\n };\n return FillStyle;\n}());\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nfunction fixOrientation(points, hole) {\n var _a, _b;\n if (hole === void 0) { hole = false; }\n var m = points.length;\n if (m < 6) {\n return;\n }\n var area = 0;\n for (var i = 0, x1 = points[m - 2], y1 = points[m - 1]; i < m; i += 2) {\n var x2 = points[i];\n var y2 = points[i + 1];\n area += (x2 - x1) * (y2 + y1);\n x1 = x2;\n y1 = y2;\n }\n if ((!hole && area > 0) || (hole && area <= 0)) {\n var n = m / 2;\n for (var i = n + (n % 2); i < m; i += 2) {\n var i1 = m - i - 2;\n var i2 = m - i - 1;\n var i3 = i;\n var i4 = i + 1;\n _a = [points[i3], points[i1]], points[i1] = _a[0], points[i3] = _a[1];\n _b = [points[i4], points[i2]], points[i2] = _b[0], points[i4] = _b[1];\n }\n }\n}\n/**\n * Builds a polygon to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildPoly = {\n build: function (graphicsData) {\n graphicsData.points = graphicsData.shape.points.slice();\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n var points = graphicsData.points;\n var holes = graphicsData.holes;\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n if (points.length >= 6) {\n fixOrientation(points, false);\n var holeArray = [];\n // Process holes..\n for (var i = 0; i < holes.length; i++) {\n var hole = holes[i];\n fixOrientation(hole.points, true);\n holeArray.push(points.length / 2);\n points = points.concat(hole.points);\n }\n // sort color\n var triangles = earcut(points, holeArray, 2);\n if (!triangles) {\n return;\n }\n var vertPos = verts.length / 2;\n for (var i = 0; i < triangles.length; i += 3) {\n indices.push(triangles[i] + vertPos);\n indices.push(triangles[i + 1] + vertPos);\n indices.push(triangles[i + 2] + vertPos);\n }\n for (var i = 0; i < points.length; i++) {\n verts.push(points[i]);\n }\n }\n },\n};\n\n// for type only\n/**\n * Builds a circle to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object to draw\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildCircle = {\n build: function (graphicsData) {\n // need to convert points to a nice regular data\n var points = graphicsData.points;\n var x;\n var y;\n var dx;\n var dy;\n var rx;\n var ry;\n if (graphicsData.type === SHAPES.CIRC) {\n var circle = graphicsData.shape;\n x = circle.x;\n y = circle.y;\n rx = ry = circle.radius;\n dx = dy = 0;\n }\n else if (graphicsData.type === SHAPES.ELIP) {\n var ellipse = graphicsData.shape;\n x = ellipse.x;\n y = ellipse.y;\n rx = ellipse.width;\n ry = ellipse.height;\n dx = dy = 0;\n }\n else {\n var roundedRect = graphicsData.shape;\n var halfWidth = roundedRect.width / 2;\n var halfHeight = roundedRect.height / 2;\n x = roundedRect.x + halfWidth;\n y = roundedRect.y + halfHeight;\n rx = ry = Math.max(0, Math.min(roundedRect.radius, Math.min(halfWidth, halfHeight)));\n dx = halfWidth - rx;\n dy = halfHeight - ry;\n }\n // Choose a number of segments such that the maximum absolute deviation from the circle is approximately 0.029\n var n = Math.ceil(2.3 * Math.sqrt(rx + ry));\n var m = (n * 8) + (dx ? 4 : 0) + (dy ? 4 : 0);\n points.length = m;\n if (m === 0) {\n return;\n }\n if (n === 0) {\n points.length = 8;\n points[0] = points[6] = x + dx;\n points[1] = points[3] = y + dy;\n points[2] = points[4] = x - dx;\n points[5] = points[7] = y - dy;\n return;\n }\n var j1 = 0;\n var j2 = (n * 4) + (dx ? 2 : 0) + 2;\n var j3 = j2;\n var j4 = m;\n {\n var x0 = dx + rx;\n var y0 = dy;\n var x1 = x + x0;\n var x2 = x - x0;\n var y1 = y + y0;\n points[j1++] = x1;\n points[j1++] = y1;\n points[--j2] = y1;\n points[--j2] = x2;\n if (dy) {\n var y2 = y - y0;\n points[j3++] = x2;\n points[j3++] = y2;\n points[--j4] = y2;\n points[--j4] = x1;\n }\n }\n for (var i = 1; i < n; i++) {\n var a = Math.PI / 2 * (i / n);\n var x0 = dx + (Math.cos(a) * rx);\n var y0 = dy + (Math.sin(a) * ry);\n var x1 = x + x0;\n var x2 = x - x0;\n var y1 = y + y0;\n var y2 = y - y0;\n points[j1++] = x1;\n points[j1++] = y1;\n points[--j2] = y1;\n points[--j2] = x2;\n points[j3++] = x2;\n points[j3++] = y2;\n points[--j4] = y2;\n points[--j4] = x1;\n }\n {\n var x0 = dx;\n var y0 = dy + ry;\n var x1 = x + x0;\n var x2 = x - x0;\n var y1 = y + y0;\n var y2 = y - y0;\n points[j1++] = x1;\n points[j1++] = y1;\n points[--j4] = y2;\n points[--j4] = x1;\n if (dx) {\n points[j1++] = x2;\n points[j1++] = y1;\n points[--j4] = y2;\n points[--j4] = x2;\n }\n }\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n var points = graphicsData.points;\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n var vertPos = verts.length / 2;\n var center = vertPos;\n var x;\n var y;\n if (graphicsData.type !== SHAPES.RREC) {\n var circle = graphicsData.shape;\n x = circle.x;\n y = circle.y;\n }\n else {\n var roundedRect = graphicsData.shape;\n x = roundedRect.x + (roundedRect.width / 2);\n y = roundedRect.y + (roundedRect.height / 2);\n }\n var matrix = graphicsData.matrix;\n // Push center (special point)\n verts.push(graphicsData.matrix ? (matrix.a * x) + (matrix.c * y) + matrix.tx : x, graphicsData.matrix ? (matrix.b * x) + (matrix.d * y) + matrix.ty : y);\n vertPos++;\n verts.push(points[0], points[1]);\n for (var i = 2; i < points.length; i += 2) {\n verts.push(points[i], points[i + 1]);\n // add some uvs\n indices.push(vertPos++, center, vertPos);\n }\n indices.push(center + 1, center, vertPos);\n },\n};\n\n/**\n * Builds a rectangle to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildRectangle = {\n build: function (graphicsData) {\n // --- //\n // need to convert points to a nice regular data\n //\n var rectData = graphicsData.shape;\n var x = rectData.x;\n var y = rectData.y;\n var width = rectData.width;\n var height = rectData.height;\n var points = graphicsData.points;\n points.length = 0;\n points.push(x, y, x + width, y, x + width, y + height, x, y + height);\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n var points = graphicsData.points;\n var verts = graphicsGeometry.points;\n var vertPos = verts.length / 2;\n verts.push(points[0], points[1], points[2], points[3], points[6], points[7], points[4], points[5]);\n graphicsGeometry.indices.push(vertPos, vertPos + 1, vertPos + 2, vertPos + 1, vertPos + 2, vertPos + 3);\n },\n};\n\n/**\n * Calculate a single point for a quadratic bezier curve.\n * Utility function used by quadraticBezierCurve.\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} n1 - first number\n * @param {number} n2 - second number\n * @param {number} perc - percentage\n * @return {number} the result\n *\n */\nfunction getPt(n1, n2, perc) {\n var diff = n2 - n1;\n return n1 + (diff * perc);\n}\n/**\n * Calculate the points for a quadratic bezier curve. (helper function..)\n * Based on: https://stackoverflow.com/questions/785097/how-do-i-implement-a-bezier-curve-in-c\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} fromX - Origin point x\n * @param {number} fromY - Origin point x\n * @param {number} cpX - Control point x\n * @param {number} cpY - Control point y\n * @param {number} toX - Destination point x\n * @param {number} toY - Destination point y\n * @param {number[]} [out=[]] - The output array to add points into. If not passed, a new array is created.\n * @return {number[]} an array of points\n */\nfunction quadraticBezierCurve(fromX, fromY, cpX, cpY, toX, toY, out) {\n if (out === void 0) { out = []; }\n var n = 20;\n var points = out;\n var xa = 0;\n var ya = 0;\n var xb = 0;\n var yb = 0;\n var x = 0;\n var y = 0;\n for (var i = 0, j = 0; i <= n; ++i) {\n j = i / n;\n // The Green Line\n xa = getPt(fromX, cpX, j);\n ya = getPt(fromY, cpY, j);\n xb = getPt(cpX, toX, j);\n yb = getPt(cpY, toY, j);\n // The Black Dot\n x = getPt(xa, xb, j);\n y = getPt(ya, yb, j);\n // Handle case when first curve points overlaps and earcut fails to triangulate\n if (i === 0 && points[points.length - 2] === x && points[points.length - 1] === y) {\n continue;\n }\n points.push(x, y);\n }\n return points;\n}\n/**\n * Builds a rounded rectangle to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildRoundedRectangle = {\n build: function (graphicsData) {\n if (Graphics.nextRoundedRectBehavior) {\n buildCircle.build(graphicsData);\n return;\n }\n var rrectData = graphicsData.shape;\n var points = graphicsData.points;\n var x = rrectData.x;\n var y = rrectData.y;\n var width = rrectData.width;\n var height = rrectData.height;\n // Don't allow negative radius or greater than half the smallest width\n var radius = Math.max(0, Math.min(rrectData.radius, Math.min(width, height) / 2));\n points.length = 0;\n // No radius, do a simple rectangle\n if (!radius) {\n points.push(x, y, x + width, y, x + width, y + height, x, y + height);\n }\n else {\n quadraticBezierCurve(x, y + radius, x, y, x + radius, y, points);\n quadraticBezierCurve(x + width - radius, y, x + width, y, x + width, y + radius, points);\n quadraticBezierCurve(x + width, y + height - radius, x + width, y + height, x + width - radius, y + height, points);\n quadraticBezierCurve(x + radius, y + height, x, y + height, x, y + height - radius, points);\n }\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n if (Graphics.nextRoundedRectBehavior) {\n buildCircle.triangulate(graphicsData, graphicsGeometry);\n return;\n }\n var points = graphicsData.points;\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n var vecPos = verts.length / 2;\n var triangles = earcut(points, null, 2);\n for (var i = 0, j = triangles.length; i < j; i += 3) {\n indices.push(triangles[i] + vecPos);\n // indices.push(triangles[i] + vecPos);\n indices.push(triangles[i + 1] + vecPos);\n // indices.push(triangles[i + 2] + vecPos);\n indices.push(triangles[i + 2] + vecPos);\n }\n for (var i = 0, j = points.length; i < j; i++) {\n verts.push(points[i], points[++i]);\n }\n },\n};\n\n/**\n * Buffers vertices to draw a square cap.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} x - X-coord of end point\n * @param {number} y - Y-coord of end point\n * @param {number} nx - X-coord of line normal pointing inside\n * @param {number} ny - Y-coord of line normal pointing inside\n * @param {Array<number>} verts - vertex buffer\n * @returns {}\n */\nfunction square(x, y, nx, ny, innerWeight, outerWeight, clockwise, /* rotation for square (true at left end, false at right end) */ verts) {\n var ix = x - (nx * innerWeight);\n var iy = y - (ny * innerWeight);\n var ox = x + (nx * outerWeight);\n var oy = y + (ny * outerWeight);\n /* Rotate nx,ny for extension vector */\n var exx;\n var eyy;\n if (clockwise) {\n exx = ny;\n eyy = -nx;\n }\n else {\n exx = -ny;\n eyy = nx;\n }\n /* [i|0]x,y extended at cap */\n var eix = ix + exx;\n var eiy = iy + eyy;\n var eox = ox + exx;\n var eoy = oy + eyy;\n /* Square itself must be inserted clockwise*/\n verts.push(eix, eiy);\n verts.push(eox, eoy);\n return 2;\n}\n/**\n * Buffers vertices to draw an arc at the line joint or cap.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} cx - X-coord of center\n * @param {number} cy - Y-coord of center\n * @param {number} sx - X-coord of arc start\n * @param {number} sy - Y-coord of arc start\n * @param {number} ex - X-coord of arc end\n * @param {number} ey - Y-coord of arc end\n * @param {Array<number>} verts - buffer of vertices\n * @param {boolean} clockwise - orientation of vertices\n * @returns {number} - no. of vertices pushed\n */\nfunction round(cx, cy, sx, sy, ex, ey, verts, clockwise) {\n var cx2p0x = sx - cx;\n var cy2p0y = sy - cy;\n var angle0 = Math.atan2(cx2p0x, cy2p0y);\n var angle1 = Math.atan2(ex - cx, ey - cy);\n if (clockwise && angle0 < angle1) {\n angle0 += Math.PI * 2;\n }\n else if (!clockwise && angle0 > angle1) {\n angle1 += Math.PI * 2;\n }\n var startAngle = angle0;\n var angleDiff = angle1 - angle0;\n var absAngleDiff = Math.abs(angleDiff);\n /* if (absAngleDiff >= PI_LBOUND && absAngleDiff <= PI_UBOUND)\n {\n const r1x = cx - nxtPx;\n const r1y = cy - nxtPy;\n\n if (r1x === 0)\n {\n if (r1y > 0)\n {\n angleDiff = -angleDiff;\n }\n }\n else if (r1x >= -GRAPHICS_CURVES.epsilon)\n {\n angleDiff = -angleDiff;\n }\n }*/\n var radius = Math.sqrt((cx2p0x * cx2p0x) + (cy2p0y * cy2p0y));\n var segCount = ((15 * absAngleDiff * Math.sqrt(radius) / Math.PI) >> 0) + 1;\n var angleInc = angleDiff / segCount;\n startAngle += angleInc;\n if (clockwise) {\n verts.push(cx, cy);\n verts.push(sx, sy);\n for (var i = 1, angle = startAngle; i < segCount; i++, angle += angleInc) {\n verts.push(cx, cy);\n verts.push(cx + ((Math.sin(angle) * radius)), cy + ((Math.cos(angle) * radius)));\n }\n verts.push(cx, cy);\n verts.push(ex, ey);\n }\n else {\n verts.push(sx, sy);\n verts.push(cx, cy);\n for (var i = 1, angle = startAngle; i < segCount; i++, angle += angleInc) {\n verts.push(cx + ((Math.sin(angle) * radius)), cy + ((Math.cos(angle) * radius)));\n verts.push(cx, cy);\n }\n verts.push(ex, ey);\n verts.push(cx, cy);\n }\n return segCount * 2;\n}\n/**\n * Builds a line to draw using the polygon method.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.GraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {PIXI.GraphicsGeometry} graphicsGeometry - Geometry where to append output\n */\nfunction buildNonNativeLine(graphicsData, graphicsGeometry) {\n var shape = graphicsData.shape;\n var points = graphicsData.points || shape.points.slice();\n var eps = graphicsGeometry.closePointEps;\n if (points.length === 0) {\n return;\n }\n // if the line width is an odd number add 0.5 to align to a whole pixel\n // commenting this out fixes #711 and #1620\n // if (graphicsData.lineWidth%2)\n // {\n // for (i = 0; i < points.length; i++)\n // {\n // points[i] += 0.5;\n // }\n // }\n var style = graphicsData.lineStyle;\n // get first and last point.. figure out the middle!\n var firstPoint = new Point(points[0], points[1]);\n var lastPoint = new Point(points[points.length - 2], points[points.length - 1]);\n var closedShape = shape.type !== SHAPES.POLY || shape.closeStroke;\n var closedPath = Math.abs(firstPoint.x - lastPoint.x) < eps\n && Math.abs(firstPoint.y - lastPoint.y) < eps;\n // if the first point is the last point - gonna have issues :)\n if (closedShape) {\n // need to clone as we are going to slightly modify the shape..\n points = points.slice();\n if (closedPath) {\n points.pop();\n points.pop();\n lastPoint.set(points[points.length - 2], points[points.length - 1]);\n }\n var midPointX = (firstPoint.x + lastPoint.x) * 0.5;\n var midPointY = (lastPoint.y + firstPoint.y) * 0.5;\n points.unshift(midPointX, midPointY);\n points.push(midPointX, midPointY);\n }\n var verts = graphicsGeometry.points;\n var length = points.length / 2;\n var indexCount = points.length;\n var indexStart = verts.length / 2;\n // Max. inner and outer width\n var width = style.width / 2;\n var widthSquared = width * width;\n var miterLimitSquared = style.miterLimit * style.miterLimit;\n /* Line segments of interest where (x1,y1) forms the corner. */\n var x0 = points[0];\n var y0 = points[1];\n var x1 = points[2];\n var y1 = points[3];\n var x2 = 0;\n var y2 = 0;\n /* perp[?](x|y) = the line normal with magnitude lineWidth. */\n var perpx = -(y0 - y1);\n var perpy = x0 - x1;\n var perp1x = 0;\n var perp1y = 0;\n var dist = Math.sqrt((perpx * perpx) + (perpy * perpy));\n perpx /= dist;\n perpy /= dist;\n perpx *= width;\n perpy *= width;\n var ratio = style.alignment; // 0.5;\n var innerWeight = (1 - ratio) * 2;\n var outerWeight = ratio * 2;\n if (!closedShape) {\n if (style.cap === LINE_CAP.ROUND) {\n indexCount += round(x0 - (perpx * (innerWeight - outerWeight) * 0.5), y0 - (perpy * (innerWeight - outerWeight) * 0.5), x0 - (perpx * innerWeight), y0 - (perpy * innerWeight), x0 + (perpx * outerWeight), y0 + (perpy * outerWeight), verts, true) + 2;\n }\n else if (style.cap === LINE_CAP.SQUARE) {\n indexCount += square(x0, y0, perpx, perpy, innerWeight, outerWeight, true, verts);\n }\n }\n // Push first point (below & above vertices)\n verts.push(x0 - (perpx * innerWeight), y0 - (perpy * innerWeight));\n verts.push(x0 + (perpx * outerWeight), y0 + (perpy * outerWeight));\n for (var i = 1; i < length - 1; ++i) {\n x0 = points[(i - 1) * 2];\n y0 = points[((i - 1) * 2) + 1];\n x1 = points[i * 2];\n y1 = points[(i * 2) + 1];\n x2 = points[(i + 1) * 2];\n y2 = points[((i + 1) * 2) + 1];\n perpx = -(y0 - y1);\n perpy = x0 - x1;\n dist = Math.sqrt((perpx * perpx) + (perpy * perpy));\n perpx /= dist;\n perpy /= dist;\n perpx *= width;\n perpy *= width;\n perp1x = -(y1 - y2);\n perp1y = x1 - x2;\n dist = Math.sqrt((perp1x * perp1x) + (perp1y * perp1y));\n perp1x /= dist;\n perp1y /= dist;\n perp1x *= width;\n perp1y *= width;\n /* d[x|y](0|1) = the component displacement between points p(0,1|1,2) */\n var dx0 = x1 - x0;\n var dy0 = y0 - y1;\n var dx1 = x1 - x2;\n var dy1 = y2 - y1;\n /* +ve if internal angle counterclockwise, -ve if internal angle clockwise. */\n var cross = (dy0 * dx1) - (dy1 * dx0);\n var clockwise = (cross < 0);\n /* Going nearly straight? */\n if (Math.abs(cross) < 0.1) {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight));\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight));\n continue;\n }\n /* p[x|y] is the miter point. pdist is the distance between miter point and p1. */\n var c1 = ((-perpx + x0) * (-perpy + y1)) - ((-perpx + x1) * (-perpy + y0));\n var c2 = ((-perp1x + x2) * (-perp1y + y1)) - ((-perp1x + x1) * (-perp1y + y2));\n var px = ((dx0 * c2) - (dx1 * c1)) / cross;\n var py = ((dy1 * c1) - (dy0 * c2)) / cross;\n var pdist = ((px - x1) * (px - x1)) + ((py - y1) * (py - y1));\n /* Inner miter point */\n var imx = x1 + ((px - x1) * innerWeight);\n var imy = y1 + ((py - y1) * innerWeight);\n /* Outer miter point */\n var omx = x1 - ((px - x1) * outerWeight);\n var omy = y1 - ((py - y1) * outerWeight);\n /* Is the inside miter point too far away, creating a spike? */\n var smallerInsideSegmentSq = Math.min((dx0 * dx0) + (dy0 * dy0), (dx1 * dx1) + (dy1 * dy1));\n var insideWeight = clockwise ? innerWeight : outerWeight;\n var smallerInsideDiagonalSq = smallerInsideSegmentSq + (insideWeight * insideWeight * widthSquared);\n var insideMiterOk = pdist <= smallerInsideDiagonalSq;\n if (insideMiterOk) {\n if (style.join === LINE_JOIN.BEVEL || pdist / widthSquared > miterLimitSquared) {\n if (clockwise) /* rotating at inner angle */ {\n verts.push(imx, imy); // inner miter point\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight)); // first segment's outer vertex\n verts.push(imx, imy); // inner miter point\n verts.push(x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight)); // second segment's outer vertex\n }\n else /* rotating at outer angle */ {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight)); // first segment's inner vertex\n verts.push(omx, omy); // outer miter point\n verts.push(x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight)); // second segment's outer vertex\n verts.push(omx, omy); // outer miter point\n }\n indexCount += 2;\n }\n else if (style.join === LINE_JOIN.ROUND) {\n if (clockwise) /* arc is outside */ {\n verts.push(imx, imy);\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight));\n indexCount += round(x1, y1, x1 + (perpx * outerWeight), y1 + (perpy * outerWeight), x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight), verts, true) + 4;\n verts.push(imx, imy);\n verts.push(x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight));\n }\n else /* arc is inside */ {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight));\n verts.push(omx, omy);\n indexCount += round(x1, y1, x1 - (perpx * innerWeight), y1 - (perpy * innerWeight), x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight), verts, false) + 4;\n verts.push(x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight));\n verts.push(omx, omy);\n }\n }\n else {\n verts.push(imx, imy);\n verts.push(omx, omy);\n }\n }\n else // inside miter is NOT ok\n {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight)); // first segment's inner vertex\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight)); // first segment's outer vertex\n if (style.join === LINE_JOIN.BEVEL || pdist / widthSquared > miterLimitSquared) ;\n else if (style.join === LINE_JOIN.ROUND) {\n if (clockwise) /* arc is outside */ {\n indexCount += round(x1, y1, x1 + (perpx * outerWeight), y1 + (perpy * outerWeight), x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight), verts, true) + 2;\n }\n else /* arc is inside */ {\n indexCount += round(x1, y1, x1 - (perpx * innerWeight), y1 - (perpy * innerWeight), x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight), verts, false) + 2;\n }\n }\n else {\n if (clockwise) {\n verts.push(omx, omy); // inner miter point\n verts.push(omx, omy); // inner miter point\n }\n else {\n verts.push(imx, imy); // outer miter point\n verts.push(imx, imy); // outer miter point\n }\n indexCount += 2;\n }\n verts.push(x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight)); // second segment's inner vertex\n verts.push(x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight)); // second segment's outer vertex\n indexCount += 2;\n }\n }\n x0 = points[(length - 2) * 2];\n y0 = points[((length - 2) * 2) + 1];\n x1 = points[(length - 1) * 2];\n y1 = points[((length - 1) * 2) + 1];\n perpx = -(y0 - y1);\n perpy = x0 - x1;\n dist = Math.sqrt((perpx * perpx) + (perpy * perpy));\n perpx /= dist;\n perpy /= dist;\n perpx *= width;\n perpy *= width;\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight));\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight));\n if (!closedShape) {\n if (style.cap === LINE_CAP.ROUND) {\n indexCount += round(x1 - (perpx * (innerWeight - outerWeight) * 0.5), y1 - (perpy * (innerWeight - outerWeight) * 0.5), x1 - (perpx * innerWeight), y1 - (perpy * innerWeight), x1 + (perpx * outerWeight), y1 + (perpy * outerWeight), verts, false) + 2;\n }\n else if (style.cap === LINE_CAP.SQUARE) {\n indexCount += square(x1, y1, perpx, perpy, innerWeight, outerWeight, false, verts);\n }\n }\n var indices = graphicsGeometry.indices;\n var eps2 = GRAPHICS_CURVES.epsilon * GRAPHICS_CURVES.epsilon;\n // indices.push(indexStart);\n for (var i = indexStart; i < indexCount + indexStart - 2; ++i) {\n x0 = verts[(i * 2)];\n y0 = verts[(i * 2) + 1];\n x1 = verts[(i + 1) * 2];\n y1 = verts[((i + 1) * 2) + 1];\n x2 = verts[(i + 2) * 2];\n y2 = verts[((i + 2) * 2) + 1];\n /* Skip zero area triangles */\n if (Math.abs((x0 * (y1 - y2)) + (x1 * (y2 - y0)) + (x2 * (y0 - y1))) < eps2) {\n continue;\n }\n indices.push(i, i + 1, i + 2);\n }\n}\n/**\n * Builds a line to draw using the gl.drawArrays(gl.LINES) method\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.GraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {PIXI.GraphicsGeometry} graphicsGeometry - Geometry where to append output\n */\nfunction buildNativeLine(graphicsData, graphicsGeometry) {\n var i = 0;\n var shape = graphicsData.shape;\n var points = graphicsData.points || shape.points;\n var closedShape = shape.type !== SHAPES.POLY || shape.closeStroke;\n if (points.length === 0)\n { return; }\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n var length = points.length / 2;\n var startIndex = verts.length / 2;\n var currentIndex = startIndex;\n verts.push(points[0], points[1]);\n for (i = 1; i < length; i++) {\n verts.push(points[i * 2], points[(i * 2) + 1]);\n indices.push(currentIndex, currentIndex + 1);\n currentIndex++;\n }\n if (closedShape) {\n indices.push(currentIndex, startIndex);\n }\n}\n/**\n * Builds a line to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.GraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {PIXI.GraphicsGeometry} graphicsGeometry - Geometry where to append output\n */\nfunction buildLine(graphicsData, graphicsGeometry) {\n if (graphicsData.lineStyle.native) {\n buildNativeLine(graphicsData, graphicsGeometry);\n }\n else {\n buildNonNativeLine(graphicsData, graphicsGeometry);\n }\n}\n\n/**\n * Utilities for arc curves.\n *\n * @private\n */\nvar ArcUtils = /** @class */ (function () {\n function ArcUtils() {\n }\n /**\n * The arcTo() method creates an arc/curve between two tangents on the canvas.\n *\n * \"borrowed\" from https://code.google.com/p/fxcanvas/ - thanks google!\n *\n * @private\n * @param x1 - The x-coordinate of the beginning of the arc\n * @param y1 - The y-coordinate of the beginning of the arc\n * @param x2 - The x-coordinate of the end of the arc\n * @param y2 - The y-coordinate of the end of the arc\n * @param radius - The radius of the arc\n * @return - If the arc length is valid, return center of circle, radius and other info otherwise `null`.\n */\n ArcUtils.curveTo = function (x1, y1, x2, y2, radius, points) {\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n var a1 = fromY - y1;\n var b1 = fromX - x1;\n var a2 = y2 - y1;\n var b2 = x2 - x1;\n var mm = Math.abs((a1 * b2) - (b1 * a2));\n if (mm < 1.0e-8 || radius === 0) {\n if (points[points.length - 2] !== x1 || points[points.length - 1] !== y1) {\n points.push(x1, y1);\n }\n return null;\n }\n var dd = (a1 * a1) + (b1 * b1);\n var cc = (a2 * a2) + (b2 * b2);\n var tt = (a1 * a2) + (b1 * b2);\n var k1 = radius * Math.sqrt(dd) / mm;\n var k2 = radius * Math.sqrt(cc) / mm;\n var j1 = k1 * tt / dd;\n var j2 = k2 * tt / cc;\n var cx = (k1 * b2) + (k2 * b1);\n var cy = (k1 * a2) + (k2 * a1);\n var px = b1 * (k2 + j1);\n var py = a1 * (k2 + j1);\n var qx = b2 * (k1 + j2);\n var qy = a2 * (k1 + j2);\n var startAngle = Math.atan2(py - cy, px - cx);\n var endAngle = Math.atan2(qy - cy, qx - cx);\n return {\n cx: (cx + x1),\n cy: (cy + y1),\n radius: radius,\n startAngle: startAngle,\n endAngle: endAngle,\n anticlockwise: (b1 * a2 > b2 * a1),\n };\n };\n /* eslint-disable max-len */\n /**\n * The arc method creates an arc/curve (used to create circles, or parts of circles).\n *\n * @private\n * @param startX - Start x location of arc\n * @param startY - Start y location of arc\n * @param cx - The x-coordinate of the center of the circle\n * @param cy - The y-coordinate of the center of the circle\n * @param radius - The radius of the circle\n * @param startAngle - The starting angle, in radians (0 is at the 3 o'clock position\n * of the arc's circle)\n * @param endAngle - The ending angle, in radians\n * @param anticlockwise - Specifies whether the drawing should be\n * counter-clockwise or clockwise. False is default, and indicates clockwise, while true\n * indicates counter-clockwise.\n * @param points - Collection of points to add to\n */\n ArcUtils.arc = function (_startX, _startY, cx, cy, radius, startAngle, endAngle, _anticlockwise, points) {\n var sweep = endAngle - startAngle;\n var n = GRAPHICS_CURVES._segmentsCount(Math.abs(sweep) * radius, Math.ceil(Math.abs(sweep) / PI_2) * 40);\n var theta = (sweep) / (n * 2);\n var theta2 = theta * 2;\n var cTheta = Math.cos(theta);\n var sTheta = Math.sin(theta);\n var segMinus = n - 1;\n var remainder = (segMinus % 1) / segMinus;\n for (var i = 0; i <= segMinus; ++i) {\n var real = i + (remainder * i);\n var angle = ((theta) + startAngle + (theta2 * real));\n var c = Math.cos(angle);\n var s = -Math.sin(angle);\n points.push((((cTheta * c) + (sTheta * s)) * radius) + cx, (((cTheta * -s) + (sTheta * c)) * radius) + cy);\n }\n };\n return ArcUtils;\n}());\n\n/**\n * Utilities for bezier curves\n *\n * @private\n */\nvar BezierUtils = /** @class */ (function () {\n function BezierUtils() {\n }\n /**\n * Calculate length of bezier curve.\n * Analytical solution is impossible, since it involves an integral that does not integrate in general.\n * Therefore numerical solution is used.\n *\n * @private\n * @param fromX - Starting point x\n * @param fromY - Starting point y\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param cpX2 - Second Control point x\n * @param cpY2 - Second Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @return - Length of bezier curve\n */\n BezierUtils.curveLength = function (fromX, fromY, cpX, cpY, cpX2, cpY2, toX, toY) {\n var n = 10;\n var result = 0.0;\n var t = 0.0;\n var t2 = 0.0;\n var t3 = 0.0;\n var nt = 0.0;\n var nt2 = 0.0;\n var nt3 = 0.0;\n var x = 0.0;\n var y = 0.0;\n var dx = 0.0;\n var dy = 0.0;\n var prevX = fromX;\n var prevY = fromY;\n for (var i = 1; i <= n; ++i) {\n t = i / n;\n t2 = t * t;\n t3 = t2 * t;\n nt = (1.0 - t);\n nt2 = nt * nt;\n nt3 = nt2 * nt;\n x = (nt3 * fromX) + (3.0 * nt2 * t * cpX) + (3.0 * nt * t2 * cpX2) + (t3 * toX);\n y = (nt3 * fromY) + (3.0 * nt2 * t * cpY) + (3 * nt * t2 * cpY2) + (t3 * toY);\n dx = prevX - x;\n dy = prevY - y;\n prevX = x;\n prevY = y;\n result += Math.sqrt((dx * dx) + (dy * dy));\n }\n return result;\n };\n /**\n * Calculate the points for a bezier curve and then draws it.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param cpX2 - Second Control point x\n * @param cpY2 - Second Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @param points - Path array to push points into\n */\n BezierUtils.curveTo = function (cpX, cpY, cpX2, cpY2, toX, toY, points) {\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n points.length -= 2;\n var n = GRAPHICS_CURVES._segmentsCount(BezierUtils.curveLength(fromX, fromY, cpX, cpY, cpX2, cpY2, toX, toY));\n var dt = 0;\n var dt2 = 0;\n var dt3 = 0;\n var t2 = 0;\n var t3 = 0;\n points.push(fromX, fromY);\n for (var i = 1, j = 0; i <= n; ++i) {\n j = i / n;\n dt = (1 - j);\n dt2 = dt * dt;\n dt3 = dt2 * dt;\n t2 = j * j;\n t3 = t2 * j;\n points.push((dt3 * fromX) + (3 * dt2 * j * cpX) + (3 * dt * t2 * cpX2) + (t3 * toX), (dt3 * fromY) + (3 * dt2 * j * cpY) + (3 * dt * t2 * cpY2) + (t3 * toY));\n }\n };\n return BezierUtils;\n}());\n\n/**\n * Utilities for quadratic curves.\n *\n * @private\n */\nvar QuadraticUtils = /** @class */ (function () {\n function QuadraticUtils() {\n }\n /**\n * Calculate length of quadratic curve\n * @see {@link http://www.malczak.linuxpl.com/blog/quadratic-bezier-curve-length/}\n * for the detailed explanation of math behind this.\n *\n * @private\n * @param fromX - x-coordinate of curve start point\n * @param fromY - y-coordinate of curve start point\n * @param cpX - x-coordinate of curve control point\n * @param cpY - y-coordinate of curve control point\n * @param toX - x-coordinate of curve end point\n * @param toY - y-coordinate of curve end point\n * @return - Length of quadratic curve\n */\n QuadraticUtils.curveLength = function (fromX, fromY, cpX, cpY, toX, toY) {\n var ax = fromX - (2.0 * cpX) + toX;\n var ay = fromY - (2.0 * cpY) + toY;\n var bx = (2.0 * cpX) - (2.0 * fromX);\n var by = (2.0 * cpY) - (2.0 * fromY);\n var a = 4.0 * ((ax * ax) + (ay * ay));\n var b = 4.0 * ((ax * bx) + (ay * by));\n var c = (bx * bx) + (by * by);\n var s = 2.0 * Math.sqrt(a + b + c);\n var a2 = Math.sqrt(a);\n var a32 = 2.0 * a * a2;\n var c2 = 2.0 * Math.sqrt(c);\n var ba = b / a2;\n return ((a32 * s)\n + (a2 * b * (s - c2))\n + (((4.0 * c * a) - (b * b))\n * Math.log(((2.0 * a2) + ba + s) / (ba + c2)))) / (4.0 * a32);\n };\n /**\n * Calculate the points for a quadratic bezier curve and then draws it.\n * Based on: https://stackoverflow.com/questions/785097/how-do-i-implement-a-bezier-curve-in-c\n *\n * @private\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @param points - Points to add segments to.\n */\n QuadraticUtils.curveTo = function (cpX, cpY, toX, toY, points) {\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n var n = GRAPHICS_CURVES._segmentsCount(QuadraticUtils.curveLength(fromX, fromY, cpX, cpY, toX, toY));\n var xa = 0;\n var ya = 0;\n for (var i = 1; i <= n; ++i) {\n var j = i / n;\n xa = fromX + ((cpX - fromX) * j);\n ya = fromY + ((cpY - fromY) * j);\n points.push(xa + (((cpX + ((toX - cpX) * j)) - xa) * j), ya + (((cpY + ((toY - cpY) * j)) - ya) * j));\n }\n };\n return QuadraticUtils;\n}());\n\n/**\n * A structure to hold interim batch objects for Graphics.\n *\n * @memberof PIXI.graphicsUtils\n */\nvar BatchPart = /** @class */ (function () {\n function BatchPart() {\n this.reset();\n }\n /** Begin batch part. */\n BatchPart.prototype.begin = function (style, startIndex, attribStart) {\n this.reset();\n this.style = style;\n this.start = startIndex;\n this.attribStart = attribStart;\n };\n /** End batch part. */\n BatchPart.prototype.end = function (endIndex, endAttrib) {\n this.attribSize = endAttrib - this.attribStart;\n this.size = endIndex - this.start;\n };\n BatchPart.prototype.reset = function () {\n this.style = null;\n this.size = 0;\n this.start = 0;\n this.attribStart = 0;\n this.attribSize = 0;\n };\n return BatchPart;\n}());\n\n/**\n * Generalized convenience utilities for Graphics.\n *\n * @namespace graphicsUtils\n * @memberof PIXI\n */\nvar _a;\n/**\n * Map of fill commands for each shape type.\n *\n * @memberof PIXI.graphicsUtils\n * @member {Object} FILL_COMMANDS\n */\nvar FILL_COMMANDS = (_a = {},\n _a[SHAPES.POLY] = buildPoly,\n _a[SHAPES.CIRC] = buildCircle,\n _a[SHAPES.ELIP] = buildCircle,\n _a[SHAPES.RECT] = buildRectangle,\n _a[SHAPES.RREC] = buildRoundedRectangle,\n _a);\n/**\n * Batch pool, stores unused batches for preventing allocations.\n *\n * @memberof PIXI.graphicsUtils\n * @member {Array<PIXI.graphicsUtils.BatchPart>} BATCH_POOL\n */\nvar BATCH_POOL = [];\n/**\n * Draw call pool, stores unused draw calls for preventing allocations.\n *\n * @memberof PIXI.graphicsUtils\n * @member {Array<PIXI.BatchDrawCall>} DRAW_CALL_POOL\n */\nvar DRAW_CALL_POOL = [];\n\n/**\n * A class to contain data useful for Graphics objects\n *\n * @memberof PIXI\n */\nvar GraphicsData = /** @class */ (function () {\n /**\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - The shape object to draw.\n * @param fillStyle - the width of the line to draw\n * @param lineStyle - the color of the line to draw\n * @param matrix - Transform matrix\n */\n function GraphicsData(shape, fillStyle, lineStyle, matrix) {\n if (fillStyle === void 0) { fillStyle = null; }\n if (lineStyle === void 0) { lineStyle = null; }\n if (matrix === void 0) { matrix = null; }\n /** The collection of points. */\n this.points = [];\n /** The collection of holes. */\n this.holes = [];\n this.shape = shape;\n this.lineStyle = lineStyle;\n this.fillStyle = fillStyle;\n this.matrix = matrix;\n this.type = shape.type;\n }\n /**\n * Creates a new GraphicsData object with the same values as this one.\n *\n * @return - Cloned GraphicsData object\n */\n GraphicsData.prototype.clone = function () {\n return new GraphicsData(this.shape, this.fillStyle, this.lineStyle, this.matrix);\n };\n /** Destroys the Graphics data. */\n GraphicsData.prototype.destroy = function () {\n this.shape = null;\n this.holes.length = 0;\n this.holes = null;\n this.points.length = 0;\n this.points = null;\n this.lineStyle = null;\n this.fillStyle = null;\n };\n return GraphicsData;\n}());\n\nvar tmpPoint = new Point();\nvar tmpBounds = new Bounds();\n/**\n * The Graphics class contains methods used to draw primitive shapes such as lines, circles and\n * rectangles to the display, and to color and fill them.\n *\n * GraphicsGeometry is designed to not be continually updating the geometry since it's expensive\n * to re-tesselate using **earcut**. Consider using {@link PIXI.Mesh} for this use-case, it's much faster.\n *\n * @memberof PIXI\n */\nvar GraphicsGeometry = /** @class */ (function (_super) {\n __extends(GraphicsGeometry, _super);\n // eslint-disable-next-line @typescript-eslint/no-useless-constructor\n function GraphicsGeometry() {\n var _this = _super.call(this) || this;\n /**\n * Minimal distance between points that are considered different.\n * Affects line tesselation.\n */\n _this.closePointEps = 1e-4;\n /** Padding to add to the bounds. */\n _this.boundsPadding = 0;\n _this.uvsFloat32 = null;\n _this.indicesUint16 = null;\n _this.batchable = false;\n /** An array of points to draw, 2 numbers per point */\n _this.points = [];\n /** The collection of colors */\n _this.colors = [];\n /** The UVs collection */\n _this.uvs = [];\n /** The indices of the vertices */\n _this.indices = [];\n /** Reference to the texture IDs. */\n _this.textureIds = [];\n /**\n * The collection of drawn shapes.\n *\n * @member {PIXI.GraphicsData[]}\n */\n _this.graphicsData = [];\n /**\n * List of current draw calls drived from the batches.\n *\n * @member {PIXI.BatchDrawCall[]}\n */\n _this.drawCalls = [];\n /** Batches need to regenerated if the geometry is updated. */\n _this.batchDirty = -1;\n /**\n * Intermediate abstract format sent to batch system.\n * Can be converted to drawCalls or to batchable objects.\n *\n * @member {PIXI.graphicsUtils.BatchPart[]}\n */\n _this.batches = [];\n /** Used to detect if the graphics object has changed. */\n _this.dirty = 0;\n /** Used to check if the cache is dirty. */\n _this.cacheDirty = -1;\n /** Used to detect if we cleared the graphicsData. */\n _this.clearDirty = 0;\n /** Index of the last batched shape in the stack of calls. */\n _this.shapeIndex = 0;\n /** Cached bounds. */\n _this._bounds = new Bounds();\n /** The bounds dirty flag. */\n _this.boundsDirty = -1;\n return _this;\n }\n Object.defineProperty(GraphicsGeometry.prototype, \"bounds\", {\n /**\n * Get the current bounds of the graphic geometry.\n *\n * @readonly\n */\n get: function () {\n if (this.boundsDirty !== this.dirty) {\n this.boundsDirty = this.dirty;\n this.calculateBounds();\n }\n return this._bounds;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Call if you changed graphicsData manually.\n * Empties all batch buffers.\n */\n GraphicsGeometry.prototype.invalidate = function () {\n this.boundsDirty = -1;\n this.dirty++;\n this.batchDirty++;\n this.shapeIndex = 0;\n this.points.length = 0;\n this.colors.length = 0;\n this.uvs.length = 0;\n this.indices.length = 0;\n this.textureIds.length = 0;\n for (var i = 0; i < this.drawCalls.length; i++) {\n this.drawCalls[i].texArray.clear();\n DRAW_CALL_POOL.push(this.drawCalls[i]);\n }\n this.drawCalls.length = 0;\n for (var i = 0; i < this.batches.length; i++) {\n var batchPart = this.batches[i];\n batchPart.reset();\n BATCH_POOL.push(batchPart);\n }\n this.batches.length = 0;\n };\n /**\n * Clears the graphics that were drawn to this Graphics object, and resets fill and line style settings.\n *\n * @return - This GraphicsGeometry object. Good for chaining method calls\n */\n GraphicsGeometry.prototype.clear = function () {\n if (this.graphicsData.length > 0) {\n this.invalidate();\n this.clearDirty++;\n this.graphicsData.length = 0;\n }\n return this;\n };\n /**\n * Draws the given shape to this Graphics object. Can be any of Circle, Rectangle, Ellipse, Line or Polygon.\n *\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - The shape object to draw.\n * @param fillStyle - Defines style of the fill.\n * @param lineStyle - Defines style of the lines.\n * @param matrix - Transform applied to the points of the shape.\n * @return - Returns geometry for chaining.\n */\n GraphicsGeometry.prototype.drawShape = function (shape, fillStyle, lineStyle, matrix) {\n if (fillStyle === void 0) { fillStyle = null; }\n if (lineStyle === void 0) { lineStyle = null; }\n if (matrix === void 0) { matrix = null; }\n var data = new GraphicsData(shape, fillStyle, lineStyle, matrix);\n this.graphicsData.push(data);\n this.dirty++;\n return this;\n };\n /**\n * Draws the given shape to this Graphics object. Can be any of Circle, Rectangle, Ellipse, Line or Polygon.\n *\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - The shape object to draw.\n * @param matrix - Transform applied to the points of the shape.\n * @return - Returns geometry for chaining.\n */\n GraphicsGeometry.prototype.drawHole = function (shape, matrix) {\n if (matrix === void 0) { matrix = null; }\n if (!this.graphicsData.length) {\n return null;\n }\n var data = new GraphicsData(shape, null, null, matrix);\n var lastShape = this.graphicsData[this.graphicsData.length - 1];\n data.lineStyle = lastShape.lineStyle;\n lastShape.holes.push(data);\n this.dirty++;\n return this;\n };\n /** Destroys the GraphicsGeometry object. */\n GraphicsGeometry.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n // destroy each of the GraphicsData objects\n for (var i = 0; i < this.graphicsData.length; ++i) {\n this.graphicsData[i].destroy();\n }\n this.points.length = 0;\n this.points = null;\n this.colors.length = 0;\n this.colors = null;\n this.uvs.length = 0;\n this.uvs = null;\n this.indices.length = 0;\n this.indices = null;\n this.indexBuffer.destroy();\n this.indexBuffer = null;\n this.graphicsData.length = 0;\n this.graphicsData = null;\n this.drawCalls.length = 0;\n this.drawCalls = null;\n this.batches.length = 0;\n this.batches = null;\n this._bounds = null;\n };\n /**\n * Check to see if a point is contained within this geometry.\n *\n * @param point - Point to check if it's contained.\n * @return {Boolean} `true` if the point is contained within geometry.\n */\n GraphicsGeometry.prototype.containsPoint = function (point) {\n var graphicsData = this.graphicsData;\n for (var i = 0; i < graphicsData.length; ++i) {\n var data = graphicsData[i];\n if (!data.fillStyle.visible) {\n continue;\n }\n // only deal with fills..\n if (data.shape) {\n if (data.matrix) {\n data.matrix.applyInverse(point, tmpPoint);\n }\n else {\n tmpPoint.copyFrom(point);\n }\n if (data.shape.contains(tmpPoint.x, tmpPoint.y)) {\n var hitHole = false;\n if (data.holes) {\n for (var i_1 = 0; i_1 < data.holes.length; i_1++) {\n var hole = data.holes[i_1];\n if (hole.shape.contains(tmpPoint.x, tmpPoint.y)) {\n hitHole = true;\n break;\n }\n }\n }\n if (!hitHole) {\n return true;\n }\n }\n }\n }\n return false;\n };\n /**\n * Generates intermediate batch data. Either gets converted to drawCalls\n * or used to convert to batch objects directly by the Graphics object.\n *\n * @param allow32Indices - Allow using 32-bit indices for preventing artifacts when more that 65535 vertices\n */\n GraphicsGeometry.prototype.updateBatches = function (allow32Indices) {\n if (!this.graphicsData.length) {\n this.batchable = true;\n return;\n }\n if (!this.validateBatching()) {\n return;\n }\n this.cacheDirty = this.dirty;\n var uvs = this.uvs;\n var graphicsData = this.graphicsData;\n var batchPart = null;\n var currentStyle = null;\n if (this.batches.length > 0) {\n batchPart = this.batches[this.batches.length - 1];\n currentStyle = batchPart.style;\n }\n for (var i = this.shapeIndex; i < graphicsData.length; i++) {\n this.shapeIndex++;\n var data = graphicsData[i];\n var fillStyle = data.fillStyle;\n var lineStyle = data.lineStyle;\n var command = FILL_COMMANDS[data.type];\n // build out the shapes points..\n command.build(data);\n if (data.matrix) {\n this.transformPoints(data.points, data.matrix);\n }\n if (fillStyle.visible || lineStyle.visible) {\n this.processHoles(data.holes);\n }\n for (var j = 0; j < 2; j++) {\n var style = (j === 0) ? fillStyle : lineStyle;\n if (!style.visible)\n { continue; }\n var nextTexture = style.texture.baseTexture;\n var index_1 = this.indices.length;\n var attribIndex = this.points.length / 2;\n nextTexture.wrapMode = WRAP_MODES.REPEAT;\n if (j === 0) {\n this.processFill(data);\n }\n else {\n this.processLine(data);\n }\n var size = (this.points.length / 2) - attribIndex;\n if (size === 0)\n { continue; }\n // close batch if style is different\n if (batchPart && !this._compareStyles(currentStyle, style)) {\n batchPart.end(index_1, attribIndex);\n batchPart = null;\n }\n // spawn new batch if its first batch or previous was closed\n if (!batchPart) {\n batchPart = BATCH_POOL.pop() || new BatchPart();\n batchPart.begin(style, index_1, attribIndex);\n this.batches.push(batchPart);\n currentStyle = style;\n }\n this.addUvs(this.points, uvs, style.texture, attribIndex, size, style.matrix);\n }\n }\n var index = this.indices.length;\n var attrib = this.points.length / 2;\n if (batchPart) {\n batchPart.end(index, attrib);\n }\n if (this.batches.length === 0) {\n // there are no visible styles in GraphicsData\n // its possible that someone wants Graphics just for the bounds\n this.batchable = true;\n return;\n }\n // prevent allocation when length is same as buffer\n if (this.indicesUint16 && this.indices.length === this.indicesUint16.length) {\n this.indicesUint16.set(this.indices);\n }\n else {\n var need32 = attrib > 0xffff && allow32Indices;\n this.indicesUint16 = need32 ? new Uint32Array(this.indices) : new Uint16Array(this.indices);\n }\n // TODO make this a const..\n this.batchable = this.isBatchable();\n if (this.batchable) {\n this.packBatches();\n }\n else {\n this.buildDrawCalls();\n }\n };\n /**\n * Affinity check\n *\n * @param styleA\n * @param styleB\n */\n GraphicsGeometry.prototype._compareStyles = function (styleA, styleB) {\n if (!styleA || !styleB) {\n return false;\n }\n if (styleA.texture.baseTexture !== styleB.texture.baseTexture) {\n return false;\n }\n if (styleA.color + styleA.alpha !== styleB.color + styleB.alpha) {\n return false;\n }\n if (!!styleA.native !== !!styleB.native) {\n return false;\n }\n return true;\n };\n /** Test geometry for batching process. */\n GraphicsGeometry.prototype.validateBatching = function () {\n if (this.dirty === this.cacheDirty || !this.graphicsData.length) {\n return false;\n }\n for (var i = 0, l = this.graphicsData.length; i < l; i++) {\n var data = this.graphicsData[i];\n var fill = data.fillStyle;\n var line = data.lineStyle;\n if (fill && !fill.texture.baseTexture.valid)\n { return false; }\n if (line && !line.texture.baseTexture.valid)\n { return false; }\n }\n return true;\n };\n /** Offset the indices so that it works with the batcher. */\n GraphicsGeometry.prototype.packBatches = function () {\n this.batchDirty++;\n this.uvsFloat32 = new Float32Array(this.uvs);\n var batches = this.batches;\n for (var i = 0, l = batches.length; i < l; i++) {\n var batch = batches[i];\n for (var j = 0; j < batch.size; j++) {\n var index = batch.start + j;\n this.indicesUint16[index] = this.indicesUint16[index] - batch.attribStart;\n }\n }\n };\n /**\n * Checks to see if this graphics geometry can be batched.\n * Currently it needs to be small enough and not contain any native lines.\n */\n GraphicsGeometry.prototype.isBatchable = function () {\n // prevent heavy mesh batching\n if (this.points.length > 0xffff * 2) {\n return false;\n }\n var batches = this.batches;\n for (var i = 0; i < batches.length; i++) {\n if (batches[i].style.native) {\n return false;\n }\n }\n return (this.points.length < GraphicsGeometry.BATCHABLE_SIZE * 2);\n };\n /** Converts intermediate batches data to drawCalls. */\n GraphicsGeometry.prototype.buildDrawCalls = function () {\n var TICK = ++BaseTexture._globalBatch;\n for (var i = 0; i < this.drawCalls.length; i++) {\n this.drawCalls[i].texArray.clear();\n DRAW_CALL_POOL.push(this.drawCalls[i]);\n }\n this.drawCalls.length = 0;\n var colors = this.colors;\n var textureIds = this.textureIds;\n var currentGroup = DRAW_CALL_POOL.pop();\n if (!currentGroup) {\n currentGroup = new BatchDrawCall();\n currentGroup.texArray = new BatchTextureArray();\n }\n currentGroup.texArray.count = 0;\n currentGroup.start = 0;\n currentGroup.size = 0;\n currentGroup.type = DRAW_MODES.TRIANGLES;\n var textureCount = 0;\n var currentTexture = null;\n var textureId = 0;\n var native = false;\n var drawMode = DRAW_MODES.TRIANGLES;\n var index = 0;\n this.drawCalls.push(currentGroup);\n // TODO - this can be simplified\n for (var i = 0; i < this.batches.length; i++) {\n var data = this.batches[i];\n // TODO add some full on MAX_TEXTURE CODE..\n var MAX_TEXTURES = 8;\n // Forced cast for checking `native` without errors\n var style = data.style;\n var nextTexture = style.texture.baseTexture;\n if (native !== !!style.native) {\n native = !!style.native;\n drawMode = native ? DRAW_MODES.LINES : DRAW_MODES.TRIANGLES;\n // force the batch to break!\n currentTexture = null;\n textureCount = MAX_TEXTURES;\n TICK++;\n }\n if (currentTexture !== nextTexture) {\n currentTexture = nextTexture;\n if (nextTexture._batchEnabled !== TICK) {\n if (textureCount === MAX_TEXTURES) {\n TICK++;\n textureCount = 0;\n if (currentGroup.size > 0) {\n currentGroup = DRAW_CALL_POOL.pop();\n if (!currentGroup) {\n currentGroup = new BatchDrawCall();\n currentGroup.texArray = new BatchTextureArray();\n }\n this.drawCalls.push(currentGroup);\n }\n currentGroup.start = index;\n currentGroup.size = 0;\n currentGroup.texArray.count = 0;\n currentGroup.type = drawMode;\n }\n // TODO add this to the render part..\n // Hack! Because texture has protected `touched`\n nextTexture.touched = 1; // touch;\n nextTexture._batchEnabled = TICK;\n nextTexture._batchLocation = textureCount;\n nextTexture.wrapMode = WRAP_MODES.REPEAT;\n currentGroup.texArray.elements[currentGroup.texArray.count++] = nextTexture;\n textureCount++;\n }\n }\n currentGroup.size += data.size;\n index += data.size;\n textureId = nextTexture._batchLocation;\n this.addColors(colors, style.color, style.alpha, data.attribSize, data.attribStart);\n this.addTextureIds(textureIds, textureId, data.attribSize, data.attribStart);\n }\n BaseTexture._globalBatch = TICK;\n // upload..\n // merge for now!\n this.packAttributes();\n };\n /** Packs attributes to single buffer. */\n GraphicsGeometry.prototype.packAttributes = function () {\n var verts = this.points;\n var uvs = this.uvs;\n var colors = this.colors;\n var textureIds = this.textureIds;\n // verts are 2 positions.. so we * by 3 as there are 6 properties.. then 4 cos its bytes\n var glPoints = new ArrayBuffer(verts.length * 3 * 4);\n var f32 = new Float32Array(glPoints);\n var u32 = new Uint32Array(glPoints);\n var p = 0;\n for (var i = 0; i < verts.length / 2; i++) {\n f32[p++] = verts[i * 2];\n f32[p++] = verts[(i * 2) + 1];\n f32[p++] = uvs[i * 2];\n f32[p++] = uvs[(i * 2) + 1];\n u32[p++] = colors[i];\n f32[p++] = textureIds[i];\n }\n this._buffer.update(glPoints);\n this._indexBuffer.update(this.indicesUint16);\n };\n /** Process fill part of Graphics. */\n GraphicsGeometry.prototype.processFill = function (data) {\n if (data.holes.length) {\n buildPoly.triangulate(data, this);\n }\n else {\n var command = FILL_COMMANDS[data.type];\n command.triangulate(data, this);\n }\n };\n /** Process line part of Graphics. */\n GraphicsGeometry.prototype.processLine = function (data) {\n buildLine(data, this);\n for (var i = 0; i < data.holes.length; i++) {\n buildLine(data.holes[i], this);\n }\n };\n /** Process the holes data. */\n GraphicsGeometry.prototype.processHoles = function (holes) {\n for (var i = 0; i < holes.length; i++) {\n var hole = holes[i];\n var command = FILL_COMMANDS[hole.type];\n command.build(hole);\n if (hole.matrix) {\n this.transformPoints(hole.points, hole.matrix);\n }\n }\n };\n /** Update the local bounds of the object. Expensive to use performance-wise. */\n GraphicsGeometry.prototype.calculateBounds = function () {\n var bounds = this._bounds;\n var sequenceBounds = tmpBounds;\n var curMatrix = Matrix.IDENTITY;\n this._bounds.clear();\n sequenceBounds.clear();\n for (var i = 0; i < this.graphicsData.length; i++) {\n var data = this.graphicsData[i];\n var shape = data.shape;\n var type = data.type;\n var lineStyle = data.lineStyle;\n var nextMatrix = data.matrix || Matrix.IDENTITY;\n var lineWidth = 0.0;\n if (lineStyle && lineStyle.visible) {\n lineWidth = lineStyle.width * Math.max(0, lineStyle.alignment);\n }\n if (curMatrix !== nextMatrix) {\n if (!sequenceBounds.isEmpty()) {\n bounds.addBoundsMatrix(sequenceBounds, curMatrix);\n sequenceBounds.clear();\n }\n curMatrix = nextMatrix;\n }\n if (type === SHAPES.RECT || type === SHAPES.RREC) {\n var rect = shape;\n sequenceBounds.addFramePad(rect.x, rect.y, rect.x + rect.width, rect.y + rect.height, lineWidth, lineWidth);\n }\n else if (type === SHAPES.CIRC) {\n var circle = shape;\n sequenceBounds.addFramePad(circle.x, circle.y, circle.x, circle.y, circle.radius + lineWidth, circle.radius + lineWidth);\n }\n else if (type === SHAPES.ELIP) {\n var ellipse = shape;\n sequenceBounds.addFramePad(ellipse.x, ellipse.y, ellipse.x, ellipse.y, ellipse.width + lineWidth, ellipse.height + lineWidth);\n }\n else {\n var poly = shape;\n // adding directly to the bounds\n bounds.addVerticesMatrix(curMatrix, poly.points, 0, poly.points.length, lineWidth, lineWidth);\n }\n }\n if (!sequenceBounds.isEmpty()) {\n bounds.addBoundsMatrix(sequenceBounds, curMatrix);\n }\n bounds.pad(this.boundsPadding, this.boundsPadding);\n };\n /**\n * Transform points using matrix.\n *\n * @param points - Points to transform\n * @param matrix - Transform matrix\n */\n GraphicsGeometry.prototype.transformPoints = function (points, matrix) {\n for (var i = 0; i < points.length / 2; i++) {\n var x = points[(i * 2)];\n var y = points[(i * 2) + 1];\n points[(i * 2)] = (matrix.a * x) + (matrix.c * y) + matrix.tx;\n points[(i * 2) + 1] = (matrix.b * x) + (matrix.d * y) + matrix.ty;\n }\n };\n /**\n * Add colors.\n *\n * @param colors - List of colors to add to\n * @param color - Color to add\n * @param alpha - Alpha to use\n * @param size - Number of colors to add\n * @param offset\n */\n GraphicsGeometry.prototype.addColors = function (colors, color, alpha, size, offset) {\n if (offset === void 0) { offset = 0; }\n // TODO use the premultiply bits Ivan added\n var rgb = (color >> 16) + (color & 0xff00) + ((color & 0xff) << 16);\n var rgba = premultiplyTint(rgb, alpha);\n colors.length = Math.max(colors.length, offset + size);\n for (var i = 0; i < size; i++) {\n colors[offset + i] = rgba;\n }\n };\n /** Add texture id that the shader/fragment wants to use. */\n GraphicsGeometry.prototype.addTextureIds = function (textureIds, id, size, offset) {\n if (offset === void 0) { offset = 0; }\n textureIds.length = Math.max(textureIds.length, offset + size);\n for (var i = 0; i < size; i++) {\n textureIds[offset + i] = id;\n }\n };\n /**\n * Generates the UVs for a shape.\n *\n * @param verts - Vertices\n * @param uvs - UVs\n * @param texture - Reference to Texture\n * @param start - Index buffer start index.\n * @param size - The size/length for index buffer.\n * @param matrix - Optional transform for all points.\n */\n GraphicsGeometry.prototype.addUvs = function (verts, uvs, texture, start, size, matrix) {\n if (matrix === void 0) { matrix = null; }\n var index = 0;\n var uvsStart = uvs.length;\n var frame = texture.frame;\n while (index < size) {\n var x = verts[(start + index) * 2];\n var y = verts[((start + index) * 2) + 1];\n if (matrix) {\n var nx = (matrix.a * x) + (matrix.c * y) + matrix.tx;\n y = (matrix.b * x) + (matrix.d * y) + matrix.ty;\n x = nx;\n }\n index++;\n uvs.push(x / frame.width, y / frame.height);\n }\n var baseTexture = texture.baseTexture;\n if (frame.width < baseTexture.width\n || frame.height < baseTexture.height) {\n this.adjustUvs(uvs, texture, uvsStart, size);\n }\n };\n /**\n * Modify uvs array according to position of texture region\n * Does not work with rotated or trimmed textures\n *\n * @param uvs - array\n * @param texture - region\n * @param start - starting index for uvs\n * @param size - how many points to adjust\n */\n GraphicsGeometry.prototype.adjustUvs = function (uvs, texture, start, size) {\n var baseTexture = texture.baseTexture;\n var eps = 1e-6;\n var finish = start + (size * 2);\n var frame = texture.frame;\n var scaleX = frame.width / baseTexture.width;\n var scaleY = frame.height / baseTexture.height;\n var offsetX = frame.x / frame.width;\n var offsetY = frame.y / frame.height;\n var minX = Math.floor(uvs[start] + eps);\n var minY = Math.floor(uvs[start + 1] + eps);\n for (var i = start + 2; i < finish; i += 2) {\n minX = Math.min(minX, Math.floor(uvs[i] + eps));\n minY = Math.min(minY, Math.floor(uvs[i + 1] + eps));\n }\n offsetX -= minX;\n offsetY -= minY;\n for (var i = start; i < finish; i += 2) {\n uvs[i] = (uvs[i] + offsetX) * scaleX;\n uvs[i + 1] = (uvs[i + 1] + offsetY) * scaleY;\n }\n };\n /**\n * The maximum number of points to consider an object \"batchable\",\n * able to be batched by the renderer's batch system.\n\\ */\n GraphicsGeometry.BATCHABLE_SIZE = 100;\n return GraphicsGeometry;\n}(BatchGeometry));\n\n/**\n * Represents the line style for Graphics.\n *\n * @memberof PIXI\n */\nvar LineStyle = /** @class */ (function (_super) {\n __extends(LineStyle, _super);\n function LineStyle() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n /** The width (thickness) of any lines drawn. */\n _this.width = 0;\n /** The alignment of any lines drawn (0.5 = middle, 1 = outer, 0 = inner). WebGL only. */\n _this.alignment = 0.5;\n /** If true the lines will be draw using LINES instead of TRIANGLE_STRIP. */\n _this.native = false;\n /**\n * Line cap style.\n *\n * @member {PIXI.LINE_CAP}\n * @default PIXI.LINE_CAP.BUTT\n */\n _this.cap = LINE_CAP.BUTT;\n /**\n * Line join style.\n *\n * @member {PIXI.LINE_JOIN}\n * @default PIXI.LINE_JOIN.MITER\n */\n _this.join = LINE_JOIN.MITER;\n /** Miter limit. */\n _this.miterLimit = 10;\n return _this;\n }\n /** Clones the object. */\n LineStyle.prototype.clone = function () {\n var obj = new LineStyle();\n obj.color = this.color;\n obj.alpha = this.alpha;\n obj.texture = this.texture;\n obj.matrix = this.matrix;\n obj.visible = this.visible;\n obj.width = this.width;\n obj.alignment = this.alignment;\n obj.native = this.native;\n obj.cap = this.cap;\n obj.join = this.join;\n obj.miterLimit = this.miterLimit;\n return obj;\n };\n /** Reset the line style to default. */\n LineStyle.prototype.reset = function () {\n _super.prototype.reset.call(this);\n // Override default line style color\n this.color = 0x0;\n this.alignment = 0.5;\n this.width = 0;\n this.native = false;\n };\n return LineStyle;\n}(FillStyle));\n\nvar temp = new Float32Array(3);\n// a default shaders map used by graphics..\nvar DEFAULT_SHADERS = {};\n/**\n * The Graphics class is primarily used to render primitive shapes such as lines, circles and\n * rectangles to the display, and to color and fill them. However, you can also use a Graphics\n * object to build a list of primitives to use as a mask, or as a complex hitArea.\n *\n * Please note that due to legacy naming conventions, the behavior of some functions in this class\n * can be confusing. Each call to `drawRect()`, `drawPolygon()`, etc. actually stores that primitive\n * in the Geometry class's GraphicsGeometry object for later use in rendering or hit testing - the\n * functions do not directly draw anything to the screen. Similarly, the `clear()` function doesn't\n * change the screen, it simply resets the list of primitives, which can be useful if you want to\n * rebuild the contents of an existing Graphics object.\n *\n * Once a GraphicsGeometry list is built, you can re-use it in other Geometry objects as\n * an optimization, by passing it into a new Geometry object's constructor. Because of this\n * ability, it's important to call `destroy()` on Geometry objects once you are done with them, to\n * properly dereference each GraphicsGeometry and prevent memory leaks.\n *\n * @memberof PIXI\n */\nvar Graphics = /** @class */ (function (_super) {\n __extends(Graphics, _super);\n /**\n * @param geometry - Geometry to use, if omitted will create a new GraphicsGeometry instance.\n */\n function Graphics(geometry) {\n if (geometry === void 0) { geometry = null; }\n var _this = _super.call(this) || this;\n /**\n * Represents the vertex and fragment shaders that processes the geometry and runs on the GPU.\n * Can be shared between multiple Graphics objects.\n */\n _this.shader = null;\n /** Renderer plugin for batching */\n _this.pluginName = 'batch';\n /**\n * Current path\n *\n * @readonly\n */\n _this.currentPath = null;\n /** A collections of batches! These can be drawn by the renderer batch system. */\n _this.batches = [];\n /** Update dirty for limiting calculating tints for batches. */\n _this.batchTint = -1;\n /** Update dirty for limiting calculating batches.*/\n _this.batchDirty = -1;\n /** Copy of the object vertex data. */\n _this.vertexData = null;\n /** Current fill style. */\n _this._fillStyle = new FillStyle();\n /** Current line style. */\n _this._lineStyle = new LineStyle();\n /** Current shape transform matrix. */\n _this._matrix = null;\n /** Current hole mode is enabled. */\n _this._holeMode = false;\n /**\n * Represents the WebGL state the Graphics required to render, excludes shader and geometry. E.g.,\n * blend mode, culling, depth testing, direction of rendering triangles, backface, etc.\n */\n _this.state = State.for2d();\n _this._geometry = geometry || new GraphicsGeometry();\n _this._geometry.refCount++;\n /**\n * When cacheAsBitmap is set to true the graphics object will be rendered as if it was a sprite.\n * This is useful if your graphics element does not change often, as it will speed up the rendering\n * of the object in exchange for taking up texture memory. It is also useful if you need the graphics\n * object to be anti-aliased, because it will be rendered using canvas. This is not recommended if\n * you are constantly redrawing the graphics element.\n *\n * @name cacheAsBitmap\n * @member {boolean}\n * @memberof PIXI.Graphics#\n * @default false\n */\n _this._transformID = -1;\n // Set default\n _this.tint = 0xFFFFFF;\n _this.blendMode = BLEND_MODES.NORMAL;\n return _this;\n }\n Object.defineProperty(Graphics.prototype, \"geometry\", {\n /**\n * Includes vertex positions, face indices, normals, colors, UVs, and\n * custom attributes within buffers, reducing the cost of passing all\n * this data to the GPU. Can be shared between multiple Mesh or Graphics objects.\n *\n * @readonly\n */\n get: function () {\n return this._geometry;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Creates a new Graphics object with the same values as this one.\n * Note that only the geometry of the object is cloned, not its transform (position,scale,etc)\n *\n * @return - A clone of the graphics object\n */\n Graphics.prototype.clone = function () {\n this.finishPoly();\n return new Graphics(this._geometry);\n };\n Object.defineProperty(Graphics.prototype, \"blendMode\", {\n get: function () {\n return this.state.blendMode;\n },\n /**\n * The blend mode to be applied to the graphic shape. Apply a value of\n * `PIXI.BLEND_MODES.NORMAL` to reset the blend mode. Note that, since each\n * primitive in the GraphicsGeometry list is rendered sequentially, modes\n * such as `PIXI.BLEND_MODES.ADD` and `PIXI.BLEND_MODES.MULTIPLY` will\n * be applied per-primitive.\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n set: function (value) {\n this.state.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Graphics.prototype, \"tint\", {\n /**\n * The tint applied to each graphic shape. This is a hex value. A value of\n * 0xFFFFFF will remove any tint effect.\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n this._tint = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Graphics.prototype, \"fill\", {\n /**\n * The current fill style.\n *\n * @readonly\n */\n get: function () {\n return this._fillStyle;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Graphics.prototype, \"line\", {\n /**\n * The current line style.\n *\n * @readonly\n */\n get: function () {\n return this._lineStyle;\n },\n enumerable: false,\n configurable: true\n });\n Graphics.prototype.lineStyle = function (options, color, alpha, alignment, native) {\n if (options === void 0) { options = null; }\n if (color === void 0) { color = 0x0; }\n if (alpha === void 0) { alpha = 1; }\n if (alignment === void 0) { alignment = 0.5; }\n if (native === void 0) { native = false; }\n // Support non-object params: (width, color, alpha, alignment, native)\n if (typeof options === 'number') {\n options = { width: options, color: color, alpha: alpha, alignment: alignment, native: native };\n }\n return this.lineTextureStyle(options);\n };\n /**\n * Like line style but support texture for line fill.\n *\n * @param options - Collection of options for setting line style.\n * @param {number} [options.width=0] - width of the line to draw, will update the objects stored style\n * @param {PIXI.Texture} [options.texture=PIXI.Texture.WHITE] - Texture to use\n * @param {number} [options.color=0x0] - color of the line to draw, will update the objects stored style.\n * Default 0xFFFFFF if texture present.\n * @param {number} [options.alpha=1] - alpha of the line to draw, will update the objects stored style\n * @param {PIXI.Matrix} [options.matrix=null] - Texture matrix to transform texture\n * @param {number} [options.alignment=0.5] - alignment of the line to draw, (0 = inner, 0.5 = middle, 1 = outer).\n * WebGL only.\n * @param {boolean} [options.native=false] - If true the lines will be draw using LINES instead of TRIANGLE_STRIP\n * @param {PIXI.LINE_CAP}[options.cap=PIXI.LINE_CAP.BUTT] - line cap style\n * @param {PIXI.LINE_JOIN}[options.join=PIXI.LINE_JOIN.MITER] - line join style\n * @param {number}[options.miterLimit=10] - miter limit ratio\n * @return {PIXI.Graphics} This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.lineTextureStyle = function (options) {\n // Apply defaults\n options = Object.assign({\n width: 0,\n texture: Texture.WHITE,\n color: (options && options.texture) ? 0xFFFFFF : 0x0,\n alpha: 1,\n matrix: null,\n alignment: 0.5,\n native: false,\n cap: LINE_CAP.BUTT,\n join: LINE_JOIN.MITER,\n miterLimit: 10,\n }, options);\n if (this.currentPath) {\n this.startPoly();\n }\n var visible = options.width > 0 && options.alpha > 0;\n if (!visible) {\n this._lineStyle.reset();\n }\n else {\n if (options.matrix) {\n options.matrix = options.matrix.clone();\n options.matrix.invert();\n }\n Object.assign(this._lineStyle, { visible: visible }, options);\n }\n return this;\n };\n /**\n * Start a polygon object internally.\n *\n * @protected\n */\n Graphics.prototype.startPoly = function () {\n if (this.currentPath) {\n var points = this.currentPath.points;\n var len = this.currentPath.points.length;\n if (len > 2) {\n this.drawShape(this.currentPath);\n this.currentPath = new Polygon();\n this.currentPath.closeStroke = false;\n this.currentPath.points.push(points[len - 2], points[len - 1]);\n }\n }\n else {\n this.currentPath = new Polygon();\n this.currentPath.closeStroke = false;\n }\n };\n /**\n * Finish the polygon object.\n *\n * @protected\n */\n Graphics.prototype.finishPoly = function () {\n if (this.currentPath) {\n if (this.currentPath.points.length > 2) {\n this.drawShape(this.currentPath);\n this.currentPath = null;\n }\n else {\n this.currentPath.points.length = 0;\n }\n }\n };\n /**\n * Moves the current drawing position to x, y.\n *\n * @param x - the X coordinate to move to\n * @param y - the Y coordinate to move to\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.moveTo = function (x, y) {\n this.startPoly();\n this.currentPath.points[0] = x;\n this.currentPath.points[1] = y;\n return this;\n };\n /**\n * Draws a line using the current line style from the current drawing position to (x, y);\n * The current drawing position is then set to (x, y).\n *\n * @param x - the X coordinate to draw to\n * @param y - the Y coordinate to draw to\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.lineTo = function (x, y) {\n if (!this.currentPath) {\n this.moveTo(0, 0);\n }\n // remove duplicates..\n var points = this.currentPath.points;\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n if (fromX !== x || fromY !== y) {\n points.push(x, y);\n }\n return this;\n };\n /** Initialize the curve */\n Graphics.prototype._initCurve = function (x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (this.currentPath) {\n if (this.currentPath.points.length === 0) {\n this.currentPath.points = [x, y];\n }\n }\n else {\n this.moveTo(x, y);\n }\n };\n /**\n * Calculate the points for a quadratic bezier curve and then draws it.\n * Based on: https://stackoverflow.com/questions/785097/how-do-i-implement-a-bezier-curve-in-c\n *\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.quadraticCurveTo = function (cpX, cpY, toX, toY) {\n this._initCurve();\n var points = this.currentPath.points;\n if (points.length === 0) {\n this.moveTo(0, 0);\n }\n QuadraticUtils.curveTo(cpX, cpY, toX, toY, points);\n return this;\n };\n /**\n * Calculate the points for a bezier curve and then draws it.\n *\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param cpX2 - Second Control point x\n * @param cpY2 - Second Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @return This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.bezierCurveTo = function (cpX, cpY, cpX2, cpY2, toX, toY) {\n this._initCurve();\n BezierUtils.curveTo(cpX, cpY, cpX2, cpY2, toX, toY, this.currentPath.points);\n return this;\n };\n /**\n * The arcTo() method creates an arc/curve between two tangents on the canvas.\n *\n * \"borrowed\" from https://code.google.com/p/fxcanvas/ - thanks google!\n *\n * @param x1 - The x-coordinate of the first tangent point of the arc\n * @param y1 - The y-coordinate of the first tangent point of the arc\n * @param x2 - The x-coordinate of the end of the arc\n * @param y2 - The y-coordinate of the end of the arc\n * @param radius - The radius of the arc\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.arcTo = function (x1, y1, x2, y2, radius) {\n this._initCurve(x1, y1);\n var points = this.currentPath.points;\n var result = ArcUtils.curveTo(x1, y1, x2, y2, radius, points);\n if (result) {\n var cx = result.cx, cy = result.cy, radius_1 = result.radius, startAngle = result.startAngle, endAngle = result.endAngle, anticlockwise = result.anticlockwise;\n this.arc(cx, cy, radius_1, startAngle, endAngle, anticlockwise);\n }\n return this;\n };\n /**\n * The arc method creates an arc/curve (used to create circles, or parts of circles).\n *\n * @param cx - The x-coordinate of the center of the circle\n * @param cy - The y-coordinate of the center of the circle\n * @param radius - The radius of the circle\n * @param startAngle - The starting angle, in radians (0 is at the 3 o'clock position\n * of the arc's circle)\n * @param endAngle - The ending angle, in radians\n * @param anticlockwise - Specifies whether the drawing should be\n * counter-clockwise or clockwise. False is default, and indicates clockwise, while true\n * indicates counter-clockwise.\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.arc = function (cx, cy, radius, startAngle, endAngle, anticlockwise) {\n if (anticlockwise === void 0) { anticlockwise = false; }\n if (startAngle === endAngle) {\n return this;\n }\n if (!anticlockwise && endAngle <= startAngle) {\n endAngle += PI_2;\n }\n else if (anticlockwise && startAngle <= endAngle) {\n startAngle += PI_2;\n }\n var sweep = endAngle - startAngle;\n if (sweep === 0) {\n return this;\n }\n var startX = cx + (Math.cos(startAngle) * radius);\n var startY = cy + (Math.sin(startAngle) * radius);\n var eps = this._geometry.closePointEps;\n // If the currentPath exists, take its points. Otherwise call `moveTo` to start a path.\n var points = this.currentPath ? this.currentPath.points : null;\n if (points) {\n // TODO: make a better fix.\n // We check how far our start is from the last existing point\n var xDiff = Math.abs(points[points.length - 2] - startX);\n var yDiff = Math.abs(points[points.length - 1] - startY);\n if (xDiff < eps && yDiff < eps) ;\n else {\n points.push(startX, startY);\n }\n }\n else {\n this.moveTo(startX, startY);\n points = this.currentPath.points;\n }\n ArcUtils.arc(startX, startY, cx, cy, radius, startAngle, endAngle, anticlockwise, points);\n return this;\n };\n /**\n * Specifies a simple one-color fill that subsequent calls to other Graphics methods\n * (such as lineTo() or drawCircle()) use when drawing.\n *\n * @param color - the color of the fill\n * @param alpha - the alpha of the fill\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.beginFill = function (color, alpha) {\n if (color === void 0) { color = 0; }\n if (alpha === void 0) { alpha = 1; }\n return this.beginTextureFill({ texture: Texture.WHITE, color: color, alpha: alpha });\n };\n /**\n * Begin the texture fill\n *\n * @param options - Object object.\n * @param {PIXI.Texture} [options.texture=PIXI.Texture.WHITE] - Texture to fill\n * @param {number} [options.color=0xffffff] - Background to fill behind texture\n * @param {number} [options.alpha=1] - Alpha of fill\n * @param {PIXI.Matrix} [options.matrix=null] - Transform matrix\n * @return {PIXI.Graphics} This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.beginTextureFill = function (options) {\n // Apply defaults\n options = Object.assign({\n texture: Texture.WHITE,\n color: 0xFFFFFF,\n alpha: 1,\n matrix: null,\n }, options);\n if (this.currentPath) {\n this.startPoly();\n }\n var visible = options.alpha > 0;\n if (!visible) {\n this._fillStyle.reset();\n }\n else {\n if (options.matrix) {\n options.matrix = options.matrix.clone();\n options.matrix.invert();\n }\n Object.assign(this._fillStyle, { visible: visible }, options);\n }\n return this;\n };\n /**\n * Applies a fill to the lines and shapes that were added since the last call to the beginFill() method.\n *\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.endFill = function () {\n this.finishPoly();\n this._fillStyle.reset();\n return this;\n };\n /**\n * Draws a rectangle shape.\n *\n * @param x - The X coord of the top-left of the rectangle\n * @param y - The Y coord of the top-left of the rectangle\n * @param width - The width of the rectangle\n * @param height - The height of the rectangle\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawRect = function (x, y, width, height) {\n return this.drawShape(new Rectangle(x, y, width, height));\n };\n /**\n * Draw a rectangle shape with rounded/beveled corners.\n *\n * @param x - The X coord of the top-left of the rectangle\n * @param y - The Y coord of the top-left of the rectangle\n * @param width - The width of the rectangle\n * @param height - The height of the rectangle\n * @param radius - Radius of the rectangle corners\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawRoundedRect = function (x, y, width, height, radius) {\n return this.drawShape(new RoundedRectangle(x, y, width, height, radius));\n };\n /**\n * Draws a circle.\n *\n * @param x - The X coordinate of the center of the circle\n * @param y - The Y coordinate of the center of the circle\n * @param radius - The radius of the circle\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawCircle = function (x, y, radius) {\n return this.drawShape(new Circle(x, y, radius));\n };\n /**\n * Draws an ellipse.\n *\n * @param x - The X coordinate of the center of the ellipse\n * @param y - The Y coordinate of the center of the ellipse\n * @param width - The half width of the ellipse\n * @param height - The half height of the ellipse\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawEllipse = function (x, y, width, height) {\n return this.drawShape(new Ellipse(x, y, width, height));\n };\n /**\n * Draws a polygon using the given path.\n *\n * @param {number[]|PIXI.Point[]|PIXI.Polygon} path - The path data used to construct the polygon.\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawPolygon = function () {\n var arguments$1 = arguments;\n\n var path = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n path[_i] = arguments$1[_i];\n }\n var points;\n var closeStroke = true; // !!this._fillStyle;\n var poly = path[0];\n // check if data has points..\n if (poly.points) {\n closeStroke = poly.closeStroke;\n points = poly.points;\n }\n else if (Array.isArray(path[0])) {\n points = path[0];\n }\n else {\n points = path;\n }\n var shape = new Polygon(points);\n shape.closeStroke = closeStroke;\n this.drawShape(shape);\n return this;\n };\n /**\n * Draw any shape.\n *\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - Shape to draw\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawShape = function (shape) {\n if (!this._holeMode) {\n this._geometry.drawShape(shape, this._fillStyle.clone(), this._lineStyle.clone(), this._matrix);\n }\n else {\n this._geometry.drawHole(shape, this._matrix);\n }\n return this;\n };\n /**\n * Clears the graphics that were drawn to this Graphics object, and resets fill and line style settings.\n *\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.clear = function () {\n this._geometry.clear();\n this._lineStyle.reset();\n this._fillStyle.reset();\n this._boundsID++;\n this._matrix = null;\n this._holeMode = false;\n this.currentPath = null;\n return this;\n };\n /**\n * True if graphics consists of one rectangle, and thus, can be drawn like a Sprite and\n * masked with gl.scissor.\n *\n * @returns - True if only 1 rect.\n */\n Graphics.prototype.isFastRect = function () {\n var data = this._geometry.graphicsData;\n return data.length === 1\n && data[0].shape.type === SHAPES.RECT\n && !data[0].matrix\n && !data[0].holes.length\n && !(data[0].lineStyle.visible && data[0].lineStyle.width);\n };\n /**\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._render = function (renderer) {\n this.finishPoly();\n var geometry = this._geometry;\n var hasuint32 = renderer.context.supports.uint32Indices;\n // batch part..\n // batch it!\n geometry.updateBatches(hasuint32);\n if (geometry.batchable) {\n if (this.batchDirty !== geometry.batchDirty) {\n this._populateBatches();\n }\n this._renderBatched(renderer);\n }\n else {\n // no batching...\n renderer.batch.flush();\n this._renderDirect(renderer);\n }\n };\n /** Populating batches for rendering. */\n Graphics.prototype._populateBatches = function () {\n var geometry = this._geometry;\n var blendMode = this.blendMode;\n var len = geometry.batches.length;\n this.batchTint = -1;\n this._transformID = -1;\n this.batchDirty = geometry.batchDirty;\n this.batches.length = len;\n this.vertexData = new Float32Array(geometry.points);\n for (var i = 0; i < len; i++) {\n var gI = geometry.batches[i];\n var color = gI.style.color;\n var vertexData = new Float32Array(this.vertexData.buffer, gI.attribStart * 4 * 2, gI.attribSize * 2);\n var uvs = new Float32Array(geometry.uvsFloat32.buffer, gI.attribStart * 4 * 2, gI.attribSize * 2);\n var indices = new Uint16Array(geometry.indicesUint16.buffer, gI.start * 2, gI.size);\n var batch = {\n vertexData: vertexData,\n blendMode: blendMode,\n indices: indices,\n uvs: uvs,\n _batchRGB: hex2rgb(color),\n _tintRGB: color,\n _texture: gI.style.texture,\n alpha: gI.style.alpha,\n worldAlpha: 1\n };\n this.batches[i] = batch;\n }\n };\n /**\n * Renders the batches using the BathedRenderer plugin\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._renderBatched = function (renderer) {\n if (!this.batches.length) {\n return;\n }\n renderer.batch.setObjectRenderer(renderer.plugins[this.pluginName]);\n this.calculateVertices();\n this.calculateTints();\n for (var i = 0, l = this.batches.length; i < l; i++) {\n var batch = this.batches[i];\n batch.worldAlpha = this.worldAlpha * batch.alpha;\n renderer.plugins[this.pluginName].render(batch);\n }\n };\n /**\n * Renders the graphics direct\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._renderDirect = function (renderer) {\n var shader = this._resolveDirectShader(renderer);\n var geometry = this._geometry;\n var tint = this.tint;\n var worldAlpha = this.worldAlpha;\n var uniforms = shader.uniforms;\n var drawCalls = geometry.drawCalls;\n // lets set the transfomr\n uniforms.translationMatrix = this.transform.worldTransform;\n // and then lets set the tint..\n uniforms.tint[0] = (((tint >> 16) & 0xFF) / 255) * worldAlpha;\n uniforms.tint[1] = (((tint >> 8) & 0xFF) / 255) * worldAlpha;\n uniforms.tint[2] = ((tint & 0xFF) / 255) * worldAlpha;\n uniforms.tint[3] = worldAlpha;\n // the first draw call, we can set the uniforms of the shader directly here.\n // this means that we can tack advantage of the sync function of pixi!\n // bind and sync uniforms..\n // there is a way to optimise this..\n renderer.shader.bind(shader);\n renderer.geometry.bind(geometry, shader);\n // set state..\n renderer.state.set(this.state);\n // then render the rest of them...\n for (var i = 0, l = drawCalls.length; i < l; i++) {\n this._renderDrawCallDirect(renderer, geometry.drawCalls[i]);\n }\n };\n /** Renders specific DrawCall */\n Graphics.prototype._renderDrawCallDirect = function (renderer, drawCall) {\n var texArray = drawCall.texArray, type = drawCall.type, size = drawCall.size, start = drawCall.start;\n var groupTextureCount = texArray.count;\n for (var j = 0; j < groupTextureCount; j++) {\n renderer.texture.bind(texArray.elements[j], j);\n }\n renderer.geometry.draw(type, size, start);\n };\n /**\n * Resolves shader for direct rendering\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._resolveDirectShader = function (renderer) {\n var shader = this.shader;\n var pluginName = this.pluginName;\n if (!shader) {\n // if there is no shader here, we can use the default shader.\n // and that only gets created if we actually need it..\n // but may be more than one plugins for graphics\n if (!DEFAULT_SHADERS[pluginName]) {\n var MAX_TEXTURES = renderer.plugins.batch.MAX_TEXTURES;\n var sampleValues = new Int32Array(MAX_TEXTURES);\n for (var i = 0; i < MAX_TEXTURES; i++) {\n sampleValues[i] = i;\n }\n var uniforms = {\n tint: new Float32Array([1, 1, 1, 1]),\n translationMatrix: new Matrix(),\n default: UniformGroup.from({ uSamplers: sampleValues }, true),\n };\n var program = renderer.plugins[pluginName]._shader.program;\n DEFAULT_SHADERS[pluginName] = new Shader(program, uniforms);\n }\n shader = DEFAULT_SHADERS[pluginName];\n }\n return shader;\n };\n /** Retrieves the bounds of the graphic shape as a rectangle object. */\n Graphics.prototype._calculateBounds = function () {\n this.finishPoly();\n var geometry = this._geometry;\n // skipping when graphics is empty, like a container\n if (!geometry.graphicsData.length) {\n return;\n }\n var _a = geometry.bounds, minX = _a.minX, minY = _a.minY, maxX = _a.maxX, maxY = _a.maxY;\n this._bounds.addFrame(this.transform, minX, minY, maxX, maxY);\n };\n /**\n * Tests if a point is inside this graphics object\n *\n * @param point - the point to test\n * @return - the result of the test\n */\n Graphics.prototype.containsPoint = function (point) {\n this.worldTransform.applyInverse(point, Graphics._TEMP_POINT);\n return this._geometry.containsPoint(Graphics._TEMP_POINT);\n };\n /** Recalculate the tint by applying tint to batches using Graphics tint. */\n Graphics.prototype.calculateTints = function () {\n if (this.batchTint !== this.tint) {\n this.batchTint = this.tint;\n var tintRGB = hex2rgb(this.tint, temp);\n for (var i = 0; i < this.batches.length; i++) {\n var batch = this.batches[i];\n var batchTint = batch._batchRGB;\n var r = (tintRGB[0] * batchTint[0]) * 255;\n var g = (tintRGB[1] * batchTint[1]) * 255;\n var b = (tintRGB[2] * batchTint[2]) * 255;\n // TODO Ivan, can this be done in one go?\n var color = (r << 16) + (g << 8) + (b | 0);\n batch._tintRGB = (color >> 16)\n + (color & 0xff00)\n + ((color & 0xff) << 16);\n }\n }\n };\n /**\n * If there's a transform update or a change to the shape of the\n * geometry, recalculate the vertices.\n */\n Graphics.prototype.calculateVertices = function () {\n var wtID = this.transform._worldID;\n if (this._transformID === wtID) {\n return;\n }\n this._transformID = wtID;\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var data = this._geometry.points; // batch.vertexDataOriginal;\n var vertexData = this.vertexData;\n var count = 0;\n for (var i = 0; i < data.length; i += 2) {\n var x = data[i];\n var y = data[i + 1];\n vertexData[count++] = (a * x) + (c * y) + tx;\n vertexData[count++] = (d * y) + (b * x) + ty;\n }\n };\n /**\n * Closes the current path.\n *\n * @return - Returns itself.\n */\n Graphics.prototype.closePath = function () {\n var currentPath = this.currentPath;\n if (currentPath) {\n // we don't need to add extra point in the end because buildLine will take care of that\n currentPath.closeStroke = true;\n // ensure that the polygon is completed, and is available for hit detection\n // (even if the graphics is not rendered yet)\n this.finishPoly();\n }\n return this;\n };\n /**\n * Apply a matrix to the positional data.\n *\n * @param matrix - Matrix to use for transform current shape.\n * @return - Returns itself.\n */\n Graphics.prototype.setMatrix = function (matrix) {\n this._matrix = matrix;\n return this;\n };\n /**\n * Begin adding holes to the last draw shape\n * IMPORTANT: holes must be fully inside a shape to work\n * Also weirdness ensues if holes overlap!\n * Ellipses, Circles, Rectangles and Rounded Rectangles cannot be holes or host for holes in CanvasRenderer,\n * please use `moveTo` `lineTo`, `quadraticCurveTo` if you rely on pixi-legacy bundle.\n *\n * @return - Returns itself.\n */\n Graphics.prototype.beginHole = function () {\n this.finishPoly();\n this._holeMode = true;\n return this;\n };\n /**\n * End adding holes to the last draw shape.\n *\n * @return - Returns itself.\n */\n Graphics.prototype.endHole = function () {\n this.finishPoly();\n this._holeMode = false;\n return this;\n };\n /**\n * Destroys the Graphics object.\n *\n * @param options - Options parameter. A boolean will act as if all\n * options have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have\n * their destroy method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the texture of the child sprite\n * @param {boolean} [options.baseTexture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the base texture of the child sprite\n */\n Graphics.prototype.destroy = function (options) {\n this._geometry.refCount--;\n if (this._geometry.refCount === 0) {\n this._geometry.dispose();\n }\n this._matrix = null;\n this.currentPath = null;\n this._lineStyle.destroy();\n this._lineStyle = null;\n this._fillStyle.destroy();\n this._fillStyle = null;\n this._geometry = null;\n this.shader = null;\n this.vertexData = null;\n this.batches.length = 0;\n this.batches = null;\n _super.prototype.destroy.call(this, options);\n };\n /**\n * New rendering behavior for rounded rectangles: circular arcs instead of quadratic bezier curves.\n * In the next major release, we'll enable this by default.\n */\n Graphics.nextRoundedRectBehavior = false;\n /**\n * Temporary point to use for containsPoint.\n *\n * @private\n */\n Graphics._TEMP_POINT = new Point();\n return Graphics;\n}(Container));\n\nvar graphicsUtils = {\n buildPoly: buildPoly,\n buildCircle: buildCircle,\n buildRectangle: buildRectangle,\n buildRoundedRectangle: buildRoundedRectangle,\n buildLine: buildLine,\n ArcUtils: ArcUtils,\n BezierUtils: BezierUtils,\n QuadraticUtils: QuadraticUtils,\n BatchPart: BatchPart,\n FILL_COMMANDS: FILL_COMMANDS,\n BATCH_POOL: BATCH_POOL,\n DRAW_CALL_POOL: DRAW_CALL_POOL\n};\n\nexport { FillStyle, GRAPHICS_CURVES, Graphics, GraphicsData, GraphicsGeometry, LINE_CAP, LINE_JOIN, LineStyle, graphicsUtils };\n//# sourceMappingURL=graphics.js.map\n","/*!\n * @pixi/text - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/text is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Sprite } from '@pixi/sprite';\nimport { Texture } from '@pixi/core';\nimport { settings } from '@pixi/settings';\nimport { Rectangle } from '@pixi/math';\nimport { hex2string, hex2rgb, string2hex, trimCanvas, sign } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * Constants that define the type of gradient on text.\n *\n * @static\n * @constant\n * @name TEXT_GRADIENT\n * @memberof PIXI\n * @type {object}\n * @property {number} LINEAR_VERTICAL Vertical gradient\n * @property {number} LINEAR_HORIZONTAL Linear gradient\n */\nvar TEXT_GRADIENT;\n(function (TEXT_GRADIENT) {\n TEXT_GRADIENT[TEXT_GRADIENT[\"LINEAR_VERTICAL\"] = 0] = \"LINEAR_VERTICAL\";\n TEXT_GRADIENT[TEXT_GRADIENT[\"LINEAR_HORIZONTAL\"] = 1] = \"LINEAR_HORIZONTAL\";\n})(TEXT_GRADIENT || (TEXT_GRADIENT = {}));\n\n// disabling eslint for now, going to rewrite this in v5\nvar defaultStyle = {\n align: 'left',\n breakWords: false,\n dropShadow: false,\n dropShadowAlpha: 1,\n dropShadowAngle: Math.PI / 6,\n dropShadowBlur: 0,\n dropShadowColor: 'black',\n dropShadowDistance: 5,\n fill: 'black',\n fillGradientType: TEXT_GRADIENT.LINEAR_VERTICAL,\n fillGradientStops: [],\n fontFamily: 'Arial',\n fontSize: 26,\n fontStyle: 'normal',\n fontVariant: 'normal',\n fontWeight: 'normal',\n letterSpacing: 0,\n lineHeight: 0,\n lineJoin: 'miter',\n miterLimit: 10,\n padding: 0,\n stroke: 'black',\n strokeThickness: 0,\n textBaseline: 'alphabetic',\n trim: false,\n whiteSpace: 'pre',\n wordWrap: false,\n wordWrapWidth: 100,\n leading: 0,\n};\nvar genericFontFamilies = [\n 'serif',\n 'sans-serif',\n 'monospace',\n 'cursive',\n 'fantasy',\n 'system-ui' ];\n/**\n * A TextStyle Object contains information to decorate a Text objects.\n *\n * An instance can be shared between multiple Text objects; then changing the style will update all text objects using it.\n *\n * A tool can be used to generate a text style [here](https://pixijs.io/pixi-text-style).\n *\n * @memberof PIXI\n */\nvar TextStyle = /** @class */ (function () {\n /**\n * @param {object} [style] - The style parameters\n * @param {string} [style.align='left'] - Alignment for multiline text ('left', 'center' or 'right'),\n * does not affect single line text\n * @param {boolean} [style.breakWords=false] - Indicates if lines can be wrapped within words, it\n * needs wordWrap to be set to true\n * @param {boolean} [style.dropShadow=false] - Set a drop shadow for the text\n * @param {number} [style.dropShadowAlpha=1] - Set alpha for the drop shadow\n * @param {number} [style.dropShadowAngle=Math.PI/6] - Set a angle of the drop shadow\n * @param {number} [style.dropShadowBlur=0] - Set a shadow blur radius\n * @param {string|number} [style.dropShadowColor='black'] - A fill style to be used on the dropshadow e.g 'red', '#00FF00'\n * @param {number} [style.dropShadowDistance=5] - Set a distance of the drop shadow\n * @param {string|string[]|number|number[]|CanvasGradient|CanvasPattern} [style.fill='black'] - A canvas\n * fillstyle that will be used on the text e.g 'red', '#00FF00'. Can be an array to create a gradient\n * eg ['#000000','#FFFFFF']\n * {@link https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/fillStyle|MDN}\n * @param {number} [style.fillGradientType=PIXI.TEXT_GRADIENT.LINEAR_VERTICAL] - If fill is an array of colours\n * to create a gradient, this can change the type/direction of the gradient. See {@link PIXI.TEXT_GRADIENT}\n * @param {number[]} [style.fillGradientStops] - If fill is an array of colours to create a gradient, this array can set\n * the stop points (numbers between 0 and 1) for the color, overriding the default behaviour of evenly spacing them.\n * @param {string|string[]} [style.fontFamily='Arial'] - The font family\n * @param {number|string} [style.fontSize=26] - The font size (as a number it converts to px, but as a string,\n * equivalents are '26px','20pt','160%' or '1.6em')\n * @param {string} [style.fontStyle='normal'] - The font style ('normal', 'italic' or 'oblique')\n * @param {string} [style.fontVariant='normal'] - The font variant ('normal' or 'small-caps')\n * @param {string} [style.fontWeight='normal'] - The font weight ('normal', 'bold', 'bolder', 'lighter' and '100',\n * '200', '300', '400', '500', '600', '700', '800' or '900')\n * @param {number} [style.leading=0] - The space between lines\n * @param {number} [style.letterSpacing=0] - The amount of spacing between letters, default is 0\n * @param {number} [style.lineHeight] - The line height, a number that represents the vertical space that a letter uses\n * @param {string} [style.lineJoin='miter'] - The lineJoin property sets the type of corner created, it can resolve\n * spiked text issues. Possible values \"miter\" (creates a sharp corner), \"round\" (creates a round corner) or \"bevel\"\n * (creates a squared corner).\n * @param {number} [style.miterLimit=10] - The miter limit to use when using the 'miter' lineJoin mode. This can reduce\n * or increase the spikiness of rendered text.\n * @param {number} [style.padding=0] - Occasionally some fonts are cropped. Adding some padding will prevent this from\n * happening by adding padding to all sides of the text.\n * @param {string|number} [style.stroke='black'] - A canvas fillstyle that will be used on the text stroke\n * e.g 'blue', '#FCFF00'\n * @param {number} [style.strokeThickness=0] - A number that represents the thickness of the stroke.\n * Default is 0 (no stroke)\n * @param {boolean} [style.trim=false] - Trim transparent borders\n * @param {string} [style.textBaseline='alphabetic'] - The baseline of the text that is rendered.\n * @param {string} [style.whiteSpace='pre'] - Determines whether newlines & spaces are collapsed or preserved \"normal\"\n * (collapse, collapse), \"pre\" (preserve, preserve) | \"pre-line\" (preserve, collapse). It needs wordWrap to be set to true\n * @param {boolean} [style.wordWrap=false] - Indicates if word wrap should be used\n * @param {number} [style.wordWrapWidth=100] - The width at which text will wrap, it needs wordWrap to be set to true\n */\n function TextStyle(style) {\n this.styleID = 0;\n this.reset();\n deepCopyProperties(this, style, style);\n }\n /**\n * Creates a new TextStyle object with the same values as this one.\n * Note that the only the properties of the object are cloned.\n *\n * @return New cloned TextStyle object\n */\n TextStyle.prototype.clone = function () {\n var clonedProperties = {};\n deepCopyProperties(clonedProperties, this, defaultStyle);\n return new TextStyle(clonedProperties);\n };\n /** Resets all properties to the defaults specified in TextStyle.prototype._default */\n TextStyle.prototype.reset = function () {\n deepCopyProperties(this, defaultStyle, defaultStyle);\n };\n Object.defineProperty(TextStyle.prototype, \"align\", {\n /**\n * Alignment for multiline text ('left', 'center' or 'right'), does not affect single line text\n *\n * @member {string}\n */\n get: function () {\n return this._align;\n },\n set: function (align) {\n if (this._align !== align) {\n this._align = align;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"breakWords\", {\n /** Indicates if lines can be wrapped within words, it needs wordWrap to be set to true. */\n get: function () {\n return this._breakWords;\n },\n set: function (breakWords) {\n if (this._breakWords !== breakWords) {\n this._breakWords = breakWords;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadow\", {\n /** Set a drop shadow for the text. */\n get: function () {\n return this._dropShadow;\n },\n set: function (dropShadow) {\n if (this._dropShadow !== dropShadow) {\n this._dropShadow = dropShadow;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowAlpha\", {\n /** Set alpha for the drop shadow. */\n get: function () {\n return this._dropShadowAlpha;\n },\n set: function (dropShadowAlpha) {\n if (this._dropShadowAlpha !== dropShadowAlpha) {\n this._dropShadowAlpha = dropShadowAlpha;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowAngle\", {\n /** Set a angle of the drop shadow. */\n get: function () {\n return this._dropShadowAngle;\n },\n set: function (dropShadowAngle) {\n if (this._dropShadowAngle !== dropShadowAngle) {\n this._dropShadowAngle = dropShadowAngle;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowBlur\", {\n /** Set a shadow blur radius. */\n get: function () {\n return this._dropShadowBlur;\n },\n set: function (dropShadowBlur) {\n if (this._dropShadowBlur !== dropShadowBlur) {\n this._dropShadowBlur = dropShadowBlur;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowColor\", {\n /** A fill style to be used on the dropshadow e.g 'red', '#00FF00'. */\n get: function () {\n return this._dropShadowColor;\n },\n set: function (dropShadowColor) {\n var outputColor = getColor(dropShadowColor);\n if (this._dropShadowColor !== outputColor) {\n this._dropShadowColor = outputColor;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowDistance\", {\n /** Set a distance of the drop shadow. */\n get: function () {\n return this._dropShadowDistance;\n },\n set: function (dropShadowDistance) {\n if (this._dropShadowDistance !== dropShadowDistance) {\n this._dropShadowDistance = dropShadowDistance;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fill\", {\n /**\n * A canvas fillstyle that will be used on the text e.g 'red', '#00FF00'.\n *\n * Can be an array to create a gradient eg ['#000000','#FFFFFF']\n * {@link https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/fillStyle|MDN}\n *\n * @member {string|string[]|number|number[]|CanvasGradient|CanvasPattern}\n */\n get: function () {\n return this._fill;\n },\n set: function (fill) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n // TODO: Not sure if getColor works properly with CanvasGradient and/or CanvasPattern, can't pass in\n // without casting here.\n var outputColor = getColor(fill);\n if (this._fill !== outputColor) {\n this._fill = outputColor;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fillGradientType\", {\n /**\n * If fill is an array of colours to create a gradient, this can change the type/direction of the gradient.\n *\n * @see PIXI.TEXT_GRADIENT\n */\n get: function () {\n return this._fillGradientType;\n },\n set: function (fillGradientType) {\n if (this._fillGradientType !== fillGradientType) {\n this._fillGradientType = fillGradientType;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fillGradientStops\", {\n /**\n * If fill is an array of colours to create a gradient, this array can set the stop points\n * (numbers between 0 and 1) for the color, overriding the default behaviour of evenly spacing them.\n */\n get: function () {\n return this._fillGradientStops;\n },\n set: function (fillGradientStops) {\n if (!areArraysEqual(this._fillGradientStops, fillGradientStops)) {\n this._fillGradientStops = fillGradientStops;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontFamily\", {\n /** The font family. */\n get: function () {\n return this._fontFamily;\n },\n set: function (fontFamily) {\n if (this.fontFamily !== fontFamily) {\n this._fontFamily = fontFamily;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontSize\", {\n /**\n * The font size\n * (as a number it converts to px, but as a string, equivalents are '26px','20pt','160%' or '1.6em')\n */\n get: function () {\n return this._fontSize;\n },\n set: function (fontSize) {\n if (this._fontSize !== fontSize) {\n this._fontSize = fontSize;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontStyle\", {\n /**\n * The font style\n * ('normal', 'italic' or 'oblique')\n *\n * @member {string}\n */\n get: function () {\n return this._fontStyle;\n },\n set: function (fontStyle) {\n if (this._fontStyle !== fontStyle) {\n this._fontStyle = fontStyle;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontVariant\", {\n /**\n * The font variant\n * ('normal' or 'small-caps')\n *\n * @member {string}\n */\n get: function () {\n return this._fontVariant;\n },\n set: function (fontVariant) {\n if (this._fontVariant !== fontVariant) {\n this._fontVariant = fontVariant;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontWeight\", {\n /**\n * The font weight\n * ('normal', 'bold', 'bolder', 'lighter' and '100', '200', '300', '400', '500', '600', '700', 800' or '900')\n *\n * @member {string}\n */\n get: function () {\n return this._fontWeight;\n },\n set: function (fontWeight) {\n if (this._fontWeight !== fontWeight) {\n this._fontWeight = fontWeight;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"letterSpacing\", {\n /** The amount of spacing between letters, default is 0. */\n get: function () {\n return this._letterSpacing;\n },\n set: function (letterSpacing) {\n if (this._letterSpacing !== letterSpacing) {\n this._letterSpacing = letterSpacing;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"lineHeight\", {\n /** The line height, a number that represents the vertical space that a letter uses. */\n get: function () {\n return this._lineHeight;\n },\n set: function (lineHeight) {\n if (this._lineHeight !== lineHeight) {\n this._lineHeight = lineHeight;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"leading\", {\n /** The space between lines. */\n get: function () {\n return this._leading;\n },\n set: function (leading) {\n if (this._leading !== leading) {\n this._leading = leading;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"lineJoin\", {\n /**\n * The lineJoin property sets the type of corner created, it can resolve spiked text issues.\n * Default is 'miter' (creates a sharp corner).\n *\n * @member {string}\n */\n get: function () {\n return this._lineJoin;\n },\n set: function (lineJoin) {\n if (this._lineJoin !== lineJoin) {\n this._lineJoin = lineJoin;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"miterLimit\", {\n /**\n * The miter limit to use when using the 'miter' lineJoin mode.\n *\n * This can reduce or increase the spikiness of rendered text.\n */\n get: function () {\n return this._miterLimit;\n },\n set: function (miterLimit) {\n if (this._miterLimit !== miterLimit) {\n this._miterLimit = miterLimit;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"padding\", {\n /**\n * Occasionally some fonts are cropped. Adding some padding will prevent this from happening\n * by adding padding to all sides of the text.\n */\n get: function () {\n return this._padding;\n },\n set: function (padding) {\n if (this._padding !== padding) {\n this._padding = padding;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"stroke\", {\n /**\n * A canvas fillstyle that will be used on the text stroke\n * e.g 'blue', '#FCFF00'\n */\n get: function () {\n return this._stroke;\n },\n set: function (stroke) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n var outputColor = getColor(stroke);\n if (this._stroke !== outputColor) {\n this._stroke = outputColor;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"strokeThickness\", {\n /**\n * A number that represents the thickness of the stroke.\n *\n * @default 0\n */\n get: function () {\n return this._strokeThickness;\n },\n set: function (strokeThickness) {\n if (this._strokeThickness !== strokeThickness) {\n this._strokeThickness = strokeThickness;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"textBaseline\", {\n /**\n * The baseline of the text that is rendered.\n *\n * @member {string}\n */\n get: function () {\n return this._textBaseline;\n },\n set: function (textBaseline) {\n if (this._textBaseline !== textBaseline) {\n this._textBaseline = textBaseline;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"trim\", {\n /** Trim transparent borders. */\n get: function () {\n return this._trim;\n },\n set: function (trim) {\n if (this._trim !== trim) {\n this._trim = trim;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"whiteSpace\", {\n /**\n * How newlines and spaces should be handled.\n * Default is 'pre' (preserve, preserve).\n *\n * value | New lines | Spaces\n * --- | --- | ---\n * 'normal' | Collapse | Collapse\n * 'pre' | Preserve | Preserve\n * 'pre-line' | Preserve | Collapse\n *\n * @member {string}\n */\n get: function () {\n return this._whiteSpace;\n },\n set: function (whiteSpace) {\n if (this._whiteSpace !== whiteSpace) {\n this._whiteSpace = whiteSpace;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"wordWrap\", {\n /** Indicates if word wrap should be used. */\n get: function () {\n return this._wordWrap;\n },\n set: function (wordWrap) {\n if (this._wordWrap !== wordWrap) {\n this._wordWrap = wordWrap;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"wordWrapWidth\", {\n /** The width at which text will wrap, it needs wordWrap to be set to true. */\n get: function () {\n return this._wordWrapWidth;\n },\n set: function (wordWrapWidth) {\n if (this._wordWrapWidth !== wordWrapWidth) {\n this._wordWrapWidth = wordWrapWidth;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Generates a font style string to use for `TextMetrics.measureFont()`.\n *\n * @return Font style string, for passing to `TextMetrics.measureFont()`\n */\n TextStyle.prototype.toFontString = function () {\n // build canvas api font setting from individual components. Convert a numeric this.fontSize to px\n var fontSizeString = (typeof this.fontSize === 'number') ? this.fontSize + \"px\" : this.fontSize;\n // Clean-up fontFamily property by quoting each font name\n // this will support font names with spaces\n var fontFamilies = this.fontFamily;\n if (!Array.isArray(this.fontFamily)) {\n fontFamilies = this.fontFamily.split(',');\n }\n for (var i = fontFamilies.length - 1; i >= 0; i--) {\n // Trim any extra white-space\n var fontFamily = fontFamilies[i].trim();\n // Check if font already contains strings\n if (!(/([\\\"\\'])[^\\'\\\"]+\\1/).test(fontFamily) && genericFontFamilies.indexOf(fontFamily) < 0) {\n fontFamily = \"\\\"\" + fontFamily + \"\\\"\";\n }\n fontFamilies[i] = fontFamily;\n }\n return this.fontStyle + \" \" + this.fontVariant + \" \" + this.fontWeight + \" \" + fontSizeString + \" \" + fontFamilies.join(',');\n };\n return TextStyle;\n}());\n/**\n * Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string.\n * @private\n * @param color\n * @return The color as a string.\n */\nfunction getSingleColor(color) {\n if (typeof color === 'number') {\n return hex2string(color);\n }\n else if (typeof color === 'string') {\n if (color.indexOf('0x') === 0) {\n color = color.replace('0x', '#');\n }\n }\n return color;\n}\nfunction getColor(color) {\n if (!Array.isArray(color)) {\n return getSingleColor(color);\n }\n else {\n for (var i = 0; i < color.length; ++i) {\n color[i] = getSingleColor(color[i]);\n }\n return color;\n }\n}\n/**\n * Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string.\n * This version can also convert array of colors\n * @private\n * @param array1 - First array to compare\n * @param array2 - Second array to compare\n * @return Do the arrays contain the same values in the same order\n */\nfunction areArraysEqual(array1, array2) {\n if (!Array.isArray(array1) || !Array.isArray(array2)) {\n return false;\n }\n if (array1.length !== array2.length) {\n return false;\n }\n for (var i = 0; i < array1.length; ++i) {\n if (array1[i] !== array2[i]) {\n return false;\n }\n }\n return true;\n}\n/**\n * Utility function to ensure that object properties are copied by value, and not by reference\n * @private\n * @param target - Target object to copy properties into\n * @param source - Source object for the properties to copy\n * @param propertyObj - Object containing properties names we want to loop over\n */\nfunction deepCopyProperties(target, source, propertyObj) {\n for (var prop in propertyObj) {\n if (Array.isArray(source[prop])) {\n target[prop] = source[prop].slice();\n }\n else {\n target[prop] = source[prop];\n }\n }\n}\n\n/**\n * The TextMetrics object represents the measurement of a block of text with a specified style.\n *\n * ```js\n * let style = new PIXI.TextStyle({fontFamily : 'Arial', fontSize: 24, fill : 0xff1010, align : 'center'})\n * let textMetrics = PIXI.TextMetrics.measureText('Your text', style)\n * ```\n *\n * @memberof PIXI\n */\nvar TextMetrics = /** @class */ (function () {\n /**\n * @param text - the text that was measured\n * @param style - the style that was measured\n * @param width - the measured width of the text\n * @param height - the measured height of the text\n * @param lines - an array of the lines of text broken by new lines and wrapping if specified in style\n * @param lineWidths - an array of the line widths for each line matched to `lines`\n * @param lineHeight - the measured line height for this style\n * @param maxLineWidth - the maximum line width for all measured lines\n * @param {PIXI.IFontMetrics} fontProperties - the font properties object from TextMetrics.measureFont\n */\n function TextMetrics(text, style, width, height, lines, lineWidths, lineHeight, maxLineWidth, fontProperties) {\n this.text = text;\n this.style = style;\n this.width = width;\n this.height = height;\n this.lines = lines;\n this.lineWidths = lineWidths;\n this.lineHeight = lineHeight;\n this.maxLineWidth = maxLineWidth;\n this.fontProperties = fontProperties;\n }\n /**\n * Measures the supplied string of text and returns a Rectangle.\n *\n * @param text - The text to measure.\n * @param style - The text style to use for measuring\n * @param wordWrap - Override for if word-wrap should be applied to the text.\n * @param canvas - optional specification of the canvas to use for measuring.\n * @return Measured width and height of the text.\n */\n TextMetrics.measureText = function (text, style, wordWrap, canvas) {\n if (canvas === void 0) { canvas = TextMetrics._canvas; }\n wordWrap = (wordWrap === undefined || wordWrap === null) ? style.wordWrap : wordWrap;\n var font = style.toFontString();\n var fontProperties = TextMetrics.measureFont(font);\n // fallback in case UA disallow canvas data extraction\n // (toDataURI, getImageData functions)\n if (fontProperties.fontSize === 0) {\n fontProperties.fontSize = style.fontSize;\n fontProperties.ascent = style.fontSize;\n }\n var context = canvas.getContext('2d');\n context.font = font;\n var outputText = wordWrap ? TextMetrics.wordWrap(text, style, canvas) : text;\n var lines = outputText.split(/(?:\\r\\n|\\r|\\n)/);\n var lineWidths = new Array(lines.length);\n var maxLineWidth = 0;\n for (var i = 0; i < lines.length; i++) {\n var lineWidth = context.measureText(lines[i]).width + ((lines[i].length - 1) * style.letterSpacing);\n lineWidths[i] = lineWidth;\n maxLineWidth = Math.max(maxLineWidth, lineWidth);\n }\n var width = maxLineWidth + style.strokeThickness;\n if (style.dropShadow) {\n width += style.dropShadowDistance;\n }\n var lineHeight = style.lineHeight || fontProperties.fontSize + style.strokeThickness;\n var height = Math.max(lineHeight, fontProperties.fontSize + style.strokeThickness)\n + ((lines.length - 1) * (lineHeight + style.leading));\n if (style.dropShadow) {\n height += style.dropShadowDistance;\n }\n return new TextMetrics(text, style, width, height, lines, lineWidths, lineHeight + style.leading, maxLineWidth, fontProperties);\n };\n /**\n * Applies newlines to a string to have it optimally fit into the horizontal\n * bounds set by the Text object's wordWrapWidth property.\n *\n * @param text - String to apply word wrapping to\n * @param style - the style to use when wrapping\n * @param canvas - optional specification of the canvas to use for measuring.\n * @return New string with new lines applied where required\n */\n TextMetrics.wordWrap = function (text, style, canvas) {\n if (canvas === void 0) { canvas = TextMetrics._canvas; }\n var context = canvas.getContext('2d');\n var width = 0;\n var line = '';\n var lines = '';\n var cache = Object.create(null);\n var letterSpacing = style.letterSpacing, whiteSpace = style.whiteSpace;\n // How to handle whitespaces\n var collapseSpaces = TextMetrics.collapseSpaces(whiteSpace);\n var collapseNewlines = TextMetrics.collapseNewlines(whiteSpace);\n // whether or not spaces may be added to the beginning of lines\n var canPrependSpaces = !collapseSpaces;\n // There is letterSpacing after every char except the last one\n // t_h_i_s_' '_i_s_' '_a_n_' '_e_x_a_m_p_l_e_' '_!\n // so for convenience the above needs to be compared to width + 1 extra letterSpace\n // t_h_i_s_' '_i_s_' '_a_n_' '_e_x_a_m_p_l_e_' '_!_\n // ________________________________________________\n // And then the final space is simply no appended to each line\n var wordWrapWidth = style.wordWrapWidth + letterSpacing;\n // break text into words, spaces and newline chars\n var tokens = TextMetrics.tokenize(text);\n for (var i = 0; i < tokens.length; i++) {\n // get the word, space or newlineChar\n var token = tokens[i];\n // if word is a new line\n if (TextMetrics.isNewline(token)) {\n // keep the new line\n if (!collapseNewlines) {\n lines += TextMetrics.addLine(line);\n canPrependSpaces = !collapseSpaces;\n line = '';\n width = 0;\n continue;\n }\n // if we should collapse new lines\n // we simply convert it into a space\n token = ' ';\n }\n // if we should collapse repeated whitespaces\n if (collapseSpaces) {\n // check both this and the last tokens for spaces\n var currIsBreakingSpace = TextMetrics.isBreakingSpace(token);\n var lastIsBreakingSpace = TextMetrics.isBreakingSpace(line[line.length - 1]);\n if (currIsBreakingSpace && lastIsBreakingSpace) {\n continue;\n }\n }\n // get word width from cache if possible\n var tokenWidth = TextMetrics.getFromCache(token, letterSpacing, cache, context);\n // word is longer than desired bounds\n if (tokenWidth > wordWrapWidth) {\n // if we are not already at the beginning of a line\n if (line !== '') {\n // start newlines for overflow words\n lines += TextMetrics.addLine(line);\n line = '';\n width = 0;\n }\n // break large word over multiple lines\n if (TextMetrics.canBreakWords(token, style.breakWords)) {\n // break word into characters\n var characters = TextMetrics.wordWrapSplit(token);\n // loop the characters\n for (var j = 0; j < characters.length; j++) {\n var char = characters[j];\n var k = 1;\n // we are not at the end of the token\n while (characters[j + k]) {\n var nextChar = characters[j + k];\n var lastChar = char[char.length - 1];\n // should not split chars\n if (!TextMetrics.canBreakChars(lastChar, nextChar, token, j, style.breakWords)) {\n // combine chars & move forward one\n char += nextChar;\n }\n else {\n break;\n }\n k++;\n }\n j += char.length - 1;\n var characterWidth = TextMetrics.getFromCache(char, letterSpacing, cache, context);\n if (characterWidth + width > wordWrapWidth) {\n lines += TextMetrics.addLine(line);\n canPrependSpaces = false;\n line = '';\n width = 0;\n }\n line += char;\n width += characterWidth;\n }\n }\n // run word out of the bounds\n else {\n // if there are words in this line already\n // finish that line and start a new one\n if (line.length > 0) {\n lines += TextMetrics.addLine(line);\n line = '';\n width = 0;\n }\n var isLastToken = i === tokens.length - 1;\n // give it its own line if it's not the end\n lines += TextMetrics.addLine(token, !isLastToken);\n canPrependSpaces = false;\n line = '';\n width = 0;\n }\n }\n // word could fit\n else {\n // word won't fit because of existing words\n // start a new line\n if (tokenWidth + width > wordWrapWidth) {\n // if its a space we don't want it\n canPrependSpaces = false;\n // add a new line\n lines += TextMetrics.addLine(line);\n // start a new line\n line = '';\n width = 0;\n }\n // don't add spaces to the beginning of lines\n if (line.length > 0 || !TextMetrics.isBreakingSpace(token) || canPrependSpaces) {\n // add the word to the current line\n line += token;\n // update width counter\n width += tokenWidth;\n }\n }\n }\n lines += TextMetrics.addLine(line, false);\n return lines;\n };\n /**\n * Convienience function for logging each line added during the wordWrap method.\n *\n * @param line - The line of text to add\n * @param newLine - Add new line character to end\n * @return A formatted line\n */\n TextMetrics.addLine = function (line, newLine) {\n if (newLine === void 0) { newLine = true; }\n line = TextMetrics.trimRight(line);\n line = (newLine) ? line + \"\\n\" : line;\n return line;\n };\n /**\n * Gets & sets the widths of calculated characters in a cache object\n *\n * @param key - The key\n * @param letterSpacing - The letter spacing\n * @param cache - The cache\n * @param context - The canvas context\n * @return The from cache.\n */\n TextMetrics.getFromCache = function (key, letterSpacing, cache, context) {\n var width = cache[key];\n if (typeof width !== 'number') {\n var spacing = ((key.length) * letterSpacing);\n width = context.measureText(key).width + spacing;\n cache[key] = width;\n }\n return width;\n };\n /**\n * Determines whether we should collapse breaking spaces.\n *\n * @param whiteSpace - The TextStyle property whiteSpace\n * @return Should collapse\n */\n TextMetrics.collapseSpaces = function (whiteSpace) {\n return (whiteSpace === 'normal' || whiteSpace === 'pre-line');\n };\n /**\n * Determines whether we should collapse newLine chars.\n *\n * @param whiteSpace - The white space\n * @return should collapse\n */\n TextMetrics.collapseNewlines = function (whiteSpace) {\n return (whiteSpace === 'normal');\n };\n /**\n * Trims breaking whitespaces from string.\n *\n * @param text - The text\n * @return Trimmed string\n */\n TextMetrics.trimRight = function (text) {\n if (typeof text !== 'string') {\n return '';\n }\n for (var i = text.length - 1; i >= 0; i--) {\n var char = text[i];\n if (!TextMetrics.isBreakingSpace(char)) {\n break;\n }\n text = text.slice(0, -1);\n }\n return text;\n };\n /**\n * Determines if char is a newline.\n *\n * @param char - The character\n * @return True if newline, False otherwise.\n */\n TextMetrics.isNewline = function (char) {\n if (typeof char !== 'string') {\n return false;\n }\n return (TextMetrics._newlines.indexOf(char.charCodeAt(0)) >= 0);\n };\n /**\n * Determines if char is a breaking whitespace.\n *\n * It allows one to determine whether char should be a breaking whitespace\n * For example certain characters in CJK langs or numbers.\n * It must return a boolean.\n *\n * @param char - The character\n * @param [nextChar] - The next character\n * @return True if whitespace, False otherwise.\n */\n TextMetrics.isBreakingSpace = function (char, _nextChar) {\n if (typeof char !== 'string') {\n return false;\n }\n return (TextMetrics._breakingSpaces.indexOf(char.charCodeAt(0)) >= 0);\n };\n /**\n * Splits a string into words, breaking-spaces and newLine characters\n *\n * @param text - The text\n * @return A tokenized array\n */\n TextMetrics.tokenize = function (text) {\n var tokens = [];\n var token = '';\n if (typeof text !== 'string') {\n return tokens;\n }\n for (var i = 0; i < text.length; i++) {\n var char = text[i];\n var nextChar = text[i + 1];\n if (TextMetrics.isBreakingSpace(char, nextChar) || TextMetrics.isNewline(char)) {\n if (token !== '') {\n tokens.push(token);\n token = '';\n }\n tokens.push(char);\n continue;\n }\n token += char;\n }\n if (token !== '') {\n tokens.push(token);\n }\n return tokens;\n };\n /**\n * Overridable helper method used internally by TextMetrics, exposed to allow customizing the class's behavior.\n *\n * It allows one to customise which words should break\n * Examples are if the token is CJK or numbers.\n * It must return a boolean.\n *\n * @param token - The token\n * @param breakWords - The style attr break words\n * @return Whether to break word or not\n */\n TextMetrics.canBreakWords = function (_token, breakWords) {\n return breakWords;\n };\n /**\n * Overridable helper method used internally by TextMetrics, exposed to allow customizing the class's behavior.\n *\n * It allows one to determine whether a pair of characters\n * should be broken by newlines\n * For example certain characters in CJK langs or numbers.\n * It must return a boolean.\n *\n * @param char - The character\n * @param nextChar - The next character\n * @param token - The token/word the characters are from\n * @param index - The index in the token of the char\n * @param breakWords - The style attr break words\n * @return whether to break word or not\n */\n TextMetrics.canBreakChars = function (_char, _nextChar, _token, _index, _breakWords) {\n return true;\n };\n /**\n * Overridable helper method used internally by TextMetrics, exposed to allow customizing the class's behavior.\n *\n * It is called when a token (usually a word) has to be split into separate pieces\n * in order to determine the point to break a word.\n * It must return an array of characters.\n *\n * @example\n * // Correctly splits emojis, eg \"🤪🤪\" will result in two element array, each with one emoji.\n * TextMetrics.wordWrapSplit = (token) => [...token];\n *\n * @param token - The token to split\n * @return The characters of the token\n */\n TextMetrics.wordWrapSplit = function (token) {\n return token.split('');\n };\n /**\n * Calculates the ascent, descent and fontSize of a given font-style\n *\n * @param font - String representing the style of the font\n * @return Font properties object\n */\n TextMetrics.measureFont = function (font) {\n // as this method is used for preparing assets, don't recalculate things if we don't need to\n if (TextMetrics._fonts[font]) {\n return TextMetrics._fonts[font];\n }\n var properties = {\n ascent: 0,\n descent: 0,\n fontSize: 0,\n };\n var canvas = TextMetrics._canvas;\n var context = TextMetrics._context;\n context.font = font;\n var metricsString = TextMetrics.METRICS_STRING + TextMetrics.BASELINE_SYMBOL;\n var width = Math.ceil(context.measureText(metricsString).width);\n var baseline = Math.ceil(context.measureText(TextMetrics.BASELINE_SYMBOL).width);\n var height = Math.ceil(TextMetrics.HEIGHT_MULTIPLIER * baseline);\n baseline = baseline * TextMetrics.BASELINE_MULTIPLIER | 0;\n canvas.width = width;\n canvas.height = height;\n context.fillStyle = '#f00';\n context.fillRect(0, 0, width, height);\n context.font = font;\n context.textBaseline = 'alphabetic';\n context.fillStyle = '#000';\n context.fillText(metricsString, 0, baseline);\n var imagedata = context.getImageData(0, 0, width, height).data;\n var pixels = imagedata.length;\n var line = width * 4;\n var i = 0;\n var idx = 0;\n var stop = false;\n // ascent. scan from top to bottom until we find a non red pixel\n for (i = 0; i < baseline; ++i) {\n for (var j = 0; j < line; j += 4) {\n if (imagedata[idx + j] !== 255) {\n stop = true;\n break;\n }\n }\n if (!stop) {\n idx += line;\n }\n else {\n break;\n }\n }\n properties.ascent = baseline - i;\n idx = pixels - line;\n stop = false;\n // descent. scan from bottom to top until we find a non red pixel\n for (i = height; i > baseline; --i) {\n for (var j = 0; j < line; j += 4) {\n if (imagedata[idx + j] !== 255) {\n stop = true;\n break;\n }\n }\n if (!stop) {\n idx -= line;\n }\n else {\n break;\n }\n }\n properties.descent = i - baseline;\n properties.fontSize = properties.ascent + properties.descent;\n TextMetrics._fonts[font] = properties;\n return properties;\n };\n /**\n * Clear font metrics in metrics cache.\n *\n * @param {string} [font] - font name. If font name not set then clear cache for all fonts.\n */\n TextMetrics.clearMetrics = function (font) {\n if (font === void 0) { font = ''; }\n if (font) {\n delete TextMetrics._fonts[font];\n }\n else {\n TextMetrics._fonts = {};\n }\n };\n return TextMetrics;\n}());\n/**\n * Internal return object for {@link PIXI.TextMetrics.measureFont `TextMetrics.measureFont`}.\n *\n * @typedef {object} FontMetrics\n * @property {number} ascent - The ascent distance\n * @property {number} descent - The descent distance\n * @property {number} fontSize - Font size from ascent to descent\n * @memberof PIXI.TextMetrics\n * @private\n */\nvar canvas = (function () {\n try {\n // OffscreenCanvas2D measureText can be up to 40% faster.\n var c = new OffscreenCanvas(0, 0);\n var context = c.getContext('2d');\n if (context && context.measureText) {\n return c;\n }\n return document.createElement('canvas');\n }\n catch (ex) {\n return document.createElement('canvas');\n }\n})();\ncanvas.width = canvas.height = 10;\n/**\n * Cached canvas element for measuring text\n *\n * @memberof PIXI.TextMetrics\n * @type {HTMLCanvasElement}\n * @private\n */\nTextMetrics._canvas = canvas;\n/**\n * Cache for context to use.\n *\n * @memberof PIXI.TextMetrics\n * @type {CanvasRenderingContext2D}\n * @private\n */\nTextMetrics._context = canvas.getContext('2d');\n/**\n * Cache of {@see PIXI.TextMetrics.FontMetrics} objects.\n *\n * @memberof PIXI.TextMetrics\n * @type {Object}\n * @private\n */\nTextMetrics._fonts = {};\n/**\n * String used for calculate font metrics.\n * These characters are all tall to help calculate the height required for text.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name METRICS_STRING\n * @type {string}\n * @default |ÉqÅ\n */\nTextMetrics.METRICS_STRING = '|ÉqÅ';\n/**\n * Baseline symbol for calculate font metrics.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name BASELINE_SYMBOL\n * @type {string}\n * @default M\n */\nTextMetrics.BASELINE_SYMBOL = 'M';\n/**\n * Baseline multiplier for calculate font metrics.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name BASELINE_MULTIPLIER\n * @type {number}\n * @default 1.4\n */\nTextMetrics.BASELINE_MULTIPLIER = 1.4;\n/**\n * Height multiplier for setting height of canvas to calculate font metrics.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name HEIGHT_MULTIPLIER\n * @type {number}\n * @default 2.00\n */\nTextMetrics.HEIGHT_MULTIPLIER = 2.0;\n/**\n * Cache of new line chars.\n *\n * @memberof PIXI.TextMetrics\n * @type {number[]}\n * @private\n */\nTextMetrics._newlines = [\n 0x000A,\n 0x000D ];\n/**\n * Cache of breaking spaces.\n *\n * @memberof PIXI.TextMetrics\n * @type {number[]}\n * @private\n */\nTextMetrics._breakingSpaces = [\n 0x0009,\n 0x0020,\n 0x2000,\n 0x2001,\n 0x2002,\n 0x2003,\n 0x2004,\n 0x2005,\n 0x2006,\n 0x2008,\n 0x2009,\n 0x200A,\n 0x205F,\n 0x3000 ];\n/**\n * A number, or a string containing a number.\n *\n * @memberof PIXI\n * @typedef {object} IFontMetrics\n * @property {number} ascent - Font ascent\n * @property {number} descent - Font descent\n * @property {number} fontSize - Font size\n */\n\nvar defaultDestroyOptions = {\n texture: true,\n children: false,\n baseTexture: true,\n};\n/**\n * A Text Object will create a line or multiple lines of text.\n *\n * The text is created using the [Canvas API](https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API).\n *\n * The primary advantage of this class over BitmapText is that you have great control over the style of the text,\n * which you can change at runtime.\n *\n * The primary disadvantages is that each piece of text has it's own texture, which can use more memory.\n * When text changes, this texture has to be re-generated and re-uploaded to the GPU, taking up time.\n *\n * To split a line you can use '\\n' in your text string, or, on the `style` object,\n * change its `wordWrap` property to true and and give the `wordWrapWidth` property a value.\n *\n * A Text can be created directly from a string and a style object,\n * which can be generated [here](https://pixijs.io/pixi-text-style).\n *\n * ```js\n * let text = new PIXI.Text('This is a PixiJS text',{fontFamily : 'Arial', fontSize: 24, fill : 0xff1010, align : 'center'});\n * ```\n *\n * @memberof PIXI\n */\nvar Text = /** @class */ (function (_super) {\n __extends(Text, _super);\n /**\n * @param text - The string that you would like the text to display\n * @param {object|PIXI.TextStyle} [style] - The style parameters\n * @param canvas - The canvas element for drawing text\n */\n function Text(text, style, canvas) {\n var _this = this;\n var ownCanvas = false;\n if (!canvas) {\n canvas = document.createElement('canvas');\n ownCanvas = true;\n }\n canvas.width = 3;\n canvas.height = 3;\n var texture = Texture.from(canvas);\n texture.orig = new Rectangle();\n texture.trim = new Rectangle();\n _this = _super.call(this, texture) || this;\n _this._ownCanvas = ownCanvas;\n _this.canvas = canvas;\n _this.context = _this.canvas.getContext('2d');\n _this._resolution = settings.RESOLUTION;\n _this._autoResolution = true;\n _this._text = null;\n _this._style = null;\n _this._styleListener = null;\n _this._font = '';\n _this.text = text;\n _this.style = style;\n _this.localStyleID = -1;\n return _this;\n }\n /**\n * Renders text to its canvas, and updates its texture.\n *\n * By default this is used internally to ensure the texture is correct before rendering,\n * but it can be used called externally, for example from this class to 'pre-generate' the texture from a piece of text,\n * and then shared across multiple Sprites.\n *\n * @param respectDirty - Whether to abort updating the text if the Text isn't dirty and the function is called.\n */\n Text.prototype.updateText = function (respectDirty) {\n var style = this._style;\n // check if style has changed..\n if (this.localStyleID !== style.styleID) {\n this.dirty = true;\n this.localStyleID = style.styleID;\n }\n if (!this.dirty && respectDirty) {\n return;\n }\n this._font = this._style.toFontString();\n var context = this.context;\n var measured = TextMetrics.measureText(this._text || ' ', this._style, this._style.wordWrap, this.canvas);\n var width = measured.width;\n var height = measured.height;\n var lines = measured.lines;\n var lineHeight = measured.lineHeight;\n var lineWidths = measured.lineWidths;\n var maxLineWidth = measured.maxLineWidth;\n var fontProperties = measured.fontProperties;\n this.canvas.width = Math.ceil(Math.ceil((Math.max(1, width) + (style.padding * 2))) * this._resolution);\n this.canvas.height = Math.ceil(Math.ceil((Math.max(1, height) + (style.padding * 2))) * this._resolution);\n context.scale(this._resolution, this._resolution);\n context.clearRect(0, 0, this.canvas.width, this.canvas.height);\n context.font = this._font;\n context.lineWidth = style.strokeThickness;\n context.textBaseline = style.textBaseline;\n context.lineJoin = style.lineJoin;\n context.miterLimit = style.miterLimit;\n var linePositionX;\n var linePositionY;\n // require 2 passes if a shadow; the first to draw the drop shadow, the second to draw the text\n var passesCount = style.dropShadow ? 2 : 1;\n // For v4, we drew text at the colours of the drop shadow underneath the normal text. This gave the correct zIndex,\n // but features such as alpha and shadowblur did not look right at all, since we were using actual text as a shadow.\n //\n // For v5.0.0, we moved over to just use the canvas API for drop shadows, which made them look much nicer and more\n // visually please, but now because the stroke is drawn and then the fill, drop shadows would appear on both the fill\n // and the stroke; and fill drop shadows would appear over the top of the stroke.\n //\n // For v5.1.1, the new route is to revert to v4 style of drawing text first to get the drop shadows underneath normal\n // text, but instead drawing text in the correct location, we'll draw it off screen (-paddingY), and then adjust the\n // drop shadow so only that appears on screen (+paddingY). Now we'll have the correct draw order of the shadow\n // beneath the text, whilst also having the proper text shadow styling.\n for (var i = 0; i < passesCount; ++i) {\n var isShadowPass = style.dropShadow && i === 0;\n // we only want the drop shadow, so put text way off-screen\n var dsOffsetText = isShadowPass ? Math.ceil(Math.max(1, height) + (style.padding * 2)) : 0;\n var dsOffsetShadow = dsOffsetText * this._resolution;\n if (isShadowPass) {\n // On Safari, text with gradient and drop shadows together do not position correctly\n // if the scale of the canvas is not 1: https://bugs.webkit.org/show_bug.cgi?id=197689\n // Therefore we'll set the styles to be a plain black whilst generating this drop shadow\n context.fillStyle = 'black';\n context.strokeStyle = 'black';\n var dropShadowColor = style.dropShadowColor;\n var rgb = hex2rgb(typeof dropShadowColor === 'number' ? dropShadowColor : string2hex(dropShadowColor));\n var dropShadowBlur = style.dropShadowBlur * this._resolution;\n var dropShadowDistance = style.dropShadowDistance * this._resolution;\n context.shadowColor = \"rgba(\" + rgb[0] * 255 + \",\" + rgb[1] * 255 + \",\" + rgb[2] * 255 + \",\" + style.dropShadowAlpha + \")\";\n context.shadowBlur = dropShadowBlur;\n context.shadowOffsetX = Math.cos(style.dropShadowAngle) * dropShadowDistance;\n context.shadowOffsetY = (Math.sin(style.dropShadowAngle) * dropShadowDistance) + dsOffsetShadow;\n }\n else {\n // set canvas text styles\n context.fillStyle = this._generateFillStyle(style, lines, measured);\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n context.strokeStyle = style.stroke;\n context.shadowColor = 'black';\n context.shadowBlur = 0;\n context.shadowOffsetX = 0;\n context.shadowOffsetY = 0;\n }\n var linePositionYShift = (lineHeight - fontProperties.fontSize) / 2;\n if (!Text.nextLineHeightBehavior || lineHeight - fontProperties.fontSize < 0) {\n linePositionYShift = 0;\n }\n // draw lines line by line\n for (var i_1 = 0; i_1 < lines.length; i_1++) {\n linePositionX = style.strokeThickness / 2;\n linePositionY = ((style.strokeThickness / 2) + (i_1 * lineHeight)) + fontProperties.ascent\n + linePositionYShift;\n if (style.align === 'right') {\n linePositionX += maxLineWidth - lineWidths[i_1];\n }\n else if (style.align === 'center') {\n linePositionX += (maxLineWidth - lineWidths[i_1]) / 2;\n }\n if (style.stroke && style.strokeThickness) {\n this.drawLetterSpacing(lines[i_1], linePositionX + style.padding, linePositionY + style.padding - dsOffsetText, true);\n }\n if (style.fill) {\n this.drawLetterSpacing(lines[i_1], linePositionX + style.padding, linePositionY + style.padding - dsOffsetText);\n }\n }\n }\n this.updateTexture();\n };\n /**\n * Render the text with letter-spacing.\n *\n * @param text - The text to draw\n * @param x - Horizontal position to draw the text\n * @param y - Vertical position to draw the text\n * @param isStroke - Is this drawing for the outside stroke of the\n * text? If not, it's for the inside fill\n */\n Text.prototype.drawLetterSpacing = function (text, x, y, isStroke) {\n if (isStroke === void 0) { isStroke = false; }\n var style = this._style;\n // letterSpacing of 0 means normal\n var letterSpacing = style.letterSpacing;\n // Checking that we can use moddern canvas2D api\n // https://developer.chrome.com/origintrials/#/view_trial/3585991203293757441\n // note: this is unstable API, Chrome less 94 use a `textLetterSpacing`, newest use a letterSpacing\n // eslint-disable-next-line max-len\n var supportLetterSpacing = Text.experimentalLetterSpacing\n && ('letterSpacing' in CanvasRenderingContext2D.prototype\n || 'textLetterSpacing' in CanvasRenderingContext2D.prototype);\n if (letterSpacing === 0 || supportLetterSpacing) {\n if (supportLetterSpacing) {\n this.context.letterSpacing = letterSpacing;\n this.context.textLetterSpacing = letterSpacing;\n }\n if (isStroke) {\n this.context.strokeText(text, x, y);\n }\n else {\n this.context.fillText(text, x, y);\n }\n return;\n }\n var currentPosition = x;\n // Using Array.from correctly splits characters whilst keeping emoji together.\n // This is not supported on IE as it requires ES6, so regular text splitting occurs.\n // This also doesn't account for emoji that are multiple emoji put together to make something else.\n // Handling all of this would require a big library itself.\n // https://medium.com/@giltayar/iterating-over-emoji-characters-the-es6-way-f06e4589516\n // https://github.com/orling/grapheme-splitter\n var stringArray = Array.from ? Array.from(text) : text.split('');\n var previousWidth = this.context.measureText(text).width;\n var currentWidth = 0;\n for (var i = 0; i < stringArray.length; ++i) {\n var currentChar = stringArray[i];\n if (isStroke) {\n this.context.strokeText(currentChar, currentPosition, y);\n }\n else {\n this.context.fillText(currentChar, currentPosition, y);\n }\n var textStr = '';\n for (var j = i + 1; j < stringArray.length; ++j) {\n textStr += stringArray[j];\n }\n currentWidth = this.context.measureText(textStr).width;\n currentPosition += previousWidth - currentWidth + letterSpacing;\n previousWidth = currentWidth;\n }\n };\n /** Updates texture size based on canvas size. */\n Text.prototype.updateTexture = function () {\n var canvas = this.canvas;\n if (this._style.trim) {\n var trimmed = trimCanvas(canvas);\n if (trimmed.data) {\n canvas.width = trimmed.width;\n canvas.height = trimmed.height;\n this.context.putImageData(trimmed.data, 0, 0);\n }\n }\n var texture = this._texture;\n var style = this._style;\n var padding = style.trim ? 0 : style.padding;\n var baseTexture = texture.baseTexture;\n texture.trim.width = texture._frame.width = canvas.width / this._resolution;\n texture.trim.height = texture._frame.height = canvas.height / this._resolution;\n texture.trim.x = -padding;\n texture.trim.y = -padding;\n texture.orig.width = texture._frame.width - (padding * 2);\n texture.orig.height = texture._frame.height - (padding * 2);\n // call sprite onTextureUpdate to update scale if _width or _height were set\n this._onTextureUpdate();\n baseTexture.setRealSize(canvas.width, canvas.height, this._resolution);\n texture.updateUvs();\n // Recursively updates transform of all objects from the root to this one\n this._recursivePostUpdateTransform();\n this.dirty = false;\n };\n /**\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The renderer\n */\n Text.prototype._render = function (renderer) {\n if (this._autoResolution && this._resolution !== renderer.resolution) {\n this._resolution = renderer.resolution;\n this.dirty = true;\n }\n this.updateText(true);\n _super.prototype._render.call(this, renderer);\n };\n /**\n * Gets the local bounds of the text object.\n *\n * @param rect - The output rectangle.\n * @return The bounds.\n */\n Text.prototype.getLocalBounds = function (rect) {\n this.updateText(true);\n return _super.prototype.getLocalBounds.call(this, rect);\n };\n /** Calculates the bounds of the Text as a rectangle. The bounds calculation takes the worldTransform into account. */\n Text.prototype._calculateBounds = function () {\n this.updateText(true);\n this.calculateVertices();\n // if we have already done this on THIS frame.\n this._bounds.addQuad(this.vertexData);\n };\n /**\n * Generates the fill style. Can automatically generate a gradient based on the fill style being an array\n *\n * @param style - The style.\n * @param lines - The lines of text.\n * @return The fill style\n */\n Text.prototype._generateFillStyle = function (style, lines, metrics) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n var fillStyle = style.fill;\n if (!Array.isArray(fillStyle)) {\n return fillStyle;\n }\n else if (fillStyle.length === 1) {\n return fillStyle[0];\n }\n // the gradient will be evenly spaced out according to how large the array is.\n // ['#FF0000', '#00FF00', '#0000FF'] would created stops at 0.25, 0.5 and 0.75\n var gradient;\n // a dropshadow will enlarge the canvas and result in the gradient being\n // generated with the incorrect dimensions\n var dropShadowCorrection = (style.dropShadow) ? style.dropShadowDistance : 0;\n // should also take padding into account, padding can offset the gradient\n var padding = style.padding || 0;\n var width = (this.canvas.width / this._resolution) - dropShadowCorrection - (padding * 2);\n var height = (this.canvas.height / this._resolution) - dropShadowCorrection - (padding * 2);\n // make a copy of the style settings, so we can manipulate them later\n var fill = fillStyle.slice();\n var fillGradientStops = style.fillGradientStops.slice();\n // wanting to evenly distribute the fills. So an array of 4 colours should give fills of 0.25, 0.5 and 0.75\n if (!fillGradientStops.length) {\n var lengthPlus1 = fill.length + 1;\n for (var i = 1; i < lengthPlus1; ++i) {\n fillGradientStops.push(i / lengthPlus1);\n }\n }\n // stop the bleeding of the last gradient on the line above to the top gradient of the this line\n // by hard defining the first gradient colour at point 0, and last gradient colour at point 1\n fill.unshift(fillStyle[0]);\n fillGradientStops.unshift(0);\n fill.push(fillStyle[fillStyle.length - 1]);\n fillGradientStops.push(1);\n if (style.fillGradientType === TEXT_GRADIENT.LINEAR_VERTICAL) {\n // start the gradient at the top center of the canvas, and end at the bottom middle of the canvas\n gradient = this.context.createLinearGradient(width / 2, padding, width / 2, height + padding);\n // we need to repeat the gradient so that each individual line of text has the same vertical gradient effect\n // ['#FF0000', '#00FF00', '#0000FF'] over 2 lines would create stops at 0.125, 0.25, 0.375, 0.625, 0.75, 0.875\n // Actual height of the text itself, not counting spacing for lineHeight/leading/dropShadow etc\n var textHeight = metrics.fontProperties.fontSize + style.strokeThickness;\n for (var i = 0; i < lines.length; i++) {\n var lastLineBottom = (metrics.lineHeight * (i - 1)) + textHeight;\n var thisLineTop = metrics.lineHeight * i;\n var thisLineGradientStart = thisLineTop;\n // Handle case where last & this line overlap\n if (i > 0 && lastLineBottom > thisLineTop) {\n thisLineGradientStart = (thisLineTop + lastLineBottom) / 2;\n }\n var thisLineBottom = thisLineTop + textHeight;\n var nextLineTop = metrics.lineHeight * (i + 1);\n var thisLineGradientEnd = thisLineBottom;\n // Handle case where this & next line overlap\n if (i + 1 < lines.length && nextLineTop < thisLineBottom) {\n thisLineGradientEnd = (thisLineBottom + nextLineTop) / 2;\n }\n // textHeight, but as a 0-1 size in global gradient stop space\n var gradStopLineHeight = (thisLineGradientEnd - thisLineGradientStart) / height;\n for (var j = 0; j < fill.length; j++) {\n // 0-1 stop point for the current line, multiplied to global space afterwards\n var lineStop = 0;\n if (typeof fillGradientStops[j] === 'number') {\n lineStop = fillGradientStops[j];\n }\n else {\n lineStop = j / fill.length;\n }\n var globalStop = Math.min(1, Math.max(0, (thisLineGradientStart / height) + (lineStop * gradStopLineHeight)));\n // There's potential for floating point precision issues at the seams between gradient repeats.\n globalStop = Number(globalStop.toFixed(5));\n gradient.addColorStop(globalStop, fill[j]);\n }\n }\n }\n else {\n // start the gradient at the center left of the canvas, and end at the center right of the canvas\n gradient = this.context.createLinearGradient(padding, height / 2, width + padding, height / 2);\n // can just evenly space out the gradients in this case, as multiple lines makes no difference\n // to an even left to right gradient\n var totalIterations = fill.length + 1;\n var currentIteration = 1;\n for (var i = 0; i < fill.length; i++) {\n var stop = void 0;\n if (typeof fillGradientStops[i] === 'number') {\n stop = fillGradientStops[i];\n }\n else {\n stop = currentIteration / totalIterations;\n }\n gradient.addColorStop(stop, fill[i]);\n currentIteration++;\n }\n }\n return gradient;\n };\n /**\n * Destroys this text object.\n *\n * Note* Unlike a Sprite, a Text object will automatically destroy its baseTexture and texture as\n * the majority of the time the texture will not be shared with any other Sprites.\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their\n * destroy method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=true] - Should it destroy the current texture of the sprite as well\n * @param {boolean} [options.baseTexture=true] - Should it destroy the base texture of the sprite as well\n */\n Text.prototype.destroy = function (options) {\n if (typeof options === 'boolean') {\n options = { children: options };\n }\n options = Object.assign({}, defaultDestroyOptions, options);\n _super.prototype.destroy.call(this, options);\n // set canvas width and height to 0 to workaround memory leak in Safari < 13\n // https://stackoverflow.com/questions/52532614/total-canvas-memory-use-exceeds-the-maximum-limit-safari-12\n if (this._ownCanvas) {\n this.canvas.height = this.canvas.width = 0;\n }\n // make sure to reset the context and canvas.. dont want this hanging around in memory!\n this.context = null;\n this.canvas = null;\n this._style = null;\n };\n Object.defineProperty(Text.prototype, \"width\", {\n /** The width of the Text, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n this.updateText(true);\n return Math.abs(this.scale.x) * this._texture.orig.width;\n },\n set: function (value) {\n this.updateText(true);\n var s = sign(this.scale.x) || 1;\n this.scale.x = s * value / this._texture.orig.width;\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"height\", {\n /** The height of the Text, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n this.updateText(true);\n return Math.abs(this.scale.y) * this._texture.orig.height;\n },\n set: function (value) {\n this.updateText(true);\n var s = sign(this.scale.y) || 1;\n this.scale.y = s * value / this._texture.orig.height;\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"style\", {\n /**\n * Set the style of the text.\n *\n * Set up an event listener to listen for changes on the style object and mark the text as dirty.\n */\n get: function () {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the ITextStyle\n // since the setter creates the TextStyle. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n return this._style;\n },\n set: function (style) {\n style = style || {};\n if (style instanceof TextStyle) {\n this._style = style;\n }\n else {\n this._style = new TextStyle(style);\n }\n this.localStyleID = -1;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"text\", {\n /** Set the copy for the text object. To split a line you can use '\\n'. */\n get: function () {\n return this._text;\n },\n set: function (text) {\n text = String(text === null || text === undefined ? '' : text);\n if (this._text === text) {\n return;\n }\n this._text = text;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"resolution\", {\n /**\n * The resolution / device pixel ratio of the canvas.\n *\n * This is set to automatically match the renderer resolution by default, but can be overridden by setting manually.\n *\n * @default 1\n */\n get: function () {\n return this._resolution;\n },\n set: function (value) {\n this._autoResolution = false;\n if (this._resolution === value) {\n return;\n }\n this._resolution = value;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * New behavior for `lineHeight` that's meant to mimic HTML text. A value of `true` will\n * make sure the first baseline is offset by the `lineHeight` value if it is greater than `fontSize`.\n * A value of `false` will use the legacy behavior and not change the baseline of the first line.\n * In the next major release, we'll enable this by default.\n */\n Text.nextLineHeightBehavior = false;\n /**\n * New rendering behavior for letter-spacing which uses Chrome's new native API. This will\n * lead to more accurate letter-spacing results because it does not try to manually draw\n * each character. However, this Chrome API is experimental and may not serve all cases yet.\n */\n Text.experimentalLetterSpacing = false;\n return Text;\n}(Sprite));\n\nexport { TEXT_GRADIENT, Text, TextMetrics, TextStyle };\n//# sourceMappingURL=text.js.map\n","/*!\n * @pixi/prepare - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/prepare is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nimport { Texture, BaseTexture } from '@pixi/core';\nimport { Graphics } from '@pixi/graphics';\nimport { Ticker, UPDATE_PRIORITY } from '@pixi/ticker';\nimport { Container } from '@pixi/display';\nimport { Text, TextStyle, TextMetrics } from '@pixi/text';\n\n/**\n * Default number of uploads per frame using prepare plugin.\n *\n * @static\n * @memberof PIXI.settings\n * @name UPLOADS_PER_FRAME\n * @type {number}\n * @default 4\n */\nsettings.UPLOADS_PER_FRAME = 4;\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * CountLimiter limits the number of items handled by a {@link PIXI.BasePrepare} to a specified\n * number of items per frame.\n *\n * @memberof PIXI\n */\nvar CountLimiter = /** @class */ (function () {\n /**\n * @param maxItemsPerFrame - The maximum number of items that can be prepared each frame.\n */\n function CountLimiter(maxItemsPerFrame) {\n this.maxItemsPerFrame = maxItemsPerFrame;\n this.itemsLeft = 0;\n }\n /** Resets any counting properties to start fresh on a new frame. */\n CountLimiter.prototype.beginFrame = function () {\n this.itemsLeft = this.maxItemsPerFrame;\n };\n /**\n * Checks to see if another item can be uploaded. This should only be called once per item.\n *\n * @return If the item is allowed to be uploaded.\n */\n CountLimiter.prototype.allowedToUpload = function () {\n return this.itemsLeft-- > 0;\n };\n return CountLimiter;\n}());\n\n/**\n * Built-in hook to find multiple textures from objects like AnimatedSprites.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.Texture object was found.\n */\nfunction findMultipleBaseTextures(item, queue) {\n var result = false;\n // Objects with multiple textures\n if (item && item._textures && item._textures.length) {\n for (var i = 0; i < item._textures.length; i++) {\n if (item._textures[i] instanceof Texture) {\n var baseTexture = item._textures[i].baseTexture;\n if (queue.indexOf(baseTexture) === -1) {\n queue.push(baseTexture);\n result = true;\n }\n }\n }\n }\n return result;\n}\n/**\n * Built-in hook to find BaseTextures from Texture.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.Texture object was found.\n */\nfunction findBaseTexture(item, queue) {\n if (item.baseTexture instanceof BaseTexture) {\n var texture = item.baseTexture;\n if (queue.indexOf(texture) === -1) {\n queue.push(texture);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to find textures from objects.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.Texture object was found.\n */\nfunction findTexture(item, queue) {\n if (item._texture && item._texture instanceof Texture) {\n var texture = item._texture.baseTexture;\n if (queue.indexOf(texture) === -1) {\n queue.push(texture);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to draw PIXI.Text to its texture.\n *\n * @private\n * @param helper - Not used by this upload handler\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction drawText(_helper, item) {\n if (item instanceof Text) {\n // updating text will return early if it is not dirty\n item.updateText(true);\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to calculate a text style for a PIXI.Text object.\n *\n * @private\n * @param helper - Not used by this upload handler\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction calculateTextStyle(_helper, item) {\n if (item instanceof TextStyle) {\n var font = item.toFontString();\n TextMetrics.measureFont(font);\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to find Text objects.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return if a PIXI.Text object was found.\n */\nfunction findText(item, queue) {\n if (item instanceof Text) {\n // push the text style to prepare it - this can be really expensive\n if (queue.indexOf(item.style) === -1) {\n queue.push(item.style);\n }\n // also push the text object so that we can render it (to canvas/texture) if needed\n if (queue.indexOf(item) === -1) {\n queue.push(item);\n }\n // also push the Text's texture for upload to GPU\n var texture = item._texture.baseTexture;\n if (queue.indexOf(texture) === -1) {\n queue.push(texture);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to find TextStyle objects.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.TextStyle object was found.\n */\nfunction findTextStyle(item, queue) {\n if (item instanceof TextStyle) {\n if (queue.indexOf(item) === -1) {\n queue.push(item);\n }\n return true;\n }\n return false;\n}\n/**\n * The prepare manager provides functionality to upload content to the GPU.\n *\n * BasePrepare handles basic queuing functionality and is extended by\n * {@link PIXI.Prepare} and {@link PIXI.CanvasPrepare}\n * to provide preparation capabilities specific to their respective renderers.\n *\n * @example\n * // Create a sprite\n * const sprite = PIXI.Sprite.from('something.png');\n *\n * // Load object into GPU\n * app.renderer.plugins.prepare.upload(sprite, () => {\n *\n * //Texture(s) has been uploaded to GPU\n * app.stage.addChild(sprite);\n *\n * })\n *\n * @abstract\n * @memberof PIXI\n */\nvar BasePrepare = /** @class */ (function () {\n /**\n * @param {PIXI.AbstractRenderer} renderer - A reference to the current renderer\n */\n function BasePrepare(renderer) {\n var _this = this;\n this.limiter = new CountLimiter(settings.UPLOADS_PER_FRAME);\n this.renderer = renderer;\n this.uploadHookHelper = null;\n this.queue = [];\n this.addHooks = [];\n this.uploadHooks = [];\n this.completes = [];\n this.ticking = false;\n this.delayedTick = function () {\n // unlikely, but in case we were destroyed between tick() and delayedTick()\n if (!_this.queue) {\n return;\n }\n _this.prepareItems();\n };\n // hooks to find the correct texture\n this.registerFindHook(findText);\n this.registerFindHook(findTextStyle);\n this.registerFindHook(findMultipleBaseTextures);\n this.registerFindHook(findBaseTexture);\n this.registerFindHook(findTexture);\n // upload hooks\n this.registerUploadHook(drawText);\n this.registerUploadHook(calculateTextStyle);\n }\n /**\n * Upload all the textures and graphics to the GPU.\n *\n * @param {Function|PIXI.DisplayObject|PIXI.Container|PIXI.BaseTexture|PIXI.Texture|PIXI.Graphics|PIXI.Text} item -\n * Either the container or display object to search for items to upload, the items to upload themselves,\n * or the callback function, if items have been added using `prepare.add`.\n * @param {Function} [done] - Optional callback when all queued uploads have completed\n */\n BasePrepare.prototype.upload = function (item, done) {\n if (typeof item === 'function') {\n done = item;\n item = null;\n }\n // If a display object, search for items\n // that we could upload\n if (item) {\n this.add(item);\n }\n // Get the items for upload from the display\n if (this.queue.length) {\n if (done) {\n this.completes.push(done);\n }\n if (!this.ticking) {\n this.ticking = true;\n Ticker.system.addOnce(this.tick, this, UPDATE_PRIORITY.UTILITY);\n }\n }\n else if (done) {\n done();\n }\n };\n /**\n * Handle tick update\n *\n * @private\n */\n BasePrepare.prototype.tick = function () {\n setTimeout(this.delayedTick, 0);\n };\n /**\n * Actually prepare items. This is handled outside of the tick because it will take a while\n * and we do NOT want to block the current animation frame from rendering.\n *\n * @private\n */\n BasePrepare.prototype.prepareItems = function () {\n this.limiter.beginFrame();\n // Upload the graphics\n while (this.queue.length && this.limiter.allowedToUpload()) {\n var item = this.queue[0];\n var uploaded = false;\n if (item && !item._destroyed) {\n for (var i = 0, len = this.uploadHooks.length; i < len; i++) {\n if (this.uploadHooks[i](this.uploadHookHelper, item)) {\n this.queue.shift();\n uploaded = true;\n break;\n }\n }\n }\n if (!uploaded) {\n this.queue.shift();\n }\n }\n // We're finished\n if (!this.queue.length) {\n this.ticking = false;\n var completes = this.completes.slice(0);\n this.completes.length = 0;\n for (var i = 0, len = completes.length; i < len; i++) {\n completes[i]();\n }\n }\n else {\n // if we are not finished, on the next rAF do this again\n Ticker.system.addOnce(this.tick, this, UPDATE_PRIORITY.UTILITY);\n }\n };\n /**\n * Adds hooks for finding items.\n *\n * @param {Function} addHook - Function call that takes two parameters: `item:*, queue:Array`\n * function must return `true` if it was able to add item to the queue.\n * @return Instance of plugin for chaining.\n */\n BasePrepare.prototype.registerFindHook = function (addHook) {\n if (addHook) {\n this.addHooks.push(addHook);\n }\n return this;\n };\n /**\n * Adds hooks for uploading items.\n *\n * @param {Function} uploadHook - Function call that takes two parameters: `prepare:CanvasPrepare, item:*` and\n * function must return `true` if it was able to handle upload of item.\n * @return Instance of plugin for chaining.\n */\n BasePrepare.prototype.registerUploadHook = function (uploadHook) {\n if (uploadHook) {\n this.uploadHooks.push(uploadHook);\n }\n return this;\n };\n /**\n * Manually add an item to the uploading queue.\n *\n * @param {PIXI.DisplayObject|PIXI.Container|PIXI.BaseTexture|PIXI.Texture|PIXI.Graphics|PIXI.Text|*} item - Object to\n * add to the queue\n * @return Instance of plugin for chaining.\n */\n BasePrepare.prototype.add = function (item) {\n // Add additional hooks for finding elements on special\n // types of objects that\n for (var i = 0, len = this.addHooks.length; i < len; i++) {\n if (this.addHooks[i](item, this.queue)) {\n break;\n }\n }\n // Get children recursively\n if (item instanceof Container) {\n for (var i = item.children.length - 1; i >= 0; i--) {\n this.add(item.children[i]);\n }\n }\n return this;\n };\n /** Destroys the plugin, don't use after this. */\n BasePrepare.prototype.destroy = function () {\n if (this.ticking) {\n Ticker.system.remove(this.tick, this);\n }\n this.ticking = false;\n this.addHooks = null;\n this.uploadHooks = null;\n this.renderer = null;\n this.completes = null;\n this.queue = null;\n this.limiter = null;\n this.uploadHookHelper = null;\n };\n return BasePrepare;\n}());\n\n/**\n * Built-in hook to upload PIXI.Texture objects to the GPU.\n *\n * @private\n * @param renderer - instance of the webgl renderer\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction uploadBaseTextures(renderer, item) {\n if (item instanceof BaseTexture) {\n // if the texture already has a GL texture, then the texture has been prepared or rendered\n // before now. If the texture changed, then the changer should be calling texture.update() which\n // reuploads the texture without need for preparing it again\n if (!item._glTextures[renderer.CONTEXT_UID]) {\n renderer.texture.bind(item);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to upload PIXI.Graphics to the GPU.\n *\n * @private\n * @param renderer - instance of the webgl renderer\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction uploadGraphics(renderer, item) {\n if (!(item instanceof Graphics)) {\n return false;\n }\n var geometry = item.geometry;\n // update dirty graphics to get batches\n item.finishPoly();\n geometry.updateBatches();\n var batches = geometry.batches;\n // upload all textures found in styles\n for (var i = 0; i < batches.length; i++) {\n var texture = batches[i].style.texture;\n if (texture) {\n uploadBaseTextures(renderer, texture.baseTexture);\n }\n }\n // if its not batchable - update vao for particular shader\n if (!geometry.batchable) {\n renderer.geometry.bind(geometry, item._resolveDirectShader(renderer));\n }\n return true;\n}\n/**\n * Built-in hook to find graphics.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return if a PIXI.Graphics object was found.\n */\nfunction findGraphics(item, queue) {\n if (item instanceof Graphics) {\n queue.push(item);\n return true;\n }\n return false;\n}\n/**\n * The prepare plugin provides renderer-specific plugins for pre-rendering DisplayObjects. These plugins are useful for\n * asynchronously preparing and uploading to the GPU assets, textures, graphics waiting to be displayed.\n *\n * Do not instantiate this plugin directly. It is available from the `renderer.plugins` property.\n * See {@link PIXI.CanvasRenderer#plugins} or {@link PIXI.Renderer#plugins}.\n * @example\n * // Create a new application\n * const app = new PIXI.Application();\n * document.body.appendChild(app.view);\n *\n * // Don't start rendering right away\n * app.stop();\n *\n * // create a display object\n * const rect = new PIXI.Graphics()\n * .beginFill(0x00ff00)\n * .drawRect(40, 40, 200, 200);\n *\n * // Add to the stage\n * app.stage.addChild(rect);\n *\n * // Don't start rendering until the graphic is uploaded to the GPU\n * app.renderer.plugins.prepare.upload(app.stage, () => {\n * app.start();\n * });\n *\n *\n * @memberof PIXI\n */\nvar Prepare = /** @class */ (function (_super) {\n __extends(Prepare, _super);\n /**\n * @param {PIXI.Renderer} renderer - A reference to the current renderer\n */\n function Prepare(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.uploadHookHelper = _this.renderer;\n // Add textures and graphics to upload\n _this.registerFindHook(findGraphics);\n _this.registerUploadHook(uploadBaseTextures);\n _this.registerUploadHook(uploadGraphics);\n return _this;\n }\n return Prepare;\n}(BasePrepare));\n\n/**\n * TimeLimiter limits the number of items handled by a {@link PIXI.BasePrepare} to a specified\n * number of milliseconds per frame.\n *\n * @memberof PIXI\n */\nvar TimeLimiter = /** @class */ (function () {\n /** @param maxMilliseconds - The maximum milliseconds that can be spent preparing items each frame. */\n function TimeLimiter(maxMilliseconds) {\n this.maxMilliseconds = maxMilliseconds;\n this.frameStart = 0;\n }\n /** Resets any counting properties to start fresh on a new frame. */\n TimeLimiter.prototype.beginFrame = function () {\n this.frameStart = Date.now();\n };\n /**\n * Checks to see if another item can be uploaded. This should only be called once per item.\n *\n * @return - If the item is allowed to be uploaded.\n */\n TimeLimiter.prototype.allowedToUpload = function () {\n return Date.now() - this.frameStart < this.maxMilliseconds;\n };\n return TimeLimiter;\n}());\n\nexport { BasePrepare, CountLimiter, Prepare, TimeLimiter };\n//# sourceMappingURL=prepare.js.map\n","/*!\n * @pixi/spritesheet - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/spritesheet is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Rectangle } from '@pixi/math';\nimport { Texture, BaseTexture } from '@pixi/core';\nimport { getResolutionOfUrl, url } from '@pixi/utils';\nimport { LoaderResource } from '@pixi/loaders';\n\n/**\n * Utility class for maintaining reference to a collection\n * of Textures on a single Spritesheet.\n *\n * To access a sprite sheet from your code pass its JSON data file to Pixi's loader:\n *\n * ```js\n * PIXI.Loader.shared.add(\"images/spritesheet.json\").load(setup);\n *\n * function setup() {\n * let sheet = PIXI.Loader.shared.resources[\"images/spritesheet.json\"].spritesheet;\n * ...\n * }\n * ```\n * With the `sheet.textures` you can create Sprite objects,`sheet.animations` can be used to create an AnimatedSprite.\n *\n * Sprite sheets can be packed using tools like {@link https://codeandweb.com/texturepacker|TexturePacker},\n * {@link https://renderhjs.net/shoebox/|Shoebox} or {@link https://github.com/krzysztof-o/spritesheet.js|Spritesheet.js}.\n * Default anchor points (see {@link PIXI.Texture#defaultAnchor}) and grouping of animation sprites are currently only\n * supported by TexturePacker.\n *\n * @memberof PIXI\n */\nvar Spritesheet = /** @class */ (function () {\n /**\n * @param baseTexture - Reference to the source BaseTexture object.\n * @param {Object} data - Spritesheet image data.\n * @param resolutionFilename - The filename to consider when determining\n * the resolution of the spritesheet. If not provided, the imageUrl will\n * be used on the BaseTexture.\n */\n function Spritesheet(texture, data, resolutionFilename) {\n if (resolutionFilename === void 0) { resolutionFilename = null; }\n this._texture = texture instanceof Texture ? texture : null;\n this.baseTexture = texture instanceof BaseTexture ? texture : this._texture.baseTexture;\n this.textures = {};\n this.animations = {};\n this.data = data;\n var resource = this.baseTexture.resource;\n this.resolution = this._updateResolution(resolutionFilename || (resource ? resource.url : null));\n this._frames = this.data.frames;\n this._frameKeys = Object.keys(this._frames);\n this._batchIndex = 0;\n this._callback = null;\n }\n /**\n * Generate the resolution from the filename or fallback\n * to the meta.scale field of the JSON data.\n *\n * @param resolutionFilename - The filename to use for resolving\n * the default resolution.\n * @return Resolution to use for spritesheet.\n */\n Spritesheet.prototype._updateResolution = function (resolutionFilename) {\n if (resolutionFilename === void 0) { resolutionFilename = null; }\n var scale = this.data.meta.scale;\n // Use a defaultValue of `null` to check if a url-based resolution is set\n var resolution = getResolutionOfUrl(resolutionFilename, null);\n // No resolution found via URL\n if (resolution === null) {\n // Use the scale value or default to 1\n resolution = scale !== undefined ? parseFloat(scale) : 1;\n }\n // For non-1 resolutions, update baseTexture\n if (resolution !== 1) {\n this.baseTexture.setResolution(resolution);\n }\n return resolution;\n };\n /**\n * Parser spritesheet from loaded data. This is done asynchronously\n * to prevent creating too many Texture within a single process.\n *\n * @param {Function} callback - Callback when complete returns\n * a map of the Textures for this spritesheet.\n */\n Spritesheet.prototype.parse = function (callback) {\n this._batchIndex = 0;\n this._callback = callback;\n if (this._frameKeys.length <= Spritesheet.BATCH_SIZE) {\n this._processFrames(0);\n this._processAnimations();\n this._parseComplete();\n }\n else {\n this._nextBatch();\n }\n };\n /**\n * Process a batch of frames\n *\n * @param initialFrameIndex - The index of frame to start.\n */\n Spritesheet.prototype._processFrames = function (initialFrameIndex) {\n var frameIndex = initialFrameIndex;\n var maxFrames = Spritesheet.BATCH_SIZE;\n while (frameIndex - initialFrameIndex < maxFrames && frameIndex < this._frameKeys.length) {\n var i = this._frameKeys[frameIndex];\n var data = this._frames[i];\n var rect = data.frame;\n if (rect) {\n var frame = null;\n var trim = null;\n var sourceSize = data.trimmed !== false && data.sourceSize\n ? data.sourceSize : data.frame;\n var orig = new Rectangle(0, 0, Math.floor(sourceSize.w) / this.resolution, Math.floor(sourceSize.h) / this.resolution);\n if (data.rotated) {\n frame = new Rectangle(Math.floor(rect.x) / this.resolution, Math.floor(rect.y) / this.resolution, Math.floor(rect.h) / this.resolution, Math.floor(rect.w) / this.resolution);\n }\n else {\n frame = new Rectangle(Math.floor(rect.x) / this.resolution, Math.floor(rect.y) / this.resolution, Math.floor(rect.w) / this.resolution, Math.floor(rect.h) / this.resolution);\n }\n // Check to see if the sprite is trimmed\n if (data.trimmed !== false && data.spriteSourceSize) {\n trim = new Rectangle(Math.floor(data.spriteSourceSize.x) / this.resolution, Math.floor(data.spriteSourceSize.y) / this.resolution, Math.floor(rect.w) / this.resolution, Math.floor(rect.h) / this.resolution);\n }\n this.textures[i] = new Texture(this.baseTexture, frame, orig, trim, data.rotated ? 2 : 0, data.anchor);\n // lets also add the frame to pixi's global cache for 'from' and 'fromLoader' functions\n Texture.addToCache(this.textures[i], i);\n }\n frameIndex++;\n }\n };\n /** Parse animations config. */\n Spritesheet.prototype._processAnimations = function () {\n var animations = this.data.animations || {};\n for (var animName in animations) {\n this.animations[animName] = [];\n for (var i = 0; i < animations[animName].length; i++) {\n var frameName = animations[animName][i];\n this.animations[animName].push(this.textures[frameName]);\n }\n }\n };\n /** The parse has completed. */\n Spritesheet.prototype._parseComplete = function () {\n var callback = this._callback;\n this._callback = null;\n this._batchIndex = 0;\n callback.call(this, this.textures);\n };\n /** Begin the next batch of textures. */\n Spritesheet.prototype._nextBatch = function () {\n var _this = this;\n this._processFrames(this._batchIndex * Spritesheet.BATCH_SIZE);\n this._batchIndex++;\n setTimeout(function () {\n if (_this._batchIndex * Spritesheet.BATCH_SIZE < _this._frameKeys.length) {\n _this._nextBatch();\n }\n else {\n _this._processAnimations();\n _this._parseComplete();\n }\n }, 0);\n };\n /**\n * Destroy Spritesheet and don't use after this.\n *\n * @param {boolean} [destroyBase=false] - Whether to destroy the base texture as well\n */\n Spritesheet.prototype.destroy = function (destroyBase) {\n var _a;\n if (destroyBase === void 0) { destroyBase = false; }\n for (var i in this.textures) {\n this.textures[i].destroy();\n }\n this._frames = null;\n this._frameKeys = null;\n this.data = null;\n this.textures = null;\n if (destroyBase) {\n (_a = this._texture) === null || _a === void 0 ? void 0 : _a.destroy();\n this.baseTexture.destroy();\n }\n this._texture = null;\n this.baseTexture = null;\n };\n /** The maximum number of Textures to build per process. */\n Spritesheet.BATCH_SIZE = 1000;\n return Spritesheet;\n}());\n/**\n * Reference to Spritesheet object created.\n * @member {PIXI.Spritesheet} spritesheet\n * @memberof PIXI.LoaderResource\n * @instance\n */\n/**\n * Dictionary of textures from Spritesheet.\n * @member {object<string, PIXI.Texture>} textures\n * @memberof PIXI.LoaderResource\n * @instance\n */\n\n/**\n * {@link PIXI.Loader} middleware for loading texture atlases that have been created with\n * TexturePacker or similar JSON-based spritesheet.\n *\n * This middleware automatically generates Texture resources.\n *\n * If you're using Webpack or other bundlers and plan on bundling the atlas' JSON,\n * use the {@link PIXI.Spritesheet} class to directly parse the JSON.\n *\n * The Loader's image Resource name is automatically appended with `\"_image\"`.\n * If a Resource with this name is already loaded, the Loader will skip parsing the\n * Spritesheet. The code below will generate an internal Loader Resource called `\"myatlas_image\"`.\n *\n * @example\n * loader.add('myatlas', 'path/to/myatlas.json');\n * loader.load(() => {\n * loader.resources.myatlas; // atlas JSON resource\n * loader.resources.myatlas_image; // atlas Image resource\n * });\n *\n * @memberof PIXI\n */\nvar SpritesheetLoader = /** @class */ (function () {\n function SpritesheetLoader() {\n }\n /**\n * Called after a resource is loaded.\n *\n * @see PIXI.Loader.loaderMiddleware\n * @param resource\n * @param next\n */\n SpritesheetLoader.use = function (resource, next) {\n var _a, _b;\n // because this is middleware, it execute in loader context. `this` = loader\n var loader = this;\n var imageResourceName = resource.name + \"_image\";\n // skip if no data, its not json, it isn't spritesheet data, or the image resource already exists\n if (!resource.data\n || resource.type !== LoaderResource.TYPE.JSON\n || !resource.data.frames\n || loader.resources[imageResourceName]) {\n next();\n return;\n }\n // Check and add the multi atlas\n // Heavily influenced and based on https://github.com/rocket-ua/pixi-tps-loader/blob/master/src/ResourceLoader.js\n // eslint-disable-next-line camelcase\n var multiPacks = (_b = (_a = resource.data) === null || _a === void 0 ? void 0 : _a.meta) === null || _b === void 0 ? void 0 : _b.related_multi_packs;\n if (Array.isArray(multiPacks)) {\n var _loop_1 = function (item) {\n if (typeof item !== 'string') {\n return \"continue\";\n }\n var itemName = item.replace('.json', '');\n var itemUrl = url.resolve(resource.url.replace(loader.baseUrl, ''), item);\n // Check if the file wasn't already added as multipacks are redundant\n if (loader.resources[itemName]\n || Object.values(loader.resources).some(function (r) { return url.format(url.parse(r.url)) === itemUrl; })) {\n return \"continue\";\n }\n var options = {\n crossOrigin: resource.crossOrigin,\n loadType: LoaderResource.LOAD_TYPE.XHR,\n xhrType: LoaderResource.XHR_RESPONSE_TYPE.JSON,\n parentResource: resource,\n metadata: resource.metadata\n };\n loader.add(itemName, itemUrl, options);\n };\n for (var _i = 0, multiPacks_1 = multiPacks; _i < multiPacks_1.length; _i++) {\n var item = multiPacks_1[_i];\n _loop_1(item);\n }\n }\n var loadOptions = {\n crossOrigin: resource.crossOrigin,\n metadata: resource.metadata.imageMetadata,\n parentResource: resource,\n };\n var resourcePath = SpritesheetLoader.getResourcePath(resource, loader.baseUrl);\n // load the image for this sheet\n loader.add(imageResourceName, resourcePath, loadOptions, function onImageLoad(res) {\n if (res.error) {\n next(res.error);\n return;\n }\n var spritesheet = new Spritesheet(res.texture, resource.data, resource.url);\n spritesheet.parse(function () {\n resource.spritesheet = spritesheet;\n resource.textures = spritesheet.textures;\n next();\n });\n });\n };\n /**\n * Get the spritesheets root path\n *\n * @param resource - Resource to check path\n * @param baseUrl - Base root url\n */\n SpritesheetLoader.getResourcePath = function (resource, baseUrl) {\n // Prepend url path unless the resource image is a data url\n if (resource.isDataUrl) {\n return resource.data.meta.image;\n }\n return url.resolve(resource.url.replace(baseUrl, ''), resource.data.meta.image);\n };\n return SpritesheetLoader;\n}());\n\nexport { Spritesheet, SpritesheetLoader };\n//# sourceMappingURL=spritesheet.js.map\n","/*!\n * @pixi/sprite-tiling - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/sprite-tiling is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture, TextureMatrix, Shader, QuadUv, State, ObjectRenderer } from '@pixi/core';\nimport { Point, Rectangle, Transform, Matrix } from '@pixi/math';\nimport { Sprite } from '@pixi/sprite';\nimport { WRAP_MODES } from '@pixi/constants';\nimport { premultiplyTintToRgba, correctBlendMode } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar tempPoint = new Point();\n/**\n * A tiling sprite is a fast way of rendering a tiling image.\n *\n * @memberof PIXI\n */\nvar TilingSprite = /** @class */ (function (_super) {\n __extends(TilingSprite, _super);\n /**\n * @param texture - The texture of the tiling sprite.\n * @param width - The width of the tiling sprite.\n * @param height - The height of the tiling sprite.\n */\n function TilingSprite(texture, width, height) {\n if (width === void 0) { width = 100; }\n if (height === void 0) { height = 100; }\n var _this = _super.call(this, texture) || this;\n _this.tileTransform = new Transform();\n // The width of the tiling sprite\n _this._width = width;\n // The height of the tiling sprite\n _this._height = height;\n _this.uvMatrix = _this.texture.uvMatrix || new TextureMatrix(texture);\n /**\n * Plugin that is responsible for rendering this element.\n * Allows to customize the rendering process without overriding '_render' method.\n *\n * @default 'tilingSprite'\n */\n _this.pluginName = 'tilingSprite';\n _this.uvRespectAnchor = false;\n return _this;\n }\n Object.defineProperty(TilingSprite.prototype, \"clampMargin\", {\n /**\n * Changes frame clamping in corresponding textureTransform, shortcut\n * Change to -0.5 to add a pixel to the edge, recommended for transparent trimmed textures in atlas\n *\n * @default 0.5\n * @member {number}\n */\n get: function () {\n return this.uvMatrix.clampMargin;\n },\n set: function (value) {\n this.uvMatrix.clampMargin = value;\n this.uvMatrix.update(true);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TilingSprite.prototype, \"tileScale\", {\n /** The scaling of the image that is being tiled. */\n get: function () {\n return this.tileTransform.scale;\n },\n set: function (value) {\n this.tileTransform.scale.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TilingSprite.prototype, \"tilePosition\", {\n /** The offset of the image that is being tiled. */\n get: function () {\n return this.tileTransform.position;\n },\n set: function (value) {\n this.tileTransform.position.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * @protected\n */\n TilingSprite.prototype._onTextureUpdate = function () {\n if (this.uvMatrix) {\n this.uvMatrix.texture = this._texture;\n }\n this._cachedTint = 0xFFFFFF;\n };\n /**\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The renderer\n */\n TilingSprite.prototype._render = function (renderer) {\n // tweak our texture temporarily..\n var texture = this._texture;\n if (!texture || !texture.valid) {\n return;\n }\n this.tileTransform.updateLocalTransform();\n this.uvMatrix.update();\n renderer.batch.setObjectRenderer(renderer.plugins[this.pluginName]);\n renderer.plugins[this.pluginName].render(this);\n };\n /** Updates the bounds of the tiling sprite. */\n TilingSprite.prototype._calculateBounds = function () {\n var minX = this._width * -this._anchor._x;\n var minY = this._height * -this._anchor._y;\n var maxX = this._width * (1 - this._anchor._x);\n var maxY = this._height * (1 - this._anchor._y);\n this._bounds.addFrame(this.transform, minX, minY, maxX, maxY);\n };\n /**\n * Gets the local bounds of the sprite object.\n *\n * @param rect - Optional output rectangle.\n * @return The bounds.\n */\n TilingSprite.prototype.getLocalBounds = function (rect) {\n // we can do a fast local bounds if the sprite has no children!\n if (this.children.length === 0) {\n this._bounds.minX = this._width * -this._anchor._x;\n this._bounds.minY = this._height * -this._anchor._y;\n this._bounds.maxX = this._width * (1 - this._anchor._x);\n this._bounds.maxY = this._height * (1 - this._anchor._y);\n if (!rect) {\n if (!this._localBoundsRect) {\n this._localBoundsRect = new Rectangle();\n }\n rect = this._localBoundsRect;\n }\n return this._bounds.getRectangle(rect);\n }\n return _super.prototype.getLocalBounds.call(this, rect);\n };\n /**\n * Checks if a point is inside this tiling sprite.\n *\n * @param point - The point to check.\n * @return Whether or not the sprite contains the point.\n */\n TilingSprite.prototype.containsPoint = function (point) {\n this.worldTransform.applyInverse(point, tempPoint);\n var width = this._width;\n var height = this._height;\n var x1 = -width * this.anchor._x;\n if (tempPoint.x >= x1 && tempPoint.x < x1 + width) {\n var y1 = -height * this.anchor._y;\n if (tempPoint.y >= y1 && tempPoint.y < y1 + height) {\n return true;\n }\n }\n return false;\n };\n /**\n * Destroys this sprite and optionally its texture and children\n *\n * @param {object|boolean} [options] - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Should it destroy the current texture of the sprite as well\n * @param {boolean} [options.baseTexture=false] - Should it destroy the base texture of the sprite as well\n */\n TilingSprite.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n this.tileTransform = null;\n this.uvMatrix = null;\n };\n /**\n * Helper function that creates a new tiling sprite based on the source you provide.\n * The source can be - frame id, image url, video url, canvas element, video element, base texture\n *\n * @static\n * @param {string|PIXI.Texture|HTMLCanvasElement|HTMLVideoElement} source - Source to create texture from\n * @param {Object} options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @param {number} options.width - required width of the tiling sprite\n * @param {number} options.height - required height of the tiling sprite\n * @return {PIXI.TilingSprite} The newly created texture\n */\n TilingSprite.from = function (source, options) {\n var texture = (source instanceof Texture)\n ? source\n : Texture.from(source, options);\n return new TilingSprite(texture, options.width, options.height);\n };\n Object.defineProperty(TilingSprite.prototype, \"width\", {\n /** The width of the sprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this._width;\n },\n set: function (value) {\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TilingSprite.prototype, \"height\", {\n /** The height of the TilingSprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this._height;\n },\n set: function (value) {\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n return TilingSprite;\n}(Sprite));\n\nvar fragmentSimpleSrc = \"#version 100\\n#define SHADER_NAME Tiling-Sprite-Simple-100\\n\\nprecision lowp float;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform vec4 uColor;\\n\\nvoid main(void)\\n{\\n vec4 texSample = texture2D(uSampler, vTextureCoord);\\n gl_FragColor = texSample * uColor;\\n}\\n\";\n\nvar gl1VertexSrc = \"#version 100\\n#define SHADER_NAME Tiling-Sprite-100\\n\\nprecision lowp float;\\n\\nattribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform mat3 uTransform;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\\n}\\n\";\n\nvar gl1FragmentSrc = \"#version 100\\n#ifdef GL_EXT_shader_texture_lod\\n #extension GL_EXT_shader_texture_lod : enable\\n#endif\\n#define SHADER_NAME Tiling-Sprite-100\\n\\nprecision lowp float;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform vec4 uColor;\\nuniform mat3 uMapCoord;\\nuniform vec4 uClampFrame;\\nuniform vec2 uClampOffset;\\n\\nvoid main(void)\\n{\\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\\n vec2 unclamped = coord;\\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\\n\\n #ifdef GL_EXT_shader_texture_lod\\n vec4 texSample = unclamped == coord\\n ? texture2D(uSampler, coord) \\n : texture2DLodEXT(uSampler, coord, 0);\\n #else\\n vec4 texSample = texture2D(uSampler, coord);\\n #endif\\n\\n gl_FragColor = texSample * uColor;\\n}\\n\";\n\nvar gl2VertexSrc = \"#version 300 es\\n#define SHADER_NAME Tiling-Sprite-300\\n\\nprecision lowp float;\\n\\nin vec2 aVertexPosition;\\nin vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform mat3 uTransform;\\n\\nout vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\\n}\\n\";\n\nvar gl2FragmentSrc = \"#version 300 es\\n#define SHADER_NAME Tiling-Sprite-100\\n\\nprecision lowp float;\\n\\nin vec2 vTextureCoord;\\n\\nout vec4 fragmentColor;\\n\\nuniform sampler2D uSampler;\\nuniform vec4 uColor;\\nuniform mat3 uMapCoord;\\nuniform vec4 uClampFrame;\\nuniform vec2 uClampOffset;\\n\\nvoid main(void)\\n{\\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\\n vec2 unclamped = coord;\\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\\n\\n vec4 texSample = texture(uSampler, coord, unclamped == coord ? 0.0f : -32.0f);// lod-bias very negative to force lod 0\\n\\n fragmentColor = texSample * uColor;\\n}\\n\";\n\nvar tempMat = new Matrix();\n/**\n * WebGL renderer plugin for tiling sprites\n *\n * @class\n * @memberof PIXI\n * @extends PIXI.ObjectRenderer\n */\nvar TilingSpriteRenderer = /** @class */ (function (_super) {\n __extends(TilingSpriteRenderer, _super);\n /**\n * constructor for renderer\n *\n * @param {PIXI.Renderer} renderer - The renderer this tiling awesomeness works for.\n */\n function TilingSpriteRenderer(renderer) {\n var _this = _super.call(this, renderer) || this;\n // WebGL version is not available during initialization!\n renderer.runners.contextChange.add(_this);\n _this.quad = new QuadUv();\n /**\n * The WebGL state in which this renderer will work.\n *\n * @member {PIXI.State}\n * @readonly\n */\n _this.state = State.for2d();\n return _this;\n }\n /**\n * Creates shaders when context is initialized.\n */\n TilingSpriteRenderer.prototype.contextChange = function () {\n var renderer = this.renderer;\n var uniforms = { globals: renderer.globalUniforms };\n this.simpleShader = Shader.from(gl1VertexSrc, fragmentSimpleSrc, uniforms);\n this.shader = renderer.context.webGLVersion > 1\n ? Shader.from(gl2VertexSrc, gl2FragmentSrc, uniforms)\n : Shader.from(gl1VertexSrc, gl1FragmentSrc, uniforms);\n };\n /**\n * @param {PIXI.TilingSprite} ts - tilingSprite to be rendered\n */\n TilingSpriteRenderer.prototype.render = function (ts) {\n var renderer = this.renderer;\n var quad = this.quad;\n var vertices = quad.vertices;\n vertices[0] = vertices[6] = (ts._width) * -ts.anchor.x;\n vertices[1] = vertices[3] = ts._height * -ts.anchor.y;\n vertices[2] = vertices[4] = (ts._width) * (1.0 - ts.anchor.x);\n vertices[5] = vertices[7] = ts._height * (1.0 - ts.anchor.y);\n var anchorX = ts.uvRespectAnchor ? ts.anchor.x : 0;\n var anchorY = ts.uvRespectAnchor ? ts.anchor.y : 0;\n vertices = quad.uvs;\n vertices[0] = vertices[6] = -anchorX;\n vertices[1] = vertices[3] = -anchorY;\n vertices[2] = vertices[4] = 1.0 - anchorX;\n vertices[5] = vertices[7] = 1.0 - anchorY;\n quad.invalidate();\n var tex = ts._texture;\n var baseTex = tex.baseTexture;\n var lt = ts.tileTransform.localTransform;\n var uv = ts.uvMatrix;\n var isSimple = baseTex.isPowerOfTwo\n && tex.frame.width === baseTex.width && tex.frame.height === baseTex.height;\n // auto, force repeat wrapMode for big tiling textures\n if (isSimple) {\n if (!baseTex._glTextures[renderer.CONTEXT_UID]) {\n if (baseTex.wrapMode === WRAP_MODES.CLAMP) {\n baseTex.wrapMode = WRAP_MODES.REPEAT;\n }\n }\n else {\n isSimple = baseTex.wrapMode !== WRAP_MODES.CLAMP;\n }\n }\n var shader = isSimple ? this.simpleShader : this.shader;\n var w = tex.width;\n var h = tex.height;\n var W = ts._width;\n var H = ts._height;\n tempMat.set(lt.a * w / W, lt.b * w / H, lt.c * h / W, lt.d * h / H, lt.tx / W, lt.ty / H);\n // that part is the same as above:\n // tempMat.identity();\n // tempMat.scale(tex.width, tex.height);\n // tempMat.prepend(lt);\n // tempMat.scale(1.0 / ts._width, 1.0 / ts._height);\n tempMat.invert();\n if (isSimple) {\n tempMat.prepend(uv.mapCoord);\n }\n else {\n shader.uniforms.uMapCoord = uv.mapCoord.toArray(true);\n shader.uniforms.uClampFrame = uv.uClampFrame;\n shader.uniforms.uClampOffset = uv.uClampOffset;\n }\n shader.uniforms.uTransform = tempMat.toArray(true);\n shader.uniforms.uColor = premultiplyTintToRgba(ts.tint, ts.worldAlpha, shader.uniforms.uColor, baseTex.alphaMode);\n shader.uniforms.translationMatrix = ts.transform.worldTransform.toArray(true);\n shader.uniforms.uSampler = tex;\n renderer.shader.bind(shader);\n renderer.geometry.bind(quad);\n this.state.blendMode = correctBlendMode(ts.blendMode, baseTex.alphaMode);\n renderer.state.set(this.state);\n renderer.geometry.draw(this.renderer.gl.TRIANGLES, 6, 0);\n };\n return TilingSpriteRenderer;\n}(ObjectRenderer));\n\nexport { TilingSprite, TilingSpriteRenderer };\n//# sourceMappingURL=sprite-tiling.js.map\n","/*!\n * @pixi/mesh - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mesh is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { State, Program, TextureMatrix, Shader, Buffer, Geometry } from '@pixi/core';\nimport { Point, Polygon, Matrix } from '@pixi/math';\nimport { DRAW_MODES, TYPES } from '@pixi/constants';\nimport { Container } from '@pixi/display';\nimport { settings } from '@pixi/settings';\nimport { premultiplyTintToRgba } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * Class controls cache for UV mapping from Texture normal space to BaseTexture normal space.\n *\n * @memberof PIXI\n */\nvar MeshBatchUvs = /** @class */ (function () {\n /**\n * @param uvBuffer - Buffer with normalized uv's\n * @param uvMatrix - Material UV matrix\n */\n function MeshBatchUvs(uvBuffer, uvMatrix) {\n this.uvBuffer = uvBuffer;\n this.uvMatrix = uvMatrix;\n this.data = null;\n this._bufferUpdateId = -1;\n this._textureUpdateId = -1;\n this._updateID = 0;\n }\n /**\n * Updates\n *\n * @param forceUpdate - force the update\n */\n MeshBatchUvs.prototype.update = function (forceUpdate) {\n if (!forceUpdate\n && this._bufferUpdateId === this.uvBuffer._updateID\n && this._textureUpdateId === this.uvMatrix._updateID) {\n return;\n }\n this._bufferUpdateId = this.uvBuffer._updateID;\n this._textureUpdateId = this.uvMatrix._updateID;\n var data = this.uvBuffer.data;\n if (!this.data || this.data.length !== data.length) {\n this.data = new Float32Array(data.length);\n }\n this.uvMatrix.multiplyUvs(data, this.data);\n this._updateID++;\n };\n return MeshBatchUvs;\n}());\n\nvar tempPoint = new Point();\nvar tempPolygon = new Polygon();\n/**\n * Base mesh class.\n *\n * This class empowers you to have maximum flexibility to render any kind of WebGL visuals you can think of.\n * This class assumes a certain level of WebGL knowledge.\n * If you know a bit this should abstract enough away to make your life easier!\n *\n * Pretty much ALL WebGL can be broken down into the following:\n * - Geometry - The structure and data for the mesh. This can include anything from positions, uvs, normals, colors etc..\n * - Shader - This is the shader that PixiJS will render the geometry with (attributes in the shader must match the geometry)\n * - State - This is the state of WebGL required to render the mesh.\n *\n * Through a combination of the above elements you can render anything you want, 2D or 3D!\n *\n * @memberof PIXI\n */\nvar Mesh = /** @class */ (function (_super) {\n __extends(Mesh, _super);\n /**\n * @param geometry - The geometry the mesh will use.\n * @param {PIXI.MeshMaterial} shader - The shader the mesh will use.\n * @param state - The state that the WebGL context is required to be in to render the mesh\n * if no state is provided, uses {@link PIXI.State.for2d} to create a 2D state for PixiJS.\n * @param drawMode - The drawMode, can be any of the {@link PIXI.DRAW_MODES} constants.\n */\n function Mesh(geometry, shader, state, drawMode) {\n if (drawMode === void 0) { drawMode = DRAW_MODES.TRIANGLES; }\n var _this = _super.call(this) || this;\n _this.geometry = geometry;\n _this.shader = shader;\n _this.state = state || State.for2d();\n _this.drawMode = drawMode;\n _this.start = 0;\n _this.size = 0;\n _this.uvs = null;\n _this.indices = null;\n _this.vertexData = new Float32Array(1);\n _this.vertexDirty = -1;\n _this._transformID = -1;\n _this._roundPixels = settings.ROUND_PIXELS;\n _this.batchUvs = null;\n return _this;\n }\n Object.defineProperty(Mesh.prototype, \"geometry\", {\n /**\n * Includes vertex positions, face indices, normals, colors, UVs, and\n * custom attributes within buffers, reducing the cost of passing all\n * this data to the GPU. Can be shared between multiple Mesh objects.\n */\n get: function () {\n return this._geometry;\n },\n set: function (value) {\n if (this._geometry === value) {\n return;\n }\n if (this._geometry) {\n this._geometry.refCount--;\n if (this._geometry.refCount === 0) {\n this._geometry.dispose();\n }\n }\n this._geometry = value;\n if (this._geometry) {\n this._geometry.refCount++;\n }\n this.vertexDirty = -1;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"uvBuffer\", {\n /**\n * To change mesh uv's, change its uvBuffer data and increment its _updateID.\n *\n * @readonly\n */\n get: function () {\n return this.geometry.buffers[1];\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"verticesBuffer\", {\n /**\n * To change mesh vertices, change its uvBuffer data and increment its _updateID.\n * Incrementing _updateID is optional because most of Mesh objects do it anyway.\n *\n * @readonly\n */\n get: function () {\n return this.geometry.buffers[0];\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"material\", {\n get: function () {\n return this.shader;\n },\n /** Alias for {@link PIXI.Mesh#shader}. */\n set: function (value) {\n this.shader = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"blendMode\", {\n get: function () {\n return this.state.blendMode;\n },\n /**\n * The blend mode to be applied to the Mesh. Apply a value of\n * `PIXI.BLEND_MODES.NORMAL` to reset the blend mode.\n *\n * @default PIXI.BLEND_MODES.NORMAL;\n */\n set: function (value) {\n this.state.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"roundPixels\", {\n get: function () {\n return this._roundPixels;\n },\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n * To set the global default, change {@link PIXI.settings.ROUND_PIXELS}\n *\n * @default false\n */\n set: function (value) {\n if (this._roundPixels !== value) {\n this._transformID = -1;\n }\n this._roundPixels = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"tint\", {\n /**\n * The multiply tint applied to the Mesh. This is a hex value. A value of\n * `0xFFFFFF` will remove any tint effect.\n *\n * Null for non-MeshMaterial shaders\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return 'tint' in this.shader ? this.shader.tint : null;\n },\n set: function (value) {\n this.shader.tint = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"texture\", {\n /**\n * The texture that the Mesh uses.\n *\n * Null for non-MeshMaterial shaders\n */\n get: function () {\n return 'texture' in this.shader ? this.shader.texture : null;\n },\n set: function (value) {\n this.shader.texture = value;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Standard renderer draw.\n *\n * @param renderer - Instance to renderer.\n */\n Mesh.prototype._render = function (renderer) {\n // set properties for batching..\n // TODO could use a different way to grab verts?\n var vertices = this.geometry.buffers[0].data;\n var shader = this.shader;\n // TODO benchmark check for attribute size..\n if (shader.batchable\n && this.drawMode === DRAW_MODES.TRIANGLES\n && vertices.length < Mesh.BATCHABLE_SIZE * 2) {\n this._renderToBatch(renderer);\n }\n else {\n this._renderDefault(renderer);\n }\n };\n /**\n * Standard non-batching way of rendering.\n *\n * @param renderer - Instance to renderer.\n */\n Mesh.prototype._renderDefault = function (renderer) {\n var shader = this.shader;\n shader.alpha = this.worldAlpha;\n if (shader.update) {\n shader.update();\n }\n renderer.batch.flush();\n // bind and sync uniforms..\n shader.uniforms.translationMatrix = this.transform.worldTransform.toArray(true);\n renderer.shader.bind(shader);\n // set state..\n renderer.state.set(this.state);\n // bind the geometry...\n renderer.geometry.bind(this.geometry, shader);\n // then render it\n renderer.geometry.draw(this.drawMode, this.size, this.start, this.geometry.instanceCount);\n };\n /**\n * Rendering by using the Batch system.\n *\n * @param renderer - Instance to renderer.\n */\n Mesh.prototype._renderToBatch = function (renderer) {\n var geometry = this.geometry;\n var shader = this.shader;\n if (shader.uvMatrix) {\n shader.uvMatrix.update();\n this.calculateUvs();\n }\n // set properties for batching..\n this.calculateVertices();\n this.indices = geometry.indexBuffer.data;\n this._tintRGB = shader._tintRGB;\n this._texture = shader.texture;\n var pluginName = this.material.pluginName;\n renderer.batch.setObjectRenderer(renderer.plugins[pluginName]);\n renderer.plugins[pluginName].render(this);\n };\n /** Updates vertexData field based on transform and vertices. */\n Mesh.prototype.calculateVertices = function () {\n var geometry = this.geometry;\n var verticesBuffer = geometry.buffers[0];\n var vertices = verticesBuffer.data;\n var vertexDirtyId = verticesBuffer._updateID;\n if (vertexDirtyId === this.vertexDirty && this._transformID === this.transform._worldID) {\n return;\n }\n this._transformID = this.transform._worldID;\n if (this.vertexData.length !== vertices.length) {\n this.vertexData = new Float32Array(vertices.length);\n }\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var vertexData = this.vertexData;\n for (var i = 0; i < vertexData.length / 2; i++) {\n var x = vertices[(i * 2)];\n var y = vertices[(i * 2) + 1];\n vertexData[(i * 2)] = (a * x) + (c * y) + tx;\n vertexData[(i * 2) + 1] = (b * x) + (d * y) + ty;\n }\n if (this._roundPixels) {\n var resolution = settings.RESOLUTION;\n for (var i = 0; i < vertexData.length; ++i) {\n vertexData[i] = Math.round((vertexData[i] * resolution | 0) / resolution);\n }\n }\n this.vertexDirty = vertexDirtyId;\n };\n /** Updates uv field based on from geometry uv's or batchUvs. */\n Mesh.prototype.calculateUvs = function () {\n var geomUvs = this.geometry.buffers[1];\n var shader = this.shader;\n if (!shader.uvMatrix.isSimple) {\n if (!this.batchUvs) {\n this.batchUvs = new MeshBatchUvs(geomUvs, shader.uvMatrix);\n }\n this.batchUvs.update();\n this.uvs = this.batchUvs.data;\n }\n else {\n this.uvs = geomUvs.data;\n }\n };\n /**\n * Updates the bounds of the mesh as a rectangle. The bounds calculation takes the worldTransform into account.\n * there must be a aVertexPosition attribute present in the geometry for bounds to be calculated correctly.\n */\n Mesh.prototype._calculateBounds = function () {\n this.calculateVertices();\n this._bounds.addVertexData(this.vertexData, 0, this.vertexData.length);\n };\n /**\n * Tests if a point is inside this mesh. Works only for PIXI.DRAW_MODES.TRIANGLES.\n *\n * @param point - The point to test.\n * @return - The result of the test.\n */\n Mesh.prototype.containsPoint = function (point) {\n if (!this.getBounds().contains(point.x, point.y)) {\n return false;\n }\n this.worldTransform.applyInverse(point, tempPoint);\n var vertices = this.geometry.getBuffer('aVertexPosition').data;\n var points = tempPolygon.points;\n var indices = this.geometry.getIndex().data;\n var len = indices.length;\n var step = this.drawMode === 4 ? 3 : 1;\n for (var i = 0; i + 2 < len; i += step) {\n var ind0 = indices[i] * 2;\n var ind1 = indices[i + 1] * 2;\n var ind2 = indices[i + 2] * 2;\n points[0] = vertices[ind0];\n points[1] = vertices[ind0 + 1];\n points[2] = vertices[ind1];\n points[3] = vertices[ind1 + 1];\n points[4] = vertices[ind2];\n points[5] = vertices[ind2 + 1];\n if (tempPolygon.contains(tempPoint.x, tempPoint.y)) {\n return true;\n }\n }\n return false;\n };\n Mesh.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n if (this._cachedTexture) {\n this._cachedTexture.destroy();\n this._cachedTexture = null;\n }\n this.geometry = null;\n this.shader = null;\n this.state = null;\n this.uvs = null;\n this.indices = null;\n this.vertexData = null;\n };\n /**\n * The maximum number of vertices to consider batchable. Generally, the complexity\n * of the geometry.\n */\n Mesh.BATCHABLE_SIZE = 100;\n return Mesh;\n}(Container));\n\nvar fragment = \"varying vec2 vTextureCoord;\\nuniform vec4 uColor;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void)\\n{\\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uColor;\\n}\\n\";\n\nvar vertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform mat3 uTextureMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\\n}\\n\";\n\n/**\n * Slightly opinionated default shader for PixiJS 2D objects.\n *\n * @memberof PIXI\n */\nvar MeshMaterial = /** @class */ (function (_super) {\n __extends(MeshMaterial, _super);\n /**\n * @param uSampler - Texture that material uses to render.\n * @param options - Additional options\n * @param {number} [options.alpha=1] - Default alpha.\n * @param {number} [options.tint=0xFFFFFF] - Default tint.\n * @param {string} [options.pluginName='batch'] - Renderer plugin for batching.\n * @param {PIXI.Program} [options.program=0xFFFFFF] - Custom program.\n * @param {object} [options.uniforms] - Custom uniforms.\n */\n function MeshMaterial(uSampler, options) {\n var _this = this;\n var uniforms = {\n uSampler: uSampler,\n alpha: 1,\n uTextureMatrix: Matrix.IDENTITY,\n uColor: new Float32Array([1, 1, 1, 1]),\n };\n // Set defaults\n options = Object.assign({\n tint: 0xFFFFFF,\n alpha: 1,\n pluginName: 'batch',\n }, options);\n if (options.uniforms) {\n Object.assign(uniforms, options.uniforms);\n }\n _this = _super.call(this, options.program || Program.from(vertex, fragment), uniforms) || this;\n _this._colorDirty = false;\n _this.uvMatrix = new TextureMatrix(uSampler);\n _this.batchable = options.program === undefined;\n _this.pluginName = options.pluginName;\n _this.tint = options.tint;\n _this.alpha = options.alpha;\n return _this;\n }\n Object.defineProperty(MeshMaterial.prototype, \"texture\", {\n /** Reference to the texture being rendered. */\n get: function () {\n return this.uniforms.uSampler;\n },\n set: function (value) {\n if (this.uniforms.uSampler !== value) {\n this.uniforms.uSampler = value;\n this.uvMatrix.texture = value;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MeshMaterial.prototype, \"alpha\", {\n get: function () {\n return this._alpha;\n },\n /**\n * This gets automatically set by the object using this.\n *\n * @default 1\n */\n set: function (value) {\n if (value === this._alpha)\n { return; }\n this._alpha = value;\n this._colorDirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MeshMaterial.prototype, \"tint\", {\n get: function () {\n return this._tint;\n },\n /**\n * Multiply tint for the material.\n *\n * @default 0xFFFFFF\n */\n set: function (value) {\n if (value === this._tint)\n { return; }\n this._tint = value;\n this._tintRGB = (value >> 16) + (value & 0xff00) + ((value & 0xff) << 16);\n this._colorDirty = true;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Gets called automatically by the Mesh. Intended to be overridden for custom\n * {@link MeshMaterial} objects.\n */\n MeshMaterial.prototype.update = function () {\n if (this._colorDirty) {\n this._colorDirty = false;\n var baseTexture = this.texture.baseTexture;\n premultiplyTintToRgba(this._tint, this._alpha, this.uniforms.uColor, baseTexture.alphaMode);\n }\n if (this.uvMatrix.update()) {\n this.uniforms.uTextureMatrix = this.uvMatrix.mapCoord;\n }\n };\n return MeshMaterial;\n}(Shader));\n\n/**\n * Standard 2D geometry used in PixiJS.\n *\n * Geometry can be defined without passing in a style or data if required.\n *\n * ```js\n * const geometry = new PIXI.Geometry();\n *\n * geometry.addAttribute('positions', [0, 0, 100, 0, 100, 100, 0, 100], 2);\n * geometry.addAttribute('uvs', [0,0,1,0,1,1,0,1], 2);\n * geometry.addIndex([0,1,2,1,3,2]);\n *\n * ```\n *\n * @memberof PIXI\n */\nvar MeshGeometry = /** @class */ (function (_super) {\n __extends(MeshGeometry, _super);\n /**\n * @param {Float32Array|number[]} [vertices] - Positional data on geometry.\n * @param {Float32Array|number[]} [uvs] - Texture UVs.\n * @param {Uint16Array|number[]} [index] - IndexBuffer\n */\n function MeshGeometry(vertices, uvs, index) {\n var _this = _super.call(this) || this;\n var verticesBuffer = new Buffer(vertices);\n var uvsBuffer = new Buffer(uvs, true);\n var indexBuffer = new Buffer(index, true, true);\n _this.addAttribute('aVertexPosition', verticesBuffer, 2, false, TYPES.FLOAT)\n .addAttribute('aTextureCoord', uvsBuffer, 2, false, TYPES.FLOAT)\n .addIndex(indexBuffer);\n _this._updateId = -1;\n return _this;\n }\n Object.defineProperty(MeshGeometry.prototype, \"vertexDirtyId\", {\n /**\n * If the vertex position is updated.\n *\n * @readonly\n * @private\n */\n get: function () {\n return this.buffers[0]._updateID;\n },\n enumerable: false,\n configurable: true\n });\n return MeshGeometry;\n}(Geometry));\n\nexport { Mesh, MeshBatchUvs, MeshGeometry, MeshMaterial };\n//# sourceMappingURL=mesh.js.map\n","/*!\n * @pixi/text-bitmap - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/text-bitmap is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Rectangle, Point, ObservablePoint } from '@pixi/math';\nimport { settings } from '@pixi/settings';\nimport { MeshGeometry, MeshMaterial, Mesh } from '@pixi/mesh';\nimport { hex2rgb, string2hex, getResolutionOfUrl, removeItems } from '@pixi/utils';\nimport { BaseTexture, Texture, Program } from '@pixi/core';\nimport { TEXT_GRADIENT, TextStyle, TextMetrics } from '@pixi/text';\nimport { ALPHA_MODES, BLEND_MODES } from '@pixi/constants';\nimport { Container } from '@pixi/display';\nimport { LoaderResource } from '@pixi/loaders';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/* eslint-disable max-len */\n/**\n * Normalized parsed data from .fnt files.\n *\n * @memberof PIXI\n */\nvar BitmapFontData = /** @class */ (function () {\n function BitmapFontData() {\n this.info = [];\n this.common = [];\n this.page = [];\n this.char = [];\n this.kerning = [];\n this.distanceField = [];\n }\n return BitmapFontData;\n}());\n\n/**\n * BitmapFont format that's Text-based.\n *\n * @private\n */\nvar TextFormat = /** @class */ (function () {\n function TextFormat() {\n }\n /**\n * Check if resource refers to txt font data.\n *\n * @param data\n * @return - True if resource could be treated as font data, false otherwise.\n */\n TextFormat.test = function (data) {\n return typeof data === 'string' && data.indexOf('info face=') === 0;\n };\n /**\n * Convert text font data to a javascript object.\n *\n * @param txt - Raw string data to be converted\n * @return - Parsed font data\n */\n TextFormat.parse = function (txt) {\n // Retrieve data item\n var items = txt.match(/^[a-z]+\\s+.+$/gm);\n var rawData = {\n info: [],\n common: [],\n page: [],\n char: [],\n chars: [],\n kerning: [],\n kernings: [],\n distanceField: [],\n };\n for (var i in items) {\n // Extract item name\n var name = items[i].match(/^[a-z]+/gm)[0];\n // Extract item attribute list as string ex.: \"width=10\"\n var attributeList = items[i].match(/[a-zA-Z]+=([^\\s\"']+|\"([^\"]*)\")/gm);\n // Convert attribute list into an object\n var itemData = {};\n for (var i_1 in attributeList) {\n // Split key-value pairs\n var split = attributeList[i_1].split('=');\n var key = split[0];\n // Remove eventual quotes from value\n var strValue = split[1].replace(/\"/gm, '');\n // Try to convert value into float\n var floatValue = parseFloat(strValue);\n // Use string value case float value is NaN\n var value = isNaN(floatValue) ? strValue : floatValue;\n itemData[key] = value;\n }\n // Push current item to the resulting data\n rawData[name].push(itemData);\n }\n var font = new BitmapFontData();\n rawData.info.forEach(function (info) { return font.info.push({\n face: info.face,\n size: parseInt(info.size, 10),\n }); });\n rawData.common.forEach(function (common) { return font.common.push({\n lineHeight: parseInt(common.lineHeight, 10),\n }); });\n rawData.page.forEach(function (page) { return font.page.push({\n id: parseInt(page.id, 10),\n file: page.file,\n }); });\n rawData.char.forEach(function (char) { return font.char.push({\n id: parseInt(char.id, 10),\n page: parseInt(char.page, 10),\n x: parseInt(char.x, 10),\n y: parseInt(char.y, 10),\n width: parseInt(char.width, 10),\n height: parseInt(char.height, 10),\n xoffset: parseInt(char.xoffset, 10),\n yoffset: parseInt(char.yoffset, 10),\n xadvance: parseInt(char.xadvance, 10),\n }); });\n rawData.kerning.forEach(function (kerning) { return font.kerning.push({\n first: parseInt(kerning.first, 10),\n second: parseInt(kerning.second, 10),\n amount: parseInt(kerning.amount, 10),\n }); });\n rawData.distanceField.forEach(function (df) { return font.distanceField.push({\n distanceRange: parseInt(df.distanceRange, 10),\n fieldType: df.fieldType,\n }); });\n return font;\n };\n return TextFormat;\n}());\n\n/**\n * BitmapFont format that's XML-based.\n *\n * @private\n */\nvar XMLFormat = /** @class */ (function () {\n function XMLFormat() {\n }\n /**\n * Check if resource refers to xml font data.\n *\n * @param data\n * @return - True if resource could be treated as font data, false otherwise.\n */\n XMLFormat.test = function (data) {\n return data instanceof XMLDocument\n && data.getElementsByTagName('page').length\n && data.getElementsByTagName('info')[0].getAttribute('face') !== null;\n };\n /**\n * Convert the XML into BitmapFontData that we can use.\n *\n * @param xml\n * @return - Data to use for BitmapFont\n */\n XMLFormat.parse = function (xml) {\n var data = new BitmapFontData();\n var info = xml.getElementsByTagName('info');\n var common = xml.getElementsByTagName('common');\n var page = xml.getElementsByTagName('page');\n var char = xml.getElementsByTagName('char');\n var kerning = xml.getElementsByTagName('kerning');\n var distanceField = xml.getElementsByTagName('distanceField');\n for (var i = 0; i < info.length; i++) {\n data.info.push({\n face: info[i].getAttribute('face'),\n size: parseInt(info[i].getAttribute('size'), 10),\n });\n }\n for (var i = 0; i < common.length; i++) {\n data.common.push({\n lineHeight: parseInt(common[i].getAttribute('lineHeight'), 10),\n });\n }\n for (var i = 0; i < page.length; i++) {\n data.page.push({\n id: parseInt(page[i].getAttribute('id'), 10) || 0,\n file: page[i].getAttribute('file'),\n });\n }\n for (var i = 0; i < char.length; i++) {\n var letter = char[i];\n data.char.push({\n id: parseInt(letter.getAttribute('id'), 10),\n page: parseInt(letter.getAttribute('page'), 10) || 0,\n x: parseInt(letter.getAttribute('x'), 10),\n y: parseInt(letter.getAttribute('y'), 10),\n width: parseInt(letter.getAttribute('width'), 10),\n height: parseInt(letter.getAttribute('height'), 10),\n xoffset: parseInt(letter.getAttribute('xoffset'), 10),\n yoffset: parseInt(letter.getAttribute('yoffset'), 10),\n xadvance: parseInt(letter.getAttribute('xadvance'), 10),\n });\n }\n for (var i = 0; i < kerning.length; i++) {\n data.kerning.push({\n first: parseInt(kerning[i].getAttribute('first'), 10),\n second: parseInt(kerning[i].getAttribute('second'), 10),\n amount: parseInt(kerning[i].getAttribute('amount'), 10),\n });\n }\n for (var i = 0; i < distanceField.length; i++) {\n data.distanceField.push({\n fieldType: distanceField[i].getAttribute('fieldType'),\n distanceRange: parseInt(distanceField[i].getAttribute('distanceRange'), 10),\n });\n }\n return data;\n };\n return XMLFormat;\n}());\n\n/**\n * BitmapFont format that's XML-based.\n *\n * @private\n */\nvar XMLStringFormat = /** @class */ (function () {\n function XMLStringFormat() {\n }\n /**\n * Check if resource refers to text xml font data.\n *\n * @param data\n * @return - True if resource could be treated as font data, false otherwise.\n */\n XMLStringFormat.test = function (data) {\n if (typeof data === 'string' && data.indexOf('<font>') > -1) {\n var xml = new globalThis.DOMParser().parseFromString(data, 'text/xml');\n return XMLFormat.test(xml);\n }\n return false;\n };\n /**\n * Convert the text XML into BitmapFontData that we can use.\n *\n * @param xmlTxt\n * @return - Data to use for BitmapFont\n */\n XMLStringFormat.parse = function (xmlTxt) {\n var xml = new globalThis.DOMParser().parseFromString(xmlTxt, 'text/xml');\n return XMLFormat.parse(xml);\n };\n return XMLStringFormat;\n}());\n\n// Registered formats, maybe make this extensible in the future?\nvar formats = [\n TextFormat,\n XMLFormat,\n XMLStringFormat ];\n/**\n * Auto-detect BitmapFont parsing format based on data.\n * @private\n * @param {any} data - Data to detect format\n * @return {any} Format or null\n */\nfunction autoDetectFormat(data) {\n for (var i = 0; i < formats.length; i++) {\n if (formats[i].test(data)) {\n return formats[i];\n }\n }\n return null;\n}\n\n// TODO: Prevent code duplication b/w generateFillStyle & Text#generateFillStyle\n/**\n * Generates the fill style. Can automatically generate a gradient based on the fill style being an array\n *\n * @private\n * @param {object} style - The style.\n * @param {string[]} lines - The lines of text.\n * @return {string|number|CanvasGradient} The fill style\n */\nfunction generateFillStyle(canvas, context, style, resolution, lines, metrics) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n var fillStyle = style.fill;\n if (!Array.isArray(fillStyle)) {\n return fillStyle;\n }\n else if (fillStyle.length === 1) {\n return fillStyle[0];\n }\n // the gradient will be evenly spaced out according to how large the array is.\n // ['#FF0000', '#00FF00', '#0000FF'] would created stops at 0.25, 0.5 and 0.75\n var gradient;\n // a dropshadow will enlarge the canvas and result in the gradient being\n // generated with the incorrect dimensions\n var dropShadowCorrection = (style.dropShadow) ? style.dropShadowDistance : 0;\n // should also take padding into account, padding can offset the gradient\n var padding = style.padding || 0;\n var width = (canvas.width / resolution) - dropShadowCorrection - (padding * 2);\n var height = (canvas.height / resolution) - dropShadowCorrection - (padding * 2);\n // make a copy of the style settings, so we can manipulate them later\n var fill = fillStyle.slice();\n var fillGradientStops = style.fillGradientStops.slice();\n // wanting to evenly distribute the fills. So an array of 4 colours should give fills of 0.25, 0.5 and 0.75\n if (!fillGradientStops.length) {\n var lengthPlus1 = fill.length + 1;\n for (var i = 1; i < lengthPlus1; ++i) {\n fillGradientStops.push(i / lengthPlus1);\n }\n }\n // stop the bleeding of the last gradient on the line above to the top gradient of the this line\n // by hard defining the first gradient colour at point 0, and last gradient colour at point 1\n fill.unshift(fillStyle[0]);\n fillGradientStops.unshift(0);\n fill.push(fillStyle[fillStyle.length - 1]);\n fillGradientStops.push(1);\n if (style.fillGradientType === TEXT_GRADIENT.LINEAR_VERTICAL) {\n // start the gradient at the top center of the canvas, and end at the bottom middle of the canvas\n gradient = context.createLinearGradient(width / 2, padding, width / 2, height + padding);\n // we need to repeat the gradient so that each individual line of text has the same vertical gradient effect\n // ['#FF0000', '#00FF00', '#0000FF'] over 2 lines would create stops at 0.125, 0.25, 0.375, 0.625, 0.75, 0.875\n // There's potential for floating point precision issues at the seams between gradient repeats.\n // The loop below generates the stops in order, so track the last generated one to prevent\n // floating point precision from making us go the teeniest bit backwards, resulting in\n // the first and last colors getting swapped.\n var lastIterationStop = 0;\n // Actual height of the text itself, not counting spacing for lineHeight/leading/dropShadow etc\n var textHeight = metrics.fontProperties.fontSize + style.strokeThickness;\n // textHeight, but as a 0-1 size in global gradient stop space\n var gradStopLineHeight = textHeight / height;\n for (var i = 0; i < lines.length; i++) {\n var thisLineTop = metrics.lineHeight * i;\n for (var j = 0; j < fill.length; j++) {\n // 0-1 stop point for the current line, multiplied to global space afterwards\n var lineStop = 0;\n if (typeof fillGradientStops[j] === 'number') {\n lineStop = fillGradientStops[j];\n }\n else {\n lineStop = j / fill.length;\n }\n var globalStop = (thisLineTop / height) + (lineStop * gradStopLineHeight);\n // Prevent color stop generation going backwards from floating point imprecision\n var clampedStop = Math.max(lastIterationStop, globalStop);\n clampedStop = Math.min(clampedStop, 1); // Cap at 1 as well for safety's sake to avoid a possible throw.\n gradient.addColorStop(clampedStop, fill[j]);\n lastIterationStop = clampedStop;\n }\n }\n }\n else {\n // start the gradient at the center left of the canvas, and end at the center right of the canvas\n gradient = context.createLinearGradient(padding, height / 2, width + padding, height / 2);\n // can just evenly space out the gradients in this case, as multiple lines makes no difference\n // to an even left to right gradient\n var totalIterations = fill.length + 1;\n var currentIteration = 1;\n for (var i = 0; i < fill.length; i++) {\n var stop = void 0;\n if (typeof fillGradientStops[i] === 'number') {\n stop = fillGradientStops[i];\n }\n else {\n stop = currentIteration / totalIterations;\n }\n gradient.addColorStop(stop, fill[i]);\n currentIteration++;\n }\n }\n return gradient;\n}\n\n// TODO: Prevent code duplication b/w drawGlyph & Text#updateText\n/**\n * Draws the glyph `metrics.text` on the given canvas.\n *\n * Ignored because not directly exposed.\n *\n * @ignore\n * @param {HTMLCanvasElement} canvas\n * @param {CanvasRenderingContext2D} context\n * @param {TextMetrics} metrics\n * @param {number} x\n * @param {number} y\n * @param {number} resolution\n * @param {TextStyle} style\n */\nfunction drawGlyph(canvas, context, metrics, x, y, resolution, style) {\n var char = metrics.text;\n var fontProperties = metrics.fontProperties;\n context.translate(x, y);\n context.scale(resolution, resolution);\n var tx = style.strokeThickness / 2;\n var ty = -(style.strokeThickness / 2);\n context.font = style.toFontString();\n context.lineWidth = style.strokeThickness;\n context.textBaseline = style.textBaseline;\n context.lineJoin = style.lineJoin;\n context.miterLimit = style.miterLimit;\n // set canvas text styles\n context.fillStyle = generateFillStyle(canvas, context, style, resolution, [char], metrics);\n context.strokeStyle = style.stroke;\n if (style.dropShadow) {\n var dropShadowColor = style.dropShadowColor;\n var rgb = hex2rgb(typeof dropShadowColor === 'number' ? dropShadowColor : string2hex(dropShadowColor));\n var dropShadowBlur = style.dropShadowBlur * resolution;\n var dropShadowDistance = style.dropShadowDistance * resolution;\n context.shadowColor = \"rgba(\" + rgb[0] * 255 + \",\" + rgb[1] * 255 + \",\" + rgb[2] * 255 + \",\" + style.dropShadowAlpha + \")\";\n context.shadowBlur = dropShadowBlur;\n context.shadowOffsetX = Math.cos(style.dropShadowAngle) * dropShadowDistance;\n context.shadowOffsetY = Math.sin(style.dropShadowAngle) * dropShadowDistance;\n }\n else {\n context.shadowColor = 'black';\n context.shadowBlur = 0;\n context.shadowOffsetX = 0;\n context.shadowOffsetY = 0;\n }\n if (style.stroke && style.strokeThickness) {\n context.strokeText(char, tx, ty + metrics.lineHeight - fontProperties.descent);\n }\n if (style.fill) {\n context.fillText(char, tx, ty + metrics.lineHeight - fontProperties.descent);\n }\n context.setTransform(1, 0, 0, 1, 0, 0); // defaults needed for older browsers (e.g. Opera 29)\n context.fillStyle = 'rgba(0, 0, 0, 0)';\n}\n\n/**\n * Ponyfill for IE because it doesn't support `Array.from`\n * @private\n */\nfunction splitTextToCharacters(text) {\n return Array.from ? Array.from(text) : text.split('');\n}\n\n/**\n * Processes the passed character set data and returns a flattened array of all the characters.\n *\n * Ignored because not directly exposed.\n *\n * @ignore\n * @param {string | string[] | string[][] } chars\n * @returns {string[]}\n */\nfunction resolveCharacters(chars) {\n // Split the chars string into individual characters\n if (typeof chars === 'string') {\n chars = [chars];\n }\n // Handle an array of characters+ranges\n var result = [];\n for (var i = 0, j = chars.length; i < j; i++) {\n var item = chars[i];\n // Handle range delimited by start/end chars\n if (Array.isArray(item)) {\n if (item.length !== 2) {\n throw new Error(\"[BitmapFont]: Invalid character range length, expecting 2 got \" + item.length + \".\");\n }\n var startCode = item[0].charCodeAt(0);\n var endCode = item[1].charCodeAt(0);\n if (endCode < startCode) {\n throw new Error('[BitmapFont]: Invalid character range.');\n }\n for (var i_1 = startCode, j_1 = endCode; i_1 <= j_1; i_1++) {\n result.push(String.fromCharCode(i_1));\n }\n }\n // Handle a character set string\n else {\n result.push.apply(result, splitTextToCharacters(item));\n }\n }\n if (result.length === 0) {\n throw new Error('[BitmapFont]: Empty set when resolving characters.');\n }\n return result;\n}\n\n/**\n * Ponyfill for IE because it doesn't support `codePointAt`\n * @private\n */\nfunction extractCharCode(str) {\n return str.codePointAt ? str.codePointAt(0) : str.charCodeAt(0);\n}\n\n/**\n * BitmapFont represents a typeface available for use with the BitmapText class. Use the `install`\n * method for adding a font to be used.\n *\n * @memberof PIXI\n */\nvar BitmapFont = /** @class */ (function () {\n /**\n * @param data\n * @param textures\n * @param ownsTextures - Setting to `true` will destroy page textures\n * when the font is uninstalled.\n */\n function BitmapFont(data, textures, ownsTextures) {\n var _a, _b;\n var info = data.info[0];\n var common = data.common[0];\n var page = data.page[0];\n var distanceField = data.distanceField[0];\n var res = getResolutionOfUrl(page.file);\n var pageTextures = {};\n this._ownsTextures = ownsTextures;\n this.font = info.face;\n this.size = info.size;\n this.lineHeight = common.lineHeight / res;\n this.chars = {};\n this.pageTextures = pageTextures;\n // Convert the input Texture, Textures or object\n // into a page Texture lookup by \"id\"\n for (var i = 0; i < data.page.length; i++) {\n var _c = data.page[i], id = _c.id, file = _c.file;\n pageTextures[id] = textures instanceof Array\n ? textures[i] : textures[file];\n // only MSDF and SDF fonts need no-premultiplied-alpha\n if ((distanceField === null || distanceField === void 0 ? void 0 : distanceField.fieldType) && distanceField.fieldType !== 'none') {\n pageTextures[id].baseTexture.alphaMode = ALPHA_MODES.NO_PREMULTIPLIED_ALPHA;\n }\n }\n // parse letters\n for (var i = 0; i < data.char.length; i++) {\n var _d = data.char[i], id = _d.id, page_1 = _d.page;\n var _e = data.char[i], x = _e.x, y = _e.y, width = _e.width, height = _e.height, xoffset = _e.xoffset, yoffset = _e.yoffset, xadvance = _e.xadvance;\n x /= res;\n y /= res;\n width /= res;\n height /= res;\n xoffset /= res;\n yoffset /= res;\n xadvance /= res;\n var rect = new Rectangle(x + (pageTextures[page_1].frame.x / res), y + (pageTextures[page_1].frame.y / res), width, height);\n this.chars[id] = {\n xOffset: xoffset,\n yOffset: yoffset,\n xAdvance: xadvance,\n kerning: {},\n texture: new Texture(pageTextures[page_1].baseTexture, rect),\n page: page_1,\n };\n }\n // parse kernings\n for (var i = 0; i < data.kerning.length; i++) {\n var _f = data.kerning[i], first = _f.first, second = _f.second, amount = _f.amount;\n first /= res;\n second /= res;\n amount /= res;\n if (this.chars[second]) {\n this.chars[second].kerning[first] = amount;\n }\n }\n // Store distance field information\n this.distanceFieldRange = distanceField === null || distanceField === void 0 ? void 0 : distanceField.distanceRange;\n this.distanceFieldType = (_b = (_a = distanceField === null || distanceField === void 0 ? void 0 : distanceField.fieldType) === null || _a === void 0 ? void 0 : _a.toLowerCase()) !== null && _b !== void 0 ? _b : 'none';\n }\n /** Remove references to created glyph textures. */\n BitmapFont.prototype.destroy = function () {\n for (var id in this.chars) {\n this.chars[id].texture.destroy();\n this.chars[id].texture = null;\n }\n for (var id in this.pageTextures) {\n if (this._ownsTextures) {\n this.pageTextures[id].destroy(true);\n }\n this.pageTextures[id] = null;\n }\n // Set readonly null.\n this.chars = null;\n this.pageTextures = null;\n };\n /**\n * Register a new bitmap font.\n *\n * @param data - The\n * characters map that could be provided as xml or raw string.\n * @param textures - List of textures for each page.\n * @param ownsTextures - Set to `true` to destroy page textures\n * when the font is uninstalled. By default fonts created with\n * `BitmapFont.from` or from the `BitmapFontLoader` are `true`.\n * @return {PIXI.BitmapFont} Result font object with font, size, lineHeight\n * and char fields.\n */\n BitmapFont.install = function (data, textures, ownsTextures) {\n var fontData;\n if (data instanceof BitmapFontData) {\n fontData = data;\n }\n else {\n var format = autoDetectFormat(data);\n if (!format) {\n throw new Error('Unrecognized data format for font.');\n }\n fontData = format.parse(data);\n }\n // Single texture, convert to list\n if (textures instanceof Texture) {\n textures = [textures];\n }\n var font = new BitmapFont(fontData, textures, ownsTextures);\n BitmapFont.available[font.font] = font;\n return font;\n };\n /**\n * Remove bitmap font by name.\n *\n * @param name - Name of the font to uninstall.\n */\n BitmapFont.uninstall = function (name) {\n var font = BitmapFont.available[name];\n if (!font) {\n throw new Error(\"No font found named '\" + name + \"'\");\n }\n font.destroy();\n delete BitmapFont.available[name];\n };\n /**\n * Generates a bitmap-font for the given style and character set. This does not support\n * kernings yet. With `style` properties, only the following non-layout properties are used:\n *\n * - {@link PIXI.TextStyle#dropShadow|dropShadow}\n * - {@link PIXI.TextStyle#dropShadowDistance|dropShadowDistance}\n * - {@link PIXI.TextStyle#dropShadowColor|dropShadowColor}\n * - {@link PIXI.TextStyle#dropShadowBlur|dropShadowBlur}\n * - {@link PIXI.TextStyle#dropShadowAngle|dropShadowAngle}\n * - {@link PIXI.TextStyle#fill|fill}\n * - {@link PIXI.TextStyle#fillGradientStops|fillGradientStops}\n * - {@link PIXI.TextStyle#fillGradientType|fillGradientType}\n * - {@link PIXI.TextStyle#fontFamily|fontFamily}\n * - {@link PIXI.TextStyle#fontSize|fontSize}\n * - {@link PIXI.TextStyle#fontVariant|fontVariant}\n * - {@link PIXI.TextStyle#fontWeight|fontWeight}\n * - {@link PIXI.TextStyle#lineJoin|lineJoin}\n * - {@link PIXI.TextStyle#miterLimit|miterLimit}\n * - {@link PIXI.TextStyle#stroke|stroke}\n * - {@link PIXI.TextStyle#strokeThickness|strokeThickness}\n * - {@link PIXI.TextStyle#textBaseline|textBaseline}\n *\n * @param name - The name of the custom font to use with BitmapText.\n * @param style - Style options to render with BitmapFont.\n * @param options - Setup options for font or name of the font.\n * @param {string|string[]|string[][]} [options.chars=PIXI.BitmapFont.ALPHANUMERIC] - characters included\n * in the font set. You can also use ranges. For example, `[['a', 'z'], ['A', 'Z'], \"!@#$%^&*()~{}[] \"]`.\n * Don't forget to include spaces ' ' in your character set!\n * @param {number} [options.resolution=1] - Render resolution for glyphs.\n * @param {number} [options.textureWidth=512] - Optional width of atlas, smaller values to reduce memory.\n * @param {number} [options.textureHeight=512] - Optional height of atlas, smaller values to reduce memory.\n * @param {number} [options.padding=4] - Padding between glyphs on texture atlas.\n * @return Font generated by style options.\n * @example\n * PIXI.BitmapFont.from(\"TitleFont\", {\n * fontFamily: \"Arial\",\n * fontSize: 12,\n * strokeThickness: 2,\n * fill: \"purple\"\n * });\n *\n * const title = new PIXI.BitmapText(\"This is the title\", { fontName: \"TitleFont\" });\n */\n BitmapFont.from = function (name, textStyle, options) {\n if (!name) {\n throw new Error('[BitmapFont] Property `name` is required.');\n }\n var _a = Object.assign({}, BitmapFont.defaultOptions, options), chars = _a.chars, padding = _a.padding, resolution = _a.resolution, textureWidth = _a.textureWidth, textureHeight = _a.textureHeight;\n var charsList = resolveCharacters(chars);\n var style = textStyle instanceof TextStyle ? textStyle : new TextStyle(textStyle);\n var lineWidth = textureWidth;\n var fontData = new BitmapFontData();\n fontData.info[0] = {\n face: style.fontFamily,\n size: style.fontSize,\n };\n fontData.common[0] = {\n lineHeight: style.fontSize,\n };\n var positionX = 0;\n var positionY = 0;\n var canvas;\n var context;\n var baseTexture;\n var maxCharHeight = 0;\n var textures = [];\n for (var i = 0; i < charsList.length; i++) {\n if (!canvas) {\n canvas = document.createElement('canvas');\n canvas.width = textureWidth;\n canvas.height = textureHeight;\n context = canvas.getContext('2d');\n baseTexture = new BaseTexture(canvas, { resolution: resolution });\n textures.push(new Texture(baseTexture));\n fontData.page.push({\n id: textures.length - 1,\n file: '',\n });\n }\n // Measure glyph dimensions\n var metrics = TextMetrics.measureText(charsList[i], style, false, canvas);\n var width = metrics.width;\n var height = Math.ceil(metrics.height);\n // This is ugly - but italics are given more space so they don't overlap\n var textureGlyphWidth = Math.ceil((style.fontStyle === 'italic' ? 2 : 1) * width);\n // Can't fit char anymore: next canvas please!\n if (positionY >= textureHeight - (height * resolution)) {\n if (positionY === 0) {\n // We don't want user debugging an infinite loop (or do we? :)\n throw new Error(\"[BitmapFont] textureHeight \" + textureHeight + \"px is \"\n + (\"too small for \" + style.fontSize + \"px fonts\"));\n }\n --i;\n // Create new atlas once current has filled up\n canvas = null;\n context = null;\n baseTexture = null;\n positionY = 0;\n positionX = 0;\n maxCharHeight = 0;\n continue;\n }\n maxCharHeight = Math.max(height + metrics.fontProperties.descent, maxCharHeight);\n // Wrap line once full row has been rendered\n if ((textureGlyphWidth * resolution) + positionX >= lineWidth) {\n --i;\n positionY += maxCharHeight * resolution;\n positionY = Math.ceil(positionY);\n positionX = 0;\n maxCharHeight = 0;\n continue;\n }\n drawGlyph(canvas, context, metrics, positionX, positionY, resolution, style);\n // Unique (numeric) ID mapping to this glyph\n var id = extractCharCode(metrics.text);\n // Create a texture holding just the glyph\n fontData.char.push({\n id: id,\n page: textures.length - 1,\n x: positionX / resolution,\n y: positionY / resolution,\n width: textureGlyphWidth,\n height: height,\n xoffset: 0,\n yoffset: 0,\n xadvance: Math.ceil(width\n - (style.dropShadow ? style.dropShadowDistance : 0)\n - (style.stroke ? style.strokeThickness : 0)),\n });\n positionX += (textureGlyphWidth + (2 * padding)) * resolution;\n positionX = Math.ceil(positionX);\n }\n // Brute-force kerning info, this can be expensive b/c it's an O(n²),\n // but we're using measureText which is native and fast.\n for (var i = 0, len = charsList.length; i < len; i++) {\n var first = charsList[i];\n for (var j = 0; j < len; j++) {\n var second = charsList[j];\n var c1 = context.measureText(first).width;\n var c2 = context.measureText(second).width;\n var total = context.measureText(first + second).width;\n var amount = total - (c1 + c2);\n if (amount) {\n fontData.kerning.push({\n first: extractCharCode(first),\n second: extractCharCode(second),\n amount: amount,\n });\n }\n }\n }\n var font = new BitmapFont(fontData, textures, true);\n // Make it easier to replace a font\n if (BitmapFont.available[name] !== undefined) {\n BitmapFont.uninstall(name);\n }\n BitmapFont.available[name] = font;\n return font;\n };\n /**\n * This character set includes all the letters in the alphabet (both lower- and upper- case).\n *\n * @type {string[][]}\n * @example\n * BitmapFont.from(\"ExampleFont\", style, { chars: BitmapFont.ALPHA })\n */\n BitmapFont.ALPHA = [['a', 'z'], ['A', 'Z'], ' '];\n /**\n * This character set includes all decimal digits (from 0 to 9).\n *\n * @type {string[][]}\n * @example\n * BitmapFont.from(\"ExampleFont\", style, { chars: BitmapFont.NUMERIC })\n */\n BitmapFont.NUMERIC = [['0', '9']];\n /**\n * This character set is the union of `BitmapFont.ALPHA` and `BitmapFont.NUMERIC`.\n *\n * @type {string[][]}\n */\n BitmapFont.ALPHANUMERIC = [['a', 'z'], ['A', 'Z'], ['0', '9'], ' '];\n /**\n * This character set consists of all the ASCII table.\n *\n * @member {string[][]}\n * @see http://www.asciitable.com/\n */\n BitmapFont.ASCII = [[' ', '~']];\n /**\n * Collection of default options when using `BitmapFont.from`.\n *\n * @property {number} resolution=1\n * @property {number} textureWidth=512\n * @property {number} textureHeight=512\n * @property {number} padding=4\n * @property {string|string[]|string[][]} chars = PIXI.BitmapFont.ALPHANUMERIC\n */\n BitmapFont.defaultOptions = {\n resolution: 1,\n textureWidth: 512,\n textureHeight: 512,\n padding: 4,\n chars: BitmapFont.ALPHANUMERIC,\n };\n /** Collection of available/installed fonts. */\n BitmapFont.available = {};\n return BitmapFont;\n}());\n\nvar msdfFrag = \"// Pixi texture info\\r\\nvarying vec2 vTextureCoord;\\r\\nuniform sampler2D uSampler;\\r\\n\\r\\n// Tint\\r\\nuniform vec4 uColor;\\r\\n\\r\\n// on 2D applications fwidth is screenScale / glyphAtlasScale * distanceFieldRange\\r\\nuniform float uFWidth;\\r\\n\\r\\nvoid main(void) {\\r\\n\\r\\n // To stack MSDF and SDF we need a non-pre-multiplied-alpha texture.\\r\\n vec4 texColor = texture2D(uSampler, vTextureCoord);\\r\\n\\r\\n // MSDF\\r\\n float median = texColor.r + texColor.g + texColor.b -\\r\\n min(texColor.r, min(texColor.g, texColor.b)) -\\r\\n max(texColor.r, max(texColor.g, texColor.b));\\r\\n // SDF\\r\\n median = min(median, texColor.a);\\r\\n\\r\\n float screenPxDistance = uFWidth * (median - 0.5);\\r\\n float alpha = clamp(screenPxDistance + 0.5, 0.0, 1.0);\\r\\n\\r\\n // NPM Textures, NPM outputs\\r\\n gl_FragColor = vec4(uColor.rgb, uColor.a * alpha);\\r\\n\\r\\n}\\r\\n\";\n\nvar msdfVert = \"// Mesh material default fragment\\r\\nattribute vec2 aVertexPosition;\\r\\nattribute vec2 aTextureCoord;\\r\\n\\r\\nuniform mat3 projectionMatrix;\\r\\nuniform mat3 translationMatrix;\\r\\nuniform mat3 uTextureMatrix;\\r\\n\\r\\nvarying vec2 vTextureCoord;\\r\\n\\r\\nvoid main(void)\\r\\n{\\r\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\r\\n\\r\\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\\r\\n}\\r\\n\";\n\n// If we ever need more than two pools, please make a Dict or something better.\nvar pageMeshDataDefaultPageMeshData = [];\nvar pageMeshDataMSDFPageMeshData = [];\nvar charRenderDataPool = [];\n/**\n * A BitmapText object will create a line or multiple lines of text using bitmap font.\n *\n * The primary advantage of this class over Text is that all of your textures are pre-generated and loading,\n * meaning that rendering is fast, and changing text has no performance implications.\n *\n * Supporting character sets other than latin, such as CJK languages, may be impractical due to the number of characters.\n *\n * To split a line you can use '\\n', '\\r' or '\\r\\n' in your string.\n *\n * PixiJS can auto-generate fonts on-the-fly using BitmapFont or use fnt files provided by:\n * http://www.angelcode.com/products/bmfont/ for Windows or\n * http://www.bmglyph.com/ for Mac.\n *\n * You can also use SDF, MSDF and MTSDF BitmapFonts for vector-like scaling appearance provided by:\n * https://github.com/soimy/msdf-bmfont-xml for SDF and MSDF fnt files or\n * https://github.com/Chlumsky/msdf-atlas-gen for SDF, MSDF and MTSDF json files\n *\n * A BitmapText can only be created when the font is loaded.\n *\n * ```js\n * // in this case the font is in a file called 'desyrel.fnt'\n * let bitmapText = new PIXI.BitmapText(\"text using a fancy font!\", {\n * fontName: \"Desyrel\",\n * fontSize: 35,\n * align: \"right\"\n * });\n * ```\n *\n * @memberof PIXI\n */\nvar BitmapText = /** @class */ (function (_super) {\n __extends(BitmapText, _super);\n /**\n * @param text - A string that you would like the text to display.\n * @param style - The style parameters.\n * @param {string} style.fontName - The installed BitmapFont name.\n * @param {number} [style.fontSize] - The size of the font in pixels, e.g. 24. If undefined,\n *. this will default to the BitmapFont size.\n * @param {string} [style.align='left'] - Alignment for multiline text ('left', 'center', 'right' or 'justify'),\n * does not affect single line text.\n * @param {number} [style.tint=0xFFFFFF] - The tint color.\n * @param {number} [style.letterSpacing=0] - The amount of spacing between letters.\n * @param {number} [style.maxWidth=0] - The max width of the text before line wrapping.\n */\n function BitmapText(text, style) {\n if (style === void 0) { style = {}; }\n var _this = _super.call(this) || this;\n /**\n * Private tracker for the current tint.\n *\n * @private\n */\n _this._tint = 0xFFFFFF;\n // Apply the defaults\n var _a = Object.assign({}, BitmapText.styleDefaults, style), align = _a.align, tint = _a.tint, maxWidth = _a.maxWidth, letterSpacing = _a.letterSpacing, fontName = _a.fontName, fontSize = _a.fontSize;\n if (!BitmapFont.available[fontName]) {\n throw new Error(\"Missing BitmapFont \\\"\" + fontName + \"\\\"\");\n }\n _this._activePagesMeshData = [];\n _this._textWidth = 0;\n _this._textHeight = 0;\n _this._align = align;\n _this._tint = tint;\n _this._fontName = fontName;\n _this._fontSize = fontSize || BitmapFont.available[fontName].size;\n _this._text = text;\n _this._maxWidth = maxWidth;\n _this._maxLineHeight = 0;\n _this._letterSpacing = letterSpacing;\n _this._anchor = new ObservablePoint(function () { _this.dirty = true; }, _this, 0, 0);\n _this._roundPixels = settings.ROUND_PIXELS;\n _this.dirty = true;\n _this._textureCache = {};\n return _this;\n }\n /**\n * Renders text and updates it when needed. This should only be called\n * if the BitmapFont is regenerated.\n */\n BitmapText.prototype.updateText = function () {\n var _a;\n var data = BitmapFont.available[this._fontName];\n var scale = this._fontSize / data.size;\n var pos = new Point();\n var chars = [];\n var lineWidths = [];\n var lineSpaces = [];\n var text = this._text.replace(/(?:\\r\\n|\\r)/g, '\\n') || ' ';\n var charsInput = splitTextToCharacters(text);\n var maxWidth = this._maxWidth * data.size / this._fontSize;\n var pageMeshDataPool = data.distanceFieldType === 'none'\n ? pageMeshDataDefaultPageMeshData : pageMeshDataMSDFPageMeshData;\n var prevCharCode = null;\n var lastLineWidth = 0;\n var maxLineWidth = 0;\n var line = 0;\n var lastBreakPos = -1;\n var lastBreakWidth = 0;\n var spacesRemoved = 0;\n var maxLineHeight = 0;\n var spaceCount = 0;\n for (var i = 0; i < charsInput.length; i++) {\n var char = charsInput[i];\n var charCode = extractCharCode(char);\n if ((/(?:\\s)/).test(char)) {\n lastBreakPos = i;\n lastBreakWidth = lastLineWidth;\n spaceCount++;\n }\n if (char === '\\r' || char === '\\n') {\n lineWidths.push(lastLineWidth);\n lineSpaces.push(-1);\n maxLineWidth = Math.max(maxLineWidth, lastLineWidth);\n ++line;\n ++spacesRemoved;\n pos.x = 0;\n pos.y += data.lineHeight;\n prevCharCode = null;\n spaceCount = 0;\n continue;\n }\n var charData = data.chars[charCode];\n if (!charData) {\n continue;\n }\n if (prevCharCode && charData.kerning[prevCharCode]) {\n pos.x += charData.kerning[prevCharCode];\n }\n var charRenderData = charRenderDataPool.pop() || {\n texture: Texture.EMPTY,\n line: 0,\n charCode: 0,\n prevSpaces: 0,\n position: new Point(),\n };\n charRenderData.texture = charData.texture;\n charRenderData.line = line;\n charRenderData.charCode = charCode;\n charRenderData.position.x = pos.x + charData.xOffset + (this._letterSpacing / 2);\n charRenderData.position.y = pos.y + charData.yOffset;\n charRenderData.prevSpaces = spaceCount;\n chars.push(charRenderData);\n lastLineWidth = charRenderData.position.x + Math.max(charData.xAdvance, charData.texture.orig.width);\n pos.x += charData.xAdvance + this._letterSpacing;\n maxLineHeight = Math.max(maxLineHeight, (charData.yOffset + charData.texture.height));\n prevCharCode = charCode;\n if (lastBreakPos !== -1 && maxWidth > 0 && pos.x > maxWidth) {\n ++spacesRemoved;\n removeItems(chars, 1 + lastBreakPos - spacesRemoved, 1 + i - lastBreakPos);\n i = lastBreakPos;\n lastBreakPos = -1;\n lineWidths.push(lastBreakWidth);\n lineSpaces.push(chars.length > 0 ? chars[chars.length - 1].prevSpaces : 0);\n maxLineWidth = Math.max(maxLineWidth, lastBreakWidth);\n line++;\n pos.x = 0;\n pos.y += data.lineHeight;\n prevCharCode = null;\n spaceCount = 0;\n }\n }\n var lastChar = charsInput[charsInput.length - 1];\n if (lastChar !== '\\r' && lastChar !== '\\n') {\n if ((/(?:\\s)/).test(lastChar)) {\n lastLineWidth = lastBreakWidth;\n }\n lineWidths.push(lastLineWidth);\n maxLineWidth = Math.max(maxLineWidth, lastLineWidth);\n lineSpaces.push(-1);\n }\n var lineAlignOffsets = [];\n for (var i = 0; i <= line; i++) {\n var alignOffset = 0;\n if (this._align === 'right') {\n alignOffset = maxLineWidth - lineWidths[i];\n }\n else if (this._align === 'center') {\n alignOffset = (maxLineWidth - lineWidths[i]) / 2;\n }\n else if (this._align === 'justify') {\n alignOffset = lineSpaces[i] < 0 ? 0 : (maxLineWidth - lineWidths[i]) / lineSpaces[i];\n }\n lineAlignOffsets.push(alignOffset);\n }\n var lenChars = chars.length;\n var pagesMeshData = {};\n var newPagesMeshData = [];\n var activePagesMeshData = this._activePagesMeshData;\n for (var i = 0; i < activePagesMeshData.length; i++) {\n pageMeshDataPool.push(activePagesMeshData[i]);\n }\n for (var i = 0; i < lenChars; i++) {\n var texture = chars[i].texture;\n var baseTextureUid = texture.baseTexture.uid;\n if (!pagesMeshData[baseTextureUid]) {\n var pageMeshData = pageMeshDataPool.pop();\n if (!pageMeshData) {\n var geometry = new MeshGeometry();\n var material = void 0;\n var meshBlendMode = void 0;\n if (data.distanceFieldType === 'none') {\n material = new MeshMaterial(Texture.EMPTY);\n meshBlendMode = BLEND_MODES.NORMAL;\n }\n else {\n material = new MeshMaterial(Texture.EMPTY, { program: Program.from(msdfVert, msdfFrag), uniforms: { uFWidth: 0 } });\n meshBlendMode = BLEND_MODES.NORMAL_NPM;\n }\n var mesh = new Mesh(geometry, material);\n mesh.blendMode = meshBlendMode;\n pageMeshData = {\n index: 0,\n indexCount: 0,\n vertexCount: 0,\n uvsCount: 0,\n total: 0,\n mesh: mesh,\n vertices: null,\n uvs: null,\n indices: null,\n };\n }\n // reset data..\n pageMeshData.index = 0;\n pageMeshData.indexCount = 0;\n pageMeshData.vertexCount = 0;\n pageMeshData.uvsCount = 0;\n pageMeshData.total = 0;\n // TODO need to get page texture here somehow..\n var _textureCache = this._textureCache;\n _textureCache[baseTextureUid] = _textureCache[baseTextureUid] || new Texture(texture.baseTexture);\n pageMeshData.mesh.texture = _textureCache[baseTextureUid];\n pageMeshData.mesh.tint = this._tint;\n newPagesMeshData.push(pageMeshData);\n pagesMeshData[baseTextureUid] = pageMeshData;\n }\n pagesMeshData[baseTextureUid].total++;\n }\n // lets find any previously active pageMeshDatas that are no longer required for\n // the updated text (if any), removed and return them to the pool.\n for (var i = 0; i < activePagesMeshData.length; i++) {\n if (newPagesMeshData.indexOf(activePagesMeshData[i]) === -1) {\n this.removeChild(activePagesMeshData[i].mesh);\n }\n }\n // next lets add any new meshes, that have not yet been added to this BitmapText\n // we only add if its not already a child of this BitmapObject\n for (var i = 0; i < newPagesMeshData.length; i++) {\n if (newPagesMeshData[i].mesh.parent !== this) {\n this.addChild(newPagesMeshData[i].mesh);\n }\n }\n // active page mesh datas are set to be the new pages added.\n this._activePagesMeshData = newPagesMeshData;\n for (var i in pagesMeshData) {\n var pageMeshData = pagesMeshData[i];\n var total = pageMeshData.total;\n // lets only allocate new buffers if we can fit the new text in the current ones..\n // unless that is, we will be batching. Currently batching dose not respect the size property of mesh\n if (!(((_a = pageMeshData.indices) === null || _a === void 0 ? void 0 : _a.length) > 6 * total) || pageMeshData.vertices.length < Mesh.BATCHABLE_SIZE * 2) {\n pageMeshData.vertices = new Float32Array(4 * 2 * total);\n pageMeshData.uvs = new Float32Array(4 * 2 * total);\n pageMeshData.indices = new Uint16Array(6 * total);\n }\n else {\n var total_1 = pageMeshData.total;\n var vertices = pageMeshData.vertices;\n // Clear the garbage at the end of the vertices buffer. This will prevent the bounds miscalculation.\n for (var i_1 = total_1 * 4 * 2; i_1 < vertices.length; i_1++) {\n vertices[i_1] = 0;\n }\n }\n // as a buffer maybe bigger than the current word, we set the size of the meshMaterial\n // to match the number of letters needed\n pageMeshData.mesh.size = 6 * total;\n }\n for (var i = 0; i < lenChars; i++) {\n var char = chars[i];\n var offset = char.position.x + (lineAlignOffsets[char.line] * (this._align === 'justify' ? char.prevSpaces : 1));\n if (this._roundPixels) {\n offset = Math.round(offset);\n }\n var xPos = offset * scale;\n var yPos = char.position.y * scale;\n var texture = char.texture;\n var pageMesh = pagesMeshData[texture.baseTexture.uid];\n var textureFrame = texture.frame;\n var textureUvs = texture._uvs;\n var index = pageMesh.index++;\n pageMesh.indices[(index * 6) + 0] = 0 + (index * 4);\n pageMesh.indices[(index * 6) + 1] = 1 + (index * 4);\n pageMesh.indices[(index * 6) + 2] = 2 + (index * 4);\n pageMesh.indices[(index * 6) + 3] = 0 + (index * 4);\n pageMesh.indices[(index * 6) + 4] = 2 + (index * 4);\n pageMesh.indices[(index * 6) + 5] = 3 + (index * 4);\n pageMesh.vertices[(index * 8) + 0] = xPos;\n pageMesh.vertices[(index * 8) + 1] = yPos;\n pageMesh.vertices[(index * 8) + 2] = xPos + (textureFrame.width * scale);\n pageMesh.vertices[(index * 8) + 3] = yPos;\n pageMesh.vertices[(index * 8) + 4] = xPos + (textureFrame.width * scale);\n pageMesh.vertices[(index * 8) + 5] = yPos + (textureFrame.height * scale);\n pageMesh.vertices[(index * 8) + 6] = xPos;\n pageMesh.vertices[(index * 8) + 7] = yPos + (textureFrame.height * scale);\n pageMesh.uvs[(index * 8) + 0] = textureUvs.x0;\n pageMesh.uvs[(index * 8) + 1] = textureUvs.y0;\n pageMesh.uvs[(index * 8) + 2] = textureUvs.x1;\n pageMesh.uvs[(index * 8) + 3] = textureUvs.y1;\n pageMesh.uvs[(index * 8) + 4] = textureUvs.x2;\n pageMesh.uvs[(index * 8) + 5] = textureUvs.y2;\n pageMesh.uvs[(index * 8) + 6] = textureUvs.x3;\n pageMesh.uvs[(index * 8) + 7] = textureUvs.y3;\n }\n this._textWidth = maxLineWidth * scale;\n this._textHeight = (pos.y + data.lineHeight) * scale;\n for (var i in pagesMeshData) {\n var pageMeshData = pagesMeshData[i];\n // apply anchor\n if (this.anchor.x !== 0 || this.anchor.y !== 0) {\n var vertexCount = 0;\n var anchorOffsetX = this._textWidth * this.anchor.x;\n var anchorOffsetY = this._textHeight * this.anchor.y;\n for (var i_2 = 0; i_2 < pageMeshData.total; i_2++) {\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n }\n }\n this._maxLineHeight = maxLineHeight * scale;\n var vertexBuffer = pageMeshData.mesh.geometry.getBuffer('aVertexPosition');\n var textureBuffer = pageMeshData.mesh.geometry.getBuffer('aTextureCoord');\n var indexBuffer = pageMeshData.mesh.geometry.getIndex();\n vertexBuffer.data = pageMeshData.vertices;\n textureBuffer.data = pageMeshData.uvs;\n indexBuffer.data = pageMeshData.indices;\n vertexBuffer.update();\n textureBuffer.update();\n indexBuffer.update();\n }\n for (var i = 0; i < chars.length; i++) {\n charRenderDataPool.push(chars[i]);\n }\n };\n BitmapText.prototype.updateTransform = function () {\n this.validate();\n this.containerUpdateTransform();\n };\n BitmapText.prototype._render = function (renderer) {\n // Update the uniform\n var _a = BitmapFont.available[this._fontName], distanceFieldRange = _a.distanceFieldRange, distanceFieldType = _a.distanceFieldType, size = _a.size;\n if (distanceFieldType !== 'none') {\n // Inject the shader code with the correct value\n var _b = this.worldTransform, a = _b.a, b = _b.b, c = _b.c, d = _b.d;\n var dx = Math.sqrt((a * a) + (b * b));\n var dy = Math.sqrt((c * c) + (d * d));\n var worldScale = (Math.abs(dx) + Math.abs(dy)) / 2;\n var fontScale = this._fontSize / size;\n for (var _i = 0, _c = this._activePagesMeshData; _i < _c.length; _i++) {\n var mesh = _c[_i];\n mesh.mesh.shader.uniforms.uFWidth = worldScale * distanceFieldRange * fontScale * renderer.resolution;\n }\n }\n _super.prototype._render.call(this, renderer);\n };\n /**\n * Validates text before calling parent's getLocalBounds\n *\n * @return - The rectangular bounding area\n */\n BitmapText.prototype.getLocalBounds = function () {\n this.validate();\n return _super.prototype.getLocalBounds.call(this);\n };\n /**\n * Updates text when needed\n *\n * @private\n */\n BitmapText.prototype.validate = function () {\n if (this.dirty) {\n this.updateText();\n this.dirty = false;\n }\n };\n Object.defineProperty(BitmapText.prototype, \"tint\", {\n /**\n * The tint of the BitmapText object.\n *\n * @default 0xffffff\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n if (this._tint === value)\n { return; }\n this._tint = value;\n for (var i = 0; i < this._activePagesMeshData.length; i++) {\n this._activePagesMeshData[i].mesh.tint = value;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"align\", {\n /**\n * The alignment of the BitmapText object.\n *\n * @member {string}\n * @default 'left'\n */\n get: function () {\n return this._align;\n },\n set: function (value) {\n if (this._align !== value) {\n this._align = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"fontName\", {\n /** The name of the BitmapFont. */\n get: function () {\n return this._fontName;\n },\n set: function (value) {\n if (!BitmapFont.available[value]) {\n throw new Error(\"Missing BitmapFont \\\"\" + value + \"\\\"\");\n }\n if (this._fontName !== value) {\n this._fontName = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"fontSize\", {\n /** The size of the font to display. */\n get: function () {\n return this._fontSize;\n },\n set: function (value) {\n if (this._fontSize !== value) {\n this._fontSize = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"anchor\", {\n /**\n * The anchor sets the origin point of the text.\n *\n * The default is `(0,0)`, this means the text's origin is the top left.\n *\n * Setting the anchor to `(0.5,0.5)` means the text's origin is centered.\n *\n * Setting the anchor to `(1,1)` would mean the text's origin point will be the bottom right corner.\n */\n get: function () {\n return this._anchor;\n },\n set: function (value) {\n if (typeof value === 'number') {\n this._anchor.set(value);\n }\n else {\n this._anchor.copyFrom(value);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"text\", {\n /** The text of the BitmapText object. */\n get: function () {\n return this._text;\n },\n set: function (text) {\n text = String(text === null || text === undefined ? '' : text);\n if (this._text === text) {\n return;\n }\n this._text = text;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"maxWidth\", {\n /**\n * The max width of this bitmap text in pixels. If the text provided is longer than the\n * value provided, line breaks will be automatically inserted in the last whitespace.\n * Disable by setting the value to 0.\n */\n get: function () {\n return this._maxWidth;\n },\n set: function (value) {\n if (this._maxWidth === value) {\n return;\n }\n this._maxWidth = value;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"maxLineHeight\", {\n /**\n * The max line height. This is useful when trying to use the total height of the Text,\n * i.e. when trying to vertically align.\n *\n * @readonly\n */\n get: function () {\n this.validate();\n return this._maxLineHeight;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"textWidth\", {\n /**\n * The width of the overall text, different from fontSize,\n * which is defined in the style object.\n *\n * @readonly\n */\n get: function () {\n this.validate();\n return this._textWidth;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"letterSpacing\", {\n /** Additional space between characters. */\n get: function () {\n return this._letterSpacing;\n },\n set: function (value) {\n if (this._letterSpacing !== value) {\n this._letterSpacing = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"roundPixels\", {\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n * To set the global default, change {@link PIXI.settings.ROUND_PIXELS}\n *\n * @default PIXI.settings.ROUND_PIXELS\n */\n get: function () {\n return this._roundPixels;\n },\n set: function (value) {\n if (value !== this._roundPixels) {\n this._roundPixels = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"textHeight\", {\n /**\n * The height of the overall text, different from fontSize,\n * which is defined in the style object.\n *\n * @readonly\n */\n get: function () {\n this.validate();\n return this._textHeight;\n },\n enumerable: false,\n configurable: true\n });\n BitmapText.prototype.destroy = function (options) {\n var _textureCache = this._textureCache;\n for (var id in _textureCache) {\n var texture = _textureCache[id];\n texture.destroy();\n delete _textureCache[id];\n }\n this._textureCache = null;\n _super.prototype.destroy.call(this, options);\n };\n BitmapText.styleDefaults = {\n align: 'left',\n tint: 0xFFFFFF,\n maxWidth: 0,\n letterSpacing: 0,\n };\n return BitmapText;\n}(Container));\n\n/**\n * {@link PIXI.Loader Loader} middleware for loading\n * bitmap-based fonts suitable for using with {@link PIXI.BitmapText}.\n *\n * @memberof PIXI\n */\nvar BitmapFontLoader = /** @class */ (function () {\n function BitmapFontLoader() {\n }\n /**\n * Called when the plugin is installed.\n *\n * @see PIXI.Loader.registerPlugin\n */\n BitmapFontLoader.add = function () {\n LoaderResource.setExtensionXhrType('fnt', LoaderResource.XHR_RESPONSE_TYPE.TEXT);\n };\n /**\n * Called after a resource is loaded.\n *\n * @see PIXI.Loader.loaderMiddleware\n * @param {PIXI.LoaderResource} resource\n * @param {function} next\n */\n BitmapFontLoader.use = function (resource, next) {\n var format = autoDetectFormat(resource.data);\n // Resource was not recognised as any of the expected font data format\n if (!format) {\n next();\n return;\n }\n var baseUrl = BitmapFontLoader.getBaseUrl(this, resource);\n var data = format.parse(resource.data);\n var textures = {};\n // Handle completed, when the number of textures\n // load is the same number as references in the fnt file\n var completed = function (page) {\n textures[page.metadata.pageFile] = page.texture;\n if (Object.keys(textures).length === data.page.length) {\n resource.bitmapFont = BitmapFont.install(data, textures, true);\n next();\n }\n };\n for (var i = 0; i < data.page.length; ++i) {\n var pageFile = data.page[i].file;\n var url = baseUrl + pageFile;\n var exists = false;\n // incase the image is loaded outside\n // using the same loader, resource will be available\n for (var name in this.resources) {\n var bitmapResource = this.resources[name];\n if (bitmapResource.url === url) {\n bitmapResource.metadata.pageFile = pageFile;\n if (bitmapResource.texture) {\n completed(bitmapResource);\n }\n else {\n bitmapResource.onAfterMiddleware.add(completed);\n }\n exists = true;\n break;\n }\n }\n // texture is not loaded, we'll attempt to add\n // it to the load and add the texture to the list\n if (!exists) {\n // Standard loading options for images\n var options = {\n crossOrigin: resource.crossOrigin,\n loadType: LoaderResource.LOAD_TYPE.IMAGE,\n metadata: Object.assign({ pageFile: pageFile }, resource.metadata.imageMetadata),\n parentResource: resource,\n };\n this.add(url, options, completed);\n }\n }\n };\n /** Get folder path from a resource. */\n BitmapFontLoader.getBaseUrl = function (loader, resource) {\n var resUrl = !resource.isDataUrl ? BitmapFontLoader.dirname(resource.url) : '';\n if (resource.isDataUrl) {\n if (resUrl === '.') {\n resUrl = '';\n }\n if (loader.baseUrl && resUrl) {\n // if baseurl has a trailing slash then add one to resUrl so the replace works below\n if (loader.baseUrl.charAt(loader.baseUrl.length - 1) === '/') {\n resUrl += '/';\n }\n }\n }\n // remove baseUrl from resUrl\n resUrl = resUrl.replace(loader.baseUrl, '');\n // if there is an resUrl now, it needs a trailing slash. Ensure that it does if the string isn't empty.\n if (resUrl && resUrl.charAt(resUrl.length - 1) !== '/') {\n resUrl += '/';\n }\n return resUrl;\n };\n /**\n * Replacement for NodeJS's path.dirname\n *\n * @param {string} url - Path to get directory for\n */\n BitmapFontLoader.dirname = function (url) {\n var dir = url\n .replace(/\\\\/g, '/') // convert windows notation to UNIX notation, URL-safe because it's a forbidden character\n .replace(/\\/$/, '') // replace trailing slash\n .replace(/\\/[^\\/]*$/, ''); // remove everything after the last\n // File request is relative, use current directory\n if (dir === url) {\n return '.';\n }\n // Started with a slash\n else if (dir === '') {\n return '/';\n }\n return dir;\n };\n return BitmapFontLoader;\n}());\n\nexport { BitmapFont, BitmapFontData, BitmapFontLoader, BitmapText };\n//# sourceMappingURL=text-bitmap.js.map\n","/*!\n * @pixi/filter-alpha - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-alpha is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { defaultVertex, Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"varying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform float uAlpha;\\n\\nvoid main(void)\\n{\\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uAlpha;\\n}\\n\";\n\n/**\n * Simplest filter - applies alpha.\n *\n * Use this instead of Container's alpha property to avoid visual layering of individual elements.\n * AlphaFilter applies alpha evenly across the entire display object and any opaque elements it contains.\n * If elements are not opaque, they will blend with each other anyway.\n *\n * Very handy if you want to use common features of all filters:\n *\n * 1. Assign a blendMode to this filter, blend all elements inside display object with background.\n *\n * 2. To use clipping in display coordinates, assign a filterArea to the same container that has this filter.\n *\n * @memberof PIXI.filters\n */\nvar AlphaFilter = /** @class */ (function (_super) {\n __extends(AlphaFilter, _super);\n /**\n * @param alpha - Amount of alpha from 0 to 1, where 0 is transparent\n */\n function AlphaFilter(alpha) {\n if (alpha === void 0) { alpha = 1.0; }\n var _this = _super.call(this, defaultVertex, fragment, { uAlpha: 1 }) || this;\n _this.alpha = alpha;\n return _this;\n }\n Object.defineProperty(AlphaFilter.prototype, \"alpha\", {\n /**\n * Coefficient for alpha multiplication\n *\n * @default 1\n */\n get: function () {\n return this.uniforms.uAlpha;\n },\n set: function (value) {\n this.uniforms.uAlpha = value;\n },\n enumerable: false,\n configurable: true\n });\n return AlphaFilter;\n}(Filter));\n\nexport { AlphaFilter };\n//# sourceMappingURL=filter-alpha.js.map\n","/*!\n * @pixi/filter-blur - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-blur is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Filter } from '@pixi/core';\nimport { settings } from '@pixi/settings';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar vertTemplate = \"\\n attribute vec2 aVertexPosition;\\n\\n uniform mat3 projectionMatrix;\\n\\n uniform float strength;\\n\\n varying vec2 vBlurTexCoords[%size%];\\n\\n uniform vec4 inputSize;\\n uniform vec4 outputFrame;\\n\\n vec4 filterVertexPosition( void )\\n {\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n }\\n\\n vec2 filterTextureCoord( void )\\n {\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n }\\n\\n void main(void)\\n {\\n gl_Position = filterVertexPosition();\\n\\n vec2 textureCoord = filterTextureCoord();\\n %blur%\\n }\";\nfunction generateBlurVertSource(kernelSize, x) {\n var halfLength = Math.ceil(kernelSize / 2);\n var vertSource = vertTemplate;\n var blurLoop = '';\n var template;\n if (x) {\n template = 'vBlurTexCoords[%index%] = textureCoord + vec2(%sampleIndex% * strength, 0.0);';\n }\n else {\n template = 'vBlurTexCoords[%index%] = textureCoord + vec2(0.0, %sampleIndex% * strength);';\n }\n for (var i = 0; i < kernelSize; i++) {\n var blur = template.replace('%index%', i.toString());\n blur = blur.replace('%sampleIndex%', i - (halfLength - 1) + \".0\");\n blurLoop += blur;\n blurLoop += '\\n';\n }\n vertSource = vertSource.replace('%blur%', blurLoop);\n vertSource = vertSource.replace('%size%', kernelSize.toString());\n return vertSource;\n}\n\nvar GAUSSIAN_VALUES = {\n 5: [0.153388, 0.221461, 0.250301],\n 7: [0.071303, 0.131514, 0.189879, 0.214607],\n 9: [0.028532, 0.067234, 0.124009, 0.179044, 0.20236],\n 11: [0.0093, 0.028002, 0.065984, 0.121703, 0.175713, 0.198596],\n 13: [0.002406, 0.009255, 0.027867, 0.065666, 0.121117, 0.174868, 0.197641],\n 15: [0.000489, 0.002403, 0.009246, 0.02784, 0.065602, 0.120999, 0.174697, 0.197448],\n};\nvar fragTemplate = [\n 'varying vec2 vBlurTexCoords[%size%];',\n 'uniform sampler2D uSampler;',\n 'void main(void)',\n '{',\n ' gl_FragColor = vec4(0.0);',\n ' %blur%',\n '}' ].join('\\n');\nfunction generateBlurFragSource(kernelSize) {\n var kernel = GAUSSIAN_VALUES[kernelSize];\n var halfLength = kernel.length;\n var fragSource = fragTemplate;\n var blurLoop = '';\n var template = 'gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;';\n var value;\n for (var i = 0; i < kernelSize; i++) {\n var blur = template.replace('%index%', i.toString());\n value = i;\n if (i >= halfLength) {\n value = kernelSize - i - 1;\n }\n blur = blur.replace('%value%', kernel[value].toString());\n blurLoop += blur;\n blurLoop += '\\n';\n }\n fragSource = fragSource.replace('%blur%', blurLoop);\n fragSource = fragSource.replace('%size%', kernelSize.toString());\n return fragSource;\n}\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\n/**\n * The BlurFilterPass applies a horizontal or vertical Gaussian blur to an object.\n *\n * @memberof PIXI.filters\n */\nvar BlurFilterPass = /** @class */ (function (_super) {\n __extends(BlurFilterPass, _super);\n /**\n * @param horizontal - Do pass along the x-axis (`true`) or y-axis (`false`).\n * @param strength - The strength of the blur filter.\n * @param quality - The quality of the blur filter.\n * @param resolution - The resolution of the blur filter.\n * @param kernelSize - The kernelSize of the blur filter.Options: 5, 7, 9, 11, 13, 15.\n */\n function BlurFilterPass(horizontal, strength, quality, resolution, kernelSize) {\n if (strength === void 0) { strength = 8; }\n if (quality === void 0) { quality = 4; }\n if (resolution === void 0) { resolution = settings.FILTER_RESOLUTION; }\n if (kernelSize === void 0) { kernelSize = 5; }\n var _this = this;\n var vertSrc = generateBlurVertSource(kernelSize, horizontal);\n var fragSrc = generateBlurFragSource(kernelSize);\n _this = _super.call(this, \n // vertex shader\n vertSrc, \n // fragment shader\n fragSrc) || this;\n _this.horizontal = horizontal;\n _this.resolution = resolution;\n _this._quality = 0;\n _this.quality = quality;\n _this.blur = strength;\n return _this;\n }\n /**\n * Applies the filter.\n *\n * @param filterManager - The manager.\n * @param input - The input target.\n * @param output - The output target.\n * @param clearMode - How to clear\n */\n BlurFilterPass.prototype.apply = function (filterManager, input, output, clearMode) {\n if (output) {\n if (this.horizontal) {\n this.uniforms.strength = (1 / output.width) * (output.width / input.width);\n }\n else {\n this.uniforms.strength = (1 / output.height) * (output.height / input.height);\n }\n }\n else {\n if (this.horizontal) // eslint-disable-line\n {\n this.uniforms.strength = (1 / filterManager.renderer.width) * (filterManager.renderer.width / input.width);\n }\n else {\n this.uniforms.strength = (1 / filterManager.renderer.height) * (filterManager.renderer.height / input.height); // eslint-disable-line\n }\n }\n // screen space!\n this.uniforms.strength *= this.strength;\n this.uniforms.strength /= this.passes;\n if (this.passes === 1) {\n filterManager.applyFilter(this, input, output, clearMode);\n }\n else {\n var renderTarget = filterManager.getFilterTexture();\n var renderer = filterManager.renderer;\n var flip = input;\n var flop = renderTarget;\n this.state.blend = false;\n filterManager.applyFilter(this, flip, flop, CLEAR_MODES.CLEAR);\n for (var i = 1; i < this.passes - 1; i++) {\n filterManager.bindAndClear(flip, CLEAR_MODES.BLIT);\n this.uniforms.uSampler = flop;\n var temp = flop;\n flop = flip;\n flip = temp;\n renderer.shader.bind(this);\n renderer.geometry.draw(5);\n }\n this.state.blend = true;\n filterManager.applyFilter(this, flop, output, clearMode);\n filterManager.returnFilterTexture(renderTarget);\n }\n };\n Object.defineProperty(BlurFilterPass.prototype, \"blur\", {\n /**\n * Sets the strength of both the blur.\n *\n * @default 16\n */\n get: function () {\n return this.strength;\n },\n set: function (value) {\n this.padding = 1 + (Math.abs(value) * 2);\n this.strength = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilterPass.prototype, \"quality\", {\n /**\n * Sets the quality of the blur by modifying the number of passes. More passes means higher\n * quality bluring but the lower the performance.\n *\n * @default 4\n */\n get: function () {\n return this._quality;\n },\n set: function (value) {\n this._quality = value;\n this.passes = value;\n },\n enumerable: false,\n configurable: true\n });\n return BlurFilterPass;\n}(Filter));\n\n/**\n * The BlurFilter applies a Gaussian blur to an object.\n *\n * The strength of the blur can be set for the x-axis and y-axis separately.\n *\n * @memberof PIXI.filters\n */\nvar BlurFilter = /** @class */ (function (_super) {\n __extends(BlurFilter, _super);\n /**\n * @param strength - The strength of the blur filter.\n * @param quality - The quality of the blur filter.\n * @param [resolution=PIXI.settings.FILTER_RESOLUTION] - The resolution of the blur filter.\n * @param kernelSize - The kernelSize of the blur filter.Options: 5, 7, 9, 11, 13, 15.\n */\n function BlurFilter(strength, quality, resolution, kernelSize) {\n if (strength === void 0) { strength = 8; }\n if (quality === void 0) { quality = 4; }\n if (resolution === void 0) { resolution = settings.FILTER_RESOLUTION; }\n if (kernelSize === void 0) { kernelSize = 5; }\n var _this = _super.call(this) || this;\n _this.blurXFilter = new BlurFilterPass(true, strength, quality, resolution, kernelSize);\n _this.blurYFilter = new BlurFilterPass(false, strength, quality, resolution, kernelSize);\n _this.resolution = resolution;\n _this.quality = quality;\n _this.blur = strength;\n _this.repeatEdgePixels = false;\n return _this;\n }\n /**\n * Applies the filter.\n *\n * @param filterManager - The manager.\n * @param input - The input target.\n * @param output - The output target.\n * @param clearMode - How to clear\n */\n BlurFilter.prototype.apply = function (filterManager, input, output, clearMode) {\n var xStrength = Math.abs(this.blurXFilter.strength);\n var yStrength = Math.abs(this.blurYFilter.strength);\n if (xStrength && yStrength) {\n var renderTarget = filterManager.getFilterTexture();\n this.blurXFilter.apply(filterManager, input, renderTarget, CLEAR_MODES.CLEAR);\n this.blurYFilter.apply(filterManager, renderTarget, output, clearMode);\n filterManager.returnFilterTexture(renderTarget);\n }\n else if (yStrength) {\n this.blurYFilter.apply(filterManager, input, output, clearMode);\n }\n else {\n this.blurXFilter.apply(filterManager, input, output, clearMode);\n }\n };\n BlurFilter.prototype.updatePadding = function () {\n if (this._repeatEdgePixels) {\n this.padding = 0;\n }\n else {\n this.padding = Math.max(Math.abs(this.blurXFilter.strength), Math.abs(this.blurYFilter.strength)) * 2;\n }\n };\n Object.defineProperty(BlurFilter.prototype, \"blur\", {\n /**\n * Sets the strength of both the blurX and blurY properties simultaneously\n *\n * @default 2\n */\n get: function () {\n return this.blurXFilter.blur;\n },\n set: function (value) {\n this.blurXFilter.blur = this.blurYFilter.blur = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"quality\", {\n /**\n * Sets the number of passes for blur. More passes means higher quality bluring.\n *\n * @default 1\n */\n get: function () {\n return this.blurXFilter.quality;\n },\n set: function (value) {\n this.blurXFilter.quality = this.blurYFilter.quality = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"blurX\", {\n /**\n * Sets the strength of the blurX property\n *\n * @default 2\n */\n get: function () {\n return this.blurXFilter.blur;\n },\n set: function (value) {\n this.blurXFilter.blur = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"blurY\", {\n /**\n * Sets the strength of the blurY property\n *\n * @default 2\n */\n get: function () {\n return this.blurYFilter.blur;\n },\n set: function (value) {\n this.blurYFilter.blur = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"blendMode\", {\n /**\n * Sets the blendmode of the filter\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n get: function () {\n return this.blurYFilter.blendMode;\n },\n set: function (value) {\n this.blurYFilter.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"repeatEdgePixels\", {\n /**\n * If set to true the edge of the target will be clamped\n *\n * @default false\n */\n get: function () {\n return this._repeatEdgePixels;\n },\n set: function (value) {\n this._repeatEdgePixels = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n return BlurFilter;\n}(Filter));\n\nexport { BlurFilter, BlurFilterPass };\n//# sourceMappingURL=filter-blur.js.map\n","/*!\n * @pixi/filter-color-matrix - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-color-matrix is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { defaultFilterVertex, Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"varying vec2 vTextureCoord;\\nuniform sampler2D uSampler;\\nuniform float m[20];\\nuniform float uAlpha;\\n\\nvoid main(void)\\n{\\n vec4 c = texture2D(uSampler, vTextureCoord);\\n\\n if (uAlpha == 0.0) {\\n gl_FragColor = c;\\n return;\\n }\\n\\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\\n if (c.a > 0.0) {\\n c.rgb /= c.a;\\n }\\n\\n vec4 result;\\n\\n result.r = (m[0] * c.r);\\n result.r += (m[1] * c.g);\\n result.r += (m[2] * c.b);\\n result.r += (m[3] * c.a);\\n result.r += m[4];\\n\\n result.g = (m[5] * c.r);\\n result.g += (m[6] * c.g);\\n result.g += (m[7] * c.b);\\n result.g += (m[8] * c.a);\\n result.g += m[9];\\n\\n result.b = (m[10] * c.r);\\n result.b += (m[11] * c.g);\\n result.b += (m[12] * c.b);\\n result.b += (m[13] * c.a);\\n result.b += m[14];\\n\\n result.a = (m[15] * c.r);\\n result.a += (m[16] * c.g);\\n result.a += (m[17] * c.b);\\n result.a += (m[18] * c.a);\\n result.a += m[19];\\n\\n vec3 rgb = mix(c.rgb, result.rgb, uAlpha);\\n\\n // Premultiply alpha again.\\n rgb *= result.a;\\n\\n gl_FragColor = vec4(rgb, result.a);\\n}\\n\";\n\n/**\n * The ColorMatrixFilter class lets you apply a 5x4 matrix transformation on the RGBA\n * color and alpha values of every pixel on your displayObject to produce a result\n * with a new set of RGBA color and alpha values. It's pretty powerful!\n *\n * ```js\n * let colorMatrix = new PIXI.filters.ColorMatrixFilter();\n * container.filters = [colorMatrix];\n * colorMatrix.contrast(2);\n * ```\n * @author Clément Chenebault <clement@goodboydigital.com>\n * @memberof PIXI.filters\n */\nvar ColorMatrixFilter = /** @class */ (function (_super) {\n __extends(ColorMatrixFilter, _super);\n function ColorMatrixFilter() {\n var _this = this;\n var uniforms = {\n m: new Float32Array([1, 0, 0, 0, 0,\n 0, 1, 0, 0, 0,\n 0, 0, 1, 0, 0,\n 0, 0, 0, 1, 0]),\n uAlpha: 1,\n };\n _this = _super.call(this, defaultFilterVertex, fragment, uniforms) || this;\n _this.alpha = 1;\n return _this;\n }\n /**\n * Transforms current matrix and set the new one\n *\n * @param {number[]} matrix - 5x4 matrix\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype._loadMatrix = function (matrix, multiply) {\n if (multiply === void 0) { multiply = false; }\n var newMatrix = matrix;\n if (multiply) {\n this._multiply(newMatrix, this.uniforms.m, matrix);\n newMatrix = this._colorMatrix(newMatrix);\n }\n // set the new matrix\n this.uniforms.m = newMatrix;\n };\n /**\n * Multiplies two mat5's\n *\n * @private\n * @param out - 5x4 matrix the receiving matrix\n * @param a - 5x4 matrix the first operand\n * @param b - 5x4 matrix the second operand\n * @returns {number[]} 5x4 matrix\n */\n ColorMatrixFilter.prototype._multiply = function (out, a, b) {\n // Red Channel\n out[0] = (a[0] * b[0]) + (a[1] * b[5]) + (a[2] * b[10]) + (a[3] * b[15]);\n out[1] = (a[0] * b[1]) + (a[1] * b[6]) + (a[2] * b[11]) + (a[3] * b[16]);\n out[2] = (a[0] * b[2]) + (a[1] * b[7]) + (a[2] * b[12]) + (a[3] * b[17]);\n out[3] = (a[0] * b[3]) + (a[1] * b[8]) + (a[2] * b[13]) + (a[3] * b[18]);\n out[4] = (a[0] * b[4]) + (a[1] * b[9]) + (a[2] * b[14]) + (a[3] * b[19]) + a[4];\n // Green Channel\n out[5] = (a[5] * b[0]) + (a[6] * b[5]) + (a[7] * b[10]) + (a[8] * b[15]);\n out[6] = (a[5] * b[1]) + (a[6] * b[6]) + (a[7] * b[11]) + (a[8] * b[16]);\n out[7] = (a[5] * b[2]) + (a[6] * b[7]) + (a[7] * b[12]) + (a[8] * b[17]);\n out[8] = (a[5] * b[3]) + (a[6] * b[8]) + (a[7] * b[13]) + (a[8] * b[18]);\n out[9] = (a[5] * b[4]) + (a[6] * b[9]) + (a[7] * b[14]) + (a[8] * b[19]) + a[9];\n // Blue Channel\n out[10] = (a[10] * b[0]) + (a[11] * b[5]) + (a[12] * b[10]) + (a[13] * b[15]);\n out[11] = (a[10] * b[1]) + (a[11] * b[6]) + (a[12] * b[11]) + (a[13] * b[16]);\n out[12] = (a[10] * b[2]) + (a[11] * b[7]) + (a[12] * b[12]) + (a[13] * b[17]);\n out[13] = (a[10] * b[3]) + (a[11] * b[8]) + (a[12] * b[13]) + (a[13] * b[18]);\n out[14] = (a[10] * b[4]) + (a[11] * b[9]) + (a[12] * b[14]) + (a[13] * b[19]) + a[14];\n // Alpha Channel\n out[15] = (a[15] * b[0]) + (a[16] * b[5]) + (a[17] * b[10]) + (a[18] * b[15]);\n out[16] = (a[15] * b[1]) + (a[16] * b[6]) + (a[17] * b[11]) + (a[18] * b[16]);\n out[17] = (a[15] * b[2]) + (a[16] * b[7]) + (a[17] * b[12]) + (a[18] * b[17]);\n out[18] = (a[15] * b[3]) + (a[16] * b[8]) + (a[17] * b[13]) + (a[18] * b[18]);\n out[19] = (a[15] * b[4]) + (a[16] * b[9]) + (a[17] * b[14]) + (a[18] * b[19]) + a[19];\n return out;\n };\n /**\n * Create a Float32 Array and normalize the offset component to 0-1\n *\n * @param {number[]} matrix - 5x4 matrix\n * @return {number[]} 5x4 matrix with all values between 0-1\n */\n ColorMatrixFilter.prototype._colorMatrix = function (matrix) {\n // Create a Float32 Array and normalize the offset component to 0-1\n var m = new Float32Array(matrix);\n m[4] /= 255;\n m[9] /= 255;\n m[14] /= 255;\n m[19] /= 255;\n return m;\n };\n /**\n * Adjusts brightness\n *\n * @param b - value of the brigthness (0-1, where 0 is black)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.brightness = function (b, multiply) {\n var matrix = [\n b, 0, 0, 0, 0,\n 0, b, 0, 0, 0,\n 0, 0, b, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Sets each channel on the diagonal of the color matrix.\n * This can be used to achieve a tinting effect on Containers similar to the tint field of some\n * display objects like Sprite, Text, Graphics, and Mesh.\n *\n * @param color - Color of the tint. This is a hex value.\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.tint = function (color, multiply) {\n var r = (color >> 16) & 0xff;\n var g = (color >> 8) & 0xff;\n var b = color & 0xff;\n var matrix = [\n r / 255, 0, 0, 0, 0,\n 0, g / 255, 0, 0, 0,\n 0, 0, b / 255, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the matrices in grey scales\n *\n * @param scale - value of the grey (0-1, where 0 is black)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.greyscale = function (scale, multiply) {\n var matrix = [\n scale, scale, scale, 0, 0,\n scale, scale, scale, 0, 0,\n scale, scale, scale, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the black and white matrice.\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.blackAndWhite = function (multiply) {\n var matrix = [\n 0.3, 0.6, 0.1, 0, 0,\n 0.3, 0.6, 0.1, 0, 0,\n 0.3, 0.6, 0.1, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the hue property of the color\n *\n * @param rotation - in degrees\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.hue = function (rotation, multiply) {\n rotation = (rotation || 0) / 180 * Math.PI;\n var cosR = Math.cos(rotation);\n var sinR = Math.sin(rotation);\n var sqrt = Math.sqrt;\n /* a good approximation for hue rotation\n This matrix is far better than the versions with magic luminance constants\n formerly used here, but also used in the starling framework (flash) and known from this\n old part of the internet: quasimondo.com/archives/000565.php\n\n This new matrix is based on rgb cube rotation in space. Look here for a more descriptive\n implementation as a shader not a general matrix:\n https://github.com/evanw/glfx.js/blob/58841c23919bd59787effc0333a4897b43835412/src/filters/adjust/huesaturation.js\n\n This is the source for the code:\n see http://stackoverflow.com/questions/8507885/shift-hue-of-an-rgb-color/8510751#8510751\n */\n var w = 1 / 3;\n var sqrW = sqrt(w); // weight is\n var a00 = cosR + ((1.0 - cosR) * w);\n var a01 = (w * (1.0 - cosR)) - (sqrW * sinR);\n var a02 = (w * (1.0 - cosR)) + (sqrW * sinR);\n var a10 = (w * (1.0 - cosR)) + (sqrW * sinR);\n var a11 = cosR + (w * (1.0 - cosR));\n var a12 = (w * (1.0 - cosR)) - (sqrW * sinR);\n var a20 = (w * (1.0 - cosR)) - (sqrW * sinR);\n var a21 = (w * (1.0 - cosR)) + (sqrW * sinR);\n var a22 = cosR + (w * (1.0 - cosR));\n var matrix = [\n a00, a01, a02, 0, 0,\n a10, a11, a12, 0, 0,\n a20, a21, a22, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the contrast matrix, increase the separation between dark and bright\n * Increase contrast : shadows darker and highlights brighter\n * Decrease contrast : bring the shadows up and the highlights down\n *\n * @param amount - value of the contrast (0-1)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.contrast = function (amount, multiply) {\n var v = (amount || 0) + 1;\n var o = -0.5 * (v - 1);\n var matrix = [\n v, 0, 0, 0, o,\n 0, v, 0, 0, o,\n 0, 0, v, 0, o,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the saturation matrix, increase the separation between colors\n * Increase saturation : increase contrast, brightness, and sharpness\n *\n * @param amount - The saturation amount (0-1)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.saturate = function (amount, multiply) {\n if (amount === void 0) { amount = 0; }\n var x = (amount * 2 / 3) + 1;\n var y = ((x - 1) * -0.5);\n var matrix = [\n x, y, y, 0, 0,\n y, x, y, 0, 0,\n y, y, x, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Desaturate image (remove color)\n *\n * Call the saturate function\n */\n ColorMatrixFilter.prototype.desaturate = function () {\n this.saturate(-1);\n };\n /**\n * Negative image (inverse of classic rgb matrix)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.negative = function (multiply) {\n var matrix = [\n -1, 0, 0, 1, 0,\n 0, -1, 0, 1, 0,\n 0, 0, -1, 1, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Sepia image\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.sepia = function (multiply) {\n var matrix = [\n 0.393, 0.7689999, 0.18899999, 0, 0,\n 0.349, 0.6859999, 0.16799999, 0, 0,\n 0.272, 0.5339999, 0.13099999, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Color motion picture process invented in 1916 (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.technicolor = function (multiply) {\n var matrix = [\n 1.9125277891456083, -0.8545344976951645, -0.09155508482755585, 0, 11.793603434377337,\n -0.3087833385928097, 1.7658908555458428, -0.10601743074722245, 0, -70.35205161461398,\n -0.231103377548616, -0.7501899197440212, 1.847597816108189, 0, 30.950940869491138,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Polaroid filter\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.polaroid = function (multiply) {\n var matrix = [\n 1.438, -0.062, -0.062, 0, 0,\n -0.122, 1.378, -0.122, 0, 0,\n -0.016, -0.016, 1.483, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Filter who transforms : Red -> Blue and Blue -> Red\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.toBGR = function (multiply) {\n var matrix = [\n 0, 0, 1, 0, 0,\n 0, 1, 0, 0, 0,\n 1, 0, 0, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Color reversal film introduced by Eastman Kodak in 1935. (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.kodachrome = function (multiply) {\n var matrix = [\n 1.1285582396593525, -0.3967382283601348, -0.03992559172921793, 0, 63.72958762196502,\n -0.16404339962244616, 1.0835251566291304, -0.05498805115633132, 0, 24.732407896706203,\n -0.16786010706155763, -0.5603416277695248, 1.6014850761964943, 0, 35.62982807460946,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Brown delicious browni filter (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.browni = function (multiply) {\n var matrix = [\n 0.5997023498159715, 0.34553243048391263, -0.2708298674538042, 0, 47.43192855600873,\n -0.037703249837783157, 0.8609577587992641, 0.15059552388459913, 0, -36.96841498319127,\n 0.24113635128153335, -0.07441037908422492, 0.44972182064877153, 0, -7.562075277591283,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Vintage filter (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.vintage = function (multiply) {\n var matrix = [\n 0.6279345635605994, 0.3202183420819367, -0.03965408211312453, 0, 9.651285835294123,\n 0.02578397704808868, 0.6441188644374771, 0.03259127616149294, 0, 7.462829176470591,\n 0.0466055556782719, -0.0851232987247891, 0.5241648018700465, 0, 5.159190588235296,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * We don't know exactly what it does, kind of gradient map, but funny to play with!\n *\n * @param desaturation - Tone values.\n * @param toned - Tone values.\n * @param lightColor - Tone values, example: `0xFFE580`\n * @param darkColor - Tone values, example: `0xFFE580`\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.colorTone = function (desaturation, toned, lightColor, darkColor, multiply) {\n desaturation = desaturation || 0.2;\n toned = toned || 0.15;\n lightColor = lightColor || 0xFFE580;\n darkColor = darkColor || 0x338000;\n var lR = ((lightColor >> 16) & 0xFF) / 255;\n var lG = ((lightColor >> 8) & 0xFF) / 255;\n var lB = (lightColor & 0xFF) / 255;\n var dR = ((darkColor >> 16) & 0xFF) / 255;\n var dG = ((darkColor >> 8) & 0xFF) / 255;\n var dB = (darkColor & 0xFF) / 255;\n var matrix = [\n 0.3, 0.59, 0.11, 0, 0,\n lR, lG, lB, desaturation, 0,\n dR, dG, dB, toned, 0,\n lR - dR, lG - dG, lB - dB, 0, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Night effect\n *\n * @param intensity - The intensity of the night effect.\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.night = function (intensity, multiply) {\n intensity = intensity || 0.1;\n var matrix = [\n intensity * (-2.0), -intensity, 0, 0, 0,\n -intensity, 0, intensity, 0, 0,\n 0, intensity, intensity * 2.0, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Predator effect\n *\n * Erase the current matrix by setting a new indepent one\n *\n * @param amount - how much the predator feels his future victim\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.predator = function (amount, multiply) {\n var matrix = [\n // row 1\n 11.224130630493164 * amount,\n -4.794486999511719 * amount,\n -2.8746118545532227 * amount,\n 0 * amount,\n 0.40342438220977783 * amount,\n // row 2\n -3.6330697536468506 * amount,\n 9.193157196044922 * amount,\n -2.951810836791992 * amount,\n 0 * amount,\n -1.316135048866272 * amount,\n // row 3\n -3.2184197902679443 * amount,\n -4.2375030517578125 * amount,\n 7.476448059082031 * amount,\n 0 * amount,\n 0.8044459223747253 * amount,\n // row 4\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * LSD effect\n *\n * Multiply the current matrix\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.lsd = function (multiply) {\n var matrix = [\n 2, -0.4, 0.5, 0, 0,\n -0.5, 2, -0.4, 0, 0,\n -0.4, -0.5, 3, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /** Erase the current matrix by setting the default one. */\n ColorMatrixFilter.prototype.reset = function () {\n var matrix = [\n 1, 0, 0, 0, 0,\n 0, 1, 0, 0, 0,\n 0, 0, 1, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, false);\n };\n Object.defineProperty(ColorMatrixFilter.prototype, \"matrix\", {\n /**\n * The matrix of the color matrix filter\n *\n * @member {number[]}\n * @default [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0]\n */\n get: function () {\n return this.uniforms.m;\n },\n set: function (value) {\n this.uniforms.m = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ColorMatrixFilter.prototype, \"alpha\", {\n /**\n * The opacity value to use when mixing the original and resultant colors.\n *\n * When the value is 0, the original color is used without modification.\n * When the value is 1, the result color is used.\n * When in the range (0, 1) the color is interpolated between the original and result by this amount.\n *\n * @default 1\n */\n get: function () {\n return this.uniforms.uAlpha;\n },\n set: function (value) {\n this.uniforms.uAlpha = value;\n },\n enumerable: false,\n configurable: true\n });\n return ColorMatrixFilter;\n}(Filter));\n// Americanized alias\nColorMatrixFilter.prototype.grayscale = ColorMatrixFilter.prototype.greyscale;\n\nexport { ColorMatrixFilter };\n//# sourceMappingURL=filter-color-matrix.js.map\n","/*!\n * @pixi/filter-displacement - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-displacement is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Filter } from '@pixi/core';\nimport { Matrix, Point } from '@pixi/math';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"varying vec2 vFilterCoord;\\nvarying vec2 vTextureCoord;\\n\\nuniform vec2 scale;\\nuniform mat2 rotation;\\nuniform sampler2D uSampler;\\nuniform sampler2D mapSampler;\\n\\nuniform highp vec4 inputSize;\\nuniform vec4 inputClamp;\\n\\nvoid main(void)\\n{\\n vec4 map = texture2D(mapSampler, vFilterCoord);\\n\\n map -= 0.5;\\n map.xy = scale * inputSize.zw * (rotation * map.xy);\\n\\n gl_FragColor = texture2D(uSampler, clamp(vec2(vTextureCoord.x + map.x, vTextureCoord.y + map.y), inputClamp.xy, inputClamp.zw));\\n}\\n\";\n\nvar vertex = \"attribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 filterMatrix;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec2 vFilterCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvec2 filterTextureCoord( void )\\n{\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n}\\n\\nvoid main(void)\\n{\\n\\tgl_Position = filterVertexPosition();\\n\\tvTextureCoord = filterTextureCoord();\\n\\tvFilterCoord = ( filterMatrix * vec3( vTextureCoord, 1.0) ).xy;\\n}\\n\";\n\n/**\n * The DisplacementFilter class uses the pixel values from the specified texture\n * (called the displacement map) to perform a displacement of an object.\n *\n * You can use this filter to apply all manor of crazy warping effects.\n * Currently the `r` property of the texture is used to offset the `x`\n * and the `g` property of the texture is used to offset the `y`.\n *\n * The way it works is it uses the values of the displacement map to look up the\n * correct pixels to output. This means it's not technically moving the original.\n * Instead, it's starting at the output and asking \"which pixel from the original goes here\".\n * For example, if a displacement map pixel has `red = 1` and the filter scale is `20`,\n * this filter will output the pixel approximately 20 pixels to the right of the original.\n *\n * @memberof PIXI.filters\n */\nvar DisplacementFilter = /** @class */ (function (_super) {\n __extends(DisplacementFilter, _super);\n /**\n * @param {PIXI.Sprite} sprite - The sprite used for the displacement map. (make sure its added to the scene!)\n * @param scale - The scale of the displacement\n */\n function DisplacementFilter(sprite, scale) {\n var _this = this;\n var maskMatrix = new Matrix();\n sprite.renderable = false;\n _this = _super.call(this, vertex, fragment, {\n mapSampler: sprite._texture,\n filterMatrix: maskMatrix,\n scale: { x: 1, y: 1 },\n rotation: new Float32Array([1, 0, 0, 1]),\n }) || this;\n _this.maskSprite = sprite;\n _this.maskMatrix = maskMatrix;\n if (scale === null || scale === undefined) {\n scale = 20;\n }\n /**\n * scaleX, scaleY for displacements\n * @member {PIXI.Point}\n */\n _this.scale = new Point(scale, scale);\n return _this;\n }\n /**\n * Applies the filter.\n *\n * @param filterManager - The manager.\n * @param input - The input target.\n * @param output - The output target.\n * @param clearMode - clearMode.\n */\n DisplacementFilter.prototype.apply = function (filterManager, input, output, clearMode) {\n // fill maskMatrix with _normalized sprite texture coords_\n this.uniforms.filterMatrix = filterManager.calculateSpriteMatrix(this.maskMatrix, this.maskSprite);\n this.uniforms.scale.x = this.scale.x;\n this.uniforms.scale.y = this.scale.y;\n // Extract rotation from world transform\n var wt = this.maskSprite.worldTransform;\n var lenX = Math.sqrt((wt.a * wt.a) + (wt.b * wt.b));\n var lenY = Math.sqrt((wt.c * wt.c) + (wt.d * wt.d));\n if (lenX !== 0 && lenY !== 0) {\n this.uniforms.rotation[0] = wt.a / lenX;\n this.uniforms.rotation[1] = wt.b / lenX;\n this.uniforms.rotation[2] = wt.c / lenY;\n this.uniforms.rotation[3] = wt.d / lenY;\n }\n // draw the filter...\n filterManager.applyFilter(this, input, output, clearMode);\n };\n Object.defineProperty(DisplacementFilter.prototype, \"map\", {\n /** The texture used for the displacement map. Must be power of 2 sized texture. */\n get: function () {\n return this.uniforms.mapSampler;\n },\n set: function (value) {\n this.uniforms.mapSampler = value;\n },\n enumerable: false,\n configurable: true\n });\n return DisplacementFilter;\n}(Filter));\n\nexport { DisplacementFilter };\n//# sourceMappingURL=filter-displacement.js.map\n","/*!\n * @pixi/filter-fxaa - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-fxaa is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar vertex = \"\\nattribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 v_rgbNW;\\nvarying vec2 v_rgbNE;\\nvarying vec2 v_rgbSW;\\nvarying vec2 v_rgbSE;\\nvarying vec2 v_rgbM;\\n\\nvarying vec2 vFragCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvoid texcoords(vec2 fragCoord, vec2 inverseVP,\\n out vec2 v_rgbNW, out vec2 v_rgbNE,\\n out vec2 v_rgbSW, out vec2 v_rgbSE,\\n out vec2 v_rgbM) {\\n v_rgbNW = (fragCoord + vec2(-1.0, -1.0)) * inverseVP;\\n v_rgbNE = (fragCoord + vec2(1.0, -1.0)) * inverseVP;\\n v_rgbSW = (fragCoord + vec2(-1.0, 1.0)) * inverseVP;\\n v_rgbSE = (fragCoord + vec2(1.0, 1.0)) * inverseVP;\\n v_rgbM = vec2(fragCoord * inverseVP);\\n}\\n\\nvoid main(void) {\\n\\n gl_Position = filterVertexPosition();\\n\\n vFragCoord = aVertexPosition * outputFrame.zw;\\n\\n texcoords(vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\\n}\\n\";\n\nvar fragment = \"varying vec2 v_rgbNW;\\nvarying vec2 v_rgbNE;\\nvarying vec2 v_rgbSW;\\nvarying vec2 v_rgbSE;\\nvarying vec2 v_rgbM;\\n\\nvarying vec2 vFragCoord;\\nuniform sampler2D uSampler;\\nuniform highp vec4 inputSize;\\n\\n\\n/**\\n Basic FXAA implementation based on the code on geeks3d.com with the\\n modification that the texture2DLod stuff was removed since it's\\n unsupported by WebGL.\\n\\n --\\n\\n From:\\n https://github.com/mitsuhiko/webgl-meincraft\\n\\n Copyright (c) 2011 by Armin Ronacher.\\n\\n Some rights reserved.\\n\\n Redistribution and use in source and binary forms, with or without\\n modification, are permitted provided that the following conditions are\\n met:\\n\\n * Redistributions of source code must retain the above copyright\\n notice, this list of conditions and the following disclaimer.\\n\\n * Redistributions in binary form must reproduce the above\\n copyright notice, this list of conditions and the following\\n disclaimer in the documentation and/or other materials provided\\n with the distribution.\\n\\n * The names of the contributors may not be used to endorse or\\n promote products derived from this software without specific\\n prior written permission.\\n\\n THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\\n \\\"AS IS\\\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\\n LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\\n A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\\n OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\\n SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\\n LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\\n DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\\n THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\\n (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\\n OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\\n */\\n\\n#ifndef FXAA_REDUCE_MIN\\n#define FXAA_REDUCE_MIN (1.0/ 128.0)\\n#endif\\n#ifndef FXAA_REDUCE_MUL\\n#define FXAA_REDUCE_MUL (1.0 / 8.0)\\n#endif\\n#ifndef FXAA_SPAN_MAX\\n#define FXAA_SPAN_MAX 8.0\\n#endif\\n\\n//optimized version for mobile, where dependent\\n//texture reads can be a bottleneck\\nvec4 fxaa(sampler2D tex, vec2 fragCoord, vec2 inverseVP,\\n vec2 v_rgbNW, vec2 v_rgbNE,\\n vec2 v_rgbSW, vec2 v_rgbSE,\\n vec2 v_rgbM) {\\n vec4 color;\\n vec3 rgbNW = texture2D(tex, v_rgbNW).xyz;\\n vec3 rgbNE = texture2D(tex, v_rgbNE).xyz;\\n vec3 rgbSW = texture2D(tex, v_rgbSW).xyz;\\n vec3 rgbSE = texture2D(tex, v_rgbSE).xyz;\\n vec4 texColor = texture2D(tex, v_rgbM);\\n vec3 rgbM = texColor.xyz;\\n vec3 luma = vec3(0.299, 0.587, 0.114);\\n float lumaNW = dot(rgbNW, luma);\\n float lumaNE = dot(rgbNE, luma);\\n float lumaSW = dot(rgbSW, luma);\\n float lumaSE = dot(rgbSE, luma);\\n float lumaM = dot(rgbM, luma);\\n float lumaMin = min(lumaM, min(min(lumaNW, lumaNE), min(lumaSW, lumaSE)));\\n float lumaMax = max(lumaM, max(max(lumaNW, lumaNE), max(lumaSW, lumaSE)));\\n\\n mediump vec2 dir;\\n dir.x = -((lumaNW + lumaNE) - (lumaSW + lumaSE));\\n dir.y = ((lumaNW + lumaSW) - (lumaNE + lumaSE));\\n\\n float dirReduce = max((lumaNW + lumaNE + lumaSW + lumaSE) *\\n (0.25 * FXAA_REDUCE_MUL), FXAA_REDUCE_MIN);\\n\\n float rcpDirMin = 1.0 / (min(abs(dir.x), abs(dir.y)) + dirReduce);\\n dir = min(vec2(FXAA_SPAN_MAX, FXAA_SPAN_MAX),\\n max(vec2(-FXAA_SPAN_MAX, -FXAA_SPAN_MAX),\\n dir * rcpDirMin)) * inverseVP;\\n\\n vec3 rgbA = 0.5 * (\\n texture2D(tex, fragCoord * inverseVP + dir * (1.0 / 3.0 - 0.5)).xyz +\\n texture2D(tex, fragCoord * inverseVP + dir * (2.0 / 3.0 - 0.5)).xyz);\\n vec3 rgbB = rgbA * 0.5 + 0.25 * (\\n texture2D(tex, fragCoord * inverseVP + dir * -0.5).xyz +\\n texture2D(tex, fragCoord * inverseVP + dir * 0.5).xyz);\\n\\n float lumaB = dot(rgbB, luma);\\n if ((lumaB < lumaMin) || (lumaB > lumaMax))\\n color = vec4(rgbA, texColor.a);\\n else\\n color = vec4(rgbB, texColor.a);\\n return color;\\n}\\n\\nvoid main() {\\n\\n vec4 color;\\n\\n color = fxaa(uSampler, vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\\n\\n gl_FragColor = color;\\n}\\n\";\n\n/**\n * Basic FXAA (Fast Approximate Anti-Aliasing) implementation based on the code on geeks3d.com\n * with the modification that the texture2DLod stuff was removed since it is unsupported by WebGL.\n *\n * @see https://github.com/mitsuhiko/webgl-meincraft\n *\n * @memberof PIXI.filters\n */\nvar FXAAFilter = /** @class */ (function (_super) {\n __extends(FXAAFilter, _super);\n function FXAAFilter() {\n // TODO - needs work\n return _super.call(this, vertex, fragment) || this;\n }\n return FXAAFilter;\n}(Filter));\n\nexport { FXAAFilter };\n//# sourceMappingURL=filter-fxaa.js.map\n","/*!\n * @pixi/filter-noise - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-noise is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { defaultFilterVertex, Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"precision highp float;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec4 vColor;\\n\\nuniform float uNoise;\\nuniform float uSeed;\\nuniform sampler2D uSampler;\\n\\nfloat rand(vec2 co)\\n{\\n return fract(sin(dot(co.xy, vec2(12.9898, 78.233))) * 43758.5453);\\n}\\n\\nvoid main()\\n{\\n vec4 color = texture2D(uSampler, vTextureCoord);\\n float randomValue = rand(gl_FragCoord.xy * uSeed);\\n float diff = (randomValue - 0.5) * uNoise;\\n\\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\\n if (color.a > 0.0) {\\n color.rgb /= color.a;\\n }\\n\\n color.r += diff;\\n color.g += diff;\\n color.b += diff;\\n\\n // Premultiply alpha again.\\n color.rgb *= color.a;\\n\\n gl_FragColor = color;\\n}\\n\";\n\n/**\n * A Noise effect filter.\n *\n * original filter: https://github.com/evanw/glfx.js/blob/master/src/filters/adjust/noise.js\n *\n * @memberof PIXI.filters\n * @author Vico @vicocotea\n */\nvar NoiseFilter = /** @class */ (function (_super) {\n __extends(NoiseFilter, _super);\n /**\n * @param {number} [noise=0.5] - The noise intensity, should be a normalized value in the range [0, 1].\n * @param {number} [seed] - A random seed for the noise generation. Default is `Math.random()`.\n */\n function NoiseFilter(noise, seed) {\n if (noise === void 0) { noise = 0.5; }\n if (seed === void 0) { seed = Math.random(); }\n var _this = _super.call(this, defaultFilterVertex, fragment, {\n uNoise: 0,\n uSeed: 0,\n }) || this;\n _this.noise = noise;\n _this.seed = seed;\n return _this;\n }\n Object.defineProperty(NoiseFilter.prototype, \"noise\", {\n /**\n * The amount of noise to apply, this value should be in the range (0, 1].\n *\n * @default 0.5\n */\n get: function () {\n return this.uniforms.uNoise;\n },\n set: function (value) {\n this.uniforms.uNoise = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NoiseFilter.prototype, \"seed\", {\n /** A seed value to apply to the random noise generation. `Math.random()` is a good value to use. */\n get: function () {\n return this.uniforms.uSeed;\n },\n set: function (value) {\n this.uniforms.uSeed = value;\n },\n enumerable: false,\n configurable: true\n });\n return NoiseFilter;\n}(Filter));\n\nexport { NoiseFilter };\n//# sourceMappingURL=filter-noise.js.map\n","/*!\n * @pixi/mixin-cache-as-bitmap - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mixin-cache-as-bitmap is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { RenderTexture, BaseTexture, Texture } from '@pixi/core';\nimport { Sprite } from '@pixi/sprite';\nimport { DisplayObject } from '@pixi/display';\nimport { Matrix } from '@pixi/math';\nimport { uid } from '@pixi/utils';\nimport { settings } from '@pixi/settings';\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\nvar _tempMatrix = new Matrix();\nDisplayObject.prototype._cacheAsBitmap = false;\nDisplayObject.prototype._cacheData = null;\nDisplayObject.prototype._cacheAsBitmapResolution = null;\nDisplayObject.prototype._cacheAsBitmapMultisample = MSAA_QUALITY.NONE;\n// figured there's no point adding ALL the extra variables to prototype.\n// this model can hold the information needed. This can also be generated on demand as\n// most objects are not cached as bitmaps.\n/**\n * @class\n * @ignore\n * @private\n */\nvar CacheData = /** @class */ (function () {\n function CacheData() {\n this.textureCacheId = null;\n this.originalRender = null;\n this.originalRenderCanvas = null;\n this.originalCalculateBounds = null;\n this.originalGetLocalBounds = null;\n this.originalUpdateTransform = null;\n this.originalDestroy = null;\n this.originalMask = null;\n this.originalFilterArea = null;\n this.originalContainsPoint = null;\n this.sprite = null;\n }\n return CacheData;\n}());\nObject.defineProperties(DisplayObject.prototype, {\n /**\n * The resolution to use for cacheAsBitmap. By default this will use the renderer's resolution\n * but can be overriden for performance. Lower values will reduce memory usage at the expense\n * of render quality. A falsey value of `null` or `0` will default to the renderer's resolution.\n * If `cacheAsBitmap` is set to `true`, this will re-render with the new resolution.\n *\n * @member {number} cacheAsBitmapResolution\n * @memberof PIXI.DisplayObject#\n * @default null\n */\n cacheAsBitmapResolution: {\n get: function () {\n return this._cacheAsBitmapResolution;\n },\n set: function (resolution) {\n if (resolution === this._cacheAsBitmapResolution) {\n return;\n }\n this._cacheAsBitmapResolution = resolution;\n if (this.cacheAsBitmap) {\n // Toggle to re-render at the new resolution\n this.cacheAsBitmap = false;\n this.cacheAsBitmap = true;\n }\n },\n },\n /**\n * The number of samples to use for cacheAsBitmap. If set to `null`, the renderer's\n * sample count is used.\n * If `cacheAsBitmap` is set to `true`, this will re-render with the new number of samples.\n *\n * @member {number} cacheAsBitmapMultisample\n * @memberof PIXI.DisplayObject#\n * @default PIXI.MSAA_QUALITY.NONE\n */\n cacheAsBitmapMultisample: {\n get: function () {\n return this._cacheAsBitmapMultisample;\n },\n set: function (multisample) {\n if (multisample === this._cacheAsBitmapMultisample) {\n return;\n }\n this._cacheAsBitmapMultisample = multisample;\n if (this.cacheAsBitmap) {\n // Toggle to re-render with new multisample\n this.cacheAsBitmap = false;\n this.cacheAsBitmap = true;\n }\n },\n },\n /**\n * Set this to true if you want this display object to be cached as a bitmap.\n * This basically takes a snap shot of the display object as it is at that moment. It can\n * provide a performance benefit for complex static displayObjects.\n * To remove simply set this property to `false`\n *\n * IMPORTANT GOTCHA - Make sure that all your textures are preloaded BEFORE setting this property to true\n * as it will take a snapshot of what is currently there. If the textures have not loaded then they will not appear.\n *\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n */\n cacheAsBitmap: {\n get: function () {\n return this._cacheAsBitmap;\n },\n set: function (value) {\n if (this._cacheAsBitmap === value) {\n return;\n }\n this._cacheAsBitmap = value;\n var data;\n if (value) {\n if (!this._cacheData) {\n this._cacheData = new CacheData();\n }\n data = this._cacheData;\n data.originalRender = this.render;\n data.originalRenderCanvas = this.renderCanvas;\n data.originalUpdateTransform = this.updateTransform;\n data.originalCalculateBounds = this.calculateBounds;\n data.originalGetLocalBounds = this.getLocalBounds;\n data.originalDestroy = this.destroy;\n data.originalContainsPoint = this.containsPoint;\n data.originalMask = this._mask;\n data.originalFilterArea = this.filterArea;\n this.render = this._renderCached;\n this.renderCanvas = this._renderCachedCanvas;\n this.destroy = this._cacheAsBitmapDestroy;\n }\n else {\n data = this._cacheData;\n if (data.sprite) {\n this._destroyCachedDisplayObject();\n }\n this.render = data.originalRender;\n this.renderCanvas = data.originalRenderCanvas;\n this.calculateBounds = data.originalCalculateBounds;\n this.getLocalBounds = data.originalGetLocalBounds;\n this.destroy = data.originalDestroy;\n this.updateTransform = data.originalUpdateTransform;\n this.containsPoint = data.originalContainsPoint;\n this._mask = data.originalMask;\n this.filterArea = data.originalFilterArea;\n }\n },\n },\n});\n/**\n * Renders a cached version of the sprite with WebGL\n *\n * @private\n * @method _renderCached\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.Renderer} renderer - the WebGL renderer\n */\nDisplayObject.prototype._renderCached = function _renderCached(renderer) {\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\n return;\n }\n this._initCachedDisplayObject(renderer);\n this._cacheData.sprite.transform._worldID = this.transform._worldID;\n this._cacheData.sprite.worldAlpha = this.worldAlpha;\n this._cacheData.sprite._render(renderer);\n};\n/**\n * Prepares the WebGL renderer to cache the sprite\n *\n * @private\n * @method _initCachedDisplayObject\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.Renderer} renderer - the WebGL renderer\n */\nDisplayObject.prototype._initCachedDisplayObject = function _initCachedDisplayObject(renderer) {\n var _a;\n if (this._cacheData && this._cacheData.sprite) {\n return;\n }\n // make sure alpha is set to 1 otherwise it will get rendered as invisible!\n var cacheAlpha = this.alpha;\n this.alpha = 1;\n // first we flush anything left in the renderer (otherwise it would get rendered to the cached texture)\n renderer.batch.flush();\n // this.filters= [];\n // next we find the dimensions of the untransformed object\n // this function also calls updatetransform on all its children as part of the measuring.\n // This means we don't need to update the transform again in this function\n // TODO pass an object to clone too? saves having to create a new one each time!\n var bounds = this.getLocalBounds(null, true).clone();\n // add some padding!\n if (this.filters && this.filters.length) {\n var padding = this.filters[0].padding;\n bounds.pad(padding);\n }\n bounds.ceil(settings.RESOLUTION);\n // for now we cache the current renderTarget that the WebGL renderer is currently using.\n // this could be more elegant..\n var cachedRenderTexture = renderer.renderTexture.current;\n var cachedSourceFrame = renderer.renderTexture.sourceFrame.clone();\n var cachedDestinationFrame = renderer.renderTexture.destinationFrame.clone();\n var cachedProjectionTransform = renderer.projection.transform;\n // We also store the filter stack - I will definitely look to change how this works a little later down the line.\n // const stack = renderer.filterManager.filterStack;\n // this renderTexture will be used to store the cached DisplayObject\n var renderTexture = RenderTexture.create({\n width: bounds.width,\n height: bounds.height,\n resolution: this.cacheAsBitmapResolution || renderer.resolution,\n multisample: (_a = this.cacheAsBitmapMultisample) !== null && _a !== void 0 ? _a : renderer.multisample,\n });\n var textureCacheId = \"cacheAsBitmap_\" + uid();\n this._cacheData.textureCacheId = textureCacheId;\n BaseTexture.addToCache(renderTexture.baseTexture, textureCacheId);\n Texture.addToCache(renderTexture, textureCacheId);\n // need to set //\n var m = this.transform.localTransform.copyTo(_tempMatrix).invert().translate(-bounds.x, -bounds.y);\n // set all properties to there original so we can render to a texture\n this.render = this._cacheData.originalRender;\n renderer.render(this, { renderTexture: renderTexture, clear: true, transform: m, skipUpdateTransform: false });\n renderer.framebuffer.blit();\n // now restore the state be setting the new properties\n renderer.projection.transform = cachedProjectionTransform;\n renderer.renderTexture.bind(cachedRenderTexture, cachedSourceFrame, cachedDestinationFrame);\n // renderer.filterManager.filterStack = stack;\n this.render = this._renderCached;\n // the rest is the same as for Canvas\n this.updateTransform = this.displayObjectUpdateTransform;\n this.calculateBounds = this._calculateCachedBounds;\n this.getLocalBounds = this._getCachedLocalBounds;\n this._mask = null;\n this.filterArea = null;\n this.alpha = cacheAlpha;\n // create our cached sprite\n var cachedSprite = new Sprite(renderTexture);\n cachedSprite.transform.worldTransform = this.transform.worldTransform;\n cachedSprite.anchor.x = -(bounds.x / bounds.width);\n cachedSprite.anchor.y = -(bounds.y / bounds.height);\n cachedSprite.alpha = cacheAlpha;\n cachedSprite._bounds = this._bounds;\n this._cacheData.sprite = cachedSprite;\n this.transform._parentID = -1;\n // restore the transform of the cached sprite to avoid the nasty flicker..\n if (!this.parent) {\n this.enableTempParent();\n this.updateTransform();\n this.disableTempParent(null);\n }\n else {\n this.updateTransform();\n }\n // map the hit test..\n this.containsPoint = cachedSprite.containsPoint.bind(cachedSprite);\n};\n/**\n * Renders a cached version of the sprite with canvas\n *\n * @private\n * @method _renderCachedCanvas\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.CanvasRenderer} renderer - The canvas renderer\n */\nDisplayObject.prototype._renderCachedCanvas = function _renderCachedCanvas(renderer) {\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\n return;\n }\n this._initCachedDisplayObjectCanvas(renderer);\n this._cacheData.sprite.worldAlpha = this.worldAlpha;\n this._cacheData.sprite._renderCanvas(renderer);\n};\n// TODO this can be the same as the WebGL version.. will need to do a little tweaking first though..\n/**\n * Prepares the Canvas renderer to cache the sprite\n *\n * @private\n * @method _initCachedDisplayObjectCanvas\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.CanvasRenderer} renderer - The canvas renderer\n */\nDisplayObject.prototype._initCachedDisplayObjectCanvas = function _initCachedDisplayObjectCanvas(renderer) {\n if (this._cacheData && this._cacheData.sprite) {\n return;\n }\n // get bounds actually transforms the object for us already!\n var bounds = this.getLocalBounds(null, true);\n var cacheAlpha = this.alpha;\n this.alpha = 1;\n var cachedRenderTarget = renderer.context;\n var cachedProjectionTransform = renderer._projTransform;\n bounds.ceil(settings.RESOLUTION);\n var renderTexture = RenderTexture.create({ width: bounds.width, height: bounds.height });\n var textureCacheId = \"cacheAsBitmap_\" + uid();\n this._cacheData.textureCacheId = textureCacheId;\n BaseTexture.addToCache(renderTexture.baseTexture, textureCacheId);\n Texture.addToCache(renderTexture, textureCacheId);\n // need to set //\n var m = _tempMatrix;\n this.transform.localTransform.copyTo(m);\n m.invert();\n m.tx -= bounds.x;\n m.ty -= bounds.y;\n // m.append(this.transform.worldTransform.)\n // set all properties to there original so we can render to a texture\n this.renderCanvas = this._cacheData.originalRenderCanvas;\n renderer.render(this, { renderTexture: renderTexture, clear: true, transform: m, skipUpdateTransform: false });\n // now restore the state be setting the new properties\n renderer.context = cachedRenderTarget;\n renderer._projTransform = cachedProjectionTransform;\n this.renderCanvas = this._renderCachedCanvas;\n // the rest is the same as for WebGL\n this.updateTransform = this.displayObjectUpdateTransform;\n this.calculateBounds = this._calculateCachedBounds;\n this.getLocalBounds = this._getCachedLocalBounds;\n this._mask = null;\n this.filterArea = null;\n this.alpha = cacheAlpha;\n // create our cached sprite\n var cachedSprite = new Sprite(renderTexture);\n cachedSprite.transform.worldTransform = this.transform.worldTransform;\n cachedSprite.anchor.x = -(bounds.x / bounds.width);\n cachedSprite.anchor.y = -(bounds.y / bounds.height);\n cachedSprite.alpha = cacheAlpha;\n cachedSprite._bounds = this._bounds;\n this._cacheData.sprite = cachedSprite;\n this.transform._parentID = -1;\n // restore the transform of the cached sprite to avoid the nasty flicker..\n if (!this.parent) {\n this.parent = renderer._tempDisplayObjectParent;\n this.updateTransform();\n this.parent = null;\n }\n else {\n this.updateTransform();\n }\n // map the hit test..\n this.containsPoint = cachedSprite.containsPoint.bind(cachedSprite);\n};\n/**\n * Calculates the bounds of the cached sprite\n *\n * @private\n * @method\n */\nDisplayObject.prototype._calculateCachedBounds = function _calculateCachedBounds() {\n this._bounds.clear();\n this._cacheData.sprite.transform._worldID = this.transform._worldID;\n this._cacheData.sprite._calculateBounds();\n this._bounds.updateID = this._boundsID;\n};\n/**\n * Gets the bounds of the cached sprite.\n *\n * @private\n * @method\n * @return {Rectangle} The local bounds.\n */\nDisplayObject.prototype._getCachedLocalBounds = function _getCachedLocalBounds() {\n return this._cacheData.sprite.getLocalBounds(null);\n};\n/**\n * Destroys the cached sprite.\n *\n * @private\n * @method\n */\nDisplayObject.prototype._destroyCachedDisplayObject = function _destroyCachedDisplayObject() {\n this._cacheData.sprite._texture.destroy(true);\n this._cacheData.sprite = null;\n BaseTexture.removeFromCache(this._cacheData.textureCacheId);\n Texture.removeFromCache(this._cacheData.textureCacheId);\n this._cacheData.textureCacheId = null;\n};\n/**\n * Destroys the cached object.\n *\n * @private\n * @method\n * @param {object|boolean} [options] - Options parameter. A boolean will act as if all options\n * have been set to that value.\n * Used when destroying containers, see the Container.destroy method.\n */\nDisplayObject.prototype._cacheAsBitmapDestroy = function _cacheAsBitmapDestroy(options) {\n this.cacheAsBitmap = false;\n this.destroy(options);\n};\n\nexport { CacheData };\n//# sourceMappingURL=mixin-cache-as-bitmap.js.map\n","/*!\n * @pixi/mixin-get-child-by-name - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mixin-get-child-by-name is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { DisplayObject, Container } from '@pixi/display';\n\n/**\n * The instance name of the object.\n *\n * @memberof PIXI.DisplayObject#\n * @member {string} name\n */\nDisplayObject.prototype.name = null;\n/**\n * Returns the display object in the container.\n *\n * Recursive searches are done in a preorder traversal.\n *\n * @method getChildByName\n * @memberof PIXI.Container#\n * @param {string} name - Instance name.\n * @param {boolean}[deep=false] - Whether to search recursively\n * @return {PIXI.DisplayObject} The child with the specified name.\n */\nContainer.prototype.getChildByName = function getChildByName(name, deep) {\n for (var i = 0, j = this.children.length; i < j; i++) {\n if (this.children[i].name === name) {\n return this.children[i];\n }\n }\n if (deep) {\n for (var i = 0, j = this.children.length; i < j; i++) {\n var child = this.children[i];\n if (!child.getChildByName) {\n continue;\n }\n var target = this.children[i].getChildByName(name, true);\n if (target) {\n return target;\n }\n }\n }\n return null;\n};\n//# sourceMappingURL=mixin-get-child-by-name.js.map\n","/*!\n * @pixi/mixin-get-global-position - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mixin-get-global-position is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { DisplayObject } from '@pixi/display';\nimport { Point } from '@pixi/math';\n\n/**\n * Returns the global position of the displayObject. Does not depend on object scale, rotation and pivot.\n *\n * @method getGlobalPosition\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.Point} [point=new PIXI.Point()] - The point to write the global value to.\n * @param {boolean} [skipUpdate=false] - Setting to true will stop the transforms of the scene graph from\n * being updated. This means the calculation returned MAY be out of date BUT will give you a\n * nice performance boost.\n * @return {PIXI.Point} The updated point.\n */\nDisplayObject.prototype.getGlobalPosition = function getGlobalPosition(point, skipUpdate) {\n if (point === void 0) { point = new Point(); }\n if (skipUpdate === void 0) { skipUpdate = false; }\n if (this.parent) {\n this.parent.toGlobal(this.position, point, skipUpdate);\n }\n else {\n point.x = this.position.x;\n point.y = this.position.y;\n }\n return point;\n};\n//# sourceMappingURL=mixin-get-global-position.js.map\n","/*!\n * @pixi/mesh-extras - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mesh-extras is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { MeshGeometry, Mesh, MeshMaterial } from '@pixi/mesh';\nimport { WRAP_MODES } from '@pixi/constants';\nimport { Texture } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * @memberof PIXI\n */\nvar PlaneGeometry = /** @class */ (function (_super) {\n __extends(PlaneGeometry, _super);\n /**\n * @param width - The width of the plane.\n * @param height - The height of the plane.\n * @param segWidth - Number of horizontal segments.\n * @param segHeight - Number of vertical segments.\n */\n function PlaneGeometry(width, height, segWidth, segHeight) {\n if (width === void 0) { width = 100; }\n if (height === void 0) { height = 100; }\n if (segWidth === void 0) { segWidth = 10; }\n if (segHeight === void 0) { segHeight = 10; }\n var _this = _super.call(this) || this;\n _this.segWidth = segWidth;\n _this.segHeight = segHeight;\n _this.width = width;\n _this.height = height;\n _this.build();\n return _this;\n }\n /**\n * Refreshes plane coordinates\n * @private\n */\n PlaneGeometry.prototype.build = function () {\n var total = this.segWidth * this.segHeight;\n var verts = [];\n var uvs = [];\n var indices = [];\n var segmentsX = this.segWidth - 1;\n var segmentsY = this.segHeight - 1;\n var sizeX = (this.width) / segmentsX;\n var sizeY = (this.height) / segmentsY;\n for (var i = 0; i < total; i++) {\n var x = (i % this.segWidth);\n var y = ((i / this.segWidth) | 0);\n verts.push(x * sizeX, y * sizeY);\n uvs.push(x / segmentsX, y / segmentsY);\n }\n var totalSub = segmentsX * segmentsY;\n for (var i = 0; i < totalSub; i++) {\n var xpos = i % segmentsX;\n var ypos = (i / segmentsX) | 0;\n var value = (ypos * this.segWidth) + xpos;\n var value2 = (ypos * this.segWidth) + xpos + 1;\n var value3 = ((ypos + 1) * this.segWidth) + xpos;\n var value4 = ((ypos + 1) * this.segWidth) + xpos + 1;\n indices.push(value, value2, value3, value2, value4, value3);\n }\n this.buffers[0].data = new Float32Array(verts);\n this.buffers[1].data = new Float32Array(uvs);\n this.indexBuffer.data = new Uint16Array(indices);\n // ensure that the changes are uploaded\n this.buffers[0].update();\n this.buffers[1].update();\n this.indexBuffer.update();\n };\n return PlaneGeometry;\n}(MeshGeometry));\n\n/**\n * RopeGeometry allows you to draw a geometry across several points and then manipulate these points.\n *\n * ```js\n * for (let i = 0; i < 20; i++) {\n * points.push(new PIXI.Point(i * 50, 0));\n * };\n * const rope = new PIXI.RopeGeometry(100, points);\n * ```\n *\n * @memberof PIXI\n */\nvar RopeGeometry = /** @class */ (function (_super) {\n __extends(RopeGeometry, _super);\n /**\n * @param width - The width (i.e., thickness) of the rope.\n * @param points - An array of {@link PIXI.Point} objects to construct this rope.\n * @param textureScale - By default the rope texture will be stretched to match\n * rope length. If textureScale is positive this value will be treated as a scaling\n * factor and the texture will preserve its aspect ratio instead. To create a tiling rope\n * set baseTexture.wrapMode to {@link PIXI.WRAP_MODES.REPEAT} and use a power of two texture,\n * then set textureScale=1 to keep the original texture pixel size.\n * In order to reduce alpha channel artifacts provide a larger texture and downsample -\n * i.e. set textureScale=0.5 to scale it down twice.\n */\n function RopeGeometry(width, points, textureScale) {\n if (width === void 0) { width = 200; }\n if (textureScale === void 0) { textureScale = 0; }\n var _this = _super.call(this, new Float32Array(points.length * 4), new Float32Array(points.length * 4), new Uint16Array((points.length - 1) * 6)) || this;\n _this.points = points;\n _this._width = width;\n _this.textureScale = textureScale;\n _this.build();\n return _this;\n }\n Object.defineProperty(RopeGeometry.prototype, \"width\", {\n /**\n * The width (i.e., thickness) of the rope.\n *\n * @readOnly\n */\n get: function () {\n return this._width;\n },\n enumerable: false,\n configurable: true\n });\n /** Refreshes Rope indices and uvs */\n RopeGeometry.prototype.build = function () {\n var points = this.points;\n if (!points)\n { return; }\n var vertexBuffer = this.getBuffer('aVertexPosition');\n var uvBuffer = this.getBuffer('aTextureCoord');\n var indexBuffer = this.getIndex();\n // if too little points, or texture hasn't got UVs set yet just move on.\n if (points.length < 1) {\n return;\n }\n // if the number of points has changed we will need to recreate the arraybuffers\n if (vertexBuffer.data.length / 4 !== points.length) {\n vertexBuffer.data = new Float32Array(points.length * 4);\n uvBuffer.data = new Float32Array(points.length * 4);\n indexBuffer.data = new Uint16Array((points.length - 1) * 6);\n }\n var uvs = uvBuffer.data;\n var indices = indexBuffer.data;\n uvs[0] = 0;\n uvs[1] = 0;\n uvs[2] = 0;\n uvs[3] = 1;\n var amount = 0;\n var prev = points[0];\n var textureWidth = this._width * this.textureScale;\n var total = points.length; // - 1;\n for (var i = 0; i < total; i++) {\n // time to do some smart drawing!\n var index = i * 4;\n if (this.textureScale > 0) {\n // calculate pixel distance from previous point\n var dx = prev.x - points[i].x;\n var dy = prev.y - points[i].y;\n var distance = Math.sqrt((dx * dx) + (dy * dy));\n prev = points[i];\n amount += distance / textureWidth;\n }\n else {\n // stretch texture\n amount = i / (total - 1);\n }\n uvs[index] = amount;\n uvs[index + 1] = 0;\n uvs[index + 2] = amount;\n uvs[index + 3] = 1;\n }\n var indexCount = 0;\n for (var i = 0; i < total - 1; i++) {\n var index = i * 2;\n indices[indexCount++] = index;\n indices[indexCount++] = index + 1;\n indices[indexCount++] = index + 2;\n indices[indexCount++] = index + 2;\n indices[indexCount++] = index + 1;\n indices[indexCount++] = index + 3;\n }\n // ensure that the changes are uploaded\n uvBuffer.update();\n indexBuffer.update();\n this.updateVertices();\n };\n /**\n * refreshes vertices of Rope mesh\n */\n RopeGeometry.prototype.updateVertices = function () {\n var points = this.points;\n if (points.length < 1) {\n return;\n }\n var lastPoint = points[0];\n var nextPoint;\n var perpX = 0;\n var perpY = 0;\n var vertices = this.buffers[0].data;\n var total = points.length;\n for (var i = 0; i < total; i++) {\n var point = points[i];\n var index = i * 4;\n if (i < points.length - 1) {\n nextPoint = points[i + 1];\n }\n else {\n nextPoint = point;\n }\n perpY = -(nextPoint.x - lastPoint.x);\n perpX = nextPoint.y - lastPoint.y;\n var perpLength = Math.sqrt((perpX * perpX) + (perpY * perpY));\n var num = this.textureScale > 0 ? this.textureScale * this._width / 2 : this._width / 2;\n perpX /= perpLength;\n perpY /= perpLength;\n perpX *= num;\n perpY *= num;\n vertices[index] = point.x + perpX;\n vertices[index + 1] = point.y + perpY;\n vertices[index + 2] = point.x - perpX;\n vertices[index + 3] = point.y - perpY;\n lastPoint = point;\n }\n this.buffers[0].update();\n };\n RopeGeometry.prototype.update = function () {\n if (this.textureScale > 0) {\n this.build(); // we need to update UVs\n }\n else {\n this.updateVertices();\n }\n };\n return RopeGeometry;\n}(MeshGeometry));\n\n/**\n * The rope allows you to draw a texture across several points and then manipulate these points\n *\n *```js\n * for (let i = 0; i < 20; i++) {\n * points.push(new PIXI.Point(i * 50, 0));\n * };\n * let rope = new PIXI.SimpleRope(PIXI.Texture.from(\"snake.png\"), points);\n * ```\n *\n * @memberof PIXI\n */\nvar SimpleRope = /** @class */ (function (_super) {\n __extends(SimpleRope, _super);\n /**\n * @param texture - The texture to use on the rope.\n * @param points - An array of {@link PIXI.Point} objects to construct this rope.\n * @param {number} textureScale - Optional. Positive values scale rope texture\n * keeping its aspect ratio. You can reduce alpha channel artifacts by providing a larger texture\n * and downsampling here. If set to zero, texture will be stretched instead.\n */\n function SimpleRope(texture, points, textureScale) {\n if (textureScale === void 0) { textureScale = 0; }\n var _this = this;\n var ropeGeometry = new RopeGeometry(texture.height, points, textureScale);\n var meshMaterial = new MeshMaterial(texture);\n if (textureScale > 0) {\n // attempt to set UV wrapping, will fail on non-power of two textures\n texture.baseTexture.wrapMode = WRAP_MODES.REPEAT;\n }\n _this = _super.call(this, ropeGeometry, meshMaterial) || this;\n /**\n * re-calculate vertices by rope points each frame\n *\n * @member {boolean}\n */\n _this.autoUpdate = true;\n return _this;\n }\n SimpleRope.prototype._render = function (renderer) {\n var geometry = this.geometry;\n if (this.autoUpdate || geometry._width !== this.shader.texture.height) {\n geometry._width = this.shader.texture.height;\n geometry.update();\n }\n _super.prototype._render.call(this, renderer);\n };\n return SimpleRope;\n}(Mesh));\n\n/**\n * The SimplePlane allows you to draw a texture across several points and then manipulate these points\n *\n *```js\n * for (let i = 0; i < 20; i++) {\n * points.push(new PIXI.Point(i * 50, 0));\n * };\n * let SimplePlane = new PIXI.SimplePlane(PIXI.Texture.from(\"snake.png\"), points);\n * ```\n *\n * @memberof PIXI\n */\nvar SimplePlane = /** @class */ (function (_super) {\n __extends(SimplePlane, _super);\n /**\n * @param texture - The texture to use on the SimplePlane.\n * @param verticesX - The number of vertices in the x-axis\n * @param verticesY - The number of vertices in the y-axis\n */\n function SimplePlane(texture, verticesX, verticesY) {\n var _this = this;\n var planeGeometry = new PlaneGeometry(texture.width, texture.height, verticesX, verticesY);\n var meshMaterial = new MeshMaterial(Texture.WHITE);\n _this = _super.call(this, planeGeometry, meshMaterial) || this;\n // lets call the setter to ensure all necessary updates are performed\n _this.texture = texture;\n _this.autoResize = true;\n return _this;\n }\n /**\n * Method used for overrides, to do something in case texture frame was changed.\n * Meshes based on plane can override it and change more details based on texture.\n */\n SimplePlane.prototype.textureUpdated = function () {\n this._textureID = this.shader.texture._updateID;\n var geometry = this.geometry;\n var _a = this.shader.texture, width = _a.width, height = _a.height;\n if (this.autoResize && (geometry.width !== width || geometry.height !== height)) {\n geometry.width = this.shader.texture.width;\n geometry.height = this.shader.texture.height;\n geometry.build();\n }\n };\n Object.defineProperty(SimplePlane.prototype, \"texture\", {\n get: function () {\n return this.shader.texture;\n },\n set: function (value) {\n // Track texture same way sprite does.\n // For generated meshes like NineSlicePlane it can change the geometry.\n // Unfortunately, this method might not work if you directly change texture in material.\n if (this.shader.texture === value) {\n return;\n }\n this.shader.texture = value;\n this._textureID = -1;\n if (value.baseTexture.valid) {\n this.textureUpdated();\n }\n else {\n value.once('update', this.textureUpdated, this);\n }\n },\n enumerable: false,\n configurable: true\n });\n SimplePlane.prototype._render = function (renderer) {\n if (this._textureID !== this.shader.texture._updateID) {\n this.textureUpdated();\n }\n _super.prototype._render.call(this, renderer);\n };\n SimplePlane.prototype.destroy = function (options) {\n this.shader.texture.off('update', this.textureUpdated, this);\n _super.prototype.destroy.call(this, options);\n };\n return SimplePlane;\n}(Mesh));\n\n/**\n * The Simple Mesh class mimics Mesh in PixiJS v4, providing easy-to-use constructor arguments.\n * For more robust customization, use {@link PIXI.Mesh}.\n *\n * @memberof PIXI\n */\nvar SimpleMesh = /** @class */ (function (_super) {\n __extends(SimpleMesh, _super);\n /**\n * @param texture - The texture to use\n * @param {Float32Array} [vertices] - if you want to specify the vertices\n * @param {Float32Array} [uvs] - if you want to specify the uvs\n * @param {Uint16Array} [indices] - if you want to specify the indices\n * @param drawMode - the drawMode, can be any of the Mesh.DRAW_MODES consts\n */\n function SimpleMesh(texture, vertices, uvs, indices, drawMode) {\n if (texture === void 0) { texture = Texture.EMPTY; }\n var _this = this;\n var geometry = new MeshGeometry(vertices, uvs, indices);\n geometry.getBuffer('aVertexPosition').static = false;\n var meshMaterial = new MeshMaterial(texture);\n _this = _super.call(this, geometry, meshMaterial, null, drawMode) || this;\n _this.autoUpdate = true;\n return _this;\n }\n Object.defineProperty(SimpleMesh.prototype, \"vertices\", {\n /**\n * Collection of vertices data.\n * @type {Float32Array}\n */\n get: function () {\n return this.geometry.getBuffer('aVertexPosition').data;\n },\n set: function (value) {\n this.geometry.getBuffer('aVertexPosition').data = value;\n },\n enumerable: false,\n configurable: true\n });\n SimpleMesh.prototype._render = function (renderer) {\n if (this.autoUpdate) {\n this.geometry.getBuffer('aVertexPosition').update();\n }\n _super.prototype._render.call(this, renderer);\n };\n return SimpleMesh;\n}(Mesh));\n\nvar DEFAULT_BORDER_SIZE = 10;\n/**\n * The NineSlicePlane allows you to stretch a texture using 9-slice scaling. The corners will remain unscaled (useful\n * for buttons with rounded corners for example) and the other areas will be scaled horizontally and or vertically\n *\n *```js\n * let Plane9 = new PIXI.NineSlicePlane(PIXI.Texture.from('BoxWithRoundedCorners.png'), 15, 15, 15, 15);\n * ```\n * <pre>\n * A B\n * +---+----------------------+---+\n * C | 1 | 2 | 3 |\n * +---+----------------------+---+\n * | | | |\n * | 4 | 5 | 6 |\n * | | | |\n * +---+----------------------+---+\n * D | 7 | 8 | 9 |\n * +---+----------------------+---+\n\n * When changing this objects width and/or height:\n * areas 1 3 7 and 9 will remain unscaled.\n * areas 2 and 8 will be stretched horizontally\n * areas 4 and 6 will be stretched vertically\n * area 5 will be stretched both horizontally and vertically\n * </pre>\n *\n * @memberof PIXI\n */\nvar NineSlicePlane = /** @class */ (function (_super) {\n __extends(NineSlicePlane, _super);\n /**\n * @param texture - The texture to use on the NineSlicePlane.\n * @param {number} [leftWidth=10] - size of the left vertical bar (A)\n * @param {number} [topHeight=10] - size of the top horizontal bar (C)\n * @param {number} [rightWidth=10] - size of the right vertical bar (B)\n * @param {number} [bottomHeight=10] - size of the bottom horizontal bar (D)\n */\n function NineSlicePlane(texture, leftWidth, topHeight, rightWidth, bottomHeight) {\n if (leftWidth === void 0) { leftWidth = DEFAULT_BORDER_SIZE; }\n if (topHeight === void 0) { topHeight = DEFAULT_BORDER_SIZE; }\n if (rightWidth === void 0) { rightWidth = DEFAULT_BORDER_SIZE; }\n if (bottomHeight === void 0) { bottomHeight = DEFAULT_BORDER_SIZE; }\n var _this = _super.call(this, Texture.WHITE, 4, 4) || this;\n _this._origWidth = texture.orig.width;\n _this._origHeight = texture.orig.height;\n /** The width of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n _this._width = _this._origWidth;\n /** The height of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n _this._height = _this._origHeight;\n _this._leftWidth = leftWidth;\n _this._rightWidth = rightWidth;\n _this._topHeight = topHeight;\n _this._bottomHeight = bottomHeight;\n // lets call the setter to ensure all necessary updates are performed\n _this.texture = texture;\n return _this;\n }\n NineSlicePlane.prototype.textureUpdated = function () {\n this._textureID = this.shader.texture._updateID;\n this._refresh();\n };\n Object.defineProperty(NineSlicePlane.prototype, \"vertices\", {\n get: function () {\n return this.geometry.getBuffer('aVertexPosition').data;\n },\n set: function (value) {\n this.geometry.getBuffer('aVertexPosition').data = value;\n },\n enumerable: false,\n configurable: true\n });\n /** Updates the horizontal vertices. */\n NineSlicePlane.prototype.updateHorizontalVertices = function () {\n var vertices = this.vertices;\n var scale = this._getMinScale();\n vertices[9] = vertices[11] = vertices[13] = vertices[15] = this._topHeight * scale;\n vertices[17] = vertices[19] = vertices[21] = vertices[23] = this._height - (this._bottomHeight * scale);\n vertices[25] = vertices[27] = vertices[29] = vertices[31] = this._height;\n };\n /** Updates the vertical vertices. */\n NineSlicePlane.prototype.updateVerticalVertices = function () {\n var vertices = this.vertices;\n var scale = this._getMinScale();\n vertices[2] = vertices[10] = vertices[18] = vertices[26] = this._leftWidth * scale;\n vertices[4] = vertices[12] = vertices[20] = vertices[28] = this._width - (this._rightWidth * scale);\n vertices[6] = vertices[14] = vertices[22] = vertices[30] = this._width;\n };\n /**\n * Returns the smaller of a set of vertical and horizontal scale of nine slice corners.\n *\n * @return Smaller number of vertical and horizontal scale.\n */\n NineSlicePlane.prototype._getMinScale = function () {\n var w = this._leftWidth + this._rightWidth;\n var scaleW = this._width > w ? 1.0 : this._width / w;\n var h = this._topHeight + this._bottomHeight;\n var scaleH = this._height > h ? 1.0 : this._height / h;\n var scale = Math.min(scaleW, scaleH);\n return scale;\n };\n Object.defineProperty(NineSlicePlane.prototype, \"width\", {\n /** The width of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n get: function () {\n return this._width;\n },\n set: function (value) {\n this._width = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"height\", {\n /** The height of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n get: function () {\n return this._height;\n },\n set: function (value) {\n this._height = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"leftWidth\", {\n /** The width of the left column. */\n get: function () {\n return this._leftWidth;\n },\n set: function (value) {\n this._leftWidth = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"rightWidth\", {\n /** The width of the right column. */\n get: function () {\n return this._rightWidth;\n },\n set: function (value) {\n this._rightWidth = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"topHeight\", {\n /** The height of the top row. */\n get: function () {\n return this._topHeight;\n },\n set: function (value) {\n this._topHeight = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"bottomHeight\", {\n /** The height of the bottom row. */\n get: function () {\n return this._bottomHeight;\n },\n set: function (value) {\n this._bottomHeight = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n /** Refreshes NineSlicePlane coords. All of them. */\n NineSlicePlane.prototype._refresh = function () {\n var texture = this.texture;\n var uvs = this.geometry.buffers[1].data;\n this._origWidth = texture.orig.width;\n this._origHeight = texture.orig.height;\n var _uvw = 1.0 / this._origWidth;\n var _uvh = 1.0 / this._origHeight;\n uvs[0] = uvs[8] = uvs[16] = uvs[24] = 0;\n uvs[1] = uvs[3] = uvs[5] = uvs[7] = 0;\n uvs[6] = uvs[14] = uvs[22] = uvs[30] = 1;\n uvs[25] = uvs[27] = uvs[29] = uvs[31] = 1;\n uvs[2] = uvs[10] = uvs[18] = uvs[26] = _uvw * this._leftWidth;\n uvs[4] = uvs[12] = uvs[20] = uvs[28] = 1 - (_uvw * this._rightWidth);\n uvs[9] = uvs[11] = uvs[13] = uvs[15] = _uvh * this._topHeight;\n uvs[17] = uvs[19] = uvs[21] = uvs[23] = 1 - (_uvh * this._bottomHeight);\n this.updateHorizontalVertices();\n this.updateVerticalVertices();\n this.geometry.buffers[0].update();\n this.geometry.buffers[1].update();\n };\n return NineSlicePlane;\n}(SimplePlane));\n\nexport { NineSlicePlane, PlaneGeometry, RopeGeometry, SimpleMesh, SimplePlane, SimpleRope };\n//# sourceMappingURL=mesh-extras.js.map\n","/*!\n * @pixi/sprite-animated - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/sprite-animated is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture } from '@pixi/core';\nimport { Sprite } from '@pixi/sprite';\nimport { Ticker, UPDATE_PRIORITY } from '@pixi/ticker';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * An AnimatedSprite is a simple way to display an animation depicted by a list of textures.\n *\n * ```js\n * let alienImages = [\"image_sequence_01.png\",\"image_sequence_02.png\",\"image_sequence_03.png\",\"image_sequence_04.png\"];\n * let textureArray = [];\n *\n * for (let i=0; i < 4; i++)\n * {\n * let texture = PIXI.Texture.from(alienImages[i]);\n * textureArray.push(texture);\n * };\n *\n * let animatedSprite = new PIXI.AnimatedSprite(textureArray);\n * ```\n *\n * The more efficient and simpler way to create an animated sprite is using a {@link PIXI.Spritesheet}\n * containing the animation definitions:\n *\n * ```js\n * PIXI.Loader.shared.add(\"assets/spritesheet.json\").load(setup);\n *\n * function setup() {\n * let sheet = PIXI.Loader.shared.resources[\"assets/spritesheet.json\"].spritesheet;\n * animatedSprite = new PIXI.AnimatedSprite(sheet.animations[\"image_sequence\"]);\n * ...\n * }\n * ```\n *\n * @memberof PIXI\n */\nvar AnimatedSprite = /** @class */ (function (_super) {\n __extends(AnimatedSprite, _super);\n /**\n * @param textures - An array of {@link PIXI.Texture} or frame\n * objects that make up the animation.\n * @param {boolean} [autoUpdate=true] - Whether to use PIXI.Ticker.shared to auto update animation time.\n */\n function AnimatedSprite(textures, autoUpdate) {\n if (autoUpdate === void 0) { autoUpdate = true; }\n var _this = _super.call(this, textures[0] instanceof Texture ? textures[0] : textures[0].texture) || this;\n _this._textures = null;\n _this._durations = null;\n _this._autoUpdate = autoUpdate;\n _this._isConnectedToTicker = false;\n _this.animationSpeed = 1;\n _this.loop = true;\n _this.updateAnchor = false;\n _this.onComplete = null;\n _this.onFrameChange = null;\n _this.onLoop = null;\n _this._currentTime = 0;\n _this._playing = false;\n _this._previousFrame = null;\n _this.textures = textures;\n return _this;\n }\n /** Stops the AnimatedSprite. */\n AnimatedSprite.prototype.stop = function () {\n if (!this._playing) {\n return;\n }\n this._playing = false;\n if (this._autoUpdate && this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n };\n /** Plays the AnimatedSprite. */\n AnimatedSprite.prototype.play = function () {\n if (this._playing) {\n return;\n }\n this._playing = true;\n if (this._autoUpdate && !this._isConnectedToTicker) {\n Ticker.shared.add(this.update, this, UPDATE_PRIORITY.HIGH);\n this._isConnectedToTicker = true;\n }\n };\n /**\n * Stops the AnimatedSprite and goes to a specific frame.\n *\n * @param frameNumber - Frame index to stop at.\n */\n AnimatedSprite.prototype.gotoAndStop = function (frameNumber) {\n this.stop();\n var previousFrame = this.currentFrame;\n this._currentTime = frameNumber;\n if (previousFrame !== this.currentFrame) {\n this.updateTexture();\n }\n };\n /**\n * Goes to a specific frame and begins playing the AnimatedSprite.\n *\n * @param frameNumber - Frame index to start at.\n */\n AnimatedSprite.prototype.gotoAndPlay = function (frameNumber) {\n var previousFrame = this.currentFrame;\n this._currentTime = frameNumber;\n if (previousFrame !== this.currentFrame) {\n this.updateTexture();\n }\n this.play();\n };\n /**\n * Updates the object transform for rendering.\n *\n * @param deltaTime - Time since last tick.\n */\n AnimatedSprite.prototype.update = function (deltaTime) {\n if (!this._playing) {\n return;\n }\n var elapsed = this.animationSpeed * deltaTime;\n var previousFrame = this.currentFrame;\n if (this._durations !== null) {\n var lag = this._currentTime % 1 * this._durations[this.currentFrame];\n lag += elapsed / 60 * 1000;\n while (lag < 0) {\n this._currentTime--;\n lag += this._durations[this.currentFrame];\n }\n var sign = Math.sign(this.animationSpeed * deltaTime);\n this._currentTime = Math.floor(this._currentTime);\n while (lag >= this._durations[this.currentFrame]) {\n lag -= this._durations[this.currentFrame] * sign;\n this._currentTime += sign;\n }\n this._currentTime += lag / this._durations[this.currentFrame];\n }\n else {\n this._currentTime += elapsed;\n }\n if (this._currentTime < 0 && !this.loop) {\n this.gotoAndStop(0);\n if (this.onComplete) {\n this.onComplete();\n }\n }\n else if (this._currentTime >= this._textures.length && !this.loop) {\n this.gotoAndStop(this._textures.length - 1);\n if (this.onComplete) {\n this.onComplete();\n }\n }\n else if (previousFrame !== this.currentFrame) {\n if (this.loop && this.onLoop) {\n if (this.animationSpeed > 0 && this.currentFrame < previousFrame) {\n this.onLoop();\n }\n else if (this.animationSpeed < 0 && this.currentFrame > previousFrame) {\n this.onLoop();\n }\n }\n this.updateTexture();\n }\n };\n /** Updates the displayed texture to match the current frame index. */\n AnimatedSprite.prototype.updateTexture = function () {\n var currentFrame = this.currentFrame;\n if (this._previousFrame === currentFrame) {\n return;\n }\n this._previousFrame = currentFrame;\n this._texture = this._textures[currentFrame];\n this._textureID = -1;\n this._textureTrimmedID = -1;\n this._cachedTint = 0xFFFFFF;\n this.uvs = this._texture._uvs.uvsFloat32;\n if (this.updateAnchor) {\n this._anchor.copyFrom(this._texture.defaultAnchor);\n }\n if (this.onFrameChange) {\n this.onFrameChange(this.currentFrame);\n }\n };\n /**\n * Stops the AnimatedSprite and destroys it.\n *\n * @param {object|boolean} [options] - Options parameter. A boolean will act as if all options\n * have been set to that value.\n * @param {boolean} [options.children=false] - If set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Should it destroy the current texture of the sprite as well.\n * @param {boolean} [options.baseTexture=false] - Should it destroy the base texture of the sprite as well.\n */\n AnimatedSprite.prototype.destroy = function (options) {\n this.stop();\n _super.prototype.destroy.call(this, options);\n this.onComplete = null;\n this.onFrameChange = null;\n this.onLoop = null;\n };\n /**\n * A short hand way of creating an AnimatedSprite from an array of frame ids.\n *\n * @param frames - The array of frames ids the AnimatedSprite will use as its texture frames.\n * @return - The new animated sprite with the specified frames.\n */\n AnimatedSprite.fromFrames = function (frames) {\n var textures = [];\n for (var i = 0; i < frames.length; ++i) {\n textures.push(Texture.from(frames[i]));\n }\n return new AnimatedSprite(textures);\n };\n /**\n * A short hand way of creating an AnimatedSprite from an array of image ids.\n *\n * @param images - The array of image urls the AnimatedSprite will use as its texture frames.\n * @return The new animate sprite with the specified images as frames.\n */\n AnimatedSprite.fromImages = function (images) {\n var textures = [];\n for (var i = 0; i < images.length; ++i) {\n textures.push(Texture.from(images[i]));\n }\n return new AnimatedSprite(textures);\n };\n Object.defineProperty(AnimatedSprite.prototype, \"totalFrames\", {\n /**\n * The total number of frames in the AnimatedSprite. This is the same as number of textures\n * assigned to the AnimatedSprite.\n *\n * @readonly\n * @default 0\n */\n get: function () {\n return this._textures.length;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"textures\", {\n /** The array of textures used for this AnimatedSprite. */\n get: function () {\n return this._textures;\n },\n set: function (value) {\n if (value[0] instanceof Texture) {\n this._textures = value;\n this._durations = null;\n }\n else {\n this._textures = [];\n this._durations = [];\n for (var i = 0; i < value.length; i++) {\n this._textures.push(value[i].texture);\n this._durations.push(value[i].time);\n }\n }\n this._previousFrame = null;\n this.gotoAndStop(0);\n this.updateTexture();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"currentFrame\", {\n /**\n * The AnimatedSprites current frame index.\n *\n * @readonly\n */\n get: function () {\n var currentFrame = Math.floor(this._currentTime) % this._textures.length;\n if (currentFrame < 0) {\n currentFrame += this._textures.length;\n }\n return currentFrame;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"playing\", {\n /**\n * Indicates if the AnimatedSprite is currently playing.\n *\n * @readonly\n */\n get: function () {\n return this._playing;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"autoUpdate\", {\n /** Whether to use PIXI.Ticker.shared to auto update animation time. */\n get: function () {\n return this._autoUpdate;\n },\n set: function (value) {\n if (value !== this._autoUpdate) {\n this._autoUpdate = value;\n if (!this._autoUpdate && this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n else if (this._autoUpdate && !this._isConnectedToTicker && this._playing) {\n Ticker.shared.add(this.update, this);\n this._isConnectedToTicker = true;\n }\n }\n },\n enumerable: false,\n configurable: true\n });\n return AnimatedSprite;\n}(Sprite));\n\nexport { AnimatedSprite };\n//# sourceMappingURL=sprite-animated.js.map\n","/*!\n * pixi.js - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * pixi.js is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport '@pixi/polyfill';\nimport * as utils from '@pixi/utils';\nexport { utils };\nimport { AccessibilityManager } from '@pixi/accessibility';\nexport * from '@pixi/accessibility';\nimport { InteractionManager } from '@pixi/interaction';\nexport * from '@pixi/interaction';\nimport { Application } from '@pixi/app';\nexport * from '@pixi/app';\nimport { Renderer, BatchRenderer } from '@pixi/core';\nexport * from '@pixi/core';\nimport { Extract } from '@pixi/extract';\nexport * from '@pixi/extract';\nimport { Loader, AppLoaderPlugin } from '@pixi/loaders';\nexport * from '@pixi/loaders';\nimport { CompressedTextureLoader, DDSLoader, KTXLoader } from '@pixi/compressed-textures';\nexport * from '@pixi/compressed-textures';\nimport { ParticleRenderer } from '@pixi/particle-container';\nexport * from '@pixi/particle-container';\nimport { Prepare } from '@pixi/prepare';\nexport * from '@pixi/prepare';\nimport { SpritesheetLoader } from '@pixi/spritesheet';\nexport * from '@pixi/spritesheet';\nimport { TilingSpriteRenderer } from '@pixi/sprite-tiling';\nexport * from '@pixi/sprite-tiling';\nimport { BitmapFontLoader } from '@pixi/text-bitmap';\nexport * from '@pixi/text-bitmap';\nimport { TickerPlugin } from '@pixi/ticker';\nexport * from '@pixi/ticker';\nimport { AlphaFilter } from '@pixi/filter-alpha';\nimport { BlurFilter, BlurFilterPass } from '@pixi/filter-blur';\nimport { ColorMatrixFilter } from '@pixi/filter-color-matrix';\nimport { DisplacementFilter } from '@pixi/filter-displacement';\nimport { FXAAFilter } from '@pixi/filter-fxaa';\nimport { NoiseFilter } from '@pixi/filter-noise';\nimport '@pixi/mixin-cache-as-bitmap';\nimport '@pixi/mixin-get-child-by-name';\nimport '@pixi/mixin-get-global-position';\nexport * from '@pixi/constants';\nexport * from '@pixi/display';\nexport * from '@pixi/graphics';\nexport * from '@pixi/math';\nexport * from '@pixi/mesh';\nexport * from '@pixi/mesh-extras';\nexport * from '@pixi/runner';\nexport * from '@pixi/sprite';\nexport * from '@pixi/sprite-animated';\nexport * from '@pixi/text';\nexport * from '@pixi/settings';\n\n// Install renderer plugins\nRenderer.registerPlugin('accessibility', AccessibilityManager);\nRenderer.registerPlugin('extract', Extract);\nRenderer.registerPlugin('interaction', InteractionManager);\nRenderer.registerPlugin('particle', ParticleRenderer);\nRenderer.registerPlugin('prepare', Prepare);\nRenderer.registerPlugin('batch', BatchRenderer);\nRenderer.registerPlugin('tilingSprite', TilingSpriteRenderer);\n// Install loader plugins\nLoader.registerPlugin(BitmapFontLoader);\nLoader.registerPlugin(CompressedTextureLoader);\nLoader.registerPlugin(DDSLoader);\nLoader.registerPlugin(KTXLoader);\nLoader.registerPlugin(SpritesheetLoader);\n// Install application plugins\nApplication.registerPlugin(TickerPlugin);\nApplication.registerPlugin(AppLoaderPlugin);\n/**\n * String of the current PIXI version.\n *\n * @static\n * @constant\n * @memberof PIXI\n * @name VERSION\n * @type {string}\n */\nvar VERSION = '6.3.0';\n/**\n * @namespace PIXI\n */\n/**\n * This namespace contains WebGL-only display filters that can be applied\n * to DisplayObjects using the {@link PIXI.DisplayObject#filters filters} property.\n *\n * Since PixiJS only had a handful of built-in filters, additional filters\n * can be downloaded {@link https://github.com/pixijs/pixi-filters here} from the\n * PixiJS Filters repository.\n *\n * All filters must extend {@link PIXI.Filter}.\n *\n * @example\n * // Create a new application\n * const app = new PIXI.Application();\n *\n * // Draw a green rectangle\n * const rect = new PIXI.Graphics()\n * .beginFill(0x00ff00)\n * .drawRect(40, 40, 200, 200);\n *\n * // Add a blur filter\n * rect.filters = [new PIXI.filters.BlurFilter()];\n *\n * // Display rectangle\n * app.stage.addChild(rect);\n * document.body.appendChild(app.view);\n * @namespace PIXI.filters\n */\nvar filters = {\n AlphaFilter: AlphaFilter,\n BlurFilter: BlurFilter,\n BlurFilterPass: BlurFilterPass,\n ColorMatrixFilter: ColorMatrixFilter,\n DisplacementFilter: DisplacementFilter,\n FXAAFilter: FXAAFilter,\n NoiseFilter: NoiseFilter,\n};\n\nexport { VERSION, filters };\n//# sourceMappingURL=pixi.js.map\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\n// If obj.hasOwnProperty has been overridden, then calling\n// obj.hasOwnProperty(prop) will break.\n// See: https://github.com/joyent/node/issues/1707\nfunction hasOwnProperty(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\nmodule.exports = function(qs, sep, eq, options) {\n sep = sep || '&';\n eq = eq || '=';\n var obj = {};\n\n if (typeof qs !== 'string' || qs.length === 0) {\n return obj;\n }\n\n var regexp = /\\+/g;\n qs = qs.split(sep);\n\n var maxKeys = 1000;\n if (options && typeof options.maxKeys === 'number') {\n maxKeys = options.maxKeys;\n }\n\n var len = qs.length;\n // maxKeys <= 0 means that we should not limit keys count\n if (maxKeys > 0 && len > maxKeys) {\n len = maxKeys;\n }\n\n for (var i = 0; i < len; ++i) {\n var x = qs[i].replace(regexp, '%20'),\n idx = x.indexOf(eq),\n kstr, vstr, k, v;\n\n if (idx >= 0) {\n kstr = x.substr(0, idx);\n vstr = x.substr(idx + 1);\n } else {\n kstr = x;\n vstr = '';\n }\n\n k = decodeURIComponent(kstr);\n v = decodeURIComponent(vstr);\n\n if (!hasOwnProperty(obj, k)) {\n obj[k] = v;\n } else if (Array.isArray(obj[k])) {\n obj[k].push(v);\n } else {\n obj[k] = [obj[k], v];\n }\n }\n\n return obj;\n};\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\nvar stringifyPrimitive = function(v) {\n switch (typeof v) {\n case 'string':\n return v;\n\n case 'boolean':\n return v ? 'true' : 'false';\n\n case 'number':\n return isFinite(v) ? v : '';\n\n default:\n return '';\n }\n};\n\nmodule.exports = function(obj, sep, eq, name) {\n sep = sep || '&';\n eq = eq || '=';\n if (obj === null) {\n obj = undefined;\n }\n\n if (typeof obj === 'object') {\n return Object.keys(obj).map(function(k) {\n var ks = encodeURIComponent(stringifyPrimitive(k)) + eq;\n if (Array.isArray(obj[k])) {\n return obj[k].map(function(v) {\n return ks + encodeURIComponent(stringifyPrimitive(v));\n }).join(sep);\n } else {\n return ks + encodeURIComponent(stringifyPrimitive(obj[k]));\n }\n }).join(sep);\n\n }\n\n if (!name) return '';\n return encodeURIComponent(stringifyPrimitive(name)) + eq +\n encodeURIComponent(stringifyPrimitive(obj));\n};\n","'use strict';\n\nexports.decode = exports.parse = require('./decode');\nexports.encode = exports.stringify = require('./encode');\n","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function define(obj, key, value) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n return obj[key];\n }\n try {\n // IE 8 has a broken Object.defineProperty that only works on DOM objects.\n define({}, \"\");\n } catch (err) {\n define = function(obj, key, value) {\n return obj[key] = value;\n };\n }\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n define(IteratorPrototype, iteratorSymbol, function () {\n return this;\n });\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = GeneratorFunctionPrototype;\n define(Gp, \"constructor\", GeneratorFunctionPrototype);\n define(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction);\n GeneratorFunction.displayName = define(\n GeneratorFunctionPrototype,\n toStringTagSymbol,\n \"GeneratorFunction\"\n );\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n define(prototype, method, function(arg) {\n return this._invoke(method, arg);\n });\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n define(genFun, toStringTagSymbol, \"GeneratorFunction\");\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator, PromiseImpl) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return PromiseImpl.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return PromiseImpl.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new PromiseImpl(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n define(AsyncIterator.prototype, asyncIteratorSymbol, function () {\n return this;\n });\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {\n if (PromiseImpl === void 0) PromiseImpl = Promise;\n\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList),\n PromiseImpl\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n define(Gp, toStringTagSymbol, \"Generator\");\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n define(Gp, iteratorSymbol, function() {\n return this;\n });\n\n define(Gp, \"toString\", function() {\n return \"[object Generator]\";\n });\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, in modern engines\n // we can explicitly access globalThis. In older engines we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n if (typeof globalThis === \"object\") {\n globalThis.regeneratorRuntime = runtime;\n } else {\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n }\n}\n","/**!\n * Sortable 1.14.0\n * @author\tRubaXa <trash@rubaxa.org>\n * @author\towenm <owen23355@gmail.com>\n * @license MIT\n */\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n\n if (enumerableOnly) {\n symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n }\n\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nfunction _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}\n\nfunction _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function (obj) {\n return typeof obj;\n };\n } else {\n _typeof = function (obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}\n\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}\n\nfunction _extends() {\n _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n };\n\n return _extends.apply(this, arguments);\n}\n\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n\n return target;\n}\n\nfunction _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n\n var target = _objectWithoutPropertiesLoose(source, excluded);\n\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}\n\nfunction _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n}\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n}\n\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n}\n\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];\n\n return arr2;\n}\n\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n\nvar version = \"1.14.0\";\n\nfunction userAgent(pattern) {\n if (typeof window !== 'undefined' && window.navigator) {\n return !! /*@__PURE__*/navigator.userAgent.match(pattern);\n }\n}\n\nvar IE11OrLess = userAgent(/(?:Trident.*rv[ :]?11\\.|msie|iemobile|Windows Phone)/i);\nvar Edge = userAgent(/Edge/i);\nvar FireFox = userAgent(/firefox/i);\nvar Safari = userAgent(/safari/i) && !userAgent(/chrome/i) && !userAgent(/android/i);\nvar IOS = userAgent(/iP(ad|od|hone)/i);\nvar ChromeForAndroid = userAgent(/chrome/i) && userAgent(/android/i);\n\nvar captureMode = {\n capture: false,\n passive: false\n};\n\nfunction on(el, event, fn) {\n el.addEventListener(event, fn, !IE11OrLess && captureMode);\n}\n\nfunction off(el, event, fn) {\n el.removeEventListener(event, fn, !IE11OrLess && captureMode);\n}\n\nfunction matches(\n/**HTMLElement*/\nel,\n/**String*/\nselector) {\n if (!selector) return;\n selector[0] === '>' && (selector = selector.substring(1));\n\n if (el) {\n try {\n if (el.matches) {\n return el.matches(selector);\n } else if (el.msMatchesSelector) {\n return el.msMatchesSelector(selector);\n } else if (el.webkitMatchesSelector) {\n return el.webkitMatchesSelector(selector);\n }\n } catch (_) {\n return false;\n }\n }\n\n return false;\n}\n\nfunction getParentOrHost(el) {\n return el.host && el !== document && el.host.nodeType ? el.host : el.parentNode;\n}\n\nfunction closest(\n/**HTMLElement*/\nel,\n/**String*/\nselector,\n/**HTMLElement*/\nctx, includeCTX) {\n if (el) {\n ctx = ctx || document;\n\n do {\n if (selector != null && (selector[0] === '>' ? el.parentNode === ctx && matches(el, selector) : matches(el, selector)) || includeCTX && el === ctx) {\n return el;\n }\n\n if (el === ctx) break;\n /* jshint boss:true */\n } while (el = getParentOrHost(el));\n }\n\n return null;\n}\n\nvar R_SPACE = /\\s+/g;\n\nfunction toggleClass(el, name, state) {\n if (el && name) {\n if (el.classList) {\n el.classList[state ? 'add' : 'remove'](name);\n } else {\n var className = (' ' + el.className + ' ').replace(R_SPACE, ' ').replace(' ' + name + ' ', ' ');\n el.className = (className + (state ? ' ' + name : '')).replace(R_SPACE, ' ');\n }\n }\n}\n\nfunction css(el, prop, val) {\n var style = el && el.style;\n\n if (style) {\n if (val === void 0) {\n if (document.defaultView && document.defaultView.getComputedStyle) {\n val = document.defaultView.getComputedStyle(el, '');\n } else if (el.currentStyle) {\n val = el.currentStyle;\n }\n\n return prop === void 0 ? val : val[prop];\n } else {\n if (!(prop in style) && prop.indexOf('webkit') === -1) {\n prop = '-webkit-' + prop;\n }\n\n style[prop] = val + (typeof val === 'string' ? '' : 'px');\n }\n }\n}\n\nfunction matrix(el, selfOnly) {\n var appliedTransforms = '';\n\n if (typeof el === 'string') {\n appliedTransforms = el;\n } else {\n do {\n var transform = css(el, 'transform');\n\n if (transform && transform !== 'none') {\n appliedTransforms = transform + ' ' + appliedTransforms;\n }\n /* jshint boss:true */\n\n } while (!selfOnly && (el = el.parentNode));\n }\n\n var matrixFn = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;\n /*jshint -W056 */\n\n return matrixFn && new matrixFn(appliedTransforms);\n}\n\nfunction find(ctx, tagName, iterator) {\n if (ctx) {\n var list = ctx.getElementsByTagName(tagName),\n i = 0,\n n = list.length;\n\n if (iterator) {\n for (; i < n; i++) {\n iterator(list[i], i);\n }\n }\n\n return list;\n }\n\n return [];\n}\n\nfunction getWindowScrollingElement() {\n var scrollingElement = document.scrollingElement;\n\n if (scrollingElement) {\n return scrollingElement;\n } else {\n return document.documentElement;\n }\n}\n/**\n * Returns the \"bounding client rect\" of given element\n * @param {HTMLElement} el The element whose boundingClientRect is wanted\n * @param {[Boolean]} relativeToContainingBlock Whether the rect should be relative to the containing block of (including) the container\n * @param {[Boolean]} relativeToNonStaticParent Whether the rect should be relative to the relative parent of (including) the contaienr\n * @param {[Boolean]} undoScale Whether the container's scale() should be undone\n * @param {[HTMLElement]} container The parent the element will be placed in\n * @return {Object} The boundingClientRect of el, with specified adjustments\n */\n\n\nfunction getRect(el, relativeToContainingBlock, relativeToNonStaticParent, undoScale, container) {\n if (!el.getBoundingClientRect && el !== window) return;\n var elRect, top, left, bottom, right, height, width;\n\n if (el !== window && el.parentNode && el !== getWindowScrollingElement()) {\n elRect = el.getBoundingClientRect();\n top = elRect.top;\n left = elRect.left;\n bottom = elRect.bottom;\n right = elRect.right;\n height = elRect.height;\n width = elRect.width;\n } else {\n top = 0;\n left = 0;\n bottom = window.innerHeight;\n right = window.innerWidth;\n height = window.innerHeight;\n width = window.innerWidth;\n }\n\n if ((relativeToContainingBlock || relativeToNonStaticParent) && el !== window) {\n // Adjust for translate()\n container = container || el.parentNode; // solves #1123 (see: https://stackoverflow.com/a/37953806/6088312)\n // Not needed on <= IE11\n\n if (!IE11OrLess) {\n do {\n if (container && container.getBoundingClientRect && (css(container, 'transform') !== 'none' || relativeToNonStaticParent && css(container, 'position') !== 'static')) {\n var containerRect = container.getBoundingClientRect(); // Set relative to edges of padding box of container\n\n top -= containerRect.top + parseInt(css(container, 'border-top-width'));\n left -= containerRect.left + parseInt(css(container, 'border-left-width'));\n bottom = top + elRect.height;\n right = left + elRect.width;\n break;\n }\n /* jshint boss:true */\n\n } while (container = container.parentNode);\n }\n }\n\n if (undoScale && el !== window) {\n // Adjust for scale()\n var elMatrix = matrix(container || el),\n scaleX = elMatrix && elMatrix.a,\n scaleY = elMatrix && elMatrix.d;\n\n if (elMatrix) {\n top /= scaleY;\n left /= scaleX;\n width /= scaleX;\n height /= scaleY;\n bottom = top + height;\n right = left + width;\n }\n }\n\n return {\n top: top,\n left: left,\n bottom: bottom,\n right: right,\n width: width,\n height: height\n };\n}\n/**\n * Checks if a side of an element is scrolled past a side of its parents\n * @param {HTMLElement} el The element who's side being scrolled out of view is in question\n * @param {String} elSide Side of the element in question ('top', 'left', 'right', 'bottom')\n * @param {String} parentSide Side of the parent in question ('top', 'left', 'right', 'bottom')\n * @return {HTMLElement} The parent scroll element that the el's side is scrolled past, or null if there is no such element\n */\n\n\nfunction isScrolledPast(el, elSide, parentSide) {\n var parent = getParentAutoScrollElement(el, true),\n elSideVal = getRect(el)[elSide];\n /* jshint boss:true */\n\n while (parent) {\n var parentSideVal = getRect(parent)[parentSide],\n visible = void 0;\n\n if (parentSide === 'top' || parentSide === 'left') {\n visible = elSideVal >= parentSideVal;\n } else {\n visible = elSideVal <= parentSideVal;\n }\n\n if (!visible) return parent;\n if (parent === getWindowScrollingElement()) break;\n parent = getParentAutoScrollElement(parent, false);\n }\n\n return false;\n}\n/**\n * Gets nth child of el, ignoring hidden children, sortable's elements (does not ignore clone if it's visible)\n * and non-draggable elements\n * @param {HTMLElement} el The parent element\n * @param {Number} childNum The index of the child\n * @param {Object} options Parent Sortable's options\n * @return {HTMLElement} The child at index childNum, or null if not found\n */\n\n\nfunction getChild(el, childNum, options, includeDragEl) {\n var currentChild = 0,\n i = 0,\n children = el.children;\n\n while (i < children.length) {\n if (children[i].style.display !== 'none' && children[i] !== Sortable.ghost && (includeDragEl || children[i] !== Sortable.dragged) && closest(children[i], options.draggable, el, false)) {\n if (currentChild === childNum) {\n return children[i];\n }\n\n currentChild++;\n }\n\n i++;\n }\n\n return null;\n}\n/**\n * Gets the last child in the el, ignoring ghostEl or invisible elements (clones)\n * @param {HTMLElement} el Parent element\n * @param {selector} selector Any other elements that should be ignored\n * @return {HTMLElement} The last child, ignoring ghostEl\n */\n\n\nfunction lastChild(el, selector) {\n var last = el.lastElementChild;\n\n while (last && (last === Sortable.ghost || css(last, 'display') === 'none' || selector && !matches(last, selector))) {\n last = last.previousElementSibling;\n }\n\n return last || null;\n}\n/**\n * Returns the index of an element within its parent for a selected set of\n * elements\n * @param {HTMLElement} el\n * @param {selector} selector\n * @return {number}\n */\n\n\nfunction index(el, selector) {\n var index = 0;\n\n if (!el || !el.parentNode) {\n return -1;\n }\n /* jshint boss:true */\n\n\n while (el = el.previousElementSibling) {\n if (el.nodeName.toUpperCase() !== 'TEMPLATE' && el !== Sortable.clone && (!selector || matches(el, selector))) {\n index++;\n }\n }\n\n return index;\n}\n/**\n * Returns the scroll offset of the given element, added with all the scroll offsets of parent elements.\n * The value is returned in real pixels.\n * @param {HTMLElement} el\n * @return {Array} Offsets in the format of [left, top]\n */\n\n\nfunction getRelativeScrollOffset(el) {\n var offsetLeft = 0,\n offsetTop = 0,\n winScroller = getWindowScrollingElement();\n\n if (el) {\n do {\n var elMatrix = matrix(el),\n scaleX = elMatrix.a,\n scaleY = elMatrix.d;\n offsetLeft += el.scrollLeft * scaleX;\n offsetTop += el.scrollTop * scaleY;\n } while (el !== winScroller && (el = el.parentNode));\n }\n\n return [offsetLeft, offsetTop];\n}\n/**\n * Returns the index of the object within the given array\n * @param {Array} arr Array that may or may not hold the object\n * @param {Object} obj An object that has a key-value pair unique to and identical to a key-value pair in the object you want to find\n * @return {Number} The index of the object in the array, or -1\n */\n\n\nfunction indexOfObject(arr, obj) {\n for (var i in arr) {\n if (!arr.hasOwnProperty(i)) continue;\n\n for (var key in obj) {\n if (obj.hasOwnProperty(key) && obj[key] === arr[i][key]) return Number(i);\n }\n }\n\n return -1;\n}\n\nfunction getParentAutoScrollElement(el, includeSelf) {\n // skip to window\n if (!el || !el.getBoundingClientRect) return getWindowScrollingElement();\n var elem = el;\n var gotSelf = false;\n\n do {\n // we don't need to get elem css if it isn't even overflowing in the first place (performance)\n if (elem.clientWidth < elem.scrollWidth || elem.clientHeight < elem.scrollHeight) {\n var elemCSS = css(elem);\n\n if (elem.clientWidth < elem.scrollWidth && (elemCSS.overflowX == 'auto' || elemCSS.overflowX == 'scroll') || elem.clientHeight < elem.scrollHeight && (elemCSS.overflowY == 'auto' || elemCSS.overflowY == 'scroll')) {\n if (!elem.getBoundingClientRect || elem === document.body) return getWindowScrollingElement();\n if (gotSelf || includeSelf) return elem;\n gotSelf = true;\n }\n }\n /* jshint boss:true */\n\n } while (elem = elem.parentNode);\n\n return getWindowScrollingElement();\n}\n\nfunction extend(dst, src) {\n if (dst && src) {\n for (var key in src) {\n if (src.hasOwnProperty(key)) {\n dst[key] = src[key];\n }\n }\n }\n\n return dst;\n}\n\nfunction isRectEqual(rect1, rect2) {\n return Math.round(rect1.top) === Math.round(rect2.top) && Math.round(rect1.left) === Math.round(rect2.left) && Math.round(rect1.height) === Math.round(rect2.height) && Math.round(rect1.width) === Math.round(rect2.width);\n}\n\nvar _throttleTimeout;\n\nfunction throttle(callback, ms) {\n return function () {\n if (!_throttleTimeout) {\n var args = arguments,\n _this = this;\n\n if (args.length === 1) {\n callback.call(_this, args[0]);\n } else {\n callback.apply(_this, args);\n }\n\n _throttleTimeout = setTimeout(function () {\n _throttleTimeout = void 0;\n }, ms);\n }\n };\n}\n\nfunction cancelThrottle() {\n clearTimeout(_throttleTimeout);\n _throttleTimeout = void 0;\n}\n\nfunction scrollBy(el, x, y) {\n el.scrollLeft += x;\n el.scrollTop += y;\n}\n\nfunction clone(el) {\n var Polymer = window.Polymer;\n var $ = window.jQuery || window.Zepto;\n\n if (Polymer && Polymer.dom) {\n return Polymer.dom(el).cloneNode(true);\n } else if ($) {\n return $(el).clone(true)[0];\n } else {\n return el.cloneNode(true);\n }\n}\n\nfunction setRect(el, rect) {\n css(el, 'position', 'absolute');\n css(el, 'top', rect.top);\n css(el, 'left', rect.left);\n css(el, 'width', rect.width);\n css(el, 'height', rect.height);\n}\n\nfunction unsetRect(el) {\n css(el, 'position', '');\n css(el, 'top', '');\n css(el, 'left', '');\n css(el, 'width', '');\n css(el, 'height', '');\n}\n\nvar expando = 'Sortable' + new Date().getTime();\n\nfunction AnimationStateManager() {\n var animationStates = [],\n animationCallbackId;\n return {\n captureAnimationState: function captureAnimationState() {\n animationStates = [];\n if (!this.options.animation) return;\n var children = [].slice.call(this.el.children);\n children.forEach(function (child) {\n if (css(child, 'display') === 'none' || child === Sortable.ghost) return;\n animationStates.push({\n target: child,\n rect: getRect(child)\n });\n\n var fromRect = _objectSpread2({}, animationStates[animationStates.length - 1].rect); // If animating: compensate for current animation\n\n\n if (child.thisAnimationDuration) {\n var childMatrix = matrix(child, true);\n\n if (childMatrix) {\n fromRect.top -= childMatrix.f;\n fromRect.left -= childMatrix.e;\n }\n }\n\n child.fromRect = fromRect;\n });\n },\n addAnimationState: function addAnimationState(state) {\n animationStates.push(state);\n },\n removeAnimationState: function removeAnimationState(target) {\n animationStates.splice(indexOfObject(animationStates, {\n target: target\n }), 1);\n },\n animateAll: function animateAll(callback) {\n var _this = this;\n\n if (!this.options.animation) {\n clearTimeout(animationCallbackId);\n if (typeof callback === 'function') callback();\n return;\n }\n\n var animating = false,\n animationTime = 0;\n animationStates.forEach(function (state) {\n var time = 0,\n target = state.target,\n fromRect = target.fromRect,\n toRect = getRect(target),\n prevFromRect = target.prevFromRect,\n prevToRect = target.prevToRect,\n animatingRect = state.rect,\n targetMatrix = matrix(target, true);\n\n if (targetMatrix) {\n // Compensate for current animation\n toRect.top -= targetMatrix.f;\n toRect.left -= targetMatrix.e;\n }\n\n target.toRect = toRect;\n\n if (target.thisAnimationDuration) {\n // Could also check if animatingRect is between fromRect and toRect\n if (isRectEqual(prevFromRect, toRect) && !isRectEqual(fromRect, toRect) && // Make sure animatingRect is on line between toRect & fromRect\n (animatingRect.top - toRect.top) / (animatingRect.left - toRect.left) === (fromRect.top - toRect.top) / (fromRect.left - toRect.left)) {\n // If returning to same place as started from animation and on same axis\n time = calculateRealTime(animatingRect, prevFromRect, prevToRect, _this.options);\n }\n } // if fromRect != toRect: animate\n\n\n if (!isRectEqual(toRect, fromRect)) {\n target.prevFromRect = fromRect;\n target.prevToRect = toRect;\n\n if (!time) {\n time = _this.options.animation;\n }\n\n _this.animate(target, animatingRect, toRect, time);\n }\n\n if (time) {\n animating = true;\n animationTime = Math.max(animationTime, time);\n clearTimeout(target.animationResetTimer);\n target.animationResetTimer = setTimeout(function () {\n target.animationTime = 0;\n target.prevFromRect = null;\n target.fromRect = null;\n target.prevToRect = null;\n target.thisAnimationDuration = null;\n }, time);\n target.thisAnimationDuration = time;\n }\n });\n clearTimeout(animationCallbackId);\n\n if (!animating) {\n if (typeof callback === 'function') callback();\n } else {\n animationCallbackId = setTimeout(function () {\n if (typeof callback === 'function') callback();\n }, animationTime);\n }\n\n animationStates = [];\n },\n animate: function animate(target, currentRect, toRect, duration) {\n if (duration) {\n css(target, 'transition', '');\n css(target, 'transform', '');\n var elMatrix = matrix(this.el),\n scaleX = elMatrix && elMatrix.a,\n scaleY = elMatrix && elMatrix.d,\n translateX = (currentRect.left - toRect.left) / (scaleX || 1),\n translateY = (currentRect.top - toRect.top) / (scaleY || 1);\n target.animatingX = !!translateX;\n target.animatingY = !!translateY;\n css(target, 'transform', 'translate3d(' + translateX + 'px,' + translateY + 'px,0)');\n this.forRepaintDummy = repaint(target); // repaint\n\n css(target, 'transition', 'transform ' + duration + 'ms' + (this.options.easing ? ' ' + this.options.easing : ''));\n css(target, 'transform', 'translate3d(0,0,0)');\n typeof target.animated === 'number' && clearTimeout(target.animated);\n target.animated = setTimeout(function () {\n css(target, 'transition', '');\n css(target, 'transform', '');\n target.animated = false;\n target.animatingX = false;\n target.animatingY = false;\n }, duration);\n }\n }\n };\n}\n\nfunction repaint(target) {\n return target.offsetWidth;\n}\n\nfunction calculateRealTime(animatingRect, fromRect, toRect, options) {\n return Math.sqrt(Math.pow(fromRect.top - animatingRect.top, 2) + Math.pow(fromRect.left - animatingRect.left, 2)) / Math.sqrt(Math.pow(fromRect.top - toRect.top, 2) + Math.pow(fromRect.left - toRect.left, 2)) * options.animation;\n}\n\nvar plugins = [];\nvar defaults = {\n initializeByDefault: true\n};\nvar PluginManager = {\n mount: function mount(plugin) {\n // Set default static properties\n for (var option in defaults) {\n if (defaults.hasOwnProperty(option) && !(option in plugin)) {\n plugin[option] = defaults[option];\n }\n }\n\n plugins.forEach(function (p) {\n if (p.pluginName === plugin.pluginName) {\n throw \"Sortable: Cannot mount plugin \".concat(plugin.pluginName, \" more than once\");\n }\n });\n plugins.push(plugin);\n },\n pluginEvent: function pluginEvent(eventName, sortable, evt) {\n var _this = this;\n\n this.eventCanceled = false;\n\n evt.cancel = function () {\n _this.eventCanceled = true;\n };\n\n var eventNameGlobal = eventName + 'Global';\n plugins.forEach(function (plugin) {\n if (!sortable[plugin.pluginName]) return; // Fire global events if it exists in this sortable\n\n if (sortable[plugin.pluginName][eventNameGlobal]) {\n sortable[plugin.pluginName][eventNameGlobal](_objectSpread2({\n sortable: sortable\n }, evt));\n } // Only fire plugin event if plugin is enabled in this sortable,\n // and plugin has event defined\n\n\n if (sortable.options[plugin.pluginName] && sortable[plugin.pluginName][eventName]) {\n sortable[plugin.pluginName][eventName](_objectSpread2({\n sortable: sortable\n }, evt));\n }\n });\n },\n initializePlugins: function initializePlugins(sortable, el, defaults, options) {\n plugins.forEach(function (plugin) {\n var pluginName = plugin.pluginName;\n if (!sortable.options[pluginName] && !plugin.initializeByDefault) return;\n var initialized = new plugin(sortable, el, sortable.options);\n initialized.sortable = sortable;\n initialized.options = sortable.options;\n sortable[pluginName] = initialized; // Add default options from plugin\n\n _extends(defaults, initialized.defaults);\n });\n\n for (var option in sortable.options) {\n if (!sortable.options.hasOwnProperty(option)) continue;\n var modified = this.modifyOption(sortable, option, sortable.options[option]);\n\n if (typeof modified !== 'undefined') {\n sortable.options[option] = modified;\n }\n }\n },\n getEventProperties: function getEventProperties(name, sortable) {\n var eventProperties = {};\n plugins.forEach(function (plugin) {\n if (typeof plugin.eventProperties !== 'function') return;\n\n _extends(eventProperties, plugin.eventProperties.call(sortable[plugin.pluginName], name));\n });\n return eventProperties;\n },\n modifyOption: function modifyOption(sortable, name, value) {\n var modifiedValue;\n plugins.forEach(function (plugin) {\n // Plugin must exist on the Sortable\n if (!sortable[plugin.pluginName]) return; // If static option listener exists for this option, call in the context of the Sortable's instance of this plugin\n\n if (plugin.optionListeners && typeof plugin.optionListeners[name] === 'function') {\n modifiedValue = plugin.optionListeners[name].call(sortable[plugin.pluginName], value);\n }\n });\n return modifiedValue;\n }\n};\n\nfunction dispatchEvent(_ref) {\n var sortable = _ref.sortable,\n rootEl = _ref.rootEl,\n name = _ref.name,\n targetEl = _ref.targetEl,\n cloneEl = _ref.cloneEl,\n toEl = _ref.toEl,\n fromEl = _ref.fromEl,\n oldIndex = _ref.oldIndex,\n newIndex = _ref.newIndex,\n oldDraggableIndex = _ref.oldDraggableIndex,\n newDraggableIndex = _ref.newDraggableIndex,\n originalEvent = _ref.originalEvent,\n putSortable = _ref.putSortable,\n extraEventProperties = _ref.extraEventProperties;\n sortable = sortable || rootEl && rootEl[expando];\n if (!sortable) return;\n var evt,\n options = sortable.options,\n onName = 'on' + name.charAt(0).toUpperCase() + name.substr(1); // Support for new CustomEvent feature\n\n if (window.CustomEvent && !IE11OrLess && !Edge) {\n evt = new CustomEvent(name, {\n bubbles: true,\n cancelable: true\n });\n } else {\n evt = document.createEvent('Event');\n evt.initEvent(name, true, true);\n }\n\n evt.to = toEl || rootEl;\n evt.from = fromEl || rootEl;\n evt.item = targetEl || rootEl;\n evt.clone = cloneEl;\n evt.oldIndex = oldIndex;\n evt.newIndex = newIndex;\n evt.oldDraggableIndex = oldDraggableIndex;\n evt.newDraggableIndex = newDraggableIndex;\n evt.originalEvent = originalEvent;\n evt.pullMode = putSortable ? putSortable.lastPutMode : undefined;\n\n var allEventProperties = _objectSpread2(_objectSpread2({}, extraEventProperties), PluginManager.getEventProperties(name, sortable));\n\n for (var option in allEventProperties) {\n evt[option] = allEventProperties[option];\n }\n\n if (rootEl) {\n rootEl.dispatchEvent(evt);\n }\n\n if (options[onName]) {\n options[onName].call(sortable, evt);\n }\n}\n\nvar _excluded = [\"evt\"];\n\nvar pluginEvent = function pluginEvent(eventName, sortable) {\n var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},\n originalEvent = _ref.evt,\n data = _objectWithoutProperties(_ref, _excluded);\n\n PluginManager.pluginEvent.bind(Sortable)(eventName, sortable, _objectSpread2({\n dragEl: dragEl,\n parentEl: parentEl,\n ghostEl: ghostEl,\n rootEl: rootEl,\n nextEl: nextEl,\n lastDownEl: lastDownEl,\n cloneEl: cloneEl,\n cloneHidden: cloneHidden,\n dragStarted: moved,\n putSortable: putSortable,\n activeSortable: Sortable.active,\n originalEvent: originalEvent,\n oldIndex: oldIndex,\n oldDraggableIndex: oldDraggableIndex,\n newIndex: newIndex,\n newDraggableIndex: newDraggableIndex,\n hideGhostForTarget: _hideGhostForTarget,\n unhideGhostForTarget: _unhideGhostForTarget,\n cloneNowHidden: function cloneNowHidden() {\n cloneHidden = true;\n },\n cloneNowShown: function cloneNowShown() {\n cloneHidden = false;\n },\n dispatchSortableEvent: function dispatchSortableEvent(name) {\n _dispatchEvent({\n sortable: sortable,\n name: name,\n originalEvent: originalEvent\n });\n }\n }, data));\n};\n\nfunction _dispatchEvent(info) {\n dispatchEvent(_objectSpread2({\n putSortable: putSortable,\n cloneEl: cloneEl,\n targetEl: dragEl,\n rootEl: rootEl,\n oldIndex: oldIndex,\n oldDraggableIndex: oldDraggableIndex,\n newIndex: newIndex,\n newDraggableIndex: newDraggableIndex\n }, info));\n}\n\nvar dragEl,\n parentEl,\n ghostEl,\n rootEl,\n nextEl,\n lastDownEl,\n cloneEl,\n cloneHidden,\n oldIndex,\n newIndex,\n oldDraggableIndex,\n newDraggableIndex,\n activeGroup,\n putSortable,\n awaitingDragStarted = false,\n ignoreNextClick = false,\n sortables = [],\n tapEvt,\n touchEvt,\n lastDx,\n lastDy,\n tapDistanceLeft,\n tapDistanceTop,\n moved,\n lastTarget,\n lastDirection,\n pastFirstInvertThresh = false,\n isCircumstantialInvert = false,\n targetMoveDistance,\n // For positioning ghost absolutely\nghostRelativeParent,\n ghostRelativeParentInitialScroll = [],\n // (left, top)\n_silent = false,\n savedInputChecked = [];\n/** @const */\n\nvar documentExists = typeof document !== 'undefined',\n PositionGhostAbsolutely = IOS,\n CSSFloatProperty = Edge || IE11OrLess ? 'cssFloat' : 'float',\n // This will not pass for IE9, because IE9 DnD only works on anchors\nsupportDraggable = documentExists && !ChromeForAndroid && !IOS && 'draggable' in document.createElement('div'),\n supportCssPointerEvents = function () {\n if (!documentExists) return; // false when <= IE11\n\n if (IE11OrLess) {\n return false;\n }\n\n var el = document.createElement('x');\n el.style.cssText = 'pointer-events:auto';\n return el.style.pointerEvents === 'auto';\n}(),\n _detectDirection = function _detectDirection(el, options) {\n var elCSS = css(el),\n elWidth = parseInt(elCSS.width) - parseInt(elCSS.paddingLeft) - parseInt(elCSS.paddingRight) - parseInt(elCSS.borderLeftWidth) - parseInt(elCSS.borderRightWidth),\n child1 = getChild(el, 0, options),\n child2 = getChild(el, 1, options),\n firstChildCSS = child1 && css(child1),\n secondChildCSS = child2 && css(child2),\n firstChildWidth = firstChildCSS && parseInt(firstChildCSS.marginLeft) + parseInt(firstChildCSS.marginRight) + getRect(child1).width,\n secondChildWidth = secondChildCSS && parseInt(secondChildCSS.marginLeft) + parseInt(secondChildCSS.marginRight) + getRect(child2).width;\n\n if (elCSS.display === 'flex') {\n return elCSS.flexDirection === 'column' || elCSS.flexDirection === 'column-reverse' ? 'vertical' : 'horizontal';\n }\n\n if (elCSS.display === 'grid') {\n return elCSS.gridTemplateColumns.split(' ').length <= 1 ? 'vertical' : 'horizontal';\n }\n\n if (child1 && firstChildCSS[\"float\"] && firstChildCSS[\"float\"] !== 'none') {\n var touchingSideChild2 = firstChildCSS[\"float\"] === 'left' ? 'left' : 'right';\n return child2 && (secondChildCSS.clear === 'both' || secondChildCSS.clear === touchingSideChild2) ? 'vertical' : 'horizontal';\n }\n\n return child1 && (firstChildCSS.display === 'block' || firstChildCSS.display === 'flex' || firstChildCSS.display === 'table' || firstChildCSS.display === 'grid' || firstChildWidth >= elWidth && elCSS[CSSFloatProperty] === 'none' || child2 && elCSS[CSSFloatProperty] === 'none' && firstChildWidth + secondChildWidth > elWidth) ? 'vertical' : 'horizontal';\n},\n _dragElInRowColumn = function _dragElInRowColumn(dragRect, targetRect, vertical) {\n var dragElS1Opp = vertical ? dragRect.left : dragRect.top,\n dragElS2Opp = vertical ? dragRect.right : dragRect.bottom,\n dragElOppLength = vertical ? dragRect.width : dragRect.height,\n targetS1Opp = vertical ? targetRect.left : targetRect.top,\n targetS2Opp = vertical ? targetRect.right : targetRect.bottom,\n targetOppLength = vertical ? targetRect.width : targetRect.height;\n return dragElS1Opp === targetS1Opp || dragElS2Opp === targetS2Opp || dragElS1Opp + dragElOppLength / 2 === targetS1Opp + targetOppLength / 2;\n},\n\n/**\n * Detects first nearest empty sortable to X and Y position using emptyInsertThreshold.\n * @param {Number} x X position\n * @param {Number} y Y position\n * @return {HTMLElement} Element of the first found nearest Sortable\n */\n_detectNearestEmptySortable = function _detectNearestEmptySortable(x, y) {\n var ret;\n sortables.some(function (sortable) {\n var threshold = sortable[expando].options.emptyInsertThreshold;\n if (!threshold || lastChild(sortable)) return;\n var rect = getRect(sortable),\n insideHorizontally = x >= rect.left - threshold && x <= rect.right + threshold,\n insideVertically = y >= rect.top - threshold && y <= rect.bottom + threshold;\n\n if (insideHorizontally && insideVertically) {\n return ret = sortable;\n }\n });\n return ret;\n},\n _prepareGroup = function _prepareGroup(options) {\n function toFn(value, pull) {\n return function (to, from, dragEl, evt) {\n var sameGroup = to.options.group.name && from.options.group.name && to.options.group.name === from.options.group.name;\n\n if (value == null && (pull || sameGroup)) {\n // Default pull value\n // Default pull and put value if same group\n return true;\n } else if (value == null || value === false) {\n return false;\n } else if (pull && value === 'clone') {\n return value;\n } else if (typeof value === 'function') {\n return toFn(value(to, from, dragEl, evt), pull)(to, from, dragEl, evt);\n } else {\n var otherGroup = (pull ? to : from).options.group.name;\n return value === true || typeof value === 'string' && value === otherGroup || value.join && value.indexOf(otherGroup) > -1;\n }\n };\n }\n\n var group = {};\n var originalGroup = options.group;\n\n if (!originalGroup || _typeof(originalGroup) != 'object') {\n originalGroup = {\n name: originalGroup\n };\n }\n\n group.name = originalGroup.name;\n group.checkPull = toFn(originalGroup.pull, true);\n group.checkPut = toFn(originalGroup.put);\n group.revertClone = originalGroup.revertClone;\n options.group = group;\n},\n _hideGhostForTarget = function _hideGhostForTarget() {\n if (!supportCssPointerEvents && ghostEl) {\n css(ghostEl, 'display', 'none');\n }\n},\n _unhideGhostForTarget = function _unhideGhostForTarget() {\n if (!supportCssPointerEvents && ghostEl) {\n css(ghostEl, 'display', '');\n }\n}; // #1184 fix - Prevent click event on fallback if dragged but item not changed position\n\n\nif (documentExists) {\n document.addEventListener('click', function (evt) {\n if (ignoreNextClick) {\n evt.preventDefault();\n evt.stopPropagation && evt.stopPropagation();\n evt.stopImmediatePropagation && evt.stopImmediatePropagation();\n ignoreNextClick = false;\n return false;\n }\n }, true);\n}\n\nvar nearestEmptyInsertDetectEvent = function nearestEmptyInsertDetectEvent(evt) {\n if (dragEl) {\n evt = evt.touches ? evt.touches[0] : evt;\n\n var nearest = _detectNearestEmptySortable(evt.clientX, evt.clientY);\n\n if (nearest) {\n // Create imitation event\n var event = {};\n\n for (var i in evt) {\n if (evt.hasOwnProperty(i)) {\n event[i] = evt[i];\n }\n }\n\n event.target = event.rootEl = nearest;\n event.preventDefault = void 0;\n event.stopPropagation = void 0;\n\n nearest[expando]._onDragOver(event);\n }\n }\n};\n\nvar _checkOutsideTargetEl = function _checkOutsideTargetEl(evt) {\n if (dragEl) {\n dragEl.parentNode[expando]._isOutsideThisEl(evt.target);\n }\n};\n/**\n * @class Sortable\n * @param {HTMLElement} el\n * @param {Object} [options]\n */\n\n\nfunction Sortable(el, options) {\n if (!(el && el.nodeType && el.nodeType === 1)) {\n throw \"Sortable: `el` must be an HTMLElement, not \".concat({}.toString.call(el));\n }\n\n this.el = el; // root element\n\n this.options = options = _extends({}, options); // Export instance\n\n el[expando] = this;\n var defaults = {\n group: null,\n sort: true,\n disabled: false,\n store: null,\n handle: null,\n draggable: /^[uo]l$/i.test(el.nodeName) ? '>li' : '>*',\n swapThreshold: 1,\n // percentage; 0 <= x <= 1\n invertSwap: false,\n // invert always\n invertedSwapThreshold: null,\n // will be set to same as swapThreshold if default\n removeCloneOnHide: true,\n direction: function direction() {\n return _detectDirection(el, this.options);\n },\n ghostClass: 'sortable-ghost',\n chosenClass: 'sortable-chosen',\n dragClass: 'sortable-drag',\n ignore: 'a, img',\n filter: null,\n preventOnFilter: true,\n animation: 0,\n easing: null,\n setData: function setData(dataTransfer, dragEl) {\n dataTransfer.setData('Text', dragEl.textContent);\n },\n dropBubble: false,\n dragoverBubble: false,\n dataIdAttr: 'data-id',\n delay: 0,\n delayOnTouchOnly: false,\n touchStartThreshold: (Number.parseInt ? Number : window).parseInt(window.devicePixelRatio, 10) || 1,\n forceFallback: false,\n fallbackClass: 'sortable-fallback',\n fallbackOnBody: false,\n fallbackTolerance: 0,\n fallbackOffset: {\n x: 0,\n y: 0\n },\n supportPointer: Sortable.supportPointer !== false && 'PointerEvent' in window && !Safari,\n emptyInsertThreshold: 5\n };\n PluginManager.initializePlugins(this, el, defaults); // Set default options\n\n for (var name in defaults) {\n !(name in options) && (options[name] = defaults[name]);\n }\n\n _prepareGroup(options); // Bind all private methods\n\n\n for (var fn in this) {\n if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {\n this[fn] = this[fn].bind(this);\n }\n } // Setup drag mode\n\n\n this.nativeDraggable = options.forceFallback ? false : supportDraggable;\n\n if (this.nativeDraggable) {\n // Touch start threshold cannot be greater than the native dragstart threshold\n this.options.touchStartThreshold = 1;\n } // Bind events\n\n\n if (options.supportPointer) {\n on(el, 'pointerdown', this._onTapStart);\n } else {\n on(el, 'mousedown', this._onTapStart);\n on(el, 'touchstart', this._onTapStart);\n }\n\n if (this.nativeDraggable) {\n on(el, 'dragover', this);\n on(el, 'dragenter', this);\n }\n\n sortables.push(this.el); // Restore sorting\n\n options.store && options.store.get && this.sort(options.store.get(this) || []); // Add animation state manager\n\n _extends(this, AnimationStateManager());\n}\n\nSortable.prototype =\n/** @lends Sortable.prototype */\n{\n constructor: Sortable,\n _isOutsideThisEl: function _isOutsideThisEl(target) {\n if (!this.el.contains(target) && target !== this.el) {\n lastTarget = null;\n }\n },\n _getDirection: function _getDirection(evt, target) {\n return typeof this.options.direction === 'function' ? this.options.direction.call(this, evt, target, dragEl) : this.options.direction;\n },\n _onTapStart: function _onTapStart(\n /** Event|TouchEvent */\n evt) {\n if (!evt.cancelable) return;\n\n var _this = this,\n el = this.el,\n options = this.options,\n preventOnFilter = options.preventOnFilter,\n type = evt.type,\n touch = evt.touches && evt.touches[0] || evt.pointerType && evt.pointerType === 'touch' && evt,\n target = (touch || evt).target,\n originalTarget = evt.target.shadowRoot && (evt.path && evt.path[0] || evt.composedPath && evt.composedPath()[0]) || target,\n filter = options.filter;\n\n _saveInputCheckedState(el); // Don't trigger start event when an element is been dragged, otherwise the evt.oldindex always wrong when set option.group.\n\n\n if (dragEl) {\n return;\n }\n\n if (/mousedown|pointerdown/.test(type) && evt.button !== 0 || options.disabled) {\n return; // only left button and enabled\n } // cancel dnd if original target is content editable\n\n\n if (originalTarget.isContentEditable) {\n return;\n } // Safari ignores further event handling after mousedown\n\n\n if (!this.nativeDraggable && Safari && target && target.tagName.toUpperCase() === 'SELECT') {\n return;\n }\n\n target = closest(target, options.draggable, el, false);\n\n if (target && target.animated) {\n return;\n }\n\n if (lastDownEl === target) {\n // Ignoring duplicate `down`\n return;\n } // Get the index of the dragged element within its parent\n\n\n oldIndex = index(target);\n oldDraggableIndex = index(target, options.draggable); // Check filter\n\n if (typeof filter === 'function') {\n if (filter.call(this, evt, target, this)) {\n _dispatchEvent({\n sortable: _this,\n rootEl: originalTarget,\n name: 'filter',\n targetEl: target,\n toEl: el,\n fromEl: el\n });\n\n pluginEvent('filter', _this, {\n evt: evt\n });\n preventOnFilter && evt.cancelable && evt.preventDefault();\n return; // cancel dnd\n }\n } else if (filter) {\n filter = filter.split(',').some(function (criteria) {\n criteria = closest(originalTarget, criteria.trim(), el, false);\n\n if (criteria) {\n _dispatchEvent({\n sortable: _this,\n rootEl: criteria,\n name: 'filter',\n targetEl: target,\n fromEl: el,\n toEl: el\n });\n\n pluginEvent('filter', _this, {\n evt: evt\n });\n return true;\n }\n });\n\n if (filter) {\n preventOnFilter && evt.cancelable && evt.preventDefault();\n return; // cancel dnd\n }\n }\n\n if (options.handle && !closest(originalTarget, options.handle, el, false)) {\n return;\n } // Prepare `dragstart`\n\n\n this._prepareDragStart(evt, touch, target);\n },\n _prepareDragStart: function _prepareDragStart(\n /** Event */\n evt,\n /** Touch */\n touch,\n /** HTMLElement */\n target) {\n var _this = this,\n el = _this.el,\n options = _this.options,\n ownerDocument = el.ownerDocument,\n dragStartFn;\n\n if (target && !dragEl && target.parentNode === el) {\n var dragRect = getRect(target);\n rootEl = el;\n dragEl = target;\n parentEl = dragEl.parentNode;\n nextEl = dragEl.nextSibling;\n lastDownEl = target;\n activeGroup = options.group;\n Sortable.dragged = dragEl;\n tapEvt = {\n target: dragEl,\n clientX: (touch || evt).clientX,\n clientY: (touch || evt).clientY\n };\n tapDistanceLeft = tapEvt.clientX - dragRect.left;\n tapDistanceTop = tapEvt.clientY - dragRect.top;\n this._lastX = (touch || evt).clientX;\n this._lastY = (touch || evt).clientY;\n dragEl.style['will-change'] = 'all';\n\n dragStartFn = function dragStartFn() {\n pluginEvent('delayEnded', _this, {\n evt: evt\n });\n\n if (Sortable.eventCanceled) {\n _this._onDrop();\n\n return;\n } // Delayed drag has been triggered\n // we can re-enable the events: touchmove/mousemove\n\n\n _this._disableDelayedDragEvents();\n\n if (!FireFox && _this.nativeDraggable) {\n dragEl.draggable = true;\n } // Bind the events: dragstart/dragend\n\n\n _this._triggerDragStart(evt, touch); // Drag start event\n\n\n _dispatchEvent({\n sortable: _this,\n name: 'choose',\n originalEvent: evt\n }); // Chosen item\n\n\n toggleClass(dragEl, options.chosenClass, true);\n }; // Disable \"draggable\"\n\n\n options.ignore.split(',').forEach(function (criteria) {\n find(dragEl, criteria.trim(), _disableDraggable);\n });\n on(ownerDocument, 'dragover', nearestEmptyInsertDetectEvent);\n on(ownerDocument, 'mousemove', nearestEmptyInsertDetectEvent);\n on(ownerDocument, 'touchmove', nearestEmptyInsertDetectEvent);\n on(ownerDocument, 'mouseup', _this._onDrop);\n on(ownerDocument, 'touchend', _this._onDrop);\n on(ownerDocument, 'touchcancel', _this._onDrop); // Make dragEl draggable (must be before delay for FireFox)\n\n if (FireFox && this.nativeDraggable) {\n this.options.touchStartThreshold = 4;\n dragEl.draggable = true;\n }\n\n pluginEvent('delayStart', this, {\n evt: evt\n }); // Delay is impossible for native DnD in Edge or IE\n\n if (options.delay && (!options.delayOnTouchOnly || touch) && (!this.nativeDraggable || !(Edge || IE11OrLess))) {\n if (Sortable.eventCanceled) {\n this._onDrop();\n\n return;\n } // If the user moves the pointer or let go the click or touch\n // before the delay has been reached:\n // disable the delayed drag\n\n\n on(ownerDocument, 'mouseup', _this._disableDelayedDrag);\n on(ownerDocument, 'touchend', _this._disableDelayedDrag);\n on(ownerDocument, 'touchcancel', _this._disableDelayedDrag);\n on(ownerDocument, 'mousemove', _this._delayedDragTouchMoveHandler);\n on(ownerDocument, 'touchmove', _this._delayedDragTouchMoveHandler);\n options.supportPointer && on(ownerDocument, 'pointermove', _this._delayedDragTouchMoveHandler);\n _this._dragStartTimer = setTimeout(dragStartFn, options.delay);\n } else {\n dragStartFn();\n }\n }\n },\n _delayedDragTouchMoveHandler: function _delayedDragTouchMoveHandler(\n /** TouchEvent|PointerEvent **/\n e) {\n var touch = e.touches ? e.touches[0] : e;\n\n if (Math.max(Math.abs(touch.clientX - this._lastX), Math.abs(touch.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1))) {\n this._disableDelayedDrag();\n }\n },\n _disableDelayedDrag: function _disableDelayedDrag() {\n dragEl && _disableDraggable(dragEl);\n clearTimeout(this._dragStartTimer);\n\n this._disableDelayedDragEvents();\n },\n _disableDelayedDragEvents: function _disableDelayedDragEvents() {\n var ownerDocument = this.el.ownerDocument;\n off(ownerDocument, 'mouseup', this._disableDelayedDrag);\n off(ownerDocument, 'touchend', this._disableDelayedDrag);\n off(ownerDocument, 'touchcancel', this._disableDelayedDrag);\n off(ownerDocument, 'mousemove', this._delayedDragTouchMoveHandler);\n off(ownerDocument, 'touchmove', this._delayedDragTouchMoveHandler);\n off(ownerDocument, 'pointermove', this._delayedDragTouchMoveHandler);\n },\n _triggerDragStart: function _triggerDragStart(\n /** Event */\n evt,\n /** Touch */\n touch) {\n touch = touch || evt.pointerType == 'touch' && evt;\n\n if (!this.nativeDraggable || touch) {\n if (this.options.supportPointer) {\n on(document, 'pointermove', this._onTouchMove);\n } else if (touch) {\n on(document, 'touchmove', this._onTouchMove);\n } else {\n on(document, 'mousemove', this._onTouchMove);\n }\n } else {\n on(dragEl, 'dragend', this);\n on(rootEl, 'dragstart', this._onDragStart);\n }\n\n try {\n if (document.selection) {\n // Timeout neccessary for IE9\n _nextTick(function () {\n document.selection.empty();\n });\n } else {\n window.getSelection().removeAllRanges();\n }\n } catch (err) {}\n },\n _dragStarted: function _dragStarted(fallback, evt) {\n\n awaitingDragStarted = false;\n\n if (rootEl && dragEl) {\n pluginEvent('dragStarted', this, {\n evt: evt\n });\n\n if (this.nativeDraggable) {\n on(document, 'dragover', _checkOutsideTargetEl);\n }\n\n var options = this.options; // Apply effect\n\n !fallback && toggleClass(dragEl, options.dragClass, false);\n toggleClass(dragEl, options.ghostClass, true);\n Sortable.active = this;\n fallback && this._appendGhost(); // Drag start event\n\n _dispatchEvent({\n sortable: this,\n name: 'start',\n originalEvent: evt\n });\n } else {\n this._nulling();\n }\n },\n _emulateDragOver: function _emulateDragOver() {\n if (touchEvt) {\n this._lastX = touchEvt.clientX;\n this._lastY = touchEvt.clientY;\n\n _hideGhostForTarget();\n\n var target = document.elementFromPoint(touchEvt.clientX, touchEvt.clientY);\n var parent = target;\n\n while (target && target.shadowRoot) {\n target = target.shadowRoot.elementFromPoint(touchEvt.clientX, touchEvt.clientY);\n if (target === parent) break;\n parent = target;\n }\n\n dragEl.parentNode[expando]._isOutsideThisEl(target);\n\n if (parent) {\n do {\n if (parent[expando]) {\n var inserted = void 0;\n inserted = parent[expando]._onDragOver({\n clientX: touchEvt.clientX,\n clientY: touchEvt.clientY,\n target: target,\n rootEl: parent\n });\n\n if (inserted && !this.options.dragoverBubble) {\n break;\n }\n }\n\n target = parent; // store last element\n }\n /* jshint boss:true */\n while (parent = parent.parentNode);\n }\n\n _unhideGhostForTarget();\n }\n },\n _onTouchMove: function _onTouchMove(\n /**TouchEvent*/\n evt) {\n if (tapEvt) {\n var options = this.options,\n fallbackTolerance = options.fallbackTolerance,\n fallbackOffset = options.fallbackOffset,\n touch = evt.touches ? evt.touches[0] : evt,\n ghostMatrix = ghostEl && matrix(ghostEl, true),\n scaleX = ghostEl && ghostMatrix && ghostMatrix.a,\n scaleY = ghostEl && ghostMatrix && ghostMatrix.d,\n relativeScrollOffset = PositionGhostAbsolutely && ghostRelativeParent && getRelativeScrollOffset(ghostRelativeParent),\n dx = (touch.clientX - tapEvt.clientX + fallbackOffset.x) / (scaleX || 1) + (relativeScrollOffset ? relativeScrollOffset[0] - ghostRelativeParentInitialScroll[0] : 0) / (scaleX || 1),\n dy = (touch.clientY - tapEvt.clientY + fallbackOffset.y) / (scaleY || 1) + (relativeScrollOffset ? relativeScrollOffset[1] - ghostRelativeParentInitialScroll[1] : 0) / (scaleY || 1); // only set the status to dragging, when we are actually dragging\n\n if (!Sortable.active && !awaitingDragStarted) {\n if (fallbackTolerance && Math.max(Math.abs(touch.clientX - this._lastX), Math.abs(touch.clientY - this._lastY)) < fallbackTolerance) {\n return;\n }\n\n this._onDragStart(evt, true);\n }\n\n if (ghostEl) {\n if (ghostMatrix) {\n ghostMatrix.e += dx - (lastDx || 0);\n ghostMatrix.f += dy - (lastDy || 0);\n } else {\n ghostMatrix = {\n a: 1,\n b: 0,\n c: 0,\n d: 1,\n e: dx,\n f: dy\n };\n }\n\n var cssMatrix = \"matrix(\".concat(ghostMatrix.a, \",\").concat(ghostMatrix.b, \",\").concat(ghostMatrix.c, \",\").concat(ghostMatrix.d, \",\").concat(ghostMatrix.e, \",\").concat(ghostMatrix.f, \")\");\n css(ghostEl, 'webkitTransform', cssMatrix);\n css(ghostEl, 'mozTransform', cssMatrix);\n css(ghostEl, 'msTransform', cssMatrix);\n css(ghostEl, 'transform', cssMatrix);\n lastDx = dx;\n lastDy = dy;\n touchEvt = touch;\n }\n\n evt.cancelable && evt.preventDefault();\n }\n },\n _appendGhost: function _appendGhost() {\n // Bug if using scale(): https://stackoverflow.com/questions/2637058\n // Not being adjusted for\n if (!ghostEl) {\n var container = this.options.fallbackOnBody ? document.body : rootEl,\n rect = getRect(dragEl, true, PositionGhostAbsolutely, true, container),\n options = this.options; // Position absolutely\n\n if (PositionGhostAbsolutely) {\n // Get relatively positioned parent\n ghostRelativeParent = container;\n\n while (css(ghostRelativeParent, 'position') === 'static' && css(ghostRelativeParent, 'transform') === 'none' && ghostRelativeParent !== document) {\n ghostRelativeParent = ghostRelativeParent.parentNode;\n }\n\n if (ghostRelativeParent !== document.body && ghostRelativeParent !== document.documentElement) {\n if (ghostRelativeParent === document) ghostRelativeParent = getWindowScrollingElement();\n rect.top += ghostRelativeParent.scrollTop;\n rect.left += ghostRelativeParent.scrollLeft;\n } else {\n ghostRelativeParent = getWindowScrollingElement();\n }\n\n ghostRelativeParentInitialScroll = getRelativeScrollOffset(ghostRelativeParent);\n }\n\n ghostEl = dragEl.cloneNode(true);\n toggleClass(ghostEl, options.ghostClass, false);\n toggleClass(ghostEl, options.fallbackClass, true);\n toggleClass(ghostEl, options.dragClass, true);\n css(ghostEl, 'transition', '');\n css(ghostEl, 'transform', '');\n css(ghostEl, 'box-sizing', 'border-box');\n css(ghostEl, 'margin', 0);\n css(ghostEl, 'top', rect.top);\n css(ghostEl, 'left', rect.left);\n css(ghostEl, 'width', rect.width);\n css(ghostEl, 'height', rect.height);\n css(ghostEl, 'opacity', '0.8');\n css(ghostEl, 'position', PositionGhostAbsolutely ? 'absolute' : 'fixed');\n css(ghostEl, 'zIndex', '100000');\n css(ghostEl, 'pointerEvents', 'none');\n Sortable.ghost = ghostEl;\n container.appendChild(ghostEl); // Set transform-origin\n\n css(ghostEl, 'transform-origin', tapDistanceLeft / parseInt(ghostEl.style.width) * 100 + '% ' + tapDistanceTop / parseInt(ghostEl.style.height) * 100 + '%');\n }\n },\n _onDragStart: function _onDragStart(\n /**Event*/\n evt,\n /**boolean*/\n fallback) {\n var _this = this;\n\n var dataTransfer = evt.dataTransfer;\n var options = _this.options;\n pluginEvent('dragStart', this, {\n evt: evt\n });\n\n if (Sortable.eventCanceled) {\n this._onDrop();\n\n return;\n }\n\n pluginEvent('setupClone', this);\n\n if (!Sortable.eventCanceled) {\n cloneEl = clone(dragEl);\n cloneEl.draggable = false;\n cloneEl.style['will-change'] = '';\n\n this._hideClone();\n\n toggleClass(cloneEl, this.options.chosenClass, false);\n Sortable.clone = cloneEl;\n } // #1143: IFrame support workaround\n\n\n _this.cloneId = _nextTick(function () {\n pluginEvent('clone', _this);\n if (Sortable.eventCanceled) return;\n\n if (!_this.options.removeCloneOnHide) {\n rootEl.insertBefore(cloneEl, dragEl);\n }\n\n _this._hideClone();\n\n _dispatchEvent({\n sortable: _this,\n name: 'clone'\n });\n });\n !fallback && toggleClass(dragEl, options.dragClass, true); // Set proper drop events\n\n if (fallback) {\n ignoreNextClick = true;\n _this._loopId = setInterval(_this._emulateDragOver, 50);\n } else {\n // Undo what was set in _prepareDragStart before drag started\n off(document, 'mouseup', _this._onDrop);\n off(document, 'touchend', _this._onDrop);\n off(document, 'touchcancel', _this._onDrop);\n\n if (dataTransfer) {\n dataTransfer.effectAllowed = 'move';\n options.setData && options.setData.call(_this, dataTransfer, dragEl);\n }\n\n on(document, 'drop', _this); // #1276 fix:\n\n css(dragEl, 'transform', 'translateZ(0)');\n }\n\n awaitingDragStarted = true;\n _this._dragStartId = _nextTick(_this._dragStarted.bind(_this, fallback, evt));\n on(document, 'selectstart', _this);\n moved = true;\n\n if (Safari) {\n css(document.body, 'user-select', 'none');\n }\n },\n // Returns true - if no further action is needed (either inserted or another condition)\n _onDragOver: function _onDragOver(\n /**Event*/\n evt) {\n var el = this.el,\n target = evt.target,\n dragRect,\n targetRect,\n revert,\n options = this.options,\n group = options.group,\n activeSortable = Sortable.active,\n isOwner = activeGroup === group,\n canSort = options.sort,\n fromSortable = putSortable || activeSortable,\n vertical,\n _this = this,\n completedFired = false;\n\n if (_silent) return;\n\n function dragOverEvent(name, extra) {\n pluginEvent(name, _this, _objectSpread2({\n evt: evt,\n isOwner: isOwner,\n axis: vertical ? 'vertical' : 'horizontal',\n revert: revert,\n dragRect: dragRect,\n targetRect: targetRect,\n canSort: canSort,\n fromSortable: fromSortable,\n target: target,\n completed: completed,\n onMove: function onMove(target, after) {\n return _onMove(rootEl, el, dragEl, dragRect, target, getRect(target), evt, after);\n },\n changed: changed\n }, extra));\n } // Capture animation state\n\n\n function capture() {\n dragOverEvent('dragOverAnimationCapture');\n\n _this.captureAnimationState();\n\n if (_this !== fromSortable) {\n fromSortable.captureAnimationState();\n }\n } // Return invocation when dragEl is inserted (or completed)\n\n\n function completed(insertion) {\n dragOverEvent('dragOverCompleted', {\n insertion: insertion\n });\n\n if (insertion) {\n // Clones must be hidden before folding animation to capture dragRectAbsolute properly\n if (isOwner) {\n activeSortable._hideClone();\n } else {\n activeSortable._showClone(_this);\n }\n\n if (_this !== fromSortable) {\n // Set ghost class to new sortable's ghost class\n toggleClass(dragEl, putSortable ? putSortable.options.ghostClass : activeSortable.options.ghostClass, false);\n toggleClass(dragEl, options.ghostClass, true);\n }\n\n if (putSortable !== _this && _this !== Sortable.active) {\n putSortable = _this;\n } else if (_this === Sortable.active && putSortable) {\n putSortable = null;\n } // Animation\n\n\n if (fromSortable === _this) {\n _this._ignoreWhileAnimating = target;\n }\n\n _this.animateAll(function () {\n dragOverEvent('dragOverAnimationComplete');\n _this._ignoreWhileAnimating = null;\n });\n\n if (_this !== fromSortable) {\n fromSortable.animateAll();\n fromSortable._ignoreWhileAnimating = null;\n }\n } // Null lastTarget if it is not inside a previously swapped element\n\n\n if (target === dragEl && !dragEl.animated || target === el && !target.animated) {\n lastTarget = null;\n } // no bubbling and not fallback\n\n\n if (!options.dragoverBubble && !evt.rootEl && target !== document) {\n dragEl.parentNode[expando]._isOutsideThisEl(evt.target); // Do not detect for empty insert if already inserted\n\n\n !insertion && nearestEmptyInsertDetectEvent(evt);\n }\n\n !options.dragoverBubble && evt.stopPropagation && evt.stopPropagation();\n return completedFired = true;\n } // Call when dragEl has been inserted\n\n\n function changed() {\n newIndex = index(dragEl);\n newDraggableIndex = index(dragEl, options.draggable);\n\n _dispatchEvent({\n sortable: _this,\n name: 'change',\n toEl: el,\n newIndex: newIndex,\n newDraggableIndex: newDraggableIndex,\n originalEvent: evt\n });\n }\n\n if (evt.preventDefault !== void 0) {\n evt.cancelable && evt.preventDefault();\n }\n\n target = closest(target, options.draggable, el, true);\n dragOverEvent('dragOver');\n if (Sortable.eventCanceled) return completedFired;\n\n if (dragEl.contains(evt.target) || target.animated && target.animatingX && target.animatingY || _this._ignoreWhileAnimating === target) {\n return completed(false);\n }\n\n ignoreNextClick = false;\n\n if (activeSortable && !options.disabled && (isOwner ? canSort || (revert = parentEl !== rootEl) // Reverting item into the original list\n : putSortable === this || (this.lastPutMode = activeGroup.checkPull(this, activeSortable, dragEl, evt)) && group.checkPut(this, activeSortable, dragEl, evt))) {\n vertical = this._getDirection(evt, target) === 'vertical';\n dragRect = getRect(dragEl);\n dragOverEvent('dragOverValid');\n if (Sortable.eventCanceled) return completedFired;\n\n if (revert) {\n parentEl = rootEl; // actualization\n\n capture();\n\n this._hideClone();\n\n dragOverEvent('revert');\n\n if (!Sortable.eventCanceled) {\n if (nextEl) {\n rootEl.insertBefore(dragEl, nextEl);\n } else {\n rootEl.appendChild(dragEl);\n }\n }\n\n return completed(true);\n }\n\n var elLastChild = lastChild(el, options.draggable);\n\n if (!elLastChild || _ghostIsLast(evt, vertical, this) && !elLastChild.animated) {\n // Insert to end of list\n // If already at end of list: Do not insert\n if (elLastChild === dragEl) {\n return completed(false);\n } // if there is a last element, it is the target\n\n\n if (elLastChild && el === evt.target) {\n target = elLastChild;\n }\n\n if (target) {\n targetRect = getRect(target);\n }\n\n if (_onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, !!target) !== false) {\n capture();\n el.appendChild(dragEl);\n parentEl = el; // actualization\n\n changed();\n return completed(true);\n }\n } else if (elLastChild && _ghostIsFirst(evt, vertical, this)) {\n // Insert to start of list\n var firstChild = getChild(el, 0, options, true);\n\n if (firstChild === dragEl) {\n return completed(false);\n }\n\n target = firstChild;\n targetRect = getRect(target);\n\n if (_onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, false) !== false) {\n capture();\n el.insertBefore(dragEl, firstChild);\n parentEl = el; // actualization\n\n changed();\n return completed(true);\n }\n } else if (target.parentNode === el) {\n targetRect = getRect(target);\n var direction = 0,\n targetBeforeFirstSwap,\n differentLevel = dragEl.parentNode !== el,\n differentRowCol = !_dragElInRowColumn(dragEl.animated && dragEl.toRect || dragRect, target.animated && target.toRect || targetRect, vertical),\n side1 = vertical ? 'top' : 'left',\n scrolledPastTop = isScrolledPast(target, 'top', 'top') || isScrolledPast(dragEl, 'top', 'top'),\n scrollBefore = scrolledPastTop ? scrolledPastTop.scrollTop : void 0;\n\n if (lastTarget !== target) {\n targetBeforeFirstSwap = targetRect[side1];\n pastFirstInvertThresh = false;\n isCircumstantialInvert = !differentRowCol && options.invertSwap || differentLevel;\n }\n\n direction = _getSwapDirection(evt, target, targetRect, vertical, differentRowCol ? 1 : options.swapThreshold, options.invertedSwapThreshold == null ? options.swapThreshold : options.invertedSwapThreshold, isCircumstantialInvert, lastTarget === target);\n var sibling;\n\n if (direction !== 0) {\n // Check if target is beside dragEl in respective direction (ignoring hidden elements)\n var dragIndex = index(dragEl);\n\n do {\n dragIndex -= direction;\n sibling = parentEl.children[dragIndex];\n } while (sibling && (css(sibling, 'display') === 'none' || sibling === ghostEl));\n } // If dragEl is already beside target: Do not insert\n\n\n if (direction === 0 || sibling === target) {\n return completed(false);\n }\n\n lastTarget = target;\n lastDirection = direction;\n var nextSibling = target.nextElementSibling,\n after = false;\n after = direction === 1;\n\n var moveVector = _onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, after);\n\n if (moveVector !== false) {\n if (moveVector === 1 || moveVector === -1) {\n after = moveVector === 1;\n }\n\n _silent = true;\n setTimeout(_unsilent, 30);\n capture();\n\n if (after && !nextSibling) {\n el.appendChild(dragEl);\n } else {\n target.parentNode.insertBefore(dragEl, after ? nextSibling : target);\n } // Undo chrome's scroll adjustment (has no effect on other browsers)\n\n\n if (scrolledPastTop) {\n scrollBy(scrolledPastTop, 0, scrollBefore - scrolledPastTop.scrollTop);\n }\n\n parentEl = dragEl.parentNode; // actualization\n // must be done before animation\n\n if (targetBeforeFirstSwap !== undefined && !isCircumstantialInvert) {\n targetMoveDistance = Math.abs(targetBeforeFirstSwap - getRect(target)[side1]);\n }\n\n changed();\n return completed(true);\n }\n }\n\n if (el.contains(dragEl)) {\n return completed(false);\n }\n }\n\n return false;\n },\n _ignoreWhileAnimating: null,\n _offMoveEvents: function _offMoveEvents() {\n off(document, 'mousemove', this._onTouchMove);\n off(document, 'touchmove', this._onTouchMove);\n off(document, 'pointermove', this._onTouchMove);\n off(document, 'dragover', nearestEmptyInsertDetectEvent);\n off(document, 'mousemove', nearestEmptyInsertDetectEvent);\n off(document, 'touchmove', nearestEmptyInsertDetectEvent);\n },\n _offUpEvents: function _offUpEvents() {\n var ownerDocument = this.el.ownerDocument;\n off(ownerDocument, 'mouseup', this._onDrop);\n off(ownerDocument, 'touchend', this._onDrop);\n off(ownerDocument, 'pointerup', this._onDrop);\n off(ownerDocument, 'touchcancel', this._onDrop);\n off(document, 'selectstart', this);\n },\n _onDrop: function _onDrop(\n /**Event*/\n evt) {\n var el = this.el,\n options = this.options; // Get the index of the dragged element within its parent\n\n newIndex = index(dragEl);\n newDraggableIndex = index(dragEl, options.draggable);\n pluginEvent('drop', this, {\n evt: evt\n });\n parentEl = dragEl && dragEl.parentNode; // Get again after plugin event\n\n newIndex = index(dragEl);\n newDraggableIndex = index(dragEl, options.draggable);\n\n if (Sortable.eventCanceled) {\n this._nulling();\n\n return;\n }\n\n awaitingDragStarted = false;\n isCircumstantialInvert = false;\n pastFirstInvertThresh = false;\n clearInterval(this._loopId);\n clearTimeout(this._dragStartTimer);\n\n _cancelNextTick(this.cloneId);\n\n _cancelNextTick(this._dragStartId); // Unbind events\n\n\n if (this.nativeDraggable) {\n off(document, 'drop', this);\n off(el, 'dragstart', this._onDragStart);\n }\n\n this._offMoveEvents();\n\n this._offUpEvents();\n\n if (Safari) {\n css(document.body, 'user-select', '');\n }\n\n css(dragEl, 'transform', '');\n\n if (evt) {\n if (moved) {\n evt.cancelable && evt.preventDefault();\n !options.dropBubble && evt.stopPropagation();\n }\n\n ghostEl && ghostEl.parentNode && ghostEl.parentNode.removeChild(ghostEl);\n\n if (rootEl === parentEl || putSortable && putSortable.lastPutMode !== 'clone') {\n // Remove clone(s)\n cloneEl && cloneEl.parentNode && cloneEl.parentNode.removeChild(cloneEl);\n }\n\n if (dragEl) {\n if (this.nativeDraggable) {\n off(dragEl, 'dragend', this);\n }\n\n _disableDraggable(dragEl);\n\n dragEl.style['will-change'] = ''; // Remove classes\n // ghostClass is added in dragStarted\n\n if (moved && !awaitingDragStarted) {\n toggleClass(dragEl, putSortable ? putSortable.options.ghostClass : this.options.ghostClass, false);\n }\n\n toggleClass(dragEl, this.options.chosenClass, false); // Drag stop event\n\n _dispatchEvent({\n sortable: this,\n name: 'unchoose',\n toEl: parentEl,\n newIndex: null,\n newDraggableIndex: null,\n originalEvent: evt\n });\n\n if (rootEl !== parentEl) {\n if (newIndex >= 0) {\n // Add event\n _dispatchEvent({\n rootEl: parentEl,\n name: 'add',\n toEl: parentEl,\n fromEl: rootEl,\n originalEvent: evt\n }); // Remove event\n\n\n _dispatchEvent({\n sortable: this,\n name: 'remove',\n toEl: parentEl,\n originalEvent: evt\n }); // drag from one list and drop into another\n\n\n _dispatchEvent({\n rootEl: parentEl,\n name: 'sort',\n toEl: parentEl,\n fromEl: rootEl,\n originalEvent: evt\n });\n\n _dispatchEvent({\n sortable: this,\n name: 'sort',\n toEl: parentEl,\n originalEvent: evt\n });\n }\n\n putSortable && putSortable.save();\n } else {\n if (newIndex !== oldIndex) {\n if (newIndex >= 0) {\n // drag & drop within the same list\n _dispatchEvent({\n sortable: this,\n name: 'update',\n toEl: parentEl,\n originalEvent: evt\n });\n\n _dispatchEvent({\n sortable: this,\n name: 'sort',\n toEl: parentEl,\n originalEvent: evt\n });\n }\n }\n }\n\n if (Sortable.active) {\n /* jshint eqnull:true */\n if (newIndex == null || newIndex === -1) {\n newIndex = oldIndex;\n newDraggableIndex = oldDraggableIndex;\n }\n\n _dispatchEvent({\n sortable: this,\n name: 'end',\n toEl: parentEl,\n originalEvent: evt\n }); // Save sorting\n\n\n this.save();\n }\n }\n }\n\n this._nulling();\n },\n _nulling: function _nulling() {\n pluginEvent('nulling', this);\n rootEl = dragEl = parentEl = ghostEl = nextEl = cloneEl = lastDownEl = cloneHidden = tapEvt = touchEvt = moved = newIndex = newDraggableIndex = oldIndex = oldDraggableIndex = lastTarget = lastDirection = putSortable = activeGroup = Sortable.dragged = Sortable.ghost = Sortable.clone = Sortable.active = null;\n savedInputChecked.forEach(function (el) {\n el.checked = true;\n });\n savedInputChecked.length = lastDx = lastDy = 0;\n },\n handleEvent: function handleEvent(\n /**Event*/\n evt) {\n switch (evt.type) {\n case 'drop':\n case 'dragend':\n this._onDrop(evt);\n\n break;\n\n case 'dragenter':\n case 'dragover':\n if (dragEl) {\n this._onDragOver(evt);\n\n _globalDragOver(evt);\n }\n\n break;\n\n case 'selectstart':\n evt.preventDefault();\n break;\n }\n },\n\n /**\n * Serializes the item into an array of string.\n * @returns {String[]}\n */\n toArray: function toArray() {\n var order = [],\n el,\n children = this.el.children,\n i = 0,\n n = children.length,\n options = this.options;\n\n for (; i < n; i++) {\n el = children[i];\n\n if (closest(el, options.draggable, this.el, false)) {\n order.push(el.getAttribute(options.dataIdAttr) || _generateId(el));\n }\n }\n\n return order;\n },\n\n /**\n * Sorts the elements according to the array.\n * @param {String[]} order order of the items\n */\n sort: function sort(order, useAnimation) {\n var items = {},\n rootEl = this.el;\n this.toArray().forEach(function (id, i) {\n var el = rootEl.children[i];\n\n if (closest(el, this.options.draggable, rootEl, false)) {\n items[id] = el;\n }\n }, this);\n useAnimation && this.captureAnimationState();\n order.forEach(function (id) {\n if (items[id]) {\n rootEl.removeChild(items[id]);\n rootEl.appendChild(items[id]);\n }\n });\n useAnimation && this.animateAll();\n },\n\n /**\n * Save the current sorting\n */\n save: function save() {\n var store = this.options.store;\n store && store.set && store.set(this);\n },\n\n /**\n * For each element in the set, get the first element that matches the selector by testing the element itself and traversing up through its ancestors in the DOM tree.\n * @param {HTMLElement} el\n * @param {String} [selector] default: `options.draggable`\n * @returns {HTMLElement|null}\n */\n closest: function closest$1(el, selector) {\n return closest(el, selector || this.options.draggable, this.el, false);\n },\n\n /**\n * Set/get option\n * @param {string} name\n * @param {*} [value]\n * @returns {*}\n */\n option: function option(name, value) {\n var options = this.options;\n\n if (value === void 0) {\n return options[name];\n } else {\n var modifiedValue = PluginManager.modifyOption(this, name, value);\n\n if (typeof modifiedValue !== 'undefined') {\n options[name] = modifiedValue;\n } else {\n options[name] = value;\n }\n\n if (name === 'group') {\n _prepareGroup(options);\n }\n }\n },\n\n /**\n * Destroy\n */\n destroy: function destroy() {\n pluginEvent('destroy', this);\n var el = this.el;\n el[expando] = null;\n off(el, 'mousedown', this._onTapStart);\n off(el, 'touchstart', this._onTapStart);\n off(el, 'pointerdown', this._onTapStart);\n\n if (this.nativeDraggable) {\n off(el, 'dragover', this);\n off(el, 'dragenter', this);\n } // Remove draggable attributes\n\n\n Array.prototype.forEach.call(el.querySelectorAll('[draggable]'), function (el) {\n el.removeAttribute('draggable');\n });\n\n this._onDrop();\n\n this._disableDelayedDragEvents();\n\n sortables.splice(sortables.indexOf(this.el), 1);\n this.el = el = null;\n },\n _hideClone: function _hideClone() {\n if (!cloneHidden) {\n pluginEvent('hideClone', this);\n if (Sortable.eventCanceled) return;\n css(cloneEl, 'display', 'none');\n\n if (this.options.removeCloneOnHide && cloneEl.parentNode) {\n cloneEl.parentNode.removeChild(cloneEl);\n }\n\n cloneHidden = true;\n }\n },\n _showClone: function _showClone(putSortable) {\n if (putSortable.lastPutMode !== 'clone') {\n this._hideClone();\n\n return;\n }\n\n if (cloneHidden) {\n pluginEvent('showClone', this);\n if (Sortable.eventCanceled) return; // show clone at dragEl or original position\n\n if (dragEl.parentNode == rootEl && !this.options.group.revertClone) {\n rootEl.insertBefore(cloneEl, dragEl);\n } else if (nextEl) {\n rootEl.insertBefore(cloneEl, nextEl);\n } else {\n rootEl.appendChild(cloneEl);\n }\n\n if (this.options.group.revertClone) {\n this.animate(dragEl, cloneEl);\n }\n\n css(cloneEl, 'display', '');\n cloneHidden = false;\n }\n }\n};\n\nfunction _globalDragOver(\n/**Event*/\nevt) {\n if (evt.dataTransfer) {\n evt.dataTransfer.dropEffect = 'move';\n }\n\n evt.cancelable && evt.preventDefault();\n}\n\nfunction _onMove(fromEl, toEl, dragEl, dragRect, targetEl, targetRect, originalEvent, willInsertAfter) {\n var evt,\n sortable = fromEl[expando],\n onMoveFn = sortable.options.onMove,\n retVal; // Support for new CustomEvent feature\n\n if (window.CustomEvent && !IE11OrLess && !Edge) {\n evt = new CustomEvent('move', {\n bubbles: true,\n cancelable: true\n });\n } else {\n evt = document.createEvent('Event');\n evt.initEvent('move', true, true);\n }\n\n evt.to = toEl;\n evt.from = fromEl;\n evt.dragged = dragEl;\n evt.draggedRect = dragRect;\n evt.related = targetEl || toEl;\n evt.relatedRect = targetRect || getRect(toEl);\n evt.willInsertAfter = willInsertAfter;\n evt.originalEvent = originalEvent;\n fromEl.dispatchEvent(evt);\n\n if (onMoveFn) {\n retVal = onMoveFn.call(sortable, evt, originalEvent);\n }\n\n return retVal;\n}\n\nfunction _disableDraggable(el) {\n el.draggable = false;\n}\n\nfunction _unsilent() {\n _silent = false;\n}\n\nfunction _ghostIsFirst(evt, vertical, sortable) {\n var rect = getRect(getChild(sortable.el, 0, sortable.options, true));\n var spacer = 10;\n return vertical ? evt.clientX < rect.left - spacer || evt.clientY < rect.top && evt.clientX < rect.right : evt.clientY < rect.top - spacer || evt.clientY < rect.bottom && evt.clientX < rect.left;\n}\n\nfunction _ghostIsLast(evt, vertical, sortable) {\n var rect = getRect(lastChild(sortable.el, sortable.options.draggable));\n var spacer = 10;\n return vertical ? evt.clientX > rect.right + spacer || evt.clientX <= rect.right && evt.clientY > rect.bottom && evt.clientX >= rect.left : evt.clientX > rect.right && evt.clientY > rect.top || evt.clientX <= rect.right && evt.clientY > rect.bottom + spacer;\n}\n\nfunction _getSwapDirection(evt, target, targetRect, vertical, swapThreshold, invertedSwapThreshold, invertSwap, isLastTarget) {\n var mouseOnAxis = vertical ? evt.clientY : evt.clientX,\n targetLength = vertical ? targetRect.height : targetRect.width,\n targetS1 = vertical ? targetRect.top : targetRect.left,\n targetS2 = vertical ? targetRect.bottom : targetRect.right,\n invert = false;\n\n if (!invertSwap) {\n // Never invert or create dragEl shadow when target movemenet causes mouse to move past the end of regular swapThreshold\n if (isLastTarget && targetMoveDistance < targetLength * swapThreshold) {\n // multiplied only by swapThreshold because mouse will already be inside target by (1 - threshold) * targetLength / 2\n // check if past first invert threshold on side opposite of lastDirection\n if (!pastFirstInvertThresh && (lastDirection === 1 ? mouseOnAxis > targetS1 + targetLength * invertedSwapThreshold / 2 : mouseOnAxis < targetS2 - targetLength * invertedSwapThreshold / 2)) {\n // past first invert threshold, do not restrict inverted threshold to dragEl shadow\n pastFirstInvertThresh = true;\n }\n\n if (!pastFirstInvertThresh) {\n // dragEl shadow (target move distance shadow)\n if (lastDirection === 1 ? mouseOnAxis < targetS1 + targetMoveDistance // over dragEl shadow\n : mouseOnAxis > targetS2 - targetMoveDistance) {\n return -lastDirection;\n }\n } else {\n invert = true;\n }\n } else {\n // Regular\n if (mouseOnAxis > targetS1 + targetLength * (1 - swapThreshold) / 2 && mouseOnAxis < targetS2 - targetLength * (1 - swapThreshold) / 2) {\n return _getInsertDirection(target);\n }\n }\n }\n\n invert = invert || invertSwap;\n\n if (invert) {\n // Invert of regular\n if (mouseOnAxis < targetS1 + targetLength * invertedSwapThreshold / 2 || mouseOnAxis > targetS2 - targetLength * invertedSwapThreshold / 2) {\n return mouseOnAxis > targetS1 + targetLength / 2 ? 1 : -1;\n }\n }\n\n return 0;\n}\n/**\n * Gets the direction dragEl must be swapped relative to target in order to make it\n * seem that dragEl has been \"inserted\" into that element's position\n * @param {HTMLElement} target The target whose position dragEl is being inserted at\n * @return {Number} Direction dragEl must be swapped\n */\n\n\nfunction _getInsertDirection(target) {\n if (index(dragEl) < index(target)) {\n return 1;\n } else {\n return -1;\n }\n}\n/**\n * Generate id\n * @param {HTMLElement} el\n * @returns {String}\n * @private\n */\n\n\nfunction _generateId(el) {\n var str = el.tagName + el.className + el.src + el.href + el.textContent,\n i = str.length,\n sum = 0;\n\n while (i--) {\n sum += str.charCodeAt(i);\n }\n\n return sum.toString(36);\n}\n\nfunction _saveInputCheckedState(root) {\n savedInputChecked.length = 0;\n var inputs = root.getElementsByTagName('input');\n var idx = inputs.length;\n\n while (idx--) {\n var el = inputs[idx];\n el.checked && savedInputChecked.push(el);\n }\n}\n\nfunction _nextTick(fn) {\n return setTimeout(fn, 0);\n}\n\nfunction _cancelNextTick(id) {\n return clearTimeout(id);\n} // Fixed #973:\n\n\nif (documentExists) {\n on(document, 'touchmove', function (evt) {\n if ((Sortable.active || awaitingDragStarted) && evt.cancelable) {\n evt.preventDefault();\n }\n });\n} // Export utils\n\n\nSortable.utils = {\n on: on,\n off: off,\n css: css,\n find: find,\n is: function is(el, selector) {\n return !!closest(el, selector, el, false);\n },\n extend: extend,\n throttle: throttle,\n closest: closest,\n toggleClass: toggleClass,\n clone: clone,\n index: index,\n nextTick: _nextTick,\n cancelNextTick: _cancelNextTick,\n detectDirection: _detectDirection,\n getChild: getChild\n};\n/**\n * Get the Sortable instance of an element\n * @param {HTMLElement} element The element\n * @return {Sortable|undefined} The instance of Sortable\n */\n\nSortable.get = function (element) {\n return element[expando];\n};\n/**\n * Mount a plugin to Sortable\n * @param {...SortablePlugin|SortablePlugin[]} plugins Plugins being mounted\n */\n\n\nSortable.mount = function () {\n for (var _len = arguments.length, plugins = new Array(_len), _key = 0; _key < _len; _key++) {\n plugins[_key] = arguments[_key];\n }\n\n if (plugins[0].constructor === Array) plugins = plugins[0];\n plugins.forEach(function (plugin) {\n if (!plugin.prototype || !plugin.prototype.constructor) {\n throw \"Sortable: Mounted plugin must be a constructor function, not \".concat({}.toString.call(plugin));\n }\n\n if (plugin.utils) Sortable.utils = _objectSpread2(_objectSpread2({}, Sortable.utils), plugin.utils);\n PluginManager.mount(plugin);\n });\n};\n/**\n * Create sortable instance\n * @param {HTMLElement} el\n * @param {Object} [options]\n */\n\n\nSortable.create = function (el, options) {\n return new Sortable(el, options);\n}; // Export\n\n\nSortable.version = version;\n\nvar autoScrolls = [],\n scrollEl,\n scrollRootEl,\n scrolling = false,\n lastAutoScrollX,\n lastAutoScrollY,\n touchEvt$1,\n pointerElemChangedInterval;\n\nfunction AutoScrollPlugin() {\n function AutoScroll() {\n this.defaults = {\n scroll: true,\n forceAutoScrollFallback: false,\n scrollSensitivity: 30,\n scrollSpeed: 10,\n bubbleScroll: true\n }; // Bind all private methods\n\n for (var fn in this) {\n if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {\n this[fn] = this[fn].bind(this);\n }\n }\n }\n\n AutoScroll.prototype = {\n dragStarted: function dragStarted(_ref) {\n var originalEvent = _ref.originalEvent;\n\n if (this.sortable.nativeDraggable) {\n on(document, 'dragover', this._handleAutoScroll);\n } else {\n if (this.options.supportPointer) {\n on(document, 'pointermove', this._handleFallbackAutoScroll);\n } else if (originalEvent.touches) {\n on(document, 'touchmove', this._handleFallbackAutoScroll);\n } else {\n on(document, 'mousemove', this._handleFallbackAutoScroll);\n }\n }\n },\n dragOverCompleted: function dragOverCompleted(_ref2) {\n var originalEvent = _ref2.originalEvent;\n\n // For when bubbling is canceled and using fallback (fallback 'touchmove' always reached)\n if (!this.options.dragOverBubble && !originalEvent.rootEl) {\n this._handleAutoScroll(originalEvent);\n }\n },\n drop: function drop() {\n if (this.sortable.nativeDraggable) {\n off(document, 'dragover', this._handleAutoScroll);\n } else {\n off(document, 'pointermove', this._handleFallbackAutoScroll);\n off(document, 'touchmove', this._handleFallbackAutoScroll);\n off(document, 'mousemove', this._handleFallbackAutoScroll);\n }\n\n clearPointerElemChangedInterval();\n clearAutoScrolls();\n cancelThrottle();\n },\n nulling: function nulling() {\n touchEvt$1 = scrollRootEl = scrollEl = scrolling = pointerElemChangedInterval = lastAutoScrollX = lastAutoScrollY = null;\n autoScrolls.length = 0;\n },\n _handleFallbackAutoScroll: function _handleFallbackAutoScroll(evt) {\n this._handleAutoScroll(evt, true);\n },\n _handleAutoScroll: function _handleAutoScroll(evt, fallback) {\n var _this = this;\n\n var x = (evt.touches ? evt.touches[0] : evt).clientX,\n y = (evt.touches ? evt.touches[0] : evt).clientY,\n elem = document.elementFromPoint(x, y);\n touchEvt$1 = evt; // IE does not seem to have native autoscroll,\n // Edge's autoscroll seems too conditional,\n // MACOS Safari does not have autoscroll,\n // Firefox and Chrome are good\n\n if (fallback || this.options.forceAutoScrollFallback || Edge || IE11OrLess || Safari) {\n autoScroll(evt, this.options, elem, fallback); // Listener for pointer element change\n\n var ogElemScroller = getParentAutoScrollElement(elem, true);\n\n if (scrolling && (!pointerElemChangedInterval || x !== lastAutoScrollX || y !== lastAutoScrollY)) {\n pointerElemChangedInterval && clearPointerElemChangedInterval(); // Detect for pointer elem change, emulating native DnD behaviour\n\n pointerElemChangedInterval = setInterval(function () {\n var newElem = getParentAutoScrollElement(document.elementFromPoint(x, y), true);\n\n if (newElem !== ogElemScroller) {\n ogElemScroller = newElem;\n clearAutoScrolls();\n }\n\n autoScroll(evt, _this.options, newElem, fallback);\n }, 10);\n lastAutoScrollX = x;\n lastAutoScrollY = y;\n }\n } else {\n // if DnD is enabled (and browser has good autoscrolling), first autoscroll will already scroll, so get parent autoscroll of first autoscroll\n if (!this.options.bubbleScroll || getParentAutoScrollElement(elem, true) === getWindowScrollingElement()) {\n clearAutoScrolls();\n return;\n }\n\n autoScroll(evt, this.options, getParentAutoScrollElement(elem, false), false);\n }\n }\n };\n return _extends(AutoScroll, {\n pluginName: 'scroll',\n initializeByDefault: true\n });\n}\n\nfunction clearAutoScrolls() {\n autoScrolls.forEach(function (autoScroll) {\n clearInterval(autoScroll.pid);\n });\n autoScrolls = [];\n}\n\nfunction clearPointerElemChangedInterval() {\n clearInterval(pointerElemChangedInterval);\n}\n\nvar autoScroll = throttle(function (evt, options, rootEl, isFallback) {\n // Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=505521\n if (!options.scroll) return;\n var x = (evt.touches ? evt.touches[0] : evt).clientX,\n y = (evt.touches ? evt.touches[0] : evt).clientY,\n sens = options.scrollSensitivity,\n speed = options.scrollSpeed,\n winScroller = getWindowScrollingElement();\n var scrollThisInstance = false,\n scrollCustomFn; // New scroll root, set scrollEl\n\n if (scrollRootEl !== rootEl) {\n scrollRootEl = rootEl;\n clearAutoScrolls();\n scrollEl = options.scroll;\n scrollCustomFn = options.scrollFn;\n\n if (scrollEl === true) {\n scrollEl = getParentAutoScrollElement(rootEl, true);\n }\n }\n\n var layersOut = 0;\n var currentParent = scrollEl;\n\n do {\n var el = currentParent,\n rect = getRect(el),\n top = rect.top,\n bottom = rect.bottom,\n left = rect.left,\n right = rect.right,\n width = rect.width,\n height = rect.height,\n canScrollX = void 0,\n canScrollY = void 0,\n scrollWidth = el.scrollWidth,\n scrollHeight = el.scrollHeight,\n elCSS = css(el),\n scrollPosX = el.scrollLeft,\n scrollPosY = el.scrollTop;\n\n if (el === winScroller) {\n canScrollX = width < scrollWidth && (elCSS.overflowX === 'auto' || elCSS.overflowX === 'scroll' || elCSS.overflowX === 'visible');\n canScrollY = height < scrollHeight && (elCSS.overflowY === 'auto' || elCSS.overflowY === 'scroll' || elCSS.overflowY === 'visible');\n } else {\n canScrollX = width < scrollWidth && (elCSS.overflowX === 'auto' || elCSS.overflowX === 'scroll');\n canScrollY = height < scrollHeight && (elCSS.overflowY === 'auto' || elCSS.overflowY === 'scroll');\n }\n\n var vx = canScrollX && (Math.abs(right - x) <= sens && scrollPosX + width < scrollWidth) - (Math.abs(left - x) <= sens && !!scrollPosX);\n var vy = canScrollY && (Math.abs(bottom - y) <= sens && scrollPosY + height < scrollHeight) - (Math.abs(top - y) <= sens && !!scrollPosY);\n\n if (!autoScrolls[layersOut]) {\n for (var i = 0; i <= layersOut; i++) {\n if (!autoScrolls[i]) {\n autoScrolls[i] = {};\n }\n }\n }\n\n if (autoScrolls[layersOut].vx != vx || autoScrolls[layersOut].vy != vy || autoScrolls[layersOut].el !== el) {\n autoScrolls[layersOut].el = el;\n autoScrolls[layersOut].vx = vx;\n autoScrolls[layersOut].vy = vy;\n clearInterval(autoScrolls[layersOut].pid);\n\n if (vx != 0 || vy != 0) {\n scrollThisInstance = true;\n /* jshint loopfunc:true */\n\n autoScrolls[layersOut].pid = setInterval(function () {\n // emulate drag over during autoscroll (fallback), emulating native DnD behaviour\n if (isFallback && this.layer === 0) {\n Sortable.active._onTouchMove(touchEvt$1); // To move ghost if it is positioned absolutely\n\n }\n\n var scrollOffsetY = autoScrolls[this.layer].vy ? autoScrolls[this.layer].vy * speed : 0;\n var scrollOffsetX = autoScrolls[this.layer].vx ? autoScrolls[this.layer].vx * speed : 0;\n\n if (typeof scrollCustomFn === 'function') {\n if (scrollCustomFn.call(Sortable.dragged.parentNode[expando], scrollOffsetX, scrollOffsetY, evt, touchEvt$1, autoScrolls[this.layer].el) !== 'continue') {\n return;\n }\n }\n\n scrollBy(autoScrolls[this.layer].el, scrollOffsetX, scrollOffsetY);\n }.bind({\n layer: layersOut\n }), 24);\n }\n }\n\n layersOut++;\n } while (options.bubbleScroll && currentParent !== winScroller && (currentParent = getParentAutoScrollElement(currentParent, false)));\n\n scrolling = scrollThisInstance; // in case another function catches scrolling as false in between when it is not\n}, 30);\n\nvar drop = function drop(_ref) {\n var originalEvent = _ref.originalEvent,\n putSortable = _ref.putSortable,\n dragEl = _ref.dragEl,\n activeSortable = _ref.activeSortable,\n dispatchSortableEvent = _ref.dispatchSortableEvent,\n hideGhostForTarget = _ref.hideGhostForTarget,\n unhideGhostForTarget = _ref.unhideGhostForTarget;\n if (!originalEvent) return;\n var toSortable = putSortable || activeSortable;\n hideGhostForTarget();\n var touch = originalEvent.changedTouches && originalEvent.changedTouches.length ? originalEvent.changedTouches[0] : originalEvent;\n var target = document.elementFromPoint(touch.clientX, touch.clientY);\n unhideGhostForTarget();\n\n if (toSortable && !toSortable.el.contains(target)) {\n dispatchSortableEvent('spill');\n this.onSpill({\n dragEl: dragEl,\n putSortable: putSortable\n });\n }\n};\n\nfunction Revert() {}\n\nRevert.prototype = {\n startIndex: null,\n dragStart: function dragStart(_ref2) {\n var oldDraggableIndex = _ref2.oldDraggableIndex;\n this.startIndex = oldDraggableIndex;\n },\n onSpill: function onSpill(_ref3) {\n var dragEl = _ref3.dragEl,\n putSortable = _ref3.putSortable;\n this.sortable.captureAnimationState();\n\n if (putSortable) {\n putSortable.captureAnimationState();\n }\n\n var nextSibling = getChild(this.sortable.el, this.startIndex, this.options);\n\n if (nextSibling) {\n this.sortable.el.insertBefore(dragEl, nextSibling);\n } else {\n this.sortable.el.appendChild(dragEl);\n }\n\n this.sortable.animateAll();\n\n if (putSortable) {\n putSortable.animateAll();\n }\n },\n drop: drop\n};\n\n_extends(Revert, {\n pluginName: 'revertOnSpill'\n});\n\nfunction Remove() {}\n\nRemove.prototype = {\n onSpill: function onSpill(_ref4) {\n var dragEl = _ref4.dragEl,\n putSortable = _ref4.putSortable;\n var parentSortable = putSortable || this.sortable;\n parentSortable.captureAnimationState();\n dragEl.parentNode && dragEl.parentNode.removeChild(dragEl);\n parentSortable.animateAll();\n },\n drop: drop\n};\n\n_extends(Remove, {\n pluginName: 'removeOnSpill'\n});\n\nvar lastSwapEl;\n\nfunction SwapPlugin() {\n function Swap() {\n this.defaults = {\n swapClass: 'sortable-swap-highlight'\n };\n }\n\n Swap.prototype = {\n dragStart: function dragStart(_ref) {\n var dragEl = _ref.dragEl;\n lastSwapEl = dragEl;\n },\n dragOverValid: function dragOverValid(_ref2) {\n var completed = _ref2.completed,\n target = _ref2.target,\n onMove = _ref2.onMove,\n activeSortable = _ref2.activeSortable,\n changed = _ref2.changed,\n cancel = _ref2.cancel;\n if (!activeSortable.options.swap) return;\n var el = this.sortable.el,\n options = this.options;\n\n if (target && target !== el) {\n var prevSwapEl = lastSwapEl;\n\n if (onMove(target) !== false) {\n toggleClass(target, options.swapClass, true);\n lastSwapEl = target;\n } else {\n lastSwapEl = null;\n }\n\n if (prevSwapEl && prevSwapEl !== lastSwapEl) {\n toggleClass(prevSwapEl, options.swapClass, false);\n }\n }\n\n changed();\n completed(true);\n cancel();\n },\n drop: function drop(_ref3) {\n var activeSortable = _ref3.activeSortable,\n putSortable = _ref3.putSortable,\n dragEl = _ref3.dragEl;\n var toSortable = putSortable || this.sortable;\n var options = this.options;\n lastSwapEl && toggleClass(lastSwapEl, options.swapClass, false);\n\n if (lastSwapEl && (options.swap || putSortable && putSortable.options.swap)) {\n if (dragEl !== lastSwapEl) {\n toSortable.captureAnimationState();\n if (toSortable !== activeSortable) activeSortable.captureAnimationState();\n swapNodes(dragEl, lastSwapEl);\n toSortable.animateAll();\n if (toSortable !== activeSortable) activeSortable.animateAll();\n }\n }\n },\n nulling: function nulling() {\n lastSwapEl = null;\n }\n };\n return _extends(Swap, {\n pluginName: 'swap',\n eventProperties: function eventProperties() {\n return {\n swapItem: lastSwapEl\n };\n }\n });\n}\n\nfunction swapNodes(n1, n2) {\n var p1 = n1.parentNode,\n p2 = n2.parentNode,\n i1,\n i2;\n if (!p1 || !p2 || p1.isEqualNode(n2) || p2.isEqualNode(n1)) return;\n i1 = index(n1);\n i2 = index(n2);\n\n if (p1.isEqualNode(p2) && i1 < i2) {\n i2++;\n }\n\n p1.insertBefore(n2, p1.children[i1]);\n p2.insertBefore(n1, p2.children[i2]);\n}\n\nvar multiDragElements = [],\n multiDragClones = [],\n lastMultiDragSelect,\n // for selection with modifier key down (SHIFT)\nmultiDragSortable,\n initialFolding = false,\n // Initial multi-drag fold when drag started\nfolding = false,\n // Folding any other time\ndragStarted = false,\n dragEl$1,\n clonesFromRect,\n clonesHidden;\n\nfunction MultiDragPlugin() {\n function MultiDrag(sortable) {\n // Bind all private methods\n for (var fn in this) {\n if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {\n this[fn] = this[fn].bind(this);\n }\n }\n\n if (sortable.options.supportPointer) {\n on(document, 'pointerup', this._deselectMultiDrag);\n } else {\n on(document, 'mouseup', this._deselectMultiDrag);\n on(document, 'touchend', this._deselectMultiDrag);\n }\n\n on(document, 'keydown', this._checkKeyDown);\n on(document, 'keyup', this._checkKeyUp);\n this.defaults = {\n selectedClass: 'sortable-selected',\n multiDragKey: null,\n setData: function setData(dataTransfer, dragEl) {\n var data = '';\n\n if (multiDragElements.length && multiDragSortable === sortable) {\n multiDragElements.forEach(function (multiDragElement, i) {\n data += (!i ? '' : ', ') + multiDragElement.textContent;\n });\n } else {\n data = dragEl.textContent;\n }\n\n dataTransfer.setData('Text', data);\n }\n };\n }\n\n MultiDrag.prototype = {\n multiDragKeyDown: false,\n isMultiDrag: false,\n delayStartGlobal: function delayStartGlobal(_ref) {\n var dragged = _ref.dragEl;\n dragEl$1 = dragged;\n },\n delayEnded: function delayEnded() {\n this.isMultiDrag = ~multiDragElements.indexOf(dragEl$1);\n },\n setupClone: function setupClone(_ref2) {\n var sortable = _ref2.sortable,\n cancel = _ref2.cancel;\n if (!this.isMultiDrag) return;\n\n for (var i = 0; i < multiDragElements.length; i++) {\n multiDragClones.push(clone(multiDragElements[i]));\n multiDragClones[i].sortableIndex = multiDragElements[i].sortableIndex;\n multiDragClones[i].draggable = false;\n multiDragClones[i].style['will-change'] = '';\n toggleClass(multiDragClones[i], this.options.selectedClass, false);\n multiDragElements[i] === dragEl$1 && toggleClass(multiDragClones[i], this.options.chosenClass, false);\n }\n\n sortable._hideClone();\n\n cancel();\n },\n clone: function clone(_ref3) {\n var sortable = _ref3.sortable,\n rootEl = _ref3.rootEl,\n dispatchSortableEvent = _ref3.dispatchSortableEvent,\n cancel = _ref3.cancel;\n if (!this.isMultiDrag) return;\n\n if (!this.options.removeCloneOnHide) {\n if (multiDragElements.length && multiDragSortable === sortable) {\n insertMultiDragClones(true, rootEl);\n dispatchSortableEvent('clone');\n cancel();\n }\n }\n },\n showClone: function showClone(_ref4) {\n var cloneNowShown = _ref4.cloneNowShown,\n rootEl = _ref4.rootEl,\n cancel = _ref4.cancel;\n if (!this.isMultiDrag) return;\n insertMultiDragClones(false, rootEl);\n multiDragClones.forEach(function (clone) {\n css(clone, 'display', '');\n });\n cloneNowShown();\n clonesHidden = false;\n cancel();\n },\n hideClone: function hideClone(_ref5) {\n var _this = this;\n\n var sortable = _ref5.sortable,\n cloneNowHidden = _ref5.cloneNowHidden,\n cancel = _ref5.cancel;\n if (!this.isMultiDrag) return;\n multiDragClones.forEach(function (clone) {\n css(clone, 'display', 'none');\n\n if (_this.options.removeCloneOnHide && clone.parentNode) {\n clone.parentNode.removeChild(clone);\n }\n });\n cloneNowHidden();\n clonesHidden = true;\n cancel();\n },\n dragStartGlobal: function dragStartGlobal(_ref6) {\n var sortable = _ref6.sortable;\n\n if (!this.isMultiDrag && multiDragSortable) {\n multiDragSortable.multiDrag._deselectMultiDrag();\n }\n\n multiDragElements.forEach(function (multiDragElement) {\n multiDragElement.sortableIndex = index(multiDragElement);\n }); // Sort multi-drag elements\n\n multiDragElements = multiDragElements.sort(function (a, b) {\n return a.sortableIndex - b.sortableIndex;\n });\n dragStarted = true;\n },\n dragStarted: function dragStarted(_ref7) {\n var _this2 = this;\n\n var sortable = _ref7.sortable;\n if (!this.isMultiDrag) return;\n\n if (this.options.sort) {\n // Capture rects,\n // hide multi drag elements (by positioning them absolute),\n // set multi drag elements rects to dragRect,\n // show multi drag elements,\n // animate to rects,\n // unset rects & remove from DOM\n sortable.captureAnimationState();\n\n if (this.options.animation) {\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n css(multiDragElement, 'position', 'absolute');\n });\n var dragRect = getRect(dragEl$1, false, true, true);\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n setRect(multiDragElement, dragRect);\n });\n folding = true;\n initialFolding = true;\n }\n }\n\n sortable.animateAll(function () {\n folding = false;\n initialFolding = false;\n\n if (_this2.options.animation) {\n multiDragElements.forEach(function (multiDragElement) {\n unsetRect(multiDragElement);\n });\n } // Remove all auxiliary multidrag items from el, if sorting enabled\n\n\n if (_this2.options.sort) {\n removeMultiDragElements();\n }\n });\n },\n dragOver: function dragOver(_ref8) {\n var target = _ref8.target,\n completed = _ref8.completed,\n cancel = _ref8.cancel;\n\n if (folding && ~multiDragElements.indexOf(target)) {\n completed(false);\n cancel();\n }\n },\n revert: function revert(_ref9) {\n var fromSortable = _ref9.fromSortable,\n rootEl = _ref9.rootEl,\n sortable = _ref9.sortable,\n dragRect = _ref9.dragRect;\n\n if (multiDragElements.length > 1) {\n // Setup unfold animation\n multiDragElements.forEach(function (multiDragElement) {\n sortable.addAnimationState({\n target: multiDragElement,\n rect: folding ? getRect(multiDragElement) : dragRect\n });\n unsetRect(multiDragElement);\n multiDragElement.fromRect = dragRect;\n fromSortable.removeAnimationState(multiDragElement);\n });\n folding = false;\n insertMultiDragElements(!this.options.removeCloneOnHide, rootEl);\n }\n },\n dragOverCompleted: function dragOverCompleted(_ref10) {\n var sortable = _ref10.sortable,\n isOwner = _ref10.isOwner,\n insertion = _ref10.insertion,\n activeSortable = _ref10.activeSortable,\n parentEl = _ref10.parentEl,\n putSortable = _ref10.putSortable;\n var options = this.options;\n\n if (insertion) {\n // Clones must be hidden before folding animation to capture dragRectAbsolute properly\n if (isOwner) {\n activeSortable._hideClone();\n }\n\n initialFolding = false; // If leaving sort:false root, or already folding - Fold to new location\n\n if (options.animation && multiDragElements.length > 1 && (folding || !isOwner && !activeSortable.options.sort && !putSortable)) {\n // Fold: Set all multi drag elements's rects to dragEl's rect when multi-drag elements are invisible\n var dragRectAbsolute = getRect(dragEl$1, false, true, true);\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n setRect(multiDragElement, dragRectAbsolute); // Move element(s) to end of parentEl so that it does not interfere with multi-drag clones insertion if they are inserted\n // while folding, and so that we can capture them again because old sortable will no longer be fromSortable\n\n parentEl.appendChild(multiDragElement);\n });\n folding = true;\n } // Clones must be shown (and check to remove multi drags) after folding when interfering multiDragElements are moved out\n\n\n if (!isOwner) {\n // Only remove if not folding (folding will remove them anyways)\n if (!folding) {\n removeMultiDragElements();\n }\n\n if (multiDragElements.length > 1) {\n var clonesHiddenBefore = clonesHidden;\n\n activeSortable._showClone(sortable); // Unfold animation for clones if showing from hidden\n\n\n if (activeSortable.options.animation && !clonesHidden && clonesHiddenBefore) {\n multiDragClones.forEach(function (clone) {\n activeSortable.addAnimationState({\n target: clone,\n rect: clonesFromRect\n });\n clone.fromRect = clonesFromRect;\n clone.thisAnimationDuration = null;\n });\n }\n } else {\n activeSortable._showClone(sortable);\n }\n }\n }\n },\n dragOverAnimationCapture: function dragOverAnimationCapture(_ref11) {\n var dragRect = _ref11.dragRect,\n isOwner = _ref11.isOwner,\n activeSortable = _ref11.activeSortable;\n multiDragElements.forEach(function (multiDragElement) {\n multiDragElement.thisAnimationDuration = null;\n });\n\n if (activeSortable.options.animation && !isOwner && activeSortable.multiDrag.isMultiDrag) {\n clonesFromRect = _extends({}, dragRect);\n var dragMatrix = matrix(dragEl$1, true);\n clonesFromRect.top -= dragMatrix.f;\n clonesFromRect.left -= dragMatrix.e;\n }\n },\n dragOverAnimationComplete: function dragOverAnimationComplete() {\n if (folding) {\n folding = false;\n removeMultiDragElements();\n }\n },\n drop: function drop(_ref12) {\n var evt = _ref12.originalEvent,\n rootEl = _ref12.rootEl,\n parentEl = _ref12.parentEl,\n sortable = _ref12.sortable,\n dispatchSortableEvent = _ref12.dispatchSortableEvent,\n oldIndex = _ref12.oldIndex,\n putSortable = _ref12.putSortable;\n var toSortable = putSortable || this.sortable;\n if (!evt) return;\n var options = this.options,\n children = parentEl.children; // Multi-drag selection\n\n if (!dragStarted) {\n if (options.multiDragKey && !this.multiDragKeyDown) {\n this._deselectMultiDrag();\n }\n\n toggleClass(dragEl$1, options.selectedClass, !~multiDragElements.indexOf(dragEl$1));\n\n if (!~multiDragElements.indexOf(dragEl$1)) {\n multiDragElements.push(dragEl$1);\n dispatchEvent({\n sortable: sortable,\n rootEl: rootEl,\n name: 'select',\n targetEl: dragEl$1,\n originalEvt: evt\n }); // Modifier activated, select from last to dragEl\n\n if (evt.shiftKey && lastMultiDragSelect && sortable.el.contains(lastMultiDragSelect)) {\n var lastIndex = index(lastMultiDragSelect),\n currentIndex = index(dragEl$1);\n\n if (~lastIndex && ~currentIndex && lastIndex !== currentIndex) {\n // Must include lastMultiDragSelect (select it), in case modified selection from no selection\n // (but previous selection existed)\n var n, i;\n\n if (currentIndex > lastIndex) {\n i = lastIndex;\n n = currentIndex;\n } else {\n i = currentIndex;\n n = lastIndex + 1;\n }\n\n for (; i < n; i++) {\n if (~multiDragElements.indexOf(children[i])) continue;\n toggleClass(children[i], options.selectedClass, true);\n multiDragElements.push(children[i]);\n dispatchEvent({\n sortable: sortable,\n rootEl: rootEl,\n name: 'select',\n targetEl: children[i],\n originalEvt: evt\n });\n }\n }\n } else {\n lastMultiDragSelect = dragEl$1;\n }\n\n multiDragSortable = toSortable;\n } else {\n multiDragElements.splice(multiDragElements.indexOf(dragEl$1), 1);\n lastMultiDragSelect = null;\n dispatchEvent({\n sortable: sortable,\n rootEl: rootEl,\n name: 'deselect',\n targetEl: dragEl$1,\n originalEvt: evt\n });\n }\n } // Multi-drag drop\n\n\n if (dragStarted && this.isMultiDrag) {\n folding = false; // Do not \"unfold\" after around dragEl if reverted\n\n if ((parentEl[expando].options.sort || parentEl !== rootEl) && multiDragElements.length > 1) {\n var dragRect = getRect(dragEl$1),\n multiDragIndex = index(dragEl$1, ':not(.' + this.options.selectedClass + ')');\n if (!initialFolding && options.animation) dragEl$1.thisAnimationDuration = null;\n toSortable.captureAnimationState();\n\n if (!initialFolding) {\n if (options.animation) {\n dragEl$1.fromRect = dragRect;\n multiDragElements.forEach(function (multiDragElement) {\n multiDragElement.thisAnimationDuration = null;\n\n if (multiDragElement !== dragEl$1) {\n var rect = folding ? getRect(multiDragElement) : dragRect;\n multiDragElement.fromRect = rect; // Prepare unfold animation\n\n toSortable.addAnimationState({\n target: multiDragElement,\n rect: rect\n });\n }\n });\n } // Multi drag elements are not necessarily removed from the DOM on drop, so to reinsert\n // properly they must all be removed\n\n\n removeMultiDragElements();\n multiDragElements.forEach(function (multiDragElement) {\n if (children[multiDragIndex]) {\n parentEl.insertBefore(multiDragElement, children[multiDragIndex]);\n } else {\n parentEl.appendChild(multiDragElement);\n }\n\n multiDragIndex++;\n }); // If initial folding is done, the elements may have changed position because they are now\n // unfolding around dragEl, even though dragEl may not have his index changed, so update event\n // must be fired here as Sortable will not.\n\n if (oldIndex === index(dragEl$1)) {\n var update = false;\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement.sortableIndex !== index(multiDragElement)) {\n update = true;\n return;\n }\n });\n\n if (update) {\n dispatchSortableEvent('update');\n }\n }\n } // Must be done after capturing individual rects (scroll bar)\n\n\n multiDragElements.forEach(function (multiDragElement) {\n unsetRect(multiDragElement);\n });\n toSortable.animateAll();\n }\n\n multiDragSortable = toSortable;\n } // Remove clones if necessary\n\n\n if (rootEl === parentEl || putSortable && putSortable.lastPutMode !== 'clone') {\n multiDragClones.forEach(function (clone) {\n clone.parentNode && clone.parentNode.removeChild(clone);\n });\n }\n },\n nullingGlobal: function nullingGlobal() {\n this.isMultiDrag = dragStarted = false;\n multiDragClones.length = 0;\n },\n destroyGlobal: function destroyGlobal() {\n this._deselectMultiDrag();\n\n off(document, 'pointerup', this._deselectMultiDrag);\n off(document, 'mouseup', this._deselectMultiDrag);\n off(document, 'touchend', this._deselectMultiDrag);\n off(document, 'keydown', this._checkKeyDown);\n off(document, 'keyup', this._checkKeyUp);\n },\n _deselectMultiDrag: function _deselectMultiDrag(evt) {\n if (typeof dragStarted !== \"undefined\" && dragStarted) return; // Only deselect if selection is in this sortable\n\n if (multiDragSortable !== this.sortable) return; // Only deselect if target is not item in this sortable\n\n if (evt && closest(evt.target, this.options.draggable, this.sortable.el, false)) return; // Only deselect if left click\n\n if (evt && evt.button !== 0) return;\n\n while (multiDragElements.length) {\n var el = multiDragElements[0];\n toggleClass(el, this.options.selectedClass, false);\n multiDragElements.shift();\n dispatchEvent({\n sortable: this.sortable,\n rootEl: this.sortable.el,\n name: 'deselect',\n targetEl: el,\n originalEvt: evt\n });\n }\n },\n _checkKeyDown: function _checkKeyDown(evt) {\n if (evt.key === this.options.multiDragKey) {\n this.multiDragKeyDown = true;\n }\n },\n _checkKeyUp: function _checkKeyUp(evt) {\n if (evt.key === this.options.multiDragKey) {\n this.multiDragKeyDown = false;\n }\n }\n };\n return _extends(MultiDrag, {\n // Static methods & properties\n pluginName: 'multiDrag',\n utils: {\n /**\n * Selects the provided multi-drag item\n * @param {HTMLElement} el The element to be selected\n */\n select: function select(el) {\n var sortable = el.parentNode[expando];\n if (!sortable || !sortable.options.multiDrag || ~multiDragElements.indexOf(el)) return;\n\n if (multiDragSortable && multiDragSortable !== sortable) {\n multiDragSortable.multiDrag._deselectMultiDrag();\n\n multiDragSortable = sortable;\n }\n\n toggleClass(el, sortable.options.selectedClass, true);\n multiDragElements.push(el);\n },\n\n /**\n * Deselects the provided multi-drag item\n * @param {HTMLElement} el The element to be deselected\n */\n deselect: function deselect(el) {\n var sortable = el.parentNode[expando],\n index = multiDragElements.indexOf(el);\n if (!sortable || !sortable.options.multiDrag || !~index) return;\n toggleClass(el, sortable.options.selectedClass, false);\n multiDragElements.splice(index, 1);\n }\n },\n eventProperties: function eventProperties() {\n var _this3 = this;\n\n var oldIndicies = [],\n newIndicies = [];\n multiDragElements.forEach(function (multiDragElement) {\n oldIndicies.push({\n multiDragElement: multiDragElement,\n index: multiDragElement.sortableIndex\n }); // multiDragElements will already be sorted if folding\n\n var newIndex;\n\n if (folding && multiDragElement !== dragEl$1) {\n newIndex = -1;\n } else if (folding) {\n newIndex = index(multiDragElement, ':not(.' + _this3.options.selectedClass + ')');\n } else {\n newIndex = index(multiDragElement);\n }\n\n newIndicies.push({\n multiDragElement: multiDragElement,\n index: newIndex\n });\n });\n return {\n items: _toConsumableArray(multiDragElements),\n clones: [].concat(multiDragClones),\n oldIndicies: oldIndicies,\n newIndicies: newIndicies\n };\n },\n optionListeners: {\n multiDragKey: function multiDragKey(key) {\n key = key.toLowerCase();\n\n if (key === 'ctrl') {\n key = 'Control';\n } else if (key.length > 1) {\n key = key.charAt(0).toUpperCase() + key.substr(1);\n }\n\n return key;\n }\n }\n });\n}\n\nfunction insertMultiDragElements(clonesInserted, rootEl) {\n multiDragElements.forEach(function (multiDragElement, i) {\n var target = rootEl.children[multiDragElement.sortableIndex + (clonesInserted ? Number(i) : 0)];\n\n if (target) {\n rootEl.insertBefore(multiDragElement, target);\n } else {\n rootEl.appendChild(multiDragElement);\n }\n });\n}\n/**\n * Insert multi-drag clones\n * @param {[Boolean]} elementsInserted Whether the multi-drag elements are inserted\n * @param {HTMLElement} rootEl\n */\n\n\nfunction insertMultiDragClones(elementsInserted, rootEl) {\n multiDragClones.forEach(function (clone, i) {\n var target = rootEl.children[clone.sortableIndex + (elementsInserted ? Number(i) : 0)];\n\n if (target) {\n rootEl.insertBefore(clone, target);\n } else {\n rootEl.appendChild(clone);\n }\n });\n}\n\nfunction removeMultiDragElements() {\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n multiDragElement.parentNode && multiDragElement.parentNode.removeChild(multiDragElement);\n });\n}\n\nSortable.mount(new AutoScrollPlugin());\nSortable.mount(Remove, Revert);\n\nexport default Sortable;\nexport { MultiDragPlugin as MultiDrag, Sortable, SwapPlugin as Swap };\n","/*! https://mths.be/punycode v1.3.2 by @mathias */\n;(function(root) {\n\n\t/** Detect free variables */\n\tvar freeExports = typeof exports == 'object' && exports &&\n\t\t!exports.nodeType && exports;\n\tvar freeModule = typeof module == 'object' && module &&\n\t\t!module.nodeType && module;\n\tvar freeGlobal = typeof global == 'object' && global;\n\tif (\n\t\tfreeGlobal.global === freeGlobal ||\n\t\tfreeGlobal.window === freeGlobal ||\n\t\tfreeGlobal.self === freeGlobal\n\t) {\n\t\troot = freeGlobal;\n\t}\n\n\t/**\n\t * The `punycode` object.\n\t * @name punycode\n\t * @type Object\n\t */\n\tvar punycode,\n\n\t/** Highest positive signed 32-bit float value */\n\tmaxInt = 2147483647, // aka. 0x7FFFFFFF or 2^31-1\n\n\t/** Bootstring parameters */\n\tbase = 36,\n\ttMin = 1,\n\ttMax = 26,\n\tskew = 38,\n\tdamp = 700,\n\tinitialBias = 72,\n\tinitialN = 128, // 0x80\n\tdelimiter = '-', // '\\x2D'\n\n\t/** Regular expressions */\n\tregexPunycode = /^xn--/,\n\tregexNonASCII = /[^\\x20-\\x7E]/, // unprintable ASCII chars + non-ASCII chars\n\tregexSeparators = /[\\x2E\\u3002\\uFF0E\\uFF61]/g, // RFC 3490 separators\n\n\t/** Error messages */\n\terrors = {\n\t\t'overflow': 'Overflow: input needs wider integers to process',\n\t\t'not-basic': 'Illegal input >= 0x80 (not a basic code point)',\n\t\t'invalid-input': 'Invalid input'\n\t},\n\n\t/** Convenience shortcuts */\n\tbaseMinusTMin = base - tMin,\n\tfloor = Math.floor,\n\tstringFromCharCode = String.fromCharCode,\n\n\t/** Temporary variable */\n\tkey;\n\n\t/*--------------------------------------------------------------------------*/\n\n\t/**\n\t * A generic error utility function.\n\t * @private\n\t * @param {String} type The error type.\n\t * @returns {Error} Throws a `RangeError` with the applicable error message.\n\t */\n\tfunction error(type) {\n\t\tthrow RangeError(errors[type]);\n\t}\n\n\t/**\n\t * A generic `Array#map` utility function.\n\t * @private\n\t * @param {Array} array The array to iterate over.\n\t * @param {Function} callback The function that gets called for every array\n\t * item.\n\t * @returns {Array} A new array of values returned by the callback function.\n\t */\n\tfunction map(array, fn) {\n\t\tvar length = array.length;\n\t\tvar result = [];\n\t\twhile (length--) {\n\t\t\tresult[length] = fn(array[length]);\n\t\t}\n\t\treturn result;\n\t}\n\n\t/**\n\t * A simple `Array#map`-like wrapper to work with domain name strings or email\n\t * addresses.\n\t * @private\n\t * @param {String} domain The domain name or email address.\n\t * @param {Function} callback The function that gets called for every\n\t * character.\n\t * @returns {Array} A new string of characters returned by the callback\n\t * function.\n\t */\n\tfunction mapDomain(string, fn) {\n\t\tvar parts = string.split('@');\n\t\tvar result = '';\n\t\tif (parts.length > 1) {\n\t\t\t// In email addresses, only the domain name should be punycoded. Leave\n\t\t\t// the local part (i.e. everything up to `@`) intact.\n\t\t\tresult = parts[0] + '@';\n\t\t\tstring = parts[1];\n\t\t}\n\t\t// Avoid `split(regex)` for IE8 compatibility. See #17.\n\t\tstring = string.replace(regexSeparators, '\\x2E');\n\t\tvar labels = string.split('.');\n\t\tvar encoded = map(labels, fn).join('.');\n\t\treturn result + encoded;\n\t}\n\n\t/**\n\t * Creates an array containing the numeric code points of each Unicode\n\t * character in the string. While JavaScript uses UCS-2 internally,\n\t * this function will convert a pair of surrogate halves (each of which\n\t * UCS-2 exposes as separate characters) into a single code point,\n\t * matching UTF-16.\n\t * @see `punycode.ucs2.encode`\n\t * @see <https://mathiasbynens.be/notes/javascript-encoding>\n\t * @memberOf punycode.ucs2\n\t * @name decode\n\t * @param {String} string The Unicode input string (UCS-2).\n\t * @returns {Array} The new array of code points.\n\t */\n\tfunction ucs2decode(string) {\n\t\tvar output = [],\n\t\t counter = 0,\n\t\t length = string.length,\n\t\t value,\n\t\t extra;\n\t\twhile (counter < length) {\n\t\t\tvalue = string.charCodeAt(counter++);\n\t\t\tif (value >= 0xD800 && value <= 0xDBFF && counter < length) {\n\t\t\t\t// high surrogate, and there is a next character\n\t\t\t\textra = string.charCodeAt(counter++);\n\t\t\t\tif ((extra & 0xFC00) == 0xDC00) { // low surrogate\n\t\t\t\t\toutput.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);\n\t\t\t\t} else {\n\t\t\t\t\t// unmatched surrogate; only append this code unit, in case the next\n\t\t\t\t\t// code unit is the high surrogate of a surrogate pair\n\t\t\t\t\toutput.push(value);\n\t\t\t\t\tcounter--;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\toutput.push(value);\n\t\t\t}\n\t\t}\n\t\treturn output;\n\t}\n\n\t/**\n\t * Creates a string based on an array of numeric code points.\n\t * @see `punycode.ucs2.decode`\n\t * @memberOf punycode.ucs2\n\t * @name encode\n\t * @param {Array} codePoints The array of numeric code points.\n\t * @returns {String} The new Unicode string (UCS-2).\n\t */\n\tfunction ucs2encode(array) {\n\t\treturn map(array, function(value) {\n\t\t\tvar output = '';\n\t\t\tif (value > 0xFFFF) {\n\t\t\t\tvalue -= 0x10000;\n\t\t\t\toutput += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);\n\t\t\t\tvalue = 0xDC00 | value & 0x3FF;\n\t\t\t}\n\t\t\toutput += stringFromCharCode(value);\n\t\t\treturn output;\n\t\t}).join('');\n\t}\n\n\t/**\n\t * Converts a basic code point into a digit/integer.\n\t * @see `digitToBasic()`\n\t * @private\n\t * @param {Number} codePoint The basic numeric code point value.\n\t * @returns {Number} The numeric value of a basic code point (for use in\n\t * representing integers) in the range `0` to `base - 1`, or `base` if\n\t * the code point does not represent a value.\n\t */\n\tfunction basicToDigit(codePoint) {\n\t\tif (codePoint - 48 < 10) {\n\t\t\treturn codePoint - 22;\n\t\t}\n\t\tif (codePoint - 65 < 26) {\n\t\t\treturn codePoint - 65;\n\t\t}\n\t\tif (codePoint - 97 < 26) {\n\t\t\treturn codePoint - 97;\n\t\t}\n\t\treturn base;\n\t}\n\n\t/**\n\t * Converts a digit/integer into a basic code point.\n\t * @see `basicToDigit()`\n\t * @private\n\t * @param {Number} digit The numeric value of a basic code point.\n\t * @returns {Number} The basic code point whose value (when used for\n\t * representing integers) is `digit`, which needs to be in the range\n\t * `0` to `base - 1`. If `flag` is non-zero, the uppercase form is\n\t * used; else, the lowercase form is used. The behavior is undefined\n\t * if `flag` is non-zero and `digit` has no uppercase form.\n\t */\n\tfunction digitToBasic(digit, flag) {\n\t\t// 0..25 map to ASCII a..z or A..Z\n\t\t// 26..35 map to ASCII 0..9\n\t\treturn digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);\n\t}\n\n\t/**\n\t * Bias adaptation function as per section 3.4 of RFC 3492.\n\t * http://tools.ietf.org/html/rfc3492#section-3.4\n\t * @private\n\t */\n\tfunction adapt(delta, numPoints, firstTime) {\n\t\tvar k = 0;\n\t\tdelta = firstTime ? floor(delta / damp) : delta >> 1;\n\t\tdelta += floor(delta / numPoints);\n\t\tfor (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {\n\t\t\tdelta = floor(delta / baseMinusTMin);\n\t\t}\n\t\treturn floor(k + (baseMinusTMin + 1) * delta / (delta + skew));\n\t}\n\n\t/**\n\t * Converts a Punycode string of ASCII-only symbols to a string of Unicode\n\t * symbols.\n\t * @memberOf punycode\n\t * @param {String} input The Punycode string of ASCII-only symbols.\n\t * @returns {String} The resulting string of Unicode symbols.\n\t */\n\tfunction decode(input) {\n\t\t// Don't use UCS-2\n\t\tvar output = [],\n\t\t inputLength = input.length,\n\t\t out,\n\t\t i = 0,\n\t\t n = initialN,\n\t\t bias = initialBias,\n\t\t basic,\n\t\t j,\n\t\t index,\n\t\t oldi,\n\t\t w,\n\t\t k,\n\t\t digit,\n\t\t t,\n\t\t /** Cached calculation results */\n\t\t baseMinusT;\n\n\t\t// Handle the basic code points: let `basic` be the number of input code\n\t\t// points before the last delimiter, or `0` if there is none, then copy\n\t\t// the first basic code points to the output.\n\n\t\tbasic = input.lastIndexOf(delimiter);\n\t\tif (basic < 0) {\n\t\t\tbasic = 0;\n\t\t}\n\n\t\tfor (j = 0; j < basic; ++j) {\n\t\t\t// if it's not a basic code point\n\t\t\tif (input.charCodeAt(j) >= 0x80) {\n\t\t\t\terror('not-basic');\n\t\t\t}\n\t\t\toutput.push(input.charCodeAt(j));\n\t\t}\n\n\t\t// Main decoding loop: start just after the last delimiter if any basic code\n\t\t// points were copied; start at the beginning otherwise.\n\n\t\tfor (index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {\n\n\t\t\t// `index` is the index of the next character to be consumed.\n\t\t\t// Decode a generalized variable-length integer into `delta`,\n\t\t\t// which gets added to `i`. The overflow checking is easier\n\t\t\t// if we increase `i` as we go, then subtract off its starting\n\t\t\t// value at the end to obtain `delta`.\n\t\t\tfor (oldi = i, w = 1, k = base; /* no condition */; k += base) {\n\n\t\t\t\tif (index >= inputLength) {\n\t\t\t\t\terror('invalid-input');\n\t\t\t\t}\n\n\t\t\t\tdigit = basicToDigit(input.charCodeAt(index++));\n\n\t\t\t\tif (digit >= base || digit > floor((maxInt - i) / w)) {\n\t\t\t\t\terror('overflow');\n\t\t\t\t}\n\n\t\t\t\ti += digit * w;\n\t\t\t\tt = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);\n\n\t\t\t\tif (digit < t) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tbaseMinusT = base - t;\n\t\t\t\tif (w > floor(maxInt / baseMinusT)) {\n\t\t\t\t\terror('overflow');\n\t\t\t\t}\n\n\t\t\t\tw *= baseMinusT;\n\n\t\t\t}\n\n\t\t\tout = output.length + 1;\n\t\t\tbias = adapt(i - oldi, out, oldi == 0);\n\n\t\t\t// `i` was supposed to wrap around from `out` to `0`,\n\t\t\t// incrementing `n` each time, so we'll fix that now:\n\t\t\tif (floor(i / out) > maxInt - n) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\n\t\t\tn += floor(i / out);\n\t\t\ti %= out;\n\n\t\t\t// Insert `n` at position `i` of the output\n\t\t\toutput.splice(i++, 0, n);\n\n\t\t}\n\n\t\treturn ucs2encode(output);\n\t}\n\n\t/**\n\t * Converts a string of Unicode symbols (e.g. a domain name label) to a\n\t * Punycode string of ASCII-only symbols.\n\t * @memberOf punycode\n\t * @param {String} input The string of Unicode symbols.\n\t * @returns {String} The resulting Punycode string of ASCII-only symbols.\n\t */\n\tfunction encode(input) {\n\t\tvar n,\n\t\t delta,\n\t\t handledCPCount,\n\t\t basicLength,\n\t\t bias,\n\t\t j,\n\t\t m,\n\t\t q,\n\t\t k,\n\t\t t,\n\t\t currentValue,\n\t\t output = [],\n\t\t /** `inputLength` will hold the number of code points in `input`. */\n\t\t inputLength,\n\t\t /** Cached calculation results */\n\t\t handledCPCountPlusOne,\n\t\t baseMinusT,\n\t\t qMinusT;\n\n\t\t// Convert the input in UCS-2 to Unicode\n\t\tinput = ucs2decode(input);\n\n\t\t// Cache the length\n\t\tinputLength = input.length;\n\n\t\t// Initialize the state\n\t\tn = initialN;\n\t\tdelta = 0;\n\t\tbias = initialBias;\n\n\t\t// Handle the basic code points\n\t\tfor (j = 0; j < inputLength; ++j) {\n\t\t\tcurrentValue = input[j];\n\t\t\tif (currentValue < 0x80) {\n\t\t\t\toutput.push(stringFromCharCode(currentValue));\n\t\t\t}\n\t\t}\n\n\t\thandledCPCount = basicLength = output.length;\n\n\t\t// `handledCPCount` is the number of code points that have been handled;\n\t\t// `basicLength` is the number of basic code points.\n\n\t\t// Finish the basic string - if it is not empty - with a delimiter\n\t\tif (basicLength) {\n\t\t\toutput.push(delimiter);\n\t\t}\n\n\t\t// Main encoding loop:\n\t\twhile (handledCPCount < inputLength) {\n\n\t\t\t// All non-basic code points < n have been handled already. Find the next\n\t\t\t// larger one:\n\t\t\tfor (m = maxInt, j = 0; j < inputLength; ++j) {\n\t\t\t\tcurrentValue = input[j];\n\t\t\t\tif (currentValue >= n && currentValue < m) {\n\t\t\t\t\tm = currentValue;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,\n\t\t\t// but guard against overflow\n\t\t\thandledCPCountPlusOne = handledCPCount + 1;\n\t\t\tif (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\n\t\t\tdelta += (m - n) * handledCPCountPlusOne;\n\t\t\tn = m;\n\n\t\t\tfor (j = 0; j < inputLength; ++j) {\n\t\t\t\tcurrentValue = input[j];\n\n\t\t\t\tif (currentValue < n && ++delta > maxInt) {\n\t\t\t\t\terror('overflow');\n\t\t\t\t}\n\n\t\t\t\tif (currentValue == n) {\n\t\t\t\t\t// Represent delta as a generalized variable-length integer\n\t\t\t\t\tfor (q = delta, k = base; /* no condition */; k += base) {\n\t\t\t\t\t\tt = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);\n\t\t\t\t\t\tif (q < t) {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tqMinusT = q - t;\n\t\t\t\t\t\tbaseMinusT = base - t;\n\t\t\t\t\t\toutput.push(\n\t\t\t\t\t\t\tstringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))\n\t\t\t\t\t\t);\n\t\t\t\t\t\tq = floor(qMinusT / baseMinusT);\n\t\t\t\t\t}\n\n\t\t\t\t\toutput.push(stringFromCharCode(digitToBasic(q, 0)));\n\t\t\t\t\tbias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);\n\t\t\t\t\tdelta = 0;\n\t\t\t\t\t++handledCPCount;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t++delta;\n\t\t\t++n;\n\n\t\t}\n\t\treturn output.join('');\n\t}\n\n\t/**\n\t * Converts a Punycode string representing a domain name or an email address\n\t * to Unicode. Only the Punycoded parts of the input will be converted, i.e.\n\t * it doesn't matter if you call it on a string that has already been\n\t * converted to Unicode.\n\t * @memberOf punycode\n\t * @param {String} input The Punycoded domain name or email address to\n\t * convert to Unicode.\n\t * @returns {String} The Unicode representation of the given Punycode\n\t * string.\n\t */\n\tfunction toUnicode(input) {\n\t\treturn mapDomain(input, function(string) {\n\t\t\treturn regexPunycode.test(string)\n\t\t\t\t? decode(string.slice(4).toLowerCase())\n\t\t\t\t: string;\n\t\t});\n\t}\n\n\t/**\n\t * Converts a Unicode string representing a domain name or an email address to\n\t * Punycode. Only the non-ASCII parts of the domain name will be converted,\n\t * i.e. it doesn't matter if you call it with a domain that's already in\n\t * ASCII.\n\t * @memberOf punycode\n\t * @param {String} input The domain name or email address to convert, as a\n\t * Unicode string.\n\t * @returns {String} The Punycode representation of the given domain name or\n\t * email address.\n\t */\n\tfunction toASCII(input) {\n\t\treturn mapDomain(input, function(string) {\n\t\t\treturn regexNonASCII.test(string)\n\t\t\t\t? 'xn--' + encode(string)\n\t\t\t\t: string;\n\t\t});\n\t}\n\n\t/*--------------------------------------------------------------------------*/\n\n\t/** Define the public API */\n\tpunycode = {\n\t\t/**\n\t\t * A string representing the current Punycode.js version number.\n\t\t * @memberOf punycode\n\t\t * @type String\n\t\t */\n\t\t'version': '1.3.2',\n\t\t/**\n\t\t * An object of methods to convert from JavaScript's internal character\n\t\t * representation (UCS-2) to Unicode code points, and back.\n\t\t * @see <https://mathiasbynens.be/notes/javascript-encoding>\n\t\t * @memberOf punycode\n\t\t * @type Object\n\t\t */\n\t\t'ucs2': {\n\t\t\t'decode': ucs2decode,\n\t\t\t'encode': ucs2encode\n\t\t},\n\t\t'decode': decode,\n\t\t'encode': encode,\n\t\t'toASCII': toASCII,\n\t\t'toUnicode': toUnicode\n\t};\n\n\t/** Expose `punycode` */\n\t// Some AMD build optimizers, like r.js, check for specific condition patterns\n\t// like the following:\n\tif (\n\t\ttypeof define == 'function' &&\n\t\ttypeof define.amd == 'object' &&\n\t\tdefine.amd\n\t) {\n\t\tdefine('punycode', function() {\n\t\t\treturn punycode;\n\t\t});\n\t} else if (freeExports && freeModule) {\n\t\tif (module.exports == freeExports) { // in Node.js or RingoJS v0.8.0+\n\t\t\tfreeModule.exports = punycode;\n\t\t} else { // in Narwhal or RingoJS v0.7.0-\n\t\t\tfor (key in punycode) {\n\t\t\t\tpunycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]);\n\t\t\t}\n\t\t}\n\t} else { // in Rhino or a web browser\n\t\troot.punycode = punycode;\n\t}\n\n}(this));\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\nvar punycode = require('punycode');\nvar util = require('./util');\n\nexports.parse = urlParse;\nexports.resolve = urlResolve;\nexports.resolveObject = urlResolveObject;\nexports.format = urlFormat;\n\nexports.Url = Url;\n\nfunction Url() {\n this.protocol = null;\n this.slashes = null;\n this.auth = null;\n this.host = null;\n this.port = null;\n this.hostname = null;\n this.hash = null;\n this.search = null;\n this.query = null;\n this.pathname = null;\n this.path = null;\n this.href = null;\n}\n\n// Reference: RFC 3986, RFC 1808, RFC 2396\n\n// define these here so at least they only have to be\n// compiled once on the first module load.\nvar protocolPattern = /^([a-z0-9.+-]+:)/i,\n portPattern = /:[0-9]*$/,\n\n // Special case for a simple path URL\n simplePathPattern = /^(\\/\\/?(?!\\/)[^\\?\\s]*)(\\?[^\\s]*)?$/,\n\n // RFC 2396: characters reserved for delimiting URLs.\n // We actually just auto-escape these.\n delims = ['<', '>', '\"', '`', ' ', '\\r', '\\n', '\\t'],\n\n // RFC 2396: characters not allowed for various reasons.\n unwise = ['{', '}', '|', '\\\\', '^', '`'].concat(delims),\n\n // Allowed by RFCs, but cause of XSS attacks. Always escape these.\n autoEscape = ['\\''].concat(unwise),\n // Characters that are never ever allowed in a hostname.\n // Note that any invalid chars are also handled, but these\n // are the ones that are *expected* to be seen, so we fast-path\n // them.\n nonHostChars = ['%', '/', '?', ';', '#'].concat(autoEscape),\n hostEndingChars = ['/', '?', '#'],\n hostnameMaxLen = 255,\n hostnamePartPattern = /^[+a-z0-9A-Z_-]{0,63}$/,\n hostnamePartStart = /^([+a-z0-9A-Z_-]{0,63})(.*)$/,\n // protocols that can allow \"unsafe\" and \"unwise\" chars.\n unsafeProtocol = {\n 'javascript': true,\n 'javascript:': true\n },\n // protocols that never have a hostname.\n hostlessProtocol = {\n 'javascript': true,\n 'javascript:': true\n },\n // protocols that always contain a // bit.\n slashedProtocol = {\n 'http': true,\n 'https': true,\n 'ftp': true,\n 'gopher': true,\n 'file': true,\n 'http:': true,\n 'https:': true,\n 'ftp:': true,\n 'gopher:': true,\n 'file:': true\n },\n querystring = require('querystring');\n\nfunction urlParse(url, parseQueryString, slashesDenoteHost) {\n if (url && util.isObject(url) && url instanceof Url) return url;\n\n var u = new Url;\n u.parse(url, parseQueryString, slashesDenoteHost);\n return u;\n}\n\nUrl.prototype.parse = function(url, parseQueryString, slashesDenoteHost) {\n if (!util.isString(url)) {\n throw new TypeError(\"Parameter 'url' must be a string, not \" + typeof url);\n }\n\n // Copy chrome, IE, opera backslash-handling behavior.\n // Back slashes before the query string get converted to forward slashes\n // See: https://code.google.com/p/chromium/issues/detail?id=25916\n var queryIndex = url.indexOf('?'),\n splitter =\n (queryIndex !== -1 && queryIndex < url.indexOf('#')) ? '?' : '#',\n uSplit = url.split(splitter),\n slashRegex = /\\\\/g;\n uSplit[0] = uSplit[0].replace(slashRegex, '/');\n url = uSplit.join(splitter);\n\n var rest = url;\n\n // trim before proceeding.\n // This is to support parse stuff like \" http://foo.com \\n\"\n rest = rest.trim();\n\n if (!slashesDenoteHost && url.split('#').length === 1) {\n // Try fast path regexp\n var simplePath = simplePathPattern.exec(rest);\n if (simplePath) {\n this.path = rest;\n this.href = rest;\n this.pathname = simplePath[1];\n if (simplePath[2]) {\n this.search = simplePath[2];\n if (parseQueryString) {\n this.query = querystring.parse(this.search.substr(1));\n } else {\n this.query = this.search.substr(1);\n }\n } else if (parseQueryString) {\n this.search = '';\n this.query = {};\n }\n return this;\n }\n }\n\n var proto = protocolPattern.exec(rest);\n if (proto) {\n proto = proto[0];\n var lowerProto = proto.toLowerCase();\n this.protocol = lowerProto;\n rest = rest.substr(proto.length);\n }\n\n // figure out if it's got a host\n // user@server is *always* interpreted as a hostname, and url\n // resolution will treat //foo/bar as host=foo,path=bar because that's\n // how the browser resolves relative URLs.\n if (slashesDenoteHost || proto || rest.match(/^\\/\\/[^@\\/]+@[^@\\/]+/)) {\n var slashes = rest.substr(0, 2) === '//';\n if (slashes && !(proto && hostlessProtocol[proto])) {\n rest = rest.substr(2);\n this.slashes = true;\n }\n }\n\n if (!hostlessProtocol[proto] &&\n (slashes || (proto && !slashedProtocol[proto]))) {\n\n // there's a hostname.\n // the first instance of /, ?, ;, or # ends the host.\n //\n // If there is an @ in the hostname, then non-host chars *are* allowed\n // to the left of the last @ sign, unless some host-ending character\n // comes *before* the @-sign.\n // URLs are obnoxious.\n //\n // ex:\n // http://a@b@c/ => user:a@b host:c\n // http://a@b?@c => user:a host:c path:/?@c\n\n // v0.12 TODO(isaacs): This is not quite how Chrome does things.\n // Review our test case against browsers more comprehensively.\n\n // find the first instance of any hostEndingChars\n var hostEnd = -1;\n for (var i = 0; i < hostEndingChars.length; i++) {\n var hec = rest.indexOf(hostEndingChars[i]);\n if (hec !== -1 && (hostEnd === -1 || hec < hostEnd))\n hostEnd = hec;\n }\n\n // at this point, either we have an explicit point where the\n // auth portion cannot go past, or the last @ char is the decider.\n var auth, atSign;\n if (hostEnd === -1) {\n // atSign can be anywhere.\n atSign = rest.lastIndexOf('@');\n } else {\n // atSign must be in auth portion.\n // http://a@b/c@d => host:b auth:a path:/c@d\n atSign = rest.lastIndexOf('@', hostEnd);\n }\n\n // Now we have a portion which is definitely the auth.\n // Pull that off.\n if (atSign !== -1) {\n auth = rest.slice(0, atSign);\n rest = rest.slice(atSign + 1);\n this.auth = decodeURIComponent(auth);\n }\n\n // the host is the remaining to the left of the first non-host char\n hostEnd = -1;\n for (var i = 0; i < nonHostChars.length; i++) {\n var hec = rest.indexOf(nonHostChars[i]);\n if (hec !== -1 && (hostEnd === -1 || hec < hostEnd))\n hostEnd = hec;\n }\n // if we still have not hit it, then the entire thing is a host.\n if (hostEnd === -1)\n hostEnd = rest.length;\n\n this.host = rest.slice(0, hostEnd);\n rest = rest.slice(hostEnd);\n\n // pull out port.\n this.parseHost();\n\n // we've indicated that there is a hostname,\n // so even if it's empty, it has to be present.\n this.hostname = this.hostname || '';\n\n // if hostname begins with [ and ends with ]\n // assume that it's an IPv6 address.\n var ipv6Hostname = this.hostname[0] === '[' &&\n this.hostname[this.hostname.length - 1] === ']';\n\n // validate a little.\n if (!ipv6Hostname) {\n var hostparts = this.hostname.split(/\\./);\n for (var i = 0, l = hostparts.length; i < l; i++) {\n var part = hostparts[i];\n if (!part) continue;\n if (!part.match(hostnamePartPattern)) {\n var newpart = '';\n for (var j = 0, k = part.length; j < k; j++) {\n if (part.charCodeAt(j) > 127) {\n // we replace non-ASCII char with a temporary placeholder\n // we need this to make sure size of hostname is not\n // broken by replacing non-ASCII by nothing\n newpart += 'x';\n } else {\n newpart += part[j];\n }\n }\n // we test again with ASCII char only\n if (!newpart.match(hostnamePartPattern)) {\n var validParts = hostparts.slice(0, i);\n var notHost = hostparts.slice(i + 1);\n var bit = part.match(hostnamePartStart);\n if (bit) {\n validParts.push(bit[1]);\n notHost.unshift(bit[2]);\n }\n if (notHost.length) {\n rest = '/' + notHost.join('.') + rest;\n }\n this.hostname = validParts.join('.');\n break;\n }\n }\n }\n }\n\n if (this.hostname.length > hostnameMaxLen) {\n this.hostname = '';\n } else {\n // hostnames are always lower case.\n this.hostname = this.hostname.toLowerCase();\n }\n\n if (!ipv6Hostname) {\n // IDNA Support: Returns a punycoded representation of \"domain\".\n // It only converts parts of the domain name that\n // have non-ASCII characters, i.e. it doesn't matter if\n // you call it with a domain that already is ASCII-only.\n this.hostname = punycode.toASCII(this.hostname);\n }\n\n var p = this.port ? ':' + this.port : '';\n var h = this.hostname || '';\n this.host = h + p;\n this.href += this.host;\n\n // strip [ and ] from the hostname\n // the host field still retains them, though\n if (ipv6Hostname) {\n this.hostname = this.hostname.substr(1, this.hostname.length - 2);\n if (rest[0] !== '/') {\n rest = '/' + rest;\n }\n }\n }\n\n // now rest is set to the post-host stuff.\n // chop off any delim chars.\n if (!unsafeProtocol[lowerProto]) {\n\n // First, make 100% sure that any \"autoEscape\" chars get\n // escaped, even if encodeURIComponent doesn't think they\n // need to be.\n for (var i = 0, l = autoEscape.length; i < l; i++) {\n var ae = autoEscape[i];\n if (rest.indexOf(ae) === -1)\n continue;\n var esc = encodeURIComponent(ae);\n if (esc === ae) {\n esc = escape(ae);\n }\n rest = rest.split(ae).join(esc);\n }\n }\n\n\n // chop off from the tail first.\n var hash = rest.indexOf('#');\n if (hash !== -1) {\n // got a fragment string.\n this.hash = rest.substr(hash);\n rest = rest.slice(0, hash);\n }\n var qm = rest.indexOf('?');\n if (qm !== -1) {\n this.search = rest.substr(qm);\n this.query = rest.substr(qm + 1);\n if (parseQueryString) {\n this.query = querystring.parse(this.query);\n }\n rest = rest.slice(0, qm);\n } else if (parseQueryString) {\n // no query string, but parseQueryString still requested\n this.search = '';\n this.query = {};\n }\n if (rest) this.pathname = rest;\n if (slashedProtocol[lowerProto] &&\n this.hostname && !this.pathname) {\n this.pathname = '/';\n }\n\n //to support http.request\n if (this.pathname || this.search) {\n var p = this.pathname || '';\n var s = this.search || '';\n this.path = p + s;\n }\n\n // finally, reconstruct the href based on what has been validated.\n this.href = this.format();\n return this;\n};\n\n// format a parsed object into a url string\nfunction urlFormat(obj) {\n // ensure it's an object, and not a string url.\n // If it's an obj, this is a no-op.\n // this way, you can call url_format() on strings\n // to clean up potentially wonky urls.\n if (util.isString(obj)) obj = urlParse(obj);\n if (!(obj instanceof Url)) return Url.prototype.format.call(obj);\n return obj.format();\n}\n\nUrl.prototype.format = function() {\n var auth = this.auth || '';\n if (auth) {\n auth = encodeURIComponent(auth);\n auth = auth.replace(/%3A/i, ':');\n auth += '@';\n }\n\n var protocol = this.protocol || '',\n pathname = this.pathname || '',\n hash = this.hash || '',\n host = false,\n query = '';\n\n if (this.host) {\n host = auth + this.host;\n } else if (this.hostname) {\n host = auth + (this.hostname.indexOf(':') === -1 ?\n this.hostname :\n '[' + this.hostname + ']');\n if (this.port) {\n host += ':' + this.port;\n }\n }\n\n if (this.query &&\n util.isObject(this.query) &&\n Object.keys(this.query).length) {\n query = querystring.stringify(this.query);\n }\n\n var search = this.search || (query && ('?' + query)) || '';\n\n if (protocol && protocol.substr(-1) !== ':') protocol += ':';\n\n // only the slashedProtocols get the //. Not mailto:, xmpp:, etc.\n // unless they had them to begin with.\n if (this.slashes ||\n (!protocol || slashedProtocol[protocol]) && host !== false) {\n host = '//' + (host || '');\n if (pathname && pathname.charAt(0) !== '/') pathname = '/' + pathname;\n } else if (!host) {\n host = '';\n }\n\n if (hash && hash.charAt(0) !== '#') hash = '#' + hash;\n if (search && search.charAt(0) !== '?') search = '?' + search;\n\n pathname = pathname.replace(/[?#]/g, function(match) {\n return encodeURIComponent(match);\n });\n search = search.replace('#', '%23');\n\n return protocol + host + pathname + search + hash;\n};\n\nfunction urlResolve(source, relative) {\n return urlParse(source, false, true).resolve(relative);\n}\n\nUrl.prototype.resolve = function(relative) {\n return this.resolveObject(urlParse(relative, false, true)).format();\n};\n\nfunction urlResolveObject(source, relative) {\n if (!source) return relative;\n return urlParse(source, false, true).resolveObject(relative);\n}\n\nUrl.prototype.resolveObject = function(relative) {\n if (util.isString(relative)) {\n var rel = new Url();\n rel.parse(relative, false, true);\n relative = rel;\n }\n\n var result = new Url();\n var tkeys = Object.keys(this);\n for (var tk = 0; tk < tkeys.length; tk++) {\n var tkey = tkeys[tk];\n result[tkey] = this[tkey];\n }\n\n // hash is always overridden, no matter what.\n // even href=\"\" will remove it.\n result.hash = relative.hash;\n\n // if the relative url is empty, then there's nothing left to do here.\n if (relative.href === '') {\n result.href = result.format();\n return result;\n }\n\n // hrefs like //foo/bar always cut to the protocol.\n if (relative.slashes && !relative.protocol) {\n // take everything except the protocol from relative\n var rkeys = Object.keys(relative);\n for (var rk = 0; rk < rkeys.length; rk++) {\n var rkey = rkeys[rk];\n if (rkey !== 'protocol')\n result[rkey] = relative[rkey];\n }\n\n //urlParse appends trailing / to urls like http://www.example.com\n if (slashedProtocol[result.protocol] &&\n result.hostname && !result.pathname) {\n result.path = result.pathname = '/';\n }\n\n result.href = result.format();\n return result;\n }\n\n if (relative.protocol && relative.protocol !== result.protocol) {\n // if it's a known url protocol, then changing\n // the protocol does weird things\n // first, if it's not file:, then we MUST have a host,\n // and if there was a path\n // to begin with, then we MUST have a path.\n // if it is file:, then the host is dropped,\n // because that's known to be hostless.\n // anything else is assumed to be absolute.\n if (!slashedProtocol[relative.protocol]) {\n var keys = Object.keys(relative);\n for (var v = 0; v < keys.length; v++) {\n var k = keys[v];\n result[k] = relative[k];\n }\n result.href = result.format();\n return result;\n }\n\n result.protocol = relative.protocol;\n if (!relative.host && !hostlessProtocol[relative.protocol]) {\n var relPath = (relative.pathname || '').split('/');\n while (relPath.length && !(relative.host = relPath.shift()));\n if (!relative.host) relative.host = '';\n if (!relative.hostname) relative.hostname = '';\n if (relPath[0] !== '') relPath.unshift('');\n if (relPath.length < 2) relPath.unshift('');\n result.pathname = relPath.join('/');\n } else {\n result.pathname = relative.pathname;\n }\n result.search = relative.search;\n result.query = relative.query;\n result.host = relative.host || '';\n result.auth = relative.auth;\n result.hostname = relative.hostname || relative.host;\n result.port = relative.port;\n // to support http.request\n if (result.pathname || result.search) {\n var p = result.pathname || '';\n var s = result.search || '';\n result.path = p + s;\n }\n result.slashes = result.slashes || relative.slashes;\n result.href = result.format();\n return result;\n }\n\n var isSourceAbs = (result.pathname && result.pathname.charAt(0) === '/'),\n isRelAbs = (\n relative.host ||\n relative.pathname && relative.pathname.charAt(0) === '/'\n ),\n mustEndAbs = (isRelAbs || isSourceAbs ||\n (result.host && relative.pathname)),\n removeAllDots = mustEndAbs,\n srcPath = result.pathname && result.pathname.split('/') || [],\n relPath = relative.pathname && relative.pathname.split('/') || [],\n psychotic = result.protocol && !slashedProtocol[result.protocol];\n\n // if the url is a non-slashed url, then relative\n // links like ../.. should be able\n // to crawl up to the hostname, as well. This is strange.\n // result.protocol has already been set by now.\n // Later on, put the first path part into the host field.\n if (psychotic) {\n result.hostname = '';\n result.port = null;\n if (result.host) {\n if (srcPath[0] === '') srcPath[0] = result.host;\n else srcPath.unshift(result.host);\n }\n result.host = '';\n if (relative.protocol) {\n relative.hostname = null;\n relative.port = null;\n if (relative.host) {\n if (relPath[0] === '') relPath[0] = relative.host;\n else relPath.unshift(relative.host);\n }\n relative.host = null;\n }\n mustEndAbs = mustEndAbs && (relPath[0] === '' || srcPath[0] === '');\n }\n\n if (isRelAbs) {\n // it's absolute.\n result.host = (relative.host || relative.host === '') ?\n relative.host : result.host;\n result.hostname = (relative.hostname || relative.hostname === '') ?\n relative.hostname : result.hostname;\n result.search = relative.search;\n result.query = relative.query;\n srcPath = relPath;\n // fall through to the dot-handling below.\n } else if (relPath.length) {\n // it's relative\n // throw away the existing file, and take the new path instead.\n if (!srcPath) srcPath = [];\n srcPath.pop();\n srcPath = srcPath.concat(relPath);\n result.search = relative.search;\n result.query = relative.query;\n } else if (!util.isNullOrUndefined(relative.search)) {\n // just pull out the search.\n // like href='?foo'.\n // Put this after the other two cases because it simplifies the booleans\n if (psychotic) {\n result.hostname = result.host = srcPath.shift();\n //occationaly the auth can get stuck only in host\n //this especially happens in cases like\n //url.resolveObject('mailto:local1@domain1', 'local2@domain2')\n var authInHost = result.host && result.host.indexOf('@') > 0 ?\n result.host.split('@') : false;\n if (authInHost) {\n result.auth = authInHost.shift();\n result.host = result.hostname = authInHost.shift();\n }\n }\n result.search = relative.search;\n result.query = relative.query;\n //to support http.request\n if (!util.isNull(result.pathname) || !util.isNull(result.search)) {\n result.path = (result.pathname ? result.pathname : '') +\n (result.search ? result.search : '');\n }\n result.href = result.format();\n return result;\n }\n\n if (!srcPath.length) {\n // no path at all. easy.\n // we've already handled the other stuff above.\n result.pathname = null;\n //to support http.request\n if (result.search) {\n result.path = '/' + result.search;\n } else {\n result.path = null;\n }\n result.href = result.format();\n return result;\n }\n\n // if a url ENDs in . or .., then it must get a trailing slash.\n // however, if it ends in anything else non-slashy,\n // then it must NOT get a trailing slash.\n var last = srcPath.slice(-1)[0];\n var hasTrailingSlash = (\n (result.host || relative.host || srcPath.length > 1) &&\n (last === '.' || last === '..') || last === '');\n\n // strip single dots, resolve double dots to parent dir\n // if the path tries to go above the root, `up` ends up > 0\n var up = 0;\n for (var i = srcPath.length; i >= 0; i--) {\n last = srcPath[i];\n if (last === '.') {\n srcPath.splice(i, 1);\n } else if (last === '..') {\n srcPath.splice(i, 1);\n up++;\n } else if (up) {\n srcPath.splice(i, 1);\n up--;\n }\n }\n\n // if the path is allowed to go above the root, restore leading ..s\n if (!mustEndAbs && !removeAllDots) {\n for (; up--; up) {\n srcPath.unshift('..');\n }\n }\n\n if (mustEndAbs && srcPath[0] !== '' &&\n (!srcPath[0] || srcPath[0].charAt(0) !== '/')) {\n srcPath.unshift('');\n }\n\n if (hasTrailingSlash && (srcPath.join('/').substr(-1) !== '/')) {\n srcPath.push('');\n }\n\n var isAbsolute = srcPath[0] === '' ||\n (srcPath[0] && srcPath[0].charAt(0) === '/');\n\n // put the host back\n if (psychotic) {\n result.hostname = result.host = isAbsolute ? '' :\n srcPath.length ? srcPath.shift() : '';\n //occationaly the auth can get stuck only in host\n //this especially happens in cases like\n //url.resolveObject('mailto:local1@domain1', 'local2@domain2')\n var authInHost = result.host && result.host.indexOf('@') > 0 ?\n result.host.split('@') : false;\n if (authInHost) {\n result.auth = authInHost.shift();\n result.host = result.hostname = authInHost.shift();\n }\n }\n\n mustEndAbs = mustEndAbs || (result.host && srcPath.length);\n\n if (mustEndAbs && !isAbsolute) {\n srcPath.unshift('');\n }\n\n if (!srcPath.length) {\n result.pathname = null;\n result.path = null;\n } else {\n result.pathname = srcPath.join('/');\n }\n\n //to support request.http\n if (!util.isNull(result.pathname) || !util.isNull(result.search)) {\n result.path = (result.pathname ? result.pathname : '') +\n (result.search ? result.search : '');\n }\n result.auth = relative.auth || result.auth;\n result.slashes = result.slashes || relative.slashes;\n result.href = result.format();\n return result;\n};\n\nUrl.prototype.parseHost = function() {\n var host = this.host;\n var port = portPattern.exec(host);\n if (port) {\n port = port[0];\n if (port !== ':') {\n this.port = port.substr(1);\n }\n host = host.substr(0, host.length - port.length);\n }\n if (host) this.hostname = host;\n};\n","'use strict';\n\nmodule.exports = {\n isString: function(arg) {\n return typeof(arg) === 'string';\n },\n isObject: function(arg) {\n return typeof(arg) === 'object' && arg !== null;\n },\n isNull: function(arg) {\n return arg === null;\n },\n isNullOrUndefined: function(arg) {\n return arg == null;\n }\n};\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n// runtime helper for setting properties on components\n// in a tree-shakable way\nexports.default = (sfc, props) => {\n const target = sfc.__vccOpts || sfc;\n for (const [key, val] of props) {\n target[key] = val;\n }\n return target;\n};\n","import{ref as e,onMounted as n,onUpdated as t,openBlock as a,createElementBlock as l,renderSlot as o,createElementVNode as u,withKeys as i,withModifiers as r,inject as c,mergeProps as d,Fragment as s,renderList as p,normalizeClass as v,toDisplayString as f,createCommentVNode as g,reactive as y,toRef as m,computed as h,watchEffect as b,defineComponent as B,getCurrentInstance as I,watch as x,nextTick as w,provide as M,resolveComponent as k,createVNode as O,withCtx as F,createBlock as V,withDirectives as S,vShow as A}from\"vue\";function T(e){return(T=\"function\"==typeof Symbol&&\"symbol\"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&\"function\"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?\"symbol\":typeof e})(e)}function C(e){return function(e){if(Array.isArray(e))return N(e)}(e)||function(e){if(\"undefined\"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e[\"@@iterator\"])return Array.from(e)}(e)||D(e)||function(){throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\")}()}function D(e,n){if(e){if(\"string\"==typeof e)return N(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return\"Object\"===t&&e.constructor&&(t=e.constructor.name),\"Map\"===t||\"Set\"===t?Array.from(e):\"Arguments\"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?N(e,n):void 0}}function N(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,a=new Array(n);t<n;t++)a[t]=e[t];return a}function E(e,n){var t=\"undefined\"!=typeof Symbol&&e[Symbol.iterator]||e[\"@@iterator\"];if(!t){if(Array.isArray(e)||(t=D(e))||n&&e&&\"number\"==typeof e.length){t&&(e=t);var a=0,l=function(){};return{s:l,n:function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}},e:function(e){throw e},f:l}}throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\")}var o,u=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return u=e.done,e},e:function(e){i=!0,o=e},f:function(){try{u||null==t.return||t.return()}finally{if(i)throw o}}}}var L={inheritAttrs:!1,name:\"vue-input\",props:{autocomplete:{required:!1,type:String},modelValue:{required:!0,type:String},placeholder:{required:!0,type:String},disabled:{required:!0,type:Boolean},tabindex:{required:!0,type:Number},autofocus:{required:!0,type:Boolean},comboboxUid:{required:!0,type:Number}},emits:[\"update:modelValue\",\"input\",\"change\",\"focus\",\"blur\",\"escape\"],setup:function(a,l){var o=e(null);return n((function(){a.autofocus&&o.value.focus()})),t((function(){a.autofocus&&o.value.focus()})),{handleInput:function(e){l.emit(\"input\",e),l.emit(\"update:modelValue\",e.target.value)},handleChange:function(e){l.emit(\"change\",e),l.emit(\"update:modelValue\",e.target.value)},handleFocus:function(e){l.emit(\"focus\",e)},handleBlur:function(e){l.emit(\"blur\",e)},input:o,handleEscape:function(e){o.value.blur(),l.emit(\"escape\",e)}}}},j={class:\"vue-input\"},$=[\"autocomplete\",\"modelValue\",\"placeholder\",\"disabled\",\"tabindex\",\"autofocus\",\"aria-controls\",\"aria-labelledby\"];L.render=function(e,n,t,c,d,s){return a(),l(\"div\",j,[o(e.$slots,\"prepend\"),u(\"input\",{ref:\"input\",autocomplete:t.autocomplete,modelValue:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,onInput:n[0]||(n[0]=function(){return c.handleInput&&c.handleInput.apply(c,arguments)}),onChange:n[1]||(n[1]=function(){return c.handleChange&&c.handleChange.apply(c,arguments)}),onFocus:n[2]||(n[2]=function(){return c.handleFocus&&c.handleFocus.apply(c,arguments)}),onBlur:n[3]||(n[3]=function(){return c.handleBlur&&c.handleBlur.apply(c,arguments)}),onKeyup:n[4]||(n[4]=i(r((function(){return c.handleEscape&&c.handleEscape.apply(c,arguments)}),[\"exact\"]),[\"esc\"])),tabindex:t.tabindex,autofocus:t.autofocus,\"aria-autocomplete\":\"list\",\"aria-controls\":\"vs\".concat(t.comboboxUid,\"-listbox\"),\"aria-labelledby\":\"vs\".concat(t.comboboxUid,\"-combobox\")},null,40,$),o(e.$slots,\"append\")])},L.__file=\"src/components/input.vue\";var U={inheritAttrs:!1,name:\"vue-tags\",props:{modelValue:{required:!0,type:Array,validator:function(e){return e.every((function(e){return void 0!==T(e.key)&&void 0!==e.label&&\"boolean\"==typeof e.selected}))}},collapseTags:{type:Boolean}},emits:[\"click\"],setup:function(e,n){return{dataAttrs:c(\"dataAttrs\"),handleClick:function(e){n.emit(\"click\",e)}}}};U.render=function(e,n,t,i,c,y){return a(),l(\"ul\",d({class:[\"vue-tags\",{collapsed:t.collapseTags}],onMousedown:n[0]||(n[0]=r((function(){}),[\"prevent\"])),tabindex:\"-1\",onClick:n[1]||(n[1]=function(){return i.handleClick&&i.handleClick.apply(i,arguments)})},i.dataAttrs),[(a(!0),l(s,null,p(t.modelValue,(function(n){return a(),l(s,{key:n.key},[n.group?g(\"v-if\",!0):(a(),l(\"li\",{key:0,class:v([\"vue-tag\",{selected:n.selected}])},[o(e.$slots,\"default\",{option:n},(function(){return[u(\"span\",null,f(n.label),1)]}))],2))],64)})),128))],16)},U.__file=\"src/components/tags.vue\";var z={inheritAttrs:!1,name:\"vue-dropdown\",props:{modelValue:{required:!0,type:Array,validator:function(e){return e.every((function(e){return void 0!==T(e.key)&&void 0!==e.label&&\"boolean\"==typeof e.selected}))}},comboboxUid:{required:!0,type:Number},maxHeight:{required:!0},highlightedOriginalIndex:{required:!0}},emits:[\"click-item\",\"mouseenter\"],setup:function(e,n){return{dataAttrs:c(\"dataAttrs\"),handleClickItem:function(e,t){t.disabled||n.emit(\"click-item\",e,t)},handleMouseenter:function(e,t){n.emit(\"mouseenter\",e,t)}}}},P=[\"id\",\"aria-multiselectable\",\"aria-busy\",\"aria-disabled\"],q=[\"onClick\",\"onMouseenter\",\"id\",\"aria-selected\",\"aria-disabled\"];z.render=function(e,n,t,i,c,y){return a(),l(\"ul\",d({class:\"vue-dropdown\",style:{maxHeight:t.maxHeight+\"px\"},onMousedown:n[0]||(n[0]=r((function(){}),[\"prevent\"]))},i.dataAttrs,{role:\"listbox\",id:\"vs\".concat(t.comboboxUid,\"-listbox\"),\"aria-multiselectable\":i.dataAttrs[\"data-multiple\"],\"aria-busy\":i.dataAttrs[\"data-loading\"],\"aria-disabled\":i.dataAttrs[\"data-disabled\"]}),[(a(!0),l(s,null,p(t.modelValue,(function(n,r){return a(),l(s,{key:n.key},[n.visible&&!1===n.hidden?(a(),l(\"li\",{key:0,onClick:function(e){return i.handleClickItem(e,n)},class:v([\"vue-dropdown-item\",{selected:n.selected,disabled:n.disabled,highlighted:n.originalIndex===t.highlightedOriginalIndex,group:n.group}]),onMouseenter:function(e){return i.handleMouseenter(e,n)},role:\"option\",id:\"vs\".concat(t.comboboxUid,\"-option-\").concat(r),\"aria-selected\":!!n.selected||!!n.disabled&&void 0,\"aria-disabled\":n.disabled},[o(e.$slots,\"default\",{option:n},(function(){return[u(\"span\",null,f(n.label),1)]}))],42,q)):g(\"v-if\",!0)],64)})),128))],16,P)},z.__file=\"src/components/dropdown.vue\";var H=function(e,n,t){var a=t.valueBy;return a(e)===a(n)},_=function(e,n,t){var a=t.valueBy;return e.some((function(e){return H(e,n,{valueBy:a})}))},W=function(e,n,t){var a=t.valueBy;return e.find((function(e){return a(e)===n}))},Z=function(e,n,t){var a=t.max,l=t.valueBy;return _(e,n,{valueBy:l})||e.length>=a?e:e.concat(n)},R=function(e,n,t){var a=t.min,l=t.valueBy;return!1===_(e,n,{valueBy:l})||e.length<=a?e:e.filter((function(e){return!1===H(e,n,{valueBy:l})}))},G=function(e){return h((function(){return\"function\"==typeof e.value?e.value:\"string\"==typeof e.value?function(n){return e.value.split(\".\").reduce((function(e,n){return e[n]}),n)}:function(e){return e}}))},Q=function(e,n){var t=h((function(){return e.value.reduce((function(e,n){return Object.assign(e,(t={},a=n.originalIndex,l=n,a in t?Object.defineProperty(t,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):t[a]=l,t));var t,a,l}),{})})),a=function(e){var a=t.value[e];return void 0!==a&&(!1!==l(a)&&(n.value=e,!0))},l=function(e){return!e.disabled&&!e.hidden&&e.visible},o=h((function(){return e.value.some((function(e){return l(e)}))}));return b((function(){if(!1===o.value&&(n.value=null),null!==n.value&&e.value.length<=n.value){var t,u=E(e.value.reverse());try{for(u.s();!(t=u.n()).done;){var i=t.value;if(a(i.originalIndex))break}}catch(e){u.e(e)}finally{u.f()}}if(null===n.value||!1===l(e.value[n.value])){var r,c=E(e.value);try{for(c.s();!(r=c.n()).done;){var d=r.value;if(a(d.originalIndex))break}}catch(e){c.e(e)}finally{c.f()}}})),{pointerForward:function(){if(!1!==o.value&&null!==n.value)for(var t=n.value+1,l=0;t!==n.value&&l++<e.value.length&&(e.value.length<=t&&(t=0),!a(t));)++t},pointerBackward:function(){if(!1!==o.value&&null!==n.value)for(var t=n.value-1,l=0;t!==n.value&&l++<e.value.length&&(t<0&&(t=e.value.length-1),!a(t));)--t},pointerSet:a}};var Y=B({name:\"vue-select\",inheritAttrs:!1,props:{modelValue:{required:!0},emptyModelValue:{},options:{required:!0,type:Array},labelBy:{type:[String,Function]},valueBy:{type:[String,Function]},disabledBy:{default:\"disabled\",type:[String,Function]},groupBy:{default:\"group\",type:[String,Function]},visibleOptions:{type:Array,default:null},multiple:{default:!1,type:Boolean},min:{default:0,type:Number},max:{default:1/0,type:Number},searchable:{default:!1,type:Boolean},searchPlaceholder:{default:\"Type to search\",type:String},clearOnSelect:{default:!1,type:Boolean},clearOnClose:{default:!1,type:Boolean},taggable:{default:!1,type:Boolean},collapseTags:{default:!1,type:Boolean},autocomplete:{default:\"off\",type:String},disabled:{default:!1,type:Boolean},loading:{default:!1,type:Boolean},closeOnSelect:{default:!1,type:Boolean},hideSelected:{default:!1,type:Boolean},placeholder:{default:\"Select option\",type:String},tabindex:{default:0,type:Number},autofocus:{default:!1,type:Boolean},maxHeight:{default:300,type:Number},openDirection:{type:String,validator:function(e){return[\"top\",\"bottom\"].includes(e)}}},emits:[\"selected\",\"removed\",\"update:modelValue\",\"focus\",\"blur\",\"toggle\",\"opened\",\"closed\",\"search:input\",\"search:change\",\"search:focus\",\"search:blur\"],setup:function(n,t){var a=function(e){var n=y({}),t=G(m(e,\"labelBy\"));b((function(){return n.labelBy=t.value}));var a=G(m(e,\"valueBy\"));b((function(){return n.valueBy=a.value}));var l=G(m(e,\"disabledBy\"));b((function(){return n.disabledBy=l.value}));var o=G(m(e,\"groupBy\"));b((function(){return n.groupBy=o.value}));var u=h((function(){return e.multiple?e.min:Math.min(1,e.min)}));b((function(){return n.min=u.value}));var i=h((function(){return e.multiple?e.max:1}));return b((function(){return n.max=i.value})),b((function(){return n.options=e.options})),n}(n),l=h((function(){var e;return null!==(e=n.emptyModelValue)&&void 0!==e?e:null})),o=I(),u=e(),i=e(),r=e(),c=h((function(){var e;return null===(e=r.value)||void 0===e?void 0:e._.refs.input})),d=e(!1);x((function(){return d.value}),(function(){d.value?(t.emit(\"opened\"),t.emit(\"focus\"),n.searchable?(c.value!==document.activeElement&&c.value.focus(),t.emit(\"search:focus\")):u.value.focus()):(n.searchable?(c.value===document.activeElement&&c.value.blur(),n.clearOnClose&&D(),t.emit(\"search:blur\")):u.value.blur(),t.emit(\"closed\"),t.emit(\"blur\")),t.emit(\"toggle\")}));var s=function(){n.disabled||(d.value=!0)},p=function(e){u.value.contains(null==e?void 0:e.relatedTarget)?setTimeout((function(){u.value.focus()})):d.value=!1};x((function(){return n.disabled}),(function(){return p()}));var v=e(\"\"),f=h((function(){return new RegExp(v.value.replace(/[.*+?^${}()|[\\]\\\\]/g,\"\\\\$&\"),\"i\")})),g=h((function(){return v.value?a.options.filter((function(e){return f.value.test(a.labelBy(e))})):void 0})),B=e([]),k=h((function(){return new Set(B.value.map((function(e){return a.valueBy(e)})))})),O=function(){if(n.multiple){if(!1===Array.isArray(n.modelValue))return!1;if(B.value.length!==n.modelValue.length)return!1;if(Object.keys(B.value).some((function(e){return B.value[e]!==W(a.options,n.modelValue[e],{valueBy:a.valueBy})})))return!1}else{if(0===B.value.length&&n.modelValue!==l.value)return!1;if(1===B.value.length&&n.modelValue===l.value)return!1;if(B.value[0]!==W(a.options,n.modelValue,{valueBy:a.valueBy}))return!1}return!0},F=function(){if(!O()){B.value=[];var e,t=E(n.multiple?n.modelValue:n.modelValue===l.value?[]:[n.modelValue]);try{for(t.s();!(e=t.n()).done;){var o=e.value,u=W(a.options,o,{valueBy:a.valueBy});!1!==_(a.options,u,{valueBy:a.valueBy})&&(B.value=Z(B.value,u,{max:1/0,valueBy:a.valueBy}))}}catch(e){t.e(e)}finally{t.f()}}};F(),x((function(){return n.modelValue}),(function(){return F()}),{deep:!0}),x((function(){return a.options}),(function(){B.value=a.options.filter((function(e){return k.value.has(a.valueBy(e))}))}),{deep:!0});var V,S=function(e,n){(n=n.originalOption).value.every((function(e){var n=W(a.options,e,{valueBy:a.valueBy});return _(B.value,n,{valueBy:a.valueBy})}))?n.value.forEach((function(e){var n=W(a.options,e,{valueBy:a.valueBy});B.value=R(B.value,n,{min:a.min,valueBy:a.valueBy}),t.emit(\"removed\",n)})):n.value.forEach((function(e){var n=W(a.options,e,{valueBy:a.valueBy});_(B.value,n,{valueBy:a.valueBy})||(B.value=Z(B.value,n,{max:a.max,valueBy:a.valueBy}),t.emit(\"selected\",n))}))},A=function(e,l){if(l=l.originalOption,_(B.value,l,{valueBy:a.valueBy}))B.value=R(B.value,l,{min:a.min,valueBy:a.valueBy}),t.emit(\"removed\",l);else{if(!n.multiple&&1===B.value.length){var o=B.value[0];B.value=R(B.value,B.value[0],{min:0,valueBy:a.valueBy}),t.emit(\"removed\",o)}B.value=Z(B.value,l,{max:a.max,valueBy:a.valueBy}),t.emit(\"selected\",l)}},T=function(){if(!O()){var e=B.value.map((function(e){return a.valueBy(e)}));n.multiple?t.emit(\"update:modelValue\",e):e.length?t.emit(\"update:modelValue\",e[0]):t.emit(\"update:modelValue\",l.value)}},D=function(){c.value.value=\"\",c.value.dispatchEvent(new Event(\"input\")),c.value.dispatchEvent(new Event(\"change\"))},N=h((function(){var e,t;return null!==(t=null!==(e=n.visibleOptions)&&void 0!==e?e:g.value)&&void 0!==t?t:a.options})),L=e(0),j=h((function(){var e,t=new Set(N.value.map((function(e){return a.valueBy(e)}))),l=a.options.map((function(e,l){var o,u={key:a.valueBy(e),label:a.labelBy(e),group:null!==(o=a.groupBy(e))&&void 0!==o&&o,originalIndex:l,originalOption:e};return u.selected=u.group?e.value.every((function(e){return k.value.has(e)})):k.value.has(a.valueBy(e)),u.disabled=u.group?a.disabledBy(e)||e.value.every((function(e){var n=W(a.options,e,{valueBy:a.valueBy});return a.disabledBy(n)})):a.disabledBy(e),u.visible=u.group?e.value.some((function(e){return t.has(e)})):t.has(a.valueBy(e)),u.hidden=!!n.hideSelected&&(u.group?e.value.every((function(e){return k.value.has(e)})):k.value.has(a.valueBy(e))),u})),o=E(l);try{for(o.s();!(e=o.n()).done;){var u=e.value;!1!==u.group&&(u.disabled&&function(){var e=new Set(u.originalOption.value);l.filter((function(n){return e.has(a.valueBy(n.originalOption))})).forEach((function(e){return e.disabled=!0}))}())}}catch(e){o.e(e)}finally{o.f()}return l})),$=Q(j,L),U=$.pointerForward,z=$.pointerBackward,P=$.pointerSet,q=\"\",H=/^[\\w]$/,Y=h((function(){var e=C(a.options.keys());return e.slice(L.value).concat(e.slice(0,L.value))})),K=function(){var e,n=null===(e=u.value)||void 0===e?void 0:e.querySelector(\".highlighted\");if(n&&i.value){var t,a=getComputedStyle(n);for(t=0;n.offsetTop+parseFloat(a.height)+parseFloat(a.paddingTop)+parseFloat(a.paddingBottom)>i.value.$el.clientHeight+i.value.$el.scrollTop&&t++<j.value.length;)i.value.$el.scrollTop=i.value.$el.scrollTop+parseFloat(a.height)+parseFloat(a.paddingTop)+parseFloat(a.paddingBottom);for(t=0;n.offsetTop<i.value.$el.scrollTop&&t++<j.value.length;)i.value.$el.scrollTop=i.value.$el.scrollTop-parseFloat(a.height)-parseFloat(a.paddingTop)-parseFloat(a.paddingBottom)}};x((function(){return[d.value,a.options,k.value]}),(function(e,n){!0!==(null==n?void 0:n[0])&&!1!==d.value&&0!==B.value.length&&(P(a.options.findIndex((function(e){return k.value.has(a.valueBy(e))}))),w(K))}),{deep:!0,immediate:!0});var J=h((function(){return{\"data-is-focusing\":d.value,\"data-visible-length\":j.value.filter((function(e){return e.visible&&!1===e.hidden})).length,\"data-not-selected-length\":a.options.length-j.value.filter((function(e){return e.selected})).length,\"data-selected-length\":j.value.filter((function(e){return e.selected})).length,\"data-addable\":j.value.filter((function(e){return e.selected})).length<a.max,\"data-removable\":j.value.filter((function(e){return e.selected})).length>a.min,\"data-total-length\":a.options.length,\"data-multiple\":n.multiple,\"data-loading\":n.loading,\"data-disabled\":n.disabled}}));M(\"dataAttrs\",J);var X=h((function(){return j.value.filter((function(e){return e.selected})).filter((function(e){return!e.group}))})),ee=h((function(){return n.multiple?0===X.value.length?n.placeholder:1===X.value.length?\"1 option selected\":X.value.length+\" options selected\":0===X.value.length?n.placeholder:X.value[0].label+\"\"})),ne=h((function(){var e=X.value.map((function(e){return e.originalOption}));return n.multiple?e:e[0]||l.value})),te=e();return x((function(){return[n.openDirection,d.value]}),(function(){var e,t;te.value=null!==(t=null!==(e=n.openDirection)&&void 0!==e?e:function(){if(void 0===u.value)return;if(void 0===window)return;return window.innerHeight-u.value.getBoundingClientRect().bottom>=n.maxHeight?\"bottom\":\"top\"}())&&void 0!==t?t:\"bottom\"}),{immediate:!0}),{instance:o,isFocusing:d,wrapper:u,dropdown:i,input:r,focus:s,blur:p,toggle:function(){d.value?p():s()},searchingInputValue:v,handleInputForInput:function(e){t.emit(\"search:input\",e)},handleChangeForInput:function(e){t.emit(\"search:change\",e)},handleFocusForInput:function(e){s()},handleBlurForInput:function(e){p()},optionsWithInfo:j,addOrRemoveOption:function(e,t){n.disabled||(t.group&&n.multiple?S(e,t):A(e,t),T(),!0===n.closeOnSelect&&(d.value=!1),!0===n.clearOnSelect&&v.value&&D())},dataAttrs:J,innerPlaceholder:ee,selected:ne,highlightedOriginalIndex:L,pointerForward:function(){U(),w(K)},pointerBackward:function(){z(),w(K)},pointerFirst:function(){var e,n=E(a.options.keys());try{for(n.s();!(e=n.n()).done;){var t=e.value;if(P(t))break}}catch(e){n.e(e)}finally{n.f()}w(K)},pointerLast:function(){var e,n=E(C(a.options.keys()).reverse());try{for(n.s();!(e=n.n()).done;){var t=e.value;if(P(t))break}}catch(e){n.e(e)}finally{n.f()}w(K)},typeAhead:function(e){var t,l;if(!n.searchable){var o=!1;if(H.test(e.key)?(q+=e.key.toLowerCase(),o=!0):\"Space\"===e.code&&(q+=\" \"),o){var u,i=E(Y.value);try{for(i.s();!(u=i.n()).done;){var r=u.value;if(!0===(null===(l=null===(t=a.labelBy(a.options[r]))||void 0===t?void 0:t.toLowerCase())||void 0===l?void 0:l.startsWith(q))&&P(r))break}}catch(e){i.e(e)}finally{i.f()}clearTimeout(V),V=setTimeout((function(){q=\"\"}),500)}}},pointerSet:P,direction:te}},components:{VInput:L,VTags:U,VDropdown:z}});Y.__VERSION__=\"2.10.2\";var K=[\"tabindex\",\"id\",\"role\",\"aria-expanded\",\"aria-owns\",\"aria-activedescendant\",\"aria-busy\",\"aria-disabled\"],J={ref:\"header\",class:\"vue-select-header\"},X={key:0,class:\"vue-input\"},ee=[\"placeholder\",\"autocomplete\"],ne=[\"onClick\"],te=u(\"span\",{class:\"icon loading\"},[u(\"div\"),u(\"div\"),u(\"div\")],-1),ae={key:0,class:\"vue-select-input-wrapper\"},le=u(\"span\",{class:\"icon loading\"},[u(\"div\"),u(\"div\"),u(\"div\")],-1);Y.render=function(e,n,t,c,p,y){var m=k(\"v-tags\"),h=k(\"v-input\"),b=k(\"v-dropdown\");return a(),l(\"div\",d({ref:\"wrapper\",class:[\"vue-select\",[\"direction-\".concat(e.direction)]],tabindex:e.isFocusing?-1:e.tabindex,onFocus:n[9]||(n[9]=function(){return e.focus&&e.focus.apply(e,arguments)}),onBlur:n[10]||(n[10]=function(n){return!e.searchable&&e.blur(n)})},Object.assign({},e.dataAttrs,e.$attrs),{onKeypress:n[11]||(n[11]=i(r((function(){return null!==e.highlightedOriginalIndex&&e.addOrRemoveOption(e.$event,e.optionsWithInfo[e.highlightedOriginalIndex])}),[\"prevent\",\"exact\"]),[\"enter\"])),onKeydown:[n[12]||(n[12]=i(r((function(){return e.pointerForward&&e.pointerForward.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"down\"])),n[13]||(n[13]=i(r((function(){return e.pointerBackward&&e.pointerBackward.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"up\"])),n[14]||(n[14]=i(r((function(){return e.pointerFirst&&e.pointerFirst.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"home\"])),n[15]||(n[15]=i(r((function(){return e.pointerLast&&e.pointerLast.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"end\"])),n[16]||(n[16]=function(){return e.typeAhead&&e.typeAhead.apply(e,arguments)})],id:\"vs\".concat(e.instance.uid,\"-combobox\"),role:e.searchable?\"combobox\":null,\"aria-expanded\":e.isFocusing,\"aria-haspopup\":\"listbox\",\"aria-owns\":\"vs\".concat(e.instance.uid,\"-listbox\"),\"aria-activedescendant\":null===e.highlightedOriginalIndex?null:\"vs\".concat(e.instance.uid,\"-option-\").concat(e.highlightedOriginalIndex),\"aria-busy\":e.loading,\"aria-disabled\":e.disabled}),[u(\"div\",J,[e.multiple&&e.taggable&&0===e.modelValue.length||!1===e.searchable&&!1===e.taggable?(a(),l(\"div\",X,[o(e.$slots,\"label\",{selected:e.selected},(function(){return[u(\"input\",{placeholder:e.innerPlaceholder,autocomplete:e.autocomplete,readonly:\"\",onClick:n[0]||(n[0]=function(){return e.focus&&e.focus.apply(e,arguments)})},null,8,ee)]}))])):g(\"v-if\",!0),e.multiple&&e.taggable?(a(),l(s,{key:1},[O(m,{modelValue:e.optionsWithInfo,\"collapse-tags\":e.collapseTags,tabindex:\"-1\",onClick:e.focus},{default:F((function(n){var t=n.option;return[o(e.$slots,\"tag\",{option:t.originalOption,remove:function(){return e.addOrRemoveOption(e.$event,t)}},(function(){return[u(\"span\",null,f(t.label),1),u(\"img\",{src:\"data:image/svg+xml;base64,PHN2ZyBpZD0iZGVsZXRlIiBkYXRhLW5hbWU9ImRlbGV0ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNTEyIDUxMiI+PHRpdGxlPmRlbGV0ZTwvdGl0bGU+PHBhdGggZD0iTTI1NiwyNEMzODMuOSwyNCw0ODgsMTI4LjEsNDg4LDI1NlMzODMuOSw0ODgsMjU2LDQ4OCwyNC4wNiwzODMuOSwyNC4wNiwyNTYsMTI4LjEsMjQsMjU2LDI0Wk0wLDI1NkMwLDM5Ny4xNiwxMTQuODQsNTEyLDI1Niw1MTJTNTEyLDM5Ny4xNiw1MTIsMjU2LDM5Ny4xNiwwLDI1NiwwLDAsMTE0Ljg0LDAsMjU2WiIgZmlsbD0iIzViNWI1ZiIvPjxwb2x5Z29uIHBvaW50cz0iMzgyIDE3Mi43MiAzMzkuMjkgMTMwLjAxIDI1NiAyMTMuMjkgMTcyLjcyIDEzMC4wMSAxMzAuMDEgMTcyLjcyIDIxMy4yOSAyNTYgMTMwLjAxIDMzOS4yOCAxNzIuNzIgMzgyIDI1NiAyOTguNzEgMzM5LjI5IDM4MS45OSAzODIgMzM5LjI4IDI5OC43MSAyNTYgMzgyIDE3Mi43MiIgZmlsbD0iIzViNWI1ZiIvPjwvc3ZnPg==\",alt:\"delete tag\",class:\"icon delete\",onClick:r((function(){return e.addOrRemoveOption(e.$event,t)}),[\"prevent\",\"stop\"])},null,8,ne)]}))]})),_:3},8,[\"modelValue\",\"collapse-tags\",\"onClick\"]),o(e.$slots,\"toggle\",{isFocusing:e.isFocusing,toggle:e.toggle},(function(){return[u(\"span\",{class:v([\"icon arrow-downward\",{active:e.isFocusing}]),onClick:n[1]||(n[1]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),onMousedown:n[2]||(n[2]=r((function(){}),[\"prevent\",\"stop\"]))},null,34)]}))],64)):(a(),l(s,{key:2},[e.searchable?(a(),V(h,{key:0,ref:\"input\",modelValue:e.searchingInputValue,\"onUpdate:modelValue\":n[3]||(n[3]=function(n){return e.searchingInputValue=n}),disabled:e.disabled,autocomplete:e.autocomplete,placeholder:e.isFocusing?e.searchPlaceholder:e.innerPlaceholder,onInput:e.handleInputForInput,onChange:e.handleChangeForInput,onFocus:e.handleFocusForInput,onBlur:e.handleBlurForInput,onEscape:e.blur,autofocus:e.autofocus||e.taggable&&e.searchable,tabindex:e.tabindex,comboboxUid:e.instance.uid},null,8,[\"modelValue\",\"disabled\",\"autocomplete\",\"placeholder\",\"onInput\",\"onChange\",\"onFocus\",\"onBlur\",\"onEscape\",\"autofocus\",\"tabindex\",\"comboboxUid\"])):g(\"v-if\",!0),e.loading?o(e.$slots,\"loading\",{key:1},(function(){return[te]})):o(e.$slots,\"toggle\",{key:2,isFocusing:e.isFocusing,toggle:e.toggle},(function(){return[u(\"span\",{class:v([\"icon arrow-downward\",{active:e.isFocusing}]),onClick:n[4]||(n[4]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),onMousedown:n[5]||(n[5]=r((function(){}),[\"prevent\",\"stop\"]))},null,34)]}))],64))],512),e.multiple&&e.taggable&&e.searchable?(a(),l(\"div\",ae,[S(O(h,{ref:\"input\",modelValue:e.searchingInputValue,\"onUpdate:modelValue\":n[6]||(n[6]=function(n){return e.searchingInputValue=n}),disabled:e.disabled,autocomplete:e.autocomplete,placeholder:e.isFocusing?e.searchPlaceholder:e.innerPlaceholder,onInput:e.handleInputForInput,onChange:e.handleChangeForInput,onFocus:e.handleFocusForInput,onBlur:e.handleBlurForInput,onEscape:e.blur,autofocus:e.autofocus||e.taggable&&e.searchable,tabindex:e.tabindex,comboboxUid:e.instance.uid},null,8,[\"modelValue\",\"disabled\",\"autocomplete\",\"placeholder\",\"onInput\",\"onChange\",\"onFocus\",\"onBlur\",\"onEscape\",\"autofocus\",\"tabindex\",\"comboboxUid\"]),[[A,e.isFocusing]]),e.loading?o(e.$slots,\"loading\",{key:0},(function(){return[le]})):g(\"v-if\",!0)])):g(\"v-if\",!0),O(b,{ref:\"dropdown\",modelValue:e.optionsWithInfo,\"onUpdate:modelValue\":n[7]||(n[7]=function(n){return e.optionsWithInfo=n}),onClickItem:e.addOrRemoveOption,onMouseenter:n[8]||(n[8]=function(n,t){return e.pointerSet(t.originalIndex)}),comboboxUid:e.instance.uid,maxHeight:e.maxHeight,highlightedOriginalIndex:e.highlightedOriginalIndex},{default:F((function(n){var t=n.option;return[o(e.$slots,\"dropdown-item\",{option:t.originalOption},(function(){return[u(\"span\",null,f(t.label),1)]}))]})),_:3},8,[\"modelValue\",\"onClickItem\",\"comboboxUid\",\"maxHeight\",\"highlightedOriginalIndex\"])],16,K)},Y.__file=\"src/index.vue\";export{Y as default};\n","/*!\n * vue-textarea-autosize v1.1.1 \n * (c) 2019 Saymon\n * Released under the MIT License.\n */\n//\n//\n//\n//\n//\n//\n//\nvar script = {\n name: 'TextareaAutosize',\n props: {\n value: {\n type: [String, Number],\n default: ''\n },\n autosize: {\n type: Boolean,\n default: true\n },\n minHeight: {\n type: [Number],\n 'default': null\n },\n maxHeight: {\n type: [Number],\n 'default': null\n },\n\n /*\n * Force !important for style properties\n */\n important: {\n type: [Boolean, Array],\n default: false\n }\n },\n data: function data() {\n return {\n // data property for v-model binding with real textarea tag\n val: null,\n // works when content height becomes more then value of the maxHeight property\n maxHeightScroll: false,\n height: 'auto'\n };\n },\n computed: {\n computedStyles: function computedStyles() {\n if (!this.autosize) return {};\n return {\n resize: !this.isResizeImportant ? 'none' : 'none !important',\n height: this.height,\n overflow: this.maxHeightScroll ? 'auto' : !this.isOverflowImportant ? 'hidden' : 'hidden !important'\n };\n },\n isResizeImportant: function isResizeImportant() {\n var imp = this.important;\n return imp === true || Array.isArray(imp) && imp.includes('resize');\n },\n isOverflowImportant: function isOverflowImportant() {\n var imp = this.important;\n return imp === true || Array.isArray(imp) && imp.includes('overflow');\n },\n isHeightImportant: function isHeightImportant() {\n var imp = this.important;\n return imp === true || Array.isArray(imp) && imp.includes('height');\n }\n },\n watch: {\n value: function value(val) {\n this.val = val;\n },\n val: function val(_val) {\n this.$nextTick(this.resize);\n this.$emit('input', _val);\n },\n minHeight: function minHeight() {\n this.$nextTick(this.resize);\n },\n maxHeight: function maxHeight() {\n this.$nextTick(this.resize);\n },\n autosize: function autosize(val) {\n if (val) this.resize();\n }\n },\n methods: {\n resize: function resize() {\n var _this = this;\n\n var important = this.isHeightImportant ? 'important' : '';\n this.height = \"auto\".concat(important ? ' !important' : '');\n this.$nextTick(function () {\n var contentHeight = _this.$el.scrollHeight + 1;\n\n if (_this.minHeight) {\n contentHeight = contentHeight < _this.minHeight ? _this.minHeight : contentHeight;\n }\n\n if (_this.maxHeight) {\n if (contentHeight > _this.maxHeight) {\n contentHeight = _this.maxHeight;\n _this.maxHeightScroll = true;\n } else {\n _this.maxHeightScroll = false;\n }\n }\n\n var heightVal = contentHeight + 'px';\n _this.height = \"\".concat(heightVal).concat(important ? ' !important' : '');\n });\n return this;\n }\n },\n created: function created() {\n this.val = this.value;\n },\n mounted: function mounted() {\n this.resize();\n }\n};\n\nfunction normalizeComponent(template, style, script, scopeId, isFunctionalTemplate, moduleIdentifier\n/* server only */\n, shadowMode, createInjector, createInjectorSSR, createInjectorShadow) {\n if (typeof shadowMode !== 'boolean') {\n createInjectorSSR = createInjector;\n createInjector = shadowMode;\n shadowMode = false;\n } // Vue.extend constructor export interop.\n\n\n var options = typeof script === 'function' ? script.options : script; // render functions\n\n if (template && template.render) {\n options.render = template.render;\n options.staticRenderFns = template.staticRenderFns;\n options._compiled = true; // functional template\n\n if (isFunctionalTemplate) {\n options.functional = true;\n }\n } // scopedId\n\n\n if (scopeId) {\n options._scopeId = scopeId;\n }\n\n var hook;\n\n if (moduleIdentifier) {\n // server build\n hook = function hook(context) {\n // 2.3 injection\n context = context || // cached call\n this.$vnode && this.$vnode.ssrContext || // stateful\n this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext; // functional\n // 2.2 with runInNewContext: true\n\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__;\n } // inject component styles\n\n\n if (style) {\n style.call(this, createInjectorSSR(context));\n } // register component module identifier for async chunk inference\n\n\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier);\n }\n }; // used by ssr in case component is cached and beforeCreate\n // never gets called\n\n\n options._ssrRegister = hook;\n } else if (style) {\n hook = shadowMode ? function () {\n style.call(this, createInjectorShadow(this.$root.$options.shadowRoot));\n } : function (context) {\n style.call(this, createInjector(context));\n };\n }\n\n if (hook) {\n if (options.functional) {\n // register for functional component in vue file\n var originalRender = options.render;\n\n options.render = function renderWithStyleInjection(h, context) {\n hook.call(context);\n return originalRender(h, context);\n };\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate;\n options.beforeCreate = existing ? [].concat(existing, hook) : [hook];\n }\n }\n\n return script;\n}\n\nvar normalizeComponent_1 = normalizeComponent;\n\n/* script */\nconst __vue_script__ = script;\n\n/* template */\nvar __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('textarea',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.val),expression:\"val\"}],style:(_vm.computedStyles),domProps:{\"value\":(_vm.val)},on:{\"focus\":_vm.resize,\"input\":function($event){if($event.target.composing){ return; }_vm.val=$event.target.value;}}})};\nvar __vue_staticRenderFns__ = [];\n\n /* style */\n const __vue_inject_styles__ = undefined;\n /* scoped */\n const __vue_scope_id__ = undefined;\n /* module identifier */\n const __vue_module_identifier__ = undefined;\n /* functional template */\n const __vue_is_functional_template__ = false;\n /* style inject */\n \n /* style inject SSR */\n \n\n \n var TextareaAutosize = normalizeComponent_1(\n { render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },\n __vue_inject_styles__,\n __vue_script__,\n __vue_scope_id__,\n __vue_is_functional_template__,\n __vue_module_identifier__,\n undefined,\n undefined\n );\n\nvar version = '1.1.1';\n\nvar install = function install(Vue) {\n Vue.component('TextareaAutosize', TextareaAutosize);\n};\n\nvar plugin = {\n install: install,\n version: version\n};\n\nif (typeof window !== 'undefined' && window.Vue) {\n window.Vue.use(plugin);\n}\n\nexport default plugin;\n","import { extend, isArray, isMap, isIntegerKey, isSymbol, hasOwn, isObject, hasChanged, makeMap, capitalize, toRawType, def, isFunction, NOOP } from '@vue/shared';\n\nfunction warn(msg, ...args) {\r\n console.warn(`[Vue warn] ${msg}`, ...args);\r\n}\n\nlet activeEffectScope;\r\nconst effectScopeStack = [];\r\nclass EffectScope {\r\n constructor(detached = false) {\r\n this.active = true;\r\n this.effects = [];\r\n this.cleanups = [];\r\n if (!detached && activeEffectScope) {\r\n this.parent = activeEffectScope;\r\n this.index =\r\n (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(this) - 1;\r\n }\r\n }\r\n run(fn) {\r\n if (this.active) {\r\n try {\r\n this.on();\r\n return fn();\r\n }\r\n finally {\r\n this.off();\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`cannot run an inactive effect scope.`);\r\n }\r\n }\r\n on() {\r\n if (this.active) {\r\n effectScopeStack.push(this);\r\n activeEffectScope = this;\r\n }\r\n }\r\n off() {\r\n if (this.active) {\r\n effectScopeStack.pop();\r\n activeEffectScope = effectScopeStack[effectScopeStack.length - 1];\r\n }\r\n }\r\n stop(fromParent) {\r\n if (this.active) {\r\n this.effects.forEach(e => e.stop());\r\n this.cleanups.forEach(cleanup => cleanup());\r\n if (this.scopes) {\r\n this.scopes.forEach(e => e.stop(true));\r\n }\r\n // nested scope, dereference from parent to avoid memory leaks\r\n if (this.parent && !fromParent) {\r\n // optimized O(1) removal\r\n const last = this.parent.scopes.pop();\r\n if (last && last !== this) {\r\n this.parent.scopes[this.index] = last;\r\n last.index = this.index;\r\n }\r\n }\r\n this.active = false;\r\n }\r\n }\r\n}\r\nfunction effectScope(detached) {\r\n return new EffectScope(detached);\r\n}\r\nfunction recordEffectScope(effect, scope) {\r\n scope = scope || activeEffectScope;\r\n if (scope && scope.active) {\r\n scope.effects.push(effect);\r\n }\r\n}\r\nfunction getCurrentScope() {\r\n return activeEffectScope;\r\n}\r\nfunction onScopeDispose(fn) {\r\n if (activeEffectScope) {\r\n activeEffectScope.cleanups.push(fn);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`onScopeDispose() is called when there is no active effect scope` +\r\n ` to be associated with.`);\r\n }\r\n}\n\nconst createDep = (effects) => {\r\n const dep = new Set(effects);\r\n dep.w = 0;\r\n dep.n = 0;\r\n return dep;\r\n};\r\nconst wasTracked = (dep) => (dep.w & trackOpBit) > 0;\r\nconst newTracked = (dep) => (dep.n & trackOpBit) > 0;\r\nconst initDepMarkers = ({ deps }) => {\r\n if (deps.length) {\r\n for (let i = 0; i < deps.length; i++) {\r\n deps[i].w |= trackOpBit; // set was tracked\r\n }\r\n }\r\n};\r\nconst finalizeDepMarkers = (effect) => {\r\n const { deps } = effect;\r\n if (deps.length) {\r\n let ptr = 0;\r\n for (let i = 0; i < deps.length; i++) {\r\n const dep = deps[i];\r\n if (wasTracked(dep) && !newTracked(dep)) {\r\n dep.delete(effect);\r\n }\r\n else {\r\n deps[ptr++] = dep;\r\n }\r\n // clear bits\r\n dep.w &= ~trackOpBit;\r\n dep.n &= ~trackOpBit;\r\n }\r\n deps.length = ptr;\r\n }\r\n};\n\nconst targetMap = new WeakMap();\r\n// The number of effects currently being tracked recursively.\r\nlet effectTrackDepth = 0;\r\nlet trackOpBit = 1;\r\n/**\r\n * The bitwise track markers support at most 30 levels of recursion.\r\n * This value is chosen to enable modern JS engines to use a SMI on all platforms.\r\n * When recursion depth is greater, fall back to using a full cleanup.\r\n */\r\nconst maxMarkerBits = 30;\r\nconst effectStack = [];\r\nlet activeEffect;\r\nconst ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'iterate' : '');\r\nconst MAP_KEY_ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'Map key iterate' : '');\r\nclass ReactiveEffect {\r\n constructor(fn, scheduler = null, scope) {\r\n this.fn = fn;\r\n this.scheduler = scheduler;\r\n this.active = true;\r\n this.deps = [];\r\n recordEffectScope(this, scope);\r\n }\r\n run() {\r\n if (!this.active) {\r\n return this.fn();\r\n }\r\n if (!effectStack.includes(this)) {\r\n try {\r\n effectStack.push((activeEffect = this));\r\n enableTracking();\r\n trackOpBit = 1 << ++effectTrackDepth;\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n initDepMarkers(this);\r\n }\r\n else {\r\n cleanupEffect(this);\r\n }\r\n return this.fn();\r\n }\r\n finally {\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n finalizeDepMarkers(this);\r\n }\r\n trackOpBit = 1 << --effectTrackDepth;\r\n resetTracking();\r\n effectStack.pop();\r\n const n = effectStack.length;\r\n activeEffect = n > 0 ? effectStack[n - 1] : undefined;\r\n }\r\n }\r\n }\r\n stop() {\r\n if (this.active) {\r\n cleanupEffect(this);\r\n if (this.onStop) {\r\n this.onStop();\r\n }\r\n this.active = false;\r\n }\r\n }\r\n}\r\nfunction cleanupEffect(effect) {\r\n const { deps } = effect;\r\n if (deps.length) {\r\n for (let i = 0; i < deps.length; i++) {\r\n deps[i].delete(effect);\r\n }\r\n deps.length = 0;\r\n }\r\n}\r\nfunction effect(fn, options) {\r\n if (fn.effect) {\r\n fn = fn.effect.fn;\r\n }\r\n const _effect = new ReactiveEffect(fn);\r\n if (options) {\r\n extend(_effect, options);\r\n if (options.scope)\r\n recordEffectScope(_effect, options.scope);\r\n }\r\n if (!options || !options.lazy) {\r\n _effect.run();\r\n }\r\n const runner = _effect.run.bind(_effect);\r\n runner.effect = _effect;\r\n return runner;\r\n}\r\nfunction stop(runner) {\r\n runner.effect.stop();\r\n}\r\nlet shouldTrack = true;\r\nconst trackStack = [];\r\nfunction pauseTracking() {\r\n trackStack.push(shouldTrack);\r\n shouldTrack = false;\r\n}\r\nfunction enableTracking() {\r\n trackStack.push(shouldTrack);\r\n shouldTrack = true;\r\n}\r\nfunction resetTracking() {\r\n const last = trackStack.pop();\r\n shouldTrack = last === undefined ? true : last;\r\n}\r\nfunction track(target, type, key) {\r\n if (!isTracking()) {\r\n return;\r\n }\r\n let depsMap = targetMap.get(target);\r\n if (!depsMap) {\r\n targetMap.set(target, (depsMap = new Map()));\r\n }\r\n let dep = depsMap.get(key);\r\n if (!dep) {\r\n depsMap.set(key, (dep = createDep()));\r\n }\r\n const eventInfo = (process.env.NODE_ENV !== 'production')\r\n ? { effect: activeEffect, target, type, key }\r\n : undefined;\r\n trackEffects(dep, eventInfo);\r\n}\r\nfunction isTracking() {\r\n return shouldTrack && activeEffect !== undefined;\r\n}\r\nfunction trackEffects(dep, debuggerEventExtraInfo) {\r\n let shouldTrack = false;\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n if (!newTracked(dep)) {\r\n dep.n |= trackOpBit; // set newly tracked\r\n shouldTrack = !wasTracked(dep);\r\n }\r\n }\r\n else {\r\n // Full cleanup mode.\r\n shouldTrack = !dep.has(activeEffect);\r\n }\r\n if (shouldTrack) {\r\n dep.add(activeEffect);\r\n activeEffect.deps.push(dep);\r\n if ((process.env.NODE_ENV !== 'production') && activeEffect.onTrack) {\r\n activeEffect.onTrack(Object.assign({\r\n effect: activeEffect\r\n }, debuggerEventExtraInfo));\r\n }\r\n }\r\n}\r\nfunction trigger(target, type, key, newValue, oldValue, oldTarget) {\r\n const depsMap = targetMap.get(target);\r\n if (!depsMap) {\r\n // never been tracked\r\n return;\r\n }\r\n let deps = [];\r\n if (type === \"clear\" /* CLEAR */) {\r\n // collection being cleared\r\n // trigger all effects for target\r\n deps = [...depsMap.values()];\r\n }\r\n else if (key === 'length' && isArray(target)) {\r\n depsMap.forEach((dep, key) => {\r\n if (key === 'length' || key >= newValue) {\r\n deps.push(dep);\r\n }\r\n });\r\n }\r\n else {\r\n // schedule runs for SET | ADD | DELETE\r\n if (key !== void 0) {\r\n deps.push(depsMap.get(key));\r\n }\r\n // also run for iteration key on ADD | DELETE | Map.SET\r\n switch (type) {\r\n case \"add\" /* ADD */:\r\n if (!isArray(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n }\r\n }\r\n else if (isIntegerKey(key)) {\r\n // new index added to array -> length changes\r\n deps.push(depsMap.get('length'));\r\n }\r\n break;\r\n case \"delete\" /* DELETE */:\r\n if (!isArray(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n }\r\n }\r\n break;\r\n case \"set\" /* SET */:\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n }\r\n break;\r\n }\r\n }\r\n const eventInfo = (process.env.NODE_ENV !== 'production')\r\n ? { target, type, key, newValue, oldValue, oldTarget }\r\n : undefined;\r\n if (deps.length === 1) {\r\n if (deps[0]) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(deps[0], eventInfo);\r\n }\r\n else {\r\n triggerEffects(deps[0]);\r\n }\r\n }\r\n }\r\n else {\r\n const effects = [];\r\n for (const dep of deps) {\r\n if (dep) {\r\n effects.push(...dep);\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(createDep(effects), eventInfo);\r\n }\r\n else {\r\n triggerEffects(createDep(effects));\r\n }\r\n }\r\n}\r\nfunction triggerEffects(dep, debuggerEventExtraInfo) {\r\n // spread into array for stabilization\r\n for (const effect of isArray(dep) ? dep : [...dep]) {\r\n if (effect !== activeEffect || effect.allowRecurse) {\r\n if ((process.env.NODE_ENV !== 'production') && effect.onTrigger) {\r\n effect.onTrigger(extend({ effect }, debuggerEventExtraInfo));\r\n }\r\n if (effect.scheduler) {\r\n effect.scheduler();\r\n }\r\n else {\r\n effect.run();\r\n }\r\n }\r\n }\r\n}\n\nconst isNonTrackableKeys = /*#__PURE__*/ makeMap(`__proto__,__v_isRef,__isVue`);\r\nconst builtInSymbols = new Set(Object.getOwnPropertyNames(Symbol)\r\n .map(key => Symbol[key])\r\n .filter(isSymbol));\r\nconst get = /*#__PURE__*/ createGetter();\r\nconst shallowGet = /*#__PURE__*/ createGetter(false, true);\r\nconst readonlyGet = /*#__PURE__*/ createGetter(true);\r\nconst shallowReadonlyGet = /*#__PURE__*/ createGetter(true, true);\r\nconst arrayInstrumentations = /*#__PURE__*/ createArrayInstrumentations();\r\nfunction createArrayInstrumentations() {\r\n const instrumentations = {};\r\n ['includes', 'indexOf', 'lastIndexOf'].forEach(key => {\r\n instrumentations[key] = function (...args) {\r\n const arr = toRaw(this);\r\n for (let i = 0, l = this.length; i < l; i++) {\r\n track(arr, \"get\" /* GET */, i + '');\r\n }\r\n // we run the method using the original args first (which may be reactive)\r\n const res = arr[key](...args);\r\n if (res === -1 || res === false) {\r\n // if that didn't work, run it again using raw values.\r\n return arr[key](...args.map(toRaw));\r\n }\r\n else {\r\n return res;\r\n }\r\n };\r\n });\r\n ['push', 'pop', 'shift', 'unshift', 'splice'].forEach(key => {\r\n instrumentations[key] = function (...args) {\r\n pauseTracking();\r\n const res = toRaw(this)[key].apply(this, args);\r\n resetTracking();\r\n return res;\r\n };\r\n });\r\n return instrumentations;\r\n}\r\nfunction createGetter(isReadonly = false, shallow = false) {\r\n return function get(target, key, receiver) {\r\n if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n return !isReadonly;\r\n }\r\n else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n return isReadonly;\r\n }\r\n else if (key === \"__v_raw\" /* RAW */ &&\r\n receiver ===\r\n (isReadonly\r\n ? shallow\r\n ? shallowReadonlyMap\r\n : readonlyMap\r\n : shallow\r\n ? shallowReactiveMap\r\n : reactiveMap).get(target)) {\r\n return target;\r\n }\r\n const targetIsArray = isArray(target);\r\n if (!isReadonly && targetIsArray && hasOwn(arrayInstrumentations, key)) {\r\n return Reflect.get(arrayInstrumentations, key, receiver);\r\n }\r\n const res = Reflect.get(target, key, receiver);\r\n if (isSymbol(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {\r\n return res;\r\n }\r\n if (!isReadonly) {\r\n track(target, \"get\" /* GET */, key);\r\n }\r\n if (shallow) {\r\n return res;\r\n }\r\n if (isRef(res)) {\r\n // ref unwrapping - does not apply for Array + integer key.\r\n const shouldUnwrap = !targetIsArray || !isIntegerKey(key);\r\n return shouldUnwrap ? res.value : res;\r\n }\r\n if (isObject(res)) {\r\n // Convert returned value into a proxy as well. we do the isObject check\r\n // here to avoid invalid value warning. Also need to lazy access readonly\r\n // and reactive here to avoid circular dependency.\r\n return isReadonly ? readonly(res) : reactive(res);\r\n }\r\n return res;\r\n };\r\n}\r\nconst set = /*#__PURE__*/ createSetter();\r\nconst shallowSet = /*#__PURE__*/ createSetter(true);\r\nfunction createSetter(shallow = false) {\r\n return function set(target, key, value, receiver) {\r\n let oldValue = target[key];\r\n if (!shallow && !isReadonly(value)) {\r\n value = toRaw(value);\r\n oldValue = toRaw(oldValue);\r\n if (!isArray(target) && isRef(oldValue) && !isRef(value)) {\r\n oldValue.value = value;\r\n return true;\r\n }\r\n }\r\n const hadKey = isArray(target) && isIntegerKey(key)\r\n ? Number(key) < target.length\r\n : hasOwn(target, key);\r\n const result = Reflect.set(target, key, value, receiver);\r\n // don't trigger if target is something up in the prototype chain of original\r\n if (target === toRaw(receiver)) {\r\n if (!hadKey) {\r\n trigger(target, \"add\" /* ADD */, key, value);\r\n }\r\n else if (hasChanged(value, oldValue)) {\r\n trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n }\r\n }\r\n return result;\r\n };\r\n}\r\nfunction deleteProperty(target, key) {\r\n const hadKey = hasOwn(target, key);\r\n const oldValue = target[key];\r\n const result = Reflect.deleteProperty(target, key);\r\n if (result && hadKey) {\r\n trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n }\r\n return result;\r\n}\r\nfunction has(target, key) {\r\n const result = Reflect.has(target, key);\r\n if (!isSymbol(key) || !builtInSymbols.has(key)) {\r\n track(target, \"has\" /* HAS */, key);\r\n }\r\n return result;\r\n}\r\nfunction ownKeys(target) {\r\n track(target, \"iterate\" /* ITERATE */, isArray(target) ? 'length' : ITERATE_KEY);\r\n return Reflect.ownKeys(target);\r\n}\r\nconst mutableHandlers = {\r\n get,\r\n set,\r\n deleteProperty,\r\n has,\r\n ownKeys\r\n};\r\nconst readonlyHandlers = {\r\n get: readonlyGet,\r\n set(target, key) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`Set operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n }\r\n return true;\r\n },\r\n deleteProperty(target, key) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`Delete operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n }\r\n return true;\r\n }\r\n};\r\nconst shallowReactiveHandlers = /*#__PURE__*/ extend({}, mutableHandlers, {\r\n get: shallowGet,\r\n set: shallowSet\r\n});\r\n// Props handlers are special in the sense that it should not unwrap top-level\r\n// refs (in order to allow refs to be explicitly passed down), but should\r\n// retain the reactivity of the normal readonly object.\r\nconst shallowReadonlyHandlers = /*#__PURE__*/ extend({}, readonlyHandlers, {\r\n get: shallowReadonlyGet\r\n});\n\nconst toShallow = (value) => value;\r\nconst getProto = (v) => Reflect.getPrototypeOf(v);\r\nfunction get$1(target, key, isReadonly = false, isShallow = false) {\r\n // #1772: readonly(reactive(Map)) should return readonly + reactive version\r\n // of the value\r\n target = target[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const rawKey = toRaw(key);\r\n if (key !== rawKey) {\r\n !isReadonly && track(rawTarget, \"get\" /* GET */, key);\r\n }\r\n !isReadonly && track(rawTarget, \"get\" /* GET */, rawKey);\r\n const { has } = getProto(rawTarget);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n if (has.call(rawTarget, key)) {\r\n return wrap(target.get(key));\r\n }\r\n else if (has.call(rawTarget, rawKey)) {\r\n return wrap(target.get(rawKey));\r\n }\r\n else if (target !== rawTarget) {\r\n // #3602 readonly(reactive(Map))\r\n // ensure that the nested reactive `Map` can do tracking for itself\r\n target.get(key);\r\n }\r\n}\r\nfunction has$1(key, isReadonly = false) {\r\n const target = this[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const rawKey = toRaw(key);\r\n if (key !== rawKey) {\r\n !isReadonly && track(rawTarget, \"has\" /* HAS */, key);\r\n }\r\n !isReadonly && track(rawTarget, \"has\" /* HAS */, rawKey);\r\n return key === rawKey\r\n ? target.has(key)\r\n : target.has(key) || target.has(rawKey);\r\n}\r\nfunction size(target, isReadonly = false) {\r\n target = target[\"__v_raw\" /* RAW */];\r\n !isReadonly && track(toRaw(target), \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n return Reflect.get(target, 'size', target);\r\n}\r\nfunction add(value) {\r\n value = toRaw(value);\r\n const target = toRaw(this);\r\n const proto = getProto(target);\r\n const hadKey = proto.has.call(target, value);\r\n if (!hadKey) {\r\n target.add(value);\r\n trigger(target, \"add\" /* ADD */, value, value);\r\n }\r\n return this;\r\n}\r\nfunction set$1(key, value) {\r\n value = toRaw(value);\r\n const target = toRaw(this);\r\n const { has, get } = getProto(target);\r\n let hadKey = has.call(target, key);\r\n if (!hadKey) {\r\n key = toRaw(key);\r\n hadKey = has.call(target, key);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n checkIdentityKeys(target, has, key);\r\n }\r\n const oldValue = get.call(target, key);\r\n target.set(key, value);\r\n if (!hadKey) {\r\n trigger(target, \"add\" /* ADD */, key, value);\r\n }\r\n else if (hasChanged(value, oldValue)) {\r\n trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n }\r\n return this;\r\n}\r\nfunction deleteEntry(key) {\r\n const target = toRaw(this);\r\n const { has, get } = getProto(target);\r\n let hadKey = has.call(target, key);\r\n if (!hadKey) {\r\n key = toRaw(key);\r\n hadKey = has.call(target, key);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n checkIdentityKeys(target, has, key);\r\n }\r\n const oldValue = get ? get.call(target, key) : undefined;\r\n // forward the operation before queueing reactions\r\n const result = target.delete(key);\r\n if (hadKey) {\r\n trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n }\r\n return result;\r\n}\r\nfunction clear() {\r\n const target = toRaw(this);\r\n const hadItems = target.size !== 0;\r\n const oldTarget = (process.env.NODE_ENV !== 'production')\r\n ? isMap(target)\r\n ? new Map(target)\r\n : new Set(target)\r\n : undefined;\r\n // forward the operation before queueing reactions\r\n const result = target.clear();\r\n if (hadItems) {\r\n trigger(target, \"clear\" /* CLEAR */, undefined, undefined, oldTarget);\r\n }\r\n return result;\r\n}\r\nfunction createForEach(isReadonly, isShallow) {\r\n return function forEach(callback, thisArg) {\r\n const observed = this;\r\n const target = observed[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n !isReadonly && track(rawTarget, \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n return target.forEach((value, key) => {\r\n // important: make sure the callback is\r\n // 1. invoked with the reactive map as `this` and 3rd arg\r\n // 2. the value received should be a corresponding reactive/readonly.\r\n return callback.call(thisArg, wrap(value), wrap(key), observed);\r\n });\r\n };\r\n}\r\nfunction createIterableMethod(method, isReadonly, isShallow) {\r\n return function (...args) {\r\n const target = this[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const targetIsMap = isMap(rawTarget);\r\n const isPair = method === 'entries' || (method === Symbol.iterator && targetIsMap);\r\n const isKeyOnly = method === 'keys' && targetIsMap;\r\n const innerIterator = target[method](...args);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n !isReadonly &&\r\n track(rawTarget, \"iterate\" /* ITERATE */, isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY);\r\n // return a wrapped iterator which returns observed versions of the\r\n // values emitted from the real iterator\r\n return {\r\n // iterator protocol\r\n next() {\r\n const { value, done } = innerIterator.next();\r\n return done\r\n ? { value, done }\r\n : {\r\n value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),\r\n done\r\n };\r\n },\r\n // iterable protocol\r\n [Symbol.iterator]() {\r\n return this;\r\n }\r\n };\r\n };\r\n}\r\nfunction createReadonlyMethod(type) {\r\n return function (...args) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const key = args[0] ? `on key \"${args[0]}\" ` : ``;\r\n console.warn(`${capitalize(type)} operation ${key}failed: target is readonly.`, toRaw(this));\r\n }\r\n return type === \"delete\" /* DELETE */ ? false : this;\r\n };\r\n}\r\nfunction createInstrumentations() {\r\n const mutableInstrumentations = {\r\n get(key) {\r\n return get$1(this, key);\r\n },\r\n get size() {\r\n return size(this);\r\n },\r\n has: has$1,\r\n add,\r\n set: set$1,\r\n delete: deleteEntry,\r\n clear,\r\n forEach: createForEach(false, false)\r\n };\r\n const shallowInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, false, true);\r\n },\r\n get size() {\r\n return size(this);\r\n },\r\n has: has$1,\r\n add,\r\n set: set$1,\r\n delete: deleteEntry,\r\n clear,\r\n forEach: createForEach(false, true)\r\n };\r\n const readonlyInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, true);\r\n },\r\n get size() {\r\n return size(this, true);\r\n },\r\n has(key) {\r\n return has$1.call(this, key, true);\r\n },\r\n add: createReadonlyMethod(\"add\" /* ADD */),\r\n set: createReadonlyMethod(\"set\" /* SET */),\r\n delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n forEach: createForEach(true, false)\r\n };\r\n const shallowReadonlyInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, true, true);\r\n },\r\n get size() {\r\n return size(this, true);\r\n },\r\n has(key) {\r\n return has$1.call(this, key, true);\r\n },\r\n add: createReadonlyMethod(\"add\" /* ADD */),\r\n set: createReadonlyMethod(\"set\" /* SET */),\r\n delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n forEach: createForEach(true, true)\r\n };\r\n const iteratorMethods = ['keys', 'values', 'entries', Symbol.iterator];\r\n iteratorMethods.forEach(method => {\r\n mutableInstrumentations[method] = createIterableMethod(method, false, false);\r\n readonlyInstrumentations[method] = createIterableMethod(method, true, false);\r\n shallowInstrumentations[method] = createIterableMethod(method, false, true);\r\n shallowReadonlyInstrumentations[method] = createIterableMethod(method, true, true);\r\n });\r\n return [\r\n mutableInstrumentations,\r\n readonlyInstrumentations,\r\n shallowInstrumentations,\r\n shallowReadonlyInstrumentations\r\n ];\r\n}\r\nconst [mutableInstrumentations, readonlyInstrumentations, shallowInstrumentations, shallowReadonlyInstrumentations] = /* #__PURE__*/ createInstrumentations();\r\nfunction createInstrumentationGetter(isReadonly, shallow) {\r\n const instrumentations = shallow\r\n ? isReadonly\r\n ? shallowReadonlyInstrumentations\r\n : shallowInstrumentations\r\n : isReadonly\r\n ? readonlyInstrumentations\r\n : mutableInstrumentations;\r\n return (target, key, receiver) => {\r\n if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n return !isReadonly;\r\n }\r\n else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n return isReadonly;\r\n }\r\n else if (key === \"__v_raw\" /* RAW */) {\r\n return target;\r\n }\r\n return Reflect.get(hasOwn(instrumentations, key) && key in target\r\n ? instrumentations\r\n : target, key, receiver);\r\n };\r\n}\r\nconst mutableCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(false, false)\r\n};\r\nconst shallowCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(false, true)\r\n};\r\nconst readonlyCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(true, false)\r\n};\r\nconst shallowReadonlyCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(true, true)\r\n};\r\nfunction checkIdentityKeys(target, has, key) {\r\n const rawKey = toRaw(key);\r\n if (rawKey !== key && has.call(target, rawKey)) {\r\n const type = toRawType(target);\r\n console.warn(`Reactive ${type} contains both the raw and reactive ` +\r\n `versions of the same object${type === `Map` ? ` as keys` : ``}, ` +\r\n `which can lead to inconsistencies. ` +\r\n `Avoid differentiating between the raw and reactive versions ` +\r\n `of an object and only use the reactive version if possible.`);\r\n }\r\n}\n\nconst reactiveMap = new WeakMap();\r\nconst shallowReactiveMap = new WeakMap();\r\nconst readonlyMap = new WeakMap();\r\nconst shallowReadonlyMap = new WeakMap();\r\nfunction targetTypeMap(rawType) {\r\n switch (rawType) {\r\n case 'Object':\r\n case 'Array':\r\n return 1 /* COMMON */;\r\n case 'Map':\r\n case 'Set':\r\n case 'WeakMap':\r\n case 'WeakSet':\r\n return 2 /* COLLECTION */;\r\n default:\r\n return 0 /* INVALID */;\r\n }\r\n}\r\nfunction getTargetType(value) {\r\n return value[\"__v_skip\" /* SKIP */] || !Object.isExtensible(value)\r\n ? 0 /* INVALID */\r\n : targetTypeMap(toRawType(value));\r\n}\r\nfunction reactive(target) {\r\n // if trying to observe a readonly proxy, return the readonly version.\r\n if (target && target[\"__v_isReadonly\" /* IS_READONLY */]) {\r\n return target;\r\n }\r\n return createReactiveObject(target, false, mutableHandlers, mutableCollectionHandlers, reactiveMap);\r\n}\r\n/**\r\n * Return a shallowly-reactive copy of the original object, where only the root\r\n * level properties are reactive. It also does not auto-unwrap refs (even at the\r\n * root level).\r\n */\r\nfunction shallowReactive(target) {\r\n return createReactiveObject(target, false, shallowReactiveHandlers, shallowCollectionHandlers, shallowReactiveMap);\r\n}\r\n/**\r\n * Creates a readonly copy of the original object. Note the returned copy is not\r\n * made reactive, but `readonly` can be called on an already reactive object.\r\n */\r\nfunction readonly(target) {\r\n return createReactiveObject(target, true, readonlyHandlers, readonlyCollectionHandlers, readonlyMap);\r\n}\r\n/**\r\n * Returns a reactive-copy of the original object, where only the root level\r\n * properties are readonly, and does NOT unwrap refs nor recursively convert\r\n * returned properties.\r\n * This is used for creating the props proxy object for stateful components.\r\n */\r\nfunction shallowReadonly(target) {\r\n return createReactiveObject(target, true, shallowReadonlyHandlers, shallowReadonlyCollectionHandlers, shallowReadonlyMap);\r\n}\r\nfunction createReactiveObject(target, isReadonly, baseHandlers, collectionHandlers, proxyMap) {\r\n if (!isObject(target)) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`value cannot be made reactive: ${String(target)}`);\r\n }\r\n return target;\r\n }\r\n // target is already a Proxy, return it.\r\n // exception: calling readonly() on a reactive object\r\n if (target[\"__v_raw\" /* RAW */] &&\r\n !(isReadonly && target[\"__v_isReactive\" /* IS_REACTIVE */])) {\r\n return target;\r\n }\r\n // target already has corresponding Proxy\r\n const existingProxy = proxyMap.get(target);\r\n if (existingProxy) {\r\n return existingProxy;\r\n }\r\n // only a whitelist of value types can be observed.\r\n const targetType = getTargetType(target);\r\n if (targetType === 0 /* INVALID */) {\r\n return target;\r\n }\r\n const proxy = new Proxy(target, targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers);\r\n proxyMap.set(target, proxy);\r\n return proxy;\r\n}\r\nfunction isReactive(value) {\r\n if (isReadonly(value)) {\r\n return isReactive(value[\"__v_raw\" /* RAW */]);\r\n }\r\n return !!(value && value[\"__v_isReactive\" /* IS_REACTIVE */]);\r\n}\r\nfunction isReadonly(value) {\r\n return !!(value && value[\"__v_isReadonly\" /* IS_READONLY */]);\r\n}\r\nfunction isProxy(value) {\r\n return isReactive(value) || isReadonly(value);\r\n}\r\nfunction toRaw(observed) {\r\n const raw = observed && observed[\"__v_raw\" /* RAW */];\r\n return raw ? toRaw(raw) : observed;\r\n}\r\nfunction markRaw(value) {\r\n def(value, \"__v_skip\" /* SKIP */, true);\r\n return value;\r\n}\r\nconst toReactive = (value) => isObject(value) ? reactive(value) : value;\r\nconst toReadonly = (value) => isObject(value) ? readonly(value) : value;\n\nfunction trackRefValue(ref) {\r\n if (isTracking()) {\r\n ref = toRaw(ref);\r\n if (!ref.dep) {\r\n ref.dep = createDep();\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n trackEffects(ref.dep, {\r\n target: ref,\r\n type: \"get\" /* GET */,\r\n key: 'value'\r\n });\r\n }\r\n else {\r\n trackEffects(ref.dep);\r\n }\r\n }\r\n}\r\nfunction triggerRefValue(ref, newVal) {\r\n ref = toRaw(ref);\r\n if (ref.dep) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(ref.dep, {\r\n target: ref,\r\n type: \"set\" /* SET */,\r\n key: 'value',\r\n newValue: newVal\r\n });\r\n }\r\n else {\r\n triggerEffects(ref.dep);\r\n }\r\n }\r\n}\r\nfunction isRef(r) {\r\n return Boolean(r && r.__v_isRef === true);\r\n}\r\nfunction ref(value) {\r\n return createRef(value, false);\r\n}\r\nfunction shallowRef(value) {\r\n return createRef(value, true);\r\n}\r\nfunction createRef(rawValue, shallow) {\r\n if (isRef(rawValue)) {\r\n return rawValue;\r\n }\r\n return new RefImpl(rawValue, shallow);\r\n}\r\nclass RefImpl {\r\n constructor(value, _shallow) {\r\n this._shallow = _shallow;\r\n this.dep = undefined;\r\n this.__v_isRef = true;\r\n this._rawValue = _shallow ? value : toRaw(value);\r\n this._value = _shallow ? value : toReactive(value);\r\n }\r\n get value() {\r\n trackRefValue(this);\r\n return this._value;\r\n }\r\n set value(newVal) {\r\n newVal = this._shallow ? newVal : toRaw(newVal);\r\n if (hasChanged(newVal, this._rawValue)) {\r\n this._rawValue = newVal;\r\n this._value = this._shallow ? newVal : toReactive(newVal);\r\n triggerRefValue(this, newVal);\r\n }\r\n }\r\n}\r\nfunction triggerRef(ref) {\r\n triggerRefValue(ref, (process.env.NODE_ENV !== 'production') ? ref.value : void 0);\r\n}\r\nfunction unref(ref) {\r\n return isRef(ref) ? ref.value : ref;\r\n}\r\nconst shallowUnwrapHandlers = {\r\n get: (target, key, receiver) => unref(Reflect.get(target, key, receiver)),\r\n set: (target, key, value, receiver) => {\r\n const oldValue = target[key];\r\n if (isRef(oldValue) && !isRef(value)) {\r\n oldValue.value = value;\r\n return true;\r\n }\r\n else {\r\n return Reflect.set(target, key, value, receiver);\r\n }\r\n }\r\n};\r\nfunction proxyRefs(objectWithRefs) {\r\n return isReactive(objectWithRefs)\r\n ? objectWithRefs\r\n : new Proxy(objectWithRefs, shallowUnwrapHandlers);\r\n}\r\nclass CustomRefImpl {\r\n constructor(factory) {\r\n this.dep = undefined;\r\n this.__v_isRef = true;\r\n const { get, set } = factory(() => trackRefValue(this), () => triggerRefValue(this));\r\n this._get = get;\r\n this._set = set;\r\n }\r\n get value() {\r\n return this._get();\r\n }\r\n set value(newVal) {\r\n this._set(newVal);\r\n }\r\n}\r\nfunction customRef(factory) {\r\n return new CustomRefImpl(factory);\r\n}\r\nfunction toRefs(object) {\r\n if ((process.env.NODE_ENV !== 'production') && !isProxy(object)) {\r\n console.warn(`toRefs() expects a reactive object but received a plain one.`);\r\n }\r\n const ret = isArray(object) ? new Array(object.length) : {};\r\n for (const key in object) {\r\n ret[key] = toRef(object, key);\r\n }\r\n return ret;\r\n}\r\nclass ObjectRefImpl {\r\n constructor(_object, _key, _defaultValue) {\r\n this._object = _object;\r\n this._key = _key;\r\n this._defaultValue = _defaultValue;\r\n this.__v_isRef = true;\r\n }\r\n get value() {\r\n const val = this._object[this._key];\r\n return val === undefined ? this._defaultValue : val;\r\n }\r\n set value(newVal) {\r\n this._object[this._key] = newVal;\r\n }\r\n}\r\nfunction toRef(object, key, defaultValue) {\r\n const val = object[key];\r\n return isRef(val)\r\n ? val\r\n : new ObjectRefImpl(object, key, defaultValue);\r\n}\n\nclass ComputedRefImpl {\r\n constructor(getter, _setter, isReadonly) {\r\n this._setter = _setter;\r\n this.dep = undefined;\r\n this._dirty = true;\r\n this.__v_isRef = true;\r\n this.effect = new ReactiveEffect(getter, () => {\r\n if (!this._dirty) {\r\n this._dirty = true;\r\n triggerRefValue(this);\r\n }\r\n });\r\n this[\"__v_isReadonly\" /* IS_READONLY */] = isReadonly;\r\n }\r\n get value() {\r\n // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n const self = toRaw(this);\r\n trackRefValue(self);\r\n if (self._dirty) {\r\n self._dirty = false;\r\n self._value = self.effect.run();\r\n }\r\n return self._value;\r\n }\r\n set value(newValue) {\r\n this._setter(newValue);\r\n }\r\n}\r\nfunction computed(getterOrOptions, debugOptions) {\r\n let getter;\r\n let setter;\r\n const onlyGetter = isFunction(getterOrOptions);\r\n if (onlyGetter) {\r\n getter = getterOrOptions;\r\n setter = (process.env.NODE_ENV !== 'production')\r\n ? () => {\r\n console.warn('Write operation failed: computed value is readonly');\r\n }\r\n : NOOP;\r\n }\r\n else {\r\n getter = getterOrOptions.get;\r\n setter = getterOrOptions.set;\r\n }\r\n const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter);\r\n if ((process.env.NODE_ENV !== 'production') && debugOptions) {\r\n cRef.effect.onTrack = debugOptions.onTrack;\r\n cRef.effect.onTrigger = debugOptions.onTrigger;\r\n }\r\n return cRef;\r\n}\n\nvar _a;\r\nconst tick = Promise.resolve();\r\nconst queue = [];\r\nlet queued = false;\r\nconst scheduler = (fn) => {\r\n queue.push(fn);\r\n if (!queued) {\r\n queued = true;\r\n tick.then(flush);\r\n }\r\n};\r\nconst flush = () => {\r\n for (let i = 0; i < queue.length; i++) {\r\n queue[i]();\r\n }\r\n queue.length = 0;\r\n queued = false;\r\n};\r\nclass DeferredComputedRefImpl {\r\n constructor(getter) {\r\n this.dep = undefined;\r\n this._dirty = true;\r\n this.__v_isRef = true;\r\n this[_a] = true;\r\n let compareTarget;\r\n let hasCompareTarget = false;\r\n let scheduled = false;\r\n this.effect = new ReactiveEffect(getter, (computedTrigger) => {\r\n if (this.dep) {\r\n if (computedTrigger) {\r\n compareTarget = this._value;\r\n hasCompareTarget = true;\r\n }\r\n else if (!scheduled) {\r\n const valueToCompare = hasCompareTarget ? compareTarget : this._value;\r\n scheduled = true;\r\n hasCompareTarget = false;\r\n scheduler(() => {\r\n if (this.effect.active && this._get() !== valueToCompare) {\r\n triggerRefValue(this);\r\n }\r\n scheduled = false;\r\n });\r\n }\r\n // chained upstream computeds are notified synchronously to ensure\r\n // value invalidation in case of sync access; normal effects are\r\n // deferred to be triggered in scheduler.\r\n for (const e of this.dep) {\r\n if (e.computed) {\r\n e.scheduler(true /* computedTrigger */);\r\n }\r\n }\r\n }\r\n this._dirty = true;\r\n });\r\n this.effect.computed = true;\r\n }\r\n _get() {\r\n if (this._dirty) {\r\n this._dirty = false;\r\n return (this._value = this.effect.run());\r\n }\r\n return this._value;\r\n }\r\n get value() {\r\n trackRefValue(this);\r\n // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n return toRaw(this)._get();\r\n }\r\n}\r\n_a = \"__v_isReadonly\" /* IS_READONLY */;\r\nfunction deferredComputed(getter) {\r\n return new DeferredComputedRefImpl(getter);\r\n}\n\nexport { EffectScope, ITERATE_KEY, ReactiveEffect, computed, customRef, deferredComputed, effect, effectScope, enableTracking, getCurrentScope, isProxy, isReactive, isReadonly, isRef, markRaw, onScopeDispose, pauseTracking, proxyRefs, reactive, readonly, ref, resetTracking, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, track, trigger, triggerRef, unref };\n","import { toRaw, ref, pauseTracking, resetTracking, reactive, computed, isRef, shallowReactive, trigger, ReactiveEffect, isProxy, shallowReadonly, track, EffectScope, markRaw, proxyRefs, isReactive, isReadonly } from '@vue/reactivity';\nexport { EffectScope, ReactiveEffect, computed, customRef, effect, effectScope, getCurrentScope, isProxy, isReactive, isReadonly, isRef, markRaw, onScopeDispose, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, triggerRef, unref } from '@vue/reactivity';\nimport { getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, isFunction, toNumber, hyphenate, camelize, isArray, isOn, hasOwn, isModelListener, isObject, remove, isString, invokeArrayFns, isPromise, NOOP, def, isReservedProp, EMPTY_ARR, capitalize, toRawType, makeMap, NO, normalizeClass, normalizeStyle, isGloballyWhitelisted, hasChanged, isSet, isMap, isPlainObject } from '@vue/shared';\nexport { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';\n\n/* eslint-disable no-restricted-globals */\r\nlet isHmrUpdating = false;\r\nconst hmrDirtyComponents = new Set();\r\n// Expose the HMR runtime on the global object\r\n// This makes it entirely tree-shakable without polluting the exports and makes\r\n// it easier to be used in toolings like vue-loader\r\n// Note: for a component to be eligible for HMR it also needs the __hmrId option\r\n// to be set so that its instances can be registered / removed.\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n getGlobalThis().__VUE_HMR_RUNTIME__ = {\r\n createRecord: tryWrap(createRecord),\r\n rerender: tryWrap(rerender),\r\n reload: tryWrap(reload)\r\n };\r\n}\r\nconst map = new Map();\r\nfunction registerHMR(instance) {\r\n const id = instance.type.__hmrId;\r\n let record = map.get(id);\r\n if (!record) {\r\n createRecord(id, instance.type);\r\n record = map.get(id);\r\n }\r\n record.instances.add(instance);\r\n}\r\nfunction unregisterHMR(instance) {\r\n map.get(instance.type.__hmrId).instances.delete(instance);\r\n}\r\nfunction createRecord(id, initialDef) {\r\n if (map.has(id)) {\r\n return false;\r\n }\r\n map.set(id, {\r\n initialDef: normalizeClassComponent(initialDef),\r\n instances: new Set()\r\n });\r\n return true;\r\n}\r\nfunction normalizeClassComponent(component) {\r\n return isClassComponent(component) ? component.__vccOpts : component;\r\n}\r\nfunction rerender(id, newRender) {\r\n const record = map.get(id);\r\n if (!record) {\r\n return;\r\n }\r\n // update initial record (for not-yet-rendered component)\r\n record.initialDef.render = newRender;\r\n [...record.instances].forEach(instance => {\r\n if (newRender) {\r\n instance.render = newRender;\r\n normalizeClassComponent(instance.type).render = newRender;\r\n }\r\n instance.renderCache = [];\r\n // this flag forces child components with slot content to update\r\n isHmrUpdating = true;\r\n instance.update();\r\n isHmrUpdating = false;\r\n });\r\n}\r\nfunction reload(id, newComp) {\r\n const record = map.get(id);\r\n if (!record)\r\n return;\r\n newComp = normalizeClassComponent(newComp);\r\n // update initial def (for not-yet-rendered components)\r\n updateComponentDef(record.initialDef, newComp);\r\n // create a snapshot which avoids the set being mutated during updates\r\n const instances = [...record.instances];\r\n for (const instance of instances) {\r\n const oldComp = normalizeClassComponent(instance.type);\r\n if (!hmrDirtyComponents.has(oldComp)) {\r\n // 1. Update existing comp definition to match new one\r\n if (oldComp !== record.initialDef) {\r\n updateComponentDef(oldComp, newComp);\r\n }\r\n // 2. mark definition dirty. This forces the renderer to replace the\r\n // component on patch.\r\n hmrDirtyComponents.add(oldComp);\r\n }\r\n // 3. invalidate options resolution cache\r\n instance.appContext.optionsCache.delete(instance.type);\r\n // 4. actually update\r\n if (instance.ceReload) {\r\n // custom element\r\n hmrDirtyComponents.add(oldComp);\r\n instance.ceReload(newComp.styles);\r\n hmrDirtyComponents.delete(oldComp);\r\n }\r\n else if (instance.parent) {\r\n // 4. Force the parent instance to re-render. This will cause all updated\r\n // components to be unmounted and re-mounted. Queue the update so that we\r\n // don't end up forcing the same parent to re-render multiple times.\r\n queueJob(instance.parent.update);\r\n // instance is the inner component of an async custom element\r\n // invoke to reset styles\r\n if (instance.parent.type.__asyncLoader &&\r\n instance.parent.ceReload) {\r\n instance.parent.ceReload(newComp.styles);\r\n }\r\n }\r\n else if (instance.appContext.reload) {\r\n // root instance mounted via createApp() has a reload method\r\n instance.appContext.reload();\r\n }\r\n else if (typeof window !== 'undefined') {\r\n // root instance inside tree created via raw render(). Force reload.\r\n window.location.reload();\r\n }\r\n else {\r\n console.warn('[HMR] Root or manually mounted instance modified. Full reload required.');\r\n }\r\n }\r\n // 5. make sure to cleanup dirty hmr components after update\r\n queuePostFlushCb(() => {\r\n for (const instance of instances) {\r\n hmrDirtyComponents.delete(normalizeClassComponent(instance.type));\r\n }\r\n });\r\n}\r\nfunction updateComponentDef(oldComp, newComp) {\r\n extend(oldComp, newComp);\r\n for (const key in oldComp) {\r\n if (key !== '__file' && !(key in newComp)) {\r\n delete oldComp[key];\r\n }\r\n }\r\n}\r\nfunction tryWrap(fn) {\r\n return (id, arg) => {\r\n try {\r\n return fn(id, arg);\r\n }\r\n catch (e) {\r\n console.error(e);\r\n console.warn(`[HMR] Something went wrong during Vue component hot-reload. ` +\r\n `Full reload required.`);\r\n }\r\n };\r\n}\n\nlet devtools;\r\nlet buffer = [];\r\nlet devtoolsNotInstalled = false;\r\nfunction emit(event, ...args) {\r\n if (devtools) {\r\n devtools.emit(event, ...args);\r\n }\r\n else if (!devtoolsNotInstalled) {\r\n buffer.push({ event, args });\r\n }\r\n}\r\nfunction setDevtoolsHook(hook, target) {\r\n var _a, _b;\r\n devtools = hook;\r\n if (devtools) {\r\n devtools.enabled = true;\r\n buffer.forEach(({ event, args }) => devtools.emit(event, ...args));\r\n buffer = [];\r\n }\r\n else if (\r\n // handle late devtools injection - only do this if we are in an actual\r\n // browser environment to avoid the timer handle stalling test runner exit\r\n // (#4815)\r\n // eslint-disable-next-line no-restricted-globals\r\n typeof window !== 'undefined' &&\r\n // some envs mock window but not fully\r\n window.HTMLElement &&\r\n // also exclude jsdom\r\n !((_b = (_a = window.navigator) === null || _a === void 0 ? void 0 : _a.userAgent) === null || _b === void 0 ? void 0 : _b.includes('jsdom'))) {\r\n const replay = (target.__VUE_DEVTOOLS_HOOK_REPLAY__ =\r\n target.__VUE_DEVTOOLS_HOOK_REPLAY__ || []);\r\n replay.push((newHook) => {\r\n setDevtoolsHook(newHook, target);\r\n });\r\n // clear buffer after 3s - the user probably doesn't have devtools installed\r\n // at all, and keeping the buffer will cause memory leaks (#4738)\r\n setTimeout(() => {\r\n if (!devtools) {\r\n target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;\r\n devtoolsNotInstalled = true;\r\n buffer = [];\r\n }\r\n }, 3000);\r\n }\r\n else {\r\n // non-browser env, assume not installed\r\n devtoolsNotInstalled = true;\r\n buffer = [];\r\n }\r\n}\r\nfunction devtoolsInitApp(app, version) {\r\n emit(\"app:init\" /* APP_INIT */, app, version, {\r\n Fragment,\r\n Text,\r\n Comment,\r\n Static\r\n });\r\n}\r\nfunction devtoolsUnmountApp(app) {\r\n emit(\"app:unmount\" /* APP_UNMOUNT */, app);\r\n}\r\nconst devtoolsComponentAdded = /*#__PURE__*/ createDevtoolsComponentHook(\"component:added\" /* COMPONENT_ADDED */);\r\nconst devtoolsComponentUpdated = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:updated\" /* COMPONENT_UPDATED */);\r\nconst devtoolsComponentRemoved = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:removed\" /* COMPONENT_REMOVED */);\r\nfunction createDevtoolsComponentHook(hook) {\r\n return (component) => {\r\n emit(hook, component.appContext.app, component.uid, component.parent ? component.parent.uid : undefined, component);\r\n };\r\n}\r\nconst devtoolsPerfStart = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:start\" /* PERFORMANCE_START */);\r\nconst devtoolsPerfEnd = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:end\" /* PERFORMANCE_END */);\r\nfunction createDevtoolsPerformanceHook(hook) {\r\n return (component, type, time) => {\r\n emit(hook, component.appContext.app, component.uid, component, type, time);\r\n };\r\n}\r\nfunction devtoolsComponentEmit(component, event, params) {\r\n emit(\"component:emit\" /* COMPONENT_EMIT */, component.appContext.app, component, event, params);\r\n}\n\nfunction emit$1(instance, event, ...rawArgs) {\r\n const props = instance.vnode.props || EMPTY_OBJ;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const { emitsOptions, propsOptions: [propsOptions] } = instance;\r\n if (emitsOptions) {\r\n if (!(event in emitsOptions) &&\r\n !(false )) {\r\n if (!propsOptions || !(toHandlerKey(event) in propsOptions)) {\r\n warn(`Component emitted event \"${event}\" but it is neither declared in ` +\r\n `the emits option nor as an \"${toHandlerKey(event)}\" prop.`);\r\n }\r\n }\r\n else {\r\n const validator = emitsOptions[event];\r\n if (isFunction(validator)) {\r\n const isValid = validator(...rawArgs);\r\n if (!isValid) {\r\n warn(`Invalid event arguments: event validation failed for event \"${event}\".`);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n let args = rawArgs;\r\n const isModelListener = event.startsWith('update:');\r\n // for v-model update:xxx events, apply modifiers on args\r\n const modelArg = isModelListener && event.slice(7);\r\n if (modelArg && modelArg in props) {\r\n const modifiersKey = `${modelArg === 'modelValue' ? 'model' : modelArg}Modifiers`;\r\n const { number, trim } = props[modifiersKey] || EMPTY_OBJ;\r\n if (trim) {\r\n args = rawArgs.map(a => a.trim());\r\n }\r\n else if (number) {\r\n args = rawArgs.map(toNumber);\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentEmit(instance, event, args);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const lowerCaseEvent = event.toLowerCase();\r\n if (lowerCaseEvent !== event && props[toHandlerKey(lowerCaseEvent)]) {\r\n warn(`Event \"${lowerCaseEvent}\" is emitted in component ` +\r\n `${formatComponentName(instance, instance.type)} but the handler is registered for \"${event}\". ` +\r\n `Note that HTML attributes are case-insensitive and you cannot use ` +\r\n `v-on to listen to camelCase events when using in-DOM templates. ` +\r\n `You should probably use \"${hyphenate(event)}\" instead of \"${event}\".`);\r\n }\r\n }\r\n let handlerName;\r\n let handler = props[(handlerName = toHandlerKey(event))] ||\r\n // also try camelCase event handler (#2249)\r\n props[(handlerName = toHandlerKey(camelize(event)))];\r\n // for v-model update:xxx events, also trigger kebab-case equivalent\r\n // for props passed via kebab-case\r\n if (!handler && isModelListener) {\r\n handler = props[(handlerName = toHandlerKey(hyphenate(event)))];\r\n }\r\n if (handler) {\r\n callWithAsyncErrorHandling(handler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n }\r\n const onceHandler = props[handlerName + `Once`];\r\n if (onceHandler) {\r\n if (!instance.emitted) {\r\n instance.emitted = {};\r\n }\r\n else if (instance.emitted[handlerName]) {\r\n return;\r\n }\r\n instance.emitted[handlerName] = true;\r\n callWithAsyncErrorHandling(onceHandler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n }\r\n}\r\nfunction normalizeEmitsOptions(comp, appContext, asMixin = false) {\r\n const cache = appContext.emitsCache;\r\n const cached = cache.get(comp);\r\n if (cached !== undefined) {\r\n return cached;\r\n }\r\n const raw = comp.emits;\r\n let normalized = {};\r\n // apply mixin/extends props\r\n let hasExtends = false;\r\n if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n const extendEmits = (raw) => {\r\n const normalizedFromExtend = normalizeEmitsOptions(raw, appContext, true);\r\n if (normalizedFromExtend) {\r\n hasExtends = true;\r\n extend(normalized, normalizedFromExtend);\r\n }\r\n };\r\n if (!asMixin && appContext.mixins.length) {\r\n appContext.mixins.forEach(extendEmits);\r\n }\r\n if (comp.extends) {\r\n extendEmits(comp.extends);\r\n }\r\n if (comp.mixins) {\r\n comp.mixins.forEach(extendEmits);\r\n }\r\n }\r\n if (!raw && !hasExtends) {\r\n cache.set(comp, null);\r\n return null;\r\n }\r\n if (isArray(raw)) {\r\n raw.forEach(key => (normalized[key] = null));\r\n }\r\n else {\r\n extend(normalized, raw);\r\n }\r\n cache.set(comp, normalized);\r\n return normalized;\r\n}\r\n// Check if an incoming prop key is a declared emit event listener.\r\n// e.g. With `emits: { click: null }`, props named `onClick` and `onclick` are\r\n// both considered matched listeners.\r\nfunction isEmitListener(options, key) {\r\n if (!options || !isOn(key)) {\r\n return false;\r\n }\r\n key = key.slice(2).replace(/Once$/, '');\r\n return (hasOwn(options, key[0].toLowerCase() + key.slice(1)) ||\r\n hasOwn(options, hyphenate(key)) ||\r\n hasOwn(options, key));\r\n}\n\n/**\r\n * mark the current rendering instance for asset resolution (e.g.\r\n * resolveComponent, resolveDirective) during render\r\n */\r\nlet currentRenderingInstance = null;\r\nlet currentScopeId = null;\r\n/**\r\n * Note: rendering calls maybe nested. The function returns the parent rendering\r\n * instance if present, which should be restored after the render is done:\r\n *\r\n * ```js\r\n * const prev = setCurrentRenderingInstance(i)\r\n * // ...render\r\n * setCurrentRenderingInstance(prev)\r\n * ```\r\n */\r\nfunction setCurrentRenderingInstance(instance) {\r\n const prev = currentRenderingInstance;\r\n currentRenderingInstance = instance;\r\n currentScopeId = (instance && instance.type.__scopeId) || null;\r\n return prev;\r\n}\r\n/**\r\n * Set scope id when creating hoisted vnodes.\r\n * @private compiler helper\r\n */\r\nfunction pushScopeId(id) {\r\n currentScopeId = id;\r\n}\r\n/**\r\n * Technically we no longer need this after 3.0.8 but we need to keep the same\r\n * API for backwards compat w/ code generated by compilers.\r\n * @private\r\n */\r\nfunction popScopeId() {\r\n currentScopeId = null;\r\n}\r\n/**\r\n * Only for backwards compat\r\n * @private\r\n */\r\nconst withScopeId = (_id) => withCtx;\r\n/**\r\n * Wrap a slot function to memoize current rendering instance\r\n * @private compiler helper\r\n */\r\nfunction withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot // false only\r\n) {\r\n if (!ctx)\r\n return fn;\r\n // already normalized\r\n if (fn._n) {\r\n return fn;\r\n }\r\n const renderFnWithContext = (...args) => {\r\n // If a user calls a compiled slot inside a template expression (#1745), it\r\n // can mess up block tracking, so by default we disable block tracking and\r\n // force bail out when invoking a compiled slot (indicated by the ._d flag).\r\n // This isn't necessary if rendering a compiled `<slot>`, so we flip the\r\n // ._d flag off when invoking the wrapped fn inside `renderSlot`.\r\n if (renderFnWithContext._d) {\r\n setBlockTracking(-1);\r\n }\r\n const prevInstance = setCurrentRenderingInstance(ctx);\r\n const res = fn(...args);\r\n setCurrentRenderingInstance(prevInstance);\r\n if (renderFnWithContext._d) {\r\n setBlockTracking(1);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentUpdated(ctx);\r\n }\r\n return res;\r\n };\r\n // mark normalized to avoid duplicated wrapping\r\n renderFnWithContext._n = true;\r\n // mark this as compiled by default\r\n // this is used in vnode.ts -> normalizeChildren() to set the slot\r\n // rendering flag.\r\n renderFnWithContext._c = true;\r\n // disable block tracking by default\r\n renderFnWithContext._d = true;\r\n return renderFnWithContext;\r\n}\n\n/**\r\n * dev only flag to track whether $attrs was used during render.\r\n * If $attrs was used during render then the warning for failed attrs\r\n * fallthrough can be suppressed.\r\n */\r\nlet accessedAttrs = false;\r\nfunction markAttrsAccessed() {\r\n accessedAttrs = true;\r\n}\r\nfunction renderComponentRoot(instance) {\r\n const { type: Component, vnode, proxy, withProxy, props, propsOptions: [propsOptions], slots, attrs, emit, render, renderCache, data, setupState, ctx, inheritAttrs } = instance;\r\n let result;\r\n let fallthroughAttrs;\r\n const prev = setCurrentRenderingInstance(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n accessedAttrs = false;\r\n }\r\n try {\r\n if (vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */) {\r\n // withProxy is a proxy with a different `has` trap only for\r\n // runtime-compiled render functions using `with` block.\r\n const proxyToUse = withProxy || proxy;\r\n result = normalizeVNode(render.call(proxyToUse, proxyToUse, renderCache, props, setupState, data, ctx));\r\n fallthroughAttrs = attrs;\r\n }\r\n else {\r\n // functional\r\n const render = Component;\r\n // in dev, mark attrs accessed if optional props (attrs === props)\r\n if ((process.env.NODE_ENV !== 'production') && attrs === props) {\r\n markAttrsAccessed();\r\n }\r\n result = normalizeVNode(render.length > 1\r\n ? render(props, (process.env.NODE_ENV !== 'production')\r\n ? {\r\n get attrs() {\r\n markAttrsAccessed();\r\n return attrs;\r\n },\r\n slots,\r\n emit\r\n }\r\n : { attrs, slots, emit })\r\n : render(props, null /* we know it doesn't need it */));\r\n fallthroughAttrs = Component.props\r\n ? attrs\r\n : getFunctionalFallthrough(attrs);\r\n }\r\n }\r\n catch (err) {\r\n blockStack.length = 0;\r\n handleError(err, instance, 1 /* RENDER_FUNCTION */);\r\n result = createVNode(Comment);\r\n }\r\n // attr merging\r\n // in dev mode, comments are preserved, and it's possible for a template\r\n // to have comments along side the root element which makes it a fragment\r\n let root = result;\r\n let setRoot = undefined;\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n result.patchFlag > 0 &&\r\n result.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n [root, setRoot] = getChildRoot(result);\r\n }\r\n if (fallthroughAttrs && inheritAttrs !== false) {\r\n const keys = Object.keys(fallthroughAttrs);\r\n const { shapeFlag } = root;\r\n if (keys.length) {\r\n if (shapeFlag & (1 /* ELEMENT */ | 6 /* COMPONENT */)) {\r\n if (propsOptions && keys.some(isModelListener)) {\r\n // If a v-model listener (onUpdate:xxx) has a corresponding declared\r\n // prop, it indicates this component expects to handle v-model and\r\n // it should not fallthrough.\r\n // related: #1543, #1643, #1989\r\n fallthroughAttrs = filterModelListeners(fallthroughAttrs, propsOptions);\r\n }\r\n root = cloneVNode(root, fallthroughAttrs);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && !accessedAttrs && root.type !== Comment) {\r\n const allAttrs = Object.keys(attrs);\r\n const eventAttrs = [];\r\n const extraAttrs = [];\r\n for (let i = 0, l = allAttrs.length; i < l; i++) {\r\n const key = allAttrs[i];\r\n if (isOn(key)) {\r\n // ignore v-model handlers when they fail to fallthrough\r\n if (!isModelListener(key)) {\r\n // remove `on`, lowercase first letter to reflect event casing\r\n // accurately\r\n eventAttrs.push(key[2].toLowerCase() + key.slice(3));\r\n }\r\n }\r\n else {\r\n extraAttrs.push(key);\r\n }\r\n }\r\n if (extraAttrs.length) {\r\n warn(`Extraneous non-props attributes (` +\r\n `${extraAttrs.join(', ')}) ` +\r\n `were passed to component but could not be automatically inherited ` +\r\n `because component renders fragment or text root nodes.`);\r\n }\r\n if (eventAttrs.length) {\r\n warn(`Extraneous non-emits event listeners (` +\r\n `${eventAttrs.join(', ')}) ` +\r\n `were passed to component but could not be automatically inherited ` +\r\n `because component renders fragment or text root nodes. ` +\r\n `If the listener is intended to be a component custom event listener only, ` +\r\n `declare it using the \"emits\" option.`);\r\n }\r\n }\r\n }\r\n }\r\n // inherit directives\r\n if (vnode.dirs) {\r\n if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n warn(`Runtime directive used on component with non-element root node. ` +\r\n `The directives will not function as intended.`);\r\n }\r\n root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;\r\n }\r\n // inherit transition data\r\n if (vnode.transition) {\r\n if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n warn(`Component inside <Transition> renders non-element root node ` +\r\n `that cannot be animated.`);\r\n }\r\n root.transition = vnode.transition;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && setRoot) {\r\n setRoot(root);\r\n }\r\n else {\r\n result = root;\r\n }\r\n setCurrentRenderingInstance(prev);\r\n return result;\r\n}\r\n/**\r\n * dev only\r\n * In dev mode, template root level comments are rendered, which turns the\r\n * template into a fragment root, but we need to locate the single element\r\n * root for attrs and scope id processing.\r\n */\r\nconst getChildRoot = (vnode) => {\r\n const rawChildren = vnode.children;\r\n const dynamicChildren = vnode.dynamicChildren;\r\n const childRoot = filterSingleRoot(rawChildren);\r\n if (!childRoot) {\r\n return [vnode, undefined];\r\n }\r\n const index = rawChildren.indexOf(childRoot);\r\n const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;\r\n const setRoot = (updatedRoot) => {\r\n rawChildren[index] = updatedRoot;\r\n if (dynamicChildren) {\r\n if (dynamicIndex > -1) {\r\n dynamicChildren[dynamicIndex] = updatedRoot;\r\n }\r\n else if (updatedRoot.patchFlag > 0) {\r\n vnode.dynamicChildren = [...dynamicChildren, updatedRoot];\r\n }\r\n }\r\n };\r\n return [normalizeVNode(childRoot), setRoot];\r\n};\r\nfunction filterSingleRoot(children) {\r\n let singleRoot;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isVNode(child)) {\r\n // ignore user comment\r\n if (child.type !== Comment || child.children === 'v-if') {\r\n if (singleRoot) {\r\n // has more than 1 non-comment child, return now\r\n return;\r\n }\r\n else {\r\n singleRoot = child;\r\n }\r\n }\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n return singleRoot;\r\n}\r\nconst getFunctionalFallthrough = (attrs) => {\r\n let res;\r\n for (const key in attrs) {\r\n if (key === 'class' || key === 'style' || isOn(key)) {\r\n (res || (res = {}))[key] = attrs[key];\r\n }\r\n }\r\n return res;\r\n};\r\nconst filterModelListeners = (attrs, props) => {\r\n const res = {};\r\n for (const key in attrs) {\r\n if (!isModelListener(key) || !(key.slice(9) in props)) {\r\n res[key] = attrs[key];\r\n }\r\n }\r\n return res;\r\n};\r\nconst isElementRoot = (vnode) => {\r\n return (vnode.shapeFlag & (6 /* COMPONENT */ | 1 /* ELEMENT */) ||\r\n vnode.type === Comment // potential v-if branch switch\r\n );\r\n};\r\nfunction shouldUpdateComponent(prevVNode, nextVNode, optimized) {\r\n const { props: prevProps, children: prevChildren, component } = prevVNode;\r\n const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;\r\n const emits = component.emitsOptions;\r\n // Parent component's render function was hot-updated. Since this may have\r\n // caused the child component's slots content to have changed, we need to\r\n // force the child to update as well.\r\n if ((process.env.NODE_ENV !== 'production') && (prevChildren || nextChildren) && isHmrUpdating) {\r\n return true;\r\n }\r\n // force child update for runtime directive or transition on component vnode.\r\n if (nextVNode.dirs || nextVNode.transition) {\r\n return true;\r\n }\r\n if (optimized && patchFlag >= 0) {\r\n if (patchFlag & 1024 /* DYNAMIC_SLOTS */) {\r\n // slot content that references values that might have changed,\r\n // e.g. in a v-for\r\n return true;\r\n }\r\n if (patchFlag & 16 /* FULL_PROPS */) {\r\n if (!prevProps) {\r\n return !!nextProps;\r\n }\r\n // presence of this flag indicates props are always non-null\r\n return hasPropsChanged(prevProps, nextProps, emits);\r\n }\r\n else if (patchFlag & 8 /* PROPS */) {\r\n const dynamicProps = nextVNode.dynamicProps;\r\n for (let i = 0; i < dynamicProps.length; i++) {\r\n const key = dynamicProps[i];\r\n if (nextProps[key] !== prevProps[key] &&\r\n !isEmitListener(emits, key)) {\r\n return true;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // this path is only taken by manually written render functions\r\n // so presence of any children leads to a forced update\r\n if (prevChildren || nextChildren) {\r\n if (!nextChildren || !nextChildren.$stable) {\r\n return true;\r\n }\r\n }\r\n if (prevProps === nextProps) {\r\n return false;\r\n }\r\n if (!prevProps) {\r\n return !!nextProps;\r\n }\r\n if (!nextProps) {\r\n return true;\r\n }\r\n return hasPropsChanged(prevProps, nextProps, emits);\r\n }\r\n return false;\r\n}\r\nfunction hasPropsChanged(prevProps, nextProps, emitsOptions) {\r\n const nextKeys = Object.keys(nextProps);\r\n if (nextKeys.length !== Object.keys(prevProps).length) {\r\n return true;\r\n }\r\n for (let i = 0; i < nextKeys.length; i++) {\r\n const key = nextKeys[i];\r\n if (nextProps[key] !== prevProps[key] &&\r\n !isEmitListener(emitsOptions, key)) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}\r\nfunction updateHOCHostEl({ vnode, parent }, el // HostNode\r\n) {\r\n while (parent && parent.subTree === vnode) {\r\n (vnode = parent.vnode).el = el;\r\n parent = parent.parent;\r\n }\r\n}\n\nconst isSuspense = (type) => type.__isSuspense;\r\n// Suspense exposes a component-like API, and is treated like a component\r\n// in the compiler, but internally it's a special built-in type that hooks\r\n// directly into the renderer.\r\nconst SuspenseImpl = {\r\n name: 'Suspense',\r\n // In order to make Suspense tree-shakable, we need to avoid importing it\r\n // directly in the renderer. The renderer checks for the __isSuspense flag\r\n // on a vnode's type and calls the `process` method, passing in renderer\r\n // internals.\r\n __isSuspense: true,\r\n process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, \r\n // platform-specific impl passed from renderer\r\n rendererInternals) {\r\n if (n1 == null) {\r\n mountSuspense(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals);\r\n }\r\n else {\r\n patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, rendererInternals);\r\n }\r\n },\r\n hydrate: hydrateSuspense,\r\n create: createSuspenseBoundary,\r\n normalize: normalizeSuspenseChildren\r\n};\r\n// Force-casted public typing for h and TSX props inference\r\nconst Suspense = (SuspenseImpl );\r\nfunction triggerEvent(vnode, name) {\r\n const eventListener = vnode.props && vnode.props[name];\r\n if (isFunction(eventListener)) {\r\n eventListener();\r\n }\r\n}\r\nfunction mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) {\r\n const { p: patch, o: { createElement } } = rendererInternals;\r\n const hiddenContainer = createElement('div');\r\n const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals));\r\n // start mounting the content subtree in an off-dom container\r\n patch(null, (suspense.pendingBranch = vnode.ssContent), hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds);\r\n // now check if we have encountered any async deps\r\n if (suspense.deps > 0) {\r\n // has async\r\n // invoke @fallback event\r\n triggerEvent(vnode, 'onPending');\r\n triggerEvent(vnode, 'onFallback');\r\n // mount the fallback tree\r\n patch(null, vnode.ssFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds);\r\n setActiveBranch(suspense, vnode.ssFallback);\r\n }\r\n else {\r\n // Suspense has no async deps. Just resolve.\r\n suspense.resolve();\r\n }\r\n}\r\nfunction patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) {\r\n const suspense = (n2.suspense = n1.suspense);\r\n suspense.vnode = n2;\r\n n2.el = n1.el;\r\n const newBranch = n2.ssContent;\r\n const newFallback = n2.ssFallback;\r\n const { activeBranch, pendingBranch, isInFallback, isHydrating } = suspense;\r\n if (pendingBranch) {\r\n suspense.pendingBranch = newBranch;\r\n if (isSameVNodeType(newBranch, pendingBranch)) {\r\n // same root type but content may have changed.\r\n patch(pendingBranch, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n else if (isInFallback) {\r\n patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newFallback);\r\n }\r\n }\r\n else {\r\n // toggled before pending tree is resolved\r\n suspense.pendingId++;\r\n if (isHydrating) {\r\n // if toggled before hydration is finished, the current DOM tree is\r\n // no longer valid. set it as the active branch so it will be unmounted\r\n // when resolved\r\n suspense.isHydrating = false;\r\n suspense.activeBranch = pendingBranch;\r\n }\r\n else {\r\n unmount(pendingBranch, parentComponent, suspense);\r\n }\r\n // increment pending ID. this is used to invalidate async callbacks\r\n // reset suspense state\r\n suspense.deps = 0;\r\n // discard effects from pending branch\r\n suspense.effects.length = 0;\r\n // discard previous container\r\n suspense.hiddenContainer = createElement('div');\r\n if (isInFallback) {\r\n // already in fallback state\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n else {\r\n patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newFallback);\r\n }\r\n }\r\n else if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n // toggled \"back\" to current active branch\r\n patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n // force resolve\r\n suspense.resolve(true);\r\n }\r\n else {\r\n // switched to a 3rd branch\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n // root did not change, just normal patch\r\n patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newBranch);\r\n }\r\n else {\r\n // root node toggled\r\n // invoke @pending event\r\n triggerEvent(n2, 'onPending');\r\n // mount pending branch in off-dom container\r\n suspense.pendingBranch = newBranch;\r\n suspense.pendingId++;\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n // incoming branch has no async deps, resolve now.\r\n suspense.resolve();\r\n }\r\n else {\r\n const { timeout, pendingId } = suspense;\r\n if (timeout > 0) {\r\n setTimeout(() => {\r\n if (suspense.pendingId === pendingId) {\r\n suspense.fallback(newFallback);\r\n }\r\n }, timeout);\r\n }\r\n else if (timeout === 0) {\r\n suspense.fallback(newFallback);\r\n }\r\n }\r\n }\r\n }\r\n}\r\nlet hasWarned = false;\r\nfunction createSuspenseBoundary(vnode, parent, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals, isHydrating = false) {\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production') && !false && !hasWarned) {\r\n hasWarned = true;\r\n // @ts-ignore `console.info` cannot be null error\r\n console[console.info ? 'info' : 'log'](`<Suspense> is an experimental feature and its API will likely change.`);\r\n }\r\n const { p: patch, m: move, um: unmount, n: next, o: { parentNode, remove } } = rendererInternals;\r\n const timeout = toNumber(vnode.props && vnode.props.timeout);\r\n const suspense = {\r\n vnode,\r\n parent,\r\n parentComponent,\r\n isSVG,\r\n container,\r\n hiddenContainer,\r\n anchor,\r\n deps: 0,\r\n pendingId: 0,\r\n timeout: typeof timeout === 'number' ? timeout : -1,\r\n activeBranch: null,\r\n pendingBranch: null,\r\n isInFallback: true,\r\n isHydrating,\r\n isUnmounted: false,\r\n effects: [],\r\n resolve(resume = false) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!resume && !suspense.pendingBranch) {\r\n throw new Error(`suspense.resolve() is called without a pending branch.`);\r\n }\r\n if (suspense.isUnmounted) {\r\n throw new Error(`suspense.resolve() is called on an already unmounted suspense boundary.`);\r\n }\r\n }\r\n const { vnode, activeBranch, pendingBranch, pendingId, effects, parentComponent, container } = suspense;\r\n if (suspense.isHydrating) {\r\n suspense.isHydrating = false;\r\n }\r\n else if (!resume) {\r\n const delayEnter = activeBranch &&\r\n pendingBranch.transition &&\r\n pendingBranch.transition.mode === 'out-in';\r\n if (delayEnter) {\r\n activeBranch.transition.afterLeave = () => {\r\n if (pendingId === suspense.pendingId) {\r\n move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n }\r\n };\r\n }\r\n // this is initial anchor on mount\r\n let { anchor } = suspense;\r\n // unmount current active tree\r\n if (activeBranch) {\r\n // if the fallback tree was mounted, it may have been moved\r\n // as part of a parent suspense. get the latest anchor for insertion\r\n anchor = next(activeBranch);\r\n unmount(activeBranch, parentComponent, suspense, true);\r\n }\r\n if (!delayEnter) {\r\n // move content from off-dom container to actual container\r\n move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n }\r\n }\r\n setActiveBranch(suspense, pendingBranch);\r\n suspense.pendingBranch = null;\r\n suspense.isInFallback = false;\r\n // flush buffered effects\r\n // check if there is a pending parent suspense\r\n let parent = suspense.parent;\r\n let hasUnresolvedAncestor = false;\r\n while (parent) {\r\n if (parent.pendingBranch) {\r\n // found a pending parent suspense, merge buffered post jobs\r\n // into that parent\r\n parent.effects.push(...effects);\r\n hasUnresolvedAncestor = true;\r\n break;\r\n }\r\n parent = parent.parent;\r\n }\r\n // no pending parent suspense, flush all jobs\r\n if (!hasUnresolvedAncestor) {\r\n queuePostFlushCb(effects);\r\n }\r\n suspense.effects = [];\r\n // invoke @resolve event\r\n triggerEvent(vnode, 'onResolve');\r\n },\r\n fallback(fallbackVNode) {\r\n if (!suspense.pendingBranch) {\r\n return;\r\n }\r\n const { vnode, activeBranch, parentComponent, container, isSVG } = suspense;\r\n // invoke @fallback event\r\n triggerEvent(vnode, 'onFallback');\r\n const anchor = next(activeBranch);\r\n const mountFallback = () => {\r\n if (!suspense.isInFallback) {\r\n return;\r\n }\r\n // mount the fallback tree\r\n patch(null, fallbackVNode, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, fallbackVNode);\r\n };\r\n const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === 'out-in';\r\n if (delayEnter) {\r\n activeBranch.transition.afterLeave = mountFallback;\r\n }\r\n suspense.isInFallback = true;\r\n // unmount current active branch\r\n unmount(activeBranch, parentComponent, null, // no suspense so unmount hooks fire now\r\n true // shouldRemove\r\n );\r\n if (!delayEnter) {\r\n mountFallback();\r\n }\r\n },\r\n move(container, anchor, type) {\r\n suspense.activeBranch &&\r\n move(suspense.activeBranch, container, anchor, type);\r\n suspense.container = container;\r\n },\r\n next() {\r\n return suspense.activeBranch && next(suspense.activeBranch);\r\n },\r\n registerDep(instance, setupRenderEffect) {\r\n const isInPendingSuspense = !!suspense.pendingBranch;\r\n if (isInPendingSuspense) {\r\n suspense.deps++;\r\n }\r\n const hydratedEl = instance.vnode.el;\r\n instance\r\n .asyncDep.catch(err => {\r\n handleError(err, instance, 0 /* SETUP_FUNCTION */);\r\n })\r\n .then(asyncSetupResult => {\r\n // retry when the setup() promise resolves.\r\n // component may have been unmounted before resolve.\r\n if (instance.isUnmounted ||\r\n suspense.isUnmounted ||\r\n suspense.pendingId !== instance.suspenseId) {\r\n return;\r\n }\r\n // retry from this component\r\n instance.asyncResolved = true;\r\n const { vnode } = instance;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(vnode);\r\n }\r\n handleSetupResult(instance, asyncSetupResult, false);\r\n if (hydratedEl) {\r\n // vnode may have been replaced if an update happened before the\r\n // async dep is resolved.\r\n vnode.el = hydratedEl;\r\n }\r\n const placeholder = !hydratedEl && instance.subTree.el;\r\n setupRenderEffect(instance, vnode, \r\n // component may have been moved before resolve.\r\n // if this is not a hydration, instance.subTree will be the comment\r\n // placeholder.\r\n parentNode(hydratedEl || instance.subTree.el), \r\n // anchor will not be used if this is hydration, so only need to\r\n // consider the comment placeholder case.\r\n hydratedEl ? null : next(instance.subTree), suspense, isSVG, optimized);\r\n if (placeholder) {\r\n remove(placeholder);\r\n }\r\n updateHOCHostEl(instance, vnode.el);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n // only decrease deps count if suspense is not already resolved\r\n if (isInPendingSuspense && --suspense.deps === 0) {\r\n suspense.resolve();\r\n }\r\n });\r\n },\r\n unmount(parentSuspense, doRemove) {\r\n suspense.isUnmounted = true;\r\n if (suspense.activeBranch) {\r\n unmount(suspense.activeBranch, parentComponent, parentSuspense, doRemove);\r\n }\r\n if (suspense.pendingBranch) {\r\n unmount(suspense.pendingBranch, parentComponent, parentSuspense, doRemove);\r\n }\r\n }\r\n };\r\n return suspense;\r\n}\r\nfunction hydrateSuspense(node, vnode, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals, hydrateNode) {\r\n /* eslint-disable no-restricted-globals */\r\n const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, node.parentNode, document.createElement('div'), null, isSVG, slotScopeIds, optimized, rendererInternals, true /* hydrating */));\r\n // there are two possible scenarios for server-rendered suspense:\r\n // - success: ssr content should be fully resolved\r\n // - failure: ssr content should be the fallback branch.\r\n // however, on the client we don't really know if it has failed or not\r\n // attempt to hydrate the DOM assuming it has succeeded, but we still\r\n // need to construct a suspense boundary first\r\n const result = hydrateNode(node, (suspense.pendingBranch = vnode.ssContent), parentComponent, suspense, slotScopeIds, optimized);\r\n if (suspense.deps === 0) {\r\n suspense.resolve();\r\n }\r\n return result;\r\n /* eslint-enable no-restricted-globals */\r\n}\r\nfunction normalizeSuspenseChildren(vnode) {\r\n const { shapeFlag, children } = vnode;\r\n const isSlotChildren = shapeFlag & 32 /* SLOTS_CHILDREN */;\r\n vnode.ssContent = normalizeSuspenseSlot(isSlotChildren ? children.default : children);\r\n vnode.ssFallback = isSlotChildren\r\n ? normalizeSuspenseSlot(children.fallback)\r\n : createVNode(Comment);\r\n}\r\nfunction normalizeSuspenseSlot(s) {\r\n let block;\r\n if (isFunction(s)) {\r\n const trackBlock = isBlockTreeEnabled && s._c;\r\n if (trackBlock) {\r\n // disableTracking: false\r\n // allow block tracking for compiled slots\r\n // (see ./componentRenderContext.ts)\r\n s._d = false;\r\n openBlock();\r\n }\r\n s = s();\r\n if (trackBlock) {\r\n s._d = true;\r\n block = currentBlock;\r\n closeBlock();\r\n }\r\n }\r\n if (isArray(s)) {\r\n const singleChild = filterSingleRoot(s);\r\n if ((process.env.NODE_ENV !== 'production') && !singleChild) {\r\n warn(`<Suspense> slots expect a single root node.`);\r\n }\r\n s = singleChild;\r\n }\r\n s = normalizeVNode(s);\r\n if (block && !s.dynamicChildren) {\r\n s.dynamicChildren = block.filter(c => c !== s);\r\n }\r\n return s;\r\n}\r\nfunction queueEffectWithSuspense(fn, suspense) {\r\n if (suspense && suspense.pendingBranch) {\r\n if (isArray(fn)) {\r\n suspense.effects.push(...fn);\r\n }\r\n else {\r\n suspense.effects.push(fn);\r\n }\r\n }\r\n else {\r\n queuePostFlushCb(fn);\r\n }\r\n}\r\nfunction setActiveBranch(suspense, branch) {\r\n suspense.activeBranch = branch;\r\n const { vnode, parentComponent } = suspense;\r\n const el = (vnode.el = branch.el);\r\n // in case suspense is the root node of a component,\r\n // recursively update the HOC el\r\n if (parentComponent && parentComponent.subTree === vnode) {\r\n parentComponent.vnode.el = el;\r\n updateHOCHostEl(parentComponent, el);\r\n }\r\n}\n\nfunction provide(key, value) {\r\n if (!currentInstance) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`provide() can only be used inside setup().`);\r\n }\r\n }\r\n else {\r\n let provides = currentInstance.provides;\r\n // by default an instance inherits its parent's provides object\r\n // but when it needs to provide values of its own, it creates its\r\n // own provides object using parent provides object as prototype.\r\n // this way in `inject` we can simply look up injections from direct\r\n // parent and let the prototype chain do the work.\r\n const parentProvides = currentInstance.parent && currentInstance.parent.provides;\r\n if (parentProvides === provides) {\r\n provides = currentInstance.provides = Object.create(parentProvides);\r\n }\r\n // TS doesn't allow symbol as index type\r\n provides[key] = value;\r\n }\r\n}\r\nfunction inject(key, defaultValue, treatDefaultAsFactory = false) {\r\n // fallback to `currentRenderingInstance` so that this can be called in\r\n // a functional component\r\n const instance = currentInstance || currentRenderingInstance;\r\n if (instance) {\r\n // #2400\r\n // to support `app.use` plugins,\r\n // fallback to appContext's `provides` if the intance is at root\r\n const provides = instance.parent == null\r\n ? instance.vnode.appContext && instance.vnode.appContext.provides\r\n : instance.parent.provides;\r\n if (provides && key in provides) {\r\n // TS doesn't allow symbol as index type\r\n return provides[key];\r\n }\r\n else if (arguments.length > 1) {\r\n return treatDefaultAsFactory && isFunction(defaultValue)\r\n ? defaultValue.call(instance.proxy)\r\n : defaultValue;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`injection \"${String(key)}\" not found.`);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`inject() can only be used inside setup() or functional components.`);\r\n }\r\n}\n\nfunction useTransitionState() {\r\n const state = {\r\n isMounted: false,\r\n isLeaving: false,\r\n isUnmounting: false,\r\n leavingVNodes: new Map()\r\n };\r\n onMounted(() => {\r\n state.isMounted = true;\r\n });\r\n onBeforeUnmount(() => {\r\n state.isUnmounting = true;\r\n });\r\n return state;\r\n}\r\nconst TransitionHookValidator = [Function, Array];\r\nconst BaseTransitionImpl = {\r\n name: `BaseTransition`,\r\n props: {\r\n mode: String,\r\n appear: Boolean,\r\n persisted: Boolean,\r\n // enter\r\n onBeforeEnter: TransitionHookValidator,\r\n onEnter: TransitionHookValidator,\r\n onAfterEnter: TransitionHookValidator,\r\n onEnterCancelled: TransitionHookValidator,\r\n // leave\r\n onBeforeLeave: TransitionHookValidator,\r\n onLeave: TransitionHookValidator,\r\n onAfterLeave: TransitionHookValidator,\r\n onLeaveCancelled: TransitionHookValidator,\r\n // appear\r\n onBeforeAppear: TransitionHookValidator,\r\n onAppear: TransitionHookValidator,\r\n onAfterAppear: TransitionHookValidator,\r\n onAppearCancelled: TransitionHookValidator\r\n },\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n const state = useTransitionState();\r\n let prevTransitionKey;\r\n return () => {\r\n const children = slots.default && getTransitionRawChildren(slots.default(), true);\r\n if (!children || !children.length) {\r\n return;\r\n }\r\n // warn multiple elements\r\n if ((process.env.NODE_ENV !== 'production') && children.length > 1) {\r\n warn('<transition> can only be used on a single element or component. Use ' +\r\n '<transition-group> for lists.');\r\n }\r\n // there's no need to track reactivity for these props so use the raw\r\n // props for a bit better perf\r\n const rawProps = toRaw(props);\r\n const { mode } = rawProps;\r\n // check mode\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n mode &&\r\n mode !== 'in-out' && mode !== 'out-in' && mode !== 'default') {\r\n warn(`invalid <transition> mode: ${mode}`);\r\n }\r\n // at this point children has a guaranteed length of 1.\r\n const child = children[0];\r\n if (state.isLeaving) {\r\n return emptyPlaceholder(child);\r\n }\r\n // in the case of <transition><keep-alive/></transition>, we need to\r\n // compare the type of the kept-alive children.\r\n const innerChild = getKeepAliveChild(child);\r\n if (!innerChild) {\r\n return emptyPlaceholder(child);\r\n }\r\n const enterHooks = resolveTransitionHooks(innerChild, rawProps, state, instance);\r\n setTransitionHooks(innerChild, enterHooks);\r\n const oldChild = instance.subTree;\r\n const oldInnerChild = oldChild && getKeepAliveChild(oldChild);\r\n let transitionKeyChanged = false;\r\n const { getTransitionKey } = innerChild.type;\r\n if (getTransitionKey) {\r\n const key = getTransitionKey();\r\n if (prevTransitionKey === undefined) {\r\n prevTransitionKey = key;\r\n }\r\n else if (key !== prevTransitionKey) {\r\n prevTransitionKey = key;\r\n transitionKeyChanged = true;\r\n }\r\n }\r\n // handle mode\r\n if (oldInnerChild &&\r\n oldInnerChild.type !== Comment &&\r\n (!isSameVNodeType(innerChild, oldInnerChild) || transitionKeyChanged)) {\r\n const leavingHooks = resolveTransitionHooks(oldInnerChild, rawProps, state, instance);\r\n // update old tree's hooks in case of dynamic transition\r\n setTransitionHooks(oldInnerChild, leavingHooks);\r\n // switching between different views\r\n if (mode === 'out-in') {\r\n state.isLeaving = true;\r\n // return placeholder node and queue update when leave finishes\r\n leavingHooks.afterLeave = () => {\r\n state.isLeaving = false;\r\n instance.update();\r\n };\r\n return emptyPlaceholder(child);\r\n }\r\n else if (mode === 'in-out' && innerChild.type !== Comment) {\r\n leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {\r\n const leavingVNodesCache = getLeavingNodesForType(state, oldInnerChild);\r\n leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;\r\n // early removal callback\r\n el._leaveCb = () => {\r\n earlyRemove();\r\n el._leaveCb = undefined;\r\n delete enterHooks.delayedLeave;\r\n };\r\n enterHooks.delayedLeave = delayedLeave;\r\n };\r\n }\r\n }\r\n return child;\r\n };\r\n }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst BaseTransition = BaseTransitionImpl;\r\nfunction getLeavingNodesForType(state, vnode) {\r\n const { leavingVNodes } = state;\r\n let leavingVNodesCache = leavingVNodes.get(vnode.type);\r\n if (!leavingVNodesCache) {\r\n leavingVNodesCache = Object.create(null);\r\n leavingVNodes.set(vnode.type, leavingVNodesCache);\r\n }\r\n return leavingVNodesCache;\r\n}\r\n// The transition hooks are attached to the vnode as vnode.transition\r\n// and will be called at appropriate timing in the renderer.\r\nfunction resolveTransitionHooks(vnode, props, state, instance) {\r\n const { appear, mode, persisted = false, onBeforeEnter, onEnter, onAfterEnter, onEnterCancelled, onBeforeLeave, onLeave, onAfterLeave, onLeaveCancelled, onBeforeAppear, onAppear, onAfterAppear, onAppearCancelled } = props;\r\n const key = String(vnode.key);\r\n const leavingVNodesCache = getLeavingNodesForType(state, vnode);\r\n const callHook = (hook, args) => {\r\n hook &&\r\n callWithAsyncErrorHandling(hook, instance, 9 /* TRANSITION_HOOK */, args);\r\n };\r\n const hooks = {\r\n mode,\r\n persisted,\r\n beforeEnter(el) {\r\n let hook = onBeforeEnter;\r\n if (!state.isMounted) {\r\n if (appear) {\r\n hook = onBeforeAppear || onBeforeEnter;\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n // for same element (v-show)\r\n if (el._leaveCb) {\r\n el._leaveCb(true /* cancelled */);\r\n }\r\n // for toggled element with same key (v-if)\r\n const leavingVNode = leavingVNodesCache[key];\r\n if (leavingVNode &&\r\n isSameVNodeType(vnode, leavingVNode) &&\r\n leavingVNode.el._leaveCb) {\r\n // force early removal (not cancelled)\r\n leavingVNode.el._leaveCb();\r\n }\r\n callHook(hook, [el]);\r\n },\r\n enter(el) {\r\n let hook = onEnter;\r\n let afterHook = onAfterEnter;\r\n let cancelHook = onEnterCancelled;\r\n if (!state.isMounted) {\r\n if (appear) {\r\n hook = onAppear || onEnter;\r\n afterHook = onAfterAppear || onAfterEnter;\r\n cancelHook = onAppearCancelled || onEnterCancelled;\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n let called = false;\r\n const done = (el._enterCb = (cancelled) => {\r\n if (called)\r\n return;\r\n called = true;\r\n if (cancelled) {\r\n callHook(cancelHook, [el]);\r\n }\r\n else {\r\n callHook(afterHook, [el]);\r\n }\r\n if (hooks.delayedLeave) {\r\n hooks.delayedLeave();\r\n }\r\n el._enterCb = undefined;\r\n });\r\n if (hook) {\r\n hook(el, done);\r\n if (hook.length <= 1) {\r\n done();\r\n }\r\n }\r\n else {\r\n done();\r\n }\r\n },\r\n leave(el, remove) {\r\n const key = String(vnode.key);\r\n if (el._enterCb) {\r\n el._enterCb(true /* cancelled */);\r\n }\r\n if (state.isUnmounting) {\r\n return remove();\r\n }\r\n callHook(onBeforeLeave, [el]);\r\n let called = false;\r\n const done = (el._leaveCb = (cancelled) => {\r\n if (called)\r\n return;\r\n called = true;\r\n remove();\r\n if (cancelled) {\r\n callHook(onLeaveCancelled, [el]);\r\n }\r\n else {\r\n callHook(onAfterLeave, [el]);\r\n }\r\n el._leaveCb = undefined;\r\n if (leavingVNodesCache[key] === vnode) {\r\n delete leavingVNodesCache[key];\r\n }\r\n });\r\n leavingVNodesCache[key] = vnode;\r\n if (onLeave) {\r\n onLeave(el, done);\r\n if (onLeave.length <= 1) {\r\n done();\r\n }\r\n }\r\n else {\r\n done();\r\n }\r\n },\r\n clone(vnode) {\r\n return resolveTransitionHooks(vnode, props, state, instance);\r\n }\r\n };\r\n return hooks;\r\n}\r\n// the placeholder really only handles one special case: KeepAlive\r\n// in the case of a KeepAlive in a leave phase we need to return a KeepAlive\r\n// placeholder with empty content to avoid the KeepAlive instance from being\r\n// unmounted.\r\nfunction emptyPlaceholder(vnode) {\r\n if (isKeepAlive(vnode)) {\r\n vnode = cloneVNode(vnode);\r\n vnode.children = null;\r\n return vnode;\r\n }\r\n}\r\nfunction getKeepAliveChild(vnode) {\r\n return isKeepAlive(vnode)\r\n ? vnode.children\r\n ? vnode.children[0]\r\n : undefined\r\n : vnode;\r\n}\r\nfunction setTransitionHooks(vnode, hooks) {\r\n if (vnode.shapeFlag & 6 /* COMPONENT */ && vnode.component) {\r\n setTransitionHooks(vnode.component.subTree, hooks);\r\n }\r\n else if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.ssContent.transition = hooks.clone(vnode.ssContent);\r\n vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);\r\n }\r\n else {\r\n vnode.transition = hooks;\r\n }\r\n}\r\nfunction getTransitionRawChildren(children, keepComment = false) {\r\n let ret = [];\r\n let keyedFragmentCount = 0;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n // handle fragment children case, e.g. v-for\r\n if (child.type === Fragment) {\r\n if (child.patchFlag & 128 /* KEYED_FRAGMENT */)\r\n keyedFragmentCount++;\r\n ret = ret.concat(getTransitionRawChildren(child.children, keepComment));\r\n }\r\n // comment placeholders should be skipped, e.g. v-if\r\n else if (keepComment || child.type !== Comment) {\r\n ret.push(child);\r\n }\r\n }\r\n // #1126 if a transition children list contains multiple sub fragments, these\r\n // fragments will be merged into a flat children array. Since each v-for\r\n // fragment may contain different static bindings inside, we need to de-op\r\n // these children to force full diffs to ensure correct behavior.\r\n if (keyedFragmentCount > 1) {\r\n for (let i = 0; i < ret.length; i++) {\r\n ret[i].patchFlag = -2 /* BAIL */;\r\n }\r\n }\r\n return ret;\r\n}\n\n// implementation, close to no-op\r\nfunction defineComponent(options) {\r\n return isFunction(options) ? { setup: options, name: options.name } : options;\r\n}\n\nconst isAsyncWrapper = (i) => !!i.type.__asyncLoader;\r\nfunction defineAsyncComponent(source) {\r\n if (isFunction(source)) {\r\n source = { loader: source };\r\n }\r\n const { loader, loadingComponent, errorComponent, delay = 200, timeout, // undefined = never times out\r\n suspensible = true, onError: userOnError } = source;\r\n let pendingRequest = null;\r\n let resolvedComp;\r\n let retries = 0;\r\n const retry = () => {\r\n retries++;\r\n pendingRequest = null;\r\n return load();\r\n };\r\n const load = () => {\r\n let thisRequest;\r\n return (pendingRequest ||\r\n (thisRequest = pendingRequest =\r\n loader()\r\n .catch(err => {\r\n err = err instanceof Error ? err : new Error(String(err));\r\n if (userOnError) {\r\n return new Promise((resolve, reject) => {\r\n const userRetry = () => resolve(retry());\r\n const userFail = () => reject(err);\r\n userOnError(err, userRetry, userFail, retries + 1);\r\n });\r\n }\r\n else {\r\n throw err;\r\n }\r\n })\r\n .then((comp) => {\r\n if (thisRequest !== pendingRequest && pendingRequest) {\r\n return pendingRequest;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && !comp) {\r\n warn(`Async component loader resolved to undefined. ` +\r\n `If you are using retry(), make sure to return its return value.`);\r\n }\r\n // interop module default\r\n if (comp &&\r\n (comp.__esModule || comp[Symbol.toStringTag] === 'Module')) {\r\n comp = comp.default;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && comp && !isObject(comp) && !isFunction(comp)) {\r\n throw new Error(`Invalid async component load result: ${comp}`);\r\n }\r\n resolvedComp = comp;\r\n return comp;\r\n })));\r\n };\r\n return defineComponent({\r\n name: 'AsyncComponentWrapper',\r\n __asyncLoader: load,\r\n get __asyncResolved() {\r\n return resolvedComp;\r\n },\r\n setup() {\r\n const instance = currentInstance;\r\n // already resolved\r\n if (resolvedComp) {\r\n return () => createInnerComp(resolvedComp, instance);\r\n }\r\n const onError = (err) => {\r\n pendingRequest = null;\r\n handleError(err, instance, 13 /* ASYNC_COMPONENT_LOADER */, !errorComponent /* do not throw in dev if user provided error component */);\r\n };\r\n // suspense-controlled or SSR.\r\n if ((suspensible && instance.suspense) ||\r\n (isInSSRComponentSetup)) {\r\n return load()\r\n .then(comp => {\r\n return () => createInnerComp(comp, instance);\r\n })\r\n .catch(err => {\r\n onError(err);\r\n return () => errorComponent\r\n ? createVNode(errorComponent, {\r\n error: err\r\n })\r\n : null;\r\n });\r\n }\r\n const loaded = ref(false);\r\n const error = ref();\r\n const delayed = ref(!!delay);\r\n if (delay) {\r\n setTimeout(() => {\r\n delayed.value = false;\r\n }, delay);\r\n }\r\n if (timeout != null) {\r\n setTimeout(() => {\r\n if (!loaded.value && !error.value) {\r\n const err = new Error(`Async component timed out after ${timeout}ms.`);\r\n onError(err);\r\n error.value = err;\r\n }\r\n }, timeout);\r\n }\r\n load()\r\n .then(() => {\r\n loaded.value = true;\r\n if (instance.parent && isKeepAlive(instance.parent.vnode)) {\r\n // parent is keep-alive, force update so the loaded component's\r\n // name is taken into account\r\n queueJob(instance.parent.update);\r\n }\r\n })\r\n .catch(err => {\r\n onError(err);\r\n error.value = err;\r\n });\r\n return () => {\r\n if (loaded.value && resolvedComp) {\r\n return createInnerComp(resolvedComp, instance);\r\n }\r\n else if (error.value && errorComponent) {\r\n return createVNode(errorComponent, {\r\n error: error.value\r\n });\r\n }\r\n else if (loadingComponent && !delayed.value) {\r\n return createVNode(loadingComponent);\r\n }\r\n };\r\n }\r\n });\r\n}\r\nfunction createInnerComp(comp, { vnode: { ref, props, children } }) {\r\n const vnode = createVNode(comp, props, children);\r\n // ensure inner component inherits the async wrapper's ref owner\r\n vnode.ref = ref;\r\n return vnode;\r\n}\n\nconst isKeepAlive = (vnode) => vnode.type.__isKeepAlive;\r\nconst KeepAliveImpl = {\r\n name: `KeepAlive`,\r\n // Marker for special handling inside the renderer. We are not using a ===\r\n // check directly on KeepAlive in the renderer, because importing it directly\r\n // would prevent it from being tree-shaken.\r\n __isKeepAlive: true,\r\n props: {\r\n include: [String, RegExp, Array],\r\n exclude: [String, RegExp, Array],\r\n max: [String, Number]\r\n },\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n // KeepAlive communicates with the instantiated renderer via the\r\n // ctx where the renderer passes in its internals,\r\n // and the KeepAlive instance exposes activate/deactivate implementations.\r\n // The whole point of this is to avoid importing KeepAlive directly in the\r\n // renderer to facilitate tree-shaking.\r\n const sharedContext = instance.ctx;\r\n // if the internal renderer is not registered, it indicates that this is server-side rendering,\r\n // for KeepAlive, we just need to render its children\r\n if (!sharedContext.renderer) {\r\n return slots.default;\r\n }\r\n const cache = new Map();\r\n const keys = new Set();\r\n let current = null;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n instance.__v_cache = cache;\r\n }\r\n const parentSuspense = instance.suspense;\r\n const { renderer: { p: patch, m: move, um: _unmount, o: { createElement } } } = sharedContext;\r\n const storageContainer = createElement('div');\r\n sharedContext.activate = (vnode, container, anchor, isSVG, optimized) => {\r\n const instance = vnode.component;\r\n move(vnode, container, anchor, 0 /* ENTER */, parentSuspense);\r\n // in case props have changed\r\n patch(instance.vnode, vnode, container, anchor, instance, parentSuspense, isSVG, vnode.slotScopeIds, optimized);\r\n queuePostRenderEffect(() => {\r\n instance.isDeactivated = false;\r\n if (instance.a) {\r\n invokeArrayFns(instance.a);\r\n }\r\n const vnodeHook = vnode.props && vnode.props.onVnodeMounted;\r\n if (vnodeHook) {\r\n invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n }\r\n }, parentSuspense);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n // Update components tree\r\n devtoolsComponentAdded(instance);\r\n }\r\n };\r\n sharedContext.deactivate = (vnode) => {\r\n const instance = vnode.component;\r\n move(vnode, storageContainer, null, 1 /* LEAVE */, parentSuspense);\r\n queuePostRenderEffect(() => {\r\n if (instance.da) {\r\n invokeArrayFns(instance.da);\r\n }\r\n const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;\r\n if (vnodeHook) {\r\n invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n }\r\n instance.isDeactivated = true;\r\n }, parentSuspense);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n // Update components tree\r\n devtoolsComponentAdded(instance);\r\n }\r\n };\r\n function unmount(vnode) {\r\n // reset the shapeFlag so it can be properly unmounted\r\n resetShapeFlag(vnode);\r\n _unmount(vnode, instance, parentSuspense);\r\n }\r\n function pruneCache(filter) {\r\n cache.forEach((vnode, key) => {\r\n const name = getComponentName(vnode.type);\r\n if (name && (!filter || !filter(name))) {\r\n pruneCacheEntry(key);\r\n }\r\n });\r\n }\r\n function pruneCacheEntry(key) {\r\n const cached = cache.get(key);\r\n if (!current || cached.type !== current.type) {\r\n unmount(cached);\r\n }\r\n else if (current) {\r\n // current active instance should no longer be kept-alive.\r\n // we can't unmount it now but it might be later, so reset its flag now.\r\n resetShapeFlag(current);\r\n }\r\n cache.delete(key);\r\n keys.delete(key);\r\n }\r\n // prune cache on include/exclude prop change\r\n watch(() => [props.include, props.exclude], ([include, exclude]) => {\r\n include && pruneCache(name => matches(include, name));\r\n exclude && pruneCache(name => !matches(exclude, name));\r\n }, \r\n // prune post-render after `current` has been updated\r\n { flush: 'post', deep: true });\r\n // cache sub tree after render\r\n let pendingCacheKey = null;\r\n const cacheSubtree = () => {\r\n // fix #1621, the pendingCacheKey could be 0\r\n if (pendingCacheKey != null) {\r\n cache.set(pendingCacheKey, getInnerChild(instance.subTree));\r\n }\r\n };\r\n onMounted(cacheSubtree);\r\n onUpdated(cacheSubtree);\r\n onBeforeUnmount(() => {\r\n cache.forEach(cached => {\r\n const { subTree, suspense } = instance;\r\n const vnode = getInnerChild(subTree);\r\n if (cached.type === vnode.type) {\r\n // current instance will be unmounted as part of keep-alive's unmount\r\n resetShapeFlag(vnode);\r\n // but invoke its deactivated hook here\r\n const da = vnode.component.da;\r\n da && queuePostRenderEffect(da, suspense);\r\n return;\r\n }\r\n unmount(cached);\r\n });\r\n });\r\n return () => {\r\n pendingCacheKey = null;\r\n if (!slots.default) {\r\n return null;\r\n }\r\n const children = slots.default();\r\n const rawVNode = children[0];\r\n if (children.length > 1) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`KeepAlive should contain exactly one component child.`);\r\n }\r\n current = null;\r\n return children;\r\n }\r\n else if (!isVNode(rawVNode) ||\r\n (!(rawVNode.shapeFlag & 4 /* STATEFUL_COMPONENT */) &&\r\n !(rawVNode.shapeFlag & 128 /* SUSPENSE */))) {\r\n current = null;\r\n return rawVNode;\r\n }\r\n let vnode = getInnerChild(rawVNode);\r\n const comp = vnode.type;\r\n // for async components, name check should be based in its loaded\r\n // inner component if available\r\n const name = getComponentName(isAsyncWrapper(vnode)\r\n ? vnode.type.__asyncResolved || {}\r\n : comp);\r\n const { include, exclude, max } = props;\r\n if ((include && (!name || !matches(include, name))) ||\r\n (exclude && name && matches(exclude, name))) {\r\n current = vnode;\r\n return rawVNode;\r\n }\r\n const key = vnode.key == null ? comp : vnode.key;\r\n const cachedVNode = cache.get(key);\r\n // clone vnode if it's reused because we are going to mutate it\r\n if (vnode.el) {\r\n vnode = cloneVNode(vnode);\r\n if (rawVNode.shapeFlag & 128 /* SUSPENSE */) {\r\n rawVNode.ssContent = vnode;\r\n }\r\n }\r\n // #1513 it's possible for the returned vnode to be cloned due to attr\r\n // fallthrough or scopeId, so the vnode here may not be the final vnode\r\n // that is mounted. Instead of caching it directly, we store the pending\r\n // key and cache `instance.subTree` (the normalized vnode) in\r\n // beforeMount/beforeUpdate hooks.\r\n pendingCacheKey = key;\r\n if (cachedVNode) {\r\n // copy over mounted state\r\n vnode.el = cachedVNode.el;\r\n vnode.component = cachedVNode.component;\r\n if (vnode.transition) {\r\n // recursively update transition hooks on subTree\r\n setTransitionHooks(vnode, vnode.transition);\r\n }\r\n // avoid vnode being mounted as fresh\r\n vnode.shapeFlag |= 512 /* COMPONENT_KEPT_ALIVE */;\r\n // make this key the freshest\r\n keys.delete(key);\r\n keys.add(key);\r\n }\r\n else {\r\n keys.add(key);\r\n // prune oldest entry\r\n if (max && keys.size > parseInt(max, 10)) {\r\n pruneCacheEntry(keys.values().next().value);\r\n }\r\n }\r\n // avoid vnode being unmounted\r\n vnode.shapeFlag |= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n current = vnode;\r\n return rawVNode;\r\n };\r\n }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst KeepAlive = KeepAliveImpl;\r\nfunction matches(pattern, name) {\r\n if (isArray(pattern)) {\r\n return pattern.some((p) => matches(p, name));\r\n }\r\n else if (isString(pattern)) {\r\n return pattern.split(',').indexOf(name) > -1;\r\n }\r\n else if (pattern.test) {\r\n return pattern.test(name);\r\n }\r\n /* istanbul ignore next */\r\n return false;\r\n}\r\nfunction onActivated(hook, target) {\r\n registerKeepAliveHook(hook, \"a\" /* ACTIVATED */, target);\r\n}\r\nfunction onDeactivated(hook, target) {\r\n registerKeepAliveHook(hook, \"da\" /* DEACTIVATED */, target);\r\n}\r\nfunction registerKeepAliveHook(hook, type, target = currentInstance) {\r\n // cache the deactivate branch check wrapper for injected hooks so the same\r\n // hook can be properly deduped by the scheduler. \"__wdc\" stands for \"with\r\n // deactivation check\".\r\n const wrappedHook = hook.__wdc ||\r\n (hook.__wdc = () => {\r\n // only fire the hook if the target instance is NOT in a deactivated branch.\r\n let current = target;\r\n while (current) {\r\n if (current.isDeactivated) {\r\n return;\r\n }\r\n current = current.parent;\r\n }\r\n return hook();\r\n });\r\n injectHook(type, wrappedHook, target);\r\n // In addition to registering it on the target instance, we walk up the parent\r\n // chain and register it on all ancestor instances that are keep-alive roots.\r\n // This avoids the need to walk the entire component tree when invoking these\r\n // hooks, and more importantly, avoids the need to track child components in\r\n // arrays.\r\n if (target) {\r\n let current = target.parent;\r\n while (current && current.parent) {\r\n if (isKeepAlive(current.parent.vnode)) {\r\n injectToKeepAliveRoot(wrappedHook, type, target, current);\r\n }\r\n current = current.parent;\r\n }\r\n }\r\n}\r\nfunction injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {\r\n // injectHook wraps the original for error handling, so make sure to remove\r\n // the wrapped version.\r\n const injected = injectHook(type, hook, keepAliveRoot, true /* prepend */);\r\n onUnmounted(() => {\r\n remove(keepAliveRoot[type], injected);\r\n }, target);\r\n}\r\nfunction resetShapeFlag(vnode) {\r\n let shapeFlag = vnode.shapeFlag;\r\n if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n shapeFlag -= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n }\r\n if (shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n shapeFlag -= 512 /* COMPONENT_KEPT_ALIVE */;\r\n }\r\n vnode.shapeFlag = shapeFlag;\r\n}\r\nfunction getInnerChild(vnode) {\r\n return vnode.shapeFlag & 128 /* SUSPENSE */ ? vnode.ssContent : vnode;\r\n}\n\nfunction injectHook(type, hook, target = currentInstance, prepend = false) {\r\n if (target) {\r\n const hooks = target[type] || (target[type] = []);\r\n // cache the error handling wrapper for injected hooks so the same hook\r\n // can be properly deduped by the scheduler. \"__weh\" stands for \"with error\r\n // handling\".\r\n const wrappedHook = hook.__weh ||\r\n (hook.__weh = (...args) => {\r\n if (target.isUnmounted) {\r\n return;\r\n }\r\n // disable tracking inside all lifecycle hooks\r\n // since they can potentially be called inside effects.\r\n pauseTracking();\r\n // Set currentInstance during hook invocation.\r\n // This assumes the hook does not synchronously trigger other hooks, which\r\n // can only be false when the user does something really funky.\r\n setCurrentInstance(target);\r\n const res = callWithAsyncErrorHandling(hook, target, type, args);\r\n unsetCurrentInstance();\r\n resetTracking();\r\n return res;\r\n });\r\n if (prepend) {\r\n hooks.unshift(wrappedHook);\r\n }\r\n else {\r\n hooks.push(wrappedHook);\r\n }\r\n return wrappedHook;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n const apiName = toHandlerKey(ErrorTypeStrings[type].replace(/ hook$/, ''));\r\n warn(`${apiName} is called when there is no active component instance to be ` +\r\n `associated with. ` +\r\n `Lifecycle injection APIs can only be used during execution of setup().` +\r\n (` If you are using async setup(), make sure to register lifecycle ` +\r\n `hooks before the first await statement.`\r\n ));\r\n }\r\n}\r\nconst createHook = (lifecycle) => (hook, target = currentInstance) => \r\n// post-create lifecycle registrations are noops during SSR (except for serverPrefetch)\r\n(!isInSSRComponentSetup || lifecycle === \"sp\" /* SERVER_PREFETCH */) &&\r\n injectHook(lifecycle, hook, target);\r\nconst onBeforeMount = createHook(\"bm\" /* BEFORE_MOUNT */);\r\nconst onMounted = createHook(\"m\" /* MOUNTED */);\r\nconst onBeforeUpdate = createHook(\"bu\" /* BEFORE_UPDATE */);\r\nconst onUpdated = createHook(\"u\" /* UPDATED */);\r\nconst onBeforeUnmount = createHook(\"bum\" /* BEFORE_UNMOUNT */);\r\nconst onUnmounted = createHook(\"um\" /* UNMOUNTED */);\r\nconst onServerPrefetch = createHook(\"sp\" /* SERVER_PREFETCH */);\r\nconst onRenderTriggered = createHook(\"rtg\" /* RENDER_TRIGGERED */);\r\nconst onRenderTracked = createHook(\"rtc\" /* RENDER_TRACKED */);\r\nfunction onErrorCaptured(hook, target = currentInstance) {\r\n injectHook(\"ec\" /* ERROR_CAPTURED */, hook, target);\r\n}\n\nfunction createDuplicateChecker() {\r\n const cache = Object.create(null);\r\n return (type, key) => {\r\n if (cache[key]) {\r\n warn(`${type} property \"${key}\" is already defined in ${cache[key]}.`);\r\n }\r\n else {\r\n cache[key] = type;\r\n }\r\n };\r\n}\r\nlet shouldCacheAccess = true;\r\nfunction applyOptions(instance) {\r\n const options = resolveMergedOptions(instance);\r\n const publicThis = instance.proxy;\r\n const ctx = instance.ctx;\r\n // do not cache property access on public proxy during state initialization\r\n shouldCacheAccess = false;\r\n // call beforeCreate first before accessing other options since\r\n // the hook may mutate resolved options (#2791)\r\n if (options.beforeCreate) {\r\n callHook(options.beforeCreate, instance, \"bc\" /* BEFORE_CREATE */);\r\n }\r\n const { \r\n // state\r\n data: dataOptions, computed: computedOptions, methods, watch: watchOptions, provide: provideOptions, inject: injectOptions, \r\n // lifecycle\r\n created, beforeMount, mounted, beforeUpdate, updated, activated, deactivated, beforeDestroy, beforeUnmount, destroyed, unmounted, render, renderTracked, renderTriggered, errorCaptured, serverPrefetch, \r\n // public API\r\n expose, inheritAttrs, \r\n // assets\r\n components, directives, filters } = options;\r\n const checkDuplicateProperties = (process.env.NODE_ENV !== 'production') ? createDuplicateChecker() : null;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const [propsOptions] = instance.propsOptions;\r\n if (propsOptions) {\r\n for (const key in propsOptions) {\r\n checkDuplicateProperties(\"Props\" /* PROPS */, key);\r\n }\r\n }\r\n }\r\n // options initialization order (to be consistent with Vue 2):\r\n // - props (already done outside of this function)\r\n // - inject\r\n // - methods\r\n // - data (deferred since it relies on `this` access)\r\n // - computed\r\n // - watch (deferred since it relies on `this` access)\r\n if (injectOptions) {\r\n resolveInjections(injectOptions, ctx, checkDuplicateProperties, instance.appContext.config.unwrapInjectedRef);\r\n }\r\n if (methods) {\r\n for (const key in methods) {\r\n const methodHandler = methods[key];\r\n if (isFunction(methodHandler)) {\r\n // In dev mode, we use the `createRenderContext` function to define\r\n // methods to the proxy target, and those are read-only but\r\n // reconfigurable, so it needs to be redefined here\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n Object.defineProperty(ctx, key, {\r\n value: methodHandler.bind(publicThis),\r\n configurable: true,\r\n enumerable: true,\r\n writable: true\r\n });\r\n }\r\n else {\r\n ctx[key] = methodHandler.bind(publicThis);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Methods\" /* METHODS */, key);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Method \"${key}\" has type \"${typeof methodHandler}\" in the component definition. ` +\r\n `Did you reference the function correctly?`);\r\n }\r\n }\r\n }\r\n if (dataOptions) {\r\n if ((process.env.NODE_ENV !== 'production') && !isFunction(dataOptions)) {\r\n warn(`The data option must be a function. ` +\r\n `Plain object usage is no longer supported.`);\r\n }\r\n const data = dataOptions.call(publicThis, publicThis);\r\n if ((process.env.NODE_ENV !== 'production') && isPromise(data)) {\r\n warn(`data() returned a Promise - note data() cannot be async; If you ` +\r\n `intend to perform data fetching before component renders, use ` +\r\n `async setup() + <Suspense>.`);\r\n }\r\n if (!isObject(data)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`data() should return an object.`);\r\n }\r\n else {\r\n instance.data = reactive(data);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n for (const key in data) {\r\n checkDuplicateProperties(\"Data\" /* DATA */, key);\r\n // expose data on ctx during dev\r\n if (key[0] !== '$' && key[0] !== '_') {\r\n Object.defineProperty(ctx, key, {\r\n configurable: true,\r\n enumerable: true,\r\n get: () => data[key],\r\n set: NOOP\r\n });\r\n }\r\n }\r\n }\r\n }\r\n }\r\n // state initialization complete at this point - start caching access\r\n shouldCacheAccess = true;\r\n if (computedOptions) {\r\n for (const key in computedOptions) {\r\n const opt = computedOptions[key];\r\n const get = isFunction(opt)\r\n ? opt.bind(publicThis, publicThis)\r\n : isFunction(opt.get)\r\n ? opt.get.bind(publicThis, publicThis)\r\n : NOOP;\r\n if ((process.env.NODE_ENV !== 'production') && get === NOOP) {\r\n warn(`Computed property \"${key}\" has no getter.`);\r\n }\r\n const set = !isFunction(opt) && isFunction(opt.set)\r\n ? opt.set.bind(publicThis)\r\n : (process.env.NODE_ENV !== 'production')\r\n ? () => {\r\n warn(`Write operation failed: computed property \"${key}\" is readonly.`);\r\n }\r\n : NOOP;\r\n const c = computed({\r\n get,\r\n set\r\n });\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => c.value,\r\n set: v => (c.value = v)\r\n });\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Computed\" /* COMPUTED */, key);\r\n }\r\n }\r\n }\r\n if (watchOptions) {\r\n for (const key in watchOptions) {\r\n createWatcher(watchOptions[key], ctx, publicThis, key);\r\n }\r\n }\r\n if (provideOptions) {\r\n const provides = isFunction(provideOptions)\r\n ? provideOptions.call(publicThis)\r\n : provideOptions;\r\n Reflect.ownKeys(provides).forEach(key => {\r\n provide(key, provides[key]);\r\n });\r\n }\r\n if (created) {\r\n callHook(created, instance, \"c\" /* CREATED */);\r\n }\r\n function registerLifecycleHook(register, hook) {\r\n if (isArray(hook)) {\r\n hook.forEach(_hook => register(_hook.bind(publicThis)));\r\n }\r\n else if (hook) {\r\n register(hook.bind(publicThis));\r\n }\r\n }\r\n registerLifecycleHook(onBeforeMount, beforeMount);\r\n registerLifecycleHook(onMounted, mounted);\r\n registerLifecycleHook(onBeforeUpdate, beforeUpdate);\r\n registerLifecycleHook(onUpdated, updated);\r\n registerLifecycleHook(onActivated, activated);\r\n registerLifecycleHook(onDeactivated, deactivated);\r\n registerLifecycleHook(onErrorCaptured, errorCaptured);\r\n registerLifecycleHook(onRenderTracked, renderTracked);\r\n registerLifecycleHook(onRenderTriggered, renderTriggered);\r\n registerLifecycleHook(onBeforeUnmount, beforeUnmount);\r\n registerLifecycleHook(onUnmounted, unmounted);\r\n registerLifecycleHook(onServerPrefetch, serverPrefetch);\r\n if (isArray(expose)) {\r\n if (expose.length) {\r\n const exposed = instance.exposed || (instance.exposed = {});\r\n expose.forEach(key => {\r\n Object.defineProperty(exposed, key, {\r\n get: () => publicThis[key],\r\n set: val => (publicThis[key] = val)\r\n });\r\n });\r\n }\r\n else if (!instance.exposed) {\r\n instance.exposed = {};\r\n }\r\n }\r\n // options that are handled when creating the instance but also need to be\r\n // applied from mixins\r\n if (render && instance.render === NOOP) {\r\n instance.render = render;\r\n }\r\n if (inheritAttrs != null) {\r\n instance.inheritAttrs = inheritAttrs;\r\n }\r\n // asset options.\r\n if (components)\r\n instance.components = components;\r\n if (directives)\r\n instance.directives = directives;\r\n}\r\nfunction resolveInjections(injectOptions, ctx, checkDuplicateProperties = NOOP, unwrapRef = false) {\r\n if (isArray(injectOptions)) {\r\n injectOptions = normalizeInject(injectOptions);\r\n }\r\n for (const key in injectOptions) {\r\n const opt = injectOptions[key];\r\n let injected;\r\n if (isObject(opt)) {\r\n if ('default' in opt) {\r\n injected = inject(opt.from || key, opt.default, true /* treat default function as factory */);\r\n }\r\n else {\r\n injected = inject(opt.from || key);\r\n }\r\n }\r\n else {\r\n injected = inject(opt);\r\n }\r\n if (isRef(injected)) {\r\n // TODO remove the check in 3.3\r\n if (unwrapRef) {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => injected.value,\r\n set: v => (injected.value = v)\r\n });\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`injected property \"${key}\" is a ref and will be auto-unwrapped ` +\r\n `and no longer needs \\`.value\\` in the next minor release. ` +\r\n `To opt-in to the new behavior now, ` +\r\n `set \\`app.config.unwrapInjectedRef = true\\` (this config is ` +\r\n `temporary and will not be needed in the future.)`);\r\n }\r\n ctx[key] = injected;\r\n }\r\n }\r\n else {\r\n ctx[key] = injected;\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Inject\" /* INJECT */, key);\r\n }\r\n }\r\n}\r\nfunction callHook(hook, instance, type) {\r\n callWithAsyncErrorHandling(isArray(hook)\r\n ? hook.map(h => h.bind(instance.proxy))\r\n : hook.bind(instance.proxy), instance, type);\r\n}\r\nfunction createWatcher(raw, ctx, publicThis, key) {\r\n const getter = key.includes('.')\r\n ? createPathGetter(publicThis, key)\r\n : () => publicThis[key];\r\n if (isString(raw)) {\r\n const handler = ctx[raw];\r\n if (isFunction(handler)) {\r\n watch(getter, handler);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch handler specified by key \"${raw}\"`, handler);\r\n }\r\n }\r\n else if (isFunction(raw)) {\r\n watch(getter, raw.bind(publicThis));\r\n }\r\n else if (isObject(raw)) {\r\n if (isArray(raw)) {\r\n raw.forEach(r => createWatcher(r, ctx, publicThis, key));\r\n }\r\n else {\r\n const handler = isFunction(raw.handler)\r\n ? raw.handler.bind(publicThis)\r\n : ctx[raw.handler];\r\n if (isFunction(handler)) {\r\n watch(getter, handler, raw);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch handler specified by key \"${raw.handler}\"`, handler);\r\n }\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch option: \"${key}\"`, raw);\r\n }\r\n}\r\n/**\r\n * Resolve merged options and cache it on the component.\r\n * This is done only once per-component since the merging does not involve\r\n * instances.\r\n */\r\nfunction resolveMergedOptions(instance) {\r\n const base = instance.type;\r\n const { mixins, extends: extendsOptions } = base;\r\n const { mixins: globalMixins, optionsCache: cache, config: { optionMergeStrategies } } = instance.appContext;\r\n const cached = cache.get(base);\r\n let resolved;\r\n if (cached) {\r\n resolved = cached;\r\n }\r\n else if (!globalMixins.length && !mixins && !extendsOptions) {\r\n {\r\n resolved = base;\r\n }\r\n }\r\n else {\r\n resolved = {};\r\n if (globalMixins.length) {\r\n globalMixins.forEach(m => mergeOptions(resolved, m, optionMergeStrategies, true));\r\n }\r\n mergeOptions(resolved, base, optionMergeStrategies);\r\n }\r\n cache.set(base, resolved);\r\n return resolved;\r\n}\r\nfunction mergeOptions(to, from, strats, asMixin = false) {\r\n const { mixins, extends: extendsOptions } = from;\r\n if (extendsOptions) {\r\n mergeOptions(to, extendsOptions, strats, true);\r\n }\r\n if (mixins) {\r\n mixins.forEach((m) => mergeOptions(to, m, strats, true));\r\n }\r\n for (const key in from) {\r\n if (asMixin && key === 'expose') {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`\"expose\" option is ignored when declared in mixins or extends. ` +\r\n `It should only be declared in the base component itself.`);\r\n }\r\n else {\r\n const strat = internalOptionMergeStrats[key] || (strats && strats[key]);\r\n to[key] = strat ? strat(to[key], from[key]) : from[key];\r\n }\r\n }\r\n return to;\r\n}\r\nconst internalOptionMergeStrats = {\r\n data: mergeDataFn,\r\n props: mergeObjectOptions,\r\n emits: mergeObjectOptions,\r\n // objects\r\n methods: mergeObjectOptions,\r\n computed: mergeObjectOptions,\r\n // lifecycle\r\n beforeCreate: mergeAsArray,\r\n created: mergeAsArray,\r\n beforeMount: mergeAsArray,\r\n mounted: mergeAsArray,\r\n beforeUpdate: mergeAsArray,\r\n updated: mergeAsArray,\r\n beforeDestroy: mergeAsArray,\r\n beforeUnmount: mergeAsArray,\r\n destroyed: mergeAsArray,\r\n unmounted: mergeAsArray,\r\n activated: mergeAsArray,\r\n deactivated: mergeAsArray,\r\n errorCaptured: mergeAsArray,\r\n serverPrefetch: mergeAsArray,\r\n // assets\r\n components: mergeObjectOptions,\r\n directives: mergeObjectOptions,\r\n // watch\r\n watch: mergeWatchOptions,\r\n // provide / inject\r\n provide: mergeDataFn,\r\n inject: mergeInject\r\n};\r\nfunction mergeDataFn(to, from) {\r\n if (!from) {\r\n return to;\r\n }\r\n if (!to) {\r\n return from;\r\n }\r\n return function mergedDataFn() {\r\n return (extend)(isFunction(to) ? to.call(this, this) : to, isFunction(from) ? from.call(this, this) : from);\r\n };\r\n}\r\nfunction mergeInject(to, from) {\r\n return mergeObjectOptions(normalizeInject(to), normalizeInject(from));\r\n}\r\nfunction normalizeInject(raw) {\r\n if (isArray(raw)) {\r\n const res = {};\r\n for (let i = 0; i < raw.length; i++) {\r\n res[raw[i]] = raw[i];\r\n }\r\n return res;\r\n }\r\n return raw;\r\n}\r\nfunction mergeAsArray(to, from) {\r\n return to ? [...new Set([].concat(to, from))] : from;\r\n}\r\nfunction mergeObjectOptions(to, from) {\r\n return to ? extend(extend(Object.create(null), to), from) : from;\r\n}\r\nfunction mergeWatchOptions(to, from) {\r\n if (!to)\r\n return from;\r\n if (!from)\r\n return to;\r\n const merged = extend(Object.create(null), to);\r\n for (const key in from) {\r\n merged[key] = mergeAsArray(to[key], from[key]);\r\n }\r\n return merged;\r\n}\n\nfunction initProps(instance, rawProps, isStateful, // result of bitwise flag comparison\r\nisSSR = false) {\r\n const props = {};\r\n const attrs = {};\r\n def(attrs, InternalObjectKey, 1);\r\n instance.propsDefaults = Object.create(null);\r\n setFullProps(instance, rawProps, props, attrs);\r\n // ensure all declared prop keys are present\r\n for (const key in instance.propsOptions[0]) {\r\n if (!(key in props)) {\r\n props[key] = undefined;\r\n }\r\n }\r\n // validation\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateProps(rawProps || {}, props, instance);\r\n }\r\n if (isStateful) {\r\n // stateful\r\n instance.props = isSSR ? props : shallowReactive(props);\r\n }\r\n else {\r\n if (!instance.type.props) {\r\n // functional w/ optional props, props === attrs\r\n instance.props = attrs;\r\n }\r\n else {\r\n // functional w/ declared props\r\n instance.props = props;\r\n }\r\n }\r\n instance.attrs = attrs;\r\n}\r\nfunction updateProps(instance, rawProps, rawPrevProps, optimized) {\r\n const { props, attrs, vnode: { patchFlag } } = instance;\r\n const rawCurrentProps = toRaw(props);\r\n const [options] = instance.propsOptions;\r\n let hasAttrsChanged = false;\r\n if (\r\n // always force full diff in dev\r\n // - #1942 if hmr is enabled with sfc component\r\n // - vite#872 non-sfc component used by sfc component\r\n !((process.env.NODE_ENV !== 'production') &&\r\n (instance.type.__hmrId ||\r\n (instance.parent && instance.parent.type.__hmrId))) &&\r\n (optimized || patchFlag > 0) &&\r\n !(patchFlag & 16 /* FULL_PROPS */)) {\r\n if (patchFlag & 8 /* PROPS */) {\r\n // Compiler-generated props & no keys change, just set the updated\r\n // the props.\r\n const propsToUpdate = instance.vnode.dynamicProps;\r\n for (let i = 0; i < propsToUpdate.length; i++) {\r\n let key = propsToUpdate[i];\r\n // PROPS flag guarantees rawProps to be non-null\r\n const value = rawProps[key];\r\n if (options) {\r\n // attr / props separation was done on init and will be consistent\r\n // in this code path, so just check if attrs have it.\r\n if (hasOwn(attrs, key)) {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n else {\r\n const camelizedKey = camelize(key);\r\n props[camelizedKey] = resolvePropValue(options, rawCurrentProps, camelizedKey, value, instance, false /* isAbsent */);\r\n }\r\n }\r\n else {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // full props update.\r\n if (setFullProps(instance, rawProps, props, attrs)) {\r\n hasAttrsChanged = true;\r\n }\r\n // in case of dynamic props, check if we need to delete keys from\r\n // the props object\r\n let kebabKey;\r\n for (const key in rawCurrentProps) {\r\n if (!rawProps ||\r\n // for camelCase\r\n (!hasOwn(rawProps, key) &&\r\n // it's possible the original props was passed in as kebab-case\r\n // and converted to camelCase (#955)\r\n ((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey)))) {\r\n if (options) {\r\n if (rawPrevProps &&\r\n // for camelCase\r\n (rawPrevProps[key] !== undefined ||\r\n // for kebab-case\r\n rawPrevProps[kebabKey] !== undefined)) {\r\n props[key] = resolvePropValue(options, rawCurrentProps, key, undefined, instance, true /* isAbsent */);\r\n }\r\n }\r\n else {\r\n delete props[key];\r\n }\r\n }\r\n }\r\n // in the case of functional component w/o props declaration, props and\r\n // attrs point to the same object so it should already have been updated.\r\n if (attrs !== rawCurrentProps) {\r\n for (const key in attrs) {\r\n if (!rawProps || !hasOwn(rawProps, key)) {\r\n delete attrs[key];\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n // trigger updates for $attrs in case it's used in component slots\r\n if (hasAttrsChanged) {\r\n trigger(instance, \"set\" /* SET */, '$attrs');\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateProps(rawProps || {}, props, instance);\r\n }\r\n}\r\nfunction setFullProps(instance, rawProps, props, attrs) {\r\n const [options, needCastKeys] = instance.propsOptions;\r\n let hasAttrsChanged = false;\r\n let rawCastValues;\r\n if (rawProps) {\r\n for (let key in rawProps) {\r\n // key, ref are reserved and never passed down\r\n if (isReservedProp(key)) {\r\n continue;\r\n }\r\n const value = rawProps[key];\r\n // prop option names are camelized during normalization, so to support\r\n // kebab -> camel conversion here we need to camelize the key.\r\n let camelKey;\r\n if (options && hasOwn(options, (camelKey = camelize(key)))) {\r\n if (!needCastKeys || !needCastKeys.includes(camelKey)) {\r\n props[camelKey] = value;\r\n }\r\n else {\r\n (rawCastValues || (rawCastValues = {}))[camelKey] = value;\r\n }\r\n }\r\n else if (!isEmitListener(instance.emitsOptions, key)) {\r\n if (!(key in attrs) || value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n if (needCastKeys) {\r\n const rawCurrentProps = toRaw(props);\r\n const castValues = rawCastValues || EMPTY_OBJ;\r\n for (let i = 0; i < needCastKeys.length; i++) {\r\n const key = needCastKeys[i];\r\n props[key] = resolvePropValue(options, rawCurrentProps, key, castValues[key], instance, !hasOwn(castValues, key));\r\n }\r\n }\r\n return hasAttrsChanged;\r\n}\r\nfunction resolvePropValue(options, props, key, value, instance, isAbsent) {\r\n const opt = options[key];\r\n if (opt != null) {\r\n const hasDefault = hasOwn(opt, 'default');\r\n // default values\r\n if (hasDefault && value === undefined) {\r\n const defaultValue = opt.default;\r\n if (opt.type !== Function && isFunction(defaultValue)) {\r\n const { propsDefaults } = instance;\r\n if (key in propsDefaults) {\r\n value = propsDefaults[key];\r\n }\r\n else {\r\n setCurrentInstance(instance);\r\n value = propsDefaults[key] = defaultValue.call(null, props);\r\n unsetCurrentInstance();\r\n }\r\n }\r\n else {\r\n value = defaultValue;\r\n }\r\n }\r\n // boolean casting\r\n if (opt[0 /* shouldCast */]) {\r\n if (isAbsent && !hasDefault) {\r\n value = false;\r\n }\r\n else if (opt[1 /* shouldCastTrue */] &&\r\n (value === '' || value === hyphenate(key))) {\r\n value = true;\r\n }\r\n }\r\n }\r\n return value;\r\n}\r\nfunction normalizePropsOptions(comp, appContext, asMixin = false) {\r\n const cache = appContext.propsCache;\r\n const cached = cache.get(comp);\r\n if (cached) {\r\n return cached;\r\n }\r\n const raw = comp.props;\r\n const normalized = {};\r\n const needCastKeys = [];\r\n // apply mixin/extends props\r\n let hasExtends = false;\r\n if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n const extendProps = (raw) => {\r\n hasExtends = true;\r\n const [props, keys] = normalizePropsOptions(raw, appContext, true);\r\n extend(normalized, props);\r\n if (keys)\r\n needCastKeys.push(...keys);\r\n };\r\n if (!asMixin && appContext.mixins.length) {\r\n appContext.mixins.forEach(extendProps);\r\n }\r\n if (comp.extends) {\r\n extendProps(comp.extends);\r\n }\r\n if (comp.mixins) {\r\n comp.mixins.forEach(extendProps);\r\n }\r\n }\r\n if (!raw && !hasExtends) {\r\n cache.set(comp, EMPTY_ARR);\r\n return EMPTY_ARR;\r\n }\r\n if (isArray(raw)) {\r\n for (let i = 0; i < raw.length; i++) {\r\n if ((process.env.NODE_ENV !== 'production') && !isString(raw[i])) {\r\n warn(`props must be strings when using array syntax.`, raw[i]);\r\n }\r\n const normalizedKey = camelize(raw[i]);\r\n if (validatePropName(normalizedKey)) {\r\n normalized[normalizedKey] = EMPTY_OBJ;\r\n }\r\n }\r\n }\r\n else if (raw) {\r\n if ((process.env.NODE_ENV !== 'production') && !isObject(raw)) {\r\n warn(`invalid props options`, raw);\r\n }\r\n for (const key in raw) {\r\n const normalizedKey = camelize(key);\r\n if (validatePropName(normalizedKey)) {\r\n const opt = raw[key];\r\n const prop = (normalized[normalizedKey] =\r\n isArray(opt) || isFunction(opt) ? { type: opt } : opt);\r\n if (prop) {\r\n const booleanIndex = getTypeIndex(Boolean, prop.type);\r\n const stringIndex = getTypeIndex(String, prop.type);\r\n prop[0 /* shouldCast */] = booleanIndex > -1;\r\n prop[1 /* shouldCastTrue */] =\r\n stringIndex < 0 || booleanIndex < stringIndex;\r\n // if the prop needs boolean casting or default value\r\n if (booleanIndex > -1 || hasOwn(prop, 'default')) {\r\n needCastKeys.push(normalizedKey);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n const res = [normalized, needCastKeys];\r\n cache.set(comp, res);\r\n return res;\r\n}\r\nfunction validatePropName(key) {\r\n if (key[0] !== '$') {\r\n return true;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid prop name: \"${key}\" is a reserved property.`);\r\n }\r\n return false;\r\n}\r\n// use function string name to check type constructors\r\n// so that it works across vms / iframes.\r\nfunction getType(ctor) {\r\n const match = ctor && ctor.toString().match(/^\\s*function (\\w+)/);\r\n return match ? match[1] : ctor === null ? 'null' : '';\r\n}\r\nfunction isSameType(a, b) {\r\n return getType(a) === getType(b);\r\n}\r\nfunction getTypeIndex(type, expectedTypes) {\r\n if (isArray(expectedTypes)) {\r\n return expectedTypes.findIndex(t => isSameType(t, type));\r\n }\r\n else if (isFunction(expectedTypes)) {\r\n return isSameType(expectedTypes, type) ? 0 : -1;\r\n }\r\n return -1;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProps(rawProps, props, instance) {\r\n const resolvedValues = toRaw(props);\r\n const options = instance.propsOptions[0];\r\n for (const key in options) {\r\n let opt = options[key];\r\n if (opt == null)\r\n continue;\r\n validateProp(key, resolvedValues[key], opt, !hasOwn(rawProps, key) && !hasOwn(rawProps, hyphenate(key)));\r\n }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProp(name, value, prop, isAbsent) {\r\n const { type, required, validator } = prop;\r\n // required!\r\n if (required && isAbsent) {\r\n warn('Missing required prop: \"' + name + '\"');\r\n return;\r\n }\r\n // missing but optional\r\n if (value == null && !prop.required) {\r\n return;\r\n }\r\n // type check\r\n if (type != null && type !== true) {\r\n let isValid = false;\r\n const types = isArray(type) ? type : [type];\r\n const expectedTypes = [];\r\n // value is valid as long as one of the specified types match\r\n for (let i = 0; i < types.length && !isValid; i++) {\r\n const { valid, expectedType } = assertType(value, types[i]);\r\n expectedTypes.push(expectedType || '');\r\n isValid = valid;\r\n }\r\n if (!isValid) {\r\n warn(getInvalidTypeMessage(name, value, expectedTypes));\r\n return;\r\n }\r\n }\r\n // custom validator\r\n if (validator && !validator(value)) {\r\n warn('Invalid prop: custom validator check failed for prop \"' + name + '\".');\r\n }\r\n}\r\nconst isSimpleType = /*#__PURE__*/ makeMap('String,Number,Boolean,Function,Symbol,BigInt');\r\n/**\r\n * dev only\r\n */\r\nfunction assertType(value, type) {\r\n let valid;\r\n const expectedType = getType(type);\r\n if (isSimpleType(expectedType)) {\r\n const t = typeof value;\r\n valid = t === expectedType.toLowerCase();\r\n // for primitive wrapper objects\r\n if (!valid && t === 'object') {\r\n valid = value instanceof type;\r\n }\r\n }\r\n else if (expectedType === 'Object') {\r\n valid = isObject(value);\r\n }\r\n else if (expectedType === 'Array') {\r\n valid = isArray(value);\r\n }\r\n else if (expectedType === 'null') {\r\n valid = value === null;\r\n }\r\n else {\r\n valid = value instanceof type;\r\n }\r\n return {\r\n valid,\r\n expectedType\r\n };\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction getInvalidTypeMessage(name, value, expectedTypes) {\r\n let message = `Invalid prop: type check failed for prop \"${name}\".` +\r\n ` Expected ${expectedTypes.map(capitalize).join(' | ')}`;\r\n const expectedType = expectedTypes[0];\r\n const receivedType = toRawType(value);\r\n const expectedValue = styleValue(value, expectedType);\r\n const receivedValue = styleValue(value, receivedType);\r\n // check if we need to specify expected value\r\n if (expectedTypes.length === 1 &&\r\n isExplicable(expectedType) &&\r\n !isBoolean(expectedType, receivedType)) {\r\n message += ` with value ${expectedValue}`;\r\n }\r\n message += `, got ${receivedType} `;\r\n // check if we need to specify received value\r\n if (isExplicable(receivedType)) {\r\n message += `with value ${receivedValue}.`;\r\n }\r\n return message;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction styleValue(value, type) {\r\n if (type === 'String') {\r\n return `\"${value}\"`;\r\n }\r\n else if (type === 'Number') {\r\n return `${Number(value)}`;\r\n }\r\n else {\r\n return `${value}`;\r\n }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isExplicable(type) {\r\n const explicitTypes = ['string', 'number', 'boolean'];\r\n return explicitTypes.some(elem => type.toLowerCase() === elem);\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isBoolean(...args) {\r\n return args.some(elem => elem.toLowerCase() === 'boolean');\r\n}\n\nconst isInternalKey = (key) => key[0] === '_' || key === '$stable';\r\nconst normalizeSlotValue = (value) => isArray(value)\r\n ? value.map(normalizeVNode)\r\n : [normalizeVNode(value)];\r\nconst normalizeSlot = (key, rawSlot, ctx) => {\r\n const normalized = withCtx((...args) => {\r\n if ((process.env.NODE_ENV !== 'production') && currentInstance) {\r\n warn(`Slot \"${key}\" invoked outside of the render function: ` +\r\n `this will not track dependencies used in the slot. ` +\r\n `Invoke the slot function inside the render function instead.`);\r\n }\r\n return normalizeSlotValue(rawSlot(...args));\r\n }, ctx);\r\n normalized._c = false;\r\n return normalized;\r\n};\r\nconst normalizeObjectSlots = (rawSlots, slots, instance) => {\r\n const ctx = rawSlots._ctx;\r\n for (const key in rawSlots) {\r\n if (isInternalKey(key))\r\n continue;\r\n const value = rawSlots[key];\r\n if (isFunction(value)) {\r\n slots[key] = normalizeSlot(key, value, ctx);\r\n }\r\n else if (value != null) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !(false )) {\r\n warn(`Non-function value encountered for slot \"${key}\". ` +\r\n `Prefer function slots for better performance.`);\r\n }\r\n const normalized = normalizeSlotValue(value);\r\n slots[key] = () => normalized;\r\n }\r\n }\r\n};\r\nconst normalizeVNodeSlots = (instance, children) => {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !isKeepAlive(instance.vnode) &&\r\n !(false )) {\r\n warn(`Non-function value encountered for default slot. ` +\r\n `Prefer function slots for better performance.`);\r\n }\r\n const normalized = normalizeSlotValue(children);\r\n instance.slots.default = () => normalized;\r\n};\r\nconst initSlots = (instance, children) => {\r\n if (instance.vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n const type = children._;\r\n if (type) {\r\n // users can get the shallow readonly version of the slots object through `this.$slots`,\r\n // we should avoid the proxy object polluting the slots of the internal instance\r\n instance.slots = toRaw(children);\r\n // make compiler marker non-enumerable\r\n def(children, '_', type);\r\n }\r\n else {\r\n normalizeObjectSlots(children, (instance.slots = {}));\r\n }\r\n }\r\n else {\r\n instance.slots = {};\r\n if (children) {\r\n normalizeVNodeSlots(instance, children);\r\n }\r\n }\r\n def(instance.slots, InternalObjectKey, 1);\r\n};\r\nconst updateSlots = (instance, children, optimized) => {\r\n const { vnode, slots } = instance;\r\n let needDeletionCheck = true;\r\n let deletionComparisonTarget = EMPTY_OBJ;\r\n if (vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n const type = children._;\r\n if (type) {\r\n // compiled slots.\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // Parent was HMR updated so slot content may have changed.\r\n // force update slots and mark instance for hmr as well\r\n extend(slots, children);\r\n }\r\n else if (optimized && type === 1 /* STABLE */) {\r\n // compiled AND stable.\r\n // no need to update, and skip stale slots removal.\r\n needDeletionCheck = false;\r\n }\r\n else {\r\n // compiled but dynamic (v-if/v-for on slots) - update slots, but skip\r\n // normalization.\r\n extend(slots, children);\r\n // #2893\r\n // when rendering the optimized slots by manually written render function,\r\n // we need to delete the `slots._` flag if necessary to make subsequent updates reliable,\r\n // i.e. let the `renderSlot` create the bailed Fragment\r\n if (!optimized && type === 1 /* STABLE */) {\r\n delete slots._;\r\n }\r\n }\r\n }\r\n else {\r\n needDeletionCheck = !children.$stable;\r\n normalizeObjectSlots(children, slots);\r\n }\r\n deletionComparisonTarget = children;\r\n }\r\n else if (children) {\r\n // non slot object children (direct value) passed to a component\r\n normalizeVNodeSlots(instance, children);\r\n deletionComparisonTarget = { default: 1 };\r\n }\r\n // delete stale slots\r\n if (needDeletionCheck) {\r\n for (const key in slots) {\r\n if (!isInternalKey(key) && !(key in deletionComparisonTarget)) {\r\n delete slots[key];\r\n }\r\n }\r\n }\r\n};\n\n/**\r\nRuntime helper for applying directives to a vnode. Example usage:\r\n\nconst comp = resolveComponent('comp')\r\nconst foo = resolveDirective('foo')\r\nconst bar = resolveDirective('bar')\r\n\nreturn withDirectives(h(comp), [\r\n [foo, this.x],\r\n [bar, this.y]\r\n])\r\n*/\r\nconst isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');\r\nfunction validateDirectiveName(name) {\r\n if (isBuiltInDirective(name)) {\r\n warn('Do not use built-in directive ids as custom directive id: ' + name);\r\n }\r\n}\r\n/**\r\n * Adds directives to a VNode.\r\n */\r\nfunction withDirectives(vnode, directives) {\r\n const internalInstance = currentRenderingInstance;\r\n if (internalInstance === null) {\r\n (process.env.NODE_ENV !== 'production') && warn(`withDirectives can only be used inside render functions.`);\r\n return vnode;\r\n }\r\n const instance = internalInstance.proxy;\r\n const bindings = vnode.dirs || (vnode.dirs = []);\r\n for (let i = 0; i < directives.length; i++) {\r\n let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];\r\n if (isFunction(dir)) {\r\n dir = {\r\n mounted: dir,\r\n updated: dir\r\n };\r\n }\r\n if (dir.deep) {\r\n traverse(value);\r\n }\r\n bindings.push({\r\n dir,\r\n instance,\r\n value,\r\n oldValue: void 0,\r\n arg,\r\n modifiers\r\n });\r\n }\r\n return vnode;\r\n}\r\nfunction invokeDirectiveHook(vnode, prevVNode, instance, name) {\r\n const bindings = vnode.dirs;\r\n const oldBindings = prevVNode && prevVNode.dirs;\r\n for (let i = 0; i < bindings.length; i++) {\r\n const binding = bindings[i];\r\n if (oldBindings) {\r\n binding.oldValue = oldBindings[i].value;\r\n }\r\n let hook = binding.dir[name];\r\n if (hook) {\r\n // disable tracking inside all lifecycle hooks\r\n // since they can potentially be called inside effects.\r\n pauseTracking();\r\n callWithAsyncErrorHandling(hook, instance, 8 /* DIRECTIVE_HOOK */, [\r\n vnode.el,\r\n binding,\r\n vnode,\r\n prevVNode\r\n ]);\r\n resetTracking();\r\n }\r\n }\r\n}\n\nfunction createAppContext() {\r\n return {\r\n app: null,\r\n config: {\r\n isNativeTag: NO,\r\n performance: false,\r\n globalProperties: {},\r\n optionMergeStrategies: {},\r\n errorHandler: undefined,\r\n warnHandler: undefined,\r\n compilerOptions: {}\r\n },\r\n mixins: [],\r\n components: {},\r\n directives: {},\r\n provides: Object.create(null),\r\n optionsCache: new WeakMap(),\r\n propsCache: new WeakMap(),\r\n emitsCache: new WeakMap()\r\n };\r\n}\r\nlet uid = 0;\r\nfunction createAppAPI(render, hydrate) {\r\n return function createApp(rootComponent, rootProps = null) {\r\n if (rootProps != null && !isObject(rootProps)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`root props passed to app.mount() must be an object.`);\r\n rootProps = null;\r\n }\r\n const context = createAppContext();\r\n const installedPlugins = new Set();\r\n let isMounted = false;\r\n const app = (context.app = {\r\n _uid: uid++,\r\n _component: rootComponent,\r\n _props: rootProps,\r\n _container: null,\r\n _context: context,\r\n _instance: null,\r\n version,\r\n get config() {\r\n return context.config;\r\n },\r\n set config(v) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`app.config cannot be replaced. Modify individual options instead.`);\r\n }\r\n },\r\n use(plugin, ...options) {\r\n if (installedPlugins.has(plugin)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Plugin has already been applied to target app.`);\r\n }\r\n else if (plugin && isFunction(plugin.install)) {\r\n installedPlugins.add(plugin);\r\n plugin.install(app, ...options);\r\n }\r\n else if (isFunction(plugin)) {\r\n installedPlugins.add(plugin);\r\n plugin(app, ...options);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`A plugin must either be a function or an object with an \"install\" ` +\r\n `function.`);\r\n }\r\n return app;\r\n },\r\n mixin(mixin) {\r\n if (__VUE_OPTIONS_API__) {\r\n if (!context.mixins.includes(mixin)) {\r\n context.mixins.push(mixin);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Mixin has already been applied to target app' +\r\n (mixin.name ? `: ${mixin.name}` : ''));\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Mixins are only available in builds supporting Options API');\r\n }\r\n return app;\r\n },\r\n component(name, component) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateComponentName(name, context.config);\r\n }\r\n if (!component) {\r\n return context.components[name];\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && context.components[name]) {\r\n warn(`Component \"${name}\" has already been registered in target app.`);\r\n }\r\n context.components[name] = component;\r\n return app;\r\n },\r\n directive(name, directive) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateDirectiveName(name);\r\n }\r\n if (!directive) {\r\n return context.directives[name];\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && context.directives[name]) {\r\n warn(`Directive \"${name}\" has already been registered in target app.`);\r\n }\r\n context.directives[name] = directive;\r\n return app;\r\n },\r\n mount(rootContainer, isHydrate, isSVG) {\r\n if (!isMounted) {\r\n const vnode = createVNode(rootComponent, rootProps);\r\n // store app context on the root VNode.\r\n // this will be set on the root instance on initial mount.\r\n vnode.appContext = context;\r\n // HMR root reload\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n context.reload = () => {\r\n render(cloneVNode(vnode), rootContainer, isSVG);\r\n };\r\n }\r\n if (isHydrate && hydrate) {\r\n hydrate(vnode, rootContainer);\r\n }\r\n else {\r\n render(vnode, rootContainer, isSVG);\r\n }\r\n isMounted = true;\r\n app._container = rootContainer;\r\n rootContainer.__vue_app__ = app;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n app._instance = vnode.component;\r\n devtoolsInitApp(app, version);\r\n }\r\n return getExposeProxy(vnode.component) || vnode.component.proxy;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`App has already been mounted.\\n` +\r\n `If you want to remount the same app, move your app creation logic ` +\r\n `into a factory function and create fresh app instances for each ` +\r\n `mount - e.g. \\`const createMyApp = () => createApp(App)\\``);\r\n }\r\n },\r\n unmount() {\r\n if (isMounted) {\r\n render(null, app._container);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n app._instance = null;\r\n devtoolsUnmountApp(app);\r\n }\r\n delete app._container.__vue_app__;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Cannot unmount an app that is not mounted.`);\r\n }\r\n },\r\n provide(key, value) {\r\n if ((process.env.NODE_ENV !== 'production') && key in context.provides) {\r\n warn(`App already provides property with key \"${String(key)}\". ` +\r\n `It will be overwritten with the new value.`);\r\n }\r\n // TypeScript doesn't allow symbols as index type\r\n // https://github.com/Microsoft/TypeScript/issues/24587\r\n context.provides[key] = value;\r\n return app;\r\n }\r\n });\r\n return app;\r\n };\r\n}\n\n/**\r\n * Function for handling a template ref\r\n */\r\nfunction setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {\r\n if (isArray(rawRef)) {\r\n rawRef.forEach((r, i) => setRef(r, oldRawRef && (isArray(oldRawRef) ? oldRawRef[i] : oldRawRef), parentSuspense, vnode, isUnmount));\r\n return;\r\n }\r\n if (isAsyncWrapper(vnode) && !isUnmount) {\r\n // when mounting async components, nothing needs to be done,\r\n // because the template ref is forwarded to inner component\r\n return;\r\n }\r\n const refValue = vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */\r\n ? getExposeProxy(vnode.component) || vnode.component.proxy\r\n : vnode.el;\r\n const value = isUnmount ? null : refValue;\r\n const { i: owner, r: ref } = rawRef;\r\n if ((process.env.NODE_ENV !== 'production') && !owner) {\r\n warn(`Missing ref owner context. ref cannot be used on hoisted vnodes. ` +\r\n `A vnode with ref must be created inside the render function.`);\r\n return;\r\n }\r\n const oldRef = oldRawRef && oldRawRef.r;\r\n const refs = owner.refs === EMPTY_OBJ ? (owner.refs = {}) : owner.refs;\r\n const setupState = owner.setupState;\r\n // dynamic ref changed. unset old ref\r\n if (oldRef != null && oldRef !== ref) {\r\n if (isString(oldRef)) {\r\n refs[oldRef] = null;\r\n if (hasOwn(setupState, oldRef)) {\r\n setupState[oldRef] = null;\r\n }\r\n }\r\n else if (isRef(oldRef)) {\r\n oldRef.value = null;\r\n }\r\n }\r\n if (isFunction(ref)) {\r\n callWithErrorHandling(ref, owner, 12 /* FUNCTION_REF */, [value, refs]);\r\n }\r\n else {\r\n const _isString = isString(ref);\r\n const _isRef = isRef(ref);\r\n if (_isString || _isRef) {\r\n const doSet = () => {\r\n if (rawRef.f) {\r\n const existing = _isString ? refs[ref] : ref.value;\r\n if (isUnmount) {\r\n isArray(existing) && remove(existing, refValue);\r\n }\r\n else {\r\n if (!isArray(existing)) {\r\n if (_isString) {\r\n refs[ref] = [refValue];\r\n }\r\n else {\r\n ref.value = [refValue];\r\n if (rawRef.k)\r\n refs[rawRef.k] = ref.value;\r\n }\r\n }\r\n else if (!existing.includes(refValue)) {\r\n existing.push(refValue);\r\n }\r\n }\r\n }\r\n else if (_isString) {\r\n refs[ref] = value;\r\n if (hasOwn(setupState, ref)) {\r\n setupState[ref] = value;\r\n }\r\n }\r\n else if (isRef(ref)) {\r\n ref.value = value;\r\n if (rawRef.k)\r\n refs[rawRef.k] = value;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid template ref type:', ref, `(${typeof ref})`);\r\n }\r\n };\r\n if (value) {\r\n doSet.id = -1;\r\n queuePostRenderEffect(doSet, parentSuspense);\r\n }\r\n else {\r\n doSet();\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid template ref type:', ref, `(${typeof ref})`);\r\n }\r\n }\r\n}\n\nlet hasMismatch = false;\r\nconst isSVGContainer = (container) => /svg/.test(container.namespaceURI) && container.tagName !== 'foreignObject';\r\nconst isComment = (node) => node.nodeType === 8 /* COMMENT */;\r\n// Note: hydration is DOM-specific\r\n// But we have to place it in core due to tight coupling with core - splitting\r\n// it out creates a ton of unnecessary complexity.\r\n// Hydration also depends on some renderer internal logic which needs to be\r\n// passed in via arguments.\r\nfunction createHydrationFunctions(rendererInternals) {\r\n const { mt: mountComponent, p: patch, o: { patchProp, nextSibling, parentNode, remove, insert, createComment } } = rendererInternals;\r\n const hydrate = (vnode, container) => {\r\n if (!container.hasChildNodes()) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to hydrate existing markup but container is empty. ` +\r\n `Performing full mount instead.`);\r\n patch(null, vnode, container);\r\n flushPostFlushCbs();\r\n return;\r\n }\r\n hasMismatch = false;\r\n hydrateNode(container.firstChild, vnode, null, null, null);\r\n flushPostFlushCbs();\r\n if (hasMismatch && !false) {\r\n // this error should show up in production\r\n console.error(`Hydration completed but contains mismatches.`);\r\n }\r\n };\r\n const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {\r\n const isFragmentStart = isComment(node) && node.data === '[';\r\n const onMismatch = () => handleMismatch(node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragmentStart);\r\n const { type, ref, shapeFlag } = vnode;\r\n const domType = node.nodeType;\r\n vnode.el = node;\r\n let nextNode = null;\r\n switch (type) {\r\n case Text:\r\n if (domType !== 3 /* TEXT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n if (node.data !== vnode.children) {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration text mismatch:` +\r\n `\\n- Client: ${JSON.stringify(node.data)}` +\r\n `\\n- Server: ${JSON.stringify(vnode.children)}`);\r\n node.data = vnode.children;\r\n }\r\n nextNode = nextSibling(node);\r\n }\r\n break;\r\n case Comment:\r\n if (domType !== 8 /* COMMENT */ || isFragmentStart) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = nextSibling(node);\r\n }\r\n break;\r\n case Static:\r\n if (domType !== 1 /* ELEMENT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n // determine anchor, adopt content\r\n nextNode = node;\r\n // if the static vnode has its content stripped during build,\r\n // adopt it from the server-rendered HTML.\r\n const needToAdoptContent = !vnode.children.length;\r\n for (let i = 0; i < vnode.staticCount; i++) {\r\n if (needToAdoptContent)\r\n vnode.children += nextNode.outerHTML;\r\n if (i === vnode.staticCount - 1) {\r\n vnode.anchor = nextNode;\r\n }\r\n nextNode = nextSibling(nextNode);\r\n }\r\n return nextNode;\r\n }\r\n break;\r\n case Fragment:\r\n if (!isFragmentStart) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = hydrateFragment(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n break;\r\n default:\r\n if (shapeFlag & 1 /* ELEMENT */) {\r\n if (domType !== 1 /* ELEMENT */ ||\r\n vnode.type.toLowerCase() !==\r\n node.tagName.toLowerCase()) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n }\r\n else if (shapeFlag & 6 /* COMPONENT */) {\r\n // when setting up the render effect, if the initial vnode already\r\n // has .el set, the component will perform hydration instead of mount\r\n // on its sub-tree.\r\n vnode.slotScopeIds = slotScopeIds;\r\n const container = parentNode(node);\r\n mountComponent(vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), optimized);\r\n // component may be async, so in the case of fragments we cannot rely\r\n // on component's rendered output to determine the end of the fragment\r\n // instead, we do a lookahead to find the end anchor node.\r\n nextNode = isFragmentStart\r\n ? locateClosingAsyncAnchor(node)\r\n : nextSibling(node);\r\n // #3787\r\n // if component is async, it may get moved / unmounted before its\r\n // inner component is loaded, so we need to give it a placeholder\r\n // vnode that matches its adopted DOM.\r\n if (isAsyncWrapper(vnode)) {\r\n let subTree;\r\n if (isFragmentStart) {\r\n subTree = createVNode(Fragment);\r\n subTree.anchor = nextNode\r\n ? nextNode.previousSibling\r\n : container.lastChild;\r\n }\r\n else {\r\n subTree =\r\n node.nodeType === 3 ? createTextVNode('') : createVNode('div');\r\n }\r\n subTree.el = node;\r\n vnode.component.subTree = subTree;\r\n }\r\n }\r\n else if (shapeFlag & 64 /* TELEPORT */) {\r\n if (domType !== 8 /* COMMENT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);\r\n }\r\n }\r\n else if (shapeFlag & 128 /* SUSPENSE */) {\r\n nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, isSVGContainer(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid HostVNode type:', type, `(${typeof type})`);\r\n }\r\n }\r\n if (ref != null) {\r\n setRef(ref, null, parentSuspense, vnode);\r\n }\r\n return nextNode;\r\n };\r\n const hydrateElement = (el, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n optimized = optimized || !!vnode.dynamicChildren;\r\n const { type, props, patchFlag, shapeFlag, dirs } = vnode;\r\n // #4006 for form elements with non-string v-model value bindings\r\n // e.g. <option :value=\"obj\">, <input type=\"checkbox\" :true-value=\"1\">\r\n const forcePatchValue = (type === 'input' && dirs) || type === 'option';\r\n // skip props & children if this is hoisted static nodes\r\n if (forcePatchValue || patchFlag !== -1 /* HOISTED */) {\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n }\r\n // props\r\n if (props) {\r\n if (forcePatchValue ||\r\n !optimized ||\r\n patchFlag & (16 /* FULL_PROPS */ | 32 /* HYDRATE_EVENTS */)) {\r\n for (const key in props) {\r\n if ((forcePatchValue && key.endsWith('value')) ||\r\n (isOn(key) && !isReservedProp(key))) {\r\n patchProp(el, key, null, props[key], false, undefined, parentComponent);\r\n }\r\n }\r\n }\r\n else if (props.onClick) {\r\n // Fast path for click listeners (which is most often) to avoid\r\n // iterating through props.\r\n patchProp(el, 'onClick', null, props.onClick, false, undefined, parentComponent);\r\n }\r\n }\r\n // vnode / directive hooks\r\n let vnodeHooks;\r\n if ((vnodeHooks = props && props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n }\r\n if ((vnodeHooks = props && props.onVnodeMounted) || dirs) {\r\n queueEffectWithSuspense(() => {\r\n vnodeHooks && invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n }, parentSuspense);\r\n }\r\n // children\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */ &&\r\n // skip if element has innerHTML / textContent\r\n !(props && (props.innerHTML || props.textContent))) {\r\n let next = hydrateChildren(el.firstChild, vnode, el, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n let hasWarned = false;\r\n while (next) {\r\n hasMismatch = true;\r\n if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n warn(`Hydration children mismatch in <${vnode.type}>: ` +\r\n `server rendered element contains more child nodes than client vdom.`);\r\n hasWarned = true;\r\n }\r\n // The SSRed DOM contains more nodes than it should. Remove them.\r\n const cur = next;\r\n next = next.nextSibling;\r\n remove(cur);\r\n }\r\n }\r\n else if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n if (el.textContent !== vnode.children) {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration text content mismatch in <${vnode.type}>:\\n` +\r\n `- Client: ${el.textContent}\\n` +\r\n `- Server: ${vnode.children}`);\r\n el.textContent = vnode.children;\r\n }\r\n }\r\n }\r\n return el.nextSibling;\r\n };\r\n const hydrateChildren = (node, parentVNode, container, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n optimized = optimized || !!parentVNode.dynamicChildren;\r\n const children = parentVNode.children;\r\n const l = children.length;\r\n let hasWarned = false;\r\n for (let i = 0; i < l; i++) {\r\n const vnode = optimized\r\n ? children[i]\r\n : (children[i] = normalizeVNode(children[i]));\r\n if (node) {\r\n node = hydrateNode(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n else if (vnode.type === Text && !vnode.children) {\r\n continue;\r\n }\r\n else {\r\n hasMismatch = true;\r\n if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n warn(`Hydration children mismatch in <${container.tagName.toLowerCase()}>: ` +\r\n `server rendered element contains fewer child nodes than client vdom.`);\r\n hasWarned = true;\r\n }\r\n // the SSRed DOM didn't contain enough nodes. Mount the missing ones.\r\n patch(null, vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n }\r\n }\r\n return node;\r\n };\r\n const hydrateFragment = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n const { slotScopeIds: fragmentSlotScopeIds } = vnode;\r\n if (fragmentSlotScopeIds) {\r\n slotScopeIds = slotScopeIds\r\n ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n : fragmentSlotScopeIds;\r\n }\r\n const container = parentNode(node);\r\n const next = hydrateChildren(nextSibling(node), vnode, container, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n if (next && isComment(next) && next.data === ']') {\r\n return nextSibling((vnode.anchor = next));\r\n }\r\n else {\r\n // fragment didn't hydrate successfully, since we didn't get a end anchor\r\n // back. This should have led to node/children mismatch warnings.\r\n hasMismatch = true;\r\n // since the anchor is missing, we need to create one and insert it\r\n insert((vnode.anchor = createComment(`]`)), container, next);\r\n return next;\r\n }\r\n };\r\n const handleMismatch = (node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragment) => {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration node mismatch:\\n- Client vnode:`, vnode.type, `\\n- Server rendered DOM:`, node, node.nodeType === 3 /* TEXT */\r\n ? `(text)`\r\n : isComment(node) && node.data === '['\r\n ? `(start of fragment)`\r\n : ``);\r\n vnode.el = null;\r\n if (isFragment) {\r\n // remove excessive fragment nodes\r\n const end = locateClosingAsyncAnchor(node);\r\n while (true) {\r\n const next = nextSibling(node);\r\n if (next && next !== end) {\r\n remove(next);\r\n }\r\n else {\r\n break;\r\n }\r\n }\r\n }\r\n const next = nextSibling(node);\r\n const container = parentNode(node);\r\n remove(node);\r\n patch(null, vnode, container, next, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n return next;\r\n };\r\n const locateClosingAsyncAnchor = (node) => {\r\n let match = 0;\r\n while (node) {\r\n node = nextSibling(node);\r\n if (node && isComment(node)) {\r\n if (node.data === '[')\r\n match++;\r\n if (node.data === ']') {\r\n if (match === 0) {\r\n return nextSibling(node);\r\n }\r\n else {\r\n match--;\r\n }\r\n }\r\n }\r\n }\r\n return node;\r\n };\r\n return [hydrate, hydrateNode];\r\n}\n\nlet supported;\r\nlet perf;\r\nfunction startMeasure(instance, type) {\r\n if (instance.appContext.config.performance && isSupported()) {\r\n perf.mark(`vue-${type}-${instance.uid}`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsPerfStart(instance, type, supported ? perf.now() : Date.now());\r\n }\r\n}\r\nfunction endMeasure(instance, type) {\r\n if (instance.appContext.config.performance && isSupported()) {\r\n const startTag = `vue-${type}-${instance.uid}`;\r\n const endTag = startTag + `:end`;\r\n perf.mark(endTag);\r\n perf.measure(`<${formatComponentName(instance, instance.type)}> ${type}`, startTag, endTag);\r\n perf.clearMarks(startTag);\r\n perf.clearMarks(endTag);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsPerfEnd(instance, type, supported ? perf.now() : Date.now());\r\n }\r\n}\r\nfunction isSupported() {\r\n if (supported !== undefined) {\r\n return supported;\r\n }\r\n /* eslint-disable no-restricted-globals */\r\n if (typeof window !== 'undefined' && window.performance) {\r\n supported = true;\r\n perf = window.performance;\r\n }\r\n else {\r\n supported = false;\r\n }\r\n /* eslint-enable no-restricted-globals */\r\n return supported;\r\n}\n\n/**\r\n * This is only called in esm-bundler builds.\r\n * It is called when a renderer is created, in `baseCreateRenderer` so that\r\n * importing runtime-core is side-effects free.\r\n *\r\n * istanbul-ignore-next\r\n */\r\nfunction initFeatureFlags() {\r\n const needWarn = [];\r\n if (typeof __VUE_OPTIONS_API__ !== 'boolean') {\r\n (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_OPTIONS_API__`);\r\n getGlobalThis().__VUE_OPTIONS_API__ = true;\r\n }\r\n if (typeof __VUE_PROD_DEVTOOLS__ !== 'boolean') {\r\n (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_PROD_DEVTOOLS__`);\r\n getGlobalThis().__VUE_PROD_DEVTOOLS__ = false;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && needWarn.length) {\r\n const multi = needWarn.length > 1;\r\n console.warn(`Feature flag${multi ? `s` : ``} ${needWarn.join(', ')} ${multi ? `are` : `is`} not explicitly defined. You are running the esm-bundler build of Vue, ` +\r\n `which expects these compile-time feature flags to be globally injected ` +\r\n `via the bundler config in order to get better tree-shaking in the ` +\r\n `production bundle.\\n\\n` +\r\n `For more details, see https://link.vuejs.org/feature-flags.`);\r\n }\r\n}\n\nconst queuePostRenderEffect = queueEffectWithSuspense\r\n ;\r\n/**\r\n * The createRenderer function accepts two generic arguments:\r\n * HostNode and HostElement, corresponding to Node and Element types in the\r\n * host environment. For example, for runtime-dom, HostNode would be the DOM\r\n * `Node` interface and HostElement would be the DOM `Element` interface.\r\n *\r\n * Custom renderers can pass in the platform specific types like this:\r\n *\r\n * ``` js\r\n * const { render, createApp } = createRenderer<Node, Element>({\r\n * patchProp,\r\n * ...nodeOps\r\n * })\r\n * ```\r\n */\r\nfunction createRenderer(options) {\r\n return baseCreateRenderer(options);\r\n}\r\n// Separate API for creating hydration-enabled renderer.\r\n// Hydration logic is only used when calling this function, making it\r\n// tree-shakable.\r\nfunction createHydrationRenderer(options) {\r\n return baseCreateRenderer(options, createHydrationFunctions);\r\n}\r\n// implementation\r\nfunction baseCreateRenderer(options, createHydrationFns) {\r\n // compile-time feature flags check\r\n {\r\n initFeatureFlags();\r\n }\r\n const target = getGlobalThis();\r\n target.__VUE__ = true;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n setDevtoolsHook(target.__VUE_DEVTOOLS_GLOBAL_HOOK__, target);\r\n }\r\n const { insert: hostInsert, remove: hostRemove, patchProp: hostPatchProp, createElement: hostCreateElement, createText: hostCreateText, createComment: hostCreateComment, setText: hostSetText, setElementText: hostSetElementText, parentNode: hostParentNode, nextSibling: hostNextSibling, setScopeId: hostSetScopeId = NOOP, cloneNode: hostCloneNode, insertStaticContent: hostInsertStaticContent } = options;\r\n // Note: functions inside this closure should use `const xxx = () => {}`\r\n // style in order to prevent being inlined by minifiers.\r\n const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, isSVG = false, slotScopeIds = null, optimized = (process.env.NODE_ENV !== 'production') && isHmrUpdating ? false : !!n2.dynamicChildren) => {\r\n if (n1 === n2) {\r\n return;\r\n }\r\n // patching & not same type, unmount old tree\r\n if (n1 && !isSameVNodeType(n1, n2)) {\r\n anchor = getNextHostNode(n1);\r\n unmount(n1, parentComponent, parentSuspense, true);\r\n n1 = null;\r\n }\r\n if (n2.patchFlag === -2 /* BAIL */) {\r\n optimized = false;\r\n n2.dynamicChildren = null;\r\n }\r\n const { type, ref, shapeFlag } = n2;\r\n switch (type) {\r\n case Text:\r\n processText(n1, n2, container, anchor);\r\n break;\r\n case Comment:\r\n processCommentNode(n1, n2, container, anchor);\r\n break;\r\n case Static:\r\n if (n1 == null) {\r\n mountStaticNode(n2, container, anchor, isSVG);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n patchStaticNode(n1, n2, container, isSVG);\r\n }\r\n break;\r\n case Fragment:\r\n processFragment(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n break;\r\n default:\r\n if (shapeFlag & 1 /* ELEMENT */) {\r\n processElement(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (shapeFlag & 6 /* COMPONENT */) {\r\n processComponent(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (shapeFlag & 64 /* TELEPORT */) {\r\n type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n }\r\n else if (shapeFlag & 128 /* SUSPENSE */) {\r\n type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid VNode type:', type, `(${typeof type})`);\r\n }\r\n }\r\n // set ref\r\n if (ref != null && parentComponent) {\r\n setRef(ref, n1 && n1.ref, parentSuspense, n2 || n1, !n2);\r\n }\r\n };\r\n const processText = (n1, n2, container, anchor) => {\r\n if (n1 == null) {\r\n hostInsert((n2.el = hostCreateText(n2.children)), container, anchor);\r\n }\r\n else {\r\n const el = (n2.el = n1.el);\r\n if (n2.children !== n1.children) {\r\n hostSetText(el, n2.children);\r\n }\r\n }\r\n };\r\n const processCommentNode = (n1, n2, container, anchor) => {\r\n if (n1 == null) {\r\n hostInsert((n2.el = hostCreateComment(n2.children || '')), container, anchor);\r\n }\r\n else {\r\n // there's no support for dynamic comments\r\n n2.el = n1.el;\r\n }\r\n };\r\n const mountStaticNode = (n2, container, anchor, isSVG) => {\r\n [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n };\r\n /**\r\n * Dev / HMR only\r\n */\r\n const patchStaticNode = (n1, n2, container, isSVG) => {\r\n // static nodes are only patched during dev for HMR\r\n if (n2.children !== n1.children) {\r\n const anchor = hostNextSibling(n1.anchor);\r\n // remove existing\r\n removeStaticNode(n1);\r\n [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n }\r\n else {\r\n n2.el = n1.el;\r\n n2.anchor = n1.anchor;\r\n }\r\n };\r\n const moveStaticNode = ({ el, anchor }, container, nextSibling) => {\r\n let next;\r\n while (el && el !== anchor) {\r\n next = hostNextSibling(el);\r\n hostInsert(el, container, nextSibling);\r\n el = next;\r\n }\r\n hostInsert(anchor, container, nextSibling);\r\n };\r\n const removeStaticNode = ({ el, anchor }) => {\r\n let next;\r\n while (el && el !== anchor) {\r\n next = hostNextSibling(el);\r\n hostRemove(el);\r\n el = next;\r\n }\r\n hostRemove(anchor);\r\n };\r\n const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n isSVG = isSVG || n2.type === 'svg';\r\n if (n1 == null) {\r\n mountElement(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n patchElement(n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n const mountElement = (vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n let el;\r\n let vnodeHook;\r\n const { type, props, shapeFlag, transition, patchFlag, dirs } = vnode;\r\n if (!(process.env.NODE_ENV !== 'production') &&\r\n vnode.el &&\r\n hostCloneNode !== undefined &&\r\n patchFlag === -1 /* HOISTED */) {\r\n // If a vnode has non-null el, it means it's being reused.\r\n // Only static vnodes can be reused, so its mounted DOM nodes should be\r\n // exactly the same, and we can simply do a clone here.\r\n // only do this in production since cloned trees cannot be HMR updated.\r\n el = vnode.el = hostCloneNode(vnode.el);\r\n }\r\n else {\r\n el = vnode.el = hostCreateElement(vnode.type, isSVG, props && props.is, props);\r\n // mount children first, since some props may rely on child content\r\n // being already rendered, e.g. `<select value>`\r\n if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n hostSetElementText(el, vnode.children);\r\n }\r\n else if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(vnode.children, el, null, parentComponent, parentSuspense, isSVG && type !== 'foreignObject', slotScopeIds, optimized);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n }\r\n // props\r\n if (props) {\r\n for (const key in props) {\r\n if (key !== 'value' && !isReservedProp(key)) {\r\n hostPatchProp(el, key, null, props[key], isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n /**\r\n * Special case for setting value on DOM elements:\r\n * - it can be order-sensitive (e.g. should be set *after* min/max, #2325, #4024)\r\n * - it needs to be forced (#1471)\r\n * #2353 proposes adding another renderer option to configure this, but\r\n * the properties affects are so finite it is worth special casing it\r\n * here to reduce the complexity. (Special casing it also should not\r\n * affect non-DOM renderers)\r\n */\r\n if ('value' in props) {\r\n hostPatchProp(el, 'value', null, props.value);\r\n }\r\n if ((vnodeHook = props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n }\r\n }\r\n // scopeId\r\n setScopeId(el, vnode, vnode.scopeId, slotScopeIds, parentComponent);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n Object.defineProperty(el, '__vnode', {\r\n value: vnode,\r\n enumerable: false\r\n });\r\n Object.defineProperty(el, '__vueParentComponent', {\r\n value: parentComponent,\r\n enumerable: false\r\n });\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n }\r\n // #1583 For inside suspense + suspense not resolved case, enter hook should call when suspense resolved\r\n // #1689 For inside suspense + suspense resolved case, just call it\r\n const needCallTransitionHooks = (!parentSuspense || (parentSuspense && !parentSuspense.pendingBranch)) &&\r\n transition &&\r\n !transition.persisted;\r\n if (needCallTransitionHooks) {\r\n transition.beforeEnter(el);\r\n }\r\n hostInsert(el, container, anchor);\r\n if ((vnodeHook = props && props.onVnodeMounted) ||\r\n needCallTransitionHooks ||\r\n dirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n needCallTransitionHooks && transition.enter(el);\r\n dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n }, parentSuspense);\r\n }\r\n };\r\n const setScopeId = (el, vnode, scopeId, slotScopeIds, parentComponent) => {\r\n if (scopeId) {\r\n hostSetScopeId(el, scopeId);\r\n }\r\n if (slotScopeIds) {\r\n for (let i = 0; i < slotScopeIds.length; i++) {\r\n hostSetScopeId(el, slotScopeIds[i]);\r\n }\r\n }\r\n if (parentComponent) {\r\n let subTree = parentComponent.subTree;\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n subTree.patchFlag > 0 &&\r\n subTree.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n subTree =\r\n filterSingleRoot(subTree.children) || subTree;\r\n }\r\n if (vnode === subTree) {\r\n const parentVNode = parentComponent.vnode;\r\n setScopeId(el, parentVNode, parentVNode.scopeId, parentVNode.slotScopeIds, parentComponent.parent);\r\n }\r\n }\r\n };\r\n const mountChildren = (children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, start = 0) => {\r\n for (let i = start; i < children.length; i++) {\r\n const child = (children[i] = optimized\r\n ? cloneIfMounted(children[i])\r\n : normalizeVNode(children[i]));\r\n patch(null, child, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n const patchElement = (n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n const el = (n2.el = n1.el);\r\n let { patchFlag, dynamicChildren, dirs } = n2;\r\n // #1426 take the old vnode's patch flag into account since user may clone a\r\n // compiler-generated vnode, which de-opts to FULL_PROPS\r\n patchFlag |= n1.patchFlag & 16 /* FULL_PROPS */;\r\n const oldProps = n1.props || EMPTY_OBJ;\r\n const newProps = n2.props || EMPTY_OBJ;\r\n let vnodeHook;\r\n // disable recurse in beforeUpdate hooks\r\n parentComponent && toggleRecurse(parentComponent, false);\r\n if ((vnodeHook = newProps.onVnodeBeforeUpdate)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(n2, n1, parentComponent, 'beforeUpdate');\r\n }\r\n parentComponent && toggleRecurse(parentComponent, true);\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // HMR updated, force full diff\r\n patchFlag = 0;\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n const areChildrenSVG = isSVG && n2.type !== 'foreignObject';\r\n if (dynamicChildren) {\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, el, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds);\r\n if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n traverseStaticChildren(n1, n2);\r\n }\r\n }\r\n else if (!optimized) {\r\n // full diff\r\n patchChildren(n1, n2, el, null, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds, false);\r\n }\r\n if (patchFlag > 0) {\r\n // the presence of a patchFlag means this element's render code was\r\n // generated by the compiler and can take the fast path.\r\n // in this path old node and new node are guaranteed to have the same shape\r\n // (i.e. at the exact same position in the source template)\r\n if (patchFlag & 16 /* FULL_PROPS */) {\r\n // element props contain dynamic keys, full diff needed\r\n patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n }\r\n else {\r\n // class\r\n // this flag is matched when the element has dynamic class bindings.\r\n if (patchFlag & 2 /* CLASS */) {\r\n if (oldProps.class !== newProps.class) {\r\n hostPatchProp(el, 'class', null, newProps.class, isSVG);\r\n }\r\n }\r\n // style\r\n // this flag is matched when the element has dynamic style bindings\r\n if (patchFlag & 4 /* STYLE */) {\r\n hostPatchProp(el, 'style', oldProps.style, newProps.style, isSVG);\r\n }\r\n // props\r\n // This flag is matched when the element has dynamic prop/attr bindings\r\n // other than class and style. The keys of dynamic prop/attrs are saved for\r\n // faster iteration.\r\n // Note dynamic keys like :[foo]=\"bar\" will cause this optimization to\r\n // bail out and go through a full diff because we need to unset the old key\r\n if (patchFlag & 8 /* PROPS */) {\r\n // if the flag is present then dynamicProps must be non-null\r\n const propsToUpdate = n2.dynamicProps;\r\n for (let i = 0; i < propsToUpdate.length; i++) {\r\n const key = propsToUpdate[i];\r\n const prev = oldProps[key];\r\n const next = newProps[key];\r\n // #1471 force patch value\r\n if (next !== prev || key === 'value') {\r\n hostPatchProp(el, key, prev, next, isSVG, n1.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n }\r\n }\r\n // text\r\n // This flag is matched when the element has only dynamic text children.\r\n if (patchFlag & 1 /* TEXT */) {\r\n if (n1.children !== n2.children) {\r\n hostSetElementText(el, n2.children);\r\n }\r\n }\r\n }\r\n else if (!optimized && dynamicChildren == null) {\r\n // unoptimized, full diff\r\n patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n }\r\n if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n dirs && invokeDirectiveHook(n2, n1, parentComponent, 'updated');\r\n }, parentSuspense);\r\n }\r\n };\r\n // The fast path for blocks.\r\n const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, isSVG, slotScopeIds) => {\r\n for (let i = 0; i < newChildren.length; i++) {\r\n const oldVNode = oldChildren[i];\r\n const newVNode = newChildren[i];\r\n // Determine the container (parent element) for the patch.\r\n const container = \r\n // oldVNode may be an errored async setup() component inside Suspense\r\n // which will not have a mounted element\r\n oldVNode.el &&\r\n // - In the case of a Fragment, we need to provide the actual parent\r\n // of the Fragment itself so it can move its children.\r\n (oldVNode.type === Fragment ||\r\n // - In the case of different nodes, there is going to be a replacement\r\n // which also requires the correct parent container\r\n !isSameVNodeType(oldVNode, newVNode) ||\r\n // - In the case of a component, it could contain anything.\r\n oldVNode.shapeFlag & (6 /* COMPONENT */ | 64 /* TELEPORT */))\r\n ? hostParentNode(oldVNode.el)\r\n : // In other cases, the parent container is not actually used so we\r\n // just pass the block element here to avoid a DOM parentNode call.\r\n fallbackContainer;\r\n patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, true);\r\n }\r\n };\r\n const patchProps = (el, vnode, oldProps, newProps, parentComponent, parentSuspense, isSVG) => {\r\n if (oldProps !== newProps) {\r\n for (const key in newProps) {\r\n // empty string is not valid prop\r\n if (isReservedProp(key))\r\n continue;\r\n const next = newProps[key];\r\n const prev = oldProps[key];\r\n // defer patching value\r\n if (next !== prev && key !== 'value') {\r\n hostPatchProp(el, key, prev, next, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n if (oldProps !== EMPTY_OBJ) {\r\n for (const key in oldProps) {\r\n if (!isReservedProp(key) && !(key in newProps)) {\r\n hostPatchProp(el, key, oldProps[key], null, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n }\r\n if ('value' in newProps) {\r\n hostPatchProp(el, 'value', oldProps.value, newProps.value);\r\n }\r\n }\r\n };\r\n const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n const fragmentStartAnchor = (n2.el = n1 ? n1.el : hostCreateText(''));\r\n const fragmentEndAnchor = (n2.anchor = n1 ? n1.anchor : hostCreateText(''));\r\n let { patchFlag, dynamicChildren, slotScopeIds: fragmentSlotScopeIds } = n2;\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // HMR updated, force full diff\r\n patchFlag = 0;\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n // check if this is a slot fragment with :slotted scope ids\r\n if (fragmentSlotScopeIds) {\r\n slotScopeIds = slotScopeIds\r\n ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n : fragmentSlotScopeIds;\r\n }\r\n if (n1 == null) {\r\n hostInsert(fragmentStartAnchor, container, anchor);\r\n hostInsert(fragmentEndAnchor, container, anchor);\r\n // a fragment can only have array children\r\n // since they are either generated by the compiler, or implicitly created\r\n // from arrays.\r\n mountChildren(n2.children, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n if (patchFlag > 0 &&\r\n patchFlag & 64 /* STABLE_FRAGMENT */ &&\r\n dynamicChildren &&\r\n // #2715 the previous fragment could've been a BAILed one as a result\r\n // of renderSlot() with no valid children\r\n n1.dynamicChildren) {\r\n // a stable fragment (template root or <template v-for>) doesn't need to\r\n // patch children order, but it may contain dynamicChildren.\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, container, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n traverseStaticChildren(n1, n2);\r\n }\r\n else if (\r\n // #2080 if the stable fragment has a key, it's a <template v-for> that may\r\n // get moved around. Make sure all root level vnodes inherit el.\r\n // #2134 or if it's a component root, it may also get moved around\r\n // as the component is being moved.\r\n n2.key != null ||\r\n (parentComponent && n2 === parentComponent.subTree)) {\r\n traverseStaticChildren(n1, n2, true /* shallow */);\r\n }\r\n }\r\n else {\r\n // keyed / unkeyed, or manual fragments.\r\n // for keyed & unkeyed, since they are compiler generated from v-for,\r\n // each child is guaranteed to be a block so the fragment will never\r\n // have dynamicChildren.\r\n patchChildren(n1, n2, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n }\r\n };\r\n const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n n2.slotScopeIds = slotScopeIds;\r\n if (n1 == null) {\r\n if (n2.shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n parentComponent.ctx.activate(n2, container, anchor, isSVG, optimized);\r\n }\r\n else {\r\n mountComponent(n2, container, anchor, parentComponent, parentSuspense, isSVG, optimized);\r\n }\r\n }\r\n else {\r\n updateComponent(n1, n2, optimized);\r\n }\r\n };\r\n const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, isSVG, optimized) => {\r\n const instance = (initialVNode.component = createComponentInstance(initialVNode, parentComponent, parentSuspense));\r\n if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n registerHMR(instance);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(initialVNode);\r\n startMeasure(instance, `mount`);\r\n }\r\n // inject renderer internals for keepAlive\r\n if (isKeepAlive(initialVNode)) {\r\n instance.ctx.renderer = internals;\r\n }\r\n // resolve props and slots for setup context\r\n {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `init`);\r\n }\r\n setupComponent(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `init`);\r\n }\r\n }\r\n // setup() is async. This component relies on async logic to be resolved\r\n // before proceeding\r\n if (instance.asyncDep) {\r\n parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect);\r\n // Give it a placeholder if this is not hydration\r\n // TODO handle self-defined fallback\r\n if (!initialVNode.el) {\r\n const placeholder = (instance.subTree = createVNode(Comment));\r\n processCommentNode(null, placeholder, container, anchor);\r\n }\r\n return;\r\n }\r\n setupRenderEffect(instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n endMeasure(instance, `mount`);\r\n }\r\n };\r\n const updateComponent = (n1, n2, optimized) => {\r\n const instance = (n2.component = n1.component);\r\n if (shouldUpdateComponent(n1, n2, optimized)) {\r\n if (instance.asyncDep &&\r\n !instance.asyncResolved) {\r\n // async & still pending - just update props and slots\r\n // since the component's reactive effect for render isn't set-up yet\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(n2);\r\n }\r\n updateComponentPreRender(instance, n2, optimized);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n return;\r\n }\r\n else {\r\n // normal update\r\n instance.next = n2;\r\n // in case the child component is also queued, remove it to avoid\r\n // double updating the same child component in the same flush.\r\n invalidateJob(instance.update);\r\n // instance.update is the reactive effect.\r\n instance.update();\r\n }\r\n }\r\n else {\r\n // no update needed. just copy over properties\r\n n2.component = n1.component;\r\n n2.el = n1.el;\r\n instance.vnode = n2;\r\n }\r\n };\r\n const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized) => {\r\n const componentUpdateFn = () => {\r\n if (!instance.isMounted) {\r\n let vnodeHook;\r\n const { el, props } = initialVNode;\r\n const { bm, m, parent } = instance;\r\n const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);\r\n toggleRecurse(instance, false);\r\n // beforeMount hook\r\n if (bm) {\r\n invokeArrayFns(bm);\r\n }\r\n // onVnodeBeforeMount\r\n if (!isAsyncWrapperVNode &&\r\n (vnodeHook = props && props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHook, parent, initialVNode);\r\n }\r\n toggleRecurse(instance, true);\r\n if (el && hydrateNode) {\r\n // vnode has adopted host node - perform hydration instead of mount.\r\n const hydrateSubTree = () => {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n instance.subTree = renderComponentRoot(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `hydrate`);\r\n }\r\n hydrateNode(el, instance.subTree, instance, parentSuspense, null);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `hydrate`);\r\n }\r\n };\r\n if (isAsyncWrapperVNode) {\r\n initialVNode.type.__asyncLoader().then(\r\n // note: we are moving the render call into an async callback,\r\n // which means it won't track dependencies - but it's ok because\r\n // a server-rendered async wrapper is already in resolved state\r\n // and it will never need to change.\r\n () => !instance.isUnmounted && hydrateSubTree());\r\n }\r\n else {\r\n hydrateSubTree();\r\n }\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n const subTree = (instance.subTree = renderComponentRoot(instance));\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `patch`);\r\n }\r\n patch(null, subTree, container, anchor, instance, parentSuspense, isSVG);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `patch`);\r\n }\r\n initialVNode.el = subTree.el;\r\n }\r\n // mounted hook\r\n if (m) {\r\n queuePostRenderEffect(m, parentSuspense);\r\n }\r\n // onVnodeMounted\r\n if (!isAsyncWrapperVNode &&\r\n (vnodeHook = props && props.onVnodeMounted)) {\r\n const scopedInitialVNode = initialVNode;\r\n queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode), parentSuspense);\r\n }\r\n // activated hook for keep-alive roots.\r\n // #1742 activated hook must be accessed after first render\r\n // since the hook may be injected by a child keep-alive\r\n if (initialVNode.shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n instance.a && queuePostRenderEffect(instance.a, parentSuspense);\r\n }\r\n instance.isMounted = true;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentAdded(instance);\r\n }\r\n // #2458: deference mount-only object parameters to prevent memleaks\r\n initialVNode = container = anchor = null;\r\n }\r\n else {\r\n // updateComponent\r\n // This is triggered by mutation of component's own state (next: null)\r\n // OR parent calling processComponent (next: VNode)\r\n let { next, bu, u, parent, vnode } = instance;\r\n let originNext = next;\r\n let vnodeHook;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(next || instance.vnode);\r\n }\r\n // Disallow component effect recursion during pre-lifecycle hooks.\r\n toggleRecurse(instance, false);\r\n if (next) {\r\n next.el = vnode.el;\r\n updateComponentPreRender(instance, next, optimized);\r\n }\r\n else {\r\n next = vnode;\r\n }\r\n // beforeUpdate hook\r\n if (bu) {\r\n invokeArrayFns(bu);\r\n }\r\n // onVnodeBeforeUpdate\r\n if ((vnodeHook = next.props && next.props.onVnodeBeforeUpdate)) {\r\n invokeVNodeHook(vnodeHook, parent, next, vnode);\r\n }\r\n toggleRecurse(instance, true);\r\n // render\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n const nextTree = renderComponentRoot(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n const prevTree = instance.subTree;\r\n instance.subTree = nextTree;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `patch`);\r\n }\r\n patch(prevTree, nextTree, \r\n // parent may have changed if it's in a teleport\r\n hostParentNode(prevTree.el), \r\n // anchor may have changed if it's in a fragment\r\n getNextHostNode(prevTree), instance, parentSuspense, isSVG);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `patch`);\r\n }\r\n next.el = nextTree.el;\r\n if (originNext === null) {\r\n // self-triggered update. In case of HOC, update parent component\r\n // vnode el. HOC is indicated by parent instance's subTree pointing\r\n // to child component's vnode\r\n updateHOCHostEl(instance, nextTree.el);\r\n }\r\n // updated hook\r\n if (u) {\r\n queuePostRenderEffect(u, parentSuspense);\r\n }\r\n // onVnodeUpdated\r\n if ((vnodeHook = next.props && next.props.onVnodeUpdated)) {\r\n queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, next, vnode), parentSuspense);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentUpdated(instance);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n }\r\n };\r\n // create reactive effect for rendering\r\n const effect = (instance.effect = new ReactiveEffect(componentUpdateFn, () => queueJob(instance.update), instance.scope // track it in component's effect scope\r\n ));\r\n const update = (instance.update = effect.run.bind(effect));\r\n update.id = instance.uid;\r\n // allowRecurse\r\n // #1801, #2043 component render effects should allow recursive updates\r\n toggleRecurse(instance, true);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n effect.onTrack = instance.rtc\r\n ? e => invokeArrayFns(instance.rtc, e)\r\n : void 0;\r\n effect.onTrigger = instance.rtg\r\n ? e => invokeArrayFns(instance.rtg, e)\r\n : void 0;\r\n // @ts-ignore (for scheduler)\r\n update.ownerInstance = instance;\r\n }\r\n update();\r\n };\r\n const updateComponentPreRender = (instance, nextVNode, optimized) => {\r\n nextVNode.component = instance;\r\n const prevProps = instance.vnode.props;\r\n instance.vnode = nextVNode;\r\n instance.next = null;\r\n updateProps(instance, nextVNode.props, prevProps, optimized);\r\n updateSlots(instance, nextVNode.children, optimized);\r\n pauseTracking();\r\n // props update may have triggered pre-flush watchers.\r\n // flush them before the render update.\r\n flushPreFlushCbs(undefined, instance.update);\r\n resetTracking();\r\n };\r\n const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized = false) => {\r\n const c1 = n1 && n1.children;\r\n const prevShapeFlag = n1 ? n1.shapeFlag : 0;\r\n const c2 = n2.children;\r\n const { patchFlag, shapeFlag } = n2;\r\n // fast path\r\n if (patchFlag > 0) {\r\n if (patchFlag & 128 /* KEYED_FRAGMENT */) {\r\n // this could be either fully-keyed or mixed (some keyed some not)\r\n // presence of patchFlag means children are guaranteed to be arrays\r\n patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n return;\r\n }\r\n else if (patchFlag & 256 /* UNKEYED_FRAGMENT */) {\r\n // unkeyed\r\n patchUnkeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n return;\r\n }\r\n }\r\n // children has 3 possibilities: text, array or no children.\r\n if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n // text children fast path\r\n if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n unmountChildren(c1, parentComponent, parentSuspense);\r\n }\r\n if (c2 !== c1) {\r\n hostSetElementText(container, c2);\r\n }\r\n }\r\n else {\r\n if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n // prev children was array\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n // two arrays, cannot assume anything, do full diff\r\n patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n // no new children, just unmount old\r\n unmountChildren(c1, parentComponent, parentSuspense, true);\r\n }\r\n }\r\n else {\r\n // prev children was text OR null\r\n // new children is array OR null\r\n if (prevShapeFlag & 8 /* TEXT_CHILDREN */) {\r\n hostSetElementText(container, '');\r\n }\r\n // mount new if array\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n }\r\n }\r\n };\r\n const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n c1 = c1 || EMPTY_ARR;\r\n c2 = c2 || EMPTY_ARR;\r\n const oldLength = c1.length;\r\n const newLength = c2.length;\r\n const commonLength = Math.min(oldLength, newLength);\r\n let i;\r\n for (i = 0; i < commonLength; i++) {\r\n const nextChild = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n patch(c1[i], nextChild, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n if (oldLength > newLength) {\r\n // remove old\r\n unmountChildren(c1, parentComponent, parentSuspense, true, false, commonLength);\r\n }\r\n else {\r\n // mount new\r\n mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, commonLength);\r\n }\r\n };\r\n // can be all-keyed or mixed\r\n const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n let i = 0;\r\n const l2 = c2.length;\r\n let e1 = c1.length - 1; // prev ending index\r\n let e2 = l2 - 1; // next ending index\r\n // 1. sync from start\r\n // (a b) c\r\n // (a b) d e\r\n while (i <= e1 && i <= e2) {\r\n const n1 = c1[i];\r\n const n2 = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n if (isSameVNodeType(n1, n2)) {\r\n patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n break;\r\n }\r\n i++;\r\n }\r\n // 2. sync from end\r\n // a (b c)\r\n // d e (b c)\r\n while (i <= e1 && i <= e2) {\r\n const n1 = c1[e1];\r\n const n2 = (c2[e2] = optimized\r\n ? cloneIfMounted(c2[e2])\r\n : normalizeVNode(c2[e2]));\r\n if (isSameVNodeType(n1, n2)) {\r\n patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n break;\r\n }\r\n e1--;\r\n e2--;\r\n }\r\n // 3. common sequence + mount\r\n // (a b)\r\n // (a b) c\r\n // i = 2, e1 = 1, e2 = 2\r\n // (a b)\r\n // c (a b)\r\n // i = 0, e1 = -1, e2 = 0\r\n if (i > e1) {\r\n if (i <= e2) {\r\n const nextPos = e2 + 1;\r\n const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;\r\n while (i <= e2) {\r\n patch(null, (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i])), container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n i++;\r\n }\r\n }\r\n }\r\n // 4. common sequence + unmount\r\n // (a b) c\r\n // (a b)\r\n // i = 2, e1 = 2, e2 = 1\r\n // a (b c)\r\n // (b c)\r\n // i = 0, e1 = 0, e2 = -1\r\n else if (i > e2) {\r\n while (i <= e1) {\r\n unmount(c1[i], parentComponent, parentSuspense, true);\r\n i++;\r\n }\r\n }\r\n // 5. unknown sequence\r\n // [i ... e1 + 1]: a b [c d e] f g\r\n // [i ... e2 + 1]: a b [e d c h] f g\r\n // i = 2, e1 = 4, e2 = 5\r\n else {\r\n const s1 = i; // prev starting index\r\n const s2 = i; // next starting index\r\n // 5.1 build key:index map for newChildren\r\n const keyToNewIndexMap = new Map();\r\n for (i = s2; i <= e2; i++) {\r\n const nextChild = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n if (nextChild.key != null) {\r\n if ((process.env.NODE_ENV !== 'production') && keyToNewIndexMap.has(nextChild.key)) {\r\n warn(`Duplicate keys found during update:`, JSON.stringify(nextChild.key), `Make sure keys are unique.`);\r\n }\r\n keyToNewIndexMap.set(nextChild.key, i);\r\n }\r\n }\r\n // 5.2 loop through old children left to be patched and try to patch\r\n // matching nodes & remove nodes that are no longer present\r\n let j;\r\n let patched = 0;\r\n const toBePatched = e2 - s2 + 1;\r\n let moved = false;\r\n // used to track whether any node has moved\r\n let maxNewIndexSoFar = 0;\r\n // works as Map<newIndex, oldIndex>\r\n // Note that oldIndex is offset by +1\r\n // and oldIndex = 0 is a special value indicating the new node has\r\n // no corresponding old node.\r\n // used for determining longest stable subsequence\r\n const newIndexToOldIndexMap = new Array(toBePatched);\r\n for (i = 0; i < toBePatched; i++)\r\n newIndexToOldIndexMap[i] = 0;\r\n for (i = s1; i <= e1; i++) {\r\n const prevChild = c1[i];\r\n if (patched >= toBePatched) {\r\n // all new children have been patched so this can only be a removal\r\n unmount(prevChild, parentComponent, parentSuspense, true);\r\n continue;\r\n }\r\n let newIndex;\r\n if (prevChild.key != null) {\r\n newIndex = keyToNewIndexMap.get(prevChild.key);\r\n }\r\n else {\r\n // key-less node, try to locate a key-less node of the same type\r\n for (j = s2; j <= e2; j++) {\r\n if (newIndexToOldIndexMap[j - s2] === 0 &&\r\n isSameVNodeType(prevChild, c2[j])) {\r\n newIndex = j;\r\n break;\r\n }\r\n }\r\n }\r\n if (newIndex === undefined) {\r\n unmount(prevChild, parentComponent, parentSuspense, true);\r\n }\r\n else {\r\n newIndexToOldIndexMap[newIndex - s2] = i + 1;\r\n if (newIndex >= maxNewIndexSoFar) {\r\n maxNewIndexSoFar = newIndex;\r\n }\r\n else {\r\n moved = true;\r\n }\r\n patch(prevChild, c2[newIndex], container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n patched++;\r\n }\r\n }\r\n // 5.3 move and mount\r\n // generate longest stable subsequence only when nodes have moved\r\n const increasingNewIndexSequence = moved\r\n ? getSequence(newIndexToOldIndexMap)\r\n : EMPTY_ARR;\r\n j = increasingNewIndexSequence.length - 1;\r\n // looping backwards so that we can use last patched node as anchor\r\n for (i = toBePatched - 1; i >= 0; i--) {\r\n const nextIndex = s2 + i;\r\n const nextChild = c2[nextIndex];\r\n const anchor = nextIndex + 1 < l2 ? c2[nextIndex + 1].el : parentAnchor;\r\n if (newIndexToOldIndexMap[i] === 0) {\r\n // mount new\r\n patch(null, nextChild, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (moved) {\r\n // move if:\r\n // There is no stable subsequence (e.g. a reverse)\r\n // OR current node is not among the stable sequence\r\n if (j < 0 || i !== increasingNewIndexSequence[j]) {\r\n move(nextChild, container, anchor, 2 /* REORDER */);\r\n }\r\n else {\r\n j--;\r\n }\r\n }\r\n }\r\n }\r\n };\r\n const move = (vnode, container, anchor, moveType, parentSuspense = null) => {\r\n const { el, type, transition, children, shapeFlag } = vnode;\r\n if (shapeFlag & 6 /* COMPONENT */) {\r\n move(vnode.component.subTree, container, anchor, moveType);\r\n return;\r\n }\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.suspense.move(container, anchor, moveType);\r\n return;\r\n }\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n type.move(vnode, container, anchor, internals);\r\n return;\r\n }\r\n if (type === Fragment) {\r\n hostInsert(el, container, anchor);\r\n for (let i = 0; i < children.length; i++) {\r\n move(children[i], container, anchor, moveType);\r\n }\r\n hostInsert(vnode.anchor, container, anchor);\r\n return;\r\n }\r\n if (type === Static) {\r\n moveStaticNode(vnode, container, anchor);\r\n return;\r\n }\r\n // single nodes\r\n const needTransition = moveType !== 2 /* REORDER */ &&\r\n shapeFlag & 1 /* ELEMENT */ &&\r\n transition;\r\n if (needTransition) {\r\n if (moveType === 0 /* ENTER */) {\r\n transition.beforeEnter(el);\r\n hostInsert(el, container, anchor);\r\n queuePostRenderEffect(() => transition.enter(el), parentSuspense);\r\n }\r\n else {\r\n const { leave, delayLeave, afterLeave } = transition;\r\n const remove = () => hostInsert(el, container, anchor);\r\n const performLeave = () => {\r\n leave(el, () => {\r\n remove();\r\n afterLeave && afterLeave();\r\n });\r\n };\r\n if (delayLeave) {\r\n delayLeave(el, remove, performLeave);\r\n }\r\n else {\r\n performLeave();\r\n }\r\n }\r\n }\r\n else {\r\n hostInsert(el, container, anchor);\r\n }\r\n };\r\n const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {\r\n const { type, props, ref, children, dynamicChildren, shapeFlag, patchFlag, dirs } = vnode;\r\n // unset ref\r\n if (ref != null) {\r\n setRef(ref, null, parentSuspense, vnode, true);\r\n }\r\n if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n parentComponent.ctx.deactivate(vnode);\r\n return;\r\n }\r\n const shouldInvokeDirs = shapeFlag & 1 /* ELEMENT */ && dirs;\r\n const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);\r\n let vnodeHook;\r\n if (shouldInvokeVnodeHook &&\r\n (vnodeHook = props && props.onVnodeBeforeUnmount)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n }\r\n if (shapeFlag & 6 /* COMPONENT */) {\r\n unmountComponent(vnode.component, parentSuspense, doRemove);\r\n }\r\n else {\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.suspense.unmount(parentSuspense, doRemove);\r\n return;\r\n }\r\n if (shouldInvokeDirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeUnmount');\r\n }\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n vnode.type.remove(vnode, parentComponent, parentSuspense, optimized, internals, doRemove);\r\n }\r\n else if (dynamicChildren &&\r\n // #1153: fast path should not be taken for non-stable (v-for) fragments\r\n (type !== Fragment ||\r\n (patchFlag > 0 && patchFlag & 64 /* STABLE_FRAGMENT */))) {\r\n // fast path for block nodes: only need to unmount dynamic children.\r\n unmountChildren(dynamicChildren, parentComponent, parentSuspense, false, true);\r\n }\r\n else if ((type === Fragment &&\r\n patchFlag &\r\n (128 /* KEYED_FRAGMENT */ | 256 /* UNKEYED_FRAGMENT */)) ||\r\n (!optimized && shapeFlag & 16 /* ARRAY_CHILDREN */)) {\r\n unmountChildren(children, parentComponent, parentSuspense);\r\n }\r\n if (doRemove) {\r\n remove(vnode);\r\n }\r\n }\r\n if ((shouldInvokeVnodeHook &&\r\n (vnodeHook = props && props.onVnodeUnmounted)) ||\r\n shouldInvokeDirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n shouldInvokeDirs &&\r\n invokeDirectiveHook(vnode, null, parentComponent, 'unmounted');\r\n }, parentSuspense);\r\n }\r\n };\r\n const remove = vnode => {\r\n const { type, el, anchor, transition } = vnode;\r\n if (type === Fragment) {\r\n removeFragment(el, anchor);\r\n return;\r\n }\r\n if (type === Static) {\r\n removeStaticNode(vnode);\r\n return;\r\n }\r\n const performRemove = () => {\r\n hostRemove(el);\r\n if (transition && !transition.persisted && transition.afterLeave) {\r\n transition.afterLeave();\r\n }\r\n };\r\n if (vnode.shapeFlag & 1 /* ELEMENT */ &&\r\n transition &&\r\n !transition.persisted) {\r\n const { leave, delayLeave } = transition;\r\n const performLeave = () => leave(el, performRemove);\r\n if (delayLeave) {\r\n delayLeave(vnode.el, performRemove, performLeave);\r\n }\r\n else {\r\n performLeave();\r\n }\r\n }\r\n else {\r\n performRemove();\r\n }\r\n };\r\n const removeFragment = (cur, end) => {\r\n // For fragments, directly remove all contained DOM nodes.\r\n // (fragment child nodes cannot have transition)\r\n let next;\r\n while (cur !== end) {\r\n next = hostNextSibling(cur);\r\n hostRemove(cur);\r\n cur = next;\r\n }\r\n hostRemove(end);\r\n };\r\n const unmountComponent = (instance, parentSuspense, doRemove) => {\r\n if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n unregisterHMR(instance);\r\n }\r\n const { bum, scope, update, subTree, um } = instance;\r\n // beforeUnmount hook\r\n if (bum) {\r\n invokeArrayFns(bum);\r\n }\r\n // stop effects in component scope\r\n scope.stop();\r\n // update may be null if a component is unmounted before its async\r\n // setup has resolved.\r\n if (update) {\r\n // so that scheduler will no longer invoke it\r\n update.active = false;\r\n unmount(subTree, instance, parentSuspense, doRemove);\r\n }\r\n // unmounted hook\r\n if (um) {\r\n queuePostRenderEffect(um, parentSuspense);\r\n }\r\n queuePostRenderEffect(() => {\r\n instance.isUnmounted = true;\r\n }, parentSuspense);\r\n // A component with async dep inside a pending suspense is unmounted before\r\n // its async dep resolves. This should remove the dep from the suspense, and\r\n // cause the suspense to resolve immediately if that was the last dep.\r\n if (parentSuspense &&\r\n parentSuspense.pendingBranch &&\r\n !parentSuspense.isUnmounted &&\r\n instance.asyncDep &&\r\n !instance.asyncResolved &&\r\n instance.suspenseId === parentSuspense.pendingId) {\r\n parentSuspense.deps--;\r\n if (parentSuspense.deps === 0) {\r\n parentSuspense.resolve();\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentRemoved(instance);\r\n }\r\n };\r\n const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {\r\n for (let i = start; i < children.length; i++) {\r\n unmount(children[i], parentComponent, parentSuspense, doRemove, optimized);\r\n }\r\n };\r\n const getNextHostNode = vnode => {\r\n if (vnode.shapeFlag & 6 /* COMPONENT */) {\r\n return getNextHostNode(vnode.component.subTree);\r\n }\r\n if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n return vnode.suspense.next();\r\n }\r\n return hostNextSibling((vnode.anchor || vnode.el));\r\n };\r\n const render = (vnode, container, isSVG) => {\r\n if (vnode == null) {\r\n if (container._vnode) {\r\n unmount(container._vnode, null, null, true);\r\n }\r\n }\r\n else {\r\n patch(container._vnode || null, vnode, container, null, null, null, isSVG);\r\n }\r\n flushPostFlushCbs();\r\n container._vnode = vnode;\r\n };\r\n const internals = {\r\n p: patch,\r\n um: unmount,\r\n m: move,\r\n r: remove,\r\n mt: mountComponent,\r\n mc: mountChildren,\r\n pc: patchChildren,\r\n pbc: patchBlockChildren,\r\n n: getNextHostNode,\r\n o: options\r\n };\r\n let hydrate;\r\n let hydrateNode;\r\n if (createHydrationFns) {\r\n [hydrate, hydrateNode] = createHydrationFns(internals);\r\n }\r\n return {\r\n render,\r\n hydrate,\r\n createApp: createAppAPI(render, hydrate)\r\n };\r\n}\r\nfunction toggleRecurse({ effect, update }, allowed) {\r\n effect.allowRecurse = update.allowRecurse = allowed;\r\n}\r\n/**\r\n * #1156\r\n * When a component is HMR-enabled, we need to make sure that all static nodes\r\n * inside a block also inherit the DOM element from the previous tree so that\r\n * HMR updates (which are full updates) can retrieve the element for patching.\r\n *\r\n * #2080\r\n * Inside keyed `template` fragment static children, if a fragment is moved,\r\n * the children will always be moved. Therefore, in order to ensure correct move\r\n * position, el should be inherited from previous nodes.\r\n */\r\nfunction traverseStaticChildren(n1, n2, shallow = false) {\r\n const ch1 = n1.children;\r\n const ch2 = n2.children;\r\n if (isArray(ch1) && isArray(ch2)) {\r\n for (let i = 0; i < ch1.length; i++) {\r\n // this is only called in the optimized path so array children are\r\n // guaranteed to be vnodes\r\n const c1 = ch1[i];\r\n let c2 = ch2[i];\r\n if (c2.shapeFlag & 1 /* ELEMENT */ && !c2.dynamicChildren) {\r\n if (c2.patchFlag <= 0 || c2.patchFlag === 32 /* HYDRATE_EVENTS */) {\r\n c2 = ch2[i] = cloneIfMounted(ch2[i]);\r\n c2.el = c1.el;\r\n }\r\n if (!shallow)\r\n traverseStaticChildren(c1, c2);\r\n }\r\n // also inherit for comment nodes, but not placeholders (e.g. v-if which\r\n // would have received .el during block patch)\r\n if ((process.env.NODE_ENV !== 'production') && c2.type === Comment && !c2.el) {\r\n c2.el = c1.el;\r\n }\r\n }\r\n }\r\n}\r\n// https://en.wikipedia.org/wiki/Longest_increasing_subsequence\r\nfunction getSequence(arr) {\r\n const p = arr.slice();\r\n const result = [0];\r\n let i, j, u, v, c;\r\n const len = arr.length;\r\n for (i = 0; i < len; i++) {\r\n const arrI = arr[i];\r\n if (arrI !== 0) {\r\n j = result[result.length - 1];\r\n if (arr[j] < arrI) {\r\n p[i] = j;\r\n result.push(i);\r\n continue;\r\n }\r\n u = 0;\r\n v = result.length - 1;\r\n while (u < v) {\r\n c = (u + v) >> 1;\r\n if (arr[result[c]] < arrI) {\r\n u = c + 1;\r\n }\r\n else {\r\n v = c;\r\n }\r\n }\r\n if (arrI < arr[result[u]]) {\r\n if (u > 0) {\r\n p[i] = result[u - 1];\r\n }\r\n result[u] = i;\r\n }\r\n }\r\n }\r\n u = result.length;\r\n v = result[u - 1];\r\n while (u-- > 0) {\r\n result[u] = v;\r\n v = p[v];\r\n }\r\n return result;\r\n}\n\nconst isTeleport = (type) => type.__isTeleport;\r\nconst isTeleportDisabled = (props) => props && (props.disabled || props.disabled === '');\r\nconst isTargetSVG = (target) => typeof SVGElement !== 'undefined' && target instanceof SVGElement;\r\nconst resolveTarget = (props, select) => {\r\n const targetSelector = props && props.to;\r\n if (isString(targetSelector)) {\r\n if (!select) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Current renderer does not support string target for Teleports. ` +\r\n `(missing querySelector renderer option)`);\r\n return null;\r\n }\r\n else {\r\n const target = select(targetSelector);\r\n if (!target) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Failed to locate Teleport target with selector \"${targetSelector}\". ` +\r\n `Note the target element must exist before the component is mounted - ` +\r\n `i.e. the target cannot be rendered by the component itself, and ` +\r\n `ideally should be outside of the entire Vue component tree.`);\r\n }\r\n return target;\r\n }\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && !targetSelector && !isTeleportDisabled(props)) {\r\n warn(`Invalid Teleport target: ${targetSelector}`);\r\n }\r\n return targetSelector;\r\n }\r\n};\r\nconst TeleportImpl = {\r\n __isTeleport: true,\r\n process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals) {\r\n const { mc: mountChildren, pc: patchChildren, pbc: patchBlockChildren, o: { insert, querySelector, createText, createComment } } = internals;\r\n const disabled = isTeleportDisabled(n2.props);\r\n let { shapeFlag, children, dynamicChildren } = n2;\r\n // #3302\r\n // HMR updated, force full diff\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n if (n1 == null) {\r\n // insert anchors in the main view\r\n const placeholder = (n2.el = (process.env.NODE_ENV !== 'production')\r\n ? createComment('teleport start')\r\n : createText(''));\r\n const mainAnchor = (n2.anchor = (process.env.NODE_ENV !== 'production')\r\n ? createComment('teleport end')\r\n : createText(''));\r\n insert(placeholder, container, anchor);\r\n insert(mainAnchor, container, anchor);\r\n const target = (n2.target = resolveTarget(n2.props, querySelector));\r\n const targetAnchor = (n2.targetAnchor = createText(''));\r\n if (target) {\r\n insert(targetAnchor, target);\r\n // #2652 we could be teleporting from a non-SVG tree into an SVG tree\r\n isSVG = isSVG || isTargetSVG(target);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && !disabled) {\r\n warn('Invalid Teleport target on mount:', target, `(${typeof target})`);\r\n }\r\n const mount = (container, anchor) => {\r\n // Teleport *always* has Array children. This is enforced in both the\r\n // compiler and vnode children normalization.\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n if (disabled) {\r\n mount(container, mainAnchor);\r\n }\r\n else if (target) {\r\n mount(target, targetAnchor);\r\n }\r\n }\r\n else {\r\n // update content\r\n n2.el = n1.el;\r\n const mainAnchor = (n2.anchor = n1.anchor);\r\n const target = (n2.target = n1.target);\r\n const targetAnchor = (n2.targetAnchor = n1.targetAnchor);\r\n const wasDisabled = isTeleportDisabled(n1.props);\r\n const currentContainer = wasDisabled ? container : target;\r\n const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;\r\n isSVG = isSVG || isTargetSVG(target);\r\n if (dynamicChildren) {\r\n // fast path when the teleport happens to be a block root\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, currentContainer, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n // even in block tree mode we need to make sure all root-level nodes\r\n // in the teleport inherit previous DOM references so that they can\r\n // be moved in future patches.\r\n traverseStaticChildren(n1, n2, true);\r\n }\r\n else if (!optimized) {\r\n patchChildren(n1, n2, currentContainer, currentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, false);\r\n }\r\n if (disabled) {\r\n if (!wasDisabled) {\r\n // enabled -> disabled\r\n // move into main container\r\n moveTeleport(n2, container, mainAnchor, internals, 1 /* TOGGLE */);\r\n }\r\n }\r\n else {\r\n // target changed\r\n if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {\r\n const nextTarget = (n2.target = resolveTarget(n2.props, querySelector));\r\n if (nextTarget) {\r\n moveTeleport(n2, nextTarget, null, internals, 0 /* TARGET_CHANGE */);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid Teleport target on update:', target, `(${typeof target})`);\r\n }\r\n }\r\n else if (wasDisabled) {\r\n // disabled -> enabled\r\n // move into teleport target\r\n moveTeleport(n2, target, targetAnchor, internals, 1 /* TOGGLE */);\r\n }\r\n }\r\n }\r\n },\r\n remove(vnode, parentComponent, parentSuspense, optimized, { um: unmount, o: { remove: hostRemove } }, doRemove) {\r\n const { shapeFlag, children, anchor, targetAnchor, target, props } = vnode;\r\n if (target) {\r\n hostRemove(targetAnchor);\r\n }\r\n // an unmounted teleport should always remove its children if not disabled\r\n if (doRemove || !isTeleportDisabled(props)) {\r\n hostRemove(anchor);\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n unmount(child, parentComponent, parentSuspense, true, !!child.dynamicChildren);\r\n }\r\n }\r\n }\r\n },\r\n move: moveTeleport,\r\n hydrate: hydrateTeleport\r\n};\r\nfunction moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }, moveType = 2 /* REORDER */) {\r\n // move target anchor if this is a target change.\r\n if (moveType === 0 /* TARGET_CHANGE */) {\r\n insert(vnode.targetAnchor, container, parentAnchor);\r\n }\r\n const { el, anchor, shapeFlag, children, props } = vnode;\r\n const isReorder = moveType === 2 /* REORDER */;\r\n // move main view anchor if this is a re-order.\r\n if (isReorder) {\r\n insert(el, container, parentAnchor);\r\n }\r\n // if this is a re-order and teleport is enabled (content is in target)\r\n // do not move children. So the opposite is: only move children if this\r\n // is not a reorder, or the teleport is disabled\r\n if (!isReorder || isTeleportDisabled(props)) {\r\n // Teleport has either Array children or no children.\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n for (let i = 0; i < children.length; i++) {\r\n move(children[i], container, parentAnchor, 2 /* REORDER */);\r\n }\r\n }\r\n }\r\n // move main view anchor if this is a re-order.\r\n if (isReorder) {\r\n insert(anchor, container, parentAnchor);\r\n }\r\n}\r\nfunction hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, { o: { nextSibling, parentNode, querySelector } }, hydrateChildren) {\r\n const target = (vnode.target = resolveTarget(vnode.props, querySelector));\r\n if (target) {\r\n // if multiple teleports rendered to the same target element, we need to\r\n // pick up from where the last teleport finished instead of the first node\r\n const targetNode = target._lpa || target.firstChild;\r\n if (vnode.shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n if (isTeleportDisabled(vnode.props)) {\r\n vnode.anchor = hydrateChildren(nextSibling(node), vnode, parentNode(node), parentComponent, parentSuspense, slotScopeIds, optimized);\r\n vnode.targetAnchor = targetNode;\r\n }\r\n else {\r\n vnode.anchor = nextSibling(node);\r\n vnode.targetAnchor = hydrateChildren(targetNode, vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n target._lpa =\r\n vnode.targetAnchor && nextSibling(vnode.targetAnchor);\r\n }\r\n }\r\n return vnode.anchor && nextSibling(vnode.anchor);\r\n}\r\n// Force-casted public typing for h and TSX props inference\r\nconst Teleport = TeleportImpl;\n\nconst COMPONENTS = 'components';\r\nconst DIRECTIVES = 'directives';\r\n/**\r\n * @private\r\n */\r\nfunction resolveComponent(name, maybeSelfReference) {\r\n return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;\r\n}\r\nconst NULL_DYNAMIC_COMPONENT = Symbol();\r\n/**\r\n * @private\r\n */\r\nfunction resolveDynamicComponent(component) {\r\n if (isString(component)) {\r\n return resolveAsset(COMPONENTS, component, false) || component;\r\n }\r\n else {\r\n // invalid types will fallthrough to createVNode and raise warning\r\n return (component || NULL_DYNAMIC_COMPONENT);\r\n }\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction resolveDirective(name) {\r\n return resolveAsset(DIRECTIVES, name);\r\n}\r\n// implementation\r\nfunction resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {\r\n const instance = currentRenderingInstance || currentInstance;\r\n if (instance) {\r\n const Component = instance.type;\r\n // explicit self name has highest priority\r\n if (type === COMPONENTS) {\r\n const selfName = getComponentName(Component);\r\n if (selfName &&\r\n (selfName === name ||\r\n selfName === camelize(name) ||\r\n selfName === capitalize(camelize(name)))) {\r\n return Component;\r\n }\r\n }\r\n const res = \r\n // local registration\r\n // check instance[type] first which is resolved for options API\r\n resolve(instance[type] || Component[type], name) ||\r\n // global registration\r\n resolve(instance.appContext[type], name);\r\n if (!res && maybeSelfReference) {\r\n // fallback to implicit self-reference\r\n return Component;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && warnMissing && !res) {\r\n const extra = type === COMPONENTS\r\n ? `\\nIf this is a native custom element, make sure to exclude it from ` +\r\n `component resolution via compilerOptions.isCustomElement.`\r\n : ``;\r\n warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);\r\n }\r\n return res;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`resolve${capitalize(type.slice(0, -1))} ` +\r\n `can only be used in render() or setup().`);\r\n }\r\n}\r\nfunction resolve(registry, name) {\r\n return (registry &&\r\n (registry[name] ||\r\n registry[camelize(name)] ||\r\n registry[capitalize(camelize(name))]));\r\n}\n\nconst Fragment = Symbol((process.env.NODE_ENV !== 'production') ? 'Fragment' : undefined);\r\nconst Text = Symbol((process.env.NODE_ENV !== 'production') ? 'Text' : undefined);\r\nconst Comment = Symbol((process.env.NODE_ENV !== 'production') ? 'Comment' : undefined);\r\nconst Static = Symbol((process.env.NODE_ENV !== 'production') ? 'Static' : undefined);\r\n// Since v-if and v-for are the two possible ways node structure can dynamically\r\n// change, once we consider v-if branches and each v-for fragment a block, we\r\n// can divide a template into nested blocks, and within each block the node\r\n// structure would be stable. This allows us to skip most children diffing\r\n// and only worry about the dynamic nodes (indicated by patch flags).\r\nconst blockStack = [];\r\nlet currentBlock = null;\r\n/**\r\n * Open a block.\r\n * This must be called before `createBlock`. It cannot be part of `createBlock`\r\n * because the children of the block are evaluated before `createBlock` itself\r\n * is called. The generated code typically looks like this:\r\n *\r\n * ```js\r\n * function render() {\r\n * return (openBlock(),createBlock('div', null, [...]))\r\n * }\r\n * ```\r\n * disableTracking is true when creating a v-for fragment block, since a v-for\r\n * fragment always diffs its children.\r\n *\r\n * @private\r\n */\r\nfunction openBlock(disableTracking = false) {\r\n blockStack.push((currentBlock = disableTracking ? null : []));\r\n}\r\nfunction closeBlock() {\r\n blockStack.pop();\r\n currentBlock = blockStack[blockStack.length - 1] || null;\r\n}\r\n// Whether we should be tracking dynamic child nodes inside a block.\r\n// Only tracks when this value is > 0\r\n// We are not using a simple boolean because this value may need to be\r\n// incremented/decremented by nested usage of v-once (see below)\r\nlet isBlockTreeEnabled = 1;\r\n/**\r\n * Block tracking sometimes needs to be disabled, for example during the\r\n * creation of a tree that needs to be cached by v-once. The compiler generates\r\n * code like this:\r\n *\r\n * ``` js\r\n * _cache[1] || (\r\n * setBlockTracking(-1),\r\n * _cache[1] = createVNode(...),\r\n * setBlockTracking(1),\r\n * _cache[1]\r\n * )\r\n * ```\r\n *\r\n * @private\r\n */\r\nfunction setBlockTracking(value) {\r\n isBlockTreeEnabled += value;\r\n}\r\nfunction setupBlock(vnode) {\r\n // save current block children on the block vnode\r\n vnode.dynamicChildren =\r\n isBlockTreeEnabled > 0 ? currentBlock || EMPTY_ARR : null;\r\n // close block\r\n closeBlock();\r\n // a block is always going to be patched, so track it as a child of its\r\n // parent block\r\n if (isBlockTreeEnabled > 0 && currentBlock) {\r\n currentBlock.push(vnode);\r\n }\r\n return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {\r\n return setupBlock(createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, true /* isBlock */));\r\n}\r\n/**\r\n * Create a block root vnode. Takes the same exact arguments as `createVNode`.\r\n * A block root keeps track of dynamic nodes within the block in the\r\n * `dynamicChildren` array.\r\n *\r\n * @private\r\n */\r\nfunction createBlock(type, props, children, patchFlag, dynamicProps) {\r\n return setupBlock(createVNode(type, props, children, patchFlag, dynamicProps, true /* isBlock: prevent a block from tracking itself */));\r\n}\r\nfunction isVNode(value) {\r\n return value ? value.__v_isVNode === true : false;\r\n}\r\nfunction isSameVNodeType(n1, n2) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n n2.shapeFlag & 6 /* COMPONENT */ &&\r\n hmrDirtyComponents.has(n2.type)) {\r\n // HMR only: if the component has been hot-updated, force a reload.\r\n return false;\r\n }\r\n return n1.type === n2.type && n1.key === n2.key;\r\n}\r\nlet vnodeArgsTransformer;\r\n/**\r\n * Internal API for registering an arguments transform for createVNode\r\n * used for creating stubs in the test-utils\r\n * It is *internal* but needs to be exposed for test-utils to pick up proper\r\n * typings\r\n */\r\nfunction transformVNodeArgs(transformer) {\r\n vnodeArgsTransformer = transformer;\r\n}\r\nconst createVNodeWithArgsTransform = (...args) => {\r\n return _createVNode(...(vnodeArgsTransformer\r\n ? vnodeArgsTransformer(args, currentRenderingInstance)\r\n : args));\r\n};\r\nconst InternalObjectKey = `__vInternal`;\r\nconst normalizeKey = ({ key }) => key != null ? key : null;\r\nconst normalizeRef = ({ ref, ref_key, ref_for }) => {\r\n return (ref != null\r\n ? isString(ref) || isRef(ref) || isFunction(ref)\r\n ? { i: currentRenderingInstance, r: ref, k: ref_key, f: !!ref_for }\r\n : ref\r\n : null);\r\n};\r\nfunction createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1 /* ELEMENT */, isBlockNode = false, needFullChildrenNormalization = false) {\r\n const vnode = {\r\n __v_isVNode: true,\r\n __v_skip: true,\r\n type,\r\n props,\r\n key: props && normalizeKey(props),\r\n ref: props && normalizeRef(props),\r\n scopeId: currentScopeId,\r\n slotScopeIds: null,\r\n children,\r\n component: null,\r\n suspense: null,\r\n ssContent: null,\r\n ssFallback: null,\r\n dirs: null,\r\n transition: null,\r\n el: null,\r\n anchor: null,\r\n target: null,\r\n targetAnchor: null,\r\n staticCount: 0,\r\n shapeFlag,\r\n patchFlag,\r\n dynamicProps,\r\n dynamicChildren: null,\r\n appContext: null\r\n };\r\n if (needFullChildrenNormalization) {\r\n normalizeChildren(vnode, children);\r\n // normalize suspense children\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n type.normalize(vnode);\r\n }\r\n }\r\n else if (children) {\r\n // compiled element vnode - if children is passed, only possible types are\r\n // string or Array.\r\n vnode.shapeFlag |= isString(children)\r\n ? 8 /* TEXT_CHILDREN */\r\n : 16 /* ARRAY_CHILDREN */;\r\n }\r\n // validate key\r\n if ((process.env.NODE_ENV !== 'production') && vnode.key !== vnode.key) {\r\n warn(`VNode created with invalid key (NaN). VNode type:`, vnode.type);\r\n }\r\n // track vnode for block tree\r\n if (isBlockTreeEnabled > 0 &&\r\n // avoid a block node from tracking itself\r\n !isBlockNode &&\r\n // has current parent block\r\n currentBlock &&\r\n // presence of a patch flag indicates this node needs patching on updates.\r\n // component nodes also should always be patched, because even if the\r\n // component doesn't need to update, it needs to persist the instance on to\r\n // the next vnode so that it can be properly unmounted later.\r\n (vnode.patchFlag > 0 || shapeFlag & 6 /* COMPONENT */) &&\r\n // the EVENTS flag is only for hydration and if it is the only flag, the\r\n // vnode should not be considered dynamic due to handler caching.\r\n vnode.patchFlag !== 32 /* HYDRATE_EVENTS */) {\r\n currentBlock.push(vnode);\r\n }\r\n return vnode;\r\n}\r\nconst createVNode = ((process.env.NODE_ENV !== 'production') ? createVNodeWithArgsTransform : _createVNode);\r\nfunction _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {\r\n if (!type || type === NULL_DYNAMIC_COMPONENT) {\r\n if ((process.env.NODE_ENV !== 'production') && !type) {\r\n warn(`Invalid vnode type when creating vnode: ${type}.`);\r\n }\r\n type = Comment;\r\n }\r\n if (isVNode(type)) {\r\n // createVNode receiving an existing vnode. This happens in cases like\r\n // <component :is=\"vnode\"/>\r\n // #2078 make sure to merge refs during the clone instead of overwriting it\r\n const cloned = cloneVNode(type, props, true /* mergeRef: true */);\r\n if (children) {\r\n normalizeChildren(cloned, children);\r\n }\r\n return cloned;\r\n }\r\n // class component normalization.\r\n if (isClassComponent(type)) {\r\n type = type.__vccOpts;\r\n }\r\n // class & style normalization.\r\n if (props) {\r\n // for reactive or proxy objects, we need to clone it to enable mutation.\r\n props = guardReactiveProps(props);\r\n let { class: klass, style } = props;\r\n if (klass && !isString(klass)) {\r\n props.class = normalizeClass(klass);\r\n }\r\n if (isObject(style)) {\r\n // reactive state objects need to be cloned since they are likely to be\r\n // mutated\r\n if (isProxy(style) && !isArray(style)) {\r\n style = extend({}, style);\r\n }\r\n props.style = normalizeStyle(style);\r\n }\r\n }\r\n // encode the vnode type information into a bitmap\r\n const shapeFlag = isString(type)\r\n ? 1 /* ELEMENT */\r\n : isSuspense(type)\r\n ? 128 /* SUSPENSE */\r\n : isTeleport(type)\r\n ? 64 /* TELEPORT */\r\n : isObject(type)\r\n ? 4 /* STATEFUL_COMPONENT */\r\n : isFunction(type)\r\n ? 2 /* FUNCTIONAL_COMPONENT */\r\n : 0;\r\n if ((process.env.NODE_ENV !== 'production') && shapeFlag & 4 /* STATEFUL_COMPONENT */ && isProxy(type)) {\r\n type = toRaw(type);\r\n warn(`Vue received a Component which was made a reactive object. This can ` +\r\n `lead to unnecessary performance overhead, and should be avoided by ` +\r\n `marking the component with \\`markRaw\\` or using \\`shallowRef\\` ` +\r\n `instead of \\`ref\\`.`, `\\nComponent that was made reactive: `, type);\r\n }\r\n return createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, isBlockNode, true);\r\n}\r\nfunction guardReactiveProps(props) {\r\n if (!props)\r\n return null;\r\n return isProxy(props) || InternalObjectKey in props\r\n ? extend({}, props)\r\n : props;\r\n}\r\nfunction cloneVNode(vnode, extraProps, mergeRef = false) {\r\n // This is intentionally NOT using spread or extend to avoid the runtime\r\n // key enumeration cost.\r\n const { props, ref, patchFlag, children } = vnode;\r\n const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;\r\n const cloned = {\r\n __v_isVNode: true,\r\n __v_skip: true,\r\n type: vnode.type,\r\n props: mergedProps,\r\n key: mergedProps && normalizeKey(mergedProps),\r\n ref: extraProps && extraProps.ref\r\n ? // #2078 in the case of <component :is=\"vnode\" ref=\"extra\"/>\r\n // if the vnode itself already has a ref, cloneVNode will need to merge\r\n // the refs so the single vnode can be set on multiple refs\r\n mergeRef && ref\r\n ? isArray(ref)\r\n ? ref.concat(normalizeRef(extraProps))\r\n : [ref, normalizeRef(extraProps)]\r\n : normalizeRef(extraProps)\r\n : ref,\r\n scopeId: vnode.scopeId,\r\n slotScopeIds: vnode.slotScopeIds,\r\n children: (process.env.NODE_ENV !== 'production') && patchFlag === -1 /* HOISTED */ && isArray(children)\r\n ? children.map(deepCloneVNode)\r\n : children,\r\n target: vnode.target,\r\n targetAnchor: vnode.targetAnchor,\r\n staticCount: vnode.staticCount,\r\n shapeFlag: vnode.shapeFlag,\r\n // if the vnode is cloned with extra props, we can no longer assume its\r\n // existing patch flag to be reliable and need to add the FULL_PROPS flag.\r\n // note: perserve flag for fragments since they use the flag for children\r\n // fast paths only.\r\n patchFlag: extraProps && vnode.type !== Fragment\r\n ? patchFlag === -1 // hoisted node\r\n ? 16 /* FULL_PROPS */\r\n : patchFlag | 16 /* FULL_PROPS */\r\n : patchFlag,\r\n dynamicProps: vnode.dynamicProps,\r\n dynamicChildren: vnode.dynamicChildren,\r\n appContext: vnode.appContext,\r\n dirs: vnode.dirs,\r\n transition: vnode.transition,\r\n // These should technically only be non-null on mounted VNodes. However,\r\n // they *should* be copied for kept-alive vnodes. So we just always copy\r\n // them since them being non-null during a mount doesn't affect the logic as\r\n // they will simply be overwritten.\r\n component: vnode.component,\r\n suspense: vnode.suspense,\r\n ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),\r\n ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),\r\n el: vnode.el,\r\n anchor: vnode.anchor\r\n };\r\n return cloned;\r\n}\r\n/**\r\n * Dev only, for HMR of hoisted vnodes reused in v-for\r\n * https://github.com/vitejs/vite/issues/2022\r\n */\r\nfunction deepCloneVNode(vnode) {\r\n const cloned = cloneVNode(vnode);\r\n if (isArray(vnode.children)) {\r\n cloned.children = vnode.children.map(deepCloneVNode);\r\n }\r\n return cloned;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createTextVNode(text = ' ', flag = 0) {\r\n return createVNode(Text, null, text, flag);\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createStaticVNode(content, numberOfNodes) {\r\n // A static vnode can contain multiple stringified elements, and the number\r\n // of elements is necessary for hydration.\r\n const vnode = createVNode(Static, null, content);\r\n vnode.staticCount = numberOfNodes;\r\n return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createCommentVNode(text = '', \r\n// when used as the v-else branch, the comment node must be created as a\r\n// block to ensure correct updates.\r\nasBlock = false) {\r\n return asBlock\r\n ? (openBlock(), createBlock(Comment, null, text))\r\n : createVNode(Comment, null, text);\r\n}\r\nfunction normalizeVNode(child) {\r\n if (child == null || typeof child === 'boolean') {\r\n // empty placeholder\r\n return createVNode(Comment);\r\n }\r\n else if (isArray(child)) {\r\n // fragment\r\n return createVNode(Fragment, null, \r\n // #3666, avoid reference pollution when reusing vnode\r\n child.slice());\r\n }\r\n else if (typeof child === 'object') {\r\n // already vnode, this should be the most common since compiled templates\r\n // always produce all-vnode children arrays\r\n return cloneIfMounted(child);\r\n }\r\n else {\r\n // strings and numbers\r\n return createVNode(Text, null, String(child));\r\n }\r\n}\r\n// optimized normalization for template-compiled render fns\r\nfunction cloneIfMounted(child) {\r\n return child.el === null || child.memo ? child : cloneVNode(child);\r\n}\r\nfunction normalizeChildren(vnode, children) {\r\n let type = 0;\r\n const { shapeFlag } = vnode;\r\n if (children == null) {\r\n children = null;\r\n }\r\n else if (isArray(children)) {\r\n type = 16 /* ARRAY_CHILDREN */;\r\n }\r\n else if (typeof children === 'object') {\r\n if (shapeFlag & (1 /* ELEMENT */ | 64 /* TELEPORT */)) {\r\n // Normalize slot to plain children for plain element and Teleport\r\n const slot = children.default;\r\n if (slot) {\r\n // _c marker is added by withCtx() indicating this is a compiled slot\r\n slot._c && (slot._d = false);\r\n normalizeChildren(vnode, slot());\r\n slot._c && (slot._d = true);\r\n }\r\n return;\r\n }\r\n else {\r\n type = 32 /* SLOTS_CHILDREN */;\r\n const slotFlag = children._;\r\n if (!slotFlag && !(InternalObjectKey in children)) {\r\n children._ctx = currentRenderingInstance;\r\n }\r\n else if (slotFlag === 3 /* FORWARDED */ && currentRenderingInstance) {\r\n // a child component receives forwarded slots from the parent.\r\n // its slot type is determined by its parent's slot type.\r\n if (currentRenderingInstance.slots._ === 1 /* STABLE */) {\r\n children._ = 1 /* STABLE */;\r\n }\r\n else {\r\n children._ = 2 /* DYNAMIC */;\r\n vnode.patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n }\r\n }\r\n }\r\n }\r\n else if (isFunction(children)) {\r\n children = { default: children, _ctx: currentRenderingInstance };\r\n type = 32 /* SLOTS_CHILDREN */;\r\n }\r\n else {\r\n children = String(children);\r\n // force teleport children to array so it can be moved around\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n type = 16 /* ARRAY_CHILDREN */;\r\n children = [createTextVNode(children)];\r\n }\r\n else {\r\n type = 8 /* TEXT_CHILDREN */;\r\n }\r\n }\r\n vnode.children = children;\r\n vnode.shapeFlag |= type;\r\n}\r\nfunction mergeProps(...args) {\r\n const ret = {};\r\n for (let i = 0; i < args.length; i++) {\r\n const toMerge = args[i];\r\n for (const key in toMerge) {\r\n if (key === 'class') {\r\n if (ret.class !== toMerge.class) {\r\n ret.class = normalizeClass([ret.class, toMerge.class]);\r\n }\r\n }\r\n else if (key === 'style') {\r\n ret.style = normalizeStyle([ret.style, toMerge.style]);\r\n }\r\n else if (isOn(key)) {\r\n const existing = ret[key];\r\n const incoming = toMerge[key];\r\n if (existing !== incoming &&\r\n !(isArray(existing) && existing.includes(incoming))) {\r\n ret[key] = existing\r\n ? [].concat(existing, incoming)\r\n : incoming;\r\n }\r\n }\r\n else if (key !== '') {\r\n ret[key] = toMerge[key];\r\n }\r\n }\r\n }\r\n return ret;\r\n}\r\nfunction invokeVNodeHook(hook, instance, vnode, prevVNode = null) {\r\n callWithAsyncErrorHandling(hook, instance, 7 /* VNODE_HOOK */, [\r\n vnode,\r\n prevVNode\r\n ]);\r\n}\n\n/**\r\n * Actual implementation\r\n */\r\nfunction renderList(source, renderItem, cache, index) {\r\n let ret;\r\n const cached = (cache && cache[index]);\r\n if (isArray(source) || isString(source)) {\r\n ret = new Array(source.length);\r\n for (let i = 0, l = source.length; i < l; i++) {\r\n ret[i] = renderItem(source[i], i, undefined, cached && cached[i]);\r\n }\r\n }\r\n else if (typeof source === 'number') {\r\n if ((process.env.NODE_ENV !== 'production') && !Number.isInteger(source)) {\r\n warn(`The v-for range expect an integer value but got ${source}.`);\r\n return [];\r\n }\r\n ret = new Array(source);\r\n for (let i = 0; i < source; i++) {\r\n ret[i] = renderItem(i + 1, i, undefined, cached && cached[i]);\r\n }\r\n }\r\n else if (isObject(source)) {\r\n if (source[Symbol.iterator]) {\r\n ret = Array.from(source, (item, i) => renderItem(item, i, undefined, cached && cached[i]));\r\n }\r\n else {\r\n const keys = Object.keys(source);\r\n ret = new Array(keys.length);\r\n for (let i = 0, l = keys.length; i < l; i++) {\r\n const key = keys[i];\r\n ret[i] = renderItem(source[key], key, i, cached && cached[i]);\r\n }\r\n }\r\n }\r\n else {\r\n ret = [];\r\n }\r\n if (cache) {\r\n cache[index] = ret;\r\n }\r\n return ret;\r\n}\n\n/**\r\n * Compiler runtime helper for creating dynamic slots object\r\n * @private\r\n */\r\nfunction createSlots(slots, dynamicSlots) {\r\n for (let i = 0; i < dynamicSlots.length; i++) {\r\n const slot = dynamicSlots[i];\r\n // array of dynamic slot generated by <template v-for=\"...\" #[...]>\r\n if (isArray(slot)) {\r\n for (let j = 0; j < slot.length; j++) {\r\n slots[slot[j].name] = slot[j].fn;\r\n }\r\n }\r\n else if (slot) {\r\n // conditional single slot generated by <template v-if=\"...\" #foo>\r\n slots[slot.name] = slot.fn;\r\n }\r\n }\r\n return slots;\r\n}\n\n/**\r\n * Compiler runtime helper for rendering `<slot/>`\r\n * @private\r\n */\r\nfunction renderSlot(slots, name, props = {}, \r\n// this is not a user-facing function, so the fallback is always generated by\r\n// the compiler and guaranteed to be a function returning an array\r\nfallback, noSlotted) {\r\n if (currentRenderingInstance.isCE) {\r\n return createVNode('slot', name === 'default' ? null : { name }, fallback && fallback());\r\n }\r\n let slot = slots[name];\r\n if ((process.env.NODE_ENV !== 'production') && slot && slot.length > 1) {\r\n warn(`SSR-optimized slot function detected in a non-SSR-optimized render ` +\r\n `function. You need to mark this component with $dynamic-slots in the ` +\r\n `parent template.`);\r\n slot = () => [];\r\n }\r\n // a compiled slot disables block tracking by default to avoid manual\r\n // invocation interfering with template-based block tracking, but in\r\n // `renderSlot` we can be sure that it's template-based so we can force\r\n // enable it.\r\n if (slot && slot._c) {\r\n slot._d = false;\r\n }\r\n openBlock();\r\n const validSlotContent = slot && ensureValidVNode(slot(props));\r\n const rendered = createBlock(Fragment, { key: props.key || `_${name}` }, validSlotContent || (fallback ? fallback() : []), validSlotContent && slots._ === 1 /* STABLE */\r\n ? 64 /* STABLE_FRAGMENT */\r\n : -2 /* BAIL */);\r\n if (!noSlotted && rendered.scopeId) {\r\n rendered.slotScopeIds = [rendered.scopeId + '-s'];\r\n }\r\n if (slot && slot._c) {\r\n slot._d = true;\r\n }\r\n return rendered;\r\n}\r\nfunction ensureValidVNode(vnodes) {\r\n return vnodes.some(child => {\r\n if (!isVNode(child))\r\n return true;\r\n if (child.type === Comment)\r\n return false;\r\n if (child.type === Fragment &&\r\n !ensureValidVNode(child.children))\r\n return false;\r\n return true;\r\n })\r\n ? vnodes\r\n : null;\r\n}\n\n/**\r\n * For prefixing keys in v-on=\"obj\" with \"on\"\r\n * @private\r\n */\r\nfunction toHandlers(obj) {\r\n const ret = {};\r\n if ((process.env.NODE_ENV !== 'production') && !isObject(obj)) {\r\n warn(`v-on with no argument expects an object value.`);\r\n return ret;\r\n }\r\n for (const key in obj) {\r\n ret[toHandlerKey(key)] = obj[key];\r\n }\r\n return ret;\r\n}\n\n/**\r\n * #2437 In Vue 3, functional components do not have a public instance proxy but\r\n * they exist in the internal parent chain. For code that relies on traversing\r\n * public $parent chains, skip functional ones and go to the parent instead.\r\n */\r\nconst getPublicInstance = (i) => {\r\n if (!i)\r\n return null;\r\n if (isStatefulComponent(i))\r\n return getExposeProxy(i) || i.proxy;\r\n return getPublicInstance(i.parent);\r\n};\r\nconst publicPropertiesMap = extend(Object.create(null), {\r\n $: i => i,\r\n $el: i => i.vnode.el,\r\n $data: i => i.data,\r\n $props: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.props) : i.props),\r\n $attrs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.attrs) : i.attrs),\r\n $slots: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.slots) : i.slots),\r\n $refs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.refs) : i.refs),\r\n $parent: i => getPublicInstance(i.parent),\r\n $root: i => getPublicInstance(i.root),\r\n $emit: i => i.emit,\r\n $options: i => (__VUE_OPTIONS_API__ ? resolveMergedOptions(i) : i.type),\r\n $forceUpdate: i => () => queueJob(i.update),\r\n $nextTick: i => nextTick.bind(i.proxy),\r\n $watch: i => (__VUE_OPTIONS_API__ ? instanceWatch.bind(i) : NOOP)\r\n});\r\nconst PublicInstanceProxyHandlers = {\r\n get({ _: instance }, key) {\r\n const { ctx, setupState, data, props, accessCache, type, appContext } = instance;\r\n // for internal formatters to know that this is a Vue instance\r\n if ((process.env.NODE_ENV !== 'production') && key === '__isVue') {\r\n return true;\r\n }\r\n // prioritize <script setup> bindings during dev.\r\n // this allows even properties that start with _ or $ to be used - so that\r\n // it aligns with the production behavior where the render fn is inlined and\r\n // indeed has access to all declared variables.\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n setupState !== EMPTY_OBJ &&\r\n setupState.__isScriptSetup &&\r\n hasOwn(setupState, key)) {\r\n return setupState[key];\r\n }\r\n // data / props / ctx\r\n // This getter gets called for every property access on the render context\r\n // during render and is a major hotspot. The most expensive part of this\r\n // is the multiple hasOwn() calls. It's much faster to do a simple property\r\n // access on a plain object, so we use an accessCache object (with null\r\n // prototype) to memoize what access type a key corresponds to.\r\n let normalizedProps;\r\n if (key[0] !== '$') {\r\n const n = accessCache[key];\r\n if (n !== undefined) {\r\n switch (n) {\r\n case 1 /* SETUP */:\r\n return setupState[key];\r\n case 2 /* DATA */:\r\n return data[key];\r\n case 4 /* CONTEXT */:\r\n return ctx[key];\r\n case 3 /* PROPS */:\r\n return props[key];\r\n // default: just fallthrough\r\n }\r\n }\r\n else if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n accessCache[key] = 1 /* SETUP */;\r\n return setupState[key];\r\n }\r\n else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n accessCache[key] = 2 /* DATA */;\r\n return data[key];\r\n }\r\n else if (\r\n // only cache other properties when instance has declared (thus stable)\r\n // props\r\n (normalizedProps = instance.propsOptions[0]) &&\r\n hasOwn(normalizedProps, key)) {\r\n accessCache[key] = 3 /* PROPS */;\r\n return props[key];\r\n }\r\n else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n accessCache[key] = 4 /* CONTEXT */;\r\n return ctx[key];\r\n }\r\n else if (!__VUE_OPTIONS_API__ || shouldCacheAccess) {\r\n accessCache[key] = 0 /* OTHER */;\r\n }\r\n }\r\n const publicGetter = publicPropertiesMap[key];\r\n let cssModule, globalProperties;\r\n // public $xxx properties\r\n if (publicGetter) {\r\n if (key === '$attrs') {\r\n track(instance, \"get\" /* GET */, key);\r\n (process.env.NODE_ENV !== 'production') && markAttrsAccessed();\r\n }\r\n return publicGetter(instance);\r\n }\r\n else if (\r\n // css module (injected by vue-loader)\r\n (cssModule = type.__cssModules) &&\r\n (cssModule = cssModule[key])) {\r\n return cssModule;\r\n }\r\n else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n // user may set custom properties to `this` that start with `$`\r\n accessCache[key] = 4 /* CONTEXT */;\r\n return ctx[key];\r\n }\r\n else if (\r\n // global properties\r\n ((globalProperties = appContext.config.globalProperties),\r\n hasOwn(globalProperties, key))) {\r\n {\r\n return globalProperties[key];\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') &&\r\n currentRenderingInstance &&\r\n (!isString(key) ||\r\n // #1091 avoid internal isRef/isVNode checks on component instance leading\r\n // to infinite warning loop\r\n key.indexOf('__v') !== 0)) {\r\n if (data !== EMPTY_OBJ &&\r\n (key[0] === '$' || key[0] === '_') &&\r\n hasOwn(data, key)) {\r\n warn(`Property ${JSON.stringify(key)} must be accessed via $data because it starts with a reserved ` +\r\n `character (\"$\" or \"_\") and is not proxied on the render context.`);\r\n }\r\n else if (instance === currentRenderingInstance) {\r\n warn(`Property ${JSON.stringify(key)} was accessed during render ` +\r\n `but is not defined on instance.`);\r\n }\r\n }\r\n },\r\n set({ _: instance }, key, value) {\r\n const { data, setupState, ctx } = instance;\r\n if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n setupState[key] = value;\r\n }\r\n else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n data[key] = value;\r\n }\r\n else if (hasOwn(instance.props, key)) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to mutate prop \"${key}\". Props are readonly.`, instance);\r\n return false;\r\n }\r\n if (key[0] === '$' && key.slice(1) in instance) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to mutate public property \"${key}\". ` +\r\n `Properties starting with $ are reserved and readonly.`, instance);\r\n return false;\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && key in instance.appContext.config.globalProperties) {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n value\r\n });\r\n }\r\n else {\r\n ctx[key] = value;\r\n }\r\n }\r\n return true;\r\n },\r\n has({ _: { data, setupState, accessCache, ctx, appContext, propsOptions } }, key) {\r\n let normalizedProps;\r\n return (!!accessCache[key] ||\r\n (data !== EMPTY_OBJ && hasOwn(data, key)) ||\r\n (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) ||\r\n ((normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key)) ||\r\n hasOwn(ctx, key) ||\r\n hasOwn(publicPropertiesMap, key) ||\r\n hasOwn(appContext.config.globalProperties, key));\r\n }\r\n};\r\nif ((process.env.NODE_ENV !== 'production') && !false) {\r\n PublicInstanceProxyHandlers.ownKeys = (target) => {\r\n warn(`Avoid app logic that relies on enumerating keys on a component instance. ` +\r\n `The keys will be empty in production mode to avoid performance overhead.`);\r\n return Reflect.ownKeys(target);\r\n };\r\n}\r\nconst RuntimeCompiledPublicInstanceProxyHandlers = /*#__PURE__*/ extend({}, PublicInstanceProxyHandlers, {\r\n get(target, key) {\r\n // fast path for unscopables when using `with` block\r\n if (key === Symbol.unscopables) {\r\n return;\r\n }\r\n return PublicInstanceProxyHandlers.get(target, key, target);\r\n },\r\n has(_, key) {\r\n const has = key[0] !== '_' && !isGloballyWhitelisted(key);\r\n if ((process.env.NODE_ENV !== 'production') && !has && PublicInstanceProxyHandlers.has(_, key)) {\r\n warn(`Property ${JSON.stringify(key)} should not start with _ which is a reserved prefix for Vue internals.`);\r\n }\r\n return has;\r\n }\r\n});\r\n// dev only\r\n// In dev mode, the proxy target exposes the same properties as seen on `this`\r\n// for easier console inspection. In prod mode it will be an empty object so\r\n// these properties definitions can be skipped.\r\nfunction createDevRenderContext(instance) {\r\n const target = {};\r\n // expose internal instance for proxy handlers\r\n Object.defineProperty(target, `_`, {\r\n configurable: true,\r\n enumerable: false,\r\n get: () => instance\r\n });\r\n // expose public properties\r\n Object.keys(publicPropertiesMap).forEach(key => {\r\n Object.defineProperty(target, key, {\r\n configurable: true,\r\n enumerable: false,\r\n get: () => publicPropertiesMap[key](instance),\r\n // intercepted by the proxy so no need for implementation,\r\n // but needed to prevent set errors\r\n set: NOOP\r\n });\r\n });\r\n return target;\r\n}\r\n// dev only\r\nfunction exposePropsOnRenderContext(instance) {\r\n const { ctx, propsOptions: [propsOptions] } = instance;\r\n if (propsOptions) {\r\n Object.keys(propsOptions).forEach(key => {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => instance.props[key],\r\n set: NOOP\r\n });\r\n });\r\n }\r\n}\r\n// dev only\r\nfunction exposeSetupStateOnRenderContext(instance) {\r\n const { ctx, setupState } = instance;\r\n Object.keys(toRaw(setupState)).forEach(key => {\r\n if (!setupState.__isScriptSetup) {\r\n if (key[0] === '$' || key[0] === '_') {\r\n warn(`setup() return property ${JSON.stringify(key)} should not start with \"$\" or \"_\" ` +\r\n `which are reserved prefixes for Vue internals.`);\r\n return;\r\n }\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => setupState[key],\r\n set: NOOP\r\n });\r\n }\r\n });\r\n}\n\nconst emptyAppContext = createAppContext();\r\nlet uid$1 = 0;\r\nfunction createComponentInstance(vnode, parent, suspense) {\r\n const type = vnode.type;\r\n // inherit parent app context - or - if root, adopt from root vnode\r\n const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;\r\n const instance = {\r\n uid: uid$1++,\r\n vnode,\r\n type,\r\n parent,\r\n appContext,\r\n root: null,\r\n next: null,\r\n subTree: null,\r\n effect: null,\r\n update: null,\r\n scope: new EffectScope(true /* detached */),\r\n render: null,\r\n proxy: null,\r\n exposed: null,\r\n exposeProxy: null,\r\n withProxy: null,\r\n provides: parent ? parent.provides : Object.create(appContext.provides),\r\n accessCache: null,\r\n renderCache: [],\r\n // local resovled assets\r\n components: null,\r\n directives: null,\r\n // resolved props and emits options\r\n propsOptions: normalizePropsOptions(type, appContext),\r\n emitsOptions: normalizeEmitsOptions(type, appContext),\r\n // emit\r\n emit: null,\r\n emitted: null,\r\n // props default value\r\n propsDefaults: EMPTY_OBJ,\r\n // inheritAttrs\r\n inheritAttrs: type.inheritAttrs,\r\n // state\r\n ctx: EMPTY_OBJ,\r\n data: EMPTY_OBJ,\r\n props: EMPTY_OBJ,\r\n attrs: EMPTY_OBJ,\r\n slots: EMPTY_OBJ,\r\n refs: EMPTY_OBJ,\r\n setupState: EMPTY_OBJ,\r\n setupContext: null,\r\n // suspense related\r\n suspense,\r\n suspenseId: suspense ? suspense.pendingId : 0,\r\n asyncDep: null,\r\n asyncResolved: false,\r\n // lifecycle hooks\r\n // not using enums here because it results in computed properties\r\n isMounted: false,\r\n isUnmounted: false,\r\n isDeactivated: false,\r\n bc: null,\r\n c: null,\r\n bm: null,\r\n m: null,\r\n bu: null,\r\n u: null,\r\n um: null,\r\n bum: null,\r\n da: null,\r\n a: null,\r\n rtg: null,\r\n rtc: null,\r\n ec: null,\r\n sp: null\r\n };\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n instance.ctx = createDevRenderContext(instance);\r\n }\r\n else {\r\n instance.ctx = { _: instance };\r\n }\r\n instance.root = parent ? parent.root : instance;\r\n instance.emit = emit$1.bind(null, instance);\r\n // apply custom element special handling\r\n if (vnode.ce) {\r\n vnode.ce(instance);\r\n }\r\n return instance;\r\n}\r\nlet currentInstance = null;\r\nconst getCurrentInstance = () => currentInstance || currentRenderingInstance;\r\nconst setCurrentInstance = (instance) => {\r\n currentInstance = instance;\r\n instance.scope.on();\r\n};\r\nconst unsetCurrentInstance = () => {\r\n currentInstance && currentInstance.scope.off();\r\n currentInstance = null;\r\n};\r\nconst isBuiltInTag = /*#__PURE__*/ makeMap('slot,component');\r\nfunction validateComponentName(name, config) {\r\n const appIsNativeTag = config.isNativeTag || NO;\r\n if (isBuiltInTag(name) || appIsNativeTag(name)) {\r\n warn('Do not use built-in or reserved HTML elements as component id: ' + name);\r\n }\r\n}\r\nfunction isStatefulComponent(instance) {\r\n return instance.vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */;\r\n}\r\nlet isInSSRComponentSetup = false;\r\nfunction setupComponent(instance, isSSR = false) {\r\n isInSSRComponentSetup = isSSR;\r\n const { props, children } = instance.vnode;\r\n const isStateful = isStatefulComponent(instance);\r\n initProps(instance, props, isStateful, isSSR);\r\n initSlots(instance, children);\r\n const setupResult = isStateful\r\n ? setupStatefulComponent(instance, isSSR)\r\n : undefined;\r\n isInSSRComponentSetup = false;\r\n return setupResult;\r\n}\r\nfunction setupStatefulComponent(instance, isSSR) {\r\n const Component = instance.type;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (Component.name) {\r\n validateComponentName(Component.name, instance.appContext.config);\r\n }\r\n if (Component.components) {\r\n const names = Object.keys(Component.components);\r\n for (let i = 0; i < names.length; i++) {\r\n validateComponentName(names[i], instance.appContext.config);\r\n }\r\n }\r\n if (Component.directives) {\r\n const names = Object.keys(Component.directives);\r\n for (let i = 0; i < names.length; i++) {\r\n validateDirectiveName(names[i]);\r\n }\r\n }\r\n if (Component.compilerOptions && isRuntimeOnly()) {\r\n warn(`\"compilerOptions\" is only supported when using a build of Vue that ` +\r\n `includes the runtime compiler. Since you are using a runtime-only ` +\r\n `build, the options should be passed via your build tool config instead.`);\r\n }\r\n }\r\n // 0. create render proxy property access cache\r\n instance.accessCache = Object.create(null);\r\n // 1. create public instance / render proxy\r\n // also mark it raw so it's never observed\r\n instance.proxy = markRaw(new Proxy(instance.ctx, PublicInstanceProxyHandlers));\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n exposePropsOnRenderContext(instance);\r\n }\r\n // 2. call setup()\r\n const { setup } = Component;\r\n if (setup) {\r\n const setupContext = (instance.setupContext =\r\n setup.length > 1 ? createSetupContext(instance) : null);\r\n setCurrentInstance(instance);\r\n pauseTracking();\r\n const setupResult = callWithErrorHandling(setup, instance, 0 /* SETUP_FUNCTION */, [(process.env.NODE_ENV !== 'production') ? shallowReadonly(instance.props) : instance.props, setupContext]);\r\n resetTracking();\r\n unsetCurrentInstance();\r\n if (isPromise(setupResult)) {\r\n setupResult.then(unsetCurrentInstance, unsetCurrentInstance);\r\n if (isSSR) {\r\n // return the promise so server-renderer can wait on it\r\n return setupResult\r\n .then((resolvedResult) => {\r\n handleSetupResult(instance, resolvedResult, isSSR);\r\n })\r\n .catch(e => {\r\n handleError(e, instance, 0 /* SETUP_FUNCTION */);\r\n });\r\n }\r\n else {\r\n // async setup returned Promise.\r\n // bail here and wait for re-entry.\r\n instance.asyncDep = setupResult;\r\n }\r\n }\r\n else {\r\n handleSetupResult(instance, setupResult, isSSR);\r\n }\r\n }\r\n else {\r\n finishComponentSetup(instance, isSSR);\r\n }\r\n}\r\nfunction handleSetupResult(instance, setupResult, isSSR) {\r\n if (isFunction(setupResult)) {\r\n // setup returned an inline render function\r\n if (instance.type.__ssrInlineRender) {\r\n // when the function's name is `ssrRender` (compiled by SFC inline mode),\r\n // set it as ssrRender instead.\r\n instance.ssrRender = setupResult;\r\n }\r\n else {\r\n instance.render = setupResult;\r\n }\r\n }\r\n else if (isObject(setupResult)) {\r\n if ((process.env.NODE_ENV !== 'production') && isVNode(setupResult)) {\r\n warn(`setup() should not return VNodes directly - ` +\r\n `return a render function instead.`);\r\n }\r\n // setup returned bindings.\r\n // assuming a render function compiled from template is present.\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n instance.devtoolsRawSetupState = setupResult;\r\n }\r\n instance.setupState = proxyRefs(setupResult);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n exposeSetupStateOnRenderContext(instance);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && setupResult !== undefined) {\r\n warn(`setup() should return an object. Received: ${setupResult === null ? 'null' : typeof setupResult}`);\r\n }\r\n finishComponentSetup(instance, isSSR);\r\n}\r\nlet compile;\r\nlet installWithProxy;\r\n/**\r\n * For runtime-dom to register the compiler.\r\n * Note the exported method uses any to avoid d.ts relying on the compiler types.\r\n */\r\nfunction registerRuntimeCompiler(_compile) {\r\n compile = _compile;\r\n installWithProxy = i => {\r\n if (i.render._rc) {\r\n i.withProxy = new Proxy(i.ctx, RuntimeCompiledPublicInstanceProxyHandlers);\r\n }\r\n };\r\n}\r\n// dev only\r\nconst isRuntimeOnly = () => !compile;\r\nfunction finishComponentSetup(instance, isSSR, skipOptions) {\r\n const Component = instance.type;\r\n // template / render function normalization\r\n // could be already set when returned from setup()\r\n if (!instance.render) {\r\n // only do on-the-fly compile if not in SSR - SSR on-the-fly compliation\r\n // is done by server-renderer\r\n if (!isSSR && compile && !Component.render) {\r\n const template = Component.template;\r\n if (template) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `compile`);\r\n }\r\n const { isCustomElement, compilerOptions } = instance.appContext.config;\r\n const { delimiters, compilerOptions: componentCompilerOptions } = Component;\r\n const finalCompilerOptions = extend(extend({\r\n isCustomElement,\r\n delimiters\r\n }, compilerOptions), componentCompilerOptions);\r\n Component.render = compile(template, finalCompilerOptions);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `compile`);\r\n }\r\n }\r\n }\r\n instance.render = (Component.render || NOOP);\r\n // for runtime-compiled render functions using `with` blocks, the render\r\n // proxy used needs a different `has` handler which is more performant and\r\n // also only allows a whitelist of globals to fallthrough.\r\n if (installWithProxy) {\r\n installWithProxy(instance);\r\n }\r\n }\r\n // support for 2.x options\r\n if (__VUE_OPTIONS_API__ && !(false )) {\r\n setCurrentInstance(instance);\r\n pauseTracking();\r\n applyOptions(instance);\r\n resetTracking();\r\n unsetCurrentInstance();\r\n }\r\n // warn missing template/render\r\n // the runtime compilation of template in SSR is done by server-render\r\n if ((process.env.NODE_ENV !== 'production') && !Component.render && instance.render === NOOP && !isSSR) {\r\n /* istanbul ignore if */\r\n if (!compile && Component.template) {\r\n warn(`Component provided template option but ` +\r\n `runtime compilation is not supported in this build of Vue.` +\r\n (` Configure your bundler to alias \"vue\" to \"vue/dist/vue.esm-bundler.js\".`\r\n ) /* should not happen */);\r\n }\r\n else {\r\n warn(`Component is missing template or render function.`);\r\n }\r\n }\r\n}\r\nfunction createAttrsProxy(instance) {\r\n return new Proxy(instance.attrs, (process.env.NODE_ENV !== 'production')\r\n ? {\r\n get(target, key) {\r\n markAttrsAccessed();\r\n track(instance, \"get\" /* GET */, '$attrs');\r\n return target[key];\r\n },\r\n set() {\r\n warn(`setupContext.attrs is readonly.`);\r\n return false;\r\n },\r\n deleteProperty() {\r\n warn(`setupContext.attrs is readonly.`);\r\n return false;\r\n }\r\n }\r\n : {\r\n get(target, key) {\r\n track(instance, \"get\" /* GET */, '$attrs');\r\n return target[key];\r\n }\r\n });\r\n}\r\nfunction createSetupContext(instance) {\r\n const expose = exposed => {\r\n if ((process.env.NODE_ENV !== 'production') && instance.exposed) {\r\n warn(`expose() should be called only once per setup().`);\r\n }\r\n instance.exposed = exposed || {};\r\n };\r\n let attrs;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n // We use getters in dev in case libs like test-utils overwrite instance\r\n // properties (overwrites should not be done in prod)\r\n return Object.freeze({\r\n get attrs() {\r\n return attrs || (attrs = createAttrsProxy(instance));\r\n },\r\n get slots() {\r\n return shallowReadonly(instance.slots);\r\n },\r\n get emit() {\r\n return (event, ...args) => instance.emit(event, ...args);\r\n },\r\n expose\r\n });\r\n }\r\n else {\r\n return {\r\n get attrs() {\r\n return attrs || (attrs = createAttrsProxy(instance));\r\n },\r\n slots: instance.slots,\r\n emit: instance.emit,\r\n expose\r\n };\r\n }\r\n}\r\nfunction getExposeProxy(instance) {\r\n if (instance.exposed) {\r\n return (instance.exposeProxy ||\r\n (instance.exposeProxy = new Proxy(proxyRefs(markRaw(instance.exposed)), {\r\n get(target, key) {\r\n if (key in target) {\r\n return target[key];\r\n }\r\n else if (key in publicPropertiesMap) {\r\n return publicPropertiesMap[key](instance);\r\n }\r\n }\r\n })));\r\n }\r\n}\r\nconst classifyRE = /(?:^|[-_])(\\w)/g;\r\nconst classify = (str) => str.replace(classifyRE, c => c.toUpperCase()).replace(/[-_]/g, '');\r\nfunction getComponentName(Component) {\r\n return isFunction(Component)\r\n ? Component.displayName || Component.name\r\n : Component.name;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatComponentName(instance, Component, isRoot = false) {\r\n let name = getComponentName(Component);\r\n if (!name && Component.__file) {\r\n const match = Component.__file.match(/([^/\\\\]+)\\.\\w+$/);\r\n if (match) {\r\n name = match[1];\r\n }\r\n }\r\n if (!name && instance && instance.parent) {\r\n // try to infer the name based on reverse resolution\r\n const inferFromRegistry = (registry) => {\r\n for (const key in registry) {\r\n if (registry[key] === Component) {\r\n return key;\r\n }\r\n }\r\n };\r\n name =\r\n inferFromRegistry(instance.components ||\r\n instance.parent.type.components) || inferFromRegistry(instance.appContext.components);\r\n }\r\n return name ? classify(name) : isRoot ? `App` : `Anonymous`;\r\n}\r\nfunction isClassComponent(value) {\r\n return isFunction(value) && '__vccOpts' in value;\r\n}\n\nconst stack = [];\r\nfunction pushWarningContext(vnode) {\r\n stack.push(vnode);\r\n}\r\nfunction popWarningContext() {\r\n stack.pop();\r\n}\r\nfunction warn(msg, ...args) {\r\n // avoid props formatting or warn handler tracking deps that might be mutated\r\n // during patch, leading to infinite recursion.\r\n pauseTracking();\r\n const instance = stack.length ? stack[stack.length - 1].component : null;\r\n const appWarnHandler = instance && instance.appContext.config.warnHandler;\r\n const trace = getComponentTrace();\r\n if (appWarnHandler) {\r\n callWithErrorHandling(appWarnHandler, instance, 11 /* APP_WARN_HANDLER */, [\r\n msg + args.join(''),\r\n instance && instance.proxy,\r\n trace\r\n .map(({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`)\r\n .join('\\n'),\r\n trace\r\n ]);\r\n }\r\n else {\r\n const warnArgs = [`[Vue warn]: ${msg}`, ...args];\r\n /* istanbul ignore if */\r\n if (trace.length &&\r\n // avoid spamming console during tests\r\n !false) {\r\n warnArgs.push(`\\n`, ...formatTrace(trace));\r\n }\r\n console.warn(...warnArgs);\r\n }\r\n resetTracking();\r\n}\r\nfunction getComponentTrace() {\r\n let currentVNode = stack[stack.length - 1];\r\n if (!currentVNode) {\r\n return [];\r\n }\r\n // we can't just use the stack because it will be incomplete during updates\r\n // that did not start from the root. Re-construct the parent chain using\r\n // instance parent pointers.\r\n const normalizedStack = [];\r\n while (currentVNode) {\r\n const last = normalizedStack[0];\r\n if (last && last.vnode === currentVNode) {\r\n last.recurseCount++;\r\n }\r\n else {\r\n normalizedStack.push({\r\n vnode: currentVNode,\r\n recurseCount: 0\r\n });\r\n }\r\n const parentInstance = currentVNode.component && currentVNode.component.parent;\r\n currentVNode = parentInstance && parentInstance.vnode;\r\n }\r\n return normalizedStack;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatTrace(trace) {\r\n const logs = [];\r\n trace.forEach((entry, i) => {\r\n logs.push(...(i === 0 ? [] : [`\\n`]), ...formatTraceEntry(entry));\r\n });\r\n return logs;\r\n}\r\nfunction formatTraceEntry({ vnode, recurseCount }) {\r\n const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;\r\n const isRoot = vnode.component ? vnode.component.parent == null : false;\r\n const open = ` at <${formatComponentName(vnode.component, vnode.type, isRoot)}`;\r\n const close = `>` + postfix;\r\n return vnode.props\r\n ? [open, ...formatProps(vnode.props), close]\r\n : [open + close];\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProps(props) {\r\n const res = [];\r\n const keys = Object.keys(props);\r\n keys.slice(0, 3).forEach(key => {\r\n res.push(...formatProp(key, props[key]));\r\n });\r\n if (keys.length > 3) {\r\n res.push(` ...`);\r\n }\r\n return res;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProp(key, value, raw) {\r\n if (isString(value)) {\r\n value = JSON.stringify(value);\r\n return raw ? value : [`${key}=${value}`];\r\n }\r\n else if (typeof value === 'number' ||\r\n typeof value === 'boolean' ||\r\n value == null) {\r\n return raw ? value : [`${key}=${value}`];\r\n }\r\n else if (isRef(value)) {\r\n value = formatProp(key, toRaw(value.value), true);\r\n return raw ? value : [`${key}=Ref<`, value, `>`];\r\n }\r\n else if (isFunction(value)) {\r\n return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];\r\n }\r\n else {\r\n value = toRaw(value);\r\n return raw ? value : [`${key}=`, value];\r\n }\r\n}\n\nconst ErrorTypeStrings = {\r\n [\"sp\" /* SERVER_PREFETCH */]: 'serverPrefetch hook',\r\n [\"bc\" /* BEFORE_CREATE */]: 'beforeCreate hook',\r\n [\"c\" /* CREATED */]: 'created hook',\r\n [\"bm\" /* BEFORE_MOUNT */]: 'beforeMount hook',\r\n [\"m\" /* MOUNTED */]: 'mounted hook',\r\n [\"bu\" /* BEFORE_UPDATE */]: 'beforeUpdate hook',\r\n [\"u\" /* UPDATED */]: 'updated',\r\n [\"bum\" /* BEFORE_UNMOUNT */]: 'beforeUnmount hook',\r\n [\"um\" /* UNMOUNTED */]: 'unmounted hook',\r\n [\"a\" /* ACTIVATED */]: 'activated hook',\r\n [\"da\" /* DEACTIVATED */]: 'deactivated hook',\r\n [\"ec\" /* ERROR_CAPTURED */]: 'errorCaptured hook',\r\n [\"rtc\" /* RENDER_TRACKED */]: 'renderTracked hook',\r\n [\"rtg\" /* RENDER_TRIGGERED */]: 'renderTriggered hook',\r\n [0 /* SETUP_FUNCTION */]: 'setup function',\r\n [1 /* RENDER_FUNCTION */]: 'render function',\r\n [2 /* WATCH_GETTER */]: 'watcher getter',\r\n [3 /* WATCH_CALLBACK */]: 'watcher callback',\r\n [4 /* WATCH_CLEANUP */]: 'watcher cleanup function',\r\n [5 /* NATIVE_EVENT_HANDLER */]: 'native event handler',\r\n [6 /* COMPONENT_EVENT_HANDLER */]: 'component event handler',\r\n [7 /* VNODE_HOOK */]: 'vnode hook',\r\n [8 /* DIRECTIVE_HOOK */]: 'directive hook',\r\n [9 /* TRANSITION_HOOK */]: 'transition hook',\r\n [10 /* APP_ERROR_HANDLER */]: 'app errorHandler',\r\n [11 /* APP_WARN_HANDLER */]: 'app warnHandler',\r\n [12 /* FUNCTION_REF */]: 'ref function',\r\n [13 /* ASYNC_COMPONENT_LOADER */]: 'async component loader',\r\n [14 /* SCHEDULER */]: 'scheduler flush. This is likely a Vue internals bug. ' +\r\n 'Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-next'\r\n};\r\nfunction callWithErrorHandling(fn, instance, type, args) {\r\n let res;\r\n try {\r\n res = args ? fn(...args) : fn();\r\n }\r\n catch (err) {\r\n handleError(err, instance, type);\r\n }\r\n return res;\r\n}\r\nfunction callWithAsyncErrorHandling(fn, instance, type, args) {\r\n if (isFunction(fn)) {\r\n const res = callWithErrorHandling(fn, instance, type, args);\r\n if (res && isPromise(res)) {\r\n res.catch(err => {\r\n handleError(err, instance, type);\r\n });\r\n }\r\n return res;\r\n }\r\n const values = [];\r\n for (let i = 0; i < fn.length; i++) {\r\n values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));\r\n }\r\n return values;\r\n}\r\nfunction handleError(err, instance, type, throwInDev = true) {\r\n const contextVNode = instance ? instance.vnode : null;\r\n if (instance) {\r\n let cur = instance.parent;\r\n // the exposed instance is the render proxy to keep it consistent with 2.x\r\n const exposedInstance = instance.proxy;\r\n // in production the hook receives only the error code\r\n const errorInfo = (process.env.NODE_ENV !== 'production') ? ErrorTypeStrings[type] : type;\r\n while (cur) {\r\n const errorCapturedHooks = cur.ec;\r\n if (errorCapturedHooks) {\r\n for (let i = 0; i < errorCapturedHooks.length; i++) {\r\n if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {\r\n return;\r\n }\r\n }\r\n }\r\n cur = cur.parent;\r\n }\r\n // app-level handling\r\n const appErrorHandler = instance.appContext.config.errorHandler;\r\n if (appErrorHandler) {\r\n callWithErrorHandling(appErrorHandler, null, 10 /* APP_ERROR_HANDLER */, [err, exposedInstance, errorInfo]);\r\n return;\r\n }\r\n }\r\n logError(err, type, contextVNode, throwInDev);\r\n}\r\nfunction logError(err, type, contextVNode, throwInDev = true) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const info = ErrorTypeStrings[type];\r\n if (contextVNode) {\r\n pushWarningContext(contextVNode);\r\n }\r\n warn(`Unhandled error${info ? ` during execution of ${info}` : ``}`);\r\n if (contextVNode) {\r\n popWarningContext();\r\n }\r\n // crash in dev by default so it's more noticeable\r\n if (throwInDev) {\r\n throw err;\r\n }\r\n else {\r\n console.error(err);\r\n }\r\n }\r\n else {\r\n // recover in prod to reduce the impact on end-user\r\n console.error(err);\r\n }\r\n}\n\nlet isFlushing = false;\r\nlet isFlushPending = false;\r\nconst queue = [];\r\nlet flushIndex = 0;\r\nconst pendingPreFlushCbs = [];\r\nlet activePreFlushCbs = null;\r\nlet preFlushIndex = 0;\r\nconst pendingPostFlushCbs = [];\r\nlet activePostFlushCbs = null;\r\nlet postFlushIndex = 0;\r\nconst resolvedPromise = Promise.resolve();\r\nlet currentFlushPromise = null;\r\nlet currentPreFlushParentJob = null;\r\nconst RECURSION_LIMIT = 100;\r\nfunction nextTick(fn) {\r\n const p = currentFlushPromise || resolvedPromise;\r\n return fn ? p.then(this ? fn.bind(this) : fn) : p;\r\n}\r\n// #2768\r\n// Use binary-search to find a suitable position in the queue,\r\n// so that the queue maintains the increasing order of job's id,\r\n// which can prevent the job from being skipped and also can avoid repeated patching.\r\nfunction findInsertionIndex(id) {\r\n // the start index should be `flushIndex + 1`\r\n let start = flushIndex + 1;\r\n let end = queue.length;\r\n while (start < end) {\r\n const middle = (start + end) >>> 1;\r\n const middleJobId = getId(queue[middle]);\r\n middleJobId < id ? (start = middle + 1) : (end = middle);\r\n }\r\n return start;\r\n}\r\nfunction queueJob(job) {\r\n // the dedupe search uses the startIndex argument of Array.includes()\r\n // by default the search index includes the current job that is being run\r\n // so it cannot recursively trigger itself again.\r\n // if the job is a watch() callback, the search will start with a +1 index to\r\n // allow it recursively trigger itself - it is the user's responsibility to\r\n // ensure it doesn't end up in an infinite loop.\r\n if ((!queue.length ||\r\n !queue.includes(job, isFlushing && job.allowRecurse ? flushIndex + 1 : flushIndex)) &&\r\n job !== currentPreFlushParentJob) {\r\n if (job.id == null) {\r\n queue.push(job);\r\n }\r\n else {\r\n queue.splice(findInsertionIndex(job.id), 0, job);\r\n }\r\n queueFlush();\r\n }\r\n}\r\nfunction queueFlush() {\r\n if (!isFlushing && !isFlushPending) {\r\n isFlushPending = true;\r\n currentFlushPromise = resolvedPromise.then(flushJobs);\r\n }\r\n}\r\nfunction invalidateJob(job) {\r\n const i = queue.indexOf(job);\r\n if (i > flushIndex) {\r\n queue.splice(i, 1);\r\n }\r\n}\r\nfunction queueCb(cb, activeQueue, pendingQueue, index) {\r\n if (!isArray(cb)) {\r\n if (!activeQueue ||\r\n !activeQueue.includes(cb, cb.allowRecurse ? index + 1 : index)) {\r\n pendingQueue.push(cb);\r\n }\r\n }\r\n else {\r\n // if cb is an array, it is a component lifecycle hook which can only be\r\n // triggered by a job, which is already deduped in the main queue, so\r\n // we can skip duplicate check here to improve perf\r\n pendingQueue.push(...cb);\r\n }\r\n queueFlush();\r\n}\r\nfunction queuePreFlushCb(cb) {\r\n queueCb(cb, activePreFlushCbs, pendingPreFlushCbs, preFlushIndex);\r\n}\r\nfunction queuePostFlushCb(cb) {\r\n queueCb(cb, activePostFlushCbs, pendingPostFlushCbs, postFlushIndex);\r\n}\r\nfunction flushPreFlushCbs(seen, parentJob = null) {\r\n if (pendingPreFlushCbs.length) {\r\n currentPreFlushParentJob = parentJob;\r\n activePreFlushCbs = [...new Set(pendingPreFlushCbs)];\r\n pendingPreFlushCbs.length = 0;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n for (preFlushIndex = 0; preFlushIndex < activePreFlushCbs.length; preFlushIndex++) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n checkRecursiveUpdates(seen, activePreFlushCbs[preFlushIndex])) {\r\n continue;\r\n }\r\n activePreFlushCbs[preFlushIndex]();\r\n }\r\n activePreFlushCbs = null;\r\n preFlushIndex = 0;\r\n currentPreFlushParentJob = null;\r\n // recursively flush until it drains\r\n flushPreFlushCbs(seen, parentJob);\r\n }\r\n}\r\nfunction flushPostFlushCbs(seen) {\r\n if (pendingPostFlushCbs.length) {\r\n const deduped = [...new Set(pendingPostFlushCbs)];\r\n pendingPostFlushCbs.length = 0;\r\n // #1947 already has active queue, nested flushPostFlushCbs call\r\n if (activePostFlushCbs) {\r\n activePostFlushCbs.push(...deduped);\r\n return;\r\n }\r\n activePostFlushCbs = deduped;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n activePostFlushCbs.sort((a, b) => getId(a) - getId(b));\r\n for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n checkRecursiveUpdates(seen, activePostFlushCbs[postFlushIndex])) {\r\n continue;\r\n }\r\n activePostFlushCbs[postFlushIndex]();\r\n }\r\n activePostFlushCbs = null;\r\n postFlushIndex = 0;\r\n }\r\n}\r\nconst getId = (job) => job.id == null ? Infinity : job.id;\r\nfunction flushJobs(seen) {\r\n isFlushPending = false;\r\n isFlushing = true;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n flushPreFlushCbs(seen);\r\n // Sort queue before flush.\r\n // This ensures that:\r\n // 1. Components are updated from parent to child. (because parent is always\r\n // created before the child so its render effect will have smaller\r\n // priority number)\r\n // 2. If a component is unmounted during a parent component's update,\r\n // its update can be skipped.\r\n queue.sort((a, b) => getId(a) - getId(b));\r\n // conditional usage of checkRecursiveUpdate must be determined out of\r\n // try ... catch block since Rollup by default de-optimizes treeshaking\r\n // inside try-catch. This can leave all warning code unshaked. Although\r\n // they would get eventually shaken by a minifier like terser, some minifiers\r\n // would fail to do that (e.g. https://github.com/evanw/esbuild/issues/1610)\r\n const check = (process.env.NODE_ENV !== 'production')\r\n ? (job) => checkRecursiveUpdates(seen, job)\r\n : NOOP;\r\n try {\r\n for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {\r\n const job = queue[flushIndex];\r\n if (job && job.active !== false) {\r\n if ((process.env.NODE_ENV !== 'production') && check(job)) {\r\n continue;\r\n }\r\n // console.log(`running:`, job.id)\r\n callWithErrorHandling(job, null, 14 /* SCHEDULER */);\r\n }\r\n }\r\n }\r\n finally {\r\n flushIndex = 0;\r\n queue.length = 0;\r\n flushPostFlushCbs(seen);\r\n isFlushing = false;\r\n currentFlushPromise = null;\r\n // some postFlushCb queued jobs!\r\n // keep flushing until it drains.\r\n if (queue.length ||\r\n pendingPreFlushCbs.length ||\r\n pendingPostFlushCbs.length) {\r\n flushJobs(seen);\r\n }\r\n }\r\n}\r\nfunction checkRecursiveUpdates(seen, fn) {\r\n if (!seen.has(fn)) {\r\n seen.set(fn, 1);\r\n }\r\n else {\r\n const count = seen.get(fn);\r\n if (count > RECURSION_LIMIT) {\r\n const instance = fn.ownerInstance;\r\n const componentName = instance && getComponentName(instance.type);\r\n warn(`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. ` +\r\n `This means you have a reactive effect that is mutating its own ` +\r\n `dependencies and thus recursively triggering itself. Possible sources ` +\r\n `include component template, render function, updated hook or ` +\r\n `watcher source function.`);\r\n return true;\r\n }\r\n else {\r\n seen.set(fn, count + 1);\r\n }\r\n }\r\n}\n\n// Simple effect.\r\nfunction watchEffect(effect, options) {\r\n return doWatch(effect, null, options);\r\n}\r\nfunction watchPostEffect(effect, options) {\r\n return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n ? Object.assign(options || {}, { flush: 'post' })\r\n : { flush: 'post' }));\r\n}\r\nfunction watchSyncEffect(effect, options) {\r\n return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n ? Object.assign(options || {}, { flush: 'sync' })\r\n : { flush: 'sync' }));\r\n}\r\n// initial value for watchers to trigger on undefined initial values\r\nconst INITIAL_WATCHER_VALUE = {};\r\n// implementation\r\nfunction watch(source, cb, options) {\r\n if ((process.env.NODE_ENV !== 'production') && !isFunction(cb)) {\r\n warn(`\\`watch(fn, options?)\\` signature has been moved to a separate API. ` +\r\n `Use \\`watchEffect(fn, options?)\\` instead. \\`watch\\` now only ` +\r\n `supports \\`watch(source, cb, options?) signature.`);\r\n }\r\n return doWatch(source, cb, options);\r\n}\r\nfunction doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EMPTY_OBJ) {\r\n if ((process.env.NODE_ENV !== 'production') && !cb) {\r\n if (immediate !== undefined) {\r\n warn(`watch() \"immediate\" option is only respected when using the ` +\r\n `watch(source, callback, options?) signature.`);\r\n }\r\n if (deep !== undefined) {\r\n warn(`watch() \"deep\" option is only respected when using the ` +\r\n `watch(source, callback, options?) signature.`);\r\n }\r\n }\r\n const warnInvalidSource = (s) => {\r\n warn(`Invalid watch source: `, s, `A watch source can only be a getter/effect function, a ref, ` +\r\n `a reactive object, or an array of these types.`);\r\n };\r\n const instance = currentInstance;\r\n let getter;\r\n let forceTrigger = false;\r\n let isMultiSource = false;\r\n if (isRef(source)) {\r\n getter = () => source.value;\r\n forceTrigger = !!source._shallow;\r\n }\r\n else if (isReactive(source)) {\r\n getter = () => source;\r\n deep = true;\r\n }\r\n else if (isArray(source)) {\r\n isMultiSource = true;\r\n forceTrigger = source.some(isReactive);\r\n getter = () => source.map(s => {\r\n if (isRef(s)) {\r\n return s.value;\r\n }\r\n else if (isReactive(s)) {\r\n return traverse(s);\r\n }\r\n else if (isFunction(s)) {\r\n return callWithErrorHandling(s, instance, 2 /* WATCH_GETTER */);\r\n }\r\n else {\r\n (process.env.NODE_ENV !== 'production') && warnInvalidSource(s);\r\n }\r\n });\r\n }\r\n else if (isFunction(source)) {\r\n if (cb) {\r\n // getter with cb\r\n getter = () => callWithErrorHandling(source, instance, 2 /* WATCH_GETTER */);\r\n }\r\n else {\r\n // no cb -> simple effect\r\n getter = () => {\r\n if (instance && instance.isUnmounted) {\r\n return;\r\n }\r\n if (cleanup) {\r\n cleanup();\r\n }\r\n return callWithAsyncErrorHandling(source, instance, 3 /* WATCH_CALLBACK */, [onInvalidate]);\r\n };\r\n }\r\n }\r\n else {\r\n getter = NOOP;\r\n (process.env.NODE_ENV !== 'production') && warnInvalidSource(source);\r\n }\r\n if (cb && deep) {\r\n const baseGetter = getter;\r\n getter = () => traverse(baseGetter());\r\n }\r\n let cleanup;\r\n let onInvalidate = (fn) => {\r\n cleanup = effect.onStop = () => {\r\n callWithErrorHandling(fn, instance, 4 /* WATCH_CLEANUP */);\r\n };\r\n };\r\n // in SSR there is no need to setup an actual effect, and it should be noop\r\n // unless it's eager\r\n if (isInSSRComponentSetup) {\r\n // we will also not call the invalidate callback (+ runner is not set up)\r\n onInvalidate = NOOP;\r\n if (!cb) {\r\n getter();\r\n }\r\n else if (immediate) {\r\n callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n getter(),\r\n isMultiSource ? [] : undefined,\r\n onInvalidate\r\n ]);\r\n }\r\n return NOOP;\r\n }\r\n let oldValue = isMultiSource ? [] : INITIAL_WATCHER_VALUE;\r\n const job = () => {\r\n if (!effect.active) {\r\n return;\r\n }\r\n if (cb) {\r\n // watch(source, cb)\r\n const newValue = effect.run();\r\n if (deep ||\r\n forceTrigger ||\r\n (isMultiSource\r\n ? newValue.some((v, i) => hasChanged(v, oldValue[i]))\r\n : hasChanged(newValue, oldValue)) ||\r\n (false )) {\r\n // cleanup before running cb again\r\n if (cleanup) {\r\n cleanup();\r\n }\r\n callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n newValue,\r\n // pass undefined as the old value when it's changed for the first time\r\n oldValue === INITIAL_WATCHER_VALUE ? undefined : oldValue,\r\n onInvalidate\r\n ]);\r\n oldValue = newValue;\r\n }\r\n }\r\n else {\r\n // watchEffect\r\n effect.run();\r\n }\r\n };\r\n // important: mark the job as a watcher callback so that scheduler knows\r\n // it is allowed to self-trigger (#1727)\r\n job.allowRecurse = !!cb;\r\n let scheduler;\r\n if (flush === 'sync') {\r\n scheduler = job; // the scheduler function gets called directly\r\n }\r\n else if (flush === 'post') {\r\n scheduler = () => queuePostRenderEffect(job, instance && instance.suspense);\r\n }\r\n else {\r\n // default: 'pre'\r\n scheduler = () => {\r\n if (!instance || instance.isMounted) {\r\n queuePreFlushCb(job);\r\n }\r\n else {\r\n // with 'pre' option, the first call must happen before\r\n // the component is mounted so it is called synchronously.\r\n job();\r\n }\r\n };\r\n }\r\n const effect = new ReactiveEffect(getter, scheduler);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n effect.onTrack = onTrack;\r\n effect.onTrigger = onTrigger;\r\n }\r\n // initial run\r\n if (cb) {\r\n if (immediate) {\r\n job();\r\n }\r\n else {\r\n oldValue = effect.run();\r\n }\r\n }\r\n else if (flush === 'post') {\r\n queuePostRenderEffect(effect.run.bind(effect), instance && instance.suspense);\r\n }\r\n else {\r\n effect.run();\r\n }\r\n return () => {\r\n effect.stop();\r\n if (instance && instance.scope) {\r\n remove(instance.scope.effects, effect);\r\n }\r\n };\r\n}\r\n// this.$watch\r\nfunction instanceWatch(source, value, options) {\r\n const publicThis = this.proxy;\r\n const getter = isString(source)\r\n ? source.includes('.')\r\n ? createPathGetter(publicThis, source)\r\n : () => publicThis[source]\r\n : source.bind(publicThis, publicThis);\r\n let cb;\r\n if (isFunction(value)) {\r\n cb = value;\r\n }\r\n else {\r\n cb = value.handler;\r\n options = value;\r\n }\r\n const cur = currentInstance;\r\n setCurrentInstance(this);\r\n const res = doWatch(getter, cb.bind(publicThis), options);\r\n if (cur) {\r\n setCurrentInstance(cur);\r\n }\r\n else {\r\n unsetCurrentInstance();\r\n }\r\n return res;\r\n}\r\nfunction createPathGetter(ctx, path) {\r\n const segments = path.split('.');\r\n return () => {\r\n let cur = ctx;\r\n for (let i = 0; i < segments.length && cur; i++) {\r\n cur = cur[segments[i]];\r\n }\r\n return cur;\r\n };\r\n}\r\nfunction traverse(value, seen) {\r\n if (!isObject(value) || value[\"__v_skip\" /* SKIP */]) {\r\n return value;\r\n }\r\n seen = seen || new Set();\r\n if (seen.has(value)) {\r\n return value;\r\n }\r\n seen.add(value);\r\n if (isRef(value)) {\r\n traverse(value.value, seen);\r\n }\r\n else if (isArray(value)) {\r\n for (let i = 0; i < value.length; i++) {\r\n traverse(value[i], seen);\r\n }\r\n }\r\n else if (isSet(value) || isMap(value)) {\r\n value.forEach((v) => {\r\n traverse(v, seen);\r\n });\r\n }\r\n else if (isPlainObject(value)) {\r\n for (const key in value) {\r\n traverse(value[key], seen);\r\n }\r\n }\r\n return value;\r\n}\n\n// dev only\r\nconst warnRuntimeUsage = (method) => warn(`${method}() is a compiler-hint helper that is only usable inside ` +\r\n `<script setup> of a single file component. Its arguments should be ` +\r\n `compiled away and passing it at runtime has no effect.`);\r\n// implementation\r\nfunction defineProps() {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineProps`);\r\n }\r\n return null;\r\n}\r\n// implementation\r\nfunction defineEmits() {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineEmits`);\r\n }\r\n return null;\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for declaring a component's exposed\r\n * instance properties when it is accessed by a parent component via template\r\n * refs.\r\n *\r\n * `<script setup>` components are closed by default - i.e. varaibles inside\r\n * the `<script setup>` scope is not exposed to parent unless explicitly exposed\r\n * via `defineExpose`.\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the\r\n * output and should **not** be actually called at runtime.\r\n */\r\nfunction defineExpose(exposed) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineExpose`);\r\n }\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for providing props default values when\r\n * using type-based `defineProps` declaration.\r\n *\r\n * Example usage:\r\n * ```ts\r\n * withDefaults(defineProps<{\r\n * size?: number\r\n * labels?: string[]\r\n * }>(), {\r\n * size: 3,\r\n * labels: () => ['default label']\r\n * })\r\n * ```\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the output\r\n * and should **not** be actually called at runtime.\r\n */\r\nfunction withDefaults(props, defaults) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`withDefaults`);\r\n }\r\n return null;\r\n}\r\nfunction useSlots() {\r\n return getContext().slots;\r\n}\r\nfunction useAttrs() {\r\n return getContext().attrs;\r\n}\r\nfunction getContext() {\r\n const i = getCurrentInstance();\r\n if ((process.env.NODE_ENV !== 'production') && !i) {\r\n warn(`useContext() called without active instance.`);\r\n }\r\n return i.setupContext || (i.setupContext = createSetupContext(i));\r\n}\r\n/**\r\n * Runtime helper for merging default declarations. Imported by compiled code\r\n * only.\r\n * @internal\r\n */\r\nfunction mergeDefaults(raw, defaults) {\r\n const props = isArray(raw)\r\n ? raw.reduce((normalized, p) => ((normalized[p] = {}), normalized), {})\r\n : raw;\r\n for (const key in defaults) {\r\n const opt = props[key];\r\n if (opt) {\r\n if (isArray(opt) || isFunction(opt)) {\r\n props[key] = { type: opt, default: defaults[key] };\r\n }\r\n else {\r\n opt.default = defaults[key];\r\n }\r\n }\r\n else if (opt === null) {\r\n props[key] = { default: defaults[key] };\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`props default key \"${key}\" has no corresponding declaration.`);\r\n }\r\n }\r\n return props;\r\n}\r\n/**\r\n * Used to create a proxy for the rest element when destructuring props with\r\n * defineProps().\r\n * @internal\r\n */\r\nfunction createPropsRestProxy(props, excludedKeys) {\r\n const ret = {};\r\n for (const key in props) {\r\n if (!excludedKeys.includes(key)) {\r\n Object.defineProperty(ret, key, {\r\n enumerable: true,\r\n get: () => props[key]\r\n });\r\n }\r\n }\r\n return ret;\r\n}\r\n/**\r\n * `<script setup>` helper for persisting the current instance context over\r\n * async/await flows.\r\n *\r\n * `@vue/compiler-sfc` converts the following:\r\n *\r\n * ```ts\r\n * const x = await foo()\r\n * ```\r\n *\r\n * into:\r\n *\r\n * ```ts\r\n * let __temp, __restore\r\n * const x = (([__temp, __restore] = withAsyncContext(() => foo())),__temp=await __temp,__restore(),__temp)\r\n * ```\r\n * @internal\r\n */\r\nfunction withAsyncContext(getAwaitable) {\r\n const ctx = getCurrentInstance();\r\n if ((process.env.NODE_ENV !== 'production') && !ctx) {\r\n warn(`withAsyncContext called without active current instance. ` +\r\n `This is likely a bug.`);\r\n }\r\n let awaitable = getAwaitable();\r\n unsetCurrentInstance();\r\n if (isPromise(awaitable)) {\r\n awaitable = awaitable.catch(e => {\r\n setCurrentInstance(ctx);\r\n throw e;\r\n });\r\n }\r\n return [awaitable, () => setCurrentInstance(ctx)];\r\n}\n\n// Actual implementation\r\nfunction h(type, propsOrChildren, children) {\r\n const l = arguments.length;\r\n if (l === 2) {\r\n if (isObject(propsOrChildren) && !isArray(propsOrChildren)) {\r\n // single vnode without props\r\n if (isVNode(propsOrChildren)) {\r\n return createVNode(type, null, [propsOrChildren]);\r\n }\r\n // props without children\r\n return createVNode(type, propsOrChildren);\r\n }\r\n else {\r\n // omit props\r\n return createVNode(type, null, propsOrChildren);\r\n }\r\n }\r\n else {\r\n if (l > 3) {\r\n children = Array.prototype.slice.call(arguments, 2);\r\n }\r\n else if (l === 3 && isVNode(children)) {\r\n children = [children];\r\n }\r\n return createVNode(type, propsOrChildren, children);\r\n }\r\n}\n\nconst ssrContextKey = Symbol((process.env.NODE_ENV !== 'production') ? `ssrContext` : ``);\r\nconst useSSRContext = () => {\r\n {\r\n const ctx = inject(ssrContextKey);\r\n if (!ctx) {\r\n warn(`Server rendering context not provided. Make sure to only call ` +\r\n `useSSRContext() conditionally in the server build.`);\r\n }\r\n return ctx;\r\n }\r\n};\n\nfunction initCustomFormatter() {\r\n /* eslint-disable no-restricted-globals */\r\n if (!(process.env.NODE_ENV !== 'production') || typeof window === 'undefined') {\r\n return;\r\n }\r\n const vueStyle = { style: 'color:#3ba776' };\r\n const numberStyle = { style: 'color:#0b1bc9' };\r\n const stringStyle = { style: 'color:#b62e24' };\r\n const keywordStyle = { style: 'color:#9d288c' };\r\n // custom formatter for Chrome\r\n // https://www.mattzeunert.com/2016/02/19/custom-chrome-devtools-object-formatters.html\r\n const formatter = {\r\n header(obj) {\r\n // TODO also format ComponentPublicInstance & ctx.slots/attrs in setup\r\n if (!isObject(obj)) {\r\n return null;\r\n }\r\n if (obj.__isVue) {\r\n return ['div', vueStyle, `VueInstance`];\r\n }\r\n else if (isRef(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, genRefFlag(obj)],\r\n '<',\r\n formatValue(obj.value),\r\n `>`\r\n ];\r\n }\r\n else if (isReactive(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, 'Reactive'],\r\n '<',\r\n formatValue(obj),\r\n `>${isReadonly(obj) ? ` (readonly)` : ``}`\r\n ];\r\n }\r\n else if (isReadonly(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, 'Readonly'],\r\n '<',\r\n formatValue(obj),\r\n '>'\r\n ];\r\n }\r\n return null;\r\n },\r\n hasBody(obj) {\r\n return obj && obj.__isVue;\r\n },\r\n body(obj) {\r\n if (obj && obj.__isVue) {\r\n return [\r\n 'div',\r\n {},\r\n ...formatInstance(obj.$)\r\n ];\r\n }\r\n }\r\n };\r\n function formatInstance(instance) {\r\n const blocks = [];\r\n if (instance.type.props && instance.props) {\r\n blocks.push(createInstanceBlock('props', toRaw(instance.props)));\r\n }\r\n if (instance.setupState !== EMPTY_OBJ) {\r\n blocks.push(createInstanceBlock('setup', instance.setupState));\r\n }\r\n if (instance.data !== EMPTY_OBJ) {\r\n blocks.push(createInstanceBlock('data', toRaw(instance.data)));\r\n }\r\n const computed = extractKeys(instance, 'computed');\r\n if (computed) {\r\n blocks.push(createInstanceBlock('computed', computed));\r\n }\r\n const injected = extractKeys(instance, 'inject');\r\n if (injected) {\r\n blocks.push(createInstanceBlock('injected', injected));\r\n }\r\n blocks.push([\r\n 'div',\r\n {},\r\n [\r\n 'span',\r\n {\r\n style: keywordStyle.style + ';opacity:0.66'\r\n },\r\n '$ (internal): '\r\n ],\r\n ['object', { object: instance }]\r\n ]);\r\n return blocks;\r\n }\r\n function createInstanceBlock(type, target) {\r\n target = extend({}, target);\r\n if (!Object.keys(target).length) {\r\n return ['span', {}];\r\n }\r\n return [\r\n 'div',\r\n { style: 'line-height:1.25em;margin-bottom:0.6em' },\r\n [\r\n 'div',\r\n {\r\n style: 'color:#476582'\r\n },\r\n type\r\n ],\r\n [\r\n 'div',\r\n {\r\n style: 'padding-left:1.25em'\r\n },\r\n ...Object.keys(target).map(key => {\r\n return [\r\n 'div',\r\n {},\r\n ['span', keywordStyle, key + ': '],\r\n formatValue(target[key], false)\r\n ];\r\n })\r\n ]\r\n ];\r\n }\r\n function formatValue(v, asRaw = true) {\r\n if (typeof v === 'number') {\r\n return ['span', numberStyle, v];\r\n }\r\n else if (typeof v === 'string') {\r\n return ['span', stringStyle, JSON.stringify(v)];\r\n }\r\n else if (typeof v === 'boolean') {\r\n return ['span', keywordStyle, v];\r\n }\r\n else if (isObject(v)) {\r\n return ['object', { object: asRaw ? toRaw(v) : v }];\r\n }\r\n else {\r\n return ['span', stringStyle, String(v)];\r\n }\r\n }\r\n function extractKeys(instance, type) {\r\n const Comp = instance.type;\r\n if (isFunction(Comp)) {\r\n return;\r\n }\r\n const extracted = {};\r\n for (const key in instance.ctx) {\r\n if (isKeyOfType(Comp, key, type)) {\r\n extracted[key] = instance.ctx[key];\r\n }\r\n }\r\n return extracted;\r\n }\r\n function isKeyOfType(Comp, key, type) {\r\n const opts = Comp[type];\r\n if ((isArray(opts) && opts.includes(key)) ||\r\n (isObject(opts) && key in opts)) {\r\n return true;\r\n }\r\n if (Comp.extends && isKeyOfType(Comp.extends, key, type)) {\r\n return true;\r\n }\r\n if (Comp.mixins && Comp.mixins.some(m => isKeyOfType(m, key, type))) {\r\n return true;\r\n }\r\n }\r\n function genRefFlag(v) {\r\n if (v._shallow) {\r\n return `ShallowRef`;\r\n }\r\n if (v.effect) {\r\n return `ComputedRef`;\r\n }\r\n return `Ref`;\r\n }\r\n if (window.devtoolsFormatters) {\r\n window.devtoolsFormatters.push(formatter);\r\n }\r\n else {\r\n window.devtoolsFormatters = [formatter];\r\n }\r\n}\n\nfunction withMemo(memo, render, cache, index) {\r\n const cached = cache[index];\r\n if (cached && isMemoSame(cached, memo)) {\r\n return cached;\r\n }\r\n const ret = render();\r\n // shallow clone\r\n ret.memo = memo.slice();\r\n return (cache[index] = ret);\r\n}\r\nfunction isMemoSame(cached, memo) {\r\n const prev = cached.memo;\r\n if (prev.length != memo.length) {\r\n return false;\r\n }\r\n for (let i = 0; i < prev.length; i++) {\r\n if (prev[i] !== memo[i]) {\r\n return false;\r\n }\r\n }\r\n // make sure to let parent block track it when returning cached\r\n if (isBlockTreeEnabled > 0 && currentBlock) {\r\n currentBlock.push(cached);\r\n }\r\n return true;\r\n}\n\n// Core API ------------------------------------------------------------------\r\nconst version = \"3.2.26\";\r\nconst _ssrUtils = {\r\n createComponentInstance,\r\n setupComponent,\r\n renderComponentRoot,\r\n setCurrentRenderingInstance,\r\n isVNode,\r\n normalizeVNode\r\n};\r\n/**\r\n * SSR utils for \\@vue/server-renderer. Only exposed in cjs builds.\r\n * @internal\r\n */\r\nconst ssrUtils = (_ssrUtils );\r\n/**\r\n * @internal only exposed in compat builds\r\n */\r\nconst resolveFilter = null;\r\n/**\r\n * @internal only exposed in compat builds.\r\n */\r\nconst compatUtils = (null);\n\nexport { BaseTransition, Comment, Fragment, KeepAlive, Static, Suspense, Teleport, Text, callWithAsyncErrorHandling, callWithErrorHandling, cloneVNode, compatUtils, createBlock, createCommentVNode, createElementBlock, createBaseVNode as createElementVNode, createHydrationRenderer, createPropsRestProxy, createRenderer, createSlots, createStaticVNode, createTextVNode, createVNode, defineAsyncComponent, defineComponent, defineEmits, defineExpose, defineProps, devtools, getCurrentInstance, getTransitionRawChildren, guardReactiveProps, h, handleError, initCustomFormatter, inject, isMemoSame, isRuntimeOnly, isVNode, mergeDefaults, mergeProps, nextTick, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, onUpdated, openBlock, popScopeId, provide, pushScopeId, queuePostFlushCb, registerRuntimeCompiler, renderList, renderSlot, resolveComponent, resolveDirective, resolveDynamicComponent, resolveFilter, resolveTransitionHooks, setBlockTracking, setDevtoolsHook, setTransitionHooks, ssrContextKey, ssrUtils, toHandlers, transformVNodeArgs, useAttrs, useSSRContext, useSlots, useTransitionState, version, warn, watch, watchEffect, watchPostEffect, watchSyncEffect, withAsyncContext, withCtx, withDefaults, withDirectives, withMemo, withScopeId };\n","import { camelize, warn, callWithAsyncErrorHandling, defineComponent, nextTick, createVNode, getCurrentInstance, watchPostEffect, onMounted, onUnmounted, Fragment, Static, h, BaseTransition, useTransitionState, onUpdated, toRaw, getTransitionRawChildren, setTransitionHooks, resolveTransitionHooks, createRenderer, isRuntimeOnly, createHydrationRenderer } from '@vue/runtime-core';\nexport * from '@vue/runtime-core';\nimport { isString, isArray, hyphenate, capitalize, isSpecialBooleanAttr, includeBooleanAttr, isOn, isModelListener, isFunction, toNumber, camelize as camelize$1, extend, EMPTY_OBJ, isObject, invokeArrayFns, looseIndexOf, isSet, looseEqual, isHTMLTag, isSVGTag } from '@vue/shared';\n\nconst svgNS = 'http://www.w3.org/2000/svg';\r\nconst doc = (typeof document !== 'undefined' ? document : null);\r\nconst staticTemplateCache = new Map();\r\nconst nodeOps = {\r\n insert: (child, parent, anchor) => {\r\n parent.insertBefore(child, anchor || null);\r\n },\r\n remove: child => {\r\n const parent = child.parentNode;\r\n if (parent) {\r\n parent.removeChild(child);\r\n }\r\n },\r\n createElement: (tag, isSVG, is, props) => {\r\n const el = isSVG\r\n ? doc.createElementNS(svgNS, tag)\r\n : doc.createElement(tag, is ? { is } : undefined);\r\n if (tag === 'select' && props && props.multiple != null) {\r\n el.setAttribute('multiple', props.multiple);\r\n }\r\n return el;\r\n },\r\n createText: text => doc.createTextNode(text),\r\n createComment: text => doc.createComment(text),\r\n setText: (node, text) => {\r\n node.nodeValue = text;\r\n },\r\n setElementText: (el, text) => {\r\n el.textContent = text;\r\n },\r\n parentNode: node => node.parentNode,\r\n nextSibling: node => node.nextSibling,\r\n querySelector: selector => doc.querySelector(selector),\r\n setScopeId(el, id) {\r\n el.setAttribute(id, '');\r\n },\r\n cloneNode(el) {\r\n const cloned = el.cloneNode(true);\r\n // #3072\r\n // - in `patchDOMProp`, we store the actual value in the `el._value` property.\r\n // - normally, elements using `:value` bindings will not be hoisted, but if\r\n // the bound value is a constant, e.g. `:value=\"true\"` - they do get\r\n // hoisted.\r\n // - in production, hoisted nodes are cloned when subsequent inserts, but\r\n // cloneNode() does not copy the custom property we attached.\r\n // - This may need to account for other custom DOM properties we attach to\r\n // elements in addition to `_value` in the future.\r\n if (`_value` in el) {\r\n cloned._value = el._value;\r\n }\r\n return cloned;\r\n },\r\n // __UNSAFE__\r\n // Reason: innerHTML.\r\n // Static content here can only come from compiled templates.\r\n // As long as the user only uses trusted templates, this is safe.\r\n insertStaticContent(content, parent, anchor, isSVG) {\r\n // <parent> before | first ... last | anchor </parent>\r\n const before = anchor ? anchor.previousSibling : parent.lastChild;\r\n let template = staticTemplateCache.get(content);\r\n if (!template) {\r\n const t = doc.createElement('template');\r\n t.innerHTML = isSVG ? `<svg>${content}</svg>` : content;\r\n template = t.content;\r\n if (isSVG) {\r\n // remove outer svg wrapper\r\n const wrapper = template.firstChild;\r\n while (wrapper.firstChild) {\r\n template.appendChild(wrapper.firstChild);\r\n }\r\n template.removeChild(wrapper);\r\n }\r\n staticTemplateCache.set(content, template);\r\n }\r\n parent.insertBefore(template.cloneNode(true), anchor);\r\n return [\r\n // first\r\n before ? before.nextSibling : parent.firstChild,\r\n // last\r\n anchor ? anchor.previousSibling : parent.lastChild\r\n ];\r\n }\r\n};\n\n// compiler should normalize class + :class bindings on the same element\r\n// into a single binding ['staticClass', dynamic]\r\nfunction patchClass(el, value, isSVG) {\r\n // directly setting className should be faster than setAttribute in theory\r\n // if this is an element during a transition, take the temporary transition\r\n // classes into account.\r\n const transitionClasses = el._vtc;\r\n if (transitionClasses) {\r\n value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(' ');\r\n }\r\n if (value == null) {\r\n el.removeAttribute('class');\r\n }\r\n else if (isSVG) {\r\n el.setAttribute('class', value);\r\n }\r\n else {\r\n el.className = value;\r\n }\r\n}\n\nfunction patchStyle(el, prev, next) {\r\n const style = el.style;\r\n const isCssString = isString(next);\r\n if (next && !isCssString) {\r\n for (const key in next) {\r\n setStyle(style, key, next[key]);\r\n }\r\n if (prev && !isString(prev)) {\r\n for (const key in prev) {\r\n if (next[key] == null) {\r\n setStyle(style, key, '');\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n const currentDisplay = style.display;\r\n if (isCssString) {\r\n if (prev !== next) {\r\n style.cssText = next;\r\n }\r\n }\r\n else if (prev) {\r\n el.removeAttribute('style');\r\n }\r\n // indicates that the `display` of the element is controlled by `v-show`,\r\n // so we always keep the current `display` value regardless of the `style`\r\n // value, thus handing over control to `v-show`.\r\n if ('_vod' in el) {\r\n style.display = currentDisplay;\r\n }\r\n }\r\n}\r\nconst importantRE = /\\s*!important$/;\r\nfunction setStyle(style, name, val) {\r\n if (isArray(val)) {\r\n val.forEach(v => setStyle(style, name, v));\r\n }\r\n else {\r\n if (name.startsWith('--')) {\r\n // custom property definition\r\n style.setProperty(name, val);\r\n }\r\n else {\r\n const prefixed = autoPrefix(style, name);\r\n if (importantRE.test(val)) {\r\n // !important\r\n style.setProperty(hyphenate(prefixed), val.replace(importantRE, ''), 'important');\r\n }\r\n else {\r\n style[prefixed] = val;\r\n }\r\n }\r\n }\r\n}\r\nconst prefixes = ['Webkit', 'Moz', 'ms'];\r\nconst prefixCache = {};\r\nfunction autoPrefix(style, rawName) {\r\n const cached = prefixCache[rawName];\r\n if (cached) {\r\n return cached;\r\n }\r\n let name = camelize(rawName);\r\n if (name !== 'filter' && name in style) {\r\n return (prefixCache[rawName] = name);\r\n }\r\n name = capitalize(name);\r\n for (let i = 0; i < prefixes.length; i++) {\r\n const prefixed = prefixes[i] + name;\r\n if (prefixed in style) {\r\n return (prefixCache[rawName] = prefixed);\r\n }\r\n }\r\n return rawName;\r\n}\n\nconst xlinkNS = 'http://www.w3.org/1999/xlink';\r\nfunction patchAttr(el, key, value, isSVG, instance) {\r\n if (isSVG && key.startsWith('xlink:')) {\r\n if (value == null) {\r\n el.removeAttributeNS(xlinkNS, key.slice(6, key.length));\r\n }\r\n else {\r\n el.setAttributeNS(xlinkNS, key, value);\r\n }\r\n }\r\n else {\r\n // note we are only checking boolean attributes that don't have a\r\n // corresponding dom prop of the same name here.\r\n const isBoolean = isSpecialBooleanAttr(key);\r\n if (value == null || (isBoolean && !includeBooleanAttr(value))) {\r\n el.removeAttribute(key);\r\n }\r\n else {\r\n el.setAttribute(key, isBoolean ? '' : value);\r\n }\r\n }\r\n}\n\n// __UNSAFE__\r\n// functions. The user is responsible for using them with only trusted content.\r\nfunction patchDOMProp(el, key, value, \r\n// the following args are passed only due to potential innerHTML/textContent\r\n// overriding existing VNodes, in which case the old tree must be properly\r\n// unmounted.\r\nprevChildren, parentComponent, parentSuspense, unmountChildren) {\r\n if (key === 'innerHTML' || key === 'textContent') {\r\n if (prevChildren) {\r\n unmountChildren(prevChildren, parentComponent, parentSuspense);\r\n }\r\n el[key] = value == null ? '' : value;\r\n return;\r\n }\r\n if (key === 'value' &&\r\n el.tagName !== 'PROGRESS' &&\r\n // custom elements may use _value internally\r\n !el.tagName.includes('-')) {\r\n // store value as _value as well since\r\n // non-string values will be stringified.\r\n el._value = value;\r\n const newValue = value == null ? '' : value;\r\n if (el.value !== newValue ||\r\n // #4956: always set for OPTION elements because its value falls back to\r\n // textContent if no value attribute is present. And setting .value for\r\n // OPTION has no side effect\r\n el.tagName === 'OPTION') {\r\n el.value = newValue;\r\n }\r\n if (value == null) {\r\n el.removeAttribute(key);\r\n }\r\n return;\r\n }\r\n if (value === '' || value == null) {\r\n const type = typeof el[key];\r\n if (type === 'boolean') {\r\n // e.g. <select multiple> compiles to { multiple: '' }\r\n el[key] = includeBooleanAttr(value);\r\n return;\r\n }\r\n else if (value == null && type === 'string') {\r\n // e.g. <div :id=\"null\">\r\n el[key] = '';\r\n el.removeAttribute(key);\r\n return;\r\n }\r\n else if (type === 'number') {\r\n // e.g. <img :width=\"null\">\r\n // the value of some IDL attr must be greater than 0, e.g. input.size = 0 -> error\r\n try {\r\n el[key] = 0;\r\n }\r\n catch (_a) { }\r\n el.removeAttribute(key);\r\n return;\r\n }\r\n }\r\n // some properties perform value validation and throw\r\n try {\r\n el[key] = value;\r\n }\r\n catch (e) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Failed setting prop \"${key}\" on <${el.tagName.toLowerCase()}>: ` +\r\n `value ${value} is invalid.`, e);\r\n }\r\n }\r\n}\n\n// Async edge case fix requires storing an event listener's attach timestamp.\r\nlet _getNow = Date.now;\r\nlet skipTimestampCheck = false;\r\nif (typeof window !== 'undefined') {\r\n // Determine what event timestamp the browser is using. Annoyingly, the\r\n // timestamp can either be hi-res (relative to page load) or low-res\r\n // (relative to UNIX epoch), so in order to compare time we have to use the\r\n // same timestamp type when saving the flush timestamp.\r\n if (_getNow() > document.createEvent('Event').timeStamp) {\r\n // if the low-res timestamp which is bigger than the event timestamp\r\n // (which is evaluated AFTER) it means the event is using a hi-res timestamp,\r\n // and we need to use the hi-res version for event listeners as well.\r\n _getNow = () => performance.now();\r\n }\r\n // #3485: Firefox <= 53 has incorrect Event.timeStamp implementation\r\n // and does not fire microtasks in between event propagation, so safe to exclude.\r\n const ffMatch = navigator.userAgent.match(/firefox\\/(\\d+)/i);\r\n skipTimestampCheck = !!(ffMatch && Number(ffMatch[1]) <= 53);\r\n}\r\n// To avoid the overhead of repeatedly calling performance.now(), we cache\r\n// and use the same timestamp for all event listeners attached in the same tick.\r\nlet cachedNow = 0;\r\nconst p = Promise.resolve();\r\nconst reset = () => {\r\n cachedNow = 0;\r\n};\r\nconst getNow = () => cachedNow || (p.then(reset), (cachedNow = _getNow()));\r\nfunction addEventListener(el, event, handler, options) {\r\n el.addEventListener(event, handler, options);\r\n}\r\nfunction removeEventListener(el, event, handler, options) {\r\n el.removeEventListener(event, handler, options);\r\n}\r\nfunction patchEvent(el, rawName, prevValue, nextValue, instance = null) {\r\n // vei = vue event invokers\r\n const invokers = el._vei || (el._vei = {});\r\n const existingInvoker = invokers[rawName];\r\n if (nextValue && existingInvoker) {\r\n // patch\r\n existingInvoker.value = nextValue;\r\n }\r\n else {\r\n const [name, options] = parseName(rawName);\r\n if (nextValue) {\r\n // add\r\n const invoker = (invokers[rawName] = createInvoker(nextValue, instance));\r\n addEventListener(el, name, invoker, options);\r\n }\r\n else if (existingInvoker) {\r\n // remove\r\n removeEventListener(el, name, existingInvoker, options);\r\n invokers[rawName] = undefined;\r\n }\r\n }\r\n}\r\nconst optionsModifierRE = /(?:Once|Passive|Capture)$/;\r\nfunction parseName(name) {\r\n let options;\r\n if (optionsModifierRE.test(name)) {\r\n options = {};\r\n let m;\r\n while ((m = name.match(optionsModifierRE))) {\r\n name = name.slice(0, name.length - m[0].length);\r\n options[m[0].toLowerCase()] = true;\r\n }\r\n }\r\n return [hyphenate(name.slice(2)), options];\r\n}\r\nfunction createInvoker(initialValue, instance) {\r\n const invoker = (e) => {\r\n // async edge case #6566: inner click event triggers patch, event handler\r\n // attached to outer element during patch, and triggered again. This\r\n // happens because browsers fire microtask ticks between event propagation.\r\n // the solution is simple: we save the timestamp when a handler is attached,\r\n // and the handler would only fire if the event passed to it was fired\r\n // AFTER it was attached.\r\n const timeStamp = e.timeStamp || _getNow();\r\n if (skipTimestampCheck || timeStamp >= invoker.attached - 1) {\r\n callWithAsyncErrorHandling(patchStopImmediatePropagation(e, invoker.value), instance, 5 /* NATIVE_EVENT_HANDLER */, [e]);\r\n }\r\n };\r\n invoker.value = initialValue;\r\n invoker.attached = getNow();\r\n return invoker;\r\n}\r\nfunction patchStopImmediatePropagation(e, value) {\r\n if (isArray(value)) {\r\n const originalStop = e.stopImmediatePropagation;\r\n e.stopImmediatePropagation = () => {\r\n originalStop.call(e);\r\n e._stopped = true;\r\n };\r\n return value.map(fn => (e) => !e._stopped && fn(e));\r\n }\r\n else {\r\n return value;\r\n }\r\n}\n\nconst nativeOnRE = /^on[a-z]/;\r\nconst patchProp = (el, key, prevValue, nextValue, isSVG = false, prevChildren, parentComponent, parentSuspense, unmountChildren) => {\r\n if (key === 'class') {\r\n patchClass(el, nextValue, isSVG);\r\n }\r\n else if (key === 'style') {\r\n patchStyle(el, prevValue, nextValue);\r\n }\r\n else if (isOn(key)) {\r\n // ignore v-model listeners\r\n if (!isModelListener(key)) {\r\n patchEvent(el, key, prevValue, nextValue, parentComponent);\r\n }\r\n }\r\n else if (key[0] === '.'\r\n ? ((key = key.slice(1)), true)\r\n : key[0] === '^'\r\n ? ((key = key.slice(1)), false)\r\n : shouldSetAsProp(el, key, nextValue, isSVG)) {\r\n patchDOMProp(el, key, nextValue, prevChildren, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n else {\r\n // special case for <input v-model type=\"checkbox\"> with\r\n // :true-value & :false-value\r\n // store value as dom properties since non-string values will be\r\n // stringified.\r\n if (key === 'true-value') {\r\n el._trueValue = nextValue;\r\n }\r\n else if (key === 'false-value') {\r\n el._falseValue = nextValue;\r\n }\r\n patchAttr(el, key, nextValue, isSVG);\r\n }\r\n};\r\nfunction shouldSetAsProp(el, key, value, isSVG) {\r\n if (isSVG) {\r\n // most keys must be set as attribute on svg elements to work\r\n // ...except innerHTML & textContent\r\n if (key === 'innerHTML' || key === 'textContent') {\r\n return true;\r\n }\r\n // or native onclick with function values\r\n if (key in el && nativeOnRE.test(key) && isFunction(value)) {\r\n return true;\r\n }\r\n return false;\r\n }\r\n // spellcheck and draggable are numerated attrs, however their\r\n // corresponding DOM properties are actually booleans - this leads to\r\n // setting it with a string \"false\" value leading it to be coerced to\r\n // `true`, so we need to always treat them as attributes.\r\n // Note that `contentEditable` doesn't have this problem: its DOM\r\n // property is also enumerated string values.\r\n if (key === 'spellcheck' || key === 'draggable') {\r\n return false;\r\n }\r\n // #1787, #2840 form property on form elements is readonly and must be set as\r\n // attribute.\r\n if (key === 'form') {\r\n return false;\r\n }\r\n // #1526 <input list> must be set as attribute\r\n if (key === 'list' && el.tagName === 'INPUT') {\r\n return false;\r\n }\r\n // #2766 <textarea type> must be set as attribute\r\n if (key === 'type' && el.tagName === 'TEXTAREA') {\r\n return false;\r\n }\r\n // native onclick with string value, must be set as attribute\r\n if (nativeOnRE.test(key) && isString(value)) {\r\n return false;\r\n }\r\n return key in el;\r\n}\n\nfunction defineCustomElement(options, hydate) {\r\n const Comp = defineComponent(options);\r\n class VueCustomElement extends VueElement {\r\n constructor(initialProps) {\r\n super(Comp, initialProps, hydate);\r\n }\r\n }\r\n VueCustomElement.def = Comp;\r\n return VueCustomElement;\r\n}\r\nconst defineSSRCustomElement = ((options) => {\r\n // @ts-ignore\r\n return defineCustomElement(options, hydrate);\r\n});\r\nconst BaseClass = (typeof HTMLElement !== 'undefined' ? HTMLElement : class {\r\n});\r\nclass VueElement extends BaseClass {\r\n constructor(_def, _props = {}, hydrate) {\r\n super();\r\n this._def = _def;\r\n this._props = _props;\r\n /**\r\n * @internal\r\n */\r\n this._instance = null;\r\n this._connected = false;\r\n this._resolved = false;\r\n this._numberProps = null;\r\n if (this.shadowRoot && hydrate) {\r\n hydrate(this._createVNode(), this.shadowRoot);\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && this.shadowRoot) {\r\n warn(`Custom element has pre-rendered declarative shadow root but is not ` +\r\n `defined as hydratable. Use \\`defineSSRCustomElement\\`.`);\r\n }\r\n this.attachShadow({ mode: 'open' });\r\n }\r\n }\r\n connectedCallback() {\r\n this._connected = true;\r\n if (!this._instance) {\r\n this._resolveDef();\r\n }\r\n }\r\n disconnectedCallback() {\r\n this._connected = false;\r\n nextTick(() => {\r\n if (!this._connected) {\r\n render(null, this.shadowRoot);\r\n this._instance = null;\r\n }\r\n });\r\n }\r\n /**\r\n * resolve inner component definition (handle possible async component)\r\n */\r\n _resolveDef() {\r\n if (this._resolved) {\r\n return;\r\n }\r\n this._resolved = true;\r\n // set initial attrs\r\n for (let i = 0; i < this.attributes.length; i++) {\r\n this._setAttr(this.attributes[i].name);\r\n }\r\n // watch future attr changes\r\n new MutationObserver(mutations => {\r\n for (const m of mutations) {\r\n this._setAttr(m.attributeName);\r\n }\r\n }).observe(this, { attributes: true });\r\n const resolve = (def) => {\r\n const { props, styles } = def;\r\n const hasOptions = !isArray(props);\r\n const rawKeys = props ? (hasOptions ? Object.keys(props) : props) : [];\r\n // cast Number-type props set before resolve\r\n let numberProps;\r\n if (hasOptions) {\r\n for (const key in this._props) {\r\n const opt = props[key];\r\n if (opt === Number || (opt && opt.type === Number)) {\r\n this._props[key] = toNumber(this._props[key]);\r\n (numberProps || (numberProps = Object.create(null)))[key] = true;\r\n }\r\n }\r\n }\r\n this._numberProps = numberProps;\r\n // check if there are props set pre-upgrade or connect\r\n for (const key of Object.keys(this)) {\r\n if (key[0] !== '_') {\r\n this._setProp(key, this[key], true, false);\r\n }\r\n }\r\n // defining getter/setters on prototype\r\n for (const key of rawKeys.map(camelize$1)) {\r\n Object.defineProperty(this, key, {\r\n get() {\r\n return this._getProp(key);\r\n },\r\n set(val) {\r\n this._setProp(key, val);\r\n }\r\n });\r\n }\r\n // apply CSS\r\n this._applyStyles(styles);\r\n // initial render\r\n this._update();\r\n };\r\n const asyncDef = this._def.__asyncLoader;\r\n if (asyncDef) {\r\n asyncDef().then(resolve);\r\n }\r\n else {\r\n resolve(this._def);\r\n }\r\n }\r\n _setAttr(key) {\r\n let value = this.getAttribute(key);\r\n if (this._numberProps && this._numberProps[key]) {\r\n value = toNumber(value);\r\n }\r\n this._setProp(camelize$1(key), value, false);\r\n }\r\n /**\r\n * @internal\r\n */\r\n _getProp(key) {\r\n return this._props[key];\r\n }\r\n /**\r\n * @internal\r\n */\r\n _setProp(key, val, shouldReflect = true, shouldUpdate = true) {\r\n if (val !== this._props[key]) {\r\n this._props[key] = val;\r\n if (shouldUpdate && this._instance) {\r\n this._update();\r\n }\r\n // reflect\r\n if (shouldReflect) {\r\n if (val === true) {\r\n this.setAttribute(hyphenate(key), '');\r\n }\r\n else if (typeof val === 'string' || typeof val === 'number') {\r\n this.setAttribute(hyphenate(key), val + '');\r\n }\r\n else if (!val) {\r\n this.removeAttribute(hyphenate(key));\r\n }\r\n }\r\n }\r\n }\r\n _update() {\r\n render(this._createVNode(), this.shadowRoot);\r\n }\r\n _createVNode() {\r\n const vnode = createVNode(this._def, extend({}, this._props));\r\n if (!this._instance) {\r\n vnode.ce = instance => {\r\n this._instance = instance;\r\n instance.isCE = true;\r\n // HMR\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n instance.ceReload = newStyles => {\r\n // always reset styles\r\n if (this._styles) {\r\n this._styles.forEach(s => this.shadowRoot.removeChild(s));\r\n this._styles.length = 0;\r\n }\r\n this._applyStyles(newStyles);\r\n // if this is an async component, ceReload is called from the inner\r\n // component so no need to reload the async wrapper\r\n if (!this._def.__asyncLoader) {\r\n // reload\r\n this._instance = null;\r\n this._update();\r\n }\r\n };\r\n }\r\n // intercept emit\r\n instance.emit = (event, ...args) => {\r\n this.dispatchEvent(new CustomEvent(event, {\r\n detail: args\r\n }));\r\n };\r\n // locate nearest Vue custom element parent for provide/inject\r\n let parent = this;\r\n while ((parent =\r\n parent && (parent.parentNode || parent.host))) {\r\n if (parent instanceof VueElement) {\r\n instance.parent = parent._instance;\r\n break;\r\n }\r\n }\r\n };\r\n }\r\n return vnode;\r\n }\r\n _applyStyles(styles) {\r\n if (styles) {\r\n styles.forEach(css => {\r\n const s = document.createElement('style');\r\n s.textContent = css;\r\n this.shadowRoot.appendChild(s);\r\n // record for HMR\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n (this._styles || (this._styles = [])).push(s);\r\n }\r\n });\r\n }\r\n }\r\n}\n\nfunction useCssModule(name = '$style') {\r\n /* istanbul ignore else */\r\n {\r\n const instance = getCurrentInstance();\r\n if (!instance) {\r\n (process.env.NODE_ENV !== 'production') && warn(`useCssModule must be called inside setup()`);\r\n return EMPTY_OBJ;\r\n }\r\n const modules = instance.type.__cssModules;\r\n if (!modules) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Current instance does not have CSS modules injected.`);\r\n return EMPTY_OBJ;\r\n }\r\n const mod = modules[name];\r\n if (!mod) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Current instance does not have CSS module named \"${name}\".`);\r\n return EMPTY_OBJ;\r\n }\r\n return mod;\r\n }\r\n}\n\n/**\r\n * Runtime helper for SFC's CSS variable injection feature.\r\n * @private\r\n */\r\nfunction useCssVars(getter) {\r\n const instance = getCurrentInstance();\r\n /* istanbul ignore next */\r\n if (!instance) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`useCssVars is called without current active component instance.`);\r\n return;\r\n }\r\n const setVars = () => setVarsOnVNode(instance.subTree, getter(instance.proxy));\r\n watchPostEffect(setVars);\r\n onMounted(() => {\r\n const ob = new MutationObserver(setVars);\r\n ob.observe(instance.subTree.el.parentNode, { childList: true });\r\n onUnmounted(() => ob.disconnect());\r\n });\r\n}\r\nfunction setVarsOnVNode(vnode, vars) {\r\n if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n const suspense = vnode.suspense;\r\n vnode = suspense.activeBranch;\r\n if (suspense.pendingBranch && !suspense.isHydrating) {\r\n suspense.effects.push(() => {\r\n setVarsOnVNode(suspense.activeBranch, vars);\r\n });\r\n }\r\n }\r\n // drill down HOCs until it's a non-component vnode\r\n while (vnode.component) {\r\n vnode = vnode.component.subTree;\r\n }\r\n if (vnode.shapeFlag & 1 /* ELEMENT */ && vnode.el) {\r\n setVarsOnNode(vnode.el, vars);\r\n }\r\n else if (vnode.type === Fragment) {\r\n vnode.children.forEach(c => setVarsOnVNode(c, vars));\r\n }\r\n else if (vnode.type === Static) {\r\n let { el, anchor } = vnode;\r\n while (el) {\r\n setVarsOnNode(el, vars);\r\n if (el === anchor)\r\n break;\r\n el = el.nextSibling;\r\n }\r\n }\r\n}\r\nfunction setVarsOnNode(el, vars) {\r\n if (el.nodeType === 1) {\r\n const style = el.style;\r\n for (const key in vars) {\r\n style.setProperty(`--${key}`, vars[key]);\r\n }\r\n }\r\n}\n\nconst TRANSITION = 'transition';\r\nconst ANIMATION = 'animation';\r\n// DOM Transition is a higher-order-component based on the platform-agnostic\r\n// base Transition component, with DOM-specific logic.\r\nconst Transition = (props, { slots }) => h(BaseTransition, resolveTransitionProps(props), slots);\r\nTransition.displayName = 'Transition';\r\nconst DOMTransitionPropsValidators = {\r\n name: String,\r\n type: String,\r\n css: {\r\n type: Boolean,\r\n default: true\r\n },\r\n duration: [String, Number, Object],\r\n enterFromClass: String,\r\n enterActiveClass: String,\r\n enterToClass: String,\r\n appearFromClass: String,\r\n appearActiveClass: String,\r\n appearToClass: String,\r\n leaveFromClass: String,\r\n leaveActiveClass: String,\r\n leaveToClass: String\r\n};\r\nconst TransitionPropsValidators = (Transition.props =\r\n /*#__PURE__*/ extend({}, BaseTransition.props, DOMTransitionPropsValidators));\r\n/**\r\n * #3227 Incoming hooks may be merged into arrays when wrapping Transition\r\n * with custom HOCs.\r\n */\r\nconst callHook = (hook, args = []) => {\r\n if (isArray(hook)) {\r\n hook.forEach(h => h(...args));\r\n }\r\n else if (hook) {\r\n hook(...args);\r\n }\r\n};\r\n/**\r\n * Check if a hook expects a callback (2nd arg), which means the user\r\n * intends to explicitly control the end of the transition.\r\n */\r\nconst hasExplicitCallback = (hook) => {\r\n return hook\r\n ? isArray(hook)\r\n ? hook.some(h => h.length > 1)\r\n : hook.length > 1\r\n : false;\r\n};\r\nfunction resolveTransitionProps(rawProps) {\r\n const baseProps = {};\r\n for (const key in rawProps) {\r\n if (!(key in DOMTransitionPropsValidators)) {\r\n baseProps[key] = rawProps[key];\r\n }\r\n }\r\n if (rawProps.css === false) {\r\n return baseProps;\r\n }\r\n const { name = 'v', type, duration, enterFromClass = `${name}-enter-from`, enterActiveClass = `${name}-enter-active`, enterToClass = `${name}-enter-to`, appearFromClass = enterFromClass, appearActiveClass = enterActiveClass, appearToClass = enterToClass, leaveFromClass = `${name}-leave-from`, leaveActiveClass = `${name}-leave-active`, leaveToClass = `${name}-leave-to` } = rawProps;\r\n const durations = normalizeDuration(duration);\r\n const enterDuration = durations && durations[0];\r\n const leaveDuration = durations && durations[1];\r\n const { onBeforeEnter, onEnter, onEnterCancelled, onLeave, onLeaveCancelled, onBeforeAppear = onBeforeEnter, onAppear = onEnter, onAppearCancelled = onEnterCancelled } = baseProps;\r\n const finishEnter = (el, isAppear, done) => {\r\n removeTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);\r\n done && done();\r\n };\r\n const finishLeave = (el, done) => {\r\n removeTransitionClass(el, leaveToClass);\r\n removeTransitionClass(el, leaveActiveClass);\r\n done && done();\r\n };\r\n const makeEnterHook = (isAppear) => {\r\n return (el, done) => {\r\n const hook = isAppear ? onAppear : onEnter;\r\n const resolve = () => finishEnter(el, isAppear, done);\r\n callHook(hook, [el, resolve]);\r\n nextFrame(() => {\r\n removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);\r\n addTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n if (!hasExplicitCallback(hook)) {\r\n whenTransitionEnds(el, type, enterDuration, resolve);\r\n }\r\n });\r\n };\r\n };\r\n return extend(baseProps, {\r\n onBeforeEnter(el) {\r\n callHook(onBeforeEnter, [el]);\r\n addTransitionClass(el, enterFromClass);\r\n addTransitionClass(el, enterActiveClass);\r\n },\r\n onBeforeAppear(el) {\r\n callHook(onBeforeAppear, [el]);\r\n addTransitionClass(el, appearFromClass);\r\n addTransitionClass(el, appearActiveClass);\r\n },\r\n onEnter: makeEnterHook(false),\r\n onAppear: makeEnterHook(true),\r\n onLeave(el, done) {\r\n const resolve = () => finishLeave(el, done);\r\n addTransitionClass(el, leaveFromClass);\r\n // force reflow so *-leave-from classes immediately take effect (#2593)\r\n forceReflow();\r\n addTransitionClass(el, leaveActiveClass);\r\n nextFrame(() => {\r\n removeTransitionClass(el, leaveFromClass);\r\n addTransitionClass(el, leaveToClass);\r\n if (!hasExplicitCallback(onLeave)) {\r\n whenTransitionEnds(el, type, leaveDuration, resolve);\r\n }\r\n });\r\n callHook(onLeave, [el, resolve]);\r\n },\r\n onEnterCancelled(el) {\r\n finishEnter(el, false);\r\n callHook(onEnterCancelled, [el]);\r\n },\r\n onAppearCancelled(el) {\r\n finishEnter(el, true);\r\n callHook(onAppearCancelled, [el]);\r\n },\r\n onLeaveCancelled(el) {\r\n finishLeave(el);\r\n callHook(onLeaveCancelled, [el]);\r\n }\r\n });\r\n}\r\nfunction normalizeDuration(duration) {\r\n if (duration == null) {\r\n return null;\r\n }\r\n else if (isObject(duration)) {\r\n return [NumberOf(duration.enter), NumberOf(duration.leave)];\r\n }\r\n else {\r\n const n = NumberOf(duration);\r\n return [n, n];\r\n }\r\n}\r\nfunction NumberOf(val) {\r\n const res = toNumber(val);\r\n if ((process.env.NODE_ENV !== 'production'))\r\n validateDuration(res);\r\n return res;\r\n}\r\nfunction validateDuration(val) {\r\n if (typeof val !== 'number') {\r\n warn(`<transition> explicit duration is not a valid number - ` +\r\n `got ${JSON.stringify(val)}.`);\r\n }\r\n else if (isNaN(val)) {\r\n warn(`<transition> explicit duration is NaN - ` +\r\n 'the duration expression might be incorrect.');\r\n }\r\n}\r\nfunction addTransitionClass(el, cls) {\r\n cls.split(/\\s+/).forEach(c => c && el.classList.add(c));\r\n (el._vtc ||\r\n (el._vtc = new Set())).add(cls);\r\n}\r\nfunction removeTransitionClass(el, cls) {\r\n cls.split(/\\s+/).forEach(c => c && el.classList.remove(c));\r\n const { _vtc } = el;\r\n if (_vtc) {\r\n _vtc.delete(cls);\r\n if (!_vtc.size) {\r\n el._vtc = undefined;\r\n }\r\n }\r\n}\r\nfunction nextFrame(cb) {\r\n requestAnimationFrame(() => {\r\n requestAnimationFrame(cb);\r\n });\r\n}\r\nlet endId = 0;\r\nfunction whenTransitionEnds(el, expectedType, explicitTimeout, resolve) {\r\n const id = (el._endId = ++endId);\r\n const resolveIfNotStale = () => {\r\n if (id === el._endId) {\r\n resolve();\r\n }\r\n };\r\n if (explicitTimeout) {\r\n return setTimeout(resolveIfNotStale, explicitTimeout);\r\n }\r\n const { type, timeout, propCount } = getTransitionInfo(el, expectedType);\r\n if (!type) {\r\n return resolve();\r\n }\r\n const endEvent = type + 'end';\r\n let ended = 0;\r\n const end = () => {\r\n el.removeEventListener(endEvent, onEnd);\r\n resolveIfNotStale();\r\n };\r\n const onEnd = (e) => {\r\n if (e.target === el && ++ended >= propCount) {\r\n end();\r\n }\r\n };\r\n setTimeout(() => {\r\n if (ended < propCount) {\r\n end();\r\n }\r\n }, timeout + 1);\r\n el.addEventListener(endEvent, onEnd);\r\n}\r\nfunction getTransitionInfo(el, expectedType) {\r\n const styles = window.getComputedStyle(el);\r\n // JSDOM may return undefined for transition properties\r\n const getStyleProperties = (key) => (styles[key] || '').split(', ');\r\n const transitionDelays = getStyleProperties(TRANSITION + 'Delay');\r\n const transitionDurations = getStyleProperties(TRANSITION + 'Duration');\r\n const transitionTimeout = getTimeout(transitionDelays, transitionDurations);\r\n const animationDelays = getStyleProperties(ANIMATION + 'Delay');\r\n const animationDurations = getStyleProperties(ANIMATION + 'Duration');\r\n const animationTimeout = getTimeout(animationDelays, animationDurations);\r\n let type = null;\r\n let timeout = 0;\r\n let propCount = 0;\r\n /* istanbul ignore if */\r\n if (expectedType === TRANSITION) {\r\n if (transitionTimeout > 0) {\r\n type = TRANSITION;\r\n timeout = transitionTimeout;\r\n propCount = transitionDurations.length;\r\n }\r\n }\r\n else if (expectedType === ANIMATION) {\r\n if (animationTimeout > 0) {\r\n type = ANIMATION;\r\n timeout = animationTimeout;\r\n propCount = animationDurations.length;\r\n }\r\n }\r\n else {\r\n timeout = Math.max(transitionTimeout, animationTimeout);\r\n type =\r\n timeout > 0\r\n ? transitionTimeout > animationTimeout\r\n ? TRANSITION\r\n : ANIMATION\r\n : null;\r\n propCount = type\r\n ? type === TRANSITION\r\n ? transitionDurations.length\r\n : animationDurations.length\r\n : 0;\r\n }\r\n const hasTransform = type === TRANSITION &&\r\n /\\b(transform|all)(,|$)/.test(styles[TRANSITION + 'Property']);\r\n return {\r\n type,\r\n timeout,\r\n propCount,\r\n hasTransform\r\n };\r\n}\r\nfunction getTimeout(delays, durations) {\r\n while (delays.length < durations.length) {\r\n delays = delays.concat(delays);\r\n }\r\n return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));\r\n}\r\n// Old versions of Chromium (below 61.0.3163.100) formats floating pointer\r\n// numbers in a locale-dependent way, using a comma instead of a dot.\r\n// If comma is not replaced with a dot, the input will be rounded down\r\n// (i.e. acting as a floor function) causing unexpected behaviors\r\nfunction toMs(s) {\r\n return Number(s.slice(0, -1).replace(',', '.')) * 1000;\r\n}\r\n// synchronously force layout to put elements into a certain state\r\nfunction forceReflow() {\r\n return document.body.offsetHeight;\r\n}\n\nconst positionMap = new WeakMap();\r\nconst newPositionMap = new WeakMap();\r\nconst TransitionGroupImpl = {\r\n name: 'TransitionGroup',\r\n props: /*#__PURE__*/ extend({}, TransitionPropsValidators, {\r\n tag: String,\r\n moveClass: String\r\n }),\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n const state = useTransitionState();\r\n let prevChildren;\r\n let children;\r\n onUpdated(() => {\r\n // children is guaranteed to exist after initial render\r\n if (!prevChildren.length) {\r\n return;\r\n }\r\n const moveClass = props.moveClass || `${props.name || 'v'}-move`;\r\n if (!hasCSSTransform(prevChildren[0].el, instance.vnode.el, moveClass)) {\r\n return;\r\n }\r\n // we divide the work into three loops to avoid mixing DOM reads and writes\r\n // in each iteration - which helps prevent layout thrashing.\r\n prevChildren.forEach(callPendingCbs);\r\n prevChildren.forEach(recordPosition);\r\n const movedChildren = prevChildren.filter(applyTranslation);\r\n // force reflow to put everything in position\r\n forceReflow();\r\n movedChildren.forEach(c => {\r\n const el = c.el;\r\n const style = el.style;\r\n addTransitionClass(el, moveClass);\r\n style.transform = style.webkitTransform = style.transitionDuration = '';\r\n const cb = (el._moveCb = (e) => {\r\n if (e && e.target !== el) {\r\n return;\r\n }\r\n if (!e || /transform$/.test(e.propertyName)) {\r\n el.removeEventListener('transitionend', cb);\r\n el._moveCb = null;\r\n removeTransitionClass(el, moveClass);\r\n }\r\n });\r\n el.addEventListener('transitionend', cb);\r\n });\r\n });\r\n return () => {\r\n const rawProps = toRaw(props);\r\n const cssTransitionProps = resolveTransitionProps(rawProps);\r\n let tag = rawProps.tag || Fragment;\r\n prevChildren = children;\r\n children = slots.default ? getTransitionRawChildren(slots.default()) : [];\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (child.key != null) {\r\n setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`<TransitionGroup> children must be keyed.`);\r\n }\r\n }\r\n if (prevChildren) {\r\n for (let i = 0; i < prevChildren.length; i++) {\r\n const child = prevChildren[i];\r\n setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n positionMap.set(child, child.el.getBoundingClientRect());\r\n }\r\n }\r\n return createVNode(tag, null, children);\r\n };\r\n }\r\n};\r\nconst TransitionGroup = TransitionGroupImpl;\r\nfunction callPendingCbs(c) {\r\n const el = c.el;\r\n if (el._moveCb) {\r\n el._moveCb();\r\n }\r\n if (el._enterCb) {\r\n el._enterCb();\r\n }\r\n}\r\nfunction recordPosition(c) {\r\n newPositionMap.set(c, c.el.getBoundingClientRect());\r\n}\r\nfunction applyTranslation(c) {\r\n const oldPos = positionMap.get(c);\r\n const newPos = newPositionMap.get(c);\r\n const dx = oldPos.left - newPos.left;\r\n const dy = oldPos.top - newPos.top;\r\n if (dx || dy) {\r\n const s = c.el.style;\r\n s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;\r\n s.transitionDuration = '0s';\r\n return c;\r\n }\r\n}\r\nfunction hasCSSTransform(el, root, moveClass) {\r\n // Detect whether an element with the move class applied has\r\n // CSS transitions. Since the element may be inside an entering\r\n // transition at this very moment, we make a clone of it and remove\r\n // all other transition classes applied to ensure only the move class\r\n // is applied.\r\n const clone = el.cloneNode();\r\n if (el._vtc) {\r\n el._vtc.forEach(cls => {\r\n cls.split(/\\s+/).forEach(c => c && clone.classList.remove(c));\r\n });\r\n }\r\n moveClass.split(/\\s+/).forEach(c => c && clone.classList.add(c));\r\n clone.style.display = 'none';\r\n const container = (root.nodeType === 1 ? root : root.parentNode);\r\n container.appendChild(clone);\r\n const { hasTransform } = getTransitionInfo(clone);\r\n container.removeChild(clone);\r\n return hasTransform;\r\n}\n\nconst getModelAssigner = (vnode) => {\r\n const fn = vnode.props['onUpdate:modelValue'];\r\n return isArray(fn) ? value => invokeArrayFns(fn, value) : fn;\r\n};\r\nfunction onCompositionStart(e) {\r\n e.target.composing = true;\r\n}\r\nfunction onCompositionEnd(e) {\r\n const target = e.target;\r\n if (target.composing) {\r\n target.composing = false;\r\n trigger(target, 'input');\r\n }\r\n}\r\nfunction trigger(el, type) {\r\n const e = document.createEvent('HTMLEvents');\r\n e.initEvent(type, true, true);\r\n el.dispatchEvent(e);\r\n}\r\n// We are exporting the v-model runtime directly as vnode hooks so that it can\r\n// be tree-shaken in case v-model is never used.\r\nconst vModelText = {\r\n created(el, { modifiers: { lazy, trim, number } }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n const castToNumber = number || (vnode.props && vnode.props.type === 'number');\r\n addEventListener(el, lazy ? 'change' : 'input', e => {\r\n if (e.target.composing)\r\n return;\r\n let domValue = el.value;\r\n if (trim) {\r\n domValue = domValue.trim();\r\n }\r\n else if (castToNumber) {\r\n domValue = toNumber(domValue);\r\n }\r\n el._assign(domValue);\r\n });\r\n if (trim) {\r\n addEventListener(el, 'change', () => {\r\n el.value = el.value.trim();\r\n });\r\n }\r\n if (!lazy) {\r\n addEventListener(el, 'compositionstart', onCompositionStart);\r\n addEventListener(el, 'compositionend', onCompositionEnd);\r\n // Safari < 10.2 & UIWebView doesn't fire compositionend when\r\n // switching focus before confirming composition choice\r\n // this also fixes the issue where some browsers e.g. iOS Chrome\r\n // fires \"change\" instead of \"input\" on autocomplete.\r\n addEventListener(el, 'change', onCompositionEnd);\r\n }\r\n },\r\n // set value on mounted so it's after min/max for type=\"range\"\r\n mounted(el, { value }) {\r\n el.value = value == null ? '' : value;\r\n },\r\n beforeUpdate(el, { value, modifiers: { lazy, trim, number } }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n // avoid clearing unresolved text. #2302\r\n if (el.composing)\r\n return;\r\n if (document.activeElement === el) {\r\n if (lazy) {\r\n return;\r\n }\r\n if (trim && el.value.trim() === value) {\r\n return;\r\n }\r\n if ((number || el.type === 'number') && toNumber(el.value) === value) {\r\n return;\r\n }\r\n }\r\n const newValue = value == null ? '' : value;\r\n if (el.value !== newValue) {\r\n el.value = newValue;\r\n }\r\n }\r\n};\r\nconst vModelCheckbox = {\r\n // #4096 array checkboxes need to be deep traversed\r\n deep: true,\r\n created(el, _, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n addEventListener(el, 'change', () => {\r\n const modelValue = el._modelValue;\r\n const elementValue = getValue(el);\r\n const checked = el.checked;\r\n const assign = el._assign;\r\n if (isArray(modelValue)) {\r\n const index = looseIndexOf(modelValue, elementValue);\r\n const found = index !== -1;\r\n if (checked && !found) {\r\n assign(modelValue.concat(elementValue));\r\n }\r\n else if (!checked && found) {\r\n const filtered = [...modelValue];\r\n filtered.splice(index, 1);\r\n assign(filtered);\r\n }\r\n }\r\n else if (isSet(modelValue)) {\r\n const cloned = new Set(modelValue);\r\n if (checked) {\r\n cloned.add(elementValue);\r\n }\r\n else {\r\n cloned.delete(elementValue);\r\n }\r\n assign(cloned);\r\n }\r\n else {\r\n assign(getCheckboxValue(el, checked));\r\n }\r\n });\r\n },\r\n // set initial checked on mount to wait for true-value/false-value\r\n mounted: setChecked,\r\n beforeUpdate(el, binding, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n setChecked(el, binding, vnode);\r\n }\r\n};\r\nfunction setChecked(el, { value, oldValue }, vnode) {\r\n el._modelValue = value;\r\n if (isArray(value)) {\r\n el.checked = looseIndexOf(value, vnode.props.value) > -1;\r\n }\r\n else if (isSet(value)) {\r\n el.checked = value.has(vnode.props.value);\r\n }\r\n else if (value !== oldValue) {\r\n el.checked = looseEqual(value, getCheckboxValue(el, true));\r\n }\r\n}\r\nconst vModelRadio = {\r\n created(el, { value }, vnode) {\r\n el.checked = looseEqual(value, vnode.props.value);\r\n el._assign = getModelAssigner(vnode);\r\n addEventListener(el, 'change', () => {\r\n el._assign(getValue(el));\r\n });\r\n },\r\n beforeUpdate(el, { value, oldValue }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n if (value !== oldValue) {\r\n el.checked = looseEqual(value, vnode.props.value);\r\n }\r\n }\r\n};\r\nconst vModelSelect = {\r\n // <select multiple> value need to be deep traversed\r\n deep: true,\r\n created(el, { value, modifiers: { number } }, vnode) {\r\n const isSetModel = isSet(value);\r\n addEventListener(el, 'change', () => {\r\n const selectedVal = Array.prototype.filter\r\n .call(el.options, (o) => o.selected)\r\n .map((o) => number ? toNumber(getValue(o)) : getValue(o));\r\n el._assign(el.multiple\r\n ? isSetModel\r\n ? new Set(selectedVal)\r\n : selectedVal\r\n : selectedVal[0]);\r\n });\r\n el._assign = getModelAssigner(vnode);\r\n },\r\n // set value in mounted & updated because <select> relies on its children\r\n // <option>s.\r\n mounted(el, { value }) {\r\n setSelected(el, value);\r\n },\r\n beforeUpdate(el, _binding, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n },\r\n updated(el, { value }) {\r\n setSelected(el, value);\r\n }\r\n};\r\nfunction setSelected(el, value) {\r\n const isMultiple = el.multiple;\r\n if (isMultiple && !isArray(value) && !isSet(value)) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`<select multiple v-model> expects an Array or Set value for its binding, ` +\r\n `but got ${Object.prototype.toString.call(value).slice(8, -1)}.`);\r\n return;\r\n }\r\n for (let i = 0, l = el.options.length; i < l; i++) {\r\n const option = el.options[i];\r\n const optionValue = getValue(option);\r\n if (isMultiple) {\r\n if (isArray(value)) {\r\n option.selected = looseIndexOf(value, optionValue) > -1;\r\n }\r\n else {\r\n option.selected = value.has(optionValue);\r\n }\r\n }\r\n else {\r\n if (looseEqual(getValue(option), value)) {\r\n if (el.selectedIndex !== i)\r\n el.selectedIndex = i;\r\n return;\r\n }\r\n }\r\n }\r\n if (!isMultiple && el.selectedIndex !== -1) {\r\n el.selectedIndex = -1;\r\n }\r\n}\r\n// retrieve raw value set via :value bindings\r\nfunction getValue(el) {\r\n return '_value' in el ? el._value : el.value;\r\n}\r\n// retrieve raw value for true-value and false-value set via :true-value or :false-value bindings\r\nfunction getCheckboxValue(el, checked) {\r\n const key = checked ? '_trueValue' : '_falseValue';\r\n return key in el ? el[key] : checked;\r\n}\r\nconst vModelDynamic = {\r\n created(el, binding, vnode) {\r\n callModelHook(el, binding, vnode, null, 'created');\r\n },\r\n mounted(el, binding, vnode) {\r\n callModelHook(el, binding, vnode, null, 'mounted');\r\n },\r\n beforeUpdate(el, binding, vnode, prevVNode) {\r\n callModelHook(el, binding, vnode, prevVNode, 'beforeUpdate');\r\n },\r\n updated(el, binding, vnode, prevVNode) {\r\n callModelHook(el, binding, vnode, prevVNode, 'updated');\r\n }\r\n};\r\nfunction callModelHook(el, binding, vnode, prevVNode, hook) {\r\n let modelToUse;\r\n switch (el.tagName) {\r\n case 'SELECT':\r\n modelToUse = vModelSelect;\r\n break;\r\n case 'TEXTAREA':\r\n modelToUse = vModelText;\r\n break;\r\n default:\r\n switch (vnode.props && vnode.props.type) {\r\n case 'checkbox':\r\n modelToUse = vModelCheckbox;\r\n break;\r\n case 'radio':\r\n modelToUse = vModelRadio;\r\n break;\r\n default:\r\n modelToUse = vModelText;\r\n }\r\n }\r\n const fn = modelToUse[hook];\r\n fn && fn(el, binding, vnode, prevVNode);\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVModelForSSR() {\r\n vModelText.getSSRProps = ({ value }) => ({ value });\r\n vModelRadio.getSSRProps = ({ value }, vnode) => {\r\n if (vnode.props && looseEqual(vnode.props.value, value)) {\r\n return { checked: true };\r\n }\r\n };\r\n vModelCheckbox.getSSRProps = ({ value }, vnode) => {\r\n if (isArray(value)) {\r\n if (vnode.props && looseIndexOf(value, vnode.props.value) > -1) {\r\n return { checked: true };\r\n }\r\n }\r\n else if (isSet(value)) {\r\n if (vnode.props && value.has(vnode.props.value)) {\r\n return { checked: true };\r\n }\r\n }\r\n else if (value) {\r\n return { checked: true };\r\n }\r\n };\r\n}\n\nconst systemModifiers = ['ctrl', 'shift', 'alt', 'meta'];\r\nconst modifierGuards = {\r\n stop: e => e.stopPropagation(),\r\n prevent: e => e.preventDefault(),\r\n self: e => e.target !== e.currentTarget,\r\n ctrl: e => !e.ctrlKey,\r\n shift: e => !e.shiftKey,\r\n alt: e => !e.altKey,\r\n meta: e => !e.metaKey,\r\n left: e => 'button' in e && e.button !== 0,\r\n middle: e => 'button' in e && e.button !== 1,\r\n right: e => 'button' in e && e.button !== 2,\r\n exact: (e, modifiers) => systemModifiers.some(m => e[`${m}Key`] && !modifiers.includes(m))\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withModifiers = (fn, modifiers) => {\r\n return (event, ...args) => {\r\n for (let i = 0; i < modifiers.length; i++) {\r\n const guard = modifierGuards[modifiers[i]];\r\n if (guard && guard(event, modifiers))\r\n return;\r\n }\r\n return fn(event, ...args);\r\n };\r\n};\r\n// Kept for 2.x compat.\r\n// Note: IE11 compat for `spacebar` and `del` is removed for now.\r\nconst keyNames = {\r\n esc: 'escape',\r\n space: ' ',\r\n up: 'arrow-up',\r\n left: 'arrow-left',\r\n right: 'arrow-right',\r\n down: 'arrow-down',\r\n delete: 'backspace'\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withKeys = (fn, modifiers) => {\r\n return (event) => {\r\n if (!('key' in event)) {\r\n return;\r\n }\r\n const eventKey = hyphenate(event.key);\r\n if (modifiers.some(k => k === eventKey || keyNames[k] === eventKey)) {\r\n return fn(event);\r\n }\r\n };\r\n};\n\nconst vShow = {\r\n beforeMount(el, { value }, { transition }) {\r\n el._vod = el.style.display === 'none' ? '' : el.style.display;\r\n if (transition && value) {\r\n transition.beforeEnter(el);\r\n }\r\n else {\r\n setDisplay(el, value);\r\n }\r\n },\r\n mounted(el, { value }, { transition }) {\r\n if (transition && value) {\r\n transition.enter(el);\r\n }\r\n },\r\n updated(el, { value, oldValue }, { transition }) {\r\n if (!value === !oldValue)\r\n return;\r\n if (transition) {\r\n if (value) {\r\n transition.beforeEnter(el);\r\n setDisplay(el, true);\r\n transition.enter(el);\r\n }\r\n else {\r\n transition.leave(el, () => {\r\n setDisplay(el, false);\r\n });\r\n }\r\n }\r\n else {\r\n setDisplay(el, value);\r\n }\r\n },\r\n beforeUnmount(el, { value }) {\r\n setDisplay(el, value);\r\n }\r\n};\r\nfunction setDisplay(el, value) {\r\n el.style.display = value ? el._vod : 'none';\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVShowForSSR() {\r\n vShow.getSSRProps = ({ value }) => {\r\n if (!value) {\r\n return { style: { display: 'none' } };\r\n }\r\n };\r\n}\n\nconst rendererOptions = extend({ patchProp }, nodeOps);\r\n// lazy create the renderer - this makes core renderer logic tree-shakable\r\n// in case the user only imports reactivity utilities from Vue.\r\nlet renderer;\r\nlet enabledHydration = false;\r\nfunction ensureRenderer() {\r\n return (renderer ||\r\n (renderer = createRenderer(rendererOptions)));\r\n}\r\nfunction ensureHydrationRenderer() {\r\n renderer = enabledHydration\r\n ? renderer\r\n : createHydrationRenderer(rendererOptions);\r\n enabledHydration = true;\r\n return renderer;\r\n}\r\n// use explicit type casts here to avoid import() calls in rolled-up d.ts\r\nconst render = ((...args) => {\r\n ensureRenderer().render(...args);\r\n});\r\nconst hydrate = ((...args) => {\r\n ensureHydrationRenderer().hydrate(...args);\r\n});\r\nconst createApp = ((...args) => {\r\n const app = ensureRenderer().createApp(...args);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n injectNativeTagCheck(app);\r\n injectCompilerOptionsCheck(app);\r\n }\r\n const { mount } = app;\r\n app.mount = (containerOrSelector) => {\r\n const container = normalizeContainer(containerOrSelector);\r\n if (!container)\r\n return;\r\n const component = app._component;\r\n if (!isFunction(component) && !component.render && !component.template) {\r\n // __UNSAFE__\r\n // Reason: potential execution of JS expressions in in-DOM template.\r\n // The user must make sure the in-DOM template is trusted. If it's\r\n // rendered by the server, the template should not contain any user data.\r\n component.template = container.innerHTML;\r\n }\r\n // clear content before mounting\r\n container.innerHTML = '';\r\n const proxy = mount(container, false, container instanceof SVGElement);\r\n if (container instanceof Element) {\r\n container.removeAttribute('v-cloak');\r\n container.setAttribute('data-v-app', '');\r\n }\r\n return proxy;\r\n };\r\n return app;\r\n});\r\nconst createSSRApp = ((...args) => {\r\n const app = ensureHydrationRenderer().createApp(...args);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n injectNativeTagCheck(app);\r\n injectCompilerOptionsCheck(app);\r\n }\r\n const { mount } = app;\r\n app.mount = (containerOrSelector) => {\r\n const container = normalizeContainer(containerOrSelector);\r\n if (container) {\r\n return mount(container, true, container instanceof SVGElement);\r\n }\r\n };\r\n return app;\r\n});\r\nfunction injectNativeTagCheck(app) {\r\n // Inject `isNativeTag`\r\n // this is used for component name validation (dev only)\r\n Object.defineProperty(app.config, 'isNativeTag', {\r\n value: (tag) => isHTMLTag(tag) || isSVGTag(tag),\r\n writable: false\r\n });\r\n}\r\n// dev only\r\nfunction injectCompilerOptionsCheck(app) {\r\n if (isRuntimeOnly()) {\r\n const isCustomElement = app.config.isCustomElement;\r\n Object.defineProperty(app.config, 'isCustomElement', {\r\n get() {\r\n return isCustomElement;\r\n },\r\n set() {\r\n warn(`The \\`isCustomElement\\` config option is deprecated. Use ` +\r\n `\\`compilerOptions.isCustomElement\\` instead.`);\r\n }\r\n });\r\n const compilerOptions = app.config.compilerOptions;\r\n const msg = `The \\`compilerOptions\\` config option is only respected when using ` +\r\n `a build of Vue.js that includes the runtime compiler (aka \"full build\"). ` +\r\n `Since you are using the runtime-only build, \\`compilerOptions\\` ` +\r\n `must be passed to \\`@vue/compiler-dom\\` in the build setup instead.\\n` +\r\n `- For vue-loader: pass it via vue-loader's \\`compilerOptions\\` loader option.\\n` +\r\n `- For vue-cli: see https://cli.vuejs.org/guide/webpack.html#modifying-options-of-a-loader\\n` +\r\n `- For vite: pass it via @vitejs/plugin-vue options. See https://github.com/vitejs/vite/tree/main/packages/plugin-vue#example-for-passing-options-to-vuecompiler-dom`;\r\n Object.defineProperty(app.config, 'compilerOptions', {\r\n get() {\r\n warn(msg);\r\n return compilerOptions;\r\n },\r\n set() {\r\n warn(msg);\r\n }\r\n });\r\n }\r\n}\r\nfunction normalizeContainer(container) {\r\n if (isString(container)) {\r\n const res = document.querySelector(container);\r\n if ((process.env.NODE_ENV !== 'production') && !res) {\r\n warn(`Failed to mount app: mount target selector \"${container}\" returned null.`);\r\n }\r\n return res;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n window.ShadowRoot &&\r\n container instanceof window.ShadowRoot &&\r\n container.mode === 'closed') {\r\n warn(`mounting on a ShadowRoot with \\`{mode: \"closed\"}\\` may lead to unpredictable bugs`);\r\n }\r\n return container;\r\n}\r\nlet ssrDirectiveInitialized = false;\r\n/**\r\n * @internal\r\n */\r\nconst initDirectivesForSSR = () => {\r\n if (!ssrDirectiveInitialized) {\r\n ssrDirectiveInitialized = true;\r\n initVModelForSSR();\r\n initVShowForSSR();\r\n }\r\n }\r\n ;\n\nexport { Transition, TransitionGroup, VueElement, createApp, createSSRApp, defineCustomElement, defineSSRCustomElement, hydrate, initDirectivesForSSR, render, useCssModule, useCssVars, vModelCheckbox, vModelDynamic, vModelRadio, vModelSelect, vModelText, vShow, withKeys, withModifiers };\n","import { isString, hyphenate, NOOP, extend, isObject, NO, isArray, makeMap, isSymbol, EMPTY_OBJ, capitalize, camelize as camelize$1, PatchFlagNames, slotFlagsText, isOn, isReservedProp, toHandlerKey } from '@vue/shared';\nexport { generateCodeFrame } from '@vue/shared';\n\nfunction defaultOnError(error) {\r\n throw error;\r\n}\r\nfunction defaultOnWarn(msg) {\r\n (process.env.NODE_ENV !== 'production') && console.warn(`[Vue warn] ${msg.message}`);\r\n}\r\nfunction createCompilerError(code, loc, messages, additionalMessage) {\r\n const msg = (process.env.NODE_ENV !== 'production') || !true\r\n ? (messages || errorMessages)[code] + (additionalMessage || ``)\r\n : code;\r\n const error = new SyntaxError(String(msg));\r\n error.code = code;\r\n error.loc = loc;\r\n return error;\r\n}\r\nconst errorMessages = {\r\n // parse errors\r\n [0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */]: 'Illegal comment.',\r\n [1 /* CDATA_IN_HTML_CONTENT */]: 'CDATA section is allowed only in XML context.',\r\n [2 /* DUPLICATE_ATTRIBUTE */]: 'Duplicate attribute.',\r\n [3 /* END_TAG_WITH_ATTRIBUTES */]: 'End tag cannot have attributes.',\r\n [4 /* END_TAG_WITH_TRAILING_SOLIDUS */]: \"Illegal '/' in tags.\",\r\n [5 /* EOF_BEFORE_TAG_NAME */]: 'Unexpected EOF in tag.',\r\n [6 /* EOF_IN_CDATA */]: 'Unexpected EOF in CDATA section.',\r\n [7 /* EOF_IN_COMMENT */]: 'Unexpected EOF in comment.',\r\n [8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */]: 'Unexpected EOF in script.',\r\n [9 /* EOF_IN_TAG */]: 'Unexpected EOF in tag.',\r\n [10 /* INCORRECTLY_CLOSED_COMMENT */]: 'Incorrectly closed comment.',\r\n [11 /* INCORRECTLY_OPENED_COMMENT */]: 'Incorrectly opened comment.',\r\n [12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */]: \"Illegal tag name. Use '<' to print '<'.\",\r\n [13 /* MISSING_ATTRIBUTE_VALUE */]: 'Attribute value was expected.',\r\n [14 /* MISSING_END_TAG_NAME */]: 'End tag name was expected.',\r\n [15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */]: 'Whitespace was expected.',\r\n [16 /* NESTED_COMMENT */]: \"Unexpected '<!--' in comment.\",\r\n [17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */]: 'Attribute name cannot contain U+0022 (\"), U+0027 (\\'), and U+003C (<).',\r\n [18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */]: 'Unquoted attribute value cannot contain U+0022 (\"), U+0027 (\\'), U+003C (<), U+003D (=), and U+0060 (`).',\r\n [19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */]: \"Attribute name cannot start with '='.\",\r\n [21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */]: \"'<?' is allowed only in XML context.\",\r\n [20 /* UNEXPECTED_NULL_CHARACTER */]: `Unexpected null character.`,\r\n [22 /* UNEXPECTED_SOLIDUS_IN_TAG */]: \"Illegal '/' in tags.\",\r\n // Vue-specific parse errors\r\n [23 /* X_INVALID_END_TAG */]: 'Invalid end tag.',\r\n [24 /* X_MISSING_END_TAG */]: 'Element is missing end tag.',\r\n [25 /* X_MISSING_INTERPOLATION_END */]: 'Interpolation end sign was not found.',\r\n [27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */]: 'End bracket for dynamic directive argument was not found. ' +\r\n 'Note that dynamic directive argument cannot contain spaces.',\r\n [26 /* X_MISSING_DIRECTIVE_NAME */]: 'Legal directive name was expected.',\r\n // transform errors\r\n [28 /* X_V_IF_NO_EXPRESSION */]: `v-if/v-else-if is missing expression.`,\r\n [29 /* X_V_IF_SAME_KEY */]: `v-if/else branches must use unique keys.`,\r\n [30 /* X_V_ELSE_NO_ADJACENT_IF */]: `v-else/v-else-if has no adjacent v-if or v-else-if.`,\r\n [31 /* X_V_FOR_NO_EXPRESSION */]: `v-for is missing expression.`,\r\n [32 /* X_V_FOR_MALFORMED_EXPRESSION */]: `v-for has invalid expression.`,\r\n [33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */]: `<template v-for> key should be placed on the <template> tag.`,\r\n [34 /* X_V_BIND_NO_EXPRESSION */]: `v-bind is missing expression.`,\r\n [35 /* X_V_ON_NO_EXPRESSION */]: `v-on is missing expression.`,\r\n [36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */]: `Unexpected custom directive on <slot> outlet.`,\r\n [37 /* X_V_SLOT_MIXED_SLOT_USAGE */]: `Mixed v-slot usage on both the component and nested <template>.` +\r\n `When there are multiple named slots, all slots should use <template> ` +\r\n `syntax to avoid scope ambiguity.`,\r\n [38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */]: `Duplicate slot names found. `,\r\n [39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */]: `Extraneous children found when component already has explicitly named ` +\r\n `default slot. These children will be ignored.`,\r\n [40 /* X_V_SLOT_MISPLACED */]: `v-slot can only be used on components or <template> tags.`,\r\n [41 /* X_V_MODEL_NO_EXPRESSION */]: `v-model is missing expression.`,\r\n [42 /* X_V_MODEL_MALFORMED_EXPRESSION */]: `v-model value must be a valid JavaScript member expression.`,\r\n [43 /* X_V_MODEL_ON_SCOPE_VARIABLE */]: `v-model cannot be used on v-for or v-slot scope variables because they are not writable.`,\r\n [44 /* X_INVALID_EXPRESSION */]: `Error parsing JavaScript expression: `,\r\n [45 /* X_KEEP_ALIVE_INVALID_CHILDREN */]: `<KeepAlive> expects exactly one child component.`,\r\n // generic errors\r\n [46 /* X_PREFIX_ID_NOT_SUPPORTED */]: `\"prefixIdentifiers\" option is not supported in this build of compiler.`,\r\n [47 /* X_MODULE_MODE_NOT_SUPPORTED */]: `ES module mode is not supported in this build of compiler.`,\r\n [48 /* X_CACHE_HANDLER_NOT_SUPPORTED */]: `\"cacheHandlers\" option is only supported when the \"prefixIdentifiers\" option is enabled.`,\r\n [49 /* X_SCOPE_ID_NOT_SUPPORTED */]: `\"scopeId\" option is only supported in module mode.`,\r\n // just to fulfill types\r\n [50 /* __EXTEND_POINT__ */]: ``\r\n};\n\nconst FRAGMENT = Symbol((process.env.NODE_ENV !== 'production') ? `Fragment` : ``);\r\nconst TELEPORT = Symbol((process.env.NODE_ENV !== 'production') ? `Teleport` : ``);\r\nconst SUSPENSE = Symbol((process.env.NODE_ENV !== 'production') ? `Suspense` : ``);\r\nconst KEEP_ALIVE = Symbol((process.env.NODE_ENV !== 'production') ? `KeepAlive` : ``);\r\nconst BASE_TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `BaseTransition` : ``);\r\nconst OPEN_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `openBlock` : ``);\r\nconst CREATE_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createBlock` : ``);\r\nconst CREATE_ELEMENT_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createElementBlock` : ``);\r\nconst CREATE_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createVNode` : ``);\r\nconst CREATE_ELEMENT_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createElementVNode` : ``);\r\nconst CREATE_COMMENT = Symbol((process.env.NODE_ENV !== 'production') ? `createCommentVNode` : ``);\r\nconst CREATE_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `createTextVNode` : ``);\r\nconst CREATE_STATIC = Symbol((process.env.NODE_ENV !== 'production') ? `createStaticVNode` : ``);\r\nconst RESOLVE_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveComponent` : ``);\r\nconst RESOLVE_DYNAMIC_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDynamicComponent` : ``);\r\nconst RESOLVE_DIRECTIVE = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDirective` : ``);\r\nconst RESOLVE_FILTER = Symbol((process.env.NODE_ENV !== 'production') ? `resolveFilter` : ``);\r\nconst WITH_DIRECTIVES = Symbol((process.env.NODE_ENV !== 'production') ? `withDirectives` : ``);\r\nconst RENDER_LIST = Symbol((process.env.NODE_ENV !== 'production') ? `renderList` : ``);\r\nconst RENDER_SLOT = Symbol((process.env.NODE_ENV !== 'production') ? `renderSlot` : ``);\r\nconst CREATE_SLOTS = Symbol((process.env.NODE_ENV !== 'production') ? `createSlots` : ``);\r\nconst TO_DISPLAY_STRING = Symbol((process.env.NODE_ENV !== 'production') ? `toDisplayString` : ``);\r\nconst MERGE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `mergeProps` : ``);\r\nconst NORMALIZE_CLASS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeClass` : ``);\r\nconst NORMALIZE_STYLE = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeStyle` : ``);\r\nconst NORMALIZE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeProps` : ``);\r\nconst GUARD_REACTIVE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `guardReactiveProps` : ``);\r\nconst TO_HANDLERS = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlers` : ``);\r\nconst CAMELIZE = Symbol((process.env.NODE_ENV !== 'production') ? `camelize` : ``);\r\nconst CAPITALIZE = Symbol((process.env.NODE_ENV !== 'production') ? `capitalize` : ``);\r\nconst TO_HANDLER_KEY = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlerKey` : ``);\r\nconst SET_BLOCK_TRACKING = Symbol((process.env.NODE_ENV !== 'production') ? `setBlockTracking` : ``);\r\nconst PUSH_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `pushScopeId` : ``);\r\nconst POP_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `popScopeId` : ``);\r\nconst WITH_CTX = Symbol((process.env.NODE_ENV !== 'production') ? `withCtx` : ``);\r\nconst UNREF = Symbol((process.env.NODE_ENV !== 'production') ? `unref` : ``);\r\nconst IS_REF = Symbol((process.env.NODE_ENV !== 'production') ? `isRef` : ``);\r\nconst WITH_MEMO = Symbol((process.env.NODE_ENV !== 'production') ? `withMemo` : ``);\r\nconst IS_MEMO_SAME = Symbol((process.env.NODE_ENV !== 'production') ? `isMemoSame` : ``);\r\n// Name mapping for runtime helpers that need to be imported from 'vue' in\r\n// generated code. Make sure these are correctly exported in the runtime!\r\n// Using `any` here because TS doesn't allow symbols as index type.\r\nconst helperNameMap = {\r\n [FRAGMENT]: `Fragment`,\r\n [TELEPORT]: `Teleport`,\r\n [SUSPENSE]: `Suspense`,\r\n [KEEP_ALIVE]: `KeepAlive`,\r\n [BASE_TRANSITION]: `BaseTransition`,\r\n [OPEN_BLOCK]: `openBlock`,\r\n [CREATE_BLOCK]: `createBlock`,\r\n [CREATE_ELEMENT_BLOCK]: `createElementBlock`,\r\n [CREATE_VNODE]: `createVNode`,\r\n [CREATE_ELEMENT_VNODE]: `createElementVNode`,\r\n [CREATE_COMMENT]: `createCommentVNode`,\r\n [CREATE_TEXT]: `createTextVNode`,\r\n [CREATE_STATIC]: `createStaticVNode`,\r\n [RESOLVE_COMPONENT]: `resolveComponent`,\r\n [RESOLVE_DYNAMIC_COMPONENT]: `resolveDynamicComponent`,\r\n [RESOLVE_DIRECTIVE]: `resolveDirective`,\r\n [RESOLVE_FILTER]: `resolveFilter`,\r\n [WITH_DIRECTIVES]: `withDirectives`,\r\n [RENDER_LIST]: `renderList`,\r\n [RENDER_SLOT]: `renderSlot`,\r\n [CREATE_SLOTS]: `createSlots`,\r\n [TO_DISPLAY_STRING]: `toDisplayString`,\r\n [MERGE_PROPS]: `mergeProps`,\r\n [NORMALIZE_CLASS]: `normalizeClass`,\r\n [NORMALIZE_STYLE]: `normalizeStyle`,\r\n [NORMALIZE_PROPS]: `normalizeProps`,\r\n [GUARD_REACTIVE_PROPS]: `guardReactiveProps`,\r\n [TO_HANDLERS]: `toHandlers`,\r\n [CAMELIZE]: `camelize`,\r\n [CAPITALIZE]: `capitalize`,\r\n [TO_HANDLER_KEY]: `toHandlerKey`,\r\n [SET_BLOCK_TRACKING]: `setBlockTracking`,\r\n [PUSH_SCOPE_ID]: `pushScopeId`,\r\n [POP_SCOPE_ID]: `popScopeId`,\r\n [WITH_CTX]: `withCtx`,\r\n [UNREF]: `unref`,\r\n [IS_REF]: `isRef`,\r\n [WITH_MEMO]: `withMemo`,\r\n [IS_MEMO_SAME]: `isMemoSame`\r\n};\r\nfunction registerRuntimeHelpers(helpers) {\r\n Object.getOwnPropertySymbols(helpers).forEach(s => {\r\n helperNameMap[s] = helpers[s];\r\n });\r\n}\n\n// AST Utilities ---------------------------------------------------------------\r\n// Some expressions, e.g. sequence and conditional expressions, are never\r\n// associated with template nodes, so their source locations are just a stub.\r\n// Container types like CompoundExpression also don't need a real location.\r\nconst locStub = {\r\n source: '',\r\n start: { line: 1, column: 1, offset: 0 },\r\n end: { line: 1, column: 1, offset: 0 }\r\n};\r\nfunction createRoot(children, loc = locStub) {\r\n return {\r\n type: 0 /* ROOT */,\r\n children,\r\n helpers: [],\r\n components: [],\r\n directives: [],\r\n hoists: [],\r\n imports: [],\r\n cached: 0,\r\n temps: 0,\r\n codegenNode: undefined,\r\n loc\r\n };\r\n}\r\nfunction createVNodeCall(context, tag, props, children, patchFlag, dynamicProps, directives, isBlock = false, disableTracking = false, isComponent = false, loc = locStub) {\r\n if (context) {\r\n if (isBlock) {\r\n context.helper(OPEN_BLOCK);\r\n context.helper(getVNodeBlockHelper(context.inSSR, isComponent));\r\n }\r\n else {\r\n context.helper(getVNodeHelper(context.inSSR, isComponent));\r\n }\r\n if (directives) {\r\n context.helper(WITH_DIRECTIVES);\r\n }\r\n }\r\n return {\r\n type: 13 /* VNODE_CALL */,\r\n tag,\r\n props,\r\n children,\r\n patchFlag,\r\n dynamicProps,\r\n directives,\r\n isBlock,\r\n disableTracking,\r\n isComponent,\r\n loc\r\n };\r\n}\r\nfunction createArrayExpression(elements, loc = locStub) {\r\n return {\r\n type: 17 /* JS_ARRAY_EXPRESSION */,\r\n loc,\r\n elements\r\n };\r\n}\r\nfunction createObjectExpression(properties, loc = locStub) {\r\n return {\r\n type: 15 /* JS_OBJECT_EXPRESSION */,\r\n loc,\r\n properties\r\n };\r\n}\r\nfunction createObjectProperty(key, value) {\r\n return {\r\n type: 16 /* JS_PROPERTY */,\r\n loc: locStub,\r\n key: isString(key) ? createSimpleExpression(key, true) : key,\r\n value\r\n };\r\n}\r\nfunction createSimpleExpression(content, isStatic = false, loc = locStub, constType = 0 /* NOT_CONSTANT */) {\r\n return {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n loc,\r\n content,\r\n isStatic,\r\n constType: isStatic ? 3 /* CAN_STRINGIFY */ : constType\r\n };\r\n}\r\nfunction createInterpolation(content, loc) {\r\n return {\r\n type: 5 /* INTERPOLATION */,\r\n loc,\r\n content: isString(content)\r\n ? createSimpleExpression(content, false, loc)\r\n : content\r\n };\r\n}\r\nfunction createCompoundExpression(children, loc = locStub) {\r\n return {\r\n type: 8 /* COMPOUND_EXPRESSION */,\r\n loc,\r\n children\r\n };\r\n}\r\nfunction createCallExpression(callee, args = [], loc = locStub) {\r\n return {\r\n type: 14 /* JS_CALL_EXPRESSION */,\r\n loc,\r\n callee,\r\n arguments: args\r\n };\r\n}\r\nfunction createFunctionExpression(params, returns = undefined, newline = false, isSlot = false, loc = locStub) {\r\n return {\r\n type: 18 /* JS_FUNCTION_EXPRESSION */,\r\n params,\r\n returns,\r\n newline,\r\n isSlot,\r\n loc\r\n };\r\n}\r\nfunction createConditionalExpression(test, consequent, alternate, newline = true) {\r\n return {\r\n type: 19 /* JS_CONDITIONAL_EXPRESSION */,\r\n test,\r\n consequent,\r\n alternate,\r\n newline,\r\n loc: locStub\r\n };\r\n}\r\nfunction createCacheExpression(index, value, isVNode = false) {\r\n return {\r\n type: 20 /* JS_CACHE_EXPRESSION */,\r\n index,\r\n value,\r\n isVNode,\r\n loc: locStub\r\n };\r\n}\r\nfunction createBlockStatement(body) {\r\n return {\r\n type: 21 /* JS_BLOCK_STATEMENT */,\r\n body,\r\n loc: locStub\r\n };\r\n}\r\nfunction createTemplateLiteral(elements) {\r\n return {\r\n type: 22 /* JS_TEMPLATE_LITERAL */,\r\n elements,\r\n loc: locStub\r\n };\r\n}\r\nfunction createIfStatement(test, consequent, alternate) {\r\n return {\r\n type: 23 /* JS_IF_STATEMENT */,\r\n test,\r\n consequent,\r\n alternate,\r\n loc: locStub\r\n };\r\n}\r\nfunction createAssignmentExpression(left, right) {\r\n return {\r\n type: 24 /* JS_ASSIGNMENT_EXPRESSION */,\r\n left,\r\n right,\r\n loc: locStub\r\n };\r\n}\r\nfunction createSequenceExpression(expressions) {\r\n return {\r\n type: 25 /* JS_SEQUENCE_EXPRESSION */,\r\n expressions,\r\n loc: locStub\r\n };\r\n}\r\nfunction createReturnStatement(returns) {\r\n return {\r\n type: 26 /* JS_RETURN_STATEMENT */,\r\n returns,\r\n loc: locStub\r\n };\r\n}\n\nconst isStaticExp = (p) => p.type === 4 /* SIMPLE_EXPRESSION */ && p.isStatic;\r\nconst isBuiltInType = (tag, expected) => tag === expected || tag === hyphenate(expected);\r\nfunction isCoreComponent(tag) {\r\n if (isBuiltInType(tag, 'Teleport')) {\r\n return TELEPORT;\r\n }\r\n else if (isBuiltInType(tag, 'Suspense')) {\r\n return SUSPENSE;\r\n }\r\n else if (isBuiltInType(tag, 'KeepAlive')) {\r\n return KEEP_ALIVE;\r\n }\r\n else if (isBuiltInType(tag, 'BaseTransition')) {\r\n return BASE_TRANSITION;\r\n }\r\n}\r\nconst nonIdentifierRE = /^\\d|[^\\$\\w]/;\r\nconst isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);\r\nconst validFirstIdentCharRE = /[A-Za-z_$\\xA0-\\uFFFF]/;\r\nconst validIdentCharRE = /[\\.\\?\\w$\\xA0-\\uFFFF]/;\r\nconst whitespaceRE = /\\s+[.[]\\s*|\\s*[.[]\\s+/g;\r\n/**\r\n * Simple lexer to check if an expression is a member expression. This is\r\n * lax and only checks validity at the root level (i.e. does not validate exps\r\n * inside square brackets), but it's ok since these are only used on template\r\n * expressions and false positives are invalid expressions in the first place.\r\n */\r\nconst isMemberExpressionBrowser = (path) => {\r\n // remove whitespaces around . or [ first\r\n path = path.trim().replace(whitespaceRE, s => s.trim());\r\n let state = 0 /* inMemberExp */;\r\n let stateStack = [];\r\n let currentOpenBracketCount = 0;\r\n let currentOpenParensCount = 0;\r\n let currentStringType = null;\r\n for (let i = 0; i < path.length; i++) {\r\n const char = path.charAt(i);\r\n switch (state) {\r\n case 0 /* inMemberExp */:\r\n if (char === '[') {\r\n stateStack.push(state);\r\n state = 1 /* inBrackets */;\r\n currentOpenBracketCount++;\r\n }\r\n else if (char === '(') {\r\n stateStack.push(state);\r\n state = 2 /* inParens */;\r\n currentOpenParensCount++;\r\n }\r\n else if (!(i === 0 ? validFirstIdentCharRE : validIdentCharRE).test(char)) {\r\n return false;\r\n }\r\n break;\r\n case 1 /* inBrackets */:\r\n if (char === `'` || char === `\"` || char === '`') {\r\n stateStack.push(state);\r\n state = 3 /* inString */;\r\n currentStringType = char;\r\n }\r\n else if (char === `[`) {\r\n currentOpenBracketCount++;\r\n }\r\n else if (char === `]`) {\r\n if (!--currentOpenBracketCount) {\r\n state = stateStack.pop();\r\n }\r\n }\r\n break;\r\n case 2 /* inParens */:\r\n if (char === `'` || char === `\"` || char === '`') {\r\n stateStack.push(state);\r\n state = 3 /* inString */;\r\n currentStringType = char;\r\n }\r\n else if (char === `(`) {\r\n currentOpenParensCount++;\r\n }\r\n else if (char === `)`) {\r\n // if the exp ends as a call then it should not be considered valid\r\n if (i === path.length - 1) {\r\n return false;\r\n }\r\n if (!--currentOpenParensCount) {\r\n state = stateStack.pop();\r\n }\r\n }\r\n break;\r\n case 3 /* inString */:\r\n if (char === currentStringType) {\r\n state = stateStack.pop();\r\n currentStringType = null;\r\n }\r\n break;\r\n }\r\n }\r\n return !currentOpenBracketCount && !currentOpenParensCount;\r\n};\r\nconst isMemberExpressionNode = NOOP\r\n ;\r\nconst isMemberExpression = isMemberExpressionBrowser\r\n ;\r\nfunction getInnerRange(loc, offset, length) {\r\n const source = loc.source.slice(offset, offset + length);\r\n const newLoc = {\r\n source,\r\n start: advancePositionWithClone(loc.start, loc.source, offset),\r\n end: loc.end\r\n };\r\n if (length != null) {\r\n newLoc.end = advancePositionWithClone(loc.start, loc.source, offset + length);\r\n }\r\n return newLoc;\r\n}\r\nfunction advancePositionWithClone(pos, source, numberOfCharacters = source.length) {\r\n return advancePositionWithMutation(extend({}, pos), source, numberOfCharacters);\r\n}\r\n// advance by mutation without cloning (for performance reasons), since this\r\n// gets called a lot in the parser\r\nfunction advancePositionWithMutation(pos, source, numberOfCharacters = source.length) {\r\n let linesCount = 0;\r\n let lastNewLinePos = -1;\r\n for (let i = 0; i < numberOfCharacters; i++) {\r\n if (source.charCodeAt(i) === 10 /* newline char code */) {\r\n linesCount++;\r\n lastNewLinePos = i;\r\n }\r\n }\r\n pos.offset += numberOfCharacters;\r\n pos.line += linesCount;\r\n pos.column =\r\n lastNewLinePos === -1\r\n ? pos.column + numberOfCharacters\r\n : numberOfCharacters - lastNewLinePos;\r\n return pos;\r\n}\r\nfunction assert(condition, msg) {\r\n /* istanbul ignore if */\r\n if (!condition) {\r\n throw new Error(msg || `unexpected compiler condition`);\r\n }\r\n}\r\nfunction findDir(node, name, allowEmpty = false) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ &&\r\n (allowEmpty || p.exp) &&\r\n (isString(name) ? p.name === name : name.test(p.name))) {\r\n return p;\r\n }\r\n }\r\n}\r\nfunction findProp(node, name, dynamicOnly = false, allowEmpty = false) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (dynamicOnly)\r\n continue;\r\n if (p.name === name && (p.value || allowEmpty)) {\r\n return p;\r\n }\r\n }\r\n else if (p.name === 'bind' &&\r\n (p.exp || allowEmpty) &&\r\n isStaticArgOf(p.arg, name)) {\r\n return p;\r\n }\r\n }\r\n}\r\nfunction isStaticArgOf(arg, name) {\r\n return !!(arg && isStaticExp(arg) && arg.content === name);\r\n}\r\nfunction hasDynamicKeyVBind(node) {\r\n return node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n p.name === 'bind' &&\r\n (!p.arg || // v-bind=\"obj\"\r\n p.arg.type !== 4 /* SIMPLE_EXPRESSION */ || // v-bind:[_ctx.foo]\r\n !p.arg.isStatic) // v-bind:[foo]\r\n );\r\n}\r\nfunction isText(node) {\r\n return node.type === 5 /* INTERPOLATION */ || node.type === 2 /* TEXT */;\r\n}\r\nfunction isVSlot(p) {\r\n return p.type === 7 /* DIRECTIVE */ && p.name === 'slot';\r\n}\r\nfunction isTemplateNode(node) {\r\n return (node.type === 1 /* ELEMENT */ && node.tagType === 3 /* TEMPLATE */);\r\n}\r\nfunction isSlotOutlet(node) {\r\n return node.type === 1 /* ELEMENT */ && node.tagType === 2 /* SLOT */;\r\n}\r\nfunction getVNodeHelper(ssr, isComponent) {\r\n return ssr || isComponent ? CREATE_VNODE : CREATE_ELEMENT_VNODE;\r\n}\r\nfunction getVNodeBlockHelper(ssr, isComponent) {\r\n return ssr || isComponent ? CREATE_BLOCK : CREATE_ELEMENT_BLOCK;\r\n}\r\nconst propsHelperSet = new Set([NORMALIZE_PROPS, GUARD_REACTIVE_PROPS]);\r\nfunction getUnnormalizedProps(props, callPath = []) {\r\n if (props &&\r\n !isString(props) &&\r\n props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n const callee = props.callee;\r\n if (!isString(callee) && propsHelperSet.has(callee)) {\r\n return getUnnormalizedProps(props.arguments[0], callPath.concat(props));\r\n }\r\n }\r\n return [props, callPath];\r\n}\r\nfunction injectProp(node, prop, context) {\r\n let propsWithInjection;\r\n /**\r\n * 1. mergeProps(...)\r\n * 2. toHandlers(...)\r\n * 3. normalizeProps(...)\r\n * 4. normalizeProps(guardReactiveProps(...))\r\n *\r\n * we need to get the real props before normalization\r\n */\r\n let props = node.type === 13 /* VNODE_CALL */ ? node.props : node.arguments[2];\r\n let callPath = [];\r\n let parentCall;\r\n if (props &&\r\n !isString(props) &&\r\n props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n const ret = getUnnormalizedProps(props);\r\n props = ret[0];\r\n callPath = ret[1];\r\n parentCall = callPath[callPath.length - 1];\r\n }\r\n if (props == null || isString(props)) {\r\n propsWithInjection = createObjectExpression([prop]);\r\n }\r\n else if (props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // merged props... add ours\r\n // only inject key to object literal if it's the first argument so that\r\n // if doesn't override user provided keys\r\n const first = props.arguments[0];\r\n if (!isString(first) && first.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n first.properties.unshift(prop);\r\n }\r\n else {\r\n if (props.callee === TO_HANDLERS) {\r\n // #2366\r\n propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n createObjectExpression([prop]),\r\n props\r\n ]);\r\n }\r\n else {\r\n props.arguments.unshift(createObjectExpression([prop]));\r\n }\r\n }\r\n !propsWithInjection && (propsWithInjection = props);\r\n }\r\n else if (props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n let alreadyExists = false;\r\n // check existing key to avoid overriding user provided keys\r\n if (prop.key.type === 4 /* SIMPLE_EXPRESSION */) {\r\n const propKeyName = prop.key.content;\r\n alreadyExists = props.properties.some(p => p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n p.key.content === propKeyName);\r\n }\r\n if (!alreadyExists) {\r\n props.properties.unshift(prop);\r\n }\r\n propsWithInjection = props;\r\n }\r\n else {\r\n // single v-bind with expression, return a merged replacement\r\n propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n createObjectExpression([prop]),\r\n props\r\n ]);\r\n // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(props))`,\r\n // it will be rewritten as `normalizeProps(mergeProps({ key: 0 }, props))`,\r\n // the `guardReactiveProps` will no longer be needed\r\n if (parentCall && parentCall.callee === GUARD_REACTIVE_PROPS) {\r\n parentCall = callPath[callPath.length - 2];\r\n }\r\n }\r\n if (node.type === 13 /* VNODE_CALL */) {\r\n if (parentCall) {\r\n parentCall.arguments[0] = propsWithInjection;\r\n }\r\n else {\r\n node.props = propsWithInjection;\r\n }\r\n }\r\n else {\r\n if (parentCall) {\r\n parentCall.arguments[0] = propsWithInjection;\r\n }\r\n else {\r\n node.arguments[2] = propsWithInjection;\r\n }\r\n }\r\n}\r\nfunction toValidAssetId(name, type) {\r\n // see issue#4422, we need adding identifier on validAssetId if variable `name` has specific character\r\n return `_${type}_${name.replace(/[^\\w]/g, (searchValue, replaceValue) => {\r\n return searchValue === '-' ? '_' : name.charCodeAt(replaceValue).toString();\r\n })}`;\r\n}\r\n// Check if a node contains expressions that reference current context scope ids\r\nfunction hasScopeRef(node, ids) {\r\n if (!node || Object.keys(ids).length === 0) {\r\n return false;\r\n }\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ &&\r\n (hasScopeRef(p.arg, ids) || hasScopeRef(p.exp, ids))) {\r\n return true;\r\n }\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 11 /* FOR */:\r\n if (hasScopeRef(node.source, ids)) {\r\n return true;\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 9 /* IF */:\r\n return node.branches.some(b => hasScopeRef(b, ids));\r\n case 10 /* IF_BRANCH */:\r\n if (hasScopeRef(node.condition, ids)) {\r\n return true;\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n return (!node.isStatic &&\r\n isSimpleIdentifier(node.content) &&\r\n !!ids[node.content]);\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n return node.children.some(c => isObject(c) && hasScopeRef(c, ids));\r\n case 5 /* INTERPOLATION */:\r\n case 12 /* TEXT_CALL */:\r\n return hasScopeRef(node.content, ids);\r\n case 2 /* TEXT */:\r\n case 3 /* COMMENT */:\r\n return false;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) ;\r\n return false;\r\n }\r\n}\r\nfunction getMemoedVNodeCall(node) {\r\n if (node.type === 14 /* JS_CALL_EXPRESSION */ && node.callee === WITH_MEMO) {\r\n return node.arguments[1].returns;\r\n }\r\n else {\r\n return node;\r\n }\r\n}\r\nfunction makeBlock(node, { helper, removeHelper, inSSR }) {\r\n if (!node.isBlock) {\r\n node.isBlock = true;\r\n removeHelper(getVNodeHelper(inSSR, node.isComponent));\r\n helper(OPEN_BLOCK);\r\n helper(getVNodeBlockHelper(inSSR, node.isComponent));\r\n }\r\n}\n\nconst deprecationData = {\r\n [\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */]: {\r\n message: `Platform-native elements with \"is\" prop will no longer be ` +\r\n `treated as components in Vue 3 unless the \"is\" value is explicitly ` +\r\n `prefixed with \"vue:\".`,\r\n link: `https://v3.vuejs.org/guide/migration/custom-elements-interop.html`\r\n },\r\n [\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */]: {\r\n message: key => `.sync modifier for v-bind has been removed. Use v-model with ` +\r\n `argument instead. \\`v-bind:${key}.sync\\` should be changed to ` +\r\n `\\`v-model:${key}\\`.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-model.html`\r\n },\r\n [\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */]: {\r\n message: `.prop modifier for v-bind has been removed and no longer necessary. ` +\r\n `Vue 3 will automatically set a binding as DOM property when appropriate.`\r\n },\r\n [\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */]: {\r\n message: `v-bind=\"obj\" usage is now order sensitive and behaves like JavaScript ` +\r\n `object spread: it will now overwrite an existing non-mergeable attribute ` +\r\n `that appears before v-bind in the case of conflict. ` +\r\n `To retain 2.x behavior, move v-bind to make it the first attribute. ` +\r\n `You can also suppress this warning if the usage is intended.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-bind.html`\r\n },\r\n [\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */]: {\r\n message: `.native modifier for v-on has been removed as is no longer necessary.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-on-native-modifier-removed.html`\r\n },\r\n [\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */]: {\r\n message: `v-if / v-for precedence when used on the same element has changed ` +\r\n `in Vue 3: v-if now takes higher precedence and will no longer have ` +\r\n `access to v-for scope variables. It is best to avoid the ambiguity ` +\r\n `with <template> tags or use a computed property that filters v-for ` +\r\n `data source.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-if-v-for.html`\r\n },\r\n [\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */]: {\r\n message: `<template> with no special directives will render as a native template ` +\r\n `element instead of its inner content in Vue 3.`\r\n },\r\n [\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */]: {\r\n message: `\"inline-template\" has been removed in Vue 3.`,\r\n link: `https://v3.vuejs.org/guide/migration/inline-template-attribute.html`\r\n },\r\n [\"COMPILER_FILTER\" /* COMPILER_FILTERS */]: {\r\n message: `filters have been removed in Vue 3. ` +\r\n `The \"|\" symbol will be treated as native JavaScript bitwise OR operator. ` +\r\n `Use method calls or computed properties instead.`,\r\n link: `https://v3.vuejs.org/guide/migration/filters.html`\r\n }\r\n};\r\nfunction getCompatValue(key, context) {\r\n const config = context.options\r\n ? context.options.compatConfig\r\n : context.compatConfig;\r\n const value = config && config[key];\r\n if (key === 'MODE') {\r\n return value || 3; // compiler defaults to v3 behavior\r\n }\r\n else {\r\n return value;\r\n }\r\n}\r\nfunction isCompatEnabled(key, context) {\r\n const mode = getCompatValue('MODE', context);\r\n const value = getCompatValue(key, context);\r\n // in v3 mode, only enable if explicitly set to true\r\n // otherwise enable for any non-false value\r\n return mode === 3 ? value === true : value !== false;\r\n}\r\nfunction checkCompatEnabled(key, context, loc, ...args) {\r\n const enabled = isCompatEnabled(key, context);\r\n if ((process.env.NODE_ENV !== 'production') && enabled) {\r\n warnDeprecation(key, context, loc, ...args);\r\n }\r\n return enabled;\r\n}\r\nfunction warnDeprecation(key, context, loc, ...args) {\r\n const val = getCompatValue(key, context);\r\n if (val === 'suppress-warning') {\r\n return;\r\n }\r\n const { message, link } = deprecationData[key];\r\n const msg = `(deprecation ${key}) ${typeof message === 'function' ? message(...args) : message}${link ? `\\n Details: ${link}` : ``}`;\r\n const err = new SyntaxError(msg);\r\n err.code = key;\r\n if (loc)\r\n err.loc = loc;\r\n context.onWarn(err);\r\n}\n\n// The default decoder only provides escapes for characters reserved as part of\r\n// the template syntax, and is only used if the custom renderer did not provide\r\n// a platform-specific decoder.\r\nconst decodeRE = /&(gt|lt|amp|apos|quot);/g;\r\nconst decodeMap = {\r\n gt: '>',\r\n lt: '<',\r\n amp: '&',\r\n apos: \"'\",\r\n quot: '\"'\r\n};\r\nconst defaultParserOptions = {\r\n delimiters: [`{{`, `}}`],\r\n getNamespace: () => 0 /* HTML */,\r\n getTextMode: () => 0 /* DATA */,\r\n isVoidTag: NO,\r\n isPreTag: NO,\r\n isCustomElement: NO,\r\n decodeEntities: (rawText) => rawText.replace(decodeRE, (_, p1) => decodeMap[p1]),\r\n onError: defaultOnError,\r\n onWarn: defaultOnWarn,\r\n comments: (process.env.NODE_ENV !== 'production')\r\n};\r\nfunction baseParse(content, options = {}) {\r\n const context = createParserContext(content, options);\r\n const start = getCursor(context);\r\n return createRoot(parseChildren(context, 0 /* DATA */, []), getSelection(context, start));\r\n}\r\nfunction createParserContext(content, rawOptions) {\r\n const options = extend({}, defaultParserOptions);\r\n let key;\r\n for (key in rawOptions) {\r\n // @ts-ignore\r\n options[key] =\r\n rawOptions[key] === undefined\r\n ? defaultParserOptions[key]\r\n : rawOptions[key];\r\n }\r\n return {\r\n options,\r\n column: 1,\r\n line: 1,\r\n offset: 0,\r\n originalSource: content,\r\n source: content,\r\n inPre: false,\r\n inVPre: false,\r\n onWarn: options.onWarn\r\n };\r\n}\r\nfunction parseChildren(context, mode, ancestors) {\r\n const parent = last(ancestors);\r\n const ns = parent ? parent.ns : 0 /* HTML */;\r\n const nodes = [];\r\n while (!isEnd(context, mode, ancestors)) {\r\n const s = context.source;\r\n let node = undefined;\r\n if (mode === 0 /* DATA */ || mode === 1 /* RCDATA */) {\r\n if (!context.inVPre && startsWith(s, context.options.delimiters[0])) {\r\n // '{{'\r\n node = parseInterpolation(context, mode);\r\n }\r\n else if (mode === 0 /* DATA */ && s[0] === '<') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#tag-open-state\r\n if (s.length === 1) {\r\n emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 1);\r\n }\r\n else if (s[1] === '!') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#markup-declaration-open-state\r\n if (startsWith(s, '<!--')) {\r\n node = parseComment(context);\r\n }\r\n else if (startsWith(s, '<!DOCTYPE')) {\r\n // Ignore DOCTYPE by a limitation.\r\n node = parseBogusComment(context);\r\n }\r\n else if (startsWith(s, '<![CDATA[')) {\r\n if (ns !== 0 /* HTML */) {\r\n node = parseCDATA(context, ancestors);\r\n }\r\n else {\r\n emitError(context, 1 /* CDATA_IN_HTML_CONTENT */);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else {\r\n emitError(context, 11 /* INCORRECTLY_OPENED_COMMENT */);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else if (s[1] === '/') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#end-tag-open-state\r\n if (s.length === 2) {\r\n emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 2);\r\n }\r\n else if (s[2] === '>') {\r\n emitError(context, 14 /* MISSING_END_TAG_NAME */, 2);\r\n advanceBy(context, 3);\r\n continue;\r\n }\r\n else if (/[a-z]/i.test(s[2])) {\r\n emitError(context, 23 /* X_INVALID_END_TAG */);\r\n parseTag(context, 1 /* End */, parent);\r\n continue;\r\n }\r\n else {\r\n emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 2);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else if (/[a-z]/i.test(s[1])) {\r\n node = parseElement(context, ancestors);\r\n // 2.x <template> with no directive compat\r\n if (isCompatEnabled(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context) &&\r\n node &&\r\n node.tag === 'template' &&\r\n !node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n isSpecialTemplateDirective(p.name))) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warnDeprecation(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context, node.loc);\r\n node = node.children;\r\n }\r\n }\r\n else if (s[1] === '?') {\r\n emitError(context, 21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */, 1);\r\n node = parseBogusComment(context);\r\n }\r\n else {\r\n emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 1);\r\n }\r\n }\r\n }\r\n if (!node) {\r\n node = parseText(context, mode);\r\n }\r\n if (isArray(node)) {\r\n for (let i = 0; i < node.length; i++) {\r\n pushNode(nodes, node[i]);\r\n }\r\n }\r\n else {\r\n pushNode(nodes, node);\r\n }\r\n }\r\n // Whitespace handling strategy like v2\r\n let removedWhitespace = false;\r\n if (mode !== 2 /* RAWTEXT */ && mode !== 1 /* RCDATA */) {\r\n const shouldCondense = context.options.whitespace !== 'preserve';\r\n for (let i = 0; i < nodes.length; i++) {\r\n const node = nodes[i];\r\n if (!context.inPre && node.type === 2 /* TEXT */) {\r\n if (!/[^\\t\\r\\n\\f ]/.test(node.content)) {\r\n const prev = nodes[i - 1];\r\n const next = nodes[i + 1];\r\n // Remove if:\r\n // - the whitespace is the first or last node, or:\r\n // - (condense mode) the whitespace is adjacent to a comment, or:\r\n // - (condense mode) the whitespace is between two elements AND contains newline\r\n if (!prev ||\r\n !next ||\r\n (shouldCondense &&\r\n (prev.type === 3 /* COMMENT */ ||\r\n next.type === 3 /* COMMENT */ ||\r\n (prev.type === 1 /* ELEMENT */ &&\r\n next.type === 1 /* ELEMENT */ &&\r\n /[\\r\\n]/.test(node.content))))) {\r\n removedWhitespace = true;\r\n nodes[i] = null;\r\n }\r\n else {\r\n // Otherwise, the whitespace is condensed into a single space\r\n node.content = ' ';\r\n }\r\n }\r\n else if (shouldCondense) {\r\n // in condense mode, consecutive whitespaces in text are condensed\r\n // down to a single space.\r\n node.content = node.content.replace(/[\\t\\r\\n\\f ]+/g, ' ');\r\n }\r\n }\r\n // Remove comment nodes if desired by configuration.\r\n else if (node.type === 3 /* COMMENT */ && !context.options.comments) {\r\n removedWhitespace = true;\r\n nodes[i] = null;\r\n }\r\n }\r\n if (context.inPre && parent && context.options.isPreTag(parent.tag)) {\r\n // remove leading newline per html spec\r\n // https://html.spec.whatwg.org/multipage/grouping-content.html#the-pre-element\r\n const first = nodes[0];\r\n if (first && first.type === 2 /* TEXT */) {\r\n first.content = first.content.replace(/^\\r?\\n/, '');\r\n }\r\n }\r\n }\r\n return removedWhitespace ? nodes.filter(Boolean) : nodes;\r\n}\r\nfunction pushNode(nodes, node) {\r\n if (node.type === 2 /* TEXT */) {\r\n const prev = last(nodes);\r\n // Merge if both this and the previous node are text and those are\r\n // consecutive. This happens for cases like \"a < b\".\r\n if (prev &&\r\n prev.type === 2 /* TEXT */ &&\r\n prev.loc.end.offset === node.loc.start.offset) {\r\n prev.content += node.content;\r\n prev.loc.end = node.loc.end;\r\n prev.loc.source += node.loc.source;\r\n return;\r\n }\r\n }\r\n nodes.push(node);\r\n}\r\nfunction parseCDATA(context, ancestors) {\r\n advanceBy(context, 9);\r\n const nodes = parseChildren(context, 3 /* CDATA */, ancestors);\r\n if (context.source.length === 0) {\r\n emitError(context, 6 /* EOF_IN_CDATA */);\r\n }\r\n else {\r\n advanceBy(context, 3);\r\n }\r\n return nodes;\r\n}\r\nfunction parseComment(context) {\r\n const start = getCursor(context);\r\n let content;\r\n // Regular comment.\r\n const match = /--(\\!)?>/.exec(context.source);\r\n if (!match) {\r\n content = context.source.slice(4);\r\n advanceBy(context, context.source.length);\r\n emitError(context, 7 /* EOF_IN_COMMENT */);\r\n }\r\n else {\r\n if (match.index <= 3) {\r\n emitError(context, 0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */);\r\n }\r\n if (match[1]) {\r\n emitError(context, 10 /* INCORRECTLY_CLOSED_COMMENT */);\r\n }\r\n content = context.source.slice(4, match.index);\r\n // Advancing with reporting nested comments.\r\n const s = context.source.slice(0, match.index);\r\n let prevIndex = 1, nestedIndex = 0;\r\n while ((nestedIndex = s.indexOf('<!--', prevIndex)) !== -1) {\r\n advanceBy(context, nestedIndex - prevIndex + 1);\r\n if (nestedIndex + 4 < s.length) {\r\n emitError(context, 16 /* NESTED_COMMENT */);\r\n }\r\n prevIndex = nestedIndex + 1;\r\n }\r\n advanceBy(context, match.index + match[0].length - prevIndex + 1);\r\n }\r\n return {\r\n type: 3 /* COMMENT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseBogusComment(context) {\r\n const start = getCursor(context);\r\n const contentStart = context.source[1] === '?' ? 1 : 2;\r\n let content;\r\n const closeIndex = context.source.indexOf('>');\r\n if (closeIndex === -1) {\r\n content = context.source.slice(contentStart);\r\n advanceBy(context, context.source.length);\r\n }\r\n else {\r\n content = context.source.slice(contentStart, closeIndex);\r\n advanceBy(context, closeIndex + 1);\r\n }\r\n return {\r\n type: 3 /* COMMENT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseElement(context, ancestors) {\r\n // Start tag.\r\n const wasInPre = context.inPre;\r\n const wasInVPre = context.inVPre;\r\n const parent = last(ancestors);\r\n const element = parseTag(context, 0 /* Start */, parent);\r\n const isPreBoundary = context.inPre && !wasInPre;\r\n const isVPreBoundary = context.inVPre && !wasInVPre;\r\n if (element.isSelfClosing || context.options.isVoidTag(element.tag)) {\r\n // #4030 self-closing <pre> tag\r\n if (isPreBoundary) {\r\n context.inPre = false;\r\n }\r\n if (isVPreBoundary) {\r\n context.inVPre = false;\r\n }\r\n return element;\r\n }\r\n // Children.\r\n ancestors.push(element);\r\n const mode = context.options.getTextMode(element, parent);\r\n const children = parseChildren(context, mode, ancestors);\r\n ancestors.pop();\r\n // 2.x inline-template compat\r\n {\r\n const inlineTemplateProp = element.props.find(p => p.type === 6 /* ATTRIBUTE */ && p.name === 'inline-template');\r\n if (inlineTemplateProp &&\r\n checkCompatEnabled(\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */, context, inlineTemplateProp.loc)) {\r\n const loc = getSelection(context, element.loc.end);\r\n inlineTemplateProp.value = {\r\n type: 2 /* TEXT */,\r\n content: loc.source,\r\n loc\r\n };\r\n }\r\n }\r\n element.children = children;\r\n // End tag.\r\n if (startsWithEndTagOpen(context.source, element.tag)) {\r\n parseTag(context, 1 /* End */, parent);\r\n }\r\n else {\r\n emitError(context, 24 /* X_MISSING_END_TAG */, 0, element.loc.start);\r\n if (context.source.length === 0 && element.tag.toLowerCase() === 'script') {\r\n const first = children[0];\r\n if (first && startsWith(first.loc.source, '<!--')) {\r\n emitError(context, 8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */);\r\n }\r\n }\r\n }\r\n element.loc = getSelection(context, element.loc.start);\r\n if (isPreBoundary) {\r\n context.inPre = false;\r\n }\r\n if (isVPreBoundary) {\r\n context.inVPre = false;\r\n }\r\n return element;\r\n}\r\nconst isSpecialTemplateDirective = /*#__PURE__*/ makeMap(`if,else,else-if,for,slot`);\r\nfunction parseTag(context, type, parent) {\r\n // Tag open.\r\n const start = getCursor(context);\r\n const match = /^<\\/?([a-z][^\\t\\r\\n\\f />]*)/i.exec(context.source);\r\n const tag = match[1];\r\n const ns = context.options.getNamespace(tag, parent);\r\n advanceBy(context, match[0].length);\r\n advanceSpaces(context);\r\n // save current state in case we need to re-parse attributes with v-pre\r\n const cursor = getCursor(context);\r\n const currentSource = context.source;\r\n // check <pre> tag\r\n if (context.options.isPreTag(tag)) {\r\n context.inPre = true;\r\n }\r\n // Attributes.\r\n let props = parseAttributes(context, type);\r\n // check v-pre\r\n if (type === 0 /* Start */ &&\r\n !context.inVPre &&\r\n props.some(p => p.type === 7 /* DIRECTIVE */ && p.name === 'pre')) {\r\n context.inVPre = true;\r\n // reset context\r\n extend(context, cursor);\r\n context.source = currentSource;\r\n // re-parse attrs and filter out v-pre itself\r\n props = parseAttributes(context, type).filter(p => p.name !== 'v-pre');\r\n }\r\n // Tag close.\r\n let isSelfClosing = false;\r\n if (context.source.length === 0) {\r\n emitError(context, 9 /* EOF_IN_TAG */);\r\n }\r\n else {\r\n isSelfClosing = startsWith(context.source, '/>');\r\n if (type === 1 /* End */ && isSelfClosing) {\r\n emitError(context, 4 /* END_TAG_WITH_TRAILING_SOLIDUS */);\r\n }\r\n advanceBy(context, isSelfClosing ? 2 : 1);\r\n }\r\n if (type === 1 /* End */) {\r\n return;\r\n }\r\n // 2.x deprecation checks\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n isCompatEnabled(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context)) {\r\n let hasIf = false;\r\n let hasFor = false;\r\n for (let i = 0; i < props.length; i++) {\r\n const p = props[i];\r\n if (p.type === 7 /* DIRECTIVE */) {\r\n if (p.name === 'if') {\r\n hasIf = true;\r\n }\r\n else if (p.name === 'for') {\r\n hasFor = true;\r\n }\r\n }\r\n if (hasIf && hasFor) {\r\n warnDeprecation(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context, getSelection(context, start));\r\n break;\r\n }\r\n }\r\n }\r\n let tagType = 0 /* ELEMENT */;\r\n if (!context.inVPre) {\r\n if (tag === 'slot') {\r\n tagType = 2 /* SLOT */;\r\n }\r\n else if (tag === 'template') {\r\n if (props.some(p => p.type === 7 /* DIRECTIVE */ && isSpecialTemplateDirective(p.name))) {\r\n tagType = 3 /* TEMPLATE */;\r\n }\r\n }\r\n else if (isComponent(tag, props, context)) {\r\n tagType = 1 /* COMPONENT */;\r\n }\r\n }\r\n return {\r\n type: 1 /* ELEMENT */,\r\n ns,\r\n tag,\r\n tagType,\r\n props,\r\n isSelfClosing,\r\n children: [],\r\n loc: getSelection(context, start),\r\n codegenNode: undefined // to be created during transform phase\r\n };\r\n}\r\nfunction isComponent(tag, props, context) {\r\n const options = context.options;\r\n if (options.isCustomElement(tag)) {\r\n return false;\r\n }\r\n if (tag === 'component' ||\r\n /^[A-Z]/.test(tag) ||\r\n isCoreComponent(tag) ||\r\n (options.isBuiltInComponent && options.isBuiltInComponent(tag)) ||\r\n (options.isNativeTag && !options.isNativeTag(tag))) {\r\n return true;\r\n }\r\n // at this point the tag should be a native tag, but check for potential \"is\"\r\n // casting\r\n for (let i = 0; i < props.length; i++) {\r\n const p = props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (p.name === 'is' && p.value) {\r\n if (p.value.content.startsWith('vue:')) {\r\n return true;\r\n }\r\n else if (checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n return true;\r\n }\r\n }\r\n }\r\n else {\r\n // directive\r\n // v-is (TODO Deprecate)\r\n if (p.name === 'is') {\r\n return true;\r\n }\r\n else if (\r\n // :is on plain element - only treat as component in compat mode\r\n p.name === 'bind' &&\r\n isStaticArgOf(p.arg, 'is') &&\r\n true &&\r\n checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n return true;\r\n }\r\n }\r\n }\r\n}\r\nfunction parseAttributes(context, type) {\r\n const props = [];\r\n const attributeNames = new Set();\r\n while (context.source.length > 0 &&\r\n !startsWith(context.source, '>') &&\r\n !startsWith(context.source, '/>')) {\r\n if (startsWith(context.source, '/')) {\r\n emitError(context, 22 /* UNEXPECTED_SOLIDUS_IN_TAG */);\r\n advanceBy(context, 1);\r\n advanceSpaces(context);\r\n continue;\r\n }\r\n if (type === 1 /* End */) {\r\n emitError(context, 3 /* END_TAG_WITH_ATTRIBUTES */);\r\n }\r\n const attr = parseAttribute(context, attributeNames);\r\n // Trim whitespace between class\r\n // https://github.com/vuejs/vue-next/issues/4251\r\n if (attr.type === 6 /* ATTRIBUTE */ &&\r\n attr.value &&\r\n attr.name === 'class') {\r\n attr.value.content = attr.value.content.replace(/\\s+/g, ' ').trim();\r\n }\r\n if (type === 0 /* Start */) {\r\n props.push(attr);\r\n }\r\n if (/^[^\\t\\r\\n\\f />]/.test(context.source)) {\r\n emitError(context, 15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */);\r\n }\r\n advanceSpaces(context);\r\n }\r\n return props;\r\n}\r\nfunction parseAttribute(context, nameSet) {\r\n // Name.\r\n const start = getCursor(context);\r\n const match = /^[^\\t\\r\\n\\f />][^\\t\\r\\n\\f />=]*/.exec(context.source);\r\n const name = match[0];\r\n if (nameSet.has(name)) {\r\n emitError(context, 2 /* DUPLICATE_ATTRIBUTE */);\r\n }\r\n nameSet.add(name);\r\n if (name[0] === '=') {\r\n emitError(context, 19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */);\r\n }\r\n {\r\n const pattern = /[\"'<]/g;\r\n let m;\r\n while ((m = pattern.exec(name))) {\r\n emitError(context, 17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */, m.index);\r\n }\r\n }\r\n advanceBy(context, name.length);\r\n // Value\r\n let value = undefined;\r\n if (/^[\\t\\r\\n\\f ]*=/.test(context.source)) {\r\n advanceSpaces(context);\r\n advanceBy(context, 1);\r\n advanceSpaces(context);\r\n value = parseAttributeValue(context);\r\n if (!value) {\r\n emitError(context, 13 /* MISSING_ATTRIBUTE_VALUE */);\r\n }\r\n }\r\n const loc = getSelection(context, start);\r\n if (!context.inVPre && /^(v-[A-Za-z0-9-]|:|\\.|@|#)/.test(name)) {\r\n const match = /(?:^v-([a-z0-9-]+))?(?:(?::|^\\.|^@|^#)(\\[[^\\]]+\\]|[^\\.]+))?(.+)?$/i.exec(name);\r\n let isPropShorthand = startsWith(name, '.');\r\n let dirName = match[1] ||\r\n (isPropShorthand || startsWith(name, ':')\r\n ? 'bind'\r\n : startsWith(name, '@')\r\n ? 'on'\r\n : 'slot');\r\n let arg;\r\n if (match[2]) {\r\n const isSlot = dirName === 'slot';\r\n const startOffset = name.lastIndexOf(match[2]);\r\n const loc = getSelection(context, getNewPosition(context, start, startOffset), getNewPosition(context, start, startOffset + match[2].length + ((isSlot && match[3]) || '').length));\r\n let content = match[2];\r\n let isStatic = true;\r\n if (content.startsWith('[')) {\r\n isStatic = false;\r\n if (!content.endsWith(']')) {\r\n emitError(context, 27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */);\r\n content = content.slice(1);\r\n }\r\n else {\r\n content = content.slice(1, content.length - 1);\r\n }\r\n }\r\n else if (isSlot) {\r\n // #1241 special case for v-slot: vuetify relies extensively on slot\r\n // names containing dots. v-slot doesn't have any modifiers and Vue 2.x\r\n // supports such usage so we are keeping it consistent with 2.x.\r\n content += match[3] || '';\r\n }\r\n arg = {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n content,\r\n isStatic,\r\n constType: isStatic\r\n ? 3 /* CAN_STRINGIFY */\r\n : 0 /* NOT_CONSTANT */,\r\n loc\r\n };\r\n }\r\n if (value && value.isQuoted) {\r\n const valueLoc = value.loc;\r\n valueLoc.start.offset++;\r\n valueLoc.start.column++;\r\n valueLoc.end = advancePositionWithClone(valueLoc.start, value.content);\r\n valueLoc.source = valueLoc.source.slice(1, -1);\r\n }\r\n const modifiers = match[3] ? match[3].slice(1).split('.') : [];\r\n if (isPropShorthand)\r\n modifiers.push('prop');\r\n // 2.x compat v-bind:foo.sync -> v-model:foo\r\n if (dirName === 'bind' && arg) {\r\n if (modifiers.includes('sync') &&\r\n checkCompatEnabled(\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */, context, loc, arg.loc.source)) {\r\n dirName = 'model';\r\n modifiers.splice(modifiers.indexOf('sync'), 1);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && modifiers.includes('prop')) {\r\n checkCompatEnabled(\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */, context, loc);\r\n }\r\n }\r\n return {\r\n type: 7 /* DIRECTIVE */,\r\n name: dirName,\r\n exp: value && {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n content: value.content,\r\n isStatic: false,\r\n // Treat as non-constant by default. This can be potentially set to\r\n // other values by `transformExpression` to make it eligible for hoisting.\r\n constType: 0 /* NOT_CONSTANT */,\r\n loc: value.loc\r\n },\r\n arg,\r\n modifiers,\r\n loc\r\n };\r\n }\r\n // missing directive name or illegal directive name\r\n if (!context.inVPre && startsWith(name, 'v-')) {\r\n emitError(context, 26 /* X_MISSING_DIRECTIVE_NAME */);\r\n }\r\n return {\r\n type: 6 /* ATTRIBUTE */,\r\n name,\r\n value: value && {\r\n type: 2 /* TEXT */,\r\n content: value.content,\r\n loc: value.loc\r\n },\r\n loc\r\n };\r\n}\r\nfunction parseAttributeValue(context) {\r\n const start = getCursor(context);\r\n let content;\r\n const quote = context.source[0];\r\n const isQuoted = quote === `\"` || quote === `'`;\r\n if (isQuoted) {\r\n // Quoted value.\r\n advanceBy(context, 1);\r\n const endIndex = context.source.indexOf(quote);\r\n if (endIndex === -1) {\r\n content = parseTextData(context, context.source.length, 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n else {\r\n content = parseTextData(context, endIndex, 4 /* ATTRIBUTE_VALUE */);\r\n advanceBy(context, 1);\r\n }\r\n }\r\n else {\r\n // Unquoted\r\n const match = /^[^\\t\\r\\n\\f >]+/.exec(context.source);\r\n if (!match) {\r\n return undefined;\r\n }\r\n const unexpectedChars = /[\"'<=`]/g;\r\n let m;\r\n while ((m = unexpectedChars.exec(match[0]))) {\r\n emitError(context, 18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */, m.index);\r\n }\r\n content = parseTextData(context, match[0].length, 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n return { content, isQuoted, loc: getSelection(context, start) };\r\n}\r\nfunction parseInterpolation(context, mode) {\r\n const [open, close] = context.options.delimiters;\r\n const closeIndex = context.source.indexOf(close, open.length);\r\n if (closeIndex === -1) {\r\n emitError(context, 25 /* X_MISSING_INTERPOLATION_END */);\r\n return undefined;\r\n }\r\n const start = getCursor(context);\r\n advanceBy(context, open.length);\r\n const innerStart = getCursor(context);\r\n const innerEnd = getCursor(context);\r\n const rawContentLength = closeIndex - open.length;\r\n const rawContent = context.source.slice(0, rawContentLength);\r\n const preTrimContent = parseTextData(context, rawContentLength, mode);\r\n const content = preTrimContent.trim();\r\n const startOffset = preTrimContent.indexOf(content);\r\n if (startOffset > 0) {\r\n advancePositionWithMutation(innerStart, rawContent, startOffset);\r\n }\r\n const endOffset = rawContentLength - (preTrimContent.length - content.length - startOffset);\r\n advancePositionWithMutation(innerEnd, rawContent, endOffset);\r\n advanceBy(context, close.length);\r\n return {\r\n type: 5 /* INTERPOLATION */,\r\n content: {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n isStatic: false,\r\n // Set `isConstant` to false by default and will decide in transformExpression\r\n constType: 0 /* NOT_CONSTANT */,\r\n content,\r\n loc: getSelection(context, innerStart, innerEnd)\r\n },\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseText(context, mode) {\r\n const endTokens = mode === 3 /* CDATA */ ? [']]>'] : ['<', context.options.delimiters[0]];\r\n let endIndex = context.source.length;\r\n for (let i = 0; i < endTokens.length; i++) {\r\n const index = context.source.indexOf(endTokens[i], 1);\r\n if (index !== -1 && endIndex > index) {\r\n endIndex = index;\r\n }\r\n }\r\n const start = getCursor(context);\r\n const content = parseTextData(context, endIndex, mode);\r\n return {\r\n type: 2 /* TEXT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\n/**\r\n * Get text data with a given length from the current location.\r\n * This translates HTML entities in the text data.\r\n */\r\nfunction parseTextData(context, length, mode) {\r\n const rawText = context.source.slice(0, length);\r\n advanceBy(context, length);\r\n if (mode === 2 /* RAWTEXT */ ||\r\n mode === 3 /* CDATA */ ||\r\n rawText.indexOf('&') === -1) {\r\n return rawText;\r\n }\r\n else {\r\n // DATA or RCDATA containing \"&\"\". Entity decoding required.\r\n return context.options.decodeEntities(rawText, mode === 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n}\r\nfunction getCursor(context) {\r\n const { column, line, offset } = context;\r\n return { column, line, offset };\r\n}\r\nfunction getSelection(context, start, end) {\r\n end = end || getCursor(context);\r\n return {\r\n start,\r\n end,\r\n source: context.originalSource.slice(start.offset, end.offset)\r\n };\r\n}\r\nfunction last(xs) {\r\n return xs[xs.length - 1];\r\n}\r\nfunction startsWith(source, searchString) {\r\n return source.startsWith(searchString);\r\n}\r\nfunction advanceBy(context, numberOfCharacters) {\r\n const { source } = context;\r\n advancePositionWithMutation(context, source, numberOfCharacters);\r\n context.source = source.slice(numberOfCharacters);\r\n}\r\nfunction advanceSpaces(context) {\r\n const match = /^[\\t\\r\\n\\f ]+/.exec(context.source);\r\n if (match) {\r\n advanceBy(context, match[0].length);\r\n }\r\n}\r\nfunction getNewPosition(context, start, numberOfCharacters) {\r\n return advancePositionWithClone(start, context.originalSource.slice(start.offset, numberOfCharacters), numberOfCharacters);\r\n}\r\nfunction emitError(context, code, offset, loc = getCursor(context)) {\r\n if (offset) {\r\n loc.offset += offset;\r\n loc.column += offset;\r\n }\r\n context.options.onError(createCompilerError(code, {\r\n start: loc,\r\n end: loc,\r\n source: ''\r\n }));\r\n}\r\nfunction isEnd(context, mode, ancestors) {\r\n const s = context.source;\r\n switch (mode) {\r\n case 0 /* DATA */:\r\n if (startsWith(s, '</')) {\r\n // TODO: probably bad performance\r\n for (let i = ancestors.length - 1; i >= 0; --i) {\r\n if (startsWithEndTagOpen(s, ancestors[i].tag)) {\r\n return true;\r\n }\r\n }\r\n }\r\n break;\r\n case 1 /* RCDATA */:\r\n case 2 /* RAWTEXT */: {\r\n const parent = last(ancestors);\r\n if (parent && startsWithEndTagOpen(s, parent.tag)) {\r\n return true;\r\n }\r\n break;\r\n }\r\n case 3 /* CDATA */:\r\n if (startsWith(s, ']]>')) {\r\n return true;\r\n }\r\n break;\r\n }\r\n return !s;\r\n}\r\nfunction startsWithEndTagOpen(source, tag) {\r\n return (startsWith(source, '</') &&\r\n source.slice(2, 2 + tag.length).toLowerCase() === tag.toLowerCase() &&\r\n /[\\t\\r\\n\\f />]/.test(source[2 + tag.length] || '>'));\r\n}\n\nfunction hoistStatic(root, context) {\r\n walk(root, context, \r\n // Root node is unfortunately non-hoistable due to potential parent\r\n // fallthrough attributes.\r\n isSingleElementRoot(root, root.children[0]));\r\n}\r\nfunction isSingleElementRoot(root, child) {\r\n const { children } = root;\r\n return (children.length === 1 &&\r\n child.type === 1 /* ELEMENT */ &&\r\n !isSlotOutlet(child));\r\n}\r\nfunction walk(node, context, doNotHoistNode = false) {\r\n const { children } = node;\r\n const originalCount = children.length;\r\n let hoistedCount = 0;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n // only plain elements & text calls are eligible for hoisting.\r\n if (child.type === 1 /* ELEMENT */ &&\r\n child.tagType === 0 /* ELEMENT */) {\r\n const constantType = doNotHoistNode\r\n ? 0 /* NOT_CONSTANT */\r\n : getConstantType(child, context);\r\n if (constantType > 0 /* NOT_CONSTANT */) {\r\n if (constantType >= 2 /* CAN_HOIST */) {\r\n child.codegenNode.patchFlag =\r\n -1 /* HOISTED */ + ((process.env.NODE_ENV !== 'production') ? ` /* HOISTED */` : ``);\r\n child.codegenNode = context.hoist(child.codegenNode);\r\n hoistedCount++;\r\n continue;\r\n }\r\n }\r\n else {\r\n // node may contain dynamic children, but its props may be eligible for\r\n // hoisting.\r\n const codegenNode = child.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n const flag = getPatchFlag(codegenNode);\r\n if ((!flag ||\r\n flag === 512 /* NEED_PATCH */ ||\r\n flag === 1 /* TEXT */) &&\r\n getGeneratedPropsConstantType(child, context) >=\r\n 2 /* CAN_HOIST */) {\r\n const props = getNodeProps(child);\r\n if (props) {\r\n codegenNode.props = context.hoist(props);\r\n }\r\n }\r\n if (codegenNode.dynamicProps) {\r\n codegenNode.dynamicProps = context.hoist(codegenNode.dynamicProps);\r\n }\r\n }\r\n }\r\n }\r\n else if (child.type === 12 /* TEXT_CALL */ &&\r\n getConstantType(child.content, context) >= 2 /* CAN_HOIST */) {\r\n child.codegenNode = context.hoist(child.codegenNode);\r\n hoistedCount++;\r\n }\r\n // walk further\r\n if (child.type === 1 /* ELEMENT */) {\r\n const isComponent = child.tagType === 1 /* COMPONENT */;\r\n if (isComponent) {\r\n context.scopes.vSlot++;\r\n }\r\n walk(child, context);\r\n if (isComponent) {\r\n context.scopes.vSlot--;\r\n }\r\n }\r\n else if (child.type === 11 /* FOR */) {\r\n // Do not hoist v-for single child because it has to be a block\r\n walk(child, context, child.children.length === 1);\r\n }\r\n else if (child.type === 9 /* IF */) {\r\n for (let i = 0; i < child.branches.length; i++) {\r\n // Do not hoist v-if single child because it has to be a block\r\n walk(child.branches[i], context, child.branches[i].children.length === 1);\r\n }\r\n }\r\n }\r\n if (hoistedCount && context.transformHoist) {\r\n context.transformHoist(children, context, node);\r\n }\r\n // all children were hoisted - the entire children array is hoistable.\r\n if (hoistedCount &&\r\n hoistedCount === originalCount &&\r\n node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n node.codegenNode &&\r\n node.codegenNode.type === 13 /* VNODE_CALL */ &&\r\n isArray(node.codegenNode.children)) {\r\n node.codegenNode.children = context.hoist(createArrayExpression(node.codegenNode.children));\r\n }\r\n}\r\nfunction getConstantType(node, context) {\r\n const { constantCache } = context;\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n if (node.tagType !== 0 /* ELEMENT */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n const cached = constantCache.get(node);\r\n if (cached !== undefined) {\r\n return cached;\r\n }\r\n const codegenNode = node.codegenNode;\r\n if (codegenNode.type !== 13 /* VNODE_CALL */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (codegenNode.isBlock &&\r\n node.tag !== 'svg' &&\r\n node.tag !== 'foreignObject') {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n const flag = getPatchFlag(codegenNode);\r\n if (!flag) {\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n // Element itself has no patch flag. However we still need to check:\r\n // 1. Even for a node with no patch flag, it is possible for it to contain\r\n // non-hoistable expressions that refers to scope variables, e.g. compiler\r\n // injected keys or cached event handlers. Therefore we need to always\r\n // check the codegenNode's props to be sure.\r\n const generatedPropsType = getGeneratedPropsConstantType(node, context);\r\n if (generatedPropsType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (generatedPropsType < returnType) {\r\n returnType = generatedPropsType;\r\n }\r\n // 2. its children.\r\n for (let i = 0; i < node.children.length; i++) {\r\n const childType = getConstantType(node.children[i], context);\r\n if (childType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (childType < returnType) {\r\n returnType = childType;\r\n }\r\n }\r\n // 3. if the type is not already CAN_SKIP_PATCH which is the lowest non-0\r\n // type, check if any of the props can cause the type to be lowered\r\n // we can skip can_patch because it's guaranteed by the absence of a\r\n // patchFlag.\r\n if (returnType > 1 /* CAN_SKIP_PATCH */) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ && p.name === 'bind' && p.exp) {\r\n const expType = getConstantType(p.exp, context);\r\n if (expType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (expType < returnType) {\r\n returnType = expType;\r\n }\r\n }\r\n }\r\n }\r\n // only svg/foreignObject could be block here, however if they are\r\n // static then they don't need to be blocks since there will be no\r\n // nested updates.\r\n if (codegenNode.isBlock) {\r\n context.removeHelper(OPEN_BLOCK);\r\n context.removeHelper(getVNodeBlockHelper(context.inSSR, codegenNode.isComponent));\r\n codegenNode.isBlock = false;\r\n context.helper(getVNodeHelper(context.inSSR, codegenNode.isComponent));\r\n }\r\n constantCache.set(node, returnType);\r\n return returnType;\r\n }\r\n else {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n case 2 /* TEXT */:\r\n case 3 /* COMMENT */:\r\n return 3 /* CAN_STRINGIFY */;\r\n case 9 /* IF */:\r\n case 11 /* FOR */:\r\n case 10 /* IF_BRANCH */:\r\n return 0 /* NOT_CONSTANT */;\r\n case 5 /* INTERPOLATION */:\r\n case 12 /* TEXT_CALL */:\r\n return getConstantType(node.content, context);\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n return node.constType;\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (isString(child) || isSymbol(child)) {\r\n continue;\r\n }\r\n const childType = getConstantType(child, context);\r\n if (childType === 0 /* NOT_CONSTANT */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n else if (childType < returnType) {\r\n returnType = childType;\r\n }\r\n }\r\n return returnType;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) ;\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n}\r\nconst allowHoistedHelperSet = new Set([\r\n NORMALIZE_CLASS,\r\n NORMALIZE_STYLE,\r\n NORMALIZE_PROPS,\r\n GUARD_REACTIVE_PROPS\r\n]);\r\nfunction getConstantTypeOfHelperCall(value, context) {\r\n if (value.type === 14 /* JS_CALL_EXPRESSION */ &&\r\n !isString(value.callee) &&\r\n allowHoistedHelperSet.has(value.callee)) {\r\n const arg = value.arguments[0];\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n return getConstantType(arg, context);\r\n }\r\n else if (arg.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(exp))`\r\n return getConstantTypeOfHelperCall(arg, context);\r\n }\r\n }\r\n return 0 /* NOT_CONSTANT */;\r\n}\r\nfunction getGeneratedPropsConstantType(node, context) {\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n const props = getNodeProps(node);\r\n if (props && props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n const { properties } = props;\r\n for (let i = 0; i < properties.length; i++) {\r\n const { key, value } = properties[i];\r\n const keyType = getConstantType(key, context);\r\n if (keyType === 0 /* NOT_CONSTANT */) {\r\n return keyType;\r\n }\r\n if (keyType < returnType) {\r\n returnType = keyType;\r\n }\r\n let valueType;\r\n if (value.type === 4 /* SIMPLE_EXPRESSION */) {\r\n valueType = getConstantType(value, context);\r\n }\r\n else if (value.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // some helper calls can be hoisted,\r\n // such as the `normalizeProps` generated by the compiler for pre-normalize class,\r\n // in this case we need to respect the ConstantType of the helper's arguments\r\n valueType = getConstantTypeOfHelperCall(value, context);\r\n }\r\n else {\r\n valueType = 0 /* NOT_CONSTANT */;\r\n }\r\n if (valueType === 0 /* NOT_CONSTANT */) {\r\n return valueType;\r\n }\r\n if (valueType < returnType) {\r\n returnType = valueType;\r\n }\r\n }\r\n }\r\n return returnType;\r\n}\r\nfunction getNodeProps(node) {\r\n const codegenNode = node.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n return codegenNode.props;\r\n }\r\n}\r\nfunction getPatchFlag(node) {\r\n const flag = node.patchFlag;\r\n return flag ? parseInt(flag, 10) : undefined;\r\n}\n\nfunction createTransformContext(root, { filename = '', prefixIdentifiers = false, hoistStatic = false, cacheHandlers = false, nodeTransforms = [], directiveTransforms = {}, transformHoist = null, isBuiltInComponent = NOOP, isCustomElement = NOOP, expressionPlugins = [], scopeId = null, slotted = true, ssr = false, inSSR = false, ssrCssVars = ``, bindingMetadata = EMPTY_OBJ, inline = false, isTS = false, onError = defaultOnError, onWarn = defaultOnWarn, compatConfig }) {\r\n const nameMatch = filename.replace(/\\?.*$/, '').match(/([^/\\\\]+)\\.\\w+$/);\r\n const context = {\r\n // options\r\n selfName: nameMatch && capitalize(camelize$1(nameMatch[1])),\r\n prefixIdentifiers,\r\n hoistStatic,\r\n cacheHandlers,\r\n nodeTransforms,\r\n directiveTransforms,\r\n transformHoist,\r\n isBuiltInComponent,\r\n isCustomElement,\r\n expressionPlugins,\r\n scopeId,\r\n slotted,\r\n ssr,\r\n inSSR,\r\n ssrCssVars,\r\n bindingMetadata,\r\n inline,\r\n isTS,\r\n onError,\r\n onWarn,\r\n compatConfig,\r\n // state\r\n root,\r\n helpers: new Map(),\r\n components: new Set(),\r\n directives: new Set(),\r\n hoists: [],\r\n imports: [],\r\n constantCache: new Map(),\r\n temps: 0,\r\n cached: 0,\r\n identifiers: Object.create(null),\r\n scopes: {\r\n vFor: 0,\r\n vSlot: 0,\r\n vPre: 0,\r\n vOnce: 0\r\n },\r\n parent: null,\r\n currentNode: root,\r\n childIndex: 0,\r\n inVOnce: false,\r\n // methods\r\n helper(name) {\r\n const count = context.helpers.get(name) || 0;\r\n context.helpers.set(name, count + 1);\r\n return name;\r\n },\r\n removeHelper(name) {\r\n const count = context.helpers.get(name);\r\n if (count) {\r\n const currentCount = count - 1;\r\n if (!currentCount) {\r\n context.helpers.delete(name);\r\n }\r\n else {\r\n context.helpers.set(name, currentCount);\r\n }\r\n }\r\n },\r\n helperString(name) {\r\n return `_${helperNameMap[context.helper(name)]}`;\r\n },\r\n replaceNode(node) {\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!context.currentNode) {\r\n throw new Error(`Node being replaced is already removed.`);\r\n }\r\n if (!context.parent) {\r\n throw new Error(`Cannot replace root node.`);\r\n }\r\n }\r\n context.parent.children[context.childIndex] = context.currentNode = node;\r\n },\r\n removeNode(node) {\r\n if ((process.env.NODE_ENV !== 'production') && !context.parent) {\r\n throw new Error(`Cannot remove root node.`);\r\n }\r\n const list = context.parent.children;\r\n const removalIndex = node\r\n ? list.indexOf(node)\r\n : context.currentNode\r\n ? context.childIndex\r\n : -1;\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production') && removalIndex < 0) {\r\n throw new Error(`node being removed is not a child of current parent`);\r\n }\r\n if (!node || node === context.currentNode) {\r\n // current node removed\r\n context.currentNode = null;\r\n context.onNodeRemoved();\r\n }\r\n else {\r\n // sibling node removed\r\n if (context.childIndex > removalIndex) {\r\n context.childIndex--;\r\n context.onNodeRemoved();\r\n }\r\n }\r\n context.parent.children.splice(removalIndex, 1);\r\n },\r\n onNodeRemoved: () => { },\r\n addIdentifiers(exp) {\r\n },\r\n removeIdentifiers(exp) {\r\n },\r\n hoist(exp) {\r\n if (isString(exp))\r\n exp = createSimpleExpression(exp);\r\n context.hoists.push(exp);\r\n const identifier = createSimpleExpression(`_hoisted_${context.hoists.length}`, false, exp.loc, 2 /* CAN_HOIST */);\r\n identifier.hoisted = exp;\r\n return identifier;\r\n },\r\n cache(exp, isVNode = false) {\r\n return createCacheExpression(context.cached++, exp, isVNode);\r\n }\r\n };\r\n {\r\n context.filters = new Set();\r\n }\r\n return context;\r\n}\r\nfunction transform(root, options) {\r\n const context = createTransformContext(root, options);\r\n traverseNode(root, context);\r\n if (options.hoistStatic) {\r\n hoistStatic(root, context);\r\n }\r\n if (!options.ssr) {\r\n createRootCodegen(root, context);\r\n }\r\n // finalize meta information\r\n root.helpers = [...context.helpers.keys()];\r\n root.components = [...context.components];\r\n root.directives = [...context.directives];\r\n root.imports = context.imports;\r\n root.hoists = context.hoists;\r\n root.temps = context.temps;\r\n root.cached = context.cached;\r\n {\r\n root.filters = [...context.filters];\r\n }\r\n}\r\nfunction createRootCodegen(root, context) {\r\n const { helper } = context;\r\n const { children } = root;\r\n if (children.length === 1) {\r\n const child = children[0];\r\n // if the single child is an element, turn it into a block.\r\n if (isSingleElementRoot(root, child) && child.codegenNode) {\r\n // single element root is never hoisted so codegenNode will never be\r\n // SimpleExpressionNode\r\n const codegenNode = child.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n makeBlock(codegenNode, context);\r\n }\r\n root.codegenNode = codegenNode;\r\n }\r\n else {\r\n // - single <slot/>, IfNode, ForNode: already blocks.\r\n // - single text node: always patched.\r\n // root codegen falls through via genNode()\r\n root.codegenNode = child;\r\n }\r\n }\r\n else if (children.length > 1) {\r\n // root has multiple nodes - return a fragment block.\r\n let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n // check if the fragment actually contains a single valid child with\r\n // the rest being comments\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n }\r\n root.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, root.children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n }\r\n else ;\r\n}\r\nfunction traverseChildren(parent, context) {\r\n let i = 0;\r\n const nodeRemoved = () => {\r\n i--;\r\n };\r\n for (; i < parent.children.length; i++) {\r\n const child = parent.children[i];\r\n if (isString(child))\r\n continue;\r\n context.parent = parent;\r\n context.childIndex = i;\r\n context.onNodeRemoved = nodeRemoved;\r\n traverseNode(child, context);\r\n }\r\n}\r\nfunction traverseNode(node, context) {\r\n context.currentNode = node;\r\n // apply transform plugins\r\n const { nodeTransforms } = context;\r\n const exitFns = [];\r\n for (let i = 0; i < nodeTransforms.length; i++) {\r\n const onExit = nodeTransforms[i](node, context);\r\n if (onExit) {\r\n if (isArray(onExit)) {\r\n exitFns.push(...onExit);\r\n }\r\n else {\r\n exitFns.push(onExit);\r\n }\r\n }\r\n if (!context.currentNode) {\r\n // node was removed\r\n return;\r\n }\r\n else {\r\n // node may have been replaced\r\n node = context.currentNode;\r\n }\r\n }\r\n switch (node.type) {\r\n case 3 /* COMMENT */:\r\n if (!context.ssr) {\r\n // inject import for the Comment symbol, which is needed for creating\r\n // comment nodes with `createVNode`\r\n context.helper(CREATE_COMMENT);\r\n }\r\n break;\r\n case 5 /* INTERPOLATION */:\r\n // no need to traverse, but we need to inject toString helper\r\n if (!context.ssr) {\r\n context.helper(TO_DISPLAY_STRING);\r\n }\r\n break;\r\n // for container types, further traverse downwards\r\n case 9 /* IF */:\r\n for (let i = 0; i < node.branches.length; i++) {\r\n traverseNode(node.branches[i], context);\r\n }\r\n break;\r\n case 10 /* IF_BRANCH */:\r\n case 11 /* FOR */:\r\n case 1 /* ELEMENT */:\r\n case 0 /* ROOT */:\r\n traverseChildren(node, context);\r\n break;\r\n }\r\n // exit transforms\r\n context.currentNode = node;\r\n let i = exitFns.length;\r\n while (i--) {\r\n exitFns[i]();\r\n }\r\n}\r\nfunction createStructuralDirectiveTransform(name, fn) {\r\n const matches = isString(name)\r\n ? (n) => n === name\r\n : (n) => name.test(n);\r\n return (node, context) => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n const { props } = node;\r\n // structural directive transforms are not concerned with slots\r\n // as they are handled separately in vSlot.ts\r\n if (node.tagType === 3 /* TEMPLATE */ && props.some(isVSlot)) {\r\n return;\r\n }\r\n const exitFns = [];\r\n for (let i = 0; i < props.length; i++) {\r\n const prop = props[i];\r\n if (prop.type === 7 /* DIRECTIVE */ && matches(prop.name)) {\r\n // structural directives are removed to avoid infinite recursion\r\n // also we remove them *before* applying so that it can further\r\n // traverse itself in case it moves the node around\r\n props.splice(i, 1);\r\n i--;\r\n const onExit = fn(node, prop, context);\r\n if (onExit)\r\n exitFns.push(onExit);\r\n }\r\n }\r\n return exitFns;\r\n }\r\n };\r\n}\n\nconst PURE_ANNOTATION = `/*#__PURE__*/`;\r\nfunction createCodegenContext(ast, { mode = 'function', prefixIdentifiers = mode === 'module', sourceMap = false, filename = `template.vue.html`, scopeId = null, optimizeImports = false, runtimeGlobalName = `Vue`, runtimeModuleName = `vue`, ssrRuntimeModuleName = 'vue/server-renderer', ssr = false, isTS = false, inSSR = false }) {\r\n const context = {\r\n mode,\r\n prefixIdentifiers,\r\n sourceMap,\r\n filename,\r\n scopeId,\r\n optimizeImports,\r\n runtimeGlobalName,\r\n runtimeModuleName,\r\n ssrRuntimeModuleName,\r\n ssr,\r\n isTS,\r\n inSSR,\r\n source: ast.loc.source,\r\n code: ``,\r\n column: 1,\r\n line: 1,\r\n offset: 0,\r\n indentLevel: 0,\r\n pure: false,\r\n map: undefined,\r\n helper(key) {\r\n return `_${helperNameMap[key]}`;\r\n },\r\n push(code, node) {\r\n context.code += code;\r\n },\r\n indent() {\r\n newline(++context.indentLevel);\r\n },\r\n deindent(withoutNewLine = false) {\r\n if (withoutNewLine) {\r\n --context.indentLevel;\r\n }\r\n else {\r\n newline(--context.indentLevel);\r\n }\r\n },\r\n newline() {\r\n newline(context.indentLevel);\r\n }\r\n };\r\n function newline(n) {\r\n context.push('\\n' + ` `.repeat(n));\r\n }\r\n return context;\r\n}\r\nfunction generate(ast, options = {}) {\r\n const context = createCodegenContext(ast, options);\r\n if (options.onContextCreated)\r\n options.onContextCreated(context);\r\n const { mode, push, prefixIdentifiers, indent, deindent, newline, scopeId, ssr } = context;\r\n const hasHelpers = ast.helpers.length > 0;\r\n const useWithBlock = !prefixIdentifiers && mode !== 'module';\r\n // preambles\r\n // in setup() inline mode, the preamble is generated in a sub context\r\n // and returned separately.\r\n const preambleContext = context;\r\n {\r\n genFunctionPreamble(ast, preambleContext);\r\n }\r\n // enter render function\r\n const functionName = ssr ? `ssrRender` : `render`;\r\n const args = ssr ? ['_ctx', '_push', '_parent', '_attrs'] : ['_ctx', '_cache'];\r\n const signature = args.join(', ');\r\n {\r\n push(`function ${functionName}(${signature}) {`);\r\n }\r\n indent();\r\n if (useWithBlock) {\r\n push(`with (_ctx) {`);\r\n indent();\r\n // function mode const declarations should be inside with block\r\n // also they should be renamed to avoid collision with user properties\r\n if (hasHelpers) {\r\n push(`const { ${ast.helpers\r\n .map(s => `${helperNameMap[s]}: _${helperNameMap[s]}`)\r\n .join(', ')} } = _Vue`);\r\n push(`\\n`);\r\n newline();\r\n }\r\n }\r\n // generate asset resolution statements\r\n if (ast.components.length) {\r\n genAssets(ast.components, 'component', context);\r\n if (ast.directives.length || ast.temps > 0) {\r\n newline();\r\n }\r\n }\r\n if (ast.directives.length) {\r\n genAssets(ast.directives, 'directive', context);\r\n if (ast.temps > 0) {\r\n newline();\r\n }\r\n }\r\n if (ast.filters && ast.filters.length) {\r\n newline();\r\n genAssets(ast.filters, 'filter', context);\r\n newline();\r\n }\r\n if (ast.temps > 0) {\r\n push(`let `);\r\n for (let i = 0; i < ast.temps; i++) {\r\n push(`${i > 0 ? `, ` : ``}_temp${i}`);\r\n }\r\n }\r\n if (ast.components.length || ast.directives.length || ast.temps) {\r\n push(`\\n`);\r\n newline();\r\n }\r\n // generate the VNode tree expression\r\n if (!ssr) {\r\n push(`return `);\r\n }\r\n if (ast.codegenNode) {\r\n genNode(ast.codegenNode, context);\r\n }\r\n else {\r\n push(`null`);\r\n }\r\n if (useWithBlock) {\r\n deindent();\r\n push(`}`);\r\n }\r\n deindent();\r\n push(`}`);\r\n return {\r\n ast,\r\n code: context.code,\r\n preamble: ``,\r\n // SourceMapGenerator does have toJSON() method but it's not in the types\r\n map: context.map ? context.map.toJSON() : undefined\r\n };\r\n}\r\nfunction genFunctionPreamble(ast, context) {\r\n const { ssr, prefixIdentifiers, push, newline, runtimeModuleName, runtimeGlobalName, ssrRuntimeModuleName } = context;\r\n const VueBinding = runtimeGlobalName;\r\n const aliasHelper = (s) => `${helperNameMap[s]}: _${helperNameMap[s]}`;\r\n // Generate const declaration for helpers\r\n // In prefix mode, we place the const declaration at top so it's done\r\n // only once; But if we not prefixing, we place the declaration inside the\r\n // with block so it doesn't incur the `in` check cost for every helper access.\r\n if (ast.helpers.length > 0) {\r\n {\r\n // \"with\" mode.\r\n // save Vue in a separate variable to avoid collision\r\n push(`const _Vue = ${VueBinding}\\n`);\r\n // in \"with\" mode, helpers are declared inside the with block to avoid\r\n // has check cost, but hoists are lifted out of the function - we need\r\n // to provide the helper here.\r\n if (ast.hoists.length) {\r\n const staticHelpers = [\r\n CREATE_VNODE,\r\n CREATE_ELEMENT_VNODE,\r\n CREATE_COMMENT,\r\n CREATE_TEXT,\r\n CREATE_STATIC\r\n ]\r\n .filter(helper => ast.helpers.includes(helper))\r\n .map(aliasHelper)\r\n .join(', ');\r\n push(`const { ${staticHelpers} } = _Vue\\n`);\r\n }\r\n }\r\n }\r\n genHoists(ast.hoists, context);\r\n newline();\r\n push(`return `);\r\n}\r\nfunction genAssets(assets, type, { helper, push, newline, isTS }) {\r\n const resolver = helper(type === 'filter'\r\n ? RESOLVE_FILTER\r\n : type === 'component'\r\n ? RESOLVE_COMPONENT\r\n : RESOLVE_DIRECTIVE);\r\n for (let i = 0; i < assets.length; i++) {\r\n let id = assets[i];\r\n // potential component implicit self-reference inferred from SFC filename\r\n const maybeSelfReference = id.endsWith('__self');\r\n if (maybeSelfReference) {\r\n id = id.slice(0, -6);\r\n }\r\n push(`const ${toValidAssetId(id, type)} = ${resolver}(${JSON.stringify(id)}${maybeSelfReference ? `, true` : ``})${isTS ? `!` : ``}`);\r\n if (i < assets.length - 1) {\r\n newline();\r\n }\r\n }\r\n}\r\nfunction genHoists(hoists, context) {\r\n if (!hoists.length) {\r\n return;\r\n }\r\n context.pure = true;\r\n const { push, newline, helper, scopeId, mode } = context;\r\n newline();\r\n for (let i = 0; i < hoists.length; i++) {\r\n const exp = hoists[i];\r\n if (exp) {\r\n push(`const _hoisted_${i + 1} = ${``}`);\r\n genNode(exp, context);\r\n newline();\r\n }\r\n }\r\n context.pure = false;\r\n}\r\nfunction isText$1(n) {\r\n return (isString(n) ||\r\n n.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n n.type === 2 /* TEXT */ ||\r\n n.type === 5 /* INTERPOLATION */ ||\r\n n.type === 8 /* COMPOUND_EXPRESSION */);\r\n}\r\nfunction genNodeListAsArray(nodes, context) {\r\n const multilines = nodes.length > 3 ||\r\n (((process.env.NODE_ENV !== 'production')) && nodes.some(n => isArray(n) || !isText$1(n)));\r\n context.push(`[`);\r\n multilines && context.indent();\r\n genNodeList(nodes, context, multilines);\r\n multilines && context.deindent();\r\n context.push(`]`);\r\n}\r\nfunction genNodeList(nodes, context, multilines = false, comma = true) {\r\n const { push, newline } = context;\r\n for (let i = 0; i < nodes.length; i++) {\r\n const node = nodes[i];\r\n if (isString(node)) {\r\n push(node);\r\n }\r\n else if (isArray(node)) {\r\n genNodeListAsArray(node, context);\r\n }\r\n else {\r\n genNode(node, context);\r\n }\r\n if (i < nodes.length - 1) {\r\n if (multilines) {\r\n comma && push(',');\r\n newline();\r\n }\r\n else {\r\n comma && push(', ');\r\n }\r\n }\r\n }\r\n}\r\nfunction genNode(node, context) {\r\n if (isString(node)) {\r\n context.push(node);\r\n return;\r\n }\r\n if (isSymbol(node)) {\r\n context.push(context.helper(node));\r\n return;\r\n }\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n case 9 /* IF */:\r\n case 11 /* FOR */:\r\n (process.env.NODE_ENV !== 'production') &&\r\n assert(node.codegenNode != null, `Codegen node is missing for element/if/for node. ` +\r\n `Apply appropriate transforms first.`);\r\n genNode(node.codegenNode, context);\r\n break;\r\n case 2 /* TEXT */:\r\n genText(node, context);\r\n break;\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n genExpression(node, context);\r\n break;\r\n case 5 /* INTERPOLATION */:\r\n genInterpolation(node, context);\r\n break;\r\n case 12 /* TEXT_CALL */:\r\n genNode(node.codegenNode, context);\r\n break;\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n genCompoundExpression(node, context);\r\n break;\r\n case 3 /* COMMENT */:\r\n genComment(node, context);\r\n break;\r\n case 13 /* VNODE_CALL */:\r\n genVNodeCall(node, context);\r\n break;\r\n case 14 /* JS_CALL_EXPRESSION */:\r\n genCallExpression(node, context);\r\n break;\r\n case 15 /* JS_OBJECT_EXPRESSION */:\r\n genObjectExpression(node, context);\r\n break;\r\n case 17 /* JS_ARRAY_EXPRESSION */:\r\n genArrayExpression(node, context);\r\n break;\r\n case 18 /* JS_FUNCTION_EXPRESSION */:\r\n genFunctionExpression(node, context);\r\n break;\r\n case 19 /* JS_CONDITIONAL_EXPRESSION */:\r\n genConditionalExpression(node, context);\r\n break;\r\n case 20 /* JS_CACHE_EXPRESSION */:\r\n genCacheExpression(node, context);\r\n break;\r\n case 21 /* JS_BLOCK_STATEMENT */:\r\n genNodeList(node.body, context, true, false);\r\n break;\r\n // SSR only types\r\n case 22 /* JS_TEMPLATE_LITERAL */:\r\n break;\r\n case 23 /* JS_IF_STATEMENT */:\r\n break;\r\n case 24 /* JS_ASSIGNMENT_EXPRESSION */:\r\n break;\r\n case 25 /* JS_SEQUENCE_EXPRESSION */:\r\n break;\r\n case 26 /* JS_RETURN_STATEMENT */:\r\n break;\r\n /* istanbul ignore next */\r\n case 10 /* IF_BRANCH */:\r\n // noop\r\n break;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n assert(false, `unhandled codegen node type: ${node.type}`);\r\n // make sure we exhaust all possible types\r\n const exhaustiveCheck = node;\r\n return exhaustiveCheck;\r\n }\r\n }\r\n}\r\nfunction genText(node, context) {\r\n context.push(JSON.stringify(node.content), node);\r\n}\r\nfunction genExpression(node, context) {\r\n const { content, isStatic } = node;\r\n context.push(isStatic ? JSON.stringify(content) : content, node);\r\n}\r\nfunction genInterpolation(node, context) {\r\n const { push, helper, pure } = context;\r\n if (pure)\r\n push(PURE_ANNOTATION);\r\n push(`${helper(TO_DISPLAY_STRING)}(`);\r\n genNode(node.content, context);\r\n push(`)`);\r\n}\r\nfunction genCompoundExpression(node, context) {\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (isString(child)) {\r\n context.push(child);\r\n }\r\n else {\r\n genNode(child, context);\r\n }\r\n }\r\n}\r\nfunction genExpressionAsPropertyKey(node, context) {\r\n const { push } = context;\r\n if (node.type === 8 /* COMPOUND_EXPRESSION */) {\r\n push(`[`);\r\n genCompoundExpression(node, context);\r\n push(`]`);\r\n }\r\n else if (node.isStatic) {\r\n // only quote keys if necessary\r\n const text = isSimpleIdentifier(node.content)\r\n ? node.content\r\n : JSON.stringify(node.content);\r\n push(text, node);\r\n }\r\n else {\r\n push(`[${node.content}]`, node);\r\n }\r\n}\r\nfunction genComment(node, context) {\r\n const { push, helper, pure } = context;\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n push(`${helper(CREATE_COMMENT)}(${JSON.stringify(node.content)})`, node);\r\n}\r\nfunction genVNodeCall(node, context) {\r\n const { push, helper, pure } = context;\r\n const { tag, props, children, patchFlag, dynamicProps, directives, isBlock, disableTracking, isComponent } = node;\r\n if (directives) {\r\n push(helper(WITH_DIRECTIVES) + `(`);\r\n }\r\n if (isBlock) {\r\n push(`(${helper(OPEN_BLOCK)}(${disableTracking ? `true` : ``}), `);\r\n }\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n const callHelper = isBlock\r\n ? getVNodeBlockHelper(context.inSSR, isComponent)\r\n : getVNodeHelper(context.inSSR, isComponent);\r\n push(helper(callHelper) + `(`, node);\r\n genNodeList(genNullableArgs([tag, props, children, patchFlag, dynamicProps]), context);\r\n push(`)`);\r\n if (isBlock) {\r\n push(`)`);\r\n }\r\n if (directives) {\r\n push(`, `);\r\n genNode(directives, context);\r\n push(`)`);\r\n }\r\n}\r\nfunction genNullableArgs(args) {\r\n let i = args.length;\r\n while (i--) {\r\n if (args[i] != null)\r\n break;\r\n }\r\n return args.slice(0, i + 1).map(arg => arg || `null`);\r\n}\r\n// JavaScript\r\nfunction genCallExpression(node, context) {\r\n const { push, helper, pure } = context;\r\n const callee = isString(node.callee) ? node.callee : helper(node.callee);\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n push(callee + `(`, node);\r\n genNodeList(node.arguments, context);\r\n push(`)`);\r\n}\r\nfunction genObjectExpression(node, context) {\r\n const { push, indent, deindent, newline } = context;\r\n const { properties } = node;\r\n if (!properties.length) {\r\n push(`{}`, node);\r\n return;\r\n }\r\n const multilines = properties.length > 1 ||\r\n (((process.env.NODE_ENV !== 'production')) &&\r\n properties.some(p => p.value.type !== 4 /* SIMPLE_EXPRESSION */));\r\n push(multilines ? `{` : `{ `);\r\n multilines && indent();\r\n for (let i = 0; i < properties.length; i++) {\r\n const { key, value } = properties[i];\r\n // key\r\n genExpressionAsPropertyKey(key, context);\r\n push(`: `);\r\n // value\r\n genNode(value, context);\r\n if (i < properties.length - 1) {\r\n // will only reach this if it's multilines\r\n push(`,`);\r\n newline();\r\n }\r\n }\r\n multilines && deindent();\r\n push(multilines ? `}` : ` }`);\r\n}\r\nfunction genArrayExpression(node, context) {\r\n genNodeListAsArray(node.elements, context);\r\n}\r\nfunction genFunctionExpression(node, context) {\r\n const { push, indent, deindent } = context;\r\n const { params, returns, body, newline, isSlot } = node;\r\n if (isSlot) {\r\n // wrap slot functions with owner context\r\n push(`_${helperNameMap[WITH_CTX]}(`);\r\n }\r\n push(`(`, node);\r\n if (isArray(params)) {\r\n genNodeList(params, context);\r\n }\r\n else if (params) {\r\n genNode(params, context);\r\n }\r\n push(`) => `);\r\n if (newline || body) {\r\n push(`{`);\r\n indent();\r\n }\r\n if (returns) {\r\n if (newline) {\r\n push(`return `);\r\n }\r\n if (isArray(returns)) {\r\n genNodeListAsArray(returns, context);\r\n }\r\n else {\r\n genNode(returns, context);\r\n }\r\n }\r\n else if (body) {\r\n genNode(body, context);\r\n }\r\n if (newline || body) {\r\n deindent();\r\n push(`}`);\r\n }\r\n if (isSlot) {\r\n if (node.isNonScopedSlot) {\r\n push(`, undefined, true`);\r\n }\r\n push(`)`);\r\n }\r\n}\r\nfunction genConditionalExpression(node, context) {\r\n const { test, consequent, alternate, newline: needNewline } = node;\r\n const { push, indent, deindent, newline } = context;\r\n if (test.type === 4 /* SIMPLE_EXPRESSION */) {\r\n const needsParens = !isSimpleIdentifier(test.content);\r\n needsParens && push(`(`);\r\n genExpression(test, context);\r\n needsParens && push(`)`);\r\n }\r\n else {\r\n push(`(`);\r\n genNode(test, context);\r\n push(`)`);\r\n }\r\n needNewline && indent();\r\n context.indentLevel++;\r\n needNewline || push(` `);\r\n push(`? `);\r\n genNode(consequent, context);\r\n context.indentLevel--;\r\n needNewline && newline();\r\n needNewline || push(` `);\r\n push(`: `);\r\n const isNested = alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */;\r\n if (!isNested) {\r\n context.indentLevel++;\r\n }\r\n genNode(alternate, context);\r\n if (!isNested) {\r\n context.indentLevel--;\r\n }\r\n needNewline && deindent(true /* without newline */);\r\n}\r\nfunction genCacheExpression(node, context) {\r\n const { push, helper, indent, deindent, newline } = context;\r\n push(`_cache[${node.index}] || (`);\r\n if (node.isVNode) {\r\n indent();\r\n push(`${helper(SET_BLOCK_TRACKING)}(-1),`);\r\n newline();\r\n }\r\n push(`_cache[${node.index}] = `);\r\n genNode(node.value, context);\r\n if (node.isVNode) {\r\n push(`,`);\r\n newline();\r\n push(`${helper(SET_BLOCK_TRACKING)}(1),`);\r\n newline();\r\n push(`_cache[${node.index}]`);\r\n deindent();\r\n }\r\n push(`)`);\r\n}\n\nfunction walkIdentifiers(root, onIdentifier, includeAll = false, parentStack = [], knownIds = Object.create(null)) {\r\n {\r\n return;\r\n }\r\n}\r\nfunction isReferencedIdentifier(id, parent, parentStack) {\r\n {\r\n return false;\r\n }\r\n}\r\nfunction isInDestructureAssignment(parent, parentStack) {\r\n if (parent &&\r\n (parent.type === 'ObjectProperty' || parent.type === 'ArrayPattern')) {\r\n let i = parentStack.length;\r\n while (i--) {\r\n const p = parentStack[i];\r\n if (p.type === 'AssignmentExpression') {\r\n return true;\r\n }\r\n else if (p.type !== 'ObjectProperty' && !p.type.endsWith('Pattern')) {\r\n break;\r\n }\r\n }\r\n }\r\n return false;\r\n}\r\nfunction walkFunctionParams(node, onIdent) {\r\n for (const p of node.params) {\r\n for (const id of extractIdentifiers(p)) {\r\n onIdent(id);\r\n }\r\n }\r\n}\r\nfunction walkBlockDeclarations(block, onIdent) {\r\n for (const stmt of block.body) {\r\n if (stmt.type === 'VariableDeclaration') {\r\n if (stmt.declare)\r\n continue;\r\n for (const decl of stmt.declarations) {\r\n for (const id of extractIdentifiers(decl.id)) {\r\n onIdent(id);\r\n }\r\n }\r\n }\r\n else if (stmt.type === 'FunctionDeclaration' ||\r\n stmt.type === 'ClassDeclaration') {\r\n if (stmt.declare || !stmt.id)\r\n continue;\r\n onIdent(stmt.id);\r\n }\r\n }\r\n}\r\nfunction extractIdentifiers(param, nodes = []) {\r\n switch (param.type) {\r\n case 'Identifier':\r\n nodes.push(param);\r\n break;\r\n case 'MemberExpression':\r\n let object = param;\r\n while (object.type === 'MemberExpression') {\r\n object = object.object;\r\n }\r\n nodes.push(object);\r\n break;\r\n case 'ObjectPattern':\r\n for (const prop of param.properties) {\r\n if (prop.type === 'RestElement') {\r\n extractIdentifiers(prop.argument, nodes);\r\n }\r\n else {\r\n extractIdentifiers(prop.value, nodes);\r\n }\r\n }\r\n break;\r\n case 'ArrayPattern':\r\n param.elements.forEach(element => {\r\n if (element)\r\n extractIdentifiers(element, nodes);\r\n });\r\n break;\r\n case 'RestElement':\r\n extractIdentifiers(param.argument, nodes);\r\n break;\r\n case 'AssignmentPattern':\r\n extractIdentifiers(param.left, nodes);\r\n break;\r\n }\r\n return nodes;\r\n}\r\nconst isFunctionType = (node) => {\r\n return /Function(?:Expression|Declaration)$|Method$/.test(node.type);\r\n};\r\nconst isStaticProperty = (node) => node &&\r\n (node.type === 'ObjectProperty' || node.type === 'ObjectMethod') &&\r\n !node.computed;\r\nconst isStaticPropertyKey = (node, parent) => isStaticProperty(parent) && parent.key === node;\n\n// these keywords should not appear inside expressions, but operators like\r\n// typeof, instanceof and in are allowed\r\nconst prohibitedKeywordRE = new RegExp('\\\\b' +\r\n ('do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,' +\r\n 'super,throw,while,yield,delete,export,import,return,switch,default,' +\r\n 'extends,finally,continue,debugger,function,arguments,typeof,void')\r\n .split(',')\r\n .join('\\\\b|\\\\b') +\r\n '\\\\b');\r\n// strip strings in expressions\r\nconst stripStringRE = /'(?:[^'\\\\]|\\\\.)*'|\"(?:[^\"\\\\]|\\\\.)*\"|`(?:[^`\\\\]|\\\\.)*\\$\\{|\\}(?:[^`\\\\]|\\\\.)*`|`(?:[^`\\\\]|\\\\.)*`/g;\r\n/**\r\n * Validate a non-prefixed expression.\r\n * This is only called when using the in-browser runtime compiler since it\r\n * doesn't prefix expressions.\r\n */\r\nfunction validateBrowserExpression(node, context, asParams = false, asRawStatements = false) {\r\n const exp = node.content;\r\n // empty expressions are validated per-directive since some directives\r\n // do allow empty expressions.\r\n if (!exp.trim()) {\r\n return;\r\n }\r\n try {\r\n new Function(asRawStatements\r\n ? ` ${exp} `\r\n : `return ${asParams ? `(${exp}) => {}` : `(${exp})`}`);\r\n }\r\n catch (e) {\r\n let message = e.message;\r\n const keywordMatch = exp\r\n .replace(stripStringRE, '')\r\n .match(prohibitedKeywordRE);\r\n if (keywordMatch) {\r\n message = `avoid using JavaScript keyword as property name: \"${keywordMatch[0]}\"`;\r\n }\r\n context.onError(createCompilerError(44 /* X_INVALID_EXPRESSION */, node.loc, undefined, message));\r\n }\r\n}\n\nconst transformExpression = (node, context) => {\r\n if (node.type === 5 /* INTERPOLATION */) {\r\n node.content = processExpression(node.content, context);\r\n }\r\n else if (node.type === 1 /* ELEMENT */) {\r\n // handle directives on element\r\n for (let i = 0; i < node.props.length; i++) {\r\n const dir = node.props[i];\r\n // do not process for v-on & v-for since they are special handled\r\n if (dir.type === 7 /* DIRECTIVE */ && dir.name !== 'for') {\r\n const exp = dir.exp;\r\n const arg = dir.arg;\r\n // do not process exp if this is v-on:arg - we need special handling\r\n // for wrapping inline statements.\r\n if (exp &&\r\n exp.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n !(dir.name === 'on' && arg)) {\r\n dir.exp = processExpression(exp, context, \r\n // slot args must be processed as function params\r\n dir.name === 'slot');\r\n }\r\n if (arg && arg.type === 4 /* SIMPLE_EXPRESSION */ && !arg.isStatic) {\r\n dir.arg = processExpression(arg, context);\r\n }\r\n }\r\n }\r\n }\r\n};\r\n// Important: since this function uses Node.js only dependencies, it should\r\n// always be used with a leading !true check so that it can be\r\n// tree-shaken from the browser build.\r\nfunction processExpression(node, context, \r\n// some expressions like v-slot props & v-for aliases should be parsed as\r\n// function params\r\nasParams = false, \r\n// v-on handler values may contain multiple statements\r\nasRawStatements = false, localVars = Object.create(context.identifiers)) {\r\n {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n // simple in-browser validation (same logic in 2.x)\r\n validateBrowserExpression(node, context, asParams, asRawStatements);\r\n }\r\n return node;\r\n }\r\n}\n\nconst transformIf = createStructuralDirectiveTransform(/^(if|else|else-if)$/, (node, dir, context) => {\r\n return processIf(node, dir, context, (ifNode, branch, isRoot) => {\r\n // #1587: We need to dynamically increment the key based on the current\r\n // node's sibling nodes, since chained v-if/else branches are\r\n // rendered at the same depth\r\n const siblings = context.parent.children;\r\n let i = siblings.indexOf(ifNode);\r\n let key = 0;\r\n while (i-- >= 0) {\r\n const sibling = siblings[i];\r\n if (sibling && sibling.type === 9 /* IF */) {\r\n key += sibling.branches.length;\r\n }\r\n }\r\n // Exit callback. Complete the codegenNode when all children have been\r\n // transformed.\r\n return () => {\r\n if (isRoot) {\r\n ifNode.codegenNode = createCodegenNodeForBranch(branch, key, context);\r\n }\r\n else {\r\n // attach this branch's codegen node to the v-if root.\r\n const parentCondition = getParentCondition(ifNode.codegenNode);\r\n parentCondition.alternate = createCodegenNodeForBranch(branch, key + ifNode.branches.length - 1, context);\r\n }\r\n };\r\n });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processIf(node, dir, context, processCodegen) {\r\n if (dir.name !== 'else' &&\r\n (!dir.exp || !dir.exp.content.trim())) {\r\n const loc = dir.exp ? dir.exp.loc : node.loc;\r\n context.onError(createCompilerError(28 /* X_V_IF_NO_EXPRESSION */, dir.loc));\r\n dir.exp = createSimpleExpression(`true`, false, loc);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && true && dir.exp) {\r\n validateBrowserExpression(dir.exp, context);\r\n }\r\n if (dir.name === 'if') {\r\n const branch = createIfBranch(node, dir);\r\n const ifNode = {\r\n type: 9 /* IF */,\r\n loc: node.loc,\r\n branches: [branch]\r\n };\r\n context.replaceNode(ifNode);\r\n if (processCodegen) {\r\n return processCodegen(ifNode, branch, true);\r\n }\r\n }\r\n else {\r\n // locate the adjacent v-if\r\n const siblings = context.parent.children;\r\n const comments = [];\r\n let i = siblings.indexOf(node);\r\n while (i-- >= -1) {\r\n const sibling = siblings[i];\r\n if ((process.env.NODE_ENV !== 'production') && sibling && sibling.type === 3 /* COMMENT */) {\r\n context.removeNode(sibling);\r\n comments.unshift(sibling);\r\n continue;\r\n }\r\n if (sibling &&\r\n sibling.type === 2 /* TEXT */ &&\r\n !sibling.content.trim().length) {\r\n context.removeNode(sibling);\r\n continue;\r\n }\r\n if (sibling && sibling.type === 9 /* IF */) {\r\n // Check if v-else was followed by v-else-if\r\n if (dir.name === 'else-if' &&\r\n sibling.branches[sibling.branches.length - 1].condition === undefined) {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n }\r\n // move the node to the if node's branches\r\n context.removeNode();\r\n const branch = createIfBranch(node, dir);\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n comments.length &&\r\n // #3619 ignore comments if the v-if is direct child of <transition>\r\n !(context.parent &&\r\n context.parent.type === 1 /* ELEMENT */ &&\r\n isBuiltInType(context.parent.tag, 'transition'))) {\r\n branch.children = [...comments, ...branch.children];\r\n }\r\n // check if user is forcing same key on different branches\r\n if ((process.env.NODE_ENV !== 'production') || !true) {\r\n const key = branch.userKey;\r\n if (key) {\r\n sibling.branches.forEach(({ userKey }) => {\r\n if (isSameKey(userKey, key)) {\r\n context.onError(createCompilerError(29 /* X_V_IF_SAME_KEY */, branch.userKey.loc));\r\n }\r\n });\r\n }\r\n }\r\n sibling.branches.push(branch);\r\n const onExit = processCodegen && processCodegen(sibling, branch, false);\r\n // since the branch was removed, it will not be traversed.\r\n // make sure to traverse here.\r\n traverseNode(branch, context);\r\n // call on exit\r\n if (onExit)\r\n onExit();\r\n // make sure to reset currentNode after traversal to indicate this\r\n // node has been removed.\r\n context.currentNode = null;\r\n }\r\n else {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n }\r\n break;\r\n }\r\n }\r\n}\r\nfunction createIfBranch(node, dir) {\r\n return {\r\n type: 10 /* IF_BRANCH */,\r\n loc: node.loc,\r\n condition: dir.name === 'else' ? undefined : dir.exp,\r\n children: node.tagType === 3 /* TEMPLATE */ && !findDir(node, 'for')\r\n ? node.children\r\n : [node],\r\n userKey: findProp(node, `key`)\r\n };\r\n}\r\nfunction createCodegenNodeForBranch(branch, keyIndex, context) {\r\n if (branch.condition) {\r\n return createConditionalExpression(branch.condition, createChildrenCodegenNode(branch, keyIndex, context), \r\n // make sure to pass in asBlock: true so that the comment node call\r\n // closes the current block.\r\n createCallExpression(context.helper(CREATE_COMMENT), [\r\n (process.env.NODE_ENV !== 'production') ? '\"v-if\"' : '\"\"',\r\n 'true'\r\n ]));\r\n }\r\n else {\r\n return createChildrenCodegenNode(branch, keyIndex, context);\r\n }\r\n}\r\nfunction createChildrenCodegenNode(branch, keyIndex, context) {\r\n const { helper } = context;\r\n const keyProperty = createObjectProperty(`key`, createSimpleExpression(`${keyIndex}`, false, locStub, 2 /* CAN_HOIST */));\r\n const { children } = branch;\r\n const firstChild = children[0];\r\n const needFragmentWrapper = children.length !== 1 || firstChild.type !== 1 /* ELEMENT */;\r\n if (needFragmentWrapper) {\r\n if (children.length === 1 && firstChild.type === 11 /* FOR */) {\r\n // optimize away nested fragments when child is a ForNode\r\n const vnodeCall = firstChild.codegenNode;\r\n injectProp(vnodeCall, keyProperty, context);\r\n return vnodeCall;\r\n }\r\n else {\r\n let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n // check if the fragment actually contains a single valid child with\r\n // the rest being comments\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n }\r\n return createVNodeCall(context, helper(FRAGMENT), createObjectExpression([keyProperty]), children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, false, false /* isComponent */, branch.loc);\r\n }\r\n }\r\n else {\r\n const ret = firstChild.codegenNode;\r\n const vnodeCall = getMemoedVNodeCall(ret);\r\n // Change createVNode to createBlock.\r\n if (vnodeCall.type === 13 /* VNODE_CALL */) {\r\n makeBlock(vnodeCall, context);\r\n }\r\n // inject branch key\r\n injectProp(vnodeCall, keyProperty, context);\r\n return ret;\r\n }\r\n}\r\nfunction isSameKey(a, b) {\r\n if (!a || a.type !== b.type) {\r\n return false;\r\n }\r\n if (a.type === 6 /* ATTRIBUTE */) {\r\n if (a.value.content !== b.value.content) {\r\n return false;\r\n }\r\n }\r\n else {\r\n // directive\r\n const exp = a.exp;\r\n const branchExp = b.exp;\r\n if (exp.type !== branchExp.type) {\r\n return false;\r\n }\r\n if (exp.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n exp.isStatic !== branchExp.isStatic ||\r\n exp.content !== branchExp.content) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n}\r\nfunction getParentCondition(node) {\r\n while (true) {\r\n if (node.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n if (node.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n node = node.alternate;\r\n }\r\n else {\r\n return node;\r\n }\r\n }\r\n else if (node.type === 20 /* JS_CACHE_EXPRESSION */) {\r\n node = node.value;\r\n }\r\n }\r\n}\n\nconst transformFor = createStructuralDirectiveTransform('for', (node, dir, context) => {\r\n const { helper, removeHelper } = context;\r\n return processFor(node, dir, context, forNode => {\r\n // create the loop render function expression now, and add the\r\n // iterator on exit after all children have been traversed\r\n const renderExp = createCallExpression(helper(RENDER_LIST), [\r\n forNode.source\r\n ]);\r\n const memo = findDir(node, 'memo');\r\n const keyProp = findProp(node, `key`);\r\n const keyExp = keyProp &&\r\n (keyProp.type === 6 /* ATTRIBUTE */\r\n ? createSimpleExpression(keyProp.value.content, true)\r\n : keyProp.exp);\r\n const keyProperty = keyProp ? createObjectProperty(`key`, keyExp) : null;\r\n const isStableFragment = forNode.source.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n forNode.source.constType > 0 /* NOT_CONSTANT */;\r\n const fragmentFlag = isStableFragment\r\n ? 64 /* STABLE_FRAGMENT */\r\n : keyProp\r\n ? 128 /* KEYED_FRAGMENT */\r\n : 256 /* UNKEYED_FRAGMENT */;\r\n forNode.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, renderExp, fragmentFlag +\r\n ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[fragmentFlag]} */` : ``), undefined, undefined, true /* isBlock */, !isStableFragment /* disableTracking */, false /* isComponent */, node.loc);\r\n return () => {\r\n // finish the codegen now that all children have been traversed\r\n let childBlock;\r\n const isTemplate = isTemplateNode(node);\r\n const { children } = forNode;\r\n // check <template v-for> key placement\r\n if (((process.env.NODE_ENV !== 'production') || !true) && isTemplate) {\r\n node.children.some(c => {\r\n if (c.type === 1 /* ELEMENT */) {\r\n const key = findProp(c, 'key');\r\n if (key) {\r\n context.onError(createCompilerError(33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */, key.loc));\r\n return true;\r\n }\r\n }\r\n });\r\n }\r\n const needFragmentWrapper = children.length !== 1 || children[0].type !== 1 /* ELEMENT */;\r\n const slotOutlet = isSlotOutlet(node)\r\n ? node\r\n : isTemplate &&\r\n node.children.length === 1 &&\r\n isSlotOutlet(node.children[0])\r\n ? node.children[0] // api-extractor somehow fails to infer this\r\n : null;\r\n if (slotOutlet) {\r\n // <slot v-for=\"...\"> or <template v-for=\"...\"><slot/></template>\r\n childBlock = slotOutlet.codegenNode;\r\n if (isTemplate && keyProperty) {\r\n // <template v-for=\"...\" :key=\"...\"><slot/></template>\r\n // we need to inject the key to the renderSlot() call.\r\n // the props for renderSlot is passed as the 3rd argument.\r\n injectProp(childBlock, keyProperty, context);\r\n }\r\n }\r\n else if (needFragmentWrapper) {\r\n // <template v-for=\"...\"> with text or multi-elements\r\n // should generate a fragment block for each loop\r\n childBlock = createVNodeCall(context, helper(FRAGMENT), keyProperty ? createObjectExpression([keyProperty]) : undefined, node.children, 64 /* STABLE_FRAGMENT */ +\r\n ((process.env.NODE_ENV !== 'production')\r\n ? ` /* ${PatchFlagNames[64 /* STABLE_FRAGMENT */]} */`\r\n : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n }\r\n else {\r\n // Normal element v-for. Directly use the child's codegenNode\r\n // but mark it as a block.\r\n childBlock = children[0]\r\n .codegenNode;\r\n if (isTemplate && keyProperty) {\r\n injectProp(childBlock, keyProperty, context);\r\n }\r\n if (childBlock.isBlock !== !isStableFragment) {\r\n if (childBlock.isBlock) {\r\n // switch from block to vnode\r\n removeHelper(OPEN_BLOCK);\r\n removeHelper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n else {\r\n // switch from vnode to block\r\n removeHelper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n }\r\n childBlock.isBlock = !isStableFragment;\r\n if (childBlock.isBlock) {\r\n helper(OPEN_BLOCK);\r\n helper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n else {\r\n helper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n }\r\n if (memo) {\r\n const loop = createFunctionExpression(createForLoopParams(forNode.parseResult, [\r\n createSimpleExpression(`_cached`)\r\n ]));\r\n loop.body = createBlockStatement([\r\n createCompoundExpression([`const _memo = (`, memo.exp, `)`]),\r\n createCompoundExpression([\r\n `if (_cached`,\r\n ...(keyExp ? [` && _cached.key === `, keyExp] : []),\r\n ` && ${context.helperString(IS_MEMO_SAME)}(_cached, _memo)) return _cached`\r\n ]),\r\n createCompoundExpression([`const _item = `, childBlock]),\r\n createSimpleExpression(`_item.memo = _memo`),\r\n createSimpleExpression(`return _item`)\r\n ]);\r\n renderExp.arguments.push(loop, createSimpleExpression(`_cache`), createSimpleExpression(String(context.cached++)));\r\n }\r\n else {\r\n renderExp.arguments.push(createFunctionExpression(createForLoopParams(forNode.parseResult), childBlock, true /* force newline */));\r\n }\r\n };\r\n });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processFor(node, dir, context, processCodegen) {\r\n if (!dir.exp) {\r\n context.onError(createCompilerError(31 /* X_V_FOR_NO_EXPRESSION */, dir.loc));\r\n return;\r\n }\r\n const parseResult = parseForExpression(\r\n // can only be simple expression because vFor transform is applied\r\n // before expression transform.\r\n dir.exp, context);\r\n if (!parseResult) {\r\n context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, dir.loc));\r\n return;\r\n }\r\n const { addIdentifiers, removeIdentifiers, scopes } = context;\r\n const { source, value, key, index } = parseResult;\r\n const forNode = {\r\n type: 11 /* FOR */,\r\n loc: dir.loc,\r\n source,\r\n valueAlias: value,\r\n keyAlias: key,\r\n objectIndexAlias: index,\r\n parseResult,\r\n children: isTemplateNode(node) ? node.children : [node]\r\n };\r\n context.replaceNode(forNode);\r\n // bookkeeping\r\n scopes.vFor++;\r\n const onExit = processCodegen && processCodegen(forNode);\r\n return () => {\r\n scopes.vFor--;\r\n if (onExit)\r\n onExit();\r\n };\r\n}\r\nconst forAliasRE = /([\\s\\S]*?)\\s+(?:in|of)\\s+([\\s\\S]*)/;\r\n// This regex doesn't cover the case if key or index aliases have destructuring,\r\n// but those do not make sense in the first place, so this works in practice.\r\nconst forIteratorRE = /,([^,\\}\\]]*)(?:,([^,\\}\\]]*))?$/;\r\nconst stripParensRE = /^\\(|\\)$/g;\r\nfunction parseForExpression(input, context) {\r\n const loc = input.loc;\r\n const exp = input.content;\r\n const inMatch = exp.match(forAliasRE);\r\n if (!inMatch)\r\n return;\r\n const [, LHS, RHS] = inMatch;\r\n const result = {\r\n source: createAliasExpression(loc, RHS.trim(), exp.indexOf(RHS, LHS.length)),\r\n value: undefined,\r\n key: undefined,\r\n index: undefined\r\n };\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.source, context);\r\n }\r\n let valueContent = LHS.trim().replace(stripParensRE, '').trim();\r\n const trimmedOffset = LHS.indexOf(valueContent);\r\n const iteratorMatch = valueContent.match(forIteratorRE);\r\n if (iteratorMatch) {\r\n valueContent = valueContent.replace(forIteratorRE, '').trim();\r\n const keyContent = iteratorMatch[1].trim();\r\n let keyOffset;\r\n if (keyContent) {\r\n keyOffset = exp.indexOf(keyContent, trimmedOffset + valueContent.length);\r\n result.key = createAliasExpression(loc, keyContent, keyOffset);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.key, context, true);\r\n }\r\n }\r\n if (iteratorMatch[2]) {\r\n const indexContent = iteratorMatch[2].trim();\r\n if (indexContent) {\r\n result.index = createAliasExpression(loc, indexContent, exp.indexOf(indexContent, result.key\r\n ? keyOffset + keyContent.length\r\n : trimmedOffset + valueContent.length));\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.index, context, true);\r\n }\r\n }\r\n }\r\n }\r\n if (valueContent) {\r\n result.value = createAliasExpression(loc, valueContent, trimmedOffset);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.value, context, true);\r\n }\r\n }\r\n return result;\r\n}\r\nfunction createAliasExpression(range, content, offset) {\r\n return createSimpleExpression(content, false, getInnerRange(range, offset, content.length));\r\n}\r\nfunction createForLoopParams({ value, key, index }, memoArgs = []) {\r\n return createParamsList([value, key, index, ...memoArgs]);\r\n}\r\nfunction createParamsList(args) {\r\n let i = args.length;\r\n while (i--) {\r\n if (args[i])\r\n break;\r\n }\r\n return args\r\n .slice(0, i + 1)\r\n .map((arg, i) => arg || createSimpleExpression(`_`.repeat(i + 1), false));\r\n}\n\nconst defaultFallback = createSimpleExpression(`undefined`, false);\r\n// A NodeTransform that:\r\n// 1. Tracks scope identifiers for scoped slots so that they don't get prefixed\r\n// by transformExpression. This is only applied in non-browser builds with\r\n// { prefixIdentifiers: true }.\r\n// 2. Track v-slot depths so that we know a slot is inside another slot.\r\n// Note the exit callback is executed before buildSlots() on the same node,\r\n// so only nested slots see positive numbers.\r\nconst trackSlotScopes = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n (node.tagType === 1 /* COMPONENT */ ||\r\n node.tagType === 3 /* TEMPLATE */)) {\r\n // We are only checking non-empty v-slot here\r\n // since we only care about slots that introduce scope variables.\r\n const vSlot = findDir(node, 'slot');\r\n if (vSlot) {\r\n vSlot.exp;\r\n context.scopes.vSlot++;\r\n return () => {\r\n context.scopes.vSlot--;\r\n };\r\n }\r\n }\r\n};\r\n// A NodeTransform that tracks scope identifiers for scoped slots with v-for.\r\n// This transform is only applied in non-browser builds with { prefixIdentifiers: true }\r\nconst trackVForSlotScopes = (node, context) => {\r\n let vFor;\r\n if (isTemplateNode(node) &&\r\n node.props.some(isVSlot) &&\r\n (vFor = findDir(node, 'for'))) {\r\n const result = (vFor.parseResult = parseForExpression(vFor.exp, context));\r\n if (result) {\r\n const { value, key, index } = result;\r\n const { addIdentifiers, removeIdentifiers } = context;\r\n value && addIdentifiers(value);\r\n key && addIdentifiers(key);\r\n index && addIdentifiers(index);\r\n return () => {\r\n value && removeIdentifiers(value);\r\n key && removeIdentifiers(key);\r\n index && removeIdentifiers(index);\r\n };\r\n }\r\n }\r\n};\r\nconst buildClientSlotFn = (props, children, loc) => createFunctionExpression(props, children, false /* newline */, true /* isSlot */, children.length ? children[0].loc : loc);\r\n// Instead of being a DirectiveTransform, v-slot processing is called during\r\n// transformElement to build the slots object for a component.\r\nfunction buildSlots(node, context, buildSlotFn = buildClientSlotFn) {\r\n context.helper(WITH_CTX);\r\n const { children, loc } = node;\r\n const slotsProperties = [];\r\n const dynamicSlots = [];\r\n // If the slot is inside a v-for or another v-slot, force it to be dynamic\r\n // since it likely uses a scope variable.\r\n let hasDynamicSlots = context.scopes.vSlot > 0 || context.scopes.vFor > 0;\r\n // 1. Check for slot with slotProps on component itself.\r\n // <Comp v-slot=\"{ prop }\"/>\r\n const onComponentSlot = findDir(node, 'slot', true);\r\n if (onComponentSlot) {\r\n const { arg, exp } = onComponentSlot;\r\n if (arg && !isStaticExp(arg)) {\r\n hasDynamicSlots = true;\r\n }\r\n slotsProperties.push(createObjectProperty(arg || createSimpleExpression('default', true), buildSlotFn(exp, children, loc)));\r\n }\r\n // 2. Iterate through children and check for template slots\r\n // <template v-slot:foo=\"{ prop }\">\r\n let hasTemplateSlots = false;\r\n let hasNamedDefaultSlot = false;\r\n const implicitDefaultChildren = [];\r\n const seenSlotNames = new Set();\r\n for (let i = 0; i < children.length; i++) {\r\n const slotElement = children[i];\r\n let slotDir;\r\n if (!isTemplateNode(slotElement) ||\r\n !(slotDir = findDir(slotElement, 'slot', true))) {\r\n // not a <template v-slot>, skip.\r\n if (slotElement.type !== 3 /* COMMENT */) {\r\n implicitDefaultChildren.push(slotElement);\r\n }\r\n continue;\r\n }\r\n if (onComponentSlot) {\r\n // already has on-component slot - this is incorrect usage.\r\n context.onError(createCompilerError(37 /* X_V_SLOT_MIXED_SLOT_USAGE */, slotDir.loc));\r\n break;\r\n }\r\n hasTemplateSlots = true;\r\n const { children: slotChildren, loc: slotLoc } = slotElement;\r\n const { arg: slotName = createSimpleExpression(`default`, true), exp: slotProps, loc: dirLoc } = slotDir;\r\n // check if name is dynamic.\r\n let staticSlotName;\r\n if (isStaticExp(slotName)) {\r\n staticSlotName = slotName ? slotName.content : `default`;\r\n }\r\n else {\r\n hasDynamicSlots = true;\r\n }\r\n const slotFunction = buildSlotFn(slotProps, slotChildren, slotLoc);\r\n // check if this slot is conditional (v-if/v-for)\r\n let vIf;\r\n let vElse;\r\n let vFor;\r\n if ((vIf = findDir(slotElement, 'if'))) {\r\n hasDynamicSlots = true;\r\n dynamicSlots.push(createConditionalExpression(vIf.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback));\r\n }\r\n else if ((vElse = findDir(slotElement, /^else(-if)?$/, true /* allowEmpty */))) {\r\n // find adjacent v-if\r\n let j = i;\r\n let prev;\r\n while (j--) {\r\n prev = children[j];\r\n if (prev.type !== 3 /* COMMENT */) {\r\n break;\r\n }\r\n }\r\n if (prev && isTemplateNode(prev) && findDir(prev, 'if')) {\r\n // remove node\r\n children.splice(i, 1);\r\n i--;\r\n // attach this slot to previous conditional\r\n let conditional = dynamicSlots[dynamicSlots.length - 1];\r\n while (conditional.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n conditional = conditional.alternate;\r\n }\r\n conditional.alternate = vElse.exp\r\n ? createConditionalExpression(vElse.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback)\r\n : buildDynamicSlot(slotName, slotFunction);\r\n }\r\n else {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, vElse.loc));\r\n }\r\n }\r\n else if ((vFor = findDir(slotElement, 'for'))) {\r\n hasDynamicSlots = true;\r\n const parseResult = vFor.parseResult ||\r\n parseForExpression(vFor.exp, context);\r\n if (parseResult) {\r\n // Render the dynamic slots as an array and add it to the createSlot()\r\n // args. The runtime knows how to handle it appropriately.\r\n dynamicSlots.push(createCallExpression(context.helper(RENDER_LIST), [\r\n parseResult.source,\r\n createFunctionExpression(createForLoopParams(parseResult), buildDynamicSlot(slotName, slotFunction), true /* force newline */)\r\n ]));\r\n }\r\n else {\r\n context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, vFor.loc));\r\n }\r\n }\r\n else {\r\n // check duplicate static names\r\n if (staticSlotName) {\r\n if (seenSlotNames.has(staticSlotName)) {\r\n context.onError(createCompilerError(38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */, dirLoc));\r\n continue;\r\n }\r\n seenSlotNames.add(staticSlotName);\r\n if (staticSlotName === 'default') {\r\n hasNamedDefaultSlot = true;\r\n }\r\n }\r\n slotsProperties.push(createObjectProperty(slotName, slotFunction));\r\n }\r\n }\r\n if (!onComponentSlot) {\r\n const buildDefaultSlotProperty = (props, children) => {\r\n const fn = buildSlotFn(props, children, loc);\r\n if (context.compatConfig) {\r\n fn.isNonScopedSlot = true;\r\n }\r\n return createObjectProperty(`default`, fn);\r\n };\r\n if (!hasTemplateSlots) {\r\n // implicit default slot (on component)\r\n slotsProperties.push(buildDefaultSlotProperty(undefined, children));\r\n }\r\n else if (implicitDefaultChildren.length &&\r\n // #3766\r\n // with whitespace: 'preserve', whitespaces between slots will end up in\r\n // implicitDefaultChildren. Ignore if all implicit children are whitespaces.\r\n implicitDefaultChildren.some(node => isNonWhitespaceContent(node))) {\r\n // implicit default slot (mixed with named slots)\r\n if (hasNamedDefaultSlot) {\r\n context.onError(createCompilerError(39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */, implicitDefaultChildren[0].loc));\r\n }\r\n else {\r\n slotsProperties.push(buildDefaultSlotProperty(undefined, implicitDefaultChildren));\r\n }\r\n }\r\n }\r\n const slotFlag = hasDynamicSlots\r\n ? 2 /* DYNAMIC */\r\n : hasForwardedSlots(node.children)\r\n ? 3 /* FORWARDED */\r\n : 1 /* STABLE */;\r\n let slots = createObjectExpression(slotsProperties.concat(createObjectProperty(`_`, \r\n // 2 = compiled but dynamic = can skip normalization, but must run diff\r\n // 1 = compiled and static = can skip normalization AND diff as optimized\r\n createSimpleExpression(slotFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${slotFlagsText[slotFlag]} */` : ``), false))), loc);\r\n if (dynamicSlots.length) {\r\n slots = createCallExpression(context.helper(CREATE_SLOTS), [\r\n slots,\r\n createArrayExpression(dynamicSlots)\r\n ]);\r\n }\r\n return {\r\n slots,\r\n hasDynamicSlots\r\n };\r\n}\r\nfunction buildDynamicSlot(name, fn) {\r\n return createObjectExpression([\r\n createObjectProperty(`name`, name),\r\n createObjectProperty(`fn`, fn)\r\n ]);\r\n}\r\nfunction hasForwardedSlots(children) {\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n switch (child.type) {\r\n case 1 /* ELEMENT */:\r\n if (child.tagType === 2 /* SLOT */ ||\r\n hasForwardedSlots(child.children)) {\r\n return true;\r\n }\r\n break;\r\n case 9 /* IF */:\r\n if (hasForwardedSlots(child.branches))\r\n return true;\r\n break;\r\n case 10 /* IF_BRANCH */:\r\n case 11 /* FOR */:\r\n if (hasForwardedSlots(child.children))\r\n return true;\r\n break;\r\n }\r\n }\r\n return false;\r\n}\r\nfunction isNonWhitespaceContent(node) {\r\n if (node.type !== 2 /* TEXT */ && node.type !== 12 /* TEXT_CALL */)\r\n return true;\r\n return node.type === 2 /* TEXT */\r\n ? !!node.content.trim()\r\n : isNonWhitespaceContent(node.content);\r\n}\n\n// some directive transforms (e.g. v-model) may return a symbol for runtime\r\n// import, which should be used instead of a resolveDirective call.\r\nconst directiveImportMap = new WeakMap();\r\n// generate a JavaScript AST for this element's codegen\r\nconst transformElement = (node, context) => {\r\n // perform the work on exit, after all child expressions have been\r\n // processed and merged.\r\n return function postTransformElement() {\r\n node = context.currentNode;\r\n if (!(node.type === 1 /* ELEMENT */ &&\r\n (node.tagType === 0 /* ELEMENT */ ||\r\n node.tagType === 1 /* COMPONENT */))) {\r\n return;\r\n }\r\n const { tag, props } = node;\r\n const isComponent = node.tagType === 1 /* COMPONENT */;\r\n // The goal of the transform is to create a codegenNode implementing the\r\n // VNodeCall interface.\r\n let vnodeTag = isComponent\r\n ? resolveComponentType(node, context)\r\n : `\"${tag}\"`;\r\n const isDynamicComponent = isObject(vnodeTag) && vnodeTag.callee === RESOLVE_DYNAMIC_COMPONENT;\r\n let vnodeProps;\r\n let vnodeChildren;\r\n let vnodePatchFlag;\r\n let patchFlag = 0;\r\n let vnodeDynamicProps;\r\n let dynamicPropNames;\r\n let vnodeDirectives;\r\n let shouldUseBlock = \r\n // dynamic component may resolve to plain elements\r\n isDynamicComponent ||\r\n vnodeTag === TELEPORT ||\r\n vnodeTag === SUSPENSE ||\r\n (!isComponent &&\r\n // <svg> and <foreignObject> must be forced into blocks so that block\r\n // updates inside get proper isSVG flag at runtime. (#639, #643)\r\n // This is technically web-specific, but splitting the logic out of core\r\n // leads to too much unnecessary complexity.\r\n (tag === 'svg' || tag === 'foreignObject'));\r\n // props\r\n if (props.length > 0) {\r\n const propsBuildResult = buildProps(node, context);\r\n vnodeProps = propsBuildResult.props;\r\n patchFlag = propsBuildResult.patchFlag;\r\n dynamicPropNames = propsBuildResult.dynamicPropNames;\r\n const directives = propsBuildResult.directives;\r\n vnodeDirectives =\r\n directives && directives.length\r\n ? createArrayExpression(directives.map(dir => buildDirectiveArgs(dir, context)))\r\n : undefined;\r\n if (propsBuildResult.shouldUseBlock) {\r\n shouldUseBlock = true;\r\n }\r\n }\r\n // children\r\n if (node.children.length > 0) {\r\n if (vnodeTag === KEEP_ALIVE) {\r\n // Although a built-in component, we compile KeepAlive with raw children\r\n // instead of slot functions so that it can be used inside Transition\r\n // or other Transition-wrapping HOCs.\r\n // To ensure correct updates with block optimizations, we need to:\r\n // 1. Force keep-alive into a block. This avoids its children being\r\n // collected by a parent block.\r\n shouldUseBlock = true;\r\n // 2. Force keep-alive to always be updated, since it uses raw children.\r\n patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n if ((process.env.NODE_ENV !== 'production') && node.children.length > 1) {\r\n context.onError(createCompilerError(45 /* X_KEEP_ALIVE_INVALID_CHILDREN */, {\r\n start: node.children[0].loc.start,\r\n end: node.children[node.children.length - 1].loc.end,\r\n source: ''\r\n }));\r\n }\r\n }\r\n const shouldBuildAsSlots = isComponent &&\r\n // Teleport is not a real component and has dedicated runtime handling\r\n vnodeTag !== TELEPORT &&\r\n // explained above.\r\n vnodeTag !== KEEP_ALIVE;\r\n if (shouldBuildAsSlots) {\r\n const { slots, hasDynamicSlots } = buildSlots(node, context);\r\n vnodeChildren = slots;\r\n if (hasDynamicSlots) {\r\n patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n }\r\n }\r\n else if (node.children.length === 1 && vnodeTag !== TELEPORT) {\r\n const child = node.children[0];\r\n const type = child.type;\r\n // check for dynamic text children\r\n const hasDynamicTextChild = type === 5 /* INTERPOLATION */ ||\r\n type === 8 /* COMPOUND_EXPRESSION */;\r\n if (hasDynamicTextChild &&\r\n getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n patchFlag |= 1 /* TEXT */;\r\n }\r\n // pass directly if the only child is a text node\r\n // (plain / interpolation / expression)\r\n if (hasDynamicTextChild || type === 2 /* TEXT */) {\r\n vnodeChildren = child;\r\n }\r\n else {\r\n vnodeChildren = node.children;\r\n }\r\n }\r\n else {\r\n vnodeChildren = node.children;\r\n }\r\n }\r\n // patchFlag & dynamicPropNames\r\n if (patchFlag !== 0) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (patchFlag < 0) {\r\n // special flags (negative and mutually exclusive)\r\n vnodePatchFlag = patchFlag + ` /* ${PatchFlagNames[patchFlag]} */`;\r\n }\r\n else {\r\n // bitwise flags\r\n const flagNames = Object.keys(PatchFlagNames)\r\n .map(Number)\r\n .filter(n => n > 0 && patchFlag & n)\r\n .map(n => PatchFlagNames[n])\r\n .join(`, `);\r\n vnodePatchFlag = patchFlag + ` /* ${flagNames} */`;\r\n }\r\n }\r\n else {\r\n vnodePatchFlag = String(patchFlag);\r\n }\r\n if (dynamicPropNames && dynamicPropNames.length) {\r\n vnodeDynamicProps = stringifyDynamicPropNames(dynamicPropNames);\r\n }\r\n }\r\n node.codegenNode = createVNodeCall(context, vnodeTag, vnodeProps, vnodeChildren, vnodePatchFlag, vnodeDynamicProps, vnodeDirectives, !!shouldUseBlock, false /* disableTracking */, isComponent, node.loc);\r\n };\r\n};\r\nfunction resolveComponentType(node, context, ssr = false) {\r\n let { tag } = node;\r\n // 1. dynamic component\r\n const isExplicitDynamic = isComponentTag(tag);\r\n const isProp = findProp(node, 'is');\r\n if (isProp) {\r\n if (isExplicitDynamic ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))) {\r\n const exp = isProp.type === 6 /* ATTRIBUTE */\r\n ? isProp.value && createSimpleExpression(isProp.value.content, true)\r\n : isProp.exp;\r\n if (exp) {\r\n return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n exp\r\n ]);\r\n }\r\n }\r\n else if (isProp.type === 6 /* ATTRIBUTE */ &&\r\n isProp.value.content.startsWith('vue:')) {\r\n // <button is=\"vue:xxx\">\r\n // if not <component>, only is value that starts with \"vue:\" will be\r\n // treated as component by the parse phase and reach here, unless it's\r\n // compat mode where all is values are considered components\r\n tag = isProp.value.content.slice(4);\r\n }\r\n }\r\n // 1.5 v-is (TODO: Deprecate)\r\n const isDir = !isExplicitDynamic && findDir(node, 'is');\r\n if (isDir && isDir.exp) {\r\n return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n isDir.exp\r\n ]);\r\n }\r\n // 2. built-in components (Teleport, Transition, KeepAlive, Suspense...)\r\n const builtIn = isCoreComponent(tag) || context.isBuiltInComponent(tag);\r\n if (builtIn) {\r\n // built-ins are simply fallthroughs / have special handling during ssr\r\n // so we don't need to import their runtime equivalents\r\n if (!ssr)\r\n context.helper(builtIn);\r\n return builtIn;\r\n }\r\n // 5. user component (resolve)\r\n context.helper(RESOLVE_COMPONENT);\r\n context.components.add(tag);\r\n return toValidAssetId(tag, `component`);\r\n}\r\nfunction buildProps(node, context, props = node.props, ssr = false) {\r\n const { tag, loc: elementLoc, children } = node;\r\n const isComponent = node.tagType === 1 /* COMPONENT */;\r\n let properties = [];\r\n const mergeArgs = [];\r\n const runtimeDirectives = [];\r\n const hasChildren = children.length > 0;\r\n let shouldUseBlock = false;\r\n // patchFlag analysis\r\n let patchFlag = 0;\r\n let hasRef = false;\r\n let hasClassBinding = false;\r\n let hasStyleBinding = false;\r\n let hasHydrationEventBinding = false;\r\n let hasDynamicKeys = false;\r\n let hasVnodeHook = false;\r\n const dynamicPropNames = [];\r\n const analyzePatchFlag = ({ key, value }) => {\r\n if (isStaticExp(key)) {\r\n const name = key.content;\r\n const isEventHandler = isOn(name);\r\n if (!isComponent &&\r\n isEventHandler &&\r\n // omit the flag for click handlers because hydration gives click\r\n // dedicated fast path.\r\n name.toLowerCase() !== 'onclick' &&\r\n // omit v-model handlers\r\n name !== 'onUpdate:modelValue' &&\r\n // omit onVnodeXXX hooks\r\n !isReservedProp(name)) {\r\n hasHydrationEventBinding = true;\r\n }\r\n if (isEventHandler && isReservedProp(name)) {\r\n hasVnodeHook = true;\r\n }\r\n if (value.type === 20 /* JS_CACHE_EXPRESSION */ ||\r\n ((value.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n value.type === 8 /* COMPOUND_EXPRESSION */) &&\r\n getConstantType(value, context) > 0)) {\r\n // skip if the prop is a cached handler or has constant value\r\n return;\r\n }\r\n if (name === 'ref') {\r\n hasRef = true;\r\n }\r\n else if (name === 'class') {\r\n hasClassBinding = true;\r\n }\r\n else if (name === 'style') {\r\n hasStyleBinding = true;\r\n }\r\n else if (name !== 'key' && !dynamicPropNames.includes(name)) {\r\n dynamicPropNames.push(name);\r\n }\r\n // treat the dynamic class and style binding of the component as dynamic props\r\n if (isComponent &&\r\n (name === 'class' || name === 'style') &&\r\n !dynamicPropNames.includes(name)) {\r\n dynamicPropNames.push(name);\r\n }\r\n }\r\n else {\r\n hasDynamicKeys = true;\r\n }\r\n };\r\n for (let i = 0; i < props.length; i++) {\r\n // static attribute\r\n const prop = props[i];\r\n if (prop.type === 6 /* ATTRIBUTE */) {\r\n const { loc, name, value } = prop;\r\n let isStatic = true;\r\n if (name === 'ref') {\r\n hasRef = true;\r\n if (context.scopes.vFor > 0) {\r\n properties.push(createObjectProperty(createSimpleExpression('ref_for', true), createSimpleExpression('true')));\r\n }\r\n }\r\n // skip is on <component>, or is=\"vue:xxx\"\r\n if (name === 'is' &&\r\n (isComponentTag(tag) ||\r\n (value && value.content.startsWith('vue:')) ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context)))) {\r\n continue;\r\n }\r\n properties.push(createObjectProperty(createSimpleExpression(name, true, getInnerRange(loc, 0, name.length)), createSimpleExpression(value ? value.content : '', isStatic, value ? value.loc : loc)));\r\n }\r\n else {\r\n // directives\r\n const { name, arg, exp, loc } = prop;\r\n const isVBind = name === 'bind';\r\n const isVOn = name === 'on';\r\n // skip v-slot - it is handled by its dedicated transform.\r\n if (name === 'slot') {\r\n if (!isComponent) {\r\n context.onError(createCompilerError(40 /* X_V_SLOT_MISPLACED */, loc));\r\n }\r\n continue;\r\n }\r\n // skip v-once/v-memo - they are handled by dedicated transforms.\r\n if (name === 'once' || name === 'memo') {\r\n continue;\r\n }\r\n // skip v-is and :is on <component>\r\n if (name === 'is' ||\r\n (isVBind &&\r\n isStaticArgOf(arg, 'is') &&\r\n (isComponentTag(tag) ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))))) {\r\n continue;\r\n }\r\n // skip v-on in SSR compilation\r\n if (isVOn && ssr) {\r\n continue;\r\n }\r\n if (\r\n // #938: elements with dynamic keys should be forced into blocks\r\n (isVBind && isStaticArgOf(arg, 'key')) ||\r\n // inline before-update hooks need to force block so that it is invoked\r\n // before children\r\n (isVOn && hasChildren && isStaticArgOf(arg, 'vue:before-update'))) {\r\n shouldUseBlock = true;\r\n }\r\n if (isVBind && isStaticArgOf(arg, 'ref') && context.scopes.vFor > 0) {\r\n properties.push(createObjectProperty(createSimpleExpression('ref_for', true), createSimpleExpression('true')));\r\n }\r\n // special case for v-bind and v-on with no argument\r\n if (!arg && (isVBind || isVOn)) {\r\n hasDynamicKeys = true;\r\n if (exp) {\r\n if (properties.length) {\r\n mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n properties = [];\r\n }\r\n if (isVBind) {\r\n {\r\n // 2.x v-bind object order compat\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const hasOverridableKeys = mergeArgs.some(arg => {\r\n if (arg.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n return arg.properties.some(({ key }) => {\r\n if (key.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n !key.isStatic) {\r\n return true;\r\n }\r\n return (key.content !== 'class' &&\r\n key.content !== 'style' &&\r\n !isOn(key.content));\r\n });\r\n }\r\n else {\r\n // dynamic expression\r\n return true;\r\n }\r\n });\r\n if (hasOverridableKeys) {\r\n checkCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context, loc);\r\n }\r\n }\r\n if (isCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context)) {\r\n mergeArgs.unshift(exp);\r\n continue;\r\n }\r\n }\r\n mergeArgs.push(exp);\r\n }\r\n else {\r\n // v-on=\"obj\" -> toHandlers(obj)\r\n mergeArgs.push({\r\n type: 14 /* JS_CALL_EXPRESSION */,\r\n loc,\r\n callee: context.helper(TO_HANDLERS),\r\n arguments: [exp]\r\n });\r\n }\r\n }\r\n else {\r\n context.onError(createCompilerError(isVBind\r\n ? 34 /* X_V_BIND_NO_EXPRESSION */\r\n : 35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n }\r\n continue;\r\n }\r\n const directiveTransform = context.directiveTransforms[name];\r\n if (directiveTransform) {\r\n // has built-in directive transform.\r\n const { props, needRuntime } = directiveTransform(prop, node, context);\r\n !ssr && props.forEach(analyzePatchFlag);\r\n properties.push(...props);\r\n if (needRuntime) {\r\n runtimeDirectives.push(prop);\r\n if (isSymbol(needRuntime)) {\r\n directiveImportMap.set(prop, needRuntime);\r\n }\r\n }\r\n }\r\n else {\r\n // no built-in transform, this is a user custom directive.\r\n runtimeDirectives.push(prop);\r\n // custom dirs may use beforeUpdate so they need to force blocks\r\n // to ensure before-update gets called before children update\r\n if (hasChildren) {\r\n shouldUseBlock = true;\r\n }\r\n }\r\n }\r\n }\r\n let propsExpression = undefined;\r\n // has v-bind=\"object\" or v-on=\"object\", wrap with mergeProps\r\n if (mergeArgs.length) {\r\n if (properties.length) {\r\n mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n }\r\n if (mergeArgs.length > 1) {\r\n propsExpression = createCallExpression(context.helper(MERGE_PROPS), mergeArgs, elementLoc);\r\n }\r\n else {\r\n // single v-bind with nothing else - no need for a mergeProps call\r\n propsExpression = mergeArgs[0];\r\n }\r\n }\r\n else if (properties.length) {\r\n propsExpression = createObjectExpression(dedupeProperties(properties), elementLoc);\r\n }\r\n // patchFlag analysis\r\n if (hasDynamicKeys) {\r\n patchFlag |= 16 /* FULL_PROPS */;\r\n }\r\n else {\r\n if (hasClassBinding && !isComponent) {\r\n patchFlag |= 2 /* CLASS */;\r\n }\r\n if (hasStyleBinding && !isComponent) {\r\n patchFlag |= 4 /* STYLE */;\r\n }\r\n if (dynamicPropNames.length) {\r\n patchFlag |= 8 /* PROPS */;\r\n }\r\n if (hasHydrationEventBinding) {\r\n patchFlag |= 32 /* HYDRATE_EVENTS */;\r\n }\r\n }\r\n if (!shouldUseBlock &&\r\n (patchFlag === 0 || patchFlag === 32 /* HYDRATE_EVENTS */) &&\r\n (hasRef || hasVnodeHook || runtimeDirectives.length > 0)) {\r\n patchFlag |= 512 /* NEED_PATCH */;\r\n }\r\n // pre-normalize props, SSR is skipped for now\r\n if (!context.inSSR && propsExpression) {\r\n switch (propsExpression.type) {\r\n case 15 /* JS_OBJECT_EXPRESSION */:\r\n // means that there is no v-bind,\r\n // but still need to deal with dynamic key binding\r\n let classKeyIndex = -1;\r\n let styleKeyIndex = -1;\r\n let hasDynamicKey = false;\r\n for (let i = 0; i < propsExpression.properties.length; i++) {\r\n const key = propsExpression.properties[i].key;\r\n if (isStaticExp(key)) {\r\n if (key.content === 'class') {\r\n classKeyIndex = i;\r\n }\r\n else if (key.content === 'style') {\r\n styleKeyIndex = i;\r\n }\r\n }\r\n else if (!key.isHandlerKey) {\r\n hasDynamicKey = true;\r\n }\r\n }\r\n const classProp = propsExpression.properties[classKeyIndex];\r\n const styleProp = propsExpression.properties[styleKeyIndex];\r\n // no dynamic key\r\n if (!hasDynamicKey) {\r\n if (classProp && !isStaticExp(classProp.value)) {\r\n classProp.value = createCallExpression(context.helper(NORMALIZE_CLASS), [classProp.value]);\r\n }\r\n if (styleProp &&\r\n !isStaticExp(styleProp.value) &&\r\n // the static style is compiled into an object,\r\n // so use `hasStyleBinding` to ensure that it is a dynamic style binding\r\n (hasStyleBinding ||\r\n // v-bind:style and style both exist,\r\n // v-bind:style with static literal object\r\n styleProp.value.type === 17 /* JS_ARRAY_EXPRESSION */)) {\r\n styleProp.value = createCallExpression(context.helper(NORMALIZE_STYLE), [styleProp.value]);\r\n }\r\n }\r\n else {\r\n // dynamic key binding, wrap with `normalizeProps`\r\n propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [propsExpression]);\r\n }\r\n break;\r\n case 14 /* JS_CALL_EXPRESSION */:\r\n // mergeProps call, do nothing\r\n break;\r\n default:\r\n // single v-bind\r\n propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [\r\n createCallExpression(context.helper(GUARD_REACTIVE_PROPS), [\r\n propsExpression\r\n ])\r\n ]);\r\n break;\r\n }\r\n }\r\n return {\r\n props: propsExpression,\r\n directives: runtimeDirectives,\r\n patchFlag,\r\n dynamicPropNames,\r\n shouldUseBlock\r\n };\r\n}\r\n// Dedupe props in an object literal.\r\n// Literal duplicated attributes would have been warned during the parse phase,\r\n// however, it's possible to encounter duplicated `onXXX` handlers with different\r\n// modifiers. We also need to merge static and dynamic class / style attributes.\r\n// - onXXX handlers / style: merge into array\r\n// - class: merge into single expression with concatenation\r\nfunction dedupeProperties(properties) {\r\n const knownProps = new Map();\r\n const deduped = [];\r\n for (let i = 0; i < properties.length; i++) {\r\n const prop = properties[i];\r\n // dynamic keys are always allowed\r\n if (prop.key.type === 8 /* COMPOUND_EXPRESSION */ || !prop.key.isStatic) {\r\n deduped.push(prop);\r\n continue;\r\n }\r\n const name = prop.key.content;\r\n const existing = knownProps.get(name);\r\n if (existing) {\r\n if (name === 'style' || name === 'class' || isOn(name)) {\r\n mergeAsArray(existing, prop);\r\n }\r\n // unexpected duplicate, should have emitted error during parse\r\n }\r\n else {\r\n knownProps.set(name, prop);\r\n deduped.push(prop);\r\n }\r\n }\r\n return deduped;\r\n}\r\nfunction mergeAsArray(existing, incoming) {\r\n if (existing.value.type === 17 /* JS_ARRAY_EXPRESSION */) {\r\n existing.value.elements.push(incoming.value);\r\n }\r\n else {\r\n existing.value = createArrayExpression([existing.value, incoming.value], existing.loc);\r\n }\r\n}\r\nfunction buildDirectiveArgs(dir, context) {\r\n const dirArgs = [];\r\n const runtime = directiveImportMap.get(dir);\r\n if (runtime) {\r\n // built-in directive with runtime\r\n dirArgs.push(context.helperString(runtime));\r\n }\r\n else {\r\n {\r\n // inject statement for resolving directive\r\n context.helper(RESOLVE_DIRECTIVE);\r\n context.directives.add(dir.name);\r\n dirArgs.push(toValidAssetId(dir.name, `directive`));\r\n }\r\n }\r\n const { loc } = dir;\r\n if (dir.exp)\r\n dirArgs.push(dir.exp);\r\n if (dir.arg) {\r\n if (!dir.exp) {\r\n dirArgs.push(`void 0`);\r\n }\r\n dirArgs.push(dir.arg);\r\n }\r\n if (Object.keys(dir.modifiers).length) {\r\n if (!dir.arg) {\r\n if (!dir.exp) {\r\n dirArgs.push(`void 0`);\r\n }\r\n dirArgs.push(`void 0`);\r\n }\r\n const trueExpression = createSimpleExpression(`true`, false, loc);\r\n dirArgs.push(createObjectExpression(dir.modifiers.map(modifier => createObjectProperty(modifier, trueExpression)), loc));\r\n }\r\n return createArrayExpression(dirArgs, dir.loc);\r\n}\r\nfunction stringifyDynamicPropNames(props) {\r\n let propsNamesString = `[`;\r\n for (let i = 0, l = props.length; i < l; i++) {\r\n propsNamesString += JSON.stringify(props[i]);\r\n if (i < l - 1)\r\n propsNamesString += ', ';\r\n }\r\n return propsNamesString + `]`;\r\n}\r\nfunction isComponentTag(tag) {\r\n return tag === 'component' || tag === 'Component';\r\n}\n\n(process.env.NODE_ENV !== 'production')\r\n ? Object.freeze({})\r\n : {};\r\n(process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst cacheStringFunction = (fn) => {\r\n const cache = Object.create(null);\r\n return ((str) => {\r\n const hit = cache[str];\r\n return hit || (cache[str] = fn(str));\r\n });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\n\nconst transformSlotOutlet = (node, context) => {\r\n if (isSlotOutlet(node)) {\r\n const { children, loc } = node;\r\n const { slotName, slotProps } = processSlotOutlet(node, context);\r\n const slotArgs = [\r\n context.prefixIdentifiers ? `_ctx.$slots` : `$slots`,\r\n slotName,\r\n '{}',\r\n 'undefined',\r\n 'true'\r\n ];\r\n let expectedLen = 2;\r\n if (slotProps) {\r\n slotArgs[2] = slotProps;\r\n expectedLen = 3;\r\n }\r\n if (children.length) {\r\n slotArgs[3] = createFunctionExpression([], children, false, false, loc);\r\n expectedLen = 4;\r\n }\r\n if (context.scopeId && !context.slotted) {\r\n expectedLen = 5;\r\n }\r\n slotArgs.splice(expectedLen); // remove unused arguments\r\n node.codegenNode = createCallExpression(context.helper(RENDER_SLOT), slotArgs, loc);\r\n }\r\n};\r\nfunction processSlotOutlet(node, context) {\r\n let slotName = `\"default\"`;\r\n let slotProps = undefined;\r\n const nonNameProps = [];\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (p.value) {\r\n if (p.name === 'name') {\r\n slotName = JSON.stringify(p.value.content);\r\n }\r\n else {\r\n p.name = camelize(p.name);\r\n nonNameProps.push(p);\r\n }\r\n }\r\n }\r\n else {\r\n if (p.name === 'bind' && isStaticArgOf(p.arg, 'name')) {\r\n if (p.exp)\r\n slotName = p.exp;\r\n }\r\n else {\r\n if (p.name === 'bind' && p.arg && isStaticExp(p.arg)) {\r\n p.arg.content = camelize(p.arg.content);\r\n }\r\n nonNameProps.push(p);\r\n }\r\n }\r\n }\r\n if (nonNameProps.length > 0) {\r\n const { props, directives } = buildProps(node, context, nonNameProps);\r\n slotProps = props;\r\n if (directives.length) {\r\n context.onError(createCompilerError(36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */, directives[0].loc));\r\n }\r\n }\r\n return {\r\n slotName,\r\n slotProps\r\n };\r\n}\n\nconst fnExpRE = /^\\s*([\\w$_]+|(async\\s*)?\\([^)]*?\\))\\s*=>|^\\s*(async\\s+)?function(?:\\s+[\\w$]+)?\\s*\\(/;\r\nconst transformOn = (dir, node, context, augmentor) => {\r\n const { loc, modifiers, arg } = dir;\r\n if (!dir.exp && !modifiers.length) {\r\n context.onError(createCompilerError(35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n }\r\n let eventName;\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n let rawName = arg.content;\r\n // TODO deprecate @vnodeXXX usage\r\n if (rawName.startsWith('vue:')) {\r\n rawName = `vnode-${rawName.slice(4)}`;\r\n }\r\n // for all event listeners, auto convert it to camelCase. See issue #2249\r\n eventName = createSimpleExpression(toHandlerKey(camelize$1(rawName)), true, arg.loc);\r\n }\r\n else {\r\n // #2388\r\n eventName = createCompoundExpression([\r\n `${context.helperString(TO_HANDLER_KEY)}(`,\r\n arg,\r\n `)`\r\n ]);\r\n }\r\n }\r\n else {\r\n // already a compound expression.\r\n eventName = arg;\r\n eventName.children.unshift(`${context.helperString(TO_HANDLER_KEY)}(`);\r\n eventName.children.push(`)`);\r\n }\r\n // handler processing\r\n let exp = dir.exp;\r\n if (exp && !exp.content.trim()) {\r\n exp = undefined;\r\n }\r\n let shouldCache = context.cacheHandlers && !exp && !context.inVOnce;\r\n if (exp) {\r\n const isMemberExp = isMemberExpression(exp.content);\r\n const isInlineStatement = !(isMemberExp || fnExpRE.test(exp.content));\r\n const hasMultipleStatements = exp.content.includes(`;`);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(exp, context, false, hasMultipleStatements);\r\n }\r\n if (isInlineStatement || (shouldCache && isMemberExp)) {\r\n // wrap inline statement in a function expression\r\n exp = createCompoundExpression([\r\n `${isInlineStatement\r\n ? `$event`\r\n : `${``}(...args)`} => ${hasMultipleStatements ? `{` : `(`}`,\r\n exp,\r\n hasMultipleStatements ? `}` : `)`\r\n ]);\r\n }\r\n }\r\n let ret = {\r\n props: [\r\n createObjectProperty(eventName, exp || createSimpleExpression(`() => {}`, false, loc))\r\n ]\r\n };\r\n // apply extended compiler augmentor\r\n if (augmentor) {\r\n ret = augmentor(ret);\r\n }\r\n if (shouldCache) {\r\n // cache handlers so that it's always the same handler being passed down.\r\n // this avoids unnecessary re-renders when users use inline handlers on\r\n // components.\r\n ret.props[0].value = context.cache(ret.props[0].value);\r\n }\r\n // mark the key as handler for props normalization check\r\n ret.props.forEach(p => (p.key.isHandlerKey = true));\r\n return ret;\r\n};\n\n// v-bind without arg is handled directly in ./transformElements.ts due to it affecting\r\n// codegen for the entire props object. This transform here is only for v-bind\r\n// *with* args.\r\nconst transformBind = (dir, _node, context) => {\r\n const { exp, modifiers, loc } = dir;\r\n const arg = dir.arg;\r\n if (arg.type !== 4 /* SIMPLE_EXPRESSION */) {\r\n arg.children.unshift(`(`);\r\n arg.children.push(`) || \"\"`);\r\n }\r\n else if (!arg.isStatic) {\r\n arg.content = `${arg.content} || \"\"`;\r\n }\r\n // .sync is replaced by v-model:arg\r\n if (modifiers.includes('camel')) {\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n arg.content = camelize$1(arg.content);\r\n }\r\n else {\r\n arg.content = `${context.helperString(CAMELIZE)}(${arg.content})`;\r\n }\r\n }\r\n else {\r\n arg.children.unshift(`${context.helperString(CAMELIZE)}(`);\r\n arg.children.push(`)`);\r\n }\r\n }\r\n if (!context.inSSR) {\r\n if (modifiers.includes('prop')) {\r\n injectPrefix(arg, '.');\r\n }\r\n if (modifiers.includes('attr')) {\r\n injectPrefix(arg, '^');\r\n }\r\n }\r\n if (!exp ||\r\n (exp.type === 4 /* SIMPLE_EXPRESSION */ && !exp.content.trim())) {\r\n context.onError(createCompilerError(34 /* X_V_BIND_NO_EXPRESSION */, loc));\r\n return {\r\n props: [createObjectProperty(arg, createSimpleExpression('', true, loc))]\r\n };\r\n }\r\n return {\r\n props: [createObjectProperty(arg, exp)]\r\n };\r\n};\r\nconst injectPrefix = (arg, prefix) => {\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n arg.content = prefix + arg.content;\r\n }\r\n else {\r\n arg.content = `\\`${prefix}\\${${arg.content}}\\``;\r\n }\r\n }\r\n else {\r\n arg.children.unshift(`'${prefix}' + (`);\r\n arg.children.push(`)`);\r\n }\r\n};\n\n// Merge adjacent text nodes and expressions into a single expression\r\n// e.g. <div>abc {{ d }} {{ e }}</div> should have a single expression node as child.\r\nconst transformText = (node, context) => {\r\n if (node.type === 0 /* ROOT */ ||\r\n node.type === 1 /* ELEMENT */ ||\r\n node.type === 11 /* FOR */ ||\r\n node.type === 10 /* IF_BRANCH */) {\r\n // perform the transform on node exit so that all expressions have already\r\n // been processed.\r\n return () => {\r\n const children = node.children;\r\n let currentContainer = undefined;\r\n let hasText = false;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isText(child)) {\r\n hasText = true;\r\n for (let j = i + 1; j < children.length; j++) {\r\n const next = children[j];\r\n if (isText(next)) {\r\n if (!currentContainer) {\r\n currentContainer = children[i] = {\r\n type: 8 /* COMPOUND_EXPRESSION */,\r\n loc: child.loc,\r\n children: [child]\r\n };\r\n }\r\n // merge adjacent text node into current\r\n currentContainer.children.push(` + `, next);\r\n children.splice(j, 1);\r\n j--;\r\n }\r\n else {\r\n currentContainer = undefined;\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n if (!hasText ||\r\n // if this is a plain element with a single text child, leave it\r\n // as-is since the runtime has dedicated fast path for this by directly\r\n // setting textContent of the element.\r\n // for component root it's always normalized anyway.\r\n (children.length === 1 &&\r\n (node.type === 0 /* ROOT */ ||\r\n (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n // #3756\r\n // custom directives can potentially add DOM elements arbitrarily,\r\n // we need to avoid setting textContent of the element at runtime\r\n // to avoid accidentally overwriting the DOM elements added\r\n // by the user through custom directives.\r\n !node.props.find(p => p.type === 7 /* DIRECTIVE */ &&\r\n !context.directiveTransforms[p.name]) &&\r\n // in compat mode, <template> tags with no special directives\r\n // will be rendered as a fragment so its children must be\r\n // converted into vnodes.\r\n !(node.tag === 'template'))))) {\r\n return;\r\n }\r\n // pre-convert text nodes into createTextVNode(text) calls to avoid\r\n // runtime normalization.\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isText(child) || child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n const callArgs = [];\r\n // createTextVNode defaults to single whitespace, so if it is a\r\n // single space the code could be an empty call to save bytes.\r\n if (child.type !== 2 /* TEXT */ || child.content !== ' ') {\r\n callArgs.push(child);\r\n }\r\n // mark dynamic text with flag so it gets patched inside a block\r\n if (!context.ssr &&\r\n getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n callArgs.push(1 /* TEXT */ +\r\n ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[1 /* TEXT */]} */` : ``));\r\n }\r\n children[i] = {\r\n type: 12 /* TEXT_CALL */,\r\n content: child,\r\n loc: child.loc,\r\n codegenNode: createCallExpression(context.helper(CREATE_TEXT), callArgs)\r\n };\r\n }\r\n }\r\n };\r\n }\r\n};\n\nconst seen = new WeakSet();\r\nconst transformOnce = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ && findDir(node, 'once', true)) {\r\n if (seen.has(node) || context.inVOnce) {\r\n return;\r\n }\r\n seen.add(node);\r\n context.inVOnce = true;\r\n context.helper(SET_BLOCK_TRACKING);\r\n return () => {\r\n context.inVOnce = false;\r\n const cur = context.currentNode;\r\n if (cur.codegenNode) {\r\n cur.codegenNode = context.cache(cur.codegenNode, true /* isVNode */);\r\n }\r\n };\r\n }\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n const { exp, arg } = dir;\r\n if (!exp) {\r\n context.onError(createCompilerError(41 /* X_V_MODEL_NO_EXPRESSION */, dir.loc));\r\n return createTransformProps();\r\n }\r\n const rawExp = exp.loc.source;\r\n const expString = exp.type === 4 /* SIMPLE_EXPRESSION */ ? exp.content : rawExp;\r\n // im SFC <script setup> inline mode, the exp may have been transformed into\r\n // _unref(exp)\r\n context.bindingMetadata[rawExp];\r\n const maybeRef = !true /* SETUP_CONST */;\r\n if (!expString.trim() ||\r\n (!isMemberExpression(expString) && !maybeRef)) {\r\n context.onError(createCompilerError(42 /* X_V_MODEL_MALFORMED_EXPRESSION */, exp.loc));\r\n return createTransformProps();\r\n }\r\n const propName = arg ? arg : createSimpleExpression('modelValue', true);\r\n const eventName = arg\r\n ? isStaticExp(arg)\r\n ? `onUpdate:${arg.content}`\r\n : createCompoundExpression(['\"onUpdate:\" + ', arg])\r\n : `onUpdate:modelValue`;\r\n let assignmentExp;\r\n const eventArg = context.isTS ? `($event: any)` : `$event`;\r\n {\r\n assignmentExp = createCompoundExpression([\r\n `${eventArg} => ((`,\r\n exp,\r\n `) = $event)`\r\n ]);\r\n }\r\n const props = [\r\n // modelValue: foo\r\n createObjectProperty(propName, dir.exp),\r\n // \"onUpdate:modelValue\": $event => (foo = $event)\r\n createObjectProperty(eventName, assignmentExp)\r\n ];\r\n // modelModifiers: { foo: true, \"bar-baz\": true }\r\n if (dir.modifiers.length && node.tagType === 1 /* COMPONENT */) {\r\n const modifiers = dir.modifiers\r\n .map(m => (isSimpleIdentifier(m) ? m : JSON.stringify(m)) + `: true`)\r\n .join(`, `);\r\n const modifiersKey = arg\r\n ? isStaticExp(arg)\r\n ? `${arg.content}Modifiers`\r\n : createCompoundExpression([arg, ' + \"Modifiers\"'])\r\n : `modelModifiers`;\r\n props.push(createObjectProperty(modifiersKey, createSimpleExpression(`{ ${modifiers} }`, false, dir.loc, 2 /* CAN_HOIST */)));\r\n }\r\n return createTransformProps(props);\r\n};\r\nfunction createTransformProps(props = []) {\r\n return { props };\r\n}\n\nconst validDivisionCharRE = /[\\w).+\\-_$\\]]/;\r\nconst transformFilter = (node, context) => {\r\n if (!isCompatEnabled(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context)) {\r\n return;\r\n }\r\n if (node.type === 5 /* INTERPOLATION */) {\r\n // filter rewrite is applied before expression transform so only\r\n // simple expressions are possible at this stage\r\n rewriteFilter(node.content, context);\r\n }\r\n if (node.type === 1 /* ELEMENT */) {\r\n node.props.forEach((prop) => {\r\n if (prop.type === 7 /* DIRECTIVE */ &&\r\n prop.name !== 'for' &&\r\n prop.exp) {\r\n rewriteFilter(prop.exp, context);\r\n }\r\n });\r\n }\r\n};\r\nfunction rewriteFilter(node, context) {\r\n if (node.type === 4 /* SIMPLE_EXPRESSION */) {\r\n parseFilter(node, context);\r\n }\r\n else {\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (typeof child !== 'object')\r\n continue;\r\n if (child.type === 4 /* SIMPLE_EXPRESSION */) {\r\n parseFilter(child, context);\r\n }\r\n else if (child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n rewriteFilter(node, context);\r\n }\r\n else if (child.type === 5 /* INTERPOLATION */) {\r\n rewriteFilter(child.content, context);\r\n }\r\n }\r\n }\r\n}\r\nfunction parseFilter(node, context) {\r\n const exp = node.content;\r\n let inSingle = false;\r\n let inDouble = false;\r\n let inTemplateString = false;\r\n let inRegex = false;\r\n let curly = 0;\r\n let square = 0;\r\n let paren = 0;\r\n let lastFilterIndex = 0;\r\n let c, prev, i, expression, filters = [];\r\n for (i = 0; i < exp.length; i++) {\r\n prev = c;\r\n c = exp.charCodeAt(i);\r\n if (inSingle) {\r\n if (c === 0x27 && prev !== 0x5c)\r\n inSingle = false;\r\n }\r\n else if (inDouble) {\r\n if (c === 0x22 && prev !== 0x5c)\r\n inDouble = false;\r\n }\r\n else if (inTemplateString) {\r\n if (c === 0x60 && prev !== 0x5c)\r\n inTemplateString = false;\r\n }\r\n else if (inRegex) {\r\n if (c === 0x2f && prev !== 0x5c)\r\n inRegex = false;\r\n }\r\n else if (c === 0x7c && // pipe\r\n exp.charCodeAt(i + 1) !== 0x7c &&\r\n exp.charCodeAt(i - 1) !== 0x7c &&\r\n !curly &&\r\n !square &&\r\n !paren) {\r\n if (expression === undefined) {\r\n // first filter, end of expression\r\n lastFilterIndex = i + 1;\r\n expression = exp.slice(0, i).trim();\r\n }\r\n else {\r\n pushFilter();\r\n }\r\n }\r\n else {\r\n switch (c) {\r\n case 0x22:\r\n inDouble = true;\r\n break; // \"\r\n case 0x27:\r\n inSingle = true;\r\n break; // '\r\n case 0x60:\r\n inTemplateString = true;\r\n break; // `\r\n case 0x28:\r\n paren++;\r\n break; // (\r\n case 0x29:\r\n paren--;\r\n break; // )\r\n case 0x5b:\r\n square++;\r\n break; // [\r\n case 0x5d:\r\n square--;\r\n break; // ]\r\n case 0x7b:\r\n curly++;\r\n break; // {\r\n case 0x7d:\r\n curly--;\r\n break; // }\r\n }\r\n if (c === 0x2f) {\r\n // /\r\n let j = i - 1;\r\n let p;\r\n // find first non-whitespace prev char\r\n for (; j >= 0; j--) {\r\n p = exp.charAt(j);\r\n if (p !== ' ')\r\n break;\r\n }\r\n if (!p || !validDivisionCharRE.test(p)) {\r\n inRegex = true;\r\n }\r\n }\r\n }\r\n }\r\n if (expression === undefined) {\r\n expression = exp.slice(0, i).trim();\r\n }\r\n else if (lastFilterIndex !== 0) {\r\n pushFilter();\r\n }\r\n function pushFilter() {\r\n filters.push(exp.slice(lastFilterIndex, i).trim());\r\n lastFilterIndex = i + 1;\r\n }\r\n if (filters.length) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warnDeprecation(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context, node.loc);\r\n for (i = 0; i < filters.length; i++) {\r\n expression = wrapFilter(expression, filters[i], context);\r\n }\r\n node.content = expression;\r\n }\r\n}\r\nfunction wrapFilter(exp, filter, context) {\r\n context.helper(RESOLVE_FILTER);\r\n const i = filter.indexOf('(');\r\n if (i < 0) {\r\n context.filters.add(filter);\r\n return `${toValidAssetId(filter, 'filter')}(${exp})`;\r\n }\r\n else {\r\n const name = filter.slice(0, i);\r\n const args = filter.slice(i + 1);\r\n context.filters.add(name);\r\n return `${toValidAssetId(name, 'filter')}(${exp}${args !== ')' ? ',' + args : args}`;\r\n }\r\n}\n\nconst seen$1 = new WeakSet();\r\nconst transformMemo = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n const dir = findDir(node, 'memo');\r\n if (!dir || seen$1.has(node)) {\r\n return;\r\n }\r\n seen$1.add(node);\r\n return () => {\r\n const codegenNode = node.codegenNode ||\r\n context.currentNode.codegenNode;\r\n if (codegenNode && codegenNode.type === 13 /* VNODE_CALL */) {\r\n // non-component sub tree should be turned into a block\r\n if (node.tagType !== 1 /* COMPONENT */) {\r\n makeBlock(codegenNode, context);\r\n }\r\n node.codegenNode = createCallExpression(context.helper(WITH_MEMO), [\r\n dir.exp,\r\n createFunctionExpression(undefined, codegenNode),\r\n `_cache`,\r\n String(context.cached++)\r\n ]);\r\n }\r\n };\r\n }\r\n};\n\nfunction getBaseTransformPreset(prefixIdentifiers) {\r\n return [\r\n [\r\n transformOnce,\r\n transformIf,\r\n transformMemo,\r\n transformFor,\r\n ...([transformFilter] ),\r\n ...((process.env.NODE_ENV !== 'production')\r\n ? [transformExpression]\r\n : []),\r\n transformSlotOutlet,\r\n transformElement,\r\n trackSlotScopes,\r\n transformText\r\n ],\r\n {\r\n on: transformOn,\r\n bind: transformBind,\r\n model: transformModel\r\n }\r\n ];\r\n}\r\n// we name it `baseCompile` so that higher order compilers like\r\n// @vue/compiler-dom can export `compile` while re-exporting everything else.\r\nfunction baseCompile(template, options = {}) {\r\n const onError = options.onError || defaultOnError;\r\n const isModuleMode = options.mode === 'module';\r\n /* istanbul ignore if */\r\n {\r\n if (options.prefixIdentifiers === true) {\r\n onError(createCompilerError(46 /* X_PREFIX_ID_NOT_SUPPORTED */));\r\n }\r\n else if (isModuleMode) {\r\n onError(createCompilerError(47 /* X_MODULE_MODE_NOT_SUPPORTED */));\r\n }\r\n }\r\n const prefixIdentifiers = !true ;\r\n if (options.cacheHandlers) {\r\n onError(createCompilerError(48 /* X_CACHE_HANDLER_NOT_SUPPORTED */));\r\n }\r\n if (options.scopeId && !isModuleMode) {\r\n onError(createCompilerError(49 /* X_SCOPE_ID_NOT_SUPPORTED */));\r\n }\r\n const ast = isString(template) ? baseParse(template, options) : template;\r\n const [nodeTransforms, directiveTransforms] = getBaseTransformPreset();\r\n transform(ast, extend({}, options, {\r\n prefixIdentifiers,\r\n nodeTransforms: [\r\n ...nodeTransforms,\r\n ...(options.nodeTransforms || []) // user transforms\r\n ],\r\n directiveTransforms: extend({}, directiveTransforms, options.directiveTransforms || {} // user transforms\r\n )\r\n }));\r\n return generate(ast, extend({}, options, {\r\n prefixIdentifiers\r\n }));\r\n}\n\nconst noopDirectiveTransform = () => ({ props: [] });\n\nexport { BASE_TRANSITION, CAMELIZE, CAPITALIZE, CREATE_BLOCK, CREATE_COMMENT, CREATE_ELEMENT_BLOCK, CREATE_ELEMENT_VNODE, CREATE_SLOTS, CREATE_STATIC, CREATE_TEXT, CREATE_VNODE, FRAGMENT, GUARD_REACTIVE_PROPS, IS_MEMO_SAME, IS_REF, KEEP_ALIVE, MERGE_PROPS, NORMALIZE_CLASS, NORMALIZE_PROPS, NORMALIZE_STYLE, OPEN_BLOCK, POP_SCOPE_ID, PUSH_SCOPE_ID, RENDER_LIST, RENDER_SLOT, RESOLVE_COMPONENT, RESOLVE_DIRECTIVE, RESOLVE_DYNAMIC_COMPONENT, RESOLVE_FILTER, SET_BLOCK_TRACKING, SUSPENSE, TELEPORT, TO_DISPLAY_STRING, TO_HANDLERS, TO_HANDLER_KEY, UNREF, WITH_CTX, WITH_DIRECTIVES, WITH_MEMO, advancePositionWithClone, advancePositionWithMutation, assert, baseCompile, baseParse, buildProps, buildSlots, checkCompatEnabled, createArrayExpression, createAssignmentExpression, createBlockStatement, createCacheExpression, createCallExpression, createCompilerError, createCompoundExpression, createConditionalExpression, createForLoopParams, createFunctionExpression, createIfStatement, createInterpolation, createObjectExpression, createObjectProperty, createReturnStatement, createRoot, createSequenceExpression, createSimpleExpression, createStructuralDirectiveTransform, createTemplateLiteral, createTransformContext, createVNodeCall, extractIdentifiers, findDir, findProp, generate, getBaseTransformPreset, getInnerRange, getMemoedVNodeCall, getVNodeBlockHelper, getVNodeHelper, hasDynamicKeyVBind, hasScopeRef, helperNameMap, injectProp, isBuiltInType, isCoreComponent, isFunctionType, isInDestructureAssignment, isMemberExpression, isMemberExpressionBrowser, isMemberExpressionNode, isReferencedIdentifier, isSimpleIdentifier, isSlotOutlet, isStaticArgOf, isStaticExp, isStaticProperty, isStaticPropertyKey, isTemplateNode, isText, isVSlot, locStub, makeBlock, noopDirectiveTransform, processExpression, processFor, processIf, processSlotOutlet, registerRuntimeHelpers, resolveComponentType, toValidAssetId, trackSlotScopes, trackVForSlotScopes, transform, transformBind, transformElement, transformExpression, transformModel, transformOn, traverseNode, walkBlockDeclarations, walkFunctionParams, walkIdentifiers, warnDeprecation };\n","import { registerRuntimeHelpers, isBuiltInType, createSimpleExpression, createCompilerError, createObjectProperty, createCallExpression, TO_DISPLAY_STRING, transformModel as transformModel$1, findProp, hasDynamicKeyVBind, transformOn as transformOn$1, createCompoundExpression, isStaticExp, checkCompatEnabled, noopDirectiveTransform, baseCompile, baseParse } from '@vue/compiler-core';\nexport * from '@vue/compiler-core';\nimport { isVoidTag, isHTMLTag, isSVGTag, makeMap, parseStringStyle, capitalize, extend } from '@vue/shared';\n\nconst V_MODEL_RADIO = Symbol((process.env.NODE_ENV !== 'production') ? `vModelRadio` : ``);\r\nconst V_MODEL_CHECKBOX = Symbol((process.env.NODE_ENV !== 'production') ? `vModelCheckbox` : ``);\r\nconst V_MODEL_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelText` : ``);\r\nconst V_MODEL_SELECT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelSelect` : ``);\r\nconst V_MODEL_DYNAMIC = Symbol((process.env.NODE_ENV !== 'production') ? `vModelDynamic` : ``);\r\nconst V_ON_WITH_MODIFIERS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnModifiersGuard` : ``);\r\nconst V_ON_WITH_KEYS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnKeysGuard` : ``);\r\nconst V_SHOW = Symbol((process.env.NODE_ENV !== 'production') ? `vShow` : ``);\r\nconst TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `Transition` : ``);\r\nconst TRANSITION_GROUP = Symbol((process.env.NODE_ENV !== 'production') ? `TransitionGroup` : ``);\r\nregisterRuntimeHelpers({\r\n [V_MODEL_RADIO]: `vModelRadio`,\r\n [V_MODEL_CHECKBOX]: `vModelCheckbox`,\r\n [V_MODEL_TEXT]: `vModelText`,\r\n [V_MODEL_SELECT]: `vModelSelect`,\r\n [V_MODEL_DYNAMIC]: `vModelDynamic`,\r\n [V_ON_WITH_MODIFIERS]: `withModifiers`,\r\n [V_ON_WITH_KEYS]: `withKeys`,\r\n [V_SHOW]: `vShow`,\r\n [TRANSITION]: `Transition`,\r\n [TRANSITION_GROUP]: `TransitionGroup`\r\n});\n\n/* eslint-disable no-restricted-globals */\r\nlet decoder;\r\nfunction decodeHtmlBrowser(raw, asAttr = false) {\r\n if (!decoder) {\r\n decoder = document.createElement('div');\r\n }\r\n if (asAttr) {\r\n decoder.innerHTML = `<div foo=\"${raw.replace(/\"/g, '"')}\">`;\r\n return decoder.children[0].getAttribute('foo');\r\n }\r\n else {\r\n decoder.innerHTML = raw;\r\n return decoder.textContent;\r\n }\r\n}\n\nconst isRawTextContainer = /*#__PURE__*/ makeMap('style,iframe,script,noscript', true);\r\nconst parserOptions = {\r\n isVoidTag,\r\n isNativeTag: tag => isHTMLTag(tag) || isSVGTag(tag),\r\n isPreTag: tag => tag === 'pre',\r\n decodeEntities: decodeHtmlBrowser ,\r\n isBuiltInComponent: (tag) => {\r\n if (isBuiltInType(tag, `Transition`)) {\r\n return TRANSITION;\r\n }\r\n else if (isBuiltInType(tag, `TransitionGroup`)) {\r\n return TRANSITION_GROUP;\r\n }\r\n },\r\n // https://html.spec.whatwg.org/multipage/parsing.html#tree-construction-dispatcher\r\n getNamespace(tag, parent) {\r\n let ns = parent ? parent.ns : 0 /* HTML */;\r\n if (parent && ns === 2 /* MATH_ML */) {\r\n if (parent.tag === 'annotation-xml') {\r\n if (tag === 'svg') {\r\n return 1 /* SVG */;\r\n }\r\n if (parent.props.some(a => a.type === 6 /* ATTRIBUTE */ &&\r\n a.name === 'encoding' &&\r\n a.value != null &&\r\n (a.value.content === 'text/html' ||\r\n a.value.content === 'application/xhtml+xml'))) {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n else if (/^m(?:[ions]|text)$/.test(parent.tag) &&\r\n tag !== 'mglyph' &&\r\n tag !== 'malignmark') {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n else if (parent && ns === 1 /* SVG */) {\r\n if (parent.tag === 'foreignObject' ||\r\n parent.tag === 'desc' ||\r\n parent.tag === 'title') {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n if (ns === 0 /* HTML */) {\r\n if (tag === 'svg') {\r\n return 1 /* SVG */;\r\n }\r\n if (tag === 'math') {\r\n return 2 /* MATH_ML */;\r\n }\r\n }\r\n return ns;\r\n },\r\n // https://html.spec.whatwg.org/multipage/parsing.html#parsing-html-fragments\r\n getTextMode({ tag, ns }) {\r\n if (ns === 0 /* HTML */) {\r\n if (tag === 'textarea' || tag === 'title') {\r\n return 1 /* RCDATA */;\r\n }\r\n if (isRawTextContainer(tag)) {\r\n return 2 /* RAWTEXT */;\r\n }\r\n }\r\n return 0 /* DATA */;\r\n }\r\n};\n\n// Parse inline CSS strings for static style attributes into an object.\r\n// This is a NodeTransform since it works on the static `style` attribute and\r\n// converts it into a dynamic equivalent:\r\n// style=\"color: red\" -> :style='{ \"color\": \"red\" }'\r\n// It is then processed by `transformElement` and included in the generated\r\n// props.\r\nconst transformStyle = node => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n node.props.forEach((p, i) => {\r\n if (p.type === 6 /* ATTRIBUTE */ && p.name === 'style' && p.value) {\r\n // replace p with an expression node\r\n node.props[i] = {\r\n type: 7 /* DIRECTIVE */,\r\n name: `bind`,\r\n arg: createSimpleExpression(`style`, true, p.loc),\r\n exp: parseInlineCSS(p.value.content, p.loc),\r\n modifiers: [],\r\n loc: p.loc\r\n };\r\n }\r\n });\r\n }\r\n};\r\nconst parseInlineCSS = (cssText, loc) => {\r\n const normalized = parseStringStyle(cssText);\r\n return createSimpleExpression(JSON.stringify(normalized), false, loc, 3 /* CAN_STRINGIFY */);\r\n};\n\nfunction createDOMCompilerError(code, loc) {\r\n return createCompilerError(code, loc, (process.env.NODE_ENV !== 'production') || !true ? DOMErrorMessages : undefined);\r\n}\r\nconst DOMErrorMessages = {\r\n [50 /* X_V_HTML_NO_EXPRESSION */]: `v-html is missing expression.`,\r\n [51 /* X_V_HTML_WITH_CHILDREN */]: `v-html will override element children.`,\r\n [52 /* X_V_TEXT_NO_EXPRESSION */]: `v-text is missing expression.`,\r\n [53 /* X_V_TEXT_WITH_CHILDREN */]: `v-text will override element children.`,\r\n [54 /* X_V_MODEL_ON_INVALID_ELEMENT */]: `v-model can only be used on <input>, <textarea> and <select> elements.`,\r\n [55 /* X_V_MODEL_ARG_ON_ELEMENT */]: `v-model argument is not supported on plain elements.`,\r\n [56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */]: `v-model cannot be used on file inputs since they are read-only. Use a v-on:change listener instead.`,\r\n [57 /* X_V_MODEL_UNNECESSARY_VALUE */]: `Unnecessary value binding used alongside v-model. It will interfere with v-model's behavior.`,\r\n [58 /* X_V_SHOW_NO_EXPRESSION */]: `v-show is missing expression.`,\r\n [59 /* X_TRANSITION_INVALID_CHILDREN */]: `<Transition> expects exactly one child element or component.`,\r\n [60 /* X_IGNORED_SIDE_EFFECT_TAG */]: `Tags with side effect (<script> and <style>) are ignored in client component templates.`\r\n};\n\nconst transformVHtml = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(50 /* X_V_HTML_NO_EXPRESSION */, loc));\r\n }\r\n if (node.children.length) {\r\n context.onError(createDOMCompilerError(51 /* X_V_HTML_WITH_CHILDREN */, loc));\r\n node.children.length = 0;\r\n }\r\n return {\r\n props: [\r\n createObjectProperty(createSimpleExpression(`innerHTML`, true, loc), exp || createSimpleExpression('', true))\r\n ]\r\n };\r\n};\n\nconst transformVText = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(52 /* X_V_TEXT_NO_EXPRESSION */, loc));\r\n }\r\n if (node.children.length) {\r\n context.onError(createDOMCompilerError(53 /* X_V_TEXT_WITH_CHILDREN */, loc));\r\n node.children.length = 0;\r\n }\r\n return {\r\n props: [\r\n createObjectProperty(createSimpleExpression(`textContent`, true), exp\r\n ? createCallExpression(context.helperString(TO_DISPLAY_STRING), [exp], loc)\r\n : createSimpleExpression('', true))\r\n ]\r\n };\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n const baseResult = transformModel$1(dir, node, context);\r\n // base transform has errors OR component v-model (only need props)\r\n if (!baseResult.props.length || node.tagType === 1 /* COMPONENT */) {\r\n return baseResult;\r\n }\r\n if (dir.arg) {\r\n context.onError(createDOMCompilerError(55 /* X_V_MODEL_ARG_ON_ELEMENT */, dir.arg.loc));\r\n }\r\n function checkDuplicatedValue() {\r\n const value = findProp(node, 'value');\r\n if (value) {\r\n context.onError(createDOMCompilerError(57 /* X_V_MODEL_UNNECESSARY_VALUE */, value.loc));\r\n }\r\n }\r\n const { tag } = node;\r\n const isCustomElement = context.isCustomElement(tag);\r\n if (tag === 'input' ||\r\n tag === 'textarea' ||\r\n tag === 'select' ||\r\n isCustomElement) {\r\n let directiveToUse = V_MODEL_TEXT;\r\n let isInvalidType = false;\r\n if (tag === 'input' || isCustomElement) {\r\n const type = findProp(node, `type`);\r\n if (type) {\r\n if (type.type === 7 /* DIRECTIVE */) {\r\n // :type=\"foo\"\r\n directiveToUse = V_MODEL_DYNAMIC;\r\n }\r\n else if (type.value) {\r\n switch (type.value.content) {\r\n case 'radio':\r\n directiveToUse = V_MODEL_RADIO;\r\n break;\r\n case 'checkbox':\r\n directiveToUse = V_MODEL_CHECKBOX;\r\n break;\r\n case 'file':\r\n isInvalidType = true;\r\n context.onError(createDOMCompilerError(56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */, dir.loc));\r\n break;\r\n default:\r\n // text type\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n break;\r\n }\r\n }\r\n }\r\n else if (hasDynamicKeyVBind(node)) {\r\n // element has bindings with dynamic keys, which can possibly contain\r\n // \"type\".\r\n directiveToUse = V_MODEL_DYNAMIC;\r\n }\r\n else {\r\n // text type\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n }\r\n }\r\n else if (tag === 'select') {\r\n directiveToUse = V_MODEL_SELECT;\r\n }\r\n else {\r\n // textarea\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n }\r\n // inject runtime directive\r\n // by returning the helper symbol via needRuntime\r\n // the import will replaced a resolveDirective call.\r\n if (!isInvalidType) {\r\n baseResult.needRuntime = context.helper(directiveToUse);\r\n }\r\n }\r\n else {\r\n context.onError(createDOMCompilerError(54 /* X_V_MODEL_ON_INVALID_ELEMENT */, dir.loc));\r\n }\r\n // native vmodel doesn't need the `modelValue` props since they are also\r\n // passed to the runtime as `binding.value`. removing it reduces code size.\r\n baseResult.props = baseResult.props.filter(p => !(p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n p.key.content === 'modelValue'));\r\n return baseResult;\r\n};\n\nconst isEventOptionModifier = /*#__PURE__*/ makeMap(`passive,once,capture`);\r\nconst isNonKeyModifier = /*#__PURE__*/ makeMap(\r\n// event propagation management\r\n`stop,prevent,self,` +\r\n // system modifiers + exact\r\n `ctrl,shift,alt,meta,exact,` +\r\n // mouse\r\n `middle`);\r\n// left & right could be mouse or key modifiers based on event type\r\nconst maybeKeyModifier = /*#__PURE__*/ makeMap('left,right');\r\nconst isKeyboardEvent = /*#__PURE__*/ makeMap(`onkeyup,onkeydown,onkeypress`, true);\r\nconst resolveModifiers = (key, modifiers, context, loc) => {\r\n const keyModifiers = [];\r\n const nonKeyModifiers = [];\r\n const eventOptionModifiers = [];\r\n for (let i = 0; i < modifiers.length; i++) {\r\n const modifier = modifiers[i];\r\n if (modifier === 'native' &&\r\n checkCompatEnabled(\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */, context, loc)) {\r\n eventOptionModifiers.push(modifier);\r\n }\r\n else if (isEventOptionModifier(modifier)) {\r\n // eventOptionModifiers: modifiers for addEventListener() options,\r\n // e.g. .passive & .capture\r\n eventOptionModifiers.push(modifier);\r\n }\r\n else {\r\n // runtimeModifiers: modifiers that needs runtime guards\r\n if (maybeKeyModifier(modifier)) {\r\n if (isStaticExp(key)) {\r\n if (isKeyboardEvent(key.content)) {\r\n keyModifiers.push(modifier);\r\n }\r\n else {\r\n nonKeyModifiers.push(modifier);\r\n }\r\n }\r\n else {\r\n keyModifiers.push(modifier);\r\n nonKeyModifiers.push(modifier);\r\n }\r\n }\r\n else {\r\n if (isNonKeyModifier(modifier)) {\r\n nonKeyModifiers.push(modifier);\r\n }\r\n else {\r\n keyModifiers.push(modifier);\r\n }\r\n }\r\n }\r\n }\r\n return {\r\n keyModifiers,\r\n nonKeyModifiers,\r\n eventOptionModifiers\r\n };\r\n};\r\nconst transformClick = (key, event) => {\r\n const isStaticClick = isStaticExp(key) && key.content.toLowerCase() === 'onclick';\r\n return isStaticClick\r\n ? createSimpleExpression(event, true)\r\n : key.type !== 4 /* SIMPLE_EXPRESSION */\r\n ? createCompoundExpression([\r\n `(`,\r\n key,\r\n `) === \"onClick\" ? \"${event}\" : (`,\r\n key,\r\n `)`\r\n ])\r\n : key;\r\n};\r\nconst transformOn = (dir, node, context) => {\r\n return transformOn$1(dir, node, context, baseResult => {\r\n const { modifiers } = dir;\r\n if (!modifiers.length)\r\n return baseResult;\r\n let { key, value: handlerExp } = baseResult.props[0];\r\n const { keyModifiers, nonKeyModifiers, eventOptionModifiers } = resolveModifiers(key, modifiers, context, dir.loc);\r\n // normalize click.right and click.middle since they don't actually fire\r\n if (nonKeyModifiers.includes('right')) {\r\n key = transformClick(key, `onContextmenu`);\r\n }\r\n if (nonKeyModifiers.includes('middle')) {\r\n key = transformClick(key, `onMouseup`);\r\n }\r\n if (nonKeyModifiers.length) {\r\n handlerExp = createCallExpression(context.helper(V_ON_WITH_MODIFIERS), [\r\n handlerExp,\r\n JSON.stringify(nonKeyModifiers)\r\n ]);\r\n }\r\n if (keyModifiers.length &&\r\n // if event name is dynamic, always wrap with keys guard\r\n (!isStaticExp(key) || isKeyboardEvent(key.content))) {\r\n handlerExp = createCallExpression(context.helper(V_ON_WITH_KEYS), [\r\n handlerExp,\r\n JSON.stringify(keyModifiers)\r\n ]);\r\n }\r\n if (eventOptionModifiers.length) {\r\n const modifierPostfix = eventOptionModifiers.map(capitalize).join('');\r\n key = isStaticExp(key)\r\n ? createSimpleExpression(`${key.content}${modifierPostfix}`, true)\r\n : createCompoundExpression([`(`, key, `) + \"${modifierPostfix}\"`]);\r\n }\r\n return {\r\n props: [createObjectProperty(key, handlerExp)]\r\n };\r\n });\r\n};\n\nconst transformShow = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(58 /* X_V_SHOW_NO_EXPRESSION */, loc));\r\n }\r\n return {\r\n props: [],\r\n needRuntime: context.helper(V_SHOW)\r\n };\r\n};\n\nconst warnTransitionChildren = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 1 /* COMPONENT */) {\r\n const component = context.isBuiltInComponent(node.tag);\r\n if (component === TRANSITION) {\r\n return () => {\r\n if (node.children.length && hasMultipleChildren(node)) {\r\n context.onError(createDOMCompilerError(59 /* X_TRANSITION_INVALID_CHILDREN */, {\r\n start: node.children[0].loc.start,\r\n end: node.children[node.children.length - 1].loc.end,\r\n source: ''\r\n }));\r\n }\r\n };\r\n }\r\n }\r\n};\r\nfunction hasMultipleChildren(node) {\r\n // #1352 filter out potential comment nodes.\r\n const children = (node.children = node.children.filter(c => c.type !== 3 /* COMMENT */ &&\r\n !(c.type === 2 /* TEXT */ && !c.content.trim())));\r\n const child = children[0];\r\n return (children.length !== 1 ||\r\n child.type === 11 /* FOR */ ||\r\n (child.type === 9 /* IF */ && child.branches.some(hasMultipleChildren)));\r\n}\n\nconst ignoreSideEffectTags = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n (node.tag === 'script' || node.tag === 'style')) {\r\n context.onError(createDOMCompilerError(60 /* X_IGNORED_SIDE_EFFECT_TAG */, node.loc));\r\n context.removeNode();\r\n }\r\n};\n\nconst DOMNodeTransforms = [\r\n transformStyle,\r\n ...((process.env.NODE_ENV !== 'production') ? [warnTransitionChildren] : [])\r\n];\r\nconst DOMDirectiveTransforms = {\r\n cloak: noopDirectiveTransform,\r\n html: transformVHtml,\r\n text: transformVText,\r\n model: transformModel,\r\n on: transformOn,\r\n show: transformShow\r\n};\r\nfunction compile(template, options = {}) {\r\n return baseCompile(template, extend({}, parserOptions, options, {\r\n nodeTransforms: [\r\n // ignore <script> and <tag>\r\n // this is not put inside DOMNodeTransforms because that list is used\r\n // by compiler-ssr to generate vnode fallback branches\r\n ignoreSideEffectTags,\r\n ...DOMNodeTransforms,\r\n ...(options.nodeTransforms || [])\r\n ],\r\n directiveTransforms: extend({}, DOMDirectiveTransforms, options.directiveTransforms || {}),\r\n transformHoist: null \r\n }));\r\n}\r\nfunction parse(template, options = {}) {\r\n return baseParse(template, extend({}, parserOptions, options));\r\n}\n\nexport { DOMDirectiveTransforms, DOMNodeTransforms, TRANSITION, TRANSITION_GROUP, V_MODEL_CHECKBOX, V_MODEL_DYNAMIC, V_MODEL_RADIO, V_MODEL_SELECT, V_MODEL_TEXT, V_ON_WITH_KEYS, V_ON_WITH_MODIFIERS, V_SHOW, compile, createDOMCompilerError, parse, parserOptions, transformStyle };\n","import * as runtimeDom from '@vue/runtime-dom';\nimport { initCustomFormatter, warn, registerRuntimeCompiler } from '@vue/runtime-dom';\nexport * from '@vue/runtime-dom';\nimport { compile } from '@vue/compiler-dom';\nimport { isString, NOOP, extend, generateCodeFrame } from '@vue/shared';\n\nfunction initDev() {\r\n {\r\n initCustomFormatter();\r\n }\r\n}\n\n// This entry is the \"full-build\" that includes both the runtime\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n initDev();\r\n}\r\nconst compileCache = Object.create(null);\r\nfunction compileToFunction(template, options) {\r\n if (!isString(template)) {\r\n if (template.nodeType) {\r\n template = template.innerHTML;\r\n }\r\n else {\r\n (process.env.NODE_ENV !== 'production') && warn(`invalid template option: `, template);\r\n return NOOP;\r\n }\r\n }\r\n const key = template;\r\n const cached = compileCache[key];\r\n if (cached) {\r\n return cached;\r\n }\r\n if (template[0] === '#') {\r\n const el = document.querySelector(template);\r\n if ((process.env.NODE_ENV !== 'production') && !el) {\r\n warn(`Template element not found or is empty: ${template}`);\r\n }\r\n // __UNSAFE__\r\n // Reason: potential execution of JS expressions in in-DOM template.\r\n // The user must make sure the in-DOM template is trusted. If it's rendered\r\n // by the server, the template should not contain any user data.\r\n template = el ? el.innerHTML : ``;\r\n }\r\n const { code } = compile(template, extend({\r\n hoistStatic: true,\r\n onError: (process.env.NODE_ENV !== 'production') ? onError : undefined,\r\n onWarn: (process.env.NODE_ENV !== 'production') ? e => onError(e, true) : NOOP\r\n }, options));\r\n function onError(err, asWarning = false) {\r\n const message = asWarning\r\n ? err.message\r\n : `Template compilation error: ${err.message}`;\r\n const codeFrame = err.loc &&\r\n generateCodeFrame(template, err.loc.start.offset, err.loc.end.offset);\r\n warn(codeFrame ? `${message}\\n${codeFrame}` : message);\r\n }\r\n // The wildcard import results in a huge object with every export\r\n // with keys that cannot be mangled, and can be quite heavy size-wise.\r\n // In the global build we know `Vue` is available globally so we can avoid\r\n // the wildcard object.\r\n const render = (new Function('Vue', code)(runtimeDom));\r\n render._rc = true;\r\n return (compileCache[key] = render);\r\n}\r\nregisterRuntimeCompiler(compileToFunction);\n\nexport { compileToFunction as compile };\n","(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory(require(\"vue\"), require(\"sortablejs\"));\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([, \"sortablejs\"], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"vuedraggable\"] = factory(require(\"vue\"), require(\"sortablejs\"));\n\telse\n\t\troot[\"vuedraggable\"] = factory(root[\"Vue\"], root[\"Sortable\"]);\n})((typeof self !== 'undefined' ? self : this), function(__WEBPACK_EXTERNAL_MODULE__8bbf__, __WEBPACK_EXTERNAL_MODULE_a352__) {\nreturn /******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n/******/\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n/******/\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId]) {\n/******/ \t\t\treturn installedModules[moduleId].exports;\n/******/ \t\t}\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\ti: moduleId,\n/******/ \t\t\tl: false,\n/******/ \t\t\texports: {}\n/******/ \t\t};\n/******/\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n/******/\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.l = true;\n/******/\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n/******/\n/******/\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n/******/\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n/******/\n/******/ \t// define getter function for harmony exports\n/******/ \t__webpack_require__.d = function(exports, name, getter) {\n/******/ \t\tif(!__webpack_require__.o(exports, name)) {\n/******/ \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n/******/ \t\t}\n/******/ \t};\n/******/\n/******/ \t// define __esModule on exports\n/******/ \t__webpack_require__.r = function(exports) {\n/******/ \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n/******/ \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n/******/ \t\t}\n/******/ \t\tObject.defineProperty(exports, '__esModule', { value: true });\n/******/ \t};\n/******/\n/******/ \t// create a fake namespace object\n/******/ \t// mode & 1: value is a module id, require it\n/******/ \t// mode & 2: merge all properties of value into the ns\n/******/ \t// mode & 4: return value when already ns object\n/******/ \t// mode & 8|1: behave like require\n/******/ \t__webpack_require__.t = function(value, mode) {\n/******/ \t\tif(mode & 1) value = __webpack_require__(value);\n/******/ \t\tif(mode & 8) return value;\n/******/ \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n/******/ \t\tvar ns = Object.create(null);\n/******/ \t\t__webpack_require__.r(ns);\n/******/ \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n/******/ \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n/******/ \t\treturn ns;\n/******/ \t};\n/******/\n/******/ \t// getDefaultExport function for compatibility with non-harmony modules\n/******/ \t__webpack_require__.n = function(module) {\n/******/ \t\tvar getter = module && module.__esModule ?\n/******/ \t\t\tfunction getDefault() { return module['default']; } :\n/******/ \t\t\tfunction getModuleExports() { return module; };\n/******/ \t\t__webpack_require__.d(getter, 'a', getter);\n/******/ \t\treturn getter;\n/******/ \t};\n/******/\n/******/ \t// Object.prototype.hasOwnProperty.call\n/******/ \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n/******/\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n/******/\n/******/\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n/******/ })\n/************************************************************************/\n/******/ ({\n\n/***/ \"00ee\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n\n\n/***/ }),\n\n/***/ \"0366\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar aFunction = __webpack_require__(\"1c0b\");\n\n// optional / simple context binding\nmodule.exports = function (fn, that, length) {\n aFunction(fn);\n if (that === undefined) return fn;\n switch (length) {\n case 0: return function () {\n return fn.call(that);\n };\n case 1: return function (a) {\n return fn.call(that, a);\n };\n case 2: return function (a, b) {\n return fn.call(that, a, b);\n };\n case 3: return function (a, b, c) {\n return fn.call(that, a, b, c);\n };\n }\n return function (/* ...args */) {\n return fn.apply(that, arguments);\n };\n};\n\n\n/***/ }),\n\n/***/ \"057f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar nativeGetOwnPropertyNames = __webpack_require__(\"241c\").f;\n\nvar toString = {}.toString;\n\nvar windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames\n ? Object.getOwnPropertyNames(window) : [];\n\nvar getWindowNames = function (it) {\n try {\n return nativeGetOwnPropertyNames(it);\n } catch (error) {\n return windowNames.slice();\n }\n};\n\n// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window\nmodule.exports.f = function getOwnPropertyNames(it) {\n return windowNames && toString.call(it) == '[object Window]'\n ? getWindowNames(it)\n : nativeGetOwnPropertyNames(toIndexedObject(it));\n};\n\n\n/***/ }),\n\n/***/ \"06cf\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar propertyIsEnumerableModule = __webpack_require__(\"d1e7\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar toPrimitive = __webpack_require__(\"c04e\");\nvar has = __webpack_require__(\"5135\");\nvar IE8_DOM_DEFINE = __webpack_require__(\"0cfb\");\n\nvar nativeGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? nativeGetOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPrimitive(P, true);\n if (IE8_DOM_DEFINE) try {\n return nativeGetOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (has(O, P)) return createPropertyDescriptor(!propertyIsEnumerableModule.f.call(O, P), O[P]);\n};\n\n\n/***/ }),\n\n/***/ \"0cfb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar fails = __webpack_require__(\"d039\");\nvar createElement = __webpack_require__(\"cc12\");\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a != 7;\n});\n\n\n/***/ }),\n\n/***/ \"13d5\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $reduce = __webpack_require__(\"d58f\").left;\nvar arrayMethodIsStrict = __webpack_require__(\"a640\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar STRICT_METHOD = arrayMethodIsStrict('reduce');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('reduce', { 1: 0 });\n\n// `Array.prototype.reduce` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.reduce\n$({ target: 'Array', proto: true, forced: !STRICT_METHOD || !USES_TO_LENGTH }, {\n reduce: function reduce(callbackfn /* , initialValue */) {\n return $reduce(this, callbackfn, arguments.length, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"14c3\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar classof = __webpack_require__(\"c6b6\");\nvar regexpExec = __webpack_require__(\"9263\");\n\n// `RegExpExec` abstract operation\n// https://tc39.github.io/ecma262/#sec-regexpexec\nmodule.exports = function (R, S) {\n var exec = R.exec;\n if (typeof exec === 'function') {\n var result = exec.call(R, S);\n if (typeof result !== 'object') {\n throw TypeError('RegExp exec method returned something other than an Object or null');\n }\n return result;\n }\n\n if (classof(R) !== 'RegExp') {\n throw TypeError('RegExp#exec called on incompatible receiver');\n }\n\n return regexpExec.call(R, S);\n};\n\n\n\n/***/ }),\n\n/***/ \"159b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar DOMIterables = __webpack_require__(\"fdbc\");\nvar forEach = __webpack_require__(\"17c2\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\n\nfor (var COLLECTION_NAME in DOMIterables) {\n var Collection = global[COLLECTION_NAME];\n var CollectionPrototype = Collection && Collection.prototype;\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype && CollectionPrototype.forEach !== forEach) try {\n createNonEnumerableProperty(CollectionPrototype, 'forEach', forEach);\n } catch (error) {\n CollectionPrototype.forEach = forEach;\n }\n}\n\n\n/***/ }),\n\n/***/ \"17c2\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $forEach = __webpack_require__(\"b727\").forEach;\nvar arrayMethodIsStrict = __webpack_require__(\"a640\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar STRICT_METHOD = arrayMethodIsStrict('forEach');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('forEach');\n\n// `Array.prototype.forEach` method implementation\n// https://tc39.github.io/ecma262/#sec-array.prototype.foreach\nmodule.exports = (!STRICT_METHOD || !USES_TO_LENGTH) ? function forEach(callbackfn /* , thisArg */) {\n return $forEach(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n} : [].forEach;\n\n\n/***/ }),\n\n/***/ \"1be4\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar getBuiltIn = __webpack_require__(\"d066\");\n\nmodule.exports = getBuiltIn('document', 'documentElement');\n\n\n/***/ }),\n\n/***/ \"1c0b\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (it) {\n if (typeof it != 'function') {\n throw TypeError(String(it) + ' is not a function');\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"1c7e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar SAFE_CLOSING = false;\n\ntry {\n var called = 0;\n var iteratorWithReturn = {\n next: function () {\n return { done: !!called++ };\n },\n 'return': function () {\n SAFE_CLOSING = true;\n }\n };\n iteratorWithReturn[ITERATOR] = function () {\n return this;\n };\n // eslint-disable-next-line no-throw-literal\n Array.from(iteratorWithReturn, function () { throw 2; });\n} catch (error) { /* empty */ }\n\nmodule.exports = function (exec, SKIP_CLOSING) {\n if (!SKIP_CLOSING && !SAFE_CLOSING) return false;\n var ITERATION_SUPPORT = false;\n try {\n var object = {};\n object[ITERATOR] = function () {\n return {\n next: function () {\n return { done: ITERATION_SUPPORT = true };\n }\n };\n };\n exec(object);\n } catch (error) { /* empty */ }\n return ITERATION_SUPPORT;\n};\n\n\n/***/ }),\n\n/***/ \"1d80\":\n/***/ (function(module, exports) {\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.github.io/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (it == undefined) throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n\n\n/***/ }),\n\n/***/ \"1dde\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar V8_VERSION = __webpack_require__(\"2d00\");\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (METHOD_NAME) {\n // We can't use this feature detection in V8 since it causes\n // deoptimization and serious performance degradation\n // https://github.com/zloirock/core-js/issues/677\n return V8_VERSION >= 51 || !fails(function () {\n var array = [];\n var constructor = array.constructor = {};\n constructor[SPECIES] = function () {\n return { foo: 1 };\n };\n return array[METHOD_NAME](Boolean).foo !== 1;\n });\n};\n\n\n/***/ }),\n\n/***/ \"23cb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toInteger = __webpack_require__(\"a691\");\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toInteger(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n\n\n/***/ }),\n\n/***/ \"23e7\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar getOwnPropertyDescriptor = __webpack_require__(\"06cf\").f;\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar setGlobal = __webpack_require__(\"ce4e\");\nvar copyConstructorProperties = __webpack_require__(\"e893\");\nvar isForced = __webpack_require__(\"94ca\");\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.noTargetGet - prevent calling a getter on target\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var FORCED, target, key, targetProperty, sourceProperty, descriptor;\n if (GLOBAL) {\n target = global;\n } else if (STATIC) {\n target = global[TARGET] || setGlobal(TARGET, {});\n } else {\n target = (global[TARGET] || {}).prototype;\n }\n if (target) for (key in source) {\n sourceProperty = source[key];\n if (options.noTargetGet) {\n descriptor = getOwnPropertyDescriptor(target, key);\n targetProperty = descriptor && descriptor.value;\n } else targetProperty = target[key];\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contained in target\n if (!FORCED && targetProperty !== undefined) {\n if (typeof sourceProperty === typeof targetProperty) continue;\n copyConstructorProperties(sourceProperty, targetProperty);\n }\n // add a flag to not completely full polyfills\n if (options.sham || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(sourceProperty, 'sham', true);\n }\n // extend global\n redefine(target, key, sourceProperty, options);\n }\n};\n\n\n/***/ }),\n\n/***/ \"241c\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar internalObjectKeys = __webpack_require__(\"ca84\");\nvar enumBugKeys = __webpack_require__(\"7839\");\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertynames\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n\n\n/***/ }),\n\n/***/ \"25f0\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar redefine = __webpack_require__(\"6eeb\");\nvar anObject = __webpack_require__(\"825a\");\nvar fails = __webpack_require__(\"d039\");\nvar flags = __webpack_require__(\"ad6d\");\n\nvar TO_STRING = 'toString';\nvar RegExpPrototype = RegExp.prototype;\nvar nativeToString = RegExpPrototype[TO_STRING];\n\nvar NOT_GENERIC = fails(function () { return nativeToString.call({ source: 'a', flags: 'b' }) != '/a/b'; });\n// FF44- RegExp#toString has a wrong name\nvar INCORRECT_NAME = nativeToString.name != TO_STRING;\n\n// `RegExp.prototype.toString` method\n// https://tc39.github.io/ecma262/#sec-regexp.prototype.tostring\nif (NOT_GENERIC || INCORRECT_NAME) {\n redefine(RegExp.prototype, TO_STRING, function toString() {\n var R = anObject(this);\n var p = String(R.source);\n var rf = R.flags;\n var f = String(rf === undefined && R instanceof RegExp && !('flags' in RegExpPrototype) ? flags.call(R) : rf);\n return '/' + p + '/' + f;\n }, { unsafe: true });\n}\n\n\n/***/ }),\n\n/***/ \"2ca0\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar getOwnPropertyDescriptor = __webpack_require__(\"06cf\").f;\nvar toLength = __webpack_require__(\"50c4\");\nvar notARegExp = __webpack_require__(\"5a34\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\nvar correctIsRegExpLogic = __webpack_require__(\"ab13\");\nvar IS_PURE = __webpack_require__(\"c430\");\n\nvar nativeStartsWith = ''.startsWith;\nvar min = Math.min;\n\nvar CORRECT_IS_REGEXP_LOGIC = correctIsRegExpLogic('startsWith');\n// https://github.com/zloirock/core-js/pull/702\nvar MDN_POLYFILL_BUG = !IS_PURE && !CORRECT_IS_REGEXP_LOGIC && !!function () {\n var descriptor = getOwnPropertyDescriptor(String.prototype, 'startsWith');\n return descriptor && !descriptor.writable;\n}();\n\n// `String.prototype.startsWith` method\n// https://tc39.github.io/ecma262/#sec-string.prototype.startswith\n$({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_REGEXP_LOGIC }, {\n startsWith: function startsWith(searchString /* , position = 0 */) {\n var that = String(requireObjectCoercible(this));\n notARegExp(searchString);\n var index = toLength(min(arguments.length > 1 ? arguments[1] : undefined, that.length));\n var search = String(searchString);\n return nativeStartsWith\n ? nativeStartsWith.call(that, search, index)\n : that.slice(index, index + search.length) === search;\n }\n});\n\n\n/***/ }),\n\n/***/ \"2d00\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar userAgent = __webpack_require__(\"342f\");\n\nvar process = global.process;\nvar versions = process && process.versions;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n version = match[0] + match[1];\n} else if (userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = match[1];\n }\n}\n\nmodule.exports = version && +version;\n\n\n/***/ }),\n\n/***/ \"342f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar getBuiltIn = __webpack_require__(\"d066\");\n\nmodule.exports = getBuiltIn('navigator', 'userAgent') || '';\n\n\n/***/ }),\n\n/***/ \"35a1\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar classof = __webpack_require__(\"f5df\");\nvar Iterators = __webpack_require__(\"3f8c\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\n\nmodule.exports = function (it) {\n if (it != undefined) return it[ITERATOR]\n || it['@@iterator']\n || Iterators[classof(it)];\n};\n\n\n/***/ }),\n\n/***/ \"37e8\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar anObject = __webpack_require__(\"825a\");\nvar objectKeys = __webpack_require__(\"df75\");\n\n// `Object.defineProperties` method\n// https://tc39.github.io/ecma262/#sec-object.defineproperties\nmodule.exports = DESCRIPTORS ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n while (length > index) definePropertyModule.f(O, key = keys[index++], Properties[key]);\n return O;\n};\n\n\n/***/ }),\n\n/***/ \"3bbe\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\n\nmodule.exports = function (it) {\n if (!isObject(it) && it !== null) {\n throw TypeError(\"Can't set \" + String(it) + ' as a prototype');\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"3ca3\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar charAt = __webpack_require__(\"6547\").charAt;\nvar InternalStateModule = __webpack_require__(\"69f3\");\nvar defineIterator = __webpack_require__(\"7dd0\");\n\nvar STRING_ITERATOR = 'String Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);\n\n// `String.prototype[@@iterator]` method\n// https://tc39.github.io/ecma262/#sec-string.prototype-@@iterator\ndefineIterator(String, 'String', function (iterated) {\n setInternalState(this, {\n type: STRING_ITERATOR,\n string: String(iterated),\n index: 0\n });\n// `%StringIteratorPrototype%.next` method\n// https://tc39.github.io/ecma262/#sec-%stringiteratorprototype%.next\n}, function next() {\n var state = getInternalState(this);\n var string = state.string;\n var index = state.index;\n var point;\n if (index >= string.length) return { value: undefined, done: true };\n point = charAt(string, index);\n state.index += point.length;\n return { value: point, done: false };\n});\n\n\n/***/ }),\n\n/***/ \"3f8c\":\n/***/ (function(module, exports) {\n\nmodule.exports = {};\n\n\n/***/ }),\n\n/***/ \"4160\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar forEach = __webpack_require__(\"17c2\");\n\n// `Array.prototype.forEach` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.foreach\n$({ target: 'Array', proto: true, forced: [].forEach != forEach }, {\n forEach: forEach\n});\n\n\n/***/ }),\n\n/***/ \"428f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\n\nmodule.exports = global;\n\n\n/***/ }),\n\n/***/ \"44ad\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\nvar classof = __webpack_require__(\"c6b6\");\n\nvar split = ''.split;\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins\n return !Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) == 'String' ? split.call(it, '') : Object(it);\n} : Object;\n\n\n/***/ }),\n\n/***/ \"44d2\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar create = __webpack_require__(\"7c73\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\n\nvar UNSCOPABLES = wellKnownSymbol('unscopables');\nvar ArrayPrototype = Array.prototype;\n\n// Array.prototype[@@unscopables]\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\nif (ArrayPrototype[UNSCOPABLES] == undefined) {\n definePropertyModule.f(ArrayPrototype, UNSCOPABLES, {\n configurable: true,\n value: create(null)\n });\n}\n\n// add a key to Array.prototype[@@unscopables]\nmodule.exports = function (key) {\n ArrayPrototype[UNSCOPABLES][key] = true;\n};\n\n\n/***/ }),\n\n/***/ \"44e7\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\nvar classof = __webpack_require__(\"c6b6\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar MATCH = wellKnownSymbol('match');\n\n// `IsRegExp` abstract operation\n// https://tc39.github.io/ecma262/#sec-isregexp\nmodule.exports = function (it) {\n var isRegExp;\n return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classof(it) == 'RegExp');\n};\n\n\n/***/ }),\n\n/***/ \"4930\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n // Chrome 38 Symbol has incorrect toString conversion\n // eslint-disable-next-line no-undef\n return !String(Symbol());\n});\n\n\n/***/ }),\n\n/***/ \"4d64\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toAbsoluteIndex = __webpack_require__(\"23cb\");\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = toLength(O.length);\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare\n if (IS_INCLUDES && el != el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare\n if (value != value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n\n\n/***/ }),\n\n/***/ \"4de4\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $filter = __webpack_require__(\"b727\").filter;\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('filter');\n// Edge 14- issue\nvar USES_TO_LENGTH = arrayMethodUsesToLength('filter');\n\n// `Array.prototype.filter` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.filter\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n filter: function filter(callbackfn /* , thisArg */) {\n return $filter(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"4df4\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar bind = __webpack_require__(\"0366\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar callWithSafeIterationClosing = __webpack_require__(\"9bdd\");\nvar isArrayIteratorMethod = __webpack_require__(\"e95a\");\nvar toLength = __webpack_require__(\"50c4\");\nvar createProperty = __webpack_require__(\"8418\");\nvar getIteratorMethod = __webpack_require__(\"35a1\");\n\n// `Array.from` method implementation\n// https://tc39.github.io/ecma262/#sec-array.from\nmodule.exports = function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {\n var O = toObject(arrayLike);\n var C = typeof this == 'function' ? this : Array;\n var argumentsLength = arguments.length;\n var mapfn = argumentsLength > 1 ? arguments[1] : undefined;\n var mapping = mapfn !== undefined;\n var iteratorMethod = getIteratorMethod(O);\n var index = 0;\n var length, result, step, iterator, next, value;\n if (mapping) mapfn = bind(mapfn, argumentsLength > 2 ? arguments[2] : undefined, 2);\n // if the target is not iterable or it's an array with the default iterator - use a simple case\n if (iteratorMethod != undefined && !(C == Array && isArrayIteratorMethod(iteratorMethod))) {\n iterator = iteratorMethod.call(O);\n next = iterator.next;\n result = new C();\n for (;!(step = next.call(iterator)).done; index++) {\n value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value;\n createProperty(result, index, value);\n }\n } else {\n length = toLength(O.length);\n result = new C(length);\n for (;length > index; index++) {\n value = mapping ? mapfn(O[index], index) : O[index];\n createProperty(result, index, value);\n }\n }\n result.length = index;\n return result;\n};\n\n\n/***/ }),\n\n/***/ \"4fad\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar $entries = __webpack_require__(\"6f53\").entries;\n\n// `Object.entries` method\n// https://tc39.github.io/ecma262/#sec-object.entries\n$({ target: 'Object', stat: true }, {\n entries: function entries(O) {\n return $entries(O);\n }\n});\n\n\n/***/ }),\n\n/***/ \"50c4\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toInteger = __webpack_require__(\"a691\");\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.github.io/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n return argument > 0 ? min(toInteger(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n\n\n/***/ }),\n\n/***/ \"5135\":\n/***/ (function(module, exports) {\n\nvar hasOwnProperty = {}.hasOwnProperty;\n\nmodule.exports = function (it, key) {\n return hasOwnProperty.call(it, key);\n};\n\n\n/***/ }),\n\n/***/ \"5319\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar fixRegExpWellKnownSymbolLogic = __webpack_require__(\"d784\");\nvar anObject = __webpack_require__(\"825a\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toInteger = __webpack_require__(\"a691\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\nvar advanceStringIndex = __webpack_require__(\"8aa5\");\nvar regExpExec = __webpack_require__(\"14c3\");\n\nvar max = Math.max;\nvar min = Math.min;\nvar floor = Math.floor;\nvar SUBSTITUTION_SYMBOLS = /\\$([$&'`]|\\d\\d?|<[^>]*>)/g;\nvar SUBSTITUTION_SYMBOLS_NO_NAMED = /\\$([$&'`]|\\d\\d?)/g;\n\nvar maybeToString = function (it) {\n return it === undefined ? it : String(it);\n};\n\n// @@replace logic\nfixRegExpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, maybeCallNative, reason) {\n var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = reason.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE;\n var REPLACE_KEEPS_$0 = reason.REPLACE_KEEPS_$0;\n var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';\n\n return [\n // `String.prototype.replace` method\n // https://tc39.github.io/ecma262/#sec-string.prototype.replace\n function replace(searchValue, replaceValue) {\n var O = requireObjectCoercible(this);\n var replacer = searchValue == undefined ? undefined : searchValue[REPLACE];\n return replacer !== undefined\n ? replacer.call(searchValue, O, replaceValue)\n : nativeReplace.call(String(O), searchValue, replaceValue);\n },\n // `RegExp.prototype[@@replace]` method\n // https://tc39.github.io/ecma262/#sec-regexp.prototype-@@replace\n function (regexp, replaceValue) {\n if (\n (!REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE && REPLACE_KEEPS_$0) ||\n (typeof replaceValue === 'string' && replaceValue.indexOf(UNSAFE_SUBSTITUTE) === -1)\n ) {\n var res = maybeCallNative(nativeReplace, regexp, this, replaceValue);\n if (res.done) return res.value;\n }\n\n var rx = anObject(regexp);\n var S = String(this);\n\n var functionalReplace = typeof replaceValue === 'function';\n if (!functionalReplace) replaceValue = String(replaceValue);\n\n var global = rx.global;\n if (global) {\n var fullUnicode = rx.unicode;\n rx.lastIndex = 0;\n }\n var results = [];\n while (true) {\n var result = regExpExec(rx, S);\n if (result === null) break;\n\n results.push(result);\n if (!global) break;\n\n var matchStr = String(result[0]);\n if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);\n }\n\n var accumulatedResult = '';\n var nextSourcePosition = 0;\n for (var i = 0; i < results.length; i++) {\n result = results[i];\n\n var matched = String(result[0]);\n var position = max(min(toInteger(result.index), S.length), 0);\n var captures = [];\n // NOTE: This is equivalent to\n // captures = result.slice(1).map(maybeToString)\n // but for some reason `nativeSlice.call(result, 1, result.length)` (called in\n // the slice polyfill when slicing native arrays) \"doesn't work\" in safari 9 and\n // causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.\n for (var j = 1; j < result.length; j++) captures.push(maybeToString(result[j]));\n var namedCaptures = result.groups;\n if (functionalReplace) {\n var replacerArgs = [matched].concat(captures, position, S);\n if (namedCaptures !== undefined) replacerArgs.push(namedCaptures);\n var replacement = String(replaceValue.apply(undefined, replacerArgs));\n } else {\n replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);\n }\n if (position >= nextSourcePosition) {\n accumulatedResult += S.slice(nextSourcePosition, position) + replacement;\n nextSourcePosition = position + matched.length;\n }\n }\n return accumulatedResult + S.slice(nextSourcePosition);\n }\n ];\n\n // https://tc39.github.io/ecma262/#sec-getsubstitution\n function getSubstitution(matched, str, position, captures, namedCaptures, replacement) {\n var tailPos = position + matched.length;\n var m = captures.length;\n var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;\n if (namedCaptures !== undefined) {\n namedCaptures = toObject(namedCaptures);\n symbols = SUBSTITUTION_SYMBOLS;\n }\n return nativeReplace.call(replacement, symbols, function (match, ch) {\n var capture;\n switch (ch.charAt(0)) {\n case '$': return '$';\n case '&': return matched;\n case '`': return str.slice(0, position);\n case \"'\": return str.slice(tailPos);\n case '<':\n capture = namedCaptures[ch.slice(1, -1)];\n break;\n default: // \\d\\d?\n var n = +ch;\n if (n === 0) return match;\n if (n > m) {\n var f = floor(n / 10);\n if (f === 0) return match;\n if (f <= m) return captures[f - 1] === undefined ? ch.charAt(1) : captures[f - 1] + ch.charAt(1);\n return match;\n }\n capture = captures[n - 1];\n }\n return capture === undefined ? '' : capture;\n });\n }\n});\n\n\n/***/ }),\n\n/***/ \"5692\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar IS_PURE = __webpack_require__(\"c430\");\nvar store = __webpack_require__(\"c6cd\");\n\n(module.exports = function (key, value) {\n return store[key] || (store[key] = value !== undefined ? value : {});\n})('versions', []).push({\n version: '3.6.5',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2020 Denis Pushkarev (zloirock.ru)'\n});\n\n\n/***/ }),\n\n/***/ \"56ef\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar getBuiltIn = __webpack_require__(\"d066\");\nvar getOwnPropertyNamesModule = __webpack_require__(\"241c\");\nvar getOwnPropertySymbolsModule = __webpack_require__(\"7418\");\nvar anObject = __webpack_require__(\"825a\");\n\n// all object keys, includes non-enumerable and symbols\nmodule.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {\n var keys = getOwnPropertyNamesModule.f(anObject(it));\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return getOwnPropertySymbols ? keys.concat(getOwnPropertySymbols(it)) : keys;\n};\n\n\n/***/ }),\n\n/***/ \"5a34\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isRegExp = __webpack_require__(\"44e7\");\n\nmodule.exports = function (it) {\n if (isRegExp(it)) {\n throw TypeError(\"The method doesn't accept regular expressions\");\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"5c6c\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n\n\n/***/ }),\n\n/***/ \"5db7\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar flattenIntoArray = __webpack_require__(\"a2bf\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar aFunction = __webpack_require__(\"1c0b\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\n\n// `Array.prototype.flatMap` method\n// https://github.com/tc39/proposal-flatMap\n$({ target: 'Array', proto: true }, {\n flatMap: function flatMap(callbackfn /* , thisArg */) {\n var O = toObject(this);\n var sourceLen = toLength(O.length);\n var A;\n aFunction(callbackfn);\n A = arraySpeciesCreate(O, 0);\n A.length = flattenIntoArray(A, O, O, sourceLen, 0, 1, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n return A;\n }\n});\n\n\n/***/ }),\n\n/***/ \"6547\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toInteger = __webpack_require__(\"a691\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\n\n// `String.prototype.{ codePointAt, at }` methods implementation\nvar createMethod = function (CONVERT_TO_STRING) {\n return function ($this, pos) {\n var S = String(requireObjectCoercible($this));\n var position = toInteger(pos);\n var size = S.length;\n var first, second;\n if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;\n first = S.charCodeAt(position);\n return first < 0xD800 || first > 0xDBFF || position + 1 === size\n || (second = S.charCodeAt(position + 1)) < 0xDC00 || second > 0xDFFF\n ? CONVERT_TO_STRING ? S.charAt(position) : first\n : CONVERT_TO_STRING ? S.slice(position, position + 2) : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;\n };\n};\n\nmodule.exports = {\n // `String.prototype.codePointAt` method\n // https://tc39.github.io/ecma262/#sec-string.prototype.codepointat\n codeAt: createMethod(false),\n // `String.prototype.at` method\n // https://github.com/mathiasbynens/String.prototype.at\n charAt: createMethod(true)\n};\n\n\n/***/ }),\n\n/***/ \"65f0\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar SPECIES = wellKnownSymbol('species');\n\n// `ArraySpeciesCreate` abstract operation\n// https://tc39.github.io/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray, length) {\n var C;\n if (isArray(originalArray)) {\n C = originalArray.constructor;\n // cross-realm fallback\n if (typeof C == 'function' && (C === Array || isArray(C.prototype))) C = undefined;\n else if (isObject(C)) {\n C = C[SPECIES];\n if (C === null) C = undefined;\n }\n } return new (C === undefined ? Array : C)(length === 0 ? 0 : length);\n};\n\n\n/***/ }),\n\n/***/ \"69f3\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar NATIVE_WEAK_MAP = __webpack_require__(\"7f9a\");\nvar global = __webpack_require__(\"da84\");\nvar isObject = __webpack_require__(\"861d\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar objectHas = __webpack_require__(\"5135\");\nvar sharedKey = __webpack_require__(\"f772\");\nvar hiddenKeys = __webpack_require__(\"d012\");\n\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP) {\n var store = new WeakMap();\n var wmget = store.get;\n var wmhas = store.has;\n var wmset = store.set;\n set = function (it, metadata) {\n wmset.call(store, it, metadata);\n return metadata;\n };\n get = function (it) {\n return wmget.call(store, it) || {};\n };\n has = function (it) {\n return wmhas.call(store, it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return objectHas(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return objectHas(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n\n\n/***/ }),\n\n/***/ \"6eeb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar has = __webpack_require__(\"5135\");\nvar setGlobal = __webpack_require__(\"ce4e\");\nvar inspectSource = __webpack_require__(\"8925\");\nvar InternalStateModule = __webpack_require__(\"69f3\");\n\nvar getInternalState = InternalStateModule.get;\nvar enforceInternalState = InternalStateModule.enforce;\nvar TEMPLATE = String(String).split('String');\n\n(module.exports = function (O, key, value, options) {\n var unsafe = options ? !!options.unsafe : false;\n var simple = options ? !!options.enumerable : false;\n var noTargetGet = options ? !!options.noTargetGet : false;\n if (typeof value == 'function') {\n if (typeof key == 'string' && !has(value, 'name')) createNonEnumerableProperty(value, 'name', key);\n enforceInternalState(value).source = TEMPLATE.join(typeof key == 'string' ? key : '');\n }\n if (O === global) {\n if (simple) O[key] = value;\n else setGlobal(key, value);\n return;\n } else if (!unsafe) {\n delete O[key];\n } else if (!noTargetGet && O[key]) {\n simple = true;\n }\n if (simple) O[key] = value;\n else createNonEnumerableProperty(O, key, value);\n// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n})(Function.prototype, 'toString', function toString() {\n return typeof this == 'function' && getInternalState(this).source || inspectSource(this);\n});\n\n\n/***/ }),\n\n/***/ \"6f53\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar objectKeys = __webpack_require__(\"df75\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar propertyIsEnumerable = __webpack_require__(\"d1e7\").f;\n\n// `Object.{ entries, values }` methods implementation\nvar createMethod = function (TO_ENTRIES) {\n return function (it) {\n var O = toIndexedObject(it);\n var keys = objectKeys(O);\n var length = keys.length;\n var i = 0;\n var result = [];\n var key;\n while (length > i) {\n key = keys[i++];\n if (!DESCRIPTORS || propertyIsEnumerable.call(O, key)) {\n result.push(TO_ENTRIES ? [key, O[key]] : O[key]);\n }\n }\n return result;\n };\n};\n\nmodule.exports = {\n // `Object.entries` method\n // https://tc39.github.io/ecma262/#sec-object.entries\n entries: createMethod(true),\n // `Object.values` method\n // https://tc39.github.io/ecma262/#sec-object.values\n values: createMethod(false)\n};\n\n\n/***/ }),\n\n/***/ \"73d9\":\n/***/ (function(module, exports, __webpack_require__) {\n\n// this method was added to unscopables after implementation\n// in popular engines, so it's moved to a separate module\nvar addToUnscopables = __webpack_require__(\"44d2\");\n\naddToUnscopables('flatMap');\n\n\n/***/ }),\n\n/***/ \"7418\":\n/***/ (function(module, exports) {\n\nexports.f = Object.getOwnPropertySymbols;\n\n\n/***/ }),\n\n/***/ \"746f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar path = __webpack_require__(\"428f\");\nvar has = __webpack_require__(\"5135\");\nvar wrappedWellKnownSymbolModule = __webpack_require__(\"e538\");\nvar defineProperty = __webpack_require__(\"9bf2\").f;\n\nmodule.exports = function (NAME) {\n var Symbol = path.Symbol || (path.Symbol = {});\n if (!has(Symbol, NAME)) defineProperty(Symbol, NAME, {\n value: wrappedWellKnownSymbolModule.f(NAME)\n });\n};\n\n\n/***/ }),\n\n/***/ \"7839\":\n/***/ (function(module, exports) {\n\n// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n\n\n/***/ }),\n\n/***/ \"7b0b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\n\n// `ToObject` abstract operation\n// https://tc39.github.io/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return Object(requireObjectCoercible(argument));\n};\n\n\n/***/ }),\n\n/***/ \"7c73\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar anObject = __webpack_require__(\"825a\");\nvar defineProperties = __webpack_require__(\"37e8\");\nvar enumBugKeys = __webpack_require__(\"7839\");\nvar hiddenKeys = __webpack_require__(\"d012\");\nvar html = __webpack_require__(\"1be4\");\nvar documentCreateElement = __webpack_require__(\"cc12\");\nvar sharedKey = __webpack_require__(\"f772\");\n\nvar GT = '>';\nvar LT = '<';\nvar PROTOTYPE = 'prototype';\nvar SCRIPT = 'script';\nvar IE_PROTO = sharedKey('IE_PROTO');\n\nvar EmptyConstructor = function () { /* empty */ };\n\nvar scriptTag = function (content) {\n return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;\n};\n\n// Create object with fake `null` prototype: use ActiveX Object with cleared prototype\nvar NullProtoObjectViaActiveX = function (activeXDocument) {\n activeXDocument.write(scriptTag(''));\n activeXDocument.close();\n var temp = activeXDocument.parentWindow.Object;\n activeXDocument = null; // avoid memory leak\n return temp;\n};\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar NullProtoObjectViaIFrame = function () {\n // Thrash, waste and sodomy: IE GC bug\n var iframe = documentCreateElement('iframe');\n var JS = 'java' + SCRIPT + ':';\n var iframeDocument;\n iframe.style.display = 'none';\n html.appendChild(iframe);\n // https://github.com/zloirock/core-js/issues/475\n iframe.src = String(JS);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(scriptTag('document.F=Object'));\n iframeDocument.close();\n return iframeDocument.F;\n};\n\n// Check for document.domain and active x support\n// No need to use active x approach when document.domain is not set\n// see https://github.com/es-shims/es5-shim/issues/150\n// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346\n// avoid IE GC bug\nvar activeXDocument;\nvar NullProtoObject = function () {\n try {\n /* global ActiveXObject */\n activeXDocument = document.domain && new ActiveXObject('htmlfile');\n } catch (error) { /* ignore */ }\n NullProtoObject = activeXDocument ? NullProtoObjectViaActiveX(activeXDocument) : NullProtoObjectViaIFrame();\n var length = enumBugKeys.length;\n while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];\n return NullProtoObject();\n};\n\nhiddenKeys[IE_PROTO] = true;\n\n// `Object.create` method\n// https://tc39.github.io/ecma262/#sec-object.create\nmodule.exports = Object.create || function create(O, Properties) {\n var result;\n if (O !== null) {\n EmptyConstructor[PROTOTYPE] = anObject(O);\n result = new EmptyConstructor();\n EmptyConstructor[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = NullProtoObject();\n return Properties === undefined ? result : defineProperties(result, Properties);\n};\n\n\n/***/ }),\n\n/***/ \"7dd0\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar createIteratorConstructor = __webpack_require__(\"9ed3\");\nvar getPrototypeOf = __webpack_require__(\"e163\");\nvar setPrototypeOf = __webpack_require__(\"d2bb\");\nvar setToStringTag = __webpack_require__(\"d44e\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar IS_PURE = __webpack_require__(\"c430\");\nvar Iterators = __webpack_require__(\"3f8c\");\nvar IteratorsCore = __webpack_require__(\"ae93\");\n\nvar IteratorPrototype = IteratorsCore.IteratorPrototype;\nvar BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;\nvar ITERATOR = wellKnownSymbol('iterator');\nvar KEYS = 'keys';\nvar VALUES = 'values';\nvar ENTRIES = 'entries';\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {\n createIteratorConstructor(IteratorConstructor, NAME, next);\n\n var getIterationMethod = function (KIND) {\n if (KIND === DEFAULT && defaultIterator) return defaultIterator;\n if (!BUGGY_SAFARI_ITERATORS && KIND in IterablePrototype) return IterablePrototype[KIND];\n switch (KIND) {\n case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };\n case VALUES: return function values() { return new IteratorConstructor(this, KIND); };\n case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };\n } return function () { return new IteratorConstructor(this); };\n };\n\n var TO_STRING_TAG = NAME + ' Iterator';\n var INCORRECT_VALUES_NAME = false;\n var IterablePrototype = Iterable.prototype;\n var nativeIterator = IterablePrototype[ITERATOR]\n || IterablePrototype['@@iterator']\n || DEFAULT && IterablePrototype[DEFAULT];\n var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);\n var anyNativeIterator = NAME == 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;\n var CurrentIteratorPrototype, methods, KEY;\n\n // fix native\n if (anyNativeIterator) {\n CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));\n if (IteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {\n if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {\n if (setPrototypeOf) {\n setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);\n } else if (typeof CurrentIteratorPrototype[ITERATOR] != 'function') {\n createNonEnumerableProperty(CurrentIteratorPrototype, ITERATOR, returnThis);\n }\n }\n // Set @@toStringTag to native iterators\n setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);\n if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;\n }\n }\n\n // fix Array#{values, @@iterator}.name in V8 / FF\n if (DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) {\n INCORRECT_VALUES_NAME = true;\n defaultIterator = function values() { return nativeIterator.call(this); };\n }\n\n // define iterator\n if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {\n createNonEnumerableProperty(IterablePrototype, ITERATOR, defaultIterator);\n }\n Iterators[NAME] = defaultIterator;\n\n // export additional methods\n if (DEFAULT) {\n methods = {\n values: getIterationMethod(VALUES),\n keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),\n entries: getIterationMethod(ENTRIES)\n };\n if (FORCED) for (KEY in methods) {\n if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {\n redefine(IterablePrototype, KEY, methods[KEY]);\n }\n } else $({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);\n }\n\n return methods;\n};\n\n\n/***/ }),\n\n/***/ \"7f9a\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar inspectSource = __webpack_require__(\"8925\");\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = typeof WeakMap === 'function' && /native code/.test(inspectSource(WeakMap));\n\n\n/***/ }),\n\n/***/ \"825a\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\n\nmodule.exports = function (it) {\n if (!isObject(it)) {\n throw TypeError(String(it) + ' is not an object');\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"83ab\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !fails(function () {\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;\n});\n\n\n/***/ }),\n\n/***/ \"8418\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar toPrimitive = __webpack_require__(\"c04e\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\n\nmodule.exports = function (object, key, value) {\n var propertyKey = toPrimitive(key);\n if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));\n else object[propertyKey] = value;\n};\n\n\n/***/ }),\n\n/***/ \"861d\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (it) {\n return typeof it === 'object' ? it !== null : typeof it === 'function';\n};\n\n\n/***/ }),\n\n/***/ \"8875\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (true) {\n !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),\n\t\t\t\t__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?\n\t\t\t\t(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),\n\t\t\t\t__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));\n } else {}\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n var descriptor = Object.getOwnPropertyDescriptor(document, 'currentScript')\n // for chrome\n if (!descriptor && 'currentScript' in document && document.currentScript) {\n return document.currentScript\n }\n\n // for other browsers with native support for currentScript\n if (descriptor && descriptor.get !== getCurrentScript && document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*<script>([\\\\d\\\\D]*?)<\\\\/script>[\\\\d\\\\D]*', 'i');\n inlineScriptSource = pageSource.replace(inlineScriptSourceRegExp, '$1').trim();\n }\n \n for (var i = 0; i < scripts.length; i++) {\n // If ready state is interactive, return the script tag\n if (scripts[i].readyState === 'interactive') {\n return scripts[i];\n }\n \n // If src matches, return the script tag\n if (scripts[i].src === scriptLocation) {\n return scripts[i];\n }\n \n // If inline source matches, return the script tag\n if (\n scriptLocation === currentLocation &&\n scripts[i].innerHTML &&\n scripts[i].innerHTML.trim() === inlineScriptSource\n ) {\n return scripts[i];\n }\n }\n \n // If no match, return null\n return null;\n }\n };\n\n return getCurrentScript\n}));\n\n\n/***/ }),\n\n/***/ \"8925\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar store = __webpack_require__(\"c6cd\");\n\nvar functionToString = Function.toString;\n\n// this helper broken in `3.4.1-3.4.4`, so we can't use `shared` helper\nif (typeof store.inspectSource != 'function') {\n store.inspectSource = function (it) {\n return functionToString.call(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n\n\n/***/ }),\n\n/***/ \"8aa5\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar charAt = __webpack_require__(\"6547\").charAt;\n\n// `AdvanceStringIndex` abstract operation\n// https://tc39.github.io/ecma262/#sec-advancestringindex\nmodule.exports = function (S, index, unicode) {\n return index + (unicode ? charAt(S, index).length : 1);\n};\n\n\n/***/ }),\n\n/***/ \"8bbf\":\n/***/ (function(module, exports) {\n\nmodule.exports = __WEBPACK_EXTERNAL_MODULE__8bbf__;\n\n/***/ }),\n\n/***/ \"90e3\":\n/***/ (function(module, exports) {\n\nvar id = 0;\nvar postfix = Math.random();\n\nmodule.exports = function (key) {\n return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36);\n};\n\n\n/***/ }),\n\n/***/ \"9112\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n\n\n/***/ }),\n\n/***/ \"9263\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar regexpFlags = __webpack_require__(\"ad6d\");\nvar stickyHelpers = __webpack_require__(\"9f7f\");\n\nvar nativeExec = RegExp.prototype.exec;\n// This always refers to the native implementation, because the\n// String#replace polyfill uses ./fix-regexp-well-known-symbol-logic.js,\n// which loads this file before patching the method.\nvar nativeReplace = String.prototype.replace;\n\nvar patchedExec = nativeExec;\n\nvar UPDATES_LAST_INDEX_WRONG = (function () {\n var re1 = /a/;\n var re2 = /b*/g;\n nativeExec.call(re1, 'a');\n nativeExec.call(re2, 'a');\n return re1.lastIndex !== 0 || re2.lastIndex !== 0;\n})();\n\nvar UNSUPPORTED_Y = stickyHelpers.UNSUPPORTED_Y || stickyHelpers.BROKEN_CARET;\n\n// nonparticipating capturing group, copied from es5-shim's String#split patch.\nvar NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;\n\nvar PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y;\n\nif (PATCH) {\n patchedExec = function exec(str) {\n var re = this;\n var lastIndex, reCopy, match, i;\n var sticky = UNSUPPORTED_Y && re.sticky;\n var flags = regexpFlags.call(re);\n var source = re.source;\n var charsAdded = 0;\n var strCopy = str;\n\n if (sticky) {\n flags = flags.replace('y', '');\n if (flags.indexOf('g') === -1) {\n flags += 'g';\n }\n\n strCopy = String(str).slice(re.lastIndex);\n // Support anchored sticky behavior.\n if (re.lastIndex > 0 && (!re.multiline || re.multiline && str[re.lastIndex - 1] !== '\\n')) {\n source = '(?: ' + source + ')';\n strCopy = ' ' + strCopy;\n charsAdded++;\n }\n // ^(? + rx + ) is needed, in combination with some str slicing, to\n // simulate the 'y' flag.\n reCopy = new RegExp('^(?:' + source + ')', flags);\n }\n\n if (NPCG_INCLUDED) {\n reCopy = new RegExp('^' + source + '$(?!\\\\s)', flags);\n }\n if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;\n\n match = nativeExec.call(sticky ? reCopy : re, strCopy);\n\n if (sticky) {\n if (match) {\n match.input = match.input.slice(charsAdded);\n match[0] = match[0].slice(charsAdded);\n match.index = re.lastIndex;\n re.lastIndex += match[0].length;\n } else re.lastIndex = 0;\n } else if (UPDATES_LAST_INDEX_WRONG && match) {\n re.lastIndex = re.global ? match.index + match[0].length : lastIndex;\n }\n if (NPCG_INCLUDED && match && match.length > 1) {\n // Fix browsers whose `exec` methods don't consistently return `undefined`\n // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/\n nativeReplace.call(match[0], reCopy, function () {\n for (i = 1; i < arguments.length - 2; i++) {\n if (arguments[i] === undefined) match[i] = undefined;\n }\n });\n }\n\n return match;\n };\n}\n\nmodule.exports = patchedExec;\n\n\n/***/ }),\n\n/***/ \"94ca\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value == POLYFILL ? true\n : value == NATIVE ? false\n : typeof detection == 'function' ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n\n\n/***/ }),\n\n/***/ \"99af\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar fails = __webpack_require__(\"d039\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar isObject = __webpack_require__(\"861d\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar createProperty = __webpack_require__(\"8418\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar V8_VERSION = __webpack_require__(\"2d00\");\n\nvar IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_INDEX_EXCEEDED = 'Maximum allowed index exceeded';\n\n// We can't use this feature detection in V8 since it causes\n// deoptimization and serious performance degradation\n// https://github.com/zloirock/core-js/issues/679\nvar IS_CONCAT_SPREADABLE_SUPPORT = V8_VERSION >= 51 || !fails(function () {\n var array = [];\n array[IS_CONCAT_SPREADABLE] = false;\n return array.concat()[0] !== array;\n});\n\nvar SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('concat');\n\nvar isConcatSpreadable = function (O) {\n if (!isObject(O)) return false;\n var spreadable = O[IS_CONCAT_SPREADABLE];\n return spreadable !== undefined ? !!spreadable : isArray(O);\n};\n\nvar FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !SPECIES_SUPPORT;\n\n// `Array.prototype.concat` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.concat\n// with adding support of @@isConcatSpreadable and @@species\n$({ target: 'Array', proto: true, forced: FORCED }, {\n concat: function concat(arg) { // eslint-disable-line no-unused-vars\n var O = toObject(this);\n var A = arraySpeciesCreate(O, 0);\n var n = 0;\n var i, k, length, len, E;\n for (i = -1, length = arguments.length; i < length; i++) {\n E = i === -1 ? O : arguments[i];\n if (isConcatSpreadable(E)) {\n len = toLength(E.length);\n if (n + len > MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);\n } else {\n if (n >= MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n createProperty(A, n++, E);\n }\n }\n A.length = n;\n return A;\n }\n});\n\n\n/***/ }),\n\n/***/ \"9bdd\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar anObject = __webpack_require__(\"825a\");\n\n// call something on iterator step with safe closing on error\nmodule.exports = function (iterator, fn, value, ENTRIES) {\n try {\n return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);\n // 7.4.6 IteratorClose(iterator, completion)\n } catch (error) {\n var returnMethod = iterator['return'];\n if (returnMethod !== undefined) anObject(returnMethod.call(iterator));\n throw error;\n }\n};\n\n\n/***/ }),\n\n/***/ \"9bf2\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar IE8_DOM_DEFINE = __webpack_require__(\"0cfb\");\nvar anObject = __webpack_require__(\"825a\");\nvar toPrimitive = __webpack_require__(\"c04e\");\n\nvar nativeDefineProperty = Object.defineProperty;\n\n// `Object.defineProperty` method\n// https://tc39.github.io/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? nativeDefineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPrimitive(P, true);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return nativeDefineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n\n\n/***/ }),\n\n/***/ \"9ed3\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar IteratorPrototype = __webpack_require__(\"ae93\").IteratorPrototype;\nvar create = __webpack_require__(\"7c73\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\nvar setToStringTag = __webpack_require__(\"d44e\");\nvar Iterators = __webpack_require__(\"3f8c\");\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (IteratorConstructor, NAME, next) {\n var TO_STRING_TAG = NAME + ' Iterator';\n IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(1, next) });\n setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);\n Iterators[TO_STRING_TAG] = returnThis;\n return IteratorConstructor;\n};\n\n\n/***/ }),\n\n/***/ \"9f7f\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nvar fails = __webpack_require__(\"d039\");\n\n// babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError,\n// so we use an intermediate function.\nfunction RE(s, f) {\n return RegExp(s, f);\n}\n\nexports.UNSUPPORTED_Y = fails(function () {\n // babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError\n var re = RE('a', 'y');\n re.lastIndex = 2;\n return re.exec('abcd') != null;\n});\n\nexports.BROKEN_CARET = fails(function () {\n // https://bugzilla.mozilla.org/show_bug.cgi?id=773687\n var re = RE('^r', 'gy');\n re.lastIndex = 2;\n return re.exec('str') != null;\n});\n\n\n/***/ }),\n\n/***/ \"a2bf\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar isArray = __webpack_require__(\"e8b5\");\nvar toLength = __webpack_require__(\"50c4\");\nvar bind = __webpack_require__(\"0366\");\n\n// `FlattenIntoArray` abstract operation\n// https://tc39.github.io/proposal-flatMap/#sec-FlattenIntoArray\nvar flattenIntoArray = function (target, original, source, sourceLen, start, depth, mapper, thisArg) {\n var targetIndex = start;\n var sourceIndex = 0;\n var mapFn = mapper ? bind(mapper, thisArg, 3) : false;\n var element;\n\n while (sourceIndex < sourceLen) {\n if (sourceIndex in source) {\n element = mapFn ? mapFn(source[sourceIndex], sourceIndex, original) : source[sourceIndex];\n\n if (depth > 0 && isArray(element)) {\n targetIndex = flattenIntoArray(target, original, element, toLength(element.length), targetIndex, depth - 1) - 1;\n } else {\n if (targetIndex >= 0x1FFFFFFFFFFFFF) throw TypeError('Exceed the acceptable array length');\n target[targetIndex] = element;\n }\n\n targetIndex++;\n }\n sourceIndex++;\n }\n return targetIndex;\n};\n\nmodule.exports = flattenIntoArray;\n\n\n/***/ }),\n\n/***/ \"a352\":\n/***/ (function(module, exports) {\n\nmodule.exports = __WEBPACK_EXTERNAL_MODULE_a352__;\n\n/***/ }),\n\n/***/ \"a434\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar toAbsoluteIndex = __webpack_require__(\"23cb\");\nvar toInteger = __webpack_require__(\"a691\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\nvar createProperty = __webpack_require__(\"8418\");\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('splice');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('splice', { ACCESSORS: true, 0: 0, 1: 2 });\n\nvar max = Math.max;\nvar min = Math.min;\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_LENGTH_EXCEEDED = 'Maximum allowed length exceeded';\n\n// `Array.prototype.splice` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.splice\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n splice: function splice(start, deleteCount /* , ...items */) {\n var O = toObject(this);\n var len = toLength(O.length);\n var actualStart = toAbsoluteIndex(start, len);\n var argumentsLength = arguments.length;\n var insertCount, actualDeleteCount, A, k, from, to;\n if (argumentsLength === 0) {\n insertCount = actualDeleteCount = 0;\n } else if (argumentsLength === 1) {\n insertCount = 0;\n actualDeleteCount = len - actualStart;\n } else {\n insertCount = argumentsLength - 2;\n actualDeleteCount = min(max(toInteger(deleteCount), 0), len - actualStart);\n }\n if (len + insertCount - actualDeleteCount > MAX_SAFE_INTEGER) {\n throw TypeError(MAXIMUM_ALLOWED_LENGTH_EXCEEDED);\n }\n A = arraySpeciesCreate(O, actualDeleteCount);\n for (k = 0; k < actualDeleteCount; k++) {\n from = actualStart + k;\n if (from in O) createProperty(A, k, O[from]);\n }\n A.length = actualDeleteCount;\n if (insertCount < actualDeleteCount) {\n for (k = actualStart; k < len - actualDeleteCount; k++) {\n from = k + actualDeleteCount;\n to = k + insertCount;\n if (from in O) O[to] = O[from];\n else delete O[to];\n }\n for (k = len; k > len - actualDeleteCount + insertCount; k--) delete O[k - 1];\n } else if (insertCount > actualDeleteCount) {\n for (k = len - actualDeleteCount; k > actualStart; k--) {\n from = k + actualDeleteCount - 1;\n to = k + insertCount - 1;\n if (from in O) O[to] = O[from];\n else delete O[to];\n }\n }\n for (k = 0; k < insertCount; k++) {\n O[k + actualStart] = arguments[k + 2];\n }\n O.length = len - actualDeleteCount + insertCount;\n return A;\n }\n});\n\n\n/***/ }),\n\n/***/ \"a4d3\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar global = __webpack_require__(\"da84\");\nvar getBuiltIn = __webpack_require__(\"d066\");\nvar IS_PURE = __webpack_require__(\"c430\");\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar NATIVE_SYMBOL = __webpack_require__(\"4930\");\nvar USE_SYMBOL_AS_UID = __webpack_require__(\"fdbf\");\nvar fails = __webpack_require__(\"d039\");\nvar has = __webpack_require__(\"5135\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar isObject = __webpack_require__(\"861d\");\nvar anObject = __webpack_require__(\"825a\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar toPrimitive = __webpack_require__(\"c04e\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\nvar nativeObjectCreate = __webpack_require__(\"7c73\");\nvar objectKeys = __webpack_require__(\"df75\");\nvar getOwnPropertyNamesModule = __webpack_require__(\"241c\");\nvar getOwnPropertyNamesExternal = __webpack_require__(\"057f\");\nvar getOwnPropertySymbolsModule = __webpack_require__(\"7418\");\nvar getOwnPropertyDescriptorModule = __webpack_require__(\"06cf\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar propertyIsEnumerableModule = __webpack_require__(\"d1e7\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar shared = __webpack_require__(\"5692\");\nvar sharedKey = __webpack_require__(\"f772\");\nvar hiddenKeys = __webpack_require__(\"d012\");\nvar uid = __webpack_require__(\"90e3\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar wrappedWellKnownSymbolModule = __webpack_require__(\"e538\");\nvar defineWellKnownSymbol = __webpack_require__(\"746f\");\nvar setToStringTag = __webpack_require__(\"d44e\");\nvar InternalStateModule = __webpack_require__(\"69f3\");\nvar $forEach = __webpack_require__(\"b727\").forEach;\n\nvar HIDDEN = sharedKey('hidden');\nvar SYMBOL = 'Symbol';\nvar PROTOTYPE = 'prototype';\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(SYMBOL);\nvar ObjectPrototype = Object[PROTOTYPE];\nvar $Symbol = global.Symbol;\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\nvar nativeDefineProperty = definePropertyModule.f;\nvar nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f;\nvar nativePropertyIsEnumerable = propertyIsEnumerableModule.f;\nvar AllSymbols = shared('symbols');\nvar ObjectPrototypeSymbols = shared('op-symbols');\nvar StringToSymbolRegistry = shared('string-to-symbol-registry');\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\nvar WellKnownSymbolsStore = shared('wks');\nvar QObject = global.QObject;\n// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173\nvar USE_SETTER = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;\n\n// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687\nvar setSymbolDescriptor = DESCRIPTORS && fails(function () {\n return nativeObjectCreate(nativeDefineProperty({}, 'a', {\n get: function () { return nativeDefineProperty(this, 'a', { value: 7 }).a; }\n })).a != 7;\n}) ? function (O, P, Attributes) {\n var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor(ObjectPrototype, P);\n if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];\n nativeDefineProperty(O, P, Attributes);\n if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {\n nativeDefineProperty(ObjectPrototype, P, ObjectPrototypeDescriptor);\n }\n} : nativeDefineProperty;\n\nvar wrap = function (tag, description) {\n var symbol = AllSymbols[tag] = nativeObjectCreate($Symbol[PROTOTYPE]);\n setInternalState(symbol, {\n type: SYMBOL,\n tag: tag,\n description: description\n });\n if (!DESCRIPTORS) symbol.description = description;\n return symbol;\n};\n\nvar isSymbol = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n return Object(it) instanceof $Symbol;\n};\n\nvar $defineProperty = function defineProperty(O, P, Attributes) {\n if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);\n anObject(O);\n var key = toPrimitive(P, true);\n anObject(Attributes);\n if (has(AllSymbols, key)) {\n if (!Attributes.enumerable) {\n if (!has(O, HIDDEN)) nativeDefineProperty(O, HIDDEN, createPropertyDescriptor(1, {}));\n O[HIDDEN][key] = true;\n } else {\n if (has(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;\n Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });\n } return setSymbolDescriptor(O, key, Attributes);\n } return nativeDefineProperty(O, key, Attributes);\n};\n\nvar $defineProperties = function defineProperties(O, Properties) {\n anObject(O);\n var properties = toIndexedObject(Properties);\n var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));\n $forEach(keys, function (key) {\n if (!DESCRIPTORS || $propertyIsEnumerable.call(properties, key)) $defineProperty(O, key, properties[key]);\n });\n return O;\n};\n\nvar $create = function create(O, Properties) {\n return Properties === undefined ? nativeObjectCreate(O) : $defineProperties(nativeObjectCreate(O), Properties);\n};\n\nvar $propertyIsEnumerable = function propertyIsEnumerable(V) {\n var P = toPrimitive(V, true);\n var enumerable = nativePropertyIsEnumerable.call(this, P);\n if (this === ObjectPrototype && has(AllSymbols, P) && !has(ObjectPrototypeSymbols, P)) return false;\n return enumerable || !has(this, P) || !has(AllSymbols, P) || has(this, HIDDEN) && this[HIDDEN][P] ? enumerable : true;\n};\n\nvar $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {\n var it = toIndexedObject(O);\n var key = toPrimitive(P, true);\n if (it === ObjectPrototype && has(AllSymbols, key) && !has(ObjectPrototypeSymbols, key)) return;\n var descriptor = nativeGetOwnPropertyDescriptor(it, key);\n if (descriptor && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) {\n descriptor.enumerable = true;\n }\n return descriptor;\n};\n\nvar $getOwnPropertyNames = function getOwnPropertyNames(O) {\n var names = nativeGetOwnPropertyNames(toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (!has(AllSymbols, key) && !has(hiddenKeys, key)) result.push(key);\n });\n return result;\n};\n\nvar $getOwnPropertySymbols = function getOwnPropertySymbols(O) {\n var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;\n var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (has(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || has(ObjectPrototype, key))) {\n result.push(AllSymbols[key]);\n }\n });\n return result;\n};\n\n// `Symbol` constructor\n// https://tc39.github.io/ecma262/#sec-symbol-constructor\nif (!NATIVE_SYMBOL) {\n $Symbol = function Symbol() {\n if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor');\n var description = !arguments.length || arguments[0] === undefined ? undefined : String(arguments[0]);\n var tag = uid(description);\n var setter = function (value) {\n if (this === ObjectPrototype) setter.call(ObjectPrototypeSymbols, value);\n if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;\n setSymbolDescriptor(this, tag, createPropertyDescriptor(1, value));\n };\n if (DESCRIPTORS && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });\n return wrap(tag, description);\n };\n\n redefine($Symbol[PROTOTYPE], 'toString', function toString() {\n return getInternalState(this).tag;\n });\n\n redefine($Symbol, 'withoutSetter', function (description) {\n return wrap(uid(description), description);\n });\n\n propertyIsEnumerableModule.f = $propertyIsEnumerable;\n definePropertyModule.f = $defineProperty;\n getOwnPropertyDescriptorModule.f = $getOwnPropertyDescriptor;\n getOwnPropertyNamesModule.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames;\n getOwnPropertySymbolsModule.f = $getOwnPropertySymbols;\n\n wrappedWellKnownSymbolModule.f = function (name) {\n return wrap(wellKnownSymbol(name), name);\n };\n\n if (DESCRIPTORS) {\n // https://github.com/tc39/proposal-Symbol-description\n nativeDefineProperty($Symbol[PROTOTYPE], 'description', {\n configurable: true,\n get: function description() {\n return getInternalState(this).description;\n }\n });\n if (!IS_PURE) {\n redefine(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });\n }\n }\n}\n\n$({ global: true, wrap: true, forced: !NATIVE_SYMBOL, sham: !NATIVE_SYMBOL }, {\n Symbol: $Symbol\n});\n\n$forEach(objectKeys(WellKnownSymbolsStore), function (name) {\n defineWellKnownSymbol(name);\n});\n\n$({ target: SYMBOL, stat: true, forced: !NATIVE_SYMBOL }, {\n // `Symbol.for` method\n // https://tc39.github.io/ecma262/#sec-symbol.for\n 'for': function (key) {\n var string = String(key);\n if (has(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];\n var symbol = $Symbol(string);\n StringToSymbolRegistry[string] = symbol;\n SymbolToStringRegistry[symbol] = string;\n return symbol;\n },\n // `Symbol.keyFor` method\n // https://tc39.github.io/ecma262/#sec-symbol.keyfor\n keyFor: function keyFor(sym) {\n if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol');\n if (has(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];\n },\n useSetter: function () { USE_SETTER = true; },\n useSimple: function () { USE_SETTER = false; }\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL, sham: !DESCRIPTORS }, {\n // `Object.create` method\n // https://tc39.github.io/ecma262/#sec-object.create\n create: $create,\n // `Object.defineProperty` method\n // https://tc39.github.io/ecma262/#sec-object.defineproperty\n defineProperty: $defineProperty,\n // `Object.defineProperties` method\n // https://tc39.github.io/ecma262/#sec-object.defineproperties\n defineProperties: $defineProperties,\n // `Object.getOwnPropertyDescriptor` method\n // https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptors\n getOwnPropertyDescriptor: $getOwnPropertyDescriptor\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL }, {\n // `Object.getOwnPropertyNames` method\n // https://tc39.github.io/ecma262/#sec-object.getownpropertynames\n getOwnPropertyNames: $getOwnPropertyNames,\n // `Object.getOwnPropertySymbols` method\n // https://tc39.github.io/ecma262/#sec-object.getownpropertysymbols\n getOwnPropertySymbols: $getOwnPropertySymbols\n});\n\n// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives\n// https://bugs.chromium.org/p/v8/issues/detail?id=3443\n$({ target: 'Object', stat: true, forced: fails(function () { getOwnPropertySymbolsModule.f(1); }) }, {\n getOwnPropertySymbols: function getOwnPropertySymbols(it) {\n return getOwnPropertySymbolsModule.f(toObject(it));\n }\n});\n\n// `JSON.stringify` method behavior with symbols\n// https://tc39.github.io/ecma262/#sec-json.stringify\nif ($stringify) {\n var FORCED_JSON_STRINGIFY = !NATIVE_SYMBOL || fails(function () {\n var symbol = $Symbol();\n // MS Edge converts symbol values to JSON as {}\n return $stringify([symbol]) != '[null]'\n // WebKit converts symbol values to JSON as null\n || $stringify({ a: symbol }) != '{}'\n // V8 throws on boxed symbols\n || $stringify(Object(symbol)) != '{}';\n });\n\n $({ target: 'JSON', stat: true, forced: FORCED_JSON_STRINGIFY }, {\n // eslint-disable-next-line no-unused-vars\n stringify: function stringify(it, replacer, space) {\n var args = [it];\n var index = 1;\n var $replacer;\n while (arguments.length > index) args.push(arguments[index++]);\n $replacer = replacer;\n if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined\n if (!isArray(replacer)) replacer = function (key, value) {\n if (typeof $replacer == 'function') value = $replacer.call(this, key, value);\n if (!isSymbol(value)) return value;\n };\n args[1] = replacer;\n return $stringify.apply(null, args);\n }\n });\n}\n\n// `Symbol.prototype[@@toPrimitive]` method\n// https://tc39.github.io/ecma262/#sec-symbol.prototype-@@toprimitive\nif (!$Symbol[PROTOTYPE][TO_PRIMITIVE]) {\n createNonEnumerableProperty($Symbol[PROTOTYPE], TO_PRIMITIVE, $Symbol[PROTOTYPE].valueOf);\n}\n// `Symbol.prototype[@@toStringTag]` property\n// https://tc39.github.io/ecma262/#sec-symbol.prototype-@@tostringtag\nsetToStringTag($Symbol, SYMBOL);\n\nhiddenKeys[HIDDEN] = true;\n\n\n/***/ }),\n\n/***/ \"a630\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar from = __webpack_require__(\"4df4\");\nvar checkCorrectnessOfIteration = __webpack_require__(\"1c7e\");\n\nvar INCORRECT_ITERATION = !checkCorrectnessOfIteration(function (iterable) {\n Array.from(iterable);\n});\n\n// `Array.from` method\n// https://tc39.github.io/ecma262/#sec-array.from\n$({ target: 'Array', stat: true, forced: INCORRECT_ITERATION }, {\n from: from\n});\n\n\n/***/ }),\n\n/***/ \"a640\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar fails = __webpack_require__(\"d039\");\n\nmodule.exports = function (METHOD_NAME, argument) {\n var method = [][METHOD_NAME];\n return !!method && fails(function () {\n // eslint-disable-next-line no-useless-call,no-throw-literal\n method.call(null, argument || function () { throw 1; }, 1);\n });\n};\n\n\n/***/ }),\n\n/***/ \"a691\":\n/***/ (function(module, exports) {\n\nvar ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `ToInteger` abstract operation\n// https://tc39.github.io/ecma262/#sec-tointeger\nmodule.exports = function (argument) {\n return isNaN(argument = +argument) ? 0 : (argument > 0 ? floor : ceil)(argument);\n};\n\n\n/***/ }),\n\n/***/ \"ab13\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar MATCH = wellKnownSymbol('match');\n\nmodule.exports = function (METHOD_NAME) {\n var regexp = /./;\n try {\n '/./'[METHOD_NAME](regexp);\n } catch (e) {\n try {\n regexp[MATCH] = false;\n return '/./'[METHOD_NAME](regexp);\n } catch (f) { /* empty */ }\n } return false;\n};\n\n\n/***/ }),\n\n/***/ \"ac1f\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar exec = __webpack_require__(\"9263\");\n\n$({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {\n exec: exec\n});\n\n\n/***/ }),\n\n/***/ \"ad6d\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar anObject = __webpack_require__(\"825a\");\n\n// `RegExp.prototype.flags` getter implementation\n// https://tc39.github.io/ecma262/#sec-get-regexp.prototype.flags\nmodule.exports = function () {\n var that = anObject(this);\n var result = '';\n if (that.global) result += 'g';\n if (that.ignoreCase) result += 'i';\n if (that.multiline) result += 'm';\n if (that.dotAll) result += 's';\n if (that.unicode) result += 'u';\n if (that.sticky) result += 'y';\n return result;\n};\n\n\n/***/ }),\n\n/***/ \"ae40\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar fails = __webpack_require__(\"d039\");\nvar has = __webpack_require__(\"5135\");\n\nvar defineProperty = Object.defineProperty;\nvar cache = {};\n\nvar thrower = function (it) { throw it; };\n\nmodule.exports = function (METHOD_NAME, options) {\n if (has(cache, METHOD_NAME)) return cache[METHOD_NAME];\n if (!options) options = {};\n var method = [][METHOD_NAME];\n var ACCESSORS = has(options, 'ACCESSORS') ? options.ACCESSORS : false;\n var argument0 = has(options, 0) ? options[0] : thrower;\n var argument1 = has(options, 1) ? options[1] : undefined;\n\n return cache[METHOD_NAME] = !!method && !fails(function () {\n if (ACCESSORS && !DESCRIPTORS) return true;\n var O = { length: -1 };\n\n if (ACCESSORS) defineProperty(O, 1, { enumerable: true, get: thrower });\n else O[1] = 1;\n\n method.call(O, argument0, argument1);\n });\n};\n\n\n/***/ }),\n\n/***/ \"ae93\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar getPrototypeOf = __webpack_require__(\"e163\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar has = __webpack_require__(\"5135\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar IS_PURE = __webpack_require__(\"c430\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false;\n\nvar returnThis = function () { return this; };\n\n// `%IteratorPrototype%` object\n// https://tc39.github.io/ecma262/#sec-%iteratorprototype%-object\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n\nif ([].keys) {\n arrayIterator = [].keys();\n // Safari 8 has buggy iterators w/o `next`\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;\n else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nif (IteratorPrototype == undefined) IteratorPrototype = {};\n\n// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()\nif (!IS_PURE && !has(IteratorPrototype, ITERATOR)) {\n createNonEnumerableProperty(IteratorPrototype, ITERATOR, returnThis);\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};\n\n\n/***/ }),\n\n/***/ \"b041\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar TO_STRING_TAG_SUPPORT = __webpack_require__(\"00ee\");\nvar classof = __webpack_require__(\"f5df\");\n\n// `Object.prototype.toString` method implementation\n// https://tc39.github.io/ecma262/#sec-object.prototype.tostring\nmodule.exports = TO_STRING_TAG_SUPPORT ? {}.toString : function toString() {\n return '[object ' + classof(this) + ']';\n};\n\n\n/***/ }),\n\n/***/ \"b0c0\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar defineProperty = __webpack_require__(\"9bf2\").f;\n\nvar FunctionPrototype = Function.prototype;\nvar FunctionPrototypeToString = FunctionPrototype.toString;\nvar nameRE = /^\\s*function ([^ (]*)/;\nvar NAME = 'name';\n\n// Function instances `.name` property\n// https://tc39.github.io/ecma262/#sec-function-instances-name\nif (DESCRIPTORS && !(NAME in FunctionPrototype)) {\n defineProperty(FunctionPrototype, NAME, {\n configurable: true,\n get: function () {\n try {\n return FunctionPrototypeToString.call(this).match(nameRE)[1];\n } catch (error) {\n return '';\n }\n }\n });\n}\n\n\n/***/ }),\n\n/***/ \"b622\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar shared = __webpack_require__(\"5692\");\nvar has = __webpack_require__(\"5135\");\nvar uid = __webpack_require__(\"90e3\");\nvar NATIVE_SYMBOL = __webpack_require__(\"4930\");\nvar USE_SYMBOL_AS_UID = __webpack_require__(\"fdbf\");\n\nvar WellKnownSymbolsStore = shared('wks');\nvar Symbol = global.Symbol;\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!has(WellKnownSymbolsStore, name)) {\n if (NATIVE_SYMBOL && has(Symbol, name)) WellKnownSymbolsStore[name] = Symbol[name];\n else WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name);\n } return WellKnownSymbolsStore[name];\n};\n\n\n/***/ }),\n\n/***/ \"b64b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar nativeKeys = __webpack_require__(\"df75\");\nvar fails = __webpack_require__(\"d039\");\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeKeys(1); });\n\n// `Object.keys` method\n// https://tc39.github.io/ecma262/#sec-object.keys\n$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES }, {\n keys: function keys(it) {\n return nativeKeys(toObject(it));\n }\n});\n\n\n/***/ }),\n\n/***/ \"b727\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar bind = __webpack_require__(\"0366\");\nvar IndexedObject = __webpack_require__(\"44ad\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\n\nvar push = [].push;\n\n// `Array.prototype.{ forEach, map, filter, some, every, find, findIndex }` methods implementation\nvar createMethod = function (TYPE) {\n var IS_MAP = TYPE == 1;\n var IS_FILTER = TYPE == 2;\n var IS_SOME = TYPE == 3;\n var IS_EVERY = TYPE == 4;\n var IS_FIND_INDEX = TYPE == 6;\n var NO_HOLES = TYPE == 5 || IS_FIND_INDEX;\n return function ($this, callbackfn, that, specificCreate) {\n var O = toObject($this);\n var self = IndexedObject(O);\n var boundFunction = bind(callbackfn, that, 3);\n var length = toLength(self.length);\n var index = 0;\n var create = specificCreate || arraySpeciesCreate;\n var target = IS_MAP ? create($this, length) : IS_FILTER ? create($this, 0) : undefined;\n var value, result;\n for (;length > index; index++) if (NO_HOLES || index in self) {\n value = self[index];\n result = boundFunction(value, index, O);\n if (TYPE) {\n if (IS_MAP) target[index] = result; // map\n else if (result) switch (TYPE) {\n case 3: return true; // some\n case 5: return value; // find\n case 6: return index; // findIndex\n case 2: push.call(target, value); // filter\n } else if (IS_EVERY) return false; // every\n }\n }\n return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.forEach` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.foreach\n forEach: createMethod(0),\n // `Array.prototype.map` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.map\n map: createMethod(1),\n // `Array.prototype.filter` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.filter\n filter: createMethod(2),\n // `Array.prototype.some` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.some\n some: createMethod(3),\n // `Array.prototype.every` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.every\n every: createMethod(4),\n // `Array.prototype.find` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.find\n find: createMethod(5),\n // `Array.prototype.findIndex` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.findIndex\n findIndex: createMethod(6)\n};\n\n\n/***/ }),\n\n/***/ \"c04e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\n\n// `ToPrimitive` abstract operation\n// https://tc39.github.io/ecma262/#sec-toprimitive\n// instead of the ES6 spec version, we didn't implement @@toPrimitive case\n// and the second argument - flag - preferred type is a string\nmodule.exports = function (input, PREFERRED_STRING) {\n if (!isObject(input)) return input;\n var fn, val;\n if (PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;\n if (typeof (fn = input.valueOf) == 'function' && !isObject(val = fn.call(input))) return val;\n if (!PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;\n throw TypeError(\"Can't convert object to primitive value\");\n};\n\n\n/***/ }),\n\n/***/ \"c430\":\n/***/ (function(module, exports) {\n\nmodule.exports = false;\n\n\n/***/ }),\n\n/***/ \"c6b6\":\n/***/ (function(module, exports) {\n\nvar toString = {}.toString;\n\nmodule.exports = function (it) {\n return toString.call(it).slice(8, -1);\n};\n\n\n/***/ }),\n\n/***/ \"c6cd\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar setGlobal = __webpack_require__(\"ce4e\");\n\nvar SHARED = '__core-js_shared__';\nvar store = global[SHARED] || setGlobal(SHARED, {});\n\nmodule.exports = store;\n\n\n/***/ }),\n\n/***/ \"c740\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $findIndex = __webpack_require__(\"b727\").findIndex;\nvar addToUnscopables = __webpack_require__(\"44d2\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar FIND_INDEX = 'findIndex';\nvar SKIPS_HOLES = true;\n\nvar USES_TO_LENGTH = arrayMethodUsesToLength(FIND_INDEX);\n\n// Shouldn't skip holes\nif (FIND_INDEX in []) Array(1)[FIND_INDEX](function () { SKIPS_HOLES = false; });\n\n// `Array.prototype.findIndex` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.findindex\n$({ target: 'Array', proto: true, forced: SKIPS_HOLES || !USES_TO_LENGTH }, {\n findIndex: function findIndex(callbackfn /* , that = undefined */) {\n return $findIndex(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables(FIND_INDEX);\n\n\n/***/ }),\n\n/***/ \"c8ba\":\n/***/ (function(module, exports) {\n\nvar g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n\n\n/***/ }),\n\n/***/ \"c975\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $indexOf = __webpack_require__(\"4d64\").indexOf;\nvar arrayMethodIsStrict = __webpack_require__(\"a640\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar nativeIndexOf = [].indexOf;\n\nvar NEGATIVE_ZERO = !!nativeIndexOf && 1 / [1].indexOf(1, -0) < 0;\nvar STRICT_METHOD = arrayMethodIsStrict('indexOf');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('indexOf', { ACCESSORS: true, 1: 0 });\n\n// `Array.prototype.indexOf` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.indexof\n$({ target: 'Array', proto: true, forced: NEGATIVE_ZERO || !STRICT_METHOD || !USES_TO_LENGTH }, {\n indexOf: function indexOf(searchElement /* , fromIndex = 0 */) {\n return NEGATIVE_ZERO\n // convert -0 to +0\n ? nativeIndexOf.apply(this, arguments) || 0\n : $indexOf(this, searchElement, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"ca84\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar has = __webpack_require__(\"5135\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar indexOf = __webpack_require__(\"4d64\").indexOf;\nvar hiddenKeys = __webpack_require__(\"d012\");\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !has(hiddenKeys, key) && has(O, key) && result.push(key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (has(O, key = names[i++])) {\n ~indexOf(result, key) || result.push(key);\n }\n return result;\n};\n\n\n/***/ }),\n\n/***/ \"caad\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $includes = __webpack_require__(\"4d64\").includes;\nvar addToUnscopables = __webpack_require__(\"44d2\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar USES_TO_LENGTH = arrayMethodUsesToLength('indexOf', { ACCESSORS: true, 1: 0 });\n\n// `Array.prototype.includes` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.includes\n$({ target: 'Array', proto: true, forced: !USES_TO_LENGTH }, {\n includes: function includes(el /* , fromIndex = 0 */) {\n return $includes(this, el, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('includes');\n\n\n/***/ }),\n\n/***/ \"cc12\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar isObject = __webpack_require__(\"861d\");\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n\n\n/***/ }),\n\n/***/ \"ce4e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\n\nmodule.exports = function (key, value) {\n try {\n createNonEnumerableProperty(global, key, value);\n } catch (error) {\n global[key] = value;\n } return value;\n};\n\n\n/***/ }),\n\n/***/ \"d012\":\n/***/ (function(module, exports) {\n\nmodule.exports = {};\n\n\n/***/ }),\n\n/***/ \"d039\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n\n\n/***/ }),\n\n/***/ \"d066\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar path = __webpack_require__(\"428f\");\nvar global = __webpack_require__(\"da84\");\n\nvar aFunction = function (variable) {\n return typeof variable == 'function' ? variable : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(path[namespace]) || aFunction(global[namespace])\n : path[namespace] && path[namespace][method] || global[namespace] && global[namespace][method];\n};\n\n\n/***/ }),\n\n/***/ \"d1e7\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar nativePropertyIsEnumerable = {}.propertyIsEnumerable;\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !nativePropertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.github.io/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : nativePropertyIsEnumerable;\n\n\n/***/ }),\n\n/***/ \"d28b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar defineWellKnownSymbol = __webpack_require__(\"746f\");\n\n// `Symbol.iterator` well-known symbol\n// https://tc39.github.io/ecma262/#sec-symbol.iterator\ndefineWellKnownSymbol('iterator');\n\n\n/***/ }),\n\n/***/ \"d2bb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar anObject = __webpack_require__(\"825a\");\nvar aPossiblePrototype = __webpack_require__(\"3bbe\");\n\n// `Object.setPrototypeOf` method\n// https://tc39.github.io/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n/* eslint-disable no-proto */\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n setter = Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set;\n setter.call(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter.call(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n\n\n/***/ }),\n\n/***/ \"d3b7\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar TO_STRING_TAG_SUPPORT = __webpack_require__(\"00ee\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar toString = __webpack_require__(\"b041\");\n\n// `Object.prototype.toString` method\n// https://tc39.github.io/ecma262/#sec-object.prototype.tostring\nif (!TO_STRING_TAG_SUPPORT) {\n redefine(Object.prototype, 'toString', toString, { unsafe: true });\n}\n\n\n/***/ }),\n\n/***/ \"d44e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar defineProperty = __webpack_require__(\"9bf2\").f;\nvar has = __webpack_require__(\"5135\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n\nmodule.exports = function (it, TAG, STATIC) {\n if (it && !has(it = STATIC ? it : it.prototype, TO_STRING_TAG)) {\n defineProperty(it, TO_STRING_TAG, { configurable: true, value: TAG });\n }\n};\n\n\n/***/ }),\n\n/***/ \"d58f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar aFunction = __webpack_require__(\"1c0b\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar IndexedObject = __webpack_require__(\"44ad\");\nvar toLength = __webpack_require__(\"50c4\");\n\n// `Array.prototype.{ reduce, reduceRight }` methods implementation\nvar createMethod = function (IS_RIGHT) {\n return function (that, callbackfn, argumentsLength, memo) {\n aFunction(callbackfn);\n var O = toObject(that);\n var self = IndexedObject(O);\n var length = toLength(O.length);\n var index = IS_RIGHT ? length - 1 : 0;\n var i = IS_RIGHT ? -1 : 1;\n if (argumentsLength < 2) while (true) {\n if (index in self) {\n memo = self[index];\n index += i;\n break;\n }\n index += i;\n if (IS_RIGHT ? index < 0 : length <= index) {\n throw TypeError('Reduce of empty array with no initial value');\n }\n }\n for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {\n memo = callbackfn(memo, self[index], index, O);\n }\n return memo;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.reduce` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.reduce\n left: createMethod(false),\n // `Array.prototype.reduceRight` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.reduceright\n right: createMethod(true)\n};\n\n\n/***/ }),\n\n/***/ \"d784\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n// TODO: Remove from `core-js@4` since it's moved to entry points\n__webpack_require__(\"ac1f\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar fails = __webpack_require__(\"d039\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar regexpExec = __webpack_require__(\"9263\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\n\nvar SPECIES = wellKnownSymbol('species');\n\nvar REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {\n // #replace needs built-in support for named groups.\n // #match works fine because it just return the exec results, even if it has\n // a \"grops\" property.\n var re = /./;\n re.exec = function () {\n var result = [];\n result.groups = { a: '7' };\n return result;\n };\n return ''.replace(re, '$<a>') !== '7';\n});\n\n// IE <= 11 replaces $0 with the whole match, as if it was $&\n// https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0\nvar REPLACE_KEEPS_$0 = (function () {\n return 'a'.replace(/./, '$0') === '$0';\n})();\n\nvar REPLACE = wellKnownSymbol('replace');\n// Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string\nvar REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {\n if (/./[REPLACE]) {\n return /./[REPLACE]('a', '$0') === '';\n }\n return false;\n})();\n\n// Chrome 51 has a buggy \"split\" implementation when RegExp#exec !== nativeExec\n// Weex JS has frozen built-in prototypes, so use try / catch wrapper\nvar SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails(function () {\n var re = /(?:)/;\n var originalExec = re.exec;\n re.exec = function () { return originalExec.apply(this, arguments); };\n var result = 'ab'.split(re);\n return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';\n});\n\nmodule.exports = function (KEY, length, exec, sham) {\n var SYMBOL = wellKnownSymbol(KEY);\n\n var DELEGATES_TO_SYMBOL = !fails(function () {\n // String methods call symbol-named RegEp methods\n var O = {};\n O[SYMBOL] = function () { return 7; };\n return ''[KEY](O) != 7;\n });\n\n var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {\n // Symbol-named RegExp methods call .exec\n var execCalled = false;\n var re = /a/;\n\n if (KEY === 'split') {\n // We can't use real regex here since it causes deoptimization\n // and serious performance degradation in V8\n // https://github.com/zloirock/core-js/issues/306\n re = {};\n // RegExp[@@split] doesn't call the regex's exec method, but first creates\n // a new one. We need to return the patched regex when creating the new one.\n re.constructor = {};\n re.constructor[SPECIES] = function () { return re; };\n re.flags = '';\n re[SYMBOL] = /./[SYMBOL];\n }\n\n re.exec = function () { execCalled = true; return null; };\n\n re[SYMBOL]('');\n return !execCalled;\n });\n\n if (\n !DELEGATES_TO_SYMBOL ||\n !DELEGATES_TO_EXEC ||\n (KEY === 'replace' && !(\n REPLACE_SUPPORTS_NAMED_GROUPS &&\n REPLACE_KEEPS_$0 &&\n !REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE\n )) ||\n (KEY === 'split' && !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC)\n ) {\n var nativeRegExpMethod = /./[SYMBOL];\n var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {\n if (regexp.exec === regexpExec) {\n if (DELEGATES_TO_SYMBOL && !forceStringMethod) {\n // The native String method already delegates to @@method (this\n // polyfilled function), leasing to infinite recursion.\n // We avoid it by directly calling the native @@method method.\n return { done: true, value: nativeRegExpMethod.call(regexp, str, arg2) };\n }\n return { done: true, value: nativeMethod.call(str, regexp, arg2) };\n }\n return { done: false };\n }, {\n REPLACE_KEEPS_$0: REPLACE_KEEPS_$0,\n REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE: REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE\n });\n var stringMethod = methods[0];\n var regexMethod = methods[1];\n\n redefine(String.prototype, KEY, stringMethod);\n redefine(RegExp.prototype, SYMBOL, length == 2\n // 21.2.5.8 RegExp.prototype[@@replace](string, replaceValue)\n // 21.2.5.11 RegExp.prototype[@@split](string, limit)\n ? function (string, arg) { return regexMethod.call(string, this, arg); }\n // 21.2.5.6 RegExp.prototype[@@match](string)\n // 21.2.5.9 RegExp.prototype[@@search](string)\n : function (string) { return regexMethod.call(string, this); }\n );\n }\n\n if (sham) createNonEnumerableProperty(RegExp.prototype[SYMBOL], 'sham', true);\n};\n\n\n/***/ }),\n\n/***/ \"d81d\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $map = __webpack_require__(\"b727\").map;\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('map');\n// FF49- issue\nvar USES_TO_LENGTH = arrayMethodUsesToLength('map');\n\n// `Array.prototype.map` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.map\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n map: function map(callbackfn /* , thisArg */) {\n return $map(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"da84\":\n/***/ (function(module, exports, __webpack_require__) {\n\n/* WEBPACK VAR INJECTION */(function(global) {var check = function (it) {\n return it && it.Math == Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line no-undef\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n // eslint-disable-next-line no-new-func\n Function('return this')();\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(\"c8ba\")))\n\n/***/ }),\n\n/***/ \"dbb4\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar ownKeys = __webpack_require__(\"56ef\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar getOwnPropertyDescriptorModule = __webpack_require__(\"06cf\");\nvar createProperty = __webpack_require__(\"8418\");\n\n// `Object.getOwnPropertyDescriptors` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptors\n$({ target: 'Object', stat: true, sham: !DESCRIPTORS }, {\n getOwnPropertyDescriptors: function getOwnPropertyDescriptors(object) {\n var O = toIndexedObject(object);\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n var keys = ownKeys(O);\n var result = {};\n var index = 0;\n var key, descriptor;\n while (keys.length > index) {\n descriptor = getOwnPropertyDescriptor(O, key = keys[index++]);\n if (descriptor !== undefined) createProperty(result, key, descriptor);\n }\n return result;\n }\n});\n\n\n/***/ }),\n\n/***/ \"dbf1\":\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* WEBPACK VAR INJECTION */(function(global) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return console; });\nfunction getConsole() {\n if (typeof window !== \"undefined\") {\n return window.console;\n }\n\n return global.console;\n}\n\nvar console = getConsole();\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(\"c8ba\")))\n\n/***/ }),\n\n/***/ \"ddb0\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar DOMIterables = __webpack_require__(\"fdbc\");\nvar ArrayIteratorMethods = __webpack_require__(\"e260\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar ArrayValues = ArrayIteratorMethods.values;\n\nfor (var COLLECTION_NAME in DOMIterables) {\n var Collection = global[COLLECTION_NAME];\n var CollectionPrototype = Collection && Collection.prototype;\n if (CollectionPrototype) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[ITERATOR] !== ArrayValues) try {\n createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);\n } catch (error) {\n CollectionPrototype[ITERATOR] = ArrayValues;\n }\n if (!CollectionPrototype[TO_STRING_TAG]) {\n createNonEnumerableProperty(CollectionPrototype, TO_STRING_TAG, COLLECTION_NAME);\n }\n if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {\n createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);\n } catch (error) {\n CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];\n }\n }\n }\n}\n\n\n/***/ }),\n\n/***/ \"df75\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar internalObjectKeys = __webpack_require__(\"ca84\");\nvar enumBugKeys = __webpack_require__(\"7839\");\n\n// `Object.keys` method\n// https://tc39.github.io/ecma262/#sec-object.keys\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};\n\n\n/***/ }),\n\n/***/ \"e01a\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n// `Symbol.prototype.description` getter\n// https://tc39.github.io/ecma262/#sec-symbol.prototype.description\n\nvar $ = __webpack_require__(\"23e7\");\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar global = __webpack_require__(\"da84\");\nvar has = __webpack_require__(\"5135\");\nvar isObject = __webpack_require__(\"861d\");\nvar defineProperty = __webpack_require__(\"9bf2\").f;\nvar copyConstructorProperties = __webpack_require__(\"e893\");\n\nvar NativeSymbol = global.Symbol;\n\nif (DESCRIPTORS && typeof NativeSymbol == 'function' && (!('description' in NativeSymbol.prototype) ||\n // Safari 12 bug\n NativeSymbol().description !== undefined\n)) {\n var EmptyStringDescriptionStore = {};\n // wrap Symbol constructor for correct work with undefined description\n var SymbolWrapper = function Symbol() {\n var description = arguments.length < 1 || arguments[0] === undefined ? undefined : String(arguments[0]);\n var result = this instanceof SymbolWrapper\n ? new NativeSymbol(description)\n // in Edge 13, String(Symbol(undefined)) === 'Symbol(undefined)'\n : description === undefined ? NativeSymbol() : NativeSymbol(description);\n if (description === '') EmptyStringDescriptionStore[result] = true;\n return result;\n };\n copyConstructorProperties(SymbolWrapper, NativeSymbol);\n var symbolPrototype = SymbolWrapper.prototype = NativeSymbol.prototype;\n symbolPrototype.constructor = SymbolWrapper;\n\n var symbolToString = symbolPrototype.toString;\n var native = String(NativeSymbol('test')) == 'Symbol(test)';\n var regexp = /^Symbol\\((.*)\\)[^)]+$/;\n defineProperty(symbolPrototype, 'description', {\n configurable: true,\n get: function description() {\n var symbol = isObject(this) ? this.valueOf() : this;\n var string = symbolToString.call(symbol);\n if (has(EmptyStringDescriptionStore, symbol)) return '';\n var desc = native ? string.slice(7, -1) : string.replace(regexp, '$1');\n return desc === '' ? undefined : desc;\n }\n });\n\n $({ global: true, forced: true }, {\n Symbol: SymbolWrapper\n });\n}\n\n\n/***/ }),\n\n/***/ \"e163\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar has = __webpack_require__(\"5135\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar sharedKey = __webpack_require__(\"f772\");\nvar CORRECT_PROTOTYPE_GETTER = __webpack_require__(\"e177\");\n\nvar IE_PROTO = sharedKey('IE_PROTO');\nvar ObjectPrototype = Object.prototype;\n\n// `Object.getPrototypeOf` method\n// https://tc39.github.io/ecma262/#sec-object.getprototypeof\nmodule.exports = CORRECT_PROTOTYPE_GETTER ? Object.getPrototypeOf : function (O) {\n O = toObject(O);\n if (has(O, IE_PROTO)) return O[IE_PROTO];\n if (typeof O.constructor == 'function' && O instanceof O.constructor) {\n return O.constructor.prototype;\n } return O instanceof Object ? ObjectPrototype : null;\n};\n\n\n/***/ }),\n\n/***/ \"e177\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n\n\n/***/ }),\n\n/***/ \"e260\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar addToUnscopables = __webpack_require__(\"44d2\");\nvar Iterators = __webpack_require__(\"3f8c\");\nvar InternalStateModule = __webpack_require__(\"69f3\");\nvar defineIterator = __webpack_require__(\"7dd0\");\n\nvar ARRAY_ITERATOR = 'Array Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);\n\n// `Array.prototype.entries` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.entries\n// `Array.prototype.keys` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.keys\n// `Array.prototype.values` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.values\n// `Array.prototype[@@iterator]` method\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@iterator\n// `CreateArrayIterator` internal method\n// https://tc39.github.io/ecma262/#sec-createarrayiterator\nmodule.exports = defineIterator(Array, 'Array', function (iterated, kind) {\n setInternalState(this, {\n type: ARRAY_ITERATOR,\n target: toIndexedObject(iterated), // target\n index: 0, // next index\n kind: kind // kind\n });\n// `%ArrayIteratorPrototype%.next` method\n// https://tc39.github.io/ecma262/#sec-%arrayiteratorprototype%.next\n}, function () {\n var state = getInternalState(this);\n var target = state.target;\n var kind = state.kind;\n var index = state.index++;\n if (!target || index >= target.length) {\n state.target = undefined;\n return { value: undefined, done: true };\n }\n if (kind == 'keys') return { value: index, done: false };\n if (kind == 'values') return { value: target[index], done: false };\n return { value: [index, target[index]], done: false };\n}, 'values');\n\n// argumentsList[@@iterator] is %ArrayProto_values%\n// https://tc39.github.io/ecma262/#sec-createunmappedargumentsobject\n// https://tc39.github.io/ecma262/#sec-createmappedargumentsobject\nIterators.Arguments = Iterators.Array;\n\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries');\n\n\n/***/ }),\n\n/***/ \"e439\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar fails = __webpack_require__(\"d039\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar nativeGetOwnPropertyDescriptor = __webpack_require__(\"06cf\").f;\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeGetOwnPropertyDescriptor(1); });\nvar FORCED = !DESCRIPTORS || FAILS_ON_PRIMITIVES;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptor\n$({ target: 'Object', stat: true, forced: FORCED, sham: !DESCRIPTORS }, {\n getOwnPropertyDescriptor: function getOwnPropertyDescriptor(it, key) {\n return nativeGetOwnPropertyDescriptor(toIndexedObject(it), key);\n }\n});\n\n\n/***/ }),\n\n/***/ \"e538\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nexports.f = wellKnownSymbol;\n\n\n/***/ }),\n\n/***/ \"e893\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar has = __webpack_require__(\"5135\");\nvar ownKeys = __webpack_require__(\"56ef\");\nvar getOwnPropertyDescriptorModule = __webpack_require__(\"06cf\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\n\nmodule.exports = function (target, source) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n if (!has(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n};\n\n\n/***/ }),\n\n/***/ \"e8b5\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar classof = __webpack_require__(\"c6b6\");\n\n// `IsArray` abstract operation\n// https://tc39.github.io/ecma262/#sec-isarray\nmodule.exports = Array.isArray || function isArray(arg) {\n return classof(arg) == 'Array';\n};\n\n\n/***/ }),\n\n/***/ \"e95a\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar Iterators = __webpack_require__(\"3f8c\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar ArrayPrototype = Array.prototype;\n\n// check on default Array iterator\nmodule.exports = function (it) {\n return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);\n};\n\n\n/***/ }),\n\n/***/ \"f5df\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar TO_STRING_TAG_SUPPORT = __webpack_require__(\"00ee\");\nvar classofRaw = __webpack_require__(\"c6b6\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : result;\n};\n\n\n/***/ }),\n\n/***/ \"f772\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar shared = __webpack_require__(\"5692\");\nvar uid = __webpack_require__(\"90e3\");\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n\n\n/***/ }),\n\n/***/ \"fb15\":\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n// ESM COMPAT FLAG\n__webpack_require__.r(__webpack_exports__);\n\n// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js\n// This file is imported into lib/wc client bundles.\n\nif (typeof window !== 'undefined') {\n var currentScript = window.document.currentScript\n if (true) {\n var getCurrentScript = __webpack_require__(\"8875\")\n currentScript = getCurrentScript()\n\n // for backward compatibility, because previously we directly included the polyfill\n if (!('currentScript' in document)) {\n Object.defineProperty(document, 'currentScript', { get: getCurrentScript })\n }\n }\n\n var src = currentScript && currentScript.src.match(/(.+\\/)[^/]+\\.js(\\?.*)?$/)\n if (src) {\n __webpack_require__.p = src[1] // eslint-disable-line\n }\n}\n\n// Indicate to webpack that this file can be concatenated\n/* harmony default export */ var setPublicPath = (null);\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.concat.js\nvar es_array_concat = __webpack_require__(\"99af\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.filter.js\nvar es_array_filter = __webpack_require__(\"4de4\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.for-each.js\nvar es_array_for_each = __webpack_require__(\"4160\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.index-of.js\nvar es_array_index_of = __webpack_require__(\"c975\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.map.js\nvar es_array_map = __webpack_require__(\"d81d\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.splice.js\nvar es_array_splice = __webpack_require__(\"a434\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.for-each.js\nvar web_dom_collections_for_each = __webpack_require__(\"159b\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.js\nvar es_symbol = __webpack_require__(\"a4d3\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.get-own-property-descriptor.js\nvar es_object_get_own_property_descriptor = __webpack_require__(\"e439\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.get-own-property-descriptors.js\nvar es_object_get_own_property_descriptors = __webpack_require__(\"dbb4\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.keys.js\nvar es_object_keys = __webpack_require__(\"b64b\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/defineProperty.js\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js\n\n\n\n\n\n\n\n\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nfunction _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js\nfunction _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.description.js\nvar es_symbol_description = __webpack_require__(\"e01a\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.iterator.js\nvar es_symbol_iterator = __webpack_require__(\"d28b\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.iterator.js\nvar es_array_iterator = __webpack_require__(\"e260\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js\nvar es_object_to_string = __webpack_require__(\"d3b7\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.iterator.js\nvar es_string_iterator = __webpack_require__(\"3ca3\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.iterator.js\nvar web_dom_collections_iterator = __webpack_require__(\"ddb0\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js\n\n\n\n\n\n\n\nfunction _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.from.js\nvar es_array_from = __webpack_require__(\"a630\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.slice.js\nvar es_array_slice = __webpack_require__(\"fb6a\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.function.name.js\nvar es_function_name = __webpack_require__(\"b0c0\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.to-string.js\nvar es_regexp_to_string = __webpack_require__(\"25f0\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js\n\n\n\n\n\n\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableRest.js\nfunction _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js\n\n\n\n\nfunction _slicedToArray(arr, i) {\n return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArray.js\n\n\n\n\n\n\n\n\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js\n\n\n\n\nfunction _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n}\n// EXTERNAL MODULE: external {\"commonjs\":\"sortablejs\",\"commonjs2\":\"sortablejs\",\"amd\":\"sortablejs\",\"root\":\"Sortable\"}\nvar external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_ = __webpack_require__(\"a352\");\nvar external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_default = /*#__PURE__*/__webpack_require__.n(external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_);\n\n// CONCATENATED MODULE: ./src/util/htmlHelper.js\nfunction removeNode(node) {\n if (node.parentElement !== null) {\n node.parentElement.removeChild(node);\n }\n}\n\nfunction insertNodeAt(fatherNode, node, position) {\n var refNode = position === 0 ? fatherNode.children[0] : fatherNode.children[position - 1].nextSibling;\n fatherNode.insertBefore(node, refNode);\n}\n\n\n// EXTERNAL MODULE: ./src/util/console.js\nvar console = __webpack_require__(\"dbf1\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.reduce.js\nvar es_array_reduce = __webpack_require__(\"13d5\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.entries.js\nvar es_object_entries = __webpack_require__(\"4fad\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.exec.js\nvar es_regexp_exec = __webpack_require__(\"ac1f\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.replace.js\nvar es_string_replace = __webpack_require__(\"5319\");\n\n// CONCATENATED MODULE: ./src/util/string.js\n\n\n\nfunction cached(fn) {\n var cache = Object.create(null);\n return function cachedFn(str) {\n var hit = cache[str];\n return hit || (cache[str] = fn(str));\n };\n}\n\nvar regex = /-(\\w)/g;\nvar camelize = cached(function (str) {\n return str.replace(regex, function (_, c) {\n return c.toUpperCase();\n });\n});\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.flat-map.js\nvar es_array_flat_map = __webpack_require__(\"5db7\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.unscopables.flat-map.js\nvar es_array_unscopables_flat_map = __webpack_require__(\"73d9\");\n\n// CONCATENATED MODULE: ./src/core/sortableEvents.js\n\n\n\n\nvar manageAndEmit = [\"Start\", \"Add\", \"Remove\", \"Update\", \"End\"];\nvar emit = [\"Choose\", \"Unchoose\", \"Sort\", \"Filter\", \"Clone\"];\nvar manage = [\"Move\"];\nvar eventHandlerNames = [manage, manageAndEmit, emit].flatMap(function (events) {\n return events;\n}).map(function (evt) {\n return \"on\".concat(evt);\n});\nvar events = {\n manage: manage,\n manageAndEmit: manageAndEmit,\n emit: emit\n};\n\nfunction isReadOnly(eventName) {\n return eventHandlerNames.indexOf(eventName) !== -1;\n}\n\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.includes.js\nvar es_array_includes = __webpack_require__(\"caad\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.starts-with.js\nvar es_string_starts_with = __webpack_require__(\"2ca0\");\n\n// CONCATENATED MODULE: ./src/util/tags.js\n\n\nvar tags = [\"a\", \"abbr\", \"address\", \"area\", \"article\", \"aside\", \"audio\", \"b\", \"base\", \"bdi\", \"bdo\", \"blockquote\", \"body\", \"br\", \"button\", \"canvas\", \"caption\", \"cite\", \"code\", \"col\", \"colgroup\", \"data\", \"datalist\", \"dd\", \"del\", \"details\", \"dfn\", \"dialog\", \"div\", \"dl\", \"dt\", \"em\", \"embed\", \"fieldset\", \"figcaption\", \"figure\", \"footer\", \"form\", \"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\", \"head\", \"header\", \"hgroup\", \"hr\", \"html\", \"i\", \"iframe\", \"img\", \"input\", \"ins\", \"kbd\", \"label\", \"legend\", \"li\", \"link\", \"main\", \"map\", \"mark\", \"math\", \"menu\", \"menuitem\", \"meta\", \"meter\", \"nav\", \"noscript\", \"object\", \"ol\", \"optgroup\", \"option\", \"output\", \"p\", \"param\", \"picture\", \"pre\", \"progress\", \"q\", \"rb\", \"rp\", \"rt\", \"rtc\", \"ruby\", \"s\", \"samp\", \"script\", \"section\", \"select\", \"slot\", \"small\", \"source\", \"span\", \"strong\", \"style\", \"sub\", \"summary\", \"sup\", \"svg\", \"table\", \"tbody\", \"td\", \"template\", \"textarea\", \"tfoot\", \"th\", \"thead\", \"time\", \"title\", \"tr\", \"track\", \"u\", \"ul\", \"var\", \"video\", \"wbr\"];\n\nfunction isHtmlTag(name) {\n return tags.includes(name);\n}\n\nfunction isTransition(name) {\n return [\"transition-group\", \"TransitionGroup\"].includes(name);\n}\n\nfunction isHtmlAttribute(value) {\n return [\"id\", \"class\", \"role\", \"style\"].includes(value) || value.startsWith(\"data-\") || value.startsWith(\"aria-\") || value.startsWith(\"on\");\n}\n\n\n// CONCATENATED MODULE: ./src/core/componentBuilderHelper.js\n\n\n\n\n\n\n\n\n\n\n\n\nfunction project(entries) {\n return entries.reduce(function (res, _ref) {\n var _ref2 = _slicedToArray(_ref, 2),\n key = _ref2[0],\n value = _ref2[1];\n\n res[key] = value;\n return res;\n }, {});\n}\n\nfunction getComponentAttributes(_ref3) {\n var $attrs = _ref3.$attrs,\n _ref3$componentData = _ref3.componentData,\n componentData = _ref3$componentData === void 0 ? {} : _ref3$componentData;\n var attributes = project(Object.entries($attrs).filter(function (_ref4) {\n var _ref5 = _slicedToArray(_ref4, 2),\n key = _ref5[0],\n _ = _ref5[1];\n\n return isHtmlAttribute(key);\n }));\n return _objectSpread2(_objectSpread2({}, attributes), componentData);\n}\n\nfunction createSortableOption(_ref6) {\n var $attrs = _ref6.$attrs,\n callBackBuilder = _ref6.callBackBuilder;\n var options = project(getValidSortableEntries($attrs));\n Object.entries(callBackBuilder).forEach(function (_ref7) {\n var _ref8 = _slicedToArray(_ref7, 2),\n eventType = _ref8[0],\n eventBuilder = _ref8[1];\n\n events[eventType].forEach(function (event) {\n options[\"on\".concat(event)] = eventBuilder(event);\n });\n });\n var draggable = \"[data-draggable]\".concat(options.draggable || \"\");\n return _objectSpread2(_objectSpread2({}, options), {}, {\n draggable: draggable\n });\n}\n\nfunction getValidSortableEntries(value) {\n return Object.entries(value).filter(function (_ref9) {\n var _ref10 = _slicedToArray(_ref9, 2),\n key = _ref10[0],\n _ = _ref10[1];\n\n return !isHtmlAttribute(key);\n }).map(function (_ref11) {\n var _ref12 = _slicedToArray(_ref11, 2),\n key = _ref12[0],\n value = _ref12[1];\n\n return [camelize(key), value];\n }).filter(function (_ref13) {\n var _ref14 = _slicedToArray(_ref13, 2),\n key = _ref14[0],\n _ = _ref14[1];\n\n return !isReadOnly(key);\n });\n}\n\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.find-index.js\nvar es_array_find_index = __webpack_require__(\"c740\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js\nfunction _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}\n// CONCATENATED MODULE: ./src/core/componentStructure.js\n\n\n\n\n\n\n\n\nvar getHtmlElementFromNode = function getHtmlElementFromNode(_ref) {\n var el = _ref.el;\n return el;\n};\n\nvar addContext = function addContext(domElement, context) {\n return domElement.__draggable_context = context;\n};\n\nvar getContext = function getContext(domElement) {\n return domElement.__draggable_context;\n};\n\nvar componentStructure_ComponentStructure = /*#__PURE__*/function () {\n function ComponentStructure(_ref2) {\n var _ref2$nodes = _ref2.nodes,\n header = _ref2$nodes.header,\n defaultNodes = _ref2$nodes.default,\n footer = _ref2$nodes.footer,\n root = _ref2.root,\n realList = _ref2.realList;\n\n _classCallCheck(this, ComponentStructure);\n\n this.defaultNodes = defaultNodes;\n this.children = [].concat(_toConsumableArray(header), _toConsumableArray(defaultNodes), _toConsumableArray(footer));\n this.externalComponent = root.externalComponent;\n this.rootTransition = root.transition;\n this.tag = root.tag;\n this.realList = realList;\n }\n\n _createClass(ComponentStructure, [{\n key: \"render\",\n value: function render(h, attributes) {\n var tag = this.tag,\n children = this.children,\n _isRootComponent = this._isRootComponent;\n var option = !_isRootComponent ? children : {\n default: function _default() {\n return children;\n }\n };\n return h(tag, attributes, option);\n }\n }, {\n key: \"updated\",\n value: function updated() {\n var defaultNodes = this.defaultNodes,\n realList = this.realList;\n defaultNodes.forEach(function (node, index) {\n addContext(getHtmlElementFromNode(node), {\n element: realList[index],\n index: index\n });\n });\n }\n }, {\n key: \"getUnderlyingVm\",\n value: function getUnderlyingVm(domElement) {\n return getContext(domElement);\n }\n }, {\n key: \"getVmIndexFromDomIndex\",\n value: function getVmIndexFromDomIndex(domIndex, element) {\n var defaultNodes = this.defaultNodes;\n var length = defaultNodes.length;\n var domChildren = element.children;\n var domElement = domChildren.item(domIndex);\n\n if (domElement === null) {\n return length;\n }\n\n var context = getContext(domElement);\n\n if (context) {\n return context.index;\n }\n\n if (length === 0) {\n return 0;\n }\n\n var firstDomListElement = getHtmlElementFromNode(defaultNodes[0]);\n\n var indexFirstDomListElement = _toConsumableArray(domChildren).findIndex(function (element) {\n return element === firstDomListElement;\n });\n\n return domIndex < indexFirstDomListElement ? 0 : length;\n }\n }, {\n key: \"_isRootComponent\",\n get: function get() {\n return this.externalComponent || this.rootTransition;\n }\n }]);\n\n return ComponentStructure;\n}();\n\n\n// EXTERNAL MODULE: external {\"commonjs\":\"vue\",\"commonjs2\":\"vue\",\"root\":\"Vue\"}\nvar external_commonjs_vue_commonjs2_vue_root_Vue_ = __webpack_require__(\"8bbf\");\n\n// CONCATENATED MODULE: ./src/core/renderHelper.js\n\n\n\n\n\n\n\n\n\nfunction getSlot(slots, key) {\n var slotValue = slots[key];\n return slotValue ? slotValue() : [];\n}\n\nfunction computeNodes(_ref) {\n var $slots = _ref.$slots,\n realList = _ref.realList,\n getKey = _ref.getKey;\n var normalizedList = realList || [];\n\n var _map = [\"header\", \"footer\"].map(function (name) {\n return getSlot($slots, name);\n }),\n _map2 = _slicedToArray(_map, 2),\n header = _map2[0],\n footer = _map2[1];\n\n var item = $slots.item;\n\n if (!item) {\n throw new Error(\"draggable element must have an item slot\");\n }\n\n var defaultNodes = normalizedList.flatMap(function (element, index) {\n return item({\n element: element,\n index: index\n }).map(function (node) {\n node.key = getKey(element);\n node.props = _objectSpread2(_objectSpread2({}, node.props || {}), {}, {\n \"data-draggable\": true\n });\n return node;\n });\n });\n\n if (defaultNodes.length !== normalizedList.length) {\n throw new Error(\"Item slot must have only one child\");\n }\n\n return {\n header: header,\n footer: footer,\n default: defaultNodes\n };\n}\n\nfunction getRootInformation(tag) {\n var transition = isTransition(tag);\n var externalComponent = !isHtmlTag(tag) && !transition;\n return {\n transition: transition,\n externalComponent: externalComponent,\n tag: externalComponent ? Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"resolveComponent\"])(tag) : transition ? external_commonjs_vue_commonjs2_vue_root_Vue_[\"TransitionGroup\"] : tag\n };\n}\n\nfunction computeComponentStructure(_ref2) {\n var $slots = _ref2.$slots,\n tag = _ref2.tag,\n realList = _ref2.realList,\n getKey = _ref2.getKey;\n var nodes = computeNodes({\n $slots: $slots,\n realList: realList,\n getKey: getKey\n });\n var root = getRootInformation(tag);\n return new componentStructure_ComponentStructure({\n nodes: nodes,\n root: root,\n realList: realList\n });\n}\n\n\n// CONCATENATED MODULE: ./src/vuedraggable.js\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nfunction _emit(evtName, evtData) {\n var _this = this;\n\n Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"nextTick\"])(function () {\n return _this.$emit(evtName.toLowerCase(), evtData);\n });\n}\n\nfunction _manage(evtName) {\n var _this2 = this;\n\n return function (evtData, originalElement) {\n if (_this2.realList !== null) {\n return _this2[\"onDrag\".concat(evtName)](evtData, originalElement);\n }\n };\n}\n\nfunction _manageAndEmit(evtName) {\n var _this3 = this;\n\n var delegateCallBack = _manage.call(this, evtName);\n\n return function (evtData, originalElement) {\n delegateCallBack.call(_this3, evtData, originalElement);\n\n _emit.call(_this3, evtName, evtData);\n };\n}\n\nvar draggingElement = null;\nvar props = {\n list: {\n type: Array,\n required: false,\n default: null\n },\n modelValue: {\n type: Array,\n required: false,\n default: null\n },\n itemKey: {\n type: [String, Function],\n required: true\n },\n clone: {\n type: Function,\n default: function _default(original) {\n return original;\n }\n },\n tag: {\n type: String,\n default: \"div\"\n },\n move: {\n type: Function,\n default: null\n },\n componentData: {\n type: Object,\n required: false,\n default: null\n }\n};\nvar emits = [\"update:modelValue\", \"change\"].concat(_toConsumableArray([].concat(_toConsumableArray(events.manageAndEmit), _toConsumableArray(events.emit)).map(function (evt) {\n return evt.toLowerCase();\n})));\nvar draggableComponent = Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"defineComponent\"])({\n name: \"draggable\",\n inheritAttrs: false,\n props: props,\n emits: emits,\n data: function data() {\n return {\n error: false\n };\n },\n render: function render() {\n try {\n this.error = false;\n var $slots = this.$slots,\n $attrs = this.$attrs,\n tag = this.tag,\n componentData = this.componentData,\n realList = this.realList,\n getKey = this.getKey;\n var componentStructure = computeComponentStructure({\n $slots: $slots,\n tag: tag,\n realList: realList,\n getKey: getKey\n });\n this.componentStructure = componentStructure;\n var attributes = getComponentAttributes({\n $attrs: $attrs,\n componentData: componentData\n });\n return componentStructure.render(external_commonjs_vue_commonjs2_vue_root_Vue_[\"h\"], attributes);\n } catch (err) {\n this.error = true;\n return Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"h\"])(\"pre\", {\n style: {\n color: \"red\"\n }\n }, err.stack);\n }\n },\n created: function created() {\n if (this.list !== null && this.modelValue !== null) {\n console[\"a\" /* console */].error(\"modelValue and list props are mutually exclusive! Please set one or another.\");\n }\n },\n mounted: function mounted() {\n var _this4 = this;\n\n if (this.error) {\n return;\n }\n\n var $attrs = this.$attrs,\n $el = this.$el,\n componentStructure = this.componentStructure;\n componentStructure.updated();\n var sortableOptions = createSortableOption({\n $attrs: $attrs,\n callBackBuilder: {\n manageAndEmit: function manageAndEmit(event) {\n return _manageAndEmit.call(_this4, event);\n },\n emit: function emit(event) {\n return _emit.bind(_this4, event);\n },\n manage: function manage(event) {\n return _manage.call(_this4, event);\n }\n }\n });\n var targetDomElement = $el.nodeType === 1 ? $el : $el.parentElement;\n this._sortable = new external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_default.a(targetDomElement, sortableOptions);\n this.targetDomElement = targetDomElement;\n targetDomElement.__draggable_component__ = this;\n },\n updated: function updated() {\n this.componentStructure.updated();\n },\n beforeUnmount: function beforeUnmount() {\n if (this._sortable !== undefined) this._sortable.destroy();\n },\n computed: {\n realList: function realList() {\n var list = this.list;\n return list ? list : this.modelValue;\n },\n getKey: function getKey() {\n var itemKey = this.itemKey;\n\n if (typeof itemKey === \"function\") {\n return itemKey;\n }\n\n return function (element) {\n return element[itemKey];\n };\n }\n },\n watch: {\n $attrs: {\n handler: function handler(newOptionValue) {\n var _sortable = this._sortable;\n if (!_sortable) return;\n getValidSortableEntries(newOptionValue).forEach(function (_ref) {\n var _ref2 = _slicedToArray(_ref, 2),\n key = _ref2[0],\n value = _ref2[1];\n\n _sortable.option(key, value);\n });\n },\n deep: true\n }\n },\n methods: {\n getUnderlyingVm: function getUnderlyingVm(domElement) {\n return this.componentStructure.getUnderlyingVm(domElement) || null;\n },\n getUnderlyingPotencialDraggableComponent: function getUnderlyingPotencialDraggableComponent(htmElement) {\n //TODO check case where you need to see component children\n return htmElement.__draggable_component__;\n },\n emitChanges: function emitChanges(evt) {\n var _this5 = this;\n\n Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"nextTick\"])(function () {\n return _this5.$emit(\"change\", evt);\n });\n },\n alterList: function alterList(onList) {\n if (this.list) {\n onList(this.list);\n return;\n }\n\n var newList = _toConsumableArray(this.modelValue);\n\n onList(newList);\n this.$emit(\"update:modelValue\", newList);\n },\n spliceList: function spliceList() {\n var _arguments = arguments;\n\n var spliceList = function spliceList(list) {\n return list.splice.apply(list, _toConsumableArray(_arguments));\n };\n\n this.alterList(spliceList);\n },\n updatePosition: function updatePosition(oldIndex, newIndex) {\n var updatePosition = function updatePosition(list) {\n return list.splice(newIndex, 0, list.splice(oldIndex, 1)[0]);\n };\n\n this.alterList(updatePosition);\n },\n getRelatedContextFromMoveEvent: function getRelatedContextFromMoveEvent(_ref3) {\n var to = _ref3.to,\n related = _ref3.related;\n var component = this.getUnderlyingPotencialDraggableComponent(to);\n\n if (!component) {\n return {\n component: component\n };\n }\n\n var list = component.realList;\n var context = {\n list: list,\n component: component\n };\n\n if (to !== related && list) {\n var destination = component.getUnderlyingVm(related) || {};\n return _objectSpread2(_objectSpread2({}, destination), context);\n }\n\n return context;\n },\n getVmIndexFromDomIndex: function getVmIndexFromDomIndex(domIndex) {\n return this.componentStructure.getVmIndexFromDomIndex(domIndex, this.targetDomElement);\n },\n onDragStart: function onDragStart(evt) {\n this.context = this.getUnderlyingVm(evt.item);\n evt.item._underlying_vm_ = this.clone(this.context.element);\n draggingElement = evt.item;\n },\n onDragAdd: function onDragAdd(evt) {\n var element = evt.item._underlying_vm_;\n\n if (element === undefined) {\n return;\n }\n\n removeNode(evt.item);\n var newIndex = this.getVmIndexFromDomIndex(evt.newIndex);\n this.spliceList(newIndex, 0, element);\n var added = {\n element: element,\n newIndex: newIndex\n };\n this.emitChanges({\n added: added\n });\n },\n onDragRemove: function onDragRemove(evt) {\n insertNodeAt(this.$el, evt.item, evt.oldIndex);\n\n if (evt.pullMode === \"clone\") {\n removeNode(evt.clone);\n return;\n }\n\n var _this$context = this.context,\n oldIndex = _this$context.index,\n element = _this$context.element;\n this.spliceList(oldIndex, 1);\n var removed = {\n element: element,\n oldIndex: oldIndex\n };\n this.emitChanges({\n removed: removed\n });\n },\n onDragUpdate: function onDragUpdate(evt) {\n removeNode(evt.item);\n insertNodeAt(evt.from, evt.item, evt.oldIndex);\n var oldIndex = this.context.index;\n var newIndex = this.getVmIndexFromDomIndex(evt.newIndex);\n this.updatePosition(oldIndex, newIndex);\n var moved = {\n element: this.context.element,\n oldIndex: oldIndex,\n newIndex: newIndex\n };\n this.emitChanges({\n moved: moved\n });\n },\n computeFutureIndex: function computeFutureIndex(relatedContext, evt) {\n if (!relatedContext.element) {\n return 0;\n }\n\n var domChildren = _toConsumableArray(evt.to.children).filter(function (el) {\n return el.style[\"display\"] !== \"none\";\n });\n\n var currentDomIndex = domChildren.indexOf(evt.related);\n var currentIndex = relatedContext.component.getVmIndexFromDomIndex(currentDomIndex);\n var draggedInList = domChildren.indexOf(draggingElement) !== -1;\n return draggedInList || !evt.willInsertAfter ? currentIndex : currentIndex + 1;\n },\n onDragMove: function onDragMove(evt, originalEvent) {\n var move = this.move,\n realList = this.realList;\n\n if (!move || !realList) {\n return true;\n }\n\n var relatedContext = this.getRelatedContextFromMoveEvent(evt);\n var futureIndex = this.computeFutureIndex(relatedContext, evt);\n\n var draggedContext = _objectSpread2(_objectSpread2({}, this.context), {}, {\n futureIndex: futureIndex\n });\n\n var sendEvent = _objectSpread2(_objectSpread2({}, evt), {}, {\n relatedContext: relatedContext,\n draggedContext: draggedContext\n });\n\n return move(sendEvent, originalEvent);\n },\n onDragEnd: function onDragEnd() {\n draggingElement = null;\n }\n }\n});\n/* harmony default export */ var vuedraggable = (draggableComponent);\n// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js\n\n\n/* harmony default export */ var entry_lib = __webpack_exports__[\"default\"] = (vuedraggable);\n\n\n\n/***/ }),\n\n/***/ \"fb6a\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar isObject = __webpack_require__(\"861d\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar toAbsoluteIndex = __webpack_require__(\"23cb\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar createProperty = __webpack_require__(\"8418\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('slice');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('slice', { ACCESSORS: true, 0: 0, 1: 2 });\n\nvar SPECIES = wellKnownSymbol('species');\nvar nativeSlice = [].slice;\nvar max = Math.max;\n\n// `Array.prototype.slice` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.slice\n// fallback for not array-like ES3 strings and DOM objects\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n slice: function slice(start, end) {\n var O = toIndexedObject(this);\n var length = toLength(O.length);\n var k = toAbsoluteIndex(start, length);\n var fin = toAbsoluteIndex(end === undefined ? length : end, length);\n // inline `ArraySpeciesCreate` for usage native `Array#slice` where it's possible\n var Constructor, result, n;\n if (isArray(O)) {\n Constructor = O.constructor;\n // cross-realm fallback\n if (typeof Constructor == 'function' && (Constructor === Array || isArray(Constructor.prototype))) {\n Constructor = undefined;\n } else if (isObject(Constructor)) {\n Constructor = Constructor[SPECIES];\n if (Constructor === null) Constructor = undefined;\n }\n if (Constructor === Array || Constructor === undefined) {\n return nativeSlice.call(O, k, fin);\n }\n }\n result = new (Constructor === undefined ? Array : Constructor)(max(fin - k, 0));\n for (n = 0; k < fin; k++, n++) if (k in O) createProperty(result, n, O[k]);\n result.length = n;\n return result;\n }\n});\n\n\n/***/ }),\n\n/***/ \"fc6a\":\n/***/ (function(module, exports, __webpack_require__) {\n\n// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = __webpack_require__(\"44ad\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n\n\n/***/ }),\n\n/***/ \"fdbc\":\n/***/ (function(module, exports) {\n\n// iterable DOM collections\n// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods\nmodule.exports = {\n CSSRuleList: 0,\n CSSStyleDeclaration: 0,\n CSSValueList: 0,\n ClientRectList: 0,\n DOMRectList: 0,\n DOMStringList: 0,\n DOMTokenList: 1,\n DataTransferItemList: 0,\n FileList: 0,\n HTMLAllCollection: 0,\n HTMLCollection: 0,\n HTMLFormElement: 0,\n HTMLSelectElement: 0,\n MediaList: 0,\n MimeTypeArray: 0,\n NamedNodeMap: 0,\n NodeList: 1,\n PaintRequestList: 0,\n Plugin: 0,\n PluginArray: 0,\n SVGLengthList: 0,\n SVGNumberList: 0,\n SVGPathSegList: 0,\n SVGPointList: 0,\n SVGStringList: 0,\n SVGTransformList: 0,\n SourceBufferList: 0,\n StyleSheetList: 0,\n TextTrackCueList: 0,\n TextTrackList: 0,\n TouchList: 0\n};\n\n\n/***/ }),\n\n/***/ \"fdbf\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar NATIVE_SYMBOL = __webpack_require__(\"4930\");\n\nmodule.exports = NATIVE_SYMBOL\n // eslint-disable-next-line no-undef\n && !Symbol.sham\n // eslint-disable-next-line no-undef\n && typeof Symbol.iterator == 'symbol';\n\n\n/***/ })\n\n/******/ })[\"default\"];\n});\n//# sourceMappingURL=vuedraggable.umd.js.map","export let createNanoEvents = () => ({\n events: {},\n emit(event, ...args) {\n ;(this.events[event] || []).forEach(i => i(...args))\n },\n on(event, cb) {\n ;(this.events[event] = this.events[event] || []).push(cb)\n return () =>\n (this.events[event] = (this.events[event] || []).filter(i => i !== cb))\n }\n})\n","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n}","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","import defineProperty from \"./defineProperty.js\";\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n enumerableOnly && (symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n })), keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nexport default function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = null != arguments[i] ? arguments[i] : {};\n i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {\n defineProperty(target, key, source[key]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n\n return target;\n}","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _iterableToArrayLimit(arr, i) {\n var _i = arr == null ? null : typeof Symbol !== \"undefined\" && arr[Symbol.iterator] || arr[\"@@iterator\"];\n\n if (_i == null) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n\n var _s, _e;\n\n try {\n for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import arrayWithHoles from \"./arrayWithHoles.js\";\nimport iterableToArrayLimit from \"./iterableToArrayLimit.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableRest from \"./nonIterableRest.js\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import arrayWithoutHoles from \"./arrayWithoutHoles.js\";\nimport iterableToArray from \"./iterableToArray.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableSpread from \"./nonIterableSpread.js\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (obj) {\n return typeof obj;\n } : function (obj) {\n return obj && \"function\" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n }, _typeof(obj);\n}","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","var __defProp = Object.defineProperty;\nvar __getOwnPropSymbols = Object.getOwnPropertySymbols;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __propIsEnum = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues = (a, b) => {\n for (var prop in b || (b = {}))\n if (__hasOwnProp.call(b, prop))\n __defNormalProp(a, prop, b[prop]);\n if (__getOwnPropSymbols)\n for (var prop of __getOwnPropSymbols(b)) {\n if (__propIsEnum.call(b, prop))\n __defNormalProp(a, prop, b[prop]);\n }\n return a;\n};\n\n// src/index.ts\nimport { provide, inject, getCurrentInstance } from \"vue\";\n\n// src/ts/interface.ts\nimport { createApp, nextTick } from \"vue\";\n\n// src/ts/utils.ts\nimport { defineComponent, toRaw, unref } from \"vue\";\nvar isFunction = (value) => typeof value === \"function\";\nvar isString = (value) => typeof value === \"string\";\nvar isNonEmptyString = (value) => isString(value) && value.trim().length > 0;\nvar isNumber = (value) => typeof value === \"number\";\nvar isUndefined = (value) => typeof value === \"undefined\";\nvar isObject = (value) => typeof value === \"object\" && value !== null;\nvar isJSX = (obj) => hasProp(obj, \"tag\") && isNonEmptyString(obj.tag);\nvar isTouchEvent = (event) => window.TouchEvent && event instanceof TouchEvent;\nvar isToastComponent = (obj) => hasProp(obj, \"component\") && isToastContent(obj.component);\nvar isVueComponent = (c) => isFunction(c) || isObject(c);\nvar isToastContent = (obj) => !isUndefined(obj) && (isString(obj) || isVueComponent(obj) || isToastComponent(obj));\nvar isDOMRect = (obj) => isObject(obj) && [\"height\", \"width\", \"right\", \"left\", \"top\", \"bottom\"].every((p) => isNumber(obj[p]));\nvar hasProp = (obj, propKey) => (isObject(obj) || isFunction(obj)) && propKey in obj;\nvar getId = ((i) => () => i++)(0);\nfunction getX(event) {\n return isTouchEvent(event) ? event.targetTouches[0].clientX : event.clientX;\n}\nfunction getY(event) {\n return isTouchEvent(event) ? event.targetTouches[0].clientY : event.clientY;\n}\nvar removeElement = (el) => {\n if (!isUndefined(el.remove)) {\n el.remove();\n } else if (el.parentNode) {\n el.parentNode.removeChild(el);\n }\n};\nvar getVueComponentFromObj = (obj) => {\n if (isToastComponent(obj)) {\n return getVueComponentFromObj(obj.component);\n }\n if (isJSX(obj)) {\n return defineComponent({\n render() {\n return obj;\n }\n });\n }\n return typeof obj === \"string\" ? obj : toRaw(unref(obj));\n};\nvar normalizeToastComponent = (obj) => {\n if (typeof obj === \"string\") {\n return obj;\n }\n const props = hasProp(obj, \"props\") && isObject(obj.props) ? obj.props : {};\n const listeners = hasProp(obj, \"listeners\") && isObject(obj.listeners) ? obj.listeners : {};\n return { component: getVueComponentFromObj(obj), props, listeners };\n};\nvar isBrowser = () => typeof window !== \"undefined\";\n\n// src/ts/eventBus.ts\nvar EventBus = class {\n constructor() {\n this.allHandlers = {};\n }\n getHandlers(eventType) {\n return this.allHandlers[eventType] || [];\n }\n on(eventType, handler) {\n const handlers = this.getHandlers(eventType);\n handlers.push(handler);\n this.allHandlers[eventType] = handlers;\n }\n off(eventType, handler) {\n const handlers = this.getHandlers(eventType);\n handlers.splice(handlers.indexOf(handler) >>> 0, 1);\n }\n emit(eventType, event) {\n const handlers = this.getHandlers(eventType);\n handlers.forEach((handler) => handler(event));\n }\n};\nvar isEventBusInterface = (e) => [\"on\", \"off\", \"emit\"].every((f) => hasProp(e, f) && isFunction(e[f]));\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue?vue&type=script\nimport { defineComponent as defineComponent7 } from \"vue\";\n\n// src/ts/constants.ts\nvar TYPE;\n(function(TYPE2) {\n TYPE2[\"SUCCESS\"] = \"success\";\n TYPE2[\"ERROR\"] = \"error\";\n TYPE2[\"WARNING\"] = \"warning\";\n TYPE2[\"INFO\"] = \"info\";\n TYPE2[\"DEFAULT\"] = \"default\";\n})(TYPE || (TYPE = {}));\nvar POSITION;\n(function(POSITION2) {\n POSITION2[\"TOP_LEFT\"] = \"top-left\";\n POSITION2[\"TOP_CENTER\"] = \"top-center\";\n POSITION2[\"TOP_RIGHT\"] = \"top-right\";\n POSITION2[\"BOTTOM_LEFT\"] = \"bottom-left\";\n POSITION2[\"BOTTOM_CENTER\"] = \"bottom-center\";\n POSITION2[\"BOTTOM_RIGHT\"] = \"bottom-right\";\n})(POSITION || (POSITION = {}));\nvar EVENTS;\n(function(EVENTS2) {\n EVENTS2[\"ADD\"] = \"add\";\n EVENTS2[\"DISMISS\"] = \"dismiss\";\n EVENTS2[\"UPDATE\"] = \"update\";\n EVENTS2[\"CLEAR\"] = \"clear\";\n EVENTS2[\"UPDATE_DEFAULTS\"] = \"update_defaults\";\n})(EVENTS || (EVENTS = {}));\nvar VT_NAMESPACE = \"Vue-Toastification\";\n\n// src/ts/propValidators.ts\nvar COMMON = {\n type: {\n type: String,\n default: TYPE.DEFAULT\n },\n classNames: {\n type: [String, Array],\n default: () => []\n },\n trueBoolean: {\n type: Boolean,\n default: true\n }\n};\nvar ICON = {\n type: COMMON.type,\n customIcon: {\n type: [String, Boolean, Object, Function],\n default: true\n }\n};\nvar CLOSE_BUTTON = {\n component: {\n type: [String, Object, Function, Boolean],\n default: \"button\"\n },\n classNames: COMMON.classNames,\n showOnHover: {\n type: Boolean,\n default: false\n },\n ariaLabel: {\n type: String,\n default: \"close\"\n }\n};\nvar PROGRESS_BAR = {\n timeout: {\n type: [Number, Boolean],\n default: 5e3\n },\n hideProgressBar: {\n type: Boolean,\n default: false\n },\n isRunning: {\n type: Boolean,\n default: false\n }\n};\nvar TRANSITION = {\n transition: {\n type: [Object, String],\n default: `${VT_NAMESPACE}__bounce`\n }\n};\nvar CORE_TOAST = {\n position: {\n type: String,\n default: POSITION.TOP_RIGHT\n },\n draggable: COMMON.trueBoolean,\n draggablePercent: {\n type: Number,\n default: 0.6\n },\n pauseOnFocusLoss: COMMON.trueBoolean,\n pauseOnHover: COMMON.trueBoolean,\n closeOnClick: COMMON.trueBoolean,\n timeout: PROGRESS_BAR.timeout,\n hideProgressBar: PROGRESS_BAR.hideProgressBar,\n toastClassName: COMMON.classNames,\n bodyClassName: COMMON.classNames,\n icon: ICON.customIcon,\n closeButton: CLOSE_BUTTON.component,\n closeButtonClassName: CLOSE_BUTTON.classNames,\n showCloseButtonOnHover: CLOSE_BUTTON.showOnHover,\n accessibility: {\n type: Object,\n default: () => ({\n toastRole: \"alert\",\n closeButtonLabel: \"close\"\n })\n },\n rtl: {\n type: Boolean,\n default: false\n },\n eventBus: {\n type: Object,\n required: false,\n default: () => new EventBus()\n }\n};\nvar TOAST = {\n id: {\n type: [String, Number],\n required: true,\n default: 0\n },\n type: COMMON.type,\n content: {\n type: [String, Object, Function],\n required: true,\n default: \"\"\n },\n onClick: {\n type: Function,\n default: void 0\n },\n onClose: {\n type: Function,\n default: void 0\n }\n};\nvar CONTAINER = {\n container: {\n type: [\n Object,\n Function\n ],\n default: () => document.body\n },\n newestOnTop: COMMON.trueBoolean,\n maxToasts: {\n type: Number,\n default: 20\n },\n transition: TRANSITION.transition,\n toastDefaults: Object,\n filterBeforeCreate: {\n type: Function,\n default: (toast) => toast\n },\n filterToasts: {\n type: Function,\n default: (toasts) => toasts\n },\n containerClassName: COMMON.classNames,\n onMounted: Function,\n shareAppContext: [Boolean, Object]\n};\nvar propValidators_default = {\n CORE_TOAST,\n TOAST,\n CONTAINER,\n PROGRESS_BAR,\n ICON,\n TRANSITION,\n CLOSE_BUTTON\n};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue?vue&type=script\nimport { defineComponent as defineComponent5 } from \"vue\";\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtProgressBar.vue?vue&type=script\nimport { defineComponent as defineComponent2 } from \"vue\";\nvar VtProgressBar_default = defineComponent2({\n name: \"VtProgressBar\",\n props: propValidators_default.PROGRESS_BAR,\n data() {\n return {\n hasClass: true\n };\n },\n computed: {\n style() {\n return {\n animationDuration: `${this.timeout}ms`,\n animationPlayState: this.isRunning ? \"running\" : \"paused\",\n opacity: this.hideProgressBar ? 0 : 1\n };\n },\n cpClass() {\n return this.hasClass ? `${VT_NAMESPACE}__progress-bar` : \"\";\n }\n },\n watch: {\n timeout() {\n this.hasClass = false;\n this.$nextTick(() => this.hasClass = true);\n }\n },\n mounted() {\n this.$el.addEventListener(\"animationend\", this.animationEnded);\n },\n beforeUnmount() {\n this.$el.removeEventListener(\"animationend\", this.animationEnded);\n },\n methods: {\n animationEnded() {\n this.$emit(\"close-toast\");\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtProgressBar.vue?vue&type=template\nimport { normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\";\nfunction render(_ctx, _cache) {\n return _openBlock(), _createElementBlock(\"div\", {\n style: _normalizeStyle(_ctx.style),\n class: _normalizeClass(_ctx.cpClass)\n }, null, 6);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtProgressBar.vue\nVtProgressBar_default.render = render;\nvar VtProgressBar_default2 = VtProgressBar_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtCloseButton.vue?vue&type=script\nimport { defineComponent as defineComponent3 } from \"vue\";\nvar VtCloseButton_default = defineComponent3({\n name: \"VtCloseButton\",\n props: propValidators_default.CLOSE_BUTTON,\n computed: {\n buttonComponent() {\n if (this.component !== false) {\n return getVueComponentFromObj(this.component);\n }\n return \"button\";\n },\n classes() {\n const classes = [`${VT_NAMESPACE}__close-button`];\n if (this.showOnHover) {\n classes.push(\"show-on-hover\");\n }\n return classes.concat(this.classNames);\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtCloseButton.vue?vue&type=template\nimport { createTextVNode as _createTextVNode, resolveDynamicComponent as _resolveDynamicComponent, mergeProps as _mergeProps, withCtx as _withCtx, openBlock as _openBlock2, createBlock as _createBlock } from \"vue\";\nvar _hoisted_1 = /* @__PURE__ */ _createTextVNode(\" \\xD7 \");\nfunction render2(_ctx, _cache) {\n return _openBlock2(), _createBlock(_resolveDynamicComponent(_ctx.buttonComponent), _mergeProps({\n \"aria-label\": _ctx.ariaLabel,\n class: _ctx.classes\n }, _ctx.$attrs), {\n default: _withCtx(() => [\n _hoisted_1\n ]),\n _: 1\n }, 16, [\"aria-label\", \"class\"]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtCloseButton.vue\nVtCloseButton_default.render = render2;\nvar VtCloseButton_default2 = VtCloseButton_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue?vue&type=script\nimport { defineComponent as defineComponent4 } from \"vue\";\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtSuccessIcon.vue?vue&type=script\nvar VtSuccessIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtSuccessIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode, openBlock as _openBlock3, createElementBlock as _createElementBlock2 } from \"vue\";\nvar _hoisted_12 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"check-circle\",\n class: \"svg-inline--fa fa-check-circle fa-w-16\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 512 512\"\n};\nvar _hoisted_2 = /* @__PURE__ */ _createElementVNode(\"path\", {\n fill: \"currentColor\",\n d: \"M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z\"\n}, null, -1);\nvar _hoisted_3 = [\n _hoisted_2\n];\nfunction render3(_ctx, _cache) {\n return _openBlock3(), _createElementBlock2(\"svg\", _hoisted_12, _hoisted_3);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtSuccessIcon.vue\nVtSuccessIcon_default.render = render3;\nvar VtSuccessIcon_default2 = VtSuccessIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtInfoIcon.vue?vue&type=script\nvar VtInfoIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtInfoIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode2, openBlock as _openBlock4, createElementBlock as _createElementBlock3 } from \"vue\";\nvar _hoisted_13 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"info-circle\",\n class: \"svg-inline--fa fa-info-circle fa-w-16\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 512 512\"\n};\nvar _hoisted_22 = /* @__PURE__ */ _createElementVNode2(\"path\", {\n fill: \"currentColor\",\n d: \"M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z\"\n}, null, -1);\nvar _hoisted_32 = [\n _hoisted_22\n];\nfunction render4(_ctx, _cache) {\n return _openBlock4(), _createElementBlock3(\"svg\", _hoisted_13, _hoisted_32);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtInfoIcon.vue\nVtInfoIcon_default.render = render4;\nvar VtInfoIcon_default2 = VtInfoIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtWarningIcon.vue?vue&type=script\nvar VtWarningIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtWarningIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode3, openBlock as _openBlock5, createElementBlock as _createElementBlock4 } from \"vue\";\nvar _hoisted_14 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"exclamation-circle\",\n class: \"svg-inline--fa fa-exclamation-circle fa-w-16\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 512 512\"\n};\nvar _hoisted_23 = /* @__PURE__ */ _createElementVNode3(\"path\", {\n fill: \"currentColor\",\n d: \"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z\"\n}, null, -1);\nvar _hoisted_33 = [\n _hoisted_23\n];\nfunction render5(_ctx, _cache) {\n return _openBlock5(), _createElementBlock4(\"svg\", _hoisted_14, _hoisted_33);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtWarningIcon.vue\nVtWarningIcon_default.render = render5;\nvar VtWarningIcon_default2 = VtWarningIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtErrorIcon.vue?vue&type=script\nvar VtErrorIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtErrorIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode4, openBlock as _openBlock6, createElementBlock as _createElementBlock5 } from \"vue\";\nvar _hoisted_15 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"exclamation-triangle\",\n class: \"svg-inline--fa fa-exclamation-triangle fa-w-18\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 576 512\"\n};\nvar _hoisted_24 = /* @__PURE__ */ _createElementVNode4(\"path\", {\n fill: \"currentColor\",\n d: \"M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z\"\n}, null, -1);\nvar _hoisted_34 = [\n _hoisted_24\n];\nfunction render6(_ctx, _cache) {\n return _openBlock6(), _createElementBlock5(\"svg\", _hoisted_15, _hoisted_34);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtErrorIcon.vue\nVtErrorIcon_default.render = render6;\nvar VtErrorIcon_default2 = VtErrorIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue?vue&type=script\nvar VtIcon_default = defineComponent4({\n name: \"VtIcon\",\n props: propValidators_default.ICON,\n computed: {\n customIconChildren() {\n return hasProp(this.customIcon, \"iconChildren\") ? this.trimValue(this.customIcon.iconChildren) : \"\";\n },\n customIconClass() {\n if (isString(this.customIcon)) {\n return this.trimValue(this.customIcon);\n } else if (hasProp(this.customIcon, \"iconClass\")) {\n return this.trimValue(this.customIcon.iconClass);\n }\n return \"\";\n },\n customIconTag() {\n if (hasProp(this.customIcon, \"iconTag\")) {\n return this.trimValue(this.customIcon.iconTag, \"i\");\n }\n return \"i\";\n },\n hasCustomIcon() {\n return this.customIconClass.length > 0;\n },\n component() {\n if (this.hasCustomIcon) {\n return this.customIconTag;\n }\n if (isToastContent(this.customIcon)) {\n return getVueComponentFromObj(this.customIcon);\n }\n return this.iconTypeComponent;\n },\n iconTypeComponent() {\n const types = {\n [TYPE.DEFAULT]: VtInfoIcon_default2,\n [TYPE.INFO]: VtInfoIcon_default2,\n [TYPE.SUCCESS]: VtSuccessIcon_default2,\n [TYPE.ERROR]: VtErrorIcon_default2,\n [TYPE.WARNING]: VtWarningIcon_default2\n };\n return types[this.type];\n },\n iconClasses() {\n const classes = [`${VT_NAMESPACE}__icon`];\n if (this.hasCustomIcon) {\n return classes.concat(this.customIconClass);\n }\n return classes;\n }\n },\n methods: {\n trimValue(value, empty = \"\") {\n return isNonEmptyString(value) ? value.trim() : empty;\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue?vue&type=template\nimport { toDisplayString as _toDisplayString, createTextVNode as _createTextVNode2, resolveDynamicComponent as _resolveDynamicComponent2, normalizeClass as _normalizeClass2, withCtx as _withCtx2, openBlock as _openBlock7, createBlock as _createBlock2 } from \"vue\";\nfunction render7(_ctx, _cache) {\n return _openBlock7(), _createBlock2(_resolveDynamicComponent2(_ctx.component), {\n class: _normalizeClass2(_ctx.iconClasses)\n }, {\n default: _withCtx2(() => [\n _createTextVNode2(_toDisplayString(_ctx.customIconChildren), 1)\n ]),\n _: 1\n }, 8, [\"class\"]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue\nVtIcon_default.render = render7;\nvar VtIcon_default2 = VtIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue?vue&type=script\nvar VtToast_default = defineComponent5({\n name: \"VtToast\",\n components: { ProgressBar: VtProgressBar_default2, CloseButton: VtCloseButton_default2, Icon: VtIcon_default2 },\n inheritAttrs: false,\n props: Object.assign({}, propValidators_default.CORE_TOAST, propValidators_default.TOAST),\n data() {\n const data = {\n isRunning: true,\n disableTransitions: false,\n beingDragged: false,\n dragStart: 0,\n dragPos: { x: 0, y: 0 },\n dragRect: {}\n };\n return data;\n },\n computed: {\n classes() {\n const classes = [\n `${VT_NAMESPACE}__toast`,\n `${VT_NAMESPACE}__toast--${this.type}`,\n `${this.position}`\n ].concat(this.toastClassName);\n if (this.disableTransitions) {\n classes.push(\"disable-transition\");\n }\n if (this.rtl) {\n classes.push(`${VT_NAMESPACE}__toast--rtl`);\n }\n return classes;\n },\n bodyClasses() {\n const classes = [\n `${VT_NAMESPACE}__toast-${isString(this.content) ? \"body\" : \"component-body\"}`\n ].concat(this.bodyClassName);\n return classes;\n },\n draggableStyle() {\n if (this.dragStart === this.dragPos.x) {\n return {};\n } else if (this.beingDragged) {\n return {\n transform: `translateX(${this.dragDelta}px)`,\n opacity: 1 - Math.abs(this.dragDelta / this.removalDistance)\n };\n } else {\n return {\n transition: \"transform 0.2s, opacity 0.2s\",\n transform: \"translateX(0)\",\n opacity: 1\n };\n }\n },\n dragDelta() {\n return this.beingDragged ? this.dragPos.x - this.dragStart : 0;\n },\n removalDistance() {\n if (isDOMRect(this.dragRect)) {\n return (this.dragRect.right - this.dragRect.left) * this.draggablePercent;\n }\n return 0;\n }\n },\n mounted() {\n if (this.draggable) {\n this.draggableSetup();\n }\n if (this.pauseOnFocusLoss) {\n this.focusSetup();\n }\n },\n beforeUnmount() {\n if (this.draggable) {\n this.draggableCleanup();\n }\n if (this.pauseOnFocusLoss) {\n this.focusCleanup();\n }\n },\n methods: {\n hasProp,\n getVueComponentFromObj,\n closeToast() {\n this.eventBus.emit(EVENTS.DISMISS, this.id);\n },\n clickHandler() {\n if (this.onClick) {\n this.onClick(this.closeToast);\n }\n if (this.closeOnClick) {\n if (!this.beingDragged || this.dragStart === this.dragPos.x) {\n this.closeToast();\n }\n }\n },\n timeoutHandler() {\n this.closeToast();\n },\n hoverPause() {\n if (this.pauseOnHover) {\n this.isRunning = false;\n }\n },\n hoverPlay() {\n if (this.pauseOnHover) {\n this.isRunning = true;\n }\n },\n focusPause() {\n this.isRunning = false;\n },\n focusPlay() {\n this.isRunning = true;\n },\n focusSetup() {\n addEventListener(\"blur\", this.focusPause);\n addEventListener(\"focus\", this.focusPlay);\n },\n focusCleanup() {\n removeEventListener(\"blur\", this.focusPause);\n removeEventListener(\"focus\", this.focusPlay);\n },\n draggableSetup() {\n const element = this.$el;\n element.addEventListener(\"touchstart\", this.onDragStart, {\n passive: true\n });\n element.addEventListener(\"mousedown\", this.onDragStart);\n addEventListener(\"touchmove\", this.onDragMove, { passive: false });\n addEventListener(\"mousemove\", this.onDragMove);\n addEventListener(\"touchend\", this.onDragEnd);\n addEventListener(\"mouseup\", this.onDragEnd);\n },\n draggableCleanup() {\n const element = this.$el;\n element.removeEventListener(\"touchstart\", this.onDragStart);\n element.removeEventListener(\"mousedown\", this.onDragStart);\n removeEventListener(\"touchmove\", this.onDragMove);\n removeEventListener(\"mousemove\", this.onDragMove);\n removeEventListener(\"touchend\", this.onDragEnd);\n removeEventListener(\"mouseup\", this.onDragEnd);\n },\n onDragStart(event) {\n this.beingDragged = true;\n this.dragPos = { x: getX(event), y: getY(event) };\n this.dragStart = getX(event);\n this.dragRect = this.$el.getBoundingClientRect();\n },\n onDragMove(event) {\n if (this.beingDragged) {\n event.preventDefault();\n if (this.isRunning) {\n this.isRunning = false;\n }\n this.dragPos = { x: getX(event), y: getY(event) };\n }\n },\n onDragEnd() {\n if (this.beingDragged) {\n if (Math.abs(this.dragDelta) >= this.removalDistance) {\n this.disableTransitions = true;\n this.$nextTick(() => this.closeToast());\n } else {\n setTimeout(() => {\n this.beingDragged = false;\n if (isDOMRect(this.dragRect) && this.pauseOnHover && this.dragRect.bottom >= this.dragPos.y && this.dragPos.y >= this.dragRect.top && this.dragRect.left <= this.dragPos.x && this.dragPos.x <= this.dragRect.right) {\n this.isRunning = false;\n } else {\n this.isRunning = true;\n }\n });\n }\n }\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue?vue&type=template\nimport { resolveComponent as _resolveComponent, openBlock as _openBlock8, createBlock as _createBlock3, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString2, createTextVNode as _createTextVNode3, Fragment as _Fragment, createElementBlock as _createElementBlock6, resolveDynamicComponent as _resolveDynamicComponent3, toHandlers as _toHandlers, mergeProps as _mergeProps2, normalizeClass as _normalizeClass3, createElementVNode as _createElementVNode5, withModifiers as _withModifiers, normalizeStyle as _normalizeStyle2 } from \"vue\";\nvar _hoisted_16 = [\"role\"];\nfunction render8(_ctx, _cache) {\n const _component_Icon = _resolveComponent(\"Icon\");\n const _component_CloseButton = _resolveComponent(\"CloseButton\");\n const _component_ProgressBar = _resolveComponent(\"ProgressBar\");\n return _openBlock8(), _createElementBlock6(\"div\", {\n class: _normalizeClass3(_ctx.classes),\n style: _normalizeStyle2(_ctx.draggableStyle),\n onClick: _cache[0] || (_cache[0] = (...args) => _ctx.clickHandler && _ctx.clickHandler(...args)),\n onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.hoverPause && _ctx.hoverPause(...args)),\n onMouseleave: _cache[2] || (_cache[2] = (...args) => _ctx.hoverPlay && _ctx.hoverPlay(...args))\n }, [\n _ctx.icon ? (_openBlock8(), _createBlock3(_component_Icon, {\n key: 0,\n \"custom-icon\": _ctx.icon,\n type: _ctx.type\n }, null, 8, [\"custom-icon\", \"type\"])) : _createCommentVNode(\"v-if\", true),\n _createElementVNode5(\"div\", {\n role: _ctx.accessibility.toastRole || \"alert\",\n class: _normalizeClass3(_ctx.bodyClasses)\n }, [\n typeof _ctx.content === \"string\" ? (_openBlock8(), _createElementBlock6(_Fragment, { key: 0 }, [\n _createTextVNode3(_toDisplayString2(_ctx.content), 1)\n ], 2112)) : (_openBlock8(), _createBlock3(_resolveDynamicComponent3(_ctx.getVueComponentFromObj(_ctx.content)), _mergeProps2({\n key: 1,\n \"toast-id\": _ctx.id\n }, _ctx.hasProp(_ctx.content, \"props\") ? _ctx.content.props : {}, _toHandlers(_ctx.hasProp(_ctx.content, \"listeners\") ? _ctx.content.listeners : {}), { onCloseToast: _ctx.closeToast }), null, 16, [\"toast-id\", \"onCloseToast\"]))\n ], 10, _hoisted_16),\n !!_ctx.closeButton ? (_openBlock8(), _createBlock3(_component_CloseButton, {\n key: 1,\n component: _ctx.closeButton,\n \"class-names\": _ctx.closeButtonClassName,\n \"show-on-hover\": _ctx.showCloseButtonOnHover,\n \"aria-label\": _ctx.accessibility.closeButtonLabel,\n onClick: _withModifiers(_ctx.closeToast, [\"stop\"])\n }, null, 8, [\"component\", \"class-names\", \"show-on-hover\", \"aria-label\", \"onClick\"])) : _createCommentVNode(\"v-if\", true),\n _ctx.timeout ? (_openBlock8(), _createBlock3(_component_ProgressBar, {\n key: 2,\n \"is-running\": _ctx.isRunning,\n \"hide-progress-bar\": _ctx.hideProgressBar,\n timeout: _ctx.timeout,\n onCloseToast: _ctx.timeoutHandler\n }, null, 8, [\"is-running\", \"hide-progress-bar\", \"timeout\", \"onCloseToast\"])) : _createCommentVNode(\"v-if\", true)\n ], 38);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue\nVtToast_default.render = render8;\nvar VtToast_default2 = VtToast_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtTransition.vue?vue&type=script\nimport { defineComponent as defineComponent6 } from \"vue\";\nvar VtTransition_default = defineComponent6({\n name: \"VtTransition\",\n props: propValidators_default.TRANSITION,\n emits: [\"leave\"],\n methods: {\n hasProp,\n leave(el) {\n if (el instanceof HTMLElement) {\n el.style.left = el.offsetLeft + \"px\";\n el.style.top = el.offsetTop + \"px\";\n el.style.width = getComputedStyle(el).width;\n el.style.position = \"absolute\";\n }\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtTransition.vue?vue&type=template\nimport { renderSlot as _renderSlot, TransitionGroup as _TransitionGroup, withCtx as _withCtx3, openBlock as _openBlock9, createBlock as _createBlock4 } from \"vue\";\nfunction render9(_ctx, _cache) {\n return _openBlock9(), _createBlock4(_TransitionGroup, {\n tag: \"div\",\n \"enter-active-class\": _ctx.transition.enter ? _ctx.transition.enter : `${_ctx.transition}-enter-active`,\n \"move-class\": _ctx.transition.move ? _ctx.transition.move : `${_ctx.transition}-move`,\n \"leave-active-class\": _ctx.transition.leave ? _ctx.transition.leave : `${_ctx.transition}-leave-active`,\n onLeave: _ctx.leave\n }, {\n default: _withCtx3(() => [\n _renderSlot(_ctx.$slots, \"default\")\n ]),\n _: 3\n }, 8, [\"enter-active-class\", \"move-class\", \"leave-active-class\", \"onLeave\"]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtTransition.vue\nVtTransition_default.render = render9;\nvar VtTransition_default2 = VtTransition_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue?vue&type=script\nvar VtToastContainer_default = defineComponent7({\n name: \"VueToastification\",\n devtools: {\n hide: true\n },\n components: { Toast: VtToast_default2, VtTransition: VtTransition_default2 },\n props: Object.assign({}, propValidators_default.CORE_TOAST, propValidators_default.CONTAINER, propValidators_default.TRANSITION),\n data() {\n const data = {\n count: 0,\n positions: Object.values(POSITION),\n toasts: {},\n defaults: {}\n };\n return data;\n },\n computed: {\n toastArray() {\n return Object.values(this.toasts);\n },\n filteredToasts() {\n return this.defaults.filterToasts(this.toastArray);\n }\n },\n beforeMount() {\n const events = this.eventBus;\n events.on(EVENTS.ADD, this.addToast);\n events.on(EVENTS.CLEAR, this.clearToasts);\n events.on(EVENTS.DISMISS, this.dismissToast);\n events.on(EVENTS.UPDATE, this.updateToast);\n events.on(EVENTS.UPDATE_DEFAULTS, this.updateDefaults);\n this.defaults = this.$props;\n },\n mounted() {\n this.setup(this.container);\n },\n methods: {\n async setup(container) {\n if (isFunction(container)) {\n container = await container();\n }\n removeElement(this.$el);\n container.appendChild(this.$el);\n },\n setToast(props) {\n if (!isUndefined(props.id)) {\n this.toasts[props.id] = props;\n }\n },\n addToast(params) {\n params.content = normalizeToastComponent(params.content);\n const props = Object.assign({}, this.defaults, params.type && this.defaults.toastDefaults && this.defaults.toastDefaults[params.type], params);\n const toast = this.defaults.filterBeforeCreate(props, this.toastArray);\n toast && this.setToast(toast);\n },\n dismissToast(id) {\n const toast = this.toasts[id];\n if (!isUndefined(toast) && !isUndefined(toast.onClose)) {\n toast.onClose();\n }\n delete this.toasts[id];\n },\n clearToasts() {\n Object.keys(this.toasts).forEach((id) => {\n this.dismissToast(id);\n });\n },\n getPositionToasts(position) {\n const toasts = this.filteredToasts.filter((toast) => toast.position === position).slice(0, this.defaults.maxToasts);\n return this.defaults.newestOnTop ? toasts.reverse() : toasts;\n },\n updateDefaults(update) {\n if (!isUndefined(update.container)) {\n this.setup(update.container);\n }\n this.defaults = Object.assign({}, this.defaults, update);\n },\n updateToast({\n id,\n options,\n create\n }) {\n if (this.toasts[id]) {\n if (options.timeout && options.timeout === this.toasts[id].timeout) {\n options.timeout++;\n }\n this.setToast(Object.assign({}, this.toasts[id], options));\n } else if (create) {\n this.addToast(Object.assign({}, { id }, options));\n }\n },\n getClasses(position) {\n const classes = [`${VT_NAMESPACE}__container`, position];\n return classes.concat(this.defaults.containerClassName);\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue?vue&type=template\nimport { renderList as _renderList, Fragment as _Fragment2, openBlock as _openBlock10, createElementBlock as _createElementBlock7, resolveComponent as _resolveComponent2, mergeProps as _mergeProps3, createBlock as _createBlock5, normalizeClass as _normalizeClass4, withCtx as _withCtx4, createVNode as _createVNode } from \"vue\";\nfunction render10(_ctx, _cache) {\n const _component_Toast = _resolveComponent2(\"Toast\");\n const _component_VtTransition = _resolveComponent2(\"VtTransition\");\n return _openBlock10(), _createElementBlock7(\"div\", null, [\n (_openBlock10(true), _createElementBlock7(_Fragment2, null, _renderList(_ctx.positions, (pos) => {\n return _openBlock10(), _createElementBlock7(\"div\", { key: pos }, [\n _createVNode(_component_VtTransition, {\n transition: _ctx.defaults.transition,\n class: _normalizeClass4(_ctx.getClasses(pos))\n }, {\n default: _withCtx4(() => [\n (_openBlock10(true), _createElementBlock7(_Fragment2, null, _renderList(_ctx.getPositionToasts(pos), (toast) => {\n return _openBlock10(), _createBlock5(_component_Toast, _mergeProps3({\n key: toast.id\n }, toast), null, 16);\n }), 128))\n ]),\n _: 2\n }, 1032, [\"transition\", \"class\"])\n ]);\n }), 128))\n ]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue\nVtToastContainer_default.render = render10;\nvar VtToastContainer_default2 = VtToastContainer_default;\n\n// src/ts/interface.ts\nvar buildInterface = (globalOptions = {}, mountContainer = true) => {\n const events = globalOptions.eventBus = globalOptions.eventBus || new EventBus();\n if (mountContainer) {\n nextTick(() => {\n const app = createApp(VtToastContainer_default2, __spreadValues({}, globalOptions));\n const component = app.mount(document.createElement(\"div\"));\n const onMounted = globalOptions.onMounted;\n if (!isUndefined(onMounted)) {\n onMounted(component, app);\n }\n if (globalOptions.shareAppContext) {\n const baseApp = globalOptions.shareAppContext;\n if (baseApp === true) {\n console.warn(`[${VT_NAMESPACE}] App to share context with was not provided.`);\n } else {\n app._context.components = baseApp._context.components;\n app._context.directives = baseApp._context.directives;\n app._context.mixins = baseApp._context.mixins;\n app._context.provides = baseApp._context.provides;\n app.config.globalProperties = baseApp.config.globalProperties;\n }\n }\n });\n }\n const toast = (content, options) => {\n const props = Object.assign({}, { id: getId(), type: TYPE.DEFAULT }, options, {\n content\n });\n events.emit(EVENTS.ADD, props);\n return props.id;\n };\n toast.clear = () => events.emit(EVENTS.CLEAR, void 0);\n toast.updateDefaults = (update) => {\n events.emit(EVENTS.UPDATE_DEFAULTS, update);\n };\n toast.dismiss = (id) => {\n events.emit(EVENTS.DISMISS, id);\n };\n function updateToast(id, { content, options }, create = false) {\n const opt = Object.assign({}, options, { content });\n events.emit(EVENTS.UPDATE, {\n id,\n options: opt,\n create\n });\n }\n toast.update = updateToast;\n toast.success = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.SUCCESS }));\n toast.info = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.INFO }));\n toast.error = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.ERROR }));\n toast.warning = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.WARNING }));\n return toast;\n};\n\n// src/index.ts\nvar createMockToastInterface = () => {\n const toast = () => console.warn(`[${VT_NAMESPACE}] This plugin does not support SSR!`);\n return new Proxy(toast, {\n get() {\n return toast;\n }\n });\n};\nfunction createToastInterface(optionsOrEventBus) {\n if (!isBrowser()) {\n return createMockToastInterface();\n }\n if (isEventBusInterface(optionsOrEventBus)) {\n return buildInterface({ eventBus: optionsOrEventBus }, false);\n }\n return buildInterface(optionsOrEventBus, true);\n}\nvar toastInjectionKey = Symbol(\"VueToastification\");\nvar globalEventBus = new EventBus();\nvar VueToastificationPlugin = (App, options) => {\n if ((options == null ? void 0 : options.shareAppContext) === true) {\n options.shareAppContext = App;\n }\n const inter = createToastInterface(__spreadValues({\n eventBus: globalEventBus\n }, options));\n App.provide(toastInjectionKey, inter);\n};\nvar provideToast = (options) => {\n const toast = createToastInterface(options);\n if (getCurrentInstance()) {\n provide(toastInjectionKey, toast);\n }\n};\nvar useToast = (eventBus) => {\n if (eventBus) {\n return createToastInterface(eventBus);\n }\n const toast = getCurrentInstance() ? inject(toastInjectionKey, void 0) : void 0;\n return toast ? toast : createToastInterface(globalEventBus);\n};\nvar src_default = VueToastificationPlugin;\nexport {\n EventBus,\n POSITION,\n TYPE,\n createToastInterface,\n src_default as default,\n globalEventBus,\n provideToast,\n toastInjectionKey,\n useToast\n};\n"],"names":["ENV","RENDERER_TYPE","BUFFER_BITS","BLEND_MODES","DRAW_MODES","FORMATS","TARGETS","TYPES","SAMPLER_TYPES","SCALE_MODES","WRAP_MODES","MIPMAP_MODES","ALPHA_MODES","CLEAR_MODES","GC_MODES","PRECISION","MASK_TYPES","MSAA_QUALITY","BUFFER_TYPE","INSTALLED","autoDetectResource","source","options","extension","result","exec","toLowerCase","i","length","ResourcePlugin","test","Error","extendStatics","d","b","Object","setPrototypeOf","__proto__","Array","p","hasOwnProperty","__extends","__","this","constructor","prototype","create","__assign","assign","t","s","arguments$1","arguments","n","call","apply","__rest","e","indexOf","getOwnPropertySymbols","Resource","width","height","_width","_height","destroyed","internal","onResize","R","onUpdate","onError","bind","baseTexture","add","emit","unbind","remove","resize","defineProperty","get","enumerable","configurable","update","load","Promise","resolve","style","_renderer","_baseTexture","_glTexture","dispose","destroy","removeAll","_source","_extension","BufferResource","_super","_this","_a","data","upload","renderer","glTexture","gl","pixelStorei","UNPACK_PREMULTIPLY_ALPHA_WEBGL","alphaMode","realWidth","realHeight","texSubImage2D","target","format","type","texImage2D","internalFormat","Float32Array","Uint8Array","Uint32Array","defaultBufferOptions","scaleMode","BaseTexture","resource","mipmap","anisotropicLevel","wrapMode","resolution","resourceOptions","Math","round","_mipmap","undefined","_wrapMode","_scaleMode","uid","touched","isPowerOfTwo","_refreshPOT","_glTextures","dirtyId","dirtyStyleId","cacheId","valid","textureCacheIds","_batchEnabled","_batchLocation","parentTextureArray","setResource","set","value","setStyle","dirty","setSize","desiredWidth","desiredHeight","setRealSize","setResolution","oldResolution","event","removeFromCache","castToBaseTexture","from","strict","isFrame","_pixiId","prefix","pixiIdPrefix","addToCache","fromBuffer","buffer","id","push","console","warn","baseTextureFromCache","index","splice","_globalBatch","AbstractMultiResource","items","itemDirtyIds","partTexture","_load","initFromArray","resources","addBaseTextureAt","addResourceAt","len","on","off","map","item","filter","promises","all","then","ArrayResource","urls","isArray","texture","texImage3D","TEXTURE_2D_ARRAY","texSubImage3D","BaseImageResource","sourceAny","naturalWidth","videoWidth","naturalHeight","videoHeight","noSubImage","crossOrigin","element","url","crossorigin","HTMLImageElement","complete","HTMLVideoElement","readyState","TEXTURE_2D","CanvasResource","OffscreenCanvas","globalThis","HTMLCanvasElement","CubeResource","autoLoad","linkBaseTexture","SIDES","keys","side","ImageResource","imageElement","Image","src","_process","preserveBitmap","createBitmap","createImageBitmap","bitmap","reject","completed","onload","onerror","process","cors","fetch","mode","r","blob","premultiplyAlpha","flag","glTextures","key","otherTex","close","SVGResource","sourceBase64","document","createElement","svg","scale","_overrideWidth","_overrideHeight","_resolve","_crossorigin","SVG_XML","trim","btoa","unescape","encodeURIComponent","_loadSvg","tempImage","svgWidth","svgHeight","canvas","getContext","drawImage","getSize","svgString","sizeMatch","SVG_SIZE","size","parseFloat","VideoResource","videoElement","setAttribute","firstSrc","sourceElement","mime","baseSrc","split","shift","ext","slice","lastIndexOf","MIME_TYPES","appendChild","_autoUpdate","_isConnectedToTicker","_updateFPS","updateFPS","_msToNextUpdate","autoPlay","_onCanPlay","_onError","_deltaTime","elapsedMS","playbackRate","floor","HAVE_ENOUGH_DATA","HAVE_FUTURE_DATA","addEventListener","_onPlayStart","_onPlayStop","_isSourceReady","removeEventListener","_isSourcePlaying","currentTime","paused","ended","autoUpdate","play","pause","ogv","mov","m4v","ImageBitmapResource","ImageBitmap","_resources","DepthResource","Framebuffer","stencil","depth","dirtyFormat","dirtySize","depthTexture","colorTextures","glFramebuffers","disposeRunner","multisample","addColorTexture","addDepthTexture","enableDepth","enableStencil","destroyDepthTexture","BaseRenderTexture","clearColor","framebuffer","maskStack","filterStack","TextureUvs","x0","y0","x1","y1","x2","y2","x3","y3","uvsFloat32","frame","baseFrame","rotate","tw","th","w2","h2","cX","x","cY","y","toString","DEFAULT_UVS","Texture","orig","anchor","noFrame","_frame","_uvs","uvMatrix","_rotate","Number","defaultAnchor","_updateID","onBaseTextureUpdated","once","updateUvs","destroyBase","clone","clonedFrame","clonedOrig","clonedTexture","fromURL","fromLoader","imageUrl","name","textureFromCache","xNotFit","yNotFit","relationship","errorX","errorY","createWhiteTexture","context","fillStyle","fillRect","removeAllHandlers","tex","EMPTY","WHITE","RenderTexture","baseRenderTexture","filterFrame","filterPoolKey","resizeBaseTexture","rest","_i","RenderTexturePool","textureOptions","texturePool","enableFullScreen","_pixelsWidth","_pixelsHeight","createTexture","getOptimalTexture","minWidth","minHeight","ceil","renderTexture","pop","getFilterTexture","input","filterTexture","returnTexture","returnFilterTexture","clear","destroyTextures","textures","j","setScreenSize","SCREEN_KEY","Attribute","normalized","stride","start","instance","UID","Buffer","_static","_glBuffers","static","Int32Array","interleaveTypedArrays","arrays","sizes","outSize","views","ArrayBuffer","out","littleOffset","array","indexStart","byteSizeMap","UID$1","map$1","Uint16Array","Geometry","buffers","attributes","indexBuffer","glVertexArrayObjects","instanced","instanceCount","refCount","addAttribute","ids","bufferIndex","getAttribute","getBuffer","addIndex","getIndex","interleave","interleavedBuffer","attribute","geometry","attrib","merge","geometries","geometryOut","offsets","offset","offset2","bufferIndexToCount","indexBufferData","Quad","QuadUv","vertices","uvs","vertexBuffer","uvBuffer","targetTextureFrame","destinationFrame","invalidate","UID$2","UniformGroup","uniforms","isStatic","isUbo","group","syncUniforms","ubo","autoManage","_ubo","uboFrom","FilterState","legacy","sourceFrame","bindingSourceFrame","bindingDestinationFrame","filters","transform","tempPoints","tempMatrix","FilterSystem","defaultFilterStack","view","statePool","quad","quadUv","tempRect","activeState","globalUniforms","outputFrame","inputSize","inputPixel","inputClamp","filterArea","filterClamp","forceClear","useMaxPadding","_b","state","renderTextureSystem","padding","autoFit","min","max","current","copyFrom","getBounds","pad","sourceFrameProjected","projection","transformAABB","invert","fit","roundFrame","getOptimalFilterTexture","lastState","blit","flip","flop","CLEAR","bindAndClear","clearMode","stateSystem","autoClear","stateId","applyFilter","output","uSampler","filterGlobals","shader","program","attributeData","aTextureCoord","draw","calculateSpriteMatrix","outputMatrix","sprite","_texture","mappedMatrix","worldTransform","copyTo","prepend","translate","swap","emptyPool","matrix","rect","lt","lb","rt","rb","left","top","bottom","right","a","c","abs","identity","ObjectRenderer","flush","stop","render","_object","BatchSystem","emptyRenderer","currentRenderer","setObjectRenderer","objectRenderer","reset","copyBoundTextures","arr","maxTextures","boundTextures","boundArray","texArray","batchId","elements","count","loc","bound","CONTEXT_UID_COUNTER","ContextSystem","webGLVersion","extensions","supports","uint32Indices","handleContextLost","handleContextRestored","isContextLost","contextChange","CONTEXT_UID","getExtension","restoreContext","initFromContext","validateContext","runners","initFromOptions","createContext","getExtensions","common","anisotropicFiltering","floatTextureLinear","s3tc","s3tc_sRGB","etc","etc1","pvrtc","atc","astc","drawBuffers","loseContext","vertexArrayObject","uint32ElementIndex","floatTexture","textureHalfFloat","textureHalfFloatLinear","colorBufferFloat","preventDefault","useProgram","postrender","renderingToScreen","getContextAttributes","isWebGl2","WebGL2RenderingContext","hasuint32","GLFramebuffer","msaaBuffer","blitFramebuffer","mipLevel","tempRectangle","FramebufferSystem","managedFramebuffers","unknownFramebuffer","msaaSamples","viewport","hasMRT","writeDepthTexture","disposeAll","nativeDrawBuffersExtension_1","nativeDepthTextureExtension","activeTextures","drawBuffersWEBGL","getInternalformatParameter","RENDERBUFFER","RGBA8","SAMPLES","fbo","initFramebuffer","bindFramebuffer","FRAMEBUFFER","updateFramebuffer","resizeFramebuffer","mipWidth","mipHeight","setViewport","v","g","mask","createFramebuffer","detectSamples","bindRenderbuffer","renderbufferStorageMultisample","DEPTH24_STENCIL8","renderbufferStorage","DEPTH_STENCIL","parentTexture","canMultisampleFramebuffer","createRenderbuffer","framebufferRenderbuffer","COLOR_ATTACHMENT0","deleteRenderbuffer","framebufferTexture2D","DEPTH_ATTACHMENT","DEPTH_STENCIL_ATTACHMENT","samples","res","sourcePixels","destPixels","colorTexture","sameSize","READ_FRAMEBUFFER","COLOR_BUFFER_BIT","NEAREST","LINEAR","disposeFramebuffer","contextLost","deleteFramebuffer","list","forceStencil","w","h","byteSizeMap$1","GeometrySystem","_activeGeometry","_activeVao","hasVao","hasInstance","canUseUInt32ElementIndex","managedGeometries","nativeVaoExtension_1","createVertexArray","createVertexArrayOES","bindVertexArray","vao","bindVertexArrayOES","deleteVertexArray","deleteVertexArrayOES","instanceExt_1","vertexAttribDivisor","vertexAttribDivisorANGLE","drawElementsInstanced","drawElementsInstancedANGLE","drawArraysInstanced","drawArraysInstancedANGLE","vaos","incRefCount","initGeometryVao","activateVao","updateBuffers","bufferSystem","checkCompatibility","geometryAttributes","shaderAttributes","getSignature","attribs","strings","location","join","glPrograms","generateProgram","signature","vaoObjectHash","tempStride","tempStart","attribSize","disposeGeometry","buf","vaoId","lastBuffer","glBuffer","enableVertexAttribArray","vertexAttribPointer","FLOAT","byteSize","BYTES_PER_ELEMENT","glType","UNSIGNED_SHORT","UNSIGNED_INT","drawElements","drawArrays","MaskData","maskObject","autoDetect","pooled","isMaskData","enabled","_filters","_stencilCounter","_scissorCounter","_scissorRect","_scissorRectLocal","_target","copyCountersOrReset","maskAbove","compileShader","createShader","shaderSource","logPrettyShaderError","shaderSrc","getShaderSource","line","shaderLog","getShaderInfoLog","splitShader","dedupe","lineNumbers","replace","logArgs","forEach","number","fragmentSourceToLog","error","groupCollapsed","groupEnd","logProgramError","vertexShader","fragmentShader","getProgramParameter","LINK_STATUS","getShaderParameter","COMPILE_STATUS","getProgramInfoLog","booleanArray","defaultValue","maxFragmentPrecision","unknownContext","getTestContext","getMaxFragmentPrecision","getShaderPrecisionFormat","shaderFragment","FRAGMENT_SHADER","HIGH_FLOAT","precision","setPrecision","requestedPrecision","maxSupportedPrecision","substring","GLSL_TO_SIZE","float","vec2","vec3","vec4","int","ivec2","ivec3","ivec4","uint","uvec2","uvec3","uvec4","bool","bvec2","bvec3","bvec4","mat2","mat3","mat4","sampler2D","mapSize","GL_TABLE","GL_TO_GLSL_TYPES","FLOAT_VEC2","FLOAT_VEC3","FLOAT_VEC4","INT","INT_VEC2","INT_VEC3","INT_VEC4","UNSIGNED_INT_VEC2","UNSIGNED_INT_VEC3","UNSIGNED_INT_VEC4","BOOL","BOOL_VEC2","BOOL_VEC3","BOOL_VEC4","FLOAT_MAT2","FLOAT_MAT3","FLOAT_MAT4","SAMPLER_2D","INT_SAMPLER_2D","UNSIGNED_INT_SAMPLER_2D","SAMPLER_CUBE","INT_SAMPLER_CUBE","UNSIGNED_INT_SAMPLER_CUBE","SAMPLER_2D_ARRAY","INT_SAMPLER_2D_ARRAY","UNSIGNED_INT_SAMPLER_2D_ARRAY","mapType","typeNames","tn","uniformParsers","code","uniform","codeUbo","GLSL_TO_SINGLE_SETTERS_CACHED","samplerCube","sampler2DArray","GLSL_TO_ARRAY_SETTERS","generateUniformsSync","uniformData","funcFragments","parsed","templateType","template","Function","unsafeEval","fragTemplate","generateIfTestSrc","maxIfs","checkMaxIfStatementsInShader","fragmentSrc","unsafeEvalSupported","func","defaultFragment","defaultVertex","UID$3","nameCache","Program","vertexSrc","defaultVertexSrc","defaultFragmentSrc","Shader","uniformBindCount","uniformGroup","checkUniformExists","BLEND","OFFSET","CULLING","DEPTH_TEST","WINDING","DEPTH_MASK","State","blendMode","polygonOffset","blend","depthMask","_blendMode","_polygonOffset","clockwiseFrontFace","culling","for2d","depthTest","defaultVertex$1","defaultFragment$1","Filter","filterManager","_currentState","_resolution","vertex","fragment","tempMat","TextureMatrix","clampMargin","mapCoord","uClampFrame","uClampOffset","_textureID","clampOffset","isSimple","multiplyUvs","mat","tx","ty","forceUpdate","append","texBase","margin","SpriteMaskFilter","maskSprite","maskMatrix","_maskSprite","renderable","npmAlpha","otherMatrix","alpha","worldAlpha","maskClamp","MaskSystem","enableScissor","alphaMaskPool","maskDataPool","alphaMaskIndex","setMaskStack","scissor","maskDataOrTarget","maskData","detect","pushSpriteMask","popSpriteMask","maskCurrent","isSprite","testScissor","alphaMaskFilter","stashFilterArea","AbstractMaskSystem","glConst","getStackLength","curStackLen","newStackLen","disable","enable","_useCurrent","tempMatrix$1","ScissorSystem","WebGLRenderingContext","SCISSOR_TEST","calcScissorRect","prevData","roundFrameToPixels","isMatrixRotated","isFastRect","StencilSystem","STENCIL_TEST","prevMaskCount","clearStencil","STENCIL_BUFFER_BIT","colorMask","stencilFunc","EQUAL","stencilOp","KEEP","INCR","batch","DECR","ProjectionSystem","defaultFrame","projectionMatrix","root","calculateProjection","syncUniformGroup","globals","_destinationFrame","pm","sign","setTransform","_matrix","tempRect2","RenderTextureSystem","_backgroundColorRgba","defaultMaskStack","viewportFrame","screen","clearMask","uboUpdate","_ud","_uv","_syncData","UBO_TO_SINGLE_SETTERS","GLSL_TO_STD40_SIZE","createUBOElements","uboElements","dataLen","chunkSize","uboElement","lineUpValue","getUBOData","usedUniformDatas","sort","generateUniformBufferSync","syncFunc","uniformParser","size_1","rowSize","elementSize","remainder","IGLUniformData","GLProgram","uniformGroups","uniformDirtyGroups","uniformBufferBindings","getAttributeData","totalAttributes","ACTIVE_ATTRIBUTES","attribData","getActiveAttrib","getAttribLocation","getUniformData","totalUniforms","ACTIVE_UNIFORMS","getActiveUniform","match","glVertShader","VERTEX_SHADER","glFragShader","webGLProgram","createProgram","attachShader","linkProgram","bindAttribLocation","deleteShader","getUniformLocation","glProgram","UID$4","defaultSyncData","textureCount","uboCount","ShaderSystem","systemCheck","cache","_uboCache","dontSync","setUniforms","syncData","getGlProgram","createSyncGroups","syncUniformBufferGroup","createSyncBufferGroup","bindBufferBase","uniformBlockIndex","getUniformBlockIndex","uniformBlockBinding","uboData","preFix","mapWebGLBlendModesToPixi","ONE","ONE_MINUS_SRC_ALPHA","DST_COLOR","ONE_MINUS_SRC_COLOR","SRC_ALPHA","DST_ALPHA","ZERO","ONE_MINUS_DST_ALPHA","FUNC_REVERSE_SUBTRACT","FUNC_ADD","BLEND$1","OFFSET$1","CULLING$1","DEPTH_TEST$1","WINDING$1","DEPTH_MASK$1","StateSystem","_blendEq","setBlend","setOffset","setCullFace","setDepthTest","setFrontFace","setDepthMask","checks","defaultState","blendModes","diff","forceState","updateCheck","checkBlendMode","checkPolygonOffset","POLYGON_OFFSET_FILL","CULL_FACE","frontFace","setBlendMode","blendFunc","blendFuncSeparate","blendEquationSeparate","setPolygonOffset","UNPACK_FLIP_Y_WEBGL","system","TextureGCSystem","checkCount","maxIdle","checkCountMax","run","tm","managedTextures","wasRemoved","destroyTexture","unload","displayObject","children","mapTypeAndFormatToInternalFormat","_c","_d","_e","_f","_g","_h","_j","_k","_l","_m","_o","_p","_q","_r","_s","_t","_u","_v","_w","_x","table","RGB8","RG8","R8","RGBA8UI","RGB8UI","RG8UI","R8UI","ALPHA","LUMINANCE","LUMINANCE_ALPHA","RGBA8_SNORM","RGB8_SNORM","RG8_SNORM","R8_SNORM","RGBA8I","RGB8I","RG8I","R8I","RGBA16UI","RGB16UI","RG16UI","R16UI","DEPTH_COMPONENT16","RGBA16I","RGB16I","RG16I","R16I","RGBA32UI","RGB32UI","RG32UI","R32UI","DEPTH_COMPONENT24","RGBA32I","RGB32I","RG32I","R32I","RGBA32F","RGB32F","RG32F","R32F","DEPTH_COMPONENT32F","RGBA16F","RGB16F","RG16F","R16F","RGB565","RGBA4","RGB5_A1","RGB10_A2","RGB10_A2UI","R11F_G11F_B10F","RGB9_E5","DEPTH32F_STENCIL8","RGBA","RGB","GLTexture","samplerType","TextureSystem","currentLocation","_unknownBoundTextures","unknownTexture","hasIntegerTextures","internalFormats","getParameter","MAX_TEXTURE_IMAGE_UNITS","emptyTextures","emptyTexture2D","bindTexture","UNSIGNED_BYTE","TEXTURE_CUBE_MAP","TEXTURE_CUBE_MAP_POSITIVE_X","texParameteri","TEXTURE_MAG_FILTER","TEXTURE_MIN_FILTER","textureGC","initTexture","activeTexture","TEXTURE0","updateTexture","ensureSamplerType","initTextureType","HALF_FLOAT","updateTextureStyle","skipRemove","deleteTexture","generateMipmap","TEXTURE_WRAP_S","TEXTURE_WRAP_T","LINEAR_MIPMAP_LINEAR","NEAREST_MIPMAP_NEAREST","anisotropicExt","level","MAX_TEXTURE_MAX_ANISOTROPY_EXT","texParameterf","TEXTURE_MAX_ANISOTROPY_EXT","_systems","tempMatrix$2","AbstractRenderer","useContextAlpha","autoDensity","preserveDrawingBuffer","clearBeforeRender","_backgroundColor","_backgroundColorString","backgroundColor","backgroundAlpha","transparent","_lastObjectRendered","plugins","initPlugins","staticMap","o","desiredScreenWidth","desiredScreenHeight","screenWidth","screenHeight","generateTexture","region","manualRegion","getLocalBounds","skipUpdateTransform","parent","removeView","parentNode","removeChild","thisAny","_tempDisplayObjectParent","GLBuffer","updateID","byteLength","BufferSystem","managedBuffers","boundBufferBases","createGLBuffer","bindBuffer","UNIFORM_BUFFER","bindBufferRange","bufferSubData","drawType","STATIC_DRAW","DYNAMIC_DRAW","bufferData","deleteBuffer","createBuffer","Renderer","prerender","addSystem","__plugins","antialias","premultipliedAlpha","powerPreference","FRAMEBUFFER_BINDING","DRAW_FRAMEBUFFER_BINDING","DRAW_FRAMEBUFFER","ClassRef","isLost","cacheParent","enableTempParent","updateTransform","disableTempParent","extract","registerPlugin","pluginName","ctor","autoDetectRenderer","$defaultVertex","$defaultFilterVertex","defaultVertex$2","defaultFilterVertex","BatchDrawCall","System","BatchTextureArray","ViewableBuffer","sizeOrBuffer","rawBinaryData","uint32View","float32View","_int8View","Int8Array","_uint8View","_int16View","Int16Array","_uint16View","_int32View","sizeOf","AbstractBatchRenderer","shaderGenerator","geometryClass","vertexSize","_vertexCount","_indexCount","_bufferedElements","_bufferedTextures","_bufferSize","_shader","_packedGeometries","_packedGeometryPoolSize","_flushId","_aBuffers","_iBuffers","MAX_TEXTURES","onPrerender","_dcIndex","_aIndex","_iIndex","_attributeBuffer","_indexBuffer","_tempBoundTextures","generateShader","initFlushBuffers","_drawCallPool","_textureArrayPool","MAX_SPRITES","MAX_TA","vertexData","indices","buildTexturesAndDrawCalls","textureArrays","touch","TICK","countTexArrays","buildDrawCalls","finish","drawCalls","dcIndex","aIndex","iIndex","drawCall","spriteBlendMode","packInterleavedGeometry","bindAndClearTexArray","textureSystem","updateGeometry","packedGeometries","attributeBuffer","_buffer","drawBatches","dcCount","curTexArray","getAttributeBuffer","getIndexBuffer","roundedP2","roundedSizeIndex","roundedSize","packedVertices","indicies","textureId","argb","_tintRGB","BatchShaderGenerator","programCache","defaultGroupCache","sampleValues","uSamplers","generateSampleSrc","tint","translationMatrix","default","BatchGeometry","defaultVertex$3","defaultFragment$2","BatchPluginFactory","BatchPlugin","BatchRenderer","_loop_1","systems","_loop_2","Bounds","minX","Infinity","minY","maxX","maxY","isEmpty","getRectangle","addPoint","point","addPointMatrix","addQuad","addFrame","addFrameMatrix","addVertexData","beginOffset","endOffset","addVertices","addVerticesMatrix","padX","padY","rawX","rawY","addBounds","bounds","addBoundsMask","_minX","_minY","_maxX","_maxY","addBoundsMatrix","addBoundsArea","area","paddingX","paddingY","addFramePad","DisplayObject","tempDisplayObjectParent","visible","cullable","cullArea","_lastSortedIndex","_zIndex","_enabledFilters","_bounds","_localBounds","_boundsID","_boundsRect","_localBoundsRect","_mask","_maskRefCount","_destroyed","isMask","mixin","propertyName","getOwnPropertyDescriptor","_recursivePostUpdateTransform","skipUpdate","calculateBounds","transformRef","parentRef","worldBounds","worldBoundsID","toGlobal","position","displayObjectUpdateTransform","toLocal","applyInverse","setParent","container","addChild","scaleX","scaleY","rotation","skewX","skewY","pivotX","pivotY","skew","pivot","_options","removeAllListeners","hitArea","interactive","interactiveChildren","TemporaryDisplayObject","myParent","localTransform","sortDirty","sortChildren","zIndex","Container","sortableChildren","onChildrenChange","_length","child","_parentID","addChildAt","swapChildren","child2","index1","getChildIndex","index2","setChildIndex","currentIndex","getChildAt","removeChildAt","removeChildren","beginIndex","endIndex","removed","begin","end","range","RangeError","sortRequired","_calculateBounds","skipChildrenUpdate","_renderWithCulling","_render","intersects","childCullable","renderAdvanced","NONE","destroyChildren","oldChildren","containerUpdateTransform","SHAPES","PI_2","PI","RAD_TO_DEG","DEG_TO_RAD","Point","equals","Rectangle","RECT","rectangle","contains","other","x0_1","x1_1","y0_1","y1_1","nx","ny","n00","n10","n01","n11","mx","my","m00","m10","m01","m11","eps","enlarge","Circle","radius","CIRC","r2","dx","dy","Ellipse","halfWidth","halfHeight","ELIP","normx","normy","Polygon","points","flat","il","POLY","closeStroke","polygon","inside","xi","yi","xj","yj","intersect","reduce","pointsDesc","currentPoint","RoundedRectangle","RREC","radius2","ObservablePoint","cb","scope","_y","Matrix","fromArray","toArray","transpose","pos","newPos","angle","cos","sin","a1","c1","tx1","b1","d1","decompose","atan2","delta","sqrt","ux","uy","vx","vy","rotationCayley","rotationMatrices","signum","init","row","_ux","_uy","_vx","_vy","k","groupD8","E","SE","S","SW","W","NW","N","NE","MIRROR_VERTICAL","MAIN_DIAGONAL","MIRROR_HORIZONTAL","REVERSE_DIAGONAL","uX","ind","uY","vX","vY","inv","rotationSecond","rotationFirst","sub","rotate180","isVertical","byDirection","matrixAppendRotationInv","Transform","onChange","updateSkew","_rotation","_cx","_sx","_cy","_sy","_localID","_currentLocalID","_worldID","updateLocalTransform","parentTransform","pt","wt","setFromMatrix","IDENTITY","PropertyNode","time","ease","next","isStepped","generateEase","node","first","hexToRGB","GetTextureFromString","DEG_TO_RADS","rotatePoint","xnew","ynew","combineRGBComponents","normalize","oneOverLen","scaleBy","color","charAt","substr","parseInt","segments","qty","oneOverQty","cp","getBlendMode","toUpperCase","BehaviorOrder","Particle","emitter","super","prevChild","nextChild","config","maxLife","age","agePercent","oneOverLife","prev","kill","recycle","ticker","PositionParticle","Symbol","Emitter","particleParent","initBehaviors","updateBehaviors","recycleBehaviors","minLifetime","maxLifetime","customEase","_frequency","spawnChance","maxParticles","emitterLifetime","spawnPos","particlesPerWave","ownerPos","_prevEmitterPos","_prevPosIsValid","_posChanged","_parent","addAtBack","particleCount","_emit","_spawnTimer","_emitterLife","_activeParticlesFirst","_activeParticlesLast","_poolFirst","_origConfig","_destroyWhenComplete","_completeCallback","updateSpawnPos","updateOwnerPos","knownBehaviors","frequency","cleanup","lifetime","behaviors","order","Spawn","updateParticle","recycleParticle","getBehavior","find","fillPool","particle","fromCleanup","newRot","resetPositionTracking","playOnceAndDestroy","callback","playOnce","lerp","prevX","prevY","curX","curY","emitPosX","emitPosY","waveFirst","waveLast","random","behavior","initParticles","emitNow","getRandPos","editorConfig","Torus","innerRadius","affectRotation","PolygonalChain","countingLengths","totalLength","chain","prevPoint","second","p1","p2","l","segLength","rand","chosenSeg","AccelerationBehavior","Late","minStart","maxStart","accel","maxSpeed","speed","velocity","deltaSec","vel","oldVX","oldVY","currentSpeed","intValueSimple","intColorSimple","curVal","nextVal","intValueComplex","intColorComplex","intValueStepped","intColorStepped","PropertyList","isColor","interpolate","AlphaBehavior","Normal","createList","StaticAlphaBehavior","getTextures","outTextures","dupe","RandomAnimatedTextureBehavior","anims","anim","framerate","parsedAnim","duration","loop","animElapsed","animDuration","animFramerate","SingleAnimatedTextureBehavior","BlendModeBehavior","BurstSpawnBehavior","spacing","distance","ColorBehavior","StaticColorBehavior","OrderedTextureBehavior","helperPoint","MATH_FUNCS","WHITELISTER","RegExp","concat","parsePath","pathString","matches","PathBehavior","path","minMult","initRotation","initPosition","movement","mult","speedMult","PointSpawnBehavior","_first","RandomTextureBehavior","RotationBehavior","minSpeed","rotSpeed","oldSpeed","StaticRotationBehavior","NoRotationBehavior","ScaleBehavior","scaleMult","StaticScaleBehavior","ShapeSpawnBehavior","ShapeClass","shapes","shape","typeOverride","registerShape","SingleTextureBehavior","SpeedBehavior","StaticSpeedBehavior","upgradeConfig","art","acceleration","minimumSpeedMultiplier","noRotation","extraData","minimumScaleMultiplier","rotationAcceleration","rotationSpeed","startRotation","orderedArt","spawnType","angleStart","particleSpacing","spawnCircle","minR","spawnRect","spawnPolygon","registerBehavior","Runner","_name","_aliasCount","a0","a2","a3","a4","a5","a6","a7","ensureNonAliasedItems","defineProperties","dispatch","appleIphone","appleIpod","appleTablet","appleUniversal","androidPhone","androidTablet","amazonPhone","amazonTablet","windowsPhone","windowsTablet","otherBlackBerry","otherBlackBerry10","otherOpera","otherChrome","otherFirefox","isAppleTabletOnIos13","navigator","platform","maxTouchPoints","MSStream","createMatch","userAgent","regex","isMobile","param","nav","tmp","apple","phone","ipod","tablet","universal","device","amazon","android","windows","blackberry","blackberry10","opera","firefox","chrome","any","maxRecommendedTextures","allowMax","majorVersion","canUploadSameBuffer","settings","MIPMAP_TEXTURES","POW2","ANISOTROPIC_LEVEL","RESOLUTION","FILTER_RESOLUTION","FILTER_MULTISAMPLE","SPRITE_MAX_TEXTURES","SPRITE_BATCH_SIZE","RENDER_OPTIONS","GC_MODE","AUTO","GC_MAX_IDLE","GC_MAX_CHECK_COUNT","WRAP_MODE","CLAMP","SCALE_MODE","PRECISION_VERTEX","HIGH","PRECISION_FRAGMENT","MEDIUM","CAN_UPLOAD_SAME_BUFFER","CREATE_IMAGE_BITMAP","ROUND_PIXELS","tempPoint","Sprite","_anchor","_onAnchorUpdate","_tint","_cachedTint","vertexTrimmedData","_transformID","_transformTrimmedID","_textureTrimmedID","_roundPixels","_onTextureUpdate","calculateVertices","w0","w1","h0","h1","calculateTrimmedVertices","containsPoint","destroyBaseTexture","UPDATE_PRIORITY","TickerListener","fn","priority","previous","deltaTime","redirect","connect","hard","Ticker","autoStart","lastTime","started","_requestId","_maxElapsedMS","_minElapsedMS","_protected","_lastFrame","_head","deltaMS","_tick","requestAnimationFrame","_requestIfNeeded","performance","now","_cancelIfNeeded","cancelAnimationFrame","_startIfPossible","NORMAL","_addListener","addOnce","listener","head","fps","minFPS","maxFPS","minFPMS","_shared","shared","_system","TickerPlugin","sharedTicker","_ticker","LOW","oldTicker","parse","supported","saidHello","VERSION","sayHello","args","log","isWebGLSupported","contextOptions","failIfMajorPerformanceCaveat","success","aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","goldenrod","gold","gray","green","greenyellow","grey","honeydew","hotpink","indianred","indigo","ivory","khaki","lavenderblush","lavender","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen","cssColorNames","hex2rgb","hex","hex2string","hexString","string2hex","string","mapPremultipliedBlendModes","npm","premultiplyBlendMode","correctBlendMode","premultiplied","premultiplyRgba","rgb","premultiply","premultiplyTint","G","B","premultiplyTintToRgba","createIndicesForQuads","outBuffer","totalIndices","getBufferType","nextPow2","isPow2","log2","removeItems","startIdx","removeCount","nextUid","warnings","deprecation","version","message","ignoreDepth","stack","ProgramCache","TextureCache","BaseTextureCache","CanvasRenderTarget","clearRect","val","trimCanvas","imageData","getImageData","pixels","tempAnchor","determineCrossOrigin","url$1","href","parsedUrl","samePort","port","hostname","protocol","getResolutionOfUrl","has","Events","EE","addListener","TypeError","evt","_events","_eventsCount","clearEvent","EventEmitter","eventNames","events","names","listeners","handlers","ee","listenerCount","removeListener","prefixed","module","exports","makeMap","str","expectsLowerCase","PatchFlagNames","GLOBALS_WHITE_LISTED","isGloballyWhitelisted","generateCodeFrame","lines","newlineSequences","_","idx","repeat","String","lineLength","newLineSeqLength","specialBooleanAttrs","isSpecialBooleanAttr","includeBooleanAttr","normalizeStyle","isString","parseStringStyle","isObject","listDelimiterRE","propertyDelimiterRE","cssText","ret","normalizeClass","normalizeProps","props","class","klass","HTML_TAGS","SVG_TAGS","VOID_TAGS","isHTMLTag","isSVGTag","isVoidTag","looseCompareArrays","equal","looseEqual","aValidType","isDate","bValidType","getTime","aKeysCount","bKeysCount","aHasKey","bHasKey","looseIndexOf","findIndex","toDisplayString","objectToString","isFunction","JSON","stringify","replacer","_key","__v_isRef","isMap","entries","isSet","values","isPlainObject","EMPTY_OBJ","EMPTY_ARR","NOOP","NO","onRE","isOn","isModelListener","startsWith","extend","el","hasOwn","toTypeString","Date","isSymbol","isPromise","catch","toRawType","isIntegerKey","isReservedProp","cacheStringFunction","hit","camelizeRE","camelize","hyphenateRE","hyphenate","capitalize","toHandlerKey","hasChanged","oldValue","is","invokeArrayFns","fns","arg","def","obj","toNumber","isNaN","_globalThis","getGlobalThis","self","window","beforeAppear","appear","afterAppear","appearCancelled","beforeEnter","enter","afterEnter","enterCancelled","beforeLeave","leave","afterLeave","leaveCancelled","required","dimension","validator","includes","easing","watch","clearCachedDimensions","cachedStyles","computed","transition","transitions","convertToCssProperty","methods","$emit","done","detectAndCacheDimensions","setClosedDimensions","hideOverflow","forceRepaint","setTransition","setOpenedDimensions","setTimeout","unsetOverflow","unsetTransition","unsetDimensions","visibility","display","detectRelevantDimensions","offsetHeight","paddingTop","getCssValue","paddingBottom","offsetWidth","paddingLeft","paddingRight","overflow","getComputedStyle","getPropertyValue","upperChars","__exports__","global","isCallable","tryToString","argument","isConstructor","wellKnownSymbol","definePropertyModule","UNSCOPABLES","ArrayPrototype","f","unicode","isPrototypeOf","it","Prototype","fails","isExtensible","$forEach","arrayMethodIsStrict","STRICT_METHOD","callbackfn","toObject","callWithSafeIterationClosing","isArrayIteratorMethod","lengthOfArrayLike","createProperty","getIterator","getIteratorMethod","arrayLike","O","IS_CONSTRUCTOR","argumentsLength","mapfn","mapping","step","iterator","iteratorMethod","toIndexedObject","toAbsoluteIndex","createMethod","IS_INCLUDES","$this","fromIndex","uncurryThis","IndexedObject","arraySpeciesCreate","TYPE","IS_MAP","IS_FILTER","IS_SOME","IS_EVERY","IS_FIND_INDEX","IS_FILTER_REJECT","NO_HOLES","that","specificCreate","boundFunction","some","every","filterReject","V8_VERSION","SPECIES","METHOD_NAME","foo","Boolean","method","fin","originalArray","C","arraySpeciesConstructor","anObject","iteratorClose","ENTRIES","ITERATOR","SAFE_CLOSING","called","iteratorWithReturn","SKIP_CLOSING","ITERATION_SUPPORT","object","stringSlice","TO_STRING_TAG_SUPPORT","classofRaw","TO_STRING_TAG","CORRECT_ARGUMENTS","tryGet","tag","callee","TEST","V8_OR_CHAKRA_STACK_ENTRY","IS_V8_OR_CHAKRA_STACK","dropEntries","redefineAll","anInstance","iterate","defineIterator","setSpecies","DESCRIPTORS","fastKey","InternalStateModule","setInternalState","internalStateGetterFor","getterFor","getConstructor","wrapper","CONSTRUCTOR_NAME","ADDER","Constructor","iterable","last","AS_ENTRIES","getInternalState","define","entry","getEntry","setStrong","ITERATOR_NAME","getInternalCollectionState","getInternalIteratorState","iterated","kind","$","isForced","redefine","InternalMetadataModule","checkCorrectnessOfIteration","setToStringTag","inheritIfRequired","IS_WEAK","NativeConstructor","NativePrototype","exported","fixMethod","KEY","uncurriedNativeMethod","REPLACE","HASNT_CHAINING","THROWS_ON_PRIMITIVES","ACCEPT_ITERABLES","BUGGY_ZERO","$instance","dummy","forced","ownKeys","getOwnPropertyDescriptorModule","exceptions","MATCH","regexp","error1","error2","F","getPrototypeOf","requireObjectCoercible","quot","IteratorPrototype","createPropertyDescriptor","Iterators","returnThis","IteratorConstructor","NAME","ENUMERABLE_NEXT","writable","toPropertyKey","propertyKey","IS_PURE","FunctionName","createIteratorConstructor","createNonEnumerableProperty","IteratorsCore","PROPER_FUNCTION_NAME","PROPER","CONFIGURABLE_FUNCTION_NAME","CONFIGURABLE","BUGGY_SAFARI_ITERATORS","KEYS","VALUES","Iterable","DEFAULT","IS_SET","FORCED","CurrentIteratorPrototype","getIterationMethod","KIND","defaultIterator","IterablePrototype","INCORRECT_VALUES_NAME","nativeIterator","anyNativeIterator","proto","wrappedWellKnownSymbolModule","EXISTS","IndexSizeError","m","DOMStringSizeError","HierarchyRequestError","WrongDocumentError","InvalidCharacterError","NoDataAllowedError","NoModificationAllowedError","NotFoundError","NotSupportedError","InUseAttributeError","InvalidStateError","SyntaxError","InvalidModificationError","NamespaceError","InvalidAccessError","ValidationError","TypeMismatchError","SecurityError","NetworkError","AbortError","URLMismatchError","QuotaExceededError","TimeoutError","InvalidNodeTypeError","DataCloneError","CSSRuleList","CSSStyleDeclaration","CSSValueList","ClientRectList","DOMRectList","DOMStringList","DOMTokenList","DataTransferItemList","FileList","HTMLAllCollection","HTMLCollection","HTMLFormElement","HTMLSelectElement","MediaList","MimeTypeArray","NamedNodeMap","NodeList","PaintRequestList","Plugin","PluginArray","SVGLengthList","SVGNumberList","SVGPathSegList","SVGPointList","SVGStringList","SVGTransformList","SourceBufferList","StyleSheetList","TextTrackCueList","TextTrackList","TouchList","documentCreateElement","classList","DOMTokenListPrototype","Pebble","classof","getBuiltIn","Deno","versions","v8","normalizeStringArgument","nativeErrorToString","INCORRECT_TO_STRING","setGlobal","copyConstructorProperties","targetProperty","sourceProperty","descriptor","TARGET","GLOBAL","STATIC","stat","noTargetGet","sham","regexpExec","RegExpPrototype","SHAM","SYMBOL","DELEGATES_TO_SYMBOL","DELEGATES_TO_EXEC","execCalled","re","flags","uncurriedNativeRegExpMethod","nativeMethod","arg2","forceStringMethod","$exec","preventExtensions","FunctionPrototype","Reflect","aCallable","getDescriptor","aFunction","namespace","getMethod","usingIterator","V","P","SUBSTITUTION_SYMBOLS","SUBSTITUTION_SYMBOLS_NO_NAMED","matched","captures","namedCaptures","replacement","tailPos","symbols","ch","capture","check","propertyIsEnumerable","Wrapper","NewTarget","NewTargetPrototype","store","functionToString","inspectSource","cause","hiddenKeys","getOwnPropertyNamesModule","getOwnPropertyNamesExternalModule","FREEZING","REQUIRED","METADATA","setMetadata","objectID","weakData","getWeakData","onFreeze","meta","getOwnPropertyNames","NATIVE_WEAK_MAP","sharedKey","OBJECT_ALREADY_INITIALIZED","WeakMap","enforce","wmget","wmhas","wmset","metadata","facade","STATE","noop","empty","construct","constructorRegExp","isConstructorModern","isConstructorLegacy","feature","detection","POLYFILL","NATIVE","isRegExp","USE_SYMBOL_AS_UID","$Symbol","Result","stopped","ResultPrototype","unboundFunction","iterFn","IS_ITERATOR","INTERRUPTED","condition","callFn","innerResult","innerError","PrototypeOfArrayIteratorPrototype","arrayIterator","NEW_ITERATOR_PROTOTYPE","toLength","LOG10E","log10","notify","toggle","promise","macrotask","IS_IOS","IS_IOS_PEBBLE","IS_WEBOS_WEBKIT","IS_NODE","MutationObserver","WebKitMutationObserver","queueMicrotaskDescriptor","queueMicrotask","domain","exit","nextTick","createTextNode","observe","characterData","task","symbol","PromiseCapability","$$resolve","$$reject","$default","globalIsFinite","isFinite","objectKeys","getOwnPropertySymbolsModule","propertyIsEnumerableModule","$assign","A","alphabet","chr","T","activeXDocument","definePropertiesModule","enumBugKeys","html","GT","LT","PROTOTYPE","SCRIPT","IE_PROTO","EmptyConstructor","scriptTag","content","NullProtoObjectViaActiveX","write","temp","parentWindow","NullProtoObjectViaIFrame","iframeDocument","iframe","JS","contentWindow","open","NullProtoObject","ActiveXObject","Properties","V8_PROTOTYPE_DEFINE_BUG","IE8_DOM_DEFINE","$defineProperty","$getOwnPropertyDescriptor","ENUMERABLE","WRITABLE","Attributes","$getOwnPropertyNames","arraySlice","windowNames","getWindowNames","internalObjectKeys","CORRECT_PROTOTYPE_GETTER","ObjectPrototype","ARRAY_BUFFER_NON_EXTENSIBLE","$isExtensible","FAILS_ON_PRIMITIVES","$propertyIsEnumerable","NASHORN_BUG","aPossiblePrototype","setter","CORRECT_SETTER","TO_ENTRIES","pref","valueOf","newPromiseCapability","promiseCapability","Queue","tail","enforceInternalState","TEMPLATE","unsafe","simple","regexpFlags","stickyHelpers","UNSUPPORTED_DOT_ALL","UNSUPPORTED_NCG","nativeReplace","nativeExec","patchedExec","UPDATES_LAST_INDEX_WRONG","re1","re2","lastIndex","UNSUPPORTED_Y","BROKEN_CARET","NPCG_INCLUDED","PATCH","reCopy","raw","groups","sticky","charsAdded","strCopy","multiline","ignoreCase","dotAll","$RegExp","MISSED_STICKY","TAG","SHARED","copyright","aConstructor","defaultConstructor","toIntegerOrInfinity","charCodeAt","CONVERT_TO_STRING","codeAt","whitespaces","non","whitespace","ltrim","rtrim","defer","channel","setImmediate","clearImmediate","Dispatch","MessageChannel","counter","queue","ONREADYSTATECHANGE","runner","post","postMessage","host","port2","port1","onmessage","importScripts","integer","ordinaryToPrimitive","TO_PRIMITIVE","exoticToPrim","toPrimitive","postfix","NATIVE_SYMBOL","WellKnownSymbolsStore","symbolFor","createWellKnownSymbol","withoutSetter","description","installErrorCause","clearErrorStack","ERROR_STACK_INSTALLABLE","FULL_NAME","IS_AGGREGATE_ERROR","OPTIONS_POSITION","ERROR_NAME","OriginalError","OriginalErrorPrototype","BaseError","WrappedError","arrayMethodHasSpeciesSupport","IS_CONCAT_SPREADABLE","MAX_SAFE_INTEGER","MAXIMUM_ALLOWED_INDEX_EXCEEDED","IS_CONCAT_SPREADABLE_SUPPORT","SPECIES_SUPPORT","isConcatSpreadable","spreadable","$filter","HAS_SPECIES_SUPPORT","$findIndex","addToUnscopables","FIND_INDEX","SKIPS_HOLES","$find","FIND","INCORRECT_ITERATION","$includes","ARRAY_ITERATOR","Arguments","un$Join","ES3_STRINGS","separator","$map","un$Slice","MAXIMUM_ALLOWED_LENGTH_EXCEEDED","deleteCount","insertCount","actualDeleteCount","to","actualStart","wrapErrorConstructorWithCause","WEB_ASSEMBLY","WebAssembly","exportGlobalErrorCauseWrapper","exportWebAssemblyErrorCauseWrapper","FUNCTION_NAME_EXISTS","nameRE","regExpExec","$stringify","numberToString","tester","low","hi","fix","space","LN2","trunc","thisNumberValue","NUMBER","NativeNumber","NumberPrototype","toNumeric","primValue","third","radix","maxCode","digits","NaN","NumberWrapper","numberIsFinite","$repeat","pow","un$ToExponential","toExponential","ROUNDS_PROPERLY","THROWS_ON_INFINITY_FRACTION","PROPER_NON_FINITE_THIS_CHECK","fractionDigits","un$ToFixed","toFixed","acc","multiply","c2","divide","dataToString","z","fractDigits","nativeGetOwnPropertyDescriptor","getOwnPropertyDescriptors","nativeKeys","$values","NativePromise","speciesConstructor","promiseResolve","NON_GENERIC","real","onFinally","Internal","OwnPromiseCapability","PromiseWrapper","nativeThen","microtask","hostReportErrors","newPromiseCapabilityModule","perform","IS_BROWSER","PROMISE","getInternalPromiseState","NativePromisePrototype","PromiseConstructor","PromisePrototype","newGenericPromiseCapability","DISPATCH_EVENT","createEvent","dispatchEvent","NATIVE_REJECTION_EVENT","PromiseRejectionEvent","UNHANDLED_REJECTION","REJECTION_HANDLED","PENDING","FULFILLED","REJECTED","HANDLED","UNHANDLED","SUBCLASSING","PROMISE_CONSTRUCTOR_SOURCE","GLOBAL_CORE_JS_PROMISE","FakePromise","isThenable","callReaction","reaction","exited","ok","handler","fail","rejection","onHandleUnhandled","isReject","notified","reactions","onUnhandled","reason","initEvent","IS_UNHANDLED","isUnhandled","unwrap","internalReject","internalResolve","executor","onFulfilled","onRejected","wrap","capability","$promiseResolve","remaining","alreadyCalled","race","un$Test","$toString","regExpFlags","TO_STRING","n$ToString","getFlags","NOT_GENERIC","INCORRECT_NAME","rf","collection","collectionStrong","notARegExp","correctIsRegExpLogic","stringIndexOf","searchString","STRING_ITERATOR","createHTML","forcedStringHTMLMethod","link","fixRegExpWellKnownSymbolLogic","advanceStringIndex","getSubstitution","maybeToString","REPLACE_KEEPS_$0","REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE","REPLACE_SUPPORTS_NAMED_GROUPS","maybeCallNative","UNSAFE_SUBSTITUTE","searchValue","replaceValue","rx","functionalReplace","fullUnicode","results","matchStr","accumulatedResult","nextSourcePosition","replacerArgs","small","callRegExpExec","MAX_UINT32","$push","SPLIT_WORKS_WITH_OVERWRITTEN_EXEC","originalExec","SPLIT","nativeSplit","internalSplit","limit","lim","lastLength","lastLastIndex","separatorCopy","splitter","unicodeMatching","q","$trim","forcedStringTrimMethod","NativeSymbol","SymbolPrototype","EmptyStringDescriptionStore","SymbolWrapper","symbolToString","symbolValueOf","desc","defineWellKnownSymbol","nativeObjectCreate","getOwnPropertyNamesExternal","HIDDEN","QObject","nativeDefineProperty","nativeGetOwnPropertyNames","nativePropertyIsEnumerable","AllSymbols","ObjectPrototypeSymbols","StringToSymbolRegistry","SymbolToStringRegistry","USE_SETTER","findChild","setSymbolDescriptor","ObjectPrototypeDescriptor","$defineProperties","properties","$getOwnPropertySymbols","$create","IS_OBJECT_PROTOTYPE","keyFor","sym","useSetter","useSimple","FORCED_JSON_STRINGIFY","$replacer","hint","DOMIterables","handlePrototype","CollectionPrototype","COLLECTION_NAME","ArrayIteratorMethods","ArrayValues","tryNodeRequire","errorToString","DOMExceptionConstants","DOM_EXCEPTION","DATA_CLONE_ERR","NativeDOMException","NativeDOMExceptionPrototype","ErrorPrototype","HAS_STACK","codeFor","$DOMException","DOMExceptionPrototype","createGetterDescriptor","INCORRECT_CONSTRUCTOR","INCORRECT_CODE","MISSED_CONSTANTS","FORCED_CONSTRUCTOR","DOMException","PolyfilledDOMException","PolyfilledDOMExceptionPrototype","constant","constantName","ERROR_HAS_STACK","DOM_EXCEPTION_HAS_STACK","earcut","holeIndices","dim","invSize","hasHoles","outerLen","outerNode","linkedList","triangles","eliminateHoles","earcutLinked","clockwise","signedArea","insertNode","removeNode","filterPoints","again","steiner","ear","pass","indexCurve","isEarHashed","isEar","cureLocalIntersections","splitEarcut","pointInTriangle","minTX","minTY","maxTX","maxTY","minZ","zOrder","maxZ","prevZ","nextZ","locallyInside","isValidDiagonal","splitPolygon","getLeftmost","compareX","eliminateHole","hole","bridge","findHoleBridge","bridgeReverse","filteredBridge","hx","hy","qx","tanMin","sectorContainsSector","sortLinked","numMerges","pSize","qSize","inSize","leftmost","ax","ay","bx","by","cx","cy","px","py","intersectsPolygon","middleInside","q1","q2","o1","o2","o3","o4","onSegment","num","Node","b2","an","bp","sum","deviation","polygonArea","trianglesArea","flatten","holes","dimensions","holeIndex","LZString","fromCharCode","keyStrBase64","keyStrUriSafe","baseReverseDic","getBaseValue","character","compressToBase64","_compress","decompressFromBase64","_decompress","compressToUTF16","decompressFromUTF16","compressed","compressToUint8Array","uncompressed","compress","TotalLen","current_value","decompressFromUint8Array","decompress","compressToEncodedURIComponent","decompressFromEncodedURIComponent","bitsPerChar","getCharFromInt","ii","context_dictionary","context_dictionaryToCreate","context_c","context_wc","context_w","context_enlargeIn","context_dictSize","context_numBits","context_data","context_data_val","context_data_position","resetValue","getNextValue","bits","resb","maxpower","power","dictionary","enlargeIn","dictSize","numBits","propIsEnumerable","shouldUseNative","test1","test2","order2","test3","letter","err","finallyConstructor","allSettled","status","setTimeoutFunc","thisArg","_state","_handled","_value","_deferreds","doResolve","handle","deferred","_immediateFn","newValue","finale","_unhandledRejectionFn","Handler","ex","prom","ONE_FRAME_TIME","startTime_1","vendors","delay","clearTimeout","isInteger","accessibleTarget","accessible","accessibleTitle","accessibleHint","tabIndex","_accessibleActive","_accessibleDiv","accessibleType","accessiblePointerEvents","accessibleChildren","renderId","KEY_CODE_TAB","DIV_TOUCH_SIZE","DIV_TOUCH_POS_X","DIV_TOUCH_POS_Y","DIV_TOUCH_ZINDEX","DIV_HOOK_SIZE","DIV_HOOK_POS_X","DIV_HOOK_POS_Y","DIV_HOOK_ZINDEX","AccessibilityManager","debug","_isActive","_isMobileAccessibility","pool","androidUpdateCount","androidUpdateFrequency","_hookDiv","createTouchHook","div","_onKeyDown","_onMouseMove","hookDiv","title","activate","destroyTouchHook","body","deactivate","updateAccessibleObjects","getBoundingClientRect","viewWidth","viewHeight","sx","sy","capHitArea","updateDebugHTML","innerHTML","borderStyle","_onClick","_onFocus","_onFocusOut","pointerEvents","interactionManager","interaction","eventData","keyCode","movementX","movementY","InteractionData","pressure","rotationAngle","twist","tangentialPressure","originalEvent","identifier","isPrimary","button","buttons","tiltX","tiltY","pointerType","getLocalPosition","globalPos","copyEvent","which","InteractionEvent","stopsPropagatingAt","stopPropagationHint","currentTarget","stopPropagation","InteractionTrackingData","pointerId","_pointerId","_flags","FLAGS","_doSet","yn","OVER","RIGHT_DOWN","LEFT_DOWN","freeze","TreeSearch","_tempPoint","recursiveFindHit","interactionEvent","hitTest","interactiveParent","hitTestChildren","childHit","findHit","interactiveTarget","buttonMode","cursor","trackedPointers","_trackedPointers","MOUSE_POINTER_ID","hitTestEvent","InteractionManager","autoPreventDefault","interactionFrequency","mouse","activeInteractionData","interactionDataPool","interactionDOMElement","moveWhenInside","eventsAdded","tickerAdded","mouseOverRenderer","supportsTouchEvents","supportsPointerEvents","PointerEvent","onPointerUp","processPointerUp","onPointerCancel","processPointerCancel","onPointerDown","processPointerDown","onPointerMove","processPointerMove","onPointerOut","processPointerOverOut","onPointerOver","cursorStyles","pointer","currentCursorMode","delayedEvents","search","_tempDisplayObject","_eventListenerOptions","passive","_useSystemTicker","useSystemTicker","setTargetElement","addTickerListener","removeTickerListener","globalPoint","lastObjectRendered","processInteractive","removeEvents","addEvents","tickerUpdate","msPointerEnabled","msContentZooming","msTouchAction","touchAction","_didMove","interactionData","configureInteractionEventForDOMEvent","setCursorMode","applyStyles","eventString","delayDispatchEvent","mapPositionToPoint","parentElement","resolutionMultiplier","delayedLen","displayObject_1","normalizeToPointerData","isNormalized","cancelable","eventLen","getInteractionDataForPointerId","isRightButton","rightDown","leftDown","onPointerComplete","cancelled","eventAppend","releaseInteractionDataForPointerId","trackingData","isTouch","isMouse","isMouseTap","isDown","over","none","pointerEvent","clientX","clientY","globalX","globalY","normalizedEvents","TouchEvent","li","changedTouches","touches","radiusX","radiusY","force","layerX","offsetX","layerY","offsetY","MouseEvent","tempEvent","Application","stage","forceCanvas","_plugins","plugin","stageOptions","reverse","ResizePlugin","dom","queueResize","_resizeTo","cancelResize","_resizeId","innerWidth","innerHeight","clientWidth","clientHeight","resizeTo","TEMP_RECT","BYTES_PER_PIXEL","Extract","image","quality","base64","toDataURL","flipY","generated","canvasBuffer","webglPixels","readPixels","canvasData","arrayPostDivide","putImageData","target_1","SignalBinding","_fn","_once","_thisArg","_next","_prev","_owner","detach","_addSignalBinding","_tail","Signal","exists","detachAll","parseUri","opts","parser","loose","strictMode","uri","_t0","t1","t2","useXdr","XDomainRequest","XMLHttpRequest","STATUS_NONE","STATUS_OK","STATUS_EMPTY","STATUS_IE_BUG_EMPTY","STATUS_TYPE_OK","_noop","setExtMap","extname","reqType","xhr","LoaderResource","_dequeue","_onLoadBinding","_elementTimer","_boundComplete","_boundOnError","_boundOnProgress","_boundOnTimeout","_boundXhrOnError","_boundXhrOnTimeout","_boundXhrOnAbort","_boundXhrOnLoad","_setFlag","STATUS_FLAGS","DATA_URL","_getExtension","timeout","loadType","_determineLoadType","xhrType","UNKNOWN","progressChunk","_onProgress","_onTimeout","_xhrOnError","_xhrOnTimeout","_xhrOnAbort","_xhrOnLoad","onStart","onProgress","onComplete","onAfterMiddleware","setExtensionLoadType","_loadTypeMap","setExtensionXhrType","_xhrTypeMap","_hasFlag","COMPLETE","LOADING","_clearEvents","_finish","abort","xdr","EMPTY_GIF","firstChild","isLoading","isComplete","_determineCrossOrigin","LOAD_TYPE","IMAGE","_loadElement","AUDIO","_loadSourceElement","VIDEO","XHR","_loadXdr","_loadXhr","ontimeout","onprogress","loadElement","skipSource","Audio","isCocoonJS","mimeTypes","mimeType","_createSource","_determineXhrType","withCredentials","XHR_RESPONSE_TYPE","DOCUMENT","responseType","TEXT","send","nodeName","lengthComputable","loaded","total","statusText","text","responseText","BUFFER","statusType","DOMParser","domparser","parseFromString","XML","e$1","response","responseURL","origin","isDataUrl","slashIndex","queryStart","hashStart","_getMimeFromXhrType","BLOB","_noop$1","onlyOnce","gif","png","bmp","jpg","jpeg","tif","tiff","webp","tga","mp3","ogg","wav","mp4","webm","xhtml","htm","xml","tmx","tsx","json","txt","ttf","otf","AsyncQueueItem","AsyncQueue","worker","concurrency","workers","saturated","unsaturated","drain","_tasks","_insert","insertAtFront","idle","unshift","_worker","running","resume","eachSeries","deferNext","MAX_PROGRESS","rgxExtractUrlHash","Loader","baseUrl","progress","loading","defaultQueryString","_beforeMiddleware","_afterMiddleware","_resourcesParsing","_boundLoadResource","_loadResource","_queue","onLoad","pre","use","_add","parentResource","_prepareUrl","incompleteChildren","fullChunk","eachChunk","_onStart","_onComplete","numTasks","chunk","hash","dequeue","_onLoad","AppLoaderPlugin","sharedLoader","loader","TextureLoader","_keyStr","encodeBinary","inx","bytebuffer","encodedCharIndexes","jnx","paddingBytes","Url","URL","webkitURL","parsing","Blob","src_1","createObjectURL","revokeObjectURL","getResponseHeader","INTERNAL_FORMATS","INTERNAL_FORMAT_TO_BYTES_PER_PIXEL","COMPRESSED_RGB_S3TC_DXT1_EXT","COMPRESSED_RGBA_S3TC_DXT1_EXT","COMPRESSED_RGBA_S3TC_DXT3_EXT","COMPRESSED_RGBA_S3TC_DXT5_EXT","COMPRESSED_SRGB_S3TC_DXT1_EXT","COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT","COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT","COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT","COMPRESSED_R11_EAC","COMPRESSED_SIGNED_R11_EAC","COMPRESSED_RG11_EAC","COMPRESSED_SIGNED_RG11_EAC","COMPRESSED_RGB8_ETC2","COMPRESSED_RGBA8_ETC2_EAC","COMPRESSED_SRGB8_ETC2","COMPRESSED_SRGB8_ALPHA8_ETC2_EAC","COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2","COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2","COMPRESSED_RGB_PVRTC_4BPPV1_IMG","COMPRESSED_RGBA_PVRTC_4BPPV1_IMG","COMPRESSED_RGB_PVRTC_2BPPV1_IMG","COMPRESSED_RGBA_PVRTC_2BPPV1_IMG","COMPRESSED_RGB_ETC1_WEBGL","COMPRESSED_RGB_ATC_WEBGL","COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL","COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL","__awaiter","_arguments","generator","fulfilled","rejected","__generator","label","sent","trys","ops","verb","op","_a$1","BlobResource","onBlobLoaded","_data","arrayBuffer","CompressedTextureResource","levels","_formatToExtension","levelBuffers","_levelBuffers","_createLevelBuffers","uint8View","levelID","levelWidth","levelHeight","levelBuffer","compressedTexImage2D","blockWidth","blockHeight","imageWidth","imageHeight","byteOffset","alignedLevelWidth","alignedLevelHeight","levelSize","CompressedTextureLoader","cacheID","textureURL","fallbackURL","url_1","textureFormats","loadOptions","imageMetadata","resourcePath","resourceName","extensionName","textureExtensions","registerCompressedTextures","DXGI_FORMAT","D3D10_RESOURCE_DIMENSION","DDS_MAGIC_SIZE","DDS_HEADER_SIZE","DDS_HEADER_PF_SIZE","DDS_HEADER_DX10_SIZE","DDS_MAGIC","DDS_FIELDS","SIZE","HEIGHT","WIDTH","MIPMAP_COUNT","PIXEL_FORMAT","DDS_PF_FIELDS","FOURCC","RGB_BITCOUNT","R_BIT_MASK","G_BIT_MASK","B_BIT_MASK","A_BIT_MASK","DDS_DX10_FIELDS","RESOURCE_DIMENSION","MISC_FLAG","ARRAY_SIZE","MISC_FLAGS2","_a$2","_b$1","PF_FLAGS","DDPF_ALPHA","DDPF_FOURCC","DDPF_RGB","DDPF_YUV","DDPF_LUMINANCE","FOURCC_DXT1","FOURCC_DXT3","FOURCC_DXT5","FOURCC_DX10","DDS_RESOURCE_MISC_TEXTURECUBE","FOURCC_TO_FORMAT","DXGI_TO_FORMAT","DXGI_FORMAT_BC1_TYPELESS","DXGI_FORMAT_BC1_UNORM","DXGI_FORMAT_BC2_TYPELESS","DXGI_FORMAT_BC2_UNORM","DXGI_FORMAT_BC3_TYPELESS","DXGI_FORMAT_BC3_UNORM","DXGI_FORMAT_BC1_UNORM_SRGB","DXGI_FORMAT_BC2_UNORM_SRGB","DXGI_FORMAT_BC3_UNORM_SRGB","DDSLoader","magicWord","header","mipmapCount","pixelFormat","formatFlags","fourCC","internalFormat_1","dataOffset_1","texData","dx10Offset","dx10Header","dxgiFormat","resourceDimension","miscFlag","arraySize","internalFormat_2","DDS_DIMENSION_TEXTURE3D","imageBuffers","dataOffset","pixelSize","imageSize","imageOffset","FILE_IDENTIFIER","ENDIANNESS","KTX_FIELDS","GL_TYPE","GL_TYPE_SIZE","GL_FORMAT","GL_INTERNAL_FORMAT","GL_BASE_INTERNAL_FORMAT","PIXEL_WIDTH","PIXEL_HEIGHT","PIXEL_DEPTH","NUMBER_OF_ARRAY_ELEMENTS","NUMBER_OF_FACES","NUMBER_OF_MIPMAP_LEVELS","BYTES_OF_KEY_VALUE_DATA","FILE_HEADER_SIZE","TYPES_TO_BYTES_PER_COMPONENT","FORMATS_TO_COMPONENTS","TYPES_TO_BYTES_PER_PIXEL","KTXLoader","textures_1","dataView","DataView","validate","littleEndian","getUint32","glFormat","glInternalFormat","pixelWidth","pixelHeight","pixelDepth","numberOfArrayElements","numberOfFaces","numberOfMipmapLevels","bytesOfKeyValueData","imagePixelByteSize","alignedWidth","alignedHeight","imagePixels","imageByteSize","mipByteSize","alignedMipWidth","alignedMipHeight","mipmapLevel","elementOffset","arrayElement","mips","convertToInt","convertFormatToInteger","getUint8","ParticleContainer","maxSize","batchSize","autoResize","maxBatchSize","_properties","_maxSize","_batchSize","_buffers","_bufferUpdateIDs","roundPixels","setProperties","tintRgb","smallestChildIndex","LINE_JOIN","LINE_CAP","ParticleBuffer","dynamicPropertyFlags","dynamicProperties","staticProperties","property","attributeName","uploadFunction","staticStride","staticBuffer","staticData","staticDataUint32","dynamicStride","dynamicBuffer","dynamicData","dynamicDataUint32","initBuffers","dynamicOffset","dynBuffer","staticOffset","statBuffer","uploadDynamic","startIndex","amount","uploadStatic","ParticleRenderer","uploadVertices","uploadPosition","uploadRotation","uploadUvs","uploadTint","totalChildren","generateBuffers","uColor","updateStatic","_generateOneMoreBuffer","bid","TRIANGLES","spritePosition","spriteRotation","textureUvs","GRAPHICS_CURVES","adaptive","maxLength","minSegments","maxSegments","epsilon","_segmentsCount","defaultSegments","FillStyle","fixOrientation","i1","i2","i3","i4","buildPoly","build","graphicsData","triangulate","graphicsGeometry","verts","holeArray","vertPos","buildCircle","ry","circle","ellipse","roundedRect","j1","j2","j3","j4","center","buildRectangle","rectData","getPt","n1","n2","perc","quadraticBezierCurve","fromX","fromY","cpX","cpY","toX","toY","xa","ya","xb","yb","buildRoundedRectangle","Graphics","nextRoundedRectBehavior","rrectData","vecPos","square","innerWeight","outerWeight","exx","eyy","ix","iy","ox","oy","eix","eiy","eox","eoy","ey","cx2p0x","cy2p0y","angle0","angle1","startAngle","angleDiff","absAngleDiff","segCount","angleInc","buildNonNativeLine","closePointEps","lineStyle","firstPoint","lastPoint","closedShape","closedPath","midPointX","midPointY","indexCount","widthSquared","miterLimitSquared","miterLimit","perpx","perpy","perp1x","perp1y","dist","ratio","alignment","cap","ROUND","SQUARE","dx0","dy0","dx1","dy1","cross","pdist","imx","imy","omx","omy","smallerInsideSegmentSq","insideWeight","smallerInsideDiagonalSq","insideMiterOk","BEVEL","eps2","buildNativeLine","buildLine","native","TEXT_GRADIENT","ArcUtils","curveTo","mm","dd","cc","tt","k1","k2","qy","endAngle","anticlockwise","arc","_startX","_startY","_anticlockwise","sweep","theta","theta2","cTheta","sTheta","segMinus","BezierUtils","curveLength","cpX2","cpY2","t3","nt","nt2","nt3","dt","dt2","dt3","QuadraticUtils","a32","ba","BatchPart","attribStart","endAttrib","FILL_COMMANDS","BATCH_POOL","DRAW_CALL_POOL","GraphicsData","tmpPoint","tmpBounds","GraphicsGeometry","boundsPadding","indicesUint16","batchable","colors","textureIds","batchDirty","batches","cacheDirty","clearDirty","shapeIndex","boundsDirty","batchPart","drawShape","drawHole","lastShape","hitHole","i_1","updateBatches","allow32Indices","validateBatching","currentStyle","command","transformPoints","processHoles","nextTexture","index_1","attribIndex","processFill","processLine","_compareStyles","addUvs","need32","isBatchable","packBatches","styleA","styleB","fill","BATCHABLE_SIZE","currentGroup","currentTexture","drawMode","addColors","addTextureIds","packAttributes","glPoints","f32","u32","sequenceBounds","curMatrix","nextMatrix","lineWidth","poly","rgba","uvsStart","adjustUvs","LineStyle","BUTT","MITER","DEFAULT_SHADERS","currentPath","batchTint","_fillStyle","_lineStyle","_holeMode","_geometry","finishPoly","lineTextureStyle","startPoly","moveTo","lineTo","_initCurve","quadraticCurveTo","bezierCurveTo","arcTo","radius_1","startX","startY","xDiff","yDiff","beginFill","beginTextureFill","endFill","drawRect","drawRoundedRect","drawCircle","drawEllipse","drawPolygon","_populateBatches","_renderBatched","_renderDirect","gI","_batchRGB","calculateTints","_resolveDirectShader","_renderDrawCallDirect","groupTextureCount","_TEMP_POINT","tintRGB","wtID","closePath","setMatrix","beginHole","endHole","defaultStyle","align","breakWords","dropShadow","dropShadowAlpha","dropShadowAngle","dropShadowBlur","dropShadowColor","dropShadowDistance","fillGradientType","LINEAR_VERTICAL","fillGradientStops","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","letterSpacing","lineHeight","lineJoin","stroke","strokeThickness","textBaseline","whiteSpace","wordWrap","wordWrapWidth","leading","genericFontFamilies","TextStyle","styleID","deepCopyProperties","clonedProperties","_align","_breakWords","_dropShadow","_dropShadowAlpha","_dropShadowAngle","_dropShadowBlur","_dropShadowColor","outputColor","getColor","_dropShadowDistance","_fill","_fillGradientType","_fillGradientStops","areArraysEqual","_fontFamily","_fontSize","_fontStyle","_fontVariant","_fontWeight","_letterSpacing","_lineHeight","_leading","_lineJoin","_miterLimit","_padding","_stroke","_strokeThickness","_textBaseline","_trim","_whiteSpace","_wordWrap","_wordWrapWidth","toFontString","fontSizeString","fontFamilies","getSingleColor","array1","array2","propertyObj","prop","TextMetrics","lineWidths","maxLineWidth","fontProperties","measureText","_canvas","font","measureFont","ascent","outputText","collapseSpaces","collapseNewlines","canPrependSpaces","tokens","tokenize","token","isNewline","addLine","currIsBreakingSpace","isBreakingSpace","lastIsBreakingSpace","tokenWidth","getFromCache","canBreakWords","characters","wordWrapSplit","char","nextChar","lastChar","canBreakChars","characterWidth","isLastToken","newLine","trimRight","_newlines","_nextChar","_breakingSpaces","_token","_char","_index","_fonts","descent","_context","metricsString","METRICS_STRING","BASELINE_SYMBOL","baseline","HEIGHT_MULTIPLIER","BASELINE_MULTIPLIER","fillText","imagedata","clearMetrics","defaultDestroyOptions","Text","ownCanvas","_ownCanvas","_autoResolution","_text","_style","_styleListener","_font","localStyleID","updateText","respectDirty","linePositionX","linePositionY","measured","passesCount","isShadowPass","dsOffsetText","dsOffsetShadow","strokeStyle","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","_generateFillStyle","linePositionYShift","nextLineHeightBehavior","drawLetterSpacing","isStroke","supportLetterSpacing","experimentalLetterSpacing","CanvasRenderingContext2D","textLetterSpacing","strokeText","currentPosition","stringArray","previousWidth","currentWidth","currentChar","textStr","trimmed","metrics","gradient","dropShadowCorrection","lengthPlus1","createLinearGradient","textHeight","lastLineBottom","thisLineTop","thisLineGradientStart","thisLineBottom","nextLineTop","thisLineGradientEnd","gradStopLineHeight","lineStop","globalStop","addColorStop","totalIterations","currentIteration","CountLimiter","maxItemsPerFrame","itemsLeft","beginFrame","allowedToUpload","findMultipleBaseTextures","_textures","findBaseTexture","findTexture","drawText","_helper","calculateTextStyle","findText","findTextStyle","BasePrepare","limiter","uploadHookHelper","addHooks","uploadHooks","completes","ticking","delayedTick","prepareItems","registerFindHook","registerUploadHook","tick","uploaded","addHook","uploadHook","uploadBaseTextures","uploadGraphics","findGraphics","Prepare","Spritesheet","TimeLimiter","maxMilliseconds","frameStart","resolutionFilename","animations","_updateResolution","_frames","frames","_frameKeys","_batchIndex","_callback","BATCH_SIZE","_processFrames","_processAnimations","_parseComplete","_nextBatch","initialFrameIndex","frameIndex","maxFrames","sourceSize","rotated","spriteSourceSize","animName","frameName","SpritesheetLoader","imageResourceName","multiPacks","related_multi_packs","itemName","itemUrl","multiPacks_1","getResourcePath","spritesheet","fragmentSimpleSrc","TilingSprite","tileTransform","uvRespectAnchor","gl1VertexSrc","gl1FragmentSrc","gl2VertexSrc","gl2FragmentSrc","TilingSpriteRenderer","simpleShader","ts","anchorX","anchorY","baseTex","uv","H","uMapCoord","uTransform","MeshBatchUvs","_bufferUpdateId","_textureUpdateId","tempPolygon","Mesh","vertexDirty","batchUvs","_renderToBatch","_renderDefault","calculateUvs","material","verticesBuffer","vertexDirtyId","geomUvs","ind0","ind1","ind2","_cachedTexture","MeshMaterial","uTextureMatrix","_colorDirty","_alpha","MeshGeometry","uvsBuffer","_updateId","BitmapFontData","info","page","kerning","distanceField","TextFormat","rawData","chars","kernings","attributeList","itemData","strValue","floatValue","face","file","xoffset","yoffset","xadvance","df","distanceRange","fieldType","XMLFormat","XMLDocument","getElementsByTagName","XMLStringFormat","xmlTxt","formats","autoDetectFormat","generateFillStyle","lastIterationStop","clampedStop","drawGlyph","splitTextToCharacters","resolveCharacters","startCode","endCode","j_1","extractCharCode","codePointAt","BitmapFont","ownsTextures","pageTextures","_ownsTextures","page_1","xOffset","yOffset","xAdvance","distanceFieldRange","distanceFieldType","install","fontData","available","uninstall","textStyle","defaultOptions","textureWidth","textureHeight","charsList","positionX","positionY","maxCharHeight","textureGlyphWidth","NUMERIC","ALPHANUMERIC","ASCII","msdfFrag","msdfVert","pageMeshDataDefaultPageMeshData","pageMeshDataMSDFPageMeshData","charRenderDataPool","BitmapFontLoader","BitmapText","styleDefaults","maxWidth","fontName","_activePagesMeshData","_textWidth","_textHeight","_fontName","_maxWidth","_maxLineHeight","_textureCache","lineSpaces","charsInput","pageMeshDataPool","prevCharCode","lastLineWidth","lastBreakPos","lastBreakWidth","spacesRemoved","maxLineHeight","spaceCount","charCode","charData","charRenderData","prevSpaces","lineAlignOffsets","alignOffset","lenChars","pagesMeshData","newPagesMeshData","activePagesMeshData","baseTextureUid","pageMeshData","meshBlendMode","uFWidth","mesh","vertexCount","uvsCount","total_1","xPos","yPos","pageMesh","textureFrame","anchorOffsetX","anchorOffsetY","i_2","textureBuffer","worldScale","fontScale","getBaseUrl","pageFile","bitmapFont","bitmapResource","resUrl","dirname","dir","AlphaFilter","uAlpha","vertTemplate","generateBlurVertSource","kernelSize","halfLength","vertSource","blurLoop","blur","GAUSSIAN_VALUES","generateBlurFragSource","kernel","fragSource","BlurFilterPass","horizontal","strength","vertSrc","fragSrc","_quality","passes","renderTarget","BLIT","BlurFilter","blurXFilter","blurYFilter","repeatEdgePixels","xStrength","yStrength","updatePadding","_repeatEdgePixels","ColorMatrixFilter","_loadMatrix","newMatrix","_multiply","_colorMatrix","brightness","greyscale","blackAndWhite","hue","cosR","sinR","sqrW","a00","a01","a02","a10","a11","a12","a20","a21","a22","contrast","saturate","desaturate","negative","sepia","technicolor","polaroid","toBGR","kodachrome","browni","vintage","colorTone","desaturation","toned","lightColor","darkColor","lR","lG","lB","dR","dG","dB","night","intensity","predator","lsd","grayscale","DisplacementFilter","mapSampler","filterMatrix","lenX","lenY","FXAAFilter","NoiseFilter","noise","seed","uNoise","uSeed","_tempMatrix","CacheData","textureCacheId","originalRender","originalRenderCanvas","originalCalculateBounds","originalGetLocalBounds","originalUpdateTransform","originalDestroy","originalMask","originalFilterArea","originalContainsPoint","cacheAsBitmapResolution","_cacheAsBitmapResolution","cacheAsBitmap","cacheAsBitmapMultisample","_cacheAsBitmapMultisample","_cacheAsBitmap","_cacheData","renderCanvas","_renderCached","_renderCachedCanvas","_cacheAsBitmapDestroy","_destroyCachedDisplayObject","_initCachedDisplayObject","cacheAlpha","cachedRenderTexture","cachedSourceFrame","cachedDestinationFrame","cachedProjectionTransform","_calculateCachedBounds","_getCachedLocalBounds","cachedSprite","_initCachedDisplayObjectCanvas","_renderCanvas","cachedRenderTarget","_projTransform","deep","getChildByName","PlaneGeometry","segWidth","segHeight","segmentsX","segmentsY","sizeX","sizeY","totalSub","xpos","ypos","value2","value3","value4","RopeGeometry","textureScale","updateVertices","nextPoint","perpX","perpY","perpLength","SimplePlane","SimpleRope","ropeGeometry","meshMaterial","verticesX","verticesY","planeGeometry","textureUpdated","DEFAULT_BORDER_SIZE","SimpleMesh","NineSlicePlane","leftWidth","topHeight","rightWidth","bottomHeight","_origWidth","_origHeight","_leftWidth","_rightWidth","_topHeight","_bottomHeight","_refresh","updateHorizontalVertices","_getMinScale","updateVerticalVertices","scaleW","scaleH","_uvw","_uvh","AnimatedSprite","_durations","animationSpeed","updateAnchor","onFrameChange","onLoop","_currentTime","_playing","_previousFrame","gotoAndStop","frameNumber","previousFrame","currentFrame","gotoAndPlay","elapsed","lag","fromFrames","fromImages","images","qs","sep","eq","maxKeys","kstr","vstr","decodeURIComponent","stringifyPrimitive","ks","decode","encode","runtime","Op","iteratorSymbol","asyncIteratorSymbol","asyncIterator","toStringTagSymbol","toStringTag","innerFn","outerFn","tryLocsList","protoGenerator","Generator","Context","_invoke","makeInvokeMethod","tryCatch","GenStateSuspendedStart","GenStateSuspendedYield","GenStateExecuting","GenStateCompleted","ContinueSentinel","GeneratorFunction","GeneratorFunctionPrototype","getProto","NativeIteratorPrototype","Gp","defineIteratorMethods","AsyncIterator","PromiseImpl","invoke","record","__await","unwrapped","previousPromise","enqueue","callInvokeWithMethodAndArg","doneResult","delegate","delegateResult","maybeInvokeDelegate","_sent","dispatchException","abrupt","resultName","nextLoc","pushTryEntry","locs","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","displayName","isGeneratorFunction","genFun","mark","awrap","async","iter","skipTempReset","rootEntry","rootRecord","rval","exception","caught","hasCatch","hasFinally","finallyEntry","thrown","delegateYield","regeneratorRuntime","accidentalStrictMode","enumerableOnly","_objectSpread2","_defineProperty","_typeof","_extends","_objectWithoutPropertiesLoose","excluded","sourceKeys","_objectWithoutProperties","sourceSymbolKeys","_toConsumableArray","_arrayWithoutHoles","_iterableToArray","_unsupportedIterableToArray","_nonIterableSpread","_arrayLikeToArray","minLen","arr2","pattern","IE11OrLess","Edge","FireFox","Safari","IOS","ChromeForAndroid","captureMode","selector","msMatchesSelector","webkitMatchesSelector","getParentOrHost","nodeType","closest","ctx","includeCTX","_throttleTimeout","R_SPACE","toggleClass","className","css","defaultView","selfOnly","appliedTransforms","matrixFn","DOMMatrix","WebKitCSSMatrix","CSSMatrix","MSCSSMatrix","tagName","getWindowScrollingElement","scrollingElement","documentElement","getRect","relativeToContainingBlock","relativeToNonStaticParent","undoScale","elRect","containerRect","elMatrix","isScrolledPast","elSide","parentSide","getParentAutoScrollElement","elSideVal","parentSideVal","getChild","childNum","includeDragEl","currentChild","Sortable","ghost","dragged","draggable","lastChild","lastElementChild","previousElementSibling","getRelativeScrollOffset","offsetLeft","offsetTop","winScroller","scrollLeft","scrollTop","indexOfObject","includeSelf","elem","gotSelf","scrollWidth","scrollHeight","elemCSS","overflowX","overflowY","dst","isRectEqual","rect1","rect2","throttle","ms","cancelThrottle","scrollBy","Polymer","jQuery","Zepto","cloneNode","setRect","unsetRect","expando","AnimationStateManager","animationCallbackId","animationStates","captureAnimationState","animation","fromRect","thisAnimationDuration","childMatrix","addAnimationState","removeAnimationState","animateAll","animating","animationTime","toRect","prevFromRect","prevToRect","animatingRect","targetMatrix","calculateRealTime","animate","animationResetTimer","currentRect","translateX","translateY","animatingX","animatingY","forRepaintDummy","repaint","animated","defaults","initializeByDefault","PluginManager","mount","option","pluginEvent","eventName","sortable","eventCanceled","cancel","eventNameGlobal","initializePlugins","initialized","modified","modifyOption","getEventProperties","eventProperties","modifiedValue","optionListeners","_ref","rootEl","targetEl","cloneEl","toEl","fromEl","oldIndex","newIndex","oldDraggableIndex","newDraggableIndex","putSortable","extraEventProperties","onName","CustomEvent","bubbles","pullMode","lastPutMode","allEventProperties","_excluded","dragEl","parentEl","ghostEl","nextEl","lastDownEl","cloneHidden","dragStarted","moved","activeSortable","active","hideGhostForTarget","_hideGhostForTarget","unhideGhostForTarget","_unhideGhostForTarget","cloneNowHidden","cloneNowShown","dispatchSortableEvent","_dispatchEvent","activeGroup","tapEvt","touchEvt","lastDx","lastDy","tapDistanceLeft","tapDistanceTop","lastTarget","lastDirection","targetMoveDistance","ghostRelativeParent","awaitingDragStarted","ignoreNextClick","sortables","pastFirstInvertThresh","isCircumstantialInvert","ghostRelativeParentInitialScroll","_silent","savedInputChecked","documentExists","PositionGhostAbsolutely","CSSFloatProperty","supportDraggable","supportCssPointerEvents","_detectDirection","elCSS","elWidth","borderLeftWidth","borderRightWidth","child1","firstChildCSS","secondChildCSS","firstChildWidth","marginLeft","marginRight","secondChildWidth","flexDirection","gridTemplateColumns","touchingSideChild2","_dragElInRowColumn","dragRect","targetRect","vertical","dragElS1Opp","dragElS2Opp","dragElOppLength","targetS1Opp","targetS2Opp","targetOppLength","_detectNearestEmptySortable","threshold","emptyInsertThreshold","insideHorizontally","insideVertically","_prepareGroup","toFn","pull","sameGroup","otherGroup","originalGroup","checkPull","checkPut","put","revertClone","stopImmediatePropagation","nearestEmptyInsertDetectEvent","nearest","_onDragOver","_checkOutsideTargetEl","_isOutsideThisEl","disabled","swapThreshold","invertSwap","invertedSwapThreshold","removeCloneOnHide","direction","ghostClass","chosenClass","dragClass","ignore","preventOnFilter","setData","dataTransfer","textContent","dropBubble","dragoverBubble","dataIdAttr","delayOnTouchOnly","touchStartThreshold","devicePixelRatio","forceFallback","fallbackClass","fallbackOnBody","fallbackTolerance","fallbackOffset","supportPointer","nativeDraggable","_onTapStart","_globalDragOver","dropEffect","_onMove","willInsertAfter","retVal","onMoveFn","onMove","draggedRect","related","relatedRect","_disableDraggable","_unsilent","_ghostIsFirst","spacer","_ghostIsLast","_getSwapDirection","isLastTarget","mouseOnAxis","targetLength","targetS1","targetS2","_getInsertDirection","_generateId","_saveInputCheckedState","inputs","checked","_nextTick","_cancelNextTick","_getDirection","originalTarget","shadowRoot","composedPath","isContentEditable","criteria","_prepareDragStart","dragStartFn","ownerDocument","nextSibling","_lastX","_lastY","_onDrop","_disableDelayedDragEvents","_triggerDragStart","_disableDelayedDrag","_delayedDragTouchMoveHandler","_dragStartTimer","_onTouchMove","_onDragStart","selection","getSelection","removeAllRanges","_dragStarted","fallback","_appendGhost","_nulling","_emulateDragOver","elementFromPoint","inserted","ghostMatrix","relativeScrollOffset","cssMatrix","_hideClone","cloneId","insertBefore","_loopId","setInterval","effectAllowed","_dragStartId","revert","isOwner","canSort","fromSortable","completedFired","dragOverEvent","_ignoreWhileAnimating","elLastChild","changed","targetBeforeFirstSwap","sibling","differentLevel","differentRowCol","side1","scrolledPastTop","scrollBefore","dragIndex","nextElementSibling","after","moveVector","extra","axis","insertion","_showClone","_offMoveEvents","_offUpEvents","clearInterval","save","handleEvent","useAnimation","querySelectorAll","removeAttribute","utils","cancelNextTick","detectDirection","_len","scrollEl","scrollRootEl","lastAutoScrollX","lastAutoScrollY","touchEvt$1","pointerElemChangedInterval","autoScrolls","scrolling","AutoScrollPlugin","AutoScroll","scroll","forceAutoScrollFallback","scrollSensitivity","scrollSpeed","bubbleScroll","_handleAutoScroll","_handleFallbackAutoScroll","dragOverCompleted","_ref2","dragOverBubble","drop","clearPointerElemChangedInterval","clearAutoScrolls","nulling","autoScroll","ogElemScroller","newElem","pid","lastSwapEl","isFallback","scrollCustomFn","sens","scrollThisInstance","scrollFn","layersOut","currentParent","canScrollX","canScrollY","scrollPosX","scrollPosY","layer","scrollOffsetY","scrollOffsetX","toSortable","onSpill","Revert","Remove","SwapPlugin","Swap","swapClass","dragStart","dragOverValid","prevSwapEl","_ref3","swapNodes","swapItem","isEqualNode","_ref4","parentSortable","lastMultiDragSelect","multiDragSortable","dragEl$1","clonesFromRect","clonesHidden","multiDragElements","multiDragClones","initialFolding","folding","MultiDragPlugin","MultiDrag","_deselectMultiDrag","_checkKeyDown","_checkKeyUp","selectedClass","multiDragKey","multiDragElement","multiDragKeyDown","isMultiDrag","delayStartGlobal","delayEnded","setupClone","sortableIndex","insertMultiDragClones","showClone","hideClone","_ref5","dragStartGlobal","_ref6","multiDrag","_ref7","_this2","removeMultiDragElements","dragOver","_ref8","_ref9","insertMultiDragElements","_ref10","dragRectAbsolute","clonesHiddenBefore","dragOverAnimationCapture","_ref11","dragMatrix","dragOverAnimationComplete","_ref12","originalEvt","shiftKey","multiDragIndex","nullingGlobal","destroyGlobal","select","deselect","_this3","oldIndicies","newIndicies","clones","clonesInserted","elementsInserted","freeGlobal","punycode","maxInt","base","tMin","tMax","damp","initialBias","initialN","delimiter","regexPunycode","regexNonASCII","regexSeparators","errors","baseMinusTMin","stringFromCharCode","mapDomain","parts","labels","encoded","ucs2decode","ucs2encode","basicToDigit","codePoint","digitToBasic","digit","adapt","numPoints","firstTime","basic","oldi","baseMinusT","inputLength","bias","handledCPCount","basicLength","currentValue","handledCPCountPlusOne","qMinusT","toUnicode","toASCII","util","slashes","auth","query","pathname","urlParse","urlResolve","urlFormat","protocolPattern","portPattern","simplePathPattern","delims","unwise","autoEscape","nonHostChars","hostEndingChars","hostnameMaxLen","hostnamePartPattern","hostnamePartStart","unsafeProtocol","hostlessProtocol","slashedProtocol","querystring","parseQueryString","slashesDenoteHost","u","relative","urlResolveObject","resolveObject","queryIndex","uSplit","slashRegex","simplePath","lowerProto","atSign","hostEnd","hec","parseHost","ipv6Hostname","hostparts","part","newpart","validParts","notHost","bit","ae","esc","escape","qm","rel","tkeys","tk","tkey","rkeys","rk","rkey","relPath","isSourceAbs","isRelAbs","mustEndAbs","removeAllDots","srcPath","psychotic","isNullOrUndefined","authInHost","isNull","hasTrailingSlash","up","isAbsolute","sfc","__vccOpts","D","return","L","inheritAttrs","autocomplete","modelValue","placeholder","tabindex","autofocus","comboboxUid","emits","setup","focus","handleInput","handleChange","handleFocus","handleBlur","handleEscape","$slots","ref","onInput","onFocus","onBlur","onKeyup","__file","U","selected","collapseTags","dataAttrs","handleClick","collapsed","onMousedown","onClick","maxHeight","highlightedOriginalIndex","handleClickItem","handleMouseenter","role","hidden","highlighted","originalIndex","onMouseenter","valueBy","Z","Q","pointerForward","pointerBackward","pointerSet","Y","emptyModelValue","labelBy","disabledBy","groupBy","visibleOptions","multiple","searchable","searchPlaceholder","clearOnSelect","clearOnClose","taggable","closeOnSelect","hideSelected","openDirection","refs","activeElement","relatedTarget","Set","originalOption","Event","K","querySelector","$el","immediate","J","X","ne","te","isFocusing","dropdown","searchingInputValue","handleInputForInput","handleChangeForInput","handleFocusForInput","handleBlurForInput","optionsWithInfo","addOrRemoveOption","innerPlaceholder","pointerFirst","pointerLast","typeAhead","components","VInput","VTags","VDropdown","__VERSION__","le","$attrs","onKeypress","$event","onKeydown","readonly","alt","onEscape","onClickItem","script","autosize","important","maxHeightScroll","computedStyles","isResizeImportant","isOverflowImportant","imp","isHeightImportant","_val","$nextTick","contentHeight","heightVal","created","mounted","normalizeComponent","scopeId","isFunctionalTemplate","moduleIdentifier","shadowMode","createInjector","createInjectorSSR","createInjectorShadow","hook","staticRenderFns","_compiled","functional","_scopeId","$vnode","ssrContext","__VUE_SSR_CONTEXT__","_registeredComponents","_ssrRegister","$root","$options","existing","beforeCreate","normalizeComponent_1","__vue_script__","__vue_render__","_vm","$createElement","_self","directives","rawName","expression","domProps","composing","__vue_staticRenderFns__","__vue_inject_styles__","__vue_scope_id__","__vue_module_identifier__","__vue_is_functional_template__","TextareaAutosize","Vue","component","activeEffectScope","effectScopeStack","EffectScope","detached","effects","cleanups","scopes","fromParent","effectScope","recordEffectScope","effect","getCurrentScope","onScopeDispose","createDep","dep","wasTracked","trackOpBit","newTracked","initDepMarkers","deps","finalizeDepMarkers","ptr","delete","targetMap","effectTrackDepth","maxMarkerBits","effectStack","activeEffect","ITERATE_KEY","MAP_KEY_ITERATE_KEY","ReactiveEffect","scheduler","enableTracking","cleanupEffect","resetTracking","onStop","_effect","lazy","shouldTrack","trackStack","pauseTracking","track","isTracking","depsMap","Map","eventInfo","trackEffects","debuggerEventExtraInfo","trigger","oldTarget","triggerEffects","allowRecurse","isNonTrackableKeys","builtInSymbols","createGetter","shallowGet","readonlyGet","shallowReadonlyGet","arrayInstrumentations","createArrayInstrumentations","instrumentations","isReadonly","shallow","receiver","shallowReadonlyMap","readonlyMap","shallowReactiveMap","reactiveMap","targetIsArray","isRef","shouldUnwrap","reactive","createSetter","shallowSet","hadKey","deleteProperty","mutableHandlers","readonlyHandlers","shallowReactiveHandlers","shallowReadonlyHandlers","toShallow","get$1","isShallow","rawTarget","rawKey","toReadonly","toReactive","has$1","set$1","deleteEntry","hadItems","createForEach","observed","createIterableMethod","targetIsMap","isPair","isKeyOnly","innerIterator","createReadonlyMethod","createInstrumentations","mutableInstrumentations","shallowInstrumentations","readonlyInstrumentations","shallowReadonlyInstrumentations","iteratorMethods","createInstrumentationGetter","mutableCollectionHandlers","shallowCollectionHandlers","readonlyCollectionHandlers","shallowReadonlyCollectionHandlers","targetTypeMap","rawType","getTargetType","createReactiveObject","shallowReactive","shallowReadonly","baseHandlers","collectionHandlers","proxyMap","existingProxy","targetType","proxy","Proxy","isReactive","isProxy","markRaw","trackRefValue","triggerRefValue","newVal","createRef","shallowRef","rawValue","RefImpl","_shallow","_rawValue","triggerRef","unref","shallowUnwrapHandlers","proxyRefs","objectWithRefs","CustomRefImpl","factory","_get","_set","customRef","toRefs","toRef","ObjectRefImpl","_defaultValue","ComputedRefImpl","getter","_setter","_dirty","getterOrOptions","debugOptions","onlyGetter","cRef","devtools","devtoolsNotInstalled","setDevtoolsHook","HTMLElement","replay","__VUE_DEVTOOLS_HOOK_REPLAY__","newHook","emit$1","rawArgs","vnode","modelArg","modifiersKey","handlerName","callWithAsyncErrorHandling","onceHandler","emitted","normalizeEmitsOptions","comp","appContext","asMixin","emitsCache","cached","hasExtends","extendEmits","normalizedFromExtend","mixins","extends","isEmitListener","currentRenderingInstance","currentScopeId","setCurrentRenderingInstance","__scopeId","pushScopeId","popScopeId","withScopeId","_id","withCtx","isNonScopedSlot","_n","renderFnWithContext","setBlockTracking","prevInstance","renderComponentRoot","Component","withProxy","propsOptions","slots","attrs","renderCache","setupState","fallthroughAttrs","shapeFlag","proxyToUse","normalizeVNode","getFunctionalFallthrough","blockStack","handleError","createVNode","Comment","filterModelListeners","cloneVNode","dirs","filterSingleRoot","singleRoot","isVNode","shouldUpdateComponent","prevVNode","nextVNode","optimized","prevProps","prevChildren","nextProps","nextChildren","patchFlag","emitsOptions","$stable","hasPropsChanged","dynamicProps","nextKeys","updateHOCHostEl","subTree","isSuspense","__isSuspense","SuspenseImpl","parentComponent","parentSuspense","isSVG","slotScopeIds","rendererInternals","mountSuspense","patchSuspense","hydrate","hydrateSuspense","createSuspenseBoundary","normalizeSuspenseChildren","Suspense","triggerEvent","eventListener","patch","hiddenContainer","suspense","pendingBranch","ssContent","ssFallback","setActiveBranch","um","unmount","newBranch","newFallback","activeBranch","isInFallback","isHydrating","isSameVNodeType","pendingId","move","isUnmounted","delayEnter","hasUnresolvedAncestor","queuePostFlushCb","fallbackVNode","mountFallback","registerDep","setupRenderEffect","isInPendingSuspense","hydratedEl","asyncDep","asyncSetupResult","suspenseId","asyncResolved","handleSetupResult","doRemove","hydrateNode","isSlotChildren","normalizeSuspenseSlot","block","trackBlock","isBlockTreeEnabled","openBlock","currentBlock","closeBlock","singleChild","dynamicChildren","queueEffectWithSuspense","branch","provide","currentInstance","provides","parentProvides","inject","treatDefaultAsFactory","useTransitionState","isMounted","isLeaving","isUnmounting","leavingVNodes","onMounted","onBeforeUnmount","TransitionHookValidator","BaseTransitionImpl","persisted","onBeforeEnter","onEnter","onAfterEnter","onEnterCancelled","onBeforeLeave","onLeave","onAfterLeave","onLeaveCancelled","onBeforeAppear","onAppear","onAfterAppear","onAppearCancelled","getCurrentInstance","prevTransitionKey","getTransitionRawChildren","rawProps","emptyPlaceholder","innerChild","getKeepAliveChild","enterHooks","resolveTransitionHooks","setTransitionHooks","oldChild","oldInnerChild","transitionKeyChanged","getTransitionKey","leavingHooks","delayLeave","earlyRemove","delayedLeave","leavingVNodesCache","getLeavingNodesForType","_leaveCb","BaseTransition","callHook","hooks","leavingVNode","afterHook","cancelHook","_enterCb","isKeepAlive","keepComment","keyedFragmentCount","Fragment","defineComponent","isAsyncWrapper","__asyncLoader","defineAsyncComponent","loadingComponent","errorComponent","suspensible","userOnError","resolvedComp","pendingRequest","retries","retry","thisRequest","userRetry","userFail","__esModule","__asyncResolved","createInnerComp","delayed","queueJob","__isKeepAlive","KeepAliveImpl","include","exclude","sharedContext","_unmount","storageContainer","resetShapeFlag","pruneCache","getComponentName","pruneCacheEntry","queuePostRenderEffect","isDeactivated","vnodeHook","onVnodeMounted","invokeVNodeHook","da","onVnodeUnmounted","pendingCacheKey","cacheSubtree","getInnerChild","onUpdated","rawVNode","cachedVNode","KeepAlive","onActivated","registerKeepAliveHook","onDeactivated","wrappedHook","__wdc","injectHook","injectToKeepAliveRoot","keepAliveRoot","injected","onUnmounted","__weh","setCurrentInstance","unsetCurrentInstance","createHook","lifecycle","isInSSRComponentSetup","onBeforeMount","onBeforeUpdate","onServerPrefetch","onRenderTriggered","onRenderTracked","onErrorCaptured","shouldCacheAccess","applyOptions","resolveMergedOptions","publicThis","dataOptions","computedOptions","watchOptions","provideOptions","injectOptions","beforeMount","beforeUpdate","updated","activated","deactivated","beforeDestroy","beforeUnmount","unmounted","renderTracked","renderTriggered","errorCaptured","serverPrefetch","expose","checkDuplicateProperties","resolveInjections","unwrapInjectedRef","methodHandler","opt","createWatcher","registerLifecycleHook","register","_hook","exposed","unwrapRef","normalizeInject","createPathGetter","extendsOptions","globalMixins","optionsCache","optionMergeStrategies","resolved","mergeOptions","strats","strat","internalOptionMergeStrats","mergeDataFn","mergeObjectOptions","mergeAsArray","mergeWatchOptions","mergeInject","merged","initProps","isStateful","isSSR","InternalObjectKey","propsDefaults","setFullProps","updateProps","rawPrevProps","rawCurrentProps","hasAttrsChanged","kebabKey","resolvePropValue","propsToUpdate","camelizedKey","needCastKeys","rawCastValues","camelKey","castValues","isAbsent","hasDefault","normalizePropsOptions","propsCache","extendProps","normalizedKey","validatePropName","booleanIndex","getTypeIndex","stringIndex","getType","isSameType","expectedTypes","isInternalKey","normalizeSlotValue","normalizeSlot","rawSlot","normalizeObjectSlots","rawSlots","_ctx","normalizeVNodeSlots","initSlots","updateSlots","needDeletionCheck","deletionComparisonTarget","withDirectives","internalInstance","bindings","modifiers","traverse","invokeDirectiveHook","oldBindings","binding","createAppContext","app","isNativeTag","globalProperties","errorHandler","warnHandler","compilerOptions","createAppAPI","rootComponent","rootProps","installedPlugins","_uid","_component","_props","_container","_instance","directive","rootContainer","isHydrate","__vue_app__","getExposeProxy","setRef","rawRef","oldRawRef","isUnmount","refValue","owner","oldRef","callWithErrorHandling","_isString","_isRef","doSet","hasMismatch","isSVGContainer","namespaceURI","isComment","createHydrationFunctions","mt","mountComponent","patchProp","insert","createComment","hasChildNodes","flushPostFlushCbs","isFragmentStart","onMismatch","handleMismatch","domType","nextNode","Static","needToAdoptContent","staticCount","outerHTML","hydrateFragment","hydrateElement","locateClosingAsyncAnchor","previousSibling","createTextVNode","hydrateChildren","forcePatchValue","endsWith","vnodeHooks","onVnodeBeforeMount","cur","parentVNode","fragmentSlotScopeIds","isFragment","initFeatureFlags","createRenderer","baseCreateRenderer","createHydrationRenderer","createHydrationFns","__VUE__","hostInsert","hostRemove","hostPatchProp","hostCreateElement","createText","hostCreateText","hostCreateComment","setText","hostSetText","setElementText","hostSetElementText","hostParentNode","hostNextSibling","setScopeId","hostSetScopeId","hostCloneNode","insertStaticContent","hostInsertStaticContent","getNextHostNode","processText","processCommentNode","mountStaticNode","processFragment","processElement","processComponent","internals","moveStaticNode","removeStaticNode","mountElement","patchElement","mountChildren","unmountChildren","needCallTransitionHooks","cloneIfMounted","oldProps","newProps","toggleRecurse","onVnodeBeforeUpdate","areChildrenSVG","patchBlockChildren","patchChildren","patchProps","onVnodeUpdated","newChildren","fallbackContainer","oldVNode","newVNode","fragmentStartAnchor","fragmentEndAnchor","traverseStaticChildren","updateComponent","initialVNode","createComponentInstance","setupComponent","updateComponentPreRender","invalidateJob","componentUpdateFn","bu","originNext","nextTree","prevTree","bm","isAsyncWrapperVNode","hydrateSubTree","scopedInitialVNode","flushPreFlushCbs","prevShapeFlag","patchKeyedChildren","patchUnkeyedChildren","oldLength","newLength","commonLength","parentAnchor","l2","e1","e2","nextPos","s1","s2","keyToNewIndexMap","patched","toBePatched","maxNewIndexSoFar","newIndexToOldIndexMap","increasingNewIndexSequence","getSequence","nextIndex","moveType","needTransition","performLeave","shouldInvokeDirs","shouldInvokeVnodeHook","onVnodeBeforeUnmount","unmountComponent","removeFragment","performRemove","bum","_vnode","mc","pc","pbc","createApp","allowed","ch1","ch2","arrI","isTeleport","__isTeleport","isTeleportDisabled","isTargetSVG","SVGElement","resolveTarget","targetSelector","TeleportImpl","mainAnchor","targetAnchor","wasDisabled","currentContainer","currentAnchor","moveTeleport","nextTarget","hydrateTeleport","isReorder","targetNode","_lpa","Teleport","COMPONENTS","DIRECTIVES","resolveComponent","maybeSelfReference","resolveAsset","NULL_DYNAMIC_COMPONENT","resolveDynamicComponent","resolveDirective","warnMissing","selfName","registry","disableTracking","vnodeArgsTransformer","setupBlock","createElementBlock","createBaseVNode","createBlock","__v_isVNode","transformVNodeArgs","transformer","normalizeKey","normalizeRef","ref_key","ref_for","isBlockNode","needFullChildrenNormalization","__v_skip","normalizeChildren","_createVNode","cloned","isClassComponent","guardReactiveProps","extraProps","mergeRef","mergedProps","mergeProps","createStaticVNode","numberOfNodes","createCommentVNode","asBlock","memo","slot","slotFlag","toMerge","incoming","renderList","renderItem","createSlots","dynamicSlots","renderSlot","noSlotted","isCE","validSlotContent","ensureValidVNode","rendered","vnodes","toHandlers","getPublicInstance","isStatefulComponent","publicPropertiesMap","$data","$props","$refs","$parent","$forceUpdate","$watch","instanceWatch","PublicInstanceProxyHandlers","accessCache","normalizedProps","publicGetter","cssModule","__cssModules","RuntimeCompiledPublicInstanceProxyHandlers","unscopables","emptyAppContext","uid$1","exposeProxy","setupContext","bc","rtg","rtc","ec","sp","ce","compile","installWithProxy","setupResult","setupStatefulComponent","createSetupContext","resolvedResult","finishComponentSetup","__ssrInlineRender","ssrRender","registerRuntimeCompiler","_compile","_rc","skipOptions","isCustomElement","delimiters","componentCompilerOptions","finalCompilerOptions","createAttrsProxy","classifyRE","classify","formatComponentName","isRoot","inferFromRegistry","msg","appWarnHandler","trace","getComponentTrace","warnArgs","formatTrace","currentVNode","normalizedStack","recurseCount","parentInstance","logs","formatTraceEntry","formatProps","formatProp","throwInDev","contextVNode","exposedInstance","errorInfo","errorCapturedHooks","appErrorHandler","logError","isFlushing","isFlushPending","flushIndex","pendingPreFlushCbs","activePreFlushCbs","preFlushIndex","pendingPostFlushCbs","activePostFlushCbs","postFlushIndex","resolvedPromise","currentFlushPromise","currentPreFlushParentJob","findInsertionIndex","middle","middleJobId","getId","job","queueFlush","flushJobs","queueCb","activeQueue","pendingQueue","queuePreFlushCb","seen","parentJob","deduped","watchEffect","doWatch","watchPostEffect","watchSyncEffect","INITIAL_WATCHER_VALUE","onTrack","onTrigger","forceTrigger","isMultiSource","onInvalidate","baseGetter","defineProps","defineEmits","defineExpose","withDefaults","useSlots","useAttrs","mergeDefaults","createPropsRestProxy","excludedKeys","withAsyncContext","getAwaitable","awaitable","propsOrChildren","ssrContextKey","useSSRContext","withMemo","isMemoSame","_ssrUtils","ssrUtils","resolveFilter","compatUtils","svgNS","doc","staticTemplateCache","nodeOps","createElementNS","nodeValue","before","patchClass","transitionClasses","_vtc","patchStyle","isCssString","currentDisplay","importantRE","setProperty","autoPrefix","prefixes","prefixCache","xlinkNS","patchAttr","removeAttributeNS","setAttributeNS","isBoolean","patchDOMProp","_getNow","skipTimestampCheck","timeStamp","ffMatch","cachedNow","getNow","patchEvent","prevValue","nextValue","invokers","_vei","existingInvoker","parseName","invoker","createInvoker","optionsModifierRE","initialValue","attached","patchStopImmediatePropagation","originalStop","_stopped","nativeOnRE","shouldSetAsProp","_trueValue","_falseValue","defineCustomElement","hydate","Comp","VueCustomElement","VueElement","initialProps","defineSSRCustomElement","BaseClass","_def","_connected","_resolved","_numberProps","attachShadow","connectedCallback","_resolveDef","disconnectedCallback","_setAttr","mutations","styles","hasOptions","rawKeys","numberProps","_setProp","_getProp","_applyStyles","_update","asyncDef","shouldReflect","shouldUpdate","detail","useCssModule","modules","mod","useCssVars","setVars","setVarsOnVNode","ob","childList","disconnect","vars","setVarsOnNode","TRANSITION","ANIMATION","Transition","resolveTransitionProps","DOMTransitionPropsValidators","enterFromClass","enterActiveClass","enterToClass","appearFromClass","appearActiveClass","appearToClass","leaveFromClass","leaveActiveClass","leaveToClass","TransitionPropsValidators","hasExplicitCallback","baseProps","durations","normalizeDuration","enterDuration","leaveDuration","finishEnter","isAppear","removeTransitionClass","finishLeave","makeEnterHook","nextFrame","addTransitionClass","whenTransitionEnds","forceReflow","NumberOf","cls","endId","expectedType","explicitTimeout","_endId","resolveIfNotStale","propCount","getTransitionInfo","endEvent","onEnd","getStyleProperties","transitionDelays","transitionDurations","transitionTimeout","getTimeout","animationDelays","animationDurations","animationTimeout","hasTransform","delays","toMs","positionMap","newPositionMap","TransitionGroupImpl","moveClass","hasCSSTransform","callPendingCbs","recordPosition","movedChildren","applyTranslation","webkitTransform","transitionDuration","_moveCb","cssTransitionProps","TransitionGroup","oldPos","getModelAssigner","onCompositionStart","onCompositionEnd","vModelText","_assign","castToNumber","domValue","vModelCheckbox","_modelValue","elementValue","getValue","found","filtered","getCheckboxValue","setChecked","vModelRadio","vModelSelect","isSetModel","selectedVal","setSelected","_binding","isMultiple","optionValue","selectedIndex","vModelDynamic","callModelHook","modelToUse","initVModelForSSR","getSSRProps","systemModifiers","modifierGuards","prevent","ctrl","ctrlKey","altKey","metaKey","exact","withModifiers","guard","keyNames","down","withKeys","eventKey","vShow","_vod","setDisplay","initVShowForSSR","rendererOptions","enabledHydration","ensureRenderer","ensureHydrationRenderer","containerOrSelector","normalizeContainer","Element","createSSRApp","ssrDirectiveInitialized","initDirectivesForSSR","defaultOnError","defaultOnWarn","createCompilerError","messages","additionalMessage","FRAGMENT","TELEPORT","SUSPENSE","KEEP_ALIVE","BASE_TRANSITION","OPEN_BLOCK","CREATE_BLOCK","CREATE_ELEMENT_BLOCK","CREATE_VNODE","CREATE_ELEMENT_VNODE","CREATE_COMMENT","CREATE_TEXT","CREATE_STATIC","RESOLVE_COMPONENT","RESOLVE_DYNAMIC_COMPONENT","RESOLVE_DIRECTIVE","RESOLVE_FILTER","WITH_DIRECTIVES","RENDER_LIST","RENDER_SLOT","CREATE_SLOTS","TO_DISPLAY_STRING","MERGE_PROPS","NORMALIZE_CLASS","NORMALIZE_STYLE","NORMALIZE_PROPS","GUARD_REACTIVE_PROPS","TO_HANDLERS","CAMELIZE","CAPITALIZE","TO_HANDLER_KEY","SET_BLOCK_TRACKING","PUSH_SCOPE_ID","POP_SCOPE_ID","WITH_CTX","UNREF","IS_REF","WITH_MEMO","IS_MEMO_SAME","helperNameMap","registerRuntimeHelpers","helpers","locStub","column","createRoot","hoists","imports","temps","codegenNode","createVNodeCall","isBlock","isComponent","helper","getVNodeBlockHelper","inSSR","getVNodeHelper","createArrayExpression","createObjectExpression","createObjectProperty","createSimpleExpression","constType","createCompoundExpression","createCallExpression","createFunctionExpression","params","returns","newline","isSlot","createConditionalExpression","consequent","alternate","createCacheExpression","createBlockStatement","isStaticExp","isBuiltInType","expected","isCoreComponent","nonIdentifierRE","isSimpleIdentifier","validFirstIdentCharRE","validIdentCharRE","whitespaceRE","isMemberExpressionBrowser","stateStack","currentOpenBracketCount","currentOpenParensCount","currentStringType","isMemberExpression","getInnerRange","newLoc","advancePositionWithClone","numberOfCharacters","advancePositionWithMutation","linesCount","lastNewLinePos","findDir","allowEmpty","exp","findProp","dynamicOnly","isStaticArgOf","hasDynamicKeyVBind","isText","isVSlot","isTemplateNode","tagType","isSlotOutlet","ssr","propsHelperSet","getUnnormalizedProps","callPath","injectProp","propsWithInjection","parentCall","alreadyExists","propKeyName","toValidAssetId","getMemoedVNodeCall","makeBlock","removeHelper","getCompatValue","compatConfig","isCompatEnabled","checkCompatEnabled","decodeRE","decodeMap","gt","amp","apos","defaultParserOptions","getNamespace","getTextMode","isPreTag","decodeEntities","rawText","onWarn","comments","createParserContext","getCursor","parseChildren","rawOptions","originalSource","inPre","inVPre","ancestors","ns","nodes","isEnd","parseInterpolation","emitError","parseComment","parseBogusComment","parseCDATA","advanceBy","parseTag","parseElement","isSpecialTemplateDirective","parseText","pushNode","removedWhitespace","shouldCondense","prevIndex","nestedIndex","contentStart","closeIndex","wasInPre","wasInVPre","isPreBoundary","isVPreBoundary","isSelfClosing","inlineTemplateProp","startsWithEndTagOpen","advanceSpaces","currentSource","parseAttributes","isBuiltInComponent","attributeNames","attr","parseAttribute","nameSet","parseAttributeValue","isPropShorthand","dirName","startOffset","getNewPosition","isQuoted","valueLoc","quote","parseTextData","unexpectedChars","innerStart","innerEnd","rawContentLength","rawContent","preTrimContent","endTokens","xs","hoistStatic","walk","isSingleElementRoot","doNotHoistNode","originalCount","hoistedCount","constantType","getConstantType","hoist","getPatchFlag","getGeneratedPropsConstantType","getNodeProps","vSlot","branches","transformHoist","constantCache","returnType","generatedPropsType","childType","expType","allowHoistedHelperSet","getConstantTypeOfHelperCall","keyType","valueType","createTransformContext","filename","prefixIdentifiers","cacheHandlers","nodeTransforms","directiveTransforms","expressionPlugins","slotted","ssrCssVars","bindingMetadata","inline","isTS","nameMatch","identifiers","vFor","vPre","vOnce","currentNode","childIndex","inVOnce","currentCount","helperString","replaceNode","removalIndex","onNodeRemoved","addIdentifiers","removeIdentifiers","hoisted","traverseNode","createRootCodegen","traverseChildren","nodeRemoved","exitFns","onExit","createStructuralDirectiveTransform","PURE_ANNOTATION","createCodegenContext","ast","sourceMap","optimizeImports","runtimeGlobalName","runtimeModuleName","ssrRuntimeModuleName","indentLevel","pure","indent","deindent","withoutNewLine","generate","onContextCreated","hasHelpers","useWithBlock","preambleContext","genFunctionPreamble","functionName","genAssets","genNode","preamble","toJSON","VueBinding","aliasHelper","staticHelpers","genHoists","assets","resolver","genNodeListAsArray","multilines","genNodeList","comma","genText","genExpression","genInterpolation","genCompoundExpression","genComment","genVNodeCall","genCallExpression","genObjectExpression","genArrayExpression","genFunctionExpression","genConditionalExpression","genCacheExpression","genExpressionAsPropertyKey","callHelper","genNullableArgs","needNewline","needsParens","isNested","transformIf","processIf","ifNode","siblings","createCodegenNodeForBranch","parentCondition","getParentCondition","processCodegen","createIfBranch","userKey","keyIndex","createChildrenCodegenNode","keyProperty","needFragmentWrapper","vnodeCall","transformFor","processFor","forNode","renderExp","keyProp","keyExp","isStableFragment","fragmentFlag","childBlock","isTemplate","slotOutlet","createForLoopParams","parseResult","parseForExpression","valueAlias","keyAlias","objectIndexAlias","forAliasRE","forIteratorRE","stripParensRE","inMatch","LHS","RHS","createAliasExpression","valueContent","trimmedOffset","iteratorMatch","keyContent","keyOffset","indexContent","memoArgs","createParamsList","defaultFallback","trackSlotScopes","buildClientSlotFn","buildSlots","buildSlotFn","slotsProperties","hasDynamicSlots","onComponentSlot","hasTemplateSlots","hasNamedDefaultSlot","implicitDefaultChildren","seenSlotNames","slotElement","slotDir","slotChildren","slotLoc","slotName","slotProps","dirLoc","staticSlotName","slotFunction","vIf","vElse","buildDynamicSlot","conditional","buildDefaultSlotProperty","isNonWhitespaceContent","hasForwardedSlots","directiveImportMap","transformElement","vnodeTag","resolveComponentType","isDynamicComponent","vnodeProps","vnodeChildren","vnodePatchFlag","vnodeDynamicProps","dynamicPropNames","vnodeDirectives","shouldUseBlock","propsBuildResult","buildProps","buildDirectiveArgs","shouldBuildAsSlots","hasDynamicTextChild","stringifyDynamicPropNames","isExplicitDynamic","isComponentTag","isProp","isDir","builtIn","elementLoc","mergeArgs","runtimeDirectives","hasChildren","hasRef","hasClassBinding","hasStyleBinding","hasHydrationEventBinding","hasDynamicKeys","hasVnodeHook","analyzePatchFlag","isEventHandler","isVBind","isVOn","dedupeProperties","directiveTransform","needRuntime","propsExpression","classKeyIndex","styleKeyIndex","hasDynamicKey","isHandlerKey","classProp","styleProp","knownProps","dirArgs","trueExpression","modifier","propsNamesString","transformSlotOutlet","processSlotOutlet","slotArgs","expectedLen","nonNameProps","fnExpRE","transformOn","augmentor","shouldCache","isMemberExp","isInlineStatement","hasMultipleStatements","transformBind","_node","injectPrefix","transformText","hasText","callArgs","WeakSet","transformOnce","transformModel","createTransformProps","rawExp","expString","maybeRef","propName","assignmentExp","eventArg","validDivisionCharRE","transformFilter","rewriteFilter","parseFilter","inSingle","inDouble","inTemplateString","inRegex","curly","paren","lastFilterIndex","pushFilter","wrapFilter","seen$1","transformMemo","getBaseTransformPreset","model","baseCompile","isModuleMode","noopDirectiveTransform","V_MODEL_RADIO","V_MODEL_CHECKBOX","V_MODEL_TEXT","V_MODEL_SELECT","V_MODEL_DYNAMIC","V_ON_WITH_MODIFIERS","V_ON_WITH_KEYS","V_SHOW","TRANSITION_GROUP","decoder","decodeHtmlBrowser","asAttr","isRawTextContainer","parserOptions","transformStyle","parseInlineCSS","createDOMCompilerError","transformVHtml","transformVText","baseResult","directiveToUse","isInvalidType","isEventOptionModifier","isNonKeyModifier","maybeKeyModifier","isKeyboardEvent","resolveModifiers","keyModifiers","nonKeyModifiers","eventOptionModifiers","transformClick","isStaticClick","handlerExp","modifierPostfix","transformShow","ignoreSideEffectTags","DOMNodeTransforms","DOMDirectiveTransforms","cloak","show","compileCache","compileToFunction","__WEBPACK_EXTERNAL_MODULE__8bbf__","__WEBPACK_EXTERNAL_MODULE_a352__","installedModules","moduleId","$reduce","arrayMethodUsesToLength","USES_TO_LENGTH","Collection","toInteger","nativeToString","nativeStartsWith","CORRECT_IS_REGEXP_LOGIC","MDN_POLYFILL_BUG","$entries","flattenIntoArray","flatMap","sourceLen","objectHas","__webpack_require__","__WEBPACK_AMD_DEFINE_FACTORY__","__WEBPACK_AMD_DEFINE_ARRAY__","__WEBPACK_AMD_DEFINE_RESULT__","getCurrentScript","currentScript","pageSource","inlineScriptSourceRegExp","inlineScriptSource","ieStackRegExp","ffStackRegExp","stackDetails","scriptLocation","scripts","returnMethod","RE","original","mapper","targetIndex","sourceIndex","mapFn","ACCESSORS","thrower","argument0","argument1","FunctionPrototypeToString","PREFERRED_STRING","$indexOf","nativeIndexOf","NEGATIVE_ZERO","searchElement","variable","IS_RIGHT","nativeRegExpMethod","stringMethod","regexMethod","__webpack_exports__","getConsole","symbolPrototype","_arrayWithHoles","_iterableToArrayLimit","_arr","_nonIterableRest","_slicedToArray","external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_","external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_default","insertNodeAt","fatherNode","refNode","manageAndEmit","manage","eventHandlerNames","isReadOnly","tags","isHtmlTag","isTransition","isHtmlAttribute","project","getComponentAttributes","_ref3$componentData","componentData","createSortableOption","callBackBuilder","getValidSortableEntries","eventType","eventBuilder","_ref13","_ref14","_classCallCheck","_defineProperties","_createClass","protoProps","staticProps","getHtmlElementFromNode","addContext","domElement","__draggable_context","componentStructure_ComponentStructure","ComponentStructure","_ref2$nodes","defaultNodes","footer","realList","externalComponent","rootTransition","_isRootComponent","domIndex","domChildren","firstDomListElement","indexFirstDomListElement","external_commonjs_vue_commonjs2_vue_root_Vue_","getSlot","slotValue","computeNodes","getKey","normalizedList","_map","_map2","getRootInformation","computeComponentStructure","evtName","evtData","_manage","originalElement","_manageAndEmit","delegateCallBack","draggingElement","itemKey","draggableComponent","componentStructure","_this4","sortableOptions","targetDomElement","_sortable","__draggable_component__","newOptionValue","getUnderlyingVm","getUnderlyingPotencialDraggableComponent","htmElement","emitChanges","_this5","alterList","onList","newList","spliceList","updatePosition","getRelatedContextFromMoveEvent","destination","getVmIndexFromDomIndex","onDragStart","_underlying_vm_","onDragAdd","added","onDragRemove","_this$context","onDragUpdate","computeFutureIndex","relatedContext","currentDomIndex","draggedInList","onDragMove","futureIndex","draggedContext","sendEvent","onDragEnd","vuedraggable","nativeSlice","createNanoEvents","for","asyncGeneratorStep","gen","_throw","_asyncToGenerator","arrayWithHoles","iterableToArrayLimit","unsupportedIterableToArray","nonIterableRest","arrayLikeToArray","arrayWithoutHoles","iterableToArray","nonIterableSpread","__defProp","__getOwnPropSymbols","__hasOwnProp","__propIsEnum","__defNormalProp","__spreadValues","isNonEmptyString","isNumber","isUndefined","isJSX","hasProp","isTouchEvent","isToastComponent","isToastContent","isVueComponent","isDOMRect","propKey","getX","targetTouches","getY","POSITION","EVENTS","removeElement","getVueComponentFromObj","toRaw","normalizeToastComponent","isBrowser","EventBus","allHandlers","getHandlers","isEventBusInterface","TYPE2","POSITION2","EVENTS2","VT_NAMESPACE","COMMON","classNames","trueBoolean","ICON","customIcon","CLOSE_BUTTON","showOnHover","ariaLabel","PROGRESS_BAR","hideProgressBar","isRunning","CORE_TOAST","TOP_RIGHT","draggablePercent","pauseOnFocusLoss","pauseOnHover","closeOnClick","toastClassName","bodyClassName","icon","closeButton","closeButtonClassName","showCloseButtonOnHover","accessibility","toastRole","closeButtonLabel","rtl","eventBus","TOAST","onClose","CONTAINER","newestOnTop","maxToasts","toastDefaults","filterBeforeCreate","toast","filterToasts","toasts","containerClassName","shareAppContext","propValidators_default","VtProgressBar_default","hasClass","animationDuration","animationPlayState","opacity","cpClass","animationEnded","_cache","VtProgressBar_default2","VtCloseButton_default","buttonComponent","classes","_hoisted_1","render2","VtCloseButton_default2","VtSuccessIcon_default","_hoisted_12","focusable","xmlns","viewBox","_hoisted_2","_hoisted_3","render3","VtSuccessIcon_default2","VtInfoIcon_default","_hoisted_13","_hoisted_22","_hoisted_32","render4","VtInfoIcon_default2","VtWarningIcon_default","_hoisted_14","_hoisted_23","_hoisted_33","render5","VtWarningIcon_default2","VtErrorIcon_default","_hoisted_15","_hoisted_24","_hoisted_34","render6","VtErrorIcon_default2","VtIcon_default","customIconChildren","trimValue","iconChildren","customIconClass","iconClass","customIconTag","iconTag","hasCustomIcon","iconTypeComponent","types","INFO","SUCCESS","ERROR","WARNING","iconClasses","render7","VtIcon_default2","VtToast_default","ProgressBar","CloseButton","Icon","disableTransitions","beingDragged","dragPos","bodyClasses","draggableStyle","dragDelta","removalDistance","draggableSetup","focusSetup","draggableCleanup","focusCleanup","closeToast","DISMISS","clickHandler","timeoutHandler","hoverPause","hoverPlay","focusPause","focusPlay","_hoisted_16","render8","_component_Icon","_component_CloseButton","_component_ProgressBar","onMouseleave","onCloseToast","VtToast_default2","VtTransition_default","render9","VtTransition_default2","VtToastContainer_default","hide","Toast","VtTransition","positions","toastArray","filteredToasts","ADD","addToast","clearToasts","dismissToast","UPDATE","updateToast","UPDATE_DEFAULTS","updateDefaults","setToast","getPositionToasts","getClasses","render10","_component_Toast","_component_VtTransition","VtToastContainer_default2","buildInterface","globalOptions","mountContainer","baseApp","dismiss","warning","createMockToastInterface","createToastInterface","optionsOrEventBus","toastInjectionKey","globalEventBus","VueToastificationPlugin","App","inter","useToast","src_default"],"sourceRoot":""} \ No newline at end of file diff --git a/js/chunk-vendors.354a9a53.js b/js/chunk-vendors.354a9a53.js deleted file mode 100644 index deac87f..0000000 --- a/js/chunk-vendors.354a9a53.js +++ /dev/null @@ -1,245 +0,0 @@ -(self["webpackChunkprofectus"]=self["webpackChunkprofectus"]||[]).push([[998],{1680:function(t,e,n){"use strict"; -/*! - * @pixi/constants - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/constants is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var r,i,o,s,a,u,l,c,h,f,d,p,m,v,g,_,y,b,E;n.d(e,{iw:function(){return m},T$:function(){return s},V0:function(){return o},mr:function(){return E},yl:function(){return v},lg:function(){return a},Vi:function(){return r},I2:function(){return u},UN:function(){return g},A7:function(){return y},WB:function(){return p},G5:function(){return b},cB:function(){return _},N3:function(){return i},oT:function(){return h},aH:function(){return f},sp:function(){return l},vK:function(){return c},Nt:function(){return d}}),function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"}(r||(r={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(i||(i={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(o||(o={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(s||(s={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(a||(a={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(u||(u={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(l||(l={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(c||(c={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(h||(h={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(f||(f={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(d||(d={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(p||(p={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(m||(m={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(v||(v={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(g||(g={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(_||(_={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(y||(y={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(b||(b={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(E||(E={}))},2038:function(t,e,n){"use strict";n.d(e,{VL:function(){return _},a$:function(){return qe},JZ:function(){return tn},Bv:function(){return on},Ie:function(){return Ke},lW:function(){return X},qm:function(){return v},wn:function(){return Jt},ZX:function(){return z},bO:function(){return nt},$r:function(){return Xt},ud:function(){return q},TI:function(){return F},Th:function(){return je},ex:function(){return Ht},ZM:function(){return qt},xE:function(){return D},UX:function(){return ne},oo:function(){return Z},Rv:function(){return Ze},e6:function(){return Ve},Y9:function(){return $e},kP:function(){return ze}});var r=n(1576),i=n(1680),o=n(8942),s=n(1034),a=n(6679),u=n(9658); -/*! - * @pixi/core - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/core is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -r.X.PREFER_ENV=o.tq.any?i.Vi.WEBGL:i.Vi.WEBGL2,r.X.STRICT_TEXTURE_CACHE=!1;var l=[];function c(t,e){if(!t)return null;var n="";if("string"===typeof t){var r=/\.(\w{3,4})(?:$|\?|#)/i.exec(t);r&&(n=r[1].toLowerCase())}for(var i=l.length-1;i>=0;--i){var o=l[i];if(o.test&&o.test(t,n))return new o(t,e)}throw new Error("Unrecognized source type to auto-detect Resource")} -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */var h=function(t,e){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},h(t,e)};function f(t,e){function n(){this.constructor=t}h(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var d=function(){return d=Object.assign||function(t){for(var e,n=arguments,r=1,i=arguments.length;r<i;r++)for(var o in e=n[r],e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},d.apply(this,arguments)};function p(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&(n[r[i]]=t[r[i]])}return n}var m=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this._width=t,this._height=e,this.destroyed=!1,this.internal=!1,this.onResize=new s.R("setRealSize"),this.onUpdate=new s.R("update"),this.onError=new s.R("onError")}return t.prototype.bind=function(t){this.onResize.add(t),this.onUpdate.add(t),this.onError.add(t),(this._width||this._height)&&this.onResize.emit(this._width,this._height)},t.prototype.unbind=function(t){this.onResize.remove(t),this.onUpdate.remove(t),this.onError.remove(t)},t.prototype.resize=function(t,e){t===this._width&&e===this._height||(this._width=t,this._height=e,this.onResize.emit(t,e))},Object.defineProperty(t.prototype,"valid",{get:function(){return!!this._width&&!!this._height},enumerable:!1,configurable:!0}),t.prototype.update=function(){this.destroyed||this.onUpdate.emit()},t.prototype.load=function(){return Promise.resolve(this)},Object.defineProperty(t.prototype,"width",{get:function(){return this._width},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this._height},enumerable:!1,configurable:!0}),t.prototype.style=function(t,e,n){return!1},t.prototype.dispose=function(){},t.prototype.destroy=function(){this.destroyed||(this.destroyed=!0,this.dispose(),this.onError.removeAll(),this.onError=null,this.onResize.removeAll(),this.onResize=null,this.onUpdate.removeAll(),this.onUpdate=null)},t.test=function(t,e){return!1},t}(),v=function(t){function e(e,n){var r=this,i=n||{},o=i.width,s=i.height;if(!o||!s)throw new Error("BufferResource width or height invalid");return r=t.call(this,o,s)||this,r.data=e,r}return f(e,t),e.prototype.upload=function(t,e,n){var r=t.gl;r.pixelStorei(r.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e.alphaMode===i.iw.UNPACK);var o=e.realWidth,s=e.realHeight;return n.width===o&&n.height===s?r.texSubImage2D(e.target,0,0,0,o,s,e.format,n.type,this.data):(n.width=o,n.height=s,r.texImage2D(e.target,0,n.internalFormat,o,s,0,e.format,n.type,this.data)),!0},e.prototype.dispose=function(){this.data=null},e.test=function(t){return t instanceof Float32Array||t instanceof Uint8Array||t instanceof Uint32Array},e}(m),g={scaleMode:i.aH.NEAREST,format:i.I2.RGBA,alphaMode:i.iw.NPM},_=function(t){function e(e,n){void 0===e&&(e=null),void 0===n&&(n=null);var s=t.call(this)||this;n=n||{};var a=n.alphaMode,u=n.mipmap,l=n.anisotropicLevel,h=n.scaleMode,f=n.width,d=n.height,p=n.wrapMode,v=n.format,g=n.type,_=n.target,y=n.resolution,b=n.resourceOptions;return!e||e instanceof m||(e=c(e,b),e.internal=!0),s.resolution=y||r.X.RESOLUTION,s.width=Math.round((f||0)*s.resolution)/s.resolution,s.height=Math.round((d||0)*s.resolution)/s.resolution,s._mipmap=void 0!==u?u:r.X.MIPMAP_TEXTURES,s.anisotropicLevel=void 0!==l?l:r.X.ANISOTROPIC_LEVEL,s._wrapMode=p||r.X.WRAP_MODE,s._scaleMode=void 0!==h?h:r.X.SCALE_MODE,s.format=v||i.I2.RGBA,s.type=g||i.vK.UNSIGNED_BYTE,s.target=_||i.sp.TEXTURE_2D,s.alphaMode=void 0!==a?a:i.iw.UNPACK,s.uid=(0,o.hQ)(),s.touched=0,s.isPowerOfTwo=!1,s._refreshPOT(),s._glTextures={},s.dirtyId=0,s.dirtyStyleId=0,s.cacheId=null,s.valid=f>0&&d>0,s.textureCacheIds=[],s.destroyed=!1,s.resource=null,s._batchEnabled=0,s._batchLocation=0,s.parentTextureArray=null,s.setResource(e),s}return f(e,t),Object.defineProperty(e.prototype,"realWidth",{get:function(){return Math.round(this.width*this.resolution)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"realHeight",{get:function(){return Math.round(this.height*this.resolution)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"mipmap",{get:function(){return this._mipmap},set:function(t){this._mipmap!==t&&(this._mipmap=t,this.dirtyStyleId++)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"scaleMode",{get:function(){return this._scaleMode},set:function(t){this._scaleMode!==t&&(this._scaleMode=t,this.dirtyStyleId++)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"wrapMode",{get:function(){return this._wrapMode},set:function(t){this._wrapMode!==t&&(this._wrapMode=t,this.dirtyStyleId++)},enumerable:!1,configurable:!0}),e.prototype.setStyle=function(t,e){var n;return void 0!==t&&t!==this.scaleMode&&(this.scaleMode=t,n=!0),void 0!==e&&e!==this.mipmap&&(this.mipmap=e,n=!0),n&&this.dirtyStyleId++,this},e.prototype.setSize=function(t,e,n){return n=n||this.resolution,this.setRealSize(t*n,e*n,n)},e.prototype.setRealSize=function(t,e,n){return this.resolution=n||this.resolution,this.width=Math.round(t)/this.resolution,this.height=Math.round(e)/this.resolution,this._refreshPOT(),this.update(),this},e.prototype._refreshPOT=function(){this.isPowerOfTwo=(0,o.wv)(this.realWidth)&&(0,o.wv)(this.realHeight)},e.prototype.setResolution=function(t){var e=this.resolution;return e===t||(this.resolution=t,this.valid&&(this.width=Math.round(this.width*e)/t,this.height=Math.round(this.height*e)/t,this.emit("update",this)),this._refreshPOT()),this},e.prototype.setResource=function(t){if(this.resource===t)return this;if(this.resource)throw new Error("Resource can be set only once");return t.bind(this),this.resource=t,this},e.prototype.update=function(){this.valid?(this.dirtyId++,this.dirtyStyleId++,this.emit("update",this)):this.width>0&&this.height>0&&(this.valid=!0,this.emit("loaded",this),this.emit("update",this))},e.prototype.onError=function(t){this.emit("error",this,t)},e.prototype.destroy=function(){this.resource&&(this.resource.unbind(this),this.resource.internal&&this.resource.destroy(),this.resource=null),this.cacheId&&(delete o.V8[this.cacheId],delete o.kN[this.cacheId],this.cacheId=null),this.dispose(),e.removeFromCache(this),this.textureCacheIds=null,this.destroyed=!0},e.prototype.dispose=function(){this.emit("dispose",this)},e.prototype.castToBaseTexture=function(){return this},e.from=function(t,n,i){void 0===i&&(i=r.X.STRICT_TEXTURE_CACHE);var s="string"===typeof t,a=null;if(s)a=t;else{if(!t._pixiId){var u=n&&n.pixiIdPrefix||"pixiid";t._pixiId=u+"_"+(0,o.hQ)()}a=t._pixiId}var l=o.V8[a];if(s&&i&&!l)throw new Error('The cacheId "'+a+'" does not exist in BaseTextureCache.');return l||(l=new e(t,n),l.cacheId=a,e.addToCache(l,a)),l},e.fromBuffer=function(t,n,r,o){t=t||new Float32Array(n*r*4);var s=new v(t,{width:n,height:r}),a=t instanceof Float32Array?i.vK.FLOAT:i.vK.UNSIGNED_BYTE;return new e(s,Object.assign(g,o||{width:n,height:r,type:a}))},e.addToCache=function(t,e){e&&(-1===t.textureCacheIds.indexOf(e)&&t.textureCacheIds.push(e),o.V8[e]&&console.warn("BaseTexture added to the cache with an id ["+e+"] that already had an entry"),o.V8[e]=t)},e.removeFromCache=function(t){if("string"===typeof t){var e=o.V8[t];if(e){var n=e.textureCacheIds.indexOf(t);return n>-1&&e.textureCacheIds.splice(n,1),delete o.V8[t],e}}else if(t&&t.textureCacheIds){for(var r=0;r<t.textureCacheIds.length;++r)delete o.V8[t.textureCacheIds[r]];return t.textureCacheIds.length=0,t}return null},e._globalBatch=0,e}(o.vp),y=function(t){function e(e,n){var r=this,i=n||{},o=i.width,s=i.height;r=t.call(this,o,s)||this,r.items=[],r.itemDirtyIds=[];for(var a=0;a<e;a++){var u=new _;r.items.push(u),r.itemDirtyIds.push(-2)}return r.length=e,r._load=null,r.baseTexture=null,r}return f(e,t),e.prototype.initFromArray=function(t,e){for(var n=0;n<this.length;n++)t[n]&&(t[n].castToBaseTexture?this.addBaseTextureAt(t[n].castToBaseTexture(),n):t[n]instanceof m?this.addResourceAt(t[n],n):this.addResourceAt(c(t[n],e),n))},e.prototype.dispose=function(){for(var t=0,e=this.length;t<e;t++)this.items[t].destroy();this.items=null,this.itemDirtyIds=null,this._load=null},e.prototype.addResourceAt=function(t,e){if(!this.items[e])throw new Error("Index "+e+" is out of bounds");return t.valid&&!this.valid&&this.resize(t.width,t.height),this.items[e].setResource(t),this},e.prototype.bind=function(e){if(null!==this.baseTexture)throw new Error("Only one base texture per TextureArray is allowed");t.prototype.bind.call(this,e);for(var n=0;n<this.length;n++)this.items[n].parentTextureArray=e,this.items[n].on("update",e.update,e)},e.prototype.unbind=function(e){t.prototype.unbind.call(this,e);for(var n=0;n<this.length;n++)this.items[n].parentTextureArray=null,this.items[n].off("update",e.update,e)},e.prototype.load=function(){var t=this;if(this._load)return this._load;var e=this.items.map((function(t){return t.resource})).filter((function(t){return t})),n=e.map((function(t){return t.load()}));return this._load=Promise.all(n).then((function(){var e=t.items[0],n=e.realWidth,r=e.realHeight;return t.resize(n,r),Promise.resolve(t)})),this._load},e}(m),b=function(t){function e(e,n){var r,i,o=this,s=n||{},a=s.width,u=s.height;return Array.isArray(e)?(r=e,i=e.length):i=e,o=t.call(this,i,{width:a,height:u})||this,r&&o.initFromArray(r,n),o}return f(e,t),e.prototype.addBaseTextureAt=function(t,e){if(!t.resource)throw new Error("ArrayResource does not support RenderTexture");return this.addResourceAt(t.resource,e),this},e.prototype.bind=function(e){t.prototype.bind.call(this,e),e.target=i.sp.TEXTURE_2D_ARRAY},e.prototype.upload=function(t,e,n){var r=this,i=r.length,o=r.itemDirtyIds,s=r.items,a=t.gl;n.dirtyId<0&&a.texImage3D(a.TEXTURE_2D_ARRAY,0,n.internalFormat,this._width,this._height,i,0,e.format,n.type,null);for(var u=0;u<i;u++){var l=s[u];o[u]<l.dirtyId&&(o[u]=l.dirtyId,l.valid&&a.texSubImage3D(a.TEXTURE_2D_ARRAY,0,0,0,u,l.resource.width,l.resource.height,1,e.format,n.type,l.resource.source))}return!0},e}(y),E=function(t){function e(e){var n=this,r=e,i=r.naturalWidth||r.videoWidth||r.width,o=r.naturalHeight||r.videoHeight||r.height;return n=t.call(this,i,o)||this,n.source=e,n.noSubImage=!1,n}return f(e,t),e.crossOrigin=function(t,e,n){void 0===n&&0!==e.indexOf("data:")?t.crossOrigin=(0,o.Qq)(e):!1!==n&&(t.crossOrigin="string"===typeof n?n:"anonymous")},e.prototype.upload=function(t,e,n,r){var o=t.gl,s=e.realWidth,a=e.realHeight;if(r=r||this.source,r instanceof HTMLImageElement){if(!r.complete||0===r.naturalWidth)return!1}else if(r instanceof HTMLVideoElement&&r.readyState<=1)return!1;return o.pixelStorei(o.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e.alphaMode===i.iw.UNPACK),this.noSubImage||e.target!==o.TEXTURE_2D||n.width!==s||n.height!==a?(n.width=s,n.height=a,o.texImage2D(e.target,0,n.internalFormat,e.format,n.type,r)):o.texSubImage2D(o.TEXTURE_2D,0,0,0,e.format,n.type,r),!0},e.prototype.update=function(){if(!this.destroyed){var e=this.source,n=e.naturalWidth||e.videoWidth||e.width,r=e.naturalHeight||e.videoHeight||e.height;this.resize(n,r),t.prototype.update.call(this)}},e.prototype.dispose=function(){this.source=null},e}(m),T=function(t){function e(e){return t.call(this,e)||this}return f(e,t),e.test=function(t){var e=globalThis.OffscreenCanvas;return!!(e&&t instanceof e)||globalThis.HTMLCanvasElement&&t instanceof HTMLCanvasElement},e}(E),x=function(t){function e(n,r){var o=this,s=r||{},a=s.width,u=s.height,l=s.autoLoad,c=s.linkBaseTexture;if(n&&n.length!==e.SIDES)throw new Error("Invalid length. Got "+n.length+", expected 6");o=t.call(this,6,{width:a,height:u})||this;for(var h=0;h<e.SIDES;h++)o.items[h].target=i.sp.TEXTURE_CUBE_MAP_POSITIVE_X+h;return o.linkBaseTexture=!1!==c,n&&o.initFromArray(n,r),!1!==l&&o.load(),o}return f(e,t),e.prototype.bind=function(e){t.prototype.bind.call(this,e),e.target=i.sp.TEXTURE_CUBE_MAP},e.prototype.addBaseTextureAt=function(t,e,n){if(void 0===n&&(n=this.linkBaseTexture),!this.items[e])throw new Error("Index "+e+" is out of bounds");if(!this.linkBaseTexture||t.parentTextureArray||Object.keys(t._glTextures).length>0){if(!t.resource)throw new Error("CubeResource does not support copying of renderTexture.");this.addResourceAt(t.resource,e)}else t.target=i.sp.TEXTURE_CUBE_MAP_POSITIVE_X+e,t.parentTextureArray=this.baseTexture,this.items[e]=t;return t.valid&&!this.valid&&this.resize(t.realWidth,t.realHeight),this.items[e]=t,this},e.prototype.upload=function(t,n,r){for(var i=this.itemDirtyIds,o=0;o<e.SIDES;o++){var s=this.items[o];i[o]<s.dirtyId&&(s.valid&&s.resource?(s.resource.upload(t,s,r),i[o]=s.dirtyId):i[o]<-1&&(t.gl.texImage2D(s.target,0,r.internalFormat,n.realWidth,n.realHeight,0,n.format,r.type,null),i[o]=-1))}return!0},e.test=function(t){return Array.isArray(t)&&t.length===e.SIDES},e.SIDES=6,e}(y),S=function(t){function e(e,n){var i=this;if(n=n||{},!(e instanceof HTMLImageElement)){var o=new Image;E.crossOrigin(o,e,n.crossorigin),o.src=e,e=o}return i=t.call(this,e)||this,!e.complete&&i._width&&i._height&&(i._width=0,i._height=0),i.url=e.src,i._process=null,i.preserveBitmap=!1,i.createBitmap=(void 0!==n.createBitmap?n.createBitmap:r.X.CREATE_IMAGE_BITMAP)&&!!globalThis.createImageBitmap,i.alphaMode="number"===typeof n.alphaMode?n.alphaMode:null,i.bitmap=null,i._load=null,!1!==n.autoLoad&&i.load(),i}return f(e,t),e.prototype.load=function(t){var e=this;return this._load||(void 0!==t&&(this.createBitmap=t),this._load=new Promise((function(t,n){var r=e.source;e.url=r.src;var i=function(){e.destroyed||(r.onload=null,r.onerror=null,e.resize(r.width,r.height),e._load=null,e.createBitmap?t(e.process()):t(e))};r.complete&&r.src?i():(r.onload=i,r.onerror=function(t){n(t),e.onError.emit(t)})}))),this._load},e.prototype.process=function(){var t=this,e=this.source;if(null!==this._process)return this._process;if(null!==this.bitmap||!globalThis.createImageBitmap)return Promise.resolve(this);var n=globalThis.createImageBitmap,r=!e.crossOrigin||"anonymous"===e.crossOrigin;return this._process=fetch(e.src,{mode:r?"cors":"no-cors"}).then((function(t){return t.blob()})).then((function(r){return n(r,0,0,e.width,e.height,{premultiplyAlpha:t.alphaMode===i.iw.UNPACK?"premultiply":"none"})})).then((function(e){return t.destroyed?Promise.reject():(t.bitmap=e,t.update(),t._process=null,Promise.resolve(t))})),this._process},e.prototype.upload=function(e,n,r){if("number"===typeof this.alphaMode&&(n.alphaMode=this.alphaMode),!this.createBitmap)return t.prototype.upload.call(this,e,n,r);if(!this.bitmap&&(this.process(),!this.bitmap))return!1;if(t.prototype.upload.call(this,e,n,r,this.bitmap),!this.preserveBitmap){var i=!0,o=n._glTextures;for(var s in o){var a=o[s];if(a!==r&&a.dirtyId!==n.dirtyId){i=!1;break}}i&&(this.bitmap.close&&this.bitmap.close(),this.bitmap=null)}return!0},e.prototype.dispose=function(){this.source.onload=null,this.source.onerror=null,t.prototype.dispose.call(this),this.bitmap&&(this.bitmap.close(),this.bitmap=null),this._process=null,this._load=null},e.test=function(t){return"string"===typeof t||t instanceof HTMLImageElement},e}(E),R=function(t){function e(e,n){var r=this;return n=n||{},r=t.call(this,document.createElement("canvas"))||this,r._width=0,r._height=0,r.svg=e,r.scale=n.scale||1,r._overrideWidth=n.width,r._overrideHeight=n.height,r._resolve=null,r._crossorigin=n.crossorigin,r._load=null,!1!==n.autoLoad&&r.load(),r}return f(e,t),e.prototype.load=function(){var t=this;return this._load||(this._load=new Promise((function(n){if(t._resolve=function(){t.resize(t.source.width,t.source.height),n(t)},e.SVG_XML.test(t.svg.trim())){if(!btoa)throw new Error("Your browser doesn't support base64 conversions.");t.svg="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(t.svg)))}t._loadSvg()}))),this._load},e.prototype._loadSvg=function(){var t=this,e=new Image;E.crossOrigin(e,this.svg,this._crossorigin),e.src=this.svg,e.onerror=function(n){t._resolve&&(e.onerror=null,t.onError.emit(n))},e.onload=function(){if(t._resolve){var n=e.width,r=e.height;if(!n||!r)throw new Error("The SVG image must have width and height defined (in pixels), canvas API needs them.");var i=n*t.scale,s=r*t.scale;(t._overrideWidth||t._overrideHeight)&&(i=t._overrideWidth||t._overrideHeight/r*n,s=t._overrideHeight||t._overrideWidth/n*r),i=Math.round(i),s=Math.round(s);var a=t.source;a.width=i,a.height=s,a._pixiId="canvas_"+(0,o.hQ)(),a.getContext("2d").drawImage(e,0,0,n,r,0,0,i,s),t._resolve(),t._resolve=null}}},e.getSize=function(t){var n=e.SVG_SIZE.exec(t),r={};return n&&(r[n[1]]=Math.round(parseFloat(n[3])),r[n[5]]=Math.round(parseFloat(n[7]))),r},e.prototype.dispose=function(){t.prototype.dispose.call(this),this._resolve=null,this._crossorigin=null},e.test=function(t,n){return"svg"===n||"string"===typeof t&&/^data:image\/svg\+xml(;(charset=utf8|utf8))?;base64/.test(t)||"string"===typeof t&&e.SVG_XML.test(t)},e.SVG_XML=/^(<\?xml[^?]+\?>)?\s*(<!--[^(-->)]*-->)?\s*\<svg/m,e.SVG_SIZE=/<svg[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*>/i,e}(E),A=function(t){function e(n,r){var i=this;if(r=r||{},!(n instanceof HTMLVideoElement)){var o=document.createElement("video");o.setAttribute("preload","auto"),o.setAttribute("webkit-playsinline",""),o.setAttribute("playsinline",""),"string"===typeof n&&(n=[n]);var s=n[0].src||n[0];E.crossOrigin(o,s,r.crossorigin);for(var a=0;a<n.length;++a){var u=document.createElement("source"),l=n[a],c=l.src,h=l.mime;c=c||n[a];var f=c.split("?").shift().toLowerCase(),d=f.slice(f.lastIndexOf(".")+1);h=h||e.MIME_TYPES[d]||"video/"+d,u.src=c,u.type=h,o.appendChild(u)}n=o}return i=t.call(this,n)||this,i.noSubImage=!0,i._autoUpdate=!0,i._isConnectedToTicker=!1,i._updateFPS=r.updateFPS||0,i._msToNextUpdate=0,i.autoPlay=!1!==r.autoPlay,i._load=null,i._resolve=null,i._onCanPlay=i._onCanPlay.bind(i),i._onError=i._onError.bind(i),!1!==r.autoLoad&&i.load(),i}return f(e,t),e.prototype.update=function(e){if(!this.destroyed){var n=a.vB.shared.elapsedMS*this.source.playbackRate;this._msToNextUpdate=Math.floor(this._msToNextUpdate-n),(!this._updateFPS||this._msToNextUpdate<=0)&&(t.prototype.update.call(this),this._msToNextUpdate=this._updateFPS?Math.floor(1e3/this._updateFPS):0)}},e.prototype.load=function(){var t=this;if(this._load)return this._load;var e=this.source;return(e.readyState===e.HAVE_ENOUGH_DATA||e.readyState===e.HAVE_FUTURE_DATA)&&e.width&&e.height&&(e.complete=!0),e.addEventListener("play",this._onPlayStart.bind(this)),e.addEventListener("pause",this._onPlayStop.bind(this)),this._isSourceReady()?this._onCanPlay():(e.addEventListener("canplay",this._onCanPlay),e.addEventListener("canplaythrough",this._onCanPlay),e.addEventListener("error",this._onError,!0)),this._load=new Promise((function(n){t.valid?n(t):(t._resolve=n,e.load())})),this._load},e.prototype._onError=function(t){this.source.removeEventListener("error",this._onError,!0),this.onError.emit(t)},e.prototype._isSourcePlaying=function(){var t=this.source;return t.currentTime>0&&!1===t.paused&&!1===t.ended&&t.readyState>2},e.prototype._isSourceReady=function(){var t=this.source;return 3===t.readyState||4===t.readyState},e.prototype._onPlayStart=function(){this.valid||this._onCanPlay(),this.autoUpdate&&!this._isConnectedToTicker&&(a.vB.shared.add(this.update,this),this._isConnectedToTicker=!0)},e.prototype._onPlayStop=function(){this._isConnectedToTicker&&(a.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1)},e.prototype._onCanPlay=function(){var t=this.source;t.removeEventListener("canplay",this._onCanPlay),t.removeEventListener("canplaythrough",this._onCanPlay);var e=this.valid;this.resize(t.videoWidth,t.videoHeight),!e&&this._resolve&&(this._resolve(this),this._resolve=null),this._isSourcePlaying()?this._onPlayStart():this.autoPlay&&t.play()},e.prototype.dispose=function(){this._isConnectedToTicker&&(a.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1);var e=this.source;e&&(e.removeEventListener("error",this._onError,!0),e.pause(),e.src="",e.load()),t.prototype.dispose.call(this)},Object.defineProperty(e.prototype,"autoUpdate",{get:function(){return this._autoUpdate},set:function(t){t!==this._autoUpdate&&(this._autoUpdate=t,!this._autoUpdate&&this._isConnectedToTicker?(a.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1):this._autoUpdate&&!this._isConnectedToTicker&&this._isSourcePlaying()&&(a.vB.shared.add(this.update,this),this._isConnectedToTicker=!0))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"updateFPS",{get:function(){return this._updateFPS},set:function(t){t!==this._updateFPS&&(this._updateFPS=t)},enumerable:!1,configurable:!0}),e.test=function(t,n){return globalThis.HTMLVideoElement&&t instanceof HTMLVideoElement||e.TYPES.indexOf(n)>-1},e.TYPES=["mp4","m4v","webm","ogg","ogv","h264","avi","mov"],e.MIME_TYPES={ogv:"video/ogg",mov:"video/quicktime",m4v:"video/mp4"},e}(E),O=function(t){function e(e){return t.call(this,e)||this}return f(e,t),e.test=function(t){return!!globalThis.createImageBitmap&&t instanceof ImageBitmap},e}(E);l.push(S,O,T,A,R,v,x,b);var I={__proto__:null,Resource:m,BaseImageResource:E,INSTALLED:l,autoDetectResource:c,AbstractMultiResource:y,ArrayResource:b,BufferResource:v,CanvasResource:T,CubeResource:x,ImageResource:S,SVGResource:R,VideoResource:A,ImageBitmapResource:O},w=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return f(e,t),e.prototype.upload=function(t,e,n){var r=t.gl;r.pixelStorei(r.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e.alphaMode===i.iw.UNPACK);var o=e.realWidth,s=e.realHeight;return n.width===o&&n.height===s?r.texSubImage2D(e.target,0,0,0,o,s,e.format,n.type,this.data):(n.width=o,n.height=s,r.texImage2D(e.target,0,n.internalFormat,o,s,0,e.format,n.type,this.data)),!0},e}(v),C=function(){function t(t,e){this.width=Math.round(t||100),this.height=Math.round(e||100),this.stencil=!1,this.depth=!1,this.dirtyId=0,this.dirtyFormat=0,this.dirtySize=0,this.depthTexture=null,this.colorTextures=[],this.glFramebuffers={},this.disposeRunner=new s.R("disposeFramebuffer"),this.multisample=i.G5.NONE}return Object.defineProperty(t.prototype,"colorTexture",{get:function(){return this.colorTextures[0]},enumerable:!1,configurable:!0}),t.prototype.addColorTexture=function(t,e){return void 0===t&&(t=0),this.colorTextures[t]=e||new _(null,{scaleMode:i.aH.NEAREST,resolution:1,mipmap:i.WB.OFF,width:this.width,height:this.height}),this.dirtyId++,this.dirtyFormat++,this},t.prototype.addDepthTexture=function(t){return this.depthTexture=t||new _(new w(null,{width:this.width,height:this.height}),{scaleMode:i.aH.NEAREST,resolution:1,width:this.width,height:this.height,mipmap:i.WB.OFF,format:i.I2.DEPTH_COMPONENT,type:i.vK.UNSIGNED_SHORT}),this.dirtyId++,this.dirtyFormat++,this},t.prototype.enableDepth=function(){return this.depth=!0,this.dirtyId++,this.dirtyFormat++,this},t.prototype.enableStencil=function(){return this.stencil=!0,this.dirtyId++,this.dirtyFormat++,this},t.prototype.resize=function(t,e){if(t=Math.round(t),e=Math.round(e),t!==this.width||e!==this.height){this.width=t,this.height=e,this.dirtyId++,this.dirtySize++;for(var n=0;n<this.colorTextures.length;n++){var r=this.colorTextures[n],i=r.resolution;r.setSize(t/i,e/i)}if(this.depthTexture){i=this.depthTexture.resolution;this.depthTexture.setSize(t/i,e/i)}}},t.prototype.dispose=function(){this.disposeRunner.emit(this,!1)},t.prototype.destroyDepthTexture=function(){this.depthTexture&&(this.depthTexture.destroy(),this.depthTexture=null,++this.dirtyId,++this.dirtyFormat)},t}(),P=function(t){function e(e){void 0===e&&(e={});var n=this;if("number"===typeof e){var r=arguments[0],o=arguments[1],s=arguments[2],a=arguments[3];e={width:r,height:o,scaleMode:s,resolution:a}}return e.width=e.width||100,e.height=e.height||100,e.multisample=void 0!==e.multisample?e.multisample:i.G5.NONE,n=t.call(this,null,e)||this,n.mipmap=i.WB.OFF,n.valid=!0,n.clearColor=[0,0,0,0],n.framebuffer=new C(n.realWidth,n.realHeight).addColorTexture(0,n),n.framebuffer.multisample=e.multisample,n.maskStack=[],n.filterStack=[{}],n}return f(e,t),e.prototype.resize=function(t,e){this.framebuffer.resize(t*this.resolution,e*this.resolution),this.setRealSize(this.framebuffer.width,this.framebuffer.height)},e.prototype.dispose=function(){this.framebuffer.dispose(),t.prototype.dispose.call(this)},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.framebuffer.destroyDepthTexture(),this.framebuffer=null},e}(_),N=function(){function t(){this.x0=0,this.y0=0,this.x1=1,this.y1=0,this.x2=1,this.y2=1,this.x3=0,this.y3=1,this.uvsFloat32=new Float32Array(8)}return t.prototype.set=function(t,e,n){var r=e.width,i=e.height;if(n){var o=t.width/2/r,s=t.height/2/i,a=t.x/r+o,l=t.y/i+s;n=u.Lv.add(n,u.Lv.NW),this.x0=a+o*u.Lv.uX(n),this.y0=l+s*u.Lv.uY(n),n=u.Lv.add(n,2),this.x1=a+o*u.Lv.uX(n),this.y1=l+s*u.Lv.uY(n),n=u.Lv.add(n,2),this.x2=a+o*u.Lv.uX(n),this.y2=l+s*u.Lv.uY(n),n=u.Lv.add(n,2),this.x3=a+o*u.Lv.uX(n),this.y3=l+s*u.Lv.uY(n)}else this.x0=t.x/r,this.y0=t.y/i,this.x1=(t.x+t.width)/r,this.y1=t.y/i,this.x2=(t.x+t.width)/r,this.y2=(t.y+t.height)/i,this.x3=t.x/r,this.y3=(t.y+t.height)/i;this.uvsFloat32[0]=this.x0,this.uvsFloat32[1]=this.y0,this.uvsFloat32[2]=this.x1,this.uvsFloat32[3]=this.y1,this.uvsFloat32[4]=this.x2,this.uvsFloat32[5]=this.y2,this.uvsFloat32[6]=this.x3,this.uvsFloat32[7]=this.y3},t.prototype.toString=function(){return"[@pixi/core:TextureUvs x0="+this.x0+" y0="+this.y0+" x1="+this.x1+" y1="+this.y1+" x2="+this.x2+" y2="+this.y2+" x3="+this.x3+" y3="+this.y3+"]"},t}(),M=new N,D=function(t){function e(n,r,i,o,s,a){var l=t.call(this)||this;if(l.noFrame=!1,r||(l.noFrame=!0,r=new u.Ae(0,0,1,1)),n instanceof e&&(n=n.baseTexture),l.baseTexture=n,l._frame=r,l.trim=o,l.valid=!1,l._uvs=M,l.uvMatrix=null,l.orig=i||r,l._rotate=Number(s||0),!0===s)l._rotate=2;else if(l._rotate%2!==0)throw new Error("attempt to use diamond-shaped UVs. If you are sure, set rotation manually");return l.defaultAnchor=a?new u.E9(a.x,a.y):new u.E9(0,0),l._updateID=0,l.textureCacheIds=[],n.valid?l.noFrame?n.valid&&l.onBaseTextureUpdated(n):l.frame=r:n.once("loaded",l.onBaseTextureUpdated,l),l.noFrame&&n.on("update",l.onBaseTextureUpdated,l),l}return f(e,t),e.prototype.update=function(){this.baseTexture.resource&&this.baseTexture.resource.update()},e.prototype.onBaseTextureUpdated=function(t){if(this.noFrame){if(!this.baseTexture.valid)return;this._frame.width=t.width,this._frame.height=t.height,this.valid=!0,this.updateUvs()}else this.frame=this._frame;this.emit("update",this)},e.prototype.destroy=function(t){if(this.baseTexture){if(t){var n=this.baseTexture.resource;n&&n.url&&o.kN[n.url]&&e.removeFromCache(n.url),this.baseTexture.destroy()}this.baseTexture.off("loaded",this.onBaseTextureUpdated,this),this.baseTexture.off("update",this.onBaseTextureUpdated,this),this.baseTexture=null}this._frame=null,this._uvs=null,this.trim=null,this.orig=null,this.valid=!1,e.removeFromCache(this),this.textureCacheIds=null},e.prototype.clone=function(){var t=this._frame.clone(),n=this._frame===this.orig?t:this.orig.clone(),r=new e(this.baseTexture,!this.noFrame&&t,n,this.trim&&this.trim.clone(),this.rotate,this.defaultAnchor);return this.noFrame&&(r._frame=t),r},e.prototype.updateUvs=function(){this._uvs===M&&(this._uvs=new N),this._uvs.set(this._frame,this.baseTexture,this.rotate),this._updateID++},e.from=function(t,n,i){void 0===n&&(n={}),void 0===i&&(i=r.X.STRICT_TEXTURE_CACHE);var s="string"===typeof t,a=null;if(s)a=t;else if(t instanceof _){if(!t.cacheId){var u=n&&n.pixiIdPrefix||"pixiid";t.cacheId=u+"-"+(0,o.hQ)(),_.addToCache(t,t.cacheId)}a=t.cacheId}else{if(!t._pixiId){u=n&&n.pixiIdPrefix||"pixiid";t._pixiId=u+"_"+(0,o.hQ)()}a=t._pixiId}var l=o.kN[a];if(s&&i&&!l)throw new Error('The cacheId "'+a+'" does not exist in TextureCache.');return l||t instanceof _?!l&&t instanceof _&&(l=new e(t),e.addToCache(l,a)):(n.resolution||(n.resolution=(0,o.fL)(t)),l=new e(new _(t,n)),l.baseTexture.cacheId=a,_.addToCache(l.baseTexture,a),e.addToCache(l,a)),l},e.fromURL=function(t,n){var r=Object.assign({autoLoad:!1},null===n||void 0===n?void 0:n.resourceOptions),i=e.from(t,Object.assign({resourceOptions:r},n),!1),o=i.baseTexture.resource;return i.baseTexture.valid?Promise.resolve(i):o.load().then((function(){return Promise.resolve(i)}))},e.fromBuffer=function(t,n,r,i){return new e(_.fromBuffer(t,n,r,i))},e.fromLoader=function(t,n,i,s){var a=new _(t,Object.assign({scaleMode:r.X.SCALE_MODE,resolution:(0,o.fL)(n)},s)),u=a.resource;u instanceof S&&(u.url=n);var l=new e(a);return i||(i=n),_.addToCache(l.baseTexture,i),e.addToCache(l,i),i!==n&&(_.addToCache(l.baseTexture,n),e.addToCache(l,n)),l.baseTexture.valid?Promise.resolve(l):new Promise((function(t){l.baseTexture.once("loaded",(function(){return t(l)}))}))},e.addToCache=function(t,e){e&&(-1===t.textureCacheIds.indexOf(e)&&t.textureCacheIds.push(e),o.kN[e]&&console.warn("Texture added to the cache with an id ["+e+"] that already had an entry"),o.kN[e]=t)},e.removeFromCache=function(t){if("string"===typeof t){var e=o.kN[t];if(e){var n=e.textureCacheIds.indexOf(t);return n>-1&&e.textureCacheIds.splice(n,1),delete o.kN[t],e}}else if(t&&t.textureCacheIds){for(var r=0;r<t.textureCacheIds.length;++r)o.kN[t.textureCacheIds[r]]===t&&delete o.kN[t.textureCacheIds[r]];return t.textureCacheIds.length=0,t}return null},Object.defineProperty(e.prototype,"resolution",{get:function(){return this.baseTexture.resolution},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"frame",{get:function(){return this._frame},set:function(t){this._frame=t,this.noFrame=!1;var e=t.x,n=t.y,r=t.width,i=t.height,o=e+r>this.baseTexture.width,s=n+i>this.baseTexture.height;if(o||s){var a=o&&s?"and":"or",u="X: "+e+" + "+r+" = "+(e+r)+" > "+this.baseTexture.width,l="Y: "+n+" + "+i+" = "+(n+i)+" > "+this.baseTexture.height;throw new Error("Texture Error: frame does not fit inside the base Texture dimensions: "+u+" "+a+" "+l)}this.valid=r&&i&&this.baseTexture.valid,this.trim||this.rotate||(this.orig=t),this.valid&&this.updateUvs()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rotate",{get:function(){return this._rotate},set:function(t){this._rotate=t,this.valid&&this.updateUvs()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"width",{get:function(){return this.orig.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.orig.height},enumerable:!1,configurable:!0}),e.prototype.castToBaseTexture=function(){return this.baseTexture},e}(o.vp);function L(){var t=document.createElement("canvas");t.width=16,t.height=16;var e=t.getContext("2d");return e.fillStyle="white",e.fillRect(0,0,16,16),new D(new _(new T(t)))}function B(t){t.destroy=function(){},t.on=function(){},t.once=function(){},t.emit=function(){}}D.EMPTY=new D(new _),B(D.EMPTY),B(D.EMPTY.baseTexture),D.WHITE=L(),B(D.WHITE),B(D.WHITE.baseTexture);var F=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.valid=!0,r.filterFrame=null,r.filterPoolKey=null,r.updateUvs(),r}return f(e,t),Object.defineProperty(e.prototype,"framebuffer",{get:function(){return this.baseTexture.framebuffer},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"multisample",{get:function(){return this.framebuffer.multisample},set:function(t){this.framebuffer.multisample=t},enumerable:!1,configurable:!0}),e.prototype.resize=function(t,e,n){void 0===n&&(n=!0);var r=this.baseTexture.resolution,i=Math.round(t*r)/r,o=Math.round(e*r)/r;this.valid=i>0&&o>0,this._frame.width=this.orig.width=i,this._frame.height=this.orig.height=o,n&&this.baseTexture.resize(i,o),this.updateUvs()},e.prototype.setResolution=function(t){var e=this.baseTexture;e.resolution!==t&&(e.setResolution(t),this.resize(e.width,e.height,!1))},e.create=function(t){for(var n=arguments,r=[],i=1;i<arguments.length;i++)r[i-1]=n[i];return"number"===typeof t&&((0,o.a1)("6.0.0","Arguments (width, height, scaleMode, resolution) have been deprecated."),t={width:t,height:r[0],scaleMode:r[1],resolution:r[2]}),new e(new P(t))},e}(D),U=function(){function t(t){this.texturePool={},this.textureOptions=t||{},this.enableFullScreen=!1,this._pixelsWidth=0,this._pixelsHeight=0}return t.prototype.createTexture=function(t,e,n){void 0===n&&(n=i.G5.NONE);var r=new P(Object.assign({width:t,height:e,resolution:1,multisample:n},this.textureOptions));return new F(r)},t.prototype.getOptimalTexture=function(t,e,n,r){var s;void 0===n&&(n=1),void 0===r&&(r=i.G5.NONE),t=Math.ceil(t*n-1e-6),e=Math.ceil(e*n-1e-6),this.enableFullScreen&&t===this._pixelsWidth&&e===this._pixelsHeight?s=r>1?-r:-1:(t=(0,o.a9)(t),e=(0,o.a9)(e),s=((65535&t)<<16|65535&e)>>>0,r>1&&(s+=4294967296*r)),this.texturePool[s]||(this.texturePool[s]=[]);var a=this.texturePool[s].pop();return a||(a=this.createTexture(t,e,r)),a.filterPoolKey=s,a.setResolution(n),a},t.prototype.getFilterTexture=function(t,e,n){var r=this.getOptimalTexture(t.width,t.height,e||t.resolution,n||i.G5.NONE);return r.filterFrame=t.filterFrame,r},t.prototype.returnTexture=function(t){var e=t.filterPoolKey;t.filterFrame=null,this.texturePool[e].push(t)},t.prototype.returnFilterTexture=function(t){this.returnTexture(t)},t.prototype.clear=function(t){if(t=!1!==t,t)for(var e in this.texturePool){var n=this.texturePool[e];if(n)for(var r=0;r<n.length;r++)n[r].destroy(!0)}this.texturePool={}},t.prototype.setScreenSize=function(t){if(t.width!==this._pixelsWidth||t.height!==this._pixelsHeight){for(var e in this.enableFullScreen=t.width>0&&t.height>0,this.texturePool)if(Number(e)<0){var n=this.texturePool[e];if(n)for(var r=0;r<n.length;r++)n[r].destroy(!0);this.texturePool[e]=[]}this._pixelsWidth=t.width,this._pixelsHeight=t.height}},t.SCREEN_KEY=-1,t}(),G=function(){function t(t,e,n,r,o,s,a){void 0===e&&(e=0),void 0===n&&(n=!1),void 0===r&&(r=i.vK.FLOAT),this.buffer=t,this.size=e,this.normalized=n,this.type=r,this.stride=o,this.start=s,this.instance=a}return t.prototype.destroy=function(){this.buffer=null},t.from=function(e,n,r,i,o){return new t(e,n,r,i,o)},t}(),k=0,X=function(){function t(t,e,n){void 0===e&&(e=!0),void 0===n&&(n=!1),this.data=t||new Float32Array(1),this._glBuffers={},this._updateID=0,this.index=n,this.static=e,this.id=k++,this.disposeRunner=new s.R("disposeBuffer")}return t.prototype.update=function(t){t instanceof Array&&(t=new Float32Array(t)),this.data=t||this.data,this._updateID++},t.prototype.dispose=function(){this.disposeRunner.emit(this,!1)},t.prototype.destroy=function(){this.dispose(),this.data=null},Object.defineProperty(t.prototype,"index",{get:function(){return this.type===i.mr.ELEMENT_ARRAY_BUFFER},set:function(t){this.type=t?i.mr.ELEMENT_ARRAY_BUFFER:i.mr.ARRAY_BUFFER},enumerable:!1,configurable:!0}),t.from=function(e){return e instanceof Array&&(e=new Float32Array(e)),new t(e)},t}(),H={Float32Array:Float32Array,Uint32Array:Uint32Array,Int32Array:Int32Array,Uint8Array:Uint8Array};function j(t,e){for(var n=0,r=0,i={},s=0;s<t.length;s++)r+=e[s],n+=t[s].length;var a=new ArrayBuffer(4*n),u=null,l=0;for(s=0;s<t.length;s++){var c=e[s],h=t[s],f=(0,o.u7)(h);i[f]||(i[f]=new H[f](a)),u=i[f];for(var d=0;d<h.length;d++){var p=(d/c|0)*r+l,m=d%c;u[p+m]=h[d]}l+=c}return new Float32Array(a)}var V={5126:4,5123:2,5121:1},Y=0,W={Float32Array:Float32Array,Uint32Array:Uint32Array,Int32Array:Int32Array,Uint8Array:Uint8Array,Uint16Array:Uint16Array},z=function(){function t(t,e){void 0===t&&(t=[]),void 0===e&&(e={}),this.buffers=t,this.indexBuffer=null,this.attributes=e,this.glVertexArrayObjects={},this.id=Y++,this.instanced=!1,this.instanceCount=1,this.disposeRunner=new s.R("disposeGeometry"),this.refCount=0}return t.prototype.addAttribute=function(t,e,n,r,i,o,s,a){if(void 0===n&&(n=0),void 0===r&&(r=!1),void 0===a&&(a=!1),!e)throw new Error("You must pass a buffer when creating an attribute");e instanceof X||(e instanceof Array&&(e=new Float32Array(e)),e=new X(e));var u=t.split("|");if(u.length>1){for(var l=0;l<u.length;l++)this.addAttribute(u[l],e,n,r,i);return this}var c=this.buffers.indexOf(e);return-1===c&&(this.buffers.push(e),c=this.buffers.length-1),this.attributes[t]=new G(c,n,r,i,o,s,a),this.instanced=this.instanced||a,this},t.prototype.getAttribute=function(t){return this.attributes[t]},t.prototype.getBuffer=function(t){return this.buffers[this.getAttribute(t).buffer]},t.prototype.addIndex=function(t){return t instanceof X||(t instanceof Array&&(t=new Uint16Array(t)),t=new X(t)),t.type=i.mr.ELEMENT_ARRAY_BUFFER,this.indexBuffer=t,-1===this.buffers.indexOf(t)&&this.buffers.push(t),this},t.prototype.getIndex=function(){return this.indexBuffer},t.prototype.interleave=function(){if(1===this.buffers.length||2===this.buffers.length&&this.indexBuffer)return this;var t,e=[],n=[],r=new X;for(t in this.attributes){var i=this.attributes[t],o=this.buffers[i.buffer];e.push(o.data),n.push(i.size*V[i.type]/4),i.buffer=0}for(r.data=j(e,n),t=0;t<this.buffers.length;t++)this.buffers[t]!==this.indexBuffer&&this.buffers[t].destroy();return this.buffers=[r],this.indexBuffer&&this.buffers.push(this.indexBuffer),this},t.prototype.getSize=function(){for(var t in this.attributes){var e=this.attributes[t],n=this.buffers[e.buffer];return n.data.length/(e.stride/4||e.size)}return 0},t.prototype.dispose=function(){this.disposeRunner.emit(this,!1)},t.prototype.destroy=function(){this.dispose(),this.buffers=null,this.indexBuffer=null,this.attributes=null},t.prototype.clone=function(){for(var e=new t,n=0;n<this.buffers.length;n++)e.buffers[n]=new X(this.buffers[n].data.slice(0));for(var n in this.attributes){var r=this.attributes[n];e.attributes[n]=new G(r.buffer,r.size,r.normalized,r.type,r.stride,r.start,r.instance)}return this.indexBuffer&&(e.indexBuffer=e.buffers[this.buffers.indexOf(this.indexBuffer)],e.indexBuffer.type=i.mr.ELEMENT_ARRAY_BUFFER),e},t.merge=function(e){for(var n,r=new t,s=[],a=[],u=[],l=0;l<e.length;l++){n=e[l];for(var c=0;c<n.buffers.length;c++)a[c]=a[c]||0,a[c]+=n.buffers[c].data.length,u[c]=0}for(l=0;l<n.buffers.length;l++)s[l]=new(W[(0,o.u7)(n.buffers[l].data)])(a[l]),r.buffers[l]=new X(s[l]);for(l=0;l<e.length;l++){n=e[l];for(c=0;c<n.buffers.length;c++)s[c].set(n.buffers[c].data,u[c]),u[c]+=n.buffers[c].data.length}if(r.attributes=n.attributes,n.indexBuffer){r.indexBuffer=r.buffers[n.buffers.indexOf(n.indexBuffer)],r.indexBuffer.type=i.mr.ELEMENT_ARRAY_BUFFER;var h=0,f=0,d=0,p=0;for(l=0;l<n.buffers.length;l++)if(n.buffers[l]!==n.indexBuffer){p=l;break}for(var l in n.attributes){var m=n.attributes[l];(0|m.buffer)===p&&(f+=m.size*V[m.type]/4)}for(l=0;l<e.length;l++){var v=e[l].indexBuffer.data;for(c=0;c<v.length;c++)r.indexBuffer.data[c+d]+=h;h+=e[l].buffers[p].data.length/f,d+=v.length}}return r},t}(),$=function(t){function e(){var e=t.call(this)||this;return e.addAttribute("aVertexPosition",new Float32Array([0,0,1,0,1,1,0,1])).addIndex([0,1,3,2]),e}return f(e,t),e}(z),q=function(t){function e(){var e=t.call(this)||this;return e.vertices=new Float32Array([-1,-1,1,-1,1,1,-1,1]),e.uvs=new Float32Array([0,0,1,0,1,1,0,1]),e.vertexBuffer=new X(e.vertices),e.uvBuffer=new X(e.uvs),e.addAttribute("aVertexPosition",e.vertexBuffer).addAttribute("aTextureCoord",e.uvBuffer).addIndex([0,1,2,0,2,3]),e}return f(e,t),e.prototype.map=function(t,e){var n=0,r=0;return this.uvs[0]=n,this.uvs[1]=r,this.uvs[2]=n+e.width/t.width,this.uvs[3]=r,this.uvs[4]=n+e.width/t.width,this.uvs[5]=r+e.height/t.height,this.uvs[6]=n,this.uvs[7]=r+e.height/t.height,n=e.x,r=e.y,this.vertices[0]=n,this.vertices[1]=r,this.vertices[2]=n+e.width,this.vertices[3]=r,this.vertices[4]=n+e.width,this.vertices[5]=r+e.height,this.vertices[6]=n,this.vertices[7]=r+e.height,this.invalidate(),this},e.prototype.invalidate=function(){return this.vertexBuffer._updateID++,this.uvBuffer._updateID++,this},e}(z),K=0,Z=function(){function t(t,e,n){this.group=!0,this.syncUniforms={},this.dirtyId=0,this.id=K++,this.static=!!e,this.ubo=!!n,t instanceof X?(this.buffer=t,this.buffer.type=i.mr.UNIFORM_BUFFER,this.autoManage=!1,this.ubo=!0):(this.uniforms=t,this.ubo&&(this.buffer=new X(new Float32Array(1)),this.buffer.type=i.mr.UNIFORM_BUFFER,this.autoManage=!0))}return t.prototype.update=function(){this.dirtyId++,!this.autoManage&&this.buffer&&this.buffer.update()},t.prototype.add=function(e,n,r){if(this.ubo)throw new Error("[UniformGroup] uniform groups in ubo mode cannot be modified, or have uniform groups nested in them");this.uniforms[e]=new t(n,r)},t.from=function(e,n,r){return new t(e,n,r)},t.uboFrom=function(e,n){return new t(e,null===n||void 0===n||n,!0)},t}(),J=function(){function t(){this.renderTexture=null,this.target=null,this.legacy=!1,this.resolution=1,this.multisample=i.G5.NONE,this.sourceFrame=new u.Ae,this.destinationFrame=new u.Ae,this.bindingSourceFrame=new u.Ae,this.bindingDestinationFrame=new u.Ae,this.filters=[],this.transform=null}return t.prototype.clear=function(){this.target=null,this.filters=null,this.renderTexture=null},t}(),Q=[new u.E9,new u.E9,new u.E9,new u.E9],tt=new u.y3,et=function(){function t(t){this.renderer=t,this.defaultFilterStack=[{}],this.texturePool=new U,this.texturePool.setScreenSize(t.view),this.statePool=[],this.quad=new $,this.quadUv=new q,this.tempRect=new u.Ae,this.activeState={},this.globalUniforms=new Z({outputFrame:new u.Ae,inputSize:new Float32Array(4),inputPixel:new Float32Array(4),inputClamp:new Float32Array(4),resolution:1,filterArea:new Float32Array(4),filterClamp:new Float32Array(4)},!0),this.forceClear=!1,this.useMaxPadding=!1}return t.prototype.push=function(t,e){for(var n,r,i=this.renderer,o=this.defaultFilterStack,s=this.statePool.pop()||new J,a=this.renderer.renderTexture,u=e[0].resolution,l=e[0].multisample,c=e[0].padding,h=e[0].autoFit,f=null===(n=e[0].legacy)||void 0===n||n,d=1;d<e.length;d++){var p=e[d];u=Math.min(u,p.resolution),l=Math.min(l,p.multisample),c=this.useMaxPadding?Math.max(c,p.padding):c+p.padding,h=h&&p.autoFit,f=f||null===(r=p.legacy)||void 0===r||r}if(1===o.length&&(this.defaultFilterStack[0].renderTexture=a.current),o.push(s),s.resolution=u,s.multisample=l,s.legacy=f,s.target=t,s.sourceFrame.copyFrom(t.filterArea||t.getBounds(!0)),s.sourceFrame.pad(c),h){var m=this.tempRect.copyFrom(a.sourceFrame);i.projection.transform&&this.transformAABB(tt.copyFrom(i.projection.transform).invert(),m),s.sourceFrame.fit(m)}this.roundFrame(s.sourceFrame,a.current?a.current.resolution:i.resolution,a.sourceFrame,a.destinationFrame,i.projection.transform),s.renderTexture=this.getOptimalFilterTexture(s.sourceFrame.width,s.sourceFrame.height,u,l),s.filters=e,s.destinationFrame.width=s.renderTexture.width,s.destinationFrame.height=s.renderTexture.height;var v=this.tempRect;v.x=0,v.y=0,v.width=s.sourceFrame.width,v.height=s.sourceFrame.height,s.renderTexture.filterFrame=s.sourceFrame,s.bindingSourceFrame.copyFrom(a.sourceFrame),s.bindingDestinationFrame.copyFrom(a.destinationFrame),s.transform=i.projection.transform,i.projection.transform=null,a.bind(s.renderTexture,s.sourceFrame,v),i.framebuffer.clear(0,0,0,0)},t.prototype.pop=function(){var t=this.defaultFilterStack,e=t.pop(),n=e.filters;this.activeState=e;var r=this.globalUniforms.uniforms;r.outputFrame=e.sourceFrame,r.resolution=e.resolution;var o=r.inputSize,s=r.inputPixel,a=r.inputClamp;if(o[0]=e.destinationFrame.width,o[1]=e.destinationFrame.height,o[2]=1/o[0],o[3]=1/o[1],s[0]=Math.round(o[0]*e.resolution),s[1]=Math.round(o[1]*e.resolution),s[2]=1/s[0],s[3]=1/s[1],a[0]=.5*s[2],a[1]=.5*s[3],a[2]=e.sourceFrame.width*o[2]-.5*s[2],a[3]=e.sourceFrame.height*o[3]-.5*s[3],e.legacy){var u=r.filterArea;u[0]=e.destinationFrame.width,u[1]=e.destinationFrame.height,u[2]=e.sourceFrame.x,u[3]=e.sourceFrame.y,r.filterClamp=r.inputClamp}this.globalUniforms.update();var l=t[t.length-1];if(this.renderer.framebuffer.blit(),1===n.length)n[0].apply(this,e.renderTexture,l.renderTexture,i.yl.BLEND,e),this.returnFilterTexture(e.renderTexture);else{var c=e.renderTexture,h=this.getOptimalFilterTexture(c.width,c.height,e.resolution);h.filterFrame=c.filterFrame;var f=0;for(f=0;f<n.length-1;++f){1===f&&e.multisample>1&&(h=this.getOptimalFilterTexture(c.width,c.height,e.resolution),h.filterFrame=c.filterFrame),n[f].apply(this,c,h,i.yl.CLEAR,e);var d=c;c=h,h=d}n[f].apply(this,c,l.renderTexture,i.yl.BLEND,e),f>1&&e.multisample>1&&this.returnFilterTexture(e.renderTexture),this.returnFilterTexture(c),this.returnFilterTexture(h)}e.clear(),this.statePool.push(e)},t.prototype.bindAndClear=function(t,e){void 0===e&&(e=i.yl.CLEAR);var n=this.renderer,r=n.renderTexture,o=n.state;if(t===this.defaultFilterStack[this.defaultFilterStack.length-1].renderTexture?this.renderer.projection.transform=this.activeState.transform:this.renderer.projection.transform=null,t&&t.filterFrame){var s=this.tempRect;s.x=0,s.y=0,s.width=t.filterFrame.width,s.height=t.filterFrame.height,r.bind(t,t.filterFrame,s)}else t!==this.defaultFilterStack[this.defaultFilterStack.length-1].renderTexture?r.bind(t):this.renderer.renderTexture.bind(t,this.activeState.bindingSourceFrame,this.activeState.bindingDestinationFrame);var a=1&o.stateId||this.forceClear;(e===i.yl.CLEAR||e===i.yl.BLIT&&a)&&this.renderer.framebuffer.clear(0,0,0,0)},t.prototype.applyFilter=function(t,e,n,r){var o=this.renderer;o.state.set(t.state),this.bindAndClear(n,r),t.uniforms.uSampler=e,t.uniforms.filterGlobals=this.globalUniforms,o.shader.bind(t),t.legacy=!!t.program.attributeData.aTextureCoord,t.legacy?(this.quadUv.map(e._frame,e.filterFrame),o.geometry.bind(this.quadUv),o.geometry.draw(i.lg.TRIANGLES)):(o.geometry.bind(this.quad),o.geometry.draw(i.lg.TRIANGLE_STRIP))},t.prototype.calculateSpriteMatrix=function(t,e){var n=this.activeState,r=n.sourceFrame,i=n.destinationFrame,o=e._texture.orig,s=t.set(i.width,0,0,i.height,r.x,r.y),a=e.worldTransform.copyTo(u.y3.TEMP_MATRIX);return a.invert(),s.prepend(a),s.scale(1/o.width,1/o.height),s.translate(e.anchor.x,e.anchor.y),s},t.prototype.destroy=function(){this.renderer=null,this.texturePool.clear(!1)},t.prototype.getOptimalFilterTexture=function(t,e,n,r){return void 0===n&&(n=1),void 0===r&&(r=i.G5.NONE),this.texturePool.getOptimalTexture(t,e,n,r)},t.prototype.getFilterTexture=function(t,e,n){if("number"===typeof t){var r=t;t=e,e=r}t=t||this.activeState.renderTexture;var o=this.texturePool.getOptimalTexture(t.width,t.height,e||t.resolution,n||i.G5.NONE);return o.filterFrame=t.filterFrame,o},t.prototype.returnFilterTexture=function(t){this.texturePool.returnTexture(t)},t.prototype.emptyPool=function(){this.texturePool.clear(!0)},t.prototype.resize=function(){this.texturePool.setScreenSize(this.renderer.view)},t.prototype.transformAABB=function(t,e){var n=Q[0],r=Q[1],i=Q[2],o=Q[3];n.set(e.left,e.top),r.set(e.left,e.bottom),i.set(e.right,e.top),o.set(e.right,e.bottom),t.apply(n,n),t.apply(r,r),t.apply(i,i),t.apply(o,o);var s=Math.min(n.x,r.x,i.x,o.x),a=Math.min(n.y,r.y,i.y,o.y),u=Math.max(n.x,r.x,i.x,o.x),l=Math.max(n.y,r.y,i.y,o.y);e.x=s,e.y=a,e.width=u-s,e.height=l-a},t.prototype.roundFrame=function(t,e,n,r,i){if(!(t.width<=0||t.height<=0||n.width<=0||n.height<=0)){if(i){var o=i.a,s=i.b,a=i.c,u=i.d;if((Math.abs(s)>1e-4||Math.abs(a)>1e-4)&&(Math.abs(o)>1e-4||Math.abs(u)>1e-4))return}i=i?tt.copyFrom(i):tt.identity(),i.translate(-n.x,-n.y).scale(r.width/n.width,r.height/n.height).translate(r.x,r.y),this.transformAABB(i,t),t.ceil(e),this.transformAABB(i.invert(),t)}},t}(),nt=function(){function t(t){this.renderer=t}return t.prototype.flush=function(){},t.prototype.destroy=function(){this.renderer=null},t.prototype.start=function(){},t.prototype.stop=function(){this.flush()},t.prototype.render=function(t){},t}(),rt=function(){function t(t){this.renderer=t,this.emptyRenderer=new nt(t),this.currentRenderer=this.emptyRenderer}return t.prototype.setObjectRenderer=function(t){this.currentRenderer!==t&&(this.currentRenderer.stop(),this.currentRenderer=t,this.currentRenderer.start())},t.prototype.flush=function(){this.setObjectRenderer(this.emptyRenderer)},t.prototype.reset=function(){this.setObjectRenderer(this.emptyRenderer)},t.prototype.copyBoundTextures=function(t,e){for(var n=this.renderer.texture.boundTextures,r=e-1;r>=0;--r)t[r]=n[r]||null,t[r]&&(t[r]._batchLocation=r)},t.prototype.boundArray=function(t,e,n,r){for(var i=t.elements,o=t.ids,s=t.count,a=0,u=0;u<s;u++){var l=i[u],c=l._batchLocation;if(c>=0&&c<r&&e[c]===l)o[u]=c;else while(a<r){var h=e[a];if(!h||h._batchEnabled!==n||h._batchLocation!==a){o[u]=a,l._batchLocation=a,e[a]=l;break}a++}}},t.prototype.destroy=function(){this.renderer=null},t}(),it=0,ot=function(){function t(t){this.renderer=t,this.webGLVersion=1,this.extensions={},this.supports={uint32Indices:!1},this.handleContextLost=this.handleContextLost.bind(this),this.handleContextRestored=this.handleContextRestored.bind(this),t.view.addEventListener("webglcontextlost",this.handleContextLost,!1),t.view.addEventListener("webglcontextrestored",this.handleContextRestored,!1)}return Object.defineProperty(t.prototype,"isLost",{get:function(){return!this.gl||this.gl.isContextLost()},enumerable:!1,configurable:!0}),t.prototype.contextChange=function(t){this.gl=t,this.renderer.gl=t,this.renderer.CONTEXT_UID=it++,t.isContextLost()&&t.getExtension("WEBGL_lose_context")&&t.getExtension("WEBGL_lose_context").restoreContext()},t.prototype.initFromContext=function(t){this.gl=t,this.validateContext(t),this.renderer.gl=t,this.renderer.CONTEXT_UID=it++,this.renderer.runners.contextChange.emit(t)},t.prototype.initFromOptions=function(t){var e=this.createContext(this.renderer.view,t);this.initFromContext(e)},t.prototype.createContext=function(t,e){var n;if(r.X.PREFER_ENV>=i.Vi.WEBGL2&&(n=t.getContext("webgl2",e)),n)this.webGLVersion=2;else if(this.webGLVersion=1,n=t.getContext("webgl",e)||t.getContext("experimental-webgl",e),!n)throw new Error("This browser does not support WebGL. Try using the canvas renderer");return this.gl=n,this.getExtensions(),this.gl},t.prototype.getExtensions=function(){var t=this.gl,e={anisotropicFiltering:t.getExtension("EXT_texture_filter_anisotropic"),floatTextureLinear:t.getExtension("OES_texture_float_linear"),s3tc:t.getExtension("WEBGL_compressed_texture_s3tc"),s3tc_sRGB:t.getExtension("WEBGL_compressed_texture_s3tc_srgb"),etc:t.getExtension("WEBGL_compressed_texture_etc"),etc1:t.getExtension("WEBGL_compressed_texture_etc1"),pvrtc:t.getExtension("WEBGL_compressed_texture_pvrtc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc"),atc:t.getExtension("WEBGL_compressed_texture_atc"),astc:t.getExtension("WEBGL_compressed_texture_astc")};1===this.webGLVersion?Object.assign(this.extensions,e,{drawBuffers:t.getExtension("WEBGL_draw_buffers"),depthTexture:t.getExtension("WEBGL_depth_texture"),loseContext:t.getExtension("WEBGL_lose_context"),vertexArrayObject:t.getExtension("OES_vertex_array_object")||t.getExtension("MOZ_OES_vertex_array_object")||t.getExtension("WEBKIT_OES_vertex_array_object"),uint32ElementIndex:t.getExtension("OES_element_index_uint"),floatTexture:t.getExtension("OES_texture_float"),floatTextureLinear:t.getExtension("OES_texture_float_linear"),textureHalfFloat:t.getExtension("OES_texture_half_float"),textureHalfFloatLinear:t.getExtension("OES_texture_half_float_linear")}):2===this.webGLVersion&&Object.assign(this.extensions,e,{colorBufferFloat:t.getExtension("EXT_color_buffer_float")})},t.prototype.handleContextLost=function(t){t.preventDefault()},t.prototype.handleContextRestored=function(){this.renderer.runners.contextChange.emit(this.gl)},t.prototype.destroy=function(){var t=this.renderer.view;this.renderer=null,t.removeEventListener("webglcontextlost",this.handleContextLost),t.removeEventListener("webglcontextrestored",this.handleContextRestored),this.gl.useProgram(null),this.extensions.loseContext&&this.extensions.loseContext.loseContext()},t.prototype.postrender=function(){this.renderer.renderingToScreen&&this.gl.flush()},t.prototype.validateContext=function(t){var e=t.getContextAttributes(),n="WebGL2RenderingContext"in globalThis&&t instanceof globalThis.WebGL2RenderingContext;n&&(this.webGLVersion=2),e.stencil||console.warn("Provided WebGL context does not have a stencil buffer, masks may not render correctly");var r=n||!!t.getExtension("OES_element_index_uint");this.supports.uint32Indices=r,r||console.warn("Provided WebGL context does not support 32 index buffer, complex graphics may not render correctly")},t}(),st=function(){function t(t){this.framebuffer=t,this.stencil=null,this.dirtyId=-1,this.dirtyFormat=-1,this.dirtySize=-1,this.multisample=i.G5.NONE,this.msaaBuffer=null,this.blitFramebuffer=null,this.mipLevel=0}return t}(),at=new u.Ae,ut=function(){function t(t){this.renderer=t,this.managedFramebuffers=[],this.unknownFramebuffer=new C(10,10),this.msaaSamples=null}return t.prototype.contextChange=function(){var t=this.gl=this.renderer.gl;if(this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.current=this.unknownFramebuffer,this.viewport=new u.Ae,this.hasMRT=!0,this.writeDepthTexture=!0,this.disposeAll(!0),1===this.renderer.context.webGLVersion){var e=this.renderer.context.extensions.drawBuffers,n=this.renderer.context.extensions.depthTexture;r.X.PREFER_ENV===i.Vi.WEBGL_LEGACY&&(e=null,n=null),e?t.drawBuffers=function(t){return e.drawBuffersWEBGL(t)}:(this.hasMRT=!1,t.drawBuffers=function(){}),n||(this.writeDepthTexture=!1)}else this.msaaSamples=t.getInternalformatParameter(t.RENDERBUFFER,t.RGBA8,t.SAMPLES)},t.prototype.bind=function(t,e,n){void 0===n&&(n=0);var r=this.gl;if(t){var i=t.glFramebuffers[this.CONTEXT_UID]||this.initFramebuffer(t);this.current!==t&&(this.current=t,r.bindFramebuffer(r.FRAMEBUFFER,i.framebuffer)),i.mipLevel!==n&&(t.dirtyId++,t.dirtyFormat++,i.mipLevel=n),i.dirtyId!==t.dirtyId&&(i.dirtyId=t.dirtyId,i.dirtyFormat!==t.dirtyFormat?(i.dirtyFormat=t.dirtyFormat,i.dirtySize=t.dirtySize,this.updateFramebuffer(t,n)):i.dirtySize!==t.dirtySize&&(i.dirtySize=t.dirtySize,this.resizeFramebuffer(t)));for(var o=0;o<t.colorTextures.length;o++){var s=t.colorTextures[o];this.renderer.texture.unbind(s.parentTextureArray||s)}if(t.depthTexture&&this.renderer.texture.unbind(t.depthTexture),e){var a=e.width>>n,u=e.height>>n,l=a/e.width;this.setViewport(e.x*l,e.y*l,a,u)}else{a=t.width>>n,u=t.height>>n;this.setViewport(0,0,a,u)}}else this.current&&(this.current=null,r.bindFramebuffer(r.FRAMEBUFFER,null)),e?this.setViewport(e.x,e.y,e.width,e.height):this.setViewport(0,0,this.renderer.width,this.renderer.height)},t.prototype.setViewport=function(t,e,n,r){var i=this.viewport;t=Math.round(t),e=Math.round(e),n=Math.round(n),r=Math.round(r),i.width===n&&i.height===r&&i.x===t&&i.y===e||(i.x=t,i.y=e,i.width=n,i.height=r,this.gl.viewport(t,e,n,r))},Object.defineProperty(t.prototype,"size",{get:function(){return this.current?{x:0,y:0,width:this.current.width,height:this.current.height}:{x:0,y:0,width:this.renderer.width,height:this.renderer.height}},enumerable:!1,configurable:!0}),t.prototype.clear=function(t,e,n,r,o){void 0===o&&(o=i.V0.COLOR|i.V0.DEPTH);var s=this.gl;s.clearColor(t,e,n,r),s.clear(o)},t.prototype.initFramebuffer=function(t){var e=this.gl,n=new st(e.createFramebuffer());return n.multisample=this.detectSamples(t.multisample),t.glFramebuffers[this.CONTEXT_UID]=n,this.managedFramebuffers.push(t),t.disposeRunner.add(this),n},t.prototype.resizeFramebuffer=function(t){var e=this.gl,n=t.glFramebuffers[this.CONTEXT_UID];n.msaaBuffer&&(e.bindRenderbuffer(e.RENDERBUFFER,n.msaaBuffer),e.renderbufferStorageMultisample(e.RENDERBUFFER,n.multisample,e.RGBA8,t.width,t.height)),n.stencil&&(e.bindRenderbuffer(e.RENDERBUFFER,n.stencil),n.msaaBuffer?e.renderbufferStorageMultisample(e.RENDERBUFFER,n.multisample,e.DEPTH24_STENCIL8,t.width,t.height):e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_STENCIL,t.width,t.height));var r=t.colorTextures,i=r.length;e.drawBuffers||(i=Math.min(i,1));for(var o=0;o<i;o++){var s=r[o],a=s.parentTextureArray||s;this.renderer.texture.bind(a,0)}t.depthTexture&&this.writeDepthTexture&&this.renderer.texture.bind(t.depthTexture,0)},t.prototype.updateFramebuffer=function(t,e){var n=this.gl,r=t.glFramebuffers[this.CONTEXT_UID],i=t.colorTextures,o=i.length;n.drawBuffers||(o=Math.min(o,1)),r.multisample>1&&this.canMultisampleFramebuffer(t)?(r.msaaBuffer=r.msaaBuffer||n.createRenderbuffer(),n.bindRenderbuffer(n.RENDERBUFFER,r.msaaBuffer),n.renderbufferStorageMultisample(n.RENDERBUFFER,r.multisample,n.RGBA8,t.width,t.height),n.framebufferRenderbuffer(n.FRAMEBUFFER,n.COLOR_ATTACHMENT0,n.RENDERBUFFER,r.msaaBuffer)):r.msaaBuffer&&(n.deleteRenderbuffer(r.msaaBuffer),r.msaaBuffer=null,r.blitFramebuffer&&(r.blitFramebuffer.dispose(),r.blitFramebuffer=null));for(var s=[],a=0;a<o;a++){var u=i[a],l=u.parentTextureArray||u;this.renderer.texture.bind(l,0),0===a&&r.msaaBuffer||(n.framebufferTexture2D(n.FRAMEBUFFER,n.COLOR_ATTACHMENT0+a,u.target,l._glTextures[this.CONTEXT_UID].texture,e),s.push(n.COLOR_ATTACHMENT0+a))}if(s.length>1&&n.drawBuffers(s),t.depthTexture){var c=this.writeDepthTexture;if(c){var h=t.depthTexture;this.renderer.texture.bind(h,0),n.framebufferTexture2D(n.FRAMEBUFFER,n.DEPTH_ATTACHMENT,n.TEXTURE_2D,h._glTextures[this.CONTEXT_UID].texture,e)}}!t.stencil&&!t.depth||t.depthTexture&&this.writeDepthTexture?r.stencil&&(n.deleteRenderbuffer(r.stencil),r.stencil=null):(r.stencil=r.stencil||n.createRenderbuffer(),n.bindRenderbuffer(n.RENDERBUFFER,r.stencil),r.msaaBuffer?n.renderbufferStorageMultisample(n.RENDERBUFFER,r.multisample,n.DEPTH24_STENCIL8,t.width,t.height):n.renderbufferStorage(n.RENDERBUFFER,n.DEPTH_STENCIL,t.width,t.height),n.framebufferRenderbuffer(n.FRAMEBUFFER,n.DEPTH_STENCIL_ATTACHMENT,n.RENDERBUFFER,r.stencil))},t.prototype.canMultisampleFramebuffer=function(t){return 1!==this.renderer.context.webGLVersion&&t.colorTextures.length<=1&&!t.depthTexture},t.prototype.detectSamples=function(t){var e=this.msaaSamples,n=i.G5.NONE;if(t<=1||null===e)return n;for(var r=0;r<e.length;r++)if(e[r]<=t){n=e[r];break}return 1===n&&(n=i.G5.NONE),n},t.prototype.blit=function(t,e,n){var r=this,i=r.current,o=r.renderer,s=r.gl,a=r.CONTEXT_UID;if(2===o.context.webGLVersion&&i){var u=i.glFramebuffers[a];if(u){if(!t){if(!u.msaaBuffer)return;var l=i.colorTextures[0];if(!l)return;u.blitFramebuffer||(u.blitFramebuffer=new C(i.width,i.height),u.blitFramebuffer.addColorTexture(0,l)),t=u.blitFramebuffer,t.colorTextures[0]!==l&&(t.colorTextures[0]=l,t.dirtyId++,t.dirtyFormat++),t.width===i.width&&t.height===i.height||(t.width=i.width,t.height=i.height,t.dirtyId++,t.dirtySize++)}e||(e=at,e.width=i.width,e.height=i.height),n||(n=e);var c=e.width===n.width&&e.height===n.height;this.bind(t),s.bindFramebuffer(s.READ_FRAMEBUFFER,u.framebuffer),s.blitFramebuffer(e.left,e.top,e.right,e.bottom,n.left,n.top,n.right,n.bottom,s.COLOR_BUFFER_BIT,c?s.NEAREST:s.LINEAR)}}},t.prototype.disposeFramebuffer=function(t,e){var n=t.glFramebuffers[this.CONTEXT_UID],r=this.gl;if(n){delete t.glFramebuffers[this.CONTEXT_UID];var i=this.managedFramebuffers.indexOf(t);i>=0&&this.managedFramebuffers.splice(i,1),t.disposeRunner.remove(this),e||(r.deleteFramebuffer(n.framebuffer),n.msaaBuffer&&r.deleteRenderbuffer(n.msaaBuffer),n.stencil&&r.deleteRenderbuffer(n.stencil)),n.blitFramebuffer&&n.blitFramebuffer.dispose()}},t.prototype.disposeAll=function(t){var e=this.managedFramebuffers;this.managedFramebuffers=[];for(var n=0;n<e.length;n++)this.disposeFramebuffer(e[n],t)},t.prototype.forceStencil=function(){var t=this.current;if(t){var e=t.glFramebuffers[this.CONTEXT_UID];if(e&&!e.stencil){t.stencil=!0;var n=t.width,r=t.height,i=this.gl,o=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,o),e.msaaBuffer?i.renderbufferStorageMultisample(i.RENDERBUFFER,e.multisample,i.DEPTH24_STENCIL8,n,r):i.renderbufferStorage(i.RENDERBUFFER,i.DEPTH_STENCIL,n,r),e.stencil=o,i.framebufferRenderbuffer(i.FRAMEBUFFER,i.DEPTH_STENCIL_ATTACHMENT,i.RENDERBUFFER,o)}}},t.prototype.reset=function(){this.current=this.unknownFramebuffer,this.viewport=new u.Ae},t.prototype.destroy=function(){this.renderer=null},t}(),lt={5126:4,5123:2,5121:1},ct=function(){function t(t){this.renderer=t,this._activeGeometry=null,this._activeVao=null,this.hasVao=!0,this.hasInstance=!0,this.canUseUInt32ElementIndex=!1,this.managedGeometries={}}return t.prototype.contextChange=function(){this.disposeAll(!0);var t=this.gl=this.renderer.gl,e=this.renderer.context;if(this.CONTEXT_UID=this.renderer.CONTEXT_UID,2!==e.webGLVersion){var n=this.renderer.context.extensions.vertexArrayObject;r.X.PREFER_ENV===i.Vi.WEBGL_LEGACY&&(n=null),n?(t.createVertexArray=function(){return n.createVertexArrayOES()},t.bindVertexArray=function(t){return n.bindVertexArrayOES(t)},t.deleteVertexArray=function(t){return n.deleteVertexArrayOES(t)}):(this.hasVao=!1,t.createVertexArray=function(){return null},t.bindVertexArray=function(){return null},t.deleteVertexArray=function(){return null})}if(2!==e.webGLVersion){var o=t.getExtension("ANGLE_instanced_arrays");o?(t.vertexAttribDivisor=function(t,e){return o.vertexAttribDivisorANGLE(t,e)},t.drawElementsInstanced=function(t,e,n,r,i){return o.drawElementsInstancedANGLE(t,e,n,r,i)},t.drawArraysInstanced=function(t,e,n,r){return o.drawArraysInstancedANGLE(t,e,n,r)}):this.hasInstance=!1}this.canUseUInt32ElementIndex=2===e.webGLVersion||!!e.extensions.uint32ElementIndex},t.prototype.bind=function(t,e){e=e||this.renderer.shader.shader;var n=this.gl,r=t.glVertexArrayObjects[this.CONTEXT_UID],i=!1;r||(this.managedGeometries[t.id]=t,t.disposeRunner.add(this),t.glVertexArrayObjects[this.CONTEXT_UID]=r={},i=!0);var o=r[e.program.id]||this.initGeometryVao(t,e,i);this._activeGeometry=t,this._activeVao!==o&&(this._activeVao=o,this.hasVao?n.bindVertexArray(o):this.activateVao(t,e.program)),this.updateBuffers()},t.prototype.reset=function(){this.unbind()},t.prototype.updateBuffers=function(){for(var t=this._activeGeometry,e=this.renderer.buffer,n=0;n<t.buffers.length;n++){var r=t.buffers[n];e.update(r)}},t.prototype.checkCompatibility=function(t,e){var n=t.attributes,r=e.attributeData;for(var i in r)if(!n[i])throw new Error('shader and geometry incompatible, geometry missing the "'+i+'" attribute')},t.prototype.getSignature=function(t,e){var n=t.attributes,r=e.attributeData,i=["g",t.id];for(var o in n)r[o]&&i.push(o,r[o].location);return i.join("-")},t.prototype.initGeometryVao=function(t,e,n){void 0===n&&(n=!0);var r=this.gl,i=this.CONTEXT_UID,o=this.renderer.buffer,s=e.program;s.glPrograms[i]||this.renderer.shader.generateProgram(e),this.checkCompatibility(t,s);var a=this.getSignature(t,s),u=t.glVertexArrayObjects[this.CONTEXT_UID],l=u[a];if(l)return u[s.id]=l,l;var c=t.buffers,h=t.attributes,f={},d={};for(var p in c)f[p]=0,d[p]=0;for(var p in h)!h[p].size&&s.attributeData[p]?h[p].size=s.attributeData[p].size:h[p].size||console.warn("PIXI Geometry attribute '"+p+"' size cannot be determined (likely the bound shader does not have the attribute)"),f[h[p].buffer]+=h[p].size*lt[h[p].type];for(var p in h){var m=h[p],v=m.size;void 0===m.stride&&(f[m.buffer]===v*lt[m.type]?m.stride=0:m.stride=f[m.buffer]),void 0===m.start&&(m.start=d[m.buffer],d[m.buffer]+=v*lt[m.type])}l=r.createVertexArray(),r.bindVertexArray(l);for(var g=0;g<c.length;g++){var _=c[g];o.bind(_),n&&_._glBuffers[i].refCount++}return this.activateVao(t,s),this._activeVao=l,u[s.id]=l,u[a]=l,l},t.prototype.disposeGeometry=function(t,e){var n;if(this.managedGeometries[t.id]){delete this.managedGeometries[t.id];var r=t.glVertexArrayObjects[this.CONTEXT_UID],i=this.gl,o=t.buffers,s=null===(n=this.renderer)||void 0===n?void 0:n.buffer;if(t.disposeRunner.remove(this),r){if(s)for(var a=0;a<o.length;a++){var u=o[a]._glBuffers[this.CONTEXT_UID];u&&(u.refCount--,0!==u.refCount||e||s.dispose(o[a],e))}if(!e)for(var l in r)if("g"===l[0]){var c=r[l];this._activeVao===c&&this.unbind(),i.deleteVertexArray(c)}delete t.glVertexArrayObjects[this.CONTEXT_UID]}}},t.prototype.disposeAll=function(t){for(var e=Object.keys(this.managedGeometries),n=0;n<e.length;n++)this.disposeGeometry(this.managedGeometries[e[n]],t)},t.prototype.activateVao=function(t,e){var n=this.gl,r=this.CONTEXT_UID,i=this.renderer.buffer,o=t.buffers,s=t.attributes;t.indexBuffer&&i.bind(t.indexBuffer);var a=null;for(var u in s){var l=s[u],c=o[l.buffer],h=c._glBuffers[r];if(e.attributeData[u]){a!==h&&(i.bind(c),a=h);var f=e.attributeData[u].location;if(n.enableVertexAttribArray(f),n.vertexAttribPointer(f,l.size,l.type||n.FLOAT,l.normalized,l.stride,l.start),l.instance){if(!this.hasInstance)throw new Error("geometry error, GPU Instancing is not supported on this device");n.vertexAttribDivisor(f,1)}}}},t.prototype.draw=function(t,e,n,r){var i=this.gl,o=this._activeGeometry;if(o.indexBuffer){var s=o.indexBuffer.data.BYTES_PER_ELEMENT,a=2===s?i.UNSIGNED_SHORT:i.UNSIGNED_INT;2===s||4===s&&this.canUseUInt32ElementIndex?o.instanced?i.drawElementsInstanced(t,e||o.indexBuffer.data.length,a,(n||0)*s,r||1):i.drawElements(t,e||o.indexBuffer.data.length,a,(n||0)*s):console.warn("unsupported index buffer type: uint32")}else o.instanced?i.drawArraysInstanced(t,n,e||o.getSize(),r||1):i.drawArrays(t,n,e||o.getSize());return this},t.prototype.unbind=function(){this.gl.bindVertexArray(null),this._activeVao=null,this._activeGeometry=null},t.prototype.destroy=function(){this.renderer=null},t}(),ht=function(){function t(t){void 0===t&&(t=null),this.type=i.A7.NONE,this.autoDetect=!0,this.maskObject=t||null,this.pooled=!1,this.isMaskData=!0,this.resolution=null,this.multisample=r.X.FILTER_MULTISAMPLE,this.enabled=!0,this._filters=null,this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null,this._scissorRectLocal=null,this._target=null}return Object.defineProperty(t.prototype,"filter",{get:function(){return this._filters?this._filters[0]:null},set:function(t){t?this._filters?this._filters[0]=t:this._filters=[t]:this._filters=null},enumerable:!1,configurable:!0}),t.prototype.reset=function(){this.pooled&&(this.maskObject=null,this.type=i.A7.NONE,this.autoDetect=!0),this._target=null,this._scissorRectLocal=null},t.prototype.copyCountersOrReset=function(t){t?(this._stencilCounter=t._stencilCounter,this._scissorCounter=t._scissorCounter,this._scissorRect=t._scissorRect):(this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null)},t}();function ft(t,e,n){var r=t.createShader(e);return t.shaderSource(r,n),t.compileShader(r),r}function dt(t,e){var n=t.getShaderSource(e).split("\n").map((function(t,e){return e+": "+t})),r=t.getShaderInfoLog(e),i=r.split("\n"),o={},s=i.map((function(t){return parseFloat(t.replace(/^ERROR\: 0\:([\d]+)\:.*$/,"$1"))})).filter((function(t){return!(!t||o[t])&&(o[t]=!0,!0)})),a=[""];s.forEach((function(t){n[t-1]="%c"+n[t-1]+"%c",a.push("background: #FF0000; color:#FFFFFF; font-size: 10px","font-size: 10px")}));var u=n.join("\n");a[0]=u,console.error(r),console.groupCollapsed("click to view full shader code"),console.warn.apply(console,a),console.groupEnd()}function pt(t,e,n,r){t.getProgramParameter(e,t.LINK_STATUS)||(t.getShaderParameter(n,t.COMPILE_STATUS)||dt(t,n),t.getShaderParameter(r,t.COMPILE_STATUS)||dt(t,r),console.error("PixiJS Error: Could not initialize shader."),""!==t.getProgramInfoLog(e)&&console.warn("PixiJS Warning: gl.getProgramInfoLog()",t.getProgramInfoLog(e)))}function mt(t){for(var e=new Array(t),n=0;n<e.length;n++)e[n]=!1;return e}function vt(t,e){switch(t){case"float":return 0;case"vec2":return new Float32Array(2*e);case"vec3":return new Float32Array(3*e);case"vec4":return new Float32Array(4*e);case"int":case"uint":case"sampler2D":case"sampler2DArray":return 0;case"ivec2":return new Int32Array(2*e);case"ivec3":return new Int32Array(3*e);case"ivec4":return new Int32Array(4*e);case"uvec2":return new Uint32Array(2*e);case"uvec3":return new Uint32Array(3*e);case"uvec4":return new Uint32Array(4*e);case"bool":return!1;case"bvec2":return mt(2*e);case"bvec3":return mt(3*e);case"bvec4":return mt(4*e);case"mat2":return new Float32Array([1,0,0,1]);case"mat3":return new Float32Array([1,0,0,0,1,0,0,0,1]);case"mat4":return new Float32Array([1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1])}return null}var gt,_t={},yt=_t;function bt(){if(yt===_t||yt&&yt.isContextLost()){var t=document.createElement("canvas"),e=void 0;r.X.PREFER_ENV>=i.Vi.WEBGL2&&(e=t.getContext("webgl2",{})),e||(e=t.getContext("webgl",{})||t.getContext("experimental-webgl",{}),e?e.getExtension("WEBGL_draw_buffers"):e=null),yt=e}return yt}function Et(){if(!gt){gt=i.cB.MEDIUM;var t=bt();if(t&&t.getShaderPrecisionFormat){var e=t.getShaderPrecisionFormat(t.FRAGMENT_SHADER,t.HIGH_FLOAT);gt=e.precision?i.cB.HIGH:i.cB.MEDIUM}}return gt}function Tt(t,e,n){if("precision"!==t.substring(0,9)){var r=e;return e===i.cB.HIGH&&n!==i.cB.HIGH&&(r=i.cB.MEDIUM),"precision "+r+" float;\n"+t}return n!==i.cB.HIGH&&"precision highp"===t.substring(0,15)?t.replace("precision highp","precision mediump"):t}var xt={float:1,vec2:2,vec3:3,vec4:4,int:1,ivec2:2,ivec3:3,ivec4:4,uint:1,uvec2:2,uvec3:3,uvec4:4,bool:1,bvec2:2,bvec3:3,bvec4:4,mat2:4,mat3:9,mat4:16,sampler2D:1};function St(t){return xt[t]}var Rt=null,At={FLOAT:"float",FLOAT_VEC2:"vec2",FLOAT_VEC3:"vec3",FLOAT_VEC4:"vec4",INT:"int",INT_VEC2:"ivec2",INT_VEC3:"ivec3",INT_VEC4:"ivec4",UNSIGNED_INT:"uint",UNSIGNED_INT_VEC2:"uvec2",UNSIGNED_INT_VEC3:"uvec3",UNSIGNED_INT_VEC4:"uvec4",BOOL:"bool",BOOL_VEC2:"bvec2",BOOL_VEC3:"bvec3",BOOL_VEC4:"bvec4",FLOAT_MAT2:"mat2",FLOAT_MAT3:"mat3",FLOAT_MAT4:"mat4",SAMPLER_2D:"sampler2D",INT_SAMPLER_2D:"sampler2D",UNSIGNED_INT_SAMPLER_2D:"sampler2D",SAMPLER_CUBE:"samplerCube",INT_SAMPLER_CUBE:"samplerCube",UNSIGNED_INT_SAMPLER_CUBE:"samplerCube",SAMPLER_2D_ARRAY:"sampler2DArray",INT_SAMPLER_2D_ARRAY:"sampler2DArray",UNSIGNED_INT_SAMPLER_2D_ARRAY:"sampler2DArray"};function Ot(t,e){if(!Rt){var n=Object.keys(At);Rt={};for(var r=0;r<n.length;++r){var i=n[r];Rt[t[i]]=At[i]}}return Rt[e]}var It=[{test:function(t){return"float"===t.type&&1===t.size},code:function(t){return'\n if(uv["'+t+'"] !== ud["'+t+'"].value)\n {\n ud["'+t+'"].value = uv["'+t+'"]\n gl.uniform1f(ud["'+t+'"].location, uv["'+t+'"])\n }\n '}},{test:function(t){return("sampler2D"===t.type||"samplerCube"===t.type||"sampler2DArray"===t.type)&&1===t.size&&!t.isArray},code:function(t){return't = syncData.textureCount++;\n\n renderer.texture.bind(uv["'+t+'"], t);\n\n if(ud["'+t+'"].value !== t)\n {\n ud["'+t+'"].value = t;\n gl.uniform1i(ud["'+t+'"].location, t);\n; // eslint-disable-line max-len\n }'}},{test:function(t,e){return"mat3"===t.type&&1===t.size&&void 0!==e.a},code:function(t){return'\n gl.uniformMatrix3fv(ud["'+t+'"].location, false, uv["'+t+'"].toArray(true));\n '},codeUbo:function(t){return"\n var "+t+"_matrix = uv."+t+".toArray(true);\n\n data[offset] = "+t+"_matrix[0];\n data[offset+1] = "+t+"_matrix[1];\n data[offset+2] = "+t+"_matrix[2];\n \n data[offset + 4] = "+t+"_matrix[3];\n data[offset + 5] = "+t+"_matrix[4];\n data[offset + 6] = "+t+"_matrix[5];\n \n data[offset + 8] = "+t+"_matrix[6];\n data[offset + 9] = "+t+"_matrix[7];\n data[offset + 10] = "+t+"_matrix[8];\n "}},{test:function(t,e){return"vec2"===t.type&&1===t.size&&void 0!==e.x},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v.x || cv[1] !== v.y)\n {\n cv[0] = v.x;\n cv[1] = v.y;\n gl.uniform2f(ud["'+t+'"].location, v.x, v.y);\n }'},codeUbo:function(t){return"\n v = uv."+t+";\n\n data[offset] = v.x;\n data[offset+1] = v.y;\n "}},{test:function(t){return"vec2"===t.type&&1===t.size},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n gl.uniform2f(ud["'+t+'"].location, v[0], v[1]);\n }\n '}},{test:function(t,e){return"vec4"===t.type&&1===t.size&&void 0!==e.width},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v.x || cv[1] !== v.y || cv[2] !== v.width || cv[3] !== v.height)\n {\n cv[0] = v.x;\n cv[1] = v.y;\n cv[2] = v.width;\n cv[3] = v.height;\n gl.uniform4f(ud["'+t+'"].location, v.x, v.y, v.width, v.height)\n }'},codeUbo:function(t){return"\n v = uv."+t+";\n\n data[offset] = v.x;\n data[offset+1] = v.y;\n data[offset+2] = v.width;\n data[offset+3] = v.height;\n "}},{test:function(t){return"vec4"===t.type&&1===t.size},code:function(t){return'\n cv = ud["'+t+'"].value;\n v = uv["'+t+'"];\n\n if(cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4f(ud["'+t+'"].location, v[0], v[1], v[2], v[3])\n }'}}],wt={float:"\n if (cv !== v)\n {\n cu.value = v;\n gl.uniform1f(location, v);\n }",vec2:"\n if (cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2f(location, v[0], v[1])\n }",vec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3f(location, v[0], v[1], v[2])\n }",vec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4f(location, v[0], v[1], v[2], v[3]);\n }",int:"\n if (cv !== v)\n {\n cu.value = v;\n\n gl.uniform1i(location, v);\n }",ivec2:"\n if (cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2i(location, v[0], v[1]);\n }",ivec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3i(location, v[0], v[1], v[2]);\n }",ivec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\n }",uint:"\n if (cv !== v)\n {\n cu.value = v;\n\n gl.uniform1ui(location, v);\n }",uvec2:"\n if (cv[0] !== v[0] || cv[1] !== v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2ui(location, v[0], v[1]);\n }",uvec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3ui(location, v[0], v[1], v[2]);\n }",uvec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4ui(location, v[0], v[1], v[2], v[3]);\n }",bool:"\n if (cv !== v)\n {\n cu.value = v;\n gl.uniform1i(location, v);\n }",bvec2:"\n if (cv[0] != v[0] || cv[1] != v[1])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n\n gl.uniform2i(location, v[0], v[1]);\n }",bvec3:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n\n gl.uniform3i(location, v[0], v[1], v[2]);\n }",bvec4:"\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\n {\n cv[0] = v[0];\n cv[1] = v[1];\n cv[2] = v[2];\n cv[3] = v[3];\n\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\n }",mat2:"gl.uniformMatrix2fv(location, false, v)",mat3:"gl.uniformMatrix3fv(location, false, v)",mat4:"gl.uniformMatrix4fv(location, false, v)",sampler2D:"gl.uniform1i(location, v)",samplerCube:"gl.uniform1i(location, v)",sampler2DArray:"gl.uniform1i(location, v)"},Ct={float:"gl.uniform1fv(location, v)",vec2:"gl.uniform2fv(location, v)",vec3:"gl.uniform3fv(location, v)",vec4:"gl.uniform4fv(location, v)",mat4:"gl.uniformMatrix4fv(location, false, v)",mat3:"gl.uniformMatrix3fv(location, false, v)",mat2:"gl.uniformMatrix2fv(location, false, v)",int:"gl.uniform1iv(location, v)",ivec2:"gl.uniform2iv(location, v)",ivec3:"gl.uniform3iv(location, v)",ivec4:"gl.uniform4iv(location, v)",uint:"gl.uniform1uiv(location, v)",uvec2:"gl.uniform2uiv(location, v)",uvec3:"gl.uniform3uiv(location, v)",uvec4:"gl.uniform4uiv(location, v)",bool:"gl.uniform1iv(location, v)",bvec2:"gl.uniform2iv(location, v)",bvec3:"gl.uniform3iv(location, v)",bvec4:"gl.uniform4iv(location, v)",sampler2D:"gl.uniform1iv(location, v)",samplerCube:"gl.uniform1iv(location, v)",sampler2DArray:"gl.uniform1iv(location, v)"};function Pt(t,e){var n,r=["\n var v = null;\n var cv = null;\n var cu = null;\n var t = 0;\n var gl = renderer.gl;\n "];for(var i in t.uniforms){var o=e[i];if(o){for(var s=t.uniforms[i],a=!1,u=0;u<It.length;u++)if(It[u].test(o,s)){r.push(It[u].code(i,s)),a=!0;break}if(!a){var l=1===o.size?wt:Ct,c=l[o.type].replace("location",'ud["'+i+'"].location');r.push('\n cu = ud["'+i+'"];\n cv = cu.value;\n v = uv["'+i+'"];\n '+c+";")}}else(null===(n=t.uniforms[i])||void 0===n?void 0:n.group)&&(t.uniforms[i].ubo?r.push("\n renderer.shader.syncUniformBufferGroup(uv."+i+", '"+i+"');\n "):r.push("\n renderer.shader.syncUniformGroup(uv."+i+", syncData);\n "))}return new Function("ud","uv","renderer","syncData",r.join("\n"))}var Nt,Mt=["precision mediump float;","void main(void){","float test = 0.1;","%forloop%","gl_FragColor = vec4(0.0);","}"].join("\n");function Dt(t){for(var e="",n=0;n<t;++n)n>0&&(e+="\nelse "),n<t-1&&(e+="if(test == "+n+".0){}");return e}function Lt(t,e){if(0===t)throw new Error("Invalid value of `0` passed to `checkMaxIfStatementsInShader`");var n=e.createShader(e.FRAGMENT_SHADER);while(1){var r=Mt.replace(/%forloop%/gi,Dt(t));if(e.shaderSource(n,r),e.compileShader(n),e.getShaderParameter(n,e.COMPILE_STATUS))break;t=t/2|0}return t}function Bt(){if("boolean"===typeof Nt)return Nt;try{var t=new Function("param1","param2","param3","return param1[param2] === param3;");Nt=!0===t({a:"b"},"a","b")}catch(e){Nt=!1}return Nt}var Ft="varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\n\nvoid main(void){\n gl_FragColor *= texture2D(uSampler, vTextureCoord);\n}",Ut="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void){\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}\n",Gt=0,kt={},Xt=function(){function t(e,n,o){void 0===o&&(o="pixi-shader"),this.id=Gt++,this.vertexSrc=e||t.defaultVertexSrc,this.fragmentSrc=n||t.defaultFragmentSrc,this.vertexSrc=this.vertexSrc.trim(),this.fragmentSrc=this.fragmentSrc.trim(),"#version"!==this.vertexSrc.substring(0,8)&&(o=o.replace(/\s+/g,"-"),kt[o]?(kt[o]++,o+="-"+kt[o]):kt[o]=1,this.vertexSrc="#define SHADER_NAME "+o+"\n"+this.vertexSrc,this.fragmentSrc="#define SHADER_NAME "+o+"\n"+this.fragmentSrc,this.vertexSrc=Tt(this.vertexSrc,r.X.PRECISION_VERTEX,i.cB.HIGH),this.fragmentSrc=Tt(this.fragmentSrc,r.X.PRECISION_FRAGMENT,Et())),this.glPrograms={},this.syncUniforms=null}return Object.defineProperty(t,"defaultVertexSrc",{get:function(){return Ut},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultFragmentSrc",{get:function(){return Ft},enumerable:!1,configurable:!0}),t.from=function(e,n,r){var i=e+n,s=o.GG[i];return s||(o.GG[i]=s=new t(e,n,r)),s},t}(),Ht=function(){function t(t,e){this.uniformBindCount=0,this.program=t,this.uniformGroup=e?e instanceof Z?e:new Z(e):new Z({})}return t.prototype.checkUniformExists=function(t,e){if(e.uniforms[t])return!0;for(var n in e.uniforms){var r=e.uniforms[n];if(r.group&&this.checkUniformExists(t,r))return!0}return!1},t.prototype.destroy=function(){this.uniformGroup=null},Object.defineProperty(t.prototype,"uniforms",{get:function(){return this.uniformGroup.uniforms},enumerable:!1,configurable:!0}),t.from=function(e,n,r){var i=Xt.from(e,n);return new t(i,r)},t}(),jt=0,Vt=1,Yt=2,Wt=3,zt=4,$t=5,qt=function(){function t(){this.data=0,this.blendMode=i.T$.NORMAL,this.polygonOffset=0,this.blend=!0,this.depthMask=!0}return Object.defineProperty(t.prototype,"blend",{get:function(){return!!(this.data&1<<jt)},set:function(t){!!(this.data&1<<jt)!==t&&(this.data^=1<<jt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"offsets",{get:function(){return!!(this.data&1<<Vt)},set:function(t){!!(this.data&1<<Vt)!==t&&(this.data^=1<<Vt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"culling",{get:function(){return!!(this.data&1<<Yt)},set:function(t){!!(this.data&1<<Yt)!==t&&(this.data^=1<<Yt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"depthTest",{get:function(){return!!(this.data&1<<Wt)},set:function(t){!!(this.data&1<<Wt)!==t&&(this.data^=1<<Wt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"depthMask",{get:function(){return!!(this.data&1<<$t)},set:function(t){!!(this.data&1<<$t)!==t&&(this.data^=1<<$t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"clockwiseFrontFace",{get:function(){return!!(this.data&1<<zt)},set:function(t){!!(this.data&1<<zt)!==t&&(this.data^=1<<zt)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"blendMode",{get:function(){return this._blendMode},set:function(t){this.blend=t!==i.T$.NONE,this._blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"polygonOffset",{get:function(){return this._polygonOffset},set:function(t){this.offsets=!!t,this._polygonOffset=t},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"[@pixi/core:State blendMode="+this.blendMode+" clockwiseFrontFace="+this.clockwiseFrontFace+" culling="+this.culling+" depthMask="+this.depthMask+" polygonOffset="+this.polygonOffset+"]"},t.for2d=function(){var e=new t;return e.depthTest=!1,e.blend=!0,e},t}(),Kt="attribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvec2 filterTextureCoord( void )\n{\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n}\n\nvoid main(void)\n{\n gl_Position = filterVertexPosition();\n vTextureCoord = filterTextureCoord();\n}\n",Zt="varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\n\nvoid main(void){\n gl_FragColor = texture2D(uSampler, vTextureCoord);\n}\n",Jt=function(t){function e(n,i,o){var s=this,a=Xt.from(n||e.defaultVertexSrc,i||e.defaultFragmentSrc);return s=t.call(this,a,o)||this,s.padding=0,s.resolution=r.X.FILTER_RESOLUTION,s.multisample=r.X.FILTER_MULTISAMPLE,s.enabled=!0,s.autoFit=!0,s.state=new qt,s}return f(e,t),e.prototype.apply=function(t,e,n,r,i){t.applyFilter(this,e,n,r)},Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.state.blendMode},set:function(t){this.state.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"resolution",{get:function(){return this._resolution},set:function(t){this._resolution=t},enumerable:!1,configurable:!0}),Object.defineProperty(e,"defaultVertexSrc",{get:function(){return Kt},enumerable:!1,configurable:!0}),Object.defineProperty(e,"defaultFragmentSrc",{get:function(){return Zt},enumerable:!1,configurable:!0}),e}(Ht),Qt="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 otherMatrix;\n\nvarying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;\n}\n",te="varying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform sampler2D mask;\nuniform float alpha;\nuniform float npmAlpha;\nuniform vec4 maskClamp;\n\nvoid main(void)\n{\n float clip = step(3.5,\n step(maskClamp.x, vMaskCoord.x) +\n step(maskClamp.y, vMaskCoord.y) +\n step(vMaskCoord.x, maskClamp.z) +\n step(vMaskCoord.y, maskClamp.w));\n\n vec4 original = texture2D(uSampler, vTextureCoord);\n vec4 masky = texture2D(mask, vMaskCoord);\n float alphaMul = 1.0 - npmAlpha * (1.0 - masky.a);\n\n original *= (alphaMul * masky.r * alpha * clip);\n\n gl_FragColor = original;\n}\n",ee=new u.y3,ne=function(){function t(t,e){this._texture=t,this.mapCoord=new u.y3,this.uClampFrame=new Float32Array(4),this.uClampOffset=new Float32Array(2),this._textureID=-1,this._updateID=0,this.clampOffset=0,this.clampMargin="undefined"===typeof e?.5:e,this.isSimple=!1}return Object.defineProperty(t.prototype,"texture",{get:function(){return this._texture},set:function(t){this._texture=t,this._textureID=-1},enumerable:!1,configurable:!0}),t.prototype.multiplyUvs=function(t,e){void 0===e&&(e=t);for(var n=this.mapCoord,r=0;r<t.length;r+=2){var i=t[r],o=t[r+1];e[r]=i*n.a+o*n.c+n.tx,e[r+1]=i*n.b+o*n.d+n.ty}return e},t.prototype.update=function(t){var e=this._texture;if(!e||!e.valid)return!1;if(!t&&this._textureID===e._updateID)return!1;this._textureID=e._updateID,this._updateID++;var n=e._uvs;this.mapCoord.set(n.x1-n.x0,n.y1-n.y0,n.x3-n.x0,n.y3-n.y0,n.x0,n.y0);var r=e.orig,i=e.trim;i&&(ee.set(r.width/i.width,0,0,r.height/i.height,-i.x/i.width,-i.y/i.height),this.mapCoord.append(ee));var o=e.baseTexture,s=this.uClampFrame,a=this.clampMargin/o.resolution,u=this.clampOffset;return s[0]=(e._frame.x+a+u)/o.width,s[1]=(e._frame.y+a+u)/o.height,s[2]=(e._frame.x+e._frame.width-a+u)/o.width,s[3]=(e._frame.y+e._frame.height-a+u)/o.height,this.uClampOffset[0]=u/o.realWidth,this.uClampOffset[1]=u/o.realHeight,this.isSimple=e._frame.width===o.width&&e._frame.height===o.height&&0===e.rotate,!0},t}(),re=function(t){function e(e,n,r){var i=this,o=null;return"string"!==typeof e&&void 0===n&&void 0===r&&(o=e,e=void 0,n=void 0,r=void 0),i=t.call(this,e||Qt,n||te,r)||this,i.maskSprite=o,i.maskMatrix=new u.y3,i}return f(e,t),Object.defineProperty(e.prototype,"maskSprite",{get:function(){return this._maskSprite},set:function(t){this._maskSprite=t,this._maskSprite&&(this._maskSprite.renderable=!1)},enumerable:!1,configurable:!0}),e.prototype.apply=function(t,e,n,r){var i=this._maskSprite,o=i._texture;o.valid&&(o.uvMatrix||(o.uvMatrix=new ne(o,0)),o.uvMatrix.update(),this.uniforms.npmAlpha=o.baseTexture.alphaMode?0:1,this.uniforms.mask=o,this.uniforms.otherMatrix=t.calculateSpriteMatrix(this.maskMatrix,i).prepend(o.uvMatrix.mapCoord),this.uniforms.alpha=i.worldAlpha,this.uniforms.maskClamp=o.uvMatrix.uClampFrame,t.applyFilter(this,e,n,r))},e}(Jt),ie=function(){function t(t){this.renderer=t,this.enableScissor=!0,this.alphaMaskPool=[],this.maskDataPool=[],this.maskStack=[],this.alphaMaskIndex=0}return t.prototype.setMaskStack=function(t){this.maskStack=t,this.renderer.scissor.setMaskStack(t),this.renderer.stencil.setMaskStack(t)},t.prototype.push=function(t,e){var n=e;if(!n.isMaskData){var r=this.maskDataPool.pop()||new ht;r.pooled=!0,r.maskObject=e,n=r}var o=0!==this.maskStack.length?this.maskStack[this.maskStack.length-1]:null;if(n.copyCountersOrReset(o),n.autoDetect&&this.detect(n),n._target=t,n.type!==i.A7.SPRITE&&this.maskStack.push(n),n.enabled)switch(n.type){case i.A7.SCISSOR:this.renderer.scissor.push(n);break;case i.A7.STENCIL:this.renderer.stencil.push(n);break;case i.A7.SPRITE:n.copyCountersOrReset(null),this.pushSpriteMask(n);break}n.type===i.A7.SPRITE&&this.maskStack.push(n)},t.prototype.pop=function(t){var e=this.maskStack.pop();if(e&&e._target===t){if(e.enabled)switch(e.type){case i.A7.SCISSOR:this.renderer.scissor.pop();break;case i.A7.STENCIL:this.renderer.stencil.pop(e.maskObject);break;case i.A7.SPRITE:this.popSpriteMask(e);break}if(e.reset(),e.pooled&&this.maskDataPool.push(e),0!==this.maskStack.length){var n=this.maskStack[this.maskStack.length-1];n.type===i.A7.SPRITE&&n._filters&&(n._filters[0].maskSprite=n.maskObject)}}},t.prototype.detect=function(t){var e=t.maskObject;e.isSprite?t.type=i.A7.SPRITE:this.enableScissor&&this.renderer.scissor.testScissor(t)?t.type=i.A7.SCISSOR:t.type=i.A7.STENCIL},t.prototype.pushSpriteMask=function(t){var e,n,r=t.maskObject,i=t._target,o=t._filters;o||(o=this.alphaMaskPool[this.alphaMaskIndex],o||(o=this.alphaMaskPool[this.alphaMaskIndex]=[new re]));var s,a,u=this.renderer,l=u.renderTexture;if(l.current){var c=l.current;s=t.resolution||c.resolution,a=null!==(e=t.multisample)&&void 0!==e?e:c.multisample}else s=t.resolution||u.resolution,a=null!==(n=t.multisample)&&void 0!==n?n:u.multisample;o[0].resolution=s,o[0].multisample=a,o[0].maskSprite=r;var h=i.filterArea;i.filterArea=r.getBounds(!0),u.filter.push(i,o),i.filterArea=h,t._filters||this.alphaMaskIndex++},t.prototype.popSpriteMask=function(t){this.renderer.filter.pop(),t._filters?t._filters[0].maskSprite=null:(this.alphaMaskIndex--,this.alphaMaskPool[this.alphaMaskIndex][0].maskSprite=null)},t.prototype.destroy=function(){this.renderer=null},t}(),oe=function(){function t(t){this.renderer=t,this.maskStack=[],this.glConst=0}return t.prototype.getStackLength=function(){return this.maskStack.length},t.prototype.setMaskStack=function(t){var e=this.renderer.gl,n=this.getStackLength();this.maskStack=t;var r=this.getStackLength();r!==n&&(0===r?e.disable(this.glConst):(e.enable(this.glConst),this._useCurrent()))},t.prototype._useCurrent=function(){},t.prototype.destroy=function(){this.renderer=null,this.maskStack=null},t}(),se=new u.y3,ae=function(t){function e(e){var n=t.call(this,e)||this;return n.glConst=WebGLRenderingContext.SCISSOR_TEST,n}return f(e,t),e.prototype.getStackLength=function(){var t=this.maskStack[this.maskStack.length-1];return t?t._scissorCounter:0},e.prototype.calcScissorRect=function(t){if(!t._scissorRectLocal){var e=t._scissorRect,n=t.maskObject,r=this.renderer,i=r.renderTexture;n.renderable=!0;var o=n.getBounds();this.roundFrameToPixels(o,i.current?i.current.resolution:r.resolution,i.sourceFrame,i.destinationFrame,r.projection.transform),n.renderable=!1,e&&o.fit(e),t._scissorRectLocal=o}},e.isMatrixRotated=function(t){if(!t)return!1;var e=t.a,n=t.b,r=t.c,i=t.d;return(Math.abs(n)>1e-4||Math.abs(r)>1e-4)&&(Math.abs(e)>1e-4||Math.abs(i)>1e-4)},e.prototype.testScissor=function(t){var n=t.maskObject;if(!n.isFastRect||!n.isFastRect())return!1;if(e.isMatrixRotated(n.worldTransform))return!1;if(e.isMatrixRotated(this.renderer.projection.transform))return!1;this.calcScissorRect(t);var r=t._scissorRectLocal;return r.width>0&&r.height>0},e.prototype.roundFrameToPixels=function(t,n,r,i,o){e.isMatrixRotated(o)||(o=o?se.copyFrom(o):se.identity(),o.translate(-r.x,-r.y).scale(i.width/r.width,i.height/r.height).translate(i.x,i.y),this.renderer.filter.transformAABB(o,t),t.fit(i),t.x=Math.round(t.x*n),t.y=Math.round(t.y*n),t.width=Math.round(t.width*n),t.height=Math.round(t.height*n))},e.prototype.push=function(t){t._scissorRectLocal||this.calcScissorRect(t);var e=this.renderer.gl;t._scissorRect||e.enable(e.SCISSOR_TEST),t._scissorCounter++,t._scissorRect=t._scissorRectLocal,this._useCurrent()},e.prototype.pop=function(){var t=this.renderer.gl;this.getStackLength()>0?this._useCurrent():t.disable(t.SCISSOR_TEST)},e.prototype._useCurrent=function(){var t,e=this.maskStack[this.maskStack.length-1]._scissorRect;t=this.renderer.renderTexture.current?e.y:this.renderer.height-e.height-e.y,this.renderer.gl.scissor(e.x,t,e.width,e.height)},e}(oe),ue=function(t){function e(e){var n=t.call(this,e)||this;return n.glConst=WebGLRenderingContext.STENCIL_TEST,n}return f(e,t),e.prototype.getStackLength=function(){var t=this.maskStack[this.maskStack.length-1];return t?t._stencilCounter:0},e.prototype.push=function(t){var e=t.maskObject,n=this.renderer.gl,r=t._stencilCounter;0===r&&(this.renderer.framebuffer.forceStencil(),n.clearStencil(0),n.clear(n.STENCIL_BUFFER_BIT),n.enable(n.STENCIL_TEST)),t._stencilCounter++,n.colorMask(!1,!1,!1,!1),n.stencilFunc(n.EQUAL,r,4294967295),n.stencilOp(n.KEEP,n.KEEP,n.INCR),e.renderable=!0,e.render(this.renderer),this.renderer.batch.flush(),e.renderable=!1,this._useCurrent()},e.prototype.pop=function(t){var e=this.renderer.gl;0===this.getStackLength()?e.disable(e.STENCIL_TEST):(e.colorMask(!1,!1,!1,!1),e.stencilOp(e.KEEP,e.KEEP,e.DECR),t.renderable=!0,t.render(this.renderer),this.renderer.batch.flush(),t.renderable=!1,this._useCurrent())},e.prototype._useCurrent=function(){var t=this.renderer.gl;t.colorMask(!0,!0,!0,!0),t.stencilFunc(t.EQUAL,this.getStackLength(),4294967295),t.stencilOp(t.KEEP,t.KEEP,t.KEEP)},e}(oe),le=function(){function t(t){this.renderer=t,this.destinationFrame=null,this.sourceFrame=null,this.defaultFrame=null,this.projectionMatrix=new u.y3,this.transform=null}return t.prototype.update=function(t,e,n,r){this.destinationFrame=t||this.destinationFrame||this.defaultFrame,this.sourceFrame=e||this.sourceFrame||t,this.calculateProjection(this.destinationFrame,this.sourceFrame,n,r),this.transform&&this.projectionMatrix.append(this.transform);var i=this.renderer;i.globalUniforms.uniforms.projectionMatrix=this.projectionMatrix,i.globalUniforms.update(),i.shader.shader&&i.shader.syncUniformGroup(i.shader.shader.uniforms.globals)},t.prototype.calculateProjection=function(t,e,n,r){var i=this.projectionMatrix,o=r?-1:1;i.identity(),i.a=1/e.width*2,i.d=o*(1/e.height*2),i.tx=-1-e.x*i.a,i.ty=-o-e.y*i.d},t.prototype.setTransform=function(t){},t.prototype.destroy=function(){this.renderer=null},t}(),ce=new u.Ae,he=new u.Ae,fe=function(){function t(t){this.renderer=t,this.clearColor=t._backgroundColorRgba,this.defaultMaskStack=[],this.current=null,this.sourceFrame=new u.Ae,this.destinationFrame=new u.Ae,this.viewportFrame=new u.Ae}return t.prototype.bind=function(t,e,n){void 0===t&&(t=null);var r,i,o,s=this.renderer;this.current=t,t?(r=t.baseTexture,o=r.resolution,e||(ce.width=t.frame.width,ce.height=t.frame.height,e=ce),n||(he.x=t.frame.x,he.y=t.frame.y,he.width=e.width,he.height=e.height,n=he),i=r.framebuffer):(o=s.resolution,e||(ce.width=s.screen.width,ce.height=s.screen.height,e=ce),n||(n=ce,n.width=e.width,n.height=e.height));var a=this.viewportFrame;a.x=n.x*o,a.y=n.y*o,a.width=n.width*o,a.height=n.height*o,t||(a.y=s.view.height-(a.y+a.height)),a.ceil(),this.renderer.framebuffer.bind(i,a),this.renderer.projection.update(n,e,o,!i),t?this.renderer.mask.setMaskStack(r.maskStack):this.renderer.mask.setMaskStack(this.defaultMaskStack),this.sourceFrame.copyFrom(e),this.destinationFrame.copyFrom(n)},t.prototype.clear=function(t,e){t=this.current?t||this.current.baseTexture.clearColor:t||this.clearColor;var n=this.destinationFrame,r=this.current?this.current.baseTexture:this.renderer.screen,i=n.width!==r.width||n.height!==r.height;if(i){var o=this.viewportFrame,s=o.x,a=o.y,u=o.width,l=o.height;s=Math.round(s),a=Math.round(a),u=Math.round(u),l=Math.round(l),this.renderer.gl.enable(this.renderer.gl.SCISSOR_TEST),this.renderer.gl.scissor(s,a,u,l)}this.renderer.framebuffer.clear(t[0],t[1],t[2],t[3],e),i&&this.renderer.scissor.pop()},t.prototype.resize=function(){this.bind(null)},t.prototype.reset=function(){this.bind(null)},t.prototype.destroy=function(){this.renderer=null},t}();function de(t,e,n,r,i){n.buffer.update(i)}var pe={float:"\n data[offset] = v;\n ",vec2:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n ",vec3:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n data[offset+2] = v[2];\n\n ",vec4:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n data[offset+2] = v[2];\n data[offset+3] = v[3];\n ",mat2:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n\n data[offset+4] = v[2];\n data[offset+5] = v[3];\n ",mat3:"\n data[offset] = v[0];\n data[offset+1] = v[1];\n data[offset+2] = v[2];\n\n data[offset + 4] = v[3];\n data[offset + 5] = v[4];\n data[offset + 6] = v[5];\n\n data[offset + 8] = v[6];\n data[offset + 9] = v[7];\n data[offset + 10] = v[8];\n ",mat4:"\n for(var i = 0; i < 16; i++)\n {\n data[offset + i] = v[i];\n }\n "},me={float:4,vec2:8,vec3:12,vec4:16,int:4,ivec2:8,ivec3:12,ivec4:16,uint:4,uvec2:8,uvec3:12,uvec4:16,bool:4,bvec2:8,bvec3:12,bvec4:16,mat2:32,mat3:48,mat4:64};function ve(t){for(var e=t.map((function(t){return{data:t,offset:0,dataLen:0,dirty:0}})),n=0,r=0,i=0,o=0;o<e.length;o++){var s=e[o];if(n=me[s.data.type],s.data.size>1&&(n=Math.max(n,16)*s.data.size),s.dataLen=n,r%n!==0&&r<16){var a=r%n%16;r+=a,i+=a}r+n>16?(i=16*Math.ceil(i/16),s.offset=i,i+=n,r=n):(s.offset=i,r+=n,i+=n)}return i=16*Math.ceil(i/16),{uboElements:e,size:i}}function ge(t,e){var n=[];for(var r in t)e[r]&&n.push(e[r]);return n.sort((function(t,e){return t.index-e.index})),n}function _e(t,e){if(!t.autoManage)return{size:0,syncFunc:de};for(var n=ge(t.uniforms,e),r=ve(n),i=r.uboElements,o=r.size,s=["\n var v = null;\n var v2 = null;\n var cv = null;\n var t = 0;\n var gl = renderer.gl\n var index = 0;\n var data = buffer.data;\n "],a=0;a<i.length;a++){for(var u=i[a],l=t.uniforms[u.data.name],c=u.data.name,h=!1,f=0;f<It.length;f++){var d=It[f];if(d.codeUbo&&d.test(u.data,l)){s.push("offset = "+u.offset/4+";",It[f].codeUbo(u.data.name,l)),h=!0;break}}if(!h)if(u.data.size>1){var p=St(u.data.type),m=Math.max(me[u.data.type]/16,1),v=p/m,g=(4-v%4)%4;s.push("\n cv = ud."+c+".value;\n v = uv."+c+";\n offset = "+u.offset/4+";\n\n t = 0;\n\n for(var i=0; i < "+u.data.size*m+"; i++)\n {\n for(var j = 0; j < "+v+"; j++)\n {\n data[offset++] = v[t++];\n }\n offset += "+g+";\n }\n\n ")}else{var _=pe[u.data.type];s.push("\n cv = ud."+c+".value;\n v = uv."+c+";\n offset = "+u.offset/4+";\n "+_+";\n ")}}return s.push("\n renderer.buffer.update(buffer);\n "),{size:o,syncFunc:new Function("ud","uv","renderer","syncData","buffer",s.join("\n"))}}(function(){function t(){}})();var ye=function(){function t(t,e){this.program=t,this.uniformData=e,this.uniformGroups={},this.uniformDirtyGroups={},this.uniformBufferBindings={}}return t.prototype.destroy=function(){this.uniformData=null,this.uniformGroups=null,this.uniformDirtyGroups=null,this.uniformBufferBindings=null,this.program=null},t}();function be(t,e){for(var n={},r=e.getProgramParameter(t,e.ACTIVE_ATTRIBUTES),i=0;i<r;i++){var o=e.getActiveAttrib(t,i);if(0!==o.name.indexOf("gl_")){var s=Ot(e,o.type),a={type:s,name:o.name,size:St(s),location:e.getAttribLocation(t,o.name)};n[o.name]=a}}return n}function Ee(t,e){for(var n={},r=e.getProgramParameter(t,e.ACTIVE_UNIFORMS),i=0;i<r;i++){var o=e.getActiveUniform(t,i),s=o.name.replace(/\[.*?\]$/,""),a=!!o.name.match(/\[.*?\]$/),u=Ot(e,o.type);n[s]={name:s,index:i,type:u,size:o.size,isArray:a,value:vt(u,o.size)}}return n}function Te(t,e){var n=ft(t,t.VERTEX_SHADER,e.vertexSrc),r=ft(t,t.FRAGMENT_SHADER,e.fragmentSrc),i=t.createProgram();if(t.attachShader(i,n),t.attachShader(i,r),t.linkProgram(i),t.getProgramParameter(i,t.LINK_STATUS)||pt(t,i,n,r),e.attributeData=be(i,t),e.uniformData=Ee(i,t),!/^[ \t]*#[ \t]*version[ \t]+300[ \t]+es[ \t]*$/m.test(e.vertexSrc)){var o=Object.keys(e.attributeData);o.sort((function(t,e){return t>e?1:-1}));for(var s=0;s<o.length;s++)e.attributeData[o[s]].location=s,t.bindAttribLocation(i,s,o[s]);t.linkProgram(i)}t.deleteShader(n),t.deleteShader(r);var a={};for(var s in e.uniformData){var u=e.uniformData[s];a[s]={location:t.getUniformLocation(i,s),value:vt(u.type,u.size)}}var l=new ye(i,a);return l}var xe=0,Se={textureCount:0,uboCount:0},Re=function(){function t(t){this.destroyed=!1,this.renderer=t,this.systemCheck(),this.gl=null,this.shader=null,this.program=null,this.cache={},this._uboCache={},this.id=xe++}return t.prototype.systemCheck=function(){if(!Bt())throw new Error("Current environment does not allow unsafe-eval, please use @pixi/unsafe-eval module to enable support.")},t.prototype.contextChange=function(t){this.gl=t,this.reset()},t.prototype.bind=function(t,e){t.uniforms.globals=this.renderer.globalUniforms;var n=t.program,r=n.glPrograms[this.renderer.CONTEXT_UID]||this.generateProgram(t);return this.shader=t,this.program!==n&&(this.program=n,this.gl.useProgram(r.program)),e||(Se.textureCount=0,Se.uboCount=0,this.syncUniformGroup(t.uniformGroup,Se)),r},t.prototype.setUniforms=function(t){var e=this.shader.program,n=e.glPrograms[this.renderer.CONTEXT_UID];e.syncUniforms(n.uniformData,t,this.renderer)},t.prototype.syncUniformGroup=function(t,e){var n=this.getGlProgram();t.static&&t.dirtyId===n.uniformDirtyGroups[t.id]||(n.uniformDirtyGroups[t.id]=t.dirtyId,this.syncUniforms(t,n,e))},t.prototype.syncUniforms=function(t,e,n){var r=t.syncUniforms[this.shader.program.id]||this.createSyncGroups(t);r(e.uniformData,t.uniforms,this.renderer,n)},t.prototype.createSyncGroups=function(t){var e=this.getSignature(t,this.shader.program.uniformData,"u");return this.cache[e]||(this.cache[e]=Pt(t,this.shader.program.uniformData)),t.syncUniforms[this.shader.program.id]=this.cache[e],t.syncUniforms[this.shader.program.id]},t.prototype.syncUniformBufferGroup=function(t,e){var n=this.getGlProgram();if(!t.static||0!==t.dirtyId||!n.uniformGroups[t.id]){t.dirtyId=0;var r=n.uniformGroups[t.id]||this.createSyncBufferGroup(t,n,e);t.buffer.update(),r(n.uniformData,t.uniforms,this.renderer,Se,t.buffer)}this.renderer.buffer.bindBufferBase(t.buffer,n.uniformBufferBindings[e])},t.prototype.createSyncBufferGroup=function(t,e,n){var r=this.renderer.gl;this.renderer.buffer.bind(t.buffer);var i=this.gl.getUniformBlockIndex(e.program,n);e.uniformBufferBindings[n]=this.shader.uniformBindCount,r.uniformBlockBinding(e.program,i,this.shader.uniformBindCount),this.shader.uniformBindCount++;var o=this.getSignature(t,this.shader.program.uniformData,"ubo"),s=this._uboCache[o];if(s||(s=this._uboCache[o]=_e(t,this.shader.program.uniformData)),t.autoManage){var a=new Float32Array(s.size/4);t.buffer.update(a)}return e.uniformGroups[t.id]=s.syncFunc,e.uniformGroups[t.id]},t.prototype.getSignature=function(t,e,n){var r=t.uniforms,i=[n+"-"];for(var o in r)i.push(o),e[o]&&i.push(e[o].type);return i.join("-")},t.prototype.getGlProgram=function(){return this.shader?this.shader.program.glPrograms[this.renderer.CONTEXT_UID]:null},t.prototype.generateProgram=function(t){var e=this.gl,n=t.program,r=Te(e,n);return n.glPrograms[this.renderer.CONTEXT_UID]=r,r},t.prototype.reset=function(){this.program=null,this.shader=null},t.prototype.destroy=function(){this.renderer=null,this.destroyed=!0},t}();function Ae(t,e){return void 0===e&&(e=[]),e[i.T$.NORMAL]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.ADD]=[t.ONE,t.ONE],e[i.T$.MULTIPLY]=[t.DST_COLOR,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.SCREEN]=[t.ONE,t.ONE_MINUS_SRC_COLOR,t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.OVERLAY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.DARKEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.LIGHTEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[i.T$.COLOR_DODGE]=[t.ONE,t.ONE_MINUS_S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REVERSE_SUBTRACT,t.FUNC_ADD],e}var Oe=0,Ie=1,we=2,Ce=3,Pe=4,Ne=5,Me=function(){function t(){this.gl=null,this.stateId=0,this.polygonOffset=0,this.blendMode=i.T$.NONE,this._blendEq=!1,this.map=[],this.map[Oe]=this.setBlend,this.map[Ie]=this.setOffset,this.map[we]=this.setCullFace,this.map[Ce]=this.setDepthTest,this.map[Pe]=this.setFrontFace,this.map[Ne]=this.setDepthMask,this.checks=[],this.defaultState=new qt,this.defaultState.blend=!0}return t.prototype.contextChange=function(t){this.gl=t,this.blendModes=Ae(t),this.set(this.defaultState),this.reset()},t.prototype.set=function(t){if(t=t||this.defaultState,this.stateId!==t.data){var e=this.stateId^t.data,n=0;while(e)1&e&&this.map[n].call(this,!!(t.data&1<<n)),e>>=1,n++;this.stateId=t.data}for(n=0;n<this.checks.length;n++)this.checks[n](this,t)},t.prototype.forceState=function(t){t=t||this.defaultState;for(var e=0;e<this.map.length;e++)this.map[e].call(this,!!(t.data&1<<e));for(e=0;e<this.checks.length;e++)this.checks[e](this,t);this.stateId=t.data},t.prototype.setBlend=function(e){this.updateCheck(t.checkBlendMode,e),this.gl[e?"enable":"disable"](this.gl.BLEND)},t.prototype.setOffset=function(e){this.updateCheck(t.checkPolygonOffset,e),this.gl[e?"enable":"disable"](this.gl.POLYGON_OFFSET_FILL)},t.prototype.setDepthTest=function(t){this.gl[t?"enable":"disable"](this.gl.DEPTH_TEST)},t.prototype.setDepthMask=function(t){this.gl.depthMask(t)},t.prototype.setCullFace=function(t){this.gl[t?"enable":"disable"](this.gl.CULL_FACE)},t.prototype.setFrontFace=function(t){this.gl.frontFace(this.gl[t?"CW":"CCW"])},t.prototype.setBlendMode=function(t){if(t!==this.blendMode){this.blendMode=t;var e=this.blendModes[t],n=this.gl;2===e.length?n.blendFunc(e[0],e[1]):n.blendFuncSeparate(e[0],e[1],e[2],e[3]),6===e.length?(this._blendEq=!0,n.blendEquationSeparate(e[4],e[5])):this._blendEq&&(this._blendEq=!1,n.blendEquationSeparate(n.FUNC_ADD,n.FUNC_ADD))}},t.prototype.setPolygonOffset=function(t,e){this.gl.polygonOffset(t,e)},t.prototype.reset=function(){this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL,!1),this.forceState(this.defaultState),this._blendEq=!0,this.blendMode=-1,this.setBlendMode(0)},t.prototype.updateCheck=function(t,e){var n=this.checks.indexOf(t);e&&-1===n?this.checks.push(t):e||-1===n||this.checks.splice(n,1)},t.checkBlendMode=function(t,e){t.setBlendMode(e.blendMode)},t.checkPolygonOffset=function(t,e){t.setPolygonOffset(1,e.polygonOffset)},t.prototype.destroy=function(){this.gl=null},t}(),De=function(){function t(t){this.renderer=t,this.count=0,this.checkCount=0,this.maxIdle=r.X.GC_MAX_IDLE,this.checkCountMax=r.X.GC_MAX_CHECK_COUNT,this.mode=r.X.GC_MODE}return t.prototype.postrender=function(){this.renderer.renderingToScreen&&(this.count++,this.mode!==i.UN.MANUAL&&(this.checkCount++,this.checkCount>this.checkCountMax&&(this.checkCount=0,this.run())))},t.prototype.run=function(){for(var t=this.renderer.texture,e=t.managedTextures,n=!1,r=0;r<e.length;r++){var i=e[r];!i.framebuffer&&this.count-i.touched>this.maxIdle&&(t.destroyTexture(i,!0),e[r]=null,n=!0)}if(n){var o=0;for(r=0;r<e.length;r++)null!==e[r]&&(e[o++]=e[r]);e.length=o}},t.prototype.unload=function(t){var e=this.renderer.texture,n=t._texture;n&&!n.framebuffer&&e.destroyTexture(n);for(var r=t.children.length-1;r>=0;r--)this.unload(t.children[r])},t.prototype.destroy=function(){this.renderer=null},t}();function Le(t){var e,n,r,o,s,a,u,l,c,h,f,d,p,m,v,g,_,y,b,E,T,x,S;return"WebGL2RenderingContext"in globalThis&&t instanceof globalThis.WebGL2RenderingContext?(e={},e[i.vK.UNSIGNED_BYTE]=(n={},n[i.I2.RGBA]=t.RGBA8,n[i.I2.RGB]=t.RGB8,n[i.I2.RG]=t.RG8,n[i.I2.RED]=t.R8,n[i.I2.RGBA_INTEGER]=t.RGBA8UI,n[i.I2.RGB_INTEGER]=t.RGB8UI,n[i.I2.RG_INTEGER]=t.RG8UI,n[i.I2.RED_INTEGER]=t.R8UI,n[i.I2.ALPHA]=t.ALPHA,n[i.I2.LUMINANCE]=t.LUMINANCE,n[i.I2.LUMINANCE_ALPHA]=t.LUMINANCE_ALPHA,n),e[i.vK.BYTE]=(r={},r[i.I2.RGBA]=t.RGBA8_SNORM,r[i.I2.RGB]=t.RGB8_SNORM,r[i.I2.RG]=t.RG8_SNORM,r[i.I2.RED]=t.R8_SNORM,r[i.I2.RGBA_INTEGER]=t.RGBA8I,r[i.I2.RGB_INTEGER]=t.RGB8I,r[i.I2.RG_INTEGER]=t.RG8I,r[i.I2.RED_INTEGER]=t.R8I,r),e[i.vK.UNSIGNED_SHORT]=(o={},o[i.I2.RGBA_INTEGER]=t.RGBA16UI,o[i.I2.RGB_INTEGER]=t.RGB16UI,o[i.I2.RG_INTEGER]=t.RG16UI,o[i.I2.RED_INTEGER]=t.R16UI,o[i.I2.DEPTH_COMPONENT]=t.DEPTH_COMPONENT16,o),e[i.vK.SHORT]=(s={},s[i.I2.RGBA_INTEGER]=t.RGBA16I,s[i.I2.RGB_INTEGER]=t.RGB16I,s[i.I2.RG_INTEGER]=t.RG16I,s[i.I2.RED_INTEGER]=t.R16I,s),e[i.vK.UNSIGNED_INT]=(a={},a[i.I2.RGBA_INTEGER]=t.RGBA32UI,a[i.I2.RGB_INTEGER]=t.RGB32UI,a[i.I2.RG_INTEGER]=t.RG32UI,a[i.I2.RED_INTEGER]=t.R32UI,a[i.I2.DEPTH_COMPONENT]=t.DEPTH_COMPONENT24,a),e[i.vK.INT]=(u={},u[i.I2.RGBA_INTEGER]=t.RGBA32I,u[i.I2.RGB_INTEGER]=t.RGB32I,u[i.I2.RG_INTEGER]=t.RG32I,u[i.I2.RED_INTEGER]=t.R32I,u),e[i.vK.FLOAT]=(l={},l[i.I2.RGBA]=t.RGBA32F,l[i.I2.RGB]=t.RGB32F,l[i.I2.RG]=t.RG32F,l[i.I2.RED]=t.R32F,l[i.I2.DEPTH_COMPONENT]=t.DEPTH_COMPONENT32F,l),e[i.vK.HALF_FLOAT]=(c={},c[i.I2.RGBA]=t.RGBA16F,c[i.I2.RGB]=t.RGB16F,c[i.I2.RG]=t.RG16F,c[i.I2.RED]=t.R16F,c),e[i.vK.UNSIGNED_SHORT_5_6_5]=(h={},h[i.I2.RGB]=t.RGB565,h),e[i.vK.UNSIGNED_SHORT_4_4_4_4]=(f={},f[i.I2.RGBA]=t.RGBA4,f),e[i.vK.UNSIGNED_SHORT_5_5_5_1]=(d={},d[i.I2.RGBA]=t.RGB5_A1,d),e[i.vK.UNSIGNED_INT_2_10_10_10_REV]=(p={},p[i.I2.RGBA]=t.RGB10_A2,p[i.I2.RGBA_INTEGER]=t.RGB10_A2UI,p),e[i.vK.UNSIGNED_INT_10F_11F_11F_REV]=(m={},m[i.I2.RGB]=t.R11F_G11F_B10F,m),e[i.vK.UNSIGNED_INT_5_9_9_9_REV]=(v={},v[i.I2.RGB]=t.RGB9_E5,v),e[i.vK.UNSIGNED_INT_24_8]=(g={},g[i.I2.DEPTH_STENCIL]=t.DEPTH24_STENCIL8,g),e[i.vK.FLOAT_32_UNSIGNED_INT_24_8_REV]=(_={},_[i.I2.DEPTH_STENCIL]=t.DEPTH32F_STENCIL8,_),S=e):(y={},y[i.vK.UNSIGNED_BYTE]=(b={},b[i.I2.RGBA]=t.RGBA,b[i.I2.RGB]=t.RGB,b[i.I2.ALPHA]=t.ALPHA,b[i.I2.LUMINANCE]=t.LUMINANCE,b[i.I2.LUMINANCE_ALPHA]=t.LUMINANCE_ALPHA,b),y[i.vK.UNSIGNED_SHORT_5_6_5]=(E={},E[i.I2.RGB]=t.RGB,E),y[i.vK.UNSIGNED_SHORT_4_4_4_4]=(T={},T[i.I2.RGBA]=t.RGBA,T),y[i.vK.UNSIGNED_SHORT_5_5_5_1]=(x={},x[i.I2.RGBA]=t.RGBA,x),S=y),S}var Be=function(){function t(t){this.texture=t,this.width=-1,this.height=-1,this.dirtyId=-1,this.dirtyStyleId=-1,this.mipmap=!1,this.wrapMode=33071,this.type=i.vK.UNSIGNED_BYTE,this.internalFormat=i.I2.RGBA,this.samplerType=0}return t}(),Fe=function(){function t(t){this.renderer=t,this.boundTextures=[],this.currentLocation=-1,this.managedTextures=[],this._unknownBoundTextures=!1,this.unknownTexture=new _,this.hasIntegerTextures=!1}return t.prototype.contextChange=function(){var t=this.gl=this.renderer.gl;this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.webGLVersion=this.renderer.context.webGLVersion,this.internalFormats=Le(t);var e=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS);this.boundTextures.length=e;for(var n=0;n<e;n++)this.boundTextures[n]=null;this.emptyTextures={};var r=new Be(t.createTexture());t.bindTexture(t.TEXTURE_2D,r.texture),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,1,1,0,t.RGBA,t.UNSIGNED_BYTE,new Uint8Array(4)),this.emptyTextures[t.TEXTURE_2D]=r,this.emptyTextures[t.TEXTURE_CUBE_MAP]=new Be(t.createTexture()),t.bindTexture(t.TEXTURE_CUBE_MAP,this.emptyTextures[t.TEXTURE_CUBE_MAP].texture);for(n=0;n<6;n++)t.texImage2D(t.TEXTURE_CUBE_MAP_POSITIVE_X+n,0,t.RGBA,1,1,0,t.RGBA,t.UNSIGNED_BYTE,null);t.texParameteri(t.TEXTURE_CUBE_MAP,t.TEXTURE_MAG_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_CUBE_MAP,t.TEXTURE_MIN_FILTER,t.LINEAR);for(n=0;n<this.boundTextures.length;n++)this.bind(null,n)},t.prototype.bind=function(t,e){void 0===e&&(e=0);var n=this.gl;if(t=null===t||void 0===t?void 0:t.castToBaseTexture(),t&&t.valid&&!t.parentTextureArray){t.touched=this.renderer.textureGC.count;var r=t._glTextures[this.CONTEXT_UID]||this.initTexture(t);this.boundTextures[e]!==t&&(this.currentLocation!==e&&(this.currentLocation=e,n.activeTexture(n.TEXTURE0+e)),n.bindTexture(t.target,r.texture)),r.dirtyId!==t.dirtyId&&(this.currentLocation!==e&&(this.currentLocation=e,n.activeTexture(n.TEXTURE0+e)),this.updateTexture(t)),this.boundTextures[e]=t}else this.currentLocation!==e&&(this.currentLocation=e,n.activeTexture(n.TEXTURE0+e)),n.bindTexture(n.TEXTURE_2D,this.emptyTextures[n.TEXTURE_2D].texture),this.boundTextures[e]=null},t.prototype.reset=function(){this._unknownBoundTextures=!0,this.hasIntegerTextures=!1,this.currentLocation=-1;for(var t=0;t<this.boundTextures.length;t++)this.boundTextures[t]=this.unknownTexture},t.prototype.unbind=function(t){var e=this,n=e.gl,r=e.boundTextures;if(this._unknownBoundTextures){this._unknownBoundTextures=!1;for(var i=0;i<r.length;i++)r[i]===this.unknownTexture&&this.bind(null,i)}for(i=0;i<r.length;i++)r[i]===t&&(this.currentLocation!==i&&(n.activeTexture(n.TEXTURE0+i),this.currentLocation=i),n.bindTexture(t.target,this.emptyTextures[t.target].texture),r[i]=null)},t.prototype.ensureSamplerType=function(t){var e=this,n=e.boundTextures,r=e.hasIntegerTextures,o=e.CONTEXT_UID;if(r)for(var s=t-1;s>=0;--s){var a=n[s];if(a){var u=a._glTextures[o];u.samplerType!==i.oT.FLOAT&&this.renderer.texture.unbind(a)}}},t.prototype.initTexture=function(t){var e=new Be(this.gl.createTexture());return e.dirtyId=-1,t._glTextures[this.CONTEXT_UID]=e,this.managedTextures.push(t),t.on("dispose",this.destroyTexture,this),e},t.prototype.initTextureType=function(t,e){var n,r;e.internalFormat=null!==(r=null===(n=this.internalFormats[t.type])||void 0===n?void 0:n[t.format])&&void 0!==r?r:t.format,2===this.webGLVersion&&t.type===i.vK.HALF_FLOAT?e.type=this.gl.HALF_FLOAT:e.type=t.type},t.prototype.updateTexture=function(t){var e=t._glTextures[this.CONTEXT_UID];if(e){var n=this.renderer;if(this.initTextureType(t,e),t.resource&&t.resource.upload(n,t,e))e.samplerType!==i.oT.FLOAT&&(this.hasIntegerTextures=!0);else{var r=t.realWidth,o=t.realHeight,s=n.gl;(e.width!==r||e.height!==o||e.dirtyId<0)&&(e.width=r,e.height=o,s.texImage2D(t.target,0,e.internalFormat,r,o,0,t.format,e.type,null))}t.dirtyStyleId!==e.dirtyStyleId&&this.updateTextureStyle(t),e.dirtyId=t.dirtyId}},t.prototype.destroyTexture=function(t,e){var n=this.gl;if(t=t.castToBaseTexture(),t._glTextures[this.CONTEXT_UID]&&(this.unbind(t),n.deleteTexture(t._glTextures[this.CONTEXT_UID].texture),t.off("dispose",this.destroyTexture,this),delete t._glTextures[this.CONTEXT_UID],!e)){var r=this.managedTextures.indexOf(t);-1!==r&&(0,o.Er)(this.managedTextures,r,1)}},t.prototype.updateTextureStyle=function(t){var e=t._glTextures[this.CONTEXT_UID];e&&(t.mipmap!==i.WB.POW2&&2===this.webGLVersion||t.isPowerOfTwo?e.mipmap=t.mipmap>=1:e.mipmap=!1,2===this.webGLVersion||t.isPowerOfTwo?e.wrapMode=t.wrapMode:e.wrapMode=i.Nt.CLAMP,t.resource&&t.resource.style(this.renderer,t,e)||this.setStyle(t,e),e.dirtyStyleId=t.dirtyStyleId)},t.prototype.setStyle=function(t,e){var n=this.gl;if(e.mipmap&&t.mipmap!==i.WB.ON_MANUAL&&n.generateMipmap(t.target),n.texParameteri(t.target,n.TEXTURE_WRAP_S,e.wrapMode),n.texParameteri(t.target,n.TEXTURE_WRAP_T,e.wrapMode),e.mipmap){n.texParameteri(t.target,n.TEXTURE_MIN_FILTER,t.scaleMode===i.aH.LINEAR?n.LINEAR_MIPMAP_LINEAR:n.NEAREST_MIPMAP_NEAREST);var r=this.renderer.context.extensions.anisotropicFiltering;if(r&&t.anisotropicLevel>0&&t.scaleMode===i.aH.LINEAR){var o=Math.min(t.anisotropicLevel,n.getParameter(r.MAX_TEXTURE_MAX_ANISOTROPY_EXT));n.texParameterf(t.target,r.TEXTURE_MAX_ANISOTROPY_EXT,o)}}else n.texParameteri(t.target,n.TEXTURE_MIN_FILTER,t.scaleMode===i.aH.LINEAR?n.LINEAR:n.NEAREST);n.texParameteri(t.target,n.TEXTURE_MAG_FILTER,t.scaleMode===i.aH.LINEAR?n.LINEAR:n.NEAREST)},t.prototype.destroy=function(){this.renderer=null},t}(),Ue={__proto__:null,FilterSystem:et,BatchSystem:rt,ContextSystem:ot,FramebufferSystem:ut,GeometrySystem:ct,MaskSystem:ie,ScissorSystem:ae,StencilSystem:ue,ProjectionSystem:le,RenderTextureSystem:fe,ShaderSystem:Re,StateSystem:Me,TextureGCSystem:De,TextureSystem:Fe},Ge=new u.y3,ke=function(t){function e(e,n){void 0===e&&(e=i.N3.UNKNOWN);var s=t.call(this)||this;return n=Object.assign({},r.X.RENDER_OPTIONS,n),s.options=n,s.type=e,s.screen=new u.Ae(0,0,n.width,n.height),s.view=n.view||document.createElement("canvas"),s.resolution=n.resolution||r.X.RESOLUTION,s.useContextAlpha=n.useContextAlpha,s.autoDensity=!!n.autoDensity,s.preserveDrawingBuffer=n.preserveDrawingBuffer,s.clearBeforeRender=n.clearBeforeRender,s._backgroundColor=0,s._backgroundColorRgba=[0,0,0,1],s._backgroundColorString="#000000",s.backgroundColor=n.backgroundColor||s._backgroundColor,s.backgroundAlpha=n.backgroundAlpha,void 0!==n.transparent&&((0,o.a1)("6.0.0","Option transparent is deprecated, please use backgroundAlpha instead."),s.useContextAlpha=n.transparent,s.backgroundAlpha=n.transparent?0:1),s._lastObjectRendered=null,s.plugins={},s}return f(e,t),e.prototype.initPlugins=function(t){for(var e in t)this.plugins[e]=new t[e](this)},Object.defineProperty(e.prototype,"width",{get:function(){return this.view.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.view.height},enumerable:!1,configurable:!0}),e.prototype.resize=function(t,e){this.view.width=Math.round(t*this.resolution),this.view.height=Math.round(e*this.resolution);var n=this.view.width/this.resolution,r=this.view.height/this.resolution;this.screen.width=n,this.screen.height=r,this.autoDensity&&(this.view.style.width=n+"px",this.view.style.height=r+"px"),this.emit("resize",n,r)},e.prototype.generateTexture=function(t,e,n,r){void 0===e&&(e={}),"number"===typeof e&&((0,o.a1)("6.1.0","generateTexture options (scaleMode, resolution, region) are now object options."),e={scaleMode:e,resolution:n,region:r});var i=e.region,s=p(e,["region"]);r=i||t.getLocalBounds(null,!0),0===r.width&&(r.width=1),0===r.height&&(r.height=1);var a=F.create(d({width:r.width,height:r.height},s));return Ge.tx=-r.x,Ge.ty=-r.y,this.render(t,{renderTexture:a,clear:!1,transform:Ge,skipUpdateTransform:!!t.parent}),a},e.prototype.destroy=function(t){for(var e in this.plugins)this.plugins[e].destroy(),this.plugins[e]=null;t&&this.view.parentNode&&this.view.parentNode.removeChild(this.view);var n=this;n.plugins=null,n.type=i.N3.UNKNOWN,n.view=null,n.screen=null,n._tempDisplayObjectParent=null,n.options=null,this._backgroundColorRgba=null,this._backgroundColorString=null,this._lastObjectRendered=null},Object.defineProperty(e.prototype,"backgroundColor",{get:function(){return this._backgroundColor},set:function(t){this._backgroundColor=t,this._backgroundColorString=(0,o.XN)(t),(0,o.wK)(t,this._backgroundColorRgba)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"backgroundAlpha",{get:function(){return this._backgroundColorRgba[3]},set:function(t){this._backgroundColorRgba[3]=t},enumerable:!1,configurable:!0}),e}(o.vp),Xe=function(){function t(t){this.buffer=t||null,this.updateID=-1,this.byteLength=-1,this.refCount=0}return t}(),He=function(){function t(t){this.renderer=t,this.managedBuffers={},this.boundBufferBases={}}return t.prototype.destroy=function(){this.renderer=null},t.prototype.contextChange=function(){this.disposeAll(!0),this.gl=this.renderer.gl,this.CONTEXT_UID=this.renderer.CONTEXT_UID},t.prototype.bind=function(t){var e=this,n=e.gl,r=e.CONTEXT_UID,i=t._glBuffers[r]||this.createGLBuffer(t);n.bindBuffer(t.type,i.buffer)},t.prototype.bindBufferBase=function(t,e){var n=this,r=n.gl,i=n.CONTEXT_UID;if(this.boundBufferBases[e]!==t){var o=t._glBuffers[i]||this.createGLBuffer(t);this.boundBufferBases[e]=t,r.bindBufferBase(r.UNIFORM_BUFFER,e,o.buffer)}},t.prototype.bindBufferRange=function(t,e,n){var r=this,i=r.gl,o=r.CONTEXT_UID;n=n||0;var s=t._glBuffers[o]||this.createGLBuffer(t);i.bindBufferRange(i.UNIFORM_BUFFER,e||0,s.buffer,256*n,256)},t.prototype.update=function(t){var e=this,n=e.gl,r=e.CONTEXT_UID,i=t._glBuffers[r];if(t._updateID!==i.updateID)if(i.updateID=t._updateID,n.bindBuffer(t.type,i.buffer),i.byteLength>=t.data.byteLength)n.bufferSubData(t.type,0,t.data);else{var o=t.static?n.STATIC_DRAW:n.DYNAMIC_DRAW;i.byteLength=t.data.byteLength,n.bufferData(t.type,t.data,o)}},t.prototype.dispose=function(t,e){if(this.managedBuffers[t.id]){delete this.managedBuffers[t.id];var n=t._glBuffers[this.CONTEXT_UID],r=this.gl;t.disposeRunner.remove(this),n&&(e||r.deleteBuffer(n.buffer),delete t._glBuffers[this.CONTEXT_UID])}},t.prototype.disposeAll=function(t){for(var e=Object.keys(this.managedBuffers),n=0;n<e.length;n++)this.dispose(this.managedBuffers[e[n]],t)},t.prototype.createGLBuffer=function(t){var e=this,n=e.CONTEXT_UID,r=e.gl;return t._glBuffers[n]=new Xe(r.createBuffer()),this.managedBuffers[t.id]=t,t.disposeRunner.add(this),t._glBuffers[n]},t}(),je=function(t){function e(n){var r=t.call(this,i.N3.WEBGL,n)||this;return n=r.options,r.gl=null,r.CONTEXT_UID=0,r.runners={destroy:new s.R("destroy"),contextChange:new s.R("contextChange"),reset:new s.R("reset"),update:new s.R("update"),postrender:new s.R("postrender"),prerender:new s.R("prerender"),resize:new s.R("resize")},r.runners.contextChange.add(r),r.globalUniforms=new Z({projectionMatrix:new u.y3},!0),r.addSystem(ie,"mask").addSystem(ot,"context").addSystem(Me,"state").addSystem(Re,"shader").addSystem(Fe,"texture").addSystem(He,"buffer").addSystem(ct,"geometry").addSystem(ut,"framebuffer").addSystem(ae,"scissor").addSystem(ue,"stencil").addSystem(le,"projection").addSystem(De,"textureGC").addSystem(et,"filter").addSystem(fe,"renderTexture").addSystem(rt,"batch"),r.initPlugins(e.__plugins),r.multisample=void 0,n.context?r.context.initFromContext(n.context):r.context.initFromOptions({alpha:!!r.useContextAlpha,antialias:n.antialias,premultipliedAlpha:r.useContextAlpha&&"notMultiplied"!==r.useContextAlpha,stencil:!0,preserveDrawingBuffer:n.preserveDrawingBuffer,powerPreference:r.options.powerPreference}),r.renderingToScreen=!0,(0,o.DE)(2===r.context.webGLVersion?"WebGL 2":"WebGL 1"),r.resize(r.options.width,r.options.height),r}return f(e,t),e.create=function(t){if((0,o.HR)())return new e(t);throw new Error('WebGL unsupported in this browser, use "pixi.js-legacy" for fallback canvas2d support.')},e.prototype.contextChange=function(){var t,e=this.gl;if(1===this.context.webGLVersion){var n=e.getParameter(e.FRAMEBUFFER_BINDING);e.bindFramebuffer(e.FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.FRAMEBUFFER,n)}else{n=e.getParameter(e.DRAW_FRAMEBUFFER_BINDING);e.bindFramebuffer(e.DRAW_FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.DRAW_FRAMEBUFFER,n)}t>=i.G5.HIGH?this.multisample=i.G5.HIGH:t>=i.G5.MEDIUM?this.multisample=i.G5.MEDIUM:t>=i.G5.LOW?this.multisample=i.G5.LOW:this.multisample=i.G5.NONE},e.prototype.addSystem=function(t,e){var n=new t(this);if(this[e])throw new Error('Whoops! The name "'+e+'" is already in use');for(var r in this[e]=n,this.runners)this.runners[r].add(n);return this},e.prototype.render=function(t,e){var n,r,i,s;if(e&&(e instanceof F?((0,o.a1)("6.0.0","Renderer#render arguments changed, use options instead."),n=e,r=arguments[2],i=arguments[3],s=arguments[4]):(n=e.renderTexture,r=e.clear,i=e.transform,s=e.skipUpdateTransform)),this.renderingToScreen=!n,this.runners.prerender.emit(),this.emit("prerender"),this.projection.transform=i,!this.context.isLost){if(n||(this._lastObjectRendered=t),!s){var a=t.enableTempParent();t.updateTransform(),t.disableTempParent(a)}this.renderTexture.bind(n),this.batch.currentRenderer.start(),(void 0!==r?r:this.clearBeforeRender)&&this.renderTexture.clear(),t.render(this),this.batch.currentRenderer.flush(),n&&n.baseTexture.update(),this.runners.postrender.emit(),this.projection.transform=null,this.emit("postrender")}},e.prototype.generateTexture=function(e,n,r,i){void 0===n&&(n={});var o=t.prototype.generateTexture.call(this,e,n,r,i);return this.framebuffer.blit(),o},e.prototype.resize=function(e,n){t.prototype.resize.call(this,e,n),this.runners.resize.emit(this.screen.height,this.screen.width)},e.prototype.reset=function(){return this.runners.reset.emit(),this},e.prototype.clear=function(){this.renderTexture.bind(),this.renderTexture.clear()},e.prototype.destroy=function(e){for(var n in this.runners.destroy.emit(),this.runners)this.runners[n].destroy();t.prototype.destroy.call(this,e),this.gl=null},Object.defineProperty(e.prototype,"extract",{get:function(){return(0,o.a1)("6.0.0","Renderer#extract has been deprecated, please use Renderer#plugins.extract instead."),this.plugins.extract},enumerable:!1,configurable:!0}),e.registerPlugin=function(t,n){e.__plugins=e.__plugins||{},e.__plugins[t]=n},e}(ke);function Ve(t){return je.create(t)}var Ye="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n vTextureCoord = aTextureCoord;\n}",We="attribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 vTextureCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvec2 filterTextureCoord( void )\n{\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n}\n\nvoid main(void)\n{\n gl_Position = filterVertexPosition();\n vTextureCoord = filterTextureCoord();\n}\n",ze=Ye,$e=We,qe=(function(){function t(t){(0,o.a1)("6.1.0","System class is deprecated, implemement ISystem interface instead."),this.renderer=t}t.prototype.destroy=function(){this.renderer=null}}(),function(){function t(){this.texArray=null,this.blend=0,this.type=i.lg.TRIANGLES,this.start=0,this.size=0,this.data=null}return t}()),Ke=function(){function t(){this.elements=[],this.ids=[],this.count=0}return t.prototype.clear=function(){for(var t=0;t<this.count;t++)this.elements[t]=null;this.count=0},t}(),Ze=function(){function t(t){"number"===typeof t?this.rawBinaryData=new ArrayBuffer(t):t instanceof Uint8Array?this.rawBinaryData=t.buffer:this.rawBinaryData=t,this.uint32View=new Uint32Array(this.rawBinaryData),this.float32View=new Float32Array(this.rawBinaryData)}return Object.defineProperty(t.prototype,"int8View",{get:function(){return this._int8View||(this._int8View=new Int8Array(this.rawBinaryData)),this._int8View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"uint8View",{get:function(){return this._uint8View||(this._uint8View=new Uint8Array(this.rawBinaryData)),this._uint8View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"int16View",{get:function(){return this._int16View||(this._int16View=new Int16Array(this.rawBinaryData)),this._int16View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"uint16View",{get:function(){return this._uint16View||(this._uint16View=new Uint16Array(this.rawBinaryData)),this._uint16View},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"int32View",{get:function(){return this._int32View||(this._int32View=new Int32Array(this.rawBinaryData)),this._int32View},enumerable:!1,configurable:!0}),t.prototype.view=function(t){return this[t+"View"]},t.prototype.destroy=function(){this.rawBinaryData=null,this._int8View=null,this._uint8View=null,this._int16View=null,this._uint16View=null,this._int32View=null,this.uint32View=null,this.float32View=null},t.sizeOf=function(t){switch(t){case"int8":case"uint8":return 1;case"int16":case"uint16":return 2;case"int32":case"uint32":case"float32":return 4;default:throw new Error(t+" isn't a valid view type")}},t}(),Je=function(t){function e(e){var n=t.call(this,e)||this;return n.shaderGenerator=null,n.geometryClass=null,n.vertexSize=null,n.state=qt.for2d(),n.size=4*r.X.SPRITE_BATCH_SIZE,n._vertexCount=0,n._indexCount=0,n._bufferedElements=[],n._bufferedTextures=[],n._bufferSize=0,n._shader=null,n._packedGeometries=[],n._packedGeometryPoolSize=2,n._flushId=0,n._aBuffers={},n._iBuffers={},n.MAX_TEXTURES=1,n.renderer.on("prerender",n.onPrerender,n),e.runners.contextChange.add(n),n._dcIndex=0,n._aIndex=0,n._iIndex=0,n._attributeBuffer=null,n._indexBuffer=null,n._tempBoundTextures=[],n}return f(e,t),e.prototype.contextChange=function(){var t=this.renderer.gl;r.X.PREFER_ENV===i.Vi.WEBGL_LEGACY?this.MAX_TEXTURES=1:(this.MAX_TEXTURES=Math.min(t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS),r.X.SPRITE_MAX_TEXTURES),this.MAX_TEXTURES=Lt(this.MAX_TEXTURES,t)),this._shader=this.shaderGenerator.generateShader(this.MAX_TEXTURES);for(var e=0;e<this._packedGeometryPoolSize;e++)this._packedGeometries[e]=new this.geometryClass;this.initFlushBuffers()},e.prototype.initFlushBuffers=function(){var t=e._drawCallPool,n=e._textureArrayPool,r=this.size/4,i=Math.floor(r/this.MAX_TEXTURES)+1;while(t.length<r)t.push(new qe);while(n.length<i)n.push(new Ke);for(var o=0;o<this.MAX_TEXTURES;o++)this._tempBoundTextures[o]=null},e.prototype.onPrerender=function(){this._flushId=0},e.prototype.render=function(t){t._texture.valid&&(this._vertexCount+t.vertexData.length/2>this.size&&this.flush(),this._vertexCount+=t.vertexData.length/2,this._indexCount+=t.indices.length,this._bufferedTextures[this._bufferSize]=t._texture.baseTexture,this._bufferedElements[this._bufferSize++]=t)},e.prototype.buildTexturesAndDrawCalls=function(){var t=this,n=t._bufferedTextures,r=t.MAX_TEXTURES,i=e._textureArrayPool,o=this.renderer.batch,s=this._tempBoundTextures,a=this.renderer.textureGC.count,u=++_._globalBatch,l=0,c=i[0],h=0;o.copyBoundTextures(s,r);for(var f=0;f<this._bufferSize;++f){var d=n[f];n[f]=null,d._batchEnabled!==u&&(c.count>=r&&(o.boundArray(c,s,u,r),this.buildDrawCalls(c,h,f),h=f,c=i[++l],++u),d._batchEnabled=u,d.touched=a,c.elements[c.count++]=d)}c.count>0&&(o.boundArray(c,s,u,r),this.buildDrawCalls(c,h,this._bufferSize),++l,++u);for(f=0;f<s.length;f++)s[f]=null;_._globalBatch=u},e.prototype.buildDrawCalls=function(t,n,r){var i=this,s=i._bufferedElements,a=i._attributeBuffer,u=i._indexBuffer,l=i.vertexSize,c=e._drawCallPool,h=this._dcIndex,f=this._aIndex,d=this._iIndex,p=c[h];p.start=this._iIndex,p.texArray=t;for(var m=n;m<r;++m){var v=s[m],g=v._texture.baseTexture,_=o.YA[g.alphaMode?1:0][v.blendMode];s[m]=null,n<m&&p.blend!==_&&(p.size=d-p.start,n=m,p=c[++h],p.texArray=t,p.start=d),this.packInterleavedGeometry(v,a,u,f,d),f+=v.vertexData.length/2*l,d+=v.indices.length,p.blend=_}n<r&&(p.size=d-p.start,++h),this._dcIndex=h,this._aIndex=f,this._iIndex=d},e.prototype.bindAndClearTexArray=function(t){for(var e=this.renderer.texture,n=0;n<t.count;n++)e.bind(t.elements[n],t.ids[n]),t.elements[n]=null;t.count=0},e.prototype.updateGeometry=function(){var t=this,e=t._packedGeometries,n=t._attributeBuffer,i=t._indexBuffer;r.X.CAN_UPLOAD_SAME_BUFFER?(e[this._flushId]._buffer.update(n.rawBinaryData),e[this._flushId]._indexBuffer.update(i),this.renderer.geometry.updateBuffers()):(this._packedGeometryPoolSize<=this._flushId&&(this._packedGeometryPoolSize++,e[this._flushId]=new this.geometryClass),e[this._flushId]._buffer.update(n.rawBinaryData),e[this._flushId]._indexBuffer.update(i),this.renderer.geometry.bind(e[this._flushId]),this.renderer.geometry.updateBuffers(),this._flushId++)},e.prototype.drawBatches=function(){for(var t=this._dcIndex,n=this.renderer,r=n.gl,i=n.state,o=e._drawCallPool,s=null,a=0;a<t;a++){var u=o[a],l=u.texArray,c=u.type,h=u.size,f=u.start,d=u.blend;s!==l&&(s=l,this.bindAndClearTexArray(l)),this.state.blendMode=d,i.set(this.state),r.drawElements(c,h,r.UNSIGNED_SHORT,2*f)}},e.prototype.flush=function(){0!==this._vertexCount&&(this._attributeBuffer=this.getAttributeBuffer(this._vertexCount),this._indexBuffer=this.getIndexBuffer(this._indexCount),this._aIndex=0,this._iIndex=0,this._dcIndex=0,this.buildTexturesAndDrawCalls(),this.updateGeometry(),this.drawBatches(),this._bufferSize=0,this._vertexCount=0,this._indexCount=0)},e.prototype.start=function(){this.renderer.state.set(this.state),this.renderer.texture.ensureSamplerType(this.MAX_TEXTURES),this.renderer.shader.bind(this._shader),r.X.CAN_UPLOAD_SAME_BUFFER&&this.renderer.geometry.bind(this._packedGeometries[this._flushId])},e.prototype.stop=function(){this.flush()},e.prototype.destroy=function(){for(var e=0;e<this._packedGeometryPoolSize;e++)this._packedGeometries[e]&&this._packedGeometries[e].destroy();this.renderer.off("prerender",this.onPrerender,this),this._aBuffers=null,this._iBuffers=null,this._packedGeometries=null,this._attributeBuffer=null,this._indexBuffer=null,this._shader&&(this._shader.destroy(),this._shader=null),t.prototype.destroy.call(this)},e.prototype.getAttributeBuffer=function(t){var e=(0,o.a9)(Math.ceil(t/8)),n=(0,o.k3)(e),r=8*e;this._aBuffers.length<=n&&(this._iBuffers.length=n+1);var i=this._aBuffers[r];return i||(this._aBuffers[r]=i=new Ze(r*this.vertexSize*4)),i},e.prototype.getIndexBuffer=function(t){var e=(0,o.a9)(Math.ceil(t/12)),n=(0,o.k3)(e),r=12*e;this._iBuffers.length<=n&&(this._iBuffers.length=n+1);var i=this._iBuffers[n];return i||(this._iBuffers[n]=i=new Uint16Array(r)),i},e.prototype.packInterleavedGeometry=function(t,e,n,r,i){for(var s=e.uint32View,a=e.float32View,u=r/this.vertexSize,l=t.uvs,c=t.indices,h=t.vertexData,f=t._texture.baseTexture._batchLocation,d=Math.min(t.worldAlpha,1),p=d<1&&t._texture.baseTexture.alphaMode?(0,o.rA)(t._tintRGB,d):t._tintRGB+(255*d<<24),m=0;m<h.length;m+=2)a[r++]=h[m],a[r++]=h[m+1],a[r++]=l[m],a[r++]=l[m+1],s[r++]=p,a[r++]=f;for(m=0;m<c.length;m++)n[i++]=u+c[m]},e._drawCallPool=[],e._textureArrayPool=[],e}(nt),Qe=function(){function t(t,e){if(this.vertexSrc=t,this.fragTemplate=e,this.programCache={},this.defaultGroupCache={},e.indexOf("%count%")<0)throw new Error('Fragment template must contain "%count%".');if(e.indexOf("%forloop%")<0)throw new Error('Fragment template must contain "%forloop%".')}return t.prototype.generateShader=function(t){if(!this.programCache[t]){for(var e=new Int32Array(t),n=0;n<t;n++)e[n]=n;this.defaultGroupCache[t]=Z.from({uSamplers:e},!0);var r=this.fragTemplate;r=r.replace(/%count%/gi,""+t),r=r.replace(/%forloop%/gi,this.generateSampleSrc(t)),this.programCache[t]=new Xt(this.vertexSrc,r)}var i={tint:new Float32Array([1,1,1,1]),translationMatrix:new u.y3,default:this.defaultGroupCache[t]};return new Ht(this.programCache[t],i)},t.prototype.generateSampleSrc=function(t){var e="";e+="\n",e+="\n";for(var n=0;n<t;n++)n>0&&(e+="\nelse "),n<t-1&&(e+="if(vTextureId < "+n+".5)"),e+="\n{",e+="\n\tcolor = texture2D(uSamplers["+n+"], vTextureCoord);",e+="\n}";return e+="\n",e+="\n",e},t}(),tn=function(t){function e(e){void 0===e&&(e=!1);var n=t.call(this)||this;return n._buffer=new X(null,e,!1),n._indexBuffer=new X(null,e,!0),n.addAttribute("aVertexPosition",n._buffer,2,!1,i.vK.FLOAT).addAttribute("aTextureCoord",n._buffer,2,!1,i.vK.FLOAT).addAttribute("aColor",n._buffer,4,!0,i.vK.UNSIGNED_BYTE).addAttribute("aTextureId",n._buffer,1,!0,i.vK.FLOAT).addIndex(n._indexBuffer),n}return f(e,t),e}(z),en="precision highp float;\nattribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\nattribute vec4 aColor;\nattribute float aTextureId;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform vec4 tint;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\nvarying float vTextureId;\n\nvoid main(void){\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vTextureId = aTextureId;\n vColor = aColor * tint;\n}\n",nn="varying vec2 vTextureCoord;\nvarying vec4 vColor;\nvarying float vTextureId;\nuniform sampler2D uSamplers[%count%];\n\nvoid main(void){\n vec4 color;\n %forloop%\n gl_FragColor = color * vColor;\n}\n",rn=function(){function t(){}return t.create=function(t){var e=Object.assign({vertex:en,fragment:nn,geometryClass:tn,vertexSize:6},t),n=e.vertex,r=e.fragment,i=e.vertexSize,o=e.geometryClass;return function(t){function e(e){var s=t.call(this,e)||this;return s.shaderGenerator=new Qe(n,r),s.geometryClass=o,s.vertexSize=i,s}return f(e,t),e}(Je)},Object.defineProperty(t,"defaultVertexSrc",{get:function(){return en},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultFragmentTemplate",{get:function(){return nn},enumerable:!1,configurable:!0}),t}(),on=rn.create(),sn={},an=function(t){Object.defineProperty(sn,t,{get:function(){return(0,o.a1)("6.0.0","PIXI.systems."+t+" has moved to PIXI."+t),I[t]}})};for(var un in I)an(un);var ln={},cn=function(t){Object.defineProperty(ln,t,{get:function(){return(0,o.a1)("6.0.0","PIXI.resources."+t+" has moved to PIXI."+t),Ue[t]}})};for(var un in Ue)cn(un)},1585:function(t,e,n){"use strict";n.d(e,{YZ:function(){return s},W2:function(){return P},s$:function(){return I},Ql:function(){return w}});var r=n(1576),i=n(9658),o=n(8942); -/*! - * @pixi/display - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/display is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -r.X.SORTABLE_CHILDREN=!1;var s=function(){function t(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0,this.rect=null,this.updateID=-1}return t.prototype.isEmpty=function(){return this.minX>this.maxX||this.minY>this.maxY},t.prototype.clear=function(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0},t.prototype.getRectangle=function(t){return this.minX>this.maxX||this.minY>this.maxY?i.Ae.EMPTY:(t=t||new i.Ae(0,0,1,1),t.x=this.minX,t.y=this.minY,t.width=this.maxX-this.minX,t.height=this.maxY-this.minY,t)},t.prototype.addPoint=function(t){this.minX=Math.min(this.minX,t.x),this.maxX=Math.max(this.maxX,t.x),this.minY=Math.min(this.minY,t.y),this.maxY=Math.max(this.maxY,t.y)},t.prototype.addPointMatrix=function(t,e){var n=t.a,r=t.b,i=t.c,o=t.d,s=t.tx,a=t.ty,u=n*e.x+i*e.y+s,l=r*e.x+o*e.y+a;this.minX=Math.min(this.minX,u),this.maxX=Math.max(this.maxX,u),this.minY=Math.min(this.minY,l),this.maxY=Math.max(this.maxY,l)},t.prototype.addQuad=function(t){var e=this.minX,n=this.minY,r=this.maxX,i=this.maxY,o=t[0],s=t[1];e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,o=t[2],s=t[3],e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,o=t[4],s=t[5],e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,o=t[6],s=t[7],e=o<e?o:e,n=s<n?s:n,r=o>r?o:r,i=s>i?s:i,this.minX=e,this.minY=n,this.maxX=r,this.maxY=i},t.prototype.addFrame=function(t,e,n,r,i){this.addFrameMatrix(t.worldTransform,e,n,r,i)},t.prototype.addFrameMatrix=function(t,e,n,r,i){var o=t.a,s=t.b,a=t.c,u=t.d,l=t.tx,c=t.ty,h=this.minX,f=this.minY,d=this.maxX,p=this.maxY,m=o*e+a*n+l,v=s*e+u*n+c;h=m<h?m:h,f=v<f?v:f,d=m>d?m:d,p=v>p?v:p,m=o*r+a*n+l,v=s*r+u*n+c,h=m<h?m:h,f=v<f?v:f,d=m>d?m:d,p=v>p?v:p,m=o*e+a*i+l,v=s*e+u*i+c,h=m<h?m:h,f=v<f?v:f,d=m>d?m:d,p=v>p?v:p,m=o*r+a*i+l,v=s*r+u*i+c,h=m<h?m:h,f=v<f?v:f,d=m>d?m:d,p=v>p?v:p,this.minX=h,this.minY=f,this.maxX=d,this.maxY=p},t.prototype.addVertexData=function(t,e,n){for(var r=this.minX,i=this.minY,o=this.maxX,s=this.maxY,a=e;a<n;a+=2){var u=t[a],l=t[a+1];r=u<r?u:r,i=l<i?l:i,o=u>o?u:o,s=l>s?l:s}this.minX=r,this.minY=i,this.maxX=o,this.maxY=s},t.prototype.addVertices=function(t,e,n,r){this.addVerticesMatrix(t.worldTransform,e,n,r)},t.prototype.addVerticesMatrix=function(t,e,n,r,i,o){void 0===i&&(i=0),void 0===o&&(o=i);for(var s=t.a,a=t.b,u=t.c,l=t.d,c=t.tx,h=t.ty,f=this.minX,d=this.minY,p=this.maxX,m=this.maxY,v=n;v<r;v+=2){var g=e[v],_=e[v+1],y=s*g+u*_+c,b=l*_+a*g+h;f=Math.min(f,y-i),p=Math.max(p,y+i),d=Math.min(d,b-o),m=Math.max(m,b+o)}this.minX=f,this.minY=d,this.maxX=p,this.maxY=m},t.prototype.addBounds=function(t){var e=this.minX,n=this.minY,r=this.maxX,i=this.maxY;this.minX=t.minX<e?t.minX:e,this.minY=t.minY<n?t.minY:n,this.maxX=t.maxX>r?t.maxX:r,this.maxY=t.maxY>i?t.maxY:i},t.prototype.addBoundsMask=function(t,e){var n=t.minX>e.minX?t.minX:e.minX,r=t.minY>e.minY?t.minY:e.minY,i=t.maxX<e.maxX?t.maxX:e.maxX,o=t.maxY<e.maxY?t.maxY:e.maxY;if(n<=i&&r<=o){var s=this.minX,a=this.minY,u=this.maxX,l=this.maxY;this.minX=n<s?n:s,this.minY=r<a?r:a,this.maxX=i>u?i:u,this.maxY=o>l?o:l}},t.prototype.addBoundsMatrix=function(t,e){this.addFrameMatrix(e,t.minX,t.minY,t.maxX,t.maxY)},t.prototype.addBoundsArea=function(t,e){var n=t.minX>e.x?t.minX:e.x,r=t.minY>e.y?t.minY:e.y,i=t.maxX<e.x+e.width?t.maxX:e.x+e.width,o=t.maxY<e.y+e.height?t.maxY:e.y+e.height;if(n<=i&&r<=o){var s=this.minX,a=this.minY,u=this.maxX,l=this.maxY;this.minX=n<s?n:s,this.minY=r<a?r:a,this.maxX=i>u?i:u,this.maxY=o>l?o:l}},t.prototype.pad=function(t,e){void 0===t&&(t=0),void 0===e&&(e=t),this.isEmpty()||(this.minX-=t,this.maxX+=t,this.minY-=e,this.maxY+=e)},t.prototype.addFramePad=function(t,e,n,r,i,o){t-=i,e-=o,n+=i,r+=o,this.minX=this.minX<t?this.minX:t,this.maxX=this.maxX>n?this.maxX:n,this.minY=this.minY<e?this.minY:e,this.maxY=this.maxY>r?this.maxY:r},t}(),a=function(t,e){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},a(t,e)}; -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */function u(t,e){function n(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var l,c,h,f,d,p,m,v,g,_,y,b,E,T,x,S,R,A,O,I=function(t){function e(){var e=t.call(this)||this;return e.tempDisplayObjectParent=null,e.transform=new i.wx,e.alpha=1,e.visible=!0,e.renderable=!0,e.cullable=!1,e.cullArea=null,e.parent=null,e.worldAlpha=1,e._lastSortedIndex=0,e._zIndex=0,e.filterArea=null,e.filters=null,e._enabledFilters=null,e._bounds=new s,e._localBounds=null,e._boundsID=0,e._boundsRect=null,e._localBoundsRect=null,e._mask=null,e._maskRefCount=0,e._destroyed=!1,e.isSprite=!1,e.isMask=!1,e}return u(e,t),e.mixin=function(t){for(var n=Object.keys(t),r=0;r<n.length;++r){var i=n[r];Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t,i))}},Object.defineProperty(e.prototype,"destroyed",{get:function(){return this._destroyed},enumerable:!1,configurable:!0}),e.prototype._recursivePostUpdateTransform=function(){this.parent?(this.parent._recursivePostUpdateTransform(),this.transform.updateTransform(this.parent.transform)):this.transform.updateTransform(this._tempDisplayObjectParent.transform)},e.prototype.updateTransform=function(){this._boundsID++,this.transform.updateTransform(this.parent.transform),this.worldAlpha=this.alpha*this.parent.worldAlpha},e.prototype.getBounds=function(t,e){return t||(this.parent?(this._recursivePostUpdateTransform(),this.updateTransform()):(this.parent=this._tempDisplayObjectParent,this.updateTransform(),this.parent=null)),this._bounds.updateID!==this._boundsID&&(this.calculateBounds(),this._bounds.updateID=this._boundsID),e||(this._boundsRect||(this._boundsRect=new i.Ae),e=this._boundsRect),this._bounds.getRectangle(e)},e.prototype.getLocalBounds=function(t){t||(this._localBoundsRect||(this._localBoundsRect=new i.Ae),t=this._localBoundsRect),this._localBounds||(this._localBounds=new s);var e=this.transform,n=this.parent;this.parent=null,this.transform=this._tempDisplayObjectParent.transform;var r=this._bounds,o=this._boundsID;this._bounds=this._localBounds;var a=this.getBounds(!1,t);return this.parent=n,this.transform=e,this._bounds=r,this._bounds.updateID+=this._boundsID-o,a},e.prototype.toGlobal=function(t,e,n){return void 0===n&&(n=!1),n||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.apply(t,e)},e.prototype.toLocal=function(t,e,n,r){return e&&(t=e.toGlobal(t,n,r)),r||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.applyInverse(t,n)},e.prototype.setParent=function(t){if(!t||!t.addChild)throw new Error("setParent: Argument must be a Container");return t.addChild(this),t},e.prototype.setTransform=function(t,e,n,r,i,o,s,a,u){return void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=1),void 0===r&&(r=1),void 0===i&&(i=0),void 0===o&&(o=0),void 0===s&&(s=0),void 0===a&&(a=0),void 0===u&&(u=0),this.position.x=t,this.position.y=e,this.scale.x=n||1,this.scale.y=r||1,this.rotation=i,this.skew.x=o,this.skew.y=s,this.pivot.x=a,this.pivot.y=u,this},e.prototype.destroy=function(t){this.parent&&this.parent.removeChild(this),this.emit("destroyed"),this.removeAllListeners(),this.transform=null,this.parent=null,this._bounds=null,this.mask=null,this.cullArea=null,this.filters=null,this.filterArea=null,this.hitArea=null,this.interactive=!1,this.interactiveChildren=!1,this._destroyed=!0},Object.defineProperty(e.prototype,"_tempDisplayObjectParent",{get:function(){return null===this.tempDisplayObjectParent&&(this.tempDisplayObjectParent=new w),this.tempDisplayObjectParent},enumerable:!1,configurable:!0}),e.prototype.enableTempParent=function(){var t=this.parent;return this.parent=this._tempDisplayObjectParent,t},e.prototype.disableTempParent=function(t){this.parent=t},Object.defineProperty(e.prototype,"x",{get:function(){return this.position.x},set:function(t){this.transform.position.x=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"y",{get:function(){return this.position.y},set:function(t){this.transform.position.y=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"worldTransform",{get:function(){return this.transform.worldTransform},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"localTransform",{get:function(){return this.transform.localTransform},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"position",{get:function(){return this.transform.position},set:function(t){this.transform.position.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"scale",{get:function(){return this.transform.scale},set:function(t){this.transform.scale.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"pivot",{get:function(){return this.transform.pivot},set:function(t){this.transform.pivot.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"skew",{get:function(){return this.transform.skew},set:function(t){this.transform.skew.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rotation",{get:function(){return this.transform.rotation},set:function(t){this.transform.rotation=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angle",{get:function(){return this.transform.rotation*i.jl},set:function(t){this.transform.rotation=t*i.ZX},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"zIndex",{get:function(){return this._zIndex},set:function(t){this._zIndex=t,this.parent&&(this.parent.sortDirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"worldVisible",{get:function(){var t=this;do{if(!t.visible)return!1;t=t.parent}while(t);return!0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"mask",{get:function(){return this._mask},set:function(t){if(this._mask!==t){if(this._mask){var e=this._mask.maskObject||this._mask;e._maskRefCount--,0===e._maskRefCount&&(e.renderable=!0,e.isMask=!1)}if(this._mask=t,this._mask){e=this._mask.maskObject||this._mask;0===e._maskRefCount&&(e.renderable=!1,e.isMask=!0),e._maskRefCount++}}},enumerable:!1,configurable:!0}),e}(o.vp),w=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.sortDirty=null,e}return u(e,t),e}(I);function C(t,e){return t.zIndex===e.zIndex?t._lastSortedIndex-e._lastSortedIndex:t.zIndex-e.zIndex}I.prototype.displayObjectUpdateTransform=I.prototype.updateTransform,function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"}(l||(l={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(c||(c={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(h||(h={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(f||(f={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(d||(d={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(p||(p={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(m||(m={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(v||(v={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(g||(g={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(_||(_={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(y||(y={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(b||(b={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(E||(E={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(T||(T={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(x||(x={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(S||(S={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(R||(R={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(A||(A={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(O||(O={}));var P=function(t){function e(){var e=t.call(this)||this;return e.children=[],e.sortableChildren=r.X.SORTABLE_CHILDREN,e.sortDirty=!1,e}return u(e,t),e.prototype.onChildrenChange=function(t){},e.prototype.addChild=function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];if(e.length>1)for(var r=0;r<e.length;r++)this.addChild(e[r]);else{var i=e[0];i.parent&&i.parent.removeChild(i),i.parent=this,this.sortDirty=!0,i.transform._parentID=-1,this.children.push(i),this._boundsID++,this.onChildrenChange(this.children.length-1),this.emit("childAdded",i,this,this.children.length-1),i.emit("added",this)}return e[0]},e.prototype.addChildAt=function(t,e){if(e<0||e>this.children.length)throw new Error(t+"addChildAt: The index "+e+" supplied is out of bounds "+this.children.length);return t.parent&&t.parent.removeChild(t),t.parent=this,this.sortDirty=!0,t.transform._parentID=-1,this.children.splice(e,0,t),this._boundsID++,this.onChildrenChange(e),t.emit("added",this),this.emit("childAdded",t,this,e),t},e.prototype.swapChildren=function(t,e){if(t!==e){var n=this.getChildIndex(t),r=this.getChildIndex(e);this.children[n]=e,this.children[r]=t,this.onChildrenChange(n<r?n:r)}},e.prototype.getChildIndex=function(t){var e=this.children.indexOf(t);if(-1===e)throw new Error("The supplied DisplayObject must be a child of the caller");return e},e.prototype.setChildIndex=function(t,e){if(e<0||e>=this.children.length)throw new Error("The index "+e+" supplied is out of bounds "+this.children.length);var n=this.getChildIndex(t);(0,o.Er)(this.children,n,1),this.children.splice(e,0,t),this.onChildrenChange(e)},e.prototype.getChildAt=function(t){if(t<0||t>=this.children.length)throw new Error("getChildAt: Index ("+t+") does not exist.");return this.children[t]},e.prototype.removeChild=function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];if(e.length>1)for(var r=0;r<e.length;r++)this.removeChild(e[r]);else{var i=e[0],s=this.children.indexOf(i);if(-1===s)return null;i.parent=null,i.transform._parentID=-1,(0,o.Er)(this.children,s,1),this._boundsID++,this.onChildrenChange(s),i.emit("removed",this),this.emit("childRemoved",i,this,s)}return e[0]},e.prototype.removeChildAt=function(t){var e=this.getChildAt(t);return e.parent=null,e.transform._parentID=-1,(0,o.Er)(this.children,t,1),this._boundsID++,this.onChildrenChange(t),e.emit("removed",this),this.emit("childRemoved",e,this,t),e},e.prototype.removeChildren=function(t,e){void 0===t&&(t=0),void 0===e&&(e=this.children.length);var n,r=t,i=e,o=i-r;if(o>0&&o<=i){n=this.children.splice(r,o);for(var s=0;s<n.length;++s)n[s].parent=null,n[s].transform&&(n[s].transform._parentID=-1);this._boundsID++,this.onChildrenChange(t);for(s=0;s<n.length;++s)n[s].emit("removed",this),this.emit("childRemoved",n[s],this,s);return n}if(0===o&&0===this.children.length)return[];throw new RangeError("removeChildren: numeric values are outside the acceptable range.")},e.prototype.sortChildren=function(){for(var t=!1,e=0,n=this.children.length;e<n;++e){var r=this.children[e];r._lastSortedIndex=e,t||0===r.zIndex||(t=!0)}t&&this.children.length>1&&this.children.sort(C),this.sortDirty=!1},e.prototype.updateTransform=function(){this.sortableChildren&&this.sortDirty&&this.sortChildren(),this._boundsID++,this.transform.updateTransform(this.parent.transform),this.worldAlpha=this.alpha*this.parent.worldAlpha;for(var t=0,e=this.children.length;t<e;++t){var n=this.children[t];n.visible&&n.updateTransform()}},e.prototype.calculateBounds=function(){this._bounds.clear(),this._calculateBounds();for(var t=0;t<this.children.length;t++){var e=this.children[t];if(e.visible&&e.renderable)if(e.calculateBounds(),e._mask){var n=e._mask.maskObject||e._mask;n.calculateBounds(),this._bounds.addBoundsMask(e._bounds,n._bounds)}else e.filterArea?this._bounds.addBoundsArea(e._bounds,e.filterArea):this._bounds.addBounds(e._bounds)}this._bounds.updateID=this._boundsID},e.prototype.getLocalBounds=function(e,n){void 0===n&&(n=!1);var r=t.prototype.getLocalBounds.call(this,e);if(!n)for(var i=0,o=this.children.length;i<o;++i){var s=this.children[i];s.visible&&s.updateTransform()}return r},e.prototype._calculateBounds=function(){},e.prototype._renderWithCulling=function(t){var n=t.renderTexture.sourceFrame;if(n.width>0&&n.height>0){var r,i;if(this.cullArea?(r=this.cullArea,i=this.worldTransform):this._render!==e.prototype._render&&(r=this.getBounds(!0)),r&&n.intersects(r,i))this._render(t);else if(this.cullArea)return;for(var o=0,s=this.children.length;o<s;++o){var a=this.children[o],u=a.cullable;a.cullable=u||!this.cullArea,a.render(t),a.cullable=u}}},e.prototype.render=function(t){if(this.visible&&!(this.worldAlpha<=0)&&this.renderable)if(this._mask||this.filters&&this.filters.length)this.renderAdvanced(t);else if(this.cullable)this._renderWithCulling(t);else{this._render(t);for(var e=0,n=this.children.length;e<n;++e)this.children[e].render(t)}},e.prototype.renderAdvanced=function(t){var e=this.filters,n=this._mask;if(e){this._enabledFilters||(this._enabledFilters=[]),this._enabledFilters.length=0;for(var r=0;r<e.length;r++)e[r].enabled&&this._enabledFilters.push(e[r])}var i=e&&this._enabledFilters&&this._enabledFilters.length||n&&(!n.isMaskData||n.enabled&&(n.autoDetect||n.type!==R.NONE));if(i&&t.batch.flush(),e&&this._enabledFilters&&this._enabledFilters.length&&t.filter.push(this,this._enabledFilters),n&&t.mask.push(this,this._mask),this.cullable)this._renderWithCulling(t);else{this._render(t);r=0;for(var o=this.children.length;r<o;++r)this.children[r].render(t)}i&&t.batch.flush(),n&&t.mask.pop(this),e&&this._enabledFilters&&this._enabledFilters.length&&t.filter.pop()},e.prototype._render=function(t){},e.prototype.destroy=function(e){t.prototype.destroy.call(this),this.sortDirty=!1;var n="boolean"===typeof e?e:e&&e.children,r=this.removeChildren(0,this.children.length);if(n)for(var i=0;i<r.length;++i)r[i].destroy(e)},Object.defineProperty(e.prototype,"width",{get:function(){return this.scale.x*this.getLocalBounds().width},set:function(t){var e=this.getLocalBounds().width;this.scale.x=0!==e?t/e:1,this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.scale.y*this.getLocalBounds().height},set:function(t){var e=this.getLocalBounds().height;this.scale.y=0!==e?t/e:1,this._height=t},enumerable:!1,configurable:!0}),e}(I);P.prototype.containerUpdateTransform=P.prototype.updateTransform},9658:function(t,e,n){"use strict";n.d(e,{Cd:function(){return c},ZX:function(){return s},Pj:function(){return h},y3:function(){return m},AB:function(){return p},_b:function(){return i},E9:function(){return a},mg:function(){return f},jl:function(){return o},Ae:function(){return l},c9:function(){return d},HS:function(){return r},wx:function(){return R},Lv:function(){return S}}); -/*! - * @pixi/math - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/math is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var r,i=2*Math.PI,o=180/Math.PI,s=Math.PI/180;(function(t){t[t["POLY"]=0]="POLY",t[t["RECT"]=1]="RECT",t[t["CIRC"]=2]="CIRC",t[t["ELIP"]=3]="ELIP",t[t["RREC"]=4]="RREC"})(r||(r={}));var a=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.x=0,this.y=0,this.x=t,this.y=e}return t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.copyFrom=function(t){return this.set(t.x,t.y),this},t.prototype.copyTo=function(t){return t.set(this.x,this.y),t},t.prototype.equals=function(t){return t.x===this.x&&t.y===this.y},t.prototype.set=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=t),this.x=t,this.y=e,this},t.prototype.toString=function(){return"[@pixi/math:Point x="+this.x+" y="+this.y+"]"},t}(),u=[new a,new a,new a,new a],l=function(){function t(t,e,n,i){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=0),this.x=Number(t),this.y=Number(e),this.width=Number(n),this.height=Number(i),this.type=r.RECT}return Object.defineProperty(t.prototype,"left",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"right",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"top",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"bottom",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),Object.defineProperty(t,"EMPTY",{get:function(){return new t(0,0,0,0)},enumerable:!1,configurable:!0}),t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.copyFrom=function(t){return this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height,this},t.prototype.copyTo=function(t){return t.x=this.x,t.y=this.y,t.width=this.width,t.height=this.height,t},t.prototype.contains=function(t,e){return!(this.width<=0||this.height<=0)&&(t>=this.x&&t<this.x+this.width&&e>=this.y&&e<this.y+this.height)},t.prototype.intersects=function(t,e){if(!e){var n=this.x<t.x?t.x:this.x,r=this.right>t.right?t.right:this.right;if(r<=n)return!1;var i=this.y<t.y?t.y:this.y,o=this.bottom>t.bottom?t.bottom:this.bottom;return o>i}var s=this.left,a=this.right,l=this.top,c=this.bottom;if(a<=s||c<=l)return!1;var h=u[0].set(t.left,t.top),f=u[1].set(t.left,t.bottom),d=u[2].set(t.right,t.top),p=u[3].set(t.right,t.bottom);if(d.x<=h.x||f.y<=h.y)return!1;var m=Math.sign(e.a*e.d-e.b*e.c);if(0===m)return!1;if(e.apply(h,h),e.apply(f,f),e.apply(d,d),e.apply(p,p),Math.max(h.x,f.x,d.x,p.x)<=s||Math.min(h.x,f.x,d.x,p.x)>=a||Math.max(h.y,f.y,d.y,p.y)<=l||Math.min(h.y,f.y,d.y,p.y)>=c)return!1;var v=m*(f.y-h.y),g=m*(h.x-f.x),_=v*s+g*l,y=v*a+g*l,b=v*s+g*c,E=v*a+g*c;if(Math.max(_,y,b,E)<=v*h.x+g*h.y||Math.min(_,y,b,E)>=v*p.x+g*p.y)return!1;var T=m*(h.y-d.y),x=m*(d.x-h.x),S=T*s+x*l,R=T*a+x*l,A=T*s+x*c,O=T*a+x*c;return!(Math.max(S,R,A,O)<=T*h.x+x*h.y||Math.min(S,R,A,O)>=T*p.x+x*p.y)},t.prototype.pad=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=t),this.x-=t,this.y-=e,this.width+=2*t,this.height+=2*e,this},t.prototype.fit=function(t){var e=Math.max(this.x,t.x),n=Math.min(this.x+this.width,t.x+t.width),r=Math.max(this.y,t.y),i=Math.min(this.y+this.height,t.y+t.height);return this.x=e,this.width=Math.max(n-e,0),this.y=r,this.height=Math.max(i-r,0),this},t.prototype.ceil=function(t,e){void 0===t&&(t=1),void 0===e&&(e=.001);var n=Math.ceil((this.x+this.width-e)*t)/t,r=Math.ceil((this.y+this.height-e)*t)/t;return this.x=Math.floor((this.x+e)*t)/t,this.y=Math.floor((this.y+e)*t)/t,this.width=n-this.x,this.height=r-this.y,this},t.prototype.enlarge=function(t){var e=Math.min(this.x,t.x),n=Math.max(this.x+this.width,t.x+t.width),r=Math.min(this.y,t.y),i=Math.max(this.y+this.height,t.y+t.height);return this.x=e,this.width=n-e,this.y=r,this.height=i-r,this},t.prototype.toString=function(){return"[@pixi/math:Rectangle x="+this.x+" y="+this.y+" width="+this.width+" height="+this.height+"]"},t}(),c=function(){function t(t,e,n){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),this.x=t,this.y=e,this.radius=n,this.type=r.CIRC}return t.prototype.clone=function(){return new t(this.x,this.y,this.radius)},t.prototype.contains=function(t,e){if(this.radius<=0)return!1;var n=this.radius*this.radius,r=this.x-t,i=this.y-e;return r*=r,i*=i,r+i<=n},t.prototype.getBounds=function(){return new l(this.x-this.radius,this.y-this.radius,2*this.radius,2*this.radius)},t.prototype.toString=function(){return"[@pixi/math:Circle x="+this.x+" y="+this.y+" radius="+this.radius+"]"},t}(),h=function(){function t(t,e,n,i){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=0),this.x=t,this.y=e,this.width=n,this.height=i,this.type=r.ELIP}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;var n=(t-this.x)/this.width,r=(e-this.y)/this.height;return n*=n,r*=r,n+r<=1},t.prototype.getBounds=function(){return new l(this.x-this.width,this.y-this.height,this.width,this.height)},t.prototype.toString=function(){return"[@pixi/math:Ellipse x="+this.x+" y="+this.y+" width="+this.width+" height="+this.height+"]"},t}(),f=function(){function t(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];var i=Array.isArray(e[0])?e[0]:e;if("number"!==typeof i[0]){for(var o=[],s=0,a=i.length;s<a;s++)o.push(i[s].x,i[s].y);i=o}this.points=i,this.type=r.POLY,this.closeStroke=!0}return t.prototype.clone=function(){var e=this.points.slice(),n=new t(e);return n.closeStroke=this.closeStroke,n},t.prototype.contains=function(t,e){for(var n=!1,r=this.points.length/2,i=0,o=r-1;i<r;o=i++){var s=this.points[2*i],a=this.points[2*i+1],u=this.points[2*o],l=this.points[2*o+1],c=a>e!==l>e&&t<(e-a)/(l-a)*(u-s)+s;c&&(n=!n)}return n},t.prototype.toString=function(){return"[@pixi/math:PolygoncloseStroke="+this.closeStroke+"points="+this.points.reduce((function(t,e){return t+", "+e}),"")+"]"},t}(),d=function(){function t(t,e,n,i,o){void 0===t&&(t=0),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=0),void 0===o&&(o=20),this.x=t,this.y=e,this.width=n,this.height=i,this.radius=o,this.type=r.RREC}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height,this.radius)},t.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;if(t>=this.x&&t<=this.x+this.width&&e>=this.y&&e<=this.y+this.height){var n=Math.max(0,Math.min(this.radius,Math.min(this.width,this.height)/2));if(e>=this.y+n&&e<=this.y+this.height-n||t>=this.x+n&&t<=this.x+this.width-n)return!0;var r=t-(this.x+n),i=e-(this.y+n),o=n*n;if(r*r+i*i<=o)return!0;if(r=t-(this.x+this.width-n),r*r+i*i<=o)return!0;if(i=e-(this.y+this.height-n),r*r+i*i<=o)return!0;if(r=t-(this.x+n),r*r+i*i<=o)return!0}return!1},t.prototype.toString=function(){return"[@pixi/math:RoundedRectangle x="+this.x+" y="+this.y+"width="+this.width+" height="+this.height+" radius="+this.radius+"]"},t}(),p=function(){function t(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),this._x=n,this._y=r,this.cb=t,this.scope=e}return t.prototype.clone=function(e,n){return void 0===e&&(e=this.cb),void 0===n&&(n=this.scope),new t(e,n,this._x,this._y)},t.prototype.set=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=t),this._x===t&&this._y===e||(this._x=t,this._y=e,this.cb.call(this.scope)),this},t.prototype.copyFrom=function(t){return this._x===t.x&&this._y===t.y||(this._x=t.x,this._y=t.y,this.cb.call(this.scope)),this},t.prototype.copyTo=function(t){return t.set(this._x,this._y),t},t.prototype.equals=function(t){return t.x===this._x&&t.y===this._y},t.prototype.toString=function(){return"[@pixi/math:ObservablePoint x=0 y=0 scope="+this.scope+"]"},Object.defineProperty(t.prototype,"x",{get:function(){return this._x},set:function(t){this._x!==t&&(this._x=t,this.cb.call(this.scope))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"y",{get:function(){return this._y},set:function(t){this._y!==t&&(this._y=t,this.cb.call(this.scope))},enumerable:!1,configurable:!0}),t}(),m=function(){function t(t,e,n,r,i,o){void 0===t&&(t=1),void 0===e&&(e=0),void 0===n&&(n=0),void 0===r&&(r=1),void 0===i&&(i=0),void 0===o&&(o=0),this.array=null,this.a=t,this.b=e,this.c=n,this.d=r,this.tx=i,this.ty=o}return t.prototype.fromArray=function(t){this.a=t[0],this.b=t[1],this.c=t[3],this.d=t[4],this.tx=t[2],this.ty=t[5]},t.prototype.set=function(t,e,n,r,i,o){return this.a=t,this.b=e,this.c=n,this.d=r,this.tx=i,this.ty=o,this},t.prototype.toArray=function(t,e){this.array||(this.array=new Float32Array(9));var n=e||this.array;return t?(n[0]=this.a,n[1]=this.b,n[2]=0,n[3]=this.c,n[4]=this.d,n[5]=0,n[6]=this.tx,n[7]=this.ty,n[8]=1):(n[0]=this.a,n[1]=this.c,n[2]=this.tx,n[3]=this.b,n[4]=this.d,n[5]=this.ty,n[6]=0,n[7]=0,n[8]=1),n},t.prototype.apply=function(t,e){e=e||new a;var n=t.x,r=t.y;return e.x=this.a*n+this.c*r+this.tx,e.y=this.b*n+this.d*r+this.ty,e},t.prototype.applyInverse=function(t,e){e=e||new a;var n=1/(this.a*this.d+this.c*-this.b),r=t.x,i=t.y;return e.x=this.d*n*r+-this.c*n*i+(this.ty*this.c-this.tx*this.d)*n,e.y=this.a*n*i+-this.b*n*r+(-this.ty*this.a+this.tx*this.b)*n,e},t.prototype.translate=function(t,e){return this.tx+=t,this.ty+=e,this},t.prototype.scale=function(t,e){return this.a*=t,this.d*=e,this.c*=t,this.b*=e,this.tx*=t,this.ty*=e,this},t.prototype.rotate=function(t){var e=Math.cos(t),n=Math.sin(t),r=this.a,i=this.c,o=this.tx;return this.a=r*e-this.b*n,this.b=r*n+this.b*e,this.c=i*e-this.d*n,this.d=i*n+this.d*e,this.tx=o*e-this.ty*n,this.ty=o*n+this.ty*e,this},t.prototype.append=function(t){var e=this.a,n=this.b,r=this.c,i=this.d;return this.a=t.a*e+t.b*r,this.b=t.a*n+t.b*i,this.c=t.c*e+t.d*r,this.d=t.c*n+t.d*i,this.tx=t.tx*e+t.ty*r+this.tx,this.ty=t.tx*n+t.ty*i+this.ty,this},t.prototype.setTransform=function(t,e,n,r,i,o,s,a,u){return this.a=Math.cos(s+u)*i,this.b=Math.sin(s+u)*i,this.c=-Math.sin(s-a)*o,this.d=Math.cos(s-a)*o,this.tx=t-(n*this.a+r*this.c),this.ty=e-(n*this.b+r*this.d),this},t.prototype.prepend=function(t){var e=this.tx;if(1!==t.a||0!==t.b||0!==t.c||1!==t.d){var n=this.a,r=this.c;this.a=n*t.a+this.b*t.c,this.b=n*t.b+this.b*t.d,this.c=r*t.a+this.d*t.c,this.d=r*t.b+this.d*t.d}return this.tx=e*t.a+this.ty*t.c+t.tx,this.ty=e*t.b+this.ty*t.d+t.ty,this},t.prototype.decompose=function(t){var e=this.a,n=this.b,r=this.c,o=this.d,s=t.pivot,a=-Math.atan2(-r,o),u=Math.atan2(n,e),l=Math.abs(a+u);return l<1e-5||Math.abs(i-l)<1e-5?(t.rotation=u,t.skew.x=t.skew.y=0):(t.rotation=0,t.skew.x=a,t.skew.y=u),t.scale.x=Math.sqrt(e*e+n*n),t.scale.y=Math.sqrt(r*r+o*o),t.position.x=this.tx+(s.x*e+s.y*r),t.position.y=this.ty+(s.x*n+s.y*o),t},t.prototype.invert=function(){var t=this.a,e=this.b,n=this.c,r=this.d,i=this.tx,o=t*r-e*n;return this.a=r/o,this.b=-e/o,this.c=-n/o,this.d=t/o,this.tx=(n*this.ty-r*i)/o,this.ty=-(t*this.ty-e*i)/o,this},t.prototype.identity=function(){return this.a=1,this.b=0,this.c=0,this.d=1,this.tx=0,this.ty=0,this},t.prototype.clone=function(){var e=new t;return e.a=this.a,e.b=this.b,e.c=this.c,e.d=this.d,e.tx=this.tx,e.ty=this.ty,e},t.prototype.copyTo=function(t){return t.a=this.a,t.b=this.b,t.c=this.c,t.d=this.d,t.tx=this.tx,t.ty=this.ty,t},t.prototype.copyFrom=function(t){return this.a=t.a,this.b=t.b,this.c=t.c,this.d=t.d,this.tx=t.tx,this.ty=t.ty,this},t.prototype.toString=function(){return"[@pixi/math:Matrix a="+this.a+" b="+this.b+" c="+this.c+" d="+this.d+" tx="+this.tx+" ty="+this.ty+"]"},Object.defineProperty(t,"IDENTITY",{get:function(){return new t},enumerable:!1,configurable:!0}),Object.defineProperty(t,"TEMP_MATRIX",{get:function(){return new t},enumerable:!1,configurable:!0}),t}(),v=[1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1,0,1],g=[0,1,1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1],_=[0,-1,-1,-1,0,1,1,1,0,1,1,1,0,-1,-1,-1],y=[1,1,0,-1,-1,-1,0,1,-1,-1,0,1,1,1,0,-1],b=[],E=[],T=Math.sign;function x(){for(var t=0;t<16;t++){var e=[];b.push(e);for(var n=0;n<16;n++)for(var r=T(v[t]*v[n]+_[t]*g[n]),i=T(g[t]*v[n]+y[t]*g[n]),o=T(v[t]*_[n]+_[t]*y[n]),s=T(g[t]*_[n]+y[t]*y[n]),a=0;a<16;a++)if(v[a]===r&&g[a]===i&&_[a]===o&&y[a]===s){e.push(a);break}}for(t=0;t<16;t++){var u=new m;u.set(v[t],g[t],_[t],y[t],0,0),E.push(u)}}x();var S={E:0,SE:1,S:2,SW:3,W:4,NW:5,N:6,NE:7,MIRROR_VERTICAL:8,MAIN_DIAGONAL:10,MIRROR_HORIZONTAL:12,REVERSE_DIAGONAL:14,uX:function(t){return v[t]},uY:function(t){return g[t]},vX:function(t){return _[t]},vY:function(t){return y[t]},inv:function(t){return 8&t?15&t:7&-t},add:function(t,e){return b[t][e]},sub:function(t,e){return b[t][S.inv(e)]},rotate180:function(t){return 4^t},isVertical:function(t){return 2===(3&t)},byDirection:function(t,e){return 2*Math.abs(t)<=Math.abs(e)?e>=0?S.S:S.N:2*Math.abs(e)<=Math.abs(t)?t>0?S.E:S.W:e>0?t>0?S.SE:S.SW:t>0?S.NE:S.NW},matrixAppendRotationInv:function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0);var i=E[S.inv(e)];i.tx=n,i.ty=r,t.append(i)}},R=function(){function t(){this.worldTransform=new m,this.localTransform=new m,this.position=new p(this.onChange,this,0,0),this.scale=new p(this.onChange,this,1,1),this.pivot=new p(this.onChange,this,0,0),this.skew=new p(this.updateSkew,this,0,0),this._rotation=0,this._cx=1,this._sx=0,this._cy=0,this._sy=1,this._localID=0,this._currentLocalID=0,this._worldID=0,this._parentID=0}return t.prototype.onChange=function(){this._localID++},t.prototype.updateSkew=function(){this._cx=Math.cos(this._rotation+this.skew.y),this._sx=Math.sin(this._rotation+this.skew.y),this._cy=-Math.sin(this._rotation-this.skew.x),this._sy=Math.cos(this._rotation-this.skew.x),this._localID++},t.prototype.toString=function(){return"[@pixi/math:Transform position=("+this.position.x+", "+this.position.y+") rotation="+this.rotation+" scale=("+this.scale.x+", "+this.scale.y+") skew=("+this.skew.x+", "+this.skew.y+") ]"},t.prototype.updateLocalTransform=function(){var t=this.localTransform;this._localID!==this._currentLocalID&&(t.a=this._cx*this.scale.x,t.b=this._sx*this.scale.x,t.c=this._cy*this.scale.y,t.d=this._sy*this.scale.y,t.tx=this.position.x-(this.pivot.x*t.a+this.pivot.y*t.c),t.ty=this.position.y-(this.pivot.x*t.b+this.pivot.y*t.d),this._currentLocalID=this._localID,this._parentID=-1)},t.prototype.updateTransform=function(t){var e=this.localTransform;if(this._localID!==this._currentLocalID&&(e.a=this._cx*this.scale.x,e.b=this._sx*this.scale.x,e.c=this._cy*this.scale.y,e.d=this._sy*this.scale.y,e.tx=this.position.x-(this.pivot.x*e.a+this.pivot.y*e.c),e.ty=this.position.y-(this.pivot.x*e.b+this.pivot.y*e.d),this._currentLocalID=this._localID,this._parentID=-1),this._parentID!==t._worldID){var n=t.worldTransform,r=this.worldTransform;r.a=e.a*n.a+e.b*n.c,r.b=e.a*n.b+e.b*n.d,r.c=e.c*n.a+e.d*n.c,r.d=e.c*n.b+e.d*n.d,r.tx=e.tx*n.a+e.ty*n.c+n.tx,r.ty=e.tx*n.b+e.ty*n.d+n.ty,this._parentID=t._worldID,this._worldID++}},t.prototype.setFromMatrix=function(t){t.decompose(this),this._localID++},Object.defineProperty(t.prototype,"rotation",{get:function(){return this._rotation},set:function(t){this._rotation!==t&&(this._rotation=t,this.updateSkew())},enumerable:!1,configurable:!0}),t.IDENTITY=new t,t}()},1845:function(t,e,n){"use strict";n.d(e,{Q5:function(){return S},oC:function(){return ut}});var r=n(2038),i=n(1680),o=n(8033),s=n(1576),a=n(9658),u=n(6679);n(1585); -/*! - * @pixi/particle-emitter - v5.0.4 - * Compiled Thu, 10 Mar 2022 03:05:06 UTC - * - * @pixi/particle-emitter is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -class l{constructor(t,e,n){this.value=t,this.time=e,this.next=null,this.isStepped=!1,this.ease=n?"function"===typeof n?n:_(n):null}static createList(t){if("list"in t){const e=t.list;let n;const{value:r,time:i}=e[0],o=n=new l("string"===typeof r?g(r):r,i,t.ease);if(e.length>2||2===e.length&&e[1].value!==r)for(let t=1;t<e.length;++t){const{value:r,time:i}=e[t];n.next=new l("string"===typeof r?g(r):r,i),n=n.next}return o.isStepped=!!t.isStepped,o}const e=new l("string"===typeof t.start?g(t.start):t.start,0);return t.end!==t.start&&(e.next=new l("string"===typeof t.end?g(t.end):t.end,1)),e}}let c=r.xE.from;const h=Math.PI/180;function f(t,e){if(!t)return;const n=Math.sin(t),r=Math.cos(t),i=e.x*r-e.y*n,o=e.x*n+e.y*r;e.x=i,e.y=o}function d(t,e,n){return t<<16|e<<8|n}function p(t){return Math.sqrt(t.x*t.x+t.y*t.y)}function m(t){const e=1/p(t);t.x*=e,t.y*=e}function v(t,e){t.x*=e,t.y*=e}function g(t,e){let n;return e||(e={}),"#"===t.charAt(0)?t=t.substr(1):0===t.indexOf("0x")&&(t=t.substr(2)),8===t.length&&(n=t.substr(0,2),t=t.substr(2)),e.r=parseInt(t.substr(0,2),16),e.g=parseInt(t.substr(2,2),16),e.b=parseInt(t.substr(4,2),16),n&&(e.a=parseInt(n,16)),e}function _(t){const e=t.length,n=1/e;return function(r){const i=e*r|0,o=(r-i*n)*e,s=t[i]||t[e-1];return s.s+o*(2*(1-o)*(s.cp-s.s)+o*(s.e-s.s))}}function y(t){return t?(t=t.toUpperCase().replace(/ /g,"_"),i.T$[t]||i.T$.NORMAL):i.T$.NORMAL}var b;class E extends o.j{constructor(t){super(),this.prevChild=this.nextChild=null,this.emitter=t,this.config={},this.anchor.x=this.anchor.y=.5,this.maxLife=0,this.age=0,this.agePercent=0,this.oneOverLife=0,this.next=null,this.prev=null,this.init=this.init,this.kill=this.kill}init(t){this.maxLife=t,this.age=this.agePercent=0,this.rotation=0,this.position.x=this.position.y=0,this.scale.x=this.scale.y=1,this.tint=16777215,this.alpha=1,this.oneOverLife=1/this.maxLife,this.visible=!0}kill(){this.emitter.recycle(this)}destroy(){this.parent&&this.parent.removeChild(this),this.emitter=this.next=this.prev=null,super.destroy()}}(function(t){t[t["Spawn"]=0]="Spawn",t[t["Normal"]=2]="Normal",t[t["Late"]=5]="Late"})(b||(b={}));const T=u.vB.shared,x=Symbol("Position particle per emitter position");class S{constructor(t,e){this.initBehaviors=[],this.updateBehaviors=[],this.recycleBehaviors=[],this.minLifetime=0,this.maxLifetime=0,this.customEase=null,this._frequency=1,this.spawnChance=1,this.maxParticles=1e3,this.emitterLifetime=-1,this.spawnPos=new a.E9,this.particlesPerWave=1,this.rotation=0,this.ownerPos=new a.E9,this._prevEmitterPos=new a.E9,this._prevPosIsValid=!1,this._posChanged=!1,this._parent=null,this.addAtBack=!1,this.particleCount=0,this._emit=!1,this._spawnTimer=0,this._emitterLife=-1,this._activeParticlesFirst=null,this._activeParticlesLast=null,this._poolFirst=null,this._origConfig=null,this._autoUpdate=!1,this._destroyWhenComplete=!1,this._completeCallback=null,this.parent=t,e&&this.init(e),this.recycle=this.recycle,this.update=this.update,this.rotate=this.rotate,this.updateSpawnPos=this.updateSpawnPos,this.updateOwnerPos=this.updateOwnerPos}static registerBehavior(t){S.knownBehaviors[t.type]=t}get frequency(){return this._frequency}set frequency(t){this._frequency="number"===typeof t&&t>0?t:1}get parent(){return this._parent}set parent(t){this.cleanup(),this._parent=t}init(t){if(!t)return;this.cleanup(),this._origConfig=t,this.minLifetime=t.lifetime.min,this.maxLifetime=t.lifetime.max,t.ease?this.customEase="function"===typeof t.ease?t.ease:_(t.ease):this.customEase=null,this.particlesPerWave=1,t.particlesPerWave&&t.particlesPerWave>1&&(this.particlesPerWave=t.particlesPerWave),this.frequency=t.frequency,this.spawnChance="number"===typeof t.spawnChance&&t.spawnChance>0?t.spawnChance:1,this.emitterLifetime=t.emitterLifetime||-1,this.maxParticles=t.maxParticles>0?t.maxParticles:1e3,this.addAtBack=!!t.addAtBack,this.rotation=0,this.ownerPos.set(0),t.pos?this.spawnPos.copyFrom(t.pos):this.spawnPos.set(0),this._prevEmitterPos.copyFrom(this.spawnPos),this._prevPosIsValid=!1,this._spawnTimer=0,this.emit=void 0===t.emit||!!t.emit,this.autoUpdate=!!t.autoUpdate;const e=t.behaviors.map((t=>{const e=S.knownBehaviors[t.type];return e?new e(t.config):(console.error(`Unknown behavior: ${t.type}`),null)})).filter((t=>!!t));e.push(x),e.sort(((t,e)=>t===x?e.order===b.Spawn?1:-1:e===x?t.order===b.Spawn?-1:1:t.order-e.order)),this.initBehaviors=e.slice(),this.updateBehaviors=e.filter((t=>t!==x&&t.updateParticle)),this.recycleBehaviors=e.filter((t=>t!==x&&t.recycleParticle))}getBehavior(t){return S.knownBehaviors[t]&&this.initBehaviors.find((e=>e instanceof S.knownBehaviors[t]))||null}fillPool(t){for(;t>0;--t){const t=new E(this);t.next=this._poolFirst,this._poolFirst=t}}recycle(t,e=!1){for(let n=0;n<this.recycleBehaviors.length;++n)this.recycleBehaviors[n].recycleParticle(t,!e);t.next&&(t.next.prev=t.prev),t.prev&&(t.prev.next=t.next),t===this._activeParticlesLast&&(this._activeParticlesLast=t.prev),t===this._activeParticlesFirst&&(this._activeParticlesFirst=t.next),t.prev=null,t.next=this._poolFirst,this._poolFirst=t,t.parent&&t.parent.removeChild(t),--this.particleCount}rotate(t){if(this.rotation===t)return;const e=t-this.rotation;this.rotation=t,f(e,this.spawnPos),this._posChanged=!0}updateSpawnPos(t,e){this._posChanged=!0,this.spawnPos.x=t,this.spawnPos.y=e}updateOwnerPos(t,e){this._posChanged=!0,this.ownerPos.x=t,this.ownerPos.y=e}resetPositionTracking(){this._prevPosIsValid=!1}get emit(){return this._emit}set emit(t){this._emit=!!t,this._emitterLife=this.emitterLifetime}get autoUpdate(){return this._autoUpdate}set autoUpdate(t){this._autoUpdate&&!t?T.remove(this.update,this):!this._autoUpdate&&t&&T.add(this.update,this),this._autoUpdate=!!t}playOnceAndDestroy(t){this.autoUpdate=!0,this.emit=!0,this._destroyWhenComplete=!0,this._completeCallback=t}playOnce(t){this.emit=!0,this._completeCallback=t}update(t){if(this._autoUpdate&&(t=t/s.X.TARGET_FPMS/1e3),!this._parent)return;for(let o,s=this._activeParticlesFirst;s;s=o)if(o=s.next,s.age+=t,s.age>s.maxLife||s.age<0)this.recycle(s);else{let e=s.age*s.oneOverLife;this.customEase&&(e=4===this.customEase.length?this.customEase(e,0,1,1):this.customEase(e)),s.agePercent=e;for(let n=0;n<this.updateBehaviors.length;++n)if(this.updateBehaviors[n].updateParticle(s,t)){this.recycle(s);break}}let e,n;this._prevPosIsValid&&(e=this._prevEmitterPos.x,n=this._prevEmitterPos.y);const r=this.ownerPos.x+this.spawnPos.x,i=this.ownerPos.y+this.spawnPos.y;if(this._emit){this._spawnTimer-=t<0?0:t;while(this._spawnTimer<=0){if(this._emitterLife>=0&&(this._emitterLife-=this._frequency,this._emitterLife<=0)){this._spawnTimer=0,this._emitterLife=0,this.emit=!1;break}if(this.particleCount>=this.maxParticles){this._spawnTimer+=this._frequency;continue}let o,s;if(this._prevPosIsValid&&this._posChanged){const a=1+this._spawnTimer/t;o=(r-e)*a+e,s=(i-n)*a+n}else o=r,s=i;let a=null,u=null;for(let t=Math.min(this.particlesPerWave,this.maxParticles-this.particleCount),e=0;e<t;++e){if(this.spawnChance<1&&Math.random()>=this.spawnChance)continue;let t,e;(t=this.minLifetime===this.maxLifetime?this.minLifetime:Math.random()*(this.maxLifetime-this.minLifetime)+this.minLifetime,-this._spawnTimer>=t)||(this._poolFirst?(e=this._poolFirst,this._poolFirst=this._poolFirst.next,e.next=null):e=new E(this),e.init(t),this.addAtBack?this._parent.addChildAt(e,0):this._parent.addChild(e),a?(u.next=e,e.prev=u,u=e):u=a=e,++this.particleCount)}if(a){this._activeParticlesLast?(this._activeParticlesLast.next=a,a.prev=this._activeParticlesLast,this._activeParticlesLast=u):(this._activeParticlesFirst=a,this._activeParticlesLast=u);for(let t=0;t<this.initBehaviors.length;++t){const e=this.initBehaviors[t];if(e===x)for(let t,n=a;n;n=t){t=n.next,0!==this.rotation&&(f(this.rotation,n.position),n.rotation+=this.rotation),n.position.x+=o,n.position.y+=s,n.age+=-this._spawnTimer;let e=n.age*n.oneOverLife;this.customEase&&(e=4===this.customEase.length?this.customEase(e,0,1,1):this.customEase(e)),n.agePercent=e}else e.initParticles(a)}for(let t,e=a;e;e=t){t=e.next;for(let t=0;t<this.updateBehaviors.length;++t)if(this.updateBehaviors[t].updateParticle(e,-this._spawnTimer)){this.recycle(e);break}}}this._spawnTimer+=this._frequency}}if(this._posChanged&&(this._prevEmitterPos.x=r,this._prevEmitterPos.y=i,this._prevPosIsValid=!0,this._posChanged=!1),!this._emit&&!this._activeParticlesFirst){if(this._completeCallback){const t=this._completeCallback;this._completeCallback=null,t()}this._destroyWhenComplete&&this.destroy()}}emitNow(){const t=this.ownerPos.x+this.spawnPos.x,e=this.ownerPos.y+this.spawnPos.y;let n=null,r=null;for(let i=Math.min(this.particlesPerWave,this.maxParticles-this.particleCount),o=0;o<i;++o){if(this.spawnChance<1&&Math.random()>=this.spawnChance)continue;let t,e;this._poolFirst?(t=this._poolFirst,this._poolFirst=this._poolFirst.next,t.next=null):t=new E(this),e=this.minLifetime===this.maxLifetime?this.minLifetime:Math.random()*(this.maxLifetime-this.minLifetime)+this.minLifetime,t.init(e),this.addAtBack?this._parent.addChildAt(t,0):this._parent.addChild(t),n?(r.next=t,t.prev=r,r=t):r=n=t,++this.particleCount}if(n){this._activeParticlesLast?(this._activeParticlesLast.next=n,n.prev=this._activeParticlesLast,this._activeParticlesLast=r):(this._activeParticlesFirst=n,this._activeParticlesLast=r);for(let r=0;r<this.initBehaviors.length;++r){const i=this.initBehaviors[r];if(i===x)for(let r,o=n;o;o=r)r=o.next,0!==this.rotation&&(f(this.rotation,o.position),o.rotation+=this.rotation),o.position.x+=t,o.position.y+=e;else i.initParticles(n)}}}cleanup(){let t,e;for(t=this._activeParticlesFirst;t;t=e)e=t.next,this.recycle(t,!0);this._activeParticlesFirst=this._activeParticlesLast=null,this.particleCount=0}get destroyed(){return!(this._parent&&this.initBehaviors.length)}destroy(){let t;this.autoUpdate=!1,this.cleanup();for(let e=this._poolFirst;e;e=t)t=e.next,e.destroy();this._poolFirst=this._parent=this.spawnPos=this.ownerPos=this.customEase=this._completeCallback=null,this.initBehaviors.length=this.updateBehaviors.length=this.recycleBehaviors.length=0}}S.knownBehaviors={};class R{constructor(t){this.x=t.x,this.y=t.y,this.w=t.w,this.h=t.h}getRandPos(t){t.x=Math.random()*this.w+this.x,t.y=Math.random()*this.h+this.y}}R.type="rect",R.editorConfig=null;class A{constructor(t){this.x=t.x||0,this.y=t.y||0,this.radius=t.radius,this.innerRadius=t.innerRadius||0,this.rotation=!!t.affectRotation}getRandPos(t){this.innerRadius!==this.radius?t.x=Math.random()*(this.radius-this.innerRadius)+this.innerRadius:t.x=this.radius,t.y=0;const e=Math.random()*Math.PI*2;this.rotation&&(t.rotation+=e),f(e,t.position),t.position.x+=this.x,t.position.y+=this.y}}A.type="torus",A.editorConfig=null;class O{constructor(t){this.segments=[],this.countingLengths=[],this.totalLength=0,this.init(t)}init(t){if(t&&t.length)if(Array.isArray(t[0]))for(let e=0;e<t.length;++e){const n=t[e];let r=n[0];for(let t=1;t<n.length;++t){const e=n[t];this.segments.push({p1:r,p2:e,l:0}),r=e}}else{let e=t[0];for(let n=1;n<t.length;++n){const r=t[n];this.segments.push({p1:e,p2:r,l:0}),e=r}}else this.segments.push({p1:{x:0,y:0},p2:{x:0,y:0},l:0});for(let e=0;e<this.segments.length;++e){const{p1:t,p2:n}=this.segments[e],r=Math.sqrt((n.x-t.x)*(n.x-t.x)+(n.y-t.y)*(n.y-t.y));this.segments[e].l=r,this.totalLength+=r,this.countingLengths.push(this.totalLength)}}getRandPos(t){const e=Math.random()*this.totalLength;let n,r;if(1===this.segments.length)n=this.segments[0],r=e;else for(let s=0;s<this.countingLengths.length;++s)if(e<this.countingLengths[s]){n=this.segments[s],r=0===s?e:e-this.countingLengths[s-1];break}r/=n.l||1;const{p1:i,p2:o}=n;t.x=i.x+r*(o.x-i.x),t.y=i.y+r*(o.y-i.y)}}O.type="polygonalChain",O.editorConfig=null;class I{constructor(t){var e;this.order=b.Late,this.minStart=t.minStart,this.maxStart=t.maxStart,this.accel=t.accel,this.rotate=!!t.rotate,this.maxSpeed=null!==(e=t.maxSpeed)&&void 0!==e?e:0}initParticles(t){let e=t;while(e){const t=Math.random()*(this.maxStart-this.minStart)+this.minStart;e.config.velocity?e.config.velocity.set(t,0):e.config.velocity=new a.E9(t,0),f(e.rotation,e.config.velocity),e=e.next}}updateParticle(t,e){const n=t.config.velocity,r=n.x,i=n.y;if(n.x+=this.accel.x*e,n.y+=this.accel.y*e,this.maxSpeed){const t=p(n);t>this.maxSpeed&&v(n,this.maxSpeed/t)}t.x+=(r+n.x)/2*e,t.y+=(i+n.y)/2*e,this.rotate&&(t.rotation=Math.atan2(n.y,n.x))}}function w(t){return this.ease&&(t=this.ease(t)),(this.first.next.value-this.first.value)*t+this.first.value}function C(t){this.ease&&(t=this.ease(t));const e=this.first.value,n=this.first.next.value,r=(n.r-e.r)*t+e.r,i=(n.g-e.g)*t+e.g,o=(n.b-e.b)*t+e.b;return d(r,i,o)}function P(t){this.ease&&(t=this.ease(t));let e=this.first,n=e.next;while(t>n.time)e=n,n=n.next;return t=(t-e.time)/(n.time-e.time),(n.value-e.value)*t+e.value}function N(t){this.ease&&(t=this.ease(t));let e=this.first,n=e.next;while(t>n.time)e=n,n=n.next;t=(t-e.time)/(n.time-e.time);const r=e.value,i=n.value,o=(i.r-r.r)*t+r.r,s=(i.g-r.g)*t+r.g,a=(i.b-r.b)*t+r.b;return d(o,s,a)}function M(t){this.ease&&(t=this.ease(t));let e=this.first;while(e.next&&t>e.next.time)e=e.next;return e.value}function D(t){this.ease&&(t=this.ease(t));let e=this.first;while(e.next&&t>e.next.time)e=e.next;const n=e.value;return d(n.r,n.g,n.b)}I.type="moveAcceleration",I.editorConfig=null;class L{constructor(t=!1){this.first=null,this.isColor=!!t,this.interpolate=null,this.ease=null}reset(t){this.first=t;const e=t.next&&t.next.time>=1;e?this.interpolate=this.isColor?C:w:t.isStepped?this.interpolate=this.isColor?D:M:this.interpolate=this.isColor?N:P,this.ease=this.first.ease}}class B{constructor(t){this.order=b.Normal,this.list=new L(!1),this.list.reset(l.createList(t.alpha))}initParticles(t){let e=t;while(e)e.alpha=this.list.first.value,e=e.next}updateParticle(t){t.alpha=this.list.interpolate(t.agePercent)}}B.type="alpha",B.editorConfig=null;class F{constructor(t){this.order=b.Normal,this.value=t.alpha}initParticles(t){let e=t;while(e)e.alpha=this.value,e=e.next}}function U(t){const e=[];for(let n=0;n<t.length;++n){let i=t[n];if("string"===typeof i)e.push(c(i));else if(i instanceof r.xE)e.push(i);else{let t=i.count||1;for(i="string"===typeof i.texture?c(i.texture):i.texture;t>0;--t)e.push(i)}}return e}F.type="alphaStatic",F.editorConfig=null;class G{constructor(t){this.order=b.Normal,this.anims=[];for(let e=0;e<t.anims.length;++e){const n=t.anims[e],r=U(n.textures),i=n.framerate<0?-1:n.framerate>0?n.framerate:60,o={textures:r,duration:i>0?r.length/i:0,framerate:i,loop:i>0&&!!n.loop};this.anims.push(o)}}initParticles(t){let e=t;while(e){const t=Math.floor(Math.random()*this.anims.length),n=e.config.anim=this.anims[t];e.texture=n.textures[0],e.config.animElapsed=0,-1===n.framerate?(e.config.animDuration=e.maxLife,e.config.animFramerate=n.textures.length/e.maxLife):(e.config.animDuration=n.duration,e.config.animFramerate=n.framerate),e=e.next}}updateParticle(t,e){const n=t.config,i=n.anim;n.animElapsed+=e,n.animElapsed>=n.animDuration&&(n.anim.loop?n.animElapsed=n.animElapsed%n.animDuration:n.animElapsed=n.animDuration-1e-6);const o=n.animElapsed*n.animFramerate+1e-7|0;t.texture=i.textures[o]||i.textures[i.textures.length-1]||r.xE.EMPTY}}G.type="animatedRandom",G.editorConfig=null;class k{constructor(t){this.order=b.Normal;const e=t.anim,n=U(e.textures),r=e.framerate<0?-1:e.framerate>0?e.framerate:60;this.anim={textures:n,duration:r>0?n.length/r:0,framerate:r,loop:r>0&&!!e.loop}}initParticles(t){let e=t;const n=this.anim;while(e)e.texture=n.textures[0],e.config.animElapsed=0,-1===n.framerate?(e.config.animDuration=e.maxLife,e.config.animFramerate=n.textures.length/e.maxLife):(e.config.animDuration=n.duration,e.config.animFramerate=n.framerate),e=e.next}updateParticle(t,e){const n=this.anim,i=t.config;i.animElapsed+=e,i.animElapsed>=i.animDuration&&(n.loop?i.animElapsed=i.animElapsed%i.animDuration:i.animElapsed=i.animDuration-1e-6);const o=i.animElapsed*i.animFramerate+1e-7|0;t.texture=n.textures[o]||n.textures[n.textures.length-1]||r.xE.EMPTY}}k.type="animatedSingle",k.editorConfig=null;class X{constructor(t){this.order=b.Normal,this.value=t.blendMode}initParticles(t){let e=t;while(e)e.blendMode=y(this.value),e=e.next}}X.type="blendMode",X.editorConfig=null;class H{constructor(t){this.order=b.Spawn,this.spacing=t.spacing*h,this.start=t.start*h,this.distance=t.distance}initParticles(t){let e=0,n=t;while(n){let t;t=this.spacing?this.start+this.spacing*e:Math.random()*Math.PI*2,n.rotation=t,this.distance&&(n.position.x=this.distance,f(t,n.position)),n=n.next,++e}}}H.type="spawnBurst",H.editorConfig=null;class j{constructor(t){this.order=b.Normal,this.list=new L(!0),this.list.reset(l.createList(t.color))}initParticles(t){let e=t;const n=this.list.first.value,r=d(n.r,n.g,n.b);while(e)e.tint=r,e=e.next}updateParticle(t){t.tint=this.list.interpolate(t.agePercent)}}j.type="color",j.editorConfig=null;class V{constructor(t){this.order=b.Normal;let e=t.color;"#"===e.charAt(0)?e=e.substr(1):0===e.indexOf("0x")&&(e=e.substr(2)),this.value=parseInt(e,16)}initParticles(t){let e=t;while(e)e.tint=this.value,e=e.next}}V.type="colorStatic",V.editorConfig=null;class Y{constructor(t){this.order=b.Normal,this.index=0,this.textures=t.textures.map((t=>"string"===typeof t?c(t):t))}initParticles(t){let e=t;while(e)e.texture=this.textures[this.index],++this.index>=this.textures.length&&(this.index=0),e=e.next}}Y.type="textureOrdered",Y.editorConfig=null;const W=new a.E9,z=["E","LN2","LN10","LOG2E","LOG10E","PI","SQRT1_2","SQRT2","abs","acos","acosh","asin","asinh","atan","atanh","atan2","cbrt","ceil","cos","cosh","exp","expm1","floor","fround","hypot","log","log1p","log10","log2","max","min","pow","random","round","sign","sin","sinh","sqrt","tan","tanh"],$=new RegExp(["[01234567890\\.\\*\\-\\+\\/\\(\\)x ,]"].concat(z).join("|"),"g");function q(t){const e=t.match($);for(let n=e.length-1;n>=0;--n)z.indexOf(e[n])>=0&&(e[n]=`Math.${e[n]}`);return t=e.join(""),new Function("x",`return ${t};`)}class K{constructor(t){var e;if(this.order=b.Late,t.path)if("function"===typeof t.path)this.path=t.path;else try{this.path=q(t.path)}catch(n){this.path=null}else this.path=t=>t;this.list=new L(!1),this.list.reset(l.createList(t.speed)),this.minMult=null!==(e=t.minMult)&&void 0!==e?e:1}initParticles(t){let e=t;while(e){e.config.initRotation=e.rotation,e.config.initPosition?e.config.initPosition.copyFrom(e.position):e.config.initPosition=new a.E9(e.x,e.y),e.config.movement=0;const t=Math.random()*(1-this.minMult)+this.minMult;e.config.speedMult=t,e=e.next}}updateParticle(t,e){const n=this.list.interpolate(t.agePercent)*t.config.speedMult;t.config.movement+=n*e,W.x=t.config.movement,W.y=this.path(W.x),f(t.config.initRotation,W),t.position.x=t.config.initPosition.x+W.x,t.position.y=t.config.initPosition.y+W.y}}K.type="movePath",K.editorConfig=null;class Z{constructor(){this.order=b.Spawn}initParticles(t){}}Z.type="spawnPoint",Z.editorConfig=null;class J{constructor(t){this.order=b.Normal,this.textures=t.textures.map((t=>"string"===typeof t?c(t):t))}initParticles(t){let e=t;while(e){const t=Math.floor(Math.random()*this.textures.length);e.texture=this.textures[t],e=e.next}}}J.type="textureRandom",J.editorConfig=null;class Q{constructor(t){this.order=b.Normal,this.minStart=t.minStart*h,this.maxStart=t.maxStart*h,this.minSpeed=t.minSpeed*h,this.maxSpeed=t.maxSpeed*h,this.accel=t.accel*h}initParticles(t){let e=t;while(e)this.minStart===this.maxStart?e.rotation+=this.maxStart:e.rotation+=Math.random()*(this.maxStart-this.minStart)+this.minStart,e.config.rotSpeed=Math.random()*(this.maxSpeed-this.minSpeed)+this.minSpeed,e=e.next}updateParticle(t,e){if(this.accel){const n=t.config.rotSpeed;t.config.rotSpeed+=this.accel*e,t.rotation+=(t.config.rotSpeed+n)/2*e}else t.rotation+=t.config.rotSpeed*e}}Q.type="rotation",Q.editorConfig=null;class tt{constructor(t){this.order=b.Normal,this.min=t.min*h,this.max=t.max*h}initParticles(t){let e=t;while(e)this.min===this.max?e.rotation+=this.max:e.rotation+=Math.random()*(this.max-this.min)+this.min,e=e.next}}tt.type="rotationStatic",tt.editorConfig=null;class et{constructor(t){this.order=b.Late+1,this.rotation=(t.rotation||0)*h}initParticles(t){let e=t;while(e)e.rotation=this.rotation,e=e.next}}et.type="noRotation",et.editorConfig=null;class nt{constructor(t){var e;this.order=b.Normal,this.list=new L(!1),this.list.reset(l.createList(t.scale)),this.minMult=null!==(e=t.minMult)&&void 0!==e?e:1}initParticles(t){let e=t;while(e){const t=Math.random()*(1-this.minMult)+this.minMult;e.config.scaleMult=t,e.scale.x=e.scale.y=this.list.first.value*t,e=e.next}}updateParticle(t){t.scale.x=t.scale.y=this.list.interpolate(t.agePercent)*t.config.scaleMult}}nt.type="scale",nt.editorConfig=null;class rt{constructor(t){this.order=b.Normal,this.min=t.min,this.max=t.max}initParticles(t){let e=t;while(e){const t=Math.random()*(this.max-this.min)+this.min;e.scale.x=e.scale.y=t,e=e.next}}}rt.type="scaleStatic",rt.editorConfig=null;class it{constructor(t){this.order=b.Spawn;const e=it.shapes[t.type];if(!e)throw new Error(`No shape found with type '${t.type}'`);this.shape=new e(t.data)}static registerShape(t,e){it.shapes[e||t.type]=t}initParticles(t){let e=t;while(e)this.shape.getRandPos(e),e=e.next}}it.type="spawnShape",it.editorConfig=null,it.shapes={},it.registerShape(O),it.registerShape(R),it.registerShape(A),it.registerShape(A,"circle");class ot{constructor(t){this.order=b.Normal,this.texture="string"===typeof t.texture?c(t.texture):t.texture}initParticles(t){let e=t;while(e)e.texture=this.texture,e=e.next}}ot.type="textureSingle",ot.editorConfig=null;class st{constructor(t){var e;this.order=b.Late,this.list=new L(!1),this.list.reset(l.createList(t.speed)),this.minMult=null!==(e=t.minMult)&&void 0!==e?e:1}initParticles(t){let e=t;while(e){const t=Math.random()*(1-this.minMult)+this.minMult;e.config.speedMult=t,e.config.velocity?e.config.velocity.set(this.list.first.value*t,0):e.config.velocity=new a.E9(this.list.first.value*t,0),f(e.rotation,e.config.velocity),e=e.next}}updateParticle(t,e){const n=this.list.interpolate(t.agePercent)*t.config.speedMult,r=t.config.velocity;m(r),v(r,n),t.x+=r.x*e,t.y+=r.y*e}}st.type="moveSpeed",st.editorConfig=null;class at{constructor(t){this.order=b.Late,this.min=t.min,this.max=t.max}initParticles(t){let e=t;while(e){const t=Math.random()*(this.max-this.min)+this.min;e.config.velocity?e.config.velocity.set(t,0):e.config.velocity=new a.E9(t,0),f(e.rotation,e.config.velocity),e=e.next}}updateParticle(t,e){const n=t.config.velocity;t.x+=n.x*e,t.y+=n.y*e}}at.type="moveSpeedStatic",at.editorConfig=null;function ut(t,e){var n,r,i,o,s,a,u,l,c,h,f,d,p,m,v,g,_,y,b,E,T;if("behaviors"in t)return t;const x={lifetime:t.lifetime,ease:t.ease,particlesPerWave:t.particlesPerWave,frequency:t.frequency,spawnChance:t.spawnChance,emitterLifetime:t.emitterLifetime,maxParticles:t.maxParticles,addAtBack:t.addAtBack,pos:t.pos,emit:t.emit,autoUpdate:t.autoUpdate,behaviors:[]};if(t.alpha)if("start"in t.alpha)if(t.alpha.start===t.alpha.end)1!==t.alpha.start&&x.behaviors.push({type:"alphaStatic",config:{alpha:t.alpha.start}});else{const e={list:[{time:0,value:t.alpha.start},{time:1,value:t.alpha.end}]};x.behaviors.push({type:"alpha",config:{alpha:e}})}else 1===t.alpha.list.length?1!==t.alpha.list[0].value&&x.behaviors.push({type:"alphaStatic",config:{alpha:t.alpha.list[0].value}}):x.behaviors.push({type:"alpha",config:{alpha:t.alpha}});if(t.acceleration&&(t.acceleration.x||t.acceleration.y)){let e,i;"start"in t.speed?(e=t.speed.start*(null!==(n=t.speed.minimumSpeedMultiplier)&&void 0!==n?n:1),i=t.speed.start):(e=t.speed.list[0].value*(null!==(r=t.minimumSpeedMultiplier)&&void 0!==r?r:1),i=t.speed.list[0].value),x.behaviors.push({type:"moveAcceleration",config:{accel:t.acceleration,minStart:e,maxStart:i,rotate:!t.noRotation,maxSpeed:t.maxSpeed}})}else if(null===(i=t.extraData)||void 0===i?void 0:i.path){let e,n;"start"in t.speed?(n=null!==(o=t.speed.minimumSpeedMultiplier)&&void 0!==o?o:1,e=t.speed.start===t.speed.end?{list:[{time:0,value:t.speed.start}]}:{list:[{time:0,value:t.speed.start},{time:1,value:t.speed.end}]}):(e=t.speed,n=null!==(s=t.minimumSpeedMultiplier)&&void 0!==s?s:1),x.behaviors.push({type:"movePath",config:{path:t.extraData.path,speed:e,minMult:n}})}else if(t.speed)if("start"in t.speed)if(t.speed.start===t.speed.end)x.behaviors.push({type:"moveSpeedStatic",config:{min:t.speed.start*(null!==(a=t.speed.minimumSpeedMultiplier)&&void 0!==a?a:1),max:t.speed.start}});else{const e={list:[{time:0,value:t.speed.start},{time:1,value:t.speed.end}]};x.behaviors.push({type:"moveSpeed",config:{speed:e,minMult:t.speed.minimumSpeedMultiplier}})}else 1===t.speed.list.length?x.behaviors.push({type:"moveSpeedStatic",config:{min:t.speed.list[0].value*(null!==(u=t.minimumSpeedMultiplier)&&void 0!==u?u:1),max:t.speed.list[0].value}}):x.behaviors.push({type:"moveSpeed",config:{speed:t.speed,minMult:null!==(l=t.minimumSpeedMultiplier)&&void 0!==l?l:1}});if(t.scale)if("start"in t.scale){const e=null!==(c=t.scale.minimumScaleMultiplier)&&void 0!==c?c:1;if(t.scale.start===t.scale.end)x.behaviors.push({type:"scaleStatic",config:{min:t.scale.start*e,max:t.scale.start}});else{const n={list:[{time:0,value:t.scale.start},{time:1,value:t.scale.end}]};x.behaviors.push({type:"scale",config:{scale:n,minMult:e}})}}else if(1===t.scale.list.length){const e=null!==(h=t.minimumScaleMultiplier)&&void 0!==h?h:1,n=t.scale.list[0].value;x.behaviors.push({type:"scaleStatic",config:{min:n*e,max:n}})}else x.behaviors.push({type:"scale",config:{scale:t.scale,minMult:null!==(f=t.minimumScaleMultiplier)&&void 0!==f?f:1}});if(t.color)if("start"in t.color)if(t.color.start===t.color.end)"ffffff"!==t.color.start&&x.behaviors.push({type:"colorStatic",config:{color:t.color.start}});else{const e={list:[{time:0,value:t.color.start},{time:1,value:t.color.end}]};x.behaviors.push({type:"color",config:{color:e}})}else 1===t.color.list.length?"ffffff"!==t.color.list[0].value&&x.behaviors.push({type:"colorStatic",config:{color:t.color.list[0].value}}):x.behaviors.push({type:"color",config:{color:t.color}});if(t.rotationAcceleration||(null===(d=t.rotationSpeed)||void 0===d?void 0:d.min)||(null===(p=t.rotationSpeed)||void 0===p?void 0:p.max)?x.behaviors.push({type:"rotation",config:{accel:t.rotationAcceleration||0,minSpeed:(null===(m=t.rotationSpeed)||void 0===m?void 0:m.min)||0,maxSpeed:(null===(v=t.rotationSpeed)||void 0===v?void 0:v.max)||0,minStart:(null===(g=t.startRotation)||void 0===g?void 0:g.min)||0,maxStart:(null===(_=t.startRotation)||void 0===_?void 0:_.max)||0}}):((null===(y=t.startRotation)||void 0===y?void 0:y.min)||(null===(b=t.startRotation)||void 0===b?void 0:b.max))&&x.behaviors.push({type:"rotationStatic",config:{min:(null===(E=t.startRotation)||void 0===E?void 0:E.min)||0,max:(null===(T=t.startRotation)||void 0===T?void 0:T.max)||0}}),t.noRotation&&x.behaviors.push({type:"noRotation",config:{}}),t.blendMode&&"normal"!==t.blendMode&&x.behaviors.push({type:"blendMode",config:{blendMode:t.blendMode}}),Array.isArray(e)&&"string"!==typeof e[0]&&"framerate"in e[0]){for(let t=0;t<e.length;++t)"matchLife"===e[t].framerate&&(e[t].framerate=-1);x.behaviors.push({type:"animatedRandom",config:{anims:e}})}else"string"!==typeof e&&"framerate"in e?("matchLife"===e.framerate&&(e.framerate=-1),x.behaviors.push({type:"animatedSingle",config:{anim:e}})):t.orderedArt&&Array.isArray(e)?x.behaviors.push({type:"textureOrdered",config:{textures:e}}):Array.isArray(e)?x.behaviors.push({type:"textureRandom",config:{textures:e}}):x.behaviors.push({type:"textureSingle",config:{texture:e}});if("burst"===t.spawnType)x.behaviors.push({type:"spawnBurst",config:{start:t.angleStart||0,spacing:t.particleSpacing,distance:0}});else if("point"===t.spawnType)x.behaviors.push({type:"spawnPoint",config:{}});else{let e;"ring"===t.spawnType?e={type:"torus",data:{x:t.spawnCircle.x,y:t.spawnCircle.y,radius:t.spawnCircle.r,innerRadius:t.spawnCircle.minR,affectRotation:!0}}:"circle"===t.spawnType?e={type:"torus",data:{x:t.spawnCircle.x,y:t.spawnCircle.y,radius:t.spawnCircle.r,innerRadius:0,affectRotation:!1}}:"rect"===t.spawnType?e={type:"rect",data:t.spawnRect}:"polygonalChain"===t.spawnType&&(e={type:"polygonalChain",data:t.spawnPolygon}),e&&x.behaviors.push({type:"spawnShape",config:e})}return x}S.registerBehavior(I),S.registerBehavior(B),S.registerBehavior(F),S.registerBehavior(G),S.registerBehavior(k),S.registerBehavior(X),S.registerBehavior(H),S.registerBehavior(j),S.registerBehavior(V),S.registerBehavior(Y),S.registerBehavior(K),S.registerBehavior(Z),S.registerBehavior(J),S.registerBehavior(Q),S.registerBehavior(tt),S.registerBehavior(et),S.registerBehavior(nt),S.registerBehavior(rt),S.registerBehavior(it),S.registerBehavior(ot),S.registerBehavior(st),S.registerBehavior(at)},1034:function(t,e,n){"use strict";n.d(e,{R:function(){return r}}); -/*! - * @pixi/runner - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/runner is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var r=function(){function t(t){this.items=[],this._name=t,this._aliasCount=0}return t.prototype.emit=function(t,e,n,r,i,o,s,a){if(arguments.length>8)throw new Error("max arguments reached");var u=this,l=u.name,c=u.items;this._aliasCount++;for(var h=0,f=c.length;h<f;h++)c[h][l](t,e,n,r,i,o,s,a);return c===this.items&&this._aliasCount--,this},t.prototype.ensureNonAliasedItems=function(){this._aliasCount>0&&this.items.length>1&&(this._aliasCount=0,this.items=this.items.slice(0))},t.prototype.add=function(t){return t[this._name]&&(this.ensureNonAliasedItems(),this.remove(t),this.items.push(t)),this},t.prototype.remove=function(t){var e=this.items.indexOf(t);return-1!==e&&(this.ensureNonAliasedItems(),this.items.splice(e,1)),this},t.prototype.contains=function(t){return-1!==this.items.indexOf(t)},t.prototype.removeAll=function(){return this.ensureNonAliasedItems(),this.items.length=0,this},t.prototype.destroy=function(){this.removeAll(),this.items=null,this._name=null},Object.defineProperty(t.prototype,"empty",{get:function(){return 0===this.items.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return this._name},enumerable:!1,configurable:!0}),t}();Object.defineProperties(r.prototype,{dispatch:{value:r.prototype.emit},run:{value:r.prototype.emit}})},1576:function(t,e,n){"use strict";n.d(e,{t:function(){return k},X:function(){return j}});var r=/iPhone/i,i=/iPod/i,o=/iPad/i,s=/\biOS-universal(?:.+)Mac\b/i,a=/\bAndroid(?:.+)Mobile\b/i,u=/Android/i,l=/(?:SD4930UR|\bSilk(?:.+)Mobile\b)/i,c=/Silk/i,h=/Windows Phone/i,f=/\bWindows(?:.+)ARM\b/i,d=/BlackBerry/i,p=/BB10/i,m=/Opera Mini/i,v=/\b(CriOS|Chrome)(?:.+)Mobile/i,g=/Mobile(?:.+)Firefox\b/i,_=function(t){return"undefined"!==typeof t&&"MacIntel"===t.platform&&"number"===typeof t.maxTouchPoints&&t.maxTouchPoints>1&&"undefined"===typeof MSStream};function y(t){return function(e){return e.test(t)}}function b(t){var e={userAgent:"",platform:"",maxTouchPoints:0};t||"undefined"===typeof navigator?"string"===typeof t?e.userAgent=t:t&&t.userAgent&&(e={userAgent:t.userAgent,platform:t.platform,maxTouchPoints:t.maxTouchPoints||0}):e={userAgent:navigator.userAgent,platform:navigator.platform,maxTouchPoints:navigator.maxTouchPoints||0};var n=e.userAgent,b=n.split("[FBAN");"undefined"!==typeof b[1]&&(n=b[0]),b=n.split("Twitter"),"undefined"!==typeof b[1]&&(n=b[0]);var E=y(n),T={apple:{phone:E(r)&&!E(h),ipod:E(i),tablet:!E(r)&&(E(o)||_(e))&&!E(h),universal:E(s),device:(E(r)||E(i)||E(o)||E(s)||_(e))&&!E(h)},amazon:{phone:E(l),tablet:!E(l)&&E(c),device:E(l)||E(c)},android:{phone:!E(h)&&E(l)||!E(h)&&E(a),tablet:!E(h)&&!E(l)&&!E(a)&&(E(c)||E(u)),device:!E(h)&&(E(l)||E(c)||E(a)||E(u))||E(/\bokhttp\b/i)},windows:{phone:E(h),tablet:E(f),device:E(h)||E(f)},other:{blackberry:E(d),blackberry10:E(p),opera:E(m),firefox:E(g),chrome:E(v),device:E(d)||E(p)||E(m)||E(g)||E(v)},any:!1,phone:!1,tablet:!1};return T.any=T.apple.device||T.android.device||T.windows.device||T.other.device,T.phone=T.apple.phone||T.android.phone||T.windows.phone,T.tablet=T.apple.tablet||T.android.tablet||T.windows.tablet,T} -/*! - * @pixi/settings - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/settings is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var E,T,x,S,R,A,O,I,w,C,P,N,M,D,L,B,F,U,G,k=b(globalThis.navigator);function X(t){var e=!0;if(k.tablet||k.phone){if(k.apple.device){var n=navigator.userAgent.match(/OS (\d+)_(\d+)?/);if(n){var r=parseInt(n[1],10);r<11&&(e=!1)}}if(k.android.device){n=navigator.userAgent.match(/Android\s([0-9.]*)/);if(n){r=parseInt(n[1],10);r<7&&(e=!1)}}}return e?t:4}function H(){return!k.apple.device} -/*! - * @pixi/constants - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/constants is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */(function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"})(E||(E={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(T||(T={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(x||(x={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(S||(S={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(R||(R={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(A||(A={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(O||(O={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(I||(I={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(w||(w={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(C||(C={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(P||(P={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(N||(N={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(M||(M={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(D||(D={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(L||(L={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(B||(B={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(F||(F={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(U||(U={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(G||(G={}));var j={MIPMAP_TEXTURES:N.POW2,ANISOTROPIC_LEVEL:0,RESOLUTION:1,FILTER_RESOLUTION:1,FILTER_MULTISAMPLE:U.NONE,SPRITE_MAX_TEXTURES:X(32),SPRITE_BATCH_SIZE:4096,RENDER_OPTIONS:{view:null,antialias:!1,autoDensity:!1,backgroundColor:0,backgroundAlpha:1,useContextAlpha:!0,clearBeforeRender:!0,preserveDrawingBuffer:!1,width:800,height:600,legacy:!1},GC_MODE:L.AUTO,GC_MAX_IDLE:3600,GC_MAX_CHECK_COUNT:600,WRAP_MODE:P.CLAMP,SCALE_MODE:C.LINEAR,PRECISION_VERTEX:B.HIGH,PRECISION_FRAGMENT:k.apple.device?B.HIGH:B.MEDIUM,CAN_UPLOAD_SAME_BUFFER:H(),CREATE_IMAGE_BITMAP:!1,ROUND_PIXELS:!1}},8033:function(t,e,n){"use strict";n.d(e,{j:function(){return d}});var r=n(1680),i=n(2038),o=n(1585),s=n(9658),a=n(1576),u=n(8942),l=function(t,e){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},l(t,e)};function c(t,e){function n(){this.constructor=t}l(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var h=new s.E9,f=new Uint16Array([0,1,2,0,2,3]),d=function(t){function e(e){var n=t.call(this)||this;return n._anchor=new s.AB(n._onAnchorUpdate,n,e?e.defaultAnchor.x:0,e?e.defaultAnchor.y:0),n._texture=null,n._width=0,n._height=0,n._tint=null,n._tintRGB=null,n.tint=16777215,n.blendMode=r.T$.NORMAL,n._cachedTint=16777215,n.uvs=null,n.texture=e||i.xE.EMPTY,n.vertexData=new Float32Array(8),n.vertexTrimmedData=null,n._transformID=-1,n._textureID=-1,n._transformTrimmedID=-1,n._textureTrimmedID=-1,n.indices=f,n.pluginName="batch",n.isSprite=!0,n._roundPixels=a.X.ROUND_PIXELS,n}return c(e,t),e.prototype._onTextureUpdate=function(){this._textureID=-1,this._textureTrimmedID=-1,this._cachedTint=16777215,this._width&&(this.scale.x=(0,u.Xx)(this.scale.x)*this._width/this._texture.orig.width),this._height&&(this.scale.y=(0,u.Xx)(this.scale.y)*this._height/this._texture.orig.height)},e.prototype._onAnchorUpdate=function(){this._transformID=-1,this._transformTrimmedID=-1},e.prototype.calculateVertices=function(){var t=this._texture;if(this._transformID!==this.transform._worldID||this._textureID!==t._updateID){this._textureID!==t._updateID&&(this.uvs=this._texture._uvs.uvsFloat32),this._transformID=this.transform._worldID,this._textureID=t._updateID;var e=this.transform.worldTransform,n=e.a,r=e.b,i=e.c,o=e.d,s=e.tx,u=e.ty,l=this.vertexData,c=t.trim,h=t.orig,f=this._anchor,d=0,p=0,m=0,v=0;if(c?(p=c.x-f._x*h.width,d=p+c.width,v=c.y-f._y*h.height,m=v+c.height):(p=-f._x*h.width,d=p+h.width,v=-f._y*h.height,m=v+h.height),l[0]=n*p+i*v+s,l[1]=o*v+r*p+u,l[2]=n*d+i*v+s,l[3]=o*v+r*d+u,l[4]=n*d+i*m+s,l[5]=o*m+r*d+u,l[6]=n*p+i*m+s,l[7]=o*m+r*p+u,this._roundPixels)for(var g=a.X.RESOLUTION,_=0;_<l.length;++_)l[_]=Math.round((l[_]*g|0)/g)}},e.prototype.calculateTrimmedVertices=function(){if(this.vertexTrimmedData){if(this._transformTrimmedID===this.transform._worldID&&this._textureTrimmedID===this._texture._updateID)return}else this.vertexTrimmedData=new Float32Array(8);this._transformTrimmedID=this.transform._worldID,this._textureTrimmedID=this._texture._updateID;var t=this._texture,e=this.vertexTrimmedData,n=t.orig,r=this._anchor,i=this.transform.worldTransform,o=i.a,s=i.b,a=i.c,u=i.d,l=i.tx,c=i.ty,h=-r._x*n.width,f=h+n.width,d=-r._y*n.height,p=d+n.height;e[0]=o*h+a*d+l,e[1]=u*d+s*h+c,e[2]=o*f+a*d+l,e[3]=u*d+s*f+c,e[4]=o*f+a*p+l,e[5]=u*p+s*f+c,e[6]=o*h+a*p+l,e[7]=u*p+s*h+c},e.prototype._render=function(t){this.calculateVertices(),t.batch.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this)},e.prototype._calculateBounds=function(){var t=this._texture.trim,e=this._texture.orig;!t||t.width===e.width&&t.height===e.height?(this.calculateVertices(),this._bounds.addQuad(this.vertexData)):(this.calculateTrimmedVertices(),this._bounds.addQuad(this.vertexTrimmedData))},e.prototype.getLocalBounds=function(e){return 0===this.children.length?(this._localBounds||(this._localBounds=new o.YZ),this._localBounds.minX=this._texture.orig.width*-this._anchor._x,this._localBounds.minY=this._texture.orig.height*-this._anchor._y,this._localBounds.maxX=this._texture.orig.width*(1-this._anchor._x),this._localBounds.maxY=this._texture.orig.height*(1-this._anchor._y),e||(this._localBoundsRect||(this._localBoundsRect=new s.Ae),e=this._localBoundsRect),this._localBounds.getRectangle(e)):t.prototype.getLocalBounds.call(this,e)},e.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,h);var e=this._texture.orig.width,n=this._texture.orig.height,r=-e*this.anchor.x,i=0;return h.x>=r&&h.x<r+e&&(i=-n*this.anchor.y,h.y>=i&&h.y<i+n)},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this._texture.off("update",this._onTextureUpdate,this),this._anchor=null;var n="boolean"===typeof e?e:e&&e.texture;if(n){var r="boolean"===typeof e?e:e&&e.baseTexture;this._texture.destroy(!!r)}this._texture=null},e.from=function(t,n){var r=t instanceof i.xE?t:i.xE.from(t,n);return new e(r)},Object.defineProperty(e.prototype,"roundPixels",{get:function(){return this._roundPixels},set:function(t){this._roundPixels!==t&&(this._transformID=-1),this._roundPixels=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"width",{get:function(){return Math.abs(this.scale.x)*this._texture.orig.width},set:function(t){var e=(0,u.Xx)(this.scale.x)||1;this.scale.x=e*t/this._texture.orig.width,this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return Math.abs(this.scale.y)*this._texture.orig.height},set:function(t){var e=(0,u.Xx)(this.scale.y)||1;this.scale.y=e*t/this._texture.orig.height,this._height=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"anchor",{get:function(){return this._anchor},set:function(t){this._anchor.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){this._tint=t,this._tintRGB=(t>>16)+(65280&t)+((255&t)<<16)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"texture",{get:function(){return this._texture},set:function(t){this._texture!==t&&(this._texture&&this._texture.off("update",this._onTextureUpdate,this),this._texture=t||i.xE.EMPTY,this._cachedTint=16777215,this._textureID=-1,this._textureTrimmedID=-1,t&&(t.baseTexture.valid?this._onTextureUpdate():t.once("update",this._onTextureUpdate,this)))},enumerable:!1,configurable:!0}),e}(o.W2)},6679:function(t,e,n){"use strict";n.d(e,{vB:function(){return s},Sb:function(){return a},uF:function(){return r}});var r,i=n(1576); -/*! - * @pixi/ticker - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/ticker is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */i.X.TARGET_FPMS=.06,function(t){t[t["INTERACTION"]=50]="INTERACTION",t[t["HIGH"]=25]="HIGH",t[t["NORMAL"]=0]="NORMAL",t[t["LOW"]=-25]="LOW",t[t["UTILITY"]=-50]="UTILITY"}(r||(r={}));var o=function(){function t(t,e,n,r){void 0===e&&(e=null),void 0===n&&(n=0),void 0===r&&(r=!1),this.next=null,this.previous=null,this._destroyed=!1,this.fn=t,this.context=e,this.priority=n,this.once=r}return t.prototype.match=function(t,e){return void 0===e&&(e=null),this.fn===t&&this.context===e},t.prototype.emit=function(t){this.fn&&(this.context?this.fn.call(this.context,t):this.fn(t));var e=this.next;return this.once&&this.destroy(!0),this._destroyed&&(this.next=null),e},t.prototype.connect=function(t){this.previous=t,t.next&&(t.next.previous=this),this.next=t.next,t.next=this},t.prototype.destroy=function(t){void 0===t&&(t=!1),this._destroyed=!0,this.fn=null,this.context=null,this.previous&&(this.previous.next=this.next),this.next&&(this.next.previous=this.previous);var e=this.next;return this.next=t?null:e,this.previous=null,e},t}(),s=function(){function t(){var t=this;this.autoStart=!1,this.deltaTime=1,this.lastTime=-1,this.speed=1,this.started=!1,this._requestId=null,this._maxElapsedMS=100,this._minElapsedMS=0,this._protected=!1,this._lastFrame=-1,this._head=new o(null,null,1/0),this.deltaMS=1/i.X.TARGET_FPMS,this.elapsedMS=1/i.X.TARGET_FPMS,this._tick=function(e){t._requestId=null,t.started&&(t.update(e),t.started&&null===t._requestId&&t._head.next&&(t._requestId=requestAnimationFrame(t._tick)))}}return t.prototype._requestIfNeeded=function(){null===this._requestId&&this._head.next&&(this.lastTime=performance.now(),this._lastFrame=this.lastTime,this._requestId=requestAnimationFrame(this._tick))},t.prototype._cancelIfNeeded=function(){null!==this._requestId&&(cancelAnimationFrame(this._requestId),this._requestId=null)},t.prototype._startIfPossible=function(){this.started?this._requestIfNeeded():this.autoStart&&this.start()},t.prototype.add=function(t,e,n){return void 0===n&&(n=r.NORMAL),this._addListener(new o(t,e,n))},t.prototype.addOnce=function(t,e,n){return void 0===n&&(n=r.NORMAL),this._addListener(new o(t,e,n,!0))},t.prototype._addListener=function(t){var e=this._head.next,n=this._head;if(e){while(e){if(t.priority>e.priority){t.connect(n);break}n=e,e=e.next}t.previous||t.connect(n)}else t.connect(n);return this._startIfPossible(),this},t.prototype.remove=function(t,e){var n=this._head.next;while(n)n=n.match(t,e)?n.destroy():n.next;return this._head.next||this._cancelIfNeeded(),this},Object.defineProperty(t.prototype,"count",{get:function(){if(!this._head)return 0;var t=0,e=this._head;while(e=e.next)t++;return t},enumerable:!1,configurable:!0}),t.prototype.start=function(){this.started||(this.started=!0,this._requestIfNeeded())},t.prototype.stop=function(){this.started&&(this.started=!1,this._cancelIfNeeded())},t.prototype.destroy=function(){if(!this._protected){this.stop();var t=this._head.next;while(t)t=t.destroy(!0);this._head.destroy(),this._head=null}},t.prototype.update=function(t){var e;if(void 0===t&&(t=performance.now()),t>this.lastTime){if(e=this.elapsedMS=t-this.lastTime,e>this._maxElapsedMS&&(e=this._maxElapsedMS),e*=this.speed,this._minElapsedMS){var n=t-this._lastFrame|0;if(n<this._minElapsedMS)return;this._lastFrame=t-n%this._minElapsedMS}this.deltaMS=e,this.deltaTime=this.deltaMS*i.X.TARGET_FPMS;var r=this._head,o=r.next;while(o)o=o.emit(this.deltaTime);r.next||this._cancelIfNeeded()}else this.deltaTime=this.deltaMS=this.elapsedMS=0;this.lastTime=t},Object.defineProperty(t.prototype,"FPS",{get:function(){return 1e3/this.elapsedMS},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"minFPS",{get:function(){return 1e3/this._maxElapsedMS},set:function(t){var e=Math.min(this.maxFPS,t),n=Math.min(Math.max(0,e)/1e3,i.X.TARGET_FPMS);this._maxElapsedMS=1/n},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"maxFPS",{get:function(){return this._minElapsedMS?Math.round(1e3/this._minElapsedMS):0},set:function(t){if(0===t)this._minElapsedMS=0;else{var e=Math.max(this.minFPS,t);this._minElapsedMS=1/(e/1e3)}},enumerable:!1,configurable:!0}),Object.defineProperty(t,"shared",{get:function(){if(!t._shared){var e=t._shared=new t;e.autoStart=!0,e._protected=!0}return t._shared},enumerable:!1,configurable:!0}),Object.defineProperty(t,"system",{get:function(){if(!t._system){var e=t._system=new t;e.autoStart=!0,e._protected=!0}return t._system},enumerable:!1,configurable:!0}),t}(),a=function(){function t(){}return t.init=function(t){var e=this;t=Object.assign({autoStart:!0,sharedTicker:!1},t),Object.defineProperty(this,"ticker",{set:function(t){this._ticker&&this._ticker.remove(this.render,this),this._ticker=t,t&&t.add(this.render,this,r.LOW)},get:function(){return this._ticker}}),this.stop=function(){e._ticker.stop()},this.start=function(){e._ticker.start()},this._ticker=null,this.ticker=t.sharedTicker?s.shared:new s,t.autoStart&&this.start()},t.destroy=function(){if(this._ticker){var t=this._ticker;this.ticker=null,t.destroy()}},t}()},8942:function(t,e,n){"use strict";n.d(e,{tq:function(){return r.t},vp:function(){return o.a},OT:function(){return a.a},V8:function(){return An},qU:function(){return On},GG:function(){return Sn},kN:function(){return Rn},D:function(){return ln},fl:function(){return dn},a1:function(){return xn},Qq:function(){return Cn},u7:function(){return pn},fL:function(){return Pn},wK:function(){return rn},XN:function(){return on},wv:function(){return vn},HR:function(){return m},k3:function(){return gn},a9:function(){return mn},YA:function(){return un},Qt:function(){return cn},rA:function(){return hn},GT:function(){return fn},Er:function(){return _n},DE:function(){return p},Xx:function(){return yn},qm:function(){return sn},yA:function(){return In},hQ:function(){return En},HQ:function(){return c}});var r=n(1576),i=n(8718),o=n.n(i),s=n(9187),a=n.n(s),u=n(8575),l=n(1680),c={parse:u.Qc,format:u.WU,resolve:u.DB};r.X.RETINA_PREFIX=/@([0-9\.]+)x/,r.X.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT=!1;var h,f=!1,d="6.3.0";function p(t){var e;if(!f){if(navigator.userAgent.toLowerCase().indexOf("chrome")>-1){var n=["\n %c %c %c PixiJS "+d+" - ✰ "+t+" ✰ %c %c http://www.pixijs.com/ %c %c ♥%c♥%c♥ \n\n","background: #ff66a5; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff66a5; background: #030307; padding:5px 0;","background: #ff66a5; padding:5px 0;","background: #ffc3dc; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;"];(e=globalThis.console).log.apply(e,n)}else globalThis.console&&globalThis.console.log("PixiJS "+d+" - "+t+" - http://www.pixijs.com/");f=!0}}function m(){return"undefined"===typeof h&&(h=function(){var t={stencil:!0,failIfMajorPerformanceCaveat:r.X.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT};try{if(!globalThis.WebGLRenderingContext)return!1;var e=document.createElement("canvas"),n=e.getContext("webgl",t)||e.getContext("experimental-webgl",t),i=!(!n||!n.getContextAttributes().stencil);if(n){var o=n.getExtension("WEBGL_lose_context");o&&o.loseContext()}return n=null,i}catch(s){return!1}}()),h}var v="#f0f8ff",g="#faebd7",_="#00ffff",y="#7fffd4",b="#f0ffff",E="#f5f5dc",T="#ffe4c4",x="#000000",S="#ffebcd",R="#0000ff",A="#8a2be2",O="#a52a2a",I="#deb887",w="#5f9ea0",C="#7fff00",P="#d2691e",N="#ff7f50",M="#6495ed",D="#fff8dc",L="#dc143c",B="#00ffff",F="#00008b",U="#008b8b",G="#b8860b",k="#a9a9a9",X="#006400",H="#a9a9a9",j="#bdb76b",V="#8b008b",Y="#556b2f",W="#ff8c00",z="#9932cc",$="#8b0000",q="#e9967a",K="#8fbc8f",Z="#483d8b",J="#2f4f4f",Q="#2f4f4f",tt="#00ced1",et="#9400d3",nt="#ff1493",rt="#00bfff",it="#696969",ot="#696969",st="#1e90ff",at="#b22222",ut="#fffaf0",lt="#228b22",ct="#ff00ff",ht="#dcdcdc",ft="#f8f8ff",dt="#daa520",pt="#ffd700",mt="#808080",vt="#008000",gt="#adff2f",_t="#808080",yt="#f0fff0",bt="#ff69b4",Et="#cd5c5c",Tt="#4b0082",xt="#fffff0",St="#f0e68c",Rt="#fff0f5",At="#e6e6fa",Ot="#7cfc00",It="#fffacd",wt="#add8e6",Ct="#f08080",Pt="#e0ffff",Nt="#fafad2",Mt="#d3d3d3",Dt="#90ee90",Lt="#d3d3d3",Bt="#ffb6c1",Ft="#ffa07a",Ut="#20b2aa",Gt="#87cefa",kt="#778899",Xt="#778899",Ht="#b0c4de",jt="#ffffe0",Vt="#00ff00",Yt="#32cd32",Wt="#faf0e6",zt="#ff00ff",$t="#800000",qt="#66cdaa",Kt="#0000cd",Zt="#ba55d3",Jt="#9370db",Qt="#3cb371",te="#7b68ee",ee="#00fa9a",ne="#48d1cc",re="#c71585",ie="#191970",oe="#f5fffa",se="#ffe4e1",ae="#ffe4b5",ue="#ffdead",le="#000080",ce="#fdf5e6",he="#808000",fe="#6b8e23",de="#ffa500",pe="#ff4500",me="#da70d6",ve="#eee8aa",ge="#98fb98",_e="#afeeee",ye="#db7093",be="#ffefd5",Ee="#ffdab9",Te="#cd853f",xe="#ffc0cb",Se="#dda0dd",Re="#b0e0e6",Ae="#800080",Oe="#663399",Ie="#ff0000",we="#bc8f8f",Ce="#4169e1",Pe="#8b4513",Ne="#fa8072",Me="#f4a460",De="#2e8b57",Le="#fff5ee",Be="#a0522d",Fe="#c0c0c0",Ue="#87ceeb",Ge="#6a5acd",ke="#708090",Xe="#708090",He="#fffafa",je="#00ff7f",Ve="#4682b4",Ye="#d2b48c",We="#008080",ze="#d8bfd8",$e="#ff6347",qe="#40e0d0",Ke="#ee82ee",Ze="#f5deb3",Je="#ffffff",Qe="#f5f5f5",tn="#ffff00",en="#9acd32",nn={aliceblue:v,antiquewhite:g,aqua:_,aquamarine:y,azure:b,beige:E,bisque:T,black:x,blanchedalmond:S,blue:R,blueviolet:A,brown:O,burlywood:I,cadetblue:w,chartreuse:C,chocolate:P,coral:N,cornflowerblue:M,cornsilk:D,crimson:L,cyan:B,darkblue:F,darkcyan:U,darkgoldenrod:G,darkgray:k,darkgreen:X,darkgrey:H,darkkhaki:j,darkmagenta:V,darkolivegreen:Y,darkorange:W,darkorchid:z,darkred:$,darksalmon:q,darkseagreen:K,darkslateblue:Z,darkslategray:J,darkslategrey:Q,darkturquoise:tt,darkviolet:et,deeppink:nt,deepskyblue:rt,dimgray:it,dimgrey:ot,dodgerblue:st,firebrick:at,floralwhite:ut,forestgreen:lt,fuchsia:ct,gainsboro:ht,ghostwhite:ft,goldenrod:dt,gold:pt,gray:mt,green:vt,greenyellow:gt,grey:_t,honeydew:yt,hotpink:bt,indianred:Et,indigo:Tt,ivory:xt,khaki:St,lavenderblush:Rt,lavender:At,lawngreen:Ot,lemonchiffon:It,lightblue:wt,lightcoral:Ct,lightcyan:Pt,lightgoldenrodyellow:Nt,lightgray:Mt,lightgreen:Dt,lightgrey:Lt,lightpink:Bt,lightsalmon:Ft,lightseagreen:Ut,lightskyblue:Gt,lightslategray:kt,lightslategrey:Xt,lightsteelblue:Ht,lightyellow:jt,lime:Vt,limegreen:Yt,linen:Wt,magenta:zt,maroon:$t,mediumaquamarine:qt,mediumblue:Kt,mediumorchid:Zt,mediumpurple:Jt,mediumseagreen:Qt,mediumslateblue:te,mediumspringgreen:ee,mediumturquoise:ne,mediumvioletred:re,midnightblue:ie,mintcream:oe,mistyrose:se,moccasin:ae,navajowhite:ue,navy:le,oldlace:ce,olive:he,olivedrab:fe,orange:de,orangered:pe,orchid:me,palegoldenrod:ve,palegreen:ge,paleturquoise:_e,palevioletred:ye,papayawhip:be,peachpuff:Ee,peru:Te,pink:xe,plum:Se,powderblue:Re,purple:Ae,rebeccapurple:Oe,red:Ie,rosybrown:we,royalblue:Ce,saddlebrown:Pe,salmon:Ne,sandybrown:Me,seagreen:De,seashell:Le,sienna:Be,silver:Fe,skyblue:Ue,slateblue:Ge,slategray:ke,slategrey:Xe,snow:He,springgreen:je,steelblue:Ve,tan:Ye,teal:We,thistle:ze,tomato:$e,turquoise:qe,violet:Ke,wheat:Ze,white:Je,whitesmoke:Qe,yellow:tn,yellowgreen:en};function rn(t,e){return void 0===e&&(e=[]),e[0]=(t>>16&255)/255,e[1]=(t>>8&255)/255,e[2]=(255&t)/255,e}function on(t){var e=t.toString(16);return e="000000".substring(0,6-e.length)+e,"#"+e}function sn(t){return"string"===typeof t&&(t=nn[t.toLowerCase()]||t,"#"===t[0]&&(t=t.slice(1))),parseInt(t,16)}function an(){for(var t=[],e=[],n=0;n<32;n++)t[n]=n,e[n]=n;t[l.T$.NORMAL_NPM]=l.T$.NORMAL,t[l.T$.ADD_NPM]=l.T$.ADD,t[l.T$.SCREEN_NPM]=l.T$.SCREEN,e[l.T$.NORMAL]=l.T$.NORMAL_NPM,e[l.T$.ADD]=l.T$.ADD_NPM,e[l.T$.SCREEN]=l.T$.SCREEN_NPM;var r=[];return r.push(e),r.push(t),r}var un=an();function ln(t,e){return un[e?1:0][t]}function cn(t,e,n,r){return n=n||new Float32Array(4),r||void 0===r?(n[0]=t[0]*e,n[1]=t[1]*e,n[2]=t[2]*e):(n[0]=t[0],n[1]=t[1],n[2]=t[2]),n[3]=e,n}function hn(t,e){if(1===e)return(255*e<<24)+t;if(0===e)return 0;var n=t>>16&255,r=t>>8&255,i=255&t;return n=n*e+.5|0,r=r*e+.5|0,i=i*e+.5|0,(255*e<<24)+(n<<16)+(r<<8)+i}function fn(t,e,n,r){return n=n||new Float32Array(4),n[0]=(t>>16&255)/255,n[1]=(t>>8&255)/255,n[2]=(255&t)/255,(r||void 0===r)&&(n[0]*=e,n[1]*=e,n[2]*=e),n[3]=e,n}function dn(t,e){void 0===e&&(e=null);var n=6*t;if(e=e||new Uint16Array(n),e.length!==n)throw new Error("Out buffer length is incorrect, got "+e.length+" and expected "+n);for(var r=0,i=0;r<n;r+=6,i+=4)e[r+0]=i+0,e[r+1]=i+1,e[r+2]=i+2,e[r+3]=i+0,e[r+4]=i+2,e[r+5]=i+3;return e}function pn(t){if(4===t.BYTES_PER_ELEMENT)return t instanceof Float32Array?"Float32Array":t instanceof Uint32Array?"Uint32Array":"Int32Array";if(2===t.BYTES_PER_ELEMENT){if(t instanceof Uint16Array)return"Uint16Array"}else if(1===t.BYTES_PER_ELEMENT&&t instanceof Uint8Array)return"Uint8Array";return null}Float32Array,Uint32Array,Int32Array,Uint8Array;function mn(t){return t+=0===t?1:0,--t,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t+1}function vn(t){return!(t&t-1)&&!!t}function gn(t){var e=(t>65535?1:0)<<4;t>>>=e;var n=(t>255?1:0)<<3;return t>>>=n,e|=n,n=(t>15?1:0)<<2,t>>>=n,e|=n,n=(t>3?1:0)<<1,t>>>=n,e|=n,e|t>>1}function _n(t,e,n){var r,i=t.length;if(!(e>=i||0===n)){n=e+n>i?i-e:n;var o=i-n;for(r=e;r<o;++r)t[r]=t[r+n];t.length=o}}function yn(t){return 0===t?0:t<0?-1:1}var bn=0;function En(){return++bn}var Tn={};function xn(t,e,n){if(void 0===n&&(n=3),!Tn[e]){var r=(new Error).stack;"undefined"===typeof r?console.warn("PixiJS Deprecation Warning: ",e+"\nDeprecated since v"+t):(r=r.split("\n").splice(n).join("\n"),console.groupCollapsed?(console.groupCollapsed("%cPixiJS Deprecation Warning: %c%s","color:#614108;background:#fffbe6","font-weight:normal;color:#614108;background:#fffbe6",e+"\nDeprecated since v"+t),console.warn(r),console.groupEnd()):(console.warn("PixiJS Deprecation Warning: ",e+"\nDeprecated since v"+t),console.warn(r))),Tn[e]=!0}}var Sn={},Rn=Object.create(null),An=Object.create(null);var On=function(){function t(t,e,n){this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d"),this.resolution=n||r.X.RESOLUTION,this.resize(t,e)}return t.prototype.clear=function(){this.context.setTransform(1,0,0,1,0,0),this.context.clearRect(0,0,this.canvas.width,this.canvas.height)},t.prototype.resize=function(t,e){this.canvas.width=Math.round(t*this.resolution),this.canvas.height=Math.round(e*this.resolution)},t.prototype.destroy=function(){this.context=null,this.canvas=null},Object.defineProperty(t.prototype,"width",{get:function(){return this.canvas.width},set:function(t){this.canvas.width=Math.round(t)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this.canvas.height},set:function(t){this.canvas.height=Math.round(t)},enumerable:!1,configurable:!0}),t}();function In(t){var e,n,r,i=t.width,o=t.height,s=t.getContext("2d"),a=s.getImageData(0,0,i,o),u=a.data,l=u.length,c={top:null,left:null,right:null,bottom:null},h=null;for(e=0;e<l;e+=4)0!==u[e+3]&&(n=e/4%i,r=~~(e/4/i),null===c.top&&(c.top=r),(null===c.left||n<c.left)&&(c.left=n),(null===c.right||c.right<n)&&(c.right=n+1),(null===c.bottom||c.bottom<r)&&(c.bottom=r));return null!==c.top&&(i=c.right-c.left,o=c.bottom-c.top+1,h=s.getImageData(c.left,c.top,i,o)),{height:o,width:i,data:h}}var wn;function Cn(t,e){if(void 0===e&&(e=globalThis.location),0===t.indexOf("data:"))return"";e=e||globalThis.location,wn||(wn=document.createElement("a")),wn.href=t;var n=c.parse(wn.href),r=!n.port&&""===e.port||n.port===e.port;return n.hostname===e.hostname&&r&&n.protocol===e.protocol?"":"anonymous"}function Pn(t,e){var n=r.X.RETINA_PREFIX.exec(t);return n?parseFloat(n[1]):void 0!==e?e:1}},8718:function(t){"use strict";var e=Object.prototype.hasOwnProperty,n="~";function r(){}function i(t,e,n){this.fn=t,this.context=e,this.once=n||!1}function o(t,e,r,o,s){if("function"!==typeof r)throw new TypeError("The listener must be a function");var a=new i(r,o||t,s),u=n?n+e:e;return t._events[u]?t._events[u].fn?t._events[u]=[t._events[u],a]:t._events[u].push(a):(t._events[u]=a,t._eventsCount++),t}function s(t,e){0===--t._eventsCount?t._events=new r:delete t._events[e]}function a(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),a.prototype.eventNames=function(){var t,r,i=[];if(0===this._eventsCount)return i;for(r in t=this._events)e.call(t,r)&&i.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(t)):i},a.prototype.listeners=function(t){var e=n?n+t:t,r=this._events[e];if(!r)return[];if(r.fn)return[r.fn];for(var i=0,o=r.length,s=new Array(o);i<o;i++)s[i]=r[i].fn;return s},a.prototype.listenerCount=function(t){var e=n?n+t:t,r=this._events[e];return r?r.fn?1:r.length:0},a.prototype.emit=function(t,e,r,i,o,s){var a=n?n+t:t;if(!this._events[a])return!1;var u,l,c=this._events[a],h=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),h){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,r),!0;case 4:return c.fn.call(c.context,e,r,i),!0;case 5:return c.fn.call(c.context,e,r,i,o),!0;case 6:return c.fn.call(c.context,e,r,i,o,s),!0}for(l=1,u=new Array(h-1);l<h;l++)u[l-1]=arguments[l];c.fn.apply(c.context,u)}else{var f,d=c.length;for(l=0;l<d;l++)switch(c[l].once&&this.removeListener(t,c[l].fn,void 0,!0),h){case 1:c[l].fn.call(c[l].context);break;case 2:c[l].fn.call(c[l].context,e);break;case 3:c[l].fn.call(c[l].context,e,r);break;case 4:c[l].fn.call(c[l].context,e,r,i);break;default:if(!u)for(f=1,u=new Array(h-1);f<h;f++)u[f-1]=arguments[f];c[l].fn.apply(c[l].context,u)}}return!0},a.prototype.on=function(t,e,n){return o(this,t,e,n,!1)},a.prototype.once=function(t,e,n){return o(this,t,e,n,!0)},a.prototype.removeListener=function(t,e,r,i){var o=n?n+t:t;if(!this._events[o])return this;if(!e)return s(this,o),this;var a=this._events[o];if(a.fn)a.fn!==e||i&&!a.once||r&&a.context!==r||s(this,o);else{for(var u=0,l=[],c=a.length;u<c;u++)(a[u].fn!==e||i&&!a[u].once||r&&a[u].context!==r)&&l.push(a[u]);l.length?this._events[o]=1===l.length?l[0]:l:s(this,o)}return this},a.prototype.removeAllListeners=function(t){var e;return t?(e=n?n+t:t,this._events[e]&&s(this,e)):(this._events=new r,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=n,a.EventEmitter=a,t.exports=a},3577:function(t,e,n){"use strict";function r(t,e){const n=Object.create(null),r=t.split(",");for(let i=0;i<r.length;i++)n[r[i]]=!0;return e?t=>!!n[t.toLowerCase()]:t=>!!n[t]}n.d(e,{Z6:function(){return C},kT:function(){return w},NO:function(){return N},dG:function(){return P},m:function(){return i},_A:function(){return rt},kC:function(){return st},Nj:function(){return ct},l7:function(){return B},Kp:function(){return u},E9:function(){return dt},aU:function(){return ut},RI:function(){return G},rs:function(){return ot},yA:function(){return h},ir:function(){return lt},kJ:function(){return k},mf:function(){return V},e1:function(){return s},eS:function(){return E},S0:function(){return Q},_N:function(){return X},tR:function(){return L},Kn:function(){return z},F7:function(){return D},PO:function(){return J},tI:function(){return $},Gg:function(){return tt},aN:function(){return T},DM:function(){return H},Pq:function(){return c},HD:function(){return Y},yk:function(){return W},WB:function(){return x},WV:function(){return R},hq:function(){return A},fY:function(){return r},C_:function(){return v},vs:function(){return g},j5:function(){return f},yL:function(){return m},Od:function(){return F},zw:function(){return O},hR:function(){return at},He:function(){return ht},W7:function(){return Z}});const i={[1]:"TEXT",[2]:"CLASS",[4]:"STYLE",[8]:"PROPS",[16]:"FULL_PROPS",[32]:"HYDRATE_EVENTS",[64]:"STABLE_FRAGMENT",[128]:"KEYED_FRAGMENT",[256]:"UNKEYED_FRAGMENT",[512]:"NEED_PATCH",[1024]:"DYNAMIC_SLOTS",[2048]:"DEV_ROOT_FRAGMENT",[-1]:"HOISTED",[-2]:"BAIL"},o="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt",s=r(o),a=2;function u(t,e=0,n=t.length){let r=t.split(/(\r?\n)/);const i=r.filter(((t,e)=>e%2===1));r=r.filter(((t,e)=>e%2===0));let o=0;const s=[];for(let u=0;u<r.length;u++)if(o+=r[u].length+(i[u]&&i[u].length||0),o>=e){for(let t=u-a;t<=u+a||n>o;t++){if(t<0||t>=r.length)continue;const a=t+1;s.push(`${a}${" ".repeat(Math.max(3-String(a).length,0))}| ${r[t]}`);const l=r[t].length,c=i[t]&&i[t].length||0;if(t===u){const t=e-(o-(l+c)),r=Math.max(1,n>o?l-t:n-e);s.push(" | "+" ".repeat(t)+"^".repeat(r))}else if(t>u){if(n>o){const t=Math.max(Math.min(n-o,l),1);s.push(" | "+"^".repeat(t))}o+=l+c}}break}return s.join("\n")}const l="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",c=r(l);function h(t){return!!t||""===t}function f(t){if(k(t)){const e={};for(let n=0;n<t.length;n++){const r=t[n],i=Y(r)?m(r):f(r);if(i)for(const t in i)e[t]=i[t]}return e}return Y(t)||z(t)?t:void 0}const d=/;(?![^(]*\))/g,p=/:(.+)/;function m(t){const e={};return t.split(d).forEach((t=>{if(t){const n=t.split(p);n.length>1&&(e[n[0].trim()]=n[1].trim())}})),e}function v(t){let e="";if(Y(t))e=t;else if(k(t))for(let n=0;n<t.length;n++){const r=v(t[n]);r&&(e+=r+" ")}else if(z(t))for(const n in t)t[n]&&(e+=n+" ");return e.trim()}function g(t){if(!t)return null;let{class:e,style:n}=t;return e&&!Y(e)&&(t.class=v(e)),n&&(t.style=f(n)),t}const _="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot",y="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",b="area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr",E=r(_),T=r(y),x=r(b);function S(t,e){if(t.length!==e.length)return!1;let n=!0;for(let r=0;n&&r<t.length;r++)n=R(t[r],e[r]);return n}function R(t,e){if(t===e)return!0;let n=j(t),r=j(e);if(n||r)return!(!n||!r)&&t.getTime()===e.getTime();if(n=k(t),r=k(e),n||r)return!(!n||!r)&&S(t,e);if(n=z(t),r=z(e),n||r){if(!n||!r)return!1;const i=Object.keys(t).length,o=Object.keys(e).length;if(i!==o)return!1;for(const n in t){const r=t.hasOwnProperty(n),i=e.hasOwnProperty(n);if(r&&!i||!r&&i||!R(t[n],e[n]))return!1}}return String(t)===String(e)}function A(t,e){return t.findIndex((t=>R(t,e)))}const O=t=>null==t?"":k(t)||z(t)&&(t.toString===q||!V(t.toString))?JSON.stringify(t,I,2):String(t),I=(t,e)=>e&&e.__v_isRef?I(t,e.value):X(e)?{[`Map(${e.size})`]:[...e.entries()].reduce(((t,[e,n])=>(t[`${e} =>`]=n,t)),{})}:H(e)?{[`Set(${e.size})`]:[...e.values()]}:!z(e)||k(e)||J(e)?e:String(e),w={},C=[],P=()=>{},N=()=>!1,M=/^on[^a-z]/,D=t=>M.test(t),L=t=>t.startsWith("onUpdate:"),B=Object.assign,F=(t,e)=>{const n=t.indexOf(e);n>-1&&t.splice(n,1)},U=Object.prototype.hasOwnProperty,G=(t,e)=>U.call(t,e),k=Array.isArray,X=t=>"[object Map]"===K(t),H=t=>"[object Set]"===K(t),j=t=>t instanceof Date,V=t=>"function"===typeof t,Y=t=>"string"===typeof t,W=t=>"symbol"===typeof t,z=t=>null!==t&&"object"===typeof t,$=t=>z(t)&&V(t.then)&&V(t.catch),q=Object.prototype.toString,K=t=>q.call(t),Z=t=>K(t).slice(8,-1),J=t=>"[object Object]"===K(t),Q=t=>Y(t)&&"NaN"!==t&&"-"!==t[0]&&""+parseInt(t,10)===t,tt=r(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),et=t=>{const e=Object.create(null);return n=>{const r=e[n];return r||(e[n]=t(n))}},nt=/-(\w)/g,rt=et((t=>t.replace(nt,((t,e)=>e?e.toUpperCase():"")))),it=/\B([A-Z])/g,ot=et((t=>t.replace(it,"-$1").toLowerCase())),st=et((t=>t.charAt(0).toUpperCase()+t.slice(1))),at=et((t=>t?`on${st(t)}`:"")),ut=(t,e)=>!Object.is(t,e),lt=(t,e)=>{for(let n=0;n<t.length;n++)t[n](e)},ct=(t,e,n)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:n})},ht=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let ft;const dt=()=>ft||(ft="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof self?self:"undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:{})},423:function(t,e,n){"use strict";n.d(e,{Z:function(){return u}});var r=n(4865);function i(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createBlock)(r.Transition,{name:n.name,onBeforeAppear:s.beforeAppear,onAppear:s.appear,onAfterAppear:s.afterAppear,onAppearCancelled:s.appearCancelled,onBeforeEnter:s.beforeEnter,onEnter:s.enter,onAfterEnter:s.afterEnter,onEnterCancelled:s.enterCancelled,onBeforeLeave:s.beforeLeave,onLeave:s.leave,onAfterLeave:s.afterLeave,onLeaveCancelled:s.leaveCancelled},{default:(0,r.withCtx)((()=>[(0,r.renderSlot)(t.$slots,"default")])),_:3},8,["name","onBeforeAppear","onAppear","onAfterAppear","onAppearCancelled","onBeforeEnter","onEnter","onAfterEnter","onEnterCancelled","onBeforeLeave","onLeave","onAfterLeave","onLeaveCancelled"])}var o={name:"CollapseTransition",props:{name:{type:String,required:!1,default:"collapse"},dimension:{type:String,required:!1,default:"height",validator:t=>["height","width"].includes(t)},duration:{type:Number,required:!1,default:300},easing:{type:String,required:!1,default:"ease-in-out"}},watch:{dimension(){this.clearCachedDimensions()}},data(){return{cachedStyles:null}},computed:{transition(){let t=[];return Object.keys(this.cachedStyles).forEach((e=>{t.push(`${this.convertToCssProperty(e)} ${this.duration}ms ${this.easing}`)})),t.join(", ")}},methods:{beforeAppear(t){this.$emit("before-appear",t)},appear(t){this.$emit("appear",t)},afterAppear(t){this.$emit("after-appear",t)},appearCancelled(t){this.$emit("appear-cancelled",t)},beforeEnter(t){this.$emit("before-enter",t)},enter(t,e){this.detectAndCacheDimensions(t),this.setClosedDimensions(t),this.hideOverflow(t),this.forceRepaint(t),this.setTransition(t),this.setOpenedDimensions(t),this.$emit("enter",t,e),setTimeout(e,this.duration)},afterEnter(t){this.unsetOverflow(t),this.unsetTransition(t),this.unsetDimensions(t),this.clearCachedDimensions(),this.$emit("after-enter",t)},enterCancelled(t){this.$emit("enter-cancelled",t)},beforeLeave(t){this.$emit("before-leave",t)},leave(t,e){this.detectAndCacheDimensions(t),this.setOpenedDimensions(t),this.hideOverflow(t),this.forceRepaint(t),this.setTransition(t),this.setClosedDimensions(t),this.$emit("leave",t,e),setTimeout(e,this.duration)},afterLeave(t){this.unsetOverflow(t),this.unsetTransition(t),this.unsetDimensions(t),this.clearCachedDimensions(),this.$emit("after-leave",t)},leaveCancelled(t){this.$emit("leave-cancelled",t)},detectAndCacheDimensions(t){if(this.cachedStyles)return;const e=t.style.visibility,n=t.style.display;t.style.visibility="hidden",t.style.display="",this.cachedStyles=this.detectRelevantDimensions(t),t.style.visibility=e,t.style.display=n},clearCachedDimensions(){this.cachedStyles=null},detectRelevantDimensions(t){return"height"===this.dimension?{height:t.offsetHeight+"px",paddingTop:t.style.paddingTop||this.getCssValue(t,"padding-top"),paddingBottom:t.style.paddingBottom||this.getCssValue(t,"padding-bottom")}:"width"===this.dimension?{width:t.offsetWidth+"px",paddingLeft:t.style.paddingLeft||this.getCssValue(t,"padding-left"),paddingRight:t.style.paddingRight||this.getCssValue(t,"padding-right")}:{}},setTransition(t){t.style.transition=this.transition},unsetTransition(t){t.style.transition=""},hideOverflow(t){t.style.overflow="hidden"},unsetOverflow(t){t.style.overflow=""},setClosedDimensions(t){Object.keys(this.cachedStyles).forEach((e=>{t.style[e]="0"}))},setOpenedDimensions(t){Object.keys(this.cachedStyles).forEach((e=>{t.style[e]=this.cachedStyles[e]}))},unsetDimensions(t){Object.keys(this.cachedStyles).forEach((e=>{t.style[e]=""}))},forceRepaint(t){getComputedStyle(t)[this.dimension]},getCssValue(t,e){return getComputedStyle(t,null).getPropertyValue(e)},convertToCssProperty(t){const e=t.match(/([A-Z])/g);if(!e)return t;for(let n=0,r=e.length;n<r;n++)t=t.replace(new RegExp(e[n]),"-"+e[n].toLowerCase());return"-"===t.slice(0,1)&&(t=t.slice(1)),t}}},s=n(3744);const a=(0,s.Z)(o,[["render",i]]);var u=a},9662:function(t,e,n){var r=n(7854),i=n(614),o=n(6330),s=r.TypeError;t.exports=function(t){if(i(t))return t;throw s(o(t)+" is not a function")}},6077:function(t,e,n){var r=n(7854),i=n(614),o=r.String,s=r.TypeError;t.exports=function(t){if("object"==typeof t||i(t))return t;throw s("Can't set "+o(t)+" as a prototype")}},5787:function(t,e,n){var r=n(7854),i=n(7976),o=r.TypeError;t.exports=function(t,e){if(i(e,t))return t;throw o("Incorrect invocation")}},9670:function(t,e,n){var r=n(7854),i=n(111),o=r.String,s=r.TypeError;t.exports=function(t){if(i(t))return t;throw s(o(t)+" is not an object")}},1318:function(t,e,n){var r=n(5656),i=n(1400),o=n(6244),s=function(t){return function(e,n,s){var a,u=r(e),l=o(u),c=i(s,l);if(t&&n!=n){while(l>c)if(a=u[c++],a!=a)return!0}else for(;l>c;c++)if((t||c in u)&&u[c]===n)return t||c||0;return!t&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},4326:function(t,e,n){var r=n(1702),i=r({}.toString),o=r("".slice);t.exports=function(t){return o(i(t),8,-1)}},648:function(t,e,n){var r=n(7854),i=n(1694),o=n(614),s=n(4326),a=n(5112),u=a("toStringTag"),l=r.Object,c="Arguments"==s(function(){return arguments}()),h=function(t,e){try{return t[e]}catch(n){}};t.exports=i?s:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=h(e=l(t),u))?n:c?s(e):"Object"==(r=s(e))&&o(e.callee)?"Arguments":r}},7741:function(t,e,n){var r=n(1702),i=r("".replace),o=function(t){return String(Error(t).stack)}("zxcasd"),s=/\n\s*at [^:]*:[^\n]*/,a=s.test(o);t.exports=function(t,e){if(a&&"string"==typeof t)while(e--)t=i(t,s,"");return t}},9920:function(t,e,n){var r=n(2597),i=n(3887),o=n(1236),s=n(3070);t.exports=function(t,e,n){for(var a=i(e),u=s.f,l=o.f,c=0;c<a.length;c++){var h=a[c];r(t,h)||n&&r(n,h)||u(t,h,l(e,h))}}},8880:function(t,e,n){var r=n(9781),i=n(3070),o=n(9114);t.exports=r?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},9114:function(t){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},9781:function(t,e,n){var r=n(7293);t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},317:function(t,e,n){var r=n(7854),i=n(111),o=r.document,s=i(o)&&i(o.createElement);t.exports=function(t){return s?o.createElement(t):{}}},3678:function(t){t.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}},8113:function(t,e,n){var r=n(5005);t.exports=r("navigator","userAgent")||""},7392:function(t,e,n){var r,i,o=n(7854),s=n(8113),a=o.process,u=o.Deno,l=a&&a.versions||u&&u.version,c=l&&l.v8;c&&(r=c.split("."),i=r[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&s&&(r=s.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/),r&&(i=+r[1]))),t.exports=i},748:function(t){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},2914:function(t,e,n){var r=n(7293),i=n(9114);t.exports=!r((function(){var t=Error("a");return!("stack"in t)||(Object.defineProperty(t,"stack",i(1,7)),7!==t.stack)}))},2109:function(t,e,n){var r=n(7854),i=n(1236).f,o=n(8880),s=n(1320),a=n(3505),u=n(9920),l=n(4705);t.exports=function(t,e){var n,c,h,f,d,p,m=t.target,v=t.global,g=t.stat;if(c=v?r:g?r[m]||a(m,{}):(r[m]||{}).prototype,c)for(h in e){if(d=e[h],t.noTargetGet?(p=i(c,h),f=p&&p.value):f=c[h],n=l(v?h:m+(g?".":"#")+h,t.forced),!n&&void 0!==f){if(typeof d==typeof f)continue;u(d,f)}(t.sham||f&&f.sham)&&o(d,"sham",!0),s(c,h,d,t)}}},7293:function(t){t.exports=function(t){try{return!!t()}catch(e){return!0}}},2104:function(t){var e=Function.prototype,n=e.apply,r=e.bind,i=e.call;t.exports="object"==typeof Reflect&&Reflect.apply||(r?i.bind(n):function(){return i.apply(n,arguments)})},6916:function(t){var e=Function.prototype.call;t.exports=e.bind?e.bind(e):function(){return e.apply(e,arguments)}},6530:function(t,e,n){var r=n(9781),i=n(2597),o=Function.prototype,s=r&&Object.getOwnPropertyDescriptor,a=i(o,"name"),u=a&&"something"===function(){}.name,l=a&&(!r||r&&s(o,"name").configurable);t.exports={EXISTS:a,PROPER:u,CONFIGURABLE:l}},1702:function(t){var e=Function.prototype,n=e.bind,r=e.call,i=n&&n.bind(r,r);t.exports=n?function(t){return t&&i(t)}:function(t){return t&&function(){return r.apply(t,arguments)}}},5005:function(t,e,n){var r=n(7854),i=n(614),o=function(t){return i(t)?t:void 0};t.exports=function(t,e){return arguments.length<2?o(r[t]):r[t]&&r[t][e]}},8173:function(t,e,n){var r=n(9662);t.exports=function(t,e){var n=t[e];return null==n?void 0:r(n)}},7854:function(t,e,n){var r=function(t){return t&&t.Math==Math&&t};t.exports=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof n.g&&n.g)||function(){return this}()||Function("return this")()},2597:function(t,e,n){var r=n(1702),i=n(7908),o=r({}.hasOwnProperty);t.exports=Object.hasOwn||function(t,e){return o(i(t),e)}},3501:function(t){t.exports={}},4664:function(t,e,n){var r=n(9781),i=n(7293),o=n(317);t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},8361:function(t,e,n){var r=n(7854),i=n(1702),o=n(7293),s=n(4326),a=r.Object,u=i("".split);t.exports=o((function(){return!a("z").propertyIsEnumerable(0)}))?function(t){return"String"==s(t)?u(t,""):a(t)}:a},9587:function(t,e,n){var r=n(614),i=n(111),o=n(7674);t.exports=function(t,e,n){var s,a;return o&&r(s=e.constructor)&&s!==n&&i(a=s.prototype)&&a!==n.prototype&&o(t,a),t}},2788:function(t,e,n){var r=n(1702),i=n(614),o=n(5465),s=r(Function.toString);i(o.inspectSource)||(o.inspectSource=function(t){return s(t)}),t.exports=o.inspectSource},8340:function(t,e,n){var r=n(111),i=n(8880);t.exports=function(t,e){r(e)&&"cause"in e&&i(t,"cause",e.cause)}},9909:function(t,e,n){var r,i,o,s=n(8536),a=n(7854),u=n(1702),l=n(111),c=n(8880),h=n(2597),f=n(5465),d=n(6200),p=n(3501),m="Object already initialized",v=a.TypeError,g=a.WeakMap,_=function(t){return o(t)?i(t):r(t,{})},y=function(t){return function(e){var n;if(!l(e)||(n=i(e)).type!==t)throw v("Incompatible receiver, "+t+" required");return n}};if(s||f.state){var b=f.state||(f.state=new g),E=u(b.get),T=u(b.has),x=u(b.set);r=function(t,e){if(T(b,t))throw new v(m);return e.facade=t,x(b,t,e),e},i=function(t){return E(b,t)||{}},o=function(t){return T(b,t)}}else{var S=d("state");p[S]=!0,r=function(t,e){if(h(t,S))throw new v(m);return e.facade=t,c(t,S,e),e},i=function(t){return h(t,S)?t[S]:{}},o=function(t){return h(t,S)}}t.exports={set:r,get:i,has:o,enforce:_,getterFor:y}},614:function(t){t.exports=function(t){return"function"==typeof t}},4705:function(t,e,n){var r=n(7293),i=n(614),o=/#|\.prototype\./,s=function(t,e){var n=u[a(t)];return n==c||n!=l&&(i(e)?r(e):!!e)},a=s.normalize=function(t){return String(t).replace(o,".").toLowerCase()},u=s.data={},l=s.NATIVE="N",c=s.POLYFILL="P";t.exports=s},111:function(t,e,n){var r=n(614);t.exports=function(t){return"object"==typeof t?null!==t:r(t)}},1913:function(t){t.exports=!1},2190:function(t,e,n){var r=n(7854),i=n(5005),o=n(614),s=n(7976),a=n(3307),u=r.Object;t.exports=a?function(t){return"symbol"==typeof t}:function(t){var e=i("Symbol");return o(e)&&s(e.prototype,u(t))}},6244:function(t,e,n){var r=n(7466);t.exports=function(t){return r(t.length)}},133:function(t,e,n){var r=n(7392),i=n(7293);t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},8536:function(t,e,n){var r=n(7854),i=n(614),o=n(2788),s=r.WeakMap;t.exports=i(s)&&/native code/.test(o(s))},6277:function(t,e,n){var r=n(1340);t.exports=function(t,e){return void 0===t?arguments.length<2?"":e:r(t)}},3070:function(t,e,n){var r=n(7854),i=n(9781),o=n(4664),s=n(3353),a=n(9670),u=n(4948),l=r.TypeError,c=Object.defineProperty,h=Object.getOwnPropertyDescriptor,f="enumerable",d="configurable",p="writable";e.f=i?s?function(t,e,n){if(a(t),e=u(e),a(n),"function"===typeof t&&"prototype"===e&&"value"in n&&p in n&&!n[p]){var r=h(t,e);r&&r[p]&&(t[e]=n.value,n={configurable:d in n?n[d]:r[d],enumerable:f in n?n[f]:r[f],writable:!1})}return c(t,e,n)}:c:function(t,e,n){if(a(t),e=u(e),a(n),o)try{return c(t,e,n)}catch(r){}if("get"in n||"set"in n)throw l("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},1236:function(t,e,n){var r=n(9781),i=n(6916),o=n(5296),s=n(9114),a=n(5656),u=n(4948),l=n(2597),c=n(4664),h=Object.getOwnPropertyDescriptor;e.f=r?h:function(t,e){if(t=a(t),e=u(e),c)try{return h(t,e)}catch(n){}if(l(t,e))return s(!i(o.f,t,e),t[e])}},8006:function(t,e,n){var r=n(6324),i=n(748),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},5181:function(t,e){e.f=Object.getOwnPropertySymbols},7976:function(t,e,n){var r=n(1702);t.exports=r({}.isPrototypeOf)},6324:function(t,e,n){var r=n(1702),i=n(2597),o=n(5656),s=n(1318).indexOf,a=n(3501),u=r([].push);t.exports=function(t,e){var n,r=o(t),l=0,c=[];for(n in r)!i(a,n)&&i(r,n)&&u(c,n);while(e.length>l)i(r,n=e[l++])&&(~s(c,n)||u(c,n));return c}},5296:function(t,e){"use strict";var n={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,i=r&&!n.call({1:2},1);e.f=i?function(t){var e=r(this,t);return!!e&&e.enumerable}:n},7674:function(t,e,n){var r=n(1702),i=n(9670),o=n(6077);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{t=r(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set),t(n,[]),e=n instanceof Array}catch(s){}return function(n,r){return i(n),o(r),e?t(n,r):n.__proto__=r,n}}():void 0)},2140:function(t,e,n){var r=n(7854),i=n(6916),o=n(614),s=n(111),a=r.TypeError;t.exports=function(t,e){var n,r;if("string"===e&&o(n=t.toString)&&!s(r=i(n,t)))return r;if(o(n=t.valueOf)&&!s(r=i(n,t)))return r;if("string"!==e&&o(n=t.toString)&&!s(r=i(n,t)))return r;throw a("Can't convert object to primitive value")}},3887:function(t,e,n){var r=n(5005),i=n(1702),o=n(8006),s=n(5181),a=n(9670),u=i([].concat);t.exports=r("Reflect","ownKeys")||function(t){var e=o.f(a(t)),n=s.f;return n?u(e,n(t)):e}},1320:function(t,e,n){var r=n(7854),i=n(614),o=n(2597),s=n(8880),a=n(3505),u=n(2788),l=n(9909),c=n(6530).CONFIGURABLE,h=l.get,f=l.enforce,d=String(String).split("String");(t.exports=function(t,e,n,u){var l,h=!!u&&!!u.unsafe,p=!!u&&!!u.enumerable,m=!!u&&!!u.noTargetGet,v=u&&void 0!==u.name?u.name:e;i(n)&&("Symbol("===String(v).slice(0,7)&&(v="["+String(v).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!o(n,"name")||c&&n.name!==v)&&s(n,"name",v),l=f(n),l.source||(l.source=d.join("string"==typeof v?v:""))),t!==r?(h?!m&&t[e]&&(p=!0):delete t[e],p?t[e]=n:s(t,e,n)):p?t[e]=n:a(e,n)})(Function.prototype,"toString",(function(){return i(this)&&h(this).source||u(this)}))},4488:function(t,e,n){var r=n(7854),i=r.TypeError;t.exports=function(t){if(void 0==t)throw i("Can't call method on "+t);return t}},3505:function(t,e,n){var r=n(7854),i=Object.defineProperty;t.exports=function(t,e){try{i(r,t,{value:e,configurable:!0,writable:!0})}catch(n){r[t]=e}return e}},6200:function(t,e,n){var r=n(2309),i=n(9711),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},5465:function(t,e,n){var r=n(7854),i=n(3505),o="__core-js_shared__",s=r[o]||i(o,{});t.exports=s},2309:function(t,e,n){var r=n(1913),i=n(5465);(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.20.2",mode:r?"pure":"global",copyright:"© 2022 Denis Pushkarev (zloirock.ru)"})},1400:function(t,e,n){var r=n(9303),i=Math.max,o=Math.min;t.exports=function(t,e){var n=r(t);return n<0?i(n+e,0):o(n,e)}},5656:function(t,e,n){var r=n(8361),i=n(4488);t.exports=function(t){return r(i(t))}},9303:function(t){var e=Math.ceil,n=Math.floor;t.exports=function(t){var r=+t;return r!==r||0===r?0:(r>0?n:e)(r)}},7466:function(t,e,n){var r=n(9303),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},7908:function(t,e,n){var r=n(7854),i=n(4488),o=r.Object;t.exports=function(t){return o(i(t))}},7593:function(t,e,n){var r=n(7854),i=n(6916),o=n(111),s=n(2190),a=n(8173),u=n(2140),l=n(5112),c=r.TypeError,h=l("toPrimitive");t.exports=function(t,e){if(!o(t)||s(t))return t;var n,r=a(t,h);if(r){if(void 0===e&&(e="default"),n=i(r,t,e),!o(n)||s(n))return n;throw c("Can't convert object to primitive value")}return void 0===e&&(e="number"),u(t,e)}},4948:function(t,e,n){var r=n(7593),i=n(2190);t.exports=function(t){var e=r(t,"string");return i(e)?e:e+""}},1694:function(t,e,n){var r=n(5112),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},1340:function(t,e,n){var r=n(7854),i=n(648),o=r.String;t.exports=function(t){if("Symbol"===i(t))throw TypeError("Cannot convert a Symbol value to a string");return o(t)}},6330:function(t,e,n){var r=n(7854),i=r.String;t.exports=function(t){try{return i(t)}catch(e){return"Object"}}},9711:function(t,e,n){var r=n(1702),i=0,o=Math.random(),s=r(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+s(++i+o,36)}},3307:function(t,e,n){var r=n(133);t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},3353:function(t,e,n){var r=n(9781),i=n(7293);t.exports=r&&i((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},5112:function(t,e,n){var r=n(7854),i=n(2309),o=n(2597),s=n(9711),a=n(133),u=n(3307),l=i("wks"),c=r.Symbol,h=c&&c["for"],f=u?c:c&&c.withoutSetter||s;t.exports=function(t){if(!o(l,t)||!a&&"string"!=typeof l[t]){var e="Symbol."+t;a&&o(c,t)?l[t]=c[t]:l[t]=u&&h?h(e):f(e)}return l[t]}},9191:function(t,e,n){"use strict";var r=n(5005),i=n(2597),o=n(8880),s=n(7976),a=n(7674),u=n(9920),l=n(9587),c=n(6277),h=n(8340),f=n(7741),d=n(2914),p=n(1913);t.exports=function(t,e,n,m){var v=m?2:1,g=t.split("."),_=g[g.length-1],y=r.apply(null,g);if(y){var b=y.prototype;if(!p&&i(b,"cause")&&delete b.cause,!n)return y;var E=r("Error"),T=e((function(t,e){var n=c(m?e:t,void 0),r=m?new y(t):new y;return void 0!==n&&o(r,"message",n),d&&o(r,"stack",f(r.stack,2)),this&&s(b,this)&&l(r,this,T),arguments.length>v&&h(r,arguments[v]),r}));if(T.prototype=b,"Error"!==_&&(a?a(T,E):u(T,E,{name:!0})),u(T,y),!p)try{b.name!==_&&o(b,"name",_),b.constructor=T}catch(x){}return T}}},1703:function(t,e,n){var r=n(2109),i=n(7854),o=n(2104),s=n(9191),a="WebAssembly",u=i[a],l=7!==Error("e",{cause:7}).cause,c=function(t,e){var n={};n[t]=s(t,e,l),r({global:!0,forced:l},n)},h=function(t,e){if(u&&u[t]){var n={};n[t]=s(a+"."+t,e,l),r({target:a,stat:!0,forced:l},n)}};c("Error",(function(t){return function(e){return o(t,this,arguments)}})),c("EvalError",(function(t){return function(e){return o(t,this,arguments)}})),c("RangeError",(function(t){return function(e){return o(t,this,arguments)}})),c("ReferenceError",(function(t){return function(e){return o(t,this,arguments)}})),c("SyntaxError",(function(t){return function(e){return o(t,this,arguments)}})),c("TypeError",(function(t){return function(e){return o(t,this,arguments)}})),c("URIError",(function(t){return function(e){return o(t,this,arguments)}})),h("CompileError",(function(t){return function(e){return o(t,this,arguments)}})),h("LinkError",(function(t){return function(e){return o(t,this,arguments)}})),h("RuntimeError",(function(t){return function(e){return o(t,this,arguments)}}))},2801:function(t,e,n){"use strict";var r=n(2109),i=n(5005),o=n(9114),s=n(3070).f,a=n(2597),u=n(5787),l=n(9587),c=n(6277),h=n(3678),f=n(7741),d=n(1913),p="DOMException",m=i("Error"),v=i(p),g=function(){u(this,_);var t=arguments.length,e=c(t<1?void 0:arguments[0]),n=c(t<2?void 0:arguments[1],"Error"),r=new v(e,n),i=m(e);return i.name=p,s(r,"stack",o(1,f(i.stack,1))),l(r,this,g),r},_=g.prototype=v.prototype,y="stack"in m(p),b="stack"in new v(1,2),E=y&&!b;r({global:!0,forced:d||E},{DOMException:E?g:v});var T=i(p),x=T.prototype;if(x.constructor!==T)for(var S in d||s(x,"constructor",o(1,T)),h)if(a(h,S)){var R=h[S],A=R.s;a(T,A)||s(T,A,o(6,R.c))}},9187:function(t){"use strict";function e(t,e,r){r=r||2;var o,s,a,u,c,h,f,d=e&&e.length,p=d?e[0]*r:t.length,m=n(t,0,p,r,!0),v=[];if(!m||m.next===m.prev)return v;if(d&&(m=l(t,e,m,r)),t.length>80*r){o=a=t[0],s=u=t[1];for(var g=r;g<p;g+=r)c=t[g],h=t[g+1],c<o&&(o=c),h<s&&(s=h),c>a&&(a=c),h>u&&(u=h);f=Math.max(a-o,u-s),f=0!==f?1/f:0}return i(m,v,r,o,s,f),v}function n(t,e,n,r,i){var o,s;if(i===N(t,e,n,r)>0)for(o=e;o<n;o+=r)s=w(o,t[o],t[o+1],s);else for(o=n-r;o>=e;o-=r)s=w(o,t[o],t[o+1],s);return s&&E(s,s.next)&&(C(s),s=s.next),s}function r(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!E(r,r.next)&&0!==b(r.prev,r,r.next))r=r.next;else{if(C(r),r=e=r.prev,r===r.next)break;n=!0}}while(n||r!==e);return e}function i(t,e,n,l,c,h,f){if(t){!f&&h&&p(t,l,c,h);var d,m,v=t;while(t.prev!==t.next)if(d=t.prev,m=t.next,h?s(t,l,c,h):o(t))e.push(d.i/n),e.push(t.i/n),e.push(m.i/n),C(t),t=m.next,v=m.next;else if(t=m,t===v){f?1===f?(t=a(r(t),e,n),i(t,e,n,l,c,h,2)):2===f&&u(t,e,n,l,c,h):i(r(t),e,n,l,c,h,1);break}}}function o(t){var e=t.prev,n=t,r=t.next;if(b(e,n,r)>=0)return!1;var i=t.next.next;while(i!==t.prev){if(_(e.x,e.y,n.x,n.y,r.x,r.y,i.x,i.y)&&b(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function s(t,e,n,r){var i=t.prev,o=t,s=t.next;if(b(i,o,s)>=0)return!1;var a=i.x<o.x?i.x<s.x?i.x:s.x:o.x<s.x?o.x:s.x,u=i.y<o.y?i.y<s.y?i.y:s.y:o.y<s.y?o.y:s.y,l=i.x>o.x?i.x>s.x?i.x:s.x:o.x>s.x?o.x:s.x,c=i.y>o.y?i.y>s.y?i.y:s.y:o.y>s.y?o.y:s.y,h=v(a,u,e,n,r),f=v(l,c,e,n,r),d=t.prevZ,p=t.nextZ;while(d&&d.z>=h&&p&&p.z<=f){if(d!==t.prev&&d!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,d.x,d.y)&&b(d.prev,d,d.next)>=0)return!1;if(d=d.prevZ,p!==t.prev&&p!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&b(p.prev,p,p.next)>=0)return!1;p=p.nextZ}while(d&&d.z>=h){if(d!==t.prev&&d!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,d.x,d.y)&&b(d.prev,d,d.next)>=0)return!1;d=d.prevZ}while(p&&p.z<=f){if(p!==t.prev&&p!==t.next&&_(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&b(p.prev,p,p.next)>=0)return!1;p=p.nextZ}return!0}function a(t,e,n){var i=t;do{var o=i.prev,s=i.next.next;!E(o,s)&&T(o,i,i.next,s)&&A(o,s)&&A(s,o)&&(e.push(o.i/n),e.push(i.i/n),e.push(s.i/n),C(i),C(i.next),i=t=s),i=i.next}while(i!==t);return r(i)}function u(t,e,n,o,s,a){var u=t;do{var l=u.next.next;while(l!==u.prev){if(u.i!==l.i&&y(u,l)){var c=I(u,l);return u=r(u,u.next),c=r(c,c.next),i(u,e,n,o,s,a),void i(c,e,n,o,s,a)}l=l.next}u=u.next}while(u!==t)}function l(t,e,i,o){var s,a,u,l,f,d=[];for(s=0,a=e.length;s<a;s++)u=e[s]*o,l=s<a-1?e[s+1]*o:t.length,f=n(t,u,l,o,!1),f===f.next&&(f.steiner=!0),d.push(g(f));for(d.sort(c),s=0;s<d.length;s++)i=h(d[s],i),i=r(i,i.next);return i}function c(t,e){return t.x-e.x}function h(t,e){var n=f(t,e);if(!n)return e;var i=I(n,t),o=r(n,n.next);return r(i,i.next),e===n?o:e}function f(t,e){var n,r=e,i=t.x,o=t.y,s=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var a=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(a<=i&&a>s){if(s=a,a===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==e);if(!n)return null;if(i===s)return n;var u,l=n,c=n.x,h=n.y,f=1/0;r=n;do{i>=r.x&&r.x>=c&&i!==r.x&&_(o<h?i:s,o,c,h,o<h?s:i,o,r.x,r.y)&&(u=Math.abs(o-r.y)/(i-r.x),A(r,t)&&(u<f||u===f&&(r.x>n.x||r.x===n.x&&d(n,r)))&&(n=r,f=u)),r=r.next}while(r!==l);return n}function d(t,e){return b(t.prev,t,e.prev)<0&&b(e.next,t,t.next)<0}function p(t,e,n,r){var i=t;do{null===i.z&&(i.z=v(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,m(i)}function m(t){var e,n,r,i,o,s,a,u,l=1;do{n=t,t=null,o=null,s=0;while(n){for(s++,r=n,a=0,e=0;e<l;e++)if(a++,r=r.nextZ,!r)break;u=l;while(a>0||u>0&&r)0!==a&&(0===u||!r||n.z<=r.z)?(i=n,n=n.nextZ,a--):(i=r,r=r.nextZ,u--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;n=r}o.nextZ=null,l*=2}while(s>1);return t}function v(t,e,n,r,i){return t=32767*(t-n)*i,e=32767*(e-r)*i,t=16711935&(t|t<<8),t=252645135&(t|t<<4),t=858993459&(t|t<<2),t=1431655765&(t|t<<1),e=16711935&(e|e<<8),e=252645135&(e|e<<4),e=858993459&(e|e<<2),e=1431655765&(e|e<<1),t|e<<1}function g(t){var e=t,n=t;do{(e.x<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function _(t,e,n,r,i,o,s,a){return(i-s)*(e-a)-(t-s)*(o-a)>=0&&(t-s)*(r-a)-(n-s)*(e-a)>=0&&(n-s)*(o-a)-(i-s)*(r-a)>=0}function y(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!R(t,e)&&(A(t,e)&&A(e,t)&&O(t,e)&&(b(t.prev,t,e.prev)||b(t,e.prev,e))||E(t,e)&&b(t.prev,t,t.next)>0&&b(e.prev,e,e.next)>0)}function b(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function E(t,e){return t.x===e.x&&t.y===e.y}function T(t,e,n,r){var i=S(b(t,e,n)),o=S(b(t,e,r)),s=S(b(n,r,t)),a=S(b(n,r,e));return i!==o&&s!==a||(!(0!==i||!x(t,n,e))||(!(0!==o||!x(t,r,e))||(!(0!==s||!x(n,t,r))||!(0!==a||!x(n,e,r)))))}function x(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function S(t){return t>0?1:t<0?-1:0}function R(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&T(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}function A(t,e){return b(t.prev,t,t.next)<0?b(t,e,t.next)>=0&&b(t,t.prev,e)>=0:b(t,e,t.prev)<0||b(t,t.next,e)<0}function O(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!==n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}function I(t,e){var n=new P(t.i,t.x,t.y),r=new P(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function w(t,e,n,r){var i=new P(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function C(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function P(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function N(t,e,n,r){for(var i=0,o=e,s=n-r;o<n;o+=r)i+=(t[s]-t[o])*(t[o+1]+t[s+1]),s=o;return i}t.exports=e,t.exports["default"]=e,e.deviation=function(t,e,n,r){var i=e&&e.length,o=i?e[0]*n:t.length,s=Math.abs(N(t,0,o,n));if(i)for(var a=0,u=e.length;a<u;a++){var l=e[a]*n,c=a<u-1?e[a+1]*n:t.length;s-=Math.abs(N(t,l,c,n))}var h=0;for(a=0;a<r.length;a+=3){var f=r[a]*n,d=r[a+1]*n,p=r[a+2]*n;h+=Math.abs((t[f]-t[p])*(t[d+1]-t[f+1])-(t[f]-t[d])*(t[p+1]-t[f+1]))}return 0===s&&0===h?0:Math.abs((h-s)/s)},e.flatten=function(t){for(var e=t[0][0].length,n={vertices:[],holes:[],dimensions:e},r=0,i=0;i<t.length;i++){for(var o=0;o<t[i].length;o++)for(var s=0;s<e;s++)n.vertices.push(t[i][o][s]);i>0&&(r+=t[i-1].length,n.holes.push(r))}return n}},6961:function(t,e,n){var r,i=function(){var t=String.fromCharCode,e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",r={};function i(t,e){if(!r[t]){r[t]={};for(var n=0;n<t.length;n++)r[t][t.charAt(n)]=n}return r[t][e]}var o={compressToBase64:function(t){if(null==t)return"";var n=o._compress(t,6,(function(t){return e.charAt(t)}));switch(n.length%4){default:case 0:return n;case 1:return n+"===";case 2:return n+"==";case 3:return n+"="}},decompressFromBase64:function(t){return null==t?"":""==t?null:o._decompress(t.length,32,(function(n){return i(e,t.charAt(n))}))},compressToUTF16:function(e){return null==e?"":o._compress(e,15,(function(e){return t(e+32)}))+" "},decompressFromUTF16:function(t){return null==t?"":""==t?null:o._decompress(t.length,16384,(function(e){return t.charCodeAt(e)-32}))},compressToUint8Array:function(t){for(var e=o.compress(t),n=new Uint8Array(2*e.length),r=0,i=e.length;r<i;r++){var s=e.charCodeAt(r);n[2*r]=s>>>8,n[2*r+1]=s%256}return n},decompressFromUint8Array:function(e){if(null===e||void 0===e)return o.decompress(e);for(var n=new Array(e.length/2),r=0,i=n.length;r<i;r++)n[r]=256*e[2*r]+e[2*r+1];var s=[];return n.forEach((function(e){s.push(t(e))})),o.decompress(s.join(""))},compressToEncodedURIComponent:function(t){return null==t?"":o._compress(t,6,(function(t){return n.charAt(t)}))},decompressFromEncodedURIComponent:function(t){return null==t?"":""==t?null:(t=t.replace(/ /g,"+"),o._decompress(t.length,32,(function(e){return i(n,t.charAt(e))})))},compress:function(e){return o._compress(e,16,(function(e){return t(e)}))},_compress:function(t,e,n){if(null==t)return"";var r,i,o,s={},a={},u="",l="",c="",h=2,f=3,d=2,p=[],m=0,v=0;for(o=0;o<t.length;o+=1)if(u=t.charAt(o),Object.prototype.hasOwnProperty.call(s,u)||(s[u]=f++,a[u]=!0),l=c+u,Object.prototype.hasOwnProperty.call(s,l))c=l;else{if(Object.prototype.hasOwnProperty.call(a,c)){if(c.charCodeAt(0)<256){for(r=0;r<d;r++)m<<=1,v==e-1?(v=0,p.push(n(m)),m=0):v++;for(i=c.charCodeAt(0),r=0;r<8;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1}else{for(i=1,r=0;r<d;r++)m=m<<1|i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i=0;for(i=c.charCodeAt(0),r=0;r<16;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1}h--,0==h&&(h=Math.pow(2,d),d++),delete a[c]}else for(i=s[c],r=0;r<d;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1;h--,0==h&&(h=Math.pow(2,d),d++),s[l]=f++,c=String(u)}if(""!==c){if(Object.prototype.hasOwnProperty.call(a,c)){if(c.charCodeAt(0)<256){for(r=0;r<d;r++)m<<=1,v==e-1?(v=0,p.push(n(m)),m=0):v++;for(i=c.charCodeAt(0),r=0;r<8;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1}else{for(i=1,r=0;r<d;r++)m=m<<1|i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i=0;for(i=c.charCodeAt(0),r=0;r<16;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1}h--,0==h&&(h=Math.pow(2,d),d++),delete a[c]}else for(i=s[c],r=0;r<d;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1;h--,0==h&&(h=Math.pow(2,d),d++)}for(i=2,r=0;r<d;r++)m=m<<1|1&i,v==e-1?(v=0,p.push(n(m)),m=0):v++,i>>=1;while(1){if(m<<=1,v==e-1){p.push(n(m));break}v++}return p.join("")},decompress:function(t){return null==t?"":""==t?null:o._decompress(t.length,32768,(function(e){return t.charCodeAt(e)}))},_decompress:function(e,n,r){var i,o,s,a,u,l,c,h=[],f=4,d=4,p=3,m="",v=[],g={val:r(0),position:n,index:1};for(i=0;i<3;i+=1)h[i]=i;s=0,u=Math.pow(2,2),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;switch(s){case 0:s=0,u=Math.pow(2,8),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;c=t(s);break;case 1:s=0,u=Math.pow(2,16),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;c=t(s);break;case 2:return""}h[3]=c,o=c,v.push(c);while(1){if(g.index>e)return"";s=0,u=Math.pow(2,p),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;switch(c=s){case 0:s=0,u=Math.pow(2,8),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;h[d++]=t(s),c=d-1,f--;break;case 1:s=0,u=Math.pow(2,16),l=1;while(l!=u)a=g.val&g.position,g.position>>=1,0==g.position&&(g.position=n,g.val=r(g.index++)),s|=(a>0?1:0)*l,l<<=1;h[d++]=t(s),c=d-1,f--;break;case 2:return v.join("")}if(0==f&&(f=Math.pow(2,p),p++),h[c])m=h[c];else{if(c!==d)return null;m=o+o.charAt(0)}v.push(m),h[d++]=o+m.charAt(0),f--,o=m,0==f&&(f=Math.pow(2,p),p++)}}};return o}();r=function(){return i}.call(e,n,e,t),void 0===r||(t.exports=r)},343:function(){},7418:function(t){"use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/var e=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function i(t){if(null===t||void 0===t)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}function o(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de","5"===Object.getOwnPropertyNames(t)[0])return!1;for(var e={},n=0;n<10;n++)e["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(e).map((function(t){return e[t]}));if("0123456789"!==r.join(""))return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach((function(t){i[t]=t})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},i)).join("")}catch(o){return!1}}t.exports=o()?Object.assign:function(t,o){for(var s,a,u=i(t),l=1;l<arguments.length;l++){for(var c in s=Object(arguments[l]),s)n.call(s,c)&&(u[c]=s[c]);if(e){a=e(s);for(var h=0;h<a.length;h++)r.call(s,a[h])&&(u[a[h]]=s[a[h]])}}return u}},6591:function(t,e,n){"use strict";function r(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){return e.reject(n)}))}))}n.d(e,{MxU:function(){return Q}});var i=r;function o(t){var e=this;return new e((function(e,n){if(!t||"undefined"===typeof t.length)return n(new TypeError(typeof t+" "+t+" is not iterable(cannot read property Symbol(Symbol.iterator))"));var r=Array.prototype.slice.call(t);if(0===r.length)return e([]);var i=r.length;function o(t,n){if(n&&("object"===typeof n||"function"===typeof n)){var s=n.then;if("function"===typeof s)return void s.call(n,(function(e){o(t,e)}),(function(n){r[t]={status:"rejected",reason:n},0===--i&&e(r)}))}r[t]={status:"fulfilled",value:n},0===--i&&e(r)}for(var s=0;s<r.length;s++)o(s,r[s])}))}var s=o,a=setTimeout;function u(t){return Boolean(t&&"undefined"!==typeof t.length)}function l(){}function c(t,e){return function(){t.apply(e,arguments)}}function h(t){if(!(this instanceof h))throw new TypeError("Promises must be constructed via new");if("function"!==typeof t)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],g(t,this)}function f(t,e){while(3===t._state)t=t._value;0!==t._state?(t._handled=!0,h._immediateFn((function(){var n=1===t._state?e.onFulfilled:e.onRejected;if(null!==n){var r;try{r=n(t._value)}catch(i){return void p(e.promise,i)}d(e.promise,r)}else(1===t._state?d:p)(e.promise,t._value)}))):t._deferreds.push(e)}function d(t,e){try{if(e===t)throw new TypeError("A promise cannot be resolved with itself.");if(e&&("object"===typeof e||"function"===typeof e)){var n=e.then;if(e instanceof h)return t._state=3,t._value=e,void m(t);if("function"===typeof n)return void g(c(n,e),t)}t._state=1,t._value=e,m(t)}catch(r){p(t,r)}}function p(t,e){t._state=2,t._value=e,m(t)}function m(t){2===t._state&&0===t._deferreds.length&&h._immediateFn((function(){t._handled||h._unhandledRejectionFn(t._value)}));for(var e=0,n=t._deferreds.length;e<n;e++)f(t,t._deferreds[e]);t._deferreds=null}function v(t,e,n){this.onFulfilled="function"===typeof t?t:null,this.onRejected="function"===typeof e?e:null,this.promise=n}function g(t,e){var n=!1;try{t((function(t){n||(n=!0,d(e,t))}),(function(t){n||(n=!0,p(e,t))}))}catch(r){if(n)return;n=!0,p(e,r)}}h.prototype["catch"]=function(t){return this.then(null,t)},h.prototype.then=function(t,e){var n=new this.constructor(l);return f(this,new v(t,e,n)),n},h.prototype["finally"]=i,h.all=function(t){return new h((function(e,n){if(!u(t))return n(new TypeError("Promise.all accepts an array"));var r=Array.prototype.slice.call(t);if(0===r.length)return e([]);var i=r.length;function o(t,s){try{if(s&&("object"===typeof s||"function"===typeof s)){var a=s.then;if("function"===typeof a)return void a.call(s,(function(e){o(t,e)}),n)}r[t]=s,0===--i&&e(r)}catch(u){n(u)}}for(var s=0;s<r.length;s++)o(s,r[s])}))},h.allSettled=s,h.resolve=function(t){return t&&"object"===typeof t&&t.constructor===h?t:new h((function(e){e(t)}))},h.reject=function(t){return new h((function(e,n){n(t)}))},h.race=function(t){return new h((function(e,n){if(!u(t))return n(new TypeError("Promise.race accepts an array"));for(var r=0,i=t.length;r<i;r++)h.resolve(t[r]).then(e,n)}))},h._immediateFn="function"===typeof setImmediate&&function(t){setImmediate(t)}||function(t){a(t,0)},h._unhandledRejectionFn=function(t){"undefined"!==typeof console&&console&&console.warn("Possible Unhandled Promise Rejection:",t)};var _=h,y=n(7418),b=n.n(y); -/*! - * @pixi/polyfill - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/polyfill is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -"undefined"===typeof globalThis&&("undefined"!==typeof self?self.globalThis=self:"undefined"!==typeof n.g&&(n.g.globalThis=n.g)),globalThis.Promise||(globalThis.Promise=_),Object.assign||(Object.assign=b());var E=16;if(Date.now&&Date.prototype.getTime||(Date.now=function(){return(new Date).getTime()}),!globalThis.performance||!globalThis.performance.now){var T=Date.now();globalThis.performance||(globalThis.performance={}),globalThis.performance.now=function(){return Date.now()-T}}for(var x=Date.now(),S=["ms","moz","webkit","o"],R=0;R<S.length&&!globalThis.requestAnimationFrame;++R){var A=S[R];globalThis.requestAnimationFrame=globalThis[A+"RequestAnimationFrame"],globalThis.cancelAnimationFrame=globalThis[A+"CancelAnimationFrame"]||globalThis[A+"CancelRequestAnimationFrame"]}globalThis.requestAnimationFrame||(globalThis.requestAnimationFrame=function(t){if("function"!==typeof t)throw new TypeError(t+"is not a function");var e=Date.now(),n=E+x-e;return n<0&&(n=0),x=e,globalThis.self.setTimeout((function(){x=Date.now(),t(performance.now())}),n)}),globalThis.cancelAnimationFrame||(globalThis.cancelAnimationFrame=function(t){return clearTimeout(t)}),Math.sign||(Math.sign=function(t){return t=Number(t),0===t||isNaN(t)?t:t>0?1:-1}),Number.isInteger||(Number.isInteger=function(t){return"number"===typeof t&&isFinite(t)&&Math.floor(t)===t}),globalThis.ArrayBuffer||(globalThis.ArrayBuffer=Array),globalThis.Float32Array||(globalThis.Float32Array=Array),globalThis.Uint32Array||(globalThis.Uint32Array=Array),globalThis.Uint16Array||(globalThis.Uint16Array=Array),globalThis.Uint8Array||(globalThis.Uint8Array=Array),globalThis.Int32Array||(globalThis.Int32Array=Array);var O=n(8942),I=n(1585),w={accessible:!1,accessibleTitle:null,accessibleHint:null,tabIndex:0,_accessibleActive:!1,_accessibleDiv:null,accessibleType:"button",accessiblePointerEvents:"auto",accessibleChildren:!0,renderId:-1};I.s$.mixin(w);var C=9,P=100,N=0,M=0,D=2,L=1,B=-1e3,F=-1e3,U=2,G=function(){function t(t){this.debug=!1,this._isActive=!1,this._isMobileAccessibility=!1,this.pool=[],this.renderId=0,this.children=[],this.androidUpdateCount=0,this.androidUpdateFrequency=500,this._hookDiv=null,(O.tq.tablet||O.tq.phone)&&this.createTouchHook();var e=document.createElement("div");e.style.width=P+"px",e.style.height=P+"px",e.style.position="absolute",e.style.top=N+"px",e.style.left=M+"px",e.style.zIndex=D.toString(),this.div=e,this.renderer=t,this._onKeyDown=this._onKeyDown.bind(this),this._onMouseMove=this._onMouseMove.bind(this),globalThis.addEventListener("keydown",this._onKeyDown,!1)}return Object.defineProperty(t.prototype,"isActive",{get:function(){return this._isActive},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMobileAccessibility",{get:function(){return this._isMobileAccessibility},enumerable:!1,configurable:!0}),t.prototype.createTouchHook=function(){var t=this,e=document.createElement("button");e.style.width=L+"px",e.style.height=L+"px",e.style.position="absolute",e.style.top=B+"px",e.style.left=F+"px",e.style.zIndex=U.toString(),e.style.backgroundColor="#FF0000",e.title="select to enable accessibility for this content",e.addEventListener("focus",(function(){t._isMobileAccessibility=!0,t.activate(),t.destroyTouchHook()})),document.body.appendChild(e),this._hookDiv=e},t.prototype.destroyTouchHook=function(){this._hookDiv&&(document.body.removeChild(this._hookDiv),this._hookDiv=null)},t.prototype.activate=function(){var t;this._isActive||(this._isActive=!0,globalThis.document.addEventListener("mousemove",this._onMouseMove,!0),globalThis.removeEventListener("keydown",this._onKeyDown,!1),this.renderer.on("postrender",this.update,this),null===(t=this.renderer.view.parentNode)||void 0===t||t.appendChild(this.div))},t.prototype.deactivate=function(){var t;this._isActive&&!this._isMobileAccessibility&&(this._isActive=!1,globalThis.document.removeEventListener("mousemove",this._onMouseMove,!0),globalThis.addEventListener("keydown",this._onKeyDown,!1),this.renderer.off("postrender",this.update),null===(t=this.div.parentNode)||void 0===t||t.removeChild(this.div))},t.prototype.updateAccessibleObjects=function(t){if(t.visible&&t.accessibleChildren){t.accessible&&t.interactive&&(t._accessibleActive||this.addChild(t),t.renderId=this.renderId);var e=t.children;if(e)for(var n=0;n<e.length;n++)this.updateAccessibleObjects(e[n])}},t.prototype.update=function(){var t=performance.now();if(!(O.tq.android.device&&t<this.androidUpdateCount)&&(this.androidUpdateCount=t+this.androidUpdateFrequency,this.renderer.renderingToScreen)){this.renderer._lastObjectRendered&&this.updateAccessibleObjects(this.renderer._lastObjectRendered);var e=this.renderer.view.getBoundingClientRect(),n=e.left,r=e.top,i=e.width,o=e.height,s=this.renderer,a=s.width,u=s.height,l=s.resolution,c=i/a*l,h=o/u*l,f=this.div;f.style.left=n+"px",f.style.top=r+"px",f.style.width=a+"px",f.style.height=u+"px";for(var d=0;d<this.children.length;d++){var p=this.children[d];if(p.renderId!==this.renderId)p._accessibleActive=!1,(0,O.Er)(this.children,d,1),this.div.removeChild(p._accessibleDiv),this.pool.push(p._accessibleDiv),p._accessibleDiv=null,d--;else{f=p._accessibleDiv;var m=p.hitArea,v=p.worldTransform;p.hitArea?(f.style.left=(v.tx+m.x*v.a)*c+"px",f.style.top=(v.ty+m.y*v.d)*h+"px",f.style.width=m.width*v.a*c+"px",f.style.height=m.height*v.d*h+"px"):(m=p.getBounds(),this.capHitArea(m),f.style.left=m.x*c+"px",f.style.top=m.y*h+"px",f.style.width=m.width*c+"px",f.style.height=m.height*h+"px",f.title!==p.accessibleTitle&&null!==p.accessibleTitle&&(f.title=p.accessibleTitle),f.getAttribute("aria-label")!==p.accessibleHint&&null!==p.accessibleHint&&f.setAttribute("aria-label",p.accessibleHint)),p.accessibleTitle===f.title&&p.tabIndex===f.tabIndex||(f.title=p.accessibleTitle,f.tabIndex=p.tabIndex,this.debug&&this.updateDebugHTML(f))}}this.renderId++}},t.prototype.updateDebugHTML=function(t){t.innerHTML="type: "+t.type+"</br> title : "+t.title+"</br> tabIndex: "+t.tabIndex},t.prototype.capHitArea=function(t){t.x<0&&(t.width+=t.x,t.x=0),t.y<0&&(t.height+=t.y,t.y=0);var e=this.renderer,n=e.width,r=e.height;t.x+t.width>n&&(t.width=n-t.x),t.y+t.height>r&&(t.height=r-t.y)},t.prototype.addChild=function(t){var e=this.pool.pop();e||(e=document.createElement("button"),e.style.width=P+"px",e.style.height=P+"px",e.style.backgroundColor=this.debug?"rgba(255,255,255,0.5)":"transparent",e.style.position="absolute",e.style.zIndex=D.toString(),e.style.borderStyle="none",navigator.userAgent.toLowerCase().indexOf("chrome")>-1?e.setAttribute("aria-live","off"):e.setAttribute("aria-live","polite"),navigator.userAgent.match(/rv:.*Gecko\//)?e.setAttribute("aria-relevant","additions"):e.setAttribute("aria-relevant","text"),e.addEventListener("click",this._onClick.bind(this)),e.addEventListener("focus",this._onFocus.bind(this)),e.addEventListener("focusout",this._onFocusOut.bind(this))),e.style.pointerEvents=t.accessiblePointerEvents,e.type=t.accessibleType,t.accessibleTitle&&null!==t.accessibleTitle?e.title=t.accessibleTitle:t.accessibleHint&&null!==t.accessibleHint||(e.title="displayObject "+t.tabIndex),t.accessibleHint&&null!==t.accessibleHint&&e.setAttribute("aria-label",t.accessibleHint),this.debug&&this.updateDebugHTML(e),t._accessibleActive=!0,t._accessibleDiv=e,e.displayObject=t,this.children.push(t),this.div.appendChild(t._accessibleDiv),t._accessibleDiv.tabIndex=t.tabIndex},t.prototype._onClick=function(t){var e=this.renderer.plugins.interaction,n=t.target.displayObject,r=e.eventData;e.dispatchEvent(n,"click",r),e.dispatchEvent(n,"pointertap",r),e.dispatchEvent(n,"tap",r)},t.prototype._onFocus=function(t){t.target.getAttribute("aria-live")||t.target.setAttribute("aria-live","assertive");var e=this.renderer.plugins.interaction,n=t.target.displayObject,r=e.eventData;e.dispatchEvent(n,"mouseover",r)},t.prototype._onFocusOut=function(t){t.target.getAttribute("aria-live")||t.target.setAttribute("aria-live","polite");var e=this.renderer.plugins.interaction,n=t.target.displayObject,r=e.eventData;e.dispatchEvent(n,"mouseout",r)},t.prototype._onKeyDown=function(t){t.keyCode===C&&this.activate()},t.prototype._onMouseMove=function(t){0===t.movementX&&0===t.movementY||this.deactivate()},t.prototype.destroy=function(){this.destroyTouchHook(),this.div=null,globalThis.document.removeEventListener("mousemove",this._onMouseMove,!0),globalThis.removeEventListener("keydown",this._onKeyDown),this.pool=null,this.children=null,this.renderer=null},t}(),k=n(9658),X=n(6679),H=function(){function t(){this.pressure=0,this.rotationAngle=0,this.twist=0,this.tangentialPressure=0,this.global=new k.E9,this.target=null,this.originalEvent=null,this.identifier=null,this.isPrimary=!1,this.button=0,this.buttons=0,this.width=0,this.height=0,this.tiltX=0,this.tiltY=0,this.pointerType=null,this.pressure=0,this.rotationAngle=0,this.twist=0,this.tangentialPressure=0}return Object.defineProperty(t.prototype,"pointerId",{get:function(){return this.identifier},enumerable:!1,configurable:!0}),t.prototype.getLocalPosition=function(t,e,n){return t.worldTransform.applyInverse(n||this.global,e)},t.prototype.copyEvent=function(t){"isPrimary"in t&&t.isPrimary&&(this.isPrimary=!0),this.button="button"in t&&t.button;var e="buttons"in t&&t.buttons;this.buttons=Number.isInteger(e)?e:"which"in t&&t.which,this.width="width"in t&&t.width,this.height="height"in t&&t.height,this.tiltX="tiltX"in t&&t.tiltX,this.tiltY="tiltY"in t&&t.tiltY,this.pointerType="pointerType"in t&&t.pointerType,this.pressure="pressure"in t&&t.pressure,this.rotationAngle="rotationAngle"in t&&t.rotationAngle,this.twist="twist"in t&&t.twist||0,this.tangentialPressure="tangentialPressure"in t&&t.tangentialPressure||0},t.prototype.reset=function(){this.isPrimary=!1},t}(),j=function(t,e){return j=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},j(t,e)};function V(t,e){function n(){this.constructor=t}j(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Y=function(){function t(){this.stopped=!1,this.stopsPropagatingAt=null,this.stopPropagationHint=!1,this.target=null,this.currentTarget=null,this.type=null,this.data=null}return t.prototype.stopPropagation=function(){this.stopped=!0,this.stopPropagationHint=!0,this.stopsPropagatingAt=this.currentTarget},t.prototype.reset=function(){this.stopped=!1,this.stopsPropagatingAt=null,this.stopPropagationHint=!1,this.currentTarget=null,this.target=null},t}(),W=function(){function t(e){this._pointerId=e,this._flags=t.FLAGS.NONE}return t.prototype._doSet=function(t,e){this._flags=e?this._flags|t:this._flags&~t},Object.defineProperty(t.prototype,"pointerId",{get:function(){return this._pointerId},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"flags",{get:function(){return this._flags},set:function(t){this._flags=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"none",{get:function(){return this._flags===t.FLAGS.NONE},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"over",{get:function(){return 0!==(this._flags&t.FLAGS.OVER)},set:function(e){this._doSet(t.FLAGS.OVER,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rightDown",{get:function(){return 0!==(this._flags&t.FLAGS.RIGHT_DOWN)},set:function(e){this._doSet(t.FLAGS.RIGHT_DOWN,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"leftDown",{get:function(){return 0!==(this._flags&t.FLAGS.LEFT_DOWN)},set:function(e){this._doSet(t.FLAGS.LEFT_DOWN,e)},enumerable:!1,configurable:!0}),t.FLAGS=Object.freeze({NONE:0,OVER:1,LEFT_DOWN:2,RIGHT_DOWN:4}),t}(),z=function(){function t(){this._tempPoint=new k.E9}return t.prototype.recursiveFindHit=function(t,e,n,r,i){if(!e||!e.visible)return!1;var o=t.data.global;i=e.interactive||i;var s=!1,a=i,u=!0;if(e.hitArea?(r&&(e.worldTransform.applyInverse(o,this._tempPoint),e.hitArea.contains(this._tempPoint.x,this._tempPoint.y)?s=!0:(r=!1,u=!1)),a=!1):e._mask&&r&&(e._mask.containsPoint&&e._mask.containsPoint(o)||(r=!1)),u&&e.interactiveChildren&&e.children)for(var l=e.children,c=l.length-1;c>=0;c--){var h=l[c],f=this.recursiveFindHit(t,h,n,r,a);if(f){if(!h.parent)continue;a=!1,f&&(t.target&&(r=!1),s=!0)}}return i&&(r&&!t.target&&!e.hitArea&&e.containsPoint&&e.containsPoint(o)&&(s=!0),e.interactive&&(s&&!t.target&&(t.target=e),n&&n(t,e,!!s))),s},t.prototype.findHit=function(t,e,n,r){this.recursiveFindHit(t,e,n,r,!1)},t}(),$={interactive:!1,interactiveChildren:!0,hitArea:null,get buttonMode(){return"pointer"===this.cursor},set buttonMode(t){t?this.cursor="pointer":"pointer"===this.cursor&&(this.cursor=null)},cursor:null,get trackedPointers(){return void 0===this._trackedPointers&&(this._trackedPointers={}),this._trackedPointers},_trackedPointers:void 0};I.s$.mixin($);var q=1,K={target:null,data:{global:null}},Z=function(t){function e(e,n){var r=t.call(this)||this;return n=n||{},r.renderer=e,r.autoPreventDefault=void 0===n.autoPreventDefault||n.autoPreventDefault,r.interactionFrequency=n.interactionFrequency||10,r.mouse=new H,r.mouse.identifier=q,r.mouse.global.set(-999999),r.activeInteractionData={},r.activeInteractionData[q]=r.mouse,r.interactionDataPool=[],r.eventData=new Y,r.interactionDOMElement=null,r.moveWhenInside=!1,r.eventsAdded=!1,r.tickerAdded=!1,r.mouseOverRenderer=!("PointerEvent"in globalThis),r.supportsTouchEvents="ontouchstart"in globalThis,r.supportsPointerEvents=!!globalThis.PointerEvent,r.onPointerUp=r.onPointerUp.bind(r),r.processPointerUp=r.processPointerUp.bind(r),r.onPointerCancel=r.onPointerCancel.bind(r),r.processPointerCancel=r.processPointerCancel.bind(r),r.onPointerDown=r.onPointerDown.bind(r),r.processPointerDown=r.processPointerDown.bind(r),r.onPointerMove=r.onPointerMove.bind(r),r.processPointerMove=r.processPointerMove.bind(r),r.onPointerOut=r.onPointerOut.bind(r),r.processPointerOverOut=r.processPointerOverOut.bind(r),r.onPointerOver=r.onPointerOver.bind(r),r.cursorStyles={default:"inherit",pointer:"pointer"},r.currentCursorMode=null,r.cursor=null,r.resolution=1,r.delayedEvents=[],r.search=new z,r._tempDisplayObject=new I.Ql,r._eventListenerOptions={capture:!0,passive:!1},r._useSystemTicker=void 0===n.useSystemTicker||n.useSystemTicker,r.setTargetElement(r.renderer.view,r.renderer.resolution),r}return V(e,t),Object.defineProperty(e.prototype,"useSystemTicker",{get:function(){return this._useSystemTicker},set:function(t){this._useSystemTicker=t,t?this.addTickerListener():this.removeTickerListener()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastObjectRendered",{get:function(){return this.renderer._lastObjectRendered||this._tempDisplayObject},enumerable:!1,configurable:!0}),e.prototype.hitTest=function(t,e){return K.target=null,K.data.global=t,e||(e=this.lastObjectRendered),this.processInteractive(K,e,null,!0),K.target},e.prototype.setTargetElement=function(t,e){void 0===e&&(e=1),this.removeTickerListener(),this.removeEvents(),this.interactionDOMElement=t,this.resolution=e,this.addEvents(),this.addTickerListener()},e.prototype.addTickerListener=function(){!this.tickerAdded&&this.interactionDOMElement&&this._useSystemTicker&&(X.vB.system.add(this.tickerUpdate,this,X.uF.INTERACTION),this.tickerAdded=!0)},e.prototype.removeTickerListener=function(){this.tickerAdded&&(X.vB.system.remove(this.tickerUpdate,this),this.tickerAdded=!1)},e.prototype.addEvents=function(){if(!this.eventsAdded&&this.interactionDOMElement){var t=this.interactionDOMElement.style;globalThis.navigator.msPointerEnabled?(t.msContentZooming="none",t.msTouchAction="none"):this.supportsPointerEvents&&(t.touchAction="none"),this.supportsPointerEvents?(globalThis.document.addEventListener("pointermove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.addEventListener("pointerdown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.addEventListener("pointerleave",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.addEventListener("pointerover",this.onPointerOver,this._eventListenerOptions),globalThis.addEventListener("pointercancel",this.onPointerCancel,this._eventListenerOptions),globalThis.addEventListener("pointerup",this.onPointerUp,this._eventListenerOptions)):(globalThis.document.addEventListener("mousemove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.addEventListener("mousedown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.addEventListener("mouseout",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.addEventListener("mouseover",this.onPointerOver,this._eventListenerOptions),globalThis.addEventListener("mouseup",this.onPointerUp,this._eventListenerOptions)),this.supportsTouchEvents&&(this.interactionDOMElement.addEventListener("touchstart",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.addEventListener("touchcancel",this.onPointerCancel,this._eventListenerOptions),this.interactionDOMElement.addEventListener("touchend",this.onPointerUp,this._eventListenerOptions),this.interactionDOMElement.addEventListener("touchmove",this.onPointerMove,this._eventListenerOptions)),this.eventsAdded=!0}},e.prototype.removeEvents=function(){if(this.eventsAdded&&this.interactionDOMElement){var t=this.interactionDOMElement.style;globalThis.navigator.msPointerEnabled?(t.msContentZooming="",t.msTouchAction=""):this.supportsPointerEvents&&(t.touchAction=""),this.supportsPointerEvents?(globalThis.document.removeEventListener("pointermove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("pointerdown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("pointerleave",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("pointerover",this.onPointerOver,this._eventListenerOptions),globalThis.removeEventListener("pointercancel",this.onPointerCancel,this._eventListenerOptions),globalThis.removeEventListener("pointerup",this.onPointerUp,this._eventListenerOptions)):(globalThis.document.removeEventListener("mousemove",this.onPointerMove,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("mousedown",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("mouseout",this.onPointerOut,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("mouseover",this.onPointerOver,this._eventListenerOptions),globalThis.removeEventListener("mouseup",this.onPointerUp,this._eventListenerOptions)),this.supportsTouchEvents&&(this.interactionDOMElement.removeEventListener("touchstart",this.onPointerDown,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("touchcancel",this.onPointerCancel,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("touchend",this.onPointerUp,this._eventListenerOptions),this.interactionDOMElement.removeEventListener("touchmove",this.onPointerMove,this._eventListenerOptions)),this.interactionDOMElement=null,this.eventsAdded=!1}},e.prototype.tickerUpdate=function(t){this._deltaTime+=t,this._deltaTime<this.interactionFrequency||(this._deltaTime=0,this.update())},e.prototype.update=function(){if(this.interactionDOMElement)if(this._didMove)this._didMove=!1;else{for(var t in this.cursor=null,this.activeInteractionData)if(this.activeInteractionData.hasOwnProperty(t)){var e=this.activeInteractionData[t];if(e.originalEvent&&"touch"!==e.pointerType){var n=this.configureInteractionEventForDOMEvent(this.eventData,e.originalEvent,e);this.processInteractive(n,this.lastObjectRendered,this.processPointerOverOut,!0)}}this.setCursorMode(this.cursor)}},e.prototype.setCursorMode=function(t){t=t||"default";var e=!0;if(globalThis.OffscreenCanvas&&this.interactionDOMElement instanceof OffscreenCanvas&&(e=!1),this.currentCursorMode!==t){this.currentCursorMode=t;var n=this.cursorStyles[t];if(n)switch(typeof n){case"string":e&&(this.interactionDOMElement.style.cursor=n);break;case"function":n(t);break;case"object":e&&Object.assign(this.interactionDOMElement.style,n);break}else e&&"string"===typeof t&&!Object.prototype.hasOwnProperty.call(this.cursorStyles,t)&&(this.interactionDOMElement.style.cursor=t)}},e.prototype.dispatchEvent=function(t,e,n){n.stopPropagationHint&&t!==n.stopsPropagatingAt||(n.currentTarget=t,n.type=e,t.emit(e,n),t[e]&&t[e](n))},e.prototype.delayDispatchEvent=function(t,e,n){this.delayedEvents.push({displayObject:t,eventString:e,eventData:n})},e.prototype.mapPositionToPoint=function(t,e,n){var r;r=this.interactionDOMElement.parentElement?this.interactionDOMElement.getBoundingClientRect():{x:0,y:0,width:this.interactionDOMElement.width,height:this.interactionDOMElement.height,left:0,top:0};var i=1/this.resolution;t.x=(e-r.left)*(this.interactionDOMElement.width/r.width)*i,t.y=(n-r.top)*(this.interactionDOMElement.height/r.height)*i},e.prototype.processInteractive=function(t,e,n,r){var i=this.search.findHit(t,e,n,r),o=this.delayedEvents;if(!o.length)return i;t.stopPropagationHint=!1;var s=o.length;this.delayedEvents=[];for(var a=0;a<s;a++){var u=o[a],l=u.displayObject,c=u.eventString,h=u.eventData;h.stopsPropagatingAt===l&&(h.stopPropagationHint=!0),this.dispatchEvent(l,c,h)}return i},e.prototype.onPointerDown=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t);if(this.autoPreventDefault&&e[0].isNormalized){var n=t.cancelable||!("cancelable"in t);n&&t.preventDefault()}for(var r=e.length,i=0;i<r;i++){var o=e[i],s=this.getInteractionDataForPointerId(o),a=this.configureInteractionEventForDOMEvent(this.eventData,o,s);if(a.data.originalEvent=t,this.processInteractive(a,this.lastObjectRendered,this.processPointerDown,!0),this.emit("pointerdown",a),"touch"===o.pointerType)this.emit("touchstart",a);else if("mouse"===o.pointerType||"pen"===o.pointerType){var u=2===o.button;this.emit(u?"rightdown":"mousedown",this.eventData)}}}},e.prototype.processPointerDown=function(t,e,n){var r=t.data,i=t.data.identifier;if(n)if(e.trackedPointers[i]||(e.trackedPointers[i]=new W(i)),this.dispatchEvent(e,"pointerdown",t),"touch"===r.pointerType)this.dispatchEvent(e,"touchstart",t);else if("mouse"===r.pointerType||"pen"===r.pointerType){var o=2===r.button;o?e.trackedPointers[i].rightDown=!0:e.trackedPointers[i].leftDown=!0,this.dispatchEvent(e,o?"rightdown":"mousedown",t)}},e.prototype.onPointerComplete=function(t,e,n){for(var r=this.normalizeToPointerData(t),i=r.length,o=t.target!==this.interactionDOMElement?"outside":"",s=0;s<i;s++){var a=r[s],u=this.getInteractionDataForPointerId(a),l=this.configureInteractionEventForDOMEvent(this.eventData,a,u);if(l.data.originalEvent=t,this.processInteractive(l,this.lastObjectRendered,n,e||!o),this.emit(e?"pointercancel":"pointerup"+o,l),"mouse"===a.pointerType||"pen"===a.pointerType){var c=2===a.button;this.emit(c?"rightup"+o:"mouseup"+o,l)}else"touch"===a.pointerType&&(this.emit(e?"touchcancel":"touchend"+o,l),this.releaseInteractionDataForPointerId(a.pointerId))}},e.prototype.onPointerCancel=function(t){this.supportsTouchEvents&&"touch"===t.pointerType||this.onPointerComplete(t,!0,this.processPointerCancel)},e.prototype.processPointerCancel=function(t,e){var n=t.data,r=t.data.identifier;void 0!==e.trackedPointers[r]&&(delete e.trackedPointers[r],this.dispatchEvent(e,"pointercancel",t),"touch"===n.pointerType&&this.dispatchEvent(e,"touchcancel",t))},e.prototype.onPointerUp=function(t){this.supportsTouchEvents&&"touch"===t.pointerType||this.onPointerComplete(t,!1,this.processPointerUp)},e.prototype.processPointerUp=function(t,e,n){var r=t.data,i=t.data.identifier,o=e.trackedPointers[i],s="touch"===r.pointerType,a="mouse"===r.pointerType||"pen"===r.pointerType,u=!1;if(a){var l=2===r.button,c=W.FLAGS,h=l?c.RIGHT_DOWN:c.LEFT_DOWN,f=void 0!==o&&o.flags&h;n?(this.dispatchEvent(e,l?"rightup":"mouseup",t),f&&(this.dispatchEvent(e,l?"rightclick":"click",t),u=!0)):f&&this.dispatchEvent(e,l?"rightupoutside":"mouseupoutside",t),o&&(l?o.rightDown=!1:o.leftDown=!1)}n?(this.dispatchEvent(e,"pointerup",t),s&&this.dispatchEvent(e,"touchend",t),o&&(a&&!u||this.dispatchEvent(e,"pointertap",t),s&&(this.dispatchEvent(e,"tap",t),o.over=!1))):o&&(this.dispatchEvent(e,"pointerupoutside",t),s&&this.dispatchEvent(e,"touchendoutside",t)),o&&o.none&&delete e.trackedPointers[i]},e.prototype.onPointerMove=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t);"mouse"!==e[0].pointerType&&"pen"!==e[0].pointerType||(this._didMove=!0,this.cursor=null);for(var n=e.length,r=0;r<n;r++){var i=e[r],o=this.getInteractionDataForPointerId(i),s=this.configureInteractionEventForDOMEvent(this.eventData,i,o);s.data.originalEvent=t,this.processInteractive(s,this.lastObjectRendered,this.processPointerMove,!0),this.emit("pointermove",s),"touch"===i.pointerType&&this.emit("touchmove",s),"mouse"!==i.pointerType&&"pen"!==i.pointerType||this.emit("mousemove",s)}"mouse"===e[0].pointerType&&this.setCursorMode(this.cursor)}},e.prototype.processPointerMove=function(t,e,n){var r=t.data,i="touch"===r.pointerType,o="mouse"===r.pointerType||"pen"===r.pointerType;o&&this.processPointerOverOut(t,e,n),this.moveWhenInside&&!n||(this.dispatchEvent(e,"pointermove",t),i&&this.dispatchEvent(e,"touchmove",t),o&&this.dispatchEvent(e,"mousemove",t))},e.prototype.onPointerOut=function(t){if(!this.supportsTouchEvents||"touch"!==t.pointerType){var e=this.normalizeToPointerData(t),n=e[0];"mouse"===n.pointerType&&(this.mouseOverRenderer=!1,this.setCursorMode(null));var r=this.getInteractionDataForPointerId(n),i=this.configureInteractionEventForDOMEvent(this.eventData,n,r);i.data.originalEvent=n,this.processInteractive(i,this.lastObjectRendered,this.processPointerOverOut,!1),this.emit("pointerout",i),"mouse"===n.pointerType||"pen"===n.pointerType?this.emit("mouseout",i):this.releaseInteractionDataForPointerId(r.identifier)}},e.prototype.processPointerOverOut=function(t,e,n){var r=t.data,i=t.data.identifier,o="mouse"===r.pointerType||"pen"===r.pointerType,s=e.trackedPointers[i];n&&!s&&(s=e.trackedPointers[i]=new W(i)),void 0!==s&&(n&&this.mouseOverRenderer?(s.over||(s.over=!0,this.delayDispatchEvent(e,"pointerover",t),o&&this.delayDispatchEvent(e,"mouseover",t)),o&&null===this.cursor&&(this.cursor=e.cursor)):s.over&&(s.over=!1,this.dispatchEvent(e,"pointerout",this.eventData),o&&this.dispatchEvent(e,"mouseout",t),s.none&&delete e.trackedPointers[i]))},e.prototype.onPointerOver=function(t){var e=this.normalizeToPointerData(t),n=e[0],r=this.getInteractionDataForPointerId(n),i=this.configureInteractionEventForDOMEvent(this.eventData,n,r);i.data.originalEvent=n,"mouse"===n.pointerType&&(this.mouseOverRenderer=!0),this.emit("pointerover",i),"mouse"!==n.pointerType&&"pen"!==n.pointerType||this.emit("mouseover",i)},e.prototype.getInteractionDataForPointerId=function(t){var e,n=t.pointerId;return n===q||"mouse"===t.pointerType?e=this.mouse:this.activeInteractionData[n]?e=this.activeInteractionData[n]:(e=this.interactionDataPool.pop()||new H,e.identifier=n,this.activeInteractionData[n]=e),e.copyEvent(t),e},e.prototype.releaseInteractionDataForPointerId=function(t){var e=this.activeInteractionData[t];e&&(delete this.activeInteractionData[t],e.reset(),this.interactionDataPool.push(e))},e.prototype.configureInteractionEventForDOMEvent=function(t,e,n){return t.data=n,this.mapPositionToPoint(n.global,e.clientX,e.clientY),"touch"===e.pointerType&&(e.globalX=n.global.x,e.globalY=n.global.y),n.originalEvent=e,t.reset(),t},e.prototype.normalizeToPointerData=function(t){var e=[];if(this.supportsTouchEvents&&t instanceof TouchEvent)for(var n=0,r=t.changedTouches.length;n<r;n++){var i=t.changedTouches[n];"undefined"===typeof i.button&&(i.button=t.touches.length?1:0),"undefined"===typeof i.buttons&&(i.buttons=t.touches.length?1:0),"undefined"===typeof i.isPrimary&&(i.isPrimary=1===t.touches.length&&"touchstart"===t.type),"undefined"===typeof i.width&&(i.width=i.radiusX||1),"undefined"===typeof i.height&&(i.height=i.radiusY||1),"undefined"===typeof i.tiltX&&(i.tiltX=0),"undefined"===typeof i.tiltY&&(i.tiltY=0),"undefined"===typeof i.pointerType&&(i.pointerType="touch"),"undefined"===typeof i.pointerId&&(i.pointerId=i.identifier||0),"undefined"===typeof i.pressure&&(i.pressure=i.force||.5),"undefined"===typeof i.twist&&(i.twist=0),"undefined"===typeof i.tangentialPressure&&(i.tangentialPressure=0),"undefined"===typeof i.layerX&&(i.layerX=i.offsetX=i.clientX),"undefined"===typeof i.layerY&&(i.layerY=i.offsetY=i.clientY),i.isNormalized=!0,e.push(i)}else if(globalThis.MouseEvent&&(!(t instanceof MouseEvent)||this.supportsPointerEvents&&t instanceof globalThis.PointerEvent))e.push(t);else{var o=t;"undefined"===typeof o.isPrimary&&(o.isPrimary=!0),"undefined"===typeof o.width&&(o.width=1),"undefined"===typeof o.height&&(o.height=1),"undefined"===typeof o.tiltX&&(o.tiltX=0),"undefined"===typeof o.tiltY&&(o.tiltY=0),"undefined"===typeof o.pointerType&&(o.pointerType="mouse"),"undefined"===typeof o.pointerId&&(o.pointerId=q),"undefined"===typeof o.pressure&&(o.pressure=.5),"undefined"===typeof o.twist&&(o.twist=0),"undefined"===typeof o.tangentialPressure&&(o.tangentialPressure=0),o.isNormalized=!0,e.push(o)}return e},e.prototype.destroy=function(){this.removeEvents(),this.removeTickerListener(),this.removeAllListeners(),this.renderer=null,this.mouse=null,this.eventData=null,this.interactionDOMElement=null,this.onPointerDown=null,this.processPointerDown=null,this.onPointerUp=null,this.processPointerUp=null,this.onPointerCancel=null,this.processPointerCancel=null,this.onPointerMove=null,this.processPointerMove=null,this.onPointerOut=null,this.processPointerOverOut=null,this.onPointerOver=null,this.search=null},e}(O.vp),J=n(2038),Q=function(){function t(e){var n=this;this.stage=new I.W2,e=Object.assign({forceCanvas:!1},e),this.renderer=(0,J.e6)(e),t._plugins.forEach((function(t){t.init.call(n,e)}))}return t.registerPlugin=function(e){t._plugins.push(e)},t.prototype.render=function(){this.renderer.render(this.stage)},Object.defineProperty(t.prototype,"view",{get:function(){return this.renderer.view},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"screen",{get:function(){return this.renderer.screen},enumerable:!1,configurable:!0}),t.prototype.destroy=function(e,n){var r=this,i=t._plugins.slice(0);i.reverse(),i.forEach((function(t){t.destroy.call(r)})),this.stage.destroy(n),this.stage=null,this.renderer.destroy(e),this.renderer=null},t._plugins=[],t}(),tt=function(){function t(){}return t.init=function(t){var e=this;Object.defineProperty(this,"resizeTo",{set:function(t){globalThis.removeEventListener("resize",this.queueResize),this._resizeTo=t,t&&(globalThis.addEventListener("resize",this.queueResize),this.resize())},get:function(){return this._resizeTo}}),this.queueResize=function(){e._resizeTo&&(e.cancelResize(),e._resizeId=requestAnimationFrame((function(){return e.resize()})))},this.cancelResize=function(){e._resizeId&&(cancelAnimationFrame(e._resizeId),e._resizeId=null)},this.resize=function(){if(e._resizeTo){var t,n;if(e.cancelResize(),e._resizeTo===globalThis.window)t=globalThis.innerWidth,n=globalThis.innerHeight;else{var r=e._resizeTo,i=r.clientWidth,o=r.clientHeight;t=i,n=o}e.renderer.resize(t,n)}},this._resizeId=null,this._resizeTo=null,this.resizeTo=t.resizeTo||null},t.destroy=function(){globalThis.removeEventListener("resize",this.queueResize),this.cancelResize(),this.cancelResize=null,this.queueResize=null,this.resizeTo=null,this.resize=null},t}();Q.registerPlugin(tt); -/*! - * @pixi/extract - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/extract is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -var et=new k.Ae,nt=4,rt=function(){function t(t){this.renderer=t}return t.prototype.image=function(t,e,n){var r=new Image;return r.src=this.base64(t,e,n),r},t.prototype.base64=function(t,e,n){return this.canvas(t).toDataURL(e,n)},t.prototype.canvas=function(e){var n,r,i,o=this.renderer,s=!1,a=!1;e&&(e instanceof J.TI?i=e:(i=this.renderer.generateTexture(e),a=!0)),i?(n=i.baseTexture.resolution,r=i.frame,s=!1,o.renderTexture.bind(i)):(n=this.renderer.resolution,s=!0,r=et,r.width=this.renderer.width,r.height=this.renderer.height,o.renderTexture.bind(null));var u=Math.floor(r.width*n+1e-4),l=Math.floor(r.height*n+1e-4),c=new O.qU(u,l,1),h=new Uint8Array(nt*u*l),f=o.gl;f.readPixels(r.x*n,r.y*n,u,l,f.RGBA,f.UNSIGNED_BYTE,h);var d=c.context.getImageData(0,0,u,l);if(t.arrayPostDivide(h,d.data),c.context.putImageData(d,0,0),s){var p=new O.qU(c.width,c.height,1);p.context.scale(1,-1),p.context.drawImage(c.canvas,0,-l),c.destroy(),c=p}return a&&i.destroy(!0),c.canvas},t.prototype.pixels=function(e){var n,r,i,o=this.renderer,s=!1;e&&(e instanceof J.TI?i=e:(i=this.renderer.generateTexture(e),s=!0)),i?(n=i.baseTexture.resolution,r=i.frame,o.renderTexture.bind(i)):(n=o.resolution,r=et,r.width=o.width,r.height=o.height,o.renderTexture.bind(null));var a=r.width*n,u=r.height*n,l=new Uint8Array(nt*a*u),c=o.gl;return c.readPixels(r.x*n,r.y*n,a,u,c.RGBA,c.UNSIGNED_BYTE,l),s&&i.destroy(!0),t.arrayPostDivide(l,l),l},t.prototype.destroy=function(){this.renderer=null},t.arrayPostDivide=function(t,e){for(var n=0;n<t.length;n+=4){var r=e[n+3]=t[n+3];0!==r?(e[n]=Math.round(Math.min(255*t[n]/r,255)),e[n+1]=Math.round(Math.min(255*t[n+1]/r,255)),e[n+2]=Math.round(Math.min(255*t[n+2]/r,255))):(e[n]=t[n],e[n+1]=t[n+1],e[n+2]=t[n+2])}},t}(),it=function(){function t(t,e,n){void 0===e&&(e=!1),this._fn=t,this._once=e,this._thisArg=n,this._next=this._prev=this._owner=null}return t.prototype.detach=function(){return null!==this._owner&&(this._owner.detach(this),!0)},t}();function ot(t,e){return t._head?(t._tail._next=e,e._prev=t._tail,t._tail=e):(t._head=e,t._tail=e),e._owner=t,e}var st=function(){function t(){this._head=this._tail=void 0}return t.prototype.handlers=function(t){void 0===t&&(t=!1);var e=this._head;if(t)return!!e;var n=[];while(e)n.push(e),e=e._next;return n},t.prototype.has=function(t){if(!(t instanceof it))throw new Error("MiniSignal#has(): First arg must be a SignalBinding object.");return t._owner===this},t.prototype.dispatch=function(){for(var t=arguments,e=[],n=0;n<arguments.length;n++)e[n]=t[n];var r=this._head;if(!r)return!1;while(r)r._once&&this.detach(r),r._fn.apply(r._thisArg,e),r=r._next;return!0},t.prototype.add=function(t,e){if(void 0===e&&(e=null),"function"!==typeof t)throw new Error("MiniSignal#add(): First arg must be a Function.");return ot(this,new it(t,!1,e))},t.prototype.once=function(t,e){if(void 0===e&&(e=null),"function"!==typeof t)throw new Error("MiniSignal#once(): First arg must be a Function.");return ot(this,new it(t,!0,e))},t.prototype.detach=function(t){if(!(t instanceof it))throw new Error("MiniSignal#detach(): First arg must be a SignalBinding object.");return t._owner!==this||(t._prev&&(t._prev._next=t._next),t._next&&(t._next._prev=t._prev),t===this._head?(this._head=t._next,null===t._next&&(this._tail=null)):t===this._tail&&(this._tail=t._prev,this._tail._next=null),t._owner=null),this},t.prototype.detachAll=function(){var t=this._head;if(!t)return this;this._head=this._tail=null;while(t)t._owner=null,t=t._next;return this},t}();function at(t,e){e=e||{};var n={key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],q:{name:"queryKey",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}},r=n.parser[e.strictMode?"strict":"loose"].exec(t),i={},o=14;while(o--)i[n.key[o]]=r[o]||"";return i[n.q.name]={},i[n.key[12]].replace(n.q.parser,(function(t,e,r){e&&(i[n.q.name][e]=r)})),i}var ut=!(!globalThis.XDomainRequest||"withCredentials"in new XMLHttpRequest),lt=null,ct=0,ht=200,ft=204,dt=1223,pt=2;function mt(){}function vt(t,e,n){e&&0===e.indexOf(".")&&(e=e.substring(1)),e&&(t[e]=n)}function gt(t){return t.toString().replace("object ","")}var _t=function(){function t(e,n,r){if(this._dequeue=mt,this._onLoadBinding=null,this._elementTimer=0,this._boundComplete=null,this._boundOnError=null,this._boundOnProgress=null,this._boundOnTimeout=null,this._boundXhrOnError=null,this._boundXhrOnTimeout=null,this._boundXhrOnAbort=null,this._boundXhrOnLoad=null,"string"!==typeof e||"string"!==typeof n)throw new Error("Both name and url are required for constructing a resource.");r=r||{},this._flags=0,this._setFlag(t.STATUS_FLAGS.DATA_URL,0===n.indexOf("data:")),this.name=e,this.url=n,this.extension=this._getExtension(),this.data=null,this.crossOrigin=!0===r.crossOrigin?"anonymous":r.crossOrigin,this.timeout=r.timeout||0,this.loadType=r.loadType||this._determineLoadType(),this.xhrType=r.xhrType,this.metadata=r.metadata||{},this.error=null,this.xhr=null,this.children=[],this.type=t.TYPE.UNKNOWN,this.progressChunk=0,this._dequeue=mt,this._onLoadBinding=null,this._elementTimer=0,this._boundComplete=this.complete.bind(this),this._boundOnError=this._onError.bind(this),this._boundOnProgress=this._onProgress.bind(this),this._boundOnTimeout=this._onTimeout.bind(this),this._boundXhrOnError=this._xhrOnError.bind(this),this._boundXhrOnTimeout=this._xhrOnTimeout.bind(this),this._boundXhrOnAbort=this._xhrOnAbort.bind(this),this._boundXhrOnLoad=this._xhrOnLoad.bind(this),this.onStart=new st,this.onProgress=new st,this.onComplete=new st,this.onAfterMiddleware=new st}return t.setExtensionLoadType=function(e,n){vt(t._loadTypeMap,e,n)},t.setExtensionXhrType=function(e,n){vt(t._xhrTypeMap,e,n)},Object.defineProperty(t.prototype,"isDataUrl",{get:function(){return this._hasFlag(t.STATUS_FLAGS.DATA_URL)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isComplete",{get:function(){return this._hasFlag(t.STATUS_FLAGS.COMPLETE)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isLoading",{get:function(){return this._hasFlag(t.STATUS_FLAGS.LOADING)},enumerable:!1,configurable:!0}),t.prototype.complete=function(){this._clearEvents(),this._finish()},t.prototype.abort=function(e){if(!this.error){if(this.error=new Error(e),this._clearEvents(),this.xhr)this.xhr.abort();else if(this.xdr)this.xdr.abort();else if(this.data)if(this.data.src)this.data.src=t.EMPTY_GIF;else while(this.data.firstChild)this.data.removeChild(this.data.firstChild);this._finish()}},t.prototype.load=function(e){var n=this;if(!this.isLoading)if(this.isComplete)e&&setTimeout((function(){return e(n)}),1);else switch(e&&this.onComplete.once(e),this._setFlag(t.STATUS_FLAGS.LOADING,!0),this.onStart.dispatch(this),!1!==this.crossOrigin&&"string"===typeof this.crossOrigin||(this.crossOrigin=this._determineCrossOrigin(this.url)),this.loadType){case t.LOAD_TYPE.IMAGE:this.type=t.TYPE.IMAGE,this._loadElement("image");break;case t.LOAD_TYPE.AUDIO:this.type=t.TYPE.AUDIO,this._loadSourceElement("audio");break;case t.LOAD_TYPE.VIDEO:this.type=t.TYPE.VIDEO,this._loadSourceElement("video");break;case t.LOAD_TYPE.XHR:default:ut&&this.crossOrigin?this._loadXdr():this._loadXhr();break}},t.prototype._hasFlag=function(t){return 0!==(this._flags&t)},t.prototype._setFlag=function(t,e){this._flags=e?this._flags|t:this._flags&~t},t.prototype._clearEvents=function(){clearTimeout(this._elementTimer),this.data&&this.data.removeEventListener&&(this.data.removeEventListener("error",this._boundOnError,!1),this.data.removeEventListener("load",this._boundComplete,!1),this.data.removeEventListener("progress",this._boundOnProgress,!1),this.data.removeEventListener("canplaythrough",this._boundComplete,!1)),this.xhr&&(this.xhr.removeEventListener?(this.xhr.removeEventListener("error",this._boundXhrOnError,!1),this.xhr.removeEventListener("timeout",this._boundXhrOnTimeout,!1),this.xhr.removeEventListener("abort",this._boundXhrOnAbort,!1),this.xhr.removeEventListener("progress",this._boundOnProgress,!1),this.xhr.removeEventListener("load",this._boundXhrOnLoad,!1)):(this.xhr.onerror=null,this.xhr.ontimeout=null,this.xhr.onprogress=null,this.xhr.onload=null))},t.prototype._finish=function(){if(this.isComplete)throw new Error("Complete called again for an already completed resource.");this._setFlag(t.STATUS_FLAGS.COMPLETE,!0),this._setFlag(t.STATUS_FLAGS.LOADING,!1),this.onComplete.dispatch(this)},t.prototype._loadElement=function(t){this.metadata.loadElement?this.data=this.metadata.loadElement:"image"===t&&"undefined"!==typeof globalThis.Image?this.data=new Image:this.data=document.createElement(t),this.crossOrigin&&(this.data.crossOrigin=this.crossOrigin),this.metadata.skipSource||(this.data.src=this.url),this.data.addEventListener("error",this._boundOnError,!1),this.data.addEventListener("load",this._boundComplete,!1),this.data.addEventListener("progress",this._boundOnProgress,!1),this.timeout&&(this._elementTimer=setTimeout(this._boundOnTimeout,this.timeout))},t.prototype._loadSourceElement=function(t){if(this.metadata.loadElement?this.data=this.metadata.loadElement:"audio"===t&&"undefined"!==typeof globalThis.Audio?this.data=new Audio:this.data=document.createElement(t),null!==this.data){if(this.crossOrigin&&(this.data.crossOrigin=this.crossOrigin),!this.metadata.skipSource)if(navigator.isCocoonJS)this.data.src=Array.isArray(this.url)?this.url[0]:this.url;else if(Array.isArray(this.url))for(var e=this.metadata.mimeType,n=0;n<this.url.length;++n)this.data.appendChild(this._createSource(t,this.url[n],Array.isArray(e)?e[n]:e));else{e=this.metadata.mimeType;this.data.appendChild(this._createSource(t,this.url,Array.isArray(e)?e[0]:e))}this.data.addEventListener("error",this._boundOnError,!1),this.data.addEventListener("load",this._boundComplete,!1),this.data.addEventListener("progress",this._boundOnProgress,!1),this.data.addEventListener("canplaythrough",this._boundComplete,!1),this.data.load(),this.timeout&&(this._elementTimer=setTimeout(this._boundOnTimeout,this.timeout))}else this.abort("Unsupported element: "+t)},t.prototype._loadXhr=function(){"string"!==typeof this.xhrType&&(this.xhrType=this._determineXhrType());var e=this.xhr=new XMLHttpRequest;"use-credentials"===this.crossOrigin&&(e.withCredentials=!0),e.open("GET",this.url,!0),e.timeout=this.timeout,this.xhrType===t.XHR_RESPONSE_TYPE.JSON||this.xhrType===t.XHR_RESPONSE_TYPE.DOCUMENT?e.responseType=t.XHR_RESPONSE_TYPE.TEXT:e.responseType=this.xhrType,e.addEventListener("error",this._boundXhrOnError,!1),e.addEventListener("timeout",this._boundXhrOnTimeout,!1),e.addEventListener("abort",this._boundXhrOnAbort,!1),e.addEventListener("progress",this._boundOnProgress,!1),e.addEventListener("load",this._boundXhrOnLoad,!1),e.send()},t.prototype._loadXdr=function(){"string"!==typeof this.xhrType&&(this.xhrType=this._determineXhrType());var t=this.xhr=new globalThis.XDomainRequest;t.timeout=this.timeout||5e3,t.onerror=this._boundXhrOnError,t.ontimeout=this._boundXhrOnTimeout,t.onprogress=this._boundOnProgress,t.onload=this._boundXhrOnLoad,t.open("GET",this.url,!0),setTimeout((function(){return t.send()}),1)},t.prototype._createSource=function(t,e,n){n||(n=t+"/"+this._getExtension(e));var r=document.createElement("source");return r.src=e,r.type=n,r},t.prototype._onError=function(t){this.abort("Failed to load element using: "+t.target.nodeName)},t.prototype._onProgress=function(t){t&&t.lengthComputable&&this.onProgress.dispatch(this,t.loaded/t.total)},t.prototype._onTimeout=function(){this.abort("Load timed out.")},t.prototype._xhrOnError=function(){var t=this.xhr;this.abort(gt(t)+" Request failed. Status: "+t.status+', text: "'+t.statusText+'"')},t.prototype._xhrOnTimeout=function(){var t=this.xhr;this.abort(gt(t)+" Request timed out.")},t.prototype._xhrOnAbort=function(){var t=this.xhr;this.abort(gt(t)+" Request was aborted by the user.")},t.prototype._xhrOnLoad=function(){var e=this.xhr,n="",r="undefined"===typeof e.status?ht:e.status;""!==e.responseType&&"text"!==e.responseType&&"undefined"!==typeof e.responseType||(n=e.responseText),r===ct&&(n.length>0||e.responseType===t.XHR_RESPONSE_TYPE.BUFFER)?r=ht:r===dt&&(r=ft);var i=r/100|0;if(i===pt){if(this.xhrType===t.XHR_RESPONSE_TYPE.TEXT)this.data=n,this.type=t.TYPE.TEXT;else if(this.xhrType===t.XHR_RESPONSE_TYPE.JSON)try{this.data=JSON.parse(n),this.type=t.TYPE.JSON}catch(a){return void this.abort("Error trying to parse loaded json: "+a)}else if(this.xhrType===t.XHR_RESPONSE_TYPE.DOCUMENT)try{if(globalThis.DOMParser){var o=new DOMParser;this.data=o.parseFromString(n,"text/xml")}else{var s=document.createElement("div");s.innerHTML=n,this.data=s}this.type=t.TYPE.XML}catch(u){return void this.abort("Error trying to parse loaded xml: "+u)}else this.data=e.response||n;this.complete()}else this.abort("["+e.status+"] "+e.statusText+": "+e.responseURL)},t.prototype._determineCrossOrigin=function(t,e){if(0===t.indexOf("data:"))return"";if(globalThis.origin!==globalThis.location.origin)return"anonymous";e=e||globalThis.location,lt||(lt=document.createElement("a")),lt.href=t;var n=at(lt.href,{strictMode:!0}),r=!n.port&&""===e.port||n.port===e.port,i=n.protocol?n.protocol+":":"";return n.host===e.hostname&&r&&i===e.protocol?"":"anonymous"},t.prototype._determineXhrType=function(){return t._xhrTypeMap[this.extension]||t.XHR_RESPONSE_TYPE.TEXT},t.prototype._determineLoadType=function(){return t._loadTypeMap[this.extension]||t.LOAD_TYPE.XHR},t.prototype._getExtension=function(t){void 0===t&&(t=this.url);var e="";if(this.isDataUrl){var n=t.indexOf("/");e=t.substring(n+1,t.indexOf(";",n))}else{var r=t.indexOf("?"),i=t.indexOf("#"),o=Math.min(r>-1?r:t.length,i>-1?i:t.length);t=t.substring(0,o),e=t.substring(t.lastIndexOf(".")+1)}return e.toLowerCase()},t.prototype._getMimeFromXhrType=function(e){switch(e){case t.XHR_RESPONSE_TYPE.BUFFER:return"application/octet-binary";case t.XHR_RESPONSE_TYPE.BLOB:return"application/blob";case t.XHR_RESPONSE_TYPE.DOCUMENT:return"application/xml";case t.XHR_RESPONSE_TYPE.JSON:return"application/json";case t.XHR_RESPONSE_TYPE.DEFAULT:case t.XHR_RESPONSE_TYPE.TEXT:default:return"text/plain"}},t}();function yt(){}function bt(t){return function(){for(var e=arguments,n=[],r=0;r<arguments.length;r++)n[r]=e[r];if(null===t)throw new Error("Callback was already called.");var i=t;t=null,i.apply(this,n)}}(function(t){(function(t){t[t["NONE"]=0]="NONE",t[t["DATA_URL"]=1]="DATA_URL",t[t["COMPLETE"]=2]="COMPLETE",t[t["LOADING"]=4]="LOADING"})(t.STATUS_FLAGS||(t.STATUS_FLAGS={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["JSON"]=1]="JSON",t[t["XML"]=2]="XML",t[t["IMAGE"]=3]="IMAGE",t[t["AUDIO"]=4]="AUDIO",t[t["VIDEO"]=5]="VIDEO",t[t["TEXT"]=6]="TEXT"}(t.TYPE||(t.TYPE={})),function(t){t[t["XHR"]=1]="XHR",t[t["IMAGE"]=2]="IMAGE",t[t["AUDIO"]=3]="AUDIO",t[t["VIDEO"]=4]="VIDEO"}(t.LOAD_TYPE||(t.LOAD_TYPE={})),function(t){t["DEFAULT"]="text",t["BUFFER"]="arraybuffer",t["BLOB"]="blob",t["DOCUMENT"]="document",t["JSON"]="json",t["TEXT"]="text"}(t.XHR_RESPONSE_TYPE||(t.XHR_RESPONSE_TYPE={})),t._loadTypeMap={gif:t.LOAD_TYPE.IMAGE,png:t.LOAD_TYPE.IMAGE,bmp:t.LOAD_TYPE.IMAGE,jpg:t.LOAD_TYPE.IMAGE,jpeg:t.LOAD_TYPE.IMAGE,tif:t.LOAD_TYPE.IMAGE,tiff:t.LOAD_TYPE.IMAGE,webp:t.LOAD_TYPE.IMAGE,tga:t.LOAD_TYPE.IMAGE,svg:t.LOAD_TYPE.IMAGE,"svg+xml":t.LOAD_TYPE.IMAGE,mp3:t.LOAD_TYPE.AUDIO,ogg:t.LOAD_TYPE.AUDIO,wav:t.LOAD_TYPE.AUDIO,mp4:t.LOAD_TYPE.VIDEO,webm:t.LOAD_TYPE.VIDEO},t._xhrTypeMap={xhtml:t.XHR_RESPONSE_TYPE.DOCUMENT,html:t.XHR_RESPONSE_TYPE.DOCUMENT,htm:t.XHR_RESPONSE_TYPE.DOCUMENT,xml:t.XHR_RESPONSE_TYPE.DOCUMENT,tmx:t.XHR_RESPONSE_TYPE.DOCUMENT,svg:t.XHR_RESPONSE_TYPE.DOCUMENT,tsx:t.XHR_RESPONSE_TYPE.DOCUMENT,gif:t.XHR_RESPONSE_TYPE.BLOB,png:t.XHR_RESPONSE_TYPE.BLOB,bmp:t.XHR_RESPONSE_TYPE.BLOB,jpg:t.XHR_RESPONSE_TYPE.BLOB,jpeg:t.XHR_RESPONSE_TYPE.BLOB,tif:t.XHR_RESPONSE_TYPE.BLOB,tiff:t.XHR_RESPONSE_TYPE.BLOB,webp:t.XHR_RESPONSE_TYPE.BLOB,tga:t.XHR_RESPONSE_TYPE.BLOB,json:t.XHR_RESPONSE_TYPE.JSON,text:t.XHR_RESPONSE_TYPE.TEXT,txt:t.XHR_RESPONSE_TYPE.TEXT,ttf:t.XHR_RESPONSE_TYPE.BUFFER,otf:t.XHR_RESPONSE_TYPE.BUFFER},t.EMPTY_GIF="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=="})(_t||(_t={}));var Et=function(){function t(t,e){this.data=t,this.callback=e}return t}(),Tt=function(){function t(t,e){var n=this;if(void 0===e&&(e=1),this.workers=0,this.saturated=yt,this.unsaturated=yt,this.empty=yt,this.drain=yt,this.error=yt,this.started=!1,this.paused=!1,this._tasks=[],this._insert=function(t,e,r){if(r&&"function"!==typeof r)throw new Error("task callback must be a function");if(n.started=!0,null==t&&n.idle())setTimeout((function(){return n.drain()}),1);else{var i=new Et(t,"function"===typeof r?r:yt);e?n._tasks.unshift(i):n._tasks.push(i),setTimeout(n.process,1)}},this.process=function(){while(!n.paused&&n.workers<n.concurrency&&n._tasks.length){var t=n._tasks.shift();0===n._tasks.length&&n.empty(),n.workers+=1,n.workers===n.concurrency&&n.saturated(),n._worker(t.data,bt(n._next(t)))}},this._worker=t,0===e)throw new Error("Concurrency must not be zero");this.concurrency=e,this.buffer=e/4}return t.prototype._next=function(t){var e=this;return function(){for(var n=arguments,r=[],i=0;i<arguments.length;i++)r[i]=n[i];e.workers-=1,t.callback.apply(t,r),null!=r[0]&&e.error(r[0],t.data),e.workers<=e.concurrency-e.buffer&&e.unsaturated(),e.idle()&&e.drain(),e.process()}},t.prototype.push=function(t,e){this._insert(t,!1,e)},t.prototype.kill=function(){this.workers=0,this.drain=yt,this.started=!1,this._tasks=[]},t.prototype.unshift=function(t,e){this._insert(t,!0,e)},t.prototype.length=function(){return this._tasks.length},t.prototype.running=function(){return this.workers},t.prototype.idle=function(){return this._tasks.length+this.workers===0},t.prototype.pause=function(){!0!==this.paused&&(this.paused=!0)},t.prototype.resume=function(){if(!1!==this.paused){this.paused=!1;for(var t=1;t<=this.concurrency;t++)this.process()}},t.eachSeries=function(t,e,n,r){var i=0,o=t.length;function s(a){a||i===o?n&&n(a):r?setTimeout((function(){e(t[i++],s)}),1):e(t[i++],s)}s()},t.queue=function(e,n){return new t(e,n)},t}(),xt=100,St=/(#[\w-]+)?$/,Rt=function(){function t(e,n){var r=this;void 0===e&&(e=""),void 0===n&&(n=10),this.progress=0,this.loading=!1,this.defaultQueryString="",this._beforeMiddleware=[],this._afterMiddleware=[],this._resourcesParsing=[],this._boundLoadResource=function(t,e){return r._loadResource(t,e)},this.resources={},this.baseUrl=e,this._beforeMiddleware=[],this._afterMiddleware=[],this._resourcesParsing=[],this._boundLoadResource=function(t,e){return r._loadResource(t,e)},this._queue=Tt.queue(this._boundLoadResource,n),this._queue.pause(),this.resources={},this.onProgress=new st,this.onError=new st,this.onLoad=new st,this.onStart=new st,this.onComplete=new st;for(var i=0;i<t._plugins.length;++i){var o=t._plugins[i],s=o.pre,a=o.use;s&&this.pre(s),a&&this.use(a)}this._protected=!1}return t.prototype._add=function(t,e,n,r){if(this.loading&&(!n||!n.parentResource))throw new Error("Cannot add resources while the loader is running.");if(this.resources[t])throw new Error('Resource named "'+t+'" already exists.');if(e=this._prepareUrl(e),this.resources[t]=new _t(t,e,n),"function"===typeof r&&this.resources[t].onAfterMiddleware.once(r),this.loading){for(var i=n.parentResource,o=[],s=0;s<i.children.length;++s)i.children[s].isComplete||o.push(i.children[s]);var a=i.progressChunk*(o.length+1),u=a/(o.length+2);i.children.push(this.resources[t]),i.progressChunk=u;for(s=0;s<o.length;++s)o[s].progressChunk=u;this.resources[t].progressChunk=u}return this._queue.push(this.resources[t]),this},t.prototype.pre=function(t){return this._beforeMiddleware.push(t),this},t.prototype.use=function(t){return this._afterMiddleware.push(t),this},t.prototype.reset=function(){for(var t in this.progress=0,this.loading=!1,this._queue.kill(),this._queue.pause(),this.resources){var e=this.resources[t];e._onLoadBinding&&e._onLoadBinding.detach(),e.isLoading&&e.abort("loader reset")}return this.resources={},this},t.prototype.load=function(t){if("function"===typeof t&&this.onComplete.once(t),this.loading)return this;if(this._queue.idle())this._onStart(),this._onComplete();else{for(var e=this._queue._tasks.length,n=xt/e,r=0;r<this._queue._tasks.length;++r)this._queue._tasks[r].data.progressChunk=n;this._onStart(),this._queue.resume()}return this},Object.defineProperty(t.prototype,"concurrency",{get:function(){return this._queue.concurrency},set:function(t){this._queue.concurrency=t},enumerable:!1,configurable:!0}),t.prototype._prepareUrl=function(t){var e,n=at(t,{strictMode:!0});if(e=n.protocol||!n.path||0===t.indexOf("//")?t:this.baseUrl.length&&this.baseUrl.lastIndexOf("/")!==this.baseUrl.length-1&&"/"!==t.charAt(0)?this.baseUrl+"/"+t:this.baseUrl+t,this.defaultQueryString){var r=St.exec(e)[0];e=e.slice(0,e.length-r.length),-1!==e.indexOf("?")?e+="&"+this.defaultQueryString:e+="?"+this.defaultQueryString,e+=r}return e},t.prototype._loadResource=function(t,e){var n=this;t._dequeue=e,Tt.eachSeries(this._beforeMiddleware,(function(e,r){e.call(n,t,(function(){r(t.isComplete?{}:null)}))}),(function(){t.isComplete?n._onLoad(t):(t._onLoadBinding=t.onComplete.once(n._onLoad,n),t.load())}),!0)},t.prototype._onStart=function(){this.progress=0,this.loading=!0,this.onStart.dispatch(this)},t.prototype._onComplete=function(){this.progress=xt,this.loading=!1,this.onComplete.dispatch(this,this.resources)},t.prototype._onLoad=function(t){var e=this;t._onLoadBinding=null,this._resourcesParsing.push(t),t._dequeue(),Tt.eachSeries(this._afterMiddleware,(function(n,r){n.call(e,t,r)}),(function(){t.onAfterMiddleware.dispatch(t),e.progress=Math.min(xt,e.progress+t.progressChunk),e.onProgress.dispatch(e,t),t.error?e.onError.dispatch(t.error,e,t):e.onLoad.dispatch(e,t),e._resourcesParsing.splice(e._resourcesParsing.indexOf(t),1),e._queue.idle()&&0===e._resourcesParsing.length&&e._onComplete()}),!0)},t.prototype.destroy=function(){this._protected||this.reset()},Object.defineProperty(t,"shared",{get:function(){var e=t._shared;return e||(e=new t,e._protected=!0,t._shared=e),e},enumerable:!1,configurable:!0}),t.registerPlugin=function(e){return t._plugins.push(e),e.add&&e.add(),t},t._plugins=[],t}();Rt.prototype.add=function(t,e,n,r){if(Array.isArray(t)){for(var i=0;i<t.length;++i)this.add(t[i]);return this}if("object"===typeof t&&(n=t,r=e||n.callback||n.onComplete,e=n.url,t=n.name||n.key||n.url),"string"!==typeof e&&(r=n,n=e,e=t),"string"!==typeof e)throw new Error("No url passed to add resource to loader.");return"function"===typeof n&&(r=n,n=null),this._add(t,e,n,r)};var At=function(){function t(){}return t.init=function(t){t=Object.assign({sharedLoader:!1},t),this.loader=t.sharedLoader?Rt.shared:new Rt},t.destroy=function(){this.loader&&(this.loader.destroy(),this.loader=null)},t}(),Ot=function(){function t(){}return t.add=function(){_t.setExtensionLoadType("svg",_t.LOAD_TYPE.XHR),_t.setExtensionXhrType("svg",_t.XHR_RESPONSE_TYPE.TEXT)},t.use=function(t,e){if(!t.data||t.type!==_t.TYPE.IMAGE&&"svg"!==t.extension)e();else{var n=t.data,r=t.url,i=t.name,o=t.metadata;J.xE.fromLoader(n,r,i,o).then((function(n){t.texture=n,e()})).catch(e)}},t}(),It="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function wt(t){var e="",n=0;while(n<t.length){for(var r=[0,0,0],i=[0,0,0,0],o=0;o<r.length;++o)n<t.length?r[o]=255&t.charCodeAt(n++):r[o]=0;i[0]=r[0]>>2,i[1]=(3&r[0])<<4|r[1]>>4,i[2]=(15&r[1])<<2|r[2]>>6,i[3]=63&r[2];var s=n-(t.length-1);switch(s){case 2:i[3]=64,i[2]=64;break;case 1:i[3]=64;break}for(o=0;o<i.length;++o)e+=It.charAt(i[o])}return e}var Ct=self.URL||self.webkitURL;function Pt(t,e){if(t.data){if(t.xhr&&t.xhrType===_t.XHR_RESPONSE_TYPE.BLOB)if(self.Blob&&"string"!==typeof t.data){if(0===t.data.type.indexOf("image")){var n=Ct.createObjectURL(t.data);return t.blob=t.data,t.data=new Image,t.data.src=n,t.type=_t.TYPE.IMAGE,void(t.data.onload=function(){Ct.revokeObjectURL(n),t.data.onload=null,e()})}}else{var r=t.xhr.getResponseHeader("content-type");if(r&&0===r.indexOf("image"))return t.data=new Image,t.data.src="data:"+r+";base64,"+wt(t.xhr.responseText),t.type=_t.TYPE.IMAGE,void(t.data.onload=function(){t.data.onload=null,e()})}e()}else e()}Rt.registerPlugin({use:Pt}),Rt.registerPlugin(Ot);var Nt,Mt,Dt=n(1680);(function(t){t[t["COMPRESSED_RGB_S3TC_DXT1_EXT"]=33776]="COMPRESSED_RGB_S3TC_DXT1_EXT",t[t["COMPRESSED_RGBA_S3TC_DXT1_EXT"]=33777]="COMPRESSED_RGBA_S3TC_DXT1_EXT",t[t["COMPRESSED_RGBA_S3TC_DXT3_EXT"]=33778]="COMPRESSED_RGBA_S3TC_DXT3_EXT",t[t["COMPRESSED_RGBA_S3TC_DXT5_EXT"]=33779]="COMPRESSED_RGBA_S3TC_DXT5_EXT",t[t["COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT"]=35917]="COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT",t[t["COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT"]=35918]="COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT",t[t["COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT"]=35919]="COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT",t[t["COMPRESSED_SRGB_S3TC_DXT1_EXT"]=35916]="COMPRESSED_SRGB_S3TC_DXT1_EXT",t[t["COMPRESSED_R11_EAC"]=37488]="COMPRESSED_R11_EAC",t[t["COMPRESSED_SIGNED_R11_EAC"]=37489]="COMPRESSED_SIGNED_R11_EAC",t[t["COMPRESSED_RG11_EAC"]=37490]="COMPRESSED_RG11_EAC",t[t["COMPRESSED_SIGNED_RG11_EAC"]=37491]="COMPRESSED_SIGNED_RG11_EAC",t[t["COMPRESSED_RGB8_ETC2"]=37492]="COMPRESSED_RGB8_ETC2",t[t["COMPRESSED_RGBA8_ETC2_EAC"]=37496]="COMPRESSED_RGBA8_ETC2_EAC",t[t["COMPRESSED_SRGB8_ETC2"]=37493]="COMPRESSED_SRGB8_ETC2",t[t["COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"]=37497]="COMPRESSED_SRGB8_ALPHA8_ETC2_EAC",t[t["COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"]=37494]="COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2",t[t["COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"]=37495]="COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2",t[t["COMPRESSED_RGB_PVRTC_4BPPV1_IMG"]=35840]="COMPRESSED_RGB_PVRTC_4BPPV1_IMG",t[t["COMPRESSED_RGBA_PVRTC_4BPPV1_IMG"]=35842]="COMPRESSED_RGBA_PVRTC_4BPPV1_IMG",t[t["COMPRESSED_RGB_PVRTC_2BPPV1_IMG"]=35841]="COMPRESSED_RGB_PVRTC_2BPPV1_IMG",t[t["COMPRESSED_RGBA_PVRTC_2BPPV1_IMG"]=35843]="COMPRESSED_RGBA_PVRTC_2BPPV1_IMG",t[t["COMPRESSED_RGB_ETC1_W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PVRTC_4BPPV1_IMG]=.5,Nt[Mt.COMPRESSED_RGB_PVRTC_2BPPV1_IMG]=.25,Nt[Mt.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG]=.25,Nt[Mt.COMPRESSED_RGB_ETC1_WEBGL]=.5,Nt[Mt.COMPRESSED_RGB_ATC_WEBGL]=.5,Nt[Mt.COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL]=1,Nt[Mt.COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL]=1,Nt),Bt=function(t,e){return Bt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Bt(t,e)}; -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */function Ft(t,e){function n(){this.constructor=t}Bt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function Ut(t,e,n,r){return new(n||(n=Promise))((function(i,o){function s(t){try{u(r.next(t))}catch(e){o(e)}}function a(t){try{u(r["throw"](t))}catch(e){o(e)}}function u(t){t.done?i(t.value):new n((function(e){e(t.value)})).then(s,a)}u((r=r.apply(t,e||[])).next())}))}function Gt(t,e){var n,r,i,o,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"===typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(t){return function(e){return u([t,e])}}function u(o){if(n)throw new TypeError("Generator is already executing.");while(s)try{if(n=1,r&&(i=2&o[0]?r["return"]:o[0]?r["throw"]||((i=r["return"])&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,r=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(i=s.trys,!(i=i.length>0&&i[i.length-1])&&(6===o[0]||2===o[0])){s=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){s.label=o[1];break}if(6===o[0]&&s.label<i[1]){s.label=i[1],i=o;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(o);break}i[2]&&s.ops.pop(),s.trys.pop();continue}o=e.call(t,s)}catch(a){o=[6,a],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}}var kt,Xt,Ht=function(t){function e(e,n){void 0===n&&(n={width:1,height:1,autoLoad:!0});var r,i,o=this;return"string"===typeof e?(r=e,i=new Uint8Array):(r=null,i=e),o=t.call(this,i,n)||this,o.origin=r,o.buffer=i?new J.Rv(i):null,o.origin&&!1!==n.autoLoad&&o.load(),i&&i.length&&(o.loaded=!0,o.onBlobLoaded(o.buffer.rawBinaryData)),o}return Ft(e,t),e.prototype.onBlobLoaded=function(t){},e.prototype.load=function(){return Ut(this,void 0,Promise,(function(){var t,e,n;return Gt(this,(function(r){switch(r.label){case 0:return[4,fetch(this.origin)];case 1:return t=r.sent(),[4,t.blob()];case 2:return e=r.sent(),[4,e.arrayBuffer()];case 3:return n=r.sent(),this.data=new Uint32Array(n),this.buffer=new J.Rv(n),this.loaded=!0,this.onBlobLoaded(n),this.update(),[2,this]}}))}))},e}(J.qm),jt=function(t){function e(n,r){var i=t.call(this,n,r)||this;return i.format=r.format,i.levels=r.levels||1,i._width=r.width,i._height=r.height,i._extension=e._formatToExtension(i.format),(r.levelBuffers||i.buffer)&&(i._levelBuffers=r.levelBuffers||e._createLevelBuffers(n instanceof Uint8Array?n:i.buffer.uint8View,i.format,i.levels,4,4,i.width,i.height)),i}return Ft(e,t),e.prototype.upload=function(t,e,n){var r=t.gl,i=t.context.extensions[this._extension];if(!i)throw new Error(this._extension+" textures are not supported on the current machine");if(!this._levelBuffers)return!1;for(var o=0,s=this.levels;o<s;o++){var a=this._levelBuffers[o],u=a.levelID,l=a.levelWidth,c=a.levelHeight,h=a.levelBuffer;r.compressedTexImage2D(r.TEXTURE_2D,u,this.format,l,c,0,h)}return!0},e.prototype.onBlobLoaded=function(){this._levelBuffers=e._createLevelBuffers(this.buffer.uint8View,this.format,this.levels,4,4,this.width,this.height)},e._formatToExtension=function(t){if(t>=33776&&t<=33779)return"s3tc";if(t>=37488&&t<=37497)return"etc";if(t>=35840&&t<=35843)return"pvrtc";if(t>=36196)return"etc1";if(t>=35986&&t<=34798)return"atc";throw new Error("Invalid (compressed) texture format given!")},e._createLevelBuffers=function(t,e,n,r,i,o,s){for(var a=new Array(n),u=t.byteOffset,l=o,c=s,h=l+r-1&~(r-1),f=c+i-1&~(i-1),d=h*f*Lt[e],p=0;p<n;p++)a[p]={levelID:p,levelWidth:n>1?l:h,levelHeight:n>1?c:f,levelBuffer:new Uint8Array(t.buffer,u,d)},u+=d,l=l>>1||1,c=c>>1||1,h=l+r-1&~(r-1),f=c+i-1&~(i-1),d=h*f*Lt[e];return a},e}(Ht),Vt=function(){function t(){}return t.use=function(e,n){var r=e.data,i=this;if(e.type===_t.TYPE.JSON&&r&&r.cacheID&&r.textures){for(var o=r.textures,s=void 0,a=void 0,u=0,l=o.length;u<l;u++){var c=o[u],h=c.src,f=c.format;if(f||(a=h),t.textureFormats[f]){s=h;break}}if(s=s||a,!s)return void n(new Error("Cannot load compressed-textures in "+e.url+", make sure you provide a fallback"));if(s===e.url)return void n(new Error("URL of compressed texture cannot be the same as the manifest's URL"));var d={crossOrigin:e.crossOrigin,metadata:e.metadata.imageMetadata,parentResource:e},p=O.HQ.resolve(e.url.replace(i.baseUrl,""),s),m=r.cacheID;i.add(m,p,d,(function(t){if(t.error)n(t.error);else{var r=t.texture,i=void 0===r?null:r,o=t.textures,s=void 0===o?{}:o;Object.assign(e,{texture:i,textures:s}),n()}}))}else n()},t.add=function(){var e=document.createElement("canvas"),n=e.getContext("webgl");if(n){var r={s3tc:n.getExtension("WEBGL_compressed_texture_s3tc"),s3tc_sRGB:n.getExtension("WEBGL_compressed_texture_s3tc_srgb"),etc:n.getExtension("WEBGL_compressed_texture_etc"),etc1:n.getExtension("WEBGL_compressed_texture_etc1"),pvrtc:n.getExtension("WEBGL_compressed_texture_pvrtc")||n.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc"),atc:n.getExtension("WEBGL_compressed_texture_atc"),astc:n.getExtension("WEBGL_compressed_texture_astc")};for(var i in t.textureExtensions=r,t.textureFormats={},r){var o=r[i];o&&Object.assign(t.textureFormats,Object.getPrototypeOf(o))}}else console.warn("WebGL not available for compressed textures. Silently failing.")},t}();function Yt(t,e,n){var r={textures:{},texture:null};if(!e)return r;var i=e.map((function(t){return new J.xE(new J.VL(t,Object.assign({mipmap:Dt.WB.OFF,alphaMode:Dt.iw.NO_PREMULTIPLIED_ALPHA},n)))}));return i.forEach((function(e,n){var i=e.baseTexture,o=t+"-"+(n+1);J.VL.addToCache(i,o),J.xE.addToCache(e,o),0===n&&(J.VL.addToCache(i,t),J.xE.addToCache(e,t),r.texture=e),r.textures[o]=e})),r}_t.setExtensionXhrType("dds",_t.XHR_RESPONSE_TYPE.BUFFER);var Wt,zt,$t=4,qt=124,Kt=32,Zt=20,Jt=542327876,Qt={SIZE:1,FLAGS:2,HEIGHT:3,WIDTH:4,MIPMAP_COUNT:7,PIXEL_FORMAT:19},te={SIZE:0,FLAGS:1,FOURCC:2,RGB_BITCOUNT:3,R_BIT_MASK:4,G_BIT_MASK:5,B_BIT_MASK:6,A_BIT_MASK:7},ee={DXGI_FORMAT:0,RESOURCE_DIMENSION:1,MISC_FLAG:2,ARRAY_SIZE:3,MISC_FLAGS2:4};(function(t){t[t["DXGI_FORMAT_UNKNOWN"]=0]="DXGI_FORMAT_UNKNOWN",t[t["DXGI_FORMAT_R32G32B32A32_TYPELESS"]=1]="DXGI_FORMAT_R32G32B32A32_TYPELESS",t[t["DXGI_FORMAT_R32G32B32A32_FLOAT"]=2]="DXGI_FORMAT_R32G32B32A32_FLOAT",t[t["DXGI_FORMAT_R32G32B32A32_UINT"]=3]="DXGI_FORMAT_R32G32B32A32_UINT",t[t["DXGI_FORMAT_R32G32B32A32_SINT"]=4]="DXGI_FORMAT_R32G32B32A32_SINT",t[t["DXGI_FORMAT_R32G32B32_TYPELESS"]=5]="DXGI_FORMAT_R32G32B32_TYPELESS",t[t["DXGI_FORMAT_R32G32B32_FLOAT"]=6]="DXGI_FORMAT_R32G32B32_FLOAT",t[t["DXGI_FORMAT_R32G32B32_UINT"]=7]="DXGI_FORMAT_R32G32B32_UINT",t[t["DXGI_FORMAT_R32G32B32_SINT"]=8]="DXGI_FORMAT_R32G32B32_SINT",t[t["DXGI_FORMAT_R16G16B16A16_TYPELESS"]=9]="DXGI_FORMAT_R16G16B16A16_TYPELESS",t[t["DXGI_FORMAT_R16G16B16A16_FLOAT"]=10]="DXGI_FORMAT_R16G16B16A16_FLOAT",t[t["DXGI_FORMAT_R16G16B16A16_UNORM"]=11]="DXGI_FORMAT_R16G16B16A16_UNORM",t[t["DXGI_FORMAT_R16G16B16A16_UINT"]=12]="DXGI_FORMAT_R16G16B16A16_UINT",t[t["DXGI_FORMAT_R16G16B16A16_SNORM"]=13]="DXGI_FORMAT_R16G16B16A16_SNORM",t[t["DXGI_FORMAT_R16G16B16A16_SINT"]=14]="DXGI_FORMAT_R16G16B16A16_SINT",t[t["DXGI_FORMAT_R32G32_TYPELESS"]=15]="DXGI_FORMAT_R32G32_TYPELESS",t[t["DXGI_FORMAT_R32G32_FLOAT"]=16]="DXGI_FORMAT_R32G32_FLOAT",t[t["DXGI_FORMAT_R32G32_UINT"]=17]="DXGI_FORMAT_R32G32_UINT",t[t["DXGI_FORMAT_R32G32_SINT"]=18]="DXGI_FORMAT_R32G32_SINT",t[t["DXGI_FORMAT_R32G8X24_TYPELESS"]=19]="DXGI_FORMAT_R32G8X24_TYPELESS",t[t["DXGI_FORMAT_D32_FLOAT_S8X24_UINT"]=20]="DXGI_FORMAT_D32_FLOAT_S8X24_UINT",t[t["DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS"]=21]="DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS",t[t["DXGI_FORMAT_X32_TYPELESS_G8X24_UINT"]=22]="DXGI_FORMAT_X32_TYPELESS_G8X24_UINT",t[t["DXGI_FORMAT_R10G10B10A2_TYPELESS"]=23]="DXGI_FORMAT_R10G10B10A2_TYPELESS",t[t["DXGI_FORMAT_R10G10B10A2_UNORM"]=24]="DXGI_FORMAT_R10G10B10A2_UNORM",t[t["DXGI_FORMAT_R10G10B10A2_UINT"]=25]="DXGI_FORMAT_R10G10B10A2_UINT",t[t["DXGI_FORMAT_R11G11B10_FLOAT"]=26]="DXGI_FORMAT_R11G11B10_FLOAT",t[t["DXGI_FORMAT_R8G8B8A8_TYPELESS"]=27]="DXGI_FORMAT_R8G8B8A8_TYPELESS",t[t["DXGI_FORMAT_R8G8B8A8_UNORM"]=28]="DXGI_FORMAT_R8G8B8A8_UNORM",t[t["DXGI_FORMAT_R8G8B8A8_UNORM_SRGB"]=29]="DXGI_FORMAT_R8G8B8A8_UNORM_SRGB",t[t["DXGI_FORMAT_R8G8B8A8_UINT"]=30]="DXGI_FORMAT_R8G8B8A8_UINT",t[t["DXGI_FORMAT_R8G8B8A8_SNORM"]=31]="DXGI_FORMAT_R8G8B8A8_SNORM",t[t["DXGI_FORMAT_R8G8B8A8_SINT"]=32]="DXGI_FORMAT_R8G8B8A8_SINT",t[t["DXGI_FORMAT_R16G16_TYPELESS"]=33]="DXGI_FORMAT_R16G16_TYPELESS",t[t["DXGI_FORMAT_R16G16_FLOAT"]=34]="DXGI_FORMAT_R16G16_FLOAT",t[t["DXGI_FORMAT_R16G16_UNORM"]=35]="DXGI_FORMAT_R16G16_UNORM",t[t["DXGI_FORMAT_R16G16_UINT"]=36]="DXGI_FORMAT_R16G16_UINT",t[t["DXGI_FORMAT_R16G16_SNORM"]=37]="DXGI_FORMAT_R16G16_SNORM",t[t["DXGI_FORMAT_R16G16_SINT"]=38]="DXGI_FORMAT_R16G16_SINT",t[t["DXGI_FORMAT_R32_TYPELESS"]=39]="DXGI_FORMAT_R32_TYPELESS",t[t["DXGI_FORMAT_D32_FLOAT"]=40]="DXGI_FORMAT_D32_FLOAT",t[t["DXGI_FORMAT_R32_FLOAT"]=41]="DXGI_FORMAT_R32_FLOAT",t[t["DXGI_FORMAT_R32_UINT"]=42]="DXGI_FORMAT_R32_UINT",t[t["DXGI_FORMAT_R32_SINT"]=43]="DXGI_FORMAT_R32_SINT",t[t["DXGI_FORMAT_R24G8_TYPELESS"]=44]="DXGI_FORMAT_R24G8_TYPELESS",t[t["DXGI_FORMAT_D24_UNORM_S8_UINT"]=45]="DXGI_FORMAT_D24_UNORM_S8_UINT",t[t["DXGI_FORMAT_R24_UNORM_X8_TYPELESS"]=46]="DXGI_FORMAT_R24_UNORM_X8_TYPELESS",t[t["DXGI_FORMAT_X24_TYPELESS_G8_UINT"]=47]="DXGI_FORMAT_X24_TYPELESS_G8_UINT",t[t["DXGI_FORMAT_R8G8_TYPELESS"]=48]="DXGI_FORMAT_R8G8_TYPELESS",t[t["DXGI_FORMAT_R8G8_UNORM"]=49]="DXGI_FORMAT_R8G8_UNORM",t[t["DXGI_FORMAT_R8G8_UINT"]=50]="DXGI_FORMAT_R8G8_UINT",t[t["DXGI_FORMAT_R8G8_SNORM"]=51]="DXGI_FORMAT_R8G8_SNORM",t[t["DXGI_FORMAT_R8G8_SINT"]=52]="DXGI_FORMAT_R8G8_SINT",t[t["DXGI_FORMAT_R16_TYPELESS"]=53]="DXGI_FORMAT_R16_TYPELESS",t[t["DXGI_FORMAT_R16_FLOAT"]=54]="DXGI_FORMAT_R16_FLOAT",t[t["DXGI_FORMAT_D16_UNORM"]=55]="DXGI_FORMAT_D16_UNORM",t[t["DXGI_FORMAT_R16_UNORM"]=56]="DXGI_FORMAT_R16_UNORM",t[t["DXGI_FORMAT_R16_UINT"]=57]="DXGI_FORMAT_R16_UINT",t[t["DXGI_FORMAT_R16_SNORM"]=58]="DXGI_FORMAT_R16_SNORM",t[t["DXGI_FORMAT_R16_SINT"]=59]="DXGI_FORMAT_R16_SINT",t[t["DXGI_FORMAT_R8_TYPELESS"]=60]="DXGI_FORMAT_R8_TYPELESS",t[t["DXGI_FORMAT_R8_UNORM"]=61]="DXGI_FORMAT_R8_UNORM",t[t["DXGI_FORMAT_R8_UINT"]=62]="DXGI_FORMAT_R8_UINT",t[t["DXGI_FORMAT_R8_SNORM"]=63]="DXGI_FORMAT_R8_SNORM",t[t["DXGI_FORMAT_R8_SINT"]=64]="DXGI_FORMAT_R8_SINT",t[t["DXGI_FORMAT_A8_UNORM"]=65]="DXGI_FORMAT_A8_UNORM",t[t["DXGI_FORMAT_R1_UNORM"]=66]="DXGI_FORMAT_R1_UNORM",t[t["DXGI_FORMAT_R9G9B9E5_SHAREDEXP"]=67]="DXGI_FORMAT_R9G9B9E5_SHAREDEXP",t[t["DXGI_FORMAT_R8G8_B8G8_UNORM"]=68]="DXGI_FORMAT_R8G8_B8G8_UNORM",t[t["DXGI_FORMAT_G8R8_G8B8_UNORM"]=69]="DXGI_FORMAT_G8R8_G8B8_UNORM",t[t["DXGI_FORMAT_BC1_TYPELESS"]=70]="DXGI_FORMAT_BC1_TYPELESS",t[t["DXGI_FORMAT_BC1_UNORM"]=71]="DXGI_FORMAT_BC1_UNORM",t[t["DXGI_FORMAT_BC1_UNORM_SRGB"]=72]="DXGI_FORMAT_BC1_UNORM_SRGB",t[t["DXGI_FORMAT_BC2_TYPELESS"]=73]="DXGI_FORMAT_BC2_TYPELESS",t[t["DXGI_FORMAT_BC2_UNORM"]=74]="DXGI_FORMAT_BC2_UNORM",t[t["DXGI_FORMAT_BC2_UNORM_SRGB"]=75]="DXGI_FORMAT_BC2_UNORM_SRGB",t[t["DXGI_FORMAT_BC3_TYPELESS"]=76]="DXGI_FORMAT_BC3_TYPELESS",t[t["DXGI_FORMAT_BC3_UNORM"]=77]="DXGI_FORMAT_BC3_UNORM",t[t["DXGI_FORMAT_BC3_UNORM_SRGB"]=78]="DXGI_FORMAT_BC3_UNORM_SRGB",t[t["DXGI_FORMAT_BC4_TYPELESS"]=79]="DXGI_FORMAT_BC4_TYPELESS",t[t["DXGI_FORMAT_BC4_UNORM"]=80]="DXGI_FORMAT_BC4_UNORM",t[t["DXGI_FORMAT_BC4_SNORM"]=81]="DXGI_FORMAT_BC4_SNORM",t[t["DXGI_FORMAT_BC5_TYPELESS"]=82]="DXGI_FORMAT_BC5_TYPELESS",t[t["DXGI_FORMAT_BC5_UNORM"]=83]="DXGI_FORMAT_BC5_UNORM",t[t["DXGI_FORMAT_BC5_SNORM"]=84]="DXGI_FORMAT_BC5_SNORM",t[t["DXGI_FORMAT_B5G6R5_UNORM"]=85]="DXGI_FORMAT_B5G6R5_UNORM",t[t["DXGI_FORMAT_B5G5R5A1_UNORM"]=86]="DXGI_FORMAT_B5G5R5A1_UNORM",t[t["DXGI_FORMAT_B8G8R8A8_UNORM"]=87]="DXGI_FORMAT_B8G8R8A8_UNORM",t[t["DXGI_FORMAT_B8G8R8X8_UNORM"]=88]="DXGI_FORMAT_B8G8R8X8_UNORM",t[t["DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM"]=89]="DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM",t[t["DXGI_FORMAT_B8G8R8A8_TYPELESS"]=90]="DXGI_FORMAT_B8G8R8A8_TYPELESS",t[t["DXGI_FORMAT_B8G8R8A8_UNORM_SRGB"]=91]="DXGI_FORMAT_B8G8R8A8_UNORM_SRGB",t[t["DXGI_FORMAT_B8G8R8X8_TYPELESS"]=92]="DXGI_FORMAT_B8G8R8X8_TYPELESS",t[t["DXGI_FORMAT_B8G8R8X8_UNORM_SRGB"]=93]="DXGI_FORMAT_B8G8R8X8_UNORM_SRGB",t[t["DXGI_FORMAT_BC6H_TYPELESS"]=94]="DXGI_FORMAT_BC6H_TYPELESS",t[t["DXGI_FORMAT_BC6H_UF16"]=95]="DXGI_FORMAT_BC6H_UF16",t[t["DXGI_FORMAT_BC6H_SF16"]=96]="DXGI_FORMAT_BC6H_SF16",t[t["DXGI_FORMAT_BC7_TYPELESS"]=97]="DXGI_FORMAT_BC7_TYPELESS",t[t["DXGI_FORMAT_BC7_UNORM"]=98]="DXGI_FORMAT_BC7_UNORM",t[t["DXGI_FORMAT_BC7_UNORM_SRGB"]=99]="DXGI_FORMAT_BC7_UNORM_SRGB",t[t["DXGI_FORMAT_AYUV"]=100]="DXGI_FORMAT_AYUV",t[t["DXGI_FORMAT_Y410"]=101]="DXGI_FORMAT_Y410",t[t["DXGI_FORMAT_Y416"]=102]="DXGI_FORMAT_Y416",t[t["DXGI_FORMAT_NV12"]=103]="DXGI_FORMAT_NV12",t[t["DXGI_FORMAT_P010"]=104]="DXGI_FORMAT_P010",t[t["DXGI_FORMAT_P016"]=105]="DXGI_FORMAT_P016",t[t["DXGI_FORMAT_420_OPAQUE"]=106]="DXGI_FORMAT_420_OPAQUE",t[t["DXGI_FORMAT_YUY2"]=107]="DXGI_FORMAT_YUY2",t[t["DXGI_FORMAT_Y210"]=108]="DXGI_FORMAT_Y210",t[t["DXGI_FORMAT_Y216"]=109]="DXGI_FORMAT_Y216",t[t["DXGI_FORMAT_NV11"]=110]="DXGI_FORMAT_NV11",t[t["DXGI_FORMAT_AI44"]=111]="DXGI_FORMAT_AI44",t[t["DXGI_FORMAT_IA44"]=112]="DXGI_FORMAT_IA44",t[t["DXGI_FORMAT_P8"]=113]="DXGI_FORMAT_P8",t[t["DXGI_FORMAT_A8P8"]=114]="DXGI_FORMAT_A8P8",t[t["DXGI_FORMAT_B4G4R4A4_UNORM"]=115]="DXGI_FORMAT_B4G4R4A4_UNORM",t[t["DXGI_FORMAT_P208"]=116]="DXGI_FORMAT_P208",t[t["DXGI_FORMAT_V208"]=117]="DXGI_FORMAT_V208",t[t["DXGI_FORMAT_V408"]=118]="DXGI_FORMAT_V408",t[t["DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE"]=119]="DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE",t[t["DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE"]=120]="DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE",t[t["DXGI_FORMAT_FORCE_UINT"]=121]="DXGI_FORMAT_FORCE_UINT"})(Wt||(Wt={})),function(t){t[t["DDS_DIMENSION_TEXTURE1D"]=2]="DDS_DIMENSION_TEXTURE1D",t[t["DDS_DIMENSION_TEXTURE2D"]=3]="DDS_DIMENSION_TEXTURE2D",t[t["DDS_DIMENSION_TEXTURE3D"]=6]="DDS_DIMENSION_TEXTURE3D"}(zt||(zt={}));var ne,re,ie,oe=1,se=2,ae=4,ue=64,le=512,ce=131072,he=827611204,fe=861165636,de=894720068,pe=808540228,me=4,ve=(kt={},kt[he]=Mt.COMPRESSED_RGBA_S3TC_DXT1_EXT,kt[fe]=Mt.COMPRESSED_RGBA_S3TC_DXT3_EXT,kt[de]=Mt.COMPRESSED_RGBA_S3TC_DXT5_EXT,kt),ge=(Xt={},Xt[Wt.DXGI_FORMAT_BC1_TYPELESS]=Mt.COMPRESSED_RGBA_S3TC_DXT1_EXT,Xt[Wt.DXGI_FORMAT_BC1_UNORM]=Mt.COMPRESSED_RGBA_S3TC_DXT1_EXT,Xt[Wt.DXGI_FORMAT_BC2_TYPELESS]=Mt.COMPRESSED_RGBA_S3TC_DXT3_EXT,Xt[Wt.DXGI_FORMAT_BC2_UNORM]=Mt.COMPRESSED_RGBA_S3TC_DXT3_EXT,Xt[Wt.DXGI_FORMAT_BC3_TYPELESS]=Mt.COMPRESSED_RGBA_S3TC_DXT5_EXT,Xt[Wt.DXGI_FORMAT_BC3_UNORM]=Mt.COMPRESSED_RGBA_S3TC_DXT5_EXT,Xt[Wt.DXGI_FORMAT_BC1_UNORM_SRGB]=Mt.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT,Xt[Wt.DXGI_FORMAT_BC2_UNORM_SRGB]=Mt.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT,Xt[Wt.DXGI_FORMAT_BC3_UNORM_SRGB]=Mt.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT,Xt),_e=function(){function t(){}return t.use=function(e,n){if("dds"===e.extension&&e.data)try{Object.assign(e,Yt(e.name||e.url,t.parse(e.data),e.metadata))}catch(r){return void n(r)}n()},t.parse=function(t){var e=new Uint32Array(t),n=e[0];if(n!==Jt)throw new Error("Invalid DDS file magic word");var r=new Uint32Array(t,0,qt/Uint32Array.BYTES_PER_ELEMENT),i=r[Qt.HEIGHT],o=r[Qt.WIDTH],s=r[Qt.MIPMAP_COUNT],a=new Uint32Array(t,Qt.PIXEL_FORMAT*Uint32Array.BYTES_PER_ELEMENT,Kt/Uint32Array.BYTES_PER_ELEMENT),u=a[oe];if(u&ae){var l=a[te.FOURCC];if(l!==pe){var c=ve[l],h=$t+qt,f=new Uint8Array(t,h),d=new jt(f,{format:c,width:o,height:i,levels:s});return[d]}var p=$t+qt,m=new Uint32Array(e.buffer,p,Zt/Uint32Array.BYTES_PER_ELEMENT),v=m[ee.DXGI_FORMAT],g=m[ee.RESOURCE_DIMENSION],_=m[ee.MISC_FLAG],y=m[ee.ARRAY_SIZE],b=ge[v];if(void 0===b)throw new Error("DDSLoader cannot parse texture data with DXGI format "+v);if(_===me)throw new Error("DDSLoader does not support cubemap textures");if(g===zt.DDS_DIMENSION_TEXTURE3D)throw new Error("DDSLoader does not supported 3D texture data");var E=new Array,T=$t+qt+Zt;if(1===y)E.push(new Uint8Array(t,T));else{for(var x=Lt[b],S=0,R=o,A=i,O=0;O<s;O++){var I=Math.max(1,R+3&-4),w=Math.max(1,A+3&-4),C=I*w*x;S+=C,R>>>=1,A>>>=1}var P=T;for(O=0;O<y;O++)E.push(new Uint8Array(t,P,S)),P+=S}return E.map((function(t){return new jt(t,{format:b,width:o,height:i,levels:s})}))}if(u&ue)throw new Error("DDSLoader does not support uncompressed texture data.");if(u&le)throw new Error("DDSLoader does not supported YUV uncompressed texture data.");if(u&ce)throw new Error("DDSLoader does not support single-channel (lumninance) texture data!");if(u&se)throw new Error("DDSLoader does not support single-channel (alpha) texture data!");throw new Error("DDSLoader failed to load a texture file due to an unknown reason!")},t}();_t.setExtensionXhrType("ktx",_t.XHR_RESPONSE_TYPE.BUFFER);var ye=[171,75,84,88,32,49,49,187,13,10,26,10],be=67305985,Ee={FILE_IDENTIFIER:0,ENDIANNESS:12,GL_TYPE:16,GL_TYPE_SIZE:20,GL_FORMAT:24,GL_INTERNAL_FORMAT:28,GL_BASE_INTERNAL_FORMAT:32,PIXEL_WIDTH:36,PIXEL_HEIGHT:40,PIXEL_DEPTH:44,NUMBER_OF_ARRAY_ELEMENTS:48,NUMBER_OF_FACES:52,NUMBER_OF_MIPMAP_LEVELS:56,BYTES_OF_KEY_VALUE_DATA:60},Te=64,xe=(ne={},ne[Dt.vK.UNSIGNED_BYTE]=1,ne[Dt.vK.UNSIGNED_SHORT]=2,ne[Dt.vK.INT]=4,ne[Dt.vK.UNSIGNED_INT]=4,ne[Dt.vK.FLOAT]=4,ne[Dt.vK.HALF_FLOAT]=8,ne),Se=(re={},re[Dt.I2.RGBA]=4,re[Dt.I2.RGB]=3,re[Dt.I2.RG]=2,re[Dt.I2.RED]=1,re[Dt.I2.LUMINANCE]=1,re[Dt.I2.LUMINANCE_ALPHA]=2,re[Dt.I2.ALPHA]=1,re),Re=(ie={},ie[Dt.vK.UNSIGNED_SHORT_4_4_4_4]=2,ie[Dt.vK.UNSIGNED_SHORT_5_5_5_1]=2,ie[Dt.vK.UNSIGNED_SHORT_5_6_5]=2,ie),Ae=function(){function t(){}return t.use=function(e,n){if("ktx"===e.extension&&e.data)try{var r=e.name||e.url,i=t.parse(r,e.data),o=i.compressed,s=i.uncompressed;if(o)Object.assign(e,Yt(r,o,e.metadata));else if(s){var a={};s.forEach((function(t,e){var n=new J.xE(new J.VL(t.resource,{mipmap:Dt.WB.OFF,alphaMode:Dt.iw.NO_PREMULTIPLIED_ALPHA,type:t.type,format:t.format})),i=r+"-"+(e+1);J.VL.addToCache(n.baseTexture,i),J.xE.addToCache(n,i),0===e&&(a[r]=n,J.VL.addToCache(n.baseTexture,r),J.xE.addToCache(n,r)),a[i]=n})),Object.assign(e,{textures:a})}}catch(u){return void n(u)}n()},t.parse=function(e,n){var r=new DataView(n);if(!t.validate(e,r))return null;var i=r.getUint32(Ee.ENDIANNESS,!0)===be,o=r.getUint32(Ee.GL_TYPE,i),s=r.getUint32(Ee.GL_FORMAT,i),a=r.getUint32(Ee.GL_INTERNAL_FORMAT,i),u=r.getUint32(Ee.PIXEL_WIDTH,i),l=r.getUint32(Ee.PIXEL_HEIGHT,i)||1,c=r.getUint32(Ee.PIXEL_DEPTH,i)||1,h=r.getUint32(Ee.NUMBER_OF_ARRAY_ELEMENTS,i)||1,f=r.getUint32(Ee.NUMBER_OF_FACES,i),d=r.getUint32(Ee.NUMBER_OF_MIPMAP_LEVELS,i),p=r.getUint32(Ee.BYTES_OF_KEY_VALUE_DATA,i);if(0===l||1!==c)throw new Error("Only 2D textures are supported");if(1!==f)throw new Error("CubeTextures are not supported by KTXLoader yet!");if(1!==h)throw new Error("WebGL does not support array textures");var m,v=4,g=4,_=u+3&-4,y=l+3&-4,b=new Array(h),E=u*l;if(0===o&&(E=_*y),m=0!==o?xe[o]?xe[o]*Se[s]:Re[o]:Lt[a],void 0===m)throw new Error("Unable to resolve the pixel format stored in the *.ktx file!");for(var T=E*m,x=T,S=u,R=l,A=_,O=y,I=Te+p,w=0;w<d;w++){for(var C=r.getUint32(I,i),P=I+4,N=0;N<h;N++){var M=b[N];M||(M=b[N]=new Array(d)),M[w]={levelID:w,levelWidth:d>1||0!==o?S:A,levelHeight:d>1||0!==o?R:O,levelBuffer:new Uint8Array(n,P,x)},P+=x}I+=C+4,I=I%4!==0?I+4-I%4:I,S=S>>1||1,R=R>>1||1,A=S+v-1&~(v-1),O=R+g-1&~(g-1),x=A*O*m}return 0!==o?{uncompressed:b.map((function(e){var n=e[0].levelBuffer,r=!1;return o===Dt.vK.FLOAT?n=new Float32Array(e[0].levelBuffer.buffer,e[0].levelBuffer.byteOffset,e[0].levelBuffer.byteLength/4):o===Dt.vK.UNSIGNED_INT?(r=!0,n=new Uint32Array(e[0].levelBuffer.buffer,e[0].levelBuffer.byteOffset,e[0].levelBuffer.byteLength/4)):o===Dt.vK.INT&&(r=!0,n=new Int32Array(e[0].levelBuffer.buffer,e[0].levelBuffer.byteOffset,e[0].levelBuffer.byteLength/4)),{resource:new J.qm(n,{width:e[0].levelWidth,height:e[0].levelHeight}),type:o,format:r?t.convertFormatToInteger(s):s}}))}:{compressed:b.map((function(t){return new jt(null,{format:a,width:u,height:l,levels:d,levelBuffers:t})}))}},t.validate=function(t,e){for(var n=0;n<ye.length;n++)if(e.getUint8(n)!==ye[n])return console.error(t+" is not a valid *.ktx file!"),!1;return!0},t.convertFormatToInteger=function(t){switch(t){case Dt.I2.RGBA:return Dt.I2.RGBA_INTEGER;case Dt.I2.RGB:return Dt.I2.RGB_INTEGER;case Dt.I2.RG:return Dt.I2.RG_INTEGER;case Dt.I2.RED:return Dt.I2.RED_INTEGER;default:return t}},t}(),Oe=function(t,e){return Oe=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Oe(t,e)};function Ie(t,e){function n(){this.constructor=t}Oe(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}(function(t){function e(e,n,r,i){void 0===e&&(e=1500),void 0===r&&(r=16384),void 0===i&&(i=!1);var o=t.call(this)||this,s=16384;return r>s&&(r=s),o._properties=[!1,!0,!1,!1,!1],o._maxSize=e,o._batchSize=r,o._buffers=null,o._bufferUpdateIDs=[],o._updateID=0,o.interactiveChildren=!1,o.blendMode=Dt.T$.NORMAL,o.autoResize=i,o.roundPixels=!0,o.baseTexture=null,o.setProperties(n),o._tint=0,o.tintRgb=new Float32Array(4),o.tint=16777215,o}Ie(e,t),e.prototype.setProperties=function(t){t&&(this._properties[0]="vertices"in t||"scale"in t?!!t.vertices||!!t.scale:this._properties[0],this._properties[1]="position"in t?!!t.position:this._properties[1],this._properties[2]="rotation"in t?!!t.rotation:this._properties[2],this._properties[3]="uvs"in t?!!t.uvs:this._properties[3],this._properties[4]="tint"in t||"alpha"in t?!!t.tint||!!t.alpha:this._properties[4])},e.prototype.updateTransform=function(){this.displayObjectUpdateTransform()},Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){this._tint=t,(0,O.wK)(t,this.tintRgb)},enumerable:!1,configurable:!0}),e.prototype.render=function(t){var e=this;this.visible&&!(this.worldAlpha<=0)&&this.children.length&&this.renderable&&(this.baseTexture||(this.baseTexture=this.children[0]._texture.baseTexture,this.baseTexture.valid||this.baseTexture.once("update",(function(){return e.onChildrenChange(0)}))),t.batch.setObjectRenderer(t.plugins.particle),t.plugins.particle.render(this))},e.prototype.onChildrenChange=function(t){var e=Math.floor(t/this._batchSize);while(this._bufferUpdateIDs.length<e)this._bufferUpdateIDs.push(0);this._bufferUpdateIDs[e]=++this._updateID},e.prototype.dispose=function(){if(this._buffers){for(var t=0;t<this._buffers.length;++t)this._buffers[t].destroy();this._buffers=null}},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this.dispose(),this._properties=null,this._buffers=null,this._bufferUpdateIDs=null}})(I.W2);var we,Ce,Pe=function(){function t(t,e,n){this.geometry=new J.ZX,this.indexBuffer=null,this.size=n,this.dynamicProperties=[],this.staticProperties=[];for(var r=0;r<t.length;++r){var i=t[r];i={attributeName:i.attributeName,size:i.size,uploadFunction:i.uploadFunction,type:i.type||Dt.vK.FLOAT,offset:i.offset},e[r]?this.dynamicProperties.push(i):this.staticProperties.push(i)}this.staticStride=0,this.staticBuffer=null,this.staticData=null,this.staticDataUint32=null,this.dynamicStride=0,this.dynamicBuffer=null,this.dynamicData=null,this.dynamicDataUint32=null,this._updateID=0,this.initBuffers()}return t.prototype.initBuffers=function(){var t=this.geometry,e=0;this.indexBuffer=new J.lW((0,O.fl)(this.size),!0,!0),t.addIndex(this.indexBuffer),this.dynamicStride=0;for(var n=0;n<this.dynamicProperties.length;++n){var r=this.dynamicProperties[n];r.offset=e,e+=r.size,this.dynamicStride+=r.size}var i=new ArrayBuffer(this.size*this.dynamicStride*4*4);this.dynamicData=new Float32Array(i),this.dynamicDataUint32=new Uint32Array(i),this.dynamicBuffer=new J.lW(this.dynamicData,!1,!1);var o=0;this.staticStride=0;for(n=0;n<this.staticProperties.length;++n){r=this.staticProperties[n];r.offset=o,o+=r.size,this.staticStride+=r.size}var s=new ArrayBuffer(this.size*this.staticStride*4*4);this.staticData=new Float32Array(s),this.staticDataUint32=new Uint32Array(s),this.staticBuffer=new J.lW(this.staticData,!0,!1);for(n=0;n<this.dynamicProperties.length;++n){r=this.dynamicProperties[n];t.addAttribute(r.attributeName,this.dynamicBuffer,0,r.type===Dt.vK.UNSIGNED_BYTE,r.type,4*this.dynamicStride,4*r.offset)}for(n=0;n<this.staticProperties.length;++n){r=this.staticProperties[n];t.addAttribute(r.attributeName,this.staticBuffer,0,r.type===Dt.vK.UNSIGNED_BYTE,r.type,4*this.staticStride,4*r.offset)}},t.prototype.uploadDynamic=function(t,e,n){for(var r=0;r<this.dynamicProperties.length;r++){var i=this.dynamicProperties[r];i.uploadFunction(t,e,n,i.type===Dt.vK.UNSIGNED_BYTE?this.dynamicDataUint32:this.dynamicData,this.dynamicStride,i.offset)}this.dynamicBuffer._updateID++},t.prototype.uploadStatic=function(t,e,n){for(var r=0;r<this.staticProperties.length;r++){var i=this.staticProperties[r];i.uploadFunction(t,e,n,i.type===Dt.vK.UNSIGNED_BYTE?this.staticDataUint32:this.staticData,this.staticStride,i.offset)}this.staticBuffer._updateID++},t.prototype.destroy=function(){this.indexBuffer=null,this.dynamicProperties=null,this.dynamicBuffer=null,this.dynamicData=null,this.dynamicDataUint32=null,this.staticProperties=null,this.staticBuffer=null,this.staticData=null,this.staticDataUint32=null,this.geometry.destroy()},t}(),Ne="varying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nuniform sampler2D uSampler;\n\nvoid main(void){\n vec4 color = texture2D(uSampler, vTextureCoord) * vColor;\n gl_FragColor = color;\n}",Me="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\nattribute vec4 aColor;\n\nattribute vec2 aPositionCoord;\nattribute float aRotation;\n\nuniform mat3 translationMatrix;\nuniform vec4 uColor;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nvoid main(void){\n float x = (aVertexPosition.x) * cos(aRotation) - (aVertexPosition.y) * sin(aRotation);\n float y = (aVertexPosition.x) * sin(aRotation) + (aVertexPosition.y) * cos(aRotation);\n\n vec2 v = vec2(x, y);\n v = v + aPositionCoord;\n\n gl_Position = vec4((translationMatrix * vec3(v, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vColor = aColor * uColor;\n}\n",De=function(t){function e(e){var n=t.call(this,e)||this;return n.shader=null,n.properties=null,n.tempMatrix=new k.y3,n.properties=[{attributeName:"aVertexPosition",size:2,uploadFunction:n.uploadVertices,offset:0},{attributeName:"aPositionCoord",size:2,uploadFunction:n.uploadPosition,offset:0},{attributeName:"aRotation",size:1,uploadFunction:n.uploadRotation,offset:0},{attributeName:"aTextureCoord",size:2,uploadFunction:n.uploadUvs,offset:0},{attributeName:"aColor",size:1,type:Dt.vK.UNSIGNED_BYTE,uploadFunction:n.uploadTint,offset:0}],n.shader=J.ex.from(Me,Ne,{}),n.state=J.ZM.for2d(),n}return Ie(e,t),e.prototype.render=function(t){var e=t.children,n=t._maxSize,r=t._batchSize,i=this.renderer,o=e.length;if(0!==o){o>n&&!t.autoResize&&(o=n);var s=t._buffers;s||(s=t._buffers=this.generateBuffers(t));var a=e[0]._texture.baseTexture;this.state.blendMode=(0,O.D)(t.blendMode,a.alphaMode),i.state.set(this.state);var u=i.gl,l=t.worldTransform.copyTo(this.tempMatrix);l.prepend(i.globalUniforms.uniforms.projectionMatrix),this.shader.uniforms.translationMatrix=l.toArray(!0),this.shader.uniforms.uColor=(0,O.Qt)(t.tintRgb,t.worldAlpha,this.shader.uniforms.uColor,a.alphaMode),this.shader.uniforms.uSampler=a,this.renderer.shader.bind(this.shader);for(var c=!1,h=0,f=0;h<o;h+=r,f+=1){var d=o-h;d>r&&(d=r),f>=s.length&&s.push(this._generateOneMoreBuffer(t));var p=s[f];p.uploadDynamic(e,h,d);var m=t._bufferUpdateIDs[f]||0;c=c||p._updateID<m,c&&(p._updateID=t._updateID,p.uploadStatic(e,h,d)),i.geometry.bind(p.geometry),u.drawElements(u.TRIANGLES,6*d,u.UNSIGNED_SHORT,0)}}},e.prototype.generateBuffers=function(t){for(var e=[],n=t._maxSize,r=t._batchSize,i=t._properties,o=0;o<n;o+=r)e.push(new Pe(this.properties,i,r));return e},e.prototype._generateOneMoreBuffer=function(t){var e=t._batchSize,n=t._properties;return new Pe(this.properties,n,e)},e.prototype.uploadVertices=function(t,e,n,r,i,o){for(var s=0,a=0,u=0,l=0,c=0;c<n;++c){var h=t[e+c],f=h._texture,d=h.scale.x,p=h.scale.y,m=f.trim,v=f.orig;m?(a=m.x-h.anchor.x*v.width,s=a+m.width,l=m.y-h.anchor.y*v.height,u=l+m.height):(s=v.width*(1-h.anchor.x),a=v.width*-h.anchor.x,u=v.height*(1-h.anchor.y),l=v.height*-h.anchor.y),r[o]=a*d,r[o+1]=l*p,r[o+i]=s*d,r[o+i+1]=l*p,r[o+2*i]=s*d,r[o+2*i+1]=u*p,r[o+3*i]=a*d,r[o+3*i+1]=u*p,o+=4*i}},e.prototype.uploadPosition=function(t,e,n,r,i,o){for(var s=0;s<n;s++){var a=t[e+s].position;r[o]=a.x,r[o+1]=a.y,r[o+i]=a.x,r[o+i+1]=a.y,r[o+2*i]=a.x,r[o+2*i+1]=a.y,r[o+3*i]=a.x,r[o+3*i+1]=a.y,o+=4*i}},e.prototype.uploadRotation=function(t,e,n,r,i,o){for(var s=0;s<n;s++){var a=t[e+s].rotation;r[o]=a,r[o+i]=a,r[o+2*i]=a,r[o+3*i]=a,o+=4*i}},e.prototype.uploadUvs=function(t,e,n,r,i,o){for(var s=0;s<n;++s){var a=t[e+s]._texture._uvs;a?(r[o]=a.x0,r[o+1]=a.y0,r[o+i]=a.x1,r[o+i+1]=a.y1,r[o+2*i]=a.x2,r[o+2*i+1]=a.y2,r[o+3*i]=a.x3,r[o+3*i+1]=a.y3,o+=4*i):(r[o]=0,r[o+1]=0,r[o+i]=0,r[o+i+1]=0,r[o+2*i]=0,r[o+2*i+1]=0,r[o+3*i]=0,r[o+3*i+1]=0,o+=4*i)}},e.prototype.uploadTint=function(t,e,n,r,i,o){for(var s=0;s<n;++s){var a=t[e+s],u=a._texture.baseTexture.alphaMode>0,l=a.alpha,c=l<1&&u?(0,O.rA)(a._tintRGB,l):a._tintRGB+(255*l<<24);r[o]=c,r[o+i]=c,r[o+2*i]=c,r[o+3*i]=c,o+=4*i}},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.shader&&(this.shader.destroy(),this.shader=null),this.tempMatrix=null},e}(J.bO),Le=n(1576);(function(t){t["MITER"]="miter",t["BEVEL"]="bevel",t["ROUND"]="round"})(we||(we={})),function(t){t["BUTT"]="butt",t["ROUND"]="round",t["SQUARE"]="square"}(Ce||(Ce={}));var Be={adaptive:!0,maxLength:10,minSegments:8,maxSegments:2048,epsilon:1e-4,_segmentsCount:function(t,e){if(void 0===e&&(e=20),!this.adaptive||!t||isNaN(t))return e;var n=Math.ceil(t/this.maxLength);return n<this.minSegments?n=this.minSegments:n>this.maxSegments&&(n=this.maxSegments),n}},Fe=function(){function t(){this.color=16777215,this.alpha=1,this.texture=J.xE.WHITE,this.matrix=null,this.visible=!1,this.reset()}return t.prototype.clone=function(){var e=new t;return e.color=this.color,e.alpha=this.alpha,e.texture=this.texture,e.matrix=this.matrix,e.visible=this.visible,e},t.prototype.reset=function(){this.color=16777215,this.alpha=1,this.texture=J.xE.WHITE,this.matrix=null,this.visible=!1},t.prototype.destroy=function(){this.texture=null,this.matrix=null},t}(),Ue=function(t,e){return Ue=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Ue(t,e)};function Ge(t,e){function n(){this.constructor=t}Ue(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function ke(t,e){var n,r;void 0===e&&(e=!1);var i=t.length;if(!(i<6)){for(var o=0,s=0,a=t[i-2],u=t[i-1];s<i;s+=2){var l=t[s],c=t[s+1];o+=(l-a)*(c+u),a=l,u=c}if(!e&&o>0||e&&o<=0){var h=i/2;for(s=h+h%2;s<i;s+=2){var f=i-s-2,d=i-s-1,p=s,m=s+1;n=[t[p],t[f]],t[f]=n[0],t[p]=n[1],r=[t[m],t[d]],t[d]=r[0],t[m]=r[1]}}}}var Xe={build:function(t){t.points=t.shape.points.slice()},triangulate:function(t,e){var n=t.points,r=t.holes,i=e.points,o=e.indices;if(n.length>=6){ke(n,!1);for(var s=[],a=0;a<r.length;a++){var u=r[a];ke(u.points,!0),s.push(n.length/2),n=n.concat(u.points)}var l=(0,O.OT)(n,s,2);if(!l)return;var c=i.length/2;for(a=0;a<l.length;a+=3)o.push(l[a]+c),o.push(l[a+1]+c),o.push(l[a+2]+c);for(a=0;a<n.length;a++)i.push(n[a])}}},He={build:function(t){var e,n,r,i,o,s,a=t.points;if(t.type===k.HS.CIRC){var u=t.shape;e=u.x,n=u.y,o=s=u.radius,r=i=0}else if(t.type===k.HS.ELIP){var l=t.shape;e=l.x,n=l.y,o=l.width,s=l.height,r=i=0}else{var c=t.shape,h=c.width/2,f=c.height/2;e=c.x+h,n=c.y+f,o=s=Math.max(0,Math.min(c.radius,Math.min(h,f))),r=h-o,i=f-s}var d=Math.ceil(2.3*Math.sqrt(o+s)),p=8*d+(r?4:0)+(i?4:0);if(a.length=p,0!==p){if(0===d)return a.length=8,a[0]=a[6]=e+r,a[1]=a[3]=n+i,a[2]=a[4]=e-r,void(a[5]=a[7]=n-i);var m=0,v=4*d+(r?2:0)+2,g=v,_=p,y=r+o,b=i,E=e+y,T=e-y,x=n+b;if(a[m++]=E,a[m++]=x,a[--v]=x,a[--v]=T,i){var S=n-b;a[g++]=T,a[g++]=S,a[--_]=S,a[--_]=E}for(var R=1;R<d;R++){var A=Math.PI/2*(R/d);y=r+Math.cos(A)*o,b=i+Math.sin(A)*s,E=e+y,T=e-y,x=n+b,S=n-b;a[m++]=E,a[m++]=x,a[--v]=x,a[--v]=T,a[g++]=T,a[g++]=S,a[--_]=S,a[--_]=E}y=r,b=i+s,E=e+y,T=e-y,x=n+b,S=n-b;a[m++]=E,a[m++]=x,a[--_]=S,a[--_]=E,r&&(a[m++]=T,a[m++]=x,a[--_]=S,a[--_]=T)}},triangulate:function(t,e){var n,r,i=t.points,o=e.points,s=e.indices,a=o.length/2,u=a;if(t.type!==k.HS.RREC){var l=t.shape;n=l.x,r=l.y}else{var c=t.shape;n=c.x+c.width/2,r=c.y+c.height/2}var h=t.matrix;o.push(t.matrix?h.a*n+h.c*r+h.tx:n,t.matrix?h.b*n+h.d*r+h.ty:r),a++,o.push(i[0],i[1]);for(var f=2;f<i.length;f+=2)o.push(i[f],i[f+1]),s.push(a++,u,a);s.push(u+1,u,a)}},je={build:function(t){var e=t.shape,n=e.x,r=e.y,i=e.width,o=e.height,s=t.points;s.length=0,s.push(n,r,n+i,r,n+i,r+o,n,r+o)},triangulate:function(t,e){var n=t.points,r=e.points,i=r.length/2;r.push(n[0],n[1],n[2],n[3],n[6],n[7],n[4],n[5]),e.indices.push(i,i+1,i+2,i+1,i+2,i+3)}};function Ve(t,e,n){var r=e-t;return t+r*n}function Ye(t,e,n,r,i,o,s){void 0===s&&(s=[]);for(var a=20,u=s,l=0,c=0,h=0,f=0,d=0,p=0,m=0,v=0;m<=a;++m)v=m/a,l=Ve(t,n,v),c=Ve(e,r,v),h=Ve(n,i,v),f=Ve(r,o,v),d=Ve(l,h,v),p=Ve(c,f,v),0===m&&u[u.length-2]===d&&u[u.length-1]===p||u.push(d,p);return u}var We={build:function(t){if(mn.nextRoundedRectBehavior)He.build(t);else{var e=t.shape,n=t.points,r=e.x,i=e.y,o=e.width,s=e.height,a=Math.max(0,Math.min(e.radius,Math.min(o,s)/2));n.length=0,a?(Ye(r,i+a,r,i,r+a,i,n),Ye(r+o-a,i,r+o,i,r+o,i+a,n),Ye(r+o,i+s-a,r+o,i+s,r+o-a,i+s,n),Ye(r+a,i+s,r,i+s,r,i+s-a,n)):n.push(r,i,r+o,i,r+o,i+s,r,i+s)}},triangulate:function(t,e){if(mn.nextRoundedRectBehavior)He.triangulate(t,e);else{for(var n=t.points,r=e.points,i=e.indices,o=r.length/2,s=(0,O.OT)(n,null,2),a=0,u=s.length;a<u;a+=3)i.push(s[a]+o),i.push(s[a+1]+o),i.push(s[a+2]+o);for(a=0,u=n.length;a<u;a++)r.push(n[a],n[++a])}}};function ze(t,e,n,r,i,o,s,a){var u,l,c=t-n*i,h=e-r*i,f=t+n*o,d=e+r*o;s?(u=r,l=-n):(u=-r,l=n);var p=c+u,m=h+l,v=f+u,g=d+l;return a.push(p,m),a.push(v,g),2}function $e(t,e,n,r,i,o,s,a){var u=n-t,l=r-e,c=Math.atan2(u,l),h=Math.atan2(i-t,o-e);a&&c<h?c+=2*Math.PI:!a&&c>h&&(h+=2*Math.PI);var f=c,d=h-c,p=Math.abs(d),m=Math.sqrt(u*u+l*l),v=1+(15*p*Math.sqrt(m)/Math.PI>>0),g=d/v;if(f+=g,a){s.push(t,e),s.push(n,r);for(var _=1,y=f;_<v;_++,y+=g)s.push(t,e),s.push(t+Math.sin(y)*m,e+Math.cos(y)*m);s.push(t,e),s.push(i,o)}else{s.push(n,r),s.push(t,e);for(_=1,y=f;_<v;_++,y+=g)s.push(t+Math.sin(y)*m,e+Math.cos(y)*m),s.push(t,e);s.push(i,o),s.push(t,e)}return 2*v}function qe(t,e){var n=t.shape,r=t.points||n.points.slice(),i=e.closePointEps;if(0!==r.length){var o=t.lineStyle,s=new k.E9(r[0],r[1]),a=new k.E9(r[r.length-2],r[r.length-1]),u=n.type!==k.HS.POLY||n.closeStroke,l=Math.abs(s.x-a.x)<i&&Math.abs(s.y-a.y)<i;if(u){r=r.slice(),l&&(r.pop(),r.pop(),a.set(r[r.length-2],r[r.length-1]));var c=.5*(s.x+a.x),h=.5*(a.y+s.y);r.unshift(c,h),r.push(c,h)}var f=e.points,d=r.length/2,p=r.length,m=f.length/2,v=o.width/2,g=v*v,_=o.miterLimit*o.miterLimit,y=r[0],b=r[1],E=r[2],T=r[3],x=0,S=0,R=-(b-T),A=y-E,O=0,I=0,w=Math.sqrt(R*R+A*A);R/=w,A/=w,R*=v,A*=v;var C=o.alignment,P=2*(1-C),N=2*C;u||(o.cap===Ce.ROUND?p+=$e(y-R*(P-N)*.5,b-A*(P-N)*.5,y-R*P,b-A*P,y+R*N,b+A*N,f,!0)+2:o.cap===Ce.SQUARE&&(p+=ze(y,b,R,A,P,N,!0,f))),f.push(y-R*P,b-A*P),f.push(y+R*N,b+A*N);for(var M=1;M<d-1;++M){y=r[2*(M-1)],b=r[2*(M-1)+1],E=r[2*M],T=r[2*M+1],x=r[2*(M+1)],S=r[2*(M+1)+1],R=-(b-T),A=y-E,w=Math.sqrt(R*R+A*A),R/=w,A/=w,R*=v,A*=v,O=-(T-S),I=E-x,w=Math.sqrt(O*O+I*I),O/=w,I/=w,O*=v,I*=v;var D=E-y,L=b-T,B=E-x,F=S-T,U=L*B-F*D,G=U<0;if(Math.abs(U)<.1)f.push(E-R*P,T-A*P),f.push(E+R*N,T+A*N);else{var X=(-R+y)*(-A+T)-(-R+E)*(-A+b),H=(-O+x)*(-I+T)-(-O+E)*(-I+S),j=(D*H-B*X)/U,V=(F*X-L*H)/U,Y=(j-E)*(j-E)+(V-T)*(V-T),W=E+(j-E)*P,z=T+(V-T)*P,$=E-(j-E)*N,q=T-(V-T)*N,K=Math.min(D*D+L*L,B*B+F*F),Z=G?P:N,J=K+Z*Z*g,Q=Y<=J;Q?o.join===we.BEVEL||Y/g>_?(G?(f.push(W,z),f.push(E+R*N,T+A*N),f.push(W,z),f.push(E+O*N,T+I*N)):(f.push(E-R*P,T-A*P),f.push($,q),f.push(E-O*P,T-I*P),f.push($,q)),p+=2):o.join===we.ROUND?G?(f.push(W,z),f.push(E+R*N,T+A*N),p+=$e(E,T,E+R*N,T+A*N,E+O*N,T+I*N,f,!0)+4,f.push(W,z),f.push(E+O*N,T+I*N)):(f.push(E-R*P,T-A*P),f.push($,q),p+=$e(E,T,E-R*P,T-A*P,E-O*P,T-I*P,f,!1)+4,f.push(E-O*P,T-I*P),f.push($,q)):(f.push(W,z),f.push($,q)):(f.push(E-R*P,T-A*P),f.push(E+R*N,T+A*N),o.join===we.BEVEL||Y/g>_||(o.join===we.ROUND?p+=G?$e(E,T,E+R*N,T+A*N,E+O*N,T+I*N,f,!0)+2:$e(E,T,E-R*P,T-A*P,E-O*P,T-I*P,f,!1)+2:(G?(f.push($,q),f.push($,q)):(f.push(W,z),f.push(W,z)),p+=2)),f.push(E-O*P,T-I*P),f.push(E+O*N,T+I*N),p+=2)}}y=r[2*(d-2)],b=r[2*(d-2)+1],E=r[2*(d-1)],T=r[2*(d-1)+1],R=-(b-T),A=y-E,w=Math.sqrt(R*R+A*A),R/=w,A/=w,R*=v,A*=v,f.push(E-R*P,T-A*P),f.push(E+R*N,T+A*N),u||(o.cap===Ce.ROUND?p+=$e(E-R*(P-N)*.5,T-A*(P-N)*.5,E-R*P,T-A*P,E+R*N,T+A*N,f,!1)+2:o.cap===Ce.SQUARE&&(p+=ze(E,T,R,A,P,N,!1,f)));var tt=e.indices,et=Be.epsilon*Be.epsilon;for(M=m;M<p+m-2;++M)y=f[2*M],b=f[2*M+1],E=f[2*(M+1)],T=f[2*(M+1)+1],x=f[2*(M+2)],S=f[2*(M+2)+1],Math.abs(y*(T-S)+E*(S-b)+x*(b-T))<et||tt.push(M,M+1,M+2)}}function Ke(t,e){var n=0,r=t.shape,i=t.points||r.points,o=r.type!==k.HS.POLY||r.closeStroke;if(0!==i.length){var s=e.points,a=e.indices,u=i.length/2,l=s.length/2,c=l;for(s.push(i[0],i[1]),n=1;n<u;n++)s.push(i[2*n],i[2*n+1]),a.push(c,c+1),c++;o&&a.push(c,l)}}function Ze(t,e){t.lineStyle.native?Ke(t,e):qe(t,e)}var Je,Qe,tn=function(){function t(){}return t.curveTo=function(t,e,n,r,i,o){var s=o[o.length-2],a=o[o.length-1],u=a-e,l=s-t,c=r-e,h=n-t,f=Math.abs(u*h-l*c);if(f<1e-8||0===i)return o[o.length-2]===t&&o[o.length-1]===e||o.push(t,e),null;var d=u*u+l*l,p=c*c+h*h,m=u*c+l*h,v=i*Math.sqrt(d)/f,g=i*Math.sqrt(p)/f,_=v*m/d,y=g*m/p,b=v*h+g*l,E=v*c+g*u,T=l*(g+_),x=u*(g+_),S=h*(v+y),R=c*(v+y),A=Math.atan2(x-E,T-b),O=Math.atan2(R-E,S-b);return{cx:b+t,cy:E+e,radius:i,startAngle:A,endAngle:O,anticlockwise:l*c>h*u}},t.arc=function(t,e,n,r,i,o,s,a,u){for(var l=s-o,c=Be._segmentsCount(Math.abs(l)*i,40*Math.ceil(Math.abs(l)/k._b)),h=l/(2*c),f=2*h,d=Math.cos(h),p=Math.sin(h),m=c-1,v=m%1/m,g=0;g<=m;++g){var _=g+v*g,y=h+o+f*_,b=Math.cos(y),E=-Math.sin(y);u.push((d*b+p*E)*i+n,(d*-E+p*b)*i+r)}},t}(),en=function(){function t(){}return t.curveLength=function(t,e,n,r,i,o,s,a){for(var u=10,l=0,c=0,h=0,f=0,d=0,p=0,m=0,v=0,g=0,_=0,y=0,b=t,E=e,T=1;T<=u;++T)c=T/u,h=c*c,f=h*c,d=1-c,p=d*d,m=p*d,v=m*t+3*p*c*n+3*d*h*i+f*s,g=m*e+3*p*c*r+3*d*h*o+f*a,_=b-v,y=E-g,b=v,E=g,l+=Math.sqrt(_*_+y*y);return l},t.curveTo=function(e,n,r,i,o,s,a){var u=a[a.length-2],l=a[a.length-1];a.length-=2;var c=Be._segmentsCount(t.curveLength(u,l,e,n,r,i,o,s)),h=0,f=0,d=0,p=0,m=0;a.push(u,l);for(var v=1,g=0;v<=c;++v)g=v/c,h=1-g,f=h*h,d=f*h,p=g*g,m=p*g,a.push(d*u+3*f*g*e+3*h*p*r+m*o,d*l+3*f*g*n+3*h*p*i+m*s)},t}(),nn=function(){function t(){}return t.curveLength=function(t,e,n,r,i,o){var s=t-2*n+i,a=e-2*r+o,u=2*n-2*t,l=2*r-2*e,c=4*(s*s+a*a),h=4*(s*u+a*l),f=u*u+l*l,d=2*Math.sqrt(c+h+f),p=Math.sqrt(c),m=2*c*p,v=2*Math.sqrt(f),g=h/p;return(m*d+p*h*(d-v)+(4*f*c-h*h)*Math.log((2*p+g+d)/(g+v)))/(4*m)},t.curveTo=function(e,n,r,i,o){for(var s=o[o.length-2],a=o[o.length-1],u=Be._segmentsCount(t.curveLength(s,a,e,n,r,i)),l=0,c=0,h=1;h<=u;++h){var f=h/u;l=s+(e-s)*f,c=a+(n-a)*f,o.push(l+(e+(r-e)*f-l)*f,c+(n+(i-n)*f-c)*f)}},t}(),rn=function(){function t(){this.reset()}return t.prototype.begin=function(t,e,n){this.reset(),this.style=t,this.start=e,this.attribStart=n},t.prototype.end=function(t,e){this.attribSize=e-this.attribStart,this.size=t-this.start},t.prototype.reset=function(){this.style=null,this.size=0,this.start=0,this.attribStart=0,this.attribSize=0},t}(),on=(Je={},Je[k.HS.POLY]=Xe,Je[k.HS.CIRC]=He,Je[k.HS.ELIP]=He,Je[k.HS.RECT]=je,Je[k.HS.RREC]=We,Je),sn=[],an=[],un=function(){function t(t,e,n,r){void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null),this.points=[],this.holes=[],this.shape=t,this.lineStyle=n,this.fillStyle=e,this.matrix=r,this.type=t.type}return t.prototype.clone=function(){return new t(this.shape,this.fillStyle,this.lineStyle,this.matrix)},t.prototype.destroy=function(){this.shape=null,this.holes.length=0,this.holes=null,this.points.length=0,this.points=null,this.lineStyle=null,this.fillStyle=null},t}(),ln=new k.E9,cn=new I.YZ,hn=function(t){function e(){var e=t.call(this)||this;return e.closePointEps=1e-4,e.boundsPadding=0,e.uvsFloat32=null,e.indicesUint16=null,e.batchable=!1,e.points=[],e.colors=[],e.uvs=[],e.indices=[],e.textureIds=[],e.graphicsData=[],e.drawCalls=[],e.batchDirty=-1,e.batches=[],e.dirty=0,e.cacheDirty=-1,e.clearDirty=0,e.shapeIndex=0,e._bounds=new I.YZ,e.boundsDirty=-1,e}return Ge(e,t),Object.defineProperty(e.prototype,"bounds",{get:function(){return this.boundsDirty!==this.dirty&&(this.boundsDirty=this.dirty,this.calculateBounds()),this._bounds},enumerable:!1,configurable:!0}),e.prototype.invalidate=function(){this.boundsDirty=-1,this.dirty++,this.batchDirty++,this.shapeIndex=0,this.points.length=0,this.colors.length=0,this.uvs.length=0,this.indices.length=0,this.textureIds.length=0;for(var t=0;t<this.drawCalls.length;t++)this.drawCalls[t].texArray.clear(),an.push(this.drawCalls[t]);this.drawCalls.length=0;for(t=0;t<this.batches.length;t++){var e=this.batches[t];e.reset(),sn.push(e)}this.batches.length=0},e.prototype.clear=function(){return this.graphicsData.length>0&&(this.invalidate(),this.clearDirty++,this.graphicsData.length=0),this},e.prototype.drawShape=function(t,e,n,r){void 0===e&&(e=null),void 0===n&&(n=null),void 0===r&&(r=null);var i=new un(t,e,n,r);return this.graphicsData.push(i),this.dirty++,this},e.prototype.drawHole=function(t,e){if(void 0===e&&(e=null),!this.graphicsData.length)return null;var n=new un(t,null,null,e),r=this.graphicsData[this.graphicsData.length-1];return n.lineStyle=r.lineStyle,r.holes.push(n),this.dirty++,this},e.prototype.destroy=function(){t.prototype.destroy.call(this);for(var e=0;e<this.graphicsData.length;++e)this.graphicsData[e].destroy();this.points.length=0,this.points=null,this.colors.length=0,this.colors=null,this.uvs.length=0,this.uvs=null,this.indices.length=0,this.indices=null,this.indexBuffer.destroy(),this.indexBuffer=null,this.graphicsData.length=0,this.graphicsData=null,this.drawCalls.length=0,this.drawCalls=null,this.batches.length=0,this.batches=null,this._bounds=null},e.prototype.containsPoint=function(t){for(var e=this.graphicsData,n=0;n<e.length;++n){var r=e[n];if(r.fillStyle.visible&&(r.shape&&(r.matrix?r.matrix.applyInverse(t,ln):ln.copyFrom(t),r.shape.contains(ln.x,ln.y)))){var i=!1;if(r.holes)for(var o=0;o<r.holes.length;o++){var s=r.holes[o];if(s.shape.contains(ln.x,ln.y)){i=!0;break}}if(!i)return!0}}return!1},e.prototype.updateBatches=function(t){if(this.graphicsData.length){if(this.validateBatching()){this.cacheDirty=this.dirty;var e=this.uvs,n=this.graphicsData,r=null,i=null;this.batches.length>0&&(r=this.batches[this.batches.length-1],i=r.style);for(var o=this.shapeIndex;o<n.length;o++){this.shapeIndex++;var s=n[o],a=s.fillStyle,u=s.lineStyle,l=on[s.type];l.build(s),s.matrix&&this.transformPoints(s.points,s.matrix),(a.visible||u.visible)&&this.processHoles(s.holes);for(var c=0;c<2;c++){var h=0===c?a:u;if(h.visible){var f=h.texture.baseTexture,d=this.indices.length,p=this.points.length/2;f.wrapMode=Dt.Nt.REPEAT,0===c?this.processFill(s):this.processLine(s);var m=this.points.length/2-p;0!==m&&(r&&!this._compareStyles(i,h)&&(r.end(d,p),r=null),r||(r=sn.pop()||new rn,r.begin(h,d,p),this.batches.push(r),i=h),this.addUvs(this.points,e,h.texture,p,m,h.matrix))}}}var v=this.indices.length,g=this.points.length/2;if(r&&r.end(v,g),0!==this.batches.length){if(this.indicesUint16&&this.indices.length===this.indicesUint16.length)this.indicesUint16.set(this.indices);else{var _=g>65535&&t;this.indicesUint16=_?new Uint32Array(this.indices):new Uint16Array(this.indices)}this.batchable=this.isBatchable(),this.batchable?this.packBatches():this.buildDrawCalls()}else this.batchable=!0}}else this.batchable=!0},e.prototype._compareStyles=function(t,e){return!(!t||!e)&&(t.texture.baseTexture===e.texture.baseTexture&&(t.color+t.alpha===e.color+e.alpha&&!!t.native===!!e.native))},e.prototype.validateBatching=function(){if(this.dirty===this.cacheDirty||!this.graphicsData.length)return!1;for(var t=0,e=this.graphicsData.length;t<e;t++){var n=this.graphicsData[t],r=n.fillStyle,i=n.lineStyle;if(r&&!r.texture.baseTexture.valid)return!1;if(i&&!i.texture.baseTexture.valid)return!1}return!0},e.prototype.packBatches=function(){this.batchDirty++,this.uvsFloat32=new Float32Array(this.uvs);for(var t=this.batches,e=0,n=t.length;e<n;e++)for(var r=t[e],i=0;i<r.size;i++){var o=r.start+i;this.indicesUint16[o]=this.indicesUint16[o]-r.attribStart}},e.prototype.isBatchable=function(){if(this.points.length>131070)return!1;for(var t=this.batches,n=0;n<t.length;n++)if(t[n].style.native)return!1;return this.points.length<2*e.BATCHABLE_SIZE},e.prototype.buildDrawCalls=function(){for(var t=++J.VL._globalBatch,e=0;e<this.drawCalls.length;e++)this.drawCalls[e].texArray.clear(),an.push(this.drawCalls[e]);this.drawCalls.length=0;var n=this.colors,r=this.textureIds,i=an.pop();i||(i=new J.a$,i.texArray=new J.Ie),i.texArray.count=0,i.start=0,i.size=0,i.type=Dt.lg.TRIANGLES;var o=0,s=null,a=0,u=!1,l=Dt.lg.TRIANGLES,c=0;this.drawCalls.push(i);for(e=0;e<this.batches.length;e++){var h=this.batches[e],f=8,d=h.style,p=d.texture.baseTexture;u!==!!d.native&&(u=!!d.native,l=u?Dt.lg.LINES:Dt.lg.TRIANGLES,s=null,o=f,t++),s!==p&&(s=p,p._batchEnabled!==t&&(o===f&&(t++,o=0,i.size>0&&(i=an.pop(),i||(i=new J.a$,i.texArray=new J.Ie),this.drawCalls.push(i)),i.start=c,i.size=0,i.texArray.count=0,i.type=l),p.touched=1,p._batchEnabled=t,p._batchLocation=o,p.wrapMode=Dt.Nt.REPEAT,i.texArray.elements[i.texArray.count++]=p,o++)),i.size+=h.size,c+=h.size,a=p._batchLocation,this.addColors(n,d.color,d.alpha,h.attribSize,h.attribStart),this.addTextureIds(r,a,h.attribSize,h.attribStart)}J.VL._globalBatch=t,this.packAttributes()},e.prototype.packAttributes=function(){for(var t=this.points,e=this.uvs,n=this.colors,r=this.textureIds,i=new ArrayBuffer(3*t.length*4),o=new Float32Array(i),s=new Uint32Array(i),a=0,u=0;u<t.length/2;u++)o[a++]=t[2*u],o[a++]=t[2*u+1],o[a++]=e[2*u],o[a++]=e[2*u+1],s[a++]=n[u],o[a++]=r[u];this._buffer.update(i),this._indexBuffer.update(this.indicesUint16)},e.prototype.processFill=function(t){if(t.holes.length)Xe.triangulate(t,this);else{var e=on[t.type];e.triangulate(t,this)}},e.prototype.processLine=function(t){Ze(t,this);for(var e=0;e<t.holes.length;e++)Ze(t.holes[e],this)},e.prototype.processHoles=function(t){for(var e=0;e<t.length;e++){var n=t[e],r=on[n.type];r.build(n),n.matrix&&this.transformPoints(n.points,n.matrix)}},e.prototype.calculateBounds=function(){var t=this._bounds,e=cn,n=k.y3.IDENTITY;this._bounds.clear(),e.clear();for(var r=0;r<this.graphicsData.length;r++){var i=this.graphicsData[r],o=i.shape,s=i.type,a=i.lineStyle,u=i.matrix||k.y3.IDENTITY,l=0;if(a&&a.visible&&(l=a.width*Math.max(0,a.alignment)),n!==u&&(e.isEmpty()||(t.addBoundsMatrix(e,n),e.clear()),n=u),s===k.HS.RECT||s===k.HS.RREC){var c=o;e.addFramePad(c.x,c.y,c.x+c.width,c.y+c.height,l,l)}else if(s===k.HS.CIRC){var h=o;e.addFramePad(h.x,h.y,h.x,h.y,h.radius+l,h.radius+l)}else if(s===k.HS.ELIP){var f=o;e.addFramePad(f.x,f.y,f.x,f.y,f.width+l,f.height+l)}else{var d=o;t.addVerticesMatrix(n,d.points,0,d.points.length,l,l)}}e.isEmpty()||t.addBoundsMatrix(e,n),t.pad(this.boundsPadding,this.boundsPadding)},e.prototype.transformPoints=function(t,e){for(var n=0;n<t.length/2;n++){var r=t[2*n],i=t[2*n+1];t[2*n]=e.a*r+e.c*i+e.tx,t[2*n+1]=e.b*r+e.d*i+e.ty}},e.prototype.addColors=function(t,e,n,r,i){void 0===i&&(i=0);var o=(e>>16)+(65280&e)+((255&e)<<16),s=(0,O.rA)(o,n);t.length=Math.max(t.length,i+r);for(var a=0;a<r;a++)t[i+a]=s},e.prototype.addTextureIds=function(t,e,n,r){void 0===r&&(r=0),t.length=Math.max(t.length,r+n);for(var i=0;i<n;i++)t[r+i]=e},e.prototype.addUvs=function(t,e,n,r,i,o){void 0===o&&(o=null);var s=0,a=e.length,u=n.frame;while(s<i){var l=t[2*(r+s)],c=t[2*(r+s)+1];if(o){var h=o.a*l+o.c*c+o.tx;c=o.b*l+o.d*c+o.ty,l=h}s++,e.push(l/u.width,c/u.height)}var f=n.baseTexture;(u.width<f.width||u.height<f.height)&&this.adjustUvs(e,n,a,i)},e.prototype.adjustUvs=function(t,e,n,r){for(var i=e.baseTexture,o=1e-6,s=n+2*r,a=e.frame,u=a.width/i.width,l=a.height/i.height,c=a.x/a.width,h=a.y/a.height,f=Math.floor(t[n]+o),d=Math.floor(t[n+1]+o),p=n+2;p<s;p+=2)f=Math.min(f,Math.floor(t[p]+o)),d=Math.min(d,Math.floor(t[p+1]+o));c-=f,h-=d;for(p=n;p<s;p+=2)t[p]=(t[p]+c)*u,t[p+1]=(t[p+1]+h)*l},e.BATCHABLE_SIZE=100,e}(J.JZ),fn=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.width=0,e.alignment=.5,e.native=!1,e.cap=Ce.BUTT,e.join=we.MITER,e.miterLimit=10,e}return Ge(e,t),e.prototype.clone=function(){var t=new e;return t.color=this.color,t.alpha=this.alpha,t.texture=this.texture,t.matrix=this.matrix,t.visible=this.visible,t.width=this.width,t.alignment=this.alignment,t.native=this.native,t.cap=this.cap,t.join=this.join,t.miterLimit=this.miterLimit,t},e.prototype.reset=function(){t.prototype.reset.call(this),this.color=0,this.alignment=.5,this.width=0,this.native=!1},e}(Fe),dn=new Float32Array(3),pn={},mn=function(t){function e(e){void 0===e&&(e=null);var n=t.call(this)||this;return n.shader=null,n.pluginName="batch",n.currentPath=null,n.batches=[],n.batchTint=-1,n.batchDirty=-1,n.vertexData=null,n._fillStyle=new Fe,n._lineStyle=new fn,n._matrix=null,n._holeMode=!1,n.state=J.ZM.for2d(),n._geometry=e||new hn,n._geometry.refCount++,n._transformID=-1,n.tint=16777215,n.blendMode=Dt.T$.NORMAL,n}return Ge(e,t),Object.defineProperty(e.prototype,"geometry",{get:function(){return this._geometry},enumerable:!1,configurable:!0}),e.prototype.clone=function(){return this.finishPoly(),new e(this._geometry)},Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.state.blendMode},set:function(t){this.state.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){this._tint=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fill",{get:function(){return this._fillStyle},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"line",{get:function(){return this._lineStyle},enumerable:!1,configurable:!0}),e.prototype.lineStyle=function(t,e,n,r,i){return void 0===t&&(t=null),void 0===e&&(e=0),void 0===n&&(n=1),void 0===r&&(r=.5),void 0===i&&(i=!1),"number"===typeof t&&(t={width:t,color:e,alpha:n,alignment:r,native:i}),this.lineTextureStyle(t)},e.prototype.lineTextureStyle=function(t){t=Object.assign({width:0,texture:J.xE.WHITE,color:t&&t.texture?16777215:0,alpha:1,matrix:null,alignment:.5,native:!1,cap:Ce.BUTT,join:we.MITER,miterLimit:10},t),this.currentPath&&this.startPoly();var e=t.width>0&&t.alpha>0;return e?(t.matrix&&(t.matrix=t.matrix.clone(),t.matrix.invert()),Object.assign(this._lineStyle,{visible:e},t)):this._lineStyle.reset(),this},e.prototype.startPoly=function(){if(this.currentPath){var t=this.currentPath.points,e=this.currentPath.points.length;e>2&&(this.drawShape(this.currentPath),this.currentPath=new k.mg,this.currentPath.closeStroke=!1,this.currentPath.points.push(t[e-2],t[e-1]))}else this.currentPath=new k.mg,this.currentPath.closeStroke=!1},e.prototype.finishPoly=function(){this.currentPath&&(this.currentPath.points.length>2?(this.drawShape(this.currentPath),this.currentPath=null):this.currentPath.points.length=0)},e.prototype.moveTo=function(t,e){return this.startPoly(),this.currentPath.points[0]=t,this.currentPath.points[1]=e,this},e.prototype.lineTo=function(t,e){this.currentPath||this.moveTo(0,0);var n=this.currentPath.points,r=n[n.length-2],i=n[n.length-1];return r===t&&i===e||n.push(t,e),this},e.prototype._initCurve=function(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.currentPath?0===this.currentPath.points.length&&(this.currentPath.points=[t,e]):this.moveTo(t,e)},e.prototype.quadraticCurveTo=function(t,e,n,r){this._initCurve();var i=this.currentPath.points;return 0===i.length&&this.moveTo(0,0),nn.curveTo(t,e,n,r,i),this},e.prototype.bezierCurveTo=function(t,e,n,r,i,o){return this._initCurve(),en.curveTo(t,e,n,r,i,o,this.currentPath.points),this},e.prototype.arcTo=function(t,e,n,r,i){this._initCurve(t,e);var o=this.currentPath.points,s=tn.curveTo(t,e,n,r,i,o);if(s){var a=s.cx,u=s.cy,l=s.radius,c=s.startAngle,h=s.endAngle,f=s.anticlockwise;this.arc(a,u,l,c,h,f)}return this},e.prototype.arc=function(t,e,n,r,i,o){if(void 0===o&&(o=!1),r===i)return this;!o&&i<=r?i+=k._b:o&&r<=i&&(r+=k._b);var s=i-r;if(0===s)return this;var a=t+Math.cos(r)*n,u=e+Math.sin(r)*n,l=this._geometry.closePointEps,c=this.currentPath?this.currentPath.points:null;if(c){var h=Math.abs(c[c.length-2]-a),f=Math.abs(c[c.length-1]-u);h<l&&f<l||c.push(a,u)}else this.moveTo(a,u),c=this.currentPath.points;return tn.arc(a,u,t,e,n,r,i,o,c),this},e.prototype.beginFill=function(t,e){return void 0===t&&(t=0),void 0===e&&(e=1),this.beginTextureFill({texture:J.xE.WHITE,color:t,alpha:e})},e.prototype.beginTextureFill=function(t){t=Object.assign({texture:J.xE.WHITE,color:16777215,alpha:1,matrix:null},t),this.currentPath&&this.startPoly();var e=t.alpha>0;return e?(t.matrix&&(t.matrix=t.matrix.clone(),t.matrix.invert()),Object.assign(this._fillStyle,{visible:e},t)):this._fillStyle.reset(),this},e.prototype.endFill=function(){return this.finishPoly(),this._fillStyle.reset(),this},e.prototype.drawRect=function(t,e,n,r){return this.drawShape(new k.Ae(t,e,n,r))},e.prototype.drawRoundedRect=function(t,e,n,r,i){return this.drawShape(new k.c9(t,e,n,r,i))},e.prototype.drawCircle=function(t,e,n){return this.drawShape(new k.Cd(t,e,n))},e.prototype.drawEllipse=function(t,e,n,r){return this.drawShape(new k.Pj(t,e,n,r))},e.prototype.drawPolygon=function(){for(var t,e=arguments,n=[],r=0;r<arguments.length;r++)n[r]=e[r];var i=!0,o=n[0];o.points?(i=o.closeStroke,t=o.points):t=Array.isArray(n[0])?n[0]:n;var s=new k.mg(t);return s.closeStroke=i,this.drawShape(s),this},e.prototype.drawShape=function(t){return this._holeMode?this._geometry.drawHole(t,this._matrix):this._geometry.drawShape(t,this._fillStyle.clone(),this._lineStyle.clone(),this._matrix),this},e.prototype.clear=function(){return this._geometry.clear(),this._lineStyle.reset(),this._fillStyle.reset(),this._boundsID++,this._matrix=null,this._holeMode=!1,this.currentPath=null,this},e.prototype.isFastRect=function(){var t=this._geometry.graphicsData;return 1===t.length&&t[0].shape.type===k.HS.RECT&&!t[0].matrix&&!t[0].holes.length&&!(t[0].lineStyle.visible&&t[0].lineStyle.width)},e.prototype._render=function(t){this.finishPoly();var e=this._geometry,n=t.context.supports.uint32Indices;e.updateBatches(n),e.batchable?(this.batchDirty!==e.batchDirty&&this._populateBatches(),this._renderBatched(t)):(t.batch.flush(),this._renderDirect(t))},e.prototype._populateBatches=function(){var t=this._geometry,e=this.blendMode,n=t.batches.length;this.batchTint=-1,this._transformID=-1,this.batchDirty=t.batchDirty,this.batches.length=n,this.vertexData=new Float32Array(t.points);for(var r=0;r<n;r++){var i=t.batches[r],o=i.style.color,s=new Float32Array(this.vertexData.buffer,4*i.attribStart*2,2*i.attribSize),a=new Float32Array(t.uvsFloat32.buffer,4*i.attribStart*2,2*i.attribSize),u=new Uint16Array(t.indicesUint16.buffer,2*i.start,i.size),l={vertexData:s,blendMode:e,indices:u,uvs:a,_batchRGB:(0,O.wK)(o),_tintRGB:o,_texture:i.style.texture,alpha:i.style.alpha,worldAlpha:1};this.batches[r]=l}},e.prototype._renderBatched=function(t){if(this.batches.length){t.batch.setObjectRenderer(t.plugins[this.pluginName]),this.calculateVertices(),this.calculateTints();for(var e=0,n=this.batches.length;e<n;e++){var r=this.batches[e];r.worldAlpha=this.worldAlpha*r.alpha,t.plugins[this.pluginName].render(r)}}},e.prototype._renderDirect=function(t){var e=this._resolveDirectShader(t),n=this._geometry,r=this.tint,i=this.worldAlpha,o=e.uniforms,s=n.drawCalls;o.translationMatrix=this.transform.worldTransform,o.tint[0]=(r>>16&255)/255*i,o.tint[1]=(r>>8&255)/255*i,o.tint[2]=(255&r)/255*i,o.tint[3]=i,t.shader.bind(e),t.geometry.bind(n,e),t.state.set(this.state);for(var a=0,u=s.length;a<u;a++)this._renderDrawCallDirect(t,n.drawCalls[a])},e.prototype._renderDrawCallDirect=function(t,e){for(var n=e.texArray,r=e.type,i=e.size,o=e.start,s=n.count,a=0;a<s;a++)t.texture.bind(n.elements[a],a);t.geometry.draw(r,i,o)},e.prototype._resolveDirectShader=function(t){var e=this.shader,n=this.pluginName;if(!e){if(!pn[n]){for(var r=t.plugins.batch.MAX_TEXTURES,i=new Int32Array(r),o=0;o<r;o++)i[o]=o;var s={tint:new Float32Array([1,1,1,1]),translationMatrix:new k.y3,default:J.oo.from({uSamplers:i},!0)},a=t.plugins[n]._shader.program;pn[n]=new J.ex(a,s)}e=pn[n]}return e},e.prototype._calculateBounds=function(){this.finishPoly();var t=this._geometry;if(t.graphicsData.length){var e=t.bounds,n=e.minX,r=e.minY,i=e.maxX,o=e.maxY;this._bounds.addFrame(this.transform,n,r,i,o)}},e.prototype.containsPoint=function(t){return this.worldTransform.applyInverse(t,e._TEMP_POINT),this._geometry.containsPoint(e._TEMP_POINT)},e.prototype.calculateTints=function(){if(this.batchTint!==this.tint){this.batchTint=this.tint;for(var t=(0,O.wK)(this.tint,dn),e=0;e<this.batches.length;e++){var n=this.batches[e],r=n._batchRGB,i=t[0]*r[0]*255,o=t[1]*r[1]*255,s=t[2]*r[2]*255,a=(i<<16)+(o<<8)+(0|s);n._tintRGB=(a>>16)+(65280&a)+((255&a)<<16)}}},e.prototype.calculateVertices=function(){var t=this.transform._worldID;if(this._transformID!==t){this._transformID=t;for(var e=this.transform.worldTransform,n=e.a,r=e.b,i=e.c,o=e.d,s=e.tx,a=e.ty,u=this._geometry.points,l=this.vertexData,c=0,h=0;h<u.length;h+=2){var f=u[h],d=u[h+1];l[c++]=n*f+i*d+s,l[c++]=o*d+r*f+a}}},e.prototype.closePath=function(){var t=this.currentPath;return t&&(t.closeStroke=!0,this.finishPoly()),this},e.prototype.setMatrix=function(t){return this._matrix=t,this},e.prototype.beginHole=function(){return this.finishPoly(),this._holeMode=!0,this},e.prototype.endHole=function(){return this.finishPoly(),this._holeMode=!1,this},e.prototype.destroy=function(e){this._geometry.refCount--,0===this._geometry.refCount&&this._geometry.dispose(),this._matrix=null,this.currentPath=null,this._lineStyle.destroy(),this._lineStyle=null,this._fillStyle.destroy(),this._fillStyle=null,this._geometry=null,this.shader=null,this.vertexData=null,this.batches.length=0,this.batches=null,t.prototype.destroy.call(this,e)},e.nextRoundedRectBehavior=!1,e._TEMP_POINT=new k.E9,e}(I.W2),vn=n(8033),gn=function(t,e){return gn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},gn(t,e)};function _n(t,e){function n(){this.constructor=t}gn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}(function(t){t[t["LINEAR_VERTICAL"]=0]="LINEAR_VERTICAL",t[t["LINEAR_HORIZONTAL"]=1]="LINEAR_HORIZONTAL"})(Qe||(Qe={}));var yn={align:"left",breakWords:!1,dropShadow:!1,dropShadowAlpha:1,dropShadowAngle:Math.PI/6,dropShadowBlur:0,dropShadowColor:"black",dropShadowDistance:5,fill:"black",fillGradientType:Qe.LINEAR_VERTICAL,fillGradientStops:[],fontFamily:"Arial",fontSize:26,fontStyle:"normal",fontVariant:"normal",fontWeight:"normal",letterSpacing:0,lineHeight:0,lineJoin:"miter",miterLimit:10,padding:0,stroke:"black",strokeThickness:0,textBaseline:"alphabetic",trim:!1,whiteSpace:"pre",wordWrap:!1,wordWrapWidth:100,leading:0},bn=["serif","sans-serif","monospace","cursive","fantasy","system-ui"],En=function(){function t(t){this.styleID=0,this.reset(),Rn(this,t,t)}return t.prototype.clone=function(){var e={};return Rn(e,this,yn),new t(e)},t.prototype.reset=function(){Rn(this,yn,yn)},Object.defineProperty(t.prototype,"align",{get:function(){return this._align},set:function(t){this._align!==t&&(this._align=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"breakWords",{get:function(){return this._breakWords},set:function(t){this._breakWords!==t&&(this._breakWords=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadow",{get:function(){return this._dropShadow},set:function(t){this._dropShadow!==t&&(this._dropShadow=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowAlpha",{get:function(){return this._dropShadowAlpha},set:function(t){this._dropShadowAlpha!==t&&(this._dropShadowAlpha=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowAngle",{get:function(){return this._dropShadowAngle},set:function(t){this._dropShadowAngle!==t&&(this._dropShadowAngle=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowBlur",{get:function(){return this._dropShadowBlur},set:function(t){this._dropShadowBlur!==t&&(this._dropShadowBlur=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowColor",{get:function(){return this._dropShadowColor},set:function(t){var e=xn(t);this._dropShadowColor!==e&&(this._dropShadowColor=e,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dropShadowDistance",{get:function(){return this._dropShadowDistance},set:function(t){this._dropShadowDistance!==t&&(this._dropShadowDistance=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fill",{get:function(){return this._fill},set:function(t){var e=xn(t);this._fill!==e&&(this._fill=e,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fillGradientType",{get:function(){return this._fillGradientType},set:function(t){this._fillGradientType!==t&&(this._fillGradientType=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fillGradientStops",{get:function(){return this._fillGradientStops},set:function(t){Sn(this._fillGradientStops,t)||(this._fillGradientStops=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontFamily",{get:function(){return this._fontFamily},set:function(t){this.fontFamily!==t&&(this._fontFamily=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontSize",{get:function(){return this._fontSize},set:function(t){this._fontSize!==t&&(this._fontSize=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontStyle",{get:function(){return this._fontStyle},set:function(t){this._fontStyle!==t&&(this._fontStyle=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontVariant",{get:function(){return this._fontVariant},set:function(t){this._fontVariant!==t&&(this._fontVariant=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fontWeight",{get:function(){return this._fontWeight},set:function(t){this._fontWeight!==t&&(this._fontWeight=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"letterSpacing",{get:function(){return this._letterSpacing},set:function(t){this._letterSpacing!==t&&(this._letterSpacing=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lineHeight",{get:function(){return this._lineHeight},set:function(t){this._lineHeight!==t&&(this._lineHeight=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"leading",{get:function(){return this._leading},set:function(t){this._leading!==t&&(this._leading=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"lineJoin",{get:function(){return this._lineJoin},set:function(t){this._lineJoin!==t&&(this._lineJoin=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"miterLimit",{get:function(){return this._miterLimit},set:function(t){this._miterLimit!==t&&(this._miterLimit=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"padding",{get:function(){return this._padding},set:function(t){this._padding!==t&&(this._padding=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"stroke",{get:function(){return this._stroke},set:function(t){var e=xn(t);this._stroke!==e&&(this._stroke=e,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"strokeThickness",{get:function(){return this._strokeThickness},set:function(t){this._strokeThickness!==t&&(this._strokeThickness=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textBaseline",{get:function(){return this._textBaseline},set:function(t){this._textBaseline!==t&&(this._textBaseline=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"trim",{get:function(){return this._trim},set:function(t){this._trim!==t&&(this._trim=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"whiteSpace",{get:function(){return this._whiteSpace},set:function(t){this._whiteSpace!==t&&(this._whiteSpace=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"wordWrap",{get:function(){return this._wordWrap},set:function(t){this._wordWrap!==t&&(this._wordWrap=t,this.styleID++)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"wordWrapWidth",{get:function(){return this._wordWrapWidth},set:function(t){this._wordWrapWidth!==t&&(this._wordWrapWidth=t,this.styleID++)},enumerable:!1,configurable:!0}),t.prototype.toFontString=function(){var t="number"===typeof this.fontSize?this.fontSize+"px":this.fontSize,e=this.fontFamily;Array.isArray(this.fontFamily)||(e=this.fontFamily.split(","));for(var n=e.length-1;n>=0;n--){var r=e[n].trim();!/([\"\'])[^\'\"]+\1/.test(r)&&bn.indexOf(r)<0&&(r='"'+r+'"'),e[n]=r}return this.fontStyle+" "+this.fontVariant+" "+this.fontWeight+" "+t+" "+e.join(",")},t}();function Tn(t){return"number"===typeof t?(0,O.XN)(t):("string"===typeof t&&0===t.indexOf("0x")&&(t=t.replace("0x","#")),t)}function xn(t){if(Array.isArray(t)){for(var e=0;e<t.length;++e)t[e]=Tn(t[e]);return t}return Tn(t)}function Sn(t,e){if(!Array.isArray(t)||!Array.isArray(e))return!1;if(t.length!==e.length)return!1;for(var n=0;n<t.length;++n)if(t[n]!==e[n])return!1;return!0}function Rn(t,e,n){for(var r in n)Array.isArray(e[r])?t[r]=e[r].slice():t[r]=e[r]}var An=function(){function t(t,e,n,r,i,o,s,a,u){this.text=t,this.style=e,this.width=n,this.height=r,this.lines=i,this.lineWidths=o,this.lineHeight=s,this.maxLineWidth=a,this.fontProperties=u}return t.measureText=function(e,n,r,i){void 0===i&&(i=t._canvas),r=void 0===r||null===r?n.wordWrap:r;var o=n.toFontString(),s=t.measureFont(o);0===s.fontSize&&(s.fontSize=n.fontSize,s.ascent=n.fontSize);var a=i.getContext("2d");a.font=o;for(var u=r?t.wordWrap(e,n,i):e,l=u.split(/(?:\r\n|\r|\n)/),c=new Array(l.length),h=0,f=0;f<l.length;f++){var d=a.measureText(l[f]).width+(l[f].length-1)*n.letterSpacing;c[f]=d,h=Math.max(h,d)}var p=h+n.strokeThickness;n.dropShadow&&(p+=n.dropShadowDistance);var m=n.lineHeight||s.fontSize+n.strokeThickness,v=Math.max(m,s.fontSize+n.strokeThickness)+(l.length-1)*(m+n.leading);return n.dropShadow&&(v+=n.dropShadowDistance),new t(e,n,p,v,l,c,m+n.leading,h,s)},t.wordWrap=function(e,n,r){void 0===r&&(r=t._canvas);for(var i=r.getContext("2d"),o=0,s="",a="",u=Object.create(null),l=n.letterSpacing,c=n.whiteSpace,h=t.collapseSpaces(c),f=t.collapseNewlines(c),d=!h,p=n.wordWrapWidth+l,m=t.tokenize(e),v=0;v<m.length;v++){var g=m[v];if(t.isNewline(g)){if(!f){a+=t.addLine(s),d=!h,s="",o=0;continue}g=" "}if(h){var _=t.isBreakingSpace(g),y=t.isBreakingSpace(s[s.length-1]);if(_&&y)continue}var b=t.getFromCache(g,l,u,i);if(b>p)if(""!==s&&(a+=t.addLine(s),s="",o=0),t.canBreakWords(g,n.breakWords))for(var E=t.wordWrapSplit(g),T=0;T<E.length;T++){var x=E[T],S=1;while(E[T+S]){var R=E[T+S],A=x[x.length-1];if(t.canBreakChars(A,R,g,T,n.breakWords))break;x+=R,S++}T+=x.length-1;var O=t.getFromCache(x,l,u,i);O+o>p&&(a+=t.addLine(s),d=!1,s="",o=0),s+=x,o+=O}else{s.length>0&&(a+=t.addLine(s),s="",o=0);var I=v===m.length-1;a+=t.addLine(g,!I),d=!1,s="",o=0}else b+o>p&&(d=!1,a+=t.addLine(s),s="",o=0),(s.length>0||!t.isBreakingSpace(g)||d)&&(s+=g,o+=b)}return a+=t.addLine(s,!1),a},t.addLine=function(e,n){return void 0===n&&(n=!0),e=t.trimRight(e),e=n?e+"\n":e,e},t.getFromCache=function(t,e,n,r){var i=n[t];if("number"!==typeof i){var o=t.length*e;i=r.measureText(t).width+o,n[t]=i}return i},t.collapseSpaces=function(t){return"normal"===t||"pre-line"===t},t.collapseNewlines=function(t){return"normal"===t},t.trimRight=function(e){if("string"!==typeof e)return"";for(var n=e.length-1;n>=0;n--){var r=e[n];if(!t.isBreakingSpace(r))break;e=e.slice(0,-1)}return e},t.isNewline=function(e){return"string"===typeof e&&t._newlines.indexOf(e.charCodeAt(0))>=0},t.isBreakingSpace=function(e,n){return"string"===typeof e&&t._breakingSpaces.indexOf(e.charCodeAt(0))>=0},t.tokenize=function(e){var n=[],r="";if("string"!==typeof e)return n;for(var i=0;i<e.length;i++){var o=e[i],s=e[i+1];t.isBreakingSpace(o,s)||t.isNewline(o)?(""!==r&&(n.push(r),r=""),n.push(o)):r+=o}return""!==r&&n.push(r),n},t.canBreakWords=function(t,e){return e},t.canBreakChars=function(t,e,n,r,i){return!0},t.wordWrapSplit=function(t){return t.split("")},t.measureFont=function(e){if(t._fonts[e])return t._fonts[e];var n={ascent:0,descent:0,fontSize:0},r=t._canvas,i=t._context;i.font=e;var o=t.METRICS_STRING+t.BASELINE_SYMBOL,s=Math.ceil(i.measureText(o).width),a=Math.ceil(i.measureText(t.BASELINE_SYMBOL).width),u=Math.ceil(t.HEIGHT_MULTIPLIER*a);a=a*t.BASELINE_MULTIPLIER|0,r.width=s,r.height=u,i.fillStyle="#f00",i.fillRect(0,0,s,u),i.font=e,i.textBaseline="alphabetic",i.fillStyle="#000",i.fillText(o,0,a);var l=i.getImageData(0,0,s,u).data,c=l.length,h=4*s,f=0,d=0,p=!1;for(f=0;f<a;++f){for(var m=0;m<h;m+=4)if(255!==l[d+m]){p=!0;break}if(p)break;d+=h}for(n.ascent=a-f,d=c-h,p=!1,f=u;f>a;--f){for(m=0;m<h;m+=4)if(255!==l[d+m]){p=!0;break}if(p)break;d-=h}return n.descent=f-a,n.fontSize=n.ascent+n.descent,t._fonts[e]=n,n},t.clearMetrics=function(e){void 0===e&&(e=""),e?delete t._fonts[e]:t._fonts={}},t}(),On=function(){try{var t=new OffscreenCanvas(0,0),e=t.getContext("2d");return e&&e.measureText?t:document.createElement("canvas")}catch(n){return document.createElement("canvas")}}();On.width=On.height=10,An._canvas=On,An._context=On.getContext("2d"),An._fonts={},An.METRICS_STRING="|ÉqÅ",An.BASELINE_SYMBOL="M",An.BASELINE_MULTIPLIER=1.4,An.HEIGHT_MULTIPLIER=2,An._newlines=[10,13],An._breakingSpaces=[9,32,8192,8193,8194,8195,8196,8197,8198,8200,8201,8202,8287,12288];var In={texture:!0,children:!1,baseTexture:!0},wn=function(t){function e(e,n,r){var i=this,o=!1;r||(r=document.createElement("canvas"),o=!0),r.width=3,r.height=3;var s=J.xE.from(r);return s.orig=new k.Ae,s.trim=new k.Ae,i=t.call(this,s)||this,i._ownCanvas=o,i.canvas=r,i.context=i.canvas.getContext("2d"),i._resolution=Le.X.RESOLUTION,i._autoResolution=!0,i._text=null,i._style=null,i._styleListener=null,i._font="",i.text=e,i.style=n,i.localStyleID=-1,i}return _n(e,t),e.prototype.updateText=function(t){var n=this._style;if(this.localStyleID!==n.styleID&&(this.dirty=!0,this.localStyleID=n.styleID),this.dirty||!t){this._font=this._style.toFontString();var r,i,o=this.context,s=An.measureText(this._text||" ",this._style,this._style.wordWrap,this.canvas),a=s.width,u=s.height,l=s.lines,c=s.lineHeight,h=s.lineWidths,f=s.maxLineWidth,d=s.fontProperties;this.canvas.width=Math.ceil(Math.ceil(Math.max(1,a)+2*n.padding)*this._resolution),this.canvas.height=Math.ceil(Math.ceil(Math.max(1,u)+2*n.padding)*this._resolution),o.scale(this._resolution,this._resolution),o.clearRect(0,0,this.canvas.width,this.canvas.height),o.font=this._font,o.lineWidth=n.strokeThickness,o.textBaseline=n.textBaseline,o.lineJoin=n.lineJoin,o.miterLimit=n.miterLimit;for(var p=n.dropShadow?2:1,m=0;m<p;++m){var v=n.dropShadow&&0===m,g=v?Math.ceil(Math.max(1,u)+2*n.padding):0,_=g*this._resolution;if(v){o.fillStyle="black",o.strokeStyle="black";var y=n.dropShadowColor,b=(0,O.wK)("number"===typeof y?y:(0,O.qm)(y)),E=n.dropShadowBlur*this._resolution,T=n.dropShadowDistance*this._resolution;o.shadowColor="rgba("+255*b[0]+","+255*b[1]+","+255*b[2]+","+n.dropShadowAlpha+")",o.shadowBlur=E,o.shadowOffsetX=Math.cos(n.dropShadowAngle)*T,o.shadowOffsetY=Math.sin(n.dropShadowAngle)*T+_}else o.fillStyle=this._generateFillStyle(n,l,s),o.strokeStyle=n.stroke,o.shadowColor="black",o.shadowBlur=0,o.shadowOffsetX=0,o.shadowOffsetY=0;var x=(c-d.fontSize)/2;(!e.nextLineHeightBehavior||c-d.fontSize<0)&&(x=0);for(var S=0;S<l.length;S++)r=n.strokeThickness/2,i=n.strokeThickness/2+S*c+d.ascent+x,"right"===n.align?r+=f-h[S]:"center"===n.align&&(r+=(f-h[S])/2),n.stroke&&n.strokeThickness&&this.drawLetterSpacing(l[S],r+n.padding,i+n.padding-g,!0),n.fill&&this.drawLetterSpacing(l[S],r+n.padding,i+n.padding-g)}this.updateTexture()}},e.prototype.drawLetterSpacing=function(t,n,r,i){void 0===i&&(i=!1);var o=this._style,s=o.letterSpacing,a=e.experimentalLetterSpacing&&("letterSpacing"in CanvasRenderingContext2D.prototype||"textLetterSpacing"in CanvasRenderingContext2D.prototype);if(0===s||a)return a&&(this.context.letterSpacing=s,this.context.textLetterSpacing=s),void(i?this.context.strokeText(t,n,r):this.context.fillText(t,n,r));for(var u=n,l=Array.from?Array.from(t):t.split(""),c=this.context.measureText(t).width,h=0,f=0;f<l.length;++f){var d=l[f];i?this.context.strokeText(d,u,r):this.context.fillText(d,u,r);for(var p="",m=f+1;m<l.length;++m)p+=l[m];h=this.context.measureText(p).width,u+=c-h+s,c=h}},e.prototype.updateTexture=function(){var t=this.canvas;if(this._style.trim){var e=(0,O.yA)(t);e.data&&(t.width=e.width,t.height=e.height,this.context.putImageData(e.data,0,0))}var n=this._texture,r=this._style,i=r.trim?0:r.padding,o=n.baseTexture;n.trim.width=n._frame.width=t.width/this._resolution,n.trim.height=n._frame.height=t.height/this._resolution,n.trim.x=-i,n.trim.y=-i,n.orig.width=n._frame.width-2*i,n.orig.height=n._frame.height-2*i,this._onTextureUpdate(),o.setRealSize(t.width,t.height,this._resolution),n.updateUvs(),this._recursivePostUpdateTransform(),this.dirty=!1},e.prototype._render=function(e){this._autoResolution&&this._resolution!==e.resolution&&(this._resolution=e.resolution,this.dirty=!0),this.updateText(!0),t.prototype._render.call(this,e)},e.prototype.getLocalBounds=function(e){return this.updateText(!0),t.prototype.getLocalBounds.call(this,e)},e.prototype._calculateBounds=function(){this.updateText(!0),this.calculateVertices(),this._bounds.addQuad(this.vertexData)},e.prototype._generateFillStyle=function(t,e,n){var r,i=t.fill;if(!Array.isArray(i))return i;if(1===i.length)return i[0];var o=t.dropShadow?t.dropShadowDistance:0,s=t.padding||0,a=this.canvas.width/this._resolution-o-2*s,u=this.canvas.height/this._resolution-o-2*s,l=i.slice(),c=t.fillGradientStops.slice();if(!c.length)for(var h=l.length+1,f=1;f<h;++f)c.push(f/h);if(l.unshift(i[0]),c.unshift(0),l.push(i[i.length-1]),c.push(1),t.fillGradientType===Qe.LINEAR_VERTICAL){r=this.context.createLinearGradient(a/2,s,a/2,u+s);var d=n.fontProperties.fontSize+t.strokeThickness;for(f=0;f<e.length;f++){var p=n.lineHeight*(f-1)+d,m=n.lineHeight*f,v=m;f>0&&p>m&&(v=(m+p)/2);var g=m+d,_=n.lineHeight*(f+1),y=g;f+1<e.length&&_<g&&(y=(g+_)/2);for(var b=(y-v)/u,E=0;E<l.length;E++){var T=0;T="number"===typeof c[E]?c[E]:E/l.length;var x=Math.min(1,Math.max(0,v/u+T*b));x=Number(x.toFixed(5)),r.addColorStop(x,l[E])}}}else{r=this.context.createLinearGradient(s,u/2,a+s,u/2);var S=l.length+1,R=1;for(f=0;f<l.length;f++){var A=void 0;A="number"===typeof c[f]?c[f]:R/S,r.addColorStop(A,l[f]),R++}}return r},e.prototype.destroy=function(e){"boolean"===typeof e&&(e={children:e}),e=Object.assign({},In,e),t.prototype.destroy.call(this,e),this._ownCanvas&&(this.canvas.height=this.canvas.width=0),this.context=null,this.canvas=null,this._style=null},Object.defineProperty(e.prototype,"width",{get:function(){return this.updateText(!0),Math.abs(this.scale.x)*this._texture.orig.width},set:function(t){this.updateText(!0);var e=(0,O.Xx)(this.scale.x)||1;this.scale.x=e*t/this._texture.orig.width,this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.updateText(!0),Math.abs(this.scale.y)*this._texture.orig.height},set:function(t){this.updateText(!0);var e=(0,O.Xx)(this.scale.y)||1;this.scale.y=e*t/this._texture.orig.height,this._height=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"style",{get:function(){return this._style},set:function(t){t=t||{},this._style=t instanceof En?t:new En(t),this.localStyleID=-1,this.dirty=!0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this._text},set:function(t){t=String(null===t||void 0===t?"":t),this._text!==t&&(this._text=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"resolution",{get:function(){return this._resolution},set:function(t){this._autoResolution=!1,this._resolution!==t&&(this._resolution=t,this.dirty=!0)},enumerable:!1,configurable:!0}),e.nextLineHeightBehavior=!1,e.experimentalLetterSpacing=!1,e}(vn.j); -/*! - * @pixi/prepare - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/prepare is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -Le.X.UPLOADS_PER_FRAME=4; -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ -var Cn=function(t,e){return Cn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Cn(t,e)};function Pn(t,e){function n(){this.constructor=t}Cn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Nn=function(){function t(t){this.maxItemsPerFrame=t,this.itemsLeft=0}return t.prototype.beginFrame=function(){this.itemsLeft=this.maxItemsPerFrame},t.prototype.allowedToUpload=function(){return this.itemsLeft-- >0},t}();function Mn(t,e){var n=!1;if(t&&t._textures&&t._textures.length)for(var r=0;r<t._textures.length;r++)if(t._textures[r]instanceof J.xE){var i=t._textures[r].baseTexture;-1===e.indexOf(i)&&(e.push(i),n=!0)}return n}function Dn(t,e){if(t.baseTexture instanceof J.VL){var n=t.baseTexture;return-1===e.indexOf(n)&&e.push(n),!0}return!1}function Ln(t,e){if(t._texture&&t._texture instanceof J.xE){var n=t._texture.baseTexture;return-1===e.indexOf(n)&&e.push(n),!0}return!1}function Bn(t,e){return e instanceof wn&&(e.updateText(!0),!0)}function Fn(t,e){if(e instanceof En){var n=e.toFontString();return An.measureFont(n),!0}return!1}function Un(t,e){if(t instanceof wn){-1===e.indexOf(t.style)&&e.push(t.style),-1===e.indexOf(t)&&e.push(t);var n=t._texture.baseTexture;return-1===e.indexOf(n)&&e.push(n),!0}return!1}function Gn(t,e){return t instanceof En&&(-1===e.indexOf(t)&&e.push(t),!0)}var kn=function(){function t(t){var e=this;this.limiter=new Nn(Le.X.UPLOADS_PER_FRAME),this.renderer=t,this.uploadHookHelper=null,this.queue=[],this.addHooks=[],this.uploadHooks=[],this.completes=[],this.ticking=!1,this.delayedTick=function(){e.queue&&e.prepareItems()},this.registerFindHook(Un),this.registerFindHook(Gn),this.registerFindHook(Mn),this.registerFindHook(Dn),this.registerFindHook(Ln),this.registerUploadHook(Bn),this.registerUploadHook(Fn)}return t.prototype.upload=function(t,e){"function"===typeof t&&(e=t,t=null),t&&this.add(t),this.queue.length?(e&&this.completes.push(e),this.ticking||(this.ticking=!0,X.vB.system.addOnce(this.tick,this,X.uF.UTILITY))):e&&e()},t.prototype.tick=function(){setTimeout(this.delayedTick,0)},t.prototype.prepareItems=function(){this.limiter.beginFrame();while(this.queue.length&&this.limiter.allowedToUpload()){var t=this.queue[0],e=!1;if(t&&!t._destroyed)for(var n=0,r=this.uploadHooks.length;n<r;n++)if(this.uploadHooks[n](this.uploadHookHelper,t)){this.queue.shift(),e=!0;break}e||this.queue.shift()}if(this.queue.length)X.vB.system.addOnce(this.tick,this,X.uF.UTILITY);else{this.ticking=!1;var i=this.completes.slice(0);this.completes.length=0;for(n=0,r=i.length;n<r;n++)i[n]()}},t.prototype.registerFindHook=function(t){return t&&this.addHooks.push(t),this},t.prototype.registerUploadHook=function(t){return t&&this.uploadHooks.push(t),this},t.prototype.add=function(t){for(var e=0,n=this.addHooks.length;e<n;e++)if(this.addHooks[e](t,this.queue))break;if(t instanceof I.W2)for(e=t.children.length-1;e>=0;e--)this.add(t.children[e]);return this},t.prototype.destroy=function(){this.ticking&&X.vB.system.remove(this.tick,this),this.ticking=!1,this.addHooks=null,this.uploadHooks=null,this.renderer=null,this.completes=null,this.queue=null,this.limiter=null,this.uploadHookHelper=null},t}();function Xn(t,e){return e instanceof J.VL&&(e._glTextures[t.CONTEXT_UID]||t.texture.bind(e),!0)}function Hn(t,e){if(!(e instanceof mn))return!1;var n=e.geometry;e.finishPoly(),n.updateBatches();for(var r=n.batches,i=0;i<r.length;i++){var o=r[i].style.texture;o&&Xn(t,o.baseTexture)}return n.batchable||t.geometry.bind(n,e._resolveDirectShader(t)),!0}function jn(t,e){return t instanceof mn&&(e.push(t),!0)}var Vn=function(t){function e(e){var n=t.call(this,e)||this;return n.uploadHookHelper=n.renderer,n.registerFindHook(jn),n.registerUploadHook(Xn),n.registerUploadHook(Hn),n}return Pn(e,t),e}(kn),Yn=(function(){function t(t){this.maxMilliseconds=t,this.frameStart=0}t.prototype.beginFrame=function(){this.frameStart=Date.now()},t.prototype.allowedToUpload=function(){return Date.now()-this.frameStart<this.maxMilliseconds}}(),function(){function t(t,e,n){void 0===n&&(n=null),this._texture=t instanceof J.xE?t:null,this.baseTexture=t instanceof J.VL?t:this._texture.baseTexture,this.textures={},this.animations={},this.data=e;var r=this.baseTexture.resource;this.resolution=this._updateResolution(n||(r?r.url:null)),this._frames=this.data.frames,this._frameKeys=Object.keys(this._frames),this._batchIndex=0,this._callback=null}return t.prototype._updateResolution=function(t){void 0===t&&(t=null);var e=this.data.meta.scale,n=(0,O.fL)(t,null);return null===n&&(n=void 0!==e?parseFloat(e):1),1!==n&&this.baseTexture.setResolution(n),n},t.prototype.parse=function(e){this._batchIndex=0,this._callback=e,this._frameKeys.length<=t.BATCH_SIZE?(this._processFrames(0),this._processAnimations(),this._parseComplete()):this._nextBatch()},t.prototype._processFrames=function(e){var n=e,r=t.BATCH_SIZE;while(n-e<r&&n<this._frameKeys.length){var i=this._frameKeys[n],o=this._frames[i],s=o.frame;if(s){var a=null,u=null,l=!1!==o.trimmed&&o.sourceSize?o.sourceSize:o.frame,c=new k.Ae(0,0,Math.floor(l.w)/this.resolution,Math.floor(l.h)/this.resolution);a=o.rotated?new k.Ae(Math.floor(s.x)/this.resolution,Math.floor(s.y)/this.resolution,Math.floor(s.h)/this.resolution,Math.floor(s.w)/this.resolution):new k.Ae(Math.floor(s.x)/this.resolution,Math.floor(s.y)/this.resolution,Math.floor(s.w)/this.resolution,Math.floor(s.h)/this.resolution),!1!==o.trimmed&&o.spriteSourceSize&&(u=new k.Ae(Math.floor(o.spriteSourceSize.x)/this.resolution,Math.floor(o.spriteSourceSize.y)/this.resolution,Math.floor(s.w)/this.resolution,Math.floor(s.h)/this.resolution)),this.textures[i]=new J.xE(this.baseTexture,a,c,u,o.rotated?2:0,o.anchor),J.xE.addToCache(this.textures[i],i)}n++}},t.prototype._processAnimations=function(){var t=this.data.animations||{};for(var e in t){this.animations[e]=[];for(var n=0;n<t[e].length;n++){var r=t[e][n];this.animations[e].push(this.textures[r])}}},t.prototype._parseComplete=function(){var t=this._callback;this._callback=null,this._batchIndex=0,t.call(this,this.textures)},t.prototype._nextBatch=function(){var e=this;this._processFrames(this._batchIndex*t.BATCH_SIZE),this._batchIndex++,setTimeout((function(){e._batchIndex*t.BATCH_SIZE<e._frameKeys.length?e._nextBatch():(e._processAnimations(),e._parseComplete())}),0)},t.prototype.destroy=function(t){var e;for(var n in void 0===t&&(t=!1),this.textures)this.textures[n].destroy();this._frames=null,this._frameKeys=null,this.data=null,this.textures=null,t&&(null===(e=this._texture)||void 0===e||e.destroy(),this.baseTexture.destroy()),this._texture=null,this.baseTexture=null},t.BATCH_SIZE=1e3,t}()),Wn=function(){function t(){}return t.use=function(e,n){var r,i,o=this,s=e.name+"_image";if(e.data&&e.type===_t.TYPE.JSON&&e.data.frames&&!o.resources[s]){var a=null===(i=null===(r=e.data)||void 0===r?void 0:r.meta)||void 0===i?void 0:i.related_multi_packs;if(Array.isArray(a))for(var u=function(t){if("string"!==typeof t)return"continue";var n=t.replace(".json",""),r=O.HQ.resolve(e.url.replace(o.baseUrl,""),t);if(o.resources[n]||Object.values(o.resources).some((function(t){return O.HQ.format(O.HQ.parse(t.url))===r})))return"continue";var i={crossOrigin:e.crossOrigin,loadType:_t.LOAD_TYPE.XHR,xhrType:_t.XHR_RESPONSE_TYPE.JSON,parentResource:e,metadata:e.metadata};o.add(n,r,i)},l=0,c=a;l<c.length;l++){var h=c[l];u(h)}var f={crossOrigin:e.crossOrigin,metadata:e.metadata.imageMetadata,parentResource:e},d=t.getResourcePath(e,o.baseUrl);o.add(s,d,f,(function(t){if(t.error)n(t.error);else{var r=new Yn(t.texture,e.data,e.url);r.parse((function(){e.spritesheet=r,e.textures=r.textures,n()}))}}))}else n()},t.getResourcePath=function(t,e){return t.isDataUrl?t.data.meta.image:O.HQ.resolve(t.url.replace(e,""),t.data.meta.image)},t}(),zn=function(t,e){return zn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},zn(t,e)};function $n(t,e){function n(){this.constructor=t}zn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var qn=new k.E9,Kn=(function(t){function e(e,n,r){void 0===n&&(n=100),void 0===r&&(r=100);var i=t.call(this,e)||this;return i.tileTransform=new k.wx,i._width=n,i._height=r,i.uvMatrix=i.texture.uvMatrix||new J.UX(e),i.pluginName="tilingSprite",i.uvRespectAnchor=!1,i}$n(e,t),Object.defineProperty(e.prototype,"clampMargin",{get:function(){return this.uvMatrix.clampMargin},set:function(t){this.uvMatrix.clampMargin=t,this.uvMatrix.update(!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tileScale",{get:function(){return this.tileTransform.scale},set:function(t){this.tileTransform.scale.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tilePosition",{get:function(){return this.tileTransform.position},set:function(t){this.tileTransform.position.copyFrom(t)},enumerable:!1,configurable:!0}),e.prototype._onTextureUpdate=function(){this.uvMatrix&&(this.uvMatrix.texture=this._texture),this._cachedTint=16777215},e.prototype._render=function(t){var e=this._texture;e&&e.valid&&(this.tileTransform.updateLocalTransform(),this.uvMatrix.update(),t.batch.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this))},e.prototype._calculateBounds=function(){var t=this._width*-this._anchor._x,e=this._height*-this._anchor._y,n=this._width*(1-this._anchor._x),r=this._height*(1-this._anchor._y);this._bounds.addFrame(this.transform,t,e,n,r)},e.prototype.getLocalBounds=function(e){return 0===this.children.length?(this._bounds.minX=this._width*-this._anchor._x,this._bounds.minY=this._height*-this._anchor._y,this._bounds.maxX=this._width*(1-this._anchor._x),this._bounds.maxY=this._height*(1-this._anchor._y),e||(this._localBoundsRect||(this._localBoundsRect=new k.Ae),e=this._localBoundsRect),this._bounds.getRectangle(e)):t.prototype.getLocalBounds.call(this,e)},e.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,qn);var e=this._width,n=this._height,r=-e*this.anchor._x;if(qn.x>=r&&qn.x<r+e){var i=-n*this.anchor._y;if(qn.y>=i&&qn.y<i+n)return!0}return!1},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this.tileTransform=null,this.uvMatrix=null},e.from=function(t,n){var r=t instanceof J.xE?t:J.xE.from(t,n);return new e(r,n.width,n.height)},Object.defineProperty(e.prototype,"width",{get:function(){return this._width},set:function(t){this._width=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this._height},set:function(t){this._height=t},enumerable:!1,configurable:!0})}(vn.j),"#version 100\n#define SHADER_NAME Tiling-Sprite-Simple-100\n\nprecision lowp float;\n\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\n\nvoid main(void)\n{\n vec4 texSample = texture2D(uSampler, vTextureCoord);\n gl_FragColor = texSample * uColor;\n}\n"),Zn="#version 100\n#define SHADER_NAME Tiling-Sprite-100\n\nprecision lowp float;\n\nattribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n",Jn="#version 100\n#ifdef GL_EXT_shader_texture_lod\n #extension GL_EXT_shader_texture_lod : enable\n#endif\n#define SHADER_NAME Tiling-Sprite-100\n\nprecision lowp float;\n\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\nuniform mat3 uMapCoord;\nuniform vec4 uClampFrame;\nuniform vec2 uClampOffset;\n\nvoid main(void)\n{\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\n vec2 unclamped = coord;\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\n\n #ifdef GL_EXT_shader_texture_lod\n vec4 texSample = unclamped == coord\n ? texture2D(uSampler, coord) \n : texture2DLodEXT(uSampler, coord, 0);\n #else\n vec4 texSample = texture2D(uSampler, coord);\n #endif\n\n gl_FragColor = texSample * uColor;\n}\n",Qn="#version 300 es\n#define SHADER_NAME Tiling-Sprite-300\n\nprecision lowp float;\n\nin vec2 aVertexPosition;\nin vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nout vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n",tr="#version 300 es\n#define SHADER_NAME Tiling-Sprite-100\n\nprecision lowp float;\n\nin vec2 vTextureCoord;\n\nout vec4 fragmentColor;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\nuniform mat3 uMapCoord;\nuniform vec4 uClampFrame;\nuniform vec2 uClampOffset;\n\nvoid main(void)\n{\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\n vec2 unclamped = coord;\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\n\n vec4 texSample = texture(uSampler, coord, unclamped == coord ? 0.0f : -32.0f);// lod-bias very negative to force lod 0\n\n fragmentColor = texSample * uColor;\n}\n",er=new k.y3,nr=function(t){function e(e){var n=t.call(this,e)||this;return e.runners.contextChange.add(n),n.quad=new J.ud,n.state=J.ZM.for2d(),n}return $n(e,t),e.prototype.contextChange=function(){var t=this.renderer,e={globals:t.globalUniforms};this.simpleShader=J.ex.from(Zn,Kn,e),this.shader=t.context.webGLVersion>1?J.ex.from(Qn,tr,e):J.ex.from(Zn,Jn,e)},e.prototype.render=function(t){var e=this.renderer,n=this.quad,r=n.vertices;r[0]=r[6]=t._width*-t.anchor.x,r[1]=r[3]=t._height*-t.anchor.y,r[2]=r[4]=t._width*(1-t.anchor.x),r[5]=r[7]=t._height*(1-t.anchor.y);var i=t.uvRespectAnchor?t.anchor.x:0,o=t.uvRespectAnchor?t.anchor.y:0;r=n.uvs,r[0]=r[6]=-i,r[1]=r[3]=-o,r[2]=r[4]=1-i,r[5]=r[7]=1-o,n.invalidate();var s=t._texture,a=s.baseTexture,u=t.tileTransform.localTransform,l=t.uvMatrix,c=a.isPowerOfTwo&&s.frame.width===a.width&&s.frame.height===a.height;c&&(a._glTextures[e.CONTEXT_UID]?c=a.wrapMode!==Dt.Nt.CLAMP:a.wrapMode===Dt.Nt.CLAMP&&(a.wrapMode=Dt.Nt.REPEAT));var h=c?this.simpleShader:this.shader,f=s.width,d=s.height,p=t._width,m=t._height;er.set(u.a*f/p,u.b*f/m,u.c*d/p,u.d*d/m,u.tx/p,u.ty/m),er.invert(),c?er.prepend(l.mapCoord):(h.uniforms.uMapCoord=l.mapCoord.toArray(!0),h.uniforms.uClampFrame=l.uClampFrame,h.uniforms.uClampOffset=l.uClampOffset),h.uniforms.uTransform=er.toArray(!0),h.uniforms.uColor=(0,O.GT)(t.tint,t.worldAlpha,h.uniforms.uColor,a.alphaMode),h.uniforms.translationMatrix=t.transform.worldTransform.toArray(!0),h.uniforms.uSampler=s,e.shader.bind(h),e.geometry.bind(n),this.state.blendMode=(0,O.D)(t.blendMode,a.alphaMode),e.state.set(this.state),e.geometry.draw(this.renderer.gl.TRIANGLES,6,0)},e}(J.bO),rr=function(t,e){return rr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},rr(t,e)};function ir(t,e){function n(){this.constructor=t}rr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var or=function(){function t(t,e){this.uvBuffer=t,this.uvMatrix=e,this.data=null,this._bufferUpdateId=-1,this._textureUpdateId=-1,this._updateID=0}return t.prototype.update=function(t){if(t||this._bufferUpdateId!==this.uvBuffer._updateID||this._textureUpdateId!==this.uvMatrix._updateID){this._bufferUpdateId=this.uvBuffer._updateID,this._textureUpdateId=this.uvMatrix._updateID;var e=this.uvBuffer.data;this.data&&this.data.length===e.length||(this.data=new Float32Array(e.length)),this.uvMatrix.multiplyUvs(e,this.data),this._updateID++}},t}(),sr=new k.E9,ar=new k.mg,ur=function(t){function e(e,n,r,i){void 0===i&&(i=Dt.lg.TRIANGLES);var o=t.call(this)||this;return o.geometry=e,o.shader=n,o.state=r||J.ZM.for2d(),o.drawMode=i,o.start=0,o.size=0,o.uvs=null,o.indices=null,o.vertexData=new Float32Array(1),o.vertexDirty=-1,o._transformID=-1,o._roundPixels=Le.X.ROUND_PIXELS,o.batchUvs=null,o}return ir(e,t),Object.defineProperty(e.prototype,"geometry",{get:function(){return this._geometry},set:function(t){this._geometry!==t&&(this._geometry&&(this._geometry.refCount--,0===this._geometry.refCount&&this._geometry.dispose()),this._geometry=t,this._geometry&&this._geometry.refCount++,this.vertexDirty=-1)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"uvBuffer",{get:function(){return this.geometry.buffers[1]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"verticesBuffer",{get:function(){return this.geometry.buffers[0]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"material",{get:function(){return this.shader},set:function(t){this.shader=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.state.blendMode},set:function(t){this.state.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"roundPixels",{get:function(){return this._roundPixels},set:function(t){this._roundPixels!==t&&(this._transformID=-1),this._roundPixels=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return"tint"in this.shader?this.shader.tint:null},set:function(t){this.shader.tint=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"texture",{get:function(){return"texture"in this.shader?this.shader.texture:null},set:function(t){this.shader.texture=t},enumerable:!1,configurable:!0}),e.prototype._render=function(t){var n=this.geometry.buffers[0].data,r=this.shader;r.batchable&&this.drawMode===Dt.lg.TRIANGLES&&n.length<2*e.BATCHABLE_SIZE?this._renderToBatch(t):this._renderDefault(t)},e.prototype._renderDefault=function(t){var e=this.shader;e.alpha=this.worldAlpha,e.update&&e.update(),t.batch.flush(),e.uniforms.translationMatrix=this.transform.worldTransform.toArray(!0),t.shader.bind(e),t.state.set(this.state),t.geometry.bind(this.geometry,e),t.geometry.draw(this.drawMode,this.size,this.start,this.geometry.instanceCount)},e.prototype._renderToBatch=function(t){var e=this.geometry,n=this.shader;n.uvMatrix&&(n.uvMatrix.update(),this.calculateUvs()),this.calculateVertices(),this.indices=e.indexBuffer.data,this._tintRGB=n._tintRGB,this._texture=n.texture;var r=this.material.pluginName;t.batch.setObjectRenderer(t.plugins[r]),t.plugins[r].render(this)},e.prototype.calculateVertices=function(){var t=this.geometry,e=t.buffers[0],n=e.data,r=e._updateID;if(r!==this.vertexDirty||this._transformID!==this.transform._worldID){this._transformID=this.transform._worldID,this.vertexData.length!==n.length&&(this.vertexData=new Float32Array(n.length));for(var i=this.transform.worldTransform,o=i.a,s=i.b,a=i.c,u=i.d,l=i.tx,c=i.ty,h=this.vertexData,f=0;f<h.length/2;f++){var d=n[2*f],p=n[2*f+1];h[2*f]=o*d+a*p+l,h[2*f+1]=s*d+u*p+c}if(this._roundPixels){var m=Le.X.RESOLUTION;for(f=0;f<h.length;++f)h[f]=Math.round((h[f]*m|0)/m)}this.vertexDirty=r}},e.prototype.calculateUvs=function(){var t=this.geometry.buffers[1],e=this.shader;e.uvMatrix.isSimple?this.uvs=t.data:(this.batchUvs||(this.batchUvs=new or(t,e.uvMatrix)),this.batchUvs.update(),this.uvs=this.batchUvs.data)},e.prototype._calculateBounds=function(){this.calculateVertices(),this._bounds.addVertexData(this.vertexData,0,this.vertexData.length)},e.prototype.containsPoint=function(t){if(!this.getBounds().contains(t.x,t.y))return!1;this.worldTransform.applyInverse(t,sr);for(var e=this.geometry.getBuffer("aVertexPosition").data,n=ar.points,r=this.geometry.getIndex().data,i=r.length,o=4===this.drawMode?3:1,s=0;s+2<i;s+=o){var a=2*r[s],u=2*r[s+1],l=2*r[s+2];if(n[0]=e[a],n[1]=e[a+1],n[2]=e[u],n[3]=e[u+1],n[4]=e[l],n[5]=e[l+1],ar.contains(sr.x,sr.y))return!0}return!1},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e),this._cachedTexture&&(this._cachedTexture.destroy(),this._cachedTexture=null),this.geometry=null,this.shader=null,this.state=null,this.uvs=null,this.indices=null,this.vertexData=null},e.BATCHABLE_SIZE=100,e}(I.W2),lr="varying vec2 vTextureCoord;\nuniform vec4 uColor;\n\nuniform sampler2D uSampler;\n\nvoid main(void)\n{\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uColor;\n}\n",cr="attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTextureMatrix;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\n}\n",hr=function(t){function e(e,n){var r=this,i={uSampler:e,alpha:1,uTextureMatrix:k.y3.IDENTITY,uColor:new Float32Array([1,1,1,1])};return n=Object.assign({tint:16777215,alpha:1,pluginName:"batch"},n),n.uniforms&&Object.assign(i,n.uniforms),r=t.call(this,n.program||J.$r.from(cr,lr),i)||this,r._colorDirty=!1,r.uvMatrix=new J.UX(e),r.batchable=void 0===n.program,r.pluginName=n.pluginName,r.tint=n.tint,r.alpha=n.alpha,r}return ir(e,t),Object.defineProperty(e.prototype,"texture",{get:function(){return this.uniforms.uSampler},set:function(t){this.uniforms.uSampler!==t&&(this.uniforms.uSampler=t,this.uvMatrix.texture=t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alpha",{get:function(){return this._alpha},set:function(t){t!==this._alpha&&(this._alpha=t,this._colorDirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){t!==this._tint&&(this._tint=t,this._tintRGB=(t>>16)+(65280&t)+((255&t)<<16),this._colorDirty=!0)},enumerable:!1,configurable:!0}),e.prototype.update=function(){if(this._colorDirty){this._colorDirty=!1;var t=this.texture.baseTexture;(0,O.GT)(this._tint,this._alpha,this.uniforms.uColor,t.alphaMode)}this.uvMatrix.update()&&(this.uniforms.uTextureMatrix=this.uvMatrix.mapCoord)},e}(J.ex),fr=function(t){function e(e,n,r){var i=t.call(this)||this,o=new J.lW(e),s=new J.lW(n,!0),a=new J.lW(r,!0,!0);return i.addAttribute("aVertexPosition",o,2,!1,Dt.vK.FLOAT).addAttribute("aTextureCoord",s,2,!1,Dt.vK.FLOAT).addIndex(a),i._updateId=-1,i}return ir(e,t),Object.defineProperty(e.prototype,"vertexDirtyId",{get:function(){return this.buffers[0]._updateID},enumerable:!1,configurable:!0}),e}(J.ZX),dr=function(t,e){return dr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},dr(t,e)};function pr(t,e){function n(){this.constructor=t}dr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var mr=function(){function t(){this.info=[],this.common=[],this.page=[],this.char=[],this.kerning=[],this.distanceField=[]}return t}(),vr=function(){function t(){}return t.test=function(t){return"string"===typeof t&&0===t.indexOf("info face=")},t.parse=function(t){var e=t.match(/^[a-z]+\s+.+$/gm),n={info:[],common:[],page:[],char:[],chars:[],kerning:[],kernings:[],distanceField:[]};for(var r in e){var i=e[r].match(/^[a-z]+/gm)[0],o=e[r].match(/[a-zA-Z]+=([^\s"']+|"([^"]*)")/gm),s={};for(var a in o){var u=o[a].split("="),l=u[0],c=u[1].replace(/"/gm,""),h=parseFloat(c),f=isNaN(h)?c:h;s[l]=f}n[i].push(s)}var d=new mr;return n.info.forEach((function(t){return d.info.push({face:t.face,size:parseInt(t.size,10)})})),n.common.forEach((function(t){return d.common.push({lineHeight:parseInt(t.lineHeight,10)})})),n.page.forEach((function(t){return d.page.push({id:parseInt(t.id,10),file:t.file})})),n.char.forEach((function(t){return d.char.push({id:parseInt(t.id,10),page:parseInt(t.page,10),x:parseInt(t.x,10),y:parseInt(t.y,10),width:parseInt(t.width,10),height:parseInt(t.height,10),xoffset:parseInt(t.xoffset,10),yoffset:parseInt(t.yoffset,10),xadvance:parseInt(t.xadvance,10)})})),n.kerning.forEach((function(t){return d.kerning.push({first:parseInt(t.first,10),second:parseInt(t.second,10),amount:parseInt(t.amount,10)})})),n.distanceField.forEach((function(t){return d.distanceField.push({distanceRange:parseInt(t.distanceRange,10),fieldType:t.fieldType})})),d},t}(),gr=function(){function t(){}return t.test=function(t){return t instanceof XMLDocument&&t.getElementsByTagName("page").length&&null!==t.getElementsByTagName("info")[0].getAttribute("face")},t.parse=function(t){for(var e=new mr,n=t.getElementsByTagName("info"),r=t.getElementsByTagName("common"),i=t.getElementsByTagName("page"),o=t.getElementsByTagName("char"),s=t.getElementsByTagName("kerning"),a=t.getElementsByTagName("distanceField"),u=0;u<n.length;u++)e.info.push({face:n[u].getAttribute("face"),size:parseInt(n[u].getAttribute("size"),10)});for(u=0;u<r.length;u++)e.common.push({lineHeight:parseInt(r[u].getAttribute("lineHeight"),10)});for(u=0;u<i.length;u++)e.page.push({id:parseInt(i[u].getAttribute("id"),10)||0,file:i[u].getAttribute("file")});for(u=0;u<o.length;u++){var l=o[u];e.char.push({id:parseInt(l.getAttribute("id"),10),page:parseInt(l.getAttribute("page"),10)||0,x:parseInt(l.getAttribute("x"),10),y:parseInt(l.getAttribute("y"),10),width:parseInt(l.getAttribute("width"),10),height:parseInt(l.getAttribute("height"),10),xoffset:parseInt(l.getAttribute("xoffset"),10),yoffset:parseInt(l.getAttribute("yoffset"),10),xadvance:parseInt(l.getAttribute("xadvance"),10)})}for(u=0;u<s.length;u++)e.kerning.push({first:parseInt(s[u].getAttribute("first"),10),second:parseInt(s[u].getAttribute("second"),10),amount:parseInt(s[u].getAttribute("amount"),10)});for(u=0;u<a.length;u++)e.distanceField.push({fieldType:a[u].getAttribute("fieldType"),distanceRange:parseInt(a[u].getAttribute("distanceRange"),10)});return e},t}(),_r=function(){function t(){}return t.test=function(t){if("string"===typeof t&&t.indexOf("<font>")>-1){var e=(new globalThis.DOMParser).parseFromString(t,"text/xml");return gr.test(e)}return!1},t.parse=function(t){var e=(new globalThis.DOMParser).parseFromString(t,"text/xml");return gr.parse(e)},t}(),yr=[vr,gr,_r];function br(t){for(var e=0;e<yr.length;e++)if(yr[e].test(t))return yr[e];return null}function Er(t,e,n,r,i,o){var s,a=n.fill;if(!Array.isArray(a))return a;if(1===a.length)return a[0];var u=n.dropShadow?n.dropShadowDistance:0,l=n.padding||0,c=t.width/r-u-2*l,h=t.height/r-u-2*l,f=a.slice(),d=n.fillGradientStops.slice();if(!d.length)for(var p=f.length+1,m=1;m<p;++m)d.push(m/p);if(f.unshift(a[0]),d.unshift(0),f.push(a[a.length-1]),d.push(1),n.fillGradientType===Qe.LINEAR_VERTICAL){s=e.createLinearGradient(c/2,l,c/2,h+l);var v=0,g=o.fontProperties.fontSize+n.strokeThickness,_=g/h;for(m=0;m<i.length;m++)for(var y=o.lineHeight*m,b=0;b<f.length;b++){var E=0;E="number"===typeof d[b]?d[b]:b/f.length;var T=y/h+E*_,x=Math.max(v,T);x=Math.min(x,1),s.addColorStop(x,f[b]),v=x}}else{s=e.createLinearGradient(l,h/2,c+l,h/2);var S=f.length+1,R=1;for(m=0;m<f.length;m++){var A=void 0;A="number"===typeof d[m]?d[m]:R/S,s.addColorStop(A,f[m]),R++}}return s}function Tr(t,e,n,r,i,o,s){var a=n.text,u=n.fontProperties;e.translate(r,i),e.scale(o,o);var l=s.strokeThickness/2,c=-s.strokeThickness/2;if(e.font=s.toFontString(),e.lineWidth=s.strokeThickness,e.textBaseline=s.textBaseline,e.lineJoin=s.lineJoin,e.miterLimit=s.miterLimit,e.fillStyle=Er(t,e,s,o,[a],n),e.strokeStyle=s.stroke,s.dropShadow){var h=s.dropShadowColor,f=(0,O.wK)("number"===typeof h?h:(0,O.qm)(h)),d=s.dropShadowBlur*o,p=s.dropShadowDistance*o;e.shadowColor="rgba("+255*f[0]+","+255*f[1]+","+255*f[2]+","+s.dropShadowAlpha+")",e.shadowBlur=d,e.shadowOffsetX=Math.cos(s.dropShadowAngle)*p,e.shadowOffsetY=Math.sin(s.dropShadowAngle)*p}else e.shadowColor="black",e.shadowBlur=0,e.shadowOffsetX=0,e.shadowOffsetY=0;s.stroke&&s.strokeThickness&&e.strokeText(a,l,c+n.lineHeight-u.descent),s.fill&&e.fillText(a,l,c+n.lineHeight-u.descent),e.setTransform(1,0,0,1,0,0),e.fillStyle="rgba(0, 0, 0, 0)"}function xr(t){return Array.from?Array.from(t):t.split("")}function Sr(t){"string"===typeof t&&(t=[t]);for(var e=[],n=0,r=t.length;n<r;n++){var i=t[n];if(Array.isArray(i)){if(2!==i.length)throw new Error("[BitmapFont]: Invalid character range length, expecting 2 got "+i.length+".");var o=i[0].charCodeAt(0),s=i[1].charCodeAt(0);if(s<o)throw new Error("[BitmapFont]: Invalid character range.");for(var a=o,u=s;a<=u;a++)e.push(String.fromCharCode(a))}else e.push.apply(e,xr(i))}if(0===e.length)throw new Error("[BitmapFont]: Empty set when resolving characters.");return e}function Rr(t){return t.codePointAt?t.codePointAt(0):t.charCodeAt(0)}var Ar=function(){function t(t,e,n){var r,i,o=t.info[0],s=t.common[0],a=t.page[0],u=t.distanceField[0],l=(0,O.fL)(a.file),c={};this._ownsTextures=n,this.font=o.face,this.size=o.size,this.lineHeight=s.lineHeight/l,this.chars={},this.pageTextures=c;for(var h=0;h<t.page.length;h++){var f=t.page[h],d=f.id,p=f.file;c[d]=e instanceof Array?e[h]:e[p],(null===u||void 0===u?void 0:u.fieldType)&&"none"!==u.fieldType&&(c[d].baseTexture.alphaMode=Dt.iw.NO_PREMULTIPLIED_ALPHA)}for(h=0;h<t.char.length;h++){var m=t.char[h],v=(d=m.id,m.page),g=t.char[h],_=g.x,y=g.y,b=g.width,E=g.height,T=g.xoffset,x=g.yoffset,S=g.xadvance;_/=l,y/=l,b/=l,E/=l,T/=l,x/=l,S/=l;var R=new k.Ae(_+c[v].frame.x/l,y+c[v].frame.y/l,b,E);this.chars[d]={xOffset:T,yOffset:x,xAdvance:S,kerning:{},texture:new J.xE(c[v].baseTexture,R),page:v}}for(h=0;h<t.kerning.length;h++){var A=t.kerning[h],I=A.first,w=A.second,C=A.amount;I/=l,w/=l,C/=l,this.chars[w]&&(this.chars[w].kerning[I]=C)}this.distanceFieldRange=null===u||void 0===u?void 0:u.distanceRange,this.distanceFieldType=null!==(i=null===(r=null===u||void 0===u?void 0:u.fieldType)||void 0===r?void 0:r.toLowerCase())&&void 0!==i?i:"none"}return t.prototype.destroy=function(){for(var t in this.chars)this.chars[t].texture.destroy(),this.chars[t].texture=null;for(var t in this.pageTextures)this._ownsTextures&&this.pageTextures[t].destroy(!0),this.pageTextures[t]=null;this.chars=null,this.pageTextures=null},t.install=function(e,n,r){var i;if(e instanceof mr)i=e;else{var o=br(e);if(!o)throw new Error("Unrecognized data format for font.");i=o.parse(e)}n instanceof J.xE&&(n=[n]);var s=new t(i,n,r);return t.available[s.font]=s,s},t.uninstall=function(e){var n=t.available[e];if(!n)throw new Error("No font found named '"+e+"'");n.destroy(),delete t.available[e]},t.from=function(e,n,r){if(!e)throw new Error("[BitmapFont] Property `name` is required.");var i=Object.assign({},t.defaultOptions,r),o=i.chars,s=i.padding,a=i.resolution,u=i.textureWidth,l=i.textureHeight,c=Sr(o),h=n instanceof En?n:new En(n),f=u,d=new mr;d.info[0]={face:h.fontFamily,size:h.fontSize},d.common[0]={lineHeight:h.fontSize};for(var p,m,v,g=0,_=0,y=0,b=[],E=0;E<c.length;E++){p||(p=document.createElement("canvas"),p.width=u,p.height=l,m=p.getContext("2d"),v=new J.VL(p,{resolution:a}),b.push(new J.xE(v)),d.page.push({id:b.length-1,file:""}));var T=An.measureText(c[E],h,!1,p),x=T.width,S=Math.ceil(T.height),R=Math.ceil(("italic"===h.fontStyle?2:1)*x);if(_>=l-S*a){if(0===_)throw new Error("[BitmapFont] textureHeight "+l+"px is too small for "+h.fontSize+"px fonts");--E,p=null,m=null,v=null,_=0,g=0,y=0}else if(y=Math.max(S+T.fontProperties.descent,y),R*a+g>=f)--E,_+=y*a,_=Math.ceil(_),g=0,y=0;else{Tr(p,m,T,g,_,a,h);var A=Rr(T.text);d.char.push({id:A,page:b.length-1,x:g/a,y:_/a,width:R,height:S,xoffset:0,yoffset:0,xadvance:Math.ceil(x-(h.dropShadow?h.dropShadowDistance:0)-(h.stroke?h.strokeThickness:0))}),g+=(R+2*s)*a,g=Math.ceil(g)}}E=0;for(var O=c.length;E<O;E++)for(var I=c[E],w=0;w<O;w++){var C=c[w],P=m.measureText(I).width,N=m.measureText(C).width,M=m.measureText(I+C).width,D=M-(P+N);D&&d.kerning.push({first:Rr(I),second:Rr(C),amount:D})}var L=new t(d,b,!0);return void 0!==t.available[e]&&t.uninstall(e),t.available[e]=L,L},t.ALPHA=[["a","z"],["A","Z"]," "],t.NUMERIC=[["0","9"]],t.ALPHANUMERIC=[["a","z"],["A","Z"],["0","9"]," "],t.ASCII=[[" ","~"]],t.defaultOptions={resolution:1,textureWidth:512,textureHeight:512,padding:4,chars:t.ALPHANUMERIC},t.available={},t}(),Or="// Pixi texture info\r\nvarying vec2 vTextureCoord;\r\nuniform sampler2D uSampler;\r\n\r\n// Tint\r\nuniform vec4 uColor;\r\n\r\n// on 2D applications fwidth is screenScale / glyphAtlasScale * distanceFieldRange\r\nuniform float uFWidth;\r\n\r\nvoid main(void) {\r\n\r\n // To stack MSDF and SDF we need a non-pre-multiplied-alpha texture.\r\n vec4 texColor = texture2D(uSampler, vTextureCoord);\r\n\r\n // MSDF\r\n float median = texColor.r + texColor.g + texColor.b -\r\n min(texColor.r, min(texColor.g, texColor.b)) -\r\n max(texColor.r, max(texColor.g, texColor.b));\r\n // SDF\r\n median = min(median, texColor.a);\r\n\r\n float screenPxDistance = uFWidth * (median - 0.5);\r\n float alpha = clamp(screenPxDistance + 0.5, 0.0, 1.0);\r\n\r\n // NPM Textures, NPM outputs\r\n gl_FragColor = vec4(uColor.rgb, uColor.a * alpha);\r\n\r\n}\r\n",Ir="// Mesh material default fragment\r\nattribute vec2 aVertexPosition;\r\nattribute vec2 aTextureCoord;\r\n\r\nuniform mat3 projectionMatrix;\r\nuniform mat3 translationMatrix;\r\nuniform mat3 uTextureMatrix;\r\n\r\nvarying vec2 vTextureCoord;\r\n\r\nvoid main(void)\r\n{\r\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\r\n\r\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\r\n}\r\n",wr=[],Cr=[],Pr=[],Nr=(function(t){function e(n,r){void 0===r&&(r={});var i=t.call(this)||this;i._tint=16777215;var o=Object.assign({},e.styleDefaults,r),s=o.align,a=o.tint,u=o.maxWidth,l=o.letterSpacing,c=o.fontName,h=o.fontSize;if(!Ar.available[c])throw new Error('Missing BitmapFont "'+c+'"');return i._activePagesMeshData=[],i._textWidth=0,i._textHeight=0,i._align=s,i._tint=a,i._fontName=c,i._fontSize=h||Ar.available[c].size,i._text=n,i._maxWidth=u,i._maxLineHeight=0,i._letterSpacing=l,i._anchor=new k.AB((function(){i.dirty=!0}),i,0,0),i._roundPixels=Le.X.ROUND_PIXELS,i.dirty=!0,i._textureCache={},i}pr(e,t),e.prototype.updateText=function(){for(var t,e=Ar.available[this._fontName],n=this._fontSize/e.size,r=new k.E9,i=[],o=[],s=[],a=this._text.replace(/(?:\r\n|\r)/g,"\n")||" ",u=xr(a),l=this._maxWidth*e.size/this._fontSize,c="none"===e.distanceFieldType?wr:Cr,h=null,f=0,d=0,p=0,m=-1,v=0,g=0,_=0,y=0,b=0;b<u.length;b++){var E=u[b],T=Rr(E);if(/(?:\s)/.test(E)&&(m=b,v=f,y++),"\r"!==E&&"\n"!==E){var x=e.chars[T];if(x){h&&x.kerning[h]&&(r.x+=x.kerning[h]);var S=Pr.pop()||{texture:J.xE.EMPTY,line:0,charCode:0,prevSpaces:0,position:new k.E9};S.texture=x.texture,S.line=p,S.charCode=T,S.position.x=r.x+x.xOffset+this._letterSpacing/2,S.position.y=r.y+x.yOffset,S.prevSpaces=y,i.push(S),f=S.position.x+Math.max(x.xAdvance,x.texture.orig.width),r.x+=x.xAdvance+this._letterSpacing,_=Math.max(_,x.yOffset+x.texture.height),h=T,-1!==m&&l>0&&r.x>l&&(++g,(0,O.Er)(i,1+m-g,1+b-m),b=m,m=-1,o.push(v),s.push(i.length>0?i[i.length-1].prevSpaces:0),d=Math.max(d,v),p++,r.x=0,r.y+=e.lineHeight,h=null,y=0)}}else o.push(f),s.push(-1),d=Math.max(d,f),++p,++g,r.x=0,r.y+=e.lineHeight,h=null,y=0}var R=u[u.length-1];"\r"!==R&&"\n"!==R&&(/(?:\s)/.test(R)&&(f=v),o.push(f),d=Math.max(d,f),s.push(-1));var A=[];for(b=0;b<=p;b++){var I=0;"right"===this._align?I=d-o[b]:"center"===this._align?I=(d-o[b])/2:"justify"===this._align&&(I=s[b]<0?0:(d-o[b])/s[b]),A.push(I)}var w=i.length,C={},P=[],N=this._activePagesMeshData;for(b=0;b<N.length;b++)c.push(N[b]);for(b=0;b<w;b++){var M=i[b].texture,D=M.baseTexture.uid;if(!C[D]){var L=c.pop();if(!L){var B=new fr,F=void 0,U=void 0;"none"===e.distanceFieldType?(F=new hr(J.xE.EMPTY),U=Dt.T$.NORMAL):(F=new hr(J.xE.EMPTY,{program:J.$r.from(Ir,Or),uniforms:{uFWidth:0}}),U=Dt.T$.NORMAL_NPM);var G=new ur(B,F);G.blendMode=U,L={index:0,indexCount:0,vertexCount:0,uvsCount:0,total:0,mesh:G,vertices:null,uvs:null,indices:null}}L.index=0,L.indexCount=0,L.vertexCount=0,L.uvsCount=0,L.total=0;var X=this._textureCache;X[D]=X[D]||new J.xE(M.baseTexture),L.mesh.texture=X[D],L.mesh.tint=this._tint,P.push(L),C[D]=L}C[D].total++}for(b=0;b<N.length;b++)-1===P.indexOf(N[b])&&this.removeChild(N[b].mesh);for(b=0;b<P.length;b++)P[b].mesh.parent!==this&&this.addChild(P[b].mesh);for(var b in this._activePagesMeshData=P,C){L=C[b];var H=L.total;if(!((null===(t=L.indices)||void 0===t?void 0:t.length)>6*H)||L.vertices.length<2*ur.BATCHABLE_SIZE)L.vertices=new Float32Array(8*H),L.uvs=new Float32Array(8*H),L.indices=new Uint16Array(6*H);else for(var j=L.total,V=L.vertices,Y=4*j*2;Y<V.length;Y++)V[Y]=0;L.mesh.size=6*H}for(b=0;b<w;b++){E=i[b];var W=E.position.x+A[E.line]*("justify"===this._align?E.prevSpaces:1);this._roundPixels&&(W=Math.round(W));var z=W*n,$=E.position.y*n,q=(M=E.texture,C[M.baseTexture.uid]),K=M.frame,Z=M._uvs,Q=q.index++;q.indices[6*Q+0]=0+4*Q,q.indices[6*Q+1]=1+4*Q,q.indices[6*Q+2]=2+4*Q,q.indices[6*Q+3]=0+4*Q,q.indices[6*Q+4]=2+4*Q,q.indices[6*Q+5]=3+4*Q,q.vertices[8*Q+0]=z,q.vertices[8*Q+1]=$,q.vertices[8*Q+2]=z+K.width*n,q.vertices[8*Q+3]=$,q.vertices[8*Q+4]=z+K.width*n,q.vertices[8*Q+5]=$+K.height*n,q.vertices[8*Q+6]=z,q.vertices[8*Q+7]=$+K.height*n,q.uvs[8*Q+0]=Z.x0,q.uvs[8*Q+1]=Z.y0,q.uvs[8*Q+2]=Z.x1,q.uvs[8*Q+3]=Z.y1,q.uvs[8*Q+4]=Z.x2,q.uvs[8*Q+5]=Z.y2,q.uvs[8*Q+6]=Z.x3,q.uvs[8*Q+7]=Z.y3}for(var b in this._textWidth=d*n,this._textHeight=(r.y+e.lineHeight)*n,C){L=C[b];if(0!==this.anchor.x||0!==this.anchor.y)for(var tt=0,et=this._textWidth*this.anchor.x,nt=this._textHeight*this.anchor.y,rt=0;rt<L.total;rt++)L.vertices[tt++]-=et,L.vertices[tt++]-=nt,L.vertices[tt++]-=et,L.vertices[tt++]-=nt,L.vertices[tt++]-=et,L.vertices[tt++]-=nt,L.vertices[tt++]-=et,L.vertices[tt++]-=nt;this._maxLineHeight=_*n;var it=L.mesh.geometry.getBuffer("aVertexPosition"),ot=L.mesh.geometry.getBuffer("aTextureCoord"),st=L.mesh.geometry.getIndex();it.data=L.vertices,ot.data=L.uvs,st.data=L.indices,it.update(),ot.update(),st.update()}for(b=0;b<i.length;b++)Pr.push(i[b])},e.prototype.updateTransform=function(){this.validate(),this.containerUpdateTransform()},e.prototype._render=function(e){var n=Ar.available[this._fontName],r=n.distanceFieldRange,i=n.distanceFieldType,o=n.size;if("none"!==i)for(var s=this.worldTransform,a=s.a,u=s.b,l=s.c,c=s.d,h=Math.sqrt(a*a+u*u),f=Math.sqrt(l*l+c*c),d=(Math.abs(h)+Math.abs(f))/2,p=this._fontSize/o,m=0,v=this._activePagesMeshData;m<v.length;m++){var g=v[m];g.mesh.shader.uniforms.uFWidth=d*r*p*e.resolution}t.prototype._render.call(this,e)},e.prototype.getLocalBounds=function(){return this.validate(),t.prototype.getLocalBounds.call(this)},e.prototype.validate=function(){this.dirty&&(this.updateText(),this.dirty=!1)},Object.defineProperty(e.prototype,"tint",{get:function(){return this._tint},set:function(t){if(this._tint!==t){this._tint=t;for(var e=0;e<this._activePagesMeshData.length;e++)this._activePagesMeshData[e].mesh.tint=t}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"align",{get:function(){return this._align},set:function(t){this._align!==t&&(this._align=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fontName",{get:function(){return this._fontName},set:function(t){if(!Ar.available[t])throw new Error('Missing BitmapFont "'+t+'"');this._fontName!==t&&(this._fontName=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fontSize",{get:function(){return this._fontSize},set:function(t){this._fontSize!==t&&(this._fontSize=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"anchor",{get:function(){return this._anchor},set:function(t){"number"===typeof t?this._anchor.set(t):this._anchor.copyFrom(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this._text},set:function(t){t=String(null===t||void 0===t?"":t),this._text!==t&&(this._text=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxWidth",{get:function(){return this._maxWidth},set:function(t){this._maxWidth!==t&&(this._maxWidth=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxLineHeight",{get:function(){return this.validate(),this._maxLineHeight},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textWidth",{get:function(){return this.validate(),this._textWidth},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"letterSpacing",{get:function(){return this._letterSpacing},set:function(t){this._letterSpacing!==t&&(this._letterSpacing=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"roundPixels",{get:function(){return this._roundPixels},set:function(t){t!==this._roundPixels&&(this._roundPixels=t,this.dirty=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textHeight",{get:function(){return this.validate(),this._textHeight},enumerable:!1,configurable:!0}),e.prototype.destroy=function(e){var n=this._textureCache;for(var r in n){var i=n[r];i.destroy(),delete n[r]}this._textureCache=null,t.prototype.destroy.call(this,e)},e.styleDefaults={align:"left",tint:16777215,maxWidth:0,letterSpacing:0}}(I.W2),function(){function t(){}return t.add=function(){_t.setExtensionXhrType("fnt",_t.XHR_RESPONSE_TYPE.TEXT)},t.use=function(e,n){var r=br(e.data);if(r)for(var i=t.getBaseUrl(this,e),o=r.parse(e.data),s={},a=function(t){s[t.metadata.pageFile]=t.texture,Object.keys(s).length===o.page.length&&(e.bitmapFont=Ar.install(o,s,!0),n())},u=0;u<o.page.length;++u){var l=o.page[u].file,c=i+l,h=!1;for(var f in this.resources){var d=this.resources[f];if(d.url===c){d.metadata.pageFile=l,d.texture?a(d):d.onAfterMiddleware.add(a),h=!0;break}}if(!h){var p={crossOrigin:e.crossOrigin,loadType:_t.LOAD_TYPE.IMAGE,metadata:Object.assign({pageFile:l},e.metadata.imageMetadata),parentResource:e};this.add(c,p,a)}}else n()},t.getBaseUrl=function(e,n){var r=n.isDataUrl?"":t.dirname(n.url);return n.isDataUrl&&("."===r&&(r=""),e.baseUrl&&r&&"/"===e.baseUrl.charAt(e.baseUrl.length-1)&&(r+="/")),r=r.replace(e.baseUrl,""),r&&"/"!==r.charAt(r.length-1)&&(r+="/"),r},t.dirname=function(t){var e=t.replace(/\\/g,"/").replace(/\/$/,"").replace(/\/[^\/]*$/,"");return e===t?".":""===e?"/":e},t}()),Mr=function(t,e){return Mr=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Mr(t,e)};function Dr(t,e){function n(){this.constructor=t}Mr(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Lr="varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform float uAlpha;\n\nvoid main(void)\n{\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uAlpha;\n}\n",Br=(function(t){function e(e){void 0===e&&(e=1);var n=t.call(this,J.kP,Lr,{uAlpha:1})||this;return n.alpha=e,n}Dr(e,t),Object.defineProperty(e.prototype,"alpha",{get:function(){return this.uniforms.uAlpha},set:function(t){this.uniforms.uAlpha=t},enumerable:!1,configurable:!0})}(J.wn),function(t,e){return Br=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Br(t,e)});function Fr(t,e){function n(){this.constructor=t}Br(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var Ur="\n attribute vec2 aVertexPosition;\n\n uniform mat3 projectionMatrix;\n\n uniform float strength;\n\n varying vec2 vBlurTexCoords[%size%];\n\n uniform vec4 inputSize;\n uniform vec4 outputFrame;\n\n vec4 filterVertexPosition( void )\n {\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n }\n\n vec2 filterTextureCoord( void )\n {\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n }\n\n void main(void)\n {\n gl_Position = filterVertexPosition();\n\n vec2 textureCoord = filterTextureCoord();\n %blur%\n }";function Gr(t,e){var n,r=Math.ceil(t/2),i=Ur,o="";n=e?"vBlurTexCoords[%index%] = textureCoord + vec2(%sampleIndex% * strength, 0.0);":"vBlurTexCoords[%index%] = textureCoord + vec2(0.0, %sampleIndex% * strength);";for(var s=0;s<t;s++){var a=n.replace("%index%",s.toString());a=a.replace("%sampleIndex%",s-(r-1)+".0"),o+=a,o+="\n"}return i=i.replace("%blur%",o),i=i.replace("%size%",t.toString()),i}var kr,Xr,Hr,jr,Vr,Yr,Wr,zr,$r,qr,Kr,Zr,Jr,Qr,ti,ei,ni,ri,ii,oi={5:[.153388,.221461,.250301],7:[.071303,.131514,.189879,.214607],9:[.028532,.067234,.124009,.179044,.20236],11:[.0093,.028002,.065984,.121703,.175713,.198596],13:[.002406,.009255,.027867,.065666,.121117,.174868,.197641],15:[489e-6,.002403,.009246,.02784,.065602,.120999,.174697,.197448]},si=["varying vec2 vBlurTexCoords[%size%];","uniform sampler2D uSampler;","void main(void)","{"," gl_FragColor = vec4(0.0);"," %blur%","}"].join("\n");function ai(t){for(var e,n=oi[t],r=n.length,i=si,o="",s="gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;",a=0;a<t;a++){var u=s.replace("%index%",a.toString());e=a,a>=r&&(e=t-a-1),u=u.replace("%value%",n[e].toString()),o+=u,o+="\n"}return i=i.replace("%blur%",o),i=i.replace("%size%",t.toString()),i} -/*! - * @pixi/constants - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/constants is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */(function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"})(kr||(kr={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(Xr||(Xr={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(Hr||(Hr={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(jr||(jr={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(Vr||(Vr={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(Yr||(Yr={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(Wr||(Wr={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(zr||(zr={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}($r||($r={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(qr||(qr={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(Kr||(Kr={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(Zr||(Zr={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(Jr||(Jr={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(Qr||(Qr={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(ti||(ti={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(ei||(ei={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(ni||(ni={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(ri||(ri={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(ii||(ii={}));var ui=function(t){function e(e,n,r,i,o){void 0===n&&(n=8),void 0===r&&(r=4),void 0===i&&(i=Le.X.FILTER_RESOLUTION),void 0===o&&(o=5);var s=this,a=Gr(o,e),u=ai(o);return s=t.call(this,a,u)||this,s.horizontal=e,s.resolution=i,s._quality=0,s.quality=r,s.blur=n,s}return Fr(e,t),e.prototype.apply=function(t,e,n,r){if(n?this.horizontal?this.uniforms.strength=1/n.width*(n.width/e.width):this.uniforms.strength=1/n.height*(n.height/e.height):this.horizontal?this.uniforms.strength=1/t.renderer.width*(t.renderer.width/e.width):this.uniforms.strength=1/t.renderer.height*(t.renderer.height/e.height),this.uniforms.strength*=this.strength,this.uniforms.strength/=this.passes,1===this.passes)t.applyFilter(this,e,n,r);else{var i=t.getFilterTexture(),o=t.renderer,s=e,a=i;this.state.blend=!1,t.applyFilter(this,s,a,Qr.CLEAR);for(var u=1;u<this.passes-1;u++){t.bindAndClear(s,Qr.BLIT),this.uniforms.uSampler=a;var l=a;a=s,s=l,o.shader.bind(this),o.geometry.draw(5)}this.state.blend=!0,t.applyFilter(this,a,n,r),t.returnFilterTexture(i)}},Object.defineProperty(e.prototype,"blur",{get:function(){return this.strength},set:function(t){this.padding=1+2*Math.abs(t),this.strength=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"quality",{get:function(){return this._quality},set:function(t){this._quality=t,this.passes=t},enumerable:!1,configurable:!0}),e}(J.wn),li=(function(t){function e(e,n,r,i){void 0===e&&(e=8),void 0===n&&(n=4),void 0===r&&(r=Le.X.FILTER_RESOLUTION),void 0===i&&(i=5);var o=t.call(this)||this;return o.blurXFilter=new ui(!0,e,n,r,i),o.blurYFilter=new ui(!1,e,n,r,i),o.resolution=r,o.quality=n,o.blur=e,o.repeatEdgePixels=!1,o}Fr(e,t),e.prototype.apply=function(t,e,n,r){var i=Math.abs(this.blurXFilter.strength),o=Math.abs(this.blurYFilter.strength);if(i&&o){var s=t.getFilterTexture();this.blurXFilter.apply(t,e,s,Qr.CLEAR),this.blurYFilter.apply(t,s,n,r),t.returnFilterTexture(s)}else o?this.blurYFilter.apply(t,e,n,r):this.blurXFilter.apply(t,e,n,r)},e.prototype.updatePadding=function(){this._repeatEdgePixels?this.padding=0:this.padding=2*Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))},Object.defineProperty(e.prototype,"blur",{get:function(){return this.blurXFilter.blur},set:function(t){this.blurXFilter.blur=this.blurYFilter.blur=t,this.updatePadding()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"quality",{get:function(){return this.blurXFilter.quality},set:function(t){this.blurXFilter.quality=this.blurYFilter.quality=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blurX",{get:function(){return this.blurXFilter.blur},set:function(t){this.blurXFilter.blur=t,this.updatePadding()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blurY",{get:function(){return this.blurYFilter.blur},set:function(t){this.blurYFilter.blur=t,this.updatePadding()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"blendMode",{get:function(){return this.blurYFilter.blendMode},set:function(t){this.blurYFilter.blendMode=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"repeatEdgePixels",{get:function(){return this._repeatEdgePixels},set:function(t){this._repeatEdgePixels=t,this.updatePadding()},enumerable:!1,configurable:!0})}(J.wn),function(t,e){return li=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},li(t,e)});function ci(t,e){function n(){this.constructor=t}li(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var hi="varying vec2 vTextureCoord;\nuniform sampler2D uSampler;\nuniform float m[20];\nuniform float uAlpha;\n\nvoid main(void)\n{\n vec4 c = texture2D(uSampler, vTextureCoord);\n\n if (uAlpha == 0.0) {\n gl_FragColor = c;\n return;\n }\n\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\n if (c.a > 0.0) {\n c.rgb /= c.a;\n }\n\n vec4 result;\n\n result.r = (m[0] * c.r);\n result.r += (m[1] * c.g);\n result.r += (m[2] * c.b);\n result.r += (m[3] * c.a);\n result.r += m[4];\n\n result.g = (m[5] * c.r);\n result.g += (m[6] * c.g);\n result.g += (m[7] * c.b);\n result.g += (m[8] * c.a);\n result.g += m[9];\n\n result.b = (m[10] * c.r);\n result.b += (m[11] * c.g);\n result.b += (m[12] * c.b);\n result.b += (m[13] * c.a);\n result.b += m[14];\n\n result.a = (m[15] * c.r);\n result.a += (m[16] * c.g);\n result.a += (m[17] * c.b);\n result.a += (m[18] * c.a);\n result.a += m[19];\n\n vec3 rgb = mix(c.rgb, result.rgb, uAlpha);\n\n // Premultiply alpha again.\n rgb *= result.a;\n\n gl_FragColor = vec4(rgb, result.a);\n}\n",fi=function(t){function e(){var e=this,n={m:new Float32Array([1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0]),uAlpha:1};return e=t.call(this,J.Y9,hi,n)||this,e.alpha=1,e}return ci(e,t),e.prototype._loadMatrix=function(t,e){void 0===e&&(e=!1);var n=t;e&&(this._multiply(n,this.uniforms.m,t),n=this._colorMatrix(n)),this.uniforms.m=n},e.prototype._multiply=function(t,e,n){return t[0]=e[0]*n[0]+e[1]*n[5]+e[2]*n[10]+e[3]*n[15],t[1]=e[0]*n[1]+e[1]*n[6]+e[2]*n[11]+e[3]*n[16],t[2]=e[0]*n[2]+e[1]*n[7]+e[2]*n[12]+e[3]*n[17],t[3]=e[0]*n[3]+e[1]*n[8]+e[2]*n[13]+e[3]*n[18],t[4]=e[0]*n[4]+e[1]*n[9]+e[2]*n[14]+e[3]*n[19]+e[4],t[5]=e[5]*n[0]+e[6]*n[5]+e[7]*n[10]+e[8]*n[15],t[6]=e[5]*n[1]+e[6]*n[6]+e[7]*n[11]+e[8]*n[16],t[7]=e[5]*n[2]+e[6]*n[7]+e[7]*n[12]+e[8]*n[17],t[8]=e[5]*n[3]+e[6]*n[8]+e[7]*n[13]+e[8]*n[18],t[9]=e[5]*n[4]+e[6]*n[9]+e[7]*n[14]+e[8]*n[19]+e[9],t[10]=e[10]*n[0]+e[11]*n[5]+e[12]*n[10]+e[13]*n[15],t[11]=e[10]*n[1]+e[11]*n[6]+e[12]*n[11]+e[13]*n[16],t[12]=e[10]*n[2]+e[11]*n[7]+e[12]*n[12]+e[13]*n[17],t[13]=e[10]*n[3]+e[11]*n[8]+e[12]*n[13]+e[13]*n[18],t[14]=e[10]*n[4]+e[11]*n[9]+e[12]*n[14]+e[13]*n[19]+e[14],t[15]=e[15]*n[0]+e[16]*n[5]+e[17]*n[10]+e[18]*n[15],t[16]=e[15]*n[1]+e[16]*n[6]+e[17]*n[11]+e[18]*n[16],t[17]=e[15]*n[2]+e[16]*n[7]+e[17]*n[12]+e[18]*n[17],t[18]=e[15]*n[3]+e[16]*n[8]+e[17]*n[13]+e[18]*n[18],t[19]=e[15]*n[4]+e[16]*n[9]+e[17]*n[14]+e[18]*n[19]+e[19],t},e.prototype._colorMatrix=function(t){var e=new Float32Array(t);return e[4]/=255,e[9]/=255,e[14]/=255,e[19]/=255,e},e.prototype.brightness=function(t,e){var n=[t,0,0,0,0,0,t,0,0,0,0,0,t,0,0,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.tint=function(t,e){var n=t>>16&255,r=t>>8&255,i=255&t,o=[n/255,0,0,0,0,0,r/255,0,0,0,0,0,i/255,0,0,0,0,0,1,0];this._loadMatrix(o,e)},e.prototype.greyscale=function(t,e){var n=[t,t,t,0,0,t,t,t,0,0,t,t,t,0,0,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.blackAndWhite=function(t){var e=[.3,.6,.1,0,0,.3,.6,.1,0,0,.3,.6,.1,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.hue=function(t,e){t=(t||0)/180*Math.PI;var n=Math.cos(t),r=Math.sin(t),i=Math.sqrt,o=1/3,s=i(o),a=n+(1-n)*o,u=o*(1-n)-s*r,l=o*(1-n)+s*r,c=o*(1-n)+s*r,h=n+o*(1-n),f=o*(1-n)-s*r,d=o*(1-n)-s*r,p=o*(1-n)+s*r,m=n+o*(1-n),v=[a,u,l,0,0,c,h,f,0,0,d,p,m,0,0,0,0,0,1,0];this._loadMatrix(v,e)},e.prototype.contrast=function(t,e){var n=(t||0)+1,r=-.5*(n-1),i=[n,0,0,0,r,0,n,0,0,r,0,0,n,0,r,0,0,0,1,0];this._loadMatrix(i,e)},e.prototype.saturate=function(t,e){void 0===t&&(t=0);var n=2*t/3+1,r=-.5*(n-1),i=[n,r,r,0,0,r,n,r,0,0,r,r,n,0,0,0,0,0,1,0];this._loadMatrix(i,e)},e.prototype.desaturate=function(){this.saturate(-1)},e.prototype.negative=function(t){var e=[-1,0,0,1,0,0,-1,0,1,0,0,0,-1,1,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.sepia=function(t){var e=[.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.technicolor=function(t){var e=[1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.polaroid=function(t){var e=[1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.toBGR=function(t){var e=[0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.kodachrome=function(t){var e=[1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.browni=function(t){var e=[.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.vintage=function(t){var e=[.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.colorTone=function(t,e,n,r,i){t=t||.2,e=e||.15,n=n||16770432,r=r||3375104;var o=(n>>16&255)/255,s=(n>>8&255)/255,a=(255&n)/255,u=(r>>16&255)/255,l=(r>>8&255)/255,c=(255&r)/255,h=[.3,.59,.11,0,0,o,s,a,t,0,u,l,c,e,0,o-u,s-l,a-c,0,0];this._loadMatrix(h,i)},e.prototype.night=function(t,e){t=t||.1;var n=[-2*t,-t,0,0,0,-t,0,t,0,0,0,t,2*t,0,0,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.predator=function(t,e){var n=[11.224130630493164*t,-4.794486999511719*t,-2.8746118545532227*t,0*t,.40342438220977783*t,-3.6330697536468506*t,9.193157196044922*t,-2.951810836791992*t,0*t,-1.316135048866272*t,-3.2184197902679443*t,-4.2375030517578125*t,7.476448059082031*t,0*t,.8044459223747253*t,0,0,0,1,0];this._loadMatrix(n,e)},e.prototype.lsd=function(t){var e=[2,-.4,.5,0,0,-.5,2,-.4,0,0,-.4,-.5,3,0,0,0,0,0,1,0];this._loadMatrix(e,t)},e.prototype.reset=function(){var t=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0];this._loadMatrix(t,!1)},Object.defineProperty(e.prototype,"matrix",{get:function(){return this.uniforms.m},set:function(t){this.uniforms.m=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alpha",{get:function(){return this.uniforms.uAlpha},set:function(t){this.uniforms.uAlpha=t},enumerable:!1,configurable:!0}),e}(J.wn);fi.prototype.grayscale=fi.prototype.greyscale; -/*! - * @pixi/filter-displacement - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/filter-displacement is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ -var di=function(t,e){return di=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},di(t,e)};function pi(t,e){function n(){this.constructor=t}di(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var mi="varying vec2 vFilterCoord;\nvarying vec2 vTextureCoord;\n\nuniform vec2 scale;\nuniform mat2 rotation;\nuniform sampler2D uSampler;\nuniform sampler2D mapSampler;\n\nuniform highp vec4 inputSize;\nuniform vec4 inputClamp;\n\nvoid main(void)\n{\n vec4 map = texture2D(mapSampler, vFilterCoord);\n\n map -= 0.5;\n map.xy = scale * inputSize.zw * (rotation * map.xy);\n\n gl_FragColor = texture2D(uSampler, clamp(vec2(vTextureCoord.x + map.x, vTextureCoord.y + map.y), inputClamp.xy, inputClamp.zw));\n}\n",vi="attribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\nuniform mat3 filterMatrix;\n\nvarying vec2 vTextureCoord;\nvarying vec2 vFilterCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvec2 filterTextureCoord( void )\n{\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\n}\n\nvoid main(void)\n{\n\tgl_Position = filterVertexPosition();\n\tvTextureCoord = filterTextureCoord();\n\tvFilterCoord = ( filterMatrix * vec3( vTextureCoord, 1.0) ).xy;\n}\n",gi=(function(t){function e(e,n){var r=this,i=new k.y3;return e.renderable=!1,r=t.call(this,vi,mi,{mapSampler:e._texture,filterMatrix:i,scale:{x:1,y:1},rotation:new Float32Array([1,0,0,1])})||this,r.maskSprite=e,r.maskMatrix=i,null!==n&&void 0!==n||(n=20),r.scale=new k.E9(n,n),r}pi(e,t),e.prototype.apply=function(t,e,n,r){this.uniforms.filterMatrix=t.calculateSpriteMatrix(this.maskMatrix,this.maskSprite),this.uniforms.scale.x=this.scale.x,this.uniforms.scale.y=this.scale.y;var i=this.maskSprite.worldTransform,o=Math.sqrt(i.a*i.a+i.b*i.b),s=Math.sqrt(i.c*i.c+i.d*i.d);0!==o&&0!==s&&(this.uniforms.rotation[0]=i.a/o,this.uniforms.rotation[1]=i.b/o,this.uniforms.rotation[2]=i.c/s,this.uniforms.rotation[3]=i.d/s),t.applyFilter(this,e,n,r)},Object.defineProperty(e.prototype,"map",{get:function(){return this.uniforms.mapSampler},set:function(t){this.uniforms.mapSampler=t},enumerable:!1,configurable:!0})}(J.wn),function(t,e){return gi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},gi(t,e)});function _i(t,e){function n(){this.constructor=t}gi(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var yi="\nattribute vec2 aVertexPosition;\n\nuniform mat3 projectionMatrix;\n\nvarying vec2 v_rgbNW;\nvarying vec2 v_rgbNE;\nvarying vec2 v_rgbSW;\nvarying vec2 v_rgbSE;\nvarying vec2 v_rgbM;\n\nvarying vec2 vFragCoord;\n\nuniform vec4 inputSize;\nuniform vec4 outputFrame;\n\nvec4 filterVertexPosition( void )\n{\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n}\n\nvoid texcoords(vec2 fragCoord, vec2 inverseVP,\n out vec2 v_rgbNW, out vec2 v_rgbNE,\n out vec2 v_rgbSW, out vec2 v_rgbSE,\n out vec2 v_rgbM) {\n v_rgbNW = (fragCoord + vec2(-1.0, -1.0)) * inverseVP;\n v_rgbNE = (fragCoord + vec2(1.0, -1.0)) * inverseVP;\n v_rgbSW = (fragCoord + vec2(-1.0, 1.0)) * inverseVP;\n v_rgbSE = (fragCoord + vec2(1.0, 1.0)) * inverseVP;\n v_rgbM = vec2(fragCoord * inverseVP);\n}\n\nvoid main(void) {\n\n gl_Position = filterVertexPosition();\n\n vFragCoord = aVertexPosition * outputFrame.zw;\n\n texcoords(vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n}\n",bi='varying vec2 v_rgbNW;\nvarying vec2 v_rgbNE;\nvarying vec2 v_rgbSW;\nvarying vec2 v_rgbSE;\nvarying vec2 v_rgbM;\n\nvarying vec2 vFragCoord;\nuniform sampler2D uSampler;\nuniform highp vec4 inputSize;\n\n\n/**\n Basic FXAA implementation based on the code on geeks3d.com with the\n modification that the texture2DLod stuff was removed since it\'s\n unsupported by WebGL.\n\n --\n\n From:\n https://github.com/mitsuhiko/webgl-meincraft\n\n Copyright (c) 2011 by Armin Ronacher.\n\n Some rights reserved.\n\n Redistribution and use in source and binary forms, with or without\n modification, are permitted provided that the following conditions are\n met:\n\n * Redistributions of source code must retain the above copyright\n notice, this list of conditions and the following disclaimer.\n\n * Redistributions in binary form must reproduce the above\n copyright notice, this list of conditions and the following\n disclaimer in the documentation and/or other materials provided\n with the distribution.\n\n * The names of the contributors may not be used to endorse or\n promote products derived from this software without specific\n prior written permission.\n\n THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n */\n\n#ifndef FXAA_REDUCE_MIN\n#define FXAA_REDUCE_MIN (1.0/ 128.0)\n#endif\n#ifndef FXAA_REDUCE_MUL\n#define FXAA_REDUCE_MUL (1.0 / 8.0)\n#endif\n#ifndef FXAA_SPAN_MAX\n#define FXAA_SPAN_MAX 8.0\n#endif\n\n//optimized version for mobile, where dependent\n//texture reads can be a bottleneck\nvec4 fxaa(sampler2D tex, vec2 fragCoord, vec2 inverseVP,\n vec2 v_rgbNW, vec2 v_rgbNE,\n vec2 v_rgbSW, vec2 v_rgbSE,\n vec2 v_rgbM) {\n vec4 color;\n vec3 rgbNW = texture2D(tex, v_rgbNW).xyz;\n vec3 rgbNE = texture2D(tex, v_rgbNE).xyz;\n vec3 rgbSW = texture2D(tex, v_rgbSW).xyz;\n vec3 rgbSE = texture2D(tex, v_rgbSE).xyz;\n vec4 texColor = texture2D(tex, v_rgbM);\n vec3 rgbM = texColor.xyz;\n vec3 luma = vec3(0.299, 0.587, 0.114);\n float lumaNW = dot(rgbNW, luma);\n float lumaNE = dot(rgbNE, luma);\n float lumaSW = dot(rgbSW, luma);\n float lumaSE = dot(rgbSE, luma);\n float lumaM = dot(rgbM, luma);\n float lumaMin = min(lumaM, min(min(lumaNW, lumaNE), min(lumaSW, lumaSE)));\n float lumaMax = max(lumaM, max(max(lumaNW, lumaNE), max(lumaSW, lumaSE)));\n\n mediump vec2 dir;\n dir.x = -((lumaNW + lumaNE) - (lumaSW + lumaSE));\n dir.y = ((lumaNW + lumaSW) - (lumaNE + lumaSE));\n\n float dirReduce = max((lumaNW + lumaNE + lumaSW + lumaSE) *\n (0.25 * FXAA_REDUCE_MUL), FXAA_REDUCE_MIN);\n\n float rcpDirMin = 1.0 / (min(abs(dir.x), abs(dir.y)) + dirReduce);\n dir = min(vec2(FXAA_SPAN_MAX, FXAA_SPAN_MAX),\n max(vec2(-FXAA_SPAN_MAX, -FXAA_SPAN_MAX),\n dir * rcpDirMin)) * inverseVP;\n\n vec3 rgbA = 0.5 * (\n texture2D(tex, fragCoord * inverseVP + dir * (1.0 / 3.0 - 0.5)).xyz +\n texture2D(tex, fragCoord * inverseVP + dir * (2.0 / 3.0 - 0.5)).xyz);\n vec3 rgbB = rgbA * 0.5 + 0.25 * (\n texture2D(tex, fragCoord * inverseVP + dir * -0.5).xyz +\n texture2D(tex, fragCoord * inverseVP + dir * 0.5).xyz);\n\n float lumaB = dot(rgbB, luma);\n if ((lumaB < lumaMin) || (lumaB > lumaMax))\n color = vec4(rgbA, texColor.a);\n else\n color = vec4(rgbB, texColor.a);\n return color;\n}\n\nvoid main() {\n\n vec4 color;\n\n color = fxaa(uSampler, vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n\n gl_FragColor = color;\n}\n',Ei=(function(t){function e(){return t.call(this,yi,bi)||this}_i(e,t)}(J.wn),function(t,e){return Ei=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Ei(t,e)});function Ti(t,e){function n(){this.constructor=t}Ei(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var xi,Si,Ri,Ai,Oi,Ii,wi,Ci,Pi,Ni,Mi,Di,Li,Bi,Fi,Ui,Gi,ki,Xi,Hi="precision highp float;\n\nvarying vec2 vTextureCoord;\nvarying vec4 vColor;\n\nuniform float uNoise;\nuniform float uSeed;\nuniform sampler2D uSampler;\n\nfloat rand(vec2 co)\n{\n return fract(sin(dot(co.xy, vec2(12.9898, 78.233))) * 43758.5453);\n}\n\nvoid main()\n{\n vec4 color = texture2D(uSampler, vTextureCoord);\n float randomValue = rand(gl_FragCoord.xy * uSeed);\n float diff = (randomValue - 0.5) * uNoise;\n\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\n if (color.a > 0.0) {\n color.rgb /= color.a;\n }\n\n color.r += diff;\n color.g += diff;\n color.b += diff;\n\n // Premultiply alpha again.\n color.rgb *= color.a;\n\n gl_FragColor = color;\n}\n";(function(t){function e(e,n){void 0===e&&(e=.5),void 0===n&&(n=Math.random());var r=t.call(this,J.Y9,Hi,{uNoise:0,uSeed:0})||this;return r.noise=e,r.seed=n,r}Ti(e,t),Object.defineProperty(e.prototype,"noise",{get:function(){return this.uniforms.uNoise},set:function(t){this.uniforms.uNoise=t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"seed",{get:function(){return this.uniforms.uSeed},set:function(t){this.uniforms.uSeed=t},enumerable:!1,configurable:!0})})(J.wn);(function(t){t[t["WEBGL_LEGACY"]=0]="WEBGL_LEGACY",t[t["WEBGL"]=1]="WEBGL",t[t["WEBGL2"]=2]="WEBGL2"})(xi||(xi={})),function(t){t[t["UNKNOWN"]=0]="UNKNOWN",t[t["WEBGL"]=1]="WEBGL",t[t["CANVAS"]=2]="CANVAS"}(Si||(Si={})),function(t){t[t["COLOR"]=16384]="COLOR",t[t["DEPTH"]=256]="DEPTH",t[t["STENCIL"]=1024]="STENCIL"}(Ri||(Ri={})),function(t){t[t["NORMAL"]=0]="NORMAL",t[t["ADD"]=1]="ADD",t[t["MULTIPLY"]=2]="MULTIPLY",t[t["SCREEN"]=3]="SCREEN",t[t["OVERLAY"]=4]="OVERLAY",t[t["DARKEN"]=5]="DARKEN",t[t["LIGHTEN"]=6]="LIGHTEN",t[t["COLOR_DODGE"]=7]="COLOR_DODGE",t[t["COLOR_BURN"]=8]="COLOR_BURN",t[t["HARD_LIGHT"]=9]="HARD_LIGHT",t[t["SOFT_LIGHT"]=10]="SOFT_LIGHT",t[t["DIFFERENCE"]=11]="DIFFERENCE",t[t["EXCLUSION"]=12]="EXCLUSION",t[t["HUE"]=13]="HUE",t[t["SATURATION"]=14]="SATURATION",t[t["COLOR"]=15]="COLOR",t[t["LUMINOSITY"]=16]="LUMINOSITY",t[t["NORMAL_NPM"]=17]="NORMAL_NPM",t[t["ADD_NPM"]=18]="ADD_NPM",t[t["SCREEN_NPM"]=19]="SCREEN_NPM",t[t["NONE"]=20]="NONE",t[t["SRC_OVER"]=0]="SRC_OVER",t[t["SRC_IN"]=21]="SRC_IN",t[t["SRC_OUT"]=22]="SRC_OUT",t[t["SRC_ATOP"]=23]="SRC_ATOP",t[t["DST_OVER"]=24]="DST_OVER",t[t["DST_IN"]=25]="DST_IN",t[t["DST_OUT"]=26]="DST_OUT",t[t["DST_ATOP"]=27]="DST_ATOP",t[t["ERASE"]=26]="ERASE",t[t["SUBTRACT"]=28]="SUBTRACT",t[t["XOR"]=29]="XOR"}(Ai||(Ai={})),function(t){t[t["POINTS"]=0]="POINTS",t[t["LINES"]=1]="LINES",t[t["LINE_LOOP"]=2]="LINE_LOOP",t[t["LINE_STRIP"]=3]="LINE_STRIP",t[t["TRIANGLES"]=4]="TRIANGLES",t[t["TRIANGLE_STRIP"]=5]="TRIANGLE_STRIP",t[t["TRIANGLE_FAN"]=6]="TRIANGLE_FAN"}(Oi||(Oi={})),function(t){t[t["RGBA"]=6408]="RGBA",t[t["RGB"]=6407]="RGB",t[t["RG"]=33319]="RG",t[t["RED"]=6403]="RED",t[t["RGBA_INTEGER"]=36249]="RGBA_INTEGER",t[t["RGB_INTEGER"]=36248]="RGB_INTEGER",t[t["RG_INTEGER"]=33320]="RG_INTEGER",t[t["RED_INTEGER"]=36244]="RED_INTEGER",t[t["ALPHA"]=6406]="ALPHA",t[t["LUMINANCE"]=6409]="LUMINANCE",t[t["LUMINANCE_ALPHA"]=6410]="LUMINANCE_ALPHA",t[t["DEPTH_COMPONENT"]=6402]="DEPTH_COMPONENT",t[t["DEPTH_STENCIL"]=34041]="DEPTH_STENCIL"}(Ii||(Ii={})),function(t){t[t["TEXTURE_2D"]=3553]="TEXTURE_2D",t[t["TEXTURE_CUBE_MAP"]=34067]="TEXTURE_CUBE_MAP",t[t["TEXTURE_2D_ARRAY"]=35866]="TEXTURE_2D_ARRAY",t[t["TEXTURE_CUBE_MAP_POSITIVE_X"]=34069]="TEXTURE_CUBE_MAP_POSITIVE_X",t[t["TEXTURE_CUBE_MAP_NEGATIVE_X"]=34070]="TEXTURE_CUBE_MAP_NEGATIVE_X",t[t["TEXTURE_CUBE_MAP_POSITIVE_Y"]=34071]="TEXTURE_CUBE_MAP_POSITIVE_Y",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Y"]=34072]="TEXTURE_CUBE_MAP_NEGATIVE_Y",t[t["TEXTURE_CUBE_MAP_POSITIVE_Z"]=34073]="TEXTURE_CUBE_MAP_POSITIVE_Z",t[t["TEXTURE_CUBE_MAP_NEGATIVE_Z"]=34074]="TEXTURE_CUBE_MAP_NEGATIVE_Z"}(wi||(wi={})),function(t){t[t["UNSIGNED_BYTE"]=5121]="UNSIGNED_BYTE",t[t["UNSIGNED_SHORT"]=5123]="UNSIGNED_SHORT",t[t["UNSIGNED_SHORT_5_6_5"]=33635]="UNSIGNED_SHORT_5_6_5",t[t["UNSIGNED_SHORT_4_4_4_4"]=32819]="UNSIGNED_SHORT_4_4_4_4",t[t["UNSIGNED_SHORT_5_5_5_1"]=32820]="UNSIGNED_SHORT_5_5_5_1",t[t["UNSIGNED_INT"]=5125]="UNSIGNED_INT",t[t["UNSIGNED_INT_10F_11F_11F_REV"]=35899]="UNSIGNED_INT_10F_11F_11F_REV",t[t["UNSIGNED_INT_2_10_10_10_REV"]=33640]="UNSIGNED_INT_2_10_10_10_REV",t[t["UNSIGNED_INT_24_8"]=34042]="UNSIGNED_INT_24_8",t[t["UNSIGNED_INT_5_9_9_9_REV"]=35902]="UNSIGNED_INT_5_9_9_9_REV",t[t["BYTE"]=5120]="BYTE",t[t["SHORT"]=5122]="SHORT",t[t["INT"]=5124]="INT",t[t["FLOAT"]=5126]="FLOAT",t[t["FLOAT_32_UNSIGNED_INT_24_8_REV"]=36269]="FLOAT_32_UNSIGNED_INT_24_8_REV",t[t["HALF_FLOAT"]=36193]="HALF_FLOAT"}(Ci||(Ci={})),function(t){t[t["FLOAT"]=0]="FLOAT",t[t["INT"]=1]="INT",t[t["UINT"]=2]="UINT"}(Pi||(Pi={})),function(t){t[t["NEAREST"]=0]="NEAREST",t[t["LINEAR"]=1]="LINEAR"}(Ni||(Ni={})),function(t){t[t["CLAMP"]=33071]="CLAMP",t[t["REPEAT"]=10497]="REPEAT",t[t["MIRRORED_REPEAT"]=33648]="MIRRORED_REPEAT"}(Mi||(Mi={})),function(t){t[t["OFF"]=0]="OFF",t[t["POW2"]=1]="POW2",t[t["ON"]=2]="ON",t[t["ON_MANUAL"]=3]="ON_MANUAL"}(Di||(Di={})),function(t){t[t["NPM"]=0]="NPM",t[t["UNPACK"]=1]="UNPACK",t[t["PMA"]=2]="PMA",t[t["NO_PREMULTIPLIED_ALPHA"]=0]="NO_PREMULTIPLIED_ALPHA",t[t["PREMULTIPLY_ON_UPLOAD"]=1]="PREMULTIPLY_ON_UPLOAD",t[t["PREMULTIPLY_ALPHA"]=2]="PREMULTIPLY_ALPHA",t[t["PREMULTIPLIED_ALPHA"]=2]="PREMULTIPLIED_ALPHA"}(Li||(Li={})),function(t){t[t["NO"]=0]="NO",t[t["YES"]=1]="YES",t[t["AUTO"]=2]="AUTO",t[t["BLEND"]=0]="BLEND",t[t["CLEAR"]=1]="CLEAR",t[t["BLIT"]=2]="BLIT"}(Bi||(Bi={})),function(t){t[t["AUTO"]=0]="AUTO",t[t["MANUAL"]=1]="MANUAL"}(Fi||(Fi={})),function(t){t["LOW"]="lowp",t["MEDIUM"]="mediump",t["HIGH"]="highp"}(Ui||(Ui={})),function(t){t[t["NONE"]=0]="NONE",t[t["SCISSOR"]=1]="SCISSOR",t[t["STENCIL"]=2]="STENCIL",t[t["SPRITE"]=3]="SPRITE"}(Gi||(Gi={})),function(t){t[t["NONE"]=0]="NONE",t[t["LOW"]=2]="LOW",t[t["MEDIUM"]=4]="MEDIUM",t[t["HIGH"]=8]="HIGH"}(ki||(ki={})),function(t){t[t["ELEMENT_ARRAY_BUFFER"]=34963]="ELEMENT_ARRAY_BUFFER",t[t["ARRAY_BUFFER"]=34962]="ARRAY_BUFFER",t[t["UNIFORM_BUFFER"]=35345]="UNIFORM_BUFFER"}(Xi||(Xi={}));var ji=new k.y3;I.s$.prototype._cacheAsBitmap=!1,I.s$.prototype._cacheData=null,I.s$.prototype._cacheAsBitmapResolution=null,I.s$.prototype._cacheAsBitmapMultisample=ki.NONE;var Vi=function(){function t(){this.textureCacheId=null,this.originalRender=null,this.originalRenderCanvas=null,this.originalCalculateBounds=null,this.originalGetLocalBounds=null,this.originalUpdateTransform=null,this.originalDestroy=null,this.originalMask=null,this.originalFilterArea=null,this.originalContainsPoint=null,this.sprite=null}return t}();Object.defineProperties(I.s$.prototype,{cacheAsBitmapResolution:{get:function(){return this._cacheAsBitmapResolution},set:function(t){t!==this._cacheAsBitmapResolution&&(this._cacheAsBitmapResolution=t,this.cacheAsBitmap&&(this.cacheAsBitmap=!1,this.cacheAsBitmap=!0))}},cacheAsBitmapMultisample:{get:function(){return this._cacheAsBitmapMultisample},set:function(t){t!==this._cacheAsBitmapMultisample&&(this._cacheAsBitmapMultisample=t,this.cacheAsBitmap&&(this.cacheAsBitmap=!1,this.cacheAsBitmap=!0))}},cacheAsBitmap:{get:function(){return this._cacheAsBitmap},set:function(t){var e;this._cacheAsBitmap!==t&&(this._cacheAsBitmap=t,t?(this._cacheData||(this._cacheData=new Vi),e=this._cacheData,e.originalRender=this.render,e.originalRenderCanvas=this.renderCanvas,e.originalUpdateTransform=this.updateTransform,e.originalCalculateBounds=this.calculateBounds,e.originalGetLocalBounds=this.getLocalBounds,e.originalDestroy=this.destroy,e.originalContainsPoint=this.containsPoint,e.originalMask=this._mask,e.originalFilterArea=this.filterArea,this.render=this._renderCached,this.renderCanvas=this._renderCachedCanvas,this.destroy=this._cacheAsBitmapDestroy):(e=this._cacheData,e.sprite&&this._destroyCachedDisplayObject(),this.render=e.originalRender,this.renderCanvas=e.originalRenderCanvas,this.calculateBounds=e.originalCalculateBounds,this.getLocalBounds=e.originalGetLocalBounds,this.destroy=e.originalDestroy,this.updateTransform=e.originalUpdateTransform,this.containsPoint=e.originalContainsPoint,this._mask=e.originalMask,this.filterArea=e.originalFilterArea))}}}),I.s$.prototype._renderCached=function(t){!this.visible||this.worldAlpha<=0||!this.renderable||(this._initCachedDisplayObject(t),this._cacheData.sprite.transform._worldID=this.transform._worldID,this._cacheData.sprite.worldAlpha=this.worldAlpha,this._cacheData.sprite._render(t))},I.s$.prototype._initCachedDisplayObject=function(t){var e;if(!this._cacheData||!this._cacheData.sprite){var n=this.alpha;this.alpha=1,t.batch.flush();var r=this.getLocalBounds(null,!0).clone();if(this.filters&&this.filters.length){var i=this.filters[0].padding;r.pad(i)}r.ceil(Le.X.RESOLUTION);var o=t.renderTexture.current,s=t.renderTexture.sourceFrame.clone(),a=t.renderTexture.destinationFrame.clone(),u=t.projection.transform,l=J.TI.create({width:r.width,height:r.height,resolution:this.cacheAsBitmapResolution||t.resolution,multisample:null!==(e=this.cacheAsBitmapMultisample)&&void 0!==e?e:t.multisample}),c="cacheAsBitmap_"+(0,O.hQ)();this._cacheData.textureCacheId=c,J.VL.addToCache(l.baseTexture,c),J.xE.addToCache(l,c);var h=this.transform.localTransform.copyTo(ji).invert().translate(-r.x,-r.y);this.render=this._cacheData.originalRender,t.render(this,{renderTexture:l,clear:!0,transform:h,skipUpdateTransform:!1}),t.framebuffer.blit(),t.projection.transform=u,t.renderTexture.bind(o,s,a),this.render=this._renderCached,this.updateTransform=this.displayObjectUpdateTransform,this.calculateBounds=this._calculateCachedBounds,this.getLocalBounds=this._getCachedLocalBounds,this._mask=null,this.filterArea=null,this.alpha=n;var f=new vn.j(l);f.transform.worldTransform=this.transform.worldTransform,f.anchor.x=-r.x/r.width,f.anchor.y=-r.y/r.height,f.alpha=n,f._bounds=this._bounds,this._cacheData.sprite=f,this.transform._parentID=-1,this.parent?this.updateTransform():(this.enableTempParent(),this.updateTransform(),this.disableTempParent(null)),this.containsPoint=f.containsPoint.bind(f)}},I.s$.prototype._renderCachedCanvas=function(t){!this.visible||this.worldAlpha<=0||!this.renderable||(this._initCachedDisplayObjectCanvas(t),this._cacheData.sprite.worldAlpha=this.worldAlpha,this._cacheData.sprite._renderCanvas(t))},I.s$.prototype._initCachedDisplayObjectCanvas=function(t){if(!this._cacheData||!this._cacheData.sprite){var e=this.getLocalBounds(null,!0),n=this.alpha;this.alpha=1;var r=t.context,i=t._projTransform;e.ceil(Le.X.RESOLUTION);var o=J.TI.create({width:e.width,height:e.height}),s="cacheAsBitmap_"+(0,O.hQ)();this._cacheData.textureCacheId=s,J.VL.addToCache(o.baseTexture,s),J.xE.addToCache(o,s);var a=ji;this.transform.localTransform.copyTo(a),a.invert(),a.tx-=e.x,a.ty-=e.y,this.renderCanvas=this._cacheData.originalRenderCanvas,t.render(this,{renderTexture:o,clear:!0,transform:a,skipUpdateTransform:!1}),t.context=r,t._projTransform=i,this.renderCanvas=this._renderCachedCanvas,this.updateTransform=this.displayObjectUpdateTransform,this.calculateBounds=this._calculateCachedBounds,this.getLocalBounds=this._getCachedLocalBounds,this._mask=null,this.filterArea=null,this.alpha=n;var u=new vn.j(o);u.transform.worldTransform=this.transform.worldTransform,u.anchor.x=-e.x/e.width,u.anchor.y=-e.y/e.height,u.alpha=n,u._bounds=this._bounds,this._cacheData.sprite=u,this.transform._parentID=-1,this.parent?this.updateTransform():(this.parent=t._tempDisplayObjectParent,this.updateTransform(),this.parent=null),this.containsPoint=u.containsPoint.bind(u)}},I.s$.prototype._calculateCachedBounds=function(){this._bounds.clear(),this._cacheData.sprite.transform._worldID=this.transform._worldID,this._cacheData.sprite._calculateBounds(),this._bounds.updateID=this._boundsID},I.s$.prototype._getCachedLocalBounds=function(){return this._cacheData.sprite.getLocalBounds(null)},I.s$.prototype._destroyCachedDisplayObject=function(){this._cacheData.sprite._texture.destroy(!0),this._cacheData.sprite=null,J.VL.removeFromCache(this._cacheData.textureCacheId),J.xE.removeFromCache(this._cacheData.textureCacheId),this._cacheData.textureCacheId=null},I.s$.prototype._cacheAsBitmapDestroy=function(t){this.cacheAsBitmap=!1,this.destroy(t)}, -/*! - * @pixi/mixin-get-child-by-name - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/mixin-get-child-by-name is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -I.s$.prototype.name=null,I.W2.prototype.getChildByName=function(t,e){for(var n=0,r=this.children.length;n<r;n++)if(this.children[n].name===t)return this.children[n];if(e)for(n=0,r=this.children.length;n<r;n++){var i=this.children[n];if(i.getChildByName){var o=this.children[n].getChildByName(t,!0);if(o)return o}}return null}, -/*! - * @pixi/mixin-get-global-position - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/mixin-get-global-position is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -I.s$.prototype.getGlobalPosition=function(t,e){return void 0===t&&(t=new k.E9),void 0===e&&(e=!1),this.parent?this.parent.toGlobal(this.position,t,e):(t.x=this.position.x,t.y=this.position.y),t}; -/*! - * @pixi/mesh-extras - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * @pixi/mesh-extras is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ -var Yi=function(t,e){return Yi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Yi(t,e)};function Wi(t,e){function n(){this.constructor=t}Yi(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var zi=function(t){function e(e,n,r,i){void 0===e&&(e=100),void 0===n&&(n=100),void 0===r&&(r=10),void 0===i&&(i=10);var o=t.call(this)||this;return o.segWidth=r,o.segHeight=i,o.width=e,o.height=n,o.build(),o}return Wi(e,t),e.prototype.build=function(){for(var t=this.segWidth*this.segHeight,e=[],n=[],r=[],i=this.segWidth-1,o=this.segHeight-1,s=this.width/i,a=this.height/o,u=0;u<t;u++){var l=u%this.segWidth,c=u/this.segWidth|0;e.push(l*s,c*a),n.push(l/i,c/o)}var h=i*o;for(u=0;u<h;u++){var f=u%i,d=u/i|0,p=d*this.segWidth+f,m=d*this.segWidth+f+1,v=(d+1)*this.segWidth+f,g=(d+1)*this.segWidth+f+1;r.push(p,m,v,m,g,v)}this.buffers[0].data=new Float32Array(e),this.buffers[1].data=new Float32Array(n),this.indexBuffer.data=new Uint16Array(r),this.buffers[0].update(),this.buffers[1].update(),this.indexBuffer.update()},e}(fr),$i=function(t){function e(e,n,r){void 0===e&&(e=200),void 0===r&&(r=0);var i=t.call(this,new Float32Array(4*n.length),new Float32Array(4*n.length),new Uint16Array(6*(n.length-1)))||this;return i.points=n,i._width=e,i.textureScale=r,i.build(),i}return Wi(e,t),Object.defineProperty(e.prototype,"width",{get:function(){return this._width},enumerable:!1,configurable:!0}),e.prototype.build=function(){var t=this.points;if(t){var e=this.getBuffer("aVertexPosition"),n=this.getBuffer("aTextureCoord"),r=this.getIndex();if(!(t.length<1)){e.data.length/4!==t.length&&(e.data=new Float32Array(4*t.length),n.data=new Float32Array(4*t.length),r.data=new Uint16Array(6*(t.length-1)));var i=n.data,o=r.data;i[0]=0,i[1]=0,i[2]=0,i[3]=1;for(var s=0,a=t[0],u=this._width*this.textureScale,l=t.length,c=0;c<l;c++){var h=4*c;if(this.textureScale>0){var f=a.x-t[c].x,d=a.y-t[c].y,p=Math.sqrt(f*f+d*d);a=t[c],s+=p/u}else s=c/(l-1);i[h]=s,i[h+1]=0,i[h+2]=s,i[h+3]=1}var m=0;for(c=0;c<l-1;c++){h=2*c;o[m++]=h,o[m++]=h+1,o[m++]=h+2,o[m++]=h+2,o[m++]=h+1,o[m++]=h+3}n.update(),r.update(),this.updateVertices()}}},e.prototype.updateVertices=function(){var t=this.points;if(!(t.length<1)){for(var e,n=t[0],r=0,i=0,o=this.buffers[0].data,s=t.length,a=0;a<s;a++){var u=t[a],l=4*a;e=a<t.length-1?t[a+1]:u,i=-(e.x-n.x),r=e.y-n.y;var c=Math.sqrt(r*r+i*i),h=this.textureScale>0?this.textureScale*this._width/2:this._width/2;r/=c,i/=c,r*=h,i*=h,o[l]=u.x+r,o[l+1]=u.y+i,o[l+2]=u.x-r,o[l+3]=u.y-i,n=u}this.buffers[0].update()}},e.prototype.update=function(){this.textureScale>0?this.build():this.updateVertices()},e}(fr),qi=(function(t){function e(e,n,r){void 0===r&&(r=0);var i=this,o=new $i(e.height,n,r),s=new hr(e);return r>0&&(e.baseTexture.wrapMode=Dt.Nt.REPEAT),i=t.call(this,o,s)||this,i.autoUpdate=!0,i}Wi(e,t),e.prototype._render=function(e){var n=this.geometry;(this.autoUpdate||n._width!==this.shader.texture.height)&&(n._width=this.shader.texture.height,n.update()),t.prototype._render.call(this,e)}}(ur),function(t){function e(e,n,r){var i=this,o=new zi(e.width,e.height,n,r),s=new hr(J.xE.WHITE);return i=t.call(this,o,s)||this,i.texture=e,i.autoResize=!0,i}return Wi(e,t),e.prototype.textureUpdated=function(){this._textureID=this.shader.texture._updateID;var t=this.geometry,e=this.shader.texture,n=e.width,r=e.height;!this.autoResize||t.width===n&&t.height===r||(t.width=this.shader.texture.width,t.height=this.shader.texture.height,t.build())},Object.defineProperty(e.prototype,"texture",{get:function(){return this.shader.texture},set:function(t){this.shader.texture!==t&&(this.shader.texture=t,this._textureID=-1,t.baseTexture.valid?this.textureUpdated():t.once("update",this.textureUpdated,this))},enumerable:!1,configurable:!0}),e.prototype._render=function(e){this._textureID!==this.shader.texture._updateID&&this.textureUpdated(),t.prototype._render.call(this,e)},e.prototype.destroy=function(e){this.shader.texture.off("update",this.textureUpdated,this),t.prototype.destroy.call(this,e)},e}(ur)),Ki=(function(t){function e(e,n,r,i,o){void 0===e&&(e=J.xE.EMPTY);var s=this,a=new fr(n,r,i);a.getBuffer("aVertexPosition").static=!1;var u=new hr(e);return s=t.call(this,a,u,null,o)||this,s.autoUpdate=!0,s}Wi(e,t),Object.defineProperty(e.prototype,"vertices",{get:function(){return this.geometry.getBuffer("aVertexPosition").data},set:function(t){this.geometry.getBuffer("aVertexPosition").data=t},enumerable:!1,configurable:!0}),e.prototype._render=function(e){this.autoUpdate&&this.geometry.getBuffer("aVertexPosition").update(),t.prototype._render.call(this,e)}}(ur),10),Zi=(function(t){function e(e,n,r,i,o){void 0===n&&(n=Ki),void 0===r&&(r=Ki),void 0===i&&(i=Ki),void 0===o&&(o=Ki);var s=t.call(this,J.xE.WHITE,4,4)||this;return s._origWidth=e.orig.width,s._origHeight=e.orig.height,s._width=s._origWidth,s._height=s._origHeight,s._leftWidth=n,s._rightWidth=i,s._topHeight=r,s._bottomHeight=o,s.texture=e,s}Wi(e,t),e.prototype.textureUpdated=function(){this._textureID=this.shader.texture._updateID,this._refresh()},Object.defineProperty(e.prototype,"vertices",{get:function(){return this.geometry.getBuffer("aVertexPosition").data},set:function(t){this.geometry.getBuffer("aVertexPosition").data=t},enumerable:!1,configurable:!0}),e.prototype.updateHorizontalVertices=function(){var t=this.vertices,e=this._getMinScale();t[9]=t[11]=t[13]=t[15]=this._topHeight*e,t[17]=t[19]=t[21]=t[23]=this._height-this._bottomHeight*e,t[25]=t[27]=t[29]=t[31]=this._height},e.prototype.updateVerticalVertices=function(){var t=this.vertices,e=this._getMinScale();t[2]=t[10]=t[18]=t[26]=this._leftWidth*e,t[4]=t[12]=t[20]=t[28]=this._width-this._rightWidth*e,t[6]=t[14]=t[22]=t[30]=this._width},e.prototype._getMinScale=function(){var t=this._leftWidth+this._rightWidth,e=this._width>t?1:this._width/t,n=this._topHeight+this._bottomHeight,r=this._height>n?1:this._height/n,i=Math.min(e,r);return i},Object.defineProperty(e.prototype,"width",{get:function(){return this._width},set:function(t){this._width=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this._height},set:function(t){this._height=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"leftWidth",{get:function(){return this._leftWidth},set:function(t){this._leftWidth=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rightWidth",{get:function(){return this._rightWidth},set:function(t){this._rightWidth=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"topHeight",{get:function(){return this._topHeight},set:function(t){this._topHeight=t,this._refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottomHeight",{get:function(){return this._bottomHeight},set:function(t){this._bottomHeight=t,this._refresh()},enumerable:!1,configurable:!0}),e.prototype._refresh=function(){var t=this.texture,e=this.geometry.buffers[1].data;this._origWidth=t.orig.width,this._origHeight=t.orig.height;var n=1/this._origWidth,r=1/this._origHeight;e[0]=e[8]=e[16]=e[24]=0,e[1]=e[3]=e[5]=e[7]=0,e[6]=e[14]=e[22]=e[30]=1,e[25]=e[27]=e[29]=e[31]=1,e[2]=e[10]=e[18]=e[26]=n*this._leftWidth,e[4]=e[12]=e[20]=e[28]=1-n*this._rightWidth,e[9]=e[11]=e[13]=e[15]=r*this._topHeight,e[17]=e[19]=e[21]=e[23]=1-r*this._bottomHeight,this.updateHorizontalVertices(),this.updateVerticalVertices(),this.geometry.buffers[0].update(),this.geometry.buffers[1].update()}}(qi),n(1034),function(t,e){return Zi=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},Zi(t,e)});function Ji(t,e){function n(){this.constructor=t}Zi(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}(function(t){function e(e,n){void 0===n&&(n=!0);var r=t.call(this,e[0]instanceof J.xE?e[0]:e[0].texture)||this;return r._textures=null,r._durations=null,r._autoUpdate=n,r._isConnectedToTicker=!1,r.animationSpeed=1,r.loop=!0,r.updateAnchor=!1,r.onComplete=null,r.onFrameChange=null,r.onLoop=null,r._currentTime=0,r._playing=!1,r._previousFrame=null,r.textures=e,r}Ji(e,t),e.prototype.stop=function(){this._playing&&(this._playing=!1,this._autoUpdate&&this._isConnectedToTicker&&(X.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1))},e.prototype.play=function(){this._playing||(this._playing=!0,this._autoUpdate&&!this._isConnectedToTicker&&(X.vB.shared.add(this.update,this,X.uF.HIGH),this._isConnectedToTicker=!0))},e.prototype.gotoAndStop=function(t){this.stop();var e=this.currentFrame;this._currentTime=t,e!==this.currentFrame&&this.updateTexture()},e.prototype.gotoAndPlay=function(t){var e=this.currentFrame;this._currentTime=t,e!==this.currentFrame&&this.updateTexture(),this.play()},e.prototype.update=function(t){if(this._playing){var e=this.animationSpeed*t,n=this.currentFrame;if(null!==this._durations){var r=this._currentTime%1*this._durations[this.currentFrame];r+=e/60*1e3;while(r<0)this._currentTime--,r+=this._durations[this.currentFrame];var i=Math.sign(this.animationSpeed*t);this._currentTime=Math.floor(this._currentTime);while(r>=this._durations[this.currentFrame])r-=this._durations[this.currentFrame]*i,this._currentTime+=i;this._currentTime+=r/this._durations[this.currentFrame]}else this._currentTime+=e;this._currentTime<0&&!this.loop?(this.gotoAndStop(0),this.onComplete&&this.onComplete()):this._currentTime>=this._textures.length&&!this.loop?(this.gotoAndStop(this._textures.length-1),this.onComplete&&this.onComplete()):n!==this.currentFrame&&(this.loop&&this.onLoop&&(this.animationSpeed>0&&this.currentFrame<n||this.animationSpeed<0&&this.currentFrame>n)&&this.onLoop(),this.updateTexture())}},e.prototype.updateTexture=function(){var t=this.currentFrame;this._previousFrame!==t&&(this._previousFrame=t,this._texture=this._textures[t],this._textureID=-1,this._textureTrimmedID=-1,this._cachedTint=16777215,this.uvs=this._texture._uvs.uvsFloat32,this.updateAnchor&&this._anchor.copyFrom(this._texture.defaultAnchor),this.onFrameChange&&this.onFrameChange(this.currentFrame))},e.prototype.destroy=function(e){this.stop(),t.prototype.destroy.call(this,e),this.onComplete=null,this.onFrameChange=null,this.onLoop=null},e.fromFrames=function(t){for(var n=[],r=0;r<t.length;++r)n.push(J.xE.from(t[r]));return new e(n)},e.fromImages=function(t){for(var n=[],r=0;r<t.length;++r)n.push(J.xE.from(t[r]));return new e(n)},Object.defineProperty(e.prototype,"totalFrames",{get:function(){return this._textures.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textures",{get:function(){return this._textures},set:function(t){if(t[0]instanceof J.xE)this._textures=t,this._durations=null;else{this._textures=[],this._durations=[];for(var e=0;e<t.length;e++)this._textures.push(t[e].texture),this._durations.push(t[e].time)}this._previousFrame=null,this.gotoAndStop(0),this.updateTexture()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentFrame",{get:function(){var t=Math.floor(this._currentTime)%this._textures.length;return t<0&&(t+=this._textures.length),t},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"playing",{get:function(){return this._playing},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"autoUpdate",{get:function(){return this._autoUpdate},set:function(t){t!==this._autoUpdate&&(this._autoUpdate=t,!this._autoUpdate&&this._isConnectedToTicker?(X.vB.shared.remove(this.update,this),this._isConnectedToTicker=!1):this._autoUpdate&&!this._isConnectedToTicker&&this._playing&&(X.vB.shared.add(this.update,this),this._isConnectedToTicker=!0))},enumerable:!1,configurable:!0})})(vn.j); -/*! - * pixi.js - v6.3.0 - * Compiled Wed, 23 Mar 2022 18:58:56 UTC - * - * pixi.js is licensed under the MIT License. - * http://www.opensource.org/licenses/mit-license - */ -J.Th.registerPlugin("accessibility",G),J.Th.registerPlugin("extract",rt),J.Th.registerPlugin("interaction",Z),J.Th.registerPlugin("particle",De),J.Th.registerPlugin("prepare",Vn),J.Th.registerPlugin("batch",J.Bv),J.Th.registerPlugin("tilingSprite",nr),Rt.registerPlugin(Nr),Rt.registerPlugin(Vt),Rt.registerPlugin(_e),Rt.registerPlugin(Ae),Rt.registerPlugin(Wn),Q.registerPlugin(X.Sb),Q.registerPlugin(At)},2587:function(t){"use strict";function e(t,e){return Object.prototype.hasOwnProperty.call(t,e)}t.exports=function(t,n,r,i){n=n||"&",r=r||"=";var o={};if("string"!==typeof t||0===t.length)return o;var s=/\+/g;t=t.split(n);var a=1e3;i&&"number"===typeof i.maxKeys&&(a=i.maxKeys);var u=t.length;a>0&&u>a&&(u=a);for(var l=0;l<u;++l){var c,h,f,d,p=t[l].replace(s,"%20"),m=p.indexOf(r);m>=0?(c=p.substr(0,m),h=p.substr(m+1)):(c=p,h=""),f=decodeURIComponent(c),d=decodeURIComponent(h),e(o,f)?Array.isArray(o[f])?o[f].push(d):o[f]=[o[f],d]:o[f]=d}return o}},2361:function(t){"use strict";var e=function(t){switch(typeof t){case"string":return t;case"boolean":return t?"true":"false";case"number":return isFinite(t)?t:"";default:return""}};t.exports=function(t,n,r,i){return n=n||"&",r=r||"=",null===t&&(t=void 0),"object"===typeof t?Object.keys(t).map((function(i){var o=encodeURIComponent(e(i))+r;return Array.isArray(t[i])?t[i].map((function(t){return o+encodeURIComponent(e(t))})).join(n):o+encodeURIComponent(e(t[i]))})).join(n):i?encodeURIComponent(e(i))+r+encodeURIComponent(e(t)):""}},7673:function(t,e,n){"use strict";e.decode=e.parse=n(2587),e.encode=e.stringify=n(2361)},1474:function(t,e,n){"use strict"; -/**! - * Sortable 1.14.0 - * @author RubaXa <trash@rubaxa.org> - * @author owenm <owen23355@gmail.com> - * @license MIT - */ -function r(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function i(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?r(Object(n),!0).forEach((function(e){s(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function o(t){return o="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o(t)}function s(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function a(){return a=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},a.apply(this,arguments)}function u(t,e){if(null==t)return{};var n,r,i={},o=Object.keys(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||(i[n]=t[n]);return i}function l(t,e){if(null==t)return{};var n,r,i=u(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(r=0;r<o.length;r++)n=o[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function c(t){return h(t)||f(t)||d(t)||m()}function h(t){if(Array.isArray(t))return p(t)}function f(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function d(t,e){if(t){if("string"===typeof t)return p(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(t,e):void 0}}function p(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function m(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}n.r(e),n.d(e,{MultiDrag:function(){return je},Sortable:function(){return ne},Swap:function(){return Pe}});var v="1.14.0";function g(t){if("undefined"!==typeof window&&window.navigator)return!!navigator.userAgent.match(t)}var _=g(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),y=g(/Edge/i),b=g(/firefox/i),E=g(/safari/i)&&!g(/chrome/i)&&!g(/android/i),T=g(/iP(ad|od|hone)/i),x=g(/chrome/i)&&g(/android/i),S={capture:!1,passive:!1};function R(t,e,n){t.addEventListener(e,n,!_&&S)}function A(t,e,n){t.removeEventListener(e,n,!_&&S)}function O(t,e){if(e){if(">"===e[0]&&(e=e.substring(1)),t)try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch(n){return!1}return!1}}function I(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function w(t,e,n,r){if(t){n=n||document;do{if(null!=e&&(">"===e[0]?t.parentNode===n&&O(t,e):O(t,e))||r&&t===n)return t;if(t===n)break}while(t=I(t))}return null}var C,P=/\s+/g;function N(t,e,n){if(t&&e)if(t.classList)t.classList[n?"add":"remove"](e);else{var r=(" "+t.className+" ").replace(P," ").replace(" "+e+" "," ");t.className=(r+(n?" "+e:"")).replace(P," ")}}function M(t,e,n){var r=t&&t.style;if(r){if(void 0===n)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(n=t.currentStyle),void 0===e?n:n[e];e in r||-1!==e.indexOf("webkit")||(e="-webkit-"+e),r[e]=n+("string"===typeof n?"":"px")}}function D(t,e){var n="";if("string"===typeof t)n=t;else do{var r=M(t,"transform");r&&"none"!==r&&(n=r+" "+n)}while(!e&&(t=t.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function L(t,e,n){if(t){var r=t.getElementsByTagName(e),i=0,o=r.length;if(n)for(;i<o;i++)n(r[i],i);return r}return[]}function B(){var t=document.scrollingElement;return t||document.documentElement}function F(t,e,n,r,i){if(t.getBoundingClientRect||t===window){var o,s,a,u,l,c,h;if(t!==window&&t.parentNode&&t!==B()?(o=t.getBoundingClientRect(),s=o.top,a=o.left,u=o.bottom,l=o.right,c=o.height,h=o.width):(s=0,a=0,u=window.innerHeight,l=window.innerWidth,c=window.innerHeight,h=window.innerWidth),(e||n)&&t!==window&&(i=i||t.parentNode,!_))do{if(i&&i.getBoundingClientRect&&("none"!==M(i,"transform")||n&&"static"!==M(i,"position"))){var f=i.getBoundingClientRect();s-=f.top+parseInt(M(i,"border-top-width")),a-=f.left+parseInt(M(i,"border-left-width")),u=s+o.height,l=a+o.width;break}}while(i=i.parentNode);if(r&&t!==window){var d=D(i||t),p=d&&d.a,m=d&&d.d;d&&(s/=m,a/=p,h/=p,c/=m,u=s+c,l=a+h)}return{top:s,left:a,bottom:u,right:l,width:h,height:c}}}function U(t,e,n){var r=V(t,!0),i=F(t)[e];while(r){var o=F(r)[n],s=void 0;if(s="top"===n||"left"===n?i>=o:i<=o,!s)return r;if(r===B())break;r=V(r,!1)}return!1}function G(t,e,n,r){var i=0,o=0,s=t.children;while(o<s.length){if("none"!==s[o].style.display&&s[o]!==ne.ghost&&(r||s[o]!==ne.dragged)&&w(s[o],n.draggable,t,!1)){if(i===e)return s[o];i++}o++}return null}function k(t,e){var n=t.lastElementChild;while(n&&(n===ne.ghost||"none"===M(n,"display")||e&&!O(n,e)))n=n.previousElementSibling;return n||null}function X(t,e){var n=0;if(!t||!t.parentNode)return-1;while(t=t.previousElementSibling)"TEMPLATE"===t.nodeName.toUpperCase()||t===ne.clone||e&&!O(t,e)||n++;return n}function H(t){var e=0,n=0,r=B();if(t)do{var i=D(t),o=i.a,s=i.d;e+=t.scrollLeft*o,n+=t.scrollTop*s}while(t!==r&&(t=t.parentNode));return[e,n]}function j(t,e){for(var n in t)if(t.hasOwnProperty(n))for(var r in e)if(e.hasOwnProperty(r)&&e[r]===t[n][r])return Number(n);return-1}function V(t,e){if(!t||!t.getBoundingClientRect)return B();var n=t,r=!1;do{if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var i=M(n);if(n.clientWidth<n.scrollWidth&&("auto"==i.overflowX||"scroll"==i.overflowX)||n.clientHeight<n.scrollHeight&&("auto"==i.overflowY||"scroll"==i.overflowY)){if(!n.getBoundingClientRect||n===document.body)return B();if(r||e)return n;r=!0}}}while(n=n.parentNode);return B()}function Y(t,e){if(t&&e)for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function W(t,e){return Math.round(t.top)===Math.round(e.top)&&Math.round(t.left)===Math.round(e.left)&&Math.round(t.height)===Math.round(e.height)&&Math.round(t.width)===Math.round(e.width)}function z(t,e){return function(){if(!C){var n=arguments,r=this;1===n.length?t.call(r,n[0]):t.apply(r,n),C=setTimeout((function(){C=void 0}),e)}}}function $(){clearTimeout(C),C=void 0}function q(t,e,n){t.scrollLeft+=e,t.scrollTop+=n}function K(t){var e=window.Polymer,n=window.jQuery||window.Zepto;return e&&e.dom?e.dom(t).cloneNode(!0):n?n(t).clone(!0)[0]:t.cloneNode(!0)}function Z(t,e){M(t,"position","absolute"),M(t,"top",e.top),M(t,"left",e.left),M(t,"width",e.width),M(t,"height",e.height)}function J(t){M(t,"position",""),M(t,"top",""),M(t,"left",""),M(t,"width",""),M(t,"height","")}var Q="Sortable"+(new Date).getTime();function tt(){var t,e=[];return{captureAnimationState:function(){if(e=[],this.options.animation){var t=[].slice.call(this.el.children);t.forEach((function(t){if("none"!==M(t,"display")&&t!==ne.ghost){e.push({target:t,rect:F(t)});var n=i({},e[e.length-1].rect);if(t.thisAnimationDuration){var r=D(t,!0);r&&(n.top-=r.f,n.left-=r.e)}t.fromRect=n}}))}},addAnimationState:function(t){e.push(t)},removeAnimationState:function(t){e.splice(j(e,{target:t}),1)},animateAll:function(n){var r=this;if(!this.options.animation)return clearTimeout(t),void("function"===typeof n&&n());var i=!1,o=0;e.forEach((function(t){var e=0,n=t.target,s=n.fromRect,a=F(n),u=n.prevFromRect,l=n.prevToRect,c=t.rect,h=D(n,!0);h&&(a.top-=h.f,a.left-=h.e),n.toRect=a,n.thisAnimationDuration&&W(u,a)&&!W(s,a)&&(c.top-a.top)/(c.left-a.left)===(s.top-a.top)/(s.left-a.left)&&(e=nt(c,u,l,r.options)),W(a,s)||(n.prevFromRect=s,n.prevToRect=a,e||(e=r.options.animation),r.animate(n,c,a,e)),e&&(i=!0,o=Math.max(o,e),clearTimeout(n.animationResetTimer),n.animationResetTimer=setTimeout((function(){n.animationTime=0,n.prevFromRect=null,n.fromRect=null,n.prevToRect=null,n.thisAnimationDuration=null}),e),n.thisAnimationDuration=e)})),clearTimeout(t),i?t=setTimeout((function(){"function"===typeof n&&n()}),o):"function"===typeof n&&n(),e=[]},animate:function(t,e,n,r){if(r){M(t,"transition",""),M(t,"transform","");var i=D(this.el),o=i&&i.a,s=i&&i.d,a=(e.left-n.left)/(o||1),u=(e.top-n.top)/(s||1);t.animatingX=!!a,t.animatingY=!!u,M(t,"transform","translate3d("+a+"px,"+u+"px,0)"),this.forRepaintDummy=et(t),M(t,"transition","transform "+r+"ms"+(this.options.easing?" "+this.options.easing:"")),M(t,"transform","translate3d(0,0,0)"),"number"===typeof t.animated&&clearTimeout(t.animated),t.animated=setTimeout((function(){M(t,"transition",""),M(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1}),r)}}}}function et(t){return t.offsetWidth}function nt(t,e,n,r){return Math.sqrt(Math.pow(e.top-t.top,2)+Math.pow(e.left-t.left,2))/Math.sqrt(Math.pow(e.top-n.top,2)+Math.pow(e.left-n.left,2))*r.animation}var rt=[],it={initializeByDefault:!0},ot={mount:function(t){for(var e in it)it.hasOwnProperty(e)&&!(e in t)&&(t[e]=it[e]);rt.forEach((function(e){if(e.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")})),rt.push(t)},pluginEvent:function(t,e,n){var r=this;this.eventCanceled=!1,n.cancel=function(){r.eventCanceled=!0};var o=t+"Global";rt.forEach((function(r){e[r.pluginName]&&(e[r.pluginName][o]&&e[r.pluginName][o](i({sortable:e},n)),e.options[r.pluginName]&&e[r.pluginName][t]&&e[r.pluginName][t](i({sortable:e},n)))}))},initializePlugins:function(t,e,n,r){for(var i in rt.forEach((function(r){var i=r.pluginName;if(t.options[i]||r.initializeByDefault){var o=new r(t,e,t.options);o.sortable=t,o.options=t.options,t[i]=o,a(n,o.defaults)}})),t.options)if(t.options.hasOwnProperty(i)){var o=this.modifyOption(t,i,t.options[i]);"undefined"!==typeof o&&(t.options[i]=o)}},getEventProperties:function(t,e){var n={};return rt.forEach((function(r){"function"===typeof r.eventProperties&&a(n,r.eventProperties.call(e[r.pluginName],t))})),n},modifyOption:function(t,e,n){var r;return rt.forEach((function(i){t[i.pluginName]&&i.optionListeners&&"function"===typeof i.optionListeners[e]&&(r=i.optionListeners[e].call(t[i.pluginName],n))})),r}};function st(t){var e=t.sortable,n=t.rootEl,r=t.name,o=t.targetEl,s=t.cloneEl,a=t.toEl,u=t.fromEl,l=t.oldIndex,c=t.newIndex,h=t.oldDraggableIndex,f=t.newDraggableIndex,d=t.originalEvent,p=t.putSortable,m=t.extraEventProperties;if(e=e||n&&n[Q],e){var v,g=e.options,b="on"+r.charAt(0).toUpperCase()+r.substr(1);!window.CustomEvent||_||y?(v=document.createEvent("Event"),v.initEvent(r,!0,!0)):v=new CustomEvent(r,{bubbles:!0,cancelable:!0}),v.to=a||n,v.from=u||n,v.item=o||n,v.clone=s,v.oldIndex=l,v.newIndex=c,v.oldDraggableIndex=h,v.newDraggableIndex=f,v.originalEvent=d,v.pullMode=p?p.lastPutMode:void 0;var E=i(i({},m),ot.getEventProperties(r,e));for(var T in E)v[T]=E[T];n&&n.dispatchEvent(v),g[b]&&g[b].call(e,v)}}var at=["evt"],ut=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.evt,o=l(n,at);ot.pluginEvent.bind(ne)(t,e,i({dragEl:ct,parentEl:ht,ghostEl:ft,rootEl:dt,nextEl:pt,lastDownEl:mt,cloneEl:vt,cloneHidden:gt,dragStarted:Ct,putSortable:xt,activeSortable:ne.active,originalEvent:r,oldIndex:_t,oldDraggableIndex:bt,newIndex:yt,newDraggableIndex:Et,hideGhostForTarget:Jt,unhideGhostForTarget:Qt,cloneNowHidden:function(){gt=!0},cloneNowShown:function(){gt=!1},dispatchSortableEvent:function(t){lt({sortable:e,name:t,originalEvent:r})}},o))};function lt(t){st(i({putSortable:xt,cloneEl:vt,targetEl:ct,rootEl:dt,oldIndex:_t,oldDraggableIndex:bt,newIndex:yt,newDraggableIndex:Et},t))}var ct,ht,ft,dt,pt,mt,vt,gt,_t,yt,bt,Et,Tt,xt,St,Rt,At,Ot,It,wt,Ct,Pt,Nt,Mt,Dt,Lt=!1,Bt=!1,Ft=[],Ut=!1,Gt=!1,kt=[],Xt=!1,Ht=[],jt="undefined"!==typeof document,Vt=T,Yt=y||_?"cssFloat":"float",Wt=jt&&!x&&!T&&"draggable"in document.createElement("div"),zt=function(){if(jt){if(_)return!1;var t=document.createElement("x");return t.style.cssText="pointer-events:auto","auto"===t.style.pointerEvents}}(),$t=function(t,e){var n=M(t),r=parseInt(n.width)-parseInt(n.paddingLeft)-parseInt(n.paddingRight)-parseInt(n.borderLeftWidth)-parseInt(n.borderRightWidth),i=G(t,0,e),o=G(t,1,e),s=i&&M(i),a=o&&M(o),u=s&&parseInt(s.marginLeft)+parseInt(s.marginRight)+F(i).width,l=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+F(o).width;if("flex"===n.display)return"column"===n.flexDirection||"column-reverse"===n.flexDirection?"vertical":"horizontal";if("grid"===n.display)return n.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(i&&s["float"]&&"none"!==s["float"]){var c="left"===s["float"]?"left":"right";return!o||"both"!==a.clear&&a.clear!==c?"horizontal":"vertical"}return i&&("block"===s.display||"flex"===s.display||"table"===s.display||"grid"===s.display||u>=r&&"none"===n[Yt]||o&&"none"===n[Yt]&&u+l>r)?"vertical":"horizontal"},qt=function(t,e,n){var r=n?t.left:t.top,i=n?t.right:t.bottom,o=n?t.width:t.height,s=n?e.left:e.top,a=n?e.right:e.bottom,u=n?e.width:e.height;return r===s||i===a||r+o/2===s+u/2},Kt=function(t,e){var n;return Ft.some((function(r){var i=r[Q].options.emptyInsertThreshold;if(i&&!k(r)){var o=F(r),s=t>=o.left-i&&t<=o.right+i,a=e>=o.top-i&&e<=o.bottom+i;return s&&a?n=r:void 0}})),n},Zt=function(t){function e(t,n){return function(r,i,o,s){var a=r.options.group.name&&i.options.group.name&&r.options.group.name===i.options.group.name;if(null==t&&(n||a))return!0;if(null==t||!1===t)return!1;if(n&&"clone"===t)return t;if("function"===typeof t)return e(t(r,i,o,s),n)(r,i,o,s);var u=(n?r:i).options.group.name;return!0===t||"string"===typeof t&&t===u||t.join&&t.indexOf(u)>-1}}var n={},r=t.group;r&&"object"==o(r)||(r={name:r}),n.name=r.name,n.checkPull=e(r.pull,!0),n.checkPut=e(r.put),n.revertClone=r.revertClone,t.group=n},Jt=function(){!zt&&ft&&M(ft,"display","none")},Qt=function(){!zt&&ft&&M(ft,"display","")};jt&&document.addEventListener("click",(function(t){if(Bt)return t.preventDefault(),t.stopPropagation&&t.stopPropagation(),t.stopImmediatePropagation&&t.stopImmediatePropagation(),Bt=!1,!1}),!0);var te=function(t){if(ct){t=t.touches?t.touches[0]:t;var e=Kt(t.clientX,t.clientY);if(e){var n={};for(var r in t)t.hasOwnProperty(r)&&(n[r]=t[r]);n.target=n.rootEl=e,n.preventDefault=void 0,n.stopPropagation=void 0,e[Q]._onDragOver(n)}}},ee=function(t){ct&&ct.parentNode[Q]._isOutsideThisEl(t.target)};function ne(t,e){if(!t||!t.nodeType||1!==t.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=e=a({},e),t[Q]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return $t(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(t,e){t.setData("Text",e.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==ne.supportPointer&&"PointerEvent"in window&&!E,emptyInsertThreshold:5};for(var r in ot.initializePlugins(this,t,n),n)!(r in e)&&(e[r]=n[r]);for(var i in Zt(e),this)"_"===i.charAt(0)&&"function"===typeof this[i]&&(this[i]=this[i].bind(this));this.nativeDraggable=!e.forceFallback&&Wt,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?R(t,"pointerdown",this._onTapStart):(R(t,"mousedown",this._onTapStart),R(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(R(t,"dragover",this),R(t,"dragenter",this)),Ft.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),a(this,tt())}function re(t){t.dataTransfer&&(t.dataTransfer.dropEffect="move"),t.cancelable&&t.preventDefault()}function ie(t,e,n,r,i,o,s,a){var u,l,c=t[Q],h=c.options.onMove;return!window.CustomEvent||_||y?(u=document.createEvent("Event"),u.initEvent("move",!0,!0)):u=new CustomEvent("move",{bubbles:!0,cancelable:!0}),u.to=e,u.from=t,u.dragged=n,u.draggedRect=r,u.related=i||e,u.relatedRect=o||F(e),u.willInsertAfter=a,u.originalEvent=s,t.dispatchEvent(u),h&&(l=h.call(c,u,s)),l}function oe(t){t.draggable=!1}function se(){Xt=!1}function ae(t,e,n){var r=F(G(n.el,0,n.options,!0)),i=10;return e?t.clientX<r.left-i||t.clientY<r.top&&t.clientX<r.right:t.clientY<r.top-i||t.clientY<r.bottom&&t.clientX<r.left}function ue(t,e,n){var r=F(k(n.el,n.options.draggable)),i=10;return e?t.clientX>r.right+i||t.clientX<=r.right&&t.clientY>r.bottom&&t.clientX>=r.left:t.clientX>r.right&&t.clientY>r.top||t.clientX<=r.right&&t.clientY>r.bottom+i}function le(t,e,n,r,i,o,s,a){var u=r?t.clientY:t.clientX,l=r?n.height:n.width,c=r?n.top:n.left,h=r?n.bottom:n.right,f=!1;if(!s)if(a&&Mt<l*i){if(!Ut&&(1===Nt?u>c+l*o/2:u<h-l*o/2)&&(Ut=!0),Ut)f=!0;else if(1===Nt?u<c+Mt:u>h-Mt)return-Nt}else if(u>c+l*(1-i)/2&&u<h-l*(1-i)/2)return ce(e);return f=f||s,f&&(u<c+l*o/2||u>h-l*o/2)?u>c+l/2?1:-1:0}function ce(t){return X(ct)<X(t)?1:-1}function he(t){var e=t.tagName+t.className+t.src+t.href+t.textContent,n=e.length,r=0;while(n--)r+=e.charCodeAt(n);return r.toString(36)}function fe(t){Ht.length=0;var e=t.getElementsByTagName("input"),n=e.length;while(n--){var r=e[n];r.checked&&Ht.push(r)}}function de(t){return setTimeout(t,0)}function pe(t){return clearTimeout(t)}ne.prototype={constructor:ne,_isOutsideThisEl:function(t){this.el.contains(t)||t===this.el||(Pt=null)},_getDirection:function(t,e){return"function"===typeof this.options.direction?this.options.direction.call(this,t,e,ct):this.options.direction},_onTapStart:function(t){if(t.cancelable){var e=this,n=this.el,r=this.options,i=r.preventOnFilter,o=t.type,s=t.touches&&t.touches[0]||t.pointerType&&"touch"===t.pointerType&&t,a=(s||t).target,u=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||a,l=r.filter;if(fe(n),!ct&&!(/mousedown|pointerdown/.test(o)&&0!==t.button||r.disabled)&&!u.isContentEditable&&(this.nativeDraggable||!E||!a||"SELECT"!==a.tagName.toUpperCase())&&(a=w(a,r.draggable,n,!1),(!a||!a.animated)&&mt!==a)){if(_t=X(a),bt=X(a,r.draggable),"function"===typeof l){if(l.call(this,t,a,this))return lt({sortable:e,rootEl:u,name:"filter",targetEl:a,toEl:n,fromEl:n}),ut("filter",e,{evt:t}),void(i&&t.cancelable&&t.preventDefault())}else if(l&&(l=l.split(",").some((function(r){if(r=w(u,r.trim(),n,!1),r)return lt({sortable:e,rootEl:r,name:"filter",targetEl:a,fromEl:n,toEl:n}),ut("filter",e,{evt:t}),!0})),l))return void(i&&t.cancelable&&t.preventDefault());r.handle&&!w(u,r.handle,n,!1)||this._prepareDragStart(t,s,a)}}},_prepareDragStart:function(t,e,n){var r,i=this,o=i.el,s=i.options,a=o.ownerDocument;if(n&&!ct&&n.parentNode===o){var u=F(n);if(dt=o,ct=n,ht=ct.parentNode,pt=ct.nextSibling,mt=n,Tt=s.group,ne.dragged=ct,St={target:ct,clientX:(e||t).clientX,clientY:(e||t).clientY},It=St.clientX-u.left,wt=St.clientY-u.top,this._lastX=(e||t).clientX,this._lastY=(e||t).clientY,ct.style["will-change"]="all",r=function(){ut("delayEnded",i,{evt:t}),ne.eventCanceled?i._onDrop():(i._disableDelayedDragEvents(),!b&&i.nativeDraggable&&(ct.draggable=!0),i._triggerDragStart(t,e),lt({sortable:i,name:"choose",originalEvent:t}),N(ct,s.chosenClass,!0))},s.ignore.split(",").forEach((function(t){L(ct,t.trim(),oe)})),R(a,"dragover",te),R(a,"mousemove",te),R(a,"touchmove",te),R(a,"mouseup",i._onDrop),R(a,"touchend",i._onDrop),R(a,"touchcancel",i._onDrop),b&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ct.draggable=!0),ut("delayStart",this,{evt:t}),!s.delay||s.delayOnTouchOnly&&!e||this.nativeDraggable&&(y||_))r();else{if(ne.eventCanceled)return void this._onDrop();R(a,"mouseup",i._disableDelayedDrag),R(a,"touchend",i._disableDelayedDrag),R(a,"touchcancel",i._disableDelayedDrag),R(a,"mousemove",i._delayedDragTouchMoveHandler),R(a,"touchmove",i._delayedDragTouchMoveHandler),s.supportPointer&&R(a,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(r,s.delay)}}},_delayedDragTouchMoveHandler:function(t){var e=t.touches?t.touches[0]:t;Math.max(Math.abs(e.clientX-this._lastX),Math.abs(e.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ct&&oe(ct),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;A(t,"mouseup",this._disableDelayedDrag),A(t,"touchend",this._disableDelayedDrag),A(t,"touchcancel",this._disableDelayedDrag),A(t,"mousemove",this._delayedDragTouchMoveHandler),A(t,"touchmove",this._delayedDragTouchMoveHandler),A(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,e){e=e||"touch"==t.pointerType&&t,!this.nativeDraggable||e?this.options.supportPointer?R(document,"pointermove",this._onTouchMove):R(document,e?"touchmove":"mousemove",this._onTouchMove):(R(ct,"dragend",this),R(dt,"dragstart",this._onDragStart));try{document.selection?de((function(){document.selection.empty()})):window.getSelection().removeAllRanges()}catch(n){}},_dragStarted:function(t,e){if(Lt=!1,dt&&ct){ut("dragStarted",this,{evt:e}),this.nativeDraggable&&R(document,"dragover",ee);var n=this.options;!t&&N(ct,n.dragClass,!1),N(ct,n.ghostClass,!0),ne.active=this,t&&this._appendGhost(),lt({sortable:this,name:"start",originalEvent:e})}else this._nulling()},_emulateDragOver:function(){if(Rt){this._lastX=Rt.clientX,this._lastY=Rt.clientY,Jt();var t=document.elementFromPoint(Rt.clientX,Rt.clientY),e=t;while(t&&t.shadowRoot){if(t=t.shadowRoot.elementFromPoint(Rt.clientX,Rt.clientY),t===e)break;e=t}if(ct.parentNode[Q]._isOutsideThisEl(t),e)do{if(e[Q]){var n=void 0;if(n=e[Q]._onDragOver({clientX:Rt.clientX,clientY:Rt.clientY,target:t,rootEl:e}),n&&!this.options.dragoverBubble)break}t=e}while(e=e.parentNode);Qt()}},_onTouchMove:function(t){if(St){var e=this.options,n=e.fallbackTolerance,r=e.fallbackOffset,i=t.touches?t.touches[0]:t,o=ft&&D(ft,!0),s=ft&&o&&o.a,a=ft&&o&&o.d,u=Vt&&Dt&&H(Dt),l=(i.clientX-St.clientX+r.x)/(s||1)+(u?u[0]-kt[0]:0)/(s||1),c=(i.clientY-St.clientY+r.y)/(a||1)+(u?u[1]-kt[1]:0)/(a||1);if(!ne.active&&!Lt){if(n&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))<n)return;this._onDragStart(t,!0)}if(ft){o?(o.e+=l-(At||0),o.f+=c-(Ot||0)):o={a:1,b:0,c:0,d:1,e:l,f:c};var h="matrix(".concat(o.a,",").concat(o.b,",").concat(o.c,",").concat(o.d,",").concat(o.e,",").concat(o.f,")");M(ft,"webkitTransform",h),M(ft,"mozTransform",h),M(ft,"msTransform",h),M(ft,"transform",h),At=l,Ot=c,Rt=i}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!ft){var t=this.options.fallbackOnBody?document.body:dt,e=F(ct,!0,Vt,!0,t),n=this.options;if(Vt){Dt=t;while("static"===M(Dt,"position")&&"none"===M(Dt,"transform")&&Dt!==document)Dt=Dt.parentNode;Dt!==document.body&&Dt!==document.documentElement?(Dt===document&&(Dt=B()),e.top+=Dt.scrollTop,e.left+=Dt.scrollLeft):Dt=B(),kt=H(Dt)}ft=ct.cloneNode(!0),N(ft,n.ghostClass,!1),N(ft,n.fallbackClass,!0),N(ft,n.dragClass,!0),M(ft,"transition",""),M(ft,"transform",""),M(ft,"box-sizing","border-box"),M(ft,"margin",0),M(ft,"top",e.top),M(ft,"left",e.left),M(ft,"width",e.width),M(ft,"height",e.height),M(ft,"opacity","0.8"),M(ft,"position",Vt?"absolute":"fixed"),M(ft,"zIndex","100000"),M(ft,"pointerEvents","none"),ne.ghost=ft,t.appendChild(ft),M(ft,"transform-origin",It/parseInt(ft.style.width)*100+"% "+wt/parseInt(ft.style.height)*100+"%")}},_onDragStart:function(t,e){var n=this,r=t.dataTransfer,i=n.options;ut("dragStart",this,{evt:t}),ne.eventCanceled?this._onDrop():(ut("setupClone",this),ne.eventCanceled||(vt=K(ct),vt.draggable=!1,vt.style["will-change"]="",this._hideClone(),N(vt,this.options.chosenClass,!1),ne.clone=vt),n.cloneId=de((function(){ut("clone",n),ne.eventCanceled||(n.options.removeCloneOnHide||dt.insertBefore(vt,ct),n._hideClone(),lt({sortable:n,name:"clone"}))})),!e&&N(ct,i.dragClass,!0),e?(Bt=!0,n._loopId=setInterval(n._emulateDragOver,50)):(A(document,"mouseup",n._onDrop),A(document,"touchend",n._onDrop),A(document,"touchcancel",n._onDrop),r&&(r.effectAllowed="move",i.setData&&i.setData.call(n,r,ct)),R(document,"drop",n),M(ct,"transform","translateZ(0)")),Lt=!0,n._dragStartId=de(n._dragStarted.bind(n,e,t)),R(document,"selectstart",n),Ct=!0,E&&M(document.body,"user-select","none"))},_onDragOver:function(t){var e,n,r,o,s=this.el,a=t.target,u=this.options,l=u.group,c=ne.active,h=Tt===l,f=u.sort,d=xt||c,p=this,m=!1;if(!Xt){if(void 0!==t.preventDefault&&t.cancelable&&t.preventDefault(),a=w(a,u.draggable,s,!0),P("dragOver"),ne.eventCanceled)return m;if(ct.contains(t.target)||a.animated&&a.animatingX&&a.animatingY||p._ignoreWhileAnimating===a)return L(!1);if(Bt=!1,c&&!u.disabled&&(h?f||(r=ht!==dt):xt===this||(this.lastPutMode=Tt.checkPull(this,c,ct,t))&&l.checkPut(this,c,ct,t))){if(o="vertical"===this._getDirection(t,a),e=F(ct),P("dragOverValid"),ne.eventCanceled)return m;if(r)return ht=dt,D(),this._hideClone(),P("revert"),ne.eventCanceled||(pt?dt.insertBefore(ct,pt):dt.appendChild(ct)),L(!0);var v=k(s,u.draggable);if(!v||ue(t,o,this)&&!v.animated){if(v===ct)return L(!1);if(v&&s===t.target&&(a=v),a&&(n=F(a)),!1!==ie(dt,s,ct,e,a,n,t,!!a))return D(),s.appendChild(ct),ht=s,B(),L(!0)}else if(v&&ae(t,o,this)){var g=G(s,0,u,!0);if(g===ct)return L(!1);if(a=g,n=F(a),!1!==ie(dt,s,ct,e,a,n,t,!1))return D(),s.insertBefore(ct,g),ht=s,B(),L(!0)}else if(a.parentNode===s){n=F(a);var _,y,b=0,E=ct.parentNode!==s,T=!qt(ct.animated&&ct.toRect||e,a.animated&&a.toRect||n,o),x=o?"top":"left",S=U(a,"top","top")||U(ct,"top","top"),R=S?S.scrollTop:void 0;if(Pt!==a&&(_=n[x],Ut=!1,Gt=!T&&u.invertSwap||E),b=le(t,a,n,o,T?1:u.swapThreshold,null==u.invertedSwapThreshold?u.swapThreshold:u.invertedSwapThreshold,Gt,Pt===a),0!==b){var A=X(ct);do{A-=b,y=ht.children[A]}while(y&&("none"===M(y,"display")||y===ft))}if(0===b||y===a)return L(!1);Pt=a,Nt=b;var O=a.nextElementSibling,I=!1;I=1===b;var C=ie(dt,s,ct,e,a,n,t,I);if(!1!==C)return 1!==C&&-1!==C||(I=1===C),Xt=!0,setTimeout(se,30),D(),I&&!O?s.appendChild(ct):a.parentNode.insertBefore(ct,I?O:a),S&&q(S,0,R-S.scrollTop),ht=ct.parentNode,void 0===_||Gt||(Mt=Math.abs(_-F(a)[x])),B(),L(!0)}if(s.contains(ct))return L(!1)}return!1}function P(u,l){ut(u,p,i({evt:t,isOwner:h,axis:o?"vertical":"horizontal",revert:r,dragRect:e,targetRect:n,canSort:f,fromSortable:d,target:a,completed:L,onMove:function(n,r){return ie(dt,s,ct,e,n,F(n),t,r)},changed:B},l))}function D(){P("dragOverAnimationCapture"),p.captureAnimationState(),p!==d&&d.captureAnimationState()}function L(e){return P("dragOverCompleted",{insertion:e}),e&&(h?c._hideClone():c._showClone(p),p!==d&&(N(ct,xt?xt.options.ghostClass:c.options.ghostClass,!1),N(ct,u.ghostClass,!0)),xt!==p&&p!==ne.active?xt=p:p===ne.active&&xt&&(xt=null),d===p&&(p._ignoreWhileAnimating=a),p.animateAll((function(){P("dragOverAnimationComplete"),p._ignoreWhileAnimating=null})),p!==d&&(d.animateAll(),d._ignoreWhileAnimating=null)),(a===ct&&!ct.animated||a===s&&!a.animated)&&(Pt=null),u.dragoverBubble||t.rootEl||a===document||(ct.parentNode[Q]._isOutsideThisEl(t.target),!e&&te(t)),!u.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),m=!0}function B(){yt=X(ct),Et=X(ct,u.draggable),lt({sortable:p,name:"change",toEl:s,newIndex:yt,newDraggableIndex:Et,originalEvent:t})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){A(document,"mousemove",this._onTouchMove),A(document,"touchmove",this._onTouchMove),A(document,"pointermove",this._onTouchMove),A(document,"dragover",te),A(document,"mousemove",te),A(document,"touchmove",te)},_offUpEvents:function(){var t=this.el.ownerDocument;A(t,"mouseup",this._onDrop),A(t,"touchend",this._onDrop),A(t,"pointerup",this._onDrop),A(t,"touchcancel",this._onDrop),A(document,"selectstart",this)},_onDrop:function(t){var e=this.el,n=this.options;yt=X(ct),Et=X(ct,n.draggable),ut("drop",this,{evt:t}),ht=ct&&ct.parentNode,yt=X(ct),Et=X(ct,n.draggable),ne.eventCanceled||(Lt=!1,Gt=!1,Ut=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),pe(this.cloneId),pe(this._dragStartId),this.nativeDraggable&&(A(document,"drop",this),A(e,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),E&&M(document.body,"user-select",""),M(ct,"transform",""),t&&(Ct&&(t.cancelable&&t.preventDefault(),!n.dropBubble&&t.stopPropagation()),ft&&ft.parentNode&&ft.parentNode.removeChild(ft),(dt===ht||xt&&"clone"!==xt.lastPutMode)&&vt&&vt.parentNode&&vt.parentNode.removeChild(vt),ct&&(this.nativeDraggable&&A(ct,"dragend",this),oe(ct),ct.style["will-change"]="",Ct&&!Lt&&N(ct,xt?xt.options.ghostClass:this.options.ghostClass,!1),N(ct,this.options.chosenClass,!1),lt({sortable:this,name:"unchoose",toEl:ht,newIndex:null,newDraggableIndex:null,originalEvent:t}),dt!==ht?(yt>=0&&(lt({rootEl:ht,name:"add",toEl:ht,fromEl:dt,originalEvent:t}),lt({sortable:this,name:"remove",toEl:ht,originalEvent:t}),lt({rootEl:ht,name:"sort",toEl:ht,fromEl:dt,originalEvent:t}),lt({sortable:this,name:"sort",toEl:ht,originalEvent:t})),xt&&xt.save()):yt!==_t&&yt>=0&&(lt({sortable:this,name:"update",toEl:ht,originalEvent:t}),lt({sortable:this,name:"sort",toEl:ht,originalEvent:t})),ne.active&&(null!=yt&&-1!==yt||(yt=_t,Et=bt),lt({sortable:this,name:"end",toEl:ht,originalEvent:t}),this.save())))),this._nulling()},_nulling:function(){ut("nulling",this),dt=ct=ht=ft=pt=vt=mt=gt=St=Rt=Ct=yt=Et=_t=bt=Pt=Nt=xt=Tt=ne.dragged=ne.ghost=ne.clone=ne.active=null,Ht.forEach((function(t){t.checked=!0})),Ht.length=At=Ot=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":ct&&(this._onDragOver(t),re(t));break;case"selectstart":t.preventDefault();break}},toArray:function(){for(var t,e=[],n=this.el.children,r=0,i=n.length,o=this.options;r<i;r++)t=n[r],w(t,o.draggable,this.el,!1)&&e.push(t.getAttribute(o.dataIdAttr)||he(t));return e},sort:function(t,e){var n={},r=this.el;this.toArray().forEach((function(t,e){var i=r.children[e];w(i,this.options.draggable,r,!1)&&(n[t]=i)}),this),e&&this.captureAnimationState(),t.forEach((function(t){n[t]&&(r.removeChild(n[t]),r.appendChild(n[t]))})),e&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,e){return w(t,e||this.options.draggable,this.el,!1)},option:function(t,e){var n=this.options;if(void 0===e)return n[t];var r=ot.modifyOption(this,t,e);n[t]="undefined"!==typeof r?r:e,"group"===t&&Zt(n)},destroy:function(){ut("destroy",this);var t=this.el;t[Q]=null,A(t,"mousedown",this._onTapStart),A(t,"touchstart",this._onTapStart),A(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(A(t,"dragover",this),A(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),(function(t){t.removeAttribute("draggable")})),this._onDrop(),this._disableDelayedDragEvents(),Ft.splice(Ft.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!gt){if(ut("hideClone",this),ne.eventCanceled)return;M(vt,"display","none"),this.options.removeCloneOnHide&&vt.parentNode&&vt.parentNode.removeChild(vt),gt=!0}},_showClone:function(t){if("clone"===t.lastPutMode){if(gt){if(ut("showClone",this),ne.eventCanceled)return;ct.parentNode!=dt||this.options.group.revertClone?pt?dt.insertBefore(vt,pt):dt.appendChild(vt):dt.insertBefore(vt,ct),this.options.group.revertClone&&this.animate(ct,vt),M(vt,"display",""),gt=!1}}else this._hideClone()}},jt&&R(document,"touchmove",(function(t){(ne.active||Lt)&&t.cancelable&&t.preventDefault()})),ne.utils={on:R,off:A,css:M,find:L,is:function(t,e){return!!w(t,e,t,!1)},extend:Y,throttle:z,closest:w,toggleClass:N,clone:K,index:X,nextTick:de,cancelNextTick:pe,detectDirection:$t,getChild:G},ne.get=function(t){return t[Q]},ne.mount=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];e[0].constructor===Array&&(e=e[0]),e.forEach((function(t){if(!t.prototype||!t.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(t));t.utils&&(ne.utils=i(i({},ne.utils),t.utils)),ot.mount(t)}))},ne.create=function(t,e){return new ne(t,e)},ne.version=v;var me,ve,ge,_e,ye,be,Ee=[],Te=!1;function xe(){function t(){for(var t in this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0},this)"_"===t.charAt(0)&&"function"===typeof this[t]&&(this[t]=this[t].bind(this))}return t.prototype={dragStarted:function(t){var e=t.originalEvent;this.sortable.nativeDraggable?R(document,"dragover",this._handleAutoScroll):this.options.supportPointer?R(document,"pointermove",this._handleFallbackAutoScroll):e.touches?R(document,"touchmove",this._handleFallbackAutoScroll):R(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var e=t.originalEvent;this.options.dragOverBubble||e.rootEl||this._handleAutoScroll(e)},drop:function(){this.sortable.nativeDraggable?A(document,"dragover",this._handleAutoScroll):(A(document,"pointermove",this._handleFallbackAutoScroll),A(document,"touchmove",this._handleFallbackAutoScroll),A(document,"mousemove",this._handleFallbackAutoScroll)),Re(),Se(),$()},nulling:function(){ye=ve=me=Te=be=ge=_e=null,Ee.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(t,e){var n=this,r=(t.touches?t.touches[0]:t).clientX,i=(t.touches?t.touches[0]:t).clientY,o=document.elementFromPoint(r,i);if(ye=t,e||this.options.forceAutoScrollFallback||y||_||E){Oe(t,this.options,o,e);var s=V(o,!0);!Te||be&&r===ge&&i===_e||(be&&Re(),be=setInterval((function(){var o=V(document.elementFromPoint(r,i),!0);o!==s&&(s=o,Se()),Oe(t,n.options,o,e)}),10),ge=r,_e=i)}else{if(!this.options.bubbleScroll||V(o,!0)===B())return void Se();Oe(t,this.options,V(o,!1),!1)}}},a(t,{pluginName:"scroll",initializeByDefault:!0})}function Se(){Ee.forEach((function(t){clearInterval(t.pid)})),Ee=[]}function Re(){clearInterval(be)}var Ae,Oe=z((function(t,e,n,r){if(e.scroll){var i,o=(t.touches?t.touches[0]:t).clientX,s=(t.touches?t.touches[0]:t).clientY,a=e.scrollSensitivity,u=e.scrollSpeed,l=B(),c=!1;ve!==n&&(ve=n,Se(),me=e.scroll,i=e.scrollFn,!0===me&&(me=V(n,!0)));var h=0,f=me;do{var d=f,p=F(d),m=p.top,v=p.bottom,g=p.left,_=p.right,y=p.width,b=p.height,E=void 0,T=void 0,x=d.scrollWidth,S=d.scrollHeight,R=M(d),A=d.scrollLeft,O=d.scrollTop;d===l?(E=y<x&&("auto"===R.overflowX||"scroll"===R.overflowX||"visible"===R.overflowX),T=b<S&&("auto"===R.overflowY||"scroll"===R.overflowY||"visible"===R.overflowY)):(E=y<x&&("auto"===R.overflowX||"scroll"===R.overflowX),T=b<S&&("auto"===R.overflowY||"scroll"===R.overflowY));var I=E&&(Math.abs(_-o)<=a&&A+y<x)-(Math.abs(g-o)<=a&&!!A),w=T&&(Math.abs(v-s)<=a&&O+b<S)-(Math.abs(m-s)<=a&&!!O);if(!Ee[h])for(var C=0;C<=h;C++)Ee[C]||(Ee[C]={});Ee[h].vx==I&&Ee[h].vy==w&&Ee[h].el===d||(Ee[h].el=d,Ee[h].vx=I,Ee[h].vy=w,clearInterval(Ee[h].pid),0==I&&0==w||(c=!0,Ee[h].pid=setInterval(function(){r&&0===this.layer&&ne.active._onTouchMove(ye);var e=Ee[this.layer].vy?Ee[this.layer].vy*u:0,n=Ee[this.layer].vx?Ee[this.layer].vx*u:0;"function"===typeof i&&"continue"!==i.call(ne.dragged.parentNode[Q],n,e,t,ye,Ee[this.layer].el)||q(Ee[this.layer].el,n,e)}.bind({layer:h}),24))),h++}while(e.bubbleScroll&&f!==l&&(f=V(f,!1)));Te=c}}),30),Ie=function(t){var e=t.originalEvent,n=t.putSortable,r=t.dragEl,i=t.activeSortable,o=t.dispatchSortableEvent,s=t.hideGhostForTarget,a=t.unhideGhostForTarget;if(e){var u=n||i;s();var l=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e,c=document.elementFromPoint(l.clientX,l.clientY);a(),u&&!u.el.contains(c)&&(o("spill"),this.onSpill({dragEl:r,putSortable:n}))}};function we(){}function Ce(){}function Pe(){function t(){this.defaults={swapClass:"sortable-swap-highlight"}}return t.prototype={dragStart:function(t){var e=t.dragEl;Ae=e},dragOverValid:function(t){var e=t.completed,n=t.target,r=t.onMove,i=t.activeSortable,o=t.changed,s=t.cancel;if(i.options.swap){var a=this.sortable.el,u=this.options;if(n&&n!==a){var l=Ae;!1!==r(n)?(N(n,u.swapClass,!0),Ae=n):Ae=null,l&&l!==Ae&&N(l,u.swapClass,!1)}o(),e(!0),s()}},drop:function(t){var e=t.activeSortable,n=t.putSortable,r=t.dragEl,i=n||this.sortable,o=this.options;Ae&&N(Ae,o.swapClass,!1),Ae&&(o.swap||n&&n.options.swap)&&r!==Ae&&(i.captureAnimationState(),i!==e&&e.captureAnimationState(),Ne(r,Ae),i.animateAll(),i!==e&&e.animateAll())},nulling:function(){Ae=null}},a(t,{pluginName:"swap",eventProperties:function(){return{swapItem:Ae}}})}function Ne(t,e){var n,r,i=t.parentNode,o=e.parentNode;i&&o&&!i.isEqualNode(e)&&!o.isEqualNode(t)&&(n=X(t),r=X(e),i.isEqualNode(o)&&n<r&&r++,i.insertBefore(e,i.children[n]),o.insertBefore(t,o.children[r]))}we.prototype={startIndex:null,dragStart:function(t){var e=t.oldDraggableIndex;this.startIndex=e},onSpill:function(t){var e=t.dragEl,n=t.putSortable;this.sortable.captureAnimationState(),n&&n.captureAnimationState();var r=G(this.sortable.el,this.startIndex,this.options);r?this.sortable.el.insertBefore(e,r):this.sortable.el.appendChild(e),this.sortable.animateAll(),n&&n.animateAll()},drop:Ie},a(we,{pluginName:"revertOnSpill"}),Ce.prototype={onSpill:function(t){var e=t.dragEl,n=t.putSortable,r=n||this.sortable;r.captureAnimationState(),e.parentNode&&e.parentNode.removeChild(e),r.animateAll()},drop:Ie},a(Ce,{pluginName:"removeOnSpill"});var Me,De,Le,Be,Fe,Ue=[],Ge=[],ke=!1,Xe=!1,He=!1;function je(){function t(t){for(var e in this)"_"===e.charAt(0)&&"function"===typeof this[e]&&(this[e]=this[e].bind(this));t.options.supportPointer?R(document,"pointerup",this._deselectMultiDrag):(R(document,"mouseup",this._deselectMultiDrag),R(document,"touchend",this._deselectMultiDrag)),R(document,"keydown",this._checkKeyDown),R(document,"keyup",this._checkKeyUp),this.defaults={selectedClass:"sortable-selected",multiDragKey:null,setData:function(e,n){var r="";Ue.length&&De===t?Ue.forEach((function(t,e){r+=(e?", ":"")+t.textContent})):r=n.textContent,e.setData("Text",r)}}}return t.prototype={multiDragKeyDown:!1,isMultiDrag:!1,delayStartGlobal:function(t){var e=t.dragEl;Le=e},delayEnded:function(){this.isMultiDrag=~Ue.indexOf(Le)},setupClone:function(t){var e=t.sortable,n=t.cancel;if(this.isMultiDrag){for(var r=0;r<Ue.length;r++)Ge.push(K(Ue[r])),Ge[r].sortableIndex=Ue[r].sortableIndex,Ge[r].draggable=!1,Ge[r].style["will-change"]="",N(Ge[r],this.options.selectedClass,!1),Ue[r]===Le&&N(Ge[r],this.options.chosenClass,!1);e._hideClone(),n()}},clone:function(t){var e=t.sortable,n=t.rootEl,r=t.dispatchSortableEvent,i=t.cancel;this.isMultiDrag&&(this.options.removeCloneOnHide||Ue.length&&De===e&&(Ye(!0,n),r("clone"),i()))},showClone:function(t){var e=t.cloneNowShown,n=t.rootEl,r=t.cancel;this.isMultiDrag&&(Ye(!1,n),Ge.forEach((function(t){M(t,"display","")})),e(),Fe=!1,r())},hideClone:function(t){var e=this,n=(t.sortable,t.cloneNowHidden),r=t.cancel;this.isMultiDrag&&(Ge.forEach((function(t){M(t,"display","none"),e.options.removeCloneOnHide&&t.parentNode&&t.parentNode.removeChild(t)})),n(),Fe=!0,r())},dragStartGlobal:function(t){t.sortable;!this.isMultiDrag&&De&&De.multiDrag._deselectMultiDrag(),Ue.forEach((function(t){t.sortableIndex=X(t)})),Ue=Ue.sort((function(t,e){return t.sortableIndex-e.sortableIndex})),He=!0},dragStarted:function(t){var e=this,n=t.sortable;if(this.isMultiDrag){if(this.options.sort&&(n.captureAnimationState(),this.options.animation)){Ue.forEach((function(t){t!==Le&&M(t,"position","absolute")}));var r=F(Le,!1,!0,!0);Ue.forEach((function(t){t!==Le&&Z(t,r)})),Xe=!0,ke=!0}n.animateAll((function(){Xe=!1,ke=!1,e.options.animation&&Ue.forEach((function(t){J(t)})),e.options.sort&&We()}))}},dragOver:function(t){var e=t.target,n=t.completed,r=t.cancel;Xe&&~Ue.indexOf(e)&&(n(!1),r())},revert:function(t){var e=t.fromSortable,n=t.rootEl,r=t.sortable,i=t.dragRect;Ue.length>1&&(Ue.forEach((function(t){r.addAnimationState({target:t,rect:Xe?F(t):i}),J(t),t.fromRect=i,e.removeAnimationState(t)})),Xe=!1,Ve(!this.options.removeCloneOnHide,n))},dragOverCompleted:function(t){var e=t.sortable,n=t.isOwner,r=t.insertion,i=t.activeSortable,o=t.parentEl,s=t.putSortable,a=this.options;if(r){if(n&&i._hideClone(),ke=!1,a.animation&&Ue.length>1&&(Xe||!n&&!i.options.sort&&!s)){var u=F(Le,!1,!0,!0);Ue.forEach((function(t){t!==Le&&(Z(t,u),o.appendChild(t))})),Xe=!0}if(!n)if(Xe||We(),Ue.length>1){var l=Fe;i._showClone(e),i.options.animation&&!Fe&&l&&Ge.forEach((function(t){i.addAnimationState({target:t,rect:Be}),t.fromRect=Be,t.thisAnimationDuration=null}))}else i._showClone(e)}},dragOverAnimationCapture:function(t){var e=t.dragRect,n=t.isOwner,r=t.activeSortable;if(Ue.forEach((function(t){t.thisAnimationDuration=null})),r.options.animation&&!n&&r.multiDrag.isMultiDrag){Be=a({},e);var i=D(Le,!0);Be.top-=i.f,Be.left-=i.e}},dragOverAnimationComplete:function(){Xe&&(Xe=!1,We())},drop:function(t){var e=t.originalEvent,n=t.rootEl,r=t.parentEl,i=t.sortable,o=t.dispatchSortableEvent,s=t.oldIndex,a=t.putSortable,u=a||this.sortable;if(e){var l=this.options,c=r.children;if(!He)if(l.multiDragKey&&!this.multiDragKeyDown&&this._deselectMultiDrag(),N(Le,l.selectedClass,!~Ue.indexOf(Le)),~Ue.indexOf(Le))Ue.splice(Ue.indexOf(Le),1),Me=null,st({sortable:i,rootEl:n,name:"deselect",targetEl:Le,originalEvt:e});else{if(Ue.push(Le),st({sortable:i,rootEl:n,name:"select",targetEl:Le,originalEvt:e}),e.shiftKey&&Me&&i.el.contains(Me)){var h,f,d=X(Me),p=X(Le);if(~d&&~p&&d!==p)for(p>d?(f=d,h=p):(f=p,h=d+1);f<h;f++)~Ue.indexOf(c[f])||(N(c[f],l.selectedClass,!0),Ue.push(c[f]),st({sortable:i,rootEl:n,name:"select",targetEl:c[f],originalEvt:e}))}else Me=Le;De=u}if(He&&this.isMultiDrag){if(Xe=!1,(r[Q].options.sort||r!==n)&&Ue.length>1){var m=F(Le),v=X(Le,":not(."+this.options.selectedClass+")");if(!ke&&l.animation&&(Le.thisAnimationDuration=null),u.captureAnimationState(),!ke&&(l.animation&&(Le.fromRect=m,Ue.forEach((function(t){if(t.thisAnimationDuration=null,t!==Le){var e=Xe?F(t):m;t.fromRect=e,u.addAnimationState({target:t,rect:e})}}))),We(),Ue.forEach((function(t){c[v]?r.insertBefore(t,c[v]):r.appendChild(t),v++})),s===X(Le))){var g=!1;Ue.forEach((function(t){t.sortableIndex===X(t)||(g=!0)})),g&&o("update")}Ue.forEach((function(t){J(t)})),u.animateAll()}De=u}(n===r||a&&"clone"!==a.lastPutMode)&&Ge.forEach((function(t){t.parentNode&&t.parentNode.removeChild(t)}))}},nullingGlobal:function(){this.isMultiDrag=He=!1,Ge.length=0},destroyGlobal:function(){this._deselectMultiDrag(),A(document,"pointerup",this._deselectMultiDrag),A(document,"mouseup",this._deselectMultiDrag),A(document,"touchend",this._deselectMultiDrag),A(document,"keydown",this._checkKeyDown),A(document,"keyup",this._checkKeyUp)},_deselectMultiDrag:function(t){if(("undefined"===typeof He||!He)&&De===this.sortable&&(!t||!w(t.target,this.options.draggable,this.sortable.el,!1))&&(!t||0===t.button))while(Ue.length){var e=Ue[0];N(e,this.options.selectedClass,!1),Ue.shift(),st({sortable:this.sortable,rootEl:this.sortable.el,name:"deselect",targetEl:e,originalEvt:t})}},_checkKeyDown:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!0)},_checkKeyUp:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!1)}},a(t,{pluginName:"multiDrag",utils:{select:function(t){var e=t.parentNode[Q];e&&e.options.multiDrag&&!~Ue.indexOf(t)&&(De&&De!==e&&(De.multiDrag._deselectMultiDrag(),De=e),N(t,e.options.selectedClass,!0),Ue.push(t))},deselect:function(t){var e=t.parentNode[Q],n=Ue.indexOf(t);e&&e.options.multiDrag&&~n&&(N(t,e.options.selectedClass,!1),Ue.splice(n,1))}},eventProperties:function(){var t=this,e=[],n=[];return Ue.forEach((function(r){var i;e.push({multiDragElement:r,index:r.sortableIndex}),i=Xe&&r!==Le?-1:Xe?X(r,":not(."+t.options.selectedClass+")"):X(r),n.push({multiDragElement:r,index:i})})),{items:c(Ue),clones:[].concat(Ge),oldIndicies:e,newIndicies:n}},optionListeners:{multiDragKey:function(t){return t=t.toLowerCase(),"ctrl"===t?t="Control":t.length>1&&(t=t.charAt(0).toUpperCase()+t.substr(1)),t}}})}function Ve(t,e){Ue.forEach((function(n,r){var i=e.children[n.sortableIndex+(t?Number(r):0)];i?e.insertBefore(n,i):e.appendChild(n)}))}function Ye(t,e){Ge.forEach((function(n,r){var i=e.children[n.sortableIndex+(t?Number(r):0)];i?e.insertBefore(n,i):e.appendChild(n)}))}function We(){Ue.forEach((function(t){t!==Le&&t.parentNode&&t.parentNode.removeChild(t)}))}ne.mount(new xe),ne.mount(Ce,we),e["default"]=ne},2511:function(t,e,n){var r;/*! https://mths.be/punycode v1.3.2 by @mathias */t=n.nmd(t),function(i){e&&e.nodeType,t&&t.nodeType;var o="object"==typeof n.g&&n.g;o.global!==o&&o.window!==o&&o.self;var s,a=2147483647,u=36,l=1,c=26,h=38,f=700,d=72,p=128,m="-",v=/^xn--/,g=/[^\x20-\x7E]/,_=/[\x2E\u3002\uFF0E\uFF61]/g,y={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},b=u-l,E=Math.floor,T=String.fromCharCode;function x(t){throw RangeError(y[t])}function S(t,e){var n=t.length,r=[];while(n--)r[n]=e(t[n]);return r}function R(t,e){var n=t.split("@"),r="";n.length>1&&(r=n[0]+"@",t=n[1]),t=t.replace(_,".");var i=t.split("."),o=S(i,e).join(".");return r+o}function A(t){var e,n,r=[],i=0,o=t.length;while(i<o)e=t.charCodeAt(i++),e>=55296&&e<=56319&&i<o?(n=t.charCodeAt(i++),56320==(64512&n)?r.push(((1023&e)<<10)+(1023&n)+65536):(r.push(e),i--)):r.push(e);return r}function O(t){return S(t,(function(t){var e="";return t>65535&&(t-=65536,e+=T(t>>>10&1023|55296),t=56320|1023&t),e+=T(t),e})).join("")}function I(t){return t-48<10?t-22:t-65<26?t-65:t-97<26?t-97:u}function w(t,e){return t+22+75*(t<26)-((0!=e)<<5)}function C(t,e,n){var r=0;for(t=n?E(t/f):t>>1,t+=E(t/e);t>b*c>>1;r+=u)t=E(t/b);return E(r+(b+1)*t/(t+h))}function P(t){var e,n,r,i,o,s,h,f,v,g,_=[],y=t.length,b=0,T=p,S=d;for(n=t.lastIndexOf(m),n<0&&(n=0),r=0;r<n;++r)t.charCodeAt(r)>=128&&x("not-basic"),_.push(t.charCodeAt(r));for(i=n>0?n+1:0;i<y;){for(o=b,s=1,h=u;;h+=u){if(i>=y&&x("invalid-input"),f=I(t.charCodeAt(i++)),(f>=u||f>E((a-b)/s))&&x("overflow"),b+=f*s,v=h<=S?l:h>=S+c?c:h-S,f<v)break;g=u-v,s>E(a/g)&&x("overflow"),s*=g}e=_.length+1,S=C(b-o,e,0==o),E(b/e)>a-T&&x("overflow"),T+=E(b/e),b%=e,_.splice(b++,0,T)}return O(_)}function N(t){var e,n,r,i,o,s,h,f,v,g,_,y,b,S,R,O=[];for(t=A(t),y=t.length,e=p,n=0,o=d,s=0;s<y;++s)_=t[s],_<128&&O.push(T(_));r=i=O.length,i&&O.push(m);while(r<y){for(h=a,s=0;s<y;++s)_=t[s],_>=e&&_<h&&(h=_);for(b=r+1,h-e>E((a-n)/b)&&x("overflow"),n+=(h-e)*b,e=h,s=0;s<y;++s)if(_=t[s],_<e&&++n>a&&x("overflow"),_==e){for(f=n,v=u;;v+=u){if(g=v<=o?l:v>=o+c?c:v-o,f<g)break;R=f-g,S=u-g,O.push(T(w(g+R%S,0))),f=E(R/S)}O.push(T(w(f,0))),o=C(n,b,r==i),n=0,++r}++n,++e}return O.join("")}function M(t){return R(t,(function(t){return v.test(t)?P(t.slice(4).toLowerCase()):t}))}function D(t){return R(t,(function(t){return g.test(t)?"xn--"+N(t):t}))}s={version:"1.3.2",ucs2:{decode:A,encode:O},decode:P,encode:N,toASCII:D,toUnicode:M},r=function(){return s}.call(e,n,e,t),void 0===r||(t.exports=r)}()},8575:function(t,e,n){"use strict";var r=n(2511),i=n(2502);function o(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}e.Qc=E,e.DB=x,e.WU=T;var s=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,u=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,l=["<",">",'"',"`"," ","\r","\n","\t"],c=["{","}","|","\\","^","`"].concat(l),h=["'"].concat(c),f=["%","/","?",";","#"].concat(h),d=["/","?","#"],p=255,m=/^[+a-z0-9A-Z_-]{0,63}$/,v=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,g={javascript:!0,"javascript:":!0},_={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},b=n(7673);function E(t,e,n){if(t&&i.isObject(t)&&t instanceof o)return t;var r=new o;return r.parse(t,e,n),r}function T(t){return i.isString(t)&&(t=E(t)),t instanceof o?t.format():o.prototype.format.call(t)}function x(t,e){return E(t,!1,!0).resolve(e)}function S(t,e){return t?E(t,!1,!0).resolveObject(e):e}o.prototype.parse=function(t,e,n){if(!i.isString(t))throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var o=t.indexOf("?"),a=-1!==o&&o<t.indexOf("#")?"?":"#",l=t.split(a),c=/\\/g;l[0]=l[0].replace(c,"/"),t=l.join(a);var E=t;if(E=E.trim(),!n&&1===t.split("#").length){var T=u.exec(E);if(T)return this.path=E,this.href=E,this.pathname=T[1],T[2]?(this.search=T[2],this.query=e?b.parse(this.search.substr(1)):this.search.substr(1)):e&&(this.search="",this.query={}),this}var x=s.exec(E);if(x){x=x[0];var S=x.toLowerCase();this.protocol=S,E=E.substr(x.length)}if(n||x||E.match(/^\/\/[^@\/]+@[^@\/]+/)){var R="//"===E.substr(0,2);!R||x&&_[x]||(E=E.substr(2),this.slashes=!0)}if(!_[x]&&(R||x&&!y[x])){for(var A,O,I=-1,w=0;w<d.length;w++){var C=E.indexOf(d[w]);-1!==C&&(-1===I||C<I)&&(I=C)}O=-1===I?E.lastIndexOf("@"):E.lastIndexOf("@",I),-1!==O&&(A=E.slice(0,O),E=E.slice(O+1),this.auth=decodeURIComponent(A)),I=-1;for(w=0;w<f.length;w++){C=E.indexOf(f[w]);-1!==C&&(-1===I||C<I)&&(I=C)}-1===I&&(I=E.length),this.host=E.slice(0,I),E=E.slice(I),this.parseHost(),this.hostname=this.hostname||"";var P="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!P)for(var N=this.hostname.split(/\./),M=(w=0,N.length);w<M;w++){var D=N[w];if(D&&!D.match(m)){for(var L="",B=0,F=D.length;B<F;B++)D.charCodeAt(B)>127?L+="x":L+=D[B];if(!L.match(m)){var U=N.slice(0,w),G=N.slice(w+1),k=D.match(v);k&&(U.push(k[1]),G.unshift(k[2])),G.length&&(E="/"+G.join(".")+E),this.hostname=U.join(".");break}}}this.hostname.length>p?this.hostname="":this.hostname=this.hostname.toLowerCase(),P||(this.hostname=r.toASCII(this.hostname));var X=this.port?":"+this.port:"",H=this.hostname||"";this.host=H+X,this.href+=this.host,P&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==E[0]&&(E="/"+E))}if(!g[S])for(w=0,M=h.length;w<M;w++){var j=h[w];if(-1!==E.indexOf(j)){var V=encodeURIComponent(j);V===j&&(V=escape(j)),E=E.split(j).join(V)}}var Y=E.indexOf("#");-1!==Y&&(this.hash=E.substr(Y),E=E.slice(0,Y));var W=E.indexOf("?");if(-1!==W?(this.search=E.substr(W),this.query=E.substr(W+1),e&&(this.query=b.parse(this.query)),E=E.slice(0,W)):e&&(this.search="",this.query={}),E&&(this.pathname=E),y[S]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){X=this.pathname||"";var z=this.search||"";this.path=X+z}return this.href=this.format(),this},o.prototype.format=function(){var t=this.auth||"";t&&(t=encodeURIComponent(t),t=t.replace(/%3A/i,":"),t+="@");var e=this.protocol||"",n=this.pathname||"",r=this.hash||"",o=!1,s="";this.host?o=t+this.host:this.hostname&&(o=t+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(o+=":"+this.port)),this.query&&i.isObject(this.query)&&Object.keys(this.query).length&&(s=b.stringify(this.query));var a=this.search||s&&"?"+s||"";return e&&":"!==e.substr(-1)&&(e+=":"),this.slashes||(!e||y[e])&&!1!==o?(o="//"+(o||""),n&&"/"!==n.charAt(0)&&(n="/"+n)):o||(o=""),r&&"#"!==r.charAt(0)&&(r="#"+r),a&&"?"!==a.charAt(0)&&(a="?"+a),n=n.replace(/[?#]/g,(function(t){return encodeURIComponent(t)})),a=a.replace("#","%23"),e+o+n+a+r},o.prototype.resolve=function(t){return this.resolveObject(E(t,!1,!0)).format()},o.prototype.resolveObject=function(t){if(i.isString(t)){var e=new o;e.parse(t,!1,!0),t=e}for(var n=new o,r=Object.keys(this),s=0;s<r.length;s++){var a=r[s];n[a]=this[a]}if(n.hash=t.hash,""===t.href)return n.href=n.format(),n;if(t.slashes&&!t.protocol){for(var u=Object.keys(t),l=0;l<u.length;l++){var c=u[l];"protocol"!==c&&(n[c]=t[c])}return y[n.protocol]&&n.hostname&&!n.pathname&&(n.path=n.pathname="/"),n.href=n.format(),n}if(t.protocol&&t.protocol!==n.protocol){if(!y[t.protocol]){for(var h=Object.keys(t),f=0;f<h.length;f++){var d=h[f];n[d]=t[d]}return n.href=n.format(),n}if(n.protocol=t.protocol,t.host||_[t.protocol])n.pathname=t.pathname;else{var p=(t.pathname||"").split("/");while(p.length&&!(t.host=p.shift()));t.host||(t.host=""),t.hostname||(t.hostname=""),""!==p[0]&&p.unshift(""),p.length<2&&p.unshift(""),n.pathname=p.join("/")}if(n.search=t.search,n.query=t.query,n.host=t.host||"",n.auth=t.auth,n.hostname=t.hostname||t.host,n.port=t.port,n.pathname||n.search){var m=n.pathname||"",v=n.search||"";n.path=m+v}return n.slashes=n.slashes||t.slashes,n.href=n.format(),n}var g=n.pathname&&"/"===n.pathname.charAt(0),b=t.host||t.pathname&&"/"===t.pathname.charAt(0),E=b||g||n.host&&t.pathname,T=E,x=n.pathname&&n.pathname.split("/")||[],S=(p=t.pathname&&t.pathname.split("/")||[],n.protocol&&!y[n.protocol]);if(S&&(n.hostname="",n.port=null,n.host&&(""===x[0]?x[0]=n.host:x.unshift(n.host)),n.host="",t.protocol&&(t.hostname=null,t.port=null,t.host&&(""===p[0]?p[0]=t.host:p.unshift(t.host)),t.host=null),E=E&&(""===p[0]||""===x[0])),b)n.host=t.host||""===t.host?t.host:n.host,n.hostname=t.hostname||""===t.hostname?t.hostname:n.hostname,n.search=t.search,n.query=t.query,x=p;else if(p.length)x||(x=[]),x.pop(),x=x.concat(p),n.search=t.search,n.query=t.query;else if(!i.isNullOrUndefined(t.search)){if(S){n.hostname=n.host=x.shift();var R=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");R&&(n.auth=R.shift(),n.host=n.hostname=R.shift())}return n.search=t.search,n.query=t.query,i.isNull(n.pathname)&&i.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!x.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var A=x.slice(-1)[0],O=(n.host||t.host||x.length>1)&&("."===A||".."===A)||""===A,I=0,w=x.length;w>=0;w--)A=x[w],"."===A?x.splice(w,1):".."===A?(x.splice(w,1),I++):I&&(x.splice(w,1),I--);if(!E&&!T)for(;I--;I)x.unshift("..");!E||""===x[0]||x[0]&&"/"===x[0].charAt(0)||x.unshift(""),O&&"/"!==x.join("/").substr(-1)&&x.push("");var C=""===x[0]||x[0]&&"/"===x[0].charAt(0);if(S){n.hostname=n.host=C?"":x.length?x.shift():"";R=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");R&&(n.auth=R.shift(),n.host=n.hostname=R.shift())}return E=E||n.host&&x.length,E&&!C&&x.unshift(""),x.length?n.pathname=x.join("/"):(n.pathname=null,n.path=null),i.isNull(n.pathname)&&i.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=t.auth||n.auth,n.slashes=n.slashes||t.slashes,n.href=n.format(),n},o.prototype.parseHost=function(){var t=this.host,e=a.exec(t);e&&(e=e[0],":"!==e&&(this.port=e.substr(1)),t=t.substr(0,t.length-e.length)),t&&(this.hostname=t)}},2502:function(t){"use strict";t.exports={isString:function(t){return"string"===typeof t},isObject:function(t){return"object"===typeof t&&null!==t},isNull:function(t){return null===t},isNullOrUndefined:function(t){return null==t}}},3744:function(t,e){"use strict";e.Z=(t,e)=>{const n=t.__vccOpts||t;for(const[r,i]of e)n[r]=i;return n}},9179:function(t,e,n){"use strict";n.d(e,{Z:function(){return x}});var r=n(4865);function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t){return function(t){if(Array.isArray(t))return a(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||s(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(t,e){if(t){if("string"==typeof t)return a(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(t,e):void 0}}function a(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function u(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=s(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){u=!0,o=t},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw o}}}}var l={inheritAttrs:!1,name:"vue-input",props:{autocomplete:{required:!1,type:String},modelValue:{required:!0,type:String},placeholder:{required:!0,type:String},disabled:{required:!0,type:Boolean},tabindex:{required:!0,type:Number},autofocus:{required:!0,type:Boolean},comboboxUid:{required:!0,type:Number}},emits:["update:modelValue","input","change","focus","blur","escape"],setup:function(t,e){var n=(0,r.ref)(null);return(0,r.onMounted)((function(){t.autofocus&&n.value.focus()})),(0,r.onUpdated)((function(){t.autofocus&&n.value.focus()})),{handleInput:function(t){e.emit("input",t),e.emit("update:modelValue",t.target.value)},handleChange:function(t){e.emit("change",t),e.emit("update:modelValue",t.target.value)},handleFocus:function(t){e.emit("focus",t)},handleBlur:function(t){e.emit("blur",t)},input:n,handleEscape:function(t){n.value.blur(),e.emit("escape",t)}}}},c={class:"vue-input"},h=["autocomplete","modelValue","placeholder","disabled","tabindex","autofocus","aria-controls","aria-labelledby"];l.render=function(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createElementBlock)("div",c,[(0,r.renderSlot)(t.$slots,"prepend"),(0,r.createElementVNode)("input",{ref:"input",autocomplete:n.autocomplete,modelValue:n.modelValue,placeholder:n.placeholder,disabled:n.disabled,onInput:e[0]||(e[0]=function(){return i.handleInput&&i.handleInput.apply(i,arguments)}),onChange:e[1]||(e[1]=function(){return i.handleChange&&i.handleChange.apply(i,arguments)}),onFocus:e[2]||(e[2]=function(){return i.handleFocus&&i.handleFocus.apply(i,arguments)}),onBlur:e[3]||(e[3]=function(){return i.handleBlur&&i.handleBlur.apply(i,arguments)}),onKeyup:e[4]||(e[4]=(0,r.withKeys)((0,r.withModifiers)((function(){return i.handleEscape&&i.handleEscape.apply(i,arguments)}),["exact"]),["esc"])),tabindex:n.tabindex,autofocus:n.autofocus,"aria-autocomplete":"list","aria-controls":"vs".concat(n.comboboxUid,"-listbox"),"aria-labelledby":"vs".concat(n.comboboxUid,"-combobox")},null,40,h),(0,r.renderSlot)(t.$slots,"append")])},l.__file="src/components/input.vue";var f={inheritAttrs:!1,name:"vue-tags",props:{modelValue:{required:!0,type:Array,validator:function(t){return t.every((function(t){return void 0!==i(t.key)&&void 0!==t.label&&"boolean"==typeof t.selected}))}},collapseTags:{type:Boolean}},emits:["click"],setup:function(t,e){return{dataAttrs:(0,r.inject)("dataAttrs"),handleClick:function(t){e.emit("click",t)}}},render:function(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createElementBlock)("ul",(0,r.mergeProps)({class:["vue-tags",{collapsed:n.collapseTags}],onMousedown:e[0]||(e[0]=(0,r.withModifiers)((function(){}),["prevent"])),tabindex:"-1",onClick:e[1]||(e[1]=function(){return i.handleClick&&i.handleClick.apply(i,arguments)})},i.dataAttrs),[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.modelValue,(function(e){return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:e.key},[e.group?(0,r.createCommentVNode)("v-if",!0):((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:0,class:(0,r.normalizeClass)(["vue-tag",{selected:e.selected}])},[(0,r.renderSlot)(t.$slots,"default",{option:e},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.label),1)]}))],2))],64)})),128))],16)},__file:"src/components/tags.vue"},d={inheritAttrs:!1,name:"vue-dropdown",props:{modelValue:{required:!0,type:Array,validator:function(t){return t.every((function(t){return void 0!==i(t.key)&&void 0!==t.label&&"boolean"==typeof t.selected}))}},comboboxUid:{required:!0,type:Number},maxHeight:{required:!0},highlightedOriginalIndex:{required:!0}},emits:["click-item","mouseenter"],setup:function(t,e){return{dataAttrs:(0,r.inject)("dataAttrs"),handleClickItem:function(t,n){n.disabled||e.emit("click-item",t,n)},handleMouseenter:function(t,n){e.emit("mouseenter",t,n)}}}},p=["id","aria-multiselectable","aria-busy","aria-disabled"],m=["onClick","onMouseenter","id","aria-selected","aria-disabled"];d.render=function(t,e,n,i,o,s){return(0,r.openBlock)(),(0,r.createElementBlock)("ul",(0,r.mergeProps)({class:"vue-dropdown",style:{maxHeight:n.maxHeight+"px"},onMousedown:e[0]||(e[0]=(0,r.withModifiers)((function(){}),["prevent"]))},i.dataAttrs,{role:"listbox",id:"vs".concat(n.comboboxUid,"-listbox"),"aria-multiselectable":i.dataAttrs["data-multiple"],"aria-busy":i.dataAttrs["data-loading"],"aria-disabled":i.dataAttrs["data-disabled"]}),[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.modelValue,(function(e,o){return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:e.key},[e.visible&&!1===e.hidden?((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:0,onClick:function(t){return i.handleClickItem(t,e)},class:(0,r.normalizeClass)(["vue-dropdown-item",{selected:e.selected,disabled:e.disabled,highlighted:e.originalIndex===n.highlightedOriginalIndex,group:e.group}]),onMouseenter:function(t){return i.handleMouseenter(t,e)},role:"option",id:"vs".concat(n.comboboxUid,"-option-").concat(o),"aria-selected":!!e.selected||!!e.disabled&&void 0,"aria-disabled":e.disabled},[(0,r.renderSlot)(t.$slots,"default",{option:e},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.label),1)]}))],42,m)):(0,r.createCommentVNode)("v-if",!0)],64)})),128))],16,p)},d.__file="src/components/dropdown.vue";var v=function(t,e,n){var r=n.valueBy;return r(t)===r(e)},g=function(t,e,n){var r=n.valueBy;return t.some((function(t){return v(t,e,{valueBy:r})}))},_=function(t,e,n){var r=n.valueBy;return t.find((function(t){return r(t)===e}))},y=function(t,e,n){var r=n.max,i=n.valueBy;return g(t,e,{valueBy:i})||t.length>=r?t:t.concat(e)},b=function(t,e,n){var r=n.min,i=n.valueBy;return!1===g(t,e,{valueBy:i})||t.length<=r?t:t.filter((function(t){return!1===v(t,e,{valueBy:i})}))},E=function(t){return(0,r.computed)((function(){return"function"==typeof t.value?t.value:"string"==typeof t.value?function(e){return t.value.split(".").reduce((function(t,e){return t[e]}),e)}:function(t){return t}}))},T=function(t,e){var n=(0,r.computed)((function(){return t.value.reduce((function(t,e){return Object.assign(t,(n={},r=e.originalIndex,i=e,r in n?Object.defineProperty(n,r,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[r]=i,n));var n,r,i}),{})})),i=function(t){var r=n.value[t];return void 0!==r&&!1!==o(r)&&(e.value=t,!0)},o=function(t){return!t.disabled&&!t.hidden&&t.visible},s=(0,r.computed)((function(){return t.value.some((function(t){return o(t)}))}));return(0,r.watchEffect)((function(){if(!1===s.value&&(e.value=null),null!==e.value&&t.value.length<=e.value){var n,r=u(t.value.reverse());try{for(r.s();!(n=r.n()).done;){var a=n.value;if(i(a.originalIndex))break}}catch(t){r.e(t)}finally{r.f()}}if(null===e.value||!1===o(t.value[e.value])){var l,c=u(t.value);try{for(c.s();!(l=c.n()).done;){var h=l.value;if(i(h.originalIndex))break}}catch(t){c.e(t)}finally{c.f()}}})),{pointerForward:function(){if(!1!==s.value&&null!==e.value)for(var n=e.value+1,r=0;n!==e.value&&r++<t.value.length&&(t.value.length<=n&&(n=0),!i(n));)++n},pointerBackward:function(){if(!1!==s.value&&null!==e.value)for(var n=e.value-1,r=0;n!==e.value&&r++<t.value.length&&(n<0&&(n=t.value.length-1),!i(n));)--n},pointerSet:i}},x=(0,r.defineComponent)({name:"vue-select",inheritAttrs:!1,props:{modelValue:{required:!0},emptyModelValue:{},options:{required:!0,type:Array},labelBy:{type:[String,Function]},valueBy:{type:[String,Function]},disabledBy:{default:"disabled",type:[String,Function]},groupBy:{default:"group",type:[String,Function]},visibleOptions:{type:Array,default:null},multiple:{default:!1,type:Boolean},min:{default:0,type:Number},max:{default:1/0,type:Number},searchable:{default:!1,type:Boolean},searchPlaceholder:{default:"Type to search",type:String},clearOnSelect:{default:!1,type:Boolean},clearOnClose:{default:!1,type:Boolean},taggable:{default:!1,type:Boolean},collapseTags:{default:!1,type:Boolean},autocomplete:{default:"off",type:String},disabled:{default:!1,type:Boolean},loading:{default:!1,type:Boolean},closeOnSelect:{default:!1,type:Boolean},hideSelected:{default:!1,type:Boolean},placeholder:{default:"Select option",type:String},tabindex:{default:0,type:Number},autofocus:{default:!1,type:Boolean},maxHeight:{default:300,type:Number},openDirection:{type:String,validator:function(t){return["top","bottom"].includes(t)}}},emits:["selected","removed","update:modelValue","focus","blur","toggle","opened","closed","search:input","search:change","search:focus","search:blur"],setup:function(t,e){var n=function(t){var e=(0,r.reactive)({}),n=E((0,r.toRef)(t,"labelBy"));(0,r.watchEffect)((function(){return e.labelBy=n.value}));var i=E((0,r.toRef)(t,"valueBy"));(0,r.watchEffect)((function(){return e.valueBy=i.value}));var o=E((0,r.toRef)(t,"disabledBy"));(0,r.watchEffect)((function(){return e.disabledBy=o.value}));var s=E((0,r.toRef)(t,"groupBy"));(0,r.watchEffect)((function(){return e.groupBy=s.value}));var a=(0,r.computed)((function(){return t.multiple?t.min:Math.min(1,t.min)}));(0,r.watchEffect)((function(){return e.min=a.value}));var u=(0,r.computed)((function(){return t.multiple?t.max:1}));return(0,r.watchEffect)((function(){return e.max=u.value})),(0,r.watchEffect)((function(){return e.options=t.options})),e}(t),i=(0,r.computed)((function(){var e;return null!==(e=t.emptyModelValue)&&void 0!==e?e:null})),s=(0,r.getCurrentInstance)(),a=(0,r.ref)(),l=(0,r.ref)(),c=(0,r.ref)(),h=(0,r.computed)((function(){var t;return null===(t=c.value)||void 0===t?void 0:t._.refs.input})),f=(0,r.ref)(!1);(0,r.watch)((function(){return f.value}),(function(){f.value?(e.emit("opened"),e.emit("focus"),t.searchable?(h.value!==document.activeElement&&h.value.focus(),e.emit("search:focus")):a.value.focus()):(t.searchable?(h.value===document.activeElement&&h.value.blur(),t.clearOnClose&&N(),e.emit("search:blur")):a.value.blur(),e.emit("closed"),e.emit("blur")),e.emit("toggle")}));var d=function(){t.disabled||(f.value=!0)},p=function(t){a.value.contains(null==t?void 0:t.relatedTarget)?setTimeout((function(){a.value.focus()})):f.value=!1};(0,r.watch)((function(){return t.disabled}),(function(){return p()}));var m=(0,r.ref)(""),v=(0,r.computed)((function(){return new RegExp(m.value.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"i")})),x=(0,r.computed)((function(){return m.value?n.options.filter((function(t){return v.value.test(n.labelBy(t))})):void 0})),S=(0,r.ref)([]),R=(0,r.computed)((function(){return new Set(S.value.map((function(t){return n.valueBy(t)})))})),A=function(){if(t.multiple){if(!1===Array.isArray(t.modelValue))return!1;if(S.value.length!==t.modelValue.length)return!1;if(Object.keys(S.value).some((function(e){return S.value[e]!==_(n.options,t.modelValue[e],{valueBy:n.valueBy})})))return!1}else{if(0===S.value.length&&t.modelValue!==i.value)return!1;if(1===S.value.length&&t.modelValue===i.value)return!1;if(S.value[0]!==_(n.options,t.modelValue,{valueBy:n.valueBy}))return!1}return!0},O=function(){if(!A()){S.value=[];var e,r=u(t.multiple?t.modelValue:t.modelValue===i.value?[]:[t.modelValue]);try{for(r.s();!(e=r.n()).done;){var o=e.value,s=_(n.options,o,{valueBy:n.valueBy});!1!==g(n.options,s,{valueBy:n.valueBy})&&(S.value=y(S.value,s,{max:1/0,valueBy:n.valueBy}))}}catch(e){r.e(e)}finally{r.f()}}};O(),(0,r.watch)((function(){return t.modelValue}),(function(){return O()}),{deep:!0}),(0,r.watch)((function(){return n.options}),(function(){S.value=n.options.filter((function(t){return R.value.has(n.valueBy(t))}))}),{deep:!0});var I,w=function(t,r){(r=r.originalOption).value.every((function(t){var e=_(n.options,t,{valueBy:n.valueBy});return g(S.value,e,{valueBy:n.valueBy})}))?r.value.forEach((function(t){var r=_(n.options,t,{valueBy:n.valueBy});S.value=b(S.value,r,{min:n.min,valueBy:n.valueBy}),e.emit("removed",r)})):r.value.forEach((function(t){var r=_(n.options,t,{valueBy:n.valueBy});g(S.value,r,{valueBy:n.valueBy})||(S.value=y(S.value,r,{max:n.max,valueBy:n.valueBy}),e.emit("selected",r))}))},C=function(r,i){if(i=i.originalOption,g(S.value,i,{valueBy:n.valueBy}))S.value=b(S.value,i,{min:n.min,valueBy:n.valueBy}),e.emit("removed",i);else{if(!t.multiple&&1===S.value.length){var o=S.value[0];S.value=b(S.value,S.value[0],{min:0,valueBy:n.valueBy}),e.emit("removed",o)}S.value=y(S.value,i,{max:n.max,valueBy:n.valueBy}),e.emit("selected",i)}},P=function(){if(!A()){var r=S.value.map((function(t){return n.valueBy(t)}));t.multiple?e.emit("update:modelValue",r):r.length?e.emit("update:modelValue",r[0]):e.emit("update:modelValue",i.value)}},N=function(){h.value.value="",h.value.dispatchEvent(new Event("input")),h.value.dispatchEvent(new Event("change"))},M=(0,r.computed)((function(){var e,r;return null!==(r=null!==(e=t.visibleOptions)&&void 0!==e?e:x.value)&&void 0!==r?r:n.options})),D=(0,r.ref)(0),L=(0,r.computed)((function(){var e,r=new Set(M.value.map((function(t){return n.valueBy(t)}))),i=n.options.map((function(e,i){var o,s={key:n.valueBy(e),label:n.labelBy(e),group:null!==(o=n.groupBy(e))&&void 0!==o&&o,originalIndex:i,originalOption:e};return s.selected=s.group?e.value.every((function(t){return R.value.has(t)})):R.value.has(n.valueBy(e)),s.disabled=s.group?n.disabledBy(e)||e.value.every((function(t){var e=_(n.options,t,{valueBy:n.valueBy});return n.disabledBy(e)})):n.disabledBy(e),s.visible=s.group?e.value.some((function(t){return r.has(t)})):r.has(n.valueBy(e)),s.hidden=!!t.hideSelected&&(s.group?e.value.every((function(t){return R.value.has(t)})):R.value.has(n.valueBy(e))),s})),o=u(i);try{for(o.s();!(e=o.n()).done;){var s=e.value;!1!==s.group&&s.disabled&&function(){var t=new Set(s.originalOption.value);i.filter((function(e){return t.has(n.valueBy(e.originalOption))})).forEach((function(t){return t.disabled=!0}))}()}}catch(e){o.e(e)}finally{o.f()}return i})),B=T(L,D),F=B.pointerForward,U=B.pointerBackward,G=B.pointerSet,k="",X=/^[\w]$/,H=(0,r.computed)((function(){var t=o(n.options.keys());return t.slice(D.value).concat(t.slice(0,D.value))})),j=function(){var t,e=null===(t=a.value)||void 0===t?void 0:t.querySelector(".highlighted");if(e&&l.value){var n,r=getComputedStyle(e);for(n=0;e.offsetTop+parseFloat(r.height)+parseFloat(r.paddingTop)+parseFloat(r.paddingBottom)>l.value.$el.clientHeight+l.value.$el.scrollTop&&n++<L.value.length;)l.value.$el.scrollTop=l.value.$el.scrollTop+parseFloat(r.height)+parseFloat(r.paddingTop)+parseFloat(r.paddingBottom);for(n=0;e.offsetTop<l.value.$el.scrollTop&&n++<L.value.length;)l.value.$el.scrollTop=l.value.$el.scrollTop-parseFloat(r.height)-parseFloat(r.paddingTop)-parseFloat(r.paddingBottom)}};(0,r.watch)((function(){return[f.value,n.options,R.value]}),(function(t,e){!0!==(null==e?void 0:e[0])&&!1!==f.value&&0!==S.value.length&&(G(n.options.findIndex((function(t){return R.value.has(n.valueBy(t))}))),(0,r.nextTick)(j))}),{deep:!0,immediate:!0});var V=(0,r.computed)((function(){return{"data-is-focusing":f.value,"data-visible-length":L.value.filter((function(t){return t.visible&&!1===t.hidden})).length,"data-not-selected-length":n.options.length-L.value.filter((function(t){return t.selected})).length,"data-selected-length":L.value.filter((function(t){return t.selected})).length,"data-addable":L.value.filter((function(t){return t.selected})).length<n.max,"data-removable":L.value.filter((function(t){return t.selected})).length>n.min,"data-total-length":n.options.length,"data-multiple":t.multiple,"data-loading":t.loading,"data-disabled":t.disabled}}));(0,r.provide)("dataAttrs",V);var Y=(0,r.computed)((function(){return L.value.filter((function(t){return t.selected})).filter((function(t){return!t.group}))})),W=(0,r.computed)((function(){return t.multiple?0===Y.value.length?t.placeholder:1===Y.value.length?"1 option selected":Y.value.length+" options selected":0===Y.value.length?t.placeholder:Y.value[0].label+""})),z=(0,r.computed)((function(){var e=Y.value.map((function(t){return t.originalOption}));return t.multiple?e:e[0]||i.value})),$=(0,r.ref)();return(0,r.watch)((function(){return[t.openDirection,f.value]}),(function(){var e,n;$.value=null!==(n=null!==(e=t.openDirection)&&void 0!==e?e:function(){if(void 0!==a.value&&void 0!==window)return window.innerHeight-a.value.getBoundingClientRect().bottom>=t.maxHeight?"bottom":"top"}())&&void 0!==n?n:"bottom"}),{immediate:!0}),{instance:s,isFocusing:f,wrapper:a,dropdown:l,input:c,focus:d,blur:p,toggle:function(){f.value?p():d()},searchingInputValue:m,handleInputForInput:function(t){e.emit("search:input",t)},handleChangeForInput:function(t){e.emit("search:change",t)},handleFocusForInput:function(t){d()},handleBlurForInput:function(t){p()},optionsWithInfo:L,addOrRemoveOption:function(e,n){t.disabled||(n.group&&t.multiple?w(e,n):C(e,n),P(),!0===t.closeOnSelect&&(f.value=!1),!0===t.clearOnSelect&&m.value&&N())},dataAttrs:V,innerPlaceholder:W,selected:z,highlightedOriginalIndex:D,pointerForward:function(){F(),(0,r.nextTick)(j)},pointerBackward:function(){U(),(0,r.nextTick)(j)},pointerFirst:function(){var t,e=u(n.options.keys());try{for(e.s();!(t=e.n()).done;){var i=t.value;if(G(i))break}}catch(t){e.e(t)}finally{e.f()}(0,r.nextTick)(j)},pointerLast:function(){var t,e=u(o(n.options.keys()).reverse());try{for(e.s();!(t=e.n()).done;){var i=t.value;if(G(i))break}}catch(t){e.e(t)}finally{e.f()}(0,r.nextTick)(j)},typeAhead:function(e){var r,i;if(!t.searchable){var o=!1;if(X.test(e.key)?(k+=e.key.toLowerCase(),o=!0):"Space"===e.code&&(k+=" "),o){var s,a=u(H.value);try{for(a.s();!(s=a.n()).done;){var l=s.value;if(!0===(null===(i=null===(r=n.labelBy(n.options[l]))||void 0===r?void 0:r.toLowerCase())||void 0===i?void 0:i.startsWith(k))&&G(l))break}}catch(e){a.e(e)}finally{a.f()}clearTimeout(I),I=setTimeout((function(){k=""}),500)}}},pointerSet:G,direction:$}},components:{VInput:l,VTags:f,VDropdown:d}});x.__VERSION__="2.10.2";var S=["tabindex","id","role","aria-expanded","aria-owns","aria-activedescendant","aria-busy","aria-disabled"],R={ref:"header",class:"vue-select-header"},A={key:0,class:"vue-input"},O=["placeholder","autocomplete"],I=["onClick"],w=(0,r.createElementVNode)("span",{class:"icon loading"},[(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div")],-1),C={key:0,class:"vue-select-input-wrapper"},P=(0,r.createElementVNode)("span",{class:"icon loading"},[(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div"),(0,r.createElementVNode)("div")],-1);x.render=function(t,e,n,i,o,s){var a=(0,r.resolveComponent)("v-tags"),u=(0,r.resolveComponent)("v-input"),l=(0,r.resolveComponent)("v-dropdown");return(0,r.openBlock)(),(0,r.createElementBlock)("div",(0,r.mergeProps)({ref:"wrapper",class:["vue-select",["direction-".concat(t.direction)]],tabindex:t.isFocusing?-1:t.tabindex,onFocus:e[9]||(e[9]=function(){return t.focus&&t.focus.apply(t,arguments)}),onBlur:e[10]||(e[10]=function(e){return!t.searchable&&t.blur(e)})},Object.assign({},t.dataAttrs,t.$attrs),{onKeypress:e[11]||(e[11]=(0,r.withKeys)((0,r.withModifiers)((function(){return null!==t.highlightedOriginalIndex&&t.addOrRemoveOption(t.$event,t.optionsWithInfo[t.highlightedOriginalIndex])}),["prevent","exact"]),["enter"])),onKeydown:[e[12]||(e[12]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerForward&&t.pointerForward.apply(t,arguments)}),["prevent","exact"]),["down"])),e[13]||(e[13]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerBackward&&t.pointerBackward.apply(t,arguments)}),["prevent","exact"]),["up"])),e[14]||(e[14]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerFirst&&t.pointerFirst.apply(t,arguments)}),["prevent","exact"]),["home"])),e[15]||(e[15]=(0,r.withKeys)((0,r.withModifiers)((function(){return t.pointerLast&&t.pointerLast.apply(t,arguments)}),["prevent","exact"]),["end"])),e[16]||(e[16]=function(){return t.typeAhead&&t.typeAhead.apply(t,arguments)})],id:"vs".concat(t.instance.uid,"-combobox"),role:t.searchable?"combobox":null,"aria-expanded":t.isFocusing,"aria-haspopup":"listbox","aria-owns":"vs".concat(t.instance.uid,"-listbox"),"aria-activedescendant":null===t.highlightedOriginalIndex?null:"vs".concat(t.instance.uid,"-option-").concat(t.highlightedOriginalIndex),"aria-busy":t.loading,"aria-disabled":t.disabled}),[(0,r.createElementVNode)("div",R,[t.multiple&&t.taggable&&0===t.modelValue.length||!1===t.searchable&&!1===t.taggable?((0,r.openBlock)(),(0,r.createElementBlock)("div",A,[(0,r.renderSlot)(t.$slots,"label",{selected:t.selected},(function(){return[(0,r.createElementVNode)("input",{placeholder:t.innerPlaceholder,autocomplete:t.autocomplete,readonly:"",onClick:e[0]||(e[0]=function(){return t.focus&&t.focus.apply(t,arguments)})},null,8,O)]}))])):(0,r.createCommentVNode)("v-if",!0),t.multiple&&t.taggable?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createVNode)(a,{modelValue:t.optionsWithInfo,"collapse-tags":t.collapseTags,tabindex:"-1",onClick:t.focus},{default:(0,r.withCtx)((function(e){var n=e.option;return[(0,r.renderSlot)(t.$slots,"tag",{option:n.originalOption,remove:function(){return t.addOrRemoveOption(t.$event,n)}},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(n.label),1),(0,r.createElementVNode)("img",{src:"data:image/svg+xml;base64,PHN2ZyBpZD0iZGVsZXRlIiBkYXRhLW5hbWU9ImRlbGV0ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNTEyIDUxMiI+PHRpdGxlPmRlbGV0ZTwvdGl0bGU+PHBhdGggZD0iTTI1NiwyNEMzODMuOSwyNCw0ODgsMTI4LjEsNDg4LDI1NlMzODMuOSw0ODgsMjU2LDQ4OCwyNC4wNiwzODMuOSwyNC4wNiwyNTYsMTI4LjEsMjQsMjU2LDI0Wk0wLDI1NkMwLDM5Ny4xNiwxMTQuODQsNTEyLDI1Niw1MTJTNTEyLDM5Ny4xNiw1MTIsMjU2LDM5Ny4xNiwwLDI1NiwwLDAsMTE0Ljg0LDAsMjU2WiIgZmlsbD0iIzViNWI1ZiIvPjxwb2x5Z29uIHBvaW50cz0iMzgyIDE3Mi43MiAzMzkuMjkgMTMwLjAxIDI1NiAyMTMuMjkgMTcyLjcyIDEzMC4wMSAxMzAuMDEgMTcyLjcyIDIxMy4yOSAyNTYgMTMwLjAxIDMzOS4yOCAxNzIuNzIgMzgyIDI1NiAyOTguNzEgMzM5LjI5IDM4MS45OSAzODIgMzM5LjI4IDI5OC43MSAyNTYgMzgyIDE3Mi43MiIgZmlsbD0iIzViNWI1ZiIvPjwvc3ZnPg==",alt:"delete tag",class:"icon delete",onClick:(0,r.withModifiers)((function(){return t.addOrRemoveOption(t.$event,n)}),["prevent","stop"])},null,8,I)]}))]})),_:3},8,["modelValue","collapse-tags","onClick"]),(0,r.renderSlot)(t.$slots,"toggle",{isFocusing:t.isFocusing,toggle:t.toggle},(function(){return[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["icon arrow-downward",{active:t.isFocusing}]),onClick:e[1]||(e[1]=function(){return t.toggle&&t.toggle.apply(t,arguments)}),onMousedown:e[2]||(e[2]=(0,r.withModifiers)((function(){}),["prevent","stop"]))},null,34)]}))],64)):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:2},[t.searchable?((0,r.openBlock)(),(0,r.createBlock)(u,{key:0,ref:"input",modelValue:t.searchingInputValue,"onUpdate:modelValue":e[3]||(e[3]=function(e){return t.searchingInputValue=e}),disabled:t.disabled,autocomplete:t.autocomplete,placeholder:t.isFocusing?t.searchPlaceholder:t.innerPlaceholder,onInput:t.handleInputForInput,onChange:t.handleChangeForInput,onFocus:t.handleFocusForInput,onBlur:t.handleBlurForInput,onEscape:t.blur,autofocus:t.autofocus||t.taggable&&t.searchable,tabindex:t.tabindex,comboboxUid:t.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"])):(0,r.createCommentVNode)("v-if",!0),t.loading?(0,r.renderSlot)(t.$slots,"loading",{key:1},(function(){return[w]})):(0,r.renderSlot)(t.$slots,"toggle",{key:2,isFocusing:t.isFocusing,toggle:t.toggle},(function(){return[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["icon arrow-downward",{active:t.isFocusing}]),onClick:e[4]||(e[4]=function(){return t.toggle&&t.toggle.apply(t,arguments)}),onMousedown:e[5]||(e[5]=(0,r.withModifiers)((function(){}),["prevent","stop"]))},null,34)]}))],64))],512),t.multiple&&t.taggable&&t.searchable?((0,r.openBlock)(),(0,r.createElementBlock)("div",C,[(0,r.withDirectives)((0,r.createVNode)(u,{ref:"input",modelValue:t.searchingInputValue,"onUpdate:modelValue":e[6]||(e[6]=function(e){return t.searchingInputValue=e}),disabled:t.disabled,autocomplete:t.autocomplete,placeholder:t.isFocusing?t.searchPlaceholder:t.innerPlaceholder,onInput:t.handleInputForInput,onChange:t.handleChangeForInput,onFocus:t.handleFocusForInput,onBlur:t.handleBlurForInput,onEscape:t.blur,autofocus:t.autofocus||t.taggable&&t.searchable,tabindex:t.tabindex,comboboxUid:t.instance.uid},null,8,["modelValue","disabled","autocomplete","placeholder","onInput","onChange","onFocus","onBlur","onEscape","autofocus","tabindex","comboboxUid"]),[[r.vShow,t.isFocusing]]),t.loading?(0,r.renderSlot)(t.$slots,"loading",{key:0},(function(){return[P]})):(0,r.createCommentVNode)("v-if",!0)])):(0,r.createCommentVNode)("v-if",!0),(0,r.createVNode)(l,{ref:"dropdown",modelValue:t.optionsWithInfo,"onUpdate:modelValue":e[7]||(e[7]=function(e){return t.optionsWithInfo=e}),onClickItem:t.addOrRemoveOption,onMouseenter:e[8]||(e[8]=function(e,n){return t.pointerSet(n.originalIndex)}),comboboxUid:t.instance.uid,maxHeight:t.maxHeight,highlightedOriginalIndex:t.highlightedOriginalIndex},{default:(0,r.withCtx)((function(e){var n=e.option;return[(0,r.renderSlot)(t.$slots,"dropdown-item",{option:n.originalOption},(function(){return[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(n.label),1)]}))]})),_:3},8,["modelValue","onClickItem","comboboxUid","maxHeight","highlightedOriginalIndex"])],16,S)},x.__file="src/index.vue"},7197:function(t,e){"use strict"; -/*! - * vue-textarea-autosize v1.1.1 - * (c) 2019 Saymon - * Released under the MIT License. - */var n={name:"TextareaAutosize",props:{value:{type:[String,Number],default:""},autosize:{type:Boolean,default:!0},minHeight:{type:[Number],default:null},maxHeight:{type:[Number],default:null},important:{type:[Boolean,Array],default:!1}},data:function(){return{val:null,maxHeightScroll:!1,height:"auto"}},computed:{computedStyles:function(){return this.autosize?{resize:this.isResizeImportant?"none !important":"none",height:this.height,overflow:this.maxHeightScroll?"auto":this.isOverflowImportant?"hidden !important":"hidden"}:{}},isResizeImportant:function(){var t=this.important;return!0===t||Array.isArray(t)&&t.includes("resize")},isOverflowImportant:function(){var t=this.important;return!0===t||Array.isArray(t)&&t.includes("overflow")},isHeightImportant:function(){var t=this.important;return!0===t||Array.isArray(t)&&t.includes("height")}},watch:{value:function(t){this.val=t},val:function(t){this.$nextTick(this.resize),this.$emit("input",t)},minHeight:function(){this.$nextTick(this.resize)},maxHeight:function(){this.$nextTick(this.resize)},autosize:function(t){t&&this.resize()}},methods:{resize:function(){var t=this,e=this.isHeightImportant?"important":"";return this.height="auto".concat(e?" !important":""),this.$nextTick((function(){var n=t.$el.scrollHeight+1;t.minHeight&&(n=n<t.minHeight?t.minHeight:n),t.maxHeight&&(n>t.maxHeight?(n=t.maxHeight,t.maxHeightScroll=!0):t.maxHeightScroll=!1);var r=n+"px";t.height="".concat(r).concat(e?" !important":"")})),this}},created:function(){this.val=this.value},mounted:function(){this.resize()}};function r(t,e,n,r,i,o,s,a,u,l){"boolean"!==typeof s&&(u=a,a=s,s=!1);var c,h="function"===typeof n?n.options:n;if(t&&t.render&&(h.render=t.render,h.staticRenderFns=t.staticRenderFns,h._compiled=!0,i&&(h.functional=!0)),r&&(h._scopeId=r),o?(c=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),e&&e.call(this,u(t)),t&&t._registeredComponents&&t._registeredComponents.add(o)},h._ssrRegister=c):e&&(c=s?function(){e.call(this,l(this.$root.$options.shadowRoot))}:function(t){e.call(this,a(t))}),c)if(h.functional){var f=h.render;h.render=function(t,e){return c.call(e),f(t,e)}}else{var d=h.beforeCreate;h.beforeCreate=d?[].concat(d,c):[c]}return n}var i=r;const o=n;var s=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.val,expression:"val"}],style:t.computedStyles,domProps:{value:t.val},on:{focus:t.resize,input:function(e){e.target.composing||(t.val=e.target.value)}}})},a=[];const u=void 0,l=void 0,c=void 0,h=!1;var f=i({render:s,staticRenderFns:a},u,o,l,h,c,void 0,void 0),d="1.1.1",p=function(t){t.component("TextareaAutosize",f)},m={install:p,version:d};"undefined"!==typeof window&&window.Vue&&window.Vue.use(m),e["Z"]=m},4865:function(t,e,n){"use strict";n.r(e),n.d(e,{BaseTransition:function(){return We},Comment:function(){return Ur},EffectScope:function(){return a},Fragment:function(){return Br},KeepAlive:function(){return sn},ReactiveEffect:function(){return R},Static:function(){return Gr},Suspense:function(){return Pe},Teleport:function(){return Or},Text:function(){return Fr},Transition:function(){return $s},TransitionGroup:function(){return pa},VueElement:function(){return Xs},callWithAsyncErrorHandling:function(){return ro},callWithErrorHandling:function(){return no},camelize:function(){return i._A},capitalize:function(){return i.kC},cloneVNode:function(){return si},compatUtils:function(){return as},compile:function(){return Cf},computed:function(){return ae},createApp:function(){return qa},createBlock:function(){return qr},createCommentVNode:function(){return li},createElementBlock:function(){return $r},createElementVNode:function(){return ni},createHydrationRenderer:function(){return mr},createPropsRestProxy:function(){return qo},createRenderer:function(){return pr},createSSRApp:function(){return Ka},createSlots:function(){return vi},createStaticVNode:function(){return ui},createTextVNode:function(){return ai},createVNode:function(){return ri},customRef:function(){return ne},defineAsyncComponent:function(){return en},defineComponent:function(){return Qe},defineCustomElement:function(){return Us},defineEmits:function(){return Ho},defineExpose:function(){return jo},defineProps:function(){return Xo},defineSSRCustomElement:function(){return Gs},devtools:function(){return ue},effect:function(){return O},effectScope:function(){return u},getCurrentInstance:function(){return Ii},getCurrentScope:function(){return c},getTransitionRawChildren:function(){return Je},guardReactiveProps:function(){return oi},h:function(){return Zo},handleError:function(){return io},hydrate:function(){return $a},initCustomFormatter:function(){return ts},initDirectivesForSSR:function(){return Qa},inject:function(){return He},isMemoSame:function(){return ns},isProxy:function(){return Gt},isReactive:function(){return Ft},isReadonly:function(){return Ut},isRef:function(){return Wt},isRuntimeOnly:function(){return Gi},isVNode:function(){return Kr},markRaw:function(){return Xt},mergeDefaults:function(){return $o},mergeProps:function(){return di},nextTick:function(){return bo},normalizeClass:function(){return i.C_},normalizeProps:function(){return i.vs},normalizeStyle:function(){return i.j5},onActivated:function(){return un},onBeforeMount:function(){return vn},onBeforeUnmount:function(){return bn},onBeforeUpdate:function(){return _n},onDeactivated:function(){return ln},onErrorCaptured:function(){return Rn},onMounted:function(){return gn},onRenderTracked:function(){return Sn},onRenderTriggered:function(){return xn},onScopeDispose:function(){return h},onServerPrefetch:function(){return Tn},onUnmounted:function(){return En},onUpdated:function(){return yn},openBlock:function(){return Hr},popScopeId:function(){return ye},provide:function(){return Xe},proxyRefs:function(){return te},pushScopeId:function(){return _e},queuePostFlushCb:function(){return Oo},reactive:function(){return Nt},readonly:function(){return Dt},ref:function(){return zt},registerRuntimeCompiler:function(){return Ui},render:function(){return za},renderList:function(){return mi},renderSlot:function(){return gi},resolveComponent:function(){return Cr},resolveDirective:function(){return Mr},resolveDynamicComponent:function(){return Nr},resolveFilter:function(){return ss},resolveTransitionHooks:function(){return $e},setBlockTracking:function(){return Wr},setDevtoolsHook:function(){return he},setTransitionHooks:function(){return Ze},shallowReactive:function(){return Mt},shallowReadonly:function(){return Lt},shallowRef:function(){return $t},ssrContextKey:function(){return Jo},ssrUtils:function(){return os},stop:function(){return I},toDisplayString:function(){return i.zw},toHandlerKey:function(){return i.hR},toHandlers:function(){return yi},toRaw:function(){return kt},toRef:function(){return oe},toRefs:function(){return re},transformVNodeArgs:function(){return Jr},triggerRef:function(){return Zt},unref:function(){return Jt},useAttrs:function(){return Wo},useCssModule:function(){return Hs},useCssVars:function(){return js},useSSRContext:function(){return Qo},useSlots:function(){return Yo},useTransitionState:function(){return je},vModelCheckbox:function(){return Sa},vModelDynamic:function(){return Pa},vModelRadio:function(){return Aa},vModelSelect:function(){return Oa},vModelText:function(){return xa},vShow:function(){return Ga},version:function(){return rs},warn:function(){return Ki},watch:function(){return Bo},watchEffect:function(){return No},watchPostEffect:function(){return Mo},watchSyncEffect:function(){return Do},withAsyncContext:function(){return Ko},withCtx:function(){return Ee},withDefaults:function(){return Vo},withDirectives:function(){return nr},withKeys:function(){return Ua},withMemo:function(){return es},withModifiers:function(){return Ba},withScopeId:function(){return be}});var r={};n.r(r),n.d(r,{BaseTransition:function(){return We},Comment:function(){return Ur},EffectScope:function(){return a},Fragment:function(){return Br},KeepAlive:function(){return sn},ReactiveEffect:function(){return R},Static:function(){return Gr},Suspense:function(){return Pe},Teleport:function(){return Or},Text:function(){return Fr},Transition:function(){return $s},TransitionGroup:function(){return pa},VueElement:function(){return Xs},callWithAsyncErrorHandling:function(){return ro},callWithErrorHandling:function(){return no},camelize:function(){return i._A},capitalize:function(){return i.kC},cloneVNode:function(){return si},compatUtils:function(){return as},computed:function(){return ae},createApp:function(){return qa},createBlock:function(){return qr},createCommentVNode:function(){return li},createElementBlock:function(){return $r},createElementVNode:function(){return ni},createHydrationRenderer:function(){return mr},createPropsRestProxy:function(){return qo},createRenderer:function(){return pr},createSSRApp:function(){return Ka},createSlots:function(){return vi},createStaticVNode:function(){return ui},createTextVNode:function(){return ai},createVNode:function(){return ri},customRef:function(){return ne},defineAsyncComponent:function(){return en},defineComponent:function(){return Qe},defineCustomElement:function(){return Us},defineEmits:function(){return Ho},defineExpose:function(){return jo},defineProps:function(){return Xo},defineSSRCustomElement:function(){return Gs},devtools:function(){return ue},effect:function(){return O},effectScope:function(){return u},getCurrentInstance:function(){return Ii},getCurrentScope:function(){return c},getTransitionRawChildren:function(){return Je},guardReactiveProps:function(){return oi},h:function(){return Zo},handleError:function(){return io},hydrate:function(){return $a},initCustomFormatter:function(){return ts},initDirectivesForSSR:function(){return Qa},inject:function(){return He},isMemoSame:function(){return ns},isProxy:function(){return Gt},isReactive:function(){return Ft},isReadonly:function(){return Ut},isRef:function(){return Wt},isRuntimeOnly:function(){return Gi},isVNode:function(){return Kr},markRaw:function(){return Xt},mergeDefaults:function(){return $o},mergeProps:function(){return di},nextTick:function(){return bo},normalizeClass:function(){return i.C_},normalizeProps:function(){return i.vs},normalizeStyle:function(){return i.j5},onActivated:function(){return un},onBeforeMount:function(){return vn},onBeforeUnmount:function(){return bn},onBeforeUpdate:function(){return _n},onDeactivated:function(){return ln},onErrorCaptured:function(){return Rn},onMounted:function(){return gn},onRenderTracked:function(){return Sn},onRenderTriggered:function(){return xn},onScopeDispose:function(){return h},onServerPrefetch:function(){return Tn},onUnmounted:function(){return En},onUpdated:function(){return yn},openBlock:function(){return Hr},popScopeId:function(){return ye},provide:function(){return Xe},proxyRefs:function(){return te},pushScopeId:function(){return _e},queuePostFlushCb:function(){return Oo},reactive:function(){return Nt},readonly:function(){return Dt},ref:function(){return zt},registerRuntimeCompiler:function(){return Ui},render:function(){return za},renderList:function(){return mi},renderSlot:function(){return gi},resolveComponent:function(){return Cr},resolveDirective:function(){return Mr},resolveDynamicComponent:function(){return Nr},resolveFilter:function(){return ss},resolveTransitionHooks:function(){return $e},setBlockTracking:function(){return Wr},setDevtoolsHook:function(){return he},setTransitionHooks:function(){return Ze},shallowReactive:function(){return Mt},shallowReadonly:function(){return Lt},shallowRef:function(){return $t},ssrContextKey:function(){return Jo},ssrUtils:function(){return os},stop:function(){return I},toDisplayString:function(){return i.zw},toHandlerKey:function(){return i.hR},toHandlers:function(){return yi},toRaw:function(){return kt},toRef:function(){return oe},toRefs:function(){return re},transformVNodeArgs:function(){return Jr},triggerRef:function(){return Zt},unref:function(){return Jt},useAttrs:function(){return Wo},useCssModule:function(){return Hs},useCssVars:function(){return js},useSSRContext:function(){return Qo},useSlots:function(){return Yo},useTransitionState:function(){return je},vModelCheckbox:function(){return Sa},vModelDynamic:function(){return Pa},vModelRadio:function(){return Aa},vModelSelect:function(){return Oa},vModelText:function(){return xa},vShow:function(){return Ga},version:function(){return rs},warn:function(){return Ki},watch:function(){return Bo},watchEffect:function(){return No},watchPostEffect:function(){return Mo},watchSyncEffect:function(){return Do},withAsyncContext:function(){return Ko},withCtx:function(){return Ee},withDefaults:function(){return Vo},withDirectives:function(){return nr},withKeys:function(){return Ua},withMemo:function(){return es},withModifiers:function(){return Ba},withScopeId:function(){return be}});var i=n(3577);let o;const s=[];class a{constructor(t=!1){this.active=!0,this.effects=[],this.cleanups=[],!t&&o&&(this.parent=o,this.index=(o.scopes||(o.scopes=[])).push(this)-1)}run(t){if(this.active)try{return this.on(),t()}finally{this.off()}else 0}on(){this.active&&(s.push(this),o=this)}off(){this.active&&(s.pop(),o=s[s.length-1])}stop(t){if(this.active){if(this.effects.forEach((t=>t.stop())),this.cleanups.forEach((t=>t())),this.scopes&&this.scopes.forEach((t=>t.stop(!0))),this.parent&&!t){const t=this.parent.scopes.pop();t&&t!==this&&(this.parent.scopes[this.index]=t,t.index=this.index)}this.active=!1}}}function u(t){return new a(t)}function l(t,e){e=e||o,e&&e.active&&e.effects.push(t)}function c(){return o}function h(t){o&&o.cleanups.push(t)}const f=t=>{const e=new Set(t);return e.w=0,e.n=0,e},d=t=>(t.w&y)>0,p=t=>(t.n&y)>0,m=({deps:t})=>{if(t.length)for(let e=0;e<t.length;e++)t[e].w|=y},v=t=>{const{deps:e}=t;if(e.length){let n=0;for(let r=0;r<e.length;r++){const i=e[r];d(i)&&!p(i)?i.delete(t):e[n++]=i,i.w&=~y,i.n&=~y}e.length=n}},g=new WeakMap;let _=0,y=1;const b=30,E=[];let T;const x=Symbol(""),S=Symbol("");class R{constructor(t,e=null,n){this.fn=t,this.scheduler=e,this.active=!0,this.deps=[],l(this,n)}run(){if(!this.active)return this.fn();if(!E.includes(this))try{return E.push(T=this),N(),y=1<<++_,_<=b?m(this):A(this),this.fn()}finally{_<=b&&v(this),y=1<<--_,M(),E.pop();const t=E.length;T=t>0?E[t-1]:void 0}}stop(){this.active&&(A(this),this.onStop&&this.onStop(),this.active=!1)}}function A(t){const{deps:e}=t;if(e.length){for(let n=0;n<e.length;n++)e[n].delete(t);e.length=0}}function O(t,e){t.effect&&(t=t.effect.fn);const n=new R(t);e&&((0,i.l7)(n,e),e.scope&&l(n,e.scope)),e&&e.lazy||n.run();const r=n.run.bind(n);return r.effect=n,r}function I(t){t.effect.stop()}let w=!0;const C=[];function P(){C.push(w),w=!1}function N(){C.push(w),w=!0}function M(){const t=C.pop();w=void 0===t||t}function D(t,e,n){if(!L())return;let r=g.get(t);r||g.set(t,r=new Map);let i=r.get(n);i||r.set(n,i=f());const o=void 0;B(i,o)}function L(){return w&&void 0!==T}function B(t,e){let n=!1;_<=b?p(t)||(t.n|=y,n=!d(t)):n=!t.has(T),n&&(t.add(T),T.deps.push(t))}function F(t,e,n,r,o,s){const a=g.get(t);if(!a)return;let u=[];if("clear"===e)u=[...a.values()];else if("length"===n&&(0,i.kJ)(t))a.forEach(((t,e)=>{("length"===e||e>=r)&&u.push(t)}));else switch(void 0!==n&&u.push(a.get(n)),e){case"add":(0,i.kJ)(t)?(0,i.S0)(n)&&u.push(a.get("length")):(u.push(a.get(x)),(0,i._N)(t)&&u.push(a.get(S)));break;case"delete":(0,i.kJ)(t)||(u.push(a.get(x)),(0,i._N)(t)&&u.push(a.get(S)));break;case"set":(0,i._N)(t)&&u.push(a.get(x));break}if(1===u.length)u[0]&&U(u[0]);else{const t=[];for(const e of u)e&&t.push(...e);U(f(t))}}function U(t,e){for(const n of(0,i.kJ)(t)?t:[...t])(n!==T||n.allowRecurse)&&(n.scheduler?n.scheduler():n.run())}const G=(0,i.fY)("__proto__,__v_isRef,__isVue"),k=new Set(Object.getOwnPropertyNames(Symbol).map((t=>Symbol[t])).filter(i.yk)),X=z(),H=z(!1,!0),j=z(!0),V=z(!0,!0),Y=W();function W(){const t={};return["includes","indexOf","lastIndexOf"].forEach((e=>{t[e]=function(...t){const n=kt(this);for(let e=0,i=this.length;e<i;e++)D(n,"get",e+"");const r=n[e](...t);return-1===r||!1===r?n[e](...t.map(kt)):r}})),["push","pop","shift","unshift","splice"].forEach((e=>{t[e]=function(...t){P();const n=kt(this)[e].apply(this,t);return M(),n}})),t}function z(t=!1,e=!1){return function(n,r,o){if("__v_isReactive"===r)return!t;if("__v_isReadonly"===r)return t;if("__v_raw"===r&&o===(t?e?wt:It:e?Ot:At).get(n))return n;const s=(0,i.kJ)(n);if(!t&&s&&(0,i.RI)(Y,r))return Reflect.get(Y,r,o);const a=Reflect.get(n,r,o);if((0,i.yk)(r)?k.has(r):G(r))return a;if(t||D(n,"get",r),e)return a;if(Wt(a)){const t=!s||!(0,i.S0)(r);return t?a.value:a}return(0,i.Kn)(a)?t?Dt(a):Nt(a):a}}const $=K(),q=K(!0);function K(t=!1){return function(e,n,r,o){let s=e[n];if(!t&&!Ut(r)&&(r=kt(r),s=kt(s),!(0,i.kJ)(e)&&Wt(s)&&!Wt(r)))return s.value=r,!0;const a=(0,i.kJ)(e)&&(0,i.S0)(n)?Number(n)<e.length:(0,i.RI)(e,n),u=Reflect.set(e,n,r,o);return e===kt(o)&&(a?(0,i.aU)(r,s)&&F(e,"set",n,r,s):F(e,"add",n,r)),u}}function Z(t,e){const n=(0,i.RI)(t,e),r=t[e],o=Reflect.deleteProperty(t,e);return o&&n&&F(t,"delete",e,void 0,r),o}function J(t,e){const n=Reflect.has(t,e);return(0,i.yk)(e)&&k.has(e)||D(t,"has",e),n}function Q(t){return D(t,"iterate",(0,i.kJ)(t)?"length":x),Reflect.ownKeys(t)}const tt={get:X,set:$,deleteProperty:Z,has:J,ownKeys:Q},et={get:j,set(t,e){return!0},deleteProperty(t,e){return!0}},nt=(0,i.l7)({},tt,{get:H,set:q}),rt=(0,i.l7)({},et,{get:V}),it=t=>t,ot=t=>Reflect.getPrototypeOf(t);function st(t,e,n=!1,r=!1){t=t["__v_raw"];const i=kt(t),o=kt(e);e!==o&&!n&&D(i,"get",e),!n&&D(i,"get",o);const{has:s}=ot(i),a=r?it:n?jt:Ht;return s.call(i,e)?a(t.get(e)):s.call(i,o)?a(t.get(o)):void(t!==i&&t.get(e))}function at(t,e=!1){const n=this["__v_raw"],r=kt(n),i=kt(t);return t!==i&&!e&&D(r,"has",t),!e&&D(r,"has",i),t===i?n.has(t):n.has(t)||n.has(i)}function ut(t,e=!1){return t=t["__v_raw"],!e&&D(kt(t),"iterate",x),Reflect.get(t,"size",t)}function lt(t){t=kt(t);const e=kt(this),n=ot(e),r=n.has.call(e,t);return r||(e.add(t),F(e,"add",t,t)),this}function ct(t,e){e=kt(e);const n=kt(this),{has:r,get:o}=ot(n);let s=r.call(n,t);s||(t=kt(t),s=r.call(n,t));const a=o.call(n,t);return n.set(t,e),s?(0,i.aU)(e,a)&&F(n,"set",t,e,a):F(n,"add",t,e),this}function ht(t){const e=kt(this),{has:n,get:r}=ot(e);let i=n.call(e,t);i||(t=kt(t),i=n.call(e,t));const o=r?r.call(e,t):void 0,s=e.delete(t);return i&&F(e,"delete",t,void 0,o),s}function ft(){const t=kt(this),e=0!==t.size,n=void 0,r=t.clear();return e&&F(t,"clear",void 0,void 0,n),r}function dt(t,e){return function(n,r){const i=this,o=i["__v_raw"],s=kt(o),a=e?it:t?jt:Ht;return!t&&D(s,"iterate",x),o.forEach(((t,e)=>n.call(r,a(t),a(e),i)))}}function pt(t,e,n){return function(...r){const o=this["__v_raw"],s=kt(o),a=(0,i._N)(s),u="entries"===t||t===Symbol.iterator&&a,l="keys"===t&&a,c=o[t](...r),h=n?it:e?jt:Ht;return!e&&D(s,"iterate",l?S:x),{next(){const{value:t,done:e}=c.next();return e?{value:t,done:e}:{value:u?[h(t[0]),h(t[1])]:h(t),done:e}},[Symbol.iterator](){return this}}}}function mt(t){return function(...e){return"delete"!==t&&this}}function vt(){const t={get(t){return st(this,t)},get size(){return ut(this)},has:at,add:lt,set:ct,delete:ht,clear:ft,forEach:dt(!1,!1)},e={get(t){return st(this,t,!1,!0)},get size(){return ut(this)},has:at,add:lt,set:ct,delete:ht,clear:ft,forEach:dt(!1,!0)},n={get(t){return st(this,t,!0)},get size(){return ut(this,!0)},has(t){return at.call(this,t,!0)},add:mt("add"),set:mt("set"),delete:mt("delete"),clear:mt("clear"),forEach:dt(!0,!1)},r={get(t){return st(this,t,!0,!0)},get size(){return ut(this,!0)},has(t){return at.call(this,t,!0)},add:mt("add"),set:mt("set"),delete:mt("delete"),clear:mt("clear"),forEach:dt(!0,!0)},i=["keys","values","entries",Symbol.iterator];return i.forEach((i=>{t[i]=pt(i,!1,!1),n[i]=pt(i,!0,!1),e[i]=pt(i,!1,!0),r[i]=pt(i,!0,!0)})),[t,n,e,r]}const[gt,_t,yt,bt]=vt();function Et(t,e){const n=e?t?bt:yt:t?_t:gt;return(e,r,o)=>"__v_isReactive"===r?!t:"__v_isReadonly"===r?t:"__v_raw"===r?e:Reflect.get((0,i.RI)(n,r)&&r in e?n:e,r,o)}const Tt={get:Et(!1,!1)},xt={get:Et(!1,!0)},St={get:Et(!0,!1)},Rt={get:Et(!0,!0)};const At=new WeakMap,Ot=new WeakMap,It=new WeakMap,wt=new WeakMap;function Ct(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Pt(t){return t["__v_skip"]||!Object.isExtensible(t)?0:Ct((0,i.W7)(t))}function Nt(t){return t&&t["__v_isReadonly"]?t:Bt(t,!1,tt,Tt,At)}function Mt(t){return Bt(t,!1,nt,xt,Ot)}function Dt(t){return Bt(t,!0,et,St,It)}function Lt(t){return Bt(t,!0,rt,Rt,wt)}function Bt(t,e,n,r,o){if(!(0,i.Kn)(t))return t;if(t["__v_raw"]&&(!e||!t["__v_isReactive"]))return t;const s=o.get(t);if(s)return s;const a=Pt(t);if(0===a)return t;const u=new Proxy(t,2===a?r:n);return o.set(t,u),u}function Ft(t){return Ut(t)?Ft(t["__v_raw"]):!(!t||!t["__v_isReactive"])}function Ut(t){return!(!t||!t["__v_isReadonly"])}function Gt(t){return Ft(t)||Ut(t)}function kt(t){const e=t&&t["__v_raw"];return e?kt(e):t}function Xt(t){return(0,i.Nj)(t,"__v_skip",!0),t}const Ht=t=>(0,i.Kn)(t)?Nt(t):t,jt=t=>(0,i.Kn)(t)?Dt(t):t;function Vt(t){L()&&(t=kt(t),t.dep||(t.dep=f()),B(t.dep))}function Yt(t,e){t=kt(t),t.dep&&U(t.dep)}function Wt(t){return Boolean(t&&!0===t.__v_isRef)}function zt(t){return qt(t,!1)}function $t(t){return qt(t,!0)}function qt(t,e){return Wt(t)?t:new Kt(t,e)}class Kt{constructor(t,e){this._shallow=e,this.dep=void 0,this.__v_isRef=!0,this._rawValue=e?t:kt(t),this._value=e?t:Ht(t)}get value(){return Vt(this),this._value}set value(t){t=this._shallow?t:kt(t),(0,i.aU)(t,this._rawValue)&&(this._rawValue=t,this._value=this._shallow?t:Ht(t),Yt(this,t))}}function Zt(t){Yt(t,void 0)}function Jt(t){return Wt(t)?t.value:t}const Qt={get:(t,e,n)=>Jt(Reflect.get(t,e,n)),set:(t,e,n,r)=>{const i=t[e];return Wt(i)&&!Wt(n)?(i.value=n,!0):Reflect.set(t,e,n,r)}};function te(t){return Ft(t)?t:new Proxy(t,Qt)}class ee{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:e,set:n}=t((()=>Vt(this)),(()=>Yt(this)));this._get=e,this._set=n}get value(){return this._get()}set value(t){this._set(t)}}function ne(t){return new ee(t)}function re(t){const e=(0,i.kJ)(t)?new Array(t.length):{};for(const n in t)e[n]=oe(t,n);return e}class ie{constructor(t,e,n){this._object=t,this._key=e,this._defaultValue=n,this.__v_isRef=!0}get value(){const t=this._object[this._key];return void 0===t?this._defaultValue:t}set value(t){this._object[this._key]=t}}function oe(t,e,n){const r=t[e];return Wt(r)?r:new ie(t,e,n)}class se{constructor(t,e,n){this._setter=e,this.dep=void 0,this._dirty=!0,this.__v_isRef=!0,this.effect=new R(t,(()=>{this._dirty||(this._dirty=!0,Yt(this))})),this["__v_isReadonly"]=n}get value(){const t=kt(this);return Vt(t),t._dirty&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function ae(t,e){let n,r;const o=(0,i.mf)(t);o?(n=t,r=i.dG):(n=t.get,r=t.set);const s=new se(n,r,o||!r);return s}Promise.resolve();new Set;new Map;let ue,le=[],ce=!1;function he(t,e){var n,r;if(ue=t,ue)ue.enabled=!0,le.forEach((({event:t,args:e})=>ue.emit(t,...e))),le=[];else if("undefined"!==typeof window&&window.HTMLElement&&!(null===(r=null===(n=window.navigator)||void 0===n?void 0:n.userAgent)||void 0===r?void 0:r.includes("jsdom"))){const t=e.__VUE_DEVTOOLS_HOOK_REPLAY__=e.__VUE_DEVTOOLS_HOOK_REPLAY__||[];t.push((t=>{he(t,e)})),setTimeout((()=>{ue||(e.__VUE_DEVTOOLS_HOOK_REPLAY__=null,ce=!0,le=[])}),3e3)}else ce=!0,le=[]}function fe(t,e,...n){const r=t.vnode.props||i.kT;let o=n;const s=e.startsWith("update:"),a=s&&e.slice(7);if(a&&a in r){const t=`${"modelValue"===a?"model":a}Modifiers`,{number:e,trim:s}=r[t]||i.kT;s?o=n.map((t=>t.trim())):e&&(o=n.map(i.He))}let u;let l=r[u=(0,i.hR)(e)]||r[u=(0,i.hR)((0,i._A)(e))];!l&&s&&(l=r[u=(0,i.hR)((0,i.rs)(e))]),l&&ro(l,t,6,o);const c=r[u+"Once"];if(c){if(t.emitted){if(t.emitted[u])return}else t.emitted={};t.emitted[u]=!0,ro(c,t,6,o)}}function de(t,e,n=!1){const r=e.emitsCache,o=r.get(t);if(void 0!==o)return o;const s=t.emits;let a={},u=!1;if(!(0,i.mf)(t)){const r=t=>{const n=de(t,e,!0);n&&(u=!0,(0,i.l7)(a,n))};!n&&e.mixins.length&&e.mixins.forEach(r),t.extends&&r(t.extends),t.mixins&&t.mixins.forEach(r)}return s||u?((0,i.kJ)(s)?s.forEach((t=>a[t]=null)):(0,i.l7)(a,s),r.set(t,a),a):(r.set(t,null),null)}function pe(t,e){return!(!t||!(0,i.F7)(e))&&(e=e.slice(2).replace(/Once$/,""),(0,i.RI)(t,e[0].toLowerCase()+e.slice(1))||(0,i.RI)(t,(0,i.rs)(e))||(0,i.RI)(t,e))}let me=null,ve=null;function ge(t){const e=me;return me=t,ve=t&&t.type.__scopeId||null,e}function _e(t){ve=t}function ye(){ve=null}const be=t=>Ee;function Ee(t,e=me,n){if(!e)return t;if(t._n)return t;const r=(...n)=>{r._d&&Wr(-1);const i=ge(e),o=t(...n);return ge(i),r._d&&Wr(1),o};return r._n=!0,r._c=!0,r._d=!0,r}function Te(t){const{type:e,vnode:n,proxy:r,withProxy:o,props:s,propsOptions:[a],slots:u,attrs:l,emit:c,render:h,renderCache:f,data:d,setupState:p,ctx:m,inheritAttrs:v}=t;let g,_;const y=ge(t);try{if(4&n.shapeFlag){const t=o||r;g=ci(h.call(t,t,f,s,p,d,m)),_=l}else{const t=e;0,g=ci(t.length>1?t(s,{attrs:l,slots:u,emit:c}):t(s,null)),_=e.props?l:Se(l)}}catch(E){kr.length=0,io(E,t,1),g=ri(Ur)}let b=g;if(_&&!1!==v){const t=Object.keys(_),{shapeFlag:e}=b;t.length&&7&e&&(a&&t.some(i.tR)&&(_=Re(_,a)),b=si(b,_))}return n.dirs&&(b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&(b.transition=n.transition),g=b,ge(y),g}function xe(t){let e;for(let n=0;n<t.length;n++){const r=t[n];if(!Kr(r))return;if(r.type!==Ur||"v-if"===r.children){if(e)return;e=r}}return e}const Se=t=>{let e;for(const n in t)("class"===n||"style"===n||(0,i.F7)(n))&&((e||(e={}))[n]=t[n]);return e},Re=(t,e)=>{const n={};for(const r in t)(0,i.tR)(r)&&r.slice(9)in e||(n[r]=t[r]);return n};function Ae(t,e,n){const{props:r,children:i,component:o}=t,{props:s,children:a,patchFlag:u}=e,l=o.emitsOptions;if(e.dirs||e.transition)return!0;if(!(n&&u>=0))return!(!i&&!a||a&&a.$stable)||r!==s&&(r?!s||Oe(r,s,l):!!s);if(1024&u)return!0;if(16&u)return r?Oe(r,s,l):!!s;if(8&u){const t=e.dynamicProps;for(let e=0;e<t.length;e++){const n=t[e];if(s[n]!==r[n]&&!pe(l,n))return!0}}return!1}function Oe(t,e,n){const r=Object.keys(e);if(r.length!==Object.keys(t).length)return!0;for(let i=0;i<r.length;i++){const o=r[i];if(e[o]!==t[o]&&!pe(n,o))return!0}return!1}function Ie({vnode:t,parent:e},n){while(e&&e.subTree===t)(t=e.vnode).el=n,e=e.parent}const we=t=>t.__isSuspense,Ce={name:"Suspense",__isSuspense:!0,process(t,e,n,r,i,o,s,a,u,l){null==t?Me(e,n,r,i,o,s,a,u,l):De(t,e,n,r,i,s,a,u,l)},hydrate:Be,create:Le,normalize:Fe},Pe=Ce;function Ne(t,e){const n=t.props&&t.props[e];(0,i.mf)(n)&&n()}function Me(t,e,n,r,i,o,s,a,u){const{p:l,o:{createElement:c}}=u,h=c("div"),f=t.suspense=Le(t,i,r,e,h,n,o,s,a,u);l(null,f.pendingBranch=t.ssContent,h,null,r,f,o,s),f.deps>0?(Ne(t,"onPending"),Ne(t,"onFallback"),l(null,t.ssFallback,e,n,r,null,o,s),ke(f,t.ssFallback)):f.resolve()}function De(t,e,n,r,i,o,s,a,{p:u,um:l,o:{createElement:c}}){const h=e.suspense=t.suspense;h.vnode=e,e.el=t.el;const f=e.ssContent,d=e.ssFallback,{activeBranch:p,pendingBranch:m,isInFallback:v,isHydrating:g}=h;if(m)h.pendingBranch=f,Zr(f,m)?(u(m,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0?h.resolve():v&&(u(p,d,n,r,i,null,o,s,a),ke(h,d))):(h.pendingId++,g?(h.isHydrating=!1,h.activeBranch=m):l(m,i,h),h.deps=0,h.effects.length=0,h.hiddenContainer=c("div"),v?(u(null,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0?h.resolve():(u(p,d,n,r,i,null,o,s,a),ke(h,d))):p&&Zr(f,p)?(u(p,f,n,r,i,h,o,s,a),h.resolve(!0)):(u(null,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0&&h.resolve()));else if(p&&Zr(f,p))u(p,f,n,r,i,h,o,s,a),ke(h,f);else if(Ne(e,"onPending"),h.pendingBranch=f,h.pendingId++,u(null,f,h.hiddenContainer,null,i,h,o,s,a),h.deps<=0)h.resolve();else{const{timeout:t,pendingId:e}=h;t>0?setTimeout((()=>{h.pendingId===e&&h.fallback(d)}),t):0===t&&h.fallback(d)}}function Le(t,e,n,r,o,s,a,u,l,c,h=!1){const{p:f,m:d,um:p,n:m,o:{parentNode:v,remove:g}}=c,_=(0,i.He)(t.props&&t.props.timeout),y={vnode:t,parent:e,parentComponent:n,isSVG:a,container:r,hiddenContainer:o,anchor:s,deps:0,pendingId:0,timeout:"number"===typeof _?_:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:h,isUnmounted:!1,effects:[],resolve(t=!1){const{vnode:e,activeBranch:n,pendingBranch:r,pendingId:i,effects:o,parentComponent:s,container:a}=y;if(y.isHydrating)y.isHydrating=!1;else if(!t){const t=n&&r.transition&&"out-in"===r.transition.mode;t&&(n.transition.afterLeave=()=>{i===y.pendingId&&d(r,a,e,0)});let{anchor:e}=y;n&&(e=m(n),p(n,s,y,!0)),t||d(r,a,e,0)}ke(y,r),y.pendingBranch=null,y.isInFallback=!1;let u=y.parent,l=!1;while(u){if(u.pendingBranch){u.effects.push(...o),l=!0;break}u=u.parent}l||Oo(o),y.effects=[],Ne(e,"onResolve")},fallback(t){if(!y.pendingBranch)return;const{vnode:e,activeBranch:n,parentComponent:r,container:i,isSVG:o}=y;Ne(e,"onFallback");const s=m(n),a=()=>{y.isInFallback&&(f(null,t,i,s,r,null,o,u,l),ke(y,t))},c=t.transition&&"out-in"===t.transition.mode;c&&(n.transition.afterLeave=a),y.isInFallback=!0,p(n,r,null,!0),c||a()},move(t,e,n){y.activeBranch&&d(y.activeBranch,t,e,n),y.container=t},next(){return y.activeBranch&&m(y.activeBranch)},registerDep(t,e){const n=!!y.pendingBranch;n&&y.deps++;const r=t.vnode.el;t.asyncDep.catch((e=>{io(e,t,0)})).then((i=>{if(t.isUnmounted||y.isUnmounted||y.pendingId!==t.suspenseId)return;t.asyncResolved=!0;const{vnode:o}=t;Fi(t,i,!1),r&&(o.el=r);const s=!r&&t.subTree.el;e(t,o,v(r||t.subTree.el),r?null:m(t.subTree),y,a,l),s&&g(s),Ie(t,o.el),n&&0===--y.deps&&y.resolve()}))},unmount(t,e){y.isUnmounted=!0,y.activeBranch&&p(y.activeBranch,n,t,e),y.pendingBranch&&p(y.pendingBranch,n,t,e)}};return y}function Be(t,e,n,r,i,o,s,a,u){const l=e.suspense=Le(e,r,n,t.parentNode,document.createElement("div"),null,i,o,s,a,!0),c=u(t,l.pendingBranch=e.ssContent,n,l,o,s);return 0===l.deps&&l.resolve(),c}function Fe(t){const{shapeFlag:e,children:n}=t,r=32&e;t.ssContent=Ue(r?n.default:n),t.ssFallback=r?Ue(n.fallback):ri(Ur)}function Ue(t){let e;if((0,i.mf)(t)){const n=Yr&&t._c;n&&(t._d=!1,Hr()),t=t(),n&&(t._d=!0,e=Xr,jr())}if((0,i.kJ)(t)){const e=xe(t);0,t=e}return t=ci(t),e&&!t.dynamicChildren&&(t.dynamicChildren=e.filter((e=>e!==t))),t}function Ge(t,e){e&&e.pendingBranch?(0,i.kJ)(t)?e.effects.push(...t):e.effects.push(t):Oo(t)}function ke(t,e){t.activeBranch=e;const{vnode:n,parentComponent:r}=t,i=n.el=e.el;r&&r.subTree===n&&(r.vnode.el=i,Ie(r,i))}function Xe(t,e){if(Oi){let n=Oi.provides;const r=Oi.parent&&Oi.parent.provides;r===n&&(n=Oi.provides=Object.create(r)),n[t]=e}else 0}function He(t,e,n=!1){const r=Oi||me;if(r){const o=null==r.parent?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides;if(o&&t in o)return o[t];if(arguments.length>1)return n&&(0,i.mf)(e)?e.call(r.proxy):e}else 0}function je(){const t={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return gn((()=>{t.isMounted=!0})),bn((()=>{t.isUnmounting=!0})),t}const Ve=[Function,Array],Ye={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Ve,onEnter:Ve,onAfterEnter:Ve,onEnterCancelled:Ve,onBeforeLeave:Ve,onLeave:Ve,onAfterLeave:Ve,onLeaveCancelled:Ve,onBeforeAppear:Ve,onAppear:Ve,onAfterAppear:Ve,onAppearCancelled:Ve},setup(t,{slots:e}){const n=Ii(),r=je();let i;return()=>{const o=e.default&&Je(e.default(),!0);if(!o||!o.length)return;const s=kt(t),{mode:a}=s;const u=o[0];if(r.isLeaving)return qe(u);const l=Ke(u);if(!l)return qe(u);const c=$e(l,s,r,n);Ze(l,c);const h=n.subTree,f=h&&Ke(h);let d=!1;const{getTransitionKey:p}=l.type;if(p){const t=p();void 0===i?i=t:t!==i&&(i=t,d=!0)}if(f&&f.type!==Ur&&(!Zr(l,f)||d)){const t=$e(f,s,r,n);if(Ze(f,t),"out-in"===a)return r.isLeaving=!0,t.afterLeave=()=>{r.isLeaving=!1,n.update()},qe(u);"in-out"===a&&l.type!==Ur&&(t.delayLeave=(t,e,n)=>{const i=ze(r,f);i[String(f.key)]=f,t._leaveCb=()=>{e(),t._leaveCb=void 0,delete c.delayedLeave},c.delayedLeave=n})}return u}}},We=Ye;function ze(t,e){const{leavingVNodes:n}=t;let r=n.get(e.type);return r||(r=Object.create(null),n.set(e.type,r)),r}function $e(t,e,n,r){const{appear:i,mode:o,persisted:s=!1,onBeforeEnter:a,onEnter:u,onAfterEnter:l,onEnterCancelled:c,onBeforeLeave:h,onLeave:f,onAfterLeave:d,onLeaveCancelled:p,onBeforeAppear:m,onAppear:v,onAfterAppear:g,onAppearCancelled:_}=e,y=String(t.key),b=ze(n,t),E=(t,e)=>{t&&ro(t,r,9,e)},T={mode:o,persisted:s,beforeEnter(e){let r=a;if(!n.isMounted){if(!i)return;r=m||a}e._leaveCb&&e._leaveCb(!0);const o=b[y];o&&Zr(t,o)&&o.el._leaveCb&&o.el._leaveCb(),E(r,[e])},enter(t){let e=u,r=l,o=c;if(!n.isMounted){if(!i)return;e=v||u,r=g||l,o=_||c}let s=!1;const a=t._enterCb=e=>{s||(s=!0,E(e?o:r,[t]),T.delayedLeave&&T.delayedLeave(),t._enterCb=void 0)};e?(e(t,a),e.length<=1&&a()):a()},leave(e,r){const i=String(t.key);if(e._enterCb&&e._enterCb(!0),n.isUnmounting)return r();E(h,[e]);let o=!1;const s=e._leaveCb=n=>{o||(o=!0,r(),E(n?p:d,[e]),e._leaveCb=void 0,b[i]===t&&delete b[i])};b[i]=t,f?(f(e,s),f.length<=1&&s()):s()},clone(t){return $e(t,e,n,r)}};return T}function qe(t){if(rn(t))return t=si(t),t.children=null,t}function Ke(t){return rn(t)?t.children?t.children[0]:void 0:t}function Ze(t,e){6&t.shapeFlag&&t.component?Ze(t.component.subTree,e):128&t.shapeFlag?(t.ssContent.transition=e.clone(t.ssContent),t.ssFallback.transition=e.clone(t.ssFallback)):t.transition=e}function Je(t,e=!1){let n=[],r=0;for(let i=0;i<t.length;i++){const o=t[i];o.type===Br?(128&o.patchFlag&&r++,n=n.concat(Je(o.children,e))):(e||o.type!==Ur)&&n.push(o)}if(r>1)for(let i=0;i<n.length;i++)n[i].patchFlag=-2;return n}function Qe(t){return(0,i.mf)(t)?{setup:t,name:t.name}:t}const tn=t=>!!t.type.__asyncLoader;function en(t){(0,i.mf)(t)&&(t={loader:t});const{loader:e,loadingComponent:n,errorComponent:r,delay:o=200,timeout:s,suspensible:a=!0,onError:u}=t;let l,c=null,h=0;const f=()=>(h++,c=null,d()),d=()=>{let t;return c||(t=c=e().catch((t=>{if(t=t instanceof Error?t:new Error(String(t)),u)return new Promise(((e,n)=>{const r=()=>e(f()),i=()=>n(t);u(t,r,i,h+1)}));throw t})).then((e=>t!==c&&c?c:(e&&(e.__esModule||"Module"===e[Symbol.toStringTag])&&(e=e.default),l=e,e))))};return Qe({name:"AsyncComponentWrapper",__asyncLoader:d,get __asyncResolved(){return l},setup(){const t=Oi;if(l)return()=>nn(l,t);const e=e=>{c=null,io(e,t,13,!r)};if(a&&t.suspense||Di)return d().then((e=>()=>nn(e,t))).catch((t=>(e(t),()=>r?ri(r,{error:t}):null)));const i=zt(!1),u=zt(),h=zt(!!o);return o&&setTimeout((()=>{h.value=!1}),o),null!=s&&setTimeout((()=>{if(!i.value&&!u.value){const t=new Error(`Async component timed out after ${s}ms.`);e(t),u.value=t}}),s),d().then((()=>{i.value=!0,t.parent&&rn(t.parent.vnode)&&To(t.parent.update)})).catch((t=>{e(t),u.value=t})),()=>i.value&&l?nn(l,t):u.value&&r?ri(r,{error:u.value}):n&&!h.value?ri(n):void 0}})}function nn(t,{vnode:{ref:e,props:n,children:r}}){const i=ri(t,n,r);return i.ref=e,i}const rn=t=>t.type.__isKeepAlive,on={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(t,{slots:e}){const n=Ii(),r=n.ctx;if(!r.renderer)return e.default;const o=new Map,s=new Set;let a=null;const u=n.suspense,{renderer:{p:l,m:c,um:h,o:{createElement:f}}}=r,d=f("div");function p(t){fn(t),h(t,n,u)}function m(t){o.forEach(((e,n)=>{const r=Wi(e.type);!r||t&&t(r)||v(n)}))}function v(t){const e=o.get(t);a&&e.type===a.type?a&&fn(a):p(e),o.delete(t),s.delete(t)}r.activate=(t,e,n,r,o)=>{const s=t.component;c(t,e,n,0,u),l(s.vnode,t,e,n,s,u,r,t.slotScopeIds,o),dr((()=>{s.isDeactivated=!1,s.a&&(0,i.ir)(s.a);const e=t.props&&t.props.onVnodeMounted;e&&pi(e,s.parent,t)}),u)},r.deactivate=t=>{const e=t.component;c(t,d,null,1,u),dr((()=>{e.da&&(0,i.ir)(e.da);const n=t.props&&t.props.onVnodeUnmounted;n&&pi(n,e.parent,t),e.isDeactivated=!0}),u)},Bo((()=>[t.include,t.exclude]),(([t,e])=>{t&&m((e=>an(t,e))),e&&m((t=>!an(e,t)))}),{flush:"post",deep:!0});let g=null;const _=()=>{null!=g&&o.set(g,dn(n.subTree))};return gn(_),yn(_),bn((()=>{o.forEach((t=>{const{subTree:e,suspense:r}=n,i=dn(e);if(t.type!==i.type)p(t);else{fn(i);const t=i.component.da;t&&dr(t,r)}}))})),()=>{if(g=null,!e.default)return null;const n=e.default(),r=n[0];if(n.length>1)return a=null,n;if(!Kr(r)||!(4&r.shapeFlag)&&!(128&r.shapeFlag))return a=null,r;let i=dn(r);const u=i.type,l=Wi(tn(i)?i.type.__asyncResolved||{}:u),{include:c,exclude:h,max:f}=t;if(c&&(!l||!an(c,l))||h&&l&&an(h,l))return a=i,r;const d=null==i.key?u:i.key,p=o.get(d);return i.el&&(i=si(i),128&r.shapeFlag&&(r.ssContent=i)),g=d,p?(i.el=p.el,i.component=p.component,i.transition&&Ze(i,i.transition),i.shapeFlag|=512,s.delete(d),s.add(d)):(s.add(d),f&&s.size>parseInt(f,10)&&v(s.values().next().value)),i.shapeFlag|=256,a=i,r}}},sn=on;function an(t,e){return(0,i.kJ)(t)?t.some((t=>an(t,e))):(0,i.HD)(t)?t.split(",").indexOf(e)>-1:!!t.test&&t.test(e)}function un(t,e){cn(t,"a",e)}function ln(t,e){cn(t,"da",e)}function cn(t,e,n=Oi){const r=t.__wdc||(t.__wdc=()=>{let e=n;while(e){if(e.isDeactivated)return;e=e.parent}return t()});if(pn(e,r,n),n){let t=n.parent;while(t&&t.parent)rn(t.parent.vnode)&&hn(r,e,n,t),t=t.parent}}function hn(t,e,n,r){const o=pn(e,t,r,!0);En((()=>{(0,i.Od)(r[e],o)}),n)}function fn(t){let e=t.shapeFlag;256&e&&(e-=256),512&e&&(e-=512),t.shapeFlag=e}function dn(t){return 128&t.shapeFlag?t.ssContent:t}function pn(t,e,n=Oi,r=!1){if(n){const i=n[t]||(n[t]=[]),o=e.__weh||(e.__weh=(...r)=>{if(n.isUnmounted)return;P(),wi(n);const i=ro(e,n,t,r);return Ci(),M(),i});return r?i.unshift(o):i.push(o),o}}const mn=t=>(e,n=Oi)=>(!Di||"sp"===t)&&pn(t,e,n),vn=mn("bm"),gn=mn("m"),_n=mn("bu"),yn=mn("u"),bn=mn("bum"),En=mn("um"),Tn=mn("sp"),xn=mn("rtg"),Sn=mn("rtc");function Rn(t,e=Oi){pn("ec",t,e)}let An=!0;function On(t){const e=Pn(t),n=t.proxy,r=t.ctx;An=!1,e.beforeCreate&&wn(e.beforeCreate,t,"bc");const{data:o,computed:s,methods:a,watch:u,provide:l,inject:c,created:h,beforeMount:f,mounted:d,beforeUpdate:p,updated:m,activated:v,deactivated:g,beforeDestroy:_,beforeUnmount:y,destroyed:b,unmounted:E,render:T,renderTracked:x,renderTriggered:S,errorCaptured:R,serverPrefetch:A,expose:O,inheritAttrs:I,components:w,directives:C,filters:P}=e,N=null;if(c&&In(c,r,N,t.appContext.config.unwrapInjectedRef),a)for(const D in a){const t=a[D];(0,i.mf)(t)&&(r[D]=t.bind(n))}if(o){0;const e=o.call(n,n);0,(0,i.Kn)(e)&&(t.data=Nt(e))}if(An=!0,s)for(const D in s){const t=s[D],e=(0,i.mf)(t)?t.bind(n,n):(0,i.mf)(t.get)?t.get.bind(n,n):i.dG;0;const o=!(0,i.mf)(t)&&(0,i.mf)(t.set)?t.set.bind(n):i.dG,a=ae({get:e,set:o});Object.defineProperty(r,D,{enumerable:!0,configurable:!0,get:()=>a.value,set:t=>a.value=t})}if(u)for(const i in u)Cn(u[i],r,n,i);if(l){const t=(0,i.mf)(l)?l.call(n):l;Reflect.ownKeys(t).forEach((e=>{Xe(e,t[e])}))}function M(t,e){(0,i.kJ)(e)?e.forEach((e=>t(e.bind(n)))):e&&t(e.bind(n))}if(h&&wn(h,t,"c"),M(vn,f),M(gn,d),M(_n,p),M(yn,m),M(un,v),M(ln,g),M(Rn,R),M(Sn,x),M(xn,S),M(bn,y),M(En,E),M(Tn,A),(0,i.kJ)(O))if(O.length){const e=t.exposed||(t.exposed={});O.forEach((t=>{Object.defineProperty(e,t,{get:()=>n[t],set:e=>n[t]=e})}))}else t.exposed||(t.exposed={});T&&t.render===i.dG&&(t.render=T),null!=I&&(t.inheritAttrs=I),w&&(t.components=w),C&&(t.directives=C)}function In(t,e,n=i.dG,r=!1){(0,i.kJ)(t)&&(t=Bn(t));for(const o in t){const n=t[o];let s;s=(0,i.Kn)(n)?"default"in n?He(n.from||o,n.default,!0):He(n.from||o):He(n),Wt(s)&&r?Object.defineProperty(e,o,{enumerable:!0,configurable:!0,get:()=>s.value,set:t=>s.value=t}):e[o]=s}}function wn(t,e,n){ro((0,i.kJ)(t)?t.map((t=>t.bind(e.proxy))):t.bind(e.proxy),e,n)}function Cn(t,e,n,r){const o=r.includes(".")?Go(n,r):()=>n[r];if((0,i.HD)(t)){const n=e[t];(0,i.mf)(n)&&Bo(o,n)}else if((0,i.mf)(t))Bo(o,t.bind(n));else if((0,i.Kn)(t))if((0,i.kJ)(t))t.forEach((t=>Cn(t,e,n,r)));else{const r=(0,i.mf)(t.handler)?t.handler.bind(n):e[t.handler];(0,i.mf)(r)&&Bo(o,r,t)}else 0}function Pn(t){const e=t.type,{mixins:n,extends:r}=e,{mixins:i,optionsCache:o,config:{optionMergeStrategies:s}}=t.appContext,a=o.get(e);let u;return a?u=a:i.length||n||r?(u={},i.length&&i.forEach((t=>Nn(u,t,s,!0))),Nn(u,e,s)):u=e,o.set(e,u),u}function Nn(t,e,n,r=!1){const{mixins:i,extends:o}=e;o&&Nn(t,o,n,!0),i&&i.forEach((e=>Nn(t,e,n,!0)));for(const s in e)if(r&&"expose"===s);else{const r=Mn[s]||n&&n[s];t[s]=r?r(t[s],e[s]):e[s]}return t}const Mn={data:Dn,props:Un,emits:Un,methods:Un,computed:Un,beforeCreate:Fn,created:Fn,beforeMount:Fn,mounted:Fn,beforeUpdate:Fn,updated:Fn,beforeDestroy:Fn,beforeUnmount:Fn,destroyed:Fn,unmounted:Fn,activated:Fn,deactivated:Fn,errorCaptured:Fn,serverPrefetch:Fn,components:Un,directives:Un,watch:Gn,provide:Dn,inject:Ln};function Dn(t,e){return e?t?function(){return(0,i.l7)((0,i.mf)(t)?t.call(this,this):t,(0,i.mf)(e)?e.call(this,this):e)}:e:t}function Ln(t,e){return Un(Bn(t),Bn(e))}function Bn(t){if((0,i.kJ)(t)){const e={};for(let n=0;n<t.length;n++)e[t[n]]=t[n];return e}return t}function Fn(t,e){return t?[...new Set([].concat(t,e))]:e}function Un(t,e){return t?(0,i.l7)((0,i.l7)(Object.create(null),t),e):e}function Gn(t,e){if(!t)return e;if(!e)return t;const n=(0,i.l7)(Object.create(null),t);for(const r in e)n[r]=Fn(t[r],e[r]);return n}function kn(t,e,n,r=!1){const o={},s={};(0,i.Nj)(s,Qr,1),t.propsDefaults=Object.create(null),Hn(t,e,o,s);for(const i in t.propsOptions[0])i in o||(o[i]=void 0);n?t.props=r?o:Mt(o):t.type.props?t.props=o:t.props=s,t.attrs=s}function Xn(t,e,n,r){const{props:o,attrs:s,vnode:{patchFlag:a}}=t,u=kt(o),[l]=t.propsOptions;let c=!1;if(!(r||a>0)||16&a){let r;Hn(t,e,o,s)&&(c=!0);for(const s in u)e&&((0,i.RI)(e,s)||(r=(0,i.rs)(s))!==s&&(0,i.RI)(e,r))||(l?!n||void 0===n[s]&&void 0===n[r]||(o[s]=jn(l,u,s,void 0,t,!0)):delete o[s]);if(s!==u)for(const t in s)e&&(0,i.RI)(e,t)||(delete s[t],c=!0)}else if(8&a){const n=t.vnode.dynamicProps;for(let r=0;r<n.length;r++){let a=n[r];const h=e[a];if(l)if((0,i.RI)(s,a))h!==s[a]&&(s[a]=h,c=!0);else{const e=(0,i._A)(a);o[e]=jn(l,u,e,h,t,!1)}else h!==s[a]&&(s[a]=h,c=!0)}}c&&F(t,"set","$attrs")}function Hn(t,e,n,r){const[o,s]=t.propsOptions;let a,u=!1;if(e)for(let l in e){if((0,i.Gg)(l))continue;const c=e[l];let h;o&&(0,i.RI)(o,h=(0,i._A)(l))?s&&s.includes(h)?(a||(a={}))[h]=c:n[h]=c:pe(t.emitsOptions,l)||l in r&&c===r[l]||(r[l]=c,u=!0)}if(s){const e=kt(n),r=a||i.kT;for(let a=0;a<s.length;a++){const u=s[a];n[u]=jn(o,e,u,r[u],t,!(0,i.RI)(r,u))}}return u}function jn(t,e,n,r,o,s){const a=t[n];if(null!=a){const t=(0,i.RI)(a,"default");if(t&&void 0===r){const t=a.default;if(a.type!==Function&&(0,i.mf)(t)){const{propsDefaults:i}=o;n in i?r=i[n]:(wi(o),r=i[n]=t.call(null,e),Ci())}else r=t}a[0]&&(s&&!t?r=!1:!a[1]||""!==r&&r!==(0,i.rs)(n)||(r=!0))}return r}function Vn(t,e,n=!1){const r=e.propsCache,o=r.get(t);if(o)return o;const s=t.props,a={},u=[];let l=!1;if(!(0,i.mf)(t)){const r=t=>{l=!0;const[n,r]=Vn(t,e,!0);(0,i.l7)(a,n),r&&u.push(...r)};!n&&e.mixins.length&&e.mixins.forEach(r),t.extends&&r(t.extends),t.mixins&&t.mixins.forEach(r)}if(!s&&!l)return r.set(t,i.Z6),i.Z6;if((0,i.kJ)(s))for(let h=0;h<s.length;h++){0;const t=(0,i._A)(s[h]);Yn(t)&&(a[t]=i.kT)}else if(s){0;for(const t in s){const e=(0,i._A)(t);if(Yn(e)){const n=s[t],r=a[e]=(0,i.kJ)(n)||(0,i.mf)(n)?{type:n}:n;if(r){const t=$n(Boolean,r.type),n=$n(String,r.type);r[0]=t>-1,r[1]=n<0||t<n,(t>-1||(0,i.RI)(r,"default"))&&u.push(e)}}}}const c=[a,u];return r.set(t,c),c}function Yn(t){return"$"!==t[0]}function Wn(t){const e=t&&t.toString().match(/^\s*function (\w+)/);return e?e[1]:null===t?"null":""}function zn(t,e){return Wn(t)===Wn(e)}function $n(t,e){return(0,i.kJ)(e)?e.findIndex((e=>zn(e,t))):(0,i.mf)(e)&&zn(e,t)?0:-1}const qn=t=>"_"===t[0]||"$stable"===t,Kn=t=>(0,i.kJ)(t)?t.map(ci):[ci(t)],Zn=(t,e,n)=>{const r=Ee(((...t)=>Kn(e(...t))),n);return r._c=!1,r},Jn=(t,e,n)=>{const r=t._ctx;for(const o in t){if(qn(o))continue;const n=t[o];if((0,i.mf)(n))e[o]=Zn(o,n,r);else if(null!=n){0;const t=Kn(n);e[o]=()=>t}}},Qn=(t,e)=>{const n=Kn(e);t.slots.default=()=>n},tr=(t,e)=>{if(32&t.vnode.shapeFlag){const n=e._;n?(t.slots=kt(e),(0,i.Nj)(e,"_",n)):Jn(e,t.slots={})}else t.slots={},e&&Qn(t,e);(0,i.Nj)(t.slots,Qr,1)},er=(t,e,n)=>{const{vnode:r,slots:o}=t;let s=!0,a=i.kT;if(32&r.shapeFlag){const t=e._;t?n&&1===t?s=!1:((0,i.l7)(o,e),n||1!==t||delete o._):(s=!e.$stable,Jn(e,o)),a=e}else e&&(Qn(t,e),a={default:1});if(s)for(const i in o)qn(i)||i in a||delete o[i]};function nr(t,e){const n=me;if(null===n)return t;const r=n.proxy,o=t.dirs||(t.dirs=[]);for(let s=0;s<e.length;s++){let[t,n,a,u=i.kT]=e[s];(0,i.mf)(t)&&(t={mounted:t,updated:t}),t.deep&&ko(n),o.push({dir:t,instance:r,value:n,oldValue:void 0,arg:a,modifiers:u})}return t}function rr(t,e,n,r){const i=t.dirs,o=e&&e.dirs;for(let s=0;s<i.length;s++){const a=i[s];o&&(a.oldValue=o[s].value);let u=a.dir[r];u&&(P(),ro(u,n,8,[t.el,a,t,e]),M())}}function ir(){return{app:null,config:{isNativeTag:i.NO,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let or=0;function sr(t,e){return function(n,r=null){null==r||(0,i.Kn)(r)||(r=null);const o=ir(),s=new Set;let a=!1;const u=o.app={_uid:or++,_component:n,_props:r,_container:null,_context:o,_instance:null,version:rs,get config(){return o.config},set config(t){0},use(t,...e){return s.has(t)||(t&&(0,i.mf)(t.install)?(s.add(t),t.install(u,...e)):(0,i.mf)(t)&&(s.add(t),t(u,...e))),u},mixin(t){return o.mixins.includes(t)||o.mixins.push(t),u},component(t,e){return e?(o.components[t]=e,u):o.components[t]},directive(t,e){return e?(o.directives[t]=e,u):o.directives[t]},mount(i,s,l){if(!a){const c=ri(n,r);return c.appContext=o,s&&e?e(c,i):t(c,i,l),a=!0,u._container=i,i.__vue_app__=u,ji(c.component)||c.component.proxy}},unmount(){a&&(t(null,u._container),delete u._container.__vue_app__)},provide(t,e){return o.provides[t]=e,u}};return u}}function ar(t,e,n,r,o=!1){if((0,i.kJ)(t))return void t.forEach(((t,s)=>ar(t,e&&((0,i.kJ)(e)?e[s]:e),n,r,o)));if(tn(r)&&!o)return;const s=4&r.shapeFlag?ji(r.component)||r.component.proxy:r.el,a=o?null:s,{i:u,r:l}=t;const c=e&&e.r,h=u.refs===i.kT?u.refs={}:u.refs,f=u.setupState;if(null!=c&&c!==l&&((0,i.HD)(c)?(h[c]=null,(0,i.RI)(f,c)&&(f[c]=null)):Wt(c)&&(c.value=null)),(0,i.mf)(l))no(l,u,12,[a,h]);else{const e=(0,i.HD)(l),r=Wt(l);if(e||r){const r=()=>{if(t.f){const n=e?h[l]:l.value;o?(0,i.kJ)(n)&&(0,i.Od)(n,s):(0,i.kJ)(n)?n.includes(s)||n.push(s):e?h[l]=[s]:(l.value=[s],t.k&&(h[t.k]=l.value))}else e?(h[l]=a,(0,i.RI)(f,l)&&(f[l]=a)):Wt(l)&&(l.value=a,t.k&&(h[t.k]=a))};a?(r.id=-1,dr(r,n)):r()}else 0}}let ur=!1;const lr=t=>/svg/.test(t.namespaceURI)&&"foreignObject"!==t.tagName,cr=t=>8===t.nodeType;function hr(t){const{mt:e,p:n,o:{patchProp:r,nextSibling:o,parentNode:s,remove:a,insert:u,createComment:l}}=t,c=(t,e)=>{if(!e.hasChildNodes())return n(null,t,e),void wo();ur=!1,h(e.firstChild,t,null,null,null),wo(),ur&&console.error("Hydration completed but contains mismatches.")},h=(n,r,i,a,u,l=!1)=>{const c=cr(n)&&"["===n.data,g=()=>m(n,r,i,a,u,c),{type:_,ref:y,shapeFlag:b}=r,E=n.nodeType;r.el=n;let T=null;switch(_){case Fr:3!==E?T=g():(n.data!==r.children&&(ur=!0,n.data=r.children),T=o(n));break;case Ur:T=8!==E||c?g():o(n);break;case Gr:if(1===E){T=n;const t=!r.children.length;for(let e=0;e<r.staticCount;e++)t&&(r.children+=T.outerHTML),e===r.staticCount-1&&(r.anchor=T),T=o(T);return T}T=g();break;case Br:T=c?p(n,r,i,a,u,l):g();break;default:if(1&b)T=1!==E||r.type.toLowerCase()!==n.tagName.toLowerCase()?g():f(n,r,i,a,u,l);else if(6&b){r.slotScopeIds=u;const t=s(n);if(e(r,t,null,i,a,lr(t),l),T=c?v(n):o(n),tn(r)){let e;c?(e=ri(Br),e.anchor=T?T.previousSibling:t.lastChild):e=3===n.nodeType?ai(""):ri("div"),e.el=n,r.component.subTree=e}}else 64&b?T=8!==E?g():r.type.hydrate(n,r,i,a,u,l,t,d):128&b&&(T=r.type.hydrate(n,r,i,a,lr(s(n)),u,l,t,h))}return null!=y&&ar(y,null,a,r),T},f=(t,e,n,o,s,u)=>{u=u||!!e.dynamicChildren;const{type:l,props:c,patchFlag:h,shapeFlag:f,dirs:p}=e,m="input"===l&&p||"option"===l;if(m||-1!==h){if(p&&rr(e,null,n,"created"),c)if(m||!u||48&h)for(const e in c)(m&&e.endsWith("value")||(0,i.F7)(e)&&!(0,i.Gg)(e))&&r(t,e,null,c[e],!1,void 0,n);else c.onClick&&r(t,"onClick",null,c.onClick,!1,void 0,n);let l;if((l=c&&c.onVnodeBeforeMount)&&pi(l,n,e),p&&rr(e,null,n,"beforeMount"),((l=c&&c.onVnodeMounted)||p)&&Ge((()=>{l&&pi(l,n,e),p&&rr(e,null,n,"mounted")}),o),16&f&&(!c||!c.innerHTML&&!c.textContent)){let r=d(t.firstChild,e,t,n,o,s,u);while(r){ur=!0;const t=r;r=r.nextSibling,a(t)}}else 8&f&&t.textContent!==e.children&&(ur=!0,t.textContent=e.children)}return t.nextSibling},d=(t,e,r,i,o,s,a)=>{a=a||!!e.dynamicChildren;const u=e.children,l=u.length;for(let c=0;c<l;c++){const e=a?u[c]:u[c]=ci(u[c]);if(t)t=h(t,e,i,o,s,a);else{if(e.type===Fr&&!e.children)continue;ur=!0,n(null,e,r,null,i,o,lr(r),s)}}return t},p=(t,e,n,r,i,a)=>{const{slotScopeIds:c}=e;c&&(i=i?i.concat(c):c);const h=s(t),f=d(o(t),e,h,n,r,i,a);return f&&cr(f)&&"]"===f.data?o(e.anchor=f):(ur=!0,u(e.anchor=l("]"),h,f),f)},m=(t,e,r,i,u,l)=>{if(ur=!0,e.el=null,l){const e=v(t);while(1){const n=o(t);if(!n||n===e)break;a(n)}}const c=o(t),h=s(t);return a(t),n(null,e,h,c,r,i,lr(h),u),c},v=t=>{let e=0;while(t)if(t=o(t),t&&cr(t)&&("["===t.data&&e++,"]"===t.data)){if(0===e)return o(t);e--}return t};return[c,h]}function fr(){}const dr=Ge;function pr(t){return vr(t)}function mr(t){return vr(t,hr)}function vr(t,e){fr();const n=(0,i.E9)();n.__VUE__=!0;const{insert:r,remove:o,patchProp:s,createElement:a,createText:u,createComment:l,setText:c,setElementText:h,parentNode:f,nextSibling:d,setScopeId:p=i.dG,cloneNode:m,insertStaticContent:v}=t,g=(t,e,n,r=null,i=null,o=null,s=!1,a=null,u=!!e.dynamicChildren)=>{if(t===e)return;t&&!Zr(t,e)&&(r=$(t),j(t,i,o,!0),t=null),-2===e.patchFlag&&(u=!1,e.dynamicChildren=null);const{type:l,ref:c,shapeFlag:h}=e;switch(l){case Fr:_(t,e,n,r);break;case Ur:y(t,e,n,r);break;case Gr:null==t&&b(e,n,r,s);break;case Br:N(t,e,n,r,i,o,s,a,u);break;default:1&h?x(t,e,n,r,i,o,s,a,u):6&h?D(t,e,n,r,i,o,s,a,u):(64&h||128&h)&&l.process(t,e,n,r,i,o,s,a,u,K)}null!=c&&i&&ar(c,t&&t.ref,o,e||t,!e)},_=(t,e,n,i)=>{if(null==t)r(e.el=u(e.children),n,i);else{const n=e.el=t.el;e.children!==t.children&&c(n,e.children)}},y=(t,e,n,i)=>{null==t?r(e.el=l(e.children||""),n,i):e.el=t.el},b=(t,e,n,r)=>{[t.el,t.anchor]=v(t.children,e,n,r)},E=({el:t,anchor:e},n,i)=>{let o;while(t&&t!==e)o=d(t),r(t,n,i),t=o;r(e,n,i)},T=({el:t,anchor:e})=>{let n;while(t&&t!==e)n=d(t),o(t),t=n;o(e)},x=(t,e,n,r,i,o,s,a,u)=>{s=s||"svg"===e.type,null==t?S(e,n,r,i,o,s,a,u):I(t,e,i,o,s,a,u)},S=(t,e,n,o,u,l,c,f)=>{let d,p;const{type:v,props:g,shapeFlag:_,transition:y,patchFlag:b,dirs:E}=t;if(t.el&&void 0!==m&&-1===b)d=t.el=m(t.el);else{if(d=t.el=a(t.type,l,g&&g.is,g),8&_?h(d,t.children):16&_&&O(t.children,d,null,o,u,l&&"foreignObject"!==v,c,f),E&&rr(t,null,o,"created"),g){for(const e in g)"value"===e||(0,i.Gg)(e)||s(d,e,null,g[e],l,t.children,o,u,z);"value"in g&&s(d,"value",null,g.value),(p=g.onVnodeBeforeMount)&&pi(p,o,t)}A(d,t,t.scopeId,c,o)}E&&rr(t,null,o,"beforeMount");const T=(!u||u&&!u.pendingBranch)&&y&&!y.persisted;T&&y.beforeEnter(d),r(d,e,n),((p=g&&g.onVnodeMounted)||T||E)&&dr((()=>{p&&pi(p,o,t),T&&y.enter(d),E&&rr(t,null,o,"mounted")}),u)},A=(t,e,n,r,i)=>{if(n&&p(t,n),r)for(let o=0;o<r.length;o++)p(t,r[o]);if(i){let n=i.subTree;if(e===n){const e=i.vnode;A(t,e,e.scopeId,e.slotScopeIds,i.parent)}}},O=(t,e,n,r,i,o,s,a,u=0)=>{for(let l=u;l<t.length;l++){const u=t[l]=a?hi(t[l]):ci(t[l]);g(null,u,e,n,r,i,o,s,a)}},I=(t,e,n,r,o,a,u)=>{const l=e.el=t.el;let{patchFlag:c,dynamicChildren:f,dirs:d}=e;c|=16&t.patchFlag;const p=t.props||i.kT,m=e.props||i.kT;let v;n&&gr(n,!1),(v=m.onVnodeBeforeUpdate)&&pi(v,n,e,t),d&&rr(e,t,n,"beforeUpdate"),n&&gr(n,!0);const g=o&&"foreignObject"!==e.type;if(f?w(t.dynamicChildren,f,l,n,r,g,a):u||G(t,e,l,null,n,r,g,a,!1),c>0){if(16&c)C(l,e,p,m,n,r,o);else if(2&c&&p.class!==m.class&&s(l,"class",null,m.class,o),4&c&&s(l,"style",p.style,m.style,o),8&c){const i=e.dynamicProps;for(let e=0;e<i.length;e++){const a=i[e],u=p[a],c=m[a];c===u&&"value"!==a||s(l,a,u,c,o,t.children,n,r,z)}}1&c&&t.children!==e.children&&h(l,e.children)}else u||null!=f||C(l,e,p,m,n,r,o);((v=m.onVnodeUpdated)||d)&&dr((()=>{v&&pi(v,n,e,t),d&&rr(e,t,n,"updated")}),r)},w=(t,e,n,r,i,o,s)=>{for(let a=0;a<e.length;a++){const u=t[a],l=e[a],c=u.el&&(u.type===Br||!Zr(u,l)||70&u.shapeFlag)?f(u.el):n;g(u,l,c,null,r,i,o,s,!0)}},C=(t,e,n,r,o,a,u)=>{if(n!==r){for(const l in r){if((0,i.Gg)(l))continue;const c=r[l],h=n[l];c!==h&&"value"!==l&&s(t,l,h,c,u,e.children,o,a,z)}if(n!==i.kT)for(const l in n)(0,i.Gg)(l)||l in r||s(t,l,n[l],null,u,e.children,o,a,z);"value"in r&&s(t,"value",n.value,r.value)}},N=(t,e,n,i,o,s,a,l,c)=>{const h=e.el=t?t.el:u(""),f=e.anchor=t?t.anchor:u("");let{patchFlag:d,dynamicChildren:p,slotScopeIds:m}=e;m&&(l=l?l.concat(m):m),null==t?(r(h,n,i),r(f,n,i),O(e.children,n,f,o,s,a,l,c)):d>0&&64&d&&p&&t.dynamicChildren?(w(t.dynamicChildren,p,n,o,s,a,l),(null!=e.key||o&&e===o.subTree)&&_r(t,e,!0)):G(t,e,n,f,o,s,a,l,c)},D=(t,e,n,r,i,o,s,a,u)=>{e.slotScopeIds=a,null==t?512&e.shapeFlag?i.ctx.activate(e,n,r,s,u):L(e,n,r,i,o,s,u):B(t,e,u)},L=(t,e,n,r,i,o,s)=>{const a=t.component=Ai(t,r,i);if(rn(t)&&(a.ctx.renderer=K),Li(a),a.asyncDep){if(i&&i.registerDep(a,F),!t.el){const t=a.subTree=ri(Ur);y(null,t,e,n)}}else F(a,t,e,n,i,o,s)},B=(t,e,n)=>{const r=e.component=t.component;if(Ae(t,e,n)){if(r.asyncDep&&!r.asyncResolved)return void U(r,e,n);r.next=e,So(r.update),r.update()}else e.component=t.component,e.el=t.el,r.vnode=e},F=(t,e,n,r,o,s,a)=>{const u=()=>{if(t.isMounted){let e,{next:n,bu:r,u:u,parent:l,vnode:c}=t,h=n;0,gr(t,!1),n?(n.el=c.el,U(t,n,a)):n=c,r&&(0,i.ir)(r),(e=n.props&&n.props.onVnodeBeforeUpdate)&&pi(e,l,n,c),gr(t,!0);const d=Te(t);0;const p=t.subTree;t.subTree=d,g(p,d,f(p.el),$(p),t,o,s),n.el=d.el,null===h&&Ie(t,d.el),u&&dr(u,o),(e=n.props&&n.props.onVnodeUpdated)&&dr((()=>pi(e,l,n,c)),o)}else{let a;const{el:u,props:l}=e,{bm:c,m:h,parent:f}=t,d=tn(e);if(gr(t,!1),c&&(0,i.ir)(c),!d&&(a=l&&l.onVnodeBeforeMount)&&pi(a,f,e),gr(t,!0),u&&J){const n=()=>{t.subTree=Te(t),J(u,t.subTree,t,o,null)};d?e.type.__asyncLoader().then((()=>!t.isUnmounted&&n())):n()}else{0;const i=t.subTree=Te(t);0,g(null,i,n,r,t,o,s),e.el=i.el}if(h&&dr(h,o),!d&&(a=l&&l.onVnodeMounted)){const t=e;dr((()=>pi(a,f,t)),o)}256&e.shapeFlag&&t.a&&dr(t.a,o),t.isMounted=!0,e=n=r=null}},l=t.effect=new R(u,(()=>To(t.update)),t.scope),c=t.update=l.run.bind(l);c.id=t.uid,gr(t,!0),c()},U=(t,e,n)=>{e.component=t;const r=t.vnode.props;t.vnode=e,t.next=null,Xn(t,e.props,r,n),er(t,e.children,n),P(),Io(void 0,t.update),M()},G=(t,e,n,r,i,o,s,a,u=!1)=>{const l=t&&t.children,c=t?t.shapeFlag:0,f=e.children,{patchFlag:d,shapeFlag:p}=e;if(d>0){if(128&d)return void X(l,f,n,r,i,o,s,a,u);if(256&d)return void k(l,f,n,r,i,o,s,a,u)}8&p?(16&c&&z(l,i,o),f!==l&&h(n,f)):16&c?16&p?X(l,f,n,r,i,o,s,a,u):z(l,i,o,!0):(8&c&&h(n,""),16&p&&O(f,n,r,i,o,s,a,u))},k=(t,e,n,r,o,s,a,u,l)=>{t=t||i.Z6,e=e||i.Z6;const c=t.length,h=e.length,f=Math.min(c,h);let d;for(d=0;d<f;d++){const r=e[d]=l?hi(e[d]):ci(e[d]);g(t[d],r,n,null,o,s,a,u,l)}c>h?z(t,o,s,!0,!1,f):O(e,n,r,o,s,a,u,l,f)},X=(t,e,n,r,o,s,a,u,l)=>{let c=0;const h=e.length;let f=t.length-1,d=h-1;while(c<=f&&c<=d){const r=t[c],i=e[c]=l?hi(e[c]):ci(e[c]);if(!Zr(r,i))break;g(r,i,n,null,o,s,a,u,l),c++}while(c<=f&&c<=d){const r=t[f],i=e[d]=l?hi(e[d]):ci(e[d]);if(!Zr(r,i))break;g(r,i,n,null,o,s,a,u,l),f--,d--}if(c>f){if(c<=d){const t=d+1,i=t<h?e[t].el:r;while(c<=d)g(null,e[c]=l?hi(e[c]):ci(e[c]),n,i,o,s,a,u,l),c++}}else if(c>d)while(c<=f)j(t[c],o,s,!0),c++;else{const p=c,m=c,v=new Map;for(c=m;c<=d;c++){const t=e[c]=l?hi(e[c]):ci(e[c]);null!=t.key&&v.set(t.key,c)}let _,y=0;const b=d-m+1;let E=!1,T=0;const x=new Array(b);for(c=0;c<b;c++)x[c]=0;for(c=p;c<=f;c++){const r=t[c];if(y>=b){j(r,o,s,!0);continue}let i;if(null!=r.key)i=v.get(r.key);else for(_=m;_<=d;_++)if(0===x[_-m]&&Zr(r,e[_])){i=_;break}void 0===i?j(r,o,s,!0):(x[i-m]=c+1,i>=T?T=i:E=!0,g(r,e[i],n,null,o,s,a,u,l),y++)}const S=E?yr(x):i.Z6;for(_=S.length-1,c=b-1;c>=0;c--){const t=m+c,i=e[t],f=t+1<h?e[t+1].el:r;0===x[c]?g(null,i,n,f,o,s,a,u,l):E&&(_<0||c!==S[_]?H(i,n,f,2):_--)}}},H=(t,e,n,i,o=null)=>{const{el:s,type:a,transition:u,children:l,shapeFlag:c}=t;if(6&c)return void H(t.component.subTree,e,n,i);if(128&c)return void t.suspense.move(e,n,i);if(64&c)return void a.move(t,e,n,K);if(a===Br){r(s,e,n);for(let t=0;t<l.length;t++)H(l[t],e,n,i);return void r(t.anchor,e,n)}if(a===Gr)return void E(t,e,n);const h=2!==i&&1&c&&u;if(h)if(0===i)u.beforeEnter(s),r(s,e,n),dr((()=>u.enter(s)),o);else{const{leave:t,delayLeave:i,afterLeave:o}=u,a=()=>r(s,e,n),l=()=>{t(s,(()=>{a(),o&&o()}))};i?i(s,a,l):l()}else r(s,e,n)},j=(t,e,n,r=!1,i=!1)=>{const{type:o,props:s,ref:a,children:u,dynamicChildren:l,shapeFlag:c,patchFlag:h,dirs:f}=t;if(null!=a&&ar(a,null,n,t,!0),256&c)return void e.ctx.deactivate(t);const d=1&c&&f,p=!tn(t);let m;if(p&&(m=s&&s.onVnodeBeforeUnmount)&&pi(m,e,t),6&c)W(t.component,n,r);else{if(128&c)return void t.suspense.unmount(n,r);d&&rr(t,null,e,"beforeUnmount"),64&c?t.type.remove(t,e,n,i,K,r):l&&(o!==Br||h>0&&64&h)?z(l,e,n,!1,!0):(o===Br&&384&h||!i&&16&c)&&z(u,e,n),r&&V(t)}(p&&(m=s&&s.onVnodeUnmounted)||d)&&dr((()=>{m&&pi(m,e,t),d&&rr(t,null,e,"unmounted")}),n)},V=t=>{const{type:e,el:n,anchor:r,transition:i}=t;if(e===Br)return void Y(n,r);if(e===Gr)return void T(t);const s=()=>{o(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(1&t.shapeFlag&&i&&!i.persisted){const{leave:e,delayLeave:r}=i,o=()=>e(n,s);r?r(t.el,s,o):o()}else s()},Y=(t,e)=>{let n;while(t!==e)n=d(t),o(t),t=n;o(e)},W=(t,e,n)=>{const{bum:r,scope:o,update:s,subTree:a,um:u}=t;r&&(0,i.ir)(r),o.stop(),s&&(s.active=!1,j(a,t,e,n)),u&&dr(u,e),dr((()=>{t.isUnmounted=!0}),e),e&&e.pendingBranch&&!e.isUnmounted&&t.asyncDep&&!t.asyncResolved&&t.suspenseId===e.pendingId&&(e.deps--,0===e.deps&&e.resolve())},z=(t,e,n,r=!1,i=!1,o=0)=>{for(let s=o;s<t.length;s++)j(t[s],e,n,r,i)},$=t=>6&t.shapeFlag?$(t.component.subTree):128&t.shapeFlag?t.suspense.next():d(t.anchor||t.el),q=(t,e,n)=>{null==t?e._vnode&&j(e._vnode,null,null,!0):g(e._vnode||null,t,e,null,null,null,n),wo(),e._vnode=t},K={p:g,um:j,m:H,r:V,mt:L,mc:O,pc:G,pbc:w,n:$,o:t};let Z,J;return e&&([Z,J]=e(K)),{render:q,hydrate:Z,createApp:sr(q,Z)}}function gr({effect:t,update:e},n){t.allowRecurse=e.allowRecurse=n}function _r(t,e,n=!1){const r=t.children,o=e.children;if((0,i.kJ)(r)&&(0,i.kJ)(o))for(let i=0;i<r.length;i++){const t=r[i];let e=o[i];1&e.shapeFlag&&!e.dynamicChildren&&((e.patchFlag<=0||32===e.patchFlag)&&(e=o[i]=hi(o[i]),e.el=t.el),n||_r(t,e))}}function yr(t){const e=t.slice(),n=[0];let r,i,o,s,a;const u=t.length;for(r=0;r<u;r++){const u=t[r];if(0!==u){if(i=n[n.length-1],t[i]<u){e[r]=i,n.push(r);continue}o=0,s=n.length-1;while(o<s)a=o+s>>1,t[n[a]]<u?o=a+1:s=a;u<t[n[o]]&&(o>0&&(e[r]=n[o-1]),n[o]=r)}}o=n.length,s=n[o-1];while(o-- >0)n[o]=s,s=e[s];return n}const br=t=>t.__isTeleport,Er=t=>t&&(t.disabled||""===t.disabled),Tr=t=>"undefined"!==typeof SVGElement&&t instanceof SVGElement,xr=(t,e)=>{const n=t&&t.to;if((0,i.HD)(n)){if(e){const t=e(n);return t}return null}return n},Sr={__isTeleport:!0,process(t,e,n,r,i,o,s,a,u,l){const{mc:c,pc:h,pbc:f,o:{insert:d,querySelector:p,createText:m,createComment:v}}=l,g=Er(e.props);let{shapeFlag:_,children:y,dynamicChildren:b}=e;if(null==t){const t=e.el=m(""),l=e.anchor=m("");d(t,n,r),d(l,n,r);const h=e.target=xr(e.props,p),f=e.targetAnchor=m("");h&&(d(f,h),s=s||Tr(h));const v=(t,e)=>{16&_&&c(y,t,e,i,o,s,a,u)};g?v(n,l):h&&v(h,f)}else{e.el=t.el;const r=e.anchor=t.anchor,c=e.target=t.target,d=e.targetAnchor=t.targetAnchor,m=Er(t.props),v=m?n:c,_=m?r:d;if(s=s||Tr(c),b?(f(t.dynamicChildren,b,v,i,o,s,a),_r(t,e,!0)):u||h(t,e,v,_,i,o,s,a,!1),g)m||Rr(e,n,r,l,1);else if((e.props&&e.props.to)!==(t.props&&t.props.to)){const t=e.target=xr(e.props,p);t&&Rr(e,t,null,l,0)}else m&&Rr(e,c,d,l,1)}},remove(t,e,n,r,{um:i,o:{remove:o}},s){const{shapeFlag:a,children:u,anchor:l,targetAnchor:c,target:h,props:f}=t;if(h&&o(c),(s||!Er(f))&&(o(l),16&a))for(let d=0;d<u.length;d++){const t=u[d];i(t,e,n,!0,!!t.dynamicChildren)}},move:Rr,hydrate:Ar};function Rr(t,e,n,{o:{insert:r},m:i},o=2){0===o&&r(t.targetAnchor,e,n);const{el:s,anchor:a,shapeFlag:u,children:l,props:c}=t,h=2===o;if(h&&r(s,e,n),(!h||Er(c))&&16&u)for(let f=0;f<l.length;f++)i(l[f],e,n,2);h&&r(a,e,n)}function Ar(t,e,n,r,i,o,{o:{nextSibling:s,parentNode:a,querySelector:u}},l){const c=e.target=xr(e.props,u);if(c){const u=c._lpa||c.firstChild;16&e.shapeFlag&&(Er(e.props)?(e.anchor=l(s(t),e,a(t),n,r,i,o),e.targetAnchor=u):(e.anchor=s(t),e.targetAnchor=l(u,e,c,n,r,i,o)),c._lpa=e.targetAnchor&&s(e.targetAnchor))}return e.anchor&&s(e.anchor)}const Or=Sr,Ir="components",wr="directives";function Cr(t,e){return Dr(Ir,t,!0,e)||t}const Pr=Symbol();function Nr(t){return(0,i.HD)(t)?Dr(Ir,t,!1)||t:t||Pr}function Mr(t){return Dr(wr,t)}function Dr(t,e,n=!0,r=!1){const o=me||Oi;if(o){const n=o.type;if(t===Ir){const t=Wi(n);if(t&&(t===e||t===(0,i._A)(e)||t===(0,i.kC)((0,i._A)(e))))return n}const s=Lr(o[t]||n[t],e)||Lr(o.appContext[t],e);return!s&&r?n:s}}function Lr(t,e){return t&&(t[e]||t[(0,i._A)(e)]||t[(0,i.kC)((0,i._A)(e))])}const Br=Symbol(void 0),Fr=Symbol(void 0),Ur=Symbol(void 0),Gr=Symbol(void 0),kr=[];let Xr=null;function Hr(t=!1){kr.push(Xr=t?null:[])}function jr(){kr.pop(),Xr=kr[kr.length-1]||null}let Vr,Yr=1;function Wr(t){Yr+=t}function zr(t){return t.dynamicChildren=Yr>0?Xr||i.Z6:null,jr(),Yr>0&&Xr&&Xr.push(t),t}function $r(t,e,n,r,i,o){return zr(ni(t,e,n,r,i,o,!0))}function qr(t,e,n,r,i){return zr(ri(t,e,n,r,i,!0))}function Kr(t){return!!t&&!0===t.__v_isVNode}function Zr(t,e){return t.type===e.type&&t.key===e.key}function Jr(t){Vr=t}const Qr="__vInternal",ti=({key:t})=>null!=t?t:null,ei=({ref:t,ref_key:e,ref_for:n})=>null!=t?(0,i.HD)(t)||Wt(t)||(0,i.mf)(t)?{i:me,r:t,k:e,f:!!n}:t:null;function ni(t,e=null,n=null,r=0,o=null,s=(t===Br?0:1),a=!1,u=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&ti(e),ref:e&&ei(e),scopeId:ve,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:r,dynamicProps:o,dynamicChildren:null,appContext:null};return u?(fi(l,n),128&s&&t.normalize(l)):n&&(l.shapeFlag|=(0,i.HD)(n)?8:16),Yr>0&&!a&&Xr&&(l.patchFlag>0||6&s)&&32!==l.patchFlag&&Xr.push(l),l}const ri=ii;function ii(t,e=null,n=null,r=0,o=null,s=!1){if(t&&t!==Pr||(t=Ur),Kr(t)){const r=si(t,e,!0);return n&&fi(r,n),r}if($i(t)&&(t=t.__vccOpts),e){e=oi(e);let{class:t,style:n}=e;t&&!(0,i.HD)(t)&&(e.class=(0,i.C_)(t)),(0,i.Kn)(n)&&(Gt(n)&&!(0,i.kJ)(n)&&(n=(0,i.l7)({},n)),e.style=(0,i.j5)(n))}const a=(0,i.HD)(t)?1:we(t)?128:br(t)?64:(0,i.Kn)(t)?4:(0,i.mf)(t)?2:0;return ni(t,e,n,r,o,a,s,!0)}function oi(t){return t?Gt(t)||Qr in t?(0,i.l7)({},t):t:null}function si(t,e,n=!1){const{props:r,ref:o,patchFlag:s,children:a}=t,u=e?di(r||{},e):r,l={__v_isVNode:!0,__v_skip:!0,type:t.type,props:u,key:u&&ti(u),ref:e&&e.ref?n&&o?(0,i.kJ)(o)?o.concat(ei(e)):[o,ei(e)]:ei(e):o,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:a,target:t.target,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==Br?-1===s?16:16|s:s,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:t.transition,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&si(t.ssContent),ssFallback:t.ssFallback&&si(t.ssFallback),el:t.el,anchor:t.anchor};return l}function ai(t=" ",e=0){return ri(Fr,null,t,e)}function ui(t,e){const n=ri(Gr,null,t);return n.staticCount=e,n}function li(t="",e=!1){return e?(Hr(),qr(Ur,null,t)):ri(Ur,null,t)}function ci(t){return null==t||"boolean"===typeof t?ri(Ur):(0,i.kJ)(t)?ri(Br,null,t.slice()):"object"===typeof t?hi(t):ri(Fr,null,String(t))}function hi(t){return null===t.el||t.memo?t:si(t)}function fi(t,e){let n=0;const{shapeFlag:r}=t;if(null==e)e=null;else if((0,i.kJ)(e))n=16;else if("object"===typeof e){if(65&r){const n=e.default;return void(n&&(n._c&&(n._d=!1),fi(t,n()),n._c&&(n._d=!0)))}{n=32;const r=e._;r||Qr in e?3===r&&me&&(1===me.slots._?e._=1:(e._=2,t.patchFlag|=1024)):e._ctx=me}}else(0,i.mf)(e)?(e={default:e,_ctx:me},n=32):(e=String(e),64&r?(n=16,e=[ai(e)]):n=8);t.children=e,t.shapeFlag|=n}function di(...t){const e={};for(let n=0;n<t.length;n++){const r=t[n];for(const t in r)if("class"===t)e.class!==r.class&&(e.class=(0,i.C_)([e.class,r.class]));else if("style"===t)e.style=(0,i.j5)([e.style,r.style]);else if((0,i.F7)(t)){const n=e[t],o=r[t];n===o||(0,i.kJ)(n)&&n.includes(o)||(e[t]=n?[].concat(n,o):o)}else""!==t&&(e[t]=r[t])}return e}function pi(t,e,n,r=null){ro(t,e,7,[n,r])}function mi(t,e,n,r){let o;const s=n&&n[r];if((0,i.kJ)(t)||(0,i.HD)(t)){o=new Array(t.length);for(let n=0,r=t.length;n<r;n++)o[n]=e(t[n],n,void 0,s&&s[n])}else if("number"===typeof t){0,o=new Array(t);for(let n=0;n<t;n++)o[n]=e(n+1,n,void 0,s&&s[n])}else if((0,i.Kn)(t))if(t[Symbol.iterator])o=Array.from(t,((t,n)=>e(t,n,void 0,s&&s[n])));else{const n=Object.keys(t);o=new Array(n.length);for(let r=0,i=n.length;r<i;r++){const i=n[r];o[r]=e(t[i],i,r,s&&s[r])}}else o=[];return n&&(n[r]=o),o}function vi(t,e){for(let n=0;n<e.length;n++){const r=e[n];if((0,i.kJ)(r))for(let e=0;e<r.length;e++)t[r[e].name]=r[e].fn;else r&&(t[r.name]=r.fn)}return t}function gi(t,e,n={},r,i){if(me.isCE)return ri("slot","default"===e?null:{name:e},r&&r());let o=t[e];o&&o._c&&(o._d=!1),Hr();const s=o&&_i(o(n)),a=qr(Br,{key:n.key||`_${e}`},s||(r?r():[]),s&&1===t._?64:-2);return!i&&a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),o&&o._c&&(o._d=!0),a}function _i(t){return t.some((t=>!Kr(t)||t.type!==Ur&&!(t.type===Br&&!_i(t.children))))?t:null}function yi(t){const e={};for(const n in t)e[(0,i.hR)(n)]=t[n];return e}const bi=t=>t?Pi(t)?ji(t)||t.proxy:bi(t.parent):null,Ei=(0,i.l7)(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>bi(t.parent),$root:t=>bi(t.root),$emit:t=>t.emit,$options:t=>Pn(t),$forceUpdate:t=>()=>To(t.update),$nextTick:t=>bo.bind(t.proxy),$watch:t=>Uo.bind(t)}),Ti={get({_:t},e){const{ctx:n,setupState:r,data:o,props:s,accessCache:a,type:u,appContext:l}=t;let c;if("$"!==e[0]){const u=a[e];if(void 0!==u)switch(u){case 1:return r[e];case 2:return o[e];case 4:return n[e];case 3:return s[e]}else{if(r!==i.kT&&(0,i.RI)(r,e))return a[e]=1,r[e];if(o!==i.kT&&(0,i.RI)(o,e))return a[e]=2,o[e];if((c=t.propsOptions[0])&&(0,i.RI)(c,e))return a[e]=3,s[e];if(n!==i.kT&&(0,i.RI)(n,e))return a[e]=4,n[e];An&&(a[e]=0)}}const h=Ei[e];let f,d;return h?("$attrs"===e&&D(t,"get",e),h(t)):(f=u.__cssModules)&&(f=f[e])?f:n!==i.kT&&(0,i.RI)(n,e)?(a[e]=4,n[e]):(d=l.config.globalProperties,(0,i.RI)(d,e)?d[e]:void 0)},set({_:t},e,n){const{data:r,setupState:o,ctx:s}=t;if(o!==i.kT&&(0,i.RI)(o,e))o[e]=n;else if(r!==i.kT&&(0,i.RI)(r,e))r[e]=n;else if((0,i.RI)(t.props,e))return!1;return("$"!==e[0]||!(e.slice(1)in t))&&(s[e]=n,!0)},has({_:{data:t,setupState:e,accessCache:n,ctx:r,appContext:o,propsOptions:s}},a){let u;return!!n[a]||t!==i.kT&&(0,i.RI)(t,a)||e!==i.kT&&(0,i.RI)(e,a)||(u=s[0])&&(0,i.RI)(u,a)||(0,i.RI)(r,a)||(0,i.RI)(Ei,a)||(0,i.RI)(o.config.globalProperties,a)}};const xi=(0,i.l7)({},Ti,{get(t,e){if(e!==Symbol.unscopables)return Ti.get(t,e,t)},has(t,e){const n="_"!==e[0]&&!(0,i.e1)(e);return n}});const Si=ir();let Ri=0;function Ai(t,e,n){const r=t.type,o=(e?e.appContext:t.appContext)||Si,s={uid:Ri++,vnode:t,type:r,parent:e,appContext:o,root:null,next:null,subTree:null,effect:null,update:null,scope:new a(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:e?e.provides:Object.create(o.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Vn(r,o),emitsOptions:de(r,o),emit:null,emitted:null,propsDefaults:i.kT,inheritAttrs:r.inheritAttrs,ctx:i.kT,data:i.kT,props:i.kT,attrs:i.kT,slots:i.kT,refs:i.kT,setupState:i.kT,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return s.ctx={_:s},s.root=e?e.root:s,s.emit=fe.bind(null,s),t.ce&&t.ce(s),s}let Oi=null;const Ii=()=>Oi||me,wi=t=>{Oi=t,t.scope.on()},Ci=()=>{Oi&&Oi.scope.off(),Oi=null};function Pi(t){return 4&t.vnode.shapeFlag}let Ni,Mi,Di=!1;function Li(t,e=!1){Di=e;const{props:n,children:r}=t.vnode,i=Pi(t);kn(t,n,i,e),tr(t,r);const o=i?Bi(t,e):void 0;return Di=!1,o}function Bi(t,e){const n=t.type;t.accessCache=Object.create(null),t.proxy=Xt(new Proxy(t.ctx,Ti));const{setup:r}=n;if(r){const n=t.setupContext=r.length>1?Hi(t):null;wi(t),P();const o=no(r,t,0,[t.props,n]);if(M(),Ci(),(0,i.tI)(o)){if(o.then(Ci,Ci),e)return o.then((n=>{Fi(t,n,e)})).catch((e=>{io(e,t,0)}));t.asyncDep=o}else Fi(t,o,e)}else ki(t,e)}function Fi(t,e,n){(0,i.mf)(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:(0,i.Kn)(e)&&(t.setupState=te(e)),ki(t,n)}function Ui(t){Ni=t,Mi=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,xi))}}const Gi=()=>!Ni;function ki(t,e,n){const r=t.type;if(!t.render){if(!e&&Ni&&!r.render){const e=r.template;if(e){0;const{isCustomElement:n,compilerOptions:o}=t.appContext.config,{delimiters:s,compilerOptions:a}=r,u=(0,i.l7)((0,i.l7)({isCustomElement:n,delimiters:s},o),a);r.render=Ni(e,u)}}t.render=r.render||i.dG,Mi&&Mi(t)}wi(t),P(),On(t),M(),Ci()}function Xi(t){return new Proxy(t.attrs,{get(e,n){return D(t,"get","$attrs"),e[n]}})}function Hi(t){const e=e=>{t.exposed=e||{}};let n;return{get attrs(){return n||(n=Xi(t))},slots:t.slots,emit:t.emit,expose:e}}function ji(t){if(t.exposed)return t.exposeProxy||(t.exposeProxy=new Proxy(te(Xt(t.exposed)),{get(e,n){return n in e?e[n]:n in Ei?Ei[n](t):void 0}}))}const Vi=/(?:^|[-_])(\w)/g,Yi=t=>t.replace(Vi,(t=>t.toUpperCase())).replace(/[-_]/g,"");function Wi(t){return(0,i.mf)(t)&&t.displayName||t.name}function zi(t,e,n=!1){let r=Wi(e);if(!r&&e.__file){const t=e.__file.match(/([^/\\]+)\.\w+$/);t&&(r=t[1])}if(!r&&t&&t.parent){const n=t=>{for(const n in t)if(t[n]===e)return n};r=n(t.components||t.parent.type.components)||n(t.appContext.components)}return r?Yi(r):n?"App":"Anonymous"}function $i(t){return(0,i.mf)(t)&&"__vccOpts"in t}const qi=[];function Ki(t,...e){P();const n=qi.length?qi[qi.length-1].component:null,r=n&&n.appContext.config.warnHandler,i=Zi();if(r)no(r,n,11,[t+e.join(""),n&&n.proxy,i.map((({vnode:t})=>`at <${zi(n,t.type)}>`)).join("\n"),i]);else{const n=[`[Vue warn]: ${t}`,...e];i.length&&n.push("\n",...Ji(i)),console.warn(...n)}M()}function Zi(){let t=qi[qi.length-1];if(!t)return[];const e=[];while(t){const n=e[0];n&&n.vnode===t?n.recurseCount++:e.push({vnode:t,recurseCount:0});const r=t.component&&t.component.parent;t=r&&r.vnode}return e}function Ji(t){const e=[];return t.forEach(((t,n)=>{e.push(...0===n?[]:["\n"],...Qi(t))})),e}function Qi({vnode:t,recurseCount:e}){const n=e>0?`... (${e} recursive calls)`:"",r=!!t.component&&null==t.component.parent,i=` at <${zi(t.component,t.type,r)}`,o=">"+n;return t.props?[i,...to(t.props),o]:[i+o]}function to(t){const e=[],n=Object.keys(t);return n.slice(0,3).forEach((n=>{e.push(...eo(n,t[n]))})),n.length>3&&e.push(" ..."),e}function eo(t,e,n){return(0,i.HD)(e)?(e=JSON.stringify(e),n?e:[`${t}=${e}`]):"number"===typeof e||"boolean"===typeof e||null==e?n?e:[`${t}=${e}`]:Wt(e)?(e=eo(t,kt(e.value),!0),n?e:[`${t}=Ref<`,e,">"]):(0,i.mf)(e)?[`${t}=fn${e.name?`<${e.name}>`:""}`]:(e=kt(e),n?e:[`${t}=`,e])}function no(t,e,n,r){let i;try{i=r?t(...r):t()}catch(o){io(o,e,n)}return i}function ro(t,e,n,r){if((0,i.mf)(t)){const o=no(t,e,n,r);return o&&(0,i.tI)(o)&&o.catch((t=>{io(t,e,n)})),o}const o=[];for(let i=0;i<t.length;i++)o.push(ro(t[i],e,n,r));return o}function io(t,e,n,r=!0){const i=e?e.vnode:null;if(e){let r=e.parent;const i=e.proxy,o=n;while(r){const e=r.ec;if(e)for(let n=0;n<e.length;n++)if(!1===e[n](t,i,o))return;r=r.parent}const s=e.appContext.config.errorHandler;if(s)return void no(s,null,10,[t,i,o])}oo(t,n,i,r)}function oo(t,e,n,r=!0){console.error(t)}let so=!1,ao=!1;const uo=[];let lo=0;const co=[];let ho=null,fo=0;const po=[];let mo=null,vo=0;const go=Promise.resolve();let _o=null,yo=null;function bo(t){const e=_o||go;return t?e.then(this?t.bind(this):t):e}function Eo(t){let e=lo+1,n=uo.length;while(e<n){const r=e+n>>>1,i=Co(uo[r]);i<t?e=r+1:n=r}return e}function To(t){uo.length&&uo.includes(t,so&&t.allowRecurse?lo+1:lo)||t===yo||(null==t.id?uo.push(t):uo.splice(Eo(t.id),0,t),xo())}function xo(){so||ao||(ao=!0,_o=go.then(Po))}function So(t){const e=uo.indexOf(t);e>lo&&uo.splice(e,1)}function Ro(t,e,n,r){(0,i.kJ)(t)?n.push(...t):e&&e.includes(t,t.allowRecurse?r+1:r)||n.push(t),xo()}function Ao(t){Ro(t,ho,co,fo)}function Oo(t){Ro(t,mo,po,vo)}function Io(t,e=null){if(co.length){for(yo=e,ho=[...new Set(co)],co.length=0,fo=0;fo<ho.length;fo++)ho[fo]();ho=null,fo=0,yo=null,Io(t,e)}}function wo(t){if(po.length){const t=[...new Set(po)];if(po.length=0,mo)return void mo.push(...t);for(mo=t,mo.sort(((t,e)=>Co(t)-Co(e))),vo=0;vo<mo.length;vo++)mo[vo]();mo=null,vo=0}}const Co=t=>null==t.id?1/0:t.id;function Po(t){ao=!1,so=!0,Io(t),uo.sort(((t,e)=>Co(t)-Co(e)));i.dG;try{for(lo=0;lo<uo.length;lo++){const t=uo[lo];t&&!1!==t.active&&no(t,null,14)}}finally{lo=0,uo.length=0,wo(t),so=!1,_o=null,(uo.length||co.length||po.length)&&Po(t)}}function No(t,e){return Fo(t,null,e)}function Mo(t,e){return Fo(t,null,{flush:"post"})}function Do(t,e){return Fo(t,null,{flush:"sync"})}const Lo={};function Bo(t,e,n){return Fo(t,e,n)}function Fo(t,e,{immediate:n,deep:r,flush:o,onTrack:s,onTrigger:a}=i.kT){const u=Oi;let l,c,h=!1,f=!1;if(Wt(t)?(l=()=>t.value,h=!!t._shallow):Ft(t)?(l=()=>t,r=!0):(0,i.kJ)(t)?(f=!0,h=t.some(Ft),l=()=>t.map((t=>Wt(t)?t.value:Ft(t)?ko(t):(0,i.mf)(t)?no(t,u,2):void 0))):l=(0,i.mf)(t)?e?()=>no(t,u,2):()=>{if(!u||!u.isUnmounted)return c&&c(),ro(t,u,3,[d])}:i.dG,e&&r){const t=l;l=()=>ko(t())}let d=t=>{c=g.onStop=()=>{no(t,u,4)}};if(Di)return d=i.dG,e?n&&ro(e,u,3,[l(),f?[]:void 0,d]):l(),i.dG;let p=f?[]:Lo;const m=()=>{if(g.active)if(e){const t=g.run();(r||h||(f?t.some(((t,e)=>(0,i.aU)(t,p[e]))):(0,i.aU)(t,p)))&&(c&&c(),ro(e,u,3,[t,p===Lo?void 0:p,d]),p=t)}else g.run()};let v;m.allowRecurse=!!e,v="sync"===o?m:"post"===o?()=>dr(m,u&&u.suspense):()=>{!u||u.isMounted?Ao(m):m()};const g=new R(l,v);return e?n?m():p=g.run():"post"===o?dr(g.run.bind(g),u&&u.suspense):g.run(),()=>{g.stop(),u&&u.scope&&(0,i.Od)(u.scope.effects,g)}}function Uo(t,e,n){const r=this.proxy,o=(0,i.HD)(t)?t.includes(".")?Go(r,t):()=>r[t]:t.bind(r,r);let s;(0,i.mf)(e)?s=e:(s=e.handler,n=e);const a=Oi;wi(this);const u=Fo(o,s.bind(r),n);return a?wi(a):Ci(),u}function Go(t,e){const n=e.split(".");return()=>{let e=t;for(let t=0;t<n.length&&e;t++)e=e[n[t]];return e}}function ko(t,e){if(!(0,i.Kn)(t)||t["__v_skip"])return t;if(e=e||new Set,e.has(t))return t;if(e.add(t),Wt(t))ko(t.value,e);else if((0,i.kJ)(t))for(let n=0;n<t.length;n++)ko(t[n],e);else if((0,i.DM)(t)||(0,i._N)(t))t.forEach((t=>{ko(t,e)}));else if((0,i.PO)(t))for(const n in t)ko(t[n],e);return t}function Xo(){return null}function Ho(){return null}function jo(t){0}function Vo(t,e){return null}function Yo(){return zo().slots}function Wo(){return zo().attrs}function zo(){const t=Ii();return t.setupContext||(t.setupContext=Hi(t))}function $o(t,e){const n=(0,i.kJ)(t)?t.reduce(((t,e)=>(t[e]={},t)),{}):t;for(const r in e){const t=n[r];t?(0,i.kJ)(t)||(0,i.mf)(t)?n[r]={type:t,default:e[r]}:t.default=e[r]:null===t&&(n[r]={default:e[r]})}return n}function qo(t,e){const n={};for(const r in t)e.includes(r)||Object.defineProperty(n,r,{enumerable:!0,get:()=>t[r]});return n}function Ko(t){const e=Ii();let n=t();return Ci(),(0,i.tI)(n)&&(n=n.catch((t=>{throw wi(e),t}))),[n,()=>wi(e)]}function Zo(t,e,n){const r=arguments.length;return 2===r?(0,i.Kn)(e)&&!(0,i.kJ)(e)?Kr(e)?ri(t,null,[e]):ri(t,e):ri(t,null,e):(r>3?n=Array.prototype.slice.call(arguments,2):3===r&&Kr(n)&&(n=[n]),ri(t,e,n))}const Jo=Symbol(""),Qo=()=>{{const t=He(Jo);return t||Ki("Server rendering context not provided. Make sure to only call useSSRContext() conditionally in the server build."),t}};function ts(){return void 0}function es(t,e,n,r){const i=n[r];if(i&&ns(i,t))return i;const o=e();return o.memo=t.slice(),n[r]=o}function ns(t,e){const n=t.memo;if(n.length!=e.length)return!1;for(let r=0;r<n.length;r++)if(n[r]!==e[r])return!1;return Yr>0&&Xr&&Xr.push(t),!0}const rs="3.2.26",is={createComponentInstance:Ai,setupComponent:Li,renderComponentRoot:Te,setCurrentRenderingInstance:ge,isVNode:Kr,normalizeVNode:ci},os=is,ss=null,as=null,us="http://www.w3.org/2000/svg",ls="undefined"!==typeof document?document:null,cs=new Map,hs={insert:(t,e,n)=>{e.insertBefore(t,n||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,n,r)=>{const i=e?ls.createElementNS(us,t):ls.createElement(t,n?{is:n}:void 0);return"select"===t&&r&&null!=r.multiple&&i.setAttribute("multiple",r.multiple),i},createText:t=>ls.createTextNode(t),createComment:t=>ls.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>ls.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},cloneNode(t){const e=t.cloneNode(!0);return"_value"in t&&(e._value=t._value),e},insertStaticContent(t,e,n,r){const i=n?n.previousSibling:e.lastChild;let o=cs.get(t);if(!o){const e=ls.createElement("template");if(e.innerHTML=r?`<svg>${t}</svg>`:t,o=e.content,r){const t=o.firstChild;while(t.firstChild)o.appendChild(t.firstChild);o.removeChild(t)}cs.set(t,o)}return e.insertBefore(o.cloneNode(!0),n),[i?i.nextSibling:e.firstChild,n?n.previousSibling:e.lastChild]}};function fs(t,e,n){const r=t._vtc;r&&(e=(e?[e,...r]:[...r]).join(" ")),null==e?t.removeAttribute("class"):n?t.setAttribute("class",e):t.className=e}function ds(t,e,n){const r=t.style,o=(0,i.HD)(n);if(n&&!o){for(const t in n)ms(r,t,n[t]);if(e&&!(0,i.HD)(e))for(const t in e)null==n[t]&&ms(r,t,"")}else{const i=r.display;o?e!==n&&(r.cssText=n):e&&t.removeAttribute("style"),"_vod"in t&&(r.display=i)}}const ps=/\s*!important$/;function ms(t,e,n){if((0,i.kJ)(n))n.forEach((n=>ms(t,e,n)));else if(e.startsWith("--"))t.setProperty(e,n);else{const r=_s(t,e);ps.test(n)?t.setProperty((0,i.rs)(r),n.replace(ps,""),"important"):t[r]=n}}const vs=["Webkit","Moz","ms"],gs={};function _s(t,e){const n=gs[e];if(n)return n;let r=(0,i._A)(e);if("filter"!==r&&r in t)return gs[e]=r;r=(0,i.kC)(r);for(let i=0;i<vs.length;i++){const n=vs[i]+r;if(n in t)return gs[e]=n}return e}const ys="http://www.w3.org/1999/xlink";function bs(t,e,n,r,o){if(r&&e.startsWith("xlink:"))null==n?t.removeAttributeNS(ys,e.slice(6,e.length)):t.setAttributeNS(ys,e,n);else{const r=(0,i.Pq)(e);null==n||r&&!(0,i.yA)(n)?t.removeAttribute(e):t.setAttribute(e,r?"":n)}}function Es(t,e,n,r,o,s,a){if("innerHTML"===e||"textContent"===e)return r&&a(r,o,s),void(t[e]=null==n?"":n);if("value"===e&&"PROGRESS"!==t.tagName&&!t.tagName.includes("-")){t._value=n;const r=null==n?"":n;return t.value===r&&"OPTION"!==t.tagName||(t.value=r),void(null==n&&t.removeAttribute(e))}if(""===n||null==n){const r=typeof t[e];if("boolean"===r)return void(t[e]=(0,i.yA)(n));if(null==n&&"string"===r)return t[e]="",void t.removeAttribute(e);if("number"===r){try{t[e]=0}catch(u){}return void t.removeAttribute(e)}}try{t[e]=n}catch(l){0}}let Ts=Date.now,xs=!1;if("undefined"!==typeof window){Ts()>document.createEvent("Event").timeStamp&&(Ts=()=>performance.now());const t=navigator.userAgent.match(/firefox\/(\d+)/i);xs=!!(t&&Number(t[1])<=53)}let Ss=0;const Rs=Promise.resolve(),As=()=>{Ss=0},Os=()=>Ss||(Rs.then(As),Ss=Ts());function Is(t,e,n,r){t.addEventListener(e,n,r)}function ws(t,e,n,r){t.removeEventListener(e,n,r)}function Cs(t,e,n,r,i=null){const o=t._vei||(t._vei={}),s=o[e];if(r&&s)s.value=r;else{const[n,a]=Ns(e);if(r){const s=o[e]=Ms(r,i);Is(t,n,s,a)}else s&&(ws(t,n,s,a),o[e]=void 0)}}const Ps=/(?:Once|Passive|Capture)$/;function Ns(t){let e;if(Ps.test(t)){let n;e={};while(n=t.match(Ps))t=t.slice(0,t.length-n[0].length),e[n[0].toLowerCase()]=!0}return[(0,i.rs)(t.slice(2)),e]}function Ms(t,e){const n=t=>{const r=t.timeStamp||Ts();(xs||r>=n.attached-1)&&ro(Ds(t,n.value),e,5,[t])};return n.value=t,n.attached=Os(),n}function Ds(t,e){if((0,i.kJ)(e)){const n=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{n.call(t),t._stopped=!0},e.map((t=>e=>!e._stopped&&t(e)))}return e}const Ls=/^on[a-z]/,Bs=(t,e,n,r,o=!1,s,a,u,l)=>{"class"===e?fs(t,r,o):"style"===e?ds(t,n,r):(0,i.F7)(e)?(0,i.tR)(e)||Cs(t,e,n,r,a):("."===e[0]?(e=e.slice(1),1):"^"===e[0]?(e=e.slice(1),0):Fs(t,e,r,o))?Es(t,e,r,s,a,u,l):("true-value"===e?t._trueValue=r:"false-value"===e&&(t._falseValue=r),bs(t,e,r,o))};function Fs(t,e,n,r){return r?"innerHTML"===e||"textContent"===e||!!(e in t&&Ls.test(e)&&(0,i.mf)(n)):"spellcheck"!==e&&"draggable"!==e&&("form"!==e&&(("list"!==e||"INPUT"!==t.tagName)&&(("type"!==e||"TEXTAREA"!==t.tagName)&&((!Ls.test(e)||!(0,i.HD)(n))&&e in t))))}function Us(t,e){const n=Qe(t);class r extends Xs{constructor(t){super(n,t,e)}}return r.def=n,r}const Gs=t=>Us(t,$a),ks="undefined"!==typeof HTMLElement?HTMLElement:class{};class Xs extends ks{constructor(t,e={},n){super(),this._def=t,this._props=e,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this.shadowRoot&&n?n(this._createVNode(),this.shadowRoot):this.attachShadow({mode:"open"})}connectedCallback(){this._connected=!0,this._instance||this._resolveDef()}disconnectedCallback(){this._connected=!1,bo((()=>{this._connected||(za(null,this.shadowRoot),this._instance=null)}))}_resolveDef(){if(this._resolved)return;this._resolved=!0;for(let n=0;n<this.attributes.length;n++)this._setAttr(this.attributes[n].name);new MutationObserver((t=>{for(const e of t)this._setAttr(e.attributeName)})).observe(this,{attributes:!0});const t=t=>{const{props:e,styles:n}=t,r=!(0,i.kJ)(e),o=e?r?Object.keys(e):e:[];let s;if(r)for(const a in this._props){const t=e[a];(t===Number||t&&t.type===Number)&&(this._props[a]=(0,i.He)(this._props[a]),(s||(s=Object.create(null)))[a]=!0)}this._numberProps=s;for(const i of Object.keys(this))"_"!==i[0]&&this._setProp(i,this[i],!0,!1);for(const a of o.map(i._A))Object.defineProperty(this,a,{get(){return this._getProp(a)},set(t){this._setProp(a,t)}});this._applyStyles(n),this._update()},e=this._def.__asyncLoader;e?e().then(t):t(this._def)}_setAttr(t){let e=this.getAttribute(t);this._numberProps&&this._numberProps[t]&&(e=(0,i.He)(e)),this._setProp((0,i._A)(t),e,!1)}_getProp(t){return this._props[t]}_setProp(t,e,n=!0,r=!0){e!==this._props[t]&&(this._props[t]=e,r&&this._instance&&this._update(),n&&(!0===e?this.setAttribute((0,i.rs)(t),""):"string"===typeof e||"number"===typeof e?this.setAttribute((0,i.rs)(t),e+""):e||this.removeAttribute((0,i.rs)(t))))}_update(){za(this._createVNode(),this.shadowRoot)}_createVNode(){const t=ri(this._def,(0,i.l7)({},this._props));return this._instance||(t.ce=t=>{this._instance=t,t.isCE=!0,t.emit=(t,...e)=>{this.dispatchEvent(new CustomEvent(t,{detail:e}))};let e=this;while(e=e&&(e.parentNode||e.host))if(e instanceof Xs){t.parent=e._instance;break}}),t}_applyStyles(t){t&&t.forEach((t=>{const e=document.createElement("style");e.textContent=t,this.shadowRoot.appendChild(e)}))}}function Hs(t="$style"){{const e=Ii();if(!e)return i.kT;const n=e.type.__cssModules;if(!n)return i.kT;const r=n[t];return r||i.kT}}function js(t){const e=Ii();if(!e)return;const n=()=>Vs(e.subTree,t(e.proxy));Mo(n),gn((()=>{const t=new MutationObserver(n);t.observe(e.subTree.el.parentNode,{childList:!0}),En((()=>t.disconnect()))}))}function Vs(t,e){if(128&t.shapeFlag){const n=t.suspense;t=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{Vs(n.activeBranch,e)}))}while(t.component)t=t.component.subTree;if(1&t.shapeFlag&&t.el)Ys(t.el,e);else if(t.type===Br)t.children.forEach((t=>Vs(t,e)));else if(t.type===Gr){let{el:n,anchor:r}=t;while(n){if(Ys(n,e),n===r)break;n=n.nextSibling}}}function Ys(t,e){if(1===t.nodeType){const n=t.style;for(const t in e)n.setProperty(`--${t}`,e[t])}}const Ws="transition",zs="animation",$s=(t,{slots:e})=>Zo(We,Qs(t),e);$s.displayName="Transition";const qs={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Ks=$s.props=(0,i.l7)({},We.props,qs),Zs=(t,e=[])=>{(0,i.kJ)(t)?t.forEach((t=>t(...e))):t&&t(...e)},Js=t=>!!t&&((0,i.kJ)(t)?t.some((t=>t.length>1)):t.length>1);function Qs(t){const e={};for(const i in t)i in qs||(e[i]=t[i]);if(!1===t.css)return e;const{name:n="v",type:r,duration:o,enterFromClass:s=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:u=`${n}-enter-to`,appearFromClass:l=s,appearActiveClass:c=a,appearToClass:h=u,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:d=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=t,m=ta(o),v=m&&m[0],g=m&&m[1],{onBeforeEnter:_,onEnter:y,onEnterCancelled:b,onLeave:E,onLeaveCancelled:T,onBeforeAppear:x=_,onAppear:S=y,onAppearCancelled:R=b}=e,A=(t,e,n)=>{ra(t,e?h:u),ra(t,e?c:a),n&&n()},O=(t,e)=>{ra(t,p),ra(t,d),e&&e()},I=t=>(e,n)=>{const i=t?S:y,o=()=>A(e,t,n);Zs(i,[e,o]),ia((()=>{ra(e,t?l:s),na(e,t?h:u),Js(i)||sa(e,r,v,o)}))};return(0,i.l7)(e,{onBeforeEnter(t){Zs(_,[t]),na(t,s),na(t,a)},onBeforeAppear(t){Zs(x,[t]),na(t,l),na(t,c)},onEnter:I(!1),onAppear:I(!0),onLeave(t,e){const n=()=>O(t,e);na(t,f),ca(),na(t,d),ia((()=>{ra(t,f),na(t,p),Js(E)||sa(t,r,g,n)})),Zs(E,[t,n])},onEnterCancelled(t){A(t,!1),Zs(b,[t])},onAppearCancelled(t){A(t,!0),Zs(R,[t])},onLeaveCancelled(t){O(t),Zs(T,[t])}})}function ta(t){if(null==t)return null;if((0,i.Kn)(t))return[ea(t.enter),ea(t.leave)];{const e=ea(t);return[e,e]}}function ea(t){const e=(0,i.He)(t);return e}function na(t,e){e.split(/\s+/).forEach((e=>e&&t.classList.add(e))),(t._vtc||(t._vtc=new Set)).add(e)}function ra(t,e){e.split(/\s+/).forEach((e=>e&&t.classList.remove(e)));const{_vtc:n}=t;n&&(n.delete(e),n.size||(t._vtc=void 0))}function ia(t){requestAnimationFrame((()=>{requestAnimationFrame(t)}))}let oa=0;function sa(t,e,n,r){const i=t._endId=++oa,o=()=>{i===t._endId&&r()};if(n)return setTimeout(o,n);const{type:s,timeout:a,propCount:u}=aa(t,e);if(!s)return r();const l=s+"end";let c=0;const h=()=>{t.removeEventListener(l,f),o()},f=e=>{e.target===t&&++c>=u&&h()};setTimeout((()=>{c<u&&h()}),a+1),t.addEventListener(l,f)}function aa(t,e){const n=window.getComputedStyle(t),r=t=>(n[t]||"").split(", "),i=r(Ws+"Delay"),o=r(Ws+"Duration"),s=ua(i,o),a=r(zs+"Delay"),u=r(zs+"Duration"),l=ua(a,u);let c=null,h=0,f=0;e===Ws?s>0&&(c=Ws,h=s,f=o.length):e===zs?l>0&&(c=zs,h=l,f=u.length):(h=Math.max(s,l),c=h>0?s>l?Ws:zs:null,f=c?c===Ws?o.length:u.length:0);const d=c===Ws&&/\b(transform|all)(,|$)/.test(n[Ws+"Property"]);return{type:c,timeout:h,propCount:f,hasTransform:d}}function ua(t,e){while(t.length<e.length)t=t.concat(t);return Math.max(...e.map(((e,n)=>la(e)+la(t[n]))))}function la(t){return 1e3*Number(t.slice(0,-1).replace(",","."))}function ca(){return document.body.offsetHeight}const ha=new WeakMap,fa=new WeakMap,da={name:"TransitionGroup",props:(0,i.l7)({},Ks,{tag:String,moveClass:String}),setup(t,{slots:e}){const n=Ii(),r=je();let i,o;return yn((()=>{if(!i.length)return;const e=t.moveClass||`${t.name||"v"}-move`;if(!_a(i[0].el,n.vnode.el,e))return;i.forEach(ma),i.forEach(va);const r=i.filter(ga);ca(),r.forEach((t=>{const n=t.el,r=n.style;na(n,e),r.transform=r.webkitTransform=r.transitionDuration="";const i=n._moveCb=t=>{t&&t.target!==n||t&&!/transform$/.test(t.propertyName)||(n.removeEventListener("transitionend",i),n._moveCb=null,ra(n,e))};n.addEventListener("transitionend",i)}))})),()=>{const s=kt(t),a=Qs(s);let u=s.tag||Br;i=o,o=e.default?Je(e.default()):[];for(let t=0;t<o.length;t++){const e=o[t];null!=e.key&&Ze(e,$e(e,a,r,n))}if(i)for(let t=0;t<i.length;t++){const e=i[t];Ze(e,$e(e,a,r,n)),ha.set(e,e.el.getBoundingClientRect())}return ri(u,null,o)}}},pa=da;function ma(t){const e=t.el;e._moveCb&&e._moveCb(),e._enterCb&&e._enterCb()}function va(t){fa.set(t,t.el.getBoundingClientRect())}function ga(t){const e=ha.get(t),n=fa.get(t),r=e.left-n.left,i=e.top-n.top;if(r||i){const e=t.el.style;return e.transform=e.webkitTransform=`translate(${r}px,${i}px)`,e.transitionDuration="0s",t}}function _a(t,e,n){const r=t.cloneNode();t._vtc&&t._vtc.forEach((t=>{t.split(/\s+/).forEach((t=>t&&r.classList.remove(t)))})),n.split(/\s+/).forEach((t=>t&&r.classList.add(t))),r.style.display="none";const i=1===e.nodeType?e:e.parentNode;i.appendChild(r);const{hasTransform:o}=aa(r);return i.removeChild(r),o}const ya=t=>{const e=t.props["onUpdate:modelValue"];return(0,i.kJ)(e)?t=>(0,i.ir)(e,t):e};function ba(t){t.target.composing=!0}function Ea(t){const e=t.target;e.composing&&(e.composing=!1,Ta(e,"input"))}function Ta(t,e){const n=document.createEvent("HTMLEvents");n.initEvent(e,!0,!0),t.dispatchEvent(n)}const xa={created(t,{modifiers:{lazy:e,trim:n,number:r}},o){t._assign=ya(o);const s=r||o.props&&"number"===o.props.type;Is(t,e?"change":"input",(e=>{if(e.target.composing)return;let r=t.value;n?r=r.trim():s&&(r=(0,i.He)(r)),t._assign(r)})),n&&Is(t,"change",(()=>{t.value=t.value.trim()})),e||(Is(t,"compositionstart",ba),Is(t,"compositionend",Ea),Is(t,"change",Ea))},mounted(t,{value:e}){t.value=null==e?"":e},beforeUpdate(t,{value:e,modifiers:{lazy:n,trim:r,number:o}},s){if(t._assign=ya(s),t.composing)return;if(document.activeElement===t){if(n)return;if(r&&t.value.trim()===e)return;if((o||"number"===t.type)&&(0,i.He)(t.value)===e)return}const a=null==e?"":e;t.value!==a&&(t.value=a)}},Sa={deep:!0,created(t,e,n){t._assign=ya(n),Is(t,"change",(()=>{const e=t._modelValue,n=wa(t),r=t.checked,o=t._assign;if((0,i.kJ)(e)){const t=(0,i.hq)(e,n),s=-1!==t;if(r&&!s)o(e.concat(n));else if(!r&&s){const n=[...e];n.splice(t,1),o(n)}}else if((0,i.DM)(e)){const t=new Set(e);r?t.add(n):t.delete(n),o(t)}else o(Ca(t,r))}))},mounted:Ra,beforeUpdate(t,e,n){t._assign=ya(n),Ra(t,e,n)}};function Ra(t,{value:e,oldValue:n},r){t._modelValue=e,(0,i.kJ)(e)?t.checked=(0,i.hq)(e,r.props.value)>-1:(0,i.DM)(e)?t.checked=e.has(r.props.value):e!==n&&(t.checked=(0,i.WV)(e,Ca(t,!0)))}const Aa={created(t,{value:e},n){t.checked=(0,i.WV)(e,n.props.value),t._assign=ya(n),Is(t,"change",(()=>{t._assign(wa(t))}))},beforeUpdate(t,{value:e,oldValue:n},r){t._assign=ya(r),e!==n&&(t.checked=(0,i.WV)(e,r.props.value))}},Oa={deep:!0,created(t,{value:e,modifiers:{number:n}},r){const o=(0,i.DM)(e);Is(t,"change",(()=>{const e=Array.prototype.filter.call(t.options,(t=>t.selected)).map((t=>n?(0,i.He)(wa(t)):wa(t)));t._assign(t.multiple?o?new Set(e):e:e[0])})),t._assign=ya(r)},mounted(t,{value:e}){Ia(t,e)},beforeUpdate(t,e,n){t._assign=ya(n)},updated(t,{value:e}){Ia(t,e)}};function Ia(t,e){const n=t.multiple;if(!n||(0,i.kJ)(e)||(0,i.DM)(e)){for(let r=0,o=t.options.length;r<o;r++){const o=t.options[r],s=wa(o);if(n)(0,i.kJ)(e)?o.selected=(0,i.hq)(e,s)>-1:o.selected=e.has(s);else if((0,i.WV)(wa(o),e))return void(t.selectedIndex!==r&&(t.selectedIndex=r))}n||-1===t.selectedIndex||(t.selectedIndex=-1)}}function wa(t){return"_value"in t?t._value:t.value}function Ca(t,e){const n=e?"_trueValue":"_falseValue";return n in t?t[n]:e}const Pa={created(t,e,n){Na(t,e,n,null,"created")},mounted(t,e,n){Na(t,e,n,null,"mounted")},beforeUpdate(t,e,n,r){Na(t,e,n,r,"beforeUpdate")},updated(t,e,n,r){Na(t,e,n,r,"updated")}};function Na(t,e,n,r,i){let o;switch(t.tagName){case"SELECT":o=Oa;break;case"TEXTAREA":o=xa;break;default:switch(n.props&&n.props.type){case"checkbox":o=Sa;break;case"radio":o=Aa;break;default:o=xa}}const s=o[i];s&&s(t,e,n,r)}function Ma(){xa.getSSRProps=({value:t})=>({value:t}),Aa.getSSRProps=({value:t},e)=>{if(e.props&&(0,i.WV)(e.props.value,t))return{checked:!0}},Sa.getSSRProps=({value:t},e)=>{if((0,i.kJ)(t)){if(e.props&&(0,i.hq)(t,e.props.value)>-1)return{checked:!0}}else if((0,i.DM)(t)){if(e.props&&t.has(e.props.value))return{checked:!0}}else if(t)return{checked:!0}}}const Da=["ctrl","shift","alt","meta"],La={stop:t=>t.stopPropagation(),prevent:t=>t.preventDefault(),self:t=>t.target!==t.currentTarget,ctrl:t=>!t.ctrlKey,shift:t=>!t.shiftKey,alt:t=>!t.altKey,meta:t=>!t.metaKey,left:t=>"button"in t&&0!==t.button,middle:t=>"button"in t&&1!==t.button,right:t=>"button"in t&&2!==t.button,exact:(t,e)=>Da.some((n=>t[`${n}Key`]&&!e.includes(n)))},Ba=(t,e)=>(n,...r)=>{for(let t=0;t<e.length;t++){const r=La[e[t]];if(r&&r(n,e))return}return t(n,...r)},Fa={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Ua=(t,e)=>n=>{if(!("key"in n))return;const r=(0,i.rs)(n.key);return e.some((t=>t===r||Fa[t]===r))?t(n):void 0},Ga={beforeMount(t,{value:e},{transition:n}){t._vod="none"===t.style.display?"":t.style.display,n&&e?n.beforeEnter(t):ka(t,e)},mounted(t,{value:e},{transition:n}){n&&e&&n.enter(t)},updated(t,{value:e,oldValue:n},{transition:r}){!e!==!n&&(r?e?(r.beforeEnter(t),ka(t,!0),r.enter(t)):r.leave(t,(()=>{ka(t,!1)})):ka(t,e))},beforeUnmount(t,{value:e}){ka(t,e)}};function ka(t,e){t.style.display=e?t._vod:"none"}function Xa(){Ga.getSSRProps=({value:t})=>{if(!t)return{style:{display:"none"}}}}const Ha=(0,i.l7)({patchProp:Bs},hs);let ja,Va=!1;function Ya(){return ja||(ja=pr(Ha))}function Wa(){return ja=Va?ja:mr(Ha),Va=!0,ja}const za=(...t)=>{Ya().render(...t)},$a=(...t)=>{Wa().hydrate(...t)},qa=(...t)=>{const e=Ya().createApp(...t);const{mount:n}=e;return e.mount=t=>{const r=Za(t);if(!r)return;const o=e._component;(0,i.mf)(o)||o.render||o.template||(o.template=r.innerHTML),r.innerHTML="";const s=n(r,!1,r instanceof SVGElement);return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),s},e},Ka=(...t)=>{const e=Wa().createApp(...t);const{mount:n}=e;return e.mount=t=>{const e=Za(t);if(e)return n(e,!0,e instanceof SVGElement)},e};function Za(t){if((0,i.HD)(t)){const e=document.querySelector(t);return e}return t}let Ja=!1;const Qa=()=>{Ja||(Ja=!0,Ma(),Xa())};function tu(t){throw t}function eu(t){}function nu(t,e,n,r){const i=t,o=new SyntaxError(String(i));return o.code=t,o.loc=e,o}const ru=Symbol(""),iu=Symbol(""),ou=Symbol(""),su=Symbol(""),au=Symbol(""),uu=Symbol(""),lu=Symbol(""),cu=Symbol(""),hu=Symbol(""),fu=Symbol(""),du=Symbol(""),pu=Symbol(""),mu=Symbol(""),vu=Symbol(""),gu=Symbol(""),_u=Symbol(""),yu=Symbol(""),bu=Symbol(""),Eu=Symbol(""),Tu=Symbol(""),xu=Symbol(""),Su=Symbol(""),Ru=Symbol(""),Au=Symbol(""),Ou=Symbol(""),Iu=Symbol(""),wu=Symbol(""),Cu=Symbol(""),Pu=Symbol(""),Nu=Symbol(""),Mu=Symbol(""),Du=Symbol(""),Lu=Symbol(""),Bu=Symbol(""),Fu=Symbol(""),Uu=Symbol(""),Gu=Symbol(""),ku=Symbol(""),Xu=Symbol(""),Hu={[ru]:"Fragment",[iu]:"Teleport",[ou]:"Suspense",[su]:"KeepAlive",[au]:"BaseTransition",[uu]:"openBlock",[lu]:"createBlock",[cu]:"createElementBlock",[hu]:"createVNode",[fu]:"createElementVNode",[du]:"createCommentVNode",[pu]:"createTextVNode",[mu]:"createStaticVNode",[vu]:"resolveComponent",[gu]:"resolveDynamicComponent",[_u]:"resolveDirective",[yu]:"resolveFilter",[bu]:"withDirectives",[Eu]:"renderList",[Tu]:"renderSlot",[xu]:"createSlots",[Su]:"toDisplayString",[Ru]:"mergeProps",[Au]:"normalizeClass",[Ou]:"normalizeStyle",[Iu]:"normalizeProps",[wu]:"guardReactiveProps",[Cu]:"toHandlers",[Pu]:"camelize",[Nu]:"capitalize",[Mu]:"toHandlerKey",[Du]:"setBlockTracking",[Lu]:"pushScopeId",[Bu]:"popScopeId",[Fu]:"withCtx",[Uu]:"unref",[Gu]:"isRef",[ku]:"withMemo",[Xu]:"isMemoSame"};function ju(t){Object.getOwnPropertySymbols(t).forEach((e=>{Hu[e]=t[e]}))}const Vu={source:"",start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0}};function Yu(t,e=Vu){return{type:0,children:t,helpers:[],components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:e}}function Wu(t,e,n,r,i,o,s,a=!1,u=!1,l=!1,c=Vu){return t&&(a?(t.helper(uu),t.helper(Rl(t.inSSR,l))):t.helper(Sl(t.inSSR,l)),s&&t.helper(bu)),{type:13,tag:e,props:n,children:r,patchFlag:i,dynamicProps:o,directives:s,isBlock:a,disableTracking:u,isComponent:l,loc:c}}function zu(t,e=Vu){return{type:17,loc:e,elements:t}}function $u(t,e=Vu){return{type:15,loc:e,properties:t}}function qu(t,e){return{type:16,loc:Vu,key:(0,i.HD)(t)?Ku(t,!0):t,value:e}}function Ku(t,e=!1,n=Vu,r=0){return{type:4,loc:n,content:t,isStatic:e,constType:e?3:r}}function Zu(t,e=Vu){return{type:8,loc:e,children:t}}function Ju(t,e=[],n=Vu){return{type:14,loc:n,callee:t,arguments:e}}function Qu(t,e,n=!1,r=!1,i=Vu){return{type:18,params:t,returns:e,newline:n,isSlot:r,loc:i}}function tl(t,e,n,r=!0){return{type:19,test:t,consequent:e,alternate:n,newline:r,loc:Vu}}function el(t,e,n=!1){return{type:20,index:t,value:e,isVNode:n,loc:Vu}}function nl(t){return{type:21,body:t,loc:Vu}}const rl=t=>4===t.type&&t.isStatic,il=(t,e)=>t===e||t===(0,i.rs)(e);function ol(t){return il(t,"Teleport")?iu:il(t,"Suspense")?ou:il(t,"KeepAlive")?su:il(t,"BaseTransition")?au:void 0}const sl=/^\d|[^\$\w]/,al=t=>!sl.test(t),ul=/[A-Za-z_$\xA0-\uFFFF]/,ll=/[\.\?\w$\xA0-\uFFFF]/,cl=/\s+[.[]\s*|\s*[.[]\s+/g,hl=t=>{t=t.trim().replace(cl,(t=>t.trim()));let e=0,n=[],r=0,i=0,o=null;for(let s=0;s<t.length;s++){const a=t.charAt(s);switch(e){case 0:if("["===a)n.push(e),e=1,r++;else if("("===a)n.push(e),e=2,i++;else if(!(0===s?ul:ll).test(a))return!1;break;case 1:"'"===a||'"'===a||"`"===a?(n.push(e),e=3,o=a):"["===a?r++:"]"===a&&(--r||(e=n.pop()));break;case 2:if("'"===a||'"'===a||"`"===a)n.push(e),e=3,o=a;else if("("===a)i++;else if(")"===a){if(s===t.length-1)return!1;--i||(e=n.pop())}break;case 3:a===o&&(e=n.pop(),o=null);break}}return!r&&!i},fl=hl;function dl(t,e,n){const r=t.source.slice(e,e+n),i={source:r,start:pl(t.start,t.source,e),end:t.end};return null!=n&&(i.end=pl(t.start,t.source,e+n)),i}function pl(t,e,n=e.length){return ml((0,i.l7)({},t),e,n)}function ml(t,e,n=e.length){let r=0,i=-1;for(let o=0;o<n;o++)10===e.charCodeAt(o)&&(r++,i=o);return t.offset+=n,t.line+=r,t.column=-1===i?t.column+n:n-i,t}function vl(t,e,n=!1){for(let r=0;r<t.props.length;r++){const o=t.props[r];if(7===o.type&&(n||o.exp)&&((0,i.HD)(e)?o.name===e:e.test(o.name)))return o}}function gl(t,e,n=!1,r=!1){for(let i=0;i<t.props.length;i++){const o=t.props[i];if(6===o.type){if(n)continue;if(o.name===e&&(o.value||r))return o}else if("bind"===o.name&&(o.exp||r)&&_l(o.arg,e))return o}}function _l(t,e){return!(!t||!rl(t)||t.content!==e)}function yl(t){return t.props.some((t=>7===t.type&&"bind"===t.name&&(!t.arg||4!==t.arg.type||!t.arg.isStatic)))}function bl(t){return 5===t.type||2===t.type}function El(t){return 7===t.type&&"slot"===t.name}function Tl(t){return 1===t.type&&3===t.tagType}function xl(t){return 1===t.type&&2===t.tagType}function Sl(t,e){return t||e?hu:fu}function Rl(t,e){return t||e?lu:cu}const Al=new Set([Iu,wu]);function Ol(t,e=[]){if(t&&!(0,i.HD)(t)&&14===t.type){const n=t.callee;if(!(0,i.HD)(n)&&Al.has(n))return Ol(t.arguments[0],e.concat(t))}return[t,e]}function Il(t,e,n){let r,o,s=13===t.type?t.props:t.arguments[2],a=[];if(s&&!(0,i.HD)(s)&&14===s.type){const t=Ol(s);s=t[0],a=t[1],o=a[a.length-1]}if(null==s||(0,i.HD)(s))r=$u([e]);else if(14===s.type){const t=s.arguments[0];(0,i.HD)(t)||15!==t.type?s.callee===Cu?r=Ju(n.helper(Ru),[$u([e]),s]):s.arguments.unshift($u([e])):t.properties.unshift(e),!r&&(r=s)}else if(15===s.type){let t=!1;if(4===e.key.type){const n=e.key.content;t=s.properties.some((t=>4===t.key.type&&t.key.content===n))}t||s.properties.unshift(e),r=s}else r=Ju(n.helper(Ru),[$u([e]),s]),o&&o.callee===wu&&(o=a[a.length-2]);13===t.type?o?o.arguments[0]=r:t.props=r:o?o.arguments[0]=r:t.arguments[2]=r}function wl(t,e){return`_${e}_${t.replace(/[^\w]/g,((e,n)=>"-"===e?"_":t.charCodeAt(n).toString()))}`}function Cl(t){return 14===t.type&&t.callee===ku?t.arguments[1].returns:t}function Pl(t,{helper:e,removeHelper:n,inSSR:r}){t.isBlock||(t.isBlock=!0,n(Sl(r,t.isComponent)),e(uu),e(Rl(r,t.isComponent)))}function Nl(t,e){const n=e.options?e.options.compatConfig:e.compatConfig,r=n&&n[t];return"MODE"===t?r||3:r}function Ml(t,e){const n=Nl("MODE",e),r=Nl(t,e);return 3===n?!0===r:!1!==r}function Dl(t,e,n,...r){const i=Ml(t,e);return i}const Ll=/&(gt|lt|amp|apos|quot);/g,Bl={gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},Fl={delimiters:["{{","}}"],getNamespace:()=>0,getTextMode:()=>0,isVoidTag:i.NO,isPreTag:i.NO,isCustomElement:i.NO,decodeEntities:t=>t.replace(Ll,((t,e)=>Bl[e])),onError:tu,onWarn:eu,comments:!1};function Ul(t,e={}){const n=Gl(t,e),r=ec(n);return Yu(kl(n,0,[]),nc(n,r))}function Gl(t,e){const n=(0,i.l7)({},Fl);let r;for(r in e)n[r]=void 0===e[r]?Fl[r]:e[r];return{options:n,column:1,line:1,offset:0,originalSource:t,source:t,inPre:!1,inVPre:!1,onWarn:n.onWarn}}function kl(t,e,n){const r=rc(n),o=r?r.ns:0,s=[];while(!lc(t,e,n)){const a=t.source;let u;if(0===e||1===e)if(!t.inVPre&&ic(a,t.options.delimiters[0]))u=Jl(t,e);else if(0===e&&"<"===a[0])if(1===a.length)uc(t,5,1);else if("!"===a[1])ic(a,"\x3c!--")?u=jl(t):ic(a,"<!DOCTYPE")?u=Vl(t):ic(a,"<![CDATA[")?0!==o?u=Hl(t,n):(uc(t,1),u=Vl(t)):(uc(t,11),u=Vl(t));else if("/"===a[1])if(2===a.length)uc(t,5,2);else{if(">"===a[2]){uc(t,14,2),oc(t,3);continue}if(/[a-z]/i.test(a[2])){uc(t,23),zl(t,1,r);continue}uc(t,12,2),u=Vl(t)}else/[a-z]/i.test(a[1])?(u=Yl(t,n),Ml("COMPILER_NATIVE_TEMPLATE",t)&&u&&"template"===u.tag&&!u.props.some((t=>7===t.type&&Wl(t.name)))&&(u=u.children)):"?"===a[1]?(uc(t,21,1),u=Vl(t)):uc(t,12,1);if(u||(u=Ql(t,e)),(0,i.kJ)(u))for(let t=0;t<u.length;t++)Xl(s,u[t]);else Xl(s,u)}let a=!1;if(2!==e&&1!==e){const e="preserve"!==t.options.whitespace;for(let n=0;n<s.length;n++){const r=s[n];if(t.inPre||2!==r.type)3!==r.type||t.options.comments||(a=!0,s[n]=null);else if(/[^\t\r\n\f ]/.test(r.content))e&&(r.content=r.content.replace(/[\t\r\n\f ]+/g," "));else{const t=s[n-1],i=s[n+1];!t||!i||e&&(3===t.type||3===i.type||1===t.type&&1===i.type&&/[\r\n]/.test(r.content))?(a=!0,s[n]=null):r.content=" "}}if(t.inPre&&r&&t.options.isPreTag(r.tag)){const t=s[0];t&&2===t.type&&(t.content=t.content.replace(/^\r?\n/,""))}}return a?s.filter(Boolean):s}function Xl(t,e){if(2===e.type){const n=rc(t);if(n&&2===n.type&&n.loc.end.offset===e.loc.start.offset)return n.content+=e.content,n.loc.end=e.loc.end,void(n.loc.source+=e.loc.source)}t.push(e)}function Hl(t,e){oc(t,9);const n=kl(t,3,e);return 0===t.source.length?uc(t,6):oc(t,3),n}function jl(t){const e=ec(t);let n;const r=/--(\!)?>/.exec(t.source);if(r){r.index<=3&&uc(t,0),r[1]&&uc(t,10),n=t.source.slice(4,r.index);const e=t.source.slice(0,r.index);let i=1,o=0;while(-1!==(o=e.indexOf("\x3c!--",i)))oc(t,o-i+1),o+4<e.length&&uc(t,16),i=o+1;oc(t,r.index+r[0].length-i+1)}else n=t.source.slice(4),oc(t,t.source.length),uc(t,7);return{type:3,content:n,loc:nc(t,e)}}function Vl(t){const e=ec(t),n="?"===t.source[1]?1:2;let r;const i=t.source.indexOf(">");return-1===i?(r=t.source.slice(n),oc(t,t.source.length)):(r=t.source.slice(n,i),oc(t,i+1)),{type:3,content:r,loc:nc(t,e)}}function Yl(t,e){const n=t.inPre,r=t.inVPre,i=rc(e),o=zl(t,0,i),s=t.inPre&&!n,a=t.inVPre&&!r;if(o.isSelfClosing||t.options.isVoidTag(o.tag))return s&&(t.inPre=!1),a&&(t.inVPre=!1),o;e.push(o);const u=t.options.getTextMode(o,i),l=kl(t,u,e);e.pop();{const e=o.props.find((t=>6===t.type&&"inline-template"===t.name));if(e&&Dl("COMPILER_INLINE_TEMPLATE",t,e.loc)){const n=nc(t,o.loc.end);e.value={type:2,content:n.source,loc:n}}}if(o.children=l,cc(t.source,o.tag))zl(t,1,i);else if(uc(t,24,0,o.loc.start),0===t.source.length&&"script"===o.tag.toLowerCase()){const e=l[0];e&&ic(e.loc.source,"\x3c!--")&&uc(t,8)}return o.loc=nc(t,o.loc.start),s&&(t.inPre=!1),a&&(t.inVPre=!1),o}const Wl=(0,i.fY)("if,else,else-if,for,slot");function zl(t,e,n){const r=ec(t),o=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(t.source),s=o[1],a=t.options.getNamespace(s,n);oc(t,o[0].length),sc(t);const u=ec(t),l=t.source;t.options.isPreTag(s)&&(t.inPre=!0);let c=ql(t,e);0===e&&!t.inVPre&&c.some((t=>7===t.type&&"pre"===t.name))&&(t.inVPre=!0,(0,i.l7)(t,u),t.source=l,c=ql(t,e).filter((t=>"v-pre"!==t.name)));let h=!1;if(0===t.source.length?uc(t,9):(h=ic(t.source,"/>"),1===e&&h&&uc(t,4),oc(t,h?2:1)),1===e)return;let f=0;return t.inVPre||("slot"===s?f=2:"template"===s?c.some((t=>7===t.type&&Wl(t.name)))&&(f=3):$l(s,c,t)&&(f=1)),{type:1,ns:a,tag:s,tagType:f,props:c,isSelfClosing:h,children:[],loc:nc(t,r),codegenNode:void 0}}function $l(t,e,n){const r=n.options;if(r.isCustomElement(t))return!1;if("component"===t||/^[A-Z]/.test(t)||ol(t)||r.isBuiltInComponent&&r.isBuiltInComponent(t)||r.isNativeTag&&!r.isNativeTag(t))return!0;for(let i=0;i<e.length;i++){const t=e[i];if(6===t.type){if("is"===t.name&&t.value){if(t.value.content.startsWith("vue:"))return!0;if(Dl("COMPILER_IS_ON_ELEMENT",n,t.loc))return!0}}else{if("is"===t.name)return!0;if("bind"===t.name&&_l(t.arg,"is")&&Dl("COMPILER_IS_ON_ELEMENT",n,t.loc))return!0}}}function ql(t,e){const n=[],r=new Set;while(t.source.length>0&&!ic(t.source,">")&&!ic(t.source,"/>")){if(ic(t.source,"/")){uc(t,22),oc(t,1),sc(t);continue}1===e&&uc(t,3);const i=Kl(t,r);6===i.type&&i.value&&"class"===i.name&&(i.value.content=i.value.content.replace(/\s+/g," ").trim()),0===e&&n.push(i),/^[^\t\r\n\f />]/.test(t.source)&&uc(t,15),sc(t)}return n}function Kl(t,e){const n=ec(t),r=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(t.source),i=r[0];e.has(i)&&uc(t,2),e.add(i),"="===i[0]&&uc(t,19);{const e=/["'<]/g;let n;while(n=e.exec(i))uc(t,17,n.index)}let o;oc(t,i.length),/^[\t\r\n\f ]*=/.test(t.source)&&(sc(t),oc(t,1),sc(t),o=Zl(t),o||uc(t,13));const s=nc(t,n);if(!t.inVPre&&/^(v-[A-Za-z0-9-]|:|\.|@|#)/.test(i)){const e=/(?:^v-([a-z0-9-]+))?(?:(?::|^\.|^@|^#)(\[[^\]]+\]|[^\.]+))?(.+)?$/i.exec(i);let r,a=ic(i,"."),u=e[1]||(a||ic(i,":")?"bind":ic(i,"@")?"on":"slot");if(e[2]){const o="slot"===u,s=i.lastIndexOf(e[2]),a=nc(t,ac(t,n,s),ac(t,n,s+e[2].length+(o&&e[3]||"").length));let l=e[2],c=!0;l.startsWith("[")?(c=!1,l.endsWith("]")?l=l.slice(1,l.length-1):(uc(t,27),l=l.slice(1))):o&&(l+=e[3]||""),r={type:4,content:l,isStatic:c,constType:c?3:0,loc:a}}if(o&&o.isQuoted){const t=o.loc;t.start.offset++,t.start.column++,t.end=pl(t.start,o.content),t.source=t.source.slice(1,-1)}const l=e[3]?e[3].slice(1).split("."):[];return a&&l.push("prop"),"bind"===u&&r&&l.includes("sync")&&Dl("COMPILER_V_BIND_SYNC",t,s,r.loc.source)&&(u="model",l.splice(l.indexOf("sync"),1)),{type:7,name:u,exp:o&&{type:4,content:o.content,isStatic:!1,constType:0,loc:o.loc},arg:r,modifiers:l,loc:s}}return!t.inVPre&&ic(i,"v-")&&uc(t,26),{type:6,name:i,value:o&&{type:2,content:o.content,loc:o.loc},loc:s}}function Zl(t){const e=ec(t);let n;const r=t.source[0],i='"'===r||"'"===r;if(i){oc(t,1);const e=t.source.indexOf(r);-1===e?n=tc(t,t.source.length,4):(n=tc(t,e,4),oc(t,1))}else{const e=/^[^\t\r\n\f >]+/.exec(t.source);if(!e)return;const r=/["'<=`]/g;let i;while(i=r.exec(e[0]))uc(t,18,i.index);n=tc(t,e[0].length,4)}return{content:n,isQuoted:i,loc:nc(t,e)}}function Jl(t,e){const[n,r]=t.options.delimiters,i=t.source.indexOf(r,n.length);if(-1===i)return void uc(t,25);const o=ec(t);oc(t,n.length);const s=ec(t),a=ec(t),u=i-n.length,l=t.source.slice(0,u),c=tc(t,u,e),h=c.trim(),f=c.indexOf(h);f>0&&ml(s,l,f);const d=u-(c.length-h.length-f);return ml(a,l,d),oc(t,r.length),{type:5,content:{type:4,isStatic:!1,constType:0,content:h,loc:nc(t,s,a)},loc:nc(t,o)}}function Ql(t,e){const n=3===e?["]]>"]:["<",t.options.delimiters[0]];let r=t.source.length;for(let s=0;s<n.length;s++){const e=t.source.indexOf(n[s],1);-1!==e&&r>e&&(r=e)}const i=ec(t),o=tc(t,r,e);return{type:2,content:o,loc:nc(t,i)}}function tc(t,e,n){const r=t.source.slice(0,e);return oc(t,e),2===n||3===n||-1===r.indexOf("&")?r:t.options.decodeEntities(r,4===n)}function ec(t){const{column:e,line:n,offset:r}=t;return{column:e,line:n,offset:r}}function nc(t,e,n){return n=n||ec(t),{start:e,end:n,source:t.originalSource.slice(e.offset,n.offset)}}function rc(t){return t[t.length-1]}function ic(t,e){return t.startsWith(e)}function oc(t,e){const{source:n}=t;ml(t,n,e),t.source=n.slice(e)}function sc(t){const e=/^[\t\r\n\f ]+/.exec(t.source);e&&oc(t,e[0].length)}function ac(t,e,n){return pl(e,t.originalSource.slice(e.offset,n),n)}function uc(t,e,n,r=ec(t)){n&&(r.offset+=n,r.column+=n),t.options.onError(nu(e,{start:r,end:r,source:""}))}function lc(t,e,n){const r=t.source;switch(e){case 0:if(ic(r,"</"))for(let t=n.length-1;t>=0;--t)if(cc(r,n[t].tag))return!0;break;case 1:case 2:{const t=rc(n);if(t&&cc(r,t.tag))return!0;break}case 3:if(ic(r,"]]>"))return!0;break}return!r}function cc(t,e){return ic(t,"</")&&t.slice(2,2+e.length).toLowerCase()===e.toLowerCase()&&/[\t\r\n\f />]/.test(t[2+e.length]||">")}function hc(t,e){dc(t,e,fc(t,t.children[0]))}function fc(t,e){const{children:n}=t;return 1===n.length&&1===e.type&&!xl(e)}function dc(t,e,n=!1){const{children:r}=t,o=r.length;let s=0;for(let i=0;i<r.length;i++){const t=r[i];if(1===t.type&&0===t.tagType){const r=n?0:pc(t,e);if(r>0){if(r>=2){t.codegenNode.patchFlag="-1",t.codegenNode=e.hoist(t.codegenNode),s++;continue}}else{const n=t.codegenNode;if(13===n.type){const r=yc(n);if((!r||512===r||1===r)&&gc(t,e)>=2){const r=_c(t);r&&(n.props=e.hoist(r))}n.dynamicProps&&(n.dynamicProps=e.hoist(n.dynamicProps))}}}else 12===t.type&&pc(t.content,e)>=2&&(t.codegenNode=e.hoist(t.codegenNode),s++);if(1===t.type){const n=1===t.tagType;n&&e.scopes.vSlot++,dc(t,e),n&&e.scopes.vSlot--}else if(11===t.type)dc(t,e,1===t.children.length);else if(9===t.type)for(let n=0;n<t.branches.length;n++)dc(t.branches[n],e,1===t.branches[n].children.length)}s&&e.transformHoist&&e.transformHoist(r,e,t),s&&s===o&&1===t.type&&0===t.tagType&&t.codegenNode&&13===t.codegenNode.type&&(0,i.kJ)(t.codegenNode.children)&&(t.codegenNode.children=e.hoist(zu(t.codegenNode.children)))}function pc(t,e){const{constantCache:n}=e;switch(t.type){case 1:if(0!==t.tagType)return 0;const r=n.get(t);if(void 0!==r)return r;const o=t.codegenNode;if(13!==o.type)return 0;if(o.isBlock&&"svg"!==t.tag&&"foreignObject"!==t.tag)return 0;const s=yc(o);if(s)return n.set(t,0),0;{let r=3;const i=gc(t,e);if(0===i)return n.set(t,0),0;i<r&&(r=i);for(let o=0;o<t.children.length;o++){const i=pc(t.children[o],e);if(0===i)return n.set(t,0),0;i<r&&(r=i)}if(r>1)for(let o=0;o<t.props.length;o++){const i=t.props[o];if(7===i.type&&"bind"===i.name&&i.exp){const o=pc(i.exp,e);if(0===o)return n.set(t,0),0;o<r&&(r=o)}}return o.isBlock&&(e.removeHelper(uu),e.removeHelper(Rl(e.inSSR,o.isComponent)),o.isBlock=!1,e.helper(Sl(e.inSSR,o.isComponent))),n.set(t,r),r}case 2:case 3:return 3;case 9:case 11:case 10:return 0;case 5:case 12:return pc(t.content,e);case 4:return t.constType;case 8:let a=3;for(let n=0;n<t.children.length;n++){const r=t.children[n];if((0,i.HD)(r)||(0,i.yk)(r))continue;const o=pc(r,e);if(0===o)return 0;o<a&&(a=o)}return a;default:return 0}}const mc=new Set([Au,Ou,Iu,wu]);function vc(t,e){if(14===t.type&&!(0,i.HD)(t.callee)&&mc.has(t.callee)){const n=t.arguments[0];if(4===n.type)return pc(n,e);if(14===n.type)return vc(n,e)}return 0}function gc(t,e){let n=3;const r=_c(t);if(r&&15===r.type){const{properties:t}=r;for(let r=0;r<t.length;r++){const{key:i,value:o}=t[r],s=pc(i,e);if(0===s)return s;let a;if(s<n&&(n=s),a=4===o.type?pc(o,e):14===o.type?vc(o,e):0,0===a)return a;a<n&&(n=a)}}return n}function _c(t){const e=t.codegenNode;if(13===e.type)return e.props}function yc(t){const e=t.patchFlag;return e?parseInt(e,10):void 0}function bc(t,{filename:e="",prefixIdentifiers:n=!1,hoistStatic:r=!1,cacheHandlers:o=!1,nodeTransforms:s=[],directiveTransforms:a={},transformHoist:u=null,isBuiltInComponent:l=i.dG,isCustomElement:c=i.dG,expressionPlugins:h=[],scopeId:f=null,slotted:d=!0,ssr:p=!1,inSSR:m=!1,ssrCssVars:v="",bindingMetadata:g=i.kT,inline:_=!1,isTS:y=!1,onError:b=tu,onWarn:E=eu,compatConfig:T}){const x=e.replace(/\?.*$/,"").match(/([^/\\]+)\.\w+$/),S={selfName:x&&(0,i.kC)((0,i._A)(x[1])),prefixIdentifiers:n,hoistStatic:r,cacheHandlers:o,nodeTransforms:s,directiveTransforms:a,transformHoist:u,isBuiltInComponent:l,isCustomElement:c,expressionPlugins:h,scopeId:f,slotted:d,ssr:p,inSSR:m,ssrCssVars:v,bindingMetadata:g,inline:_,isTS:y,onError:b,onWarn:E,compatConfig:T,root:t,helpers:new Map,components:new Set,directives:new Set,hoists:[],imports:[],constantCache:new Map,temps:0,cached:0,identifiers:Object.create(null),scopes:{vFor:0,vSlot:0,vPre:0,vOnce:0},parent:null,currentNode:t,childIndex:0,inVOnce:!1,helper(t){const e=S.helpers.get(t)||0;return S.helpers.set(t,e+1),t},removeHelper(t){const e=S.helpers.get(t);if(e){const n=e-1;n?S.helpers.set(t,n):S.helpers.delete(t)}},helperString(t){return`_${Hu[S.helper(t)]}`},replaceNode(t){S.parent.children[S.childIndex]=S.currentNode=t},removeNode(t){const e=S.parent.children,n=t?e.indexOf(t):S.currentNode?S.childIndex:-1;t&&t!==S.currentNode?S.childIndex>n&&(S.childIndex--,S.onNodeRemoved()):(S.currentNode=null,S.onNodeRemoved()),S.parent.children.splice(n,1)},onNodeRemoved:()=>{},addIdentifiers(t){},removeIdentifiers(t){},hoist(t){(0,i.HD)(t)&&(t=Ku(t)),S.hoists.push(t);const e=Ku(`_hoisted_${S.hoists.length}`,!1,t.loc,2);return e.hoisted=t,e},cache(t,e=!1){return el(S.cached++,t,e)}};return S.filters=new Set,S}function Ec(t,e){const n=bc(t,e);Sc(t,n),e.hoistStatic&&hc(t,n),e.ssr||Tc(t,n),t.helpers=[...n.helpers.keys()],t.components=[...n.components],t.directives=[...n.directives],t.imports=n.imports,t.hoists=n.hoists,t.temps=n.temps,t.cached=n.cached,t.filters=[...n.filters]}function Tc(t,e){const{helper:n}=e,{children:r}=t;if(1===r.length){const n=r[0];if(fc(t,n)&&n.codegenNode){const r=n.codegenNode;13===r.type&&Pl(r,e),t.codegenNode=r}else t.codegenNode=n}else if(r.length>1){let r=64;i.m[64];0,t.codegenNode=Wu(e,n(ru),void 0,t.children,r+"",void 0,void 0,!0,void 0,!1)}}function xc(t,e){let n=0;const r=()=>{n--};for(;n<t.children.length;n++){const o=t.children[n];(0,i.HD)(o)||(e.parent=t,e.childIndex=n,e.onNodeRemoved=r,Sc(o,e))}}function Sc(t,e){e.currentNode=t;const{nodeTransforms:n}=e,r=[];for(let s=0;s<n.length;s++){const o=n[s](t,e);if(o&&((0,i.kJ)(o)?r.push(...o):r.push(o)),!e.currentNode)return;t=e.currentNode}switch(t.type){case 3:e.ssr||e.helper(du);break;case 5:e.ssr||e.helper(Su);break;case 9:for(let n=0;n<t.branches.length;n++)Sc(t.branches[n],e);break;case 10:case 11:case 1:case 0:xc(t,e);break}e.currentNode=t;let o=r.length;while(o--)r[o]()}function Rc(t,e){const n=(0,i.HD)(t)?e=>e===t:e=>t.test(e);return(t,r)=>{if(1===t.type){const{props:i}=t;if(3===t.tagType&&i.some(El))return;const o=[];for(let s=0;s<i.length;s++){const a=i[s];if(7===a.type&&n(a.name)){i.splice(s,1),s--;const n=e(t,a,r);n&&o.push(n)}}return o}}}const Ac="/*#__PURE__*/";function Oc(t,{mode:e="function",prefixIdentifiers:n="module"===e,sourceMap:r=!1,filename:i="template.vue.html",scopeId:o=null,optimizeImports:s=!1,runtimeGlobalName:a="Vue",runtimeModuleName:u="vue",ssrRuntimeModuleName:l="vue/server-renderer",ssr:c=!1,isTS:h=!1,inSSR:f=!1}){const d={mode:e,prefixIdentifiers:n,sourceMap:r,filename:i,scopeId:o,optimizeImports:s,runtimeGlobalName:a,runtimeModuleName:u,ssrRuntimeModuleName:l,ssr:c,isTS:h,inSSR:f,source:t.loc.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(t){return`_${Hu[t]}`},push(t,e){d.code+=t},indent(){p(++d.indentLevel)},deindent(t=!1){t?--d.indentLevel:p(--d.indentLevel)},newline(){p(d.indentLevel)}};function p(t){d.push("\n"+" ".repeat(t))}return d}function Ic(t,e={}){const n=Oc(t,e);e.onContextCreated&&e.onContextCreated(n);const{mode:r,push:i,prefixIdentifiers:o,indent:s,deindent:a,newline:u,scopeId:l,ssr:c}=n,h=t.helpers.length>0,f=!o&&"module"!==r,d=n;wc(t,d);const p=c?"ssrRender":"render",m=c?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"],v=m.join(", ");if(i(`function ${p}(${v}) {`),s(),f&&(i("with (_ctx) {"),s(),h&&(i(`const { ${t.helpers.map((t=>`${Hu[t]}: _${Hu[t]}`)).join(", ")} } = _Vue`),i("\n"),u())),t.components.length&&(Cc(t.components,"component",n),(t.directives.length||t.temps>0)&&u()),t.directives.length&&(Cc(t.directives,"directive",n),t.temps>0&&u()),t.filters&&t.filters.length&&(u(),Cc(t.filters,"filter",n),u()),t.temps>0){i("let ");for(let e=0;e<t.temps;e++)i(`${e>0?", ":""}_temp${e}`)}return(t.components.length||t.directives.length||t.temps)&&(i("\n"),u()),c||i("return "),t.codegenNode?Dc(t.codegenNode,n):i("null"),f&&(a(),i("}")),a(),i("}"),{ast:t,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function wc(t,e){const{ssr:n,prefixIdentifiers:r,push:i,newline:o,runtimeModuleName:s,runtimeGlobalName:a,ssrRuntimeModuleName:u}=e,l=a,c=t=>`${Hu[t]}: _${Hu[t]}`;if(t.helpers.length>0&&(i(`const _Vue = ${l}\n`),t.hoists.length)){const e=[hu,fu,du,pu,mu].filter((e=>t.helpers.includes(e))).map(c).join(", ");i(`const { ${e} } = _Vue\n`)}Pc(t.hoists,e),o(),i("return ")}function Cc(t,e,{helper:n,push:r,newline:i,isTS:o}){const s=n("filter"===e?yu:"component"===e?vu:_u);for(let a=0;a<t.length;a++){let n=t[a];const u=n.endsWith("__self");u&&(n=n.slice(0,-6)),r(`const ${wl(n,e)} = ${s}(${JSON.stringify(n)}${u?", true":""})${o?"!":""}`),a<t.length-1&&i()}}function Pc(t,e){if(!t.length)return;e.pure=!0;const{push:n,newline:r,helper:i,scopeId:o,mode:s}=e;r();for(let a=0;a<t.length;a++){const i=t[a];i&&(n(`const _hoisted_${a+1} = `),Dc(i,e),r())}e.pure=!1}function Nc(t,e){const n=t.length>3||!1;e.push("["),n&&e.indent(),Mc(t,e,n),n&&e.deindent(),e.push("]")}function Mc(t,e,n=!1,r=!0){const{push:o,newline:s}=e;for(let a=0;a<t.length;a++){const u=t[a];(0,i.HD)(u)?o(u):(0,i.kJ)(u)?Nc(u,e):Dc(u,e),a<t.length-1&&(n?(r&&o(","),s()):r&&o(", "))}}function Dc(t,e){if((0,i.HD)(t))e.push(t);else if((0,i.yk)(t))e.push(e.helper(t));else switch(t.type){case 1:case 9:case 11:Dc(t.codegenNode,e);break;case 2:Lc(t,e);break;case 4:Bc(t,e);break;case 5:Fc(t,e);break;case 12:Dc(t.codegenNode,e);break;case 8:Uc(t,e);break;case 3:kc(t,e);break;case 13:Xc(t,e);break;case 14:jc(t,e);break;case 15:Vc(t,e);break;case 17:Yc(t,e);break;case 18:Wc(t,e);break;case 19:zc(t,e);break;case 20:$c(t,e);break;case 21:Mc(t.body,e,!0,!1);break;case 22:break;case 23:break;case 24:break;case 25:break;case 26:break;case 10:break;default:0}}function Lc(t,e){e.push(JSON.stringify(t.content),t)}function Bc(t,e){const{content:n,isStatic:r}=t;e.push(r?JSON.stringify(n):n,t)}function Fc(t,e){const{push:n,helper:r,pure:i}=e;i&&n(Ac),n(`${r(Su)}(`),Dc(t.content,e),n(")")}function Uc(t,e){for(let n=0;n<t.children.length;n++){const r=t.children[n];(0,i.HD)(r)?e.push(r):Dc(r,e)}}function Gc(t,e){const{push:n}=e;if(8===t.type)n("["),Uc(t,e),n("]");else if(t.isStatic){const e=al(t.content)?t.content:JSON.stringify(t.content);n(e,t)}else n(`[${t.content}]`,t)}function kc(t,e){const{push:n,helper:r,pure:i}=e;i&&n(Ac),n(`${r(du)}(${JSON.stringify(t.content)})`,t)}function Xc(t,e){const{push:n,helper:r,pure:i}=e,{tag:o,props:s,children:a,patchFlag:u,dynamicProps:l,directives:c,isBlock:h,disableTracking:f,isComponent:d}=t;c&&n(r(bu)+"("),h&&n(`(${r(uu)}(${f?"true":""}), `),i&&n(Ac);const p=h?Rl(e.inSSR,d):Sl(e.inSSR,d);n(r(p)+"(",t),Mc(Hc([o,s,a,u,l]),e),n(")"),h&&n(")"),c&&(n(", "),Dc(c,e),n(")"))}function Hc(t){let e=t.length;while(e--)if(null!=t[e])break;return t.slice(0,e+1).map((t=>t||"null"))}function jc(t,e){const{push:n,helper:r,pure:o}=e,s=(0,i.HD)(t.callee)?t.callee:r(t.callee);o&&n(Ac),n(s+"(",t),Mc(t.arguments,e),n(")")}function Vc(t,e){const{push:n,indent:r,deindent:i,newline:o}=e,{properties:s}=t;if(!s.length)return void n("{}",t);const a=s.length>1||!1;n(a?"{":"{ "),a&&r();for(let u=0;u<s.length;u++){const{key:t,value:r}=s[u];Gc(t,e),n(": "),Dc(r,e),u<s.length-1&&(n(","),o())}a&&i(),n(a?"}":" }")}function Yc(t,e){Nc(t.elements,e)}function Wc(t,e){const{push:n,indent:r,deindent:o}=e,{params:s,returns:a,body:u,newline:l,isSlot:c}=t;c&&n(`_${Hu[Fu]}(`),n("(",t),(0,i.kJ)(s)?Mc(s,e):s&&Dc(s,e),n(") => "),(l||u)&&(n("{"),r()),a?(l&&n("return "),(0,i.kJ)(a)?Nc(a,e):Dc(a,e)):u&&Dc(u,e),(l||u)&&(o(),n("}")),c&&(t.isNonScopedSlot&&n(", undefined, true"),n(")"))}function zc(t,e){const{test:n,consequent:r,alternate:i,newline:o}=t,{push:s,indent:a,deindent:u,newline:l}=e;if(4===n.type){const t=!al(n.content);t&&s("("),Bc(n,e),t&&s(")")}else s("("),Dc(n,e),s(")");o&&a(),e.indentLevel++,o||s(" "),s("? "),Dc(r,e),e.indentLevel--,o&&l(),o||s(" "),s(": ");const c=19===i.type;c||e.indentLevel++,Dc(i,e),c||e.indentLevel--,o&&u(!0)}function $c(t,e){const{push:n,helper:r,indent:i,deindent:o,newline:s}=e;n(`_cache[${t.index}] || (`),t.isVNode&&(i(),n(`${r(Du)}(-1),`),s()),n(`_cache[${t.index}] = `),Dc(t.value,e),t.isVNode&&(n(","),s(),n(`${r(Du)}(1),`),s(),n(`_cache[${t.index}]`),o()),n(")")}new RegExp("\\b"+"do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments,typeof,void".split(",").join("\\b|\\b")+"\\b");const qc=Rc(/^(if|else|else-if)$/,((t,e,n)=>Kc(t,e,n,((t,e,r)=>{const i=n.parent.children;let o=i.indexOf(t),s=0;while(o-- >=0){const t=i[o];t&&9===t.type&&(s+=t.branches.length)}return()=>{if(r)t.codegenNode=Jc(e,s,n);else{const r=th(t.codegenNode);r.alternate=Jc(e,s+t.branches.length-1,n)}}}))));function Kc(t,e,n,r){if("else"!==e.name&&(!e.exp||!e.exp.content.trim())){const r=e.exp?e.exp.loc:t.loc;n.onError(nu(28,e.loc)),e.exp=Ku("true",!1,r)}if("if"===e.name){const i=Zc(t,e),o={type:9,loc:t.loc,branches:[i]};if(n.replaceNode(o),r)return r(o,i,!0)}else{const i=n.parent.children;let o=i.indexOf(t);while(o-- >=-1){const s=i[o];if(!s||2!==s.type||s.content.trim().length){if(s&&9===s.type){"else-if"===e.name&&void 0===s.branches[s.branches.length-1].condition&&n.onError(nu(30,t.loc)),n.removeNode();const i=Zc(t,e);0,s.branches.push(i);const o=r&&r(s,i,!1);Sc(i,n),o&&o(),n.currentNode=null}else n.onError(nu(30,t.loc));break}n.removeNode(s)}}}function Zc(t,e){return{type:10,loc:t.loc,condition:"else"===e.name?void 0:e.exp,children:3!==t.tagType||vl(t,"for")?[t]:t.children,userKey:gl(t,"key")}}function Jc(t,e,n){return t.condition?tl(t.condition,Qc(t,e,n),Ju(n.helper(du),['""',"true"])):Qc(t,e,n)}function Qc(t,e,n){const{helper:r}=n,o=qu("key",Ku(`${e}`,!1,Vu,2)),{children:s}=t,a=s[0],u=1!==s.length||1!==a.type;if(u){if(1===s.length&&11===a.type){const t=a.codegenNode;return Il(t,o,n),t}{let e=64;i.m[64];return Wu(n,r(ru),$u([o]),s,e+"",void 0,void 0,!0,!1,!1,t.loc)}}{const t=a.codegenNode,e=Cl(t);return 13===e.type&&Pl(e,n),Il(e,o,n),t}}function th(t){while(1)if(19===t.type){if(19!==t.alternate.type)return t;t=t.alternate}else 20===t.type&&(t=t.value)}const eh=Rc("for",((t,e,n)=>{const{helper:r,removeHelper:i}=n;return nh(t,e,n,(e=>{const o=Ju(r(Eu),[e.source]),s=vl(t,"memo"),a=gl(t,"key"),u=a&&(6===a.type?Ku(a.value.content,!0):a.exp),l=a?qu("key",u):null,c=4===e.source.type&&e.source.constType>0,h=c?64:a?128:256;return e.codegenNode=Wu(n,r(ru),void 0,o,h+"",void 0,void 0,!0,!c,!1,t.loc),()=>{let a;const h=Tl(t),{children:f}=e;const d=1!==f.length||1!==f[0].type,p=xl(t)?t:h&&1===t.children.length&&xl(t.children[0])?t.children[0]:null;if(p?(a=p.codegenNode,h&&l&&Il(a,l,n)):d?a=Wu(n,r(ru),l?$u([l]):void 0,t.children,"64",void 0,void 0,!0,void 0,!1):(a=f[0].codegenNode,h&&l&&Il(a,l,n),a.isBlock!==!c&&(a.isBlock?(i(uu),i(Rl(n.inSSR,a.isComponent))):i(Sl(n.inSSR,a.isComponent))),a.isBlock=!c,a.isBlock?(r(uu),r(Rl(n.inSSR,a.isComponent))):r(Sl(n.inSSR,a.isComponent))),s){const t=Qu(uh(e.parseResult,[Ku("_cached")]));t.body=nl([Zu(["const _memo = (",s.exp,")"]),Zu(["if (_cached",...u?[" && _cached.key === ",u]:[],` && ${n.helperString(Xu)}(_cached, _memo)) return _cached`]),Zu(["const _item = ",a]),Ku("_item.memo = _memo"),Ku("return _item")]),o.arguments.push(t,Ku("_cache"),Ku(String(n.cached++)))}else o.arguments.push(Qu(uh(e.parseResult),a,!0))}}))}));function nh(t,e,n,r){if(!e.exp)return void n.onError(nu(31,e.loc));const i=sh(e.exp,n);if(!i)return void n.onError(nu(32,e.loc));const{addIdentifiers:o,removeIdentifiers:s,scopes:a}=n,{source:u,value:l,key:c,index:h}=i,f={type:11,loc:e.loc,source:u,valueAlias:l,keyAlias:c,objectIndexAlias:h,parseResult:i,children:Tl(t)?t.children:[t]};n.replaceNode(f),a.vFor++;const d=r&&r(f);return()=>{a.vFor--,d&&d()}}const rh=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,ih=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,oh=/^\(|\)$/g;function sh(t,e){const n=t.loc,r=t.content,i=r.match(rh);if(!i)return;const[,o,s]=i,a={source:ah(n,s.trim(),r.indexOf(s,o.length)),value:void 0,key:void 0,index:void 0};let u=o.trim().replace(oh,"").trim();const l=o.indexOf(u),c=u.match(ih);if(c){u=u.replace(ih,"").trim();const t=c[1].trim();let e;if(t&&(e=r.indexOf(t,l+u.length),a.key=ah(n,t,e)),c[2]){const i=c[2].trim();i&&(a.index=ah(n,i,r.indexOf(i,a.key?e+t.length:l+u.length)))}}return u&&(a.value=ah(n,u,l)),a}function ah(t,e,n){return Ku(e,!1,dl(t,n,e.length))}function uh({value:t,key:e,index:n},r=[]){return lh([t,e,n,...r])}function lh(t){let e=t.length;while(e--)if(t[e])break;return t.slice(0,e+1).map(((t,e)=>t||Ku("_".repeat(e+1),!1)))}const ch=Ku("undefined",!1),hh=(t,e)=>{if(1===t.type&&(1===t.tagType||3===t.tagType)){const n=vl(t,"slot");if(n)return n.exp,e.scopes.vSlot++,()=>{e.scopes.vSlot--}}},fh=(t,e,n)=>Qu(t,e,!1,!0,e.length?e[0].loc:n);function dh(t,e,n=fh){e.helper(Fu);const{children:r,loc:i}=t,o=[],s=[];let a=e.scopes.vSlot>0||e.scopes.vFor>0;const u=vl(t,"slot",!0);if(u){const{arg:t,exp:e}=u;t&&!rl(t)&&(a=!0),o.push(qu(t||Ku("default",!0),n(e,r,i)))}let l=!1,c=!1;const h=[],f=new Set;for(let m=0;m<r.length;m++){const t=r[m];let i;if(!Tl(t)||!(i=vl(t,"slot",!0))){3!==t.type&&h.push(t);continue}if(u){e.onError(nu(37,i.loc));break}l=!0;const{children:d,loc:p}=t,{arg:v=Ku("default",!0),exp:g,loc:_}=i;let y;rl(v)?y=v?v.content:"default":a=!0;const b=n(g,d,p);let E,T,x;if(E=vl(t,"if"))a=!0,s.push(tl(E.exp,ph(v,b),ch));else if(T=vl(t,/^else(-if)?$/,!0)){let t,n=m;while(n--)if(t=r[n],3!==t.type)break;if(t&&Tl(t)&&vl(t,"if")){r.splice(m,1),m--;let t=s[s.length-1];while(19===t.alternate.type)t=t.alternate;t.alternate=T.exp?tl(T.exp,ph(v,b),ch):ph(v,b)}else e.onError(nu(30,T.loc))}else if(x=vl(t,"for")){a=!0;const t=x.parseResult||sh(x.exp,e);t?s.push(Ju(e.helper(Eu),[t.source,Qu(uh(t),ph(v,b),!0)])):e.onError(nu(32,x.loc))}else{if(y){if(f.has(y)){e.onError(nu(38,_));continue}f.add(y),"default"===y&&(c=!0)}o.push(qu(v,b))}}if(!u){const t=(t,r)=>{const o=n(t,r,i);return e.compatConfig&&(o.isNonScopedSlot=!0),qu("default",o)};l?h.length&&h.some((t=>vh(t)))&&(c?e.onError(nu(39,h[0].loc)):o.push(t(void 0,h))):o.push(t(void 0,r))}const d=a?2:mh(t.children)?3:1;let p=$u(o.concat(qu("_",Ku(d+"",!1))),i);return s.length&&(p=Ju(e.helper(xu),[p,zu(s)])),{slots:p,hasDynamicSlots:a}}function ph(t,e){return $u([qu("name",t),qu("fn",e)])}function mh(t){for(let e=0;e<t.length;e++){const n=t[e];switch(n.type){case 1:if(2===n.tagType||mh(n.children))return!0;break;case 9:if(mh(n.branches))return!0;break;case 10:case 11:if(mh(n.children))return!0;break}}return!1}function vh(t){return 2!==t.type&&12!==t.type||(2===t.type?!!t.content.trim():vh(t.content))}const gh=new WeakMap,_h=(t,e)=>function(){if(t=e.currentNode,1!==t.type||0!==t.tagType&&1!==t.tagType)return;const{tag:n,props:r}=t,o=1===t.tagType;let s=o?yh(t,e):`"${n}"`;const a=(0,i.Kn)(s)&&s.callee===gu;let u,l,c,h,f,d,p=0,m=a||s===iu||s===ou||!o&&("svg"===n||"foreignObject"===n);if(r.length>0){const n=bh(t,e);u=n.props,p=n.patchFlag,f=n.dynamicPropNames;const r=n.directives;d=r&&r.length?zu(r.map((t=>xh(t,e)))):void 0,n.shouldUseBlock&&(m=!0)}if(t.children.length>0){s===su&&(m=!0,p|=1024);const n=o&&s!==iu&&s!==su;if(n){const{slots:n,hasDynamicSlots:r}=dh(t,e);l=n,r&&(p|=1024)}else if(1===t.children.length&&s!==iu){const n=t.children[0],r=n.type,i=5===r||8===r;i&&0===pc(n,e)&&(p|=1),l=i||2===r?n:t.children}else l=t.children}0!==p&&(c=String(p),f&&f.length&&(h=Sh(f))),t.codegenNode=Wu(e,s,u,l,c,h,d,!!m,!1,o,t.loc)};function yh(t,e,n=!1){let{tag:r}=t;const i=Rh(r),o=gl(t,"is");if(o)if(i||Ml("COMPILER_IS_ON_ELEMENT",e)){const t=6===o.type?o.value&&Ku(o.value.content,!0):o.exp;if(t)return Ju(e.helper(gu),[t])}else 6===o.type&&o.value.content.startsWith("vue:")&&(r=o.value.content.slice(4));const s=!i&&vl(t,"is");if(s&&s.exp)return Ju(e.helper(gu),[s.exp]);const a=ol(r)||e.isBuiltInComponent(r);return a?(n||e.helper(a),a):(e.helper(vu),e.components.add(r),wl(r,"component"))}function bh(t,e,n=t.props,r=!1){const{tag:o,loc:s,children:a}=t,u=1===t.tagType;let l=[];const c=[],h=[],f=a.length>0;let d=!1,p=0,m=!1,v=!1,g=!1,_=!1,y=!1,b=!1;const E=[],T=({key:t,value:n})=>{if(rl(t)){const r=t.content,o=(0,i.F7)(r);if(u||!o||"onclick"===r.toLowerCase()||"onUpdate:modelValue"===r||(0,i.Gg)(r)||(_=!0),o&&(0,i.Gg)(r)&&(b=!0),20===n.type||(4===n.type||8===n.type)&&pc(n,e)>0)return;"ref"===r?m=!0:"class"===r?v=!0:"style"===r?g=!0:"key"===r||E.includes(r)||E.push(r),!u||"class"!==r&&"style"!==r||E.includes(r)||E.push(r)}else y=!0};for(let S=0;S<n.length;S++){const a=n[S];if(6===a.type){const{loc:t,name:n,value:r}=a;let i=!0;if("ref"===n&&(m=!0,e.scopes.vFor>0&&l.push(qu(Ku("ref_for",!0),Ku("true")))),"is"===n&&(Rh(o)||r&&r.content.startsWith("vue:")||Ml("COMPILER_IS_ON_ELEMENT",e)))continue;l.push(qu(Ku(n,!0,dl(t,0,n.length)),Ku(r?r.content:"",i,r?r.loc:t)))}else{const{name:n,arg:p,exp:m,loc:v}=a,g="bind"===n,_="on"===n;if("slot"===n){u||e.onError(nu(40,v));continue}if("once"===n||"memo"===n)continue;if("is"===n||g&&_l(p,"is")&&(Rh(o)||Ml("COMPILER_IS_ON_ELEMENT",e)))continue;if(_&&r)continue;if((g&&_l(p,"key")||_&&f&&_l(p,"vue:before-update"))&&(d=!0),g&&_l(p,"ref")&&e.scopes.vFor>0&&l.push(qu(Ku("ref_for",!0),Ku("true"))),!p&&(g||_)){if(y=!0,m)if(l.length&&(c.push($u(Eh(l),s)),l=[]),g){if(Ml("COMPILER_V_BIND_OBJECT_ORDER",e)){c.unshift(m);continue}c.push(m)}else c.push({type:14,loc:v,callee:e.helper(Cu),arguments:[m]});else e.onError(nu(g?34:35,v));continue}const b=e.directiveTransforms[n];if(b){const{props:n,needRuntime:o}=b(a,t,e);!r&&n.forEach(T),l.push(...n),o&&(h.push(a),(0,i.yk)(o)&&gh.set(a,o))}else h.push(a),f&&(d=!0)}}let x;if(c.length?(l.length&&c.push($u(Eh(l),s)),x=c.length>1?Ju(e.helper(Ru),c,s):c[0]):l.length&&(x=$u(Eh(l),s)),y?p|=16:(v&&!u&&(p|=2),g&&!u&&(p|=4),E.length&&(p|=8),_&&(p|=32)),d||0!==p&&32!==p||!(m||b||h.length>0)||(p|=512),!e.inSSR&&x)switch(x.type){case 15:let t=-1,n=-1,r=!1;for(let e=0;e<x.properties.length;e++){const i=x.properties[e].key;rl(i)?"class"===i.content?t=e:"style"===i.content&&(n=e):i.isHandlerKey||(r=!0)}const i=x.properties[t],o=x.properties[n];r?x=Ju(e.helper(Iu),[x]):(i&&!rl(i.value)&&(i.value=Ju(e.helper(Au),[i.value])),!o||rl(o.value)||!g&&17!==o.value.type||(o.value=Ju(e.helper(Ou),[o.value])));break;case 14:break;default:x=Ju(e.helper(Iu),[Ju(e.helper(wu),[x])]);break}return{props:x,directives:h,patchFlag:p,dynamicPropNames:E,shouldUseBlock:d}}function Eh(t){const e=new Map,n=[];for(let r=0;r<t.length;r++){const o=t[r];if(8===o.key.type||!o.key.isStatic){n.push(o);continue}const s=o.key.content,a=e.get(s);a?("style"===s||"class"===s||(0,i.F7)(s))&&Th(a,o):(e.set(s,o),n.push(o))}return n}function Th(t,e){17===t.value.type?t.value.elements.push(e.value):t.value=zu([t.value,e.value],t.loc)}function xh(t,e){const n=[],r=gh.get(t);r?n.push(e.helperString(r)):(e.helper(_u),e.directives.add(t.name),n.push(wl(t.name,"directive")));const{loc:i}=t;if(t.exp&&n.push(t.exp),t.arg&&(t.exp||n.push("void 0"),n.push(t.arg)),Object.keys(t.modifiers).length){t.arg||(t.exp||n.push("void 0"),n.push("void 0"));const e=Ku("true",!1,i);n.push($u(t.modifiers.map((t=>qu(t,e))),i))}return zu(n,t.loc)}function Sh(t){let e="[";for(let n=0,r=t.length;n<r;n++)e+=JSON.stringify(t[n]),n<r-1&&(e+=", ");return e+"]"}function Rh(t){return"component"===t||"Component"===t}const Ah=t=>{const e=Object.create(null);return n=>{const r=e[n];return r||(e[n]=t(n))}},Oh=/-(\w)/g,Ih=Ah((t=>t.replace(Oh,((t,e)=>e?e.toUpperCase():"")))),wh=(t,e)=>{if(xl(t)){const{children:n,loc:r}=t,{slotName:i,slotProps:o}=Ch(t,e),s=[e.prefixIdentifiers?"_ctx.$slots":"$slots",i,"{}","undefined","true"];let a=2;o&&(s[2]=o,a=3),n.length&&(s[3]=Qu([],n,!1,!1,r),a=4),e.scopeId&&!e.slotted&&(a=5),s.splice(a),t.codegenNode=Ju(e.helper(Tu),s,r)}};function Ch(t,e){let n,r='"default"';const i=[];for(let o=0;o<t.props.length;o++){const e=t.props[o];6===e.type?e.value&&("name"===e.name?r=JSON.stringify(e.value.content):(e.name=Ih(e.name),i.push(e))):"bind"===e.name&&_l(e.arg,"name")?e.exp&&(r=e.exp):("bind"===e.name&&e.arg&&rl(e.arg)&&(e.arg.content=Ih(e.arg.content)),i.push(e))}if(i.length>0){const{props:r,directives:o}=bh(t,e,i);n=r,o.length&&e.onError(nu(36,o[0].loc))}return{slotName:r,slotProps:n}}const Ph=/^\s*([\w$_]+|(async\s*)?\([^)]*?\))\s*=>|^\s*(async\s+)?function(?:\s+[\w$]+)?\s*\(/,Nh=(t,e,n,r)=>{const{loc:o,modifiers:s,arg:a}=t;let u;if(t.exp||s.length||n.onError(nu(35,o)),4===a.type)if(a.isStatic){let t=a.content;t.startsWith("vue:")&&(t=`vnode-${t.slice(4)}`),u=Ku((0,i.hR)((0,i._A)(t)),!0,a.loc)}else u=Zu([`${n.helperString(Mu)}(`,a,")"]);else u=a,u.children.unshift(`${n.helperString(Mu)}(`),u.children.push(")");let l=t.exp;l&&!l.content.trim()&&(l=void 0);let c=n.cacheHandlers&&!l&&!n.inVOnce;if(l){const t=fl(l.content),e=!(t||Ph.test(l.content)),n=l.content.includes(";");0,(e||c&&t)&&(l=Zu([`${e?"$event":"(...args)"} => ${n?"{":"("}`,l,n?"}":")"]))}let h={props:[qu(u,l||Ku("() => {}",!1,o))]};return r&&(h=r(h)),c&&(h.props[0].value=n.cache(h.props[0].value)),h.props.forEach((t=>t.key.isHandlerKey=!0)),h},Mh=(t,e,n)=>{const{exp:r,modifiers:o,loc:s}=t,a=t.arg;return 4!==a.type?(a.children.unshift("("),a.children.push(') || ""')):a.isStatic||(a.content=`${a.content} || ""`),o.includes("camel")&&(4===a.type?a.isStatic?a.content=(0,i._A)(a.content):a.content=`${n.helperString(Pu)}(${a.content})`:(a.children.unshift(`${n.helperString(Pu)}(`),a.children.push(")"))),n.inSSR||(o.includes("prop")&&Dh(a,"."),o.includes("attr")&&Dh(a,"^")),!r||4===r.type&&!r.content.trim()?(n.onError(nu(34,s)),{props:[qu(a,Ku("",!0,s))]}):{props:[qu(a,r)]}},Dh=(t,e)=>{4===t.type?t.isStatic?t.content=e+t.content:t.content=`\`${e}\${${t.content}}\``:(t.children.unshift(`'${e}' + (`),t.children.push(")"))},Lh=(t,e)=>{if(0===t.type||1===t.type||11===t.type||10===t.type)return()=>{const n=t.children;let r,i=!1;for(let t=0;t<n.length;t++){const e=n[t];if(bl(e)){i=!0;for(let i=t+1;i<n.length;i++){const o=n[i];if(!bl(o)){r=void 0;break}r||(r=n[t]={type:8,loc:e.loc,children:[e]}),r.children.push(" + ",o),n.splice(i,1),i--}}}if(i&&(1!==n.length||0!==t.type&&(1!==t.type||0!==t.tagType||t.props.find((t=>7===t.type&&!e.directiveTransforms[t.name]))||"template"===t.tag)))for(let t=0;t<n.length;t++){const r=n[t];if(bl(r)||8===r.type){const i=[];2===r.type&&" "===r.content||i.push(r),e.ssr||0!==pc(r,e)||i.push("1"),n[t]={type:12,content:r,loc:r.loc,codegenNode:Ju(e.helper(pu),i)}}}}},Bh=new WeakSet,Fh=(t,e)=>{if(1===t.type&&vl(t,"once",!0)){if(Bh.has(t)||e.inVOnce)return;return Bh.add(t),e.inVOnce=!0,e.helper(Du),()=>{e.inVOnce=!1;const t=e.currentNode;t.codegenNode&&(t.codegenNode=e.cache(t.codegenNode,!0))}}},Uh=(t,e,n)=>{const{exp:r,arg:i}=t;if(!r)return n.onError(nu(41,t.loc)),Gh();const o=r.loc.source,s=4===r.type?r.content:o;n.bindingMetadata[o];const a=!1;if(!s.trim()||!fl(s)&&!a)return n.onError(nu(42,r.loc)),Gh();const u=i||Ku("modelValue",!0),l=i?rl(i)?`onUpdate:${i.content}`:Zu(['"onUpdate:" + ',i]):"onUpdate:modelValue";let c;const h=n.isTS?"($event: any)":"$event";c=Zu([`${h} => ((`,r,") = $event)"]);const f=[qu(u,t.exp),qu(l,c)];if(t.modifiers.length&&1===e.tagType){const e=t.modifiers.map((t=>(al(t)?t:JSON.stringify(t))+": true")).join(", "),n=i?rl(i)?`${i.content}Modifiers`:Zu([i,' + "Modifiers"']):"modelModifiers";f.push(qu(n,Ku(`{ ${e} }`,!1,t.loc,2)))}return Gh(f)};function Gh(t=[]){return{props:t}}const kh=/[\w).+\-_$\]]/,Xh=(t,e)=>{Ml("COMPILER_FILTER",e)&&(5===t.type&&Hh(t.content,e),1===t.type&&t.props.forEach((t=>{7===t.type&&"for"!==t.name&&t.exp&&Hh(t.exp,e)})))};function Hh(t,e){if(4===t.type)jh(t,e);else for(let n=0;n<t.children.length;n++){const r=t.children[n];"object"===typeof r&&(4===r.type?jh(r,e):8===r.type?Hh(t,e):5===r.type&&Hh(r.content,e))}}function jh(t,e){const n=t.content;let r,i,o,s,a=!1,u=!1,l=!1,c=!1,h=0,f=0,d=0,p=0,m=[];for(o=0;o<n.length;o++)if(i=r,r=n.charCodeAt(o),a)39===r&&92!==i&&(a=!1);else if(u)34===r&&92!==i&&(u=!1);else if(l)96===r&&92!==i&&(l=!1);else if(c)47===r&&92!==i&&(c=!1);else if(124!==r||124===n.charCodeAt(o+1)||124===n.charCodeAt(o-1)||h||f||d){switch(r){case 34:u=!0;break;case 39:a=!0;break;case 96:l=!0;break;case 40:d++;break;case 41:d--;break;case 91:f++;break;case 93:f--;break;case 123:h++;break;case 125:h--;break}if(47===r){let t,e=o-1;for(;e>=0;e--)if(t=n.charAt(e)," "!==t)break;t&&kh.test(t)||(c=!0)}}else void 0===s?(p=o+1,s=n.slice(0,o).trim()):v();function v(){m.push(n.slice(p,o).trim()),p=o+1}if(void 0===s?s=n.slice(0,o).trim():0!==p&&v(),m.length){for(o=0;o<m.length;o++)s=Vh(s,m[o],e);t.content=s}}function Vh(t,e,n){n.helper(yu);const r=e.indexOf("(");if(r<0)return n.filters.add(e),`${wl(e,"filter")}(${t})`;{const i=e.slice(0,r),o=e.slice(r+1);return n.filters.add(i),`${wl(i,"filter")}(${t}${")"!==o?","+o:o}`}}const Yh=new WeakSet,Wh=(t,e)=>{if(1===t.type){const n=vl(t,"memo");if(!n||Yh.has(t))return;return Yh.add(t),()=>{const r=t.codegenNode||e.currentNode.codegenNode;r&&13===r.type&&(1!==t.tagType&&Pl(r,e),t.codegenNode=Ju(e.helper(ku),[n.exp,Qu(void 0,r),"_cache",String(e.cached++)]))}}};function zh(t){return[[Fh,qc,Wh,eh,Xh,wh,_h,hh,Lh],{on:Nh,bind:Mh,model:Uh}]}function $h(t,e={}){const n=e.onError||tu,r="module"===e.mode;!0===e.prefixIdentifiers?n(nu(46)):r&&n(nu(47));const o=!1;e.cacheHandlers&&n(nu(48)),e.scopeId&&!r&&n(nu(49));const s=(0,i.HD)(t)?Ul(t,e):t,[a,u]=zh();return Ec(s,(0,i.l7)({},e,{prefixIdentifiers:o,nodeTransforms:[...a,...e.nodeTransforms||[]],directiveTransforms:(0,i.l7)({},u,e.directiveTransforms||{})})),Ic(s,(0,i.l7)({},e,{prefixIdentifiers:o}))}const qh=()=>({props:[]}),Kh=Symbol(""),Zh=Symbol(""),Jh=Symbol(""),Qh=Symbol(""),tf=Symbol(""),ef=Symbol(""),nf=Symbol(""),rf=Symbol(""),of=Symbol(""),sf=Symbol("");let af;function uf(t,e=!1){return af||(af=document.createElement("div")),e?(af.innerHTML=`<div foo="${t.replace(/"/g,""")}">`,af.children[0].getAttribute("foo")):(af.innerHTML=t,af.textContent)}ju({[Kh]:"vModelRadio",[Zh]:"vModelCheckbox",[Jh]:"vModelText",[Qh]:"vModelSelect",[tf]:"vModelDynamic",[ef]:"withModifiers",[nf]:"withKeys",[rf]:"vShow",[of]:"Transition",[sf]:"TransitionGroup"});const lf=(0,i.fY)("style,iframe,script,noscript",!0),cf={isVoidTag:i.WB,isNativeTag:t=>(0,i.eS)(t)||(0,i.aN)(t),isPreTag:t=>"pre"===t,decodeEntities:uf,isBuiltInComponent:t=>il(t,"Transition")?of:il(t,"TransitionGroup")?sf:void 0,getNamespace(t,e){let n=e?e.ns:0;if(e&&2===n)if("annotation-xml"===e.tag){if("svg"===t)return 1;e.props.some((t=>6===t.type&&"encoding"===t.name&&null!=t.value&&("text/html"===t.value.content||"application/xhtml+xml"===t.value.content)))&&(n=0)}else/^m(?:[ions]|text)$/.test(e.tag)&&"mglyph"!==t&&"malignmark"!==t&&(n=0);else e&&1===n&&("foreignObject"!==e.tag&&"desc"!==e.tag&&"title"!==e.tag||(n=0));if(0===n){if("svg"===t)return 1;if("math"===t)return 2}return n},getTextMode({tag:t,ns:e}){if(0===e){if("textarea"===t||"title"===t)return 1;if(lf(t))return 2}return 0}},hf=t=>{1===t.type&&t.props.forEach(((e,n)=>{6===e.type&&"style"===e.name&&e.value&&(t.props[n]={type:7,name:"bind",arg:Ku("style",!0,e.loc),exp:ff(e.value.content,e.loc),modifiers:[],loc:e.loc})}))},ff=(t,e)=>{const n=(0,i.yL)(t);return Ku(JSON.stringify(n),!1,e,3)};function df(t,e){return nu(t,e,void 0)}const pf=(t,e,n)=>{const{exp:r,loc:i}=t;return r||n.onError(df(50,i)),e.children.length&&(n.onError(df(51,i)),e.children.length=0),{props:[qu(Ku("innerHTML",!0,i),r||Ku("",!0))]}},mf=(t,e,n)=>{const{exp:r,loc:i}=t;return r||n.onError(df(52,i)),e.children.length&&(n.onError(df(53,i)),e.children.length=0),{props:[qu(Ku("textContent",!0),r?Ju(n.helperString(Su),[r],i):Ku("",!0))]}},vf=(t,e,n)=>{const r=Uh(t,e,n);if(!r.props.length||1===e.tagType)return r;t.arg&&n.onError(df(55,t.arg.loc));const{tag:i}=e,o=n.isCustomElement(i);if("input"===i||"textarea"===i||"select"===i||o){let s=Jh,a=!1;if("input"===i||o){const r=gl(e,"type");if(r){if(7===r.type)s=tf;else if(r.value)switch(r.value.content){case"radio":s=Kh;break;case"checkbox":s=Zh;break;case"file":a=!0,n.onError(df(56,t.loc));break;default:break}}else yl(e)&&(s=tf)}else"select"===i&&(s=Qh);a||(r.needRuntime=n.helper(s))}else n.onError(df(54,t.loc));return r.props=r.props.filter((t=>!(4===t.key.type&&"modelValue"===t.key.content))),r},gf=(0,i.fY)("passive,once,capture"),_f=(0,i.fY)("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),yf=(0,i.fY)("left,right"),bf=(0,i.fY)("onkeyup,onkeydown,onkeypress",!0),Ef=(t,e,n,r)=>{const i=[],o=[],s=[];for(let a=0;a<e.length;a++){const u=e[a];"native"===u&&Dl("COMPILER_V_ON_NATIVE",n,r)||gf(u)?s.push(u):yf(u)?rl(t)?bf(t.content)?i.push(u):o.push(u):(i.push(u),o.push(u)):_f(u)?o.push(u):i.push(u)}return{keyModifiers:i,nonKeyModifiers:o,eventOptionModifiers:s}},Tf=(t,e)=>{const n=rl(t)&&"onclick"===t.content.toLowerCase();return n?Ku(e,!0):4!==t.type?Zu(["(",t,`) === "onClick" ? "${e}" : (`,t,")"]):t},xf=(t,e,n)=>Nh(t,e,n,(e=>{const{modifiers:r}=t;if(!r.length)return e;let{key:o,value:s}=e.props[0];const{keyModifiers:a,nonKeyModifiers:u,eventOptionModifiers:l}=Ef(o,r,n,t.loc);if(u.includes("right")&&(o=Tf(o,"onContextmenu")),u.includes("middle")&&(o=Tf(o,"onMouseup")),u.length&&(s=Ju(n.helper(ef),[s,JSON.stringify(u)])),!a.length||rl(o)&&!bf(o.content)||(s=Ju(n.helper(nf),[s,JSON.stringify(a)])),l.length){const t=l.map(i.kC).join("");o=rl(o)?Ku(`${o.content}${t}`,!0):Zu(["(",o,`) + "${t}"`])}return{props:[qu(o,s)]}})),Sf=(t,e,n)=>{const{exp:r,loc:i}=t;return r||n.onError(df(58,i)),{props:[],needRuntime:n.helper(rf)}};const Rf=(t,e)=>{1!==t.type||0!==t.tagType||"script"!==t.tag&&"style"!==t.tag||(e.onError(df(60,t.loc)),e.removeNode())},Af=[hf],Of={cloak:qh,html:pf,text:mf,model:vf,on:xf,show:Sf};function If(t,e={}){return $h(t,(0,i.l7)({},cf,e,{nodeTransforms:[Rf,...Af,...e.nodeTransforms||[]],directiveTransforms:(0,i.l7)({},Of,e.directiveTransforms||{}),transformHoist:null}))}const wf=Object.create(null);function Cf(t,e){if(!(0,i.HD)(t)){if(!t.nodeType)return i.dG;t=t.innerHTML}const n=t,o=wf[n];if(o)return o;if("#"===t[0]){const e=document.querySelector(t);0,t=e?e.innerHTML:""}const{code:s}=If(t,(0,i.l7)({hoistStatic:!0,onError:void 0,onWarn:i.dG},e));const a=new Function("Vue",s)(r);return a._rc=!0,wf[n]=a}Ui(Cf)},9980:function(t,e,n){(function(e,r){t.exports=r(n(4865),n(1474))})("undefined"!==typeof self&&self,(function(t,e){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="fb15")}({"00ee":function(t,e,n){var r=n("b622"),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},"0366":function(t,e,n){var r=n("1c0b");t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},"057f":function(t,e,n){var r=n("fc6a"),i=n("241c").f,o={}.toString,s="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],a=function(t){try{return i(t)}catch(e){return s.slice()}};t.exports.f=function(t){return s&&"[object Window]"==o.call(t)?a(t):i(r(t))}},"06cf":function(t,e,n){var r=n("83ab"),i=n("d1e7"),o=n("5c6c"),s=n("fc6a"),a=n("c04e"),u=n("5135"),l=n("0cfb"),c=Object.getOwnPropertyDescriptor;e.f=r?c:function(t,e){if(t=s(t),e=a(e,!0),l)try{return c(t,e)}catch(n){}if(u(t,e))return o(!i.f.call(t,e),t[e])}},"0cfb":function(t,e,n){var r=n("83ab"),i=n("d039"),o=n("cc12");t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},"13d5":function(t,e,n){"use strict";var r=n("23e7"),i=n("d58f").left,o=n("a640"),s=n("ae40"),a=o("reduce"),u=s("reduce",{1:0});r({target:"Array",proto:!0,forced:!a||!u},{reduce:function(t){return i(this,t,arguments.length,arguments.length>1?arguments[1]:void 0)}})},"14c3":function(t,e,n){var r=n("c6b6"),i=n("9263");t.exports=function(t,e){var n=t.exec;if("function"===typeof n){var o=n.call(t,e);if("object"!==typeof o)throw TypeError("RegExp exec method returned something other than an Object or null");return o}if("RegExp"!==r(t))throw TypeError("RegExp#exec called on incompatible receiver");return i.call(t,e)}},"159b":function(t,e,n){var r=n("da84"),i=n("fdbc"),o=n("17c2"),s=n("9112");for(var a in i){var u=r[a],l=u&&u.prototype;if(l&&l.forEach!==o)try{s(l,"forEach",o)}catch(c){l.forEach=o}}},"17c2":function(t,e,n){"use strict";var r=n("b727").forEach,i=n("a640"),o=n("ae40"),s=i("forEach"),a=o("forEach");t.exports=s&&a?[].forEach:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}},"1be4":function(t,e,n){var r=n("d066");t.exports=r("document","documentElement")},"1c0b":function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},"1c7e":function(t,e,n){var r=n("b622"),i=r("iterator"),o=!1;try{var s=0,a={next:function(){return{done:!!s++}},return:function(){o=!0}};a[i]=function(){return this},Array.from(a,(function(){throw 2}))}catch(u){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var r={};r[i]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(u){}return n}},"1d80":function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},"1dde":function(t,e,n){var r=n("d039"),i=n("b622"),o=n("2d00"),s=i("species");t.exports=function(t){return o>=51||!r((function(){var e=[],n=e.constructor={};return n[s]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},"23cb":function(t,e,n){var r=n("a691"),i=Math.max,o=Math.min;t.exports=function(t,e){var n=r(t);return n<0?i(n+e,0):o(n,e)}},"23e7":function(t,e,n){var r=n("da84"),i=n("06cf").f,o=n("9112"),s=n("6eeb"),a=n("ce4e"),u=n("e893"),l=n("94ca");t.exports=function(t,e){var n,c,h,f,d,p,m=t.target,v=t.global,g=t.stat;if(c=v?r:g?r[m]||a(m,{}):(r[m]||{}).prototype,c)for(h in e){if(d=e[h],t.noTargetGet?(p=i(c,h),f=p&&p.value):f=c[h],n=l(v?h:m+(g?".":"#")+h,t.forced),!n&&void 0!==f){if(typeof d===typeof f)continue;u(d,f)}(t.sham||f&&f.sham)&&o(d,"sham",!0),s(c,h,d,t)}}},"241c":function(t,e,n){var r=n("ca84"),i=n("7839"),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},"25f0":function(t,e,n){"use strict";var r=n("6eeb"),i=n("825a"),o=n("d039"),s=n("ad6d"),a="toString",u=RegExp.prototype,l=u[a],c=o((function(){return"/a/b"!=l.call({source:"a",flags:"b"})})),h=l.name!=a;(c||h)&&r(RegExp.prototype,a,(function(){var t=i(this),e=String(t.source),n=t.flags,r=String(void 0===n&&t instanceof RegExp&&!("flags"in u)?s.call(t):n);return"/"+e+"/"+r}),{unsafe:!0})},"2ca0":function(t,e,n){"use strict";var r=n("23e7"),i=n("06cf").f,o=n("50c4"),s=n("5a34"),a=n("1d80"),u=n("ab13"),l=n("c430"),c="".startsWith,h=Math.min,f=u("startsWith"),d=!l&&!f&&!!function(){var t=i(String.prototype,"startsWith");return t&&!t.writable}();r({target:"String",proto:!0,forced:!d&&!f},{startsWith:function(t){var e=String(a(this));s(t);var n=o(h(arguments.length>1?arguments[1]:void 0,e.length)),r=String(t);return c?c.call(e,r,n):e.slice(n,n+r.length)===r}})},"2d00":function(t,e,n){var r,i,o=n("da84"),s=n("342f"),a=o.process,u=a&&a.versions,l=u&&u.v8;l?(r=l.split("."),i=r[0]+r[1]):s&&(r=s.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=s.match(/Chrome\/(\d+)/),r&&(i=r[1]))),t.exports=i&&+i},"342f":function(t,e,n){var r=n("d066");t.exports=r("navigator","userAgent")||""},"35a1":function(t,e,n){var r=n("f5df"),i=n("3f8c"),o=n("b622"),s=o("iterator");t.exports=function(t){if(void 0!=t)return t[s]||t["@@iterator"]||i[r(t)]}},"37e8":function(t,e,n){var r=n("83ab"),i=n("9bf2"),o=n("825a"),s=n("df75");t.exports=r?Object.defineProperties:function(t,e){o(t);var n,r=s(e),a=r.length,u=0;while(a>u)i.f(t,n=r[u++],e[n]);return t}},"3bbe":function(t,e,n){var r=n("861d");t.exports=function(t){if(!r(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t}},"3ca3":function(t,e,n){"use strict";var r=n("6547").charAt,i=n("69f3"),o=n("7dd0"),s="String Iterator",a=i.set,u=i.getterFor(s);o(String,"String",(function(t){a(this,{type:s,string:String(t),index:0})}),(function(){var t,e=u(this),n=e.string,i=e.index;return i>=n.length?{value:void 0,done:!0}:(t=r(n,i),e.index+=t.length,{value:t,done:!1})}))},"3f8c":function(t,e){t.exports={}},4160:function(t,e,n){"use strict";var r=n("23e7"),i=n("17c2");r({target:"Array",proto:!0,forced:[].forEach!=i},{forEach:i})},"428f":function(t,e,n){var r=n("da84");t.exports=r},"44ad":function(t,e,n){var r=n("d039"),i=n("c6b6"),o="".split;t.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==i(t)?o.call(t,""):Object(t)}:Object},"44d2":function(t,e,n){var r=n("b622"),i=n("7c73"),o=n("9bf2"),s=r("unscopables"),a=Array.prototype;void 0==a[s]&&o.f(a,s,{configurable:!0,value:i(null)}),t.exports=function(t){a[s][t]=!0}},"44e7":function(t,e,n){var r=n("861d"),i=n("c6b6"),o=n("b622"),s=o("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[s])?!!e:"RegExp"==i(t))}},4930:function(t,e,n){var r=n("d039");t.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},"4d64":function(t,e,n){var r=n("fc6a"),i=n("50c4"),o=n("23cb"),s=function(t){return function(e,n,s){var a,u=r(e),l=i(u.length),c=o(s,l);if(t&&n!=n){while(l>c)if(a=u[c++],a!=a)return!0}else for(;l>c;c++)if((t||c in u)&&u[c]===n)return t||c||0;return!t&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},"4de4":function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").filter,o=n("1dde"),s=n("ae40"),a=o("filter"),u=s("filter");r({target:"Array",proto:!0,forced:!a||!u},{filter:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"4df4":function(t,e,n){"use strict";var r=n("0366"),i=n("7b0b"),o=n("9bdd"),s=n("e95a"),a=n("50c4"),u=n("8418"),l=n("35a1");t.exports=function(t){var e,n,c,h,f,d,p=i(t),m="function"==typeof this?this:Array,v=arguments.length,g=v>1?arguments[1]:void 0,_=void 0!==g,y=l(p),b=0;if(_&&(g=r(g,v>2?arguments[2]:void 0,2)),void 0==y||m==Array&&s(y))for(e=a(p.length),n=new m(e);e>b;b++)d=_?g(p[b],b):p[b],u(n,b,d);else for(h=y.call(p),f=h.next,n=new m;!(c=f.call(h)).done;b++)d=_?o(h,g,[c.value,b],!0):c.value,u(n,b,d);return n.length=b,n}},"4fad":function(t,e,n){var r=n("23e7"),i=n("6f53").entries;r({target:"Object",stat:!0},{entries:function(t){return i(t)}})},"50c4":function(t,e,n){var r=n("a691"),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},5135:function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},5319:function(t,e,n){"use strict";var r=n("d784"),i=n("825a"),o=n("7b0b"),s=n("50c4"),a=n("a691"),u=n("1d80"),l=n("8aa5"),c=n("14c3"),h=Math.max,f=Math.min,d=Math.floor,p=/\$([$&'`]|\d\d?|<[^>]*>)/g,m=/\$([$&'`]|\d\d?)/g,v=function(t){return void 0===t?t:String(t)};r("replace",2,(function(t,e,n,r){var g=r.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE,_=r.REPLACE_KEEPS_$0,y=g?"$":"$0";return[function(n,r){var i=u(this),o=void 0==n?void 0:n[t];return void 0!==o?o.call(n,i,r):e.call(String(i),n,r)},function(t,r){if(!g&&_||"string"===typeof r&&-1===r.indexOf(y)){var o=n(e,t,this,r);if(o.done)return o.value}var u=i(t),d=String(this),p="function"===typeof r;p||(r=String(r));var m=u.global;if(m){var E=u.unicode;u.lastIndex=0}var T=[];while(1){var x=c(u,d);if(null===x)break;if(T.push(x),!m)break;var S=String(x[0]);""===S&&(u.lastIndex=l(d,s(u.lastIndex),E))}for(var R="",A=0,O=0;O<T.length;O++){x=T[O];for(var I=String(x[0]),w=h(f(a(x.index),d.length),0),C=[],P=1;P<x.length;P++)C.push(v(x[P]));var N=x.groups;if(p){var M=[I].concat(C,w,d);void 0!==N&&M.push(N);var D=String(r.apply(void 0,M))}else D=b(I,d,w,C,N,r);w>=A&&(R+=d.slice(A,w)+D,A=w+I.length)}return R+d.slice(A)}];function b(t,n,r,i,s,a){var u=r+t.length,l=i.length,c=m;return void 0!==s&&(s=o(s),c=p),e.call(a,c,(function(e,o){var a;switch(o.charAt(0)){case"$":return"$";case"&":return t;case"`":return n.slice(0,r);case"'":return n.slice(u);case"<":a=s[o.slice(1,-1)];break;default:var c=+o;if(0===c)return e;if(c>l){var h=d(c/10);return 0===h?e:h<=l?void 0===i[h-1]?o.charAt(1):i[h-1]+o.charAt(1):e}a=i[c-1]}return void 0===a?"":a}))}}))},5692:function(t,e,n){var r=n("c430"),i=n("c6cd");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.6.5",mode:r?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},"56ef":function(t,e,n){var r=n("d066"),i=n("241c"),o=n("7418"),s=n("825a");t.exports=r("Reflect","ownKeys")||function(t){var e=i.f(s(t)),n=o.f;return n?e.concat(n(t)):e}},"5a34":function(t,e,n){var r=n("44e7");t.exports=function(t){if(r(t))throw TypeError("The method doesn't accept regular expressions");return t}},"5c6c":function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},"5db7":function(t,e,n){"use strict";var r=n("23e7"),i=n("a2bf"),o=n("7b0b"),s=n("50c4"),a=n("1c0b"),u=n("65f0");r({target:"Array",proto:!0},{flatMap:function(t){var e,n=o(this),r=s(n.length);return a(t),e=u(n,0),e.length=i(e,n,n,r,0,1,t,arguments.length>1?arguments[1]:void 0),e}})},6547:function(t,e,n){var r=n("a691"),i=n("1d80"),o=function(t){return function(e,n){var o,s,a=String(i(e)),u=r(n),l=a.length;return u<0||u>=l?t?"":void 0:(o=a.charCodeAt(u),o<55296||o>56319||u+1===l||(s=a.charCodeAt(u+1))<56320||s>57343?t?a.charAt(u):o:t?a.slice(u,u+2):s-56320+(o-55296<<10)+65536)}};t.exports={codeAt:o(!1),charAt:o(!0)}},"65f0":function(t,e,n){var r=n("861d"),i=n("e8b5"),o=n("b622"),s=o("species");t.exports=function(t,e){var n;return i(t)&&(n=t.constructor,"function"!=typeof n||n!==Array&&!i(n.prototype)?r(n)&&(n=n[s],null===n&&(n=void 0)):n=void 0),new(void 0===n?Array:n)(0===e?0:e)}},"69f3":function(t,e,n){var r,i,o,s=n("7f9a"),a=n("da84"),u=n("861d"),l=n("9112"),c=n("5135"),h=n("f772"),f=n("d012"),d=a.WeakMap,p=function(t){return o(t)?i(t):r(t,{})},m=function(t){return function(e){var n;if(!u(e)||(n=i(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}};if(s){var v=new d,g=v.get,_=v.has,y=v.set;r=function(t,e){return y.call(v,t,e),e},i=function(t){return g.call(v,t)||{}},o=function(t){return _.call(v,t)}}else{var b=h("state");f[b]=!0,r=function(t,e){return l(t,b,e),e},i=function(t){return c(t,b)?t[b]:{}},o=function(t){return c(t,b)}}t.exports={set:r,get:i,has:o,enforce:p,getterFor:m}},"6eeb":function(t,e,n){var r=n("da84"),i=n("9112"),o=n("5135"),s=n("ce4e"),a=n("8925"),u=n("69f3"),l=u.get,c=u.enforce,h=String(String).split("String");(t.exports=function(t,e,n,a){var u=!!a&&!!a.unsafe,l=!!a&&!!a.enumerable,f=!!a&&!!a.noTargetGet;"function"==typeof n&&("string"!=typeof e||o(n,"name")||i(n,"name",e),c(n).source=h.join("string"==typeof e?e:"")),t!==r?(u?!f&&t[e]&&(l=!0):delete t[e],l?t[e]=n:i(t,e,n)):l?t[e]=n:s(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&l(this).source||a(this)}))},"6f53":function(t,e,n){var r=n("83ab"),i=n("df75"),o=n("fc6a"),s=n("d1e7").f,a=function(t){return function(e){var n,a=o(e),u=i(a),l=u.length,c=0,h=[];while(l>c)n=u[c++],r&&!s.call(a,n)||h.push(t?[n,a[n]]:a[n]);return h}};t.exports={entries:a(!0),values:a(!1)}},"73d9":function(t,e,n){var r=n("44d2");r("flatMap")},7418:function(t,e){e.f=Object.getOwnPropertySymbols},"746f":function(t,e,n){var r=n("428f"),i=n("5135"),o=n("e538"),s=n("9bf2").f;t.exports=function(t){var e=r.Symbol||(r.Symbol={});i(e,t)||s(e,t,{value:o.f(t)})}},7839:function(t,e){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},"7b0b":function(t,e,n){var r=n("1d80");t.exports=function(t){return Object(r(t))}},"7c73":function(t,e,n){var r,i=n("825a"),o=n("37e8"),s=n("7839"),a=n("d012"),u=n("1be4"),l=n("cc12"),c=n("f772"),h=">",f="<",d="prototype",p="script",m=c("IE_PROTO"),v=function(){},g=function(t){return f+p+h+t+f+"/"+p+h},_=function(t){t.write(g("")),t.close();var e=t.parentWindow.Object;return t=null,e},y=function(){var t,e=l("iframe"),n="java"+p+":";return e.style.display="none",u.appendChild(e),e.src=String(n),t=e.contentWindow.document,t.open(),t.write(g("document.F=Object")),t.close(),t.F},b=function(){try{r=document.domain&&new ActiveXObject("htmlfile")}catch(e){}b=r?_(r):y();var t=s.length;while(t--)delete b[d][s[t]];return b()};a[m]=!0,t.exports=Object.create||function(t,e){var n;return null!==t?(v[d]=i(t),n=new v,v[d]=null,n[m]=t):n=b(),void 0===e?n:o(n,e)}},"7dd0":function(t,e,n){"use strict";var r=n("23e7"),i=n("9ed3"),o=n("e163"),s=n("d2bb"),a=n("d44e"),u=n("9112"),l=n("6eeb"),c=n("b622"),h=n("c430"),f=n("3f8c"),d=n("ae93"),p=d.IteratorPrototype,m=d.BUGGY_SAFARI_ITERATORS,v=c("iterator"),g="keys",_="values",y="entries",b=function(){return this};t.exports=function(t,e,n,c,d,E,T){i(n,e,c);var x,S,R,A=function(t){if(t===d&&P)return P;if(!m&&t in w)return w[t];switch(t){case g:return function(){return new n(this,t)};case _:return function(){return new n(this,t)};case y:return function(){return new n(this,t)}}return function(){return new n(this)}},O=e+" Iterator",I=!1,w=t.prototype,C=w[v]||w["@@iterator"]||d&&w[d],P=!m&&C||A(d),N="Array"==e&&w.entries||C;if(N&&(x=o(N.call(new t)),p!==Object.prototype&&x.next&&(h||o(x)===p||(s?s(x,p):"function"!=typeof x[v]&&u(x,v,b)),a(x,O,!0,!0),h&&(f[O]=b))),d==_&&C&&C.name!==_&&(I=!0,P=function(){return C.call(this)}),h&&!T||w[v]===P||u(w,v,P),f[e]=P,d)if(S={values:A(_),keys:E?P:A(g),entries:A(y)},T)for(R in S)(m||I||!(R in w))&&l(w,R,S[R]);else r({target:e,proto:!0,forced:m||I},S);return S}},"7f9a":function(t,e,n){var r=n("da84"),i=n("8925"),o=r.WeakMap;t.exports="function"===typeof o&&/native code/.test(i(o))},"825a":function(t,e,n){var r=n("861d");t.exports=function(t){if(!r(t))throw TypeError(String(t)+" is not an object");return t}},"83ab":function(t,e,n){var r=n("d039");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},8418:function(t,e,n){"use strict";var r=n("c04e"),i=n("9bf2"),o=n("5c6c");t.exports=function(t,e,n){var s=r(e);s in t?i.f(t,s,o(0,n)):t[s]=n}},"861d":function(t,e){t.exports=function(t){return"object"===typeof t?null!==t:"function"===typeof t}},8875:function(t,e,n){var r,i,o;(function(n,s){i=[],r=s,o="function"===typeof r?r.apply(e,i):r,void 0===o||(t.exports=o)})("undefined"!==typeof self&&self,(function(){function t(){var e=Object.getOwnPropertyDescriptor(document,"currentScript");if(!e&&"currentScript"in document&&document.currentScript)return document.currentScript;if(e&&e.get!==t&&document.currentScript)return document.currentScript;try{throw new Error}catch(d){var n,r,i,o=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,s=/@([^@]*):(\d+):(\d+)\s*$/gi,a=o.exec(d.stack)||s.exec(d.stack),u=a&&a[1]||!1,l=a&&a[2]||!1,c=document.location.href.replace(document.location.hash,""),h=document.getElementsByTagName("script");u===c&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(l-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),i=n.replace(r,"$1").trim());for(var f=0;f<h.length;f++){if("interactive"===h[f].readyState)return h[f];if(h[f].src===u)return h[f];if(u===c&&h[f].innerHTML&&h[f].innerHTML.trim()===i)return h[f]}return null}}return t}))},8925:function(t,e,n){var r=n("c6cd"),i=Function.toString;"function"!=typeof r.inspectSource&&(r.inspectSource=function(t){return i.call(t)}),t.exports=r.inspectSource},"8aa5":function(t,e,n){"use strict";var r=n("6547").charAt;t.exports=function(t,e,n){return e+(n?r(t,e).length:1)}},"8bbf":function(e,n){e.exports=t},"90e3":function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++n+r).toString(36)}},9112:function(t,e,n){var r=n("83ab"),i=n("9bf2"),o=n("5c6c");t.exports=r?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},9263:function(t,e,n){"use strict";var r=n("ad6d"),i=n("9f7f"),o=RegExp.prototype.exec,s=String.prototype.replace,a=o,u=function(){var t=/a/,e=/b*/g;return o.call(t,"a"),o.call(e,"a"),0!==t.lastIndex||0!==e.lastIndex}(),l=i.UNSUPPORTED_Y||i.BROKEN_CARET,c=void 0!==/()??/.exec("")[1],h=u||c||l;h&&(a=function(t){var e,n,i,a,h=this,f=l&&h.sticky,d=r.call(h),p=h.source,m=0,v=t;return f&&(d=d.replace("y",""),-1===d.indexOf("g")&&(d+="g"),v=String(t).slice(h.lastIndex),h.lastIndex>0&&(!h.multiline||h.multiline&&"\n"!==t[h.lastIndex-1])&&(p="(?: "+p+")",v=" "+v,m++),n=new RegExp("^(?:"+p+")",d)),c&&(n=new RegExp("^"+p+"$(?!\\s)",d)),u&&(e=h.lastIndex),i=o.call(f?n:h,v),f?i?(i.input=i.input.slice(m),i[0]=i[0].slice(m),i.index=h.lastIndex,h.lastIndex+=i[0].length):h.lastIndex=0:u&&i&&(h.lastIndex=h.global?i.index+i[0].length:e),c&&i&&i.length>1&&s.call(i[0],n,(function(){for(a=1;a<arguments.length-2;a++)void 0===arguments[a]&&(i[a]=void 0)})),i}),t.exports=a},"94ca":function(t,e,n){var r=n("d039"),i=/#|\.prototype\./,o=function(t,e){var n=a[s(t)];return n==l||n!=u&&("function"==typeof e?r(e):!!e)},s=o.normalize=function(t){return String(t).replace(i,".").toLowerCase()},a=o.data={},u=o.NATIVE="N",l=o.POLYFILL="P";t.exports=o},"99af":function(t,e,n){"use strict";var r=n("23e7"),i=n("d039"),o=n("e8b5"),s=n("861d"),a=n("7b0b"),u=n("50c4"),l=n("8418"),c=n("65f0"),h=n("1dde"),f=n("b622"),d=n("2d00"),p=f("isConcatSpreadable"),m=9007199254740991,v="Maximum allowed index exceeded",g=d>=51||!i((function(){var t=[];return t[p]=!1,t.concat()[0]!==t})),_=h("concat"),y=function(t){if(!s(t))return!1;var e=t[p];return void 0!==e?!!e:o(t)},b=!g||!_;r({target:"Array",proto:!0,forced:b},{concat:function(t){var e,n,r,i,o,s=a(this),h=c(s,0),f=0;for(e=-1,r=arguments.length;e<r;e++)if(o=-1===e?s:arguments[e],y(o)){if(i=u(o.length),f+i>m)throw TypeError(v);for(n=0;n<i;n++,f++)n in o&&l(h,f,o[n])}else{if(f>=m)throw TypeError(v);l(h,f++,o)}return h.length=f,h}})},"9bdd":function(t,e,n){var r=n("825a");t.exports=function(t,e,n,i){try{return i?e(r(n)[0],n[1]):e(n)}catch(s){var o=t["return"];throw void 0!==o&&r(o.call(t)),s}}},"9bf2":function(t,e,n){var r=n("83ab"),i=n("0cfb"),o=n("825a"),s=n("c04e"),a=Object.defineProperty;e.f=r?a:function(t,e,n){if(o(t),e=s(e,!0),o(n),i)try{return a(t,e,n)}catch(r){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},"9ed3":function(t,e,n){"use strict";var r=n("ae93").IteratorPrototype,i=n("7c73"),o=n("5c6c"),s=n("d44e"),a=n("3f8c"),u=function(){return this};t.exports=function(t,e,n){var l=e+" Iterator";return t.prototype=i(r,{next:o(1,n)}),s(t,l,!1,!0),a[l]=u,t}},"9f7f":function(t,e,n){"use strict";var r=n("d039");function i(t,e){return RegExp(t,e)}e.UNSUPPORTED_Y=r((function(){var t=i("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),e.BROKEN_CARET=r((function(){var t=i("^r","gy");return t.lastIndex=2,null!=t.exec("str")}))},a2bf:function(t,e,n){"use strict";var r=n("e8b5"),i=n("50c4"),o=n("0366"),s=function(t,e,n,a,u,l,c,h){var f,d=u,p=0,m=!!c&&o(c,h,3);while(p<a){if(p in n){if(f=m?m(n[p],p,e):n[p],l>0&&r(f))d=s(t,e,f,i(f.length),d,l-1)-1;else{if(d>=9007199254740991)throw TypeError("Exceed the acceptable array length");t[d]=f}d++}p++}return d};t.exports=s},a352:function(t,n){t.exports=e},a434:function(t,e,n){"use strict";var r=n("23e7"),i=n("23cb"),o=n("a691"),s=n("50c4"),a=n("7b0b"),u=n("65f0"),l=n("8418"),c=n("1dde"),h=n("ae40"),f=c("splice"),d=h("splice",{ACCESSORS:!0,0:0,1:2}),p=Math.max,m=Math.min,v=9007199254740991,g="Maximum allowed length exceeded";r({target:"Array",proto:!0,forced:!f||!d},{splice:function(t,e){var n,r,c,h,f,d,_=a(this),y=s(_.length),b=i(t,y),E=arguments.length;if(0===E?n=r=0:1===E?(n=0,r=y-b):(n=E-2,r=m(p(o(e),0),y-b)),y+n-r>v)throw TypeError(g);for(c=u(_,r),h=0;h<r;h++)f=b+h,f in _&&l(c,h,_[f]);if(c.length=r,n<r){for(h=b;h<y-r;h++)f=h+r,d=h+n,f in _?_[d]=_[f]:delete _[d];for(h=y;h>y-r+n;h--)delete _[h-1]}else if(n>r)for(h=y-r;h>b;h--)f=h+r-1,d=h+n-1,f in _?_[d]=_[f]:delete _[d];for(h=0;h<n;h++)_[h+b]=arguments[h+2];return _.length=y-r+n,c}})},a4d3:function(t,e,n){"use strict";var r=n("23e7"),i=n("da84"),o=n("d066"),s=n("c430"),a=n("83ab"),u=n("4930"),l=n("fdbf"),c=n("d039"),h=n("5135"),f=n("e8b5"),d=n("861d"),p=n("825a"),m=n("7b0b"),v=n("fc6a"),g=n("c04e"),_=n("5c6c"),y=n("7c73"),b=n("df75"),E=n("241c"),T=n("057f"),x=n("7418"),S=n("06cf"),R=n("9bf2"),A=n("d1e7"),O=n("9112"),I=n("6eeb"),w=n("5692"),C=n("f772"),P=n("d012"),N=n("90e3"),M=n("b622"),D=n("e538"),L=n("746f"),B=n("d44e"),F=n("69f3"),U=n("b727").forEach,G=C("hidden"),k="Symbol",X="prototype",H=M("toPrimitive"),j=F.set,V=F.getterFor(k),Y=Object[X],W=i.Symbol,z=o("JSON","stringify"),$=S.f,q=R.f,K=T.f,Z=A.f,J=w("symbols"),Q=w("op-symbols"),tt=w("string-to-symbol-registry"),et=w("symbol-to-string-registry"),nt=w("wks"),rt=i.QObject,it=!rt||!rt[X]||!rt[X].findChild,ot=a&&c((function(){return 7!=y(q({},"a",{get:function(){return q(this,"a",{value:7}).a}})).a}))?function(t,e,n){var r=$(Y,e);r&&delete Y[e],q(t,e,n),r&&t!==Y&&q(Y,e,r)}:q,st=function(t,e){var n=J[t]=y(W[X]);return j(n,{type:k,tag:t,description:e}),a||(n.description=e),n},at=l?function(t){return"symbol"==typeof t}:function(t){return Object(t)instanceof W},ut=function(t,e,n){t===Y&&ut(Q,e,n),p(t);var r=g(e,!0);return p(n),h(J,r)?(n.enumerable?(h(t,G)&&t[G][r]&&(t[G][r]=!1),n=y(n,{enumerable:_(0,!1)})):(h(t,G)||q(t,G,_(1,{})),t[G][r]=!0),ot(t,r,n)):q(t,r,n)},lt=function(t,e){p(t);var n=v(e),r=b(n).concat(pt(n));return U(r,(function(e){a&&!ht.call(n,e)||ut(t,e,n[e])})),t},ct=function(t,e){return void 0===e?y(t):lt(y(t),e)},ht=function(t){var e=g(t,!0),n=Z.call(this,e);return!(this===Y&&h(J,e)&&!h(Q,e))&&(!(n||!h(this,e)||!h(J,e)||h(this,G)&&this[G][e])||n)},ft=function(t,e){var n=v(t),r=g(e,!0);if(n!==Y||!h(J,r)||h(Q,r)){var i=$(n,r);return!i||!h(J,r)||h(n,G)&&n[G][r]||(i.enumerable=!0),i}},dt=function(t){var e=K(v(t)),n=[];return U(e,(function(t){h(J,t)||h(P,t)||n.push(t)})),n},pt=function(t){var e=t===Y,n=K(e?Q:v(t)),r=[];return U(n,(function(t){!h(J,t)||e&&!h(Y,t)||r.push(J[t])})),r};if(u||(W=function(){if(this instanceof W)throw TypeError("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,e=N(t),n=function(t){this===Y&&n.call(Q,t),h(this,G)&&h(this[G],e)&&(this[G][e]=!1),ot(this,e,_(1,t))};return a&&it&&ot(Y,e,{configurable:!0,set:n}),st(e,t)},I(W[X],"toString",(function(){return V(this).tag})),I(W,"withoutSetter",(function(t){return st(N(t),t)})),A.f=ht,R.f=ut,S.f=ft,E.f=T.f=dt,x.f=pt,D.f=function(t){return st(M(t),t)},a&&(q(W[X],"description",{configurable:!0,get:function(){return V(this).description}}),s||I(Y,"propertyIsEnumerable",ht,{unsafe:!0}))),r({global:!0,wrap:!0,forced:!u,sham:!u},{Symbol:W}),U(b(nt),(function(t){L(t)})),r({target:k,stat:!0,forced:!u},{for:function(t){var e=String(t);if(h(tt,e))return tt[e];var n=W(e);return tt[e]=n,et[n]=e,n},keyFor:function(t){if(!at(t))throw TypeError(t+" is not a symbol");if(h(et,t))return et[t]},useSetter:function(){it=!0},useSimple:function(){it=!1}}),r({target:"Object",stat:!0,forced:!u,sham:!a},{create:ct,defineProperty:ut,defineProperties:lt,getOwnPropertyDescriptor:ft}),r({target:"Object",stat:!0,forced:!u},{getOwnPropertyNames:dt,getOwnPropertySymbols:pt}),r({target:"Object",stat:!0,forced:c((function(){x.f(1)}))},{getOwnPropertySymbols:function(t){return x.f(m(t))}}),z){var mt=!u||c((function(){var t=W();return"[null]"!=z([t])||"{}"!=z({a:t})||"{}"!=z(Object(t))}));r({target:"JSON",stat:!0,forced:mt},{stringify:function(t,e,n){var r,i=[t],o=1;while(arguments.length>o)i.push(arguments[o++]);if(r=e,(d(e)||void 0!==t)&&!at(t))return f(e)||(e=function(t,e){if("function"==typeof r&&(e=r.call(this,t,e)),!at(e))return e}),i[1]=e,z.apply(null,i)}})}W[X][H]||O(W[X],H,W[X].valueOf),B(W,k),P[G]=!0},a630:function(t,e,n){var r=n("23e7"),i=n("4df4"),o=n("1c7e"),s=!o((function(t){Array.from(t)}));r({target:"Array",stat:!0,forced:s},{from:i})},a640:function(t,e,n){"use strict";var r=n("d039");t.exports=function(t,e){var n=[][t];return!!n&&r((function(){n.call(null,e||function(){throw 1},1)}))}},a691:function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},ab13:function(t,e,n){var r=n("b622"),i=r("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[i]=!1,"/./"[t](e)}catch(r){}}return!1}},ac1f:function(t,e,n){"use strict";var r=n("23e7"),i=n("9263");r({target:"RegExp",proto:!0,forced:/./.exec!==i},{exec:i})},ad6d:function(t,e,n){"use strict";var r=n("825a");t.exports=function(){var t=r(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},ae40:function(t,e,n){var r=n("83ab"),i=n("d039"),o=n("5135"),s=Object.defineProperty,a={},u=function(t){throw t};t.exports=function(t,e){if(o(a,t))return a[t];e||(e={});var n=[][t],l=!!o(e,"ACCESSORS")&&e.ACCESSORS,c=o(e,0)?e[0]:u,h=o(e,1)?e[1]:void 0;return a[t]=!!n&&!i((function(){if(l&&!r)return!0;var t={length:-1};l?s(t,1,{enumerable:!0,get:u}):t[1]=1,n.call(t,c,h)}))}},ae93:function(t,e,n){"use strict";var r,i,o,s=n("e163"),a=n("9112"),u=n("5135"),l=n("b622"),c=n("c430"),h=l("iterator"),f=!1,d=function(){return this};[].keys&&(o=[].keys(),"next"in o?(i=s(s(o)),i!==Object.prototype&&(r=i)):f=!0),void 0==r&&(r={}),c||u(r,h)||a(r,h,d),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:f}},b041:function(t,e,n){"use strict";var r=n("00ee"),i=n("f5df");t.exports=r?{}.toString:function(){return"[object "+i(this)+"]"}},b0c0:function(t,e,n){var r=n("83ab"),i=n("9bf2").f,o=Function.prototype,s=o.toString,a=/^\s*function ([^ (]*)/,u="name";r&&!(u in o)&&i(o,u,{configurable:!0,get:function(){try{return s.call(this).match(a)[1]}catch(t){return""}}})},b622:function(t,e,n){var r=n("da84"),i=n("5692"),o=n("5135"),s=n("90e3"),a=n("4930"),u=n("fdbf"),l=i("wks"),c=r.Symbol,h=u?c:c&&c.withoutSetter||s;t.exports=function(t){return o(l,t)||(a&&o(c,t)?l[t]=c[t]:l[t]=h("Symbol."+t)),l[t]}},b64b:function(t,e,n){var r=n("23e7"),i=n("7b0b"),o=n("df75"),s=n("d039"),a=s((function(){o(1)}));r({target:"Object",stat:!0,forced:a},{keys:function(t){return o(i(t))}})},b727:function(t,e,n){var r=n("0366"),i=n("44ad"),o=n("7b0b"),s=n("50c4"),a=n("65f0"),u=[].push,l=function(t){var e=1==t,n=2==t,l=3==t,c=4==t,h=6==t,f=5==t||h;return function(d,p,m,v){for(var g,_,y=o(d),b=i(y),E=r(p,m,3),T=s(b.length),x=0,S=v||a,R=e?S(d,T):n?S(d,0):void 0;T>x;x++)if((f||x in b)&&(g=b[x],_=E(g,x,y),t))if(e)R[x]=_;else if(_)switch(t){case 3:return!0;case 5:return g;case 6:return x;case 2:u.call(R,g)}else if(c)return!1;return h?-1:l||c?c:R}};t.exports={forEach:l(0),map:l(1),filter:l(2),some:l(3),every:l(4),find:l(5),findIndex:l(6)}},c04e:function(t,e,n){var r=n("861d");t.exports=function(t,e){if(!r(t))return t;var n,i;if(e&&"function"==typeof(n=t.toString)&&!r(i=n.call(t)))return i;if("function"==typeof(n=t.valueOf)&&!r(i=n.call(t)))return i;if(!e&&"function"==typeof(n=t.toString)&&!r(i=n.call(t)))return i;throw TypeError("Can't convert object to primitive value")}},c430:function(t,e){t.exports=!1},c6b6:function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},c6cd:function(t,e,n){var r=n("da84"),i=n("ce4e"),o="__core-js_shared__",s=r[o]||i(o,{});t.exports=s},c740:function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").findIndex,o=n("44d2"),s=n("ae40"),a="findIndex",u=!0,l=s(a);a in[]&&Array(1)[a]((function(){u=!1})),r({target:"Array",proto:!0,forced:u||!l},{findIndex:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o(a)},c8ba:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}t.exports=n},c975:function(t,e,n){"use strict";var r=n("23e7"),i=n("4d64").indexOf,o=n("a640"),s=n("ae40"),a=[].indexOf,u=!!a&&1/[1].indexOf(1,-0)<0,l=o("indexOf"),c=s("indexOf",{ACCESSORS:!0,1:0});r({target:"Array",proto:!0,forced:u||!l||!c},{indexOf:function(t){return u?a.apply(this,arguments)||0:i(this,t,arguments.length>1?arguments[1]:void 0)}})},ca84:function(t,e,n){var r=n("5135"),i=n("fc6a"),o=n("4d64").indexOf,s=n("d012");t.exports=function(t,e){var n,a=i(t),u=0,l=[];for(n in a)!r(s,n)&&r(a,n)&&l.push(n);while(e.length>u)r(a,n=e[u++])&&(~o(l,n)||l.push(n));return l}},caad:function(t,e,n){"use strict";var r=n("23e7"),i=n("4d64").includes,o=n("44d2"),s=n("ae40"),a=s("indexOf",{ACCESSORS:!0,1:0});r({target:"Array",proto:!0,forced:!a},{includes:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o("includes")},cc12:function(t,e,n){var r=n("da84"),i=n("861d"),o=r.document,s=i(o)&&i(o.createElement);t.exports=function(t){return s?o.createElement(t):{}}},ce4e:function(t,e,n){var r=n("da84"),i=n("9112");t.exports=function(t,e){try{i(r,t,e)}catch(n){r[t]=e}return e}},d012:function(t,e){t.exports={}},d039:function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},d066:function(t,e,n){var r=n("428f"),i=n("da84"),o=function(t){return"function"==typeof t?t:void 0};t.exports=function(t,e){return arguments.length<2?o(r[t])||o(i[t]):r[t]&&r[t][e]||i[t]&&i[t][e]}},d1e7:function(t,e,n){"use strict";var r={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,o=i&&!r.call({1:2},1);e.f=o?function(t){var e=i(this,t);return!!e&&e.enumerable}:r},d28b:function(t,e,n){var r=n("746f");r("iterator")},d2bb:function(t,e,n){var r=n("825a"),i=n("3bbe");t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set,t.call(n,[]),e=n instanceof Array}catch(o){}return function(n,o){return r(n),i(o),e?t.call(n,o):n.__proto__=o,n}}():void 0)},d3b7:function(t,e,n){var r=n("00ee"),i=n("6eeb"),o=n("b041");r||i(Object.prototype,"toString",o,{unsafe:!0})},d44e:function(t,e,n){var r=n("9bf2").f,i=n("5135"),o=n("b622"),s=o("toStringTag");t.exports=function(t,e,n){t&&!i(t=n?t:t.prototype,s)&&r(t,s,{configurable:!0,value:e})}},d58f:function(t,e,n){var r=n("1c0b"),i=n("7b0b"),o=n("44ad"),s=n("50c4"),a=function(t){return function(e,n,a,u){r(n);var l=i(e),c=o(l),h=s(l.length),f=t?h-1:0,d=t?-1:1;if(a<2)while(1){if(f in c){u=c[f],f+=d;break}if(f+=d,t?f<0:h<=f)throw TypeError("Reduce of empty array with no initial value")}for(;t?f>=0:h>f;f+=d)f in c&&(u=n(u,c[f],f,l));return u}};t.exports={left:a(!1),right:a(!0)}},d784:function(t,e,n){"use strict";n("ac1f");var r=n("6eeb"),i=n("d039"),o=n("b622"),s=n("9263"),a=n("9112"),u=o("species"),l=!i((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")})),c=function(){return"$0"==="a".replace(/./,"$0")}(),h=o("replace"),f=function(){return!!/./[h]&&""===/./[h]("a","$0")}(),d=!i((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));t.exports=function(t,e,n,h){var p=o(t),m=!i((function(){var e={};return e[p]=function(){return 7},7!=""[t](e)})),v=m&&!i((function(){var e=!1,n=/a/;return"split"===t&&(n={},n.constructor={},n.constructor[u]=function(){return n},n.flags="",n[p]=/./[p]),n.exec=function(){return e=!0,null},n[p](""),!e}));if(!m||!v||"replace"===t&&(!l||!c||f)||"split"===t&&!d){var g=/./[p],_=n(p,""[t],(function(t,e,n,r,i){return e.exec===s?m&&!i?{done:!0,value:g.call(e,n,r)}:{done:!0,value:t.call(n,e,r)}:{done:!1}}),{REPLACE_KEEPS_$0:c,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:f}),y=_[0],b=_[1];r(String.prototype,t,y),r(RegExp.prototype,p,2==e?function(t,e){return b.call(t,this,e)}:function(t){return b.call(t,this)})}h&&a(RegExp.prototype[p],"sham",!0)}},d81d:function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").map,o=n("1dde"),s=n("ae40"),a=o("map"),u=s("map");r({target:"Array",proto:!0,forced:!a||!u},{map:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},da84:function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")()}).call(this,n("c8ba"))},dbb4:function(t,e,n){var r=n("23e7"),i=n("83ab"),o=n("56ef"),s=n("fc6a"),a=n("06cf"),u=n("8418");r({target:"Object",stat:!0,sham:!i},{getOwnPropertyDescriptors:function(t){var e,n,r=s(t),i=a.f,l=o(r),c={},h=0;while(l.length>h)n=i(r,e=l[h++]),void 0!==n&&u(c,e,n);return c}})},dbf1:function(t,e,n){"use strict";(function(t){function r(){return"undefined"!==typeof window?window.console:t.console}n.d(e,"a",(function(){return i}));var i=r()}).call(this,n("c8ba"))},ddb0:function(t,e,n){var r=n("da84"),i=n("fdbc"),o=n("e260"),s=n("9112"),a=n("b622"),u=a("iterator"),l=a("toStringTag"),c=o.values;for(var h in i){var f=r[h],d=f&&f.prototype;if(d){if(d[u]!==c)try{s(d,u,c)}catch(m){d[u]=c}if(d[l]||s(d,l,h),i[h])for(var p in o)if(d[p]!==o[p])try{s(d,p,o[p])}catch(m){d[p]=o[p]}}}},df75:function(t,e,n){var r=n("ca84"),i=n("7839");t.exports=Object.keys||function(t){return r(t,i)}},e01a:function(t,e,n){"use strict";var r=n("23e7"),i=n("83ab"),o=n("da84"),s=n("5135"),a=n("861d"),u=n("9bf2").f,l=n("e893"),c=o.Symbol;if(i&&"function"==typeof c&&(!("description"in c.prototype)||void 0!==c().description)){var h={},f=function(){var t=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),e=this instanceof f?new c(t):void 0===t?c():c(t);return""===t&&(h[e]=!0),e};l(f,c);var d=f.prototype=c.prototype;d.constructor=f;var p=d.toString,m="Symbol(test)"==String(c("test")),v=/^Symbol\((.*)\)[^)]+$/;u(d,"description",{configurable:!0,get:function(){var t=a(this)?this.valueOf():this,e=p.call(t);if(s(h,t))return"";var n=m?e.slice(7,-1):e.replace(v,"$1");return""===n?void 0:n}}),r({global:!0,forced:!0},{Symbol:f})}},e163:function(t,e,n){var r=n("5135"),i=n("7b0b"),o=n("f772"),s=n("e177"),a=o("IE_PROTO"),u=Object.prototype;t.exports=s?Object.getPrototypeOf:function(t){return t=i(t),r(t,a)?t[a]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?u:null}},e177:function(t,e,n){var r=n("d039");t.exports=!r((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},e260:function(t,e,n){"use strict";var r=n("fc6a"),i=n("44d2"),o=n("3f8c"),s=n("69f3"),a=n("7dd0"),u="Array Iterator",l=s.set,c=s.getterFor(u);t.exports=a(Array,"Array",(function(t,e){l(this,{type:u,target:r(t),index:0,kind:e})}),(function(){var t=c(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values"),o.Arguments=o.Array,i("keys"),i("values"),i("entries")},e439:function(t,e,n){var r=n("23e7"),i=n("d039"),o=n("fc6a"),s=n("06cf").f,a=n("83ab"),u=i((function(){s(1)})),l=!a||u;r({target:"Object",stat:!0,forced:l,sham:!a},{getOwnPropertyDescriptor:function(t,e){return s(o(t),e)}})},e538:function(t,e,n){var r=n("b622");e.f=r},e893:function(t,e,n){var r=n("5135"),i=n("56ef"),o=n("06cf"),s=n("9bf2");t.exports=function(t,e){for(var n=i(e),a=s.f,u=o.f,l=0;l<n.length;l++){var c=n[l];r(t,c)||a(t,c,u(e,c))}}},e8b5:function(t,e,n){var r=n("c6b6");t.exports=Array.isArray||function(t){return"Array"==r(t)}},e95a:function(t,e,n){var r=n("b622"),i=n("3f8c"),o=r("iterator"),s=Array.prototype;t.exports=function(t){return void 0!==t&&(i.Array===t||s[o]===t)}},f5df:function(t,e,n){var r=n("00ee"),i=n("c6b6"),o=n("b622"),s=o("toStringTag"),a="Arguments"==i(function(){return arguments}()),u=function(t,e){try{return t[e]}catch(n){}};t.exports=r?i:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=u(e=Object(t),s))?n:a?i(e):"Object"==(r=i(e))&&"function"==typeof e.callee?"Arguments":r}},f772:function(t,e,n){var r=n("5692"),i=n("90e3"),o=r("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},fb15:function(t,e,n){"use strict";if(n.r(e),"undefined"!==typeof window){var r=window.document.currentScript,i=n("8875");r=i(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:i});var o=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);o&&(n.p=o[1])}n("99af"),n("4de4"),n("4160"),n("c975"),n("d81d"),n("a434"),n("159b"),n("a4d3"),n("e439"),n("dbb4"),n("b64b");function s(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function u(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){s(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function l(t){if(Array.isArray(t))return t}n("e01a"),n("d28b"),n("e260"),n("d3b7"),n("3ca3"),n("ddb0");function c(t,e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(t)){var n=[],r=!0,i=!1,o=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done);r=!0)if(n.push(s.value),e&&n.length===e)break}catch(u){i=!0,o=u}finally{try{r||null==a["return"]||a["return"]()}finally{if(i)throw o}}return n}}n("a630"),n("fb6a"),n("b0c0"),n("25f0");function h(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function f(t,e){if(t){if("string"===typeof t)return h(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?h(t,e):void 0}}function d(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function p(t,e){return l(t)||c(t,e)||f(t,e)||d()}function m(t){if(Array.isArray(t))return h(t)}function v(t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}function g(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _(t){return m(t)||v(t)||f(t)||g()}var y=n("a352"),b=n.n(y);function E(t){null!==t.parentElement&&t.parentElement.removeChild(t)}function T(t,e,n){var r=0===n?t.children[0]:t.children[n-1].nextSibling;t.insertBefore(e,r)}var x=n("dbf1");n("13d5"),n("4fad"),n("ac1f"),n("5319");function S(t){var e=Object.create(null);return function(n){var r=e[n];return r||(e[n]=t(n))}}var R=/-(\w)/g,A=S((function(t){return t.replace(R,(function(t,e){return e.toUpperCase()}))})),O=(n("5db7"),n("73d9"),["Start","Add","Remove","Update","End"]),I=["Choose","Unchoose","Sort","Filter","Clone"],w=["Move"],C=[w,O,I].flatMap((function(t){return t})).map((function(t){return"on".concat(t)})),P={manage:w,manageAndEmit:O,emit:I};function N(t){return-1!==C.indexOf(t)}n("caad"),n("2ca0");var M=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","math","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rb","rp","rt","rtc","ruby","s","samp","script","section","select","slot","small","source","span","strong","style","sub","summary","sup","svg","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr"];function D(t){return M.includes(t)}function L(t){return["transition-group","TransitionGroup"].includes(t)}function B(t){return["id","class","role","style"].includes(t)||t.startsWith("data-")||t.startsWith("aria-")||t.startsWith("on")}function F(t){return t.reduce((function(t,e){var n=p(e,2),r=n[0],i=n[1];return t[r]=i,t}),{})}function U(t){var e=t.$attrs,n=t.componentData,r=void 0===n?{}:n,i=F(Object.entries(e).filter((function(t){var e=p(t,2),n=e[0];e[1];return B(n)})));return u(u({},i),r)}function G(t){var e=t.$attrs,n=t.callBackBuilder,r=F(k(e));Object.entries(n).forEach((function(t){var e=p(t,2),n=e[0],i=e[1];P[n].forEach((function(t){r["on".concat(t)]=i(t)}))}));var i="[data-draggable]".concat(r.draggable||"");return u(u({},r),{},{draggable:i})}function k(t){return Object.entries(t).filter((function(t){var e=p(t,2),n=e[0];e[1];return!B(n)})).map((function(t){var e=p(t,2),n=e[0],r=e[1];return[A(n),r]})).filter((function(t){var e=p(t,2),n=e[0];e[1];return!N(n)}))}n("c740");function X(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function H(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function j(t,e,n){return e&&H(t.prototype,e),n&&H(t,n),t}var V=function(t){var e=t.el;return e},Y=function(t,e){return t.__draggable_context=e},W=function(t){return t.__draggable_context},z=function(){function t(e){var n=e.nodes,r=n.header,i=n.default,o=n.footer,s=e.root,a=e.realList;X(this,t),this.defaultNodes=i,this.children=[].concat(_(r),_(i),_(o)),this.externalComponent=s.externalComponent,this.rootTransition=s.transition,this.tag=s.tag,this.realList=a}return j(t,[{key:"render",value:function(t,e){var n=this.tag,r=this.children,i=this._isRootComponent,o=i?{default:function(){return r}}:r;return t(n,e,o)}},{key:"updated",value:function(){var t=this.defaultNodes,e=this.realList;t.forEach((function(t,n){Y(V(t),{element:e[n],index:n})}))}},{key:"getUnderlyingVm",value:function(t){return W(t)}},{key:"getVmIndexFromDomIndex",value:function(t,e){var n=this.defaultNodes,r=n.length,i=e.children,o=i.item(t);if(null===o)return r;var s=W(o);if(s)return s.index;if(0===r)return 0;var a=V(n[0]),u=_(i).findIndex((function(t){return t===a}));return t<u?0:r}},{key:"_isRootComponent",get:function(){return this.externalComponent||this.rootTransition}}]),t}(),$=n("8bbf");function q(t,e){var n=t[e];return n?n():[]}function K(t){var e=t.$slots,n=t.realList,r=t.getKey,i=n||[],o=["header","footer"].map((function(t){return q(e,t)})),s=p(o,2),a=s[0],l=s[1],c=e.item;if(!c)throw new Error("draggable element must have an item slot");var h=i.flatMap((function(t,e){return c({element:t,index:e}).map((function(e){return e.key=r(t),e.props=u(u({},e.props||{}),{},{"data-draggable":!0}),e}))}));if(h.length!==i.length)throw new Error("Item slot must have only one child");return{header:a,footer:l,default:h}}function Z(t){var e=L(t),n=!D(t)&&!e;return{transition:e,externalComponent:n,tag:n?Object($["resolveComponent"])(t):e?$["TransitionGroup"]:t}}function J(t){var e=t.$slots,n=t.tag,r=t.realList,i=t.getKey,o=K({$slots:e,realList:r,getKey:i}),s=Z(n);return new z({nodes:o,root:s,realList:r})}function Q(t,e){var n=this;Object($["nextTick"])((function(){return n.$emit(t.toLowerCase(),e)}))}function tt(t){var e=this;return function(n,r){if(null!==e.realList)return e["onDrag".concat(t)](n,r)}}function et(t){var e=this,n=tt.call(this,t);return function(r,i){n.call(e,r,i),Q.call(e,t,r)}}var nt=null,rt={list:{type:Array,required:!1,default:null},modelValue:{type:Array,required:!1,default:null},itemKey:{type:[String,Function],required:!0},clone:{type:Function,default:function(t){return t}},tag:{type:String,default:"div"},move:{type:Function,default:null},componentData:{type:Object,required:!1,default:null}},it=["update:modelValue","change"].concat(_([].concat(_(P.manageAndEmit),_(P.emit)).map((function(t){return t.toLowerCase()})))),ot=Object($["defineComponent"])({name:"draggable",inheritAttrs:!1,props:rt,emits:it,data:function(){return{error:!1}},render:function(){try{this.error=!1;var t=this.$slots,e=this.$attrs,n=this.tag,r=this.componentData,i=this.realList,o=this.getKey,s=J({$slots:t,tag:n,realList:i,getKey:o});this.componentStructure=s;var a=U({$attrs:e,componentData:r});return s.render($["h"],a)}catch(u){return this.error=!0,Object($["h"])("pre",{style:{color:"red"}},u.stack)}},created:function(){null!==this.list&&null!==this.modelValue&&x["a"].error("modelValue and list props are mutually exclusive! Please set one or another.")},mounted:function(){var t=this;if(!this.error){var e=this.$attrs,n=this.$el,r=this.componentStructure;r.updated();var i=G({$attrs:e,callBackBuilder:{manageAndEmit:function(e){return et.call(t,e)},emit:function(e){return Q.bind(t,e)},manage:function(e){return tt.call(t,e)}}}),o=1===n.nodeType?n:n.parentElement;this._sortable=new b.a(o,i),this.targetDomElement=o,o.__draggable_component__=this}},updated:function(){this.componentStructure.updated()},beforeUnmount:function(){void 0!==this._sortable&&this._sortable.destroy()},computed:{realList:function(){var t=this.list;return t||this.modelValue},getKey:function(){var t=this.itemKey;return"function"===typeof t?t:function(e){return e[t]}}},watch:{$attrs:{handler:function(t){var e=this._sortable;e&&k(t).forEach((function(t){var n=p(t,2),r=n[0],i=n[1];e.option(r,i)}))},deep:!0}},methods:{getUnderlyingVm:function(t){return this.componentStructure.getUnderlyingVm(t)||null},getUnderlyingPotencialDraggableComponent:function(t){return t.__draggable_component__},emitChanges:function(t){var e=this;Object($["nextTick"])((function(){return e.$emit("change",t)}))},alterList:function(t){if(this.list)t(this.list);else{var e=_(this.modelValue);t(e),this.$emit("update:modelValue",e)}},spliceList:function(){var t=arguments,e=function(e){return e.splice.apply(e,_(t))};this.alterList(e)},updatePosition:function(t,e){var n=function(n){return n.splice(e,0,n.splice(t,1)[0])};this.alterList(n)},getRelatedContextFromMoveEvent:function(t){var e=t.to,n=t.related,r=this.getUnderlyingPotencialDraggableComponent(e);if(!r)return{component:r};var i=r.realList,o={list:i,component:r};if(e!==n&&i){var s=r.getUnderlyingVm(n)||{};return u(u({},s),o)}return o},getVmIndexFromDomIndex:function(t){return this.componentStructure.getVmIndexFromDomIndex(t,this.targetDomElement)},onDragStart:function(t){this.context=this.getUnderlyingVm(t.item),t.item._underlying_vm_=this.clone(this.context.element),nt=t.item},onDragAdd:function(t){var e=t.item._underlying_vm_;if(void 0!==e){E(t.item);var n=this.getVmIndexFromDomIndex(t.newIndex);this.spliceList(n,0,e);var r={element:e,newIndex:n};this.emitChanges({added:r})}},onDragRemove:function(t){if(T(this.$el,t.item,t.oldIndex),"clone"!==t.pullMode){var e=this.context,n=e.index,r=e.element;this.spliceList(n,1);var i={element:r,oldIndex:n};this.emitChanges({removed:i})}else E(t.clone)},onDragUpdate:function(t){E(t.item),T(t.from,t.item,t.oldIndex);var e=this.context.index,n=this.getVmIndexFromDomIndex(t.newIndex);this.updatePosition(e,n);var r={element:this.context.element,oldIndex:e,newIndex:n};this.emitChanges({moved:r})},computeFutureIndex:function(t,e){if(!t.element)return 0;var n=_(e.to.children).filter((function(t){return"none"!==t.style["display"]})),r=n.indexOf(e.related),i=t.component.getVmIndexFromDomIndex(r),o=-1!==n.indexOf(nt);return o||!e.willInsertAfter?i:i+1},onDragMove:function(t,e){var n=this.move,r=this.realList;if(!n||!r)return!0;var i=this.getRelatedContextFromMoveEvent(t),o=this.computeFutureIndex(i,t),s=u(u({},this.context),{},{futureIndex:o}),a=u(u({},t),{},{relatedContext:i,draggedContext:s});return n(a,e)},onDragEnd:function(){nt=null}}}),st=ot;e["default"]=st},fb6a:function(t,e,n){"use strict";var r=n("23e7"),i=n("861d"),o=n("e8b5"),s=n("23cb"),a=n("50c4"),u=n("fc6a"),l=n("8418"),c=n("b622"),h=n("1dde"),f=n("ae40"),d=h("slice"),p=f("slice",{ACCESSORS:!0,0:0,1:2}),m=c("species"),v=[].slice,g=Math.max;r({target:"Array",proto:!0,forced:!d||!p},{slice:function(t,e){var n,r,c,h=u(this),f=a(h.length),d=s(t,f),p=s(void 0===e?f:e,f);if(o(h)&&(n=h.constructor,"function"!=typeof n||n!==Array&&!o(n.prototype)?i(n)&&(n=n[m],null===n&&(n=void 0)):n=void 0,n===Array||void 0===n))return v.call(h,d,p);for(r=new(void 0===n?Array:n)(g(p-d,0)),c=0;d<p;d++,c++)d in h&&l(r,c,h[d]);return r.length=c,r}})},fc6a:function(t,e,n){var r=n("44ad"),i=n("1d80");t.exports=function(t){return r(i(t))}},fdbc:function(t,e){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},fdbf:function(t,e,n){var r=n("4930");t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}})["default"]}))},8111:function(t,e,n){"use strict";n.d(e,{i:function(){return r}});let r=()=>({events:{},emit(t,...e){(this.events[t]||[]).forEach((t=>t(...e)))},on(t,e){return(this.events[t]=this.events[t]||[]).push(e),()=>this.events[t]=(this.events[t]||[]).filter((t=>t!==e))}})},2482:function(t,e,n){"use strict";function r(t,e,n){return(()=>void 0!==e&&null!==e&&e[Symbol.for("in")]?e[Symbol.for("in")](t):e in t)()?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{Z:function(){return r}})},3002:function(t,e,n){"use strict";n.d(e,{ZP:function(){return Ht},pm:function(){return Xt}});var r=n(4865),i=Object.defineProperty,o=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable,u=(t,e,n)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,l=(t,e)=>{for(var n in e||(e={}))s.call(e,n)&&u(t,n,e[n]);if(o)for(var n of o(e))a.call(e,n)&&u(t,n,e[n]);return t},c=t=>"function"===typeof t,h=t=>"string"===typeof t,f=t=>h(t)&&t.trim().length>0,d=t=>"number"===typeof t,p=t=>"undefined"===typeof t,m=t=>"object"===typeof t&&null!==t,v=t=>T(t,"tag")&&f(t.tag),g=t=>window.TouchEvent&&t instanceof TouchEvent,_=t=>T(t,"component")&&b(t.component),y=t=>c(t)||m(t),b=t=>!p(t)&&(h(t)||y(t)||_(t)),E=t=>m(t)&&["height","width","right","left","top","bottom"].every((e=>d(t[e]))),T=(t,e)=>(m(t)||c(t))&&e in t,x=(t=>()=>t++)(0);function S(t){return g(t)?t.targetTouches[0].clientX:t.clientX}function R(t){return g(t)?t.targetTouches[0].clientY:t.clientY}var A,O,I,w=t=>{p(t.remove)?t.parentNode&&t.parentNode.removeChild(t):t.remove()},C=t=>_(t)?C(t.component):v(t)?(0,r.defineComponent)({render(){return t}}):"string"===typeof t?t:(0,r.toRaw)((0,r.unref)(t)),P=t=>{if("string"===typeof t)return t;const e=T(t,"props")&&m(t.props)?t.props:{},n=T(t,"listeners")&&m(t.listeners)?t.listeners:{};return{component:C(t),props:e,listeners:n}},N=()=>"undefined"!==typeof window,M=class{constructor(){this.allHandlers={}}getHandlers(t){return this.allHandlers[t]||[]}on(t,e){const n=this.getHandlers(t);n.push(e),this.allHandlers[t]=n}off(t,e){const n=this.getHandlers(t);n.splice(n.indexOf(e)>>>0,1)}emit(t,e){const n=this.getHandlers(t);n.forEach((t=>t(e)))}},D=t=>["on","off","emit"].every((e=>T(t,e)&&c(t[e])));(function(t){t["SUCCESS"]="success",t["ERROR"]="error",t["WARNING"]="warning",t["INFO"]="info",t["DEFAULT"]="default"})(A||(A={})),function(t){t["TOP_LEFT"]="top-left",t["TOP_CENTER"]="top-center",t["TOP_RIGHT"]="top-right",t["BOTTOM_LEFT"]="bottom-left",t["BOTTOM_CENTER"]="bottom-center",t["BOTTOM_RIGHT"]="bottom-right"}(O||(O={})),function(t){t["ADD"]="add",t["DISMISS"]="dismiss",t["UPDATE"]="update",t["CLEAR"]="clear",t["UPDATE_DEFAULTS"]="update_defaults"}(I||(I={}));var L="Vue-Toastification",B={type:{type:String,default:A.DEFAULT},classNames:{type:[String,Array],default:()=>[]},trueBoolean:{type:Boolean,default:!0}},F={type:B.type,customIcon:{type:[String,Boolean,Object,Function],default:!0}},U={component:{type:[String,Object,Function,Boolean],default:"button"},classNames:B.classNames,showOnHover:{type:Boolean,default:!1},ariaLabel:{type:String,default:"close"}},G={timeout:{type:[Number,Boolean],default:5e3},hideProgressBar:{type:Boolean,default:!1},isRunning:{type:Boolean,default:!1}},k={transition:{type:[Object,String],default:`${L}__bounce`}},X={position:{type:String,default:O.TOP_RIGHT},draggable:B.trueBoolean,draggablePercent:{type:Number,default:.6},pauseOnFocusLoss:B.trueBoolean,pauseOnHover:B.trueBoolean,closeOnClick:B.trueBoolean,timeout:G.timeout,hideProgressBar:G.hideProgressBar,toastClassName:B.classNames,bodyClassName:B.classNames,icon:F.customIcon,closeButton:U.component,closeButtonClassName:U.classNames,showCloseButtonOnHover:U.showOnHover,accessibility:{type:Object,default:()=>({toastRole:"alert",closeButtonLabel:"close"})},rtl:{type:Boolean,default:!1},eventBus:{type:Object,required:!1,default:()=>new M}},H={id:{type:[String,Number],required:!0,default:0},type:B.type,content:{type:[String,Object,Function],required:!0,default:""},onClick:{type:Function,default:void 0},onClose:{type:Function,default:void 0}},j={container:{type:[Object,Function],default:()=>document.body},newestOnTop:B.trueBoolean,maxToasts:{type:Number,default:20},transition:k.transition,toastDefaults:Object,filterBeforeCreate:{type:Function,default:t=>t},filterToasts:{type:Function,default:t=>t},containerClassName:B.classNames,onMounted:Function,shareAppContext:[Boolean,Object]},V={CORE_TOAST:X,TOAST:H,CONTAINER:j,PROGRESS_BAR:G,ICON:F,TRANSITION:k,CLOSE_BUTTON:U},Y=(0,r.defineComponent)({name:"VtProgressBar",props:V.PROGRESS_BAR,data(){return{hasClass:!0}},computed:{style(){return{animationDuration:`${this.timeout}ms`,animationPlayState:this.isRunning?"running":"paused",opacity:this.hideProgressBar?0:1}},cpClass(){return this.hasClass?`${L}__progress-bar`:""}},watch:{timeout(){this.hasClass=!1,this.$nextTick((()=>this.hasClass=!0))}},mounted(){this.$el.addEventListener("animationend",this.animationEnded)},beforeUnmount(){this.$el.removeEventListener("animationend",this.animationEnded)},methods:{animationEnded(){this.$emit("close-toast")}}});function W(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{style:(0,r.normalizeStyle)(t.style),class:(0,r.normalizeClass)(t.cpClass)},null,6)}Y.render=W;var z=Y,$=(0,r.defineComponent)({name:"VtCloseButton",props:V.CLOSE_BUTTON,computed:{buttonComponent(){return!1!==this.component?C(this.component):"button"},classes(){const t=[`${L}__close-button`];return this.showOnHover&&t.push("show-on-hover"),t.concat(this.classNames)}}}),q=(0,r.createTextVNode)(" × ");function K(t,e){return(0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.buttonComponent),(0,r.mergeProps)({"aria-label":t.ariaLabel,class:t.classes},t.$attrs),{default:(0,r.withCtx)((()=>[q])),_:1},16,["aria-label","class"])}$.render=K;var Z=$,J={},Q={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"check-circle",class:"svg-inline--fa fa-check-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},tt=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z"},null,-1),et=[tt];function nt(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",Q,et)}J.render=nt;var rt=J,it={},ot={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"info-circle",class:"svg-inline--fa fa-info-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},st=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z"},null,-1),at=[st];function ut(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",ot,at)}it.render=ut;var lt=it,ct={},ht={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"exclamation-circle",class:"svg-inline--fa fa-exclamation-circle fa-w-16",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},ft=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1),dt=[ft];function pt(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",ht,dt)}ct.render=pt;var mt=ct,vt={},gt={"aria-hidden":"true",focusable:"false","data-prefix":"fas","data-icon":"exclamation-triangle",class:"svg-inline--fa fa-exclamation-triangle fa-w-18",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512"},_t=(0,r.createElementVNode)("path",{fill:"currentColor",d:"M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"},null,-1),yt=[_t];function bt(t,e){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",gt,yt)}vt.render=bt;var Et=vt,Tt=(0,r.defineComponent)({name:"VtIcon",props:V.ICON,computed:{customIconChildren(){return T(this.customIcon,"iconChildren")?this.trimValue(this.customIcon.iconChildren):""},customIconClass(){return h(this.customIcon)?this.trimValue(this.customIcon):T(this.customIcon,"iconClass")?this.trimValue(this.customIcon.iconClass):""},customIconTag(){return T(this.customIcon,"iconTag")?this.trimValue(this.customIcon.iconTag,"i"):"i"},hasCustomIcon(){return this.customIconClass.length>0},component(){return this.hasCustomIcon?this.customIconTag:b(this.customIcon)?C(this.customIcon):this.iconTypeComponent},iconTypeComponent(){const t={[A.DEFAULT]:lt,[A.INFO]:lt,[A.SUCCESS]:rt,[A.ERROR]:Et,[A.WARNING]:mt};return t[this.type]},iconClasses(){const t=[`${L}__icon`];return this.hasCustomIcon?t.concat(this.customIconClass):t}},methods:{trimValue(t,e=""){return f(t)?t.trim():e}}});function xt(t,e){return(0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.component),{class:(0,r.normalizeClass)(t.iconClasses)},{default:(0,r.withCtx)((()=>[(0,r.createTextVNode)((0,r.toDisplayString)(t.customIconChildren),1)])),_:1},8,["class"])}Tt.render=xt;var St=Tt,Rt=(0,r.defineComponent)({name:"VtToast",components:{ProgressBar:z,CloseButton:Z,Icon:St},inheritAttrs:!1,props:Object.assign({},V.CORE_TOAST,V.TOAST),data(){const t={isRunning:!0,disableTransitions:!1,beingDragged:!1,dragStart:0,dragPos:{x:0,y:0},dragRect:{}};return t},computed:{classes(){const t=[`${L}__toast`,`${L}__toast--${this.type}`,`${this.position}`].concat(this.toastClassName);return this.disableTransitions&&t.push("disable-transition"),this.rtl&&t.push(`${L}__toast--rtl`),t},bodyClasses(){const t=[`${L}__toast-${h(this.content)?"body":"component-body"}`].concat(this.bodyClassName);return t},draggableStyle(){return this.dragStart===this.dragPos.x?{}:this.beingDragged?{transform:`translateX(${this.dragDelta}px)`,opacity:1-Math.abs(this.dragDelta/this.removalDistance)}:{transition:"transform 0.2s, opacity 0.2s",transform:"translateX(0)",opacity:1}},dragDelta(){return this.beingDragged?this.dragPos.x-this.dragStart:0},removalDistance(){return E(this.dragRect)?(this.dragRect.right-this.dragRect.left)*this.draggablePercent:0}},mounted(){this.draggable&&this.draggableSetup(),this.pauseOnFocusLoss&&this.focusSetup()},beforeUnmount(){this.draggable&&this.draggableCleanup(),this.pauseOnFocusLoss&&this.focusCleanup()},methods:{hasProp:T,getVueComponentFromObj:C,closeToast(){this.eventBus.emit(I.DISMISS,this.id)},clickHandler(){this.onClick&&this.onClick(this.closeToast),this.closeOnClick&&(this.beingDragged&&this.dragStart!==this.dragPos.x||this.closeToast())},timeoutHandler(){this.closeToast()},hoverPause(){this.pauseOnHover&&(this.isRunning=!1)},hoverPlay(){this.pauseOnHover&&(this.isRunning=!0)},focusPause(){this.isRunning=!1},focusPlay(){this.isRunning=!0},focusSetup(){addEventListener("blur",this.focusPause),addEventListener("focus",this.focusPlay)},focusCleanup(){removeEventListener("blur",this.focusPause),removeEventListener("focus",this.focusPlay)},draggableSetup(){const t=this.$el;t.addEventListener("touchstart",this.onDragStart,{passive:!0}),t.addEventListener("mousedown",this.onDragStart),addEventListener("touchmove",this.onDragMove,{passive:!1}),addEventListener("mousemove",this.onDragMove),addEventListener("touchend",this.onDragEnd),addEventListener("mouseup",this.onDragEnd)},draggableCleanup(){const t=this.$el;t.removeEventListener("touchstart",this.onDragStart),t.removeEventListener("mousedown",this.onDragStart),removeEventListener("touchmove",this.onDragMove),removeEventListener("mousemove",this.onDragMove),removeEventListener("touchend",this.onDragEnd),removeEventListener("mouseup",this.onDragEnd)},onDragStart(t){this.beingDragged=!0,this.dragPos={x:S(t),y:R(t)},this.dragStart=S(t),this.dragRect=this.$el.getBoundingClientRect()},onDragMove(t){this.beingDragged&&(t.preventDefault(),this.isRunning&&(this.isRunning=!1),this.dragPos={x:S(t),y:R(t)})},onDragEnd(){this.beingDragged&&(Math.abs(this.dragDelta)>=this.removalDistance?(this.disableTransitions=!0,this.$nextTick((()=>this.closeToast()))):setTimeout((()=>{this.beingDragged=!1,E(this.dragRect)&&this.pauseOnHover&&this.dragRect.bottom>=this.dragPos.y&&this.dragPos.y>=this.dragRect.top&&this.dragRect.left<=this.dragPos.x&&this.dragPos.x<=this.dragRect.right?this.isRunning=!1:this.isRunning=!0})))}}}),At=["role"];function Ot(t,e){const n=(0,r.resolveComponent)("Icon"),i=(0,r.resolveComponent)("CloseButton"),o=(0,r.resolveComponent)("ProgressBar");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(t.classes),style:(0,r.normalizeStyle)(t.draggableStyle),onClick:e[0]||(e[0]=(...e)=>t.clickHandler&&t.clickHandler(...e)),onMouseenter:e[1]||(e[1]=(...e)=>t.hoverPause&&t.hoverPause(...e)),onMouseleave:e[2]||(e[2]=(...e)=>t.hoverPlay&&t.hoverPlay(...e))},[t.icon?((0,r.openBlock)(),(0,r.createBlock)(n,{key:0,"custom-icon":t.icon,type:t.type},null,8,["custom-icon","type"])):(0,r.createCommentVNode)("v-if",!0),(0,r.createElementVNode)("div",{role:t.accessibility.toastRole||"alert",class:(0,r.normalizeClass)(t.bodyClasses)},["string"===typeof t.content?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.createTextVNode)((0,r.toDisplayString)(t.content),1)],2112)):((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.getVueComponentFromObj(t.content)),(0,r.mergeProps)({key:1,"toast-id":t.id},t.hasProp(t.content,"props")?t.content.props:{},(0,r.toHandlers)(t.hasProp(t.content,"listeners")?t.content.listeners:{}),{onCloseToast:t.closeToast}),null,16,["toast-id","onCloseToast"]))],10,At),t.closeButton?((0,r.openBlock)(),(0,r.createBlock)(i,{key:1,component:t.closeButton,"class-names":t.closeButtonClassName,"show-on-hover":t.showCloseButtonOnHover,"aria-label":t.accessibility.closeButtonLabel,onClick:(0,r.withModifiers)(t.closeToast,["stop"])},null,8,["component","class-names","show-on-hover","aria-label","onClick"])):(0,r.createCommentVNode)("v-if",!0),t.timeout?((0,r.openBlock)(),(0,r.createBlock)(o,{key:2,"is-running":t.isRunning,"hide-progress-bar":t.hideProgressBar,timeout:t.timeout,onCloseToast:t.timeoutHandler},null,8,["is-running","hide-progress-bar","timeout","onCloseToast"])):(0,r.createCommentVNode)("v-if",!0)],38)}Rt.render=Ot;var It=Rt,wt=(0,r.defineComponent)({name:"VtTransition",props:V.TRANSITION,emits:["leave"],methods:{hasProp:T,leave(t){t instanceof HTMLElement&&(t.style.left=t.offsetLeft+"px",t.style.top=t.offsetTop+"px",t.style.width=getComputedStyle(t).width,t.style.position="absolute")}}});function Ct(t,e){return(0,r.openBlock)(),(0,r.createBlock)(r.TransitionGroup,{tag:"div","enter-active-class":t.transition.enter?t.transition.enter:`${t.transition}-enter-active`,"move-class":t.transition.move?t.transition.move:`${t.transition}-move`,"leave-active-class":t.transition.leave?t.transition.leave:`${t.transition}-leave-active`,onLeave:t.leave},{default:(0,r.withCtx)((()=>[(0,r.renderSlot)(t.$slots,"default")])),_:3},8,["enter-active-class","move-class","leave-active-class","onLeave"])}wt.render=Ct;var Pt=wt,Nt=(0,r.defineComponent)({name:"VueToastification",devtools:{hide:!0},components:{Toast:It,VtTransition:Pt},props:Object.assign({},V.CORE_TOAST,V.CONTAINER,V.TRANSITION),data(){const t={count:0,positions:Object.values(O),toasts:{},defaults:{}};return t},computed:{toastArray(){return Object.values(this.toasts)},filteredToasts(){return this.defaults.filterToasts(this.toastArray)}},beforeMount(){const t=this.eventBus;t.on(I.ADD,this.addToast),t.on(I.CLEAR,this.clearToasts),t.on(I.DISMISS,this.dismissToast),t.on(I.UPDATE,this.updateToast),t.on(I.UPDATE_DEFAULTS,this.updateDefaults),this.defaults=this.$props},mounted(){this.setup(this.container)},methods:{async setup(t){c(t)&&(t=await t()),w(this.$el),t.appendChild(this.$el)},setToast(t){p(t.id)||(this.toasts[t.id]=t)},addToast(t){t.content=P(t.content);const e=Object.assign({},this.defaults,t.type&&this.defaults.toastDefaults&&this.defaults.toastDefaults[t.type],t),n=this.defaults.filterBeforeCreate(e,this.toastArray);n&&this.setToast(n)},dismissToast(t){const e=this.toasts[t];p(e)||p(e.onClose)||e.onClose(),delete this.toasts[t]},clearToasts(){Object.keys(this.toasts).forEach((t=>{this.dismissToast(t)}))},getPositionToasts(t){const e=this.filteredToasts.filter((e=>e.position===t)).slice(0,this.defaults.maxToasts);return this.defaults.newestOnTop?e.reverse():e},updateDefaults(t){p(t.container)||this.setup(t.container),this.defaults=Object.assign({},this.defaults,t)},updateToast({id:t,options:e,create:n}){this.toasts[t]?(e.timeout&&e.timeout===this.toasts[t].timeout&&e.timeout++,this.setToast(Object.assign({},this.toasts[t],e))):n&&this.addToast(Object.assign({},{id:t},e))},getClasses(t){const e=[`${L}__container`,t];return e.concat(this.defaults.containerClassName)}}});function Mt(t,e){const n=(0,r.resolveComponent)("Toast"),i=(0,r.resolveComponent)("VtTransition");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(t.positions,(e=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:e},[(0,r.createVNode)(i,{transition:t.defaults.transition,class:(0,r.normalizeClass)(t.getClasses(e))},{default:(0,r.withCtx)((()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(t.getPositionToasts(e),(t=>((0,r.openBlock)(),(0,r.createBlock)(n,(0,r.mergeProps)({key:t.id},t),null,16)))),128))])),_:2},1032,["transition","class"])])))),128))])}Nt.render=Mt;var Dt=Nt,Lt=(t={},e=!0)=>{const n=t.eventBus=t.eventBus||new M;e&&(0,r.nextTick)((()=>{const e=(0,r.createApp)(Dt,l({},t)),n=e.mount(document.createElement("div")),i=t.onMounted;if(p(i)||i(n,e),t.shareAppContext){const n=t.shareAppContext;!0===n?console.warn(`[${L}] App to share context with was not provided.`):(e._context.components=n._context.components,e._context.directives=n._context.directives,e._context.mixins=n._context.mixins,e._context.provides=n._context.provides,e.config.globalProperties=n.config.globalProperties)}}));const i=(t,e)=>{const r=Object.assign({},{id:x(),type:A.DEFAULT},e,{content:t});return n.emit(I.ADD,r),r.id};function o(t,{content:e,options:r},i=!1){const o=Object.assign({},r,{content:e});n.emit(I.UPDATE,{id:t,options:o,create:i})}return i.clear=()=>n.emit(I.CLEAR,void 0),i.updateDefaults=t=>{n.emit(I.UPDATE_DEFAULTS,t)},i.dismiss=t=>{n.emit(I.DISMISS,t)},i.update=o,i.success=(t,e)=>i(t,Object.assign({},e,{type:A.SUCCESS})),i.info=(t,e)=>i(t,Object.assign({},e,{type:A.INFO})),i.error=(t,e)=>i(t,Object.assign({},e,{type:A.ERROR})),i.warning=(t,e)=>i(t,Object.assign({},e,{type:A.WARNING})),i},Bt=()=>{const t=()=>console.warn(`[${L}] This plugin does not support SSR!`);return new Proxy(t,{get(){return t}})};function Ft(t){return N()?D(t)?Lt({eventBus:t},!1):Lt(t,!0):Bt()}var Ut=Symbol("VueToastification"),Gt=new M,kt=(t,e)=>{!0===(null==e?void 0:e.shareAppContext)&&(e.shareAppContext=t);const n=Ft(l({eventBus:Gt},e));t.provide(Ut,n)},Xt=t=>{if(t)return Ft(t);const e=(0,r.getCurrentInstance)()?(0,r.inject)(Ut,void 0):void 0;return e||Ft(Gt)},Ht=kt}}]); -//# sourceMappingURL=chunk-vendors.354a9a53.js.map \ No newline at end of file diff --git a/js/chunk-vendors.354a9a53.js.map b/js/chunk-vendors.354a9a53.js.map deleted file mode 100644 index 36cc13c..0000000 --- a/js/chunk-vendors.354a9a53.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"js/chunk-vendors.354a9a53.js","mappings":";;;;;;;;AAmBA,IAAIA,EAiBAC,EAiBAC,EAgDAC,EAmDAC,EA+BAC,EAiCAC,EAoCAC,EA+BAC,EAmBAC,EAuBAC,EA0BAC,EAwBAC,EA2BAC,EA4BAC,EAiBAC,EAmBAC,EAqBAC,EAoBAC,E,idAveJ,SAAWlB,GACPA,EAAIA,EAAI,gBAAkB,GAAK,eAC/BA,EAAIA,EAAI,SAAW,GAAK,QACxBA,EAAIA,EAAI,UAAY,GAAK,SAH7B,CAIGA,IAAQA,EAAM,KAajB,SAAWC,GACPA,EAAcA,EAAc,WAAa,GAAK,UAC9CA,EAAcA,EAAc,SAAW,GAAK,QAC5CA,EAAcA,EAAc,UAAY,GAAK,SAHjD,CAIGA,IAAkBA,EAAgB,KAarC,SAAWC,GACPA,EAAYA,EAAY,SAAW,OAAS,QAC5CA,EAAYA,EAAY,SAAW,KAAO,QAC1CA,EAAYA,EAAY,WAAa,MAAQ,UAHjD,CAIGA,IAAgBA,EAAc,KA4CjC,SAAWC,GACPA,EAAYA,EAAY,UAAY,GAAK,SACzCA,EAAYA,EAAY,OAAS,GAAK,MACtCA,EAAYA,EAAY,YAAc,GAAK,WAC3CA,EAAYA,EAAY,UAAY,GAAK,SACzCA,EAAYA,EAAY,WAAa,GAAK,UAC1CA,EAAYA,EAAY,UAAY,GAAK,SACzCA,EAAYA,EAAY,WAAa,GAAK,UAC1CA,EAAYA,EAAY,eAAiB,GAAK,cAC9CA,EAAYA,EAAY,cAAgB,GAAK,aAC7CA,EAAYA,EAAY,cAAgB,GAAK,aAC7C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D,uBAAuB,IAAAxB,QAAO68D,QAAmB,QAAU,EACzE,OAAOpI,GAAgBkI,GAAqBG,KAE1CK,GAAcJ","sources":["webpack://profectus/./node_modules/@pixi/constants/dist/esm/constants.js","webpack://profectus/./node_modules/@pixi/core/dist/esm/core.js","webpack://profectus/./node_modules/@pixi/display/dist/esm/display.js","webpack://profectus/./node_modules/@pixi/math/dist/esm/math.js","webpack://profectus/./node_modules/@pixi/particle-emitter/lib/particle-emitter.es.js","webpack://profectus/./node_modules/@pixi/runner/dist/esm/runner.js","webpack://profectus/./node_modules/ismobilejs/esm/isMobile.js","webpack://profectus/./node_modules/@pixi/settings/dist/esm/settings.js","webpack://profectus/./node_modules/@pixi/sprite/dist/esm/sprite.js","webpack://profectus/./node_modules/@pixi/ticker/dist/esm/ticker.js","webpack://profectus/./node_modules/@pixi/utils/dist/esm/utils.js","webpack://profectus/./node_modules/@pixi/utils/node_modules/eventemitter3/index.js","webpack://profectus/./node_modules/@vue/shared/dist/shared.esm-bundler.js","webpack://profectus/./node_modules/@ivanv/vue-collapse-transition/src/CollapseTransition.vue","webpack://profectus/./node_modules/@ivanv/vue-collapse-transition/src/CollapseTransition.vue?7164","webpack://profectus/./node_modules/core-js/internals/a-callable.js","webpack://profectus/./node_modules/core-js/internals/a-possible-prototype.js","webpack://profectus/./node_modules/core-js/internals/an-instance.js","webpack://profectus/./node_modules/core-js/internals/an-object.js","webpack://profectus/./node_modules/core-js/internals/array-includes.js","webpack://profectus/./node_modules/core-js/internals/classof-raw.js","webpack://profectus/./node_modules/core-js/internals/classof.js","webpack://profectus/./node_modules/core-js/internals/clear-error-stack.js","webpack://profectus/./node_modules/core-js/internals/copy-constructor-properties.js","webpack://profectus/./node_modules/core-js/internals/create-non-enumerable-property.js","webpack://profectus/./node_modules/core-js/internals/create-property-descriptor.js","webpack://profectus/./node_modules/core-js/internals/descriptors.js","webpack://profectus/./node_modules/core-js/internals/document-create-element.js","webpack://profectus/./node_modules/core-js/internals/dom-exception-constants.js","webpack://profectus/./node_modules/core-js/internals/engine-user-agent.js","webpack://profectus/./node_modules/core-js/internals/engine-v8-version.js","webpack://profectus/./node_modules/core-js/internals/enum-bug-keys.js","webpack://profectus/./node_modules/core-js/internals/error-stack-installable.js","webpack://profectus/./node_modules/core-js/internals/export.js","webpack://profectus/./node_modules/core-js/internals/fails.js","webpack://profectus/./node_modules/core-js/internals/function-apply.js","webpack://profectus/./node_modules/core-js/internals/function-call.js","webpack://profectus/./node_modules/core-js/internals/function-name.js","webpack://profectus/./node_modules/core-js/internals/function-uncurry-this.js","webpack://profectus/./node_modules/core-js/internals/get-built-in.js","webpack://profectus/./node_modules/core-js/internals/get-method.js","webpack://profectus/./node_modules/core-js/internals/global.js","webpack://profectus/./node_modules/core-js/internals/has-own-property.js","webpack://profectus/./node_modules/core-js/internals/hidden-keys.js","webpack://profectus/./node_modules/core-js/internals/ie8-dom-define.js","webpack://profectus/./node_modules/core-js/internals/indexed-object.js","webpack://profectus/./node_modules/core-js/internals/inherit-if-required.js","webpack://profectus/./node_modules/core-js/internals/inspect-source.js","webpack://profectus/./node_modules/core-js/internals/install-error-cause.js","webpack://profectus/./node_modules/core-js/internals/internal-state.js","webpack://profectus/./node_modules/core-js/internals/is-callable.js","webpack://profectus/./node_modules/core-js/internals/is-forced.js","webpack://profectus/./node_modules/core-js/internals/is-object.js","webpack://profectus/./node_modules/core-js/internals/is-pure.js","webpack://profectus/./node_modules/core-js/internals/is-symbol.js","webpack://profectus/./node_modules/core-js/internals/length-of-array-like.js","webpack://profectus/./node_modules/core-js/internals/native-symbol.js","webpack://profectus/./node_modules/core-js/internals/native-weak-map.js","webpack://profectus/./node_modules/core-js/internals/normalize-string-argument.js","webpack://profectus/./node_modules/core-js/internals/object-define-property.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-descriptor.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-names.js","webpack://profectus/./node_modules/core-js/internals/object-get-own-property-symbols.js","webpack://profectus/./node_modules/core-js/internals/object-is-prototype-of.js","webpack://profectus/./node_modules/core-js/internals/object-keys-internal.js","webpack://profectus/./node_modules/core-js/internals/object-property-is-enumerable.js","webpack://profectus/./node_modules/core-js/internals/object-set-prototype-of.js","webpack://profectus/./node_modules/core-js/internals/ordinary-to-primitive.js","webpack://profectus/./node_modules/core-js/internals/own-keys.js","webpack://profectus/./node_modules/core-js/internals/redefine.js","webpack://profectus/./node_modules/core-js/internals/require-object-coercible.js","webpack://profectus/./node_modules/core-js/internals/set-global.js","webpack://profectus/./node_modules/core-js/internals/shared-key.js","webpack://profectus/./node_modules/core-js/internals/shared-store.js","webpack://profectus/./node_modules/core-js/internals/shared.js","webpack://profectus/./node_modules/core-js/internals/to-absolute-index.js","webpack://profectus/./node_modules/core-js/internals/to-indexed-object.js","webpack://profectus/./node_modules/core-js/internals/to-integer-or-infinity.js","webpack://profectus/./node_modules/core-js/internals/to-length.js","webpack://profectus/./node_modules/core-js/internals/to-object.js","webpack://profectus/./node_modules/core-js/internals/to-primitive.js","webpack://profectus/./node_modules/core-js/internals/to-property-key.js","webpack://profectus/./node_modules/core-js/internals/to-string-tag-support.js","webpack://profectus/./node_modules/core-js/internals/to-string.js","webpack://profectus/./node_modules/core-js/internals/try-to-string.js","webpack://profectus/./node_modules/core-js/internals/uid.js","webpack://profectus/./node_modules/core-js/internals/use-symbol-as-uid.js","webpack://profectus/./node_modules/core-js/internals/v8-prototype-define-bug.js","webpack://profectus/./node_modules/core-js/internals/well-known-symbol.js","webpack://profectus/./node_modules/core-js/internals/wrap-error-constructor-with-cause.js","webpack://profectus/./node_modules/core-js/modules/es.error.cause.js","webpack://profectus/./node_modules/core-js/modules/web.dom-exception.stack.js","webpack://profectus/./node_modules/earcut/src/earcut.js","webpack://profectus/./node_modules/lz-string/libs/lz-string.js","webpack://profectus/./node_modules/object-assign/index.js","webpack://profectus/./node_modules/promise-polyfill/src/finally.js","webpack://profectus/./node_modules/promise-polyfill/src/allSettled.js","webpack://profectus/./node_modules/promise-polyfill/src/index.js","webpack://profectus/./node_modules/@pixi/polyfill/dist/esm/polyfill.js","webpack://profectus/./node_modules/@pixi/accessibility/dist/esm/accessibility.js","webpack://profectus/./node_modules/@pixi/interaction/dist/esm/interaction.js","webpack://profectus/./node_modules/@pixi/app/dist/esm/app.js","webpack://profectus/./node_modules/@pixi/extract/dist/esm/extract.js","webpack://profectus/./node_modules/@pixi/loaders/dist/esm/loaders.js","webpack://profectus/./node_modules/@pixi/compressed-textures/dist/esm/compressed-textures.js","webpack://profectus/./node_modules/@pixi/particle-container/dist/esm/particle-container.js","webpack://profectus/./node_modules/@pixi/graphics/dist/esm/graphics.js","webpack://profectus/./node_modules/@pixi/text/dist/esm/text.js","webpack://profectus/./node_modules/@pixi/prepare/dist/esm/prepare.js","webpack://profectus/./node_modules/@pixi/spritesheet/dist/esm/spritesheet.js","webpack://profectus/./node_modules/@pixi/sprite-tiling/dist/esm/sprite-tiling.js","webpack://profectus/./node_modules/@pixi/mesh/dist/esm/mesh.js","webpack://profectus/./node_modules/@pixi/text-bitmap/dist/esm/text-bitmap.js","webpack://profectus/./node_modules/@pixi/filter-alpha/dist/esm/filter-alpha.js","webpack://profectus/./node_modules/@pixi/filter-blur/dist/esm/filter-blur.js","webpack://profectus/./node_modules/@pixi/filter-color-matrix/dist/esm/filter-color-matrix.js","webpack://profectus/./node_modules/@pixi/filter-displacement/dist/esm/filter-displacement.js","webpack://profectus/./node_modules/@pixi/filter-fxaa/dist/esm/filter-fxaa.js","webpack://profectus/./node_modules/@pixi/filter-noise/dist/esm/filter-noise.js","webpack://profectus/./node_modules/@pixi/mixin-cache-as-bitmap/dist/esm/mixin-cache-as-bitmap.js","webpack://profectus/./node_modules/@pixi/mixin-get-child-by-name/dist/esm/mixin-get-child-by-name.js","webpack://profectus/./node_modules/@pixi/mixin-get-global-position/dist/esm/mixin-get-global-position.js","webpack://profectus/./node_modules/@pixi/mesh-extras/dist/esm/mesh-extras.js","webpack://profectus/./node_modules/@pixi/sprite-animated/dist/esm/sprite-animated.js","webpack://profectus/./node_modules/pixi.js/dist/esm/pixi.js","webpack://profectus/./node_modules/querystring/decode.js","webpack://profectus/./node_modules/querystring/encode.js","webpack://profectus/./node_modules/querystring/index.js","webpack://profectus/./node_modules/sortablejs/modular/sortable.esm.js","webpack://profectus/./node_modules/url/node_modules/punycode/punycode.js","webpack://profectus/./node_modules/url/url.js","webpack://profectus/./node_modules/url/util.js","webpack://profectus/./node_modules/vue-loader/dist/exportHelper.js","webpack://profectus/./node_modules/vue-next-select/dist/vue-next-select.es.prod.js","webpack://profectus/./node_modules/vue-textarea-autosize/dist/vue-textarea-autosize.esm.js","webpack://profectus/./node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js","webpack://profectus/./node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js","webpack://profectus/./node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js","webpack://profectus/./node_modules/@vue/compiler-core/dist/compiler-core.esm-bundler.js","webpack://profectus/./node_modules/@vue/compiler-dom/dist/compiler-dom.esm-bundler.js","webpack://profectus/./node_modules/vue/dist/vue.esm-bundler.js","webpack://profectus/./node_modules/vuedraggable/dist/vuedraggable.umd.js","webpack://profectus/./node_modules/nanoevents/index.js","webpack://profectus/./node_modules/@babel/runtime/helpers/esm/defineProperty.js","webpack://profectus/./node_modules/vue-toastification/dist/index.mjs"],"sourcesContent":["/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\nexport { ALPHA_MODES, BLEND_MODES, BUFFER_BITS, BUFFER_TYPE, CLEAR_MODES, DRAW_MODES, ENV, FORMATS, GC_MODES, MASK_TYPES, MIPMAP_MODES, MSAA_QUALITY, PRECISION, RENDERER_TYPE, SAMPLER_TYPES, SCALE_MODES, TARGETS, TYPES, WRAP_MODES };\n//# sourceMappingURL=constants.js.map\n","/*!\n * @pixi/core - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/core is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nimport { ENV, ALPHA_MODES, SCALE_MODES, FORMATS, TYPES, TARGETS, MIPMAP_MODES, MSAA_QUALITY, BUFFER_TYPE, CLEAR_MODES, DRAW_MODES, BUFFER_BITS, MASK_TYPES, PRECISION, BLEND_MODES, GC_MODES, SAMPLER_TYPES, WRAP_MODES, RENDERER_TYPE } from '@pixi/constants';\nimport { isMobile, isPow2, BaseTextureCache, TextureCache, uid, EventEmitter, determineCrossOrigin, getResolutionOfUrl, deprecation, nextPow2, getBufferType, ProgramCache, removeItems, hex2string, hex2rgb, sayHello, isWebGLSupported, premultiplyBlendMode, log2, premultiplyTint } from '@pixi/utils';\nimport { Runner } from '@pixi/runner';\nimport { Ticker } from '@pixi/ticker';\nimport { groupD8, Rectangle, Point, Matrix } from '@pixi/math';\n\n/**\n * The maximum support for using WebGL. If a device does not\n * support WebGL version, for instance WebGL 2, it will still\n * attempt to fallback support to WebGL 1. If you want to\n * explicitly remove feature support to target a more stable\n * baseline, prefer a lower environment.\n *\n * Due to {@link https://bugs.chromium.org/p/chromium/issues/detail?id=934823|bug in chromium}\n * we disable webgl2 by default for all non-apple mobile devices.\n *\n * @static\n * @name PREFER_ENV\n * @memberof PIXI.settings\n * @type {number}\n * @default PIXI.ENV.WEBGL2\n */\nsettings.PREFER_ENV = isMobile.any ? ENV.WEBGL : ENV.WEBGL2;\n/**\n * If set to `true`, *only* Textures and BaseTexture objects stored\n * in the caches ({@link PIXI.utils.TextureCache TextureCache} and\n * {@link PIXI.utils.BaseTextureCache BaseTextureCache}) can be\n * used when calling {@link PIXI.Texture.from Texture.from} or\n * {@link PIXI.BaseTexture.from BaseTexture.from}.\n * Otherwise, these `from` calls throw an exception. Using this property\n * can be useful if you want to enforce preloading all assets with\n * {@link PIXI.Loader Loader}.\n *\n * @static\n * @name STRICT_TEXTURE_CACHE\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\nsettings.STRICT_TEXTURE_CACHE = false;\n\n/**\n * Collection of installed resource types, class must extend {@link PIXI.Resource}.\n * @example\n * class CustomResource extends PIXI.Resource {\n * // MUST have source, options constructor signature\n * // for auto-detected resources to be created.\n * constructor(source, options) {\n * super();\n * }\n * upload(renderer, baseTexture, glTexture) {\n * // upload with GL\n * return true;\n * }\n * // used to auto-detect resource\n * static test(source, extension) {\n * return extension === 'xyz'|| source instanceof SomeClass;\n * }\n * }\n * // Install the new resource type\n * PIXI.INSTALLED.push(CustomResource);\n *\n * @memberof PIXI\n * @type {Array<PIXI.IResourcePlugin>}\n * @static\n * @readonly\n */\nvar INSTALLED = [];\n/**\n * Create a resource element from a single source element. This\n * auto-detects which type of resource to create. All resources that\n * are auto-detectable must have a static `test` method and a constructor\n * with the arguments `(source, options?)`. Currently, the supported\n * resources for auto-detection include:\n * - {@link PIXI.ImageResource}\n * - {@link PIXI.CanvasResource}\n * - {@link PIXI.VideoResource}\n * - {@link PIXI.SVGResource}\n * - {@link PIXI.BufferResource}\n * @static\n * @memberof PIXI\n * @function autoDetectResource\n * @param {string|*} source - Resource source, this can be the URL to the resource,\n * a typed-array (for BufferResource), HTMLVideoElement, SVG data-uri\n * or any other resource that can be auto-detected. If not resource is\n * detected, it's assumed to be an ImageResource.\n * @param {object} [options] - Pass-through options to use for Resource\n * @param {number} [options.width] - Width of BufferResource or SVG rasterization\n * @param {number} [options.height] - Height of BufferResource or SVG rasterization\n * @param {boolean} [options.autoLoad=true] - Image, SVG and Video flag to start loading\n * @param {number} [options.scale=1] - SVG source scale. Overridden by width, height\n * @param {boolean} [options.createBitmap=PIXI.settings.CREATE_IMAGE_BITMAP] - Image option to create Bitmap object\n * @param {boolean} [options.crossorigin=true] - Image and Video option to set crossOrigin\n * @param {boolean} [options.autoPlay=true] - Video option to start playing video immediately\n * @param {number} [options.updateFPS=0] - Video option to update how many times a second the\n * texture should be updated from the video. Leave at 0 to update at every render\n * @return {PIXI.Resource} The created resource.\n */\nfunction autoDetectResource(source, options) {\n if (!source) {\n return null;\n }\n var extension = '';\n if (typeof source === 'string') {\n // search for file extension: period, 3-4 chars, then ?, # or EOL\n var result = (/\\.(\\w{3,4})(?:$|\\?|#)/i).exec(source);\n if (result) {\n extension = result[1].toLowerCase();\n }\n }\n for (var i = INSTALLED.length - 1; i >= 0; --i) {\n var ResourcePlugin = INSTALLED[i];\n if (ResourcePlugin.test && ResourcePlugin.test(source, extension)) {\n return new ResourcePlugin(source, options);\n }\n }\n throw new Error('Unrecognized source type to auto-detect Resource');\n}\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nvar __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\n var arguments$1 = arguments;\n\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments$1[i];\r\n for (var p in s) { if (Object.prototype.hasOwnProperty.call(s, p)) { t[p] = s[p]; } }\r\n }\r\n return t;\r\n };\r\n return __assign.apply(this, arguments);\r\n};\r\n\r\nfunction __rest(s, e) {\r\n var t = {};\r\n for (var p in s) { if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n { t[p] = s[p]; } }\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n { for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { if (e.indexOf(p[i]) < 0)\r\n { t[p[i]] = s[p[i]]; } } }\r\n return t;\r\n}\n\n/**\n * Base resource class for textures that manages validation and uploading, depending on its type.\n *\n * Uploading of a base texture to the GPU is required.\n *\n * @memberof PIXI\n */\nvar Resource = /** @class */ (function () {\n /**\n * @param width - Width of the resource\n * @param height - Height of the resource\n */\n function Resource(width, height) {\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n this._width = width;\n this._height = height;\n this.destroyed = false;\n this.internal = false;\n this.onResize = new Runner('setRealSize');\n this.onUpdate = new Runner('update');\n this.onError = new Runner('onError');\n }\n /**\n * Bind to a parent BaseTexture\n *\n * @param baseTexture - Parent texture\n */\n Resource.prototype.bind = function (baseTexture) {\n this.onResize.add(baseTexture);\n this.onUpdate.add(baseTexture);\n this.onError.add(baseTexture);\n // Call a resize immediate if we already\n // have the width and height of the resource\n if (this._width || this._height) {\n this.onResize.emit(this._width, this._height);\n }\n };\n /**\n * Unbind to a parent BaseTexture\n *\n * @param baseTexture - Parent texture\n */\n Resource.prototype.unbind = function (baseTexture) {\n this.onResize.remove(baseTexture);\n this.onUpdate.remove(baseTexture);\n this.onError.remove(baseTexture);\n };\n /**\n * Trigger a resize event\n *\n * @param width - X dimension\n * @param height - Y dimension\n */\n Resource.prototype.resize = function (width, height) {\n if (width !== this._width || height !== this._height) {\n this._width = width;\n this._height = height;\n this.onResize.emit(width, height);\n }\n };\n Object.defineProperty(Resource.prototype, \"valid\", {\n /**\n * Has been validated\n *\n * @readonly\n */\n get: function () {\n return !!this._width && !!this._height;\n },\n enumerable: false,\n configurable: true\n });\n /** Has been updated trigger event. */\n Resource.prototype.update = function () {\n if (!this.destroyed) {\n this.onUpdate.emit();\n }\n };\n /**\n * This can be overridden to start preloading a resource\n * or do any other prepare step.\n *\n * @protected\n * @return Handle the validate event\n */\n Resource.prototype.load = function () {\n return Promise.resolve(this);\n };\n Object.defineProperty(Resource.prototype, \"width\", {\n /**\n * The width of the resource.\n *\n * @readonly\n */\n get: function () {\n return this._width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Resource.prototype, \"height\", {\n /**\n * The height of the resource.\n *\n * @readonly\n */\n get: function () {\n return this._height;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Set the style, optional to override\n *\n * @param renderer - yeah, renderer!\n * @param baseTexture - the texture\n * @param glTexture - texture instance for this webgl context\n * @returns - `true` is success\n */\n Resource.prototype.style = function (_renderer, _baseTexture, _glTexture) {\n return false;\n };\n /** Clean up anything, this happens when destroying is ready. */\n Resource.prototype.dispose = function () {\n // override\n };\n /**\n * Call when destroying resource, unbind any BaseTexture object\n * before calling this method, as reference counts are maintained\n * internally.\n */\n Resource.prototype.destroy = function () {\n if (!this.destroyed) {\n this.destroyed = true;\n this.dispose();\n this.onError.removeAll();\n this.onError = null;\n this.onResize.removeAll();\n this.onResize = null;\n this.onUpdate.removeAll();\n this.onUpdate = null;\n }\n };\n /**\n * Abstract, used to auto-detect resource type.\n *\n * @param {*} source - The source object\n * @param {string} extension - The extension of source, if set\n */\n Resource.test = function (_source, _extension) {\n return false;\n };\n return Resource;\n}());\n\n/**\n * @interface SharedArrayBuffer\n */\n/**\n * Buffer resource with data of typed array.\n *\n * @memberof PIXI\n */\nvar BufferResource = /** @class */ (function (_super) {\n __extends(BufferResource, _super);\n /**\n * @param source - Source buffer\n * @param options - Options\n * @param {number} options.width - Width of the texture\n * @param {number} options.height - Height of the texture\n */\n function BufferResource(source, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height;\n if (!width || !height) {\n throw new Error('BufferResource width or height invalid');\n }\n _this = _super.call(this, width, height) || this;\n _this.data = source;\n return _this;\n }\n /**\n * Upload the texture to the GPU.\n *\n * @param renderer - Upload to the renderer\n * @param baseTexture - Reference to parent texture\n * @param glTexture - glTexture\n * @returns - true is success\n */\n BufferResource.prototype.upload = function (renderer, baseTexture, glTexture) {\n var gl = renderer.gl;\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, baseTexture.alphaMode === ALPHA_MODES.UNPACK);\n var width = baseTexture.realWidth;\n var height = baseTexture.realHeight;\n if (glTexture.width === width && glTexture.height === height) {\n gl.texSubImage2D(baseTexture.target, 0, 0, 0, width, height, baseTexture.format, glTexture.type, this.data);\n }\n else {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(baseTexture.target, 0, glTexture.internalFormat, width, height, 0, baseTexture.format, glTexture.type, this.data);\n }\n return true;\n };\n /** Destroy and don't use after this. */\n BufferResource.prototype.dispose = function () {\n this.data = null;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if <canvas>\n */\n BufferResource.test = function (source) {\n return source instanceof Float32Array\n || source instanceof Uint8Array\n || source instanceof Uint32Array;\n };\n return BufferResource;\n}(Resource));\n\nvar defaultBufferOptions = {\n scaleMode: SCALE_MODES.NEAREST,\n format: FORMATS.RGBA,\n alphaMode: ALPHA_MODES.NPM,\n};\n/**\n * A Texture stores the information that represents an image.\n * All textures have a base texture, which contains information about the source.\n * Therefore you can have many textures all using a single BaseTexture\n *\n * @memberof PIXI\n * @typeParam R - The BaseTexture's Resource type.\n * @typeParam RO - The options for constructing resource.\n */\nvar BaseTexture = /** @class */ (function (_super) {\n __extends(BaseTexture, _super);\n /**\n * @param {PIXI.Resource|string|HTMLImageElement|HTMLCanvasElement|HTMLVideoElement} [resource=null] -\n * The current resource to use, for things that aren't Resource objects, will be converted\n * into a Resource.\n * @param options - Collection of options\n * @param {PIXI.MIPMAP_MODES} [options.mipmap=PIXI.settings.MIPMAP_TEXTURES] - If mipmapping is enabled for texture\n * @param {number} [options.anisotropicLevel=PIXI.settings.ANISOTROPIC_LEVEL] - Anisotropic filtering level of texture\n * @param {PIXI.WRAP_MODES} [options.wrapMode=PIXI.settings.WRAP_MODE] - Wrap mode for textures\n * @param {PIXI.SCALE_MODES} [options.scaleMode=PIXI.settings.SCALE_MODE] - Default scale mode, linear, nearest\n * @param {PIXI.FORMATS} [options.format=PIXI.FORMATS.RGBA] - GL format type\n * @param {PIXI.TYPES} [options.type=PIXI.TYPES.UNSIGNED_BYTE] - GL data type\n * @param {PIXI.TARGETS} [options.target=PIXI.TARGETS.TEXTURE_2D] - GL texture target\n * @param {PIXI.ALPHA_MODES} [options.alphaMode=PIXI.ALPHA_MODES.UNPACK] - Pre multiply the image alpha\n * @param {number} [options.width=0] - Width of the texture\n * @param {number} [options.height=0] - Height of the texture\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - Resolution of the base texture\n * @param {object} [options.resourceOptions] - Optional resource options,\n * see {@link PIXI.autoDetectResource autoDetectResource}\n */\n function BaseTexture(resource, options) {\n if (resource === void 0) { resource = null; }\n if (options === void 0) { options = null; }\n var _this = _super.call(this) || this;\n options = options || {};\n var alphaMode = options.alphaMode, mipmap = options.mipmap, anisotropicLevel = options.anisotropicLevel, scaleMode = options.scaleMode, width = options.width, height = options.height, wrapMode = options.wrapMode, format = options.format, type = options.type, target = options.target, resolution = options.resolution, resourceOptions = options.resourceOptions;\n // Convert the resource to a Resource object\n if (resource && !(resource instanceof Resource)) {\n resource = autoDetectResource(resource, resourceOptions);\n resource.internal = true;\n }\n _this.resolution = resolution || settings.RESOLUTION;\n _this.width = Math.round((width || 0) * _this.resolution) / _this.resolution;\n _this.height = Math.round((height || 0) * _this.resolution) / _this.resolution;\n _this._mipmap = mipmap !== undefined ? mipmap : settings.MIPMAP_TEXTURES;\n _this.anisotropicLevel = anisotropicLevel !== undefined ? anisotropicLevel : settings.ANISOTROPIC_LEVEL;\n _this._wrapMode = wrapMode || settings.WRAP_MODE;\n _this._scaleMode = scaleMode !== undefined ? scaleMode : settings.SCALE_MODE;\n _this.format = format || FORMATS.RGBA;\n _this.type = type || TYPES.UNSIGNED_BYTE;\n _this.target = target || TARGETS.TEXTURE_2D;\n _this.alphaMode = alphaMode !== undefined ? alphaMode : ALPHA_MODES.UNPACK;\n _this.uid = uid();\n _this.touched = 0;\n _this.isPowerOfTwo = false;\n _this._refreshPOT();\n _this._glTextures = {};\n _this.dirtyId = 0;\n _this.dirtyStyleId = 0;\n _this.cacheId = null;\n _this.valid = width > 0 && height > 0;\n _this.textureCacheIds = [];\n _this.destroyed = false;\n _this.resource = null;\n _this._batchEnabled = 0;\n _this._batchLocation = 0;\n _this.parentTextureArray = null;\n /**\n * Fired when a not-immediately-available source finishes loading.\n *\n * @protected\n * @event PIXI.BaseTexture#loaded\n * @param {PIXI.BaseTexture} baseTexture - Resource loaded.\n */\n /**\n * Fired when a not-immediately-available source fails to load.\n *\n * @protected\n * @event PIXI.BaseTexture#error\n * @param {PIXI.BaseTexture} baseTexture - Resource errored.\n * @param {ErrorEvent} event - Load error event.\n */\n /**\n * Fired when BaseTexture is updated.\n *\n * @protected\n * @event PIXI.BaseTexture#loaded\n * @param {PIXI.BaseTexture} baseTexture - Resource loaded.\n */\n /**\n * Fired when BaseTexture is updated.\n *\n * @protected\n * @event PIXI.BaseTexture#update\n * @param {PIXI.BaseTexture} baseTexture - Instance of texture being updated.\n */\n /**\n * Fired when BaseTexture is destroyed.\n *\n * @protected\n * @event PIXI.BaseTexture#dispose\n * @param {PIXI.BaseTexture} baseTexture - Instance of texture being destroyed.\n */\n // Set the resource\n _this.setResource(resource);\n return _this;\n }\n Object.defineProperty(BaseTexture.prototype, \"realWidth\", {\n /**\n * Pixel width of the source of this texture\n *\n * @readonly\n */\n get: function () {\n return Math.round(this.width * this.resolution);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"realHeight\", {\n /**\n * Pixel height of the source of this texture\n *\n * @readonly\n */\n get: function () {\n return Math.round(this.height * this.resolution);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"mipmap\", {\n /**\n * Mipmap mode of the texture, affects downscaled images\n *\n * @default PIXI.settings.MIPMAP_TEXTURES\n */\n get: function () {\n return this._mipmap;\n },\n set: function (value) {\n if (this._mipmap !== value) {\n this._mipmap = value;\n this.dirtyStyleId++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"scaleMode\", {\n /**\n * The scale mode to apply when scaling this texture\n *\n * @default PIXI.settings.SCALE_MODE\n */\n get: function () {\n return this._scaleMode;\n },\n set: function (value) {\n if (this._scaleMode !== value) {\n this._scaleMode = value;\n this.dirtyStyleId++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BaseTexture.prototype, \"wrapMode\", {\n /**\n * How the texture wraps\n *\n * @default PIXI.settings.WRAP_MODE\n */\n get: function () {\n return this._wrapMode;\n },\n set: function (value) {\n if (this._wrapMode !== value) {\n this._wrapMode = value;\n this.dirtyStyleId++;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Changes style options of BaseTexture\n *\n * @param scaleMode - Pixi scalemode\n * @param mipmap - enable mipmaps\n * @returns - this\n */\n BaseTexture.prototype.setStyle = function (scaleMode, mipmap) {\n var dirty;\n if (scaleMode !== undefined && scaleMode !== this.scaleMode) {\n this.scaleMode = scaleMode;\n dirty = true;\n }\n if (mipmap !== undefined && mipmap !== this.mipmap) {\n this.mipmap = mipmap;\n dirty = true;\n }\n if (dirty) {\n this.dirtyStyleId++;\n }\n return this;\n };\n /**\n * Changes w/h/resolution. Texture becomes valid if width and height are greater than zero.\n *\n * @param desiredWidth - Desired visual width\n * @param desiredHeight - Desired visual height\n * @param resolution - Optionally set resolution\n * @returns - this\n */\n BaseTexture.prototype.setSize = function (desiredWidth, desiredHeight, resolution) {\n resolution = resolution || this.resolution;\n return this.setRealSize(desiredWidth * resolution, desiredHeight * resolution, resolution);\n };\n /**\n * Sets real size of baseTexture, preserves current resolution.\n *\n * @param realWidth - Full rendered width\n * @param realHeight - Full rendered height\n * @param resolution - Optionally set resolution\n * @returns - this\n */\n BaseTexture.prototype.setRealSize = function (realWidth, realHeight, resolution) {\n this.resolution = resolution || this.resolution;\n this.width = Math.round(realWidth) / this.resolution;\n this.height = Math.round(realHeight) / this.resolution;\n this._refreshPOT();\n this.update();\n return this;\n };\n /**\n * Refresh check for isPowerOfTwo texture based on size\n *\n * @private\n */\n BaseTexture.prototype._refreshPOT = function () {\n this.isPowerOfTwo = isPow2(this.realWidth) && isPow2(this.realHeight);\n };\n /**\n * Changes resolution\n *\n * @param resolution - res\n * @returns - this\n */\n BaseTexture.prototype.setResolution = function (resolution) {\n var oldResolution = this.resolution;\n if (oldResolution === resolution) {\n return this;\n }\n this.resolution = resolution;\n if (this.valid) {\n this.width = Math.round(this.width * oldResolution) / resolution;\n this.height = Math.round(this.height * oldResolution) / resolution;\n this.emit('update', this);\n }\n this._refreshPOT();\n return this;\n };\n /**\n * Sets the resource if it wasn't set. Throws error if resource already present\n *\n * @param resource - that is managing this BaseTexture\n * @returns - this\n */\n BaseTexture.prototype.setResource = function (resource) {\n if (this.resource === resource) {\n return this;\n }\n if (this.resource) {\n throw new Error('Resource can be set only once');\n }\n resource.bind(this);\n this.resource = resource;\n return this;\n };\n /** Invalidates the object. Texture becomes valid if width and height are greater than zero. */\n BaseTexture.prototype.update = function () {\n if (!this.valid) {\n if (this.width > 0 && this.height > 0) {\n this.valid = true;\n this.emit('loaded', this);\n this.emit('update', this);\n }\n }\n else {\n this.dirtyId++;\n this.dirtyStyleId++;\n this.emit('update', this);\n }\n };\n /**\n * Handle errors with resources.\n *\n * @private\n * @param event - Error event emitted.\n */\n BaseTexture.prototype.onError = function (event) {\n this.emit('error', this, event);\n };\n /**\n * Destroys this base texture.\n * The method stops if resource doesn't want this texture to be destroyed.\n * Removes texture from all caches.\n */\n BaseTexture.prototype.destroy = function () {\n // remove and destroy the resource\n if (this.resource) {\n this.resource.unbind(this);\n // only destroy resourced created internally\n if (this.resource.internal) {\n this.resource.destroy();\n }\n this.resource = null;\n }\n if (this.cacheId) {\n delete BaseTextureCache[this.cacheId];\n delete TextureCache[this.cacheId];\n this.cacheId = null;\n }\n // finally let the WebGL renderer know..\n this.dispose();\n BaseTexture.removeFromCache(this);\n this.textureCacheIds = null;\n this.destroyed = true;\n };\n /**\n * Frees the texture from WebGL memory without destroying this texture object.\n * This means you can still use the texture later which will upload it to GPU\n * memory again.\n *\n * @fires PIXI.BaseTexture#dispose\n */\n BaseTexture.prototype.dispose = function () {\n this.emit('dispose', this);\n };\n /** Utility function for BaseTexture|Texture cast. */\n BaseTexture.prototype.castToBaseTexture = function () {\n return this;\n };\n /**\n * Helper function that creates a base texture based on the source you provide.\n * The source can be - image url, image element, canvas element. If the\n * source is an image url or an image element and not in the base texture\n * cache, it will be created and loaded.\n *\n * @static\n * @param {string|HTMLImageElement|HTMLCanvasElement|SVGElement|HTMLVideoElement} source - The\n * source to create base texture from.\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @param {string} [options.pixiIdPrefix=pixiid] - If a source has no id, this is the prefix of the generated id\n * @param {boolean} [strict] - Enforce strict-mode, see {@link PIXI.settings.STRICT_TEXTURE_CACHE}.\n * @returns {PIXI.BaseTexture} The new base texture.\n */\n BaseTexture.from = function (source, options, strict) {\n if (strict === void 0) { strict = settings.STRICT_TEXTURE_CACHE; }\n var isFrame = typeof source === 'string';\n var cacheId = null;\n if (isFrame) {\n cacheId = source;\n }\n else {\n if (!source._pixiId) {\n var prefix = (options && options.pixiIdPrefix) || 'pixiid';\n source._pixiId = prefix + \"_\" + uid();\n }\n cacheId = source._pixiId;\n }\n var baseTexture = BaseTextureCache[cacheId];\n // Strict-mode rejects invalid cacheIds\n if (isFrame && strict && !baseTexture) {\n throw new Error(\"The cacheId \\\"\" + cacheId + \"\\\" does not exist in BaseTextureCache.\");\n }\n if (!baseTexture) {\n baseTexture = new BaseTexture(source, options);\n baseTexture.cacheId = cacheId;\n BaseTexture.addToCache(baseTexture, cacheId);\n }\n return baseTexture;\n };\n /**\n * Create a new BaseTexture with a BufferResource from a Float32Array.\n * RGBA values are floats from 0 to 1.\n *\n * @param {Float32Array|Uint8Array} buffer - The optional array to use, if no data\n * is provided, a new Float32Array is created.\n * @param width - Width of the resource\n * @param height - Height of the resource\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @return - The resulting new BaseTexture\n */\n BaseTexture.fromBuffer = function (buffer, width, height, options) {\n buffer = buffer || new Float32Array(width * height * 4);\n var resource = new BufferResource(buffer, { width: width, height: height });\n var type = buffer instanceof Float32Array ? TYPES.FLOAT : TYPES.UNSIGNED_BYTE;\n return new BaseTexture(resource, Object.assign(defaultBufferOptions, options || { width: width, height: height, type: type }));\n };\n /**\n * Adds a BaseTexture to the global BaseTextureCache. This cache is shared across the whole PIXI object.\n *\n *\n * @param {PIXI.BaseTexture} baseTexture - The BaseTexture to add to the cache.\n * @param {string} id - The id that the BaseTexture will be stored against.\n */\n BaseTexture.addToCache = function (baseTexture, id) {\n if (id) {\n if (baseTexture.textureCacheIds.indexOf(id) === -1) {\n baseTexture.textureCacheIds.push(id);\n }\n if (BaseTextureCache[id]) {\n // eslint-disable-next-line no-console\n console.warn(\"BaseTexture added to the cache with an id [\" + id + \"] that already had an entry\");\n }\n BaseTextureCache[id] = baseTexture;\n }\n };\n /**\n * Remove a BaseTexture from the global BaseTextureCache.\n *\n * @param {string|PIXI.BaseTexture} baseTexture - id of a BaseTexture to be removed, or a BaseTexture instance itself.\n * @return {PIXI.BaseTexture|null} The BaseTexture that was removed.\n */\n BaseTexture.removeFromCache = function (baseTexture) {\n if (typeof baseTexture === 'string') {\n var baseTextureFromCache = BaseTextureCache[baseTexture];\n if (baseTextureFromCache) {\n var index = baseTextureFromCache.textureCacheIds.indexOf(baseTexture);\n if (index > -1) {\n baseTextureFromCache.textureCacheIds.splice(index, 1);\n }\n delete BaseTextureCache[baseTexture];\n return baseTextureFromCache;\n }\n }\n else if (baseTexture && baseTexture.textureCacheIds) {\n for (var i = 0; i < baseTexture.textureCacheIds.length; ++i) {\n delete BaseTextureCache[baseTexture.textureCacheIds[i]];\n }\n baseTexture.textureCacheIds.length = 0;\n return baseTexture;\n }\n return null;\n };\n /** Global number of the texture batch, used by multi-texture renderers. */\n BaseTexture._globalBatch = 0;\n return BaseTexture;\n}(EventEmitter));\n\n/**\n * Resource that can manage several resource (items) inside.\n * All resources need to have the same pixel size.\n * Parent class for CubeResource and ArrayResource\n *\n * @memberof PIXI\n */\nvar AbstractMultiResource = /** @class */ (function (_super) {\n __extends(AbstractMultiResource, _super);\n /**\n * @param length\n * @param options - Options to for Resource constructor\n * @param {number} [options.width] - Width of the resource\n * @param {number} [options.height] - Height of the resource\n */\n function AbstractMultiResource(length, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height;\n _this = _super.call(this, width, height) || this;\n _this.items = [];\n _this.itemDirtyIds = [];\n for (var i = 0; i < length; i++) {\n var partTexture = new BaseTexture();\n _this.items.push(partTexture);\n // -2 - first run of texture array upload\n // -1 - texture item was allocated\n // >=0 - texture item uploaded , in sync with items[i].dirtyId\n _this.itemDirtyIds.push(-2);\n }\n _this.length = length;\n _this._load = null;\n _this.baseTexture = null;\n return _this;\n }\n /**\n * Used from ArrayResource and CubeResource constructors.\n *\n * @param resources - Can be resources, image elements, canvas, etc. ,\n * length should be same as constructor length\n * @param options - Detect options for resources\n */\n AbstractMultiResource.prototype.initFromArray = function (resources, options) {\n for (var i = 0; i < this.length; i++) {\n if (!resources[i]) {\n continue;\n }\n if (resources[i].castToBaseTexture) {\n this.addBaseTextureAt(resources[i].castToBaseTexture(), i);\n }\n else if (resources[i] instanceof Resource) {\n this.addResourceAt(resources[i], i);\n }\n else {\n this.addResourceAt(autoDetectResource(resources[i], options), i);\n }\n }\n };\n /** Destroy this BaseImageResource. */\n AbstractMultiResource.prototype.dispose = function () {\n for (var i = 0, len = this.length; i < len; i++) {\n this.items[i].destroy();\n }\n this.items = null;\n this.itemDirtyIds = null;\n this._load = null;\n };\n /**\n * Set a resource by ID\n *\n * @param resource\n * @param index - Zero-based index of resource to set\n * @return - Instance for chaining\n */\n AbstractMultiResource.prototype.addResourceAt = function (resource, index) {\n if (!this.items[index]) {\n throw new Error(\"Index \" + index + \" is out of bounds\");\n }\n // Inherit the first resource dimensions\n if (resource.valid && !this.valid) {\n this.resize(resource.width, resource.height);\n }\n this.items[index].setResource(resource);\n return this;\n };\n /** Set the parent base texture. */\n AbstractMultiResource.prototype.bind = function (baseTexture) {\n if (this.baseTexture !== null) {\n throw new Error('Only one base texture per TextureArray is allowed');\n }\n _super.prototype.bind.call(this, baseTexture);\n for (var i = 0; i < this.length; i++) {\n this.items[i].parentTextureArray = baseTexture;\n this.items[i].on('update', baseTexture.update, baseTexture);\n }\n };\n /** Unset the parent base texture. */\n AbstractMultiResource.prototype.unbind = function (baseTexture) {\n _super.prototype.unbind.call(this, baseTexture);\n for (var i = 0; i < this.length; i++) {\n this.items[i].parentTextureArray = null;\n this.items[i].off('update', baseTexture.update, baseTexture);\n }\n };\n /**\n * Load all the resources simultaneously\n *\n * @return - When load is resolved\n */\n AbstractMultiResource.prototype.load = function () {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n var resources = this.items.map(function (item) { return item.resource; }).filter(function (item) { return item; });\n // TODO: also implement load part-by-part strategy\n var promises = resources.map(function (item) { return item.load(); });\n this._load = Promise.all(promises)\n .then(function () {\n var _a = _this.items[0], realWidth = _a.realWidth, realHeight = _a.realHeight;\n _this.resize(realWidth, realHeight);\n return Promise.resolve(_this);\n });\n return this._load;\n };\n return AbstractMultiResource;\n}(Resource));\n\n/**\n * A resource that contains a number of sources.\n *\n * @memberof PIXI\n */\nvar ArrayResource = /** @class */ (function (_super) {\n __extends(ArrayResource, _super);\n /**\n * @param source - Number of items in array or the collection\n * of image URLs to use. Can also be resources, image elements, canvas, etc.\n * @param options - Options to apply to {@link PIXI.autoDetectResource}\n * @param {number} [options.width] - Width of the resource\n * @param {number} [options.height] - Height of the resource\n */\n function ArrayResource(source, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height;\n var urls;\n var length;\n if (Array.isArray(source)) {\n urls = source;\n length = source.length;\n }\n else {\n length = source;\n }\n _this = _super.call(this, length, { width: width, height: height }) || this;\n if (urls) {\n _this.initFromArray(urls, options);\n }\n return _this;\n }\n /**\n * Set a baseTexture by ID,\n * ArrayResource just takes resource from it, nothing more\n *\n * @param baseTexture\n * @param index - Zero-based index of resource to set\n * @return - Instance for chaining\n */\n ArrayResource.prototype.addBaseTextureAt = function (baseTexture, index) {\n if (baseTexture.resource) {\n this.addResourceAt(baseTexture.resource, index);\n }\n else {\n throw new Error('ArrayResource does not support RenderTexture');\n }\n return this;\n };\n /** Add binding */\n ArrayResource.prototype.bind = function (baseTexture) {\n _super.prototype.bind.call(this, baseTexture);\n baseTexture.target = TARGETS.TEXTURE_2D_ARRAY;\n };\n /**\n * Upload the resources to the GPU.\n *\n * @param renderer\n * @param texture\n * @param glTexture\n * @returns - whether texture was uploaded\n */\n ArrayResource.prototype.upload = function (renderer, texture, glTexture) {\n var _a = this, length = _a.length, itemDirtyIds = _a.itemDirtyIds, items = _a.items;\n var gl = renderer.gl;\n if (glTexture.dirtyId < 0) {\n gl.texImage3D(gl.TEXTURE_2D_ARRAY, 0, glTexture.internalFormat, this._width, this._height, length, 0, texture.format, glTexture.type, null);\n }\n for (var i = 0; i < length; i++) {\n var item = items[i];\n if (itemDirtyIds[i] < item.dirtyId) {\n itemDirtyIds[i] = item.dirtyId;\n if (item.valid) {\n gl.texSubImage3D(gl.TEXTURE_2D_ARRAY, 0, 0, // xoffset\n 0, // yoffset\n i, // zoffset\n item.resource.width, item.resource.height, 1, texture.format, glTexture.type, item.resource.source);\n }\n }\n }\n return true;\n };\n return ArrayResource;\n}(AbstractMultiResource));\n\n/**\n * Base for all the image/canvas resources.\n *\n * @memberof PIXI\n */\nvar BaseImageResource = /** @class */ (function (_super) {\n __extends(BaseImageResource, _super);\n /**\n * @param {HTMLImageElement|HTMLCanvasElement|HTMLVideoElement|SVGElement} source\n */\n function BaseImageResource(source) {\n var _this = this;\n var sourceAny = source;\n var width = sourceAny.naturalWidth || sourceAny.videoWidth || sourceAny.width;\n var height = sourceAny.naturalHeight || sourceAny.videoHeight || sourceAny.height;\n _this = _super.call(this, width, height) || this;\n _this.source = source;\n _this.noSubImage = false;\n return _this;\n }\n /**\n * Set cross origin based detecting the url and the crossorigin\n *\n * @param element - Element to apply crossOrigin\n * @param url - URL to check\n * @param crossorigin - Cross origin value to use\n */\n BaseImageResource.crossOrigin = function (element, url, crossorigin) {\n if (crossorigin === undefined && url.indexOf('data:') !== 0) {\n element.crossOrigin = determineCrossOrigin(url);\n }\n else if (crossorigin !== false) {\n element.crossOrigin = typeof crossorigin === 'string' ? crossorigin : 'anonymous';\n }\n };\n /**\n * Upload the texture to the GPU.\n *\n * @param renderer - Upload to the renderer\n * @param baseTexture - Reference to parent texture\n * @param glTexture\n * @param {HTMLImageElement|HTMLCanvasElement|HTMLVideoElement|SVGElement} [source] - (optional)\n * @returns - true is success\n */\n BaseImageResource.prototype.upload = function (renderer, baseTexture, glTexture, source) {\n var gl = renderer.gl;\n var width = baseTexture.realWidth;\n var height = baseTexture.realHeight;\n source = source || this.source;\n if (source instanceof HTMLImageElement) {\n if (!source.complete || source.naturalWidth === 0) {\n return false;\n }\n }\n else if (source instanceof HTMLVideoElement) {\n if (source.readyState <= 1) {\n return false;\n }\n }\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, baseTexture.alphaMode === ALPHA_MODES.UNPACK);\n if (!this.noSubImage\n && baseTexture.target === gl.TEXTURE_2D\n && glTexture.width === width\n && glTexture.height === height) {\n gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, baseTexture.format, glTexture.type, source);\n }\n else {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(baseTexture.target, 0, glTexture.internalFormat, baseTexture.format, glTexture.type, source);\n }\n return true;\n };\n /**\n * Checks if source width/height was changed, resize can cause extra baseTexture update.\n * Triggers one update in any case.\n */\n BaseImageResource.prototype.update = function () {\n if (this.destroyed) {\n return;\n }\n var source = this.source;\n var width = source.naturalWidth || source.videoWidth || source.width;\n var height = source.naturalHeight || source.videoHeight || source.height;\n this.resize(width, height);\n _super.prototype.update.call(this);\n };\n /** Destroy this {@link BaseImageResource} */\n BaseImageResource.prototype.dispose = function () {\n this.source = null;\n };\n return BaseImageResource;\n}(Resource));\n\n/**\n * @interface OffscreenCanvas\n */\n/**\n * Resource type for HTMLCanvasElement.\n *\n * @memberof PIXI\n */\nvar CanvasResource = /** @class */ (function (_super) {\n __extends(CanvasResource, _super);\n /**\n * @param source - Canvas element to use\n */\n // eslint-disable-next-line @typescript-eslint/no-useless-constructor\n function CanvasResource(source) {\n return _super.call(this, source) || this;\n }\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is HTMLCanvasElement or OffscreenCanvas\n */\n CanvasResource.test = function (source) {\n var OffscreenCanvas = globalThis.OffscreenCanvas;\n // Check for browsers that don't yet support OffscreenCanvas\n if (OffscreenCanvas && source instanceof OffscreenCanvas) {\n return true;\n }\n return globalThis.HTMLCanvasElement && source instanceof HTMLCanvasElement;\n };\n return CanvasResource;\n}(BaseImageResource));\n\n/**\n * Resource for a CubeTexture which contains six resources.\n *\n * @memberof PIXI\n */\nvar CubeResource = /** @class */ (function (_super) {\n __extends(CubeResource, _super);\n /**\n * @param {Array<string|PIXI.Resource>} [source] - Collection of URLs or resources\n * to use as the sides of the cube.\n * @param options - ImageResource options\n * @param {number} [options.width] - Width of resource\n * @param {number} [options.height] - Height of resource\n * @param {number} [options.autoLoad=true] - Whether to auto-load resources\n * @param {number} [options.linkBaseTexture=true] - In case BaseTextures are supplied,\n * whether to copy them or use\n */\n function CubeResource(source, options) {\n var _this = this;\n var _a = options || {}, width = _a.width, height = _a.height, autoLoad = _a.autoLoad, linkBaseTexture = _a.linkBaseTexture;\n if (source && source.length !== CubeResource.SIDES) {\n throw new Error(\"Invalid length. Got \" + source.length + \", expected 6\");\n }\n _this = _super.call(this, 6, { width: width, height: height }) || this;\n for (var i = 0; i < CubeResource.SIDES; i++) {\n _this.items[i].target = TARGETS.TEXTURE_CUBE_MAP_POSITIVE_X + i;\n }\n _this.linkBaseTexture = linkBaseTexture !== false;\n if (source) {\n _this.initFromArray(source, options);\n }\n if (autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n /**\n * Add binding.\n *\n * @param baseTexture - parent base texture\n */\n CubeResource.prototype.bind = function (baseTexture) {\n _super.prototype.bind.call(this, baseTexture);\n baseTexture.target = TARGETS.TEXTURE_CUBE_MAP;\n };\n CubeResource.prototype.addBaseTextureAt = function (baseTexture, index, linkBaseTexture) {\n if (linkBaseTexture === undefined) {\n linkBaseTexture = this.linkBaseTexture;\n }\n if (!this.items[index]) {\n throw new Error(\"Index \" + index + \" is out of bounds\");\n }\n if (!this.linkBaseTexture\n || baseTexture.parentTextureArray\n || Object.keys(baseTexture._glTextures).length > 0) {\n // copy mode\n if (baseTexture.resource) {\n this.addResourceAt(baseTexture.resource, index);\n }\n else {\n throw new Error(\"CubeResource does not support copying of renderTexture.\");\n }\n }\n else {\n // link mode, the difficult one!\n baseTexture.target = TARGETS.TEXTURE_CUBE_MAP_POSITIVE_X + index;\n baseTexture.parentTextureArray = this.baseTexture;\n this.items[index] = baseTexture;\n }\n if (baseTexture.valid && !this.valid) {\n this.resize(baseTexture.realWidth, baseTexture.realHeight);\n }\n this.items[index] = baseTexture;\n return this;\n };\n /**\n * Upload the resource\n *\n * @returns {boolean} true is success\n */\n CubeResource.prototype.upload = function (renderer, _baseTexture, glTexture) {\n var dirty = this.itemDirtyIds;\n for (var i = 0; i < CubeResource.SIDES; i++) {\n var side = this.items[i];\n if (dirty[i] < side.dirtyId) {\n if (side.valid && side.resource) {\n side.resource.upload(renderer, side, glTexture);\n dirty[i] = side.dirtyId;\n }\n else if (dirty[i] < -1) {\n // either item is not valid yet, either its a renderTexture\n // allocate the memory\n renderer.gl.texImage2D(side.target, 0, glTexture.internalFormat, _baseTexture.realWidth, _baseTexture.realHeight, 0, _baseTexture.format, glTexture.type, null);\n dirty[i] = -1;\n }\n }\n }\n return true;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is an array of 6 elements\n */\n CubeResource.test = function (source) {\n return Array.isArray(source) && source.length === CubeResource.SIDES;\n };\n /** Number of texture sides to store for CubeResources. */\n CubeResource.SIDES = 6;\n return CubeResource;\n}(AbstractMultiResource));\n\n/**\n * Resource type for HTMLImageElement.\n *\n * @memberof PIXI\n */\nvar ImageResource = /** @class */ (function (_super) {\n __extends(ImageResource, _super);\n /**\n * @param source - image source or URL\n * @param options\n * @param {boolean} [options.autoLoad=true] - start loading process\n * @param {boolean} [options.createBitmap=PIXI.settings.CREATE_IMAGE_BITMAP] - whether its required to create\n * a bitmap before upload\n * @param {boolean} [options.crossorigin=true] - Load image using cross origin\n * @param {PIXI.ALPHA_MODES} [options.alphaMode=PIXI.ALPHA_MODES.UNPACK] - Premultiply image alpha in bitmap\n */\n function ImageResource(source, options) {\n var _this = this;\n options = options || {};\n if (!(source instanceof HTMLImageElement)) {\n var imageElement = new Image();\n BaseImageResource.crossOrigin(imageElement, source, options.crossorigin);\n imageElement.src = source;\n source = imageElement;\n }\n _this = _super.call(this, source) || this;\n // FireFox 68, and possibly other versions, seems like setting the HTMLImageElement#width and #height\n // to non-zero values before its loading completes if images are in a cache.\n // Because of this, need to set the `_width` and the `_height` to zero to avoid uploading incomplete images.\n // Please refer to the issue #5968 (https://github.com/pixijs/pixi.js/issues/5968).\n if (!source.complete && !!_this._width && !!_this._height) {\n _this._width = 0;\n _this._height = 0;\n }\n _this.url = source.src;\n _this._process = null;\n _this.preserveBitmap = false;\n _this.createBitmap = (options.createBitmap !== undefined\n ? options.createBitmap : settings.CREATE_IMAGE_BITMAP) && !!globalThis.createImageBitmap;\n _this.alphaMode = typeof options.alphaMode === 'number' ? options.alphaMode : null;\n _this.bitmap = null;\n _this._load = null;\n if (options.autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n /**\n * Returns a promise when image will be loaded and processed.\n *\n * @param createBitmap - whether process image into bitmap\n */\n ImageResource.prototype.load = function (createBitmap) {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n if (createBitmap !== undefined) {\n this.createBitmap = createBitmap;\n }\n this._load = new Promise(function (resolve, reject) {\n var source = _this.source;\n _this.url = source.src;\n var completed = function () {\n if (_this.destroyed) {\n return;\n }\n source.onload = null;\n source.onerror = null;\n _this.resize(source.width, source.height);\n _this._load = null;\n if (_this.createBitmap) {\n resolve(_this.process());\n }\n else {\n resolve(_this);\n }\n };\n if (source.complete && source.src) {\n completed();\n }\n else {\n source.onload = completed;\n source.onerror = function (event) {\n // Avoids Promise freezing when resource broken\n reject(event);\n _this.onError.emit(event);\n };\n }\n });\n return this._load;\n };\n /**\n * Called when we need to convert image into BitmapImage.\n * Can be called multiple times, real promise is cached inside.\n *\n * @return - Cached promise to fill that bitmap\n */\n ImageResource.prototype.process = function () {\n var _this = this;\n var source = this.source;\n if (this._process !== null) {\n return this._process;\n }\n if (this.bitmap !== null || !globalThis.createImageBitmap) {\n return Promise.resolve(this);\n }\n var createImageBitmap = globalThis.createImageBitmap;\n var cors = !source.crossOrigin || source.crossOrigin === 'anonymous';\n this._process = fetch(source.src, {\n mode: cors ? 'cors' : 'no-cors'\n })\n .then(function (r) { return r.blob(); })\n .then(function (blob) { return createImageBitmap(blob, 0, 0, source.width, source.height, {\n premultiplyAlpha: _this.alphaMode === ALPHA_MODES.UNPACK ? 'premultiply' : 'none',\n }); })\n .then(function (bitmap) {\n if (_this.destroyed) {\n return Promise.reject();\n }\n _this.bitmap = bitmap;\n _this.update();\n _this._process = null;\n return Promise.resolve(_this);\n });\n return this._process;\n };\n /**\n * Upload the image resource to GPU.\n *\n * @param renderer - Renderer to upload to\n * @param baseTexture - BaseTexture for this resource\n * @param glTexture - GLTexture to use\n * @returns {boolean} true is success\n */\n ImageResource.prototype.upload = function (renderer, baseTexture, glTexture) {\n if (typeof this.alphaMode === 'number') {\n // bitmap stores unpack premultiply flag, we dont have to notify texImage2D about it\n baseTexture.alphaMode = this.alphaMode;\n }\n if (!this.createBitmap) {\n return _super.prototype.upload.call(this, renderer, baseTexture, glTexture);\n }\n if (!this.bitmap) {\n // yeah, ignore the output\n this.process();\n if (!this.bitmap) {\n return false;\n }\n }\n _super.prototype.upload.call(this, renderer, baseTexture, glTexture, this.bitmap);\n if (!this.preserveBitmap) {\n // checks if there are other renderers that possibly need this bitmap\n var flag = true;\n var glTextures = baseTexture._glTextures;\n for (var key in glTextures) {\n var otherTex = glTextures[key];\n if (otherTex !== glTexture && otherTex.dirtyId !== baseTexture.dirtyId) {\n flag = false;\n break;\n }\n }\n if (flag) {\n if (this.bitmap.close) {\n this.bitmap.close();\n }\n this.bitmap = null;\n }\n }\n return true;\n };\n /** Destroys this resource. */\n ImageResource.prototype.dispose = function () {\n this.source.onload = null;\n this.source.onerror = null;\n _super.prototype.dispose.call(this);\n if (this.bitmap) {\n this.bitmap.close();\n this.bitmap = null;\n }\n this._process = null;\n this._load = null;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is string or HTMLImageElement\n */\n ImageResource.test = function (source) {\n return typeof source === 'string' || source instanceof HTMLImageElement;\n };\n return ImageResource;\n}(BaseImageResource));\n\n/**\n * Resource type for SVG elements and graphics.\n *\n * @memberof PIXI\n */\nvar SVGResource = /** @class */ (function (_super) {\n __extends(SVGResource, _super);\n /**\n * @param sourceBase64 - Base64 encoded SVG element or URL for SVG file.\n * @param {object} [options] - Options to use\n * @param {number} [options.scale=1] - Scale to apply to SVG. Overridden by...\n * @param {number} [options.width] - Rasterize SVG this wide. Aspect ratio preserved if height not specified.\n * @param {number} [options.height] - Rasterize SVG this high. Aspect ratio preserved if width not specified.\n * @param {boolean} [options.autoLoad=true] - Start loading right away.\n */\n function SVGResource(sourceBase64, options) {\n var _this = this;\n options = options || {};\n _this = _super.call(this, document.createElement('canvas')) || this;\n _this._width = 0;\n _this._height = 0;\n _this.svg = sourceBase64;\n _this.scale = options.scale || 1;\n _this._overrideWidth = options.width;\n _this._overrideHeight = options.height;\n _this._resolve = null;\n _this._crossorigin = options.crossorigin;\n _this._load = null;\n if (options.autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n SVGResource.prototype.load = function () {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n this._load = new Promise(function (resolve) {\n // Save this until after load is finished\n _this._resolve = function () {\n _this.resize(_this.source.width, _this.source.height);\n resolve(_this);\n };\n // Convert SVG inline string to data-uri\n if (SVGResource.SVG_XML.test(_this.svg.trim())) {\n if (!btoa) {\n throw new Error('Your browser doesn\\'t support base64 conversions.');\n }\n _this.svg = \"data:image/svg+xml;base64,\" + btoa(unescape(encodeURIComponent(_this.svg)));\n }\n _this._loadSvg();\n });\n return this._load;\n };\n /** Loads an SVG image from `imageUrl` or `data URL`. */\n SVGResource.prototype._loadSvg = function () {\n var _this = this;\n var tempImage = new Image();\n BaseImageResource.crossOrigin(tempImage, this.svg, this._crossorigin);\n tempImage.src = this.svg;\n tempImage.onerror = function (event) {\n if (!_this._resolve) {\n return;\n }\n tempImage.onerror = null;\n _this.onError.emit(event);\n };\n tempImage.onload = function () {\n if (!_this._resolve) {\n return;\n }\n var svgWidth = tempImage.width;\n var svgHeight = tempImage.height;\n if (!svgWidth || !svgHeight) {\n throw new Error('The SVG image must have width and height defined (in pixels), canvas API needs them.');\n }\n // Set render size\n var width = svgWidth * _this.scale;\n var height = svgHeight * _this.scale;\n if (_this._overrideWidth || _this._overrideHeight) {\n width = _this._overrideWidth || _this._overrideHeight / svgHeight * svgWidth;\n height = _this._overrideHeight || _this._overrideWidth / svgWidth * svgHeight;\n }\n width = Math.round(width);\n height = Math.round(height);\n // Create a canvas element\n var canvas = _this.source;\n canvas.width = width;\n canvas.height = height;\n canvas._pixiId = \"canvas_\" + uid();\n // Draw the Svg to the canvas\n canvas\n .getContext('2d')\n .drawImage(tempImage, 0, 0, svgWidth, svgHeight, 0, 0, width, height);\n _this._resolve();\n _this._resolve = null;\n };\n };\n /**\n * Get size from an svg string using a regular expression.\n *\n * @param svgString - a serialized svg element\n * @return - image extension\n */\n SVGResource.getSize = function (svgString) {\n var sizeMatch = SVGResource.SVG_SIZE.exec(svgString);\n var size = {};\n if (sizeMatch) {\n size[sizeMatch[1]] = Math.round(parseFloat(sizeMatch[3]));\n size[sizeMatch[5]] = Math.round(parseFloat(sizeMatch[7]));\n }\n return size;\n };\n /** Destroys this texture. */\n SVGResource.prototype.dispose = function () {\n _super.prototype.dispose.call(this);\n this._resolve = null;\n this._crossorigin = null;\n };\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @param {string} extension - The extension of source, if set\n * @return {boolean} - If the source is a SVG source or data file\n */\n SVGResource.test = function (source, extension) {\n // url file extension is SVG\n return extension === 'svg'\n // source is SVG data-uri\n || (typeof source === 'string' && (/^data:image\\/svg\\+xml(;(charset=utf8|utf8))?;base64/).test(source))\n // source is SVG inline\n || (typeof source === 'string' && SVGResource.SVG_XML.test(source));\n };\n /**\n * Regular expression for SVG XML document.\n *\n * @example <?xml version=\"1.0\" encoding=\"utf-8\" ?><!-- image/svg --><svg\n * @readonly\n */\n SVGResource.SVG_XML = /^(<\\?xml[^?]+\\?>)?\\s*(<!--[^(-->)]*-->)?\\s*\\<svg/m;\n /**\n * Regular expression for SVG size.\n *\n * @example <svg width=\"100\" height=\"100\"></svg>\n * @readonly\n */\n SVGResource.SVG_SIZE = /<svg[^>]*(?:\\s(width|height)=('|\")(\\d*(?:\\.\\d+)?)(?:px)?('|\"))[^>]*(?:\\s(width|height)=('|\")(\\d*(?:\\.\\d+)?)(?:px)?('|\"))[^>]*>/i; // eslint-disable-line max-len\n return SVGResource;\n}(BaseImageResource));\n\n/**\n * Resource type for {@code HTMLVideoElement}.\n *\n * @memberof PIXI\n */\nvar VideoResource = /** @class */ (function (_super) {\n __extends(VideoResource, _super);\n /**\n * @param {HTMLVideoElement|object|string|Array<string|object>} source - Video element to use.\n * @param {object} [options] - Options to use\n * @param {boolean} [options.autoLoad=true] - Start loading the video immediately\n * @param {boolean} [options.autoPlay=true] - Start playing video immediately\n * @param {number} [options.updateFPS=0] - How many times a second to update the texture from the video.\n * Leave at 0 to update at every render.\n * @param {boolean} [options.crossorigin=true] - Load image using cross origin\n */\n function VideoResource(source, options) {\n var _this = this;\n options = options || {};\n if (!(source instanceof HTMLVideoElement)) {\n var videoElement = document.createElement('video');\n // workaround for https://github.com/pixijs/pixi.js/issues/5996\n videoElement.setAttribute('preload', 'auto');\n videoElement.setAttribute('webkit-playsinline', '');\n videoElement.setAttribute('playsinline', '');\n if (typeof source === 'string') {\n source = [source];\n }\n var firstSrc = source[0].src || source[0];\n BaseImageResource.crossOrigin(videoElement, firstSrc, options.crossorigin);\n // array of objects or strings\n for (var i = 0; i < source.length; ++i) {\n var sourceElement = document.createElement('source');\n var _a = source[i], src = _a.src, mime = _a.mime;\n src = src || source[i];\n var baseSrc = src.split('?').shift().toLowerCase();\n var ext = baseSrc.slice(baseSrc.lastIndexOf('.') + 1);\n mime = mime || VideoResource.MIME_TYPES[ext] || \"video/\" + ext;\n sourceElement.src = src;\n sourceElement.type = mime;\n videoElement.appendChild(sourceElement);\n }\n // Override the source\n source = videoElement;\n }\n _this = _super.call(this, source) || this;\n _this.noSubImage = true;\n _this._autoUpdate = true;\n _this._isConnectedToTicker = false;\n _this._updateFPS = options.updateFPS || 0;\n _this._msToNextUpdate = 0;\n _this.autoPlay = options.autoPlay !== false;\n _this._load = null;\n _this._resolve = null;\n // Bind for listeners\n _this._onCanPlay = _this._onCanPlay.bind(_this);\n _this._onError = _this._onError.bind(_this);\n if (options.autoLoad !== false) {\n _this.load();\n }\n return _this;\n }\n /**\n * Trigger updating of the texture.\n *\n * @param deltaTime - time delta since last tick\n */\n VideoResource.prototype.update = function (_deltaTime) {\n if (!this.destroyed) {\n // account for if video has had its playbackRate changed\n var elapsedMS = Ticker.shared.elapsedMS * this.source.playbackRate;\n this._msToNextUpdate = Math.floor(this._msToNextUpdate - elapsedMS);\n if (!this._updateFPS || this._msToNextUpdate <= 0) {\n _super.prototype.update.call(this);\n this._msToNextUpdate = this._updateFPS ? Math.floor(1000 / this._updateFPS) : 0;\n }\n }\n };\n /**\n * Start preloading the video resource.\n *\n * @return {Promise<void>} Handle the validate event\n */\n VideoResource.prototype.load = function () {\n var _this = this;\n if (this._load) {\n return this._load;\n }\n var source = this.source;\n if ((source.readyState === source.HAVE_ENOUGH_DATA || source.readyState === source.HAVE_FUTURE_DATA)\n && source.width && source.height) {\n source.complete = true;\n }\n source.addEventListener('play', this._onPlayStart.bind(this));\n source.addEventListener('pause', this._onPlayStop.bind(this));\n if (!this._isSourceReady()) {\n source.addEventListener('canplay', this._onCanPlay);\n source.addEventListener('canplaythrough', this._onCanPlay);\n source.addEventListener('error', this._onError, true);\n }\n else {\n this._onCanPlay();\n }\n this._load = new Promise(function (resolve) {\n if (_this.valid) {\n resolve(_this);\n }\n else {\n _this._resolve = resolve;\n source.load();\n }\n });\n return this._load;\n };\n /** Handle video error events. */\n VideoResource.prototype._onError = function (event) {\n this.source.removeEventListener('error', this._onError, true);\n this.onError.emit(event);\n };\n /**\n * Returns true if the underlying source is playing.\n *\n * @return - True if playing.\n */\n VideoResource.prototype._isSourcePlaying = function () {\n var source = this.source;\n return (source.currentTime > 0 && source.paused === false && source.ended === false && source.readyState > 2);\n };\n /**\n * Returns true if the underlying source is ready for playing.\n *\n * @return - True if ready.\n */\n VideoResource.prototype._isSourceReady = function () {\n var source = this.source;\n return source.readyState === 3 || source.readyState === 4;\n };\n /** Runs the update loop when the video is ready to play. */\n VideoResource.prototype._onPlayStart = function () {\n // Just in case the video has not received its can play even yet..\n if (!this.valid) {\n this._onCanPlay();\n }\n if (this.autoUpdate && !this._isConnectedToTicker) {\n Ticker.shared.add(this.update, this);\n this._isConnectedToTicker = true;\n }\n };\n /** Fired when a pause event is triggered, stops the update loop. */\n VideoResource.prototype._onPlayStop = function () {\n if (this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n };\n /** Fired when the video is loaded and ready to play. */\n VideoResource.prototype._onCanPlay = function () {\n var source = this.source;\n source.removeEventListener('canplay', this._onCanPlay);\n source.removeEventListener('canplaythrough', this._onCanPlay);\n var valid = this.valid;\n this.resize(source.videoWidth, source.videoHeight);\n // prevent multiple loaded dispatches..\n if (!valid && this._resolve) {\n this._resolve(this);\n this._resolve = null;\n }\n if (this._isSourcePlaying()) {\n this._onPlayStart();\n }\n else if (this.autoPlay) {\n source.play();\n }\n };\n /** Destroys this texture. */\n VideoResource.prototype.dispose = function () {\n if (this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n var source = this.source;\n if (source) {\n source.removeEventListener('error', this._onError, true);\n source.pause();\n source.src = '';\n source.load();\n }\n _super.prototype.dispose.call(this);\n };\n Object.defineProperty(VideoResource.prototype, \"autoUpdate\", {\n /** Should the base texture automatically update itself, set to true by default. */\n get: function () {\n return this._autoUpdate;\n },\n set: function (value) {\n if (value !== this._autoUpdate) {\n this._autoUpdate = value;\n if (!this._autoUpdate && this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n else if (this._autoUpdate && !this._isConnectedToTicker && this._isSourcePlaying()) {\n Ticker.shared.add(this.update, this);\n this._isConnectedToTicker = true;\n }\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(VideoResource.prototype, \"updateFPS\", {\n /**\n * How many times a second to update the texture from the video. Leave at 0 to update at every render.\n * A lower fps can help performance, as updating the texture at 60fps on a 30ps video may not be efficient.\n */\n get: function () {\n return this._updateFPS;\n },\n set: function (value) {\n if (value !== this._updateFPS) {\n this._updateFPS = value;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @param {string} extension - The extension of source, if set\n * @return {boolean} `true` if video source\n */\n VideoResource.test = function (source, extension) {\n return (globalThis.HTMLVideoElement && source instanceof HTMLVideoElement)\n || VideoResource.TYPES.indexOf(extension) > -1;\n };\n /**\n * List of common video file extensions supported by VideoResource.\n *\n * @readonly\n */\n VideoResource.TYPES = ['mp4', 'm4v', 'webm', 'ogg', 'ogv', 'h264', 'avi', 'mov'];\n /**\n * Map of video MIME types that can't be directly derived from file extensions.\n *\n * @readonly\n */\n VideoResource.MIME_TYPES = {\n ogv: 'video/ogg',\n mov: 'video/quicktime',\n m4v: 'video/mp4',\n };\n return VideoResource;\n}(BaseImageResource));\n\n/**\n * Resource type for ImageBitmap.\n *\n * @memberof PIXI\n */\nvar ImageBitmapResource = /** @class */ (function (_super) {\n __extends(ImageBitmapResource, _super);\n /**\n * @param source - Image element to use\n */\n // eslint-disable-next-line @typescript-eslint/no-useless-constructor\n function ImageBitmapResource(source) {\n return _super.call(this, source) || this;\n }\n /**\n * Used to auto-detect the type of resource.\n *\n * @param {*} source - The source object\n * @return {boolean} `true` if source is an ImageBitmap\n */\n ImageBitmapResource.test = function (source) {\n return !!globalThis.createImageBitmap && source instanceof ImageBitmap;\n };\n return ImageBitmapResource;\n}(BaseImageResource));\n\nINSTALLED.push(ImageResource, ImageBitmapResource, CanvasResource, VideoResource, SVGResource, BufferResource, CubeResource, ArrayResource);\n\nvar _resources = {\n __proto__: null,\n Resource: Resource,\n BaseImageResource: BaseImageResource,\n INSTALLED: INSTALLED,\n autoDetectResource: autoDetectResource,\n AbstractMultiResource: AbstractMultiResource,\n ArrayResource: ArrayResource,\n BufferResource: BufferResource,\n CanvasResource: CanvasResource,\n CubeResource: CubeResource,\n ImageResource: ImageResource,\n SVGResource: SVGResource,\n VideoResource: VideoResource,\n ImageBitmapResource: ImageBitmapResource\n};\n\n/**\n * Resource type for DepthTexture.\n *\n * @memberof PIXI\n */\nvar DepthResource = /** @class */ (function (_super) {\n __extends(DepthResource, _super);\n function DepthResource() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * Upload the texture to the GPU.\n *\n * @param renderer - Upload to the renderer\n * @param baseTexture - Reference to parent texture\n * @param glTexture - glTexture\n * @return - true is success\n */\n DepthResource.prototype.upload = function (renderer, baseTexture, glTexture) {\n var gl = renderer.gl;\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, baseTexture.alphaMode === ALPHA_MODES.UNPACK);\n var width = baseTexture.realWidth;\n var height = baseTexture.realHeight;\n if (glTexture.width === width && glTexture.height === height) {\n gl.texSubImage2D(baseTexture.target, 0, 0, 0, width, height, baseTexture.format, glTexture.type, this.data);\n }\n else {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(baseTexture.target, 0, glTexture.internalFormat, width, height, 0, baseTexture.format, glTexture.type, this.data);\n }\n return true;\n };\n return DepthResource;\n}(BufferResource));\n\n/**\n * A framebuffer can be used to render contents off of the screen. {@link PIXI.BaseRenderTexture} uses\n * one internally to render into itself. You can attach a depth or stencil buffer to a framebuffer.\n *\n * On WebGL 2 machines, shaders can output to multiple textures simultaneously with GLSL 300 ES.\n *\n * @memberof PIXI\n */\nvar Framebuffer = /** @class */ (function () {\n /**\n * @param width - Width of the frame buffer\n * @param height - Height of the frame buffer\n */\n function Framebuffer(width, height) {\n this.width = Math.round(width || 100);\n this.height = Math.round(height || 100);\n this.stencil = false;\n this.depth = false;\n this.dirtyId = 0;\n this.dirtyFormat = 0;\n this.dirtySize = 0;\n this.depthTexture = null;\n this.colorTextures = [];\n this.glFramebuffers = {};\n this.disposeRunner = new Runner('disposeFramebuffer');\n this.multisample = MSAA_QUALITY.NONE;\n }\n Object.defineProperty(Framebuffer.prototype, \"colorTexture\", {\n /**\n * Reference to the colorTexture.\n *\n * @readonly\n */\n get: function () {\n return this.colorTextures[0];\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Add texture to the colorTexture array.\n *\n * @param index - Index of the array to add the texture to\n * @param texture - Texture to add to the array\n */\n Framebuffer.prototype.addColorTexture = function (index, texture) {\n if (index === void 0) { index = 0; }\n // TODO add some validation to the texture - same width / height etc?\n this.colorTextures[index] = texture || new BaseTexture(null, {\n scaleMode: SCALE_MODES.NEAREST,\n resolution: 1,\n mipmap: MIPMAP_MODES.OFF,\n width: this.width,\n height: this.height,\n });\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /**\n * Add a depth texture to the frame buffer.\n *\n * @param texture - Texture to add.\n */\n Framebuffer.prototype.addDepthTexture = function (texture) {\n /* eslint-disable max-len */\n this.depthTexture = texture || new BaseTexture(new DepthResource(null, { width: this.width, height: this.height }), {\n scaleMode: SCALE_MODES.NEAREST,\n resolution: 1,\n width: this.width,\n height: this.height,\n mipmap: MIPMAP_MODES.OFF,\n format: FORMATS.DEPTH_COMPONENT,\n type: TYPES.UNSIGNED_SHORT,\n });\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /** Enable depth on the frame buffer. */\n Framebuffer.prototype.enableDepth = function () {\n this.depth = true;\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /** Enable stencil on the frame buffer. */\n Framebuffer.prototype.enableStencil = function () {\n this.stencil = true;\n this.dirtyId++;\n this.dirtyFormat++;\n return this;\n };\n /**\n * Resize the frame buffer\n *\n * @param width - Width of the frame buffer to resize to\n * @param height - Height of the frame buffer to resize to\n */\n Framebuffer.prototype.resize = function (width, height) {\n width = Math.round(width);\n height = Math.round(height);\n if (width === this.width && height === this.height)\n { return; }\n this.width = width;\n this.height = height;\n this.dirtyId++;\n this.dirtySize++;\n for (var i = 0; i < this.colorTextures.length; i++) {\n var texture = this.colorTextures[i];\n var resolution = texture.resolution;\n // take into account the fact the texture may have a different resolution..\n texture.setSize(width / resolution, height / resolution);\n }\n if (this.depthTexture) {\n var resolution = this.depthTexture.resolution;\n this.depthTexture.setSize(width / resolution, height / resolution);\n }\n };\n /** Disposes WebGL resources that are connected to this geometry. */\n Framebuffer.prototype.dispose = function () {\n this.disposeRunner.emit(this, false);\n };\n /** Destroys and removes the depth texture added to this framebuffer. */\n Framebuffer.prototype.destroyDepthTexture = function () {\n if (this.depthTexture) {\n this.depthTexture.destroy();\n this.depthTexture = null;\n ++this.dirtyId;\n ++this.dirtyFormat;\n }\n };\n return Framebuffer;\n}());\n\n/**\n * A BaseRenderTexture is a special texture that allows any PixiJS display object to be rendered to it.\n *\n * __Hint__: All DisplayObjects (i.e. Sprites) that render to a BaseRenderTexture should be preloaded\n * otherwise black rectangles will be drawn instead.\n *\n * A BaseRenderTexture takes a snapshot of any Display Object given to its render method. The position\n * and rotation of the given Display Objects is ignored. For example:\n *\n * ```js\n * let renderer = PIXI.autoDetectRenderer();\n * let baseRenderTexture = new PIXI.BaseRenderTexture({ width: 800, height: 600 });\n * let renderTexture = new PIXI.RenderTexture(baseRenderTexture);\n * let sprite = PIXI.Sprite.from(\"spinObj_01.png\");\n *\n * sprite.position.x = 800/2;\n * sprite.position.y = 600/2;\n * sprite.anchor.x = 0.5;\n * sprite.anchor.y = 0.5;\n *\n * renderer.render(sprite, {renderTexture});\n * ```\n *\n * The Sprite in this case will be rendered using its local transform. To render this sprite at 0,0\n * you can clear the transform\n *\n * ```js\n *\n * sprite.setTransform()\n *\n * let baseRenderTexture = new PIXI.BaseRenderTexture({ width: 100, height: 100 });\n * let renderTexture = new PIXI.RenderTexture(baseRenderTexture);\n *\n * renderer.render(sprite, {renderTexture}); // Renders to center of RenderTexture\n * ```\n *\n * @memberof PIXI\n */\nvar BaseRenderTexture = /** @class */ (function (_super) {\n __extends(BaseRenderTexture, _super);\n /**\n * @param options\n * @param {number} [options.width=100] - The width of the base render texture.\n * @param {number} [options.height=100] - The height of the base render texture.\n * @param {PIXI.SCALE_MODES} [options.scaleMode=PIXI.settings.SCALE_MODE] - See {@link PIXI.SCALE_MODES}\n * for possible values.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio\n * of the texture being generated.\n * @param {PIXI.MSAA_QUALITY} [options.multisample=PIXI.MSAA_QUALITY.NONE] - The number of samples of the frame buffer.\n */\n function BaseRenderTexture(options) {\n if (options === void 0) { options = {}; }\n var _this = this;\n if (typeof options === 'number') {\n /* eslint-disable prefer-rest-params */\n // Backward compatibility of signature\n var width = arguments[0];\n var height = arguments[1];\n var scaleMode = arguments[2];\n var resolution = arguments[3];\n options = { width: width, height: height, scaleMode: scaleMode, resolution: resolution };\n /* eslint-enable prefer-rest-params */\n }\n options.width = options.width || 100;\n options.height = options.height || 100;\n options.multisample = options.multisample !== undefined ? options.multisample : MSAA_QUALITY.NONE;\n _this = _super.call(this, null, options) || this;\n // Set defaults\n _this.mipmap = MIPMAP_MODES.OFF;\n _this.valid = true;\n _this.clearColor = [0, 0, 0, 0];\n _this.framebuffer = new Framebuffer(_this.realWidth, _this.realHeight)\n .addColorTexture(0, _this);\n _this.framebuffer.multisample = options.multisample;\n // TODO - could this be added the systems?\n _this.maskStack = [];\n _this.filterStack = [{}];\n return _this;\n }\n /**\n * Resizes the BaseRenderTexture.\n *\n * @param desiredWidth - The desired width to resize to.\n * @param desiredHeight - The desired height to resize to.\n */\n BaseRenderTexture.prototype.resize = function (desiredWidth, desiredHeight) {\n this.framebuffer.resize(desiredWidth * this.resolution, desiredHeight * this.resolution);\n this.setRealSize(this.framebuffer.width, this.framebuffer.height);\n };\n /**\n * Frees the texture and framebuffer from WebGL memory without destroying this texture object.\n * This means you can still use the texture later which will upload it to GPU\n * memory again.\n *\n * @fires PIXI.BaseTexture#dispose\n */\n BaseRenderTexture.prototype.dispose = function () {\n this.framebuffer.dispose();\n _super.prototype.dispose.call(this);\n };\n /** Destroys this texture. */\n BaseRenderTexture.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n this.framebuffer.destroyDepthTexture();\n this.framebuffer = null;\n };\n return BaseRenderTexture;\n}(BaseTexture));\n\n/**\n * Stores a texture's frame in UV coordinates, in\n * which everything lies in the rectangle `[(0,0), (1,0),\n * (1,1), (0,1)]`.\n *\n * | Corner | Coordinates |\n * |--------------|-------------|\n * | Top-Left | `(x0,y0)` |\n * | Top-Right | `(x1,y1)` |\n * | Bottom-Right | `(x2,y2)` |\n * | Bottom-Left | `(x3,y3)` |\n *\n * @protected\n * @memberof PIXI\n */\nvar TextureUvs = /** @class */ (function () {\n function TextureUvs() {\n this.x0 = 0;\n this.y0 = 0;\n this.x1 = 1;\n this.y1 = 0;\n this.x2 = 1;\n this.y2 = 1;\n this.x3 = 0;\n this.y3 = 1;\n this.uvsFloat32 = new Float32Array(8);\n }\n /**\n * Sets the texture Uvs based on the given frame information.\n *\n * @protected\n * @param frame - The frame of the texture\n * @param baseFrame - The base frame of the texture\n * @param rotate - Rotation of frame, see {@link PIXI.groupD8}\n */\n TextureUvs.prototype.set = function (frame, baseFrame, rotate) {\n var tw = baseFrame.width;\n var th = baseFrame.height;\n if (rotate) {\n // width and height div 2 div baseFrame size\n var w2 = frame.width / 2 / tw;\n var h2 = frame.height / 2 / th;\n // coordinates of center\n var cX = (frame.x / tw) + w2;\n var cY = (frame.y / th) + h2;\n rotate = groupD8.add(rotate, groupD8.NW); // NW is top-left corner\n this.x0 = cX + (w2 * groupD8.uX(rotate));\n this.y0 = cY + (h2 * groupD8.uY(rotate));\n rotate = groupD8.add(rotate, 2); // rotate 90 degrees clockwise\n this.x1 = cX + (w2 * groupD8.uX(rotate));\n this.y1 = cY + (h2 * groupD8.uY(rotate));\n rotate = groupD8.add(rotate, 2);\n this.x2 = cX + (w2 * groupD8.uX(rotate));\n this.y2 = cY + (h2 * groupD8.uY(rotate));\n rotate = groupD8.add(rotate, 2);\n this.x3 = cX + (w2 * groupD8.uX(rotate));\n this.y3 = cY + (h2 * groupD8.uY(rotate));\n }\n else {\n this.x0 = frame.x / tw;\n this.y0 = frame.y / th;\n this.x1 = (frame.x + frame.width) / tw;\n this.y1 = frame.y / th;\n this.x2 = (frame.x + frame.width) / tw;\n this.y2 = (frame.y + frame.height) / th;\n this.x3 = frame.x / tw;\n this.y3 = (frame.y + frame.height) / th;\n }\n this.uvsFloat32[0] = this.x0;\n this.uvsFloat32[1] = this.y0;\n this.uvsFloat32[2] = this.x1;\n this.uvsFloat32[3] = this.y1;\n this.uvsFloat32[4] = this.x2;\n this.uvsFloat32[5] = this.y2;\n this.uvsFloat32[6] = this.x3;\n this.uvsFloat32[7] = this.y3;\n };\n TextureUvs.prototype.toString = function () {\n return \"[@pixi/core:TextureUvs \"\n + (\"x0=\" + this.x0 + \" y0=\" + this.y0 + \" \")\n + (\"x1=\" + this.x1 + \" y1=\" + this.y1 + \" x2=\" + this.x2 + \" \")\n + (\"y2=\" + this.y2 + \" x3=\" + this.x3 + \" y3=\" + this.y3)\n + \"]\";\n };\n return TextureUvs;\n}());\n\nvar DEFAULT_UVS = new TextureUvs();\n/**\n * A texture stores the information that represents an image or part of an image.\n *\n * It cannot be added to the display list directly; instead use it as the texture for a Sprite.\n * If no frame is provided for a texture, then the whole image is used.\n *\n * You can directly create a texture from an image and then reuse it multiple times like this :\n *\n * ```js\n * let texture = PIXI.Texture.from('assets/image.png');\n * let sprite1 = new PIXI.Sprite(texture);\n * let sprite2 = new PIXI.Sprite(texture);\n * ```\n *\n * If you didnt pass the texture frame to constructor, it enables `noFrame` mode:\n * it subscribes on baseTexture events, it automatically resizes at the same time as baseTexture.\n *\n * Textures made from SVGs, loaded or not, cannot be used before the file finishes processing.\n * You can check for this by checking the sprite's _textureID property.\n * ```js\n * var texture = PIXI.Texture.from('assets/image.svg');\n * var sprite1 = new PIXI.Sprite(texture);\n * //sprite1._textureID should not be undefined if the texture has finished processing the SVG file\n * ```\n * You can use a ticker or rAF to ensure your sprites load the finished textures after processing. See issue #3068.\n *\n * @memberof PIXI\n * @typeParam R - The BaseTexture's Resource type.\n */\nvar Texture = /** @class */ (function (_super) {\n __extends(Texture, _super);\n /**\n * @param baseTexture - The base texture source to create the texture from\n * @param frame - The rectangle frame of the texture to show\n * @param orig - The area of original texture\n * @param trim - Trimmed rectangle of original texture\n * @param rotate - indicates how the texture was rotated by texture packer. See {@link PIXI.groupD8}\n * @param anchor - Default anchor point used for sprite placement / rotation\n */\n function Texture(baseTexture, frame, orig, trim, rotate, anchor) {\n var _this = _super.call(this) || this;\n _this.noFrame = false;\n if (!frame) {\n _this.noFrame = true;\n frame = new Rectangle(0, 0, 1, 1);\n }\n if (baseTexture instanceof Texture) {\n baseTexture = baseTexture.baseTexture;\n }\n _this.baseTexture = baseTexture;\n _this._frame = frame;\n _this.trim = trim;\n _this.valid = false;\n _this._uvs = DEFAULT_UVS;\n _this.uvMatrix = null;\n _this.orig = orig || frame; // new Rectangle(0, 0, 1, 1);\n _this._rotate = Number(rotate || 0);\n if (rotate === true) {\n // this is old texturepacker legacy, some games/libraries are passing \"true\" for rotated textures\n _this._rotate = 2;\n }\n else if (_this._rotate % 2 !== 0) {\n throw new Error('attempt to use diamond-shaped UVs. If you are sure, set rotation manually');\n }\n _this.defaultAnchor = anchor ? new Point(anchor.x, anchor.y) : new Point(0, 0);\n _this._updateID = 0;\n _this.textureCacheIds = [];\n if (!baseTexture.valid) {\n baseTexture.once('loaded', _this.onBaseTextureUpdated, _this);\n }\n else if (_this.noFrame) {\n // if there is no frame we should monitor for any base texture changes..\n if (baseTexture.valid) {\n _this.onBaseTextureUpdated(baseTexture);\n }\n }\n else {\n _this.frame = frame;\n }\n if (_this.noFrame) {\n baseTexture.on('update', _this.onBaseTextureUpdated, _this);\n }\n return _this;\n }\n /**\n * Updates this texture on the gpu.\n *\n * Calls the TextureResource update.\n *\n * If you adjusted `frame` manually, please call `updateUvs()` instead.\n */\n Texture.prototype.update = function () {\n if (this.baseTexture.resource) {\n this.baseTexture.resource.update();\n }\n };\n /**\n * Called when the base texture is updated\n *\n * @protected\n * @param baseTexture - The base texture.\n */\n Texture.prototype.onBaseTextureUpdated = function (baseTexture) {\n if (this.noFrame) {\n if (!this.baseTexture.valid) {\n return;\n }\n this._frame.width = baseTexture.width;\n this._frame.height = baseTexture.height;\n this.valid = true;\n this.updateUvs();\n }\n else {\n // TODO this code looks confusing.. boo to abusing getters and setters!\n // if user gave us frame that has bigger size than resized texture it can be a problem\n this.frame = this._frame;\n }\n this.emit('update', this);\n };\n /**\n * Destroys this texture\n *\n * @param [destroyBase=false] - Whether to destroy the base texture as well\n */\n Texture.prototype.destroy = function (destroyBase) {\n if (this.baseTexture) {\n if (destroyBase) {\n var resource = this.baseTexture.resource;\n // delete the texture if it exists in the texture cache..\n // this only needs to be removed if the base texture is actually destroyed too..\n if (resource && resource.url && TextureCache[resource.url]) {\n Texture.removeFromCache(resource.url);\n }\n this.baseTexture.destroy();\n }\n this.baseTexture.off('loaded', this.onBaseTextureUpdated, this);\n this.baseTexture.off('update', this.onBaseTextureUpdated, this);\n this.baseTexture = null;\n }\n this._frame = null;\n this._uvs = null;\n this.trim = null;\n this.orig = null;\n this.valid = false;\n Texture.removeFromCache(this);\n this.textureCacheIds = null;\n };\n /**\n * Creates a new texture object that acts the same as this one.\n *\n * @return - The new texture\n */\n Texture.prototype.clone = function () {\n var clonedFrame = this._frame.clone();\n var clonedOrig = this._frame === this.orig ? clonedFrame : this.orig.clone();\n var clonedTexture = new Texture(this.baseTexture, !this.noFrame && clonedFrame, clonedOrig, this.trim && this.trim.clone(), this.rotate, this.defaultAnchor);\n if (this.noFrame) {\n clonedTexture._frame = clonedFrame;\n }\n return clonedTexture;\n };\n /**\n * Updates the internal WebGL UV cache. Use it after you change `frame` or `trim` of the texture.\n * Call it after changing the frame\n */\n Texture.prototype.updateUvs = function () {\n if (this._uvs === DEFAULT_UVS) {\n this._uvs = new TextureUvs();\n }\n this._uvs.set(this._frame, this.baseTexture, this.rotate);\n this._updateID++;\n };\n /**\n * Helper function that creates a new Texture based on the source you provide.\n * The source can be - frame id, image url, video url, canvas element, video element, base texture\n *\n * @param {string|HTMLImageElement|HTMLCanvasElement|HTMLVideoElement|PIXI.BaseTexture} source -\n * Source to create texture from\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @param {string} [options.pixiIdPrefix=pixiid] - If a source has no id, this is the prefix of the generated id\n * @param {boolean} [strict] - Enforce strict-mode, see {@link PIXI.settings.STRICT_TEXTURE_CACHE}.\n * @return {PIXI.Texture} The newly created texture\n */\n Texture.from = function (source, options, strict) {\n if (options === void 0) { options = {}; }\n if (strict === void 0) { strict = settings.STRICT_TEXTURE_CACHE; }\n var isFrame = typeof source === 'string';\n var cacheId = null;\n if (isFrame) {\n cacheId = source;\n }\n else if (source instanceof BaseTexture) {\n if (!source.cacheId) {\n var prefix = (options && options.pixiIdPrefix) || 'pixiid';\n source.cacheId = prefix + \"-\" + uid();\n BaseTexture.addToCache(source, source.cacheId);\n }\n cacheId = source.cacheId;\n }\n else {\n if (!source._pixiId) {\n var prefix = (options && options.pixiIdPrefix) || 'pixiid';\n source._pixiId = prefix + \"_\" + uid();\n }\n cacheId = source._pixiId;\n }\n var texture = TextureCache[cacheId];\n // Strict-mode rejects invalid cacheIds\n if (isFrame && strict && !texture) {\n throw new Error(\"The cacheId \\\"\" + cacheId + \"\\\" does not exist in TextureCache.\");\n }\n if (!texture && !(source instanceof BaseTexture)) {\n if (!options.resolution) {\n options.resolution = getResolutionOfUrl(source);\n }\n texture = new Texture(new BaseTexture(source, options));\n texture.baseTexture.cacheId = cacheId;\n BaseTexture.addToCache(texture.baseTexture, cacheId);\n Texture.addToCache(texture, cacheId);\n }\n else if (!texture && (source instanceof BaseTexture)) {\n texture = new Texture(source);\n Texture.addToCache(texture, cacheId);\n }\n // lets assume its a base texture!\n return texture;\n };\n /**\n * Useful for loading textures via URLs. Use instead of `Texture.from` because\n * it does a better job of handling failed URLs more effectively. This also ignores\n * `PIXI.settings.STRICT_TEXTURE_CACHE`. Works for Videos, SVGs, Images.\n *\n * @param url - The remote URL to load.\n * @param options - Optional options to include\n * @return - A Promise that resolves to a Texture.\n */\n Texture.fromURL = function (url, options) {\n var resourceOptions = Object.assign({ autoLoad: false }, options === null || options === void 0 ? void 0 : options.resourceOptions);\n var texture = Texture.from(url, Object.assign({ resourceOptions: resourceOptions }, options), false);\n var resource = texture.baseTexture.resource;\n // The texture was already loaded\n if (texture.baseTexture.valid) {\n return Promise.resolve(texture);\n }\n // Manually load the texture, this should allow users to handle load errors\n return resource.load().then(function () { return Promise.resolve(texture); });\n };\n /**\n * Create a new Texture with a BufferResource from a Float32Array.\n * RGBA values are floats from 0 to 1.\n *\n * @param {Float32Array|Uint8Array} buffer - The optional array to use, if no data\n * is provided, a new Float32Array is created.\n * @param width - Width of the resource\n * @param height - Height of the resource\n * @param options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @return - The resulting new BaseTexture\n */\n Texture.fromBuffer = function (buffer, width, height, options) {\n return new Texture(BaseTexture.fromBuffer(buffer, width, height, options));\n };\n /**\n * Create a texture from a source and add to the cache.\n *\n * @param {HTMLImageElement|HTMLCanvasElement|string} source - The input source.\n * @param imageUrl - File name of texture, for cache and resolving resolution.\n * @param name - Human readable name for the texture cache. If no name is\n * specified, only `imageUrl` will be used as the cache ID.\n * @return - Output texture\n */\n Texture.fromLoader = function (source, imageUrl, name, options) {\n var baseTexture = new BaseTexture(source, Object.assign({\n scaleMode: settings.SCALE_MODE,\n resolution: getResolutionOfUrl(imageUrl),\n }, options));\n var resource = baseTexture.resource;\n if (resource instanceof ImageResource) {\n resource.url = imageUrl;\n }\n var texture = new Texture(baseTexture);\n // No name, use imageUrl instead\n if (!name) {\n name = imageUrl;\n }\n // lets also add the frame to pixi's global cache for 'fromLoader' function\n BaseTexture.addToCache(texture.baseTexture, name);\n Texture.addToCache(texture, name);\n // also add references by url if they are different.\n if (name !== imageUrl) {\n BaseTexture.addToCache(texture.baseTexture, imageUrl);\n Texture.addToCache(texture, imageUrl);\n }\n // Generally images are valid right away\n if (texture.baseTexture.valid) {\n return Promise.resolve(texture);\n }\n // SVG assets need to be parsed async, let's wait\n return new Promise(function (resolve) {\n texture.baseTexture.once('loaded', function () { return resolve(texture); });\n });\n };\n /**\n * Adds a Texture to the global TextureCache. This cache is shared across the whole PIXI object.\n *\n * @param texture - The Texture to add to the cache.\n * @param id - The id that the Texture will be stored against.\n */\n Texture.addToCache = function (texture, id) {\n if (id) {\n if (texture.textureCacheIds.indexOf(id) === -1) {\n texture.textureCacheIds.push(id);\n }\n if (TextureCache[id]) {\n // eslint-disable-next-line no-console\n console.warn(\"Texture added to the cache with an id [\" + id + \"] that already had an entry\");\n }\n TextureCache[id] = texture;\n }\n };\n /**\n * Remove a Texture from the global TextureCache.\n *\n * @param texture - id of a Texture to be removed, or a Texture instance itself\n * @return - The Texture that was removed\n */\n Texture.removeFromCache = function (texture) {\n if (typeof texture === 'string') {\n var textureFromCache = TextureCache[texture];\n if (textureFromCache) {\n var index = textureFromCache.textureCacheIds.indexOf(texture);\n if (index > -1) {\n textureFromCache.textureCacheIds.splice(index, 1);\n }\n delete TextureCache[texture];\n return textureFromCache;\n }\n }\n else if (texture && texture.textureCacheIds) {\n for (var i = 0; i < texture.textureCacheIds.length; ++i) {\n // Check that texture matches the one being passed in before deleting it from the cache.\n if (TextureCache[texture.textureCacheIds[i]] === texture) {\n delete TextureCache[texture.textureCacheIds[i]];\n }\n }\n texture.textureCacheIds.length = 0;\n return texture;\n }\n return null;\n };\n Object.defineProperty(Texture.prototype, \"resolution\", {\n /**\n * Returns resolution of baseTexture\n *\n * @readonly\n */\n get: function () {\n return this.baseTexture.resolution;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"frame\", {\n /**\n * The frame specifies the region of the base texture that this texture uses.\n * Please call `updateUvs()` after you change coordinates of `frame` manually.\n */\n get: function () {\n return this._frame;\n },\n set: function (frame) {\n this._frame = frame;\n this.noFrame = false;\n var x = frame.x, y = frame.y, width = frame.width, height = frame.height;\n var xNotFit = x + width > this.baseTexture.width;\n var yNotFit = y + height > this.baseTexture.height;\n if (xNotFit || yNotFit) {\n var relationship = xNotFit && yNotFit ? 'and' : 'or';\n var errorX = \"X: \" + x + \" + \" + width + \" = \" + (x + width) + \" > \" + this.baseTexture.width;\n var errorY = \"Y: \" + y + \" + \" + height + \" = \" + (y + height) + \" > \" + this.baseTexture.height;\n throw new Error('Texture Error: frame does not fit inside the base Texture dimensions: '\n + (errorX + \" \" + relationship + \" \" + errorY));\n }\n this.valid = width && height && this.baseTexture.valid;\n if (!this.trim && !this.rotate) {\n this.orig = frame;\n }\n if (this.valid) {\n this.updateUvs();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"rotate\", {\n /**\n * Indicates whether the texture is rotated inside the atlas\n * set to 2 to compensate for texture packer rotation\n * set to 6 to compensate for spine packer rotation\n * can be used to rotate or mirror sprites\n * See {@link PIXI.groupD8} for explanation\n */\n get: function () {\n return this._rotate;\n },\n set: function (rotate) {\n this._rotate = rotate;\n if (this.valid) {\n this.updateUvs();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"width\", {\n /** The width of the Texture in pixels. */\n get: function () {\n return this.orig.width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Texture.prototype, \"height\", {\n /** The height of the Texture in pixels. */\n get: function () {\n return this.orig.height;\n },\n enumerable: false,\n configurable: true\n });\n /** Utility function for BaseTexture|Texture cast. */\n Texture.prototype.castToBaseTexture = function () {\n return this.baseTexture;\n };\n return Texture;\n}(EventEmitter));\nfunction createWhiteTexture() {\n var canvas = document.createElement('canvas');\n canvas.width = 16;\n canvas.height = 16;\n var context = canvas.getContext('2d');\n context.fillStyle = 'white';\n context.fillRect(0, 0, 16, 16);\n return new Texture(new BaseTexture(new CanvasResource(canvas)));\n}\nfunction removeAllHandlers(tex) {\n tex.destroy = function _emptyDestroy() { };\n tex.on = function _emptyOn() { };\n tex.once = function _emptyOnce() { };\n tex.emit = function _emptyEmit() { };\n}\n/**\n * An empty texture, used often to not have to create multiple empty textures.\n * Can not be destroyed.\n *\n * @static\n * @constant\n * @member {PIXI.Texture}\n */\nTexture.EMPTY = new Texture(new BaseTexture());\nremoveAllHandlers(Texture.EMPTY);\nremoveAllHandlers(Texture.EMPTY.baseTexture);\n/**\n * A white texture of 16x16 size, used for graphics and other things\n * Can not be destroyed.\n *\n * @static\n * @constant\n * @member {PIXI.Texture}\n */\nTexture.WHITE = createWhiteTexture();\nremoveAllHandlers(Texture.WHITE);\nremoveAllHandlers(Texture.WHITE.baseTexture);\n\n/**\n * A RenderTexture is a special texture that allows any PixiJS display object to be rendered to it.\n *\n * __Hint__: All DisplayObjects (i.e. Sprites) that render to a RenderTexture should be preloaded\n * otherwise black rectangles will be drawn instead.\n *\n * __Hint-2__: The actual memory allocation will happen on first render.\n * You shouldn't create renderTextures each frame just to delete them after, try to reuse them.\n *\n * A RenderTexture takes a snapshot of any Display Object given to its render method. For example:\n *\n * ```js\n * let renderer = PIXI.autoDetectRenderer();\n * let renderTexture = PIXI.RenderTexture.create({ width: 800, height: 600 });\n * let sprite = PIXI.Sprite.from(\"spinObj_01.png\");\n *\n * sprite.position.x = 800/2;\n * sprite.position.y = 600/2;\n * sprite.anchor.x = 0.5;\n * sprite.anchor.y = 0.5;\n *\n * renderer.render(sprite, {renderTexture});\n * ```\n * Note that you should not create a new renderer, but reuse the same one as the rest of the application.\n *\n * The Sprite in this case will be rendered using its local transform. To render this sprite at 0,0\n * you can clear the transform\n *\n * ```js\n *\n * sprite.setTransform()\n *\n * let renderTexture = new PIXI.RenderTexture.create({ width: 100, height: 100 });\n *\n * renderer.render(sprite, {renderTexture}); // Renders to center of RenderTexture\n * ```\n *\n * @memberof PIXI\n */\nvar RenderTexture = /** @class */ (function (_super) {\n __extends(RenderTexture, _super);\n /**\n * @param baseRenderTexture - The base texture object that this texture uses.\n * @param frame - The rectangle frame of the texture to show.\n */\n function RenderTexture(baseRenderTexture, frame) {\n var _this = _super.call(this, baseRenderTexture, frame) || this;\n _this.valid = true;\n _this.filterFrame = null;\n _this.filterPoolKey = null;\n _this.updateUvs();\n return _this;\n }\n Object.defineProperty(RenderTexture.prototype, \"framebuffer\", {\n /**\n * Shortcut to `this.baseTexture.framebuffer`, saves baseTexture cast.\n *\n * @readonly\n */\n get: function () {\n return this.baseTexture.framebuffer;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(RenderTexture.prototype, \"multisample\", {\n /**\n * Shortcut to `this.framebuffer.multisample`.\n *\n * @default PIXI.MSAA_QUALITY.NONE\n */\n get: function () {\n return this.framebuffer.multisample;\n },\n set: function (value) {\n this.framebuffer.multisample = value;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Resizes the RenderTexture.\n *\n * @param desiredWidth - The desired width to resize to.\n * @param desiredHeight - The desired height to resize to.\n * @param resizeBaseTexture - Should the baseTexture.width and height values be resized as well?\n */\n RenderTexture.prototype.resize = function (desiredWidth, desiredHeight, resizeBaseTexture) {\n if (resizeBaseTexture === void 0) { resizeBaseTexture = true; }\n var resolution = this.baseTexture.resolution;\n var width = Math.round(desiredWidth * resolution) / resolution;\n var height = Math.round(desiredHeight * resolution) / resolution;\n // TODO - could be not required..\n this.valid = (width > 0 && height > 0);\n this._frame.width = this.orig.width = width;\n this._frame.height = this.orig.height = height;\n if (resizeBaseTexture) {\n this.baseTexture.resize(width, height);\n }\n this.updateUvs();\n };\n /**\n * Changes the resolution of baseTexture, but does not change framebuffer size.\n *\n * @param resolution - The new resolution to apply to RenderTexture\n */\n RenderTexture.prototype.setResolution = function (resolution) {\n var baseTexture = this.baseTexture;\n if (baseTexture.resolution === resolution) {\n return;\n }\n baseTexture.setResolution(resolution);\n this.resize(baseTexture.width, baseTexture.height, false);\n };\n RenderTexture.create = function (options) {\n var arguments$1 = arguments;\n\n var rest = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n rest[_i - 1] = arguments$1[_i];\n }\n // @deprecated fallback, old-style: create(width, height, scaleMode, resolution)\n if (typeof options === 'number') {\n deprecation('6.0.0', 'Arguments (width, height, scaleMode, resolution) have been deprecated.');\n /* eslint-disable prefer-rest-params */\n options = {\n width: options,\n height: rest[0],\n scaleMode: rest[1],\n resolution: rest[2],\n };\n /* eslint-enable prefer-rest-params */\n }\n return new RenderTexture(new BaseRenderTexture(options));\n };\n return RenderTexture;\n}(Texture));\n\n/**\n * Texture pool, used by FilterSystem and plugins.\n *\n * Stores collection of temporary pow2 or screen-sized renderTextures\n *\n * If you use custom RenderTexturePool for your filters, you can use methods\n * `getFilterTexture` and `returnFilterTexture` same as in\n *\n * @memberof PIXI\n */\nvar RenderTexturePool = /** @class */ (function () {\n /**\n * @param textureOptions - options that will be passed to BaseRenderTexture constructor\n * @param {PIXI.SCALE_MODES} [textureOptions.scaleMode] - See {@link PIXI.SCALE_MODES} for possible values.\n */\n function RenderTexturePool(textureOptions) {\n this.texturePool = {};\n this.textureOptions = textureOptions || {};\n this.enableFullScreen = false;\n this._pixelsWidth = 0;\n this._pixelsHeight = 0;\n }\n /**\n * Creates texture with params that were specified in pool constructor.\n *\n * @param realWidth - Width of texture in pixels.\n * @param realHeight - Height of texture in pixels.\n * @param multisample - Number of samples of the framebuffer.\n */\n RenderTexturePool.prototype.createTexture = function (realWidth, realHeight, multisample) {\n if (multisample === void 0) { multisample = MSAA_QUALITY.NONE; }\n var baseRenderTexture = new BaseRenderTexture(Object.assign({\n width: realWidth,\n height: realHeight,\n resolution: 1,\n multisample: multisample,\n }, this.textureOptions));\n return new RenderTexture(baseRenderTexture);\n };\n /**\n * Gets a Power-of-Two render texture or fullScreen texture\n *\n * @param minWidth - The minimum width of the render texture.\n * @param minHeight - The minimum height of the render texture.\n * @param resolution - The resolution of the render texture.\n * @param multisample - Number of samples of the render texture.\n * @return The new render texture.\n */\n RenderTexturePool.prototype.getOptimalTexture = function (minWidth, minHeight, resolution, multisample) {\n if (resolution === void 0) { resolution = 1; }\n if (multisample === void 0) { multisample = MSAA_QUALITY.NONE; }\n var key;\n minWidth = Math.ceil((minWidth * resolution) - 1e-6);\n minHeight = Math.ceil((minHeight * resolution) - 1e-6);\n if (!this.enableFullScreen || minWidth !== this._pixelsWidth || minHeight !== this._pixelsHeight) {\n minWidth = nextPow2(minWidth);\n minHeight = nextPow2(minHeight);\n key = (((minWidth & 0xFFFF) << 16) | (minHeight & 0xFFFF)) >>> 0;\n if (multisample > 1) {\n key += multisample * 0x100000000;\n }\n }\n else {\n key = multisample > 1 ? -multisample : -1;\n }\n if (!this.texturePool[key]) {\n this.texturePool[key] = [];\n }\n var renderTexture = this.texturePool[key].pop();\n if (!renderTexture) {\n renderTexture = this.createTexture(minWidth, minHeight, multisample);\n }\n renderTexture.filterPoolKey = key;\n renderTexture.setResolution(resolution);\n return renderTexture;\n };\n /**\n * Gets extra texture of the same size as input renderTexture\n *\n * `getFilterTexture(input, 0.5)` or `getFilterTexture(0.5, input)`\n *\n * @param input - renderTexture from which size and resolution will be copied\n * @param resolution - override resolution of the renderTexture\n * It overrides, it does not multiply\n * @param multisample - number of samples of the renderTexture\n * @returns\n */\n RenderTexturePool.prototype.getFilterTexture = function (input, resolution, multisample) {\n var filterTexture = this.getOptimalTexture(input.width, input.height, resolution || input.resolution, multisample || MSAA_QUALITY.NONE);\n filterTexture.filterFrame = input.filterFrame;\n return filterTexture;\n };\n /**\n * Place a render texture back into the pool.\n *\n * @param renderTexture - The renderTexture to free\n */\n RenderTexturePool.prototype.returnTexture = function (renderTexture) {\n var key = renderTexture.filterPoolKey;\n renderTexture.filterFrame = null;\n this.texturePool[key].push(renderTexture);\n };\n /**\n * Alias for returnTexture, to be compliant with FilterSystem interface.\n *\n * @param renderTexture - The renderTexture to free\n */\n RenderTexturePool.prototype.returnFilterTexture = function (renderTexture) {\n this.returnTexture(renderTexture);\n };\n /**\n * Clears the pool.\n *\n * @param destroyTextures - Destroy all stored textures.\n */\n RenderTexturePool.prototype.clear = function (destroyTextures) {\n destroyTextures = destroyTextures !== false;\n if (destroyTextures) {\n for (var i in this.texturePool) {\n var textures = this.texturePool[i];\n if (textures) {\n for (var j = 0; j < textures.length; j++) {\n textures[j].destroy(true);\n }\n }\n }\n }\n this.texturePool = {};\n };\n /**\n * If screen size was changed, drops all screen-sized textures,\n * sets new screen size, sets `enableFullScreen` to true\n *\n * Size is measured in pixels, `renderer.view` can be passed here, not `renderer.screen`\n *\n * @param size - Initial size of screen.\n */\n RenderTexturePool.prototype.setScreenSize = function (size) {\n if (size.width === this._pixelsWidth\n && size.height === this._pixelsHeight) {\n return;\n }\n this.enableFullScreen = size.width > 0 && size.height > 0;\n for (var i in this.texturePool) {\n if (!(Number(i) < 0)) {\n continue;\n }\n var textures = this.texturePool[i];\n if (textures) {\n for (var j = 0; j < textures.length; j++) {\n textures[j].destroy(true);\n }\n }\n this.texturePool[i] = [];\n }\n this._pixelsWidth = size.width;\n this._pixelsHeight = size.height;\n };\n /**\n * Key that is used to store fullscreen renderTextures in a pool\n *\n * @constant\n */\n RenderTexturePool.SCREEN_KEY = -1;\n return RenderTexturePool;\n}());\n\n/* eslint-disable max-len */\n/**\n * Holds the information for a single attribute structure required to render geometry.\n *\n * This does not contain the actual data, but instead has a buffer id that maps to a {@link PIXI.Buffer}\n * This can include anything from positions, uvs, normals, colors etc.\n *\n * @memberof PIXI\n */\nvar Attribute = /** @class */ (function () {\n /**\n * @param buffer - the id of the buffer that this attribute will look for\n * @param size - the size of the attribute. If you have 2 floats per vertex (eg position x and y) this would be 2.\n * @param normalized - should the data be normalized.\n * @param {PIXI.TYPES} [type=PIXI.TYPES.FLOAT] - what type of number is the attribute. Check {@link PIXI.TYPES} to see the ones available\n * @param [stride=0] - How far apart, in bytes, the start of each value is. (used for interleaving data)\n * @param [start=0] - How far into the array to start reading values (used for interleaving data)\n * @param [instance=false] - Whether the geometry is instanced.\n */\n function Attribute(buffer, size, normalized, type, stride, start, instance) {\n if (size === void 0) { size = 0; }\n if (normalized === void 0) { normalized = false; }\n if (type === void 0) { type = TYPES.FLOAT; }\n this.buffer = buffer;\n this.size = size;\n this.normalized = normalized;\n this.type = type;\n this.stride = stride;\n this.start = start;\n this.instance = instance;\n }\n /** Destroys the Attribute. */\n Attribute.prototype.destroy = function () {\n this.buffer = null;\n };\n /**\n * Helper function that creates an Attribute based on the information provided\n *\n * @param buffer - the id of the buffer that this attribute will look for\n * @param [size=0] - the size of the attribute. If you have 2 floats per vertex (eg position x and y) this would be 2\n * @param [normalized=false] - should the data be normalized.\n * @param [type=PIXI.TYPES.FLOAT] - what type of number is the attribute. Check {@link PIXI.TYPES} to see the ones available\n * @param [stride=0] - How far apart, in bytes, the start of each value is. (used for interleaving data)\n * @returns - A new {@link PIXI.Attribute} based on the information provided\n */\n Attribute.from = function (buffer, size, normalized, type, stride) {\n return new Attribute(buffer, size, normalized, type, stride);\n };\n return Attribute;\n}());\n\nvar UID = 0;\n/**\n * A wrapper for data so that it can be used and uploaded by WebGL\n *\n * @memberof PIXI\n */\nvar Buffer = /** @class */ (function () {\n /**\n * @param {ArrayBuffer| SharedArrayBuffer|ArrayBufferView} data - the data to store in the buffer.\n * @param _static - `true` for static buffer\n * @param index - `true` for index buffer\n */\n function Buffer(data, _static, index) {\n if (_static === void 0) { _static = true; }\n if (index === void 0) { index = false; }\n this.data = (data || new Float32Array(1));\n this._glBuffers = {};\n this._updateID = 0;\n this.index = index;\n this.static = _static;\n this.id = UID++;\n this.disposeRunner = new Runner('disposeBuffer');\n }\n // TODO could explore flagging only a partial upload?\n /**\n * Flags this buffer as requiring an upload to the GPU.\n * @param {ArrayBuffer|SharedArrayBuffer|ArrayBufferView|number[]} [data] - the data to update in the buffer.\n */\n Buffer.prototype.update = function (data) {\n if (data instanceof Array) {\n data = new Float32Array(data);\n }\n this.data = data || this.data;\n this._updateID++;\n };\n /** Disposes WebGL resources that are connected to this geometry. */\n Buffer.prototype.dispose = function () {\n this.disposeRunner.emit(this, false);\n };\n /** Destroys the buffer. */\n Buffer.prototype.destroy = function () {\n this.dispose();\n this.data = null;\n };\n Object.defineProperty(Buffer.prototype, \"index\", {\n get: function () {\n return this.type === BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n },\n /**\n * Flags whether this is an index buffer.\n *\n * Index buffers are of type `ELEMENT_ARRAY_BUFFER`. Note that setting this property to false will make\n * the buffer of type `ARRAY_BUFFER`.\n *\n * For backwards compatibility.\n */\n set: function (value) {\n this.type = value ? BUFFER_TYPE.ELEMENT_ARRAY_BUFFER : BUFFER_TYPE.ARRAY_BUFFER;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Helper function that creates a buffer based on an array or TypedArray\n *\n * @param {ArrayBufferView | number[]} data - the TypedArray that the buffer will store. If this is a regular Array it will be converted to a Float32Array.\n * @return - A new Buffer based on the data provided.\n */\n Buffer.from = function (data) {\n if (data instanceof Array) {\n data = new Float32Array(data);\n }\n return new Buffer(data);\n };\n return Buffer;\n}());\n\n/* eslint-disable object-shorthand */\nvar map = {\n Float32Array: Float32Array,\n Uint32Array: Uint32Array,\n Int32Array: Int32Array,\n Uint8Array: Uint8Array,\n};\nfunction interleaveTypedArrays(arrays, sizes) {\n var outSize = 0;\n var stride = 0;\n var views = {};\n for (var i = 0; i < arrays.length; i++) {\n stride += sizes[i];\n outSize += arrays[i].length;\n }\n var buffer = new ArrayBuffer(outSize * 4);\n var out = null;\n var littleOffset = 0;\n for (var i = 0; i < arrays.length; i++) {\n var size = sizes[i];\n var array = arrays[i];\n var type = getBufferType(array);\n if (!views[type]) {\n views[type] = new map[type](buffer);\n }\n out = views[type];\n for (var j = 0; j < array.length; j++) {\n var indexStart = ((j / size | 0) * stride) + littleOffset;\n var index = j % size;\n out[indexStart + index] = array[j];\n }\n littleOffset += size;\n }\n return new Float32Array(buffer);\n}\n\nvar byteSizeMap = { 5126: 4, 5123: 2, 5121: 1 };\nvar UID$1 = 0;\n/* eslint-disable object-shorthand */\nvar map$1 = {\n Float32Array: Float32Array,\n Uint32Array: Uint32Array,\n Int32Array: Int32Array,\n Uint8Array: Uint8Array,\n Uint16Array: Uint16Array,\n};\n/* eslint-disable max-len */\n/**\n * The Geometry represents a model. It consists of two components:\n * - GeometryStyle - The structure of the model such as the attributes layout\n * - GeometryData - the data of the model - this consists of buffers.\n * This can include anything from positions, uvs, normals, colors etc.\n *\n * Geometry can be defined without passing in a style or data if required (thats how I prefer!)\n *\n * ```js\n * let geometry = new PIXI.Geometry();\n *\n * geometry.addAttribute('positions', [0, 0, 100, 0, 100, 100, 0, 100], 2);\n * geometry.addAttribute('uvs', [0,0,1,0,1,1,0,1],2)\n * geometry.addIndex([0,1,2,1,3,2])\n * ```\n *\n * @memberof PIXI\n */\nvar Geometry = /** @class */ (function () {\n /**\n * @param buffers - An array of buffers. optional.\n * @param attributes - Of the geometry, optional structure of the attributes layout\n */\n function Geometry(buffers, attributes) {\n if (buffers === void 0) { buffers = []; }\n if (attributes === void 0) { attributes = {}; }\n this.buffers = buffers;\n this.indexBuffer = null;\n this.attributes = attributes;\n this.glVertexArrayObjects = {};\n this.id = UID$1++;\n this.instanced = false;\n this.instanceCount = 1;\n this.disposeRunner = new Runner('disposeGeometry');\n this.refCount = 0;\n }\n /**\n *\n * Adds an attribute to the geometry\n * Note: `stride` and `start` should be `undefined` if you dont know them, not 0!\n *\n * @param id - the name of the attribute (matching up to a shader)\n * @param {PIXI.Buffer|number[]} buffer - the buffer that holds the data of the attribute . You can also provide an Array and a buffer will be created from it.\n * @param size - the size of the attribute. If you have 2 floats per vertex (eg position x and y) this would be 2\n * @param normalized - should the data be normalized.\n * @param [type=PIXI.TYPES.FLOAT] - what type of number is the attribute. Check {PIXI.TYPES} to see the ones available\n * @param [stride=0] - How far apart, in bytes, the start of each value is. (used for interleaving data)\n * @param [start=0] - How far into the array to start reading values (used for interleaving data)\n * @param instance - Instancing flag\n * @return - Returns self, useful for chaining.\n */\n Geometry.prototype.addAttribute = function (id, buffer, size, normalized, type, stride, start, instance) {\n if (size === void 0) { size = 0; }\n if (normalized === void 0) { normalized = false; }\n if (instance === void 0) { instance = false; }\n if (!buffer) {\n throw new Error('You must pass a buffer when creating an attribute');\n }\n // check if this is a buffer!\n if (!(buffer instanceof Buffer)) {\n // its an array!\n if (buffer instanceof Array) {\n buffer = new Float32Array(buffer);\n }\n buffer = new Buffer(buffer);\n }\n var ids = id.split('|');\n if (ids.length > 1) {\n for (var i = 0; i < ids.length; i++) {\n this.addAttribute(ids[i], buffer, size, normalized, type);\n }\n return this;\n }\n var bufferIndex = this.buffers.indexOf(buffer);\n if (bufferIndex === -1) {\n this.buffers.push(buffer);\n bufferIndex = this.buffers.length - 1;\n }\n this.attributes[id] = new Attribute(bufferIndex, size, normalized, type, stride, start, instance);\n // assuming that if there is instanced data then this will be drawn with instancing!\n this.instanced = this.instanced || instance;\n return this;\n };\n /**\n * Returns the requested attribute.\n *\n * @param id - The name of the attribute required\n * @return - The attribute requested.\n */\n Geometry.prototype.getAttribute = function (id) {\n return this.attributes[id];\n };\n /**\n * Returns the requested buffer.\n *\n * @param id - The name of the buffer required.\n * @return - The buffer requested.\n */\n Geometry.prototype.getBuffer = function (id) {\n return this.buffers[this.getAttribute(id).buffer];\n };\n /**\n *\n * Adds an index buffer to the geometry\n * The index buffer contains integers, three for each triangle in the geometry, which reference the various attribute buffers (position, colour, UV coordinates, other UV coordinates, normal, …). There is only ONE index buffer.\n *\n * @param {PIXI.Buffer|number[]} [buffer] - The buffer that holds the data of the index buffer. You can also provide an Array and a buffer will be created from it.\n * @return - Returns self, useful for chaining.\n */\n Geometry.prototype.addIndex = function (buffer) {\n if (!(buffer instanceof Buffer)) {\n // its an array!\n if (buffer instanceof Array) {\n buffer = new Uint16Array(buffer);\n }\n buffer = new Buffer(buffer);\n }\n buffer.type = BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n this.indexBuffer = buffer;\n if (this.buffers.indexOf(buffer) === -1) {\n this.buffers.push(buffer);\n }\n return this;\n };\n /**\n * Returns the index buffer\n *\n * @return - The index buffer.\n */\n Geometry.prototype.getIndex = function () {\n return this.indexBuffer;\n };\n /**\n * This function modifies the structure so that all current attributes become interleaved into a single buffer\n * This can be useful if your model remains static as it offers a little performance boost\n *\n * @return - Returns self, useful for chaining.\n */\n Geometry.prototype.interleave = function () {\n // a simple check to see if buffers are already interleaved..\n if (this.buffers.length === 1 || (this.buffers.length === 2 && this.indexBuffer))\n { return this; }\n // assume already that no buffers are interleaved\n var arrays = [];\n var sizes = [];\n var interleavedBuffer = new Buffer();\n var i;\n for (i in this.attributes) {\n var attribute = this.attributes[i];\n var buffer = this.buffers[attribute.buffer];\n arrays.push(buffer.data);\n sizes.push((attribute.size * byteSizeMap[attribute.type]) / 4);\n attribute.buffer = 0;\n }\n interleavedBuffer.data = interleaveTypedArrays(arrays, sizes);\n for (i = 0; i < this.buffers.length; i++) {\n if (this.buffers[i] !== this.indexBuffer) {\n this.buffers[i].destroy();\n }\n }\n this.buffers = [interleavedBuffer];\n if (this.indexBuffer) {\n this.buffers.push(this.indexBuffer);\n }\n return this;\n };\n /** Get the size of the geometries, in vertices. */\n Geometry.prototype.getSize = function () {\n for (var i in this.attributes) {\n var attribute = this.attributes[i];\n var buffer = this.buffers[attribute.buffer];\n return buffer.data.length / ((attribute.stride / 4) || attribute.size);\n }\n return 0;\n };\n /** Disposes WebGL resources that are connected to this geometry. */\n Geometry.prototype.dispose = function () {\n this.disposeRunner.emit(this, false);\n };\n /** Destroys the geometry. */\n Geometry.prototype.destroy = function () {\n this.dispose();\n this.buffers = null;\n this.indexBuffer = null;\n this.attributes = null;\n };\n /**\n * Returns a clone of the geometry.\n *\n * @returns - A new clone of this geometry.\n */\n Geometry.prototype.clone = function () {\n var geometry = new Geometry();\n for (var i = 0; i < this.buffers.length; i++) {\n geometry.buffers[i] = new Buffer(this.buffers[i].data.slice(0));\n }\n for (var i in this.attributes) {\n var attrib = this.attributes[i];\n geometry.attributes[i] = new Attribute(attrib.buffer, attrib.size, attrib.normalized, attrib.type, attrib.stride, attrib.start, attrib.instance);\n }\n if (this.indexBuffer) {\n geometry.indexBuffer = geometry.buffers[this.buffers.indexOf(this.indexBuffer)];\n geometry.indexBuffer.type = BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n }\n return geometry;\n };\n /**\n * Merges an array of geometries into a new single one.\n *\n * Geometry attribute styles must match for this operation to work.\n *\n * @param geometries - array of geometries to merge\n * @return - Shiny new geometry!\n */\n Geometry.merge = function (geometries) {\n // todo add a geometry check!\n // also a size check.. cant be too big!]\n var geometryOut = new Geometry();\n var arrays = [];\n var sizes = [];\n var offsets = [];\n var geometry;\n // pass one.. get sizes..\n for (var i = 0; i < geometries.length; i++) {\n geometry = geometries[i];\n for (var j = 0; j < geometry.buffers.length; j++) {\n sizes[j] = sizes[j] || 0;\n sizes[j] += geometry.buffers[j].data.length;\n offsets[j] = 0;\n }\n }\n // build the correct size arrays..\n for (var i = 0; i < geometry.buffers.length; i++) {\n // TODO types!\n arrays[i] = new map$1[getBufferType(geometry.buffers[i].data)](sizes[i]);\n geometryOut.buffers[i] = new Buffer(arrays[i]);\n }\n // pass to set data..\n for (var i = 0; i < geometries.length; i++) {\n geometry = geometries[i];\n for (var j = 0; j < geometry.buffers.length; j++) {\n arrays[j].set(geometry.buffers[j].data, offsets[j]);\n offsets[j] += geometry.buffers[j].data.length;\n }\n }\n geometryOut.attributes = geometry.attributes;\n if (geometry.indexBuffer) {\n geometryOut.indexBuffer = geometryOut.buffers[geometry.buffers.indexOf(geometry.indexBuffer)];\n geometryOut.indexBuffer.type = BUFFER_TYPE.ELEMENT_ARRAY_BUFFER;\n var offset = 0;\n var stride = 0;\n var offset2 = 0;\n var bufferIndexToCount = 0;\n // get a buffer\n for (var i = 0; i < geometry.buffers.length; i++) {\n if (geometry.buffers[i] !== geometry.indexBuffer) {\n bufferIndexToCount = i;\n break;\n }\n }\n // figure out the stride of one buffer..\n for (var i in geometry.attributes) {\n var attribute = geometry.attributes[i];\n if ((attribute.buffer | 0) === bufferIndexToCount) {\n stride += ((attribute.size * byteSizeMap[attribute.type]) / 4);\n }\n }\n // time to off set all indexes..\n for (var i = 0; i < geometries.length; i++) {\n var indexBufferData = geometries[i].indexBuffer.data;\n for (var j = 0; j < indexBufferData.length; j++) {\n geometryOut.indexBuffer.data[j + offset2] += offset;\n }\n offset += geometries[i].buffers[bufferIndexToCount].data.length / (stride);\n offset2 += indexBufferData.length;\n }\n }\n return geometryOut;\n };\n return Geometry;\n}());\n\n/**\n * Helper class to create a quad\n *\n * @memberof PIXI\n */\nvar Quad = /** @class */ (function (_super) {\n __extends(Quad, _super);\n function Quad() {\n var _this = _super.call(this) || this;\n _this.addAttribute('aVertexPosition', new Float32Array([\n 0, 0,\n 1, 0,\n 1, 1,\n 0, 1 ]))\n .addIndex([0, 1, 3, 2]);\n return _this;\n }\n return Quad;\n}(Geometry));\n\n/**\n * Helper class to create a quad with uvs like in v4\n *\n * @memberof PIXI\n */\nvar QuadUv = /** @class */ (function (_super) {\n __extends(QuadUv, _super);\n function QuadUv() {\n var _this = _super.call(this) || this;\n _this.vertices = new Float32Array([\n -1, -1,\n 1, -1,\n 1, 1,\n -1, 1 ]);\n _this.uvs = new Float32Array([\n 0, 0,\n 1, 0,\n 1, 1,\n 0, 1 ]);\n _this.vertexBuffer = new Buffer(_this.vertices);\n _this.uvBuffer = new Buffer(_this.uvs);\n _this.addAttribute('aVertexPosition', _this.vertexBuffer)\n .addAttribute('aTextureCoord', _this.uvBuffer)\n .addIndex([0, 1, 2, 0, 2, 3]);\n return _this;\n }\n /**\n * Maps two Rectangle to the quad.\n *\n * @param targetTextureFrame - The first rectangle\n * @param destinationFrame - The second rectangle\n * @return - Returns itself.\n */\n QuadUv.prototype.map = function (targetTextureFrame, destinationFrame) {\n var x = 0; // destinationFrame.x / targetTextureFrame.width;\n var y = 0; // destinationFrame.y / targetTextureFrame.height;\n this.uvs[0] = x;\n this.uvs[1] = y;\n this.uvs[2] = x + (destinationFrame.width / targetTextureFrame.width);\n this.uvs[3] = y;\n this.uvs[4] = x + (destinationFrame.width / targetTextureFrame.width);\n this.uvs[5] = y + (destinationFrame.height / targetTextureFrame.height);\n this.uvs[6] = x;\n this.uvs[7] = y + (destinationFrame.height / targetTextureFrame.height);\n x = destinationFrame.x;\n y = destinationFrame.y;\n this.vertices[0] = x;\n this.vertices[1] = y;\n this.vertices[2] = x + destinationFrame.width;\n this.vertices[3] = y;\n this.vertices[4] = x + destinationFrame.width;\n this.vertices[5] = y + destinationFrame.height;\n this.vertices[6] = x;\n this.vertices[7] = y + destinationFrame.height;\n this.invalidate();\n return this;\n };\n /**\n * Legacy upload method, just marks buffers dirty.\n *\n * @returns - Returns itself.\n */\n QuadUv.prototype.invalidate = function () {\n this.vertexBuffer._updateID++;\n this.uvBuffer._updateID++;\n return this;\n };\n return QuadUv;\n}(Geometry));\n\nvar UID$2 = 0;\n/**\n * Uniform group holds uniform map and some ID's for work\n *\n * `UniformGroup` has two modes:\n *\n * 1: Normal mode\n * Normal mode will upload the uniforms with individual function calls as required\n *\n * 2: Uniform buffer mode\n * This mode will treat the uniforms as a uniform buffer. You can pass in either a buffer that you manually handle, or\n * or a generic object that PixiJS will automatically map to a buffer for you.\n * For maximum benefits, make Ubo UniformGroups static, and only update them each frame.\n *\n * Rules of UBOs:\n * - UBOs only work with WebGL2, so make sure you have a fallback!\n * - Only floats are supported (including vec[2,3,4], mat[2,3,4])\n * - Samplers cannot be used in ubo's (a GPU limitation)\n * - You must ensure that the object you pass in exactly matches in the shader ubo structure.\n * Otherwise, weirdness will ensue!\n * - The name of the ubo object added to the group must match exactly the name of the ubo in the shader.\n *\n * ```\n * // ubo in shader:\n * uniform myCoolData { // declaring a ubo..\n * mat4 uCoolMatrix;\n * float uFloatyMcFloatFace\n *\n *\n * // a new uniform buffer object..\n * const myCoolData = new UniformBufferGroup({\n * uCoolMatrix: new Matrix(),\n * uFloatyMcFloatFace: 23,\n * }}\n *\n * // build a shader...\n * const shader = Shader.from(srcVert, srcFrag, {\n * myCoolData // name matches the ubo name in the shader. will be processed accordingly.\n * })\n *\n * ```\n *\n * @memberof PIXI\n */\nvar UniformGroup = /** @class */ (function () {\n /**\n * @param {object | Buffer} [uniforms] - Custom uniforms to use to augment the built-in ones. Or a pixi buffer.\n * @param isStatic - Uniforms wont be changed after creation.\n * @param isUbo - If true, will treat this uniform group as a uniform buffer object.\n */\n function UniformGroup(uniforms, isStatic, isUbo) {\n this.group = true;\n // lets generate this when the shader ?\n this.syncUniforms = {};\n this.dirtyId = 0;\n this.id = UID$2++;\n this.static = !!isStatic;\n this.ubo = !!isUbo;\n if (uniforms instanceof Buffer) {\n this.buffer = uniforms;\n this.buffer.type = BUFFER_TYPE.UNIFORM_BUFFER;\n this.autoManage = false;\n this.ubo = true;\n }\n else {\n this.uniforms = uniforms;\n if (this.ubo) {\n this.buffer = new Buffer(new Float32Array(1));\n this.buffer.type = BUFFER_TYPE.UNIFORM_BUFFER;\n this.autoManage = true;\n }\n }\n }\n UniformGroup.prototype.update = function () {\n this.dirtyId++;\n if (!this.autoManage && this.buffer) {\n this.buffer.update();\n }\n };\n UniformGroup.prototype.add = function (name, uniforms, _static) {\n if (!this.ubo) {\n this.uniforms[name] = new UniformGroup(uniforms, _static);\n }\n else {\n // eslint-disable-next-line max-len\n throw new Error('[UniformGroup] uniform groups in ubo mode cannot be modified, or have uniform groups nested in them');\n }\n };\n UniformGroup.from = function (uniforms, _static, _ubo) {\n return new UniformGroup(uniforms, _static, _ubo);\n };\n /**\n * A short hand function for creating a static UBO UniformGroup.\n *\n * @param uniforms - the ubo item\n * @param _static - should this be updated each time it is used? defaults to true here!\n */\n UniformGroup.uboFrom = function (uniforms, _static) {\n return new UniformGroup(uniforms, _static !== null && _static !== void 0 ? _static : true, true);\n };\n return UniformGroup;\n}());\n\n/**\n * System plugin to the renderer to manage filter states.\n *\n * @ignore\n */\nvar FilterState = /** @class */ (function () {\n function FilterState() {\n this.renderTexture = null;\n this.target = null;\n this.legacy = false;\n this.resolution = 1;\n this.multisample = MSAA_QUALITY.NONE;\n // next three fields are created only for root\n // re-assigned for everything else\n this.sourceFrame = new Rectangle();\n this.destinationFrame = new Rectangle();\n this.bindingSourceFrame = new Rectangle();\n this.bindingDestinationFrame = new Rectangle();\n this.filters = [];\n this.transform = null;\n }\n /** Clears the state */\n FilterState.prototype.clear = function () {\n this.target = null;\n this.filters = null;\n this.renderTexture = null;\n };\n return FilterState;\n}());\n\nvar tempPoints = [new Point(), new Point(), new Point(), new Point()];\nvar tempMatrix = new Matrix();\n/**\n * System plugin to the renderer to manage filters.\n *\n * ## Pipeline\n *\n * The FilterSystem executes the filtering pipeline by rendering the display-object into a texture, applying its\n * [filters]{@link PIXI.Filter} in series, and the last filter outputs into the final render-target.\n *\n * The filter-frame is the rectangle in world space being filtered, and those contents are mapped into\n * `(0, 0, filterFrame.width, filterFrame.height)` into the filter render-texture. The filter-frame is also called\n * the source-frame, as it is used to bind the filter render-textures. The last filter outputs to the `filterFrame`\n * in the final render-target.\n *\n * ## Usage\n *\n * {@link PIXI.Container#renderAdvanced} is an example of how to use the filter system. It is a 3 step process:\n *\n * * **push**: Use {@link PIXI.FilterSystem#push} to push the set of filters to be applied on a filter-target.\n * * **render**: Render the contents to be filtered using the renderer. The filter-system will only capture the contents\n * inside the bounds of the filter-target. NOTE: Using {@link PIXI.Renderer#render} is\n * illegal during an existing render cycle, and it may reset the filter system.\n * * **pop**: Use {@link PIXI.FilterSystem#pop} to pop & execute the filters you initially pushed. It will apply them\n * serially and output to the bounds of the filter-target.\n *\n * @memberof PIXI\n */\nvar FilterSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function FilterSystem(renderer) {\n this.renderer = renderer;\n this.defaultFilterStack = [{}];\n this.texturePool = new RenderTexturePool();\n this.texturePool.setScreenSize(renderer.view);\n this.statePool = [];\n this.quad = new Quad();\n this.quadUv = new QuadUv();\n this.tempRect = new Rectangle();\n this.activeState = {};\n this.globalUniforms = new UniformGroup({\n outputFrame: new Rectangle(),\n inputSize: new Float32Array(4),\n inputPixel: new Float32Array(4),\n inputClamp: new Float32Array(4),\n resolution: 1,\n // legacy variables\n filterArea: new Float32Array(4),\n filterClamp: new Float32Array(4),\n }, true);\n this.forceClear = false;\n this.useMaxPadding = false;\n }\n /**\n * Pushes a set of filters to be applied later to the system. This will redirect further rendering into an\n * input render-texture for the rest of the filtering pipeline.\n *\n * @param {PIXI.DisplayObject} target - The target of the filter to render.\n * @param filters - The filters to apply.\n */\n FilterSystem.prototype.push = function (target, filters) {\n var _a, _b;\n var renderer = this.renderer;\n var filterStack = this.defaultFilterStack;\n var state = this.statePool.pop() || new FilterState();\n var renderTextureSystem = this.renderer.renderTexture;\n var resolution = filters[0].resolution;\n var multisample = filters[0].multisample;\n var padding = filters[0].padding;\n var autoFit = filters[0].autoFit;\n // We don't know whether it's a legacy filter until it was bound for the first time,\n // therefore we have to assume that it is if legacy is undefined.\n var legacy = (_a = filters[0].legacy) !== null && _a !== void 0 ? _a : true;\n for (var i = 1; i < filters.length; i++) {\n var filter = filters[i];\n // let's use the lowest resolution\n resolution = Math.min(resolution, filter.resolution);\n // let's use the lowest number of samples\n multisample = Math.min(multisample, filter.multisample);\n // figure out the padding required for filters\n padding = this.useMaxPadding\n // old behavior: use largest amount of padding!\n ? Math.max(padding, filter.padding)\n // new behavior: sum the padding\n : padding + filter.padding;\n // only auto fit if all filters are autofit\n autoFit = autoFit && filter.autoFit;\n legacy = legacy || ((_b = filter.legacy) !== null && _b !== void 0 ? _b : true);\n }\n if (filterStack.length === 1) {\n this.defaultFilterStack[0].renderTexture = renderTextureSystem.current;\n }\n filterStack.push(state);\n state.resolution = resolution;\n state.multisample = multisample;\n state.legacy = legacy;\n state.target = target;\n state.sourceFrame.copyFrom(target.filterArea || target.getBounds(true));\n state.sourceFrame.pad(padding);\n if (autoFit) {\n var sourceFrameProjected = this.tempRect.copyFrom(renderTextureSystem.sourceFrame);\n // Project source frame into world space (if projection is applied)\n if (renderer.projection.transform) {\n this.transformAABB(tempMatrix.copyFrom(renderer.projection.transform).invert(), sourceFrameProjected);\n }\n state.sourceFrame.fit(sourceFrameProjected);\n }\n // Round sourceFrame in screen space based on render-texture.\n this.roundFrame(state.sourceFrame, renderTextureSystem.current ? renderTextureSystem.current.resolution : renderer.resolution, renderTextureSystem.sourceFrame, renderTextureSystem.destinationFrame, renderer.projection.transform);\n state.renderTexture = this.getOptimalFilterTexture(state.sourceFrame.width, state.sourceFrame.height, resolution, multisample);\n state.filters = filters;\n state.destinationFrame.width = state.renderTexture.width;\n state.destinationFrame.height = state.renderTexture.height;\n var destinationFrame = this.tempRect;\n destinationFrame.x = 0;\n destinationFrame.y = 0;\n destinationFrame.width = state.sourceFrame.width;\n destinationFrame.height = state.sourceFrame.height;\n state.renderTexture.filterFrame = state.sourceFrame;\n state.bindingSourceFrame.copyFrom(renderTextureSystem.sourceFrame);\n state.bindingDestinationFrame.copyFrom(renderTextureSystem.destinationFrame);\n state.transform = renderer.projection.transform;\n renderer.projection.transform = null;\n renderTextureSystem.bind(state.renderTexture, state.sourceFrame, destinationFrame);\n renderer.framebuffer.clear(0, 0, 0, 0);\n };\n /** Pops off the filter and applies it. */\n FilterSystem.prototype.pop = function () {\n var filterStack = this.defaultFilterStack;\n var state = filterStack.pop();\n var filters = state.filters;\n this.activeState = state;\n var globalUniforms = this.globalUniforms.uniforms;\n globalUniforms.outputFrame = state.sourceFrame;\n globalUniforms.resolution = state.resolution;\n var inputSize = globalUniforms.inputSize;\n var inputPixel = globalUniforms.inputPixel;\n var inputClamp = globalUniforms.inputClamp;\n inputSize[0] = state.destinationFrame.width;\n inputSize[1] = state.destinationFrame.height;\n inputSize[2] = 1.0 / inputSize[0];\n inputSize[3] = 1.0 / inputSize[1];\n inputPixel[0] = Math.round(inputSize[0] * state.resolution);\n inputPixel[1] = Math.round(inputSize[1] * state.resolution);\n inputPixel[2] = 1.0 / inputPixel[0];\n inputPixel[3] = 1.0 / inputPixel[1];\n inputClamp[0] = 0.5 * inputPixel[2];\n inputClamp[1] = 0.5 * inputPixel[3];\n inputClamp[2] = (state.sourceFrame.width * inputSize[2]) - (0.5 * inputPixel[2]);\n inputClamp[3] = (state.sourceFrame.height * inputSize[3]) - (0.5 * inputPixel[3]);\n // only update the rect if its legacy..\n if (state.legacy) {\n var filterArea = globalUniforms.filterArea;\n filterArea[0] = state.destinationFrame.width;\n filterArea[1] = state.destinationFrame.height;\n filterArea[2] = state.sourceFrame.x;\n filterArea[3] = state.sourceFrame.y;\n globalUniforms.filterClamp = globalUniforms.inputClamp;\n }\n this.globalUniforms.update();\n var lastState = filterStack[filterStack.length - 1];\n this.renderer.framebuffer.blit();\n if (filters.length === 1) {\n filters[0].apply(this, state.renderTexture, lastState.renderTexture, CLEAR_MODES.BLEND, state);\n this.returnFilterTexture(state.renderTexture);\n }\n else {\n var flip = state.renderTexture;\n var flop = this.getOptimalFilterTexture(flip.width, flip.height, state.resolution);\n flop.filterFrame = flip.filterFrame;\n var i = 0;\n for (i = 0; i < filters.length - 1; ++i) {\n if (i === 1 && state.multisample > 1) {\n flop = this.getOptimalFilterTexture(flip.width, flip.height, state.resolution);\n flop.filterFrame = flip.filterFrame;\n }\n filters[i].apply(this, flip, flop, CLEAR_MODES.CLEAR, state);\n var t = flip;\n flip = flop;\n flop = t;\n }\n filters[i].apply(this, flip, lastState.renderTexture, CLEAR_MODES.BLEND, state);\n if (i > 1 && state.multisample > 1) {\n this.returnFilterTexture(state.renderTexture);\n }\n this.returnFilterTexture(flip);\n this.returnFilterTexture(flop);\n }\n // lastState.renderTexture is blitted when lastState is popped\n state.clear();\n this.statePool.push(state);\n };\n /**\n * Binds a renderTexture with corresponding `filterFrame`, clears it if mode corresponds.\n *\n * @param filterTexture - renderTexture to bind, should belong to filter pool or filter stack\n * @param clearMode - clearMode, by default its CLEAR/YES. See {@link PIXI.CLEAR_MODES}\n */\n FilterSystem.prototype.bindAndClear = function (filterTexture, clearMode) {\n if (clearMode === void 0) { clearMode = CLEAR_MODES.CLEAR; }\n var _a = this.renderer, renderTextureSystem = _a.renderTexture, stateSystem = _a.state;\n if (filterTexture === this.defaultFilterStack[this.defaultFilterStack.length - 1].renderTexture) {\n // Restore projection transform if rendering into the output render-target.\n this.renderer.projection.transform = this.activeState.transform;\n }\n else {\n // Prevent projection within filtering pipeline.\n this.renderer.projection.transform = null;\n }\n if (filterTexture && filterTexture.filterFrame) {\n var destinationFrame = this.tempRect;\n destinationFrame.x = 0;\n destinationFrame.y = 0;\n destinationFrame.width = filterTexture.filterFrame.width;\n destinationFrame.height = filterTexture.filterFrame.height;\n renderTextureSystem.bind(filterTexture, filterTexture.filterFrame, destinationFrame);\n }\n else if (filterTexture !== this.defaultFilterStack[this.defaultFilterStack.length - 1].renderTexture) {\n renderTextureSystem.bind(filterTexture);\n }\n else {\n // Restore binding for output render-target.\n this.renderer.renderTexture.bind(filterTexture, this.activeState.bindingSourceFrame, this.activeState.bindingDestinationFrame);\n }\n // Clear the texture in BLIT mode if blending is disabled or the forceClear flag is set. The blending\n // is stored in the 0th bit of the state.\n var autoClear = (stateSystem.stateId & 1) || this.forceClear;\n if (clearMode === CLEAR_MODES.CLEAR\n || (clearMode === CLEAR_MODES.BLIT && autoClear)) {\n // Use framebuffer.clear because we want to clear the whole filter texture, not just the filtering\n // area over which the shaders are run. This is because filters may sampling outside of it (e.g. blur)\n // instead of clamping their arithmetic.\n this.renderer.framebuffer.clear(0, 0, 0, 0);\n }\n };\n /**\n * Draws a filter using the default rendering process.\n *\n * This should be called only by {@link Filter#apply}.\n *\n * @param filter - The filter to draw.\n * @param input - The input render target.\n * @param output - The target to output to.\n * @param clearMode - Should the output be cleared before rendering to it\n */\n FilterSystem.prototype.applyFilter = function (filter, input, output, clearMode) {\n var renderer = this.renderer;\n // Set state before binding, so bindAndClear gets the blend mode.\n renderer.state.set(filter.state);\n this.bindAndClear(output, clearMode);\n // set the uniforms..\n filter.uniforms.uSampler = input;\n filter.uniforms.filterGlobals = this.globalUniforms;\n // TODO make it so that the order of this does not matter..\n // because it does at the moment cos of global uniforms.\n // they need to get resynced\n renderer.shader.bind(filter);\n // check to see if the filter is a legacy one..\n filter.legacy = !!filter.program.attributeData.aTextureCoord;\n if (filter.legacy) {\n this.quadUv.map(input._frame, input.filterFrame);\n renderer.geometry.bind(this.quadUv);\n renderer.geometry.draw(DRAW_MODES.TRIANGLES);\n }\n else {\n renderer.geometry.bind(this.quad);\n renderer.geometry.draw(DRAW_MODES.TRIANGLE_STRIP);\n }\n };\n /**\n * Multiply _input normalized coordinates_ to this matrix to get _sprite texture normalized coordinates_.\n *\n * Use `outputMatrix * vTextureCoord` in the shader.\n *\n * @param outputMatrix - The matrix to output to.\n * @param {PIXI.Sprite} sprite - The sprite to map to.\n * @return The mapped matrix.\n */\n FilterSystem.prototype.calculateSpriteMatrix = function (outputMatrix, sprite) {\n var _a = this.activeState, sourceFrame = _a.sourceFrame, destinationFrame = _a.destinationFrame;\n var orig = sprite._texture.orig;\n var mappedMatrix = outputMatrix.set(destinationFrame.width, 0, 0, destinationFrame.height, sourceFrame.x, sourceFrame.y);\n var worldTransform = sprite.worldTransform.copyTo(Matrix.TEMP_MATRIX);\n worldTransform.invert();\n mappedMatrix.prepend(worldTransform);\n mappedMatrix.scale(1.0 / orig.width, 1.0 / orig.height);\n mappedMatrix.translate(sprite.anchor.x, sprite.anchor.y);\n return mappedMatrix;\n };\n /** Destroys this Filter System. */\n FilterSystem.prototype.destroy = function () {\n this.renderer = null;\n // Those textures has to be destroyed by RenderTextureSystem or FramebufferSystem\n this.texturePool.clear(false);\n };\n /**\n * Gets a Power-of-Two render texture or fullScreen texture\n *\n * @param minWidth - The minimum width of the render texture in real pixels.\n * @param minHeight - The minimum height of the render texture in real pixels.\n * @param resolution - The resolution of the render texture.\n * @param multisample - Number of samples of the render texture.\n * @return - The new render texture.\n */\n FilterSystem.prototype.getOptimalFilterTexture = function (minWidth, minHeight, resolution, multisample) {\n if (resolution === void 0) { resolution = 1; }\n if (multisample === void 0) { multisample = MSAA_QUALITY.NONE; }\n return this.texturePool.getOptimalTexture(minWidth, minHeight, resolution, multisample);\n };\n /**\n * Gets extra render texture to use inside current filter\n * To be compliant with older filters, you can use params in any order\n *\n * @param input - renderTexture from which size and resolution will be copied\n * @param resolution - override resolution of the renderTexture\n * @param multisample - number of samples of the renderTexture\n */\n FilterSystem.prototype.getFilterTexture = function (input, resolution, multisample) {\n if (typeof input === 'number') {\n var swap = input;\n input = resolution;\n resolution = swap;\n }\n input = input || this.activeState.renderTexture;\n var filterTexture = this.texturePool.getOptimalTexture(input.width, input.height, resolution || input.resolution, multisample || MSAA_QUALITY.NONE);\n filterTexture.filterFrame = input.filterFrame;\n return filterTexture;\n };\n /**\n * Frees a render texture back into the pool.\n *\n * @param renderTexture - The renderTarget to free\n */\n FilterSystem.prototype.returnFilterTexture = function (renderTexture) {\n this.texturePool.returnTexture(renderTexture);\n };\n /** Empties the texture pool. */\n FilterSystem.prototype.emptyPool = function () {\n this.texturePool.clear(true);\n };\n /** Calls `texturePool.resize()`, affects fullScreen renderTextures. */\n FilterSystem.prototype.resize = function () {\n this.texturePool.setScreenSize(this.renderer.view);\n };\n /**\n * @param matrix - first param\n * @param rect - second param\n */\n FilterSystem.prototype.transformAABB = function (matrix, rect) {\n var lt = tempPoints[0];\n var lb = tempPoints[1];\n var rt = tempPoints[2];\n var rb = tempPoints[3];\n lt.set(rect.left, rect.top);\n lb.set(rect.left, rect.bottom);\n rt.set(rect.right, rect.top);\n rb.set(rect.right, rect.bottom);\n matrix.apply(lt, lt);\n matrix.apply(lb, lb);\n matrix.apply(rt, rt);\n matrix.apply(rb, rb);\n var x0 = Math.min(lt.x, lb.x, rt.x, rb.x);\n var y0 = Math.min(lt.y, lb.y, rt.y, rb.y);\n var x1 = Math.max(lt.x, lb.x, rt.x, rb.x);\n var y1 = Math.max(lt.y, lb.y, rt.y, rb.y);\n rect.x = x0;\n rect.y = y0;\n rect.width = x1 - x0;\n rect.height = y1 - y0;\n };\n FilterSystem.prototype.roundFrame = function (frame, resolution, bindingSourceFrame, bindingDestinationFrame, transform) {\n if (frame.width <= 0 || frame.height <= 0 || bindingSourceFrame.width <= 0 || bindingSourceFrame.height <= 0) {\n return;\n }\n if (transform) {\n var a = transform.a, b = transform.b, c = transform.c, d = transform.d;\n // Skip if skew/rotation present in matrix, except for multiple of 90° rotation. If rotation\n // is a multiple of 90°, then either pair of (b,c) or (a,d) will be (0,0).\n if ((Math.abs(b) > 1e-4 || Math.abs(c) > 1e-4)\n && (Math.abs(a) > 1e-4 || Math.abs(d) > 1e-4)) {\n return;\n }\n }\n transform = transform ? tempMatrix.copyFrom(transform) : tempMatrix.identity();\n // Get forward transform from world space to screen space\n transform\n .translate(-bindingSourceFrame.x, -bindingSourceFrame.y)\n .scale(bindingDestinationFrame.width / bindingSourceFrame.width, bindingDestinationFrame.height / bindingSourceFrame.height)\n .translate(bindingDestinationFrame.x, bindingDestinationFrame.y);\n // Convert frame to screen space\n this.transformAABB(transform, frame);\n // Round frame in screen space\n frame.ceil(resolution);\n // Project back into world space.\n this.transformAABB(transform.invert(), frame);\n };\n return FilterSystem;\n}());\n\n/**\n * Base for a common object renderer that can be used as a\n * system renderer plugin.\n *\n * @memberof PIXI\n */\nvar ObjectRenderer = /** @class */ (function () {\n /**\n * @param renderer - The renderer this manager works for.\n */\n function ObjectRenderer(renderer) {\n this.renderer = renderer;\n }\n /**\n * Stub method that should be used to empty the current\n * batch by rendering objects now.\n */\n ObjectRenderer.prototype.flush = function () {\n // flush!\n };\n /**\n * Generic destruction method that frees all resources. This\n * should be called by subclasses.\n */\n ObjectRenderer.prototype.destroy = function () {\n this.renderer = null;\n };\n /**\n * Stub method that initializes any state required before\n * rendering starts. It is different from the `prerender`\n * signal, which occurs every frame, in that it is called\n * whenever an object requests _this_ renderer specifically.\n */\n ObjectRenderer.prototype.start = function () {\n // set the shader..\n };\n /**\n * Stops the renderer. It should free up any state and\n * become dormant.\n */\n ObjectRenderer.prototype.stop = function () {\n this.flush();\n };\n /**\n * Keeps the object to render. It doesn't have to be\n * rendered immediately.\n *\n * @param {PIXI.DisplayObject} object - The object to render.\n */\n ObjectRenderer.prototype.render = function (_object) {\n // render the object\n };\n return ObjectRenderer;\n}());\n\n/**\n * System plugin to the renderer to manage batching.\n *\n * @memberof PIXI\n */\nvar BatchSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function BatchSystem(renderer) {\n this.renderer = renderer;\n this.emptyRenderer = new ObjectRenderer(renderer);\n this.currentRenderer = this.emptyRenderer;\n }\n /**\n * Changes the current renderer to the one given in parameter\n *\n * @param objectRenderer - The object renderer to use.\n */\n BatchSystem.prototype.setObjectRenderer = function (objectRenderer) {\n if (this.currentRenderer === objectRenderer) {\n return;\n }\n this.currentRenderer.stop();\n this.currentRenderer = objectRenderer;\n this.currentRenderer.start();\n };\n /**\n * This should be called if you wish to do some custom rendering\n * It will basically render anything that may be batched up such as sprites\n */\n BatchSystem.prototype.flush = function () {\n this.setObjectRenderer(this.emptyRenderer);\n };\n /**\n * Reset the system to an empty renderer\n */\n BatchSystem.prototype.reset = function () {\n this.setObjectRenderer(this.emptyRenderer);\n };\n /**\n * Handy function for batch renderers: copies bound textures in first maxTextures locations to array\n * sets actual _batchLocation for them\n *\n * @param arr - arr copy destination\n * @param maxTextures - number of copied elements\n */\n BatchSystem.prototype.copyBoundTextures = function (arr, maxTextures) {\n var boundTextures = this.renderer.texture.boundTextures;\n for (var i = maxTextures - 1; i >= 0; --i) {\n arr[i] = boundTextures[i] || null;\n if (arr[i]) {\n arr[i]._batchLocation = i;\n }\n }\n };\n /**\n * Assigns batch locations to textures in array based on boundTextures state.\n * All textures in texArray should have `_batchEnabled = _batchId`,\n * and their count should be less than `maxTextures`.\n *\n * @param texArray - textures to bound\n * @param boundTextures - current state of bound textures\n * @param batchId - marker for _batchEnabled param of textures in texArray\n * @param maxTextures - number of texture locations to manipulate\n */\n BatchSystem.prototype.boundArray = function (texArray, boundTextures, batchId, maxTextures) {\n var elements = texArray.elements, ids = texArray.ids, count = texArray.count;\n var j = 0;\n for (var i = 0; i < count; i++) {\n var tex = elements[i];\n var loc = tex._batchLocation;\n if (loc >= 0 && loc < maxTextures\n && boundTextures[loc] === tex) {\n ids[i] = loc;\n continue;\n }\n while (j < maxTextures) {\n var bound = boundTextures[j];\n if (bound && bound._batchEnabled === batchId\n && bound._batchLocation === j) {\n j++;\n continue;\n }\n ids[i] = j;\n tex._batchLocation = j;\n boundTextures[j] = tex;\n break;\n }\n }\n };\n /**\n * @ignore\n */\n BatchSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return BatchSystem;\n}());\n\nvar CONTEXT_UID_COUNTER = 0;\n/**\n * System plugin to the renderer to manage the context.\n *\n * @memberof PIXI\n */\nvar ContextSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function ContextSystem(renderer) {\n this.renderer = renderer;\n this.webGLVersion = 1;\n this.extensions = {};\n this.supports = {\n uint32Indices: false,\n };\n // Bind functions\n this.handleContextLost = this.handleContextLost.bind(this);\n this.handleContextRestored = this.handleContextRestored.bind(this);\n renderer.view.addEventListener('webglcontextlost', this.handleContextLost, false);\n renderer.view.addEventListener('webglcontextrestored', this.handleContextRestored, false);\n }\n Object.defineProperty(ContextSystem.prototype, \"isLost\", {\n /**\n * `true` if the context is lost\n *\n * @readonly\n */\n get: function () {\n return (!this.gl || this.gl.isContextLost());\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Handles the context change event.\n *\n * @param {WebGLRenderingContext} gl - New WebGL context.\n */\n ContextSystem.prototype.contextChange = function (gl) {\n this.gl = gl;\n this.renderer.gl = gl;\n this.renderer.CONTEXT_UID = CONTEXT_UID_COUNTER++;\n // restore a context if it was previously lost\n if (gl.isContextLost() && gl.getExtension('WEBGL_lose_context')) {\n gl.getExtension('WEBGL_lose_context').restoreContext();\n }\n };\n /**\n * Initializes the context.\n *\n * @protected\n * @param {WebGLRenderingContext} gl - WebGL context\n */\n ContextSystem.prototype.initFromContext = function (gl) {\n this.gl = gl;\n this.validateContext(gl);\n this.renderer.gl = gl;\n this.renderer.CONTEXT_UID = CONTEXT_UID_COUNTER++;\n this.renderer.runners.contextChange.emit(gl);\n };\n /**\n * Initialize from context options\n *\n * @protected\n * @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/getContext\n * @param {object} options - context attributes\n */\n ContextSystem.prototype.initFromOptions = function (options) {\n var gl = this.createContext(this.renderer.view, options);\n this.initFromContext(gl);\n };\n /**\n * Helper class to create a WebGL Context\n *\n * @param canvas - the canvas element that we will get the context from\n * @param options - An options object that gets passed in to the canvas element containing the\n * context attributes\n * @see https://developer.mozilla.org/en/docs/Web/API/HTMLCanvasElement/getContext\n * @return {WebGLRenderingContext} the WebGL context\n */\n ContextSystem.prototype.createContext = function (canvas, options) {\n var gl;\n if (settings.PREFER_ENV >= ENV.WEBGL2) {\n gl = canvas.getContext('webgl2', options);\n }\n if (gl) {\n this.webGLVersion = 2;\n }\n else {\n this.webGLVersion = 1;\n gl = canvas.getContext('webgl', options)\n || canvas.getContext('experimental-webgl', options);\n if (!gl) {\n // fail, not able to get a context\n throw new Error('This browser does not support WebGL. Try using the canvas renderer');\n }\n }\n this.gl = gl;\n this.getExtensions();\n return this.gl;\n };\n /** Auto-populate the {@link PIXI.ContextSystem.extensions extensions}. */\n ContextSystem.prototype.getExtensions = function () {\n // time to set up default extensions that Pixi uses.\n var gl = this.gl;\n var common = {\n anisotropicFiltering: gl.getExtension('EXT_texture_filter_anisotropic'),\n floatTextureLinear: gl.getExtension('OES_texture_float_linear'),\n s3tc: gl.getExtension('WEBGL_compressed_texture_s3tc'),\n s3tc_sRGB: gl.getExtension('WEBGL_compressed_texture_s3tc_srgb'),\n etc: gl.getExtension('WEBGL_compressed_texture_etc'),\n etc1: gl.getExtension('WEBGL_compressed_texture_etc1'),\n pvrtc: gl.getExtension('WEBGL_compressed_texture_pvrtc')\n || gl.getExtension('WEBKIT_WEBGL_compressed_texture_pvrtc'),\n atc: gl.getExtension('WEBGL_compressed_texture_atc'),\n astc: gl.getExtension('WEBGL_compressed_texture_astc')\n };\n if (this.webGLVersion === 1) {\n Object.assign(this.extensions, common, {\n drawBuffers: gl.getExtension('WEBGL_draw_buffers'),\n depthTexture: gl.getExtension('WEBGL_depth_texture'),\n loseContext: gl.getExtension('WEBGL_lose_context'),\n vertexArrayObject: gl.getExtension('OES_vertex_array_object')\n || gl.getExtension('MOZ_OES_vertex_array_object')\n || gl.getExtension('WEBKIT_OES_vertex_array_object'),\n uint32ElementIndex: gl.getExtension('OES_element_index_uint'),\n // Floats and half-floats\n floatTexture: gl.getExtension('OES_texture_float'),\n floatTextureLinear: gl.getExtension('OES_texture_float_linear'),\n textureHalfFloat: gl.getExtension('OES_texture_half_float'),\n textureHalfFloatLinear: gl.getExtension('OES_texture_half_float_linear'),\n });\n }\n else if (this.webGLVersion === 2) {\n Object.assign(this.extensions, common, {\n // Floats and half-floats\n colorBufferFloat: gl.getExtension('EXT_color_buffer_float')\n });\n }\n };\n /**\n * Handles a lost webgl context\n *\n * @param {WebGLContextEvent} event - The context lost event.\n */\n ContextSystem.prototype.handleContextLost = function (event) {\n event.preventDefault();\n };\n /** Handles a restored webgl context. */\n ContextSystem.prototype.handleContextRestored = function () {\n this.renderer.runners.contextChange.emit(this.gl);\n };\n ContextSystem.prototype.destroy = function () {\n var view = this.renderer.view;\n this.renderer = null;\n // remove listeners\n view.removeEventListener('webglcontextlost', this.handleContextLost);\n view.removeEventListener('webglcontextrestored', this.handleContextRestored);\n this.gl.useProgram(null);\n if (this.extensions.loseContext) {\n this.extensions.loseContext.loseContext();\n }\n };\n /** Handle the post-render runner event. */\n ContextSystem.prototype.postrender = function () {\n if (this.renderer.renderingToScreen) {\n this.gl.flush();\n }\n };\n /**\n * Validate context.\n *\n * @param {WebGLRenderingContext} gl - Render context.\n */\n ContextSystem.prototype.validateContext = function (gl) {\n var attributes = gl.getContextAttributes();\n var isWebGl2 = 'WebGL2RenderingContext' in globalThis && gl instanceof globalThis.WebGL2RenderingContext;\n if (isWebGl2) {\n this.webGLVersion = 2;\n }\n // this is going to be fairly simple for now.. but at least we have room to grow!\n if (!attributes.stencil) {\n /* eslint-disable max-len, no-console */\n console.warn('Provided WebGL context does not have a stencil buffer, masks may not render correctly');\n /* eslint-enable max-len, no-console */\n }\n var hasuint32 = isWebGl2 || !!gl.getExtension('OES_element_index_uint');\n this.supports.uint32Indices = hasuint32;\n if (!hasuint32) {\n /* eslint-disable max-len, no-console */\n console.warn('Provided WebGL context does not support 32 index buffer, complex graphics may not render correctly');\n /* eslint-enable max-len, no-console */\n }\n };\n return ContextSystem;\n}());\n\n/**\n * Internal framebuffer for WebGL context.\n *\n * @memberof PIXI\n */\nvar GLFramebuffer = /** @class */ (function () {\n function GLFramebuffer(framebuffer) {\n this.framebuffer = framebuffer;\n this.stencil = null;\n this.dirtyId = -1;\n this.dirtyFormat = -1;\n this.dirtySize = -1;\n this.multisample = MSAA_QUALITY.NONE;\n this.msaaBuffer = null;\n this.blitFramebuffer = null;\n this.mipLevel = 0;\n }\n return GLFramebuffer;\n}());\n\nvar tempRectangle = new Rectangle();\n/**\n * System plugin to the renderer to manage framebuffers.\n *\n * @memberof PIXI\n */\nvar FramebufferSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function FramebufferSystem(renderer) {\n this.renderer = renderer;\n this.managedFramebuffers = [];\n this.unknownFramebuffer = new Framebuffer(10, 10);\n this.msaaSamples = null;\n }\n /** Sets up the renderer context and necessary buffers. */\n FramebufferSystem.prototype.contextChange = function () {\n var gl = this.gl = this.renderer.gl;\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n this.current = this.unknownFramebuffer;\n this.viewport = new Rectangle();\n this.hasMRT = true;\n this.writeDepthTexture = true;\n this.disposeAll(true);\n // webgl2\n if (this.renderer.context.webGLVersion === 1) {\n // webgl 1!\n var nativeDrawBuffersExtension_1 = this.renderer.context.extensions.drawBuffers;\n var nativeDepthTextureExtension = this.renderer.context.extensions.depthTexture;\n if (settings.PREFER_ENV === ENV.WEBGL_LEGACY) {\n nativeDrawBuffersExtension_1 = null;\n nativeDepthTextureExtension = null;\n }\n if (nativeDrawBuffersExtension_1) {\n gl.drawBuffers = function (activeTextures) {\n return nativeDrawBuffersExtension_1.drawBuffersWEBGL(activeTextures);\n };\n }\n else {\n this.hasMRT = false;\n gl.drawBuffers = function () {\n // empty\n };\n }\n if (!nativeDepthTextureExtension) {\n this.writeDepthTexture = false;\n }\n }\n else {\n // WebGL2\n // cache possible MSAA samples\n this.msaaSamples = gl.getInternalformatParameter(gl.RENDERBUFFER, gl.RGBA8, gl.SAMPLES);\n }\n };\n /**\n * Bind a framebuffer.\n *\n * @param framebuffer\n * @param frame - frame, default is framebuffer size\n * @param mipLevel - optional mip level to set on the framebuffer - defaults to 0\n */\n FramebufferSystem.prototype.bind = function (framebuffer, frame, mipLevel) {\n if (mipLevel === void 0) { mipLevel = 0; }\n var gl = this.gl;\n if (framebuffer) {\n // TODO caching layer!\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID] || this.initFramebuffer(framebuffer);\n if (this.current !== framebuffer) {\n this.current = framebuffer;\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo.framebuffer);\n }\n // make sure all textures are unbound..\n if (fbo.mipLevel !== mipLevel) {\n framebuffer.dirtyId++;\n framebuffer.dirtyFormat++;\n fbo.mipLevel = mipLevel;\n }\n // now check for updates...\n if (fbo.dirtyId !== framebuffer.dirtyId) {\n fbo.dirtyId = framebuffer.dirtyId;\n if (fbo.dirtyFormat !== framebuffer.dirtyFormat) {\n fbo.dirtyFormat = framebuffer.dirtyFormat;\n fbo.dirtySize = framebuffer.dirtySize;\n this.updateFramebuffer(framebuffer, mipLevel);\n }\n else if (fbo.dirtySize !== framebuffer.dirtySize) {\n fbo.dirtySize = framebuffer.dirtySize;\n this.resizeFramebuffer(framebuffer);\n }\n }\n for (var i = 0; i < framebuffer.colorTextures.length; i++) {\n var tex = framebuffer.colorTextures[i];\n this.renderer.texture.unbind(tex.parentTextureArray || tex);\n }\n if (framebuffer.depthTexture) {\n this.renderer.texture.unbind(framebuffer.depthTexture);\n }\n if (frame) {\n var mipWidth = (frame.width >> mipLevel);\n var mipHeight = (frame.height >> mipLevel);\n var scale = mipWidth / frame.width;\n this.setViewport(frame.x * scale, frame.y * scale, mipWidth, mipHeight);\n }\n else {\n var mipWidth = (framebuffer.width >> mipLevel);\n var mipHeight = (framebuffer.height >> mipLevel);\n this.setViewport(0, 0, mipWidth, mipHeight);\n }\n }\n else {\n if (this.current) {\n this.current = null;\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n }\n if (frame) {\n this.setViewport(frame.x, frame.y, frame.width, frame.height);\n }\n else {\n this.setViewport(0, 0, this.renderer.width, this.renderer.height);\n }\n }\n };\n /**\n * Set the WebGLRenderingContext's viewport.\n *\n * @param x - X position of viewport\n * @param y - Y position of viewport\n * @param width - Width of viewport\n * @param height - Height of viewport\n */\n FramebufferSystem.prototype.setViewport = function (x, y, width, height) {\n var v = this.viewport;\n x = Math.round(x);\n y = Math.round(y);\n width = Math.round(width);\n height = Math.round(height);\n if (v.width !== width || v.height !== height || v.x !== x || v.y !== y) {\n v.x = x;\n v.y = y;\n v.width = width;\n v.height = height;\n this.gl.viewport(x, y, width, height);\n }\n };\n Object.defineProperty(FramebufferSystem.prototype, \"size\", {\n /**\n * Get the size of the current width and height. Returns object with `width` and `height` values.\n *\n * @readonly\n */\n get: function () {\n if (this.current) {\n // TODO store temp\n return { x: 0, y: 0, width: this.current.width, height: this.current.height };\n }\n return { x: 0, y: 0, width: this.renderer.width, height: this.renderer.height };\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Clear the color of the context\n *\n * @param r - Red value from 0 to 1\n * @param g - Green value from 0 to 1\n * @param b - Blue value from 0 to 1\n * @param a - Alpha value from 0 to 1\n * @param {PIXI.BUFFER_BITS} [mask=BUFFER_BITS.COLOR | BUFFER_BITS.DEPTH] - Bitwise OR of masks\n * that indicate the buffers to be cleared, by default COLOR and DEPTH buffers.\n */\n FramebufferSystem.prototype.clear = function (r, g, b, a, mask) {\n if (mask === void 0) { mask = BUFFER_BITS.COLOR | BUFFER_BITS.DEPTH; }\n var gl = this.gl;\n // TODO clear color can be set only one right?\n gl.clearColor(r, g, b, a);\n gl.clear(mask);\n };\n /**\n * Initialize framebuffer for this context\n *\n * @protected\n * @param framebuffer\n * @returns - created GLFramebuffer\n */\n FramebufferSystem.prototype.initFramebuffer = function (framebuffer) {\n var gl = this.gl;\n var fbo = new GLFramebuffer(gl.createFramebuffer());\n fbo.multisample = this.detectSamples(framebuffer.multisample);\n framebuffer.glFramebuffers[this.CONTEXT_UID] = fbo;\n this.managedFramebuffers.push(framebuffer);\n framebuffer.disposeRunner.add(this);\n return fbo;\n };\n /**\n * Resize the framebuffer\n *\n * @protected\n */\n FramebufferSystem.prototype.resizeFramebuffer = function (framebuffer) {\n var gl = this.gl;\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n if (fbo.msaaBuffer) {\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.msaaBuffer);\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.RGBA8, framebuffer.width, framebuffer.height);\n }\n if (fbo.stencil) {\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.stencil);\n if (fbo.msaaBuffer) {\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.DEPTH24_STENCIL8, framebuffer.width, framebuffer.height);\n }\n else {\n gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_STENCIL, framebuffer.width, framebuffer.height);\n }\n }\n var colorTextures = framebuffer.colorTextures;\n var count = colorTextures.length;\n if (!gl.drawBuffers) {\n count = Math.min(count, 1);\n }\n for (var i = 0; i < count; i++) {\n var texture = colorTextures[i];\n var parentTexture = texture.parentTextureArray || texture;\n this.renderer.texture.bind(parentTexture, 0);\n }\n if (framebuffer.depthTexture && this.writeDepthTexture) {\n this.renderer.texture.bind(framebuffer.depthTexture, 0);\n }\n };\n /**\n * Update the framebuffer\n *\n * @protected\n */\n FramebufferSystem.prototype.updateFramebuffer = function (framebuffer, mipLevel) {\n var gl = this.gl;\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n // bind the color texture\n var colorTextures = framebuffer.colorTextures;\n var count = colorTextures.length;\n if (!gl.drawBuffers) {\n count = Math.min(count, 1);\n }\n if (fbo.multisample > 1 && this.canMultisampleFramebuffer(framebuffer)) {\n fbo.msaaBuffer = fbo.msaaBuffer || gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.msaaBuffer);\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.RGBA8, framebuffer.width, framebuffer.height);\n gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.RENDERBUFFER, fbo.msaaBuffer);\n }\n else if (fbo.msaaBuffer) {\n gl.deleteRenderbuffer(fbo.msaaBuffer);\n fbo.msaaBuffer = null;\n if (fbo.blitFramebuffer) {\n fbo.blitFramebuffer.dispose();\n fbo.blitFramebuffer = null;\n }\n }\n var activeTextures = [];\n for (var i = 0; i < count; i++) {\n var texture = colorTextures[i];\n var parentTexture = texture.parentTextureArray || texture;\n this.renderer.texture.bind(parentTexture, 0);\n if (i === 0 && fbo.msaaBuffer) {\n continue;\n }\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + i, texture.target, parentTexture._glTextures[this.CONTEXT_UID].texture, mipLevel);\n activeTextures.push(gl.COLOR_ATTACHMENT0 + i);\n }\n if (activeTextures.length > 1) {\n gl.drawBuffers(activeTextures);\n }\n if (framebuffer.depthTexture) {\n var writeDepthTexture = this.writeDepthTexture;\n if (writeDepthTexture) {\n var depthTexture = framebuffer.depthTexture;\n this.renderer.texture.bind(depthTexture, 0);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.TEXTURE_2D, depthTexture._glTextures[this.CONTEXT_UID].texture, mipLevel);\n }\n }\n if ((framebuffer.stencil || framebuffer.depth) && !(framebuffer.depthTexture && this.writeDepthTexture)) {\n fbo.stencil = fbo.stencil || gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, fbo.stencil);\n if (fbo.msaaBuffer) {\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.DEPTH24_STENCIL8, framebuffer.width, framebuffer.height);\n }\n else {\n gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_STENCIL, framebuffer.width, framebuffer.height);\n }\n gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.RENDERBUFFER, fbo.stencil);\n }\n else if (fbo.stencil) {\n gl.deleteRenderbuffer(fbo.stencil);\n fbo.stencil = null;\n }\n };\n /** Returns true if the frame buffer can be multisampled. */\n FramebufferSystem.prototype.canMultisampleFramebuffer = function (framebuffer) {\n return this.renderer.context.webGLVersion !== 1\n && framebuffer.colorTextures.length <= 1 && !framebuffer.depthTexture;\n };\n /**\n * Detects number of samples that is not more than a param but as close to it as possible\n *\n * @param samples - number of samples\n * @returns - recommended number of samples\n */\n FramebufferSystem.prototype.detectSamples = function (samples) {\n var msaaSamples = this.msaaSamples;\n var res = MSAA_QUALITY.NONE;\n if (samples <= 1 || msaaSamples === null) {\n return res;\n }\n for (var i = 0; i < msaaSamples.length; i++) {\n if (msaaSamples[i] <= samples) {\n res = msaaSamples[i];\n break;\n }\n }\n if (res === 1) {\n res = MSAA_QUALITY.NONE;\n }\n return res;\n };\n /**\n * Only works with WebGL2\n *\n * blits framebuffer to another of the same or bigger size\n * after that target framebuffer is bound\n *\n * Fails with WebGL warning if blits multisample framebuffer to different size\n *\n * @param framebuffer - by default it blits \"into itself\", from renderBuffer to texture.\n * @param sourcePixels - source rectangle in pixels\n * @param destPixels - dest rectangle in pixels, assumed to be the same as sourcePixels\n */\n FramebufferSystem.prototype.blit = function (framebuffer, sourcePixels, destPixels) {\n var _a = this, current = _a.current, renderer = _a.renderer, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n if (renderer.context.webGLVersion !== 2) {\n return;\n }\n if (!current) {\n return;\n }\n var fbo = current.glFramebuffers[CONTEXT_UID];\n if (!fbo) {\n return;\n }\n if (!framebuffer) {\n if (!fbo.msaaBuffer) {\n return;\n }\n var colorTexture = current.colorTextures[0];\n if (!colorTexture) {\n return;\n }\n if (!fbo.blitFramebuffer) {\n fbo.blitFramebuffer = new Framebuffer(current.width, current.height);\n fbo.blitFramebuffer.addColorTexture(0, colorTexture);\n }\n framebuffer = fbo.blitFramebuffer;\n if (framebuffer.colorTextures[0] !== colorTexture) {\n framebuffer.colorTextures[0] = colorTexture;\n framebuffer.dirtyId++;\n framebuffer.dirtyFormat++;\n }\n if (framebuffer.width !== current.width || framebuffer.height !== current.height) {\n framebuffer.width = current.width;\n framebuffer.height = current.height;\n framebuffer.dirtyId++;\n framebuffer.dirtySize++;\n }\n }\n if (!sourcePixels) {\n sourcePixels = tempRectangle;\n sourcePixels.width = current.width;\n sourcePixels.height = current.height;\n }\n if (!destPixels) {\n destPixels = sourcePixels;\n }\n var sameSize = sourcePixels.width === destPixels.width && sourcePixels.height === destPixels.height;\n this.bind(framebuffer);\n gl.bindFramebuffer(gl.READ_FRAMEBUFFER, fbo.framebuffer);\n gl.blitFramebuffer(sourcePixels.left, sourcePixels.top, sourcePixels.right, sourcePixels.bottom, destPixels.left, destPixels.top, destPixels.right, destPixels.bottom, gl.COLOR_BUFFER_BIT, sameSize ? gl.NEAREST : gl.LINEAR);\n };\n /**\n * Disposes framebuffer.\n *\n * @param framebuffer - framebuffer that has to be disposed of\n * @param contextLost - If context was lost, we suppress all delete function calls\n */\n FramebufferSystem.prototype.disposeFramebuffer = function (framebuffer, contextLost) {\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n var gl = this.gl;\n if (!fbo) {\n return;\n }\n delete framebuffer.glFramebuffers[this.CONTEXT_UID];\n var index = this.managedFramebuffers.indexOf(framebuffer);\n if (index >= 0) {\n this.managedFramebuffers.splice(index, 1);\n }\n framebuffer.disposeRunner.remove(this);\n if (!contextLost) {\n gl.deleteFramebuffer(fbo.framebuffer);\n if (fbo.msaaBuffer) {\n gl.deleteRenderbuffer(fbo.msaaBuffer);\n }\n if (fbo.stencil) {\n gl.deleteRenderbuffer(fbo.stencil);\n }\n }\n if (fbo.blitFramebuffer) {\n fbo.blitFramebuffer.dispose();\n }\n };\n /**\n * Disposes all framebuffers, but not textures bound to them.\n *\n * @param [contextLost=false] - If context was lost, we suppress all delete function calls\n */\n FramebufferSystem.prototype.disposeAll = function (contextLost) {\n var list = this.managedFramebuffers;\n this.managedFramebuffers = [];\n for (var i = 0; i < list.length; i++) {\n this.disposeFramebuffer(list[i], contextLost);\n }\n };\n /**\n * Forcing creation of stencil buffer for current framebuffer, if it wasn't done before.\n * Used by MaskSystem, when its time to use stencil mask for Graphics element.\n *\n * Its an alternative for public lazy `framebuffer.enableStencil`, in case we need stencil without rebind.\n *\n * @private\n */\n FramebufferSystem.prototype.forceStencil = function () {\n var framebuffer = this.current;\n if (!framebuffer) {\n return;\n }\n var fbo = framebuffer.glFramebuffers[this.CONTEXT_UID];\n if (!fbo || fbo.stencil) {\n return;\n }\n framebuffer.stencil = true;\n var w = framebuffer.width;\n var h = framebuffer.height;\n var gl = this.gl;\n var stencil = gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, stencil);\n if (fbo.msaaBuffer) {\n gl.renderbufferStorageMultisample(gl.RENDERBUFFER, fbo.multisample, gl.DEPTH24_STENCIL8, w, h);\n }\n else {\n gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_STENCIL, w, h);\n }\n fbo.stencil = stencil;\n gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.RENDERBUFFER, stencil);\n };\n /**\n * Resets framebuffer stored state, binds screen framebuffer.\n *\n * Should be called before renderTexture reset().\n */\n FramebufferSystem.prototype.reset = function () {\n this.current = this.unknownFramebuffer;\n this.viewport = new Rectangle();\n };\n FramebufferSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return FramebufferSystem;\n}());\n\nvar byteSizeMap$1 = { 5126: 4, 5123: 2, 5121: 1 };\n/**\n * System plugin to the renderer to manage geometry.\n *\n * @memberof PIXI\n */\nvar GeometrySystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function GeometrySystem(renderer) {\n this.renderer = renderer;\n this._activeGeometry = null;\n this._activeVao = null;\n this.hasVao = true;\n this.hasInstance = true;\n this.canUseUInt32ElementIndex = false;\n this.managedGeometries = {};\n }\n /** Sets up the renderer context and necessary buffers. */\n GeometrySystem.prototype.contextChange = function () {\n this.disposeAll(true);\n var gl = this.gl = this.renderer.gl;\n var context = this.renderer.context;\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n // webgl2\n if (context.webGLVersion !== 2) {\n // webgl 1!\n var nativeVaoExtension_1 = this.renderer.context.extensions.vertexArrayObject;\n if (settings.PREFER_ENV === ENV.WEBGL_LEGACY) {\n nativeVaoExtension_1 = null;\n }\n if (nativeVaoExtension_1) {\n gl.createVertexArray = function () {\n return nativeVaoExtension_1.createVertexArrayOES();\n };\n gl.bindVertexArray = function (vao) {\n return nativeVaoExtension_1.bindVertexArrayOES(vao);\n };\n gl.deleteVertexArray = function (vao) {\n return nativeVaoExtension_1.deleteVertexArrayOES(vao);\n };\n }\n else {\n this.hasVao = false;\n gl.createVertexArray = function () {\n return null;\n };\n gl.bindVertexArray = function () {\n return null;\n };\n gl.deleteVertexArray = function () {\n return null;\n };\n }\n }\n if (context.webGLVersion !== 2) {\n var instanceExt_1 = gl.getExtension('ANGLE_instanced_arrays');\n if (instanceExt_1) {\n gl.vertexAttribDivisor = function (a, b) {\n return instanceExt_1.vertexAttribDivisorANGLE(a, b);\n };\n gl.drawElementsInstanced = function (a, b, c, d, e) {\n return instanceExt_1.drawElementsInstancedANGLE(a, b, c, d, e);\n };\n gl.drawArraysInstanced = function (a, b, c, d) {\n return instanceExt_1.drawArraysInstancedANGLE(a, b, c, d);\n };\n }\n else {\n this.hasInstance = false;\n }\n }\n this.canUseUInt32ElementIndex = context.webGLVersion === 2 || !!context.extensions.uint32ElementIndex;\n };\n /**\n * Binds geometry so that is can be drawn. Creating a Vao if required\n *\n * @param geometry - Instance of geometry to bind.\n * @param shader - Instance of shader to use vao for.\n */\n GeometrySystem.prototype.bind = function (geometry, shader) {\n shader = shader || this.renderer.shader.shader;\n var gl = this.gl;\n // not sure the best way to address this..\n // currently different shaders require different VAOs for the same geometry\n // Still mulling over the best way to solve this one..\n // will likely need to modify the shader attribute locations at run time!\n var vaos = geometry.glVertexArrayObjects[this.CONTEXT_UID];\n var incRefCount = false;\n if (!vaos) {\n this.managedGeometries[geometry.id] = geometry;\n geometry.disposeRunner.add(this);\n geometry.glVertexArrayObjects[this.CONTEXT_UID] = vaos = {};\n incRefCount = true;\n }\n var vao = vaos[shader.program.id] || this.initGeometryVao(geometry, shader, incRefCount);\n this._activeGeometry = geometry;\n if (this._activeVao !== vao) {\n this._activeVao = vao;\n if (this.hasVao) {\n gl.bindVertexArray(vao);\n }\n else {\n this.activateVao(geometry, shader.program);\n }\n }\n // TODO - optimise later!\n // don't need to loop through if nothing changed!\n // maybe look to add an 'autoupdate' to geometry?\n this.updateBuffers();\n };\n /** Reset and unbind any active VAO and geometry. */\n GeometrySystem.prototype.reset = function () {\n this.unbind();\n };\n /** Update buffers of the currently bound geometry. */\n GeometrySystem.prototype.updateBuffers = function () {\n var geometry = this._activeGeometry;\n var bufferSystem = this.renderer.buffer;\n for (var i = 0; i < geometry.buffers.length; i++) {\n var buffer = geometry.buffers[i];\n bufferSystem.update(buffer);\n }\n };\n /**\n * Check compatibility between a geometry and a program\n *\n * @param geometry - Geometry instance.\n * @param program - Program instance.\n */\n GeometrySystem.prototype.checkCompatibility = function (geometry, program) {\n // geometry must have at least all the attributes that the shader requires.\n var geometryAttributes = geometry.attributes;\n var shaderAttributes = program.attributeData;\n for (var j in shaderAttributes) {\n if (!geometryAttributes[j]) {\n throw new Error(\"shader and geometry incompatible, geometry missing the \\\"\" + j + \"\\\" attribute\");\n }\n }\n };\n /**\n * Takes a geometry and program and generates a unique signature for them.\n *\n * @param geometry - To get signature from.\n * @param program - To test geometry against.\n * @return - Unique signature of the geometry and program\n */\n GeometrySystem.prototype.getSignature = function (geometry, program) {\n var attribs = geometry.attributes;\n var shaderAttributes = program.attributeData;\n var strings = ['g', geometry.id];\n for (var i in attribs) {\n if (shaderAttributes[i]) {\n strings.push(i, shaderAttributes[i].location);\n }\n }\n return strings.join('-');\n };\n /**\n * Creates or gets Vao with the same structure as the geometry and stores it on the geometry.\n * If vao is created, it is bound automatically. We use a shader to infer what and how to set up the\n * attribute locations.\n *\n * @param geometry - Instance of geometry to to generate Vao for.\n * @param shader - Instance of the shader.\n * @param incRefCount - Increment refCount of all geometry buffers.\n */\n GeometrySystem.prototype.initGeometryVao = function (geometry, shader, incRefCount) {\n if (incRefCount === void 0) { incRefCount = true; }\n var gl = this.gl;\n var CONTEXT_UID = this.CONTEXT_UID;\n var bufferSystem = this.renderer.buffer;\n var program = shader.program;\n if (!program.glPrograms[CONTEXT_UID]) {\n this.renderer.shader.generateProgram(shader);\n }\n this.checkCompatibility(geometry, program);\n var signature = this.getSignature(geometry, program);\n var vaoObjectHash = geometry.glVertexArrayObjects[this.CONTEXT_UID];\n var vao = vaoObjectHash[signature];\n if (vao) {\n // this will give us easy access to the vao\n vaoObjectHash[program.id] = vao;\n return vao;\n }\n var buffers = geometry.buffers;\n var attributes = geometry.attributes;\n var tempStride = {};\n var tempStart = {};\n for (var j in buffers) {\n tempStride[j] = 0;\n tempStart[j] = 0;\n }\n for (var j in attributes) {\n if (!attributes[j].size && program.attributeData[j]) {\n attributes[j].size = program.attributeData[j].size;\n }\n else if (!attributes[j].size) {\n console.warn(\"PIXI Geometry attribute '\" + j + \"' size cannot be determined (likely the bound shader does not have the attribute)\"); // eslint-disable-line\n }\n tempStride[attributes[j].buffer] += attributes[j].size * byteSizeMap$1[attributes[j].type];\n }\n for (var j in attributes) {\n var attribute = attributes[j];\n var attribSize = attribute.size;\n if (attribute.stride === undefined) {\n if (tempStride[attribute.buffer] === attribSize * byteSizeMap$1[attribute.type]) {\n attribute.stride = 0;\n }\n else {\n attribute.stride = tempStride[attribute.buffer];\n }\n }\n if (attribute.start === undefined) {\n attribute.start = tempStart[attribute.buffer];\n tempStart[attribute.buffer] += attribSize * byteSizeMap$1[attribute.type];\n }\n }\n vao = gl.createVertexArray();\n gl.bindVertexArray(vao);\n // first update - and create the buffers!\n // only create a gl buffer if it actually gets\n for (var i = 0; i < buffers.length; i++) {\n var buffer = buffers[i];\n bufferSystem.bind(buffer);\n if (incRefCount) {\n buffer._glBuffers[CONTEXT_UID].refCount++;\n }\n }\n // TODO - maybe make this a data object?\n // lets wait to see if we need to first!\n this.activateVao(geometry, program);\n this._activeVao = vao;\n // add it to the cache!\n vaoObjectHash[program.id] = vao;\n vaoObjectHash[signature] = vao;\n return vao;\n };\n /**\n * Disposes geometry.\n *\n * @param geometry - Geometry with buffers. Only VAO will be disposed\n * @param [contextLost=false] - If context was lost, we suppress deleteVertexArray\n */\n GeometrySystem.prototype.disposeGeometry = function (geometry, contextLost) {\n var _a;\n if (!this.managedGeometries[geometry.id]) {\n return;\n }\n delete this.managedGeometries[geometry.id];\n var vaos = geometry.glVertexArrayObjects[this.CONTEXT_UID];\n var gl = this.gl;\n var buffers = geometry.buffers;\n var bufferSystem = (_a = this.renderer) === null || _a === void 0 ? void 0 : _a.buffer;\n geometry.disposeRunner.remove(this);\n if (!vaos) {\n return;\n }\n // bufferSystem may have already been destroyed..\n // if this is the case, there is no need to destroy the geometry buffers...\n // they already have been!\n if (bufferSystem) {\n for (var i = 0; i < buffers.length; i++) {\n var buf = buffers[i]._glBuffers[this.CONTEXT_UID];\n // my be null as context may have changed right before the dispose is called\n if (buf) {\n buf.refCount--;\n if (buf.refCount === 0 && !contextLost) {\n bufferSystem.dispose(buffers[i], contextLost);\n }\n }\n }\n }\n if (!contextLost) {\n for (var vaoId in vaos) {\n // delete only signatures, everything else are copies\n if (vaoId[0] === 'g') {\n var vao = vaos[vaoId];\n if (this._activeVao === vao) {\n this.unbind();\n }\n gl.deleteVertexArray(vao);\n }\n }\n }\n delete geometry.glVertexArrayObjects[this.CONTEXT_UID];\n };\n /**\n * Dispose all WebGL resources of all managed geometries.\n *\n * @param [contextLost=false] - If context was lost, we suppress `gl.delete` calls\n */\n GeometrySystem.prototype.disposeAll = function (contextLost) {\n var all = Object.keys(this.managedGeometries);\n for (var i = 0; i < all.length; i++) {\n this.disposeGeometry(this.managedGeometries[all[i]], contextLost);\n }\n };\n /**\n * Activate vertex array object.\n *\n * @param geometry - Geometry instance.\n * @param program - Shader program instance.\n */\n GeometrySystem.prototype.activateVao = function (geometry, program) {\n var gl = this.gl;\n var CONTEXT_UID = this.CONTEXT_UID;\n var bufferSystem = this.renderer.buffer;\n var buffers = geometry.buffers;\n var attributes = geometry.attributes;\n if (geometry.indexBuffer) {\n // first update the index buffer if we have one..\n bufferSystem.bind(geometry.indexBuffer);\n }\n var lastBuffer = null;\n // add a new one!\n for (var j in attributes) {\n var attribute = attributes[j];\n var buffer = buffers[attribute.buffer];\n var glBuffer = buffer._glBuffers[CONTEXT_UID];\n if (program.attributeData[j]) {\n if (lastBuffer !== glBuffer) {\n bufferSystem.bind(buffer);\n lastBuffer = glBuffer;\n }\n var location = program.attributeData[j].location;\n // TODO introduce state again\n // we can optimise this for older devices that have no VAOs\n gl.enableVertexAttribArray(location);\n gl.vertexAttribPointer(location, attribute.size, attribute.type || gl.FLOAT, attribute.normalized, attribute.stride, attribute.start);\n if (attribute.instance) {\n // TODO calculate instance count based of this...\n if (this.hasInstance) {\n gl.vertexAttribDivisor(location, 1);\n }\n else {\n throw new Error('geometry error, GPU Instancing is not supported on this device');\n }\n }\n }\n }\n };\n /**\n * Draws the currently bound geometry.\n *\n * @param type - The type primitive to render.\n * @param size - The number of elements to be rendered. If not specified, all vertices after the\n * starting vertex will be drawn.\n * @param start - The starting vertex in the geometry to start drawing from. If not specified,\n * drawing will start from the first vertex.\n * @param instanceCount - The number of instances of the set of elements to execute. If not specified,\n * all instances will be drawn.\n */\n GeometrySystem.prototype.draw = function (type, size, start, instanceCount) {\n var gl = this.gl;\n var geometry = this._activeGeometry;\n // TODO.. this should not change so maybe cache the function?\n if (geometry.indexBuffer) {\n var byteSize = geometry.indexBuffer.data.BYTES_PER_ELEMENT;\n var glType = byteSize === 2 ? gl.UNSIGNED_SHORT : gl.UNSIGNED_INT;\n if (byteSize === 2 || (byteSize === 4 && this.canUseUInt32ElementIndex)) {\n if (geometry.instanced) {\n /* eslint-disable max-len */\n gl.drawElementsInstanced(type, size || geometry.indexBuffer.data.length, glType, (start || 0) * byteSize, instanceCount || 1);\n /* eslint-enable max-len */\n }\n else {\n /* eslint-disable max-len */\n gl.drawElements(type, size || geometry.indexBuffer.data.length, glType, (start || 0) * byteSize);\n /* eslint-enable max-len */\n }\n }\n else {\n console.warn('unsupported index buffer type: uint32');\n }\n }\n else if (geometry.instanced) {\n // TODO need a better way to calculate size..\n gl.drawArraysInstanced(type, start, size || geometry.getSize(), instanceCount || 1);\n }\n else {\n gl.drawArrays(type, start, size || geometry.getSize());\n }\n return this;\n };\n /** Unbind/reset everything. */\n GeometrySystem.prototype.unbind = function () {\n this.gl.bindVertexArray(null);\n this._activeVao = null;\n this._activeGeometry = null;\n };\n GeometrySystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return GeometrySystem;\n}());\n\n/**\n * Component for masked elements.\n *\n * Holds mask mode and temporary data about current mask.\n *\n * @memberof PIXI\n */\nvar MaskData = /** @class */ (function () {\n /**\n * Create MaskData\n *\n * @param {PIXI.DisplayObject} [maskObject=null] - object that describes the mask\n */\n function MaskData(maskObject) {\n if (maskObject === void 0) { maskObject = null; }\n this.type = MASK_TYPES.NONE;\n this.autoDetect = true;\n this.maskObject = maskObject || null;\n this.pooled = false;\n this.isMaskData = true;\n this.resolution = null;\n this.multisample = settings.FILTER_MULTISAMPLE;\n this.enabled = true;\n this._filters = null;\n this._stencilCounter = 0;\n this._scissorCounter = 0;\n this._scissorRect = null;\n this._scissorRectLocal = null;\n this._target = null;\n }\n Object.defineProperty(MaskData.prototype, \"filter\", {\n /**\n * The sprite mask filter.\n * If set to `null`, the default sprite mask filter is used.\n * @default null\n */\n get: function () {\n return this._filters ? this._filters[0] : null;\n },\n set: function (value) {\n if (value) {\n if (this._filters) {\n this._filters[0] = value;\n }\n else {\n this._filters = [value];\n }\n }\n else {\n this._filters = null;\n }\n },\n enumerable: false,\n configurable: true\n });\n /** Resets the mask data after popMask(). */\n MaskData.prototype.reset = function () {\n if (this.pooled) {\n this.maskObject = null;\n this.type = MASK_TYPES.NONE;\n this.autoDetect = true;\n }\n this._target = null;\n this._scissorRectLocal = null;\n };\n /** Copies counters from maskData above, called from pushMask(). */\n MaskData.prototype.copyCountersOrReset = function (maskAbove) {\n if (maskAbove) {\n this._stencilCounter = maskAbove._stencilCounter;\n this._scissorCounter = maskAbove._scissorCounter;\n this._scissorRect = maskAbove._scissorRect;\n }\n else {\n this._stencilCounter = 0;\n this._scissorCounter = 0;\n this._scissorRect = null;\n }\n };\n return MaskData;\n}());\n\n/**\n * @private\n * @param {WebGLRenderingContext} gl - The current WebGL context {WebGLProgram}\n * @param {Number} type - the type, can be either VERTEX_SHADER or FRAGMENT_SHADER\n * @param {string} src - The vertex shader source as an array of strings.\n * @return {WebGLShader} the shader\n */\nfunction compileShader(gl, type, src) {\n var shader = gl.createShader(type);\n gl.shaderSource(shader, src);\n gl.compileShader(shader);\n return shader;\n}\n\n/**\n * will log a shader error highlighting the lines with the error\n * also will add numbers along the side.\n *\n * @param gl - the WebGLContext\n * @param shader - the shader to log errors for\n */\nfunction logPrettyShaderError(gl, shader) {\n var shaderSrc = gl.getShaderSource(shader)\n .split('\\n')\n .map(function (line, index) { return index + \": \" + line; });\n var shaderLog = gl.getShaderInfoLog(shader);\n var splitShader = shaderLog.split('\\n');\n var dedupe = {};\n var lineNumbers = splitShader.map(function (line) { return parseFloat(line.replace(/^ERROR\\: 0\\:([\\d]+)\\:.*$/, '$1')); })\n .filter(function (n) {\n if (n && !dedupe[n]) {\n dedupe[n] = true;\n return true;\n }\n return false;\n });\n var logArgs = [''];\n lineNumbers.forEach(function (number) {\n shaderSrc[number - 1] = \"%c\" + shaderSrc[number - 1] + \"%c\";\n logArgs.push('background: #FF0000; color:#FFFFFF; font-size: 10px', 'font-size: 10px');\n });\n var fragmentSourceToLog = shaderSrc\n .join('\\n');\n logArgs[0] = fragmentSourceToLog;\n console.error(shaderLog);\n // eslint-disable-next-line no-console\n console.groupCollapsed('click to view full shader code');\n console.warn.apply(console, logArgs);\n // eslint-disable-next-line no-console\n console.groupEnd();\n}\n/**\n *\n * logs out any program errors\n *\n * @param gl - The current WebGL context\n * @param program - the WebGL program to display errors for\n * @param vertexShader - the fragment WebGL shader program\n * @param fragmentShader - the vertex WebGL shader program\n */\nfunction logProgramError(gl, program, vertexShader, fragmentShader) {\n // if linking fails, then log and cleanup\n if (!gl.getProgramParameter(program, gl.LINK_STATUS)) {\n if (!gl.getShaderParameter(vertexShader, gl.COMPILE_STATUS)) {\n logPrettyShaderError(gl, vertexShader);\n }\n if (!gl.getShaderParameter(fragmentShader, gl.COMPILE_STATUS)) {\n logPrettyShaderError(gl, fragmentShader);\n }\n console.error('PixiJS Error: Could not initialize shader.');\n // if there is a program info log, log it\n if (gl.getProgramInfoLog(program) !== '') {\n console.warn('PixiJS Warning: gl.getProgramInfoLog()', gl.getProgramInfoLog(program));\n }\n }\n}\n\nfunction booleanArray(size) {\n var array = new Array(size);\n for (var i = 0; i < array.length; i++) {\n array[i] = false;\n }\n return array;\n}\n/**\n * @method defaultValue\n * @memberof PIXI.glCore.shader\n * @param {string} type - Type of value\n * @param {number} size\n * @private\n */\nfunction defaultValue(type, size) {\n switch (type) {\n case 'float':\n return 0;\n case 'vec2':\n return new Float32Array(2 * size);\n case 'vec3':\n return new Float32Array(3 * size);\n case 'vec4':\n return new Float32Array(4 * size);\n case 'int':\n case 'uint':\n case 'sampler2D':\n case 'sampler2DArray':\n return 0;\n case 'ivec2':\n return new Int32Array(2 * size);\n case 'ivec3':\n return new Int32Array(3 * size);\n case 'ivec4':\n return new Int32Array(4 * size);\n case 'uvec2':\n return new Uint32Array(2 * size);\n case 'uvec3':\n return new Uint32Array(3 * size);\n case 'uvec4':\n return new Uint32Array(4 * size);\n case 'bool':\n return false;\n case 'bvec2':\n return booleanArray(2 * size);\n case 'bvec3':\n return booleanArray(3 * size);\n case 'bvec4':\n return booleanArray(4 * size);\n case 'mat2':\n return new Float32Array([1, 0,\n 0, 1]);\n case 'mat3':\n return new Float32Array([1, 0, 0,\n 0, 1, 0,\n 0, 0, 1]);\n case 'mat4':\n return new Float32Array([1, 0, 0, 0,\n 0, 1, 0, 0,\n 0, 0, 1, 0,\n 0, 0, 0, 1]);\n }\n return null;\n}\n\nvar unknownContext = {};\nvar context = unknownContext;\n/**\n * returns a little WebGL context to use for program inspection.\n *\n * @static\n * @private\n * @returns {WebGLRenderingContext} a gl context to test with\n */\nfunction getTestContext() {\n if (context === unknownContext || (context && context.isContextLost())) {\n var canvas = document.createElement('canvas');\n var gl = void 0;\n if (settings.PREFER_ENV >= ENV.WEBGL2) {\n gl = canvas.getContext('webgl2', {});\n }\n if (!gl) {\n gl = canvas.getContext('webgl', {})\n || canvas.getContext('experimental-webgl', {});\n if (!gl) {\n // fail, not able to get a context\n gl = null;\n }\n else {\n // for shader testing..\n gl.getExtension('WEBGL_draw_buffers');\n }\n }\n context = gl;\n }\n return context;\n}\n\nvar maxFragmentPrecision;\nfunction getMaxFragmentPrecision() {\n if (!maxFragmentPrecision) {\n maxFragmentPrecision = PRECISION.MEDIUM;\n var gl = getTestContext();\n if (gl) {\n if (gl.getShaderPrecisionFormat) {\n var shaderFragment = gl.getShaderPrecisionFormat(gl.FRAGMENT_SHADER, gl.HIGH_FLOAT);\n maxFragmentPrecision = shaderFragment.precision ? PRECISION.HIGH : PRECISION.MEDIUM;\n }\n }\n }\n return maxFragmentPrecision;\n}\n\n/**\n * Sets the float precision on the shader, ensuring the device supports the request precision.\n * If the precision is already present, it just ensures that the device is able to handle it.\n *\n * @private\n * @param {string} src - The shader source\n * @param {PIXI.PRECISION} requestedPrecision - The request float precision of the shader.\n * @param {PIXI.PRECISION} maxSupportedPrecision - The maximum precision the shader supports.\n *\n * @return {string} modified shader source\n */\nfunction setPrecision(src, requestedPrecision, maxSupportedPrecision) {\n if (src.substring(0, 9) !== 'precision') {\n // no precision supplied, so PixiJS will add the requested level.\n var precision = requestedPrecision;\n // If highp is requested but not supported, downgrade precision to a level all devices support.\n if (requestedPrecision === PRECISION.HIGH && maxSupportedPrecision !== PRECISION.HIGH) {\n precision = PRECISION.MEDIUM;\n }\n return \"precision \" + precision + \" float;\\n\" + src;\n }\n else if (maxSupportedPrecision !== PRECISION.HIGH && src.substring(0, 15) === 'precision highp') {\n // precision was supplied, but at a level this device does not support, so downgrading to mediump.\n return src.replace('precision highp', 'precision mediump');\n }\n return src;\n}\n\nvar GLSL_TO_SIZE = {\n float: 1,\n vec2: 2,\n vec3: 3,\n vec4: 4,\n int: 1,\n ivec2: 2,\n ivec3: 3,\n ivec4: 4,\n uint: 1,\n uvec2: 2,\n uvec3: 3,\n uvec4: 4,\n bool: 1,\n bvec2: 2,\n bvec3: 3,\n bvec4: 4,\n mat2: 4,\n mat3: 9,\n mat4: 16,\n sampler2D: 1,\n};\n/**\n * @private\n * @method mapSize\n * @memberof PIXI.glCore.shader\n * @param {String} type\n * @return {Number}\n */\nfunction mapSize(type) {\n return GLSL_TO_SIZE[type];\n}\n\nvar GL_TABLE = null;\nvar GL_TO_GLSL_TYPES = {\n FLOAT: 'float',\n FLOAT_VEC2: 'vec2',\n FLOAT_VEC3: 'vec3',\n FLOAT_VEC4: 'vec4',\n INT: 'int',\n INT_VEC2: 'ivec2',\n INT_VEC3: 'ivec3',\n INT_VEC4: 'ivec4',\n UNSIGNED_INT: 'uint',\n UNSIGNED_INT_VEC2: 'uvec2',\n UNSIGNED_INT_VEC3: 'uvec3',\n UNSIGNED_INT_VEC4: 'uvec4',\n BOOL: 'bool',\n BOOL_VEC2: 'bvec2',\n BOOL_VEC3: 'bvec3',\n BOOL_VEC4: 'bvec4',\n FLOAT_MAT2: 'mat2',\n FLOAT_MAT3: 'mat3',\n FLOAT_MAT4: 'mat4',\n SAMPLER_2D: 'sampler2D',\n INT_SAMPLER_2D: 'sampler2D',\n UNSIGNED_INT_SAMPLER_2D: 'sampler2D',\n SAMPLER_CUBE: 'samplerCube',\n INT_SAMPLER_CUBE: 'samplerCube',\n UNSIGNED_INT_SAMPLER_CUBE: 'samplerCube',\n SAMPLER_2D_ARRAY: 'sampler2DArray',\n INT_SAMPLER_2D_ARRAY: 'sampler2DArray',\n UNSIGNED_INT_SAMPLER_2D_ARRAY: 'sampler2DArray',\n};\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\nfunction mapType(gl, type) {\n if (!GL_TABLE) {\n var typeNames = Object.keys(GL_TO_GLSL_TYPES);\n GL_TABLE = {};\n for (var i = 0; i < typeNames.length; ++i) {\n var tn = typeNames[i];\n GL_TABLE[gl[tn]] = GL_TO_GLSL_TYPES[tn];\n }\n }\n return GL_TABLE[type];\n}\n\n/* eslint-disable @typescript-eslint/explicit-module-boundary-types */\n// Parsers, each one of these will take a look at the type of shader property and uniform.\n// if they pass the test function then the code function is called that returns a the shader upload code for that uniform.\n// Shader upload code is automagically generated with these parsers.\n// If no parser is valid then the default upload functions are used.\n// exposing Parsers means that custom upload logic can be added to pixi's shaders.\n// A good example would be a pixi rectangle can be directly set on a uniform.\n// If the shader sees it it knows how to upload the rectangle structure as a vec4\n// format is as follows:\n//\n// {\n// test: (data, uniform) => {} <--- test is this code should be used for this uniform\n// code: (name, uniform) => {} <--- returns the string of the piece of code that uploads the uniform\n// codeUbo: (name, uniform) => {} <--- returns the string of the piece of code that uploads the\n// uniform to a uniform buffer\n// }\nvar uniformParsers = [\n // a float cache layer\n {\n test: function (data) {\n return data.type === 'float' && data.size === 1;\n },\n code: function (name) {\n return \"\\n if(uv[\\\"\" + name + \"\\\"] !== ud[\\\"\" + name + \"\\\"].value)\\n {\\n ud[\\\"\" + name + \"\\\"].value = uv[\\\"\" + name + \"\\\"]\\n gl.uniform1f(ud[\\\"\" + name + \"\\\"].location, uv[\\\"\" + name + \"\\\"])\\n }\\n \";\n },\n },\n // handling samplers\n {\n test: function (data) {\n // eslint-disable-next-line max-len\n return (data.type === 'sampler2D' || data.type === 'samplerCube' || data.type === 'sampler2DArray') && data.size === 1 && !data.isArray;\n },\n code: function (name) { return \"t = syncData.textureCount++;\\n\\n renderer.texture.bind(uv[\\\"\" + name + \"\\\"], t);\\n\\n if(ud[\\\"\" + name + \"\\\"].value !== t)\\n {\\n ud[\\\"\" + name + \"\\\"].value = t;\\n gl.uniform1i(ud[\\\"\" + name + \"\\\"].location, t);\\n; // eslint-disable-line max-len\\n }\"; },\n },\n // uploading pixi matrix object to mat3\n {\n test: function (data, uniform) {\n return data.type === 'mat3' && data.size === 1 && uniform.a !== undefined;\n },\n code: function (name) {\n // TODO and some smart caching dirty ids here!\n return \"\\n gl.uniformMatrix3fv(ud[\\\"\" + name + \"\\\"].location, false, uv[\\\"\" + name + \"\\\"].toArray(true));\\n \";\n },\n codeUbo: function (name) {\n return \"\\n var \" + name + \"_matrix = uv.\" + name + \".toArray(true);\\n\\n data[offset] = \" + name + \"_matrix[0];\\n data[offset+1] = \" + name + \"_matrix[1];\\n data[offset+2] = \" + name + \"_matrix[2];\\n \\n data[offset + 4] = \" + name + \"_matrix[3];\\n data[offset + 5] = \" + name + \"_matrix[4];\\n data[offset + 6] = \" + name + \"_matrix[5];\\n \\n data[offset + 8] = \" + name + \"_matrix[6];\\n data[offset + 9] = \" + name + \"_matrix[7];\\n data[offset + 10] = \" + name + \"_matrix[8];\\n \";\n },\n },\n // uploading a pixi point as a vec2 with caching layer\n {\n test: function (data, uniform) {\n return data.type === 'vec2' && data.size === 1 && uniform.x !== undefined;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v.x || cv[1] !== v.y)\\n {\\n cv[0] = v.x;\\n cv[1] = v.y;\\n gl.uniform2f(ud[\\\"\" + name + \"\\\"].location, v.x, v.y);\\n }\";\n },\n codeUbo: function (name) {\n return \"\\n v = uv.\" + name + \";\\n\\n data[offset] = v.x;\\n data[offset+1] = v.y;\\n \";\n }\n },\n // caching layer for a vec2\n {\n test: function (data) {\n return data.type === 'vec2' && data.size === 1;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n gl.uniform2f(ud[\\\"\" + name + \"\\\"].location, v[0], v[1]);\\n }\\n \";\n },\n },\n // upload a pixi rectangle as a vec4 with caching layer\n {\n test: function (data, uniform) {\n return data.type === 'vec4' && data.size === 1 && uniform.width !== undefined;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v.x || cv[1] !== v.y || cv[2] !== v.width || cv[3] !== v.height)\\n {\\n cv[0] = v.x;\\n cv[1] = v.y;\\n cv[2] = v.width;\\n cv[3] = v.height;\\n gl.uniform4f(ud[\\\"\" + name + \"\\\"].location, v.x, v.y, v.width, v.height)\\n }\";\n },\n codeUbo: function (name) {\n return \"\\n v = uv.\" + name + \";\\n\\n data[offset] = v.x;\\n data[offset+1] = v.y;\\n data[offset+2] = v.width;\\n data[offset+3] = v.height;\\n \";\n }\n },\n // a caching layer for vec4 uploading\n {\n test: function (data) {\n return data.type === 'vec4' && data.size === 1;\n },\n code: function (name) {\n return \"\\n cv = ud[\\\"\" + name + \"\\\"].value;\\n v = uv[\\\"\" + name + \"\\\"];\\n\\n if(cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4f(ud[\\\"\" + name + \"\\\"].location, v[0], v[1], v[2], v[3])\\n }\";\n },\n } ];\n\n// cu = Cached value's uniform data field\n// cv = Cached value\n// v = value to upload\n// ud = uniformData\n// uv = uniformValue\n// l = location\nvar GLSL_TO_SINGLE_SETTERS_CACHED = {\n float: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n gl.uniform1f(location, v);\\n }\",\n vec2: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2f(location, v[0], v[1])\\n }\",\n vec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3f(location, v[0], v[1], v[2])\\n }\",\n vec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4f(location, v[0], v[1], v[2], v[3]);\\n }\",\n int: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n\\n gl.uniform1i(location, v);\\n }\",\n ivec2: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2i(location, v[0], v[1]);\\n }\",\n ivec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3i(location, v[0], v[1], v[2]);\\n }\",\n ivec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\\n }\",\n uint: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n\\n gl.uniform1ui(location, v);\\n }\",\n uvec2: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2ui(location, v[0], v[1]);\\n }\",\n uvec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3ui(location, v[0], v[1], v[2]);\\n }\",\n uvec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4ui(location, v[0], v[1], v[2], v[3]);\\n }\",\n bool: \"\\n if (cv !== v)\\n {\\n cu.value = v;\\n gl.uniform1i(location, v);\\n }\",\n bvec2: \"\\n if (cv[0] != v[0] || cv[1] != v[1])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n\\n gl.uniform2i(location, v[0], v[1]);\\n }\",\n bvec3: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n\\n gl.uniform3i(location, v[0], v[1], v[2]);\\n }\",\n bvec4: \"\\n if (cv[0] !== v[0] || cv[1] !== v[1] || cv[2] !== v[2] || cv[3] !== v[3])\\n {\\n cv[0] = v[0];\\n cv[1] = v[1];\\n cv[2] = v[2];\\n cv[3] = v[3];\\n\\n gl.uniform4i(location, v[0], v[1], v[2], v[3]);\\n }\",\n mat2: 'gl.uniformMatrix2fv(location, false, v)',\n mat3: 'gl.uniformMatrix3fv(location, false, v)',\n mat4: 'gl.uniformMatrix4fv(location, false, v)',\n sampler2D: 'gl.uniform1i(location, v)',\n samplerCube: 'gl.uniform1i(location, v)',\n sampler2DArray: 'gl.uniform1i(location, v)',\n};\nvar GLSL_TO_ARRAY_SETTERS = {\n float: \"gl.uniform1fv(location, v)\",\n vec2: \"gl.uniform2fv(location, v)\",\n vec3: \"gl.uniform3fv(location, v)\",\n vec4: 'gl.uniform4fv(location, v)',\n mat4: 'gl.uniformMatrix4fv(location, false, v)',\n mat3: 'gl.uniformMatrix3fv(location, false, v)',\n mat2: 'gl.uniformMatrix2fv(location, false, v)',\n int: 'gl.uniform1iv(location, v)',\n ivec2: 'gl.uniform2iv(location, v)',\n ivec3: 'gl.uniform3iv(location, v)',\n ivec4: 'gl.uniform4iv(location, v)',\n uint: 'gl.uniform1uiv(location, v)',\n uvec2: 'gl.uniform2uiv(location, v)',\n uvec3: 'gl.uniform3uiv(location, v)',\n uvec4: 'gl.uniform4uiv(location, v)',\n bool: 'gl.uniform1iv(location, v)',\n bvec2: 'gl.uniform2iv(location, v)',\n bvec3: 'gl.uniform3iv(location, v)',\n bvec4: 'gl.uniform4iv(location, v)',\n sampler2D: 'gl.uniform1iv(location, v)',\n samplerCube: 'gl.uniform1iv(location, v)',\n sampler2DArray: 'gl.uniform1iv(location, v)',\n};\nfunction generateUniformsSync(group, uniformData) {\n var _a;\n var funcFragments = [\"\\n var v = null;\\n var cv = null;\\n var cu = null;\\n var t = 0;\\n var gl = renderer.gl;\\n \"];\n for (var i in group.uniforms) {\n var data = uniformData[i];\n if (!data) {\n if ((_a = group.uniforms[i]) === null || _a === void 0 ? void 0 : _a.group) {\n if (group.uniforms[i].ubo) {\n funcFragments.push(\"\\n renderer.shader.syncUniformBufferGroup(uv.\" + i + \", '\" + i + \"');\\n \");\n }\n else {\n funcFragments.push(\"\\n renderer.shader.syncUniformGroup(uv.\" + i + \", syncData);\\n \");\n }\n }\n continue;\n }\n var uniform = group.uniforms[i];\n var parsed = false;\n for (var j = 0; j < uniformParsers.length; j++) {\n if (uniformParsers[j].test(data, uniform)) {\n funcFragments.push(uniformParsers[j].code(i, uniform));\n parsed = true;\n break;\n }\n }\n if (!parsed) {\n var templateType = (data.size === 1) ? GLSL_TO_SINGLE_SETTERS_CACHED : GLSL_TO_ARRAY_SETTERS;\n var template = templateType[data.type].replace('location', \"ud[\\\"\" + i + \"\\\"].location\");\n funcFragments.push(\"\\n cu = ud[\\\"\" + i + \"\\\"];\\n cv = cu.value;\\n v = uv[\\\"\" + i + \"\\\"];\\n \" + template + \";\");\n }\n }\n /*\n * the introduction of syncData is to solve an issue where textures in uniform groups are not set correctly\n * the texture count was always starting from 0 in each group. This needs to increment each time a texture is used\n * no matter which group is being used\n *\n */\n // eslint-disable-next-line no-new-func\n return new Function('ud', 'uv', 'renderer', 'syncData', funcFragments.join('\\n'));\n}\n\nvar fragTemplate = [\n 'precision mediump float;',\n 'void main(void){',\n 'float test = 0.1;',\n '%forloop%',\n 'gl_FragColor = vec4(0.0);',\n '}' ].join('\\n');\nfunction generateIfTestSrc(maxIfs) {\n var src = '';\n for (var i = 0; i < maxIfs; ++i) {\n if (i > 0) {\n src += '\\nelse ';\n }\n if (i < maxIfs - 1) {\n src += \"if(test == \" + i + \".0){}\";\n }\n }\n return src;\n}\nfunction checkMaxIfStatementsInShader(maxIfs, gl) {\n if (maxIfs === 0) {\n throw new Error('Invalid value of `0` passed to `checkMaxIfStatementsInShader`');\n }\n var shader = gl.createShader(gl.FRAGMENT_SHADER);\n while (true) // eslint-disable-line no-constant-condition\n {\n var fragmentSrc = fragTemplate.replace(/%forloop%/gi, generateIfTestSrc(maxIfs));\n gl.shaderSource(shader, fragmentSrc);\n gl.compileShader(shader);\n if (!gl.getShaderParameter(shader, gl.COMPILE_STATUS)) {\n maxIfs = (maxIfs / 2) | 0;\n }\n else {\n // valid!\n break;\n }\n }\n return maxIfs;\n}\n\n// Cache the result to prevent running this over and over\nvar unsafeEval;\n/**\n * Not all platforms allow to generate function code (e.g., `new Function`).\n * this provides the platform-level detection.\n *\n * @private\n * @returns {boolean}\n */\nfunction unsafeEvalSupported() {\n if (typeof unsafeEval === 'boolean') {\n return unsafeEval;\n }\n try {\n /* eslint-disable no-new-func */\n var func = new Function('param1', 'param2', 'param3', 'return param1[param2] === param3;');\n /* eslint-enable no-new-func */\n unsafeEval = func({ a: 'b' }, 'a', 'b') === true;\n }\n catch (e) {\n unsafeEval = false;\n }\n return unsafeEval;\n}\n\nvar defaultFragment = \"varying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void){\\n gl_FragColor *= texture2D(uSampler, vTextureCoord);\\n}\";\n\nvar defaultVertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void){\\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n vTextureCoord = aTextureCoord;\\n}\\n\";\n\nvar UID$3 = 0;\nvar nameCache = {};\n/**\n * Helper class to create a shader program.\n *\n * @memberof PIXI\n */\nvar Program = /** @class */ (function () {\n /**\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param name - Name for shader\n */\n function Program(vertexSrc, fragmentSrc, name) {\n if (name === void 0) { name = 'pixi-shader'; }\n this.id = UID$3++;\n this.vertexSrc = vertexSrc || Program.defaultVertexSrc;\n this.fragmentSrc = fragmentSrc || Program.defaultFragmentSrc;\n this.vertexSrc = this.vertexSrc.trim();\n this.fragmentSrc = this.fragmentSrc.trim();\n if (this.vertexSrc.substring(0, 8) !== '#version') {\n name = name.replace(/\\s+/g, '-');\n if (nameCache[name]) {\n nameCache[name]++;\n name += \"-\" + nameCache[name];\n }\n else {\n nameCache[name] = 1;\n }\n this.vertexSrc = \"#define SHADER_NAME \" + name + \"\\n\" + this.vertexSrc;\n this.fragmentSrc = \"#define SHADER_NAME \" + name + \"\\n\" + this.fragmentSrc;\n this.vertexSrc = setPrecision(this.vertexSrc, settings.PRECISION_VERTEX, PRECISION.HIGH);\n this.fragmentSrc = setPrecision(this.fragmentSrc, settings.PRECISION_FRAGMENT, getMaxFragmentPrecision());\n }\n // currently this does not extract structs only default types\n // this is where we store shader references..\n this.glPrograms = {};\n this.syncUniforms = null;\n }\n Object.defineProperty(Program, \"defaultVertexSrc\", {\n /**\n * The default vertex shader source.\n *\n * @constant\n */\n get: function () {\n return defaultVertex;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Program, \"defaultFragmentSrc\", {\n /**\n * The default fragment shader source.\n *\n * @constant\n */\n get: function () {\n return defaultFragment;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * A short hand function to create a program based of a vertex and fragment shader.\n *\n * This method will also check to see if there is a cached program.\n *\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param name - Name for shader\n * @returns A shiny new PixiJS shader program!\n */\n Program.from = function (vertexSrc, fragmentSrc, name) {\n var key = vertexSrc + fragmentSrc;\n var program = ProgramCache[key];\n if (!program) {\n ProgramCache[key] = program = new Program(vertexSrc, fragmentSrc, name);\n }\n return program;\n };\n return Program;\n}());\n\n/**\n * A helper class for shaders.\n *\n * @memberof PIXI\n */\nvar Shader = /** @class */ (function () {\n /**\n * @param program - The program the shader will use.\n * @param uniforms - Custom uniforms to use to augment the built-in ones.\n */\n function Shader(program, uniforms) {\n /**\n * Used internally to bind uniform buffer objects.\n * @ignore\n */\n this.uniformBindCount = 0;\n this.program = program;\n // lets see whats been passed in\n // uniforms should be converted to a uniform group\n if (uniforms) {\n if (uniforms instanceof UniformGroup) {\n this.uniformGroup = uniforms;\n }\n else {\n this.uniformGroup = new UniformGroup(uniforms);\n }\n }\n else {\n this.uniformGroup = new UniformGroup({});\n }\n }\n // TODO move to shader system..\n Shader.prototype.checkUniformExists = function (name, group) {\n if (group.uniforms[name]) {\n return true;\n }\n for (var i in group.uniforms) {\n var uniform = group.uniforms[i];\n if (uniform.group) {\n if (this.checkUniformExists(name, uniform)) {\n return true;\n }\n }\n }\n return false;\n };\n Shader.prototype.destroy = function () {\n // usage count on programs?\n // remove if not used!\n this.uniformGroup = null;\n };\n Object.defineProperty(Shader.prototype, \"uniforms\", {\n /**\n * Shader uniform values, shortcut for `uniformGroup.uniforms`.\n *\n * @readonly\n */\n get: function () {\n return this.uniformGroup.uniforms;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * A short hand function to create a shader based of a vertex and fragment shader.\n *\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param uniforms - Custom uniforms to use to augment the built-in ones.\n * @returns A shiny new PixiJS shader!\n */\n Shader.from = function (vertexSrc, fragmentSrc, uniforms) {\n var program = Program.from(vertexSrc, fragmentSrc);\n return new Shader(program, uniforms);\n };\n return Shader;\n}());\n\n/* eslint-disable max-len */\nvar BLEND = 0;\nvar OFFSET = 1;\nvar CULLING = 2;\nvar DEPTH_TEST = 3;\nvar WINDING = 4;\nvar DEPTH_MASK = 5;\n/**\n * This is a WebGL state, and is is passed to {@link PIXI.StateSystem}.\n *\n * Each mesh rendered may require WebGL to be in a different state.\n * For example you may want different blend mode or to enable polygon offsets\n *\n * @memberof PIXI\n */\nvar State = /** @class */ (function () {\n function State() {\n this.data = 0;\n this.blendMode = BLEND_MODES.NORMAL;\n this.polygonOffset = 0;\n this.blend = true;\n this.depthMask = true;\n // this.depthTest = true;\n }\n Object.defineProperty(State.prototype, \"blend\", {\n /**\n * Activates blending of the computed fragment color values.\n *\n * @default true\n */\n get: function () {\n return !!(this.data & (1 << BLEND));\n },\n set: function (value) {\n if (!!(this.data & (1 << BLEND)) !== value) {\n this.data ^= (1 << BLEND);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"offsets\", {\n /**\n * Activates adding an offset to depth values of polygon's fragments\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << OFFSET));\n },\n set: function (value) {\n if (!!(this.data & (1 << OFFSET)) !== value) {\n this.data ^= (1 << OFFSET);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"culling\", {\n /**\n * Activates culling of polygons.\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << CULLING));\n },\n set: function (value) {\n if (!!(this.data & (1 << CULLING)) !== value) {\n this.data ^= (1 << CULLING);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"depthTest\", {\n /**\n * Activates depth comparisons and updates to the depth buffer.\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << DEPTH_TEST));\n },\n set: function (value) {\n if (!!(this.data & (1 << DEPTH_TEST)) !== value) {\n this.data ^= (1 << DEPTH_TEST);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"depthMask\", {\n /**\n * Enables or disables writing to the depth buffer.\n *\n * @default true\n */\n get: function () {\n return !!(this.data & (1 << DEPTH_MASK));\n },\n set: function (value) {\n if (!!(this.data & (1 << DEPTH_MASK)) !== value) {\n this.data ^= (1 << DEPTH_MASK);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"clockwiseFrontFace\", {\n /**\n * Specifies whether or not front or back-facing polygons can be culled.\n *\n * @default false\n */\n get: function () {\n return !!(this.data & (1 << WINDING));\n },\n set: function (value) {\n if (!!(this.data & (1 << WINDING)) !== value) {\n this.data ^= (1 << WINDING);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"blendMode\", {\n /**\n * The blend mode to be applied when this state is set. Apply a value of `PIXI.BLEND_MODES.NORMAL` to reset the blend mode.\n * Setting this mode to anything other than NO_BLEND will automatically switch blending on.\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n get: function () {\n return this._blendMode;\n },\n set: function (value) {\n this.blend = (value !== BLEND_MODES.NONE);\n this._blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(State.prototype, \"polygonOffset\", {\n /**\n * The polygon offset. Setting this property to anything other than 0 will automatically enable polygon offset fill.\n *\n * @default 0\n */\n get: function () {\n return this._polygonOffset;\n },\n set: function (value) {\n this.offsets = !!value;\n this._polygonOffset = value;\n },\n enumerable: false,\n configurable: true\n });\n State.prototype.toString = function () {\n return \"[@pixi/core:State \"\n + (\"blendMode=\" + this.blendMode + \" \")\n + (\"clockwiseFrontFace=\" + this.clockwiseFrontFace + \" \")\n + (\"culling=\" + this.culling + \" \")\n + (\"depthMask=\" + this.depthMask + \" \")\n + (\"polygonOffset=\" + this.polygonOffset)\n + \"]\";\n };\n State.for2d = function () {\n var state = new State();\n state.depthTest = false;\n state.blend = true;\n return state;\n };\n return State;\n}());\n\nvar defaultVertex$1 = \"attribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvec2 filterTextureCoord( void )\\n{\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n}\\n\\nvoid main(void)\\n{\\n gl_Position = filterVertexPosition();\\n vTextureCoord = filterTextureCoord();\\n}\\n\";\n\nvar defaultFragment$1 = \"varying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void){\\n gl_FragColor = texture2D(uSampler, vTextureCoord);\\n}\\n\";\n\n/**\n * A filter is a special shader that applies post-processing effects to an input texture and writes into an output\n * render-target.\n *\n * {@link http://pixijs.io/examples/#/filters/blur-filter.js Example} of the\n * {@link PIXI.filters.BlurFilter BlurFilter}.\n *\n * ### Usage\n * Filters can be applied to any DisplayObject or Container.\n * PixiJS' `FilterSystem` renders the container into temporary Framebuffer,\n * then filter renders it to the screen.\n * Multiple filters can be added to the `filters` array property and stacked on each other.\n *\n * ```\n * const filter = new PIXI.Filter(myShaderVert, myShaderFrag, { myUniform: 0.5 });\n * const container = new PIXI.Container();\n * container.filters = [filter];\n * ```\n *\n * ### Previous Version Differences\n *\n * In PixiJS **v3**, a filter was always applied to _whole screen_.\n *\n * In PixiJS **v4**, a filter can be applied _only part of the screen_.\n * Developers had to create a set of uniforms to deal with coordinates.\n *\n * In PixiJS **v5** combines _both approaches_.\n * Developers can use normal coordinates of v3 and then allow filter to use partial Framebuffers,\n * bringing those extra uniforms into account.\n *\n * Also be aware that we have changed default vertex shader, please consult\n * {@link https://github.com/pixijs/pixi.js/wiki/v5-Creating-filters Wiki}.\n *\n * ### Frames\n *\n * The following table summarizes the coordinate spaces used in the filtering pipeline:\n *\n * <table>\n * <thead>\n * <tr>\n * <th>Coordinate Space</th>\n * <th>Description</th>\n * </tr>\n * </thead>\n * <tbody>\n * <tr>\n * <td>Texture Coordinates</td>\n * <td>\n * The texture (or UV) coordinates in the input base-texture's space. These are normalized into the (0,1) range along\n * both axes.\n * </td>\n * </tr>\n * <tr>\n * <td>World Space</td>\n * <td>\n * A point in the same space as the world bounds of any display-object (i.e. in the scene graph's space).\n * </td>\n * </tr>\n * <tr>\n * <td>Physical Pixels</td>\n * <td>\n * This is base-texture's space with the origin on the top-left. You can calculate these by multiplying the texture\n * coordinates by the dimensions of the texture.\n * </td>\n * </tr>\n * </tbody>\n * </table>\n *\n * ### Built-in Uniforms\n *\n * PixiJS viewport uses screen (CSS) coordinates, `(0, 0, renderer.screen.width, renderer.screen.height)`,\n * and `projectionMatrix` uniform maps it to the gl viewport.\n *\n * **uSampler**\n *\n * The most important uniform is the input texture that container was rendered into.\n * _Important note: as with all Framebuffers in PixiJS, both input and output are\n * premultiplied by alpha._\n *\n * By default, input normalized coordinates are passed to fragment shader with `vTextureCoord`.\n * Use it to sample the input.\n *\n * ```\n * const fragment = `\n * varying vec2 vTextureCoord;\n * uniform sampler2D uSampler;\n * void main(void)\n * {\n * gl_FragColor = texture2D(uSampler, vTextureCoord);\n * }\n * `;\n *\n * const myFilter = new PIXI.Filter(null, fragment);\n * ```\n *\n * This filter is just one uniform less than {@link PIXI.filters.AlphaFilter AlphaFilter}.\n *\n * **outputFrame**\n *\n * The `outputFrame` holds the rectangle where filter is applied in screen (CSS) coordinates.\n * It's the same as `renderer.screen` for a fullscreen filter.\n * Only a part of `outputFrame.zw` size of temporary Framebuffer is used,\n * `(0, 0, outputFrame.width, outputFrame.height)`,\n *\n * Filters uses this quad to normalized (0-1) space, its passed into `aVertexPosition` attribute.\n * To calculate vertex position in screen space using normalized (0-1) space:\n *\n * ```\n * vec4 filterVertexPosition( void )\n * {\n * vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\n * return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\n * }\n * ```\n *\n * **inputSize**\n *\n * Temporary framebuffer is different, it can be either the size of screen, either power-of-two.\n * The `inputSize.xy` are size of temporary framebuffer that holds input.\n * The `inputSize.zw` is inverted, it's a shortcut to evade division inside the shader.\n *\n * Set `inputSize.xy = outputFrame.zw` for a fullscreen filter.\n *\n * To calculate input normalized coordinate, you have to map it to filter normalized space.\n * Multiply by `outputFrame.zw` to get input coordinate.\n * Divide by `inputSize.xy` to get input normalized coordinate.\n *\n * ```\n * vec2 filterTextureCoord( void )\n * {\n * return aVertexPosition * (outputFrame.zw * inputSize.zw); // same as /inputSize.xy\n * }\n * ```\n * **resolution**\n *\n * The `resolution` is the ratio of screen (CSS) pixels to real pixels.\n *\n * **inputPixel**\n *\n * `inputPixel.xy` is the size of framebuffer in real pixels, same as `inputSize.xy * resolution`\n * `inputPixel.zw` is inverted `inputPixel.xy`.\n *\n * It's handy for filters that use neighbour pixels, like {@link PIXI.filters.FXAAFilter FXAAFilter}.\n *\n * **inputClamp**\n *\n * If you try to get info from outside of used part of Framebuffer - you'll get undefined behaviour.\n * For displacements, coordinates has to be clamped.\n *\n * The `inputClamp.xy` is left-top pixel center, you may ignore it, because we use left-top part of Framebuffer\n * `inputClamp.zw` is bottom-right pixel center.\n *\n * ```\n * vec4 color = texture2D(uSampler, clamp(modifiedTextureCoord, inputClamp.xy, inputClamp.zw))\n * ```\n * OR\n * ```\n * vec4 color = texture2D(uSampler, min(modifigedTextureCoord, inputClamp.zw))\n * ```\n *\n * ### Additional Information\n *\n * Complete documentation on Filter usage is located in the\n * {@link https://github.com/pixijs/pixi.js/wiki/v5-Creating-filters Wiki}.\n *\n * Since PixiJS only had a handful of built-in filters, additional filters can be downloaded\n * {@link https://github.com/pixijs/pixi-filters here} from the PixiJS Filters repository.\n *\n * @memberof PIXI\n */\nvar Filter = /** @class */ (function (_super) {\n __extends(Filter, _super);\n /**\n * @param vertexSrc - The source of the vertex shader.\n * @param fragmentSrc - The source of the fragment shader.\n * @param uniforms - Custom uniforms to use to augment the built-in ones.\n */\n function Filter(vertexSrc, fragmentSrc, uniforms) {\n var _this = this;\n var program = Program.from(vertexSrc || Filter.defaultVertexSrc, fragmentSrc || Filter.defaultFragmentSrc);\n _this = _super.call(this, program, uniforms) || this;\n _this.padding = 0;\n _this.resolution = settings.FILTER_RESOLUTION;\n _this.multisample = settings.FILTER_MULTISAMPLE;\n _this.enabled = true;\n _this.autoFit = true;\n _this.state = new State();\n return _this;\n }\n /**\n * Applies the filter\n *\n * @param {PIXI.FilterSystem} filterManager - The renderer to retrieve the filter from\n * @param {PIXI.RenderTexture} input - The input render target.\n * @param {PIXI.RenderTexture} output - The target to output to.\n * @param {PIXI.CLEAR_MODES} [clearMode] - Should the output be cleared before rendering to it.\n * @param {object} [currentState] - It's current state of filter.\n * There are some useful properties in the currentState :\n * target, filters, sourceFrame, destinationFrame, renderTarget, resolution\n */\n Filter.prototype.apply = function (filterManager, input, output, clearMode, _currentState) {\n // do as you please!\n filterManager.applyFilter(this, input, output, clearMode);\n // or just do a regular render..\n };\n Object.defineProperty(Filter.prototype, \"blendMode\", {\n /**\n * Sets the blend mode of the filter.\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n get: function () {\n return this.state.blendMode;\n },\n set: function (value) {\n this.state.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Filter.prototype, \"resolution\", {\n /**\n * The resolution of the filter. Setting this to be lower will lower the quality but\n * increase the performance of the filter.\n */\n get: function () {\n return this._resolution;\n },\n set: function (value) {\n this._resolution = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Filter, \"defaultVertexSrc\", {\n /**\n * The default vertex shader source\n *\n * @constant\n */\n get: function () {\n return defaultVertex$1;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Filter, \"defaultFragmentSrc\", {\n /**\n * The default fragment shader source\n *\n * @constant\n */\n get: function () {\n return defaultFragment$1;\n },\n enumerable: false,\n configurable: true\n });\n return Filter;\n}(Shader));\n\nvar vertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 otherMatrix;\\n\\nvarying vec2 vMaskCoord;\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = aTextureCoord;\\n vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;\\n}\\n\";\n\nvar fragment = \"varying vec2 vMaskCoord;\\nvarying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform sampler2D mask;\\nuniform float alpha;\\nuniform float npmAlpha;\\nuniform vec4 maskClamp;\\n\\nvoid main(void)\\n{\\n float clip = step(3.5,\\n step(maskClamp.x, vMaskCoord.x) +\\n step(maskClamp.y, vMaskCoord.y) +\\n step(vMaskCoord.x, maskClamp.z) +\\n step(vMaskCoord.y, maskClamp.w));\\n\\n vec4 original = texture2D(uSampler, vTextureCoord);\\n vec4 masky = texture2D(mask, vMaskCoord);\\n float alphaMul = 1.0 - npmAlpha * (1.0 - masky.a);\\n\\n original *= (alphaMul * masky.r * alpha * clip);\\n\\n gl_FragColor = original;\\n}\\n\";\n\nvar tempMat = new Matrix();\n/**\n * Class controls uv mapping from Texture normal space to BaseTexture normal space.\n *\n * Takes `trim` and `rotate` into account. May contain clamp settings for Meshes and TilingSprite.\n *\n * Can be used in Texture `uvMatrix` field, or separately, you can use different clamp settings on the same texture.\n * If you want to add support for texture region of certain feature or filter, that's what you're looking for.\n *\n * Takes track of Texture changes through `_lastTextureID` private field.\n * Use `update()` method call to track it from outside.\n *\n * @see PIXI.Texture\n * @see PIXI.Mesh\n * @see PIXI.TilingSprite\n * @memberof PIXI\n */\nvar TextureMatrix = /** @class */ (function () {\n /**\n * @param texture - observed texture\n * @param clampMargin - Changes frame clamping, 0.5 by default. Use -0.5 for extra border.\n */\n function TextureMatrix(texture, clampMargin) {\n this._texture = texture;\n this.mapCoord = new Matrix();\n this.uClampFrame = new Float32Array(4);\n this.uClampOffset = new Float32Array(2);\n this._textureID = -1;\n this._updateID = 0;\n this.clampOffset = 0;\n this.clampMargin = (typeof clampMargin === 'undefined') ? 0.5 : clampMargin;\n this.isSimple = false;\n }\n Object.defineProperty(TextureMatrix.prototype, \"texture\", {\n /** Texture property. */\n get: function () {\n return this._texture;\n },\n set: function (value) {\n this._texture = value;\n this._textureID = -1;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Multiplies uvs array to transform\n *\n * @param uvs - mesh uvs\n * @param [out=uvs] - output\n * @returns - output\n */\n TextureMatrix.prototype.multiplyUvs = function (uvs, out) {\n if (out === undefined) {\n out = uvs;\n }\n var mat = this.mapCoord;\n for (var i = 0; i < uvs.length; i += 2) {\n var x = uvs[i];\n var y = uvs[i + 1];\n out[i] = (x * mat.a) + (y * mat.c) + mat.tx;\n out[i + 1] = (x * mat.b) + (y * mat.d) + mat.ty;\n }\n return out;\n };\n /**\n * Updates matrices if texture was changed.\n *\n * @param [forceUpdate=false] - if true, matrices will be updated any case\n * @returns - Whether or not it was updated\n */\n TextureMatrix.prototype.update = function (forceUpdate) {\n var tex = this._texture;\n if (!tex || !tex.valid) {\n return false;\n }\n if (!forceUpdate\n && this._textureID === tex._updateID) {\n return false;\n }\n this._textureID = tex._updateID;\n this._updateID++;\n var uvs = tex._uvs;\n this.mapCoord.set(uvs.x1 - uvs.x0, uvs.y1 - uvs.y0, uvs.x3 - uvs.x0, uvs.y3 - uvs.y0, uvs.x0, uvs.y0);\n var orig = tex.orig;\n var trim = tex.trim;\n if (trim) {\n tempMat.set(orig.width / trim.width, 0, 0, orig.height / trim.height, -trim.x / trim.width, -trim.y / trim.height);\n this.mapCoord.append(tempMat);\n }\n var texBase = tex.baseTexture;\n var frame = this.uClampFrame;\n var margin = this.clampMargin / texBase.resolution;\n var offset = this.clampOffset;\n frame[0] = (tex._frame.x + margin + offset) / texBase.width;\n frame[1] = (tex._frame.y + margin + offset) / texBase.height;\n frame[2] = (tex._frame.x + tex._frame.width - margin + offset) / texBase.width;\n frame[3] = (tex._frame.y + tex._frame.height - margin + offset) / texBase.height;\n this.uClampOffset[0] = offset / texBase.realWidth;\n this.uClampOffset[1] = offset / texBase.realHeight;\n this.isSimple = tex._frame.width === texBase.width\n && tex._frame.height === texBase.height\n && tex.rotate === 0;\n return true;\n };\n return TextureMatrix;\n}());\n\n/**\n * This handles a Sprite acting as a mask, as opposed to a Graphic.\n *\n * WebGL only.\n *\n * @memberof PIXI\n */\nvar SpriteMaskFilter = /** @class */ (function (_super) {\n __extends(SpriteMaskFilter, _super);\n /** @ignore */\n function SpriteMaskFilter(vertexSrc, fragmentSrc, uniforms) {\n var _this = this;\n var sprite = null;\n if (typeof vertexSrc !== 'string' && fragmentSrc === undefined && uniforms === undefined) {\n sprite = vertexSrc;\n vertexSrc = undefined;\n fragmentSrc = undefined;\n uniforms = undefined;\n }\n _this = _super.call(this, vertexSrc || vertex, fragmentSrc || fragment, uniforms) || this;\n _this.maskSprite = sprite;\n _this.maskMatrix = new Matrix();\n return _this;\n }\n Object.defineProperty(SpriteMaskFilter.prototype, \"maskSprite\", {\n /**\n * Sprite mask\n *\n * @type {PIXI.DisplayObject}\n */\n get: function () {\n return this._maskSprite;\n },\n set: function (value) {\n this._maskSprite = value;\n if (this._maskSprite) {\n this._maskSprite.renderable = false;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Applies the filter\n *\n * @param filterManager - The renderer to retrieve the filter from\n * @param input - The input render target.\n * @param output - The target to output to.\n * @param clearMode - Should the output be cleared before rendering to it.\n */\n SpriteMaskFilter.prototype.apply = function (filterManager, input, output, clearMode) {\n var maskSprite = this._maskSprite;\n var tex = maskSprite._texture;\n if (!tex.valid) {\n return;\n }\n if (!tex.uvMatrix) {\n // margin = 0.0, let it bleed a bit, shader code becomes easier\n // assuming that atlas textures were made with 1-pixel padding\n tex.uvMatrix = new TextureMatrix(tex, 0.0);\n }\n tex.uvMatrix.update();\n this.uniforms.npmAlpha = tex.baseTexture.alphaMode ? 0.0 : 1.0;\n this.uniforms.mask = tex;\n // get _normalized sprite texture coords_ and convert them to _normalized atlas texture coords_ with `prepend`\n this.uniforms.otherMatrix = filterManager.calculateSpriteMatrix(this.maskMatrix, maskSprite)\n .prepend(tex.uvMatrix.mapCoord);\n this.uniforms.alpha = maskSprite.worldAlpha;\n this.uniforms.maskClamp = tex.uvMatrix.uClampFrame;\n filterManager.applyFilter(this, input, output, clearMode);\n };\n return SpriteMaskFilter;\n}(Filter));\n\n/**\n * System plugin to the renderer to manage masks.\n *\n * There are three built-in types of masking:\n * * **Scissor Masking**: Scissor masking discards pixels that are outside of a rectangle called the scissor box. It is\n * the most performant as the scissor test is inexpensive. However, it can only be used when the mask is rectangular.\n * * **Stencil Masking**: Stencil masking discards pixels that don't overlap with the pixels rendered into the stencil\n * buffer. It is the next fastest option as it does not require rendering into a separate framebuffer. However, it does\n * cause the mask to be rendered **twice** for each masking operation; hence, minimize the rendering cost of your masks.\n * * **Sprite Mask Filtering**: Sprite mask filtering discards pixels based on the red channel of the sprite-mask's\n * texture. (Generally, the masking texture is grayscale). Using advanced techniques, you might be able to embed this\n * type of masking in a custom shader - and hence, bypassing the masking system fully for performance wins.\n *\n * The best type of masking is auto-detected when you `push` one. To use scissor masking, you must pass in a `Graphics`\n * object with just a rectangle drawn.\n *\n * ## Mask Stacks\n *\n * In the scene graph, masks can be applied recursively, i.e. a mask can be applied during a masking operation. The mask\n * stack stores the currently applied masks in order. Each {@link PIXI.BaseRenderTexture} holds its own mask stack, i.e.\n * when you switch render-textures, the old masks only applied when you switch back to rendering to the old render-target.\n *\n * @memberof PIXI\n */\nvar MaskSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function MaskSystem(renderer) {\n this.renderer = renderer;\n this.enableScissor = true;\n this.alphaMaskPool = [];\n this.maskDataPool = [];\n this.maskStack = [];\n this.alphaMaskIndex = 0;\n }\n /**\n * Changes the mask stack that is used by this System.\n *\n * @param maskStack - The mask stack\n */\n MaskSystem.prototype.setMaskStack = function (maskStack) {\n this.maskStack = maskStack;\n this.renderer.scissor.setMaskStack(maskStack);\n this.renderer.stencil.setMaskStack(maskStack);\n };\n /**\n * Enables the mask and appends it to the current mask stack.\n *\n * NOTE: The batch renderer should be flushed beforehand to prevent pending renders from being masked.\n *\n * @param {PIXI.DisplayObject} target - Display Object to push the mask to\n * @param {PIXI.MaskData|PIXI.Sprite|PIXI.Graphics|PIXI.DisplayObject} maskData - The masking data.\n */\n MaskSystem.prototype.push = function (target, maskDataOrTarget) {\n var maskData = maskDataOrTarget;\n if (!maskData.isMaskData) {\n var d = this.maskDataPool.pop() || new MaskData();\n d.pooled = true;\n d.maskObject = maskDataOrTarget;\n maskData = d;\n }\n var maskAbove = this.maskStack.length !== 0 ? this.maskStack[this.maskStack.length - 1] : null;\n maskData.copyCountersOrReset(maskAbove);\n if (maskData.autoDetect) {\n this.detect(maskData);\n }\n maskData._target = target;\n if (maskData.type !== MASK_TYPES.SPRITE) {\n this.maskStack.push(maskData);\n }\n if (maskData.enabled) {\n switch (maskData.type) {\n case MASK_TYPES.SCISSOR:\n this.renderer.scissor.push(maskData);\n break;\n case MASK_TYPES.STENCIL:\n this.renderer.stencil.push(maskData);\n break;\n case MASK_TYPES.SPRITE:\n maskData.copyCountersOrReset(null);\n this.pushSpriteMask(maskData);\n break;\n }\n }\n if (maskData.type === MASK_TYPES.SPRITE) {\n this.maskStack.push(maskData);\n }\n };\n /**\n * Removes the last mask from the mask stack and doesn't return it.\n *\n * NOTE: The batch renderer should be flushed beforehand to render the masked contents before the mask is removed.\n *\n * @param {PIXI.DisplayObject} target - Display Object to pop the mask from\n */\n MaskSystem.prototype.pop = function (target) {\n var maskData = this.maskStack.pop();\n if (!maskData || maskData._target !== target) {\n // TODO: add an assert when we have it\n return;\n }\n if (maskData.enabled) {\n switch (maskData.type) {\n case MASK_TYPES.SCISSOR:\n this.renderer.scissor.pop();\n break;\n case MASK_TYPES.STENCIL:\n this.renderer.stencil.pop(maskData.maskObject);\n break;\n case MASK_TYPES.SPRITE:\n this.popSpriteMask(maskData);\n break;\n }\n }\n maskData.reset();\n if (maskData.pooled) {\n this.maskDataPool.push(maskData);\n }\n if (this.maskStack.length !== 0) {\n var maskCurrent = this.maskStack[this.maskStack.length - 1];\n if (maskCurrent.type === MASK_TYPES.SPRITE && maskCurrent._filters) {\n maskCurrent._filters[0].maskSprite = maskCurrent.maskObject;\n }\n }\n };\n /** Sets type of MaskData based on its maskObject. */\n MaskSystem.prototype.detect = function (maskData) {\n var maskObject = maskData.maskObject;\n if (maskObject.isSprite) {\n maskData.type = MASK_TYPES.SPRITE;\n }\n else if (this.enableScissor && this.renderer.scissor.testScissor(maskData)) {\n maskData.type = MASK_TYPES.SCISSOR;\n }\n else {\n maskData.type = MASK_TYPES.STENCIL;\n }\n };\n /**\n * Applies the Mask and adds it to the current filter stack.\n *\n * @param maskData - Sprite to be used as the mask.\n */\n MaskSystem.prototype.pushSpriteMask = function (maskData) {\n var _a, _b;\n var maskObject = maskData.maskObject;\n var target = maskData._target;\n var alphaMaskFilter = maskData._filters;\n if (!alphaMaskFilter) {\n alphaMaskFilter = this.alphaMaskPool[this.alphaMaskIndex];\n if (!alphaMaskFilter) {\n alphaMaskFilter = this.alphaMaskPool[this.alphaMaskIndex] = [new SpriteMaskFilter()];\n }\n }\n var renderer = this.renderer;\n var renderTextureSystem = renderer.renderTexture;\n var resolution;\n var multisample;\n if (renderTextureSystem.current) {\n var renderTexture = renderTextureSystem.current;\n resolution = maskData.resolution || renderTexture.resolution;\n multisample = (_a = maskData.multisample) !== null && _a !== void 0 ? _a : renderTexture.multisample;\n }\n else {\n resolution = maskData.resolution || renderer.resolution;\n multisample = (_b = maskData.multisample) !== null && _b !== void 0 ? _b : renderer.multisample;\n }\n alphaMaskFilter[0].resolution = resolution;\n alphaMaskFilter[0].multisample = multisample;\n alphaMaskFilter[0].maskSprite = maskObject;\n var stashFilterArea = target.filterArea;\n target.filterArea = maskObject.getBounds(true);\n renderer.filter.push(target, alphaMaskFilter);\n target.filterArea = stashFilterArea;\n if (!maskData._filters) {\n this.alphaMaskIndex++;\n }\n };\n /**\n * Removes the last filter from the filter stack and doesn't return it.\n *\n * @param maskData - Sprite to be used as the mask.\n */\n MaskSystem.prototype.popSpriteMask = function (maskData) {\n this.renderer.filter.pop();\n if (maskData._filters) {\n maskData._filters[0].maskSprite = null;\n }\n else {\n this.alphaMaskIndex--;\n this.alphaMaskPool[this.alphaMaskIndex][0].maskSprite = null;\n }\n };\n MaskSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return MaskSystem;\n}());\n\n/**\n * System plugin to the renderer to manage specific types of masking operations.\n *\n * @memberof PIXI\n */\nvar AbstractMaskSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function AbstractMaskSystem(renderer) {\n this.renderer = renderer;\n this.maskStack = [];\n this.glConst = 0;\n }\n /** Gets count of masks of certain type. */\n AbstractMaskSystem.prototype.getStackLength = function () {\n return this.maskStack.length;\n };\n /**\n * Changes the mask stack that is used by this System.\n *\n * @param {PIXI.MaskData[]} maskStack - The mask stack\n */\n AbstractMaskSystem.prototype.setMaskStack = function (maskStack) {\n var gl = this.renderer.gl;\n var curStackLen = this.getStackLength();\n this.maskStack = maskStack;\n var newStackLen = this.getStackLength();\n if (newStackLen !== curStackLen) {\n if (newStackLen === 0) {\n gl.disable(this.glConst);\n }\n else {\n gl.enable(this.glConst);\n this._useCurrent();\n }\n }\n };\n /**\n * Setup renderer to use the current mask data.\n * @private\n */\n AbstractMaskSystem.prototype._useCurrent = function () {\n // OVERWRITE;\n };\n /** Destroys the mask stack. */\n AbstractMaskSystem.prototype.destroy = function () {\n this.renderer = null;\n this.maskStack = null;\n };\n return AbstractMaskSystem;\n}());\n\nvar tempMatrix$1 = new Matrix();\n/**\n * System plugin to the renderer to manage scissor masking.\n *\n * Scissor masking discards pixels outside of a rectangle called the scissor box. The scissor box is in the framebuffer\n * viewport's space; however, the mask's rectangle is projected from world-space to viewport space automatically\n * by this system.\n *\n * @memberof PIXI\n */\nvar ScissorSystem = /** @class */ (function (_super) {\n __extends(ScissorSystem, _super);\n /**\n * @param {PIXI.Renderer} renderer - The renderer this System works for.\n */\n function ScissorSystem(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.glConst = WebGLRenderingContext.SCISSOR_TEST;\n return _this;\n }\n ScissorSystem.prototype.getStackLength = function () {\n var maskData = this.maskStack[this.maskStack.length - 1];\n if (maskData) {\n return maskData._scissorCounter;\n }\n return 0;\n };\n /**\n * evaluates _boundsTransformed, _scissorRect for MaskData\n * @param maskData\n */\n ScissorSystem.prototype.calcScissorRect = function (maskData) {\n if (maskData._scissorRectLocal) {\n return;\n }\n var prevData = maskData._scissorRect;\n var maskObject = maskData.maskObject;\n var renderer = this.renderer;\n var renderTextureSystem = renderer.renderTexture;\n maskObject.renderable = true;\n var rect = maskObject.getBounds();\n this.roundFrameToPixels(rect, renderTextureSystem.current ? renderTextureSystem.current.resolution : renderer.resolution, renderTextureSystem.sourceFrame, renderTextureSystem.destinationFrame, renderer.projection.transform);\n maskObject.renderable = false;\n if (prevData) {\n rect.fit(prevData);\n }\n maskData._scissorRectLocal = rect;\n };\n ScissorSystem.isMatrixRotated = function (matrix) {\n if (!matrix) {\n return false;\n }\n var a = matrix.a, b = matrix.b, c = matrix.c, d = matrix.d;\n // Skip if skew/rotation present in matrix, except for multiple of 90° rotation. If rotation\n // is a multiple of 90°, then either pair of (b,c) or (a,d) will be (0,0).\n return ((Math.abs(b) > 1e-4 || Math.abs(c) > 1e-4)\n && (Math.abs(a) > 1e-4 || Math.abs(d) > 1e-4));\n };\n /**\n * Test, whether the object can be scissor mask with current renderer projection.\n * Calls \"calcScissorRect()\" if its true.\n * @param maskData mask data\n * @returns whether Whether the object can be scissor mask\n */\n ScissorSystem.prototype.testScissor = function (maskData) {\n var maskObject = maskData.maskObject;\n if (!maskObject.isFastRect || !maskObject.isFastRect()) {\n return false;\n }\n if (ScissorSystem.isMatrixRotated(maskObject.worldTransform)) {\n return false;\n }\n if (ScissorSystem.isMatrixRotated(this.renderer.projection.transform)) {\n return false;\n }\n this.calcScissorRect(maskData);\n var rect = maskData._scissorRectLocal;\n return rect.width > 0 && rect.height > 0;\n };\n ScissorSystem.prototype.roundFrameToPixels = function (frame, resolution, bindingSourceFrame, bindingDestinationFrame, transform) {\n if (ScissorSystem.isMatrixRotated(transform)) {\n return;\n }\n transform = transform ? tempMatrix$1.copyFrom(transform) : tempMatrix$1.identity();\n // Get forward transform from world space to screen space\n transform\n .translate(-bindingSourceFrame.x, -bindingSourceFrame.y)\n .scale(bindingDestinationFrame.width / bindingSourceFrame.width, bindingDestinationFrame.height / bindingSourceFrame.height)\n .translate(bindingDestinationFrame.x, bindingDestinationFrame.y);\n // Convert frame to screen space\n this.renderer.filter.transformAABB(transform, frame);\n frame.fit(bindingDestinationFrame);\n frame.x = Math.round(frame.x * resolution);\n frame.y = Math.round(frame.y * resolution);\n frame.width = Math.round(frame.width * resolution);\n frame.height = Math.round(frame.height * resolution);\n };\n /**\n * Applies the Mask and adds it to the current stencil stack.\n *\n * @author alvin\n * @param maskData - The mask data.\n */\n ScissorSystem.prototype.push = function (maskData) {\n if (!maskData._scissorRectLocal) {\n this.calcScissorRect(maskData);\n }\n var gl = this.renderer.gl;\n if (!maskData._scissorRect) {\n gl.enable(gl.SCISSOR_TEST);\n }\n maskData._scissorCounter++;\n maskData._scissorRect = maskData._scissorRectLocal;\n this._useCurrent();\n };\n /**\n * This should be called after a mask is popped off the mask stack. It will rebind the scissor box to be latest with the\n * last mask in the stack.\n *\n * This can also be called when you directly modify the scissor box and want to restore PixiJS state.\n */\n ScissorSystem.prototype.pop = function () {\n var gl = this.renderer.gl;\n if (this.getStackLength() > 0) {\n this._useCurrent();\n }\n else {\n gl.disable(gl.SCISSOR_TEST);\n }\n };\n /**\n * Setup renderer to use the current scissor data.\n * @private\n */\n ScissorSystem.prototype._useCurrent = function () {\n var rect = this.maskStack[this.maskStack.length - 1]._scissorRect;\n var y;\n if (this.renderer.renderTexture.current) {\n y = rect.y;\n }\n else {\n // flipY. In future we'll have it over renderTextures as an option\n y = this.renderer.height - rect.height - rect.y;\n }\n this.renderer.gl.scissor(rect.x, y, rect.width, rect.height);\n };\n return ScissorSystem;\n}(AbstractMaskSystem));\n\n/**\n * System plugin to the renderer to manage stencils (used for masks).\n *\n * @memberof PIXI\n */\nvar StencilSystem = /** @class */ (function (_super) {\n __extends(StencilSystem, _super);\n /**\n * @param renderer - The renderer this System works for.\n */\n function StencilSystem(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.glConst = WebGLRenderingContext.STENCIL_TEST;\n return _this;\n }\n StencilSystem.prototype.getStackLength = function () {\n var maskData = this.maskStack[this.maskStack.length - 1];\n if (maskData) {\n return maskData._stencilCounter;\n }\n return 0;\n };\n /**\n * Applies the Mask and adds it to the current stencil stack.\n *\n * @param maskData - The mask data\n */\n StencilSystem.prototype.push = function (maskData) {\n var maskObject = maskData.maskObject;\n var gl = this.renderer.gl;\n var prevMaskCount = maskData._stencilCounter;\n if (prevMaskCount === 0) {\n // force use stencil texture in current framebuffer\n this.renderer.framebuffer.forceStencil();\n gl.clearStencil(0);\n gl.clear(gl.STENCIL_BUFFER_BIT);\n gl.enable(gl.STENCIL_TEST);\n }\n maskData._stencilCounter++;\n // Increment the reference stencil value where the new mask overlaps with the old ones.\n gl.colorMask(false, false, false, false);\n gl.stencilFunc(gl.EQUAL, prevMaskCount, 0xFFFFFFFF);\n gl.stencilOp(gl.KEEP, gl.KEEP, gl.INCR);\n maskObject.renderable = true;\n maskObject.render(this.renderer);\n this.renderer.batch.flush();\n maskObject.renderable = false;\n this._useCurrent();\n };\n /**\n * Pops stencil mask. MaskData is already removed from stack\n *\n * @param {PIXI.DisplayObject} maskObject - object of popped mask data\n */\n StencilSystem.prototype.pop = function (maskObject) {\n var gl = this.renderer.gl;\n if (this.getStackLength() === 0) {\n // the stack is empty!\n gl.disable(gl.STENCIL_TEST);\n }\n else {\n // Decrement the reference stencil value where the popped mask overlaps with the other ones\n gl.colorMask(false, false, false, false);\n gl.stencilOp(gl.KEEP, gl.KEEP, gl.DECR);\n maskObject.renderable = true;\n maskObject.render(this.renderer);\n this.renderer.batch.flush();\n maskObject.renderable = false;\n this._useCurrent();\n }\n };\n /**\n * Setup renderer to use the current stencil data.\n * @private\n */\n StencilSystem.prototype._useCurrent = function () {\n var gl = this.renderer.gl;\n gl.colorMask(true, true, true, true);\n gl.stencilFunc(gl.EQUAL, this.getStackLength(), 0xFFFFFFFF);\n gl.stencilOp(gl.KEEP, gl.KEEP, gl.KEEP);\n };\n return StencilSystem;\n}(AbstractMaskSystem));\n\n/**\n * System plugin to the renderer to manage the projection matrix.\n *\n * The `projectionMatrix` is a global uniform provided to all shaders. It is used to transform points in world space to\n * normalized device coordinates.\n *\n * @memberof PIXI\n */\nvar ProjectionSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function ProjectionSystem(renderer) {\n this.renderer = renderer;\n this.destinationFrame = null;\n this.sourceFrame = null;\n this.defaultFrame = null;\n this.projectionMatrix = new Matrix();\n this.transform = null;\n }\n /**\n * Updates the projection-matrix based on the sourceFrame → destinationFrame mapping provided.\n *\n * NOTE: It is expected you call `renderer.framebuffer.setViewport(destinationFrame)` after this. This is because\n * the framebuffer viewport converts shader vertex output in normalized device coordinates to window coordinates.\n *\n * NOTE-2: {@link RenderTextureSystem#bind} updates the projection-matrix when you bind a render-texture. It is expected\n * that you dirty the current bindings when calling this manually.\n *\n * @param destinationFrame - The rectangle in the render-target to render the contents into. If rendering to the canvas,\n * the origin is on the top-left; if rendering to a render-texture, the origin is on the bottom-left.\n * @param sourceFrame - The rectangle in world space that contains the contents being rendered.\n * @param resolution - The resolution of the render-target, which is the ratio of\n * world-space (or CSS) pixels to physical pixels.\n * @param root - Whether the render-target is the screen. This is required because rendering to textures\n * is y-flipped (i.e. upside down relative to the screen).\n */\n ProjectionSystem.prototype.update = function (destinationFrame, sourceFrame, resolution, root) {\n this.destinationFrame = destinationFrame || this.destinationFrame || this.defaultFrame;\n this.sourceFrame = sourceFrame || this.sourceFrame || destinationFrame;\n // Calculate object-space to clip-space projection\n this.calculateProjection(this.destinationFrame, this.sourceFrame, resolution, root);\n if (this.transform) {\n this.projectionMatrix.append(this.transform);\n }\n var renderer = this.renderer;\n renderer.globalUniforms.uniforms.projectionMatrix = this.projectionMatrix;\n renderer.globalUniforms.update();\n // this will work for now\n // but would be sweet to stick and even on the global uniforms..\n if (renderer.shader.shader) {\n renderer.shader.syncUniformGroup(renderer.shader.shader.uniforms.globals);\n }\n };\n /**\n * Calculates the `projectionMatrix` to map points inside `sourceFrame` to inside `destinationFrame`.\n *\n * @param destinationFrame - The destination frame in the render-target.\n * @param sourceFrame - The source frame in world space.\n * @param resolution - The render-target's resolution, i.e. ratio of CSS to physical pixels.\n * @param root - Whether rendering into the screen. Otherwise, if rendering to a framebuffer, the projection\n * is y-flipped.\n */\n ProjectionSystem.prototype.calculateProjection = function (_destinationFrame, sourceFrame, _resolution, root) {\n var pm = this.projectionMatrix;\n var sign = !root ? 1 : -1;\n pm.identity();\n pm.a = (1 / sourceFrame.width * 2);\n pm.d = sign * (1 / sourceFrame.height * 2);\n pm.tx = -1 - (sourceFrame.x * pm.a);\n pm.ty = -sign - (sourceFrame.y * pm.d);\n };\n /**\n * Sets the transform of the active render target to the given matrix.\n *\n * @param matrix - The transformation matrix\n */\n ProjectionSystem.prototype.setTransform = function (_matrix) {\n // this._activeRenderTarget.transform = matrix;\n };\n ProjectionSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return ProjectionSystem;\n}());\n\n// Temporary rectangle for assigned sourceFrame or destinationFrame\nvar tempRect = new Rectangle();\n// Temporary rectangle for renderTexture destinationFrame\nvar tempRect2 = new Rectangle();\n/* eslint-disable max-len */\n/**\n * System plugin to the renderer to manage render textures.\n *\n * Should be added after FramebufferSystem\n *\n * ### Frames\n *\n * The `RenderTextureSystem` holds a sourceFrame → destinationFrame projection. The following table explains the different\n * coordinate spaces used:\n *\n * | Frame | Description | Coordinate System |\n * | ---------------------- | ---------------------------------------------------------------- | ------------------------------------------------------- |\n * | sourceFrame | The rectangle inside of which display-objects are being rendered | **World Space**: The origin on the top-left |\n * | destinationFrame | The rectangle in the render-target (canvas or texture) into which contents should be rendered | If rendering to the canvas, this is in screen space and the origin is on the top-left. If rendering to a render-texture, this is in its base-texture's space with the origin on the bottom-left. |\n * | viewportFrame | The framebuffer viewport corresponding to the destination-frame | **Window Coordinates**: The origin is always on the bottom-left. |\n *\n * @memberof PIXI\n */\nvar RenderTextureSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this System works for.\n */\n function RenderTextureSystem(renderer) {\n this.renderer = renderer;\n this.clearColor = renderer._backgroundColorRgba;\n this.defaultMaskStack = [];\n this.current = null;\n this.sourceFrame = new Rectangle();\n this.destinationFrame = new Rectangle();\n this.viewportFrame = new Rectangle();\n }\n /**\n * Bind the current render texture.\n *\n * @param renderTexture - RenderTexture to bind, by default its `null` - the screen.\n * @param sourceFrame - Part of world that is mapped to the renderTexture.\n * @param destinationFrame - Part of renderTexture, by default it has the same size as sourceFrame.\n */\n RenderTextureSystem.prototype.bind = function (renderTexture, sourceFrame, destinationFrame) {\n if (renderTexture === void 0) { renderTexture = null; }\n var renderer = this.renderer;\n this.current = renderTexture;\n var baseTexture;\n var framebuffer;\n var resolution;\n if (renderTexture) {\n baseTexture = renderTexture.baseTexture;\n resolution = baseTexture.resolution;\n if (!sourceFrame) {\n tempRect.width = renderTexture.frame.width;\n tempRect.height = renderTexture.frame.height;\n sourceFrame = tempRect;\n }\n if (!destinationFrame) {\n tempRect2.x = renderTexture.frame.x;\n tempRect2.y = renderTexture.frame.y;\n tempRect2.width = sourceFrame.width;\n tempRect2.height = sourceFrame.height;\n destinationFrame = tempRect2;\n }\n framebuffer = baseTexture.framebuffer;\n }\n else {\n resolution = renderer.resolution;\n if (!sourceFrame) {\n tempRect.width = renderer.screen.width;\n tempRect.height = renderer.screen.height;\n sourceFrame = tempRect;\n }\n if (!destinationFrame) {\n destinationFrame = tempRect;\n destinationFrame.width = sourceFrame.width;\n destinationFrame.height = sourceFrame.height;\n }\n }\n var viewportFrame = this.viewportFrame;\n viewportFrame.x = destinationFrame.x * resolution;\n viewportFrame.y = destinationFrame.y * resolution;\n viewportFrame.width = destinationFrame.width * resolution;\n viewportFrame.height = destinationFrame.height * resolution;\n if (!renderTexture) {\n viewportFrame.y = renderer.view.height - (viewportFrame.y + viewportFrame.height);\n }\n viewportFrame.ceil();\n this.renderer.framebuffer.bind(framebuffer, viewportFrame);\n this.renderer.projection.update(destinationFrame, sourceFrame, resolution, !framebuffer);\n if (renderTexture) {\n this.renderer.mask.setMaskStack(baseTexture.maskStack);\n }\n else {\n this.renderer.mask.setMaskStack(this.defaultMaskStack);\n }\n this.sourceFrame.copyFrom(sourceFrame);\n this.destinationFrame.copyFrom(destinationFrame);\n };\n /**\n * Erases the render texture and fills the drawing area with a colour.\n *\n * @param clearColor - The color as rgba, default to use the renderer backgroundColor\n * @param [mask=BUFFER_BITS.COLOR | BUFFER_BITS.DEPTH] - Bitwise OR of masks\n * that indicate the buffers to be cleared, by default COLOR and DEPTH buffers.\n */\n RenderTextureSystem.prototype.clear = function (clearColor, mask) {\n if (this.current) {\n clearColor = clearColor || this.current.baseTexture.clearColor;\n }\n else {\n clearColor = clearColor || this.clearColor;\n }\n var destinationFrame = this.destinationFrame;\n var baseFrame = this.current ? this.current.baseTexture : this.renderer.screen;\n var clearMask = destinationFrame.width !== baseFrame.width || destinationFrame.height !== baseFrame.height;\n if (clearMask) {\n var _a = this.viewportFrame, x = _a.x, y = _a.y, width = _a.width, height = _a.height;\n x = Math.round(x);\n y = Math.round(y);\n width = Math.round(width);\n height = Math.round(height);\n // TODO: ScissorSystem should cache whether the scissor test is enabled or not.\n this.renderer.gl.enable(this.renderer.gl.SCISSOR_TEST);\n this.renderer.gl.scissor(x, y, width, height);\n }\n this.renderer.framebuffer.clear(clearColor[0], clearColor[1], clearColor[2], clearColor[3], mask);\n if (clearMask) {\n // Restore the scissor box\n this.renderer.scissor.pop();\n }\n };\n RenderTextureSystem.prototype.resize = function () {\n // resize the root only!\n this.bind(null);\n };\n /** Resets render-texture state. */\n RenderTextureSystem.prototype.reset = function () {\n this.bind(null);\n };\n RenderTextureSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return RenderTextureSystem;\n}());\n\nfunction uboUpdate(_ud, _uv, _renderer, _syncData, buffer) {\n _renderer.buffer.update(buffer);\n}\n// cv = CachedValue\n// v = value\n// ud = uniformData\n// uv = uniformValue\n// l = location\nvar UBO_TO_SINGLE_SETTERS = {\n float: \"\\n data[offset] = v;\\n \",\n vec2: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n \",\n vec3: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n data[offset+2] = v[2];\\n\\n \",\n vec4: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n data[offset+2] = v[2];\\n data[offset+3] = v[3];\\n \",\n mat2: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n\\n data[offset+4] = v[2];\\n data[offset+5] = v[3];\\n \",\n mat3: \"\\n data[offset] = v[0];\\n data[offset+1] = v[1];\\n data[offset+2] = v[2];\\n\\n data[offset + 4] = v[3];\\n data[offset + 5] = v[4];\\n data[offset + 6] = v[5];\\n\\n data[offset + 8] = v[6];\\n data[offset + 9] = v[7];\\n data[offset + 10] = v[8];\\n \",\n mat4: \"\\n for(var i = 0; i < 16; i++)\\n {\\n data[offset + i] = v[i];\\n }\\n \"\n};\nvar GLSL_TO_STD40_SIZE = {\n float: 4,\n vec2: 8,\n vec3: 12,\n vec4: 16,\n int: 4,\n ivec2: 8,\n ivec3: 12,\n ivec4: 16,\n uint: 4,\n uvec2: 8,\n uvec3: 12,\n uvec4: 16,\n bool: 4,\n bvec2: 8,\n bvec3: 12,\n bvec4: 16,\n mat2: 16 * 2,\n mat3: 16 * 3,\n mat4: 16 * 4,\n};\n/**\n * @ignore\n *\n * logic originally from here: https://github.com/sketchpunk/FunWithWebGL2/blob/master/lesson_022/Shaders.js\n * rewrote it, but this was a great starting point to get a solid understanding of whats going on :)\n *\n * @param uniformData\n */\nfunction createUBOElements(uniformData) {\n var uboElements = uniformData.map(function (data) {\n return ({\n data: data,\n offset: 0,\n dataLen: 0,\n dirty: 0\n });\n });\n var size = 0;\n var chunkSize = 0;\n var offset = 0;\n for (var i = 0; i < uboElements.length; i++) {\n var uboElement = uboElements[i];\n size = GLSL_TO_STD40_SIZE[uboElement.data.type];\n if (uboElement.data.size > 1) {\n size = Math.max(size, 16) * uboElement.data.size;\n }\n uboElement.dataLen = size;\n // add some size offset..\n // must align to the nearest 16 bytes or internally nearest round size\n if (chunkSize % size !== 0 && chunkSize < 16) {\n // diff required to line up..\n var lineUpValue = (chunkSize % size) % 16;\n chunkSize += lineUpValue;\n offset += lineUpValue;\n }\n if ((chunkSize + size) > 16) {\n offset = Math.ceil(offset / 16) * 16;\n uboElement.offset = offset;\n offset += size;\n chunkSize = size;\n }\n else {\n uboElement.offset = offset;\n chunkSize += size;\n offset += size;\n }\n }\n offset = Math.ceil(offset / 16) * 16;\n return { uboElements: uboElements, size: offset };\n}\nfunction getUBOData(uniforms, uniformData) {\n var usedUniformDatas = [];\n // build..\n for (var i in uniforms) {\n if (uniformData[i]) {\n usedUniformDatas.push(uniformData[i]);\n }\n }\n // sort them out by index!\n usedUniformDatas.sort(function (a, b) { return a.index - b.index; });\n return usedUniformDatas;\n}\nfunction generateUniformBufferSync(group, uniformData) {\n if (!group.autoManage) {\n // if the group is nott automatically managed, we don't need to generate a special function for it...\n return { size: 0, syncFunc: uboUpdate };\n }\n var usedUniformDatas = getUBOData(group.uniforms, uniformData);\n var _a = createUBOElements(usedUniformDatas), uboElements = _a.uboElements, size = _a.size;\n var funcFragments = [\"\\n var v = null;\\n var v2 = null;\\n var cv = null;\\n var t = 0;\\n var gl = renderer.gl\\n var index = 0;\\n var data = buffer.data;\\n \"];\n for (var i = 0; i < uboElements.length; i++) {\n var uboElement = uboElements[i];\n var uniform = group.uniforms[uboElement.data.name];\n var name = uboElement.data.name;\n var parsed = false;\n for (var j = 0; j < uniformParsers.length; j++) {\n var uniformParser = uniformParsers[j];\n if (uniformParser.codeUbo && uniformParser.test(uboElement.data, uniform)) {\n funcFragments.push(\"offset = \" + uboElement.offset / 4 + \";\", uniformParsers[j].codeUbo(uboElement.data.name, uniform));\n parsed = true;\n break;\n }\n }\n if (!parsed) {\n if (uboElement.data.size > 1) {\n var size_1 = mapSize(uboElement.data.type);\n var rowSize = Math.max(GLSL_TO_STD40_SIZE[uboElement.data.type] / 16, 1);\n var elementSize = size_1 / rowSize;\n var remainder = (4 - (elementSize % 4)) % 4;\n funcFragments.push(\"\\n cv = ud.\" + name + \".value;\\n v = uv.\" + name + \";\\n offset = \" + uboElement.offset / 4 + \";\\n\\n t = 0;\\n\\n for(var i=0; i < \" + uboElement.data.size * rowSize + \"; i++)\\n {\\n for(var j = 0; j < \" + elementSize + \"; j++)\\n {\\n data[offset++] = v[t++];\\n }\\n offset += \" + remainder + \";\\n }\\n\\n \");\n }\n else {\n var template = UBO_TO_SINGLE_SETTERS[uboElement.data.type];\n funcFragments.push(\"\\n cv = ud.\" + name + \".value;\\n v = uv.\" + name + \";\\n offset = \" + uboElement.offset / 4 + \";\\n \" + template + \";\\n \");\n }\n }\n }\n funcFragments.push(\"\\n renderer.buffer.update(buffer);\\n \");\n return {\n size: size,\n // eslint-disable-next-line no-new-func\n syncFunc: new Function('ud', 'uv', 'renderer', 'syncData', 'buffer', funcFragments.join('\\n'))\n };\n}\n\n/**\n * @private\n */\nvar IGLUniformData = /** @class */ (function () {\n function IGLUniformData() {\n }\n return IGLUniformData;\n}());\n/**\n * Helper class to create a WebGL Program\n *\n * @memberof PIXI\n */\nvar GLProgram = /** @class */ (function () {\n /**\n * Makes a new Pixi program.\n *\n * @param program - webgl program\n * @param uniformData - uniforms\n */\n function GLProgram(program, uniformData) {\n this.program = program;\n this.uniformData = uniformData;\n this.uniformGroups = {};\n this.uniformDirtyGroups = {};\n this.uniformBufferBindings = {};\n }\n /** Destroys this program. */\n GLProgram.prototype.destroy = function () {\n this.uniformData = null;\n this.uniformGroups = null;\n this.uniformDirtyGroups = null;\n this.uniformBufferBindings = null;\n this.program = null;\n };\n return GLProgram;\n}());\n\n/**\n * returns the attribute data from the program\n * @private\n *\n * @param {WebGLProgram} [program] - the WebGL program\n * @param {WebGLRenderingContext} [gl] - the WebGL context\n *\n * @returns {object} the attribute data for this program\n */\nfunction getAttributeData(program, gl) {\n var attributes = {};\n var totalAttributes = gl.getProgramParameter(program, gl.ACTIVE_ATTRIBUTES);\n for (var i = 0; i < totalAttributes; i++) {\n var attribData = gl.getActiveAttrib(program, i);\n if (attribData.name.indexOf('gl_') === 0) {\n continue;\n }\n var type = mapType(gl, attribData.type);\n var data = {\n type: type,\n name: attribData.name,\n size: mapSize(type),\n location: gl.getAttribLocation(program, attribData.name),\n };\n attributes[attribData.name] = data;\n }\n return attributes;\n}\n\n/**\n * returns the uniform data from the program\n * @private\n *\n * @param program - the webgl program\n * @param gl - the WebGL context\n *\n * @returns {object} the uniform data for this program\n */\nfunction getUniformData(program, gl) {\n var uniforms = {};\n var totalUniforms = gl.getProgramParameter(program, gl.ACTIVE_UNIFORMS);\n for (var i = 0; i < totalUniforms; i++) {\n var uniformData = gl.getActiveUniform(program, i);\n var name = uniformData.name.replace(/\\[.*?\\]$/, '');\n var isArray = !!(uniformData.name.match(/\\[.*?\\]$/));\n var type = mapType(gl, uniformData.type);\n uniforms[name] = {\n name: name,\n index: i,\n type: type,\n size: uniformData.size,\n isArray: isArray,\n value: defaultValue(type, uniformData.size),\n };\n }\n return uniforms;\n}\n\n/**\n * generates a WebGL Program object from a high level Pixi Program.\n *\n * @param gl - a rendering context on which to generate the program\n * @param program - the high level Pixi Program.\n */\nfunction generateProgram(gl, program) {\n var glVertShader = compileShader(gl, gl.VERTEX_SHADER, program.vertexSrc);\n var glFragShader = compileShader(gl, gl.FRAGMENT_SHADER, program.fragmentSrc);\n var webGLProgram = gl.createProgram();\n gl.attachShader(webGLProgram, glVertShader);\n gl.attachShader(webGLProgram, glFragShader);\n gl.linkProgram(webGLProgram);\n if (!gl.getProgramParameter(webGLProgram, gl.LINK_STATUS)) {\n logProgramError(gl, webGLProgram, glVertShader, glFragShader);\n }\n program.attributeData = getAttributeData(webGLProgram, gl);\n program.uniformData = getUniformData(webGLProgram, gl);\n // GLSL 1.00: bind attributes sorted by name in ascending order\n // GLSL 3.00: don't change the attribute locations that where chosen by the compiler\n // or assigned by the layout specifier in the shader source code\n if (!(/^[ \\t]*#[ \\t]*version[ \\t]+300[ \\t]+es[ \\t]*$/m).test(program.vertexSrc)) {\n var keys = Object.keys(program.attributeData);\n keys.sort(function (a, b) { return (a > b) ? 1 : -1; }); // eslint-disable-line no-confusing-arrow\n for (var i = 0; i < keys.length; i++) {\n program.attributeData[keys[i]].location = i;\n gl.bindAttribLocation(webGLProgram, i, keys[i]);\n }\n gl.linkProgram(webGLProgram);\n }\n gl.deleteShader(glVertShader);\n gl.deleteShader(glFragShader);\n var uniformData = {};\n for (var i in program.uniformData) {\n var data = program.uniformData[i];\n uniformData[i] = {\n location: gl.getUniformLocation(webGLProgram, i),\n value: defaultValue(data.type, data.size),\n };\n }\n var glProgram = new GLProgram(webGLProgram, uniformData);\n return glProgram;\n}\n\nvar UID$4 = 0;\n// default sync data so we don't create a new one each time!\nvar defaultSyncData = { textureCount: 0, uboCount: 0 };\n/**\n * System plugin to the renderer to manage shaders.\n *\n * @memberof PIXI\n */\nvar ShaderSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function ShaderSystem(renderer) {\n this.destroyed = false;\n this.renderer = renderer;\n // Validation check that this environment support `new Function`\n this.systemCheck();\n this.gl = null;\n this.shader = null;\n this.program = null;\n this.cache = {};\n this._uboCache = {};\n this.id = UID$4++;\n }\n /**\n * Overrideable function by `@pixi/unsafe-eval` to silence\n * throwing an error if platform doesn't support unsafe-evals.\n *\n * @private\n */\n ShaderSystem.prototype.systemCheck = function () {\n if (!unsafeEvalSupported()) {\n throw new Error('Current environment does not allow unsafe-eval, '\n + 'please use @pixi/unsafe-eval module to enable support.');\n }\n };\n ShaderSystem.prototype.contextChange = function (gl) {\n this.gl = gl;\n this.reset();\n };\n /**\n * Changes the current shader to the one given in parameter.\n *\n * @param shader - the new shader\n * @param dontSync - false if the shader should automatically sync its uniforms.\n * @returns the glProgram that belongs to the shader.\n */\n ShaderSystem.prototype.bind = function (shader, dontSync) {\n shader.uniforms.globals = this.renderer.globalUniforms;\n var program = shader.program;\n var glProgram = program.glPrograms[this.renderer.CONTEXT_UID] || this.generateProgram(shader);\n this.shader = shader;\n // TODO - some current Pixi plugins bypass this.. so it not safe to use yet..\n if (this.program !== program) {\n this.program = program;\n this.gl.useProgram(glProgram.program);\n }\n if (!dontSync) {\n defaultSyncData.textureCount = 0;\n defaultSyncData.uboCount = 0;\n this.syncUniformGroup(shader.uniformGroup, defaultSyncData);\n }\n return glProgram;\n };\n /**\n * Uploads the uniforms values to the currently bound shader.\n *\n * @param uniforms - the uniforms values that be applied to the current shader\n */\n ShaderSystem.prototype.setUniforms = function (uniforms) {\n var shader = this.shader.program;\n var glProgram = shader.glPrograms[this.renderer.CONTEXT_UID];\n shader.syncUniforms(glProgram.uniformData, uniforms, this.renderer);\n };\n /* eslint-disable @typescript-eslint/explicit-module-boundary-types */\n /**\n * Syncs uniforms on the group\n *\n * @param group - the uniform group to sync\n * @param syncData - this is data that is passed to the sync function and any nested sync functions\n */\n ShaderSystem.prototype.syncUniformGroup = function (group, syncData) {\n var glProgram = this.getGlProgram();\n if (!group.static || group.dirtyId !== glProgram.uniformDirtyGroups[group.id]) {\n glProgram.uniformDirtyGroups[group.id] = group.dirtyId;\n this.syncUniforms(group, glProgram, syncData);\n }\n };\n /**\n * Overrideable by the @pixi/unsafe-eval package to use static syncUniforms instead.\n */\n ShaderSystem.prototype.syncUniforms = function (group, glProgram, syncData) {\n var syncFunc = group.syncUniforms[this.shader.program.id] || this.createSyncGroups(group);\n syncFunc(glProgram.uniformData, group.uniforms, this.renderer, syncData);\n };\n ShaderSystem.prototype.createSyncGroups = function (group) {\n var id = this.getSignature(group, this.shader.program.uniformData, 'u');\n if (!this.cache[id]) {\n this.cache[id] = generateUniformsSync(group, this.shader.program.uniformData);\n }\n group.syncUniforms[this.shader.program.id] = this.cache[id];\n return group.syncUniforms[this.shader.program.id];\n };\n /**\n * Syncs uniform buffers\n *\n * @param group - the uniform buffer group to sync\n * @param name - the name of the uniform buffer\n */\n ShaderSystem.prototype.syncUniformBufferGroup = function (group, name) {\n var glProgram = this.getGlProgram();\n if (!group.static || group.dirtyId !== 0 || !glProgram.uniformGroups[group.id]) {\n group.dirtyId = 0;\n var syncFunc = glProgram.uniformGroups[group.id]\n || this.createSyncBufferGroup(group, glProgram, name);\n // TODO wrap update in a cache??\n group.buffer.update();\n syncFunc(glProgram.uniformData, group.uniforms, this.renderer, defaultSyncData, group.buffer);\n }\n this.renderer.buffer.bindBufferBase(group.buffer, glProgram.uniformBufferBindings[name]);\n };\n /**\n * Will create a function that uploads a uniform buffer using the STD140 standard.\n * The upload function will then be cached for future calls\n * If a group is manually managed, then a simple upload function is generated\n *\n * @param group - the uniform buffer group to sync\n * @param glProgram - the gl program to attach the uniform bindings to\n * @param name - the name of the uniform buffer (must exist on the shader)\n */\n ShaderSystem.prototype.createSyncBufferGroup = function (group, glProgram, name) {\n var gl = this.renderer.gl;\n this.renderer.buffer.bind(group.buffer);\n // bind them...\n var uniformBlockIndex = this.gl.getUniformBlockIndex(glProgram.program, name);\n glProgram.uniformBufferBindings[name] = this.shader.uniformBindCount;\n gl.uniformBlockBinding(glProgram.program, uniformBlockIndex, this.shader.uniformBindCount);\n this.shader.uniformBindCount++;\n var id = this.getSignature(group, this.shader.program.uniformData, 'ubo');\n var uboData = this._uboCache[id];\n if (!uboData) {\n uboData = this._uboCache[id] = generateUniformBufferSync(group, this.shader.program.uniformData);\n }\n if (group.autoManage) {\n var data = new Float32Array(uboData.size / 4);\n group.buffer.update(data);\n }\n glProgram.uniformGroups[group.id] = uboData.syncFunc;\n return glProgram.uniformGroups[group.id];\n };\n /**\n * Takes a uniform group and data and generates a unique signature for them.\n *\n * @param group - The uniform group to get signature of\n * @param uniformData - Uniform information generated by the shader\n * @returns Unique signature of the uniform group\n */\n ShaderSystem.prototype.getSignature = function (group, uniformData, preFix) {\n var uniforms = group.uniforms;\n var strings = [preFix + \"-\"];\n for (var i in uniforms) {\n strings.push(i);\n if (uniformData[i]) {\n strings.push(uniformData[i].type);\n }\n }\n return strings.join('-');\n };\n /**\n * Returns the underlying GLShade rof the currently bound shader.\n *\n * This can be handy for when you to have a little more control over the setting of your uniforms.\n *\n * @return The glProgram for the currently bound Shader for this context\n */\n ShaderSystem.prototype.getGlProgram = function () {\n if (this.shader) {\n return this.shader.program.glPrograms[this.renderer.CONTEXT_UID];\n }\n return null;\n };\n /**\n * Generates a glProgram version of the Shader provided.\n *\n * @param shader - The shader that the glProgram will be based on.\n * @return A shiny new glProgram!\n */\n ShaderSystem.prototype.generateProgram = function (shader) {\n var gl = this.gl;\n var program = shader.program;\n var glProgram = generateProgram(gl, program);\n program.glPrograms[this.renderer.CONTEXT_UID] = glProgram;\n return glProgram;\n };\n /** Resets ShaderSystem state, does not affect WebGL state. */\n ShaderSystem.prototype.reset = function () {\n this.program = null;\n this.shader = null;\n };\n /** Destroys this System and removes all its textures. */\n ShaderSystem.prototype.destroy = function () {\n this.renderer = null;\n // TODO implement destroy method for ShaderSystem\n this.destroyed = true;\n };\n return ShaderSystem;\n}());\n\n/**\n * Maps gl blend combinations to WebGL.\n *\n * @memberof PIXI\n * @function mapWebGLBlendModesToPixi\n * @private\n * @param {WebGLRenderingContext} gl - The rendering context.\n * @param {number[][]} [array=[]] - The array to output into.\n * @return {number[][]} Mapped modes.\n */\nfunction mapWebGLBlendModesToPixi(gl, array) {\n if (array === void 0) { array = []; }\n // TODO - premultiply alpha would be different.\n // add a boolean for that!\n array[BLEND_MODES.NORMAL] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.ADD] = [gl.ONE, gl.ONE];\n array[BLEND_MODES.MULTIPLY] = [gl.DST_COLOR, gl.ONE_MINUS_SRC_ALPHA, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.SCREEN] = [gl.ONE, gl.ONE_MINUS_SRC_COLOR, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.OVERLAY] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DARKEN] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.LIGHTEN] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.COLOR_DODGE] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.COLOR_BURN] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.HARD_LIGHT] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.SOFT_LIGHT] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DIFFERENCE] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.EXCLUSION] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.HUE] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.SATURATION] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.COLOR] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.LUMINOSITY] = [gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.NONE] = [0, 0];\n // not-premultiplied blend modes\n array[BLEND_MODES.NORMAL_NPM] = [gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.ADD_NPM] = [gl.SRC_ALPHA, gl.ONE, gl.ONE, gl.ONE];\n array[BLEND_MODES.SCREEN_NPM] = [gl.SRC_ALPHA, gl.ONE_MINUS_SRC_COLOR, gl.ONE, gl.ONE_MINUS_SRC_ALPHA];\n // composite operations\n array[BLEND_MODES.SRC_IN] = [gl.DST_ALPHA, gl.ZERO];\n array[BLEND_MODES.SRC_OUT] = [gl.ONE_MINUS_DST_ALPHA, gl.ZERO];\n array[BLEND_MODES.SRC_ATOP] = [gl.DST_ALPHA, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DST_OVER] = [gl.ONE_MINUS_DST_ALPHA, gl.ONE];\n array[BLEND_MODES.DST_IN] = [gl.ZERO, gl.SRC_ALPHA];\n array[BLEND_MODES.DST_OUT] = [gl.ZERO, gl.ONE_MINUS_SRC_ALPHA];\n array[BLEND_MODES.DST_ATOP] = [gl.ONE_MINUS_DST_ALPHA, gl.SRC_ALPHA];\n array[BLEND_MODES.XOR] = [gl.ONE_MINUS_DST_ALPHA, gl.ONE_MINUS_SRC_ALPHA];\n // SUBTRACT from flash\n array[BLEND_MODES.SUBTRACT] = [gl.ONE, gl.ONE, gl.ONE, gl.ONE, gl.FUNC_REVERSE_SUBTRACT, gl.FUNC_ADD];\n return array;\n}\n\nvar BLEND$1 = 0;\nvar OFFSET$1 = 1;\nvar CULLING$1 = 2;\nvar DEPTH_TEST$1 = 3;\nvar WINDING$1 = 4;\nvar DEPTH_MASK$1 = 5;\n/**\n * System plugin to the renderer to manage WebGL state machines.\n *\n * @memberof PIXI\n */\nvar StateSystem = /** @class */ (function () {\n function StateSystem() {\n this.gl = null;\n this.stateId = 0;\n this.polygonOffset = 0;\n this.blendMode = BLEND_MODES.NONE;\n this._blendEq = false;\n // map functions for when we set state..\n this.map = [];\n this.map[BLEND$1] = this.setBlend;\n this.map[OFFSET$1] = this.setOffset;\n this.map[CULLING$1] = this.setCullFace;\n this.map[DEPTH_TEST$1] = this.setDepthTest;\n this.map[WINDING$1] = this.setFrontFace;\n this.map[DEPTH_MASK$1] = this.setDepthMask;\n this.checks = [];\n this.defaultState = new State();\n this.defaultState.blend = true;\n }\n StateSystem.prototype.contextChange = function (gl) {\n this.gl = gl;\n this.blendModes = mapWebGLBlendModesToPixi(gl);\n this.set(this.defaultState);\n this.reset();\n };\n /**\n * Sets the current state\n *\n * @param {*} state - The state to set.\n */\n StateSystem.prototype.set = function (state) {\n state = state || this.defaultState;\n // TODO maybe to an object check? ( this.state === state )?\n if (this.stateId !== state.data) {\n var diff = this.stateId ^ state.data;\n var i = 0;\n // order from least to most common\n while (diff) {\n if (diff & 1) {\n // state change!\n this.map[i].call(this, !!(state.data & (1 << i)));\n }\n diff = diff >> 1;\n i++;\n }\n this.stateId = state.data;\n }\n // based on the above settings we check for specific modes..\n // for example if blend is active we check and set the blend modes\n // or of polygon offset is active we check the poly depth.\n for (var i = 0; i < this.checks.length; i++) {\n this.checks[i](this, state);\n }\n };\n /**\n * Sets the state, when previous state is unknown.\n *\n * @param {*} state - The state to set\n */\n StateSystem.prototype.forceState = function (state) {\n state = state || this.defaultState;\n for (var i = 0; i < this.map.length; i++) {\n this.map[i].call(this, !!(state.data & (1 << i)));\n }\n for (var i = 0; i < this.checks.length; i++) {\n this.checks[i](this, state);\n }\n this.stateId = state.data;\n };\n /**\n * Sets whether to enable or disable blending.\n *\n * @param value - Turn on or off WebGl blending.\n */\n StateSystem.prototype.setBlend = function (value) {\n this.updateCheck(StateSystem.checkBlendMode, value);\n this.gl[value ? 'enable' : 'disable'](this.gl.BLEND);\n };\n /**\n * Sets whether to enable or disable polygon offset fill.\n *\n * @param value - Turn on or off webgl polygon offset testing.\n */\n StateSystem.prototype.setOffset = function (value) {\n this.updateCheck(StateSystem.checkPolygonOffset, value);\n this.gl[value ? 'enable' : 'disable'](this.gl.POLYGON_OFFSET_FILL);\n };\n /**\n * Sets whether to enable or disable depth test.\n *\n * @param value - Turn on or off webgl depth testing.\n */\n StateSystem.prototype.setDepthTest = function (value) {\n this.gl[value ? 'enable' : 'disable'](this.gl.DEPTH_TEST);\n };\n /**\n * Sets whether to enable or disable depth mask.\n *\n * @param value - Turn on or off webgl depth mask.\n */\n StateSystem.prototype.setDepthMask = function (value) {\n this.gl.depthMask(value);\n };\n /**\n * Sets whether to enable or disable cull face.\n *\n * @param {boolean} value - Turn on or off webgl cull face.\n */\n StateSystem.prototype.setCullFace = function (value) {\n this.gl[value ? 'enable' : 'disable'](this.gl.CULL_FACE);\n };\n /**\n * Sets the gl front face.\n *\n * @param {boolean} value - true is clockwise and false is counter-clockwise\n */\n StateSystem.prototype.setFrontFace = function (value) {\n this.gl.frontFace(this.gl[value ? 'CW' : 'CCW']);\n };\n /**\n * Sets the blend mode.\n *\n * @param {number} value - The blend mode to set to.\n */\n StateSystem.prototype.setBlendMode = function (value) {\n if (value === this.blendMode) {\n return;\n }\n this.blendMode = value;\n var mode = this.blendModes[value];\n var gl = this.gl;\n if (mode.length === 2) {\n gl.blendFunc(mode[0], mode[1]);\n }\n else {\n gl.blendFuncSeparate(mode[0], mode[1], mode[2], mode[3]);\n }\n if (mode.length === 6) {\n this._blendEq = true;\n gl.blendEquationSeparate(mode[4], mode[5]);\n }\n else if (this._blendEq) {\n this._blendEq = false;\n gl.blendEquationSeparate(gl.FUNC_ADD, gl.FUNC_ADD);\n }\n };\n /**\n * Sets the polygon offset.\n *\n * @param {number} value - the polygon offset\n * @param {number} scale - the polygon offset scale\n */\n StateSystem.prototype.setPolygonOffset = function (value, scale) {\n this.gl.polygonOffset(value, scale);\n };\n // used\n /** Resets all the logic and disables the VAOs. */\n StateSystem.prototype.reset = function () {\n this.gl.pixelStorei(this.gl.UNPACK_FLIP_Y_WEBGL, false);\n this.forceState(this.defaultState);\n this._blendEq = true;\n this.blendMode = -1;\n this.setBlendMode(0);\n };\n /**\n * Checks to see which updates should be checked based on which settings have been activated.\n *\n * For example, if blend is enabled then we should check the blend modes each time the state is changed\n * or if polygon fill is activated then we need to check if the polygon offset changes.\n * The idea is that we only check what we have too.\n *\n * @param func - the checking function to add or remove\n * @param value - should the check function be added or removed.\n */\n StateSystem.prototype.updateCheck = function (func, value) {\n var index = this.checks.indexOf(func);\n if (value && index === -1) {\n this.checks.push(func);\n }\n else if (!value && index !== -1) {\n this.checks.splice(index, 1);\n }\n };\n /**\n * A private little wrapper function that we call to check the blend mode.\n *\n * @param System - the System to perform the state check on\n * @param state - the state that the blendMode will pulled from\n */\n StateSystem.checkBlendMode = function (system, state) {\n system.setBlendMode(state.blendMode);\n };\n /**\n * A private little wrapper function that we call to check the polygon offset.\n *\n * @param System - the System to perform the state check on\n * @param state - the state that the blendMode will pulled from\n */\n StateSystem.checkPolygonOffset = function (system, state) {\n system.setPolygonOffset(1, state.polygonOffset);\n };\n /**\n * @ignore\n */\n StateSystem.prototype.destroy = function () {\n this.gl = null;\n };\n return StateSystem;\n}());\n\n/**\n * System plugin to the renderer to manage texture garbage collection on the GPU,\n * ensuring that it does not get clogged up with textures that are no longer being used.\n *\n * @memberof PIXI\n */\nvar TextureGCSystem = /** @class */ (function () {\n /** @param renderer - The renderer this System works for. */\n function TextureGCSystem(renderer) {\n this.renderer = renderer;\n this.count = 0;\n this.checkCount = 0;\n this.maxIdle = settings.GC_MAX_IDLE;\n this.checkCountMax = settings.GC_MAX_CHECK_COUNT;\n this.mode = settings.GC_MODE;\n }\n /**\n * Checks to see when the last time a texture was used\n * if the texture has not been used for a specified amount of time it will be removed from the GPU\n */\n TextureGCSystem.prototype.postrender = function () {\n if (!this.renderer.renderingToScreen) {\n return;\n }\n this.count++;\n if (this.mode === GC_MODES.MANUAL) {\n return;\n }\n this.checkCount++;\n if (this.checkCount > this.checkCountMax) {\n this.checkCount = 0;\n this.run();\n }\n };\n /**\n * Checks to see when the last time a texture was used\n * if the texture has not been used for a specified amount of time it will be removed from the GPU\n */\n TextureGCSystem.prototype.run = function () {\n var tm = this.renderer.texture;\n var managedTextures = tm.managedTextures;\n var wasRemoved = false;\n for (var i = 0; i < managedTextures.length; i++) {\n var texture = managedTextures[i];\n // only supports non generated textures at the moment!\n if (!texture.framebuffer && this.count - texture.touched > this.maxIdle) {\n tm.destroyTexture(texture, true);\n managedTextures[i] = null;\n wasRemoved = true;\n }\n }\n if (wasRemoved) {\n var j = 0;\n for (var i = 0; i < managedTextures.length; i++) {\n if (managedTextures[i] !== null) {\n managedTextures[j++] = managedTextures[i];\n }\n }\n managedTextures.length = j;\n }\n };\n /**\n * Removes all the textures within the specified displayObject and its children from the GPU\n *\n * @param {PIXI.DisplayObject} displayObject - the displayObject to remove the textures from.\n */\n TextureGCSystem.prototype.unload = function (displayObject) {\n var tm = this.renderer.texture;\n var texture = displayObject._texture;\n // only destroy non generated textures\n if (texture && !texture.framebuffer) {\n tm.destroyTexture(texture);\n }\n for (var i = displayObject.children.length - 1; i >= 0; i--) {\n this.unload(displayObject.children[i]);\n }\n };\n TextureGCSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return TextureGCSystem;\n}());\n\n/**\n * Returns a lookup table that maps each type-format pair to a compatible internal format.\n *\n * @memberof PIXI\n * @function mapTypeAndFormatToInternalFormat\n * @private\n * @param {WebGLRenderingContext} gl - The rendering context.\n * @return {{ [type: number]: { [format: number]: number } }} Lookup table.\n */\nfunction mapTypeAndFormatToInternalFormat(gl) {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x;\n var table;\n if ('WebGL2RenderingContext' in globalThis && gl instanceof globalThis.WebGL2RenderingContext) {\n table = (_a = {},\n _a[TYPES.UNSIGNED_BYTE] = (_b = {},\n _b[FORMATS.RGBA] = gl.RGBA8,\n _b[FORMATS.RGB] = gl.RGB8,\n _b[FORMATS.RG] = gl.RG8,\n _b[FORMATS.RED] = gl.R8,\n _b[FORMATS.RGBA_INTEGER] = gl.RGBA8UI,\n _b[FORMATS.RGB_INTEGER] = gl.RGB8UI,\n _b[FORMATS.RG_INTEGER] = gl.RG8UI,\n _b[FORMATS.RED_INTEGER] = gl.R8UI,\n _b[FORMATS.ALPHA] = gl.ALPHA,\n _b[FORMATS.LUMINANCE] = gl.LUMINANCE,\n _b[FORMATS.LUMINANCE_ALPHA] = gl.LUMINANCE_ALPHA,\n _b),\n _a[TYPES.BYTE] = (_c = {},\n _c[FORMATS.RGBA] = gl.RGBA8_SNORM,\n _c[FORMATS.RGB] = gl.RGB8_SNORM,\n _c[FORMATS.RG] = gl.RG8_SNORM,\n _c[FORMATS.RED] = gl.R8_SNORM,\n _c[FORMATS.RGBA_INTEGER] = gl.RGBA8I,\n _c[FORMATS.RGB_INTEGER] = gl.RGB8I,\n _c[FORMATS.RG_INTEGER] = gl.RG8I,\n _c[FORMATS.RED_INTEGER] = gl.R8I,\n _c),\n _a[TYPES.UNSIGNED_SHORT] = (_d = {},\n _d[FORMATS.RGBA_INTEGER] = gl.RGBA16UI,\n _d[FORMATS.RGB_INTEGER] = gl.RGB16UI,\n _d[FORMATS.RG_INTEGER] = gl.RG16UI,\n _d[FORMATS.RED_INTEGER] = gl.R16UI,\n _d[FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT16,\n _d),\n _a[TYPES.SHORT] = (_e = {},\n _e[FORMATS.RGBA_INTEGER] = gl.RGBA16I,\n _e[FORMATS.RGB_INTEGER] = gl.RGB16I,\n _e[FORMATS.RG_INTEGER] = gl.RG16I,\n _e[FORMATS.RED_INTEGER] = gl.R16I,\n _e),\n _a[TYPES.UNSIGNED_INT] = (_f = {},\n _f[FORMATS.RGBA_INTEGER] = gl.RGBA32UI,\n _f[FORMATS.RGB_INTEGER] = gl.RGB32UI,\n _f[FORMATS.RG_INTEGER] = gl.RG32UI,\n _f[FORMATS.RED_INTEGER] = gl.R32UI,\n _f[FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT24,\n _f),\n _a[TYPES.INT] = (_g = {},\n _g[FORMATS.RGBA_INTEGER] = gl.RGBA32I,\n _g[FORMATS.RGB_INTEGER] = gl.RGB32I,\n _g[FORMATS.RG_INTEGER] = gl.RG32I,\n _g[FORMATS.RED_INTEGER] = gl.R32I,\n _g),\n _a[TYPES.FLOAT] = (_h = {},\n _h[FORMATS.RGBA] = gl.RGBA32F,\n _h[FORMATS.RGB] = gl.RGB32F,\n _h[FORMATS.RG] = gl.RG32F,\n _h[FORMATS.RED] = gl.R32F,\n _h[FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT32F,\n _h),\n _a[TYPES.HALF_FLOAT] = (_j = {},\n _j[FORMATS.RGBA] = gl.RGBA16F,\n _j[FORMATS.RGB] = gl.RGB16F,\n _j[FORMATS.RG] = gl.RG16F,\n _j[FORMATS.RED] = gl.R16F,\n _j),\n _a[TYPES.UNSIGNED_SHORT_5_6_5] = (_k = {},\n _k[FORMATS.RGB] = gl.RGB565,\n _k),\n _a[TYPES.UNSIGNED_SHORT_4_4_4_4] = (_l = {},\n _l[FORMATS.RGBA] = gl.RGBA4,\n _l),\n _a[TYPES.UNSIGNED_SHORT_5_5_5_1] = (_m = {},\n _m[FORMATS.RGBA] = gl.RGB5_A1,\n _m),\n _a[TYPES.UNSIGNED_INT_2_10_10_10_REV] = (_o = {},\n _o[FORMATS.RGBA] = gl.RGB10_A2,\n _o[FORMATS.RGBA_INTEGER] = gl.RGB10_A2UI,\n _o),\n _a[TYPES.UNSIGNED_INT_10F_11F_11F_REV] = (_p = {},\n _p[FORMATS.RGB] = gl.R11F_G11F_B10F,\n _p),\n _a[TYPES.UNSIGNED_INT_5_9_9_9_REV] = (_q = {},\n _q[FORMATS.RGB] = gl.RGB9_E5,\n _q),\n _a[TYPES.UNSIGNED_INT_24_8] = (_r = {},\n _r[FORMATS.DEPTH_STENCIL] = gl.DEPTH24_STENCIL8,\n _r),\n _a[TYPES.FLOAT_32_UNSIGNED_INT_24_8_REV] = (_s = {},\n _s[FORMATS.DEPTH_STENCIL] = gl.DEPTH32F_STENCIL8,\n _s),\n _a);\n }\n else {\n table = (_t = {},\n _t[TYPES.UNSIGNED_BYTE] = (_u = {},\n _u[FORMATS.RGBA] = gl.RGBA,\n _u[FORMATS.RGB] = gl.RGB,\n _u[FORMATS.ALPHA] = gl.ALPHA,\n _u[FORMATS.LUMINANCE] = gl.LUMINANCE,\n _u[FORMATS.LUMINANCE_ALPHA] = gl.LUMINANCE_ALPHA,\n _u),\n _t[TYPES.UNSIGNED_SHORT_5_6_5] = (_v = {},\n _v[FORMATS.RGB] = gl.RGB,\n _v),\n _t[TYPES.UNSIGNED_SHORT_4_4_4_4] = (_w = {},\n _w[FORMATS.RGBA] = gl.RGBA,\n _w),\n _t[TYPES.UNSIGNED_SHORT_5_5_5_1] = (_x = {},\n _x[FORMATS.RGBA] = gl.RGBA,\n _x),\n _t);\n }\n return table;\n}\n\n/**\n * Internal texture for WebGL context.\n *\n * @memberof PIXI\n */\nvar GLTexture = /** @class */ (function () {\n function GLTexture(texture) {\n this.texture = texture;\n this.width = -1;\n this.height = -1;\n this.dirtyId = -1;\n this.dirtyStyleId = -1;\n this.mipmap = false;\n this.wrapMode = 33071;\n this.type = TYPES.UNSIGNED_BYTE;\n this.internalFormat = FORMATS.RGBA;\n this.samplerType = 0;\n }\n return GLTexture;\n}());\n\n/**\n * System plugin to the renderer to manage textures.\n *\n * @memberof PIXI\n */\nvar TextureSystem = /** @class */ (function () {\n /**\n * @param renderer - The renderer this system works for.\n */\n function TextureSystem(renderer) {\n this.renderer = renderer;\n // TODO set to max textures...\n this.boundTextures = [];\n this.currentLocation = -1;\n this.managedTextures = [];\n this._unknownBoundTextures = false;\n this.unknownTexture = new BaseTexture();\n this.hasIntegerTextures = false;\n }\n /** Sets up the renderer context and necessary buffers. */\n TextureSystem.prototype.contextChange = function () {\n var gl = this.gl = this.renderer.gl;\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n this.webGLVersion = this.renderer.context.webGLVersion;\n this.internalFormats = mapTypeAndFormatToInternalFormat(gl);\n var maxTextures = gl.getParameter(gl.MAX_TEXTURE_IMAGE_UNITS);\n this.boundTextures.length = maxTextures;\n for (var i = 0; i < maxTextures; i++) {\n this.boundTextures[i] = null;\n }\n // TODO move this.. to a nice make empty textures class..\n this.emptyTextures = {};\n var emptyTexture2D = new GLTexture(gl.createTexture());\n gl.bindTexture(gl.TEXTURE_2D, emptyTexture2D.texture);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, new Uint8Array(4));\n this.emptyTextures[gl.TEXTURE_2D] = emptyTexture2D;\n this.emptyTextures[gl.TEXTURE_CUBE_MAP] = new GLTexture(gl.createTexture());\n gl.bindTexture(gl.TEXTURE_CUBE_MAP, this.emptyTextures[gl.TEXTURE_CUBE_MAP].texture);\n for (var i = 0; i < 6; i++) {\n gl.texImage2D(gl.TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);\n }\n gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MAG_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n for (var i = 0; i < this.boundTextures.length; i++) {\n this.bind(null, i);\n }\n };\n /**\n * Bind a texture to a specific location\n *\n * If you want to unbind something, please use `unbind(texture)` instead of `bind(null, textureLocation)`\n *\n * @param texture_ - Texture to bind\n * @param [location=0] - Location to bind at\n */\n TextureSystem.prototype.bind = function (texture, location) {\n if (location === void 0) { location = 0; }\n var gl = this.gl;\n texture = texture === null || texture === void 0 ? void 0 : texture.castToBaseTexture();\n // cannot bind partial texture\n // TODO: report a warning\n if (texture && texture.valid && !texture.parentTextureArray) {\n texture.touched = this.renderer.textureGC.count;\n var glTexture = texture._glTextures[this.CONTEXT_UID] || this.initTexture(texture);\n if (this.boundTextures[location] !== texture) {\n if (this.currentLocation !== location) {\n this.currentLocation = location;\n gl.activeTexture(gl.TEXTURE0 + location);\n }\n gl.bindTexture(texture.target, glTexture.texture);\n }\n if (glTexture.dirtyId !== texture.dirtyId) {\n if (this.currentLocation !== location) {\n this.currentLocation = location;\n gl.activeTexture(gl.TEXTURE0 + location);\n }\n this.updateTexture(texture);\n }\n this.boundTextures[location] = texture;\n }\n else {\n if (this.currentLocation !== location) {\n this.currentLocation = location;\n gl.activeTexture(gl.TEXTURE0 + location);\n }\n gl.bindTexture(gl.TEXTURE_2D, this.emptyTextures[gl.TEXTURE_2D].texture);\n this.boundTextures[location] = null;\n }\n };\n /**\n * Resets texture location and bound textures\n *\n * Actual `bind(null, i)` calls will be performed at next `unbind()` call\n */\n TextureSystem.prototype.reset = function () {\n this._unknownBoundTextures = true;\n this.hasIntegerTextures = false;\n this.currentLocation = -1;\n for (var i = 0; i < this.boundTextures.length; i++) {\n this.boundTextures[i] = this.unknownTexture;\n }\n };\n /**\n * Unbind a texture.\n *\n * @param texture - Texture to bind\n */\n TextureSystem.prototype.unbind = function (texture) {\n var _a = this, gl = _a.gl, boundTextures = _a.boundTextures;\n if (this._unknownBoundTextures) {\n this._unknownBoundTextures = false;\n // someone changed webGL state,\n // we have to be sure that our texture does not appear in multi-texture renderer samplers\n for (var i = 0; i < boundTextures.length; i++) {\n if (boundTextures[i] === this.unknownTexture) {\n this.bind(null, i);\n }\n }\n }\n for (var i = 0; i < boundTextures.length; i++) {\n if (boundTextures[i] === texture) {\n if (this.currentLocation !== i) {\n gl.activeTexture(gl.TEXTURE0 + i);\n this.currentLocation = i;\n }\n gl.bindTexture(texture.target, this.emptyTextures[texture.target].texture);\n boundTextures[i] = null;\n }\n }\n };\n /**\n * Ensures that current boundTextures all have FLOAT sampler type,\n * see {@link PIXI.SAMPLER_TYPES} for explanation.\n *\n * @param maxTextures - number of locations to check\n */\n TextureSystem.prototype.ensureSamplerType = function (maxTextures) {\n var _a = this, boundTextures = _a.boundTextures, hasIntegerTextures = _a.hasIntegerTextures, CONTEXT_UID = _a.CONTEXT_UID;\n if (!hasIntegerTextures) {\n return;\n }\n for (var i = maxTextures - 1; i >= 0; --i) {\n var tex = boundTextures[i];\n if (tex) {\n var glTexture = tex._glTextures[CONTEXT_UID];\n if (glTexture.samplerType !== SAMPLER_TYPES.FLOAT) {\n this.renderer.texture.unbind(tex);\n }\n }\n }\n };\n /**\n * Initialize a texture\n *\n * @private\n * @param texture - Texture to initialize\n */\n TextureSystem.prototype.initTexture = function (texture) {\n var glTexture = new GLTexture(this.gl.createTexture());\n // guarantee an update..\n glTexture.dirtyId = -1;\n texture._glTextures[this.CONTEXT_UID] = glTexture;\n this.managedTextures.push(texture);\n texture.on('dispose', this.destroyTexture, this);\n return glTexture;\n };\n TextureSystem.prototype.initTextureType = function (texture, glTexture) {\n var _a, _b;\n glTexture.internalFormat = (_b = (_a = this.internalFormats[texture.type]) === null || _a === void 0 ? void 0 : _a[texture.format]) !== null && _b !== void 0 ? _b : texture.format;\n if (this.webGLVersion === 2 && texture.type === TYPES.HALF_FLOAT) {\n // TYPES.HALF_FLOAT is WebGL1 HALF_FLOAT_OES\n // we have to convert it to WebGL HALF_FLOAT\n glTexture.type = this.gl.HALF_FLOAT;\n }\n else {\n glTexture.type = texture.type;\n }\n };\n /**\n * Update a texture\n *\n * @private\n * @param {PIXI.BaseTexture} texture - Texture to initialize\n */\n TextureSystem.prototype.updateTexture = function (texture) {\n var glTexture = texture._glTextures[this.CONTEXT_UID];\n if (!glTexture) {\n return;\n }\n var renderer = this.renderer;\n this.initTextureType(texture, glTexture);\n if (texture.resource && texture.resource.upload(renderer, texture, glTexture)) {\n // texture is uploaded, dont do anything!\n if (glTexture.samplerType !== SAMPLER_TYPES.FLOAT) {\n this.hasIntegerTextures = true;\n }\n }\n else {\n // default, renderTexture-like logic\n var width = texture.realWidth;\n var height = texture.realHeight;\n var gl = renderer.gl;\n if (glTexture.width !== width\n || glTexture.height !== height\n || glTexture.dirtyId < 0) {\n glTexture.width = width;\n glTexture.height = height;\n gl.texImage2D(texture.target, 0, glTexture.internalFormat, width, height, 0, texture.format, glTexture.type, null);\n }\n }\n // lets only update what changes..\n if (texture.dirtyStyleId !== glTexture.dirtyStyleId) {\n this.updateTextureStyle(texture);\n }\n glTexture.dirtyId = texture.dirtyId;\n };\n /**\n * Deletes the texture from WebGL\n *\n * @private\n * @param texture_ - the texture to destroy\n * @param [skipRemove=false] - Whether to skip removing the texture from the TextureManager.\n */\n TextureSystem.prototype.destroyTexture = function (texture, skipRemove) {\n var gl = this.gl;\n texture = texture.castToBaseTexture();\n if (texture._glTextures[this.CONTEXT_UID]) {\n this.unbind(texture);\n gl.deleteTexture(texture._glTextures[this.CONTEXT_UID].texture);\n texture.off('dispose', this.destroyTexture, this);\n delete texture._glTextures[this.CONTEXT_UID];\n if (!skipRemove) {\n var i = this.managedTextures.indexOf(texture);\n if (i !== -1) {\n removeItems(this.managedTextures, i, 1);\n }\n }\n }\n };\n /**\n * Update texture style such as mipmap flag\n *\n * @private\n * @param {PIXI.BaseTexture} texture - Texture to update\n */\n TextureSystem.prototype.updateTextureStyle = function (texture) {\n var glTexture = texture._glTextures[this.CONTEXT_UID];\n if (!glTexture) {\n return;\n }\n if ((texture.mipmap === MIPMAP_MODES.POW2 || this.webGLVersion !== 2) && !texture.isPowerOfTwo) {\n glTexture.mipmap = false;\n }\n else {\n glTexture.mipmap = texture.mipmap >= 1;\n }\n if (this.webGLVersion !== 2 && !texture.isPowerOfTwo) {\n glTexture.wrapMode = WRAP_MODES.CLAMP;\n }\n else {\n glTexture.wrapMode = texture.wrapMode;\n }\n if (texture.resource && texture.resource.style(this.renderer, texture, glTexture)) ;\n else {\n this.setStyle(texture, glTexture);\n }\n glTexture.dirtyStyleId = texture.dirtyStyleId;\n };\n /**\n * Set style for texture\n *\n * @private\n * @param texture - Texture to update\n * @param glTexture\n */\n TextureSystem.prototype.setStyle = function (texture, glTexture) {\n var gl = this.gl;\n if (glTexture.mipmap && texture.mipmap !== MIPMAP_MODES.ON_MANUAL) {\n gl.generateMipmap(texture.target);\n }\n gl.texParameteri(texture.target, gl.TEXTURE_WRAP_S, glTexture.wrapMode);\n gl.texParameteri(texture.target, gl.TEXTURE_WRAP_T, glTexture.wrapMode);\n if (glTexture.mipmap) {\n /* eslint-disable max-len */\n gl.texParameteri(texture.target, gl.TEXTURE_MIN_FILTER, texture.scaleMode === SCALE_MODES.LINEAR ? gl.LINEAR_MIPMAP_LINEAR : gl.NEAREST_MIPMAP_NEAREST);\n /* eslint-disable max-len */\n var anisotropicExt = this.renderer.context.extensions.anisotropicFiltering;\n if (anisotropicExt && texture.anisotropicLevel > 0 && texture.scaleMode === SCALE_MODES.LINEAR) {\n var level = Math.min(texture.anisotropicLevel, gl.getParameter(anisotropicExt.MAX_TEXTURE_MAX_ANISOTROPY_EXT));\n gl.texParameterf(texture.target, anisotropicExt.TEXTURE_MAX_ANISOTROPY_EXT, level);\n }\n }\n else {\n gl.texParameteri(texture.target, gl.TEXTURE_MIN_FILTER, texture.scaleMode === SCALE_MODES.LINEAR ? gl.LINEAR : gl.NEAREST);\n }\n gl.texParameteri(texture.target, gl.TEXTURE_MAG_FILTER, texture.scaleMode === SCALE_MODES.LINEAR ? gl.LINEAR : gl.NEAREST);\n };\n TextureSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n return TextureSystem;\n}());\n\n\n\nvar _systems = {\n __proto__: null,\n FilterSystem: FilterSystem,\n BatchSystem: BatchSystem,\n ContextSystem: ContextSystem,\n FramebufferSystem: FramebufferSystem,\n GeometrySystem: GeometrySystem,\n MaskSystem: MaskSystem,\n ScissorSystem: ScissorSystem,\n StencilSystem: StencilSystem,\n ProjectionSystem: ProjectionSystem,\n RenderTextureSystem: RenderTextureSystem,\n ShaderSystem: ShaderSystem,\n StateSystem: StateSystem,\n TextureGCSystem: TextureGCSystem,\n TextureSystem: TextureSystem\n};\n\nvar tempMatrix$2 = new Matrix();\n/**\n * The AbstractRenderer is the base for a PixiJS Renderer. It is extended by the {@link PIXI.CanvasRenderer}\n * and {@link PIXI.Renderer} which can be used for rendering a PixiJS scene.\n *\n * @abstract\n * @class\n * @extends PIXI.utils.EventEmitter\n * @memberof PIXI\n */\nvar AbstractRenderer = /** @class */ (function (_super) {\n __extends(AbstractRenderer, _super);\n /**\n * @param system - The name of the system this renderer is for.\n * @param [options] - The optional renderer parameters.\n * @param {number} [options.width=800] - The width of the screen.\n * @param {number} [options.height=600] - The height of the screen.\n * @param {HTMLCanvasElement} [options.view] - The canvas to use as a view, optional.\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1.\n * @param {boolean} [options.antialias=false] - Sets antialias\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.preserveDrawingBuffer=false] - Enables drawing buffer preservation,\n * enable this if you need to call toDataUrl on the WebGL context.\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear the canvas or\n * not before the new render pass.\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n */\n function AbstractRenderer(type, options) {\n if (type === void 0) { type = RENDERER_TYPE.UNKNOWN; }\n var _this = _super.call(this) || this;\n // Add the default render options\n options = Object.assign({}, settings.RENDER_OPTIONS, options);\n /**\n * The supplied constructor options.\n *\n * @member {Object}\n * @readOnly\n */\n _this.options = options;\n /**\n * The type of the renderer.\n *\n * @member {number}\n * @default PIXI.RENDERER_TYPE.UNKNOWN\n * @see PIXI.RENDERER_TYPE\n */\n _this.type = type;\n /**\n * Measurements of the screen. (0, 0, screenWidth, screenHeight).\n *\n * Its safe to use as filterArea or hitArea for the whole stage.\n *\n * @member {PIXI.Rectangle}\n */\n _this.screen = new Rectangle(0, 0, options.width, options.height);\n /**\n * The canvas element that everything is drawn to.\n *\n * @member {HTMLCanvasElement}\n */\n _this.view = options.view || document.createElement('canvas');\n /**\n * The resolution / device pixel ratio of the renderer.\n *\n * @member {number}\n * @default PIXI.settings.RESOLUTION\n */\n _this.resolution = options.resolution || settings.RESOLUTION;\n /**\n * Pass-thru setting for the canvas' context `alpha` property. This is typically\n * not something you need to fiddle with. If you want transparency, use `backgroundAlpha`.\n *\n * @member {boolean}\n */\n _this.useContextAlpha = options.useContextAlpha;\n /**\n * Whether CSS dimensions of canvas view should be resized to screen dimensions automatically.\n *\n * @member {boolean}\n */\n _this.autoDensity = !!options.autoDensity;\n /**\n * The value of the preserveDrawingBuffer flag affects whether or not the contents of\n * the stencil buffer is retained after rendering.\n *\n * @member {boolean}\n */\n _this.preserveDrawingBuffer = options.preserveDrawingBuffer;\n /**\n * This sets if the CanvasRenderer will clear the canvas or not before the new render pass.\n * If the scene is NOT transparent PixiJS will use a canvas sized fillRect operation every\n * frame to set the canvas background color. If the scene is transparent PixiJS will use clearRect\n * to clear the canvas every frame. Disable this by setting this to false. For example, if\n * your game has a canvas filling background image you often don't need this set.\n *\n * @member {boolean}\n * @default\n */\n _this.clearBeforeRender = options.clearBeforeRender;\n /**\n * The background color as a number.\n *\n * @member {number}\n * @protected\n */\n _this._backgroundColor = 0x000000;\n /**\n * The background color as an [R, G, B, A] array.\n *\n * @member {number[]}\n * @protected\n */\n _this._backgroundColorRgba = [0, 0, 0, 1];\n /**\n * The background color as a string.\n *\n * @member {string}\n * @protected\n */\n _this._backgroundColorString = '#000000';\n _this.backgroundColor = options.backgroundColor || _this._backgroundColor; // run bg color setter\n _this.backgroundAlpha = options.backgroundAlpha;\n // @deprecated\n if (options.transparent !== undefined) {\n deprecation('6.0.0', 'Option transparent is deprecated, please use backgroundAlpha instead.');\n _this.useContextAlpha = options.transparent;\n _this.backgroundAlpha = options.transparent ? 0 : 1;\n }\n /**\n * The last root object that the renderer tried to render.\n *\n * @member {PIXI.DisplayObject}\n * @protected\n */\n _this._lastObjectRendered = null;\n /**\n * Collection of plugins.\n * @readonly\n * @member {object}\n */\n _this.plugins = {};\n return _this;\n }\n /**\n * Initialize the plugins.\n *\n * @protected\n * @param {object} staticMap - The dictionary of statically saved plugins.\n */\n AbstractRenderer.prototype.initPlugins = function (staticMap) {\n for (var o in staticMap) {\n this.plugins[o] = new (staticMap[o])(this);\n }\n };\n Object.defineProperty(AbstractRenderer.prototype, \"width\", {\n /**\n * Same as view.width, actual number of pixels in the canvas by horizontal.\n *\n * @member {number}\n * @readonly\n * @default 800\n */\n get: function () {\n return this.view.width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AbstractRenderer.prototype, \"height\", {\n /**\n * Same as view.height, actual number of pixels in the canvas by vertical.\n *\n * @member {number}\n * @readonly\n * @default 600\n */\n get: function () {\n return this.view.height;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Resizes the screen and canvas as close as possible to the specified width and height.\n * Canvas dimensions are multiplied by resolution and rounded to the nearest integers.\n * The new canvas dimensions divided by the resolution become the new screen dimensions.\n *\n * @param desiredScreenWidth - The desired width of the screen.\n * @param desiredScreenHeight - The desired height of the screen.\n */\n AbstractRenderer.prototype.resize = function (desiredScreenWidth, desiredScreenHeight) {\n this.view.width = Math.round(desiredScreenWidth * this.resolution);\n this.view.height = Math.round(desiredScreenHeight * this.resolution);\n var screenWidth = this.view.width / this.resolution;\n var screenHeight = this.view.height / this.resolution;\n this.screen.width = screenWidth;\n this.screen.height = screenHeight;\n if (this.autoDensity) {\n this.view.style.width = screenWidth + \"px\";\n this.view.style.height = screenHeight + \"px\";\n }\n /**\n * Fired after view has been resized.\n *\n * @event PIXI.Renderer#resize\n * @param {number} screenWidth - The new width of the screen.\n * @param {number} screenHeight - The new height of the screen.\n */\n this.emit('resize', screenWidth, screenHeight);\n };\n /**\n * @ignore\n */\n AbstractRenderer.prototype.generateTexture = function (displayObject, options, resolution, region) {\n if (options === void 0) { options = {}; }\n // @deprecated parameters spread, use options instead\n if (typeof options === 'number') {\n deprecation('6.1.0', 'generateTexture options (scaleMode, resolution, region) are now object options.');\n options = { scaleMode: options, resolution: resolution, region: region };\n }\n var manualRegion = options.region, textureOptions = __rest(options, [\"region\"]);\n region = manualRegion || displayObject.getLocalBounds(null, true);\n // minimum texture size is 1x1, 0x0 will throw an error\n if (region.width === 0)\n { region.width = 1; }\n if (region.height === 0)\n { region.height = 1; }\n var renderTexture = RenderTexture.create(__assign({ width: region.width, height: region.height }, textureOptions));\n tempMatrix$2.tx = -region.x;\n tempMatrix$2.ty = -region.y;\n this.render(displayObject, {\n renderTexture: renderTexture,\n clear: false,\n transform: tempMatrix$2,\n skipUpdateTransform: !!displayObject.parent\n });\n return renderTexture;\n };\n /**\n * Removes everything from the renderer and optionally removes the Canvas DOM element.\n *\n * @param [removeView=false] - Removes the Canvas element from the DOM.\n */\n AbstractRenderer.prototype.destroy = function (removeView) {\n for (var o in this.plugins) {\n this.plugins[o].destroy();\n this.plugins[o] = null;\n }\n if (removeView && this.view.parentNode) {\n this.view.parentNode.removeChild(this.view);\n }\n var thisAny = this;\n // null-ing all objects, that's a tradition!\n thisAny.plugins = null;\n thisAny.type = RENDERER_TYPE.UNKNOWN;\n thisAny.view = null;\n thisAny.screen = null;\n thisAny._tempDisplayObjectParent = null;\n thisAny.options = null;\n this._backgroundColorRgba = null;\n this._backgroundColorString = null;\n this._lastObjectRendered = null;\n };\n Object.defineProperty(AbstractRenderer.prototype, \"backgroundColor\", {\n /**\n * The background color to fill if not transparent\n *\n * @member {number}\n */\n get: function () {\n return this._backgroundColor;\n },\n set: function (value) {\n this._backgroundColor = value;\n this._backgroundColorString = hex2string(value);\n hex2rgb(value, this._backgroundColorRgba);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AbstractRenderer.prototype, \"backgroundAlpha\", {\n /**\n * The background color alpha. Setting this to 0 will make the canvas transparent.\n *\n * @member {number}\n */\n get: function () {\n return this._backgroundColorRgba[3];\n },\n set: function (value) {\n this._backgroundColorRgba[3] = value;\n },\n enumerable: false,\n configurable: true\n });\n return AbstractRenderer;\n}(EventEmitter));\n\nvar GLBuffer = /** @class */ (function () {\n function GLBuffer(buffer) {\n this.buffer = buffer || null;\n this.updateID = -1;\n this.byteLength = -1;\n this.refCount = 0;\n }\n return GLBuffer;\n}());\n\n/**\n * System plugin to the renderer to manage buffers.\n *\n * WebGL uses Buffers as a way to store objects to the GPU.\n * This system makes working with them a lot easier.\n *\n * Buffers are used in three main places in WebGL\n * - geometry information\n * - Uniform information (via uniform buffer objects - a WebGL 2 only feature)\n * - Transform feedback information. (WebGL 2 only feature)\n *\n * This system will handle the binding of buffers to the GPU as well as uploading\n * them. With this system, you never need to work directly with GPU buffers, but instead work with\n * the PIXI.Buffer class.\n *\n *\n * @class\n * @memberof PIXI\n */\nvar BufferSystem = /** @class */ (function () {\n /**\n * @param {PIXI.Renderer} renderer - The renderer this System works for.\n */\n function BufferSystem(renderer) {\n this.renderer = renderer;\n this.managedBuffers = {};\n this.boundBufferBases = {};\n }\n /**\n * @ignore\n */\n BufferSystem.prototype.destroy = function () {\n this.renderer = null;\n };\n /**\n * Sets up the renderer context and necessary buffers.\n */\n BufferSystem.prototype.contextChange = function () {\n this.disposeAll(true);\n this.gl = this.renderer.gl;\n // TODO fill out...\n this.CONTEXT_UID = this.renderer.CONTEXT_UID;\n };\n /**\n * This binds specified buffer. On first run, it will create the webGL buffers for the context too\n *\n * @param buffer - the buffer to bind to the renderer\n */\n BufferSystem.prototype.bind = function (buffer) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n var glBuffer = buffer._glBuffers[CONTEXT_UID] || this.createGLBuffer(buffer);\n gl.bindBuffer(buffer.type, glBuffer.buffer);\n };\n /**\n * Binds an uniform buffer to at the given index.\n *\n * A cache is used so a buffer will not be bound again if already bound.\n *\n * @param buffer - the buffer to bind\n * @param index - the base index to bind it to.\n */\n BufferSystem.prototype.bindBufferBase = function (buffer, index) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n if (this.boundBufferBases[index] !== buffer) {\n var glBuffer = buffer._glBuffers[CONTEXT_UID] || this.createGLBuffer(buffer);\n this.boundBufferBases[index] = buffer;\n gl.bindBufferBase(gl.UNIFORM_BUFFER, index, glBuffer.buffer);\n }\n };\n /**\n * Binds a buffer whilst also binding its range.\n * This will make the buffer start from the offset supplied rather than 0 when it is read.\n *\n * @param buffer - the buffer to bind\n * @param index - the base index to bind at, defaults to 0\n * @param offset - the offset to bind at (this is blocks of 256). 0 = 0, 1 = 256, 2 = 512 etc\n */\n BufferSystem.prototype.bindBufferRange = function (buffer, index, offset) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n offset = offset || 0;\n var glBuffer = buffer._glBuffers[CONTEXT_UID] || this.createGLBuffer(buffer);\n gl.bindBufferRange(gl.UNIFORM_BUFFER, index || 0, glBuffer.buffer, offset * 256, 256);\n };\n /**\n * Will ensure the data in the buffer is uploaded to the GPU.\n *\n * @param {PIXI.Buffer} buffer - the buffer to update\n */\n BufferSystem.prototype.update = function (buffer) {\n var _a = this, gl = _a.gl, CONTEXT_UID = _a.CONTEXT_UID;\n var glBuffer = buffer._glBuffers[CONTEXT_UID];\n if (buffer._updateID === glBuffer.updateID) {\n return;\n }\n glBuffer.updateID = buffer._updateID;\n gl.bindBuffer(buffer.type, glBuffer.buffer);\n if (glBuffer.byteLength >= buffer.data.byteLength) {\n // offset is always zero for now!\n gl.bufferSubData(buffer.type, 0, buffer.data);\n }\n else {\n var drawType = buffer.static ? gl.STATIC_DRAW : gl.DYNAMIC_DRAW;\n glBuffer.byteLength = buffer.data.byteLength;\n gl.bufferData(buffer.type, buffer.data, drawType);\n }\n };\n /**\n * Disposes buffer\n * @param {PIXI.Buffer} buffer - buffer with data\n * @param {boolean} [contextLost=false] - If context was lost, we suppress deleteVertexArray\n */\n BufferSystem.prototype.dispose = function (buffer, contextLost) {\n if (!this.managedBuffers[buffer.id]) {\n return;\n }\n delete this.managedBuffers[buffer.id];\n var glBuffer = buffer._glBuffers[this.CONTEXT_UID];\n var gl = this.gl;\n buffer.disposeRunner.remove(this);\n if (!glBuffer) {\n return;\n }\n if (!contextLost) {\n gl.deleteBuffer(glBuffer.buffer);\n }\n delete buffer._glBuffers[this.CONTEXT_UID];\n };\n /**\n * dispose all WebGL resources of all managed buffers\n * @param {boolean} [contextLost=false] - If context was lost, we suppress `gl.delete` calls\n */\n BufferSystem.prototype.disposeAll = function (contextLost) {\n var all = Object.keys(this.managedBuffers);\n for (var i = 0; i < all.length; i++) {\n this.dispose(this.managedBuffers[all[i]], contextLost);\n }\n };\n /**\n * creates and attaches a GLBuffer object tied to the current context.\n * @protected\n */\n BufferSystem.prototype.createGLBuffer = function (buffer) {\n var _a = this, CONTEXT_UID = _a.CONTEXT_UID, gl = _a.gl;\n buffer._glBuffers[CONTEXT_UID] = new GLBuffer(gl.createBuffer());\n this.managedBuffers[buffer.id] = buffer;\n buffer.disposeRunner.add(this);\n return buffer._glBuffers[CONTEXT_UID];\n };\n return BufferSystem;\n}());\n\n/**\n * The Renderer draws the scene and all its content onto a WebGL enabled canvas.\n *\n * This renderer should be used for browsers that support WebGL.\n *\n * This renderer works by automatically managing WebGLBatchesm, so no need for Sprite Batches or Sprite Clouds.\n * Don't forget to add the view to your DOM or you will not see anything!\n *\n * Renderer is composed of systems that manage specific tasks. The following systems are added by default\n * whenever you create a renderer:\n *\n * | System | Description |\n * | ------------------------------------ | ----------------------------------------------------------------------------- |\n * | {@link PIXI.BatchSystem} | This manages object renderers that defer rendering until a flush. |\n * | {@link PIXI.ContextSystem} | This manages the WebGL context and extensions. |\n * | {@link PIXI.EventSystem} | This manages UI events. |\n * | {@link PIXI.FilterSystem} | This manages the filtering pipeline for post-processing effects. |\n * | {@link PIXI.FramebufferSystem} | This manages framebuffers, which are used for offscreen rendering. |\n * | {@link PIXI.GeometrySystem} | This manages geometries & buffers, which are used to draw object meshes. |\n * | {@link PIXI.MaskSystem} | This manages masking operations. |\n * | {@link PIXI.ProjectionSystem} | This manages the `projectionMatrix`, used by shaders to get NDC coordinates. |\n * | {@link PIXI.RenderTextureSystem} | This manages render-textures, which are an abstraction over framebuffers. |\n * | {@link PIXI.ScissorSystem} | This handles scissor masking, and is used internally by {@link MaskSystem} |\n * | {@link PIXI.ShaderSystem} | This manages shaders, programs that run on the GPU to calculate 'em pixels. |\n * | {@link PIXI.StateSystem} | This manages the WebGL state variables like blend mode, depth testing, etc. |\n * | {@link PIXI.StencilSystem} | This handles stencil masking, and is used internally by {@link MaskSystem} |\n * | {@link PIXI.TextureSystem} | This manages textures and their resources on the GPU. |\n * | {@link PIXI.TextureGCSystem} | This will automatically remove textures from the GPU if they are not used. |\n *\n * The breadth of the API surface provided by the renderer is contained within these systems.\n *\n * @memberof PIXI\n */\nvar Renderer = /** @class */ (function (_super) {\n __extends(Renderer, _super);\n /**\n * @param [options] - The optional renderer parameters.\n * @param {number} [options.width=800] - The width of the screen.\n * @param {number} [options.height=600] - The height of the screen.\n * @param {HTMLCanvasElement} [options.view] - The canvas to use as a view, optional.\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1.\n * @param {boolean} [options.antialias=false] - Sets antialias. If not available natively then FXAA\n * antialiasing is used.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear\n * the canvas or not before the new render pass. If you wish to set this to false, you *must* set\n * preserveDrawingBuffer to `true`.\n * @param {boolean} [options.preserveDrawingBuffer=false] - Enables drawing buffer preservation,\n * enable this if you need to call toDataUrl on the WebGL context.\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n * @param {string} [options.powerPreference] - Parameter passed to WebGL context, set to \"high-performance\"\n * for devices with dual graphics card.\n * @param {object} [options.context] - If WebGL context already exists, all parameters must be taken from it.\n */\n function Renderer(options) {\n var _this = _super.call(this, RENDERER_TYPE.WEBGL, options) || this;\n // the options will have been modified here in the super constructor with pixi's default settings..\n options = _this.options;\n _this.gl = null;\n _this.CONTEXT_UID = 0;\n _this.runners = {\n destroy: new Runner('destroy'),\n contextChange: new Runner('contextChange'),\n reset: new Runner('reset'),\n update: new Runner('update'),\n postrender: new Runner('postrender'),\n prerender: new Runner('prerender'),\n resize: new Runner('resize'),\n };\n _this.runners.contextChange.add(_this);\n _this.globalUniforms = new UniformGroup({\n projectionMatrix: new Matrix(),\n }, true);\n _this.addSystem(MaskSystem, 'mask')\n .addSystem(ContextSystem, 'context')\n .addSystem(StateSystem, 'state')\n .addSystem(ShaderSystem, 'shader')\n .addSystem(TextureSystem, 'texture')\n .addSystem(BufferSystem, 'buffer')\n .addSystem(GeometrySystem, 'geometry')\n .addSystem(FramebufferSystem, 'framebuffer')\n .addSystem(ScissorSystem, 'scissor')\n .addSystem(StencilSystem, 'stencil')\n .addSystem(ProjectionSystem, 'projection')\n .addSystem(TextureGCSystem, 'textureGC')\n .addSystem(FilterSystem, 'filter')\n .addSystem(RenderTextureSystem, 'renderTexture')\n .addSystem(BatchSystem, 'batch');\n _this.initPlugins(Renderer.__plugins);\n _this.multisample = undefined;\n /*\n * The options passed in to create a new WebGL context.\n */\n if (options.context) {\n _this.context.initFromContext(options.context);\n }\n else {\n _this.context.initFromOptions({\n alpha: !!_this.useContextAlpha,\n antialias: options.antialias,\n premultipliedAlpha: _this.useContextAlpha && _this.useContextAlpha !== 'notMultiplied',\n stencil: true,\n preserveDrawingBuffer: options.preserveDrawingBuffer,\n powerPreference: _this.options.powerPreference,\n });\n }\n _this.renderingToScreen = true;\n sayHello(_this.context.webGLVersion === 2 ? 'WebGL 2' : 'WebGL 1');\n _this.resize(_this.options.width, _this.options.height);\n return _this;\n }\n /**\n * Create renderer if WebGL is available. Overrideable\n * by the **@pixi/canvas-renderer** package to allow fallback.\n * throws error if WebGL is not available.\n *\n * @private\n */\n Renderer.create = function (options) {\n if (isWebGLSupported()) {\n return new Renderer(options);\n }\n throw new Error('WebGL unsupported in this browser, use \"pixi.js-legacy\" for fallback canvas2d support.');\n };\n Renderer.prototype.contextChange = function () {\n var gl = this.gl;\n var samples;\n if (this.context.webGLVersion === 1) {\n var framebuffer = gl.getParameter(gl.FRAMEBUFFER_BINDING);\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n samples = gl.getParameter(gl.SAMPLES);\n gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);\n }\n else {\n var framebuffer = gl.getParameter(gl.DRAW_FRAMEBUFFER_BINDING);\n gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, null);\n samples = gl.getParameter(gl.SAMPLES);\n gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, framebuffer);\n }\n if (samples >= MSAA_QUALITY.HIGH) {\n this.multisample = MSAA_QUALITY.HIGH;\n }\n else if (samples >= MSAA_QUALITY.MEDIUM) {\n this.multisample = MSAA_QUALITY.MEDIUM;\n }\n else if (samples >= MSAA_QUALITY.LOW) {\n this.multisample = MSAA_QUALITY.LOW;\n }\n else {\n this.multisample = MSAA_QUALITY.NONE;\n }\n };\n /**\n * Add a new system to the renderer.\n *\n * @param ClassRef - Class reference\n * @param name - Property name for system, if not specified\n * will use a static `name` property on the class itself. This\n * name will be assigned as s property on the Renderer so make\n * sure it doesn't collide with properties on Renderer.\n * @return Return instance of renderer\n */\n Renderer.prototype.addSystem = function (ClassRef, name) {\n var system = new ClassRef(this);\n if (this[name]) {\n throw new Error(\"Whoops! The name \\\"\" + name + \"\\\" is already in use\");\n }\n this[name] = system;\n for (var i in this.runners) {\n this.runners[i].add(system);\n }\n /**\n * Fired after rendering finishes.\n *\n * @event PIXI.Renderer#postrender\n */\n /**\n * Fired before rendering starts.\n *\n * @event PIXI.Renderer#prerender\n */\n /**\n * Fired when the WebGL context is set.\n *\n * @event PIXI.Renderer#context\n * @param {WebGLRenderingContext} gl - WebGL context.\n */\n return this;\n };\n /**\n * @ignore\n */\n Renderer.prototype.render = function (displayObject, options) {\n var renderTexture;\n var clear;\n var transform;\n var skipUpdateTransform;\n if (options) {\n if (options instanceof RenderTexture) {\n deprecation('6.0.0', 'Renderer#render arguments changed, use options instead.');\n /* eslint-disable prefer-rest-params */\n renderTexture = options;\n clear = arguments[2];\n transform = arguments[3];\n skipUpdateTransform = arguments[4];\n /* eslint-enable prefer-rest-params */\n }\n else {\n renderTexture = options.renderTexture;\n clear = options.clear;\n transform = options.transform;\n skipUpdateTransform = options.skipUpdateTransform;\n }\n }\n // can be handy to know!\n this.renderingToScreen = !renderTexture;\n this.runners.prerender.emit();\n this.emit('prerender');\n // apply a transform at a GPU level\n this.projection.transform = transform;\n // no point rendering if our context has been blown up!\n if (this.context.isLost) {\n return;\n }\n if (!renderTexture) {\n this._lastObjectRendered = displayObject;\n }\n if (!skipUpdateTransform) {\n // update the scene graph\n var cacheParent = displayObject.enableTempParent();\n displayObject.updateTransform();\n displayObject.disableTempParent(cacheParent);\n // displayObject.hitArea = //TODO add a temp hit area\n }\n this.renderTexture.bind(renderTexture);\n this.batch.currentRenderer.start();\n if (clear !== undefined ? clear : this.clearBeforeRender) {\n this.renderTexture.clear();\n }\n displayObject.render(this);\n // apply transform..\n this.batch.currentRenderer.flush();\n if (renderTexture) {\n renderTexture.baseTexture.update();\n }\n this.runners.postrender.emit();\n // reset transform after render\n this.projection.transform = null;\n this.emit('postrender');\n };\n /**\n * @override\n * @ignore\n */\n Renderer.prototype.generateTexture = function (displayObject, options, resolution, region) {\n if (options === void 0) { options = {}; }\n var renderTexture = _super.prototype.generateTexture.call(this, displayObject, options, resolution, region);\n this.framebuffer.blit();\n return renderTexture;\n };\n /**\n * Resizes the WebGL view to the specified width and height.\n *\n * @param desiredScreenWidth - The desired width of the screen.\n * @param desiredScreenHeight - The desired height of the screen.\n */\n Renderer.prototype.resize = function (desiredScreenWidth, desiredScreenHeight) {\n _super.prototype.resize.call(this, desiredScreenWidth, desiredScreenHeight);\n this.runners.resize.emit(this.screen.height, this.screen.width);\n };\n /**\n * Resets the WebGL state so you can render things however you fancy!\n *\n * @return Returns itself.\n */\n Renderer.prototype.reset = function () {\n this.runners.reset.emit();\n return this;\n };\n /** Clear the frame buffer. */\n Renderer.prototype.clear = function () {\n this.renderTexture.bind();\n this.renderTexture.clear();\n };\n /**\n * Removes everything from the renderer (event listeners, spritebatch, etc...)\n *\n * @param [removeView=false] - Removes the Canvas element from the DOM.\n * See: https://github.com/pixijs/pixi.js/issues/2233\n */\n Renderer.prototype.destroy = function (removeView) {\n this.runners.destroy.emit();\n for (var r in this.runners) {\n this.runners[r].destroy();\n }\n // call base destroy\n _super.prototype.destroy.call(this, removeView);\n // TODO nullify all the managers..\n this.gl = null;\n };\n Object.defineProperty(Renderer.prototype, \"extract\", {\n /**\n * Please use `plugins.extract` instead.\n * @member {PIXI.Extract} extract\n * @deprecated since 6.0.0\n * @readonly\n */\n get: function () {\n deprecation('6.0.0', 'Renderer#extract has been deprecated, please use Renderer#plugins.extract instead.');\n return this.plugins.extract;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Adds a plugin to the renderer.\n *\n * @param pluginName - The name of the plugin.\n * @param ctor - The constructor function or class for the plugin.\n */\n Renderer.registerPlugin = function (pluginName, ctor) {\n Renderer.__plugins = Renderer.__plugins || {};\n Renderer.__plugins[pluginName] = ctor;\n };\n return Renderer;\n}(AbstractRenderer));\n\n/**\n * This helper function will automatically detect which renderer you should be using.\n * WebGL is the preferred renderer as it is a lot faster. If WebGL is not supported by\n * the browser then this function will return a canvas renderer\n *\n * @memberof PIXI\n * @function autoDetectRenderer\n * @param {object} [options] - The optional renderer parameters\n * @param {number} [options.width=800] - the width of the renderers view\n * @param {number} [options.height=600] - the height of the renderers view\n * @param {HTMLCanvasElement} [options.view] - the canvas to use as a view, optional\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1\n * @param {boolean} [options.antialias=false] - sets antialias\n * @param {boolean} [options.preserveDrawingBuffer=false] - enables drawing buffer preservation, enable this if you\n * need to call toDataUrl on the webgl context\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear the canvas or\n * not before the new render pass.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.forceCanvas=false] - prevents selection of WebGL renderer, even if such is present, this\n * option only is available when using **pixi.js-legacy** or **@pixi/canvas-renderer** modules, otherwise\n * it is ignored.\n * @param {string} [options.powerPreference] - Parameter passed to webgl context, set to \"high-performance\"\n * for devices with dual graphics card **webgl only**\n * @return {PIXI.Renderer|PIXI.CanvasRenderer} Returns WebGL renderer if available, otherwise CanvasRenderer\n */\nfunction autoDetectRenderer(options) {\n return Renderer.create(options);\n}\n\nvar $defaultVertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n vTextureCoord = aTextureCoord;\\n}\";\n\nvar $defaultFilterVertex = \"attribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvec2 filterTextureCoord( void )\\n{\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n}\\n\\nvoid main(void)\\n{\\n gl_Position = filterVertexPosition();\\n vTextureCoord = filterTextureCoord();\\n}\\n\";\n\n/**\n * Default vertex shader\n * @memberof PIXI\n * @member {string} defaultVertex\n */\n/**\n * Default filter vertex shader\n * @memberof PIXI\n * @member {string} defaultFilterVertex\n */\n// NOTE: This black magic is so that @microsoft/api-extractor does not complain! This explicitly specifies the types\n// of defaultVertex, defaultFilterVertex.\nvar defaultVertex$2 = $defaultVertex;\nvar defaultFilterVertex = $defaultFilterVertex;\n\n/**\n * Use the ISystem interface instead.\n * @deprecated since 6.1.0\n * @memberof PIXI\n */\nvar System = /** @class */ (function () {\n /**\n * @param renderer - Reference to Renderer\n */\n function System(renderer) {\n deprecation('6.1.0', 'System class is deprecated, implemement ISystem interface instead.');\n this.renderer = renderer;\n }\n /** Destroy and don't use after this. */\n System.prototype.destroy = function () {\n this.renderer = null;\n };\n return System;\n}());\n\n/**\n * Used by the batcher to draw batches.\n * Each one of these contains all information required to draw a bound geometry.\n *\n * @memberof PIXI\n */\nvar BatchDrawCall = /** @class */ (function () {\n function BatchDrawCall() {\n this.texArray = null;\n this.blend = 0;\n this.type = DRAW_MODES.TRIANGLES;\n this.start = 0;\n this.size = 0;\n this.data = null;\n }\n return BatchDrawCall;\n}());\n\n/**\n * Used by the batcher to build texture batches.\n * Holds list of textures and their respective locations.\n *\n * @memberof PIXI\n */\nvar BatchTextureArray = /** @class */ (function () {\n function BatchTextureArray() {\n this.elements = [];\n this.ids = [];\n this.count = 0;\n }\n BatchTextureArray.prototype.clear = function () {\n for (var i = 0; i < this.count; i++) {\n this.elements[i] = null;\n }\n this.count = 0;\n };\n return BatchTextureArray;\n}());\n\n/**\n * Flexible wrapper around `ArrayBuffer` that also provides typed array views on demand.\n *\n * @memberof PIXI\n */\nvar ViewableBuffer = /** @class */ (function () {\n function ViewableBuffer(sizeOrBuffer) {\n if (typeof sizeOrBuffer === 'number') {\n this.rawBinaryData = new ArrayBuffer(sizeOrBuffer);\n }\n else if (sizeOrBuffer instanceof Uint8Array) {\n this.rawBinaryData = sizeOrBuffer.buffer;\n }\n else {\n this.rawBinaryData = sizeOrBuffer;\n }\n this.uint32View = new Uint32Array(this.rawBinaryData);\n this.float32View = new Float32Array(this.rawBinaryData);\n }\n Object.defineProperty(ViewableBuffer.prototype, \"int8View\", {\n /** View on the raw binary data as a `Int8Array`. */\n get: function () {\n if (!this._int8View) {\n this._int8View = new Int8Array(this.rawBinaryData);\n }\n return this._int8View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"uint8View\", {\n /** View on the raw binary data as a `Uint8Array`. */\n get: function () {\n if (!this._uint8View) {\n this._uint8View = new Uint8Array(this.rawBinaryData);\n }\n return this._uint8View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"int16View\", {\n /** View on the raw binary data as a `Int16Array`. */\n get: function () {\n if (!this._int16View) {\n this._int16View = new Int16Array(this.rawBinaryData);\n }\n return this._int16View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"uint16View\", {\n /** View on the raw binary data as a `Uint16Array`. */\n get: function () {\n if (!this._uint16View) {\n this._uint16View = new Uint16Array(this.rawBinaryData);\n }\n return this._uint16View;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ViewableBuffer.prototype, \"int32View\", {\n /** View on the raw binary data as a `Int32Array`. */\n get: function () {\n if (!this._int32View) {\n this._int32View = new Int32Array(this.rawBinaryData);\n }\n return this._int32View;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Returns the view of the given type.\n *\n * @param type - One of `int8`, `uint8`, `int16`,\n * `uint16`, `int32`, `uint32`, and `float32`.\n * @return - typed array of given type\n */\n ViewableBuffer.prototype.view = function (type) {\n return this[type + \"View\"];\n };\n /** Destroys all buffer references. Do not use after calling this. */\n ViewableBuffer.prototype.destroy = function () {\n this.rawBinaryData = null;\n this._int8View = null;\n this._uint8View = null;\n this._int16View = null;\n this._uint16View = null;\n this._int32View = null;\n this.uint32View = null;\n this.float32View = null;\n };\n ViewableBuffer.sizeOf = function (type) {\n switch (type) {\n case 'int8':\n case 'uint8':\n return 1;\n case 'int16':\n case 'uint16':\n return 2;\n case 'int32':\n case 'uint32':\n case 'float32':\n return 4;\n default:\n throw new Error(type + \" isn't a valid view type\");\n }\n };\n return ViewableBuffer;\n}());\n\n/**\n * Renderer dedicated to drawing and batching sprites.\n *\n * This is the default batch renderer. It buffers objects\n * with texture-based geometries and renders them in\n * batches. It uploads multiple textures to the GPU to\n * reduce to the number of draw calls.\n *\n * @memberof PIXI\n */\nvar AbstractBatchRenderer = /** @class */ (function (_super) {\n __extends(AbstractBatchRenderer, _super);\n /**\n * This will hook onto the renderer's `contextChange`\n * and `prerender` signals.\n *\n * @param {PIXI.Renderer} renderer - The renderer this works for.\n */\n function AbstractBatchRenderer(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.shaderGenerator = null;\n _this.geometryClass = null;\n _this.vertexSize = null;\n _this.state = State.for2d();\n _this.size = settings.SPRITE_BATCH_SIZE * 4;\n _this._vertexCount = 0;\n _this._indexCount = 0;\n _this._bufferedElements = [];\n _this._bufferedTextures = [];\n _this._bufferSize = 0;\n _this._shader = null;\n _this._packedGeometries = [];\n _this._packedGeometryPoolSize = 2;\n _this._flushId = 0;\n _this._aBuffers = {};\n _this._iBuffers = {};\n _this.MAX_TEXTURES = 1;\n _this.renderer.on('prerender', _this.onPrerender, _this);\n renderer.runners.contextChange.add(_this);\n _this._dcIndex = 0;\n _this._aIndex = 0;\n _this._iIndex = 0;\n _this._attributeBuffer = null;\n _this._indexBuffer = null;\n _this._tempBoundTextures = [];\n return _this;\n }\n /**\n * Handles the `contextChange` signal.\n *\n * It calculates `this.MAX_TEXTURES` and allocating the packed-geometry object pool.\n */\n AbstractBatchRenderer.prototype.contextChange = function () {\n var gl = this.renderer.gl;\n if (settings.PREFER_ENV === ENV.WEBGL_LEGACY) {\n this.MAX_TEXTURES = 1;\n }\n else {\n // step 1: first check max textures the GPU can handle.\n this.MAX_TEXTURES = Math.min(gl.getParameter(gl.MAX_TEXTURE_IMAGE_UNITS), settings.SPRITE_MAX_TEXTURES);\n // step 2: check the maximum number of if statements the shader can have too..\n this.MAX_TEXTURES = checkMaxIfStatementsInShader(this.MAX_TEXTURES, gl);\n }\n this._shader = this.shaderGenerator.generateShader(this.MAX_TEXTURES);\n // we use the second shader as the first one depending on your browser\n // may omit aTextureId as it is not used by the shader so is optimized out.\n for (var i = 0; i < this._packedGeometryPoolSize; i++) {\n /* eslint-disable max-len */\n this._packedGeometries[i] = new (this.geometryClass)();\n }\n this.initFlushBuffers();\n };\n /** Makes sure that static and dynamic flush pooled objects have correct dimensions. */\n AbstractBatchRenderer.prototype.initFlushBuffers = function () {\n var _drawCallPool = AbstractBatchRenderer._drawCallPool, _textureArrayPool = AbstractBatchRenderer._textureArrayPool;\n // max draw calls\n var MAX_SPRITES = this.size / 4;\n // max texture arrays\n var MAX_TA = Math.floor(MAX_SPRITES / this.MAX_TEXTURES) + 1;\n while (_drawCallPool.length < MAX_SPRITES) {\n _drawCallPool.push(new BatchDrawCall());\n }\n while (_textureArrayPool.length < MAX_TA) {\n _textureArrayPool.push(new BatchTextureArray());\n }\n for (var i = 0; i < this.MAX_TEXTURES; i++) {\n this._tempBoundTextures[i] = null;\n }\n };\n /**\n * Handles the `prerender` signal.\n *\n * It ensures that flushes start from the first geometry object again.\n */\n AbstractBatchRenderer.prototype.onPrerender = function () {\n this._flushId = 0;\n };\n /**\n * Buffers the \"batchable\" object. It need not be rendered immediately.\n *\n * @param {PIXI.DisplayObject} element - the element to render when\n * using this renderer\n */\n AbstractBatchRenderer.prototype.render = function (element) {\n if (!element._texture.valid) {\n return;\n }\n if (this._vertexCount + (element.vertexData.length / 2) > this.size) {\n this.flush();\n }\n this._vertexCount += element.vertexData.length / 2;\n this._indexCount += element.indices.length;\n this._bufferedTextures[this._bufferSize] = element._texture.baseTexture;\n this._bufferedElements[this._bufferSize++] = element;\n };\n AbstractBatchRenderer.prototype.buildTexturesAndDrawCalls = function () {\n var _a = this, textures = _a._bufferedTextures, MAX_TEXTURES = _a.MAX_TEXTURES;\n var textureArrays = AbstractBatchRenderer._textureArrayPool;\n var batch = this.renderer.batch;\n var boundTextures = this._tempBoundTextures;\n var touch = this.renderer.textureGC.count;\n var TICK = ++BaseTexture._globalBatch;\n var countTexArrays = 0;\n var texArray = textureArrays[0];\n var start = 0;\n batch.copyBoundTextures(boundTextures, MAX_TEXTURES);\n for (var i = 0; i < this._bufferSize; ++i) {\n var tex = textures[i];\n textures[i] = null;\n if (tex._batchEnabled === TICK) {\n continue;\n }\n if (texArray.count >= MAX_TEXTURES) {\n batch.boundArray(texArray, boundTextures, TICK, MAX_TEXTURES);\n this.buildDrawCalls(texArray, start, i);\n start = i;\n texArray = textureArrays[++countTexArrays];\n ++TICK;\n }\n tex._batchEnabled = TICK;\n tex.touched = touch;\n texArray.elements[texArray.count++] = tex;\n }\n if (texArray.count > 0) {\n batch.boundArray(texArray, boundTextures, TICK, MAX_TEXTURES);\n this.buildDrawCalls(texArray, start, this._bufferSize);\n ++countTexArrays;\n ++TICK;\n }\n // Clean-up\n for (var i = 0; i < boundTextures.length; i++) {\n boundTextures[i] = null;\n }\n BaseTexture._globalBatch = TICK;\n };\n /** Populating drawcalls for rendering */\n AbstractBatchRenderer.prototype.buildDrawCalls = function (texArray, start, finish) {\n var _a = this, elements = _a._bufferedElements, _attributeBuffer = _a._attributeBuffer, _indexBuffer = _a._indexBuffer, vertexSize = _a.vertexSize;\n var drawCalls = AbstractBatchRenderer._drawCallPool;\n var dcIndex = this._dcIndex;\n var aIndex = this._aIndex;\n var iIndex = this._iIndex;\n var drawCall = drawCalls[dcIndex];\n drawCall.start = this._iIndex;\n drawCall.texArray = texArray;\n for (var i = start; i < finish; ++i) {\n var sprite = elements[i];\n var tex = sprite._texture.baseTexture;\n var spriteBlendMode = premultiplyBlendMode[tex.alphaMode ? 1 : 0][sprite.blendMode];\n elements[i] = null;\n if (start < i && drawCall.blend !== spriteBlendMode) {\n drawCall.size = iIndex - drawCall.start;\n start = i;\n drawCall = drawCalls[++dcIndex];\n drawCall.texArray = texArray;\n drawCall.start = iIndex;\n }\n this.packInterleavedGeometry(sprite, _attributeBuffer, _indexBuffer, aIndex, iIndex);\n aIndex += sprite.vertexData.length / 2 * vertexSize;\n iIndex += sprite.indices.length;\n drawCall.blend = spriteBlendMode;\n }\n if (start < finish) {\n drawCall.size = iIndex - drawCall.start;\n ++dcIndex;\n }\n this._dcIndex = dcIndex;\n this._aIndex = aIndex;\n this._iIndex = iIndex;\n };\n /** Bind textures for current rendering */\n AbstractBatchRenderer.prototype.bindAndClearTexArray = function (texArray) {\n var textureSystem = this.renderer.texture;\n for (var j = 0; j < texArray.count; j++) {\n textureSystem.bind(texArray.elements[j], texArray.ids[j]);\n texArray.elements[j] = null;\n }\n texArray.count = 0;\n };\n AbstractBatchRenderer.prototype.updateGeometry = function () {\n var _a = this, packedGeometries = _a._packedGeometries, attributeBuffer = _a._attributeBuffer, indexBuffer = _a._indexBuffer;\n if (!settings.CAN_UPLOAD_SAME_BUFFER) { /* Usually on iOS devices, where the browser doesn't\n like uploads to the same buffer in a single frame. */\n if (this._packedGeometryPoolSize <= this._flushId) {\n this._packedGeometryPoolSize++;\n packedGeometries[this._flushId] = new (this.geometryClass)();\n }\n packedGeometries[this._flushId]._buffer.update(attributeBuffer.rawBinaryData);\n packedGeometries[this._flushId]._indexBuffer.update(indexBuffer);\n this.renderer.geometry.bind(packedGeometries[this._flushId]);\n this.renderer.geometry.updateBuffers();\n this._flushId++;\n }\n else {\n // lets use the faster option, always use buffer number 0\n packedGeometries[this._flushId]._buffer.update(attributeBuffer.rawBinaryData);\n packedGeometries[this._flushId]._indexBuffer.update(indexBuffer);\n this.renderer.geometry.updateBuffers();\n }\n };\n AbstractBatchRenderer.prototype.drawBatches = function () {\n var dcCount = this._dcIndex;\n var _a = this.renderer, gl = _a.gl, stateSystem = _a.state;\n var drawCalls = AbstractBatchRenderer._drawCallPool;\n var curTexArray = null;\n // Upload textures and do the draw calls\n for (var i = 0; i < dcCount; i++) {\n var _b = drawCalls[i], texArray = _b.texArray, type = _b.type, size = _b.size, start = _b.start, blend = _b.blend;\n if (curTexArray !== texArray) {\n curTexArray = texArray;\n this.bindAndClearTexArray(texArray);\n }\n this.state.blendMode = blend;\n stateSystem.set(this.state);\n gl.drawElements(type, size, gl.UNSIGNED_SHORT, start * 2);\n }\n };\n /** Renders the content _now_ and empties the current batch. */\n AbstractBatchRenderer.prototype.flush = function () {\n if (this._vertexCount === 0) {\n return;\n }\n this._attributeBuffer = this.getAttributeBuffer(this._vertexCount);\n this._indexBuffer = this.getIndexBuffer(this._indexCount);\n this._aIndex = 0;\n this._iIndex = 0;\n this._dcIndex = 0;\n this.buildTexturesAndDrawCalls();\n this.updateGeometry();\n this.drawBatches();\n // reset elements buffer for the next flush\n this._bufferSize = 0;\n this._vertexCount = 0;\n this._indexCount = 0;\n };\n /** Starts a new sprite batch. */\n AbstractBatchRenderer.prototype.start = function () {\n this.renderer.state.set(this.state);\n this.renderer.texture.ensureSamplerType(this.MAX_TEXTURES);\n this.renderer.shader.bind(this._shader);\n if (settings.CAN_UPLOAD_SAME_BUFFER) {\n // bind buffer #0, we don't need others\n this.renderer.geometry.bind(this._packedGeometries[this._flushId]);\n }\n };\n /** Stops and flushes the current batch. */\n AbstractBatchRenderer.prototype.stop = function () {\n this.flush();\n };\n /** Destroys this `AbstractBatchRenderer`. It cannot be used again. */\n AbstractBatchRenderer.prototype.destroy = function () {\n for (var i = 0; i < this._packedGeometryPoolSize; i++) {\n if (this._packedGeometries[i]) {\n this._packedGeometries[i].destroy();\n }\n }\n this.renderer.off('prerender', this.onPrerender, this);\n this._aBuffers = null;\n this._iBuffers = null;\n this._packedGeometries = null;\n this._attributeBuffer = null;\n this._indexBuffer = null;\n if (this._shader) {\n this._shader.destroy();\n this._shader = null;\n }\n _super.prototype.destroy.call(this);\n };\n /**\n * Fetches an attribute buffer from `this._aBuffers` that can hold atleast `size` floats.\n *\n * @param size - minimum capacity required\n * @return - buffer than can hold atleast `size` floats\n */\n AbstractBatchRenderer.prototype.getAttributeBuffer = function (size) {\n // 8 vertices is enough for 2 quads\n var roundedP2 = nextPow2(Math.ceil(size / 8));\n var roundedSizeIndex = log2(roundedP2);\n var roundedSize = roundedP2 * 8;\n if (this._aBuffers.length <= roundedSizeIndex) {\n this._iBuffers.length = roundedSizeIndex + 1;\n }\n var buffer = this._aBuffers[roundedSize];\n if (!buffer) {\n this._aBuffers[roundedSize] = buffer = new ViewableBuffer(roundedSize * this.vertexSize * 4);\n }\n return buffer;\n };\n /**\n * Fetches an index buffer from `this._iBuffers` that can\n * have at least `size` capacity.\n *\n * @param size - minimum required capacity\n * @return - buffer that can fit `size` indices.\n */\n AbstractBatchRenderer.prototype.getIndexBuffer = function (size) {\n // 12 indices is enough for 2 quads\n var roundedP2 = nextPow2(Math.ceil(size / 12));\n var roundedSizeIndex = log2(roundedP2);\n var roundedSize = roundedP2 * 12;\n if (this._iBuffers.length <= roundedSizeIndex) {\n this._iBuffers.length = roundedSizeIndex + 1;\n }\n var buffer = this._iBuffers[roundedSizeIndex];\n if (!buffer) {\n this._iBuffers[roundedSizeIndex] = buffer = new Uint16Array(roundedSize);\n }\n return buffer;\n };\n /**\n * Takes the four batching parameters of `element`, interleaves\n * and pushes them into the batching attribute/index buffers given.\n *\n * It uses these properties: `vertexData` `uvs`, `textureId` and\n * `indicies`. It also uses the \"tint\" of the base-texture, if\n * present.\n *\n * @param {PIXI.DisplayObject} element - element being rendered\n * @param attributeBuffer - attribute buffer.\n * @param indexBuffer - index buffer\n * @param aIndex - number of floats already in the attribute buffer\n * @param iIndex - number of indices already in `indexBuffer`\n */\n AbstractBatchRenderer.prototype.packInterleavedGeometry = function (element, attributeBuffer, indexBuffer, aIndex, iIndex) {\n var uint32View = attributeBuffer.uint32View, float32View = attributeBuffer.float32View;\n var packedVertices = aIndex / this.vertexSize;\n var uvs = element.uvs;\n var indicies = element.indices;\n var vertexData = element.vertexData;\n var textureId = element._texture.baseTexture._batchLocation;\n var alpha = Math.min(element.worldAlpha, 1.0);\n var argb = (alpha < 1.0\n && element._texture.baseTexture.alphaMode)\n ? premultiplyTint(element._tintRGB, alpha)\n : element._tintRGB + (alpha * 255 << 24);\n // lets not worry about tint! for now..\n for (var i = 0; i < vertexData.length; i += 2) {\n float32View[aIndex++] = vertexData[i];\n float32View[aIndex++] = vertexData[i + 1];\n float32View[aIndex++] = uvs[i];\n float32View[aIndex++] = uvs[i + 1];\n uint32View[aIndex++] = argb;\n float32View[aIndex++] = textureId;\n }\n for (var i = 0; i < indicies.length; i++) {\n indexBuffer[iIndex++] = packedVertices + indicies[i];\n }\n };\n /**\n * Pool of `BatchDrawCall` objects that `flush` used\n * to create \"batches\" of the objects being rendered.\n *\n * These are never re-allocated again.\n * Shared between all batch renderers because it can be only one \"flush\" working at the moment.\n *\n * @member {PIXI.BatchDrawCall[]}\n */\n AbstractBatchRenderer._drawCallPool = [];\n /**\n * Pool of `BatchDrawCall` objects that `flush` used\n * to create \"batches\" of the objects being rendered.\n *\n * These are never re-allocated again.\n * Shared between all batch renderers because it can be only one \"flush\" working at the moment.\n *\n * @member {PIXI.BatchTextureArray[]}\n */\n AbstractBatchRenderer._textureArrayPool = [];\n return AbstractBatchRenderer;\n}(ObjectRenderer));\n\n/**\n * Helper that generates batching multi-texture shader. Use it with your new BatchRenderer\n *\n * @memberof PIXI\n */\nvar BatchShaderGenerator = /** @class */ (function () {\n /**\n * @param vertexSrc - Vertex shader\n * @param fragTemplate - Fragment shader template\n */\n function BatchShaderGenerator(vertexSrc, fragTemplate) {\n this.vertexSrc = vertexSrc;\n this.fragTemplate = fragTemplate;\n this.programCache = {};\n this.defaultGroupCache = {};\n if (fragTemplate.indexOf('%count%') < 0) {\n throw new Error('Fragment template must contain \"%count%\".');\n }\n if (fragTemplate.indexOf('%forloop%') < 0) {\n throw new Error('Fragment template must contain \"%forloop%\".');\n }\n }\n BatchShaderGenerator.prototype.generateShader = function (maxTextures) {\n if (!this.programCache[maxTextures]) {\n var sampleValues = new Int32Array(maxTextures);\n for (var i = 0; i < maxTextures; i++) {\n sampleValues[i] = i;\n }\n this.defaultGroupCache[maxTextures] = UniformGroup.from({ uSamplers: sampleValues }, true);\n var fragmentSrc = this.fragTemplate;\n fragmentSrc = fragmentSrc.replace(/%count%/gi, \"\" + maxTextures);\n fragmentSrc = fragmentSrc.replace(/%forloop%/gi, this.generateSampleSrc(maxTextures));\n this.programCache[maxTextures] = new Program(this.vertexSrc, fragmentSrc);\n }\n var uniforms = {\n tint: new Float32Array([1, 1, 1, 1]),\n translationMatrix: new Matrix(),\n default: this.defaultGroupCache[maxTextures],\n };\n return new Shader(this.programCache[maxTextures], uniforms);\n };\n BatchShaderGenerator.prototype.generateSampleSrc = function (maxTextures) {\n var src = '';\n src += '\\n';\n src += '\\n';\n for (var i = 0; i < maxTextures; i++) {\n if (i > 0) {\n src += '\\nelse ';\n }\n if (i < maxTextures - 1) {\n src += \"if(vTextureId < \" + i + \".5)\";\n }\n src += '\\n{';\n src += \"\\n\\tcolor = texture2D(uSamplers[\" + i + \"], vTextureCoord);\";\n src += '\\n}';\n }\n src += '\\n';\n src += '\\n';\n return src;\n };\n return BatchShaderGenerator;\n}());\n\n/**\n * Geometry used to batch standard PIXI content (e.g. Mesh, Sprite, Graphics objects).\n *\n * @memberof PIXI\n */\nvar BatchGeometry = /** @class */ (function (_super) {\n __extends(BatchGeometry, _super);\n /**\n * @param {boolean} [_static=false] - Optimization flag, where `false`\n * is updated every frame, `true` doesn't change frame-to-frame.\n */\n function BatchGeometry(_static) {\n if (_static === void 0) { _static = false; }\n var _this = _super.call(this) || this;\n _this._buffer = new Buffer(null, _static, false);\n _this._indexBuffer = new Buffer(null, _static, true);\n _this.addAttribute('aVertexPosition', _this._buffer, 2, false, TYPES.FLOAT)\n .addAttribute('aTextureCoord', _this._buffer, 2, false, TYPES.FLOAT)\n .addAttribute('aColor', _this._buffer, 4, true, TYPES.UNSIGNED_BYTE)\n .addAttribute('aTextureId', _this._buffer, 1, true, TYPES.FLOAT)\n .addIndex(_this._indexBuffer);\n return _this;\n }\n return BatchGeometry;\n}(Geometry));\n\nvar defaultVertex$3 = \"precision highp float;\\nattribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\nattribute vec4 aColor;\\nattribute float aTextureId;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform vec4 tint;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec4 vColor;\\nvarying float vTextureId;\\n\\nvoid main(void){\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = aTextureCoord;\\n vTextureId = aTextureId;\\n vColor = aColor * tint;\\n}\\n\";\n\nvar defaultFragment$2 = \"varying vec2 vTextureCoord;\\nvarying vec4 vColor;\\nvarying float vTextureId;\\nuniform sampler2D uSamplers[%count%];\\n\\nvoid main(void){\\n vec4 color;\\n %forloop%\\n gl_FragColor = color * vColor;\\n}\\n\";\n\n/** @memberof PIXI */\nvar BatchPluginFactory = /** @class */ (function () {\n function BatchPluginFactory() {\n }\n /**\n * Create a new BatchRenderer plugin for Renderer. this convenience can provide an easy way\n * to extend BatchRenderer with all the necessary pieces.\n * @example\n * const fragment = `\n * varying vec2 vTextureCoord;\n * varying vec4 vColor;\n * varying float vTextureId;\n * uniform sampler2D uSamplers[%count%];\n *\n * void main(void){\n * vec4 color;\n * %forloop%\n * gl_FragColor = vColor * vec4(color.a - color.rgb, color.a);\n * }\n * `;\n * const InvertBatchRenderer = PIXI.BatchPluginFactory.create({ fragment });\n * PIXI.Renderer.registerPlugin('invert', InvertBatchRenderer);\n * const sprite = new PIXI.Sprite();\n * sprite.pluginName = 'invert';\n *\n * @param {object} [options]\n * @param {string} [options.vertex=PIXI.BatchPluginFactory.defaultVertexSrc] - Vertex shader source\n * @param {string} [options.fragment=PIXI.BatchPluginFactory.defaultFragmentTemplate] - Fragment shader template\n * @param {number} [options.vertexSize=6] - Vertex size\n * @param {object} [options.geometryClass=PIXI.BatchGeometry]\n * @return {*} New batch renderer plugin\n */\n BatchPluginFactory.create = function (options) {\n var _a = Object.assign({\n vertex: defaultVertex$3,\n fragment: defaultFragment$2,\n geometryClass: BatchGeometry,\n vertexSize: 6,\n }, options), vertex = _a.vertex, fragment = _a.fragment, vertexSize = _a.vertexSize, geometryClass = _a.geometryClass;\n return /** @class */ (function (_super) {\n __extends(BatchPlugin, _super);\n function BatchPlugin(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.shaderGenerator = new BatchShaderGenerator(vertex, fragment);\n _this.geometryClass = geometryClass;\n _this.vertexSize = vertexSize;\n return _this;\n }\n return BatchPlugin;\n }(AbstractBatchRenderer));\n };\n Object.defineProperty(BatchPluginFactory, \"defaultVertexSrc\", {\n /**\n * The default vertex shader source\n *\n * @readonly\n */\n get: function () {\n return defaultVertex$3;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BatchPluginFactory, \"defaultFragmentTemplate\", {\n /**\n * The default fragment shader source\n *\n * @readonly\n */\n get: function () {\n return defaultFragment$2;\n },\n enumerable: false,\n configurable: true\n });\n return BatchPluginFactory;\n}());\n// Setup the default BatchRenderer plugin, this is what\n// we'll actually export at the root level\nvar BatchRenderer = BatchPluginFactory.create();\n\n/**\n * @memberof PIXI\n * @namespace resources\n * @see PIXI\n * @deprecated since 6.0.0\n */\nvar resources = {};\nvar _loop_1 = function (name) {\n Object.defineProperty(resources, name, {\n get: function () {\n deprecation('6.0.0', \"PIXI.systems.\" + name + \" has moved to PIXI.\" + name);\n return _resources[name];\n },\n });\n};\nfor (var name in _resources) {\n _loop_1(name);\n}\n/**\n * @memberof PIXI\n * @namespace systems\n * @see PIXI\n * @deprecated since 6.0.0\n */\nvar systems = {};\nvar _loop_2 = function (name) {\n Object.defineProperty(systems, name, {\n get: function () {\n deprecation('6.0.0', \"PIXI.resources.\" + name + \" has moved to PIXI.\" + name);\n return _systems[name];\n },\n });\n};\nfor (var name in _systems) {\n _loop_2(name);\n}\n\nexport { AbstractBatchRenderer, AbstractMultiResource, AbstractRenderer, ArrayResource, Attribute, BaseImageResource, BaseRenderTexture, BaseTexture, BatchDrawCall, BatchGeometry, BatchPluginFactory, BatchRenderer, BatchShaderGenerator, BatchSystem, BatchTextureArray, Buffer, BufferResource, CanvasResource, ContextSystem, CubeResource, Filter, FilterState, FilterSystem, Framebuffer, FramebufferSystem, GLFramebuffer, GLProgram, GLTexture, Geometry, GeometrySystem, IGLUniformData, INSTALLED, ImageBitmapResource, ImageResource, MaskData, MaskSystem, ObjectRenderer, Program, ProjectionSystem, Quad, QuadUv, RenderTexture, RenderTexturePool, RenderTextureSystem, Renderer, Resource, SVGResource, ScissorSystem, Shader, ShaderSystem, SpriteMaskFilter, State, StateSystem, StencilSystem, System, Texture, TextureGCSystem, TextureMatrix, TextureSystem, TextureUvs, UniformGroup, VideoResource, ViewableBuffer, autoDetectRenderer, autoDetectResource, checkMaxIfStatementsInShader, createUBOElements, defaultFilterVertex, defaultVertex$2 as defaultVertex, generateProgram, generateUniformBufferSync, getTestContext, getUBOData, resources, systems, uniformParsers };\n//# sourceMappingURL=core.js.map\n","/*!\n * @pixi/display - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/display is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nimport { Rectangle, RAD_TO_DEG, DEG_TO_RAD, Transform } from '@pixi/math';\nimport { EventEmitter, removeItems } from '@pixi/utils';\n\n/**\n * Sets the default value for the container property 'sortableChildren'.\n * If set to true, the container will sort its children by zIndex value\n * when updateTransform() is called, or manually if sortChildren() is called.\n *\n * This actually changes the order of elements in the array, so should be treated\n * as a basic solution that is not performant compared to other solutions,\n * such as @link https://github.com/pixijs/pixi-display\n *\n * Also be aware of that this may not work nicely with the addChildAt() function,\n * as the zIndex sorting may cause the child to automatically sorted to another position.\n *\n * @static\n * @constant\n * @name SORTABLE_CHILDREN\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\nsettings.SORTABLE_CHILDREN = false;\n\n/**\n * 'Builder' pattern for bounds rectangles.\n *\n * This could be called an Axis-Aligned Bounding Box.\n * It is not an actual shape. It is a mutable thing; no 'EMPTY' or those kind of problems.\n *\n * @memberof PIXI\n */\nvar Bounds = /** @class */ (function () {\n function Bounds() {\n this.minX = Infinity;\n this.minY = Infinity;\n this.maxX = -Infinity;\n this.maxY = -Infinity;\n this.rect = null;\n this.updateID = -1;\n }\n /**\n * Checks if bounds are empty.\n *\n * @return - True if empty.\n */\n Bounds.prototype.isEmpty = function () {\n return this.minX > this.maxX || this.minY > this.maxY;\n };\n /** Clears the bounds and resets. */\n Bounds.prototype.clear = function () {\n this.minX = Infinity;\n this.minY = Infinity;\n this.maxX = -Infinity;\n this.maxY = -Infinity;\n };\n /**\n * Can return Rectangle.EMPTY constant, either construct new rectangle, either use your rectangle\n * It is not guaranteed that it will return tempRect\n *\n * @param rect - Temporary object will be used if AABB is not empty\n * @returns - A rectangle of the bounds\n */\n Bounds.prototype.getRectangle = function (rect) {\n if (this.minX > this.maxX || this.minY > this.maxY) {\n return Rectangle.EMPTY;\n }\n rect = rect || new Rectangle(0, 0, 1, 1);\n rect.x = this.minX;\n rect.y = this.minY;\n rect.width = this.maxX - this.minX;\n rect.height = this.maxY - this.minY;\n return rect;\n };\n /**\n * This function should be inlined when its possible.\n *\n * @param point - The point to add.\n */\n Bounds.prototype.addPoint = function (point) {\n this.minX = Math.min(this.minX, point.x);\n this.maxX = Math.max(this.maxX, point.x);\n this.minY = Math.min(this.minY, point.y);\n this.maxY = Math.max(this.maxY, point.y);\n };\n /** Adds a point, after transformed. This should be inlined when its possible. */\n Bounds.prototype.addPointMatrix = function (matrix, point) {\n var a = matrix.a, b = matrix.b, c = matrix.c, d = matrix.d, tx = matrix.tx, ty = matrix.ty;\n var x = (a * point.x) + (c * point.y) + tx;\n var y = (b * point.x) + (d * point.y) + ty;\n this.minX = Math.min(this.minX, x);\n this.maxX = Math.max(this.maxX, x);\n this.minY = Math.min(this.minY, y);\n this.maxY = Math.max(this.maxY, y);\n };\n /**\n * Adds a quad, not transformed\n *\n * @param vertices - The verts to add.\n */\n Bounds.prototype.addQuad = function (vertices) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n var x = vertices[0];\n var y = vertices[1];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = vertices[2];\n y = vertices[3];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = vertices[4];\n y = vertices[5];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = vertices[6];\n y = vertices[7];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Adds sprite frame, transformed.\n *\n * @param transform - transform to apply\n * @param x0 - left X of frame\n * @param y0 - top Y of frame\n * @param x1 - right X of frame\n * @param y1 - bottom Y of frame\n */\n Bounds.prototype.addFrame = function (transform, x0, y0, x1, y1) {\n this.addFrameMatrix(transform.worldTransform, x0, y0, x1, y1);\n };\n /**\n * Adds sprite frame, multiplied by matrix\n *\n * @param matrix - matrix to apply\n * @param x0 - left X of frame\n * @param y0 - top Y of frame\n * @param x1 - right X of frame\n * @param y1 - bottom Y of frame\n */\n Bounds.prototype.addFrameMatrix = function (matrix, x0, y0, x1, y1) {\n var a = matrix.a;\n var b = matrix.b;\n var c = matrix.c;\n var d = matrix.d;\n var tx = matrix.tx;\n var ty = matrix.ty;\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n var x = (a * x0) + (c * y0) + tx;\n var y = (b * x0) + (d * y0) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = (a * x1) + (c * y0) + tx;\n y = (b * x1) + (d * y0) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = (a * x0) + (c * y1) + tx;\n y = (b * x0) + (d * y1) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n x = (a * x1) + (c * y1) + tx;\n y = (b * x1) + (d * y1) + ty;\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Adds screen vertices from array\n *\n * @param vertexData - calculated vertices\n * @param beginOffset - begin offset\n * @param endOffset - end offset, excluded\n */\n Bounds.prototype.addVertexData = function (vertexData, beginOffset, endOffset) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n for (var i = beginOffset; i < endOffset; i += 2) {\n var x = vertexData[i];\n var y = vertexData[i + 1];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n }\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Add an array of mesh vertices\n *\n * @param transform - mesh transform\n * @param vertices - mesh coordinates in array\n * @param beginOffset - begin offset\n * @param endOffset - end offset, excluded\n */\n Bounds.prototype.addVertices = function (transform, vertices, beginOffset, endOffset) {\n this.addVerticesMatrix(transform.worldTransform, vertices, beginOffset, endOffset);\n };\n /**\n * Add an array of mesh vertices.\n *\n * @param matrix - mesh matrix\n * @param vertices - mesh coordinates in array\n * @param beginOffset - begin offset\n * @param endOffset - end offset, excluded\n * @param padX - x padding\n * @param padY - y padding\n */\n Bounds.prototype.addVerticesMatrix = function (matrix, vertices, beginOffset, endOffset, padX, padY) {\n if (padX === void 0) { padX = 0; }\n if (padY === void 0) { padY = padX; }\n var a = matrix.a;\n var b = matrix.b;\n var c = matrix.c;\n var d = matrix.d;\n var tx = matrix.tx;\n var ty = matrix.ty;\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n for (var i = beginOffset; i < endOffset; i += 2) {\n var rawX = vertices[i];\n var rawY = vertices[i + 1];\n var x = (a * rawX) + (c * rawY) + tx;\n var y = (d * rawY) + (b * rawX) + ty;\n minX = Math.min(minX, x - padX);\n maxX = Math.max(maxX, x + padX);\n minY = Math.min(minY, y - padY);\n maxY = Math.max(maxY, y + padY);\n }\n this.minX = minX;\n this.minY = minY;\n this.maxX = maxX;\n this.maxY = maxY;\n };\n /**\n * Adds other {@link Bounds}.\n *\n * @param bounds - The Bounds to be added\n */\n Bounds.prototype.addBounds = function (bounds) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n this.minX = bounds.minX < minX ? bounds.minX : minX;\n this.minY = bounds.minY < minY ? bounds.minY : minY;\n this.maxX = bounds.maxX > maxX ? bounds.maxX : maxX;\n this.maxY = bounds.maxY > maxY ? bounds.maxY : maxY;\n };\n /**\n * Adds other Bounds, masked with Bounds.\n *\n * @param bounds - The Bounds to be added.\n * @param mask - TODO\n */\n Bounds.prototype.addBoundsMask = function (bounds, mask) {\n var _minX = bounds.minX > mask.minX ? bounds.minX : mask.minX;\n var _minY = bounds.minY > mask.minY ? bounds.minY : mask.minY;\n var _maxX = bounds.maxX < mask.maxX ? bounds.maxX : mask.maxX;\n var _maxY = bounds.maxY < mask.maxY ? bounds.maxY : mask.maxY;\n if (_minX <= _maxX && _minY <= _maxY) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n this.minX = _minX < minX ? _minX : minX;\n this.minY = _minY < minY ? _minY : minY;\n this.maxX = _maxX > maxX ? _maxX : maxX;\n this.maxY = _maxY > maxY ? _maxY : maxY;\n }\n };\n /**\n * Adds other Bounds, multiplied by matrix. Bounds shouldn't be empty.\n *\n * @param bounds - other bounds\n * @param matrix - multiplicator\n */\n Bounds.prototype.addBoundsMatrix = function (bounds, matrix) {\n this.addFrameMatrix(matrix, bounds.minX, bounds.minY, bounds.maxX, bounds.maxY);\n };\n /**\n * Adds other Bounds, masked with Rectangle.\n *\n * @param bounds - TODO\n * @param area - TODO\n */\n Bounds.prototype.addBoundsArea = function (bounds, area) {\n var _minX = bounds.minX > area.x ? bounds.minX : area.x;\n var _minY = bounds.minY > area.y ? bounds.minY : area.y;\n var _maxX = bounds.maxX < area.x + area.width ? bounds.maxX : (area.x + area.width);\n var _maxY = bounds.maxY < area.y + area.height ? bounds.maxY : (area.y + area.height);\n if (_minX <= _maxX && _minY <= _maxY) {\n var minX = this.minX;\n var minY = this.minY;\n var maxX = this.maxX;\n var maxY = this.maxY;\n this.minX = _minX < minX ? _minX : minX;\n this.minY = _minY < minY ? _minY : minY;\n this.maxX = _maxX > maxX ? _maxX : maxX;\n this.maxY = _maxY > maxY ? _maxY : maxY;\n }\n };\n /**\n * Pads bounds object, making it grow in all directions.\n * If paddingY is omitted, both paddingX and paddingY will be set to paddingX.\n *\n * @param paddingX - The horizontal padding amount.\n * @param paddingY - The vertical padding amount.\n */\n Bounds.prototype.pad = function (paddingX, paddingY) {\n if (paddingX === void 0) { paddingX = 0; }\n if (paddingY === void 0) { paddingY = paddingX; }\n if (!this.isEmpty()) {\n this.minX -= paddingX;\n this.maxX += paddingX;\n this.minY -= paddingY;\n this.maxY += paddingY;\n }\n };\n /**\n * Adds padded frame. (x0, y0) should be strictly less than (x1, y1)\n *\n * @param x0 - left X of frame\n * @param y0 - top Y of frame\n * @param x1 - right X of frame\n * @param y1 - bottom Y of frame\n * @param padX - padding X\n * @param padY - padding Y\n */\n Bounds.prototype.addFramePad = function (x0, y0, x1, y1, padX, padY) {\n x0 -= padX;\n y0 -= padY;\n x1 += padX;\n y1 += padY;\n this.minX = this.minX < x0 ? this.minX : x0;\n this.maxX = this.maxX > x1 ? this.maxX : x1;\n this.minY = this.minY < y0 ? this.minY : y0;\n this.maxY = this.maxY > y1 ? this.maxY : y1;\n };\n return Bounds;\n}());\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * The base class for all objects that are rendered on the screen.\n *\n * This is an abstract class and can not be used on its own; rather it should be extended.\n *\n * ## Display objects implemented in PixiJS\n *\n * | Display Object | Description |\n * | ------------------------------- | --------------------------------------------------------------------- |\n * | {@link PIXI.Container} | Adds support for `children` to DisplayObject |\n * | {@link PIXI.Graphics} | Shape-drawing display object similar to the Canvas API |\n * | {@link PIXI.Sprite} | Draws textures (i.e. images) |\n * | {@link PIXI.Text} | Draws text using the Canvas API internally |\n * | {@link PIXI.BitmapText} | More scaleable solution for text rendering, reusing glyph textures |\n * | {@link PIXI.TilingSprite} | Draws textures/images in a tiled fashion |\n * | {@link PIXI.AnimatedSprite} | Draws an animation of multiple images |\n * | {@link PIXI.Mesh} | Provides a lower-level API for drawing meshes with custom data |\n * | {@link PIXI.NineSlicePlane} | Mesh-related |\n * | {@link PIXI.SimpleMesh} | v4-compatible mesh |\n * | {@link PIXI.SimplePlane} | Mesh-related |\n * | {@link PIXI.SimpleRope} | Mesh-related |\n *\n * ## Transforms\n *\n * The [transform]{@link DisplayObject#transform} of a display object describes the projection from its\n * local coordinate space to its parent's local coordinate space. The following properties are derived\n * from the transform:\n *\n * <table>\n * <thead>\n * <tr>\n * <th>Property</th>\n * <th>Description</th>\n * </tr>\n * </thead>\n * <tbody>\n * <tr>\n * <td>[pivot]{@link PIXI.DisplayObject#pivot}</td>\n * <td>\n * Invariant under rotation, scaling, and skewing. The projection of into the parent's space of the pivot\n * is equal to position, regardless of the other three transformations. In other words, It is the center of\n * rotation, scaling, and skewing.\n * </td>\n * </tr>\n * <tr>\n * <td>[position]{@link PIXI.DisplayObject#position}</td>\n * <td>\n * Translation. This is the position of the [pivot]{@link PIXI.DisplayObject#pivot} in the parent's local\n * space. The default value of the pivot is the origin (0,0). If the top-left corner of your display object\n * is (0,0) in its local space, then the position will be its top-left corner in the parent's local space.\n * </td>\n * </tr>\n * <tr>\n * <td>[scale]{@link PIXI.DisplayObject#scale}</td>\n * <td>\n * Scaling. This will stretch (or compress) the display object's projection. The scale factors are along the\n * local coordinate axes. In other words, the display object is scaled before rotated or skewed. The center\n * of scaling is the [pivot]{@link PIXI.DisplayObject#pivot}.\n * </td>\n * </tr>\n * <tr>\n * <td>[rotation]{@link PIXI.DisplayObject#rotation}</td>\n * <td>\n * Rotation. This will rotate the display object's projection by this angle (in radians).\n * </td>\n * </tr>\n * <tr>\n * <td>[skew]{@link PIXI.DisplayObject#skew}</td>\n * <td>\n * <p>Skewing. This can be used to deform a rectangular display object into a parallelogram.</p>\n * <p>\n * In PixiJS, skew has a slightly different behaviour than the conventional meaning. It can be\n * thought of the net rotation applied to the coordinate axes (separately). For example, if \"skew.x\" is\n * ⍺ and \"skew.y\" is β, then the line x = 0 will be rotated by ⍺ (y = -x*cot⍺) and the line y = 0 will be\n * rotated by β (y = x*tanβ). A line y = x*tanϴ (i.e. a line at angle ϴ to the x-axis in local-space) will\n * be rotated by an angle between ⍺ and β.\n * </p>\n * <p>\n * It can be observed that if skew is applied equally to both axes, then it will be equivalent to applying\n * a rotation. Indeed, if \"skew.x\" = -ϴ and \"skew.y\" = ϴ, it will produce an equivalent of \"rotation\" = ϴ.\n * </p>\n * <p>\n * Another quite interesting observation is that \"skew.x\", \"skew.y\", rotation are communtative operations. Indeed,\n * because rotation is essentially a careful combination of the two.\n * </p>\n * </td>\n * </tr>\n * <tr>\n * <td>angle</td>\n * <td>Rotation. This is an alias for [rotation]{@link PIXI.DisplayObject#rotation}, but in degrees.</td>\n * </tr>\n * <tr>\n * <td>x</td>\n * <td>Translation. This is an alias for position.x!</td>\n * </tr>\n * <tr>\n * <td>y</td>\n * <td>Translation. This is an alias for position.y!</td>\n * </tr>\n * <tr>\n * <td>width</td>\n * <td>\n * Implemented in [Container]{@link PIXI.Container}. Scaling. The width property calculates scale.x by dividing\n * the \"requested\" width by the local bounding box width. It is indirectly an abstraction over scale.x, and there\n * is no concept of user-defined width.\n * </td>\n * </tr>\n * <tr>\n * <td>height</td>\n * <td>\n * Implemented in [Container]{@link PIXI.Container}. Scaling. The height property calculates scale.y by dividing\n * the \"requested\" height by the local bounding box height. It is indirectly an abstraction over scale.y, and there\n * is no concept of user-defined height.\n * </td>\n * </tr>\n * </tbody>\n * </table>\n *\n * ## Bounds\n *\n * The bounds of a display object is defined by the minimum axis-aligned rectangle in world space that can fit\n * around it. The abstract `calculateBounds` method is responsible for providing it (and it should use the\n * `worldTransform` to calculate in world space).\n *\n * There are a few additional types of bounding boxes:\n *\n * | Bounds | Description |\n * | --------------------- | ---------------------------------------------------------------------------------------- |\n * | World Bounds | This is synonymous is the regular bounds described above. See `getBounds()`. |\n * | Local Bounds | This the axis-aligned bounding box in the parent's local space. See `getLocalBounds()`. |\n * | Render Bounds | The bounds, but including extra rendering effects like filter padding. |\n * | Projected Bounds | The bounds of the projected display object onto the screen. Usually equals world bounds. |\n * | Relative Bounds | The bounds of a display object when projected onto a ancestor's (or parent's) space. |\n * | Natural Bounds | The bounds of an object in its own local space (not parent's space, like in local bounds)|\n * | Content Bounds | The natural bounds when excluding all children of a `Container`. |\n *\n * ### calculateBounds\n *\n * [Container]{@link Container} already implements `calculateBounds` in a manner that includes children.\n *\n * But for a non-Container display object, the `calculateBounds` method must be overridden in order for `getBounds` and\n * `getLocalBounds` to work. This method must write the bounds into `this._bounds`.\n *\n * Generally, the following technique works for most simple cases: take the list of points\n * forming the \"hull\" of the object (i.e. outline of the object's shape), and then add them\n * using {@link PIXI.Bounds#addPointMatrix}.\n *\n * ```js\n * calculateBounds(): void\n * {\n * const points = [...];\n *\n * for (let i = 0, j = points.length; i < j; i++)\n * {\n * this._bounds.addPointMatrix(this.worldTransform, points[i]);\n * }\n * }\n * ```\n *\n * You can optimize this for a large number of points by using {@link PIXI.Bounds#addVerticesMatrix} to pass them\n * in one array together.\n *\n * ## Alpha\n *\n * This alpha sets a display object's **relative opacity** w.r.t its parent. For example, if the alpha of a display\n * object is 0.5 and its parent's alpha is 0.5, then it will be rendered with 25% opacity (assuming alpha is not\n * applied on any ancestor further up the chain).\n *\n * The alpha with which the display object will be rendered is called the [worldAlpha]{@link PIXI.DisplayObject#worldAlpha}.\n *\n * ## Renderable vs Visible\n *\n * The `renderable` and `visible` properties can be used to prevent a display object from being rendered to the\n * screen. However, there is a subtle difference between the two. When using `renderable`, the transforms of the display\n * object (and its children subtree) will continue to be calculated. When using `visible`, the transforms will not\n * be calculated.\n *\n * It is recommended that applications use the `renderable` property for culling. See\n * [@pixi-essentials/cull]{@link https://www.npmjs.com/package/@pixi-essentials/cull} or\n * [pixi-cull]{@link https://www.npmjs.com/package/pixi-cull} for more details.\n *\n * Otherwise, to prevent an object from rendering in the general-purpose sense - `visible` is the property to use. This\n * one is also better in terms of performance.\n *\n * @memberof PIXI\n */\nvar DisplayObject = /** @class */ (function (_super) {\n __extends(DisplayObject, _super);\n function DisplayObject() {\n var _this = _super.call(this) || this;\n _this.tempDisplayObjectParent = null;\n // TODO: need to create Transform from factory\n _this.transform = new Transform();\n _this.alpha = 1;\n _this.visible = true;\n _this.renderable = true;\n _this.cullable = false;\n _this.cullArea = null;\n _this.parent = null;\n _this.worldAlpha = 1;\n _this._lastSortedIndex = 0;\n _this._zIndex = 0;\n _this.filterArea = null;\n _this.filters = null;\n _this._enabledFilters = null;\n _this._bounds = new Bounds();\n _this._localBounds = null;\n _this._boundsID = 0;\n _this._boundsRect = null;\n _this._localBoundsRect = null;\n _this._mask = null;\n _this._maskRefCount = 0;\n _this._destroyed = false;\n _this.isSprite = false;\n _this.isMask = false;\n return _this;\n }\n /**\n * Mixes all enumerable properties and methods from a source object to DisplayObject.\n *\n * @param source - The source of properties and methods to mix in.\n */\n DisplayObject.mixin = function (source) {\n // in ES8/ES2017, this would be really easy:\n // Object.defineProperties(DisplayObject.prototype, Object.getOwnPropertyDescriptors(source));\n // get all the enumerable property keys\n var keys = Object.keys(source);\n // loop through properties\n for (var i = 0; i < keys.length; ++i) {\n var propertyName = keys[i];\n // Set the property using the property descriptor - this works for accessors and normal value properties\n Object.defineProperty(DisplayObject.prototype, propertyName, Object.getOwnPropertyDescriptor(source, propertyName));\n }\n };\n Object.defineProperty(DisplayObject.prototype, \"destroyed\", {\n /**\n * Fired when this DisplayObject is added to a Container.\n *\n * @instance\n * @event added\n * @param {PIXI.Container} container - The container added to.\n */\n /**\n * Fired when this DisplayObject is removed from a Container.\n *\n * @instance\n * @event removed\n * @param {PIXI.Container} container - The container removed from.\n */\n /**\n * Fired when this DisplayObject is destroyed.\n *\n * @instance\n * @event destroyed\n */\n /** Readonly flag for destroyed display objects. */\n get: function () {\n return this._destroyed;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Recursively updates transform of all objects from the root to this one\n * internal function for toLocal()\n */\n DisplayObject.prototype._recursivePostUpdateTransform = function () {\n if (this.parent) {\n this.parent._recursivePostUpdateTransform();\n this.transform.updateTransform(this.parent.transform);\n }\n else {\n this.transform.updateTransform(this._tempDisplayObjectParent.transform);\n }\n };\n /**\n * Updates the object transform for rendering.\n *\n * TODO - Optimization pass!\n */\n DisplayObject.prototype.updateTransform = function () {\n this._boundsID++;\n this.transform.updateTransform(this.parent.transform);\n // multiply the alphas..\n this.worldAlpha = this.alpha * this.parent.worldAlpha;\n };\n /**\n * Calculates and returns the (world) bounds of the display object as a [Rectangle]{@link PIXI.Rectangle}.\n *\n * This method is expensive on containers with a large subtree (like the stage). This is because the bounds\n * of a container depend on its children's bounds, which recursively causes all bounds in the subtree to\n * be recalculated. The upside, however, is that calling `getBounds` once on a container will indeed update\n * the bounds of all children (the whole subtree, in fact). This side effect should be exploited by using\n * `displayObject._bounds.getRectangle()` when traversing through all the bounds in a scene graph. Otherwise,\n * calling `getBounds` on each object in a subtree will cause the total cost to increase quadratically as\n * its height increases.\n *\n * * The transforms of all objects in a container's **subtree** and of all **ancestors** are updated.\n * * The world bounds of all display objects in a container's **subtree** will also be recalculated.\n *\n * The `_bounds` object stores the last calculation of the bounds. You can use to entirely skip bounds\n * calculation if needed.\n *\n * ```js\n * const lastCalculatedBounds = displayObject._bounds.getRectangle(optionalRect);\n * ```\n *\n * Do know that usage of `getLocalBounds` can corrupt the `_bounds` of children (the whole subtree, actually). This\n * is a known issue that has not been solved. See [getLocalBounds]{@link PIXI.DisplayObject#getLocalBounds} for more\n * details.\n *\n * `getBounds` should be called with `skipUpdate` equal to `true` in a render() call. This is because the transforms\n * are guaranteed to be update-to-date. In fact, recalculating inside a render() call may cause corruption in certain\n * cases.\n *\n * @param skipUpdate - Setting to `true` will stop the transforms of the scene graph from\n * being updated. This means the calculation returned MAY be out of date BUT will give you a\n * nice performance boost.\n * @param rect - Optional rectangle to store the result of the bounds calculation.\n * @return - The minimum axis-aligned rectangle in world space that fits around this object.\n */\n DisplayObject.prototype.getBounds = function (skipUpdate, rect) {\n if (!skipUpdate) {\n if (!this.parent) {\n this.parent = this._tempDisplayObjectParent;\n this.updateTransform();\n this.parent = null;\n }\n else {\n this._recursivePostUpdateTransform();\n this.updateTransform();\n }\n }\n if (this._bounds.updateID !== this._boundsID) {\n this.calculateBounds();\n this._bounds.updateID = this._boundsID;\n }\n if (!rect) {\n if (!this._boundsRect) {\n this._boundsRect = new Rectangle();\n }\n rect = this._boundsRect;\n }\n return this._bounds.getRectangle(rect);\n };\n /**\n * Retrieves the local bounds of the displayObject as a rectangle object.\n *\n * @param rect - Optional rectangle to store the result of the bounds calculation.\n * @return - The rectangular bounding area.\n */\n DisplayObject.prototype.getLocalBounds = function (rect) {\n if (!rect) {\n if (!this._localBoundsRect) {\n this._localBoundsRect = new Rectangle();\n }\n rect = this._localBoundsRect;\n }\n if (!this._localBounds) {\n this._localBounds = new Bounds();\n }\n var transformRef = this.transform;\n var parentRef = this.parent;\n this.parent = null;\n this.transform = this._tempDisplayObjectParent.transform;\n var worldBounds = this._bounds;\n var worldBoundsID = this._boundsID;\n this._bounds = this._localBounds;\n var bounds = this.getBounds(false, rect);\n this.parent = parentRef;\n this.transform = transformRef;\n this._bounds = worldBounds;\n this._bounds.updateID += this._boundsID - worldBoundsID; // reflect side-effects\n return bounds;\n };\n /**\n * Calculates the global position of the display object.\n *\n * @param position - The world origin to calculate from.\n * @param point - A Point object in which to store the value, optional\n * (otherwise will create a new Point).\n * @param skipUpdate - Should we skip the update transform.\n * @return - A point object representing the position of this object.\n */\n DisplayObject.prototype.toGlobal = function (position, point, skipUpdate) {\n if (skipUpdate === void 0) { skipUpdate = false; }\n if (!skipUpdate) {\n this._recursivePostUpdateTransform();\n // this parent check is for just in case the item is a root object.\n // If it is we need to give it a temporary parent so that displayObjectUpdateTransform works correctly\n // this is mainly to avoid a parent check in the main loop. Every little helps for performance :)\n if (!this.parent) {\n this.parent = this._tempDisplayObjectParent;\n this.displayObjectUpdateTransform();\n this.parent = null;\n }\n else {\n this.displayObjectUpdateTransform();\n }\n }\n // don't need to update the lot\n return this.worldTransform.apply(position, point);\n };\n /**\n * Calculates the local position of the display object relative to another point.\n *\n * @param position - The world origin to calculate from.\n * @param from - The DisplayObject to calculate the global position from.\n * @param point - A Point object in which to store the value, optional\n * (otherwise will create a new Point).\n * @param skipUpdate - Should we skip the update transform\n * @return - A point object representing the position of this object\n */\n DisplayObject.prototype.toLocal = function (position, from, point, skipUpdate) {\n if (from) {\n position = from.toGlobal(position, point, skipUpdate);\n }\n if (!skipUpdate) {\n this._recursivePostUpdateTransform();\n // this parent check is for just in case the item is a root object.\n // If it is we need to give it a temporary parent so that displayObjectUpdateTransform works correctly\n // this is mainly to avoid a parent check in the main loop. Every little helps for performance :)\n if (!this.parent) {\n this.parent = this._tempDisplayObjectParent;\n this.displayObjectUpdateTransform();\n this.parent = null;\n }\n else {\n this.displayObjectUpdateTransform();\n }\n }\n // simply apply the matrix..\n return this.worldTransform.applyInverse(position, point);\n };\n /**\n * Set the parent Container of this DisplayObject.\n *\n * @param container - The Container to add this DisplayObject to.\n * @return - The Container that this DisplayObject was added to.\n */\n DisplayObject.prototype.setParent = function (container) {\n if (!container || !container.addChild) {\n throw new Error('setParent: Argument must be a Container');\n }\n container.addChild(this);\n return container;\n };\n /**\n * Convenience function to set the position, scale, skew and pivot at once.\n *\n * @param x - The X position\n * @param y - The Y position\n * @param scaleX - The X scale value\n * @param scaleY - The Y scale value\n * @param rotation - The rotation\n * @param skewX - The X skew value\n * @param skewY - The Y skew value\n * @param pivotX - The X pivot value\n * @param pivotY - The Y pivot value\n * @return - The DisplayObject instance\n */\n DisplayObject.prototype.setTransform = function (x, y, scaleX, scaleY, rotation, skewX, skewY, pivotX, pivotY) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (scaleX === void 0) { scaleX = 1; }\n if (scaleY === void 0) { scaleY = 1; }\n if (rotation === void 0) { rotation = 0; }\n if (skewX === void 0) { skewX = 0; }\n if (skewY === void 0) { skewY = 0; }\n if (pivotX === void 0) { pivotX = 0; }\n if (pivotY === void 0) { pivotY = 0; }\n this.position.x = x;\n this.position.y = y;\n this.scale.x = !scaleX ? 1 : scaleX;\n this.scale.y = !scaleY ? 1 : scaleY;\n this.rotation = rotation;\n this.skew.x = skewX;\n this.skew.y = skewY;\n this.pivot.x = pivotX;\n this.pivot.y = pivotY;\n return this;\n };\n /**\n * Base destroy method for generic display objects. This will automatically\n * remove the display object from its parent Container as well as remove\n * all current event listeners and internal references. Do not use a DisplayObject\n * after calling `destroy()`.\n */\n DisplayObject.prototype.destroy = function (_options) {\n if (this.parent) {\n this.parent.removeChild(this);\n }\n this.emit('destroyed');\n this.removeAllListeners();\n this.transform = null;\n this.parent = null;\n this._bounds = null;\n this.mask = null;\n this.cullArea = null;\n this.filters = null;\n this.filterArea = null;\n this.hitArea = null;\n this.interactive = false;\n this.interactiveChildren = false;\n this._destroyed = true;\n };\n Object.defineProperty(DisplayObject.prototype, \"_tempDisplayObjectParent\", {\n /**\n * @protected\n * @member {PIXI.Container}\n */\n get: function () {\n if (this.tempDisplayObjectParent === null) {\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n this.tempDisplayObjectParent = new TemporaryDisplayObject();\n }\n return this.tempDisplayObjectParent;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Used in Renderer, cacheAsBitmap and other places where you call an `updateTransform` on root\n *\n * ```\n * const cacheParent = elem.enableTempParent();\n * elem.updateTransform();\n * elem.disableTempParent(cacheParent);\n * ```\n *\n * @returns - current parent\n */\n DisplayObject.prototype.enableTempParent = function () {\n var myParent = this.parent;\n this.parent = this._tempDisplayObjectParent;\n return myParent;\n };\n /**\n * Pair method for `enableTempParent`\n *\n * @param cacheParent - Actual parent of element\n */\n DisplayObject.prototype.disableTempParent = function (cacheParent) {\n this.parent = cacheParent;\n };\n Object.defineProperty(DisplayObject.prototype, \"x\", {\n /**\n * The position of the displayObject on the x axis relative to the local coordinates of the parent.\n * An alias to position.x\n */\n get: function () {\n return this.position.x;\n },\n set: function (value) {\n this.transform.position.x = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"y\", {\n /**\n * The position of the displayObject on the y axis relative to the local coordinates of the parent.\n * An alias to position.y\n */\n get: function () {\n return this.position.y;\n },\n set: function (value) {\n this.transform.position.y = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"worldTransform\", {\n /**\n * Current transform of the object based on world (parent) factors.\n *\n * @readonly\n */\n get: function () {\n return this.transform.worldTransform;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"localTransform\", {\n /**\n * Current transform of the object based on local factors: position, scale, other stuff.\n *\n * @readonly\n */\n get: function () {\n return this.transform.localTransform;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"position\", {\n /**\n * The coordinate of the object relative to the local coordinates of the parent.\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.position;\n },\n set: function (value) {\n this.transform.position.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"scale\", {\n /**\n * The scale factors of this object along the local coordinate axes.\n *\n * The default scale is (1, 1).\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.scale;\n },\n set: function (value) {\n this.transform.scale.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"pivot\", {\n /**\n * The center of rotation, scaling, and skewing for this display object in its local space. The `position`\n * is the projection of `pivot` in the parent's local space.\n *\n * By default, the pivot is the origin (0, 0).\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.pivot;\n },\n set: function (value) {\n this.transform.pivot.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"skew\", {\n /**\n * The skew factor for the object in radians.\n *\n * @since PixiJS 4\n */\n get: function () {\n return this.transform.skew;\n },\n set: function (value) {\n this.transform.skew.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"rotation\", {\n /**\n * The rotation of the object in radians.\n * 'rotation' and 'angle' have the same effect on a display object; rotation is in radians, angle is in degrees.\n */\n get: function () {\n return this.transform.rotation;\n },\n set: function (value) {\n this.transform.rotation = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"angle\", {\n /**\n * The angle of the object in degrees.\n * 'rotation' and 'angle' have the same effect on a display object; rotation is in radians, angle is in degrees.\n */\n get: function () {\n return this.transform.rotation * RAD_TO_DEG;\n },\n set: function (value) {\n this.transform.rotation = value * DEG_TO_RAD;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"zIndex\", {\n /**\n * The zIndex of the displayObject.\n *\n * If a container has the sortableChildren property set to true, children will be automatically\n * sorted by zIndex value; a higher value will mean it will be moved towards the end of the array,\n * and thus rendered on top of other display objects within the same container.\n *\n * @see PIXI.Container#sortableChildren\n */\n get: function () {\n return this._zIndex;\n },\n set: function (value) {\n this._zIndex = value;\n if (this.parent) {\n this.parent.sortDirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"worldVisible\", {\n /**\n * Indicates if the object is globally visible.\n *\n * @readonly\n */\n get: function () {\n var item = this;\n do {\n if (!item.visible) {\n return false;\n }\n item = item.parent;\n } while (item);\n return true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(DisplayObject.prototype, \"mask\", {\n /**\n * Sets a mask for the displayObject. A mask is an object that limits the visibility of an\n * object to the shape of the mask applied to it. In PixiJS a regular mask must be a\n * {@link PIXI.Graphics} or a {@link PIXI.Sprite} object. This allows for much faster masking in canvas as it\n * utilities shape clipping. To remove a mask, set this property to `null`.\n *\n * For sprite mask both alpha and red channel are used. Black mask is the same as transparent mask.\n *\n * @example\n * const graphics = new PIXI.Graphics();\n * graphics.beginFill(0xFF3300);\n * graphics.drawRect(50, 250, 100, 100);\n * graphics.endFill();\n *\n * const sprite = new PIXI.Sprite(texture);\n * sprite.mask = graphics;\n *\n * @todo At the moment, PIXI.CanvasRenderer doesn't support PIXI.Sprite as mask.\n */\n get: function () {\n return this._mask;\n },\n set: function (value) {\n if (this._mask === value) {\n return;\n }\n if (this._mask) {\n var maskObject = (this._mask.maskObject || this._mask);\n maskObject._maskRefCount--;\n if (maskObject._maskRefCount === 0) {\n maskObject.renderable = true;\n maskObject.isMask = false;\n }\n }\n this._mask = value;\n if (this._mask) {\n var maskObject = (this._mask.maskObject || this._mask);\n if (maskObject._maskRefCount === 0) {\n maskObject.renderable = false;\n maskObject.isMask = true;\n }\n maskObject._maskRefCount++;\n }\n },\n enumerable: false,\n configurable: true\n });\n return DisplayObject;\n}(EventEmitter));\n/**\n * @private\n */\nvar TemporaryDisplayObject = /** @class */ (function (_super) {\n __extends(TemporaryDisplayObject, _super);\n function TemporaryDisplayObject() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.sortDirty = null;\n return _this;\n }\n return TemporaryDisplayObject;\n}(DisplayObject));\n/**\n * DisplayObject default updateTransform, does not update children of container.\n * Will crash if there's no parent element.\n *\n * @memberof PIXI.DisplayObject#\n * @method displayObjectUpdateTransform\n */\nDisplayObject.prototype.displayObjectUpdateTransform = DisplayObject.prototype.updateTransform;\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\nfunction sortChildren(a, b) {\n if (a.zIndex === b.zIndex) {\n return a._lastSortedIndex - b._lastSortedIndex;\n }\n return a.zIndex - b.zIndex;\n}\n/**\n * Container is a general-purpose display object that holds children. It also adds built-in support for advanced\n * rendering features like masking and filtering.\n *\n * It is the base class of all display objects that act as a container for other objects, including Graphics\n * and Sprite.\n *\n * ```js\n * import { BlurFilter } from '@pixi/filter-blur';\n * import { Container } from '@pixi/display';\n * import { Graphics } from '@pixi/graphics';\n * import { Sprite } from '@pixi/sprite';\n *\n * let container = new Container();\n * let sprite = Sprite.from(\"https://s3-us-west-2.amazonaws.com/s.cdpn.io/693612/IaUrttj.png\");\n *\n * sprite.width = 512;\n * sprite.height = 512;\n *\n * // Adds a sprite as a child to this container. As a result, the sprite will be rendered whenever the container\n * // is rendered.\n * container.addChild(sprite);\n *\n * // Blurs whatever is rendered by the container\n * container.filters = [new BlurFilter()];\n *\n * // Only the contents within a circle at the center should be rendered onto the screen.\n * container.mask = new Graphics()\n * .beginFill(0xffffff)\n * .drawCircle(sprite.width / 2, sprite.height / 2, Math.min(sprite.width, sprite.height) / 2)\n * .endFill();\n * ```\n *\n * @memberof PIXI\n */\nvar Container = /** @class */ (function (_super) {\n __extends(Container, _super);\n function Container() {\n var _this = _super.call(this) || this;\n _this.children = [];\n _this.sortableChildren = settings.SORTABLE_CHILDREN;\n _this.sortDirty = false;\n return _this;\n /**\n * Fired when a DisplayObject is added to this Container.\n *\n * @event PIXI.Container#childAdded\n * @param {PIXI.DisplayObject} child - The child added to the Container.\n * @param {PIXI.Container} container - The container that added the child.\n * @param {number} index - The children's index of the added child.\n */\n /**\n * Fired when a DisplayObject is removed from this Container.\n *\n * @event PIXI.DisplayObject#removedFrom\n * @param {PIXI.DisplayObject} child - The child removed from the Container.\n * @param {PIXI.Container} container - The container that removed removed the child.\n * @param {number} index - The former children's index of the removed child\n */\n }\n /** Overridable method that can be used by Container subclasses whenever the children array is modified. */\n Container.prototype.onChildrenChange = function (_length) {\n /* empty */\n };\n /**\n * Adds one or more children to the container.\n *\n * Multiple items can be added like so: `myContainer.addChild(thingOne, thingTwo, thingThree)`\n *\n * @param {...PIXI.DisplayObject} children - The DisplayObject(s) to add to the container\n * @return {PIXI.DisplayObject} - The first child that was added.\n */\n Container.prototype.addChild = function () {\n var arguments$1 = arguments;\n\n var children = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n children[_i] = arguments$1[_i];\n }\n // if there is only one argument we can bypass looping through the them\n if (children.length > 1) {\n // loop through the array and add all children\n for (var i = 0; i < children.length; i++) {\n // eslint-disable-next-line prefer-rest-params\n this.addChild(children[i]);\n }\n }\n else {\n var child = children[0];\n // if the child has a parent then lets remove it as PixiJS objects can only exist in one place\n if (child.parent) {\n child.parent.removeChild(child);\n }\n child.parent = this;\n this.sortDirty = true;\n // ensure child transform will be recalculated\n child.transform._parentID = -1;\n this.children.push(child);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(this.children.length - 1);\n this.emit('childAdded', child, this, this.children.length - 1);\n child.emit('added', this);\n }\n return children[0];\n };\n /**\n * Adds a child to the container at a specified index. If the index is out of bounds an error will be thrown\n *\n * @param {PIXI.DisplayObject} child - The child to add\n * @param {number} index - The index to place the child in\n * @return {PIXI.DisplayObject} The child that was added.\n */\n Container.prototype.addChildAt = function (child, index) {\n if (index < 0 || index > this.children.length) {\n throw new Error(child + \"addChildAt: The index \" + index + \" supplied is out of bounds \" + this.children.length);\n }\n if (child.parent) {\n child.parent.removeChild(child);\n }\n child.parent = this;\n this.sortDirty = true;\n // ensure child transform will be recalculated\n child.transform._parentID = -1;\n this.children.splice(index, 0, child);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(index);\n child.emit('added', this);\n this.emit('childAdded', child, this, index);\n return child;\n };\n /**\n * Swaps the position of 2 Display Objects within this container.\n *\n * @param child - First display object to swap\n * @param child2 - Second display object to swap\n */\n Container.prototype.swapChildren = function (child, child2) {\n if (child === child2) {\n return;\n }\n var index1 = this.getChildIndex(child);\n var index2 = this.getChildIndex(child2);\n this.children[index1] = child2;\n this.children[index2] = child;\n this.onChildrenChange(index1 < index2 ? index1 : index2);\n };\n /**\n * Returns the index position of a child DisplayObject instance\n *\n * @param child - The DisplayObject instance to identify\n * @return - The index position of the child display object to identify\n */\n Container.prototype.getChildIndex = function (child) {\n var index = this.children.indexOf(child);\n if (index === -1) {\n throw new Error('The supplied DisplayObject must be a child of the caller');\n }\n return index;\n };\n /**\n * Changes the position of an existing child in the display object container\n *\n * @param child - The child DisplayObject instance for which you want to change the index number\n * @param index - The resulting index number for the child display object\n */\n Container.prototype.setChildIndex = function (child, index) {\n if (index < 0 || index >= this.children.length) {\n throw new Error(\"The index \" + index + \" supplied is out of bounds \" + this.children.length);\n }\n var currentIndex = this.getChildIndex(child);\n removeItems(this.children, currentIndex, 1); // remove from old position\n this.children.splice(index, 0, child); // add at new position\n this.onChildrenChange(index);\n };\n /**\n * Returns the child at the specified index\n *\n * @param index - The index to get the child at\n * @return - The child at the given index, if any.\n */\n Container.prototype.getChildAt = function (index) {\n if (index < 0 || index >= this.children.length) {\n throw new Error(\"getChildAt: Index (\" + index + \") does not exist.\");\n }\n return this.children[index];\n };\n /**\n * Removes one or more children from the container.\n *\n * @param {...PIXI.DisplayObject} children - The DisplayObject(s) to remove\n * @return {PIXI.DisplayObject} The first child that was removed.\n */\n Container.prototype.removeChild = function () {\n var arguments$1 = arguments;\n\n var children = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n children[_i] = arguments$1[_i];\n }\n // if there is only one argument we can bypass looping through the them\n if (children.length > 1) {\n // loop through the arguments property and remove all children\n for (var i = 0; i < children.length; i++) {\n this.removeChild(children[i]);\n }\n }\n else {\n var child = children[0];\n var index = this.children.indexOf(child);\n if (index === -1)\n { return null; }\n child.parent = null;\n // ensure child transform will be recalculated\n child.transform._parentID = -1;\n removeItems(this.children, index, 1);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(index);\n child.emit('removed', this);\n this.emit('childRemoved', child, this, index);\n }\n return children[0];\n };\n /**\n * Removes a child from the specified index position.\n *\n * @param index - The index to get the child from\n * @return The child that was removed.\n */\n Container.prototype.removeChildAt = function (index) {\n var child = this.getChildAt(index);\n // ensure child transform will be recalculated..\n child.parent = null;\n child.transform._parentID = -1;\n removeItems(this.children, index, 1);\n // ensure bounds will be recalculated\n this._boundsID++;\n // TODO - lets either do all callbacks or all events.. not both!\n this.onChildrenChange(index);\n child.emit('removed', this);\n this.emit('childRemoved', child, this, index);\n return child;\n };\n /**\n * Removes all children from this container that are within the begin and end indexes.\n *\n * @param beginIndex - The beginning position.\n * @param endIndex - The ending position. Default value is size of the container.\n * @returns - List of removed children\n */\n Container.prototype.removeChildren = function (beginIndex, endIndex) {\n if (beginIndex === void 0) { beginIndex = 0; }\n if (endIndex === void 0) { endIndex = this.children.length; }\n var begin = beginIndex;\n var end = endIndex;\n var range = end - begin;\n var removed;\n if (range > 0 && range <= end) {\n removed = this.children.splice(begin, range);\n for (var i = 0; i < removed.length; ++i) {\n removed[i].parent = null;\n if (removed[i].transform) {\n removed[i].transform._parentID = -1;\n }\n }\n this._boundsID++;\n this.onChildrenChange(beginIndex);\n for (var i = 0; i < removed.length; ++i) {\n removed[i].emit('removed', this);\n this.emit('childRemoved', removed[i], this, i);\n }\n return removed;\n }\n else if (range === 0 && this.children.length === 0) {\n return [];\n }\n throw new RangeError('removeChildren: numeric values are outside the acceptable range.');\n };\n /** Sorts children by zIndex. Previous order is maintained for 2 children with the same zIndex. */\n Container.prototype.sortChildren = function () {\n var sortRequired = false;\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n child._lastSortedIndex = i;\n if (!sortRequired && child.zIndex !== 0) {\n sortRequired = true;\n }\n }\n if (sortRequired && this.children.length > 1) {\n this.children.sort(sortChildren);\n }\n this.sortDirty = false;\n };\n /** Updates the transform on all children of this container for rendering. */\n Container.prototype.updateTransform = function () {\n if (this.sortableChildren && this.sortDirty) {\n this.sortChildren();\n }\n this._boundsID++;\n this.transform.updateTransform(this.parent.transform);\n // TODO: check render flags, how to process stuff here\n this.worldAlpha = this.alpha * this.parent.worldAlpha;\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n if (child.visible) {\n child.updateTransform();\n }\n }\n };\n /**\n * Recalculates the bounds of the container.\n *\n * This implementation will automatically fit the children's bounds into the calculation. Each child's bounds\n * is limited to its mask's bounds or filterArea, if any is applied.\n */\n Container.prototype.calculateBounds = function () {\n this._bounds.clear();\n this._calculateBounds();\n for (var i = 0; i < this.children.length; i++) {\n var child = this.children[i];\n if (!child.visible || !child.renderable) {\n continue;\n }\n child.calculateBounds();\n // TODO: filter+mask, need to mask both somehow\n if (child._mask) {\n var maskObject = (child._mask.maskObject || child._mask);\n maskObject.calculateBounds();\n this._bounds.addBoundsMask(child._bounds, maskObject._bounds);\n }\n else if (child.filterArea) {\n this._bounds.addBoundsArea(child._bounds, child.filterArea);\n }\n else {\n this._bounds.addBounds(child._bounds);\n }\n }\n this._bounds.updateID = this._boundsID;\n };\n /**\n * Retrieves the local bounds of the displayObject as a rectangle object.\n *\n * Calling `getLocalBounds` may invalidate the `_bounds` of the whole subtree below. If using it inside a render()\n * call, it is advised to call `getBounds()` immediately after to recalculate the world bounds of the subtree.\n *\n * @param rect - Optional rectangle to store the result of the bounds calculation.\n * @param skipChildrenUpdate - Setting to `true` will stop re-calculation of children transforms,\n * it was default behaviour of pixi 4.0-5.2 and caused many problems to users.\n * @return - The rectangular bounding area.\n */\n Container.prototype.getLocalBounds = function (rect, skipChildrenUpdate) {\n if (skipChildrenUpdate === void 0) { skipChildrenUpdate = false; }\n var result = _super.prototype.getLocalBounds.call(this, rect);\n if (!skipChildrenUpdate) {\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n if (child.visible) {\n child.updateTransform();\n }\n }\n }\n return result;\n };\n /**\n * Recalculates the content bounds of this object. This should be overriden to\n * calculate the bounds of this specific object (not including children).\n *\n * @protected\n */\n Container.prototype._calculateBounds = function () {\n // FILL IN//\n };\n /**\n * Renders this object and its children with culling.\n *\n * @protected\n * @param {PIXI.Renderer} renderer - The renderer\n */\n Container.prototype._renderWithCulling = function (renderer) {\n var sourceFrame = renderer.renderTexture.sourceFrame;\n // If the source frame is empty, stop rendering.\n if (!(sourceFrame.width > 0 && sourceFrame.height > 0)) {\n return;\n }\n // Render the content of the container only if its bounds intersect with the source frame.\n // All filters are on the stack at this point, and the filter source frame is bound:\n // therefore, even if the bounds to non intersect the filter frame, the filter\n // is still applied and any filter padding that is in the frame is rendered correctly.\n var bounds;\n var transform;\n // If cullArea is set, we use this rectangle instead of the bounds of the object. The cullArea\n // rectangle must completely contain the container and its children including filter padding.\n if (this.cullArea) {\n bounds = this.cullArea;\n transform = this.worldTransform;\n }\n // If the container doesn't override _render, we can skip the bounds calculation and intersection test.\n else if (this._render !== Container.prototype._render) {\n bounds = this.getBounds(true);\n }\n // Render the container if the source frame intersects the bounds.\n if (bounds && sourceFrame.intersects(bounds, transform)) {\n this._render(renderer);\n }\n // If the bounds are defined by cullArea and do not intersect with the source frame, stop rendering.\n else if (this.cullArea) {\n return;\n }\n // Unless cullArea is set, we cannot skip the children if the bounds of the container do not intersect\n // the source frame, because the children might have filters with nonzero padding, which may intersect\n // with the source frame while the bounds do not: filter padding is not included in the bounds.\n // If cullArea is not set, render the children with culling temporarily enabled so that they are not rendered\n // if they are out of frame; otherwise, render the children normally.\n for (var i = 0, j = this.children.length; i < j; ++i) {\n var child = this.children[i];\n var childCullable = child.cullable;\n child.cullable = childCullable || !this.cullArea;\n child.render(renderer);\n child.cullable = childCullable;\n }\n };\n /**\n * Renders the object using the WebGL renderer.\n *\n * The [_render]{@link PIXI.Container#_render} method is be overriden for rendering the contents of the\n * container itself. This `render` method will invoke it, and also invoke the `render` methods of all\n * children afterward.\n *\n * If `renderable` or `visible` is false or if `worldAlpha` is not positive or if `cullable` is true and\n * the bounds of this object are out of frame, this implementation will entirely skip rendering.\n * See {@link PIXI.DisplayObject} for choosing between `renderable` or `visible`. Generally,\n * setting alpha to zero is not recommended for purely skipping rendering.\n *\n * When your scene becomes large (especially when it is larger than can be viewed in a single screen), it is\n * advised to employ **culling** to automatically skip rendering objects outside of the current screen.\n * See [cullable]{@link PIXI.DisplayObject#cullable} and [cullArea]{@link PIXI.DisplayObject#cullArea}.\n * Other culling methods might be better suited for a large number static objects; see\n * [@pixi-essentials/cull]{@link https://www.npmjs.com/package/@pixi-essentials/cull} and\n * [pixi-cull]{@link https://www.npmjs.com/package/pixi-cull}.\n *\n * The [renderAdvanced]{@link PIXI.Container#renderAdvanced} method is internally used when when masking or\n * filtering is applied on a container. This does, however, break batching and can affect performance when\n * masking and filtering is applied extensively throughout the scene graph.\n *\n * @param renderer - The renderer\n */\n Container.prototype.render = function (renderer) {\n // if the object is not visible or the alpha is 0 then no need to render this element\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\n return;\n }\n // do a quick check to see if this element has a mask or a filter.\n if (this._mask || (this.filters && this.filters.length)) {\n this.renderAdvanced(renderer);\n }\n else if (this.cullable) {\n this._renderWithCulling(renderer);\n }\n else {\n this._render(renderer);\n for (var i = 0, j = this.children.length; i < j; ++i) {\n this.children[i].render(renderer);\n }\n }\n };\n /**\n * Render the object using the WebGL renderer and advanced features.\n *\n * @param renderer - The renderer\n */\n Container.prototype.renderAdvanced = function (renderer) {\n var filters = this.filters;\n var mask = this._mask;\n // push filter first as we need to ensure the stencil buffer is correct for any masking\n if (filters) {\n if (!this._enabledFilters) {\n this._enabledFilters = [];\n }\n this._enabledFilters.length = 0;\n for (var i = 0; i < filters.length; i++) {\n if (filters[i].enabled) {\n this._enabledFilters.push(filters[i]);\n }\n }\n }\n var flush = (filters && this._enabledFilters && this._enabledFilters.length)\n || (mask && (!mask.isMaskData\n || (mask.enabled && (mask.autoDetect || mask.type !== MASK_TYPES.NONE))));\n if (flush) {\n renderer.batch.flush();\n }\n if (filters && this._enabledFilters && this._enabledFilters.length) {\n renderer.filter.push(this, this._enabledFilters);\n }\n if (mask) {\n renderer.mask.push(this, this._mask);\n }\n if (this.cullable) {\n this._renderWithCulling(renderer);\n }\n else {\n this._render(renderer);\n for (var i = 0, j = this.children.length; i < j; ++i) {\n this.children[i].render(renderer);\n }\n }\n if (flush) {\n renderer.batch.flush();\n }\n if (mask) {\n renderer.mask.pop(this);\n }\n if (filters && this._enabledFilters && this._enabledFilters.length) {\n renderer.filter.pop();\n }\n };\n /**\n * To be overridden by the subclasses.\n *\n * @param renderer - The renderer\n */\n Container.prototype._render = function (_renderer) {\n // this is where content itself gets rendered...\n };\n /**\n * Removes all internal references and listeners as well as removes children from the display list.\n * Do not use a Container after calling `destroy`.\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the texture of the child sprite\n * @param {boolean} [options.baseTexture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the base texture of the child sprite\n */\n Container.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this);\n this.sortDirty = false;\n var destroyChildren = typeof options === 'boolean' ? options : options && options.children;\n var oldChildren = this.removeChildren(0, this.children.length);\n if (destroyChildren) {\n for (var i = 0; i < oldChildren.length; ++i) {\n oldChildren[i].destroy(options);\n }\n }\n };\n Object.defineProperty(Container.prototype, \"width\", {\n /** The width of the Container, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this.scale.x * this.getLocalBounds().width;\n },\n set: function (value) {\n var width = this.getLocalBounds().width;\n if (width !== 0) {\n this.scale.x = value / width;\n }\n else {\n this.scale.x = 1;\n }\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Container.prototype, \"height\", {\n /** The height of the Container, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this.scale.y * this.getLocalBounds().height;\n },\n set: function (value) {\n var height = this.getLocalBounds().height;\n if (height !== 0) {\n this.scale.y = value / height;\n }\n else {\n this.scale.y = 1;\n }\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n return Container;\n}(DisplayObject));\n/**\n * Container default updateTransform, does update children of container.\n * Will crash if there's no parent element.\n *\n * @memberof PIXI.Container#\n * @method containerUpdateTransform\n */\nContainer.prototype.containerUpdateTransform = Container.prototype.updateTransform;\n\nexport { Bounds, Container, DisplayObject, TemporaryDisplayObject };\n//# sourceMappingURL=display.js.map\n","/*!\n * @pixi/math - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/math is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Two Pi.\n *\n * @static\n * @member {number}\n * @memberof PIXI\n */\nvar PI_2 = Math.PI * 2;\n/**\n * Conversion factor for converting radians to degrees.\n *\n * @static\n * @member {number} RAD_TO_DEG\n * @memberof PIXI\n */\nvar RAD_TO_DEG = 180 / Math.PI;\n/**\n * Conversion factor for converting degrees to radians.\n *\n * @static\n * @member {number}\n * @memberof PIXI\n */\nvar DEG_TO_RAD = Math.PI / 180;\n/**\n * Constants that identify shapes, mainly to prevent `instanceof` calls.\n *\n * @static\n * @memberof PIXI\n * @enum {number}\n * @property {number} POLY Polygon\n * @property {number} RECT Rectangle\n * @property {number} CIRC Circle\n * @property {number} ELIP Ellipse\n * @property {number} RREC Rounded Rectangle\n */\nvar SHAPES;\n(function (SHAPES) {\n SHAPES[SHAPES[\"POLY\"] = 0] = \"POLY\";\n SHAPES[SHAPES[\"RECT\"] = 1] = \"RECT\";\n SHAPES[SHAPES[\"CIRC\"] = 2] = \"CIRC\";\n SHAPES[SHAPES[\"ELIP\"] = 3] = \"ELIP\";\n SHAPES[SHAPES[\"RREC\"] = 4] = \"RREC\";\n})(SHAPES || (SHAPES = {}));\n\n/**\n * The Point object represents a location in a two-dimensional coordinate system, where `x` represents\n * the position on the horizontal axis and `y` represents the position on the vertical axis\n *\n * @class\n * @memberof PIXI\n * @implements IPoint\n */\nvar Point = /** @class */ (function () {\n /** Creates a new `Point`\n * @param {number} [x=0] - position of the point on the x axis\n * @param {number} [y=0] - position of the point on the y axis\n */\n function Point(x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n /** Position of the point on the x axis */\n this.x = 0;\n /** Position of the point on the y axis */\n this.y = 0;\n this.x = x;\n this.y = y;\n }\n /** Creates a clone of this point\n * @returns A clone of this point\n */\n Point.prototype.clone = function () {\n return new Point(this.x, this.y);\n };\n /**\n * Copies `x` and `y` from the given point into this point\n *\n * @param p - The point to copy from\n * @returns The point instance itself\n */\n Point.prototype.copyFrom = function (p) {\n this.set(p.x, p.y);\n return this;\n };\n /**\n * Copies this point's x and y into the given point (`p`).\n *\n * @param p - The point to copy to. Can be any of type that is or extends `IPointData`\n * @returns The point (`p`) with values updated\n */\n Point.prototype.copyTo = function (p) {\n p.set(this.x, this.y);\n return p;\n };\n /**\n * Accepts another point (`p`) and returns `true` if the given point is equal to this point\n *\n * @param p - The point to check\n * @returns Returns `true` if both `x` and `y` are equal\n */\n Point.prototype.equals = function (p) {\n return (p.x === this.x) && (p.y === this.y);\n };\n /**\n * Sets the point to a new `x` and `y` position.\n * If `y` is omitted, both `x` and `y` will be set to `x`.\n *\n * @param {number} [x=0] - position of the point on the `x` axis\n * @param {number} [y=x] - position of the point on the `y` axis\n * @returns The point instance itself\n */\n Point.prototype.set = function (x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = x; }\n this.x = x;\n this.y = y;\n return this;\n };\n Point.prototype.toString = function () {\n return \"[@pixi/math:Point x=\" + this.x + \" y=\" + this.y + \"]\";\n };\n return Point;\n}());\n\nvar tempPoints = [new Point(), new Point(), new Point(), new Point()];\n/**\n * Size object, contains width and height\n *\n * @memberof PIXI\n * @typedef {object} ISize\n */\n/**\n * Rectangle object is an area defined by its position, as indicated by its top-left corner\n * point (x, y) and by its width and its height.\n *\n * @memberof PIXI\n */\nvar Rectangle = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the upper-left corner of the rectangle\n * @param y - The Y coordinate of the upper-left corner of the rectangle\n * @param width - The overall width of the rectangle\n * @param height - The overall height of the rectangle\n */\n function Rectangle(x, y, width, height) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n this.x = Number(x);\n this.y = Number(y);\n this.width = Number(width);\n this.height = Number(height);\n this.type = SHAPES.RECT;\n }\n Object.defineProperty(Rectangle.prototype, \"left\", {\n /** Returns the left edge of the rectangle. */\n get: function () {\n return this.x;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle.prototype, \"right\", {\n /** Returns the right edge of the rectangle. */\n get: function () {\n return this.x + this.width;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle.prototype, \"top\", {\n /** Returns the top edge of the rectangle. */\n get: function () {\n return this.y;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle.prototype, \"bottom\", {\n /** Returns the bottom edge of the rectangle. */\n get: function () {\n return this.y + this.height;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Rectangle, \"EMPTY\", {\n /** A constant empty rectangle. */\n get: function () {\n return new Rectangle(0, 0, 0, 0);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Creates a clone of this Rectangle\n *\n * @return a copy of the rectangle\n */\n Rectangle.prototype.clone = function () {\n return new Rectangle(this.x, this.y, this.width, this.height);\n };\n /**\n * Copies another rectangle to this one.\n *\n * @param rectangle - The rectangle to copy from.\n * @return Returns itself.\n */\n Rectangle.prototype.copyFrom = function (rectangle) {\n this.x = rectangle.x;\n this.y = rectangle.y;\n this.width = rectangle.width;\n this.height = rectangle.height;\n return this;\n };\n /**\n * Copies this rectangle to another one.\n *\n * @param rectangle - The rectangle to copy to.\n * @return Returns given parameter.\n */\n Rectangle.prototype.copyTo = function (rectangle) {\n rectangle.x = this.x;\n rectangle.y = this.y;\n rectangle.width = this.width;\n rectangle.height = this.height;\n return rectangle;\n };\n /**\n * Checks whether the x and y coordinates given are contained within this Rectangle\n *\n * @param x - The X coordinate of the point to test\n * @param y - The Y coordinate of the point to test\n * @return Whether the x/y coordinates are within this Rectangle\n */\n Rectangle.prototype.contains = function (x, y) {\n if (this.width <= 0 || this.height <= 0) {\n return false;\n }\n if (x >= this.x && x < this.x + this.width) {\n if (y >= this.y && y < this.y + this.height) {\n return true;\n }\n }\n return false;\n };\n /**\n * Determines whether the `other` Rectangle transformed by `transform` intersects with `this` Rectangle object.\n * Returns true only if the area of the intersection is >0, this means that Rectangles\n * sharing a side are not overlapping. Another side effect is that an arealess rectangle\n * (width or height equal to zero) can't intersect any other rectangle.\n *\n * @param {Rectangle} other - The Rectangle to intersect with `this`.\n * @param {Matrix} transform - The transformation matrix of `other`.\n * @returns {boolean} A value of `true` if the transformed `other` Rectangle intersects with `this`; otherwise `false`.\n */\n Rectangle.prototype.intersects = function (other, transform) {\n if (!transform) {\n var x0_1 = this.x < other.x ? other.x : this.x;\n var x1_1 = this.right > other.right ? other.right : this.right;\n if (x1_1 <= x0_1) {\n return false;\n }\n var y0_1 = this.y < other.y ? other.y : this.y;\n var y1_1 = this.bottom > other.bottom ? other.bottom : this.bottom;\n return y1_1 > y0_1;\n }\n var x0 = this.left;\n var x1 = this.right;\n var y0 = this.top;\n var y1 = this.bottom;\n if (x1 <= x0 || y1 <= y0) {\n return false;\n }\n var lt = tempPoints[0].set(other.left, other.top);\n var lb = tempPoints[1].set(other.left, other.bottom);\n var rt = tempPoints[2].set(other.right, other.top);\n var rb = tempPoints[3].set(other.right, other.bottom);\n if (rt.x <= lt.x || lb.y <= lt.y) {\n return false;\n }\n var s = Math.sign((transform.a * transform.d) - (transform.b * transform.c));\n if (s === 0) {\n return false;\n }\n transform.apply(lt, lt);\n transform.apply(lb, lb);\n transform.apply(rt, rt);\n transform.apply(rb, rb);\n if (Math.max(lt.x, lb.x, rt.x, rb.x) <= x0\n || Math.min(lt.x, lb.x, rt.x, rb.x) >= x1\n || Math.max(lt.y, lb.y, rt.y, rb.y) <= y0\n || Math.min(lt.y, lb.y, rt.y, rb.y) >= y1) {\n return false;\n }\n var nx = s * (lb.y - lt.y);\n var ny = s * (lt.x - lb.x);\n var n00 = (nx * x0) + (ny * y0);\n var n10 = (nx * x1) + (ny * y0);\n var n01 = (nx * x0) + (ny * y1);\n var n11 = (nx * x1) + (ny * y1);\n if (Math.max(n00, n10, n01, n11) <= (nx * lt.x) + (ny * lt.y)\n || Math.min(n00, n10, n01, n11) >= (nx * rb.x) + (ny * rb.y)) {\n return false;\n }\n var mx = s * (lt.y - rt.y);\n var my = s * (rt.x - lt.x);\n var m00 = (mx * x0) + (my * y0);\n var m10 = (mx * x1) + (my * y0);\n var m01 = (mx * x0) + (my * y1);\n var m11 = (mx * x1) + (my * y1);\n if (Math.max(m00, m10, m01, m11) <= (mx * lt.x) + (my * lt.y)\n || Math.min(m00, m10, m01, m11) >= (mx * rb.x) + (my * rb.y)) {\n return false;\n }\n return true;\n };\n /**\n * Pads the rectangle making it grow in all directions.\n * If paddingY is omitted, both paddingX and paddingY will be set to paddingX.\n *\n * @param paddingX - The horizontal padding amount.\n * @param paddingY - The vertical padding amount.\n * @return Returns itself.\n */\n Rectangle.prototype.pad = function (paddingX, paddingY) {\n if (paddingX === void 0) { paddingX = 0; }\n if (paddingY === void 0) { paddingY = paddingX; }\n this.x -= paddingX;\n this.y -= paddingY;\n this.width += paddingX * 2;\n this.height += paddingY * 2;\n return this;\n };\n /**\n * Fits this rectangle around the passed one.\n *\n * @param rectangle - The rectangle to fit.\n * @return Returns itself.\n */\n Rectangle.prototype.fit = function (rectangle) {\n var x1 = Math.max(this.x, rectangle.x);\n var x2 = Math.min(this.x + this.width, rectangle.x + rectangle.width);\n var y1 = Math.max(this.y, rectangle.y);\n var y2 = Math.min(this.y + this.height, rectangle.y + rectangle.height);\n this.x = x1;\n this.width = Math.max(x2 - x1, 0);\n this.y = y1;\n this.height = Math.max(y2 - y1, 0);\n return this;\n };\n /**\n * Enlarges rectangle that way its corners lie on grid\n *\n * @param resolution - resolution\n * @param eps - precision\n * @return Returns itself.\n */\n Rectangle.prototype.ceil = function (resolution, eps) {\n if (resolution === void 0) { resolution = 1; }\n if (eps === void 0) { eps = 0.001; }\n var x2 = Math.ceil((this.x + this.width - eps) * resolution) / resolution;\n var y2 = Math.ceil((this.y + this.height - eps) * resolution) / resolution;\n this.x = Math.floor((this.x + eps) * resolution) / resolution;\n this.y = Math.floor((this.y + eps) * resolution) / resolution;\n this.width = x2 - this.x;\n this.height = y2 - this.y;\n return this;\n };\n /**\n * Enlarges this rectangle to include the passed rectangle.\n *\n * @param rectangle - The rectangle to include.\n * @return Returns itself.\n */\n Rectangle.prototype.enlarge = function (rectangle) {\n var x1 = Math.min(this.x, rectangle.x);\n var x2 = Math.max(this.x + this.width, rectangle.x + rectangle.width);\n var y1 = Math.min(this.y, rectangle.y);\n var y2 = Math.max(this.y + this.height, rectangle.y + rectangle.height);\n this.x = x1;\n this.width = x2 - x1;\n this.y = y1;\n this.height = y2 - y1;\n return this;\n };\n Rectangle.prototype.toString = function () {\n return \"[@pixi/math:Rectangle x=\" + this.x + \" y=\" + this.y + \" width=\" + this.width + \" height=\" + this.height + \"]\";\n };\n return Rectangle;\n}());\n\n/**\n * The Circle object is used to help draw graphics and can also be used to specify a hit area for displayObjects.\n *\n * @memberof PIXI\n */\nvar Circle = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the center of this circle\n * @param y - The Y coordinate of the center of this circle\n * @param radius - The radius of the circle\n */\n function Circle(x, y, radius) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (radius === void 0) { radius = 0; }\n this.x = x;\n this.y = y;\n this.radius = radius;\n this.type = SHAPES.CIRC;\n }\n /**\n * Creates a clone of this Circle instance\n *\n * @return A copy of the Circle\n */\n Circle.prototype.clone = function () {\n return new Circle(this.x, this.y, this.radius);\n };\n /**\n * Checks whether the x and y coordinates given are contained within this circle\n *\n * @param x - The X coordinate of the point to test\n * @param y - The Y coordinate of the point to test\n * @return Whether the x/y coordinates are within this Circle\n */\n Circle.prototype.contains = function (x, y) {\n if (this.radius <= 0) {\n return false;\n }\n var r2 = this.radius * this.radius;\n var dx = (this.x - x);\n var dy = (this.y - y);\n dx *= dx;\n dy *= dy;\n return (dx + dy <= r2);\n };\n /**\n * Returns the framing rectangle of the circle as a Rectangle object\n *\n * @return The framing rectangle\n */\n Circle.prototype.getBounds = function () {\n return new Rectangle(this.x - this.radius, this.y - this.radius, this.radius * 2, this.radius * 2);\n };\n Circle.prototype.toString = function () {\n return \"[@pixi/math:Circle x=\" + this.x + \" y=\" + this.y + \" radius=\" + this.radius + \"]\";\n };\n return Circle;\n}());\n\n/**\n * The Ellipse object is used to help draw graphics and can also be used to specify a hit area for displayObjects.\n *\n * @memberof PIXI\n */\nvar Ellipse = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the center of this ellipse\n * @param y - The Y coordinate of the center of this ellipse\n * @param halfWidth - The half width of this ellipse\n * @param halfHeight - The half height of this ellipse\n */\n function Ellipse(x, y, halfWidth, halfHeight) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (halfWidth === void 0) { halfWidth = 0; }\n if (halfHeight === void 0) { halfHeight = 0; }\n this.x = x;\n this.y = y;\n this.width = halfWidth;\n this.height = halfHeight;\n this.type = SHAPES.ELIP;\n }\n /**\n * Creates a clone of this Ellipse instance\n *\n * @return {PIXI.Ellipse} A copy of the ellipse\n */\n Ellipse.prototype.clone = function () {\n return new Ellipse(this.x, this.y, this.width, this.height);\n };\n /**\n * Checks whether the x and y coordinates given are contained within this ellipse\n *\n * @param x - The X coordinate of the point to test\n * @param y - The Y coordinate of the point to test\n * @return Whether the x/y coords are within this ellipse\n */\n Ellipse.prototype.contains = function (x, y) {\n if (this.width <= 0 || this.height <= 0) {\n return false;\n }\n // normalize the coords to an ellipse with center 0,0\n var normx = ((x - this.x) / this.width);\n var normy = ((y - this.y) / this.height);\n normx *= normx;\n normy *= normy;\n return (normx + normy <= 1);\n };\n /**\n * Returns the framing rectangle of the ellipse as a Rectangle object\n *\n * @return The framing rectangle\n */\n Ellipse.prototype.getBounds = function () {\n return new Rectangle(this.x - this.width, this.y - this.height, this.width, this.height);\n };\n Ellipse.prototype.toString = function () {\n return \"[@pixi/math:Ellipse x=\" + this.x + \" y=\" + this.y + \" width=\" + this.width + \" height=\" + this.height + \"]\";\n };\n return Ellipse;\n}());\n\n/**\n * A class to define a shape via user defined coordinates.\n *\n * @memberof PIXI\n */\nvar Polygon = /** @class */ (function () {\n /**\n * @param {PIXI.IPointData[]|number[]} points - This can be an array of Points\n * that form the polygon, a flat array of numbers that will be interpreted as [x,y, x,y, ...], or\n * the arguments passed can be all the points of the polygon e.g.\n * `new PIXI.Polygon(new PIXI.Point(), new PIXI.Point(), ...)`, or the arguments passed can be flat\n * x,y values e.g. `new Polygon(x,y, x,y, x,y, ...)` where `x` and `y` are Numbers.\n */\n function Polygon() {\n var arguments$1 = arguments;\n\n var points = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n points[_i] = arguments$1[_i];\n }\n var flat = Array.isArray(points[0]) ? points[0] : points;\n // if this is an array of points, convert it to a flat array of numbers\n if (typeof flat[0] !== 'number') {\n var p = [];\n for (var i = 0, il = flat.length; i < il; i++) {\n p.push(flat[i].x, flat[i].y);\n }\n flat = p;\n }\n this.points = flat;\n this.type = SHAPES.POLY;\n this.closeStroke = true;\n }\n /**\n * Creates a clone of this polygon.\n *\n * @return - A copy of the polygon.\n */\n Polygon.prototype.clone = function () {\n var points = this.points.slice();\n var polygon = new Polygon(points);\n polygon.closeStroke = this.closeStroke;\n return polygon;\n };\n /**\n * Checks whether the x and y coordinates passed to this function are contained within this polygon.\n *\n * @param x - The X coordinate of the point to test.\n * @param y - The Y coordinate of the point to test.\n * @return - Whether the x/y coordinates are within this polygon.\n */\n Polygon.prototype.contains = function (x, y) {\n var inside = false;\n // use some raycasting to test hits\n // https://github.com/substack/point-in-polygon/blob/master/index.js\n var length = this.points.length / 2;\n for (var i = 0, j = length - 1; i < length; j = i++) {\n var xi = this.points[i * 2];\n var yi = this.points[(i * 2) + 1];\n var xj = this.points[j * 2];\n var yj = this.points[(j * 2) + 1];\n var intersect = ((yi > y) !== (yj > y)) && (x < ((xj - xi) * ((y - yi) / (yj - yi))) + xi);\n if (intersect) {\n inside = !inside;\n }\n }\n return inside;\n };\n Polygon.prototype.toString = function () {\n return \"[@pixi/math:Polygon\"\n + (\"closeStroke=\" + this.closeStroke)\n + (\"points=\" + this.points.reduce(function (pointsDesc, currentPoint) { return pointsDesc + \", \" + currentPoint; }, '') + \"]\");\n };\n return Polygon;\n}());\n\n/**\n * The Rounded Rectangle object is an area that has nice rounded corners, as indicated by its\n * top-left corner point (x, y) and by its width and its height and its radius.\n *\n * @memberof PIXI\n */\nvar RoundedRectangle = /** @class */ (function () {\n /**\n * @param x - The X coordinate of the upper-left corner of the rounded rectangle\n * @param y - The Y coordinate of the upper-left corner of the rounded rectangle\n * @param width - The overall width of this rounded rectangle\n * @param height - The overall height of this rounded rectangle\n * @param radius - Controls the radius of the rounded corners\n */\n function RoundedRectangle(x, y, width, height, radius) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (width === void 0) { width = 0; }\n if (height === void 0) { height = 0; }\n if (radius === void 0) { radius = 20; }\n this.x = x;\n this.y = y;\n this.width = width;\n this.height = height;\n this.radius = radius;\n this.type = SHAPES.RREC;\n }\n /**\n * Creates a clone of this Rounded Rectangle.\n *\n * @return - A copy of the rounded rectangle.\n */\n RoundedRectangle.prototype.clone = function () {\n return new RoundedRectangle(this.x, this.y, this.width, this.height, this.radius);\n };\n /**\n * Checks whether the x and y coordinates given are contained within this Rounded Rectangle\n *\n * @param x - The X coordinate of the point to test.\n * @param y - The Y coordinate of the point to test.\n * @return - Whether the x/y coordinates are within this Rounded Rectangle.\n */\n RoundedRectangle.prototype.contains = function (x, y) {\n if (this.width <= 0 || this.height <= 0) {\n return false;\n }\n if (x >= this.x && x <= this.x + this.width) {\n if (y >= this.y && y <= this.y + this.height) {\n var radius = Math.max(0, Math.min(this.radius, Math.min(this.width, this.height) / 2));\n if ((y >= this.y + radius && y <= this.y + this.height - radius)\n || (x >= this.x + radius && x <= this.x + this.width - radius)) {\n return true;\n }\n var dx = x - (this.x + radius);\n var dy = y - (this.y + radius);\n var radius2 = radius * radius;\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n dx = x - (this.x + this.width - radius);\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n dy = y - (this.y + this.height - radius);\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n dx = x - (this.x + radius);\n if ((dx * dx) + (dy * dy) <= radius2) {\n return true;\n }\n }\n }\n return false;\n };\n RoundedRectangle.prototype.toString = function () {\n return \"[@pixi/math:RoundedRectangle x=\" + this.x + \" y=\" + this.y\n + (\"width=\" + this.width + \" height=\" + this.height + \" radius=\" + this.radius + \"]\");\n };\n return RoundedRectangle;\n}());\n\n/**\n * The ObservablePoint object represents a location in a two-dimensional coordinate system, where `x` represents\n * the position on the horizontal axis and `y` represents the position on the vertical axis.\n *\n * An `ObservablePoint` is a point that triggers a callback when the point's position is changed.\n *\n * @memberof PIXI\n */\nvar ObservablePoint = /** @class */ (function () {\n /**\n * Creates a new `ObservablePoint`\n *\n * @param cb - callback function triggered when `x` and/or `y` are changed\n * @param scope - owner of callback\n * @param {number} [x=0] - position of the point on the x axis\n * @param {number} [y=0] - position of the point on the y axis\n */\n function ObservablePoint(cb, scope, x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n this._x = x;\n this._y = y;\n this.cb = cb;\n this.scope = scope;\n }\n /**\n * Creates a clone of this point.\n * The callback and scope params can be overridden otherwise they will default\n * to the clone object's values.\n *\n * @override\n * @param cb - The callback function triggered when `x` and/or `y` are changed\n * @param scope - The owner of the callback\n * @return a copy of this observable point\n */\n ObservablePoint.prototype.clone = function (cb, scope) {\n if (cb === void 0) { cb = this.cb; }\n if (scope === void 0) { scope = this.scope; }\n return new ObservablePoint(cb, scope, this._x, this._y);\n };\n /**\n * Sets the point to a new `x` and `y` position.\n * If `y` is omitted, both `x` and `y` will be set to `x`.\n *\n * @param {number} [x=0] - position of the point on the x axis\n * @param {number} [y=x] - position of the point on the y axis\n * @returns The observable point instance itself\n */\n ObservablePoint.prototype.set = function (x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = x; }\n if (this._x !== x || this._y !== y) {\n this._x = x;\n this._y = y;\n this.cb.call(this.scope);\n }\n return this;\n };\n /**\n * Copies x and y from the given point (`p`)\n *\n * @param p - The point to copy from. Can be any of type that is or extends `IPointData`\n * @returns The observable point instance itself\n */\n ObservablePoint.prototype.copyFrom = function (p) {\n if (this._x !== p.x || this._y !== p.y) {\n this._x = p.x;\n this._y = p.y;\n this.cb.call(this.scope);\n }\n return this;\n };\n /**\n * Copies this point's x and y into that of the given point (`p`)\n *\n * @param p - The point to copy to. Can be any of type that is or extends `IPointData`\n * @returns The point (`p`) with values updated\n */\n ObservablePoint.prototype.copyTo = function (p) {\n p.set(this._x, this._y);\n return p;\n };\n /**\n * Accepts another point (`p`) and returns `true` if the given point is equal to this point\n *\n * @param p - The point to check\n * @returns Returns `true` if both `x` and `y` are equal\n */\n ObservablePoint.prototype.equals = function (p) {\n return (p.x === this._x) && (p.y === this._y);\n };\n ObservablePoint.prototype.toString = function () {\n return \"[@pixi/math:ObservablePoint x=\" + 0 + \" y=\" + 0 + \" scope=\" + this.scope + \"]\";\n };\n Object.defineProperty(ObservablePoint.prototype, \"x\", {\n /** Position of the observable point on the x axis. */\n get: function () {\n return this._x;\n },\n set: function (value) {\n if (this._x !== value) {\n this._x = value;\n this.cb.call(this.scope);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ObservablePoint.prototype, \"y\", {\n /** Position of the observable point on the y axis. */\n get: function () {\n return this._y;\n },\n set: function (value) {\n if (this._y !== value) {\n this._y = value;\n this.cb.call(this.scope);\n }\n },\n enumerable: false,\n configurable: true\n });\n return ObservablePoint;\n}());\n\n/**\n * The PixiJS Matrix as a class makes it a lot faster.\n *\n * Here is a representation of it:\n * ```js\n * | a | c | tx|\n * | b | d | ty|\n * | 0 | 0 | 1 |\n * ```\n *\n * @memberof PIXI\n */\nvar Matrix = /** @class */ (function () {\n /**\n * @param a - x scale\n * @param b - y skew\n * @param c - x skew\n * @param d - y scale\n * @param tx - x translation\n * @param ty - y translation\n */\n function Matrix(a, b, c, d, tx, ty) {\n if (a === void 0) { a = 1; }\n if (b === void 0) { b = 0; }\n if (c === void 0) { c = 0; }\n if (d === void 0) { d = 1; }\n if (tx === void 0) { tx = 0; }\n if (ty === void 0) { ty = 0; }\n this.array = null;\n this.a = a;\n this.b = b;\n this.c = c;\n this.d = d;\n this.tx = tx;\n this.ty = ty;\n }\n /**\n * Creates a Matrix object based on the given array. The Element to Matrix mapping order is as follows:\n *\n * a = array[0]\n * b = array[1]\n * c = array[3]\n * d = array[4]\n * tx = array[2]\n * ty = array[5]\n *\n * @param array - The array that the matrix will be populated from.\n */\n Matrix.prototype.fromArray = function (array) {\n this.a = array[0];\n this.b = array[1];\n this.c = array[3];\n this.d = array[4];\n this.tx = array[2];\n this.ty = array[5];\n };\n /**\n * Sets the matrix properties.\n *\n * @param a - Matrix component\n * @param b - Matrix component\n * @param c - Matrix component\n * @param d - Matrix component\n * @param tx - Matrix component\n * @param ty - Matrix component\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.set = function (a, b, c, d, tx, ty) {\n this.a = a;\n this.b = b;\n this.c = c;\n this.d = d;\n this.tx = tx;\n this.ty = ty;\n return this;\n };\n /**\n * Creates an array from the current Matrix object.\n *\n * @param transpose - Whether we need to transpose the matrix or not\n * @param [out=new Float32Array(9)] - If provided the array will be assigned to out\n * @return The newly created array which contains the matrix\n */\n Matrix.prototype.toArray = function (transpose, out) {\n if (!this.array) {\n this.array = new Float32Array(9);\n }\n var array = out || this.array;\n if (transpose) {\n array[0] = this.a;\n array[1] = this.b;\n array[2] = 0;\n array[3] = this.c;\n array[4] = this.d;\n array[5] = 0;\n array[6] = this.tx;\n array[7] = this.ty;\n array[8] = 1;\n }\n else {\n array[0] = this.a;\n array[1] = this.c;\n array[2] = this.tx;\n array[3] = this.b;\n array[4] = this.d;\n array[5] = this.ty;\n array[6] = 0;\n array[7] = 0;\n array[8] = 1;\n }\n return array;\n };\n /**\n * Get a new position with the current transformation applied.\n * Can be used to go from a child's coordinate space to the world coordinate space. (e.g. rendering)\n *\n * @param pos - The origin\n * @param {PIXI.Point} [newPos] - The point that the new position is assigned to (allowed to be same as input)\n * @return {PIXI.Point} The new point, transformed through this matrix\n */\n Matrix.prototype.apply = function (pos, newPos) {\n newPos = (newPos || new Point());\n var x = pos.x;\n var y = pos.y;\n newPos.x = (this.a * x) + (this.c * y) + this.tx;\n newPos.y = (this.b * x) + (this.d * y) + this.ty;\n return newPos;\n };\n /**\n * Get a new position with the inverse of the current transformation applied.\n * Can be used to go from the world coordinate space to a child's coordinate space. (e.g. input)\n *\n * @param pos - The origin\n * @param {PIXI.Point} [newPos] - The point that the new position is assigned to (allowed to be same as input)\n * @return {PIXI.Point} The new point, inverse-transformed through this matrix\n */\n Matrix.prototype.applyInverse = function (pos, newPos) {\n newPos = (newPos || new Point());\n var id = 1 / ((this.a * this.d) + (this.c * -this.b));\n var x = pos.x;\n var y = pos.y;\n newPos.x = (this.d * id * x) + (-this.c * id * y) + (((this.ty * this.c) - (this.tx * this.d)) * id);\n newPos.y = (this.a * id * y) + (-this.b * id * x) + (((-this.ty * this.a) + (this.tx * this.b)) * id);\n return newPos;\n };\n /**\n * Translates the matrix on the x and y.\n *\n * @param x - How much to translate x by\n * @param y - How much to translate y by\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.translate = function (x, y) {\n this.tx += x;\n this.ty += y;\n return this;\n };\n /**\n * Applies a scale transformation to the matrix.\n *\n * @param x - The amount to scale horizontally\n * @param y - The amount to scale vertically\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.scale = function (x, y) {\n this.a *= x;\n this.d *= y;\n this.c *= x;\n this.b *= y;\n this.tx *= x;\n this.ty *= y;\n return this;\n };\n /**\n * Applies a rotation transformation to the matrix.\n *\n * @param angle - The angle in radians.\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.rotate = function (angle) {\n var cos = Math.cos(angle);\n var sin = Math.sin(angle);\n var a1 = this.a;\n var c1 = this.c;\n var tx1 = this.tx;\n this.a = (a1 * cos) - (this.b * sin);\n this.b = (a1 * sin) + (this.b * cos);\n this.c = (c1 * cos) - (this.d * sin);\n this.d = (c1 * sin) + (this.d * cos);\n this.tx = (tx1 * cos) - (this.ty * sin);\n this.ty = (tx1 * sin) + (this.ty * cos);\n return this;\n };\n /**\n * Appends the given Matrix to this Matrix.\n *\n * @param matrix - The matrix to append.\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.append = function (matrix) {\n var a1 = this.a;\n var b1 = this.b;\n var c1 = this.c;\n var d1 = this.d;\n this.a = (matrix.a * a1) + (matrix.b * c1);\n this.b = (matrix.a * b1) + (matrix.b * d1);\n this.c = (matrix.c * a1) + (matrix.d * c1);\n this.d = (matrix.c * b1) + (matrix.d * d1);\n this.tx = (matrix.tx * a1) + (matrix.ty * c1) + this.tx;\n this.ty = (matrix.tx * b1) + (matrix.ty * d1) + this.ty;\n return this;\n };\n /**\n * Sets the matrix based on all the available properties\n *\n * @param x - Position on the x axis\n * @param y - Position on the y axis\n * @param pivotX - Pivot on the x axis\n * @param pivotY - Pivot on the y axis\n * @param scaleX - Scale on the x axis\n * @param scaleY - Scale on the y axis\n * @param rotation - Rotation in radians\n * @param skewX - Skew on the x axis\n * @param skewY - Skew on the y axis\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.setTransform = function (x, y, pivotX, pivotY, scaleX, scaleY, rotation, skewX, skewY) {\n this.a = Math.cos(rotation + skewY) * scaleX;\n this.b = Math.sin(rotation + skewY) * scaleX;\n this.c = -Math.sin(rotation - skewX) * scaleY;\n this.d = Math.cos(rotation - skewX) * scaleY;\n this.tx = x - ((pivotX * this.a) + (pivotY * this.c));\n this.ty = y - ((pivotX * this.b) + (pivotY * this.d));\n return this;\n };\n /**\n * Prepends the given Matrix to this Matrix.\n *\n * @param matrix - The matrix to prepend\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.prepend = function (matrix) {\n var tx1 = this.tx;\n if (matrix.a !== 1 || matrix.b !== 0 || matrix.c !== 0 || matrix.d !== 1) {\n var a1 = this.a;\n var c1 = this.c;\n this.a = (a1 * matrix.a) + (this.b * matrix.c);\n this.b = (a1 * matrix.b) + (this.b * matrix.d);\n this.c = (c1 * matrix.a) + (this.d * matrix.c);\n this.d = (c1 * matrix.b) + (this.d * matrix.d);\n }\n this.tx = (tx1 * matrix.a) + (this.ty * matrix.c) + matrix.tx;\n this.ty = (tx1 * matrix.b) + (this.ty * matrix.d) + matrix.ty;\n return this;\n };\n /**\n * Decomposes the matrix (x, y, scaleX, scaleY, and rotation) and sets the properties on to a transform.\n *\n * @param transform - The transform to apply the properties to.\n * @return The transform with the newly applied properties\n */\n Matrix.prototype.decompose = function (transform) {\n // sort out rotation / skew..\n var a = this.a;\n var b = this.b;\n var c = this.c;\n var d = this.d;\n var pivot = transform.pivot;\n var skewX = -Math.atan2(-c, d);\n var skewY = Math.atan2(b, a);\n var delta = Math.abs(skewX + skewY);\n if (delta < 0.00001 || Math.abs(PI_2 - delta) < 0.00001) {\n transform.rotation = skewY;\n transform.skew.x = transform.skew.y = 0;\n }\n else {\n transform.rotation = 0;\n transform.skew.x = skewX;\n transform.skew.y = skewY;\n }\n // next set scale\n transform.scale.x = Math.sqrt((a * a) + (b * b));\n transform.scale.y = Math.sqrt((c * c) + (d * d));\n // next set position\n transform.position.x = this.tx + ((pivot.x * a) + (pivot.y * c));\n transform.position.y = this.ty + ((pivot.x * b) + (pivot.y * d));\n return transform;\n };\n /**\n * Inverts this matrix\n *\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.invert = function () {\n var a1 = this.a;\n var b1 = this.b;\n var c1 = this.c;\n var d1 = this.d;\n var tx1 = this.tx;\n var n = (a1 * d1) - (b1 * c1);\n this.a = d1 / n;\n this.b = -b1 / n;\n this.c = -c1 / n;\n this.d = a1 / n;\n this.tx = ((c1 * this.ty) - (d1 * tx1)) / n;\n this.ty = -((a1 * this.ty) - (b1 * tx1)) / n;\n return this;\n };\n /**\n * Resets this Matrix to an identity (default) matrix.\n *\n * @return This matrix. Good for chaining method calls.\n */\n Matrix.prototype.identity = function () {\n this.a = 1;\n this.b = 0;\n this.c = 0;\n this.d = 1;\n this.tx = 0;\n this.ty = 0;\n return this;\n };\n /**\n * Creates a new Matrix object with the same values as this one.\n *\n * @return A copy of this matrix. Good for chaining method calls.\n */\n Matrix.prototype.clone = function () {\n var matrix = new Matrix();\n matrix.a = this.a;\n matrix.b = this.b;\n matrix.c = this.c;\n matrix.d = this.d;\n matrix.tx = this.tx;\n matrix.ty = this.ty;\n return matrix;\n };\n /**\n * Changes the values of the given matrix to be the same as the ones in this matrix\n *\n * @param matrix - The matrix to copy to.\n * @return The matrix given in parameter with its values updated.\n */\n Matrix.prototype.copyTo = function (matrix) {\n matrix.a = this.a;\n matrix.b = this.b;\n matrix.c = this.c;\n matrix.d = this.d;\n matrix.tx = this.tx;\n matrix.ty = this.ty;\n return matrix;\n };\n /**\n * Changes the values of the matrix to be the same as the ones in given matrix\n *\n * @param {PIXI.Matrix} matrix - The matrix to copy from.\n * @return {PIXI.Matrix} this\n */\n Matrix.prototype.copyFrom = function (matrix) {\n this.a = matrix.a;\n this.b = matrix.b;\n this.c = matrix.c;\n this.d = matrix.d;\n this.tx = matrix.tx;\n this.ty = matrix.ty;\n return this;\n };\n Matrix.prototype.toString = function () {\n return \"[@pixi/math:Matrix a=\" + this.a + \" b=\" + this.b + \" c=\" + this.c + \" d=\" + this.d + \" tx=\" + this.tx + \" ty=\" + this.ty + \"]\";\n };\n Object.defineProperty(Matrix, \"IDENTITY\", {\n /**\n * A default (identity) matrix\n *\n * @readonly\n */\n get: function () {\n return new Matrix();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Matrix, \"TEMP_MATRIX\", {\n /**\n * A temp matrix\n *\n * @readonly\n */\n get: function () {\n return new Matrix();\n },\n enumerable: false,\n configurable: true\n });\n return Matrix;\n}());\n\n// Your friendly neighbour https://en.wikipedia.org/wiki/Dihedral_group\n/*\n * Transform matrix for operation n is:\n * | ux | vx |\n * | uy | vy |\n */\nvar ux = [1, 1, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, -1, -1, 0, 1];\nvar uy = [0, 1, 1, 1, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, -1, -1];\nvar vx = [0, -1, -1, -1, 0, 1, 1, 1, 0, 1, 1, 1, 0, -1, -1, -1];\nvar vy = [1, 1, 0, -1, -1, -1, 0, 1, -1, -1, 0, 1, 1, 1, 0, -1];\n/**\n * [Cayley Table]{@link https://en.wikipedia.org/wiki/Cayley_table}\n * for the composition of each rotation in the dihederal group D8.\n *\n * @type number[][]\n * @private\n */\nvar rotationCayley = [];\n/**\n * Matrices for each `GD8Symmetry` rotation.\n *\n * @type Matrix[]\n * @private\n */\nvar rotationMatrices = [];\n/*\n * Alias for {@code Math.sign}.\n */\nvar signum = Math.sign;\n/*\n * Initializes `rotationCayley` and `rotationMatrices`. It is called\n * only once below.\n */\nfunction init() {\n for (var i = 0; i < 16; i++) {\n var row = [];\n rotationCayley.push(row);\n for (var j = 0; j < 16; j++) {\n /* Multiplies rotation matrices i and j. */\n var _ux = signum((ux[i] * ux[j]) + (vx[i] * uy[j]));\n var _uy = signum((uy[i] * ux[j]) + (vy[i] * uy[j]));\n var _vx = signum((ux[i] * vx[j]) + (vx[i] * vy[j]));\n var _vy = signum((uy[i] * vx[j]) + (vy[i] * vy[j]));\n /* Finds rotation matrix matching the product and pushes it. */\n for (var k = 0; k < 16; k++) {\n if (ux[k] === _ux && uy[k] === _uy\n && vx[k] === _vx && vy[k] === _vy) {\n row.push(k);\n break;\n }\n }\n }\n }\n for (var i = 0; i < 16; i++) {\n var mat = new Matrix();\n mat.set(ux[i], uy[i], vx[i], vy[i], 0, 0);\n rotationMatrices.push(mat);\n }\n}\ninit();\n/**\n * @memberof PIXI\n * @typedef {number} GD8Symmetry\n * @see PIXI.groupD8\n */\n/**\n * Implements the dihedral group D8, which is similar to\n * [group D4]{@link http://mathworld.wolfram.com/DihedralGroupD4.html};\n * D8 is the same but with diagonals, and it is used for texture\n * rotations.\n *\n * The directions the U- and V- axes after rotation\n * of an angle of `a: GD8Constant` are the vectors `(uX(a), uY(a))`\n * and `(vX(a), vY(a))`. These aren't necessarily unit vectors.\n *\n * **Origin:**<br>\n * This is the small part of gameofbombs.com portal system. It works.\n *\n * @see PIXI.groupD8.E\n * @see PIXI.groupD8.SE\n * @see PIXI.groupD8.S\n * @see PIXI.groupD8.SW\n * @see PIXI.groupD8.W\n * @see PIXI.groupD8.NW\n * @see PIXI.groupD8.N\n * @see PIXI.groupD8.NE\n * @author Ivan @ivanpopelyshev\n * @namespace PIXI.groupD8\n * @memberof PIXI\n */\nvar groupD8 = {\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 0° | East |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n E: 0,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 45°↻ | Southeast |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n SE: 1,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 90°↻ | South |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n S: 2,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 135°↻ | Southwest |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n SW: 3,\n /**\n * | Rotation | Direction |\n * |----------|-----------|\n * | 180° | West |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n W: 4,\n /**\n * | Rotation | Direction |\n * |-------------|--------------|\n * | -135°/225°↻ | Northwest |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n NW: 5,\n /**\n * | Rotation | Direction |\n * |-------------|--------------|\n * | -90°/270°↻ | North |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n N: 6,\n /**\n * | Rotation | Direction |\n * |-------------|--------------|\n * | -45°/315°↻ | Northeast |\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n NE: 7,\n /**\n * Reflection about Y-axis.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n MIRROR_VERTICAL: 8,\n /**\n * Reflection about the main diagonal.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n MAIN_DIAGONAL: 10,\n /**\n * Reflection about X-axis.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n MIRROR_HORIZONTAL: 12,\n /**\n * Reflection about reverse diagonal.\n *\n * @memberof PIXI.groupD8\n * @constant {PIXI.GD8Symmetry}\n */\n REVERSE_DIAGONAL: 14,\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The X-component of the U-axis\n * after rotating the axes.\n */\n uX: function (ind) { return ux[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The Y-component of the U-axis\n * after rotating the axes.\n */\n uY: function (ind) { return uy[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The X-component of the V-axis\n * after rotating the axes.\n */\n vX: function (ind) { return vx[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} ind - sprite rotation angle.\n * @return {PIXI.GD8Symmetry} The Y-component of the V-axis\n * after rotating the axes.\n */\n vY: function (ind) { return vy[ind]; },\n /**\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotation - symmetry whose opposite\n * is needed. Only rotations have opposite symmetries while\n * reflections don't.\n * @return {PIXI.GD8Symmetry} The opposite symmetry of `rotation`\n */\n inv: function (rotation) {\n if (rotation & 8) // true only if between 8 & 15 (reflections)\n {\n return rotation & 15; // or rotation % 16\n }\n return (-rotation) & 7; // or (8 - rotation) % 8\n },\n /**\n * Composes the two D8 operations.\n *\n * Taking `^` as reflection:\n *\n * | | E=0 | S=2 | W=4 | N=6 | E^=8 | S^=10 | W^=12 | N^=14 |\n * |-------|-----|-----|-----|-----|------|-------|-------|-------|\n * | E=0 | E | S | W | N | E^ | S^ | W^ | N^ |\n * | S=2 | S | W | N | E | S^ | W^ | N^ | E^ |\n * | W=4 | W | N | E | S | W^ | N^ | E^ | S^ |\n * | N=6 | N | E | S | W | N^ | E^ | S^ | W^ |\n * | E^=8 | E^ | N^ | W^ | S^ | E | N | W | S |\n * | S^=10 | S^ | E^ | N^ | W^ | S | E | N | W |\n * | W^=12 | W^ | S^ | E^ | N^ | W | S | E | N |\n * | N^=14 | N^ | W^ | S^ | E^ | N | W | S | E |\n *\n * [This is a Cayley table]{@link https://en.wikipedia.org/wiki/Cayley_table}\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotationSecond - Second operation, which\n * is the row in the above cayley table.\n * @param {PIXI.GD8Symmetry} rotationFirst - First operation, which\n * is the column in the above cayley table.\n * @return {PIXI.GD8Symmetry} Composed operation\n */\n add: function (rotationSecond, rotationFirst) { return (rotationCayley[rotationSecond][rotationFirst]); },\n /**\n * Reverse of `add`.\n *\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotationSecond - Second operation\n * @param {PIXI.GD8Symmetry} rotationFirst - First operation\n * @return {PIXI.GD8Symmetry} Result\n */\n sub: function (rotationSecond, rotationFirst) { return (rotationCayley[rotationSecond][groupD8.inv(rotationFirst)]); },\n /**\n * Adds 180 degrees to rotation, which is a commutative\n * operation.\n *\n * @memberof PIXI.groupD8\n * @param {number} rotation - The number to rotate.\n * @returns {number} Rotated number\n */\n rotate180: function (rotation) { return rotation ^ 4; },\n /**\n * Checks if the rotation angle is vertical, i.e. south\n * or north. It doesn't work for reflections.\n *\n * @memberof PIXI.groupD8\n * @param {PIXI.GD8Symmetry} rotation - The number to check.\n * @returns {boolean} Whether or not the direction is vertical\n */\n isVertical: function (rotation) { return (rotation & 3) === 2; },\n /**\n * Approximates the vector `V(dx,dy)` into one of the\n * eight directions provided by `groupD8`.\n *\n * @memberof PIXI.groupD8\n * @param {number} dx - X-component of the vector\n * @param {number} dy - Y-component of the vector\n * @return {PIXI.GD8Symmetry} Approximation of the vector into\n * one of the eight symmetries.\n */\n byDirection: function (dx, dy) {\n if (Math.abs(dx) * 2 <= Math.abs(dy)) {\n if (dy >= 0) {\n return groupD8.S;\n }\n return groupD8.N;\n }\n else if (Math.abs(dy) * 2 <= Math.abs(dx)) {\n if (dx > 0) {\n return groupD8.E;\n }\n return groupD8.W;\n }\n else if (dy > 0) {\n if (dx > 0) {\n return groupD8.SE;\n }\n return groupD8.SW;\n }\n else if (dx > 0) {\n return groupD8.NE;\n }\n return groupD8.NW;\n },\n /**\n * Helps sprite to compensate texture packer rotation.\n *\n * @memberof PIXI.groupD8\n * @param {PIXI.Matrix} matrix - sprite world matrix\n * @param {PIXI.GD8Symmetry} rotation - The rotation factor to use.\n * @param {number} tx - sprite anchoring\n * @param {number} ty - sprite anchoring\n */\n matrixAppendRotationInv: function (matrix, rotation, tx, ty) {\n if (tx === void 0) { tx = 0; }\n if (ty === void 0) { ty = 0; }\n // Packer used \"rotation\", we use \"inv(rotation)\"\n var mat = rotationMatrices[groupD8.inv(rotation)];\n mat.tx = tx;\n mat.ty = ty;\n matrix.append(mat);\n },\n};\n\n/**\n * Transform that takes care about its versions.\n *\n * @memberof PIXI\n */\nvar Transform = /** @class */ (function () {\n function Transform() {\n this.worldTransform = new Matrix();\n this.localTransform = new Matrix();\n this.position = new ObservablePoint(this.onChange, this, 0, 0);\n this.scale = new ObservablePoint(this.onChange, this, 1, 1);\n this.pivot = new ObservablePoint(this.onChange, this, 0, 0);\n this.skew = new ObservablePoint(this.updateSkew, this, 0, 0);\n this._rotation = 0;\n this._cx = 1;\n this._sx = 0;\n this._cy = 0;\n this._sy = 1;\n this._localID = 0;\n this._currentLocalID = 0;\n this._worldID = 0;\n this._parentID = 0;\n }\n /** Called when a value changes. */\n Transform.prototype.onChange = function () {\n this._localID++;\n };\n /** Called when the skew or the rotation changes. */\n Transform.prototype.updateSkew = function () {\n this._cx = Math.cos(this._rotation + this.skew.y);\n this._sx = Math.sin(this._rotation + this.skew.y);\n this._cy = -Math.sin(this._rotation - this.skew.x); // cos, added PI/2\n this._sy = Math.cos(this._rotation - this.skew.x); // sin, added PI/2\n this._localID++;\n };\n Transform.prototype.toString = function () {\n return \"[@pixi/math:Transform \"\n + (\"position=(\" + this.position.x + \", \" + this.position.y + \") \")\n + (\"rotation=\" + this.rotation + \" \")\n + (\"scale=(\" + this.scale.x + \", \" + this.scale.y + \") \")\n + (\"skew=(\" + this.skew.x + \", \" + this.skew.y + \") \")\n + \"]\";\n };\n /** Updates the local transformation matrix. */\n Transform.prototype.updateLocalTransform = function () {\n var lt = this.localTransform;\n if (this._localID !== this._currentLocalID) {\n // get the matrix values of the displayobject based on its transform properties..\n lt.a = this._cx * this.scale.x;\n lt.b = this._sx * this.scale.x;\n lt.c = this._cy * this.scale.y;\n lt.d = this._sy * this.scale.y;\n lt.tx = this.position.x - ((this.pivot.x * lt.a) + (this.pivot.y * lt.c));\n lt.ty = this.position.y - ((this.pivot.x * lt.b) + (this.pivot.y * lt.d));\n this._currentLocalID = this._localID;\n // force an update..\n this._parentID = -1;\n }\n };\n /**\n * Updates the local and the world transformation matrices.\n *\n * @param parentTransform - The parent transform\n */\n Transform.prototype.updateTransform = function (parentTransform) {\n var lt = this.localTransform;\n if (this._localID !== this._currentLocalID) {\n // get the matrix values of the displayobject based on its transform properties..\n lt.a = this._cx * this.scale.x;\n lt.b = this._sx * this.scale.x;\n lt.c = this._cy * this.scale.y;\n lt.d = this._sy * this.scale.y;\n lt.tx = this.position.x - ((this.pivot.x * lt.a) + (this.pivot.y * lt.c));\n lt.ty = this.position.y - ((this.pivot.x * lt.b) + (this.pivot.y * lt.d));\n this._currentLocalID = this._localID;\n // force an update..\n this._parentID = -1;\n }\n if (this._parentID !== parentTransform._worldID) {\n // concat the parent matrix with the objects transform.\n var pt = parentTransform.worldTransform;\n var wt = this.worldTransform;\n wt.a = (lt.a * pt.a) + (lt.b * pt.c);\n wt.b = (lt.a * pt.b) + (lt.b * pt.d);\n wt.c = (lt.c * pt.a) + (lt.d * pt.c);\n wt.d = (lt.c * pt.b) + (lt.d * pt.d);\n wt.tx = (lt.tx * pt.a) + (lt.ty * pt.c) + pt.tx;\n wt.ty = (lt.tx * pt.b) + (lt.ty * pt.d) + pt.ty;\n this._parentID = parentTransform._worldID;\n // update the id of the transform..\n this._worldID++;\n }\n };\n /**\n * Decomposes a matrix and sets the transforms properties based on it.\n *\n * @param matrix - The matrix to decompose\n */\n Transform.prototype.setFromMatrix = function (matrix) {\n matrix.decompose(this);\n this._localID++;\n };\n Object.defineProperty(Transform.prototype, \"rotation\", {\n /** The rotation of the object in radians. */\n get: function () {\n return this._rotation;\n },\n set: function (value) {\n if (this._rotation !== value) {\n this._rotation = value;\n this.updateSkew();\n }\n },\n enumerable: false,\n configurable: true\n });\n /** A default (identity) transform. */\n Transform.IDENTITY = new Transform();\n return Transform;\n}());\n\nexport { Circle, DEG_TO_RAD, Ellipse, Matrix, ObservablePoint, PI_2, Point, Polygon, RAD_TO_DEG, Rectangle, RoundedRectangle, SHAPES, Transform, groupD8 };\n//# sourceMappingURL=math.js.map\n","/*!\n * @pixi/particle-emitter - v5.0.4\n * Compiled Thu, 10 Mar 2022 03:05:06 UTC\n *\n * @pixi/particle-emitter is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture } from '@pixi/core';\nimport { BLEND_MODES } from '@pixi/constants';\nimport { Sprite } from '@pixi/sprite';\nimport { settings } from '@pixi/settings';\nimport { Point } from '@pixi/math';\nimport { Ticker } from '@pixi/ticker';\nimport { Container, DisplayObject } from '@pixi/display';\n\n/**\r\n * A single node in a PropertyList.\r\n */\r\nclass PropertyNode {\r\n /**\r\n * @param value The value for this node\r\n * @param time The time for this node, between 0-1\r\n * @param [ease] Custom ease for this list. Only relevant for the first node.\r\n */\r\n constructor(value, time, ease) {\r\n this.value = value;\r\n this.time = time;\r\n this.next = null;\r\n this.isStepped = false;\r\n if (ease) {\r\n this.ease = typeof ease === 'function' ? ease : generateEase(ease);\r\n }\r\n else {\r\n this.ease = null;\r\n }\r\n }\r\n /**\r\n * Creates a list of property values from a data object {list, isStepped} with a list of objects in\r\n * the form {value, time}. Alternatively, the data object can be in the deprecated form of\r\n * {start, end}.\r\n * @param data The data for the list.\r\n * @param data.list The array of value and time objects.\r\n * @param data.isStepped If the list is stepped rather than interpolated.\r\n * @param data.ease Custom ease for this list.\r\n * @return The first node in the list\r\n */\r\n // eslint-disable-next-line max-len\r\n static createList(data) {\r\n if ('list' in data) {\r\n const array = data.list;\r\n let node;\r\n const { value, time } = array[0];\r\n // eslint-disable-next-line max-len\r\n const first = node = new PropertyNode(typeof value === 'string' ? hexToRGB(value) : value, time, data.ease);\r\n // only set up subsequent nodes if there are a bunch or the 2nd one is different from the first\r\n if (array.length > 2 || (array.length === 2 && array[1].value !== value)) {\r\n for (let i = 1; i < array.length; ++i) {\r\n const { value, time } = array[i];\r\n node.next = new PropertyNode(typeof value === 'string' ? hexToRGB(value) : value, time);\r\n node = node.next;\r\n }\r\n }\r\n first.isStepped = !!data.isStepped;\r\n return first;\r\n }\r\n // Handle deprecated version here\r\n const start = new PropertyNode(typeof data.start === 'string' ? hexToRGB(data.start) : data.start, 0);\r\n // only set up a next value if it is different from the starting value\r\n if (data.end !== data.start) {\r\n start.next = new PropertyNode(typeof data.end === 'string' ? hexToRGB(data.end) : data.end, 1);\r\n }\r\n return start;\r\n }\r\n}\n\n/**\r\n * The method used by behaviors to fetch textures. Defaults to Texture.from.\r\n */\r\n// get Texture.from(), only supports V5 and V6 with individual packages\r\n// eslint-disable-next-line prefer-const\r\nlet GetTextureFromString = Texture.from;\r\n/**\r\n * If errors and warnings should be logged within the library.\r\n */\r\nconst verbose = false;\r\nconst DEG_TO_RADS = Math.PI / 180;\r\n/**\r\n * Rotates a point by a given angle.\r\n * @param angle The angle to rotate by in radians\r\n * @param p The point to rotate around 0,0.\r\n */\r\nfunction rotatePoint(angle, p) {\r\n if (!angle)\r\n return;\r\n const s = Math.sin(angle);\r\n const c = Math.cos(angle);\r\n const xnew = (p.x * c) - (p.y * s);\r\n const ynew = (p.x * s) + (p.y * c);\r\n p.x = xnew;\r\n p.y = ynew;\r\n}\r\n/**\r\n * Combines separate color components (0-255) into a single uint color.\r\n * @param r The red value of the color\r\n * @param g The green value of the color\r\n * @param b The blue value of the color\r\n * @return The color in the form of 0xRRGGBB\r\n */\r\nfunction combineRGBComponents(r, g, b /* , a*/) {\r\n return /* a << 24 |*/ (r << 16) | (g << 8) | b;\r\n}\r\n/**\r\n * Returns the length (or magnitude) of this point.\r\n * @param point The point to measure length\r\n * @return The length of this point.\r\n */\r\nfunction length(point) {\r\n return Math.sqrt((point.x * point.x) + (point.y * point.y));\r\n}\r\n/**\r\n * Reduces the point to a length of 1.\r\n * @param point The point to normalize\r\n */\r\nfunction normalize(point) {\r\n const oneOverLen = 1 / length(point);\r\n point.x *= oneOverLen;\r\n point.y *= oneOverLen;\r\n}\r\n/**\r\n * Multiplies the x and y values of this point by a value.\r\n * @param point The point to scaleBy\r\n * @param value The value to scale by.\r\n */\r\nfunction scaleBy(point, value) {\r\n point.x *= value;\r\n point.y *= value;\r\n}\r\n/**\r\n * Converts a hex string from \"#AARRGGBB\", \"#RRGGBB\", \"0xAARRGGBB\", \"0xRRGGBB\",\r\n * \"AARRGGBB\", or \"RRGGBB\" to an object of ints of 0-255, as\r\n * {r, g, b, (a)}.\r\n * @param color The input color string.\r\n * @param output An object to put the output in. If omitted, a new object is created.\r\n * @return The object with r, g, and b properties, possibly with an a property.\r\n */\r\nfunction hexToRGB(color, output) {\r\n if (!output) {\r\n output = {};\r\n }\r\n if (color.charAt(0) === '#') {\r\n color = color.substr(1);\r\n }\r\n else if (color.indexOf('0x') === 0) {\r\n color = color.substr(2);\r\n }\r\n let alpha;\r\n if (color.length === 8) {\r\n alpha = color.substr(0, 2);\r\n color = color.substr(2);\r\n }\r\n output.r = parseInt(color.substr(0, 2), 16); // Red\r\n output.g = parseInt(color.substr(2, 2), 16); // Green\r\n output.b = parseInt(color.substr(4, 2), 16); // Blue\r\n if (alpha) {\r\n output.a = parseInt(alpha, 16);\r\n }\r\n return output;\r\n}\r\n/**\r\n * Generates a custom ease function, based on the GreenSock custom ease, as demonstrated\r\n * by the related tool at http://www.greensock.com/customease/.\r\n * @param segments An array of segments, as created by\r\n * http://www.greensock.com/customease/.\r\n * @return A function that calculates the percentage of change at\r\n * a given point in time (0-1 inclusive).\r\n */\r\nfunction generateEase(segments) {\r\n const qty = segments.length;\r\n const oneOverQty = 1 / qty;\r\n /*\r\n * Calculates the percentage of change at a given point in time (0-1 inclusive).\r\n * @param {Number} time The time of the ease, 0-1 inclusive.\r\n * @return {Number} The percentage of the change, 0-1 inclusive (unless your\r\n * ease goes outside those bounds).\r\n */\r\n // eslint-disable-next-line func-names\r\n return function (time) {\r\n const i = (qty * time) | 0; // do a quick floor operation\r\n const t = (time - (i * oneOverQty)) * qty;\r\n const s = segments[i] || segments[qty - 1];\r\n return (s.s + (t * ((2 * (1 - t) * (s.cp - s.s)) + (t * (s.e - s.s)))));\r\n };\r\n}\r\n/**\r\n * Gets a blend mode, ensuring that it is valid.\r\n * @param name The name of the blend mode to get.\r\n * @return The blend mode as specified in the PIXI.BLEND_MODES enumeration.\r\n */\r\nfunction getBlendMode(name) {\r\n if (!name)\r\n return BLEND_MODES.NORMAL;\r\n name = name.toUpperCase().replace(/ /g, '_');\r\n return BLEND_MODES[name] || BLEND_MODES.NORMAL;\r\n}\r\n/**\r\n * Converts a list of {value, time} objects starting at time 0 and ending at time 1 into an evenly\r\n * spaced stepped list of PropertyNodes for color values. This is primarily to handle conversion of\r\n * linear gradients to fewer colors, allowing for some optimization for Canvas2d fallbacks.\r\n * @param list The list of data to convert.\r\n * @param [numSteps=10] The number of steps to use.\r\n * @return The blend mode as specified in the PIXI.blendModes enumeration.\r\n */\r\nfunction createSteppedGradient(list, numSteps = 10) {\r\n if (typeof numSteps !== 'number' || numSteps <= 0) {\r\n numSteps = 10;\r\n }\r\n const first = new PropertyNode(hexToRGB(list[0].value), list[0].time);\r\n first.isStepped = true;\r\n let currentNode = first;\r\n let current = list[0];\r\n let nextIndex = 1;\r\n let next = list[nextIndex];\r\n for (let i = 1; i < numSteps; ++i) {\r\n let lerp = i / numSteps;\r\n // ensure we are on the right segment, if multiple\r\n while (lerp > next.time) {\r\n current = next;\r\n next = list[++nextIndex];\r\n }\r\n // convert the lerp value to the segment range\r\n lerp = (lerp - current.time) / (next.time - current.time);\r\n const curVal = hexToRGB(current.value);\r\n const nextVal = hexToRGB(next.value);\r\n const output = {\r\n r: ((nextVal.r - curVal.r) * lerp) + curVal.r,\r\n g: ((nextVal.g - curVal.g) * lerp) + curVal.g,\r\n b: ((nextVal.b - curVal.b) * lerp) + curVal.b,\r\n };\r\n currentNode.next = new PropertyNode(output, i / numSteps);\r\n currentNode = currentNode.next;\r\n }\r\n // we don't need to have a PropertyNode for time of 1, because in a stepped version at that point\r\n // the particle has died of old age\r\n return first;\r\n}\n\nvar ParticleUtils = {\n __proto__: null,\n GetTextureFromString: GetTextureFromString,\n verbose: verbose,\n DEG_TO_RADS: DEG_TO_RADS,\n rotatePoint: rotatePoint,\n combineRGBComponents: combineRGBComponents,\n length: length,\n normalize: normalize,\n scaleBy: scaleBy,\n hexToRGB: hexToRGB,\n generateEase: generateEase,\n getBlendMode: getBlendMode,\n createSteppedGradient: createSteppedGradient\n};\n\n/**\r\n * An individual particle image. You shouldn't have to deal with these.\r\n */\r\nclass Particle extends Sprite {\r\n /**\r\n * @param emitter The emitter that controls this particle.\r\n */\r\n constructor(emitter) {\r\n // start off the sprite with a blank texture, since we are going to replace it\r\n // later when the particle is initialized.\r\n super();\r\n // initialize LinkedListChild props so they are included in underlying JS class definition\r\n this.prevChild = this.nextChild = null;\r\n this.emitter = emitter;\r\n this.config = {};\r\n // particles should be centered\r\n this.anchor.x = this.anchor.y = 0.5;\r\n this.maxLife = 0;\r\n this.age = 0;\r\n this.agePercent = 0;\r\n this.oneOverLife = 0;\r\n this.next = null;\r\n this.prev = null;\r\n // save often used functions on the instance instead of the prototype for better speed\r\n this.init = this.init;\r\n this.kill = this.kill;\r\n }\r\n /**\r\n * Initializes the particle for use, based on the properties that have to\r\n * have been set already on the particle.\r\n */\r\n init(maxLife) {\r\n this.maxLife = maxLife;\r\n // reset the age\r\n this.age = this.agePercent = 0;\r\n // reset the sprite props\r\n this.rotation = 0;\r\n this.position.x = this.position.y = 0;\r\n this.scale.x = this.scale.y = 1;\r\n this.tint = 0xffffff;\r\n this.alpha = 1;\r\n // save our lerp helper\r\n this.oneOverLife = 1 / this.maxLife;\r\n // ensure visibility\r\n this.visible = true;\r\n }\r\n /**\r\n * Kills the particle, removing it from the display list\r\n * and telling the emitter to recycle it.\r\n */\r\n kill() {\r\n this.emitter.recycle(this);\r\n }\r\n /**\r\n * Destroys the particle, removing references and preventing future use.\r\n */\r\n destroy() {\r\n if (this.parent) {\r\n this.parent.removeChild(this);\r\n }\r\n this.emitter = this.next = this.prev = null;\r\n super.destroy();\r\n }\r\n}\n\n/**\r\n * Standard behavior order values, specifying when/how they are used. Other numeric values can be used,\r\n * but only the Spawn value will be handled in a special way. All other values will be sorted numerically.\r\n * Behaviors with the same value will not be given any specific sort order, as they are assumed to not\r\n * interfere with each other.\r\n */\r\nvar BehaviorOrder;\r\n(function (BehaviorOrder) {\r\n /**\r\n * Spawn - initial placement and/or rotation. This happens before rotation/translation due to\r\n * emitter rotation/position is applied.\r\n */\r\n BehaviorOrder[BehaviorOrder[\"Spawn\"] = 0] = \"Spawn\";\r\n /**\r\n * Normal priority, for things that don't matter when they are applied.\r\n */\r\n BehaviorOrder[BehaviorOrder[\"Normal\"] = 2] = \"Normal\";\r\n /**\r\n * Delayed priority, for things that need to read other values in order to act correctly.\r\n */\r\n BehaviorOrder[BehaviorOrder[\"Late\"] = 5] = \"Late\";\r\n})(BehaviorOrder || (BehaviorOrder = {}));\n\n// get the shared ticker, only supports V5 and V6 with individual packages\r\n/**\r\n * @hidden\r\n */\r\nconst ticker = Ticker.shared;\r\n/**\r\n * Key used in sorted order to determine when to set particle position from the emitter position\r\n * and rotation.\r\n */\r\nconst PositionParticle = Symbol('Position particle per emitter position');\r\n/**\r\n * A particle emitter.\r\n */\r\nclass Emitter {\r\n /**\r\n * @param particleParent The container to add the particles to.\r\n * @param particleImages A texture or array of textures to use\r\n * for the particles. Strings will be turned\r\n * into textures via Texture.from().\r\n * @param config A configuration object containing settings for the emitter.\r\n * @param config.emit If config.emit is explicitly passed as false, the\r\n * Emitter will start disabled.\r\n * @param config.autoUpdate If config.autoUpdate is explicitly passed as\r\n * true, the Emitter will automatically call\r\n * update via the PIXI shared ticker.\r\n */\r\n constructor(particleParent, config) {\r\n this.initBehaviors = [];\r\n this.updateBehaviors = [];\r\n this.recycleBehaviors = [];\r\n // properties for individual particles\r\n this.minLifetime = 0;\r\n this.maxLifetime = 0;\r\n this.customEase = null;\r\n // properties for spawning particles\r\n this._frequency = 1;\r\n this.spawnChance = 1;\r\n this.maxParticles = 1000;\r\n this.emitterLifetime = -1;\r\n this.spawnPos = new Point();\r\n this.particlesPerWave = 1;\r\n // emitter properties\r\n this.rotation = 0;\r\n this.ownerPos = new Point();\r\n this._prevEmitterPos = new Point();\r\n this._prevPosIsValid = false;\r\n this._posChanged = false;\r\n this._parent = null;\r\n this.addAtBack = false;\r\n this.particleCount = 0;\r\n this._emit = false;\r\n this._spawnTimer = 0;\r\n this._emitterLife = -1;\r\n this._activeParticlesFirst = null;\r\n this._activeParticlesLast = null;\r\n this._poolFirst = null;\r\n this._origConfig = null;\r\n this._autoUpdate = false;\r\n this._destroyWhenComplete = false;\r\n this._completeCallback = null;\r\n // set the initial parent\r\n this.parent = particleParent;\r\n if (config) {\r\n this.init(config);\r\n }\r\n // save often used functions on the instance instead of the prototype for better speed\r\n this.recycle = this.recycle;\r\n this.update = this.update;\r\n this.rotate = this.rotate;\r\n this.updateSpawnPos = this.updateSpawnPos;\r\n this.updateOwnerPos = this.updateOwnerPos;\r\n }\r\n /**\r\n * Registers a new behavior, so that it will be recognized when initializing emitters.\r\n * Behaviors registered later with duplicate types will override older ones, although there is no limit on\r\n * the allowed types.\r\n * @param constructor The behavior class to register.\r\n */\r\n static registerBehavior(constructor) {\r\n Emitter.knownBehaviors[constructor.type] = constructor;\r\n }\r\n /**\r\n * Time between particle spawns in seconds. If this value is not a number greater than 0,\r\n * it will be set to 1 (particle per second) to prevent infinite loops.\r\n */\r\n get frequency() { return this._frequency; }\r\n set frequency(value) {\r\n // do some error checking to prevent infinite loops\r\n if (typeof value === 'number' && value > 0) {\r\n this._frequency = value;\r\n }\r\n else {\r\n this._frequency = 1;\r\n }\r\n }\r\n /**\r\n * The container to add particles to. Settings this will dump any active particles.\r\n */\r\n get parent() { return this._parent; }\r\n set parent(value) {\r\n this.cleanup();\r\n this._parent = value;\r\n }\r\n /**\r\n * Sets up the emitter based on the config settings.\r\n * @param config A configuration object containing settings for the emitter.\r\n */\r\n init(config) {\r\n if (!config) {\r\n return;\r\n }\r\n // clean up any existing particles\r\n this.cleanup();\r\n // store the original config and particle images, in case we need to re-initialize\r\n // when the particle constructor is changed\r\n this._origConfig = config;\r\n // /////////////////////////\r\n // Particle Properties //\r\n // /////////////////////////\r\n // set up the lifetime\r\n this.minLifetime = config.lifetime.min;\r\n this.maxLifetime = config.lifetime.max;\r\n // use the custom ease if provided\r\n if (config.ease) {\r\n this.customEase = typeof config.ease === 'function'\r\n ? config.ease : generateEase(config.ease);\r\n }\r\n else {\r\n this.customEase = null;\r\n }\r\n // ////////////////////////\r\n // Emitter Properties //\r\n // ////////////////////////\r\n // reset spawn type specific settings\r\n this.particlesPerWave = 1;\r\n if (config.particlesPerWave && config.particlesPerWave > 1) {\r\n this.particlesPerWave = config.particlesPerWave;\r\n }\r\n // set the spawning frequency\r\n this.frequency = config.frequency;\r\n this.spawnChance = (typeof config.spawnChance === 'number' && config.spawnChance > 0) ? config.spawnChance : 1;\r\n // set the emitter lifetime\r\n this.emitterLifetime = config.emitterLifetime || -1;\r\n // set the max particles\r\n this.maxParticles = config.maxParticles > 0 ? config.maxParticles : 1000;\r\n // determine if we should add the particle at the back of the list or not\r\n this.addAtBack = !!config.addAtBack;\r\n // reset the emitter position and rotation variables\r\n this.rotation = 0;\r\n this.ownerPos.set(0);\r\n if (config.pos) {\r\n this.spawnPos.copyFrom(config.pos);\r\n }\r\n else {\r\n this.spawnPos.set(0);\r\n }\r\n this._prevEmitterPos.copyFrom(this.spawnPos);\r\n // previous emitter position is invalid and should not be used for interpolation\r\n this._prevPosIsValid = false;\r\n // start emitting\r\n this._spawnTimer = 0;\r\n this.emit = config.emit === undefined ? true : !!config.emit;\r\n this.autoUpdate = !!config.autoUpdate;\r\n // ////////////////////////\r\n // Behaviors //\r\n // ////////////////////////\r\n const behaviors = config.behaviors.map((data) => {\r\n const constructor = Emitter.knownBehaviors[data.type];\r\n if (!constructor) {\r\n console.error(`Unknown behavior: ${data.type}`);\r\n return null;\r\n }\r\n return new constructor(data.config);\r\n })\r\n .filter((b) => !!b);\r\n behaviors.push(PositionParticle);\r\n behaviors.sort((a, b) => {\r\n if (a === PositionParticle) {\r\n return b.order === BehaviorOrder.Spawn ? 1 : -1;\r\n }\r\n else if (b === PositionParticle) {\r\n return a.order === BehaviorOrder.Spawn ? -1 : 1;\r\n }\r\n return a.order - b.order;\r\n });\r\n this.initBehaviors = behaviors.slice();\r\n this.updateBehaviors = behaviors.filter((b) => b !== PositionParticle && b.updateParticle);\r\n this.recycleBehaviors = behaviors.filter((b) => b !== PositionParticle && b.recycleParticle);\r\n }\r\n /**\r\n * Gets the instantiated behavior of the specified type, if it is present on this emitter.\r\n * @param type The behavior type to find.\r\n */\r\n getBehavior(type) {\r\n // bail if we don't know about such an emitter\r\n if (!Emitter.knownBehaviors[type])\r\n return null;\r\n // find one that is an instance of the specified type\r\n return this.initBehaviors.find((b) => b instanceof Emitter.knownBehaviors[type]) || null;\r\n }\r\n /**\r\n * Fills the pool with the specified number of particles, so that they don't have to be instantiated later.\r\n * @param count The number of particles to create.\r\n */\r\n fillPool(count) {\r\n for (; count > 0; --count) {\r\n const p = new Particle(this);\r\n p.next = this._poolFirst;\r\n this._poolFirst = p;\r\n }\r\n }\r\n /**\r\n * Recycles an individual particle. For internal use only.\r\n * @param particle The particle to recycle.\r\n * @param fromCleanup If this is being called to manually clean up all particles.\r\n * @internal\r\n */\r\n recycle(particle, fromCleanup = false) {\r\n for (let i = 0; i < this.recycleBehaviors.length; ++i) {\r\n this.recycleBehaviors[i].recycleParticle(particle, !fromCleanup);\r\n }\r\n if (particle.next) {\r\n particle.next.prev = particle.prev;\r\n }\r\n if (particle.prev) {\r\n particle.prev.next = particle.next;\r\n }\r\n if (particle === this._activeParticlesLast) {\r\n this._activeParticlesLast = particle.prev;\r\n }\r\n if (particle === this._activeParticlesFirst) {\r\n this._activeParticlesFirst = particle.next;\r\n }\r\n // add to pool\r\n particle.prev = null;\r\n particle.next = this._poolFirst;\r\n this._poolFirst = particle;\r\n // remove child from display, or make it invisible if it is in a ParticleContainer\r\n if (particle.parent) {\r\n particle.parent.removeChild(particle);\r\n }\r\n // decrease count\r\n --this.particleCount;\r\n }\r\n /**\r\n * Sets the rotation of the emitter to a new value. This rotates the spawn position in addition\r\n * to particle direction.\r\n * @param newRot The new rotation, in degrees.\r\n */\r\n rotate(newRot) {\r\n if (this.rotation === newRot)\r\n return;\r\n // caclulate the difference in rotation for rotating spawnPos\r\n const diff = newRot - this.rotation;\r\n this.rotation = newRot;\r\n // rotate spawnPos\r\n rotatePoint(diff, this.spawnPos);\r\n // mark the position as having changed\r\n this._posChanged = true;\r\n }\r\n /**\r\n * Changes the spawn position of the emitter.\r\n * @param x The new x value of the spawn position for the emitter.\r\n * @param y The new y value of the spawn position for the emitter.\r\n */\r\n updateSpawnPos(x, y) {\r\n this._posChanged = true;\r\n this.spawnPos.x = x;\r\n this.spawnPos.y = y;\r\n }\r\n /**\r\n * Changes the position of the emitter's owner. You should call this if you are adding\r\n * particles to the world container that your emitter's owner is moving around in.\r\n * @param x The new x value of the emitter's owner.\r\n * @param y The new y value of the emitter's owner.\r\n */\r\n updateOwnerPos(x, y) {\r\n this._posChanged = true;\r\n this.ownerPos.x = x;\r\n this.ownerPos.y = y;\r\n }\r\n /**\r\n * Prevents emitter position interpolation in the next update.\r\n * This should be used if you made a major position change of your emitter's owner\r\n * that was not normal movement.\r\n */\r\n resetPositionTracking() {\r\n this._prevPosIsValid = false;\r\n }\r\n /**\r\n * If particles should be emitted during update() calls. Setting this to false\r\n * stops new particles from being created, but allows existing ones to die out.\r\n */\r\n get emit() { return this._emit; }\r\n set emit(value) {\r\n this._emit = !!value;\r\n this._emitterLife = this.emitterLifetime;\r\n }\r\n /**\r\n * If the update function is called automatically from the shared ticker.\r\n * Setting this to false requires calling the update function manually.\r\n */\r\n get autoUpdate() { return this._autoUpdate; }\r\n set autoUpdate(value) {\r\n if (this._autoUpdate && !value) {\r\n ticker.remove(this.update, this);\r\n }\r\n else if (!this._autoUpdate && value) {\r\n ticker.add(this.update, this);\r\n }\r\n this._autoUpdate = !!value;\r\n }\r\n /**\r\n * Starts emitting particles, sets autoUpdate to true, and sets up the Emitter to destroy itself\r\n * when particle emission is complete.\r\n * @param callback Callback for when emission is complete (all particles have died off)\r\n */\r\n playOnceAndDestroy(callback) {\r\n this.autoUpdate = true;\r\n this.emit = true;\r\n this._destroyWhenComplete = true;\r\n this._completeCallback = callback;\r\n }\r\n /**\r\n * Starts emitting particles and optionally calls a callback when particle emission is complete.\r\n * @param callback Callback for when emission is complete (all particles have died off)\r\n */\r\n playOnce(callback) {\r\n this.emit = true;\r\n this._completeCallback = callback;\r\n }\r\n /**\r\n * Updates all particles spawned by this emitter and emits new ones.\r\n * @param delta Time elapsed since the previous frame, in __seconds__.\r\n */\r\n update(delta) {\r\n if (this._autoUpdate) {\r\n delta = delta / settings.TARGET_FPMS / 1000;\r\n }\r\n // if we don't have a parent to add particles to, then don't do anything.\r\n // this also works as a isDestroyed check\r\n if (!this._parent)\r\n return;\r\n // == update existing particles ==\r\n // update all particle lifetimes before turning them over to behaviors\r\n for (let particle = this._activeParticlesFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // increase age\r\n particle.age += delta;\r\n // recycle particle if it is too old\r\n if (particle.age > particle.maxLife || particle.age < 0) {\r\n this.recycle(particle);\r\n }\r\n else {\r\n // determine our interpolation value\r\n let lerp = particle.age * particle.oneOverLife; // lifetime / maxLife;\r\n // global ease affects all interpolation calculations\r\n if (this.customEase) {\r\n if (this.customEase.length === 4) {\r\n // the t, b, c, d parameters that some tween libraries use\r\n // (time, initial value, end value, duration)\r\n lerp = this.customEase(lerp, 0, 1, 1);\r\n }\r\n else {\r\n // the simplified version that we like that takes\r\n // one parameter, time from 0-1. TweenJS eases provide this usage.\r\n lerp = this.customEase(lerp);\r\n }\r\n }\r\n // set age percent for all interpolation calculations\r\n particle.agePercent = lerp;\r\n // let each behavior run wild on the active particles\r\n for (let i = 0; i < this.updateBehaviors.length; ++i) {\r\n if (this.updateBehaviors[i].updateParticle(particle, delta)) {\r\n this.recycle(particle);\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n let prevX;\r\n let prevY;\r\n // if the previous position is valid, store these for later interpolation\r\n if (this._prevPosIsValid) {\r\n prevX = this._prevEmitterPos.x;\r\n prevY = this._prevEmitterPos.y;\r\n }\r\n // store current position of the emitter as local variables\r\n const curX = this.ownerPos.x + this.spawnPos.x;\r\n const curY = this.ownerPos.y + this.spawnPos.y;\r\n // spawn new particles\r\n if (this._emit) {\r\n // decrease spawn timer\r\n this._spawnTimer -= delta < 0 ? 0 : delta;\r\n // while _spawnTimer < 0, we have particles to spawn\r\n while (this._spawnTimer <= 0) {\r\n // determine if the emitter should stop spawning\r\n if (this._emitterLife >= 0) {\r\n this._emitterLife -= this._frequency;\r\n if (this._emitterLife <= 0) {\r\n this._spawnTimer = 0;\r\n this._emitterLife = 0;\r\n this.emit = false;\r\n break;\r\n }\r\n }\r\n // determine if we have hit the particle limit\r\n if (this.particleCount >= this.maxParticles) {\r\n this._spawnTimer += this._frequency;\r\n continue;\r\n }\r\n let emitPosX;\r\n let emitPosY;\r\n // If the position has changed and this isn't the first spawn,\r\n // interpolate the spawn position\r\n if (this._prevPosIsValid && this._posChanged) {\r\n // 1 - _spawnTimer / delta, but _spawnTimer is negative\r\n const lerp = 1 + (this._spawnTimer / delta);\r\n emitPosX = ((curX - prevX) * lerp) + prevX;\r\n emitPosY = ((curY - prevY) * lerp) + prevY;\r\n }\r\n // otherwise just set to the spawn position\r\n else {\r\n emitPosX = curX;\r\n emitPosY = curY;\r\n }\r\n let waveFirst = null;\r\n let waveLast = null;\r\n // create enough particles to fill the wave\r\n for (let len = Math.min(this.particlesPerWave, this.maxParticles - this.particleCount), i = 0; i < len; ++i) {\r\n // see if we actually spawn one\r\n if (this.spawnChance < 1 && Math.random() >= this.spawnChance) {\r\n continue;\r\n }\r\n // determine the particle lifetime\r\n let lifetime;\r\n if (this.minLifetime === this.maxLifetime) {\r\n lifetime = this.minLifetime;\r\n }\r\n else {\r\n lifetime = (Math.random() * (this.maxLifetime - this.minLifetime)) + this.minLifetime;\r\n }\r\n // only make the particle if it wouldn't immediately destroy itself\r\n if (-this._spawnTimer >= lifetime) {\r\n continue;\r\n }\r\n // create particle\r\n let p;\r\n if (this._poolFirst) {\r\n p = this._poolFirst;\r\n this._poolFirst = this._poolFirst.next;\r\n p.next = null;\r\n }\r\n else {\r\n p = new Particle(this);\r\n }\r\n // initialize particle\r\n p.init(lifetime);\r\n // add the particle to the display list\r\n if (this.addAtBack) {\r\n this._parent.addChildAt(p, 0);\r\n }\r\n else {\r\n this._parent.addChild(p);\r\n }\r\n // add particles to list of ones in this wave\r\n if (waveFirst) {\r\n waveLast.next = p;\r\n p.prev = waveLast;\r\n waveLast = p;\r\n }\r\n else {\r\n waveLast = waveFirst = p;\r\n }\r\n // increase our particle count\r\n ++this.particleCount;\r\n }\r\n if (waveFirst) {\r\n // add particle to list of active particles\r\n if (this._activeParticlesLast) {\r\n this._activeParticlesLast.next = waveFirst;\r\n waveFirst.prev = this._activeParticlesLast;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n else {\r\n this._activeParticlesFirst = waveFirst;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n // run behavior init on particles\r\n for (let i = 0; i < this.initBehaviors.length; ++i) {\r\n const behavior = this.initBehaviors[i];\r\n // if we hit our special key, interrupt behaviors to apply\r\n // emitter position/rotation\r\n if (behavior === PositionParticle) {\r\n for (let particle = waveFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // rotate the particle's position by the emitter's rotation\r\n if (this.rotation !== 0) {\r\n rotatePoint(this.rotation, particle.position);\r\n particle.rotation += this.rotation;\r\n }\r\n // offset by the emitter's position\r\n particle.position.x += emitPosX;\r\n particle.position.y += emitPosY;\r\n // also, just update the particle's age properties while we are looping through\r\n particle.age += -this._spawnTimer;\r\n // determine our interpolation value\r\n let lerp = particle.age * particle.oneOverLife; // lifetime / maxLife;\r\n // global ease affects all interpolation calculations\r\n if (this.customEase) {\r\n if (this.customEase.length === 4) {\r\n // the t, b, c, d parameters that some tween libraries use\r\n // (time, initial value, end value, duration)\r\n lerp = this.customEase(lerp, 0, 1, 1);\r\n }\r\n else {\r\n // the simplified version that we like that takes\r\n // one parameter, time from 0-1. TweenJS eases provide this usage.\r\n lerp = this.customEase(lerp);\r\n }\r\n }\r\n // set age percent for all interpolation calculations\r\n particle.agePercent = lerp;\r\n }\r\n }\r\n else {\r\n behavior.initParticles(waveFirst);\r\n }\r\n }\r\n for (let particle = waveFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // now update the particles by the time passed, so the particles are spread out properly\r\n for (let i = 0; i < this.updateBehaviors.length; ++i) {\r\n // we want a positive delta, because a negative delta messes things up\r\n if (this.updateBehaviors[i].updateParticle(particle, -this._spawnTimer)) {\r\n // bail if the particle got reycled\r\n this.recycle(particle);\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n // increase timer and continue on to any other particles that need to be created\r\n this._spawnTimer += this._frequency;\r\n }\r\n }\r\n // if the position changed before this update, then keep track of that\r\n if (this._posChanged) {\r\n this._prevEmitterPos.x = curX;\r\n this._prevEmitterPos.y = curY;\r\n this._prevPosIsValid = true;\r\n this._posChanged = false;\r\n }\r\n // if we are all done and should destroy ourselves, take care of that\r\n if (!this._emit && !this._activeParticlesFirst) {\r\n if (this._completeCallback) {\r\n const cb = this._completeCallback;\r\n this._completeCallback = null;\r\n cb();\r\n }\r\n if (this._destroyWhenComplete) {\r\n this.destroy();\r\n }\r\n }\r\n }\r\n /**\r\n * Emits a single wave of particles, using standard spawnChance & particlesPerWave settings. Does not affect\r\n * regular spawning through the frequency, and ignores the emit property. The max particle count is respected, however,\r\n * so if there are already too many particles then nothing will happen.\r\n */\r\n emitNow() {\r\n const emitPosX = this.ownerPos.x + this.spawnPos.x;\r\n const emitPosY = this.ownerPos.y + this.spawnPos.y;\r\n let waveFirst = null;\r\n let waveLast = null;\r\n // create enough particles to fill the wave\r\n for (let len = Math.min(this.particlesPerWave, this.maxParticles - this.particleCount), i = 0; i < len; ++i) {\r\n // see if we actually spawn one\r\n if (this.spawnChance < 1 && Math.random() >= this.spawnChance) {\r\n continue;\r\n }\r\n // create particle\r\n let p;\r\n if (this._poolFirst) {\r\n p = this._poolFirst;\r\n this._poolFirst = this._poolFirst.next;\r\n p.next = null;\r\n }\r\n else {\r\n p = new Particle(this);\r\n }\r\n let lifetime;\r\n if (this.minLifetime === this.maxLifetime) {\r\n lifetime = this.minLifetime;\r\n }\r\n else {\r\n lifetime = (Math.random() * (this.maxLifetime - this.minLifetime)) + this.minLifetime;\r\n }\r\n // initialize particle\r\n p.init(lifetime);\r\n // add the particle to the display list\r\n if (this.addAtBack) {\r\n this._parent.addChildAt(p, 0);\r\n }\r\n else {\r\n this._parent.addChild(p);\r\n }\r\n // add particles to list of ones in this wave\r\n if (waveFirst) {\r\n waveLast.next = p;\r\n p.prev = waveLast;\r\n waveLast = p;\r\n }\r\n else {\r\n waveLast = waveFirst = p;\r\n }\r\n // increase our particle count\r\n ++this.particleCount;\r\n }\r\n if (waveFirst) {\r\n // add particle to list of active particles\r\n if (this._activeParticlesLast) {\r\n this._activeParticlesLast.next = waveFirst;\r\n waveFirst.prev = this._activeParticlesLast;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n else {\r\n this._activeParticlesFirst = waveFirst;\r\n this._activeParticlesLast = waveLast;\r\n }\r\n // run behavior init on particles\r\n for (let i = 0; i < this.initBehaviors.length; ++i) {\r\n const behavior = this.initBehaviors[i];\r\n // if we hit our special key, interrupt behaviors to apply\r\n // emitter position/rotation\r\n if (behavior === PositionParticle) {\r\n for (let particle = waveFirst, next; particle; particle = next) {\r\n // save next particle in case we recycle this one\r\n next = particle.next;\r\n // rotate the particle's position by the emitter's rotation\r\n if (this.rotation !== 0) {\r\n rotatePoint(this.rotation, particle.position);\r\n particle.rotation += this.rotation;\r\n }\r\n // offset by the emitter's position\r\n particle.position.x += emitPosX;\r\n particle.position.y += emitPosY;\r\n }\r\n }\r\n else {\r\n behavior.initParticles(waveFirst);\r\n }\r\n }\r\n }\r\n }\r\n /**\r\n * Kills all active particles immediately.\r\n */\r\n cleanup() {\r\n let particle;\r\n let next;\r\n for (particle = this._activeParticlesFirst; particle; particle = next) {\r\n next = particle.next;\r\n this.recycle(particle, true);\r\n }\r\n this._activeParticlesFirst = this._activeParticlesLast = null;\r\n this.particleCount = 0;\r\n }\r\n /**\r\n * If this emitter has been destroyed. Note that a destroyed emitter can still be reused, after\r\n * having a new parent set and being reinitialized.\r\n */\r\n get destroyed() {\r\n return !(this._parent && this.initBehaviors.length);\r\n }\r\n /**\r\n * Destroys the emitter and all of its particles.\r\n */\r\n destroy() {\r\n // make sure we aren't still listening to any tickers\r\n this.autoUpdate = false;\r\n // puts all active particles in the pool, and removes them from the particle parent\r\n this.cleanup();\r\n // wipe the pool clean\r\n let next;\r\n for (let particle = this._poolFirst; particle; particle = next) {\r\n // store next value so we don't lose it in our destroy call\r\n next = particle.next;\r\n particle.destroy();\r\n }\r\n this._poolFirst = this._parent = this.spawnPos = this.ownerPos\r\n = this.customEase = this._completeCallback = null;\r\n this.initBehaviors.length = this.updateBehaviors.length = this.recycleBehaviors.length = 0;\r\n }\r\n}\r\nEmitter.knownBehaviors = {};\n\n/**\r\n * A SpawnShape that randomly picks locations inside a rectangle.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'rect',\r\n * data: {\r\n * x: 0,\r\n * y: 0,\r\n * w: 10,\r\n * h: 100\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass Rectangle {\r\n constructor(config) {\r\n this.x = config.x;\r\n this.y = config.y;\r\n this.w = config.w;\r\n this.h = config.h;\r\n }\r\n getRandPos(particle) {\r\n // place the particle at a random point in the rectangle\r\n particle.x = (Math.random() * this.w) + this.x;\r\n particle.y = (Math.random() * this.h) + this.y;\r\n }\r\n}\r\nRectangle.type = 'rect';\r\nRectangle.editorConfig = null;\n\n/**\r\n * A class for spawning particles in a circle or ring.\r\n * Can optionally apply rotation to particles so that they are aimed away from the center of the circle.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'torus',\r\n * data: {\r\n * radius: 30,\r\n * x: 0,\r\n * y: 0,\r\n * innerRadius: 10,\r\n * rotation: true\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass Torus {\r\n constructor(config) {\r\n this.x = config.x || 0;\r\n this.y = config.y || 0;\r\n this.radius = config.radius;\r\n this.innerRadius = config.innerRadius || 0;\r\n this.rotation = !!config.affectRotation;\r\n }\r\n getRandPos(particle) {\r\n // place the particle at a random radius in the ring\r\n if (this.innerRadius !== this.radius) {\r\n particle.x = (Math.random() * (this.radius - this.innerRadius)) + this.innerRadius;\r\n }\r\n else {\r\n particle.x = this.radius;\r\n }\r\n particle.y = 0;\r\n // rotate the point to a random angle in the circle\r\n const angle = Math.random() * Math.PI * 2;\r\n if (this.rotation) {\r\n particle.rotation += angle;\r\n }\r\n rotatePoint(angle, particle.position);\r\n // now add in the center of the torus\r\n particle.position.x += this.x;\r\n particle.position.y += this.y;\r\n }\r\n}\r\nTorus.type = 'torus';\r\nTorus.editorConfig = null;\n\n/**\r\n * A spawn shape that picks a random position along a series of line segments. If those\r\n * line segments form a polygon, particles will only be placed on the perimeter of that polygon.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'polygonalChain',\r\n * data: [\r\n * [{x: 0, y: 0}, {x: 10, y: 10}, {x: 20, y: 0}],\r\n * [{x: 0, y, -10}, {x: 10, y: 0}, {x: 20, y: -10}]\r\n * ]\r\n * }\r\n * ```\r\n */\r\nclass PolygonalChain {\r\n /**\r\n * @param data Point data for polygon chains. Either a list of points for a single chain, or a list of chains.\r\n */\r\n constructor(data) {\r\n this.segments = [];\r\n this.countingLengths = [];\r\n this.totalLength = 0;\r\n this.init(data);\r\n }\r\n /**\r\n * @param data Point data for polygon chains. Either a list of points for a single chain, or a list of chains.\r\n */\r\n init(data) {\r\n // if data is not present, set up a segment of length 0\r\n if (!data || !data.length) {\r\n this.segments.push({ p1: { x: 0, y: 0 }, p2: { x: 0, y: 0 }, l: 0 });\r\n }\r\n else if (Array.isArray(data[0])) {\r\n // list of segment chains, each defined as a list of points\r\n for (let i = 0; i < data.length; ++i) {\r\n // loop through the chain, connecting points\r\n const chain = data[i];\r\n let prevPoint = chain[0];\r\n for (let j = 1; j < chain.length; ++j) {\r\n const second = chain[j];\r\n this.segments.push({ p1: prevPoint, p2: second, l: 0 });\r\n prevPoint = second;\r\n }\r\n }\r\n }\r\n else {\r\n let prevPoint = data[0];\r\n // list of points\r\n for (let i = 1; i < data.length; ++i) {\r\n const second = data[i];\r\n this.segments.push({ p1: prevPoint, p2: second, l: 0 });\r\n prevPoint = second;\r\n }\r\n }\r\n // now go through our segments to calculate the lengths so that we\r\n // can set up a nice weighted random distribution\r\n for (let i = 0; i < this.segments.length; ++i) {\r\n const { p1, p2 } = this.segments[i];\r\n const segLength = Math.sqrt(((p2.x - p1.x) * (p2.x - p1.x)) + ((p2.y - p1.y) * (p2.y - p1.y)));\r\n // save length so we can turn a random number into a 0-1 interpolation value later\r\n this.segments[i].l = segLength;\r\n this.totalLength += segLength;\r\n // keep track of the length so far, counting up\r\n this.countingLengths.push(this.totalLength);\r\n }\r\n }\r\n /**\r\n * Gets a random point in the chain.\r\n * @param out The point to store the selected position in.\r\n */\r\n getRandPos(out) {\r\n // select a random spot in the length of the chain\r\n const rand = Math.random() * this.totalLength;\r\n let chosenSeg;\r\n let lerp;\r\n // if only one segment, it wins\r\n if (this.segments.length === 1) {\r\n chosenSeg = this.segments[0];\r\n lerp = rand;\r\n }\r\n else {\r\n // otherwise, go through countingLengths until we have determined\r\n // which segment we chose\r\n for (let i = 0; i < this.countingLengths.length; ++i) {\r\n if (rand < this.countingLengths[i]) {\r\n chosenSeg = this.segments[i];\r\n // set lerp equal to the length into that segment\r\n // (i.e. the remainder after subtracting all the segments before it)\r\n lerp = i === 0 ? rand : rand - this.countingLengths[i - 1];\r\n break;\r\n }\r\n }\r\n }\r\n // divide lerp by the segment length, to result in a 0-1 number.\r\n lerp /= chosenSeg.l || 1;\r\n const { p1, p2 } = chosenSeg;\r\n // now calculate the position in the segment that the lerp value represents\r\n out.x = p1.x + (lerp * (p2.x - p1.x));\r\n out.y = p1.y + (lerp * (p2.y - p1.y));\r\n }\r\n}\r\nPolygonalChain.type = 'polygonalChain';\r\nPolygonalChain.editorConfig = null;\n\nvar index = {\n __proto__: null,\n Rectangle: Rectangle,\n Torus: Torus,\n PolygonalChain: PolygonalChain\n};\n\nvar Types = {\n __proto__: null\n};\n\n/**\r\n * A Movement behavior that handles movement by applying a constant acceleration to all particles.\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"moveAcceleration\",\r\n * \"config\": {\r\n * \"accel\": {\r\n * \"x\": 0,\r\n * \"y\": 2000\r\n * },\r\n * \"minStart\": 600,\r\n * \"maxStart\": 600,\r\n * \"rotate\": true\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass AccelerationBehavior {\r\n constructor(config) {\r\n var _a;\r\n // doesn't _really_ need to be late, but doing so ensures that we can override any\r\n // rotation behavior that is mistakenly added\r\n this.order = BehaviorOrder.Late;\r\n this.minStart = config.minStart;\r\n this.maxStart = config.maxStart;\r\n this.accel = config.accel;\r\n this.rotate = !!config.rotate;\r\n this.maxSpeed = (_a = config.maxSpeed) !== null && _a !== void 0 ? _a : 0;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const speed = (Math.random() * (this.maxStart - this.minStart)) + this.minStart;\r\n if (!next.config.velocity) {\r\n next.config.velocity = new Point(speed, 0);\r\n }\r\n else {\r\n next.config.velocity.set(speed, 0);\r\n }\r\n rotatePoint(next.rotation, next.config.velocity);\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const vel = particle.config.velocity;\r\n const oldVX = vel.x;\r\n const oldVY = vel.y;\r\n vel.x += this.accel.x * deltaSec;\r\n vel.y += this.accel.y * deltaSec;\r\n if (this.maxSpeed) {\r\n const currentSpeed = length(vel);\r\n // if we are going faster than we should, clamp at the max speed\r\n // DO NOT recalculate vector length\r\n if (currentSpeed > this.maxSpeed) {\r\n scaleBy(vel, this.maxSpeed / currentSpeed);\r\n }\r\n }\r\n // calculate position delta by the midpoint between our old velocity and our new velocity\r\n particle.x += (oldVX + vel.x) / 2 * deltaSec;\r\n particle.y += (oldVY + vel.y) / 2 * deltaSec;\r\n if (this.rotate) {\r\n particle.rotation = Math.atan2(vel.y, vel.x);\r\n }\r\n }\r\n}\r\nAccelerationBehavior.type = 'moveAcceleration';\r\nAccelerationBehavior.editorConfig = null;\n\nfunction intValueSimple(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n return ((this.first.next.value - this.first.value) * lerp) + this.first.value;\r\n}\r\nfunction intColorSimple(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n const curVal = this.first.value;\r\n const nextVal = this.first.next.value;\r\n const r = ((nextVal.r - curVal.r) * lerp) + curVal.r;\r\n const g = ((nextVal.g - curVal.g) * lerp) + curVal.g;\r\n const b = ((nextVal.b - curVal.b) * lerp) + curVal.b;\r\n return combineRGBComponents(r, g, b);\r\n}\r\nfunction intValueComplex(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n let next = current.next;\r\n while (lerp > next.time) {\r\n current = next;\r\n next = next.next;\r\n }\r\n // convert the lerp value to the segment range\r\n lerp = (lerp - current.time) / (next.time - current.time);\r\n return ((next.value - current.value) * lerp) + current.value;\r\n}\r\nfunction intColorComplex(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n let next = current.next;\r\n while (lerp > next.time) {\r\n current = next;\r\n next = next.next;\r\n }\r\n // convert the lerp value to the segment range\r\n lerp = (lerp - current.time) / (next.time - current.time);\r\n const curVal = current.value;\r\n const nextVal = next.value;\r\n const r = ((nextVal.r - curVal.r) * lerp) + curVal.r;\r\n const g = ((nextVal.g - curVal.g) * lerp) + curVal.g;\r\n const b = ((nextVal.b - curVal.b) * lerp) + curVal.b;\r\n return combineRGBComponents(r, g, b);\r\n}\r\nfunction intValueStepped(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n while (current.next && lerp > current.next.time) {\r\n current = current.next;\r\n }\r\n return current.value;\r\n}\r\nfunction intColorStepped(lerp) {\r\n if (this.ease)\r\n lerp = this.ease(lerp);\r\n // make sure we are on the right segment\r\n let current = this.first;\r\n while (current.next && lerp > current.next.time) {\r\n current = current.next;\r\n }\r\n const curVal = current.value;\r\n return combineRGBComponents(curVal.r, curVal.g, curVal.b);\r\n}\r\n/**\r\n * Singly linked list container for keeping track of interpolated properties for particles.\r\n * Each Particle will have one of these for each interpolated property.\r\n */\r\nclass PropertyList {\r\n /**\r\n * @param isColor If this list handles color values\r\n */\r\n constructor(isColor = false) {\r\n this.first = null;\r\n this.isColor = !!isColor;\r\n this.interpolate = null;\r\n this.ease = null;\r\n }\r\n /**\r\n * Resets the list for use.\r\n * @param first The first node in the list.\r\n * @param first.isStepped If the values should be stepped instead of interpolated linearly.\r\n */\r\n reset(first) {\r\n this.first = first;\r\n const isSimple = first.next && first.next.time >= 1;\r\n if (isSimple) {\r\n this.interpolate = this.isColor ? intColorSimple : intValueSimple;\r\n }\r\n else if (first.isStepped) {\r\n this.interpolate = this.isColor ? intColorStepped : intValueStepped;\r\n }\r\n else {\r\n this.interpolate = this.isColor ? intColorComplex : intValueComplex;\r\n }\r\n this.ease = this.first.ease;\r\n }\r\n}\n\n/**\r\n * An Alpha behavior that applies an interpolated or stepped list of values to the particle's opacity.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'alpha',\r\n * config: {\r\n * alpha: {\r\n * list: [{value: 0, time: 0}, {value: 1, time: 0.25}, {value: 0, time: 1}]\r\n * },\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass AlphaBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.alpha));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.alpha = this.list.first.value;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle) {\r\n particle.alpha = this.list.interpolate(particle.agePercent);\r\n }\r\n}\r\nAlphaBehavior.type = 'alpha';\r\nAlphaBehavior.editorConfig = null;\r\n/**\r\n * An Alpha behavior that applies a static value to the particle's opacity at particle initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'alphaStatic',\r\n * config: {\r\n * alpha: 0.75,\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticAlphaBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.value = config.alpha;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.alpha = this.value;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticAlphaBehavior.type = 'alphaStatic';\r\nStaticAlphaBehavior.editorConfig = null;\n\nfunction getTextures(textures) {\r\n const outTextures = [];\r\n for (let j = 0; j < textures.length; ++j) {\r\n let tex = textures[j];\r\n if (typeof tex === 'string') {\r\n outTextures.push(GetTextureFromString(tex));\r\n }\r\n else if (tex instanceof Texture) {\r\n outTextures.push(tex);\r\n }\r\n // assume an object with extra data determining duplicate frame data\r\n else {\r\n let dupe = tex.count || 1;\r\n if (typeof tex.texture === 'string') {\r\n tex = GetTextureFromString(tex.texture);\r\n }\r\n else // if(tex.texture instanceof Texture)\r\n {\r\n tex = tex.texture;\r\n }\r\n for (; dupe > 0; --dupe) {\r\n outTextures.push(tex);\r\n }\r\n }\r\n }\r\n return outTextures;\r\n}\r\n/**\r\n * A Texture behavior that picks a random animation for each particle to play.\r\n * See {@link AnimatedParticleArt} for detailed configuration info.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'animatedRandom',\r\n * config: {\r\n * anims: [\r\n * {\r\n * framerate: 25,\r\n * loop: true,\r\n * textures: ['frame1', 'frame2', 'frame3']\r\n * },\r\n * {\r\n * framerate: 25,\r\n * loop: true,\r\n * textures: ['frame3', 'frame2', 'frame1']\r\n * }\r\n * ],\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass RandomAnimatedTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.anims = [];\r\n for (let i = 0; i < config.anims.length; ++i) {\r\n const anim = config.anims[i];\r\n const textures = getTextures(anim.textures);\r\n // eslint-disable-next-line no-nested-ternary\r\n const framerate = anim.framerate < 0 ? -1 : (anim.framerate > 0 ? anim.framerate : 60);\r\n const parsedAnim = {\r\n textures,\r\n duration: framerate > 0 ? textures.length / framerate : 0,\r\n framerate,\r\n loop: framerate > 0 ? !!anim.loop : false,\r\n };\r\n this.anims.push(parsedAnim);\r\n }\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const index = Math.floor(Math.random() * this.anims.length);\r\n const anim = next.config.anim = this.anims[index];\r\n next.texture = anim.textures[0];\r\n next.config.animElapsed = 0;\r\n // if anim should match particle life exactly\r\n if (anim.framerate === -1) {\r\n next.config.animDuration = next.maxLife;\r\n next.config.animFramerate = anim.textures.length / next.maxLife;\r\n }\r\n else {\r\n next.config.animDuration = anim.duration;\r\n next.config.animFramerate = anim.framerate;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const config = particle.config;\r\n const anim = config.anim;\r\n config.animElapsed += deltaSec;\r\n if (config.animElapsed >= config.animDuration) {\r\n // loop elapsed back around\r\n if (config.anim.loop) {\r\n config.animElapsed = config.animElapsed % config.animDuration;\r\n }\r\n // subtract a small amount to prevent attempting to go past the end of the animation\r\n else {\r\n config.animElapsed = config.animDuration - 0.000001;\r\n }\r\n }\r\n // add a very small number to the frame and then floor it to avoid\r\n // the frame being one short due to floating point errors.\r\n const frame = ((config.animElapsed * config.animFramerate) + 0.0000001) | 0;\r\n // in the very rare case that framerate * elapsed math ends up going past the end, use the last texture\r\n particle.texture = anim.textures[frame] || anim.textures[anim.textures.length - 1] || Texture.EMPTY;\r\n }\r\n}\r\nRandomAnimatedTextureBehavior.type = 'animatedRandom';\r\nRandomAnimatedTextureBehavior.editorConfig = null;\r\n/**\r\n * A Texture behavior that uses a single animation for each particle to play.\r\n * See {@link AnimatedParticleArt} for detailed configuration info.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'animatedSingle',\r\n * config: {\r\n * anim: {\r\n * framerate: 25,\r\n * loop: true,\r\n * textures: ['frame1', 'frame2', 'frame3']\r\n * }\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass SingleAnimatedTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n const anim = config.anim;\r\n const textures = getTextures(anim.textures);\r\n // eslint-disable-next-line no-nested-ternary\r\n const framerate = anim.framerate < 0 ? -1 : (anim.framerate > 0 ? anim.framerate : 60);\r\n this.anim = {\r\n textures,\r\n duration: framerate > 0 ? textures.length / framerate : 0,\r\n framerate,\r\n loop: framerate > 0 ? !!anim.loop : false,\r\n };\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n const anim = this.anim;\r\n while (next) {\r\n next.texture = anim.textures[0];\r\n next.config.animElapsed = 0;\r\n // if anim should match particle life exactly\r\n if (anim.framerate === -1) {\r\n next.config.animDuration = next.maxLife;\r\n next.config.animFramerate = anim.textures.length / next.maxLife;\r\n }\r\n else {\r\n next.config.animDuration = anim.duration;\r\n next.config.animFramerate = anim.framerate;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const anim = this.anim;\r\n const config = particle.config;\r\n config.animElapsed += deltaSec;\r\n if (config.animElapsed >= config.animDuration) {\r\n // loop elapsed back around\r\n if (anim.loop) {\r\n config.animElapsed = config.animElapsed % config.animDuration;\r\n }\r\n // subtract a small amount to prevent attempting to go past the end of the animation\r\n else {\r\n config.animElapsed = config.animDuration - 0.000001;\r\n }\r\n }\r\n // add a very small number to the frame and then floor it to avoid\r\n // the frame being one short due to floating point errors.\r\n const frame = ((config.animElapsed * config.animFramerate) + 0.0000001) | 0;\r\n // in the very rare case that framerate * elapsed math ends up going past the end, use the last texture\r\n particle.texture = anim.textures[frame] || anim.textures[anim.textures.length - 1] || Texture.EMPTY;\r\n }\r\n}\r\nSingleAnimatedTextureBehavior.type = 'animatedSingle';\r\nSingleAnimatedTextureBehavior.editorConfig = null;\n\n/**\r\n * A Blend Mode behavior that applies a blend mode value to the particle at initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'blendMode',\r\n * config: {\r\n * blendMode: 'multiply',\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass BlendModeBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.value = config.blendMode;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.blendMode = getBlendMode(this.value);\r\n next = next.next;\r\n }\r\n }\r\n}\r\nBlendModeBehavior.type = 'blendMode';\r\nBlendModeBehavior.editorConfig = null;\n\n/**\r\n * A Spawn behavior that sends particles out from a single point or ring, and is capable of evenly spacing\r\n * the particle's starting angles.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'spawnBurst',\r\n * config: {\r\n * spacing: 90,\r\n * start: 0,\r\n * distance: 40,\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass BurstSpawnBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Spawn;\r\n this.spacing = config.spacing * DEG_TO_RADS;\r\n this.start = config.start * DEG_TO_RADS;\r\n this.distance = config.distance;\r\n }\r\n initParticles(first) {\r\n let count = 0;\r\n let next = first;\r\n while (next) {\r\n let angle;\r\n if (this.spacing) {\r\n angle = this.start + (this.spacing * count);\r\n }\r\n else {\r\n angle = Math.random() * Math.PI * 2;\r\n }\r\n next.rotation = angle;\r\n if (this.distance) {\r\n next.position.x = this.distance;\r\n rotatePoint(angle, next.position);\r\n }\r\n next = next.next;\r\n ++count;\r\n }\r\n }\r\n}\r\nBurstSpawnBehavior.type = 'spawnBurst';\r\nBurstSpawnBehavior.editorConfig = null;\n\n/**\r\n * A Color behavior that applies an interpolated or stepped list of values to the particle's tint property.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'color',\r\n * config: {\r\n * color: {\r\n * list: [{value: '#ff0000' time: 0}, {value: '#00ff00', time: 0.5}, {value: '#0000ff', time: 1}]\r\n * },\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass ColorBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.list = new PropertyList(true);\r\n this.list.reset(PropertyNode.createList(config.color));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n const color = this.list.first.value;\r\n const tint = combineRGBComponents(color.r, color.g, color.b);\r\n while (next) {\r\n next.tint = tint;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle) {\r\n particle.tint = this.list.interpolate(particle.agePercent);\r\n }\r\n}\r\nColorBehavior.type = 'color';\r\nColorBehavior.editorConfig = null;\r\n/**\r\n * A Color behavior that applies a single color to the particle's tint property at initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'colorStatic',\r\n * config: {\r\n * color: '#ffff00',\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticColorBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n let color = config.color;\r\n if (color.charAt(0) === '#') {\r\n color = color.substr(1);\r\n }\r\n else if (color.indexOf('0x') === 0) {\r\n color = color.substr(2);\r\n }\r\n this.value = parseInt(color, 16);\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.tint = this.value;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticColorBehavior.type = 'colorStatic';\r\nStaticColorBehavior.editorConfig = null;\n\n/**\r\n * A Texture behavior that assigns a texture to each particle from its list, in order, before looping around to the first\r\n * texture again. String values will be converted to textures with {@link ParticleUtils.GetTextureFromString}.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'textureOrdered',\r\n * config: {\r\n * textures: [\"myTex1Id\", \"myTex2Id\", \"myTex3Id\", \"myTex4Id\"],\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass OrderedTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.index = 0;\r\n this.textures = config.textures.map((tex) => (typeof tex === 'string' ? GetTextureFromString(tex) : tex));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.texture = this.textures[this.index];\r\n if (++this.index >= this.textures.length) {\r\n this.index = 0;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n}\r\nOrderedTextureBehavior.type = 'textureOrdered';\r\nOrderedTextureBehavior.editorConfig = null;\n\n/**\r\n * A helper point for math things.\r\n * @hidden\r\n */\r\nconst helperPoint = new Point();\r\n/**\r\n * A hand picked list of Math functions (and a couple properties) that are\r\n * allowable. They should be used without the preceding \"Math.\"\r\n * @hidden\r\n */\r\nconst MATH_FUNCS = [\r\n 'E',\r\n 'LN2',\r\n 'LN10',\r\n 'LOG2E',\r\n 'LOG10E',\r\n 'PI',\r\n 'SQRT1_2',\r\n 'SQRT2',\r\n 'abs',\r\n 'acos',\r\n 'acosh',\r\n 'asin',\r\n 'asinh',\r\n 'atan',\r\n 'atanh',\r\n 'atan2',\r\n 'cbrt',\r\n 'ceil',\r\n 'cos',\r\n 'cosh',\r\n 'exp',\r\n 'expm1',\r\n 'floor',\r\n 'fround',\r\n 'hypot',\r\n 'log',\r\n 'log1p',\r\n 'log10',\r\n 'log2',\r\n 'max',\r\n 'min',\r\n 'pow',\r\n 'random',\r\n 'round',\r\n 'sign',\r\n 'sin',\r\n 'sinh',\r\n 'sqrt',\r\n 'tan',\r\n 'tanh',\r\n];\r\n/**\r\n * create an actual regular expression object from the string\r\n * @hidden\r\n */\r\nconst WHITELISTER = new RegExp([\r\n // Allow the 4 basic operations, parentheses and all numbers/decimals, as well\r\n // as 'x', for the variable usage.\r\n '[01234567890\\\\.\\\\*\\\\-\\\\+\\\\/\\\\(\\\\)x ,]',\r\n].concat(MATH_FUNCS).join('|'), 'g');\r\n/**\r\n * Parses a string into a function for path following.\r\n * This involves whitelisting the string for safety, inserting \"Math.\" to math function\r\n * names, and using `new Function()` to generate a function.\r\n * @hidden\r\n * @param pathString The string to parse.\r\n * @return The path function - takes x, outputs y.\r\n */\r\nfunction parsePath(pathString) {\r\n const matches = pathString.match(WHITELISTER);\r\n for (let i = matches.length - 1; i >= 0; --i) {\r\n if (MATH_FUNCS.indexOf(matches[i]) >= 0) {\r\n matches[i] = `Math.${matches[i]}`;\r\n }\r\n }\r\n pathString = matches.join('');\r\n // eslint-disable-next-line no-new-func\r\n return new Function('x', `return ${pathString};`);\r\n}\r\n/**\r\n * A particle that follows a path defined by an algebraic expression, e.g. \"sin(x)\" or\r\n * \"5x + 3\".\r\n * To use this class, the behavior config must have a \"path\" string or function.\r\n *\r\n * A string should have \"x\" in it to represent movement (from the\r\n * speed settings of the behavior). It may have numbers, parentheses, the four basic\r\n * operations, and any Math functions or properties (without the preceding \"Math.\").\r\n * The overall movement of the particle and the expression value become x and y positions for\r\n * the particle, respectively. The final position is rotated by the spawn rotation/angle of\r\n * the particle.\r\n *\r\n * A function merely needs to accept the \"x\" argument and output the a corresponding \"y\" value.\r\n *\r\n * Some example paths:\r\n *\r\n * * `\"sin(x/10) * 20\"` A sine wave path.\r\n * * `\"cos(x/100) * 30\"` Particles curve counterclockwise (for medium speed/low lifetime particles)\r\n * * `\"pow(x/10, 2) / 2\"` Particles curve clockwise (remember, +y is down).\r\n * * `(x) => Math.floor(x) * 3` Supplying an existing function should look like this\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"movePath\",\r\n * \"config\": {\r\n * \"path\": \"round(sin(x) * 2\",\r\n * \"speed\": {\r\n * \"list\": [{value: 10, time: 0}, {value: 100, time: 0.25}, {value: 0, time: 1}],\r\n * },\r\n * \"minMult\": 0.8\r\n * }\r\n *}\r\n */\r\nclass PathBehavior {\r\n constructor(config) {\r\n var _a;\r\n // *MUST* happen after other behaviors do initialization so that we can read initial transformations\r\n this.order = BehaviorOrder.Late;\r\n if (config.path) {\r\n if (typeof config.path === 'function') {\r\n this.path = config.path;\r\n }\r\n else {\r\n try {\r\n this.path = parsePath(config.path);\r\n }\r\n catch (e) {\r\n this.path = null;\r\n }\r\n }\r\n }\r\n else {\r\n // eslint-disable-next-line @typescript-eslint/explicit-function-return-type\r\n this.path = (x) => x;\r\n }\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.speed));\r\n this.minMult = (_a = config.minMult) !== null && _a !== void 0 ? _a : 1;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n /*\r\n * The initial rotation in degrees of the particle, because the direction of the path\r\n * is based on that.\r\n */\r\n next.config.initRotation = next.rotation;\r\n /* The initial position of the particle, as all path movement is added to that. */\r\n if (!next.config.initPosition) {\r\n next.config.initPosition = new Point(next.x, next.y);\r\n }\r\n else {\r\n next.config.initPosition.copyFrom(next.position);\r\n }\r\n /* Total single directional movement, due to speed. */\r\n next.config.movement = 0;\r\n // also do speed multiplier, since this includes basic speed movement\r\n const mult = (Math.random() * (1 - this.minMult)) + this.minMult;\r\n next.config.speedMult = mult;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n // increase linear movement based on speed\r\n const speed = this.list.interpolate(particle.agePercent) * particle.config.speedMult;\r\n particle.config.movement += speed * deltaSec;\r\n // set up the helper point for rotation\r\n helperPoint.x = particle.config.movement;\r\n helperPoint.y = this.path(helperPoint.x);\r\n rotatePoint(particle.config.initRotation, helperPoint);\r\n particle.position.x = particle.config.initPosition.x + helperPoint.x;\r\n particle.position.y = particle.config.initPosition.y + helperPoint.y;\r\n }\r\n}\r\nPathBehavior.type = 'movePath';\r\nPathBehavior.editorConfig = null;\n\n/**\r\n * A Spawn behavior that sends particles out from a single point at the emitter's position.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'spawnPoint',\r\n * config: {}\r\n * }\r\n * ```\r\n */\r\nclass PointSpawnBehavior {\r\n constructor() {\r\n this.order = BehaviorOrder.Spawn;\r\n }\r\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\r\n initParticles(_first) {\r\n // really just a no-op\r\n }\r\n}\r\nPointSpawnBehavior.type = 'spawnPoint';\r\nPointSpawnBehavior.editorConfig = null;\n\n/**\r\n * A Texture behavior that assigns a random texture to each particle from its list.\r\n * String values will be converted to textures with {@link ParticleUtils.GetTextureFromString}.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'textureRandom',\r\n * config: {\r\n * textures: [\"myTex1Id\", \"myTex2Id\", \"myTex3Id\", \"myTex4Id\"],\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass RandomTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.textures = config.textures.map((tex) => (typeof tex === 'string' ? GetTextureFromString(tex) : tex));\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const index = Math.floor(Math.random() * this.textures.length);\r\n next.texture = this.textures[index];\r\n next = next.next;\r\n }\r\n }\r\n}\r\nRandomTextureBehavior.type = 'textureRandom';\r\nRandomTextureBehavior.editorConfig = null;\n\n/**\r\n * A Rotation behavior that handles starting rotation, rotation speed, and rotational acceleration.\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"rotation\",\r\n * \"config\": {\r\n * \"minStart\": 0,\r\n * \"maxStart\": 180,\r\n * \"minSpeed\": 30,\r\n * \"maxSpeed\": 45,\r\n * \"accel\": 20\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass RotationBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.minStart = config.minStart * DEG_TO_RADS;\r\n this.maxStart = config.maxStart * DEG_TO_RADS;\r\n this.minSpeed = config.minSpeed * DEG_TO_RADS;\r\n this.maxSpeed = config.maxSpeed * DEG_TO_RADS;\r\n this.accel = config.accel * DEG_TO_RADS;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n if (this.minStart === this.maxStart) {\r\n next.rotation += this.maxStart;\r\n }\r\n else {\r\n next.rotation += (Math.random() * (this.maxStart - this.minStart)) + this.minStart;\r\n }\r\n next.config.rotSpeed = (Math.random() * (this.maxSpeed - this.minSpeed)) + this.minSpeed;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n if (this.accel) {\r\n const oldSpeed = particle.config.rotSpeed;\r\n particle.config.rotSpeed += this.accel * deltaSec;\r\n particle.rotation += (particle.config.rotSpeed + oldSpeed) / 2 * deltaSec;\r\n }\r\n else {\r\n particle.rotation += particle.config.rotSpeed * deltaSec;\r\n }\r\n }\r\n}\r\nRotationBehavior.type = 'rotation';\r\nRotationBehavior.editorConfig = null;\r\n/**\r\n * A Rotation behavior that handles starting rotation.\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"rotationStatic\",\r\n * \"config\": {\r\n * \"min\": 0,\r\n * \"max\": 180,\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass StaticRotationBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.min = config.min * DEG_TO_RADS;\r\n this.max = config.max * DEG_TO_RADS;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n if (this.min === this.max) {\r\n next.rotation += this.max;\r\n }\r\n else {\r\n next.rotation += (Math.random() * (this.max - this.min)) + this.min;\r\n }\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticRotationBehavior.type = 'rotationStatic';\r\nStaticRotationBehavior.editorConfig = null;\r\n/**\r\n * A Rotation behavior that blocks all rotation caused by spawn settings,\r\n * by resetting it to the specified rotation (or 0).\r\n *\r\n * Example configuration:\r\n * ```javascript\r\n * {\r\n * \"type\": \"noRotation\",\r\n * \"config\": {\r\n * \"rotation\": 0\r\n * }\r\n *}\r\n * ```\r\n */\r\nclass NoRotationBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Late + 1;\r\n this.rotation = (config.rotation || 0) * DEG_TO_RADS;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.rotation = this.rotation;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nNoRotationBehavior.type = 'noRotation';\r\nNoRotationBehavior.editorConfig = null;\n\n/**\r\n * A Scale behavior that applies an interpolated or stepped list of values to the particle's x & y scale.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'scale',\r\n * config: {\r\n * scale: {\r\n * list: [{value: 0, time: 0}, {value: 1, time: 0.25}, {value: 0, time: 1}],\r\n * isStepped: true\r\n * },\r\n * minMult: 0.5\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass ScaleBehavior {\r\n constructor(config) {\r\n var _a;\r\n this.order = BehaviorOrder.Normal;\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.scale));\r\n this.minMult = (_a = config.minMult) !== null && _a !== void 0 ? _a : 1;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const mult = (Math.random() * (1 - this.minMult)) + this.minMult;\r\n next.config.scaleMult = mult;\r\n next.scale.x = next.scale.y = this.list.first.value * mult;\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle) {\r\n particle.scale.x = particle.scale.y = this.list.interpolate(particle.agePercent) * particle.config.scaleMult;\r\n }\r\n}\r\nScaleBehavior.type = 'scale';\r\nScaleBehavior.editorConfig = null;\r\n/**\r\n * A Scale behavior that applies a randomly picked value to the particle's x & y scale at initialization.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'scaleStatic',\r\n * config: {\r\n * min: 0.25,\r\n * max: 0.75,\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticScaleBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.min = config.min;\r\n this.max = config.max;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const scale = (Math.random() * (this.max - this.min)) + this.min;\r\n next.scale.x = next.scale.y = scale;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nStaticScaleBehavior.type = 'scaleStatic';\r\nStaticScaleBehavior.editorConfig = null;\n\n/**\r\n * A Spawn behavior that places (and optionally rotates) particles according to a\r\n * specified shape. Additional shapes can be registered with {@link registerShape | SpawnShape.registerShape()}.\r\n * Additional shapes must implement the {@link SpawnShape} interface, and their class must match the\r\n * {@link SpawnShapeClass} interface.\r\n * Shapes included by default are:\r\n * * {@link Rectangle}\r\n * * {@link Torus}\r\n * * {@link PolygonalChain}\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'spawnShape',\r\n * config: {\r\n * type: 'rect',\r\n * data: {\r\n * x: 0,\r\n * y: 0,\r\n * width: 20,\r\n * height: 300,\r\n * }\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass ShapeSpawnBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Spawn;\r\n const ShapeClass = ShapeSpawnBehavior.shapes[config.type];\r\n if (!ShapeClass) {\r\n throw new Error(`No shape found with type '${config.type}'`);\r\n }\r\n this.shape = new ShapeClass(config.data);\r\n }\r\n /**\r\n * Registers a shape to be used by the ShapeSpawn behavior.\r\n * @param constructor The shape class constructor to use, with a static `type` property to reference it by.\r\n * @param typeOverride An optional type override, primarily for registering a shape under multiple names.\r\n */\r\n static registerShape(constructor, typeOverride) {\r\n ShapeSpawnBehavior.shapes[typeOverride || constructor.type] = constructor;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n this.shape.getRandPos(next);\r\n next = next.next;\r\n }\r\n }\r\n}\r\nShapeSpawnBehavior.type = 'spawnShape';\r\nShapeSpawnBehavior.editorConfig = null;\r\n/**\r\n * Dictionary of all registered shape classes.\r\n */\r\nShapeSpawnBehavior.shapes = {};\r\nShapeSpawnBehavior.registerShape(PolygonalChain);\r\nShapeSpawnBehavior.registerShape(Rectangle);\r\nShapeSpawnBehavior.registerShape(Torus);\r\nShapeSpawnBehavior.registerShape(Torus, 'circle');\n\n/**\r\n * A Textuure behavior that assigns a single texture to each particle.\r\n * String values will be converted to textures with {@link ParticleUtils.GetTextureFromString}.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'textureSingle',\r\n * config: {\r\n * texture: Texture.from('myTexId'),\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass SingleTextureBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Normal;\r\n this.texture = typeof config.texture === 'string' ? GetTextureFromString(config.texture) : config.texture;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n next.texture = this.texture;\r\n next = next.next;\r\n }\r\n }\r\n}\r\nSingleTextureBehavior.type = 'textureSingle';\r\nSingleTextureBehavior.editorConfig = null;\n\n/**\r\n * A Movement behavior that uses an interpolated or stepped list of values for a particles speed at any given moment.\r\n * Movement direction is controlled by the particle's starting rotation.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'moveSpeed',\r\n * config: {\r\n * speed: {\r\n * list: [{value: 10, time: 0}, {value: 100, time: 0.25}, {value: 0, time: 1}],\r\n * },\r\n * minMult: 0.8\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass SpeedBehavior {\r\n constructor(config) {\r\n var _a;\r\n this.order = BehaviorOrder.Late;\r\n this.list = new PropertyList(false);\r\n this.list.reset(PropertyNode.createList(config.speed));\r\n this.minMult = (_a = config.minMult) !== null && _a !== void 0 ? _a : 1;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const mult = (Math.random() * (1 - this.minMult)) + this.minMult;\r\n next.config.speedMult = mult;\r\n if (!next.config.velocity) {\r\n next.config.velocity = new Point(this.list.first.value * mult, 0);\r\n }\r\n else {\r\n next.config.velocity.set(this.list.first.value * mult, 0);\r\n }\r\n rotatePoint(next.rotation, next.config.velocity);\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const speed = this.list.interpolate(particle.agePercent) * particle.config.speedMult;\r\n const vel = particle.config.velocity;\r\n normalize(vel);\r\n scaleBy(vel, speed);\r\n particle.x += vel.x * deltaSec;\r\n particle.y += vel.y * deltaSec;\r\n }\r\n}\r\nSpeedBehavior.type = 'moveSpeed';\r\nSpeedBehavior.editorConfig = null;\r\n/**\r\n * A Movement behavior that uses a randomly picked constant speed throughout a particle's lifetime.\r\n * Movement direction is controlled by the particle's starting rotation.\r\n *\r\n * Example config:\r\n * ```javascript\r\n * {\r\n * type: 'moveSpeedStatic',\r\n * config: {\r\n * min: 100,\r\n * max: 150\r\n * }\r\n * }\r\n * ```\r\n */\r\nclass StaticSpeedBehavior {\r\n constructor(config) {\r\n this.order = BehaviorOrder.Late;\r\n this.min = config.min;\r\n this.max = config.max;\r\n }\r\n initParticles(first) {\r\n let next = first;\r\n while (next) {\r\n const speed = (Math.random() * (this.max - this.min)) + this.min;\r\n if (!next.config.velocity) {\r\n next.config.velocity = new Point(speed, 0);\r\n }\r\n else {\r\n next.config.velocity.set(speed, 0);\r\n }\r\n rotatePoint(next.rotation, next.config.velocity);\r\n next = next.next;\r\n }\r\n }\r\n updateParticle(particle, deltaSec) {\r\n const velocity = particle.config.velocity;\r\n particle.x += velocity.x * deltaSec;\r\n particle.y += velocity.y * deltaSec;\r\n }\r\n}\r\nStaticSpeedBehavior.type = 'moveSpeedStatic';\r\nStaticSpeedBehavior.editorConfig = null;\n\n// export support types for external use\n\nvar index$1 = {\n __proto__: null,\n spawnShapes: index,\n editor: Types,\n get BehaviorOrder () { return BehaviorOrder; },\n AccelerationBehavior: AccelerationBehavior,\n AlphaBehavior: AlphaBehavior,\n StaticAlphaBehavior: StaticAlphaBehavior,\n RandomAnimatedTextureBehavior: RandomAnimatedTextureBehavior,\n SingleAnimatedTextureBehavior: SingleAnimatedTextureBehavior,\n BlendModeBehavior: BlendModeBehavior,\n BurstSpawnBehavior: BurstSpawnBehavior,\n ColorBehavior: ColorBehavior,\n StaticColorBehavior: StaticColorBehavior,\n OrderedTextureBehavior: OrderedTextureBehavior,\n PathBehavior: PathBehavior,\n PointSpawnBehavior: PointSpawnBehavior,\n RandomTextureBehavior: RandomTextureBehavior,\n RotationBehavior: RotationBehavior,\n StaticRotationBehavior: StaticRotationBehavior,\n NoRotationBehavior: NoRotationBehavior,\n ScaleBehavior: ScaleBehavior,\n StaticScaleBehavior: StaticScaleBehavior,\n ShapeSpawnBehavior: ShapeSpawnBehavior,\n SingleTextureBehavior: SingleTextureBehavior,\n SpeedBehavior: SpeedBehavior,\n StaticSpeedBehavior: StaticSpeedBehavior\n};\n\n/**\r\n * Converts emitter configuration from pre-5.0.0 library values into the current version.\r\n *\r\n * Example usage:\r\n * ```javascript\r\n * const emitter = new Emitter(myContainer, upgradeConfig(myOldConfig, [myTexture, myOtherTexture]));\r\n * ```\r\n * @param config The old emitter config to upgrade.\r\n * @param art The old art values as would have been passed into the Emitter constructor or `Emitter.init()`\r\n */\r\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\r\nfunction upgradeConfig(config, art) {\r\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w;\r\n // just ensure we aren't given any V3 config data\r\n if ('behaviors' in config) {\r\n return config;\r\n }\r\n const out = {\r\n lifetime: config.lifetime,\r\n ease: config.ease,\r\n particlesPerWave: config.particlesPerWave,\r\n frequency: config.frequency,\r\n spawnChance: config.spawnChance,\r\n emitterLifetime: config.emitterLifetime,\r\n maxParticles: config.maxParticles,\r\n addAtBack: config.addAtBack,\r\n pos: config.pos,\r\n emit: config.emit,\r\n autoUpdate: config.autoUpdate,\r\n behaviors: [],\r\n };\r\n // set up the alpha\r\n if (config.alpha) {\r\n if ('start' in config.alpha) {\r\n if (config.alpha.start === config.alpha.end) {\r\n if (config.alpha.start !== 1) {\r\n out.behaviors.push({\r\n type: 'alphaStatic',\r\n config: { alpha: config.alpha.start },\r\n });\r\n }\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.alpha.start },\r\n { time: 1, value: config.alpha.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'alpha',\r\n config: { alpha: list },\r\n });\r\n }\r\n }\r\n else if (config.alpha.list.length === 1) {\r\n if (config.alpha.list[0].value !== 1) {\r\n out.behaviors.push({\r\n type: 'alphaStatic',\r\n config: { alpha: config.alpha.list[0].value },\r\n });\r\n }\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'alpha',\r\n config: { alpha: config.alpha },\r\n });\r\n }\r\n }\r\n // acceleration movement\r\n if (config.acceleration && (config.acceleration.x || config.acceleration.y)) {\r\n let minStart;\r\n let maxStart;\r\n if ('start' in config.speed) {\r\n minStart = config.speed.start * ((_a = config.speed.minimumSpeedMultiplier) !== null && _a !== void 0 ? _a : 1);\r\n maxStart = config.speed.start;\r\n }\r\n else {\r\n minStart = config.speed.list[0].value * ((_b = config.minimumSpeedMultiplier) !== null && _b !== void 0 ? _b : 1);\r\n maxStart = config.speed.list[0].value;\r\n }\r\n out.behaviors.push({\r\n type: 'moveAcceleration',\r\n config: {\r\n accel: config.acceleration,\r\n minStart,\r\n maxStart,\r\n rotate: !config.noRotation,\r\n maxSpeed: config.maxSpeed,\r\n },\r\n });\r\n }\r\n // path movement\r\n else if ((_c = config.extraData) === null || _c === void 0 ? void 0 : _c.path) {\r\n let list;\r\n let mult;\r\n if ('start' in config.speed) {\r\n mult = (_d = config.speed.minimumSpeedMultiplier) !== null && _d !== void 0 ? _d : 1;\r\n if (config.speed.start === config.speed.end) {\r\n list = {\r\n list: [{ time: 0, value: config.speed.start }],\r\n };\r\n }\r\n else {\r\n list = {\r\n list: [\r\n { time: 0, value: config.speed.start },\r\n { time: 1, value: config.speed.end },\r\n ],\r\n };\r\n }\r\n }\r\n else {\r\n list = config.speed;\r\n mult = ((_e = config.minimumSpeedMultiplier) !== null && _e !== void 0 ? _e : 1);\r\n }\r\n out.behaviors.push({\r\n type: 'movePath',\r\n config: {\r\n path: config.extraData.path,\r\n speed: list,\r\n minMult: mult,\r\n },\r\n });\r\n }\r\n // normal speed movement\r\n else {\r\n if (config.speed) {\r\n if ('start' in config.speed) {\r\n if (config.speed.start === config.speed.end) {\r\n out.behaviors.push({\r\n type: 'moveSpeedStatic',\r\n config: {\r\n min: config.speed.start * ((_f = config.speed.minimumSpeedMultiplier) !== null && _f !== void 0 ? _f : 1),\r\n max: config.speed.start,\r\n },\r\n });\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.speed.start },\r\n { time: 1, value: config.speed.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'moveSpeed',\r\n config: { speed: list, minMult: config.speed.minimumSpeedMultiplier },\r\n });\r\n }\r\n }\r\n else if (config.speed.list.length === 1) {\r\n out.behaviors.push({\r\n type: 'moveSpeedStatic',\r\n config: {\r\n min: config.speed.list[0].value * ((_g = config.minimumSpeedMultiplier) !== null && _g !== void 0 ? _g : 1),\r\n max: config.speed.list[0].value,\r\n },\r\n });\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'moveSpeed',\r\n config: { speed: config.speed, minMult: ((_h = config.minimumSpeedMultiplier) !== null && _h !== void 0 ? _h : 1) },\r\n });\r\n }\r\n }\r\n }\r\n // scale\r\n if (config.scale) {\r\n if ('start' in config.scale) {\r\n const mult = (_j = config.scale.minimumScaleMultiplier) !== null && _j !== void 0 ? _j : 1;\r\n if (config.scale.start === config.scale.end) {\r\n out.behaviors.push({\r\n type: 'scaleStatic',\r\n config: {\r\n min: config.scale.start * mult,\r\n max: config.scale.start,\r\n },\r\n });\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.scale.start },\r\n { time: 1, value: config.scale.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'scale',\r\n config: { scale: list, minMult: mult },\r\n });\r\n }\r\n }\r\n else if (config.scale.list.length === 1) {\r\n const mult = (_k = config.minimumScaleMultiplier) !== null && _k !== void 0 ? _k : 1;\r\n const scale = config.scale.list[0].value;\r\n out.behaviors.push({\r\n type: 'scaleStatic',\r\n config: { min: scale * mult, max: scale },\r\n });\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'scale',\r\n config: { scale: config.scale, minMult: (_l = config.minimumScaleMultiplier) !== null && _l !== void 0 ? _l : 1 },\r\n });\r\n }\r\n }\r\n // color\r\n if (config.color) {\r\n if ('start' in config.color) {\r\n if (config.color.start === config.color.end) {\r\n if (config.color.start !== 'ffffff') {\r\n out.behaviors.push({\r\n type: 'colorStatic',\r\n config: { color: config.color.start },\r\n });\r\n }\r\n }\r\n else {\r\n const list = {\r\n list: [\r\n { time: 0, value: config.color.start },\r\n { time: 1, value: config.color.end },\r\n ],\r\n };\r\n out.behaviors.push({\r\n type: 'color',\r\n config: { color: list },\r\n });\r\n }\r\n }\r\n else if (config.color.list.length === 1) {\r\n if (config.color.list[0].value !== 'ffffff') {\r\n out.behaviors.push({\r\n type: 'colorStatic',\r\n config: { color: config.color.list[0].value },\r\n });\r\n }\r\n }\r\n else {\r\n out.behaviors.push({\r\n type: 'color',\r\n config: { color: config.color },\r\n });\r\n }\r\n }\r\n // rotation\r\n if (config.rotationAcceleration || ((_m = config.rotationSpeed) === null || _m === void 0 ? void 0 : _m.min) || ((_o = config.rotationSpeed) === null || _o === void 0 ? void 0 : _o.max)) {\r\n out.behaviors.push({\r\n type: 'rotation',\r\n config: {\r\n accel: config.rotationAcceleration || 0,\r\n minSpeed: ((_p = config.rotationSpeed) === null || _p === void 0 ? void 0 : _p.min) || 0,\r\n maxSpeed: ((_q = config.rotationSpeed) === null || _q === void 0 ? void 0 : _q.max) || 0,\r\n minStart: ((_r = config.startRotation) === null || _r === void 0 ? void 0 : _r.min) || 0,\r\n maxStart: ((_s = config.startRotation) === null || _s === void 0 ? void 0 : _s.max) || 0,\r\n },\r\n });\r\n }\r\n else if (((_t = config.startRotation) === null || _t === void 0 ? void 0 : _t.min) || ((_u = config.startRotation) === null || _u === void 0 ? void 0 : _u.max)) {\r\n out.behaviors.push({\r\n type: 'rotationStatic',\r\n config: {\r\n min: ((_v = config.startRotation) === null || _v === void 0 ? void 0 : _v.min) || 0,\r\n max: ((_w = config.startRotation) === null || _w === void 0 ? void 0 : _w.max) || 0,\r\n },\r\n });\r\n }\r\n if (config.noRotation) {\r\n out.behaviors.push({\r\n type: 'noRotation',\r\n config: {},\r\n });\r\n }\r\n // blend mode\r\n if (config.blendMode && config.blendMode !== 'normal') {\r\n out.behaviors.push({\r\n type: 'blendMode',\r\n config: {\r\n blendMode: config.blendMode,\r\n },\r\n });\r\n }\r\n // animated\r\n if (Array.isArray(art) && typeof art[0] !== 'string' && 'framerate' in art[0]) {\r\n for (let i = 0; i < art.length; ++i) {\r\n if (art[i].framerate === 'matchLife') {\r\n art[i].framerate = -1;\r\n }\r\n }\r\n out.behaviors.push({\r\n type: 'animatedRandom',\r\n config: {\r\n anims: art,\r\n },\r\n });\r\n }\r\n else if (typeof art !== 'string' && 'framerate' in art) {\r\n if (art.framerate === 'matchLife') {\r\n art.framerate = -1;\r\n }\r\n out.behaviors.push({\r\n type: 'animatedSingle',\r\n config: {\r\n anim: art,\r\n },\r\n });\r\n }\r\n // ordered art\r\n else if (config.orderedArt && Array.isArray(art)) {\r\n out.behaviors.push({\r\n type: 'textureOrdered',\r\n config: {\r\n textures: art,\r\n },\r\n });\r\n }\r\n // random texture\r\n else if (Array.isArray(art)) {\r\n out.behaviors.push({\r\n type: 'textureRandom',\r\n config: {\r\n textures: art,\r\n },\r\n });\r\n }\r\n // single texture\r\n else {\r\n out.behaviors.push({\r\n type: 'textureSingle',\r\n config: {\r\n texture: art,\r\n },\r\n });\r\n }\r\n // spawn burst\r\n if (config.spawnType === 'burst') {\r\n out.behaviors.push({\r\n type: 'spawnBurst',\r\n config: {\r\n start: config.angleStart || 0,\r\n spacing: config.particleSpacing,\r\n // older formats bursted from a single point\r\n distance: 0,\r\n },\r\n });\r\n }\r\n // spawn point\r\n else if (config.spawnType === 'point') {\r\n out.behaviors.push({\r\n type: 'spawnPoint',\r\n config: {},\r\n });\r\n }\r\n // spawn shape\r\n else {\r\n let shape;\r\n if (config.spawnType === 'ring') {\r\n shape = {\r\n type: 'torus',\r\n data: {\r\n x: config.spawnCircle.x,\r\n y: config.spawnCircle.y,\r\n radius: config.spawnCircle.r,\r\n innerRadius: config.spawnCircle.minR,\r\n affectRotation: true,\r\n },\r\n };\r\n }\r\n else if (config.spawnType === 'circle') {\r\n shape = {\r\n type: 'torus',\r\n data: {\r\n x: config.spawnCircle.x,\r\n y: config.spawnCircle.y,\r\n radius: config.spawnCircle.r,\r\n innerRadius: 0,\r\n affectRotation: false,\r\n },\r\n };\r\n }\r\n else if (config.spawnType === 'rect') {\r\n shape = {\r\n type: 'rect',\r\n data: config.spawnRect,\r\n };\r\n }\r\n else if (config.spawnType === 'polygonalChain') {\r\n shape = {\r\n type: 'polygonalChain',\r\n data: config.spawnPolygon,\r\n };\r\n }\r\n if (shape) {\r\n out.behaviors.push({\r\n type: 'spawnShape',\r\n config: shape,\r\n });\r\n }\r\n }\r\n return out;\r\n}\n\n/**\r\n * A semi-experimental Container that uses a doubly linked list to manage children instead of an\r\n * array. This means that adding/removing children often is not the same performance hit that\r\n * it would to be continually pushing/splicing.\r\n * However, this is primarily intended to be used for heavy particle usage, and may not handle\r\n * edge cases well if used as a complete Container replacement.\r\n */\r\nclass LinkedListContainer extends Container {\r\n constructor() {\r\n super(...arguments);\r\n this._firstChild = null;\r\n this._lastChild = null;\r\n this._childCount = 0;\r\n }\r\n get firstChild() {\r\n return this._firstChild;\r\n }\r\n get lastChild() {\r\n return this._lastChild;\r\n }\r\n get childCount() {\r\n return this._childCount;\r\n }\r\n addChild(...children) {\r\n // if there is only one argument we can bypass looping through the them\r\n if (children.length > 1) {\r\n // loop through the array and add all children\r\n for (let i = 0; i < children.length; i++) {\r\n // eslint-disable-next-line prefer-rest-params\r\n this.addChild(children[i]);\r\n }\r\n }\r\n else {\r\n const child = children[0];\r\n // if the child has a parent then lets remove it as PixiJS objects can only exist in one place\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // add to list if we have a list\r\n if (this._lastChild) {\r\n this._lastChild.nextChild = child;\r\n child.prevChild = this._lastChild;\r\n this._lastChild = child;\r\n }\r\n // otherwise initialize the list\r\n else {\r\n this._firstChild = this._lastChild = child;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n this.emit('childAdded', child, this, this._childCount);\r\n child.emit('added', this);\r\n }\r\n return children[0];\r\n }\r\n addChildAt(child, index) {\r\n if (index < 0 || index > this._childCount) {\r\n throw new Error(`addChildAt: The index ${index} supplied is out of bounds ${this._childCount}`);\r\n }\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n const c = child;\r\n // if no children, do basic initialization\r\n if (!this._firstChild) {\r\n this._firstChild = this._lastChild = c;\r\n }\r\n // add at beginning (back)\r\n else if (index === 0) {\r\n this._firstChild.prevChild = c;\r\n c.nextChild = this._firstChild;\r\n this._firstChild = c;\r\n }\r\n // add at end (front)\r\n else if (index === this._childCount) {\r\n this._lastChild.nextChild = c;\r\n c.prevChild = this._lastChild;\r\n this._lastChild = c;\r\n }\r\n // otherwise we have to start counting through the children to find the right one\r\n // - SLOW, only provided to fully support the possibility of use\r\n else {\r\n let i = 0;\r\n let target = this._firstChild;\r\n while (i < index) {\r\n target = target.nextChild;\r\n ++i;\r\n }\r\n // insert before the target that we found at the specified index\r\n target.prevChild.nextChild = c;\r\n c.prevChild = target.prevChild;\r\n c.nextChild = target;\r\n target.prevChild = c;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange(index);\r\n child.emit('added', this);\r\n this.emit('childAdded', child, this, index);\r\n return child;\r\n }\r\n /**\r\n * Adds a child to the container to be rendered below another child.\r\n *\r\n * @param child The child to add\r\n * @param relative - The current child to add the new child relative to.\r\n * @return The child that was added.\r\n */\r\n addChildBelow(child, relative) {\r\n if (relative.parent !== this) {\r\n throw new Error(`addChildBelow: The relative target must be a child of this parent`);\r\n }\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // insert before the target that we were given\r\n relative.prevChild.nextChild = child;\r\n child.prevChild = relative.prevChild;\r\n child.nextChild = relative;\r\n relative.prevChild = child;\r\n if (this._firstChild === relative) {\r\n this._firstChild = child;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n this.emit('childAdded', child, this, this._childCount);\r\n child.emit('added', this);\r\n return child;\r\n }\r\n /**\r\n * Adds a child to the container to be rendered above another child.\r\n *\r\n * @param child The child to add\r\n * @param relative - The current child to add the new child relative to.\r\n * @return The child that was added.\r\n */\r\n addChildAbove(child, relative) {\r\n if (relative.parent !== this) {\r\n throw new Error(`addChildBelow: The relative target must be a child of this parent`);\r\n }\r\n if (child.parent) {\r\n child.parent.removeChild(child);\r\n }\r\n child.parent = this;\r\n this.sortDirty = true;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // insert after the target that we were given\r\n relative.nextChild.prevChild = child;\r\n child.nextChild = relative.nextChild;\r\n child.prevChild = relative;\r\n relative.nextChild = child;\r\n if (this._lastChild === relative) {\r\n this._lastChild = child;\r\n }\r\n // update child count\r\n ++this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n this.emit('childAdded', child, this, this._childCount);\r\n child.emit('added', this);\r\n return child;\r\n }\r\n swapChildren(child, child2) {\r\n if (child === child2 || child.parent !== this || child2.parent !== this) {\r\n return;\r\n }\r\n const { prevChild, nextChild } = child;\r\n child.prevChild = child2.prevChild;\r\n child.nextChild = child2.nextChild;\r\n child2.prevChild = prevChild;\r\n child2.nextChild = nextChild;\r\n if (this._firstChild === child) {\r\n this._firstChild = child2;\r\n }\r\n else if (this._firstChild === child2) {\r\n this._firstChild = child;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child2;\r\n }\r\n else if (this._lastChild === child2) {\r\n this._lastChild = child;\r\n }\r\n this.onChildrenChange();\r\n }\r\n getChildIndex(child) {\r\n let index = 0;\r\n let test = this._firstChild;\r\n while (test) {\r\n if (test === child) {\r\n break;\r\n }\r\n test = test.nextChild;\r\n ++index;\r\n }\r\n if (!test) {\r\n throw new Error('The supplied DisplayObject must be a child of the caller');\r\n }\r\n return index;\r\n }\r\n setChildIndex(child, index) {\r\n if (index < 0 || index >= this._childCount) {\r\n throw new Error(`The index ${index} supplied is out of bounds ${this._childCount}`);\r\n }\r\n if (child.parent !== this) {\r\n throw new Error('The supplied DisplayObject must be a child of the caller');\r\n }\r\n // remove child\r\n if (child.nextChild) {\r\n child.nextChild.prevChild = child.prevChild;\r\n }\r\n if (child.prevChild) {\r\n child.prevChild.nextChild = child.nextChild;\r\n }\r\n if (this._firstChild === child) {\r\n this._firstChild = child.nextChild;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child.prevChild;\r\n }\r\n child.nextChild = null;\r\n child.prevChild = null;\r\n // do addChildAt\r\n if (!this._firstChild) {\r\n this._firstChild = this._lastChild = child;\r\n }\r\n else if (index === 0) {\r\n this._firstChild.prevChild = child;\r\n child.nextChild = this._firstChild;\r\n this._firstChild = child;\r\n }\r\n else if (index === this._childCount) {\r\n this._lastChild.nextChild = child;\r\n child.prevChild = this._lastChild;\r\n this._lastChild = child;\r\n }\r\n else {\r\n let i = 0;\r\n let target = this._firstChild;\r\n while (i < index) {\r\n target = target.nextChild;\r\n ++i;\r\n }\r\n target.prevChild.nextChild = child;\r\n child.prevChild = target.prevChild;\r\n child.nextChild = target;\r\n target.prevChild = child;\r\n }\r\n this.onChildrenChange(index);\r\n }\r\n removeChild(...children) {\r\n // if there is only one argument we can bypass looping through the them\r\n if (children.length > 1) {\r\n // loop through the arguments property and remove all children\r\n for (let i = 0; i < children.length; i++) {\r\n this.removeChild(children[i]);\r\n }\r\n }\r\n else {\r\n const child = children[0];\r\n // bail if not actually our child\r\n if (child.parent !== this)\r\n return null;\r\n child.parent = null;\r\n // ensure child transform will be recalculated\r\n child.transform._parentID = -1;\r\n // swap out child references\r\n if (child.nextChild) {\r\n child.nextChild.prevChild = child.prevChild;\r\n }\r\n if (child.prevChild) {\r\n child.prevChild.nextChild = child.nextChild;\r\n }\r\n if (this._firstChild === child) {\r\n this._firstChild = child.nextChild;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child.prevChild;\r\n }\r\n // clear sibling references\r\n child.nextChild = null;\r\n child.prevChild = null;\r\n // update child count\r\n --this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange();\r\n child.emit('removed', this);\r\n this.emit('childRemoved', child, this);\r\n }\r\n return children[0];\r\n }\r\n getChildAt(index) {\r\n if (index < 0 || index >= this._childCount) {\r\n throw new Error(`getChildAt: Index (${index}) does not exist.`);\r\n }\r\n if (index === 0) {\r\n return this._firstChild;\r\n }\r\n // add at end (front)\r\n else if (index === this._childCount) {\r\n return this._lastChild;\r\n }\r\n // otherwise we have to start counting through the children to find the right one\r\n // - SLOW, only provided to fully support the possibility of use\r\n let i = 0;\r\n let target = this._firstChild;\r\n while (i < index) {\r\n target = target.nextChild;\r\n ++i;\r\n }\r\n return target;\r\n }\r\n removeChildAt(index) {\r\n const child = this.getChildAt(index);\r\n // ensure child transform will be recalculated..\r\n child.parent = null;\r\n child.transform._parentID = -1;\r\n // swap out child references\r\n if (child.nextChild) {\r\n child.nextChild.prevChild = child.prevChild;\r\n }\r\n if (child.prevChild) {\r\n child.prevChild.nextChild = child.nextChild;\r\n }\r\n if (this._firstChild === child) {\r\n this._firstChild = child.nextChild;\r\n }\r\n if (this._lastChild === child) {\r\n this._lastChild = child.prevChild;\r\n }\r\n // clear sibling references\r\n child.nextChild = null;\r\n child.prevChild = null;\r\n // update child count\r\n --this._childCount;\r\n // ensure bounds will be recalculated\r\n this._boundsID++;\r\n // TODO - lets either do all callbacks or all events.. not both!\r\n this.onChildrenChange(index);\r\n child.emit('removed', this);\r\n this.emit('childRemoved', child, this, index);\r\n return child;\r\n }\r\n removeChildren(beginIndex = 0, endIndex = this._childCount) {\r\n const begin = beginIndex;\r\n const end = endIndex;\r\n const range = end - begin;\r\n if (range > 0 && range <= end) {\r\n const removed = [];\r\n let child = this._firstChild;\r\n for (let i = 0; i <= end && child; ++i, child = child.nextChild) {\r\n if (i >= begin) {\r\n removed.push(child);\r\n }\r\n }\r\n // child before removed section\r\n const prevChild = removed[0].prevChild;\r\n // child after removed section\r\n const nextChild = removed[removed.length - 1].nextChild;\r\n if (!nextChild) {\r\n // if we removed the last child, then the new last child is the one before\r\n // the removed section\r\n this._lastChild = prevChild;\r\n }\r\n else {\r\n // otherwise, stitch the child before the section to the child after\r\n nextChild.prevChild = prevChild;\r\n }\r\n if (!prevChild) {\r\n // if we removed the first child, then the new first child is the one after\r\n // the removed section\r\n this._firstChild = nextChild;\r\n }\r\n else {\r\n // otherwise stich the child after the section to the one before\r\n prevChild.nextChild = nextChild;\r\n }\r\n for (let i = 0; i < removed.length; ++i) {\r\n // clear parenting and sibling references for all removed children\r\n removed[i].parent = null;\r\n if (removed[i].transform) {\r\n removed[i].transform._parentID = -1;\r\n }\r\n removed[i].nextChild = null;\r\n removed[i].prevChild = null;\r\n }\r\n this._boundsID++;\r\n this.onChildrenChange(beginIndex);\r\n for (let i = 0; i < removed.length; ++i) {\r\n removed[i].emit('removed', this);\r\n this.emit('childRemoved', removed[i], this, i);\r\n }\r\n return removed;\r\n }\r\n else if (range === 0 && this._childCount === 0) {\r\n return [];\r\n }\r\n throw new RangeError('removeChildren: numeric values are outside the acceptable range.');\r\n }\r\n /**\r\n * Updates the transform on all children of this container for rendering.\r\n * Copied from and overrides PixiJS v5 method (v4 method is identical)\r\n */\r\n updateTransform() {\r\n this._boundsID++;\r\n this.transform.updateTransform(this.parent.transform);\r\n // TODO: check render flags, how to process stuff here\r\n this.worldAlpha = this.alpha * this.parent.worldAlpha;\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n if (child.visible) {\r\n child.updateTransform();\r\n }\r\n }\r\n }\r\n /**\r\n * Recalculates the bounds of the container.\r\n * Copied from and overrides PixiJS v5 method (v4 method is identical)\r\n */\r\n calculateBounds() {\r\n this._bounds.clear();\r\n this._calculateBounds();\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n if (!child.visible || !child.renderable) {\r\n continue;\r\n }\r\n child.calculateBounds();\r\n // TODO: filter+mask, need to mask both somehow\r\n if (child._mask) {\r\n const maskObject = (child._mask.maskObject || child._mask);\r\n maskObject.calculateBounds();\r\n this._bounds.addBoundsMask(child._bounds, maskObject._bounds);\r\n }\r\n else if (child.filterArea) {\r\n this._bounds.addBoundsArea(child._bounds, child.filterArea);\r\n }\r\n else {\r\n this._bounds.addBounds(child._bounds);\r\n }\r\n }\r\n this._bounds.updateID = this._boundsID;\r\n }\r\n /**\r\n * Retrieves the local bounds of the displayObject as a rectangle object. Copied from and overrides PixiJS v5 method\r\n */\r\n getLocalBounds(rect, skipChildrenUpdate = false) {\r\n // skip Container's getLocalBounds, go directly to DisplayObject\r\n const result = DisplayObject.prototype.getLocalBounds.call(this, rect);\r\n if (!skipChildrenUpdate) {\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n if (child.visible) {\r\n child.updateTransform();\r\n }\r\n }\r\n }\r\n return result;\r\n }\r\n /**\r\n * Renders the object using the WebGL renderer. Copied from and overrides PixiJS v5 method\r\n */\r\n render(renderer) {\r\n // if the object is not visible or the alpha is 0 then no need to render this element\r\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\r\n return;\r\n }\r\n // do a quick check to see if this element has a mask or a filter.\r\n if (this._mask || (this.filters && this.filters.length)) {\r\n this.renderAdvanced(renderer);\r\n }\r\n else {\r\n this._render(renderer);\r\n let child;\r\n let next;\r\n // simple render children!\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n child.render(renderer);\r\n }\r\n }\r\n }\r\n /**\r\n * Render the object using the WebGL renderer and advanced features. Copied from and overrides PixiJS v5 method\r\n */\r\n renderAdvanced(renderer) {\r\n renderer.batch.flush();\r\n const filters = this.filters;\r\n const mask = this._mask;\r\n // _enabledFilters note: As of development, _enabledFilters is not documented in pixi.js\r\n // types but is in code of current release (5.2.4).\r\n // push filter first as we need to ensure the stencil buffer is correct for any masking\r\n if (filters) {\r\n if (!this._enabledFilters) {\r\n this._enabledFilters = [];\r\n }\r\n this._enabledFilters.length = 0;\r\n for (let i = 0; i < filters.length; i++) {\r\n if (filters[i].enabled) {\r\n this._enabledFilters.push(filters[i]);\r\n }\r\n }\r\n if (this._enabledFilters.length) {\r\n renderer.filter.push(this, this._enabledFilters);\r\n }\r\n }\r\n if (mask) {\r\n renderer.mask.push(this, this._mask);\r\n }\r\n // add this object to the batch, only rendered if it has a texture.\r\n this._render(renderer);\r\n let child;\r\n let next;\r\n // now loop through the children and make sure they get rendered\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n child.render(renderer);\r\n }\r\n renderer.batch.flush();\r\n if (mask) {\r\n renderer.mask.pop(this);\r\n }\r\n if (filters && this._enabledFilters && this._enabledFilters.length) {\r\n renderer.filter.pop();\r\n }\r\n }\r\n /**\r\n * Renders the object using the Canvas renderer. Copied from and overrides PixiJS Canvas mixin in V5 and V6.\r\n */\r\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\r\n renderCanvas(renderer) {\r\n // if not visible or the alpha is 0 then no need to render this\r\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\r\n return;\r\n }\r\n if (this._mask) {\r\n renderer.maskManager.pushMask(this._mask);\r\n }\r\n this._renderCanvas(renderer);\r\n let child;\r\n let next;\r\n for (child = this._firstChild; child; child = next) {\r\n next = child.nextChild;\r\n child.renderCanvas(renderer);\r\n }\r\n if (this._mask) {\r\n renderer.maskManager.popMask(renderer);\r\n }\r\n }\r\n}\n\nEmitter.registerBehavior(AccelerationBehavior);\r\nEmitter.registerBehavior(AlphaBehavior);\r\nEmitter.registerBehavior(StaticAlphaBehavior);\r\nEmitter.registerBehavior(RandomAnimatedTextureBehavior);\r\nEmitter.registerBehavior(SingleAnimatedTextureBehavior);\r\nEmitter.registerBehavior(BlendModeBehavior);\r\nEmitter.registerBehavior(BurstSpawnBehavior);\r\nEmitter.registerBehavior(ColorBehavior);\r\nEmitter.registerBehavior(StaticColorBehavior);\r\nEmitter.registerBehavior(OrderedTextureBehavior);\r\nEmitter.registerBehavior(PathBehavior);\r\nEmitter.registerBehavior(PointSpawnBehavior);\r\nEmitter.registerBehavior(RandomTextureBehavior);\r\nEmitter.registerBehavior(RotationBehavior);\r\nEmitter.registerBehavior(StaticRotationBehavior);\r\nEmitter.registerBehavior(NoRotationBehavior);\r\nEmitter.registerBehavior(ScaleBehavior);\r\nEmitter.registerBehavior(StaticScaleBehavior);\r\nEmitter.registerBehavior(ShapeSpawnBehavior);\r\nEmitter.registerBehavior(SingleTextureBehavior);\r\nEmitter.registerBehavior(SpeedBehavior);\r\nEmitter.registerBehavior(StaticSpeedBehavior);\n\nexport { Emitter, LinkedListContainer, Particle, ParticleUtils, PropertyList, PropertyNode, index$1 as behaviors, upgradeConfig };\n//# sourceMappingURL=particle-emitter.es.js.map\n","/*!\n * @pixi/runner - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/runner is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * A Runner is a highly performant and simple alternative to signals. Best used in situations\n * where events are dispatched to many objects at high frequency (say every frame!)\n *\n *\n * like a signal..\n * ```\n * import { Runner } from '@pixi/runner';\n *\n * const myObject = {\n * loaded: new Runner('loaded')\n * }\n *\n * const listener = {\n * loaded: function(){\n * // thin\n * }\n * }\n *\n * myObject.loaded.add(listener);\n *\n * myObject.loaded.emit();\n * ```\n *\n * Or for handling calling the same function on many items\n * ```\n * import { Runner } from '@pixi/runner';\n *\n * const myGame = {\n * update: new Runner('update')\n * }\n *\n * const gameObject = {\n * update: function(time){\n * // update my gamey state\n * }\n * }\n *\n * myGame.update.add(gameObject);\n *\n * myGame.update.emit(time);\n * ```\n *\n * @memberof PIXI\n */\nvar Runner = /** @class */ (function () {\n /**\n * @param name - The function name that will be executed on the listeners added to this Runner.\n */\n function Runner(name) {\n this.items = [];\n this._name = name;\n this._aliasCount = 0;\n }\n /**\n * Dispatch/Broadcast Runner to all listeners added to the queue.\n *\n * @param {...any} params - (optional) parameters to pass to each listener\n */\n Runner.prototype.emit = function (a0, a1, a2, a3, a4, a5, a6, a7) {\n if (arguments.length > 8) {\n throw new Error('max arguments reached');\n }\n var _a = this, name = _a.name, items = _a.items;\n this._aliasCount++;\n for (var i = 0, len = items.length; i < len; i++) {\n items[i][name](a0, a1, a2, a3, a4, a5, a6, a7);\n }\n if (items === this.items) {\n this._aliasCount--;\n }\n return this;\n };\n Runner.prototype.ensureNonAliasedItems = function () {\n if (this._aliasCount > 0 && this.items.length > 1) {\n this._aliasCount = 0;\n this.items = this.items.slice(0);\n }\n };\n /**\n * Add a listener to the Runner\n *\n * Runners do not need to have scope or functions passed to them.\n * All that is required is to pass the listening object and ensure that it has contains a function that has the same name\n * as the name provided to the Runner when it was created.\n *\n * Eg A listener passed to this Runner will require a 'complete' function.\n *\n * ```\n * import { Runner } from '@pixi/runner';\n *\n * const complete = new Runner('complete');\n * ```\n *\n * The scope used will be the object itself.\n *\n * @param {any} item - The object that will be listening.\n */\n Runner.prototype.add = function (item) {\n if (item[this._name]) {\n this.ensureNonAliasedItems();\n this.remove(item);\n this.items.push(item);\n }\n return this;\n };\n /**\n * Remove a single listener from the dispatch queue.\n *\n * @param {any} item - The listener that you would like to remove.\n */\n Runner.prototype.remove = function (item) {\n var index = this.items.indexOf(item);\n if (index !== -1) {\n this.ensureNonAliasedItems();\n this.items.splice(index, 1);\n }\n return this;\n };\n /**\n * Check to see if the listener is already in the Runner\n *\n * @param {any} item - The listener that you would like to check.\n */\n Runner.prototype.contains = function (item) {\n return this.items.indexOf(item) !== -1;\n };\n /** Remove all listeners from the Runner */\n Runner.prototype.removeAll = function () {\n this.ensureNonAliasedItems();\n this.items.length = 0;\n return this;\n };\n /** Remove all references, don't use after this. */\n Runner.prototype.destroy = function () {\n this.removeAll();\n this.items = null;\n this._name = null;\n };\n Object.defineProperty(Runner.prototype, \"empty\", {\n /**\n * `true` if there are no this Runner contains no listeners\n *\n * @readonly\n */\n get: function () {\n return this.items.length === 0;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Runner.prototype, \"name\", {\n /**\n * The name of the runner.\n *\n * @readonly\n */\n get: function () {\n return this._name;\n },\n enumerable: false,\n configurable: true\n });\n return Runner;\n}());\nObject.defineProperties(Runner.prototype, {\n /**\n * Alias for `emit`\n * @memberof PIXI.Runner#\n * @method dispatch\n * @see PIXI.Runner#emit\n */\n dispatch: { value: Runner.prototype.emit },\n /**\n * Alias for `emit`\n * @memberof PIXI.Runner#\n * @method run\n * @see PIXI.Runner#emit\n */\n run: { value: Runner.prototype.emit },\n});\n\nexport { Runner };\n//# sourceMappingURL=runner.js.map\n","var appleIphone = /iPhone/i;\nvar appleIpod = /iPod/i;\nvar appleTablet = /iPad/i;\nvar appleUniversal = /\\biOS-universal(?:.+)Mac\\b/i;\nvar androidPhone = /\\bAndroid(?:.+)Mobile\\b/i;\nvar androidTablet = /Android/i;\nvar amazonPhone = /(?:SD4930UR|\\bSilk(?:.+)Mobile\\b)/i;\nvar amazonTablet = /Silk/i;\nvar windowsPhone = /Windows Phone/i;\nvar windowsTablet = /\\bWindows(?:.+)ARM\\b/i;\nvar otherBlackBerry = /BlackBerry/i;\nvar otherBlackBerry10 = /BB10/i;\nvar otherOpera = /Opera Mini/i;\nvar otherChrome = /\\b(CriOS|Chrome)(?:.+)Mobile/i;\nvar otherFirefox = /Mobile(?:.+)Firefox\\b/i;\nvar isAppleTabletOnIos13 = function (navigator) {\n return (typeof navigator !== 'undefined' &&\n navigator.platform === 'MacIntel' &&\n typeof navigator.maxTouchPoints === 'number' &&\n navigator.maxTouchPoints > 1 &&\n typeof MSStream === 'undefined');\n};\nfunction createMatch(userAgent) {\n return function (regex) { return regex.test(userAgent); };\n}\nexport default function isMobile(param) {\n var nav = {\n userAgent: '',\n platform: '',\n maxTouchPoints: 0\n };\n if (!param && typeof navigator !== 'undefined') {\n nav = {\n userAgent: navigator.userAgent,\n platform: navigator.platform,\n maxTouchPoints: navigator.maxTouchPoints || 0\n };\n }\n else if (typeof param === 'string') {\n nav.userAgent = param;\n }\n else if (param && param.userAgent) {\n nav = {\n userAgent: param.userAgent,\n platform: param.platform,\n maxTouchPoints: param.maxTouchPoints || 0\n };\n }\n var userAgent = nav.userAgent;\n var tmp = userAgent.split('[FBAN');\n if (typeof tmp[1] !== 'undefined') {\n userAgent = tmp[0];\n }\n tmp = userAgent.split('Twitter');\n if (typeof tmp[1] !== 'undefined') {\n userAgent = tmp[0];\n }\n var match = createMatch(userAgent);\n var result = {\n apple: {\n phone: match(appleIphone) && !match(windowsPhone),\n ipod: match(appleIpod),\n tablet: !match(appleIphone) &&\n (match(appleTablet) || isAppleTabletOnIos13(nav)) &&\n !match(windowsPhone),\n universal: match(appleUniversal),\n device: (match(appleIphone) ||\n match(appleIpod) ||\n match(appleTablet) ||\n match(appleUniversal) ||\n isAppleTabletOnIos13(nav)) &&\n !match(windowsPhone)\n },\n amazon: {\n phone: match(amazonPhone),\n tablet: !match(amazonPhone) && match(amazonTablet),\n device: match(amazonPhone) || match(amazonTablet)\n },\n android: {\n phone: (!match(windowsPhone) && match(amazonPhone)) ||\n (!match(windowsPhone) && match(androidPhone)),\n tablet: !match(windowsPhone) &&\n !match(amazonPhone) &&\n !match(androidPhone) &&\n (match(amazonTablet) || match(androidTablet)),\n device: (!match(windowsPhone) &&\n (match(amazonPhone) ||\n match(amazonTablet) ||\n match(androidPhone) ||\n match(androidTablet))) ||\n match(/\\bokhttp\\b/i)\n },\n windows: {\n phone: match(windowsPhone),\n tablet: match(windowsTablet),\n device: match(windowsPhone) || match(windowsTablet)\n },\n other: {\n blackberry: match(otherBlackBerry),\n blackberry10: match(otherBlackBerry10),\n opera: match(otherOpera),\n firefox: match(otherFirefox),\n chrome: match(otherChrome),\n device: match(otherBlackBerry) ||\n match(otherBlackBerry10) ||\n match(otherOpera) ||\n match(otherFirefox) ||\n match(otherChrome)\n },\n any: false,\n phone: false,\n tablet: false\n };\n result.any =\n result.apple.device ||\n result.android.device ||\n result.windows.device ||\n result.other.device;\n result.phone =\n result.apple.phone || result.android.phone || result.windows.phone;\n result.tablet =\n result.apple.tablet || result.android.tablet || result.windows.tablet;\n return result;\n}\n//# sourceMappingURL=isMobile.js.map","/*!\n * @pixi/settings - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/settings is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport isMobileCall from 'ismobilejs';\n\n// The ESM/CJS versions of ismobilejs only\nvar isMobile = isMobileCall(globalThis.navigator);\n\n/**\n * The maximum recommended texture units to use.\n * In theory the bigger the better, and for desktop we'll use as many as we can.\n * But some mobile devices slow down if there is to many branches in the shader.\n * So in practice there seems to be a sweet spot size that varies depending on the device.\n *\n * In v4, all mobile devices were limited to 4 texture units because for this.\n * In v5, we allow all texture units to be used on modern Apple or Android devices.\n *\n * @private\n * @param {number} max\n * @returns {number}\n */\nfunction maxRecommendedTextures(max) {\n var allowMax = true;\n if (isMobile.tablet || isMobile.phone) {\n if (isMobile.apple.device) {\n var match = (navigator.userAgent).match(/OS (\\d+)_(\\d+)?/);\n if (match) {\n var majorVersion = parseInt(match[1], 10);\n // Limit texture units on devices below iOS 11, which will be older hardware\n if (majorVersion < 11) {\n allowMax = false;\n }\n }\n }\n if (isMobile.android.device) {\n var match = (navigator.userAgent).match(/Android\\s([0-9.]*)/);\n if (match) {\n var majorVersion = parseInt(match[1], 10);\n // Limit texture units on devices below Android 7 (Nougat), which will be older hardware\n if (majorVersion < 7) {\n allowMax = false;\n }\n }\n }\n }\n return allowMax ? max : 4;\n}\n\n/**\n * Uploading the same buffer multiple times in a single frame can cause performance issues.\n * Apparent on iOS so only check for that at the moment\n * This check may become more complex if this issue pops up elsewhere.\n *\n * @private\n * @returns {boolean}\n */\nfunction canUploadSameBuffer() {\n return !isMobile.apple.device;\n}\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\n/**\n * User's customizable globals for overriding the default PIXI settings, such\n * as a renderer's default resolution, framerate, float precision, etc.\n * @example\n * // Use the native window resolution as the default resolution\n * // will support high-density displays when rendering\n * PIXI.settings.RESOLUTION = window.devicePixelRatio;\n *\n * // Disable interpolation when scaling, will make texture be pixelated\n * PIXI.settings.SCALE_MODE = PIXI.SCALE_MODES.NEAREST;\n * @namespace PIXI.settings\n */\nvar settings = {\n /**\n * If set to true WebGL will attempt make textures mimpaped by default.\n * Mipmapping will only succeed if the base texture uploaded has power of two dimensions.\n *\n * @static\n * @name MIPMAP_TEXTURES\n * @memberof PIXI.settings\n * @type {PIXI.MIPMAP_MODES}\n * @default PIXI.MIPMAP_MODES.POW2\n */\n MIPMAP_TEXTURES: MIPMAP_MODES.POW2,\n /**\n * Default anisotropic filtering level of textures.\n * Usually from 0 to 16\n *\n * @static\n * @name ANISOTROPIC_LEVEL\n * @memberof PIXI.settings\n * @type {number}\n * @default 0\n */\n ANISOTROPIC_LEVEL: 0,\n /**\n * Default resolution / device pixel ratio of the renderer.\n *\n * @static\n * @name RESOLUTION\n * @memberof PIXI.settings\n * @type {number}\n * @default 1\n */\n RESOLUTION: 1,\n /**\n * Default filter resolution.\n *\n * @static\n * @name FILTER_RESOLUTION\n * @memberof PIXI.settings\n * @type {number}\n * @default 1\n */\n FILTER_RESOLUTION: 1,\n /**\n * Default filter samples.\n *\n * @static\n * @name FILTER_MULTISAMPLE\n * @memberof PIXI.settings\n * @type {PIXI.MSAA_QUALITY}\n * @default PIXI.MSAA_QUALITY.NONE\n */\n FILTER_MULTISAMPLE: MSAA_QUALITY.NONE,\n /**\n * The maximum textures that this device supports.\n *\n * @static\n * @name SPRITE_MAX_TEXTURES\n * @memberof PIXI.settings\n * @type {number}\n * @default 32\n */\n SPRITE_MAX_TEXTURES: maxRecommendedTextures(32),\n // TODO: maybe change to SPRITE.BATCH_SIZE: 2000\n // TODO: maybe add PARTICLE.BATCH_SIZE: 15000\n /**\n * The default sprite batch size.\n *\n * The default aims to balance desktop and mobile devices.\n *\n * @static\n * @name SPRITE_BATCH_SIZE\n * @memberof PIXI.settings\n * @type {number}\n * @default 4096\n */\n SPRITE_BATCH_SIZE: 4096,\n /**\n * The default render options if none are supplied to {@link PIXI.Renderer}\n * or {@link PIXI.CanvasRenderer}.\n *\n * @static\n * @name RENDER_OPTIONS\n * @memberof PIXI.settings\n * @type {object}\n * @property {HTMLCanvasElement} view=null\n * @property {boolean} antialias=false\n * @property {boolean} autoDensity=false\n * @property {boolean} useContextAlpha=true\n * @property {number} backgroundColor=0x000000\n * @property {number} backgroundAlpha=1\n * @property {boolean} clearBeforeRender=true\n * @property {boolean} preserveDrawingBuffer=false\n * @property {number} width=800\n * @property {number} height=600\n * @property {boolean} legacy=false\n */\n RENDER_OPTIONS: {\n view: null,\n antialias: false,\n autoDensity: false,\n backgroundColor: 0x000000,\n backgroundAlpha: 1,\n useContextAlpha: true,\n clearBeforeRender: true,\n preserveDrawingBuffer: false,\n width: 800,\n height: 600,\n legacy: false,\n },\n /**\n * Default Garbage Collection mode.\n *\n * @static\n * @name GC_MODE\n * @memberof PIXI.settings\n * @type {PIXI.GC_MODES}\n * @default PIXI.GC_MODES.AUTO\n */\n GC_MODE: GC_MODES.AUTO,\n /**\n * Default Garbage Collection max idle.\n *\n * @static\n * @name GC_MAX_IDLE\n * @memberof PIXI.settings\n * @type {number}\n * @default 3600\n */\n GC_MAX_IDLE: 60 * 60,\n /**\n * Default Garbage Collection maximum check count.\n *\n * @static\n * @name GC_MAX_CHECK_COUNT\n * @memberof PIXI.settings\n * @type {number}\n * @default 600\n */\n GC_MAX_CHECK_COUNT: 60 * 10,\n /**\n * Default wrap modes that are supported by pixi.\n *\n * @static\n * @name WRAP_MODE\n * @memberof PIXI.settings\n * @type {PIXI.WRAP_MODES}\n * @default PIXI.WRAP_MODES.CLAMP\n */\n WRAP_MODE: WRAP_MODES.CLAMP,\n /**\n * Default scale mode for textures.\n *\n * @static\n * @name SCALE_MODE\n * @memberof PIXI.settings\n * @type {PIXI.SCALE_MODES}\n * @default PIXI.SCALE_MODES.LINEAR\n */\n SCALE_MODE: SCALE_MODES.LINEAR,\n /**\n * Default specify float precision in vertex shader.\n *\n * @static\n * @name PRECISION_VERTEX\n * @memberof PIXI.settings\n * @type {PIXI.PRECISION}\n * @default PIXI.PRECISION.HIGH\n */\n PRECISION_VERTEX: PRECISION.HIGH,\n /**\n * Default specify float precision in fragment shader.\n * iOS is best set at highp due to https://github.com/pixijs/pixi.js/issues/3742\n *\n * @static\n * @name PRECISION_FRAGMENT\n * @memberof PIXI.settings\n * @type {PIXI.PRECISION}\n * @default PIXI.PRECISION.MEDIUM\n */\n PRECISION_FRAGMENT: isMobile.apple.device ? PRECISION.HIGH : PRECISION.MEDIUM,\n /**\n * Can we upload the same buffer in a single frame?\n *\n * @static\n * @name CAN_UPLOAD_SAME_BUFFER\n * @memberof PIXI.settings\n * @type {boolean}\n */\n CAN_UPLOAD_SAME_BUFFER: canUploadSameBuffer(),\n /**\n * Enables bitmap creation before image load. This feature is experimental.\n *\n * @static\n * @name CREATE_IMAGE_BITMAP\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\n CREATE_IMAGE_BITMAP: false,\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n *\n * @static\n * @constant\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\n ROUND_PIXELS: false,\n};\n\nexport { isMobile, settings };\n//# sourceMappingURL=settings.js.map\n","/*!\n * @pixi/sprite - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/sprite is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { BLEND_MODES } from '@pixi/constants';\nimport { Texture } from '@pixi/core';\nimport { Bounds, Container } from '@pixi/display';\nimport { Point, Rectangle, ObservablePoint } from '@pixi/math';\nimport { settings } from '@pixi/settings';\nimport { sign } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar tempPoint = new Point();\nvar indices = new Uint16Array([0, 1, 2, 0, 2, 3]);\n/**\n * The Sprite object is the base for all textured objects that are rendered to the screen\n*\n * A sprite can be created directly from an image like this:\n *\n * ```js\n * let sprite = PIXI.Sprite.from('assets/image.png');\n * ```\n *\n * The more efficient way to create sprites is using a {@link PIXI.Spritesheet},\n * as swapping base textures when rendering to the screen is inefficient.\n *\n * ```js\n * PIXI.Loader.shared.add(\"assets/spritesheet.json\").load(setup);\n *\n * function setup() {\n * let sheet = PIXI.Loader.shared.resources[\"assets/spritesheet.json\"].spritesheet;\n * let sprite = new PIXI.Sprite(sheet.textures[\"image.png\"]);\n * ...\n * }\n * ```\n *\n * @memberof PIXI\n */\nvar Sprite = /** @class */ (function (_super) {\n __extends(Sprite, _super);\n /** @param texture - The texture for this sprite. */\n function Sprite(texture) {\n var _this = _super.call(this) || this;\n _this._anchor = new ObservablePoint(_this._onAnchorUpdate, _this, (texture ? texture.defaultAnchor.x : 0), (texture ? texture.defaultAnchor.y : 0));\n _this._texture = null;\n _this._width = 0;\n _this._height = 0;\n _this._tint = null;\n _this._tintRGB = null;\n _this.tint = 0xFFFFFF;\n _this.blendMode = BLEND_MODES.NORMAL;\n _this._cachedTint = 0xFFFFFF;\n _this.uvs = null;\n // call texture setter\n _this.texture = texture || Texture.EMPTY;\n _this.vertexData = new Float32Array(8);\n _this.vertexTrimmedData = null;\n _this._transformID = -1;\n _this._textureID = -1;\n _this._transformTrimmedID = -1;\n _this._textureTrimmedID = -1;\n // Batchable stuff..\n // TODO could make this a mixin?\n _this.indices = indices;\n _this.pluginName = 'batch';\n /**\n * Used to fast check if a sprite is.. a sprite!\n * @member {boolean}\n */\n _this.isSprite = true;\n _this._roundPixels = settings.ROUND_PIXELS;\n return _this;\n }\n /** When the texture is updated, this event will fire to update the scale and frame. */\n Sprite.prototype._onTextureUpdate = function () {\n this._textureID = -1;\n this._textureTrimmedID = -1;\n this._cachedTint = 0xFFFFFF;\n // so if _width is 0 then width was not set..\n if (this._width) {\n this.scale.x = sign(this.scale.x) * this._width / this._texture.orig.width;\n }\n if (this._height) {\n this.scale.y = sign(this.scale.y) * this._height / this._texture.orig.height;\n }\n };\n /** Called when the anchor position updates. */\n Sprite.prototype._onAnchorUpdate = function () {\n this._transformID = -1;\n this._transformTrimmedID = -1;\n };\n /** Calculates worldTransform * vertices, store it in vertexData. */\n Sprite.prototype.calculateVertices = function () {\n var texture = this._texture;\n if (this._transformID === this.transform._worldID && this._textureID === texture._updateID) {\n return;\n }\n // update texture UV here, because base texture can be changed without calling `_onTextureUpdate`\n if (this._textureID !== texture._updateID) {\n this.uvs = this._texture._uvs.uvsFloat32;\n }\n this._transformID = this.transform._worldID;\n this._textureID = texture._updateID;\n // set the vertex data\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var vertexData = this.vertexData;\n var trim = texture.trim;\n var orig = texture.orig;\n var anchor = this._anchor;\n var w0 = 0;\n var w1 = 0;\n var h0 = 0;\n var h1 = 0;\n if (trim) {\n // if the sprite is trimmed and is not a tilingsprite then we need to add the extra\n // space before transforming the sprite coords.\n w1 = trim.x - (anchor._x * orig.width);\n w0 = w1 + trim.width;\n h1 = trim.y - (anchor._y * orig.height);\n h0 = h1 + trim.height;\n }\n else {\n w1 = -anchor._x * orig.width;\n w0 = w1 + orig.width;\n h1 = -anchor._y * orig.height;\n h0 = h1 + orig.height;\n }\n // xy\n vertexData[0] = (a * w1) + (c * h1) + tx;\n vertexData[1] = (d * h1) + (b * w1) + ty;\n // xy\n vertexData[2] = (a * w0) + (c * h1) + tx;\n vertexData[3] = (d * h1) + (b * w0) + ty;\n // xy\n vertexData[4] = (a * w0) + (c * h0) + tx;\n vertexData[5] = (d * h0) + (b * w0) + ty;\n // xy\n vertexData[6] = (a * w1) + (c * h0) + tx;\n vertexData[7] = (d * h0) + (b * w1) + ty;\n if (this._roundPixels) {\n var resolution = settings.RESOLUTION;\n for (var i = 0; i < vertexData.length; ++i) {\n vertexData[i] = Math.round((vertexData[i] * resolution | 0) / resolution);\n }\n }\n };\n /**\n * Calculates worldTransform * vertices for a non texture with a trim. store it in vertexTrimmedData.\n *\n * This is used to ensure that the true width and height of a trimmed texture is respected.\n */\n Sprite.prototype.calculateTrimmedVertices = function () {\n if (!this.vertexTrimmedData) {\n this.vertexTrimmedData = new Float32Array(8);\n }\n else if (this._transformTrimmedID === this.transform._worldID && this._textureTrimmedID === this._texture._updateID) {\n return;\n }\n this._transformTrimmedID = this.transform._worldID;\n this._textureTrimmedID = this._texture._updateID;\n // lets do some special trim code!\n var texture = this._texture;\n var vertexData = this.vertexTrimmedData;\n var orig = texture.orig;\n var anchor = this._anchor;\n // lets calculate the new untrimmed bounds..\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var w1 = -anchor._x * orig.width;\n var w0 = w1 + orig.width;\n var h1 = -anchor._y * orig.height;\n var h0 = h1 + orig.height;\n // xy\n vertexData[0] = (a * w1) + (c * h1) + tx;\n vertexData[1] = (d * h1) + (b * w1) + ty;\n // xy\n vertexData[2] = (a * w0) + (c * h1) + tx;\n vertexData[3] = (d * h1) + (b * w0) + ty;\n // xy\n vertexData[4] = (a * w0) + (c * h0) + tx;\n vertexData[5] = (d * h0) + (b * w0) + ty;\n // xy\n vertexData[6] = (a * w1) + (c * h0) + tx;\n vertexData[7] = (d * h0) + (b * w1) + ty;\n };\n /**\n *\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The webgl renderer to use.\n */\n Sprite.prototype._render = function (renderer) {\n this.calculateVertices();\n renderer.batch.setObjectRenderer(renderer.plugins[this.pluginName]);\n renderer.plugins[this.pluginName].render(this);\n };\n /** Updates the bounds of the sprite. */\n Sprite.prototype._calculateBounds = function () {\n var trim = this._texture.trim;\n var orig = this._texture.orig;\n // First lets check to see if the current texture has a trim..\n if (!trim || (trim.width === orig.width && trim.height === orig.height)) {\n // no trim! lets use the usual calculations..\n this.calculateVertices();\n this._bounds.addQuad(this.vertexData);\n }\n else {\n // lets calculate a special trimmed bounds...\n this.calculateTrimmedVertices();\n this._bounds.addQuad(this.vertexTrimmedData);\n }\n };\n /**\n * Gets the local bounds of the sprite object.\n *\n * @param rect - Optional output rectangle.\n * @return The bounds.\n */\n Sprite.prototype.getLocalBounds = function (rect) {\n // we can do a fast local bounds if the sprite has no children!\n if (this.children.length === 0) {\n if (!this._localBounds) {\n this._localBounds = new Bounds();\n }\n this._localBounds.minX = this._texture.orig.width * -this._anchor._x;\n this._localBounds.minY = this._texture.orig.height * -this._anchor._y;\n this._localBounds.maxX = this._texture.orig.width * (1 - this._anchor._x);\n this._localBounds.maxY = this._texture.orig.height * (1 - this._anchor._y);\n if (!rect) {\n if (!this._localBoundsRect) {\n this._localBoundsRect = new Rectangle();\n }\n rect = this._localBoundsRect;\n }\n return this._localBounds.getRectangle(rect);\n }\n return _super.prototype.getLocalBounds.call(this, rect);\n };\n /**\n * Tests if a point is inside this sprite\n *\n * @param point - the point to test\n * @return The result of the test\n */\n Sprite.prototype.containsPoint = function (point) {\n this.worldTransform.applyInverse(point, tempPoint);\n var width = this._texture.orig.width;\n var height = this._texture.orig.height;\n var x1 = -width * this.anchor.x;\n var y1 = 0;\n if (tempPoint.x >= x1 && tempPoint.x < x1 + width) {\n y1 = -height * this.anchor.y;\n if (tempPoint.y >= y1 && tempPoint.y < y1 + height) {\n return true;\n }\n }\n return false;\n };\n /**\n * Destroys this sprite and optionally its texture and children.\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param [options.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param [options.texture=false] - Should it destroy the current texture of the sprite as well\n * @param [options.baseTexture=false] - Should it destroy the base texture of the sprite as well\n */\n Sprite.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n this._texture.off('update', this._onTextureUpdate, this);\n this._anchor = null;\n var destroyTexture = typeof options === 'boolean' ? options : options && options.texture;\n if (destroyTexture) {\n var destroyBaseTexture = typeof options === 'boolean' ? options : options && options.baseTexture;\n this._texture.destroy(!!destroyBaseTexture);\n }\n this._texture = null;\n };\n // some helper functions..\n /**\n * Helper function that creates a new sprite based on the source you provide.\n * The source can be - frame id, image url, video url, canvas element, video element, base texture\n *\n * @param {string|PIXI.Texture|HTMLCanvasElement|HTMLVideoElement} source - Source to create texture from\n * @param {object} [options] - See {@link PIXI.BaseTexture}'s constructor for options.\n * @return The newly created sprite\n */\n Sprite.from = function (source, options) {\n var texture = (source instanceof Texture)\n ? source\n : Texture.from(source, options);\n return new Sprite(texture);\n };\n Object.defineProperty(Sprite.prototype, \"roundPixels\", {\n get: function () {\n return this._roundPixels;\n },\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n *\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n *\n * To set the global default, change {@link PIXI.settings.ROUND_PIXELS}.\n *\n * @default false\n */\n set: function (value) {\n if (this._roundPixels !== value) {\n this._transformID = -1;\n }\n this._roundPixels = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"width\", {\n /** The width of the sprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return Math.abs(this.scale.x) * this._texture.orig.width;\n },\n set: function (value) {\n var s = sign(this.scale.x) || 1;\n this.scale.x = s * value / this._texture.orig.width;\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"height\", {\n /** The height of the sprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return Math.abs(this.scale.y) * this._texture.orig.height;\n },\n set: function (value) {\n var s = sign(this.scale.y) || 1;\n this.scale.y = s * value / this._texture.orig.height;\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"anchor\", {\n /**\n * The anchor sets the origin point of the sprite. The default value is taken from the {@link PIXI.Texture|Texture}\n * and passed to the constructor.\n *\n * The default is `(0,0)`, this means the sprite's origin is the top left.\n *\n * Setting the anchor to `(0.5,0.5)` means the sprite's origin is centered.\n *\n * Setting the anchor to `(1,1)` would mean the sprite's origin point will be the bottom right corner.\n *\n * If you pass only single parameter, it will set both x and y to the same value as shown in the example below.\n *\n * @example\n * const sprite = new PIXI.Sprite(texture);\n * sprite.anchor.set(0.5); // This will set the origin to center. (0.5) is same as (0.5, 0.5).\n */\n get: function () {\n return this._anchor;\n },\n set: function (value) {\n this._anchor.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"tint\", {\n /**\n * The tint applied to the sprite. This is a hex value.\n *\n * A value of 0xFFFFFF will remove any tint effect.\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n this._tint = value;\n this._tintRGB = (value >> 16) + (value & 0xff00) + ((value & 0xff) << 16);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Sprite.prototype, \"texture\", {\n /** The texture that the sprite is using. */\n get: function () {\n return this._texture;\n },\n set: function (value) {\n if (this._texture === value) {\n return;\n }\n if (this._texture) {\n this._texture.off('update', this._onTextureUpdate, this);\n }\n this._texture = value || Texture.EMPTY;\n this._cachedTint = 0xFFFFFF;\n this._textureID = -1;\n this._textureTrimmedID = -1;\n if (value) {\n // wait for the texture to load\n if (value.baseTexture.valid) {\n this._onTextureUpdate();\n }\n else {\n value.once('update', this._onTextureUpdate, this);\n }\n }\n },\n enumerable: false,\n configurable: true\n });\n return Sprite;\n}(Container));\n\nexport { Sprite };\n//# sourceMappingURL=sprite.js.map\n","/*!\n * @pixi/ticker - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/ticker is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\n\n/**\n * Target frames per millisecond.\n *\n * @static\n * @name TARGET_FPMS\n * @memberof PIXI.settings\n * @type {number}\n * @default 0.06\n */\nsettings.TARGET_FPMS = 0.06;\n\n/**\n * Represents the update priorities used by internal PIXI classes when registered with\n * the {@link PIXI.Ticker} object. Higher priority items are updated first and lower\n * priority items, such as render, should go later.\n *\n * @static\n * @constant\n * @name UPDATE_PRIORITY\n * @memberof PIXI\n * @enum {number}\n * @property {number} INTERACTION=50 Highest priority, used for {@link PIXI.InteractionManager}\n * @property {number} HIGH=25 High priority updating, {@link PIXI.VideoBaseTexture} and {@link PIXI.AnimatedSprite}\n * @property {number} NORMAL=0 Default priority for ticker events, see {@link PIXI.Ticker#add}.\n * @property {number} LOW=-25 Low priority used for {@link PIXI.Application} rendering.\n * @property {number} UTILITY=-50 Lowest priority used for {@link PIXI.BasePrepare} utility.\n */\nvar UPDATE_PRIORITY;\n(function (UPDATE_PRIORITY) {\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"INTERACTION\"] = 50] = \"INTERACTION\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"HIGH\"] = 25] = \"HIGH\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"NORMAL\"] = 0] = \"NORMAL\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"LOW\"] = -25] = \"LOW\";\n UPDATE_PRIORITY[UPDATE_PRIORITY[\"UTILITY\"] = -50] = \"UTILITY\";\n})(UPDATE_PRIORITY || (UPDATE_PRIORITY = {}));\n\n/**\n * Internal class for handling the priority sorting of ticker handlers.\n *\n * @private\n * @class\n * @memberof PIXI\n */\nvar TickerListener = /** @class */ (function () {\n /**\n * Constructor\n * @private\n * @param fn - The listener function to be added for one update\n * @param context - The listener context\n * @param priority - The priority for emitting\n * @param once - If the handler should fire once\n */\n function TickerListener(fn, context, priority, once) {\n if (context === void 0) { context = null; }\n if (priority === void 0) { priority = 0; }\n if (once === void 0) { once = false; }\n /** The next item in chain. */\n this.next = null;\n /** The previous item in chain. */\n this.previous = null;\n /** `true` if this listener has been destroyed already. */\n this._destroyed = false;\n this.fn = fn;\n this.context = context;\n this.priority = priority;\n this.once = once;\n }\n /**\n * Simple compare function to figure out if a function and context match.\n * @private\n * @param fn - The listener function to be added for one update\n * @param context - The listener context\n * @return `true` if the listener match the arguments\n */\n TickerListener.prototype.match = function (fn, context) {\n if (context === void 0) { context = null; }\n return this.fn === fn && this.context === context;\n };\n /**\n * Emit by calling the current function.\n * @private\n * @param deltaTime - time since the last emit.\n * @return Next ticker\n */\n TickerListener.prototype.emit = function (deltaTime) {\n if (this.fn) {\n if (this.context) {\n this.fn.call(this.context, deltaTime);\n }\n else {\n this.fn(deltaTime);\n }\n }\n var redirect = this.next;\n if (this.once) {\n this.destroy(true);\n }\n // Soft-destroying should remove\n // the next reference\n if (this._destroyed) {\n this.next = null;\n }\n return redirect;\n };\n /**\n * Connect to the list.\n * @private\n * @param previous - Input node, previous listener\n */\n TickerListener.prototype.connect = function (previous) {\n this.previous = previous;\n if (previous.next) {\n previous.next.previous = this;\n }\n this.next = previous.next;\n previous.next = this;\n };\n /**\n * Destroy and don't use after this.\n * @private\n * @param hard - `true` to remove the `next` reference, this\n * is considered a hard destroy. Soft destroy maintains the next reference.\n * @return The listener to redirect while emitting or removing.\n */\n TickerListener.prototype.destroy = function (hard) {\n if (hard === void 0) { hard = false; }\n this._destroyed = true;\n this.fn = null;\n this.context = null;\n // Disconnect, hook up next and previous\n if (this.previous) {\n this.previous.next = this.next;\n }\n if (this.next) {\n this.next.previous = this.previous;\n }\n // Redirect to the next item\n var redirect = this.next;\n // Remove references\n this.next = hard ? null : redirect;\n this.previous = null;\n return redirect;\n };\n return TickerListener;\n}());\n\n/**\n * A Ticker class that runs an update loop that other objects listen to.\n *\n * This class is composed around listeners meant for execution on the next requested animation frame.\n * Animation frames are requested only when necessary, e.g. When the ticker is started and the emitter has listeners.\n *\n * @class\n * @memberof PIXI\n */\nvar Ticker = /** @class */ (function () {\n function Ticker() {\n var _this = this;\n /**\n * Whether or not this ticker should invoke the method\n * {@link PIXI.Ticker#start} automatically\n * when a listener is added.\n */\n this.autoStart = false;\n /**\n * Scalar time value from last frame to this frame.\n * This value is capped by setting {@link PIXI.Ticker#minFPS}\n * and is scaled with {@link PIXI.Ticker#speed}.\n * **Note:** The cap may be exceeded by scaling.\n */\n this.deltaTime = 1;\n /**\n * The last time {@link PIXI.Ticker#update} was invoked.\n * This value is also reset internally outside of invoking\n * update, but only when a new animation frame is requested.\n * If the platform supports DOMHighResTimeStamp,\n * this value will have a precision of 1 µs.\n */\n this.lastTime = -1;\n /**\n * Factor of current {@link PIXI.Ticker#deltaTime}.\n * @example\n * // Scales ticker.deltaTime to what would be\n * // the equivalent of approximately 120 FPS\n * ticker.speed = 2;\n */\n this.speed = 1;\n /**\n * Whether or not this ticker has been started.\n * `true` if {@link PIXI.Ticker#start} has been called.\n * `false` if {@link PIXI.Ticker#stop} has been called.\n * While `false`, this value may change to `true` in the\n * event of {@link PIXI.Ticker#autoStart} being `true`\n * and a listener is added.\n */\n this.started = false;\n /** Internal current frame request ID */\n this._requestId = null;\n /**\n * Internal value managed by minFPS property setter and getter.\n * This is the maximum allowed milliseconds between updates.\n */\n this._maxElapsedMS = 100;\n /**\n * Internal value managed by minFPS property setter and getter.\n * This is the minimum allowed milliseconds between updates.\n */\n this._minElapsedMS = 0;\n /** If enabled, deleting is disabled.*/\n this._protected = false;\n /**\n * The last time keyframe was executed.\n * Maintains a relatively fixed interval with the previous value.\n */\n this._lastFrame = -1;\n this._head = new TickerListener(null, null, Infinity);\n this.deltaMS = 1 / settings.TARGET_FPMS;\n this.elapsedMS = 1 / settings.TARGET_FPMS;\n this._tick = function (time) {\n _this._requestId = null;\n if (_this.started) {\n // Invoke listeners now\n _this.update(time);\n // Listener side effects may have modified ticker state.\n if (_this.started && _this._requestId === null && _this._head.next) {\n _this._requestId = requestAnimationFrame(_this._tick);\n }\n }\n };\n }\n /**\n * Conditionally requests a new animation frame.\n * If a frame has not already been requested, and if the internal\n * emitter has listeners, a new frame is requested.\n *\n * @private\n */\n Ticker.prototype._requestIfNeeded = function () {\n if (this._requestId === null && this._head.next) {\n // ensure callbacks get correct delta\n this.lastTime = performance.now();\n this._lastFrame = this.lastTime;\n this._requestId = requestAnimationFrame(this._tick);\n }\n };\n /**\n * Conditionally cancels a pending animation frame.\n * @private\n */\n Ticker.prototype._cancelIfNeeded = function () {\n if (this._requestId !== null) {\n cancelAnimationFrame(this._requestId);\n this._requestId = null;\n }\n };\n /**\n * Conditionally requests a new animation frame.\n * If the ticker has been started it checks if a frame has not already\n * been requested, and if the internal emitter has listeners. If these\n * conditions are met, a new frame is requested. If the ticker has not\n * been started, but autoStart is `true`, then the ticker starts now,\n * and continues with the previous conditions to request a new frame.\n *\n * @private\n */\n Ticker.prototype._startIfPossible = function () {\n if (this.started) {\n this._requestIfNeeded();\n }\n else if (this.autoStart) {\n this.start();\n }\n };\n /**\n * Register a handler for tick events. Calls continuously unless\n * it is removed or the ticker is stopped.\n *\n * @param fn - The listener function to be added for updates\n * @param context - The listener context\n * @param {number} [priority=PIXI.UPDATE_PRIORITY.NORMAL] - The priority for emitting\n * @returns This instance of a ticker\n */\n Ticker.prototype.add = function (fn, context, priority) {\n if (priority === void 0) { priority = UPDATE_PRIORITY.NORMAL; }\n return this._addListener(new TickerListener(fn, context, priority));\n };\n /**\n * Add a handler for the tick event which is only execute once.\n *\n * @param fn - The listener function to be added for one update\n * @param context - The listener context\n * @param {number} [priority=PIXI.UPDATE_PRIORITY.NORMAL] - The priority for emitting\n * @returns This instance of a ticker\n */\n Ticker.prototype.addOnce = function (fn, context, priority) {\n if (priority === void 0) { priority = UPDATE_PRIORITY.NORMAL; }\n return this._addListener(new TickerListener(fn, context, priority, true));\n };\n /**\n * Internally adds the event handler so that it can be sorted by priority.\n * Priority allows certain handler (user, AnimatedSprite, Interaction) to be run\n * before the rendering.\n *\n * @private\n * @param listener - Current listener being added.\n * @returns This instance of a ticker\n */\n Ticker.prototype._addListener = function (listener) {\n // For attaching to head\n var current = this._head.next;\n var previous = this._head;\n // Add the first item\n if (!current) {\n listener.connect(previous);\n }\n else {\n // Go from highest to lowest priority\n while (current) {\n if (listener.priority > current.priority) {\n listener.connect(previous);\n break;\n }\n previous = current;\n current = current.next;\n }\n // Not yet connected\n if (!listener.previous) {\n listener.connect(previous);\n }\n }\n this._startIfPossible();\n return this;\n };\n /**\n * Removes any handlers matching the function and context parameters.\n * If no handlers are left after removing, then it cancels the animation frame.\n *\n * @param fn - The listener function to be removed\n * @param context - The listener context to be removed\n * @returns This instance of a ticker\n */\n Ticker.prototype.remove = function (fn, context) {\n var listener = this._head.next;\n while (listener) {\n // We found a match, lets remove it\n // no break to delete all possible matches\n // incase a listener was added 2+ times\n if (listener.match(fn, context)) {\n listener = listener.destroy();\n }\n else {\n listener = listener.next;\n }\n }\n if (!this._head.next) {\n this._cancelIfNeeded();\n }\n return this;\n };\n Object.defineProperty(Ticker.prototype, \"count\", {\n /**\n * The number of listeners on this ticker, calculated by walking through linked list\n *\n * @readonly\n * @member {number}\n */\n get: function () {\n if (!this._head) {\n return 0;\n }\n var count = 0;\n var current = this._head;\n while ((current = current.next)) {\n count++;\n }\n return count;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Starts the ticker. If the ticker has listeners\n * a new animation frame is requested at this point.\n */\n Ticker.prototype.start = function () {\n if (!this.started) {\n this.started = true;\n this._requestIfNeeded();\n }\n };\n /**\n * Stops the ticker. If the ticker has requested\n * an animation frame it is canceled at this point.\n */\n Ticker.prototype.stop = function () {\n if (this.started) {\n this.started = false;\n this._cancelIfNeeded();\n }\n };\n /**\n * Destroy the ticker and don't use after this. Calling\n * this method removes all references to internal events.\n */\n Ticker.prototype.destroy = function () {\n if (!this._protected) {\n this.stop();\n var listener = this._head.next;\n while (listener) {\n listener = listener.destroy(true);\n }\n this._head.destroy();\n this._head = null;\n }\n };\n /**\n * Triggers an update. An update entails setting the\n * current {@link PIXI.Ticker#elapsedMS},\n * the current {@link PIXI.Ticker#deltaTime},\n * invoking all listeners with current deltaTime,\n * and then finally setting {@link PIXI.Ticker#lastTime}\n * with the value of currentTime that was provided.\n * This method will be called automatically by animation\n * frame callbacks if the ticker instance has been started\n * and listeners are added.\n *\n * @param {number} [currentTime=performance.now()] - the current time of execution\n */\n Ticker.prototype.update = function (currentTime) {\n if (currentTime === void 0) { currentTime = performance.now(); }\n var elapsedMS;\n // If the difference in time is zero or negative, we ignore most of the work done here.\n // If there is no valid difference, then should be no reason to let anyone know about it.\n // A zero delta, is exactly that, nothing should update.\n //\n // The difference in time can be negative, and no this does not mean time traveling.\n // This can be the result of a race condition between when an animation frame is requested\n // on the current JavaScript engine event loop, and when the ticker's start method is invoked\n // (which invokes the internal _requestIfNeeded method). If a frame is requested before\n // _requestIfNeeded is invoked, then the callback for the animation frame the ticker requests,\n // can receive a time argument that can be less than the lastTime value that was set within\n // _requestIfNeeded. This difference is in microseconds, but this is enough to cause problems.\n //\n // This check covers this browser engine timing issue, as well as if consumers pass an invalid\n // currentTime value. This may happen if consumers opt-out of the autoStart, and update themselves.\n if (currentTime > this.lastTime) {\n // Save uncapped elapsedMS for measurement\n elapsedMS = this.elapsedMS = currentTime - this.lastTime;\n // cap the milliseconds elapsed used for deltaTime\n if (elapsedMS > this._maxElapsedMS) {\n elapsedMS = this._maxElapsedMS;\n }\n elapsedMS *= this.speed;\n // If not enough time has passed, exit the function.\n // Get ready for next frame by setting _lastFrame, but based on _minElapsedMS\n // adjustment to ensure a relatively stable interval.\n if (this._minElapsedMS) {\n var delta = currentTime - this._lastFrame | 0;\n if (delta < this._minElapsedMS) {\n return;\n }\n this._lastFrame = currentTime - (delta % this._minElapsedMS);\n }\n this.deltaMS = elapsedMS;\n this.deltaTime = this.deltaMS * settings.TARGET_FPMS;\n // Cache a local reference, in-case ticker is destroyed\n // during the emit, we can still check for head.next\n var head = this._head;\n // Invoke listeners added to internal emitter\n var listener = head.next;\n while (listener) {\n listener = listener.emit(this.deltaTime);\n }\n if (!head.next) {\n this._cancelIfNeeded();\n }\n }\n else {\n this.deltaTime = this.deltaMS = this.elapsedMS = 0;\n }\n this.lastTime = currentTime;\n };\n Object.defineProperty(Ticker.prototype, \"FPS\", {\n /**\n * The frames per second at which this ticker is running.\n * The default is approximately 60 in most modern browsers.\n * **Note:** This does not factor in the value of\n * {@link PIXI.Ticker#speed}, which is specific\n * to scaling {@link PIXI.Ticker#deltaTime}.\n *\n * @member {number}\n * @readonly\n */\n get: function () {\n return 1000 / this.elapsedMS;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker.prototype, \"minFPS\", {\n /**\n * Manages the maximum amount of milliseconds allowed to\n * elapse between invoking {@link PIXI.Ticker#update}.\n * This value is used to cap {@link PIXI.Ticker#deltaTime},\n * but does not effect the measured value of {@link PIXI.Ticker#FPS}.\n * When setting this property it is clamped to a value between\n * `0` and `PIXI.settings.TARGET_FPMS * 1000`.\n *\n * @member {number}\n * @default 10\n */\n get: function () {\n return 1000 / this._maxElapsedMS;\n },\n set: function (fps) {\n // Minimum must be below the maxFPS\n var minFPS = Math.min(this.maxFPS, fps);\n // Must be at least 0, but below 1 / settings.TARGET_FPMS\n var minFPMS = Math.min(Math.max(0, minFPS) / 1000, settings.TARGET_FPMS);\n this._maxElapsedMS = 1 / minFPMS;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker.prototype, \"maxFPS\", {\n /**\n * Manages the minimum amount of milliseconds required to\n * elapse between invoking {@link PIXI.Ticker#update}.\n * This will effect the measured value of {@link PIXI.Ticker#FPS}.\n * If it is set to `0`, then there is no limit; PixiJS will render as many frames as it can.\n * Otherwise it will be at least `minFPS`\n *\n * @member {number}\n * @default 0\n */\n get: function () {\n if (this._minElapsedMS) {\n return Math.round(1000 / this._minElapsedMS);\n }\n return 0;\n },\n set: function (fps) {\n if (fps === 0) {\n this._minElapsedMS = 0;\n }\n else {\n // Max must be at least the minFPS\n var maxFPS = Math.max(this.minFPS, fps);\n this._minElapsedMS = 1 / (maxFPS / 1000);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker, \"shared\", {\n /**\n * The shared ticker instance used by {@link PIXI.AnimatedSprite} and by\n * {@link PIXI.VideoResource} to update animation frames / video textures.\n *\n * It may also be used by {@link PIXI.Application} if created with the `sharedTicker` option property set to true.\n *\n * The property {@link PIXI.Ticker#autoStart} is set to `true` for this instance.\n * Please follow the examples for usage, including how to opt-out of auto-starting the shared ticker.\n *\n * @example\n * let ticker = PIXI.Ticker.shared;\n * // Set this to prevent starting this ticker when listeners are added.\n * // By default this is true only for the PIXI.Ticker.shared instance.\n * ticker.autoStart = false;\n * // FYI, call this to ensure the ticker is stopped. It should be stopped\n * // if you have not attempted to render anything yet.\n * ticker.stop();\n * // Call this when you are ready for a running shared ticker.\n * ticker.start();\n *\n * @example\n * // You may use the shared ticker to render...\n * let renderer = PIXI.autoDetectRenderer();\n * let stage = new PIXI.Container();\n * document.body.appendChild(renderer.view);\n * ticker.add(function (time) {\n * renderer.render(stage);\n * });\n *\n * @example\n * // Or you can just update it manually.\n * ticker.autoStart = false;\n * ticker.stop();\n * function animate(time) {\n * ticker.update(time);\n * renderer.render(stage);\n * requestAnimationFrame(animate);\n * }\n * animate(performance.now());\n *\n * @member {PIXI.Ticker}\n * @static\n */\n get: function () {\n if (!Ticker._shared) {\n var shared = Ticker._shared = new Ticker();\n shared.autoStart = true;\n shared._protected = true;\n }\n return Ticker._shared;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Ticker, \"system\", {\n /**\n * The system ticker instance used by {@link PIXI.InteractionManager} and by\n * {@link PIXI.BasePrepare} for core timing functionality that shouldn't usually need to be paused,\n * unlike the `shared` ticker which drives visual animations and rendering which may want to be paused.\n *\n * The property {@link PIXI.Ticker#autoStart} is set to `true` for this instance.\n *\n * @member {PIXI.Ticker}\n * @static\n */\n get: function () {\n if (!Ticker._system) {\n var system = Ticker._system = new Ticker();\n system.autoStart = true;\n system._protected = true;\n }\n return Ticker._system;\n },\n enumerable: false,\n configurable: true\n });\n return Ticker;\n}());\n\n/**\n * Middleware for for Application Ticker.\n *\n * @example\n * import {TickerPlugin} from '@pixi/ticker';\n * import {Application} from '@pixi/app';\n * Application.registerPlugin(TickerPlugin);\n *\n * @class\n * @memberof PIXI\n */\nvar TickerPlugin = /** @class */ (function () {\n function TickerPlugin() {\n }\n /**\n * Initialize the plugin with scope of application instance\n *\n * @static\n * @private\n * @param {object} [options] - See application options\n */\n TickerPlugin.init = function (options) {\n var _this = this;\n // Set default\n options = Object.assign({\n autoStart: true,\n sharedTicker: false,\n }, options);\n // Create ticker setter\n Object.defineProperty(this, 'ticker', {\n set: function (ticker) {\n if (this._ticker) {\n this._ticker.remove(this.render, this);\n }\n this._ticker = ticker;\n if (ticker) {\n ticker.add(this.render, this, UPDATE_PRIORITY.LOW);\n }\n },\n get: function () {\n return this._ticker;\n },\n });\n /**\n * Convenience method for stopping the render.\n *\n * @method\n * @memberof PIXI.Application\n * @instance\n */\n this.stop = function () {\n _this._ticker.stop();\n };\n /**\n * Convenience method for starting the render.\n *\n * @method\n * @memberof PIXI.Application\n * @instance\n */\n this.start = function () {\n _this._ticker.start();\n };\n /**\n * Internal reference to the ticker.\n *\n * @type {PIXI.Ticker}\n * @name _ticker\n * @memberof PIXI.Application#\n * @private\n */\n this._ticker = null;\n /**\n * Ticker for doing render updates.\n *\n * @type {PIXI.Ticker}\n * @name ticker\n * @memberof PIXI.Application#\n * @default PIXI.Ticker.shared\n */\n this.ticker = options.sharedTicker ? Ticker.shared : new Ticker();\n // Start the rendering\n if (options.autoStart) {\n this.start();\n }\n };\n /**\n * Clean up the ticker, scoped to application.\n *\n * @static\n * @private\n */\n TickerPlugin.destroy = function () {\n if (this._ticker) {\n var oldTicker = this._ticker;\n this.ticker = null;\n oldTicker.destroy();\n }\n };\n return TickerPlugin;\n}());\n\nexport { Ticker, TickerPlugin, UPDATE_PRIORITY };\n//# sourceMappingURL=ticker.js.map\n","/*!\n * @pixi/utils - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/utils is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nexport { isMobile } from '@pixi/settings';\nexport { default as EventEmitter } from 'eventemitter3';\nexport { default as earcut } from 'earcut';\nimport { parse, format, resolve } from 'url';\nimport { BLEND_MODES } from '@pixi/constants';\n\n/**\n * This file contains redeclared types for Node `url` and `querystring` modules. These modules\n * don't provide their own typings but instead are a part of the full Node typings. The purpose of\n * this file is to redeclare the required types to avoid having the whole Node types as a\n * dependency.\n */\nvar url = {\n parse: parse,\n format: format,\n resolve: resolve,\n};\n\n/**\n * The prefix that denotes a URL is for a retina asset.\n *\n * @static\n * @name RETINA_PREFIX\n * @memberof PIXI.settings\n * @type {RegExp}\n * @default /@([0-9\\.]+)x/\n * @example `@2x`\n */\nsettings.RETINA_PREFIX = /@([0-9\\.]+)x/;\n/**\n * Should the `failIfMajorPerformanceCaveat` flag be enabled as a context option used in the `isWebGLSupported` function.\n * If set to true, a WebGL renderer can fail to be created if the browser thinks there could be performance issues when\n * using WebGL.\n *\n * In PixiJS v6 this has changed from true to false by default, to allow WebGL to work in as many scenarios as possible.\n * However, some users may have a poor experience, for example, if a user has a gpu or driver version blacklisted by the\n * browser.\n *\n * If your application requires high performance rendering, you may wish to set this to false.\n * We recommend one of two options if you decide to set this flag to false:\n *\n * 1: Use the `pixi.js-legacy` package, which includes a Canvas renderer as a fallback in case high performance WebGL is\n * not supported.\n *\n * 2: Call `isWebGLSupported` (which if found in the PIXI.utils package) in your code before attempting to create a PixiJS\n * renderer, and show an error message to the user if the function returns false, explaining that their device & browser\n * combination does not support high performance WebGL.\n * This is a much better strategy than trying to create a PixiJS renderer and finding it then fails.\n *\n * @static\n * @name FAIL_IF_MAJOR_PERFORMANCE_CAVEAT\n * @memberof PIXI.settings\n * @type {boolean}\n * @default false\n */\nsettings.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT = false;\n\nvar saidHello = false;\nvar VERSION = '6.3.0';\n/**\n * Skips the hello message of renderers that are created after this is run.\n *\n * @function skipHello\n * @memberof PIXI.utils\n */\nfunction skipHello() {\n saidHello = true;\n}\n/**\n * Logs out the version and renderer information for this running instance of PIXI.\n * If you don't want to see this message you can run `PIXI.utils.skipHello()` before\n * creating your renderer. Keep in mind that doing that will forever make you a jerk face.\n *\n * @static\n * @function sayHello\n * @memberof PIXI.utils\n * @param {string} type - The string renderer type to log.\n */\nfunction sayHello(type) {\n var _a;\n if (saidHello) {\n return;\n }\n if (navigator.userAgent.toLowerCase().indexOf('chrome') > -1) {\n var args = [\n \"\\n %c %c %c PixiJS \" + VERSION + \" - \\u2730 \" + type + \" \\u2730 %c %c http://www.pixijs.com/ %c %c \\u2665%c\\u2665%c\\u2665 \\n\\n\",\n 'background: #ff66a5; padding:5px 0;',\n 'background: #ff66a5; padding:5px 0;',\n 'color: #ff66a5; background: #030307; padding:5px 0;',\n 'background: #ff66a5; padding:5px 0;',\n 'background: #ffc3dc; padding:5px 0;',\n 'background: #ff66a5; padding:5px 0;',\n 'color: #ff2424; background: #fff; padding:5px 0;',\n 'color: #ff2424; background: #fff; padding:5px 0;',\n 'color: #ff2424; background: #fff; padding:5px 0;' ];\n (_a = globalThis.console).log.apply(_a, args);\n }\n else if (globalThis.console) {\n globalThis.console.log(\"PixiJS \" + VERSION + \" - \" + type + \" - http://www.pixijs.com/\");\n }\n saidHello = true;\n}\n\nvar supported;\n/**\n * Helper for checking for WebGL support.\n *\n * @memberof PIXI.utils\n * @function isWebGLSupported\n * @return {boolean} Is WebGL supported.\n */\nfunction isWebGLSupported() {\n if (typeof supported === 'undefined') {\n supported = (function supported() {\n var contextOptions = {\n stencil: true,\n failIfMajorPerformanceCaveat: settings.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT,\n };\n try {\n if (!globalThis.WebGLRenderingContext) {\n return false;\n }\n var canvas = document.createElement('canvas');\n var gl = (canvas.getContext('webgl', contextOptions)\n || canvas.getContext('experimental-webgl', contextOptions));\n var success = !!(gl && gl.getContextAttributes().stencil);\n if (gl) {\n var loseContext = gl.getExtension('WEBGL_lose_context');\n if (loseContext) {\n loseContext.loseContext();\n }\n }\n gl = null;\n return success;\n }\n catch (e) {\n return false;\n }\n })();\n }\n return supported;\n}\n\nvar aliceblue = \"#f0f8ff\";\nvar antiquewhite = \"#faebd7\";\nvar aqua = \"#00ffff\";\nvar aquamarine = \"#7fffd4\";\nvar azure = \"#f0ffff\";\nvar beige = \"#f5f5dc\";\nvar bisque = \"#ffe4c4\";\nvar black = \"#000000\";\nvar blanchedalmond = \"#ffebcd\";\nvar blue = \"#0000ff\";\nvar blueviolet = \"#8a2be2\";\nvar brown = \"#a52a2a\";\nvar burlywood = \"#deb887\";\nvar cadetblue = \"#5f9ea0\";\nvar chartreuse = \"#7fff00\";\nvar chocolate = \"#d2691e\";\nvar coral = \"#ff7f50\";\nvar cornflowerblue = \"#6495ed\";\nvar cornsilk = \"#fff8dc\";\nvar crimson = \"#dc143c\";\nvar cyan = \"#00ffff\";\nvar darkblue = \"#00008b\";\nvar darkcyan = \"#008b8b\";\nvar darkgoldenrod = \"#b8860b\";\nvar darkgray = \"#a9a9a9\";\nvar darkgreen = \"#006400\";\nvar darkgrey = \"#a9a9a9\";\nvar darkkhaki = \"#bdb76b\";\nvar darkmagenta = \"#8b008b\";\nvar darkolivegreen = \"#556b2f\";\nvar darkorange = \"#ff8c00\";\nvar darkorchid = \"#9932cc\";\nvar darkred = \"#8b0000\";\nvar darksalmon = \"#e9967a\";\nvar darkseagreen = \"#8fbc8f\";\nvar darkslateblue = \"#483d8b\";\nvar darkslategray = \"#2f4f4f\";\nvar darkslategrey = \"#2f4f4f\";\nvar darkturquoise = \"#00ced1\";\nvar darkviolet = \"#9400d3\";\nvar deeppink = \"#ff1493\";\nvar deepskyblue = \"#00bfff\";\nvar dimgray = \"#696969\";\nvar dimgrey = \"#696969\";\nvar dodgerblue = \"#1e90ff\";\nvar firebrick = \"#b22222\";\nvar floralwhite = \"#fffaf0\";\nvar forestgreen = \"#228b22\";\nvar fuchsia = \"#ff00ff\";\nvar gainsboro = \"#dcdcdc\";\nvar ghostwhite = \"#f8f8ff\";\nvar goldenrod = \"#daa520\";\nvar gold = \"#ffd700\";\nvar gray = \"#808080\";\nvar green = \"#008000\";\nvar greenyellow = \"#adff2f\";\nvar grey = \"#808080\";\nvar honeydew = \"#f0fff0\";\nvar hotpink = \"#ff69b4\";\nvar indianred = \"#cd5c5c\";\nvar indigo = \"#4b0082\";\nvar ivory = \"#fffff0\";\nvar khaki = \"#f0e68c\";\nvar lavenderblush = \"#fff0f5\";\nvar lavender = \"#e6e6fa\";\nvar lawngreen = \"#7cfc00\";\nvar lemonchiffon = \"#fffacd\";\nvar lightblue = \"#add8e6\";\nvar lightcoral = \"#f08080\";\nvar lightcyan = \"#e0ffff\";\nvar lightgoldenrodyellow = \"#fafad2\";\nvar lightgray = \"#d3d3d3\";\nvar lightgreen = \"#90ee90\";\nvar lightgrey = \"#d3d3d3\";\nvar lightpink = \"#ffb6c1\";\nvar lightsalmon = \"#ffa07a\";\nvar lightseagreen = \"#20b2aa\";\nvar lightskyblue = \"#87cefa\";\nvar lightslategray = \"#778899\";\nvar lightslategrey = \"#778899\";\nvar lightsteelblue = \"#b0c4de\";\nvar lightyellow = \"#ffffe0\";\nvar lime = \"#00ff00\";\nvar limegreen = \"#32cd32\";\nvar linen = \"#faf0e6\";\nvar magenta = \"#ff00ff\";\nvar maroon = \"#800000\";\nvar mediumaquamarine = \"#66cdaa\";\nvar mediumblue = \"#0000cd\";\nvar mediumorchid = \"#ba55d3\";\nvar mediumpurple = \"#9370db\";\nvar mediumseagreen = \"#3cb371\";\nvar mediumslateblue = \"#7b68ee\";\nvar mediumspringgreen = \"#00fa9a\";\nvar mediumturquoise = \"#48d1cc\";\nvar mediumvioletred = \"#c71585\";\nvar midnightblue = \"#191970\";\nvar mintcream = \"#f5fffa\";\nvar mistyrose = \"#ffe4e1\";\nvar moccasin = \"#ffe4b5\";\nvar navajowhite = \"#ffdead\";\nvar navy = \"#000080\";\nvar oldlace = \"#fdf5e6\";\nvar olive = \"#808000\";\nvar olivedrab = \"#6b8e23\";\nvar orange = \"#ffa500\";\nvar orangered = \"#ff4500\";\nvar orchid = \"#da70d6\";\nvar palegoldenrod = \"#eee8aa\";\nvar palegreen = \"#98fb98\";\nvar paleturquoise = \"#afeeee\";\nvar palevioletred = \"#db7093\";\nvar papayawhip = \"#ffefd5\";\nvar peachpuff = \"#ffdab9\";\nvar peru = \"#cd853f\";\nvar pink = \"#ffc0cb\";\nvar plum = \"#dda0dd\";\nvar powderblue = \"#b0e0e6\";\nvar purple = \"#800080\";\nvar rebeccapurple = \"#663399\";\nvar red = \"#ff0000\";\nvar rosybrown = \"#bc8f8f\";\nvar royalblue = \"#4169e1\";\nvar saddlebrown = \"#8b4513\";\nvar salmon = \"#fa8072\";\nvar sandybrown = \"#f4a460\";\nvar seagreen = \"#2e8b57\";\nvar seashell = \"#fff5ee\";\nvar sienna = \"#a0522d\";\nvar silver = \"#c0c0c0\";\nvar skyblue = \"#87ceeb\";\nvar slateblue = \"#6a5acd\";\nvar slategray = \"#708090\";\nvar slategrey = \"#708090\";\nvar snow = \"#fffafa\";\nvar springgreen = \"#00ff7f\";\nvar steelblue = \"#4682b4\";\nvar tan = \"#d2b48c\";\nvar teal = \"#008080\";\nvar thistle = \"#d8bfd8\";\nvar tomato = \"#ff6347\";\nvar turquoise = \"#40e0d0\";\nvar violet = \"#ee82ee\";\nvar wheat = \"#f5deb3\";\nvar white = \"#ffffff\";\nvar whitesmoke = \"#f5f5f5\";\nvar yellow = \"#ffff00\";\nvar yellowgreen = \"#9acd32\";\nvar cssColorNames = {\n\taliceblue: aliceblue,\n\tantiquewhite: antiquewhite,\n\taqua: aqua,\n\taquamarine: aquamarine,\n\tazure: azure,\n\tbeige: beige,\n\tbisque: bisque,\n\tblack: black,\n\tblanchedalmond: blanchedalmond,\n\tblue: blue,\n\tblueviolet: blueviolet,\n\tbrown: brown,\n\tburlywood: burlywood,\n\tcadetblue: cadetblue,\n\tchartreuse: chartreuse,\n\tchocolate: chocolate,\n\tcoral: coral,\n\tcornflowerblue: cornflowerblue,\n\tcornsilk: cornsilk,\n\tcrimson: crimson,\n\tcyan: cyan,\n\tdarkblue: darkblue,\n\tdarkcyan: darkcyan,\n\tdarkgoldenrod: darkgoldenrod,\n\tdarkgray: darkgray,\n\tdarkgreen: darkgreen,\n\tdarkgrey: darkgrey,\n\tdarkkhaki: darkkhaki,\n\tdarkmagenta: darkmagenta,\n\tdarkolivegreen: darkolivegreen,\n\tdarkorange: darkorange,\n\tdarkorchid: darkorchid,\n\tdarkred: darkred,\n\tdarksalmon: darksalmon,\n\tdarkseagreen: darkseagreen,\n\tdarkslateblue: darkslateblue,\n\tdarkslategray: darkslategray,\n\tdarkslategrey: darkslategrey,\n\tdarkturquoise: darkturquoise,\n\tdarkviolet: darkviolet,\n\tdeeppink: deeppink,\n\tdeepskyblue: deepskyblue,\n\tdimgray: dimgray,\n\tdimgrey: dimgrey,\n\tdodgerblue: dodgerblue,\n\tfirebrick: firebrick,\n\tfloralwhite: floralwhite,\n\tforestgreen: forestgreen,\n\tfuchsia: fuchsia,\n\tgainsboro: gainsboro,\n\tghostwhite: ghostwhite,\n\tgoldenrod: goldenrod,\n\tgold: gold,\n\tgray: gray,\n\tgreen: green,\n\tgreenyellow: greenyellow,\n\tgrey: grey,\n\thoneydew: honeydew,\n\thotpink: hotpink,\n\tindianred: indianred,\n\tindigo: indigo,\n\tivory: ivory,\n\tkhaki: khaki,\n\tlavenderblush: lavenderblush,\n\tlavender: lavender,\n\tlawngreen: lawngreen,\n\tlemonchiffon: lemonchiffon,\n\tlightblue: lightblue,\n\tlightcoral: lightcoral,\n\tlightcyan: lightcyan,\n\tlightgoldenrodyellow: lightgoldenrodyellow,\n\tlightgray: lightgray,\n\tlightgreen: lightgreen,\n\tlightgrey: lightgrey,\n\tlightpink: lightpink,\n\tlightsalmon: lightsalmon,\n\tlightseagreen: lightseagreen,\n\tlightskyblue: lightskyblue,\n\tlightslategray: lightslategray,\n\tlightslategrey: lightslategrey,\n\tlightsteelblue: lightsteelblue,\n\tlightyellow: lightyellow,\n\tlime: lime,\n\tlimegreen: limegreen,\n\tlinen: linen,\n\tmagenta: magenta,\n\tmaroon: maroon,\n\tmediumaquamarine: mediumaquamarine,\n\tmediumblue: mediumblue,\n\tmediumorchid: mediumorchid,\n\tmediumpurple: mediumpurple,\n\tmediumseagreen: mediumseagreen,\n\tmediumslateblue: mediumslateblue,\n\tmediumspringgreen: mediumspringgreen,\n\tmediumturquoise: mediumturquoise,\n\tmediumvioletred: mediumvioletred,\n\tmidnightblue: midnightblue,\n\tmintcream: mintcream,\n\tmistyrose: mistyrose,\n\tmoccasin: moccasin,\n\tnavajowhite: navajowhite,\n\tnavy: navy,\n\toldlace: oldlace,\n\tolive: olive,\n\tolivedrab: olivedrab,\n\torange: orange,\n\torangered: orangered,\n\torchid: orchid,\n\tpalegoldenrod: palegoldenrod,\n\tpalegreen: palegreen,\n\tpaleturquoise: paleturquoise,\n\tpalevioletred: palevioletred,\n\tpapayawhip: papayawhip,\n\tpeachpuff: peachpuff,\n\tperu: peru,\n\tpink: pink,\n\tplum: plum,\n\tpowderblue: powderblue,\n\tpurple: purple,\n\trebeccapurple: rebeccapurple,\n\tred: red,\n\trosybrown: rosybrown,\n\troyalblue: royalblue,\n\tsaddlebrown: saddlebrown,\n\tsalmon: salmon,\n\tsandybrown: sandybrown,\n\tseagreen: seagreen,\n\tseashell: seashell,\n\tsienna: sienna,\n\tsilver: silver,\n\tskyblue: skyblue,\n\tslateblue: slateblue,\n\tslategray: slategray,\n\tslategrey: slategrey,\n\tsnow: snow,\n\tspringgreen: springgreen,\n\tsteelblue: steelblue,\n\ttan: tan,\n\tteal: teal,\n\tthistle: thistle,\n\ttomato: tomato,\n\tturquoise: turquoise,\n\tviolet: violet,\n\twheat: wheat,\n\twhite: white,\n\twhitesmoke: whitesmoke,\n\tyellow: yellow,\n\tyellowgreen: yellowgreen\n};\n\n/**\n * Converts a hexadecimal color number to an [R, G, B] array of normalized floats (numbers from 0.0 to 1.0).\n *\n * @example\n * PIXI.utils.hex2rgb(0xffffff); // returns [1, 1, 1]\n * @memberof PIXI.utils\n * @function hex2rgb\n * @param {number} hex - The hexadecimal number to convert\n * @param {number[]} [out=[]] - If supplied, this array will be used rather than returning a new one\n * @return {number[]} An array representing the [R, G, B] of the color where all values are floats.\n */\nfunction hex2rgb(hex, out) {\n if (out === void 0) { out = []; }\n out[0] = ((hex >> 16) & 0xFF) / 255;\n out[1] = ((hex >> 8) & 0xFF) / 255;\n out[2] = (hex & 0xFF) / 255;\n return out;\n}\n/**\n * Converts a hexadecimal color number to a string.\n *\n * @example\n * PIXI.utils.hex2string(0xffffff); // returns \"#ffffff\"\n * @memberof PIXI.utils\n * @function hex2string\n * @param {number} hex - Number in hex (e.g., `0xffffff`)\n * @return {string} The string color (e.g., `\"#ffffff\"`).\n */\nfunction hex2string(hex) {\n var hexString = hex.toString(16);\n hexString = '000000'.substring(0, 6 - hexString.length) + hexString;\n return \"#\" + hexString;\n}\n/**\n * Converts a string to a hexadecimal color number.\n * It can handle:\n * hex strings starting with #: \"#ffffff\"\n * hex strings starting with 0x: \"0xffffff\"\n * hex strings without prefix: \"ffffff\"\n * css colors: \"black\"\n *\n * @example\n * PIXI.utils.string2hex(\"#ffffff\"); // returns 0xffffff\n * @memberof PIXI.utils\n * @function string2hex\n * @param {string} string - The string color (e.g., `\"#ffffff\"`)\n * @return {number} Number in hexadecimal.\n */\nfunction string2hex(string) {\n if (typeof string === 'string') {\n string = cssColorNames[string.toLowerCase()] || string;\n if (string[0] === '#') {\n string = string.slice(1);\n }\n }\n return parseInt(string, 16);\n}\n/**\n * Converts a color as an [R, G, B] array of normalized floats to a hexadecimal number.\n *\n * @example\n * PIXI.utils.rgb2hex([1, 1, 1]); // returns 0xffffff\n * @memberof PIXI.utils\n * @function rgb2hex\n * @param {number[]} rgb - Array of numbers where all values are normalized floats from 0.0 to 1.0.\n * @return {number} Number in hexadecimal.\n */\nfunction rgb2hex(rgb) {\n return (((rgb[0] * 255) << 16) + ((rgb[1] * 255) << 8) + (rgb[2] * 255 | 0));\n}\n\n/**\n * Corrects PixiJS blend, takes premultiplied alpha into account\n *\n * @memberof PIXI.utils\n * @function mapPremultipliedBlendModes\n * @private\n * @return {Array<number[]>} Mapped modes.\n */\nfunction mapPremultipliedBlendModes() {\n var pm = [];\n var npm = [];\n for (var i = 0; i < 32; i++) {\n pm[i] = i;\n npm[i] = i;\n }\n pm[BLEND_MODES.NORMAL_NPM] = BLEND_MODES.NORMAL;\n pm[BLEND_MODES.ADD_NPM] = BLEND_MODES.ADD;\n pm[BLEND_MODES.SCREEN_NPM] = BLEND_MODES.SCREEN;\n npm[BLEND_MODES.NORMAL] = BLEND_MODES.NORMAL_NPM;\n npm[BLEND_MODES.ADD] = BLEND_MODES.ADD_NPM;\n npm[BLEND_MODES.SCREEN] = BLEND_MODES.SCREEN_NPM;\n var array = [];\n array.push(npm);\n array.push(pm);\n return array;\n}\n/**\n * maps premultiply flag and blendMode to adjusted blendMode\n * @memberof PIXI.utils\n * @const premultiplyBlendMode\n * @type {Array<number[]>}\n */\nvar premultiplyBlendMode = mapPremultipliedBlendModes();\n/**\n * changes blendMode according to texture format\n *\n * @memberof PIXI.utils\n * @function correctBlendMode\n * @param {number} blendMode - supposed blend mode\n * @param {boolean} premultiplied - whether source is premultiplied\n * @returns {number} true blend mode for this texture\n */\nfunction correctBlendMode(blendMode, premultiplied) {\n return premultiplyBlendMode[premultiplied ? 1 : 0][blendMode];\n}\n/**\n * combines rgb and alpha to out array\n *\n * @memberof PIXI.utils\n * @function premultiplyRgba\n * @param {Float32Array|number[]} rgb - input rgb\n * @param {number} alpha - alpha param\n * @param {Float32Array} [out] - output\n * @param {boolean} [premultiply=true] - do premultiply it\n * @returns {Float32Array} vec4 rgba\n */\nfunction premultiplyRgba(rgb, alpha, out, premultiply) {\n out = out || new Float32Array(4);\n if (premultiply || premultiply === undefined) {\n out[0] = rgb[0] * alpha;\n out[1] = rgb[1] * alpha;\n out[2] = rgb[2] * alpha;\n }\n else {\n out[0] = rgb[0];\n out[1] = rgb[1];\n out[2] = rgb[2];\n }\n out[3] = alpha;\n return out;\n}\n/**\n * premultiplies tint\n *\n * @memberof PIXI.utils\n * @function premultiplyTint\n * @param {number} tint - integer RGB\n * @param {number} alpha - floating point alpha (0.0-1.0)\n * @returns {number} tint multiplied by alpha\n */\nfunction premultiplyTint(tint, alpha) {\n if (alpha === 1.0) {\n return (alpha * 255 << 24) + tint;\n }\n if (alpha === 0.0) {\n return 0;\n }\n var R = ((tint >> 16) & 0xFF);\n var G = ((tint >> 8) & 0xFF);\n var B = (tint & 0xFF);\n R = ((R * alpha) + 0.5) | 0;\n G = ((G * alpha) + 0.5) | 0;\n B = ((B * alpha) + 0.5) | 0;\n return (alpha * 255 << 24) + (R << 16) + (G << 8) + B;\n}\n/**\n * converts integer tint and float alpha to vec4 form, premultiplies by default\n *\n * @memberof PIXI.utils\n * @function premultiplyTintToRgba\n * @param {number} tint - input tint\n * @param {number} alpha - alpha param\n * @param {Float32Array} [out] - output\n * @param {boolean} [premultiply=true] - do premultiply it\n * @returns {Float32Array} vec4 rgba\n */\nfunction premultiplyTintToRgba(tint, alpha, out, premultiply) {\n out = out || new Float32Array(4);\n out[0] = ((tint >> 16) & 0xFF) / 255.0;\n out[1] = ((tint >> 8) & 0xFF) / 255.0;\n out[2] = (tint & 0xFF) / 255.0;\n if (premultiply || premultiply === undefined) {\n out[0] *= alpha;\n out[1] *= alpha;\n out[2] *= alpha;\n }\n out[3] = alpha;\n return out;\n}\n\n/**\n * Generic Mask Stack data structure\n *\n * @memberof PIXI.utils\n * @function createIndicesForQuads\n * @param {number} size - Number of quads\n * @param {Uint16Array|Uint32Array} [outBuffer] - Buffer for output, length has to be `6 * size`\n * @return {Uint16Array|Uint32Array} - Resulting index buffer\n */\nfunction createIndicesForQuads(size, outBuffer) {\n if (outBuffer === void 0) { outBuffer = null; }\n // the total number of indices in our array, there are 6 points per quad.\n var totalIndices = size * 6;\n outBuffer = outBuffer || new Uint16Array(totalIndices);\n if (outBuffer.length !== totalIndices) {\n throw new Error(\"Out buffer length is incorrect, got \" + outBuffer.length + \" and expected \" + totalIndices);\n }\n // fill the indices with the quads to draw\n for (var i = 0, j = 0; i < totalIndices; i += 6, j += 4) {\n outBuffer[i + 0] = j + 0;\n outBuffer[i + 1] = j + 1;\n outBuffer[i + 2] = j + 2;\n outBuffer[i + 3] = j + 0;\n outBuffer[i + 4] = j + 2;\n outBuffer[i + 5] = j + 3;\n }\n return outBuffer;\n}\n\nfunction getBufferType(array) {\n if (array.BYTES_PER_ELEMENT === 4) {\n if (array instanceof Float32Array) {\n return 'Float32Array';\n }\n else if (array instanceof Uint32Array) {\n return 'Uint32Array';\n }\n return 'Int32Array';\n }\n else if (array.BYTES_PER_ELEMENT === 2) {\n if (array instanceof Uint16Array) {\n return 'Uint16Array';\n }\n }\n else if (array.BYTES_PER_ELEMENT === 1) {\n if (array instanceof Uint8Array) {\n return 'Uint8Array';\n }\n }\n // TODO map out the rest of the array elements!\n return null;\n}\n\n/* eslint-disable object-shorthand */\nvar map = { Float32Array: Float32Array, Uint32Array: Uint32Array, Int32Array: Int32Array, Uint8Array: Uint8Array };\nfunction interleaveTypedArrays(arrays, sizes) {\n var outSize = 0;\n var stride = 0;\n var views = {};\n for (var i = 0; i < arrays.length; i++) {\n stride += sizes[i];\n outSize += arrays[i].length;\n }\n var buffer = new ArrayBuffer(outSize * 4);\n var out = null;\n var littleOffset = 0;\n for (var i = 0; i < arrays.length; i++) {\n var size = sizes[i];\n var array = arrays[i];\n /*\n @todo This is unsafe casting but consistent with how the code worked previously. Should it stay this way\n or should and `getBufferTypeUnsafe` function be exposed that throws an Error if unsupported type is passed?\n */\n var type = getBufferType(array);\n if (!views[type]) {\n views[type] = new map[type](buffer);\n }\n out = views[type];\n for (var j = 0; j < array.length; j++) {\n var indexStart = ((j / size | 0) * stride) + littleOffset;\n var index = j % size;\n out[indexStart + index] = array[j];\n }\n littleOffset += size;\n }\n return new Float32Array(buffer);\n}\n\n// Taken from the bit-twiddle package\n/**\n * Rounds to next power of two.\n *\n * @function nextPow2\n * @memberof PIXI.utils\n * @param {number} v - input value\n * @return {number}\n */\nfunction nextPow2(v) {\n v += v === 0 ? 1 : 0;\n --v;\n v |= v >>> 1;\n v |= v >>> 2;\n v |= v >>> 4;\n v |= v >>> 8;\n v |= v >>> 16;\n return v + 1;\n}\n/**\n * Checks if a number is a power of two.\n *\n * @function isPow2\n * @memberof PIXI.utils\n * @param {number} v - input value\n * @return {boolean} `true` if value is power of two\n */\nfunction isPow2(v) {\n return !(v & (v - 1)) && (!!v);\n}\n/**\n * Computes ceil of log base 2\n *\n * @function log2\n * @memberof PIXI.utils\n * @param {number} v - input value\n * @return {number} logarithm base 2\n */\nfunction log2(v) {\n var r = (v > 0xFFFF ? 1 : 0) << 4;\n v >>>= r;\n var shift = (v > 0xFF ? 1 : 0) << 3;\n v >>>= shift;\n r |= shift;\n shift = (v > 0xF ? 1 : 0) << 2;\n v >>>= shift;\n r |= shift;\n shift = (v > 0x3 ? 1 : 0) << 1;\n v >>>= shift;\n r |= shift;\n return r | (v >> 1);\n}\n\n/**\n * Remove items from a javascript array without generating garbage\n *\n * @function removeItems\n * @memberof PIXI.utils\n * @param {Array<any>} arr - Array to remove elements from\n * @param {number} startIdx - starting index\n * @param {number} removeCount - how many to remove\n */\nfunction removeItems(arr, startIdx, removeCount) {\n var length = arr.length;\n var i;\n if (startIdx >= length || removeCount === 0) {\n return;\n }\n removeCount = (startIdx + removeCount > length ? length - startIdx : removeCount);\n var len = length - removeCount;\n for (i = startIdx; i < len; ++i) {\n arr[i] = arr[i + removeCount];\n }\n arr.length = len;\n}\n\n/**\n * Returns sign of number\n *\n * @memberof PIXI.utils\n * @function sign\n * @param {number} n - the number to check the sign of\n * @returns {number} 0 if `n` is 0, -1 if `n` is negative, 1 if `n` is positive\n */\nfunction sign(n) {\n if (n === 0)\n { return 0; }\n return n < 0 ? -1 : 1;\n}\n\nvar nextUid = 0;\n/**\n * Gets the next unique identifier\n *\n * @memberof PIXI.utils\n * @function uid\n * @return {number} The next unique identifier to use.\n */\nfunction uid() {\n return ++nextUid;\n}\n\n// A map of warning messages already fired\nvar warnings = {};\n/**\n * Helper for warning developers about deprecated features & settings.\n * A stack track for warnings is given; useful for tracking-down where\n * deprecated methods/properties/classes are being used within the code.\n *\n * @memberof PIXI.utils\n * @function deprecation\n * @param {string} version - The version where the feature became deprecated\n * @param {string} message - Message should include what is deprecated, where, and the new solution\n * @param {number} [ignoreDepth=3] - The number of steps to ignore at the top of the error stack\n * this is mostly to ignore internal deprecation calls.\n */\nfunction deprecation(version, message, ignoreDepth) {\n if (ignoreDepth === void 0) { ignoreDepth = 3; }\n // Ignore duplicat\n if (warnings[message]) {\n return;\n }\n /* eslint-disable no-console */\n var stack = new Error().stack;\n // Handle IE < 10 and Safari < 6\n if (typeof stack === 'undefined') {\n console.warn('PixiJS Deprecation Warning: ', message + \"\\nDeprecated since v\" + version);\n }\n else {\n // chop off the stack trace which includes PixiJS internal calls\n stack = stack.split('\\n').splice(ignoreDepth).join('\\n');\n if (console.groupCollapsed) {\n console.groupCollapsed('%cPixiJS Deprecation Warning: %c%s', 'color:#614108;background:#fffbe6', 'font-weight:normal;color:#614108;background:#fffbe6', message + \"\\nDeprecated since v\" + version);\n console.warn(stack);\n console.groupEnd();\n }\n else {\n console.warn('PixiJS Deprecation Warning: ', message + \"\\nDeprecated since v\" + version);\n console.warn(stack);\n }\n }\n /* eslint-enable no-console */\n warnings[message] = true;\n}\n\n/**\n * @todo Describe property usage\n *\n * @static\n * @name ProgramCache\n * @memberof PIXI.utils\n * @type {Object}\n */\nvar ProgramCache = {};\n/**\n * @todo Describe property usage\n *\n * @static\n * @name TextureCache\n * @memberof PIXI.utils\n * @type {Object}\n */\nvar TextureCache = Object.create(null);\n/**\n * @todo Describe property usage\n *\n * @static\n * @name BaseTextureCache\n * @memberof PIXI.utils\n * @type {Object}\n */\nvar BaseTextureCache = Object.create(null);\n/**\n * Destroys all texture in the cache\n *\n * @memberof PIXI.utils\n * @function destroyTextureCache\n */\nfunction destroyTextureCache() {\n var key;\n for (key in TextureCache) {\n TextureCache[key].destroy();\n }\n for (key in BaseTextureCache) {\n BaseTextureCache[key].destroy();\n }\n}\n/**\n * Removes all textures from cache, but does not destroy them\n *\n * @memberof PIXI.utils\n * @function clearTextureCache\n */\nfunction clearTextureCache() {\n var key;\n for (key in TextureCache) {\n delete TextureCache[key];\n }\n for (key in BaseTextureCache) {\n delete BaseTextureCache[key];\n }\n}\n\n/**\n * Creates a Canvas element of the given size to be used as a target for rendering to.\n *\n * @class\n * @memberof PIXI.utils\n */\nvar CanvasRenderTarget = /** @class */ (function () {\n /**\n * @param width - the width for the newly created canvas\n * @param height - the height for the newly created canvas\n * @param {number} [resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the canvas\n */\n function CanvasRenderTarget(width, height, resolution) {\n this.canvas = document.createElement('canvas');\n this.context = this.canvas.getContext('2d');\n this.resolution = resolution || settings.RESOLUTION;\n this.resize(width, height);\n }\n /**\n * Clears the canvas that was created by the CanvasRenderTarget class.\n *\n * @private\n */\n CanvasRenderTarget.prototype.clear = function () {\n this.context.setTransform(1, 0, 0, 1, 0, 0);\n this.context.clearRect(0, 0, this.canvas.width, this.canvas.height);\n };\n /**\n * Resizes the canvas to the specified width and height.\n *\n * @param desiredWidth - the desired width of the canvas\n * @param desiredHeight - the desired height of the canvas\n */\n CanvasRenderTarget.prototype.resize = function (desiredWidth, desiredHeight) {\n this.canvas.width = Math.round(desiredWidth * this.resolution);\n this.canvas.height = Math.round(desiredHeight * this.resolution);\n };\n /** Destroys this canvas. */\n CanvasRenderTarget.prototype.destroy = function () {\n this.context = null;\n this.canvas = null;\n };\n Object.defineProperty(CanvasRenderTarget.prototype, \"width\", {\n /**\n * The width of the canvas buffer in pixels.\n *\n * @member {number}\n */\n get: function () {\n return this.canvas.width;\n },\n set: function (val) {\n this.canvas.width = Math.round(val);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(CanvasRenderTarget.prototype, \"height\", {\n /**\n * The height of the canvas buffer in pixels.\n *\n * @member {number}\n */\n get: function () {\n return this.canvas.height;\n },\n set: function (val) {\n this.canvas.height = Math.round(val);\n },\n enumerable: false,\n configurable: true\n });\n return CanvasRenderTarget;\n}());\n\n/**\n * Trim transparent borders from a canvas\n *\n * @memberof PIXI.utils\n * @function trimCanvas\n * @param {HTMLCanvasElement} canvas - the canvas to trim\n * @returns {object} Trim data\n */\nfunction trimCanvas(canvas) {\n // https://gist.github.com/remy/784508\n var width = canvas.width;\n var height = canvas.height;\n var context = canvas.getContext('2d');\n var imageData = context.getImageData(0, 0, width, height);\n var pixels = imageData.data;\n var len = pixels.length;\n var bound = {\n top: null,\n left: null,\n right: null,\n bottom: null,\n };\n var data = null;\n var i;\n var x;\n var y;\n for (i = 0; i < len; i += 4) {\n if (pixels[i + 3] !== 0) {\n x = (i / 4) % width;\n y = ~~((i / 4) / width);\n if (bound.top === null) {\n bound.top = y;\n }\n if (bound.left === null) {\n bound.left = x;\n }\n else if (x < bound.left) {\n bound.left = x;\n }\n if (bound.right === null) {\n bound.right = x + 1;\n }\n else if (bound.right < x) {\n bound.right = x + 1;\n }\n if (bound.bottom === null) {\n bound.bottom = y;\n }\n else if (bound.bottom < y) {\n bound.bottom = y;\n }\n }\n }\n if (bound.top !== null) {\n width = bound.right - bound.left;\n height = bound.bottom - bound.top + 1;\n data = context.getImageData(bound.left, bound.top, width, height);\n }\n return {\n height: height,\n width: width,\n data: data,\n };\n}\n\n/**\n * Regexp for data URI.\n * Based on: {@link https://github.com/ragingwind/data-uri-regex}\n *\n * @static\n * @constant {RegExp|string} DATA_URI\n * @memberof PIXI\n * @example data:image/png;base64\n */\nvar DATA_URI = /^\\s*data:(?:([\\w-]+)\\/([\\w+.-]+))?(?:;charset=([\\w-]+))?(?:;(base64))?,(.*)/i;\n\n/**\n * @memberof PIXI.utils\n * @interface DecomposedDataUri\n */\n/**\n * type, eg. `image`\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} mediaType\n */\n/**\n * Sub type, eg. `png`\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} subType\n */\n/**\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} charset\n */\n/**\n * Data encoding, eg. `base64`\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} encoding\n */\n/**\n * The actual data\n * @memberof PIXI.utils.DecomposedDataUri#\n * @member {string} data\n */\n/**\n * Split a data URI into components. Returns undefined if\n * parameter `dataUri` is not a valid data URI.\n *\n * @memberof PIXI.utils\n * @function decomposeDataUri\n * @param {string} dataUri - the data URI to check\n * @return {PIXI.utils.DecomposedDataUri|undefined} The decomposed data uri or undefined\n */\nfunction decomposeDataUri(dataUri) {\n var dataUriMatch = DATA_URI.exec(dataUri);\n if (dataUriMatch) {\n return {\n mediaType: dataUriMatch[1] ? dataUriMatch[1].toLowerCase() : undefined,\n subType: dataUriMatch[2] ? dataUriMatch[2].toLowerCase() : undefined,\n charset: dataUriMatch[3] ? dataUriMatch[3].toLowerCase() : undefined,\n encoding: dataUriMatch[4] ? dataUriMatch[4].toLowerCase() : undefined,\n data: dataUriMatch[5],\n };\n }\n return undefined;\n}\n\nvar tempAnchor;\n/**\n * Sets the `crossOrigin` property for this resource based on if the url\n * for this resource is cross-origin. If crossOrigin was manually set, this\n * function does nothing.\n * Nipped from the resource loader!\n *\n * @ignore\n * @param {string} url - The url to test.\n * @param {object} [loc=window.location] - The location object to test against.\n * @return {string} The crossOrigin value to use (or empty string for none).\n */\nfunction determineCrossOrigin(url$1, loc) {\n if (loc === void 0) { loc = globalThis.location; }\n // data: and javascript: urls are considered same-origin\n if (url$1.indexOf('data:') === 0) {\n return '';\n }\n // default is window.location\n loc = loc || globalThis.location;\n if (!tempAnchor) {\n tempAnchor = document.createElement('a');\n }\n // let the browser determine the full href for the url of this resource and then\n // parse with the node url lib, we can't use the properties of the anchor element\n // because they don't work in IE9 :(\n tempAnchor.href = url$1;\n var parsedUrl = url.parse(tempAnchor.href);\n var samePort = (!parsedUrl.port && loc.port === '') || (parsedUrl.port === loc.port);\n // if cross origin\n if (parsedUrl.hostname !== loc.hostname || !samePort || parsedUrl.protocol !== loc.protocol) {\n return 'anonymous';\n }\n return '';\n}\n\n/**\n * get the resolution / device pixel ratio of an asset by looking for the prefix\n * used by spritesheets and image urls\n *\n * @memberof PIXI.utils\n * @function getResolutionOfUrl\n * @param {string} url - the image path\n * @param {number} [defaultValue=1] - the defaultValue if no filename prefix is set.\n * @return {number} resolution / device pixel ratio of an asset\n */\nfunction getResolutionOfUrl(url, defaultValue) {\n var resolution = settings.RETINA_PREFIX.exec(url);\n if (resolution) {\n return parseFloat(resolution[1]);\n }\n return defaultValue !== undefined ? defaultValue : 1;\n}\n\nexport { BaseTextureCache, CanvasRenderTarget, DATA_URI, ProgramCache, TextureCache, clearTextureCache, correctBlendMode, createIndicesForQuads, decomposeDataUri, deprecation, destroyTextureCache, determineCrossOrigin, getBufferType, getResolutionOfUrl, hex2rgb, hex2string, interleaveTypedArrays, isPow2, isWebGLSupported, log2, nextPow2, premultiplyBlendMode, premultiplyRgba, premultiplyTint, premultiplyTintToRgba, removeItems, rgb2hex, sayHello, sign, skipHello, string2hex, trimCanvas, uid, url };\n//# sourceMappingURL=utils.js.map\n","'use strict';\n\nvar has = Object.prototype.hasOwnProperty\n , prefix = '~';\n\n/**\n * Constructor to create a storage for our `EE` objects.\n * An `Events` instance is a plain object whose properties are event names.\n *\n * @constructor\n * @private\n */\nfunction Events() {}\n\n//\n// We try to not inherit from `Object.prototype`. In some engines creating an\n// instance in this way is faster than calling `Object.create(null)` directly.\n// If `Object.create(null)` is not supported we prefix the event names with a\n// character to make sure that the built-in object properties are not\n// overridden or used as an attack vector.\n//\nif (Object.create) {\n Events.prototype = Object.create(null);\n\n //\n // This hack is needed because the `__proto__` property is still inherited in\n // some old browsers like Android 4, iPhone 5.1, Opera 11 and Safari 5.\n //\n if (!new Events().__proto__) prefix = false;\n}\n\n/**\n * Representation of a single event listener.\n *\n * @param {Function} fn The listener function.\n * @param {*} context The context to invoke the listener with.\n * @param {Boolean} [once=false] Specify if the listener is a one-time listener.\n * @constructor\n * @private\n */\nfunction EE(fn, context, once) {\n this.fn = fn;\n this.context = context;\n this.once = once || false;\n}\n\n/**\n * Add a listener for a given event.\n *\n * @param {EventEmitter} emitter Reference to the `EventEmitter` instance.\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} context The context to invoke the listener with.\n * @param {Boolean} once Specify if the listener is a one-time listener.\n * @returns {EventEmitter}\n * @private\n */\nfunction addListener(emitter, event, fn, context, once) {\n if (typeof fn !== 'function') {\n throw new TypeError('The listener must be a function');\n }\n\n var listener = new EE(fn, context || emitter, once)\n , evt = prefix ? prefix + event : event;\n\n if (!emitter._events[evt]) emitter._events[evt] = listener, emitter._eventsCount++;\n else if (!emitter._events[evt].fn) emitter._events[evt].push(listener);\n else emitter._events[evt] = [emitter._events[evt], listener];\n\n return emitter;\n}\n\n/**\n * Clear event by name.\n *\n * @param {EventEmitter} emitter Reference to the `EventEmitter` instance.\n * @param {(String|Symbol)} evt The Event name.\n * @private\n */\nfunction clearEvent(emitter, evt) {\n if (--emitter._eventsCount === 0) emitter._events = new Events();\n else delete emitter._events[evt];\n}\n\n/**\n * Minimal `EventEmitter` interface that is molded against the Node.js\n * `EventEmitter` interface.\n *\n * @constructor\n * @public\n */\nfunction EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}\n\n/**\n * Return an array listing the events for which the emitter has registered\n * listeners.\n *\n * @returns {Array}\n * @public\n */\nEventEmitter.prototype.eventNames = function eventNames() {\n var names = []\n , events\n , name;\n\n if (this._eventsCount === 0) return names;\n\n for (name in (events = this._events)) {\n if (has.call(events, name)) names.push(prefix ? name.slice(1) : name);\n }\n\n if (Object.getOwnPropertySymbols) {\n return names.concat(Object.getOwnPropertySymbols(events));\n }\n\n return names;\n};\n\n/**\n * Return the listeners registered for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Array} The registered listeners.\n * @public\n */\nEventEmitter.prototype.listeners = function listeners(event) {\n var evt = prefix ? prefix + event : event\n , handlers = this._events[evt];\n\n if (!handlers) return [];\n if (handlers.fn) return [handlers.fn];\n\n for (var i = 0, l = handlers.length, ee = new Array(l); i < l; i++) {\n ee[i] = handlers[i].fn;\n }\n\n return ee;\n};\n\n/**\n * Return the number of listeners listening to a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Number} The number of listeners.\n * @public\n */\nEventEmitter.prototype.listenerCount = function listenerCount(event) {\n var evt = prefix ? prefix + event : event\n , listeners = this._events[evt];\n\n if (!listeners) return 0;\n if (listeners.fn) return 1;\n return listeners.length;\n};\n\n/**\n * Calls each of the listeners registered for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @returns {Boolean} `true` if the event had listeners, else `false`.\n * @public\n */\nEventEmitter.prototype.emit = function emit(event, a1, a2, a3, a4, a5) {\n var evt = prefix ? prefix + event : event;\n\n if (!this._events[evt]) return false;\n\n var listeners = this._events[evt]\n , len = arguments.length\n , args\n , i;\n\n if (listeners.fn) {\n if (listeners.once) this.removeListener(event, listeners.fn, undefined, true);\n\n switch (len) {\n case 1: return listeners.fn.call(listeners.context), true;\n case 2: return listeners.fn.call(listeners.context, a1), true;\n case 3: return listeners.fn.call(listeners.context, a1, a2), true;\n case 4: return listeners.fn.call(listeners.context, a1, a2, a3), true;\n case 5: return listeners.fn.call(listeners.context, a1, a2, a3, a4), true;\n case 6: return listeners.fn.call(listeners.context, a1, a2, a3, a4, a5), true;\n }\n\n for (i = 1, args = new Array(len -1); i < len; i++) {\n args[i - 1] = arguments[i];\n }\n\n listeners.fn.apply(listeners.context, args);\n } else {\n var length = listeners.length\n , j;\n\n for (i = 0; i < length; i++) {\n if (listeners[i].once) this.removeListener(event, listeners[i].fn, undefined, true);\n\n switch (len) {\n case 1: listeners[i].fn.call(listeners[i].context); break;\n case 2: listeners[i].fn.call(listeners[i].context, a1); break;\n case 3: listeners[i].fn.call(listeners[i].context, a1, a2); break;\n case 4: listeners[i].fn.call(listeners[i].context, a1, a2, a3); break;\n default:\n if (!args) for (j = 1, args = new Array(len -1); j < len; j++) {\n args[j - 1] = arguments[j];\n }\n\n listeners[i].fn.apply(listeners[i].context, args);\n }\n }\n }\n\n return true;\n};\n\n/**\n * Add a listener for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} [context=this] The context to invoke the listener with.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.on = function on(event, fn, context) {\n return addListener(this, event, fn, context, false);\n};\n\n/**\n * Add a one-time listener for a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn The listener function.\n * @param {*} [context=this] The context to invoke the listener with.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.once = function once(event, fn, context) {\n return addListener(this, event, fn, context, true);\n};\n\n/**\n * Remove the listeners of a given event.\n *\n * @param {(String|Symbol)} event The event name.\n * @param {Function} fn Only remove the listeners that match this function.\n * @param {*} context Only remove the listeners that have this context.\n * @param {Boolean} once Only remove one-time listeners.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.removeListener = function removeListener(event, fn, context, once) {\n var evt = prefix ? prefix + event : event;\n\n if (!this._events[evt]) return this;\n if (!fn) {\n clearEvent(this, evt);\n return this;\n }\n\n var listeners = this._events[evt];\n\n if (listeners.fn) {\n if (\n listeners.fn === fn &&\n (!once || listeners.once) &&\n (!context || listeners.context === context)\n ) {\n clearEvent(this, evt);\n }\n } else {\n for (var i = 0, events = [], length = listeners.length; i < length; i++) {\n if (\n listeners[i].fn !== fn ||\n (once && !listeners[i].once) ||\n (context && listeners[i].context !== context)\n ) {\n events.push(listeners[i]);\n }\n }\n\n //\n // Reset the array, or remove it completely if we have no more listeners.\n //\n if (events.length) this._events[evt] = events.length === 1 ? events[0] : events;\n else clearEvent(this, evt);\n }\n\n return this;\n};\n\n/**\n * Remove all listeners, or those of the specified event.\n *\n * @param {(String|Symbol)} [event] The event name.\n * @returns {EventEmitter} `this`.\n * @public\n */\nEventEmitter.prototype.removeAllListeners = function removeAllListeners(event) {\n var evt;\n\n if (event) {\n evt = prefix ? prefix + event : event;\n if (this._events[evt]) clearEvent(this, evt);\n } else {\n this._events = new Events();\n this._eventsCount = 0;\n }\n\n return this;\n};\n\n//\n// Alias methods names because people roll like that.\n//\nEventEmitter.prototype.off = EventEmitter.prototype.removeListener;\nEventEmitter.prototype.addListener = EventEmitter.prototype.on;\n\n//\n// Expose the prefix.\n//\nEventEmitter.prefixed = prefix;\n\n//\n// Allow `EventEmitter` to be imported as module namespace.\n//\nEventEmitter.EventEmitter = EventEmitter;\n\n//\n// Expose the module.\n//\nif ('undefined' !== typeof module) {\n module.exports = EventEmitter;\n}\n","/**\r\n * Make a map and return a function for checking if a key\r\n * is in that map.\r\n * IMPORTANT: all calls of this function must be prefixed with\r\n * \\/\\*#\\_\\_PURE\\_\\_\\*\\/\r\n * So that rollup can tree-shake them if necessary.\r\n */\r\nfunction makeMap(str, expectsLowerCase) {\r\n const map = Object.create(null);\r\n const list = str.split(',');\r\n for (let i = 0; i < list.length; i++) {\r\n map[list[i]] = true;\r\n }\r\n return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];\r\n}\n\n/**\r\n * dev only flag -> name mapping\r\n */\r\nconst PatchFlagNames = {\r\n [1 /* TEXT */]: `TEXT`,\r\n [2 /* CLASS */]: `CLASS`,\r\n [4 /* STYLE */]: `STYLE`,\r\n [8 /* PROPS */]: `PROPS`,\r\n [16 /* FULL_PROPS */]: `FULL_PROPS`,\r\n [32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,\r\n [64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,\r\n [128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,\r\n [256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,\r\n [512 /* NEED_PATCH */]: `NEED_PATCH`,\r\n [1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,\r\n [2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,\r\n [-1 /* HOISTED */]: `HOISTED`,\r\n [-2 /* BAIL */]: `BAIL`\r\n};\n\n/**\r\n * Dev only\r\n */\r\nconst slotFlagsText = {\r\n [1 /* STABLE */]: 'STABLE',\r\n [2 /* DYNAMIC */]: 'DYNAMIC',\r\n [3 /* FORWARDED */]: 'FORWARDED'\r\n};\n\nconst GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +\r\n 'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +\r\n 'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';\r\nconst isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);\n\nconst range = 2;\r\nfunction generateCodeFrame(source, start = 0, end = source.length) {\r\n // Split the content into individual lines but capture the newline sequence\r\n // that separated each line. This is important because the actual sequence is\r\n // needed to properly take into account the full line length for offset\r\n // comparison\r\n let lines = source.split(/(\\r?\\n)/);\r\n // Separate the lines and newline sequences into separate arrays for easier referencing\r\n const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);\r\n lines = lines.filter((_, idx) => idx % 2 === 0);\r\n let count = 0;\r\n const res = [];\r\n for (let i = 0; i < lines.length; i++) {\r\n count +=\r\n lines[i].length +\r\n ((newlineSequences[i] && newlineSequences[i].length) || 0);\r\n if (count >= start) {\r\n for (let j = i - range; j <= i + range || end > count; j++) {\r\n if (j < 0 || j >= lines.length)\r\n continue;\r\n const line = j + 1;\r\n res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);\r\n const lineLength = lines[j].length;\r\n const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;\r\n if (j === i) {\r\n // push underline\r\n const pad = start - (count - (lineLength + newLineSeqLength));\r\n const length = Math.max(1, end > count ? lineLength - pad : end - start);\r\n res.push(` | ` + ' '.repeat(pad) + '^'.repeat(length));\r\n }\r\n else if (j > i) {\r\n if (end > count) {\r\n const length = Math.max(Math.min(end - count, lineLength), 1);\r\n res.push(` | ` + '^'.repeat(length));\r\n }\r\n count += lineLength + newLineSeqLength;\r\n }\r\n }\r\n break;\r\n }\r\n }\r\n return res.join('\\n');\r\n}\n\n/**\r\n * On the client we only need to offer special cases for boolean attributes that\r\n * have different names from their corresponding dom properties:\r\n * - itemscope -> N/A\r\n * - allowfullscreen -> allowFullscreen\r\n * - formnovalidate -> formNoValidate\r\n * - ismap -> isMap\r\n * - nomodule -> noModule\r\n * - novalidate -> noValidate\r\n * - readonly -> readOnly\r\n */\r\nconst specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;\r\nconst isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);\r\n/**\r\n * The full list is needed during SSR to produce the correct initial markup.\r\n */\r\nconst isBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs +\r\n `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,` +\r\n `loop,open,required,reversed,scoped,seamless,` +\r\n `checked,muted,multiple,selected`);\r\n/**\r\n * Boolean attributes should be included if the value is truthy or ''.\r\n * e.g. `<select multiple>` compiles to `{ multiple: '' }`\r\n */\r\nfunction includeBooleanAttr(value) {\r\n return !!value || value === '';\r\n}\r\nconst unsafeAttrCharRE = /[>/=\"'\\u0009\\u000a\\u000c\\u0020]/;\r\nconst attrValidationCache = {};\r\nfunction isSSRSafeAttrName(name) {\r\n if (attrValidationCache.hasOwnProperty(name)) {\r\n return attrValidationCache[name];\r\n }\r\n const isUnsafe = unsafeAttrCharRE.test(name);\r\n if (isUnsafe) {\r\n console.error(`unsafe attribute name: ${name}`);\r\n }\r\n return (attrValidationCache[name] = !isUnsafe);\r\n}\r\nconst propsToAttrMap = {\r\n acceptCharset: 'accept-charset',\r\n className: 'class',\r\n htmlFor: 'for',\r\n httpEquiv: 'http-equiv'\r\n};\r\n/**\r\n * CSS properties that accept plain numbers\r\n */\r\nconst isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +\r\n `border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +\r\n `columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +\r\n `grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +\r\n `grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +\r\n `line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +\r\n // SVG\r\n `fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +\r\n `stroke-miterlimit,stroke-opacity,stroke-width`);\r\n/**\r\n * Known attributes, this is used for stringification of runtime static nodes\r\n * so that we don't stringify bindings that cannot be set from HTML.\r\n * Don't also forget to allow `data-*` and `aria-*`!\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes\r\n */\r\nconst isKnownHtmlAttr = /*#__PURE__*/ makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,` +\r\n `autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,` +\r\n `border,buffered,capture,challenge,charset,checked,cite,class,code,` +\r\n `codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,` +\r\n `coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,` +\r\n `disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,` +\r\n `formaction,formenctype,formmethod,formnovalidate,formtarget,headers,` +\r\n `height,hidden,high,href,hreflang,http-equiv,icon,id,importance,integrity,` +\r\n `ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,` +\r\n `manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,` +\r\n `open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,` +\r\n `referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,` +\r\n `selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,` +\r\n `start,step,style,summary,tabindex,target,title,translate,type,usemap,` +\r\n `value,width,wrap`);\r\n/**\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\r\n */\r\nconst isKnownSvgAttr = /*#__PURE__*/ makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,` +\r\n `arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,` +\r\n `baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,` +\r\n `clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,` +\r\n `color-interpolation-filters,color-profile,color-rendering,` +\r\n `contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,` +\r\n `descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,` +\r\n `dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,` +\r\n `fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,` +\r\n `font-family,font-size,font-size-adjust,font-stretch,font-style,` +\r\n `font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,` +\r\n `glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,` +\r\n `gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,` +\r\n `horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,` +\r\n `k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,` +\r\n `lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,` +\r\n `marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,` +\r\n `mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,` +\r\n `name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,` +\r\n `overflow,overline-position,overline-thickness,panose-1,paint-order,path,` +\r\n `pathLength,patternContentUnits,patternTransform,patternUnits,ping,` +\r\n `pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,` +\r\n `preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,` +\r\n `rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,` +\r\n `restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,` +\r\n `specularConstant,specularExponent,speed,spreadMethod,startOffset,` +\r\n `stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,` +\r\n `strikethrough-position,strikethrough-thickness,string,stroke,` +\r\n `stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,` +\r\n `stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,` +\r\n `systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,` +\r\n `text-decoration,text-rendering,textLength,to,transform,transform-origin,` +\r\n `type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,` +\r\n `unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,` +\r\n `v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,` +\r\n `vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,` +\r\n `writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,` +\r\n `xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,` +\r\n `xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);\n\nfunction normalizeStyle(value) {\r\n if (isArray(value)) {\r\n const res = {};\r\n for (let i = 0; i < value.length; i++) {\r\n const item = value[i];\r\n const normalized = isString(item)\r\n ? parseStringStyle(item)\r\n : normalizeStyle(item);\r\n if (normalized) {\r\n for (const key in normalized) {\r\n res[key] = normalized[key];\r\n }\r\n }\r\n }\r\n return res;\r\n }\r\n else if (isString(value)) {\r\n return value;\r\n }\r\n else if (isObject(value)) {\r\n return value;\r\n }\r\n}\r\nconst listDelimiterRE = /;(?![^(]*\\))/g;\r\nconst propertyDelimiterRE = /:(.+)/;\r\nfunction parseStringStyle(cssText) {\r\n const ret = {};\r\n cssText.split(listDelimiterRE).forEach(item => {\r\n if (item) {\r\n const tmp = item.split(propertyDelimiterRE);\r\n tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());\r\n }\r\n });\r\n return ret;\r\n}\r\nfunction stringifyStyle(styles) {\r\n let ret = '';\r\n if (!styles || isString(styles)) {\r\n return ret;\r\n }\r\n for (const key in styles) {\r\n const value = styles[key];\r\n const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);\r\n if (isString(value) ||\r\n (typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {\r\n // only render valid values\r\n ret += `${normalizedKey}:${value};`;\r\n }\r\n }\r\n return ret;\r\n}\r\nfunction normalizeClass(value) {\r\n let res = '';\r\n if (isString(value)) {\r\n res = value;\r\n }\r\n else if (isArray(value)) {\r\n for (let i = 0; i < value.length; i++) {\r\n const normalized = normalizeClass(value[i]);\r\n if (normalized) {\r\n res += normalized + ' ';\r\n }\r\n }\r\n }\r\n else if (isObject(value)) {\r\n for (const name in value) {\r\n if (value[name]) {\r\n res += name + ' ';\r\n }\r\n }\r\n }\r\n return res.trim();\r\n}\r\nfunction normalizeProps(props) {\r\n if (!props)\r\n return null;\r\n let { class: klass, style } = props;\r\n if (klass && !isString(klass)) {\r\n props.class = normalizeClass(klass);\r\n }\r\n if (style) {\r\n props.style = normalizeStyle(style);\r\n }\r\n return props;\r\n}\n\n// These tag configs are shared between compiler-dom and runtime-dom, so they\r\n// https://developer.mozilla.org/en-US/docs/Web/HTML/Element\r\nconst HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +\r\n 'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +\r\n 'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +\r\n 'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +\r\n 'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +\r\n 'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +\r\n 'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +\r\n 'option,output,progress,select,textarea,details,dialog,menu,' +\r\n 'summary,template,blockquote,iframe,tfoot';\r\n// https://developer.mozilla.org/en-US/docs/Web/SVG/Element\r\nconst SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +\r\n 'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +\r\n 'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +\r\n 'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +\r\n 'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +\r\n 'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +\r\n 'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +\r\n 'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +\r\n 'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +\r\n 'text,textPath,title,tspan,unknown,use,view';\r\nconst VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';\r\nconst isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);\r\nconst isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);\r\nconst isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);\n\nconst escapeRE = /[\"'&<>]/;\r\nfunction escapeHtml(string) {\r\n const str = '' + string;\r\n const match = escapeRE.exec(str);\r\n if (!match) {\r\n return str;\r\n }\r\n let html = '';\r\n let escaped;\r\n let index;\r\n let lastIndex = 0;\r\n for (index = match.index; index < str.length; index++) {\r\n switch (str.charCodeAt(index)) {\r\n case 34: // \"\r\n escaped = '"';\r\n break;\r\n case 38: // &\r\n escaped = '&';\r\n break;\r\n case 39: // '\r\n escaped = ''';\r\n break;\r\n case 60: // <\r\n escaped = '<';\r\n break;\r\n case 62: // >\r\n escaped = '>';\r\n break;\r\n default:\r\n continue;\r\n }\r\n if (lastIndex !== index) {\r\n html += str.slice(lastIndex, index);\r\n }\r\n lastIndex = index + 1;\r\n html += escaped;\r\n }\r\n return lastIndex !== index ? html + str.slice(lastIndex, index) : html;\r\n}\r\n// https://www.w3.org/TR/html52/syntax.html#comments\r\nconst commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;\r\nfunction escapeHtmlComment(src) {\r\n return src.replace(commentStripRE, '');\r\n}\n\nfunction looseCompareArrays(a, b) {\r\n if (a.length !== b.length)\r\n return false;\r\n let equal = true;\r\n for (let i = 0; equal && i < a.length; i++) {\r\n equal = looseEqual(a[i], b[i]);\r\n }\r\n return equal;\r\n}\r\nfunction looseEqual(a, b) {\r\n if (a === b)\r\n return true;\r\n let aValidType = isDate(a);\r\n let bValidType = isDate(b);\r\n if (aValidType || bValidType) {\r\n return aValidType && bValidType ? a.getTime() === b.getTime() : false;\r\n }\r\n aValidType = isArray(a);\r\n bValidType = isArray(b);\r\n if (aValidType || bValidType) {\r\n return aValidType && bValidType ? looseCompareArrays(a, b) : false;\r\n }\r\n aValidType = isObject(a);\r\n bValidType = isObject(b);\r\n if (aValidType || bValidType) {\r\n /* istanbul ignore if: this if will probably never be called */\r\n if (!aValidType || !bValidType) {\r\n return false;\r\n }\r\n const aKeysCount = Object.keys(a).length;\r\n const bKeysCount = Object.keys(b).length;\r\n if (aKeysCount !== bKeysCount) {\r\n return false;\r\n }\r\n for (const key in a) {\r\n const aHasKey = a.hasOwnProperty(key);\r\n const bHasKey = b.hasOwnProperty(key);\r\n if ((aHasKey && !bHasKey) ||\r\n (!aHasKey && bHasKey) ||\r\n !looseEqual(a[key], b[key])) {\r\n return false;\r\n }\r\n }\r\n }\r\n return String(a) === String(b);\r\n}\r\nfunction looseIndexOf(arr, val) {\r\n return arr.findIndex(item => looseEqual(item, val));\r\n}\n\n/**\r\n * For converting {{ interpolation }} values to displayed strings.\r\n * @private\r\n */\r\nconst toDisplayString = (val) => {\r\n return val == null\r\n ? ''\r\n : isArray(val) ||\r\n (isObject(val) &&\r\n (val.toString === objectToString || !isFunction(val.toString)))\r\n ? JSON.stringify(val, replacer, 2)\r\n : String(val);\r\n};\r\nconst replacer = (_key, val) => {\r\n // can't use isRef here since @vue/shared has no deps\r\n if (val && val.__v_isRef) {\r\n return replacer(_key, val.value);\r\n }\r\n else if (isMap(val)) {\r\n return {\r\n [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {\r\n entries[`${key} =>`] = val;\r\n return entries;\r\n }, {})\r\n };\r\n }\r\n else if (isSet(val)) {\r\n return {\r\n [`Set(${val.size})`]: [...val.values()]\r\n };\r\n }\r\n else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {\r\n return String(val);\r\n }\r\n return val;\r\n};\n\nconst EMPTY_OBJ = (process.env.NODE_ENV !== 'production')\r\n ? Object.freeze({})\r\n : {};\r\nconst EMPTY_ARR = (process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst NOOP = () => { };\r\n/**\r\n * Always return false.\r\n */\r\nconst NO = () => false;\r\nconst onRE = /^on[^a-z]/;\r\nconst isOn = (key) => onRE.test(key);\r\nconst isModelListener = (key) => key.startsWith('onUpdate:');\r\nconst extend = Object.assign;\r\nconst remove = (arr, el) => {\r\n const i = arr.indexOf(el);\r\n if (i > -1) {\r\n arr.splice(i, 1);\r\n }\r\n};\r\nconst hasOwnProperty = Object.prototype.hasOwnProperty;\r\nconst hasOwn = (val, key) => hasOwnProperty.call(val, key);\r\nconst isArray = Array.isArray;\r\nconst isMap = (val) => toTypeString(val) === '[object Map]';\r\nconst isSet = (val) => toTypeString(val) === '[object Set]';\r\nconst isDate = (val) => val instanceof Date;\r\nconst isFunction = (val) => typeof val === 'function';\r\nconst isString = (val) => typeof val === 'string';\r\nconst isSymbol = (val) => typeof val === 'symbol';\r\nconst isObject = (val) => val !== null && typeof val === 'object';\r\nconst isPromise = (val) => {\r\n return isObject(val) && isFunction(val.then) && isFunction(val.catch);\r\n};\r\nconst objectToString = Object.prototype.toString;\r\nconst toTypeString = (value) => objectToString.call(value);\r\nconst toRawType = (value) => {\r\n // extract \"RawType\" from strings like \"[object RawType]\"\r\n return toTypeString(value).slice(8, -1);\r\n};\r\nconst isPlainObject = (val) => toTypeString(val) === '[object Object]';\r\nconst isIntegerKey = (key) => isString(key) &&\r\n key !== 'NaN' &&\r\n key[0] !== '-' &&\r\n '' + parseInt(key, 10) === key;\r\nconst isReservedProp = /*#__PURE__*/ makeMap(\r\n// the leading comma is intentional so empty string \"\" is also included\r\n',key,ref,ref_for,ref_key,' +\r\n 'onVnodeBeforeMount,onVnodeMounted,' +\r\n 'onVnodeBeforeUpdate,onVnodeUpdated,' +\r\n 'onVnodeBeforeUnmount,onVnodeUnmounted');\r\nconst cacheStringFunction = (fn) => {\r\n const cache = Object.create(null);\r\n return ((str) => {\r\n const hit = cache[str];\r\n return hit || (cache[str] = fn(str));\r\n });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\r\nconst hyphenateRE = /\\B([A-Z])/g;\r\n/**\r\n * @private\r\n */\r\nconst hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());\r\n/**\r\n * @private\r\n */\r\nconst capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));\r\n/**\r\n * @private\r\n */\r\nconst toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);\r\n// compare whether a value has changed, accounting for NaN.\r\nconst hasChanged = (value, oldValue) => !Object.is(value, oldValue);\r\nconst invokeArrayFns = (fns, arg) => {\r\n for (let i = 0; i < fns.length; i++) {\r\n fns[i](arg);\r\n }\r\n};\r\nconst def = (obj, key, value) => {\r\n Object.defineProperty(obj, key, {\r\n configurable: true,\r\n enumerable: false,\r\n value\r\n });\r\n};\r\nconst toNumber = (val) => {\r\n const n = parseFloat(val);\r\n return isNaN(n) ? val : n;\r\n};\r\nlet _globalThis;\r\nconst getGlobalThis = () => {\r\n return (_globalThis ||\r\n (_globalThis =\r\n typeof globalThis !== 'undefined'\r\n ? globalThis\r\n : typeof self !== 'undefined'\r\n ? self\r\n : typeof window !== 'undefined'\r\n ? window\r\n : typeof global !== 'undefined'\r\n ? global\r\n : {}));\r\n};\n\nexport { EMPTY_ARR, EMPTY_OBJ, NO, NOOP, PatchFlagNames, camelize, capitalize, def, escapeHtml, escapeHtmlComment, extend, generateCodeFrame, getGlobalThis, hasChanged, hasOwn, hyphenate, includeBooleanAttr, invokeArrayFns, isArray, isBooleanAttr, isDate, isFunction, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownSvgAttr, isMap, isModelListener, isNoUnitNumericStyleProp, isObject, isOn, isPlainObject, isPromise, isReservedProp, isSSRSafeAttrName, isSVGTag, isSet, isSpecialBooleanAttr, isString, isSymbol, isVoidTag, looseEqual, looseIndexOf, makeMap, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, remove, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toNumber, toRawType, toTypeString };\n","<template>\n <transition :name=\"name\"\n @before-appear=\"beforeAppear\"\n @appear=\"appear\"\n @after-appear=\"afterAppear\"\n @appear-cancelled=\"appearCancelled\"\n @before-enter=\"beforeEnter\"\n @enter=\"enter\"\n @after-enter=\"afterEnter\"\n @enter-cancelled=\"enterCancelled\"\n @before-leave=\"beforeLeave\"\n @leave=\"leave\"\n @after-leave=\"afterLeave\"\n @leave-cancelled=\"leaveCancelled\"\n >\n <slot></slot>\n </transition>\n</template>\n\n<script>\n export default {\n name: \"CollapseTransition\",\n\n props: {\n name: {\n type: String,\n required: false,\n default: 'collapse'\n },\n dimension: {\n type: String,\n required: false,\n default: 'height',\n validator: (value) => {\n return ['height', 'width'].includes(value)\n }\n },\n duration: {\n type: Number,\n required: false,\n default: 300\n },\n easing: {\n type: String,\n required: false,\n default: 'ease-in-out'\n },\n },\n\n watch: {\n dimension() {\n this.clearCachedDimensions()\n }\n },\n\n data() {\n return {\n cachedStyles: null,\n }\n },\n\n computed: {\n transition() {\n let transitions = []\n\n Object.keys(this.cachedStyles).forEach((key) => {\n transitions.push(`${this.convertToCssProperty(key)} ${this.duration}ms ${this.easing}`)\n })\n\n return transitions.join(', ')\n }\n },\n\n methods: {\n beforeAppear(el) {\n // Emit the event to the parent\n this.$emit('before-appear', el)\n },\n\n appear(el) {\n // Emit the event to the parent\n this.$emit('appear', el)\n },\n\n afterAppear(el) {\n // Emit the event to the parent\n this.$emit('after-appear', el)\n },\n\n appearCancelled(el) {\n // Emit the event to the parent\n this.$emit('appear-cancelled', el)\n },\n\n beforeEnter(el) {\n // Emit the event to the parent\n this.$emit('before-enter', el)\n },\n\n enter(el, done) {\n // Because width and height may be 'auto',\n // first detect and cache the dimensions\n this.detectAndCacheDimensions(el)\n\n // The order of applying styles is important:\n // - 1. Set styles for state before transition\n // - 2. Force repaint\n // - 3. Add transition style\n // - 4. Set styles for state after transition\n // If the order is not right and you open any 2nd level submenu\n // for the first time, the transition will not work.\n this.setClosedDimensions(el)\n this.hideOverflow(el)\n this.forceRepaint(el)\n this.setTransition(el)\n this.setOpenedDimensions(el)\n\n // Emit the event to the parent\n this.$emit('enter', el, done)\n\n // Call done() when the transition ends\n // to trigger the @after-enter event.\n setTimeout(done, this.duration)\n },\n\n afterEnter(el) {\n // Clean up inline styles\n this.unsetOverflow(el)\n this.unsetTransition(el)\n this.unsetDimensions(el)\n this.clearCachedDimensions()\n\n // Emit the event to the parent\n this.$emit('after-enter', el)\n },\n\n enterCancelled(el) {\n // Emit the event to the parent\n this.$emit('enter-cancelled', el)\n },\n\n beforeLeave(el) {\n // Emit the event to the parent\n this.$emit('before-leave', el)\n },\n\n leave(el, done) {\n // For some reason, @leave triggered when starting\n // from open state on page load. So for safety,\n // check if the dimensions have been cached.\n this.detectAndCacheDimensions(el)\n\n // The order of applying styles is less important\n // than in the enter phase, as long as we repaint\n // before setting the closed dimensions.\n // But it is probably best to use the same\n // order as the enter phase.\n this.setOpenedDimensions(el)\n this.hideOverflow(el)\n this.forceRepaint(el)\n this.setTransition(el)\n this.setClosedDimensions(el)\n\n // Emit the event to the parent\n this.$emit('leave', el, done)\n\n // Call done() when the transition ends\n // to trigger the @after-leave event.\n // This will also cause v-show\n // to reapply 'display: none'.\n setTimeout(done, this.duration)\n },\n\n afterLeave(el) {\n // Clean up inline styles\n this.unsetOverflow(el)\n this.unsetTransition(el)\n this.unsetDimensions(el)\n this.clearCachedDimensions()\n\n // Emit the event to the parent\n this.$emit('after-leave', el)\n },\n\n leaveCancelled(el) {\n // Emit the event to the parent\n this.$emit('leave-cancelled', el)\n },\n\n detectAndCacheDimensions(el) {\n // Cache actual dimensions\n // only once to void invalid values when\n // triggering during a transition\n if (this.cachedStyles) return\n\n const visibility = el.style.visibility\n const display = el.style.display\n\n // Trick to get the width and\n // height of a hidden element\n el.style.visibility = 'hidden'\n el.style.display = ''\n\n this.cachedStyles = this.detectRelevantDimensions(el)\n\n // Restore any original styling\n el.style.visibility = visibility\n el.style.display = display\n },\n\n clearCachedDimensions() {\n this.cachedStyles = null\n },\n\n detectRelevantDimensions(el) {\n // These properties will be transitioned\n if (this.dimension === 'height') {\n return {\n 'height': el.offsetHeight + 'px',\n 'paddingTop': el.style.paddingTop || this.getCssValue(el, 'padding-top'),\n 'paddingBottom': el.style.paddingBottom || this.getCssValue(el, 'padding-bottom'),\n }\n }\n\n if (this.dimension === 'width') {\n return {\n 'width': el.offsetWidth + 'px',\n 'paddingLeft': el.style.paddingLeft || this.getCssValue(el, 'padding-left'),\n 'paddingRight': el.style.paddingRight || this.getCssValue(el, 'padding-right'),\n }\n }\n\n return {}\n },\n\n setTransition(el) {\n el.style.transition = this.transition\n },\n\n unsetTransition(el) {\n el.style.transition = ''\n },\n\n hideOverflow(el) {\n el.style.overflow = 'hidden'\n },\n\n unsetOverflow(el) {\n el.style.overflow = ''\n },\n\n setClosedDimensions(el) {\n Object.keys(this.cachedStyles).forEach(key => {\n el.style[key] = '0'\n })\n },\n\n setOpenedDimensions(el) {\n Object.keys(this.cachedStyles).forEach((key) => {\n el.style[key] = this.cachedStyles[key]\n })\n },\n\n unsetDimensions(el) {\n Object.keys(this.cachedStyles).forEach((key) => {\n el.style[key] = ''\n })\n },\n\n forceRepaint(el) {\n // Force repaint to make sure the animation is triggered correctly.\n // Thanks: https://markus.oberlehner.net/blog/transition-to-height-auto-with-vue/\n getComputedStyle(el)[this.dimension]\n },\n\n getCssValue(el, style) {\n return getComputedStyle(el, null).getPropertyValue(style)\n },\n\n convertToCssProperty(style) {\n // Example: convert 'paddingTop' to 'padding-top'\n // Thanks: https://gist.github.com/tan-yuki/3450323\n const upperChars = style.match(/([A-Z])/g)\n\n if ( ! upperChars) {\n return style\n }\n\n for (let i = 0, n = upperChars.length; i < n; i++) {\n style = style.replace(new RegExp(upperChars[i]), '-' + upperChars[i].toLowerCase())\n }\n\n if (style.slice(0, 1) === '-') {\n style = style.slice(1)\n }\n\n return style\n }\n }\n }\n</script>\n","import { render } from \"./CollapseTransition.vue?vue&type=template&id=0f6a5689\"\nimport script from \"./CollapseTransition.vue?vue&type=script&lang=js\"\nexport * from \"./CollapseTransition.vue?vue&type=script&lang=js\"\n\nimport exportComponent from \"/home/runner/work/TMT-Demo/TMT-Demo/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar tryToString = require('../internals/try-to-string');\n\nvar TypeError = global.TypeError;\n\n// `Assert: IsCallable(argument) is true`\nmodule.exports = function (argument) {\n if (isCallable(argument)) return argument;\n throw TypeError(tryToString(argument) + ' is not a function');\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar String = global.String;\nvar TypeError = global.TypeError;\n\nmodule.exports = function (argument) {\n if (typeof argument == 'object' || isCallable(argument)) return argument;\n throw TypeError(\"Can't set \" + String(argument) + ' as a prototype');\n};\n","var global = require('../internals/global');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\n\nvar TypeError = global.TypeError;\n\nmodule.exports = function (it, Prototype) {\n if (isPrototypeOf(Prototype, it)) return it;\n throw TypeError('Incorrect invocation');\n};\n","var global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar String = global.String;\nvar TypeError = global.TypeError;\n\n// `Assert: Type(argument) is Object`\nmodule.exports = function (argument) {\n if (isObject(argument)) return argument;\n throw TypeError(String(argument) + ' is not an object');\n};\n","var toIndexedObject = require('../internals/to-indexed-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = lengthOfArrayLike(O);\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare -- NaN check\n if (IS_INCLUDES && el != el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare -- NaN check\n if (value != value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.es/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.es/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar toString = uncurryThis({}.toString);\nvar stringSlice = uncurryThis(''.slice);\n\nmodule.exports = function (it) {\n return stringSlice(toString(it), 8, -1);\n};\n","var global = require('../internals/global');\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar isCallable = require('../internals/is-callable');\nvar classofRaw = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar Object = global.Object;\n\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) == 'Object' && isCallable(O.callee) ? 'Arguments' : result;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar replace = uncurryThis(''.replace);\n\nvar TEST = (function (arg) { return String(Error(arg).stack); })('zxcasd');\nvar V8_OR_CHAKRA_STACK_ENTRY = /\\n\\s*at [^:]*:[^\\n]*/;\nvar IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);\n\nmodule.exports = function (stack, dropEntries) {\n if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string') {\n while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');\n } return stack;\n};\n","var hasOwn = require('../internals/has-own-property');\nvar ownKeys = require('../internals/own-keys');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\n\nmodule.exports = function (target, source, exceptions) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {\n defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n }\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n","module.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n","var fails = require('../internals/fails');\n\n// Detect IE8's incomplete defineProperty implementation\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;\n});\n","var global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n","module.exports = {\n IndexSizeError: { s: 'INDEX_SIZE_ERR', c: 1, m: 1 },\n DOMStringSizeError: { s: 'DOMSTRING_SIZE_ERR', c: 2, m: 0 },\n HierarchyRequestError: { s: 'HIERARCHY_REQUEST_ERR', c: 3, m: 1 },\n WrongDocumentError: { s: 'WRONG_DOCUMENT_ERR', c: 4, m: 1 },\n InvalidCharacterError: { s: 'INVALID_CHARACTER_ERR', c: 5, m: 1 },\n NoDataAllowedError: { s: 'NO_DATA_ALLOWED_ERR', c: 6, m: 0 },\n NoModificationAllowedError: { s: 'NO_MODIFICATION_ALLOWED_ERR', c: 7, m: 1 },\n NotFoundError: { s: 'NOT_FOUND_ERR', c: 8, m: 1 },\n NotSupportedError: { s: 'NOT_SUPPORTED_ERR', c: 9, m: 1 },\n InUseAttributeError: { s: 'INUSE_ATTRIBUTE_ERR', c: 10, m: 1 },\n InvalidStateError: { s: 'INVALID_STATE_ERR', c: 11, m: 1 },\n SyntaxError: { s: 'SYNTAX_ERR', c: 12, m: 1 },\n InvalidModificationError: { s: 'INVALID_MODIFICATION_ERR', c: 13, m: 1 },\n NamespaceError: { s: 'NAMESPACE_ERR', c: 14, m: 1 },\n InvalidAccessError: { s: 'INVALID_ACCESS_ERR', c: 15, m: 1 },\n ValidationError: { s: 'VALIDATION_ERR', c: 16, m: 0 },\n TypeMismatchError: { s: 'TYPE_MISMATCH_ERR', c: 17, m: 1 },\n SecurityError: { s: 'SECURITY_ERR', c: 18, m: 1 },\n NetworkError: { s: 'NETWORK_ERR', c: 19, m: 1 },\n AbortError: { s: 'ABORT_ERR', c: 20, m: 1 },\n URLMismatchError: { s: 'URL_MISMATCH_ERR', c: 21, m: 1 },\n QuotaExceededError: { s: 'QUOTA_EXCEEDED_ERR', c: 22, m: 1 },\n TimeoutError: { s: 'TIMEOUT_ERR', c: 23, m: 1 },\n InvalidNodeTypeError: { s: 'INVALID_NODE_TYPE_ERR', c: 24, m: 1 },\n DataCloneError: { s: 'DATA_CLONE_ERR', c: 25, m: 1 }\n};\n","var getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('navigator', 'userAgent') || '';\n","var global = require('../internals/global');\nvar userAgent = require('../internals/engine-user-agent');\n\nvar process = global.process;\nvar Deno = global.Deno;\nvar versions = process && process.versions || Deno && Deno.version;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n // in old Chrome, versions of V8 isn't V8 = Chrome / 10\n // but their correct versions are not interesting for us\n version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);\n}\n\n// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`\n// so check `userAgent` even if `.v8` exists, but 0\nif (!version && userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = +match[1];\n }\n}\n\nmodule.exports = version;\n","// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n","var fails = require('../internals/fails');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = !fails(function () {\n var error = Error('a');\n if (!('stack' in error)) return true;\n // eslint-disable-next-line es/no-object-defineproperty -- safe\n Object.defineProperty(error, 'stack', createPropertyDescriptor(1, 7));\n return error.stack !== 7;\n});\n","var global = require('../internals/global');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar redefine = require('../internals/redefine');\nvar setGlobal = require('../internals/set-global');\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\nvar isForced = require('../internals/is-forced');\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.noTargetGet - prevent calling a getter on target\n options.name - the .name of the function if it does not match the key\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var FORCED, target, key, targetProperty, sourceProperty, descriptor;\n if (GLOBAL) {\n target = global;\n } else if (STATIC) {\n target = global[TARGET] || setGlobal(TARGET, {});\n } else {\n target = (global[TARGET] || {}).prototype;\n }\n if (target) for (key in source) {\n sourceProperty = source[key];\n if (options.noTargetGet) {\n descriptor = getOwnPropertyDescriptor(target, key);\n targetProperty = descriptor && descriptor.value;\n } else targetProperty = target[key];\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contained in target\n if (!FORCED && targetProperty !== undefined) {\n if (typeof sourceProperty == typeof targetProperty) continue;\n copyConstructorProperties(sourceProperty, targetProperty);\n }\n // add a flag to not completely full polyfills\n if (options.sham || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(sourceProperty, 'sham', true);\n }\n // extend global\n redefine(target, key, sourceProperty, options);\n }\n};\n","module.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n","var FunctionPrototype = Function.prototype;\nvar apply = FunctionPrototype.apply;\nvar bind = FunctionPrototype.bind;\nvar call = FunctionPrototype.call;\n\n// eslint-disable-next-line es/no-reflect -- safe\nmodule.exports = typeof Reflect == 'object' && Reflect.apply || (bind ? call.bind(apply) : function () {\n return call.apply(apply, arguments);\n});\n","var call = Function.prototype.call;\n\nmodule.exports = call.bind ? call.bind(call) : function () {\n return call.apply(call, arguments);\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar hasOwn = require('../internals/has-own-property');\n\nvar FunctionPrototype = Function.prototype;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;\n\nvar EXISTS = hasOwn(FunctionPrototype, 'name');\n// additional protection from minified / mangled / dropped function names\nvar PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';\nvar CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));\n\nmodule.exports = {\n EXISTS: EXISTS,\n PROPER: PROPER,\n CONFIGURABLE: CONFIGURABLE\n};\n","var FunctionPrototype = Function.prototype;\nvar bind = FunctionPrototype.bind;\nvar call = FunctionPrototype.call;\nvar uncurryThis = bind && bind.bind(call, call);\n\nmodule.exports = bind ? function (fn) {\n return fn && uncurryThis(fn);\n} : function (fn) {\n return fn && function () {\n return call.apply(fn, arguments);\n };\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar aFunction = function (argument) {\n return isCallable(argument) ? argument : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method];\n};\n","var aCallable = require('../internals/a-callable');\n\n// `GetMethod` abstract operation\n// https://tc39.es/ecma262/#sec-getmethod\nmodule.exports = function (V, P) {\n var func = V[P];\n return func == null ? undefined : aCallable(func);\n};\n","var check = function (it) {\n return it && it.Math == Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line es/no-global-this -- safe\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n // eslint-disable-next-line no-restricted-globals -- safe\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n // eslint-disable-next-line no-new-func -- fallback\n (function () { return this; })() || Function('return this')();\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar hasOwnProperty = uncurryThis({}.hasOwnProperty);\n\n// `HasOwnProperty` abstract operation\n// https://tc39.es/ecma262/#sec-hasownproperty\nmodule.exports = Object.hasOwn || function hasOwn(it, key) {\n return hasOwnProperty(toObject(it), key);\n};\n","module.exports = {};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\nvar createElement = require('../internals/document-create-element');\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a != 7;\n});\n","var global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar classof = require('../internals/classof-raw');\n\nvar Object = global.Object;\nvar split = uncurryThis(''.split);\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins -- safe\n return !Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) == 'String' ? split(it, '') : Object(it);\n} : Object;\n","var isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\n\n// makes subclassing work correct for wrapped built-ins\nmodule.exports = function ($this, dummy, Wrapper) {\n var NewTarget, NewTargetPrototype;\n if (\n // it can work only with native `setPrototypeOf`\n setPrototypeOf &&\n // we haven't completely correct pre-ES6 way for getting `new.target`, so use this\n isCallable(NewTarget = dummy.constructor) &&\n NewTarget !== Wrapper &&\n isObject(NewTargetPrototype = NewTarget.prototype) &&\n NewTargetPrototype !== Wrapper.prototype\n ) setPrototypeOf($this, NewTargetPrototype);\n return $this;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar isCallable = require('../internals/is-callable');\nvar store = require('../internals/shared-store');\n\nvar functionToString = uncurryThis(Function.toString);\n\n// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper\nif (!isCallable(store.inspectSource)) {\n store.inspectSource = function (it) {\n return functionToString(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n","var isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\n// `InstallErrorCause` abstract operation\n// https://tc39.es/proposal-error-cause/#sec-errorobjects-install-error-cause\nmodule.exports = function (O, options) {\n if (isObject(options) && 'cause' in options) {\n createNonEnumerableProperty(O, 'cause', options.cause);\n }\n};\n","var NATIVE_WEAK_MAP = require('../internals/native-weak-map');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\nvar shared = require('../internals/shared-store');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar OBJECT_ALREADY_INITIALIZED = 'Object already initialized';\nvar TypeError = global.TypeError;\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP || shared.state) {\n var store = shared.state || (shared.state = new WeakMap());\n var wmget = uncurryThis(store.get);\n var wmhas = uncurryThis(store.has);\n var wmset = uncurryThis(store.set);\n set = function (it, metadata) {\n if (wmhas(store, it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n wmset(store, it, metadata);\n return metadata;\n };\n get = function (it) {\n return wmget(store, it) || {};\n };\n has = function (it) {\n return wmhas(store, it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return hasOwn(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return hasOwn(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n","// `IsCallable` abstract operation\n// https://tc39.es/ecma262/#sec-iscallable\nmodule.exports = function (argument) {\n return typeof argument == 'function';\n};\n","var fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value == POLYFILL ? true\n : value == NATIVE ? false\n : isCallable(detection) ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n","var isCallable = require('../internals/is-callable');\n\nmodule.exports = function (it) {\n return typeof it == 'object' ? it !== null : isCallable(it);\n};\n","module.exports = false;\n","var global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar Object = global.Object;\n\nmodule.exports = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n var $Symbol = getBuiltIn('Symbol');\n return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, Object(it));\n};\n","var toLength = require('../internals/to-length');\n\n// `LengthOfArrayLike` abstract operation\n// https://tc39.es/ecma262/#sec-lengthofarraylike\nmodule.exports = function (obj) {\n return toLength(obj.length);\n};\n","/* eslint-disable es/no-symbol -- required for testing */\nvar V8_VERSION = require('../internals/engine-v8-version');\nvar fails = require('../internals/fails');\n\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n var symbol = Symbol();\n // Chrome 38 Symbol has incorrect toString conversion\n // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances\n return !String(symbol) || !(Object(symbol) instanceof Symbol) ||\n // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances\n !Symbol.sham && V8_VERSION && V8_VERSION < 41;\n});\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar inspectSource = require('../internals/inspect-source');\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = isCallable(WeakMap) && /native code/.test(inspectSource(WeakMap));\n","var toString = require('../internals/to-string');\n\nmodule.exports = function (argument, $default) {\n return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);\n};\n","var global = require('../internals/global');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar anObject = require('../internals/an-object');\nvar toPropertyKey = require('../internals/to-property-key');\n\nvar TypeError = global.TypeError;\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar $defineProperty = Object.defineProperty;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar ENUMERABLE = 'enumerable';\nvar CONFIGURABLE = 'configurable';\nvar WRITABLE = 'writable';\n\n// `Object.defineProperty` method\n// https://tc39.es/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {\n var current = $getOwnPropertyDescriptor(O, P);\n if (current && current[WRITABLE]) {\n O[P] = Attributes.value;\n Attributes = {\n configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],\n enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],\n writable: false\n };\n }\n } return $defineProperty(O, P, Attributes);\n} : $defineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return $defineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar call = require('../internals/function-call');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar hasOwn = require('../internals/has-own-property');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\n\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPropertyKey(P);\n if (IE8_DOM_DEFINE) try {\n return $getOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);\n};\n","var internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.es/ecma262/#sec-object.getownpropertynames\n// eslint-disable-next-line es/no-object-getownpropertynames -- safe\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n","// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe\nexports.f = Object.getOwnPropertySymbols;\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis({}.isPrototypeOf);\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar indexOf = require('../internals/array-includes').indexOf;\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (hasOwn(O, key = names[i++])) {\n ~indexOf(result, key) || push(result, key);\n }\n return result;\n};\n","'use strict';\nvar $propertyIsEnumerable = {}.propertyIsEnumerable;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : $propertyIsEnumerable;\n","/* eslint-disable no-proto -- safe */\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar anObject = require('../internals/an-object');\nvar aPossiblePrototype = require('../internals/a-possible-prototype');\n\n// `Object.setPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n// eslint-disable-next-line es/no-object-setprototypeof -- safe\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n setter = uncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\n\nvar TypeError = global.TypeError;\n\n// `OrdinaryToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-ordinarytoprimitive\nmodule.exports = function (input, pref) {\n var fn, val;\n if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;\n if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n throw TypeError(\"Can't convert object to primitive value\");\n};\n","var getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar anObject = require('../internals/an-object');\n\nvar concat = uncurryThis([].concat);\n\n// all object keys, includes non-enumerable and symbols\nmodule.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {\n var keys = getOwnPropertyNamesModule.f(anObject(it));\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar hasOwn = require('../internals/has-own-property');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar setGlobal = require('../internals/set-global');\nvar inspectSource = require('../internals/inspect-source');\nvar InternalStateModule = require('../internals/internal-state');\nvar CONFIGURABLE_FUNCTION_NAME = require('../internals/function-name').CONFIGURABLE;\n\nvar getInternalState = InternalStateModule.get;\nvar enforceInternalState = InternalStateModule.enforce;\nvar TEMPLATE = String(String).split('String');\n\n(module.exports = function (O, key, value, options) {\n var unsafe = options ? !!options.unsafe : false;\n var simple = options ? !!options.enumerable : false;\n var noTargetGet = options ? !!options.noTargetGet : false;\n var name = options && options.name !== undefined ? options.name : key;\n var state;\n if (isCallable(value)) {\n if (String(name).slice(0, 7) === 'Symbol(') {\n name = '[' + String(name).replace(/^Symbol\\(([^)]*)\\)/, '$1') + ']';\n }\n if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {\n createNonEnumerableProperty(value, 'name', name);\n }\n state = enforceInternalState(value);\n if (!state.source) {\n state.source = TEMPLATE.join(typeof name == 'string' ? name : '');\n }\n }\n if (O === global) {\n if (simple) O[key] = value;\n else setGlobal(key, value);\n return;\n } else if (!unsafe) {\n delete O[key];\n } else if (!noTargetGet && O[key]) {\n simple = true;\n }\n if (simple) O[key] = value;\n else createNonEnumerableProperty(O, key, value);\n// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n})(Function.prototype, 'toString', function toString() {\n return isCallable(this) && getInternalState(this).source || inspectSource(this);\n});\n","var global = require('../internals/global');\n\nvar TypeError = global.TypeError;\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.es/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (it == undefined) throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n","var global = require('../internals/global');\n\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar defineProperty = Object.defineProperty;\n\nmodule.exports = function (key, value) {\n try {\n defineProperty(global, key, { value: value, configurable: true, writable: true });\n } catch (error) {\n global[key] = value;\n } return value;\n};\n","var shared = require('../internals/shared');\nvar uid = require('../internals/uid');\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n","var global = require('../internals/global');\nvar setGlobal = require('../internals/set-global');\n\nvar SHARED = '__core-js_shared__';\nvar store = global[SHARED] || setGlobal(SHARED, {});\n\nmodule.exports = store;\n","var IS_PURE = require('../internals/is-pure');\nvar store = require('../internals/shared-store');\n\n(module.exports = function (key, value) {\n return store[key] || (store[key] = value !== undefined ? value : {});\n})('versions', []).push({\n version: '3.20.2',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2022 Denis Pushkarev (zloirock.ru)'\n});\n","var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toIntegerOrInfinity(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n","// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = require('../internals/indexed-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n","var ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `ToIntegerOrInfinity` abstract operation\n// https://tc39.es/ecma262/#sec-tointegerorinfinity\nmodule.exports = function (argument) {\n var number = +argument;\n // eslint-disable-next-line no-self-compare -- safe\n return number !== number || number === 0 ? 0 : (number > 0 ? floor : ceil)(number);\n};\n","var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.es/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n return argument > 0 ? min(toIntegerOrInfinity(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n","var global = require('../internals/global');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar Object = global.Object;\n\n// `ToObject` abstract operation\n// https://tc39.es/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return Object(requireObjectCoercible(argument));\n};\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar isObject = require('../internals/is-object');\nvar isSymbol = require('../internals/is-symbol');\nvar getMethod = require('../internals/get-method');\nvar ordinaryToPrimitive = require('../internals/ordinary-to-primitive');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TypeError = global.TypeError;\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n// `ToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-toprimitive\nmodule.exports = function (input, pref) {\n if (!isObject(input) || isSymbol(input)) return input;\n var exoticToPrim = getMethod(input, TO_PRIMITIVE);\n var result;\n if (exoticToPrim) {\n if (pref === undefined) pref = 'default';\n result = call(exoticToPrim, input, pref);\n if (!isObject(result) || isSymbol(result)) return result;\n throw TypeError(\"Can't convert object to primitive value\");\n }\n if (pref === undefined) pref = 'number';\n return ordinaryToPrimitive(input, pref);\n};\n","var toPrimitive = require('../internals/to-primitive');\nvar isSymbol = require('../internals/is-symbol');\n\n// `ToPropertyKey` abstract operation\n// https://tc39.es/ecma262/#sec-topropertykey\nmodule.exports = function (argument) {\n var key = toPrimitive(argument, 'string');\n return isSymbol(key) ? key : key + '';\n};\n","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n","var global = require('../internals/global');\nvar classof = require('../internals/classof');\n\nvar String = global.String;\n\nmodule.exports = function (argument) {\n if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');\n return String(argument);\n};\n","var global = require('../internals/global');\n\nvar String = global.String;\n\nmodule.exports = function (argument) {\n try {\n return String(argument);\n } catch (error) {\n return 'Object';\n }\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar id = 0;\nvar postfix = Math.random();\nvar toString = uncurryThis(1.0.toString);\n\nmodule.exports = function (key) {\n return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);\n};\n","/* eslint-disable es/no-symbol -- required for testing */\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\n\nmodule.exports = NATIVE_SYMBOL\n && !Symbol.sham\n && typeof Symbol.iterator == 'symbol';\n","var DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\n\n// V8 ~ Chrome 36-\n// https://bugs.chromium.org/p/v8/issues/detail?id=3334\nmodule.exports = DESCRIPTORS && fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(function () { /* empty */ }, 'prototype', {\n value: 42,\n writable: false\n }).prototype != 42;\n});\n","var global = require('../internals/global');\nvar shared = require('../internals/shared');\nvar hasOwn = require('../internals/has-own-property');\nvar uid = require('../internals/uid');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar WellKnownSymbolsStore = shared('wks');\nvar Symbol = global.Symbol;\nvar symbolFor = Symbol && Symbol['for'];\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!hasOwn(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {\n var description = 'Symbol.' + name;\n if (NATIVE_SYMBOL && hasOwn(Symbol, name)) {\n WellKnownSymbolsStore[name] = Symbol[name];\n } else if (USE_SYMBOL_AS_UID && symbolFor) {\n WellKnownSymbolsStore[name] = symbolFor(description);\n } else {\n WellKnownSymbolsStore[name] = createWellKnownSymbol(description);\n }\n } return WellKnownSymbolsStore[name];\n};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar hasOwn = require('../internals/has-own-property');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\nvar inheritIfRequired = require('../internals/inherit-if-required');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\nvar installErrorCause = require('../internals/install-error-cause');\nvar clearErrorStack = require('../internals/clear-error-stack');\nvar ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable');\nvar IS_PURE = require('../internals/is-pure');\n\nmodule.exports = function (FULL_NAME, wrapper, FORCED, IS_AGGREGATE_ERROR) {\n var OPTIONS_POSITION = IS_AGGREGATE_ERROR ? 2 : 1;\n var path = FULL_NAME.split('.');\n var ERROR_NAME = path[path.length - 1];\n var OriginalError = getBuiltIn.apply(null, path);\n\n if (!OriginalError) return;\n\n var OriginalErrorPrototype = OriginalError.prototype;\n\n // V8 9.3- bug https://bugs.chromium.org/p/v8/issues/detail?id=12006\n if (!IS_PURE && hasOwn(OriginalErrorPrototype, 'cause')) delete OriginalErrorPrototype.cause;\n\n if (!FORCED) return OriginalError;\n\n var BaseError = getBuiltIn('Error');\n\n var WrappedError = wrapper(function (a, b) {\n var message = normalizeStringArgument(IS_AGGREGATE_ERROR ? b : a, undefined);\n var result = IS_AGGREGATE_ERROR ? new OriginalError(a) : new OriginalError();\n if (message !== undefined) createNonEnumerableProperty(result, 'message', message);\n if (ERROR_STACK_INSTALLABLE) createNonEnumerableProperty(result, 'stack', clearErrorStack(result.stack, 2));\n if (this && isPrototypeOf(OriginalErrorPrototype, this)) inheritIfRequired(result, this, WrappedError);\n if (arguments.length > OPTIONS_POSITION) installErrorCause(result, arguments[OPTIONS_POSITION]);\n return result;\n });\n\n WrappedError.prototype = OriginalErrorPrototype;\n\n if (ERROR_NAME !== 'Error') {\n if (setPrototypeOf) setPrototypeOf(WrappedError, BaseError);\n else copyConstructorProperties(WrappedError, BaseError, { name: true });\n }\n\n copyConstructorProperties(WrappedError, OriginalError);\n\n if (!IS_PURE) try {\n // Safari 13- bug: WebAssembly errors does not have a proper `.name`\n if (OriginalErrorPrototype.name !== ERROR_NAME) {\n createNonEnumerableProperty(OriginalErrorPrototype, 'name', ERROR_NAME);\n }\n OriginalErrorPrototype.constructor = WrappedError;\n } catch (error) { /* empty */ }\n\n return WrappedError;\n};\n","/* eslint-disable no-unused-vars -- required for functions `.length` */\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar apply = require('../internals/function-apply');\nvar wrapErrorConstructorWithCause = require('../internals/wrap-error-constructor-with-cause');\n\nvar WEB_ASSEMBLY = 'WebAssembly';\nvar WebAssembly = global[WEB_ASSEMBLY];\n\nvar FORCED = Error('e', { cause: 7 }).cause !== 7;\n\nvar exportGlobalErrorCauseWrapper = function (ERROR_NAME, wrapper) {\n var O = {};\n O[ERROR_NAME] = wrapErrorConstructorWithCause(ERROR_NAME, wrapper, FORCED);\n $({ global: true, forced: FORCED }, O);\n};\n\nvar exportWebAssemblyErrorCauseWrapper = function (ERROR_NAME, wrapper) {\n if (WebAssembly && WebAssembly[ERROR_NAME]) {\n var O = {};\n O[ERROR_NAME] = wrapErrorConstructorWithCause(WEB_ASSEMBLY + '.' + ERROR_NAME, wrapper, FORCED);\n $({ target: WEB_ASSEMBLY, stat: true, forced: FORCED }, O);\n }\n};\n\n// https://github.com/tc39/proposal-error-cause\nexportGlobalErrorCauseWrapper('Error', function (init) {\n return function Error(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('EvalError', function (init) {\n return function EvalError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('RangeError', function (init) {\n return function RangeError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('ReferenceError', function (init) {\n return function ReferenceError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('SyntaxError', function (init) {\n return function SyntaxError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('TypeError', function (init) {\n return function TypeError(message) { return apply(init, this, arguments); };\n});\nexportGlobalErrorCauseWrapper('URIError', function (init) {\n return function URIError(message) { return apply(init, this, arguments); };\n});\nexportWebAssemblyErrorCauseWrapper('CompileError', function (init) {\n return function CompileError(message) { return apply(init, this, arguments); };\n});\nexportWebAssemblyErrorCauseWrapper('LinkError', function (init) {\n return function LinkError(message) { return apply(init, this, arguments); };\n});\nexportWebAssemblyErrorCauseWrapper('RuntimeError', function (init) {\n return function RuntimeError(message) { return apply(init, this, arguments); };\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar getBuiltIn = require('../internals/get-built-in');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar defineProperty = require('../internals/object-define-property').f;\nvar hasOwn = require('../internals/has-own-property');\nvar anInstance = require('../internals/an-instance');\nvar inheritIfRequired = require('../internals/inherit-if-required');\nvar normalizeStringArgument = require('../internals/normalize-string-argument');\nvar DOMExceptionConstants = require('../internals/dom-exception-constants');\nvar clearErrorStack = require('../internals/clear-error-stack');\nvar IS_PURE = require('../internals/is-pure');\n\nvar DOM_EXCEPTION = 'DOMException';\nvar Error = getBuiltIn('Error');\nvar NativeDOMException = getBuiltIn(DOM_EXCEPTION);\n\nvar $DOMException = function DOMException() {\n anInstance(this, DOMExceptionPrototype);\n var argumentsLength = arguments.length;\n var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]);\n var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error');\n var that = new NativeDOMException(message, name);\n var error = Error(message);\n error.name = DOM_EXCEPTION;\n defineProperty(that, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1)));\n inheritIfRequired(that, this, $DOMException);\n return that;\n};\n\nvar DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototype;\n\nvar ERROR_HAS_STACK = 'stack' in Error(DOM_EXCEPTION);\nvar DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2);\nvar FORCED_CONSTRUCTOR = ERROR_HAS_STACK && !DOM_EXCEPTION_HAS_STACK;\n\n// `DOMException` constructor patch for `.stack` where it's required\n// https://webidl.spec.whatwg.org/#es-DOMException-specialness\n$({ global: true, forced: IS_PURE || FORCED_CONSTRUCTOR }, { // TODO: fix export logic\n DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException\n});\n\nvar PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION);\nvar PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype;\n\nif (PolyfilledDOMExceptionPrototype.constructor !== PolyfilledDOMException) {\n if (!IS_PURE) {\n defineProperty(PolyfilledDOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, PolyfilledDOMException));\n }\n\n for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) {\n var constant = DOMExceptionConstants[key];\n var constantName = constant.s;\n if (!hasOwn(PolyfilledDOMException, constantName)) {\n defineProperty(PolyfilledDOMException, constantName, createPropertyDescriptor(6, constant.c));\n }\n }\n}\n","'use strict';\n\nmodule.exports = earcut;\nmodule.exports.default = earcut;\n\nfunction earcut(data, holeIndices, dim) {\n\n dim = dim || 2;\n\n var hasHoles = holeIndices && holeIndices.length,\n outerLen = hasHoles ? holeIndices[0] * dim : data.length,\n outerNode = linkedList(data, 0, outerLen, dim, true),\n triangles = [];\n\n if (!outerNode || outerNode.next === outerNode.prev) return triangles;\n\n var minX, minY, maxX, maxY, x, y, invSize;\n\n if (hasHoles) outerNode = eliminateHoles(data, holeIndices, outerNode, dim);\n\n // if the shape is not too simple, we'll use z-order curve hash later; calculate polygon bbox\n if (data.length > 80 * dim) {\n minX = maxX = data[0];\n minY = maxY = data[1];\n\n for (var i = dim; i < outerLen; i += dim) {\n x = data[i];\n y = data[i + 1];\n if (x < minX) minX = x;\n if (y < minY) minY = y;\n if (x > maxX) maxX = x;\n if (y > maxY) maxY = y;\n }\n\n // minX, minY and invSize are later used to transform coords into integers for z-order calculation\n invSize = Math.max(maxX - minX, maxY - minY);\n invSize = invSize !== 0 ? 1 / invSize : 0;\n }\n\n earcutLinked(outerNode, triangles, dim, minX, minY, invSize);\n\n return triangles;\n}\n\n// create a circular doubly linked list from polygon points in the specified winding order\nfunction linkedList(data, start, end, dim, clockwise) {\n var i, last;\n\n if (clockwise === (signedArea(data, start, end, dim) > 0)) {\n for (i = start; i < end; i += dim) last = insertNode(i, data[i], data[i + 1], last);\n } else {\n for (i = end - dim; i >= start; i -= dim) last = insertNode(i, data[i], data[i + 1], last);\n }\n\n if (last && equals(last, last.next)) {\n removeNode(last);\n last = last.next;\n }\n\n return last;\n}\n\n// eliminate colinear or duplicate points\nfunction filterPoints(start, end) {\n if (!start) return start;\n if (!end) end = start;\n\n var p = start,\n again;\n do {\n again = false;\n\n if (!p.steiner && (equals(p, p.next) || area(p.prev, p, p.next) === 0)) {\n removeNode(p);\n p = end = p.prev;\n if (p === p.next) break;\n again = true;\n\n } else {\n p = p.next;\n }\n } while (again || p !== end);\n\n return end;\n}\n\n// main ear slicing loop which triangulates a polygon (given as a linked list)\nfunction earcutLinked(ear, triangles, dim, minX, minY, invSize, pass) {\n if (!ear) return;\n\n // interlink polygon nodes in z-order\n if (!pass && invSize) indexCurve(ear, minX, minY, invSize);\n\n var stop = ear,\n prev, next;\n\n // iterate through ears, slicing them one by one\n while (ear.prev !== ear.next) {\n prev = ear.prev;\n next = ear.next;\n\n if (invSize ? isEarHashed(ear, minX, minY, invSize) : isEar(ear)) {\n // cut off the triangle\n triangles.push(prev.i / dim);\n triangles.push(ear.i / dim);\n triangles.push(next.i / dim);\n\n removeNode(ear);\n\n // skipping the next vertex leads to less sliver triangles\n ear = next.next;\n stop = next.next;\n\n continue;\n }\n\n ear = next;\n\n // if we looped through the whole remaining polygon and can't find any more ears\n if (ear === stop) {\n // try filtering points and slicing again\n if (!pass) {\n earcutLinked(filterPoints(ear), triangles, dim, minX, minY, invSize, 1);\n\n // if this didn't work, try curing all small self-intersections locally\n } else if (pass === 1) {\n ear = cureLocalIntersections(filterPoints(ear), triangles, dim);\n earcutLinked(ear, triangles, dim, minX, minY, invSize, 2);\n\n // as a last resort, try splitting the remaining polygon into two\n } else if (pass === 2) {\n splitEarcut(ear, triangles, dim, minX, minY, invSize);\n }\n\n break;\n }\n }\n}\n\n// check whether a polygon node forms a valid ear with adjacent nodes\nfunction isEar(ear) {\n var a = ear.prev,\n b = ear,\n c = ear.next;\n\n if (area(a, b, c) >= 0) return false; // reflex, can't be an ear\n\n // now make sure we don't have other points inside the potential ear\n var p = ear.next.next;\n\n while (p !== ear.prev) {\n if (pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) &&\n area(p.prev, p, p.next) >= 0) return false;\n p = p.next;\n }\n\n return true;\n}\n\nfunction isEarHashed(ear, minX, minY, invSize) {\n var a = ear.prev,\n b = ear,\n c = ear.next;\n\n if (area(a, b, c) >= 0) return false; // reflex, can't be an ear\n\n // triangle bbox; min & max are calculated like this for speed\n var minTX = a.x < b.x ? (a.x < c.x ? a.x : c.x) : (b.x < c.x ? b.x : c.x),\n minTY = a.y < b.y ? (a.y < c.y ? a.y : c.y) : (b.y < c.y ? b.y : c.y),\n maxTX = a.x > b.x ? (a.x > c.x ? a.x : c.x) : (b.x > c.x ? b.x : c.x),\n maxTY = a.y > b.y ? (a.y > c.y ? a.y : c.y) : (b.y > c.y ? b.y : c.y);\n\n // z-order range for the current triangle bbox;\n var minZ = zOrder(minTX, minTY, minX, minY, invSize),\n maxZ = zOrder(maxTX, maxTY, minX, minY, invSize);\n\n var p = ear.prevZ,\n n = ear.nextZ;\n\n // look for points inside the triangle in both directions\n while (p && p.z >= minZ && n && n.z <= maxZ) {\n if (p !== ear.prev && p !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) &&\n area(p.prev, p, p.next) >= 0) return false;\n p = p.prevZ;\n\n if (n !== ear.prev && n !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, n.x, n.y) &&\n area(n.prev, n, n.next) >= 0) return false;\n n = n.nextZ;\n }\n\n // look for remaining points in decreasing z-order\n while (p && p.z >= minZ) {\n if (p !== ear.prev && p !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, p.x, p.y) &&\n area(p.prev, p, p.next) >= 0) return false;\n p = p.prevZ;\n }\n\n // look for remaining points in increasing z-order\n while (n && n.z <= maxZ) {\n if (n !== ear.prev && n !== ear.next &&\n pointInTriangle(a.x, a.y, b.x, b.y, c.x, c.y, n.x, n.y) &&\n area(n.prev, n, n.next) >= 0) return false;\n n = n.nextZ;\n }\n\n return true;\n}\n\n// go through all polygon nodes and cure small local self-intersections\nfunction cureLocalIntersections(start, triangles, dim) {\n var p = start;\n do {\n var a = p.prev,\n b = p.next.next;\n\n if (!equals(a, b) && intersects(a, p, p.next, b) && locallyInside(a, b) && locallyInside(b, a)) {\n\n triangles.push(a.i / dim);\n triangles.push(p.i / dim);\n triangles.push(b.i / dim);\n\n // remove two nodes involved\n removeNode(p);\n removeNode(p.next);\n\n p = start = b;\n }\n p = p.next;\n } while (p !== start);\n\n return filterPoints(p);\n}\n\n// try splitting polygon into two and triangulate them independently\nfunction splitEarcut(start, triangles, dim, minX, minY, invSize) {\n // look for a valid diagonal that divides the polygon into two\n var a = start;\n do {\n var b = a.next.next;\n while (b !== a.prev) {\n if (a.i !== b.i && isValidDiagonal(a, b)) {\n // split the polygon in two by the diagonal\n var c = splitPolygon(a, b);\n\n // filter colinear points around the cuts\n a = filterPoints(a, a.next);\n c = filterPoints(c, c.next);\n\n // run earcut on each half\n earcutLinked(a, triangles, dim, minX, minY, invSize);\n earcutLinked(c, triangles, dim, minX, minY, invSize);\n return;\n }\n b = b.next;\n }\n a = a.next;\n } while (a !== start);\n}\n\n// link every hole into the outer loop, producing a single-ring polygon without holes\nfunction eliminateHoles(data, holeIndices, outerNode, dim) {\n var queue = [],\n i, len, start, end, list;\n\n for (i = 0, len = holeIndices.length; i < len; i++) {\n start = holeIndices[i] * dim;\n end = i < len - 1 ? holeIndices[i + 1] * dim : data.length;\n list = linkedList(data, start, end, dim, false);\n if (list === list.next) list.steiner = true;\n queue.push(getLeftmost(list));\n }\n\n queue.sort(compareX);\n\n // process holes from left to right\n for (i = 0; i < queue.length; i++) {\n outerNode = eliminateHole(queue[i], outerNode);\n outerNode = filterPoints(outerNode, outerNode.next);\n }\n\n return outerNode;\n}\n\nfunction compareX(a, b) {\n return a.x - b.x;\n}\n\n// find a bridge between vertices that connects hole with an outer ring and and link it\nfunction eliminateHole(hole, outerNode) {\n var bridge = findHoleBridge(hole, outerNode);\n if (!bridge) {\n return outerNode;\n }\n\n var bridgeReverse = splitPolygon(bridge, hole);\n\n // filter collinear points around the cuts\n var filteredBridge = filterPoints(bridge, bridge.next);\n filterPoints(bridgeReverse, bridgeReverse.next);\n\n // Check if input node was removed by the filtering\n return outerNode === bridge ? filteredBridge : outerNode;\n}\n\n// David Eberly's algorithm for finding a bridge between hole and outer polygon\nfunction findHoleBridge(hole, outerNode) {\n var p = outerNode,\n hx = hole.x,\n hy = hole.y,\n qx = -Infinity,\n m;\n\n // find a segment intersected by a ray from the hole's leftmost point to the left;\n // segment's endpoint with lesser x will be potential connection point\n do {\n if (hy <= p.y && hy >= p.next.y && p.next.y !== p.y) {\n var x = p.x + (hy - p.y) * (p.next.x - p.x) / (p.next.y - p.y);\n if (x <= hx && x > qx) {\n qx = x;\n if (x === hx) {\n if (hy === p.y) return p;\n if (hy === p.next.y) return p.next;\n }\n m = p.x < p.next.x ? p : p.next;\n }\n }\n p = p.next;\n } while (p !== outerNode);\n\n if (!m) return null;\n\n if (hx === qx) return m; // hole touches outer segment; pick leftmost endpoint\n\n // look for points inside the triangle of hole point, segment intersection and endpoint;\n // if there are no points found, we have a valid connection;\n // otherwise choose the point of the minimum angle with the ray as connection point\n\n var stop = m,\n mx = m.x,\n my = m.y,\n tanMin = Infinity,\n tan;\n\n p = m;\n\n do {\n if (hx >= p.x && p.x >= mx && hx !== p.x &&\n pointInTriangle(hy < my ? hx : qx, hy, mx, my, hy < my ? qx : hx, hy, p.x, p.y)) {\n\n tan = Math.abs(hy - p.y) / (hx - p.x); // tangential\n\n if (locallyInside(p, hole) &&\n (tan < tanMin || (tan === tanMin && (p.x > m.x || (p.x === m.x && sectorContainsSector(m, p)))))) {\n m = p;\n tanMin = tan;\n }\n }\n\n p = p.next;\n } while (p !== stop);\n\n return m;\n}\n\n// whether sector in vertex m contains sector in vertex p in the same coordinates\nfunction sectorContainsSector(m, p) {\n return area(m.prev, m, p.prev) < 0 && area(p.next, m, m.next) < 0;\n}\n\n// interlink polygon nodes in z-order\nfunction indexCurve(start, minX, minY, invSize) {\n var p = start;\n do {\n if (p.z === null) p.z = zOrder(p.x, p.y, minX, minY, invSize);\n p.prevZ = p.prev;\n p.nextZ = p.next;\n p = p.next;\n } while (p !== start);\n\n p.prevZ.nextZ = null;\n p.prevZ = null;\n\n sortLinked(p);\n}\n\n// Simon Tatham's linked list merge sort algorithm\n// http://www.chiark.greenend.org.uk/~sgtatham/algorithms/listsort.html\nfunction sortLinked(list) {\n var i, p, q, e, tail, numMerges, pSize, qSize,\n inSize = 1;\n\n do {\n p = list;\n list = null;\n tail = null;\n numMerges = 0;\n\n while (p) {\n numMerges++;\n q = p;\n pSize = 0;\n for (i = 0; i < inSize; i++) {\n pSize++;\n q = q.nextZ;\n if (!q) break;\n }\n qSize = inSize;\n\n while (pSize > 0 || (qSize > 0 && q)) {\n\n if (pSize !== 0 && (qSize === 0 || !q || p.z <= q.z)) {\n e = p;\n p = p.nextZ;\n pSize--;\n } else {\n e = q;\n q = q.nextZ;\n qSize--;\n }\n\n if (tail) tail.nextZ = e;\n else list = e;\n\n e.prevZ = tail;\n tail = e;\n }\n\n p = q;\n }\n\n tail.nextZ = null;\n inSize *= 2;\n\n } while (numMerges > 1);\n\n return list;\n}\n\n// z-order of a point given coords and inverse of the longer side of data bbox\nfunction zOrder(x, y, minX, minY, invSize) {\n // coords are transformed into non-negative 15-bit integer range\n x = 32767 * (x - minX) * invSize;\n y = 32767 * (y - minY) * invSize;\n\n x = (x | (x << 8)) & 0x00FF00FF;\n x = (x | (x << 4)) & 0x0F0F0F0F;\n x = (x | (x << 2)) & 0x33333333;\n x = (x | (x << 1)) & 0x55555555;\n\n y = (y | (y << 8)) & 0x00FF00FF;\n y = (y | (y << 4)) & 0x0F0F0F0F;\n y = (y | (y << 2)) & 0x33333333;\n y = (y | (y << 1)) & 0x55555555;\n\n return x | (y << 1);\n}\n\n// find the leftmost node of a polygon ring\nfunction getLeftmost(start) {\n var p = start,\n leftmost = start;\n do {\n if (p.x < leftmost.x || (p.x === leftmost.x && p.y < leftmost.y)) leftmost = p;\n p = p.next;\n } while (p !== start);\n\n return leftmost;\n}\n\n// check if a point lies within a convex triangle\nfunction pointInTriangle(ax, ay, bx, by, cx, cy, px, py) {\n return (cx - px) * (ay - py) - (ax - px) * (cy - py) >= 0 &&\n (ax - px) * (by - py) - (bx - px) * (ay - py) >= 0 &&\n (bx - px) * (cy - py) - (cx - px) * (by - py) >= 0;\n}\n\n// check if a diagonal between two polygon nodes is valid (lies in polygon interior)\nfunction isValidDiagonal(a, b) {\n return a.next.i !== b.i && a.prev.i !== b.i && !intersectsPolygon(a, b) && // dones't intersect other edges\n (locallyInside(a, b) && locallyInside(b, a) && middleInside(a, b) && // locally visible\n (area(a.prev, a, b.prev) || area(a, b.prev, b)) || // does not create opposite-facing sectors\n equals(a, b) && area(a.prev, a, a.next) > 0 && area(b.prev, b, b.next) > 0); // special zero-length case\n}\n\n// signed area of a triangle\nfunction area(p, q, r) {\n return (q.y - p.y) * (r.x - q.x) - (q.x - p.x) * (r.y - q.y);\n}\n\n// check if two points are equal\nfunction equals(p1, p2) {\n return p1.x === p2.x && p1.y === p2.y;\n}\n\n// check if two segments intersect\nfunction intersects(p1, q1, p2, q2) {\n var o1 = sign(area(p1, q1, p2));\n var o2 = sign(area(p1, q1, q2));\n var o3 = sign(area(p2, q2, p1));\n var o4 = sign(area(p2, q2, q1));\n\n if (o1 !== o2 && o3 !== o4) return true; // general case\n\n if (o1 === 0 && onSegment(p1, p2, q1)) return true; // p1, q1 and p2 are collinear and p2 lies on p1q1\n if (o2 === 0 && onSegment(p1, q2, q1)) return true; // p1, q1 and q2 are collinear and q2 lies on p1q1\n if (o3 === 0 && onSegment(p2, p1, q2)) return true; // p2, q2 and p1 are collinear and p1 lies on p2q2\n if (o4 === 0 && onSegment(p2, q1, q2)) return true; // p2, q2 and q1 are collinear and q1 lies on p2q2\n\n return false;\n}\n\n// for collinear points p, q, r, check if point q lies on segment pr\nfunction onSegment(p, q, r) {\n return q.x <= Math.max(p.x, r.x) && q.x >= Math.min(p.x, r.x) && q.y <= Math.max(p.y, r.y) && q.y >= Math.min(p.y, r.y);\n}\n\nfunction sign(num) {\n return num > 0 ? 1 : num < 0 ? -1 : 0;\n}\n\n// check if a polygon diagonal intersects any polygon segments\nfunction intersectsPolygon(a, b) {\n var p = a;\n do {\n if (p.i !== a.i && p.next.i !== a.i && p.i !== b.i && p.next.i !== b.i &&\n intersects(p, p.next, a, b)) return true;\n p = p.next;\n } while (p !== a);\n\n return false;\n}\n\n// check if a polygon diagonal is locally inside the polygon\nfunction locallyInside(a, b) {\n return area(a.prev, a, a.next) < 0 ?\n area(a, b, a.next) >= 0 && area(a, a.prev, b) >= 0 :\n area(a, b, a.prev) < 0 || area(a, a.next, b) < 0;\n}\n\n// check if the middle point of a polygon diagonal is inside the polygon\nfunction middleInside(a, b) {\n var p = a,\n inside = false,\n px = (a.x + b.x) / 2,\n py = (a.y + b.y) / 2;\n do {\n if (((p.y > py) !== (p.next.y > py)) && p.next.y !== p.y &&\n (px < (p.next.x - p.x) * (py - p.y) / (p.next.y - p.y) + p.x))\n inside = !inside;\n p = p.next;\n } while (p !== a);\n\n return inside;\n}\n\n// link two polygon vertices with a bridge; if the vertices belong to the same ring, it splits polygon into two;\n// if one belongs to the outer ring and another to a hole, it merges it into a single ring\nfunction splitPolygon(a, b) {\n var a2 = new Node(a.i, a.x, a.y),\n b2 = new Node(b.i, b.x, b.y),\n an = a.next,\n bp = b.prev;\n\n a.next = b;\n b.prev = a;\n\n a2.next = an;\n an.prev = a2;\n\n b2.next = a2;\n a2.prev = b2;\n\n bp.next = b2;\n b2.prev = bp;\n\n return b2;\n}\n\n// create a node and optionally link it with previous one (in a circular doubly linked list)\nfunction insertNode(i, x, y, last) {\n var p = new Node(i, x, y);\n\n if (!last) {\n p.prev = p;\n p.next = p;\n\n } else {\n p.next = last.next;\n p.prev = last;\n last.next.prev = p;\n last.next = p;\n }\n return p;\n}\n\nfunction removeNode(p) {\n p.next.prev = p.prev;\n p.prev.next = p.next;\n\n if (p.prevZ) p.prevZ.nextZ = p.nextZ;\n if (p.nextZ) p.nextZ.prevZ = p.prevZ;\n}\n\nfunction Node(i, x, y) {\n // vertex index in coordinates array\n this.i = i;\n\n // vertex coordinates\n this.x = x;\n this.y = y;\n\n // previous and next vertex nodes in a polygon ring\n this.prev = null;\n this.next = null;\n\n // z-order curve value\n this.z = null;\n\n // previous and next nodes in z-order\n this.prevZ = null;\n this.nextZ = null;\n\n // indicates whether this is a steiner point\n this.steiner = false;\n}\n\n// return a percentage difference between the polygon area and its triangulation area;\n// used to verify correctness of triangulation\nearcut.deviation = function (data, holeIndices, dim, triangles) {\n var hasHoles = holeIndices && holeIndices.length;\n var outerLen = hasHoles ? holeIndices[0] * dim : data.length;\n\n var polygonArea = Math.abs(signedArea(data, 0, outerLen, dim));\n if (hasHoles) {\n for (var i = 0, len = holeIndices.length; i < len; i++) {\n var start = holeIndices[i] * dim;\n var end = i < len - 1 ? holeIndices[i + 1] * dim : data.length;\n polygonArea -= Math.abs(signedArea(data, start, end, dim));\n }\n }\n\n var trianglesArea = 0;\n for (i = 0; i < triangles.length; i += 3) {\n var a = triangles[i] * dim;\n var b = triangles[i + 1] * dim;\n var c = triangles[i + 2] * dim;\n trianglesArea += Math.abs(\n (data[a] - data[c]) * (data[b + 1] - data[a + 1]) -\n (data[a] - data[b]) * (data[c + 1] - data[a + 1]));\n }\n\n return polygonArea === 0 && trianglesArea === 0 ? 0 :\n Math.abs((trianglesArea - polygonArea) / polygonArea);\n};\n\nfunction signedArea(data, start, end, dim) {\n var sum = 0;\n for (var i = start, j = end - dim; i < end; i += dim) {\n sum += (data[j] - data[i]) * (data[i + 1] + data[j + 1]);\n j = i;\n }\n return sum;\n}\n\n// turn a polygon in a multi-dimensional array form (e.g. as in GeoJSON) into a form Earcut accepts\nearcut.flatten = function (data) {\n var dim = data[0][0].length,\n result = {vertices: [], holes: [], dimensions: dim},\n holeIndex = 0;\n\n for (var i = 0; i < data.length; i++) {\n for (var j = 0; j < data[i].length; j++) {\n for (var d = 0; d < dim; d++) result.vertices.push(data[i][j][d]);\n }\n if (i > 0) {\n holeIndex += data[i - 1].length;\n result.holes.push(holeIndex);\n }\n }\n return result;\n};\n","// Copyright (c) 2013 Pieroxy <pieroxy@pieroxy.net>\n// This work is free. You can redistribute it and/or modify it\n// under the terms of the WTFPL, Version 2\n// For more information see LICENSE.txt or http://www.wtfpl.net/\n//\n// For more information, the home page:\n// http://pieroxy.net/blog/pages/lz-string/testing.html\n//\n// LZ-based compression algorithm, version 1.4.4\nvar LZString = (function() {\n\n// private property\nvar f = String.fromCharCode;\nvar keyStrBase64 = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\";\nvar keyStrUriSafe = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$\";\nvar baseReverseDic = {};\n\nfunction getBaseValue(alphabet, character) {\n if (!baseReverseDic[alphabet]) {\n baseReverseDic[alphabet] = {};\n for (var i=0 ; i<alphabet.length ; i++) {\n baseReverseDic[alphabet][alphabet.charAt(i)] = i;\n }\n }\n return baseReverseDic[alphabet][character];\n}\n\nvar LZString = {\n compressToBase64 : function (input) {\n if (input == null) return \"\";\n var res = LZString._compress(input, 6, function(a){return keyStrBase64.charAt(a);});\n switch (res.length % 4) { // To produce valid Base64\n default: // When could this happen ?\n case 0 : return res;\n case 1 : return res+\"===\";\n case 2 : return res+\"==\";\n case 3 : return res+\"=\";\n }\n },\n\n decompressFromBase64 : function (input) {\n if (input == null) return \"\";\n if (input == \"\") return null;\n return LZString._decompress(input.length, 32, function(index) { return getBaseValue(keyStrBase64, input.charAt(index)); });\n },\n\n compressToUTF16 : function (input) {\n if (input == null) return \"\";\n return LZString._compress(input, 15, function(a){return f(a+32);}) + \" \";\n },\n\n decompressFromUTF16: function (compressed) {\n if (compressed == null) return \"\";\n if (compressed == \"\") return null;\n return LZString._decompress(compressed.length, 16384, function(index) { return compressed.charCodeAt(index) - 32; });\n },\n\n //compress into uint8array (UCS-2 big endian format)\n compressToUint8Array: function (uncompressed) {\n var compressed = LZString.compress(uncompressed);\n var buf=new Uint8Array(compressed.length*2); // 2 bytes per character\n\n for (var i=0, TotalLen=compressed.length; i<TotalLen; i++) {\n var current_value = compressed.charCodeAt(i);\n buf[i*2] = current_value >>> 8;\n buf[i*2+1] = current_value % 256;\n }\n return buf;\n },\n\n //decompress from uint8array (UCS-2 big endian format)\n decompressFromUint8Array:function (compressed) {\n if (compressed===null || compressed===undefined){\n return LZString.decompress(compressed);\n } else {\n var buf=new Array(compressed.length/2); // 2 bytes per character\n for (var i=0, TotalLen=buf.length; i<TotalLen; i++) {\n buf[i]=compressed[i*2]*256+compressed[i*2+1];\n }\n\n var result = [];\n buf.forEach(function (c) {\n result.push(f(c));\n });\n return LZString.decompress(result.join(''));\n\n }\n\n },\n\n\n //compress into a string that is already URI encoded\n compressToEncodedURIComponent: function (input) {\n if (input == null) return \"\";\n return LZString._compress(input, 6, function(a){return keyStrUriSafe.charAt(a);});\n },\n\n //decompress from an output of compressToEncodedURIComponent\n decompressFromEncodedURIComponent:function (input) {\n if (input == null) return \"\";\n if (input == \"\") return null;\n input = input.replace(/ /g, \"+\");\n return LZString._decompress(input.length, 32, function(index) { return getBaseValue(keyStrUriSafe, input.charAt(index)); });\n },\n\n compress: function (uncompressed) {\n return LZString._compress(uncompressed, 16, function(a){return f(a);});\n },\n _compress: function (uncompressed, bitsPerChar, getCharFromInt) {\n if (uncompressed == null) return \"\";\n var i, value,\n context_dictionary= {},\n context_dictionaryToCreate= {},\n context_c=\"\",\n context_wc=\"\",\n context_w=\"\",\n context_enlargeIn= 2, // Compensate for the first entry which should not count\n context_dictSize= 3,\n context_numBits= 2,\n context_data=[],\n context_data_val=0,\n context_data_position=0,\n ii;\n\n for (ii = 0; ii < uncompressed.length; ii += 1) {\n context_c = uncompressed.charAt(ii);\n if (!Object.prototype.hasOwnProperty.call(context_dictionary,context_c)) {\n context_dictionary[context_c] = context_dictSize++;\n context_dictionaryToCreate[context_c] = true;\n }\n\n context_wc = context_w + context_c;\n if (Object.prototype.hasOwnProperty.call(context_dictionary,context_wc)) {\n context_w = context_wc;\n } else {\n if (Object.prototype.hasOwnProperty.call(context_dictionaryToCreate,context_w)) {\n if (context_w.charCodeAt(0)<256) {\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<8 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n } else {\n value = 1;\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | value;\n if (context_data_position ==bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = 0;\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<16 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n delete context_dictionaryToCreate[context_w];\n } else {\n value = context_dictionary[context_w];\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n\n\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n // Add wc to the dictionary.\n context_dictionary[context_wc] = context_dictSize++;\n context_w = String(context_c);\n }\n }\n\n // Output the code for w.\n if (context_w !== \"\") {\n if (Object.prototype.hasOwnProperty.call(context_dictionaryToCreate,context_w)) {\n if (context_w.charCodeAt(0)<256) {\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<8 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n } else {\n value = 1;\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | value;\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = 0;\n }\n value = context_w.charCodeAt(0);\n for (i=0 ; i<16 ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n delete context_dictionaryToCreate[context_w];\n } else {\n value = context_dictionary[context_w];\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n\n\n }\n context_enlargeIn--;\n if (context_enlargeIn == 0) {\n context_enlargeIn = Math.pow(2, context_numBits);\n context_numBits++;\n }\n }\n\n // Mark the end of the stream\n value = 2;\n for (i=0 ; i<context_numBits ; i++) {\n context_data_val = (context_data_val << 1) | (value&1);\n if (context_data_position == bitsPerChar-1) {\n context_data_position = 0;\n context_data.push(getCharFromInt(context_data_val));\n context_data_val = 0;\n } else {\n context_data_position++;\n }\n value = value >> 1;\n }\n\n // Flush the last char\n while (true) {\n context_data_val = (context_data_val << 1);\n if (context_data_position == bitsPerChar-1) {\n context_data.push(getCharFromInt(context_data_val));\n break;\n }\n else context_data_position++;\n }\n return context_data.join('');\n },\n\n decompress: function (compressed) {\n if (compressed == null) return \"\";\n if (compressed == \"\") return null;\n return LZString._decompress(compressed.length, 32768, function(index) { return compressed.charCodeAt(index); });\n },\n\n _decompress: function (length, resetValue, getNextValue) {\n var dictionary = [],\n next,\n enlargeIn = 4,\n dictSize = 4,\n numBits = 3,\n entry = \"\",\n result = [],\n i,\n w,\n bits, resb, maxpower, power,\n c,\n data = {val:getNextValue(0), position:resetValue, index:1};\n\n for (i = 0; i < 3; i += 1) {\n dictionary[i] = i;\n }\n\n bits = 0;\n maxpower = Math.pow(2,2);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n\n switch (next = bits) {\n case 0:\n bits = 0;\n maxpower = Math.pow(2,8);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n c = f(bits);\n break;\n case 1:\n bits = 0;\n maxpower = Math.pow(2,16);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n c = f(bits);\n break;\n case 2:\n return \"\";\n }\n dictionary[3] = c;\n w = c;\n result.push(c);\n while (true) {\n if (data.index > length) {\n return \"\";\n }\n\n bits = 0;\n maxpower = Math.pow(2,numBits);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n\n switch (c = bits) {\n case 0:\n bits = 0;\n maxpower = Math.pow(2,8);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n\n dictionary[dictSize++] = f(bits);\n c = dictSize-1;\n enlargeIn--;\n break;\n case 1:\n bits = 0;\n maxpower = Math.pow(2,16);\n power=1;\n while (power!=maxpower) {\n resb = data.val & data.position;\n data.position >>= 1;\n if (data.position == 0) {\n data.position = resetValue;\n data.val = getNextValue(data.index++);\n }\n bits |= (resb>0 ? 1 : 0) * power;\n power <<= 1;\n }\n dictionary[dictSize++] = f(bits);\n c = dictSize-1;\n enlargeIn--;\n break;\n case 2:\n return result.join('');\n }\n\n if (enlargeIn == 0) {\n enlargeIn = Math.pow(2, numBits);\n numBits++;\n }\n\n if (dictionary[c]) {\n entry = dictionary[c];\n } else {\n if (c === dictSize) {\n entry = w + w.charAt(0);\n } else {\n return null;\n }\n }\n result.push(entry);\n\n // Add w+entry[0] to the dictionary.\n dictionary[dictSize++] = w + entry.charAt(0);\n enlargeIn--;\n\n w = entry;\n\n if (enlargeIn == 0) {\n enlargeIn = Math.pow(2, numBits);\n numBits++;\n }\n\n }\n }\n};\n return LZString;\n})();\n\nif (typeof define === 'function' && define.amd) {\n define(function () { return LZString; });\n} else if( typeof module !== 'undefined' && module != null ) {\n module.exports = LZString\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * @this {Promise}\n */\nfunction finallyConstructor(callback) {\n var constructor = this.constructor;\n return this.then(\n function(value) {\n // @ts-ignore\n return constructor.resolve(callback()).then(function() {\n return value;\n });\n },\n function(reason) {\n // @ts-ignore\n return constructor.resolve(callback()).then(function() {\n // @ts-ignore\n return constructor.reject(reason);\n });\n }\n );\n}\n\nexport default finallyConstructor;\n","function allSettled(arr) {\n var P = this;\n return new P(function(resolve, reject) {\n if (!(arr && typeof arr.length !== 'undefined')) {\n return reject(\n new TypeError(\n typeof arr +\n ' ' +\n arr +\n ' is not iterable(cannot read property Symbol(Symbol.iterator))'\n )\n );\n }\n var args = Array.prototype.slice.call(arr);\n if (args.length === 0) return resolve([]);\n var remaining = args.length;\n\n function res(i, val) {\n if (val && (typeof val === 'object' || typeof val === 'function')) {\n var then = val.then;\n if (typeof then === 'function') {\n then.call(\n val,\n function(val) {\n res(i, val);\n },\n function(e) {\n args[i] = { status: 'rejected', reason: e };\n if (--remaining === 0) {\n resolve(args);\n }\n }\n );\n return;\n }\n }\n args[i] = { status: 'fulfilled', value: val };\n if (--remaining === 0) {\n resolve(args);\n }\n }\n\n for (var i = 0; i < args.length; i++) {\n res(i, args[i]);\n }\n });\n}\n\nexport default allSettled;\n","import promiseFinally from './finally';\nimport allSettled from './allSettled';\n\n// Store setTimeout reference so promise-polyfill will be unaffected by\n// other code modifying setTimeout (like sinon.useFakeTimers())\nvar setTimeoutFunc = setTimeout;\n\nfunction isArray(x) {\n return Boolean(x && typeof x.length !== 'undefined');\n}\n\nfunction noop() {}\n\n// Polyfill for Function.prototype.bind\nfunction bind(fn, thisArg) {\n return function() {\n fn.apply(thisArg, arguments);\n };\n}\n\n/**\n * @constructor\n * @param {Function} fn\n */\nfunction Promise(fn) {\n if (!(this instanceof Promise))\n throw new TypeError('Promises must be constructed via new');\n if (typeof fn !== 'function') throw new TypeError('not a function');\n /** @type {!number} */\n this._state = 0;\n /** @type {!boolean} */\n this._handled = false;\n /** @type {Promise|undefined} */\n this._value = undefined;\n /** @type {!Array<!Function>} */\n this._deferreds = [];\n\n doResolve(fn, this);\n}\n\nfunction handle(self, deferred) {\n while (self._state === 3) {\n self = self._value;\n }\n if (self._state === 0) {\n self._deferreds.push(deferred);\n return;\n }\n self._handled = true;\n Promise._immediateFn(function() {\n var cb = self._state === 1 ? deferred.onFulfilled : deferred.onRejected;\n if (cb === null) {\n (self._state === 1 ? resolve : reject)(deferred.promise, self._value);\n return;\n }\n var ret;\n try {\n ret = cb(self._value);\n } catch (e) {\n reject(deferred.promise, e);\n return;\n }\n resolve(deferred.promise, ret);\n });\n}\n\nfunction resolve(self, newValue) {\n try {\n // Promise Resolution Procedure: https://github.com/promises-aplus/promises-spec#the-promise-resolution-procedure\n if (newValue === self)\n throw new TypeError('A promise cannot be resolved with itself.');\n if (\n newValue &&\n (typeof newValue === 'object' || typeof newValue === 'function')\n ) {\n var then = newValue.then;\n if (newValue instanceof Promise) {\n self._state = 3;\n self._value = newValue;\n finale(self);\n return;\n } else if (typeof then === 'function') {\n doResolve(bind(then, newValue), self);\n return;\n }\n }\n self._state = 1;\n self._value = newValue;\n finale(self);\n } catch (e) {\n reject(self, e);\n }\n}\n\nfunction reject(self, newValue) {\n self._state = 2;\n self._value = newValue;\n finale(self);\n}\n\nfunction finale(self) {\n if (self._state === 2 && self._deferreds.length === 0) {\n Promise._immediateFn(function() {\n if (!self._handled) {\n Promise._unhandledRejectionFn(self._value);\n }\n });\n }\n\n for (var i = 0, len = self._deferreds.length; i < len; i++) {\n handle(self, self._deferreds[i]);\n }\n self._deferreds = null;\n}\n\n/**\n * @constructor\n */\nfunction Handler(onFulfilled, onRejected, promise) {\n this.onFulfilled = typeof onFulfilled === 'function' ? onFulfilled : null;\n this.onRejected = typeof onRejected === 'function' ? onRejected : null;\n this.promise = promise;\n}\n\n/**\n * Take a potentially misbehaving resolver function and make sure\n * onFulfilled and onRejected are only called once.\n *\n * Makes no guarantees about asynchrony.\n */\nfunction doResolve(fn, self) {\n var done = false;\n try {\n fn(\n function(value) {\n if (done) return;\n done = true;\n resolve(self, value);\n },\n function(reason) {\n if (done) return;\n done = true;\n reject(self, reason);\n }\n );\n } catch (ex) {\n if (done) return;\n done = true;\n reject(self, ex);\n }\n}\n\nPromise.prototype['catch'] = function(onRejected) {\n return this.then(null, onRejected);\n};\n\nPromise.prototype.then = function(onFulfilled, onRejected) {\n // @ts-ignore\n var prom = new this.constructor(noop);\n\n handle(this, new Handler(onFulfilled, onRejected, prom));\n return prom;\n};\n\nPromise.prototype['finally'] = promiseFinally;\n\nPromise.all = function(arr) {\n return new Promise(function(resolve, reject) {\n if (!isArray(arr)) {\n return reject(new TypeError('Promise.all accepts an array'));\n }\n\n var args = Array.prototype.slice.call(arr);\n if (args.length === 0) return resolve([]);\n var remaining = args.length;\n\n function res(i, val) {\n try {\n if (val && (typeof val === 'object' || typeof val === 'function')) {\n var then = val.then;\n if (typeof then === 'function') {\n then.call(\n val,\n function(val) {\n res(i, val);\n },\n reject\n );\n return;\n }\n }\n args[i] = val;\n if (--remaining === 0) {\n resolve(args);\n }\n } catch (ex) {\n reject(ex);\n }\n }\n\n for (var i = 0; i < args.length; i++) {\n res(i, args[i]);\n }\n });\n};\n\nPromise.allSettled = allSettled;\n\nPromise.resolve = function(value) {\n if (value && typeof value === 'object' && value.constructor === Promise) {\n return value;\n }\n\n return new Promise(function(resolve) {\n resolve(value);\n });\n};\n\nPromise.reject = function(value) {\n return new Promise(function(resolve, reject) {\n reject(value);\n });\n};\n\nPromise.race = function(arr) {\n return new Promise(function(resolve, reject) {\n if (!isArray(arr)) {\n return reject(new TypeError('Promise.race accepts an array'));\n }\n\n for (var i = 0, len = arr.length; i < len; i++) {\n Promise.resolve(arr[i]).then(resolve, reject);\n }\n });\n};\n\n// Use polyfill for setImmediate for performance gains\nPromise._immediateFn =\n // @ts-ignore\n (typeof setImmediate === 'function' &&\n function(fn) {\n // @ts-ignore\n setImmediate(fn);\n }) ||\n function(fn) {\n setTimeoutFunc(fn, 0);\n };\n\nPromise._unhandledRejectionFn = function _unhandledRejectionFn(err) {\n if (typeof console !== 'undefined' && console) {\n console.warn('Possible Unhandled Promise Rejection:', err); // eslint-disable-line no-console\n }\n};\n\nexport default Promise;\n","/*!\n * @pixi/polyfill - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/polyfill is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport Polyfill from 'promise-polyfill';\nimport objectAssign from 'object-assign';\n\nif (typeof globalThis === 'undefined') {\n if (typeof self !== 'undefined') {\n // covers browsers\n // @ts-expect-error not-writable ts(2540) error only on node\n self.globalThis = self;\n }\n else if (typeof global !== 'undefined') {\n // covers versions of Node < 12\n // @ts-expect-error not-writable ts(2540) error only on node\n global.globalThis = global;\n }\n}\n\n// Support for IE 9 - 11 which does not include Promises\nif (!globalThis.Promise) {\n globalThis.Promise = Polyfill;\n}\n\n// References:\nif (!Object.assign) {\n Object.assign = objectAssign;\n}\n\n// References:\n// http://paulirish.com/2011/requestanimationframe-for-smart-animating/\n// https://gist.github.com/1579671\n// http://updates.html5rocks.com/2012/05/requestAnimationFrame-API-now-with-sub-millisecond-precision\n// https://gist.github.com/timhall/4078614\n// https://github.com/Financial-Times/polyfill-service/tree/master/polyfills/requestAnimationFrame\n// Expected to be used with Browserfiy\n// Browserify automatically detects the use of `global` and passes the\n// correct reference of `global`, `globalThis`, and finally `window`\nvar ONE_FRAME_TIME = 16;\n// Date.now\nif (!(Date.now && Date.prototype.getTime)) {\n Date.now = function now() {\n return new Date().getTime();\n };\n}\n// performance.now\nif (!(globalThis.performance && globalThis.performance.now)) {\n var startTime_1 = Date.now();\n if (!globalThis.performance) {\n globalThis.performance = {};\n }\n globalThis.performance.now = function () { return Date.now() - startTime_1; };\n}\n// requestAnimationFrame\nvar lastTime = Date.now();\nvar vendors = ['ms', 'moz', 'webkit', 'o'];\nfor (var x = 0; x < vendors.length && !globalThis.requestAnimationFrame; ++x) {\n var p = vendors[x];\n globalThis.requestAnimationFrame = globalThis[p + \"RequestAnimationFrame\"];\n globalThis.cancelAnimationFrame = globalThis[p + \"CancelAnimationFrame\"]\n || globalThis[p + \"CancelRequestAnimationFrame\"];\n}\nif (!globalThis.requestAnimationFrame) {\n globalThis.requestAnimationFrame = function (callback) {\n if (typeof callback !== 'function') {\n throw new TypeError(callback + \"is not a function\");\n }\n var currentTime = Date.now();\n var delay = ONE_FRAME_TIME + lastTime - currentTime;\n if (delay < 0) {\n delay = 0;\n }\n lastTime = currentTime;\n return globalThis.self.setTimeout(function () {\n lastTime = Date.now();\n callback(performance.now());\n }, delay);\n };\n}\nif (!globalThis.cancelAnimationFrame) {\n globalThis.cancelAnimationFrame = function (id) { return clearTimeout(id); };\n}\n\n// References:\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/sign\nif (!Math.sign) {\n Math.sign = function mathSign(x) {\n x = Number(x);\n if (x === 0 || isNaN(x)) {\n return x;\n }\n return x > 0 ? 1 : -1;\n };\n}\n\n// References:\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isInteger\nif (!Number.isInteger) {\n Number.isInteger = function numberIsInteger(value) {\n return typeof value === 'number' && isFinite(value) && Math.floor(value) === value;\n };\n}\n\nif (!globalThis.ArrayBuffer) {\n globalThis.ArrayBuffer = Array;\n}\nif (!globalThis.Float32Array) {\n globalThis.Float32Array = Array;\n}\nif (!globalThis.Uint32Array) {\n globalThis.Uint32Array = Array;\n}\nif (!globalThis.Uint16Array) {\n globalThis.Uint16Array = Array;\n}\nif (!globalThis.Uint8Array) {\n globalThis.Uint8Array = Array;\n}\nif (!globalThis.Int32Array) {\n globalThis.Int32Array = Array;\n}\n//# sourceMappingURL=polyfill.js.map\n","/*!\n * @pixi/accessibility - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/accessibility is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { DisplayObject } from '@pixi/display';\nimport { isMobile, removeItems } from '@pixi/utils';\n\n/**\n * Default property values of accessible objects\n * used by {@link PIXI.AccessibilityManager}.\n *\n * @private\n * @function accessibleTarget\n * @memberof PIXI\n * @type {Object}\n * @example\n * function MyObject() {}\n *\n * Object.assign(\n * MyObject.prototype,\n * PIXI.accessibleTarget\n * );\n */\nvar accessibleTarget = {\n /**\n * Flag for if the object is accessible. If true AccessibilityManager will overlay a\n * shadow div with attributes set\n *\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n */\n accessible: false,\n /**\n * Sets the title attribute of the shadow div\n * If accessibleTitle AND accessibleHint has not been this will default to 'displayObject [tabIndex]'\n *\n * @member {?string}\n * @memberof PIXI.DisplayObject#\n */\n accessibleTitle: null,\n /**\n * Sets the aria-label attribute of the shadow div\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n */\n accessibleHint: null,\n /**\n * @member {number}\n * @memberof PIXI.DisplayObject#\n * @private\n * @todo Needs docs.\n */\n tabIndex: 0,\n /**\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n * @todo Needs docs.\n */\n _accessibleActive: false,\n /**\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n * @todo Needs docs.\n */\n _accessibleDiv: null,\n /**\n * Specify the type of div the accessible layer is. Screen readers treat the element differently\n * depending on this type. Defaults to button.\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n * @default 'button'\n */\n accessibleType: 'button',\n /**\n * Specify the pointer-events the accessible div will use\n * Defaults to auto.\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n * @default 'auto'\n */\n accessiblePointerEvents: 'auto',\n /**\n * Setting to false will prevent any children inside this container to\n * be accessible. Defaults to true.\n *\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n * @default true\n */\n accessibleChildren: true,\n renderId: -1,\n};\n\n// add some extra variables to the container..\nDisplayObject.mixin(accessibleTarget);\nvar KEY_CODE_TAB = 9;\nvar DIV_TOUCH_SIZE = 100;\nvar DIV_TOUCH_POS_X = 0;\nvar DIV_TOUCH_POS_Y = 0;\nvar DIV_TOUCH_ZINDEX = 2;\nvar DIV_HOOK_SIZE = 1;\nvar DIV_HOOK_POS_X = -1000;\nvar DIV_HOOK_POS_Y = -1000;\nvar DIV_HOOK_ZINDEX = 2;\n/**\n * The Accessibility manager recreates the ability to tab and have content read by screen readers.\n * This is very important as it can possibly help people with disabilities access PixiJS content.\n *\n * A DisplayObject can be made accessible just like it can be made interactive. This manager will map the\n * events as if the mouse was being used, minimizing the effort required to implement.\n *\n * An instance of this class is automatically created by default, and can be found at `renderer.plugins.accessibility`\n *\n * @class\n * @memberof PIXI\n */\nvar AccessibilityManager = /** @class */ (function () {\n /**\n * @param {PIXI.CanvasRenderer|PIXI.Renderer} renderer - A reference to the current renderer\n */\n function AccessibilityManager(renderer) {\n /** Setting this to true will visually show the divs. */\n this.debug = false;\n /** Internal variable, see isActive getter. */\n this._isActive = false;\n /** Internal variable, see isMobileAccessibility getter. */\n this._isMobileAccessibility = false;\n /** A simple pool for storing divs. */\n this.pool = [];\n /** This is a tick used to check if an object is no longer being rendered. */\n this.renderId = 0;\n /** The array of currently active accessible items. */\n this.children = [];\n /** Count to throttle div updates on android devices. */\n this.androidUpdateCount = 0;\n /** The frequency to update the div elements. */\n this.androidUpdateFrequency = 500; // 2fps\n this._hookDiv = null;\n if (isMobile.tablet || isMobile.phone) {\n this.createTouchHook();\n }\n // first we create a div that will sit over the PixiJS element. This is where the div overlays will go.\n var div = document.createElement('div');\n div.style.width = DIV_TOUCH_SIZE + \"px\";\n div.style.height = DIV_TOUCH_SIZE + \"px\";\n div.style.position = 'absolute';\n div.style.top = DIV_TOUCH_POS_X + \"px\";\n div.style.left = DIV_TOUCH_POS_Y + \"px\";\n div.style.zIndex = DIV_TOUCH_ZINDEX.toString();\n this.div = div;\n this.renderer = renderer;\n /**\n * pre-bind the functions\n *\n * @type {Function}\n * @private\n */\n this._onKeyDown = this._onKeyDown.bind(this);\n /**\n * pre-bind the functions\n *\n * @type {Function}\n * @private\n */\n this._onMouseMove = this._onMouseMove.bind(this);\n // let listen for tab.. once pressed we can fire up and show the accessibility layer\n globalThis.addEventListener('keydown', this._onKeyDown, false);\n }\n Object.defineProperty(AccessibilityManager.prototype, \"isActive\", {\n /**\n * Value of `true` if accessibility is currently active and accessibility layers are showing.\n * @member {boolean}\n * @readonly\n */\n get: function () {\n return this._isActive;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AccessibilityManager.prototype, \"isMobileAccessibility\", {\n /**\n * Value of `true` if accessibility is enabled for touch devices.\n * @member {boolean}\n * @readonly\n */\n get: function () {\n return this._isMobileAccessibility;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Creates the touch hooks.\n *\n * @private\n */\n AccessibilityManager.prototype.createTouchHook = function () {\n var _this = this;\n var hookDiv = document.createElement('button');\n hookDiv.style.width = DIV_HOOK_SIZE + \"px\";\n hookDiv.style.height = DIV_HOOK_SIZE + \"px\";\n hookDiv.style.position = 'absolute';\n hookDiv.style.top = DIV_HOOK_POS_X + \"px\";\n hookDiv.style.left = DIV_HOOK_POS_Y + \"px\";\n hookDiv.style.zIndex = DIV_HOOK_ZINDEX.toString();\n hookDiv.style.backgroundColor = '#FF0000';\n hookDiv.title = 'select to enable accessibility for this content';\n hookDiv.addEventListener('focus', function () {\n _this._isMobileAccessibility = true;\n _this.activate();\n _this.destroyTouchHook();\n });\n document.body.appendChild(hookDiv);\n this._hookDiv = hookDiv;\n };\n /**\n * Destroys the touch hooks.\n *\n * @private\n */\n AccessibilityManager.prototype.destroyTouchHook = function () {\n if (!this._hookDiv) {\n return;\n }\n document.body.removeChild(this._hookDiv);\n this._hookDiv = null;\n };\n /**\n * Activating will cause the Accessibility layer to be shown.\n * This is called when a user presses the tab key.\n *\n * @private\n */\n AccessibilityManager.prototype.activate = function () {\n var _a;\n if (this._isActive) {\n return;\n }\n this._isActive = true;\n globalThis.document.addEventListener('mousemove', this._onMouseMove, true);\n globalThis.removeEventListener('keydown', this._onKeyDown, false);\n this.renderer.on('postrender', this.update, this);\n (_a = this.renderer.view.parentNode) === null || _a === void 0 ? void 0 : _a.appendChild(this.div);\n };\n /**\n * Deactivating will cause the Accessibility layer to be hidden.\n * This is called when a user moves the mouse.\n *\n * @private\n */\n AccessibilityManager.prototype.deactivate = function () {\n var _a;\n if (!this._isActive || this._isMobileAccessibility) {\n return;\n }\n this._isActive = false;\n globalThis.document.removeEventListener('mousemove', this._onMouseMove, true);\n globalThis.addEventListener('keydown', this._onKeyDown, false);\n this.renderer.off('postrender', this.update);\n (_a = this.div.parentNode) === null || _a === void 0 ? void 0 : _a.removeChild(this.div);\n };\n /**\n * This recursive function will run through the scene graph and add any new accessible objects to the DOM layer.\n *\n * @private\n * @param {PIXI.Container} displayObject - The DisplayObject to check.\n */\n AccessibilityManager.prototype.updateAccessibleObjects = function (displayObject) {\n if (!displayObject.visible || !displayObject.accessibleChildren) {\n return;\n }\n if (displayObject.accessible && displayObject.interactive) {\n if (!displayObject._accessibleActive) {\n this.addChild(displayObject);\n }\n displayObject.renderId = this.renderId;\n }\n var children = displayObject.children;\n if (children) {\n for (var i = 0; i < children.length; i++) {\n this.updateAccessibleObjects(children[i]);\n }\n }\n };\n /**\n * Before each render this function will ensure that all divs are mapped correctly to their DisplayObjects.\n *\n * @private\n */\n AccessibilityManager.prototype.update = function () {\n /* On Android default web browser, tab order seems to be calculated by position rather than tabIndex,\n * moving buttons can cause focus to flicker between two buttons making it hard/impossible to navigate,\n * so I am just running update every half a second, seems to fix it.\n */\n var now = performance.now();\n if (isMobile.android.device && now < this.androidUpdateCount) {\n return;\n }\n this.androidUpdateCount = now + this.androidUpdateFrequency;\n if (!this.renderer.renderingToScreen) {\n return;\n }\n // update children...\n if (this.renderer._lastObjectRendered) {\n this.updateAccessibleObjects(this.renderer._lastObjectRendered);\n }\n var _a = this.renderer.view.getBoundingClientRect(), left = _a.left, top = _a.top, width = _a.width, height = _a.height;\n var _b = this.renderer, viewWidth = _b.width, viewHeight = _b.height, resolution = _b.resolution;\n var sx = (width / viewWidth) * resolution;\n var sy = (height / viewHeight) * resolution;\n var div = this.div;\n div.style.left = left + \"px\";\n div.style.top = top + \"px\";\n div.style.width = viewWidth + \"px\";\n div.style.height = viewHeight + \"px\";\n for (var i = 0; i < this.children.length; i++) {\n var child = this.children[i];\n if (child.renderId !== this.renderId) {\n child._accessibleActive = false;\n removeItems(this.children, i, 1);\n this.div.removeChild(child._accessibleDiv);\n this.pool.push(child._accessibleDiv);\n child._accessibleDiv = null;\n i--;\n }\n else {\n // map div to display..\n div = child._accessibleDiv;\n var hitArea = child.hitArea;\n var wt = child.worldTransform;\n if (child.hitArea) {\n div.style.left = (wt.tx + (hitArea.x * wt.a)) * sx + \"px\";\n div.style.top = (wt.ty + (hitArea.y * wt.d)) * sy + \"px\";\n div.style.width = hitArea.width * wt.a * sx + \"px\";\n div.style.height = hitArea.height * wt.d * sy + \"px\";\n }\n else {\n hitArea = child.getBounds();\n this.capHitArea(hitArea);\n div.style.left = hitArea.x * sx + \"px\";\n div.style.top = hitArea.y * sy + \"px\";\n div.style.width = hitArea.width * sx + \"px\";\n div.style.height = hitArea.height * sy + \"px\";\n // update button titles and hints if they exist and they've changed\n if (div.title !== child.accessibleTitle && child.accessibleTitle !== null) {\n div.title = child.accessibleTitle;\n }\n if (div.getAttribute('aria-label') !== child.accessibleHint\n && child.accessibleHint !== null) {\n div.setAttribute('aria-label', child.accessibleHint);\n }\n }\n // the title or index may have changed, if so lets update it!\n if (child.accessibleTitle !== div.title || child.tabIndex !== div.tabIndex) {\n div.title = child.accessibleTitle;\n div.tabIndex = child.tabIndex;\n if (this.debug)\n { this.updateDebugHTML(div); }\n }\n }\n }\n // increment the render id..\n this.renderId++;\n };\n /**\n * private function that will visually add the information to the\n * accessability div\n *\n * @param {HTMLElement} div\n */\n AccessibilityManager.prototype.updateDebugHTML = function (div) {\n div.innerHTML = \"type: \" + div.type + \"</br> title : \" + div.title + \"</br> tabIndex: \" + div.tabIndex;\n };\n /**\n * Adjust the hit area based on the bounds of a display object\n *\n * @param {PIXI.Rectangle} hitArea - Bounds of the child\n */\n AccessibilityManager.prototype.capHitArea = function (hitArea) {\n if (hitArea.x < 0) {\n hitArea.width += hitArea.x;\n hitArea.x = 0;\n }\n if (hitArea.y < 0) {\n hitArea.height += hitArea.y;\n hitArea.y = 0;\n }\n var _a = this.renderer, viewWidth = _a.width, viewHeight = _a.height;\n if (hitArea.x + hitArea.width > viewWidth) {\n hitArea.width = viewWidth - hitArea.x;\n }\n if (hitArea.y + hitArea.height > viewHeight) {\n hitArea.height = viewHeight - hitArea.y;\n }\n };\n /**\n * Adds a DisplayObject to the accessibility manager\n *\n * @private\n * @param {PIXI.DisplayObject} displayObject - The child to make accessible.\n */\n AccessibilityManager.prototype.addChild = function (displayObject) {\n // this.activate();\n var div = this.pool.pop();\n if (!div) {\n div = document.createElement('button');\n div.style.width = DIV_TOUCH_SIZE + \"px\";\n div.style.height = DIV_TOUCH_SIZE + \"px\";\n div.style.backgroundColor = this.debug ? 'rgba(255,255,255,0.5)' : 'transparent';\n div.style.position = 'absolute';\n div.style.zIndex = DIV_TOUCH_ZINDEX.toString();\n div.style.borderStyle = 'none';\n // ARIA attributes ensure that button title and hint updates are announced properly\n if (navigator.userAgent.toLowerCase().indexOf('chrome') > -1) {\n // Chrome doesn't need aria-live to work as intended; in fact it just gets more confused.\n div.setAttribute('aria-live', 'off');\n }\n else {\n div.setAttribute('aria-live', 'polite');\n }\n if (navigator.userAgent.match(/rv:.*Gecko\\//)) {\n // FireFox needs this to announce only the new button name\n div.setAttribute('aria-relevant', 'additions');\n }\n else {\n // required by IE, other browsers don't much care\n div.setAttribute('aria-relevant', 'text');\n }\n div.addEventListener('click', this._onClick.bind(this));\n div.addEventListener('focus', this._onFocus.bind(this));\n div.addEventListener('focusout', this._onFocusOut.bind(this));\n }\n // set pointer events\n div.style.pointerEvents = displayObject.accessiblePointerEvents;\n // set the type, this defaults to button!\n div.type = displayObject.accessibleType;\n if (displayObject.accessibleTitle && displayObject.accessibleTitle !== null) {\n div.title = displayObject.accessibleTitle;\n }\n else if (!displayObject.accessibleHint\n || displayObject.accessibleHint === null) {\n div.title = \"displayObject \" + displayObject.tabIndex;\n }\n if (displayObject.accessibleHint\n && displayObject.accessibleHint !== null) {\n div.setAttribute('aria-label', displayObject.accessibleHint);\n }\n if (this.debug)\n { this.updateDebugHTML(div); }\n displayObject._accessibleActive = true;\n displayObject._accessibleDiv = div;\n div.displayObject = displayObject;\n this.children.push(displayObject);\n this.div.appendChild(displayObject._accessibleDiv);\n displayObject._accessibleDiv.tabIndex = displayObject.tabIndex;\n };\n /**\n * Maps the div button press to pixi's InteractionManager (click)\n *\n * @private\n * @param {MouseEvent} e - The click event.\n */\n AccessibilityManager.prototype._onClick = function (e) {\n var interactionManager = this.renderer.plugins.interaction;\n var displayObject = e.target.displayObject;\n var eventData = interactionManager.eventData;\n interactionManager.dispatchEvent(displayObject, 'click', eventData);\n interactionManager.dispatchEvent(displayObject, 'pointertap', eventData);\n interactionManager.dispatchEvent(displayObject, 'tap', eventData);\n };\n /**\n * Maps the div focus events to pixi's InteractionManager (mouseover)\n *\n * @private\n * @param {FocusEvent} e - The focus event.\n */\n AccessibilityManager.prototype._onFocus = function (e) {\n if (!e.target.getAttribute('aria-live')) {\n e.target.setAttribute('aria-live', 'assertive');\n }\n var interactionManager = this.renderer.plugins.interaction;\n var displayObject = e.target.displayObject;\n var eventData = interactionManager.eventData;\n interactionManager.dispatchEvent(displayObject, 'mouseover', eventData);\n };\n /**\n * Maps the div focus events to pixi's InteractionManager (mouseout)\n *\n * @private\n * @param {FocusEvent} e - The focusout event.\n */\n AccessibilityManager.prototype._onFocusOut = function (e) {\n if (!e.target.getAttribute('aria-live')) {\n e.target.setAttribute('aria-live', 'polite');\n }\n var interactionManager = this.renderer.plugins.interaction;\n var displayObject = e.target.displayObject;\n var eventData = interactionManager.eventData;\n interactionManager.dispatchEvent(displayObject, 'mouseout', eventData);\n };\n /**\n * Is called when a key is pressed\n *\n * @private\n * @param {KeyboardEvent} e - The keydown event.\n */\n AccessibilityManager.prototype._onKeyDown = function (e) {\n if (e.keyCode !== KEY_CODE_TAB) {\n return;\n }\n this.activate();\n };\n /**\n * Is called when the mouse moves across the renderer element\n *\n * @private\n * @param {MouseEvent} e - The mouse event.\n */\n AccessibilityManager.prototype._onMouseMove = function (e) {\n if (e.movementX === 0 && e.movementY === 0) {\n return;\n }\n this.deactivate();\n };\n /**\n * Destroys the accessibility manager\n *\n */\n AccessibilityManager.prototype.destroy = function () {\n this.destroyTouchHook();\n this.div = null;\n globalThis.document.removeEventListener('mousemove', this._onMouseMove, true);\n globalThis.removeEventListener('keydown', this._onKeyDown);\n this.pool = null;\n this.children = null;\n this.renderer = null;\n };\n return AccessibilityManager;\n}());\n\nexport { AccessibilityManager, accessibleTarget };\n//# sourceMappingURL=accessibility.js.map\n","/*!\n * @pixi/interaction - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/interaction is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Point } from '@pixi/math';\nimport { Ticker, UPDATE_PRIORITY } from '@pixi/ticker';\nimport { DisplayObject, TemporaryDisplayObject } from '@pixi/display';\nimport { EventEmitter } from '@pixi/utils';\n\n/**\n * Holds all information related to an Interaction event\n *\n * @memberof PIXI\n */\nvar InteractionData = /** @class */ (function () {\n function InteractionData() {\n /**\n * Pressure applied by the pointing device during the event. A Touch's force property\n * will be represented by this value.\n *\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pressure\n */\n this.pressure = 0;\n /**\n * From TouchEvents (not PointerEvents triggered by touches), the rotationAngle of the Touch.\n *\n * @see https://developer.mozilla.org/en-US/docs/Web/API/Touch/rotationAngle\n */\n this.rotationAngle = 0;\n /**\n * Twist of a stylus pointer.\n *\n * @see https://w3c.github.io/pointerevents/#pointerevent-interface\n */\n this.twist = 0;\n /**\n * Barrel pressure on a stylus pointer.\n *\n * @see https://w3c.github.io/pointerevents/#pointerevent-interface\n */\n this.tangentialPressure = 0;\n this.global = new Point();\n this.target = null;\n this.originalEvent = null;\n this.identifier = null;\n this.isPrimary = false;\n this.button = 0;\n this.buttons = 0;\n this.width = 0;\n this.height = 0;\n this.tiltX = 0;\n this.tiltY = 0;\n this.pointerType = null;\n this.pressure = 0;\n this.rotationAngle = 0;\n this.twist = 0;\n this.tangentialPressure = 0;\n }\n Object.defineProperty(InteractionData.prototype, \"pointerId\", {\n /**\n * The unique identifier of the pointer. It will be the same as `identifier`.\n *\n * @readonly\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pointerId\n */\n get: function () {\n return this.identifier;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * This will return the local coordinates of the specified displayObject for this InteractionData\n *\n * @param displayObject - The DisplayObject that you would like the local\n * coords off\n * @param point - A Point object in which to store the value, optional (otherwise\n * will create a new point)\n * @param globalPos - A Point object containing your custom global coords, optional\n * (otherwise will use the current global coords)\n * @return - A point containing the coordinates of the InteractionData position relative\n * to the DisplayObject\n */\n InteractionData.prototype.getLocalPosition = function (displayObject, point, globalPos) {\n return displayObject.worldTransform.applyInverse(globalPos || this.global, point);\n };\n /**\n * Copies properties from normalized event data.\n *\n * @param {Touch|MouseEvent|PointerEvent} event - The normalized event data\n */\n InteractionData.prototype.copyEvent = function (event) {\n // isPrimary should only change on touchstart/pointerdown, so we don't want to overwrite\n // it with \"false\" on later events when our shim for it on touch events might not be\n // accurate\n if ('isPrimary' in event && event.isPrimary) {\n this.isPrimary = true;\n }\n this.button = 'button' in event && event.button;\n // event.buttons is not available in all browsers (ie. Safari), but it does have a non-standard\n // event.which property instead, which conveys the same information.\n var buttons = 'buttons' in event && event.buttons;\n this.buttons = Number.isInteger(buttons) ? buttons : 'which' in event && event.which;\n this.width = 'width' in event && event.width;\n this.height = 'height' in event && event.height;\n this.tiltX = 'tiltX' in event && event.tiltX;\n this.tiltY = 'tiltY' in event && event.tiltY;\n this.pointerType = 'pointerType' in event && event.pointerType;\n this.pressure = 'pressure' in event && event.pressure;\n this.rotationAngle = 'rotationAngle' in event && event.rotationAngle;\n this.twist = ('twist' in event && event.twist) || 0;\n this.tangentialPressure = ('tangentialPressure' in event && event.tangentialPressure) || 0;\n };\n /** Resets the data for pooling. */\n InteractionData.prototype.reset = function () {\n // isPrimary is the only property that we really need to reset - everything else is\n // guaranteed to be overwritten\n this.isPrimary = false;\n };\n return InteractionData;\n}());\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * Event class that mimics native DOM events.\n *\n * @memberof PIXI\n */\nvar InteractionEvent = /** @class */ (function () {\n function InteractionEvent() {\n this.stopped = false;\n this.stopsPropagatingAt = null;\n this.stopPropagationHint = false;\n this.target = null;\n this.currentTarget = null;\n this.type = null;\n this.data = null;\n }\n /** Prevents event from reaching any objects other than the current object. */\n InteractionEvent.prototype.stopPropagation = function () {\n this.stopped = true;\n this.stopPropagationHint = true;\n this.stopsPropagatingAt = this.currentTarget;\n };\n /** Resets the event. */\n InteractionEvent.prototype.reset = function () {\n this.stopped = false;\n this.stopsPropagatingAt = null;\n this.stopPropagationHint = false;\n this.currentTarget = null;\n this.target = null;\n };\n return InteractionEvent;\n}());\n\n/**\n * DisplayObjects with the {@link PIXI.interactiveTarget} mixin use this class to track interactions\n *\n * @class\n * @private\n * @memberof PIXI\n */\nvar InteractionTrackingData = /** @class */ (function () {\n /**\n * @param {number} pointerId - Unique pointer id of the event\n * @private\n */\n function InteractionTrackingData(pointerId) {\n this._pointerId = pointerId;\n this._flags = InteractionTrackingData.FLAGS.NONE;\n }\n /**\n *\n * @private\n * @param {number} flag - The interaction flag to set\n * @param {boolean} yn - Should the flag be set or unset\n */\n InteractionTrackingData.prototype._doSet = function (flag, yn) {\n if (yn) {\n this._flags = this._flags | flag;\n }\n else {\n this._flags = this._flags & (~flag);\n }\n };\n Object.defineProperty(InteractionTrackingData.prototype, \"pointerId\", {\n /**\n * Unique pointer id of the event\n *\n * @readonly\n * @private\n * @member {number}\n */\n get: function () {\n return this._pointerId;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"flags\", {\n /**\n * State of the tracking data, expressed as bit flags\n *\n * @private\n * @member {number}\n */\n get: function () {\n return this._flags;\n },\n set: function (flags) {\n this._flags = flags;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"none\", {\n /**\n * Is the tracked event inactive (not over or down)?\n *\n * @private\n * @member {number}\n */\n get: function () {\n return this._flags === InteractionTrackingData.FLAGS.NONE;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"over\", {\n /**\n * Is the tracked event over the DisplayObject?\n *\n * @private\n * @member {boolean}\n */\n get: function () {\n return (this._flags & InteractionTrackingData.FLAGS.OVER) !== 0;\n },\n set: function (yn) {\n this._doSet(InteractionTrackingData.FLAGS.OVER, yn);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"rightDown\", {\n /**\n * Did the right mouse button come down in the DisplayObject?\n *\n * @private\n * @member {boolean}\n */\n get: function () {\n return (this._flags & InteractionTrackingData.FLAGS.RIGHT_DOWN) !== 0;\n },\n set: function (yn) {\n this._doSet(InteractionTrackingData.FLAGS.RIGHT_DOWN, yn);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionTrackingData.prototype, \"leftDown\", {\n /**\n * Did the left mouse button come down in the DisplayObject?\n *\n * @private\n * @member {boolean}\n */\n get: function () {\n return (this._flags & InteractionTrackingData.FLAGS.LEFT_DOWN) !== 0;\n },\n set: function (yn) {\n this._doSet(InteractionTrackingData.FLAGS.LEFT_DOWN, yn);\n },\n enumerable: false,\n configurable: true\n });\n InteractionTrackingData.FLAGS = Object.freeze({\n NONE: 0,\n OVER: 1 << 0,\n LEFT_DOWN: 1 << 1,\n RIGHT_DOWN: 1 << 2,\n });\n return InteractionTrackingData;\n}());\n\n/**\n * Strategy how to search through stage tree for interactive objects\n *\n * @memberof PIXI\n */\nvar TreeSearch = /** @class */ (function () {\n function TreeSearch() {\n this._tempPoint = new Point();\n }\n /**\n * Recursive implementation for findHit\n *\n * @private\n * @param interactionEvent - event containing the point that\n * is tested for collision\n * @param displayObject - the displayObject\n * that will be hit test (recursively crawls its children)\n * @param func - the function that will be called on each interactive object. The\n * interactionEvent, displayObject and hit will be passed to the function\n * @param hitTest - this indicates if the objects inside should be hit test against the point\n * @param interactive - Whether the displayObject is interactive\n * @return - Returns true if the displayObject hit the point\n */\n TreeSearch.prototype.recursiveFindHit = function (interactionEvent, displayObject, func, hitTest, interactive) {\n if (!displayObject || !displayObject.visible) {\n return false;\n }\n var point = interactionEvent.data.global;\n // Took a little while to rework this function correctly! But now it is done and nice and optimized! ^_^\n //\n // This function will now loop through all objects and then only hit test the objects it HAS\n // to, not all of them. MUCH faster..\n // An object will be hit test if the following is true:\n //\n // 1: It is interactive.\n // 2: It belongs to a parent that is interactive AND one of the parents children have not already been hit.\n //\n // As another little optimization once an interactive object has been hit we can carry on\n // through the scenegraph, but we know that there will be no more hits! So we can avoid extra hit tests\n // A final optimization is that an object is not hit test directly if a child has already been hit.\n interactive = displayObject.interactive || interactive;\n var hit = false;\n var interactiveParent = interactive;\n // Flag here can set to false if the event is outside the parents hitArea or mask\n var hitTestChildren = true;\n // If there is a hitArea, no need to test against anything else if the pointer is not within the hitArea\n // There is also no longer a need to hitTest children.\n if (displayObject.hitArea) {\n if (hitTest) {\n displayObject.worldTransform.applyInverse(point, this._tempPoint);\n if (!displayObject.hitArea.contains(this._tempPoint.x, this._tempPoint.y)) {\n hitTest = false;\n hitTestChildren = false;\n }\n else {\n hit = true;\n }\n }\n interactiveParent = false;\n }\n // If there is a mask, no need to hitTest against anything else if the pointer is not within the mask.\n // We still want to hitTestChildren, however, to ensure a mouseout can still be generated.\n // https://github.com/pixijs/pixi.js/issues/5135\n else if (displayObject._mask) {\n if (hitTest) {\n if (!(displayObject._mask.containsPoint && displayObject._mask.containsPoint(point))) {\n hitTest = false;\n }\n }\n }\n // ** FREE TIP **! If an object is not interactive or has no buttons in it\n // (such as a game scene!) set interactiveChildren to false for that displayObject.\n // This will allow PixiJS to completely ignore and bypass checking the displayObjects children.\n if (hitTestChildren && displayObject.interactiveChildren && displayObject.children) {\n var children = displayObject.children;\n for (var i = children.length - 1; i >= 0; i--) {\n var child = children[i];\n // time to get recursive.. if this function will return if something is hit..\n var childHit = this.recursiveFindHit(interactionEvent, child, func, hitTest, interactiveParent);\n if (childHit) {\n // its a good idea to check if a child has lost its parent.\n // this means it has been removed whilst looping so its best\n if (!child.parent) {\n continue;\n }\n // we no longer need to hit test any more objects in this container as we we\n // now know the parent has been hit\n interactiveParent = false;\n // If the child is interactive , that means that the object hit was actually\n // interactive and not just the child of an interactive object.\n // This means we no longer need to hit test anything else. We still need to run\n // through all objects, but we don't need to perform any hit tests.\n if (childHit) {\n if (interactionEvent.target) {\n hitTest = false;\n }\n hit = true;\n }\n }\n }\n }\n // no point running this if the item is not interactive or does not have an interactive parent.\n if (interactive) {\n // if we are hit testing (as in we have no hit any objects yet)\n // We also don't need to worry about hit testing if once of the displayObjects children\n // has already been hit - but only if it was interactive, otherwise we need to keep\n // looking for an interactive child, just in case we hit one\n if (hitTest && !interactionEvent.target) {\n // already tested against hitArea if it is defined\n if (!displayObject.hitArea && displayObject.containsPoint) {\n if (displayObject.containsPoint(point)) {\n hit = true;\n }\n }\n }\n if (displayObject.interactive) {\n if (hit && !interactionEvent.target) {\n interactionEvent.target = displayObject;\n }\n if (func) {\n func(interactionEvent, displayObject, !!hit);\n }\n }\n }\n return hit;\n };\n /**\n * This function is provides a neat way of crawling through the scene graph and running a\n * specified function on all interactive objects it finds. It will also take care of hit\n * testing the interactive objects and passes the hit across in the function.\n *\n * @private\n * @param interactionEvent - event containing the point that\n * is tested for collision\n * @param displayObject - the displayObject\n * that will be hit test (recursively crawls its children)\n * @param func - the function that will be called on each interactive object. The\n * interactionEvent, displayObject and hit will be passed to the function\n * @param hitTest - this indicates if the objects inside should be hit test against the point\n * @return - Returns true if the displayObject hit the point\n */\n TreeSearch.prototype.findHit = function (interactionEvent, displayObject, func, hitTest) {\n this.recursiveFindHit(interactionEvent, displayObject, func, hitTest, false);\n };\n return TreeSearch;\n}());\n\n/**\n * Interface for classes that represent a hit area.\n *\n * It is implemented by the following classes:\n * - {@link PIXI.Circle}\n * - {@link PIXI.Ellipse}\n * - {@link PIXI.Polygon}\n * - {@link PIXI.RoundedRectangle}\n *\n * @interface IHitArea\n * @memberof PIXI\n */\n/**\n * Checks whether the x and y coordinates given are contained within this area\n *\n * @method\n * @name contains\n * @memberof PIXI.IHitArea#\n * @param {number} x - The X coordinate of the point to test\n * @param {number} y - The Y coordinate of the point to test\n * @return {boolean} Whether the x/y coordinates are within this area\n */\n/**\n * Default property values of interactive objects\n * Used by {@link PIXI.InteractionManager} to automatically give all DisplayObjects these properties\n *\n * @private\n * @name interactiveTarget\n * @type {Object}\n * @memberof PIXI\n * @example\n * function MyObject() {}\n *\n * Object.assign(\n * DisplayObject.prototype,\n * PIXI.interactiveTarget\n * );\n */\nvar interactiveTarget = {\n interactive: false,\n interactiveChildren: true,\n hitArea: null,\n /**\n * If enabled, the mouse cursor use the pointer behavior when hovered over the displayObject if it is interactive\n * Setting this changes the 'cursor' property to `'pointer'`.\n *\n * @example\n * const sprite = new PIXI.Sprite(texture);\n * sprite.interactive = true;\n * sprite.buttonMode = true;\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n */\n get buttonMode() {\n return this.cursor === 'pointer';\n },\n set buttonMode(value) {\n if (value) {\n this.cursor = 'pointer';\n }\n else if (this.cursor === 'pointer') {\n this.cursor = null;\n }\n },\n /**\n * This defines what cursor mode is used when the mouse cursor\n * is hovered over the displayObject.\n *\n * @example\n * const sprite = new PIXI.Sprite(texture);\n * sprite.interactive = true;\n * sprite.cursor = 'wait';\n * @see https://developer.mozilla.org/en/docs/Web/CSS/cursor\n *\n * @member {string}\n * @memberof PIXI.DisplayObject#\n */\n cursor: null,\n /**\n * Internal set of all active pointers, by identifier\n *\n * @member {Map<number, InteractionTrackingData>}\n * @memberof PIXI.DisplayObject#\n * @private\n */\n get trackedPointers() {\n if (this._trackedPointers === undefined)\n { this._trackedPointers = {}; }\n return this._trackedPointers;\n },\n /**\n * Map of all tracked pointers, by identifier. Use trackedPointers to access.\n *\n * @private\n * @type {Map<number, InteractionTrackingData>}\n */\n _trackedPointers: undefined,\n};\n\n// Mix interactiveTarget into DisplayObject.prototype\nDisplayObject.mixin(interactiveTarget);\nvar MOUSE_POINTER_ID = 1;\n// helpers for hitTest() - only used inside hitTest()\nvar hitTestEvent = {\n target: null,\n data: {\n global: null,\n },\n};\n/**\n * The interaction manager deals with mouse, touch and pointer events.\n *\n * Any DisplayObject can be interactive if its `interactive` property is set to true.\n *\n * This manager also supports multitouch.\n *\n * An instance of this class is automatically created by default, and can be found at `renderer.plugins.interaction`\n *\n * @memberof PIXI\n */\nvar InteractionManager = /** @class */ (function (_super) {\n __extends(InteractionManager, _super);\n /**\n * @param {PIXI.CanvasRenderer|PIXI.Renderer} renderer - A reference to the current renderer\n * @param options - The options for the manager.\n * @param {boolean} [options.autoPreventDefault=true] - Should the manager automatically prevent default browser actions.\n * @param {number} [options.interactionFrequency=10] - Maximum frequency (ms) at pointer over/out states will be checked.\n * @param {number} [options.useSystemTicker=true] - Whether to add {@link tickerUpdate} to {@link PIXI.Ticker.system}.\n */\n function InteractionManager(renderer, options) {\n var _this = _super.call(this) || this;\n options = options || {};\n _this.renderer = renderer;\n _this.autoPreventDefault = options.autoPreventDefault !== undefined ? options.autoPreventDefault : true;\n _this.interactionFrequency = options.interactionFrequency || 10;\n _this.mouse = new InteractionData();\n _this.mouse.identifier = MOUSE_POINTER_ID;\n // setting the mouse to start off far off screen will mean that mouse over does\n // not get called before we even move the mouse.\n _this.mouse.global.set(-999999);\n _this.activeInteractionData = {};\n _this.activeInteractionData[MOUSE_POINTER_ID] = _this.mouse;\n _this.interactionDataPool = [];\n _this.eventData = new InteractionEvent();\n _this.interactionDOMElement = null;\n _this.moveWhenInside = false;\n _this.eventsAdded = false;\n _this.tickerAdded = false;\n _this.mouseOverRenderer = !('PointerEvent' in globalThis);\n _this.supportsTouchEvents = 'ontouchstart' in globalThis;\n _this.supportsPointerEvents = !!globalThis.PointerEvent;\n // this will make it so that you don't have to call bind all the time\n _this.onPointerUp = _this.onPointerUp.bind(_this);\n _this.processPointerUp = _this.processPointerUp.bind(_this);\n _this.onPointerCancel = _this.onPointerCancel.bind(_this);\n _this.processPointerCancel = _this.processPointerCancel.bind(_this);\n _this.onPointerDown = _this.onPointerDown.bind(_this);\n _this.processPointerDown = _this.processPointerDown.bind(_this);\n _this.onPointerMove = _this.onPointerMove.bind(_this);\n _this.processPointerMove = _this.processPointerMove.bind(_this);\n _this.onPointerOut = _this.onPointerOut.bind(_this);\n _this.processPointerOverOut = _this.processPointerOverOut.bind(_this);\n _this.onPointerOver = _this.onPointerOver.bind(_this);\n _this.cursorStyles = {\n default: 'inherit',\n pointer: 'pointer',\n };\n _this.currentCursorMode = null;\n _this.cursor = null;\n _this.resolution = 1;\n _this.delayedEvents = [];\n _this.search = new TreeSearch();\n _this._tempDisplayObject = new TemporaryDisplayObject();\n _this._eventListenerOptions = { capture: true, passive: false };\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed on the display\n * object.\n *\n * @event PIXI.InteractionManager#mousedown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * on the display object.\n *\n * @event PIXI.InteractionManager#rightdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released over the display\n * object.\n *\n * @event PIXI.InteractionManager#mouseup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * over the display object.\n *\n * @event PIXI.InteractionManager#rightup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed and released on\n * the display object.\n *\n * @event PIXI.InteractionManager#click\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * and released on the display object.\n *\n * @event PIXI.InteractionManager#rightclick\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released outside the\n * display object that initially registered a\n * [mousedown]{@link PIXI.InteractionManager#event:mousedown}.\n *\n * @event PIXI.InteractionManager#mouseupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * outside the display object that initially registered a\n * [rightdown]{@link PIXI.InteractionManager#event:rightdown}.\n *\n * @event PIXI.InteractionManager#rightupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved while over the display object\n *\n * @event PIXI.InteractionManager#mousemove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved onto the display object\n *\n * @event PIXI.InteractionManager#mouseover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved off the display object\n *\n * @event PIXI.InteractionManager#mouseout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed on the display object.\n *\n * @event PIXI.InteractionManager#pointerdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released over the display object.\n * Not always fired when some buttons are held down while others are released. In those cases,\n * use [mousedown]{@link PIXI.InteractionManager#event:mousedown} and\n * [mouseup]{@link PIXI.InteractionManager#event:mouseup} instead.\n *\n * @event PIXI.InteractionManager#pointerup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a pointer event\n *\n * @event PIXI.InteractionManager#pointercancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed and released on the display object.\n *\n * @event PIXI.InteractionManager#pointertap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released outside the display object that initially\n * registered a [pointerdown]{@link PIXI.InteractionManager#event:pointerdown}.\n *\n * @event PIXI.InteractionManager#pointerupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved while over the display object\n *\n * @event PIXI.InteractionManager#pointermove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved onto the display object\n *\n * @event PIXI.InteractionManager#pointerover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved off the display object\n *\n * @event PIXI.InteractionManager#pointerout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed on the display object.\n *\n * @event PIXI.InteractionManager#touchstart\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed from the display object.\n *\n * @event PIXI.InteractionManager#touchend\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a touch\n *\n * @event PIXI.InteractionManager#touchcancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed and removed from the display object.\n *\n * @event PIXI.InteractionManager#tap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed outside of the display object that initially\n * registered a [touchstart]{@link PIXI.InteractionManager#event:touchstart}.\n *\n * @event PIXI.InteractionManager#touchendoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is moved along the display object.\n *\n * @event PIXI.InteractionManager#touchmove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed on the display.\n * object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mousedown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * on the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released over the display\n * object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * over the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is pressed and released on\n * the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#click\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is pressed\n * and released on the display object. DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightclick\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button (usually a mouse left-button) is released outside the\n * display object that initially registered a\n * [mousedown]{@link PIXI.DisplayObject#event:mousedown}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device secondary button (usually a mouse right-button) is released\n * outside the display object that initially registered a\n * [rightdown]{@link PIXI.DisplayObject#event:rightdown}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#rightupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved while over the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mousemove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved onto the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device (usually a mouse) is moved off the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#mouseout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed on the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerdown\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released over the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerup\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a pointer event.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointercancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is pressed and released on the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointertap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device button is released outside the display object that initially\n * registered a [pointerdown]{@link PIXI.DisplayObject#event:pointerdown}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerupoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved while over the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointermove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved onto the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerover\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a pointer device is moved off the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#pointerout\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed on the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchstart\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed from the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchend\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when the operating system cancels a touch.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchcancel\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is placed and removed from the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#tap\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is removed outside of the display object that initially\n * registered a [touchstart]{@link PIXI.DisplayObject#event:touchstart}.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchendoutside\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n /**\n * Fired when a touch point is moved along the display object.\n * DisplayObject's `interactive` property must be set to `true` to fire event.\n *\n * This comes from the @pixi/interaction package.\n *\n * @event PIXI.DisplayObject#touchmove\n * @param {PIXI.InteractionEvent} event - Interaction event\n */\n _this._useSystemTicker = options.useSystemTicker !== undefined ? options.useSystemTicker : true;\n _this.setTargetElement(_this.renderer.view, _this.renderer.resolution);\n return _this;\n }\n Object.defineProperty(InteractionManager.prototype, \"useSystemTicker\", {\n /**\n * Should the InteractionManager automatically add {@link tickerUpdate} to {@link PIXI.Ticker.system}.\n *\n * @default true\n */\n get: function () {\n return this._useSystemTicker;\n },\n set: function (useSystemTicker) {\n this._useSystemTicker = useSystemTicker;\n if (useSystemTicker) {\n this.addTickerListener();\n }\n else {\n this.removeTickerListener();\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(InteractionManager.prototype, \"lastObjectRendered\", {\n /**\n * Last rendered object or temp object.\n *\n * @readonly\n * @protected\n */\n get: function () {\n return this.renderer._lastObjectRendered || this._tempDisplayObject;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Hit tests a point against the display tree, returning the first interactive object that is hit.\n *\n * @param globalPoint - A point to hit test with, in global space.\n * @param root - The root display object to start from. If omitted, defaults\n * to the last rendered root of the associated renderer.\n * @return - The hit display object, if any.\n */\n InteractionManager.prototype.hitTest = function (globalPoint, root) {\n // clear the target for our hit test\n hitTestEvent.target = null;\n // assign the global point\n hitTestEvent.data.global = globalPoint;\n // ensure safety of the root\n if (!root) {\n root = this.lastObjectRendered;\n }\n // run the hit test\n this.processInteractive(hitTestEvent, root, null, true);\n // return our found object - it'll be null if we didn't hit anything\n return hitTestEvent.target;\n };\n /**\n * Sets the DOM element which will receive mouse/touch events. This is useful for when you have\n * other DOM elements on top of the renderers Canvas element. With this you'll be bale to delegate\n * another DOM element to receive those events.\n *\n * @param element - the DOM element which will receive mouse and touch events.\n * @param resolution - The resolution / device pixel ratio of the new element (relative to the canvas).\n */\n InteractionManager.prototype.setTargetElement = function (element, resolution) {\n if (resolution === void 0) { resolution = 1; }\n this.removeTickerListener();\n this.removeEvents();\n this.interactionDOMElement = element;\n this.resolution = resolution;\n this.addEvents();\n this.addTickerListener();\n };\n /** Adds the ticker listener. */\n InteractionManager.prototype.addTickerListener = function () {\n if (this.tickerAdded || !this.interactionDOMElement || !this._useSystemTicker) {\n return;\n }\n Ticker.system.add(this.tickerUpdate, this, UPDATE_PRIORITY.INTERACTION);\n this.tickerAdded = true;\n };\n /** Removes the ticker listener. */\n InteractionManager.prototype.removeTickerListener = function () {\n if (!this.tickerAdded) {\n return;\n }\n Ticker.system.remove(this.tickerUpdate, this);\n this.tickerAdded = false;\n };\n /** Registers all the DOM events. */\n InteractionManager.prototype.addEvents = function () {\n if (this.eventsAdded || !this.interactionDOMElement) {\n return;\n }\n var style = this.interactionDOMElement.style;\n if (globalThis.navigator.msPointerEnabled) {\n style.msContentZooming = 'none';\n style.msTouchAction = 'none';\n }\n else if (this.supportsPointerEvents) {\n style.touchAction = 'none';\n }\n /*\n * These events are added first, so that if pointer events are normalized, they are fired\n * in the same order as non-normalized events. ie. pointer event 1st, mouse / touch 2nd\n */\n if (this.supportsPointerEvents) {\n globalThis.document.addEventListener('pointermove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('pointerdown', this.onPointerDown, this._eventListenerOptions);\n // pointerout is fired in addition to pointerup (for touch events) and pointercancel\n // we already handle those, so for the purposes of what we do in onPointerOut, we only\n // care about the pointerleave event\n this.interactionDOMElement.addEventListener('pointerleave', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('pointerover', this.onPointerOver, this._eventListenerOptions);\n globalThis.addEventListener('pointercancel', this.onPointerCancel, this._eventListenerOptions);\n globalThis.addEventListener('pointerup', this.onPointerUp, this._eventListenerOptions);\n }\n else {\n globalThis.document.addEventListener('mousemove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('mousedown', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('mouseout', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('mouseover', this.onPointerOver, this._eventListenerOptions);\n globalThis.addEventListener('mouseup', this.onPointerUp, this._eventListenerOptions);\n }\n // always look directly for touch events so that we can provide original data\n // In a future version we should change this to being just a fallback and rely solely on\n // PointerEvents whenever available\n if (this.supportsTouchEvents) {\n this.interactionDOMElement.addEventListener('touchstart', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('touchcancel', this.onPointerCancel, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('touchend', this.onPointerUp, this._eventListenerOptions);\n this.interactionDOMElement.addEventListener('touchmove', this.onPointerMove, this._eventListenerOptions);\n }\n this.eventsAdded = true;\n };\n /** Removes all the DOM events that were previously registered. */\n InteractionManager.prototype.removeEvents = function () {\n if (!this.eventsAdded || !this.interactionDOMElement) {\n return;\n }\n var style = this.interactionDOMElement.style;\n if (globalThis.navigator.msPointerEnabled) {\n style.msContentZooming = '';\n style.msTouchAction = '';\n }\n else if (this.supportsPointerEvents) {\n style.touchAction = '';\n }\n if (this.supportsPointerEvents) {\n globalThis.document.removeEventListener('pointermove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('pointerdown', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('pointerleave', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('pointerover', this.onPointerOver, this._eventListenerOptions);\n globalThis.removeEventListener('pointercancel', this.onPointerCancel, this._eventListenerOptions);\n globalThis.removeEventListener('pointerup', this.onPointerUp, this._eventListenerOptions);\n }\n else {\n globalThis.document.removeEventListener('mousemove', this.onPointerMove, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('mousedown', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('mouseout', this.onPointerOut, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('mouseover', this.onPointerOver, this._eventListenerOptions);\n globalThis.removeEventListener('mouseup', this.onPointerUp, this._eventListenerOptions);\n }\n if (this.supportsTouchEvents) {\n this.interactionDOMElement.removeEventListener('touchstart', this.onPointerDown, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('touchcancel', this.onPointerCancel, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('touchend', this.onPointerUp, this._eventListenerOptions);\n this.interactionDOMElement.removeEventListener('touchmove', this.onPointerMove, this._eventListenerOptions);\n }\n this.interactionDOMElement = null;\n this.eventsAdded = false;\n };\n /**\n * Updates the state of interactive objects if at least {@link interactionFrequency}\n * milliseconds have passed since the last invocation.\n *\n * Invoked by a throttled ticker update from {@link PIXI.Ticker.system}.\n *\n * @param deltaTime - time delta since the last call\n */\n InteractionManager.prototype.tickerUpdate = function (deltaTime) {\n this._deltaTime += deltaTime;\n if (this._deltaTime < this.interactionFrequency) {\n return;\n }\n this._deltaTime = 0;\n this.update();\n };\n /** Updates the state of interactive objects. */\n InteractionManager.prototype.update = function () {\n if (!this.interactionDOMElement) {\n return;\n }\n // if the user move the mouse this check has already been done using the mouse move!\n if (this._didMove) {\n this._didMove = false;\n return;\n }\n this.cursor = null;\n // Resets the flag as set by a stopPropagation call. This flag is usually reset by a user interaction of any kind,\n // but there was a scenario of a display object moving under a static mouse cursor.\n // In this case, mouseover and mouseevents would not pass the flag test in dispatchEvent function\n for (var k in this.activeInteractionData) {\n // eslint-disable-next-line no-prototype-builtins\n if (this.activeInteractionData.hasOwnProperty(k)) {\n var interactionData = this.activeInteractionData[k];\n if (interactionData.originalEvent && interactionData.pointerType !== 'touch') {\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, interactionData.originalEvent, interactionData);\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerOverOut, true);\n }\n }\n }\n this.setCursorMode(this.cursor);\n };\n /**\n * Sets the current cursor mode, handling any callbacks or CSS style changes.\n *\n * @param mode - cursor mode, a key from the cursorStyles dictionary\n */\n InteractionManager.prototype.setCursorMode = function (mode) {\n mode = mode || 'default';\n var applyStyles = true;\n // offscreen canvas does not support setting styles, but cursor modes can be functions,\n // in order to handle pixi rendered cursors, so we can't bail\n if (globalThis.OffscreenCanvas && this.interactionDOMElement instanceof OffscreenCanvas) {\n applyStyles = false;\n }\n // if the mode didn't actually change, bail early\n if (this.currentCursorMode === mode) {\n return;\n }\n this.currentCursorMode = mode;\n var style = this.cursorStyles[mode];\n // only do things if there is a cursor style for it\n if (style) {\n switch (typeof style) {\n case 'string':\n // string styles are handled as cursor CSS\n if (applyStyles) {\n this.interactionDOMElement.style.cursor = style;\n }\n break;\n case 'function':\n // functions are just called, and passed the cursor mode\n style(mode);\n break;\n case 'object':\n // if it is an object, assume that it is a dictionary of CSS styles,\n // apply it to the interactionDOMElement\n if (applyStyles) {\n Object.assign(this.interactionDOMElement.style, style);\n }\n break;\n }\n }\n else if (applyStyles && typeof mode === 'string' && !Object.prototype.hasOwnProperty.call(this.cursorStyles, mode)) {\n // if it mode is a string (not a Symbol) and cursorStyles doesn't have any entry\n // for the mode, then assume that the dev wants it to be CSS for the cursor.\n this.interactionDOMElement.style.cursor = mode;\n }\n };\n /**\n * Dispatches an event on the display object that was interacted with.\n *\n * @param displayObject - the display object in question\n * @param eventString - the name of the event (e.g, mousedown)\n * @param eventData - the event data object\n */\n InteractionManager.prototype.dispatchEvent = function (displayObject, eventString, eventData) {\n // Even if the event was stopped, at least dispatch any remaining events\n // for the same display object.\n if (!eventData.stopPropagationHint || displayObject === eventData.stopsPropagatingAt) {\n eventData.currentTarget = displayObject;\n eventData.type = eventString;\n displayObject.emit(eventString, eventData);\n if (displayObject[eventString]) {\n displayObject[eventString](eventData);\n }\n }\n };\n /**\n * Puts a event on a queue to be dispatched later. This is used to guarantee correct\n * ordering of over/out events.\n *\n * @param displayObject - the display object in question\n * @param eventString - the name of the event (e.g, mousedown)\n * @param eventData - the event data object\n */\n InteractionManager.prototype.delayDispatchEvent = function (displayObject, eventString, eventData) {\n this.delayedEvents.push({ displayObject: displayObject, eventString: eventString, eventData: eventData });\n };\n /**\n * Maps x and y coords from a DOM object and maps them correctly to the PixiJS view. The\n * resulting value is stored in the point. This takes into account the fact that the DOM\n * element could be scaled and positioned anywhere on the screen.\n *\n * @param point - the point that the result will be stored in\n * @param x - the x coord of the position to map\n * @param y - the y coord of the position to map\n */\n InteractionManager.prototype.mapPositionToPoint = function (point, x, y) {\n var rect;\n // IE 11 fix\n if (!this.interactionDOMElement.parentElement) {\n rect = {\n x: 0,\n y: 0,\n width: this.interactionDOMElement.width,\n height: this.interactionDOMElement.height,\n left: 0,\n top: 0\n };\n }\n else {\n rect = this.interactionDOMElement.getBoundingClientRect();\n }\n var resolutionMultiplier = 1.0 / this.resolution;\n point.x = ((x - rect.left) * (this.interactionDOMElement.width / rect.width)) * resolutionMultiplier;\n point.y = ((y - rect.top) * (this.interactionDOMElement.height / rect.height)) * resolutionMultiplier;\n };\n /**\n * This function is provides a neat way of crawling through the scene graph and running a\n * specified function on all interactive objects it finds. It will also take care of hit\n * testing the interactive objects and passes the hit across in the function.\n *\n * @protected\n * @param interactionEvent - event containing the point that\n * is tested for collision\n * @param displayObject - the displayObject\n * that will be hit test (recursively crawls its children)\n * @param func - the function that will be called on each interactive object. The\n * interactionEvent, displayObject and hit will be passed to the function\n * @param hitTest - indicates whether we want to calculate hits\n * or just iterate through all interactive objects\n */\n InteractionManager.prototype.processInteractive = function (interactionEvent, displayObject, func, hitTest) {\n var hit = this.search.findHit(interactionEvent, displayObject, func, hitTest);\n var delayedEvents = this.delayedEvents;\n if (!delayedEvents.length) {\n return hit;\n }\n // Reset the propagation hint, because we start deeper in the tree again.\n interactionEvent.stopPropagationHint = false;\n var delayedLen = delayedEvents.length;\n this.delayedEvents = [];\n for (var i = 0; i < delayedLen; i++) {\n var _a = delayedEvents[i], displayObject_1 = _a.displayObject, eventString = _a.eventString, eventData = _a.eventData;\n // When we reach the object we wanted to stop propagating at,\n // set the propagation hint.\n if (eventData.stopsPropagatingAt === displayObject_1) {\n eventData.stopPropagationHint = true;\n }\n this.dispatchEvent(displayObject_1, eventString, eventData);\n }\n return hit;\n };\n /**\n * Is called when the pointer button is pressed down on the renderer element\n *\n * @param originalEvent - The DOM event of a pointer button being pressed down\n */\n InteractionManager.prototype.onPointerDown = function (originalEvent) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && originalEvent.pointerType === 'touch')\n { return; }\n var events = this.normalizeToPointerData(originalEvent);\n /*\n * No need to prevent default on natural pointer events, as there are no side effects\n * Normalized events, however, may have the double mousedown/touchstart issue on the native android browser,\n * so still need to be prevented.\n */\n // Guaranteed that there will be at least one event in events, and all events must have the same pointer type\n if (this.autoPreventDefault && events[0].isNormalized) {\n var cancelable = originalEvent.cancelable || !('cancelable' in originalEvent);\n if (cancelable) {\n originalEvent.preventDefault();\n }\n }\n var eventLen = events.length;\n for (var i = 0; i < eventLen; i++) {\n var event = events[i];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = originalEvent;\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerDown, true);\n this.emit('pointerdown', interactionEvent);\n if (event.pointerType === 'touch') {\n this.emit('touchstart', interactionEvent);\n }\n // emit a mouse event for \"pen\" pointers, the way a browser would emit a fallback event\n else if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n var isRightButton = event.button === 2;\n this.emit(isRightButton ? 'rightdown' : 'mousedown', this.eventData);\n }\n }\n };\n /**\n * Processes the result of the pointer down check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerDown = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n if (hit) {\n if (!displayObject.trackedPointers[id]) {\n displayObject.trackedPointers[id] = new InteractionTrackingData(id);\n }\n this.dispatchEvent(displayObject, 'pointerdown', interactionEvent);\n if (data.pointerType === 'touch') {\n this.dispatchEvent(displayObject, 'touchstart', interactionEvent);\n }\n else if (data.pointerType === 'mouse' || data.pointerType === 'pen') {\n var isRightButton = data.button === 2;\n if (isRightButton) {\n displayObject.trackedPointers[id].rightDown = true;\n }\n else {\n displayObject.trackedPointers[id].leftDown = true;\n }\n this.dispatchEvent(displayObject, isRightButton ? 'rightdown' : 'mousedown', interactionEvent);\n }\n }\n };\n /**\n * Is called when the pointer button is released on the renderer element\n *\n * @param originalEvent - The DOM event of a pointer button being released\n * @param cancelled - true if the pointer is cancelled\n * @param func - Function passed to {@link processInteractive}\n */\n InteractionManager.prototype.onPointerComplete = function (originalEvent, cancelled, func) {\n var events = this.normalizeToPointerData(originalEvent);\n var eventLen = events.length;\n // if the event wasn't targeting our canvas, then consider it to be pointerupoutside\n // in all cases (unless it was a pointercancel)\n var eventAppend = originalEvent.target !== this.interactionDOMElement ? 'outside' : '';\n for (var i = 0; i < eventLen; i++) {\n var event = events[i];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = originalEvent;\n // perform hit testing for events targeting our canvas or cancel events\n this.processInteractive(interactionEvent, this.lastObjectRendered, func, cancelled || !eventAppend);\n this.emit(cancelled ? 'pointercancel' : \"pointerup\" + eventAppend, interactionEvent);\n if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n var isRightButton = event.button === 2;\n this.emit(isRightButton ? \"rightup\" + eventAppend : \"mouseup\" + eventAppend, interactionEvent);\n }\n else if (event.pointerType === 'touch') {\n this.emit(cancelled ? 'touchcancel' : \"touchend\" + eventAppend, interactionEvent);\n this.releaseInteractionDataForPointerId(event.pointerId);\n }\n }\n };\n /**\n * Is called when the pointer button is cancelled\n *\n * @param event - The DOM event of a pointer button being released\n */\n InteractionManager.prototype.onPointerCancel = function (event) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && event.pointerType === 'touch')\n { return; }\n this.onPointerComplete(event, true, this.processPointerCancel);\n };\n /**\n * Processes the result of the pointer cancel check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n */\n InteractionManager.prototype.processPointerCancel = function (interactionEvent, displayObject) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n if (displayObject.trackedPointers[id] !== undefined) {\n delete displayObject.trackedPointers[id];\n this.dispatchEvent(displayObject, 'pointercancel', interactionEvent);\n if (data.pointerType === 'touch') {\n this.dispatchEvent(displayObject, 'touchcancel', interactionEvent);\n }\n }\n };\n /**\n * Is called when the pointer button is released on the renderer element\n *\n * @param event - The DOM event of a pointer button being released\n */\n InteractionManager.prototype.onPointerUp = function (event) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && event.pointerType === 'touch')\n { return; }\n this.onPointerComplete(event, false, this.processPointerUp);\n };\n /**\n * Processes the result of the pointer up check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerUp = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n var trackingData = displayObject.trackedPointers[id];\n var isTouch = data.pointerType === 'touch';\n var isMouse = (data.pointerType === 'mouse' || data.pointerType === 'pen');\n // need to track mouse down status in the mouse block so that we can emit\n // event in a later block\n var isMouseTap = false;\n // Mouse only\n if (isMouse) {\n var isRightButton = data.button === 2;\n var flags = InteractionTrackingData.FLAGS;\n var test = isRightButton ? flags.RIGHT_DOWN : flags.LEFT_DOWN;\n var isDown = trackingData !== undefined && (trackingData.flags & test);\n if (hit) {\n this.dispatchEvent(displayObject, isRightButton ? 'rightup' : 'mouseup', interactionEvent);\n if (isDown) {\n this.dispatchEvent(displayObject, isRightButton ? 'rightclick' : 'click', interactionEvent);\n // because we can confirm that the mousedown happened on this object, flag for later emit of pointertap\n isMouseTap = true;\n }\n }\n else if (isDown) {\n this.dispatchEvent(displayObject, isRightButton ? 'rightupoutside' : 'mouseupoutside', interactionEvent);\n }\n // update the down state of the tracking data\n if (trackingData) {\n if (isRightButton) {\n trackingData.rightDown = false;\n }\n else {\n trackingData.leftDown = false;\n }\n }\n }\n // Pointers and Touches, and Mouse\n if (hit) {\n this.dispatchEvent(displayObject, 'pointerup', interactionEvent);\n if (isTouch)\n { this.dispatchEvent(displayObject, 'touchend', interactionEvent); }\n if (trackingData) {\n // emit pointertap if not a mouse, or if the mouse block decided it was a tap\n if (!isMouse || isMouseTap) {\n this.dispatchEvent(displayObject, 'pointertap', interactionEvent);\n }\n if (isTouch) {\n this.dispatchEvent(displayObject, 'tap', interactionEvent);\n // touches are no longer over (if they ever were) when we get the touchend\n // so we should ensure that we don't keep pretending that they are\n trackingData.over = false;\n }\n }\n }\n else if (trackingData) {\n this.dispatchEvent(displayObject, 'pointerupoutside', interactionEvent);\n if (isTouch)\n { this.dispatchEvent(displayObject, 'touchendoutside', interactionEvent); }\n }\n // Only remove the tracking data if there is no over/down state still associated with it\n if (trackingData && trackingData.none) {\n delete displayObject.trackedPointers[id];\n }\n };\n /**\n * Is called when the pointer moves across the renderer element\n *\n * @param originalEvent - The DOM event of a pointer moving\n */\n InteractionManager.prototype.onPointerMove = function (originalEvent) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && originalEvent.pointerType === 'touch')\n { return; }\n var events = this.normalizeToPointerData(originalEvent);\n if (events[0].pointerType === 'mouse' || events[0].pointerType === 'pen') {\n this._didMove = true;\n this.cursor = null;\n }\n var eventLen = events.length;\n for (var i = 0; i < eventLen; i++) {\n var event = events[i];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = originalEvent;\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerMove, true);\n this.emit('pointermove', interactionEvent);\n if (event.pointerType === 'touch')\n { this.emit('touchmove', interactionEvent); }\n if (event.pointerType === 'mouse' || event.pointerType === 'pen')\n { this.emit('mousemove', interactionEvent); }\n }\n if (events[0].pointerType === 'mouse') {\n this.setCursorMode(this.cursor);\n // TODO BUG for parents interactive object (border order issue)\n }\n };\n /**\n * Processes the result of the pointer move check and dispatches the event if need be\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerMove = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var isTouch = data.pointerType === 'touch';\n var isMouse = (data.pointerType === 'mouse' || data.pointerType === 'pen');\n if (isMouse) {\n this.processPointerOverOut(interactionEvent, displayObject, hit);\n }\n if (!this.moveWhenInside || hit) {\n this.dispatchEvent(displayObject, 'pointermove', interactionEvent);\n if (isTouch)\n { this.dispatchEvent(displayObject, 'touchmove', interactionEvent); }\n if (isMouse)\n { this.dispatchEvent(displayObject, 'mousemove', interactionEvent); }\n }\n };\n /**\n * Is called when the pointer is moved out of the renderer element\n *\n * @private\n * @param {PointerEvent} originalEvent - The DOM event of a pointer being moved out\n */\n InteractionManager.prototype.onPointerOut = function (originalEvent) {\n // if we support touch events, then only use those for touch events, not pointer events\n if (this.supportsTouchEvents && originalEvent.pointerType === 'touch')\n { return; }\n var events = this.normalizeToPointerData(originalEvent);\n // Only mouse and pointer can call onPointerOut, so events will always be length 1\n var event = events[0];\n if (event.pointerType === 'mouse') {\n this.mouseOverRenderer = false;\n this.setCursorMode(null);\n }\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = event;\n this.processInteractive(interactionEvent, this.lastObjectRendered, this.processPointerOverOut, false);\n this.emit('pointerout', interactionEvent);\n if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n this.emit('mouseout', interactionEvent);\n }\n else {\n // we can get touchleave events after touchend, so we want to make sure we don't\n // introduce memory leaks\n this.releaseInteractionDataForPointerId(interactionData.identifier);\n }\n };\n /**\n * Processes the result of the pointer over/out check and dispatches the event if need be.\n *\n * @param interactionEvent - The interaction event wrapping the DOM event\n * @param displayObject - The display object that was tested\n * @param hit - the result of the hit test on the display object\n */\n InteractionManager.prototype.processPointerOverOut = function (interactionEvent, displayObject, hit) {\n var data = interactionEvent.data;\n var id = interactionEvent.data.identifier;\n var isMouse = (data.pointerType === 'mouse' || data.pointerType === 'pen');\n var trackingData = displayObject.trackedPointers[id];\n // if we just moused over the display object, then we need to track that state\n if (hit && !trackingData) {\n trackingData = displayObject.trackedPointers[id] = new InteractionTrackingData(id);\n }\n if (trackingData === undefined)\n { return; }\n if (hit && this.mouseOverRenderer) {\n if (!trackingData.over) {\n trackingData.over = true;\n this.delayDispatchEvent(displayObject, 'pointerover', interactionEvent);\n if (isMouse) {\n this.delayDispatchEvent(displayObject, 'mouseover', interactionEvent);\n }\n }\n // only change the cursor if it has not already been changed (by something deeper in the\n // display tree)\n if (isMouse && this.cursor === null) {\n this.cursor = displayObject.cursor;\n }\n }\n else if (trackingData.over) {\n trackingData.over = false;\n this.dispatchEvent(displayObject, 'pointerout', this.eventData);\n if (isMouse) {\n this.dispatchEvent(displayObject, 'mouseout', interactionEvent);\n }\n // if there is no mouse down information for the pointer, then it is safe to delete\n if (trackingData.none) {\n delete displayObject.trackedPointers[id];\n }\n }\n };\n /**\n * Is called when the pointer is moved into the renderer element.\n *\n * @param originalEvent - The DOM event of a pointer button being moved into the renderer view.\n */\n InteractionManager.prototype.onPointerOver = function (originalEvent) {\n var events = this.normalizeToPointerData(originalEvent);\n // Only mouse and pointer can call onPointerOver, so events will always be length 1\n var event = events[0];\n var interactionData = this.getInteractionDataForPointerId(event);\n var interactionEvent = this.configureInteractionEventForDOMEvent(this.eventData, event, interactionData);\n interactionEvent.data.originalEvent = event;\n if (event.pointerType === 'mouse') {\n this.mouseOverRenderer = true;\n }\n this.emit('pointerover', interactionEvent);\n if (event.pointerType === 'mouse' || event.pointerType === 'pen') {\n this.emit('mouseover', interactionEvent);\n }\n };\n /**\n * Get InteractionData for a given pointerId. Store that data as well.\n *\n * @param event - Normalized pointer event, output from normalizeToPointerData.\n * @return - Interaction data for the given pointer identifier.\n */\n InteractionManager.prototype.getInteractionDataForPointerId = function (event) {\n var pointerId = event.pointerId;\n var interactionData;\n if (pointerId === MOUSE_POINTER_ID || event.pointerType === 'mouse') {\n interactionData = this.mouse;\n }\n else if (this.activeInteractionData[pointerId]) {\n interactionData = this.activeInteractionData[pointerId];\n }\n else {\n interactionData = this.interactionDataPool.pop() || new InteractionData();\n interactionData.identifier = pointerId;\n this.activeInteractionData[pointerId] = interactionData;\n }\n // copy properties from the event, so that we can make sure that touch/pointer specific\n // data is available\n interactionData.copyEvent(event);\n return interactionData;\n };\n /**\n * Return unused InteractionData to the pool, for a given pointerId\n *\n * @param pointerId - Identifier from a pointer event\n */\n InteractionManager.prototype.releaseInteractionDataForPointerId = function (pointerId) {\n var interactionData = this.activeInteractionData[pointerId];\n if (interactionData) {\n delete this.activeInteractionData[pointerId];\n interactionData.reset();\n this.interactionDataPool.push(interactionData);\n }\n };\n /**\n * Configure an InteractionEvent to wrap a DOM PointerEvent and InteractionData\n *\n * @param interactionEvent - The event to be configured\n * @param pointerEvent - The DOM event that will be paired with the InteractionEvent\n * @param interactionData - The InteractionData that will be paired\n * with the InteractionEvent\n * @return - the interaction event that was passed in\n */\n InteractionManager.prototype.configureInteractionEventForDOMEvent = function (interactionEvent, pointerEvent, interactionData) {\n interactionEvent.data = interactionData;\n this.mapPositionToPoint(interactionData.global, pointerEvent.clientX, pointerEvent.clientY);\n // Not really sure why this is happening, but it's how a previous version handled things\n if (pointerEvent.pointerType === 'touch') {\n pointerEvent.globalX = interactionData.global.x;\n pointerEvent.globalY = interactionData.global.y;\n }\n interactionData.originalEvent = pointerEvent;\n interactionEvent.reset();\n return interactionEvent;\n };\n /**\n * Ensures that the original event object contains all data that a regular pointer event would have\n *\n * @param {TouchEvent|MouseEvent|PointerEvent} event - The original event data from a touch or mouse event\n * @return - An array containing a single normalized pointer event, in the case of a pointer\n * or mouse event, or a multiple normalized pointer events if there are multiple changed touches\n */\n InteractionManager.prototype.normalizeToPointerData = function (event) {\n var normalizedEvents = [];\n if (this.supportsTouchEvents && event instanceof TouchEvent) {\n for (var i = 0, li = event.changedTouches.length; i < li; i++) {\n var touch = event.changedTouches[i];\n if (typeof touch.button === 'undefined')\n { touch.button = event.touches.length ? 1 : 0; }\n if (typeof touch.buttons === 'undefined')\n { touch.buttons = event.touches.length ? 1 : 0; }\n if (typeof touch.isPrimary === 'undefined') {\n touch.isPrimary = event.touches.length === 1 && event.type === 'touchstart';\n }\n if (typeof touch.width === 'undefined')\n { touch.width = touch.radiusX || 1; }\n if (typeof touch.height === 'undefined')\n { touch.height = touch.radiusY || 1; }\n if (typeof touch.tiltX === 'undefined')\n { touch.tiltX = 0; }\n if (typeof touch.tiltY === 'undefined')\n { touch.tiltY = 0; }\n if (typeof touch.pointerType === 'undefined')\n { touch.pointerType = 'touch'; }\n if (typeof touch.pointerId === 'undefined')\n { touch.pointerId = touch.identifier || 0; }\n if (typeof touch.pressure === 'undefined')\n { touch.pressure = touch.force || 0.5; }\n if (typeof touch.twist === 'undefined')\n { touch.twist = 0; }\n if (typeof touch.tangentialPressure === 'undefined')\n { touch.tangentialPressure = 0; }\n // TODO: Remove these, as layerX/Y is not a standard, is deprecated, has uneven\n // support, and the fill ins are not quite the same\n // offsetX/Y might be okay, but is not the same as clientX/Y when the canvas's top\n // left is not 0,0 on the page\n if (typeof touch.layerX === 'undefined')\n { touch.layerX = touch.offsetX = touch.clientX; }\n if (typeof touch.layerY === 'undefined')\n { touch.layerY = touch.offsetY = touch.clientY; }\n // mark the touch as normalized, just so that we know we did it\n touch.isNormalized = true;\n normalizedEvents.push(touch);\n }\n }\n // apparently PointerEvent subclasses MouseEvent, so yay\n else if (!globalThis.MouseEvent\n || (event instanceof MouseEvent && (!this.supportsPointerEvents || !(event instanceof globalThis.PointerEvent)))) {\n var tempEvent = event;\n if (typeof tempEvent.isPrimary === 'undefined')\n { tempEvent.isPrimary = true; }\n if (typeof tempEvent.width === 'undefined')\n { tempEvent.width = 1; }\n if (typeof tempEvent.height === 'undefined')\n { tempEvent.height = 1; }\n if (typeof tempEvent.tiltX === 'undefined')\n { tempEvent.tiltX = 0; }\n if (typeof tempEvent.tiltY === 'undefined')\n { tempEvent.tiltY = 0; }\n if (typeof tempEvent.pointerType === 'undefined')\n { tempEvent.pointerType = 'mouse'; }\n if (typeof tempEvent.pointerId === 'undefined')\n { tempEvent.pointerId = MOUSE_POINTER_ID; }\n if (typeof tempEvent.pressure === 'undefined')\n { tempEvent.pressure = 0.5; }\n if (typeof tempEvent.twist === 'undefined')\n { tempEvent.twist = 0; }\n if (typeof tempEvent.tangentialPressure === 'undefined')\n { tempEvent.tangentialPressure = 0; }\n // mark the mouse event as normalized, just so that we know we did it\n tempEvent.isNormalized = true;\n normalizedEvents.push(tempEvent);\n }\n else {\n normalizedEvents.push(event);\n }\n return normalizedEvents;\n };\n /** Destroys the interaction manager. */\n InteractionManager.prototype.destroy = function () {\n this.removeEvents();\n this.removeTickerListener();\n this.removeAllListeners();\n this.renderer = null;\n this.mouse = null;\n this.eventData = null;\n this.interactionDOMElement = null;\n this.onPointerDown = null;\n this.processPointerDown = null;\n this.onPointerUp = null;\n this.processPointerUp = null;\n this.onPointerCancel = null;\n this.processPointerCancel = null;\n this.onPointerMove = null;\n this.processPointerMove = null;\n this.onPointerOut = null;\n this.processPointerOverOut = null;\n this.onPointerOver = null;\n this.search = null;\n };\n return InteractionManager;\n}(EventEmitter));\n\nexport { InteractionData, InteractionEvent, InteractionManager, InteractionTrackingData, interactiveTarget };\n//# sourceMappingURL=interaction.js.map\n","/*!\n * @pixi/app - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/app is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Container } from '@pixi/display';\nimport { autoDetectRenderer } from '@pixi/core';\n\n/**\n * Convenience class to create a new PIXI application.\n *\n * This class automatically creates the renderer, ticker and root container.\n *\n * @example\n * // Create the application\n * const app = new PIXI.Application();\n *\n * // Add the view to the DOM\n * document.body.appendChild(app.view);\n *\n * // ex, add display objects\n * app.stage.addChild(PIXI.Sprite.from('something.png'));\n *\n * @class\n * @memberof PIXI\n */\nvar Application = /** @class */ (function () {\n /**\n * @param {object} [options] - The optional renderer parameters.\n * @param {boolean} [options.autoStart=true] - Automatically starts the rendering after the construction.\n * **Note**: Setting this parameter to false does NOT stop the shared ticker even if you set\n * options.sharedTicker to true in case that it is already started. Stop it by your own.\n * @param {number} [options.width=800] - The width of the renderers view.\n * @param {number} [options.height=600] - The height of the renderers view.\n * @param {HTMLCanvasElement} [options.view] - The canvas to use as a view, optional.\n * @param {boolean} [options.useContextAlpha=true] - Pass-through value for canvas' context `alpha` property.\n * If you want to set transparency, please use `backgroundAlpha`. This option is for cases where the\n * canvas needs to be opaque, possibly for performance reasons on some older devices.\n * @param {boolean} [options.autoDensity=false] - Resizes renderer view in CSS pixels to allow for\n * resolutions other than 1.\n * @param {boolean} [options.antialias=false] - Sets antialias\n * @param {boolean} [options.preserveDrawingBuffer=false] - Enables drawing buffer preservation, enable this if you\n * need to call toDataUrl on the WebGL context.\n * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the renderer.\n * @param {boolean} [options.forceCanvas=false] - prevents selection of WebGL renderer, even if such is present, this\n * option only is available when using **pixi.js-legacy** or **@pixi/canvas-renderer** modules, otherwise\n * it is ignored.\n * @param {number} [options.backgroundColor=0x000000] - The background color of the rendered area\n * (shown if not transparent).\n * @param {number} [options.backgroundAlpha=1] - Value from 0 (fully transparent) to 1 (fully opaque).\n * @param {boolean} [options.clearBeforeRender=true] - This sets if the renderer will clear the canvas or\n * not before the new render pass.\n * @param {string} [options.powerPreference] - Parameter passed to webgl context, set to \"high-performance\"\n * for devices with dual graphics card. **(WebGL only)**.\n * @param {boolean} [options.sharedTicker=false] - `true` to use PIXI.Ticker.shared, `false` to create new ticker.\n * If set to false, you cannot register a handler to occur before anything that runs on the shared ticker.\n * The system ticker will always run before both the shared ticker and the app ticker.\n * @param {boolean} [options.sharedLoader=false] - `true` to use PIXI.Loader.shared, `false` to create new Loader.\n * @param {Window|HTMLElement} [options.resizeTo] - Element to automatically resize stage to.\n */\n function Application(options) {\n var _this = this;\n /**\n * The root display container that's rendered.\n * @member {PIXI.Container}\n */\n this.stage = new Container();\n // The default options\n options = Object.assign({\n forceCanvas: false,\n }, options);\n this.renderer = autoDetectRenderer(options);\n // install plugins here\n Application._plugins.forEach(function (plugin) {\n plugin.init.call(_this, options);\n });\n }\n /**\n * Register a middleware plugin for the application\n * @static\n * @param {PIXI.IApplicationPlugin} plugin - Plugin being installed\n */\n Application.registerPlugin = function (plugin) {\n Application._plugins.push(plugin);\n };\n /**\n * Render the current stage.\n */\n Application.prototype.render = function () {\n this.renderer.render(this.stage);\n };\n Object.defineProperty(Application.prototype, \"view\", {\n /**\n * Reference to the renderer's canvas element.\n * @member {HTMLCanvasElement}\n * @readonly\n */\n get: function () {\n return this.renderer.view;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Application.prototype, \"screen\", {\n /**\n * Reference to the renderer's screen rectangle. Its safe to use as `filterArea` or `hitArea` for the whole screen.\n * @member {PIXI.Rectangle}\n * @readonly\n */\n get: function () {\n return this.renderer.screen;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Destroy and don't use after this.\n * @param {Boolean} [removeView=false] - Automatically remove canvas from DOM.\n * @param {object|boolean} [stageOptions] - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [stageOptions.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'stageOptions' will be passed on to those calls.\n * @param {boolean} [stageOptions.texture=false] - Only used for child Sprites if stageOptions.children is set\n * to true. Should it destroy the texture of the child sprite\n * @param {boolean} [stageOptions.baseTexture=false] - Only used for child Sprites if stageOptions.children is set\n * to true. Should it destroy the base texture of the child sprite\n */\n Application.prototype.destroy = function (removeView, stageOptions) {\n var _this = this;\n // Destroy plugins in the opposite order\n // which they were constructed\n var plugins = Application._plugins.slice(0);\n plugins.reverse();\n plugins.forEach(function (plugin) {\n plugin.destroy.call(_this);\n });\n this.stage.destroy(stageOptions);\n this.stage = null;\n this.renderer.destroy(removeView);\n this.renderer = null;\n };\n /** Collection of installed plugins. */\n Application._plugins = [];\n return Application;\n}());\n\n/**\n * Middleware for for Application's resize functionality\n * @private\n * @class\n */\nvar ResizePlugin = /** @class */ (function () {\n function ResizePlugin() {\n }\n /**\n * Initialize the plugin with scope of application instance\n * @static\n * @private\n * @param {object} [options] - See application options\n */\n ResizePlugin.init = function (options) {\n var _this = this;\n Object.defineProperty(this, 'resizeTo', \n /**\n * The HTML element or window to automatically resize the\n * renderer's view element to match width and height.\n * @member {Window|HTMLElement}\n * @name resizeTo\n * @memberof PIXI.Application#\n */\n {\n set: function (dom) {\n globalThis.removeEventListener('resize', this.queueResize);\n this._resizeTo = dom;\n if (dom) {\n globalThis.addEventListener('resize', this.queueResize);\n this.resize();\n }\n },\n get: function () {\n return this._resizeTo;\n },\n });\n /**\n * Resize is throttled, so it's safe to call this multiple times per frame and it'll\n * only be called once.\n *\n * @memberof PIXI.Application#\n * @method queueResize\n * @private\n */\n this.queueResize = function () {\n if (!_this._resizeTo) {\n return;\n }\n _this.cancelResize();\n // // Throttle resize events per raf\n _this._resizeId = requestAnimationFrame(function () { return _this.resize(); });\n };\n /**\n * Cancel the resize queue.\n *\n * @memberof PIXI.Application#\n * @method cancelResize\n * @private\n */\n this.cancelResize = function () {\n if (_this._resizeId) {\n cancelAnimationFrame(_this._resizeId);\n _this._resizeId = null;\n }\n };\n /**\n * Execute an immediate resize on the renderer, this is not\n * throttled and can be expensive to call many times in a row.\n * Will resize only if `resizeTo` property is set.\n *\n * @memberof PIXI.Application#\n * @method resize\n */\n this.resize = function () {\n if (!_this._resizeTo) {\n return;\n }\n // clear queue resize\n _this.cancelResize();\n var width;\n var height;\n // Resize to the window\n if (_this._resizeTo === globalThis.window) {\n width = globalThis.innerWidth;\n height = globalThis.innerHeight;\n }\n // Resize to other HTML entities\n else {\n var _a = _this._resizeTo, clientWidth = _a.clientWidth, clientHeight = _a.clientHeight;\n width = clientWidth;\n height = clientHeight;\n }\n _this.renderer.resize(width, height);\n };\n // On resize\n this._resizeId = null;\n this._resizeTo = null;\n this.resizeTo = options.resizeTo || null;\n };\n /**\n * Clean up the ticker, scoped to application\n *\n * @static\n * @private\n */\n ResizePlugin.destroy = function () {\n globalThis.removeEventListener('resize', this.queueResize);\n this.cancelResize();\n this.cancelResize = null;\n this.queueResize = null;\n this.resizeTo = null;\n this.resize = null;\n };\n return ResizePlugin;\n}());\n\nApplication.registerPlugin(ResizePlugin);\n\nexport { Application };\n//# sourceMappingURL=app.js.map\n","/*!\n * @pixi/extract - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/extract is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { CanvasRenderTarget } from '@pixi/utils';\nimport { Rectangle } from '@pixi/math';\nimport { RenderTexture } from '@pixi/core';\n\nvar TEMP_RECT = new Rectangle();\nvar BYTES_PER_PIXEL = 4;\n/**\n * This class provides renderer-specific plugins for exporting content from a renderer.\n * For instance, these plugins can be used for saving an Image, Canvas element or for exporting the raw image data (pixels).\n *\n * Do not instantiate these plugins directly. It is available from the `renderer.plugins` property.\n * See {@link PIXI.CanvasRenderer#plugins} or {@link PIXI.Renderer#plugins}.\n *\n * @example\n * // Create a new app (will auto-add extract plugin to renderer)\n * const app = new PIXI.Application();\n *\n * // Draw a red circle\n * const graphics = new PIXI.Graphics()\n * .beginFill(0xFF0000)\n * .drawCircle(0, 0, 50);\n *\n * // Render the graphics as an HTMLImageElement\n * const image = app.renderer.plugins.extract.image(graphics);\n * document.body.appendChild(image);\n *\n * @memberof PIXI\n */\nvar Extract = /** @class */ (function () {\n /**\n * @param renderer - A reference to the current renderer\n */\n function Extract(renderer) {\n this.renderer = renderer;\n }\n /**\n * Will return a HTML Image of the target\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @param format - Image format, e.g. \"image/jpeg\" or \"image/webp\".\n * @param quality - JPEG or Webp compression from 0 to 1. Default is 0.92.\n * @return - HTML Image of the target\n */\n Extract.prototype.image = function (target, format, quality) {\n var image = new Image();\n image.src = this.base64(target, format, quality);\n return image;\n };\n /**\n * Will return a base64 encoded string of this target. It works by calling\n * `Extract.getCanvas` and then running toDataURL on that.\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @param format - Image format, e.g. \"image/jpeg\" or \"image/webp\".\n * @param quality - JPEG or Webp compression from 0 to 1. Default is 0.92.\n * @return - A base64 encoded string of the texture.\n */\n Extract.prototype.base64 = function (target, format, quality) {\n return this.canvas(target).toDataURL(format, quality);\n };\n /**\n * Creates a Canvas element, renders this target to it and then returns it.\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @return - A Canvas element with the texture rendered on.\n */\n Extract.prototype.canvas = function (target) {\n var renderer = this.renderer;\n var resolution;\n var frame;\n var flipY = false;\n var renderTexture;\n var generated = false;\n if (target) {\n if (target instanceof RenderTexture) {\n renderTexture = target;\n }\n else {\n renderTexture = this.renderer.generateTexture(target);\n generated = true;\n }\n }\n if (renderTexture) {\n resolution = renderTexture.baseTexture.resolution;\n frame = renderTexture.frame;\n flipY = false;\n renderer.renderTexture.bind(renderTexture);\n }\n else {\n resolution = this.renderer.resolution;\n flipY = true;\n frame = TEMP_RECT;\n frame.width = this.renderer.width;\n frame.height = this.renderer.height;\n renderer.renderTexture.bind(null);\n }\n var width = Math.floor((frame.width * resolution) + 1e-4);\n var height = Math.floor((frame.height * resolution) + 1e-4);\n var canvasBuffer = new CanvasRenderTarget(width, height, 1);\n var webglPixels = new Uint8Array(BYTES_PER_PIXEL * width * height);\n // read pixels to the array\n var gl = renderer.gl;\n gl.readPixels(frame.x * resolution, frame.y * resolution, width, height, gl.RGBA, gl.UNSIGNED_BYTE, webglPixels);\n // add the pixels to the canvas\n var canvasData = canvasBuffer.context.getImageData(0, 0, width, height);\n Extract.arrayPostDivide(webglPixels, canvasData.data);\n canvasBuffer.context.putImageData(canvasData, 0, 0);\n // pulling pixels\n if (flipY) {\n var target_1 = new CanvasRenderTarget(canvasBuffer.width, canvasBuffer.height, 1);\n target_1.context.scale(1, -1);\n // we can't render to itself because we should be empty before render.\n target_1.context.drawImage(canvasBuffer.canvas, 0, -height);\n canvasBuffer.destroy();\n canvasBuffer = target_1;\n }\n if (generated) {\n renderTexture.destroy(true);\n }\n // send the canvas back..\n return canvasBuffer.canvas;\n };\n /**\n * Will return a one-dimensional array containing the pixel data of the entire texture in RGBA\n * order, with integer values between 0 and 255 (included).\n *\n * @param target - A displayObject or renderTexture\n * to convert. If left empty will use the main renderer\n * @return - One-dimensional array containing the pixel data of the entire texture\n */\n Extract.prototype.pixels = function (target) {\n var renderer = this.renderer;\n var resolution;\n var frame;\n var renderTexture;\n var generated = false;\n if (target) {\n if (target instanceof RenderTexture) {\n renderTexture = target;\n }\n else {\n renderTexture = this.renderer.generateTexture(target);\n generated = true;\n }\n }\n if (renderTexture) {\n resolution = renderTexture.baseTexture.resolution;\n frame = renderTexture.frame;\n // bind the buffer\n renderer.renderTexture.bind(renderTexture);\n }\n else {\n resolution = renderer.resolution;\n frame = TEMP_RECT;\n frame.width = renderer.width;\n frame.height = renderer.height;\n renderer.renderTexture.bind(null);\n }\n var width = frame.width * resolution;\n var height = frame.height * resolution;\n var webglPixels = new Uint8Array(BYTES_PER_PIXEL * width * height);\n // read pixels to the array\n var gl = renderer.gl;\n gl.readPixels(frame.x * resolution, frame.y * resolution, width, height, gl.RGBA, gl.UNSIGNED_BYTE, webglPixels);\n if (generated) {\n renderTexture.destroy(true);\n }\n Extract.arrayPostDivide(webglPixels, webglPixels);\n return webglPixels;\n };\n /** Destroys the extract. */\n Extract.prototype.destroy = function () {\n this.renderer = null;\n };\n /**\n * Takes premultiplied pixel data and produces regular pixel data\n *\n * @private\n * @param pixels - array of pixel data\n * @param out - output array\n */\n Extract.arrayPostDivide = function (pixels, out) {\n for (var i = 0; i < pixels.length; i += 4) {\n var alpha = out[i + 3] = pixels[i + 3];\n if (alpha !== 0) {\n out[i] = Math.round(Math.min(pixels[i] * 255.0 / alpha, 255.0));\n out[i + 1] = Math.round(Math.min(pixels[i + 1] * 255.0 / alpha, 255.0));\n out[i + 2] = Math.round(Math.min(pixels[i + 2] * 255.0 / alpha, 255.0));\n }\n else {\n out[i] = pixels[i];\n out[i + 1] = pixels[i + 1];\n out[i + 2] = pixels[i + 2];\n }\n }\n };\n return Extract;\n}());\n\nexport { Extract };\n//# sourceMappingURL=extract.js.map\n","/*!\n * @pixi/loaders - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/loaders is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture } from '@pixi/core';\n\n/* jshint -W097 */\n/**\n * @memberof PIXI\n */\nvar SignalBinding = /** @class */ (function () {\n /**\n * SignalBinding constructor.\n * @constructs SignalBinding\n * @param {Function} fn - Event handler to be called.\n * @param {Boolean} [once=false] - Should this listener be removed after dispatch\n * @param {object} [thisArg] - The context of the callback function.\n * @api private\n */\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n function SignalBinding(fn, once, thisArg) {\n if (once === void 0) { once = false; }\n this._fn = fn;\n this._once = once;\n this._thisArg = thisArg;\n this._next = this._prev = this._owner = null;\n }\n SignalBinding.prototype.detach = function () {\n if (this._owner === null)\n { return false; }\n this._owner.detach(this);\n return true;\n };\n return SignalBinding;\n}());\n/**\n * @private\n */\nfunction _addSignalBinding(self, node) {\n if (!self._head) {\n self._head = node;\n self._tail = node;\n }\n else {\n self._tail._next = node;\n node._prev = self._tail;\n self._tail = node;\n }\n node._owner = self;\n return node;\n}\n/**\n * @memberof PIXI\n */\nvar Signal = /** @class */ (function () {\n /**\n * MiniSignal constructor.\n * @example\n * let mySignal = new Signal();\n * let binding = mySignal.add(onSignal);\n * mySignal.dispatch('foo', 'bar');\n * mySignal.detach(binding);\n */\n function Signal() {\n this._head = this._tail = undefined;\n }\n /**\n * Return an array of attached SignalBinding.\n *\n * @param {Boolean} [exists=false] - We only need to know if there are handlers.\n * @returns {PIXI.SignalBinding[]|Boolean} Array of attached SignalBinding or Boolean if called with exists = true\n * @api public\n */\n Signal.prototype.handlers = function (exists) {\n if (exists === void 0) { exists = false; }\n var node = this._head;\n if (exists)\n { return !!node; }\n var ee = [];\n while (node) {\n ee.push(node);\n node = node._next;\n }\n return ee;\n };\n /**\n * Return true if node is a SignalBinding attached to this MiniSignal\n *\n * @param {PIXI.SignalBinding} node - Node to check.\n * @returns {Boolean} True if node is attache to mini-signal\n */\n Signal.prototype.has = function (node) {\n if (!(node instanceof SignalBinding)) {\n throw new Error('MiniSignal#has(): First arg must be a SignalBinding object.');\n }\n return node._owner === this;\n };\n /**\n * Dispaches a signal to all registered listeners.\n *\n * @returns {Boolean} Indication if we've emitted an event.\n */\n Signal.prototype.dispatch = function () {\n var arguments$1 = arguments;\n\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments$1[_i];\n }\n var node = this._head;\n if (!node)\n { return false; }\n while (node) {\n if (node._once)\n { this.detach(node); }\n node._fn.apply(node._thisArg, args);\n node = node._next;\n }\n return true;\n };\n /**\n * Register a new listener.\n *\n * @param {Function} fn - Callback function.\n * @param {object} [thisArg] - The context of the callback function.\n * @returns {PIXI.SignalBinding} The SignalBinding node that was added.\n */\n Signal.prototype.add = function (fn, thisArg) {\n if (thisArg === void 0) { thisArg = null; }\n if (typeof fn !== 'function') {\n throw new Error('MiniSignal#add(): First arg must be a Function.');\n }\n return _addSignalBinding(this, new SignalBinding(fn, false, thisArg));\n };\n /**\n * Register a new listener that will be executed only once.\n *\n * @param {Function} fn - Callback function.\n * @param {object} [thisArg] - The context of the callback function.\n * @returns {PIXI.SignalBinding} The SignalBinding node that was added.\n */\n Signal.prototype.once = function (fn, thisArg) {\n if (thisArg === void 0) { thisArg = null; }\n if (typeof fn !== 'function') {\n throw new Error('MiniSignal#once(): First arg must be a Function.');\n }\n return _addSignalBinding(this, new SignalBinding(fn, true, thisArg));\n };\n /**\n * Remove binding object.\n *\n * @param {PIXI.SignalBinding} node - The binding node that will be removed.\n * @returns {Signal} The instance on which this method was called.\n * @api public */\n Signal.prototype.detach = function (node) {\n if (!(node instanceof SignalBinding)) {\n throw new Error('MiniSignal#detach(): First arg must be a SignalBinding object.');\n }\n if (node._owner !== this)\n { return this; } // todo: or error?\n if (node._prev)\n { node._prev._next = node._next; }\n if (node._next)\n { node._next._prev = node._prev; }\n if (node === this._head) { // first node\n this._head = node._next;\n if (node._next === null) {\n this._tail = null;\n }\n }\n else if (node === this._tail) { // last node\n this._tail = node._prev;\n this._tail._next = null;\n }\n node._owner = null;\n return this;\n };\n /**\n * Detach all listeners.\n *\n * @returns {Signal} The instance on which this method was called.\n */\n Signal.prototype.detachAll = function () {\n var node = this._head;\n if (!node)\n { return this; }\n this._head = this._tail = null;\n while (node) {\n node._owner = null;\n node = node._next;\n }\n return this;\n };\n return Signal;\n}());\n\n/**\n * function from npm package `parseUri`, converted to TS to avoid leftpad incident\n * @param {string} str\n * @param [opts] - options\n * @param {boolean} [opts.strictMode] - type of parser\n */\nfunction parseUri(str, opts) {\n opts = opts || {};\n var o = {\n // eslint-disable-next-line max-len\n key: ['source', 'protocol', 'authority', 'userInfo', 'user', 'password', 'host', 'port', 'relative', 'path', 'directory', 'file', 'query', 'anchor'],\n q: {\n name: 'queryKey',\n parser: /(?:^|&)([^&=]*)=?([^&]*)/g\n },\n parser: {\n // eslint-disable-next-line max-len\n strict: /^(?:([^:\\/?#]+):)?(?:\\/\\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\\/?#]*)(?::(\\d*))?))?((((?:[^?#\\/]*\\/)*)([^?#]*))(?:\\?([^#]*))?(?:#(.*))?)/,\n // eslint-disable-next-line max-len\n loose: /^(?:(?![^:@]+:[^:@\\/]*@)([^:\\/?#.]+):)?(?:\\/\\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\\/?#]*)(?::(\\d*))?)(((\\/(?:[^?#](?![^?#\\/]*\\.[^?#\\/.]+(?:[?#]|$)))*\\/?)?([^?#\\/]*))(?:\\?([^#]*))?(?:#(.*))?)/\n }\n };\n var m = o.parser[opts.strictMode ? 'strict' : 'loose'].exec(str);\n var uri = {};\n var i = 14;\n while (i--)\n { uri[o.key[i]] = m[i] || ''; }\n uri[o.q.name] = {};\n uri[o.key[12]].replace(o.q.parser, function (_t0, t1, t2) {\n if (t1)\n { uri[o.q.name][t1] = t2; }\n });\n return uri;\n}\n\n// tests if CORS is supported in XHR, if not we need to use XDR\nvar useXdr = !!(globalThis.XDomainRequest && !('withCredentials' in (new XMLHttpRequest())));\nvar tempAnchor = null;\n// some status constants\nvar STATUS_NONE = 0;\nvar STATUS_OK = 200;\nvar STATUS_EMPTY = 204;\nvar STATUS_IE_BUG_EMPTY = 1223;\nvar STATUS_TYPE_OK = 2;\n// noop\nfunction _noop() { }\n/**\n * Quick helper to set a value on one of the extension maps. Ensures there is no\n * dot at the start of the extension.\n *\n * @ignore\n * @param map - The map to set on.\n * @param extname - The extension (or key) to set.\n * @param val - The value to set.\n */\nfunction setExtMap(map, extname, val) {\n if (extname && extname.indexOf('.') === 0) {\n extname = extname.substring(1);\n }\n if (!extname) {\n return;\n }\n map[extname] = val;\n}\n/**\n * Quick helper to get string xhr type.\n *\n * @ignore\n * @param xhr - The request to check.\n * @return The type.\n */\nfunction reqType(xhr) {\n return xhr.toString().replace('object ', '');\n}\n/**\n * Manages the state and loading of a resource and all child resources.\n *\n * Can be extended in `GlobalMixins.LoaderResource`.\n *\n * @memberof PIXI\n */\nvar LoaderResource = /** @class */ (function () {\n /**\n * @param {string} name - The name of the resource to load.\n * @param {string|string[]} url - The url for this resource, for audio/video loads you can pass\n * an array of sources.\n * @param {object} [options] - The options for the load.\n * @param {string|boolean} [options.crossOrigin] - Is this request cross-origin? Default is to\n * determine automatically.\n * @param {number} [options.timeout=0] - A timeout in milliseconds for the load. If the load takes\n * longer than this time it is cancelled and the load is considered a failure. If this value is\n * set to `0` then there is no explicit timeout.\n * @param {PIXI.LoaderResource.LOAD_TYPE} [options.loadType=LOAD_TYPE.XHR] - How should this resource\n * be loaded?\n * @param {PIXI.LoaderResource.XHR_RESPONSE_TYPE} [options.xhrType=XHR_RESPONSE_TYPE.DEFAULT] - How\n * should the data being loaded be interpreted when using XHR?\n * @param {PIXI.LoaderResource.IMetadata} [options.metadata] - Extra configuration for middleware\n * and the Resource object.\n */\n function LoaderResource(name, url, options) {\n /**\n * The `dequeue` method that will be used a storage place for the async queue dequeue method\n * used privately by the loader.\n *\n * @private\n * @member {function}\n */\n this._dequeue = _noop;\n /**\n * Used a storage place for the on load binding used privately by the loader.\n *\n * @private\n * @member {function}\n */\n this._onLoadBinding = null;\n /**\n * The timer for element loads to check if they timeout.\n *\n * @private\n */\n this._elementTimer = 0;\n /**\n * The `complete` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundComplete = null;\n /**\n * The `_onError` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundOnError = null;\n /**\n * The `_onProgress` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundOnProgress = null;\n /**\n * The `_onTimeout` function bound to this resource's context.\n *\n * @private\n * @type {function}\n */\n this._boundOnTimeout = null;\n this._boundXhrOnError = null;\n this._boundXhrOnTimeout = null;\n this._boundXhrOnAbort = null;\n this._boundXhrOnLoad = null;\n if (typeof name !== 'string' || typeof url !== 'string') {\n throw new Error('Both name and url are required for constructing a resource.');\n }\n options = options || {};\n this._flags = 0;\n // set data url flag, needs to be set early for some _determineX checks to work.\n this._setFlag(LoaderResource.STATUS_FLAGS.DATA_URL, url.indexOf('data:') === 0);\n this.name = name;\n this.url = url;\n this.extension = this._getExtension();\n this.data = null;\n this.crossOrigin = options.crossOrigin === true ? 'anonymous' : options.crossOrigin;\n this.timeout = options.timeout || 0;\n this.loadType = options.loadType || this._determineLoadType();\n // The type used to load the resource via XHR. If unset, determined automatically.\n this.xhrType = options.xhrType;\n // Extra info for middleware, and controlling specifics about how the resource loads.\n // Note that if you pass in a `loadElement`, the Resource class takes ownership of it.\n // Meaning it will modify it as it sees fit.\n this.metadata = options.metadata || {};\n // The error that occurred while loading (if any).\n this.error = null;\n // The XHR object that was used to load this resource. This is only set\n // when `loadType` is `LoaderResource.LOAD_TYPE.XHR`.\n this.xhr = null;\n // The child resources this resource owns.\n this.children = [];\n // The resource type.\n this.type = LoaderResource.TYPE.UNKNOWN;\n // The progress chunk owned by this resource.\n this.progressChunk = 0;\n // The `dequeue` method that will be used a storage place for the async queue dequeue method\n // used privately by the loader.\n this._dequeue = _noop;\n // Used a storage place for the on load binding used privately by the loader.\n this._onLoadBinding = null;\n // The timer for element loads to check if they timeout.\n this._elementTimer = 0;\n this._boundComplete = this.complete.bind(this);\n this._boundOnError = this._onError.bind(this);\n this._boundOnProgress = this._onProgress.bind(this);\n this._boundOnTimeout = this._onTimeout.bind(this);\n // xhr callbacks\n this._boundXhrOnError = this._xhrOnError.bind(this);\n this._boundXhrOnTimeout = this._xhrOnTimeout.bind(this);\n this._boundXhrOnAbort = this._xhrOnAbort.bind(this);\n this._boundXhrOnLoad = this._xhrOnLoad.bind(this);\n // Dispatched when the resource beings to load.\n this.onStart = new Signal();\n // Dispatched each time progress of this resource load updates.\n // Not all resources types and loader systems can support this event\n // so sometimes it may not be available. If the resource\n // is being loaded on a modern browser, using XHR, and the remote server\n // properly sets Content-Length headers, then this will be available.\n this.onProgress = new Signal();\n // Dispatched once this resource has loaded, if there was an error it will\n // be in the `error` property.\n this.onComplete = new Signal();\n // Dispatched after this resource has had all the *after* middleware run on it.\n this.onAfterMiddleware = new Signal();\n }\n /**\n * Sets the load type to be used for a specific extension.\n *\n * @static\n * @param {string} extname - The extension to set the type for, e.g. \"png\" or \"fnt\"\n * @param {PIXI.LoaderResource.LOAD_TYPE} loadType - The load type to set it to.\n */\n LoaderResource.setExtensionLoadType = function (extname, loadType) {\n setExtMap(LoaderResource._loadTypeMap, extname, loadType);\n };\n /**\n * Sets the load type to be used for a specific extension.\n *\n * @static\n * @param {string} extname - The extension to set the type for, e.g. \"png\" or \"fnt\"\n * @param {PIXI.LoaderResource.XHR_RESPONSE_TYPE} xhrType - The xhr type to set it to.\n */\n LoaderResource.setExtensionXhrType = function (extname, xhrType) {\n setExtMap(LoaderResource._xhrTypeMap, extname, xhrType);\n };\n Object.defineProperty(LoaderResource.prototype, \"isDataUrl\", {\n /**\n * When the resource starts to load.\n *\n * @memberof PIXI.LoaderResource\n * @callback OnStartSignal\n * @param {Resource} resource - The resource that the event happened on.\n */\n /**\n * When the resource reports loading progress.\n *\n * @memberof PIXI.LoaderResource\n * @callback OnProgressSignal\n * @param {Resource} resource - The resource that the event happened on.\n * @param {number} percentage - The progress of the load in the range [0, 1].\n */\n /**\n * When the resource finishes loading.\n *\n * @memberof PIXI.LoaderResource\n * @callback OnCompleteSignal\n * @param {Resource} resource - The resource that the event happened on.\n */\n /**\n * @memberof PIXI.LoaderResource\n * @typedef {object} IMetadata\n * @property {HTMLImageElement|HTMLAudioElement|HTMLVideoElement} [loadElement=null] - The\n * element to use for loading, instead of creating one.\n * @property {boolean} [skipSource=false] - Skips adding source(s) to the load element. This\n * is useful if you want to pass in a `loadElement` that you already added load sources to.\n * @property {string|string[]} [mimeType] - The mime type to use for the source element\n * of a video/audio elment. If the urls are an array, you can pass this as an array as well\n * where each index is the mime type to use for the corresponding url index.\n */\n /**\n * Stores whether or not this url is a data url.\n *\n * @readonly\n * @member {boolean}\n */\n get: function () {\n return this._hasFlag(LoaderResource.STATUS_FLAGS.DATA_URL);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(LoaderResource.prototype, \"isComplete\", {\n /**\n * Describes if this resource has finished loading. Is true when the resource has completely\n * loaded.\n *\n * @readonly\n * @member {boolean}\n */\n get: function () {\n return this._hasFlag(LoaderResource.STATUS_FLAGS.COMPLETE);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(LoaderResource.prototype, \"isLoading\", {\n /**\n * Describes if this resource is currently loading. Is true when the resource starts loading,\n * and is false again when complete.\n *\n * @readonly\n * @member {boolean}\n */\n get: function () {\n return this._hasFlag(LoaderResource.STATUS_FLAGS.LOADING);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Marks the resource as complete.\n *\n */\n LoaderResource.prototype.complete = function () {\n this._clearEvents();\n this._finish();\n };\n /**\n * Aborts the loading of this resource, with an optional message.\n *\n * @param {string} message - The message to use for the error\n */\n LoaderResource.prototype.abort = function (message) {\n // abort can be called multiple times, ignore subsequent calls.\n if (this.error) {\n return;\n }\n // store error\n this.error = new Error(message);\n // clear events before calling aborts\n this._clearEvents();\n // abort the actual loading\n if (this.xhr) {\n this.xhr.abort();\n }\n else if (this.xdr) {\n this.xdr.abort();\n }\n else if (this.data) {\n // single source\n if (this.data.src) {\n this.data.src = LoaderResource.EMPTY_GIF;\n }\n // multi-source\n else {\n while (this.data.firstChild) {\n this.data.removeChild(this.data.firstChild);\n }\n }\n }\n // done now.\n this._finish();\n };\n /**\n * Kicks off loading of this resource. This method is asynchronous.\n *\n * @param {PIXI.LoaderResource.OnCompleteSignal} [cb] - Optional callback to call once the resource is loaded.\n */\n LoaderResource.prototype.load = function (cb) {\n var _this = this;\n if (this.isLoading) {\n return;\n }\n if (this.isComplete) {\n if (cb) {\n setTimeout(function () { return cb(_this); }, 1);\n }\n return;\n }\n else if (cb) {\n this.onComplete.once(cb);\n }\n this._setFlag(LoaderResource.STATUS_FLAGS.LOADING, true);\n this.onStart.dispatch(this);\n // if unset, determine the value\n if (this.crossOrigin === false || typeof this.crossOrigin !== 'string') {\n this.crossOrigin = this._determineCrossOrigin(this.url);\n }\n switch (this.loadType) {\n case LoaderResource.LOAD_TYPE.IMAGE:\n this.type = LoaderResource.TYPE.IMAGE;\n this._loadElement('image');\n break;\n case LoaderResource.LOAD_TYPE.AUDIO:\n this.type = LoaderResource.TYPE.AUDIO;\n this._loadSourceElement('audio');\n break;\n case LoaderResource.LOAD_TYPE.VIDEO:\n this.type = LoaderResource.TYPE.VIDEO;\n this._loadSourceElement('video');\n break;\n case LoaderResource.LOAD_TYPE.XHR:\n /* falls through */\n default:\n if (useXdr && this.crossOrigin) {\n this._loadXdr();\n }\n else {\n this._loadXhr();\n }\n break;\n }\n };\n /**\n * Checks if the flag is set.\n *\n * @param flag - The flag to check.\n * @return True if the flag is set.\n */\n LoaderResource.prototype._hasFlag = function (flag) {\n return (this._flags & flag) !== 0;\n };\n /**\n * (Un)Sets the flag.\n *\n * @param flag - The flag to (un)set.\n * @param value - Whether to set or (un)set the flag.\n */\n LoaderResource.prototype._setFlag = function (flag, value) {\n this._flags = value ? (this._flags | flag) : (this._flags & ~flag);\n };\n /**\n * Clears all the events from the underlying loading source.\n */\n LoaderResource.prototype._clearEvents = function () {\n clearTimeout(this._elementTimer);\n if (this.data && this.data.removeEventListener) {\n this.data.removeEventListener('error', this._boundOnError, false);\n this.data.removeEventListener('load', this._boundComplete, false);\n this.data.removeEventListener('progress', this._boundOnProgress, false);\n this.data.removeEventListener('canplaythrough', this._boundComplete, false);\n }\n if (this.xhr) {\n if (this.xhr.removeEventListener) {\n this.xhr.removeEventListener('error', this._boundXhrOnError, false);\n this.xhr.removeEventListener('timeout', this._boundXhrOnTimeout, false);\n this.xhr.removeEventListener('abort', this._boundXhrOnAbort, false);\n this.xhr.removeEventListener('progress', this._boundOnProgress, false);\n this.xhr.removeEventListener('load', this._boundXhrOnLoad, false);\n }\n else {\n this.xhr.onerror = null;\n this.xhr.ontimeout = null;\n this.xhr.onprogress = null;\n this.xhr.onload = null;\n }\n }\n };\n /**\n * Finalizes the load.\n */\n LoaderResource.prototype._finish = function () {\n if (this.isComplete) {\n throw new Error('Complete called again for an already completed resource.');\n }\n this._setFlag(LoaderResource.STATUS_FLAGS.COMPLETE, true);\n this._setFlag(LoaderResource.STATUS_FLAGS.LOADING, false);\n this.onComplete.dispatch(this);\n };\n /**\n * Loads this resources using an element that has a single source,\n * like an HTMLImageElement.\n * @private\n * @param type - The type of element to use.\n */\n LoaderResource.prototype._loadElement = function (type) {\n if (this.metadata.loadElement) {\n this.data = this.metadata.loadElement;\n }\n else if (type === 'image' && typeof globalThis.Image !== 'undefined') {\n this.data = new Image();\n }\n else {\n this.data = document.createElement(type);\n }\n if (this.crossOrigin) {\n this.data.crossOrigin = this.crossOrigin;\n }\n if (!this.metadata.skipSource) {\n this.data.src = this.url;\n }\n this.data.addEventListener('error', this._boundOnError, false);\n this.data.addEventListener('load', this._boundComplete, false);\n this.data.addEventListener('progress', this._boundOnProgress, false);\n if (this.timeout) {\n this._elementTimer = setTimeout(this._boundOnTimeout, this.timeout);\n }\n };\n /**\n * Loads this resources using an element that has multiple sources,\n * like an HTMLAudioElement or HTMLVideoElement.\n * @param type - The type of element to use.\n */\n LoaderResource.prototype._loadSourceElement = function (type) {\n if (this.metadata.loadElement) {\n this.data = this.metadata.loadElement;\n }\n else if (type === 'audio' && typeof globalThis.Audio !== 'undefined') {\n this.data = new Audio();\n }\n else {\n this.data = document.createElement(type);\n }\n if (this.data === null) {\n this.abort(\"Unsupported element: \" + type);\n return;\n }\n if (this.crossOrigin) {\n this.data.crossOrigin = this.crossOrigin;\n }\n if (!this.metadata.skipSource) {\n // support for CocoonJS Canvas+ runtime, lacks document.createElement('source')\n if (navigator.isCocoonJS) {\n this.data.src = Array.isArray(this.url) ? this.url[0] : this.url;\n }\n else if (Array.isArray(this.url)) {\n var mimeTypes = this.metadata.mimeType;\n for (var i = 0; i < this.url.length; ++i) {\n this.data.appendChild(this._createSource(type, this.url[i], Array.isArray(mimeTypes) ? mimeTypes[i] : mimeTypes));\n }\n }\n else {\n var mimeTypes = this.metadata.mimeType;\n this.data.appendChild(this._createSource(type, this.url, Array.isArray(mimeTypes) ? mimeTypes[0] : mimeTypes));\n }\n }\n this.data.addEventListener('error', this._boundOnError, false);\n this.data.addEventListener('load', this._boundComplete, false);\n this.data.addEventListener('progress', this._boundOnProgress, false);\n this.data.addEventListener('canplaythrough', this._boundComplete, false);\n this.data.load();\n if (this.timeout) {\n this._elementTimer = setTimeout(this._boundOnTimeout, this.timeout);\n }\n };\n /**\n * Loads this resources using an XMLHttpRequest.\n */\n LoaderResource.prototype._loadXhr = function () {\n // if unset, determine the value\n if (typeof this.xhrType !== 'string') {\n this.xhrType = this._determineXhrType();\n }\n var xhr = this.xhr = new XMLHttpRequest();\n // send credentials when crossOrigin with credentials requested\n if (this.crossOrigin === 'use-credentials') {\n xhr.withCredentials = true;\n }\n // set the request type and url\n xhr.open('GET', this.url, true);\n xhr.timeout = this.timeout;\n // load json as text and parse it ourselves. We do this because some browsers\n // *cough* safari *cough* can't deal with it.\n if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.JSON\n || this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT) {\n xhr.responseType = LoaderResource.XHR_RESPONSE_TYPE.TEXT;\n }\n else {\n xhr.responseType = this.xhrType;\n }\n xhr.addEventListener('error', this._boundXhrOnError, false);\n xhr.addEventListener('timeout', this._boundXhrOnTimeout, false);\n xhr.addEventListener('abort', this._boundXhrOnAbort, false);\n xhr.addEventListener('progress', this._boundOnProgress, false);\n xhr.addEventListener('load', this._boundXhrOnLoad, false);\n xhr.send();\n };\n /**\n * Loads this resources using an XDomainRequest. This is here because we need to support IE9 (gross).\n */\n LoaderResource.prototype._loadXdr = function () {\n // if unset, determine the value\n if (typeof this.xhrType !== 'string') {\n this.xhrType = this._determineXhrType();\n }\n var xdr = this.xhr = new globalThis.XDomainRequest(); // eslint-disable-line no-undef\n // XDomainRequest has a few quirks. Occasionally it will abort requests\n // A way to avoid this is to make sure ALL callbacks are set even if not used\n // More info here: http://stackoverflow.com/questions/15786966/xdomainrequest-aborts-post-on-ie-9\n xdr.timeout = this.timeout || 5000; // XDR needs a timeout value or it breaks in IE9\n xdr.onerror = this._boundXhrOnError;\n xdr.ontimeout = this._boundXhrOnTimeout;\n xdr.onprogress = this._boundOnProgress;\n xdr.onload = this._boundXhrOnLoad;\n xdr.open('GET', this.url, true);\n // Note: The xdr.send() call is wrapped in a timeout to prevent an\n // issue with the interface where some requests are lost if multiple\n // XDomainRequests are being sent at the same time.\n // Some info here: https://github.com/photonstorm/phaser/issues/1248\n setTimeout(function () { return xdr.send(); }, 1);\n };\n /**\n * Creates a source used in loading via an element.\n * @param type - The element type (video or audio).\n * @param url - The source URL to load from.\n * @param [mime] - The mime type of the video\n * @return The source element.\n */\n LoaderResource.prototype._createSource = function (type, url, mime) {\n if (!mime) {\n mime = type + \"/\" + this._getExtension(url);\n }\n var source = document.createElement('source');\n source.src = url;\n source.type = mime;\n return source;\n };\n /**\n * Called if a load errors out.\n *\n * @param event - The error event from the element that emits it.\n */\n LoaderResource.prototype._onError = function (event) {\n this.abort(\"Failed to load element using: \" + event.target.nodeName);\n };\n /**\n * Called if a load progress event fires for an element or xhr/xdr.\n * @param event - Progress event.\n */\n LoaderResource.prototype._onProgress = function (event) {\n if (event && event.lengthComputable) {\n this.onProgress.dispatch(this, event.loaded / event.total);\n }\n };\n /**\n * Called if a timeout event fires for an element.\n */\n LoaderResource.prototype._onTimeout = function () {\n this.abort(\"Load timed out.\");\n };\n /**\n * Called if an error event fires for xhr/xdr.\n */\n LoaderResource.prototype._xhrOnError = function () {\n var xhr = this.xhr;\n this.abort(reqType(xhr) + \" Request failed. Status: \" + xhr.status + \", text: \\\"\" + xhr.statusText + \"\\\"\");\n };\n /**\n * Called if an error event fires for xhr/xdr.\n */\n LoaderResource.prototype._xhrOnTimeout = function () {\n var xhr = this.xhr;\n this.abort(reqType(xhr) + \" Request timed out.\");\n };\n /**\n * Called if an abort event fires for xhr/xdr.\n */\n LoaderResource.prototype._xhrOnAbort = function () {\n var xhr = this.xhr;\n this.abort(reqType(xhr) + \" Request was aborted by the user.\");\n };\n /**\n * Called when data successfully loads from an xhr/xdr request.\n */\n LoaderResource.prototype._xhrOnLoad = function () {\n var xhr = this.xhr;\n var text = '';\n var status = typeof xhr.status === 'undefined' ? STATUS_OK : xhr.status; // XDR has no `.status`, assume 200.\n // responseText is accessible only if responseType is '' or 'text' and on older browsers\n if (xhr.responseType === '' || xhr.responseType === 'text' || typeof xhr.responseType === 'undefined') {\n text = xhr.responseText;\n }\n // status can be 0 when using the `file://` protocol so we also check if a response is set.\n // If it has a response, we assume 200; otherwise a 0 status code with no contents is an aborted request.\n if (status === STATUS_NONE && (text.length > 0 || xhr.responseType === LoaderResource.XHR_RESPONSE_TYPE.BUFFER)) {\n status = STATUS_OK;\n }\n // handle IE9 bug: http://stackoverflow.com/questions/10046972/msie-returns-status-code-of-1223-for-ajax-request\n else if (status === STATUS_IE_BUG_EMPTY) {\n status = STATUS_EMPTY;\n }\n var statusType = (status / 100) | 0;\n if (statusType === STATUS_TYPE_OK) {\n // if text, just return it\n if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.TEXT) {\n this.data = text;\n this.type = LoaderResource.TYPE.TEXT;\n }\n // if json, parse into json object\n else if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.JSON) {\n try {\n this.data = JSON.parse(text);\n this.type = LoaderResource.TYPE.JSON;\n }\n catch (e) {\n this.abort(\"Error trying to parse loaded json: \" + e);\n return;\n }\n }\n // if xml, parse into an xml document or div element\n else if (this.xhrType === LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT) {\n try {\n if (globalThis.DOMParser) {\n var domparser = new DOMParser();\n this.data = domparser.parseFromString(text, 'text/xml');\n }\n else {\n var div = document.createElement('div');\n div.innerHTML = text;\n this.data = div;\n }\n this.type = LoaderResource.TYPE.XML;\n }\n catch (e$1) {\n this.abort(\"Error trying to parse loaded xml: \" + e$1);\n return;\n }\n }\n // other types just return the response\n else {\n this.data = xhr.response || text;\n }\n }\n else {\n this.abort(\"[\" + xhr.status + \"] \" + xhr.statusText + \": \" + xhr.responseURL);\n return;\n }\n this.complete();\n };\n /**\n * Sets the `crossOrigin` property for this resource based on if the url\n * for this resource is cross-origin. If crossOrigin was manually set, this\n * function does nothing.\n * @private\n * @param url - The url to test.\n * @param [loc=globalThis.location] - The location object to test against.\n * @return The crossOrigin value to use (or empty string for none).\n */\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n LoaderResource.prototype._determineCrossOrigin = function (url, loc) {\n // data: and javascript: urls are considered same-origin\n if (url.indexOf('data:') === 0) {\n return '';\n }\n // A sandboxed iframe without the 'allow-same-origin' attribute will have a special\n // origin designed not to match globalThis.location.origin, and will always require\n // crossOrigin requests regardless of whether the location matches.\n if (globalThis.origin !== globalThis.location.origin) {\n return 'anonymous';\n }\n // default is globalThis.location\n loc = loc || globalThis.location;\n if (!tempAnchor) {\n tempAnchor = document.createElement('a');\n }\n // let the browser determine the full href for the url of this resource and then\n // parse with the node url lib, we can't use the properties of the anchor element\n // because they don't work in IE9 :(\n tempAnchor.href = url;\n var parsedUrl = parseUri(tempAnchor.href, { strictMode: true });\n var samePort = (!parsedUrl.port && loc.port === '') || (parsedUrl.port === loc.port);\n var protocol = parsedUrl.protocol ? parsedUrl.protocol + \":\" : '';\n // if cross origin\n if (parsedUrl.host !== loc.hostname || !samePort || protocol !== loc.protocol) {\n return 'anonymous';\n }\n return '';\n };\n /**\n * Determines the responseType of an XHR request based on the extension of the\n * resource being loaded.\n *\n * @private\n * @return {PIXI.LoaderResource.XHR_RESPONSE_TYPE} The responseType to use.\n */\n LoaderResource.prototype._determineXhrType = function () {\n return LoaderResource._xhrTypeMap[this.extension] || LoaderResource.XHR_RESPONSE_TYPE.TEXT;\n };\n /**\n * Determines the loadType of a resource based on the extension of the\n * resource being loaded.\n *\n * @private\n * @return {PIXI.LoaderResource.LOAD_TYPE} The loadType to use.\n */\n LoaderResource.prototype._determineLoadType = function () {\n return LoaderResource._loadTypeMap[this.extension] || LoaderResource.LOAD_TYPE.XHR;\n };\n /**\n * Extracts the extension (sans '.') of the file being loaded by the resource.\n *\n * @param [url] - url to parse, `this.url` by default.\n * @return The extension.\n */\n LoaderResource.prototype._getExtension = function (url) {\n if (url === void 0) { url = this.url; }\n var ext = '';\n if (this.isDataUrl) {\n var slashIndex = url.indexOf('/');\n ext = url.substring(slashIndex + 1, url.indexOf(';', slashIndex));\n }\n else {\n var queryStart = url.indexOf('?');\n var hashStart = url.indexOf('#');\n var index = Math.min(queryStart > -1 ? queryStart : url.length, hashStart > -1 ? hashStart : url.length);\n url = url.substring(0, index);\n ext = url.substring(url.lastIndexOf('.') + 1);\n }\n return ext.toLowerCase();\n };\n /**\n * Determines the mime type of an XHR request based on the responseType of\n * resource being loaded.\n *\n * @param type - The type to get a mime type for.\n * @private\n * @return The mime type to use.\n */\n LoaderResource.prototype._getMimeFromXhrType = function (type) {\n switch (type) {\n case LoaderResource.XHR_RESPONSE_TYPE.BUFFER:\n return 'application/octet-binary';\n case LoaderResource.XHR_RESPONSE_TYPE.BLOB:\n return 'application/blob';\n case LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT:\n return 'application/xml';\n case LoaderResource.XHR_RESPONSE_TYPE.JSON:\n return 'application/json';\n case LoaderResource.XHR_RESPONSE_TYPE.DEFAULT:\n case LoaderResource.XHR_RESPONSE_TYPE.TEXT:\n /* falls through */\n default:\n return 'text/plain';\n }\n };\n return LoaderResource;\n}());\n// eslint-disable-next-line @typescript-eslint/no-namespace\n(function (LoaderResource) {\n /**\n * The types of resources a resource could represent.\n *\n * @static\n * @readonly\n * @enum {number}\n * @memberof PIXI.LoaderResource\n */\n var STATUS_FLAGS;\n (function (STATUS_FLAGS) {\n /** None */\n STATUS_FLAGS[STATUS_FLAGS[\"NONE\"] = 0] = \"NONE\";\n /** Data URL */\n STATUS_FLAGS[STATUS_FLAGS[\"DATA_URL\"] = 1] = \"DATA_URL\";\n /** Complete */\n STATUS_FLAGS[STATUS_FLAGS[\"COMPLETE\"] = 2] = \"COMPLETE\";\n /** Loading */\n STATUS_FLAGS[STATUS_FLAGS[\"LOADING\"] = 4] = \"LOADING\";\n })(STATUS_FLAGS = LoaderResource.STATUS_FLAGS || (LoaderResource.STATUS_FLAGS = {}));\n /**\n * The types of resources a resource could represent.\n *\n * @static\n * @readonly\n * @enum {number}\n * @memberof PIXI.LoaderResource\n */\n var TYPE;\n (function (TYPE) {\n /** Unknown */\n TYPE[TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n /** JSON */\n TYPE[TYPE[\"JSON\"] = 1] = \"JSON\";\n /** XML */\n TYPE[TYPE[\"XML\"] = 2] = \"XML\";\n /** Image */\n TYPE[TYPE[\"IMAGE\"] = 3] = \"IMAGE\";\n /** Audio */\n TYPE[TYPE[\"AUDIO\"] = 4] = \"AUDIO\";\n /** Video */\n TYPE[TYPE[\"VIDEO\"] = 5] = \"VIDEO\";\n /** Plain text */\n TYPE[TYPE[\"TEXT\"] = 6] = \"TEXT\";\n })(TYPE = LoaderResource.TYPE || (LoaderResource.TYPE = {}));\n /**\n * The types of loading a resource can use.\n *\n * @static\n * @readonly\n * @enum {number}\n * @memberof PIXI.LoaderResource\n */\n var LOAD_TYPE;\n (function (LOAD_TYPE) {\n /** Uses XMLHttpRequest to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"XHR\"] = 1] = \"XHR\";\n /** Uses an `Image` object to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"IMAGE\"] = 2] = \"IMAGE\";\n /** Uses an `Audio` object to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"AUDIO\"] = 3] = \"AUDIO\";\n /** Uses a `Video` object to load the resource. */\n LOAD_TYPE[LOAD_TYPE[\"VIDEO\"] = 4] = \"VIDEO\";\n })(LOAD_TYPE = LoaderResource.LOAD_TYPE || (LoaderResource.LOAD_TYPE = {}));\n /**\n * The XHR ready states, used internally.\n *\n * @static\n * @readonly\n * @enum {string}\n * @memberof PIXI.LoaderResource\n */\n var XHR_RESPONSE_TYPE;\n (function (XHR_RESPONSE_TYPE) {\n /** string */\n XHR_RESPONSE_TYPE[\"DEFAULT\"] = \"text\";\n /** ArrayBuffer */\n XHR_RESPONSE_TYPE[\"BUFFER\"] = \"arraybuffer\";\n /** Blob */\n XHR_RESPONSE_TYPE[\"BLOB\"] = \"blob\";\n /** Document */\n XHR_RESPONSE_TYPE[\"DOCUMENT\"] = \"document\";\n /** Object */\n XHR_RESPONSE_TYPE[\"JSON\"] = \"json\";\n /** String */\n XHR_RESPONSE_TYPE[\"TEXT\"] = \"text\";\n })(XHR_RESPONSE_TYPE = LoaderResource.XHR_RESPONSE_TYPE || (LoaderResource.XHR_RESPONSE_TYPE = {}));\n LoaderResource._loadTypeMap = {\n // images\n gif: LoaderResource.LOAD_TYPE.IMAGE,\n png: LoaderResource.LOAD_TYPE.IMAGE,\n bmp: LoaderResource.LOAD_TYPE.IMAGE,\n jpg: LoaderResource.LOAD_TYPE.IMAGE,\n jpeg: LoaderResource.LOAD_TYPE.IMAGE,\n tif: LoaderResource.LOAD_TYPE.IMAGE,\n tiff: LoaderResource.LOAD_TYPE.IMAGE,\n webp: LoaderResource.LOAD_TYPE.IMAGE,\n tga: LoaderResource.LOAD_TYPE.IMAGE,\n svg: LoaderResource.LOAD_TYPE.IMAGE,\n 'svg+xml': LoaderResource.LOAD_TYPE.IMAGE,\n // audio\n mp3: LoaderResource.LOAD_TYPE.AUDIO,\n ogg: LoaderResource.LOAD_TYPE.AUDIO,\n wav: LoaderResource.LOAD_TYPE.AUDIO,\n // videos\n mp4: LoaderResource.LOAD_TYPE.VIDEO,\n webm: LoaderResource.LOAD_TYPE.VIDEO,\n };\n LoaderResource._xhrTypeMap = {\n // xml\n xhtml: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n html: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n htm: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n xml: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n tmx: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n svg: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n // This was added to handle Tiled Tileset XML, but .tsx is also a TypeScript React Component.\n // Since it is way less likely for people to be loading TypeScript files instead of Tiled files,\n // this should probably be fine.\n tsx: LoaderResource.XHR_RESPONSE_TYPE.DOCUMENT,\n // images\n gif: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n png: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n bmp: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n jpg: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n jpeg: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n tif: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n tiff: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n webp: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n tga: LoaderResource.XHR_RESPONSE_TYPE.BLOB,\n // json\n json: LoaderResource.XHR_RESPONSE_TYPE.JSON,\n // text\n text: LoaderResource.XHR_RESPONSE_TYPE.TEXT,\n txt: LoaderResource.XHR_RESPONSE_TYPE.TEXT,\n // fonts\n ttf: LoaderResource.XHR_RESPONSE_TYPE.BUFFER,\n otf: LoaderResource.XHR_RESPONSE_TYPE.BUFFER,\n };\n // We can't set the `src` attribute to empty string, so on abort we set it to this 1px transparent gif\n LoaderResource.EMPTY_GIF = 'data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==';\n})(LoaderResource || (LoaderResource = {}));\n\n/**\n * Smaller version of the async library constructs.\n * @ignore\n */\nfunction _noop$1() {\n}\n/**\n * Ensures a function is only called once.\n * @ignore\n * @param {function} fn - The function to wrap.\n * @return {function} The wrapping function.\n */\nfunction onlyOnce(fn) {\n return function onceWrapper() {\n var arguments$1 = arguments;\n\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments$1[_i];\n }\n if (fn === null) {\n throw new Error('Callback was already called.');\n }\n var callFn = fn;\n fn = null;\n callFn.apply(this, args);\n };\n}\n/**\n * @private\n * @memberof PIXI\n */\nvar AsyncQueueItem = /** @class */ (function () {\n /**\n * @private\n */\n function AsyncQueueItem(data, callback) {\n this.data = data;\n this.callback = callback;\n }\n return AsyncQueueItem;\n}());\n/**\n * @private\n * @memberof PIXI\n */\nvar AsyncQueue = /** @class */ (function () {\n /**\n * @private\n */\n function AsyncQueue(worker, concurrency) {\n var _this = this;\n if (concurrency === void 0) { concurrency = 1; }\n this.workers = 0;\n this.saturated = _noop$1;\n this.unsaturated = _noop$1;\n this.empty = _noop$1;\n this.drain = _noop$1;\n this.error = _noop$1;\n this.started = false;\n this.paused = false;\n this._tasks = [];\n this._insert = function (data, insertAtFront, callback) {\n if (callback && typeof callback !== 'function') {\n throw new Error('task callback must be a function');\n }\n _this.started = true;\n // eslint-disable-next-line no-eq-null,eqeqeq\n if (data == null && _this.idle()) {\n // call drain immediately if there are no tasks\n setTimeout(function () { return _this.drain(); }, 1);\n return;\n }\n var item = new AsyncQueueItem(data, typeof callback === 'function' ? callback : _noop$1);\n if (insertAtFront) {\n _this._tasks.unshift(item);\n }\n else {\n _this._tasks.push(item);\n }\n setTimeout(_this.process, 1);\n };\n this.process = function () {\n while (!_this.paused && _this.workers < _this.concurrency && _this._tasks.length) {\n var task = _this._tasks.shift();\n if (_this._tasks.length === 0) {\n _this.empty();\n }\n _this.workers += 1;\n if (_this.workers === _this.concurrency) {\n _this.saturated();\n }\n _this._worker(task.data, onlyOnce(_this._next(task)));\n }\n };\n this._worker = worker;\n if (concurrency === 0) {\n throw new Error('Concurrency must not be zero');\n }\n this.concurrency = concurrency;\n this.buffer = concurrency / 4.0;\n }\n /**\n * @private\n */\n AsyncQueue.prototype._next = function (task) {\n var _this = this;\n return function () {\n var arguments$1 = arguments;\n\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments$1[_i];\n }\n _this.workers -= 1;\n task.callback.apply(task, args);\n // eslint-disable-next-line no-eq-null,eqeqeq\n if (args[0] != null) {\n _this.error(args[0], task.data);\n }\n if (_this.workers <= (_this.concurrency - _this.buffer)) {\n _this.unsaturated();\n }\n if (_this.idle()) {\n _this.drain();\n }\n _this.process();\n };\n };\n // That was in object\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n AsyncQueue.prototype.push = function (data, callback) {\n this._insert(data, false, callback);\n };\n AsyncQueue.prototype.kill = function () {\n this.workers = 0;\n this.drain = _noop$1;\n this.started = false;\n this._tasks = [];\n };\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n AsyncQueue.prototype.unshift = function (data, callback) {\n this._insert(data, true, callback);\n };\n AsyncQueue.prototype.length = function () {\n return this._tasks.length;\n };\n AsyncQueue.prototype.running = function () {\n return this.workers;\n };\n AsyncQueue.prototype.idle = function () {\n return this._tasks.length + this.workers === 0;\n };\n AsyncQueue.prototype.pause = function () {\n if (this.paused === true) {\n return;\n }\n this.paused = true;\n };\n AsyncQueue.prototype.resume = function () {\n if (this.paused === false) {\n return;\n }\n this.paused = false;\n // Need to call this.process once per concurrent\n // worker to preserve full concurrency after pause\n for (var w = 1; w <= this.concurrency; w++) {\n this.process();\n }\n };\n /**\n * Iterates an array in series.\n *\n * @param {Array.<*>} array - Array to iterate.\n * @param {function} iterator - Function to call for each element.\n * @param {function} callback - Function to call when done, or on error.\n * @param {boolean} [deferNext=false] - Break synchronous each loop by calling next with a setTimeout of 1.\n */\n AsyncQueue.eachSeries = function (array, iterator, callback, deferNext) {\n var i = 0;\n var len = array.length;\n function next(err) {\n if (err || i === len) {\n if (callback) {\n callback(err);\n }\n return;\n }\n if (deferNext) {\n setTimeout(function () {\n iterator(array[i++], next);\n }, 1);\n }\n else {\n iterator(array[i++], next);\n }\n }\n next();\n };\n /**\n * Async queue implementation,\n *\n * @param {function} worker - The worker function to call for each task.\n * @param {number} concurrency - How many workers to run in parrallel.\n * @return {*} The async queue object.\n */\n AsyncQueue.queue = function (worker, concurrency) {\n return new AsyncQueue(worker, concurrency);\n };\n return AsyncQueue;\n}());\n\n// some constants\nvar MAX_PROGRESS = 100;\nvar rgxExtractUrlHash = /(#[\\w-]+)?$/;\n/**\n * The new loader, forked from Resource Loader by Chad Engler: https://github.com/englercj/resource-loader\n *\n * ```js\n * const loader = PIXI.Loader.shared; // PixiJS exposes a premade instance for you to use.\n * // or\n * const loader = new PIXI.Loader(); // You can also create your own if you want\n *\n * const sprites = {};\n *\n * // Chainable `add` to enqueue a resource\n * loader.add('bunny', 'data/bunny.png')\n * .add('spaceship', 'assets/spritesheet.json');\n * loader.add('scoreFont', 'assets/score.fnt');\n *\n * // Chainable `pre` to add a middleware that runs for each resource, *before* loading that resource.\n * // This is useful to implement custom caching modules (using filesystem, indexeddb, memory, etc).\n * loader.pre(cachingMiddleware);\n *\n * // Chainable `use` to add a middleware that runs for each resource, *after* loading that resource.\n * // This is useful to implement custom parsing modules (like spritesheet parsers, spine parser, etc).\n * loader.use(parsingMiddleware);\n *\n * // The `load` method loads the queue of resources, and calls the passed in callback called once all\n * // resources have loaded.\n * loader.load((loader, resources) => {\n * // resources is an object where the key is the name of the resource loaded and the value is the resource object.\n * // They have a couple default properties:\n * // - `url`: The URL that the resource was loaded from\n * // - `error`: The error that happened when trying to load (if any)\n * // - `data`: The raw data that was loaded\n * // also may contain other properties based on the middleware that runs.\n * sprites.bunny = new PIXI.TilingSprite(resources.bunny.texture);\n * sprites.spaceship = new PIXI.TilingSprite(resources.spaceship.texture);\n * sprites.scoreFont = new PIXI.TilingSprite(resources.scoreFont.texture);\n * });\n *\n * // throughout the process multiple signals can be dispatched.\n * loader.onProgress.add(() => {}); // called once per loaded/errored file\n * loader.onError.add(() => {}); // called once per errored file\n * loader.onLoad.add(() => {}); // called once per loaded file\n * loader.onComplete.add(() => {}); // called once when the queued resources all load.\n * ```\n *\n * @memberof PIXI\n */\nvar Loader = /** @class */ (function () {\n /**\n * @param baseUrl - The base url for all resources loaded by this loader.\n * @param concurrency - The number of resources to load concurrently.\n */\n function Loader(baseUrl, concurrency) {\n var _this = this;\n if (baseUrl === void 0) { baseUrl = ''; }\n if (concurrency === void 0) { concurrency = 10; }\n /**\n * The progress percent of the loader going through the queue.\n */\n this.progress = 0;\n /**\n * Loading state of the loader, true if it is currently loading resources.\n */\n this.loading = false;\n /**\n * A querystring to append to every URL added to the loader.\n *\n * This should be a valid query string *without* the question-mark (`?`). The loader will\n * also *not* escape values for you. Make sure to escape your parameters with\n * [`encodeURIComponent`](https://mdn.io/encodeURIComponent) before assigning this property.\n *\n * @example\n * const loader = new Loader();\n *\n * loader.defaultQueryString = 'user=me&password=secret';\n *\n * // This will request 'image.png?user=me&password=secret'\n * loader.add('image.png').load();\n *\n * loader.reset();\n *\n * // This will request 'image.png?v=1&user=me&password=secret'\n * loader.add('iamge.png?v=1').load();\n */\n this.defaultQueryString = '';\n /**\n * The middleware to run before loading each resource.\n */\n this._beforeMiddleware = [];\n /**\n * The middleware to run after loading each resource.\n */\n this._afterMiddleware = [];\n /**\n * The tracks the resources we are currently completing parsing for.\n */\n this._resourcesParsing = [];\n /**\n * The `_loadResource` function bound with this object context.\n *\n * @param r - The resource to load\n * @param d - The dequeue function\n */\n this._boundLoadResource = function (r, d) { return _this._loadResource(r, d); };\n /**\n * All the resources for this loader keyed by name.\n */\n this.resources = {};\n this.baseUrl = baseUrl;\n this._beforeMiddleware = [];\n this._afterMiddleware = [];\n this._resourcesParsing = [];\n this._boundLoadResource = function (r, d) { return _this._loadResource(r, d); };\n this._queue = AsyncQueue.queue(this._boundLoadResource, concurrency);\n this._queue.pause();\n this.resources = {};\n this.onProgress = new Signal();\n this.onError = new Signal();\n this.onLoad = new Signal();\n this.onStart = new Signal();\n this.onComplete = new Signal();\n for (var i = 0; i < Loader._plugins.length; ++i) {\n var plugin = Loader._plugins[i];\n var pre = plugin.pre, use = plugin.use;\n if (pre) {\n this.pre(pre);\n }\n if (use) {\n this.use(use);\n }\n }\n this._protected = false;\n }\n /**\n * Same as add, params have strict order\n *\n * @private\n * @param name - The name of the resource to load.\n * @param url - The url for this resource, relative to the baseUrl of this loader.\n * @param options - The options for the load.\n * @param callback - Function to call when this specific resource completes loading.\n * @return The loader itself.\n */\n Loader.prototype._add = function (name, url, options, callback) {\n // if loading already you can only add resources that have a parent.\n if (this.loading && (!options || !options.parentResource)) {\n throw new Error('Cannot add resources while the loader is running.');\n }\n // check if resource already exists.\n if (this.resources[name]) {\n throw new Error(\"Resource named \\\"\" + name + \"\\\" already exists.\");\n }\n // add base url if this isn't an absolute url\n url = this._prepareUrl(url);\n // create the store the resource\n this.resources[name] = new LoaderResource(name, url, options);\n if (typeof callback === 'function') {\n this.resources[name].onAfterMiddleware.once(callback);\n }\n // if actively loading, make sure to adjust progress chunks for that parent and its children\n if (this.loading) {\n var parent = options.parentResource;\n var incompleteChildren = [];\n for (var i = 0; i < parent.children.length; ++i) {\n if (!parent.children[i].isComplete) {\n incompleteChildren.push(parent.children[i]);\n }\n }\n var fullChunk = parent.progressChunk * (incompleteChildren.length + 1); // +1 for parent\n var eachChunk = fullChunk / (incompleteChildren.length + 2); // +2 for parent & new child\n parent.children.push(this.resources[name]);\n parent.progressChunk = eachChunk;\n for (var i = 0; i < incompleteChildren.length; ++i) {\n incompleteChildren[i].progressChunk = eachChunk;\n }\n this.resources[name].progressChunk = eachChunk;\n }\n // add the resource to the queue\n this._queue.push(this.resources[name]);\n return this;\n };\n /* eslint-enable require-jsdoc,valid-jsdoc */\n /**\n * Sets up a middleware function that will run *before* the\n * resource is loaded.\n *\n * @param fn - The middleware function to register.\n * @return The loader itself.\n */\n Loader.prototype.pre = function (fn) {\n this._beforeMiddleware.push(fn);\n return this;\n };\n /**\n * Sets up a middleware function that will run *after* the\n * resource is loaded.\n *\n * @param fn - The middleware function to register.\n * @return The loader itself.\n */\n Loader.prototype.use = function (fn) {\n this._afterMiddleware.push(fn);\n return this;\n };\n /**\n * Resets the queue of the loader to prepare for a new load.\n *\n * @return The loader itself.\n */\n Loader.prototype.reset = function () {\n this.progress = 0;\n this.loading = false;\n this._queue.kill();\n this._queue.pause();\n // abort all resource loads\n for (var k in this.resources) {\n var res = this.resources[k];\n if (res._onLoadBinding) {\n res._onLoadBinding.detach();\n }\n if (res.isLoading) {\n res.abort('loader reset');\n }\n }\n this.resources = {};\n return this;\n };\n /**\n * Starts loading the queued resources.\n * @param cb - Optional callback that will be bound to the `complete` event.\n * @return The loader itself.\n */\n Loader.prototype.load = function (cb) {\n // register complete callback if they pass one\n if (typeof cb === 'function') {\n this.onComplete.once(cb);\n }\n // if the queue has already started we are done here\n if (this.loading) {\n return this;\n }\n if (this._queue.idle()) {\n this._onStart();\n this._onComplete();\n }\n else {\n // distribute progress chunks\n var numTasks = this._queue._tasks.length;\n var chunk = MAX_PROGRESS / numTasks;\n for (var i = 0; i < this._queue._tasks.length; ++i) {\n this._queue._tasks[i].data.progressChunk = chunk;\n }\n // notify we are starting\n this._onStart();\n // start loading\n this._queue.resume();\n }\n return this;\n };\n Object.defineProperty(Loader.prototype, \"concurrency\", {\n /**\n * The number of resources to load concurrently.\n *\n * @default 10\n */\n get: function () {\n return this._queue.concurrency;\n },\n set: function (concurrency) {\n this._queue.concurrency = concurrency;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Prepares a url for usage based on the configuration of this object\n * @param url - The url to prepare.\n * @return The prepared url.\n */\n Loader.prototype._prepareUrl = function (url) {\n var parsedUrl = parseUri(url, { strictMode: true });\n var result;\n // absolute url, just use it as is.\n if (parsedUrl.protocol || !parsedUrl.path || url.indexOf('//') === 0) {\n result = url;\n }\n // if baseUrl doesn't end in slash and url doesn't start with slash, then add a slash inbetween\n else if (this.baseUrl.length\n && this.baseUrl.lastIndexOf('/') !== this.baseUrl.length - 1\n && url.charAt(0) !== '/') {\n result = this.baseUrl + \"/\" + url;\n }\n else {\n result = this.baseUrl + url;\n }\n // if we need to add a default querystring, there is a bit more work\n if (this.defaultQueryString) {\n var hash = rgxExtractUrlHash.exec(result)[0];\n result = result.slice(0, result.length - hash.length);\n if (result.indexOf('?') !== -1) {\n result += \"&\" + this.defaultQueryString;\n }\n else {\n result += \"?\" + this.defaultQueryString;\n }\n result += hash;\n }\n return result;\n };\n /**\n * Loads a single resource.\n *\n * @param resource - The resource to load.\n * @param dequeue - The function to call when we need to dequeue this item.\n */\n Loader.prototype._loadResource = function (resource, dequeue) {\n var _this = this;\n resource._dequeue = dequeue;\n // run before middleware\n AsyncQueue.eachSeries(this._beforeMiddleware, function (fn, next) {\n fn.call(_this, resource, function () {\n // if the before middleware marks the resource as complete,\n // break and don't process any more before middleware\n next(resource.isComplete ? {} : null);\n });\n }, function () {\n if (resource.isComplete) {\n _this._onLoad(resource);\n }\n else {\n resource._onLoadBinding = resource.onComplete.once(_this._onLoad, _this);\n resource.load();\n }\n }, true);\n };\n /**\n * Called once loading has started.\n */\n Loader.prototype._onStart = function () {\n this.progress = 0;\n this.loading = true;\n this.onStart.dispatch(this);\n };\n /**\n * Called once each resource has loaded.\n */\n Loader.prototype._onComplete = function () {\n this.progress = MAX_PROGRESS;\n this.loading = false;\n this.onComplete.dispatch(this, this.resources);\n };\n /**\n * Called each time a resources is loaded.\n * @param resource - The resource that was loaded\n */\n Loader.prototype._onLoad = function (resource) {\n var _this = this;\n resource._onLoadBinding = null;\n // remove this resource from the async queue, and add it to our list of resources that are being parsed\n this._resourcesParsing.push(resource);\n resource._dequeue();\n // run all the after middleware for this resource\n AsyncQueue.eachSeries(this._afterMiddleware, function (fn, next) {\n fn.call(_this, resource, next);\n }, function () {\n resource.onAfterMiddleware.dispatch(resource);\n _this.progress = Math.min(MAX_PROGRESS, _this.progress + resource.progressChunk);\n _this.onProgress.dispatch(_this, resource);\n if (resource.error) {\n _this.onError.dispatch(resource.error, _this, resource);\n }\n else {\n _this.onLoad.dispatch(_this, resource);\n }\n _this._resourcesParsing.splice(_this._resourcesParsing.indexOf(resource), 1);\n // do completion check\n if (_this._queue.idle() && _this._resourcesParsing.length === 0) {\n _this._onComplete();\n }\n }, true);\n };\n /**\n * Destroy the loader, removes references.\n */\n Loader.prototype.destroy = function () {\n if (!this._protected) {\n this.reset();\n }\n };\n Object.defineProperty(Loader, \"shared\", {\n /**\n * A premade instance of the loader that can be used to load resources.\n */\n get: function () {\n var shared = Loader._shared;\n if (!shared) {\n shared = new Loader();\n shared._protected = true;\n Loader._shared = shared;\n }\n return shared;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Adds a Loader plugin for the global shared loader and all\n * new Loader instances created.\n *\n * @param plugin - The plugin to add\n * @return Reference to PIXI.Loader for chaining\n */\n Loader.registerPlugin = function (plugin) {\n Loader._plugins.push(plugin);\n if (plugin.add) {\n plugin.add();\n }\n return Loader;\n };\n Loader._plugins = [];\n return Loader;\n}());\nLoader.prototype.add = function add(name, url, options, callback) {\n // special case of an array of objects or urls\n if (Array.isArray(name)) {\n for (var i = 0; i < name.length; ++i) {\n this.add(name[i]);\n }\n return this;\n }\n // if an object is passed instead of params\n if (typeof name === 'object') {\n options = name;\n callback = url || options.callback || options.onComplete;\n url = options.url;\n name = options.name || options.key || options.url;\n }\n // case where no name is passed shift all args over by one.\n if (typeof url !== 'string') {\n callback = options;\n options = url;\n url = name;\n }\n // now that we shifted make sure we have a proper url.\n if (typeof url !== 'string') {\n throw new Error('No url passed to add resource to loader.');\n }\n // options are optional so people might pass a function and no options\n if (typeof options === 'function') {\n callback = options;\n options = null;\n }\n return this._add(name, url, options, callback);\n};\n\n/**\n * Application plugin for supporting loader option. Installing the LoaderPlugin\n * is not necessary if using **pixi.js** or **pixi.js-legacy**.\n * @example\n * import {AppLoaderPlugin} from '@pixi/loaders';\n * import {Application} from '@pixi/app';\n * Application.registerPlugin(AppLoaderPlugin);\n * @memberof PIXI\n */\nvar AppLoaderPlugin = /** @class */ (function () {\n function AppLoaderPlugin() {\n }\n /**\n * Called on application constructor\n *\n * @private\n */\n AppLoaderPlugin.init = function (options) {\n options = Object.assign({\n sharedLoader: false,\n }, options);\n this.loader = options.sharedLoader ? Loader.shared : new Loader();\n };\n /**\n * Called when application destroyed\n *\n * @private\n */\n AppLoaderPlugin.destroy = function () {\n if (this.loader) {\n this.loader.destroy();\n this.loader = null;\n }\n };\n return AppLoaderPlugin;\n}());\n\n/**\n * Loader plugin for handling Texture resources.\n *\n * @memberof PIXI\n */\nvar TextureLoader = /** @class */ (function () {\n function TextureLoader() {\n }\n /**\n * Handle SVG elements a text, render with SVGResource.\n */\n TextureLoader.add = function () {\n LoaderResource.setExtensionLoadType('svg', LoaderResource.LOAD_TYPE.XHR);\n LoaderResource.setExtensionXhrType('svg', LoaderResource.XHR_RESPONSE_TYPE.TEXT);\n };\n /**\n * Called after a resource is loaded.\n * @see PIXI.Loader.loaderMiddleware\n * @param resource\n * @param {function} next\n */\n TextureLoader.use = function (resource, next) {\n // create a new texture if the data is an Image object\n if (resource.data && (resource.type === LoaderResource.TYPE.IMAGE || resource.extension === 'svg')) {\n var data = resource.data, url = resource.url, name = resource.name, metadata = resource.metadata;\n Texture.fromLoader(data, url, name, metadata).then(function (texture) {\n resource.texture = texture;\n next();\n })\n // TODO: handle errors in Texture.fromLoader\n // so we can pass them to the Loader\n .catch(next);\n }\n else {\n next();\n }\n };\n return TextureLoader;\n}());\n\nvar _keyStr = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\n/**\n * Encodes binary into base64.\n *\n * @function encodeBinary\n * @param {string} input - The input data to encode.\n * @returns {string} The encoded base64 string\n */\nfunction encodeBinary(input) {\n var output = '';\n var inx = 0;\n while (inx < input.length) {\n // Fill byte buffer array\n var bytebuffer = [0, 0, 0];\n var encodedCharIndexes = [0, 0, 0, 0];\n for (var jnx = 0; jnx < bytebuffer.length; ++jnx) {\n if (inx < input.length) {\n // throw away high-order byte, as documented at:\n // https://developer.mozilla.org/En/Using_XMLHttpRequest#Handling_binary_data\n bytebuffer[jnx] = input.charCodeAt(inx++) & 0xff;\n }\n else {\n bytebuffer[jnx] = 0;\n }\n }\n // Get each encoded character, 6 bits at a time\n // index 1: first 6 bits\n encodedCharIndexes[0] = bytebuffer[0] >> 2;\n // index 2: second 6 bits (2 least significant bits from input byte 1 + 4 most significant bits from byte 2)\n encodedCharIndexes[1] = ((bytebuffer[0] & 0x3) << 4) | (bytebuffer[1] >> 4);\n // index 3: third 6 bits (4 least significant bits from input byte 2 + 2 most significant bits from byte 3)\n encodedCharIndexes[2] = ((bytebuffer[1] & 0x0f) << 2) | (bytebuffer[2] >> 6);\n // index 3: forth 6 bits (6 least significant bits from input byte 3)\n encodedCharIndexes[3] = bytebuffer[2] & 0x3f;\n // Determine whether padding happened, and adjust accordingly\n var paddingBytes = inx - (input.length - 1);\n switch (paddingBytes) {\n case 2:\n // Set last 2 characters to padding char\n encodedCharIndexes[3] = 64;\n encodedCharIndexes[2] = 64;\n break;\n case 1:\n // Set last character to padding char\n encodedCharIndexes[3] = 64;\n break;\n }\n // Now we will grab each appropriate character out of our keystring\n // based on our index array and append it to the output string\n for (var jnx = 0; jnx < encodedCharIndexes.length; ++jnx) {\n output += _keyStr.charAt(encodedCharIndexes[jnx]);\n }\n }\n return output;\n}\n\nvar Url = self.URL || self.webkitURL;\n/**\n * A middleware for transforming XHR loaded Blobs into more useful objects\n *\n * @ignore\n * @function parsing\n * @example\n * import { Loader, middleware } from 'resource-loader';\n * const loader = new Loader();\n * loader.use(middleware.parsing);\n * @param resource - Current Resource\n * @param next - Callback when complete\n */\nfunction parsing(resource, next) {\n if (!resource.data) {\n next();\n return;\n }\n // if this was an XHR load of a blob\n if (resource.xhr && resource.xhrType === LoaderResource.XHR_RESPONSE_TYPE.BLOB) {\n // if there is no blob support we probably got a binary string back\n if (!self.Blob || typeof resource.data === 'string') {\n var type = resource.xhr.getResponseHeader('content-type');\n // this is an image, convert the binary string into a data url\n if (type && type.indexOf('image') === 0) {\n resource.data = new Image();\n resource.data.src = \"data:\" + type + \";base64,\" + encodeBinary(resource.xhr.responseText);\n resource.type = LoaderResource.TYPE.IMAGE;\n // wait until the image loads and then callback\n resource.data.onload = function () {\n resource.data.onload = null;\n next();\n };\n // next will be called on load\n return;\n }\n }\n // if content type says this is an image, then we should transform the blob into an Image object\n else if (resource.data.type.indexOf('image') === 0) {\n var src_1 = Url.createObjectURL(resource.data);\n resource.blob = resource.data;\n resource.data = new Image();\n resource.data.src = src_1;\n resource.type = LoaderResource.TYPE.IMAGE;\n // cleanup the no longer used blob after the image loads\n // TODO: Is this correct? Will the image be invalid after revoking?\n resource.data.onload = function () {\n Url.revokeObjectURL(src_1);\n resource.data.onload = null;\n next();\n };\n // next will be called on load.\n return;\n }\n }\n next();\n}\n\n// parse any blob into more usable objects (e.g. Image)\nLoader.registerPlugin({ use: parsing });\n// parse any Image objects into textures\nLoader.registerPlugin(TextureLoader);\n\nexport { AppLoaderPlugin, Loader, LoaderResource, TextureLoader };\n//# sourceMappingURL=loaders.js.map\n","/*!\n * @pixi/compressed-textures - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/compressed-textures is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { ViewableBuffer, BufferResource, Texture, BaseTexture } from '@pixi/core';\nimport { LoaderResource } from '@pixi/loaders';\nimport { url } from '@pixi/utils';\nimport { MIPMAP_MODES, ALPHA_MODES, TYPES, FORMATS } from '@pixi/constants';\n\nvar _a;\n/**\n * WebGL internal formats, including compressed texture formats provided by extensions\n *\n * @memberof PIXI\n * @static\n * @name INTERNAL_FORMATS\n * @enum {number}\n * @property {number} COMPRESSED_RGB_S3TC_DXT1_EXT=0x83F0\n * @property {number} COMPRESSED_RGBA_S3TC_DXT1_EXT=0x83F1\n * @property {number} COMPRESSED_RGBA_S3TC_DXT3_EXT=0x83F2\n * @property {number} COMPRESSED_RGBA_S3TC_DXT5_EXT=0x83F3\n * @property {number} COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT=35917\n * @property {number} COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT=35918\n * @property {number} COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT=35919\n * @property {number} COMPRESSED_SRGB_S3TC_DXT1_EXT=35916\n * @property {number} COMPRESSED_R11_EAC=0x9270\n * @property {number} COMPRESSED_SIGNED_R11_EAC=0x9271\n * @property {number} COMPRESSED_RG11_EAC=0x9272\n * @property {number} COMPRESSED_SIGNED_RG11_EAC=0x9273\n * @property {number} COMPRESSED_RGB8_ETC2=0x9274\n * @property {number} COMPRESSED_RGBA8_ETC2_EAC=0x9278\n * @property {number} COMPRESSED_SRGB8_ETC2=0x9275\n * @property {number} COMPRESSED_SRGB8_ALPHA8_ETC2_EAC=0x9279\n * @property {number} COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2=0x9276\n * @property {number} COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2=0x9277\n * @property {number} COMPRESSED_RGB_PVRTC_4BPPV1_IMG=0x8C00\n * @property {number} COMPRESSED_RGBA_PVRTC_4BPPV1_IMG=0x8C02\n * @property {number} COMPRESSED_RGB_PVRTC_2BPPV1_IMG=0x8C01\n * @property {number} COMPRESSED_RGBA_PVRTC_2BPPV1_IMG=0x8C03\n * @property {number} COMPRESSED_RGB_ETC1_WEBGL=0x8D64\n * @property {number} COMPRESSED_RGB_ATC_WEBGL=0x8C92\n * @property {number} COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL=0x8C92\n * @property {number} COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL=0x87EE\n */\nvar INTERNAL_FORMATS;\n(function (INTERNAL_FORMATS) {\n // WEBGL_compressed_texture_s3tc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_S3TC_DXT1_EXT\"] = 33776] = \"COMPRESSED_RGB_S3TC_DXT1_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_S3TC_DXT1_EXT\"] = 33777] = \"COMPRESSED_RGBA_S3TC_DXT1_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_S3TC_DXT3_EXT\"] = 33778] = \"COMPRESSED_RGBA_S3TC_DXT3_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_S3TC_DXT5_EXT\"] = 33779] = \"COMPRESSED_RGBA_S3TC_DXT5_EXT\";\n // WEBGL_compressed_texture_s3tc_srgb\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT\"] = 35917] = \"COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT\"] = 35918] = \"COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT\"] = 35919] = \"COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB_S3TC_DXT1_EXT\"] = 35916] = \"COMPRESSED_SRGB_S3TC_DXT1_EXT\";\n // WEBGL_compressed_texture_etc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_R11_EAC\"] = 37488] = \"COMPRESSED_R11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SIGNED_R11_EAC\"] = 37489] = \"COMPRESSED_SIGNED_R11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RG11_EAC\"] = 37490] = \"COMPRESSED_RG11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SIGNED_RG11_EAC\"] = 37491] = \"COMPRESSED_SIGNED_RG11_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB8_ETC2\"] = 37492] = \"COMPRESSED_RGB8_ETC2\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA8_ETC2_EAC\"] = 37496] = \"COMPRESSED_RGBA8_ETC2_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB8_ETC2\"] = 37493] = \"COMPRESSED_SRGB8_ETC2\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB8_ALPHA8_ETC2_EAC\"] = 37497] = \"COMPRESSED_SRGB8_ALPHA8_ETC2_EAC\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2\"] = 37494] = \"COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2\"] = 37495] = \"COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2\";\n // WEBGL_compressed_texture_pvrtc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_PVRTC_4BPPV1_IMG\"] = 35840] = \"COMPRESSED_RGB_PVRTC_4BPPV1_IMG\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_PVRTC_4BPPV1_IMG\"] = 35842] = \"COMPRESSED_RGBA_PVRTC_4BPPV1_IMG\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_PVRTC_2BPPV1_IMG\"] = 35841] = \"COMPRESSED_RGB_PVRTC_2BPPV1_IMG\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_PVRTC_2BPPV1_IMG\"] = 35843] = \"COMPRESSED_RGBA_PVRTC_2BPPV1_IMG\";\n // WEBGL_compressed_texture_etc1\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_ETC1_WEBGL\"] = 36196] = \"COMPRESSED_RGB_ETC1_WEBGL\";\n // WEBGL_compressed_texture_atc\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGB_ATC_WEBGL\"] = 35986] = \"COMPRESSED_RGB_ATC_WEBGL\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL\"] = 35986] = \"COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL\";\n INTERNAL_FORMATS[INTERNAL_FORMATS[\"COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL\"] = 34798] = \"COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL\";\n})(INTERNAL_FORMATS || (INTERNAL_FORMATS = {}));\n/**\n * Maps the compressed texture formats in {@link PIXI.INTERNAL_FORMATS} to the number of bytes taken by\n * each texel.\n *\n * @memberof PIXI\n * @static\n * @ignore\n */\nvar INTERNAL_FORMAT_TO_BYTES_PER_PIXEL = (_a = {},\n // WEBGL_compressed_texture_s3tc\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT] = 1,\n // WEBGL_compressed_texture_s3tc\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT] = 1,\n // WEBGL_compressed_texture_etc\n _a[INTERNAL_FORMATS.COMPRESSED_R11_EAC] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SIGNED_R11_EAC] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RG11_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_SIGNED_RG11_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGB8_ETC2] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA8_ETC2_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB8_ETC2] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2] = 0.5,\n // WEBGL_compressed_texture_pvrtc\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_PVRTC_4BPPV1_IMG] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_PVRTC_2BPPV1_IMG] = 0.25,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG] = 0.25,\n // WEBGL_compressed_texture_etc1\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_ETC1_WEBGL] = 0.5,\n // @see https://www.khronos.org/registry/OpenGL/extensions/AMD/AMD_compressed_ATC_texture.txt\n // WEBGL_compressed_texture_atc\n _a[INTERNAL_FORMATS.COMPRESSED_RGB_ATC_WEBGL] = 0.5,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL] = 1,\n _a[INTERNAL_FORMATS.COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL] = 1,\n _a);\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nfunction __awaiter(thisArg, _arguments, P, generator) {\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nfunction __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) { throw t[1]; } return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) { throw new TypeError(\"Generator is already executing.\"); }\r\n while (_) { try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) { return t; }\r\n if (y = 0, t) { op = [op[0] & 2, t.value]; }\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) { _.ops.pop(); }\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } }\r\n if (op[0] & 5) { throw op[1]; } return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\n\n/**\n * Resource that fetches texture data over the network and stores it in a buffer.\n *\n * @class\n * @extends PIXI.Resource\n * @memberof PIXI\n */\nvar BlobResource = /** @class */ (function (_super) {\n __extends(BlobResource, _super);\n /**\n * @param {string} url - the URL of the texture file\n * @param {boolean}[autoLoad] - whether to fetch the data immediately;\n * you can fetch it later via {@link BlobResource#load}\n */\n function BlobResource(source, options) {\n if (options === void 0) { options = { width: 1, height: 1, autoLoad: true }; }\n var _this = this;\n var origin;\n var data;\n if (typeof source === 'string') {\n origin = source;\n data = new Uint8Array();\n }\n else {\n origin = null;\n data = source;\n }\n _this = _super.call(this, data, options) || this;\n /**\n * The URL of the texture file\n * @member {string}\n */\n _this.origin = origin;\n /**\n * The viewable buffer on the data\n * @member {ViewableBuffer}\n */\n // HINT: BlobResource allows \"null\" sources, assuming the child class provides an alternative\n _this.buffer = data ? new ViewableBuffer(data) : null;\n // Allow autoLoad = \"undefined\" still load the resource by default\n if (_this.origin && options.autoLoad !== false) {\n _this.load();\n }\n if (data && data.length) {\n _this.loaded = true;\n _this.onBlobLoaded(_this.buffer.rawBinaryData);\n }\n return _this;\n }\n BlobResource.prototype.onBlobLoaded = function (_data) {\n // TODO: Override this method\n };\n /**\n * Loads the blob\n */\n BlobResource.prototype.load = function () {\n return __awaiter(this, void 0, Promise, function () {\n var response, blob, arrayBuffer;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4 /*yield*/, fetch(this.origin)];\n case 1:\n response = _a.sent();\n return [4 /*yield*/, response.blob()];\n case 2:\n blob = _a.sent();\n return [4 /*yield*/, blob.arrayBuffer()];\n case 3:\n arrayBuffer = _a.sent();\n this.data = new Uint32Array(arrayBuffer);\n this.buffer = new ViewableBuffer(arrayBuffer);\n this.loaded = true;\n this.onBlobLoaded(arrayBuffer);\n this.update();\n return [2 /*return*/, this];\n }\n });\n });\n };\n return BlobResource;\n}(BufferResource));\n\n/**\n * Resource for compressed texture formats, as follows: S3TC/DXTn (& their sRGB formats), ATC, ASTC, ETC 1/2, PVRTC.\n *\n * Compressed textures improve performance when rendering is texture-bound. The texture data stays compressed in\n * graphics memory, increasing memory locality and speeding up texture fetches. These formats can also be used to store\n * more detail in the same amount of memory.\n *\n * For most developers, container file formats are a better abstraction instead of directly handling raw texture\n * data. PixiJS provides native support for the following texture file formats (via {@link PIXI.Loader}):\n *\n * * **.dds** - the DirectDraw Surface file format stores DXTn (DXT-1,3,5) data. See {@link PIXI.DDSLoader}\n * * **.ktx** - the Khronos Texture Container file format supports storing all the supported WebGL compression formats.\n * See {@link PIXI.KTXLoader}.\n * * **.basis** - the BASIS supercompressed file format stores texture data in an internal format that is transcoded\n * to the compression format supported on the device at _runtime_. It also supports transcoding into a uncompressed\n * format as a fallback; you must install the `@pixi/basis-loader`, `@pixi/basis-transcoder` packages separately to\n * use these files. See {@link PIXI.BasisLoader}.\n *\n * The loaders for the aforementioned formats use `CompressedTextureResource` internally. It is strongly suggested that\n * they be used instead.\n *\n * ## Working directly with CompressedTextureResource\n *\n * Since `CompressedTextureResource` inherits `BlobResource`, you can provide it a URL pointing to a file containing\n * the raw texture data (with no file headers!):\n *\n * ```js\n * // The resource backing the texture data for your textures.\n * // NOTE: You can also provide a ArrayBufferView instead of a URL. This is used when loading data from a container file\n * // format such as KTX, DDS, or BASIS.\n * const compressedResource = new PIXI.CompressedTextureResource(\"bunny.dxt5\", {\n * format: PIXI.INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n * width: 256,\n * height: 256\n * });\n *\n * // You can create a base-texture to the cache, so that future `Texture`s can be created using the `Texture.from` API.\n * const baseTexture = new PIXI.BaseTexture(compressedResource, { pmaMode: PIXI.ALPHA_MODES.NPM });\n *\n * // Create a Texture to add to the TextureCache\n * const texture = new PIXI.Texture(baseTexture);\n *\n * // Add baseTexture & texture to the global texture cache\n * PIXI.BaseTexture.addToCache(baseTexture, \"bunny.dxt5\");\n * PIXI.Texture.addToCache(texture, \"bunny.dxt5\");\n * ```\n *\n * @memberof PIXI\n */\nvar CompressedTextureResource = /** @class */ (function (_super) {\n __extends(CompressedTextureResource, _super);\n /**\n * @param source - the buffer/URL holding the compressed texture data\n * @param options\n * @param {PIXI.INTERNAL_FORMATS} options.format - the compression format\n * @param {number} options.width - the image width in pixels.\n * @param {number} options.height - the image height in pixels.\n * @param {number} [options.level=1] - the mipmap levels stored in the compressed texture, including level 0.\n * @param {number} [options.levelBuffers] - the buffers for each mipmap level. `CompressedTextureResource` can allows you\n * to pass `null` for `source`, for cases where each level is stored in non-contiguous memory.\n */\n function CompressedTextureResource(source, options) {\n var _this = _super.call(this, source, options) || this;\n _this.format = options.format;\n _this.levels = options.levels || 1;\n _this._width = options.width;\n _this._height = options.height;\n _this._extension = CompressedTextureResource._formatToExtension(_this.format);\n if (options.levelBuffers || _this.buffer) {\n // ViewableBuffer doesn't support byteOffset :-( so allow source to be Uint8Array\n _this._levelBuffers = options.levelBuffers\n || CompressedTextureResource._createLevelBuffers(source instanceof Uint8Array ? source : _this.buffer.uint8View, _this.format, _this.levels, 4, 4, // PVRTC has 8x4 blocks in 2bpp mode\n _this.width, _this.height);\n }\n return _this;\n }\n /**\n * @override\n * @param renderer - A reference to the current renderer\n * @param _texture - the texture\n * @param _glTexture - texture instance for this webgl context\n */\n CompressedTextureResource.prototype.upload = function (renderer, _texture, _glTexture) {\n var gl = renderer.gl;\n var extension = renderer.context.extensions[this._extension];\n if (!extension) {\n throw new Error(this._extension + \" textures are not supported on the current machine\");\n }\n if (!this._levelBuffers) {\n // Do not try to upload data before BlobResource loads, unless the levelBuffers were provided directly!\n return false;\n }\n for (var i = 0, j = this.levels; i < j; i++) {\n var _a = this._levelBuffers[i], levelID = _a.levelID, levelWidth = _a.levelWidth, levelHeight = _a.levelHeight, levelBuffer = _a.levelBuffer;\n gl.compressedTexImage2D(gl.TEXTURE_2D, levelID, this.format, levelWidth, levelHeight, 0, levelBuffer);\n }\n return true;\n };\n /** @protected */\n CompressedTextureResource.prototype.onBlobLoaded = function () {\n this._levelBuffers = CompressedTextureResource._createLevelBuffers(this.buffer.uint8View, this.format, this.levels, 4, 4, // PVRTC has 8x4 blocks in 2bpp mode\n this.width, this.height);\n };\n /**\n * Returns the key (to ContextSystem#extensions) for the WebGL extension supporting the compression format\n *\n * @private\n * @param format - the compression format to get the extension for.\n */\n CompressedTextureResource._formatToExtension = function (format) {\n if (format >= 0x83F0 && format <= 0x83F3) {\n return 's3tc';\n }\n else if (format >= 0x9270 && format <= 0x9279) {\n return 'etc';\n }\n else if (format >= 0x8C00 && format <= 0x8C03) {\n return 'pvrtc';\n }\n else if (format >= 0x8D64) {\n return 'etc1';\n }\n else if (format >= 0x8C92 && format <= 0x87EE) {\n return 'atc';\n }\n throw new Error('Invalid (compressed) texture format given!');\n };\n /**\n * Pre-creates buffer views for each mipmap level\n *\n * @private\n * @param buffer -\n * @param format - compression formats\n * @param levels - mipmap levels\n * @param blockWidth -\n * @param blockHeight -\n * @param imageWidth - width of the image in pixels\n * @param imageHeight - height of the image in pixels\n */\n CompressedTextureResource._createLevelBuffers = function (buffer, format, levels, blockWidth, blockHeight, imageWidth, imageHeight) {\n // The byte-size of the first level buffer\n var buffers = new Array(levels);\n var offset = buffer.byteOffset;\n var levelWidth = imageWidth;\n var levelHeight = imageHeight;\n var alignedLevelWidth = (levelWidth + blockWidth - 1) & ~(blockWidth - 1);\n var alignedLevelHeight = (levelHeight + blockHeight - 1) & ~(blockHeight - 1);\n var levelSize = alignedLevelWidth * alignedLevelHeight * INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[format];\n for (var i = 0; i < levels; i++) {\n buffers[i] = {\n levelID: i,\n levelWidth: levels > 1 ? levelWidth : alignedLevelWidth,\n levelHeight: levels > 1 ? levelHeight : alignedLevelHeight,\n levelBuffer: new Uint8Array(buffer.buffer, offset, levelSize)\n };\n offset += levelSize;\n // Calculate levelBuffer dimensions for next iteration\n levelWidth = (levelWidth >> 1) || 1;\n levelHeight = (levelHeight >> 1) || 1;\n alignedLevelWidth = (levelWidth + blockWidth - 1) & ~(blockWidth - 1);\n alignedLevelHeight = (levelHeight + blockHeight - 1) & ~(blockHeight - 1);\n levelSize = alignedLevelWidth * alignedLevelHeight * INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[format];\n }\n return buffers;\n };\n return CompressedTextureResource;\n}(BlobResource));\n\n/* eslint-enable camelcase */\n/**\n * Loader plugin for handling compressed textures for all platforms.\n *\n * @class\n * @memberof PIXI\n * @implements PIXI.ILoaderPlugin\n */\nvar CompressedTextureLoader = /** @class */ (function () {\n function CompressedTextureLoader() {\n }\n /**\n * Called after a compressed-textures manifest is loaded.\n *\n * This will then load the correct compression format for the device. Your manifest should adhere\n * to the following schema:\n *\n * ```js\n * import { INTERNAL_FORMATS } from '@pixi/constants';\n *\n * type CompressedTextureManifest = {\n * textures: Array<{ src: string, format?: keyof INTERNAL_FORMATS}>,\n * cacheID: string;\n * };\n * ```\n *\n * This is an example of a .json manifest file\n *\n * ```json\n * {\n * \"cacheID\":\"asset\",\n * \"textures\":[\n * { \"src\":\"asset.fallback.png\" },\n * { \"format\":\"COMPRESSED_RGBA_S3TC_DXT5_EXT\", \"src\":\"asset.s3tc.ktx\" },\n * { \"format\":\"COMPRESSED_RGBA8_ETC2_EAC\", \"src\":\"asset.etc.ktx\" },\n * { \"format\":\"RGBA_PVRTC_4BPPV1_IMG\", \"src\":\"asset.pvrtc.ktx\" }\n * ]\n * }\n * ```\n */\n CompressedTextureLoader.use = function (resource, next) {\n var data = resource.data;\n var loader = this;\n if (resource.type === LoaderResource.TYPE.JSON\n && data\n && data.cacheID\n && data.textures) {\n var textures = data.textures;\n var textureURL = void 0;\n var fallbackURL = void 0;\n // Search for an extension that holds one the formats\n for (var i = 0, j = textures.length; i < j; i++) {\n var texture = textures[i];\n var url_1 = texture.src;\n var format = texture.format;\n if (!format) {\n fallbackURL = url_1;\n }\n if (CompressedTextureLoader.textureFormats[format]) {\n textureURL = url_1;\n break;\n }\n }\n textureURL = textureURL || fallbackURL;\n // Make sure we have a URL\n if (!textureURL) {\n next(new Error(\"Cannot load compressed-textures in \" + resource.url + \", make sure you provide a fallback\"));\n return;\n }\n if (textureURL === resource.url) {\n // Prevent infinite loops\n next(new Error('URL of compressed texture cannot be the same as the manifest\\'s URL'));\n return;\n }\n var loadOptions = {\n crossOrigin: resource.crossOrigin,\n metadata: resource.metadata.imageMetadata,\n parentResource: resource\n };\n var resourcePath = url.resolve(resource.url.replace(loader.baseUrl, ''), textureURL);\n var resourceName = data.cacheID;\n // The appropriate loader should register the texture\n loader.add(resourceName, resourcePath, loadOptions, function (res) {\n if (res.error) {\n next(res.error);\n return;\n }\n var _a = res.texture, texture = _a === void 0 ? null : _a, _b = res.textures, textures = _b === void 0 ? {} : _b;\n // Make sure texture/textures is assigned to parent resource\n Object.assign(resource, { texture: texture, textures: textures });\n // Pass along any error\n next();\n });\n }\n else {\n next();\n }\n };\n /**\n * Detects the available compressed texture extensions on the device.\n * @ignore\n */\n CompressedTextureLoader.add = function () {\n // Auto-detect WebGL compressed-texture extensions\n var canvas = document.createElement('canvas');\n var gl = canvas.getContext('webgl');\n if (!gl) {\n console.warn('WebGL not available for compressed textures. Silently failing.');\n return;\n }\n var extensions = {\n s3tc: gl.getExtension('WEBGL_compressed_texture_s3tc'),\n s3tc_sRGB: gl.getExtension('WEBGL_compressed_texture_s3tc_srgb'),\n etc: gl.getExtension('WEBGL_compressed_texture_etc'),\n etc1: gl.getExtension('WEBGL_compressed_texture_etc1'),\n pvrtc: gl.getExtension('WEBGL_compressed_texture_pvrtc')\n || gl.getExtension('WEBKIT_WEBGL_compressed_texture_pvrtc'),\n atc: gl.getExtension('WEBGL_compressed_texture_atc'),\n astc: gl.getExtension('WEBGL_compressed_texture_astc')\n };\n CompressedTextureLoader.textureExtensions = extensions;\n CompressedTextureLoader.textureFormats = {};\n // Assign all available compressed-texture formats\n for (var extensionName in extensions) {\n var extension = extensions[extensionName];\n if (!extension) {\n continue;\n }\n Object.assign(CompressedTextureLoader.textureFormats, Object.getPrototypeOf(extension));\n }\n };\n return CompressedTextureLoader;\n}());\n\n/**\n * Creates base-textures and textures for each compressed-texture resource and adds them into the global\n * texture cache. The first texture has two IDs - `${url}`, `${url}-1`; while the rest have an ID of the\n * form `${url}-i`.\n *\n * @param url - the original address of the resources\n * @param resources - the resources backing texture data\n * @ignore\n */\nfunction registerCompressedTextures(url, resources, metadata) {\n var result = {\n textures: {},\n texture: null,\n };\n if (!resources) {\n return result;\n }\n var textures = resources.map(function (resource) {\n return (new Texture(new BaseTexture(resource, Object.assign({\n mipmap: MIPMAP_MODES.OFF,\n alphaMode: ALPHA_MODES.NO_PREMULTIPLIED_ALPHA\n }, metadata))));\n });\n textures.forEach(function (texture, i) {\n var baseTexture = texture.baseTexture;\n var cacheID = url + \"-\" + (i + 1);\n BaseTexture.addToCache(baseTexture, cacheID);\n Texture.addToCache(texture, cacheID);\n if (i === 0) {\n BaseTexture.addToCache(baseTexture, url);\n Texture.addToCache(texture, url);\n result.texture = texture;\n }\n result.textures[cacheID] = texture;\n });\n return result;\n}\n\nvar _a$1, _b;\n// Set DDS files to be loaded as an ArrayBuffer\nLoaderResource.setExtensionXhrType('dds', LoaderResource.XHR_RESPONSE_TYPE.BUFFER);\nvar DDS_MAGIC_SIZE = 4;\nvar DDS_HEADER_SIZE = 124;\nvar DDS_HEADER_PF_SIZE = 32;\nvar DDS_HEADER_DX10_SIZE = 20;\n// DDS file format magic word\nvar DDS_MAGIC = 0x20534444;\n/**\n * DWORD offsets of the DDS file header fields (relative to file start).\n *\n * @ignore\n */\nvar DDS_FIELDS = {\n SIZE: 1,\n FLAGS: 2,\n HEIGHT: 3,\n WIDTH: 4,\n MIPMAP_COUNT: 7,\n PIXEL_FORMAT: 19,\n};\n/**\n * DWORD offsets of the DDS PIXEL_FORMAT fields.\n *\n * @ignore\n */\nvar DDS_PF_FIELDS = {\n SIZE: 0,\n FLAGS: 1,\n FOURCC: 2,\n RGB_BITCOUNT: 3,\n R_BIT_MASK: 4,\n G_BIT_MASK: 5,\n B_BIT_MASK: 6,\n A_BIT_MASK: 7\n};\n/**\n * DWORD offsets of the DDS_HEADER_DX10 fields.\n *\n * @ignore\n */\nvar DDS_DX10_FIELDS = {\n DXGI_FORMAT: 0,\n RESOURCE_DIMENSION: 1,\n MISC_FLAG: 2,\n ARRAY_SIZE: 3,\n MISC_FLAGS2: 4\n};\n/**\n * @see https://docs.microsoft.com/en-us/windows/win32/api/dxgiformat/ne-dxgiformat-dxgi_format\n * @ignore\n */\n// This is way over-blown for us! Lend us a hand, and remove the ones that aren't used (but set the remaining\n// ones to their correct value)\nvar DXGI_FORMAT;\n(function (DXGI_FORMAT) {\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_UNKNOWN\"] = 0] = \"DXGI_FORMAT_UNKNOWN\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_TYPELESS\"] = 1] = \"DXGI_FORMAT_R32G32B32A32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_FLOAT\"] = 2] = \"DXGI_FORMAT_R32G32B32A32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_UINT\"] = 3] = \"DXGI_FORMAT_R32G32B32A32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32A32_SINT\"] = 4] = \"DXGI_FORMAT_R32G32B32A32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_TYPELESS\"] = 5] = \"DXGI_FORMAT_R32G32B32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_FLOAT\"] = 6] = \"DXGI_FORMAT_R32G32B32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_UINT\"] = 7] = \"DXGI_FORMAT_R32G32B32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32B32_SINT\"] = 8] = \"DXGI_FORMAT_R32G32B32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_TYPELESS\"] = 9] = \"DXGI_FORMAT_R16G16B16A16_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_FLOAT\"] = 10] = \"DXGI_FORMAT_R16G16B16A16_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_UNORM\"] = 11] = \"DXGI_FORMAT_R16G16B16A16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_UINT\"] = 12] = \"DXGI_FORMAT_R16G16B16A16_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_SNORM\"] = 13] = \"DXGI_FORMAT_R16G16B16A16_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16B16A16_SINT\"] = 14] = \"DXGI_FORMAT_R16G16B16A16_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_TYPELESS\"] = 15] = \"DXGI_FORMAT_R32G32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_FLOAT\"] = 16] = \"DXGI_FORMAT_R32G32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_UINT\"] = 17] = \"DXGI_FORMAT_R32G32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G32_SINT\"] = 18] = \"DXGI_FORMAT_R32G32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32G8X24_TYPELESS\"] = 19] = \"DXGI_FORMAT_R32G8X24_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D32_FLOAT_S8X24_UINT\"] = 20] = \"DXGI_FORMAT_D32_FLOAT_S8X24_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS\"] = 21] = \"DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_X32_TYPELESS_G8X24_UINT\"] = 22] = \"DXGI_FORMAT_X32_TYPELESS_G8X24_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10A2_TYPELESS\"] = 23] = \"DXGI_FORMAT_R10G10B10A2_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10A2_UNORM\"] = 24] = \"DXGI_FORMAT_R10G10B10A2_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10A2_UINT\"] = 25] = \"DXGI_FORMAT_R10G10B10A2_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R11G11B10_FLOAT\"] = 26] = \"DXGI_FORMAT_R11G11B10_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_TYPELESS\"] = 27] = \"DXGI_FORMAT_R8G8B8A8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_UNORM\"] = 28] = \"DXGI_FORMAT_R8G8B8A8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_UNORM_SRGB\"] = 29] = \"DXGI_FORMAT_R8G8B8A8_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_UINT\"] = 30] = \"DXGI_FORMAT_R8G8B8A8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_SNORM\"] = 31] = \"DXGI_FORMAT_R8G8B8A8_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8B8A8_SINT\"] = 32] = \"DXGI_FORMAT_R8G8B8A8_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_TYPELESS\"] = 33] = \"DXGI_FORMAT_R16G16_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_FLOAT\"] = 34] = \"DXGI_FORMAT_R16G16_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_UNORM\"] = 35] = \"DXGI_FORMAT_R16G16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_UINT\"] = 36] = \"DXGI_FORMAT_R16G16_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_SNORM\"] = 37] = \"DXGI_FORMAT_R16G16_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16G16_SINT\"] = 38] = \"DXGI_FORMAT_R16G16_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_TYPELESS\"] = 39] = \"DXGI_FORMAT_R32_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D32_FLOAT\"] = 40] = \"DXGI_FORMAT_D32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_FLOAT\"] = 41] = \"DXGI_FORMAT_R32_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_UINT\"] = 42] = \"DXGI_FORMAT_R32_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R32_SINT\"] = 43] = \"DXGI_FORMAT_R32_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R24G8_TYPELESS\"] = 44] = \"DXGI_FORMAT_R24G8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D24_UNORM_S8_UINT\"] = 45] = \"DXGI_FORMAT_D24_UNORM_S8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R24_UNORM_X8_TYPELESS\"] = 46] = \"DXGI_FORMAT_R24_UNORM_X8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_X24_TYPELESS_G8_UINT\"] = 47] = \"DXGI_FORMAT_X24_TYPELESS_G8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_TYPELESS\"] = 48] = \"DXGI_FORMAT_R8G8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_UNORM\"] = 49] = \"DXGI_FORMAT_R8G8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_UINT\"] = 50] = \"DXGI_FORMAT_R8G8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_SNORM\"] = 51] = \"DXGI_FORMAT_R8G8_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_SINT\"] = 52] = \"DXGI_FORMAT_R8G8_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_TYPELESS\"] = 53] = \"DXGI_FORMAT_R16_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_FLOAT\"] = 54] = \"DXGI_FORMAT_R16_FLOAT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_D16_UNORM\"] = 55] = \"DXGI_FORMAT_D16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_UNORM\"] = 56] = \"DXGI_FORMAT_R16_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_UINT\"] = 57] = \"DXGI_FORMAT_R16_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_SNORM\"] = 58] = \"DXGI_FORMAT_R16_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R16_SINT\"] = 59] = \"DXGI_FORMAT_R16_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_TYPELESS\"] = 60] = \"DXGI_FORMAT_R8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_UNORM\"] = 61] = \"DXGI_FORMAT_R8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_UINT\"] = 62] = \"DXGI_FORMAT_R8_UINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_SNORM\"] = 63] = \"DXGI_FORMAT_R8_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8_SINT\"] = 64] = \"DXGI_FORMAT_R8_SINT\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_A8_UNORM\"] = 65] = \"DXGI_FORMAT_A8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R1_UNORM\"] = 66] = \"DXGI_FORMAT_R1_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R9G9B9E5_SHAREDEXP\"] = 67] = \"DXGI_FORMAT_R9G9B9E5_SHAREDEXP\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R8G8_B8G8_UNORM\"] = 68] = \"DXGI_FORMAT_R8G8_B8G8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_G8R8_G8B8_UNORM\"] = 69] = \"DXGI_FORMAT_G8R8_G8B8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC1_TYPELESS\"] = 70] = \"DXGI_FORMAT_BC1_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC1_UNORM\"] = 71] = \"DXGI_FORMAT_BC1_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC1_UNORM_SRGB\"] = 72] = \"DXGI_FORMAT_BC1_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC2_TYPELESS\"] = 73] = \"DXGI_FORMAT_BC2_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC2_UNORM\"] = 74] = \"DXGI_FORMAT_BC2_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC2_UNORM_SRGB\"] = 75] = \"DXGI_FORMAT_BC2_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC3_TYPELESS\"] = 76] = \"DXGI_FORMAT_BC3_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC3_UNORM\"] = 77] = \"DXGI_FORMAT_BC3_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC3_UNORM_SRGB\"] = 78] = \"DXGI_FORMAT_BC3_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC4_TYPELESS\"] = 79] = \"DXGI_FORMAT_BC4_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC4_UNORM\"] = 80] = \"DXGI_FORMAT_BC4_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC4_SNORM\"] = 81] = \"DXGI_FORMAT_BC4_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC5_TYPELESS\"] = 82] = \"DXGI_FORMAT_BC5_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC5_UNORM\"] = 83] = \"DXGI_FORMAT_BC5_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC5_SNORM\"] = 84] = \"DXGI_FORMAT_BC5_SNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B5G6R5_UNORM\"] = 85] = \"DXGI_FORMAT_B5G6R5_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B5G5R5A1_UNORM\"] = 86] = \"DXGI_FORMAT_B5G5R5A1_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8A8_UNORM\"] = 87] = \"DXGI_FORMAT_B8G8R8A8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8X8_UNORM\"] = 88] = \"DXGI_FORMAT_B8G8R8X8_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM\"] = 89] = \"DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8A8_TYPELESS\"] = 90] = \"DXGI_FORMAT_B8G8R8A8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8A8_UNORM_SRGB\"] = 91] = \"DXGI_FORMAT_B8G8R8A8_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8X8_TYPELESS\"] = 92] = \"DXGI_FORMAT_B8G8R8X8_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B8G8R8X8_UNORM_SRGB\"] = 93] = \"DXGI_FORMAT_B8G8R8X8_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC6H_TYPELESS\"] = 94] = \"DXGI_FORMAT_BC6H_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC6H_UF16\"] = 95] = \"DXGI_FORMAT_BC6H_UF16\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC6H_SF16\"] = 96] = \"DXGI_FORMAT_BC6H_SF16\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC7_TYPELESS\"] = 97] = \"DXGI_FORMAT_BC7_TYPELESS\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC7_UNORM\"] = 98] = \"DXGI_FORMAT_BC7_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_BC7_UNORM_SRGB\"] = 99] = \"DXGI_FORMAT_BC7_UNORM_SRGB\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_AYUV\"] = 100] = \"DXGI_FORMAT_AYUV\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y410\"] = 101] = \"DXGI_FORMAT_Y410\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y416\"] = 102] = \"DXGI_FORMAT_Y416\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_NV12\"] = 103] = \"DXGI_FORMAT_NV12\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P010\"] = 104] = \"DXGI_FORMAT_P010\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P016\"] = 105] = \"DXGI_FORMAT_P016\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_420_OPAQUE\"] = 106] = \"DXGI_FORMAT_420_OPAQUE\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_YUY2\"] = 107] = \"DXGI_FORMAT_YUY2\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y210\"] = 108] = \"DXGI_FORMAT_Y210\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_Y216\"] = 109] = \"DXGI_FORMAT_Y216\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_NV11\"] = 110] = \"DXGI_FORMAT_NV11\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_AI44\"] = 111] = \"DXGI_FORMAT_AI44\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_IA44\"] = 112] = \"DXGI_FORMAT_IA44\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P8\"] = 113] = \"DXGI_FORMAT_P8\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_A8P8\"] = 114] = \"DXGI_FORMAT_A8P8\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_B4G4R4A4_UNORM\"] = 115] = \"DXGI_FORMAT_B4G4R4A4_UNORM\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_P208\"] = 116] = \"DXGI_FORMAT_P208\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_V208\"] = 117] = \"DXGI_FORMAT_V208\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_V408\"] = 118] = \"DXGI_FORMAT_V408\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE\"] = 119] = \"DXGI_FORMAT_SAMPLER_FEEDBACK_MIN_MIP_OPAQUE\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE\"] = 120] = \"DXGI_FORMAT_SAMPLER_FEEDBACK_MIP_REGION_USED_OPAQUE\";\n DXGI_FORMAT[DXGI_FORMAT[\"DXGI_FORMAT_FORCE_UINT\"] = 121] = \"DXGI_FORMAT_FORCE_UINT\";\n})(DXGI_FORMAT || (DXGI_FORMAT = {}));\n/**\n * Possible values of the field {@link DDS_DX10_FIELDS.RESOURCE_DIMENSION}\n *\n * @ignore\n */\nvar D3D10_RESOURCE_DIMENSION;\n(function (D3D10_RESOURCE_DIMENSION) {\n D3D10_RESOURCE_DIMENSION[D3D10_RESOURCE_DIMENSION[\"DDS_DIMENSION_TEXTURE1D\"] = 2] = \"DDS_DIMENSION_TEXTURE1D\";\n D3D10_RESOURCE_DIMENSION[D3D10_RESOURCE_DIMENSION[\"DDS_DIMENSION_TEXTURE2D\"] = 3] = \"DDS_DIMENSION_TEXTURE2D\";\n D3D10_RESOURCE_DIMENSION[D3D10_RESOURCE_DIMENSION[\"DDS_DIMENSION_TEXTURE3D\"] = 6] = \"DDS_DIMENSION_TEXTURE3D\";\n})(D3D10_RESOURCE_DIMENSION || (D3D10_RESOURCE_DIMENSION = {}));\nvar PF_FLAGS = 1;\n// PIXEL_FORMAT flags\nvar DDPF_ALPHA = 0x2;\nvar DDPF_FOURCC = 0x4;\nvar DDPF_RGB = 0x40;\nvar DDPF_YUV = 0x200;\nvar DDPF_LUMINANCE = 0x20000;\n// Four character codes for DXTn formats\nvar FOURCC_DXT1 = 0x31545844;\nvar FOURCC_DXT3 = 0x33545844;\nvar FOURCC_DXT5 = 0x35545844;\nvar FOURCC_DX10 = 0x30315844;\n// Cubemap texture flag (for DDS_DX10_FIELDS.MISC_FLAG)\nvar DDS_RESOURCE_MISC_TEXTURECUBE = 0x4;\n/**\n * Maps `FOURCC_*` formats to internal formats (see {@link PIXI.INTERNAL_FORMATS}).\n *\n * @ignore\n */\nvar FOURCC_TO_FORMAT = (_a$1 = {},\n _a$1[FOURCC_DXT1] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT,\n _a$1[FOURCC_DXT3] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT,\n _a$1[FOURCC_DXT5] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n _a$1);\n/**\n * Maps {@link DXGI_FORMAT} to types/internal-formats (see {@link PIXI.TYPES}, {@link PIXI.INTERNAL_FORMATS})\n *\n * @ignore\n */\nvar DXGI_TO_FORMAT = (_b = {},\n // WEBGL_compressed_texture_s3tc\n _b[DXGI_FORMAT.DXGI_FORMAT_BC1_TYPELESS] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC1_UNORM] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT1_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC2_TYPELESS] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC2_UNORM] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT3_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC3_TYPELESS] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC3_UNORM] = INTERNAL_FORMATS.COMPRESSED_RGBA_S3TC_DXT5_EXT,\n // WEBGL_compressed_texture_s3tc_srgb\n _b[DXGI_FORMAT.DXGI_FORMAT_BC1_UNORM_SRGB] = INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC2_UNORM_SRGB] = INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT,\n _b[DXGI_FORMAT.DXGI_FORMAT_BC3_UNORM_SRGB] = INTERNAL_FORMATS.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT,\n _b);\n/**\n * @class\n * @memberof PIXI\n * @implements PIXI.ILoaderPlugin\n * @see https://docs.microsoft.com/en-us/windows/win32/direct3ddds/dx-graphics-dds-pguide\n */\nvar DDSLoader = /** @class */ (function () {\n function DDSLoader() {\n }\n /**\n * Registers a DDS compressed texture\n * @see PIXI.Loader.loaderMiddleware\n * @param resource - loader resource that is checked to see if it is a DDS file\n * @param next - callback Function to call when done\n */\n DDSLoader.use = function (resource, next) {\n if (resource.extension === 'dds' && resource.data) {\n try {\n Object.assign(resource, registerCompressedTextures(resource.name || resource.url, DDSLoader.parse(resource.data), resource.metadata));\n }\n catch (err) {\n next(err);\n return;\n }\n }\n next();\n };\n /** Parses the DDS file header, generates base-textures, and puts them into the texture cache. */\n DDSLoader.parse = function (arrayBuffer) {\n var data = new Uint32Array(arrayBuffer);\n var magicWord = data[0];\n if (magicWord !== DDS_MAGIC) {\n throw new Error('Invalid DDS file magic word');\n }\n var header = new Uint32Array(arrayBuffer, 0, DDS_HEADER_SIZE / Uint32Array.BYTES_PER_ELEMENT);\n // DDS header fields\n var height = header[DDS_FIELDS.HEIGHT];\n var width = header[DDS_FIELDS.WIDTH];\n var mipmapCount = header[DDS_FIELDS.MIPMAP_COUNT];\n // PIXEL_FORMAT fields\n var pixelFormat = new Uint32Array(arrayBuffer, DDS_FIELDS.PIXEL_FORMAT * Uint32Array.BYTES_PER_ELEMENT, DDS_HEADER_PF_SIZE / Uint32Array.BYTES_PER_ELEMENT);\n var formatFlags = pixelFormat[PF_FLAGS];\n // File contains compressed texture(s)\n if (formatFlags & DDPF_FOURCC) {\n var fourCC = pixelFormat[DDS_PF_FIELDS.FOURCC];\n // File contains one DXTn compressed texture\n if (fourCC !== FOURCC_DX10) {\n var internalFormat_1 = FOURCC_TO_FORMAT[fourCC];\n var dataOffset_1 = DDS_MAGIC_SIZE + DDS_HEADER_SIZE;\n var texData = new Uint8Array(arrayBuffer, dataOffset_1);\n var resource = new CompressedTextureResource(texData, {\n format: internalFormat_1,\n width: width,\n height: height,\n levels: mipmapCount // CompressedTextureResource will separate the levelBuffers for us!\n });\n return [resource];\n }\n // FOURCC_DX10 indicates there is a 20-byte DDS_HEADER_DX10 after DDS_HEADER\n var dx10Offset = DDS_MAGIC_SIZE + DDS_HEADER_SIZE;\n var dx10Header = new Uint32Array(data.buffer, dx10Offset, DDS_HEADER_DX10_SIZE / Uint32Array.BYTES_PER_ELEMENT);\n var dxgiFormat = dx10Header[DDS_DX10_FIELDS.DXGI_FORMAT];\n var resourceDimension = dx10Header[DDS_DX10_FIELDS.RESOURCE_DIMENSION];\n var miscFlag = dx10Header[DDS_DX10_FIELDS.MISC_FLAG];\n var arraySize = dx10Header[DDS_DX10_FIELDS.ARRAY_SIZE];\n // Map dxgiFormat to PIXI.INTERNAL_FORMATS\n var internalFormat_2 = DXGI_TO_FORMAT[dxgiFormat];\n if (internalFormat_2 === undefined) {\n throw new Error(\"DDSLoader cannot parse texture data with DXGI format \" + dxgiFormat);\n }\n if (miscFlag === DDS_RESOURCE_MISC_TEXTURECUBE) {\n // FIXME: Anybody excited about cubemap compressed textures?\n throw new Error('DDSLoader does not support cubemap textures');\n }\n if (resourceDimension === D3D10_RESOURCE_DIMENSION.DDS_DIMENSION_TEXTURE3D) {\n // FIXME: Anybody excited about 3D compressed textures?\n throw new Error('DDSLoader does not supported 3D texture data');\n }\n // Uint8Array buffers of image data, including all mipmap levels in each image\n var imageBuffers = new Array();\n var dataOffset = DDS_MAGIC_SIZE\n + DDS_HEADER_SIZE\n + DDS_HEADER_DX10_SIZE;\n if (arraySize === 1) {\n // No need bothering with the imageSize calculation!\n imageBuffers.push(new Uint8Array(arrayBuffer, dataOffset));\n }\n else {\n // Calculate imageSize for each texture, and then locate each image's texture data\n var pixelSize = INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[internalFormat_2];\n var imageSize = 0;\n var levelWidth = width;\n var levelHeight = height;\n for (var i = 0; i < mipmapCount; i++) {\n var alignedLevelWidth = Math.max(1, (levelWidth + 3) & ~3);\n var alignedLevelHeight = Math.max(1, (levelHeight + 3) & ~3);\n var levelSize = alignedLevelWidth * alignedLevelHeight * pixelSize;\n imageSize += levelSize;\n levelWidth = levelWidth >>> 1;\n levelHeight = levelHeight >>> 1;\n }\n var imageOffset = dataOffset;\n // NOTE: Cubemaps have 6-images per texture (but they aren't supported so ^_^)\n for (var i = 0; i < arraySize; i++) {\n imageBuffers.push(new Uint8Array(arrayBuffer, imageOffset, imageSize));\n imageOffset += imageSize;\n }\n }\n // Uint8Array -> CompressedTextureResource, and we're done!\n return imageBuffers.map(function (buffer) { return new CompressedTextureResource(buffer, {\n format: internalFormat_2,\n width: width,\n height: height,\n levels: mipmapCount\n }); });\n }\n if (formatFlags & DDPF_RGB) {\n // FIXME: We might want to allow uncompressed *.dds files?\n throw new Error('DDSLoader does not support uncompressed texture data.');\n }\n if (formatFlags & DDPF_YUV) {\n // FIXME: Does anybody need this feature?\n throw new Error('DDSLoader does not supported YUV uncompressed texture data.');\n }\n if (formatFlags & DDPF_LUMINANCE) {\n // FIXME: Microsoft says older DDS filers use this feature! Probably not worth the effort!\n throw new Error('DDSLoader does not support single-channel (lumninance) texture data!');\n }\n if (formatFlags & DDPF_ALPHA) {\n // FIXME: I'm tired! See above =)\n throw new Error('DDSLoader does not support single-channel (alpha) texture data!');\n }\n throw new Error('DDSLoader failed to load a texture file due to an unknown reason!');\n };\n return DDSLoader;\n}());\n\nvar _a$2, _b$1, _c;\n// Set KTX files to be loaded as an ArrayBuffer\nLoaderResource.setExtensionXhrType('ktx', LoaderResource.XHR_RESPONSE_TYPE.BUFFER);\n/**\n * The 12-byte KTX file identifier\n *\n * @see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/#2.1\n * @ignore\n */\nvar FILE_IDENTIFIER = [0xAB, 0x4B, 0x54, 0x58, 0x20, 0x31, 0x31, 0xBB, 0x0D, 0x0A, 0x1A, 0x0A];\n/**\n * The value stored in the \"endianness\" field.\n *\n * @see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/#2.2\n * @ignore\n */\nvar ENDIANNESS = 0x04030201;\n/**\n * Byte offsets of the KTX file header fields\n *\n * @ignore\n */\nvar KTX_FIELDS = {\n FILE_IDENTIFIER: 0,\n ENDIANNESS: 12,\n GL_TYPE: 16,\n GL_TYPE_SIZE: 20,\n GL_FORMAT: 24,\n GL_INTERNAL_FORMAT: 28,\n GL_BASE_INTERNAL_FORMAT: 32,\n PIXEL_WIDTH: 36,\n PIXEL_HEIGHT: 40,\n PIXEL_DEPTH: 44,\n NUMBER_OF_ARRAY_ELEMENTS: 48,\n NUMBER_OF_FACES: 52,\n NUMBER_OF_MIPMAP_LEVELS: 56,\n BYTES_OF_KEY_VALUE_DATA: 60\n};\n/**\n * Byte size of the file header fields in {@code KTX_FIELDS}\n *\n * @ignore\n */\nvar FILE_HEADER_SIZE = 64;\n/**\n * Maps {@link PIXI.TYPES} to the bytes taken per component, excluding those ones that are bit-fields.\n *\n * @ignore\n */\nvar TYPES_TO_BYTES_PER_COMPONENT = (_a$2 = {},\n _a$2[TYPES.UNSIGNED_BYTE] = 1,\n _a$2[TYPES.UNSIGNED_SHORT] = 2,\n _a$2[TYPES.INT] = 4,\n _a$2[TYPES.UNSIGNED_INT] = 4,\n _a$2[TYPES.FLOAT] = 4,\n _a$2[TYPES.HALF_FLOAT] = 8,\n _a$2);\n/**\n * Number of components in each {@link PIXI.FORMATS}\n *\n * @ignore\n */\nvar FORMATS_TO_COMPONENTS = (_b$1 = {},\n _b$1[FORMATS.RGBA] = 4,\n _b$1[FORMATS.RGB] = 3,\n _b$1[FORMATS.RG] = 2,\n _b$1[FORMATS.RED] = 1,\n _b$1[FORMATS.LUMINANCE] = 1,\n _b$1[FORMATS.LUMINANCE_ALPHA] = 2,\n _b$1[FORMATS.ALPHA] = 1,\n _b$1);\n/**\n * Number of bytes per pixel in bit-field types in {@link PIXI.TYPES}\n *\n * @ignore\n */\nvar TYPES_TO_BYTES_PER_PIXEL = (_c = {},\n _c[TYPES.UNSIGNED_SHORT_4_4_4_4] = 2,\n _c[TYPES.UNSIGNED_SHORT_5_5_5_1] = 2,\n _c[TYPES.UNSIGNED_SHORT_5_6_5] = 2,\n _c);\n/**\n * Loader plugin for handling KTX texture container files.\n *\n * This KTX loader does not currently support the following features:\n * * cube textures\n * * 3D textures\n * * vendor-specific key/value data parsing\n * * endianness conversion for big-endian machines\n * * embedded *.basis files\n *\n * It does supports the following features:\n * * multiple textures per file\n * * mipmapping (only for compressed formats)\n *\n * @class\n * @memberof PIXI\n * @implements PIXI.ILoaderPlugin\n */\nvar KTXLoader = /** @class */ (function () {\n function KTXLoader() {\n }\n /**\n * Called after a KTX file is loaded.\n *\n * This will parse the KTX file header and add a {@code BaseTexture} to the texture\n * cache.\n *\n * @see PIXI.Loader.loaderMiddleware\n * @param resource - loader resource that is checked to see if it is a KTX file\n * @param next - callback Function to call when done\n */\n KTXLoader.use = function (resource, next) {\n if (resource.extension === 'ktx' && resource.data) {\n try {\n var url_1 = resource.name || resource.url;\n var _a = KTXLoader.parse(url_1, resource.data), compressed = _a.compressed, uncompressed = _a.uncompressed;\n if (compressed) {\n Object.assign(resource, registerCompressedTextures(url_1, compressed, resource.metadata));\n }\n else if (uncompressed) {\n var textures_1 = {};\n uncompressed.forEach(function (image, i) {\n var texture = new Texture(new BaseTexture(image.resource, {\n mipmap: MIPMAP_MODES.OFF,\n alphaMode: ALPHA_MODES.NO_PREMULTIPLIED_ALPHA,\n type: image.type,\n format: image.format,\n }));\n var cacheID = url_1 + \"-\" + (i + 1);\n BaseTexture.addToCache(texture.baseTexture, cacheID);\n Texture.addToCache(texture, cacheID);\n if (i === 0) {\n textures_1[url_1] = texture;\n BaseTexture.addToCache(texture.baseTexture, url_1);\n Texture.addToCache(texture, url_1);\n }\n textures_1[cacheID] = texture;\n });\n Object.assign(resource, { textures: textures_1 });\n }\n }\n catch (err) {\n next(err);\n return;\n }\n }\n next();\n };\n /** Parses the KTX file header, generates base-textures, and puts them into the texture cache. */\n KTXLoader.parse = function (url, arrayBuffer) {\n var dataView = new DataView(arrayBuffer);\n if (!KTXLoader.validate(url, dataView)) {\n return null;\n }\n var littleEndian = dataView.getUint32(KTX_FIELDS.ENDIANNESS, true) === ENDIANNESS;\n var glType = dataView.getUint32(KTX_FIELDS.GL_TYPE, littleEndian);\n // const glTypeSize = dataView.getUint32(KTX_FIELDS.GL_TYPE_SIZE, littleEndian);\n var glFormat = dataView.getUint32(KTX_FIELDS.GL_FORMAT, littleEndian);\n var glInternalFormat = dataView.getUint32(KTX_FIELDS.GL_INTERNAL_FORMAT, littleEndian);\n var pixelWidth = dataView.getUint32(KTX_FIELDS.PIXEL_WIDTH, littleEndian);\n var pixelHeight = dataView.getUint32(KTX_FIELDS.PIXEL_HEIGHT, littleEndian) || 1; // \"pixelHeight = 0\" -> \"1\"\n var pixelDepth = dataView.getUint32(KTX_FIELDS.PIXEL_DEPTH, littleEndian) || 1; // ^^\n var numberOfArrayElements = dataView.getUint32(KTX_FIELDS.NUMBER_OF_ARRAY_ELEMENTS, littleEndian) || 1; // ^^\n var numberOfFaces = dataView.getUint32(KTX_FIELDS.NUMBER_OF_FACES, littleEndian);\n var numberOfMipmapLevels = dataView.getUint32(KTX_FIELDS.NUMBER_OF_MIPMAP_LEVELS, littleEndian);\n var bytesOfKeyValueData = dataView.getUint32(KTX_FIELDS.BYTES_OF_KEY_VALUE_DATA, littleEndian);\n // Whether the platform architecture is little endian. If littleEndian !== platformLittleEndian, then the\n // file contents must be endian-converted!\n // TODO: Endianness conversion\n // const platformLittleEndian = new Uint8Array((new Uint32Array([ENDIANNESS])).buffer)[0] === 0x01;\n if (pixelHeight === 0 || pixelDepth !== 1) {\n throw new Error('Only 2D textures are supported');\n }\n if (numberOfFaces !== 1) {\n throw new Error('CubeTextures are not supported by KTXLoader yet!');\n }\n if (numberOfArrayElements !== 1) {\n // TODO: Support splitting array-textures into multiple BaseTextures\n throw new Error('WebGL does not support array textures');\n }\n // TODO: 8x4 blocks for 2bpp pvrtc\n var blockWidth = 4;\n var blockHeight = 4;\n var alignedWidth = (pixelWidth + 3) & ~3;\n var alignedHeight = (pixelHeight + 3) & ~3;\n var imageBuffers = new Array(numberOfArrayElements);\n var imagePixels = pixelWidth * pixelHeight;\n if (glType === 0) {\n // Align to 16 pixels (4x4 blocks)\n imagePixels = alignedWidth * alignedHeight;\n }\n var imagePixelByteSize;\n if (glType !== 0) {\n // Uncompressed texture format\n if (TYPES_TO_BYTES_PER_COMPONENT[glType]) {\n imagePixelByteSize = TYPES_TO_BYTES_PER_COMPONENT[glType] * FORMATS_TO_COMPONENTS[glFormat];\n }\n else {\n imagePixelByteSize = TYPES_TO_BYTES_PER_PIXEL[glType];\n }\n }\n else {\n imagePixelByteSize = INTERNAL_FORMAT_TO_BYTES_PER_PIXEL[glInternalFormat];\n }\n if (imagePixelByteSize === undefined) {\n throw new Error('Unable to resolve the pixel format stored in the *.ktx file!');\n }\n var imageByteSize = imagePixels * imagePixelByteSize;\n var mipByteSize = imageByteSize;\n var mipWidth = pixelWidth;\n var mipHeight = pixelHeight;\n var alignedMipWidth = alignedWidth;\n var alignedMipHeight = alignedHeight;\n var imageOffset = FILE_HEADER_SIZE + bytesOfKeyValueData;\n for (var mipmapLevel = 0; mipmapLevel < numberOfMipmapLevels; mipmapLevel++) {\n var imageSize = dataView.getUint32(imageOffset, littleEndian);\n var elementOffset = imageOffset + 4;\n for (var arrayElement = 0; arrayElement < numberOfArrayElements; arrayElement++) {\n // TODO: Maybe support 3D textures? :-)\n // for (let zSlice = 0; zSlice < pixelDepth; zSlice)\n var mips = imageBuffers[arrayElement];\n if (!mips) {\n mips = imageBuffers[arrayElement] = new Array(numberOfMipmapLevels);\n }\n mips[mipmapLevel] = {\n levelID: mipmapLevel,\n // don't align mipWidth when texture not compressed! (glType not zero)\n levelWidth: numberOfMipmapLevels > 1 || glType !== 0 ? mipWidth : alignedMipWidth,\n levelHeight: numberOfMipmapLevels > 1 || glType !== 0 ? mipHeight : alignedMipHeight,\n levelBuffer: new Uint8Array(arrayBuffer, elementOffset, mipByteSize)\n };\n elementOffset += mipByteSize;\n }\n // HINT: Aligns to 4-byte boundary after jumping imageSize (in lieu of mipPadding)\n imageOffset += imageSize + 4; // (+4 to jump the imageSize field itself)\n imageOffset = imageOffset % 4 !== 0 ? imageOffset + 4 - (imageOffset % 4) : imageOffset;\n // Calculate mipWidth, mipHeight for _next_ iteration\n mipWidth = (mipWidth >> 1) || 1;\n mipHeight = (mipHeight >> 1) || 1;\n alignedMipWidth = (mipWidth + blockWidth - 1) & ~(blockWidth - 1);\n alignedMipHeight = (mipHeight + blockHeight - 1) & ~(blockHeight - 1);\n // Each mipmap level is 4-times smaller?\n mipByteSize = alignedMipWidth * alignedMipHeight * imagePixelByteSize;\n }\n // We use the levelBuffers feature of CompressedTextureResource b/c texture data is image-major, not level-major.\n if (glType !== 0) {\n return {\n uncompressed: imageBuffers.map(function (levelBuffers) {\n var buffer = levelBuffers[0].levelBuffer;\n var convertToInt = false;\n if (glType === TYPES.FLOAT) {\n buffer = new Float32Array(levelBuffers[0].levelBuffer.buffer, levelBuffers[0].levelBuffer.byteOffset, levelBuffers[0].levelBuffer.byteLength / 4);\n }\n else if (glType === TYPES.UNSIGNED_INT) {\n convertToInt = true;\n buffer = new Uint32Array(levelBuffers[0].levelBuffer.buffer, levelBuffers[0].levelBuffer.byteOffset, levelBuffers[0].levelBuffer.byteLength / 4);\n }\n else if (glType === TYPES.INT) {\n convertToInt = true;\n buffer = new Int32Array(levelBuffers[0].levelBuffer.buffer, levelBuffers[0].levelBuffer.byteOffset, levelBuffers[0].levelBuffer.byteLength / 4);\n }\n return {\n resource: new BufferResource(buffer, {\n width: levelBuffers[0].levelWidth,\n height: levelBuffers[0].levelHeight,\n }),\n type: glType,\n format: convertToInt ? KTXLoader.convertFormatToInteger(glFormat) : glFormat,\n };\n })\n };\n }\n return {\n compressed: imageBuffers.map(function (levelBuffers) { return new CompressedTextureResource(null, {\n format: glInternalFormat,\n width: pixelWidth,\n height: pixelHeight,\n levels: numberOfMipmapLevels,\n levelBuffers: levelBuffers,\n }); })\n };\n };\n /** Checks whether the arrayBuffer contains a valid *.ktx file. */\n KTXLoader.validate = function (url, dataView) {\n // NOTE: Do not optimize this into 3 32-bit integer comparison because the endianness\n // of the data is not specified.\n for (var i = 0; i < FILE_IDENTIFIER.length; i++) {\n if (dataView.getUint8(i) !== FILE_IDENTIFIER[i]) {\n console.error(url + \" is not a valid *.ktx file!\");\n return false;\n }\n }\n return true;\n };\n KTXLoader.convertFormatToInteger = function (format) {\n switch (format) {\n case FORMATS.RGBA: return FORMATS.RGBA_INTEGER;\n case FORMATS.RGB: return FORMATS.RGB_INTEGER;\n case FORMATS.RG: return FORMATS.RG_INTEGER;\n case FORMATS.RED: return FORMATS.RED_INTEGER;\n default: return format;\n }\n };\n return KTXLoader;\n}());\n\nexport { BlobResource, CompressedTextureLoader, CompressedTextureResource, DDSLoader, FORMATS_TO_COMPONENTS, INTERNAL_FORMATS, INTERNAL_FORMAT_TO_BYTES_PER_PIXEL, KTXLoader, TYPES_TO_BYTES_PER_COMPONENT, TYPES_TO_BYTES_PER_PIXEL };\n//# sourceMappingURL=compressed-textures.js.map\n","/*!\n * @pixi/particle-container - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/particle-container is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { BLEND_MODES, TYPES } from '@pixi/constants';\nimport { Container } from '@pixi/display';\nimport { hex2rgb, createIndicesForQuads, correctBlendMode, premultiplyRgba, premultiplyTint } from '@pixi/utils';\nimport { Geometry, Buffer, ObjectRenderer, Shader, State } from '@pixi/core';\nimport { Matrix } from '@pixi/math';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * The ParticleContainer class is a really fast version of the Container built solely for speed,\n * so use when you need a lot of sprites or particles.\n *\n * The tradeoff of the ParticleContainer is that most advanced functionality will not work.\n * ParticleContainer implements the basic object transform (position, scale, rotation)\n * and some advanced functionality like tint (as of v4.5.6).\n *\n * Other more advanced functionality like masking, children, filters, etc will not work on sprites in this batch.\n *\n * It's extremely easy to use:\n * ```js\n * let container = new ParticleContainer();\n *\n * for (let i = 0; i < 100; ++i)\n * {\n * let sprite = PIXI.Sprite.from(\"myImage.png\");\n * container.addChild(sprite);\n * }\n * ```\n *\n * And here you have a hundred sprites that will be rendered at the speed of light.\n *\n * @memberof PIXI\n */\nvar ParticleContainer = /** @class */ (function (_super) {\n __extends(ParticleContainer, _super);\n /**\n * @param maxSize - The maximum number of particles that can be rendered by the container.\n * Affects size of allocated buffers.\n * @param properties - The properties of children that should be uploaded to the gpu and applied.\n * @param {boolean} [properties.vertices=false] - When true, vertices be uploaded and applied.\n * if sprite's ` scale/anchor/trim/frame/orig` is dynamic, please set `true`.\n * @param {boolean} [properties.position=true] - When true, position be uploaded and applied.\n * @param {boolean} [properties.rotation=false] - When true, rotation be uploaded and applied.\n * @param {boolean} [properties.uvs=false] - When true, uvs be uploaded and applied.\n * @param {boolean} [properties.tint=false] - When true, alpha and tint be uploaded and applied.\n * @param {number} [batchSize=16384] - Number of particles per batch. If less than maxSize, it uses maxSize instead.\n * @param {boolean} [autoResize=false] - If true, container allocates more batches in case\n * there are more than `maxSize` particles.\n */\n function ParticleContainer(maxSize, properties, batchSize, autoResize) {\n if (maxSize === void 0) { maxSize = 1500; }\n if (batchSize === void 0) { batchSize = 16384; }\n if (autoResize === void 0) { autoResize = false; }\n var _this = _super.call(this) || this;\n // Making sure the batch size is valid\n // 65535 is max vertex index in the index buffer (see ParticleRenderer)\n // so max number of particles is 65536 / 4 = 16384\n var maxBatchSize = 16384;\n if (batchSize > maxBatchSize) {\n batchSize = maxBatchSize;\n }\n _this._properties = [false, true, false, false, false];\n _this._maxSize = maxSize;\n _this._batchSize = batchSize;\n _this._buffers = null;\n _this._bufferUpdateIDs = [];\n _this._updateID = 0;\n _this.interactiveChildren = false;\n _this.blendMode = BLEND_MODES.NORMAL;\n _this.autoResize = autoResize;\n _this.roundPixels = true;\n _this.baseTexture = null;\n _this.setProperties(properties);\n _this._tint = 0;\n _this.tintRgb = new Float32Array(4);\n _this.tint = 0xFFFFFF;\n return _this;\n }\n /**\n * Sets the private properties array to dynamic / static based on the passed properties object\n *\n * @param properties - The properties to be uploaded\n */\n ParticleContainer.prototype.setProperties = function (properties) {\n if (properties) {\n this._properties[0] = 'vertices' in properties || 'scale' in properties\n ? !!properties.vertices || !!properties.scale : this._properties[0];\n this._properties[1] = 'position' in properties ? !!properties.position : this._properties[1];\n this._properties[2] = 'rotation' in properties ? !!properties.rotation : this._properties[2];\n this._properties[3] = 'uvs' in properties ? !!properties.uvs : this._properties[3];\n this._properties[4] = 'tint' in properties || 'alpha' in properties\n ? !!properties.tint || !!properties.alpha : this._properties[4];\n }\n };\n ParticleContainer.prototype.updateTransform = function () {\n // TODO don't need to!\n this.displayObjectUpdateTransform();\n };\n Object.defineProperty(ParticleContainer.prototype, \"tint\", {\n /**\n * The tint applied to the container. This is a hex value.\n * A value of 0xFFFFFF will remove any tint effect.\n * IMPORTANT: This is a WebGL only feature and will be ignored by the canvas renderer.\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n this._tint = value;\n hex2rgb(value, this.tintRgb);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Renders the container using the WebGL renderer.\n *\n * @param renderer - The WebGL renderer.\n */\n ParticleContainer.prototype.render = function (renderer) {\n var _this = this;\n if (!this.visible || this.worldAlpha <= 0 || !this.children.length || !this.renderable) {\n return;\n }\n if (!this.baseTexture) {\n this.baseTexture = this.children[0]._texture.baseTexture;\n if (!this.baseTexture.valid) {\n this.baseTexture.once('update', function () { return _this.onChildrenChange(0); });\n }\n }\n renderer.batch.setObjectRenderer(renderer.plugins.particle);\n renderer.plugins.particle.render(this);\n };\n /**\n * Set the flag that static data should be updated to true\n *\n * @param smallestChildIndex - The smallest child index.\n */\n ParticleContainer.prototype.onChildrenChange = function (smallestChildIndex) {\n var bufferIndex = Math.floor(smallestChildIndex / this._batchSize);\n while (this._bufferUpdateIDs.length < bufferIndex) {\n this._bufferUpdateIDs.push(0);\n }\n this._bufferUpdateIDs[bufferIndex] = ++this._updateID;\n };\n ParticleContainer.prototype.dispose = function () {\n if (this._buffers) {\n for (var i = 0; i < this._buffers.length; ++i) {\n this._buffers[i].destroy();\n }\n this._buffers = null;\n }\n };\n /**\n * Destroys the container\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their\n * destroy method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the texture of the child sprite\n * @param {boolean} [options.baseTexture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the base texture of the child sprite\n */\n ParticleContainer.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n this.dispose();\n this._properties = null;\n this._buffers = null;\n this._bufferUpdateIDs = null;\n };\n return ParticleContainer;\n}(Container));\n\n/*\n * @author Mat Groves\n *\n * Big thanks to the very clever Matt DesLauriers <mattdesl> https://github.com/mattdesl/\n * for creating the original PixiJS version!\n * Also a thanks to https://github.com/bchevalier for tweaking the tint and alpha so that\n * they now share 4 bytes on the vertex buffer\n *\n * Heavily inspired by LibGDX's ParticleBuffer:\n * https://github.com/libgdx/libgdx/blob/master/gdx/src/com/badlogic/gdx/graphics/g2d/ParticleBuffer.java\n */\n/**\n * The particle buffer manages the static and dynamic buffers for a particle container.\n *\n * @private\n * @memberof PIXI\n */\nvar ParticleBuffer = /** @class */ (function () {\n /**\n * @param {object} properties - The properties to upload.\n * @param {boolean[]} dynamicPropertyFlags - Flags for which properties are dynamic.\n * @param {number} size - The size of the batch.\n */\n function ParticleBuffer(properties, dynamicPropertyFlags, size) {\n this.geometry = new Geometry();\n this.indexBuffer = null;\n this.size = size;\n this.dynamicProperties = [];\n this.staticProperties = [];\n for (var i = 0; i < properties.length; ++i) {\n var property = properties[i];\n // Make copy of properties object so that when we edit the offset it doesn't\n // change all other instances of the object literal\n property = {\n attributeName: property.attributeName,\n size: property.size,\n uploadFunction: property.uploadFunction,\n type: property.type || TYPES.FLOAT,\n offset: property.offset,\n };\n if (dynamicPropertyFlags[i]) {\n this.dynamicProperties.push(property);\n }\n else {\n this.staticProperties.push(property);\n }\n }\n this.staticStride = 0;\n this.staticBuffer = null;\n this.staticData = null;\n this.staticDataUint32 = null;\n this.dynamicStride = 0;\n this.dynamicBuffer = null;\n this.dynamicData = null;\n this.dynamicDataUint32 = null;\n this._updateID = 0;\n this.initBuffers();\n }\n /** Sets up the renderer context and necessary buffers. */\n ParticleBuffer.prototype.initBuffers = function () {\n var geometry = this.geometry;\n var dynamicOffset = 0;\n this.indexBuffer = new Buffer(createIndicesForQuads(this.size), true, true);\n geometry.addIndex(this.indexBuffer);\n this.dynamicStride = 0;\n for (var i = 0; i < this.dynamicProperties.length; ++i) {\n var property = this.dynamicProperties[i];\n property.offset = dynamicOffset;\n dynamicOffset += property.size;\n this.dynamicStride += property.size;\n }\n var dynBuffer = new ArrayBuffer(this.size * this.dynamicStride * 4 * 4);\n this.dynamicData = new Float32Array(dynBuffer);\n this.dynamicDataUint32 = new Uint32Array(dynBuffer);\n this.dynamicBuffer = new Buffer(this.dynamicData, false, false);\n // static //\n var staticOffset = 0;\n this.staticStride = 0;\n for (var i = 0; i < this.staticProperties.length; ++i) {\n var property = this.staticProperties[i];\n property.offset = staticOffset;\n staticOffset += property.size;\n this.staticStride += property.size;\n }\n var statBuffer = new ArrayBuffer(this.size * this.staticStride * 4 * 4);\n this.staticData = new Float32Array(statBuffer);\n this.staticDataUint32 = new Uint32Array(statBuffer);\n this.staticBuffer = new Buffer(this.staticData, true, false);\n for (var i = 0; i < this.dynamicProperties.length; ++i) {\n var property = this.dynamicProperties[i];\n geometry.addAttribute(property.attributeName, this.dynamicBuffer, 0, property.type === TYPES.UNSIGNED_BYTE, property.type, this.dynamicStride * 4, property.offset * 4);\n }\n for (var i = 0; i < this.staticProperties.length; ++i) {\n var property = this.staticProperties[i];\n geometry.addAttribute(property.attributeName, this.staticBuffer, 0, property.type === TYPES.UNSIGNED_BYTE, property.type, this.staticStride * 4, property.offset * 4);\n }\n };\n /**\n * Uploads the dynamic properties.\n *\n * @param children - The children to upload.\n * @param startIndex - The index to start at.\n * @param amount - The number to upload.\n */\n ParticleBuffer.prototype.uploadDynamic = function (children, startIndex, amount) {\n for (var i = 0; i < this.dynamicProperties.length; i++) {\n var property = this.dynamicProperties[i];\n property.uploadFunction(children, startIndex, amount, property.type === TYPES.UNSIGNED_BYTE ? this.dynamicDataUint32 : this.dynamicData, this.dynamicStride, property.offset);\n }\n this.dynamicBuffer._updateID++;\n };\n /**\n * Uploads the static properties.\n *\n * @param children - The children to upload.\n * @param startIndex - The index to start at.\n * @param amount - The number to upload.\n */\n ParticleBuffer.prototype.uploadStatic = function (children, startIndex, amount) {\n for (var i = 0; i < this.staticProperties.length; i++) {\n var property = this.staticProperties[i];\n property.uploadFunction(children, startIndex, amount, property.type === TYPES.UNSIGNED_BYTE ? this.staticDataUint32 : this.staticData, this.staticStride, property.offset);\n }\n this.staticBuffer._updateID++;\n };\n /** Destroys the ParticleBuffer. */\n ParticleBuffer.prototype.destroy = function () {\n this.indexBuffer = null;\n this.dynamicProperties = null;\n this.dynamicBuffer = null;\n this.dynamicData = null;\n this.dynamicDataUint32 = null;\n this.staticProperties = null;\n this.staticBuffer = null;\n this.staticData = null;\n this.staticDataUint32 = null;\n // all buffers are destroyed inside geometry\n this.geometry.destroy();\n };\n return ParticleBuffer;\n}());\n\nvar fragment = \"varying vec2 vTextureCoord;\\nvarying vec4 vColor;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void){\\n vec4 color = texture2D(uSampler, vTextureCoord) * vColor;\\n gl_FragColor = color;\\n}\";\n\nvar vertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\nattribute vec4 aColor;\\n\\nattribute vec2 aPositionCoord;\\nattribute float aRotation;\\n\\nuniform mat3 translationMatrix;\\nuniform vec4 uColor;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec4 vColor;\\n\\nvoid main(void){\\n float x = (aVertexPosition.x) * cos(aRotation) - (aVertexPosition.y) * sin(aRotation);\\n float y = (aVertexPosition.x) * sin(aRotation) + (aVertexPosition.y) * cos(aRotation);\\n\\n vec2 v = vec2(x, y);\\n v = v + aPositionCoord;\\n\\n gl_Position = vec4((translationMatrix * vec3(v, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = aTextureCoord;\\n vColor = aColor * uColor;\\n}\\n\";\n\n/*\n * @author Mat Groves\n *\n * Big thanks to the very clever Matt DesLauriers <mattdesl> https://github.com/mattdesl/\n * for creating the original PixiJS version!\n * Also a thanks to https://github.com/bchevalier for tweaking the tint and alpha so that they now\n * share 4 bytes on the vertex buffer\n *\n * Heavily inspired by LibGDX's ParticleRenderer:\n * https://github.com/libgdx/libgdx/blob/master/gdx/src/com/badlogic/gdx/graphics/g2d/ParticleRenderer.java\n */\n/**\n * Renderer for Particles that is designer for speed over feature set.\n *\n * @memberof PIXI\n */\nvar ParticleRenderer = /** @class */ (function (_super) {\n __extends(ParticleRenderer, _super);\n /**\n * @param renderer - The renderer this sprite batch works for.\n */\n function ParticleRenderer(renderer) {\n var _this = _super.call(this, renderer) || this;\n // 65535 is max vertex index in the index buffer (see ParticleRenderer)\n // so max number of particles is 65536 / 4 = 16384\n // and max number of element in the index buffer is 16384 * 6 = 98304\n // Creating a full index buffer, overhead is 98304 * 2 = 196Ko\n // let numIndices = 98304;\n _this.shader = null;\n _this.properties = null;\n _this.tempMatrix = new Matrix();\n _this.properties = [\n // verticesData\n {\n attributeName: 'aVertexPosition',\n size: 2,\n uploadFunction: _this.uploadVertices,\n offset: 0,\n },\n // positionData\n {\n attributeName: 'aPositionCoord',\n size: 2,\n uploadFunction: _this.uploadPosition,\n offset: 0,\n },\n // rotationData\n {\n attributeName: 'aRotation',\n size: 1,\n uploadFunction: _this.uploadRotation,\n offset: 0,\n },\n // uvsData\n {\n attributeName: 'aTextureCoord',\n size: 2,\n uploadFunction: _this.uploadUvs,\n offset: 0,\n },\n // tintData\n {\n attributeName: 'aColor',\n size: 1,\n type: TYPES.UNSIGNED_BYTE,\n uploadFunction: _this.uploadTint,\n offset: 0,\n } ];\n _this.shader = Shader.from(vertex, fragment, {});\n _this.state = State.for2d();\n return _this;\n }\n /**\n * Renders the particle container object.\n *\n * @param container - The container to render using this ParticleRenderer.\n */\n ParticleRenderer.prototype.render = function (container) {\n var children = container.children;\n var maxSize = container._maxSize;\n var batchSize = container._batchSize;\n var renderer = this.renderer;\n var totalChildren = children.length;\n if (totalChildren === 0) {\n return;\n }\n else if (totalChildren > maxSize && !container.autoResize) {\n totalChildren = maxSize;\n }\n var buffers = container._buffers;\n if (!buffers) {\n buffers = container._buffers = this.generateBuffers(container);\n }\n var baseTexture = children[0]._texture.baseTexture;\n // if the uvs have not updated then no point rendering just yet!\n this.state.blendMode = correctBlendMode(container.blendMode, baseTexture.alphaMode);\n renderer.state.set(this.state);\n var gl = renderer.gl;\n var m = container.worldTransform.copyTo(this.tempMatrix);\n m.prepend(renderer.globalUniforms.uniforms.projectionMatrix);\n this.shader.uniforms.translationMatrix = m.toArray(true);\n this.shader.uniforms.uColor = premultiplyRgba(container.tintRgb, container.worldAlpha, this.shader.uniforms.uColor, baseTexture.alphaMode);\n this.shader.uniforms.uSampler = baseTexture;\n this.renderer.shader.bind(this.shader);\n var updateStatic = false;\n // now lets upload and render the buffers..\n for (var i = 0, j = 0; i < totalChildren; i += batchSize, j += 1) {\n var amount = (totalChildren - i);\n if (amount > batchSize) {\n amount = batchSize;\n }\n if (j >= buffers.length) {\n buffers.push(this._generateOneMoreBuffer(container));\n }\n var buffer = buffers[j];\n // we always upload the dynamic\n buffer.uploadDynamic(children, i, amount);\n var bid = container._bufferUpdateIDs[j] || 0;\n updateStatic = updateStatic || (buffer._updateID < bid);\n // we only upload the static content when we have to!\n if (updateStatic) {\n buffer._updateID = container._updateID;\n buffer.uploadStatic(children, i, amount);\n }\n // bind the buffer\n renderer.geometry.bind(buffer.geometry);\n gl.drawElements(gl.TRIANGLES, amount * 6, gl.UNSIGNED_SHORT, 0);\n }\n };\n /**\n * Creates one particle buffer for each child in the container we want to render and updates internal properties.\n *\n * @param container - The container to render using this ParticleRenderer\n * @return - The buffers\n */\n ParticleRenderer.prototype.generateBuffers = function (container) {\n var buffers = [];\n var size = container._maxSize;\n var batchSize = container._batchSize;\n var dynamicPropertyFlags = container._properties;\n for (var i = 0; i < size; i += batchSize) {\n buffers.push(new ParticleBuffer(this.properties, dynamicPropertyFlags, batchSize));\n }\n return buffers;\n };\n /**\n * Creates one more particle buffer, because container has autoResize feature.\n *\n * @param container - The container to render using this ParticleRenderer\n * @return - The generated buffer\n */\n ParticleRenderer.prototype._generateOneMoreBuffer = function (container) {\n var batchSize = container._batchSize;\n var dynamicPropertyFlags = container._properties;\n return new ParticleBuffer(this.properties, dynamicPropertyFlags, batchSize);\n };\n /**\n * Uploads the vertices.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their vertices uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadVertices = function (children, startIndex, amount, array, stride, offset) {\n var w0 = 0;\n var w1 = 0;\n var h0 = 0;\n var h1 = 0;\n for (var i = 0; i < amount; ++i) {\n var sprite = children[startIndex + i];\n var texture = sprite._texture;\n var sx = sprite.scale.x;\n var sy = sprite.scale.y;\n var trim = texture.trim;\n var orig = texture.orig;\n if (trim) {\n // if the sprite is trimmed and is not a tilingsprite then we need to add the\n // extra space before transforming the sprite coords..\n w1 = trim.x - (sprite.anchor.x * orig.width);\n w0 = w1 + trim.width;\n h1 = trim.y - (sprite.anchor.y * orig.height);\n h0 = h1 + trim.height;\n }\n else {\n w0 = (orig.width) * (1 - sprite.anchor.x);\n w1 = (orig.width) * -sprite.anchor.x;\n h0 = orig.height * (1 - sprite.anchor.y);\n h1 = orig.height * -sprite.anchor.y;\n }\n array[offset] = w1 * sx;\n array[offset + 1] = h1 * sy;\n array[offset + stride] = w0 * sx;\n array[offset + stride + 1] = h1 * sy;\n array[offset + (stride * 2)] = w0 * sx;\n array[offset + (stride * 2) + 1] = h0 * sy;\n array[offset + (stride * 3)] = w1 * sx;\n array[offset + (stride * 3) + 1] = h0 * sy;\n offset += stride * 4;\n }\n };\n /**\n * Uploads the position.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their positions uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadPosition = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; i++) {\n var spritePosition = children[startIndex + i].position;\n array[offset] = spritePosition.x;\n array[offset + 1] = spritePosition.y;\n array[offset + stride] = spritePosition.x;\n array[offset + stride + 1] = spritePosition.y;\n array[offset + (stride * 2)] = spritePosition.x;\n array[offset + (stride * 2) + 1] = spritePosition.y;\n array[offset + (stride * 3)] = spritePosition.x;\n array[offset + (stride * 3) + 1] = spritePosition.y;\n offset += stride * 4;\n }\n };\n /**\n * Uploads the rotation.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their rotation uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadRotation = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; i++) {\n var spriteRotation = children[startIndex + i].rotation;\n array[offset] = spriteRotation;\n array[offset + stride] = spriteRotation;\n array[offset + (stride * 2)] = spriteRotation;\n array[offset + (stride * 3)] = spriteRotation;\n offset += stride * 4;\n }\n };\n /**\n * Uploads the UVs.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their rotation uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadUvs = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; ++i) {\n var textureUvs = children[startIndex + i]._texture._uvs;\n if (textureUvs) {\n array[offset] = textureUvs.x0;\n array[offset + 1] = textureUvs.y0;\n array[offset + stride] = textureUvs.x1;\n array[offset + stride + 1] = textureUvs.y1;\n array[offset + (stride * 2)] = textureUvs.x2;\n array[offset + (stride * 2) + 1] = textureUvs.y2;\n array[offset + (stride * 3)] = textureUvs.x3;\n array[offset + (stride * 3) + 1] = textureUvs.y3;\n offset += stride * 4;\n }\n else {\n // TODO you know this can be easier!\n array[offset] = 0;\n array[offset + 1] = 0;\n array[offset + stride] = 0;\n array[offset + stride + 1] = 0;\n array[offset + (stride * 2)] = 0;\n array[offset + (stride * 2) + 1] = 0;\n array[offset + (stride * 3)] = 0;\n array[offset + (stride * 3) + 1] = 0;\n offset += stride * 4;\n }\n }\n };\n /**\n * Uploads the tint.\n *\n * @param children - the array of display objects to render\n * @param startIndex - the index to start from in the children array\n * @param amount - the amount of children that will have their rotation uploaded\n * @param array - The vertices to upload.\n * @param stride - Stride to use for iteration.\n * @param offset - Offset to start at.\n */\n ParticleRenderer.prototype.uploadTint = function (children, startIndex, amount, array, stride, offset) {\n for (var i = 0; i < amount; ++i) {\n var sprite = children[startIndex + i];\n var premultiplied = sprite._texture.baseTexture.alphaMode > 0;\n var alpha = sprite.alpha;\n // we dont call extra function if alpha is 1.0, that's faster\n var argb = alpha < 1.0 && premultiplied\n ? premultiplyTint(sprite._tintRGB, alpha) : sprite._tintRGB + (alpha * 255 << 24);\n array[offset] = argb;\n array[offset + stride] = argb;\n array[offset + (stride * 2)] = argb;\n array[offset + (stride * 3)] = argb;\n offset += stride * 4;\n }\n };\n /** Destroys the ParticleRenderer. */\n ParticleRenderer.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n if (this.shader) {\n this.shader.destroy();\n this.shader = null;\n }\n this.tempMatrix = null;\n };\n return ParticleRenderer;\n}(ObjectRenderer));\n\nexport { ParticleContainer, ParticleRenderer };\n//# sourceMappingURL=particle-container.js.map\n","/*!\n * @pixi/graphics - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/graphics is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture, BaseTexture, BatchDrawCall, BatchTextureArray, BatchGeometry, UniformGroup, Shader, State } from '@pixi/core';\nimport { SHAPES, Point, PI_2, Matrix, Polygon, Rectangle, RoundedRectangle, Circle, Ellipse } from '@pixi/math';\nimport { earcut, premultiplyTint, hex2rgb } from '@pixi/utils';\nimport { WRAP_MODES, DRAW_MODES, BLEND_MODES } from '@pixi/constants';\nimport { Bounds, Container } from '@pixi/display';\n\n/**\n * Supported line joints in `PIXI.LineStyle` for graphics.\n *\n * @see PIXI.Graphics#lineStyle\n * @see https://graphicdesign.stackexchange.com/questions/59018/what-is-a-bevel-join-of-two-lines-exactly-illustrator\n *\n * @name LINE_JOIN\n * @memberof PIXI\n * @static\n * @enum {string}\n * @property {string} MITER - 'miter': make a sharp corner where outer part of lines meet\n * @property {string} BEVEL - 'bevel': add a square butt at each end of line segment and fill the triangle at turn\n * @property {string} ROUND - 'round': add an arc at the joint\n */\nvar LINE_JOIN;\n(function (LINE_JOIN) {\n LINE_JOIN[\"MITER\"] = \"miter\";\n LINE_JOIN[\"BEVEL\"] = \"bevel\";\n LINE_JOIN[\"ROUND\"] = \"round\";\n})(LINE_JOIN || (LINE_JOIN = {}));\n/**\n * Support line caps in `PIXI.LineStyle` for graphics.\n *\n * @see PIXI.Graphics#lineStyle\n *\n * @name LINE_CAP\n * @memberof PIXI\n * @static\n * @enum {string}\n * @property {string} BUTT - 'butt': don't add any cap at line ends (leaves orthogonal edges)\n * @property {string} ROUND - 'round': add semicircle at ends\n * @property {string} SQUARE - 'square': add square at end (like `BUTT` except more length at end)\n */\nvar LINE_CAP;\n(function (LINE_CAP) {\n LINE_CAP[\"BUTT\"] = \"butt\";\n LINE_CAP[\"ROUND\"] = \"round\";\n LINE_CAP[\"SQUARE\"] = \"square\";\n})(LINE_CAP || (LINE_CAP = {}));\n/**\n * Graphics curves resolution settings. If `adaptive` flag is set to `true`,\n * the resolution is calculated based on the curve's length to ensure better visual quality.\n * Adaptive draw works with `bezierCurveTo` and `quadraticCurveTo`.\n *\n * @static\n * @constant\n * @memberof PIXI\n * @name GRAPHICS_CURVES\n * @type {object}\n * @property {boolean} adaptive=true - flag indicating if the resolution should be adaptive\n * @property {number} maxLength=10 - maximal length of a single segment of the curve (if adaptive = false, ignored)\n * @property {number} minSegments=8 - minimal number of segments in the curve (if adaptive = false, ignored)\n * @property {number} maxSegments=2048 - maximal number of segments in the curve (if adaptive = false, ignored)\n */\nvar GRAPHICS_CURVES = {\n adaptive: true,\n maxLength: 10,\n minSegments: 8,\n maxSegments: 2048,\n epsilon: 0.0001,\n _segmentsCount: function (length, defaultSegments) {\n if (defaultSegments === void 0) { defaultSegments = 20; }\n if (!this.adaptive || !length || isNaN(length)) {\n return defaultSegments;\n }\n var result = Math.ceil(length / this.maxLength);\n if (result < this.minSegments) {\n result = this.minSegments;\n }\n else if (result > this.maxSegments) {\n result = this.maxSegments;\n }\n return result;\n },\n};\n\n/**\n * Fill style object for Graphics.\n *\n * @memberof PIXI\n */\nvar FillStyle = /** @class */ (function () {\n function FillStyle() {\n /**\n * The hex color value used when coloring the Graphics object.\n *\n * @default 0xFFFFFF\n */\n this.color = 0xFFFFFF;\n /** The alpha value used when filling the Graphics object. */\n this.alpha = 1.0;\n /**\n * The texture to be used for the fill.\n *\n * @default 0\n */\n this.texture = Texture.WHITE;\n /**\n * The transform applied to the texture.\n *\n * @default null\n */\n this.matrix = null;\n /** If the current fill is visible. */\n this.visible = false;\n this.reset();\n }\n /** Clones the object */\n FillStyle.prototype.clone = function () {\n var obj = new FillStyle();\n obj.color = this.color;\n obj.alpha = this.alpha;\n obj.texture = this.texture;\n obj.matrix = this.matrix;\n obj.visible = this.visible;\n return obj;\n };\n /** Reset */\n FillStyle.prototype.reset = function () {\n this.color = 0xFFFFFF;\n this.alpha = 1;\n this.texture = Texture.WHITE;\n this.matrix = null;\n this.visible = false;\n };\n /** Destroy and don't use after this. */\n FillStyle.prototype.destroy = function () {\n this.texture = null;\n this.matrix = null;\n };\n return FillStyle;\n}());\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nfunction fixOrientation(points, hole) {\n var _a, _b;\n if (hole === void 0) { hole = false; }\n var m = points.length;\n if (m < 6) {\n return;\n }\n var area = 0;\n for (var i = 0, x1 = points[m - 2], y1 = points[m - 1]; i < m; i += 2) {\n var x2 = points[i];\n var y2 = points[i + 1];\n area += (x2 - x1) * (y2 + y1);\n x1 = x2;\n y1 = y2;\n }\n if ((!hole && area > 0) || (hole && area <= 0)) {\n var n = m / 2;\n for (var i = n + (n % 2); i < m; i += 2) {\n var i1 = m - i - 2;\n var i2 = m - i - 1;\n var i3 = i;\n var i4 = i + 1;\n _a = [points[i3], points[i1]], points[i1] = _a[0], points[i3] = _a[1];\n _b = [points[i4], points[i2]], points[i2] = _b[0], points[i4] = _b[1];\n }\n }\n}\n/**\n * Builds a polygon to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildPoly = {\n build: function (graphicsData) {\n graphicsData.points = graphicsData.shape.points.slice();\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n var points = graphicsData.points;\n var holes = graphicsData.holes;\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n if (points.length >= 6) {\n fixOrientation(points, false);\n var holeArray = [];\n // Process holes..\n for (var i = 0; i < holes.length; i++) {\n var hole = holes[i];\n fixOrientation(hole.points, true);\n holeArray.push(points.length / 2);\n points = points.concat(hole.points);\n }\n // sort color\n var triangles = earcut(points, holeArray, 2);\n if (!triangles) {\n return;\n }\n var vertPos = verts.length / 2;\n for (var i = 0; i < triangles.length; i += 3) {\n indices.push(triangles[i] + vertPos);\n indices.push(triangles[i + 1] + vertPos);\n indices.push(triangles[i + 2] + vertPos);\n }\n for (var i = 0; i < points.length; i++) {\n verts.push(points[i]);\n }\n }\n },\n};\n\n// for type only\n/**\n * Builds a circle to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object to draw\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildCircle = {\n build: function (graphicsData) {\n // need to convert points to a nice regular data\n var points = graphicsData.points;\n var x;\n var y;\n var dx;\n var dy;\n var rx;\n var ry;\n if (graphicsData.type === SHAPES.CIRC) {\n var circle = graphicsData.shape;\n x = circle.x;\n y = circle.y;\n rx = ry = circle.radius;\n dx = dy = 0;\n }\n else if (graphicsData.type === SHAPES.ELIP) {\n var ellipse = graphicsData.shape;\n x = ellipse.x;\n y = ellipse.y;\n rx = ellipse.width;\n ry = ellipse.height;\n dx = dy = 0;\n }\n else {\n var roundedRect = graphicsData.shape;\n var halfWidth = roundedRect.width / 2;\n var halfHeight = roundedRect.height / 2;\n x = roundedRect.x + halfWidth;\n y = roundedRect.y + halfHeight;\n rx = ry = Math.max(0, Math.min(roundedRect.radius, Math.min(halfWidth, halfHeight)));\n dx = halfWidth - rx;\n dy = halfHeight - ry;\n }\n // Choose a number of segments such that the maximum absolute deviation from the circle is approximately 0.029\n var n = Math.ceil(2.3 * Math.sqrt(rx + ry));\n var m = (n * 8) + (dx ? 4 : 0) + (dy ? 4 : 0);\n points.length = m;\n if (m === 0) {\n return;\n }\n if (n === 0) {\n points.length = 8;\n points[0] = points[6] = x + dx;\n points[1] = points[3] = y + dy;\n points[2] = points[4] = x - dx;\n points[5] = points[7] = y - dy;\n return;\n }\n var j1 = 0;\n var j2 = (n * 4) + (dx ? 2 : 0) + 2;\n var j3 = j2;\n var j4 = m;\n {\n var x0 = dx + rx;\n var y0 = dy;\n var x1 = x + x0;\n var x2 = x - x0;\n var y1 = y + y0;\n points[j1++] = x1;\n points[j1++] = y1;\n points[--j2] = y1;\n points[--j2] = x2;\n if (dy) {\n var y2 = y - y0;\n points[j3++] = x2;\n points[j3++] = y2;\n points[--j4] = y2;\n points[--j4] = x1;\n }\n }\n for (var i = 1; i < n; i++) {\n var a = Math.PI / 2 * (i / n);\n var x0 = dx + (Math.cos(a) * rx);\n var y0 = dy + (Math.sin(a) * ry);\n var x1 = x + x0;\n var x2 = x - x0;\n var y1 = y + y0;\n var y2 = y - y0;\n points[j1++] = x1;\n points[j1++] = y1;\n points[--j2] = y1;\n points[--j2] = x2;\n points[j3++] = x2;\n points[j3++] = y2;\n points[--j4] = y2;\n points[--j4] = x1;\n }\n {\n var x0 = dx;\n var y0 = dy + ry;\n var x1 = x + x0;\n var x2 = x - x0;\n var y1 = y + y0;\n var y2 = y - y0;\n points[j1++] = x1;\n points[j1++] = y1;\n points[--j4] = y2;\n points[--j4] = x1;\n if (dx) {\n points[j1++] = x2;\n points[j1++] = y1;\n points[--j4] = y2;\n points[--j4] = x2;\n }\n }\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n var points = graphicsData.points;\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n var vertPos = verts.length / 2;\n var center = vertPos;\n var x;\n var y;\n if (graphicsData.type !== SHAPES.RREC) {\n var circle = graphicsData.shape;\n x = circle.x;\n y = circle.y;\n }\n else {\n var roundedRect = graphicsData.shape;\n x = roundedRect.x + (roundedRect.width / 2);\n y = roundedRect.y + (roundedRect.height / 2);\n }\n var matrix = graphicsData.matrix;\n // Push center (special point)\n verts.push(graphicsData.matrix ? (matrix.a * x) + (matrix.c * y) + matrix.tx : x, graphicsData.matrix ? (matrix.b * x) + (matrix.d * y) + matrix.ty : y);\n vertPos++;\n verts.push(points[0], points[1]);\n for (var i = 2; i < points.length; i += 2) {\n verts.push(points[i], points[i + 1]);\n // add some uvs\n indices.push(vertPos++, center, vertPos);\n }\n indices.push(center + 1, center, vertPos);\n },\n};\n\n/**\n * Builds a rectangle to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildRectangle = {\n build: function (graphicsData) {\n // --- //\n // need to convert points to a nice regular data\n //\n var rectData = graphicsData.shape;\n var x = rectData.x;\n var y = rectData.y;\n var width = rectData.width;\n var height = rectData.height;\n var points = graphicsData.points;\n points.length = 0;\n points.push(x, y, x + width, y, x + width, y + height, x, y + height);\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n var points = graphicsData.points;\n var verts = graphicsGeometry.points;\n var vertPos = verts.length / 2;\n verts.push(points[0], points[1], points[2], points[3], points[6], points[7], points[4], points[5]);\n graphicsGeometry.indices.push(vertPos, vertPos + 1, vertPos + 2, vertPos + 1, vertPos + 2, vertPos + 3);\n },\n};\n\n/**\n * Calculate a single point for a quadratic bezier curve.\n * Utility function used by quadraticBezierCurve.\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} n1 - first number\n * @param {number} n2 - second number\n * @param {number} perc - percentage\n * @return {number} the result\n *\n */\nfunction getPt(n1, n2, perc) {\n var diff = n2 - n1;\n return n1 + (diff * perc);\n}\n/**\n * Calculate the points for a quadratic bezier curve. (helper function..)\n * Based on: https://stackoverflow.com/questions/785097/how-do-i-implement-a-bezier-curve-in-c\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} fromX - Origin point x\n * @param {number} fromY - Origin point x\n * @param {number} cpX - Control point x\n * @param {number} cpY - Control point y\n * @param {number} toX - Destination point x\n * @param {number} toY - Destination point y\n * @param {number[]} [out=[]] - The output array to add points into. If not passed, a new array is created.\n * @return {number[]} an array of points\n */\nfunction quadraticBezierCurve(fromX, fromY, cpX, cpY, toX, toY, out) {\n if (out === void 0) { out = []; }\n var n = 20;\n var points = out;\n var xa = 0;\n var ya = 0;\n var xb = 0;\n var yb = 0;\n var x = 0;\n var y = 0;\n for (var i = 0, j = 0; i <= n; ++i) {\n j = i / n;\n // The Green Line\n xa = getPt(fromX, cpX, j);\n ya = getPt(fromY, cpY, j);\n xb = getPt(cpX, toX, j);\n yb = getPt(cpY, toY, j);\n // The Black Dot\n x = getPt(xa, xb, j);\n y = getPt(ya, yb, j);\n // Handle case when first curve points overlaps and earcut fails to triangulate\n if (i === 0 && points[points.length - 2] === x && points[points.length - 1] === y) {\n continue;\n }\n points.push(x, y);\n }\n return points;\n}\n/**\n * Builds a rounded rectangle to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.WebGLGraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {object} webGLData - an object containing all the WebGL-specific information to create this shape\n * @param {object} webGLDataNativeLines - an object containing all the WebGL-specific information to create nativeLines\n */\nvar buildRoundedRectangle = {\n build: function (graphicsData) {\n if (Graphics.nextRoundedRectBehavior) {\n buildCircle.build(graphicsData);\n return;\n }\n var rrectData = graphicsData.shape;\n var points = graphicsData.points;\n var x = rrectData.x;\n var y = rrectData.y;\n var width = rrectData.width;\n var height = rrectData.height;\n // Don't allow negative radius or greater than half the smallest width\n var radius = Math.max(0, Math.min(rrectData.radius, Math.min(width, height) / 2));\n points.length = 0;\n // No radius, do a simple rectangle\n if (!radius) {\n points.push(x, y, x + width, y, x + width, y + height, x, y + height);\n }\n else {\n quadraticBezierCurve(x, y + radius, x, y, x + radius, y, points);\n quadraticBezierCurve(x + width - radius, y, x + width, y, x + width, y + radius, points);\n quadraticBezierCurve(x + width, y + height - radius, x + width, y + height, x + width - radius, y + height, points);\n quadraticBezierCurve(x + radius, y + height, x, y + height, x, y + height - radius, points);\n }\n },\n triangulate: function (graphicsData, graphicsGeometry) {\n if (Graphics.nextRoundedRectBehavior) {\n buildCircle.triangulate(graphicsData, graphicsGeometry);\n return;\n }\n var points = graphicsData.points;\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n var vecPos = verts.length / 2;\n var triangles = earcut(points, null, 2);\n for (var i = 0, j = triangles.length; i < j; i += 3) {\n indices.push(triangles[i] + vecPos);\n // indices.push(triangles[i] + vecPos);\n indices.push(triangles[i + 1] + vecPos);\n // indices.push(triangles[i + 2] + vecPos);\n indices.push(triangles[i + 2] + vecPos);\n }\n for (var i = 0, j = points.length; i < j; i++) {\n verts.push(points[i], points[++i]);\n }\n },\n};\n\n/**\n * Buffers vertices to draw a square cap.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} x - X-coord of end point\n * @param {number} y - Y-coord of end point\n * @param {number} nx - X-coord of line normal pointing inside\n * @param {number} ny - Y-coord of line normal pointing inside\n * @param {Array<number>} verts - vertex buffer\n * @returns {}\n */\nfunction square(x, y, nx, ny, innerWeight, outerWeight, clockwise, /* rotation for square (true at left end, false at right end) */ verts) {\n var ix = x - (nx * innerWeight);\n var iy = y - (ny * innerWeight);\n var ox = x + (nx * outerWeight);\n var oy = y + (ny * outerWeight);\n /* Rotate nx,ny for extension vector */\n var exx;\n var eyy;\n if (clockwise) {\n exx = ny;\n eyy = -nx;\n }\n else {\n exx = -ny;\n eyy = nx;\n }\n /* [i|0]x,y extended at cap */\n var eix = ix + exx;\n var eiy = iy + eyy;\n var eox = ox + exx;\n var eoy = oy + eyy;\n /* Square itself must be inserted clockwise*/\n verts.push(eix, eiy);\n verts.push(eox, eoy);\n return 2;\n}\n/**\n * Buffers vertices to draw an arc at the line joint or cap.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {number} cx - X-coord of center\n * @param {number} cy - Y-coord of center\n * @param {number} sx - X-coord of arc start\n * @param {number} sy - Y-coord of arc start\n * @param {number} ex - X-coord of arc end\n * @param {number} ey - Y-coord of arc end\n * @param {Array<number>} verts - buffer of vertices\n * @param {boolean} clockwise - orientation of vertices\n * @returns {number} - no. of vertices pushed\n */\nfunction round(cx, cy, sx, sy, ex, ey, verts, clockwise) {\n var cx2p0x = sx - cx;\n var cy2p0y = sy - cy;\n var angle0 = Math.atan2(cx2p0x, cy2p0y);\n var angle1 = Math.atan2(ex - cx, ey - cy);\n if (clockwise && angle0 < angle1) {\n angle0 += Math.PI * 2;\n }\n else if (!clockwise && angle0 > angle1) {\n angle1 += Math.PI * 2;\n }\n var startAngle = angle0;\n var angleDiff = angle1 - angle0;\n var absAngleDiff = Math.abs(angleDiff);\n /* if (absAngleDiff >= PI_LBOUND && absAngleDiff <= PI_UBOUND)\n {\n const r1x = cx - nxtPx;\n const r1y = cy - nxtPy;\n\n if (r1x === 0)\n {\n if (r1y > 0)\n {\n angleDiff = -angleDiff;\n }\n }\n else if (r1x >= -GRAPHICS_CURVES.epsilon)\n {\n angleDiff = -angleDiff;\n }\n }*/\n var radius = Math.sqrt((cx2p0x * cx2p0x) + (cy2p0y * cy2p0y));\n var segCount = ((15 * absAngleDiff * Math.sqrt(radius) / Math.PI) >> 0) + 1;\n var angleInc = angleDiff / segCount;\n startAngle += angleInc;\n if (clockwise) {\n verts.push(cx, cy);\n verts.push(sx, sy);\n for (var i = 1, angle = startAngle; i < segCount; i++, angle += angleInc) {\n verts.push(cx, cy);\n verts.push(cx + ((Math.sin(angle) * radius)), cy + ((Math.cos(angle) * radius)));\n }\n verts.push(cx, cy);\n verts.push(ex, ey);\n }\n else {\n verts.push(sx, sy);\n verts.push(cx, cy);\n for (var i = 1, angle = startAngle; i < segCount; i++, angle += angleInc) {\n verts.push(cx + ((Math.sin(angle) * radius)), cy + ((Math.cos(angle) * radius)));\n verts.push(cx, cy);\n }\n verts.push(ex, ey);\n verts.push(cx, cy);\n }\n return segCount * 2;\n}\n/**\n * Builds a line to draw using the polygon method.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.GraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {PIXI.GraphicsGeometry} graphicsGeometry - Geometry where to append output\n */\nfunction buildNonNativeLine(graphicsData, graphicsGeometry) {\n var shape = graphicsData.shape;\n var points = graphicsData.points || shape.points.slice();\n var eps = graphicsGeometry.closePointEps;\n if (points.length === 0) {\n return;\n }\n // if the line width is an odd number add 0.5 to align to a whole pixel\n // commenting this out fixes #711 and #1620\n // if (graphicsData.lineWidth%2)\n // {\n // for (i = 0; i < points.length; i++)\n // {\n // points[i] += 0.5;\n // }\n // }\n var style = graphicsData.lineStyle;\n // get first and last point.. figure out the middle!\n var firstPoint = new Point(points[0], points[1]);\n var lastPoint = new Point(points[points.length - 2], points[points.length - 1]);\n var closedShape = shape.type !== SHAPES.POLY || shape.closeStroke;\n var closedPath = Math.abs(firstPoint.x - lastPoint.x) < eps\n && Math.abs(firstPoint.y - lastPoint.y) < eps;\n // if the first point is the last point - gonna have issues :)\n if (closedShape) {\n // need to clone as we are going to slightly modify the shape..\n points = points.slice();\n if (closedPath) {\n points.pop();\n points.pop();\n lastPoint.set(points[points.length - 2], points[points.length - 1]);\n }\n var midPointX = (firstPoint.x + lastPoint.x) * 0.5;\n var midPointY = (lastPoint.y + firstPoint.y) * 0.5;\n points.unshift(midPointX, midPointY);\n points.push(midPointX, midPointY);\n }\n var verts = graphicsGeometry.points;\n var length = points.length / 2;\n var indexCount = points.length;\n var indexStart = verts.length / 2;\n // Max. inner and outer width\n var width = style.width / 2;\n var widthSquared = width * width;\n var miterLimitSquared = style.miterLimit * style.miterLimit;\n /* Line segments of interest where (x1,y1) forms the corner. */\n var x0 = points[0];\n var y0 = points[1];\n var x1 = points[2];\n var y1 = points[3];\n var x2 = 0;\n var y2 = 0;\n /* perp[?](x|y) = the line normal with magnitude lineWidth. */\n var perpx = -(y0 - y1);\n var perpy = x0 - x1;\n var perp1x = 0;\n var perp1y = 0;\n var dist = Math.sqrt((perpx * perpx) + (perpy * perpy));\n perpx /= dist;\n perpy /= dist;\n perpx *= width;\n perpy *= width;\n var ratio = style.alignment; // 0.5;\n var innerWeight = (1 - ratio) * 2;\n var outerWeight = ratio * 2;\n if (!closedShape) {\n if (style.cap === LINE_CAP.ROUND) {\n indexCount += round(x0 - (perpx * (innerWeight - outerWeight) * 0.5), y0 - (perpy * (innerWeight - outerWeight) * 0.5), x0 - (perpx * innerWeight), y0 - (perpy * innerWeight), x0 + (perpx * outerWeight), y0 + (perpy * outerWeight), verts, true) + 2;\n }\n else if (style.cap === LINE_CAP.SQUARE) {\n indexCount += square(x0, y0, perpx, perpy, innerWeight, outerWeight, true, verts);\n }\n }\n // Push first point (below & above vertices)\n verts.push(x0 - (perpx * innerWeight), y0 - (perpy * innerWeight));\n verts.push(x0 + (perpx * outerWeight), y0 + (perpy * outerWeight));\n for (var i = 1; i < length - 1; ++i) {\n x0 = points[(i - 1) * 2];\n y0 = points[((i - 1) * 2) + 1];\n x1 = points[i * 2];\n y1 = points[(i * 2) + 1];\n x2 = points[(i + 1) * 2];\n y2 = points[((i + 1) * 2) + 1];\n perpx = -(y0 - y1);\n perpy = x0 - x1;\n dist = Math.sqrt((perpx * perpx) + (perpy * perpy));\n perpx /= dist;\n perpy /= dist;\n perpx *= width;\n perpy *= width;\n perp1x = -(y1 - y2);\n perp1y = x1 - x2;\n dist = Math.sqrt((perp1x * perp1x) + (perp1y * perp1y));\n perp1x /= dist;\n perp1y /= dist;\n perp1x *= width;\n perp1y *= width;\n /* d[x|y](0|1) = the component displacement between points p(0,1|1,2) */\n var dx0 = x1 - x0;\n var dy0 = y0 - y1;\n var dx1 = x1 - x2;\n var dy1 = y2 - y1;\n /* +ve if internal angle counterclockwise, -ve if internal angle clockwise. */\n var cross = (dy0 * dx1) - (dy1 * dx0);\n var clockwise = (cross < 0);\n /* Going nearly straight? */\n if (Math.abs(cross) < 0.1) {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight));\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight));\n continue;\n }\n /* p[x|y] is the miter point. pdist is the distance between miter point and p1. */\n var c1 = ((-perpx + x0) * (-perpy + y1)) - ((-perpx + x1) * (-perpy + y0));\n var c2 = ((-perp1x + x2) * (-perp1y + y1)) - ((-perp1x + x1) * (-perp1y + y2));\n var px = ((dx0 * c2) - (dx1 * c1)) / cross;\n var py = ((dy1 * c1) - (dy0 * c2)) / cross;\n var pdist = ((px - x1) * (px - x1)) + ((py - y1) * (py - y1));\n /* Inner miter point */\n var imx = x1 + ((px - x1) * innerWeight);\n var imy = y1 + ((py - y1) * innerWeight);\n /* Outer miter point */\n var omx = x1 - ((px - x1) * outerWeight);\n var omy = y1 - ((py - y1) * outerWeight);\n /* Is the inside miter point too far away, creating a spike? */\n var smallerInsideSegmentSq = Math.min((dx0 * dx0) + (dy0 * dy0), (dx1 * dx1) + (dy1 * dy1));\n var insideWeight = clockwise ? innerWeight : outerWeight;\n var smallerInsideDiagonalSq = smallerInsideSegmentSq + (insideWeight * insideWeight * widthSquared);\n var insideMiterOk = pdist <= smallerInsideDiagonalSq;\n if (insideMiterOk) {\n if (style.join === LINE_JOIN.BEVEL || pdist / widthSquared > miterLimitSquared) {\n if (clockwise) /* rotating at inner angle */ {\n verts.push(imx, imy); // inner miter point\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight)); // first segment's outer vertex\n verts.push(imx, imy); // inner miter point\n verts.push(x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight)); // second segment's outer vertex\n }\n else /* rotating at outer angle */ {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight)); // first segment's inner vertex\n verts.push(omx, omy); // outer miter point\n verts.push(x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight)); // second segment's outer vertex\n verts.push(omx, omy); // outer miter point\n }\n indexCount += 2;\n }\n else if (style.join === LINE_JOIN.ROUND) {\n if (clockwise) /* arc is outside */ {\n verts.push(imx, imy);\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight));\n indexCount += round(x1, y1, x1 + (perpx * outerWeight), y1 + (perpy * outerWeight), x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight), verts, true) + 4;\n verts.push(imx, imy);\n verts.push(x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight));\n }\n else /* arc is inside */ {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight));\n verts.push(omx, omy);\n indexCount += round(x1, y1, x1 - (perpx * innerWeight), y1 - (perpy * innerWeight), x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight), verts, false) + 4;\n verts.push(x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight));\n verts.push(omx, omy);\n }\n }\n else {\n verts.push(imx, imy);\n verts.push(omx, omy);\n }\n }\n else // inside miter is NOT ok\n {\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight)); // first segment's inner vertex\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight)); // first segment's outer vertex\n if (style.join === LINE_JOIN.BEVEL || pdist / widthSquared > miterLimitSquared) ;\n else if (style.join === LINE_JOIN.ROUND) {\n if (clockwise) /* arc is outside */ {\n indexCount += round(x1, y1, x1 + (perpx * outerWeight), y1 + (perpy * outerWeight), x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight), verts, true) + 2;\n }\n else /* arc is inside */ {\n indexCount += round(x1, y1, x1 - (perpx * innerWeight), y1 - (perpy * innerWeight), x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight), verts, false) + 2;\n }\n }\n else {\n if (clockwise) {\n verts.push(omx, omy); // inner miter point\n verts.push(omx, omy); // inner miter point\n }\n else {\n verts.push(imx, imy); // outer miter point\n verts.push(imx, imy); // outer miter point\n }\n indexCount += 2;\n }\n verts.push(x1 - (perp1x * innerWeight), y1 - (perp1y * innerWeight)); // second segment's inner vertex\n verts.push(x1 + (perp1x * outerWeight), y1 + (perp1y * outerWeight)); // second segment's outer vertex\n indexCount += 2;\n }\n }\n x0 = points[(length - 2) * 2];\n y0 = points[((length - 2) * 2) + 1];\n x1 = points[(length - 1) * 2];\n y1 = points[((length - 1) * 2) + 1];\n perpx = -(y0 - y1);\n perpy = x0 - x1;\n dist = Math.sqrt((perpx * perpx) + (perpy * perpy));\n perpx /= dist;\n perpy /= dist;\n perpx *= width;\n perpy *= width;\n verts.push(x1 - (perpx * innerWeight), y1 - (perpy * innerWeight));\n verts.push(x1 + (perpx * outerWeight), y1 + (perpy * outerWeight));\n if (!closedShape) {\n if (style.cap === LINE_CAP.ROUND) {\n indexCount += round(x1 - (perpx * (innerWeight - outerWeight) * 0.5), y1 - (perpy * (innerWeight - outerWeight) * 0.5), x1 - (perpx * innerWeight), y1 - (perpy * innerWeight), x1 + (perpx * outerWeight), y1 + (perpy * outerWeight), verts, false) + 2;\n }\n else if (style.cap === LINE_CAP.SQUARE) {\n indexCount += square(x1, y1, perpx, perpy, innerWeight, outerWeight, false, verts);\n }\n }\n var indices = graphicsGeometry.indices;\n var eps2 = GRAPHICS_CURVES.epsilon * GRAPHICS_CURVES.epsilon;\n // indices.push(indexStart);\n for (var i = indexStart; i < indexCount + indexStart - 2; ++i) {\n x0 = verts[(i * 2)];\n y0 = verts[(i * 2) + 1];\n x1 = verts[(i + 1) * 2];\n y1 = verts[((i + 1) * 2) + 1];\n x2 = verts[(i + 2) * 2];\n y2 = verts[((i + 2) * 2) + 1];\n /* Skip zero area triangles */\n if (Math.abs((x0 * (y1 - y2)) + (x1 * (y2 - y0)) + (x2 * (y0 - y1))) < eps2) {\n continue;\n }\n indices.push(i, i + 1, i + 2);\n }\n}\n/**\n * Builds a line to draw using the gl.drawArrays(gl.LINES) method\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.GraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {PIXI.GraphicsGeometry} graphicsGeometry - Geometry where to append output\n */\nfunction buildNativeLine(graphicsData, graphicsGeometry) {\n var i = 0;\n var shape = graphicsData.shape;\n var points = graphicsData.points || shape.points;\n var closedShape = shape.type !== SHAPES.POLY || shape.closeStroke;\n if (points.length === 0)\n { return; }\n var verts = graphicsGeometry.points;\n var indices = graphicsGeometry.indices;\n var length = points.length / 2;\n var startIndex = verts.length / 2;\n var currentIndex = startIndex;\n verts.push(points[0], points[1]);\n for (i = 1; i < length; i++) {\n verts.push(points[i * 2], points[(i * 2) + 1]);\n indices.push(currentIndex, currentIndex + 1);\n currentIndex++;\n }\n if (closedShape) {\n indices.push(currentIndex, startIndex);\n }\n}\n/**\n * Builds a line to draw\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @private\n * @param {PIXI.GraphicsData} graphicsData - The graphics object containing all the necessary properties\n * @param {PIXI.GraphicsGeometry} graphicsGeometry - Geometry where to append output\n */\nfunction buildLine(graphicsData, graphicsGeometry) {\n if (graphicsData.lineStyle.native) {\n buildNativeLine(graphicsData, graphicsGeometry);\n }\n else {\n buildNonNativeLine(graphicsData, graphicsGeometry);\n }\n}\n\n/**\n * Utilities for arc curves.\n *\n * @private\n */\nvar ArcUtils = /** @class */ (function () {\n function ArcUtils() {\n }\n /**\n * The arcTo() method creates an arc/curve between two tangents on the canvas.\n *\n * \"borrowed\" from https://code.google.com/p/fxcanvas/ - thanks google!\n *\n * @private\n * @param x1 - The x-coordinate of the beginning of the arc\n * @param y1 - The y-coordinate of the beginning of the arc\n * @param x2 - The x-coordinate of the end of the arc\n * @param y2 - The y-coordinate of the end of the arc\n * @param radius - The radius of the arc\n * @return - If the arc length is valid, return center of circle, radius and other info otherwise `null`.\n */\n ArcUtils.curveTo = function (x1, y1, x2, y2, radius, points) {\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n var a1 = fromY - y1;\n var b1 = fromX - x1;\n var a2 = y2 - y1;\n var b2 = x2 - x1;\n var mm = Math.abs((a1 * b2) - (b1 * a2));\n if (mm < 1.0e-8 || radius === 0) {\n if (points[points.length - 2] !== x1 || points[points.length - 1] !== y1) {\n points.push(x1, y1);\n }\n return null;\n }\n var dd = (a1 * a1) + (b1 * b1);\n var cc = (a2 * a2) + (b2 * b2);\n var tt = (a1 * a2) + (b1 * b2);\n var k1 = radius * Math.sqrt(dd) / mm;\n var k2 = radius * Math.sqrt(cc) / mm;\n var j1 = k1 * tt / dd;\n var j2 = k2 * tt / cc;\n var cx = (k1 * b2) + (k2 * b1);\n var cy = (k1 * a2) + (k2 * a1);\n var px = b1 * (k2 + j1);\n var py = a1 * (k2 + j1);\n var qx = b2 * (k1 + j2);\n var qy = a2 * (k1 + j2);\n var startAngle = Math.atan2(py - cy, px - cx);\n var endAngle = Math.atan2(qy - cy, qx - cx);\n return {\n cx: (cx + x1),\n cy: (cy + y1),\n radius: radius,\n startAngle: startAngle,\n endAngle: endAngle,\n anticlockwise: (b1 * a2 > b2 * a1),\n };\n };\n /* eslint-disable max-len */\n /**\n * The arc method creates an arc/curve (used to create circles, or parts of circles).\n *\n * @private\n * @param startX - Start x location of arc\n * @param startY - Start y location of arc\n * @param cx - The x-coordinate of the center of the circle\n * @param cy - The y-coordinate of the center of the circle\n * @param radius - The radius of the circle\n * @param startAngle - The starting angle, in radians (0 is at the 3 o'clock position\n * of the arc's circle)\n * @param endAngle - The ending angle, in radians\n * @param anticlockwise - Specifies whether the drawing should be\n * counter-clockwise or clockwise. False is default, and indicates clockwise, while true\n * indicates counter-clockwise.\n * @param points - Collection of points to add to\n */\n ArcUtils.arc = function (_startX, _startY, cx, cy, radius, startAngle, endAngle, _anticlockwise, points) {\n var sweep = endAngle - startAngle;\n var n = GRAPHICS_CURVES._segmentsCount(Math.abs(sweep) * radius, Math.ceil(Math.abs(sweep) / PI_2) * 40);\n var theta = (sweep) / (n * 2);\n var theta2 = theta * 2;\n var cTheta = Math.cos(theta);\n var sTheta = Math.sin(theta);\n var segMinus = n - 1;\n var remainder = (segMinus % 1) / segMinus;\n for (var i = 0; i <= segMinus; ++i) {\n var real = i + (remainder * i);\n var angle = ((theta) + startAngle + (theta2 * real));\n var c = Math.cos(angle);\n var s = -Math.sin(angle);\n points.push((((cTheta * c) + (sTheta * s)) * radius) + cx, (((cTheta * -s) + (sTheta * c)) * radius) + cy);\n }\n };\n return ArcUtils;\n}());\n\n/**\n * Utilities for bezier curves\n *\n * @private\n */\nvar BezierUtils = /** @class */ (function () {\n function BezierUtils() {\n }\n /**\n * Calculate length of bezier curve.\n * Analytical solution is impossible, since it involves an integral that does not integrate in general.\n * Therefore numerical solution is used.\n *\n * @private\n * @param fromX - Starting point x\n * @param fromY - Starting point y\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param cpX2 - Second Control point x\n * @param cpY2 - Second Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @return - Length of bezier curve\n */\n BezierUtils.curveLength = function (fromX, fromY, cpX, cpY, cpX2, cpY2, toX, toY) {\n var n = 10;\n var result = 0.0;\n var t = 0.0;\n var t2 = 0.0;\n var t3 = 0.0;\n var nt = 0.0;\n var nt2 = 0.0;\n var nt3 = 0.0;\n var x = 0.0;\n var y = 0.0;\n var dx = 0.0;\n var dy = 0.0;\n var prevX = fromX;\n var prevY = fromY;\n for (var i = 1; i <= n; ++i) {\n t = i / n;\n t2 = t * t;\n t3 = t2 * t;\n nt = (1.0 - t);\n nt2 = nt * nt;\n nt3 = nt2 * nt;\n x = (nt3 * fromX) + (3.0 * nt2 * t * cpX) + (3.0 * nt * t2 * cpX2) + (t3 * toX);\n y = (nt3 * fromY) + (3.0 * nt2 * t * cpY) + (3 * nt * t2 * cpY2) + (t3 * toY);\n dx = prevX - x;\n dy = prevY - y;\n prevX = x;\n prevY = y;\n result += Math.sqrt((dx * dx) + (dy * dy));\n }\n return result;\n };\n /**\n * Calculate the points for a bezier curve and then draws it.\n *\n * Ignored from docs since it is not directly exposed.\n *\n * @ignore\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param cpX2 - Second Control point x\n * @param cpY2 - Second Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @param points - Path array to push points into\n */\n BezierUtils.curveTo = function (cpX, cpY, cpX2, cpY2, toX, toY, points) {\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n points.length -= 2;\n var n = GRAPHICS_CURVES._segmentsCount(BezierUtils.curveLength(fromX, fromY, cpX, cpY, cpX2, cpY2, toX, toY));\n var dt = 0;\n var dt2 = 0;\n var dt3 = 0;\n var t2 = 0;\n var t3 = 0;\n points.push(fromX, fromY);\n for (var i = 1, j = 0; i <= n; ++i) {\n j = i / n;\n dt = (1 - j);\n dt2 = dt * dt;\n dt3 = dt2 * dt;\n t2 = j * j;\n t3 = t2 * j;\n points.push((dt3 * fromX) + (3 * dt2 * j * cpX) + (3 * dt * t2 * cpX2) + (t3 * toX), (dt3 * fromY) + (3 * dt2 * j * cpY) + (3 * dt * t2 * cpY2) + (t3 * toY));\n }\n };\n return BezierUtils;\n}());\n\n/**\n * Utilities for quadratic curves.\n *\n * @private\n */\nvar QuadraticUtils = /** @class */ (function () {\n function QuadraticUtils() {\n }\n /**\n * Calculate length of quadratic curve\n * @see {@link http://www.malczak.linuxpl.com/blog/quadratic-bezier-curve-length/}\n * for the detailed explanation of math behind this.\n *\n * @private\n * @param fromX - x-coordinate of curve start point\n * @param fromY - y-coordinate of curve start point\n * @param cpX - x-coordinate of curve control point\n * @param cpY - y-coordinate of curve control point\n * @param toX - x-coordinate of curve end point\n * @param toY - y-coordinate of curve end point\n * @return - Length of quadratic curve\n */\n QuadraticUtils.curveLength = function (fromX, fromY, cpX, cpY, toX, toY) {\n var ax = fromX - (2.0 * cpX) + toX;\n var ay = fromY - (2.0 * cpY) + toY;\n var bx = (2.0 * cpX) - (2.0 * fromX);\n var by = (2.0 * cpY) - (2.0 * fromY);\n var a = 4.0 * ((ax * ax) + (ay * ay));\n var b = 4.0 * ((ax * bx) + (ay * by));\n var c = (bx * bx) + (by * by);\n var s = 2.0 * Math.sqrt(a + b + c);\n var a2 = Math.sqrt(a);\n var a32 = 2.0 * a * a2;\n var c2 = 2.0 * Math.sqrt(c);\n var ba = b / a2;\n return ((a32 * s)\n + (a2 * b * (s - c2))\n + (((4.0 * c * a) - (b * b))\n * Math.log(((2.0 * a2) + ba + s) / (ba + c2)))) / (4.0 * a32);\n };\n /**\n * Calculate the points for a quadratic bezier curve and then draws it.\n * Based on: https://stackoverflow.com/questions/785097/how-do-i-implement-a-bezier-curve-in-c\n *\n * @private\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @param points - Points to add segments to.\n */\n QuadraticUtils.curveTo = function (cpX, cpY, toX, toY, points) {\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n var n = GRAPHICS_CURVES._segmentsCount(QuadraticUtils.curveLength(fromX, fromY, cpX, cpY, toX, toY));\n var xa = 0;\n var ya = 0;\n for (var i = 1; i <= n; ++i) {\n var j = i / n;\n xa = fromX + ((cpX - fromX) * j);\n ya = fromY + ((cpY - fromY) * j);\n points.push(xa + (((cpX + ((toX - cpX) * j)) - xa) * j), ya + (((cpY + ((toY - cpY) * j)) - ya) * j));\n }\n };\n return QuadraticUtils;\n}());\n\n/**\n * A structure to hold interim batch objects for Graphics.\n *\n * @memberof PIXI.graphicsUtils\n */\nvar BatchPart = /** @class */ (function () {\n function BatchPart() {\n this.reset();\n }\n /** Begin batch part. */\n BatchPart.prototype.begin = function (style, startIndex, attribStart) {\n this.reset();\n this.style = style;\n this.start = startIndex;\n this.attribStart = attribStart;\n };\n /** End batch part. */\n BatchPart.prototype.end = function (endIndex, endAttrib) {\n this.attribSize = endAttrib - this.attribStart;\n this.size = endIndex - this.start;\n };\n BatchPart.prototype.reset = function () {\n this.style = null;\n this.size = 0;\n this.start = 0;\n this.attribStart = 0;\n this.attribSize = 0;\n };\n return BatchPart;\n}());\n\n/**\n * Generalized convenience utilities for Graphics.\n *\n * @namespace graphicsUtils\n * @memberof PIXI\n */\nvar _a;\n/**\n * Map of fill commands for each shape type.\n *\n * @memberof PIXI.graphicsUtils\n * @member {Object} FILL_COMMANDS\n */\nvar FILL_COMMANDS = (_a = {},\n _a[SHAPES.POLY] = buildPoly,\n _a[SHAPES.CIRC] = buildCircle,\n _a[SHAPES.ELIP] = buildCircle,\n _a[SHAPES.RECT] = buildRectangle,\n _a[SHAPES.RREC] = buildRoundedRectangle,\n _a);\n/**\n * Batch pool, stores unused batches for preventing allocations.\n *\n * @memberof PIXI.graphicsUtils\n * @member {Array<PIXI.graphicsUtils.BatchPart>} BATCH_POOL\n */\nvar BATCH_POOL = [];\n/**\n * Draw call pool, stores unused draw calls for preventing allocations.\n *\n * @memberof PIXI.graphicsUtils\n * @member {Array<PIXI.BatchDrawCall>} DRAW_CALL_POOL\n */\nvar DRAW_CALL_POOL = [];\n\n/**\n * A class to contain data useful for Graphics objects\n *\n * @memberof PIXI\n */\nvar GraphicsData = /** @class */ (function () {\n /**\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - The shape object to draw.\n * @param fillStyle - the width of the line to draw\n * @param lineStyle - the color of the line to draw\n * @param matrix - Transform matrix\n */\n function GraphicsData(shape, fillStyle, lineStyle, matrix) {\n if (fillStyle === void 0) { fillStyle = null; }\n if (lineStyle === void 0) { lineStyle = null; }\n if (matrix === void 0) { matrix = null; }\n /** The collection of points. */\n this.points = [];\n /** The collection of holes. */\n this.holes = [];\n this.shape = shape;\n this.lineStyle = lineStyle;\n this.fillStyle = fillStyle;\n this.matrix = matrix;\n this.type = shape.type;\n }\n /**\n * Creates a new GraphicsData object with the same values as this one.\n *\n * @return - Cloned GraphicsData object\n */\n GraphicsData.prototype.clone = function () {\n return new GraphicsData(this.shape, this.fillStyle, this.lineStyle, this.matrix);\n };\n /** Destroys the Graphics data. */\n GraphicsData.prototype.destroy = function () {\n this.shape = null;\n this.holes.length = 0;\n this.holes = null;\n this.points.length = 0;\n this.points = null;\n this.lineStyle = null;\n this.fillStyle = null;\n };\n return GraphicsData;\n}());\n\nvar tmpPoint = new Point();\nvar tmpBounds = new Bounds();\n/**\n * The Graphics class contains methods used to draw primitive shapes such as lines, circles and\n * rectangles to the display, and to color and fill them.\n *\n * GraphicsGeometry is designed to not be continually updating the geometry since it's expensive\n * to re-tesselate using **earcut**. Consider using {@link PIXI.Mesh} for this use-case, it's much faster.\n *\n * @memberof PIXI\n */\nvar GraphicsGeometry = /** @class */ (function (_super) {\n __extends(GraphicsGeometry, _super);\n // eslint-disable-next-line @typescript-eslint/no-useless-constructor\n function GraphicsGeometry() {\n var _this = _super.call(this) || this;\n /**\n * Minimal distance between points that are considered different.\n * Affects line tesselation.\n */\n _this.closePointEps = 1e-4;\n /** Padding to add to the bounds. */\n _this.boundsPadding = 0;\n _this.uvsFloat32 = null;\n _this.indicesUint16 = null;\n _this.batchable = false;\n /** An array of points to draw, 2 numbers per point */\n _this.points = [];\n /** The collection of colors */\n _this.colors = [];\n /** The UVs collection */\n _this.uvs = [];\n /** The indices of the vertices */\n _this.indices = [];\n /** Reference to the texture IDs. */\n _this.textureIds = [];\n /**\n * The collection of drawn shapes.\n *\n * @member {PIXI.GraphicsData[]}\n */\n _this.graphicsData = [];\n /**\n * List of current draw calls drived from the batches.\n *\n * @member {PIXI.BatchDrawCall[]}\n */\n _this.drawCalls = [];\n /** Batches need to regenerated if the geometry is updated. */\n _this.batchDirty = -1;\n /**\n * Intermediate abstract format sent to batch system.\n * Can be converted to drawCalls or to batchable objects.\n *\n * @member {PIXI.graphicsUtils.BatchPart[]}\n */\n _this.batches = [];\n /** Used to detect if the graphics object has changed. */\n _this.dirty = 0;\n /** Used to check if the cache is dirty. */\n _this.cacheDirty = -1;\n /** Used to detect if we cleared the graphicsData. */\n _this.clearDirty = 0;\n /** Index of the last batched shape in the stack of calls. */\n _this.shapeIndex = 0;\n /** Cached bounds. */\n _this._bounds = new Bounds();\n /** The bounds dirty flag. */\n _this.boundsDirty = -1;\n return _this;\n }\n Object.defineProperty(GraphicsGeometry.prototype, \"bounds\", {\n /**\n * Get the current bounds of the graphic geometry.\n *\n * @readonly\n */\n get: function () {\n if (this.boundsDirty !== this.dirty) {\n this.boundsDirty = this.dirty;\n this.calculateBounds();\n }\n return this._bounds;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Call if you changed graphicsData manually.\n * Empties all batch buffers.\n */\n GraphicsGeometry.prototype.invalidate = function () {\n this.boundsDirty = -1;\n this.dirty++;\n this.batchDirty++;\n this.shapeIndex = 0;\n this.points.length = 0;\n this.colors.length = 0;\n this.uvs.length = 0;\n this.indices.length = 0;\n this.textureIds.length = 0;\n for (var i = 0; i < this.drawCalls.length; i++) {\n this.drawCalls[i].texArray.clear();\n DRAW_CALL_POOL.push(this.drawCalls[i]);\n }\n this.drawCalls.length = 0;\n for (var i = 0; i < this.batches.length; i++) {\n var batchPart = this.batches[i];\n batchPart.reset();\n BATCH_POOL.push(batchPart);\n }\n this.batches.length = 0;\n };\n /**\n * Clears the graphics that were drawn to this Graphics object, and resets fill and line style settings.\n *\n * @return - This GraphicsGeometry object. Good for chaining method calls\n */\n GraphicsGeometry.prototype.clear = function () {\n if (this.graphicsData.length > 0) {\n this.invalidate();\n this.clearDirty++;\n this.graphicsData.length = 0;\n }\n return this;\n };\n /**\n * Draws the given shape to this Graphics object. Can be any of Circle, Rectangle, Ellipse, Line or Polygon.\n *\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - The shape object to draw.\n * @param fillStyle - Defines style of the fill.\n * @param lineStyle - Defines style of the lines.\n * @param matrix - Transform applied to the points of the shape.\n * @return - Returns geometry for chaining.\n */\n GraphicsGeometry.prototype.drawShape = function (shape, fillStyle, lineStyle, matrix) {\n if (fillStyle === void 0) { fillStyle = null; }\n if (lineStyle === void 0) { lineStyle = null; }\n if (matrix === void 0) { matrix = null; }\n var data = new GraphicsData(shape, fillStyle, lineStyle, matrix);\n this.graphicsData.push(data);\n this.dirty++;\n return this;\n };\n /**\n * Draws the given shape to this Graphics object. Can be any of Circle, Rectangle, Ellipse, Line or Polygon.\n *\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - The shape object to draw.\n * @param matrix - Transform applied to the points of the shape.\n * @return - Returns geometry for chaining.\n */\n GraphicsGeometry.prototype.drawHole = function (shape, matrix) {\n if (matrix === void 0) { matrix = null; }\n if (!this.graphicsData.length) {\n return null;\n }\n var data = new GraphicsData(shape, null, null, matrix);\n var lastShape = this.graphicsData[this.graphicsData.length - 1];\n data.lineStyle = lastShape.lineStyle;\n lastShape.holes.push(data);\n this.dirty++;\n return this;\n };\n /** Destroys the GraphicsGeometry object. */\n GraphicsGeometry.prototype.destroy = function () {\n _super.prototype.destroy.call(this);\n // destroy each of the GraphicsData objects\n for (var i = 0; i < this.graphicsData.length; ++i) {\n this.graphicsData[i].destroy();\n }\n this.points.length = 0;\n this.points = null;\n this.colors.length = 0;\n this.colors = null;\n this.uvs.length = 0;\n this.uvs = null;\n this.indices.length = 0;\n this.indices = null;\n this.indexBuffer.destroy();\n this.indexBuffer = null;\n this.graphicsData.length = 0;\n this.graphicsData = null;\n this.drawCalls.length = 0;\n this.drawCalls = null;\n this.batches.length = 0;\n this.batches = null;\n this._bounds = null;\n };\n /**\n * Check to see if a point is contained within this geometry.\n *\n * @param point - Point to check if it's contained.\n * @return {Boolean} `true` if the point is contained within geometry.\n */\n GraphicsGeometry.prototype.containsPoint = function (point) {\n var graphicsData = this.graphicsData;\n for (var i = 0; i < graphicsData.length; ++i) {\n var data = graphicsData[i];\n if (!data.fillStyle.visible) {\n continue;\n }\n // only deal with fills..\n if (data.shape) {\n if (data.matrix) {\n data.matrix.applyInverse(point, tmpPoint);\n }\n else {\n tmpPoint.copyFrom(point);\n }\n if (data.shape.contains(tmpPoint.x, tmpPoint.y)) {\n var hitHole = false;\n if (data.holes) {\n for (var i_1 = 0; i_1 < data.holes.length; i_1++) {\n var hole = data.holes[i_1];\n if (hole.shape.contains(tmpPoint.x, tmpPoint.y)) {\n hitHole = true;\n break;\n }\n }\n }\n if (!hitHole) {\n return true;\n }\n }\n }\n }\n return false;\n };\n /**\n * Generates intermediate batch data. Either gets converted to drawCalls\n * or used to convert to batch objects directly by the Graphics object.\n *\n * @param allow32Indices - Allow using 32-bit indices for preventing artifacts when more that 65535 vertices\n */\n GraphicsGeometry.prototype.updateBatches = function (allow32Indices) {\n if (!this.graphicsData.length) {\n this.batchable = true;\n return;\n }\n if (!this.validateBatching()) {\n return;\n }\n this.cacheDirty = this.dirty;\n var uvs = this.uvs;\n var graphicsData = this.graphicsData;\n var batchPart = null;\n var currentStyle = null;\n if (this.batches.length > 0) {\n batchPart = this.batches[this.batches.length - 1];\n currentStyle = batchPart.style;\n }\n for (var i = this.shapeIndex; i < graphicsData.length; i++) {\n this.shapeIndex++;\n var data = graphicsData[i];\n var fillStyle = data.fillStyle;\n var lineStyle = data.lineStyle;\n var command = FILL_COMMANDS[data.type];\n // build out the shapes points..\n command.build(data);\n if (data.matrix) {\n this.transformPoints(data.points, data.matrix);\n }\n if (fillStyle.visible || lineStyle.visible) {\n this.processHoles(data.holes);\n }\n for (var j = 0; j < 2; j++) {\n var style = (j === 0) ? fillStyle : lineStyle;\n if (!style.visible)\n { continue; }\n var nextTexture = style.texture.baseTexture;\n var index_1 = this.indices.length;\n var attribIndex = this.points.length / 2;\n nextTexture.wrapMode = WRAP_MODES.REPEAT;\n if (j === 0) {\n this.processFill(data);\n }\n else {\n this.processLine(data);\n }\n var size = (this.points.length / 2) - attribIndex;\n if (size === 0)\n { continue; }\n // close batch if style is different\n if (batchPart && !this._compareStyles(currentStyle, style)) {\n batchPart.end(index_1, attribIndex);\n batchPart = null;\n }\n // spawn new batch if its first batch or previous was closed\n if (!batchPart) {\n batchPart = BATCH_POOL.pop() || new BatchPart();\n batchPart.begin(style, index_1, attribIndex);\n this.batches.push(batchPart);\n currentStyle = style;\n }\n this.addUvs(this.points, uvs, style.texture, attribIndex, size, style.matrix);\n }\n }\n var index = this.indices.length;\n var attrib = this.points.length / 2;\n if (batchPart) {\n batchPart.end(index, attrib);\n }\n if (this.batches.length === 0) {\n // there are no visible styles in GraphicsData\n // its possible that someone wants Graphics just for the bounds\n this.batchable = true;\n return;\n }\n // prevent allocation when length is same as buffer\n if (this.indicesUint16 && this.indices.length === this.indicesUint16.length) {\n this.indicesUint16.set(this.indices);\n }\n else {\n var need32 = attrib > 0xffff && allow32Indices;\n this.indicesUint16 = need32 ? new Uint32Array(this.indices) : new Uint16Array(this.indices);\n }\n // TODO make this a const..\n this.batchable = this.isBatchable();\n if (this.batchable) {\n this.packBatches();\n }\n else {\n this.buildDrawCalls();\n }\n };\n /**\n * Affinity check\n *\n * @param styleA\n * @param styleB\n */\n GraphicsGeometry.prototype._compareStyles = function (styleA, styleB) {\n if (!styleA || !styleB) {\n return false;\n }\n if (styleA.texture.baseTexture !== styleB.texture.baseTexture) {\n return false;\n }\n if (styleA.color + styleA.alpha !== styleB.color + styleB.alpha) {\n return false;\n }\n if (!!styleA.native !== !!styleB.native) {\n return false;\n }\n return true;\n };\n /** Test geometry for batching process. */\n GraphicsGeometry.prototype.validateBatching = function () {\n if (this.dirty === this.cacheDirty || !this.graphicsData.length) {\n return false;\n }\n for (var i = 0, l = this.graphicsData.length; i < l; i++) {\n var data = this.graphicsData[i];\n var fill = data.fillStyle;\n var line = data.lineStyle;\n if (fill && !fill.texture.baseTexture.valid)\n { return false; }\n if (line && !line.texture.baseTexture.valid)\n { return false; }\n }\n return true;\n };\n /** Offset the indices so that it works with the batcher. */\n GraphicsGeometry.prototype.packBatches = function () {\n this.batchDirty++;\n this.uvsFloat32 = new Float32Array(this.uvs);\n var batches = this.batches;\n for (var i = 0, l = batches.length; i < l; i++) {\n var batch = batches[i];\n for (var j = 0; j < batch.size; j++) {\n var index = batch.start + j;\n this.indicesUint16[index] = this.indicesUint16[index] - batch.attribStart;\n }\n }\n };\n /**\n * Checks to see if this graphics geometry can be batched.\n * Currently it needs to be small enough and not contain any native lines.\n */\n GraphicsGeometry.prototype.isBatchable = function () {\n // prevent heavy mesh batching\n if (this.points.length > 0xffff * 2) {\n return false;\n }\n var batches = this.batches;\n for (var i = 0; i < batches.length; i++) {\n if (batches[i].style.native) {\n return false;\n }\n }\n return (this.points.length < GraphicsGeometry.BATCHABLE_SIZE * 2);\n };\n /** Converts intermediate batches data to drawCalls. */\n GraphicsGeometry.prototype.buildDrawCalls = function () {\n var TICK = ++BaseTexture._globalBatch;\n for (var i = 0; i < this.drawCalls.length; i++) {\n this.drawCalls[i].texArray.clear();\n DRAW_CALL_POOL.push(this.drawCalls[i]);\n }\n this.drawCalls.length = 0;\n var colors = this.colors;\n var textureIds = this.textureIds;\n var currentGroup = DRAW_CALL_POOL.pop();\n if (!currentGroup) {\n currentGroup = new BatchDrawCall();\n currentGroup.texArray = new BatchTextureArray();\n }\n currentGroup.texArray.count = 0;\n currentGroup.start = 0;\n currentGroup.size = 0;\n currentGroup.type = DRAW_MODES.TRIANGLES;\n var textureCount = 0;\n var currentTexture = null;\n var textureId = 0;\n var native = false;\n var drawMode = DRAW_MODES.TRIANGLES;\n var index = 0;\n this.drawCalls.push(currentGroup);\n // TODO - this can be simplified\n for (var i = 0; i < this.batches.length; i++) {\n var data = this.batches[i];\n // TODO add some full on MAX_TEXTURE CODE..\n var MAX_TEXTURES = 8;\n // Forced cast for checking `native` without errors\n var style = data.style;\n var nextTexture = style.texture.baseTexture;\n if (native !== !!style.native) {\n native = !!style.native;\n drawMode = native ? DRAW_MODES.LINES : DRAW_MODES.TRIANGLES;\n // force the batch to break!\n currentTexture = null;\n textureCount = MAX_TEXTURES;\n TICK++;\n }\n if (currentTexture !== nextTexture) {\n currentTexture = nextTexture;\n if (nextTexture._batchEnabled !== TICK) {\n if (textureCount === MAX_TEXTURES) {\n TICK++;\n textureCount = 0;\n if (currentGroup.size > 0) {\n currentGroup = DRAW_CALL_POOL.pop();\n if (!currentGroup) {\n currentGroup = new BatchDrawCall();\n currentGroup.texArray = new BatchTextureArray();\n }\n this.drawCalls.push(currentGroup);\n }\n currentGroup.start = index;\n currentGroup.size = 0;\n currentGroup.texArray.count = 0;\n currentGroup.type = drawMode;\n }\n // TODO add this to the render part..\n // Hack! Because texture has protected `touched`\n nextTexture.touched = 1; // touch;\n nextTexture._batchEnabled = TICK;\n nextTexture._batchLocation = textureCount;\n nextTexture.wrapMode = WRAP_MODES.REPEAT;\n currentGroup.texArray.elements[currentGroup.texArray.count++] = nextTexture;\n textureCount++;\n }\n }\n currentGroup.size += data.size;\n index += data.size;\n textureId = nextTexture._batchLocation;\n this.addColors(colors, style.color, style.alpha, data.attribSize, data.attribStart);\n this.addTextureIds(textureIds, textureId, data.attribSize, data.attribStart);\n }\n BaseTexture._globalBatch = TICK;\n // upload..\n // merge for now!\n this.packAttributes();\n };\n /** Packs attributes to single buffer. */\n GraphicsGeometry.prototype.packAttributes = function () {\n var verts = this.points;\n var uvs = this.uvs;\n var colors = this.colors;\n var textureIds = this.textureIds;\n // verts are 2 positions.. so we * by 3 as there are 6 properties.. then 4 cos its bytes\n var glPoints = new ArrayBuffer(verts.length * 3 * 4);\n var f32 = new Float32Array(glPoints);\n var u32 = new Uint32Array(glPoints);\n var p = 0;\n for (var i = 0; i < verts.length / 2; i++) {\n f32[p++] = verts[i * 2];\n f32[p++] = verts[(i * 2) + 1];\n f32[p++] = uvs[i * 2];\n f32[p++] = uvs[(i * 2) + 1];\n u32[p++] = colors[i];\n f32[p++] = textureIds[i];\n }\n this._buffer.update(glPoints);\n this._indexBuffer.update(this.indicesUint16);\n };\n /** Process fill part of Graphics. */\n GraphicsGeometry.prototype.processFill = function (data) {\n if (data.holes.length) {\n buildPoly.triangulate(data, this);\n }\n else {\n var command = FILL_COMMANDS[data.type];\n command.triangulate(data, this);\n }\n };\n /** Process line part of Graphics. */\n GraphicsGeometry.prototype.processLine = function (data) {\n buildLine(data, this);\n for (var i = 0; i < data.holes.length; i++) {\n buildLine(data.holes[i], this);\n }\n };\n /** Process the holes data. */\n GraphicsGeometry.prototype.processHoles = function (holes) {\n for (var i = 0; i < holes.length; i++) {\n var hole = holes[i];\n var command = FILL_COMMANDS[hole.type];\n command.build(hole);\n if (hole.matrix) {\n this.transformPoints(hole.points, hole.matrix);\n }\n }\n };\n /** Update the local bounds of the object. Expensive to use performance-wise. */\n GraphicsGeometry.prototype.calculateBounds = function () {\n var bounds = this._bounds;\n var sequenceBounds = tmpBounds;\n var curMatrix = Matrix.IDENTITY;\n this._bounds.clear();\n sequenceBounds.clear();\n for (var i = 0; i < this.graphicsData.length; i++) {\n var data = this.graphicsData[i];\n var shape = data.shape;\n var type = data.type;\n var lineStyle = data.lineStyle;\n var nextMatrix = data.matrix || Matrix.IDENTITY;\n var lineWidth = 0.0;\n if (lineStyle && lineStyle.visible) {\n lineWidth = lineStyle.width * Math.max(0, lineStyle.alignment);\n }\n if (curMatrix !== nextMatrix) {\n if (!sequenceBounds.isEmpty()) {\n bounds.addBoundsMatrix(sequenceBounds, curMatrix);\n sequenceBounds.clear();\n }\n curMatrix = nextMatrix;\n }\n if (type === SHAPES.RECT || type === SHAPES.RREC) {\n var rect = shape;\n sequenceBounds.addFramePad(rect.x, rect.y, rect.x + rect.width, rect.y + rect.height, lineWidth, lineWidth);\n }\n else if (type === SHAPES.CIRC) {\n var circle = shape;\n sequenceBounds.addFramePad(circle.x, circle.y, circle.x, circle.y, circle.radius + lineWidth, circle.radius + lineWidth);\n }\n else if (type === SHAPES.ELIP) {\n var ellipse = shape;\n sequenceBounds.addFramePad(ellipse.x, ellipse.y, ellipse.x, ellipse.y, ellipse.width + lineWidth, ellipse.height + lineWidth);\n }\n else {\n var poly = shape;\n // adding directly to the bounds\n bounds.addVerticesMatrix(curMatrix, poly.points, 0, poly.points.length, lineWidth, lineWidth);\n }\n }\n if (!sequenceBounds.isEmpty()) {\n bounds.addBoundsMatrix(sequenceBounds, curMatrix);\n }\n bounds.pad(this.boundsPadding, this.boundsPadding);\n };\n /**\n * Transform points using matrix.\n *\n * @param points - Points to transform\n * @param matrix - Transform matrix\n */\n GraphicsGeometry.prototype.transformPoints = function (points, matrix) {\n for (var i = 0; i < points.length / 2; i++) {\n var x = points[(i * 2)];\n var y = points[(i * 2) + 1];\n points[(i * 2)] = (matrix.a * x) + (matrix.c * y) + matrix.tx;\n points[(i * 2) + 1] = (matrix.b * x) + (matrix.d * y) + matrix.ty;\n }\n };\n /**\n * Add colors.\n *\n * @param colors - List of colors to add to\n * @param color - Color to add\n * @param alpha - Alpha to use\n * @param size - Number of colors to add\n * @param offset\n */\n GraphicsGeometry.prototype.addColors = function (colors, color, alpha, size, offset) {\n if (offset === void 0) { offset = 0; }\n // TODO use the premultiply bits Ivan added\n var rgb = (color >> 16) + (color & 0xff00) + ((color & 0xff) << 16);\n var rgba = premultiplyTint(rgb, alpha);\n colors.length = Math.max(colors.length, offset + size);\n for (var i = 0; i < size; i++) {\n colors[offset + i] = rgba;\n }\n };\n /** Add texture id that the shader/fragment wants to use. */\n GraphicsGeometry.prototype.addTextureIds = function (textureIds, id, size, offset) {\n if (offset === void 0) { offset = 0; }\n textureIds.length = Math.max(textureIds.length, offset + size);\n for (var i = 0; i < size; i++) {\n textureIds[offset + i] = id;\n }\n };\n /**\n * Generates the UVs for a shape.\n *\n * @param verts - Vertices\n * @param uvs - UVs\n * @param texture - Reference to Texture\n * @param start - Index buffer start index.\n * @param size - The size/length for index buffer.\n * @param matrix - Optional transform for all points.\n */\n GraphicsGeometry.prototype.addUvs = function (verts, uvs, texture, start, size, matrix) {\n if (matrix === void 0) { matrix = null; }\n var index = 0;\n var uvsStart = uvs.length;\n var frame = texture.frame;\n while (index < size) {\n var x = verts[(start + index) * 2];\n var y = verts[((start + index) * 2) + 1];\n if (matrix) {\n var nx = (matrix.a * x) + (matrix.c * y) + matrix.tx;\n y = (matrix.b * x) + (matrix.d * y) + matrix.ty;\n x = nx;\n }\n index++;\n uvs.push(x / frame.width, y / frame.height);\n }\n var baseTexture = texture.baseTexture;\n if (frame.width < baseTexture.width\n || frame.height < baseTexture.height) {\n this.adjustUvs(uvs, texture, uvsStart, size);\n }\n };\n /**\n * Modify uvs array according to position of texture region\n * Does not work with rotated or trimmed textures\n *\n * @param uvs - array\n * @param texture - region\n * @param start - starting index for uvs\n * @param size - how many points to adjust\n */\n GraphicsGeometry.prototype.adjustUvs = function (uvs, texture, start, size) {\n var baseTexture = texture.baseTexture;\n var eps = 1e-6;\n var finish = start + (size * 2);\n var frame = texture.frame;\n var scaleX = frame.width / baseTexture.width;\n var scaleY = frame.height / baseTexture.height;\n var offsetX = frame.x / frame.width;\n var offsetY = frame.y / frame.height;\n var minX = Math.floor(uvs[start] + eps);\n var minY = Math.floor(uvs[start + 1] + eps);\n for (var i = start + 2; i < finish; i += 2) {\n minX = Math.min(minX, Math.floor(uvs[i] + eps));\n minY = Math.min(minY, Math.floor(uvs[i + 1] + eps));\n }\n offsetX -= minX;\n offsetY -= minY;\n for (var i = start; i < finish; i += 2) {\n uvs[i] = (uvs[i] + offsetX) * scaleX;\n uvs[i + 1] = (uvs[i + 1] + offsetY) * scaleY;\n }\n };\n /**\n * The maximum number of points to consider an object \"batchable\",\n * able to be batched by the renderer's batch system.\n\\ */\n GraphicsGeometry.BATCHABLE_SIZE = 100;\n return GraphicsGeometry;\n}(BatchGeometry));\n\n/**\n * Represents the line style for Graphics.\n *\n * @memberof PIXI\n */\nvar LineStyle = /** @class */ (function (_super) {\n __extends(LineStyle, _super);\n function LineStyle() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n /** The width (thickness) of any lines drawn. */\n _this.width = 0;\n /** The alignment of any lines drawn (0.5 = middle, 1 = outer, 0 = inner). WebGL only. */\n _this.alignment = 0.5;\n /** If true the lines will be draw using LINES instead of TRIANGLE_STRIP. */\n _this.native = false;\n /**\n * Line cap style.\n *\n * @member {PIXI.LINE_CAP}\n * @default PIXI.LINE_CAP.BUTT\n */\n _this.cap = LINE_CAP.BUTT;\n /**\n * Line join style.\n *\n * @member {PIXI.LINE_JOIN}\n * @default PIXI.LINE_JOIN.MITER\n */\n _this.join = LINE_JOIN.MITER;\n /** Miter limit. */\n _this.miterLimit = 10;\n return _this;\n }\n /** Clones the object. */\n LineStyle.prototype.clone = function () {\n var obj = new LineStyle();\n obj.color = this.color;\n obj.alpha = this.alpha;\n obj.texture = this.texture;\n obj.matrix = this.matrix;\n obj.visible = this.visible;\n obj.width = this.width;\n obj.alignment = this.alignment;\n obj.native = this.native;\n obj.cap = this.cap;\n obj.join = this.join;\n obj.miterLimit = this.miterLimit;\n return obj;\n };\n /** Reset the line style to default. */\n LineStyle.prototype.reset = function () {\n _super.prototype.reset.call(this);\n // Override default line style color\n this.color = 0x0;\n this.alignment = 0.5;\n this.width = 0;\n this.native = false;\n };\n return LineStyle;\n}(FillStyle));\n\nvar temp = new Float32Array(3);\n// a default shaders map used by graphics..\nvar DEFAULT_SHADERS = {};\n/**\n * The Graphics class is primarily used to render primitive shapes such as lines, circles and\n * rectangles to the display, and to color and fill them. However, you can also use a Graphics\n * object to build a list of primitives to use as a mask, or as a complex hitArea.\n *\n * Please note that due to legacy naming conventions, the behavior of some functions in this class\n * can be confusing. Each call to `drawRect()`, `drawPolygon()`, etc. actually stores that primitive\n * in the Geometry class's GraphicsGeometry object for later use in rendering or hit testing - the\n * functions do not directly draw anything to the screen. Similarly, the `clear()` function doesn't\n * change the screen, it simply resets the list of primitives, which can be useful if you want to\n * rebuild the contents of an existing Graphics object.\n *\n * Once a GraphicsGeometry list is built, you can re-use it in other Geometry objects as\n * an optimization, by passing it into a new Geometry object's constructor. Because of this\n * ability, it's important to call `destroy()` on Geometry objects once you are done with them, to\n * properly dereference each GraphicsGeometry and prevent memory leaks.\n *\n * @memberof PIXI\n */\nvar Graphics = /** @class */ (function (_super) {\n __extends(Graphics, _super);\n /**\n * @param geometry - Geometry to use, if omitted will create a new GraphicsGeometry instance.\n */\n function Graphics(geometry) {\n if (geometry === void 0) { geometry = null; }\n var _this = _super.call(this) || this;\n /**\n * Represents the vertex and fragment shaders that processes the geometry and runs on the GPU.\n * Can be shared between multiple Graphics objects.\n */\n _this.shader = null;\n /** Renderer plugin for batching */\n _this.pluginName = 'batch';\n /**\n * Current path\n *\n * @readonly\n */\n _this.currentPath = null;\n /** A collections of batches! These can be drawn by the renderer batch system. */\n _this.batches = [];\n /** Update dirty for limiting calculating tints for batches. */\n _this.batchTint = -1;\n /** Update dirty for limiting calculating batches.*/\n _this.batchDirty = -1;\n /** Copy of the object vertex data. */\n _this.vertexData = null;\n /** Current fill style. */\n _this._fillStyle = new FillStyle();\n /** Current line style. */\n _this._lineStyle = new LineStyle();\n /** Current shape transform matrix. */\n _this._matrix = null;\n /** Current hole mode is enabled. */\n _this._holeMode = false;\n /**\n * Represents the WebGL state the Graphics required to render, excludes shader and geometry. E.g.,\n * blend mode, culling, depth testing, direction of rendering triangles, backface, etc.\n */\n _this.state = State.for2d();\n _this._geometry = geometry || new GraphicsGeometry();\n _this._geometry.refCount++;\n /**\n * When cacheAsBitmap is set to true the graphics object will be rendered as if it was a sprite.\n * This is useful if your graphics element does not change often, as it will speed up the rendering\n * of the object in exchange for taking up texture memory. It is also useful if you need the graphics\n * object to be anti-aliased, because it will be rendered using canvas. This is not recommended if\n * you are constantly redrawing the graphics element.\n *\n * @name cacheAsBitmap\n * @member {boolean}\n * @memberof PIXI.Graphics#\n * @default false\n */\n _this._transformID = -1;\n // Set default\n _this.tint = 0xFFFFFF;\n _this.blendMode = BLEND_MODES.NORMAL;\n return _this;\n }\n Object.defineProperty(Graphics.prototype, \"geometry\", {\n /**\n * Includes vertex positions, face indices, normals, colors, UVs, and\n * custom attributes within buffers, reducing the cost of passing all\n * this data to the GPU. Can be shared between multiple Mesh or Graphics objects.\n *\n * @readonly\n */\n get: function () {\n return this._geometry;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Creates a new Graphics object with the same values as this one.\n * Note that only the geometry of the object is cloned, not its transform (position,scale,etc)\n *\n * @return - A clone of the graphics object\n */\n Graphics.prototype.clone = function () {\n this.finishPoly();\n return new Graphics(this._geometry);\n };\n Object.defineProperty(Graphics.prototype, \"blendMode\", {\n get: function () {\n return this.state.blendMode;\n },\n /**\n * The blend mode to be applied to the graphic shape. Apply a value of\n * `PIXI.BLEND_MODES.NORMAL` to reset the blend mode. Note that, since each\n * primitive in the GraphicsGeometry list is rendered sequentially, modes\n * such as `PIXI.BLEND_MODES.ADD` and `PIXI.BLEND_MODES.MULTIPLY` will\n * be applied per-primitive.\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n set: function (value) {\n this.state.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Graphics.prototype, \"tint\", {\n /**\n * The tint applied to each graphic shape. This is a hex value. A value of\n * 0xFFFFFF will remove any tint effect.\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n this._tint = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Graphics.prototype, \"fill\", {\n /**\n * The current fill style.\n *\n * @readonly\n */\n get: function () {\n return this._fillStyle;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Graphics.prototype, \"line\", {\n /**\n * The current line style.\n *\n * @readonly\n */\n get: function () {\n return this._lineStyle;\n },\n enumerable: false,\n configurable: true\n });\n Graphics.prototype.lineStyle = function (options, color, alpha, alignment, native) {\n if (options === void 0) { options = null; }\n if (color === void 0) { color = 0x0; }\n if (alpha === void 0) { alpha = 1; }\n if (alignment === void 0) { alignment = 0.5; }\n if (native === void 0) { native = false; }\n // Support non-object params: (width, color, alpha, alignment, native)\n if (typeof options === 'number') {\n options = { width: options, color: color, alpha: alpha, alignment: alignment, native: native };\n }\n return this.lineTextureStyle(options);\n };\n /**\n * Like line style but support texture for line fill.\n *\n * @param options - Collection of options for setting line style.\n * @param {number} [options.width=0] - width of the line to draw, will update the objects stored style\n * @param {PIXI.Texture} [options.texture=PIXI.Texture.WHITE] - Texture to use\n * @param {number} [options.color=0x0] - color of the line to draw, will update the objects stored style.\n * Default 0xFFFFFF if texture present.\n * @param {number} [options.alpha=1] - alpha of the line to draw, will update the objects stored style\n * @param {PIXI.Matrix} [options.matrix=null] - Texture matrix to transform texture\n * @param {number} [options.alignment=0.5] - alignment of the line to draw, (0 = inner, 0.5 = middle, 1 = outer).\n * WebGL only.\n * @param {boolean} [options.native=false] - If true the lines will be draw using LINES instead of TRIANGLE_STRIP\n * @param {PIXI.LINE_CAP}[options.cap=PIXI.LINE_CAP.BUTT] - line cap style\n * @param {PIXI.LINE_JOIN}[options.join=PIXI.LINE_JOIN.MITER] - line join style\n * @param {number}[options.miterLimit=10] - miter limit ratio\n * @return {PIXI.Graphics} This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.lineTextureStyle = function (options) {\n // Apply defaults\n options = Object.assign({\n width: 0,\n texture: Texture.WHITE,\n color: (options && options.texture) ? 0xFFFFFF : 0x0,\n alpha: 1,\n matrix: null,\n alignment: 0.5,\n native: false,\n cap: LINE_CAP.BUTT,\n join: LINE_JOIN.MITER,\n miterLimit: 10,\n }, options);\n if (this.currentPath) {\n this.startPoly();\n }\n var visible = options.width > 0 && options.alpha > 0;\n if (!visible) {\n this._lineStyle.reset();\n }\n else {\n if (options.matrix) {\n options.matrix = options.matrix.clone();\n options.matrix.invert();\n }\n Object.assign(this._lineStyle, { visible: visible }, options);\n }\n return this;\n };\n /**\n * Start a polygon object internally.\n *\n * @protected\n */\n Graphics.prototype.startPoly = function () {\n if (this.currentPath) {\n var points = this.currentPath.points;\n var len = this.currentPath.points.length;\n if (len > 2) {\n this.drawShape(this.currentPath);\n this.currentPath = new Polygon();\n this.currentPath.closeStroke = false;\n this.currentPath.points.push(points[len - 2], points[len - 1]);\n }\n }\n else {\n this.currentPath = new Polygon();\n this.currentPath.closeStroke = false;\n }\n };\n /**\n * Finish the polygon object.\n *\n * @protected\n */\n Graphics.prototype.finishPoly = function () {\n if (this.currentPath) {\n if (this.currentPath.points.length > 2) {\n this.drawShape(this.currentPath);\n this.currentPath = null;\n }\n else {\n this.currentPath.points.length = 0;\n }\n }\n };\n /**\n * Moves the current drawing position to x, y.\n *\n * @param x - the X coordinate to move to\n * @param y - the Y coordinate to move to\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.moveTo = function (x, y) {\n this.startPoly();\n this.currentPath.points[0] = x;\n this.currentPath.points[1] = y;\n return this;\n };\n /**\n * Draws a line using the current line style from the current drawing position to (x, y);\n * The current drawing position is then set to (x, y).\n *\n * @param x - the X coordinate to draw to\n * @param y - the Y coordinate to draw to\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.lineTo = function (x, y) {\n if (!this.currentPath) {\n this.moveTo(0, 0);\n }\n // remove duplicates..\n var points = this.currentPath.points;\n var fromX = points[points.length - 2];\n var fromY = points[points.length - 1];\n if (fromX !== x || fromY !== y) {\n points.push(x, y);\n }\n return this;\n };\n /** Initialize the curve */\n Graphics.prototype._initCurve = function (x, y) {\n if (x === void 0) { x = 0; }\n if (y === void 0) { y = 0; }\n if (this.currentPath) {\n if (this.currentPath.points.length === 0) {\n this.currentPath.points = [x, y];\n }\n }\n else {\n this.moveTo(x, y);\n }\n };\n /**\n * Calculate the points for a quadratic bezier curve and then draws it.\n * Based on: https://stackoverflow.com/questions/785097/how-do-i-implement-a-bezier-curve-in-c\n *\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.quadraticCurveTo = function (cpX, cpY, toX, toY) {\n this._initCurve();\n var points = this.currentPath.points;\n if (points.length === 0) {\n this.moveTo(0, 0);\n }\n QuadraticUtils.curveTo(cpX, cpY, toX, toY, points);\n return this;\n };\n /**\n * Calculate the points for a bezier curve and then draws it.\n *\n * @param cpX - Control point x\n * @param cpY - Control point y\n * @param cpX2 - Second Control point x\n * @param cpY2 - Second Control point y\n * @param toX - Destination point x\n * @param toY - Destination point y\n * @return This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.bezierCurveTo = function (cpX, cpY, cpX2, cpY2, toX, toY) {\n this._initCurve();\n BezierUtils.curveTo(cpX, cpY, cpX2, cpY2, toX, toY, this.currentPath.points);\n return this;\n };\n /**\n * The arcTo() method creates an arc/curve between two tangents on the canvas.\n *\n * \"borrowed\" from https://code.google.com/p/fxcanvas/ - thanks google!\n *\n * @param x1 - The x-coordinate of the first tangent point of the arc\n * @param y1 - The y-coordinate of the first tangent point of the arc\n * @param x2 - The x-coordinate of the end of the arc\n * @param y2 - The y-coordinate of the end of the arc\n * @param radius - The radius of the arc\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.arcTo = function (x1, y1, x2, y2, radius) {\n this._initCurve(x1, y1);\n var points = this.currentPath.points;\n var result = ArcUtils.curveTo(x1, y1, x2, y2, radius, points);\n if (result) {\n var cx = result.cx, cy = result.cy, radius_1 = result.radius, startAngle = result.startAngle, endAngle = result.endAngle, anticlockwise = result.anticlockwise;\n this.arc(cx, cy, radius_1, startAngle, endAngle, anticlockwise);\n }\n return this;\n };\n /**\n * The arc method creates an arc/curve (used to create circles, or parts of circles).\n *\n * @param cx - The x-coordinate of the center of the circle\n * @param cy - The y-coordinate of the center of the circle\n * @param radius - The radius of the circle\n * @param startAngle - The starting angle, in radians (0 is at the 3 o'clock position\n * of the arc's circle)\n * @param endAngle - The ending angle, in radians\n * @param anticlockwise - Specifies whether the drawing should be\n * counter-clockwise or clockwise. False is default, and indicates clockwise, while true\n * indicates counter-clockwise.\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.arc = function (cx, cy, radius, startAngle, endAngle, anticlockwise) {\n if (anticlockwise === void 0) { anticlockwise = false; }\n if (startAngle === endAngle) {\n return this;\n }\n if (!anticlockwise && endAngle <= startAngle) {\n endAngle += PI_2;\n }\n else if (anticlockwise && startAngle <= endAngle) {\n startAngle += PI_2;\n }\n var sweep = endAngle - startAngle;\n if (sweep === 0) {\n return this;\n }\n var startX = cx + (Math.cos(startAngle) * radius);\n var startY = cy + (Math.sin(startAngle) * radius);\n var eps = this._geometry.closePointEps;\n // If the currentPath exists, take its points. Otherwise call `moveTo` to start a path.\n var points = this.currentPath ? this.currentPath.points : null;\n if (points) {\n // TODO: make a better fix.\n // We check how far our start is from the last existing point\n var xDiff = Math.abs(points[points.length - 2] - startX);\n var yDiff = Math.abs(points[points.length - 1] - startY);\n if (xDiff < eps && yDiff < eps) ;\n else {\n points.push(startX, startY);\n }\n }\n else {\n this.moveTo(startX, startY);\n points = this.currentPath.points;\n }\n ArcUtils.arc(startX, startY, cx, cy, radius, startAngle, endAngle, anticlockwise, points);\n return this;\n };\n /**\n * Specifies a simple one-color fill that subsequent calls to other Graphics methods\n * (such as lineTo() or drawCircle()) use when drawing.\n *\n * @param color - the color of the fill\n * @param alpha - the alpha of the fill\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.beginFill = function (color, alpha) {\n if (color === void 0) { color = 0; }\n if (alpha === void 0) { alpha = 1; }\n return this.beginTextureFill({ texture: Texture.WHITE, color: color, alpha: alpha });\n };\n /**\n * Begin the texture fill\n *\n * @param options - Object object.\n * @param {PIXI.Texture} [options.texture=PIXI.Texture.WHITE] - Texture to fill\n * @param {number} [options.color=0xffffff] - Background to fill behind texture\n * @param {number} [options.alpha=1] - Alpha of fill\n * @param {PIXI.Matrix} [options.matrix=null] - Transform matrix\n * @return {PIXI.Graphics} This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.beginTextureFill = function (options) {\n // Apply defaults\n options = Object.assign({\n texture: Texture.WHITE,\n color: 0xFFFFFF,\n alpha: 1,\n matrix: null,\n }, options);\n if (this.currentPath) {\n this.startPoly();\n }\n var visible = options.alpha > 0;\n if (!visible) {\n this._fillStyle.reset();\n }\n else {\n if (options.matrix) {\n options.matrix = options.matrix.clone();\n options.matrix.invert();\n }\n Object.assign(this._fillStyle, { visible: visible }, options);\n }\n return this;\n };\n /**\n * Applies a fill to the lines and shapes that were added since the last call to the beginFill() method.\n *\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.endFill = function () {\n this.finishPoly();\n this._fillStyle.reset();\n return this;\n };\n /**\n * Draws a rectangle shape.\n *\n * @param x - The X coord of the top-left of the rectangle\n * @param y - The Y coord of the top-left of the rectangle\n * @param width - The width of the rectangle\n * @param height - The height of the rectangle\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawRect = function (x, y, width, height) {\n return this.drawShape(new Rectangle(x, y, width, height));\n };\n /**\n * Draw a rectangle shape with rounded/beveled corners.\n *\n * @param x - The X coord of the top-left of the rectangle\n * @param y - The Y coord of the top-left of the rectangle\n * @param width - The width of the rectangle\n * @param height - The height of the rectangle\n * @param radius - Radius of the rectangle corners\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawRoundedRect = function (x, y, width, height, radius) {\n return this.drawShape(new RoundedRectangle(x, y, width, height, radius));\n };\n /**\n * Draws a circle.\n *\n * @param x - The X coordinate of the center of the circle\n * @param y - The Y coordinate of the center of the circle\n * @param radius - The radius of the circle\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawCircle = function (x, y, radius) {\n return this.drawShape(new Circle(x, y, radius));\n };\n /**\n * Draws an ellipse.\n *\n * @param x - The X coordinate of the center of the ellipse\n * @param y - The Y coordinate of the center of the ellipse\n * @param width - The half width of the ellipse\n * @param height - The half height of the ellipse\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawEllipse = function (x, y, width, height) {\n return this.drawShape(new Ellipse(x, y, width, height));\n };\n /**\n * Draws a polygon using the given path.\n *\n * @param {number[]|PIXI.Point[]|PIXI.Polygon} path - The path data used to construct the polygon.\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawPolygon = function () {\n var arguments$1 = arguments;\n\n var path = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n path[_i] = arguments$1[_i];\n }\n var points;\n var closeStroke = true; // !!this._fillStyle;\n var poly = path[0];\n // check if data has points..\n if (poly.points) {\n closeStroke = poly.closeStroke;\n points = poly.points;\n }\n else if (Array.isArray(path[0])) {\n points = path[0];\n }\n else {\n points = path;\n }\n var shape = new Polygon(points);\n shape.closeStroke = closeStroke;\n this.drawShape(shape);\n return this;\n };\n /**\n * Draw any shape.\n *\n * @param {PIXI.Circle|PIXI.Ellipse|PIXI.Polygon|PIXI.Rectangle|PIXI.RoundedRectangle} shape - Shape to draw\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.drawShape = function (shape) {\n if (!this._holeMode) {\n this._geometry.drawShape(shape, this._fillStyle.clone(), this._lineStyle.clone(), this._matrix);\n }\n else {\n this._geometry.drawHole(shape, this._matrix);\n }\n return this;\n };\n /**\n * Clears the graphics that were drawn to this Graphics object, and resets fill and line style settings.\n *\n * @return - This Graphics object. Good for chaining method calls\n */\n Graphics.prototype.clear = function () {\n this._geometry.clear();\n this._lineStyle.reset();\n this._fillStyle.reset();\n this._boundsID++;\n this._matrix = null;\n this._holeMode = false;\n this.currentPath = null;\n return this;\n };\n /**\n * True if graphics consists of one rectangle, and thus, can be drawn like a Sprite and\n * masked with gl.scissor.\n *\n * @returns - True if only 1 rect.\n */\n Graphics.prototype.isFastRect = function () {\n var data = this._geometry.graphicsData;\n return data.length === 1\n && data[0].shape.type === SHAPES.RECT\n && !data[0].matrix\n && !data[0].holes.length\n && !(data[0].lineStyle.visible && data[0].lineStyle.width);\n };\n /**\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._render = function (renderer) {\n this.finishPoly();\n var geometry = this._geometry;\n var hasuint32 = renderer.context.supports.uint32Indices;\n // batch part..\n // batch it!\n geometry.updateBatches(hasuint32);\n if (geometry.batchable) {\n if (this.batchDirty !== geometry.batchDirty) {\n this._populateBatches();\n }\n this._renderBatched(renderer);\n }\n else {\n // no batching...\n renderer.batch.flush();\n this._renderDirect(renderer);\n }\n };\n /** Populating batches for rendering. */\n Graphics.prototype._populateBatches = function () {\n var geometry = this._geometry;\n var blendMode = this.blendMode;\n var len = geometry.batches.length;\n this.batchTint = -1;\n this._transformID = -1;\n this.batchDirty = geometry.batchDirty;\n this.batches.length = len;\n this.vertexData = new Float32Array(geometry.points);\n for (var i = 0; i < len; i++) {\n var gI = geometry.batches[i];\n var color = gI.style.color;\n var vertexData = new Float32Array(this.vertexData.buffer, gI.attribStart * 4 * 2, gI.attribSize * 2);\n var uvs = new Float32Array(geometry.uvsFloat32.buffer, gI.attribStart * 4 * 2, gI.attribSize * 2);\n var indices = new Uint16Array(geometry.indicesUint16.buffer, gI.start * 2, gI.size);\n var batch = {\n vertexData: vertexData,\n blendMode: blendMode,\n indices: indices,\n uvs: uvs,\n _batchRGB: hex2rgb(color),\n _tintRGB: color,\n _texture: gI.style.texture,\n alpha: gI.style.alpha,\n worldAlpha: 1\n };\n this.batches[i] = batch;\n }\n };\n /**\n * Renders the batches using the BathedRenderer plugin\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._renderBatched = function (renderer) {\n if (!this.batches.length) {\n return;\n }\n renderer.batch.setObjectRenderer(renderer.plugins[this.pluginName]);\n this.calculateVertices();\n this.calculateTints();\n for (var i = 0, l = this.batches.length; i < l; i++) {\n var batch = this.batches[i];\n batch.worldAlpha = this.worldAlpha * batch.alpha;\n renderer.plugins[this.pluginName].render(batch);\n }\n };\n /**\n * Renders the graphics direct\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._renderDirect = function (renderer) {\n var shader = this._resolveDirectShader(renderer);\n var geometry = this._geometry;\n var tint = this.tint;\n var worldAlpha = this.worldAlpha;\n var uniforms = shader.uniforms;\n var drawCalls = geometry.drawCalls;\n // lets set the transfomr\n uniforms.translationMatrix = this.transform.worldTransform;\n // and then lets set the tint..\n uniforms.tint[0] = (((tint >> 16) & 0xFF) / 255) * worldAlpha;\n uniforms.tint[1] = (((tint >> 8) & 0xFF) / 255) * worldAlpha;\n uniforms.tint[2] = ((tint & 0xFF) / 255) * worldAlpha;\n uniforms.tint[3] = worldAlpha;\n // the first draw call, we can set the uniforms of the shader directly here.\n // this means that we can tack advantage of the sync function of pixi!\n // bind and sync uniforms..\n // there is a way to optimise this..\n renderer.shader.bind(shader);\n renderer.geometry.bind(geometry, shader);\n // set state..\n renderer.state.set(this.state);\n // then render the rest of them...\n for (var i = 0, l = drawCalls.length; i < l; i++) {\n this._renderDrawCallDirect(renderer, geometry.drawCalls[i]);\n }\n };\n /** Renders specific DrawCall */\n Graphics.prototype._renderDrawCallDirect = function (renderer, drawCall) {\n var texArray = drawCall.texArray, type = drawCall.type, size = drawCall.size, start = drawCall.start;\n var groupTextureCount = texArray.count;\n for (var j = 0; j < groupTextureCount; j++) {\n renderer.texture.bind(texArray.elements[j], j);\n }\n renderer.geometry.draw(type, size, start);\n };\n /**\n * Resolves shader for direct rendering\n *\n * @param renderer - The renderer\n */\n Graphics.prototype._resolveDirectShader = function (renderer) {\n var shader = this.shader;\n var pluginName = this.pluginName;\n if (!shader) {\n // if there is no shader here, we can use the default shader.\n // and that only gets created if we actually need it..\n // but may be more than one plugins for graphics\n if (!DEFAULT_SHADERS[pluginName]) {\n var MAX_TEXTURES = renderer.plugins.batch.MAX_TEXTURES;\n var sampleValues = new Int32Array(MAX_TEXTURES);\n for (var i = 0; i < MAX_TEXTURES; i++) {\n sampleValues[i] = i;\n }\n var uniforms = {\n tint: new Float32Array([1, 1, 1, 1]),\n translationMatrix: new Matrix(),\n default: UniformGroup.from({ uSamplers: sampleValues }, true),\n };\n var program = renderer.plugins[pluginName]._shader.program;\n DEFAULT_SHADERS[pluginName] = new Shader(program, uniforms);\n }\n shader = DEFAULT_SHADERS[pluginName];\n }\n return shader;\n };\n /** Retrieves the bounds of the graphic shape as a rectangle object. */\n Graphics.prototype._calculateBounds = function () {\n this.finishPoly();\n var geometry = this._geometry;\n // skipping when graphics is empty, like a container\n if (!geometry.graphicsData.length) {\n return;\n }\n var _a = geometry.bounds, minX = _a.minX, minY = _a.minY, maxX = _a.maxX, maxY = _a.maxY;\n this._bounds.addFrame(this.transform, minX, minY, maxX, maxY);\n };\n /**\n * Tests if a point is inside this graphics object\n *\n * @param point - the point to test\n * @return - the result of the test\n */\n Graphics.prototype.containsPoint = function (point) {\n this.worldTransform.applyInverse(point, Graphics._TEMP_POINT);\n return this._geometry.containsPoint(Graphics._TEMP_POINT);\n };\n /** Recalculate the tint by applying tint to batches using Graphics tint. */\n Graphics.prototype.calculateTints = function () {\n if (this.batchTint !== this.tint) {\n this.batchTint = this.tint;\n var tintRGB = hex2rgb(this.tint, temp);\n for (var i = 0; i < this.batches.length; i++) {\n var batch = this.batches[i];\n var batchTint = batch._batchRGB;\n var r = (tintRGB[0] * batchTint[0]) * 255;\n var g = (tintRGB[1] * batchTint[1]) * 255;\n var b = (tintRGB[2] * batchTint[2]) * 255;\n // TODO Ivan, can this be done in one go?\n var color = (r << 16) + (g << 8) + (b | 0);\n batch._tintRGB = (color >> 16)\n + (color & 0xff00)\n + ((color & 0xff) << 16);\n }\n }\n };\n /**\n * If there's a transform update or a change to the shape of the\n * geometry, recalculate the vertices.\n */\n Graphics.prototype.calculateVertices = function () {\n var wtID = this.transform._worldID;\n if (this._transformID === wtID) {\n return;\n }\n this._transformID = wtID;\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var data = this._geometry.points; // batch.vertexDataOriginal;\n var vertexData = this.vertexData;\n var count = 0;\n for (var i = 0; i < data.length; i += 2) {\n var x = data[i];\n var y = data[i + 1];\n vertexData[count++] = (a * x) + (c * y) + tx;\n vertexData[count++] = (d * y) + (b * x) + ty;\n }\n };\n /**\n * Closes the current path.\n *\n * @return - Returns itself.\n */\n Graphics.prototype.closePath = function () {\n var currentPath = this.currentPath;\n if (currentPath) {\n // we don't need to add extra point in the end because buildLine will take care of that\n currentPath.closeStroke = true;\n // ensure that the polygon is completed, and is available for hit detection\n // (even if the graphics is not rendered yet)\n this.finishPoly();\n }\n return this;\n };\n /**\n * Apply a matrix to the positional data.\n *\n * @param matrix - Matrix to use for transform current shape.\n * @return - Returns itself.\n */\n Graphics.prototype.setMatrix = function (matrix) {\n this._matrix = matrix;\n return this;\n };\n /**\n * Begin adding holes to the last draw shape\n * IMPORTANT: holes must be fully inside a shape to work\n * Also weirdness ensues if holes overlap!\n * Ellipses, Circles, Rectangles and Rounded Rectangles cannot be holes or host for holes in CanvasRenderer,\n * please use `moveTo` `lineTo`, `quadraticCurveTo` if you rely on pixi-legacy bundle.\n *\n * @return - Returns itself.\n */\n Graphics.prototype.beginHole = function () {\n this.finishPoly();\n this._holeMode = true;\n return this;\n };\n /**\n * End adding holes to the last draw shape.\n *\n * @return - Returns itself.\n */\n Graphics.prototype.endHole = function () {\n this.finishPoly();\n this._holeMode = false;\n return this;\n };\n /**\n * Destroys the Graphics object.\n *\n * @param options - Options parameter. A boolean will act as if all\n * options have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have\n * their destroy method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the texture of the child sprite\n * @param {boolean} [options.baseTexture=false] - Only used for child Sprites if options.children is set to true\n * Should it destroy the base texture of the child sprite\n */\n Graphics.prototype.destroy = function (options) {\n this._geometry.refCount--;\n if (this._geometry.refCount === 0) {\n this._geometry.dispose();\n }\n this._matrix = null;\n this.currentPath = null;\n this._lineStyle.destroy();\n this._lineStyle = null;\n this._fillStyle.destroy();\n this._fillStyle = null;\n this._geometry = null;\n this.shader = null;\n this.vertexData = null;\n this.batches.length = 0;\n this.batches = null;\n _super.prototype.destroy.call(this, options);\n };\n /**\n * New rendering behavior for rounded rectangles: circular arcs instead of quadratic bezier curves.\n * In the next major release, we'll enable this by default.\n */\n Graphics.nextRoundedRectBehavior = false;\n /**\n * Temporary point to use for containsPoint.\n *\n * @private\n */\n Graphics._TEMP_POINT = new Point();\n return Graphics;\n}(Container));\n\nvar graphicsUtils = {\n buildPoly: buildPoly,\n buildCircle: buildCircle,\n buildRectangle: buildRectangle,\n buildRoundedRectangle: buildRoundedRectangle,\n buildLine: buildLine,\n ArcUtils: ArcUtils,\n BezierUtils: BezierUtils,\n QuadraticUtils: QuadraticUtils,\n BatchPart: BatchPart,\n FILL_COMMANDS: FILL_COMMANDS,\n BATCH_POOL: BATCH_POOL,\n DRAW_CALL_POOL: DRAW_CALL_POOL\n};\n\nexport { FillStyle, GRAPHICS_CURVES, Graphics, GraphicsData, GraphicsGeometry, LINE_CAP, LINE_JOIN, LineStyle, graphicsUtils };\n//# sourceMappingURL=graphics.js.map\n","/*!\n * @pixi/text - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/text is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Sprite } from '@pixi/sprite';\nimport { Texture } from '@pixi/core';\nimport { settings } from '@pixi/settings';\nimport { Rectangle } from '@pixi/math';\nimport { hex2string, hex2rgb, string2hex, trimCanvas, sign } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * Constants that define the type of gradient on text.\n *\n * @static\n * @constant\n * @name TEXT_GRADIENT\n * @memberof PIXI\n * @type {object}\n * @property {number} LINEAR_VERTICAL Vertical gradient\n * @property {number} LINEAR_HORIZONTAL Linear gradient\n */\nvar TEXT_GRADIENT;\n(function (TEXT_GRADIENT) {\n TEXT_GRADIENT[TEXT_GRADIENT[\"LINEAR_VERTICAL\"] = 0] = \"LINEAR_VERTICAL\";\n TEXT_GRADIENT[TEXT_GRADIENT[\"LINEAR_HORIZONTAL\"] = 1] = \"LINEAR_HORIZONTAL\";\n})(TEXT_GRADIENT || (TEXT_GRADIENT = {}));\n\n// disabling eslint for now, going to rewrite this in v5\nvar defaultStyle = {\n align: 'left',\n breakWords: false,\n dropShadow: false,\n dropShadowAlpha: 1,\n dropShadowAngle: Math.PI / 6,\n dropShadowBlur: 0,\n dropShadowColor: 'black',\n dropShadowDistance: 5,\n fill: 'black',\n fillGradientType: TEXT_GRADIENT.LINEAR_VERTICAL,\n fillGradientStops: [],\n fontFamily: 'Arial',\n fontSize: 26,\n fontStyle: 'normal',\n fontVariant: 'normal',\n fontWeight: 'normal',\n letterSpacing: 0,\n lineHeight: 0,\n lineJoin: 'miter',\n miterLimit: 10,\n padding: 0,\n stroke: 'black',\n strokeThickness: 0,\n textBaseline: 'alphabetic',\n trim: false,\n whiteSpace: 'pre',\n wordWrap: false,\n wordWrapWidth: 100,\n leading: 0,\n};\nvar genericFontFamilies = [\n 'serif',\n 'sans-serif',\n 'monospace',\n 'cursive',\n 'fantasy',\n 'system-ui' ];\n/**\n * A TextStyle Object contains information to decorate a Text objects.\n *\n * An instance can be shared between multiple Text objects; then changing the style will update all text objects using it.\n *\n * A tool can be used to generate a text style [here](https://pixijs.io/pixi-text-style).\n *\n * @memberof PIXI\n */\nvar TextStyle = /** @class */ (function () {\n /**\n * @param {object} [style] - The style parameters\n * @param {string} [style.align='left'] - Alignment for multiline text ('left', 'center' or 'right'),\n * does not affect single line text\n * @param {boolean} [style.breakWords=false] - Indicates if lines can be wrapped within words, it\n * needs wordWrap to be set to true\n * @param {boolean} [style.dropShadow=false] - Set a drop shadow for the text\n * @param {number} [style.dropShadowAlpha=1] - Set alpha for the drop shadow\n * @param {number} [style.dropShadowAngle=Math.PI/6] - Set a angle of the drop shadow\n * @param {number} [style.dropShadowBlur=0] - Set a shadow blur radius\n * @param {string|number} [style.dropShadowColor='black'] - A fill style to be used on the dropshadow e.g 'red', '#00FF00'\n * @param {number} [style.dropShadowDistance=5] - Set a distance of the drop shadow\n * @param {string|string[]|number|number[]|CanvasGradient|CanvasPattern} [style.fill='black'] - A canvas\n * fillstyle that will be used on the text e.g 'red', '#00FF00'. Can be an array to create a gradient\n * eg ['#000000','#FFFFFF']\n * {@link https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/fillStyle|MDN}\n * @param {number} [style.fillGradientType=PIXI.TEXT_GRADIENT.LINEAR_VERTICAL] - If fill is an array of colours\n * to create a gradient, this can change the type/direction of the gradient. See {@link PIXI.TEXT_GRADIENT}\n * @param {number[]} [style.fillGradientStops] - If fill is an array of colours to create a gradient, this array can set\n * the stop points (numbers between 0 and 1) for the color, overriding the default behaviour of evenly spacing them.\n * @param {string|string[]} [style.fontFamily='Arial'] - The font family\n * @param {number|string} [style.fontSize=26] - The font size (as a number it converts to px, but as a string,\n * equivalents are '26px','20pt','160%' or '1.6em')\n * @param {string} [style.fontStyle='normal'] - The font style ('normal', 'italic' or 'oblique')\n * @param {string} [style.fontVariant='normal'] - The font variant ('normal' or 'small-caps')\n * @param {string} [style.fontWeight='normal'] - The font weight ('normal', 'bold', 'bolder', 'lighter' and '100',\n * '200', '300', '400', '500', '600', '700', '800' or '900')\n * @param {number} [style.leading=0] - The space between lines\n * @param {number} [style.letterSpacing=0] - The amount of spacing between letters, default is 0\n * @param {number} [style.lineHeight] - The line height, a number that represents the vertical space that a letter uses\n * @param {string} [style.lineJoin='miter'] - The lineJoin property sets the type of corner created, it can resolve\n * spiked text issues. Possible values \"miter\" (creates a sharp corner), \"round\" (creates a round corner) or \"bevel\"\n * (creates a squared corner).\n * @param {number} [style.miterLimit=10] - The miter limit to use when using the 'miter' lineJoin mode. This can reduce\n * or increase the spikiness of rendered text.\n * @param {number} [style.padding=0] - Occasionally some fonts are cropped. Adding some padding will prevent this from\n * happening by adding padding to all sides of the text.\n * @param {string|number} [style.stroke='black'] - A canvas fillstyle that will be used on the text stroke\n * e.g 'blue', '#FCFF00'\n * @param {number} [style.strokeThickness=0] - A number that represents the thickness of the stroke.\n * Default is 0 (no stroke)\n * @param {boolean} [style.trim=false] - Trim transparent borders\n * @param {string} [style.textBaseline='alphabetic'] - The baseline of the text that is rendered.\n * @param {string} [style.whiteSpace='pre'] - Determines whether newlines & spaces are collapsed or preserved \"normal\"\n * (collapse, collapse), \"pre\" (preserve, preserve) | \"pre-line\" (preserve, collapse). It needs wordWrap to be set to true\n * @param {boolean} [style.wordWrap=false] - Indicates if word wrap should be used\n * @param {number} [style.wordWrapWidth=100] - The width at which text will wrap, it needs wordWrap to be set to true\n */\n function TextStyle(style) {\n this.styleID = 0;\n this.reset();\n deepCopyProperties(this, style, style);\n }\n /**\n * Creates a new TextStyle object with the same values as this one.\n * Note that the only the properties of the object are cloned.\n *\n * @return New cloned TextStyle object\n */\n TextStyle.prototype.clone = function () {\n var clonedProperties = {};\n deepCopyProperties(clonedProperties, this, defaultStyle);\n return new TextStyle(clonedProperties);\n };\n /** Resets all properties to the defaults specified in TextStyle.prototype._default */\n TextStyle.prototype.reset = function () {\n deepCopyProperties(this, defaultStyle, defaultStyle);\n };\n Object.defineProperty(TextStyle.prototype, \"align\", {\n /**\n * Alignment for multiline text ('left', 'center' or 'right'), does not affect single line text\n *\n * @member {string}\n */\n get: function () {\n return this._align;\n },\n set: function (align) {\n if (this._align !== align) {\n this._align = align;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"breakWords\", {\n /** Indicates if lines can be wrapped within words, it needs wordWrap to be set to true. */\n get: function () {\n return this._breakWords;\n },\n set: function (breakWords) {\n if (this._breakWords !== breakWords) {\n this._breakWords = breakWords;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadow\", {\n /** Set a drop shadow for the text. */\n get: function () {\n return this._dropShadow;\n },\n set: function (dropShadow) {\n if (this._dropShadow !== dropShadow) {\n this._dropShadow = dropShadow;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowAlpha\", {\n /** Set alpha for the drop shadow. */\n get: function () {\n return this._dropShadowAlpha;\n },\n set: function (dropShadowAlpha) {\n if (this._dropShadowAlpha !== dropShadowAlpha) {\n this._dropShadowAlpha = dropShadowAlpha;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowAngle\", {\n /** Set a angle of the drop shadow. */\n get: function () {\n return this._dropShadowAngle;\n },\n set: function (dropShadowAngle) {\n if (this._dropShadowAngle !== dropShadowAngle) {\n this._dropShadowAngle = dropShadowAngle;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowBlur\", {\n /** Set a shadow blur radius. */\n get: function () {\n return this._dropShadowBlur;\n },\n set: function (dropShadowBlur) {\n if (this._dropShadowBlur !== dropShadowBlur) {\n this._dropShadowBlur = dropShadowBlur;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowColor\", {\n /** A fill style to be used on the dropshadow e.g 'red', '#00FF00'. */\n get: function () {\n return this._dropShadowColor;\n },\n set: function (dropShadowColor) {\n var outputColor = getColor(dropShadowColor);\n if (this._dropShadowColor !== outputColor) {\n this._dropShadowColor = outputColor;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"dropShadowDistance\", {\n /** Set a distance of the drop shadow. */\n get: function () {\n return this._dropShadowDistance;\n },\n set: function (dropShadowDistance) {\n if (this._dropShadowDistance !== dropShadowDistance) {\n this._dropShadowDistance = dropShadowDistance;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fill\", {\n /**\n * A canvas fillstyle that will be used on the text e.g 'red', '#00FF00'.\n *\n * Can be an array to create a gradient eg ['#000000','#FFFFFF']\n * {@link https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/fillStyle|MDN}\n *\n * @member {string|string[]|number|number[]|CanvasGradient|CanvasPattern}\n */\n get: function () {\n return this._fill;\n },\n set: function (fill) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n // TODO: Not sure if getColor works properly with CanvasGradient and/or CanvasPattern, can't pass in\n // without casting here.\n var outputColor = getColor(fill);\n if (this._fill !== outputColor) {\n this._fill = outputColor;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fillGradientType\", {\n /**\n * If fill is an array of colours to create a gradient, this can change the type/direction of the gradient.\n *\n * @see PIXI.TEXT_GRADIENT\n */\n get: function () {\n return this._fillGradientType;\n },\n set: function (fillGradientType) {\n if (this._fillGradientType !== fillGradientType) {\n this._fillGradientType = fillGradientType;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fillGradientStops\", {\n /**\n * If fill is an array of colours to create a gradient, this array can set the stop points\n * (numbers between 0 and 1) for the color, overriding the default behaviour of evenly spacing them.\n */\n get: function () {\n return this._fillGradientStops;\n },\n set: function (fillGradientStops) {\n if (!areArraysEqual(this._fillGradientStops, fillGradientStops)) {\n this._fillGradientStops = fillGradientStops;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontFamily\", {\n /** The font family. */\n get: function () {\n return this._fontFamily;\n },\n set: function (fontFamily) {\n if (this.fontFamily !== fontFamily) {\n this._fontFamily = fontFamily;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontSize\", {\n /**\n * The font size\n * (as a number it converts to px, but as a string, equivalents are '26px','20pt','160%' or '1.6em')\n */\n get: function () {\n return this._fontSize;\n },\n set: function (fontSize) {\n if (this._fontSize !== fontSize) {\n this._fontSize = fontSize;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontStyle\", {\n /**\n * The font style\n * ('normal', 'italic' or 'oblique')\n *\n * @member {string}\n */\n get: function () {\n return this._fontStyle;\n },\n set: function (fontStyle) {\n if (this._fontStyle !== fontStyle) {\n this._fontStyle = fontStyle;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontVariant\", {\n /**\n * The font variant\n * ('normal' or 'small-caps')\n *\n * @member {string}\n */\n get: function () {\n return this._fontVariant;\n },\n set: function (fontVariant) {\n if (this._fontVariant !== fontVariant) {\n this._fontVariant = fontVariant;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"fontWeight\", {\n /**\n * The font weight\n * ('normal', 'bold', 'bolder', 'lighter' and '100', '200', '300', '400', '500', '600', '700', 800' or '900')\n *\n * @member {string}\n */\n get: function () {\n return this._fontWeight;\n },\n set: function (fontWeight) {\n if (this._fontWeight !== fontWeight) {\n this._fontWeight = fontWeight;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"letterSpacing\", {\n /** The amount of spacing between letters, default is 0. */\n get: function () {\n return this._letterSpacing;\n },\n set: function (letterSpacing) {\n if (this._letterSpacing !== letterSpacing) {\n this._letterSpacing = letterSpacing;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"lineHeight\", {\n /** The line height, a number that represents the vertical space that a letter uses. */\n get: function () {\n return this._lineHeight;\n },\n set: function (lineHeight) {\n if (this._lineHeight !== lineHeight) {\n this._lineHeight = lineHeight;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"leading\", {\n /** The space between lines. */\n get: function () {\n return this._leading;\n },\n set: function (leading) {\n if (this._leading !== leading) {\n this._leading = leading;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"lineJoin\", {\n /**\n * The lineJoin property sets the type of corner created, it can resolve spiked text issues.\n * Default is 'miter' (creates a sharp corner).\n *\n * @member {string}\n */\n get: function () {\n return this._lineJoin;\n },\n set: function (lineJoin) {\n if (this._lineJoin !== lineJoin) {\n this._lineJoin = lineJoin;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"miterLimit\", {\n /**\n * The miter limit to use when using the 'miter' lineJoin mode.\n *\n * This can reduce or increase the spikiness of rendered text.\n */\n get: function () {\n return this._miterLimit;\n },\n set: function (miterLimit) {\n if (this._miterLimit !== miterLimit) {\n this._miterLimit = miterLimit;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"padding\", {\n /**\n * Occasionally some fonts are cropped. Adding some padding will prevent this from happening\n * by adding padding to all sides of the text.\n */\n get: function () {\n return this._padding;\n },\n set: function (padding) {\n if (this._padding !== padding) {\n this._padding = padding;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"stroke\", {\n /**\n * A canvas fillstyle that will be used on the text stroke\n * e.g 'blue', '#FCFF00'\n */\n get: function () {\n return this._stroke;\n },\n set: function (stroke) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n var outputColor = getColor(stroke);\n if (this._stroke !== outputColor) {\n this._stroke = outputColor;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"strokeThickness\", {\n /**\n * A number that represents the thickness of the stroke.\n *\n * @default 0\n */\n get: function () {\n return this._strokeThickness;\n },\n set: function (strokeThickness) {\n if (this._strokeThickness !== strokeThickness) {\n this._strokeThickness = strokeThickness;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"textBaseline\", {\n /**\n * The baseline of the text that is rendered.\n *\n * @member {string}\n */\n get: function () {\n return this._textBaseline;\n },\n set: function (textBaseline) {\n if (this._textBaseline !== textBaseline) {\n this._textBaseline = textBaseline;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"trim\", {\n /** Trim transparent borders. */\n get: function () {\n return this._trim;\n },\n set: function (trim) {\n if (this._trim !== trim) {\n this._trim = trim;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"whiteSpace\", {\n /**\n * How newlines and spaces should be handled.\n * Default is 'pre' (preserve, preserve).\n *\n * value | New lines | Spaces\n * --- | --- | ---\n * 'normal' | Collapse | Collapse\n * 'pre' | Preserve | Preserve\n * 'pre-line' | Preserve | Collapse\n *\n * @member {string}\n */\n get: function () {\n return this._whiteSpace;\n },\n set: function (whiteSpace) {\n if (this._whiteSpace !== whiteSpace) {\n this._whiteSpace = whiteSpace;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"wordWrap\", {\n /** Indicates if word wrap should be used. */\n get: function () {\n return this._wordWrap;\n },\n set: function (wordWrap) {\n if (this._wordWrap !== wordWrap) {\n this._wordWrap = wordWrap;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TextStyle.prototype, \"wordWrapWidth\", {\n /** The width at which text will wrap, it needs wordWrap to be set to true. */\n get: function () {\n return this._wordWrapWidth;\n },\n set: function (wordWrapWidth) {\n if (this._wordWrapWidth !== wordWrapWidth) {\n this._wordWrapWidth = wordWrapWidth;\n this.styleID++;\n }\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Generates a font style string to use for `TextMetrics.measureFont()`.\n *\n * @return Font style string, for passing to `TextMetrics.measureFont()`\n */\n TextStyle.prototype.toFontString = function () {\n // build canvas api font setting from individual components. Convert a numeric this.fontSize to px\n var fontSizeString = (typeof this.fontSize === 'number') ? this.fontSize + \"px\" : this.fontSize;\n // Clean-up fontFamily property by quoting each font name\n // this will support font names with spaces\n var fontFamilies = this.fontFamily;\n if (!Array.isArray(this.fontFamily)) {\n fontFamilies = this.fontFamily.split(',');\n }\n for (var i = fontFamilies.length - 1; i >= 0; i--) {\n // Trim any extra white-space\n var fontFamily = fontFamilies[i].trim();\n // Check if font already contains strings\n if (!(/([\\\"\\'])[^\\'\\\"]+\\1/).test(fontFamily) && genericFontFamilies.indexOf(fontFamily) < 0) {\n fontFamily = \"\\\"\" + fontFamily + \"\\\"\";\n }\n fontFamilies[i] = fontFamily;\n }\n return this.fontStyle + \" \" + this.fontVariant + \" \" + this.fontWeight + \" \" + fontSizeString + \" \" + fontFamilies.join(',');\n };\n return TextStyle;\n}());\n/**\n * Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string.\n * @private\n * @param color\n * @return The color as a string.\n */\nfunction getSingleColor(color) {\n if (typeof color === 'number') {\n return hex2string(color);\n }\n else if (typeof color === 'string') {\n if (color.indexOf('0x') === 0) {\n color = color.replace('0x', '#');\n }\n }\n return color;\n}\nfunction getColor(color) {\n if (!Array.isArray(color)) {\n return getSingleColor(color);\n }\n else {\n for (var i = 0; i < color.length; ++i) {\n color[i] = getSingleColor(color[i]);\n }\n return color;\n }\n}\n/**\n * Utility function to convert hexadecimal colors to strings, and simply return the color if it's a string.\n * This version can also convert array of colors\n * @private\n * @param array1 - First array to compare\n * @param array2 - Second array to compare\n * @return Do the arrays contain the same values in the same order\n */\nfunction areArraysEqual(array1, array2) {\n if (!Array.isArray(array1) || !Array.isArray(array2)) {\n return false;\n }\n if (array1.length !== array2.length) {\n return false;\n }\n for (var i = 0; i < array1.length; ++i) {\n if (array1[i] !== array2[i]) {\n return false;\n }\n }\n return true;\n}\n/**\n * Utility function to ensure that object properties are copied by value, and not by reference\n * @private\n * @param target - Target object to copy properties into\n * @param source - Source object for the properties to copy\n * @param propertyObj - Object containing properties names we want to loop over\n */\nfunction deepCopyProperties(target, source, propertyObj) {\n for (var prop in propertyObj) {\n if (Array.isArray(source[prop])) {\n target[prop] = source[prop].slice();\n }\n else {\n target[prop] = source[prop];\n }\n }\n}\n\n/**\n * The TextMetrics object represents the measurement of a block of text with a specified style.\n *\n * ```js\n * let style = new PIXI.TextStyle({fontFamily : 'Arial', fontSize: 24, fill : 0xff1010, align : 'center'})\n * let textMetrics = PIXI.TextMetrics.measureText('Your text', style)\n * ```\n *\n * @memberof PIXI\n */\nvar TextMetrics = /** @class */ (function () {\n /**\n * @param text - the text that was measured\n * @param style - the style that was measured\n * @param width - the measured width of the text\n * @param height - the measured height of the text\n * @param lines - an array of the lines of text broken by new lines and wrapping if specified in style\n * @param lineWidths - an array of the line widths for each line matched to `lines`\n * @param lineHeight - the measured line height for this style\n * @param maxLineWidth - the maximum line width for all measured lines\n * @param {PIXI.IFontMetrics} fontProperties - the font properties object from TextMetrics.measureFont\n */\n function TextMetrics(text, style, width, height, lines, lineWidths, lineHeight, maxLineWidth, fontProperties) {\n this.text = text;\n this.style = style;\n this.width = width;\n this.height = height;\n this.lines = lines;\n this.lineWidths = lineWidths;\n this.lineHeight = lineHeight;\n this.maxLineWidth = maxLineWidth;\n this.fontProperties = fontProperties;\n }\n /**\n * Measures the supplied string of text and returns a Rectangle.\n *\n * @param text - The text to measure.\n * @param style - The text style to use for measuring\n * @param wordWrap - Override for if word-wrap should be applied to the text.\n * @param canvas - optional specification of the canvas to use for measuring.\n * @return Measured width and height of the text.\n */\n TextMetrics.measureText = function (text, style, wordWrap, canvas) {\n if (canvas === void 0) { canvas = TextMetrics._canvas; }\n wordWrap = (wordWrap === undefined || wordWrap === null) ? style.wordWrap : wordWrap;\n var font = style.toFontString();\n var fontProperties = TextMetrics.measureFont(font);\n // fallback in case UA disallow canvas data extraction\n // (toDataURI, getImageData functions)\n if (fontProperties.fontSize === 0) {\n fontProperties.fontSize = style.fontSize;\n fontProperties.ascent = style.fontSize;\n }\n var context = canvas.getContext('2d');\n context.font = font;\n var outputText = wordWrap ? TextMetrics.wordWrap(text, style, canvas) : text;\n var lines = outputText.split(/(?:\\r\\n|\\r|\\n)/);\n var lineWidths = new Array(lines.length);\n var maxLineWidth = 0;\n for (var i = 0; i < lines.length; i++) {\n var lineWidth = context.measureText(lines[i]).width + ((lines[i].length - 1) * style.letterSpacing);\n lineWidths[i] = lineWidth;\n maxLineWidth = Math.max(maxLineWidth, lineWidth);\n }\n var width = maxLineWidth + style.strokeThickness;\n if (style.dropShadow) {\n width += style.dropShadowDistance;\n }\n var lineHeight = style.lineHeight || fontProperties.fontSize + style.strokeThickness;\n var height = Math.max(lineHeight, fontProperties.fontSize + style.strokeThickness)\n + ((lines.length - 1) * (lineHeight + style.leading));\n if (style.dropShadow) {\n height += style.dropShadowDistance;\n }\n return new TextMetrics(text, style, width, height, lines, lineWidths, lineHeight + style.leading, maxLineWidth, fontProperties);\n };\n /**\n * Applies newlines to a string to have it optimally fit into the horizontal\n * bounds set by the Text object's wordWrapWidth property.\n *\n * @param text - String to apply word wrapping to\n * @param style - the style to use when wrapping\n * @param canvas - optional specification of the canvas to use for measuring.\n * @return New string with new lines applied where required\n */\n TextMetrics.wordWrap = function (text, style, canvas) {\n if (canvas === void 0) { canvas = TextMetrics._canvas; }\n var context = canvas.getContext('2d');\n var width = 0;\n var line = '';\n var lines = '';\n var cache = Object.create(null);\n var letterSpacing = style.letterSpacing, whiteSpace = style.whiteSpace;\n // How to handle whitespaces\n var collapseSpaces = TextMetrics.collapseSpaces(whiteSpace);\n var collapseNewlines = TextMetrics.collapseNewlines(whiteSpace);\n // whether or not spaces may be added to the beginning of lines\n var canPrependSpaces = !collapseSpaces;\n // There is letterSpacing after every char except the last one\n // t_h_i_s_' '_i_s_' '_a_n_' '_e_x_a_m_p_l_e_' '_!\n // so for convenience the above needs to be compared to width + 1 extra letterSpace\n // t_h_i_s_' '_i_s_' '_a_n_' '_e_x_a_m_p_l_e_' '_!_\n // ________________________________________________\n // And then the final space is simply no appended to each line\n var wordWrapWidth = style.wordWrapWidth + letterSpacing;\n // break text into words, spaces and newline chars\n var tokens = TextMetrics.tokenize(text);\n for (var i = 0; i < tokens.length; i++) {\n // get the word, space or newlineChar\n var token = tokens[i];\n // if word is a new line\n if (TextMetrics.isNewline(token)) {\n // keep the new line\n if (!collapseNewlines) {\n lines += TextMetrics.addLine(line);\n canPrependSpaces = !collapseSpaces;\n line = '';\n width = 0;\n continue;\n }\n // if we should collapse new lines\n // we simply convert it into a space\n token = ' ';\n }\n // if we should collapse repeated whitespaces\n if (collapseSpaces) {\n // check both this and the last tokens for spaces\n var currIsBreakingSpace = TextMetrics.isBreakingSpace(token);\n var lastIsBreakingSpace = TextMetrics.isBreakingSpace(line[line.length - 1]);\n if (currIsBreakingSpace && lastIsBreakingSpace) {\n continue;\n }\n }\n // get word width from cache if possible\n var tokenWidth = TextMetrics.getFromCache(token, letterSpacing, cache, context);\n // word is longer than desired bounds\n if (tokenWidth > wordWrapWidth) {\n // if we are not already at the beginning of a line\n if (line !== '') {\n // start newlines for overflow words\n lines += TextMetrics.addLine(line);\n line = '';\n width = 0;\n }\n // break large word over multiple lines\n if (TextMetrics.canBreakWords(token, style.breakWords)) {\n // break word into characters\n var characters = TextMetrics.wordWrapSplit(token);\n // loop the characters\n for (var j = 0; j < characters.length; j++) {\n var char = characters[j];\n var k = 1;\n // we are not at the end of the token\n while (characters[j + k]) {\n var nextChar = characters[j + k];\n var lastChar = char[char.length - 1];\n // should not split chars\n if (!TextMetrics.canBreakChars(lastChar, nextChar, token, j, style.breakWords)) {\n // combine chars & move forward one\n char += nextChar;\n }\n else {\n break;\n }\n k++;\n }\n j += char.length - 1;\n var characterWidth = TextMetrics.getFromCache(char, letterSpacing, cache, context);\n if (characterWidth + width > wordWrapWidth) {\n lines += TextMetrics.addLine(line);\n canPrependSpaces = false;\n line = '';\n width = 0;\n }\n line += char;\n width += characterWidth;\n }\n }\n // run word out of the bounds\n else {\n // if there are words in this line already\n // finish that line and start a new one\n if (line.length > 0) {\n lines += TextMetrics.addLine(line);\n line = '';\n width = 0;\n }\n var isLastToken = i === tokens.length - 1;\n // give it its own line if it's not the end\n lines += TextMetrics.addLine(token, !isLastToken);\n canPrependSpaces = false;\n line = '';\n width = 0;\n }\n }\n // word could fit\n else {\n // word won't fit because of existing words\n // start a new line\n if (tokenWidth + width > wordWrapWidth) {\n // if its a space we don't want it\n canPrependSpaces = false;\n // add a new line\n lines += TextMetrics.addLine(line);\n // start a new line\n line = '';\n width = 0;\n }\n // don't add spaces to the beginning of lines\n if (line.length > 0 || !TextMetrics.isBreakingSpace(token) || canPrependSpaces) {\n // add the word to the current line\n line += token;\n // update width counter\n width += tokenWidth;\n }\n }\n }\n lines += TextMetrics.addLine(line, false);\n return lines;\n };\n /**\n * Convienience function for logging each line added during the wordWrap method.\n *\n * @param line - The line of text to add\n * @param newLine - Add new line character to end\n * @return A formatted line\n */\n TextMetrics.addLine = function (line, newLine) {\n if (newLine === void 0) { newLine = true; }\n line = TextMetrics.trimRight(line);\n line = (newLine) ? line + \"\\n\" : line;\n return line;\n };\n /**\n * Gets & sets the widths of calculated characters in a cache object\n *\n * @param key - The key\n * @param letterSpacing - The letter spacing\n * @param cache - The cache\n * @param context - The canvas context\n * @return The from cache.\n */\n TextMetrics.getFromCache = function (key, letterSpacing, cache, context) {\n var width = cache[key];\n if (typeof width !== 'number') {\n var spacing = ((key.length) * letterSpacing);\n width = context.measureText(key).width + spacing;\n cache[key] = width;\n }\n return width;\n };\n /**\n * Determines whether we should collapse breaking spaces.\n *\n * @param whiteSpace - The TextStyle property whiteSpace\n * @return Should collapse\n */\n TextMetrics.collapseSpaces = function (whiteSpace) {\n return (whiteSpace === 'normal' || whiteSpace === 'pre-line');\n };\n /**\n * Determines whether we should collapse newLine chars.\n *\n * @param whiteSpace - The white space\n * @return should collapse\n */\n TextMetrics.collapseNewlines = function (whiteSpace) {\n return (whiteSpace === 'normal');\n };\n /**\n * Trims breaking whitespaces from string.\n *\n * @param text - The text\n * @return Trimmed string\n */\n TextMetrics.trimRight = function (text) {\n if (typeof text !== 'string') {\n return '';\n }\n for (var i = text.length - 1; i >= 0; i--) {\n var char = text[i];\n if (!TextMetrics.isBreakingSpace(char)) {\n break;\n }\n text = text.slice(0, -1);\n }\n return text;\n };\n /**\n * Determines if char is a newline.\n *\n * @param char - The character\n * @return True if newline, False otherwise.\n */\n TextMetrics.isNewline = function (char) {\n if (typeof char !== 'string') {\n return false;\n }\n return (TextMetrics._newlines.indexOf(char.charCodeAt(0)) >= 0);\n };\n /**\n * Determines if char is a breaking whitespace.\n *\n * It allows one to determine whether char should be a breaking whitespace\n * For example certain characters in CJK langs or numbers.\n * It must return a boolean.\n *\n * @param char - The character\n * @param [nextChar] - The next character\n * @return True if whitespace, False otherwise.\n */\n TextMetrics.isBreakingSpace = function (char, _nextChar) {\n if (typeof char !== 'string') {\n return false;\n }\n return (TextMetrics._breakingSpaces.indexOf(char.charCodeAt(0)) >= 0);\n };\n /**\n * Splits a string into words, breaking-spaces and newLine characters\n *\n * @param text - The text\n * @return A tokenized array\n */\n TextMetrics.tokenize = function (text) {\n var tokens = [];\n var token = '';\n if (typeof text !== 'string') {\n return tokens;\n }\n for (var i = 0; i < text.length; i++) {\n var char = text[i];\n var nextChar = text[i + 1];\n if (TextMetrics.isBreakingSpace(char, nextChar) || TextMetrics.isNewline(char)) {\n if (token !== '') {\n tokens.push(token);\n token = '';\n }\n tokens.push(char);\n continue;\n }\n token += char;\n }\n if (token !== '') {\n tokens.push(token);\n }\n return tokens;\n };\n /**\n * Overridable helper method used internally by TextMetrics, exposed to allow customizing the class's behavior.\n *\n * It allows one to customise which words should break\n * Examples are if the token is CJK or numbers.\n * It must return a boolean.\n *\n * @param token - The token\n * @param breakWords - The style attr break words\n * @return Whether to break word or not\n */\n TextMetrics.canBreakWords = function (_token, breakWords) {\n return breakWords;\n };\n /**\n * Overridable helper method used internally by TextMetrics, exposed to allow customizing the class's behavior.\n *\n * It allows one to determine whether a pair of characters\n * should be broken by newlines\n * For example certain characters in CJK langs or numbers.\n * It must return a boolean.\n *\n * @param char - The character\n * @param nextChar - The next character\n * @param token - The token/word the characters are from\n * @param index - The index in the token of the char\n * @param breakWords - The style attr break words\n * @return whether to break word or not\n */\n TextMetrics.canBreakChars = function (_char, _nextChar, _token, _index, _breakWords) {\n return true;\n };\n /**\n * Overridable helper method used internally by TextMetrics, exposed to allow customizing the class's behavior.\n *\n * It is called when a token (usually a word) has to be split into separate pieces\n * in order to determine the point to break a word.\n * It must return an array of characters.\n *\n * @example\n * // Correctly splits emojis, eg \"🤪🤪\" will result in two element array, each with one emoji.\n * TextMetrics.wordWrapSplit = (token) => [...token];\n *\n * @param token - The token to split\n * @return The characters of the token\n */\n TextMetrics.wordWrapSplit = function (token) {\n return token.split('');\n };\n /**\n * Calculates the ascent, descent and fontSize of a given font-style\n *\n * @param font - String representing the style of the font\n * @return Font properties object\n */\n TextMetrics.measureFont = function (font) {\n // as this method is used for preparing assets, don't recalculate things if we don't need to\n if (TextMetrics._fonts[font]) {\n return TextMetrics._fonts[font];\n }\n var properties = {\n ascent: 0,\n descent: 0,\n fontSize: 0,\n };\n var canvas = TextMetrics._canvas;\n var context = TextMetrics._context;\n context.font = font;\n var metricsString = TextMetrics.METRICS_STRING + TextMetrics.BASELINE_SYMBOL;\n var width = Math.ceil(context.measureText(metricsString).width);\n var baseline = Math.ceil(context.measureText(TextMetrics.BASELINE_SYMBOL).width);\n var height = Math.ceil(TextMetrics.HEIGHT_MULTIPLIER * baseline);\n baseline = baseline * TextMetrics.BASELINE_MULTIPLIER | 0;\n canvas.width = width;\n canvas.height = height;\n context.fillStyle = '#f00';\n context.fillRect(0, 0, width, height);\n context.font = font;\n context.textBaseline = 'alphabetic';\n context.fillStyle = '#000';\n context.fillText(metricsString, 0, baseline);\n var imagedata = context.getImageData(0, 0, width, height).data;\n var pixels = imagedata.length;\n var line = width * 4;\n var i = 0;\n var idx = 0;\n var stop = false;\n // ascent. scan from top to bottom until we find a non red pixel\n for (i = 0; i < baseline; ++i) {\n for (var j = 0; j < line; j += 4) {\n if (imagedata[idx + j] !== 255) {\n stop = true;\n break;\n }\n }\n if (!stop) {\n idx += line;\n }\n else {\n break;\n }\n }\n properties.ascent = baseline - i;\n idx = pixels - line;\n stop = false;\n // descent. scan from bottom to top until we find a non red pixel\n for (i = height; i > baseline; --i) {\n for (var j = 0; j < line; j += 4) {\n if (imagedata[idx + j] !== 255) {\n stop = true;\n break;\n }\n }\n if (!stop) {\n idx -= line;\n }\n else {\n break;\n }\n }\n properties.descent = i - baseline;\n properties.fontSize = properties.ascent + properties.descent;\n TextMetrics._fonts[font] = properties;\n return properties;\n };\n /**\n * Clear font metrics in metrics cache.\n *\n * @param {string} [font] - font name. If font name not set then clear cache for all fonts.\n */\n TextMetrics.clearMetrics = function (font) {\n if (font === void 0) { font = ''; }\n if (font) {\n delete TextMetrics._fonts[font];\n }\n else {\n TextMetrics._fonts = {};\n }\n };\n return TextMetrics;\n}());\n/**\n * Internal return object for {@link PIXI.TextMetrics.measureFont `TextMetrics.measureFont`}.\n *\n * @typedef {object} FontMetrics\n * @property {number} ascent - The ascent distance\n * @property {number} descent - The descent distance\n * @property {number} fontSize - Font size from ascent to descent\n * @memberof PIXI.TextMetrics\n * @private\n */\nvar canvas = (function () {\n try {\n // OffscreenCanvas2D measureText can be up to 40% faster.\n var c = new OffscreenCanvas(0, 0);\n var context = c.getContext('2d');\n if (context && context.measureText) {\n return c;\n }\n return document.createElement('canvas');\n }\n catch (ex) {\n return document.createElement('canvas');\n }\n})();\ncanvas.width = canvas.height = 10;\n/**\n * Cached canvas element for measuring text\n *\n * @memberof PIXI.TextMetrics\n * @type {HTMLCanvasElement}\n * @private\n */\nTextMetrics._canvas = canvas;\n/**\n * Cache for context to use.\n *\n * @memberof PIXI.TextMetrics\n * @type {CanvasRenderingContext2D}\n * @private\n */\nTextMetrics._context = canvas.getContext('2d');\n/**\n * Cache of {@see PIXI.TextMetrics.FontMetrics} objects.\n *\n * @memberof PIXI.TextMetrics\n * @type {Object}\n * @private\n */\nTextMetrics._fonts = {};\n/**\n * String used for calculate font metrics.\n * These characters are all tall to help calculate the height required for text.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name METRICS_STRING\n * @type {string}\n * @default |ÉqÅ\n */\nTextMetrics.METRICS_STRING = '|ÉqÅ';\n/**\n * Baseline symbol for calculate font metrics.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name BASELINE_SYMBOL\n * @type {string}\n * @default M\n */\nTextMetrics.BASELINE_SYMBOL = 'M';\n/**\n * Baseline multiplier for calculate font metrics.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name BASELINE_MULTIPLIER\n * @type {number}\n * @default 1.4\n */\nTextMetrics.BASELINE_MULTIPLIER = 1.4;\n/**\n * Height multiplier for setting height of canvas to calculate font metrics.\n *\n * @static\n * @memberof PIXI.TextMetrics\n * @name HEIGHT_MULTIPLIER\n * @type {number}\n * @default 2.00\n */\nTextMetrics.HEIGHT_MULTIPLIER = 2.0;\n/**\n * Cache of new line chars.\n *\n * @memberof PIXI.TextMetrics\n * @type {number[]}\n * @private\n */\nTextMetrics._newlines = [\n 0x000A,\n 0x000D ];\n/**\n * Cache of breaking spaces.\n *\n * @memberof PIXI.TextMetrics\n * @type {number[]}\n * @private\n */\nTextMetrics._breakingSpaces = [\n 0x0009,\n 0x0020,\n 0x2000,\n 0x2001,\n 0x2002,\n 0x2003,\n 0x2004,\n 0x2005,\n 0x2006,\n 0x2008,\n 0x2009,\n 0x200A,\n 0x205F,\n 0x3000 ];\n/**\n * A number, or a string containing a number.\n *\n * @memberof PIXI\n * @typedef {object} IFontMetrics\n * @property {number} ascent - Font ascent\n * @property {number} descent - Font descent\n * @property {number} fontSize - Font size\n */\n\nvar defaultDestroyOptions = {\n texture: true,\n children: false,\n baseTexture: true,\n};\n/**\n * A Text Object will create a line or multiple lines of text.\n *\n * The text is created using the [Canvas API](https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API).\n *\n * The primary advantage of this class over BitmapText is that you have great control over the style of the text,\n * which you can change at runtime.\n *\n * The primary disadvantages is that each piece of text has it's own texture, which can use more memory.\n * When text changes, this texture has to be re-generated and re-uploaded to the GPU, taking up time.\n *\n * To split a line you can use '\\n' in your text string, or, on the `style` object,\n * change its `wordWrap` property to true and and give the `wordWrapWidth` property a value.\n *\n * A Text can be created directly from a string and a style object,\n * which can be generated [here](https://pixijs.io/pixi-text-style).\n *\n * ```js\n * let text = new PIXI.Text('This is a PixiJS text',{fontFamily : 'Arial', fontSize: 24, fill : 0xff1010, align : 'center'});\n * ```\n *\n * @memberof PIXI\n */\nvar Text = /** @class */ (function (_super) {\n __extends(Text, _super);\n /**\n * @param text - The string that you would like the text to display\n * @param {object|PIXI.TextStyle} [style] - The style parameters\n * @param canvas - The canvas element for drawing text\n */\n function Text(text, style, canvas) {\n var _this = this;\n var ownCanvas = false;\n if (!canvas) {\n canvas = document.createElement('canvas');\n ownCanvas = true;\n }\n canvas.width = 3;\n canvas.height = 3;\n var texture = Texture.from(canvas);\n texture.orig = new Rectangle();\n texture.trim = new Rectangle();\n _this = _super.call(this, texture) || this;\n _this._ownCanvas = ownCanvas;\n _this.canvas = canvas;\n _this.context = _this.canvas.getContext('2d');\n _this._resolution = settings.RESOLUTION;\n _this._autoResolution = true;\n _this._text = null;\n _this._style = null;\n _this._styleListener = null;\n _this._font = '';\n _this.text = text;\n _this.style = style;\n _this.localStyleID = -1;\n return _this;\n }\n /**\n * Renders text to its canvas, and updates its texture.\n *\n * By default this is used internally to ensure the texture is correct before rendering,\n * but it can be used called externally, for example from this class to 'pre-generate' the texture from a piece of text,\n * and then shared across multiple Sprites.\n *\n * @param respectDirty - Whether to abort updating the text if the Text isn't dirty and the function is called.\n */\n Text.prototype.updateText = function (respectDirty) {\n var style = this._style;\n // check if style has changed..\n if (this.localStyleID !== style.styleID) {\n this.dirty = true;\n this.localStyleID = style.styleID;\n }\n if (!this.dirty && respectDirty) {\n return;\n }\n this._font = this._style.toFontString();\n var context = this.context;\n var measured = TextMetrics.measureText(this._text || ' ', this._style, this._style.wordWrap, this.canvas);\n var width = measured.width;\n var height = measured.height;\n var lines = measured.lines;\n var lineHeight = measured.lineHeight;\n var lineWidths = measured.lineWidths;\n var maxLineWidth = measured.maxLineWidth;\n var fontProperties = measured.fontProperties;\n this.canvas.width = Math.ceil(Math.ceil((Math.max(1, width) + (style.padding * 2))) * this._resolution);\n this.canvas.height = Math.ceil(Math.ceil((Math.max(1, height) + (style.padding * 2))) * this._resolution);\n context.scale(this._resolution, this._resolution);\n context.clearRect(0, 0, this.canvas.width, this.canvas.height);\n context.font = this._font;\n context.lineWidth = style.strokeThickness;\n context.textBaseline = style.textBaseline;\n context.lineJoin = style.lineJoin;\n context.miterLimit = style.miterLimit;\n var linePositionX;\n var linePositionY;\n // require 2 passes if a shadow; the first to draw the drop shadow, the second to draw the text\n var passesCount = style.dropShadow ? 2 : 1;\n // For v4, we drew text at the colours of the drop shadow underneath the normal text. This gave the correct zIndex,\n // but features such as alpha and shadowblur did not look right at all, since we were using actual text as a shadow.\n //\n // For v5.0.0, we moved over to just use the canvas API for drop shadows, which made them look much nicer and more\n // visually please, but now because the stroke is drawn and then the fill, drop shadows would appear on both the fill\n // and the stroke; and fill drop shadows would appear over the top of the stroke.\n //\n // For v5.1.1, the new route is to revert to v4 style of drawing text first to get the drop shadows underneath normal\n // text, but instead drawing text in the correct location, we'll draw it off screen (-paddingY), and then adjust the\n // drop shadow so only that appears on screen (+paddingY). Now we'll have the correct draw order of the shadow\n // beneath the text, whilst also having the proper text shadow styling.\n for (var i = 0; i < passesCount; ++i) {\n var isShadowPass = style.dropShadow && i === 0;\n // we only want the drop shadow, so put text way off-screen\n var dsOffsetText = isShadowPass ? Math.ceil(Math.max(1, height) + (style.padding * 2)) : 0;\n var dsOffsetShadow = dsOffsetText * this._resolution;\n if (isShadowPass) {\n // On Safari, text with gradient and drop shadows together do not position correctly\n // if the scale of the canvas is not 1: https://bugs.webkit.org/show_bug.cgi?id=197689\n // Therefore we'll set the styles to be a plain black whilst generating this drop shadow\n context.fillStyle = 'black';\n context.strokeStyle = 'black';\n var dropShadowColor = style.dropShadowColor;\n var rgb = hex2rgb(typeof dropShadowColor === 'number' ? dropShadowColor : string2hex(dropShadowColor));\n var dropShadowBlur = style.dropShadowBlur * this._resolution;\n var dropShadowDistance = style.dropShadowDistance * this._resolution;\n context.shadowColor = \"rgba(\" + rgb[0] * 255 + \",\" + rgb[1] * 255 + \",\" + rgb[2] * 255 + \",\" + style.dropShadowAlpha + \")\";\n context.shadowBlur = dropShadowBlur;\n context.shadowOffsetX = Math.cos(style.dropShadowAngle) * dropShadowDistance;\n context.shadowOffsetY = (Math.sin(style.dropShadowAngle) * dropShadowDistance) + dsOffsetShadow;\n }\n else {\n // set canvas text styles\n context.fillStyle = this._generateFillStyle(style, lines, measured);\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n context.strokeStyle = style.stroke;\n context.shadowColor = 'black';\n context.shadowBlur = 0;\n context.shadowOffsetX = 0;\n context.shadowOffsetY = 0;\n }\n var linePositionYShift = (lineHeight - fontProperties.fontSize) / 2;\n if (!Text.nextLineHeightBehavior || lineHeight - fontProperties.fontSize < 0) {\n linePositionYShift = 0;\n }\n // draw lines line by line\n for (var i_1 = 0; i_1 < lines.length; i_1++) {\n linePositionX = style.strokeThickness / 2;\n linePositionY = ((style.strokeThickness / 2) + (i_1 * lineHeight)) + fontProperties.ascent\n + linePositionYShift;\n if (style.align === 'right') {\n linePositionX += maxLineWidth - lineWidths[i_1];\n }\n else if (style.align === 'center') {\n linePositionX += (maxLineWidth - lineWidths[i_1]) / 2;\n }\n if (style.stroke && style.strokeThickness) {\n this.drawLetterSpacing(lines[i_1], linePositionX + style.padding, linePositionY + style.padding - dsOffsetText, true);\n }\n if (style.fill) {\n this.drawLetterSpacing(lines[i_1], linePositionX + style.padding, linePositionY + style.padding - dsOffsetText);\n }\n }\n }\n this.updateTexture();\n };\n /**\n * Render the text with letter-spacing.\n *\n * @param text - The text to draw\n * @param x - Horizontal position to draw the text\n * @param y - Vertical position to draw the text\n * @param isStroke - Is this drawing for the outside stroke of the\n * text? If not, it's for the inside fill\n */\n Text.prototype.drawLetterSpacing = function (text, x, y, isStroke) {\n if (isStroke === void 0) { isStroke = false; }\n var style = this._style;\n // letterSpacing of 0 means normal\n var letterSpacing = style.letterSpacing;\n // Checking that we can use moddern canvas2D api\n // https://developer.chrome.com/origintrials/#/view_trial/3585991203293757441\n // note: this is unstable API, Chrome less 94 use a `textLetterSpacing`, newest use a letterSpacing\n // eslint-disable-next-line max-len\n var supportLetterSpacing = Text.experimentalLetterSpacing\n && ('letterSpacing' in CanvasRenderingContext2D.prototype\n || 'textLetterSpacing' in CanvasRenderingContext2D.prototype);\n if (letterSpacing === 0 || supportLetterSpacing) {\n if (supportLetterSpacing) {\n this.context.letterSpacing = letterSpacing;\n this.context.textLetterSpacing = letterSpacing;\n }\n if (isStroke) {\n this.context.strokeText(text, x, y);\n }\n else {\n this.context.fillText(text, x, y);\n }\n return;\n }\n var currentPosition = x;\n // Using Array.from correctly splits characters whilst keeping emoji together.\n // This is not supported on IE as it requires ES6, so regular text splitting occurs.\n // This also doesn't account for emoji that are multiple emoji put together to make something else.\n // Handling all of this would require a big library itself.\n // https://medium.com/@giltayar/iterating-over-emoji-characters-the-es6-way-f06e4589516\n // https://github.com/orling/grapheme-splitter\n var stringArray = Array.from ? Array.from(text) : text.split('');\n var previousWidth = this.context.measureText(text).width;\n var currentWidth = 0;\n for (var i = 0; i < stringArray.length; ++i) {\n var currentChar = stringArray[i];\n if (isStroke) {\n this.context.strokeText(currentChar, currentPosition, y);\n }\n else {\n this.context.fillText(currentChar, currentPosition, y);\n }\n var textStr = '';\n for (var j = i + 1; j < stringArray.length; ++j) {\n textStr += stringArray[j];\n }\n currentWidth = this.context.measureText(textStr).width;\n currentPosition += previousWidth - currentWidth + letterSpacing;\n previousWidth = currentWidth;\n }\n };\n /** Updates texture size based on canvas size. */\n Text.prototype.updateTexture = function () {\n var canvas = this.canvas;\n if (this._style.trim) {\n var trimmed = trimCanvas(canvas);\n if (trimmed.data) {\n canvas.width = trimmed.width;\n canvas.height = trimmed.height;\n this.context.putImageData(trimmed.data, 0, 0);\n }\n }\n var texture = this._texture;\n var style = this._style;\n var padding = style.trim ? 0 : style.padding;\n var baseTexture = texture.baseTexture;\n texture.trim.width = texture._frame.width = canvas.width / this._resolution;\n texture.trim.height = texture._frame.height = canvas.height / this._resolution;\n texture.trim.x = -padding;\n texture.trim.y = -padding;\n texture.orig.width = texture._frame.width - (padding * 2);\n texture.orig.height = texture._frame.height - (padding * 2);\n // call sprite onTextureUpdate to update scale if _width or _height were set\n this._onTextureUpdate();\n baseTexture.setRealSize(canvas.width, canvas.height, this._resolution);\n texture.updateUvs();\n // Recursively updates transform of all objects from the root to this one\n this._recursivePostUpdateTransform();\n this.dirty = false;\n };\n /**\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The renderer\n */\n Text.prototype._render = function (renderer) {\n if (this._autoResolution && this._resolution !== renderer.resolution) {\n this._resolution = renderer.resolution;\n this.dirty = true;\n }\n this.updateText(true);\n _super.prototype._render.call(this, renderer);\n };\n /**\n * Gets the local bounds of the text object.\n *\n * @param rect - The output rectangle.\n * @return The bounds.\n */\n Text.prototype.getLocalBounds = function (rect) {\n this.updateText(true);\n return _super.prototype.getLocalBounds.call(this, rect);\n };\n /** Calculates the bounds of the Text as a rectangle. The bounds calculation takes the worldTransform into account. */\n Text.prototype._calculateBounds = function () {\n this.updateText(true);\n this.calculateVertices();\n // if we have already done this on THIS frame.\n this._bounds.addQuad(this.vertexData);\n };\n /**\n * Generates the fill style. Can automatically generate a gradient based on the fill style being an array\n *\n * @param style - The style.\n * @param lines - The lines of text.\n * @return The fill style\n */\n Text.prototype._generateFillStyle = function (style, lines, metrics) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n var fillStyle = style.fill;\n if (!Array.isArray(fillStyle)) {\n return fillStyle;\n }\n else if (fillStyle.length === 1) {\n return fillStyle[0];\n }\n // the gradient will be evenly spaced out according to how large the array is.\n // ['#FF0000', '#00FF00', '#0000FF'] would created stops at 0.25, 0.5 and 0.75\n var gradient;\n // a dropshadow will enlarge the canvas and result in the gradient being\n // generated with the incorrect dimensions\n var dropShadowCorrection = (style.dropShadow) ? style.dropShadowDistance : 0;\n // should also take padding into account, padding can offset the gradient\n var padding = style.padding || 0;\n var width = (this.canvas.width / this._resolution) - dropShadowCorrection - (padding * 2);\n var height = (this.canvas.height / this._resolution) - dropShadowCorrection - (padding * 2);\n // make a copy of the style settings, so we can manipulate them later\n var fill = fillStyle.slice();\n var fillGradientStops = style.fillGradientStops.slice();\n // wanting to evenly distribute the fills. So an array of 4 colours should give fills of 0.25, 0.5 and 0.75\n if (!fillGradientStops.length) {\n var lengthPlus1 = fill.length + 1;\n for (var i = 1; i < lengthPlus1; ++i) {\n fillGradientStops.push(i / lengthPlus1);\n }\n }\n // stop the bleeding of the last gradient on the line above to the top gradient of the this line\n // by hard defining the first gradient colour at point 0, and last gradient colour at point 1\n fill.unshift(fillStyle[0]);\n fillGradientStops.unshift(0);\n fill.push(fillStyle[fillStyle.length - 1]);\n fillGradientStops.push(1);\n if (style.fillGradientType === TEXT_GRADIENT.LINEAR_VERTICAL) {\n // start the gradient at the top center of the canvas, and end at the bottom middle of the canvas\n gradient = this.context.createLinearGradient(width / 2, padding, width / 2, height + padding);\n // we need to repeat the gradient so that each individual line of text has the same vertical gradient effect\n // ['#FF0000', '#00FF00', '#0000FF'] over 2 lines would create stops at 0.125, 0.25, 0.375, 0.625, 0.75, 0.875\n // Actual height of the text itself, not counting spacing for lineHeight/leading/dropShadow etc\n var textHeight = metrics.fontProperties.fontSize + style.strokeThickness;\n for (var i = 0; i < lines.length; i++) {\n var lastLineBottom = (metrics.lineHeight * (i - 1)) + textHeight;\n var thisLineTop = metrics.lineHeight * i;\n var thisLineGradientStart = thisLineTop;\n // Handle case where last & this line overlap\n if (i > 0 && lastLineBottom > thisLineTop) {\n thisLineGradientStart = (thisLineTop + lastLineBottom) / 2;\n }\n var thisLineBottom = thisLineTop + textHeight;\n var nextLineTop = metrics.lineHeight * (i + 1);\n var thisLineGradientEnd = thisLineBottom;\n // Handle case where this & next line overlap\n if (i + 1 < lines.length && nextLineTop < thisLineBottom) {\n thisLineGradientEnd = (thisLineBottom + nextLineTop) / 2;\n }\n // textHeight, but as a 0-1 size in global gradient stop space\n var gradStopLineHeight = (thisLineGradientEnd - thisLineGradientStart) / height;\n for (var j = 0; j < fill.length; j++) {\n // 0-1 stop point for the current line, multiplied to global space afterwards\n var lineStop = 0;\n if (typeof fillGradientStops[j] === 'number') {\n lineStop = fillGradientStops[j];\n }\n else {\n lineStop = j / fill.length;\n }\n var globalStop = Math.min(1, Math.max(0, (thisLineGradientStart / height) + (lineStop * gradStopLineHeight)));\n // There's potential for floating point precision issues at the seams between gradient repeats.\n globalStop = Number(globalStop.toFixed(5));\n gradient.addColorStop(globalStop, fill[j]);\n }\n }\n }\n else {\n // start the gradient at the center left of the canvas, and end at the center right of the canvas\n gradient = this.context.createLinearGradient(padding, height / 2, width + padding, height / 2);\n // can just evenly space out the gradients in this case, as multiple lines makes no difference\n // to an even left to right gradient\n var totalIterations = fill.length + 1;\n var currentIteration = 1;\n for (var i = 0; i < fill.length; i++) {\n var stop = void 0;\n if (typeof fillGradientStops[i] === 'number') {\n stop = fillGradientStops[i];\n }\n else {\n stop = currentIteration / totalIterations;\n }\n gradient.addColorStop(stop, fill[i]);\n currentIteration++;\n }\n }\n return gradient;\n };\n /**\n * Destroys this text object.\n *\n * Note* Unlike a Sprite, a Text object will automatically destroy its baseTexture and texture as\n * the majority of the time the texture will not be shared with any other Sprites.\n *\n * @param options - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their\n * destroy method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=true] - Should it destroy the current texture of the sprite as well\n * @param {boolean} [options.baseTexture=true] - Should it destroy the base texture of the sprite as well\n */\n Text.prototype.destroy = function (options) {\n if (typeof options === 'boolean') {\n options = { children: options };\n }\n options = Object.assign({}, defaultDestroyOptions, options);\n _super.prototype.destroy.call(this, options);\n // set canvas width and height to 0 to workaround memory leak in Safari < 13\n // https://stackoverflow.com/questions/52532614/total-canvas-memory-use-exceeds-the-maximum-limit-safari-12\n if (this._ownCanvas) {\n this.canvas.height = this.canvas.width = 0;\n }\n // make sure to reset the context and canvas.. dont want this hanging around in memory!\n this.context = null;\n this.canvas = null;\n this._style = null;\n };\n Object.defineProperty(Text.prototype, \"width\", {\n /** The width of the Text, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n this.updateText(true);\n return Math.abs(this.scale.x) * this._texture.orig.width;\n },\n set: function (value) {\n this.updateText(true);\n var s = sign(this.scale.x) || 1;\n this.scale.x = s * value / this._texture.orig.width;\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"height\", {\n /** The height of the Text, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n this.updateText(true);\n return Math.abs(this.scale.y) * this._texture.orig.height;\n },\n set: function (value) {\n this.updateText(true);\n var s = sign(this.scale.y) || 1;\n this.scale.y = s * value / this._texture.orig.height;\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"style\", {\n /**\n * Set the style of the text.\n *\n * Set up an event listener to listen for changes on the style object and mark the text as dirty.\n */\n get: function () {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the ITextStyle\n // since the setter creates the TextStyle. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n return this._style;\n },\n set: function (style) {\n style = style || {};\n if (style instanceof TextStyle) {\n this._style = style;\n }\n else {\n this._style = new TextStyle(style);\n }\n this.localStyleID = -1;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"text\", {\n /** Set the copy for the text object. To split a line you can use '\\n'. */\n get: function () {\n return this._text;\n },\n set: function (text) {\n text = String(text === null || text === undefined ? '' : text);\n if (this._text === text) {\n return;\n }\n this._text = text;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Text.prototype, \"resolution\", {\n /**\n * The resolution / device pixel ratio of the canvas.\n *\n * This is set to automatically match the renderer resolution by default, but can be overridden by setting manually.\n *\n * @default 1\n */\n get: function () {\n return this._resolution;\n },\n set: function (value) {\n this._autoResolution = false;\n if (this._resolution === value) {\n return;\n }\n this._resolution = value;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * New behavior for `lineHeight` that's meant to mimic HTML text. A value of `true` will\n * make sure the first baseline is offset by the `lineHeight` value if it is greater than `fontSize`.\n * A value of `false` will use the legacy behavior and not change the baseline of the first line.\n * In the next major release, we'll enable this by default.\n */\n Text.nextLineHeightBehavior = false;\n /**\n * New rendering behavior for letter-spacing which uses Chrome's new native API. This will\n * lead to more accurate letter-spacing results because it does not try to manually draw\n * each character. However, this Chrome API is experimental and may not serve all cases yet.\n */\n Text.experimentalLetterSpacing = false;\n return Text;\n}(Sprite));\n\nexport { TEXT_GRADIENT, Text, TextMetrics, TextStyle };\n//# sourceMappingURL=text.js.map\n","/*!\n * @pixi/prepare - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/prepare is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { settings } from '@pixi/settings';\nimport { Texture, BaseTexture } from '@pixi/core';\nimport { Graphics } from '@pixi/graphics';\nimport { Ticker, UPDATE_PRIORITY } from '@pixi/ticker';\nimport { Container } from '@pixi/display';\nimport { Text, TextStyle, TextMetrics } from '@pixi/text';\n\n/**\n * Default number of uploads per frame using prepare plugin.\n *\n * @static\n * @memberof PIXI.settings\n * @name UPLOADS_PER_FRAME\n * @type {number}\n * @default 4\n */\nsettings.UPLOADS_PER_FRAME = 4;\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * CountLimiter limits the number of items handled by a {@link PIXI.BasePrepare} to a specified\n * number of items per frame.\n *\n * @memberof PIXI\n */\nvar CountLimiter = /** @class */ (function () {\n /**\n * @param maxItemsPerFrame - The maximum number of items that can be prepared each frame.\n */\n function CountLimiter(maxItemsPerFrame) {\n this.maxItemsPerFrame = maxItemsPerFrame;\n this.itemsLeft = 0;\n }\n /** Resets any counting properties to start fresh on a new frame. */\n CountLimiter.prototype.beginFrame = function () {\n this.itemsLeft = this.maxItemsPerFrame;\n };\n /**\n * Checks to see if another item can be uploaded. This should only be called once per item.\n *\n * @return If the item is allowed to be uploaded.\n */\n CountLimiter.prototype.allowedToUpload = function () {\n return this.itemsLeft-- > 0;\n };\n return CountLimiter;\n}());\n\n/**\n * Built-in hook to find multiple textures from objects like AnimatedSprites.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.Texture object was found.\n */\nfunction findMultipleBaseTextures(item, queue) {\n var result = false;\n // Objects with multiple textures\n if (item && item._textures && item._textures.length) {\n for (var i = 0; i < item._textures.length; i++) {\n if (item._textures[i] instanceof Texture) {\n var baseTexture = item._textures[i].baseTexture;\n if (queue.indexOf(baseTexture) === -1) {\n queue.push(baseTexture);\n result = true;\n }\n }\n }\n }\n return result;\n}\n/**\n * Built-in hook to find BaseTextures from Texture.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.Texture object was found.\n */\nfunction findBaseTexture(item, queue) {\n if (item.baseTexture instanceof BaseTexture) {\n var texture = item.baseTexture;\n if (queue.indexOf(texture) === -1) {\n queue.push(texture);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to find textures from objects.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.Texture object was found.\n */\nfunction findTexture(item, queue) {\n if (item._texture && item._texture instanceof Texture) {\n var texture = item._texture.baseTexture;\n if (queue.indexOf(texture) === -1) {\n queue.push(texture);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to draw PIXI.Text to its texture.\n *\n * @private\n * @param helper - Not used by this upload handler\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction drawText(_helper, item) {\n if (item instanceof Text) {\n // updating text will return early if it is not dirty\n item.updateText(true);\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to calculate a text style for a PIXI.Text object.\n *\n * @private\n * @param helper - Not used by this upload handler\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction calculateTextStyle(_helper, item) {\n if (item instanceof TextStyle) {\n var font = item.toFontString();\n TextMetrics.measureFont(font);\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to find Text objects.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return if a PIXI.Text object was found.\n */\nfunction findText(item, queue) {\n if (item instanceof Text) {\n // push the text style to prepare it - this can be really expensive\n if (queue.indexOf(item.style) === -1) {\n queue.push(item.style);\n }\n // also push the text object so that we can render it (to canvas/texture) if needed\n if (queue.indexOf(item) === -1) {\n queue.push(item);\n }\n // also push the Text's texture for upload to GPU\n var texture = item._texture.baseTexture;\n if (queue.indexOf(texture) === -1) {\n queue.push(texture);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to find TextStyle objects.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return If a PIXI.TextStyle object was found.\n */\nfunction findTextStyle(item, queue) {\n if (item instanceof TextStyle) {\n if (queue.indexOf(item) === -1) {\n queue.push(item);\n }\n return true;\n }\n return false;\n}\n/**\n * The prepare manager provides functionality to upload content to the GPU.\n *\n * BasePrepare handles basic queuing functionality and is extended by\n * {@link PIXI.Prepare} and {@link PIXI.CanvasPrepare}\n * to provide preparation capabilities specific to their respective renderers.\n *\n * @example\n * // Create a sprite\n * const sprite = PIXI.Sprite.from('something.png');\n *\n * // Load object into GPU\n * app.renderer.plugins.prepare.upload(sprite, () => {\n *\n * //Texture(s) has been uploaded to GPU\n * app.stage.addChild(sprite);\n *\n * })\n *\n * @abstract\n * @memberof PIXI\n */\nvar BasePrepare = /** @class */ (function () {\n /**\n * @param {PIXI.AbstractRenderer} renderer - A reference to the current renderer\n */\n function BasePrepare(renderer) {\n var _this = this;\n this.limiter = new CountLimiter(settings.UPLOADS_PER_FRAME);\n this.renderer = renderer;\n this.uploadHookHelper = null;\n this.queue = [];\n this.addHooks = [];\n this.uploadHooks = [];\n this.completes = [];\n this.ticking = false;\n this.delayedTick = function () {\n // unlikely, but in case we were destroyed between tick() and delayedTick()\n if (!_this.queue) {\n return;\n }\n _this.prepareItems();\n };\n // hooks to find the correct texture\n this.registerFindHook(findText);\n this.registerFindHook(findTextStyle);\n this.registerFindHook(findMultipleBaseTextures);\n this.registerFindHook(findBaseTexture);\n this.registerFindHook(findTexture);\n // upload hooks\n this.registerUploadHook(drawText);\n this.registerUploadHook(calculateTextStyle);\n }\n /**\n * Upload all the textures and graphics to the GPU.\n *\n * @param {Function|PIXI.DisplayObject|PIXI.Container|PIXI.BaseTexture|PIXI.Texture|PIXI.Graphics|PIXI.Text} item -\n * Either the container or display object to search for items to upload, the items to upload themselves,\n * or the callback function, if items have been added using `prepare.add`.\n * @param {Function} [done] - Optional callback when all queued uploads have completed\n */\n BasePrepare.prototype.upload = function (item, done) {\n if (typeof item === 'function') {\n done = item;\n item = null;\n }\n // If a display object, search for items\n // that we could upload\n if (item) {\n this.add(item);\n }\n // Get the items for upload from the display\n if (this.queue.length) {\n if (done) {\n this.completes.push(done);\n }\n if (!this.ticking) {\n this.ticking = true;\n Ticker.system.addOnce(this.tick, this, UPDATE_PRIORITY.UTILITY);\n }\n }\n else if (done) {\n done();\n }\n };\n /**\n * Handle tick update\n *\n * @private\n */\n BasePrepare.prototype.tick = function () {\n setTimeout(this.delayedTick, 0);\n };\n /**\n * Actually prepare items. This is handled outside of the tick because it will take a while\n * and we do NOT want to block the current animation frame from rendering.\n *\n * @private\n */\n BasePrepare.prototype.prepareItems = function () {\n this.limiter.beginFrame();\n // Upload the graphics\n while (this.queue.length && this.limiter.allowedToUpload()) {\n var item = this.queue[0];\n var uploaded = false;\n if (item && !item._destroyed) {\n for (var i = 0, len = this.uploadHooks.length; i < len; i++) {\n if (this.uploadHooks[i](this.uploadHookHelper, item)) {\n this.queue.shift();\n uploaded = true;\n break;\n }\n }\n }\n if (!uploaded) {\n this.queue.shift();\n }\n }\n // We're finished\n if (!this.queue.length) {\n this.ticking = false;\n var completes = this.completes.slice(0);\n this.completes.length = 0;\n for (var i = 0, len = completes.length; i < len; i++) {\n completes[i]();\n }\n }\n else {\n // if we are not finished, on the next rAF do this again\n Ticker.system.addOnce(this.tick, this, UPDATE_PRIORITY.UTILITY);\n }\n };\n /**\n * Adds hooks for finding items.\n *\n * @param {Function} addHook - Function call that takes two parameters: `item:*, queue:Array`\n * function must return `true` if it was able to add item to the queue.\n * @return Instance of plugin for chaining.\n */\n BasePrepare.prototype.registerFindHook = function (addHook) {\n if (addHook) {\n this.addHooks.push(addHook);\n }\n return this;\n };\n /**\n * Adds hooks for uploading items.\n *\n * @param {Function} uploadHook - Function call that takes two parameters: `prepare:CanvasPrepare, item:*` and\n * function must return `true` if it was able to handle upload of item.\n * @return Instance of plugin for chaining.\n */\n BasePrepare.prototype.registerUploadHook = function (uploadHook) {\n if (uploadHook) {\n this.uploadHooks.push(uploadHook);\n }\n return this;\n };\n /**\n * Manually add an item to the uploading queue.\n *\n * @param {PIXI.DisplayObject|PIXI.Container|PIXI.BaseTexture|PIXI.Texture|PIXI.Graphics|PIXI.Text|*} item - Object to\n * add to the queue\n * @return Instance of plugin for chaining.\n */\n BasePrepare.prototype.add = function (item) {\n // Add additional hooks for finding elements on special\n // types of objects that\n for (var i = 0, len = this.addHooks.length; i < len; i++) {\n if (this.addHooks[i](item, this.queue)) {\n break;\n }\n }\n // Get children recursively\n if (item instanceof Container) {\n for (var i = item.children.length - 1; i >= 0; i--) {\n this.add(item.children[i]);\n }\n }\n return this;\n };\n /** Destroys the plugin, don't use after this. */\n BasePrepare.prototype.destroy = function () {\n if (this.ticking) {\n Ticker.system.remove(this.tick, this);\n }\n this.ticking = false;\n this.addHooks = null;\n this.uploadHooks = null;\n this.renderer = null;\n this.completes = null;\n this.queue = null;\n this.limiter = null;\n this.uploadHookHelper = null;\n };\n return BasePrepare;\n}());\n\n/**\n * Built-in hook to upload PIXI.Texture objects to the GPU.\n *\n * @private\n * @param renderer - instance of the webgl renderer\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction uploadBaseTextures(renderer, item) {\n if (item instanceof BaseTexture) {\n // if the texture already has a GL texture, then the texture has been prepared or rendered\n // before now. If the texture changed, then the changer should be calling texture.update() which\n // reuploads the texture without need for preparing it again\n if (!item._glTextures[renderer.CONTEXT_UID]) {\n renderer.texture.bind(item);\n }\n return true;\n }\n return false;\n}\n/**\n * Built-in hook to upload PIXI.Graphics to the GPU.\n *\n * @private\n * @param renderer - instance of the webgl renderer\n * @param item - Item to check\n * @return If item was uploaded.\n */\nfunction uploadGraphics(renderer, item) {\n if (!(item instanceof Graphics)) {\n return false;\n }\n var geometry = item.geometry;\n // update dirty graphics to get batches\n item.finishPoly();\n geometry.updateBatches();\n var batches = geometry.batches;\n // upload all textures found in styles\n for (var i = 0; i < batches.length; i++) {\n var texture = batches[i].style.texture;\n if (texture) {\n uploadBaseTextures(renderer, texture.baseTexture);\n }\n }\n // if its not batchable - update vao for particular shader\n if (!geometry.batchable) {\n renderer.geometry.bind(geometry, item._resolveDirectShader(renderer));\n }\n return true;\n}\n/**\n * Built-in hook to find graphics.\n *\n * @private\n * @param item - Display object to check\n * @param queue - Collection of items to upload\n * @return if a PIXI.Graphics object was found.\n */\nfunction findGraphics(item, queue) {\n if (item instanceof Graphics) {\n queue.push(item);\n return true;\n }\n return false;\n}\n/**\n * The prepare plugin provides renderer-specific plugins for pre-rendering DisplayObjects. These plugins are useful for\n * asynchronously preparing and uploading to the GPU assets, textures, graphics waiting to be displayed.\n *\n * Do not instantiate this plugin directly. It is available from the `renderer.plugins` property.\n * See {@link PIXI.CanvasRenderer#plugins} or {@link PIXI.Renderer#plugins}.\n * @example\n * // Create a new application\n * const app = new PIXI.Application();\n * document.body.appendChild(app.view);\n *\n * // Don't start rendering right away\n * app.stop();\n *\n * // create a display object\n * const rect = new PIXI.Graphics()\n * .beginFill(0x00ff00)\n * .drawRect(40, 40, 200, 200);\n *\n * // Add to the stage\n * app.stage.addChild(rect);\n *\n * // Don't start rendering until the graphic is uploaded to the GPU\n * app.renderer.plugins.prepare.upload(app.stage, () => {\n * app.start();\n * });\n *\n *\n * @memberof PIXI\n */\nvar Prepare = /** @class */ (function (_super) {\n __extends(Prepare, _super);\n /**\n * @param {PIXI.Renderer} renderer - A reference to the current renderer\n */\n function Prepare(renderer) {\n var _this = _super.call(this, renderer) || this;\n _this.uploadHookHelper = _this.renderer;\n // Add textures and graphics to upload\n _this.registerFindHook(findGraphics);\n _this.registerUploadHook(uploadBaseTextures);\n _this.registerUploadHook(uploadGraphics);\n return _this;\n }\n return Prepare;\n}(BasePrepare));\n\n/**\n * TimeLimiter limits the number of items handled by a {@link PIXI.BasePrepare} to a specified\n * number of milliseconds per frame.\n *\n * @memberof PIXI\n */\nvar TimeLimiter = /** @class */ (function () {\n /** @param maxMilliseconds - The maximum milliseconds that can be spent preparing items each frame. */\n function TimeLimiter(maxMilliseconds) {\n this.maxMilliseconds = maxMilliseconds;\n this.frameStart = 0;\n }\n /** Resets any counting properties to start fresh on a new frame. */\n TimeLimiter.prototype.beginFrame = function () {\n this.frameStart = Date.now();\n };\n /**\n * Checks to see if another item can be uploaded. This should only be called once per item.\n *\n * @return - If the item is allowed to be uploaded.\n */\n TimeLimiter.prototype.allowedToUpload = function () {\n return Date.now() - this.frameStart < this.maxMilliseconds;\n };\n return TimeLimiter;\n}());\n\nexport { BasePrepare, CountLimiter, Prepare, TimeLimiter };\n//# sourceMappingURL=prepare.js.map\n","/*!\n * @pixi/spritesheet - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/spritesheet is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Rectangle } from '@pixi/math';\nimport { Texture, BaseTexture } from '@pixi/core';\nimport { getResolutionOfUrl, url } from '@pixi/utils';\nimport { LoaderResource } from '@pixi/loaders';\n\n/**\n * Utility class for maintaining reference to a collection\n * of Textures on a single Spritesheet.\n *\n * To access a sprite sheet from your code pass its JSON data file to Pixi's loader:\n *\n * ```js\n * PIXI.Loader.shared.add(\"images/spritesheet.json\").load(setup);\n *\n * function setup() {\n * let sheet = PIXI.Loader.shared.resources[\"images/spritesheet.json\"].spritesheet;\n * ...\n * }\n * ```\n * With the `sheet.textures` you can create Sprite objects,`sheet.animations` can be used to create an AnimatedSprite.\n *\n * Sprite sheets can be packed using tools like {@link https://codeandweb.com/texturepacker|TexturePacker},\n * {@link https://renderhjs.net/shoebox/|Shoebox} or {@link https://github.com/krzysztof-o/spritesheet.js|Spritesheet.js}.\n * Default anchor points (see {@link PIXI.Texture#defaultAnchor}) and grouping of animation sprites are currently only\n * supported by TexturePacker.\n *\n * @memberof PIXI\n */\nvar Spritesheet = /** @class */ (function () {\n /**\n * @param baseTexture - Reference to the source BaseTexture object.\n * @param {Object} data - Spritesheet image data.\n * @param resolutionFilename - The filename to consider when determining\n * the resolution of the spritesheet. If not provided, the imageUrl will\n * be used on the BaseTexture.\n */\n function Spritesheet(texture, data, resolutionFilename) {\n if (resolutionFilename === void 0) { resolutionFilename = null; }\n this._texture = texture instanceof Texture ? texture : null;\n this.baseTexture = texture instanceof BaseTexture ? texture : this._texture.baseTexture;\n this.textures = {};\n this.animations = {};\n this.data = data;\n var resource = this.baseTexture.resource;\n this.resolution = this._updateResolution(resolutionFilename || (resource ? resource.url : null));\n this._frames = this.data.frames;\n this._frameKeys = Object.keys(this._frames);\n this._batchIndex = 0;\n this._callback = null;\n }\n /**\n * Generate the resolution from the filename or fallback\n * to the meta.scale field of the JSON data.\n *\n * @param resolutionFilename - The filename to use for resolving\n * the default resolution.\n * @return Resolution to use for spritesheet.\n */\n Spritesheet.prototype._updateResolution = function (resolutionFilename) {\n if (resolutionFilename === void 0) { resolutionFilename = null; }\n var scale = this.data.meta.scale;\n // Use a defaultValue of `null` to check if a url-based resolution is set\n var resolution = getResolutionOfUrl(resolutionFilename, null);\n // No resolution found via URL\n if (resolution === null) {\n // Use the scale value or default to 1\n resolution = scale !== undefined ? parseFloat(scale) : 1;\n }\n // For non-1 resolutions, update baseTexture\n if (resolution !== 1) {\n this.baseTexture.setResolution(resolution);\n }\n return resolution;\n };\n /**\n * Parser spritesheet from loaded data. This is done asynchronously\n * to prevent creating too many Texture within a single process.\n *\n * @param {Function} callback - Callback when complete returns\n * a map of the Textures for this spritesheet.\n */\n Spritesheet.prototype.parse = function (callback) {\n this._batchIndex = 0;\n this._callback = callback;\n if (this._frameKeys.length <= Spritesheet.BATCH_SIZE) {\n this._processFrames(0);\n this._processAnimations();\n this._parseComplete();\n }\n else {\n this._nextBatch();\n }\n };\n /**\n * Process a batch of frames\n *\n * @param initialFrameIndex - The index of frame to start.\n */\n Spritesheet.prototype._processFrames = function (initialFrameIndex) {\n var frameIndex = initialFrameIndex;\n var maxFrames = Spritesheet.BATCH_SIZE;\n while (frameIndex - initialFrameIndex < maxFrames && frameIndex < this._frameKeys.length) {\n var i = this._frameKeys[frameIndex];\n var data = this._frames[i];\n var rect = data.frame;\n if (rect) {\n var frame = null;\n var trim = null;\n var sourceSize = data.trimmed !== false && data.sourceSize\n ? data.sourceSize : data.frame;\n var orig = new Rectangle(0, 0, Math.floor(sourceSize.w) / this.resolution, Math.floor(sourceSize.h) / this.resolution);\n if (data.rotated) {\n frame = new Rectangle(Math.floor(rect.x) / this.resolution, Math.floor(rect.y) / this.resolution, Math.floor(rect.h) / this.resolution, Math.floor(rect.w) / this.resolution);\n }\n else {\n frame = new Rectangle(Math.floor(rect.x) / this.resolution, Math.floor(rect.y) / this.resolution, Math.floor(rect.w) / this.resolution, Math.floor(rect.h) / this.resolution);\n }\n // Check to see if the sprite is trimmed\n if (data.trimmed !== false && data.spriteSourceSize) {\n trim = new Rectangle(Math.floor(data.spriteSourceSize.x) / this.resolution, Math.floor(data.spriteSourceSize.y) / this.resolution, Math.floor(rect.w) / this.resolution, Math.floor(rect.h) / this.resolution);\n }\n this.textures[i] = new Texture(this.baseTexture, frame, orig, trim, data.rotated ? 2 : 0, data.anchor);\n // lets also add the frame to pixi's global cache for 'from' and 'fromLoader' functions\n Texture.addToCache(this.textures[i], i);\n }\n frameIndex++;\n }\n };\n /** Parse animations config. */\n Spritesheet.prototype._processAnimations = function () {\n var animations = this.data.animations || {};\n for (var animName in animations) {\n this.animations[animName] = [];\n for (var i = 0; i < animations[animName].length; i++) {\n var frameName = animations[animName][i];\n this.animations[animName].push(this.textures[frameName]);\n }\n }\n };\n /** The parse has completed. */\n Spritesheet.prototype._parseComplete = function () {\n var callback = this._callback;\n this._callback = null;\n this._batchIndex = 0;\n callback.call(this, this.textures);\n };\n /** Begin the next batch of textures. */\n Spritesheet.prototype._nextBatch = function () {\n var _this = this;\n this._processFrames(this._batchIndex * Spritesheet.BATCH_SIZE);\n this._batchIndex++;\n setTimeout(function () {\n if (_this._batchIndex * Spritesheet.BATCH_SIZE < _this._frameKeys.length) {\n _this._nextBatch();\n }\n else {\n _this._processAnimations();\n _this._parseComplete();\n }\n }, 0);\n };\n /**\n * Destroy Spritesheet and don't use after this.\n *\n * @param {boolean} [destroyBase=false] - Whether to destroy the base texture as well\n */\n Spritesheet.prototype.destroy = function (destroyBase) {\n var _a;\n if (destroyBase === void 0) { destroyBase = false; }\n for (var i in this.textures) {\n this.textures[i].destroy();\n }\n this._frames = null;\n this._frameKeys = null;\n this.data = null;\n this.textures = null;\n if (destroyBase) {\n (_a = this._texture) === null || _a === void 0 ? void 0 : _a.destroy();\n this.baseTexture.destroy();\n }\n this._texture = null;\n this.baseTexture = null;\n };\n /** The maximum number of Textures to build per process. */\n Spritesheet.BATCH_SIZE = 1000;\n return Spritesheet;\n}());\n/**\n * Reference to Spritesheet object created.\n * @member {PIXI.Spritesheet} spritesheet\n * @memberof PIXI.LoaderResource\n * @instance\n */\n/**\n * Dictionary of textures from Spritesheet.\n * @member {object<string, PIXI.Texture>} textures\n * @memberof PIXI.LoaderResource\n * @instance\n */\n\n/**\n * {@link PIXI.Loader} middleware for loading texture atlases that have been created with\n * TexturePacker or similar JSON-based spritesheet.\n *\n * This middleware automatically generates Texture resources.\n *\n * If you're using Webpack or other bundlers and plan on bundling the atlas' JSON,\n * use the {@link PIXI.Spritesheet} class to directly parse the JSON.\n *\n * The Loader's image Resource name is automatically appended with `\"_image\"`.\n * If a Resource with this name is already loaded, the Loader will skip parsing the\n * Spritesheet. The code below will generate an internal Loader Resource called `\"myatlas_image\"`.\n *\n * @example\n * loader.add('myatlas', 'path/to/myatlas.json');\n * loader.load(() => {\n * loader.resources.myatlas; // atlas JSON resource\n * loader.resources.myatlas_image; // atlas Image resource\n * });\n *\n * @memberof PIXI\n */\nvar SpritesheetLoader = /** @class */ (function () {\n function SpritesheetLoader() {\n }\n /**\n * Called after a resource is loaded.\n *\n * @see PIXI.Loader.loaderMiddleware\n * @param resource\n * @param next\n */\n SpritesheetLoader.use = function (resource, next) {\n var _a, _b;\n // because this is middleware, it execute in loader context. `this` = loader\n var loader = this;\n var imageResourceName = resource.name + \"_image\";\n // skip if no data, its not json, it isn't spritesheet data, or the image resource already exists\n if (!resource.data\n || resource.type !== LoaderResource.TYPE.JSON\n || !resource.data.frames\n || loader.resources[imageResourceName]) {\n next();\n return;\n }\n // Check and add the multi atlas\n // Heavily influenced and based on https://github.com/rocket-ua/pixi-tps-loader/blob/master/src/ResourceLoader.js\n // eslint-disable-next-line camelcase\n var multiPacks = (_b = (_a = resource.data) === null || _a === void 0 ? void 0 : _a.meta) === null || _b === void 0 ? void 0 : _b.related_multi_packs;\n if (Array.isArray(multiPacks)) {\n var _loop_1 = function (item) {\n if (typeof item !== 'string') {\n return \"continue\";\n }\n var itemName = item.replace('.json', '');\n var itemUrl = url.resolve(resource.url.replace(loader.baseUrl, ''), item);\n // Check if the file wasn't already added as multipacks are redundant\n if (loader.resources[itemName]\n || Object.values(loader.resources).some(function (r) { return url.format(url.parse(r.url)) === itemUrl; })) {\n return \"continue\";\n }\n var options = {\n crossOrigin: resource.crossOrigin,\n loadType: LoaderResource.LOAD_TYPE.XHR,\n xhrType: LoaderResource.XHR_RESPONSE_TYPE.JSON,\n parentResource: resource,\n metadata: resource.metadata\n };\n loader.add(itemName, itemUrl, options);\n };\n for (var _i = 0, multiPacks_1 = multiPacks; _i < multiPacks_1.length; _i++) {\n var item = multiPacks_1[_i];\n _loop_1(item);\n }\n }\n var loadOptions = {\n crossOrigin: resource.crossOrigin,\n metadata: resource.metadata.imageMetadata,\n parentResource: resource,\n };\n var resourcePath = SpritesheetLoader.getResourcePath(resource, loader.baseUrl);\n // load the image for this sheet\n loader.add(imageResourceName, resourcePath, loadOptions, function onImageLoad(res) {\n if (res.error) {\n next(res.error);\n return;\n }\n var spritesheet = new Spritesheet(res.texture, resource.data, resource.url);\n spritesheet.parse(function () {\n resource.spritesheet = spritesheet;\n resource.textures = spritesheet.textures;\n next();\n });\n });\n };\n /**\n * Get the spritesheets root path\n *\n * @param resource - Resource to check path\n * @param baseUrl - Base root url\n */\n SpritesheetLoader.getResourcePath = function (resource, baseUrl) {\n // Prepend url path unless the resource image is a data url\n if (resource.isDataUrl) {\n return resource.data.meta.image;\n }\n return url.resolve(resource.url.replace(baseUrl, ''), resource.data.meta.image);\n };\n return SpritesheetLoader;\n}());\n\nexport { Spritesheet, SpritesheetLoader };\n//# sourceMappingURL=spritesheet.js.map\n","/*!\n * @pixi/sprite-tiling - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/sprite-tiling is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture, TextureMatrix, Shader, QuadUv, State, ObjectRenderer } from '@pixi/core';\nimport { Point, Rectangle, Transform, Matrix } from '@pixi/math';\nimport { Sprite } from '@pixi/sprite';\nimport { WRAP_MODES } from '@pixi/constants';\nimport { premultiplyTintToRgba, correctBlendMode } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar tempPoint = new Point();\n/**\n * A tiling sprite is a fast way of rendering a tiling image.\n *\n * @memberof PIXI\n */\nvar TilingSprite = /** @class */ (function (_super) {\n __extends(TilingSprite, _super);\n /**\n * @param texture - The texture of the tiling sprite.\n * @param width - The width of the tiling sprite.\n * @param height - The height of the tiling sprite.\n */\n function TilingSprite(texture, width, height) {\n if (width === void 0) { width = 100; }\n if (height === void 0) { height = 100; }\n var _this = _super.call(this, texture) || this;\n _this.tileTransform = new Transform();\n // The width of the tiling sprite\n _this._width = width;\n // The height of the tiling sprite\n _this._height = height;\n _this.uvMatrix = _this.texture.uvMatrix || new TextureMatrix(texture);\n /**\n * Plugin that is responsible for rendering this element.\n * Allows to customize the rendering process without overriding '_render' method.\n *\n * @default 'tilingSprite'\n */\n _this.pluginName = 'tilingSprite';\n _this.uvRespectAnchor = false;\n return _this;\n }\n Object.defineProperty(TilingSprite.prototype, \"clampMargin\", {\n /**\n * Changes frame clamping in corresponding textureTransform, shortcut\n * Change to -0.5 to add a pixel to the edge, recommended for transparent trimmed textures in atlas\n *\n * @default 0.5\n * @member {number}\n */\n get: function () {\n return this.uvMatrix.clampMargin;\n },\n set: function (value) {\n this.uvMatrix.clampMargin = value;\n this.uvMatrix.update(true);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TilingSprite.prototype, \"tileScale\", {\n /** The scaling of the image that is being tiled. */\n get: function () {\n return this.tileTransform.scale;\n },\n set: function (value) {\n this.tileTransform.scale.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TilingSprite.prototype, \"tilePosition\", {\n /** The offset of the image that is being tiled. */\n get: function () {\n return this.tileTransform.position;\n },\n set: function (value) {\n this.tileTransform.position.copyFrom(value);\n },\n enumerable: false,\n configurable: true\n });\n /**\n * @protected\n */\n TilingSprite.prototype._onTextureUpdate = function () {\n if (this.uvMatrix) {\n this.uvMatrix.texture = this._texture;\n }\n this._cachedTint = 0xFFFFFF;\n };\n /**\n * Renders the object using the WebGL renderer\n *\n * @param renderer - The renderer\n */\n TilingSprite.prototype._render = function (renderer) {\n // tweak our texture temporarily..\n var texture = this._texture;\n if (!texture || !texture.valid) {\n return;\n }\n this.tileTransform.updateLocalTransform();\n this.uvMatrix.update();\n renderer.batch.setObjectRenderer(renderer.plugins[this.pluginName]);\n renderer.plugins[this.pluginName].render(this);\n };\n /** Updates the bounds of the tiling sprite. */\n TilingSprite.prototype._calculateBounds = function () {\n var minX = this._width * -this._anchor._x;\n var minY = this._height * -this._anchor._y;\n var maxX = this._width * (1 - this._anchor._x);\n var maxY = this._height * (1 - this._anchor._y);\n this._bounds.addFrame(this.transform, minX, minY, maxX, maxY);\n };\n /**\n * Gets the local bounds of the sprite object.\n *\n * @param rect - Optional output rectangle.\n * @return The bounds.\n */\n TilingSprite.prototype.getLocalBounds = function (rect) {\n // we can do a fast local bounds if the sprite has no children!\n if (this.children.length === 0) {\n this._bounds.minX = this._width * -this._anchor._x;\n this._bounds.minY = this._height * -this._anchor._y;\n this._bounds.maxX = this._width * (1 - this._anchor._x);\n this._bounds.maxY = this._height * (1 - this._anchor._y);\n if (!rect) {\n if (!this._localBoundsRect) {\n this._localBoundsRect = new Rectangle();\n }\n rect = this._localBoundsRect;\n }\n return this._bounds.getRectangle(rect);\n }\n return _super.prototype.getLocalBounds.call(this, rect);\n };\n /**\n * Checks if a point is inside this tiling sprite.\n *\n * @param point - The point to check.\n * @return Whether or not the sprite contains the point.\n */\n TilingSprite.prototype.containsPoint = function (point) {\n this.worldTransform.applyInverse(point, tempPoint);\n var width = this._width;\n var height = this._height;\n var x1 = -width * this.anchor._x;\n if (tempPoint.x >= x1 && tempPoint.x < x1 + width) {\n var y1 = -height * this.anchor._y;\n if (tempPoint.y >= y1 && tempPoint.y < y1 + height) {\n return true;\n }\n }\n return false;\n };\n /**\n * Destroys this sprite and optionally its texture and children\n *\n * @param {object|boolean} [options] - Options parameter. A boolean will act as if all options\n * have been set to that value\n * @param {boolean} [options.children=false] - if set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Should it destroy the current texture of the sprite as well\n * @param {boolean} [options.baseTexture=false] - Should it destroy the base texture of the sprite as well\n */\n TilingSprite.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n this.tileTransform = null;\n this.uvMatrix = null;\n };\n /**\n * Helper function that creates a new tiling sprite based on the source you provide.\n * The source can be - frame id, image url, video url, canvas element, video element, base texture\n *\n * @static\n * @param {string|PIXI.Texture|HTMLCanvasElement|HTMLVideoElement} source - Source to create texture from\n * @param {Object} options - See {@link PIXI.BaseTexture}'s constructor for options.\n * @param {number} options.width - required width of the tiling sprite\n * @param {number} options.height - required height of the tiling sprite\n * @return {PIXI.TilingSprite} The newly created texture\n */\n TilingSprite.from = function (source, options) {\n var texture = (source instanceof Texture)\n ? source\n : Texture.from(source, options);\n return new TilingSprite(texture, options.width, options.height);\n };\n Object.defineProperty(TilingSprite.prototype, \"width\", {\n /** The width of the sprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this._width;\n },\n set: function (value) {\n this._width = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(TilingSprite.prototype, \"height\", {\n /** The height of the TilingSprite, setting this will actually modify the scale to achieve the value set. */\n get: function () {\n return this._height;\n },\n set: function (value) {\n this._height = value;\n },\n enumerable: false,\n configurable: true\n });\n return TilingSprite;\n}(Sprite));\n\nvar fragmentSimpleSrc = \"#version 100\\n#define SHADER_NAME Tiling-Sprite-Simple-100\\n\\nprecision lowp float;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform vec4 uColor;\\n\\nvoid main(void)\\n{\\n vec4 texSample = texture2D(uSampler, vTextureCoord);\\n gl_FragColor = texSample * uColor;\\n}\\n\";\n\nvar gl1VertexSrc = \"#version 100\\n#define SHADER_NAME Tiling-Sprite-100\\n\\nprecision lowp float;\\n\\nattribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform mat3 uTransform;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\\n}\\n\";\n\nvar gl1FragmentSrc = \"#version 100\\n#ifdef GL_EXT_shader_texture_lod\\n #extension GL_EXT_shader_texture_lod : enable\\n#endif\\n#define SHADER_NAME Tiling-Sprite-100\\n\\nprecision lowp float;\\n\\nvarying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform vec4 uColor;\\nuniform mat3 uMapCoord;\\nuniform vec4 uClampFrame;\\nuniform vec2 uClampOffset;\\n\\nvoid main(void)\\n{\\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\\n vec2 unclamped = coord;\\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\\n\\n #ifdef GL_EXT_shader_texture_lod\\n vec4 texSample = unclamped == coord\\n ? texture2D(uSampler, coord) \\n : texture2DLodEXT(uSampler, coord, 0);\\n #else\\n vec4 texSample = texture2D(uSampler, coord);\\n #endif\\n\\n gl_FragColor = texSample * uColor;\\n}\\n\";\n\nvar gl2VertexSrc = \"#version 300 es\\n#define SHADER_NAME Tiling-Sprite-300\\n\\nprecision lowp float;\\n\\nin vec2 aVertexPosition;\\nin vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform mat3 uTransform;\\n\\nout vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\\n}\\n\";\n\nvar gl2FragmentSrc = \"#version 300 es\\n#define SHADER_NAME Tiling-Sprite-100\\n\\nprecision lowp float;\\n\\nin vec2 vTextureCoord;\\n\\nout vec4 fragmentColor;\\n\\nuniform sampler2D uSampler;\\nuniform vec4 uColor;\\nuniform mat3 uMapCoord;\\nuniform vec4 uClampFrame;\\nuniform vec2 uClampOffset;\\n\\nvoid main(void)\\n{\\n vec2 coord = vTextureCoord + ceil(uClampOffset - vTextureCoord);\\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\\n vec2 unclamped = coord;\\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\\n\\n vec4 texSample = texture(uSampler, coord, unclamped == coord ? 0.0f : -32.0f);// lod-bias very negative to force lod 0\\n\\n fragmentColor = texSample * uColor;\\n}\\n\";\n\nvar tempMat = new Matrix();\n/**\n * WebGL renderer plugin for tiling sprites\n *\n * @class\n * @memberof PIXI\n * @extends PIXI.ObjectRenderer\n */\nvar TilingSpriteRenderer = /** @class */ (function (_super) {\n __extends(TilingSpriteRenderer, _super);\n /**\n * constructor for renderer\n *\n * @param {PIXI.Renderer} renderer - The renderer this tiling awesomeness works for.\n */\n function TilingSpriteRenderer(renderer) {\n var _this = _super.call(this, renderer) || this;\n // WebGL version is not available during initialization!\n renderer.runners.contextChange.add(_this);\n _this.quad = new QuadUv();\n /**\n * The WebGL state in which this renderer will work.\n *\n * @member {PIXI.State}\n * @readonly\n */\n _this.state = State.for2d();\n return _this;\n }\n /**\n * Creates shaders when context is initialized.\n */\n TilingSpriteRenderer.prototype.contextChange = function () {\n var renderer = this.renderer;\n var uniforms = { globals: renderer.globalUniforms };\n this.simpleShader = Shader.from(gl1VertexSrc, fragmentSimpleSrc, uniforms);\n this.shader = renderer.context.webGLVersion > 1\n ? Shader.from(gl2VertexSrc, gl2FragmentSrc, uniforms)\n : Shader.from(gl1VertexSrc, gl1FragmentSrc, uniforms);\n };\n /**\n * @param {PIXI.TilingSprite} ts - tilingSprite to be rendered\n */\n TilingSpriteRenderer.prototype.render = function (ts) {\n var renderer = this.renderer;\n var quad = this.quad;\n var vertices = quad.vertices;\n vertices[0] = vertices[6] = (ts._width) * -ts.anchor.x;\n vertices[1] = vertices[3] = ts._height * -ts.anchor.y;\n vertices[2] = vertices[4] = (ts._width) * (1.0 - ts.anchor.x);\n vertices[5] = vertices[7] = ts._height * (1.0 - ts.anchor.y);\n var anchorX = ts.uvRespectAnchor ? ts.anchor.x : 0;\n var anchorY = ts.uvRespectAnchor ? ts.anchor.y : 0;\n vertices = quad.uvs;\n vertices[0] = vertices[6] = -anchorX;\n vertices[1] = vertices[3] = -anchorY;\n vertices[2] = vertices[4] = 1.0 - anchorX;\n vertices[5] = vertices[7] = 1.0 - anchorY;\n quad.invalidate();\n var tex = ts._texture;\n var baseTex = tex.baseTexture;\n var lt = ts.tileTransform.localTransform;\n var uv = ts.uvMatrix;\n var isSimple = baseTex.isPowerOfTwo\n && tex.frame.width === baseTex.width && tex.frame.height === baseTex.height;\n // auto, force repeat wrapMode for big tiling textures\n if (isSimple) {\n if (!baseTex._glTextures[renderer.CONTEXT_UID]) {\n if (baseTex.wrapMode === WRAP_MODES.CLAMP) {\n baseTex.wrapMode = WRAP_MODES.REPEAT;\n }\n }\n else {\n isSimple = baseTex.wrapMode !== WRAP_MODES.CLAMP;\n }\n }\n var shader = isSimple ? this.simpleShader : this.shader;\n var w = tex.width;\n var h = tex.height;\n var W = ts._width;\n var H = ts._height;\n tempMat.set(lt.a * w / W, lt.b * w / H, lt.c * h / W, lt.d * h / H, lt.tx / W, lt.ty / H);\n // that part is the same as above:\n // tempMat.identity();\n // tempMat.scale(tex.width, tex.height);\n // tempMat.prepend(lt);\n // tempMat.scale(1.0 / ts._width, 1.0 / ts._height);\n tempMat.invert();\n if (isSimple) {\n tempMat.prepend(uv.mapCoord);\n }\n else {\n shader.uniforms.uMapCoord = uv.mapCoord.toArray(true);\n shader.uniforms.uClampFrame = uv.uClampFrame;\n shader.uniforms.uClampOffset = uv.uClampOffset;\n }\n shader.uniforms.uTransform = tempMat.toArray(true);\n shader.uniforms.uColor = premultiplyTintToRgba(ts.tint, ts.worldAlpha, shader.uniforms.uColor, baseTex.alphaMode);\n shader.uniforms.translationMatrix = ts.transform.worldTransform.toArray(true);\n shader.uniforms.uSampler = tex;\n renderer.shader.bind(shader);\n renderer.geometry.bind(quad);\n this.state.blendMode = correctBlendMode(ts.blendMode, baseTex.alphaMode);\n renderer.state.set(this.state);\n renderer.geometry.draw(this.renderer.gl.TRIANGLES, 6, 0);\n };\n return TilingSpriteRenderer;\n}(ObjectRenderer));\n\nexport { TilingSprite, TilingSpriteRenderer };\n//# sourceMappingURL=sprite-tiling.js.map\n","/*!\n * @pixi/mesh - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mesh is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { State, Program, TextureMatrix, Shader, Buffer, Geometry } from '@pixi/core';\nimport { Point, Polygon, Matrix } from '@pixi/math';\nimport { DRAW_MODES, TYPES } from '@pixi/constants';\nimport { Container } from '@pixi/display';\nimport { settings } from '@pixi/settings';\nimport { premultiplyTintToRgba } from '@pixi/utils';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * Class controls cache for UV mapping from Texture normal space to BaseTexture normal space.\n *\n * @memberof PIXI\n */\nvar MeshBatchUvs = /** @class */ (function () {\n /**\n * @param uvBuffer - Buffer with normalized uv's\n * @param uvMatrix - Material UV matrix\n */\n function MeshBatchUvs(uvBuffer, uvMatrix) {\n this.uvBuffer = uvBuffer;\n this.uvMatrix = uvMatrix;\n this.data = null;\n this._bufferUpdateId = -1;\n this._textureUpdateId = -1;\n this._updateID = 0;\n }\n /**\n * Updates\n *\n * @param forceUpdate - force the update\n */\n MeshBatchUvs.prototype.update = function (forceUpdate) {\n if (!forceUpdate\n && this._bufferUpdateId === this.uvBuffer._updateID\n && this._textureUpdateId === this.uvMatrix._updateID) {\n return;\n }\n this._bufferUpdateId = this.uvBuffer._updateID;\n this._textureUpdateId = this.uvMatrix._updateID;\n var data = this.uvBuffer.data;\n if (!this.data || this.data.length !== data.length) {\n this.data = new Float32Array(data.length);\n }\n this.uvMatrix.multiplyUvs(data, this.data);\n this._updateID++;\n };\n return MeshBatchUvs;\n}());\n\nvar tempPoint = new Point();\nvar tempPolygon = new Polygon();\n/**\n * Base mesh class.\n *\n * This class empowers you to have maximum flexibility to render any kind of WebGL visuals you can think of.\n * This class assumes a certain level of WebGL knowledge.\n * If you know a bit this should abstract enough away to make your life easier!\n *\n * Pretty much ALL WebGL can be broken down into the following:\n * - Geometry - The structure and data for the mesh. This can include anything from positions, uvs, normals, colors etc..\n * - Shader - This is the shader that PixiJS will render the geometry with (attributes in the shader must match the geometry)\n * - State - This is the state of WebGL required to render the mesh.\n *\n * Through a combination of the above elements you can render anything you want, 2D or 3D!\n *\n * @memberof PIXI\n */\nvar Mesh = /** @class */ (function (_super) {\n __extends(Mesh, _super);\n /**\n * @param geometry - The geometry the mesh will use.\n * @param {PIXI.MeshMaterial} shader - The shader the mesh will use.\n * @param state - The state that the WebGL context is required to be in to render the mesh\n * if no state is provided, uses {@link PIXI.State.for2d} to create a 2D state for PixiJS.\n * @param drawMode - The drawMode, can be any of the {@link PIXI.DRAW_MODES} constants.\n */\n function Mesh(geometry, shader, state, drawMode) {\n if (drawMode === void 0) { drawMode = DRAW_MODES.TRIANGLES; }\n var _this = _super.call(this) || this;\n _this.geometry = geometry;\n _this.shader = shader;\n _this.state = state || State.for2d();\n _this.drawMode = drawMode;\n _this.start = 0;\n _this.size = 0;\n _this.uvs = null;\n _this.indices = null;\n _this.vertexData = new Float32Array(1);\n _this.vertexDirty = -1;\n _this._transformID = -1;\n _this._roundPixels = settings.ROUND_PIXELS;\n _this.batchUvs = null;\n return _this;\n }\n Object.defineProperty(Mesh.prototype, \"geometry\", {\n /**\n * Includes vertex positions, face indices, normals, colors, UVs, and\n * custom attributes within buffers, reducing the cost of passing all\n * this data to the GPU. Can be shared between multiple Mesh objects.\n */\n get: function () {\n return this._geometry;\n },\n set: function (value) {\n if (this._geometry === value) {\n return;\n }\n if (this._geometry) {\n this._geometry.refCount--;\n if (this._geometry.refCount === 0) {\n this._geometry.dispose();\n }\n }\n this._geometry = value;\n if (this._geometry) {\n this._geometry.refCount++;\n }\n this.vertexDirty = -1;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"uvBuffer\", {\n /**\n * To change mesh uv's, change its uvBuffer data and increment its _updateID.\n *\n * @readonly\n */\n get: function () {\n return this.geometry.buffers[1];\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"verticesBuffer\", {\n /**\n * To change mesh vertices, change its uvBuffer data and increment its _updateID.\n * Incrementing _updateID is optional because most of Mesh objects do it anyway.\n *\n * @readonly\n */\n get: function () {\n return this.geometry.buffers[0];\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"material\", {\n get: function () {\n return this.shader;\n },\n /** Alias for {@link PIXI.Mesh#shader}. */\n set: function (value) {\n this.shader = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"blendMode\", {\n get: function () {\n return this.state.blendMode;\n },\n /**\n * The blend mode to be applied to the Mesh. Apply a value of\n * `PIXI.BLEND_MODES.NORMAL` to reset the blend mode.\n *\n * @default PIXI.BLEND_MODES.NORMAL;\n */\n set: function (value) {\n this.state.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"roundPixels\", {\n get: function () {\n return this._roundPixels;\n },\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n * To set the global default, change {@link PIXI.settings.ROUND_PIXELS}\n *\n * @default false\n */\n set: function (value) {\n if (this._roundPixels !== value) {\n this._transformID = -1;\n }\n this._roundPixels = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"tint\", {\n /**\n * The multiply tint applied to the Mesh. This is a hex value. A value of\n * `0xFFFFFF` will remove any tint effect.\n *\n * Null for non-MeshMaterial shaders\n *\n * @default 0xFFFFFF\n */\n get: function () {\n return 'tint' in this.shader ? this.shader.tint : null;\n },\n set: function (value) {\n this.shader.tint = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Mesh.prototype, \"texture\", {\n /**\n * The texture that the Mesh uses.\n *\n * Null for non-MeshMaterial shaders\n */\n get: function () {\n return 'texture' in this.shader ? this.shader.texture : null;\n },\n set: function (value) {\n this.shader.texture = value;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Standard renderer draw.\n *\n * @param renderer - Instance to renderer.\n */\n Mesh.prototype._render = function (renderer) {\n // set properties for batching..\n // TODO could use a different way to grab verts?\n var vertices = this.geometry.buffers[0].data;\n var shader = this.shader;\n // TODO benchmark check for attribute size..\n if (shader.batchable\n && this.drawMode === DRAW_MODES.TRIANGLES\n && vertices.length < Mesh.BATCHABLE_SIZE * 2) {\n this._renderToBatch(renderer);\n }\n else {\n this._renderDefault(renderer);\n }\n };\n /**\n * Standard non-batching way of rendering.\n *\n * @param renderer - Instance to renderer.\n */\n Mesh.prototype._renderDefault = function (renderer) {\n var shader = this.shader;\n shader.alpha = this.worldAlpha;\n if (shader.update) {\n shader.update();\n }\n renderer.batch.flush();\n // bind and sync uniforms..\n shader.uniforms.translationMatrix = this.transform.worldTransform.toArray(true);\n renderer.shader.bind(shader);\n // set state..\n renderer.state.set(this.state);\n // bind the geometry...\n renderer.geometry.bind(this.geometry, shader);\n // then render it\n renderer.geometry.draw(this.drawMode, this.size, this.start, this.geometry.instanceCount);\n };\n /**\n * Rendering by using the Batch system.\n *\n * @param renderer - Instance to renderer.\n */\n Mesh.prototype._renderToBatch = function (renderer) {\n var geometry = this.geometry;\n var shader = this.shader;\n if (shader.uvMatrix) {\n shader.uvMatrix.update();\n this.calculateUvs();\n }\n // set properties for batching..\n this.calculateVertices();\n this.indices = geometry.indexBuffer.data;\n this._tintRGB = shader._tintRGB;\n this._texture = shader.texture;\n var pluginName = this.material.pluginName;\n renderer.batch.setObjectRenderer(renderer.plugins[pluginName]);\n renderer.plugins[pluginName].render(this);\n };\n /** Updates vertexData field based on transform and vertices. */\n Mesh.prototype.calculateVertices = function () {\n var geometry = this.geometry;\n var verticesBuffer = geometry.buffers[0];\n var vertices = verticesBuffer.data;\n var vertexDirtyId = verticesBuffer._updateID;\n if (vertexDirtyId === this.vertexDirty && this._transformID === this.transform._worldID) {\n return;\n }\n this._transformID = this.transform._worldID;\n if (this.vertexData.length !== vertices.length) {\n this.vertexData = new Float32Array(vertices.length);\n }\n var wt = this.transform.worldTransform;\n var a = wt.a;\n var b = wt.b;\n var c = wt.c;\n var d = wt.d;\n var tx = wt.tx;\n var ty = wt.ty;\n var vertexData = this.vertexData;\n for (var i = 0; i < vertexData.length / 2; i++) {\n var x = vertices[(i * 2)];\n var y = vertices[(i * 2) + 1];\n vertexData[(i * 2)] = (a * x) + (c * y) + tx;\n vertexData[(i * 2) + 1] = (b * x) + (d * y) + ty;\n }\n if (this._roundPixels) {\n var resolution = settings.RESOLUTION;\n for (var i = 0; i < vertexData.length; ++i) {\n vertexData[i] = Math.round((vertexData[i] * resolution | 0) / resolution);\n }\n }\n this.vertexDirty = vertexDirtyId;\n };\n /** Updates uv field based on from geometry uv's or batchUvs. */\n Mesh.prototype.calculateUvs = function () {\n var geomUvs = this.geometry.buffers[1];\n var shader = this.shader;\n if (!shader.uvMatrix.isSimple) {\n if (!this.batchUvs) {\n this.batchUvs = new MeshBatchUvs(geomUvs, shader.uvMatrix);\n }\n this.batchUvs.update();\n this.uvs = this.batchUvs.data;\n }\n else {\n this.uvs = geomUvs.data;\n }\n };\n /**\n * Updates the bounds of the mesh as a rectangle. The bounds calculation takes the worldTransform into account.\n * there must be a aVertexPosition attribute present in the geometry for bounds to be calculated correctly.\n */\n Mesh.prototype._calculateBounds = function () {\n this.calculateVertices();\n this._bounds.addVertexData(this.vertexData, 0, this.vertexData.length);\n };\n /**\n * Tests if a point is inside this mesh. Works only for PIXI.DRAW_MODES.TRIANGLES.\n *\n * @param point - The point to test.\n * @return - The result of the test.\n */\n Mesh.prototype.containsPoint = function (point) {\n if (!this.getBounds().contains(point.x, point.y)) {\n return false;\n }\n this.worldTransform.applyInverse(point, tempPoint);\n var vertices = this.geometry.getBuffer('aVertexPosition').data;\n var points = tempPolygon.points;\n var indices = this.geometry.getIndex().data;\n var len = indices.length;\n var step = this.drawMode === 4 ? 3 : 1;\n for (var i = 0; i + 2 < len; i += step) {\n var ind0 = indices[i] * 2;\n var ind1 = indices[i + 1] * 2;\n var ind2 = indices[i + 2] * 2;\n points[0] = vertices[ind0];\n points[1] = vertices[ind0 + 1];\n points[2] = vertices[ind1];\n points[3] = vertices[ind1 + 1];\n points[4] = vertices[ind2];\n points[5] = vertices[ind2 + 1];\n if (tempPolygon.contains(tempPoint.x, tempPoint.y)) {\n return true;\n }\n }\n return false;\n };\n Mesh.prototype.destroy = function (options) {\n _super.prototype.destroy.call(this, options);\n if (this._cachedTexture) {\n this._cachedTexture.destroy();\n this._cachedTexture = null;\n }\n this.geometry = null;\n this.shader = null;\n this.state = null;\n this.uvs = null;\n this.indices = null;\n this.vertexData = null;\n };\n /**\n * The maximum number of vertices to consider batchable. Generally, the complexity\n * of the geometry.\n */\n Mesh.BATCHABLE_SIZE = 100;\n return Mesh;\n}(Container));\n\nvar fragment = \"varying vec2 vTextureCoord;\\nuniform vec4 uColor;\\n\\nuniform sampler2D uSampler;\\n\\nvoid main(void)\\n{\\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uColor;\\n}\\n\";\n\nvar vertex = \"attribute vec2 aVertexPosition;\\nattribute vec2 aTextureCoord;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 translationMatrix;\\nuniform mat3 uTextureMatrix;\\n\\nvarying vec2 vTextureCoord;\\n\\nvoid main(void)\\n{\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\n\\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\\n}\\n\";\n\n/**\n * Slightly opinionated default shader for PixiJS 2D objects.\n *\n * @memberof PIXI\n */\nvar MeshMaterial = /** @class */ (function (_super) {\n __extends(MeshMaterial, _super);\n /**\n * @param uSampler - Texture that material uses to render.\n * @param options - Additional options\n * @param {number} [options.alpha=1] - Default alpha.\n * @param {number} [options.tint=0xFFFFFF] - Default tint.\n * @param {string} [options.pluginName='batch'] - Renderer plugin for batching.\n * @param {PIXI.Program} [options.program=0xFFFFFF] - Custom program.\n * @param {object} [options.uniforms] - Custom uniforms.\n */\n function MeshMaterial(uSampler, options) {\n var _this = this;\n var uniforms = {\n uSampler: uSampler,\n alpha: 1,\n uTextureMatrix: Matrix.IDENTITY,\n uColor: new Float32Array([1, 1, 1, 1]),\n };\n // Set defaults\n options = Object.assign({\n tint: 0xFFFFFF,\n alpha: 1,\n pluginName: 'batch',\n }, options);\n if (options.uniforms) {\n Object.assign(uniforms, options.uniforms);\n }\n _this = _super.call(this, options.program || Program.from(vertex, fragment), uniforms) || this;\n _this._colorDirty = false;\n _this.uvMatrix = new TextureMatrix(uSampler);\n _this.batchable = options.program === undefined;\n _this.pluginName = options.pluginName;\n _this.tint = options.tint;\n _this.alpha = options.alpha;\n return _this;\n }\n Object.defineProperty(MeshMaterial.prototype, \"texture\", {\n /** Reference to the texture being rendered. */\n get: function () {\n return this.uniforms.uSampler;\n },\n set: function (value) {\n if (this.uniforms.uSampler !== value) {\n this.uniforms.uSampler = value;\n this.uvMatrix.texture = value;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MeshMaterial.prototype, \"alpha\", {\n get: function () {\n return this._alpha;\n },\n /**\n * This gets automatically set by the object using this.\n *\n * @default 1\n */\n set: function (value) {\n if (value === this._alpha)\n { return; }\n this._alpha = value;\n this._colorDirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MeshMaterial.prototype, \"tint\", {\n get: function () {\n return this._tint;\n },\n /**\n * Multiply tint for the material.\n *\n * @default 0xFFFFFF\n */\n set: function (value) {\n if (value === this._tint)\n { return; }\n this._tint = value;\n this._tintRGB = (value >> 16) + (value & 0xff00) + ((value & 0xff) << 16);\n this._colorDirty = true;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Gets called automatically by the Mesh. Intended to be overridden for custom\n * {@link MeshMaterial} objects.\n */\n MeshMaterial.prototype.update = function () {\n if (this._colorDirty) {\n this._colorDirty = false;\n var baseTexture = this.texture.baseTexture;\n premultiplyTintToRgba(this._tint, this._alpha, this.uniforms.uColor, baseTexture.alphaMode);\n }\n if (this.uvMatrix.update()) {\n this.uniforms.uTextureMatrix = this.uvMatrix.mapCoord;\n }\n };\n return MeshMaterial;\n}(Shader));\n\n/**\n * Standard 2D geometry used in PixiJS.\n *\n * Geometry can be defined without passing in a style or data if required.\n *\n * ```js\n * const geometry = new PIXI.Geometry();\n *\n * geometry.addAttribute('positions', [0, 0, 100, 0, 100, 100, 0, 100], 2);\n * geometry.addAttribute('uvs', [0,0,1,0,1,1,0,1], 2);\n * geometry.addIndex([0,1,2,1,3,2]);\n *\n * ```\n *\n * @memberof PIXI\n */\nvar MeshGeometry = /** @class */ (function (_super) {\n __extends(MeshGeometry, _super);\n /**\n * @param {Float32Array|number[]} [vertices] - Positional data on geometry.\n * @param {Float32Array|number[]} [uvs] - Texture UVs.\n * @param {Uint16Array|number[]} [index] - IndexBuffer\n */\n function MeshGeometry(vertices, uvs, index) {\n var _this = _super.call(this) || this;\n var verticesBuffer = new Buffer(vertices);\n var uvsBuffer = new Buffer(uvs, true);\n var indexBuffer = new Buffer(index, true, true);\n _this.addAttribute('aVertexPosition', verticesBuffer, 2, false, TYPES.FLOAT)\n .addAttribute('aTextureCoord', uvsBuffer, 2, false, TYPES.FLOAT)\n .addIndex(indexBuffer);\n _this._updateId = -1;\n return _this;\n }\n Object.defineProperty(MeshGeometry.prototype, \"vertexDirtyId\", {\n /**\n * If the vertex position is updated.\n *\n * @readonly\n * @private\n */\n get: function () {\n return this.buffers[0]._updateID;\n },\n enumerable: false,\n configurable: true\n });\n return MeshGeometry;\n}(Geometry));\n\nexport { Mesh, MeshBatchUvs, MeshGeometry, MeshMaterial };\n//# sourceMappingURL=mesh.js.map\n","/*!\n * @pixi/text-bitmap - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/text-bitmap is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Rectangle, Point, ObservablePoint } from '@pixi/math';\nimport { settings } from '@pixi/settings';\nimport { MeshGeometry, MeshMaterial, Mesh } from '@pixi/mesh';\nimport { hex2rgb, string2hex, getResolutionOfUrl, removeItems } from '@pixi/utils';\nimport { BaseTexture, Texture, Program } from '@pixi/core';\nimport { TEXT_GRADIENT, TextStyle, TextMetrics } from '@pixi/text';\nimport { ALPHA_MODES, BLEND_MODES } from '@pixi/constants';\nimport { Container } from '@pixi/display';\nimport { LoaderResource } from '@pixi/loaders';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/* eslint-disable max-len */\n/**\n * Normalized parsed data from .fnt files.\n *\n * @memberof PIXI\n */\nvar BitmapFontData = /** @class */ (function () {\n function BitmapFontData() {\n this.info = [];\n this.common = [];\n this.page = [];\n this.char = [];\n this.kerning = [];\n this.distanceField = [];\n }\n return BitmapFontData;\n}());\n\n/**\n * BitmapFont format that's Text-based.\n *\n * @private\n */\nvar TextFormat = /** @class */ (function () {\n function TextFormat() {\n }\n /**\n * Check if resource refers to txt font data.\n *\n * @param data\n * @return - True if resource could be treated as font data, false otherwise.\n */\n TextFormat.test = function (data) {\n return typeof data === 'string' && data.indexOf('info face=') === 0;\n };\n /**\n * Convert text font data to a javascript object.\n *\n * @param txt - Raw string data to be converted\n * @return - Parsed font data\n */\n TextFormat.parse = function (txt) {\n // Retrieve data item\n var items = txt.match(/^[a-z]+\\s+.+$/gm);\n var rawData = {\n info: [],\n common: [],\n page: [],\n char: [],\n chars: [],\n kerning: [],\n kernings: [],\n distanceField: [],\n };\n for (var i in items) {\n // Extract item name\n var name = items[i].match(/^[a-z]+/gm)[0];\n // Extract item attribute list as string ex.: \"width=10\"\n var attributeList = items[i].match(/[a-zA-Z]+=([^\\s\"']+|\"([^\"]*)\")/gm);\n // Convert attribute list into an object\n var itemData = {};\n for (var i_1 in attributeList) {\n // Split key-value pairs\n var split = attributeList[i_1].split('=');\n var key = split[0];\n // Remove eventual quotes from value\n var strValue = split[1].replace(/\"/gm, '');\n // Try to convert value into float\n var floatValue = parseFloat(strValue);\n // Use string value case float value is NaN\n var value = isNaN(floatValue) ? strValue : floatValue;\n itemData[key] = value;\n }\n // Push current item to the resulting data\n rawData[name].push(itemData);\n }\n var font = new BitmapFontData();\n rawData.info.forEach(function (info) { return font.info.push({\n face: info.face,\n size: parseInt(info.size, 10),\n }); });\n rawData.common.forEach(function (common) { return font.common.push({\n lineHeight: parseInt(common.lineHeight, 10),\n }); });\n rawData.page.forEach(function (page) { return font.page.push({\n id: parseInt(page.id, 10),\n file: page.file,\n }); });\n rawData.char.forEach(function (char) { return font.char.push({\n id: parseInt(char.id, 10),\n page: parseInt(char.page, 10),\n x: parseInt(char.x, 10),\n y: parseInt(char.y, 10),\n width: parseInt(char.width, 10),\n height: parseInt(char.height, 10),\n xoffset: parseInt(char.xoffset, 10),\n yoffset: parseInt(char.yoffset, 10),\n xadvance: parseInt(char.xadvance, 10),\n }); });\n rawData.kerning.forEach(function (kerning) { return font.kerning.push({\n first: parseInt(kerning.first, 10),\n second: parseInt(kerning.second, 10),\n amount: parseInt(kerning.amount, 10),\n }); });\n rawData.distanceField.forEach(function (df) { return font.distanceField.push({\n distanceRange: parseInt(df.distanceRange, 10),\n fieldType: df.fieldType,\n }); });\n return font;\n };\n return TextFormat;\n}());\n\n/**\n * BitmapFont format that's XML-based.\n *\n * @private\n */\nvar XMLFormat = /** @class */ (function () {\n function XMLFormat() {\n }\n /**\n * Check if resource refers to xml font data.\n *\n * @param data\n * @return - True if resource could be treated as font data, false otherwise.\n */\n XMLFormat.test = function (data) {\n return data instanceof XMLDocument\n && data.getElementsByTagName('page').length\n && data.getElementsByTagName('info')[0].getAttribute('face') !== null;\n };\n /**\n * Convert the XML into BitmapFontData that we can use.\n *\n * @param xml\n * @return - Data to use for BitmapFont\n */\n XMLFormat.parse = function (xml) {\n var data = new BitmapFontData();\n var info = xml.getElementsByTagName('info');\n var common = xml.getElementsByTagName('common');\n var page = xml.getElementsByTagName('page');\n var char = xml.getElementsByTagName('char');\n var kerning = xml.getElementsByTagName('kerning');\n var distanceField = xml.getElementsByTagName('distanceField');\n for (var i = 0; i < info.length; i++) {\n data.info.push({\n face: info[i].getAttribute('face'),\n size: parseInt(info[i].getAttribute('size'), 10),\n });\n }\n for (var i = 0; i < common.length; i++) {\n data.common.push({\n lineHeight: parseInt(common[i].getAttribute('lineHeight'), 10),\n });\n }\n for (var i = 0; i < page.length; i++) {\n data.page.push({\n id: parseInt(page[i].getAttribute('id'), 10) || 0,\n file: page[i].getAttribute('file'),\n });\n }\n for (var i = 0; i < char.length; i++) {\n var letter = char[i];\n data.char.push({\n id: parseInt(letter.getAttribute('id'), 10),\n page: parseInt(letter.getAttribute('page'), 10) || 0,\n x: parseInt(letter.getAttribute('x'), 10),\n y: parseInt(letter.getAttribute('y'), 10),\n width: parseInt(letter.getAttribute('width'), 10),\n height: parseInt(letter.getAttribute('height'), 10),\n xoffset: parseInt(letter.getAttribute('xoffset'), 10),\n yoffset: parseInt(letter.getAttribute('yoffset'), 10),\n xadvance: parseInt(letter.getAttribute('xadvance'), 10),\n });\n }\n for (var i = 0; i < kerning.length; i++) {\n data.kerning.push({\n first: parseInt(kerning[i].getAttribute('first'), 10),\n second: parseInt(kerning[i].getAttribute('second'), 10),\n amount: parseInt(kerning[i].getAttribute('amount'), 10),\n });\n }\n for (var i = 0; i < distanceField.length; i++) {\n data.distanceField.push({\n fieldType: distanceField[i].getAttribute('fieldType'),\n distanceRange: parseInt(distanceField[i].getAttribute('distanceRange'), 10),\n });\n }\n return data;\n };\n return XMLFormat;\n}());\n\n/**\n * BitmapFont format that's XML-based.\n *\n * @private\n */\nvar XMLStringFormat = /** @class */ (function () {\n function XMLStringFormat() {\n }\n /**\n * Check if resource refers to text xml font data.\n *\n * @param data\n * @return - True if resource could be treated as font data, false otherwise.\n */\n XMLStringFormat.test = function (data) {\n if (typeof data === 'string' && data.indexOf('<font>') > -1) {\n var xml = new globalThis.DOMParser().parseFromString(data, 'text/xml');\n return XMLFormat.test(xml);\n }\n return false;\n };\n /**\n * Convert the text XML into BitmapFontData that we can use.\n *\n * @param xmlTxt\n * @return - Data to use for BitmapFont\n */\n XMLStringFormat.parse = function (xmlTxt) {\n var xml = new globalThis.DOMParser().parseFromString(xmlTxt, 'text/xml');\n return XMLFormat.parse(xml);\n };\n return XMLStringFormat;\n}());\n\n// Registered formats, maybe make this extensible in the future?\nvar formats = [\n TextFormat,\n XMLFormat,\n XMLStringFormat ];\n/**\n * Auto-detect BitmapFont parsing format based on data.\n * @private\n * @param {any} data - Data to detect format\n * @return {any} Format or null\n */\nfunction autoDetectFormat(data) {\n for (var i = 0; i < formats.length; i++) {\n if (formats[i].test(data)) {\n return formats[i];\n }\n }\n return null;\n}\n\n// TODO: Prevent code duplication b/w generateFillStyle & Text#generateFillStyle\n/**\n * Generates the fill style. Can automatically generate a gradient based on the fill style being an array\n *\n * @private\n * @param {object} style - The style.\n * @param {string[]} lines - The lines of text.\n * @return {string|number|CanvasGradient} The fill style\n */\nfunction generateFillStyle(canvas, context, style, resolution, lines, metrics) {\n // TODO: Can't have different types for getter and setter. The getter shouldn't have the number type as\n // the setter converts to string. See this thread for more details:\n // https://github.com/microsoft/TypeScript/issues/2521\n var fillStyle = style.fill;\n if (!Array.isArray(fillStyle)) {\n return fillStyle;\n }\n else if (fillStyle.length === 1) {\n return fillStyle[0];\n }\n // the gradient will be evenly spaced out according to how large the array is.\n // ['#FF0000', '#00FF00', '#0000FF'] would created stops at 0.25, 0.5 and 0.75\n var gradient;\n // a dropshadow will enlarge the canvas and result in the gradient being\n // generated with the incorrect dimensions\n var dropShadowCorrection = (style.dropShadow) ? style.dropShadowDistance : 0;\n // should also take padding into account, padding can offset the gradient\n var padding = style.padding || 0;\n var width = (canvas.width / resolution) - dropShadowCorrection - (padding * 2);\n var height = (canvas.height / resolution) - dropShadowCorrection - (padding * 2);\n // make a copy of the style settings, so we can manipulate them later\n var fill = fillStyle.slice();\n var fillGradientStops = style.fillGradientStops.slice();\n // wanting to evenly distribute the fills. So an array of 4 colours should give fills of 0.25, 0.5 and 0.75\n if (!fillGradientStops.length) {\n var lengthPlus1 = fill.length + 1;\n for (var i = 1; i < lengthPlus1; ++i) {\n fillGradientStops.push(i / lengthPlus1);\n }\n }\n // stop the bleeding of the last gradient on the line above to the top gradient of the this line\n // by hard defining the first gradient colour at point 0, and last gradient colour at point 1\n fill.unshift(fillStyle[0]);\n fillGradientStops.unshift(0);\n fill.push(fillStyle[fillStyle.length - 1]);\n fillGradientStops.push(1);\n if (style.fillGradientType === TEXT_GRADIENT.LINEAR_VERTICAL) {\n // start the gradient at the top center of the canvas, and end at the bottom middle of the canvas\n gradient = context.createLinearGradient(width / 2, padding, width / 2, height + padding);\n // we need to repeat the gradient so that each individual line of text has the same vertical gradient effect\n // ['#FF0000', '#00FF00', '#0000FF'] over 2 lines would create stops at 0.125, 0.25, 0.375, 0.625, 0.75, 0.875\n // There's potential for floating point precision issues at the seams between gradient repeats.\n // The loop below generates the stops in order, so track the last generated one to prevent\n // floating point precision from making us go the teeniest bit backwards, resulting in\n // the first and last colors getting swapped.\n var lastIterationStop = 0;\n // Actual height of the text itself, not counting spacing for lineHeight/leading/dropShadow etc\n var textHeight = metrics.fontProperties.fontSize + style.strokeThickness;\n // textHeight, but as a 0-1 size in global gradient stop space\n var gradStopLineHeight = textHeight / height;\n for (var i = 0; i < lines.length; i++) {\n var thisLineTop = metrics.lineHeight * i;\n for (var j = 0; j < fill.length; j++) {\n // 0-1 stop point for the current line, multiplied to global space afterwards\n var lineStop = 0;\n if (typeof fillGradientStops[j] === 'number') {\n lineStop = fillGradientStops[j];\n }\n else {\n lineStop = j / fill.length;\n }\n var globalStop = (thisLineTop / height) + (lineStop * gradStopLineHeight);\n // Prevent color stop generation going backwards from floating point imprecision\n var clampedStop = Math.max(lastIterationStop, globalStop);\n clampedStop = Math.min(clampedStop, 1); // Cap at 1 as well for safety's sake to avoid a possible throw.\n gradient.addColorStop(clampedStop, fill[j]);\n lastIterationStop = clampedStop;\n }\n }\n }\n else {\n // start the gradient at the center left of the canvas, and end at the center right of the canvas\n gradient = context.createLinearGradient(padding, height / 2, width + padding, height / 2);\n // can just evenly space out the gradients in this case, as multiple lines makes no difference\n // to an even left to right gradient\n var totalIterations = fill.length + 1;\n var currentIteration = 1;\n for (var i = 0; i < fill.length; i++) {\n var stop = void 0;\n if (typeof fillGradientStops[i] === 'number') {\n stop = fillGradientStops[i];\n }\n else {\n stop = currentIteration / totalIterations;\n }\n gradient.addColorStop(stop, fill[i]);\n currentIteration++;\n }\n }\n return gradient;\n}\n\n// TODO: Prevent code duplication b/w drawGlyph & Text#updateText\n/**\n * Draws the glyph `metrics.text` on the given canvas.\n *\n * Ignored because not directly exposed.\n *\n * @ignore\n * @param {HTMLCanvasElement} canvas\n * @param {CanvasRenderingContext2D} context\n * @param {TextMetrics} metrics\n * @param {number} x\n * @param {number} y\n * @param {number} resolution\n * @param {TextStyle} style\n */\nfunction drawGlyph(canvas, context, metrics, x, y, resolution, style) {\n var char = metrics.text;\n var fontProperties = metrics.fontProperties;\n context.translate(x, y);\n context.scale(resolution, resolution);\n var tx = style.strokeThickness / 2;\n var ty = -(style.strokeThickness / 2);\n context.font = style.toFontString();\n context.lineWidth = style.strokeThickness;\n context.textBaseline = style.textBaseline;\n context.lineJoin = style.lineJoin;\n context.miterLimit = style.miterLimit;\n // set canvas text styles\n context.fillStyle = generateFillStyle(canvas, context, style, resolution, [char], metrics);\n context.strokeStyle = style.stroke;\n if (style.dropShadow) {\n var dropShadowColor = style.dropShadowColor;\n var rgb = hex2rgb(typeof dropShadowColor === 'number' ? dropShadowColor : string2hex(dropShadowColor));\n var dropShadowBlur = style.dropShadowBlur * resolution;\n var dropShadowDistance = style.dropShadowDistance * resolution;\n context.shadowColor = \"rgba(\" + rgb[0] * 255 + \",\" + rgb[1] * 255 + \",\" + rgb[2] * 255 + \",\" + style.dropShadowAlpha + \")\";\n context.shadowBlur = dropShadowBlur;\n context.shadowOffsetX = Math.cos(style.dropShadowAngle) * dropShadowDistance;\n context.shadowOffsetY = Math.sin(style.dropShadowAngle) * dropShadowDistance;\n }\n else {\n context.shadowColor = 'black';\n context.shadowBlur = 0;\n context.shadowOffsetX = 0;\n context.shadowOffsetY = 0;\n }\n if (style.stroke && style.strokeThickness) {\n context.strokeText(char, tx, ty + metrics.lineHeight - fontProperties.descent);\n }\n if (style.fill) {\n context.fillText(char, tx, ty + metrics.lineHeight - fontProperties.descent);\n }\n context.setTransform(1, 0, 0, 1, 0, 0); // defaults needed for older browsers (e.g. Opera 29)\n context.fillStyle = 'rgba(0, 0, 0, 0)';\n}\n\n/**\n * Ponyfill for IE because it doesn't support `Array.from`\n * @private\n */\nfunction splitTextToCharacters(text) {\n return Array.from ? Array.from(text) : text.split('');\n}\n\n/**\n * Processes the passed character set data and returns a flattened array of all the characters.\n *\n * Ignored because not directly exposed.\n *\n * @ignore\n * @param {string | string[] | string[][] } chars\n * @returns {string[]}\n */\nfunction resolveCharacters(chars) {\n // Split the chars string into individual characters\n if (typeof chars === 'string') {\n chars = [chars];\n }\n // Handle an array of characters+ranges\n var result = [];\n for (var i = 0, j = chars.length; i < j; i++) {\n var item = chars[i];\n // Handle range delimited by start/end chars\n if (Array.isArray(item)) {\n if (item.length !== 2) {\n throw new Error(\"[BitmapFont]: Invalid character range length, expecting 2 got \" + item.length + \".\");\n }\n var startCode = item[0].charCodeAt(0);\n var endCode = item[1].charCodeAt(0);\n if (endCode < startCode) {\n throw new Error('[BitmapFont]: Invalid character range.');\n }\n for (var i_1 = startCode, j_1 = endCode; i_1 <= j_1; i_1++) {\n result.push(String.fromCharCode(i_1));\n }\n }\n // Handle a character set string\n else {\n result.push.apply(result, splitTextToCharacters(item));\n }\n }\n if (result.length === 0) {\n throw new Error('[BitmapFont]: Empty set when resolving characters.');\n }\n return result;\n}\n\n/**\n * Ponyfill for IE because it doesn't support `codePointAt`\n * @private\n */\nfunction extractCharCode(str) {\n return str.codePointAt ? str.codePointAt(0) : str.charCodeAt(0);\n}\n\n/**\n * BitmapFont represents a typeface available for use with the BitmapText class. Use the `install`\n * method for adding a font to be used.\n *\n * @memberof PIXI\n */\nvar BitmapFont = /** @class */ (function () {\n /**\n * @param data\n * @param textures\n * @param ownsTextures - Setting to `true` will destroy page textures\n * when the font is uninstalled.\n */\n function BitmapFont(data, textures, ownsTextures) {\n var _a, _b;\n var info = data.info[0];\n var common = data.common[0];\n var page = data.page[0];\n var distanceField = data.distanceField[0];\n var res = getResolutionOfUrl(page.file);\n var pageTextures = {};\n this._ownsTextures = ownsTextures;\n this.font = info.face;\n this.size = info.size;\n this.lineHeight = common.lineHeight / res;\n this.chars = {};\n this.pageTextures = pageTextures;\n // Convert the input Texture, Textures or object\n // into a page Texture lookup by \"id\"\n for (var i = 0; i < data.page.length; i++) {\n var _c = data.page[i], id = _c.id, file = _c.file;\n pageTextures[id] = textures instanceof Array\n ? textures[i] : textures[file];\n // only MSDF and SDF fonts need no-premultiplied-alpha\n if ((distanceField === null || distanceField === void 0 ? void 0 : distanceField.fieldType) && distanceField.fieldType !== 'none') {\n pageTextures[id].baseTexture.alphaMode = ALPHA_MODES.NO_PREMULTIPLIED_ALPHA;\n }\n }\n // parse letters\n for (var i = 0; i < data.char.length; i++) {\n var _d = data.char[i], id = _d.id, page_1 = _d.page;\n var _e = data.char[i], x = _e.x, y = _e.y, width = _e.width, height = _e.height, xoffset = _e.xoffset, yoffset = _e.yoffset, xadvance = _e.xadvance;\n x /= res;\n y /= res;\n width /= res;\n height /= res;\n xoffset /= res;\n yoffset /= res;\n xadvance /= res;\n var rect = new Rectangle(x + (pageTextures[page_1].frame.x / res), y + (pageTextures[page_1].frame.y / res), width, height);\n this.chars[id] = {\n xOffset: xoffset,\n yOffset: yoffset,\n xAdvance: xadvance,\n kerning: {},\n texture: new Texture(pageTextures[page_1].baseTexture, rect),\n page: page_1,\n };\n }\n // parse kernings\n for (var i = 0; i < data.kerning.length; i++) {\n var _f = data.kerning[i], first = _f.first, second = _f.second, amount = _f.amount;\n first /= res;\n second /= res;\n amount /= res;\n if (this.chars[second]) {\n this.chars[second].kerning[first] = amount;\n }\n }\n // Store distance field information\n this.distanceFieldRange = distanceField === null || distanceField === void 0 ? void 0 : distanceField.distanceRange;\n this.distanceFieldType = (_b = (_a = distanceField === null || distanceField === void 0 ? void 0 : distanceField.fieldType) === null || _a === void 0 ? void 0 : _a.toLowerCase()) !== null && _b !== void 0 ? _b : 'none';\n }\n /** Remove references to created glyph textures. */\n BitmapFont.prototype.destroy = function () {\n for (var id in this.chars) {\n this.chars[id].texture.destroy();\n this.chars[id].texture = null;\n }\n for (var id in this.pageTextures) {\n if (this._ownsTextures) {\n this.pageTextures[id].destroy(true);\n }\n this.pageTextures[id] = null;\n }\n // Set readonly null.\n this.chars = null;\n this.pageTextures = null;\n };\n /**\n * Register a new bitmap font.\n *\n * @param data - The\n * characters map that could be provided as xml or raw string.\n * @param textures - List of textures for each page.\n * @param ownsTextures - Set to `true` to destroy page textures\n * when the font is uninstalled. By default fonts created with\n * `BitmapFont.from` or from the `BitmapFontLoader` are `true`.\n * @return {PIXI.BitmapFont} Result font object with font, size, lineHeight\n * and char fields.\n */\n BitmapFont.install = function (data, textures, ownsTextures) {\n var fontData;\n if (data instanceof BitmapFontData) {\n fontData = data;\n }\n else {\n var format = autoDetectFormat(data);\n if (!format) {\n throw new Error('Unrecognized data format for font.');\n }\n fontData = format.parse(data);\n }\n // Single texture, convert to list\n if (textures instanceof Texture) {\n textures = [textures];\n }\n var font = new BitmapFont(fontData, textures, ownsTextures);\n BitmapFont.available[font.font] = font;\n return font;\n };\n /**\n * Remove bitmap font by name.\n *\n * @param name - Name of the font to uninstall.\n */\n BitmapFont.uninstall = function (name) {\n var font = BitmapFont.available[name];\n if (!font) {\n throw new Error(\"No font found named '\" + name + \"'\");\n }\n font.destroy();\n delete BitmapFont.available[name];\n };\n /**\n * Generates a bitmap-font for the given style and character set. This does not support\n * kernings yet. With `style` properties, only the following non-layout properties are used:\n *\n * - {@link PIXI.TextStyle#dropShadow|dropShadow}\n * - {@link PIXI.TextStyle#dropShadowDistance|dropShadowDistance}\n * - {@link PIXI.TextStyle#dropShadowColor|dropShadowColor}\n * - {@link PIXI.TextStyle#dropShadowBlur|dropShadowBlur}\n * - {@link PIXI.TextStyle#dropShadowAngle|dropShadowAngle}\n * - {@link PIXI.TextStyle#fill|fill}\n * - {@link PIXI.TextStyle#fillGradientStops|fillGradientStops}\n * - {@link PIXI.TextStyle#fillGradientType|fillGradientType}\n * - {@link PIXI.TextStyle#fontFamily|fontFamily}\n * - {@link PIXI.TextStyle#fontSize|fontSize}\n * - {@link PIXI.TextStyle#fontVariant|fontVariant}\n * - {@link PIXI.TextStyle#fontWeight|fontWeight}\n * - {@link PIXI.TextStyle#lineJoin|lineJoin}\n * - {@link PIXI.TextStyle#miterLimit|miterLimit}\n * - {@link PIXI.TextStyle#stroke|stroke}\n * - {@link PIXI.TextStyle#strokeThickness|strokeThickness}\n * - {@link PIXI.TextStyle#textBaseline|textBaseline}\n *\n * @param name - The name of the custom font to use with BitmapText.\n * @param style - Style options to render with BitmapFont.\n * @param options - Setup options for font or name of the font.\n * @param {string|string[]|string[][]} [options.chars=PIXI.BitmapFont.ALPHANUMERIC] - characters included\n * in the font set. You can also use ranges. For example, `[['a', 'z'], ['A', 'Z'], \"!@#$%^&*()~{}[] \"]`.\n * Don't forget to include spaces ' ' in your character set!\n * @param {number} [options.resolution=1] - Render resolution for glyphs.\n * @param {number} [options.textureWidth=512] - Optional width of atlas, smaller values to reduce memory.\n * @param {number} [options.textureHeight=512] - Optional height of atlas, smaller values to reduce memory.\n * @param {number} [options.padding=4] - Padding between glyphs on texture atlas.\n * @return Font generated by style options.\n * @example\n * PIXI.BitmapFont.from(\"TitleFont\", {\n * fontFamily: \"Arial\",\n * fontSize: 12,\n * strokeThickness: 2,\n * fill: \"purple\"\n * });\n *\n * const title = new PIXI.BitmapText(\"This is the title\", { fontName: \"TitleFont\" });\n */\n BitmapFont.from = function (name, textStyle, options) {\n if (!name) {\n throw new Error('[BitmapFont] Property `name` is required.');\n }\n var _a = Object.assign({}, BitmapFont.defaultOptions, options), chars = _a.chars, padding = _a.padding, resolution = _a.resolution, textureWidth = _a.textureWidth, textureHeight = _a.textureHeight;\n var charsList = resolveCharacters(chars);\n var style = textStyle instanceof TextStyle ? textStyle : new TextStyle(textStyle);\n var lineWidth = textureWidth;\n var fontData = new BitmapFontData();\n fontData.info[0] = {\n face: style.fontFamily,\n size: style.fontSize,\n };\n fontData.common[0] = {\n lineHeight: style.fontSize,\n };\n var positionX = 0;\n var positionY = 0;\n var canvas;\n var context;\n var baseTexture;\n var maxCharHeight = 0;\n var textures = [];\n for (var i = 0; i < charsList.length; i++) {\n if (!canvas) {\n canvas = document.createElement('canvas');\n canvas.width = textureWidth;\n canvas.height = textureHeight;\n context = canvas.getContext('2d');\n baseTexture = new BaseTexture(canvas, { resolution: resolution });\n textures.push(new Texture(baseTexture));\n fontData.page.push({\n id: textures.length - 1,\n file: '',\n });\n }\n // Measure glyph dimensions\n var metrics = TextMetrics.measureText(charsList[i], style, false, canvas);\n var width = metrics.width;\n var height = Math.ceil(metrics.height);\n // This is ugly - but italics are given more space so they don't overlap\n var textureGlyphWidth = Math.ceil((style.fontStyle === 'italic' ? 2 : 1) * width);\n // Can't fit char anymore: next canvas please!\n if (positionY >= textureHeight - (height * resolution)) {\n if (positionY === 0) {\n // We don't want user debugging an infinite loop (or do we? :)\n throw new Error(\"[BitmapFont] textureHeight \" + textureHeight + \"px is \"\n + (\"too small for \" + style.fontSize + \"px fonts\"));\n }\n --i;\n // Create new atlas once current has filled up\n canvas = null;\n context = null;\n baseTexture = null;\n positionY = 0;\n positionX = 0;\n maxCharHeight = 0;\n continue;\n }\n maxCharHeight = Math.max(height + metrics.fontProperties.descent, maxCharHeight);\n // Wrap line once full row has been rendered\n if ((textureGlyphWidth * resolution) + positionX >= lineWidth) {\n --i;\n positionY += maxCharHeight * resolution;\n positionY = Math.ceil(positionY);\n positionX = 0;\n maxCharHeight = 0;\n continue;\n }\n drawGlyph(canvas, context, metrics, positionX, positionY, resolution, style);\n // Unique (numeric) ID mapping to this glyph\n var id = extractCharCode(metrics.text);\n // Create a texture holding just the glyph\n fontData.char.push({\n id: id,\n page: textures.length - 1,\n x: positionX / resolution,\n y: positionY / resolution,\n width: textureGlyphWidth,\n height: height,\n xoffset: 0,\n yoffset: 0,\n xadvance: Math.ceil(width\n - (style.dropShadow ? style.dropShadowDistance : 0)\n - (style.stroke ? style.strokeThickness : 0)),\n });\n positionX += (textureGlyphWidth + (2 * padding)) * resolution;\n positionX = Math.ceil(positionX);\n }\n // Brute-force kerning info, this can be expensive b/c it's an O(n²),\n // but we're using measureText which is native and fast.\n for (var i = 0, len = charsList.length; i < len; i++) {\n var first = charsList[i];\n for (var j = 0; j < len; j++) {\n var second = charsList[j];\n var c1 = context.measureText(first).width;\n var c2 = context.measureText(second).width;\n var total = context.measureText(first + second).width;\n var amount = total - (c1 + c2);\n if (amount) {\n fontData.kerning.push({\n first: extractCharCode(first),\n second: extractCharCode(second),\n amount: amount,\n });\n }\n }\n }\n var font = new BitmapFont(fontData, textures, true);\n // Make it easier to replace a font\n if (BitmapFont.available[name] !== undefined) {\n BitmapFont.uninstall(name);\n }\n BitmapFont.available[name] = font;\n return font;\n };\n /**\n * This character set includes all the letters in the alphabet (both lower- and upper- case).\n *\n * @type {string[][]}\n * @example\n * BitmapFont.from(\"ExampleFont\", style, { chars: BitmapFont.ALPHA })\n */\n BitmapFont.ALPHA = [['a', 'z'], ['A', 'Z'], ' '];\n /**\n * This character set includes all decimal digits (from 0 to 9).\n *\n * @type {string[][]}\n * @example\n * BitmapFont.from(\"ExampleFont\", style, { chars: BitmapFont.NUMERIC })\n */\n BitmapFont.NUMERIC = [['0', '9']];\n /**\n * This character set is the union of `BitmapFont.ALPHA` and `BitmapFont.NUMERIC`.\n *\n * @type {string[][]}\n */\n BitmapFont.ALPHANUMERIC = [['a', 'z'], ['A', 'Z'], ['0', '9'], ' '];\n /**\n * This character set consists of all the ASCII table.\n *\n * @member {string[][]}\n * @see http://www.asciitable.com/\n */\n BitmapFont.ASCII = [[' ', '~']];\n /**\n * Collection of default options when using `BitmapFont.from`.\n *\n * @property {number} resolution=1\n * @property {number} textureWidth=512\n * @property {number} textureHeight=512\n * @property {number} padding=4\n * @property {string|string[]|string[][]} chars = PIXI.BitmapFont.ALPHANUMERIC\n */\n BitmapFont.defaultOptions = {\n resolution: 1,\n textureWidth: 512,\n textureHeight: 512,\n padding: 4,\n chars: BitmapFont.ALPHANUMERIC,\n };\n /** Collection of available/installed fonts. */\n BitmapFont.available = {};\n return BitmapFont;\n}());\n\nvar msdfFrag = \"// Pixi texture info\\r\\nvarying vec2 vTextureCoord;\\r\\nuniform sampler2D uSampler;\\r\\n\\r\\n// Tint\\r\\nuniform vec4 uColor;\\r\\n\\r\\n// on 2D applications fwidth is screenScale / glyphAtlasScale * distanceFieldRange\\r\\nuniform float uFWidth;\\r\\n\\r\\nvoid main(void) {\\r\\n\\r\\n // To stack MSDF and SDF we need a non-pre-multiplied-alpha texture.\\r\\n vec4 texColor = texture2D(uSampler, vTextureCoord);\\r\\n\\r\\n // MSDF\\r\\n float median = texColor.r + texColor.g + texColor.b -\\r\\n min(texColor.r, min(texColor.g, texColor.b)) -\\r\\n max(texColor.r, max(texColor.g, texColor.b));\\r\\n // SDF\\r\\n median = min(median, texColor.a);\\r\\n\\r\\n float screenPxDistance = uFWidth * (median - 0.5);\\r\\n float alpha = clamp(screenPxDistance + 0.5, 0.0, 1.0);\\r\\n\\r\\n // NPM Textures, NPM outputs\\r\\n gl_FragColor = vec4(uColor.rgb, uColor.a * alpha);\\r\\n\\r\\n}\\r\\n\";\n\nvar msdfVert = \"// Mesh material default fragment\\r\\nattribute vec2 aVertexPosition;\\r\\nattribute vec2 aTextureCoord;\\r\\n\\r\\nuniform mat3 projectionMatrix;\\r\\nuniform mat3 translationMatrix;\\r\\nuniform mat3 uTextureMatrix;\\r\\n\\r\\nvarying vec2 vTextureCoord;\\r\\n\\r\\nvoid main(void)\\r\\n{\\r\\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\\r\\n\\r\\n vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\\r\\n}\\r\\n\";\n\n// If we ever need more than two pools, please make a Dict or something better.\nvar pageMeshDataDefaultPageMeshData = [];\nvar pageMeshDataMSDFPageMeshData = [];\nvar charRenderDataPool = [];\n/**\n * A BitmapText object will create a line or multiple lines of text using bitmap font.\n *\n * The primary advantage of this class over Text is that all of your textures are pre-generated and loading,\n * meaning that rendering is fast, and changing text has no performance implications.\n *\n * Supporting character sets other than latin, such as CJK languages, may be impractical due to the number of characters.\n *\n * To split a line you can use '\\n', '\\r' or '\\r\\n' in your string.\n *\n * PixiJS can auto-generate fonts on-the-fly using BitmapFont or use fnt files provided by:\n * http://www.angelcode.com/products/bmfont/ for Windows or\n * http://www.bmglyph.com/ for Mac.\n *\n * You can also use SDF, MSDF and MTSDF BitmapFonts for vector-like scaling appearance provided by:\n * https://github.com/soimy/msdf-bmfont-xml for SDF and MSDF fnt files or\n * https://github.com/Chlumsky/msdf-atlas-gen for SDF, MSDF and MTSDF json files\n *\n * A BitmapText can only be created when the font is loaded.\n *\n * ```js\n * // in this case the font is in a file called 'desyrel.fnt'\n * let bitmapText = new PIXI.BitmapText(\"text using a fancy font!\", {\n * fontName: \"Desyrel\",\n * fontSize: 35,\n * align: \"right\"\n * });\n * ```\n *\n * @memberof PIXI\n */\nvar BitmapText = /** @class */ (function (_super) {\n __extends(BitmapText, _super);\n /**\n * @param text - A string that you would like the text to display.\n * @param style - The style parameters.\n * @param {string} style.fontName - The installed BitmapFont name.\n * @param {number} [style.fontSize] - The size of the font in pixels, e.g. 24. If undefined,\n *. this will default to the BitmapFont size.\n * @param {string} [style.align='left'] - Alignment for multiline text ('left', 'center', 'right' or 'justify'),\n * does not affect single line text.\n * @param {number} [style.tint=0xFFFFFF] - The tint color.\n * @param {number} [style.letterSpacing=0] - The amount of spacing between letters.\n * @param {number} [style.maxWidth=0] - The max width of the text before line wrapping.\n */\n function BitmapText(text, style) {\n if (style === void 0) { style = {}; }\n var _this = _super.call(this) || this;\n /**\n * Private tracker for the current tint.\n *\n * @private\n */\n _this._tint = 0xFFFFFF;\n // Apply the defaults\n var _a = Object.assign({}, BitmapText.styleDefaults, style), align = _a.align, tint = _a.tint, maxWidth = _a.maxWidth, letterSpacing = _a.letterSpacing, fontName = _a.fontName, fontSize = _a.fontSize;\n if (!BitmapFont.available[fontName]) {\n throw new Error(\"Missing BitmapFont \\\"\" + fontName + \"\\\"\");\n }\n _this._activePagesMeshData = [];\n _this._textWidth = 0;\n _this._textHeight = 0;\n _this._align = align;\n _this._tint = tint;\n _this._fontName = fontName;\n _this._fontSize = fontSize || BitmapFont.available[fontName].size;\n _this._text = text;\n _this._maxWidth = maxWidth;\n _this._maxLineHeight = 0;\n _this._letterSpacing = letterSpacing;\n _this._anchor = new ObservablePoint(function () { _this.dirty = true; }, _this, 0, 0);\n _this._roundPixels = settings.ROUND_PIXELS;\n _this.dirty = true;\n _this._textureCache = {};\n return _this;\n }\n /**\n * Renders text and updates it when needed. This should only be called\n * if the BitmapFont is regenerated.\n */\n BitmapText.prototype.updateText = function () {\n var _a;\n var data = BitmapFont.available[this._fontName];\n var scale = this._fontSize / data.size;\n var pos = new Point();\n var chars = [];\n var lineWidths = [];\n var lineSpaces = [];\n var text = this._text.replace(/(?:\\r\\n|\\r)/g, '\\n') || ' ';\n var charsInput = splitTextToCharacters(text);\n var maxWidth = this._maxWidth * data.size / this._fontSize;\n var pageMeshDataPool = data.distanceFieldType === 'none'\n ? pageMeshDataDefaultPageMeshData : pageMeshDataMSDFPageMeshData;\n var prevCharCode = null;\n var lastLineWidth = 0;\n var maxLineWidth = 0;\n var line = 0;\n var lastBreakPos = -1;\n var lastBreakWidth = 0;\n var spacesRemoved = 0;\n var maxLineHeight = 0;\n var spaceCount = 0;\n for (var i = 0; i < charsInput.length; i++) {\n var char = charsInput[i];\n var charCode = extractCharCode(char);\n if ((/(?:\\s)/).test(char)) {\n lastBreakPos = i;\n lastBreakWidth = lastLineWidth;\n spaceCount++;\n }\n if (char === '\\r' || char === '\\n') {\n lineWidths.push(lastLineWidth);\n lineSpaces.push(-1);\n maxLineWidth = Math.max(maxLineWidth, lastLineWidth);\n ++line;\n ++spacesRemoved;\n pos.x = 0;\n pos.y += data.lineHeight;\n prevCharCode = null;\n spaceCount = 0;\n continue;\n }\n var charData = data.chars[charCode];\n if (!charData) {\n continue;\n }\n if (prevCharCode && charData.kerning[prevCharCode]) {\n pos.x += charData.kerning[prevCharCode];\n }\n var charRenderData = charRenderDataPool.pop() || {\n texture: Texture.EMPTY,\n line: 0,\n charCode: 0,\n prevSpaces: 0,\n position: new Point(),\n };\n charRenderData.texture = charData.texture;\n charRenderData.line = line;\n charRenderData.charCode = charCode;\n charRenderData.position.x = pos.x + charData.xOffset + (this._letterSpacing / 2);\n charRenderData.position.y = pos.y + charData.yOffset;\n charRenderData.prevSpaces = spaceCount;\n chars.push(charRenderData);\n lastLineWidth = charRenderData.position.x + Math.max(charData.xAdvance, charData.texture.orig.width);\n pos.x += charData.xAdvance + this._letterSpacing;\n maxLineHeight = Math.max(maxLineHeight, (charData.yOffset + charData.texture.height));\n prevCharCode = charCode;\n if (lastBreakPos !== -1 && maxWidth > 0 && pos.x > maxWidth) {\n ++spacesRemoved;\n removeItems(chars, 1 + lastBreakPos - spacesRemoved, 1 + i - lastBreakPos);\n i = lastBreakPos;\n lastBreakPos = -1;\n lineWidths.push(lastBreakWidth);\n lineSpaces.push(chars.length > 0 ? chars[chars.length - 1].prevSpaces : 0);\n maxLineWidth = Math.max(maxLineWidth, lastBreakWidth);\n line++;\n pos.x = 0;\n pos.y += data.lineHeight;\n prevCharCode = null;\n spaceCount = 0;\n }\n }\n var lastChar = charsInput[charsInput.length - 1];\n if (lastChar !== '\\r' && lastChar !== '\\n') {\n if ((/(?:\\s)/).test(lastChar)) {\n lastLineWidth = lastBreakWidth;\n }\n lineWidths.push(lastLineWidth);\n maxLineWidth = Math.max(maxLineWidth, lastLineWidth);\n lineSpaces.push(-1);\n }\n var lineAlignOffsets = [];\n for (var i = 0; i <= line; i++) {\n var alignOffset = 0;\n if (this._align === 'right') {\n alignOffset = maxLineWidth - lineWidths[i];\n }\n else if (this._align === 'center') {\n alignOffset = (maxLineWidth - lineWidths[i]) / 2;\n }\n else if (this._align === 'justify') {\n alignOffset = lineSpaces[i] < 0 ? 0 : (maxLineWidth - lineWidths[i]) / lineSpaces[i];\n }\n lineAlignOffsets.push(alignOffset);\n }\n var lenChars = chars.length;\n var pagesMeshData = {};\n var newPagesMeshData = [];\n var activePagesMeshData = this._activePagesMeshData;\n for (var i = 0; i < activePagesMeshData.length; i++) {\n pageMeshDataPool.push(activePagesMeshData[i]);\n }\n for (var i = 0; i < lenChars; i++) {\n var texture = chars[i].texture;\n var baseTextureUid = texture.baseTexture.uid;\n if (!pagesMeshData[baseTextureUid]) {\n var pageMeshData = pageMeshDataPool.pop();\n if (!pageMeshData) {\n var geometry = new MeshGeometry();\n var material = void 0;\n var meshBlendMode = void 0;\n if (data.distanceFieldType === 'none') {\n material = new MeshMaterial(Texture.EMPTY);\n meshBlendMode = BLEND_MODES.NORMAL;\n }\n else {\n material = new MeshMaterial(Texture.EMPTY, { program: Program.from(msdfVert, msdfFrag), uniforms: { uFWidth: 0 } });\n meshBlendMode = BLEND_MODES.NORMAL_NPM;\n }\n var mesh = new Mesh(geometry, material);\n mesh.blendMode = meshBlendMode;\n pageMeshData = {\n index: 0,\n indexCount: 0,\n vertexCount: 0,\n uvsCount: 0,\n total: 0,\n mesh: mesh,\n vertices: null,\n uvs: null,\n indices: null,\n };\n }\n // reset data..\n pageMeshData.index = 0;\n pageMeshData.indexCount = 0;\n pageMeshData.vertexCount = 0;\n pageMeshData.uvsCount = 0;\n pageMeshData.total = 0;\n // TODO need to get page texture here somehow..\n var _textureCache = this._textureCache;\n _textureCache[baseTextureUid] = _textureCache[baseTextureUid] || new Texture(texture.baseTexture);\n pageMeshData.mesh.texture = _textureCache[baseTextureUid];\n pageMeshData.mesh.tint = this._tint;\n newPagesMeshData.push(pageMeshData);\n pagesMeshData[baseTextureUid] = pageMeshData;\n }\n pagesMeshData[baseTextureUid].total++;\n }\n // lets find any previously active pageMeshDatas that are no longer required for\n // the updated text (if any), removed and return them to the pool.\n for (var i = 0; i < activePagesMeshData.length; i++) {\n if (newPagesMeshData.indexOf(activePagesMeshData[i]) === -1) {\n this.removeChild(activePagesMeshData[i].mesh);\n }\n }\n // next lets add any new meshes, that have not yet been added to this BitmapText\n // we only add if its not already a child of this BitmapObject\n for (var i = 0; i < newPagesMeshData.length; i++) {\n if (newPagesMeshData[i].mesh.parent !== this) {\n this.addChild(newPagesMeshData[i].mesh);\n }\n }\n // active page mesh datas are set to be the new pages added.\n this._activePagesMeshData = newPagesMeshData;\n for (var i in pagesMeshData) {\n var pageMeshData = pagesMeshData[i];\n var total = pageMeshData.total;\n // lets only allocate new buffers if we can fit the new text in the current ones..\n // unless that is, we will be batching. Currently batching dose not respect the size property of mesh\n if (!(((_a = pageMeshData.indices) === null || _a === void 0 ? void 0 : _a.length) > 6 * total) || pageMeshData.vertices.length < Mesh.BATCHABLE_SIZE * 2) {\n pageMeshData.vertices = new Float32Array(4 * 2 * total);\n pageMeshData.uvs = new Float32Array(4 * 2 * total);\n pageMeshData.indices = new Uint16Array(6 * total);\n }\n else {\n var total_1 = pageMeshData.total;\n var vertices = pageMeshData.vertices;\n // Clear the garbage at the end of the vertices buffer. This will prevent the bounds miscalculation.\n for (var i_1 = total_1 * 4 * 2; i_1 < vertices.length; i_1++) {\n vertices[i_1] = 0;\n }\n }\n // as a buffer maybe bigger than the current word, we set the size of the meshMaterial\n // to match the number of letters needed\n pageMeshData.mesh.size = 6 * total;\n }\n for (var i = 0; i < lenChars; i++) {\n var char = chars[i];\n var offset = char.position.x + (lineAlignOffsets[char.line] * (this._align === 'justify' ? char.prevSpaces : 1));\n if (this._roundPixels) {\n offset = Math.round(offset);\n }\n var xPos = offset * scale;\n var yPos = char.position.y * scale;\n var texture = char.texture;\n var pageMesh = pagesMeshData[texture.baseTexture.uid];\n var textureFrame = texture.frame;\n var textureUvs = texture._uvs;\n var index = pageMesh.index++;\n pageMesh.indices[(index * 6) + 0] = 0 + (index * 4);\n pageMesh.indices[(index * 6) + 1] = 1 + (index * 4);\n pageMesh.indices[(index * 6) + 2] = 2 + (index * 4);\n pageMesh.indices[(index * 6) + 3] = 0 + (index * 4);\n pageMesh.indices[(index * 6) + 4] = 2 + (index * 4);\n pageMesh.indices[(index * 6) + 5] = 3 + (index * 4);\n pageMesh.vertices[(index * 8) + 0] = xPos;\n pageMesh.vertices[(index * 8) + 1] = yPos;\n pageMesh.vertices[(index * 8) + 2] = xPos + (textureFrame.width * scale);\n pageMesh.vertices[(index * 8) + 3] = yPos;\n pageMesh.vertices[(index * 8) + 4] = xPos + (textureFrame.width * scale);\n pageMesh.vertices[(index * 8) + 5] = yPos + (textureFrame.height * scale);\n pageMesh.vertices[(index * 8) + 6] = xPos;\n pageMesh.vertices[(index * 8) + 7] = yPos + (textureFrame.height * scale);\n pageMesh.uvs[(index * 8) + 0] = textureUvs.x0;\n pageMesh.uvs[(index * 8) + 1] = textureUvs.y0;\n pageMesh.uvs[(index * 8) + 2] = textureUvs.x1;\n pageMesh.uvs[(index * 8) + 3] = textureUvs.y1;\n pageMesh.uvs[(index * 8) + 4] = textureUvs.x2;\n pageMesh.uvs[(index * 8) + 5] = textureUvs.y2;\n pageMesh.uvs[(index * 8) + 6] = textureUvs.x3;\n pageMesh.uvs[(index * 8) + 7] = textureUvs.y3;\n }\n this._textWidth = maxLineWidth * scale;\n this._textHeight = (pos.y + data.lineHeight) * scale;\n for (var i in pagesMeshData) {\n var pageMeshData = pagesMeshData[i];\n // apply anchor\n if (this.anchor.x !== 0 || this.anchor.y !== 0) {\n var vertexCount = 0;\n var anchorOffsetX = this._textWidth * this.anchor.x;\n var anchorOffsetY = this._textHeight * this.anchor.y;\n for (var i_2 = 0; i_2 < pageMeshData.total; i_2++) {\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetX;\n pageMeshData.vertices[vertexCount++] -= anchorOffsetY;\n }\n }\n this._maxLineHeight = maxLineHeight * scale;\n var vertexBuffer = pageMeshData.mesh.geometry.getBuffer('aVertexPosition');\n var textureBuffer = pageMeshData.mesh.geometry.getBuffer('aTextureCoord');\n var indexBuffer = pageMeshData.mesh.geometry.getIndex();\n vertexBuffer.data = pageMeshData.vertices;\n textureBuffer.data = pageMeshData.uvs;\n indexBuffer.data = pageMeshData.indices;\n vertexBuffer.update();\n textureBuffer.update();\n indexBuffer.update();\n }\n for (var i = 0; i < chars.length; i++) {\n charRenderDataPool.push(chars[i]);\n }\n };\n BitmapText.prototype.updateTransform = function () {\n this.validate();\n this.containerUpdateTransform();\n };\n BitmapText.prototype._render = function (renderer) {\n // Update the uniform\n var _a = BitmapFont.available[this._fontName], distanceFieldRange = _a.distanceFieldRange, distanceFieldType = _a.distanceFieldType, size = _a.size;\n if (distanceFieldType !== 'none') {\n // Inject the shader code with the correct value\n var _b = this.worldTransform, a = _b.a, b = _b.b, c = _b.c, d = _b.d;\n var dx = Math.sqrt((a * a) + (b * b));\n var dy = Math.sqrt((c * c) + (d * d));\n var worldScale = (Math.abs(dx) + Math.abs(dy)) / 2;\n var fontScale = this._fontSize / size;\n for (var _i = 0, _c = this._activePagesMeshData; _i < _c.length; _i++) {\n var mesh = _c[_i];\n mesh.mesh.shader.uniforms.uFWidth = worldScale * distanceFieldRange * fontScale * renderer.resolution;\n }\n }\n _super.prototype._render.call(this, renderer);\n };\n /**\n * Validates text before calling parent's getLocalBounds\n *\n * @return - The rectangular bounding area\n */\n BitmapText.prototype.getLocalBounds = function () {\n this.validate();\n return _super.prototype.getLocalBounds.call(this);\n };\n /**\n * Updates text when needed\n *\n * @private\n */\n BitmapText.prototype.validate = function () {\n if (this.dirty) {\n this.updateText();\n this.dirty = false;\n }\n };\n Object.defineProperty(BitmapText.prototype, \"tint\", {\n /**\n * The tint of the BitmapText object.\n *\n * @default 0xffffff\n */\n get: function () {\n return this._tint;\n },\n set: function (value) {\n if (this._tint === value)\n { return; }\n this._tint = value;\n for (var i = 0; i < this._activePagesMeshData.length; i++) {\n this._activePagesMeshData[i].mesh.tint = value;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"align\", {\n /**\n * The alignment of the BitmapText object.\n *\n * @member {string}\n * @default 'left'\n */\n get: function () {\n return this._align;\n },\n set: function (value) {\n if (this._align !== value) {\n this._align = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"fontName\", {\n /** The name of the BitmapFont. */\n get: function () {\n return this._fontName;\n },\n set: function (value) {\n if (!BitmapFont.available[value]) {\n throw new Error(\"Missing BitmapFont \\\"\" + value + \"\\\"\");\n }\n if (this._fontName !== value) {\n this._fontName = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"fontSize\", {\n /** The size of the font to display. */\n get: function () {\n return this._fontSize;\n },\n set: function (value) {\n if (this._fontSize !== value) {\n this._fontSize = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"anchor\", {\n /**\n * The anchor sets the origin point of the text.\n *\n * The default is `(0,0)`, this means the text's origin is the top left.\n *\n * Setting the anchor to `(0.5,0.5)` means the text's origin is centered.\n *\n * Setting the anchor to `(1,1)` would mean the text's origin point will be the bottom right corner.\n */\n get: function () {\n return this._anchor;\n },\n set: function (value) {\n if (typeof value === 'number') {\n this._anchor.set(value);\n }\n else {\n this._anchor.copyFrom(value);\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"text\", {\n /** The text of the BitmapText object. */\n get: function () {\n return this._text;\n },\n set: function (text) {\n text = String(text === null || text === undefined ? '' : text);\n if (this._text === text) {\n return;\n }\n this._text = text;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"maxWidth\", {\n /**\n * The max width of this bitmap text in pixels. If the text provided is longer than the\n * value provided, line breaks will be automatically inserted in the last whitespace.\n * Disable by setting the value to 0.\n */\n get: function () {\n return this._maxWidth;\n },\n set: function (value) {\n if (this._maxWidth === value) {\n return;\n }\n this._maxWidth = value;\n this.dirty = true;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"maxLineHeight\", {\n /**\n * The max line height. This is useful when trying to use the total height of the Text,\n * i.e. when trying to vertically align.\n *\n * @readonly\n */\n get: function () {\n this.validate();\n return this._maxLineHeight;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"textWidth\", {\n /**\n * The width of the overall text, different from fontSize,\n * which is defined in the style object.\n *\n * @readonly\n */\n get: function () {\n this.validate();\n return this._textWidth;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"letterSpacing\", {\n /** Additional space between characters. */\n get: function () {\n return this._letterSpacing;\n },\n set: function (value) {\n if (this._letterSpacing !== value) {\n this._letterSpacing = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"roundPixels\", {\n /**\n * If true PixiJS will Math.floor() x/y values when rendering, stopping pixel interpolation.\n * Advantages can include sharper image quality (like text) and faster rendering on canvas.\n * The main disadvantage is movement of objects may appear less smooth.\n * To set the global default, change {@link PIXI.settings.ROUND_PIXELS}\n *\n * @default PIXI.settings.ROUND_PIXELS\n */\n get: function () {\n return this._roundPixels;\n },\n set: function (value) {\n if (value !== this._roundPixels) {\n this._roundPixels = value;\n this.dirty = true;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BitmapText.prototype, \"textHeight\", {\n /**\n * The height of the overall text, different from fontSize,\n * which is defined in the style object.\n *\n * @readonly\n */\n get: function () {\n this.validate();\n return this._textHeight;\n },\n enumerable: false,\n configurable: true\n });\n BitmapText.prototype.destroy = function (options) {\n var _textureCache = this._textureCache;\n for (var id in _textureCache) {\n var texture = _textureCache[id];\n texture.destroy();\n delete _textureCache[id];\n }\n this._textureCache = null;\n _super.prototype.destroy.call(this, options);\n };\n BitmapText.styleDefaults = {\n align: 'left',\n tint: 0xFFFFFF,\n maxWidth: 0,\n letterSpacing: 0,\n };\n return BitmapText;\n}(Container));\n\n/**\n * {@link PIXI.Loader Loader} middleware for loading\n * bitmap-based fonts suitable for using with {@link PIXI.BitmapText}.\n *\n * @memberof PIXI\n */\nvar BitmapFontLoader = /** @class */ (function () {\n function BitmapFontLoader() {\n }\n /**\n * Called when the plugin is installed.\n *\n * @see PIXI.Loader.registerPlugin\n */\n BitmapFontLoader.add = function () {\n LoaderResource.setExtensionXhrType('fnt', LoaderResource.XHR_RESPONSE_TYPE.TEXT);\n };\n /**\n * Called after a resource is loaded.\n *\n * @see PIXI.Loader.loaderMiddleware\n * @param {PIXI.LoaderResource} resource\n * @param {function} next\n */\n BitmapFontLoader.use = function (resource, next) {\n var format = autoDetectFormat(resource.data);\n // Resource was not recognised as any of the expected font data format\n if (!format) {\n next();\n return;\n }\n var baseUrl = BitmapFontLoader.getBaseUrl(this, resource);\n var data = format.parse(resource.data);\n var textures = {};\n // Handle completed, when the number of textures\n // load is the same number as references in the fnt file\n var completed = function (page) {\n textures[page.metadata.pageFile] = page.texture;\n if (Object.keys(textures).length === data.page.length) {\n resource.bitmapFont = BitmapFont.install(data, textures, true);\n next();\n }\n };\n for (var i = 0; i < data.page.length; ++i) {\n var pageFile = data.page[i].file;\n var url = baseUrl + pageFile;\n var exists = false;\n // incase the image is loaded outside\n // using the same loader, resource will be available\n for (var name in this.resources) {\n var bitmapResource = this.resources[name];\n if (bitmapResource.url === url) {\n bitmapResource.metadata.pageFile = pageFile;\n if (bitmapResource.texture) {\n completed(bitmapResource);\n }\n else {\n bitmapResource.onAfterMiddleware.add(completed);\n }\n exists = true;\n break;\n }\n }\n // texture is not loaded, we'll attempt to add\n // it to the load and add the texture to the list\n if (!exists) {\n // Standard loading options for images\n var options = {\n crossOrigin: resource.crossOrigin,\n loadType: LoaderResource.LOAD_TYPE.IMAGE,\n metadata: Object.assign({ pageFile: pageFile }, resource.metadata.imageMetadata),\n parentResource: resource,\n };\n this.add(url, options, completed);\n }\n }\n };\n /** Get folder path from a resource. */\n BitmapFontLoader.getBaseUrl = function (loader, resource) {\n var resUrl = !resource.isDataUrl ? BitmapFontLoader.dirname(resource.url) : '';\n if (resource.isDataUrl) {\n if (resUrl === '.') {\n resUrl = '';\n }\n if (loader.baseUrl && resUrl) {\n // if baseurl has a trailing slash then add one to resUrl so the replace works below\n if (loader.baseUrl.charAt(loader.baseUrl.length - 1) === '/') {\n resUrl += '/';\n }\n }\n }\n // remove baseUrl from resUrl\n resUrl = resUrl.replace(loader.baseUrl, '');\n // if there is an resUrl now, it needs a trailing slash. Ensure that it does if the string isn't empty.\n if (resUrl && resUrl.charAt(resUrl.length - 1) !== '/') {\n resUrl += '/';\n }\n return resUrl;\n };\n /**\n * Replacement for NodeJS's path.dirname\n *\n * @param {string} url - Path to get directory for\n */\n BitmapFontLoader.dirname = function (url) {\n var dir = url\n .replace(/\\\\/g, '/') // convert windows notation to UNIX notation, URL-safe because it's a forbidden character\n .replace(/\\/$/, '') // replace trailing slash\n .replace(/\\/[^\\/]*$/, ''); // remove everything after the last\n // File request is relative, use current directory\n if (dir === url) {\n return '.';\n }\n // Started with a slash\n else if (dir === '') {\n return '/';\n }\n return dir;\n };\n return BitmapFontLoader;\n}());\n\nexport { BitmapFont, BitmapFontData, BitmapFontLoader, BitmapText };\n//# sourceMappingURL=text-bitmap.js.map\n","/*!\n * @pixi/filter-alpha - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-alpha is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { defaultVertex, Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"varying vec2 vTextureCoord;\\n\\nuniform sampler2D uSampler;\\nuniform float uAlpha;\\n\\nvoid main(void)\\n{\\n gl_FragColor = texture2D(uSampler, vTextureCoord) * uAlpha;\\n}\\n\";\n\n/**\n * Simplest filter - applies alpha.\n *\n * Use this instead of Container's alpha property to avoid visual layering of individual elements.\n * AlphaFilter applies alpha evenly across the entire display object and any opaque elements it contains.\n * If elements are not opaque, they will blend with each other anyway.\n *\n * Very handy if you want to use common features of all filters:\n *\n * 1. Assign a blendMode to this filter, blend all elements inside display object with background.\n *\n * 2. To use clipping in display coordinates, assign a filterArea to the same container that has this filter.\n *\n * @memberof PIXI.filters\n */\nvar AlphaFilter = /** @class */ (function (_super) {\n __extends(AlphaFilter, _super);\n /**\n * @param alpha - Amount of alpha from 0 to 1, where 0 is transparent\n */\n function AlphaFilter(alpha) {\n if (alpha === void 0) { alpha = 1.0; }\n var _this = _super.call(this, defaultVertex, fragment, { uAlpha: 1 }) || this;\n _this.alpha = alpha;\n return _this;\n }\n Object.defineProperty(AlphaFilter.prototype, \"alpha\", {\n /**\n * Coefficient for alpha multiplication\n *\n * @default 1\n */\n get: function () {\n return this.uniforms.uAlpha;\n },\n set: function (value) {\n this.uniforms.uAlpha = value;\n },\n enumerable: false,\n configurable: true\n });\n return AlphaFilter;\n}(Filter));\n\nexport { AlphaFilter };\n//# sourceMappingURL=filter-alpha.js.map\n","/*!\n * @pixi/filter-blur - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-blur is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Filter } from '@pixi/core';\nimport { settings } from '@pixi/settings';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar vertTemplate = \"\\n attribute vec2 aVertexPosition;\\n\\n uniform mat3 projectionMatrix;\\n\\n uniform float strength;\\n\\n varying vec2 vBlurTexCoords[%size%];\\n\\n uniform vec4 inputSize;\\n uniform vec4 outputFrame;\\n\\n vec4 filterVertexPosition( void )\\n {\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n }\\n\\n vec2 filterTextureCoord( void )\\n {\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n }\\n\\n void main(void)\\n {\\n gl_Position = filterVertexPosition();\\n\\n vec2 textureCoord = filterTextureCoord();\\n %blur%\\n }\";\nfunction generateBlurVertSource(kernelSize, x) {\n var halfLength = Math.ceil(kernelSize / 2);\n var vertSource = vertTemplate;\n var blurLoop = '';\n var template;\n if (x) {\n template = 'vBlurTexCoords[%index%] = textureCoord + vec2(%sampleIndex% * strength, 0.0);';\n }\n else {\n template = 'vBlurTexCoords[%index%] = textureCoord + vec2(0.0, %sampleIndex% * strength);';\n }\n for (var i = 0; i < kernelSize; i++) {\n var blur = template.replace('%index%', i.toString());\n blur = blur.replace('%sampleIndex%', i - (halfLength - 1) + \".0\");\n blurLoop += blur;\n blurLoop += '\\n';\n }\n vertSource = vertSource.replace('%blur%', blurLoop);\n vertSource = vertSource.replace('%size%', kernelSize.toString());\n return vertSource;\n}\n\nvar GAUSSIAN_VALUES = {\n 5: [0.153388, 0.221461, 0.250301],\n 7: [0.071303, 0.131514, 0.189879, 0.214607],\n 9: [0.028532, 0.067234, 0.124009, 0.179044, 0.20236],\n 11: [0.0093, 0.028002, 0.065984, 0.121703, 0.175713, 0.198596],\n 13: [0.002406, 0.009255, 0.027867, 0.065666, 0.121117, 0.174868, 0.197641],\n 15: [0.000489, 0.002403, 0.009246, 0.02784, 0.065602, 0.120999, 0.174697, 0.197448],\n};\nvar fragTemplate = [\n 'varying vec2 vBlurTexCoords[%size%];',\n 'uniform sampler2D uSampler;',\n 'void main(void)',\n '{',\n ' gl_FragColor = vec4(0.0);',\n ' %blur%',\n '}' ].join('\\n');\nfunction generateBlurFragSource(kernelSize) {\n var kernel = GAUSSIAN_VALUES[kernelSize];\n var halfLength = kernel.length;\n var fragSource = fragTemplate;\n var blurLoop = '';\n var template = 'gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;';\n var value;\n for (var i = 0; i < kernelSize; i++) {\n var blur = template.replace('%index%', i.toString());\n value = i;\n if (i >= halfLength) {\n value = kernelSize - i - 1;\n }\n blur = blur.replace('%value%', kernel[value].toString());\n blurLoop += blur;\n blurLoop += '\\n';\n }\n fragSource = fragSource.replace('%blur%', blurLoop);\n fragSource = fragSource.replace('%size%', kernelSize.toString());\n return fragSource;\n}\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\n/**\n * The BlurFilterPass applies a horizontal or vertical Gaussian blur to an object.\n *\n * @memberof PIXI.filters\n */\nvar BlurFilterPass = /** @class */ (function (_super) {\n __extends(BlurFilterPass, _super);\n /**\n * @param horizontal - Do pass along the x-axis (`true`) or y-axis (`false`).\n * @param strength - The strength of the blur filter.\n * @param quality - The quality of the blur filter.\n * @param resolution - The resolution of the blur filter.\n * @param kernelSize - The kernelSize of the blur filter.Options: 5, 7, 9, 11, 13, 15.\n */\n function BlurFilterPass(horizontal, strength, quality, resolution, kernelSize) {\n if (strength === void 0) { strength = 8; }\n if (quality === void 0) { quality = 4; }\n if (resolution === void 0) { resolution = settings.FILTER_RESOLUTION; }\n if (kernelSize === void 0) { kernelSize = 5; }\n var _this = this;\n var vertSrc = generateBlurVertSource(kernelSize, horizontal);\n var fragSrc = generateBlurFragSource(kernelSize);\n _this = _super.call(this, \n // vertex shader\n vertSrc, \n // fragment shader\n fragSrc) || this;\n _this.horizontal = horizontal;\n _this.resolution = resolution;\n _this._quality = 0;\n _this.quality = quality;\n _this.blur = strength;\n return _this;\n }\n /**\n * Applies the filter.\n *\n * @param filterManager - The manager.\n * @param input - The input target.\n * @param output - The output target.\n * @param clearMode - How to clear\n */\n BlurFilterPass.prototype.apply = function (filterManager, input, output, clearMode) {\n if (output) {\n if (this.horizontal) {\n this.uniforms.strength = (1 / output.width) * (output.width / input.width);\n }\n else {\n this.uniforms.strength = (1 / output.height) * (output.height / input.height);\n }\n }\n else {\n if (this.horizontal) // eslint-disable-line\n {\n this.uniforms.strength = (1 / filterManager.renderer.width) * (filterManager.renderer.width / input.width);\n }\n else {\n this.uniforms.strength = (1 / filterManager.renderer.height) * (filterManager.renderer.height / input.height); // eslint-disable-line\n }\n }\n // screen space!\n this.uniforms.strength *= this.strength;\n this.uniforms.strength /= this.passes;\n if (this.passes === 1) {\n filterManager.applyFilter(this, input, output, clearMode);\n }\n else {\n var renderTarget = filterManager.getFilterTexture();\n var renderer = filterManager.renderer;\n var flip = input;\n var flop = renderTarget;\n this.state.blend = false;\n filterManager.applyFilter(this, flip, flop, CLEAR_MODES.CLEAR);\n for (var i = 1; i < this.passes - 1; i++) {\n filterManager.bindAndClear(flip, CLEAR_MODES.BLIT);\n this.uniforms.uSampler = flop;\n var temp = flop;\n flop = flip;\n flip = temp;\n renderer.shader.bind(this);\n renderer.geometry.draw(5);\n }\n this.state.blend = true;\n filterManager.applyFilter(this, flop, output, clearMode);\n filterManager.returnFilterTexture(renderTarget);\n }\n };\n Object.defineProperty(BlurFilterPass.prototype, \"blur\", {\n /**\n * Sets the strength of both the blur.\n *\n * @default 16\n */\n get: function () {\n return this.strength;\n },\n set: function (value) {\n this.padding = 1 + (Math.abs(value) * 2);\n this.strength = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilterPass.prototype, \"quality\", {\n /**\n * Sets the quality of the blur by modifying the number of passes. More passes means higher\n * quality bluring but the lower the performance.\n *\n * @default 4\n */\n get: function () {\n return this._quality;\n },\n set: function (value) {\n this._quality = value;\n this.passes = value;\n },\n enumerable: false,\n configurable: true\n });\n return BlurFilterPass;\n}(Filter));\n\n/**\n * The BlurFilter applies a Gaussian blur to an object.\n *\n * The strength of the blur can be set for the x-axis and y-axis separately.\n *\n * @memberof PIXI.filters\n */\nvar BlurFilter = /** @class */ (function (_super) {\n __extends(BlurFilter, _super);\n /**\n * @param strength - The strength of the blur filter.\n * @param quality - The quality of the blur filter.\n * @param [resolution=PIXI.settings.FILTER_RESOLUTION] - The resolution of the blur filter.\n * @param kernelSize - The kernelSize of the blur filter.Options: 5, 7, 9, 11, 13, 15.\n */\n function BlurFilter(strength, quality, resolution, kernelSize) {\n if (strength === void 0) { strength = 8; }\n if (quality === void 0) { quality = 4; }\n if (resolution === void 0) { resolution = settings.FILTER_RESOLUTION; }\n if (kernelSize === void 0) { kernelSize = 5; }\n var _this = _super.call(this) || this;\n _this.blurXFilter = new BlurFilterPass(true, strength, quality, resolution, kernelSize);\n _this.blurYFilter = new BlurFilterPass(false, strength, quality, resolution, kernelSize);\n _this.resolution = resolution;\n _this.quality = quality;\n _this.blur = strength;\n _this.repeatEdgePixels = false;\n return _this;\n }\n /**\n * Applies the filter.\n *\n * @param filterManager - The manager.\n * @param input - The input target.\n * @param output - The output target.\n * @param clearMode - How to clear\n */\n BlurFilter.prototype.apply = function (filterManager, input, output, clearMode) {\n var xStrength = Math.abs(this.blurXFilter.strength);\n var yStrength = Math.abs(this.blurYFilter.strength);\n if (xStrength && yStrength) {\n var renderTarget = filterManager.getFilterTexture();\n this.blurXFilter.apply(filterManager, input, renderTarget, CLEAR_MODES.CLEAR);\n this.blurYFilter.apply(filterManager, renderTarget, output, clearMode);\n filterManager.returnFilterTexture(renderTarget);\n }\n else if (yStrength) {\n this.blurYFilter.apply(filterManager, input, output, clearMode);\n }\n else {\n this.blurXFilter.apply(filterManager, input, output, clearMode);\n }\n };\n BlurFilter.prototype.updatePadding = function () {\n if (this._repeatEdgePixels) {\n this.padding = 0;\n }\n else {\n this.padding = Math.max(Math.abs(this.blurXFilter.strength), Math.abs(this.blurYFilter.strength)) * 2;\n }\n };\n Object.defineProperty(BlurFilter.prototype, \"blur\", {\n /**\n * Sets the strength of both the blurX and blurY properties simultaneously\n *\n * @default 2\n */\n get: function () {\n return this.blurXFilter.blur;\n },\n set: function (value) {\n this.blurXFilter.blur = this.blurYFilter.blur = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"quality\", {\n /**\n * Sets the number of passes for blur. More passes means higher quality bluring.\n *\n * @default 1\n */\n get: function () {\n return this.blurXFilter.quality;\n },\n set: function (value) {\n this.blurXFilter.quality = this.blurYFilter.quality = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"blurX\", {\n /**\n * Sets the strength of the blurX property\n *\n * @default 2\n */\n get: function () {\n return this.blurXFilter.blur;\n },\n set: function (value) {\n this.blurXFilter.blur = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"blurY\", {\n /**\n * Sets the strength of the blurY property\n *\n * @default 2\n */\n get: function () {\n return this.blurYFilter.blur;\n },\n set: function (value) {\n this.blurYFilter.blur = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"blendMode\", {\n /**\n * Sets the blendmode of the filter\n *\n * @default PIXI.BLEND_MODES.NORMAL\n */\n get: function () {\n return this.blurYFilter.blendMode;\n },\n set: function (value) {\n this.blurYFilter.blendMode = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(BlurFilter.prototype, \"repeatEdgePixels\", {\n /**\n * If set to true the edge of the target will be clamped\n *\n * @default false\n */\n get: function () {\n return this._repeatEdgePixels;\n },\n set: function (value) {\n this._repeatEdgePixels = value;\n this.updatePadding();\n },\n enumerable: false,\n configurable: true\n });\n return BlurFilter;\n}(Filter));\n\nexport { BlurFilter, BlurFilterPass };\n//# sourceMappingURL=filter-blur.js.map\n","/*!\n * @pixi/filter-color-matrix - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-color-matrix is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { defaultFilterVertex, Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"varying vec2 vTextureCoord;\\nuniform sampler2D uSampler;\\nuniform float m[20];\\nuniform float uAlpha;\\n\\nvoid main(void)\\n{\\n vec4 c = texture2D(uSampler, vTextureCoord);\\n\\n if (uAlpha == 0.0) {\\n gl_FragColor = c;\\n return;\\n }\\n\\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\\n if (c.a > 0.0) {\\n c.rgb /= c.a;\\n }\\n\\n vec4 result;\\n\\n result.r = (m[0] * c.r);\\n result.r += (m[1] * c.g);\\n result.r += (m[2] * c.b);\\n result.r += (m[3] * c.a);\\n result.r += m[4];\\n\\n result.g = (m[5] * c.r);\\n result.g += (m[6] * c.g);\\n result.g += (m[7] * c.b);\\n result.g += (m[8] * c.a);\\n result.g += m[9];\\n\\n result.b = (m[10] * c.r);\\n result.b += (m[11] * c.g);\\n result.b += (m[12] * c.b);\\n result.b += (m[13] * c.a);\\n result.b += m[14];\\n\\n result.a = (m[15] * c.r);\\n result.a += (m[16] * c.g);\\n result.a += (m[17] * c.b);\\n result.a += (m[18] * c.a);\\n result.a += m[19];\\n\\n vec3 rgb = mix(c.rgb, result.rgb, uAlpha);\\n\\n // Premultiply alpha again.\\n rgb *= result.a;\\n\\n gl_FragColor = vec4(rgb, result.a);\\n}\\n\";\n\n/**\n * The ColorMatrixFilter class lets you apply a 5x4 matrix transformation on the RGBA\n * color and alpha values of every pixel on your displayObject to produce a result\n * with a new set of RGBA color and alpha values. It's pretty powerful!\n *\n * ```js\n * let colorMatrix = new PIXI.filters.ColorMatrixFilter();\n * container.filters = [colorMatrix];\n * colorMatrix.contrast(2);\n * ```\n * @author Clément Chenebault <clement@goodboydigital.com>\n * @memberof PIXI.filters\n */\nvar ColorMatrixFilter = /** @class */ (function (_super) {\n __extends(ColorMatrixFilter, _super);\n function ColorMatrixFilter() {\n var _this = this;\n var uniforms = {\n m: new Float32Array([1, 0, 0, 0, 0,\n 0, 1, 0, 0, 0,\n 0, 0, 1, 0, 0,\n 0, 0, 0, 1, 0]),\n uAlpha: 1,\n };\n _this = _super.call(this, defaultFilterVertex, fragment, uniforms) || this;\n _this.alpha = 1;\n return _this;\n }\n /**\n * Transforms current matrix and set the new one\n *\n * @param {number[]} matrix - 5x4 matrix\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype._loadMatrix = function (matrix, multiply) {\n if (multiply === void 0) { multiply = false; }\n var newMatrix = matrix;\n if (multiply) {\n this._multiply(newMatrix, this.uniforms.m, matrix);\n newMatrix = this._colorMatrix(newMatrix);\n }\n // set the new matrix\n this.uniforms.m = newMatrix;\n };\n /**\n * Multiplies two mat5's\n *\n * @private\n * @param out - 5x4 matrix the receiving matrix\n * @param a - 5x4 matrix the first operand\n * @param b - 5x4 matrix the second operand\n * @returns {number[]} 5x4 matrix\n */\n ColorMatrixFilter.prototype._multiply = function (out, a, b) {\n // Red Channel\n out[0] = (a[0] * b[0]) + (a[1] * b[5]) + (a[2] * b[10]) + (a[3] * b[15]);\n out[1] = (a[0] * b[1]) + (a[1] * b[6]) + (a[2] * b[11]) + (a[3] * b[16]);\n out[2] = (a[0] * b[2]) + (a[1] * b[7]) + (a[2] * b[12]) + (a[3] * b[17]);\n out[3] = (a[0] * b[3]) + (a[1] * b[8]) + (a[2] * b[13]) + (a[3] * b[18]);\n out[4] = (a[0] * b[4]) + (a[1] * b[9]) + (a[2] * b[14]) + (a[3] * b[19]) + a[4];\n // Green Channel\n out[5] = (a[5] * b[0]) + (a[6] * b[5]) + (a[7] * b[10]) + (a[8] * b[15]);\n out[6] = (a[5] * b[1]) + (a[6] * b[6]) + (a[7] * b[11]) + (a[8] * b[16]);\n out[7] = (a[5] * b[2]) + (a[6] * b[7]) + (a[7] * b[12]) + (a[8] * b[17]);\n out[8] = (a[5] * b[3]) + (a[6] * b[8]) + (a[7] * b[13]) + (a[8] * b[18]);\n out[9] = (a[5] * b[4]) + (a[6] * b[9]) + (a[7] * b[14]) + (a[8] * b[19]) + a[9];\n // Blue Channel\n out[10] = (a[10] * b[0]) + (a[11] * b[5]) + (a[12] * b[10]) + (a[13] * b[15]);\n out[11] = (a[10] * b[1]) + (a[11] * b[6]) + (a[12] * b[11]) + (a[13] * b[16]);\n out[12] = (a[10] * b[2]) + (a[11] * b[7]) + (a[12] * b[12]) + (a[13] * b[17]);\n out[13] = (a[10] * b[3]) + (a[11] * b[8]) + (a[12] * b[13]) + (a[13] * b[18]);\n out[14] = (a[10] * b[4]) + (a[11] * b[9]) + (a[12] * b[14]) + (a[13] * b[19]) + a[14];\n // Alpha Channel\n out[15] = (a[15] * b[0]) + (a[16] * b[5]) + (a[17] * b[10]) + (a[18] * b[15]);\n out[16] = (a[15] * b[1]) + (a[16] * b[6]) + (a[17] * b[11]) + (a[18] * b[16]);\n out[17] = (a[15] * b[2]) + (a[16] * b[7]) + (a[17] * b[12]) + (a[18] * b[17]);\n out[18] = (a[15] * b[3]) + (a[16] * b[8]) + (a[17] * b[13]) + (a[18] * b[18]);\n out[19] = (a[15] * b[4]) + (a[16] * b[9]) + (a[17] * b[14]) + (a[18] * b[19]) + a[19];\n return out;\n };\n /**\n * Create a Float32 Array and normalize the offset component to 0-1\n *\n * @param {number[]} matrix - 5x4 matrix\n * @return {number[]} 5x4 matrix with all values between 0-1\n */\n ColorMatrixFilter.prototype._colorMatrix = function (matrix) {\n // Create a Float32 Array and normalize the offset component to 0-1\n var m = new Float32Array(matrix);\n m[4] /= 255;\n m[9] /= 255;\n m[14] /= 255;\n m[19] /= 255;\n return m;\n };\n /**\n * Adjusts brightness\n *\n * @param b - value of the brigthness (0-1, where 0 is black)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.brightness = function (b, multiply) {\n var matrix = [\n b, 0, 0, 0, 0,\n 0, b, 0, 0, 0,\n 0, 0, b, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Sets each channel on the diagonal of the color matrix.\n * This can be used to achieve a tinting effect on Containers similar to the tint field of some\n * display objects like Sprite, Text, Graphics, and Mesh.\n *\n * @param color - Color of the tint. This is a hex value.\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.tint = function (color, multiply) {\n var r = (color >> 16) & 0xff;\n var g = (color >> 8) & 0xff;\n var b = color & 0xff;\n var matrix = [\n r / 255, 0, 0, 0, 0,\n 0, g / 255, 0, 0, 0,\n 0, 0, b / 255, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the matrices in grey scales\n *\n * @param scale - value of the grey (0-1, where 0 is black)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.greyscale = function (scale, multiply) {\n var matrix = [\n scale, scale, scale, 0, 0,\n scale, scale, scale, 0, 0,\n scale, scale, scale, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the black and white matrice.\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.blackAndWhite = function (multiply) {\n var matrix = [\n 0.3, 0.6, 0.1, 0, 0,\n 0.3, 0.6, 0.1, 0, 0,\n 0.3, 0.6, 0.1, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the hue property of the color\n *\n * @param rotation - in degrees\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.hue = function (rotation, multiply) {\n rotation = (rotation || 0) / 180 * Math.PI;\n var cosR = Math.cos(rotation);\n var sinR = Math.sin(rotation);\n var sqrt = Math.sqrt;\n /* a good approximation for hue rotation\n This matrix is far better than the versions with magic luminance constants\n formerly used here, but also used in the starling framework (flash) and known from this\n old part of the internet: quasimondo.com/archives/000565.php\n\n This new matrix is based on rgb cube rotation in space. Look here for a more descriptive\n implementation as a shader not a general matrix:\n https://github.com/evanw/glfx.js/blob/58841c23919bd59787effc0333a4897b43835412/src/filters/adjust/huesaturation.js\n\n This is the source for the code:\n see http://stackoverflow.com/questions/8507885/shift-hue-of-an-rgb-color/8510751#8510751\n */\n var w = 1 / 3;\n var sqrW = sqrt(w); // weight is\n var a00 = cosR + ((1.0 - cosR) * w);\n var a01 = (w * (1.0 - cosR)) - (sqrW * sinR);\n var a02 = (w * (1.0 - cosR)) + (sqrW * sinR);\n var a10 = (w * (1.0 - cosR)) + (sqrW * sinR);\n var a11 = cosR + (w * (1.0 - cosR));\n var a12 = (w * (1.0 - cosR)) - (sqrW * sinR);\n var a20 = (w * (1.0 - cosR)) - (sqrW * sinR);\n var a21 = (w * (1.0 - cosR)) + (sqrW * sinR);\n var a22 = cosR + (w * (1.0 - cosR));\n var matrix = [\n a00, a01, a02, 0, 0,\n a10, a11, a12, 0, 0,\n a20, a21, a22, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the contrast matrix, increase the separation between dark and bright\n * Increase contrast : shadows darker and highlights brighter\n * Decrease contrast : bring the shadows up and the highlights down\n *\n * @param amount - value of the contrast (0-1)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.contrast = function (amount, multiply) {\n var v = (amount || 0) + 1;\n var o = -0.5 * (v - 1);\n var matrix = [\n v, 0, 0, 0, o,\n 0, v, 0, 0, o,\n 0, 0, v, 0, o,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Set the saturation matrix, increase the separation between colors\n * Increase saturation : increase contrast, brightness, and sharpness\n *\n * @param amount - The saturation amount (0-1)\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.saturate = function (amount, multiply) {\n if (amount === void 0) { amount = 0; }\n var x = (amount * 2 / 3) + 1;\n var y = ((x - 1) * -0.5);\n var matrix = [\n x, y, y, 0, 0,\n y, x, y, 0, 0,\n y, y, x, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Desaturate image (remove color)\n *\n * Call the saturate function\n */\n ColorMatrixFilter.prototype.desaturate = function () {\n this.saturate(-1);\n };\n /**\n * Negative image (inverse of classic rgb matrix)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.negative = function (multiply) {\n var matrix = [\n -1, 0, 0, 1, 0,\n 0, -1, 0, 1, 0,\n 0, 0, -1, 1, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Sepia image\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.sepia = function (multiply) {\n var matrix = [\n 0.393, 0.7689999, 0.18899999, 0, 0,\n 0.349, 0.6859999, 0.16799999, 0, 0,\n 0.272, 0.5339999, 0.13099999, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Color motion picture process invented in 1916 (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.technicolor = function (multiply) {\n var matrix = [\n 1.9125277891456083, -0.8545344976951645, -0.09155508482755585, 0, 11.793603434377337,\n -0.3087833385928097, 1.7658908555458428, -0.10601743074722245, 0, -70.35205161461398,\n -0.231103377548616, -0.7501899197440212, 1.847597816108189, 0, 30.950940869491138,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Polaroid filter\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.polaroid = function (multiply) {\n var matrix = [\n 1.438, -0.062, -0.062, 0, 0,\n -0.122, 1.378, -0.122, 0, 0,\n -0.016, -0.016, 1.483, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Filter who transforms : Red -> Blue and Blue -> Red\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.toBGR = function (multiply) {\n var matrix = [\n 0, 0, 1, 0, 0,\n 0, 1, 0, 0, 0,\n 1, 0, 0, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Color reversal film introduced by Eastman Kodak in 1935. (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.kodachrome = function (multiply) {\n var matrix = [\n 1.1285582396593525, -0.3967382283601348, -0.03992559172921793, 0, 63.72958762196502,\n -0.16404339962244616, 1.0835251566291304, -0.05498805115633132, 0, 24.732407896706203,\n -0.16786010706155763, -0.5603416277695248, 1.6014850761964943, 0, 35.62982807460946,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Brown delicious browni filter (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.browni = function (multiply) {\n var matrix = [\n 0.5997023498159715, 0.34553243048391263, -0.2708298674538042, 0, 47.43192855600873,\n -0.037703249837783157, 0.8609577587992641, 0.15059552388459913, 0, -36.96841498319127,\n 0.24113635128153335, -0.07441037908422492, 0.44972182064877153, 0, -7.562075277591283,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Vintage filter (thanks Dominic Szablewski)\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.vintage = function (multiply) {\n var matrix = [\n 0.6279345635605994, 0.3202183420819367, -0.03965408211312453, 0, 9.651285835294123,\n 0.02578397704808868, 0.6441188644374771, 0.03259127616149294, 0, 7.462829176470591,\n 0.0466055556782719, -0.0851232987247891, 0.5241648018700465, 0, 5.159190588235296,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * We don't know exactly what it does, kind of gradient map, but funny to play with!\n *\n * @param desaturation - Tone values.\n * @param toned - Tone values.\n * @param lightColor - Tone values, example: `0xFFE580`\n * @param darkColor - Tone values, example: `0xFFE580`\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.colorTone = function (desaturation, toned, lightColor, darkColor, multiply) {\n desaturation = desaturation || 0.2;\n toned = toned || 0.15;\n lightColor = lightColor || 0xFFE580;\n darkColor = darkColor || 0x338000;\n var lR = ((lightColor >> 16) & 0xFF) / 255;\n var lG = ((lightColor >> 8) & 0xFF) / 255;\n var lB = (lightColor & 0xFF) / 255;\n var dR = ((darkColor >> 16) & 0xFF) / 255;\n var dG = ((darkColor >> 8) & 0xFF) / 255;\n var dB = (darkColor & 0xFF) / 255;\n var matrix = [\n 0.3, 0.59, 0.11, 0, 0,\n lR, lG, lB, desaturation, 0,\n dR, dG, dB, toned, 0,\n lR - dR, lG - dG, lB - dB, 0, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Night effect\n *\n * @param intensity - The intensity of the night effect.\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.night = function (intensity, multiply) {\n intensity = intensity || 0.1;\n var matrix = [\n intensity * (-2.0), -intensity, 0, 0, 0,\n -intensity, 0, intensity, 0, 0,\n 0, intensity, intensity * 2.0, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * Predator effect\n *\n * Erase the current matrix by setting a new indepent one\n *\n * @param amount - how much the predator feels his future victim\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.predator = function (amount, multiply) {\n var matrix = [\n // row 1\n 11.224130630493164 * amount,\n -4.794486999511719 * amount,\n -2.8746118545532227 * amount,\n 0 * amount,\n 0.40342438220977783 * amount,\n // row 2\n -3.6330697536468506 * amount,\n 9.193157196044922 * amount,\n -2.951810836791992 * amount,\n 0 * amount,\n -1.316135048866272 * amount,\n // row 3\n -3.2184197902679443 * amount,\n -4.2375030517578125 * amount,\n 7.476448059082031 * amount,\n 0 * amount,\n 0.8044459223747253 * amount,\n // row 4\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /**\n * LSD effect\n *\n * Multiply the current matrix\n *\n * @param multiply - if true, current matrix and matrix are multiplied. If false,\n * just set the current matrix with @param matrix\n */\n ColorMatrixFilter.prototype.lsd = function (multiply) {\n var matrix = [\n 2, -0.4, 0.5, 0, 0,\n -0.5, 2, -0.4, 0, 0,\n -0.4, -0.5, 3, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, multiply);\n };\n /** Erase the current matrix by setting the default one. */\n ColorMatrixFilter.prototype.reset = function () {\n var matrix = [\n 1, 0, 0, 0, 0,\n 0, 1, 0, 0, 0,\n 0, 0, 1, 0, 0,\n 0, 0, 0, 1, 0 ];\n this._loadMatrix(matrix, false);\n };\n Object.defineProperty(ColorMatrixFilter.prototype, \"matrix\", {\n /**\n * The matrix of the color matrix filter\n *\n * @member {number[]}\n * @default [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0]\n */\n get: function () {\n return this.uniforms.m;\n },\n set: function (value) {\n this.uniforms.m = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ColorMatrixFilter.prototype, \"alpha\", {\n /**\n * The opacity value to use when mixing the original and resultant colors.\n *\n * When the value is 0, the original color is used without modification.\n * When the value is 1, the result color is used.\n * When in the range (0, 1) the color is interpolated between the original and result by this amount.\n *\n * @default 1\n */\n get: function () {\n return this.uniforms.uAlpha;\n },\n set: function (value) {\n this.uniforms.uAlpha = value;\n },\n enumerable: false,\n configurable: true\n });\n return ColorMatrixFilter;\n}(Filter));\n// Americanized alias\nColorMatrixFilter.prototype.grayscale = ColorMatrixFilter.prototype.greyscale;\n\nexport { ColorMatrixFilter };\n//# sourceMappingURL=filter-color-matrix.js.map\n","/*!\n * @pixi/filter-displacement - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-displacement is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Filter } from '@pixi/core';\nimport { Matrix, Point } from '@pixi/math';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"varying vec2 vFilterCoord;\\nvarying vec2 vTextureCoord;\\n\\nuniform vec2 scale;\\nuniform mat2 rotation;\\nuniform sampler2D uSampler;\\nuniform sampler2D mapSampler;\\n\\nuniform highp vec4 inputSize;\\nuniform vec4 inputClamp;\\n\\nvoid main(void)\\n{\\n vec4 map = texture2D(mapSampler, vFilterCoord);\\n\\n map -= 0.5;\\n map.xy = scale * inputSize.zw * (rotation * map.xy);\\n\\n gl_FragColor = texture2D(uSampler, clamp(vec2(vTextureCoord.x + map.x, vTextureCoord.y + map.y), inputClamp.xy, inputClamp.zw));\\n}\\n\";\n\nvar vertex = \"attribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\nuniform mat3 filterMatrix;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec2 vFilterCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvec2 filterTextureCoord( void )\\n{\\n return aVertexPosition * (outputFrame.zw * inputSize.zw);\\n}\\n\\nvoid main(void)\\n{\\n\\tgl_Position = filterVertexPosition();\\n\\tvTextureCoord = filterTextureCoord();\\n\\tvFilterCoord = ( filterMatrix * vec3( vTextureCoord, 1.0) ).xy;\\n}\\n\";\n\n/**\n * The DisplacementFilter class uses the pixel values from the specified texture\n * (called the displacement map) to perform a displacement of an object.\n *\n * You can use this filter to apply all manor of crazy warping effects.\n * Currently the `r` property of the texture is used to offset the `x`\n * and the `g` property of the texture is used to offset the `y`.\n *\n * The way it works is it uses the values of the displacement map to look up the\n * correct pixels to output. This means it's not technically moving the original.\n * Instead, it's starting at the output and asking \"which pixel from the original goes here\".\n * For example, if a displacement map pixel has `red = 1` and the filter scale is `20`,\n * this filter will output the pixel approximately 20 pixels to the right of the original.\n *\n * @memberof PIXI.filters\n */\nvar DisplacementFilter = /** @class */ (function (_super) {\n __extends(DisplacementFilter, _super);\n /**\n * @param {PIXI.Sprite} sprite - The sprite used for the displacement map. (make sure its added to the scene!)\n * @param scale - The scale of the displacement\n */\n function DisplacementFilter(sprite, scale) {\n var _this = this;\n var maskMatrix = new Matrix();\n sprite.renderable = false;\n _this = _super.call(this, vertex, fragment, {\n mapSampler: sprite._texture,\n filterMatrix: maskMatrix,\n scale: { x: 1, y: 1 },\n rotation: new Float32Array([1, 0, 0, 1]),\n }) || this;\n _this.maskSprite = sprite;\n _this.maskMatrix = maskMatrix;\n if (scale === null || scale === undefined) {\n scale = 20;\n }\n /**\n * scaleX, scaleY for displacements\n * @member {PIXI.Point}\n */\n _this.scale = new Point(scale, scale);\n return _this;\n }\n /**\n * Applies the filter.\n *\n * @param filterManager - The manager.\n * @param input - The input target.\n * @param output - The output target.\n * @param clearMode - clearMode.\n */\n DisplacementFilter.prototype.apply = function (filterManager, input, output, clearMode) {\n // fill maskMatrix with _normalized sprite texture coords_\n this.uniforms.filterMatrix = filterManager.calculateSpriteMatrix(this.maskMatrix, this.maskSprite);\n this.uniforms.scale.x = this.scale.x;\n this.uniforms.scale.y = this.scale.y;\n // Extract rotation from world transform\n var wt = this.maskSprite.worldTransform;\n var lenX = Math.sqrt((wt.a * wt.a) + (wt.b * wt.b));\n var lenY = Math.sqrt((wt.c * wt.c) + (wt.d * wt.d));\n if (lenX !== 0 && lenY !== 0) {\n this.uniforms.rotation[0] = wt.a / lenX;\n this.uniforms.rotation[1] = wt.b / lenX;\n this.uniforms.rotation[2] = wt.c / lenY;\n this.uniforms.rotation[3] = wt.d / lenY;\n }\n // draw the filter...\n filterManager.applyFilter(this, input, output, clearMode);\n };\n Object.defineProperty(DisplacementFilter.prototype, \"map\", {\n /** The texture used for the displacement map. Must be power of 2 sized texture. */\n get: function () {\n return this.uniforms.mapSampler;\n },\n set: function (value) {\n this.uniforms.mapSampler = value;\n },\n enumerable: false,\n configurable: true\n });\n return DisplacementFilter;\n}(Filter));\n\nexport { DisplacementFilter };\n//# sourceMappingURL=filter-displacement.js.map\n","/*!\n * @pixi/filter-fxaa - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-fxaa is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar vertex = \"\\nattribute vec2 aVertexPosition;\\n\\nuniform mat3 projectionMatrix;\\n\\nvarying vec2 v_rgbNW;\\nvarying vec2 v_rgbNE;\\nvarying vec2 v_rgbSW;\\nvarying vec2 v_rgbSE;\\nvarying vec2 v_rgbM;\\n\\nvarying vec2 vFragCoord;\\n\\nuniform vec4 inputSize;\\nuniform vec4 outputFrame;\\n\\nvec4 filterVertexPosition( void )\\n{\\n vec2 position = aVertexPosition * max(outputFrame.zw, vec2(0.)) + outputFrame.xy;\\n\\n return vec4((projectionMatrix * vec3(position, 1.0)).xy, 0.0, 1.0);\\n}\\n\\nvoid texcoords(vec2 fragCoord, vec2 inverseVP,\\n out vec2 v_rgbNW, out vec2 v_rgbNE,\\n out vec2 v_rgbSW, out vec2 v_rgbSE,\\n out vec2 v_rgbM) {\\n v_rgbNW = (fragCoord + vec2(-1.0, -1.0)) * inverseVP;\\n v_rgbNE = (fragCoord + vec2(1.0, -1.0)) * inverseVP;\\n v_rgbSW = (fragCoord + vec2(-1.0, 1.0)) * inverseVP;\\n v_rgbSE = (fragCoord + vec2(1.0, 1.0)) * inverseVP;\\n v_rgbM = vec2(fragCoord * inverseVP);\\n}\\n\\nvoid main(void) {\\n\\n gl_Position = filterVertexPosition();\\n\\n vFragCoord = aVertexPosition * outputFrame.zw;\\n\\n texcoords(vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\\n}\\n\";\n\nvar fragment = \"varying vec2 v_rgbNW;\\nvarying vec2 v_rgbNE;\\nvarying vec2 v_rgbSW;\\nvarying vec2 v_rgbSE;\\nvarying vec2 v_rgbM;\\n\\nvarying vec2 vFragCoord;\\nuniform sampler2D uSampler;\\nuniform highp vec4 inputSize;\\n\\n\\n/**\\n Basic FXAA implementation based on the code on geeks3d.com with the\\n modification that the texture2DLod stuff was removed since it's\\n unsupported by WebGL.\\n\\n --\\n\\n From:\\n https://github.com/mitsuhiko/webgl-meincraft\\n\\n Copyright (c) 2011 by Armin Ronacher.\\n\\n Some rights reserved.\\n\\n Redistribution and use in source and binary forms, with or without\\n modification, are permitted provided that the following conditions are\\n met:\\n\\n * Redistributions of source code must retain the above copyright\\n notice, this list of conditions and the following disclaimer.\\n\\n * Redistributions in binary form must reproduce the above\\n copyright notice, this list of conditions and the following\\n disclaimer in the documentation and/or other materials provided\\n with the distribution.\\n\\n * The names of the contributors may not be used to endorse or\\n promote products derived from this software without specific\\n prior written permission.\\n\\n THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\\n \\\"AS IS\\\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\\n LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\\n A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\\n OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\\n SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\\n LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\\n DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\\n THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\\n (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\\n OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\\n */\\n\\n#ifndef FXAA_REDUCE_MIN\\n#define FXAA_REDUCE_MIN (1.0/ 128.0)\\n#endif\\n#ifndef FXAA_REDUCE_MUL\\n#define FXAA_REDUCE_MUL (1.0 / 8.0)\\n#endif\\n#ifndef FXAA_SPAN_MAX\\n#define FXAA_SPAN_MAX 8.0\\n#endif\\n\\n//optimized version for mobile, where dependent\\n//texture reads can be a bottleneck\\nvec4 fxaa(sampler2D tex, vec2 fragCoord, vec2 inverseVP,\\n vec2 v_rgbNW, vec2 v_rgbNE,\\n vec2 v_rgbSW, vec2 v_rgbSE,\\n vec2 v_rgbM) {\\n vec4 color;\\n vec3 rgbNW = texture2D(tex, v_rgbNW).xyz;\\n vec3 rgbNE = texture2D(tex, v_rgbNE).xyz;\\n vec3 rgbSW = texture2D(tex, v_rgbSW).xyz;\\n vec3 rgbSE = texture2D(tex, v_rgbSE).xyz;\\n vec4 texColor = texture2D(tex, v_rgbM);\\n vec3 rgbM = texColor.xyz;\\n vec3 luma = vec3(0.299, 0.587, 0.114);\\n float lumaNW = dot(rgbNW, luma);\\n float lumaNE = dot(rgbNE, luma);\\n float lumaSW = dot(rgbSW, luma);\\n float lumaSE = dot(rgbSE, luma);\\n float lumaM = dot(rgbM, luma);\\n float lumaMin = min(lumaM, min(min(lumaNW, lumaNE), min(lumaSW, lumaSE)));\\n float lumaMax = max(lumaM, max(max(lumaNW, lumaNE), max(lumaSW, lumaSE)));\\n\\n mediump vec2 dir;\\n dir.x = -((lumaNW + lumaNE) - (lumaSW + lumaSE));\\n dir.y = ((lumaNW + lumaSW) - (lumaNE + lumaSE));\\n\\n float dirReduce = max((lumaNW + lumaNE + lumaSW + lumaSE) *\\n (0.25 * FXAA_REDUCE_MUL), FXAA_REDUCE_MIN);\\n\\n float rcpDirMin = 1.0 / (min(abs(dir.x), abs(dir.y)) + dirReduce);\\n dir = min(vec2(FXAA_SPAN_MAX, FXAA_SPAN_MAX),\\n max(vec2(-FXAA_SPAN_MAX, -FXAA_SPAN_MAX),\\n dir * rcpDirMin)) * inverseVP;\\n\\n vec3 rgbA = 0.5 * (\\n texture2D(tex, fragCoord * inverseVP + dir * (1.0 / 3.0 - 0.5)).xyz +\\n texture2D(tex, fragCoord * inverseVP + dir * (2.0 / 3.0 - 0.5)).xyz);\\n vec3 rgbB = rgbA * 0.5 + 0.25 * (\\n texture2D(tex, fragCoord * inverseVP + dir * -0.5).xyz +\\n texture2D(tex, fragCoord * inverseVP + dir * 0.5).xyz);\\n\\n float lumaB = dot(rgbB, luma);\\n if ((lumaB < lumaMin) || (lumaB > lumaMax))\\n color = vec4(rgbA, texColor.a);\\n else\\n color = vec4(rgbB, texColor.a);\\n return color;\\n}\\n\\nvoid main() {\\n\\n vec4 color;\\n\\n color = fxaa(uSampler, vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\\n\\n gl_FragColor = color;\\n}\\n\";\n\n/**\n * Basic FXAA (Fast Approximate Anti-Aliasing) implementation based on the code on geeks3d.com\n * with the modification that the texture2DLod stuff was removed since it is unsupported by WebGL.\n *\n * @see https://github.com/mitsuhiko/webgl-meincraft\n *\n * @memberof PIXI.filters\n */\nvar FXAAFilter = /** @class */ (function (_super) {\n __extends(FXAAFilter, _super);\n function FXAAFilter() {\n // TODO - needs work\n return _super.call(this, vertex, fragment) || this;\n }\n return FXAAFilter;\n}(Filter));\n\nexport { FXAAFilter };\n//# sourceMappingURL=filter-fxaa.js.map\n","/*!\n * @pixi/filter-noise - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/filter-noise is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { defaultFilterVertex, Filter } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\nvar fragment = \"precision highp float;\\n\\nvarying vec2 vTextureCoord;\\nvarying vec4 vColor;\\n\\nuniform float uNoise;\\nuniform float uSeed;\\nuniform sampler2D uSampler;\\n\\nfloat rand(vec2 co)\\n{\\n return fract(sin(dot(co.xy, vec2(12.9898, 78.233))) * 43758.5453);\\n}\\n\\nvoid main()\\n{\\n vec4 color = texture2D(uSampler, vTextureCoord);\\n float randomValue = rand(gl_FragCoord.xy * uSeed);\\n float diff = (randomValue - 0.5) * uNoise;\\n\\n // Un-premultiply alpha before applying the color matrix. See issue #3539.\\n if (color.a > 0.0) {\\n color.rgb /= color.a;\\n }\\n\\n color.r += diff;\\n color.g += diff;\\n color.b += diff;\\n\\n // Premultiply alpha again.\\n color.rgb *= color.a;\\n\\n gl_FragColor = color;\\n}\\n\";\n\n/**\n * A Noise effect filter.\n *\n * original filter: https://github.com/evanw/glfx.js/blob/master/src/filters/adjust/noise.js\n *\n * @memberof PIXI.filters\n * @author Vico @vicocotea\n */\nvar NoiseFilter = /** @class */ (function (_super) {\n __extends(NoiseFilter, _super);\n /**\n * @param {number} [noise=0.5] - The noise intensity, should be a normalized value in the range [0, 1].\n * @param {number} [seed] - A random seed for the noise generation. Default is `Math.random()`.\n */\n function NoiseFilter(noise, seed) {\n if (noise === void 0) { noise = 0.5; }\n if (seed === void 0) { seed = Math.random(); }\n var _this = _super.call(this, defaultFilterVertex, fragment, {\n uNoise: 0,\n uSeed: 0,\n }) || this;\n _this.noise = noise;\n _this.seed = seed;\n return _this;\n }\n Object.defineProperty(NoiseFilter.prototype, \"noise\", {\n /**\n * The amount of noise to apply, this value should be in the range (0, 1].\n *\n * @default 0.5\n */\n get: function () {\n return this.uniforms.uNoise;\n },\n set: function (value) {\n this.uniforms.uNoise = value;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NoiseFilter.prototype, \"seed\", {\n /** A seed value to apply to the random noise generation. `Math.random()` is a good value to use. */\n get: function () {\n return this.uniforms.uSeed;\n },\n set: function (value) {\n this.uniforms.uSeed = value;\n },\n enumerable: false,\n configurable: true\n });\n return NoiseFilter;\n}(Filter));\n\nexport { NoiseFilter };\n//# sourceMappingURL=filter-noise.js.map\n","/*!\n * @pixi/mixin-cache-as-bitmap - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mixin-cache-as-bitmap is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { RenderTexture, BaseTexture, Texture } from '@pixi/core';\nimport { Sprite } from '@pixi/sprite';\nimport { DisplayObject } from '@pixi/display';\nimport { Matrix } from '@pixi/math';\nimport { uid } from '@pixi/utils';\nimport { settings } from '@pixi/settings';\n\n/*!\n * @pixi/constants - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/constants is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\n/**\n * Different types of environments for WebGL.\n *\n * @static\n * @memberof PIXI\n * @name ENV\n * @enum {number}\n * @property {number} WEBGL_LEGACY - Used for older v1 WebGL devices. PixiJS will aim to ensure compatibility\n * with older / less advanced devices. If you experience unexplained flickering prefer this environment.\n * @property {number} WEBGL - Version 1 of WebGL\n * @property {number} WEBGL2 - Version 2 of WebGL\n */\nvar ENV;\n(function (ENV) {\n ENV[ENV[\"WEBGL_LEGACY\"] = 0] = \"WEBGL_LEGACY\";\n ENV[ENV[\"WEBGL\"] = 1] = \"WEBGL\";\n ENV[ENV[\"WEBGL2\"] = 2] = \"WEBGL2\";\n})(ENV || (ENV = {}));\n/**\n * Constant to identify the Renderer Type.\n *\n * @static\n * @memberof PIXI\n * @name RENDERER_TYPE\n * @enum {number}\n * @property {number} UNKNOWN - Unknown render type.\n * @property {number} WEBGL - WebGL render type.\n * @property {number} CANVAS - Canvas render type.\n */\nvar RENDERER_TYPE;\n(function (RENDERER_TYPE) {\n RENDERER_TYPE[RENDERER_TYPE[\"UNKNOWN\"] = 0] = \"UNKNOWN\";\n RENDERER_TYPE[RENDERER_TYPE[\"WEBGL\"] = 1] = \"WEBGL\";\n RENDERER_TYPE[RENDERER_TYPE[\"CANVAS\"] = 2] = \"CANVAS\";\n})(RENDERER_TYPE || (RENDERER_TYPE = {}));\n/**\n * Bitwise OR of masks that indicate the buffers to be cleared.\n *\n * @static\n * @memberof PIXI\n * @name BUFFER_BITS\n * @enum {number}\n * @property {number} COLOR - Indicates the buffers currently enabled for color writing.\n * @property {number} DEPTH - Indicates the depth buffer.\n * @property {number} STENCIL - Indicates the stencil buffer.\n */\nvar BUFFER_BITS;\n(function (BUFFER_BITS) {\n BUFFER_BITS[BUFFER_BITS[\"COLOR\"] = 16384] = \"COLOR\";\n BUFFER_BITS[BUFFER_BITS[\"DEPTH\"] = 256] = \"DEPTH\";\n BUFFER_BITS[BUFFER_BITS[\"STENCIL\"] = 1024] = \"STENCIL\";\n})(BUFFER_BITS || (BUFFER_BITS = {}));\n/**\n * Various blend modes supported by PIXI.\n *\n * IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.\n * Anything else will silently act like NORMAL.\n *\n * @memberof PIXI\n * @name BLEND_MODES\n * @enum {number}\n * @property {number} NORMAL\n * @property {number} ADD\n * @property {number} MULTIPLY\n * @property {number} SCREEN\n * @property {number} OVERLAY\n * @property {number} DARKEN\n * @property {number} LIGHTEN\n * @property {number} COLOR_DODGE\n * @property {number} COLOR_BURN\n * @property {number} HARD_LIGHT\n * @property {number} SOFT_LIGHT\n * @property {number} DIFFERENCE\n * @property {number} EXCLUSION\n * @property {number} HUE\n * @property {number} SATURATION\n * @property {number} COLOR\n * @property {number} LUMINOSITY\n * @property {number} NORMAL_NPM\n * @property {number} ADD_NPM\n * @property {number} SCREEN_NPM\n * @property {number} NONE\n * @property {number} SRC_IN\n * @property {number} SRC_OUT\n * @property {number} SRC_ATOP\n * @property {number} DST_OVER\n * @property {number} DST_IN\n * @property {number} DST_OUT\n * @property {number} DST_ATOP\n * @property {number} SUBTRACT\n * @property {number} SRC_OVER\n * @property {number} ERASE\n * @property {number} XOR\n */\nvar BLEND_MODES;\n(function (BLEND_MODES) {\n BLEND_MODES[BLEND_MODES[\"NORMAL\"] = 0] = \"NORMAL\";\n BLEND_MODES[BLEND_MODES[\"ADD\"] = 1] = \"ADD\";\n BLEND_MODES[BLEND_MODES[\"MULTIPLY\"] = 2] = \"MULTIPLY\";\n BLEND_MODES[BLEND_MODES[\"SCREEN\"] = 3] = \"SCREEN\";\n BLEND_MODES[BLEND_MODES[\"OVERLAY\"] = 4] = \"OVERLAY\";\n BLEND_MODES[BLEND_MODES[\"DARKEN\"] = 5] = \"DARKEN\";\n BLEND_MODES[BLEND_MODES[\"LIGHTEN\"] = 6] = \"LIGHTEN\";\n BLEND_MODES[BLEND_MODES[\"COLOR_DODGE\"] = 7] = \"COLOR_DODGE\";\n BLEND_MODES[BLEND_MODES[\"COLOR_BURN\"] = 8] = \"COLOR_BURN\";\n BLEND_MODES[BLEND_MODES[\"HARD_LIGHT\"] = 9] = \"HARD_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"SOFT_LIGHT\"] = 10] = \"SOFT_LIGHT\";\n BLEND_MODES[BLEND_MODES[\"DIFFERENCE\"] = 11] = \"DIFFERENCE\";\n BLEND_MODES[BLEND_MODES[\"EXCLUSION\"] = 12] = \"EXCLUSION\";\n BLEND_MODES[BLEND_MODES[\"HUE\"] = 13] = \"HUE\";\n BLEND_MODES[BLEND_MODES[\"SATURATION\"] = 14] = \"SATURATION\";\n BLEND_MODES[BLEND_MODES[\"COLOR\"] = 15] = \"COLOR\";\n BLEND_MODES[BLEND_MODES[\"LUMINOSITY\"] = 16] = \"LUMINOSITY\";\n BLEND_MODES[BLEND_MODES[\"NORMAL_NPM\"] = 17] = \"NORMAL_NPM\";\n BLEND_MODES[BLEND_MODES[\"ADD_NPM\"] = 18] = \"ADD_NPM\";\n BLEND_MODES[BLEND_MODES[\"SCREEN_NPM\"] = 19] = \"SCREEN_NPM\";\n BLEND_MODES[BLEND_MODES[\"NONE\"] = 20] = \"NONE\";\n BLEND_MODES[BLEND_MODES[\"SRC_OVER\"] = 0] = \"SRC_OVER\";\n BLEND_MODES[BLEND_MODES[\"SRC_IN\"] = 21] = \"SRC_IN\";\n BLEND_MODES[BLEND_MODES[\"SRC_OUT\"] = 22] = \"SRC_OUT\";\n BLEND_MODES[BLEND_MODES[\"SRC_ATOP\"] = 23] = \"SRC_ATOP\";\n BLEND_MODES[BLEND_MODES[\"DST_OVER\"] = 24] = \"DST_OVER\";\n BLEND_MODES[BLEND_MODES[\"DST_IN\"] = 25] = \"DST_IN\";\n BLEND_MODES[BLEND_MODES[\"DST_OUT\"] = 26] = \"DST_OUT\";\n BLEND_MODES[BLEND_MODES[\"DST_ATOP\"] = 27] = \"DST_ATOP\";\n BLEND_MODES[BLEND_MODES[\"ERASE\"] = 26] = \"ERASE\";\n BLEND_MODES[BLEND_MODES[\"SUBTRACT\"] = 28] = \"SUBTRACT\";\n BLEND_MODES[BLEND_MODES[\"XOR\"] = 29] = \"XOR\";\n})(BLEND_MODES || (BLEND_MODES = {}));\n/**\n * Various webgl draw modes. These can be used to specify which GL drawMode to use\n * under certain situations and renderers.\n *\n * @memberof PIXI\n * @static\n * @name DRAW_MODES\n * @enum {number}\n * @property {number} POINTS\n * @property {number} LINES\n * @property {number} LINE_LOOP\n * @property {number} LINE_STRIP\n * @property {number} TRIANGLES\n * @property {number} TRIANGLE_STRIP\n * @property {number} TRIANGLE_FAN\n */\nvar DRAW_MODES;\n(function (DRAW_MODES) {\n DRAW_MODES[DRAW_MODES[\"POINTS\"] = 0] = \"POINTS\";\n DRAW_MODES[DRAW_MODES[\"LINES\"] = 1] = \"LINES\";\n DRAW_MODES[DRAW_MODES[\"LINE_LOOP\"] = 2] = \"LINE_LOOP\";\n DRAW_MODES[DRAW_MODES[\"LINE_STRIP\"] = 3] = \"LINE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLES\"] = 4] = \"TRIANGLES\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_STRIP\"] = 5] = \"TRIANGLE_STRIP\";\n DRAW_MODES[DRAW_MODES[\"TRIANGLE_FAN\"] = 6] = \"TRIANGLE_FAN\";\n})(DRAW_MODES || (DRAW_MODES = {}));\n/**\n * Various GL texture/resources formats.\n *\n * @memberof PIXI\n * @static\n * @name FORMATS\n * @enum {number}\n * @property {number} RGBA=6408\n * @property {number} RGB=6407\n * @property {number} RG=33319\n * @property {number} RED=6403\n * @property {number} RGBA_INTEGER=36249\n * @property {number} RGB_INTEGER=36248\n * @property {number} RG_INTEGER=33320\n * @property {number} RED_INTEGER=36244\n * @property {number} ALPHA=6406\n * @property {number} LUMINANCE=6409\n * @property {number} LUMINANCE_ALPHA=6410\n * @property {number} DEPTH_COMPONENT=6402\n * @property {number} DEPTH_STENCIL=34041\n */\nvar FORMATS;\n(function (FORMATS) {\n FORMATS[FORMATS[\"RGBA\"] = 6408] = \"RGBA\";\n FORMATS[FORMATS[\"RGB\"] = 6407] = \"RGB\";\n FORMATS[FORMATS[\"RG\"] = 33319] = \"RG\";\n FORMATS[FORMATS[\"RED\"] = 6403] = \"RED\";\n FORMATS[FORMATS[\"RGBA_INTEGER\"] = 36249] = \"RGBA_INTEGER\";\n FORMATS[FORMATS[\"RGB_INTEGER\"] = 36248] = \"RGB_INTEGER\";\n FORMATS[FORMATS[\"RG_INTEGER\"] = 33320] = \"RG_INTEGER\";\n FORMATS[FORMATS[\"RED_INTEGER\"] = 36244] = \"RED_INTEGER\";\n FORMATS[FORMATS[\"ALPHA\"] = 6406] = \"ALPHA\";\n FORMATS[FORMATS[\"LUMINANCE\"] = 6409] = \"LUMINANCE\";\n FORMATS[FORMATS[\"LUMINANCE_ALPHA\"] = 6410] = \"LUMINANCE_ALPHA\";\n FORMATS[FORMATS[\"DEPTH_COMPONENT\"] = 6402] = \"DEPTH_COMPONENT\";\n FORMATS[FORMATS[\"DEPTH_STENCIL\"] = 34041] = \"DEPTH_STENCIL\";\n})(FORMATS || (FORMATS = {}));\n/**\n * Various GL target types.\n *\n * @memberof PIXI\n * @static\n * @name TARGETS\n * @enum {number}\n * @property {number} TEXTURE_2D=3553\n * @property {number} TEXTURE_CUBE_MAP=34067\n * @property {number} TEXTURE_2D_ARRAY=35866\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_X=34069\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_X=34070\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Y=34071\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Y=34072\n * @property {number} TEXTURE_CUBE_MAP_POSITIVE_Z=34073\n * @property {number} TEXTURE_CUBE_MAP_NEGATIVE_Z=34074\n */\nvar TARGETS;\n(function (TARGETS) {\n TARGETS[TARGETS[\"TEXTURE_2D\"] = 3553] = \"TEXTURE_2D\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP\"] = 34067] = \"TEXTURE_CUBE_MAP\";\n TARGETS[TARGETS[\"TEXTURE_2D_ARRAY\"] = 35866] = \"TEXTURE_2D_ARRAY\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_X\"] = 34069] = \"TEXTURE_CUBE_MAP_POSITIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_X\"] = 34070] = \"TEXTURE_CUBE_MAP_NEGATIVE_X\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Y\"] = 34071] = \"TEXTURE_CUBE_MAP_POSITIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Y\"] = 34072] = \"TEXTURE_CUBE_MAP_NEGATIVE_Y\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_POSITIVE_Z\"] = 34073] = \"TEXTURE_CUBE_MAP_POSITIVE_Z\";\n TARGETS[TARGETS[\"TEXTURE_CUBE_MAP_NEGATIVE_Z\"] = 34074] = \"TEXTURE_CUBE_MAP_NEGATIVE_Z\";\n})(TARGETS || (TARGETS = {}));\n/**\n * Various GL data format types.\n *\n * @memberof PIXI\n * @static\n * @name TYPES\n * @enum {number}\n * @property {number} UNSIGNED_BYTE=5121\n * @property {number} UNSIGNED_SHORT=5123\n * @property {number} UNSIGNED_SHORT_5_6_5=33635\n * @property {number} UNSIGNED_SHORT_4_4_4_4=32819\n * @property {number} UNSIGNED_SHORT_5_5_5_1=32820\n * @property {number} UNSIGNED_INT=5125\n * @property {number} UNSIGNED_INT_10F_11F_11F_REV=35899\n * @property {number} UNSIGNED_INT_2_10_10_10_REV=33640\n * @property {number} UNSIGNED_INT_24_8=34042\n * @property {number} UNSIGNED_INT_5_9_9_9_REV=35902\n * @property {number} BYTE=5120\n * @property {number} SHORT=5122\n * @property {number} INT=5124\n * @property {number} FLOAT=5126\n * @property {number} FLOAT_32_UNSIGNED_INT_24_8_REV=36269\n * @property {number} HALF_FLOAT=36193\n */\nvar TYPES;\n(function (TYPES) {\n TYPES[TYPES[\"UNSIGNED_BYTE\"] = 5121] = \"UNSIGNED_BYTE\";\n TYPES[TYPES[\"UNSIGNED_SHORT\"] = 5123] = \"UNSIGNED_SHORT\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_6_5\"] = 33635] = \"UNSIGNED_SHORT_5_6_5\";\n TYPES[TYPES[\"UNSIGNED_SHORT_4_4_4_4\"] = 32819] = \"UNSIGNED_SHORT_4_4_4_4\";\n TYPES[TYPES[\"UNSIGNED_SHORT_5_5_5_1\"] = 32820] = \"UNSIGNED_SHORT_5_5_5_1\";\n TYPES[TYPES[\"UNSIGNED_INT\"] = 5125] = \"UNSIGNED_INT\";\n TYPES[TYPES[\"UNSIGNED_INT_10F_11F_11F_REV\"] = 35899] = \"UNSIGNED_INT_10F_11F_11F_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_2_10_10_10_REV\"] = 33640] = \"UNSIGNED_INT_2_10_10_10_REV\";\n TYPES[TYPES[\"UNSIGNED_INT_24_8\"] = 34042] = \"UNSIGNED_INT_24_8\";\n TYPES[TYPES[\"UNSIGNED_INT_5_9_9_9_REV\"] = 35902] = \"UNSIGNED_INT_5_9_9_9_REV\";\n TYPES[TYPES[\"BYTE\"] = 5120] = \"BYTE\";\n TYPES[TYPES[\"SHORT\"] = 5122] = \"SHORT\";\n TYPES[TYPES[\"INT\"] = 5124] = \"INT\";\n TYPES[TYPES[\"FLOAT\"] = 5126] = \"FLOAT\";\n TYPES[TYPES[\"FLOAT_32_UNSIGNED_INT_24_8_REV\"] = 36269] = \"FLOAT_32_UNSIGNED_INT_24_8_REV\";\n TYPES[TYPES[\"HALF_FLOAT\"] = 36193] = \"HALF_FLOAT\";\n})(TYPES || (TYPES = {}));\n/**\n * Various sampler types. Correspond to `sampler`, `isampler`, `usampler` GLSL types respectively.\n * WebGL1 works only with FLOAT.\n *\n * @memberof PIXI\n * @static\n * @name SAMPLER_TYPES\n * @enum {number}\n * @property {number} FLOAT=0\n * @property {number} INT=1\n * @property {number} UINT=2\n */\nvar SAMPLER_TYPES;\n(function (SAMPLER_TYPES) {\n SAMPLER_TYPES[SAMPLER_TYPES[\"FLOAT\"] = 0] = \"FLOAT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"INT\"] = 1] = \"INT\";\n SAMPLER_TYPES[SAMPLER_TYPES[\"UINT\"] = 2] = \"UINT\";\n})(SAMPLER_TYPES || (SAMPLER_TYPES = {}));\n/**\n * The scale modes that are supported by pixi.\n *\n * The {@link PIXI.settings.SCALE_MODE} scale mode affects the default scaling mode of future operations.\n * It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.\n *\n * @memberof PIXI\n * @static\n * @name SCALE_MODES\n * @enum {number}\n * @property {number} LINEAR Smooth scaling\n * @property {number} NEAREST Pixelating scaling\n */\nvar SCALE_MODES;\n(function (SCALE_MODES) {\n SCALE_MODES[SCALE_MODES[\"NEAREST\"] = 0] = \"NEAREST\";\n SCALE_MODES[SCALE_MODES[\"LINEAR\"] = 1] = \"LINEAR\";\n})(SCALE_MODES || (SCALE_MODES = {}));\n/**\n * The wrap modes that are supported by pixi.\n *\n * The {@link PIXI.settings.WRAP_MODE} wrap mode affects the default wrapping mode of future operations.\n * It can be re-assigned to either CLAMP or REPEAT, depending upon suitability.\n * If the texture is non power of two then clamp will be used regardless as WebGL can\n * only use REPEAT if the texture is po2.\n *\n * This property only affects WebGL.\n *\n * @name WRAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} CLAMP - The textures uvs are clamped\n * @property {number} REPEAT - The texture uvs tile and repeat\n * @property {number} MIRRORED_REPEAT - The texture uvs tile and repeat with mirroring\n */\nvar WRAP_MODES;\n(function (WRAP_MODES) {\n WRAP_MODES[WRAP_MODES[\"CLAMP\"] = 33071] = \"CLAMP\";\n WRAP_MODES[WRAP_MODES[\"REPEAT\"] = 10497] = \"REPEAT\";\n WRAP_MODES[WRAP_MODES[\"MIRRORED_REPEAT\"] = 33648] = \"MIRRORED_REPEAT\";\n})(WRAP_MODES || (WRAP_MODES = {}));\n/**\n * Mipmap filtering modes that are supported by pixi.\n *\n * The {@link PIXI.settings.MIPMAP_TEXTURES} affects default texture filtering.\n * Mipmaps are generated for a baseTexture if its `mipmap` field is `ON`,\n * or its `POW2` and texture dimensions are powers of 2.\n * Due to platform restriction, `ON` option will work like `POW2` for webgl-1.\n *\n * This property only affects WebGL.\n *\n * @name MIPMAP_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} OFF - No mipmaps\n * @property {number} POW2 - Generate mipmaps if texture dimensions are pow2\n * @property {number} ON - Always generate mipmaps\n * @property {number} ON_MANUAL - Use mipmaps, but do not auto-generate them; this is used with a resource\n * that supports buffering each level-of-detail.\n */\nvar MIPMAP_MODES;\n(function (MIPMAP_MODES) {\n MIPMAP_MODES[MIPMAP_MODES[\"OFF\"] = 0] = \"OFF\";\n MIPMAP_MODES[MIPMAP_MODES[\"POW2\"] = 1] = \"POW2\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON\"] = 2] = \"ON\";\n MIPMAP_MODES[MIPMAP_MODES[\"ON_MANUAL\"] = 3] = \"ON_MANUAL\";\n})(MIPMAP_MODES || (MIPMAP_MODES = {}));\n/**\n * How to treat textures with premultiplied alpha\n *\n * @name ALPHA_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NO_PREMULTIPLIED_ALPHA - Source is not premultiplied, leave it like that.\n * Option for compressed and data textures that are created from typed arrays.\n * @property {number} PREMULTIPLY_ON_UPLOAD - Source is not premultiplied, premultiply on upload.\n * Default option, used for all loaded images.\n * @property {number} PREMULTIPLIED_ALPHA - Source is already premultiplied\n * Example: spine atlases with `_pma` suffix.\n * @property {number} NPM - Alias for NO_PREMULTIPLIED_ALPHA.\n * @property {number} UNPACK - Default option, alias for PREMULTIPLY_ON_UPLOAD.\n * @property {number} PMA - Alias for PREMULTIPLIED_ALPHA.\n */\nvar ALPHA_MODES;\n(function (ALPHA_MODES) {\n ALPHA_MODES[ALPHA_MODES[\"NPM\"] = 0] = \"NPM\";\n ALPHA_MODES[ALPHA_MODES[\"UNPACK\"] = 1] = \"UNPACK\";\n ALPHA_MODES[ALPHA_MODES[\"PMA\"] = 2] = \"PMA\";\n ALPHA_MODES[ALPHA_MODES[\"NO_PREMULTIPLIED_ALPHA\"] = 0] = \"NO_PREMULTIPLIED_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ON_UPLOAD\"] = 1] = \"PREMULTIPLY_ON_UPLOAD\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLY_ALPHA\"] = 2] = \"PREMULTIPLY_ALPHA\";\n ALPHA_MODES[ALPHA_MODES[\"PREMULTIPLIED_ALPHA\"] = 2] = \"PREMULTIPLIED_ALPHA\";\n})(ALPHA_MODES || (ALPHA_MODES = {}));\n/**\n * Configure whether filter textures are cleared after binding.\n *\n * Filter textures need not be cleared if the filter does not use pixel blending. {@link CLEAR_MODES.BLIT} will detect\n * this and skip clearing as an optimization.\n *\n * @name CLEAR_MODES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} BLEND - Do not clear the filter texture. The filter's output will blend on top of the output texture.\n * @property {number} CLEAR - Always clear the filter texture.\n * @property {number} BLIT - Clear only if {@link FilterSystem.forceClear} is set or if the filter uses pixel blending.\n * @property {number} NO - Alias for BLEND, same as `false` in earlier versions\n * @property {number} YES - Alias for CLEAR, same as `true` in earlier versions\n * @property {number} AUTO - Alias for BLIT\n */\nvar CLEAR_MODES;\n(function (CLEAR_MODES) {\n CLEAR_MODES[CLEAR_MODES[\"NO\"] = 0] = \"NO\";\n CLEAR_MODES[CLEAR_MODES[\"YES\"] = 1] = \"YES\";\n CLEAR_MODES[CLEAR_MODES[\"AUTO\"] = 2] = \"AUTO\";\n CLEAR_MODES[CLEAR_MODES[\"BLEND\"] = 0] = \"BLEND\";\n CLEAR_MODES[CLEAR_MODES[\"CLEAR\"] = 1] = \"CLEAR\";\n CLEAR_MODES[CLEAR_MODES[\"BLIT\"] = 2] = \"BLIT\";\n})(CLEAR_MODES || (CLEAR_MODES = {}));\n/**\n * The gc modes that are supported by pixi.\n *\n * The {@link PIXI.settings.GC_MODE} Garbage Collection mode for PixiJS textures is AUTO\n * If set to GC_MODE, the renderer will occasionally check textures usage. If they are not\n * used for a specified period of time they will be removed from the GPU. They will of course\n * be uploaded again when they are required. This is a silent behind the scenes process that\n * should ensure that the GPU does not get filled up.\n *\n * Handy for mobile devices!\n * This property only affects WebGL.\n *\n * @name GC_MODES\n * @enum {number}\n * @static\n * @memberof PIXI\n * @property {number} AUTO - Garbage collection will happen periodically automatically\n * @property {number} MANUAL - Garbage collection will need to be called manually\n */\nvar GC_MODES;\n(function (GC_MODES) {\n GC_MODES[GC_MODES[\"AUTO\"] = 0] = \"AUTO\";\n GC_MODES[GC_MODES[\"MANUAL\"] = 1] = \"MANUAL\";\n})(GC_MODES || (GC_MODES = {}));\n/**\n * Constants that specify float precision in shaders.\n *\n * @name PRECISION\n * @memberof PIXI\n * @constant\n * @static\n * @enum {string}\n * @property {string} LOW='lowp'\n * @property {string} MEDIUM='mediump'\n * @property {string} HIGH='highp'\n */\nvar PRECISION;\n(function (PRECISION) {\n PRECISION[\"LOW\"] = \"lowp\";\n PRECISION[\"MEDIUM\"] = \"mediump\";\n PRECISION[\"HIGH\"] = \"highp\";\n})(PRECISION || (PRECISION = {}));\n/**\n * Constants for mask implementations.\n * We use `type` suffix because it leads to very different behaviours\n *\n * @name MASK_TYPES\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - Mask is ignored\n * @property {number} SCISSOR - Scissor mask, rectangle on screen, cheap\n * @property {number} STENCIL - Stencil mask, 1-bit, medium, works only if renderer supports stencil\n * @property {number} SPRITE - Mask that uses SpriteMaskFilter, uses temporary RenderTexture\n */\nvar MASK_TYPES;\n(function (MASK_TYPES) {\n MASK_TYPES[MASK_TYPES[\"NONE\"] = 0] = \"NONE\";\n MASK_TYPES[MASK_TYPES[\"SCISSOR\"] = 1] = \"SCISSOR\";\n MASK_TYPES[MASK_TYPES[\"STENCIL\"] = 2] = \"STENCIL\";\n MASK_TYPES[MASK_TYPES[\"SPRITE\"] = 3] = \"SPRITE\";\n})(MASK_TYPES || (MASK_TYPES = {}));\n/**\n * Constants for multi-sampling antialiasing.\n *\n * @see PIXI.Framebuffer#multisample\n *\n * @name MSAA_QUALITY\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} NONE - No multisampling for this renderTexture\n * @property {number} LOW - Try 2 samples\n * @property {number} MEDIUM - Try 4 samples\n * @property {number} HIGH - Try 8 samples\n */\nvar MSAA_QUALITY;\n(function (MSAA_QUALITY) {\n MSAA_QUALITY[MSAA_QUALITY[\"NONE\"] = 0] = \"NONE\";\n MSAA_QUALITY[MSAA_QUALITY[\"LOW\"] = 2] = \"LOW\";\n MSAA_QUALITY[MSAA_QUALITY[\"MEDIUM\"] = 4] = \"MEDIUM\";\n MSAA_QUALITY[MSAA_QUALITY[\"HIGH\"] = 8] = \"HIGH\";\n})(MSAA_QUALITY || (MSAA_QUALITY = {}));\n/**\n * Constants for various buffer types in Pixi\n *\n * @see PIXI.BUFFER_TYPE\n *\n * @name BUFFER_TYPE\n * @memberof PIXI\n * @static\n * @enum {number}\n * @property {number} ELEMENT_ARRAY_BUFFER - buffer type for using as an index buffer\n * @property {number} ARRAY_BUFFER - buffer type for using attribute data\n * @property {number} UNIFORM_BUFFER - the buffer type is for uniform buffer objects\n */\nvar BUFFER_TYPE;\n(function (BUFFER_TYPE) {\n BUFFER_TYPE[BUFFER_TYPE[\"ELEMENT_ARRAY_BUFFER\"] = 34963] = \"ELEMENT_ARRAY_BUFFER\";\n BUFFER_TYPE[BUFFER_TYPE[\"ARRAY_BUFFER\"] = 34962] = \"ARRAY_BUFFER\";\n // NOT YET SUPPORTED\n BUFFER_TYPE[BUFFER_TYPE[\"UNIFORM_BUFFER\"] = 35345] = \"UNIFORM_BUFFER\";\n})(BUFFER_TYPE || (BUFFER_TYPE = {}));\n\nvar _tempMatrix = new Matrix();\nDisplayObject.prototype._cacheAsBitmap = false;\nDisplayObject.prototype._cacheData = null;\nDisplayObject.prototype._cacheAsBitmapResolution = null;\nDisplayObject.prototype._cacheAsBitmapMultisample = MSAA_QUALITY.NONE;\n// figured there's no point adding ALL the extra variables to prototype.\n// this model can hold the information needed. This can also be generated on demand as\n// most objects are not cached as bitmaps.\n/**\n * @class\n * @ignore\n * @private\n */\nvar CacheData = /** @class */ (function () {\n function CacheData() {\n this.textureCacheId = null;\n this.originalRender = null;\n this.originalRenderCanvas = null;\n this.originalCalculateBounds = null;\n this.originalGetLocalBounds = null;\n this.originalUpdateTransform = null;\n this.originalDestroy = null;\n this.originalMask = null;\n this.originalFilterArea = null;\n this.originalContainsPoint = null;\n this.sprite = null;\n }\n return CacheData;\n}());\nObject.defineProperties(DisplayObject.prototype, {\n /**\n * The resolution to use for cacheAsBitmap. By default this will use the renderer's resolution\n * but can be overriden for performance. Lower values will reduce memory usage at the expense\n * of render quality. A falsey value of `null` or `0` will default to the renderer's resolution.\n * If `cacheAsBitmap` is set to `true`, this will re-render with the new resolution.\n *\n * @member {number} cacheAsBitmapResolution\n * @memberof PIXI.DisplayObject#\n * @default null\n */\n cacheAsBitmapResolution: {\n get: function () {\n return this._cacheAsBitmapResolution;\n },\n set: function (resolution) {\n if (resolution === this._cacheAsBitmapResolution) {\n return;\n }\n this._cacheAsBitmapResolution = resolution;\n if (this.cacheAsBitmap) {\n // Toggle to re-render at the new resolution\n this.cacheAsBitmap = false;\n this.cacheAsBitmap = true;\n }\n },\n },\n /**\n * The number of samples to use for cacheAsBitmap. If set to `null`, the renderer's\n * sample count is used.\n * If `cacheAsBitmap` is set to `true`, this will re-render with the new number of samples.\n *\n * @member {number} cacheAsBitmapMultisample\n * @memberof PIXI.DisplayObject#\n * @default PIXI.MSAA_QUALITY.NONE\n */\n cacheAsBitmapMultisample: {\n get: function () {\n return this._cacheAsBitmapMultisample;\n },\n set: function (multisample) {\n if (multisample === this._cacheAsBitmapMultisample) {\n return;\n }\n this._cacheAsBitmapMultisample = multisample;\n if (this.cacheAsBitmap) {\n // Toggle to re-render with new multisample\n this.cacheAsBitmap = false;\n this.cacheAsBitmap = true;\n }\n },\n },\n /**\n * Set this to true if you want this display object to be cached as a bitmap.\n * This basically takes a snap shot of the display object as it is at that moment. It can\n * provide a performance benefit for complex static displayObjects.\n * To remove simply set this property to `false`\n *\n * IMPORTANT GOTCHA - Make sure that all your textures are preloaded BEFORE setting this property to true\n * as it will take a snapshot of what is currently there. If the textures have not loaded then they will not appear.\n *\n * @member {boolean}\n * @memberof PIXI.DisplayObject#\n */\n cacheAsBitmap: {\n get: function () {\n return this._cacheAsBitmap;\n },\n set: function (value) {\n if (this._cacheAsBitmap === value) {\n return;\n }\n this._cacheAsBitmap = value;\n var data;\n if (value) {\n if (!this._cacheData) {\n this._cacheData = new CacheData();\n }\n data = this._cacheData;\n data.originalRender = this.render;\n data.originalRenderCanvas = this.renderCanvas;\n data.originalUpdateTransform = this.updateTransform;\n data.originalCalculateBounds = this.calculateBounds;\n data.originalGetLocalBounds = this.getLocalBounds;\n data.originalDestroy = this.destroy;\n data.originalContainsPoint = this.containsPoint;\n data.originalMask = this._mask;\n data.originalFilterArea = this.filterArea;\n this.render = this._renderCached;\n this.renderCanvas = this._renderCachedCanvas;\n this.destroy = this._cacheAsBitmapDestroy;\n }\n else {\n data = this._cacheData;\n if (data.sprite) {\n this._destroyCachedDisplayObject();\n }\n this.render = data.originalRender;\n this.renderCanvas = data.originalRenderCanvas;\n this.calculateBounds = data.originalCalculateBounds;\n this.getLocalBounds = data.originalGetLocalBounds;\n this.destroy = data.originalDestroy;\n this.updateTransform = data.originalUpdateTransform;\n this.containsPoint = data.originalContainsPoint;\n this._mask = data.originalMask;\n this.filterArea = data.originalFilterArea;\n }\n },\n },\n});\n/**\n * Renders a cached version of the sprite with WebGL\n *\n * @private\n * @method _renderCached\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.Renderer} renderer - the WebGL renderer\n */\nDisplayObject.prototype._renderCached = function _renderCached(renderer) {\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\n return;\n }\n this._initCachedDisplayObject(renderer);\n this._cacheData.sprite.transform._worldID = this.transform._worldID;\n this._cacheData.sprite.worldAlpha = this.worldAlpha;\n this._cacheData.sprite._render(renderer);\n};\n/**\n * Prepares the WebGL renderer to cache the sprite\n *\n * @private\n * @method _initCachedDisplayObject\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.Renderer} renderer - the WebGL renderer\n */\nDisplayObject.prototype._initCachedDisplayObject = function _initCachedDisplayObject(renderer) {\n var _a;\n if (this._cacheData && this._cacheData.sprite) {\n return;\n }\n // make sure alpha is set to 1 otherwise it will get rendered as invisible!\n var cacheAlpha = this.alpha;\n this.alpha = 1;\n // first we flush anything left in the renderer (otherwise it would get rendered to the cached texture)\n renderer.batch.flush();\n // this.filters= [];\n // next we find the dimensions of the untransformed object\n // this function also calls updatetransform on all its children as part of the measuring.\n // This means we don't need to update the transform again in this function\n // TODO pass an object to clone too? saves having to create a new one each time!\n var bounds = this.getLocalBounds(null, true).clone();\n // add some padding!\n if (this.filters && this.filters.length) {\n var padding = this.filters[0].padding;\n bounds.pad(padding);\n }\n bounds.ceil(settings.RESOLUTION);\n // for now we cache the current renderTarget that the WebGL renderer is currently using.\n // this could be more elegant..\n var cachedRenderTexture = renderer.renderTexture.current;\n var cachedSourceFrame = renderer.renderTexture.sourceFrame.clone();\n var cachedDestinationFrame = renderer.renderTexture.destinationFrame.clone();\n var cachedProjectionTransform = renderer.projection.transform;\n // We also store the filter stack - I will definitely look to change how this works a little later down the line.\n // const stack = renderer.filterManager.filterStack;\n // this renderTexture will be used to store the cached DisplayObject\n var renderTexture = RenderTexture.create({\n width: bounds.width,\n height: bounds.height,\n resolution: this.cacheAsBitmapResolution || renderer.resolution,\n multisample: (_a = this.cacheAsBitmapMultisample) !== null && _a !== void 0 ? _a : renderer.multisample,\n });\n var textureCacheId = \"cacheAsBitmap_\" + uid();\n this._cacheData.textureCacheId = textureCacheId;\n BaseTexture.addToCache(renderTexture.baseTexture, textureCacheId);\n Texture.addToCache(renderTexture, textureCacheId);\n // need to set //\n var m = this.transform.localTransform.copyTo(_tempMatrix).invert().translate(-bounds.x, -bounds.y);\n // set all properties to there original so we can render to a texture\n this.render = this._cacheData.originalRender;\n renderer.render(this, { renderTexture: renderTexture, clear: true, transform: m, skipUpdateTransform: false });\n renderer.framebuffer.blit();\n // now restore the state be setting the new properties\n renderer.projection.transform = cachedProjectionTransform;\n renderer.renderTexture.bind(cachedRenderTexture, cachedSourceFrame, cachedDestinationFrame);\n // renderer.filterManager.filterStack = stack;\n this.render = this._renderCached;\n // the rest is the same as for Canvas\n this.updateTransform = this.displayObjectUpdateTransform;\n this.calculateBounds = this._calculateCachedBounds;\n this.getLocalBounds = this._getCachedLocalBounds;\n this._mask = null;\n this.filterArea = null;\n this.alpha = cacheAlpha;\n // create our cached sprite\n var cachedSprite = new Sprite(renderTexture);\n cachedSprite.transform.worldTransform = this.transform.worldTransform;\n cachedSprite.anchor.x = -(bounds.x / bounds.width);\n cachedSprite.anchor.y = -(bounds.y / bounds.height);\n cachedSprite.alpha = cacheAlpha;\n cachedSprite._bounds = this._bounds;\n this._cacheData.sprite = cachedSprite;\n this.transform._parentID = -1;\n // restore the transform of the cached sprite to avoid the nasty flicker..\n if (!this.parent) {\n this.enableTempParent();\n this.updateTransform();\n this.disableTempParent(null);\n }\n else {\n this.updateTransform();\n }\n // map the hit test..\n this.containsPoint = cachedSprite.containsPoint.bind(cachedSprite);\n};\n/**\n * Renders a cached version of the sprite with canvas\n *\n * @private\n * @method _renderCachedCanvas\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.CanvasRenderer} renderer - The canvas renderer\n */\nDisplayObject.prototype._renderCachedCanvas = function _renderCachedCanvas(renderer) {\n if (!this.visible || this.worldAlpha <= 0 || !this.renderable) {\n return;\n }\n this._initCachedDisplayObjectCanvas(renderer);\n this._cacheData.sprite.worldAlpha = this.worldAlpha;\n this._cacheData.sprite._renderCanvas(renderer);\n};\n// TODO this can be the same as the WebGL version.. will need to do a little tweaking first though..\n/**\n * Prepares the Canvas renderer to cache the sprite\n *\n * @private\n * @method _initCachedDisplayObjectCanvas\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.CanvasRenderer} renderer - The canvas renderer\n */\nDisplayObject.prototype._initCachedDisplayObjectCanvas = function _initCachedDisplayObjectCanvas(renderer) {\n if (this._cacheData && this._cacheData.sprite) {\n return;\n }\n // get bounds actually transforms the object for us already!\n var bounds = this.getLocalBounds(null, true);\n var cacheAlpha = this.alpha;\n this.alpha = 1;\n var cachedRenderTarget = renderer.context;\n var cachedProjectionTransform = renderer._projTransform;\n bounds.ceil(settings.RESOLUTION);\n var renderTexture = RenderTexture.create({ width: bounds.width, height: bounds.height });\n var textureCacheId = \"cacheAsBitmap_\" + uid();\n this._cacheData.textureCacheId = textureCacheId;\n BaseTexture.addToCache(renderTexture.baseTexture, textureCacheId);\n Texture.addToCache(renderTexture, textureCacheId);\n // need to set //\n var m = _tempMatrix;\n this.transform.localTransform.copyTo(m);\n m.invert();\n m.tx -= bounds.x;\n m.ty -= bounds.y;\n // m.append(this.transform.worldTransform.)\n // set all properties to there original so we can render to a texture\n this.renderCanvas = this._cacheData.originalRenderCanvas;\n renderer.render(this, { renderTexture: renderTexture, clear: true, transform: m, skipUpdateTransform: false });\n // now restore the state be setting the new properties\n renderer.context = cachedRenderTarget;\n renderer._projTransform = cachedProjectionTransform;\n this.renderCanvas = this._renderCachedCanvas;\n // the rest is the same as for WebGL\n this.updateTransform = this.displayObjectUpdateTransform;\n this.calculateBounds = this._calculateCachedBounds;\n this.getLocalBounds = this._getCachedLocalBounds;\n this._mask = null;\n this.filterArea = null;\n this.alpha = cacheAlpha;\n // create our cached sprite\n var cachedSprite = new Sprite(renderTexture);\n cachedSprite.transform.worldTransform = this.transform.worldTransform;\n cachedSprite.anchor.x = -(bounds.x / bounds.width);\n cachedSprite.anchor.y = -(bounds.y / bounds.height);\n cachedSprite.alpha = cacheAlpha;\n cachedSprite._bounds = this._bounds;\n this._cacheData.sprite = cachedSprite;\n this.transform._parentID = -1;\n // restore the transform of the cached sprite to avoid the nasty flicker..\n if (!this.parent) {\n this.parent = renderer._tempDisplayObjectParent;\n this.updateTransform();\n this.parent = null;\n }\n else {\n this.updateTransform();\n }\n // map the hit test..\n this.containsPoint = cachedSprite.containsPoint.bind(cachedSprite);\n};\n/**\n * Calculates the bounds of the cached sprite\n *\n * @private\n * @method\n */\nDisplayObject.prototype._calculateCachedBounds = function _calculateCachedBounds() {\n this._bounds.clear();\n this._cacheData.sprite.transform._worldID = this.transform._worldID;\n this._cacheData.sprite._calculateBounds();\n this._bounds.updateID = this._boundsID;\n};\n/**\n * Gets the bounds of the cached sprite.\n *\n * @private\n * @method\n * @return {Rectangle} The local bounds.\n */\nDisplayObject.prototype._getCachedLocalBounds = function _getCachedLocalBounds() {\n return this._cacheData.sprite.getLocalBounds(null);\n};\n/**\n * Destroys the cached sprite.\n *\n * @private\n * @method\n */\nDisplayObject.prototype._destroyCachedDisplayObject = function _destroyCachedDisplayObject() {\n this._cacheData.sprite._texture.destroy(true);\n this._cacheData.sprite = null;\n BaseTexture.removeFromCache(this._cacheData.textureCacheId);\n Texture.removeFromCache(this._cacheData.textureCacheId);\n this._cacheData.textureCacheId = null;\n};\n/**\n * Destroys the cached object.\n *\n * @private\n * @method\n * @param {object|boolean} [options] - Options parameter. A boolean will act as if all options\n * have been set to that value.\n * Used when destroying containers, see the Container.destroy method.\n */\nDisplayObject.prototype._cacheAsBitmapDestroy = function _cacheAsBitmapDestroy(options) {\n this.cacheAsBitmap = false;\n this.destroy(options);\n};\n\nexport { CacheData };\n//# sourceMappingURL=mixin-cache-as-bitmap.js.map\n","/*!\n * @pixi/mixin-get-child-by-name - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mixin-get-child-by-name is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { DisplayObject, Container } from '@pixi/display';\n\n/**\n * The instance name of the object.\n *\n * @memberof PIXI.DisplayObject#\n * @member {string} name\n */\nDisplayObject.prototype.name = null;\n/**\n * Returns the display object in the container.\n *\n * Recursive searches are done in a preorder traversal.\n *\n * @method getChildByName\n * @memberof PIXI.Container#\n * @param {string} name - Instance name.\n * @param {boolean}[deep=false] - Whether to search recursively\n * @return {PIXI.DisplayObject} The child with the specified name.\n */\nContainer.prototype.getChildByName = function getChildByName(name, deep) {\n for (var i = 0, j = this.children.length; i < j; i++) {\n if (this.children[i].name === name) {\n return this.children[i];\n }\n }\n if (deep) {\n for (var i = 0, j = this.children.length; i < j; i++) {\n var child = this.children[i];\n if (!child.getChildByName) {\n continue;\n }\n var target = this.children[i].getChildByName(name, true);\n if (target) {\n return target;\n }\n }\n }\n return null;\n};\n//# sourceMappingURL=mixin-get-child-by-name.js.map\n","/*!\n * @pixi/mixin-get-global-position - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mixin-get-global-position is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { DisplayObject } from '@pixi/display';\nimport { Point } from '@pixi/math';\n\n/**\n * Returns the global position of the displayObject. Does not depend on object scale, rotation and pivot.\n *\n * @method getGlobalPosition\n * @memberof PIXI.DisplayObject#\n * @param {PIXI.Point} [point=new PIXI.Point()] - The point to write the global value to.\n * @param {boolean} [skipUpdate=false] - Setting to true will stop the transforms of the scene graph from\n * being updated. This means the calculation returned MAY be out of date BUT will give you a\n * nice performance boost.\n * @return {PIXI.Point} The updated point.\n */\nDisplayObject.prototype.getGlobalPosition = function getGlobalPosition(point, skipUpdate) {\n if (point === void 0) { point = new Point(); }\n if (skipUpdate === void 0) { skipUpdate = false; }\n if (this.parent) {\n this.parent.toGlobal(this.position, point, skipUpdate);\n }\n else {\n point.x = this.position.x;\n point.y = this.position.y;\n }\n return point;\n};\n//# sourceMappingURL=mixin-get-global-position.js.map\n","/*!\n * @pixi/mesh-extras - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/mesh-extras is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { MeshGeometry, Mesh, MeshMaterial } from '@pixi/mesh';\nimport { WRAP_MODES } from '@pixi/constants';\nimport { Texture } from '@pixi/core';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * @memberof PIXI\n */\nvar PlaneGeometry = /** @class */ (function (_super) {\n __extends(PlaneGeometry, _super);\n /**\n * @param width - The width of the plane.\n * @param height - The height of the plane.\n * @param segWidth - Number of horizontal segments.\n * @param segHeight - Number of vertical segments.\n */\n function PlaneGeometry(width, height, segWidth, segHeight) {\n if (width === void 0) { width = 100; }\n if (height === void 0) { height = 100; }\n if (segWidth === void 0) { segWidth = 10; }\n if (segHeight === void 0) { segHeight = 10; }\n var _this = _super.call(this) || this;\n _this.segWidth = segWidth;\n _this.segHeight = segHeight;\n _this.width = width;\n _this.height = height;\n _this.build();\n return _this;\n }\n /**\n * Refreshes plane coordinates\n * @private\n */\n PlaneGeometry.prototype.build = function () {\n var total = this.segWidth * this.segHeight;\n var verts = [];\n var uvs = [];\n var indices = [];\n var segmentsX = this.segWidth - 1;\n var segmentsY = this.segHeight - 1;\n var sizeX = (this.width) / segmentsX;\n var sizeY = (this.height) / segmentsY;\n for (var i = 0; i < total; i++) {\n var x = (i % this.segWidth);\n var y = ((i / this.segWidth) | 0);\n verts.push(x * sizeX, y * sizeY);\n uvs.push(x / segmentsX, y / segmentsY);\n }\n var totalSub = segmentsX * segmentsY;\n for (var i = 0; i < totalSub; i++) {\n var xpos = i % segmentsX;\n var ypos = (i / segmentsX) | 0;\n var value = (ypos * this.segWidth) + xpos;\n var value2 = (ypos * this.segWidth) + xpos + 1;\n var value3 = ((ypos + 1) * this.segWidth) + xpos;\n var value4 = ((ypos + 1) * this.segWidth) + xpos + 1;\n indices.push(value, value2, value3, value2, value4, value3);\n }\n this.buffers[0].data = new Float32Array(verts);\n this.buffers[1].data = new Float32Array(uvs);\n this.indexBuffer.data = new Uint16Array(indices);\n // ensure that the changes are uploaded\n this.buffers[0].update();\n this.buffers[1].update();\n this.indexBuffer.update();\n };\n return PlaneGeometry;\n}(MeshGeometry));\n\n/**\n * RopeGeometry allows you to draw a geometry across several points and then manipulate these points.\n *\n * ```js\n * for (let i = 0; i < 20; i++) {\n * points.push(new PIXI.Point(i * 50, 0));\n * };\n * const rope = new PIXI.RopeGeometry(100, points);\n * ```\n *\n * @memberof PIXI\n */\nvar RopeGeometry = /** @class */ (function (_super) {\n __extends(RopeGeometry, _super);\n /**\n * @param width - The width (i.e., thickness) of the rope.\n * @param points - An array of {@link PIXI.Point} objects to construct this rope.\n * @param textureScale - By default the rope texture will be stretched to match\n * rope length. If textureScale is positive this value will be treated as a scaling\n * factor and the texture will preserve its aspect ratio instead. To create a tiling rope\n * set baseTexture.wrapMode to {@link PIXI.WRAP_MODES.REPEAT} and use a power of two texture,\n * then set textureScale=1 to keep the original texture pixel size.\n * In order to reduce alpha channel artifacts provide a larger texture and downsample -\n * i.e. set textureScale=0.5 to scale it down twice.\n */\n function RopeGeometry(width, points, textureScale) {\n if (width === void 0) { width = 200; }\n if (textureScale === void 0) { textureScale = 0; }\n var _this = _super.call(this, new Float32Array(points.length * 4), new Float32Array(points.length * 4), new Uint16Array((points.length - 1) * 6)) || this;\n _this.points = points;\n _this._width = width;\n _this.textureScale = textureScale;\n _this.build();\n return _this;\n }\n Object.defineProperty(RopeGeometry.prototype, \"width\", {\n /**\n * The width (i.e., thickness) of the rope.\n *\n * @readOnly\n */\n get: function () {\n return this._width;\n },\n enumerable: false,\n configurable: true\n });\n /** Refreshes Rope indices and uvs */\n RopeGeometry.prototype.build = function () {\n var points = this.points;\n if (!points)\n { return; }\n var vertexBuffer = this.getBuffer('aVertexPosition');\n var uvBuffer = this.getBuffer('aTextureCoord');\n var indexBuffer = this.getIndex();\n // if too little points, or texture hasn't got UVs set yet just move on.\n if (points.length < 1) {\n return;\n }\n // if the number of points has changed we will need to recreate the arraybuffers\n if (vertexBuffer.data.length / 4 !== points.length) {\n vertexBuffer.data = new Float32Array(points.length * 4);\n uvBuffer.data = new Float32Array(points.length * 4);\n indexBuffer.data = new Uint16Array((points.length - 1) * 6);\n }\n var uvs = uvBuffer.data;\n var indices = indexBuffer.data;\n uvs[0] = 0;\n uvs[1] = 0;\n uvs[2] = 0;\n uvs[3] = 1;\n var amount = 0;\n var prev = points[0];\n var textureWidth = this._width * this.textureScale;\n var total = points.length; // - 1;\n for (var i = 0; i < total; i++) {\n // time to do some smart drawing!\n var index = i * 4;\n if (this.textureScale > 0) {\n // calculate pixel distance from previous point\n var dx = prev.x - points[i].x;\n var dy = prev.y - points[i].y;\n var distance = Math.sqrt((dx * dx) + (dy * dy));\n prev = points[i];\n amount += distance / textureWidth;\n }\n else {\n // stretch texture\n amount = i / (total - 1);\n }\n uvs[index] = amount;\n uvs[index + 1] = 0;\n uvs[index + 2] = amount;\n uvs[index + 3] = 1;\n }\n var indexCount = 0;\n for (var i = 0; i < total - 1; i++) {\n var index = i * 2;\n indices[indexCount++] = index;\n indices[indexCount++] = index + 1;\n indices[indexCount++] = index + 2;\n indices[indexCount++] = index + 2;\n indices[indexCount++] = index + 1;\n indices[indexCount++] = index + 3;\n }\n // ensure that the changes are uploaded\n uvBuffer.update();\n indexBuffer.update();\n this.updateVertices();\n };\n /**\n * refreshes vertices of Rope mesh\n */\n RopeGeometry.prototype.updateVertices = function () {\n var points = this.points;\n if (points.length < 1) {\n return;\n }\n var lastPoint = points[0];\n var nextPoint;\n var perpX = 0;\n var perpY = 0;\n var vertices = this.buffers[0].data;\n var total = points.length;\n for (var i = 0; i < total; i++) {\n var point = points[i];\n var index = i * 4;\n if (i < points.length - 1) {\n nextPoint = points[i + 1];\n }\n else {\n nextPoint = point;\n }\n perpY = -(nextPoint.x - lastPoint.x);\n perpX = nextPoint.y - lastPoint.y;\n var perpLength = Math.sqrt((perpX * perpX) + (perpY * perpY));\n var num = this.textureScale > 0 ? this.textureScale * this._width / 2 : this._width / 2;\n perpX /= perpLength;\n perpY /= perpLength;\n perpX *= num;\n perpY *= num;\n vertices[index] = point.x + perpX;\n vertices[index + 1] = point.y + perpY;\n vertices[index + 2] = point.x - perpX;\n vertices[index + 3] = point.y - perpY;\n lastPoint = point;\n }\n this.buffers[0].update();\n };\n RopeGeometry.prototype.update = function () {\n if (this.textureScale > 0) {\n this.build(); // we need to update UVs\n }\n else {\n this.updateVertices();\n }\n };\n return RopeGeometry;\n}(MeshGeometry));\n\n/**\n * The rope allows you to draw a texture across several points and then manipulate these points\n *\n *```js\n * for (let i = 0; i < 20; i++) {\n * points.push(new PIXI.Point(i * 50, 0));\n * };\n * let rope = new PIXI.SimpleRope(PIXI.Texture.from(\"snake.png\"), points);\n * ```\n *\n * @memberof PIXI\n */\nvar SimpleRope = /** @class */ (function (_super) {\n __extends(SimpleRope, _super);\n /**\n * @param texture - The texture to use on the rope.\n * @param points - An array of {@link PIXI.Point} objects to construct this rope.\n * @param {number} textureScale - Optional. Positive values scale rope texture\n * keeping its aspect ratio. You can reduce alpha channel artifacts by providing a larger texture\n * and downsampling here. If set to zero, texture will be stretched instead.\n */\n function SimpleRope(texture, points, textureScale) {\n if (textureScale === void 0) { textureScale = 0; }\n var _this = this;\n var ropeGeometry = new RopeGeometry(texture.height, points, textureScale);\n var meshMaterial = new MeshMaterial(texture);\n if (textureScale > 0) {\n // attempt to set UV wrapping, will fail on non-power of two textures\n texture.baseTexture.wrapMode = WRAP_MODES.REPEAT;\n }\n _this = _super.call(this, ropeGeometry, meshMaterial) || this;\n /**\n * re-calculate vertices by rope points each frame\n *\n * @member {boolean}\n */\n _this.autoUpdate = true;\n return _this;\n }\n SimpleRope.prototype._render = function (renderer) {\n var geometry = this.geometry;\n if (this.autoUpdate || geometry._width !== this.shader.texture.height) {\n geometry._width = this.shader.texture.height;\n geometry.update();\n }\n _super.prototype._render.call(this, renderer);\n };\n return SimpleRope;\n}(Mesh));\n\n/**\n * The SimplePlane allows you to draw a texture across several points and then manipulate these points\n *\n *```js\n * for (let i = 0; i < 20; i++) {\n * points.push(new PIXI.Point(i * 50, 0));\n * };\n * let SimplePlane = new PIXI.SimplePlane(PIXI.Texture.from(\"snake.png\"), points);\n * ```\n *\n * @memberof PIXI\n */\nvar SimplePlane = /** @class */ (function (_super) {\n __extends(SimplePlane, _super);\n /**\n * @param texture - The texture to use on the SimplePlane.\n * @param verticesX - The number of vertices in the x-axis\n * @param verticesY - The number of vertices in the y-axis\n */\n function SimplePlane(texture, verticesX, verticesY) {\n var _this = this;\n var planeGeometry = new PlaneGeometry(texture.width, texture.height, verticesX, verticesY);\n var meshMaterial = new MeshMaterial(Texture.WHITE);\n _this = _super.call(this, planeGeometry, meshMaterial) || this;\n // lets call the setter to ensure all necessary updates are performed\n _this.texture = texture;\n _this.autoResize = true;\n return _this;\n }\n /**\n * Method used for overrides, to do something in case texture frame was changed.\n * Meshes based on plane can override it and change more details based on texture.\n */\n SimplePlane.prototype.textureUpdated = function () {\n this._textureID = this.shader.texture._updateID;\n var geometry = this.geometry;\n var _a = this.shader.texture, width = _a.width, height = _a.height;\n if (this.autoResize && (geometry.width !== width || geometry.height !== height)) {\n geometry.width = this.shader.texture.width;\n geometry.height = this.shader.texture.height;\n geometry.build();\n }\n };\n Object.defineProperty(SimplePlane.prototype, \"texture\", {\n get: function () {\n return this.shader.texture;\n },\n set: function (value) {\n // Track texture same way sprite does.\n // For generated meshes like NineSlicePlane it can change the geometry.\n // Unfortunately, this method might not work if you directly change texture in material.\n if (this.shader.texture === value) {\n return;\n }\n this.shader.texture = value;\n this._textureID = -1;\n if (value.baseTexture.valid) {\n this.textureUpdated();\n }\n else {\n value.once('update', this.textureUpdated, this);\n }\n },\n enumerable: false,\n configurable: true\n });\n SimplePlane.prototype._render = function (renderer) {\n if (this._textureID !== this.shader.texture._updateID) {\n this.textureUpdated();\n }\n _super.prototype._render.call(this, renderer);\n };\n SimplePlane.prototype.destroy = function (options) {\n this.shader.texture.off('update', this.textureUpdated, this);\n _super.prototype.destroy.call(this, options);\n };\n return SimplePlane;\n}(Mesh));\n\n/**\n * The Simple Mesh class mimics Mesh in PixiJS v4, providing easy-to-use constructor arguments.\n * For more robust customization, use {@link PIXI.Mesh}.\n *\n * @memberof PIXI\n */\nvar SimpleMesh = /** @class */ (function (_super) {\n __extends(SimpleMesh, _super);\n /**\n * @param texture - The texture to use\n * @param {Float32Array} [vertices] - if you want to specify the vertices\n * @param {Float32Array} [uvs] - if you want to specify the uvs\n * @param {Uint16Array} [indices] - if you want to specify the indices\n * @param drawMode - the drawMode, can be any of the Mesh.DRAW_MODES consts\n */\n function SimpleMesh(texture, vertices, uvs, indices, drawMode) {\n if (texture === void 0) { texture = Texture.EMPTY; }\n var _this = this;\n var geometry = new MeshGeometry(vertices, uvs, indices);\n geometry.getBuffer('aVertexPosition').static = false;\n var meshMaterial = new MeshMaterial(texture);\n _this = _super.call(this, geometry, meshMaterial, null, drawMode) || this;\n _this.autoUpdate = true;\n return _this;\n }\n Object.defineProperty(SimpleMesh.prototype, \"vertices\", {\n /**\n * Collection of vertices data.\n * @type {Float32Array}\n */\n get: function () {\n return this.geometry.getBuffer('aVertexPosition').data;\n },\n set: function (value) {\n this.geometry.getBuffer('aVertexPosition').data = value;\n },\n enumerable: false,\n configurable: true\n });\n SimpleMesh.prototype._render = function (renderer) {\n if (this.autoUpdate) {\n this.geometry.getBuffer('aVertexPosition').update();\n }\n _super.prototype._render.call(this, renderer);\n };\n return SimpleMesh;\n}(Mesh));\n\nvar DEFAULT_BORDER_SIZE = 10;\n/**\n * The NineSlicePlane allows you to stretch a texture using 9-slice scaling. The corners will remain unscaled (useful\n * for buttons with rounded corners for example) and the other areas will be scaled horizontally and or vertically\n *\n *```js\n * let Plane9 = new PIXI.NineSlicePlane(PIXI.Texture.from('BoxWithRoundedCorners.png'), 15, 15, 15, 15);\n * ```\n * <pre>\n * A B\n * +---+----------------------+---+\n * C | 1 | 2 | 3 |\n * +---+----------------------+---+\n * | | | |\n * | 4 | 5 | 6 |\n * | | | |\n * +---+----------------------+---+\n * D | 7 | 8 | 9 |\n * +---+----------------------+---+\n\n * When changing this objects width and/or height:\n * areas 1 3 7 and 9 will remain unscaled.\n * areas 2 and 8 will be stretched horizontally\n * areas 4 and 6 will be stretched vertically\n * area 5 will be stretched both horizontally and vertically\n * </pre>\n *\n * @memberof PIXI\n */\nvar NineSlicePlane = /** @class */ (function (_super) {\n __extends(NineSlicePlane, _super);\n /**\n * @param texture - The texture to use on the NineSlicePlane.\n * @param {number} [leftWidth=10] - size of the left vertical bar (A)\n * @param {number} [topHeight=10] - size of the top horizontal bar (C)\n * @param {number} [rightWidth=10] - size of the right vertical bar (B)\n * @param {number} [bottomHeight=10] - size of the bottom horizontal bar (D)\n */\n function NineSlicePlane(texture, leftWidth, topHeight, rightWidth, bottomHeight) {\n if (leftWidth === void 0) { leftWidth = DEFAULT_BORDER_SIZE; }\n if (topHeight === void 0) { topHeight = DEFAULT_BORDER_SIZE; }\n if (rightWidth === void 0) { rightWidth = DEFAULT_BORDER_SIZE; }\n if (bottomHeight === void 0) { bottomHeight = DEFAULT_BORDER_SIZE; }\n var _this = _super.call(this, Texture.WHITE, 4, 4) || this;\n _this._origWidth = texture.orig.width;\n _this._origHeight = texture.orig.height;\n /** The width of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n _this._width = _this._origWidth;\n /** The height of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n _this._height = _this._origHeight;\n _this._leftWidth = leftWidth;\n _this._rightWidth = rightWidth;\n _this._topHeight = topHeight;\n _this._bottomHeight = bottomHeight;\n // lets call the setter to ensure all necessary updates are performed\n _this.texture = texture;\n return _this;\n }\n NineSlicePlane.prototype.textureUpdated = function () {\n this._textureID = this.shader.texture._updateID;\n this._refresh();\n };\n Object.defineProperty(NineSlicePlane.prototype, \"vertices\", {\n get: function () {\n return this.geometry.getBuffer('aVertexPosition').data;\n },\n set: function (value) {\n this.geometry.getBuffer('aVertexPosition').data = value;\n },\n enumerable: false,\n configurable: true\n });\n /** Updates the horizontal vertices. */\n NineSlicePlane.prototype.updateHorizontalVertices = function () {\n var vertices = this.vertices;\n var scale = this._getMinScale();\n vertices[9] = vertices[11] = vertices[13] = vertices[15] = this._topHeight * scale;\n vertices[17] = vertices[19] = vertices[21] = vertices[23] = this._height - (this._bottomHeight * scale);\n vertices[25] = vertices[27] = vertices[29] = vertices[31] = this._height;\n };\n /** Updates the vertical vertices. */\n NineSlicePlane.prototype.updateVerticalVertices = function () {\n var vertices = this.vertices;\n var scale = this._getMinScale();\n vertices[2] = vertices[10] = vertices[18] = vertices[26] = this._leftWidth * scale;\n vertices[4] = vertices[12] = vertices[20] = vertices[28] = this._width - (this._rightWidth * scale);\n vertices[6] = vertices[14] = vertices[22] = vertices[30] = this._width;\n };\n /**\n * Returns the smaller of a set of vertical and horizontal scale of nine slice corners.\n *\n * @return Smaller number of vertical and horizontal scale.\n */\n NineSlicePlane.prototype._getMinScale = function () {\n var w = this._leftWidth + this._rightWidth;\n var scaleW = this._width > w ? 1.0 : this._width / w;\n var h = this._topHeight + this._bottomHeight;\n var scaleH = this._height > h ? 1.0 : this._height / h;\n var scale = Math.min(scaleW, scaleH);\n return scale;\n };\n Object.defineProperty(NineSlicePlane.prototype, \"width\", {\n /** The width of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n get: function () {\n return this._width;\n },\n set: function (value) {\n this._width = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"height\", {\n /** The height of the NineSlicePlane, setting this will actually modify the vertices and UV's of this plane. */\n get: function () {\n return this._height;\n },\n set: function (value) {\n this._height = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"leftWidth\", {\n /** The width of the left column. */\n get: function () {\n return this._leftWidth;\n },\n set: function (value) {\n this._leftWidth = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"rightWidth\", {\n /** The width of the right column. */\n get: function () {\n return this._rightWidth;\n },\n set: function (value) {\n this._rightWidth = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"topHeight\", {\n /** The height of the top row. */\n get: function () {\n return this._topHeight;\n },\n set: function (value) {\n this._topHeight = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(NineSlicePlane.prototype, \"bottomHeight\", {\n /** The height of the bottom row. */\n get: function () {\n return this._bottomHeight;\n },\n set: function (value) {\n this._bottomHeight = value;\n this._refresh();\n },\n enumerable: false,\n configurable: true\n });\n /** Refreshes NineSlicePlane coords. All of them. */\n NineSlicePlane.prototype._refresh = function () {\n var texture = this.texture;\n var uvs = this.geometry.buffers[1].data;\n this._origWidth = texture.orig.width;\n this._origHeight = texture.orig.height;\n var _uvw = 1.0 / this._origWidth;\n var _uvh = 1.0 / this._origHeight;\n uvs[0] = uvs[8] = uvs[16] = uvs[24] = 0;\n uvs[1] = uvs[3] = uvs[5] = uvs[7] = 0;\n uvs[6] = uvs[14] = uvs[22] = uvs[30] = 1;\n uvs[25] = uvs[27] = uvs[29] = uvs[31] = 1;\n uvs[2] = uvs[10] = uvs[18] = uvs[26] = _uvw * this._leftWidth;\n uvs[4] = uvs[12] = uvs[20] = uvs[28] = 1 - (_uvw * this._rightWidth);\n uvs[9] = uvs[11] = uvs[13] = uvs[15] = _uvh * this._topHeight;\n uvs[17] = uvs[19] = uvs[21] = uvs[23] = 1 - (_uvh * this._bottomHeight);\n this.updateHorizontalVertices();\n this.updateVerticalVertices();\n this.geometry.buffers[0].update();\n this.geometry.buffers[1].update();\n };\n return NineSlicePlane;\n}(SimplePlane));\n\nexport { NineSlicePlane, PlaneGeometry, RopeGeometry, SimpleMesh, SimplePlane, SimpleRope };\n//# sourceMappingURL=mesh-extras.js.map\n","/*!\n * @pixi/sprite-animated - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * @pixi/sprite-animated is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport { Texture } from '@pixi/core';\nimport { Sprite } from '@pixi/sprite';\nimport { Ticker, UPDATE_PRIORITY } from '@pixi/ticker';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) { if (b.hasOwnProperty(p)) { d[p] = b[p]; } } };\r\n return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * An AnimatedSprite is a simple way to display an animation depicted by a list of textures.\n *\n * ```js\n * let alienImages = [\"image_sequence_01.png\",\"image_sequence_02.png\",\"image_sequence_03.png\",\"image_sequence_04.png\"];\n * let textureArray = [];\n *\n * for (let i=0; i < 4; i++)\n * {\n * let texture = PIXI.Texture.from(alienImages[i]);\n * textureArray.push(texture);\n * };\n *\n * let animatedSprite = new PIXI.AnimatedSprite(textureArray);\n * ```\n *\n * The more efficient and simpler way to create an animated sprite is using a {@link PIXI.Spritesheet}\n * containing the animation definitions:\n *\n * ```js\n * PIXI.Loader.shared.add(\"assets/spritesheet.json\").load(setup);\n *\n * function setup() {\n * let sheet = PIXI.Loader.shared.resources[\"assets/spritesheet.json\"].spritesheet;\n * animatedSprite = new PIXI.AnimatedSprite(sheet.animations[\"image_sequence\"]);\n * ...\n * }\n * ```\n *\n * @memberof PIXI\n */\nvar AnimatedSprite = /** @class */ (function (_super) {\n __extends(AnimatedSprite, _super);\n /**\n * @param textures - An array of {@link PIXI.Texture} or frame\n * objects that make up the animation.\n * @param {boolean} [autoUpdate=true] - Whether to use PIXI.Ticker.shared to auto update animation time.\n */\n function AnimatedSprite(textures, autoUpdate) {\n if (autoUpdate === void 0) { autoUpdate = true; }\n var _this = _super.call(this, textures[0] instanceof Texture ? textures[0] : textures[0].texture) || this;\n _this._textures = null;\n _this._durations = null;\n _this._autoUpdate = autoUpdate;\n _this._isConnectedToTicker = false;\n _this.animationSpeed = 1;\n _this.loop = true;\n _this.updateAnchor = false;\n _this.onComplete = null;\n _this.onFrameChange = null;\n _this.onLoop = null;\n _this._currentTime = 0;\n _this._playing = false;\n _this._previousFrame = null;\n _this.textures = textures;\n return _this;\n }\n /** Stops the AnimatedSprite. */\n AnimatedSprite.prototype.stop = function () {\n if (!this._playing) {\n return;\n }\n this._playing = false;\n if (this._autoUpdate && this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n };\n /** Plays the AnimatedSprite. */\n AnimatedSprite.prototype.play = function () {\n if (this._playing) {\n return;\n }\n this._playing = true;\n if (this._autoUpdate && !this._isConnectedToTicker) {\n Ticker.shared.add(this.update, this, UPDATE_PRIORITY.HIGH);\n this._isConnectedToTicker = true;\n }\n };\n /**\n * Stops the AnimatedSprite and goes to a specific frame.\n *\n * @param frameNumber - Frame index to stop at.\n */\n AnimatedSprite.prototype.gotoAndStop = function (frameNumber) {\n this.stop();\n var previousFrame = this.currentFrame;\n this._currentTime = frameNumber;\n if (previousFrame !== this.currentFrame) {\n this.updateTexture();\n }\n };\n /**\n * Goes to a specific frame and begins playing the AnimatedSprite.\n *\n * @param frameNumber - Frame index to start at.\n */\n AnimatedSprite.prototype.gotoAndPlay = function (frameNumber) {\n var previousFrame = this.currentFrame;\n this._currentTime = frameNumber;\n if (previousFrame !== this.currentFrame) {\n this.updateTexture();\n }\n this.play();\n };\n /**\n * Updates the object transform for rendering.\n *\n * @param deltaTime - Time since last tick.\n */\n AnimatedSprite.prototype.update = function (deltaTime) {\n if (!this._playing) {\n return;\n }\n var elapsed = this.animationSpeed * deltaTime;\n var previousFrame = this.currentFrame;\n if (this._durations !== null) {\n var lag = this._currentTime % 1 * this._durations[this.currentFrame];\n lag += elapsed / 60 * 1000;\n while (lag < 0) {\n this._currentTime--;\n lag += this._durations[this.currentFrame];\n }\n var sign = Math.sign(this.animationSpeed * deltaTime);\n this._currentTime = Math.floor(this._currentTime);\n while (lag >= this._durations[this.currentFrame]) {\n lag -= this._durations[this.currentFrame] * sign;\n this._currentTime += sign;\n }\n this._currentTime += lag / this._durations[this.currentFrame];\n }\n else {\n this._currentTime += elapsed;\n }\n if (this._currentTime < 0 && !this.loop) {\n this.gotoAndStop(0);\n if (this.onComplete) {\n this.onComplete();\n }\n }\n else if (this._currentTime >= this._textures.length && !this.loop) {\n this.gotoAndStop(this._textures.length - 1);\n if (this.onComplete) {\n this.onComplete();\n }\n }\n else if (previousFrame !== this.currentFrame) {\n if (this.loop && this.onLoop) {\n if (this.animationSpeed > 0 && this.currentFrame < previousFrame) {\n this.onLoop();\n }\n else if (this.animationSpeed < 0 && this.currentFrame > previousFrame) {\n this.onLoop();\n }\n }\n this.updateTexture();\n }\n };\n /** Updates the displayed texture to match the current frame index. */\n AnimatedSprite.prototype.updateTexture = function () {\n var currentFrame = this.currentFrame;\n if (this._previousFrame === currentFrame) {\n return;\n }\n this._previousFrame = currentFrame;\n this._texture = this._textures[currentFrame];\n this._textureID = -1;\n this._textureTrimmedID = -1;\n this._cachedTint = 0xFFFFFF;\n this.uvs = this._texture._uvs.uvsFloat32;\n if (this.updateAnchor) {\n this._anchor.copyFrom(this._texture.defaultAnchor);\n }\n if (this.onFrameChange) {\n this.onFrameChange(this.currentFrame);\n }\n };\n /**\n * Stops the AnimatedSprite and destroys it.\n *\n * @param {object|boolean} [options] - Options parameter. A boolean will act as if all options\n * have been set to that value.\n * @param {boolean} [options.children=false] - If set to true, all the children will have their destroy\n * method called as well. 'options' will be passed on to those calls.\n * @param {boolean} [options.texture=false] - Should it destroy the current texture of the sprite as well.\n * @param {boolean} [options.baseTexture=false] - Should it destroy the base texture of the sprite as well.\n */\n AnimatedSprite.prototype.destroy = function (options) {\n this.stop();\n _super.prototype.destroy.call(this, options);\n this.onComplete = null;\n this.onFrameChange = null;\n this.onLoop = null;\n };\n /**\n * A short hand way of creating an AnimatedSprite from an array of frame ids.\n *\n * @param frames - The array of frames ids the AnimatedSprite will use as its texture frames.\n * @return - The new animated sprite with the specified frames.\n */\n AnimatedSprite.fromFrames = function (frames) {\n var textures = [];\n for (var i = 0; i < frames.length; ++i) {\n textures.push(Texture.from(frames[i]));\n }\n return new AnimatedSprite(textures);\n };\n /**\n * A short hand way of creating an AnimatedSprite from an array of image ids.\n *\n * @param images - The array of image urls the AnimatedSprite will use as its texture frames.\n * @return The new animate sprite with the specified images as frames.\n */\n AnimatedSprite.fromImages = function (images) {\n var textures = [];\n for (var i = 0; i < images.length; ++i) {\n textures.push(Texture.from(images[i]));\n }\n return new AnimatedSprite(textures);\n };\n Object.defineProperty(AnimatedSprite.prototype, \"totalFrames\", {\n /**\n * The total number of frames in the AnimatedSprite. This is the same as number of textures\n * assigned to the AnimatedSprite.\n *\n * @readonly\n * @default 0\n */\n get: function () {\n return this._textures.length;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"textures\", {\n /** The array of textures used for this AnimatedSprite. */\n get: function () {\n return this._textures;\n },\n set: function (value) {\n if (value[0] instanceof Texture) {\n this._textures = value;\n this._durations = null;\n }\n else {\n this._textures = [];\n this._durations = [];\n for (var i = 0; i < value.length; i++) {\n this._textures.push(value[i].texture);\n this._durations.push(value[i].time);\n }\n }\n this._previousFrame = null;\n this.gotoAndStop(0);\n this.updateTexture();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"currentFrame\", {\n /**\n * The AnimatedSprites current frame index.\n *\n * @readonly\n */\n get: function () {\n var currentFrame = Math.floor(this._currentTime) % this._textures.length;\n if (currentFrame < 0) {\n currentFrame += this._textures.length;\n }\n return currentFrame;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"playing\", {\n /**\n * Indicates if the AnimatedSprite is currently playing.\n *\n * @readonly\n */\n get: function () {\n return this._playing;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(AnimatedSprite.prototype, \"autoUpdate\", {\n /** Whether to use PIXI.Ticker.shared to auto update animation time. */\n get: function () {\n return this._autoUpdate;\n },\n set: function (value) {\n if (value !== this._autoUpdate) {\n this._autoUpdate = value;\n if (!this._autoUpdate && this._isConnectedToTicker) {\n Ticker.shared.remove(this.update, this);\n this._isConnectedToTicker = false;\n }\n else if (this._autoUpdate && !this._isConnectedToTicker && this._playing) {\n Ticker.shared.add(this.update, this);\n this._isConnectedToTicker = true;\n }\n }\n },\n enumerable: false,\n configurable: true\n });\n return AnimatedSprite;\n}(Sprite));\n\nexport { AnimatedSprite };\n//# sourceMappingURL=sprite-animated.js.map\n","/*!\n * pixi.js - v6.3.0\n * Compiled Wed, 23 Mar 2022 18:58:56 UTC\n *\n * pixi.js is licensed under the MIT License.\n * http://www.opensource.org/licenses/mit-license\n */\nimport '@pixi/polyfill';\nimport * as utils from '@pixi/utils';\nexport { utils };\nimport { AccessibilityManager } from '@pixi/accessibility';\nexport * from '@pixi/accessibility';\nimport { InteractionManager } from '@pixi/interaction';\nexport * from '@pixi/interaction';\nimport { Application } from '@pixi/app';\nexport * from '@pixi/app';\nimport { Renderer, BatchRenderer } from '@pixi/core';\nexport * from '@pixi/core';\nimport { Extract } from '@pixi/extract';\nexport * from '@pixi/extract';\nimport { Loader, AppLoaderPlugin } from '@pixi/loaders';\nexport * from '@pixi/loaders';\nimport { CompressedTextureLoader, DDSLoader, KTXLoader } from '@pixi/compressed-textures';\nexport * from '@pixi/compressed-textures';\nimport { ParticleRenderer } from '@pixi/particle-container';\nexport * from '@pixi/particle-container';\nimport { Prepare } from '@pixi/prepare';\nexport * from '@pixi/prepare';\nimport { SpritesheetLoader } from '@pixi/spritesheet';\nexport * from '@pixi/spritesheet';\nimport { TilingSpriteRenderer } from '@pixi/sprite-tiling';\nexport * from '@pixi/sprite-tiling';\nimport { BitmapFontLoader } from '@pixi/text-bitmap';\nexport * from '@pixi/text-bitmap';\nimport { TickerPlugin } from '@pixi/ticker';\nexport * from '@pixi/ticker';\nimport { AlphaFilter } from '@pixi/filter-alpha';\nimport { BlurFilter, BlurFilterPass } from '@pixi/filter-blur';\nimport { ColorMatrixFilter } from '@pixi/filter-color-matrix';\nimport { DisplacementFilter } from '@pixi/filter-displacement';\nimport { FXAAFilter } from '@pixi/filter-fxaa';\nimport { NoiseFilter } from '@pixi/filter-noise';\nimport '@pixi/mixin-cache-as-bitmap';\nimport '@pixi/mixin-get-child-by-name';\nimport '@pixi/mixin-get-global-position';\nexport * from '@pixi/constants';\nexport * from '@pixi/display';\nexport * from '@pixi/graphics';\nexport * from '@pixi/math';\nexport * from '@pixi/mesh';\nexport * from '@pixi/mesh-extras';\nexport * from '@pixi/runner';\nexport * from '@pixi/sprite';\nexport * from '@pixi/sprite-animated';\nexport * from '@pixi/text';\nexport * from '@pixi/settings';\n\n// Install renderer plugins\nRenderer.registerPlugin('accessibility', AccessibilityManager);\nRenderer.registerPlugin('extract', Extract);\nRenderer.registerPlugin('interaction', InteractionManager);\nRenderer.registerPlugin('particle', ParticleRenderer);\nRenderer.registerPlugin('prepare', Prepare);\nRenderer.registerPlugin('batch', BatchRenderer);\nRenderer.registerPlugin('tilingSprite', TilingSpriteRenderer);\n// Install loader plugins\nLoader.registerPlugin(BitmapFontLoader);\nLoader.registerPlugin(CompressedTextureLoader);\nLoader.registerPlugin(DDSLoader);\nLoader.registerPlugin(KTXLoader);\nLoader.registerPlugin(SpritesheetLoader);\n// Install application plugins\nApplication.registerPlugin(TickerPlugin);\nApplication.registerPlugin(AppLoaderPlugin);\n/**\n * String of the current PIXI version.\n *\n * @static\n * @constant\n * @memberof PIXI\n * @name VERSION\n * @type {string}\n */\nvar VERSION = '6.3.0';\n/**\n * @namespace PIXI\n */\n/**\n * This namespace contains WebGL-only display filters that can be applied\n * to DisplayObjects using the {@link PIXI.DisplayObject#filters filters} property.\n *\n * Since PixiJS only had a handful of built-in filters, additional filters\n * can be downloaded {@link https://github.com/pixijs/pixi-filters here} from the\n * PixiJS Filters repository.\n *\n * All filters must extend {@link PIXI.Filter}.\n *\n * @example\n * // Create a new application\n * const app = new PIXI.Application();\n *\n * // Draw a green rectangle\n * const rect = new PIXI.Graphics()\n * .beginFill(0x00ff00)\n * .drawRect(40, 40, 200, 200);\n *\n * // Add a blur filter\n * rect.filters = [new PIXI.filters.BlurFilter()];\n *\n * // Display rectangle\n * app.stage.addChild(rect);\n * document.body.appendChild(app.view);\n * @namespace PIXI.filters\n */\nvar filters = {\n AlphaFilter: AlphaFilter,\n BlurFilter: BlurFilter,\n BlurFilterPass: BlurFilterPass,\n ColorMatrixFilter: ColorMatrixFilter,\n DisplacementFilter: DisplacementFilter,\n FXAAFilter: FXAAFilter,\n NoiseFilter: NoiseFilter,\n};\n\nexport { VERSION, filters };\n//# sourceMappingURL=pixi.js.map\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\n// If obj.hasOwnProperty has been overridden, then calling\n// obj.hasOwnProperty(prop) will break.\n// See: https://github.com/joyent/node/issues/1707\nfunction hasOwnProperty(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\nmodule.exports = function(qs, sep, eq, options) {\n sep = sep || '&';\n eq = eq || '=';\n var obj = {};\n\n if (typeof qs !== 'string' || qs.length === 0) {\n return obj;\n }\n\n var regexp = /\\+/g;\n qs = qs.split(sep);\n\n var maxKeys = 1000;\n if (options && typeof options.maxKeys === 'number') {\n maxKeys = options.maxKeys;\n }\n\n var len = qs.length;\n // maxKeys <= 0 means that we should not limit keys count\n if (maxKeys > 0 && len > maxKeys) {\n len = maxKeys;\n }\n\n for (var i = 0; i < len; ++i) {\n var x = qs[i].replace(regexp, '%20'),\n idx = x.indexOf(eq),\n kstr, vstr, k, v;\n\n if (idx >= 0) {\n kstr = x.substr(0, idx);\n vstr = x.substr(idx + 1);\n } else {\n kstr = x;\n vstr = '';\n }\n\n k = decodeURIComponent(kstr);\n v = decodeURIComponent(vstr);\n\n if (!hasOwnProperty(obj, k)) {\n obj[k] = v;\n } else if (Array.isArray(obj[k])) {\n obj[k].push(v);\n } else {\n obj[k] = [obj[k], v];\n }\n }\n\n return obj;\n};\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\nvar stringifyPrimitive = function(v) {\n switch (typeof v) {\n case 'string':\n return v;\n\n case 'boolean':\n return v ? 'true' : 'false';\n\n case 'number':\n return isFinite(v) ? v : '';\n\n default:\n return '';\n }\n};\n\nmodule.exports = function(obj, sep, eq, name) {\n sep = sep || '&';\n eq = eq || '=';\n if (obj === null) {\n obj = undefined;\n }\n\n if (typeof obj === 'object') {\n return Object.keys(obj).map(function(k) {\n var ks = encodeURIComponent(stringifyPrimitive(k)) + eq;\n if (Array.isArray(obj[k])) {\n return obj[k].map(function(v) {\n return ks + encodeURIComponent(stringifyPrimitive(v));\n }).join(sep);\n } else {\n return ks + encodeURIComponent(stringifyPrimitive(obj[k]));\n }\n }).join(sep);\n\n }\n\n if (!name) return '';\n return encodeURIComponent(stringifyPrimitive(name)) + eq +\n encodeURIComponent(stringifyPrimitive(obj));\n};\n","'use strict';\n\nexports.decode = exports.parse = require('./decode');\nexports.encode = exports.stringify = require('./encode');\n","/**!\n * Sortable 1.14.0\n * @author\tRubaXa <trash@rubaxa.org>\n * @author\towenm <owen23355@gmail.com>\n * @license MIT\n */\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n\n if (enumerableOnly) {\n symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n }\n\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nfunction _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}\n\nfunction _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function (obj) {\n return typeof obj;\n };\n } else {\n _typeof = function (obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}\n\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}\n\nfunction _extends() {\n _extends = Object.assign || function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n\n return target;\n };\n\n return _extends.apply(this, arguments);\n}\n\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n\n return target;\n}\n\nfunction _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n\n var target = _objectWithoutPropertiesLoose(source, excluded);\n\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}\n\nfunction _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n}\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n}\n\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n}\n\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];\n\n return arr2;\n}\n\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n\nvar version = \"1.14.0\";\n\nfunction userAgent(pattern) {\n if (typeof window !== 'undefined' && window.navigator) {\n return !! /*@__PURE__*/navigator.userAgent.match(pattern);\n }\n}\n\nvar IE11OrLess = userAgent(/(?:Trident.*rv[ :]?11\\.|msie|iemobile|Windows Phone)/i);\nvar Edge = userAgent(/Edge/i);\nvar FireFox = userAgent(/firefox/i);\nvar Safari = userAgent(/safari/i) && !userAgent(/chrome/i) && !userAgent(/android/i);\nvar IOS = userAgent(/iP(ad|od|hone)/i);\nvar ChromeForAndroid = userAgent(/chrome/i) && userAgent(/android/i);\n\nvar captureMode = {\n capture: false,\n passive: false\n};\n\nfunction on(el, event, fn) {\n el.addEventListener(event, fn, !IE11OrLess && captureMode);\n}\n\nfunction off(el, event, fn) {\n el.removeEventListener(event, fn, !IE11OrLess && captureMode);\n}\n\nfunction matches(\n/**HTMLElement*/\nel,\n/**String*/\nselector) {\n if (!selector) return;\n selector[0] === '>' && (selector = selector.substring(1));\n\n if (el) {\n try {\n if (el.matches) {\n return el.matches(selector);\n } else if (el.msMatchesSelector) {\n return el.msMatchesSelector(selector);\n } else if (el.webkitMatchesSelector) {\n return el.webkitMatchesSelector(selector);\n }\n } catch (_) {\n return false;\n }\n }\n\n return false;\n}\n\nfunction getParentOrHost(el) {\n return el.host && el !== document && el.host.nodeType ? el.host : el.parentNode;\n}\n\nfunction closest(\n/**HTMLElement*/\nel,\n/**String*/\nselector,\n/**HTMLElement*/\nctx, includeCTX) {\n if (el) {\n ctx = ctx || document;\n\n do {\n if (selector != null && (selector[0] === '>' ? el.parentNode === ctx && matches(el, selector) : matches(el, selector)) || includeCTX && el === ctx) {\n return el;\n }\n\n if (el === ctx) break;\n /* jshint boss:true */\n } while (el = getParentOrHost(el));\n }\n\n return null;\n}\n\nvar R_SPACE = /\\s+/g;\n\nfunction toggleClass(el, name, state) {\n if (el && name) {\n if (el.classList) {\n el.classList[state ? 'add' : 'remove'](name);\n } else {\n var className = (' ' + el.className + ' ').replace(R_SPACE, ' ').replace(' ' + name + ' ', ' ');\n el.className = (className + (state ? ' ' + name : '')).replace(R_SPACE, ' ');\n }\n }\n}\n\nfunction css(el, prop, val) {\n var style = el && el.style;\n\n if (style) {\n if (val === void 0) {\n if (document.defaultView && document.defaultView.getComputedStyle) {\n val = document.defaultView.getComputedStyle(el, '');\n } else if (el.currentStyle) {\n val = el.currentStyle;\n }\n\n return prop === void 0 ? val : val[prop];\n } else {\n if (!(prop in style) && prop.indexOf('webkit') === -1) {\n prop = '-webkit-' + prop;\n }\n\n style[prop] = val + (typeof val === 'string' ? '' : 'px');\n }\n }\n}\n\nfunction matrix(el, selfOnly) {\n var appliedTransforms = '';\n\n if (typeof el === 'string') {\n appliedTransforms = el;\n } else {\n do {\n var transform = css(el, 'transform');\n\n if (transform && transform !== 'none') {\n appliedTransforms = transform + ' ' + appliedTransforms;\n }\n /* jshint boss:true */\n\n } while (!selfOnly && (el = el.parentNode));\n }\n\n var matrixFn = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;\n /*jshint -W056 */\n\n return matrixFn && new matrixFn(appliedTransforms);\n}\n\nfunction find(ctx, tagName, iterator) {\n if (ctx) {\n var list = ctx.getElementsByTagName(tagName),\n i = 0,\n n = list.length;\n\n if (iterator) {\n for (; i < n; i++) {\n iterator(list[i], i);\n }\n }\n\n return list;\n }\n\n return [];\n}\n\nfunction getWindowScrollingElement() {\n var scrollingElement = document.scrollingElement;\n\n if (scrollingElement) {\n return scrollingElement;\n } else {\n return document.documentElement;\n }\n}\n/**\n * Returns the \"bounding client rect\" of given element\n * @param {HTMLElement} el The element whose boundingClientRect is wanted\n * @param {[Boolean]} relativeToContainingBlock Whether the rect should be relative to the containing block of (including) the container\n * @param {[Boolean]} relativeToNonStaticParent Whether the rect should be relative to the relative parent of (including) the contaienr\n * @param {[Boolean]} undoScale Whether the container's scale() should be undone\n * @param {[HTMLElement]} container The parent the element will be placed in\n * @return {Object} The boundingClientRect of el, with specified adjustments\n */\n\n\nfunction getRect(el, relativeToContainingBlock, relativeToNonStaticParent, undoScale, container) {\n if (!el.getBoundingClientRect && el !== window) return;\n var elRect, top, left, bottom, right, height, width;\n\n if (el !== window && el.parentNode && el !== getWindowScrollingElement()) {\n elRect = el.getBoundingClientRect();\n top = elRect.top;\n left = elRect.left;\n bottom = elRect.bottom;\n right = elRect.right;\n height = elRect.height;\n width = elRect.width;\n } else {\n top = 0;\n left = 0;\n bottom = window.innerHeight;\n right = window.innerWidth;\n height = window.innerHeight;\n width = window.innerWidth;\n }\n\n if ((relativeToContainingBlock || relativeToNonStaticParent) && el !== window) {\n // Adjust for translate()\n container = container || el.parentNode; // solves #1123 (see: https://stackoverflow.com/a/37953806/6088312)\n // Not needed on <= IE11\n\n if (!IE11OrLess) {\n do {\n if (container && container.getBoundingClientRect && (css(container, 'transform') !== 'none' || relativeToNonStaticParent && css(container, 'position') !== 'static')) {\n var containerRect = container.getBoundingClientRect(); // Set relative to edges of padding box of container\n\n top -= containerRect.top + parseInt(css(container, 'border-top-width'));\n left -= containerRect.left + parseInt(css(container, 'border-left-width'));\n bottom = top + elRect.height;\n right = left + elRect.width;\n break;\n }\n /* jshint boss:true */\n\n } while (container = container.parentNode);\n }\n }\n\n if (undoScale && el !== window) {\n // Adjust for scale()\n var elMatrix = matrix(container || el),\n scaleX = elMatrix && elMatrix.a,\n scaleY = elMatrix && elMatrix.d;\n\n if (elMatrix) {\n top /= scaleY;\n left /= scaleX;\n width /= scaleX;\n height /= scaleY;\n bottom = top + height;\n right = left + width;\n }\n }\n\n return {\n top: top,\n left: left,\n bottom: bottom,\n right: right,\n width: width,\n height: height\n };\n}\n/**\n * Checks if a side of an element is scrolled past a side of its parents\n * @param {HTMLElement} el The element who's side being scrolled out of view is in question\n * @param {String} elSide Side of the element in question ('top', 'left', 'right', 'bottom')\n * @param {String} parentSide Side of the parent in question ('top', 'left', 'right', 'bottom')\n * @return {HTMLElement} The parent scroll element that the el's side is scrolled past, or null if there is no such element\n */\n\n\nfunction isScrolledPast(el, elSide, parentSide) {\n var parent = getParentAutoScrollElement(el, true),\n elSideVal = getRect(el)[elSide];\n /* jshint boss:true */\n\n while (parent) {\n var parentSideVal = getRect(parent)[parentSide],\n visible = void 0;\n\n if (parentSide === 'top' || parentSide === 'left') {\n visible = elSideVal >= parentSideVal;\n } else {\n visible = elSideVal <= parentSideVal;\n }\n\n if (!visible) return parent;\n if (parent === getWindowScrollingElement()) break;\n parent = getParentAutoScrollElement(parent, false);\n }\n\n return false;\n}\n/**\n * Gets nth child of el, ignoring hidden children, sortable's elements (does not ignore clone if it's visible)\n * and non-draggable elements\n * @param {HTMLElement} el The parent element\n * @param {Number} childNum The index of the child\n * @param {Object} options Parent Sortable's options\n * @return {HTMLElement} The child at index childNum, or null if not found\n */\n\n\nfunction getChild(el, childNum, options, includeDragEl) {\n var currentChild = 0,\n i = 0,\n children = el.children;\n\n while (i < children.length) {\n if (children[i].style.display !== 'none' && children[i] !== Sortable.ghost && (includeDragEl || children[i] !== Sortable.dragged) && closest(children[i], options.draggable, el, false)) {\n if (currentChild === childNum) {\n return children[i];\n }\n\n currentChild++;\n }\n\n i++;\n }\n\n return null;\n}\n/**\n * Gets the last child in the el, ignoring ghostEl or invisible elements (clones)\n * @param {HTMLElement} el Parent element\n * @param {selector} selector Any other elements that should be ignored\n * @return {HTMLElement} The last child, ignoring ghostEl\n */\n\n\nfunction lastChild(el, selector) {\n var last = el.lastElementChild;\n\n while (last && (last === Sortable.ghost || css(last, 'display') === 'none' || selector && !matches(last, selector))) {\n last = last.previousElementSibling;\n }\n\n return last || null;\n}\n/**\n * Returns the index of an element within its parent for a selected set of\n * elements\n * @param {HTMLElement} el\n * @param {selector} selector\n * @return {number}\n */\n\n\nfunction index(el, selector) {\n var index = 0;\n\n if (!el || !el.parentNode) {\n return -1;\n }\n /* jshint boss:true */\n\n\n while (el = el.previousElementSibling) {\n if (el.nodeName.toUpperCase() !== 'TEMPLATE' && el !== Sortable.clone && (!selector || matches(el, selector))) {\n index++;\n }\n }\n\n return index;\n}\n/**\n * Returns the scroll offset of the given element, added with all the scroll offsets of parent elements.\n * The value is returned in real pixels.\n * @param {HTMLElement} el\n * @return {Array} Offsets in the format of [left, top]\n */\n\n\nfunction getRelativeScrollOffset(el) {\n var offsetLeft = 0,\n offsetTop = 0,\n winScroller = getWindowScrollingElement();\n\n if (el) {\n do {\n var elMatrix = matrix(el),\n scaleX = elMatrix.a,\n scaleY = elMatrix.d;\n offsetLeft += el.scrollLeft * scaleX;\n offsetTop += el.scrollTop * scaleY;\n } while (el !== winScroller && (el = el.parentNode));\n }\n\n return [offsetLeft, offsetTop];\n}\n/**\n * Returns the index of the object within the given array\n * @param {Array} arr Array that may or may not hold the object\n * @param {Object} obj An object that has a key-value pair unique to and identical to a key-value pair in the object you want to find\n * @return {Number} The index of the object in the array, or -1\n */\n\n\nfunction indexOfObject(arr, obj) {\n for (var i in arr) {\n if (!arr.hasOwnProperty(i)) continue;\n\n for (var key in obj) {\n if (obj.hasOwnProperty(key) && obj[key] === arr[i][key]) return Number(i);\n }\n }\n\n return -1;\n}\n\nfunction getParentAutoScrollElement(el, includeSelf) {\n // skip to window\n if (!el || !el.getBoundingClientRect) return getWindowScrollingElement();\n var elem = el;\n var gotSelf = false;\n\n do {\n // we don't need to get elem css if it isn't even overflowing in the first place (performance)\n if (elem.clientWidth < elem.scrollWidth || elem.clientHeight < elem.scrollHeight) {\n var elemCSS = css(elem);\n\n if (elem.clientWidth < elem.scrollWidth && (elemCSS.overflowX == 'auto' || elemCSS.overflowX == 'scroll') || elem.clientHeight < elem.scrollHeight && (elemCSS.overflowY == 'auto' || elemCSS.overflowY == 'scroll')) {\n if (!elem.getBoundingClientRect || elem === document.body) return getWindowScrollingElement();\n if (gotSelf || includeSelf) return elem;\n gotSelf = true;\n }\n }\n /* jshint boss:true */\n\n } while (elem = elem.parentNode);\n\n return getWindowScrollingElement();\n}\n\nfunction extend(dst, src) {\n if (dst && src) {\n for (var key in src) {\n if (src.hasOwnProperty(key)) {\n dst[key] = src[key];\n }\n }\n }\n\n return dst;\n}\n\nfunction isRectEqual(rect1, rect2) {\n return Math.round(rect1.top) === Math.round(rect2.top) && Math.round(rect1.left) === Math.round(rect2.left) && Math.round(rect1.height) === Math.round(rect2.height) && Math.round(rect1.width) === Math.round(rect2.width);\n}\n\nvar _throttleTimeout;\n\nfunction throttle(callback, ms) {\n return function () {\n if (!_throttleTimeout) {\n var args = arguments,\n _this = this;\n\n if (args.length === 1) {\n callback.call(_this, args[0]);\n } else {\n callback.apply(_this, args);\n }\n\n _throttleTimeout = setTimeout(function () {\n _throttleTimeout = void 0;\n }, ms);\n }\n };\n}\n\nfunction cancelThrottle() {\n clearTimeout(_throttleTimeout);\n _throttleTimeout = void 0;\n}\n\nfunction scrollBy(el, x, y) {\n el.scrollLeft += x;\n el.scrollTop += y;\n}\n\nfunction clone(el) {\n var Polymer = window.Polymer;\n var $ = window.jQuery || window.Zepto;\n\n if (Polymer && Polymer.dom) {\n return Polymer.dom(el).cloneNode(true);\n } else if ($) {\n return $(el).clone(true)[0];\n } else {\n return el.cloneNode(true);\n }\n}\n\nfunction setRect(el, rect) {\n css(el, 'position', 'absolute');\n css(el, 'top', rect.top);\n css(el, 'left', rect.left);\n css(el, 'width', rect.width);\n css(el, 'height', rect.height);\n}\n\nfunction unsetRect(el) {\n css(el, 'position', '');\n css(el, 'top', '');\n css(el, 'left', '');\n css(el, 'width', '');\n css(el, 'height', '');\n}\n\nvar expando = 'Sortable' + new Date().getTime();\n\nfunction AnimationStateManager() {\n var animationStates = [],\n animationCallbackId;\n return {\n captureAnimationState: function captureAnimationState() {\n animationStates = [];\n if (!this.options.animation) return;\n var children = [].slice.call(this.el.children);\n children.forEach(function (child) {\n if (css(child, 'display') === 'none' || child === Sortable.ghost) return;\n animationStates.push({\n target: child,\n rect: getRect(child)\n });\n\n var fromRect = _objectSpread2({}, animationStates[animationStates.length - 1].rect); // If animating: compensate for current animation\n\n\n if (child.thisAnimationDuration) {\n var childMatrix = matrix(child, true);\n\n if (childMatrix) {\n fromRect.top -= childMatrix.f;\n fromRect.left -= childMatrix.e;\n }\n }\n\n child.fromRect = fromRect;\n });\n },\n addAnimationState: function addAnimationState(state) {\n animationStates.push(state);\n },\n removeAnimationState: function removeAnimationState(target) {\n animationStates.splice(indexOfObject(animationStates, {\n target: target\n }), 1);\n },\n animateAll: function animateAll(callback) {\n var _this = this;\n\n if (!this.options.animation) {\n clearTimeout(animationCallbackId);\n if (typeof callback === 'function') callback();\n return;\n }\n\n var animating = false,\n animationTime = 0;\n animationStates.forEach(function (state) {\n var time = 0,\n target = state.target,\n fromRect = target.fromRect,\n toRect = getRect(target),\n prevFromRect = target.prevFromRect,\n prevToRect = target.prevToRect,\n animatingRect = state.rect,\n targetMatrix = matrix(target, true);\n\n if (targetMatrix) {\n // Compensate for current animation\n toRect.top -= targetMatrix.f;\n toRect.left -= targetMatrix.e;\n }\n\n target.toRect = toRect;\n\n if (target.thisAnimationDuration) {\n // Could also check if animatingRect is between fromRect and toRect\n if (isRectEqual(prevFromRect, toRect) && !isRectEqual(fromRect, toRect) && // Make sure animatingRect is on line between toRect & fromRect\n (animatingRect.top - toRect.top) / (animatingRect.left - toRect.left) === (fromRect.top - toRect.top) / (fromRect.left - toRect.left)) {\n // If returning to same place as started from animation and on same axis\n time = calculateRealTime(animatingRect, prevFromRect, prevToRect, _this.options);\n }\n } // if fromRect != toRect: animate\n\n\n if (!isRectEqual(toRect, fromRect)) {\n target.prevFromRect = fromRect;\n target.prevToRect = toRect;\n\n if (!time) {\n time = _this.options.animation;\n }\n\n _this.animate(target, animatingRect, toRect, time);\n }\n\n if (time) {\n animating = true;\n animationTime = Math.max(animationTime, time);\n clearTimeout(target.animationResetTimer);\n target.animationResetTimer = setTimeout(function () {\n target.animationTime = 0;\n target.prevFromRect = null;\n target.fromRect = null;\n target.prevToRect = null;\n target.thisAnimationDuration = null;\n }, time);\n target.thisAnimationDuration = time;\n }\n });\n clearTimeout(animationCallbackId);\n\n if (!animating) {\n if (typeof callback === 'function') callback();\n } else {\n animationCallbackId = setTimeout(function () {\n if (typeof callback === 'function') callback();\n }, animationTime);\n }\n\n animationStates = [];\n },\n animate: function animate(target, currentRect, toRect, duration) {\n if (duration) {\n css(target, 'transition', '');\n css(target, 'transform', '');\n var elMatrix = matrix(this.el),\n scaleX = elMatrix && elMatrix.a,\n scaleY = elMatrix && elMatrix.d,\n translateX = (currentRect.left - toRect.left) / (scaleX || 1),\n translateY = (currentRect.top - toRect.top) / (scaleY || 1);\n target.animatingX = !!translateX;\n target.animatingY = !!translateY;\n css(target, 'transform', 'translate3d(' + translateX + 'px,' + translateY + 'px,0)');\n this.forRepaintDummy = repaint(target); // repaint\n\n css(target, 'transition', 'transform ' + duration + 'ms' + (this.options.easing ? ' ' + this.options.easing : ''));\n css(target, 'transform', 'translate3d(0,0,0)');\n typeof target.animated === 'number' && clearTimeout(target.animated);\n target.animated = setTimeout(function () {\n css(target, 'transition', '');\n css(target, 'transform', '');\n target.animated = false;\n target.animatingX = false;\n target.animatingY = false;\n }, duration);\n }\n }\n };\n}\n\nfunction repaint(target) {\n return target.offsetWidth;\n}\n\nfunction calculateRealTime(animatingRect, fromRect, toRect, options) {\n return Math.sqrt(Math.pow(fromRect.top - animatingRect.top, 2) + Math.pow(fromRect.left - animatingRect.left, 2)) / Math.sqrt(Math.pow(fromRect.top - toRect.top, 2) + Math.pow(fromRect.left - toRect.left, 2)) * options.animation;\n}\n\nvar plugins = [];\nvar defaults = {\n initializeByDefault: true\n};\nvar PluginManager = {\n mount: function mount(plugin) {\n // Set default static properties\n for (var option in defaults) {\n if (defaults.hasOwnProperty(option) && !(option in plugin)) {\n plugin[option] = defaults[option];\n }\n }\n\n plugins.forEach(function (p) {\n if (p.pluginName === plugin.pluginName) {\n throw \"Sortable: Cannot mount plugin \".concat(plugin.pluginName, \" more than once\");\n }\n });\n plugins.push(plugin);\n },\n pluginEvent: function pluginEvent(eventName, sortable, evt) {\n var _this = this;\n\n this.eventCanceled = false;\n\n evt.cancel = function () {\n _this.eventCanceled = true;\n };\n\n var eventNameGlobal = eventName + 'Global';\n plugins.forEach(function (plugin) {\n if (!sortable[plugin.pluginName]) return; // Fire global events if it exists in this sortable\n\n if (sortable[plugin.pluginName][eventNameGlobal]) {\n sortable[plugin.pluginName][eventNameGlobal](_objectSpread2({\n sortable: sortable\n }, evt));\n } // Only fire plugin event if plugin is enabled in this sortable,\n // and plugin has event defined\n\n\n if (sortable.options[plugin.pluginName] && sortable[plugin.pluginName][eventName]) {\n sortable[plugin.pluginName][eventName](_objectSpread2({\n sortable: sortable\n }, evt));\n }\n });\n },\n initializePlugins: function initializePlugins(sortable, el, defaults, options) {\n plugins.forEach(function (plugin) {\n var pluginName = plugin.pluginName;\n if (!sortable.options[pluginName] && !plugin.initializeByDefault) return;\n var initialized = new plugin(sortable, el, sortable.options);\n initialized.sortable = sortable;\n initialized.options = sortable.options;\n sortable[pluginName] = initialized; // Add default options from plugin\n\n _extends(defaults, initialized.defaults);\n });\n\n for (var option in sortable.options) {\n if (!sortable.options.hasOwnProperty(option)) continue;\n var modified = this.modifyOption(sortable, option, sortable.options[option]);\n\n if (typeof modified !== 'undefined') {\n sortable.options[option] = modified;\n }\n }\n },\n getEventProperties: function getEventProperties(name, sortable) {\n var eventProperties = {};\n plugins.forEach(function (plugin) {\n if (typeof plugin.eventProperties !== 'function') return;\n\n _extends(eventProperties, plugin.eventProperties.call(sortable[plugin.pluginName], name));\n });\n return eventProperties;\n },\n modifyOption: function modifyOption(sortable, name, value) {\n var modifiedValue;\n plugins.forEach(function (plugin) {\n // Plugin must exist on the Sortable\n if (!sortable[plugin.pluginName]) return; // If static option listener exists for this option, call in the context of the Sortable's instance of this plugin\n\n if (plugin.optionListeners && typeof plugin.optionListeners[name] === 'function') {\n modifiedValue = plugin.optionListeners[name].call(sortable[plugin.pluginName], value);\n }\n });\n return modifiedValue;\n }\n};\n\nfunction dispatchEvent(_ref) {\n var sortable = _ref.sortable,\n rootEl = _ref.rootEl,\n name = _ref.name,\n targetEl = _ref.targetEl,\n cloneEl = _ref.cloneEl,\n toEl = _ref.toEl,\n fromEl = _ref.fromEl,\n oldIndex = _ref.oldIndex,\n newIndex = _ref.newIndex,\n oldDraggableIndex = _ref.oldDraggableIndex,\n newDraggableIndex = _ref.newDraggableIndex,\n originalEvent = _ref.originalEvent,\n putSortable = _ref.putSortable,\n extraEventProperties = _ref.extraEventProperties;\n sortable = sortable || rootEl && rootEl[expando];\n if (!sortable) return;\n var evt,\n options = sortable.options,\n onName = 'on' + name.charAt(0).toUpperCase() + name.substr(1); // Support for new CustomEvent feature\n\n if (window.CustomEvent && !IE11OrLess && !Edge) {\n evt = new CustomEvent(name, {\n bubbles: true,\n cancelable: true\n });\n } else {\n evt = document.createEvent('Event');\n evt.initEvent(name, true, true);\n }\n\n evt.to = toEl || rootEl;\n evt.from = fromEl || rootEl;\n evt.item = targetEl || rootEl;\n evt.clone = cloneEl;\n evt.oldIndex = oldIndex;\n evt.newIndex = newIndex;\n evt.oldDraggableIndex = oldDraggableIndex;\n evt.newDraggableIndex = newDraggableIndex;\n evt.originalEvent = originalEvent;\n evt.pullMode = putSortable ? putSortable.lastPutMode : undefined;\n\n var allEventProperties = _objectSpread2(_objectSpread2({}, extraEventProperties), PluginManager.getEventProperties(name, sortable));\n\n for (var option in allEventProperties) {\n evt[option] = allEventProperties[option];\n }\n\n if (rootEl) {\n rootEl.dispatchEvent(evt);\n }\n\n if (options[onName]) {\n options[onName].call(sortable, evt);\n }\n}\n\nvar _excluded = [\"evt\"];\n\nvar pluginEvent = function pluginEvent(eventName, sortable) {\n var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},\n originalEvent = _ref.evt,\n data = _objectWithoutProperties(_ref, _excluded);\n\n PluginManager.pluginEvent.bind(Sortable)(eventName, sortable, _objectSpread2({\n dragEl: dragEl,\n parentEl: parentEl,\n ghostEl: ghostEl,\n rootEl: rootEl,\n nextEl: nextEl,\n lastDownEl: lastDownEl,\n cloneEl: cloneEl,\n cloneHidden: cloneHidden,\n dragStarted: moved,\n putSortable: putSortable,\n activeSortable: Sortable.active,\n originalEvent: originalEvent,\n oldIndex: oldIndex,\n oldDraggableIndex: oldDraggableIndex,\n newIndex: newIndex,\n newDraggableIndex: newDraggableIndex,\n hideGhostForTarget: _hideGhostForTarget,\n unhideGhostForTarget: _unhideGhostForTarget,\n cloneNowHidden: function cloneNowHidden() {\n cloneHidden = true;\n },\n cloneNowShown: function cloneNowShown() {\n cloneHidden = false;\n },\n dispatchSortableEvent: function dispatchSortableEvent(name) {\n _dispatchEvent({\n sortable: sortable,\n name: name,\n originalEvent: originalEvent\n });\n }\n }, data));\n};\n\nfunction _dispatchEvent(info) {\n dispatchEvent(_objectSpread2({\n putSortable: putSortable,\n cloneEl: cloneEl,\n targetEl: dragEl,\n rootEl: rootEl,\n oldIndex: oldIndex,\n oldDraggableIndex: oldDraggableIndex,\n newIndex: newIndex,\n newDraggableIndex: newDraggableIndex\n }, info));\n}\n\nvar dragEl,\n parentEl,\n ghostEl,\n rootEl,\n nextEl,\n lastDownEl,\n cloneEl,\n cloneHidden,\n oldIndex,\n newIndex,\n oldDraggableIndex,\n newDraggableIndex,\n activeGroup,\n putSortable,\n awaitingDragStarted = false,\n ignoreNextClick = false,\n sortables = [],\n tapEvt,\n touchEvt,\n lastDx,\n lastDy,\n tapDistanceLeft,\n tapDistanceTop,\n moved,\n lastTarget,\n lastDirection,\n pastFirstInvertThresh = false,\n isCircumstantialInvert = false,\n targetMoveDistance,\n // For positioning ghost absolutely\nghostRelativeParent,\n ghostRelativeParentInitialScroll = [],\n // (left, top)\n_silent = false,\n savedInputChecked = [];\n/** @const */\n\nvar documentExists = typeof document !== 'undefined',\n PositionGhostAbsolutely = IOS,\n CSSFloatProperty = Edge || IE11OrLess ? 'cssFloat' : 'float',\n // This will not pass for IE9, because IE9 DnD only works on anchors\nsupportDraggable = documentExists && !ChromeForAndroid && !IOS && 'draggable' in document.createElement('div'),\n supportCssPointerEvents = function () {\n if (!documentExists) return; // false when <= IE11\n\n if (IE11OrLess) {\n return false;\n }\n\n var el = document.createElement('x');\n el.style.cssText = 'pointer-events:auto';\n return el.style.pointerEvents === 'auto';\n}(),\n _detectDirection = function _detectDirection(el, options) {\n var elCSS = css(el),\n elWidth = parseInt(elCSS.width) - parseInt(elCSS.paddingLeft) - parseInt(elCSS.paddingRight) - parseInt(elCSS.borderLeftWidth) - parseInt(elCSS.borderRightWidth),\n child1 = getChild(el, 0, options),\n child2 = getChild(el, 1, options),\n firstChildCSS = child1 && css(child1),\n secondChildCSS = child2 && css(child2),\n firstChildWidth = firstChildCSS && parseInt(firstChildCSS.marginLeft) + parseInt(firstChildCSS.marginRight) + getRect(child1).width,\n secondChildWidth = secondChildCSS && parseInt(secondChildCSS.marginLeft) + parseInt(secondChildCSS.marginRight) + getRect(child2).width;\n\n if (elCSS.display === 'flex') {\n return elCSS.flexDirection === 'column' || elCSS.flexDirection === 'column-reverse' ? 'vertical' : 'horizontal';\n }\n\n if (elCSS.display === 'grid') {\n return elCSS.gridTemplateColumns.split(' ').length <= 1 ? 'vertical' : 'horizontal';\n }\n\n if (child1 && firstChildCSS[\"float\"] && firstChildCSS[\"float\"] !== 'none') {\n var touchingSideChild2 = firstChildCSS[\"float\"] === 'left' ? 'left' : 'right';\n return child2 && (secondChildCSS.clear === 'both' || secondChildCSS.clear === touchingSideChild2) ? 'vertical' : 'horizontal';\n }\n\n return child1 && (firstChildCSS.display === 'block' || firstChildCSS.display === 'flex' || firstChildCSS.display === 'table' || firstChildCSS.display === 'grid' || firstChildWidth >= elWidth && elCSS[CSSFloatProperty] === 'none' || child2 && elCSS[CSSFloatProperty] === 'none' && firstChildWidth + secondChildWidth > elWidth) ? 'vertical' : 'horizontal';\n},\n _dragElInRowColumn = function _dragElInRowColumn(dragRect, targetRect, vertical) {\n var dragElS1Opp = vertical ? dragRect.left : dragRect.top,\n dragElS2Opp = vertical ? dragRect.right : dragRect.bottom,\n dragElOppLength = vertical ? dragRect.width : dragRect.height,\n targetS1Opp = vertical ? targetRect.left : targetRect.top,\n targetS2Opp = vertical ? targetRect.right : targetRect.bottom,\n targetOppLength = vertical ? targetRect.width : targetRect.height;\n return dragElS1Opp === targetS1Opp || dragElS2Opp === targetS2Opp || dragElS1Opp + dragElOppLength / 2 === targetS1Opp + targetOppLength / 2;\n},\n\n/**\n * Detects first nearest empty sortable to X and Y position using emptyInsertThreshold.\n * @param {Number} x X position\n * @param {Number} y Y position\n * @return {HTMLElement} Element of the first found nearest Sortable\n */\n_detectNearestEmptySortable = function _detectNearestEmptySortable(x, y) {\n var ret;\n sortables.some(function (sortable) {\n var threshold = sortable[expando].options.emptyInsertThreshold;\n if (!threshold || lastChild(sortable)) return;\n var rect = getRect(sortable),\n insideHorizontally = x >= rect.left - threshold && x <= rect.right + threshold,\n insideVertically = y >= rect.top - threshold && y <= rect.bottom + threshold;\n\n if (insideHorizontally && insideVertically) {\n return ret = sortable;\n }\n });\n return ret;\n},\n _prepareGroup = function _prepareGroup(options) {\n function toFn(value, pull) {\n return function (to, from, dragEl, evt) {\n var sameGroup = to.options.group.name && from.options.group.name && to.options.group.name === from.options.group.name;\n\n if (value == null && (pull || sameGroup)) {\n // Default pull value\n // Default pull and put value if same group\n return true;\n } else if (value == null || value === false) {\n return false;\n } else if (pull && value === 'clone') {\n return value;\n } else if (typeof value === 'function') {\n return toFn(value(to, from, dragEl, evt), pull)(to, from, dragEl, evt);\n } else {\n var otherGroup = (pull ? to : from).options.group.name;\n return value === true || typeof value === 'string' && value === otherGroup || value.join && value.indexOf(otherGroup) > -1;\n }\n };\n }\n\n var group = {};\n var originalGroup = options.group;\n\n if (!originalGroup || _typeof(originalGroup) != 'object') {\n originalGroup = {\n name: originalGroup\n };\n }\n\n group.name = originalGroup.name;\n group.checkPull = toFn(originalGroup.pull, true);\n group.checkPut = toFn(originalGroup.put);\n group.revertClone = originalGroup.revertClone;\n options.group = group;\n},\n _hideGhostForTarget = function _hideGhostForTarget() {\n if (!supportCssPointerEvents && ghostEl) {\n css(ghostEl, 'display', 'none');\n }\n},\n _unhideGhostForTarget = function _unhideGhostForTarget() {\n if (!supportCssPointerEvents && ghostEl) {\n css(ghostEl, 'display', '');\n }\n}; // #1184 fix - Prevent click event on fallback if dragged but item not changed position\n\n\nif (documentExists) {\n document.addEventListener('click', function (evt) {\n if (ignoreNextClick) {\n evt.preventDefault();\n evt.stopPropagation && evt.stopPropagation();\n evt.stopImmediatePropagation && evt.stopImmediatePropagation();\n ignoreNextClick = false;\n return false;\n }\n }, true);\n}\n\nvar nearestEmptyInsertDetectEvent = function nearestEmptyInsertDetectEvent(evt) {\n if (dragEl) {\n evt = evt.touches ? evt.touches[0] : evt;\n\n var nearest = _detectNearestEmptySortable(evt.clientX, evt.clientY);\n\n if (nearest) {\n // Create imitation event\n var event = {};\n\n for (var i in evt) {\n if (evt.hasOwnProperty(i)) {\n event[i] = evt[i];\n }\n }\n\n event.target = event.rootEl = nearest;\n event.preventDefault = void 0;\n event.stopPropagation = void 0;\n\n nearest[expando]._onDragOver(event);\n }\n }\n};\n\nvar _checkOutsideTargetEl = function _checkOutsideTargetEl(evt) {\n if (dragEl) {\n dragEl.parentNode[expando]._isOutsideThisEl(evt.target);\n }\n};\n/**\n * @class Sortable\n * @param {HTMLElement} el\n * @param {Object} [options]\n */\n\n\nfunction Sortable(el, options) {\n if (!(el && el.nodeType && el.nodeType === 1)) {\n throw \"Sortable: `el` must be an HTMLElement, not \".concat({}.toString.call(el));\n }\n\n this.el = el; // root element\n\n this.options = options = _extends({}, options); // Export instance\n\n el[expando] = this;\n var defaults = {\n group: null,\n sort: true,\n disabled: false,\n store: null,\n handle: null,\n draggable: /^[uo]l$/i.test(el.nodeName) ? '>li' : '>*',\n swapThreshold: 1,\n // percentage; 0 <= x <= 1\n invertSwap: false,\n // invert always\n invertedSwapThreshold: null,\n // will be set to same as swapThreshold if default\n removeCloneOnHide: true,\n direction: function direction() {\n return _detectDirection(el, this.options);\n },\n ghostClass: 'sortable-ghost',\n chosenClass: 'sortable-chosen',\n dragClass: 'sortable-drag',\n ignore: 'a, img',\n filter: null,\n preventOnFilter: true,\n animation: 0,\n easing: null,\n setData: function setData(dataTransfer, dragEl) {\n dataTransfer.setData('Text', dragEl.textContent);\n },\n dropBubble: false,\n dragoverBubble: false,\n dataIdAttr: 'data-id',\n delay: 0,\n delayOnTouchOnly: false,\n touchStartThreshold: (Number.parseInt ? Number : window).parseInt(window.devicePixelRatio, 10) || 1,\n forceFallback: false,\n fallbackClass: 'sortable-fallback',\n fallbackOnBody: false,\n fallbackTolerance: 0,\n fallbackOffset: {\n x: 0,\n y: 0\n },\n supportPointer: Sortable.supportPointer !== false && 'PointerEvent' in window && !Safari,\n emptyInsertThreshold: 5\n };\n PluginManager.initializePlugins(this, el, defaults); // Set default options\n\n for (var name in defaults) {\n !(name in options) && (options[name] = defaults[name]);\n }\n\n _prepareGroup(options); // Bind all private methods\n\n\n for (var fn in this) {\n if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {\n this[fn] = this[fn].bind(this);\n }\n } // Setup drag mode\n\n\n this.nativeDraggable = options.forceFallback ? false : supportDraggable;\n\n if (this.nativeDraggable) {\n // Touch start threshold cannot be greater than the native dragstart threshold\n this.options.touchStartThreshold = 1;\n } // Bind events\n\n\n if (options.supportPointer) {\n on(el, 'pointerdown', this._onTapStart);\n } else {\n on(el, 'mousedown', this._onTapStart);\n on(el, 'touchstart', this._onTapStart);\n }\n\n if (this.nativeDraggable) {\n on(el, 'dragover', this);\n on(el, 'dragenter', this);\n }\n\n sortables.push(this.el); // Restore sorting\n\n options.store && options.store.get && this.sort(options.store.get(this) || []); // Add animation state manager\n\n _extends(this, AnimationStateManager());\n}\n\nSortable.prototype =\n/** @lends Sortable.prototype */\n{\n constructor: Sortable,\n _isOutsideThisEl: function _isOutsideThisEl(target) {\n if (!this.el.contains(target) && target !== this.el) {\n lastTarget = null;\n }\n },\n _getDirection: function _getDirection(evt, target) {\n return typeof this.options.direction === 'function' ? this.options.direction.call(this, evt, target, dragEl) : this.options.direction;\n },\n _onTapStart: function _onTapStart(\n /** Event|TouchEvent */\n evt) {\n if (!evt.cancelable) return;\n\n var _this = this,\n el = this.el,\n options = this.options,\n preventOnFilter = options.preventOnFilter,\n type = evt.type,\n touch = evt.touches && evt.touches[0] || evt.pointerType && evt.pointerType === 'touch' && evt,\n target = (touch || evt).target,\n originalTarget = evt.target.shadowRoot && (evt.path && evt.path[0] || evt.composedPath && evt.composedPath()[0]) || target,\n filter = options.filter;\n\n _saveInputCheckedState(el); // Don't trigger start event when an element is been dragged, otherwise the evt.oldindex always wrong when set option.group.\n\n\n if (dragEl) {\n return;\n }\n\n if (/mousedown|pointerdown/.test(type) && evt.button !== 0 || options.disabled) {\n return; // only left button and enabled\n } // cancel dnd if original target is content editable\n\n\n if (originalTarget.isContentEditable) {\n return;\n } // Safari ignores further event handling after mousedown\n\n\n if (!this.nativeDraggable && Safari && target && target.tagName.toUpperCase() === 'SELECT') {\n return;\n }\n\n target = closest(target, options.draggable, el, false);\n\n if (target && target.animated) {\n return;\n }\n\n if (lastDownEl === target) {\n // Ignoring duplicate `down`\n return;\n } // Get the index of the dragged element within its parent\n\n\n oldIndex = index(target);\n oldDraggableIndex = index(target, options.draggable); // Check filter\n\n if (typeof filter === 'function') {\n if (filter.call(this, evt, target, this)) {\n _dispatchEvent({\n sortable: _this,\n rootEl: originalTarget,\n name: 'filter',\n targetEl: target,\n toEl: el,\n fromEl: el\n });\n\n pluginEvent('filter', _this, {\n evt: evt\n });\n preventOnFilter && evt.cancelable && evt.preventDefault();\n return; // cancel dnd\n }\n } else if (filter) {\n filter = filter.split(',').some(function (criteria) {\n criteria = closest(originalTarget, criteria.trim(), el, false);\n\n if (criteria) {\n _dispatchEvent({\n sortable: _this,\n rootEl: criteria,\n name: 'filter',\n targetEl: target,\n fromEl: el,\n toEl: el\n });\n\n pluginEvent('filter', _this, {\n evt: evt\n });\n return true;\n }\n });\n\n if (filter) {\n preventOnFilter && evt.cancelable && evt.preventDefault();\n return; // cancel dnd\n }\n }\n\n if (options.handle && !closest(originalTarget, options.handle, el, false)) {\n return;\n } // Prepare `dragstart`\n\n\n this._prepareDragStart(evt, touch, target);\n },\n _prepareDragStart: function _prepareDragStart(\n /** Event */\n evt,\n /** Touch */\n touch,\n /** HTMLElement */\n target) {\n var _this = this,\n el = _this.el,\n options = _this.options,\n ownerDocument = el.ownerDocument,\n dragStartFn;\n\n if (target && !dragEl && target.parentNode === el) {\n var dragRect = getRect(target);\n rootEl = el;\n dragEl = target;\n parentEl = dragEl.parentNode;\n nextEl = dragEl.nextSibling;\n lastDownEl = target;\n activeGroup = options.group;\n Sortable.dragged = dragEl;\n tapEvt = {\n target: dragEl,\n clientX: (touch || evt).clientX,\n clientY: (touch || evt).clientY\n };\n tapDistanceLeft = tapEvt.clientX - dragRect.left;\n tapDistanceTop = tapEvt.clientY - dragRect.top;\n this._lastX = (touch || evt).clientX;\n this._lastY = (touch || evt).clientY;\n dragEl.style['will-change'] = 'all';\n\n dragStartFn = function dragStartFn() {\n pluginEvent('delayEnded', _this, {\n evt: evt\n });\n\n if (Sortable.eventCanceled) {\n _this._onDrop();\n\n return;\n } // Delayed drag has been triggered\n // we can re-enable the events: touchmove/mousemove\n\n\n _this._disableDelayedDragEvents();\n\n if (!FireFox && _this.nativeDraggable) {\n dragEl.draggable = true;\n } // Bind the events: dragstart/dragend\n\n\n _this._triggerDragStart(evt, touch); // Drag start event\n\n\n _dispatchEvent({\n sortable: _this,\n name: 'choose',\n originalEvent: evt\n }); // Chosen item\n\n\n toggleClass(dragEl, options.chosenClass, true);\n }; // Disable \"draggable\"\n\n\n options.ignore.split(',').forEach(function (criteria) {\n find(dragEl, criteria.trim(), _disableDraggable);\n });\n on(ownerDocument, 'dragover', nearestEmptyInsertDetectEvent);\n on(ownerDocument, 'mousemove', nearestEmptyInsertDetectEvent);\n on(ownerDocument, 'touchmove', nearestEmptyInsertDetectEvent);\n on(ownerDocument, 'mouseup', _this._onDrop);\n on(ownerDocument, 'touchend', _this._onDrop);\n on(ownerDocument, 'touchcancel', _this._onDrop); // Make dragEl draggable (must be before delay for FireFox)\n\n if (FireFox && this.nativeDraggable) {\n this.options.touchStartThreshold = 4;\n dragEl.draggable = true;\n }\n\n pluginEvent('delayStart', this, {\n evt: evt\n }); // Delay is impossible for native DnD in Edge or IE\n\n if (options.delay && (!options.delayOnTouchOnly || touch) && (!this.nativeDraggable || !(Edge || IE11OrLess))) {\n if (Sortable.eventCanceled) {\n this._onDrop();\n\n return;\n } // If the user moves the pointer or let go the click or touch\n // before the delay has been reached:\n // disable the delayed drag\n\n\n on(ownerDocument, 'mouseup', _this._disableDelayedDrag);\n on(ownerDocument, 'touchend', _this._disableDelayedDrag);\n on(ownerDocument, 'touchcancel', _this._disableDelayedDrag);\n on(ownerDocument, 'mousemove', _this._delayedDragTouchMoveHandler);\n on(ownerDocument, 'touchmove', _this._delayedDragTouchMoveHandler);\n options.supportPointer && on(ownerDocument, 'pointermove', _this._delayedDragTouchMoveHandler);\n _this._dragStartTimer = setTimeout(dragStartFn, options.delay);\n } else {\n dragStartFn();\n }\n }\n },\n _delayedDragTouchMoveHandler: function _delayedDragTouchMoveHandler(\n /** TouchEvent|PointerEvent **/\n e) {\n var touch = e.touches ? e.touches[0] : e;\n\n if (Math.max(Math.abs(touch.clientX - this._lastX), Math.abs(touch.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1))) {\n this._disableDelayedDrag();\n }\n },\n _disableDelayedDrag: function _disableDelayedDrag() {\n dragEl && _disableDraggable(dragEl);\n clearTimeout(this._dragStartTimer);\n\n this._disableDelayedDragEvents();\n },\n _disableDelayedDragEvents: function _disableDelayedDragEvents() {\n var ownerDocument = this.el.ownerDocument;\n off(ownerDocument, 'mouseup', this._disableDelayedDrag);\n off(ownerDocument, 'touchend', this._disableDelayedDrag);\n off(ownerDocument, 'touchcancel', this._disableDelayedDrag);\n off(ownerDocument, 'mousemove', this._delayedDragTouchMoveHandler);\n off(ownerDocument, 'touchmove', this._delayedDragTouchMoveHandler);\n off(ownerDocument, 'pointermove', this._delayedDragTouchMoveHandler);\n },\n _triggerDragStart: function _triggerDragStart(\n /** Event */\n evt,\n /** Touch */\n touch) {\n touch = touch || evt.pointerType == 'touch' && evt;\n\n if (!this.nativeDraggable || touch) {\n if (this.options.supportPointer) {\n on(document, 'pointermove', this._onTouchMove);\n } else if (touch) {\n on(document, 'touchmove', this._onTouchMove);\n } else {\n on(document, 'mousemove', this._onTouchMove);\n }\n } else {\n on(dragEl, 'dragend', this);\n on(rootEl, 'dragstart', this._onDragStart);\n }\n\n try {\n if (document.selection) {\n // Timeout neccessary for IE9\n _nextTick(function () {\n document.selection.empty();\n });\n } else {\n window.getSelection().removeAllRanges();\n }\n } catch (err) {}\n },\n _dragStarted: function _dragStarted(fallback, evt) {\n\n awaitingDragStarted = false;\n\n if (rootEl && dragEl) {\n pluginEvent('dragStarted', this, {\n evt: evt\n });\n\n if (this.nativeDraggable) {\n on(document, 'dragover', _checkOutsideTargetEl);\n }\n\n var options = this.options; // Apply effect\n\n !fallback && toggleClass(dragEl, options.dragClass, false);\n toggleClass(dragEl, options.ghostClass, true);\n Sortable.active = this;\n fallback && this._appendGhost(); // Drag start event\n\n _dispatchEvent({\n sortable: this,\n name: 'start',\n originalEvent: evt\n });\n } else {\n this._nulling();\n }\n },\n _emulateDragOver: function _emulateDragOver() {\n if (touchEvt) {\n this._lastX = touchEvt.clientX;\n this._lastY = touchEvt.clientY;\n\n _hideGhostForTarget();\n\n var target = document.elementFromPoint(touchEvt.clientX, touchEvt.clientY);\n var parent = target;\n\n while (target && target.shadowRoot) {\n target = target.shadowRoot.elementFromPoint(touchEvt.clientX, touchEvt.clientY);\n if (target === parent) break;\n parent = target;\n }\n\n dragEl.parentNode[expando]._isOutsideThisEl(target);\n\n if (parent) {\n do {\n if (parent[expando]) {\n var inserted = void 0;\n inserted = parent[expando]._onDragOver({\n clientX: touchEvt.clientX,\n clientY: touchEvt.clientY,\n target: target,\n rootEl: parent\n });\n\n if (inserted && !this.options.dragoverBubble) {\n break;\n }\n }\n\n target = parent; // store last element\n }\n /* jshint boss:true */\n while (parent = parent.parentNode);\n }\n\n _unhideGhostForTarget();\n }\n },\n _onTouchMove: function _onTouchMove(\n /**TouchEvent*/\n evt) {\n if (tapEvt) {\n var options = this.options,\n fallbackTolerance = options.fallbackTolerance,\n fallbackOffset = options.fallbackOffset,\n touch = evt.touches ? evt.touches[0] : evt,\n ghostMatrix = ghostEl && matrix(ghostEl, true),\n scaleX = ghostEl && ghostMatrix && ghostMatrix.a,\n scaleY = ghostEl && ghostMatrix && ghostMatrix.d,\n relativeScrollOffset = PositionGhostAbsolutely && ghostRelativeParent && getRelativeScrollOffset(ghostRelativeParent),\n dx = (touch.clientX - tapEvt.clientX + fallbackOffset.x) / (scaleX || 1) + (relativeScrollOffset ? relativeScrollOffset[0] - ghostRelativeParentInitialScroll[0] : 0) / (scaleX || 1),\n dy = (touch.clientY - tapEvt.clientY + fallbackOffset.y) / (scaleY || 1) + (relativeScrollOffset ? relativeScrollOffset[1] - ghostRelativeParentInitialScroll[1] : 0) / (scaleY || 1); // only set the status to dragging, when we are actually dragging\n\n if (!Sortable.active && !awaitingDragStarted) {\n if (fallbackTolerance && Math.max(Math.abs(touch.clientX - this._lastX), Math.abs(touch.clientY - this._lastY)) < fallbackTolerance) {\n return;\n }\n\n this._onDragStart(evt, true);\n }\n\n if (ghostEl) {\n if (ghostMatrix) {\n ghostMatrix.e += dx - (lastDx || 0);\n ghostMatrix.f += dy - (lastDy || 0);\n } else {\n ghostMatrix = {\n a: 1,\n b: 0,\n c: 0,\n d: 1,\n e: dx,\n f: dy\n };\n }\n\n var cssMatrix = \"matrix(\".concat(ghostMatrix.a, \",\").concat(ghostMatrix.b, \",\").concat(ghostMatrix.c, \",\").concat(ghostMatrix.d, \",\").concat(ghostMatrix.e, \",\").concat(ghostMatrix.f, \")\");\n css(ghostEl, 'webkitTransform', cssMatrix);\n css(ghostEl, 'mozTransform', cssMatrix);\n css(ghostEl, 'msTransform', cssMatrix);\n css(ghostEl, 'transform', cssMatrix);\n lastDx = dx;\n lastDy = dy;\n touchEvt = touch;\n }\n\n evt.cancelable && evt.preventDefault();\n }\n },\n _appendGhost: function _appendGhost() {\n // Bug if using scale(): https://stackoverflow.com/questions/2637058\n // Not being adjusted for\n if (!ghostEl) {\n var container = this.options.fallbackOnBody ? document.body : rootEl,\n rect = getRect(dragEl, true, PositionGhostAbsolutely, true, container),\n options = this.options; // Position absolutely\n\n if (PositionGhostAbsolutely) {\n // Get relatively positioned parent\n ghostRelativeParent = container;\n\n while (css(ghostRelativeParent, 'position') === 'static' && css(ghostRelativeParent, 'transform') === 'none' && ghostRelativeParent !== document) {\n ghostRelativeParent = ghostRelativeParent.parentNode;\n }\n\n if (ghostRelativeParent !== document.body && ghostRelativeParent !== document.documentElement) {\n if (ghostRelativeParent === document) ghostRelativeParent = getWindowScrollingElement();\n rect.top += ghostRelativeParent.scrollTop;\n rect.left += ghostRelativeParent.scrollLeft;\n } else {\n ghostRelativeParent = getWindowScrollingElement();\n }\n\n ghostRelativeParentInitialScroll = getRelativeScrollOffset(ghostRelativeParent);\n }\n\n ghostEl = dragEl.cloneNode(true);\n toggleClass(ghostEl, options.ghostClass, false);\n toggleClass(ghostEl, options.fallbackClass, true);\n toggleClass(ghostEl, options.dragClass, true);\n css(ghostEl, 'transition', '');\n css(ghostEl, 'transform', '');\n css(ghostEl, 'box-sizing', 'border-box');\n css(ghostEl, 'margin', 0);\n css(ghostEl, 'top', rect.top);\n css(ghostEl, 'left', rect.left);\n css(ghostEl, 'width', rect.width);\n css(ghostEl, 'height', rect.height);\n css(ghostEl, 'opacity', '0.8');\n css(ghostEl, 'position', PositionGhostAbsolutely ? 'absolute' : 'fixed');\n css(ghostEl, 'zIndex', '100000');\n css(ghostEl, 'pointerEvents', 'none');\n Sortable.ghost = ghostEl;\n container.appendChild(ghostEl); // Set transform-origin\n\n css(ghostEl, 'transform-origin', tapDistanceLeft / parseInt(ghostEl.style.width) * 100 + '% ' + tapDistanceTop / parseInt(ghostEl.style.height) * 100 + '%');\n }\n },\n _onDragStart: function _onDragStart(\n /**Event*/\n evt,\n /**boolean*/\n fallback) {\n var _this = this;\n\n var dataTransfer = evt.dataTransfer;\n var options = _this.options;\n pluginEvent('dragStart', this, {\n evt: evt\n });\n\n if (Sortable.eventCanceled) {\n this._onDrop();\n\n return;\n }\n\n pluginEvent('setupClone', this);\n\n if (!Sortable.eventCanceled) {\n cloneEl = clone(dragEl);\n cloneEl.draggable = false;\n cloneEl.style['will-change'] = '';\n\n this._hideClone();\n\n toggleClass(cloneEl, this.options.chosenClass, false);\n Sortable.clone = cloneEl;\n } // #1143: IFrame support workaround\n\n\n _this.cloneId = _nextTick(function () {\n pluginEvent('clone', _this);\n if (Sortable.eventCanceled) return;\n\n if (!_this.options.removeCloneOnHide) {\n rootEl.insertBefore(cloneEl, dragEl);\n }\n\n _this._hideClone();\n\n _dispatchEvent({\n sortable: _this,\n name: 'clone'\n });\n });\n !fallback && toggleClass(dragEl, options.dragClass, true); // Set proper drop events\n\n if (fallback) {\n ignoreNextClick = true;\n _this._loopId = setInterval(_this._emulateDragOver, 50);\n } else {\n // Undo what was set in _prepareDragStart before drag started\n off(document, 'mouseup', _this._onDrop);\n off(document, 'touchend', _this._onDrop);\n off(document, 'touchcancel', _this._onDrop);\n\n if (dataTransfer) {\n dataTransfer.effectAllowed = 'move';\n options.setData && options.setData.call(_this, dataTransfer, dragEl);\n }\n\n on(document, 'drop', _this); // #1276 fix:\n\n css(dragEl, 'transform', 'translateZ(0)');\n }\n\n awaitingDragStarted = true;\n _this._dragStartId = _nextTick(_this._dragStarted.bind(_this, fallback, evt));\n on(document, 'selectstart', _this);\n moved = true;\n\n if (Safari) {\n css(document.body, 'user-select', 'none');\n }\n },\n // Returns true - if no further action is needed (either inserted or another condition)\n _onDragOver: function _onDragOver(\n /**Event*/\n evt) {\n var el = this.el,\n target = evt.target,\n dragRect,\n targetRect,\n revert,\n options = this.options,\n group = options.group,\n activeSortable = Sortable.active,\n isOwner = activeGroup === group,\n canSort = options.sort,\n fromSortable = putSortable || activeSortable,\n vertical,\n _this = this,\n completedFired = false;\n\n if (_silent) return;\n\n function dragOverEvent(name, extra) {\n pluginEvent(name, _this, _objectSpread2({\n evt: evt,\n isOwner: isOwner,\n axis: vertical ? 'vertical' : 'horizontal',\n revert: revert,\n dragRect: dragRect,\n targetRect: targetRect,\n canSort: canSort,\n fromSortable: fromSortable,\n target: target,\n completed: completed,\n onMove: function onMove(target, after) {\n return _onMove(rootEl, el, dragEl, dragRect, target, getRect(target), evt, after);\n },\n changed: changed\n }, extra));\n } // Capture animation state\n\n\n function capture() {\n dragOverEvent('dragOverAnimationCapture');\n\n _this.captureAnimationState();\n\n if (_this !== fromSortable) {\n fromSortable.captureAnimationState();\n }\n } // Return invocation when dragEl is inserted (or completed)\n\n\n function completed(insertion) {\n dragOverEvent('dragOverCompleted', {\n insertion: insertion\n });\n\n if (insertion) {\n // Clones must be hidden before folding animation to capture dragRectAbsolute properly\n if (isOwner) {\n activeSortable._hideClone();\n } else {\n activeSortable._showClone(_this);\n }\n\n if (_this !== fromSortable) {\n // Set ghost class to new sortable's ghost class\n toggleClass(dragEl, putSortable ? putSortable.options.ghostClass : activeSortable.options.ghostClass, false);\n toggleClass(dragEl, options.ghostClass, true);\n }\n\n if (putSortable !== _this && _this !== Sortable.active) {\n putSortable = _this;\n } else if (_this === Sortable.active && putSortable) {\n putSortable = null;\n } // Animation\n\n\n if (fromSortable === _this) {\n _this._ignoreWhileAnimating = target;\n }\n\n _this.animateAll(function () {\n dragOverEvent('dragOverAnimationComplete');\n _this._ignoreWhileAnimating = null;\n });\n\n if (_this !== fromSortable) {\n fromSortable.animateAll();\n fromSortable._ignoreWhileAnimating = null;\n }\n } // Null lastTarget if it is not inside a previously swapped element\n\n\n if (target === dragEl && !dragEl.animated || target === el && !target.animated) {\n lastTarget = null;\n } // no bubbling and not fallback\n\n\n if (!options.dragoverBubble && !evt.rootEl && target !== document) {\n dragEl.parentNode[expando]._isOutsideThisEl(evt.target); // Do not detect for empty insert if already inserted\n\n\n !insertion && nearestEmptyInsertDetectEvent(evt);\n }\n\n !options.dragoverBubble && evt.stopPropagation && evt.stopPropagation();\n return completedFired = true;\n } // Call when dragEl has been inserted\n\n\n function changed() {\n newIndex = index(dragEl);\n newDraggableIndex = index(dragEl, options.draggable);\n\n _dispatchEvent({\n sortable: _this,\n name: 'change',\n toEl: el,\n newIndex: newIndex,\n newDraggableIndex: newDraggableIndex,\n originalEvent: evt\n });\n }\n\n if (evt.preventDefault !== void 0) {\n evt.cancelable && evt.preventDefault();\n }\n\n target = closest(target, options.draggable, el, true);\n dragOverEvent('dragOver');\n if (Sortable.eventCanceled) return completedFired;\n\n if (dragEl.contains(evt.target) || target.animated && target.animatingX && target.animatingY || _this._ignoreWhileAnimating === target) {\n return completed(false);\n }\n\n ignoreNextClick = false;\n\n if (activeSortable && !options.disabled && (isOwner ? canSort || (revert = parentEl !== rootEl) // Reverting item into the original list\n : putSortable === this || (this.lastPutMode = activeGroup.checkPull(this, activeSortable, dragEl, evt)) && group.checkPut(this, activeSortable, dragEl, evt))) {\n vertical = this._getDirection(evt, target) === 'vertical';\n dragRect = getRect(dragEl);\n dragOverEvent('dragOverValid');\n if (Sortable.eventCanceled) return completedFired;\n\n if (revert) {\n parentEl = rootEl; // actualization\n\n capture();\n\n this._hideClone();\n\n dragOverEvent('revert');\n\n if (!Sortable.eventCanceled) {\n if (nextEl) {\n rootEl.insertBefore(dragEl, nextEl);\n } else {\n rootEl.appendChild(dragEl);\n }\n }\n\n return completed(true);\n }\n\n var elLastChild = lastChild(el, options.draggable);\n\n if (!elLastChild || _ghostIsLast(evt, vertical, this) && !elLastChild.animated) {\n // Insert to end of list\n // If already at end of list: Do not insert\n if (elLastChild === dragEl) {\n return completed(false);\n } // if there is a last element, it is the target\n\n\n if (elLastChild && el === evt.target) {\n target = elLastChild;\n }\n\n if (target) {\n targetRect = getRect(target);\n }\n\n if (_onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, !!target) !== false) {\n capture();\n el.appendChild(dragEl);\n parentEl = el; // actualization\n\n changed();\n return completed(true);\n }\n } else if (elLastChild && _ghostIsFirst(evt, vertical, this)) {\n // Insert to start of list\n var firstChild = getChild(el, 0, options, true);\n\n if (firstChild === dragEl) {\n return completed(false);\n }\n\n target = firstChild;\n targetRect = getRect(target);\n\n if (_onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, false) !== false) {\n capture();\n el.insertBefore(dragEl, firstChild);\n parentEl = el; // actualization\n\n changed();\n return completed(true);\n }\n } else if (target.parentNode === el) {\n targetRect = getRect(target);\n var direction = 0,\n targetBeforeFirstSwap,\n differentLevel = dragEl.parentNode !== el,\n differentRowCol = !_dragElInRowColumn(dragEl.animated && dragEl.toRect || dragRect, target.animated && target.toRect || targetRect, vertical),\n side1 = vertical ? 'top' : 'left',\n scrolledPastTop = isScrolledPast(target, 'top', 'top') || isScrolledPast(dragEl, 'top', 'top'),\n scrollBefore = scrolledPastTop ? scrolledPastTop.scrollTop : void 0;\n\n if (lastTarget !== target) {\n targetBeforeFirstSwap = targetRect[side1];\n pastFirstInvertThresh = false;\n isCircumstantialInvert = !differentRowCol && options.invertSwap || differentLevel;\n }\n\n direction = _getSwapDirection(evt, target, targetRect, vertical, differentRowCol ? 1 : options.swapThreshold, options.invertedSwapThreshold == null ? options.swapThreshold : options.invertedSwapThreshold, isCircumstantialInvert, lastTarget === target);\n var sibling;\n\n if (direction !== 0) {\n // Check if target is beside dragEl in respective direction (ignoring hidden elements)\n var dragIndex = index(dragEl);\n\n do {\n dragIndex -= direction;\n sibling = parentEl.children[dragIndex];\n } while (sibling && (css(sibling, 'display') === 'none' || sibling === ghostEl));\n } // If dragEl is already beside target: Do not insert\n\n\n if (direction === 0 || sibling === target) {\n return completed(false);\n }\n\n lastTarget = target;\n lastDirection = direction;\n var nextSibling = target.nextElementSibling,\n after = false;\n after = direction === 1;\n\n var moveVector = _onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, after);\n\n if (moveVector !== false) {\n if (moveVector === 1 || moveVector === -1) {\n after = moveVector === 1;\n }\n\n _silent = true;\n setTimeout(_unsilent, 30);\n capture();\n\n if (after && !nextSibling) {\n el.appendChild(dragEl);\n } else {\n target.parentNode.insertBefore(dragEl, after ? nextSibling : target);\n } // Undo chrome's scroll adjustment (has no effect on other browsers)\n\n\n if (scrolledPastTop) {\n scrollBy(scrolledPastTop, 0, scrollBefore - scrolledPastTop.scrollTop);\n }\n\n parentEl = dragEl.parentNode; // actualization\n // must be done before animation\n\n if (targetBeforeFirstSwap !== undefined && !isCircumstantialInvert) {\n targetMoveDistance = Math.abs(targetBeforeFirstSwap - getRect(target)[side1]);\n }\n\n changed();\n return completed(true);\n }\n }\n\n if (el.contains(dragEl)) {\n return completed(false);\n }\n }\n\n return false;\n },\n _ignoreWhileAnimating: null,\n _offMoveEvents: function _offMoveEvents() {\n off(document, 'mousemove', this._onTouchMove);\n off(document, 'touchmove', this._onTouchMove);\n off(document, 'pointermove', this._onTouchMove);\n off(document, 'dragover', nearestEmptyInsertDetectEvent);\n off(document, 'mousemove', nearestEmptyInsertDetectEvent);\n off(document, 'touchmove', nearestEmptyInsertDetectEvent);\n },\n _offUpEvents: function _offUpEvents() {\n var ownerDocument = this.el.ownerDocument;\n off(ownerDocument, 'mouseup', this._onDrop);\n off(ownerDocument, 'touchend', this._onDrop);\n off(ownerDocument, 'pointerup', this._onDrop);\n off(ownerDocument, 'touchcancel', this._onDrop);\n off(document, 'selectstart', this);\n },\n _onDrop: function _onDrop(\n /**Event*/\n evt) {\n var el = this.el,\n options = this.options; // Get the index of the dragged element within its parent\n\n newIndex = index(dragEl);\n newDraggableIndex = index(dragEl, options.draggable);\n pluginEvent('drop', this, {\n evt: evt\n });\n parentEl = dragEl && dragEl.parentNode; // Get again after plugin event\n\n newIndex = index(dragEl);\n newDraggableIndex = index(dragEl, options.draggable);\n\n if (Sortable.eventCanceled) {\n this._nulling();\n\n return;\n }\n\n awaitingDragStarted = false;\n isCircumstantialInvert = false;\n pastFirstInvertThresh = false;\n clearInterval(this._loopId);\n clearTimeout(this._dragStartTimer);\n\n _cancelNextTick(this.cloneId);\n\n _cancelNextTick(this._dragStartId); // Unbind events\n\n\n if (this.nativeDraggable) {\n off(document, 'drop', this);\n off(el, 'dragstart', this._onDragStart);\n }\n\n this._offMoveEvents();\n\n this._offUpEvents();\n\n if (Safari) {\n css(document.body, 'user-select', '');\n }\n\n css(dragEl, 'transform', '');\n\n if (evt) {\n if (moved) {\n evt.cancelable && evt.preventDefault();\n !options.dropBubble && evt.stopPropagation();\n }\n\n ghostEl && ghostEl.parentNode && ghostEl.parentNode.removeChild(ghostEl);\n\n if (rootEl === parentEl || putSortable && putSortable.lastPutMode !== 'clone') {\n // Remove clone(s)\n cloneEl && cloneEl.parentNode && cloneEl.parentNode.removeChild(cloneEl);\n }\n\n if (dragEl) {\n if (this.nativeDraggable) {\n off(dragEl, 'dragend', this);\n }\n\n _disableDraggable(dragEl);\n\n dragEl.style['will-change'] = ''; // Remove classes\n // ghostClass is added in dragStarted\n\n if (moved && !awaitingDragStarted) {\n toggleClass(dragEl, putSortable ? putSortable.options.ghostClass : this.options.ghostClass, false);\n }\n\n toggleClass(dragEl, this.options.chosenClass, false); // Drag stop event\n\n _dispatchEvent({\n sortable: this,\n name: 'unchoose',\n toEl: parentEl,\n newIndex: null,\n newDraggableIndex: null,\n originalEvent: evt\n });\n\n if (rootEl !== parentEl) {\n if (newIndex >= 0) {\n // Add event\n _dispatchEvent({\n rootEl: parentEl,\n name: 'add',\n toEl: parentEl,\n fromEl: rootEl,\n originalEvent: evt\n }); // Remove event\n\n\n _dispatchEvent({\n sortable: this,\n name: 'remove',\n toEl: parentEl,\n originalEvent: evt\n }); // drag from one list and drop into another\n\n\n _dispatchEvent({\n rootEl: parentEl,\n name: 'sort',\n toEl: parentEl,\n fromEl: rootEl,\n originalEvent: evt\n });\n\n _dispatchEvent({\n sortable: this,\n name: 'sort',\n toEl: parentEl,\n originalEvent: evt\n });\n }\n\n putSortable && putSortable.save();\n } else {\n if (newIndex !== oldIndex) {\n if (newIndex >= 0) {\n // drag & drop within the same list\n _dispatchEvent({\n sortable: this,\n name: 'update',\n toEl: parentEl,\n originalEvent: evt\n });\n\n _dispatchEvent({\n sortable: this,\n name: 'sort',\n toEl: parentEl,\n originalEvent: evt\n });\n }\n }\n }\n\n if (Sortable.active) {\n /* jshint eqnull:true */\n if (newIndex == null || newIndex === -1) {\n newIndex = oldIndex;\n newDraggableIndex = oldDraggableIndex;\n }\n\n _dispatchEvent({\n sortable: this,\n name: 'end',\n toEl: parentEl,\n originalEvent: evt\n }); // Save sorting\n\n\n this.save();\n }\n }\n }\n\n this._nulling();\n },\n _nulling: function _nulling() {\n pluginEvent('nulling', this);\n rootEl = dragEl = parentEl = ghostEl = nextEl = cloneEl = lastDownEl = cloneHidden = tapEvt = touchEvt = moved = newIndex = newDraggableIndex = oldIndex = oldDraggableIndex = lastTarget = lastDirection = putSortable = activeGroup = Sortable.dragged = Sortable.ghost = Sortable.clone = Sortable.active = null;\n savedInputChecked.forEach(function (el) {\n el.checked = true;\n });\n savedInputChecked.length = lastDx = lastDy = 0;\n },\n handleEvent: function handleEvent(\n /**Event*/\n evt) {\n switch (evt.type) {\n case 'drop':\n case 'dragend':\n this._onDrop(evt);\n\n break;\n\n case 'dragenter':\n case 'dragover':\n if (dragEl) {\n this._onDragOver(evt);\n\n _globalDragOver(evt);\n }\n\n break;\n\n case 'selectstart':\n evt.preventDefault();\n break;\n }\n },\n\n /**\n * Serializes the item into an array of string.\n * @returns {String[]}\n */\n toArray: function toArray() {\n var order = [],\n el,\n children = this.el.children,\n i = 0,\n n = children.length,\n options = this.options;\n\n for (; i < n; i++) {\n el = children[i];\n\n if (closest(el, options.draggable, this.el, false)) {\n order.push(el.getAttribute(options.dataIdAttr) || _generateId(el));\n }\n }\n\n return order;\n },\n\n /**\n * Sorts the elements according to the array.\n * @param {String[]} order order of the items\n */\n sort: function sort(order, useAnimation) {\n var items = {},\n rootEl = this.el;\n this.toArray().forEach(function (id, i) {\n var el = rootEl.children[i];\n\n if (closest(el, this.options.draggable, rootEl, false)) {\n items[id] = el;\n }\n }, this);\n useAnimation && this.captureAnimationState();\n order.forEach(function (id) {\n if (items[id]) {\n rootEl.removeChild(items[id]);\n rootEl.appendChild(items[id]);\n }\n });\n useAnimation && this.animateAll();\n },\n\n /**\n * Save the current sorting\n */\n save: function save() {\n var store = this.options.store;\n store && store.set && store.set(this);\n },\n\n /**\n * For each element in the set, get the first element that matches the selector by testing the element itself and traversing up through its ancestors in the DOM tree.\n * @param {HTMLElement} el\n * @param {String} [selector] default: `options.draggable`\n * @returns {HTMLElement|null}\n */\n closest: function closest$1(el, selector) {\n return closest(el, selector || this.options.draggable, this.el, false);\n },\n\n /**\n * Set/get option\n * @param {string} name\n * @param {*} [value]\n * @returns {*}\n */\n option: function option(name, value) {\n var options = this.options;\n\n if (value === void 0) {\n return options[name];\n } else {\n var modifiedValue = PluginManager.modifyOption(this, name, value);\n\n if (typeof modifiedValue !== 'undefined') {\n options[name] = modifiedValue;\n } else {\n options[name] = value;\n }\n\n if (name === 'group') {\n _prepareGroup(options);\n }\n }\n },\n\n /**\n * Destroy\n */\n destroy: function destroy() {\n pluginEvent('destroy', this);\n var el = this.el;\n el[expando] = null;\n off(el, 'mousedown', this._onTapStart);\n off(el, 'touchstart', this._onTapStart);\n off(el, 'pointerdown', this._onTapStart);\n\n if (this.nativeDraggable) {\n off(el, 'dragover', this);\n off(el, 'dragenter', this);\n } // Remove draggable attributes\n\n\n Array.prototype.forEach.call(el.querySelectorAll('[draggable]'), function (el) {\n el.removeAttribute('draggable');\n });\n\n this._onDrop();\n\n this._disableDelayedDragEvents();\n\n sortables.splice(sortables.indexOf(this.el), 1);\n this.el = el = null;\n },\n _hideClone: function _hideClone() {\n if (!cloneHidden) {\n pluginEvent('hideClone', this);\n if (Sortable.eventCanceled) return;\n css(cloneEl, 'display', 'none');\n\n if (this.options.removeCloneOnHide && cloneEl.parentNode) {\n cloneEl.parentNode.removeChild(cloneEl);\n }\n\n cloneHidden = true;\n }\n },\n _showClone: function _showClone(putSortable) {\n if (putSortable.lastPutMode !== 'clone') {\n this._hideClone();\n\n return;\n }\n\n if (cloneHidden) {\n pluginEvent('showClone', this);\n if (Sortable.eventCanceled) return; // show clone at dragEl or original position\n\n if (dragEl.parentNode == rootEl && !this.options.group.revertClone) {\n rootEl.insertBefore(cloneEl, dragEl);\n } else if (nextEl) {\n rootEl.insertBefore(cloneEl, nextEl);\n } else {\n rootEl.appendChild(cloneEl);\n }\n\n if (this.options.group.revertClone) {\n this.animate(dragEl, cloneEl);\n }\n\n css(cloneEl, 'display', '');\n cloneHidden = false;\n }\n }\n};\n\nfunction _globalDragOver(\n/**Event*/\nevt) {\n if (evt.dataTransfer) {\n evt.dataTransfer.dropEffect = 'move';\n }\n\n evt.cancelable && evt.preventDefault();\n}\n\nfunction _onMove(fromEl, toEl, dragEl, dragRect, targetEl, targetRect, originalEvent, willInsertAfter) {\n var evt,\n sortable = fromEl[expando],\n onMoveFn = sortable.options.onMove,\n retVal; // Support for new CustomEvent feature\n\n if (window.CustomEvent && !IE11OrLess && !Edge) {\n evt = new CustomEvent('move', {\n bubbles: true,\n cancelable: true\n });\n } else {\n evt = document.createEvent('Event');\n evt.initEvent('move', true, true);\n }\n\n evt.to = toEl;\n evt.from = fromEl;\n evt.dragged = dragEl;\n evt.draggedRect = dragRect;\n evt.related = targetEl || toEl;\n evt.relatedRect = targetRect || getRect(toEl);\n evt.willInsertAfter = willInsertAfter;\n evt.originalEvent = originalEvent;\n fromEl.dispatchEvent(evt);\n\n if (onMoveFn) {\n retVal = onMoveFn.call(sortable, evt, originalEvent);\n }\n\n return retVal;\n}\n\nfunction _disableDraggable(el) {\n el.draggable = false;\n}\n\nfunction _unsilent() {\n _silent = false;\n}\n\nfunction _ghostIsFirst(evt, vertical, sortable) {\n var rect = getRect(getChild(sortable.el, 0, sortable.options, true));\n var spacer = 10;\n return vertical ? evt.clientX < rect.left - spacer || evt.clientY < rect.top && evt.clientX < rect.right : evt.clientY < rect.top - spacer || evt.clientY < rect.bottom && evt.clientX < rect.left;\n}\n\nfunction _ghostIsLast(evt, vertical, sortable) {\n var rect = getRect(lastChild(sortable.el, sortable.options.draggable));\n var spacer = 10;\n return vertical ? evt.clientX > rect.right + spacer || evt.clientX <= rect.right && evt.clientY > rect.bottom && evt.clientX >= rect.left : evt.clientX > rect.right && evt.clientY > rect.top || evt.clientX <= rect.right && evt.clientY > rect.bottom + spacer;\n}\n\nfunction _getSwapDirection(evt, target, targetRect, vertical, swapThreshold, invertedSwapThreshold, invertSwap, isLastTarget) {\n var mouseOnAxis = vertical ? evt.clientY : evt.clientX,\n targetLength = vertical ? targetRect.height : targetRect.width,\n targetS1 = vertical ? targetRect.top : targetRect.left,\n targetS2 = vertical ? targetRect.bottom : targetRect.right,\n invert = false;\n\n if (!invertSwap) {\n // Never invert or create dragEl shadow when target movemenet causes mouse to move past the end of regular swapThreshold\n if (isLastTarget && targetMoveDistance < targetLength * swapThreshold) {\n // multiplied only by swapThreshold because mouse will already be inside target by (1 - threshold) * targetLength / 2\n // check if past first invert threshold on side opposite of lastDirection\n if (!pastFirstInvertThresh && (lastDirection === 1 ? mouseOnAxis > targetS1 + targetLength * invertedSwapThreshold / 2 : mouseOnAxis < targetS2 - targetLength * invertedSwapThreshold / 2)) {\n // past first invert threshold, do not restrict inverted threshold to dragEl shadow\n pastFirstInvertThresh = true;\n }\n\n if (!pastFirstInvertThresh) {\n // dragEl shadow (target move distance shadow)\n if (lastDirection === 1 ? mouseOnAxis < targetS1 + targetMoveDistance // over dragEl shadow\n : mouseOnAxis > targetS2 - targetMoveDistance) {\n return -lastDirection;\n }\n } else {\n invert = true;\n }\n } else {\n // Regular\n if (mouseOnAxis > targetS1 + targetLength * (1 - swapThreshold) / 2 && mouseOnAxis < targetS2 - targetLength * (1 - swapThreshold) / 2) {\n return _getInsertDirection(target);\n }\n }\n }\n\n invert = invert || invertSwap;\n\n if (invert) {\n // Invert of regular\n if (mouseOnAxis < targetS1 + targetLength * invertedSwapThreshold / 2 || mouseOnAxis > targetS2 - targetLength * invertedSwapThreshold / 2) {\n return mouseOnAxis > targetS1 + targetLength / 2 ? 1 : -1;\n }\n }\n\n return 0;\n}\n/**\n * Gets the direction dragEl must be swapped relative to target in order to make it\n * seem that dragEl has been \"inserted\" into that element's position\n * @param {HTMLElement} target The target whose position dragEl is being inserted at\n * @return {Number} Direction dragEl must be swapped\n */\n\n\nfunction _getInsertDirection(target) {\n if (index(dragEl) < index(target)) {\n return 1;\n } else {\n return -1;\n }\n}\n/**\n * Generate id\n * @param {HTMLElement} el\n * @returns {String}\n * @private\n */\n\n\nfunction _generateId(el) {\n var str = el.tagName + el.className + el.src + el.href + el.textContent,\n i = str.length,\n sum = 0;\n\n while (i--) {\n sum += str.charCodeAt(i);\n }\n\n return sum.toString(36);\n}\n\nfunction _saveInputCheckedState(root) {\n savedInputChecked.length = 0;\n var inputs = root.getElementsByTagName('input');\n var idx = inputs.length;\n\n while (idx--) {\n var el = inputs[idx];\n el.checked && savedInputChecked.push(el);\n }\n}\n\nfunction _nextTick(fn) {\n return setTimeout(fn, 0);\n}\n\nfunction _cancelNextTick(id) {\n return clearTimeout(id);\n} // Fixed #973:\n\n\nif (documentExists) {\n on(document, 'touchmove', function (evt) {\n if ((Sortable.active || awaitingDragStarted) && evt.cancelable) {\n evt.preventDefault();\n }\n });\n} // Export utils\n\n\nSortable.utils = {\n on: on,\n off: off,\n css: css,\n find: find,\n is: function is(el, selector) {\n return !!closest(el, selector, el, false);\n },\n extend: extend,\n throttle: throttle,\n closest: closest,\n toggleClass: toggleClass,\n clone: clone,\n index: index,\n nextTick: _nextTick,\n cancelNextTick: _cancelNextTick,\n detectDirection: _detectDirection,\n getChild: getChild\n};\n/**\n * Get the Sortable instance of an element\n * @param {HTMLElement} element The element\n * @return {Sortable|undefined} The instance of Sortable\n */\n\nSortable.get = function (element) {\n return element[expando];\n};\n/**\n * Mount a plugin to Sortable\n * @param {...SortablePlugin|SortablePlugin[]} plugins Plugins being mounted\n */\n\n\nSortable.mount = function () {\n for (var _len = arguments.length, plugins = new Array(_len), _key = 0; _key < _len; _key++) {\n plugins[_key] = arguments[_key];\n }\n\n if (plugins[0].constructor === Array) plugins = plugins[0];\n plugins.forEach(function (plugin) {\n if (!plugin.prototype || !plugin.prototype.constructor) {\n throw \"Sortable: Mounted plugin must be a constructor function, not \".concat({}.toString.call(plugin));\n }\n\n if (plugin.utils) Sortable.utils = _objectSpread2(_objectSpread2({}, Sortable.utils), plugin.utils);\n PluginManager.mount(plugin);\n });\n};\n/**\n * Create sortable instance\n * @param {HTMLElement} el\n * @param {Object} [options]\n */\n\n\nSortable.create = function (el, options) {\n return new Sortable(el, options);\n}; // Export\n\n\nSortable.version = version;\n\nvar autoScrolls = [],\n scrollEl,\n scrollRootEl,\n scrolling = false,\n lastAutoScrollX,\n lastAutoScrollY,\n touchEvt$1,\n pointerElemChangedInterval;\n\nfunction AutoScrollPlugin() {\n function AutoScroll() {\n this.defaults = {\n scroll: true,\n forceAutoScrollFallback: false,\n scrollSensitivity: 30,\n scrollSpeed: 10,\n bubbleScroll: true\n }; // Bind all private methods\n\n for (var fn in this) {\n if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {\n this[fn] = this[fn].bind(this);\n }\n }\n }\n\n AutoScroll.prototype = {\n dragStarted: function dragStarted(_ref) {\n var originalEvent = _ref.originalEvent;\n\n if (this.sortable.nativeDraggable) {\n on(document, 'dragover', this._handleAutoScroll);\n } else {\n if (this.options.supportPointer) {\n on(document, 'pointermove', this._handleFallbackAutoScroll);\n } else if (originalEvent.touches) {\n on(document, 'touchmove', this._handleFallbackAutoScroll);\n } else {\n on(document, 'mousemove', this._handleFallbackAutoScroll);\n }\n }\n },\n dragOverCompleted: function dragOverCompleted(_ref2) {\n var originalEvent = _ref2.originalEvent;\n\n // For when bubbling is canceled and using fallback (fallback 'touchmove' always reached)\n if (!this.options.dragOverBubble && !originalEvent.rootEl) {\n this._handleAutoScroll(originalEvent);\n }\n },\n drop: function drop() {\n if (this.sortable.nativeDraggable) {\n off(document, 'dragover', this._handleAutoScroll);\n } else {\n off(document, 'pointermove', this._handleFallbackAutoScroll);\n off(document, 'touchmove', this._handleFallbackAutoScroll);\n off(document, 'mousemove', this._handleFallbackAutoScroll);\n }\n\n clearPointerElemChangedInterval();\n clearAutoScrolls();\n cancelThrottle();\n },\n nulling: function nulling() {\n touchEvt$1 = scrollRootEl = scrollEl = scrolling = pointerElemChangedInterval = lastAutoScrollX = lastAutoScrollY = null;\n autoScrolls.length = 0;\n },\n _handleFallbackAutoScroll: function _handleFallbackAutoScroll(evt) {\n this._handleAutoScroll(evt, true);\n },\n _handleAutoScroll: function _handleAutoScroll(evt, fallback) {\n var _this = this;\n\n var x = (evt.touches ? evt.touches[0] : evt).clientX,\n y = (evt.touches ? evt.touches[0] : evt).clientY,\n elem = document.elementFromPoint(x, y);\n touchEvt$1 = evt; // IE does not seem to have native autoscroll,\n // Edge's autoscroll seems too conditional,\n // MACOS Safari does not have autoscroll,\n // Firefox and Chrome are good\n\n if (fallback || this.options.forceAutoScrollFallback || Edge || IE11OrLess || Safari) {\n autoScroll(evt, this.options, elem, fallback); // Listener for pointer element change\n\n var ogElemScroller = getParentAutoScrollElement(elem, true);\n\n if (scrolling && (!pointerElemChangedInterval || x !== lastAutoScrollX || y !== lastAutoScrollY)) {\n pointerElemChangedInterval && clearPointerElemChangedInterval(); // Detect for pointer elem change, emulating native DnD behaviour\n\n pointerElemChangedInterval = setInterval(function () {\n var newElem = getParentAutoScrollElement(document.elementFromPoint(x, y), true);\n\n if (newElem !== ogElemScroller) {\n ogElemScroller = newElem;\n clearAutoScrolls();\n }\n\n autoScroll(evt, _this.options, newElem, fallback);\n }, 10);\n lastAutoScrollX = x;\n lastAutoScrollY = y;\n }\n } else {\n // if DnD is enabled (and browser has good autoscrolling), first autoscroll will already scroll, so get parent autoscroll of first autoscroll\n if (!this.options.bubbleScroll || getParentAutoScrollElement(elem, true) === getWindowScrollingElement()) {\n clearAutoScrolls();\n return;\n }\n\n autoScroll(evt, this.options, getParentAutoScrollElement(elem, false), false);\n }\n }\n };\n return _extends(AutoScroll, {\n pluginName: 'scroll',\n initializeByDefault: true\n });\n}\n\nfunction clearAutoScrolls() {\n autoScrolls.forEach(function (autoScroll) {\n clearInterval(autoScroll.pid);\n });\n autoScrolls = [];\n}\n\nfunction clearPointerElemChangedInterval() {\n clearInterval(pointerElemChangedInterval);\n}\n\nvar autoScroll = throttle(function (evt, options, rootEl, isFallback) {\n // Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=505521\n if (!options.scroll) return;\n var x = (evt.touches ? evt.touches[0] : evt).clientX,\n y = (evt.touches ? evt.touches[0] : evt).clientY,\n sens = options.scrollSensitivity,\n speed = options.scrollSpeed,\n winScroller = getWindowScrollingElement();\n var scrollThisInstance = false,\n scrollCustomFn; // New scroll root, set scrollEl\n\n if (scrollRootEl !== rootEl) {\n scrollRootEl = rootEl;\n clearAutoScrolls();\n scrollEl = options.scroll;\n scrollCustomFn = options.scrollFn;\n\n if (scrollEl === true) {\n scrollEl = getParentAutoScrollElement(rootEl, true);\n }\n }\n\n var layersOut = 0;\n var currentParent = scrollEl;\n\n do {\n var el = currentParent,\n rect = getRect(el),\n top = rect.top,\n bottom = rect.bottom,\n left = rect.left,\n right = rect.right,\n width = rect.width,\n height = rect.height,\n canScrollX = void 0,\n canScrollY = void 0,\n scrollWidth = el.scrollWidth,\n scrollHeight = el.scrollHeight,\n elCSS = css(el),\n scrollPosX = el.scrollLeft,\n scrollPosY = el.scrollTop;\n\n if (el === winScroller) {\n canScrollX = width < scrollWidth && (elCSS.overflowX === 'auto' || elCSS.overflowX === 'scroll' || elCSS.overflowX === 'visible');\n canScrollY = height < scrollHeight && (elCSS.overflowY === 'auto' || elCSS.overflowY === 'scroll' || elCSS.overflowY === 'visible');\n } else {\n canScrollX = width < scrollWidth && (elCSS.overflowX === 'auto' || elCSS.overflowX === 'scroll');\n canScrollY = height < scrollHeight && (elCSS.overflowY === 'auto' || elCSS.overflowY === 'scroll');\n }\n\n var vx = canScrollX && (Math.abs(right - x) <= sens && scrollPosX + width < scrollWidth) - (Math.abs(left - x) <= sens && !!scrollPosX);\n var vy = canScrollY && (Math.abs(bottom - y) <= sens && scrollPosY + height < scrollHeight) - (Math.abs(top - y) <= sens && !!scrollPosY);\n\n if (!autoScrolls[layersOut]) {\n for (var i = 0; i <= layersOut; i++) {\n if (!autoScrolls[i]) {\n autoScrolls[i] = {};\n }\n }\n }\n\n if (autoScrolls[layersOut].vx != vx || autoScrolls[layersOut].vy != vy || autoScrolls[layersOut].el !== el) {\n autoScrolls[layersOut].el = el;\n autoScrolls[layersOut].vx = vx;\n autoScrolls[layersOut].vy = vy;\n clearInterval(autoScrolls[layersOut].pid);\n\n if (vx != 0 || vy != 0) {\n scrollThisInstance = true;\n /* jshint loopfunc:true */\n\n autoScrolls[layersOut].pid = setInterval(function () {\n // emulate drag over during autoscroll (fallback), emulating native DnD behaviour\n if (isFallback && this.layer === 0) {\n Sortable.active._onTouchMove(touchEvt$1); // To move ghost if it is positioned absolutely\n\n }\n\n var scrollOffsetY = autoScrolls[this.layer].vy ? autoScrolls[this.layer].vy * speed : 0;\n var scrollOffsetX = autoScrolls[this.layer].vx ? autoScrolls[this.layer].vx * speed : 0;\n\n if (typeof scrollCustomFn === 'function') {\n if (scrollCustomFn.call(Sortable.dragged.parentNode[expando], scrollOffsetX, scrollOffsetY, evt, touchEvt$1, autoScrolls[this.layer].el) !== 'continue') {\n return;\n }\n }\n\n scrollBy(autoScrolls[this.layer].el, scrollOffsetX, scrollOffsetY);\n }.bind({\n layer: layersOut\n }), 24);\n }\n }\n\n layersOut++;\n } while (options.bubbleScroll && currentParent !== winScroller && (currentParent = getParentAutoScrollElement(currentParent, false)));\n\n scrolling = scrollThisInstance; // in case another function catches scrolling as false in between when it is not\n}, 30);\n\nvar drop = function drop(_ref) {\n var originalEvent = _ref.originalEvent,\n putSortable = _ref.putSortable,\n dragEl = _ref.dragEl,\n activeSortable = _ref.activeSortable,\n dispatchSortableEvent = _ref.dispatchSortableEvent,\n hideGhostForTarget = _ref.hideGhostForTarget,\n unhideGhostForTarget = _ref.unhideGhostForTarget;\n if (!originalEvent) return;\n var toSortable = putSortable || activeSortable;\n hideGhostForTarget();\n var touch = originalEvent.changedTouches && originalEvent.changedTouches.length ? originalEvent.changedTouches[0] : originalEvent;\n var target = document.elementFromPoint(touch.clientX, touch.clientY);\n unhideGhostForTarget();\n\n if (toSortable && !toSortable.el.contains(target)) {\n dispatchSortableEvent('spill');\n this.onSpill({\n dragEl: dragEl,\n putSortable: putSortable\n });\n }\n};\n\nfunction Revert() {}\n\nRevert.prototype = {\n startIndex: null,\n dragStart: function dragStart(_ref2) {\n var oldDraggableIndex = _ref2.oldDraggableIndex;\n this.startIndex = oldDraggableIndex;\n },\n onSpill: function onSpill(_ref3) {\n var dragEl = _ref3.dragEl,\n putSortable = _ref3.putSortable;\n this.sortable.captureAnimationState();\n\n if (putSortable) {\n putSortable.captureAnimationState();\n }\n\n var nextSibling = getChild(this.sortable.el, this.startIndex, this.options);\n\n if (nextSibling) {\n this.sortable.el.insertBefore(dragEl, nextSibling);\n } else {\n this.sortable.el.appendChild(dragEl);\n }\n\n this.sortable.animateAll();\n\n if (putSortable) {\n putSortable.animateAll();\n }\n },\n drop: drop\n};\n\n_extends(Revert, {\n pluginName: 'revertOnSpill'\n});\n\nfunction Remove() {}\n\nRemove.prototype = {\n onSpill: function onSpill(_ref4) {\n var dragEl = _ref4.dragEl,\n putSortable = _ref4.putSortable;\n var parentSortable = putSortable || this.sortable;\n parentSortable.captureAnimationState();\n dragEl.parentNode && dragEl.parentNode.removeChild(dragEl);\n parentSortable.animateAll();\n },\n drop: drop\n};\n\n_extends(Remove, {\n pluginName: 'removeOnSpill'\n});\n\nvar lastSwapEl;\n\nfunction SwapPlugin() {\n function Swap() {\n this.defaults = {\n swapClass: 'sortable-swap-highlight'\n };\n }\n\n Swap.prototype = {\n dragStart: function dragStart(_ref) {\n var dragEl = _ref.dragEl;\n lastSwapEl = dragEl;\n },\n dragOverValid: function dragOverValid(_ref2) {\n var completed = _ref2.completed,\n target = _ref2.target,\n onMove = _ref2.onMove,\n activeSortable = _ref2.activeSortable,\n changed = _ref2.changed,\n cancel = _ref2.cancel;\n if (!activeSortable.options.swap) return;\n var el = this.sortable.el,\n options = this.options;\n\n if (target && target !== el) {\n var prevSwapEl = lastSwapEl;\n\n if (onMove(target) !== false) {\n toggleClass(target, options.swapClass, true);\n lastSwapEl = target;\n } else {\n lastSwapEl = null;\n }\n\n if (prevSwapEl && prevSwapEl !== lastSwapEl) {\n toggleClass(prevSwapEl, options.swapClass, false);\n }\n }\n\n changed();\n completed(true);\n cancel();\n },\n drop: function drop(_ref3) {\n var activeSortable = _ref3.activeSortable,\n putSortable = _ref3.putSortable,\n dragEl = _ref3.dragEl;\n var toSortable = putSortable || this.sortable;\n var options = this.options;\n lastSwapEl && toggleClass(lastSwapEl, options.swapClass, false);\n\n if (lastSwapEl && (options.swap || putSortable && putSortable.options.swap)) {\n if (dragEl !== lastSwapEl) {\n toSortable.captureAnimationState();\n if (toSortable !== activeSortable) activeSortable.captureAnimationState();\n swapNodes(dragEl, lastSwapEl);\n toSortable.animateAll();\n if (toSortable !== activeSortable) activeSortable.animateAll();\n }\n }\n },\n nulling: function nulling() {\n lastSwapEl = null;\n }\n };\n return _extends(Swap, {\n pluginName: 'swap',\n eventProperties: function eventProperties() {\n return {\n swapItem: lastSwapEl\n };\n }\n });\n}\n\nfunction swapNodes(n1, n2) {\n var p1 = n1.parentNode,\n p2 = n2.parentNode,\n i1,\n i2;\n if (!p1 || !p2 || p1.isEqualNode(n2) || p2.isEqualNode(n1)) return;\n i1 = index(n1);\n i2 = index(n2);\n\n if (p1.isEqualNode(p2) && i1 < i2) {\n i2++;\n }\n\n p1.insertBefore(n2, p1.children[i1]);\n p2.insertBefore(n1, p2.children[i2]);\n}\n\nvar multiDragElements = [],\n multiDragClones = [],\n lastMultiDragSelect,\n // for selection with modifier key down (SHIFT)\nmultiDragSortable,\n initialFolding = false,\n // Initial multi-drag fold when drag started\nfolding = false,\n // Folding any other time\ndragStarted = false,\n dragEl$1,\n clonesFromRect,\n clonesHidden;\n\nfunction MultiDragPlugin() {\n function MultiDrag(sortable) {\n // Bind all private methods\n for (var fn in this) {\n if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {\n this[fn] = this[fn].bind(this);\n }\n }\n\n if (sortable.options.supportPointer) {\n on(document, 'pointerup', this._deselectMultiDrag);\n } else {\n on(document, 'mouseup', this._deselectMultiDrag);\n on(document, 'touchend', this._deselectMultiDrag);\n }\n\n on(document, 'keydown', this._checkKeyDown);\n on(document, 'keyup', this._checkKeyUp);\n this.defaults = {\n selectedClass: 'sortable-selected',\n multiDragKey: null,\n setData: function setData(dataTransfer, dragEl) {\n var data = '';\n\n if (multiDragElements.length && multiDragSortable === sortable) {\n multiDragElements.forEach(function (multiDragElement, i) {\n data += (!i ? '' : ', ') + multiDragElement.textContent;\n });\n } else {\n data = dragEl.textContent;\n }\n\n dataTransfer.setData('Text', data);\n }\n };\n }\n\n MultiDrag.prototype = {\n multiDragKeyDown: false,\n isMultiDrag: false,\n delayStartGlobal: function delayStartGlobal(_ref) {\n var dragged = _ref.dragEl;\n dragEl$1 = dragged;\n },\n delayEnded: function delayEnded() {\n this.isMultiDrag = ~multiDragElements.indexOf(dragEl$1);\n },\n setupClone: function setupClone(_ref2) {\n var sortable = _ref2.sortable,\n cancel = _ref2.cancel;\n if (!this.isMultiDrag) return;\n\n for (var i = 0; i < multiDragElements.length; i++) {\n multiDragClones.push(clone(multiDragElements[i]));\n multiDragClones[i].sortableIndex = multiDragElements[i].sortableIndex;\n multiDragClones[i].draggable = false;\n multiDragClones[i].style['will-change'] = '';\n toggleClass(multiDragClones[i], this.options.selectedClass, false);\n multiDragElements[i] === dragEl$1 && toggleClass(multiDragClones[i], this.options.chosenClass, false);\n }\n\n sortable._hideClone();\n\n cancel();\n },\n clone: function clone(_ref3) {\n var sortable = _ref3.sortable,\n rootEl = _ref3.rootEl,\n dispatchSortableEvent = _ref3.dispatchSortableEvent,\n cancel = _ref3.cancel;\n if (!this.isMultiDrag) return;\n\n if (!this.options.removeCloneOnHide) {\n if (multiDragElements.length && multiDragSortable === sortable) {\n insertMultiDragClones(true, rootEl);\n dispatchSortableEvent('clone');\n cancel();\n }\n }\n },\n showClone: function showClone(_ref4) {\n var cloneNowShown = _ref4.cloneNowShown,\n rootEl = _ref4.rootEl,\n cancel = _ref4.cancel;\n if (!this.isMultiDrag) return;\n insertMultiDragClones(false, rootEl);\n multiDragClones.forEach(function (clone) {\n css(clone, 'display', '');\n });\n cloneNowShown();\n clonesHidden = false;\n cancel();\n },\n hideClone: function hideClone(_ref5) {\n var _this = this;\n\n var sortable = _ref5.sortable,\n cloneNowHidden = _ref5.cloneNowHidden,\n cancel = _ref5.cancel;\n if (!this.isMultiDrag) return;\n multiDragClones.forEach(function (clone) {\n css(clone, 'display', 'none');\n\n if (_this.options.removeCloneOnHide && clone.parentNode) {\n clone.parentNode.removeChild(clone);\n }\n });\n cloneNowHidden();\n clonesHidden = true;\n cancel();\n },\n dragStartGlobal: function dragStartGlobal(_ref6) {\n var sortable = _ref6.sortable;\n\n if (!this.isMultiDrag && multiDragSortable) {\n multiDragSortable.multiDrag._deselectMultiDrag();\n }\n\n multiDragElements.forEach(function (multiDragElement) {\n multiDragElement.sortableIndex = index(multiDragElement);\n }); // Sort multi-drag elements\n\n multiDragElements = multiDragElements.sort(function (a, b) {\n return a.sortableIndex - b.sortableIndex;\n });\n dragStarted = true;\n },\n dragStarted: function dragStarted(_ref7) {\n var _this2 = this;\n\n var sortable = _ref7.sortable;\n if (!this.isMultiDrag) return;\n\n if (this.options.sort) {\n // Capture rects,\n // hide multi drag elements (by positioning them absolute),\n // set multi drag elements rects to dragRect,\n // show multi drag elements,\n // animate to rects,\n // unset rects & remove from DOM\n sortable.captureAnimationState();\n\n if (this.options.animation) {\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n css(multiDragElement, 'position', 'absolute');\n });\n var dragRect = getRect(dragEl$1, false, true, true);\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n setRect(multiDragElement, dragRect);\n });\n folding = true;\n initialFolding = true;\n }\n }\n\n sortable.animateAll(function () {\n folding = false;\n initialFolding = false;\n\n if (_this2.options.animation) {\n multiDragElements.forEach(function (multiDragElement) {\n unsetRect(multiDragElement);\n });\n } // Remove all auxiliary multidrag items from el, if sorting enabled\n\n\n if (_this2.options.sort) {\n removeMultiDragElements();\n }\n });\n },\n dragOver: function dragOver(_ref8) {\n var target = _ref8.target,\n completed = _ref8.completed,\n cancel = _ref8.cancel;\n\n if (folding && ~multiDragElements.indexOf(target)) {\n completed(false);\n cancel();\n }\n },\n revert: function revert(_ref9) {\n var fromSortable = _ref9.fromSortable,\n rootEl = _ref9.rootEl,\n sortable = _ref9.sortable,\n dragRect = _ref9.dragRect;\n\n if (multiDragElements.length > 1) {\n // Setup unfold animation\n multiDragElements.forEach(function (multiDragElement) {\n sortable.addAnimationState({\n target: multiDragElement,\n rect: folding ? getRect(multiDragElement) : dragRect\n });\n unsetRect(multiDragElement);\n multiDragElement.fromRect = dragRect;\n fromSortable.removeAnimationState(multiDragElement);\n });\n folding = false;\n insertMultiDragElements(!this.options.removeCloneOnHide, rootEl);\n }\n },\n dragOverCompleted: function dragOverCompleted(_ref10) {\n var sortable = _ref10.sortable,\n isOwner = _ref10.isOwner,\n insertion = _ref10.insertion,\n activeSortable = _ref10.activeSortable,\n parentEl = _ref10.parentEl,\n putSortable = _ref10.putSortable;\n var options = this.options;\n\n if (insertion) {\n // Clones must be hidden before folding animation to capture dragRectAbsolute properly\n if (isOwner) {\n activeSortable._hideClone();\n }\n\n initialFolding = false; // If leaving sort:false root, or already folding - Fold to new location\n\n if (options.animation && multiDragElements.length > 1 && (folding || !isOwner && !activeSortable.options.sort && !putSortable)) {\n // Fold: Set all multi drag elements's rects to dragEl's rect when multi-drag elements are invisible\n var dragRectAbsolute = getRect(dragEl$1, false, true, true);\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n setRect(multiDragElement, dragRectAbsolute); // Move element(s) to end of parentEl so that it does not interfere with multi-drag clones insertion if they are inserted\n // while folding, and so that we can capture them again because old sortable will no longer be fromSortable\n\n parentEl.appendChild(multiDragElement);\n });\n folding = true;\n } // Clones must be shown (and check to remove multi drags) after folding when interfering multiDragElements are moved out\n\n\n if (!isOwner) {\n // Only remove if not folding (folding will remove them anyways)\n if (!folding) {\n removeMultiDragElements();\n }\n\n if (multiDragElements.length > 1) {\n var clonesHiddenBefore = clonesHidden;\n\n activeSortable._showClone(sortable); // Unfold animation for clones if showing from hidden\n\n\n if (activeSortable.options.animation && !clonesHidden && clonesHiddenBefore) {\n multiDragClones.forEach(function (clone) {\n activeSortable.addAnimationState({\n target: clone,\n rect: clonesFromRect\n });\n clone.fromRect = clonesFromRect;\n clone.thisAnimationDuration = null;\n });\n }\n } else {\n activeSortable._showClone(sortable);\n }\n }\n }\n },\n dragOverAnimationCapture: function dragOverAnimationCapture(_ref11) {\n var dragRect = _ref11.dragRect,\n isOwner = _ref11.isOwner,\n activeSortable = _ref11.activeSortable;\n multiDragElements.forEach(function (multiDragElement) {\n multiDragElement.thisAnimationDuration = null;\n });\n\n if (activeSortable.options.animation && !isOwner && activeSortable.multiDrag.isMultiDrag) {\n clonesFromRect = _extends({}, dragRect);\n var dragMatrix = matrix(dragEl$1, true);\n clonesFromRect.top -= dragMatrix.f;\n clonesFromRect.left -= dragMatrix.e;\n }\n },\n dragOverAnimationComplete: function dragOverAnimationComplete() {\n if (folding) {\n folding = false;\n removeMultiDragElements();\n }\n },\n drop: function drop(_ref12) {\n var evt = _ref12.originalEvent,\n rootEl = _ref12.rootEl,\n parentEl = _ref12.parentEl,\n sortable = _ref12.sortable,\n dispatchSortableEvent = _ref12.dispatchSortableEvent,\n oldIndex = _ref12.oldIndex,\n putSortable = _ref12.putSortable;\n var toSortable = putSortable || this.sortable;\n if (!evt) return;\n var options = this.options,\n children = parentEl.children; // Multi-drag selection\n\n if (!dragStarted) {\n if (options.multiDragKey && !this.multiDragKeyDown) {\n this._deselectMultiDrag();\n }\n\n toggleClass(dragEl$1, options.selectedClass, !~multiDragElements.indexOf(dragEl$1));\n\n if (!~multiDragElements.indexOf(dragEl$1)) {\n multiDragElements.push(dragEl$1);\n dispatchEvent({\n sortable: sortable,\n rootEl: rootEl,\n name: 'select',\n targetEl: dragEl$1,\n originalEvt: evt\n }); // Modifier activated, select from last to dragEl\n\n if (evt.shiftKey && lastMultiDragSelect && sortable.el.contains(lastMultiDragSelect)) {\n var lastIndex = index(lastMultiDragSelect),\n currentIndex = index(dragEl$1);\n\n if (~lastIndex && ~currentIndex && lastIndex !== currentIndex) {\n // Must include lastMultiDragSelect (select it), in case modified selection from no selection\n // (but previous selection existed)\n var n, i;\n\n if (currentIndex > lastIndex) {\n i = lastIndex;\n n = currentIndex;\n } else {\n i = currentIndex;\n n = lastIndex + 1;\n }\n\n for (; i < n; i++) {\n if (~multiDragElements.indexOf(children[i])) continue;\n toggleClass(children[i], options.selectedClass, true);\n multiDragElements.push(children[i]);\n dispatchEvent({\n sortable: sortable,\n rootEl: rootEl,\n name: 'select',\n targetEl: children[i],\n originalEvt: evt\n });\n }\n }\n } else {\n lastMultiDragSelect = dragEl$1;\n }\n\n multiDragSortable = toSortable;\n } else {\n multiDragElements.splice(multiDragElements.indexOf(dragEl$1), 1);\n lastMultiDragSelect = null;\n dispatchEvent({\n sortable: sortable,\n rootEl: rootEl,\n name: 'deselect',\n targetEl: dragEl$1,\n originalEvt: evt\n });\n }\n } // Multi-drag drop\n\n\n if (dragStarted && this.isMultiDrag) {\n folding = false; // Do not \"unfold\" after around dragEl if reverted\n\n if ((parentEl[expando].options.sort || parentEl !== rootEl) && multiDragElements.length > 1) {\n var dragRect = getRect(dragEl$1),\n multiDragIndex = index(dragEl$1, ':not(.' + this.options.selectedClass + ')');\n if (!initialFolding && options.animation) dragEl$1.thisAnimationDuration = null;\n toSortable.captureAnimationState();\n\n if (!initialFolding) {\n if (options.animation) {\n dragEl$1.fromRect = dragRect;\n multiDragElements.forEach(function (multiDragElement) {\n multiDragElement.thisAnimationDuration = null;\n\n if (multiDragElement !== dragEl$1) {\n var rect = folding ? getRect(multiDragElement) : dragRect;\n multiDragElement.fromRect = rect; // Prepare unfold animation\n\n toSortable.addAnimationState({\n target: multiDragElement,\n rect: rect\n });\n }\n });\n } // Multi drag elements are not necessarily removed from the DOM on drop, so to reinsert\n // properly they must all be removed\n\n\n removeMultiDragElements();\n multiDragElements.forEach(function (multiDragElement) {\n if (children[multiDragIndex]) {\n parentEl.insertBefore(multiDragElement, children[multiDragIndex]);\n } else {\n parentEl.appendChild(multiDragElement);\n }\n\n multiDragIndex++;\n }); // If initial folding is done, the elements may have changed position because they are now\n // unfolding around dragEl, even though dragEl may not have his index changed, so update event\n // must be fired here as Sortable will not.\n\n if (oldIndex === index(dragEl$1)) {\n var update = false;\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement.sortableIndex !== index(multiDragElement)) {\n update = true;\n return;\n }\n });\n\n if (update) {\n dispatchSortableEvent('update');\n }\n }\n } // Must be done after capturing individual rects (scroll bar)\n\n\n multiDragElements.forEach(function (multiDragElement) {\n unsetRect(multiDragElement);\n });\n toSortable.animateAll();\n }\n\n multiDragSortable = toSortable;\n } // Remove clones if necessary\n\n\n if (rootEl === parentEl || putSortable && putSortable.lastPutMode !== 'clone') {\n multiDragClones.forEach(function (clone) {\n clone.parentNode && clone.parentNode.removeChild(clone);\n });\n }\n },\n nullingGlobal: function nullingGlobal() {\n this.isMultiDrag = dragStarted = false;\n multiDragClones.length = 0;\n },\n destroyGlobal: function destroyGlobal() {\n this._deselectMultiDrag();\n\n off(document, 'pointerup', this._deselectMultiDrag);\n off(document, 'mouseup', this._deselectMultiDrag);\n off(document, 'touchend', this._deselectMultiDrag);\n off(document, 'keydown', this._checkKeyDown);\n off(document, 'keyup', this._checkKeyUp);\n },\n _deselectMultiDrag: function _deselectMultiDrag(evt) {\n if (typeof dragStarted !== \"undefined\" && dragStarted) return; // Only deselect if selection is in this sortable\n\n if (multiDragSortable !== this.sortable) return; // Only deselect if target is not item in this sortable\n\n if (evt && closest(evt.target, this.options.draggable, this.sortable.el, false)) return; // Only deselect if left click\n\n if (evt && evt.button !== 0) return;\n\n while (multiDragElements.length) {\n var el = multiDragElements[0];\n toggleClass(el, this.options.selectedClass, false);\n multiDragElements.shift();\n dispatchEvent({\n sortable: this.sortable,\n rootEl: this.sortable.el,\n name: 'deselect',\n targetEl: el,\n originalEvt: evt\n });\n }\n },\n _checkKeyDown: function _checkKeyDown(evt) {\n if (evt.key === this.options.multiDragKey) {\n this.multiDragKeyDown = true;\n }\n },\n _checkKeyUp: function _checkKeyUp(evt) {\n if (evt.key === this.options.multiDragKey) {\n this.multiDragKeyDown = false;\n }\n }\n };\n return _extends(MultiDrag, {\n // Static methods & properties\n pluginName: 'multiDrag',\n utils: {\n /**\n * Selects the provided multi-drag item\n * @param {HTMLElement} el The element to be selected\n */\n select: function select(el) {\n var sortable = el.parentNode[expando];\n if (!sortable || !sortable.options.multiDrag || ~multiDragElements.indexOf(el)) return;\n\n if (multiDragSortable && multiDragSortable !== sortable) {\n multiDragSortable.multiDrag._deselectMultiDrag();\n\n multiDragSortable = sortable;\n }\n\n toggleClass(el, sortable.options.selectedClass, true);\n multiDragElements.push(el);\n },\n\n /**\n * Deselects the provided multi-drag item\n * @param {HTMLElement} el The element to be deselected\n */\n deselect: function deselect(el) {\n var sortable = el.parentNode[expando],\n index = multiDragElements.indexOf(el);\n if (!sortable || !sortable.options.multiDrag || !~index) return;\n toggleClass(el, sortable.options.selectedClass, false);\n multiDragElements.splice(index, 1);\n }\n },\n eventProperties: function eventProperties() {\n var _this3 = this;\n\n var oldIndicies = [],\n newIndicies = [];\n multiDragElements.forEach(function (multiDragElement) {\n oldIndicies.push({\n multiDragElement: multiDragElement,\n index: multiDragElement.sortableIndex\n }); // multiDragElements will already be sorted if folding\n\n var newIndex;\n\n if (folding && multiDragElement !== dragEl$1) {\n newIndex = -1;\n } else if (folding) {\n newIndex = index(multiDragElement, ':not(.' + _this3.options.selectedClass + ')');\n } else {\n newIndex = index(multiDragElement);\n }\n\n newIndicies.push({\n multiDragElement: multiDragElement,\n index: newIndex\n });\n });\n return {\n items: _toConsumableArray(multiDragElements),\n clones: [].concat(multiDragClones),\n oldIndicies: oldIndicies,\n newIndicies: newIndicies\n };\n },\n optionListeners: {\n multiDragKey: function multiDragKey(key) {\n key = key.toLowerCase();\n\n if (key === 'ctrl') {\n key = 'Control';\n } else if (key.length > 1) {\n key = key.charAt(0).toUpperCase() + key.substr(1);\n }\n\n return key;\n }\n }\n });\n}\n\nfunction insertMultiDragElements(clonesInserted, rootEl) {\n multiDragElements.forEach(function (multiDragElement, i) {\n var target = rootEl.children[multiDragElement.sortableIndex + (clonesInserted ? Number(i) : 0)];\n\n if (target) {\n rootEl.insertBefore(multiDragElement, target);\n } else {\n rootEl.appendChild(multiDragElement);\n }\n });\n}\n/**\n * Insert multi-drag clones\n * @param {[Boolean]} elementsInserted Whether the multi-drag elements are inserted\n * @param {HTMLElement} rootEl\n */\n\n\nfunction insertMultiDragClones(elementsInserted, rootEl) {\n multiDragClones.forEach(function (clone, i) {\n var target = rootEl.children[clone.sortableIndex + (elementsInserted ? Number(i) : 0)];\n\n if (target) {\n rootEl.insertBefore(clone, target);\n } else {\n rootEl.appendChild(clone);\n }\n });\n}\n\nfunction removeMultiDragElements() {\n multiDragElements.forEach(function (multiDragElement) {\n if (multiDragElement === dragEl$1) return;\n multiDragElement.parentNode && multiDragElement.parentNode.removeChild(multiDragElement);\n });\n}\n\nSortable.mount(new AutoScrollPlugin());\nSortable.mount(Remove, Revert);\n\nexport default Sortable;\nexport { MultiDragPlugin as MultiDrag, Sortable, SwapPlugin as Swap };\n","/*! https://mths.be/punycode v1.3.2 by @mathias */\n;(function(root) {\n\n\t/** Detect free variables */\n\tvar freeExports = typeof exports == 'object' && exports &&\n\t\t!exports.nodeType && exports;\n\tvar freeModule = typeof module == 'object' && module &&\n\t\t!module.nodeType && module;\n\tvar freeGlobal = typeof global == 'object' && global;\n\tif (\n\t\tfreeGlobal.global === freeGlobal ||\n\t\tfreeGlobal.window === freeGlobal ||\n\t\tfreeGlobal.self === freeGlobal\n\t) {\n\t\troot = freeGlobal;\n\t}\n\n\t/**\n\t * The `punycode` object.\n\t * @name punycode\n\t * @type Object\n\t */\n\tvar punycode,\n\n\t/** Highest positive signed 32-bit float value */\n\tmaxInt = 2147483647, // aka. 0x7FFFFFFF or 2^31-1\n\n\t/** Bootstring parameters */\n\tbase = 36,\n\ttMin = 1,\n\ttMax = 26,\n\tskew = 38,\n\tdamp = 700,\n\tinitialBias = 72,\n\tinitialN = 128, // 0x80\n\tdelimiter = '-', // '\\x2D'\n\n\t/** Regular expressions */\n\tregexPunycode = /^xn--/,\n\tregexNonASCII = /[^\\x20-\\x7E]/, // unprintable ASCII chars + non-ASCII chars\n\tregexSeparators = /[\\x2E\\u3002\\uFF0E\\uFF61]/g, // RFC 3490 separators\n\n\t/** Error messages */\n\terrors = {\n\t\t'overflow': 'Overflow: input needs wider integers to process',\n\t\t'not-basic': 'Illegal input >= 0x80 (not a basic code point)',\n\t\t'invalid-input': 'Invalid input'\n\t},\n\n\t/** Convenience shortcuts */\n\tbaseMinusTMin = base - tMin,\n\tfloor = Math.floor,\n\tstringFromCharCode = String.fromCharCode,\n\n\t/** Temporary variable */\n\tkey;\n\n\t/*--------------------------------------------------------------------------*/\n\n\t/**\n\t * A generic error utility function.\n\t * @private\n\t * @param {String} type The error type.\n\t * @returns {Error} Throws a `RangeError` with the applicable error message.\n\t */\n\tfunction error(type) {\n\t\tthrow RangeError(errors[type]);\n\t}\n\n\t/**\n\t * A generic `Array#map` utility function.\n\t * @private\n\t * @param {Array} array The array to iterate over.\n\t * @param {Function} callback The function that gets called for every array\n\t * item.\n\t * @returns {Array} A new array of values returned by the callback function.\n\t */\n\tfunction map(array, fn) {\n\t\tvar length = array.length;\n\t\tvar result = [];\n\t\twhile (length--) {\n\t\t\tresult[length] = fn(array[length]);\n\t\t}\n\t\treturn result;\n\t}\n\n\t/**\n\t * A simple `Array#map`-like wrapper to work with domain name strings or email\n\t * addresses.\n\t * @private\n\t * @param {String} domain The domain name or email address.\n\t * @param {Function} callback The function that gets called for every\n\t * character.\n\t * @returns {Array} A new string of characters returned by the callback\n\t * function.\n\t */\n\tfunction mapDomain(string, fn) {\n\t\tvar parts = string.split('@');\n\t\tvar result = '';\n\t\tif (parts.length > 1) {\n\t\t\t// In email addresses, only the domain name should be punycoded. Leave\n\t\t\t// the local part (i.e. everything up to `@`) intact.\n\t\t\tresult = parts[0] + '@';\n\t\t\tstring = parts[1];\n\t\t}\n\t\t// Avoid `split(regex)` for IE8 compatibility. See #17.\n\t\tstring = string.replace(regexSeparators, '\\x2E');\n\t\tvar labels = string.split('.');\n\t\tvar encoded = map(labels, fn).join('.');\n\t\treturn result + encoded;\n\t}\n\n\t/**\n\t * Creates an array containing the numeric code points of each Unicode\n\t * character in the string. While JavaScript uses UCS-2 internally,\n\t * this function will convert a pair of surrogate halves (each of which\n\t * UCS-2 exposes as separate characters) into a single code point,\n\t * matching UTF-16.\n\t * @see `punycode.ucs2.encode`\n\t * @see <https://mathiasbynens.be/notes/javascript-encoding>\n\t * @memberOf punycode.ucs2\n\t * @name decode\n\t * @param {String} string The Unicode input string (UCS-2).\n\t * @returns {Array} The new array of code points.\n\t */\n\tfunction ucs2decode(string) {\n\t\tvar output = [],\n\t\t counter = 0,\n\t\t length = string.length,\n\t\t value,\n\t\t extra;\n\t\twhile (counter < length) {\n\t\t\tvalue = string.charCodeAt(counter++);\n\t\t\tif (value >= 0xD800 && value <= 0xDBFF && counter < length) {\n\t\t\t\t// high surrogate, and there is a next character\n\t\t\t\textra = string.charCodeAt(counter++);\n\t\t\t\tif ((extra & 0xFC00) == 0xDC00) { // low surrogate\n\t\t\t\t\toutput.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);\n\t\t\t\t} else {\n\t\t\t\t\t// unmatched surrogate; only append this code unit, in case the next\n\t\t\t\t\t// code unit is the high surrogate of a surrogate pair\n\t\t\t\t\toutput.push(value);\n\t\t\t\t\tcounter--;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\toutput.push(value);\n\t\t\t}\n\t\t}\n\t\treturn output;\n\t}\n\n\t/**\n\t * Creates a string based on an array of numeric code points.\n\t * @see `punycode.ucs2.decode`\n\t * @memberOf punycode.ucs2\n\t * @name encode\n\t * @param {Array} codePoints The array of numeric code points.\n\t * @returns {String} The new Unicode string (UCS-2).\n\t */\n\tfunction ucs2encode(array) {\n\t\treturn map(array, function(value) {\n\t\t\tvar output = '';\n\t\t\tif (value > 0xFFFF) {\n\t\t\t\tvalue -= 0x10000;\n\t\t\t\toutput += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);\n\t\t\t\tvalue = 0xDC00 | value & 0x3FF;\n\t\t\t}\n\t\t\toutput += stringFromCharCode(value);\n\t\t\treturn output;\n\t\t}).join('');\n\t}\n\n\t/**\n\t * Converts a basic code point into a digit/integer.\n\t * @see `digitToBasic()`\n\t * @private\n\t * @param {Number} codePoint The basic numeric code point value.\n\t * @returns {Number} The numeric value of a basic code point (for use in\n\t * representing integers) in the range `0` to `base - 1`, or `base` if\n\t * the code point does not represent a value.\n\t */\n\tfunction basicToDigit(codePoint) {\n\t\tif (codePoint - 48 < 10) {\n\t\t\treturn codePoint - 22;\n\t\t}\n\t\tif (codePoint - 65 < 26) {\n\t\t\treturn codePoint - 65;\n\t\t}\n\t\tif (codePoint - 97 < 26) {\n\t\t\treturn codePoint - 97;\n\t\t}\n\t\treturn base;\n\t}\n\n\t/**\n\t * Converts a digit/integer into a basic code point.\n\t * @see `basicToDigit()`\n\t * @private\n\t * @param {Number} digit The numeric value of a basic code point.\n\t * @returns {Number} The basic code point whose value (when used for\n\t * representing integers) is `digit`, which needs to be in the range\n\t * `0` to `base - 1`. If `flag` is non-zero, the uppercase form is\n\t * used; else, the lowercase form is used. The behavior is undefined\n\t * if `flag` is non-zero and `digit` has no uppercase form.\n\t */\n\tfunction digitToBasic(digit, flag) {\n\t\t// 0..25 map to ASCII a..z or A..Z\n\t\t// 26..35 map to ASCII 0..9\n\t\treturn digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);\n\t}\n\n\t/**\n\t * Bias adaptation function as per section 3.4 of RFC 3492.\n\t * http://tools.ietf.org/html/rfc3492#section-3.4\n\t * @private\n\t */\n\tfunction adapt(delta, numPoints, firstTime) {\n\t\tvar k = 0;\n\t\tdelta = firstTime ? floor(delta / damp) : delta >> 1;\n\t\tdelta += floor(delta / numPoints);\n\t\tfor (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {\n\t\t\tdelta = floor(delta / baseMinusTMin);\n\t\t}\n\t\treturn floor(k + (baseMinusTMin + 1) * delta / (delta + skew));\n\t}\n\n\t/**\n\t * Converts a Punycode string of ASCII-only symbols to a string of Unicode\n\t * symbols.\n\t * @memberOf punycode\n\t * @param {String} input The Punycode string of ASCII-only symbols.\n\t * @returns {String} The resulting string of Unicode symbols.\n\t */\n\tfunction decode(input) {\n\t\t// Don't use UCS-2\n\t\tvar output = [],\n\t\t inputLength = input.length,\n\t\t out,\n\t\t i = 0,\n\t\t n = initialN,\n\t\t bias = initialBias,\n\t\t basic,\n\t\t j,\n\t\t index,\n\t\t oldi,\n\t\t w,\n\t\t k,\n\t\t digit,\n\t\t t,\n\t\t /** Cached calculation results */\n\t\t baseMinusT;\n\n\t\t// Handle the basic code points: let `basic` be the number of input code\n\t\t// points before the last delimiter, or `0` if there is none, then copy\n\t\t// the first basic code points to the output.\n\n\t\tbasic = input.lastIndexOf(delimiter);\n\t\tif (basic < 0) {\n\t\t\tbasic = 0;\n\t\t}\n\n\t\tfor (j = 0; j < basic; ++j) {\n\t\t\t// if it's not a basic code point\n\t\t\tif (input.charCodeAt(j) >= 0x80) {\n\t\t\t\terror('not-basic');\n\t\t\t}\n\t\t\toutput.push(input.charCodeAt(j));\n\t\t}\n\n\t\t// Main decoding loop: start just after the last delimiter if any basic code\n\t\t// points were copied; start at the beginning otherwise.\n\n\t\tfor (index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {\n\n\t\t\t// `index` is the index of the next character to be consumed.\n\t\t\t// Decode a generalized variable-length integer into `delta`,\n\t\t\t// which gets added to `i`. The overflow checking is easier\n\t\t\t// if we increase `i` as we go, then subtract off its starting\n\t\t\t// value at the end to obtain `delta`.\n\t\t\tfor (oldi = i, w = 1, k = base; /* no condition */; k += base) {\n\n\t\t\t\tif (index >= inputLength) {\n\t\t\t\t\terror('invalid-input');\n\t\t\t\t}\n\n\t\t\t\tdigit = basicToDigit(input.charCodeAt(index++));\n\n\t\t\t\tif (digit >= base || digit > floor((maxInt - i) / w)) {\n\t\t\t\t\terror('overflow');\n\t\t\t\t}\n\n\t\t\t\ti += digit * w;\n\t\t\t\tt = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);\n\n\t\t\t\tif (digit < t) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tbaseMinusT = base - t;\n\t\t\t\tif (w > floor(maxInt / baseMinusT)) {\n\t\t\t\t\terror('overflow');\n\t\t\t\t}\n\n\t\t\t\tw *= baseMinusT;\n\n\t\t\t}\n\n\t\t\tout = output.length + 1;\n\t\t\tbias = adapt(i - oldi, out, oldi == 0);\n\n\t\t\t// `i` was supposed to wrap around from `out` to `0`,\n\t\t\t// incrementing `n` each time, so we'll fix that now:\n\t\t\tif (floor(i / out) > maxInt - n) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\n\t\t\tn += floor(i / out);\n\t\t\ti %= out;\n\n\t\t\t// Insert `n` at position `i` of the output\n\t\t\toutput.splice(i++, 0, n);\n\n\t\t}\n\n\t\treturn ucs2encode(output);\n\t}\n\n\t/**\n\t * Converts a string of Unicode symbols (e.g. a domain name label) to a\n\t * Punycode string of ASCII-only symbols.\n\t * @memberOf punycode\n\t * @param {String} input The string of Unicode symbols.\n\t * @returns {String} The resulting Punycode string of ASCII-only symbols.\n\t */\n\tfunction encode(input) {\n\t\tvar n,\n\t\t delta,\n\t\t handledCPCount,\n\t\t basicLength,\n\t\t bias,\n\t\t j,\n\t\t m,\n\t\t q,\n\t\t k,\n\t\t t,\n\t\t currentValue,\n\t\t output = [],\n\t\t /** `inputLength` will hold the number of code points in `input`. */\n\t\t inputLength,\n\t\t /** Cached calculation results */\n\t\t handledCPCountPlusOne,\n\t\t baseMinusT,\n\t\t qMinusT;\n\n\t\t// Convert the input in UCS-2 to Unicode\n\t\tinput = ucs2decode(input);\n\n\t\t// Cache the length\n\t\tinputLength = input.length;\n\n\t\t// Initialize the state\n\t\tn = initialN;\n\t\tdelta = 0;\n\t\tbias = initialBias;\n\n\t\t// Handle the basic code points\n\t\tfor (j = 0; j < inputLength; ++j) {\n\t\t\tcurrentValue = input[j];\n\t\t\tif (currentValue < 0x80) {\n\t\t\t\toutput.push(stringFromCharCode(currentValue));\n\t\t\t}\n\t\t}\n\n\t\thandledCPCount = basicLength = output.length;\n\n\t\t// `handledCPCount` is the number of code points that have been handled;\n\t\t// `basicLength` is the number of basic code points.\n\n\t\t// Finish the basic string - if it is not empty - with a delimiter\n\t\tif (basicLength) {\n\t\t\toutput.push(delimiter);\n\t\t}\n\n\t\t// Main encoding loop:\n\t\twhile (handledCPCount < inputLength) {\n\n\t\t\t// All non-basic code points < n have been handled already. Find the next\n\t\t\t// larger one:\n\t\t\tfor (m = maxInt, j = 0; j < inputLength; ++j) {\n\t\t\t\tcurrentValue = input[j];\n\t\t\t\tif (currentValue >= n && currentValue < m) {\n\t\t\t\t\tm = currentValue;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,\n\t\t\t// but guard against overflow\n\t\t\thandledCPCountPlusOne = handledCPCount + 1;\n\t\t\tif (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {\n\t\t\t\terror('overflow');\n\t\t\t}\n\n\t\t\tdelta += (m - n) * handledCPCountPlusOne;\n\t\t\tn = m;\n\n\t\t\tfor (j = 0; j < inputLength; ++j) {\n\t\t\t\tcurrentValue = input[j];\n\n\t\t\t\tif (currentValue < n && ++delta > maxInt) {\n\t\t\t\t\terror('overflow');\n\t\t\t\t}\n\n\t\t\t\tif (currentValue == n) {\n\t\t\t\t\t// Represent delta as a generalized variable-length integer\n\t\t\t\t\tfor (q = delta, k = base; /* no condition */; k += base) {\n\t\t\t\t\t\tt = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);\n\t\t\t\t\t\tif (q < t) {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tqMinusT = q - t;\n\t\t\t\t\t\tbaseMinusT = base - t;\n\t\t\t\t\t\toutput.push(\n\t\t\t\t\t\t\tstringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))\n\t\t\t\t\t\t);\n\t\t\t\t\t\tq = floor(qMinusT / baseMinusT);\n\t\t\t\t\t}\n\n\t\t\t\t\toutput.push(stringFromCharCode(digitToBasic(q, 0)));\n\t\t\t\t\tbias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);\n\t\t\t\t\tdelta = 0;\n\t\t\t\t\t++handledCPCount;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t++delta;\n\t\t\t++n;\n\n\t\t}\n\t\treturn output.join('');\n\t}\n\n\t/**\n\t * Converts a Punycode string representing a domain name or an email address\n\t * to Unicode. Only the Punycoded parts of the input will be converted, i.e.\n\t * it doesn't matter if you call it on a string that has already been\n\t * converted to Unicode.\n\t * @memberOf punycode\n\t * @param {String} input The Punycoded domain name or email address to\n\t * convert to Unicode.\n\t * @returns {String} The Unicode representation of the given Punycode\n\t * string.\n\t */\n\tfunction toUnicode(input) {\n\t\treturn mapDomain(input, function(string) {\n\t\t\treturn regexPunycode.test(string)\n\t\t\t\t? decode(string.slice(4).toLowerCase())\n\t\t\t\t: string;\n\t\t});\n\t}\n\n\t/**\n\t * Converts a Unicode string representing a domain name or an email address to\n\t * Punycode. Only the non-ASCII parts of the domain name will be converted,\n\t * i.e. it doesn't matter if you call it with a domain that's already in\n\t * ASCII.\n\t * @memberOf punycode\n\t * @param {String} input The domain name or email address to convert, as a\n\t * Unicode string.\n\t * @returns {String} The Punycode representation of the given domain name or\n\t * email address.\n\t */\n\tfunction toASCII(input) {\n\t\treturn mapDomain(input, function(string) {\n\t\t\treturn regexNonASCII.test(string)\n\t\t\t\t? 'xn--' + encode(string)\n\t\t\t\t: string;\n\t\t});\n\t}\n\n\t/*--------------------------------------------------------------------------*/\n\n\t/** Define the public API */\n\tpunycode = {\n\t\t/**\n\t\t * A string representing the current Punycode.js version number.\n\t\t * @memberOf punycode\n\t\t * @type String\n\t\t */\n\t\t'version': '1.3.2',\n\t\t/**\n\t\t * An object of methods to convert from JavaScript's internal character\n\t\t * representation (UCS-2) to Unicode code points, and back.\n\t\t * @see <https://mathiasbynens.be/notes/javascript-encoding>\n\t\t * @memberOf punycode\n\t\t * @type Object\n\t\t */\n\t\t'ucs2': {\n\t\t\t'decode': ucs2decode,\n\t\t\t'encode': ucs2encode\n\t\t},\n\t\t'decode': decode,\n\t\t'encode': encode,\n\t\t'toASCII': toASCII,\n\t\t'toUnicode': toUnicode\n\t};\n\n\t/** Expose `punycode` */\n\t// Some AMD build optimizers, like r.js, check for specific condition patterns\n\t// like the following:\n\tif (\n\t\ttypeof define == 'function' &&\n\t\ttypeof define.amd == 'object' &&\n\t\tdefine.amd\n\t) {\n\t\tdefine('punycode', function() {\n\t\t\treturn punycode;\n\t\t});\n\t} else if (freeExports && freeModule) {\n\t\tif (module.exports == freeExports) { // in Node.js or RingoJS v0.8.0+\n\t\t\tfreeModule.exports = punycode;\n\t\t} else { // in Narwhal or RingoJS v0.7.0-\n\t\t\tfor (key in punycode) {\n\t\t\t\tpunycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]);\n\t\t\t}\n\t\t}\n\t} else { // in Rhino or a web browser\n\t\troot.punycode = punycode;\n\t}\n\n}(this));\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\nvar punycode = require('punycode');\nvar util = require('./util');\n\nexports.parse = urlParse;\nexports.resolve = urlResolve;\nexports.resolveObject = urlResolveObject;\nexports.format = urlFormat;\n\nexports.Url = Url;\n\nfunction Url() {\n this.protocol = null;\n this.slashes = null;\n this.auth = null;\n this.host = null;\n this.port = null;\n this.hostname = null;\n this.hash = null;\n this.search = null;\n this.query = null;\n this.pathname = null;\n this.path = null;\n this.href = null;\n}\n\n// Reference: RFC 3986, RFC 1808, RFC 2396\n\n// define these here so at least they only have to be\n// compiled once on the first module load.\nvar protocolPattern = /^([a-z0-9.+-]+:)/i,\n portPattern = /:[0-9]*$/,\n\n // Special case for a simple path URL\n simplePathPattern = /^(\\/\\/?(?!\\/)[^\\?\\s]*)(\\?[^\\s]*)?$/,\n\n // RFC 2396: characters reserved for delimiting URLs.\n // We actually just auto-escape these.\n delims = ['<', '>', '\"', '`', ' ', '\\r', '\\n', '\\t'],\n\n // RFC 2396: characters not allowed for various reasons.\n unwise = ['{', '}', '|', '\\\\', '^', '`'].concat(delims),\n\n // Allowed by RFCs, but cause of XSS attacks. Always escape these.\n autoEscape = ['\\''].concat(unwise),\n // Characters that are never ever allowed in a hostname.\n // Note that any invalid chars are also handled, but these\n // are the ones that are *expected* to be seen, so we fast-path\n // them.\n nonHostChars = ['%', '/', '?', ';', '#'].concat(autoEscape),\n hostEndingChars = ['/', '?', '#'],\n hostnameMaxLen = 255,\n hostnamePartPattern = /^[+a-z0-9A-Z_-]{0,63}$/,\n hostnamePartStart = /^([+a-z0-9A-Z_-]{0,63})(.*)$/,\n // protocols that can allow \"unsafe\" and \"unwise\" chars.\n unsafeProtocol = {\n 'javascript': true,\n 'javascript:': true\n },\n // protocols that never have a hostname.\n hostlessProtocol = {\n 'javascript': true,\n 'javascript:': true\n },\n // protocols that always contain a // bit.\n slashedProtocol = {\n 'http': true,\n 'https': true,\n 'ftp': true,\n 'gopher': true,\n 'file': true,\n 'http:': true,\n 'https:': true,\n 'ftp:': true,\n 'gopher:': true,\n 'file:': true\n },\n querystring = require('querystring');\n\nfunction urlParse(url, parseQueryString, slashesDenoteHost) {\n if (url && util.isObject(url) && url instanceof Url) return url;\n\n var u = new Url;\n u.parse(url, parseQueryString, slashesDenoteHost);\n return u;\n}\n\nUrl.prototype.parse = function(url, parseQueryString, slashesDenoteHost) {\n if (!util.isString(url)) {\n throw new TypeError(\"Parameter 'url' must be a string, not \" + typeof url);\n }\n\n // Copy chrome, IE, opera backslash-handling behavior.\n // Back slashes before the query string get converted to forward slashes\n // See: https://code.google.com/p/chromium/issues/detail?id=25916\n var queryIndex = url.indexOf('?'),\n splitter =\n (queryIndex !== -1 && queryIndex < url.indexOf('#')) ? '?' : '#',\n uSplit = url.split(splitter),\n slashRegex = /\\\\/g;\n uSplit[0] = uSplit[0].replace(slashRegex, '/');\n url = uSplit.join(splitter);\n\n var rest = url;\n\n // trim before proceeding.\n // This is to support parse stuff like \" http://foo.com \\n\"\n rest = rest.trim();\n\n if (!slashesDenoteHost && url.split('#').length === 1) {\n // Try fast path regexp\n var simplePath = simplePathPattern.exec(rest);\n if (simplePath) {\n this.path = rest;\n this.href = rest;\n this.pathname = simplePath[1];\n if (simplePath[2]) {\n this.search = simplePath[2];\n if (parseQueryString) {\n this.query = querystring.parse(this.search.substr(1));\n } else {\n this.query = this.search.substr(1);\n }\n } else if (parseQueryString) {\n this.search = '';\n this.query = {};\n }\n return this;\n }\n }\n\n var proto = protocolPattern.exec(rest);\n if (proto) {\n proto = proto[0];\n var lowerProto = proto.toLowerCase();\n this.protocol = lowerProto;\n rest = rest.substr(proto.length);\n }\n\n // figure out if it's got a host\n // user@server is *always* interpreted as a hostname, and url\n // resolution will treat //foo/bar as host=foo,path=bar because that's\n // how the browser resolves relative URLs.\n if (slashesDenoteHost || proto || rest.match(/^\\/\\/[^@\\/]+@[^@\\/]+/)) {\n var slashes = rest.substr(0, 2) === '//';\n if (slashes && !(proto && hostlessProtocol[proto])) {\n rest = rest.substr(2);\n this.slashes = true;\n }\n }\n\n if (!hostlessProtocol[proto] &&\n (slashes || (proto && !slashedProtocol[proto]))) {\n\n // there's a hostname.\n // the first instance of /, ?, ;, or # ends the host.\n //\n // If there is an @ in the hostname, then non-host chars *are* allowed\n // to the left of the last @ sign, unless some host-ending character\n // comes *before* the @-sign.\n // URLs are obnoxious.\n //\n // ex:\n // http://a@b@c/ => user:a@b host:c\n // http://a@b?@c => user:a host:c path:/?@c\n\n // v0.12 TODO(isaacs): This is not quite how Chrome does things.\n // Review our test case against browsers more comprehensively.\n\n // find the first instance of any hostEndingChars\n var hostEnd = -1;\n for (var i = 0; i < hostEndingChars.length; i++) {\n var hec = rest.indexOf(hostEndingChars[i]);\n if (hec !== -1 && (hostEnd === -1 || hec < hostEnd))\n hostEnd = hec;\n }\n\n // at this point, either we have an explicit point where the\n // auth portion cannot go past, or the last @ char is the decider.\n var auth, atSign;\n if (hostEnd === -1) {\n // atSign can be anywhere.\n atSign = rest.lastIndexOf('@');\n } else {\n // atSign must be in auth portion.\n // http://a@b/c@d => host:b auth:a path:/c@d\n atSign = rest.lastIndexOf('@', hostEnd);\n }\n\n // Now we have a portion which is definitely the auth.\n // Pull that off.\n if (atSign !== -1) {\n auth = rest.slice(0, atSign);\n rest = rest.slice(atSign + 1);\n this.auth = decodeURIComponent(auth);\n }\n\n // the host is the remaining to the left of the first non-host char\n hostEnd = -1;\n for (var i = 0; i < nonHostChars.length; i++) {\n var hec = rest.indexOf(nonHostChars[i]);\n if (hec !== -1 && (hostEnd === -1 || hec < hostEnd))\n hostEnd = hec;\n }\n // if we still have not hit it, then the entire thing is a host.\n if (hostEnd === -1)\n hostEnd = rest.length;\n\n this.host = rest.slice(0, hostEnd);\n rest = rest.slice(hostEnd);\n\n // pull out port.\n this.parseHost();\n\n // we've indicated that there is a hostname,\n // so even if it's empty, it has to be present.\n this.hostname = this.hostname || '';\n\n // if hostname begins with [ and ends with ]\n // assume that it's an IPv6 address.\n var ipv6Hostname = this.hostname[0] === '[' &&\n this.hostname[this.hostname.length - 1] === ']';\n\n // validate a little.\n if (!ipv6Hostname) {\n var hostparts = this.hostname.split(/\\./);\n for (var i = 0, l = hostparts.length; i < l; i++) {\n var part = hostparts[i];\n if (!part) continue;\n if (!part.match(hostnamePartPattern)) {\n var newpart = '';\n for (var j = 0, k = part.length; j < k; j++) {\n if (part.charCodeAt(j) > 127) {\n // we replace non-ASCII char with a temporary placeholder\n // we need this to make sure size of hostname is not\n // broken by replacing non-ASCII by nothing\n newpart += 'x';\n } else {\n newpart += part[j];\n }\n }\n // we test again with ASCII char only\n if (!newpart.match(hostnamePartPattern)) {\n var validParts = hostparts.slice(0, i);\n var notHost = hostparts.slice(i + 1);\n var bit = part.match(hostnamePartStart);\n if (bit) {\n validParts.push(bit[1]);\n notHost.unshift(bit[2]);\n }\n if (notHost.length) {\n rest = '/' + notHost.join('.') + rest;\n }\n this.hostname = validParts.join('.');\n break;\n }\n }\n }\n }\n\n if (this.hostname.length > hostnameMaxLen) {\n this.hostname = '';\n } else {\n // hostnames are always lower case.\n this.hostname = this.hostname.toLowerCase();\n }\n\n if (!ipv6Hostname) {\n // IDNA Support: Returns a punycoded representation of \"domain\".\n // It only converts parts of the domain name that\n // have non-ASCII characters, i.e. it doesn't matter if\n // you call it with a domain that already is ASCII-only.\n this.hostname = punycode.toASCII(this.hostname);\n }\n\n var p = this.port ? ':' + this.port : '';\n var h = this.hostname || '';\n this.host = h + p;\n this.href += this.host;\n\n // strip [ and ] from the hostname\n // the host field still retains them, though\n if (ipv6Hostname) {\n this.hostname = this.hostname.substr(1, this.hostname.length - 2);\n if (rest[0] !== '/') {\n rest = '/' + rest;\n }\n }\n }\n\n // now rest is set to the post-host stuff.\n // chop off any delim chars.\n if (!unsafeProtocol[lowerProto]) {\n\n // First, make 100% sure that any \"autoEscape\" chars get\n // escaped, even if encodeURIComponent doesn't think they\n // need to be.\n for (var i = 0, l = autoEscape.length; i < l; i++) {\n var ae = autoEscape[i];\n if (rest.indexOf(ae) === -1)\n continue;\n var esc = encodeURIComponent(ae);\n if (esc === ae) {\n esc = escape(ae);\n }\n rest = rest.split(ae).join(esc);\n }\n }\n\n\n // chop off from the tail first.\n var hash = rest.indexOf('#');\n if (hash !== -1) {\n // got a fragment string.\n this.hash = rest.substr(hash);\n rest = rest.slice(0, hash);\n }\n var qm = rest.indexOf('?');\n if (qm !== -1) {\n this.search = rest.substr(qm);\n this.query = rest.substr(qm + 1);\n if (parseQueryString) {\n this.query = querystring.parse(this.query);\n }\n rest = rest.slice(0, qm);\n } else if (parseQueryString) {\n // no query string, but parseQueryString still requested\n this.search = '';\n this.query = {};\n }\n if (rest) this.pathname = rest;\n if (slashedProtocol[lowerProto] &&\n this.hostname && !this.pathname) {\n this.pathname = '/';\n }\n\n //to support http.request\n if (this.pathname || this.search) {\n var p = this.pathname || '';\n var s = this.search || '';\n this.path = p + s;\n }\n\n // finally, reconstruct the href based on what has been validated.\n this.href = this.format();\n return this;\n};\n\n// format a parsed object into a url string\nfunction urlFormat(obj) {\n // ensure it's an object, and not a string url.\n // If it's an obj, this is a no-op.\n // this way, you can call url_format() on strings\n // to clean up potentially wonky urls.\n if (util.isString(obj)) obj = urlParse(obj);\n if (!(obj instanceof Url)) return Url.prototype.format.call(obj);\n return obj.format();\n}\n\nUrl.prototype.format = function() {\n var auth = this.auth || '';\n if (auth) {\n auth = encodeURIComponent(auth);\n auth = auth.replace(/%3A/i, ':');\n auth += '@';\n }\n\n var protocol = this.protocol || '',\n pathname = this.pathname || '',\n hash = this.hash || '',\n host = false,\n query = '';\n\n if (this.host) {\n host = auth + this.host;\n } else if (this.hostname) {\n host = auth + (this.hostname.indexOf(':') === -1 ?\n this.hostname :\n '[' + this.hostname + ']');\n if (this.port) {\n host += ':' + this.port;\n }\n }\n\n if (this.query &&\n util.isObject(this.query) &&\n Object.keys(this.query).length) {\n query = querystring.stringify(this.query);\n }\n\n var search = this.search || (query && ('?' + query)) || '';\n\n if (protocol && protocol.substr(-1) !== ':') protocol += ':';\n\n // only the slashedProtocols get the //. Not mailto:, xmpp:, etc.\n // unless they had them to begin with.\n if (this.slashes ||\n (!protocol || slashedProtocol[protocol]) && host !== false) {\n host = '//' + (host || '');\n if (pathname && pathname.charAt(0) !== '/') pathname = '/' + pathname;\n } else if (!host) {\n host = '';\n }\n\n if (hash && hash.charAt(0) !== '#') hash = '#' + hash;\n if (search && search.charAt(0) !== '?') search = '?' + search;\n\n pathname = pathname.replace(/[?#]/g, function(match) {\n return encodeURIComponent(match);\n });\n search = search.replace('#', '%23');\n\n return protocol + host + pathname + search + hash;\n};\n\nfunction urlResolve(source, relative) {\n return urlParse(source, false, true).resolve(relative);\n}\n\nUrl.prototype.resolve = function(relative) {\n return this.resolveObject(urlParse(relative, false, true)).format();\n};\n\nfunction urlResolveObject(source, relative) {\n if (!source) return relative;\n return urlParse(source, false, true).resolveObject(relative);\n}\n\nUrl.prototype.resolveObject = function(relative) {\n if (util.isString(relative)) {\n var rel = new Url();\n rel.parse(relative, false, true);\n relative = rel;\n }\n\n var result = new Url();\n var tkeys = Object.keys(this);\n for (var tk = 0; tk < tkeys.length; tk++) {\n var tkey = tkeys[tk];\n result[tkey] = this[tkey];\n }\n\n // hash is always overridden, no matter what.\n // even href=\"\" will remove it.\n result.hash = relative.hash;\n\n // if the relative url is empty, then there's nothing left to do here.\n if (relative.href === '') {\n result.href = result.format();\n return result;\n }\n\n // hrefs like //foo/bar always cut to the protocol.\n if (relative.slashes && !relative.protocol) {\n // take everything except the protocol from relative\n var rkeys = Object.keys(relative);\n for (var rk = 0; rk < rkeys.length; rk++) {\n var rkey = rkeys[rk];\n if (rkey !== 'protocol')\n result[rkey] = relative[rkey];\n }\n\n //urlParse appends trailing / to urls like http://www.example.com\n if (slashedProtocol[result.protocol] &&\n result.hostname && !result.pathname) {\n result.path = result.pathname = '/';\n }\n\n result.href = result.format();\n return result;\n }\n\n if (relative.protocol && relative.protocol !== result.protocol) {\n // if it's a known url protocol, then changing\n // the protocol does weird things\n // first, if it's not file:, then we MUST have a host,\n // and if there was a path\n // to begin with, then we MUST have a path.\n // if it is file:, then the host is dropped,\n // because that's known to be hostless.\n // anything else is assumed to be absolute.\n if (!slashedProtocol[relative.protocol]) {\n var keys = Object.keys(relative);\n for (var v = 0; v < keys.length; v++) {\n var k = keys[v];\n result[k] = relative[k];\n }\n result.href = result.format();\n return result;\n }\n\n result.protocol = relative.protocol;\n if (!relative.host && !hostlessProtocol[relative.protocol]) {\n var relPath = (relative.pathname || '').split('/');\n while (relPath.length && !(relative.host = relPath.shift()));\n if (!relative.host) relative.host = '';\n if (!relative.hostname) relative.hostname = '';\n if (relPath[0] !== '') relPath.unshift('');\n if (relPath.length < 2) relPath.unshift('');\n result.pathname = relPath.join('/');\n } else {\n result.pathname = relative.pathname;\n }\n result.search = relative.search;\n result.query = relative.query;\n result.host = relative.host || '';\n result.auth = relative.auth;\n result.hostname = relative.hostname || relative.host;\n result.port = relative.port;\n // to support http.request\n if (result.pathname || result.search) {\n var p = result.pathname || '';\n var s = result.search || '';\n result.path = p + s;\n }\n result.slashes = result.slashes || relative.slashes;\n result.href = result.format();\n return result;\n }\n\n var isSourceAbs = (result.pathname && result.pathname.charAt(0) === '/'),\n isRelAbs = (\n relative.host ||\n relative.pathname && relative.pathname.charAt(0) === '/'\n ),\n mustEndAbs = (isRelAbs || isSourceAbs ||\n (result.host && relative.pathname)),\n removeAllDots = mustEndAbs,\n srcPath = result.pathname && result.pathname.split('/') || [],\n relPath = relative.pathname && relative.pathname.split('/') || [],\n psychotic = result.protocol && !slashedProtocol[result.protocol];\n\n // if the url is a non-slashed url, then relative\n // links like ../.. should be able\n // to crawl up to the hostname, as well. This is strange.\n // result.protocol has already been set by now.\n // Later on, put the first path part into the host field.\n if (psychotic) {\n result.hostname = '';\n result.port = null;\n if (result.host) {\n if (srcPath[0] === '') srcPath[0] = result.host;\n else srcPath.unshift(result.host);\n }\n result.host = '';\n if (relative.protocol) {\n relative.hostname = null;\n relative.port = null;\n if (relative.host) {\n if (relPath[0] === '') relPath[0] = relative.host;\n else relPath.unshift(relative.host);\n }\n relative.host = null;\n }\n mustEndAbs = mustEndAbs && (relPath[0] === '' || srcPath[0] === '');\n }\n\n if (isRelAbs) {\n // it's absolute.\n result.host = (relative.host || relative.host === '') ?\n relative.host : result.host;\n result.hostname = (relative.hostname || relative.hostname === '') ?\n relative.hostname : result.hostname;\n result.search = relative.search;\n result.query = relative.query;\n srcPath = relPath;\n // fall through to the dot-handling below.\n } else if (relPath.length) {\n // it's relative\n // throw away the existing file, and take the new path instead.\n if (!srcPath) srcPath = [];\n srcPath.pop();\n srcPath = srcPath.concat(relPath);\n result.search = relative.search;\n result.query = relative.query;\n } else if (!util.isNullOrUndefined(relative.search)) {\n // just pull out the search.\n // like href='?foo'.\n // Put this after the other two cases because it simplifies the booleans\n if (psychotic) {\n result.hostname = result.host = srcPath.shift();\n //occationaly the auth can get stuck only in host\n //this especially happens in cases like\n //url.resolveObject('mailto:local1@domain1', 'local2@domain2')\n var authInHost = result.host && result.host.indexOf('@') > 0 ?\n result.host.split('@') : false;\n if (authInHost) {\n result.auth = authInHost.shift();\n result.host = result.hostname = authInHost.shift();\n }\n }\n result.search = relative.search;\n result.query = relative.query;\n //to support http.request\n if (!util.isNull(result.pathname) || !util.isNull(result.search)) {\n result.path = (result.pathname ? result.pathname : '') +\n (result.search ? result.search : '');\n }\n result.href = result.format();\n return result;\n }\n\n if (!srcPath.length) {\n // no path at all. easy.\n // we've already handled the other stuff above.\n result.pathname = null;\n //to support http.request\n if (result.search) {\n result.path = '/' + result.search;\n } else {\n result.path = null;\n }\n result.href = result.format();\n return result;\n }\n\n // if a url ENDs in . or .., then it must get a trailing slash.\n // however, if it ends in anything else non-slashy,\n // then it must NOT get a trailing slash.\n var last = srcPath.slice(-1)[0];\n var hasTrailingSlash = (\n (result.host || relative.host || srcPath.length > 1) &&\n (last === '.' || last === '..') || last === '');\n\n // strip single dots, resolve double dots to parent dir\n // if the path tries to go above the root, `up` ends up > 0\n var up = 0;\n for (var i = srcPath.length; i >= 0; i--) {\n last = srcPath[i];\n if (last === '.') {\n srcPath.splice(i, 1);\n } else if (last === '..') {\n srcPath.splice(i, 1);\n up++;\n } else if (up) {\n srcPath.splice(i, 1);\n up--;\n }\n }\n\n // if the path is allowed to go above the root, restore leading ..s\n if (!mustEndAbs && !removeAllDots) {\n for (; up--; up) {\n srcPath.unshift('..');\n }\n }\n\n if (mustEndAbs && srcPath[0] !== '' &&\n (!srcPath[0] || srcPath[0].charAt(0) !== '/')) {\n srcPath.unshift('');\n }\n\n if (hasTrailingSlash && (srcPath.join('/').substr(-1) !== '/')) {\n srcPath.push('');\n }\n\n var isAbsolute = srcPath[0] === '' ||\n (srcPath[0] && srcPath[0].charAt(0) === '/');\n\n // put the host back\n if (psychotic) {\n result.hostname = result.host = isAbsolute ? '' :\n srcPath.length ? srcPath.shift() : '';\n //occationaly the auth can get stuck only in host\n //this especially happens in cases like\n //url.resolveObject('mailto:local1@domain1', 'local2@domain2')\n var authInHost = result.host && result.host.indexOf('@') > 0 ?\n result.host.split('@') : false;\n if (authInHost) {\n result.auth = authInHost.shift();\n result.host = result.hostname = authInHost.shift();\n }\n }\n\n mustEndAbs = mustEndAbs || (result.host && srcPath.length);\n\n if (mustEndAbs && !isAbsolute) {\n srcPath.unshift('');\n }\n\n if (!srcPath.length) {\n result.pathname = null;\n result.path = null;\n } else {\n result.pathname = srcPath.join('/');\n }\n\n //to support request.http\n if (!util.isNull(result.pathname) || !util.isNull(result.search)) {\n result.path = (result.pathname ? result.pathname : '') +\n (result.search ? result.search : '');\n }\n result.auth = relative.auth || result.auth;\n result.slashes = result.slashes || relative.slashes;\n result.href = result.format();\n return result;\n};\n\nUrl.prototype.parseHost = function() {\n var host = this.host;\n var port = portPattern.exec(host);\n if (port) {\n port = port[0];\n if (port !== ':') {\n this.port = port.substr(1);\n }\n host = host.substr(0, host.length - port.length);\n }\n if (host) this.hostname = host;\n};\n","'use strict';\n\nmodule.exports = {\n isString: function(arg) {\n return typeof(arg) === 'string';\n },\n isObject: function(arg) {\n return typeof(arg) === 'object' && arg !== null;\n },\n isNull: function(arg) {\n return arg === null;\n },\n isNullOrUndefined: function(arg) {\n return arg == null;\n }\n};\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n// runtime helper for setting properties on components\n// in a tree-shakable way\nexports.default = (sfc, props) => {\n const target = sfc.__vccOpts || sfc;\n for (const [key, val] of props) {\n target[key] = val;\n }\n return target;\n};\n","import{ref as e,onMounted as n,onUpdated as t,openBlock as a,createElementBlock as l,renderSlot as o,createElementVNode as u,withKeys as i,withModifiers as r,inject as c,mergeProps as d,Fragment as s,renderList as p,normalizeClass as v,toDisplayString as f,createCommentVNode as g,reactive as y,toRef as m,computed as h,watchEffect as b,defineComponent as B,getCurrentInstance as I,watch as x,nextTick as w,provide as M,resolveComponent as k,createVNode as O,withCtx as F,createBlock as V,withDirectives as S,vShow as A}from\"vue\";function T(e){return(T=\"function\"==typeof Symbol&&\"symbol\"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&\"function\"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?\"symbol\":typeof e})(e)}function C(e){return function(e){if(Array.isArray(e))return N(e)}(e)||function(e){if(\"undefined\"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e[\"@@iterator\"])return Array.from(e)}(e)||D(e)||function(){throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\")}()}function D(e,n){if(e){if(\"string\"==typeof e)return N(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return\"Object\"===t&&e.constructor&&(t=e.constructor.name),\"Map\"===t||\"Set\"===t?Array.from(e):\"Arguments\"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?N(e,n):void 0}}function N(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,a=new Array(n);t<n;t++)a[t]=e[t];return a}function E(e,n){var t=\"undefined\"!=typeof Symbol&&e[Symbol.iterator]||e[\"@@iterator\"];if(!t){if(Array.isArray(e)||(t=D(e))||n&&e&&\"number\"==typeof e.length){t&&(e=t);var a=0,l=function(){};return{s:l,n:function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}},e:function(e){throw e},f:l}}throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\")}var o,u=!0,i=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return u=e.done,e},e:function(e){i=!0,o=e},f:function(){try{u||null==t.return||t.return()}finally{if(i)throw o}}}}var L={inheritAttrs:!1,name:\"vue-input\",props:{autocomplete:{required:!1,type:String},modelValue:{required:!0,type:String},placeholder:{required:!0,type:String},disabled:{required:!0,type:Boolean},tabindex:{required:!0,type:Number},autofocus:{required:!0,type:Boolean},comboboxUid:{required:!0,type:Number}},emits:[\"update:modelValue\",\"input\",\"change\",\"focus\",\"blur\",\"escape\"],setup:function(a,l){var o=e(null);return n((function(){a.autofocus&&o.value.focus()})),t((function(){a.autofocus&&o.value.focus()})),{handleInput:function(e){l.emit(\"input\",e),l.emit(\"update:modelValue\",e.target.value)},handleChange:function(e){l.emit(\"change\",e),l.emit(\"update:modelValue\",e.target.value)},handleFocus:function(e){l.emit(\"focus\",e)},handleBlur:function(e){l.emit(\"blur\",e)},input:o,handleEscape:function(e){o.value.blur(),l.emit(\"escape\",e)}}}},j={class:\"vue-input\"},$=[\"autocomplete\",\"modelValue\",\"placeholder\",\"disabled\",\"tabindex\",\"autofocus\",\"aria-controls\",\"aria-labelledby\"];L.render=function(e,n,t,c,d,s){return a(),l(\"div\",j,[o(e.$slots,\"prepend\"),u(\"input\",{ref:\"input\",autocomplete:t.autocomplete,modelValue:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,onInput:n[0]||(n[0]=function(){return c.handleInput&&c.handleInput.apply(c,arguments)}),onChange:n[1]||(n[1]=function(){return c.handleChange&&c.handleChange.apply(c,arguments)}),onFocus:n[2]||(n[2]=function(){return c.handleFocus&&c.handleFocus.apply(c,arguments)}),onBlur:n[3]||(n[3]=function(){return c.handleBlur&&c.handleBlur.apply(c,arguments)}),onKeyup:n[4]||(n[4]=i(r((function(){return c.handleEscape&&c.handleEscape.apply(c,arguments)}),[\"exact\"]),[\"esc\"])),tabindex:t.tabindex,autofocus:t.autofocus,\"aria-autocomplete\":\"list\",\"aria-controls\":\"vs\".concat(t.comboboxUid,\"-listbox\"),\"aria-labelledby\":\"vs\".concat(t.comboboxUid,\"-combobox\")},null,40,$),o(e.$slots,\"append\")])},L.__file=\"src/components/input.vue\";var U={inheritAttrs:!1,name:\"vue-tags\",props:{modelValue:{required:!0,type:Array,validator:function(e){return e.every((function(e){return void 0!==T(e.key)&&void 0!==e.label&&\"boolean\"==typeof e.selected}))}},collapseTags:{type:Boolean}},emits:[\"click\"],setup:function(e,n){return{dataAttrs:c(\"dataAttrs\"),handleClick:function(e){n.emit(\"click\",e)}}}};U.render=function(e,n,t,i,c,y){return a(),l(\"ul\",d({class:[\"vue-tags\",{collapsed:t.collapseTags}],onMousedown:n[0]||(n[0]=r((function(){}),[\"prevent\"])),tabindex:\"-1\",onClick:n[1]||(n[1]=function(){return i.handleClick&&i.handleClick.apply(i,arguments)})},i.dataAttrs),[(a(!0),l(s,null,p(t.modelValue,(function(n){return a(),l(s,{key:n.key},[n.group?g(\"v-if\",!0):(a(),l(\"li\",{key:0,class:v([\"vue-tag\",{selected:n.selected}])},[o(e.$slots,\"default\",{option:n},(function(){return[u(\"span\",null,f(n.label),1)]}))],2))],64)})),128))],16)},U.__file=\"src/components/tags.vue\";var z={inheritAttrs:!1,name:\"vue-dropdown\",props:{modelValue:{required:!0,type:Array,validator:function(e){return e.every((function(e){return void 0!==T(e.key)&&void 0!==e.label&&\"boolean\"==typeof e.selected}))}},comboboxUid:{required:!0,type:Number},maxHeight:{required:!0},highlightedOriginalIndex:{required:!0}},emits:[\"click-item\",\"mouseenter\"],setup:function(e,n){return{dataAttrs:c(\"dataAttrs\"),handleClickItem:function(e,t){t.disabled||n.emit(\"click-item\",e,t)},handleMouseenter:function(e,t){n.emit(\"mouseenter\",e,t)}}}},P=[\"id\",\"aria-multiselectable\",\"aria-busy\",\"aria-disabled\"],q=[\"onClick\",\"onMouseenter\",\"id\",\"aria-selected\",\"aria-disabled\"];z.render=function(e,n,t,i,c,y){return a(),l(\"ul\",d({class:\"vue-dropdown\",style:{maxHeight:t.maxHeight+\"px\"},onMousedown:n[0]||(n[0]=r((function(){}),[\"prevent\"]))},i.dataAttrs,{role:\"listbox\",id:\"vs\".concat(t.comboboxUid,\"-listbox\"),\"aria-multiselectable\":i.dataAttrs[\"data-multiple\"],\"aria-busy\":i.dataAttrs[\"data-loading\"],\"aria-disabled\":i.dataAttrs[\"data-disabled\"]}),[(a(!0),l(s,null,p(t.modelValue,(function(n,r){return a(),l(s,{key:n.key},[n.visible&&!1===n.hidden?(a(),l(\"li\",{key:0,onClick:function(e){return i.handleClickItem(e,n)},class:v([\"vue-dropdown-item\",{selected:n.selected,disabled:n.disabled,highlighted:n.originalIndex===t.highlightedOriginalIndex,group:n.group}]),onMouseenter:function(e){return i.handleMouseenter(e,n)},role:\"option\",id:\"vs\".concat(t.comboboxUid,\"-option-\").concat(r),\"aria-selected\":!!n.selected||!!n.disabled&&void 0,\"aria-disabled\":n.disabled},[o(e.$slots,\"default\",{option:n},(function(){return[u(\"span\",null,f(n.label),1)]}))],42,q)):g(\"v-if\",!0)],64)})),128))],16,P)},z.__file=\"src/components/dropdown.vue\";var H=function(e,n,t){var a=t.valueBy;return a(e)===a(n)},_=function(e,n,t){var a=t.valueBy;return e.some((function(e){return H(e,n,{valueBy:a})}))},W=function(e,n,t){var a=t.valueBy;return e.find((function(e){return a(e)===n}))},Z=function(e,n,t){var a=t.max,l=t.valueBy;return _(e,n,{valueBy:l})||e.length>=a?e:e.concat(n)},R=function(e,n,t){var a=t.min,l=t.valueBy;return!1===_(e,n,{valueBy:l})||e.length<=a?e:e.filter((function(e){return!1===H(e,n,{valueBy:l})}))},G=function(e){return h((function(){return\"function\"==typeof e.value?e.value:\"string\"==typeof e.value?function(n){return e.value.split(\".\").reduce((function(e,n){return e[n]}),n)}:function(e){return e}}))},Q=function(e,n){var t=h((function(){return e.value.reduce((function(e,n){return Object.assign(e,(t={},a=n.originalIndex,l=n,a in t?Object.defineProperty(t,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):t[a]=l,t));var t,a,l}),{})})),a=function(e){var a=t.value[e];return void 0!==a&&(!1!==l(a)&&(n.value=e,!0))},l=function(e){return!e.disabled&&!e.hidden&&e.visible},o=h((function(){return e.value.some((function(e){return l(e)}))}));return b((function(){if(!1===o.value&&(n.value=null),null!==n.value&&e.value.length<=n.value){var t,u=E(e.value.reverse());try{for(u.s();!(t=u.n()).done;){var i=t.value;if(a(i.originalIndex))break}}catch(e){u.e(e)}finally{u.f()}}if(null===n.value||!1===l(e.value[n.value])){var r,c=E(e.value);try{for(c.s();!(r=c.n()).done;){var d=r.value;if(a(d.originalIndex))break}}catch(e){c.e(e)}finally{c.f()}}})),{pointerForward:function(){if(!1!==o.value&&null!==n.value)for(var t=n.value+1,l=0;t!==n.value&&l++<e.value.length&&(e.value.length<=t&&(t=0),!a(t));)++t},pointerBackward:function(){if(!1!==o.value&&null!==n.value)for(var t=n.value-1,l=0;t!==n.value&&l++<e.value.length&&(t<0&&(t=e.value.length-1),!a(t));)--t},pointerSet:a}};var Y=B({name:\"vue-select\",inheritAttrs:!1,props:{modelValue:{required:!0},emptyModelValue:{},options:{required:!0,type:Array},labelBy:{type:[String,Function]},valueBy:{type:[String,Function]},disabledBy:{default:\"disabled\",type:[String,Function]},groupBy:{default:\"group\",type:[String,Function]},visibleOptions:{type:Array,default:null},multiple:{default:!1,type:Boolean},min:{default:0,type:Number},max:{default:1/0,type:Number},searchable:{default:!1,type:Boolean},searchPlaceholder:{default:\"Type to search\",type:String},clearOnSelect:{default:!1,type:Boolean},clearOnClose:{default:!1,type:Boolean},taggable:{default:!1,type:Boolean},collapseTags:{default:!1,type:Boolean},autocomplete:{default:\"off\",type:String},disabled:{default:!1,type:Boolean},loading:{default:!1,type:Boolean},closeOnSelect:{default:!1,type:Boolean},hideSelected:{default:!1,type:Boolean},placeholder:{default:\"Select option\",type:String},tabindex:{default:0,type:Number},autofocus:{default:!1,type:Boolean},maxHeight:{default:300,type:Number},openDirection:{type:String,validator:function(e){return[\"top\",\"bottom\"].includes(e)}}},emits:[\"selected\",\"removed\",\"update:modelValue\",\"focus\",\"blur\",\"toggle\",\"opened\",\"closed\",\"search:input\",\"search:change\",\"search:focus\",\"search:blur\"],setup:function(n,t){var a=function(e){var n=y({}),t=G(m(e,\"labelBy\"));b((function(){return n.labelBy=t.value}));var a=G(m(e,\"valueBy\"));b((function(){return n.valueBy=a.value}));var l=G(m(e,\"disabledBy\"));b((function(){return n.disabledBy=l.value}));var o=G(m(e,\"groupBy\"));b((function(){return n.groupBy=o.value}));var u=h((function(){return e.multiple?e.min:Math.min(1,e.min)}));b((function(){return n.min=u.value}));var i=h((function(){return e.multiple?e.max:1}));return b((function(){return n.max=i.value})),b((function(){return n.options=e.options})),n}(n),l=h((function(){var e;return null!==(e=n.emptyModelValue)&&void 0!==e?e:null})),o=I(),u=e(),i=e(),r=e(),c=h((function(){var e;return null===(e=r.value)||void 0===e?void 0:e._.refs.input})),d=e(!1);x((function(){return d.value}),(function(){d.value?(t.emit(\"opened\"),t.emit(\"focus\"),n.searchable?(c.value!==document.activeElement&&c.value.focus(),t.emit(\"search:focus\")):u.value.focus()):(n.searchable?(c.value===document.activeElement&&c.value.blur(),n.clearOnClose&&D(),t.emit(\"search:blur\")):u.value.blur(),t.emit(\"closed\"),t.emit(\"blur\")),t.emit(\"toggle\")}));var s=function(){n.disabled||(d.value=!0)},p=function(e){u.value.contains(null==e?void 0:e.relatedTarget)?setTimeout((function(){u.value.focus()})):d.value=!1};x((function(){return n.disabled}),(function(){return p()}));var v=e(\"\"),f=h((function(){return new RegExp(v.value.replace(/[.*+?^${}()|[\\]\\\\]/g,\"\\\\$&\"),\"i\")})),g=h((function(){return v.value?a.options.filter((function(e){return f.value.test(a.labelBy(e))})):void 0})),B=e([]),k=h((function(){return new Set(B.value.map((function(e){return a.valueBy(e)})))})),O=function(){if(n.multiple){if(!1===Array.isArray(n.modelValue))return!1;if(B.value.length!==n.modelValue.length)return!1;if(Object.keys(B.value).some((function(e){return B.value[e]!==W(a.options,n.modelValue[e],{valueBy:a.valueBy})})))return!1}else{if(0===B.value.length&&n.modelValue!==l.value)return!1;if(1===B.value.length&&n.modelValue===l.value)return!1;if(B.value[0]!==W(a.options,n.modelValue,{valueBy:a.valueBy}))return!1}return!0},F=function(){if(!O()){B.value=[];var e,t=E(n.multiple?n.modelValue:n.modelValue===l.value?[]:[n.modelValue]);try{for(t.s();!(e=t.n()).done;){var o=e.value,u=W(a.options,o,{valueBy:a.valueBy});!1!==_(a.options,u,{valueBy:a.valueBy})&&(B.value=Z(B.value,u,{max:1/0,valueBy:a.valueBy}))}}catch(e){t.e(e)}finally{t.f()}}};F(),x((function(){return n.modelValue}),(function(){return F()}),{deep:!0}),x((function(){return a.options}),(function(){B.value=a.options.filter((function(e){return k.value.has(a.valueBy(e))}))}),{deep:!0});var V,S=function(e,n){(n=n.originalOption).value.every((function(e){var n=W(a.options,e,{valueBy:a.valueBy});return _(B.value,n,{valueBy:a.valueBy})}))?n.value.forEach((function(e){var n=W(a.options,e,{valueBy:a.valueBy});B.value=R(B.value,n,{min:a.min,valueBy:a.valueBy}),t.emit(\"removed\",n)})):n.value.forEach((function(e){var n=W(a.options,e,{valueBy:a.valueBy});_(B.value,n,{valueBy:a.valueBy})||(B.value=Z(B.value,n,{max:a.max,valueBy:a.valueBy}),t.emit(\"selected\",n))}))},A=function(e,l){if(l=l.originalOption,_(B.value,l,{valueBy:a.valueBy}))B.value=R(B.value,l,{min:a.min,valueBy:a.valueBy}),t.emit(\"removed\",l);else{if(!n.multiple&&1===B.value.length){var o=B.value[0];B.value=R(B.value,B.value[0],{min:0,valueBy:a.valueBy}),t.emit(\"removed\",o)}B.value=Z(B.value,l,{max:a.max,valueBy:a.valueBy}),t.emit(\"selected\",l)}},T=function(){if(!O()){var e=B.value.map((function(e){return a.valueBy(e)}));n.multiple?t.emit(\"update:modelValue\",e):e.length?t.emit(\"update:modelValue\",e[0]):t.emit(\"update:modelValue\",l.value)}},D=function(){c.value.value=\"\",c.value.dispatchEvent(new Event(\"input\")),c.value.dispatchEvent(new Event(\"change\"))},N=h((function(){var e,t;return null!==(t=null!==(e=n.visibleOptions)&&void 0!==e?e:g.value)&&void 0!==t?t:a.options})),L=e(0),j=h((function(){var e,t=new Set(N.value.map((function(e){return a.valueBy(e)}))),l=a.options.map((function(e,l){var o,u={key:a.valueBy(e),label:a.labelBy(e),group:null!==(o=a.groupBy(e))&&void 0!==o&&o,originalIndex:l,originalOption:e};return u.selected=u.group?e.value.every((function(e){return k.value.has(e)})):k.value.has(a.valueBy(e)),u.disabled=u.group?a.disabledBy(e)||e.value.every((function(e){var n=W(a.options,e,{valueBy:a.valueBy});return a.disabledBy(n)})):a.disabledBy(e),u.visible=u.group?e.value.some((function(e){return t.has(e)})):t.has(a.valueBy(e)),u.hidden=!!n.hideSelected&&(u.group?e.value.every((function(e){return k.value.has(e)})):k.value.has(a.valueBy(e))),u})),o=E(l);try{for(o.s();!(e=o.n()).done;){var u=e.value;!1!==u.group&&(u.disabled&&function(){var e=new Set(u.originalOption.value);l.filter((function(n){return e.has(a.valueBy(n.originalOption))})).forEach((function(e){return e.disabled=!0}))}())}}catch(e){o.e(e)}finally{o.f()}return l})),$=Q(j,L),U=$.pointerForward,z=$.pointerBackward,P=$.pointerSet,q=\"\",H=/^[\\w]$/,Y=h((function(){var e=C(a.options.keys());return e.slice(L.value).concat(e.slice(0,L.value))})),K=function(){var e,n=null===(e=u.value)||void 0===e?void 0:e.querySelector(\".highlighted\");if(n&&i.value){var t,a=getComputedStyle(n);for(t=0;n.offsetTop+parseFloat(a.height)+parseFloat(a.paddingTop)+parseFloat(a.paddingBottom)>i.value.$el.clientHeight+i.value.$el.scrollTop&&t++<j.value.length;)i.value.$el.scrollTop=i.value.$el.scrollTop+parseFloat(a.height)+parseFloat(a.paddingTop)+parseFloat(a.paddingBottom);for(t=0;n.offsetTop<i.value.$el.scrollTop&&t++<j.value.length;)i.value.$el.scrollTop=i.value.$el.scrollTop-parseFloat(a.height)-parseFloat(a.paddingTop)-parseFloat(a.paddingBottom)}};x((function(){return[d.value,a.options,k.value]}),(function(e,n){!0!==(null==n?void 0:n[0])&&!1!==d.value&&0!==B.value.length&&(P(a.options.findIndex((function(e){return k.value.has(a.valueBy(e))}))),w(K))}),{deep:!0,immediate:!0});var J=h((function(){return{\"data-is-focusing\":d.value,\"data-visible-length\":j.value.filter((function(e){return e.visible&&!1===e.hidden})).length,\"data-not-selected-length\":a.options.length-j.value.filter((function(e){return e.selected})).length,\"data-selected-length\":j.value.filter((function(e){return e.selected})).length,\"data-addable\":j.value.filter((function(e){return e.selected})).length<a.max,\"data-removable\":j.value.filter((function(e){return e.selected})).length>a.min,\"data-total-length\":a.options.length,\"data-multiple\":n.multiple,\"data-loading\":n.loading,\"data-disabled\":n.disabled}}));M(\"dataAttrs\",J);var X=h((function(){return j.value.filter((function(e){return e.selected})).filter((function(e){return!e.group}))})),ee=h((function(){return n.multiple?0===X.value.length?n.placeholder:1===X.value.length?\"1 option selected\":X.value.length+\" options selected\":0===X.value.length?n.placeholder:X.value[0].label+\"\"})),ne=h((function(){var e=X.value.map((function(e){return e.originalOption}));return n.multiple?e:e[0]||l.value})),te=e();return x((function(){return[n.openDirection,d.value]}),(function(){var e,t;te.value=null!==(t=null!==(e=n.openDirection)&&void 0!==e?e:function(){if(void 0===u.value)return;if(void 0===window)return;return window.innerHeight-u.value.getBoundingClientRect().bottom>=n.maxHeight?\"bottom\":\"top\"}())&&void 0!==t?t:\"bottom\"}),{immediate:!0}),{instance:o,isFocusing:d,wrapper:u,dropdown:i,input:r,focus:s,blur:p,toggle:function(){d.value?p():s()},searchingInputValue:v,handleInputForInput:function(e){t.emit(\"search:input\",e)},handleChangeForInput:function(e){t.emit(\"search:change\",e)},handleFocusForInput:function(e){s()},handleBlurForInput:function(e){p()},optionsWithInfo:j,addOrRemoveOption:function(e,t){n.disabled||(t.group&&n.multiple?S(e,t):A(e,t),T(),!0===n.closeOnSelect&&(d.value=!1),!0===n.clearOnSelect&&v.value&&D())},dataAttrs:J,innerPlaceholder:ee,selected:ne,highlightedOriginalIndex:L,pointerForward:function(){U(),w(K)},pointerBackward:function(){z(),w(K)},pointerFirst:function(){var e,n=E(a.options.keys());try{for(n.s();!(e=n.n()).done;){var t=e.value;if(P(t))break}}catch(e){n.e(e)}finally{n.f()}w(K)},pointerLast:function(){var e,n=E(C(a.options.keys()).reverse());try{for(n.s();!(e=n.n()).done;){var t=e.value;if(P(t))break}}catch(e){n.e(e)}finally{n.f()}w(K)},typeAhead:function(e){var t,l;if(!n.searchable){var o=!1;if(H.test(e.key)?(q+=e.key.toLowerCase(),o=!0):\"Space\"===e.code&&(q+=\" \"),o){var u,i=E(Y.value);try{for(i.s();!(u=i.n()).done;){var r=u.value;if(!0===(null===(l=null===(t=a.labelBy(a.options[r]))||void 0===t?void 0:t.toLowerCase())||void 0===l?void 0:l.startsWith(q))&&P(r))break}}catch(e){i.e(e)}finally{i.f()}clearTimeout(V),V=setTimeout((function(){q=\"\"}),500)}}},pointerSet:P,direction:te}},components:{VInput:L,VTags:U,VDropdown:z}});Y.__VERSION__=\"2.10.2\";var K=[\"tabindex\",\"id\",\"role\",\"aria-expanded\",\"aria-owns\",\"aria-activedescendant\",\"aria-busy\",\"aria-disabled\"],J={ref:\"header\",class:\"vue-select-header\"},X={key:0,class:\"vue-input\"},ee=[\"placeholder\",\"autocomplete\"],ne=[\"onClick\"],te=u(\"span\",{class:\"icon loading\"},[u(\"div\"),u(\"div\"),u(\"div\")],-1),ae={key:0,class:\"vue-select-input-wrapper\"},le=u(\"span\",{class:\"icon loading\"},[u(\"div\"),u(\"div\"),u(\"div\")],-1);Y.render=function(e,n,t,c,p,y){var m=k(\"v-tags\"),h=k(\"v-input\"),b=k(\"v-dropdown\");return a(),l(\"div\",d({ref:\"wrapper\",class:[\"vue-select\",[\"direction-\".concat(e.direction)]],tabindex:e.isFocusing?-1:e.tabindex,onFocus:n[9]||(n[9]=function(){return e.focus&&e.focus.apply(e,arguments)}),onBlur:n[10]||(n[10]=function(n){return!e.searchable&&e.blur(n)})},Object.assign({},e.dataAttrs,e.$attrs),{onKeypress:n[11]||(n[11]=i(r((function(){return null!==e.highlightedOriginalIndex&&e.addOrRemoveOption(e.$event,e.optionsWithInfo[e.highlightedOriginalIndex])}),[\"prevent\",\"exact\"]),[\"enter\"])),onKeydown:[n[12]||(n[12]=i(r((function(){return e.pointerForward&&e.pointerForward.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"down\"])),n[13]||(n[13]=i(r((function(){return e.pointerBackward&&e.pointerBackward.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"up\"])),n[14]||(n[14]=i(r((function(){return e.pointerFirst&&e.pointerFirst.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"home\"])),n[15]||(n[15]=i(r((function(){return e.pointerLast&&e.pointerLast.apply(e,arguments)}),[\"prevent\",\"exact\"]),[\"end\"])),n[16]||(n[16]=function(){return e.typeAhead&&e.typeAhead.apply(e,arguments)})],id:\"vs\".concat(e.instance.uid,\"-combobox\"),role:e.searchable?\"combobox\":null,\"aria-expanded\":e.isFocusing,\"aria-haspopup\":\"listbox\",\"aria-owns\":\"vs\".concat(e.instance.uid,\"-listbox\"),\"aria-activedescendant\":null===e.highlightedOriginalIndex?null:\"vs\".concat(e.instance.uid,\"-option-\").concat(e.highlightedOriginalIndex),\"aria-busy\":e.loading,\"aria-disabled\":e.disabled}),[u(\"div\",J,[e.multiple&&e.taggable&&0===e.modelValue.length||!1===e.searchable&&!1===e.taggable?(a(),l(\"div\",X,[o(e.$slots,\"label\",{selected:e.selected},(function(){return[u(\"input\",{placeholder:e.innerPlaceholder,autocomplete:e.autocomplete,readonly:\"\",onClick:n[0]||(n[0]=function(){return e.focus&&e.focus.apply(e,arguments)})},null,8,ee)]}))])):g(\"v-if\",!0),e.multiple&&e.taggable?(a(),l(s,{key:1},[O(m,{modelValue:e.optionsWithInfo,\"collapse-tags\":e.collapseTags,tabindex:\"-1\",onClick:e.focus},{default:F((function(n){var t=n.option;return[o(e.$slots,\"tag\",{option:t.originalOption,remove:function(){return e.addOrRemoveOption(e.$event,t)}},(function(){return[u(\"span\",null,f(t.label),1),u(\"img\",{src:\"data:image/svg+xml;base64,PHN2ZyBpZD0iZGVsZXRlIiBkYXRhLW5hbWU9ImRlbGV0ZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgNTEyIDUxMiI+PHRpdGxlPmRlbGV0ZTwvdGl0bGU+PHBhdGggZD0iTTI1NiwyNEMzODMuOSwyNCw0ODgsMTI4LjEsNDg4LDI1NlMzODMuOSw0ODgsMjU2LDQ4OCwyNC4wNiwzODMuOSwyNC4wNiwyNTYsMTI4LjEsMjQsMjU2LDI0Wk0wLDI1NkMwLDM5Ny4xNiwxMTQuODQsNTEyLDI1Niw1MTJTNTEyLDM5Ny4xNiw1MTIsMjU2LDM5Ny4xNiwwLDI1NiwwLDAsMTE0Ljg0LDAsMjU2WiIgZmlsbD0iIzViNWI1ZiIvPjxwb2x5Z29uIHBvaW50cz0iMzgyIDE3Mi43MiAzMzkuMjkgMTMwLjAxIDI1NiAyMTMuMjkgMTcyLjcyIDEzMC4wMSAxMzAuMDEgMTcyLjcyIDIxMy4yOSAyNTYgMTMwLjAxIDMzOS4yOCAxNzIuNzIgMzgyIDI1NiAyOTguNzEgMzM5LjI5IDM4MS45OSAzODIgMzM5LjI4IDI5OC43MSAyNTYgMzgyIDE3Mi43MiIgZmlsbD0iIzViNWI1ZiIvPjwvc3ZnPg==\",alt:\"delete tag\",class:\"icon delete\",onClick:r((function(){return e.addOrRemoveOption(e.$event,t)}),[\"prevent\",\"stop\"])},null,8,ne)]}))]})),_:3},8,[\"modelValue\",\"collapse-tags\",\"onClick\"]),o(e.$slots,\"toggle\",{isFocusing:e.isFocusing,toggle:e.toggle},(function(){return[u(\"span\",{class:v([\"icon arrow-downward\",{active:e.isFocusing}]),onClick:n[1]||(n[1]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),onMousedown:n[2]||(n[2]=r((function(){}),[\"prevent\",\"stop\"]))},null,34)]}))],64)):(a(),l(s,{key:2},[e.searchable?(a(),V(h,{key:0,ref:\"input\",modelValue:e.searchingInputValue,\"onUpdate:modelValue\":n[3]||(n[3]=function(n){return e.searchingInputValue=n}),disabled:e.disabled,autocomplete:e.autocomplete,placeholder:e.isFocusing?e.searchPlaceholder:e.innerPlaceholder,onInput:e.handleInputForInput,onChange:e.handleChangeForInput,onFocus:e.handleFocusForInput,onBlur:e.handleBlurForInput,onEscape:e.blur,autofocus:e.autofocus||e.taggable&&e.searchable,tabindex:e.tabindex,comboboxUid:e.instance.uid},null,8,[\"modelValue\",\"disabled\",\"autocomplete\",\"placeholder\",\"onInput\",\"onChange\",\"onFocus\",\"onBlur\",\"onEscape\",\"autofocus\",\"tabindex\",\"comboboxUid\"])):g(\"v-if\",!0),e.loading?o(e.$slots,\"loading\",{key:1},(function(){return[te]})):o(e.$slots,\"toggle\",{key:2,isFocusing:e.isFocusing,toggle:e.toggle},(function(){return[u(\"span\",{class:v([\"icon arrow-downward\",{active:e.isFocusing}]),onClick:n[4]||(n[4]=function(){return e.toggle&&e.toggle.apply(e,arguments)}),onMousedown:n[5]||(n[5]=r((function(){}),[\"prevent\",\"stop\"]))},null,34)]}))],64))],512),e.multiple&&e.taggable&&e.searchable?(a(),l(\"div\",ae,[S(O(h,{ref:\"input\",modelValue:e.searchingInputValue,\"onUpdate:modelValue\":n[6]||(n[6]=function(n){return e.searchingInputValue=n}),disabled:e.disabled,autocomplete:e.autocomplete,placeholder:e.isFocusing?e.searchPlaceholder:e.innerPlaceholder,onInput:e.handleInputForInput,onChange:e.handleChangeForInput,onFocus:e.handleFocusForInput,onBlur:e.handleBlurForInput,onEscape:e.blur,autofocus:e.autofocus||e.taggable&&e.searchable,tabindex:e.tabindex,comboboxUid:e.instance.uid},null,8,[\"modelValue\",\"disabled\",\"autocomplete\",\"placeholder\",\"onInput\",\"onChange\",\"onFocus\",\"onBlur\",\"onEscape\",\"autofocus\",\"tabindex\",\"comboboxUid\"]),[[A,e.isFocusing]]),e.loading?o(e.$slots,\"loading\",{key:0},(function(){return[le]})):g(\"v-if\",!0)])):g(\"v-if\",!0),O(b,{ref:\"dropdown\",modelValue:e.optionsWithInfo,\"onUpdate:modelValue\":n[7]||(n[7]=function(n){return e.optionsWithInfo=n}),onClickItem:e.addOrRemoveOption,onMouseenter:n[8]||(n[8]=function(n,t){return e.pointerSet(t.originalIndex)}),comboboxUid:e.instance.uid,maxHeight:e.maxHeight,highlightedOriginalIndex:e.highlightedOriginalIndex},{default:F((function(n){var t=n.option;return[o(e.$slots,\"dropdown-item\",{option:t.originalOption},(function(){return[u(\"span\",null,f(t.label),1)]}))]})),_:3},8,[\"modelValue\",\"onClickItem\",\"comboboxUid\",\"maxHeight\",\"highlightedOriginalIndex\"])],16,K)},Y.__file=\"src/index.vue\";export{Y as default};\n","/*!\n * vue-textarea-autosize v1.1.1 \n * (c) 2019 Saymon\n * Released under the MIT License.\n */\n//\n//\n//\n//\n//\n//\n//\nvar script = {\n name: 'TextareaAutosize',\n props: {\n value: {\n type: [String, Number],\n default: ''\n },\n autosize: {\n type: Boolean,\n default: true\n },\n minHeight: {\n type: [Number],\n 'default': null\n },\n maxHeight: {\n type: [Number],\n 'default': null\n },\n\n /*\n * Force !important for style properties\n */\n important: {\n type: [Boolean, Array],\n default: false\n }\n },\n data: function data() {\n return {\n // data property for v-model binding with real textarea tag\n val: null,\n // works when content height becomes more then value of the maxHeight property\n maxHeightScroll: false,\n height: 'auto'\n };\n },\n computed: {\n computedStyles: function computedStyles() {\n if (!this.autosize) return {};\n return {\n resize: !this.isResizeImportant ? 'none' : 'none !important',\n height: this.height,\n overflow: this.maxHeightScroll ? 'auto' : !this.isOverflowImportant ? 'hidden' : 'hidden !important'\n };\n },\n isResizeImportant: function isResizeImportant() {\n var imp = this.important;\n return imp === true || Array.isArray(imp) && imp.includes('resize');\n },\n isOverflowImportant: function isOverflowImportant() {\n var imp = this.important;\n return imp === true || Array.isArray(imp) && imp.includes('overflow');\n },\n isHeightImportant: function isHeightImportant() {\n var imp = this.important;\n return imp === true || Array.isArray(imp) && imp.includes('height');\n }\n },\n watch: {\n value: function value(val) {\n this.val = val;\n },\n val: function val(_val) {\n this.$nextTick(this.resize);\n this.$emit('input', _val);\n },\n minHeight: function minHeight() {\n this.$nextTick(this.resize);\n },\n maxHeight: function maxHeight() {\n this.$nextTick(this.resize);\n },\n autosize: function autosize(val) {\n if (val) this.resize();\n }\n },\n methods: {\n resize: function resize() {\n var _this = this;\n\n var important = this.isHeightImportant ? 'important' : '';\n this.height = \"auto\".concat(important ? ' !important' : '');\n this.$nextTick(function () {\n var contentHeight = _this.$el.scrollHeight + 1;\n\n if (_this.minHeight) {\n contentHeight = contentHeight < _this.minHeight ? _this.minHeight : contentHeight;\n }\n\n if (_this.maxHeight) {\n if (contentHeight > _this.maxHeight) {\n contentHeight = _this.maxHeight;\n _this.maxHeightScroll = true;\n } else {\n _this.maxHeightScroll = false;\n }\n }\n\n var heightVal = contentHeight + 'px';\n _this.height = \"\".concat(heightVal).concat(important ? ' !important' : '');\n });\n return this;\n }\n },\n created: function created() {\n this.val = this.value;\n },\n mounted: function mounted() {\n this.resize();\n }\n};\n\nfunction normalizeComponent(template, style, script, scopeId, isFunctionalTemplate, moduleIdentifier\n/* server only */\n, shadowMode, createInjector, createInjectorSSR, createInjectorShadow) {\n if (typeof shadowMode !== 'boolean') {\n createInjectorSSR = createInjector;\n createInjector = shadowMode;\n shadowMode = false;\n } // Vue.extend constructor export interop.\n\n\n var options = typeof script === 'function' ? script.options : script; // render functions\n\n if (template && template.render) {\n options.render = template.render;\n options.staticRenderFns = template.staticRenderFns;\n options._compiled = true; // functional template\n\n if (isFunctionalTemplate) {\n options.functional = true;\n }\n } // scopedId\n\n\n if (scopeId) {\n options._scopeId = scopeId;\n }\n\n var hook;\n\n if (moduleIdentifier) {\n // server build\n hook = function hook(context) {\n // 2.3 injection\n context = context || // cached call\n this.$vnode && this.$vnode.ssrContext || // stateful\n this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext; // functional\n // 2.2 with runInNewContext: true\n\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__;\n } // inject component styles\n\n\n if (style) {\n style.call(this, createInjectorSSR(context));\n } // register component module identifier for async chunk inference\n\n\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier);\n }\n }; // used by ssr in case component is cached and beforeCreate\n // never gets called\n\n\n options._ssrRegister = hook;\n } else if (style) {\n hook = shadowMode ? function () {\n style.call(this, createInjectorShadow(this.$root.$options.shadowRoot));\n } : function (context) {\n style.call(this, createInjector(context));\n };\n }\n\n if (hook) {\n if (options.functional) {\n // register for functional component in vue file\n var originalRender = options.render;\n\n options.render = function renderWithStyleInjection(h, context) {\n hook.call(context);\n return originalRender(h, context);\n };\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate;\n options.beforeCreate = existing ? [].concat(existing, hook) : [hook];\n }\n }\n\n return script;\n}\n\nvar normalizeComponent_1 = normalizeComponent;\n\n/* script */\nconst __vue_script__ = script;\n\n/* template */\nvar __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('textarea',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.val),expression:\"val\"}],style:(_vm.computedStyles),domProps:{\"value\":(_vm.val)},on:{\"focus\":_vm.resize,\"input\":function($event){if($event.target.composing){ return; }_vm.val=$event.target.value;}}})};\nvar __vue_staticRenderFns__ = [];\n\n /* style */\n const __vue_inject_styles__ = undefined;\n /* scoped */\n const __vue_scope_id__ = undefined;\n /* module identifier */\n const __vue_module_identifier__ = undefined;\n /* functional template */\n const __vue_is_functional_template__ = false;\n /* style inject */\n \n /* style inject SSR */\n \n\n \n var TextareaAutosize = normalizeComponent_1(\n { render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },\n __vue_inject_styles__,\n __vue_script__,\n __vue_scope_id__,\n __vue_is_functional_template__,\n __vue_module_identifier__,\n undefined,\n undefined\n );\n\nvar version = '1.1.1';\n\nvar install = function install(Vue) {\n Vue.component('TextareaAutosize', TextareaAutosize);\n};\n\nvar plugin = {\n install: install,\n version: version\n};\n\nif (typeof window !== 'undefined' && window.Vue) {\n window.Vue.use(plugin);\n}\n\nexport default plugin;\n","import { extend, isArray, isMap, isIntegerKey, isSymbol, hasOwn, isObject, hasChanged, makeMap, capitalize, toRawType, def, isFunction, NOOP } from '@vue/shared';\n\nfunction warn(msg, ...args) {\r\n console.warn(`[Vue warn] ${msg}`, ...args);\r\n}\n\nlet activeEffectScope;\r\nconst effectScopeStack = [];\r\nclass EffectScope {\r\n constructor(detached = false) {\r\n this.active = true;\r\n this.effects = [];\r\n this.cleanups = [];\r\n if (!detached && activeEffectScope) {\r\n this.parent = activeEffectScope;\r\n this.index =\r\n (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(this) - 1;\r\n }\r\n }\r\n run(fn) {\r\n if (this.active) {\r\n try {\r\n this.on();\r\n return fn();\r\n }\r\n finally {\r\n this.off();\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`cannot run an inactive effect scope.`);\r\n }\r\n }\r\n on() {\r\n if (this.active) {\r\n effectScopeStack.push(this);\r\n activeEffectScope = this;\r\n }\r\n }\r\n off() {\r\n if (this.active) {\r\n effectScopeStack.pop();\r\n activeEffectScope = effectScopeStack[effectScopeStack.length - 1];\r\n }\r\n }\r\n stop(fromParent) {\r\n if (this.active) {\r\n this.effects.forEach(e => e.stop());\r\n this.cleanups.forEach(cleanup => cleanup());\r\n if (this.scopes) {\r\n this.scopes.forEach(e => e.stop(true));\r\n }\r\n // nested scope, dereference from parent to avoid memory leaks\r\n if (this.parent && !fromParent) {\r\n // optimized O(1) removal\r\n const last = this.parent.scopes.pop();\r\n if (last && last !== this) {\r\n this.parent.scopes[this.index] = last;\r\n last.index = this.index;\r\n }\r\n }\r\n this.active = false;\r\n }\r\n }\r\n}\r\nfunction effectScope(detached) {\r\n return new EffectScope(detached);\r\n}\r\nfunction recordEffectScope(effect, scope) {\r\n scope = scope || activeEffectScope;\r\n if (scope && scope.active) {\r\n scope.effects.push(effect);\r\n }\r\n}\r\nfunction getCurrentScope() {\r\n return activeEffectScope;\r\n}\r\nfunction onScopeDispose(fn) {\r\n if (activeEffectScope) {\r\n activeEffectScope.cleanups.push(fn);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`onScopeDispose() is called when there is no active effect scope` +\r\n ` to be associated with.`);\r\n }\r\n}\n\nconst createDep = (effects) => {\r\n const dep = new Set(effects);\r\n dep.w = 0;\r\n dep.n = 0;\r\n return dep;\r\n};\r\nconst wasTracked = (dep) => (dep.w & trackOpBit) > 0;\r\nconst newTracked = (dep) => (dep.n & trackOpBit) > 0;\r\nconst initDepMarkers = ({ deps }) => {\r\n if (deps.length) {\r\n for (let i = 0; i < deps.length; i++) {\r\n deps[i].w |= trackOpBit; // set was tracked\r\n }\r\n }\r\n};\r\nconst finalizeDepMarkers = (effect) => {\r\n const { deps } = effect;\r\n if (deps.length) {\r\n let ptr = 0;\r\n for (let i = 0; i < deps.length; i++) {\r\n const dep = deps[i];\r\n if (wasTracked(dep) && !newTracked(dep)) {\r\n dep.delete(effect);\r\n }\r\n else {\r\n deps[ptr++] = dep;\r\n }\r\n // clear bits\r\n dep.w &= ~trackOpBit;\r\n dep.n &= ~trackOpBit;\r\n }\r\n deps.length = ptr;\r\n }\r\n};\n\nconst targetMap = new WeakMap();\r\n// The number of effects currently being tracked recursively.\r\nlet effectTrackDepth = 0;\r\nlet trackOpBit = 1;\r\n/**\r\n * The bitwise track markers support at most 30 levels of recursion.\r\n * This value is chosen to enable modern JS engines to use a SMI on all platforms.\r\n * When recursion depth is greater, fall back to using a full cleanup.\r\n */\r\nconst maxMarkerBits = 30;\r\nconst effectStack = [];\r\nlet activeEffect;\r\nconst ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'iterate' : '');\r\nconst MAP_KEY_ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'Map key iterate' : '');\r\nclass ReactiveEffect {\r\n constructor(fn, scheduler = null, scope) {\r\n this.fn = fn;\r\n this.scheduler = scheduler;\r\n this.active = true;\r\n this.deps = [];\r\n recordEffectScope(this, scope);\r\n }\r\n run() {\r\n if (!this.active) {\r\n return this.fn();\r\n }\r\n if (!effectStack.includes(this)) {\r\n try {\r\n effectStack.push((activeEffect = this));\r\n enableTracking();\r\n trackOpBit = 1 << ++effectTrackDepth;\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n initDepMarkers(this);\r\n }\r\n else {\r\n cleanupEffect(this);\r\n }\r\n return this.fn();\r\n }\r\n finally {\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n finalizeDepMarkers(this);\r\n }\r\n trackOpBit = 1 << --effectTrackDepth;\r\n resetTracking();\r\n effectStack.pop();\r\n const n = effectStack.length;\r\n activeEffect = n > 0 ? effectStack[n - 1] : undefined;\r\n }\r\n }\r\n }\r\n stop() {\r\n if (this.active) {\r\n cleanupEffect(this);\r\n if (this.onStop) {\r\n this.onStop();\r\n }\r\n this.active = false;\r\n }\r\n }\r\n}\r\nfunction cleanupEffect(effect) {\r\n const { deps } = effect;\r\n if (deps.length) {\r\n for (let i = 0; i < deps.length; i++) {\r\n deps[i].delete(effect);\r\n }\r\n deps.length = 0;\r\n }\r\n}\r\nfunction effect(fn, options) {\r\n if (fn.effect) {\r\n fn = fn.effect.fn;\r\n }\r\n const _effect = new ReactiveEffect(fn);\r\n if (options) {\r\n extend(_effect, options);\r\n if (options.scope)\r\n recordEffectScope(_effect, options.scope);\r\n }\r\n if (!options || !options.lazy) {\r\n _effect.run();\r\n }\r\n const runner = _effect.run.bind(_effect);\r\n runner.effect = _effect;\r\n return runner;\r\n}\r\nfunction stop(runner) {\r\n runner.effect.stop();\r\n}\r\nlet shouldTrack = true;\r\nconst trackStack = [];\r\nfunction pauseTracking() {\r\n trackStack.push(shouldTrack);\r\n shouldTrack = false;\r\n}\r\nfunction enableTracking() {\r\n trackStack.push(shouldTrack);\r\n shouldTrack = true;\r\n}\r\nfunction resetTracking() {\r\n const last = trackStack.pop();\r\n shouldTrack = last === undefined ? true : last;\r\n}\r\nfunction track(target, type, key) {\r\n if (!isTracking()) {\r\n return;\r\n }\r\n let depsMap = targetMap.get(target);\r\n if (!depsMap) {\r\n targetMap.set(target, (depsMap = new Map()));\r\n }\r\n let dep = depsMap.get(key);\r\n if (!dep) {\r\n depsMap.set(key, (dep = createDep()));\r\n }\r\n const eventInfo = (process.env.NODE_ENV !== 'production')\r\n ? { effect: activeEffect, target, type, key }\r\n : undefined;\r\n trackEffects(dep, eventInfo);\r\n}\r\nfunction isTracking() {\r\n return shouldTrack && activeEffect !== undefined;\r\n}\r\nfunction trackEffects(dep, debuggerEventExtraInfo) {\r\n let shouldTrack = false;\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n if (!newTracked(dep)) {\r\n dep.n |= trackOpBit; // set newly tracked\r\n shouldTrack = !wasTracked(dep);\r\n }\r\n }\r\n else {\r\n // Full cleanup mode.\r\n shouldTrack = !dep.has(activeEffect);\r\n }\r\n if (shouldTrack) {\r\n dep.add(activeEffect);\r\n activeEffect.deps.push(dep);\r\n if ((process.env.NODE_ENV !== 'production') && activeEffect.onTrack) {\r\n activeEffect.onTrack(Object.assign({\r\n effect: activeEffect\r\n }, debuggerEventExtraInfo));\r\n }\r\n }\r\n}\r\nfunction trigger(target, type, key, newValue, oldValue, oldTarget) {\r\n const depsMap = targetMap.get(target);\r\n if (!depsMap) {\r\n // never been tracked\r\n return;\r\n }\r\n let deps = [];\r\n if (type === \"clear\" /* CLEAR */) {\r\n // collection being cleared\r\n // trigger all effects for target\r\n deps = [...depsMap.values()];\r\n }\r\n else if (key === 'length' && isArray(target)) {\r\n depsMap.forEach((dep, key) => {\r\n if (key === 'length' || key >= newValue) {\r\n deps.push(dep);\r\n }\r\n });\r\n }\r\n else {\r\n // schedule runs for SET | ADD | DELETE\r\n if (key !== void 0) {\r\n deps.push(depsMap.get(key));\r\n }\r\n // also run for iteration key on ADD | DELETE | Map.SET\r\n switch (type) {\r\n case \"add\" /* ADD */:\r\n if (!isArray(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n }\r\n }\r\n else if (isIntegerKey(key)) {\r\n // new index added to array -> length changes\r\n deps.push(depsMap.get('length'));\r\n }\r\n break;\r\n case \"delete\" /* DELETE */:\r\n if (!isArray(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n }\r\n }\r\n break;\r\n case \"set\" /* SET */:\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n }\r\n break;\r\n }\r\n }\r\n const eventInfo = (process.env.NODE_ENV !== 'production')\r\n ? { target, type, key, newValue, oldValue, oldTarget }\r\n : undefined;\r\n if (deps.length === 1) {\r\n if (deps[0]) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(deps[0], eventInfo);\r\n }\r\n else {\r\n triggerEffects(deps[0]);\r\n }\r\n }\r\n }\r\n else {\r\n const effects = [];\r\n for (const dep of deps) {\r\n if (dep) {\r\n effects.push(...dep);\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(createDep(effects), eventInfo);\r\n }\r\n else {\r\n triggerEffects(createDep(effects));\r\n }\r\n }\r\n}\r\nfunction triggerEffects(dep, debuggerEventExtraInfo) {\r\n // spread into array for stabilization\r\n for (const effect of isArray(dep) ? dep : [...dep]) {\r\n if (effect !== activeEffect || effect.allowRecurse) {\r\n if ((process.env.NODE_ENV !== 'production') && effect.onTrigger) {\r\n effect.onTrigger(extend({ effect }, debuggerEventExtraInfo));\r\n }\r\n if (effect.scheduler) {\r\n effect.scheduler();\r\n }\r\n else {\r\n effect.run();\r\n }\r\n }\r\n }\r\n}\n\nconst isNonTrackableKeys = /*#__PURE__*/ makeMap(`__proto__,__v_isRef,__isVue`);\r\nconst builtInSymbols = new Set(Object.getOwnPropertyNames(Symbol)\r\n .map(key => Symbol[key])\r\n .filter(isSymbol));\r\nconst get = /*#__PURE__*/ createGetter();\r\nconst shallowGet = /*#__PURE__*/ createGetter(false, true);\r\nconst readonlyGet = /*#__PURE__*/ createGetter(true);\r\nconst shallowReadonlyGet = /*#__PURE__*/ createGetter(true, true);\r\nconst arrayInstrumentations = /*#__PURE__*/ createArrayInstrumentations();\r\nfunction createArrayInstrumentations() {\r\n const instrumentations = {};\r\n ['includes', 'indexOf', 'lastIndexOf'].forEach(key => {\r\n instrumentations[key] = function (...args) {\r\n const arr = toRaw(this);\r\n for (let i = 0, l = this.length; i < l; i++) {\r\n track(arr, \"get\" /* GET */, i + '');\r\n }\r\n // we run the method using the original args first (which may be reactive)\r\n const res = arr[key](...args);\r\n if (res === -1 || res === false) {\r\n // if that didn't work, run it again using raw values.\r\n return arr[key](...args.map(toRaw));\r\n }\r\n else {\r\n return res;\r\n }\r\n };\r\n });\r\n ['push', 'pop', 'shift', 'unshift', 'splice'].forEach(key => {\r\n instrumentations[key] = function (...args) {\r\n pauseTracking();\r\n const res = toRaw(this)[key].apply(this, args);\r\n resetTracking();\r\n return res;\r\n };\r\n });\r\n return instrumentations;\r\n}\r\nfunction createGetter(isReadonly = false, shallow = false) {\r\n return function get(target, key, receiver) {\r\n if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n return !isReadonly;\r\n }\r\n else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n return isReadonly;\r\n }\r\n else if (key === \"__v_raw\" /* RAW */ &&\r\n receiver ===\r\n (isReadonly\r\n ? shallow\r\n ? shallowReadonlyMap\r\n : readonlyMap\r\n : shallow\r\n ? shallowReactiveMap\r\n : reactiveMap).get(target)) {\r\n return target;\r\n }\r\n const targetIsArray = isArray(target);\r\n if (!isReadonly && targetIsArray && hasOwn(arrayInstrumentations, key)) {\r\n return Reflect.get(arrayInstrumentations, key, receiver);\r\n }\r\n const res = Reflect.get(target, key, receiver);\r\n if (isSymbol(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {\r\n return res;\r\n }\r\n if (!isReadonly) {\r\n track(target, \"get\" /* GET */, key);\r\n }\r\n if (shallow) {\r\n return res;\r\n }\r\n if (isRef(res)) {\r\n // ref unwrapping - does not apply for Array + integer key.\r\n const shouldUnwrap = !targetIsArray || !isIntegerKey(key);\r\n return shouldUnwrap ? res.value : res;\r\n }\r\n if (isObject(res)) {\r\n // Convert returned value into a proxy as well. we do the isObject check\r\n // here to avoid invalid value warning. Also need to lazy access readonly\r\n // and reactive here to avoid circular dependency.\r\n return isReadonly ? readonly(res) : reactive(res);\r\n }\r\n return res;\r\n };\r\n}\r\nconst set = /*#__PURE__*/ createSetter();\r\nconst shallowSet = /*#__PURE__*/ createSetter(true);\r\nfunction createSetter(shallow = false) {\r\n return function set(target, key, value, receiver) {\r\n let oldValue = target[key];\r\n if (!shallow && !isReadonly(value)) {\r\n value = toRaw(value);\r\n oldValue = toRaw(oldValue);\r\n if (!isArray(target) && isRef(oldValue) && !isRef(value)) {\r\n oldValue.value = value;\r\n return true;\r\n }\r\n }\r\n const hadKey = isArray(target) && isIntegerKey(key)\r\n ? Number(key) < target.length\r\n : hasOwn(target, key);\r\n const result = Reflect.set(target, key, value, receiver);\r\n // don't trigger if target is something up in the prototype chain of original\r\n if (target === toRaw(receiver)) {\r\n if (!hadKey) {\r\n trigger(target, \"add\" /* ADD */, key, value);\r\n }\r\n else if (hasChanged(value, oldValue)) {\r\n trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n }\r\n }\r\n return result;\r\n };\r\n}\r\nfunction deleteProperty(target, key) {\r\n const hadKey = hasOwn(target, key);\r\n const oldValue = target[key];\r\n const result = Reflect.deleteProperty(target, key);\r\n if (result && hadKey) {\r\n trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n }\r\n return result;\r\n}\r\nfunction has(target, key) {\r\n const result = Reflect.has(target, key);\r\n if (!isSymbol(key) || !builtInSymbols.has(key)) {\r\n track(target, \"has\" /* HAS */, key);\r\n }\r\n return result;\r\n}\r\nfunction ownKeys(target) {\r\n track(target, \"iterate\" /* ITERATE */, isArray(target) ? 'length' : ITERATE_KEY);\r\n return Reflect.ownKeys(target);\r\n}\r\nconst mutableHandlers = {\r\n get,\r\n set,\r\n deleteProperty,\r\n has,\r\n ownKeys\r\n};\r\nconst readonlyHandlers = {\r\n get: readonlyGet,\r\n set(target, key) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`Set operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n }\r\n return true;\r\n },\r\n deleteProperty(target, key) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`Delete operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n }\r\n return true;\r\n }\r\n};\r\nconst shallowReactiveHandlers = /*#__PURE__*/ extend({}, mutableHandlers, {\r\n get: shallowGet,\r\n set: shallowSet\r\n});\r\n// Props handlers are special in the sense that it should not unwrap top-level\r\n// refs (in order to allow refs to be explicitly passed down), but should\r\n// retain the reactivity of the normal readonly object.\r\nconst shallowReadonlyHandlers = /*#__PURE__*/ extend({}, readonlyHandlers, {\r\n get: shallowReadonlyGet\r\n});\n\nconst toShallow = (value) => value;\r\nconst getProto = (v) => Reflect.getPrototypeOf(v);\r\nfunction get$1(target, key, isReadonly = false, isShallow = false) {\r\n // #1772: readonly(reactive(Map)) should return readonly + reactive version\r\n // of the value\r\n target = target[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const rawKey = toRaw(key);\r\n if (key !== rawKey) {\r\n !isReadonly && track(rawTarget, \"get\" /* GET */, key);\r\n }\r\n !isReadonly && track(rawTarget, \"get\" /* GET */, rawKey);\r\n const { has } = getProto(rawTarget);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n if (has.call(rawTarget, key)) {\r\n return wrap(target.get(key));\r\n }\r\n else if (has.call(rawTarget, rawKey)) {\r\n return wrap(target.get(rawKey));\r\n }\r\n else if (target !== rawTarget) {\r\n // #3602 readonly(reactive(Map))\r\n // ensure that the nested reactive `Map` can do tracking for itself\r\n target.get(key);\r\n }\r\n}\r\nfunction has$1(key, isReadonly = false) {\r\n const target = this[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const rawKey = toRaw(key);\r\n if (key !== rawKey) {\r\n !isReadonly && track(rawTarget, \"has\" /* HAS */, key);\r\n }\r\n !isReadonly && track(rawTarget, \"has\" /* HAS */, rawKey);\r\n return key === rawKey\r\n ? target.has(key)\r\n : target.has(key) || target.has(rawKey);\r\n}\r\nfunction size(target, isReadonly = false) {\r\n target = target[\"__v_raw\" /* RAW */];\r\n !isReadonly && track(toRaw(target), \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n return Reflect.get(target, 'size', target);\r\n}\r\nfunction add(value) {\r\n value = toRaw(value);\r\n const target = toRaw(this);\r\n const proto = getProto(target);\r\n const hadKey = proto.has.call(target, value);\r\n if (!hadKey) {\r\n target.add(value);\r\n trigger(target, \"add\" /* ADD */, value, value);\r\n }\r\n return this;\r\n}\r\nfunction set$1(key, value) {\r\n value = toRaw(value);\r\n const target = toRaw(this);\r\n const { has, get } = getProto(target);\r\n let hadKey = has.call(target, key);\r\n if (!hadKey) {\r\n key = toRaw(key);\r\n hadKey = has.call(target, key);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n checkIdentityKeys(target, has, key);\r\n }\r\n const oldValue = get.call(target, key);\r\n target.set(key, value);\r\n if (!hadKey) {\r\n trigger(target, \"add\" /* ADD */, key, value);\r\n }\r\n else if (hasChanged(value, oldValue)) {\r\n trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n }\r\n return this;\r\n}\r\nfunction deleteEntry(key) {\r\n const target = toRaw(this);\r\n const { has, get } = getProto(target);\r\n let hadKey = has.call(target, key);\r\n if (!hadKey) {\r\n key = toRaw(key);\r\n hadKey = has.call(target, key);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n checkIdentityKeys(target, has, key);\r\n }\r\n const oldValue = get ? get.call(target, key) : undefined;\r\n // forward the operation before queueing reactions\r\n const result = target.delete(key);\r\n if (hadKey) {\r\n trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n }\r\n return result;\r\n}\r\nfunction clear() {\r\n const target = toRaw(this);\r\n const hadItems = target.size !== 0;\r\n const oldTarget = (process.env.NODE_ENV !== 'production')\r\n ? isMap(target)\r\n ? new Map(target)\r\n : new Set(target)\r\n : undefined;\r\n // forward the operation before queueing reactions\r\n const result = target.clear();\r\n if (hadItems) {\r\n trigger(target, \"clear\" /* CLEAR */, undefined, undefined, oldTarget);\r\n }\r\n return result;\r\n}\r\nfunction createForEach(isReadonly, isShallow) {\r\n return function forEach(callback, thisArg) {\r\n const observed = this;\r\n const target = observed[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n !isReadonly && track(rawTarget, \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n return target.forEach((value, key) => {\r\n // important: make sure the callback is\r\n // 1. invoked with the reactive map as `this` and 3rd arg\r\n // 2. the value received should be a corresponding reactive/readonly.\r\n return callback.call(thisArg, wrap(value), wrap(key), observed);\r\n });\r\n };\r\n}\r\nfunction createIterableMethod(method, isReadonly, isShallow) {\r\n return function (...args) {\r\n const target = this[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const targetIsMap = isMap(rawTarget);\r\n const isPair = method === 'entries' || (method === Symbol.iterator && targetIsMap);\r\n const isKeyOnly = method === 'keys' && targetIsMap;\r\n const innerIterator = target[method](...args);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n !isReadonly &&\r\n track(rawTarget, \"iterate\" /* ITERATE */, isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY);\r\n // return a wrapped iterator which returns observed versions of the\r\n // values emitted from the real iterator\r\n return {\r\n // iterator protocol\r\n next() {\r\n const { value, done } = innerIterator.next();\r\n return done\r\n ? { value, done }\r\n : {\r\n value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),\r\n done\r\n };\r\n },\r\n // iterable protocol\r\n [Symbol.iterator]() {\r\n return this;\r\n }\r\n };\r\n };\r\n}\r\nfunction createReadonlyMethod(type) {\r\n return function (...args) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const key = args[0] ? `on key \"${args[0]}\" ` : ``;\r\n console.warn(`${capitalize(type)} operation ${key}failed: target is readonly.`, toRaw(this));\r\n }\r\n return type === \"delete\" /* DELETE */ ? false : this;\r\n };\r\n}\r\nfunction createInstrumentations() {\r\n const mutableInstrumentations = {\r\n get(key) {\r\n return get$1(this, key);\r\n },\r\n get size() {\r\n return size(this);\r\n },\r\n has: has$1,\r\n add,\r\n set: set$1,\r\n delete: deleteEntry,\r\n clear,\r\n forEach: createForEach(false, false)\r\n };\r\n const shallowInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, false, true);\r\n },\r\n get size() {\r\n return size(this);\r\n },\r\n has: has$1,\r\n add,\r\n set: set$1,\r\n delete: deleteEntry,\r\n clear,\r\n forEach: createForEach(false, true)\r\n };\r\n const readonlyInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, true);\r\n },\r\n get size() {\r\n return size(this, true);\r\n },\r\n has(key) {\r\n return has$1.call(this, key, true);\r\n },\r\n add: createReadonlyMethod(\"add\" /* ADD */),\r\n set: createReadonlyMethod(\"set\" /* SET */),\r\n delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n forEach: createForEach(true, false)\r\n };\r\n const shallowReadonlyInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, true, true);\r\n },\r\n get size() {\r\n return size(this, true);\r\n },\r\n has(key) {\r\n return has$1.call(this, key, true);\r\n },\r\n add: createReadonlyMethod(\"add\" /* ADD */),\r\n set: createReadonlyMethod(\"set\" /* SET */),\r\n delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n forEach: createForEach(true, true)\r\n };\r\n const iteratorMethods = ['keys', 'values', 'entries', Symbol.iterator];\r\n iteratorMethods.forEach(method => {\r\n mutableInstrumentations[method] = createIterableMethod(method, false, false);\r\n readonlyInstrumentations[method] = createIterableMethod(method, true, false);\r\n shallowInstrumentations[method] = createIterableMethod(method, false, true);\r\n shallowReadonlyInstrumentations[method] = createIterableMethod(method, true, true);\r\n });\r\n return [\r\n mutableInstrumentations,\r\n readonlyInstrumentations,\r\n shallowInstrumentations,\r\n shallowReadonlyInstrumentations\r\n ];\r\n}\r\nconst [mutableInstrumentations, readonlyInstrumentations, shallowInstrumentations, shallowReadonlyInstrumentations] = /* #__PURE__*/ createInstrumentations();\r\nfunction createInstrumentationGetter(isReadonly, shallow) {\r\n const instrumentations = shallow\r\n ? isReadonly\r\n ? shallowReadonlyInstrumentations\r\n : shallowInstrumentations\r\n : isReadonly\r\n ? readonlyInstrumentations\r\n : mutableInstrumentations;\r\n return (target, key, receiver) => {\r\n if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n return !isReadonly;\r\n }\r\n else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n return isReadonly;\r\n }\r\n else if (key === \"__v_raw\" /* RAW */) {\r\n return target;\r\n }\r\n return Reflect.get(hasOwn(instrumentations, key) && key in target\r\n ? instrumentations\r\n : target, key, receiver);\r\n };\r\n}\r\nconst mutableCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(false, false)\r\n};\r\nconst shallowCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(false, true)\r\n};\r\nconst readonlyCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(true, false)\r\n};\r\nconst shallowReadonlyCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(true, true)\r\n};\r\nfunction checkIdentityKeys(target, has, key) {\r\n const rawKey = toRaw(key);\r\n if (rawKey !== key && has.call(target, rawKey)) {\r\n const type = toRawType(target);\r\n console.warn(`Reactive ${type} contains both the raw and reactive ` +\r\n `versions of the same object${type === `Map` ? ` as keys` : ``}, ` +\r\n `which can lead to inconsistencies. ` +\r\n `Avoid differentiating between the raw and reactive versions ` +\r\n `of an object and only use the reactive version if possible.`);\r\n }\r\n}\n\nconst reactiveMap = new WeakMap();\r\nconst shallowReactiveMap = new WeakMap();\r\nconst readonlyMap = new WeakMap();\r\nconst shallowReadonlyMap = new WeakMap();\r\nfunction targetTypeMap(rawType) {\r\n switch (rawType) {\r\n case 'Object':\r\n case 'Array':\r\n return 1 /* COMMON */;\r\n case 'Map':\r\n case 'Set':\r\n case 'WeakMap':\r\n case 'WeakSet':\r\n return 2 /* COLLECTION */;\r\n default:\r\n return 0 /* INVALID */;\r\n }\r\n}\r\nfunction getTargetType(value) {\r\n return value[\"__v_skip\" /* SKIP */] || !Object.isExtensible(value)\r\n ? 0 /* INVALID */\r\n : targetTypeMap(toRawType(value));\r\n}\r\nfunction reactive(target) {\r\n // if trying to observe a readonly proxy, return the readonly version.\r\n if (target && target[\"__v_isReadonly\" /* IS_READONLY */]) {\r\n return target;\r\n }\r\n return createReactiveObject(target, false, mutableHandlers, mutableCollectionHandlers, reactiveMap);\r\n}\r\n/**\r\n * Return a shallowly-reactive copy of the original object, where only the root\r\n * level properties are reactive. It also does not auto-unwrap refs (even at the\r\n * root level).\r\n */\r\nfunction shallowReactive(target) {\r\n return createReactiveObject(target, false, shallowReactiveHandlers, shallowCollectionHandlers, shallowReactiveMap);\r\n}\r\n/**\r\n * Creates a readonly copy of the original object. Note the returned copy is not\r\n * made reactive, but `readonly` can be called on an already reactive object.\r\n */\r\nfunction readonly(target) {\r\n return createReactiveObject(target, true, readonlyHandlers, readonlyCollectionHandlers, readonlyMap);\r\n}\r\n/**\r\n * Returns a reactive-copy of the original object, where only the root level\r\n * properties are readonly, and does NOT unwrap refs nor recursively convert\r\n * returned properties.\r\n * This is used for creating the props proxy object for stateful components.\r\n */\r\nfunction shallowReadonly(target) {\r\n return createReactiveObject(target, true, shallowReadonlyHandlers, shallowReadonlyCollectionHandlers, shallowReadonlyMap);\r\n}\r\nfunction createReactiveObject(target, isReadonly, baseHandlers, collectionHandlers, proxyMap) {\r\n if (!isObject(target)) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`value cannot be made reactive: ${String(target)}`);\r\n }\r\n return target;\r\n }\r\n // target is already a Proxy, return it.\r\n // exception: calling readonly() on a reactive object\r\n if (target[\"__v_raw\" /* RAW */] &&\r\n !(isReadonly && target[\"__v_isReactive\" /* IS_REACTIVE */])) {\r\n return target;\r\n }\r\n // target already has corresponding Proxy\r\n const existingProxy = proxyMap.get(target);\r\n if (existingProxy) {\r\n return existingProxy;\r\n }\r\n // only a whitelist of value types can be observed.\r\n const targetType = getTargetType(target);\r\n if (targetType === 0 /* INVALID */) {\r\n return target;\r\n }\r\n const proxy = new Proxy(target, targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers);\r\n proxyMap.set(target, proxy);\r\n return proxy;\r\n}\r\nfunction isReactive(value) {\r\n if (isReadonly(value)) {\r\n return isReactive(value[\"__v_raw\" /* RAW */]);\r\n }\r\n return !!(value && value[\"__v_isReactive\" /* IS_REACTIVE */]);\r\n}\r\nfunction isReadonly(value) {\r\n return !!(value && value[\"__v_isReadonly\" /* IS_READONLY */]);\r\n}\r\nfunction isProxy(value) {\r\n return isReactive(value) || isReadonly(value);\r\n}\r\nfunction toRaw(observed) {\r\n const raw = observed && observed[\"__v_raw\" /* RAW */];\r\n return raw ? toRaw(raw) : observed;\r\n}\r\nfunction markRaw(value) {\r\n def(value, \"__v_skip\" /* SKIP */, true);\r\n return value;\r\n}\r\nconst toReactive = (value) => isObject(value) ? reactive(value) : value;\r\nconst toReadonly = (value) => isObject(value) ? readonly(value) : value;\n\nfunction trackRefValue(ref) {\r\n if (isTracking()) {\r\n ref = toRaw(ref);\r\n if (!ref.dep) {\r\n ref.dep = createDep();\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n trackEffects(ref.dep, {\r\n target: ref,\r\n type: \"get\" /* GET */,\r\n key: 'value'\r\n });\r\n }\r\n else {\r\n trackEffects(ref.dep);\r\n }\r\n }\r\n}\r\nfunction triggerRefValue(ref, newVal) {\r\n ref = toRaw(ref);\r\n if (ref.dep) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(ref.dep, {\r\n target: ref,\r\n type: \"set\" /* SET */,\r\n key: 'value',\r\n newValue: newVal\r\n });\r\n }\r\n else {\r\n triggerEffects(ref.dep);\r\n }\r\n }\r\n}\r\nfunction isRef(r) {\r\n return Boolean(r && r.__v_isRef === true);\r\n}\r\nfunction ref(value) {\r\n return createRef(value, false);\r\n}\r\nfunction shallowRef(value) {\r\n return createRef(value, true);\r\n}\r\nfunction createRef(rawValue, shallow) {\r\n if (isRef(rawValue)) {\r\n return rawValue;\r\n }\r\n return new RefImpl(rawValue, shallow);\r\n}\r\nclass RefImpl {\r\n constructor(value, _shallow) {\r\n this._shallow = _shallow;\r\n this.dep = undefined;\r\n this.__v_isRef = true;\r\n this._rawValue = _shallow ? value : toRaw(value);\r\n this._value = _shallow ? value : toReactive(value);\r\n }\r\n get value() {\r\n trackRefValue(this);\r\n return this._value;\r\n }\r\n set value(newVal) {\r\n newVal = this._shallow ? newVal : toRaw(newVal);\r\n if (hasChanged(newVal, this._rawValue)) {\r\n this._rawValue = newVal;\r\n this._value = this._shallow ? newVal : toReactive(newVal);\r\n triggerRefValue(this, newVal);\r\n }\r\n }\r\n}\r\nfunction triggerRef(ref) {\r\n triggerRefValue(ref, (process.env.NODE_ENV !== 'production') ? ref.value : void 0);\r\n}\r\nfunction unref(ref) {\r\n return isRef(ref) ? ref.value : ref;\r\n}\r\nconst shallowUnwrapHandlers = {\r\n get: (target, key, receiver) => unref(Reflect.get(target, key, receiver)),\r\n set: (target, key, value, receiver) => {\r\n const oldValue = target[key];\r\n if (isRef(oldValue) && !isRef(value)) {\r\n oldValue.value = value;\r\n return true;\r\n }\r\n else {\r\n return Reflect.set(target, key, value, receiver);\r\n }\r\n }\r\n};\r\nfunction proxyRefs(objectWithRefs) {\r\n return isReactive(objectWithRefs)\r\n ? objectWithRefs\r\n : new Proxy(objectWithRefs, shallowUnwrapHandlers);\r\n}\r\nclass CustomRefImpl {\r\n constructor(factory) {\r\n this.dep = undefined;\r\n this.__v_isRef = true;\r\n const { get, set } = factory(() => trackRefValue(this), () => triggerRefValue(this));\r\n this._get = get;\r\n this._set = set;\r\n }\r\n get value() {\r\n return this._get();\r\n }\r\n set value(newVal) {\r\n this._set(newVal);\r\n }\r\n}\r\nfunction customRef(factory) {\r\n return new CustomRefImpl(factory);\r\n}\r\nfunction toRefs(object) {\r\n if ((process.env.NODE_ENV !== 'production') && !isProxy(object)) {\r\n console.warn(`toRefs() expects a reactive object but received a plain one.`);\r\n }\r\n const ret = isArray(object) ? new Array(object.length) : {};\r\n for (const key in object) {\r\n ret[key] = toRef(object, key);\r\n }\r\n return ret;\r\n}\r\nclass ObjectRefImpl {\r\n constructor(_object, _key, _defaultValue) {\r\n this._object = _object;\r\n this._key = _key;\r\n this._defaultValue = _defaultValue;\r\n this.__v_isRef = true;\r\n }\r\n get value() {\r\n const val = this._object[this._key];\r\n return val === undefined ? this._defaultValue : val;\r\n }\r\n set value(newVal) {\r\n this._object[this._key] = newVal;\r\n }\r\n}\r\nfunction toRef(object, key, defaultValue) {\r\n const val = object[key];\r\n return isRef(val)\r\n ? val\r\n : new ObjectRefImpl(object, key, defaultValue);\r\n}\n\nclass ComputedRefImpl {\r\n constructor(getter, _setter, isReadonly) {\r\n this._setter = _setter;\r\n this.dep = undefined;\r\n this._dirty = true;\r\n this.__v_isRef = true;\r\n this.effect = new ReactiveEffect(getter, () => {\r\n if (!this._dirty) {\r\n this._dirty = true;\r\n triggerRefValue(this);\r\n }\r\n });\r\n this[\"__v_isReadonly\" /* IS_READONLY */] = isReadonly;\r\n }\r\n get value() {\r\n // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n const self = toRaw(this);\r\n trackRefValue(self);\r\n if (self._dirty) {\r\n self._dirty = false;\r\n self._value = self.effect.run();\r\n }\r\n return self._value;\r\n }\r\n set value(newValue) {\r\n this._setter(newValue);\r\n }\r\n}\r\nfunction computed(getterOrOptions, debugOptions) {\r\n let getter;\r\n let setter;\r\n const onlyGetter = isFunction(getterOrOptions);\r\n if (onlyGetter) {\r\n getter = getterOrOptions;\r\n setter = (process.env.NODE_ENV !== 'production')\r\n ? () => {\r\n console.warn('Write operation failed: computed value is readonly');\r\n }\r\n : NOOP;\r\n }\r\n else {\r\n getter = getterOrOptions.get;\r\n setter = getterOrOptions.set;\r\n }\r\n const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter);\r\n if ((process.env.NODE_ENV !== 'production') && debugOptions) {\r\n cRef.effect.onTrack = debugOptions.onTrack;\r\n cRef.effect.onTrigger = debugOptions.onTrigger;\r\n }\r\n return cRef;\r\n}\n\nvar _a;\r\nconst tick = Promise.resolve();\r\nconst queue = [];\r\nlet queued = false;\r\nconst scheduler = (fn) => {\r\n queue.push(fn);\r\n if (!queued) {\r\n queued = true;\r\n tick.then(flush);\r\n }\r\n};\r\nconst flush = () => {\r\n for (let i = 0; i < queue.length; i++) {\r\n queue[i]();\r\n }\r\n queue.length = 0;\r\n queued = false;\r\n};\r\nclass DeferredComputedRefImpl {\r\n constructor(getter) {\r\n this.dep = undefined;\r\n this._dirty = true;\r\n this.__v_isRef = true;\r\n this[_a] = true;\r\n let compareTarget;\r\n let hasCompareTarget = false;\r\n let scheduled = false;\r\n this.effect = new ReactiveEffect(getter, (computedTrigger) => {\r\n if (this.dep) {\r\n if (computedTrigger) {\r\n compareTarget = this._value;\r\n hasCompareTarget = true;\r\n }\r\n else if (!scheduled) {\r\n const valueToCompare = hasCompareTarget ? compareTarget : this._value;\r\n scheduled = true;\r\n hasCompareTarget = false;\r\n scheduler(() => {\r\n if (this.effect.active && this._get() !== valueToCompare) {\r\n triggerRefValue(this);\r\n }\r\n scheduled = false;\r\n });\r\n }\r\n // chained upstream computeds are notified synchronously to ensure\r\n // value invalidation in case of sync access; normal effects are\r\n // deferred to be triggered in scheduler.\r\n for (const e of this.dep) {\r\n if (e.computed) {\r\n e.scheduler(true /* computedTrigger */);\r\n }\r\n }\r\n }\r\n this._dirty = true;\r\n });\r\n this.effect.computed = true;\r\n }\r\n _get() {\r\n if (this._dirty) {\r\n this._dirty = false;\r\n return (this._value = this.effect.run());\r\n }\r\n return this._value;\r\n }\r\n get value() {\r\n trackRefValue(this);\r\n // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n return toRaw(this)._get();\r\n }\r\n}\r\n_a = \"__v_isReadonly\" /* IS_READONLY */;\r\nfunction deferredComputed(getter) {\r\n return new DeferredComputedRefImpl(getter);\r\n}\n\nexport { EffectScope, ITERATE_KEY, ReactiveEffect, computed, customRef, deferredComputed, effect, effectScope, enableTracking, getCurrentScope, isProxy, isReactive, isReadonly, isRef, markRaw, onScopeDispose, pauseTracking, proxyRefs, reactive, readonly, ref, resetTracking, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, track, trigger, triggerRef, unref };\n","import { toRaw, ref, pauseTracking, resetTracking, reactive, computed, isRef, shallowReactive, trigger, ReactiveEffect, isProxy, shallowReadonly, track, EffectScope, markRaw, proxyRefs, isReactive, isReadonly } from '@vue/reactivity';\nexport { EffectScope, ReactiveEffect, computed, customRef, effect, effectScope, getCurrentScope, isProxy, isReactive, isReadonly, isRef, markRaw, onScopeDispose, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, triggerRef, unref } from '@vue/reactivity';\nimport { getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, isFunction, toNumber, hyphenate, camelize, isArray, isOn, hasOwn, isModelListener, isObject, remove, isString, invokeArrayFns, isPromise, NOOP, def, isReservedProp, EMPTY_ARR, capitalize, toRawType, makeMap, NO, normalizeClass, normalizeStyle, isGloballyWhitelisted, hasChanged, isSet, isMap, isPlainObject } from '@vue/shared';\nexport { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';\n\n/* eslint-disable no-restricted-globals */\r\nlet isHmrUpdating = false;\r\nconst hmrDirtyComponents = new Set();\r\n// Expose the HMR runtime on the global object\r\n// This makes it entirely tree-shakable without polluting the exports and makes\r\n// it easier to be used in toolings like vue-loader\r\n// Note: for a component to be eligible for HMR it also needs the __hmrId option\r\n// to be set so that its instances can be registered / removed.\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n getGlobalThis().__VUE_HMR_RUNTIME__ = {\r\n createRecord: tryWrap(createRecord),\r\n rerender: tryWrap(rerender),\r\n reload: tryWrap(reload)\r\n };\r\n}\r\nconst map = new Map();\r\nfunction registerHMR(instance) {\r\n const id = instance.type.__hmrId;\r\n let record = map.get(id);\r\n if (!record) {\r\n createRecord(id, instance.type);\r\n record = map.get(id);\r\n }\r\n record.instances.add(instance);\r\n}\r\nfunction unregisterHMR(instance) {\r\n map.get(instance.type.__hmrId).instances.delete(instance);\r\n}\r\nfunction createRecord(id, initialDef) {\r\n if (map.has(id)) {\r\n return false;\r\n }\r\n map.set(id, {\r\n initialDef: normalizeClassComponent(initialDef),\r\n instances: new Set()\r\n });\r\n return true;\r\n}\r\nfunction normalizeClassComponent(component) {\r\n return isClassComponent(component) ? component.__vccOpts : component;\r\n}\r\nfunction rerender(id, newRender) {\r\n const record = map.get(id);\r\n if (!record) {\r\n return;\r\n }\r\n // update initial record (for not-yet-rendered component)\r\n record.initialDef.render = newRender;\r\n [...record.instances].forEach(instance => {\r\n if (newRender) {\r\n instance.render = newRender;\r\n normalizeClassComponent(instance.type).render = newRender;\r\n }\r\n instance.renderCache = [];\r\n // this flag forces child components with slot content to update\r\n isHmrUpdating = true;\r\n instance.update();\r\n isHmrUpdating = false;\r\n });\r\n}\r\nfunction reload(id, newComp) {\r\n const record = map.get(id);\r\n if (!record)\r\n return;\r\n newComp = normalizeClassComponent(newComp);\r\n // update initial def (for not-yet-rendered components)\r\n updateComponentDef(record.initialDef, newComp);\r\n // create a snapshot which avoids the set being mutated during updates\r\n const instances = [...record.instances];\r\n for (const instance of instances) {\r\n const oldComp = normalizeClassComponent(instance.type);\r\n if (!hmrDirtyComponents.has(oldComp)) {\r\n // 1. Update existing comp definition to match new one\r\n if (oldComp !== record.initialDef) {\r\n updateComponentDef(oldComp, newComp);\r\n }\r\n // 2. mark definition dirty. This forces the renderer to replace the\r\n // component on patch.\r\n hmrDirtyComponents.add(oldComp);\r\n }\r\n // 3. invalidate options resolution cache\r\n instance.appContext.optionsCache.delete(instance.type);\r\n // 4. actually update\r\n if (instance.ceReload) {\r\n // custom element\r\n hmrDirtyComponents.add(oldComp);\r\n instance.ceReload(newComp.styles);\r\n hmrDirtyComponents.delete(oldComp);\r\n }\r\n else if (instance.parent) {\r\n // 4. Force the parent instance to re-render. This will cause all updated\r\n // components to be unmounted and re-mounted. Queue the update so that we\r\n // don't end up forcing the same parent to re-render multiple times.\r\n queueJob(instance.parent.update);\r\n // instance is the inner component of an async custom element\r\n // invoke to reset styles\r\n if (instance.parent.type.__asyncLoader &&\r\n instance.parent.ceReload) {\r\n instance.parent.ceReload(newComp.styles);\r\n }\r\n }\r\n else if (instance.appContext.reload) {\r\n // root instance mounted via createApp() has a reload method\r\n instance.appContext.reload();\r\n }\r\n else if (typeof window !== 'undefined') {\r\n // root instance inside tree created via raw render(). Force reload.\r\n window.location.reload();\r\n }\r\n else {\r\n console.warn('[HMR] Root or manually mounted instance modified. Full reload required.');\r\n }\r\n }\r\n // 5. make sure to cleanup dirty hmr components after update\r\n queuePostFlushCb(() => {\r\n for (const instance of instances) {\r\n hmrDirtyComponents.delete(normalizeClassComponent(instance.type));\r\n }\r\n });\r\n}\r\nfunction updateComponentDef(oldComp, newComp) {\r\n extend(oldComp, newComp);\r\n for (const key in oldComp) {\r\n if (key !== '__file' && !(key in newComp)) {\r\n delete oldComp[key];\r\n }\r\n }\r\n}\r\nfunction tryWrap(fn) {\r\n return (id, arg) => {\r\n try {\r\n return fn(id, arg);\r\n }\r\n catch (e) {\r\n console.error(e);\r\n console.warn(`[HMR] Something went wrong during Vue component hot-reload. ` +\r\n `Full reload required.`);\r\n }\r\n };\r\n}\n\nlet devtools;\r\nlet buffer = [];\r\nlet devtoolsNotInstalled = false;\r\nfunction emit(event, ...args) {\r\n if (devtools) {\r\n devtools.emit(event, ...args);\r\n }\r\n else if (!devtoolsNotInstalled) {\r\n buffer.push({ event, args });\r\n }\r\n}\r\nfunction setDevtoolsHook(hook, target) {\r\n var _a, _b;\r\n devtools = hook;\r\n if (devtools) {\r\n devtools.enabled = true;\r\n buffer.forEach(({ event, args }) => devtools.emit(event, ...args));\r\n buffer = [];\r\n }\r\n else if (\r\n // handle late devtools injection - only do this if we are in an actual\r\n // browser environment to avoid the timer handle stalling test runner exit\r\n // (#4815)\r\n // eslint-disable-next-line no-restricted-globals\r\n typeof window !== 'undefined' &&\r\n // some envs mock window but not fully\r\n window.HTMLElement &&\r\n // also exclude jsdom\r\n !((_b = (_a = window.navigator) === null || _a === void 0 ? void 0 : _a.userAgent) === null || _b === void 0 ? void 0 : _b.includes('jsdom'))) {\r\n const replay = (target.__VUE_DEVTOOLS_HOOK_REPLAY__ =\r\n target.__VUE_DEVTOOLS_HOOK_REPLAY__ || []);\r\n replay.push((newHook) => {\r\n setDevtoolsHook(newHook, target);\r\n });\r\n // clear buffer after 3s - the user probably doesn't have devtools installed\r\n // at all, and keeping the buffer will cause memory leaks (#4738)\r\n setTimeout(() => {\r\n if (!devtools) {\r\n target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;\r\n devtoolsNotInstalled = true;\r\n buffer = [];\r\n }\r\n }, 3000);\r\n }\r\n else {\r\n // non-browser env, assume not installed\r\n devtoolsNotInstalled = true;\r\n buffer = [];\r\n }\r\n}\r\nfunction devtoolsInitApp(app, version) {\r\n emit(\"app:init\" /* APP_INIT */, app, version, {\r\n Fragment,\r\n Text,\r\n Comment,\r\n Static\r\n });\r\n}\r\nfunction devtoolsUnmountApp(app) {\r\n emit(\"app:unmount\" /* APP_UNMOUNT */, app);\r\n}\r\nconst devtoolsComponentAdded = /*#__PURE__*/ createDevtoolsComponentHook(\"component:added\" /* COMPONENT_ADDED */);\r\nconst devtoolsComponentUpdated = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:updated\" /* COMPONENT_UPDATED */);\r\nconst devtoolsComponentRemoved = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:removed\" /* COMPONENT_REMOVED */);\r\nfunction createDevtoolsComponentHook(hook) {\r\n return (component) => {\r\n emit(hook, component.appContext.app, component.uid, component.parent ? component.parent.uid : undefined, component);\r\n };\r\n}\r\nconst devtoolsPerfStart = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:start\" /* PERFORMANCE_START */);\r\nconst devtoolsPerfEnd = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:end\" /* PERFORMANCE_END */);\r\nfunction createDevtoolsPerformanceHook(hook) {\r\n return (component, type, time) => {\r\n emit(hook, component.appContext.app, component.uid, component, type, time);\r\n };\r\n}\r\nfunction devtoolsComponentEmit(component, event, params) {\r\n emit(\"component:emit\" /* COMPONENT_EMIT */, component.appContext.app, component, event, params);\r\n}\n\nfunction emit$1(instance, event, ...rawArgs) {\r\n const props = instance.vnode.props || EMPTY_OBJ;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const { emitsOptions, propsOptions: [propsOptions] } = instance;\r\n if (emitsOptions) {\r\n if (!(event in emitsOptions) &&\r\n !(false )) {\r\n if (!propsOptions || !(toHandlerKey(event) in propsOptions)) {\r\n warn(`Component emitted event \"${event}\" but it is neither declared in ` +\r\n `the emits option nor as an \"${toHandlerKey(event)}\" prop.`);\r\n }\r\n }\r\n else {\r\n const validator = emitsOptions[event];\r\n if (isFunction(validator)) {\r\n const isValid = validator(...rawArgs);\r\n if (!isValid) {\r\n warn(`Invalid event arguments: event validation failed for event \"${event}\".`);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n let args = rawArgs;\r\n const isModelListener = event.startsWith('update:');\r\n // for v-model update:xxx events, apply modifiers on args\r\n const modelArg = isModelListener && event.slice(7);\r\n if (modelArg && modelArg in props) {\r\n const modifiersKey = `${modelArg === 'modelValue' ? 'model' : modelArg}Modifiers`;\r\n const { number, trim } = props[modifiersKey] || EMPTY_OBJ;\r\n if (trim) {\r\n args = rawArgs.map(a => a.trim());\r\n }\r\n else if (number) {\r\n args = rawArgs.map(toNumber);\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentEmit(instance, event, args);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const lowerCaseEvent = event.toLowerCase();\r\n if (lowerCaseEvent !== event && props[toHandlerKey(lowerCaseEvent)]) {\r\n warn(`Event \"${lowerCaseEvent}\" is emitted in component ` +\r\n `${formatComponentName(instance, instance.type)} but the handler is registered for \"${event}\". ` +\r\n `Note that HTML attributes are case-insensitive and you cannot use ` +\r\n `v-on to listen to camelCase events when using in-DOM templates. ` +\r\n `You should probably use \"${hyphenate(event)}\" instead of \"${event}\".`);\r\n }\r\n }\r\n let handlerName;\r\n let handler = props[(handlerName = toHandlerKey(event))] ||\r\n // also try camelCase event handler (#2249)\r\n props[(handlerName = toHandlerKey(camelize(event)))];\r\n // for v-model update:xxx events, also trigger kebab-case equivalent\r\n // for props passed via kebab-case\r\n if (!handler && isModelListener) {\r\n handler = props[(handlerName = toHandlerKey(hyphenate(event)))];\r\n }\r\n if (handler) {\r\n callWithAsyncErrorHandling(handler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n }\r\n const onceHandler = props[handlerName + `Once`];\r\n if (onceHandler) {\r\n if (!instance.emitted) {\r\n instance.emitted = {};\r\n }\r\n else if (instance.emitted[handlerName]) {\r\n return;\r\n }\r\n instance.emitted[handlerName] = true;\r\n callWithAsyncErrorHandling(onceHandler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n }\r\n}\r\nfunction normalizeEmitsOptions(comp, appContext, asMixin = false) {\r\n const cache = appContext.emitsCache;\r\n const cached = cache.get(comp);\r\n if (cached !== undefined) {\r\n return cached;\r\n }\r\n const raw = comp.emits;\r\n let normalized = {};\r\n // apply mixin/extends props\r\n let hasExtends = false;\r\n if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n const extendEmits = (raw) => {\r\n const normalizedFromExtend = normalizeEmitsOptions(raw, appContext, true);\r\n if (normalizedFromExtend) {\r\n hasExtends = true;\r\n extend(normalized, normalizedFromExtend);\r\n }\r\n };\r\n if (!asMixin && appContext.mixins.length) {\r\n appContext.mixins.forEach(extendEmits);\r\n }\r\n if (comp.extends) {\r\n extendEmits(comp.extends);\r\n }\r\n if (comp.mixins) {\r\n comp.mixins.forEach(extendEmits);\r\n }\r\n }\r\n if (!raw && !hasExtends) {\r\n cache.set(comp, null);\r\n return null;\r\n }\r\n if (isArray(raw)) {\r\n raw.forEach(key => (normalized[key] = null));\r\n }\r\n else {\r\n extend(normalized, raw);\r\n }\r\n cache.set(comp, normalized);\r\n return normalized;\r\n}\r\n// Check if an incoming prop key is a declared emit event listener.\r\n// e.g. With `emits: { click: null }`, props named `onClick` and `onclick` are\r\n// both considered matched listeners.\r\nfunction isEmitListener(options, key) {\r\n if (!options || !isOn(key)) {\r\n return false;\r\n }\r\n key = key.slice(2).replace(/Once$/, '');\r\n return (hasOwn(options, key[0].toLowerCase() + key.slice(1)) ||\r\n hasOwn(options, hyphenate(key)) ||\r\n hasOwn(options, key));\r\n}\n\n/**\r\n * mark the current rendering instance for asset resolution (e.g.\r\n * resolveComponent, resolveDirective) during render\r\n */\r\nlet currentRenderingInstance = null;\r\nlet currentScopeId = null;\r\n/**\r\n * Note: rendering calls maybe nested. The function returns the parent rendering\r\n * instance if present, which should be restored after the render is done:\r\n *\r\n * ```js\r\n * const prev = setCurrentRenderingInstance(i)\r\n * // ...render\r\n * setCurrentRenderingInstance(prev)\r\n * ```\r\n */\r\nfunction setCurrentRenderingInstance(instance) {\r\n const prev = currentRenderingInstance;\r\n currentRenderingInstance = instance;\r\n currentScopeId = (instance && instance.type.__scopeId) || null;\r\n return prev;\r\n}\r\n/**\r\n * Set scope id when creating hoisted vnodes.\r\n * @private compiler helper\r\n */\r\nfunction pushScopeId(id) {\r\n currentScopeId = id;\r\n}\r\n/**\r\n * Technically we no longer need this after 3.0.8 but we need to keep the same\r\n * API for backwards compat w/ code generated by compilers.\r\n * @private\r\n */\r\nfunction popScopeId() {\r\n currentScopeId = null;\r\n}\r\n/**\r\n * Only for backwards compat\r\n * @private\r\n */\r\nconst withScopeId = (_id) => withCtx;\r\n/**\r\n * Wrap a slot function to memoize current rendering instance\r\n * @private compiler helper\r\n */\r\nfunction withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot // false only\r\n) {\r\n if (!ctx)\r\n return fn;\r\n // already normalized\r\n if (fn._n) {\r\n return fn;\r\n }\r\n const renderFnWithContext = (...args) => {\r\n // If a user calls a compiled slot inside a template expression (#1745), it\r\n // can mess up block tracking, so by default we disable block tracking and\r\n // force bail out when invoking a compiled slot (indicated by the ._d flag).\r\n // This isn't necessary if rendering a compiled `<slot>`, so we flip the\r\n // ._d flag off when invoking the wrapped fn inside `renderSlot`.\r\n if (renderFnWithContext._d) {\r\n setBlockTracking(-1);\r\n }\r\n const prevInstance = setCurrentRenderingInstance(ctx);\r\n const res = fn(...args);\r\n setCurrentRenderingInstance(prevInstance);\r\n if (renderFnWithContext._d) {\r\n setBlockTracking(1);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentUpdated(ctx);\r\n }\r\n return res;\r\n };\r\n // mark normalized to avoid duplicated wrapping\r\n renderFnWithContext._n = true;\r\n // mark this as compiled by default\r\n // this is used in vnode.ts -> normalizeChildren() to set the slot\r\n // rendering flag.\r\n renderFnWithContext._c = true;\r\n // disable block tracking by default\r\n renderFnWithContext._d = true;\r\n return renderFnWithContext;\r\n}\n\n/**\r\n * dev only flag to track whether $attrs was used during render.\r\n * If $attrs was used during render then the warning for failed attrs\r\n * fallthrough can be suppressed.\r\n */\r\nlet accessedAttrs = false;\r\nfunction markAttrsAccessed() {\r\n accessedAttrs = true;\r\n}\r\nfunction renderComponentRoot(instance) {\r\n const { type: Component, vnode, proxy, withProxy, props, propsOptions: [propsOptions], slots, attrs, emit, render, renderCache, data, setupState, ctx, inheritAttrs } = instance;\r\n let result;\r\n let fallthroughAttrs;\r\n const prev = setCurrentRenderingInstance(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n accessedAttrs = false;\r\n }\r\n try {\r\n if (vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */) {\r\n // withProxy is a proxy with a different `has` trap only for\r\n // runtime-compiled render functions using `with` block.\r\n const proxyToUse = withProxy || proxy;\r\n result = normalizeVNode(render.call(proxyToUse, proxyToUse, renderCache, props, setupState, data, ctx));\r\n fallthroughAttrs = attrs;\r\n }\r\n else {\r\n // functional\r\n const render = Component;\r\n // in dev, mark attrs accessed if optional props (attrs === props)\r\n if ((process.env.NODE_ENV !== 'production') && attrs === props) {\r\n markAttrsAccessed();\r\n }\r\n result = normalizeVNode(render.length > 1\r\n ? render(props, (process.env.NODE_ENV !== 'production')\r\n ? {\r\n get attrs() {\r\n markAttrsAccessed();\r\n return attrs;\r\n },\r\n slots,\r\n emit\r\n }\r\n : { attrs, slots, emit })\r\n : render(props, null /* we know it doesn't need it */));\r\n fallthroughAttrs = Component.props\r\n ? attrs\r\n : getFunctionalFallthrough(attrs);\r\n }\r\n }\r\n catch (err) {\r\n blockStack.length = 0;\r\n handleError(err, instance, 1 /* RENDER_FUNCTION */);\r\n result = createVNode(Comment);\r\n }\r\n // attr merging\r\n // in dev mode, comments are preserved, and it's possible for a template\r\n // to have comments along side the root element which makes it a fragment\r\n let root = result;\r\n let setRoot = undefined;\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n result.patchFlag > 0 &&\r\n result.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n [root, setRoot] = getChildRoot(result);\r\n }\r\n if (fallthroughAttrs && inheritAttrs !== false) {\r\n const keys = Object.keys(fallthroughAttrs);\r\n const { shapeFlag } = root;\r\n if (keys.length) {\r\n if (shapeFlag & (1 /* ELEMENT */ | 6 /* COMPONENT */)) {\r\n if (propsOptions && keys.some(isModelListener)) {\r\n // If a v-model listener (onUpdate:xxx) has a corresponding declared\r\n // prop, it indicates this component expects to handle v-model and\r\n // it should not fallthrough.\r\n // related: #1543, #1643, #1989\r\n fallthroughAttrs = filterModelListeners(fallthroughAttrs, propsOptions);\r\n }\r\n root = cloneVNode(root, fallthroughAttrs);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && !accessedAttrs && root.type !== Comment) {\r\n const allAttrs = Object.keys(attrs);\r\n const eventAttrs = [];\r\n const extraAttrs = [];\r\n for (let i = 0, l = allAttrs.length; i < l; i++) {\r\n const key = allAttrs[i];\r\n if (isOn(key)) {\r\n // ignore v-model handlers when they fail to fallthrough\r\n if (!isModelListener(key)) {\r\n // remove `on`, lowercase first letter to reflect event casing\r\n // accurately\r\n eventAttrs.push(key[2].toLowerCase() + key.slice(3));\r\n }\r\n }\r\n else {\r\n extraAttrs.push(key);\r\n }\r\n }\r\n if (extraAttrs.length) {\r\n warn(`Extraneous non-props attributes (` +\r\n `${extraAttrs.join(', ')}) ` +\r\n `were passed to component but could not be automatically inherited ` +\r\n `because component renders fragment or text root nodes.`);\r\n }\r\n if (eventAttrs.length) {\r\n warn(`Extraneous non-emits event listeners (` +\r\n `${eventAttrs.join(', ')}) ` +\r\n `were passed to component but could not be automatically inherited ` +\r\n `because component renders fragment or text root nodes. ` +\r\n `If the listener is intended to be a component custom event listener only, ` +\r\n `declare it using the \"emits\" option.`);\r\n }\r\n }\r\n }\r\n }\r\n // inherit directives\r\n if (vnode.dirs) {\r\n if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n warn(`Runtime directive used on component with non-element root node. ` +\r\n `The directives will not function as intended.`);\r\n }\r\n root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;\r\n }\r\n // inherit transition data\r\n if (vnode.transition) {\r\n if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n warn(`Component inside <Transition> renders non-element root node ` +\r\n `that cannot be animated.`);\r\n }\r\n root.transition = vnode.transition;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && setRoot) {\r\n setRoot(root);\r\n }\r\n else {\r\n result = root;\r\n }\r\n setCurrentRenderingInstance(prev);\r\n return result;\r\n}\r\n/**\r\n * dev only\r\n * In dev mode, template root level comments are rendered, which turns the\r\n * template into a fragment root, but we need to locate the single element\r\n * root for attrs and scope id processing.\r\n */\r\nconst getChildRoot = (vnode) => {\r\n const rawChildren = vnode.children;\r\n const dynamicChildren = vnode.dynamicChildren;\r\n const childRoot = filterSingleRoot(rawChildren);\r\n if (!childRoot) {\r\n return [vnode, undefined];\r\n }\r\n const index = rawChildren.indexOf(childRoot);\r\n const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;\r\n const setRoot = (updatedRoot) => {\r\n rawChildren[index] = updatedRoot;\r\n if (dynamicChildren) {\r\n if (dynamicIndex > -1) {\r\n dynamicChildren[dynamicIndex] = updatedRoot;\r\n }\r\n else if (updatedRoot.patchFlag > 0) {\r\n vnode.dynamicChildren = [...dynamicChildren, updatedRoot];\r\n }\r\n }\r\n };\r\n return [normalizeVNode(childRoot), setRoot];\r\n};\r\nfunction filterSingleRoot(children) {\r\n let singleRoot;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isVNode(child)) {\r\n // ignore user comment\r\n if (child.type !== Comment || child.children === 'v-if') {\r\n if (singleRoot) {\r\n // has more than 1 non-comment child, return now\r\n return;\r\n }\r\n else {\r\n singleRoot = child;\r\n }\r\n }\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n return singleRoot;\r\n}\r\nconst getFunctionalFallthrough = (attrs) => {\r\n let res;\r\n for (const key in attrs) {\r\n if (key === 'class' || key === 'style' || isOn(key)) {\r\n (res || (res = {}))[key] = attrs[key];\r\n }\r\n }\r\n return res;\r\n};\r\nconst filterModelListeners = (attrs, props) => {\r\n const res = {};\r\n for (const key in attrs) {\r\n if (!isModelListener(key) || !(key.slice(9) in props)) {\r\n res[key] = attrs[key];\r\n }\r\n }\r\n return res;\r\n};\r\nconst isElementRoot = (vnode) => {\r\n return (vnode.shapeFlag & (6 /* COMPONENT */ | 1 /* ELEMENT */) ||\r\n vnode.type === Comment // potential v-if branch switch\r\n );\r\n};\r\nfunction shouldUpdateComponent(prevVNode, nextVNode, optimized) {\r\n const { props: prevProps, children: prevChildren, component } = prevVNode;\r\n const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;\r\n const emits = component.emitsOptions;\r\n // Parent component's render function was hot-updated. Since this may have\r\n // caused the child component's slots content to have changed, we need to\r\n // force the child to update as well.\r\n if ((process.env.NODE_ENV !== 'production') && (prevChildren || nextChildren) && isHmrUpdating) {\r\n return true;\r\n }\r\n // force child update for runtime directive or transition on component vnode.\r\n if (nextVNode.dirs || nextVNode.transition) {\r\n return true;\r\n }\r\n if (optimized && patchFlag >= 0) {\r\n if (patchFlag & 1024 /* DYNAMIC_SLOTS */) {\r\n // slot content that references values that might have changed,\r\n // e.g. in a v-for\r\n return true;\r\n }\r\n if (patchFlag & 16 /* FULL_PROPS */) {\r\n if (!prevProps) {\r\n return !!nextProps;\r\n }\r\n // presence of this flag indicates props are always non-null\r\n return hasPropsChanged(prevProps, nextProps, emits);\r\n }\r\n else if (patchFlag & 8 /* PROPS */) {\r\n const dynamicProps = nextVNode.dynamicProps;\r\n for (let i = 0; i < dynamicProps.length; i++) {\r\n const key = dynamicProps[i];\r\n if (nextProps[key] !== prevProps[key] &&\r\n !isEmitListener(emits, key)) {\r\n return true;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // this path is only taken by manually written render functions\r\n // so presence of any children leads to a forced update\r\n if (prevChildren || nextChildren) {\r\n if (!nextChildren || !nextChildren.$stable) {\r\n return true;\r\n }\r\n }\r\n if (prevProps === nextProps) {\r\n return false;\r\n }\r\n if (!prevProps) {\r\n return !!nextProps;\r\n }\r\n if (!nextProps) {\r\n return true;\r\n }\r\n return hasPropsChanged(prevProps, nextProps, emits);\r\n }\r\n return false;\r\n}\r\nfunction hasPropsChanged(prevProps, nextProps, emitsOptions) {\r\n const nextKeys = Object.keys(nextProps);\r\n if (nextKeys.length !== Object.keys(prevProps).length) {\r\n return true;\r\n }\r\n for (let i = 0; i < nextKeys.length; i++) {\r\n const key = nextKeys[i];\r\n if (nextProps[key] !== prevProps[key] &&\r\n !isEmitListener(emitsOptions, key)) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}\r\nfunction updateHOCHostEl({ vnode, parent }, el // HostNode\r\n) {\r\n while (parent && parent.subTree === vnode) {\r\n (vnode = parent.vnode).el = el;\r\n parent = parent.parent;\r\n }\r\n}\n\nconst isSuspense = (type) => type.__isSuspense;\r\n// Suspense exposes a component-like API, and is treated like a component\r\n// in the compiler, but internally it's a special built-in type that hooks\r\n// directly into the renderer.\r\nconst SuspenseImpl = {\r\n name: 'Suspense',\r\n // In order to make Suspense tree-shakable, we need to avoid importing it\r\n // directly in the renderer. The renderer checks for the __isSuspense flag\r\n // on a vnode's type and calls the `process` method, passing in renderer\r\n // internals.\r\n __isSuspense: true,\r\n process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, \r\n // platform-specific impl passed from renderer\r\n rendererInternals) {\r\n if (n1 == null) {\r\n mountSuspense(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals);\r\n }\r\n else {\r\n patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, rendererInternals);\r\n }\r\n },\r\n hydrate: hydrateSuspense,\r\n create: createSuspenseBoundary,\r\n normalize: normalizeSuspenseChildren\r\n};\r\n// Force-casted public typing for h and TSX props inference\r\nconst Suspense = (SuspenseImpl );\r\nfunction triggerEvent(vnode, name) {\r\n const eventListener = vnode.props && vnode.props[name];\r\n if (isFunction(eventListener)) {\r\n eventListener();\r\n }\r\n}\r\nfunction mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) {\r\n const { p: patch, o: { createElement } } = rendererInternals;\r\n const hiddenContainer = createElement('div');\r\n const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals));\r\n // start mounting the content subtree in an off-dom container\r\n patch(null, (suspense.pendingBranch = vnode.ssContent), hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds);\r\n // now check if we have encountered any async deps\r\n if (suspense.deps > 0) {\r\n // has async\r\n // invoke @fallback event\r\n triggerEvent(vnode, 'onPending');\r\n triggerEvent(vnode, 'onFallback');\r\n // mount the fallback tree\r\n patch(null, vnode.ssFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds);\r\n setActiveBranch(suspense, vnode.ssFallback);\r\n }\r\n else {\r\n // Suspense has no async deps. Just resolve.\r\n suspense.resolve();\r\n }\r\n}\r\nfunction patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) {\r\n const suspense = (n2.suspense = n1.suspense);\r\n suspense.vnode = n2;\r\n n2.el = n1.el;\r\n const newBranch = n2.ssContent;\r\n const newFallback = n2.ssFallback;\r\n const { activeBranch, pendingBranch, isInFallback, isHydrating } = suspense;\r\n if (pendingBranch) {\r\n suspense.pendingBranch = newBranch;\r\n if (isSameVNodeType(newBranch, pendingBranch)) {\r\n // same root type but content may have changed.\r\n patch(pendingBranch, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n else if (isInFallback) {\r\n patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newFallback);\r\n }\r\n }\r\n else {\r\n // toggled before pending tree is resolved\r\n suspense.pendingId++;\r\n if (isHydrating) {\r\n // if toggled before hydration is finished, the current DOM tree is\r\n // no longer valid. set it as the active branch so it will be unmounted\r\n // when resolved\r\n suspense.isHydrating = false;\r\n suspense.activeBranch = pendingBranch;\r\n }\r\n else {\r\n unmount(pendingBranch, parentComponent, suspense);\r\n }\r\n // increment pending ID. this is used to invalidate async callbacks\r\n // reset suspense state\r\n suspense.deps = 0;\r\n // discard effects from pending branch\r\n suspense.effects.length = 0;\r\n // discard previous container\r\n suspense.hiddenContainer = createElement('div');\r\n if (isInFallback) {\r\n // already in fallback state\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n else {\r\n patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newFallback);\r\n }\r\n }\r\n else if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n // toggled \"back\" to current active branch\r\n patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n // force resolve\r\n suspense.resolve(true);\r\n }\r\n else {\r\n // switched to a 3rd branch\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n // root did not change, just normal patch\r\n patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newBranch);\r\n }\r\n else {\r\n // root node toggled\r\n // invoke @pending event\r\n triggerEvent(n2, 'onPending');\r\n // mount pending branch in off-dom container\r\n suspense.pendingBranch = newBranch;\r\n suspense.pendingId++;\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n // incoming branch has no async deps, resolve now.\r\n suspense.resolve();\r\n }\r\n else {\r\n const { timeout, pendingId } = suspense;\r\n if (timeout > 0) {\r\n setTimeout(() => {\r\n if (suspense.pendingId === pendingId) {\r\n suspense.fallback(newFallback);\r\n }\r\n }, timeout);\r\n }\r\n else if (timeout === 0) {\r\n suspense.fallback(newFallback);\r\n }\r\n }\r\n }\r\n }\r\n}\r\nlet hasWarned = false;\r\nfunction createSuspenseBoundary(vnode, parent, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals, isHydrating = false) {\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production') && !false && !hasWarned) {\r\n hasWarned = true;\r\n // @ts-ignore `console.info` cannot be null error\r\n console[console.info ? 'info' : 'log'](`<Suspense> is an experimental feature and its API will likely change.`);\r\n }\r\n const { p: patch, m: move, um: unmount, n: next, o: { parentNode, remove } } = rendererInternals;\r\n const timeout = toNumber(vnode.props && vnode.props.timeout);\r\n const suspense = {\r\n vnode,\r\n parent,\r\n parentComponent,\r\n isSVG,\r\n container,\r\n hiddenContainer,\r\n anchor,\r\n deps: 0,\r\n pendingId: 0,\r\n timeout: typeof timeout === 'number' ? timeout : -1,\r\n activeBranch: null,\r\n pendingBranch: null,\r\n isInFallback: true,\r\n isHydrating,\r\n isUnmounted: false,\r\n effects: [],\r\n resolve(resume = false) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!resume && !suspense.pendingBranch) {\r\n throw new Error(`suspense.resolve() is called without a pending branch.`);\r\n }\r\n if (suspense.isUnmounted) {\r\n throw new Error(`suspense.resolve() is called on an already unmounted suspense boundary.`);\r\n }\r\n }\r\n const { vnode, activeBranch, pendingBranch, pendingId, effects, parentComponent, container } = suspense;\r\n if (suspense.isHydrating) {\r\n suspense.isHydrating = false;\r\n }\r\n else if (!resume) {\r\n const delayEnter = activeBranch &&\r\n pendingBranch.transition &&\r\n pendingBranch.transition.mode === 'out-in';\r\n if (delayEnter) {\r\n activeBranch.transition.afterLeave = () => {\r\n if (pendingId === suspense.pendingId) {\r\n move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n }\r\n };\r\n }\r\n // this is initial anchor on mount\r\n let { anchor } = suspense;\r\n // unmount current active tree\r\n if (activeBranch) {\r\n // if the fallback tree was mounted, it may have been moved\r\n // as part of a parent suspense. get the latest anchor for insertion\r\n anchor = next(activeBranch);\r\n unmount(activeBranch, parentComponent, suspense, true);\r\n }\r\n if (!delayEnter) {\r\n // move content from off-dom container to actual container\r\n move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n }\r\n }\r\n setActiveBranch(suspense, pendingBranch);\r\n suspense.pendingBranch = null;\r\n suspense.isInFallback = false;\r\n // flush buffered effects\r\n // check if there is a pending parent suspense\r\n let parent = suspense.parent;\r\n let hasUnresolvedAncestor = false;\r\n while (parent) {\r\n if (parent.pendingBranch) {\r\n // found a pending parent suspense, merge buffered post jobs\r\n // into that parent\r\n parent.effects.push(...effects);\r\n hasUnresolvedAncestor = true;\r\n break;\r\n }\r\n parent = parent.parent;\r\n }\r\n // no pending parent suspense, flush all jobs\r\n if (!hasUnresolvedAncestor) {\r\n queuePostFlushCb(effects);\r\n }\r\n suspense.effects = [];\r\n // invoke @resolve event\r\n triggerEvent(vnode, 'onResolve');\r\n },\r\n fallback(fallbackVNode) {\r\n if (!suspense.pendingBranch) {\r\n return;\r\n }\r\n const { vnode, activeBranch, parentComponent, container, isSVG } = suspense;\r\n // invoke @fallback event\r\n triggerEvent(vnode, 'onFallback');\r\n const anchor = next(activeBranch);\r\n const mountFallback = () => {\r\n if (!suspense.isInFallback) {\r\n return;\r\n }\r\n // mount the fallback tree\r\n patch(null, fallbackVNode, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, fallbackVNode);\r\n };\r\n const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === 'out-in';\r\n if (delayEnter) {\r\n activeBranch.transition.afterLeave = mountFallback;\r\n }\r\n suspense.isInFallback = true;\r\n // unmount current active branch\r\n unmount(activeBranch, parentComponent, null, // no suspense so unmount hooks fire now\r\n true // shouldRemove\r\n );\r\n if (!delayEnter) {\r\n mountFallback();\r\n }\r\n },\r\n move(container, anchor, type) {\r\n suspense.activeBranch &&\r\n move(suspense.activeBranch, container, anchor, type);\r\n suspense.container = container;\r\n },\r\n next() {\r\n return suspense.activeBranch && next(suspense.activeBranch);\r\n },\r\n registerDep(instance, setupRenderEffect) {\r\n const isInPendingSuspense = !!suspense.pendingBranch;\r\n if (isInPendingSuspense) {\r\n suspense.deps++;\r\n }\r\n const hydratedEl = instance.vnode.el;\r\n instance\r\n .asyncDep.catch(err => {\r\n handleError(err, instance, 0 /* SETUP_FUNCTION */);\r\n })\r\n .then(asyncSetupResult => {\r\n // retry when the setup() promise resolves.\r\n // component may have been unmounted before resolve.\r\n if (instance.isUnmounted ||\r\n suspense.isUnmounted ||\r\n suspense.pendingId !== instance.suspenseId) {\r\n return;\r\n }\r\n // retry from this component\r\n instance.asyncResolved = true;\r\n const { vnode } = instance;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(vnode);\r\n }\r\n handleSetupResult(instance, asyncSetupResult, false);\r\n if (hydratedEl) {\r\n // vnode may have been replaced if an update happened before the\r\n // async dep is resolved.\r\n vnode.el = hydratedEl;\r\n }\r\n const placeholder = !hydratedEl && instance.subTree.el;\r\n setupRenderEffect(instance, vnode, \r\n // component may have been moved before resolve.\r\n // if this is not a hydration, instance.subTree will be the comment\r\n // placeholder.\r\n parentNode(hydratedEl || instance.subTree.el), \r\n // anchor will not be used if this is hydration, so only need to\r\n // consider the comment placeholder case.\r\n hydratedEl ? null : next(instance.subTree), suspense, isSVG, optimized);\r\n if (placeholder) {\r\n remove(placeholder);\r\n }\r\n updateHOCHostEl(instance, vnode.el);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n // only decrease deps count if suspense is not already resolved\r\n if (isInPendingSuspense && --suspense.deps === 0) {\r\n suspense.resolve();\r\n }\r\n });\r\n },\r\n unmount(parentSuspense, doRemove) {\r\n suspense.isUnmounted = true;\r\n if (suspense.activeBranch) {\r\n unmount(suspense.activeBranch, parentComponent, parentSuspense, doRemove);\r\n }\r\n if (suspense.pendingBranch) {\r\n unmount(suspense.pendingBranch, parentComponent, parentSuspense, doRemove);\r\n }\r\n }\r\n };\r\n return suspense;\r\n}\r\nfunction hydrateSuspense(node, vnode, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals, hydrateNode) {\r\n /* eslint-disable no-restricted-globals */\r\n const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, node.parentNode, document.createElement('div'), null, isSVG, slotScopeIds, optimized, rendererInternals, true /* hydrating */));\r\n // there are two possible scenarios for server-rendered suspense:\r\n // - success: ssr content should be fully resolved\r\n // - failure: ssr content should be the fallback branch.\r\n // however, on the client we don't really know if it has failed or not\r\n // attempt to hydrate the DOM assuming it has succeeded, but we still\r\n // need to construct a suspense boundary first\r\n const result = hydrateNode(node, (suspense.pendingBranch = vnode.ssContent), parentComponent, suspense, slotScopeIds, optimized);\r\n if (suspense.deps === 0) {\r\n suspense.resolve();\r\n }\r\n return result;\r\n /* eslint-enable no-restricted-globals */\r\n}\r\nfunction normalizeSuspenseChildren(vnode) {\r\n const { shapeFlag, children } = vnode;\r\n const isSlotChildren = shapeFlag & 32 /* SLOTS_CHILDREN */;\r\n vnode.ssContent = normalizeSuspenseSlot(isSlotChildren ? children.default : children);\r\n vnode.ssFallback = isSlotChildren\r\n ? normalizeSuspenseSlot(children.fallback)\r\n : createVNode(Comment);\r\n}\r\nfunction normalizeSuspenseSlot(s) {\r\n let block;\r\n if (isFunction(s)) {\r\n const trackBlock = isBlockTreeEnabled && s._c;\r\n if (trackBlock) {\r\n // disableTracking: false\r\n // allow block tracking for compiled slots\r\n // (see ./componentRenderContext.ts)\r\n s._d = false;\r\n openBlock();\r\n }\r\n s = s();\r\n if (trackBlock) {\r\n s._d = true;\r\n block = currentBlock;\r\n closeBlock();\r\n }\r\n }\r\n if (isArray(s)) {\r\n const singleChild = filterSingleRoot(s);\r\n if ((process.env.NODE_ENV !== 'production') && !singleChild) {\r\n warn(`<Suspense> slots expect a single root node.`);\r\n }\r\n s = singleChild;\r\n }\r\n s = normalizeVNode(s);\r\n if (block && !s.dynamicChildren) {\r\n s.dynamicChildren = block.filter(c => c !== s);\r\n }\r\n return s;\r\n}\r\nfunction queueEffectWithSuspense(fn, suspense) {\r\n if (suspense && suspense.pendingBranch) {\r\n if (isArray(fn)) {\r\n suspense.effects.push(...fn);\r\n }\r\n else {\r\n suspense.effects.push(fn);\r\n }\r\n }\r\n else {\r\n queuePostFlushCb(fn);\r\n }\r\n}\r\nfunction setActiveBranch(suspense, branch) {\r\n suspense.activeBranch = branch;\r\n const { vnode, parentComponent } = suspense;\r\n const el = (vnode.el = branch.el);\r\n // in case suspense is the root node of a component,\r\n // recursively update the HOC el\r\n if (parentComponent && parentComponent.subTree === vnode) {\r\n parentComponent.vnode.el = el;\r\n updateHOCHostEl(parentComponent, el);\r\n }\r\n}\n\nfunction provide(key, value) {\r\n if (!currentInstance) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`provide() can only be used inside setup().`);\r\n }\r\n }\r\n else {\r\n let provides = currentInstance.provides;\r\n // by default an instance inherits its parent's provides object\r\n // but when it needs to provide values of its own, it creates its\r\n // own provides object using parent provides object as prototype.\r\n // this way in `inject` we can simply look up injections from direct\r\n // parent and let the prototype chain do the work.\r\n const parentProvides = currentInstance.parent && currentInstance.parent.provides;\r\n if (parentProvides === provides) {\r\n provides = currentInstance.provides = Object.create(parentProvides);\r\n }\r\n // TS doesn't allow symbol as index type\r\n provides[key] = value;\r\n }\r\n}\r\nfunction inject(key, defaultValue, treatDefaultAsFactory = false) {\r\n // fallback to `currentRenderingInstance` so that this can be called in\r\n // a functional component\r\n const instance = currentInstance || currentRenderingInstance;\r\n if (instance) {\r\n // #2400\r\n // to support `app.use` plugins,\r\n // fallback to appContext's `provides` if the intance is at root\r\n const provides = instance.parent == null\r\n ? instance.vnode.appContext && instance.vnode.appContext.provides\r\n : instance.parent.provides;\r\n if (provides && key in provides) {\r\n // TS doesn't allow symbol as index type\r\n return provides[key];\r\n }\r\n else if (arguments.length > 1) {\r\n return treatDefaultAsFactory && isFunction(defaultValue)\r\n ? defaultValue.call(instance.proxy)\r\n : defaultValue;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`injection \"${String(key)}\" not found.`);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`inject() can only be used inside setup() or functional components.`);\r\n }\r\n}\n\nfunction useTransitionState() {\r\n const state = {\r\n isMounted: false,\r\n isLeaving: false,\r\n isUnmounting: false,\r\n leavingVNodes: new Map()\r\n };\r\n onMounted(() => {\r\n state.isMounted = true;\r\n });\r\n onBeforeUnmount(() => {\r\n state.isUnmounting = true;\r\n });\r\n return state;\r\n}\r\nconst TransitionHookValidator = [Function, Array];\r\nconst BaseTransitionImpl = {\r\n name: `BaseTransition`,\r\n props: {\r\n mode: String,\r\n appear: Boolean,\r\n persisted: Boolean,\r\n // enter\r\n onBeforeEnter: TransitionHookValidator,\r\n onEnter: TransitionHookValidator,\r\n onAfterEnter: TransitionHookValidator,\r\n onEnterCancelled: TransitionHookValidator,\r\n // leave\r\n onBeforeLeave: TransitionHookValidator,\r\n onLeave: TransitionHookValidator,\r\n onAfterLeave: TransitionHookValidator,\r\n onLeaveCancelled: TransitionHookValidator,\r\n // appear\r\n onBeforeAppear: TransitionHookValidator,\r\n onAppear: TransitionHookValidator,\r\n onAfterAppear: TransitionHookValidator,\r\n onAppearCancelled: TransitionHookValidator\r\n },\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n const state = useTransitionState();\r\n let prevTransitionKey;\r\n return () => {\r\n const children = slots.default && getTransitionRawChildren(slots.default(), true);\r\n if (!children || !children.length) {\r\n return;\r\n }\r\n // warn multiple elements\r\n if ((process.env.NODE_ENV !== 'production') && children.length > 1) {\r\n warn('<transition> can only be used on a single element or component. Use ' +\r\n '<transition-group> for lists.');\r\n }\r\n // there's no need to track reactivity for these props so use the raw\r\n // props for a bit better perf\r\n const rawProps = toRaw(props);\r\n const { mode } = rawProps;\r\n // check mode\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n mode &&\r\n mode !== 'in-out' && mode !== 'out-in' && mode !== 'default') {\r\n warn(`invalid <transition> mode: ${mode}`);\r\n }\r\n // at this point children has a guaranteed length of 1.\r\n const child = children[0];\r\n if (state.isLeaving) {\r\n return emptyPlaceholder(child);\r\n }\r\n // in the case of <transition><keep-alive/></transition>, we need to\r\n // compare the type of the kept-alive children.\r\n const innerChild = getKeepAliveChild(child);\r\n if (!innerChild) {\r\n return emptyPlaceholder(child);\r\n }\r\n const enterHooks = resolveTransitionHooks(innerChild, rawProps, state, instance);\r\n setTransitionHooks(innerChild, enterHooks);\r\n const oldChild = instance.subTree;\r\n const oldInnerChild = oldChild && getKeepAliveChild(oldChild);\r\n let transitionKeyChanged = false;\r\n const { getTransitionKey } = innerChild.type;\r\n if (getTransitionKey) {\r\n const key = getTransitionKey();\r\n if (prevTransitionKey === undefined) {\r\n prevTransitionKey = key;\r\n }\r\n else if (key !== prevTransitionKey) {\r\n prevTransitionKey = key;\r\n transitionKeyChanged = true;\r\n }\r\n }\r\n // handle mode\r\n if (oldInnerChild &&\r\n oldInnerChild.type !== Comment &&\r\n (!isSameVNodeType(innerChild, oldInnerChild) || transitionKeyChanged)) {\r\n const leavingHooks = resolveTransitionHooks(oldInnerChild, rawProps, state, instance);\r\n // update old tree's hooks in case of dynamic transition\r\n setTransitionHooks(oldInnerChild, leavingHooks);\r\n // switching between different views\r\n if (mode === 'out-in') {\r\n state.isLeaving = true;\r\n // return placeholder node and queue update when leave finishes\r\n leavingHooks.afterLeave = () => {\r\n state.isLeaving = false;\r\n instance.update();\r\n };\r\n return emptyPlaceholder(child);\r\n }\r\n else if (mode === 'in-out' && innerChild.type !== Comment) {\r\n leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {\r\n const leavingVNodesCache = getLeavingNodesForType(state, oldInnerChild);\r\n leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;\r\n // early removal callback\r\n el._leaveCb = () => {\r\n earlyRemove();\r\n el._leaveCb = undefined;\r\n delete enterHooks.delayedLeave;\r\n };\r\n enterHooks.delayedLeave = delayedLeave;\r\n };\r\n }\r\n }\r\n return child;\r\n };\r\n }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst BaseTransition = BaseTransitionImpl;\r\nfunction getLeavingNodesForType(state, vnode) {\r\n const { leavingVNodes } = state;\r\n let leavingVNodesCache = leavingVNodes.get(vnode.type);\r\n if (!leavingVNodesCache) {\r\n leavingVNodesCache = Object.create(null);\r\n leavingVNodes.set(vnode.type, leavingVNodesCache);\r\n }\r\n return leavingVNodesCache;\r\n}\r\n// The transition hooks are attached to the vnode as vnode.transition\r\n// and will be called at appropriate timing in the renderer.\r\nfunction resolveTransitionHooks(vnode, props, state, instance) {\r\n const { appear, mode, persisted = false, onBeforeEnter, onEnter, onAfterEnter, onEnterCancelled, onBeforeLeave, onLeave, onAfterLeave, onLeaveCancelled, onBeforeAppear, onAppear, onAfterAppear, onAppearCancelled } = props;\r\n const key = String(vnode.key);\r\n const leavingVNodesCache = getLeavingNodesForType(state, vnode);\r\n const callHook = (hook, args) => {\r\n hook &&\r\n callWithAsyncErrorHandling(hook, instance, 9 /* TRANSITION_HOOK */, args);\r\n };\r\n const hooks = {\r\n mode,\r\n persisted,\r\n beforeEnter(el) {\r\n let hook = onBeforeEnter;\r\n if (!state.isMounted) {\r\n if (appear) {\r\n hook = onBeforeAppear || onBeforeEnter;\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n // for same element (v-show)\r\n if (el._leaveCb) {\r\n el._leaveCb(true /* cancelled */);\r\n }\r\n // for toggled element with same key (v-if)\r\n const leavingVNode = leavingVNodesCache[key];\r\n if (leavingVNode &&\r\n isSameVNodeType(vnode, leavingVNode) &&\r\n leavingVNode.el._leaveCb) {\r\n // force early removal (not cancelled)\r\n leavingVNode.el._leaveCb();\r\n }\r\n callHook(hook, [el]);\r\n },\r\n enter(el) {\r\n let hook = onEnter;\r\n let afterHook = onAfterEnter;\r\n let cancelHook = onEnterCancelled;\r\n if (!state.isMounted) {\r\n if (appear) {\r\n hook = onAppear || onEnter;\r\n afterHook = onAfterAppear || onAfterEnter;\r\n cancelHook = onAppearCancelled || onEnterCancelled;\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n let called = false;\r\n const done = (el._enterCb = (cancelled) => {\r\n if (called)\r\n return;\r\n called = true;\r\n if (cancelled) {\r\n callHook(cancelHook, [el]);\r\n }\r\n else {\r\n callHook(afterHook, [el]);\r\n }\r\n if (hooks.delayedLeave) {\r\n hooks.delayedLeave();\r\n }\r\n el._enterCb = undefined;\r\n });\r\n if (hook) {\r\n hook(el, done);\r\n if (hook.length <= 1) {\r\n done();\r\n }\r\n }\r\n else {\r\n done();\r\n }\r\n },\r\n leave(el, remove) {\r\n const key = String(vnode.key);\r\n if (el._enterCb) {\r\n el._enterCb(true /* cancelled */);\r\n }\r\n if (state.isUnmounting) {\r\n return remove();\r\n }\r\n callHook(onBeforeLeave, [el]);\r\n let called = false;\r\n const done = (el._leaveCb = (cancelled) => {\r\n if (called)\r\n return;\r\n called = true;\r\n remove();\r\n if (cancelled) {\r\n callHook(onLeaveCancelled, [el]);\r\n }\r\n else {\r\n callHook(onAfterLeave, [el]);\r\n }\r\n el._leaveCb = undefined;\r\n if (leavingVNodesCache[key] === vnode) {\r\n delete leavingVNodesCache[key];\r\n }\r\n });\r\n leavingVNodesCache[key] = vnode;\r\n if (onLeave) {\r\n onLeave(el, done);\r\n if (onLeave.length <= 1) {\r\n done();\r\n }\r\n }\r\n else {\r\n done();\r\n }\r\n },\r\n clone(vnode) {\r\n return resolveTransitionHooks(vnode, props, state, instance);\r\n }\r\n };\r\n return hooks;\r\n}\r\n// the placeholder really only handles one special case: KeepAlive\r\n// in the case of a KeepAlive in a leave phase we need to return a KeepAlive\r\n// placeholder with empty content to avoid the KeepAlive instance from being\r\n// unmounted.\r\nfunction emptyPlaceholder(vnode) {\r\n if (isKeepAlive(vnode)) {\r\n vnode = cloneVNode(vnode);\r\n vnode.children = null;\r\n return vnode;\r\n }\r\n}\r\nfunction getKeepAliveChild(vnode) {\r\n return isKeepAlive(vnode)\r\n ? vnode.children\r\n ? vnode.children[0]\r\n : undefined\r\n : vnode;\r\n}\r\nfunction setTransitionHooks(vnode, hooks) {\r\n if (vnode.shapeFlag & 6 /* COMPONENT */ && vnode.component) {\r\n setTransitionHooks(vnode.component.subTree, hooks);\r\n }\r\n else if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.ssContent.transition = hooks.clone(vnode.ssContent);\r\n vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);\r\n }\r\n else {\r\n vnode.transition = hooks;\r\n }\r\n}\r\nfunction getTransitionRawChildren(children, keepComment = false) {\r\n let ret = [];\r\n let keyedFragmentCount = 0;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n // handle fragment children case, e.g. v-for\r\n if (child.type === Fragment) {\r\n if (child.patchFlag & 128 /* KEYED_FRAGMENT */)\r\n keyedFragmentCount++;\r\n ret = ret.concat(getTransitionRawChildren(child.children, keepComment));\r\n }\r\n // comment placeholders should be skipped, e.g. v-if\r\n else if (keepComment || child.type !== Comment) {\r\n ret.push(child);\r\n }\r\n }\r\n // #1126 if a transition children list contains multiple sub fragments, these\r\n // fragments will be merged into a flat children array. Since each v-for\r\n // fragment may contain different static bindings inside, we need to de-op\r\n // these children to force full diffs to ensure correct behavior.\r\n if (keyedFragmentCount > 1) {\r\n for (let i = 0; i < ret.length; i++) {\r\n ret[i].patchFlag = -2 /* BAIL */;\r\n }\r\n }\r\n return ret;\r\n}\n\n// implementation, close to no-op\r\nfunction defineComponent(options) {\r\n return isFunction(options) ? { setup: options, name: options.name } : options;\r\n}\n\nconst isAsyncWrapper = (i) => !!i.type.__asyncLoader;\r\nfunction defineAsyncComponent(source) {\r\n if (isFunction(source)) {\r\n source = { loader: source };\r\n }\r\n const { loader, loadingComponent, errorComponent, delay = 200, timeout, // undefined = never times out\r\n suspensible = true, onError: userOnError } = source;\r\n let pendingRequest = null;\r\n let resolvedComp;\r\n let retries = 0;\r\n const retry = () => {\r\n retries++;\r\n pendingRequest = null;\r\n return load();\r\n };\r\n const load = () => {\r\n let thisRequest;\r\n return (pendingRequest ||\r\n (thisRequest = pendingRequest =\r\n loader()\r\n .catch(err => {\r\n err = err instanceof Error ? err : new Error(String(err));\r\n if (userOnError) {\r\n return new Promise((resolve, reject) => {\r\n const userRetry = () => resolve(retry());\r\n const userFail = () => reject(err);\r\n userOnError(err, userRetry, userFail, retries + 1);\r\n });\r\n }\r\n else {\r\n throw err;\r\n }\r\n })\r\n .then((comp) => {\r\n if (thisRequest !== pendingRequest && pendingRequest) {\r\n return pendingRequest;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && !comp) {\r\n warn(`Async component loader resolved to undefined. ` +\r\n `If you are using retry(), make sure to return its return value.`);\r\n }\r\n // interop module default\r\n if (comp &&\r\n (comp.__esModule || comp[Symbol.toStringTag] === 'Module')) {\r\n comp = comp.default;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && comp && !isObject(comp) && !isFunction(comp)) {\r\n throw new Error(`Invalid async component load result: ${comp}`);\r\n }\r\n resolvedComp = comp;\r\n return comp;\r\n })));\r\n };\r\n return defineComponent({\r\n name: 'AsyncComponentWrapper',\r\n __asyncLoader: load,\r\n get __asyncResolved() {\r\n return resolvedComp;\r\n },\r\n setup() {\r\n const instance = currentInstance;\r\n // already resolved\r\n if (resolvedComp) {\r\n return () => createInnerComp(resolvedComp, instance);\r\n }\r\n const onError = (err) => {\r\n pendingRequest = null;\r\n handleError(err, instance, 13 /* ASYNC_COMPONENT_LOADER */, !errorComponent /* do not throw in dev if user provided error component */);\r\n };\r\n // suspense-controlled or SSR.\r\n if ((suspensible && instance.suspense) ||\r\n (isInSSRComponentSetup)) {\r\n return load()\r\n .then(comp => {\r\n return () => createInnerComp(comp, instance);\r\n })\r\n .catch(err => {\r\n onError(err);\r\n return () => errorComponent\r\n ? createVNode(errorComponent, {\r\n error: err\r\n })\r\n : null;\r\n });\r\n }\r\n const loaded = ref(false);\r\n const error = ref();\r\n const delayed = ref(!!delay);\r\n if (delay) {\r\n setTimeout(() => {\r\n delayed.value = false;\r\n }, delay);\r\n }\r\n if (timeout != null) {\r\n setTimeout(() => {\r\n if (!loaded.value && !error.value) {\r\n const err = new Error(`Async component timed out after ${timeout}ms.`);\r\n onError(err);\r\n error.value = err;\r\n }\r\n }, timeout);\r\n }\r\n load()\r\n .then(() => {\r\n loaded.value = true;\r\n if (instance.parent && isKeepAlive(instance.parent.vnode)) {\r\n // parent is keep-alive, force update so the loaded component's\r\n // name is taken into account\r\n queueJob(instance.parent.update);\r\n }\r\n })\r\n .catch(err => {\r\n onError(err);\r\n error.value = err;\r\n });\r\n return () => {\r\n if (loaded.value && resolvedComp) {\r\n return createInnerComp(resolvedComp, instance);\r\n }\r\n else if (error.value && errorComponent) {\r\n return createVNode(errorComponent, {\r\n error: error.value\r\n });\r\n }\r\n else if (loadingComponent && !delayed.value) {\r\n return createVNode(loadingComponent);\r\n }\r\n };\r\n }\r\n });\r\n}\r\nfunction createInnerComp(comp, { vnode: { ref, props, children } }) {\r\n const vnode = createVNode(comp, props, children);\r\n // ensure inner component inherits the async wrapper's ref owner\r\n vnode.ref = ref;\r\n return vnode;\r\n}\n\nconst isKeepAlive = (vnode) => vnode.type.__isKeepAlive;\r\nconst KeepAliveImpl = {\r\n name: `KeepAlive`,\r\n // Marker for special handling inside the renderer. We are not using a ===\r\n // check directly on KeepAlive in the renderer, because importing it directly\r\n // would prevent it from being tree-shaken.\r\n __isKeepAlive: true,\r\n props: {\r\n include: [String, RegExp, Array],\r\n exclude: [String, RegExp, Array],\r\n max: [String, Number]\r\n },\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n // KeepAlive communicates with the instantiated renderer via the\r\n // ctx where the renderer passes in its internals,\r\n // and the KeepAlive instance exposes activate/deactivate implementations.\r\n // The whole point of this is to avoid importing KeepAlive directly in the\r\n // renderer to facilitate tree-shaking.\r\n const sharedContext = instance.ctx;\r\n // if the internal renderer is not registered, it indicates that this is server-side rendering,\r\n // for KeepAlive, we just need to render its children\r\n if (!sharedContext.renderer) {\r\n return slots.default;\r\n }\r\n const cache = new Map();\r\n const keys = new Set();\r\n let current = null;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n instance.__v_cache = cache;\r\n }\r\n const parentSuspense = instance.suspense;\r\n const { renderer: { p: patch, m: move, um: _unmount, o: { createElement } } } = sharedContext;\r\n const storageContainer = createElement('div');\r\n sharedContext.activate = (vnode, container, anchor, isSVG, optimized) => {\r\n const instance = vnode.component;\r\n move(vnode, container, anchor, 0 /* ENTER */, parentSuspense);\r\n // in case props have changed\r\n patch(instance.vnode, vnode, container, anchor, instance, parentSuspense, isSVG, vnode.slotScopeIds, optimized);\r\n queuePostRenderEffect(() => {\r\n instance.isDeactivated = false;\r\n if (instance.a) {\r\n invokeArrayFns(instance.a);\r\n }\r\n const vnodeHook = vnode.props && vnode.props.onVnodeMounted;\r\n if (vnodeHook) {\r\n invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n }\r\n }, parentSuspense);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n // Update components tree\r\n devtoolsComponentAdded(instance);\r\n }\r\n };\r\n sharedContext.deactivate = (vnode) => {\r\n const instance = vnode.component;\r\n move(vnode, storageContainer, null, 1 /* LEAVE */, parentSuspense);\r\n queuePostRenderEffect(() => {\r\n if (instance.da) {\r\n invokeArrayFns(instance.da);\r\n }\r\n const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;\r\n if (vnodeHook) {\r\n invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n }\r\n instance.isDeactivated = true;\r\n }, parentSuspense);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n // Update components tree\r\n devtoolsComponentAdded(instance);\r\n }\r\n };\r\n function unmount(vnode) {\r\n // reset the shapeFlag so it can be properly unmounted\r\n resetShapeFlag(vnode);\r\n _unmount(vnode, instance, parentSuspense);\r\n }\r\n function pruneCache(filter) {\r\n cache.forEach((vnode, key) => {\r\n const name = getComponentName(vnode.type);\r\n if (name && (!filter || !filter(name))) {\r\n pruneCacheEntry(key);\r\n }\r\n });\r\n }\r\n function pruneCacheEntry(key) {\r\n const cached = cache.get(key);\r\n if (!current || cached.type !== current.type) {\r\n unmount(cached);\r\n }\r\n else if (current) {\r\n // current active instance should no longer be kept-alive.\r\n // we can't unmount it now but it might be later, so reset its flag now.\r\n resetShapeFlag(current);\r\n }\r\n cache.delete(key);\r\n keys.delete(key);\r\n }\r\n // prune cache on include/exclude prop change\r\n watch(() => [props.include, props.exclude], ([include, exclude]) => {\r\n include && pruneCache(name => matches(include, name));\r\n exclude && pruneCache(name => !matches(exclude, name));\r\n }, \r\n // prune post-render after `current` has been updated\r\n { flush: 'post', deep: true });\r\n // cache sub tree after render\r\n let pendingCacheKey = null;\r\n const cacheSubtree = () => {\r\n // fix #1621, the pendingCacheKey could be 0\r\n if (pendingCacheKey != null) {\r\n cache.set(pendingCacheKey, getInnerChild(instance.subTree));\r\n }\r\n };\r\n onMounted(cacheSubtree);\r\n onUpdated(cacheSubtree);\r\n onBeforeUnmount(() => {\r\n cache.forEach(cached => {\r\n const { subTree, suspense } = instance;\r\n const vnode = getInnerChild(subTree);\r\n if (cached.type === vnode.type) {\r\n // current instance will be unmounted as part of keep-alive's unmount\r\n resetShapeFlag(vnode);\r\n // but invoke its deactivated hook here\r\n const da = vnode.component.da;\r\n da && queuePostRenderEffect(da, suspense);\r\n return;\r\n }\r\n unmount(cached);\r\n });\r\n });\r\n return () => {\r\n pendingCacheKey = null;\r\n if (!slots.default) {\r\n return null;\r\n }\r\n const children = slots.default();\r\n const rawVNode = children[0];\r\n if (children.length > 1) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`KeepAlive should contain exactly one component child.`);\r\n }\r\n current = null;\r\n return children;\r\n }\r\n else if (!isVNode(rawVNode) ||\r\n (!(rawVNode.shapeFlag & 4 /* STATEFUL_COMPONENT */) &&\r\n !(rawVNode.shapeFlag & 128 /* SUSPENSE */))) {\r\n current = null;\r\n return rawVNode;\r\n }\r\n let vnode = getInnerChild(rawVNode);\r\n const comp = vnode.type;\r\n // for async components, name check should be based in its loaded\r\n // inner component if available\r\n const name = getComponentName(isAsyncWrapper(vnode)\r\n ? vnode.type.__asyncResolved || {}\r\n : comp);\r\n const { include, exclude, max } = props;\r\n if ((include && (!name || !matches(include, name))) ||\r\n (exclude && name && matches(exclude, name))) {\r\n current = vnode;\r\n return rawVNode;\r\n }\r\n const key = vnode.key == null ? comp : vnode.key;\r\n const cachedVNode = cache.get(key);\r\n // clone vnode if it's reused because we are going to mutate it\r\n if (vnode.el) {\r\n vnode = cloneVNode(vnode);\r\n if (rawVNode.shapeFlag & 128 /* SUSPENSE */) {\r\n rawVNode.ssContent = vnode;\r\n }\r\n }\r\n // #1513 it's possible for the returned vnode to be cloned due to attr\r\n // fallthrough or scopeId, so the vnode here may not be the final vnode\r\n // that is mounted. Instead of caching it directly, we store the pending\r\n // key and cache `instance.subTree` (the normalized vnode) in\r\n // beforeMount/beforeUpdate hooks.\r\n pendingCacheKey = key;\r\n if (cachedVNode) {\r\n // copy over mounted state\r\n vnode.el = cachedVNode.el;\r\n vnode.component = cachedVNode.component;\r\n if (vnode.transition) {\r\n // recursively update transition hooks on subTree\r\n setTransitionHooks(vnode, vnode.transition);\r\n }\r\n // avoid vnode being mounted as fresh\r\n vnode.shapeFlag |= 512 /* COMPONENT_KEPT_ALIVE */;\r\n // make this key the freshest\r\n keys.delete(key);\r\n keys.add(key);\r\n }\r\n else {\r\n keys.add(key);\r\n // prune oldest entry\r\n if (max && keys.size > parseInt(max, 10)) {\r\n pruneCacheEntry(keys.values().next().value);\r\n }\r\n }\r\n // avoid vnode being unmounted\r\n vnode.shapeFlag |= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n current = vnode;\r\n return rawVNode;\r\n };\r\n }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst KeepAlive = KeepAliveImpl;\r\nfunction matches(pattern, name) {\r\n if (isArray(pattern)) {\r\n return pattern.some((p) => matches(p, name));\r\n }\r\n else if (isString(pattern)) {\r\n return pattern.split(',').indexOf(name) > -1;\r\n }\r\n else if (pattern.test) {\r\n return pattern.test(name);\r\n }\r\n /* istanbul ignore next */\r\n return false;\r\n}\r\nfunction onActivated(hook, target) {\r\n registerKeepAliveHook(hook, \"a\" /* ACTIVATED */, target);\r\n}\r\nfunction onDeactivated(hook, target) {\r\n registerKeepAliveHook(hook, \"da\" /* DEACTIVATED */, target);\r\n}\r\nfunction registerKeepAliveHook(hook, type, target = currentInstance) {\r\n // cache the deactivate branch check wrapper for injected hooks so the same\r\n // hook can be properly deduped by the scheduler. \"__wdc\" stands for \"with\r\n // deactivation check\".\r\n const wrappedHook = hook.__wdc ||\r\n (hook.__wdc = () => {\r\n // only fire the hook if the target instance is NOT in a deactivated branch.\r\n let current = target;\r\n while (current) {\r\n if (current.isDeactivated) {\r\n return;\r\n }\r\n current = current.parent;\r\n }\r\n return hook();\r\n });\r\n injectHook(type, wrappedHook, target);\r\n // In addition to registering it on the target instance, we walk up the parent\r\n // chain and register it on all ancestor instances that are keep-alive roots.\r\n // This avoids the need to walk the entire component tree when invoking these\r\n // hooks, and more importantly, avoids the need to track child components in\r\n // arrays.\r\n if (target) {\r\n let current = target.parent;\r\n while (current && current.parent) {\r\n if (isKeepAlive(current.parent.vnode)) {\r\n injectToKeepAliveRoot(wrappedHook, type, target, current);\r\n }\r\n current = current.parent;\r\n }\r\n }\r\n}\r\nfunction injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {\r\n // injectHook wraps the original for error handling, so make sure to remove\r\n // the wrapped version.\r\n const injected = injectHook(type, hook, keepAliveRoot, true /* prepend */);\r\n onUnmounted(() => {\r\n remove(keepAliveRoot[type], injected);\r\n }, target);\r\n}\r\nfunction resetShapeFlag(vnode) {\r\n let shapeFlag = vnode.shapeFlag;\r\n if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n shapeFlag -= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n }\r\n if (shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n shapeFlag -= 512 /* COMPONENT_KEPT_ALIVE */;\r\n }\r\n vnode.shapeFlag = shapeFlag;\r\n}\r\nfunction getInnerChild(vnode) {\r\n return vnode.shapeFlag & 128 /* SUSPENSE */ ? vnode.ssContent : vnode;\r\n}\n\nfunction injectHook(type, hook, target = currentInstance, prepend = false) {\r\n if (target) {\r\n const hooks = target[type] || (target[type] = []);\r\n // cache the error handling wrapper for injected hooks so the same hook\r\n // can be properly deduped by the scheduler. \"__weh\" stands for \"with error\r\n // handling\".\r\n const wrappedHook = hook.__weh ||\r\n (hook.__weh = (...args) => {\r\n if (target.isUnmounted) {\r\n return;\r\n }\r\n // disable tracking inside all lifecycle hooks\r\n // since they can potentially be called inside effects.\r\n pauseTracking();\r\n // Set currentInstance during hook invocation.\r\n // This assumes the hook does not synchronously trigger other hooks, which\r\n // can only be false when the user does something really funky.\r\n setCurrentInstance(target);\r\n const res = callWithAsyncErrorHandling(hook, target, type, args);\r\n unsetCurrentInstance();\r\n resetTracking();\r\n return res;\r\n });\r\n if (prepend) {\r\n hooks.unshift(wrappedHook);\r\n }\r\n else {\r\n hooks.push(wrappedHook);\r\n }\r\n return wrappedHook;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n const apiName = toHandlerKey(ErrorTypeStrings[type].replace(/ hook$/, ''));\r\n warn(`${apiName} is called when there is no active component instance to be ` +\r\n `associated with. ` +\r\n `Lifecycle injection APIs can only be used during execution of setup().` +\r\n (` If you are using async setup(), make sure to register lifecycle ` +\r\n `hooks before the first await statement.`\r\n ));\r\n }\r\n}\r\nconst createHook = (lifecycle) => (hook, target = currentInstance) => \r\n// post-create lifecycle registrations are noops during SSR (except for serverPrefetch)\r\n(!isInSSRComponentSetup || lifecycle === \"sp\" /* SERVER_PREFETCH */) &&\r\n injectHook(lifecycle, hook, target);\r\nconst onBeforeMount = createHook(\"bm\" /* BEFORE_MOUNT */);\r\nconst onMounted = createHook(\"m\" /* MOUNTED */);\r\nconst onBeforeUpdate = createHook(\"bu\" /* BEFORE_UPDATE */);\r\nconst onUpdated = createHook(\"u\" /* UPDATED */);\r\nconst onBeforeUnmount = createHook(\"bum\" /* BEFORE_UNMOUNT */);\r\nconst onUnmounted = createHook(\"um\" /* UNMOUNTED */);\r\nconst onServerPrefetch = createHook(\"sp\" /* SERVER_PREFETCH */);\r\nconst onRenderTriggered = createHook(\"rtg\" /* RENDER_TRIGGERED */);\r\nconst onRenderTracked = createHook(\"rtc\" /* RENDER_TRACKED */);\r\nfunction onErrorCaptured(hook, target = currentInstance) {\r\n injectHook(\"ec\" /* ERROR_CAPTURED */, hook, target);\r\n}\n\nfunction createDuplicateChecker() {\r\n const cache = Object.create(null);\r\n return (type, key) => {\r\n if (cache[key]) {\r\n warn(`${type} property \"${key}\" is already defined in ${cache[key]}.`);\r\n }\r\n else {\r\n cache[key] = type;\r\n }\r\n };\r\n}\r\nlet shouldCacheAccess = true;\r\nfunction applyOptions(instance) {\r\n const options = resolveMergedOptions(instance);\r\n const publicThis = instance.proxy;\r\n const ctx = instance.ctx;\r\n // do not cache property access on public proxy during state initialization\r\n shouldCacheAccess = false;\r\n // call beforeCreate first before accessing other options since\r\n // the hook may mutate resolved options (#2791)\r\n if (options.beforeCreate) {\r\n callHook(options.beforeCreate, instance, \"bc\" /* BEFORE_CREATE */);\r\n }\r\n const { \r\n // state\r\n data: dataOptions, computed: computedOptions, methods, watch: watchOptions, provide: provideOptions, inject: injectOptions, \r\n // lifecycle\r\n created, beforeMount, mounted, beforeUpdate, updated, activated, deactivated, beforeDestroy, beforeUnmount, destroyed, unmounted, render, renderTracked, renderTriggered, errorCaptured, serverPrefetch, \r\n // public API\r\n expose, inheritAttrs, \r\n // assets\r\n components, directives, filters } = options;\r\n const checkDuplicateProperties = (process.env.NODE_ENV !== 'production') ? createDuplicateChecker() : null;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const [propsOptions] = instance.propsOptions;\r\n if (propsOptions) {\r\n for (const key in propsOptions) {\r\n checkDuplicateProperties(\"Props\" /* PROPS */, key);\r\n }\r\n }\r\n }\r\n // options initialization order (to be consistent with Vue 2):\r\n // - props (already done outside of this function)\r\n // - inject\r\n // - methods\r\n // - data (deferred since it relies on `this` access)\r\n // - computed\r\n // - watch (deferred since it relies on `this` access)\r\n if (injectOptions) {\r\n resolveInjections(injectOptions, ctx, checkDuplicateProperties, instance.appContext.config.unwrapInjectedRef);\r\n }\r\n if (methods) {\r\n for (const key in methods) {\r\n const methodHandler = methods[key];\r\n if (isFunction(methodHandler)) {\r\n // In dev mode, we use the `createRenderContext` function to define\r\n // methods to the proxy target, and those are read-only but\r\n // reconfigurable, so it needs to be redefined here\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n Object.defineProperty(ctx, key, {\r\n value: methodHandler.bind(publicThis),\r\n configurable: true,\r\n enumerable: true,\r\n writable: true\r\n });\r\n }\r\n else {\r\n ctx[key] = methodHandler.bind(publicThis);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Methods\" /* METHODS */, key);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Method \"${key}\" has type \"${typeof methodHandler}\" in the component definition. ` +\r\n `Did you reference the function correctly?`);\r\n }\r\n }\r\n }\r\n if (dataOptions) {\r\n if ((process.env.NODE_ENV !== 'production') && !isFunction(dataOptions)) {\r\n warn(`The data option must be a function. ` +\r\n `Plain object usage is no longer supported.`);\r\n }\r\n const data = dataOptions.call(publicThis, publicThis);\r\n if ((process.env.NODE_ENV !== 'production') && isPromise(data)) {\r\n warn(`data() returned a Promise - note data() cannot be async; If you ` +\r\n `intend to perform data fetching before component renders, use ` +\r\n `async setup() + <Suspense>.`);\r\n }\r\n if (!isObject(data)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`data() should return an object.`);\r\n }\r\n else {\r\n instance.data = reactive(data);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n for (const key in data) {\r\n checkDuplicateProperties(\"Data\" /* DATA */, key);\r\n // expose data on ctx during dev\r\n if (key[0] !== '$' && key[0] !== '_') {\r\n Object.defineProperty(ctx, key, {\r\n configurable: true,\r\n enumerable: true,\r\n get: () => data[key],\r\n set: NOOP\r\n });\r\n }\r\n }\r\n }\r\n }\r\n }\r\n // state initialization complete at this point - start caching access\r\n shouldCacheAccess = true;\r\n if (computedOptions) {\r\n for (const key in computedOptions) {\r\n const opt = computedOptions[key];\r\n const get = isFunction(opt)\r\n ? opt.bind(publicThis, publicThis)\r\n : isFunction(opt.get)\r\n ? opt.get.bind(publicThis, publicThis)\r\n : NOOP;\r\n if ((process.env.NODE_ENV !== 'production') && get === NOOP) {\r\n warn(`Computed property \"${key}\" has no getter.`);\r\n }\r\n const set = !isFunction(opt) && isFunction(opt.set)\r\n ? opt.set.bind(publicThis)\r\n : (process.env.NODE_ENV !== 'production')\r\n ? () => {\r\n warn(`Write operation failed: computed property \"${key}\" is readonly.`);\r\n }\r\n : NOOP;\r\n const c = computed({\r\n get,\r\n set\r\n });\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => c.value,\r\n set: v => (c.value = v)\r\n });\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Computed\" /* COMPUTED */, key);\r\n }\r\n }\r\n }\r\n if (watchOptions) {\r\n for (const key in watchOptions) {\r\n createWatcher(watchOptions[key], ctx, publicThis, key);\r\n }\r\n }\r\n if (provideOptions) {\r\n const provides = isFunction(provideOptions)\r\n ? provideOptions.call(publicThis)\r\n : provideOptions;\r\n Reflect.ownKeys(provides).forEach(key => {\r\n provide(key, provides[key]);\r\n });\r\n }\r\n if (created) {\r\n callHook(created, instance, \"c\" /* CREATED */);\r\n }\r\n function registerLifecycleHook(register, hook) {\r\n if (isArray(hook)) {\r\n hook.forEach(_hook => register(_hook.bind(publicThis)));\r\n }\r\n else if (hook) {\r\n register(hook.bind(publicThis));\r\n }\r\n }\r\n registerLifecycleHook(onBeforeMount, beforeMount);\r\n registerLifecycleHook(onMounted, mounted);\r\n registerLifecycleHook(onBeforeUpdate, beforeUpdate);\r\n registerLifecycleHook(onUpdated, updated);\r\n registerLifecycleHook(onActivated, activated);\r\n registerLifecycleHook(onDeactivated, deactivated);\r\n registerLifecycleHook(onErrorCaptured, errorCaptured);\r\n registerLifecycleHook(onRenderTracked, renderTracked);\r\n registerLifecycleHook(onRenderTriggered, renderTriggered);\r\n registerLifecycleHook(onBeforeUnmount, beforeUnmount);\r\n registerLifecycleHook(onUnmounted, unmounted);\r\n registerLifecycleHook(onServerPrefetch, serverPrefetch);\r\n if (isArray(expose)) {\r\n if (expose.length) {\r\n const exposed = instance.exposed || (instance.exposed = {});\r\n expose.forEach(key => {\r\n Object.defineProperty(exposed, key, {\r\n get: () => publicThis[key],\r\n set: val => (publicThis[key] = val)\r\n });\r\n });\r\n }\r\n else if (!instance.exposed) {\r\n instance.exposed = {};\r\n }\r\n }\r\n // options that are handled when creating the instance but also need to be\r\n // applied from mixins\r\n if (render && instance.render === NOOP) {\r\n instance.render = render;\r\n }\r\n if (inheritAttrs != null) {\r\n instance.inheritAttrs = inheritAttrs;\r\n }\r\n // asset options.\r\n if (components)\r\n instance.components = components;\r\n if (directives)\r\n instance.directives = directives;\r\n}\r\nfunction resolveInjections(injectOptions, ctx, checkDuplicateProperties = NOOP, unwrapRef = false) {\r\n if (isArray(injectOptions)) {\r\n injectOptions = normalizeInject(injectOptions);\r\n }\r\n for (const key in injectOptions) {\r\n const opt = injectOptions[key];\r\n let injected;\r\n if (isObject(opt)) {\r\n if ('default' in opt) {\r\n injected = inject(opt.from || key, opt.default, true /* treat default function as factory */);\r\n }\r\n else {\r\n injected = inject(opt.from || key);\r\n }\r\n }\r\n else {\r\n injected = inject(opt);\r\n }\r\n if (isRef(injected)) {\r\n // TODO remove the check in 3.3\r\n if (unwrapRef) {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => injected.value,\r\n set: v => (injected.value = v)\r\n });\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`injected property \"${key}\" is a ref and will be auto-unwrapped ` +\r\n `and no longer needs \\`.value\\` in the next minor release. ` +\r\n `To opt-in to the new behavior now, ` +\r\n `set \\`app.config.unwrapInjectedRef = true\\` (this config is ` +\r\n `temporary and will not be needed in the future.)`);\r\n }\r\n ctx[key] = injected;\r\n }\r\n }\r\n else {\r\n ctx[key] = injected;\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Inject\" /* INJECT */, key);\r\n }\r\n }\r\n}\r\nfunction callHook(hook, instance, type) {\r\n callWithAsyncErrorHandling(isArray(hook)\r\n ? hook.map(h => h.bind(instance.proxy))\r\n : hook.bind(instance.proxy), instance, type);\r\n}\r\nfunction createWatcher(raw, ctx, publicThis, key) {\r\n const getter = key.includes('.')\r\n ? createPathGetter(publicThis, key)\r\n : () => publicThis[key];\r\n if (isString(raw)) {\r\n const handler = ctx[raw];\r\n if (isFunction(handler)) {\r\n watch(getter, handler);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch handler specified by key \"${raw}\"`, handler);\r\n }\r\n }\r\n else if (isFunction(raw)) {\r\n watch(getter, raw.bind(publicThis));\r\n }\r\n else if (isObject(raw)) {\r\n if (isArray(raw)) {\r\n raw.forEach(r => createWatcher(r, ctx, publicThis, key));\r\n }\r\n else {\r\n const handler = isFunction(raw.handler)\r\n ? raw.handler.bind(publicThis)\r\n : ctx[raw.handler];\r\n if (isFunction(handler)) {\r\n watch(getter, handler, raw);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch handler specified by key \"${raw.handler}\"`, handler);\r\n }\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch option: \"${key}\"`, raw);\r\n }\r\n}\r\n/**\r\n * Resolve merged options and cache it on the component.\r\n * This is done only once per-component since the merging does not involve\r\n * instances.\r\n */\r\nfunction resolveMergedOptions(instance) {\r\n const base = instance.type;\r\n const { mixins, extends: extendsOptions } = base;\r\n const { mixins: globalMixins, optionsCache: cache, config: { optionMergeStrategies } } = instance.appContext;\r\n const cached = cache.get(base);\r\n let resolved;\r\n if (cached) {\r\n resolved = cached;\r\n }\r\n else if (!globalMixins.length && !mixins && !extendsOptions) {\r\n {\r\n resolved = base;\r\n }\r\n }\r\n else {\r\n resolved = {};\r\n if (globalMixins.length) {\r\n globalMixins.forEach(m => mergeOptions(resolved, m, optionMergeStrategies, true));\r\n }\r\n mergeOptions(resolved, base, optionMergeStrategies);\r\n }\r\n cache.set(base, resolved);\r\n return resolved;\r\n}\r\nfunction mergeOptions(to, from, strats, asMixin = false) {\r\n const { mixins, extends: extendsOptions } = from;\r\n if (extendsOptions) {\r\n mergeOptions(to, extendsOptions, strats, true);\r\n }\r\n if (mixins) {\r\n mixins.forEach((m) => mergeOptions(to, m, strats, true));\r\n }\r\n for (const key in from) {\r\n if (asMixin && key === 'expose') {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`\"expose\" option is ignored when declared in mixins or extends. ` +\r\n `It should only be declared in the base component itself.`);\r\n }\r\n else {\r\n const strat = internalOptionMergeStrats[key] || (strats && strats[key]);\r\n to[key] = strat ? strat(to[key], from[key]) : from[key];\r\n }\r\n }\r\n return to;\r\n}\r\nconst internalOptionMergeStrats = {\r\n data: mergeDataFn,\r\n props: mergeObjectOptions,\r\n emits: mergeObjectOptions,\r\n // objects\r\n methods: mergeObjectOptions,\r\n computed: mergeObjectOptions,\r\n // lifecycle\r\n beforeCreate: mergeAsArray,\r\n created: mergeAsArray,\r\n beforeMount: mergeAsArray,\r\n mounted: mergeAsArray,\r\n beforeUpdate: mergeAsArray,\r\n updated: mergeAsArray,\r\n beforeDestroy: mergeAsArray,\r\n beforeUnmount: mergeAsArray,\r\n destroyed: mergeAsArray,\r\n unmounted: mergeAsArray,\r\n activated: mergeAsArray,\r\n deactivated: mergeAsArray,\r\n errorCaptured: mergeAsArray,\r\n serverPrefetch: mergeAsArray,\r\n // assets\r\n components: mergeObjectOptions,\r\n directives: mergeObjectOptions,\r\n // watch\r\n watch: mergeWatchOptions,\r\n // provide / inject\r\n provide: mergeDataFn,\r\n inject: mergeInject\r\n};\r\nfunction mergeDataFn(to, from) {\r\n if (!from) {\r\n return to;\r\n }\r\n if (!to) {\r\n return from;\r\n }\r\n return function mergedDataFn() {\r\n return (extend)(isFunction(to) ? to.call(this, this) : to, isFunction(from) ? from.call(this, this) : from);\r\n };\r\n}\r\nfunction mergeInject(to, from) {\r\n return mergeObjectOptions(normalizeInject(to), normalizeInject(from));\r\n}\r\nfunction normalizeInject(raw) {\r\n if (isArray(raw)) {\r\n const res = {};\r\n for (let i = 0; i < raw.length; i++) {\r\n res[raw[i]] = raw[i];\r\n }\r\n return res;\r\n }\r\n return raw;\r\n}\r\nfunction mergeAsArray(to, from) {\r\n return to ? [...new Set([].concat(to, from))] : from;\r\n}\r\nfunction mergeObjectOptions(to, from) {\r\n return to ? extend(extend(Object.create(null), to), from) : from;\r\n}\r\nfunction mergeWatchOptions(to, from) {\r\n if (!to)\r\n return from;\r\n if (!from)\r\n return to;\r\n const merged = extend(Object.create(null), to);\r\n for (const key in from) {\r\n merged[key] = mergeAsArray(to[key], from[key]);\r\n }\r\n return merged;\r\n}\n\nfunction initProps(instance, rawProps, isStateful, // result of bitwise flag comparison\r\nisSSR = false) {\r\n const props = {};\r\n const attrs = {};\r\n def(attrs, InternalObjectKey, 1);\r\n instance.propsDefaults = Object.create(null);\r\n setFullProps(instance, rawProps, props, attrs);\r\n // ensure all declared prop keys are present\r\n for (const key in instance.propsOptions[0]) {\r\n if (!(key in props)) {\r\n props[key] = undefined;\r\n }\r\n }\r\n // validation\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateProps(rawProps || {}, props, instance);\r\n }\r\n if (isStateful) {\r\n // stateful\r\n instance.props = isSSR ? props : shallowReactive(props);\r\n }\r\n else {\r\n if (!instance.type.props) {\r\n // functional w/ optional props, props === attrs\r\n instance.props = attrs;\r\n }\r\n else {\r\n // functional w/ declared props\r\n instance.props = props;\r\n }\r\n }\r\n instance.attrs = attrs;\r\n}\r\nfunction updateProps(instance, rawProps, rawPrevProps, optimized) {\r\n const { props, attrs, vnode: { patchFlag } } = instance;\r\n const rawCurrentProps = toRaw(props);\r\n const [options] = instance.propsOptions;\r\n let hasAttrsChanged = false;\r\n if (\r\n // always force full diff in dev\r\n // - #1942 if hmr is enabled with sfc component\r\n // - vite#872 non-sfc component used by sfc component\r\n !((process.env.NODE_ENV !== 'production') &&\r\n (instance.type.__hmrId ||\r\n (instance.parent && instance.parent.type.__hmrId))) &&\r\n (optimized || patchFlag > 0) &&\r\n !(patchFlag & 16 /* FULL_PROPS */)) {\r\n if (patchFlag & 8 /* PROPS */) {\r\n // Compiler-generated props & no keys change, just set the updated\r\n // the props.\r\n const propsToUpdate = instance.vnode.dynamicProps;\r\n for (let i = 0; i < propsToUpdate.length; i++) {\r\n let key = propsToUpdate[i];\r\n // PROPS flag guarantees rawProps to be non-null\r\n const value = rawProps[key];\r\n if (options) {\r\n // attr / props separation was done on init and will be consistent\r\n // in this code path, so just check if attrs have it.\r\n if (hasOwn(attrs, key)) {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n else {\r\n const camelizedKey = camelize(key);\r\n props[camelizedKey] = resolvePropValue(options, rawCurrentProps, camelizedKey, value, instance, false /* isAbsent */);\r\n }\r\n }\r\n else {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // full props update.\r\n if (setFullProps(instance, rawProps, props, attrs)) {\r\n hasAttrsChanged = true;\r\n }\r\n // in case of dynamic props, check if we need to delete keys from\r\n // the props object\r\n let kebabKey;\r\n for (const key in rawCurrentProps) {\r\n if (!rawProps ||\r\n // for camelCase\r\n (!hasOwn(rawProps, key) &&\r\n // it's possible the original props was passed in as kebab-case\r\n // and converted to camelCase (#955)\r\n ((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey)))) {\r\n if (options) {\r\n if (rawPrevProps &&\r\n // for camelCase\r\n (rawPrevProps[key] !== undefined ||\r\n // for kebab-case\r\n rawPrevProps[kebabKey] !== undefined)) {\r\n props[key] = resolvePropValue(options, rawCurrentProps, key, undefined, instance, true /* isAbsent */);\r\n }\r\n }\r\n else {\r\n delete props[key];\r\n }\r\n }\r\n }\r\n // in the case of functional component w/o props declaration, props and\r\n // attrs point to the same object so it should already have been updated.\r\n if (attrs !== rawCurrentProps) {\r\n for (const key in attrs) {\r\n if (!rawProps || !hasOwn(rawProps, key)) {\r\n delete attrs[key];\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n // trigger updates for $attrs in case it's used in component slots\r\n if (hasAttrsChanged) {\r\n trigger(instance, \"set\" /* SET */, '$attrs');\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateProps(rawProps || {}, props, instance);\r\n }\r\n}\r\nfunction setFullProps(instance, rawProps, props, attrs) {\r\n const [options, needCastKeys] = instance.propsOptions;\r\n let hasAttrsChanged = false;\r\n let rawCastValues;\r\n if (rawProps) {\r\n for (let key in rawProps) {\r\n // key, ref are reserved and never passed down\r\n if (isReservedProp(key)) {\r\n continue;\r\n }\r\n const value = rawProps[key];\r\n // prop option names are camelized during normalization, so to support\r\n // kebab -> camel conversion here we need to camelize the key.\r\n let camelKey;\r\n if (options && hasOwn(options, (camelKey = camelize(key)))) {\r\n if (!needCastKeys || !needCastKeys.includes(camelKey)) {\r\n props[camelKey] = value;\r\n }\r\n else {\r\n (rawCastValues || (rawCastValues = {}))[camelKey] = value;\r\n }\r\n }\r\n else if (!isEmitListener(instance.emitsOptions, key)) {\r\n if (!(key in attrs) || value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n if (needCastKeys) {\r\n const rawCurrentProps = toRaw(props);\r\n const castValues = rawCastValues || EMPTY_OBJ;\r\n for (let i = 0; i < needCastKeys.length; i++) {\r\n const key = needCastKeys[i];\r\n props[key] = resolvePropValue(options, rawCurrentProps, key, castValues[key], instance, !hasOwn(castValues, key));\r\n }\r\n }\r\n return hasAttrsChanged;\r\n}\r\nfunction resolvePropValue(options, props, key, value, instance, isAbsent) {\r\n const opt = options[key];\r\n if (opt != null) {\r\n const hasDefault = hasOwn(opt, 'default');\r\n // default values\r\n if (hasDefault && value === undefined) {\r\n const defaultValue = opt.default;\r\n if (opt.type !== Function && isFunction(defaultValue)) {\r\n const { propsDefaults } = instance;\r\n if (key in propsDefaults) {\r\n value = propsDefaults[key];\r\n }\r\n else {\r\n setCurrentInstance(instance);\r\n value = propsDefaults[key] = defaultValue.call(null, props);\r\n unsetCurrentInstance();\r\n }\r\n }\r\n else {\r\n value = defaultValue;\r\n }\r\n }\r\n // boolean casting\r\n if (opt[0 /* shouldCast */]) {\r\n if (isAbsent && !hasDefault) {\r\n value = false;\r\n }\r\n else if (opt[1 /* shouldCastTrue */] &&\r\n (value === '' || value === hyphenate(key))) {\r\n value = true;\r\n }\r\n }\r\n }\r\n return value;\r\n}\r\nfunction normalizePropsOptions(comp, appContext, asMixin = false) {\r\n const cache = appContext.propsCache;\r\n const cached = cache.get(comp);\r\n if (cached) {\r\n return cached;\r\n }\r\n const raw = comp.props;\r\n const normalized = {};\r\n const needCastKeys = [];\r\n // apply mixin/extends props\r\n let hasExtends = false;\r\n if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n const extendProps = (raw) => {\r\n hasExtends = true;\r\n const [props, keys] = normalizePropsOptions(raw, appContext, true);\r\n extend(normalized, props);\r\n if (keys)\r\n needCastKeys.push(...keys);\r\n };\r\n if (!asMixin && appContext.mixins.length) {\r\n appContext.mixins.forEach(extendProps);\r\n }\r\n if (comp.extends) {\r\n extendProps(comp.extends);\r\n }\r\n if (comp.mixins) {\r\n comp.mixins.forEach(extendProps);\r\n }\r\n }\r\n if (!raw && !hasExtends) {\r\n cache.set(comp, EMPTY_ARR);\r\n return EMPTY_ARR;\r\n }\r\n if (isArray(raw)) {\r\n for (let i = 0; i < raw.length; i++) {\r\n if ((process.env.NODE_ENV !== 'production') && !isString(raw[i])) {\r\n warn(`props must be strings when using array syntax.`, raw[i]);\r\n }\r\n const normalizedKey = camelize(raw[i]);\r\n if (validatePropName(normalizedKey)) {\r\n normalized[normalizedKey] = EMPTY_OBJ;\r\n }\r\n }\r\n }\r\n else if (raw) {\r\n if ((process.env.NODE_ENV !== 'production') && !isObject(raw)) {\r\n warn(`invalid props options`, raw);\r\n }\r\n for (const key in raw) {\r\n const normalizedKey = camelize(key);\r\n if (validatePropName(normalizedKey)) {\r\n const opt = raw[key];\r\n const prop = (normalized[normalizedKey] =\r\n isArray(opt) || isFunction(opt) ? { type: opt } : opt);\r\n if (prop) {\r\n const booleanIndex = getTypeIndex(Boolean, prop.type);\r\n const stringIndex = getTypeIndex(String, prop.type);\r\n prop[0 /* shouldCast */] = booleanIndex > -1;\r\n prop[1 /* shouldCastTrue */] =\r\n stringIndex < 0 || booleanIndex < stringIndex;\r\n // if the prop needs boolean casting or default value\r\n if (booleanIndex > -1 || hasOwn(prop, 'default')) {\r\n needCastKeys.push(normalizedKey);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n const res = [normalized, needCastKeys];\r\n cache.set(comp, res);\r\n return res;\r\n}\r\nfunction validatePropName(key) {\r\n if (key[0] !== '$') {\r\n return true;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid prop name: \"${key}\" is a reserved property.`);\r\n }\r\n return false;\r\n}\r\n// use function string name to check type constructors\r\n// so that it works across vms / iframes.\r\nfunction getType(ctor) {\r\n const match = ctor && ctor.toString().match(/^\\s*function (\\w+)/);\r\n return match ? match[1] : ctor === null ? 'null' : '';\r\n}\r\nfunction isSameType(a, b) {\r\n return getType(a) === getType(b);\r\n}\r\nfunction getTypeIndex(type, expectedTypes) {\r\n if (isArray(expectedTypes)) {\r\n return expectedTypes.findIndex(t => isSameType(t, type));\r\n }\r\n else if (isFunction(expectedTypes)) {\r\n return isSameType(expectedTypes, type) ? 0 : -1;\r\n }\r\n return -1;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProps(rawProps, props, instance) {\r\n const resolvedValues = toRaw(props);\r\n const options = instance.propsOptions[0];\r\n for (const key in options) {\r\n let opt = options[key];\r\n if (opt == null)\r\n continue;\r\n validateProp(key, resolvedValues[key], opt, !hasOwn(rawProps, key) && !hasOwn(rawProps, hyphenate(key)));\r\n }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProp(name, value, prop, isAbsent) {\r\n const { type, required, validator } = prop;\r\n // required!\r\n if (required && isAbsent) {\r\n warn('Missing required prop: \"' + name + '\"');\r\n return;\r\n }\r\n // missing but optional\r\n if (value == null && !prop.required) {\r\n return;\r\n }\r\n // type check\r\n if (type != null && type !== true) {\r\n let isValid = false;\r\n const types = isArray(type) ? type : [type];\r\n const expectedTypes = [];\r\n // value is valid as long as one of the specified types match\r\n for (let i = 0; i < types.length && !isValid; i++) {\r\n const { valid, expectedType } = assertType(value, types[i]);\r\n expectedTypes.push(expectedType || '');\r\n isValid = valid;\r\n }\r\n if (!isValid) {\r\n warn(getInvalidTypeMessage(name, value, expectedTypes));\r\n return;\r\n }\r\n }\r\n // custom validator\r\n if (validator && !validator(value)) {\r\n warn('Invalid prop: custom validator check failed for prop \"' + name + '\".');\r\n }\r\n}\r\nconst isSimpleType = /*#__PURE__*/ makeMap('String,Number,Boolean,Function,Symbol,BigInt');\r\n/**\r\n * dev only\r\n */\r\nfunction assertType(value, type) {\r\n let valid;\r\n const expectedType = getType(type);\r\n if (isSimpleType(expectedType)) {\r\n const t = typeof value;\r\n valid = t === expectedType.toLowerCase();\r\n // for primitive wrapper objects\r\n if (!valid && t === 'object') {\r\n valid = value instanceof type;\r\n }\r\n }\r\n else if (expectedType === 'Object') {\r\n valid = isObject(value);\r\n }\r\n else if (expectedType === 'Array') {\r\n valid = isArray(value);\r\n }\r\n else if (expectedType === 'null') {\r\n valid = value === null;\r\n }\r\n else {\r\n valid = value instanceof type;\r\n }\r\n return {\r\n valid,\r\n expectedType\r\n };\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction getInvalidTypeMessage(name, value, expectedTypes) {\r\n let message = `Invalid prop: type check failed for prop \"${name}\".` +\r\n ` Expected ${expectedTypes.map(capitalize).join(' | ')}`;\r\n const expectedType = expectedTypes[0];\r\n const receivedType = toRawType(value);\r\n const expectedValue = styleValue(value, expectedType);\r\n const receivedValue = styleValue(value, receivedType);\r\n // check if we need to specify expected value\r\n if (expectedTypes.length === 1 &&\r\n isExplicable(expectedType) &&\r\n !isBoolean(expectedType, receivedType)) {\r\n message += ` with value ${expectedValue}`;\r\n }\r\n message += `, got ${receivedType} `;\r\n // check if we need to specify received value\r\n if (isExplicable(receivedType)) {\r\n message += `with value ${receivedValue}.`;\r\n }\r\n return message;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction styleValue(value, type) {\r\n if (type === 'String') {\r\n return `\"${value}\"`;\r\n }\r\n else if (type === 'Number') {\r\n return `${Number(value)}`;\r\n }\r\n else {\r\n return `${value}`;\r\n }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isExplicable(type) {\r\n const explicitTypes = ['string', 'number', 'boolean'];\r\n return explicitTypes.some(elem => type.toLowerCase() === elem);\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isBoolean(...args) {\r\n return args.some(elem => elem.toLowerCase() === 'boolean');\r\n}\n\nconst isInternalKey = (key) => key[0] === '_' || key === '$stable';\r\nconst normalizeSlotValue = (value) => isArray(value)\r\n ? value.map(normalizeVNode)\r\n : [normalizeVNode(value)];\r\nconst normalizeSlot = (key, rawSlot, ctx) => {\r\n const normalized = withCtx((...args) => {\r\n if ((process.env.NODE_ENV !== 'production') && currentInstance) {\r\n warn(`Slot \"${key}\" invoked outside of the render function: ` +\r\n `this will not track dependencies used in the slot. ` +\r\n `Invoke the slot function inside the render function instead.`);\r\n }\r\n return normalizeSlotValue(rawSlot(...args));\r\n }, ctx);\r\n normalized._c = false;\r\n return normalized;\r\n};\r\nconst normalizeObjectSlots = (rawSlots, slots, instance) => {\r\n const ctx = rawSlots._ctx;\r\n for (const key in rawSlots) {\r\n if (isInternalKey(key))\r\n continue;\r\n const value = rawSlots[key];\r\n if (isFunction(value)) {\r\n slots[key] = normalizeSlot(key, value, ctx);\r\n }\r\n else if (value != null) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !(false )) {\r\n warn(`Non-function value encountered for slot \"${key}\". ` +\r\n `Prefer function slots for better performance.`);\r\n }\r\n const normalized = normalizeSlotValue(value);\r\n slots[key] = () => normalized;\r\n }\r\n }\r\n};\r\nconst normalizeVNodeSlots = (instance, children) => {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !isKeepAlive(instance.vnode) &&\r\n !(false )) {\r\n warn(`Non-function value encountered for default slot. ` +\r\n `Prefer function slots for better performance.`);\r\n }\r\n const normalized = normalizeSlotValue(children);\r\n instance.slots.default = () => normalized;\r\n};\r\nconst initSlots = (instance, children) => {\r\n if (instance.vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n const type = children._;\r\n if (type) {\r\n // users can get the shallow readonly version of the slots object through `this.$slots`,\r\n // we should avoid the proxy object polluting the slots of the internal instance\r\n instance.slots = toRaw(children);\r\n // make compiler marker non-enumerable\r\n def(children, '_', type);\r\n }\r\n else {\r\n normalizeObjectSlots(children, (instance.slots = {}));\r\n }\r\n }\r\n else {\r\n instance.slots = {};\r\n if (children) {\r\n normalizeVNodeSlots(instance, children);\r\n }\r\n }\r\n def(instance.slots, InternalObjectKey, 1);\r\n};\r\nconst updateSlots = (instance, children, optimized) => {\r\n const { vnode, slots } = instance;\r\n let needDeletionCheck = true;\r\n let deletionComparisonTarget = EMPTY_OBJ;\r\n if (vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n const type = children._;\r\n if (type) {\r\n // compiled slots.\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // Parent was HMR updated so slot content may have changed.\r\n // force update slots and mark instance for hmr as well\r\n extend(slots, children);\r\n }\r\n else if (optimized && type === 1 /* STABLE */) {\r\n // compiled AND stable.\r\n // no need to update, and skip stale slots removal.\r\n needDeletionCheck = false;\r\n }\r\n else {\r\n // compiled but dynamic (v-if/v-for on slots) - update slots, but skip\r\n // normalization.\r\n extend(slots, children);\r\n // #2893\r\n // when rendering the optimized slots by manually written render function,\r\n // we need to delete the `slots._` flag if necessary to make subsequent updates reliable,\r\n // i.e. let the `renderSlot` create the bailed Fragment\r\n if (!optimized && type === 1 /* STABLE */) {\r\n delete slots._;\r\n }\r\n }\r\n }\r\n else {\r\n needDeletionCheck = !children.$stable;\r\n normalizeObjectSlots(children, slots);\r\n }\r\n deletionComparisonTarget = children;\r\n }\r\n else if (children) {\r\n // non slot object children (direct value) passed to a component\r\n normalizeVNodeSlots(instance, children);\r\n deletionComparisonTarget = { default: 1 };\r\n }\r\n // delete stale slots\r\n if (needDeletionCheck) {\r\n for (const key in slots) {\r\n if (!isInternalKey(key) && !(key in deletionComparisonTarget)) {\r\n delete slots[key];\r\n }\r\n }\r\n }\r\n};\n\n/**\r\nRuntime helper for applying directives to a vnode. Example usage:\r\n\nconst comp = resolveComponent('comp')\r\nconst foo = resolveDirective('foo')\r\nconst bar = resolveDirective('bar')\r\n\nreturn withDirectives(h(comp), [\r\n [foo, this.x],\r\n [bar, this.y]\r\n])\r\n*/\r\nconst isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');\r\nfunction validateDirectiveName(name) {\r\n if (isBuiltInDirective(name)) {\r\n warn('Do not use built-in directive ids as custom directive id: ' + name);\r\n }\r\n}\r\n/**\r\n * Adds directives to a VNode.\r\n */\r\nfunction withDirectives(vnode, directives) {\r\n const internalInstance = currentRenderingInstance;\r\n if (internalInstance === null) {\r\n (process.env.NODE_ENV !== 'production') && warn(`withDirectives can only be used inside render functions.`);\r\n return vnode;\r\n }\r\n const instance = internalInstance.proxy;\r\n const bindings = vnode.dirs || (vnode.dirs = []);\r\n for (let i = 0; i < directives.length; i++) {\r\n let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];\r\n if (isFunction(dir)) {\r\n dir = {\r\n mounted: dir,\r\n updated: dir\r\n };\r\n }\r\n if (dir.deep) {\r\n traverse(value);\r\n }\r\n bindings.push({\r\n dir,\r\n instance,\r\n value,\r\n oldValue: void 0,\r\n arg,\r\n modifiers\r\n });\r\n }\r\n return vnode;\r\n}\r\nfunction invokeDirectiveHook(vnode, prevVNode, instance, name) {\r\n const bindings = vnode.dirs;\r\n const oldBindings = prevVNode && prevVNode.dirs;\r\n for (let i = 0; i < bindings.length; i++) {\r\n const binding = bindings[i];\r\n if (oldBindings) {\r\n binding.oldValue = oldBindings[i].value;\r\n }\r\n let hook = binding.dir[name];\r\n if (hook) {\r\n // disable tracking inside all lifecycle hooks\r\n // since they can potentially be called inside effects.\r\n pauseTracking();\r\n callWithAsyncErrorHandling(hook, instance, 8 /* DIRECTIVE_HOOK */, [\r\n vnode.el,\r\n binding,\r\n vnode,\r\n prevVNode\r\n ]);\r\n resetTracking();\r\n }\r\n }\r\n}\n\nfunction createAppContext() {\r\n return {\r\n app: null,\r\n config: {\r\n isNativeTag: NO,\r\n performance: false,\r\n globalProperties: {},\r\n optionMergeStrategies: {},\r\n errorHandler: undefined,\r\n warnHandler: undefined,\r\n compilerOptions: {}\r\n },\r\n mixins: [],\r\n components: {},\r\n directives: {},\r\n provides: Object.create(null),\r\n optionsCache: new WeakMap(),\r\n propsCache: new WeakMap(),\r\n emitsCache: new WeakMap()\r\n };\r\n}\r\nlet uid = 0;\r\nfunction createAppAPI(render, hydrate) {\r\n return function createApp(rootComponent, rootProps = null) {\r\n if (rootProps != null && !isObject(rootProps)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`root props passed to app.mount() must be an object.`);\r\n rootProps = null;\r\n }\r\n const context = createAppContext();\r\n const installedPlugins = new Set();\r\n let isMounted = false;\r\n const app = (context.app = {\r\n _uid: uid++,\r\n _component: rootComponent,\r\n _props: rootProps,\r\n _container: null,\r\n _context: context,\r\n _instance: null,\r\n version,\r\n get config() {\r\n return context.config;\r\n },\r\n set config(v) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`app.config cannot be replaced. Modify individual options instead.`);\r\n }\r\n },\r\n use(plugin, ...options) {\r\n if (installedPlugins.has(plugin)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Plugin has already been applied to target app.`);\r\n }\r\n else if (plugin && isFunction(plugin.install)) {\r\n installedPlugins.add(plugin);\r\n plugin.install(app, ...options);\r\n }\r\n else if (isFunction(plugin)) {\r\n installedPlugins.add(plugin);\r\n plugin(app, ...options);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`A plugin must either be a function or an object with an \"install\" ` +\r\n `function.`);\r\n }\r\n return app;\r\n },\r\n mixin(mixin) {\r\n if (__VUE_OPTIONS_API__) {\r\n if (!context.mixins.includes(mixin)) {\r\n context.mixins.push(mixin);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Mixin has already been applied to target app' +\r\n (mixin.name ? `: ${mixin.name}` : ''));\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Mixins are only available in builds supporting Options API');\r\n }\r\n return app;\r\n },\r\n component(name, component) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateComponentName(name, context.config);\r\n }\r\n if (!component) {\r\n return context.components[name];\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && context.components[name]) {\r\n warn(`Component \"${name}\" has already been registered in target app.`);\r\n }\r\n context.components[name] = component;\r\n return app;\r\n },\r\n directive(name, directive) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateDirectiveName(name);\r\n }\r\n if (!directive) {\r\n return context.directives[name];\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && context.directives[name]) {\r\n warn(`Directive \"${name}\" has already been registered in target app.`);\r\n }\r\n context.directives[name] = directive;\r\n return app;\r\n },\r\n mount(rootContainer, isHydrate, isSVG) {\r\n if (!isMounted) {\r\n const vnode = createVNode(rootComponent, rootProps);\r\n // store app context on the root VNode.\r\n // this will be set on the root instance on initial mount.\r\n vnode.appContext = context;\r\n // HMR root reload\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n context.reload = () => {\r\n render(cloneVNode(vnode), rootContainer, isSVG);\r\n };\r\n }\r\n if (isHydrate && hydrate) {\r\n hydrate(vnode, rootContainer);\r\n }\r\n else {\r\n render(vnode, rootContainer, isSVG);\r\n }\r\n isMounted = true;\r\n app._container = rootContainer;\r\n rootContainer.__vue_app__ = app;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n app._instance = vnode.component;\r\n devtoolsInitApp(app, version);\r\n }\r\n return getExposeProxy(vnode.component) || vnode.component.proxy;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`App has already been mounted.\\n` +\r\n `If you want to remount the same app, move your app creation logic ` +\r\n `into a factory function and create fresh app instances for each ` +\r\n `mount - e.g. \\`const createMyApp = () => createApp(App)\\``);\r\n }\r\n },\r\n unmount() {\r\n if (isMounted) {\r\n render(null, app._container);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n app._instance = null;\r\n devtoolsUnmountApp(app);\r\n }\r\n delete app._container.__vue_app__;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Cannot unmount an app that is not mounted.`);\r\n }\r\n },\r\n provide(key, value) {\r\n if ((process.env.NODE_ENV !== 'production') && key in context.provides) {\r\n warn(`App already provides property with key \"${String(key)}\". ` +\r\n `It will be overwritten with the new value.`);\r\n }\r\n // TypeScript doesn't allow symbols as index type\r\n // https://github.com/Microsoft/TypeScript/issues/24587\r\n context.provides[key] = value;\r\n return app;\r\n }\r\n });\r\n return app;\r\n };\r\n}\n\n/**\r\n * Function for handling a template ref\r\n */\r\nfunction setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {\r\n if (isArray(rawRef)) {\r\n rawRef.forEach((r, i) => setRef(r, oldRawRef && (isArray(oldRawRef) ? oldRawRef[i] : oldRawRef), parentSuspense, vnode, isUnmount));\r\n return;\r\n }\r\n if (isAsyncWrapper(vnode) && !isUnmount) {\r\n // when mounting async components, nothing needs to be done,\r\n // because the template ref is forwarded to inner component\r\n return;\r\n }\r\n const refValue = vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */\r\n ? getExposeProxy(vnode.component) || vnode.component.proxy\r\n : vnode.el;\r\n const value = isUnmount ? null : refValue;\r\n const { i: owner, r: ref } = rawRef;\r\n if ((process.env.NODE_ENV !== 'production') && !owner) {\r\n warn(`Missing ref owner context. ref cannot be used on hoisted vnodes. ` +\r\n `A vnode with ref must be created inside the render function.`);\r\n return;\r\n }\r\n const oldRef = oldRawRef && oldRawRef.r;\r\n const refs = owner.refs === EMPTY_OBJ ? (owner.refs = {}) : owner.refs;\r\n const setupState = owner.setupState;\r\n // dynamic ref changed. unset old ref\r\n if (oldRef != null && oldRef !== ref) {\r\n if (isString(oldRef)) {\r\n refs[oldRef] = null;\r\n if (hasOwn(setupState, oldRef)) {\r\n setupState[oldRef] = null;\r\n }\r\n }\r\n else if (isRef(oldRef)) {\r\n oldRef.value = null;\r\n }\r\n }\r\n if (isFunction(ref)) {\r\n callWithErrorHandling(ref, owner, 12 /* FUNCTION_REF */, [value, refs]);\r\n }\r\n else {\r\n const _isString = isString(ref);\r\n const _isRef = isRef(ref);\r\n if (_isString || _isRef) {\r\n const doSet = () => {\r\n if (rawRef.f) {\r\n const existing = _isString ? refs[ref] : ref.value;\r\n if (isUnmount) {\r\n isArray(existing) && remove(existing, refValue);\r\n }\r\n else {\r\n if (!isArray(existing)) {\r\n if (_isString) {\r\n refs[ref] = [refValue];\r\n }\r\n else {\r\n ref.value = [refValue];\r\n if (rawRef.k)\r\n refs[rawRef.k] = ref.value;\r\n }\r\n }\r\n else if (!existing.includes(refValue)) {\r\n existing.push(refValue);\r\n }\r\n }\r\n }\r\n else if (_isString) {\r\n refs[ref] = value;\r\n if (hasOwn(setupState, ref)) {\r\n setupState[ref] = value;\r\n }\r\n }\r\n else if (isRef(ref)) {\r\n ref.value = value;\r\n if (rawRef.k)\r\n refs[rawRef.k] = value;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid template ref type:', ref, `(${typeof ref})`);\r\n }\r\n };\r\n if (value) {\r\n doSet.id = -1;\r\n queuePostRenderEffect(doSet, parentSuspense);\r\n }\r\n else {\r\n doSet();\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid template ref type:', ref, `(${typeof ref})`);\r\n }\r\n }\r\n}\n\nlet hasMismatch = false;\r\nconst isSVGContainer = (container) => /svg/.test(container.namespaceURI) && container.tagName !== 'foreignObject';\r\nconst isComment = (node) => node.nodeType === 8 /* COMMENT */;\r\n// Note: hydration is DOM-specific\r\n// But we have to place it in core due to tight coupling with core - splitting\r\n// it out creates a ton of unnecessary complexity.\r\n// Hydration also depends on some renderer internal logic which needs to be\r\n// passed in via arguments.\r\nfunction createHydrationFunctions(rendererInternals) {\r\n const { mt: mountComponent, p: patch, o: { patchProp, nextSibling, parentNode, remove, insert, createComment } } = rendererInternals;\r\n const hydrate = (vnode, container) => {\r\n if (!container.hasChildNodes()) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to hydrate existing markup but container is empty. ` +\r\n `Performing full mount instead.`);\r\n patch(null, vnode, container);\r\n flushPostFlushCbs();\r\n return;\r\n }\r\n hasMismatch = false;\r\n hydrateNode(container.firstChild, vnode, null, null, null);\r\n flushPostFlushCbs();\r\n if (hasMismatch && !false) {\r\n // this error should show up in production\r\n console.error(`Hydration completed but contains mismatches.`);\r\n }\r\n };\r\n const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {\r\n const isFragmentStart = isComment(node) && node.data === '[';\r\n const onMismatch = () => handleMismatch(node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragmentStart);\r\n const { type, ref, shapeFlag } = vnode;\r\n const domType = node.nodeType;\r\n vnode.el = node;\r\n let nextNode = null;\r\n switch (type) {\r\n case Text:\r\n if (domType !== 3 /* TEXT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n if (node.data !== vnode.children) {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration text mismatch:` +\r\n `\\n- Client: ${JSON.stringify(node.data)}` +\r\n `\\n- Server: ${JSON.stringify(vnode.children)}`);\r\n node.data = vnode.children;\r\n }\r\n nextNode = nextSibling(node);\r\n }\r\n break;\r\n case Comment:\r\n if (domType !== 8 /* COMMENT */ || isFragmentStart) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = nextSibling(node);\r\n }\r\n break;\r\n case Static:\r\n if (domType !== 1 /* ELEMENT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n // determine anchor, adopt content\r\n nextNode = node;\r\n // if the static vnode has its content stripped during build,\r\n // adopt it from the server-rendered HTML.\r\n const needToAdoptContent = !vnode.children.length;\r\n for (let i = 0; i < vnode.staticCount; i++) {\r\n if (needToAdoptContent)\r\n vnode.children += nextNode.outerHTML;\r\n if (i === vnode.staticCount - 1) {\r\n vnode.anchor = nextNode;\r\n }\r\n nextNode = nextSibling(nextNode);\r\n }\r\n return nextNode;\r\n }\r\n break;\r\n case Fragment:\r\n if (!isFragmentStart) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = hydrateFragment(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n break;\r\n default:\r\n if (shapeFlag & 1 /* ELEMENT */) {\r\n if (domType !== 1 /* ELEMENT */ ||\r\n vnode.type.toLowerCase() !==\r\n node.tagName.toLowerCase()) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n }\r\n else if (shapeFlag & 6 /* COMPONENT */) {\r\n // when setting up the render effect, if the initial vnode already\r\n // has .el set, the component will perform hydration instead of mount\r\n // on its sub-tree.\r\n vnode.slotScopeIds = slotScopeIds;\r\n const container = parentNode(node);\r\n mountComponent(vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), optimized);\r\n // component may be async, so in the case of fragments we cannot rely\r\n // on component's rendered output to determine the end of the fragment\r\n // instead, we do a lookahead to find the end anchor node.\r\n nextNode = isFragmentStart\r\n ? locateClosingAsyncAnchor(node)\r\n : nextSibling(node);\r\n // #3787\r\n // if component is async, it may get moved / unmounted before its\r\n // inner component is loaded, so we need to give it a placeholder\r\n // vnode that matches its adopted DOM.\r\n if (isAsyncWrapper(vnode)) {\r\n let subTree;\r\n if (isFragmentStart) {\r\n subTree = createVNode(Fragment);\r\n subTree.anchor = nextNode\r\n ? nextNode.previousSibling\r\n : container.lastChild;\r\n }\r\n else {\r\n subTree =\r\n node.nodeType === 3 ? createTextVNode('') : createVNode('div');\r\n }\r\n subTree.el = node;\r\n vnode.component.subTree = subTree;\r\n }\r\n }\r\n else if (shapeFlag & 64 /* TELEPORT */) {\r\n if (domType !== 8 /* COMMENT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);\r\n }\r\n }\r\n else if (shapeFlag & 128 /* SUSPENSE */) {\r\n nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, isSVGContainer(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid HostVNode type:', type, `(${typeof type})`);\r\n }\r\n }\r\n if (ref != null) {\r\n setRef(ref, null, parentSuspense, vnode);\r\n }\r\n return nextNode;\r\n };\r\n const hydrateElement = (el, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n optimized = optimized || !!vnode.dynamicChildren;\r\n const { type, props, patchFlag, shapeFlag, dirs } = vnode;\r\n // #4006 for form elements with non-string v-model value bindings\r\n // e.g. <option :value=\"obj\">, <input type=\"checkbox\" :true-value=\"1\">\r\n const forcePatchValue = (type === 'input' && dirs) || type === 'option';\r\n // skip props & children if this is hoisted static nodes\r\n if (forcePatchValue || patchFlag !== -1 /* HOISTED */) {\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n }\r\n // props\r\n if (props) {\r\n if (forcePatchValue ||\r\n !optimized ||\r\n patchFlag & (16 /* FULL_PROPS */ | 32 /* HYDRATE_EVENTS */)) {\r\n for (const key in props) {\r\n if ((forcePatchValue && key.endsWith('value')) ||\r\n (isOn(key) && !isReservedProp(key))) {\r\n patchProp(el, key, null, props[key], false, undefined, parentComponent);\r\n }\r\n }\r\n }\r\n else if (props.onClick) {\r\n // Fast path for click listeners (which is most often) to avoid\r\n // iterating through props.\r\n patchProp(el, 'onClick', null, props.onClick, false, undefined, parentComponent);\r\n }\r\n }\r\n // vnode / directive hooks\r\n let vnodeHooks;\r\n if ((vnodeHooks = props && props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n }\r\n if ((vnodeHooks = props && props.onVnodeMounted) || dirs) {\r\n queueEffectWithSuspense(() => {\r\n vnodeHooks && invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n }, parentSuspense);\r\n }\r\n // children\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */ &&\r\n // skip if element has innerHTML / textContent\r\n !(props && (props.innerHTML || props.textContent))) {\r\n let next = hydrateChildren(el.firstChild, vnode, el, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n let hasWarned = false;\r\n while (next) {\r\n hasMismatch = true;\r\n if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n warn(`Hydration children mismatch in <${vnode.type}>: ` +\r\n `server rendered element contains more child nodes than client vdom.`);\r\n hasWarned = true;\r\n }\r\n // The SSRed DOM contains more nodes than it should. Remove them.\r\n const cur = next;\r\n next = next.nextSibling;\r\n remove(cur);\r\n }\r\n }\r\n else if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n if (el.textContent !== vnode.children) {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration text content mismatch in <${vnode.type}>:\\n` +\r\n `- Client: ${el.textContent}\\n` +\r\n `- Server: ${vnode.children}`);\r\n el.textContent = vnode.children;\r\n }\r\n }\r\n }\r\n return el.nextSibling;\r\n };\r\n const hydrateChildren = (node, parentVNode, container, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n optimized = optimized || !!parentVNode.dynamicChildren;\r\n const children = parentVNode.children;\r\n const l = children.length;\r\n let hasWarned = false;\r\n for (let i = 0; i < l; i++) {\r\n const vnode = optimized\r\n ? children[i]\r\n : (children[i] = normalizeVNode(children[i]));\r\n if (node) {\r\n node = hydrateNode(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n else if (vnode.type === Text && !vnode.children) {\r\n continue;\r\n }\r\n else {\r\n hasMismatch = true;\r\n if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n warn(`Hydration children mismatch in <${container.tagName.toLowerCase()}>: ` +\r\n `server rendered element contains fewer child nodes than client vdom.`);\r\n hasWarned = true;\r\n }\r\n // the SSRed DOM didn't contain enough nodes. Mount the missing ones.\r\n patch(null, vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n }\r\n }\r\n return node;\r\n };\r\n const hydrateFragment = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n const { slotScopeIds: fragmentSlotScopeIds } = vnode;\r\n if (fragmentSlotScopeIds) {\r\n slotScopeIds = slotScopeIds\r\n ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n : fragmentSlotScopeIds;\r\n }\r\n const container = parentNode(node);\r\n const next = hydrateChildren(nextSibling(node), vnode, container, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n if (next && isComment(next) && next.data === ']') {\r\n return nextSibling((vnode.anchor = next));\r\n }\r\n else {\r\n // fragment didn't hydrate successfully, since we didn't get a end anchor\r\n // back. This should have led to node/children mismatch warnings.\r\n hasMismatch = true;\r\n // since the anchor is missing, we need to create one and insert it\r\n insert((vnode.anchor = createComment(`]`)), container, next);\r\n return next;\r\n }\r\n };\r\n const handleMismatch = (node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragment) => {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration node mismatch:\\n- Client vnode:`, vnode.type, `\\n- Server rendered DOM:`, node, node.nodeType === 3 /* TEXT */\r\n ? `(text)`\r\n : isComment(node) && node.data === '['\r\n ? `(start of fragment)`\r\n : ``);\r\n vnode.el = null;\r\n if (isFragment) {\r\n // remove excessive fragment nodes\r\n const end = locateClosingAsyncAnchor(node);\r\n while (true) {\r\n const next = nextSibling(node);\r\n if (next && next !== end) {\r\n remove(next);\r\n }\r\n else {\r\n break;\r\n }\r\n }\r\n }\r\n const next = nextSibling(node);\r\n const container = parentNode(node);\r\n remove(node);\r\n patch(null, vnode, container, next, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n return next;\r\n };\r\n const locateClosingAsyncAnchor = (node) => {\r\n let match = 0;\r\n while (node) {\r\n node = nextSibling(node);\r\n if (node && isComment(node)) {\r\n if (node.data === '[')\r\n match++;\r\n if (node.data === ']') {\r\n if (match === 0) {\r\n return nextSibling(node);\r\n }\r\n else {\r\n match--;\r\n }\r\n }\r\n }\r\n }\r\n return node;\r\n };\r\n return [hydrate, hydrateNode];\r\n}\n\nlet supported;\r\nlet perf;\r\nfunction startMeasure(instance, type) {\r\n if (instance.appContext.config.performance && isSupported()) {\r\n perf.mark(`vue-${type}-${instance.uid}`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsPerfStart(instance, type, supported ? perf.now() : Date.now());\r\n }\r\n}\r\nfunction endMeasure(instance, type) {\r\n if (instance.appContext.config.performance && isSupported()) {\r\n const startTag = `vue-${type}-${instance.uid}`;\r\n const endTag = startTag + `:end`;\r\n perf.mark(endTag);\r\n perf.measure(`<${formatComponentName(instance, instance.type)}> ${type}`, startTag, endTag);\r\n perf.clearMarks(startTag);\r\n perf.clearMarks(endTag);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsPerfEnd(instance, type, supported ? perf.now() : Date.now());\r\n }\r\n}\r\nfunction isSupported() {\r\n if (supported !== undefined) {\r\n return supported;\r\n }\r\n /* eslint-disable no-restricted-globals */\r\n if (typeof window !== 'undefined' && window.performance) {\r\n supported = true;\r\n perf = window.performance;\r\n }\r\n else {\r\n supported = false;\r\n }\r\n /* eslint-enable no-restricted-globals */\r\n return supported;\r\n}\n\n/**\r\n * This is only called in esm-bundler builds.\r\n * It is called when a renderer is created, in `baseCreateRenderer` so that\r\n * importing runtime-core is side-effects free.\r\n *\r\n * istanbul-ignore-next\r\n */\r\nfunction initFeatureFlags() {\r\n const needWarn = [];\r\n if (typeof __VUE_OPTIONS_API__ !== 'boolean') {\r\n (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_OPTIONS_API__`);\r\n getGlobalThis().__VUE_OPTIONS_API__ = true;\r\n }\r\n if (typeof __VUE_PROD_DEVTOOLS__ !== 'boolean') {\r\n (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_PROD_DEVTOOLS__`);\r\n getGlobalThis().__VUE_PROD_DEVTOOLS__ = false;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && needWarn.length) {\r\n const multi = needWarn.length > 1;\r\n console.warn(`Feature flag${multi ? `s` : ``} ${needWarn.join(', ')} ${multi ? `are` : `is`} not explicitly defined. You are running the esm-bundler build of Vue, ` +\r\n `which expects these compile-time feature flags to be globally injected ` +\r\n `via the bundler config in order to get better tree-shaking in the ` +\r\n `production bundle.\\n\\n` +\r\n `For more details, see https://link.vuejs.org/feature-flags.`);\r\n }\r\n}\n\nconst queuePostRenderEffect = queueEffectWithSuspense\r\n ;\r\n/**\r\n * The createRenderer function accepts two generic arguments:\r\n * HostNode and HostElement, corresponding to Node and Element types in the\r\n * host environment. For example, for runtime-dom, HostNode would be the DOM\r\n * `Node` interface and HostElement would be the DOM `Element` interface.\r\n *\r\n * Custom renderers can pass in the platform specific types like this:\r\n *\r\n * ``` js\r\n * const { render, createApp } = createRenderer<Node, Element>({\r\n * patchProp,\r\n * ...nodeOps\r\n * })\r\n * ```\r\n */\r\nfunction createRenderer(options) {\r\n return baseCreateRenderer(options);\r\n}\r\n// Separate API for creating hydration-enabled renderer.\r\n// Hydration logic is only used when calling this function, making it\r\n// tree-shakable.\r\nfunction createHydrationRenderer(options) {\r\n return baseCreateRenderer(options, createHydrationFunctions);\r\n}\r\n// implementation\r\nfunction baseCreateRenderer(options, createHydrationFns) {\r\n // compile-time feature flags check\r\n {\r\n initFeatureFlags();\r\n }\r\n const target = getGlobalThis();\r\n target.__VUE__ = true;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n setDevtoolsHook(target.__VUE_DEVTOOLS_GLOBAL_HOOK__, target);\r\n }\r\n const { insert: hostInsert, remove: hostRemove, patchProp: hostPatchProp, createElement: hostCreateElement, createText: hostCreateText, createComment: hostCreateComment, setText: hostSetText, setElementText: hostSetElementText, parentNode: hostParentNode, nextSibling: hostNextSibling, setScopeId: hostSetScopeId = NOOP, cloneNode: hostCloneNode, insertStaticContent: hostInsertStaticContent } = options;\r\n // Note: functions inside this closure should use `const xxx = () => {}`\r\n // style in order to prevent being inlined by minifiers.\r\n const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, isSVG = false, slotScopeIds = null, optimized = (process.env.NODE_ENV !== 'production') && isHmrUpdating ? false : !!n2.dynamicChildren) => {\r\n if (n1 === n2) {\r\n return;\r\n }\r\n // patching & not same type, unmount old tree\r\n if (n1 && !isSameVNodeType(n1, n2)) {\r\n anchor = getNextHostNode(n1);\r\n unmount(n1, parentComponent, parentSuspense, true);\r\n n1 = null;\r\n }\r\n if (n2.patchFlag === -2 /* BAIL */) {\r\n optimized = false;\r\n n2.dynamicChildren = null;\r\n }\r\n const { type, ref, shapeFlag } = n2;\r\n switch (type) {\r\n case Text:\r\n processText(n1, n2, container, anchor);\r\n break;\r\n case Comment:\r\n processCommentNode(n1, n2, container, anchor);\r\n break;\r\n case Static:\r\n if (n1 == null) {\r\n mountStaticNode(n2, container, anchor, isSVG);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n patchStaticNode(n1, n2, container, isSVG);\r\n }\r\n break;\r\n case Fragment:\r\n processFragment(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n break;\r\n default:\r\n if (shapeFlag & 1 /* ELEMENT */) {\r\n processElement(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (shapeFlag & 6 /* COMPONENT */) {\r\n processComponent(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (shapeFlag & 64 /* TELEPORT */) {\r\n type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n }\r\n else if (shapeFlag & 128 /* SUSPENSE */) {\r\n type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid VNode type:', type, `(${typeof type})`);\r\n }\r\n }\r\n // set ref\r\n if (ref != null && parentComponent) {\r\n setRef(ref, n1 && n1.ref, parentSuspense, n2 || n1, !n2);\r\n }\r\n };\r\n const processText = (n1, n2, container, anchor) => {\r\n if (n1 == null) {\r\n hostInsert((n2.el = hostCreateText(n2.children)), container, anchor);\r\n }\r\n else {\r\n const el = (n2.el = n1.el);\r\n if (n2.children !== n1.children) {\r\n hostSetText(el, n2.children);\r\n }\r\n }\r\n };\r\n const processCommentNode = (n1, n2, container, anchor) => {\r\n if (n1 == null) {\r\n hostInsert((n2.el = hostCreateComment(n2.children || '')), container, anchor);\r\n }\r\n else {\r\n // there's no support for dynamic comments\r\n n2.el = n1.el;\r\n }\r\n };\r\n const mountStaticNode = (n2, container, anchor, isSVG) => {\r\n [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n };\r\n /**\r\n * Dev / HMR only\r\n */\r\n const patchStaticNode = (n1, n2, container, isSVG) => {\r\n // static nodes are only patched during dev for HMR\r\n if (n2.children !== n1.children) {\r\n const anchor = hostNextSibling(n1.anchor);\r\n // remove existing\r\n removeStaticNode(n1);\r\n [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n }\r\n else {\r\n n2.el = n1.el;\r\n n2.anchor = n1.anchor;\r\n }\r\n };\r\n const moveStaticNode = ({ el, anchor }, container, nextSibling) => {\r\n let next;\r\n while (el && el !== anchor) {\r\n next = hostNextSibling(el);\r\n hostInsert(el, container, nextSibling);\r\n el = next;\r\n }\r\n hostInsert(anchor, container, nextSibling);\r\n };\r\n const removeStaticNode = ({ el, anchor }) => {\r\n let next;\r\n while (el && el !== anchor) {\r\n next = hostNextSibling(el);\r\n hostRemove(el);\r\n el = next;\r\n }\r\n hostRemove(anchor);\r\n };\r\n const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n isSVG = isSVG || n2.type === 'svg';\r\n if (n1 == null) {\r\n mountElement(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n patchElement(n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n const mountElement = (vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n let el;\r\n let vnodeHook;\r\n const { type, props, shapeFlag, transition, patchFlag, dirs } = vnode;\r\n if (!(process.env.NODE_ENV !== 'production') &&\r\n vnode.el &&\r\n hostCloneNode !== undefined &&\r\n patchFlag === -1 /* HOISTED */) {\r\n // If a vnode has non-null el, it means it's being reused.\r\n // Only static vnodes can be reused, so its mounted DOM nodes should be\r\n // exactly the same, and we can simply do a clone here.\r\n // only do this in production since cloned trees cannot be HMR updated.\r\n el = vnode.el = hostCloneNode(vnode.el);\r\n }\r\n else {\r\n el = vnode.el = hostCreateElement(vnode.type, isSVG, props && props.is, props);\r\n // mount children first, since some props may rely on child content\r\n // being already rendered, e.g. `<select value>`\r\n if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n hostSetElementText(el, vnode.children);\r\n }\r\n else if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(vnode.children, el, null, parentComponent, parentSuspense, isSVG && type !== 'foreignObject', slotScopeIds, optimized);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n }\r\n // props\r\n if (props) {\r\n for (const key in props) {\r\n if (key !== 'value' && !isReservedProp(key)) {\r\n hostPatchProp(el, key, null, props[key], isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n /**\r\n * Special case for setting value on DOM elements:\r\n * - it can be order-sensitive (e.g. should be set *after* min/max, #2325, #4024)\r\n * - it needs to be forced (#1471)\r\n * #2353 proposes adding another renderer option to configure this, but\r\n * the properties affects are so finite it is worth special casing it\r\n * here to reduce the complexity. (Special casing it also should not\r\n * affect non-DOM renderers)\r\n */\r\n if ('value' in props) {\r\n hostPatchProp(el, 'value', null, props.value);\r\n }\r\n if ((vnodeHook = props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n }\r\n }\r\n // scopeId\r\n setScopeId(el, vnode, vnode.scopeId, slotScopeIds, parentComponent);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n Object.defineProperty(el, '__vnode', {\r\n value: vnode,\r\n enumerable: false\r\n });\r\n Object.defineProperty(el, '__vueParentComponent', {\r\n value: parentComponent,\r\n enumerable: false\r\n });\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n }\r\n // #1583 For inside suspense + suspense not resolved case, enter hook should call when suspense resolved\r\n // #1689 For inside suspense + suspense resolved case, just call it\r\n const needCallTransitionHooks = (!parentSuspense || (parentSuspense && !parentSuspense.pendingBranch)) &&\r\n transition &&\r\n !transition.persisted;\r\n if (needCallTransitionHooks) {\r\n transition.beforeEnter(el);\r\n }\r\n hostInsert(el, container, anchor);\r\n if ((vnodeHook = props && props.onVnodeMounted) ||\r\n needCallTransitionHooks ||\r\n dirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n needCallTransitionHooks && transition.enter(el);\r\n dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n }, parentSuspense);\r\n }\r\n };\r\n const setScopeId = (el, vnode, scopeId, slotScopeIds, parentComponent) => {\r\n if (scopeId) {\r\n hostSetScopeId(el, scopeId);\r\n }\r\n if (slotScopeIds) {\r\n for (let i = 0; i < slotScopeIds.length; i++) {\r\n hostSetScopeId(el, slotScopeIds[i]);\r\n }\r\n }\r\n if (parentComponent) {\r\n let subTree = parentComponent.subTree;\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n subTree.patchFlag > 0 &&\r\n subTree.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n subTree =\r\n filterSingleRoot(subTree.children) || subTree;\r\n }\r\n if (vnode === subTree) {\r\n const parentVNode = parentComponent.vnode;\r\n setScopeId(el, parentVNode, parentVNode.scopeId, parentVNode.slotScopeIds, parentComponent.parent);\r\n }\r\n }\r\n };\r\n const mountChildren = (children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, start = 0) => {\r\n for (let i = start; i < children.length; i++) {\r\n const child = (children[i] = optimized\r\n ? cloneIfMounted(children[i])\r\n : normalizeVNode(children[i]));\r\n patch(null, child, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n const patchElement = (n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n const el = (n2.el = n1.el);\r\n let { patchFlag, dynamicChildren, dirs } = n2;\r\n // #1426 take the old vnode's patch flag into account since user may clone a\r\n // compiler-generated vnode, which de-opts to FULL_PROPS\r\n patchFlag |= n1.patchFlag & 16 /* FULL_PROPS */;\r\n const oldProps = n1.props || EMPTY_OBJ;\r\n const newProps = n2.props || EMPTY_OBJ;\r\n let vnodeHook;\r\n // disable recurse in beforeUpdate hooks\r\n parentComponent && toggleRecurse(parentComponent, false);\r\n if ((vnodeHook = newProps.onVnodeBeforeUpdate)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(n2, n1, parentComponent, 'beforeUpdate');\r\n }\r\n parentComponent && toggleRecurse(parentComponent, true);\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // HMR updated, force full diff\r\n patchFlag = 0;\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n const areChildrenSVG = isSVG && n2.type !== 'foreignObject';\r\n if (dynamicChildren) {\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, el, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds);\r\n if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n traverseStaticChildren(n1, n2);\r\n }\r\n }\r\n else if (!optimized) {\r\n // full diff\r\n patchChildren(n1, n2, el, null, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds, false);\r\n }\r\n if (patchFlag > 0) {\r\n // the presence of a patchFlag means this element's render code was\r\n // generated by the compiler and can take the fast path.\r\n // in this path old node and new node are guaranteed to have the same shape\r\n // (i.e. at the exact same position in the source template)\r\n if (patchFlag & 16 /* FULL_PROPS */) {\r\n // element props contain dynamic keys, full diff needed\r\n patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n }\r\n else {\r\n // class\r\n // this flag is matched when the element has dynamic class bindings.\r\n if (patchFlag & 2 /* CLASS */) {\r\n if (oldProps.class !== newProps.class) {\r\n hostPatchProp(el, 'class', null, newProps.class, isSVG);\r\n }\r\n }\r\n // style\r\n // this flag is matched when the element has dynamic style bindings\r\n if (patchFlag & 4 /* STYLE */) {\r\n hostPatchProp(el, 'style', oldProps.style, newProps.style, isSVG);\r\n }\r\n // props\r\n // This flag is matched when the element has dynamic prop/attr bindings\r\n // other than class and style. The keys of dynamic prop/attrs are saved for\r\n // faster iteration.\r\n // Note dynamic keys like :[foo]=\"bar\" will cause this optimization to\r\n // bail out and go through a full diff because we need to unset the old key\r\n if (patchFlag & 8 /* PROPS */) {\r\n // if the flag is present then dynamicProps must be non-null\r\n const propsToUpdate = n2.dynamicProps;\r\n for (let i = 0; i < propsToUpdate.length; i++) {\r\n const key = propsToUpdate[i];\r\n const prev = oldProps[key];\r\n const next = newProps[key];\r\n // #1471 force patch value\r\n if (next !== prev || key === 'value') {\r\n hostPatchProp(el, key, prev, next, isSVG, n1.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n }\r\n }\r\n // text\r\n // This flag is matched when the element has only dynamic text children.\r\n if (patchFlag & 1 /* TEXT */) {\r\n if (n1.children !== n2.children) {\r\n hostSetElementText(el, n2.children);\r\n }\r\n }\r\n }\r\n else if (!optimized && dynamicChildren == null) {\r\n // unoptimized, full diff\r\n patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n }\r\n if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n dirs && invokeDirectiveHook(n2, n1, parentComponent, 'updated');\r\n }, parentSuspense);\r\n }\r\n };\r\n // The fast path for blocks.\r\n const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, isSVG, slotScopeIds) => {\r\n for (let i = 0; i < newChildren.length; i++) {\r\n const oldVNode = oldChildren[i];\r\n const newVNode = newChildren[i];\r\n // Determine the container (parent element) for the patch.\r\n const container = \r\n // oldVNode may be an errored async setup() component inside Suspense\r\n // which will not have a mounted element\r\n oldVNode.el &&\r\n // - In the case of a Fragment, we need to provide the actual parent\r\n // of the Fragment itself so it can move its children.\r\n (oldVNode.type === Fragment ||\r\n // - In the case of different nodes, there is going to be a replacement\r\n // which also requires the correct parent container\r\n !isSameVNodeType(oldVNode, newVNode) ||\r\n // - In the case of a component, it could contain anything.\r\n oldVNode.shapeFlag & (6 /* COMPONENT */ | 64 /* TELEPORT */))\r\n ? hostParentNode(oldVNode.el)\r\n : // In other cases, the parent container is not actually used so we\r\n // just pass the block element here to avoid a DOM parentNode call.\r\n fallbackContainer;\r\n patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, true);\r\n }\r\n };\r\n const patchProps = (el, vnode, oldProps, newProps, parentComponent, parentSuspense, isSVG) => {\r\n if (oldProps !== newProps) {\r\n for (const key in newProps) {\r\n // empty string is not valid prop\r\n if (isReservedProp(key))\r\n continue;\r\n const next = newProps[key];\r\n const prev = oldProps[key];\r\n // defer patching value\r\n if (next !== prev && key !== 'value') {\r\n hostPatchProp(el, key, prev, next, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n if (oldProps !== EMPTY_OBJ) {\r\n for (const key in oldProps) {\r\n if (!isReservedProp(key) && !(key in newProps)) {\r\n hostPatchProp(el, key, oldProps[key], null, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n }\r\n if ('value' in newProps) {\r\n hostPatchProp(el, 'value', oldProps.value, newProps.value);\r\n }\r\n }\r\n };\r\n const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n const fragmentStartAnchor = (n2.el = n1 ? n1.el : hostCreateText(''));\r\n const fragmentEndAnchor = (n2.anchor = n1 ? n1.anchor : hostCreateText(''));\r\n let { patchFlag, dynamicChildren, slotScopeIds: fragmentSlotScopeIds } = n2;\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // HMR updated, force full diff\r\n patchFlag = 0;\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n // check if this is a slot fragment with :slotted scope ids\r\n if (fragmentSlotScopeIds) {\r\n slotScopeIds = slotScopeIds\r\n ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n : fragmentSlotScopeIds;\r\n }\r\n if (n1 == null) {\r\n hostInsert(fragmentStartAnchor, container, anchor);\r\n hostInsert(fragmentEndAnchor, container, anchor);\r\n // a fragment can only have array children\r\n // since they are either generated by the compiler, or implicitly created\r\n // from arrays.\r\n mountChildren(n2.children, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n if (patchFlag > 0 &&\r\n patchFlag & 64 /* STABLE_FRAGMENT */ &&\r\n dynamicChildren &&\r\n // #2715 the previous fragment could've been a BAILed one as a result\r\n // of renderSlot() with no valid children\r\n n1.dynamicChildren) {\r\n // a stable fragment (template root or <template v-for>) doesn't need to\r\n // patch children order, but it may contain dynamicChildren.\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, container, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n traverseStaticChildren(n1, n2);\r\n }\r\n else if (\r\n // #2080 if the stable fragment has a key, it's a <template v-for> that may\r\n // get moved around. Make sure all root level vnodes inherit el.\r\n // #2134 or if it's a component root, it may also get moved around\r\n // as the component is being moved.\r\n n2.key != null ||\r\n (parentComponent && n2 === parentComponent.subTree)) {\r\n traverseStaticChildren(n1, n2, true /* shallow */);\r\n }\r\n }\r\n else {\r\n // keyed / unkeyed, or manual fragments.\r\n // for keyed & unkeyed, since they are compiler generated from v-for,\r\n // each child is guaranteed to be a block so the fragment will never\r\n // have dynamicChildren.\r\n patchChildren(n1, n2, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n }\r\n };\r\n const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n n2.slotScopeIds = slotScopeIds;\r\n if (n1 == null) {\r\n if (n2.shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n parentComponent.ctx.activate(n2, container, anchor, isSVG, optimized);\r\n }\r\n else {\r\n mountComponent(n2, container, anchor, parentComponent, parentSuspense, isSVG, optimized);\r\n }\r\n }\r\n else {\r\n updateComponent(n1, n2, optimized);\r\n }\r\n };\r\n const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, isSVG, optimized) => {\r\n const instance = (initialVNode.component = createComponentInstance(initialVNode, parentComponent, parentSuspense));\r\n if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n registerHMR(instance);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(initialVNode);\r\n startMeasure(instance, `mount`);\r\n }\r\n // inject renderer internals for keepAlive\r\n if (isKeepAlive(initialVNode)) {\r\n instance.ctx.renderer = internals;\r\n }\r\n // resolve props and slots for setup context\r\n {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `init`);\r\n }\r\n setupComponent(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `init`);\r\n }\r\n }\r\n // setup() is async. This component relies on async logic to be resolved\r\n // before proceeding\r\n if (instance.asyncDep) {\r\n parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect);\r\n // Give it a placeholder if this is not hydration\r\n // TODO handle self-defined fallback\r\n if (!initialVNode.el) {\r\n const placeholder = (instance.subTree = createVNode(Comment));\r\n processCommentNode(null, placeholder, container, anchor);\r\n }\r\n return;\r\n }\r\n setupRenderEffect(instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n endMeasure(instance, `mount`);\r\n }\r\n };\r\n const updateComponent = (n1, n2, optimized) => {\r\n const instance = (n2.component = n1.component);\r\n if (shouldUpdateComponent(n1, n2, optimized)) {\r\n if (instance.asyncDep &&\r\n !instance.asyncResolved) {\r\n // async & still pending - just update props and slots\r\n // since the component's reactive effect for render isn't set-up yet\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(n2);\r\n }\r\n updateComponentPreRender(instance, n2, optimized);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n return;\r\n }\r\n else {\r\n // normal update\r\n instance.next = n2;\r\n // in case the child component is also queued, remove it to avoid\r\n // double updating the same child component in the same flush.\r\n invalidateJob(instance.update);\r\n // instance.update is the reactive effect.\r\n instance.update();\r\n }\r\n }\r\n else {\r\n // no update needed. just copy over properties\r\n n2.component = n1.component;\r\n n2.el = n1.el;\r\n instance.vnode = n2;\r\n }\r\n };\r\n const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized) => {\r\n const componentUpdateFn = () => {\r\n if (!instance.isMounted) {\r\n let vnodeHook;\r\n const { el, props } = initialVNode;\r\n const { bm, m, parent } = instance;\r\n const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);\r\n toggleRecurse(instance, false);\r\n // beforeMount hook\r\n if (bm) {\r\n invokeArrayFns(bm);\r\n }\r\n // onVnodeBeforeMount\r\n if (!isAsyncWrapperVNode &&\r\n (vnodeHook = props && props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHook, parent, initialVNode);\r\n }\r\n toggleRecurse(instance, true);\r\n if (el && hydrateNode) {\r\n // vnode has adopted host node - perform hydration instead of mount.\r\n const hydrateSubTree = () => {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n instance.subTree = renderComponentRoot(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `hydrate`);\r\n }\r\n hydrateNode(el, instance.subTree, instance, parentSuspense, null);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `hydrate`);\r\n }\r\n };\r\n if (isAsyncWrapperVNode) {\r\n initialVNode.type.__asyncLoader().then(\r\n // note: we are moving the render call into an async callback,\r\n // which means it won't track dependencies - but it's ok because\r\n // a server-rendered async wrapper is already in resolved state\r\n // and it will never need to change.\r\n () => !instance.isUnmounted && hydrateSubTree());\r\n }\r\n else {\r\n hydrateSubTree();\r\n }\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n const subTree = (instance.subTree = renderComponentRoot(instance));\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `patch`);\r\n }\r\n patch(null, subTree, container, anchor, instance, parentSuspense, isSVG);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `patch`);\r\n }\r\n initialVNode.el = subTree.el;\r\n }\r\n // mounted hook\r\n if (m) {\r\n queuePostRenderEffect(m, parentSuspense);\r\n }\r\n // onVnodeMounted\r\n if (!isAsyncWrapperVNode &&\r\n (vnodeHook = props && props.onVnodeMounted)) {\r\n const scopedInitialVNode = initialVNode;\r\n queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode), parentSuspense);\r\n }\r\n // activated hook for keep-alive roots.\r\n // #1742 activated hook must be accessed after first render\r\n // since the hook may be injected by a child keep-alive\r\n if (initialVNode.shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n instance.a && queuePostRenderEffect(instance.a, parentSuspense);\r\n }\r\n instance.isMounted = true;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentAdded(instance);\r\n }\r\n // #2458: deference mount-only object parameters to prevent memleaks\r\n initialVNode = container = anchor = null;\r\n }\r\n else {\r\n // updateComponent\r\n // This is triggered by mutation of component's own state (next: null)\r\n // OR parent calling processComponent (next: VNode)\r\n let { next, bu, u, parent, vnode } = instance;\r\n let originNext = next;\r\n let vnodeHook;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(next || instance.vnode);\r\n }\r\n // Disallow component effect recursion during pre-lifecycle hooks.\r\n toggleRecurse(instance, false);\r\n if (next) {\r\n next.el = vnode.el;\r\n updateComponentPreRender(instance, next, optimized);\r\n }\r\n else {\r\n next = vnode;\r\n }\r\n // beforeUpdate hook\r\n if (bu) {\r\n invokeArrayFns(bu);\r\n }\r\n // onVnodeBeforeUpdate\r\n if ((vnodeHook = next.props && next.props.onVnodeBeforeUpdate)) {\r\n invokeVNodeHook(vnodeHook, parent, next, vnode);\r\n }\r\n toggleRecurse(instance, true);\r\n // render\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n const nextTree = renderComponentRoot(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n const prevTree = instance.subTree;\r\n instance.subTree = nextTree;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `patch`);\r\n }\r\n patch(prevTree, nextTree, \r\n // parent may have changed if it's in a teleport\r\n hostParentNode(prevTree.el), \r\n // anchor may have changed if it's in a fragment\r\n getNextHostNode(prevTree), instance, parentSuspense, isSVG);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `patch`);\r\n }\r\n next.el = nextTree.el;\r\n if (originNext === null) {\r\n // self-triggered update. In case of HOC, update parent component\r\n // vnode el. HOC is indicated by parent instance's subTree pointing\r\n // to child component's vnode\r\n updateHOCHostEl(instance, nextTree.el);\r\n }\r\n // updated hook\r\n if (u) {\r\n queuePostRenderEffect(u, parentSuspense);\r\n }\r\n // onVnodeUpdated\r\n if ((vnodeHook = next.props && next.props.onVnodeUpdated)) {\r\n queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, next, vnode), parentSuspense);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentUpdated(instance);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n }\r\n };\r\n // create reactive effect for rendering\r\n const effect = (instance.effect = new ReactiveEffect(componentUpdateFn, () => queueJob(instance.update), instance.scope // track it in component's effect scope\r\n ));\r\n const update = (instance.update = effect.run.bind(effect));\r\n update.id = instance.uid;\r\n // allowRecurse\r\n // #1801, #2043 component render effects should allow recursive updates\r\n toggleRecurse(instance, true);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n effect.onTrack = instance.rtc\r\n ? e => invokeArrayFns(instance.rtc, e)\r\n : void 0;\r\n effect.onTrigger = instance.rtg\r\n ? e => invokeArrayFns(instance.rtg, e)\r\n : void 0;\r\n // @ts-ignore (for scheduler)\r\n update.ownerInstance = instance;\r\n }\r\n update();\r\n };\r\n const updateComponentPreRender = (instance, nextVNode, optimized) => {\r\n nextVNode.component = instance;\r\n const prevProps = instance.vnode.props;\r\n instance.vnode = nextVNode;\r\n instance.next = null;\r\n updateProps(instance, nextVNode.props, prevProps, optimized);\r\n updateSlots(instance, nextVNode.children, optimized);\r\n pauseTracking();\r\n // props update may have triggered pre-flush watchers.\r\n // flush them before the render update.\r\n flushPreFlushCbs(undefined, instance.update);\r\n resetTracking();\r\n };\r\n const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized = false) => {\r\n const c1 = n1 && n1.children;\r\n const prevShapeFlag = n1 ? n1.shapeFlag : 0;\r\n const c2 = n2.children;\r\n const { patchFlag, shapeFlag } = n2;\r\n // fast path\r\n if (patchFlag > 0) {\r\n if (patchFlag & 128 /* KEYED_FRAGMENT */) {\r\n // this could be either fully-keyed or mixed (some keyed some not)\r\n // presence of patchFlag means children are guaranteed to be arrays\r\n patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n return;\r\n }\r\n else if (patchFlag & 256 /* UNKEYED_FRAGMENT */) {\r\n // unkeyed\r\n patchUnkeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n return;\r\n }\r\n }\r\n // children has 3 possibilities: text, array or no children.\r\n if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n // text children fast path\r\n if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n unmountChildren(c1, parentComponent, parentSuspense);\r\n }\r\n if (c2 !== c1) {\r\n hostSetElementText(container, c2);\r\n }\r\n }\r\n else {\r\n if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n // prev children was array\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n // two arrays, cannot assume anything, do full diff\r\n patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n // no new children, just unmount old\r\n unmountChildren(c1, parentComponent, parentSuspense, true);\r\n }\r\n }\r\n else {\r\n // prev children was text OR null\r\n // new children is array OR null\r\n if (prevShapeFlag & 8 /* TEXT_CHILDREN */) {\r\n hostSetElementText(container, '');\r\n }\r\n // mount new if array\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n }\r\n }\r\n };\r\n const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n c1 = c1 || EMPTY_ARR;\r\n c2 = c2 || EMPTY_ARR;\r\n const oldLength = c1.length;\r\n const newLength = c2.length;\r\n const commonLength = Math.min(oldLength, newLength);\r\n let i;\r\n for (i = 0; i < commonLength; i++) {\r\n const nextChild = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n patch(c1[i], nextChild, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n if (oldLength > newLength) {\r\n // remove old\r\n unmountChildren(c1, parentComponent, parentSuspense, true, false, commonLength);\r\n }\r\n else {\r\n // mount new\r\n mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, commonLength);\r\n }\r\n };\r\n // can be all-keyed or mixed\r\n const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n let i = 0;\r\n const l2 = c2.length;\r\n let e1 = c1.length - 1; // prev ending index\r\n let e2 = l2 - 1; // next ending index\r\n // 1. sync from start\r\n // (a b) c\r\n // (a b) d e\r\n while (i <= e1 && i <= e2) {\r\n const n1 = c1[i];\r\n const n2 = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n if (isSameVNodeType(n1, n2)) {\r\n patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n break;\r\n }\r\n i++;\r\n }\r\n // 2. sync from end\r\n // a (b c)\r\n // d e (b c)\r\n while (i <= e1 && i <= e2) {\r\n const n1 = c1[e1];\r\n const n2 = (c2[e2] = optimized\r\n ? cloneIfMounted(c2[e2])\r\n : normalizeVNode(c2[e2]));\r\n if (isSameVNodeType(n1, n2)) {\r\n patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n break;\r\n }\r\n e1--;\r\n e2--;\r\n }\r\n // 3. common sequence + mount\r\n // (a b)\r\n // (a b) c\r\n // i = 2, e1 = 1, e2 = 2\r\n // (a b)\r\n // c (a b)\r\n // i = 0, e1 = -1, e2 = 0\r\n if (i > e1) {\r\n if (i <= e2) {\r\n const nextPos = e2 + 1;\r\n const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;\r\n while (i <= e2) {\r\n patch(null, (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i])), container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n i++;\r\n }\r\n }\r\n }\r\n // 4. common sequence + unmount\r\n // (a b) c\r\n // (a b)\r\n // i = 2, e1 = 2, e2 = 1\r\n // a (b c)\r\n // (b c)\r\n // i = 0, e1 = 0, e2 = -1\r\n else if (i > e2) {\r\n while (i <= e1) {\r\n unmount(c1[i], parentComponent, parentSuspense, true);\r\n i++;\r\n }\r\n }\r\n // 5. unknown sequence\r\n // [i ... e1 + 1]: a b [c d e] f g\r\n // [i ... e2 + 1]: a b [e d c h] f g\r\n // i = 2, e1 = 4, e2 = 5\r\n else {\r\n const s1 = i; // prev starting index\r\n const s2 = i; // next starting index\r\n // 5.1 build key:index map for newChildren\r\n const keyToNewIndexMap = new Map();\r\n for (i = s2; i <= e2; i++) {\r\n const nextChild = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n if (nextChild.key != null) {\r\n if ((process.env.NODE_ENV !== 'production') && keyToNewIndexMap.has(nextChild.key)) {\r\n warn(`Duplicate keys found during update:`, JSON.stringify(nextChild.key), `Make sure keys are unique.`);\r\n }\r\n keyToNewIndexMap.set(nextChild.key, i);\r\n }\r\n }\r\n // 5.2 loop through old children left to be patched and try to patch\r\n // matching nodes & remove nodes that are no longer present\r\n let j;\r\n let patched = 0;\r\n const toBePatched = e2 - s2 + 1;\r\n let moved = false;\r\n // used to track whether any node has moved\r\n let maxNewIndexSoFar = 0;\r\n // works as Map<newIndex, oldIndex>\r\n // Note that oldIndex is offset by +1\r\n // and oldIndex = 0 is a special value indicating the new node has\r\n // no corresponding old node.\r\n // used for determining longest stable subsequence\r\n const newIndexToOldIndexMap = new Array(toBePatched);\r\n for (i = 0; i < toBePatched; i++)\r\n newIndexToOldIndexMap[i] = 0;\r\n for (i = s1; i <= e1; i++) {\r\n const prevChild = c1[i];\r\n if (patched >= toBePatched) {\r\n // all new children have been patched so this can only be a removal\r\n unmount(prevChild, parentComponent, parentSuspense, true);\r\n continue;\r\n }\r\n let newIndex;\r\n if (prevChild.key != null) {\r\n newIndex = keyToNewIndexMap.get(prevChild.key);\r\n }\r\n else {\r\n // key-less node, try to locate a key-less node of the same type\r\n for (j = s2; j <= e2; j++) {\r\n if (newIndexToOldIndexMap[j - s2] === 0 &&\r\n isSameVNodeType(prevChild, c2[j])) {\r\n newIndex = j;\r\n break;\r\n }\r\n }\r\n }\r\n if (newIndex === undefined) {\r\n unmount(prevChild, parentComponent, parentSuspense, true);\r\n }\r\n else {\r\n newIndexToOldIndexMap[newIndex - s2] = i + 1;\r\n if (newIndex >= maxNewIndexSoFar) {\r\n maxNewIndexSoFar = newIndex;\r\n }\r\n else {\r\n moved = true;\r\n }\r\n patch(prevChild, c2[newIndex], container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n patched++;\r\n }\r\n }\r\n // 5.3 move and mount\r\n // generate longest stable subsequence only when nodes have moved\r\n const increasingNewIndexSequence = moved\r\n ? getSequence(newIndexToOldIndexMap)\r\n : EMPTY_ARR;\r\n j = increasingNewIndexSequence.length - 1;\r\n // looping backwards so that we can use last patched node as anchor\r\n for (i = toBePatched - 1; i >= 0; i--) {\r\n const nextIndex = s2 + i;\r\n const nextChild = c2[nextIndex];\r\n const anchor = nextIndex + 1 < l2 ? c2[nextIndex + 1].el : parentAnchor;\r\n if (newIndexToOldIndexMap[i] === 0) {\r\n // mount new\r\n patch(null, nextChild, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (moved) {\r\n // move if:\r\n // There is no stable subsequence (e.g. a reverse)\r\n // OR current node is not among the stable sequence\r\n if (j < 0 || i !== increasingNewIndexSequence[j]) {\r\n move(nextChild, container, anchor, 2 /* REORDER */);\r\n }\r\n else {\r\n j--;\r\n }\r\n }\r\n }\r\n }\r\n };\r\n const move = (vnode, container, anchor, moveType, parentSuspense = null) => {\r\n const { el, type, transition, children, shapeFlag } = vnode;\r\n if (shapeFlag & 6 /* COMPONENT */) {\r\n move(vnode.component.subTree, container, anchor, moveType);\r\n return;\r\n }\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.suspense.move(container, anchor, moveType);\r\n return;\r\n }\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n type.move(vnode, container, anchor, internals);\r\n return;\r\n }\r\n if (type === Fragment) {\r\n hostInsert(el, container, anchor);\r\n for (let i = 0; i < children.length; i++) {\r\n move(children[i], container, anchor, moveType);\r\n }\r\n hostInsert(vnode.anchor, container, anchor);\r\n return;\r\n }\r\n if (type === Static) {\r\n moveStaticNode(vnode, container, anchor);\r\n return;\r\n }\r\n // single nodes\r\n const needTransition = moveType !== 2 /* REORDER */ &&\r\n shapeFlag & 1 /* ELEMENT */ &&\r\n transition;\r\n if (needTransition) {\r\n if (moveType === 0 /* ENTER */) {\r\n transition.beforeEnter(el);\r\n hostInsert(el, container, anchor);\r\n queuePostRenderEffect(() => transition.enter(el), parentSuspense);\r\n }\r\n else {\r\n const { leave, delayLeave, afterLeave } = transition;\r\n const remove = () => hostInsert(el, container, anchor);\r\n const performLeave = () => {\r\n leave(el, () => {\r\n remove();\r\n afterLeave && afterLeave();\r\n });\r\n };\r\n if (delayLeave) {\r\n delayLeave(el, remove, performLeave);\r\n }\r\n else {\r\n performLeave();\r\n }\r\n }\r\n }\r\n else {\r\n hostInsert(el, container, anchor);\r\n }\r\n };\r\n const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {\r\n const { type, props, ref, children, dynamicChildren, shapeFlag, patchFlag, dirs } = vnode;\r\n // unset ref\r\n if (ref != null) {\r\n setRef(ref, null, parentSuspense, vnode, true);\r\n }\r\n if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n parentComponent.ctx.deactivate(vnode);\r\n return;\r\n }\r\n const shouldInvokeDirs = shapeFlag & 1 /* ELEMENT */ && dirs;\r\n const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);\r\n let vnodeHook;\r\n if (shouldInvokeVnodeHook &&\r\n (vnodeHook = props && props.onVnodeBeforeUnmount)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n }\r\n if (shapeFlag & 6 /* COMPONENT */) {\r\n unmountComponent(vnode.component, parentSuspense, doRemove);\r\n }\r\n else {\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.suspense.unmount(parentSuspense, doRemove);\r\n return;\r\n }\r\n if (shouldInvokeDirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeUnmount');\r\n }\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n vnode.type.remove(vnode, parentComponent, parentSuspense, optimized, internals, doRemove);\r\n }\r\n else if (dynamicChildren &&\r\n // #1153: fast path should not be taken for non-stable (v-for) fragments\r\n (type !== Fragment ||\r\n (patchFlag > 0 && patchFlag & 64 /* STABLE_FRAGMENT */))) {\r\n // fast path for block nodes: only need to unmount dynamic children.\r\n unmountChildren(dynamicChildren, parentComponent, parentSuspense, false, true);\r\n }\r\n else if ((type === Fragment &&\r\n patchFlag &\r\n (128 /* KEYED_FRAGMENT */ | 256 /* UNKEYED_FRAGMENT */)) ||\r\n (!optimized && shapeFlag & 16 /* ARRAY_CHILDREN */)) {\r\n unmountChildren(children, parentComponent, parentSuspense);\r\n }\r\n if (doRemove) {\r\n remove(vnode);\r\n }\r\n }\r\n if ((shouldInvokeVnodeHook &&\r\n (vnodeHook = props && props.onVnodeUnmounted)) ||\r\n shouldInvokeDirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n shouldInvokeDirs &&\r\n invokeDirectiveHook(vnode, null, parentComponent, 'unmounted');\r\n }, parentSuspense);\r\n }\r\n };\r\n const remove = vnode => {\r\n const { type, el, anchor, transition } = vnode;\r\n if (type === Fragment) {\r\n removeFragment(el, anchor);\r\n return;\r\n }\r\n if (type === Static) {\r\n removeStaticNode(vnode);\r\n return;\r\n }\r\n const performRemove = () => {\r\n hostRemove(el);\r\n if (transition && !transition.persisted && transition.afterLeave) {\r\n transition.afterLeave();\r\n }\r\n };\r\n if (vnode.shapeFlag & 1 /* ELEMENT */ &&\r\n transition &&\r\n !transition.persisted) {\r\n const { leave, delayLeave } = transition;\r\n const performLeave = () => leave(el, performRemove);\r\n if (delayLeave) {\r\n delayLeave(vnode.el, performRemove, performLeave);\r\n }\r\n else {\r\n performLeave();\r\n }\r\n }\r\n else {\r\n performRemove();\r\n }\r\n };\r\n const removeFragment = (cur, end) => {\r\n // For fragments, directly remove all contained DOM nodes.\r\n // (fragment child nodes cannot have transition)\r\n let next;\r\n while (cur !== end) {\r\n next = hostNextSibling(cur);\r\n hostRemove(cur);\r\n cur = next;\r\n }\r\n hostRemove(end);\r\n };\r\n const unmountComponent = (instance, parentSuspense, doRemove) => {\r\n if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n unregisterHMR(instance);\r\n }\r\n const { bum, scope, update, subTree, um } = instance;\r\n // beforeUnmount hook\r\n if (bum) {\r\n invokeArrayFns(bum);\r\n }\r\n // stop effects in component scope\r\n scope.stop();\r\n // update may be null if a component is unmounted before its async\r\n // setup has resolved.\r\n if (update) {\r\n // so that scheduler will no longer invoke it\r\n update.active = false;\r\n unmount(subTree, instance, parentSuspense, doRemove);\r\n }\r\n // unmounted hook\r\n if (um) {\r\n queuePostRenderEffect(um, parentSuspense);\r\n }\r\n queuePostRenderEffect(() => {\r\n instance.isUnmounted = true;\r\n }, parentSuspense);\r\n // A component with async dep inside a pending suspense is unmounted before\r\n // its async dep resolves. This should remove the dep from the suspense, and\r\n // cause the suspense to resolve immediately if that was the last dep.\r\n if (parentSuspense &&\r\n parentSuspense.pendingBranch &&\r\n !parentSuspense.isUnmounted &&\r\n instance.asyncDep &&\r\n !instance.asyncResolved &&\r\n instance.suspenseId === parentSuspense.pendingId) {\r\n parentSuspense.deps--;\r\n if (parentSuspense.deps === 0) {\r\n parentSuspense.resolve();\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentRemoved(instance);\r\n }\r\n };\r\n const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {\r\n for (let i = start; i < children.length; i++) {\r\n unmount(children[i], parentComponent, parentSuspense, doRemove, optimized);\r\n }\r\n };\r\n const getNextHostNode = vnode => {\r\n if (vnode.shapeFlag & 6 /* COMPONENT */) {\r\n return getNextHostNode(vnode.component.subTree);\r\n }\r\n if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n return vnode.suspense.next();\r\n }\r\n return hostNextSibling((vnode.anchor || vnode.el));\r\n };\r\n const render = (vnode, container, isSVG) => {\r\n if (vnode == null) {\r\n if (container._vnode) {\r\n unmount(container._vnode, null, null, true);\r\n }\r\n }\r\n else {\r\n patch(container._vnode || null, vnode, container, null, null, null, isSVG);\r\n }\r\n flushPostFlushCbs();\r\n container._vnode = vnode;\r\n };\r\n const internals = {\r\n p: patch,\r\n um: unmount,\r\n m: move,\r\n r: remove,\r\n mt: mountComponent,\r\n mc: mountChildren,\r\n pc: patchChildren,\r\n pbc: patchBlockChildren,\r\n n: getNextHostNode,\r\n o: options\r\n };\r\n let hydrate;\r\n let hydrateNode;\r\n if (createHydrationFns) {\r\n [hydrate, hydrateNode] = createHydrationFns(internals);\r\n }\r\n return {\r\n render,\r\n hydrate,\r\n createApp: createAppAPI(render, hydrate)\r\n };\r\n}\r\nfunction toggleRecurse({ effect, update }, allowed) {\r\n effect.allowRecurse = update.allowRecurse = allowed;\r\n}\r\n/**\r\n * #1156\r\n * When a component is HMR-enabled, we need to make sure that all static nodes\r\n * inside a block also inherit the DOM element from the previous tree so that\r\n * HMR updates (which are full updates) can retrieve the element for patching.\r\n *\r\n * #2080\r\n * Inside keyed `template` fragment static children, if a fragment is moved,\r\n * the children will always be moved. Therefore, in order to ensure correct move\r\n * position, el should be inherited from previous nodes.\r\n */\r\nfunction traverseStaticChildren(n1, n2, shallow = false) {\r\n const ch1 = n1.children;\r\n const ch2 = n2.children;\r\n if (isArray(ch1) && isArray(ch2)) {\r\n for (let i = 0; i < ch1.length; i++) {\r\n // this is only called in the optimized path so array children are\r\n // guaranteed to be vnodes\r\n const c1 = ch1[i];\r\n let c2 = ch2[i];\r\n if (c2.shapeFlag & 1 /* ELEMENT */ && !c2.dynamicChildren) {\r\n if (c2.patchFlag <= 0 || c2.patchFlag === 32 /* HYDRATE_EVENTS */) {\r\n c2 = ch2[i] = cloneIfMounted(ch2[i]);\r\n c2.el = c1.el;\r\n }\r\n if (!shallow)\r\n traverseStaticChildren(c1, c2);\r\n }\r\n // also inherit for comment nodes, but not placeholders (e.g. v-if which\r\n // would have received .el during block patch)\r\n if ((process.env.NODE_ENV !== 'production') && c2.type === Comment && !c2.el) {\r\n c2.el = c1.el;\r\n }\r\n }\r\n }\r\n}\r\n// https://en.wikipedia.org/wiki/Longest_increasing_subsequence\r\nfunction getSequence(arr) {\r\n const p = arr.slice();\r\n const result = [0];\r\n let i, j, u, v, c;\r\n const len = arr.length;\r\n for (i = 0; i < len; i++) {\r\n const arrI = arr[i];\r\n if (arrI !== 0) {\r\n j = result[result.length - 1];\r\n if (arr[j] < arrI) {\r\n p[i] = j;\r\n result.push(i);\r\n continue;\r\n }\r\n u = 0;\r\n v = result.length - 1;\r\n while (u < v) {\r\n c = (u + v) >> 1;\r\n if (arr[result[c]] < arrI) {\r\n u = c + 1;\r\n }\r\n else {\r\n v = c;\r\n }\r\n }\r\n if (arrI < arr[result[u]]) {\r\n if (u > 0) {\r\n p[i] = result[u - 1];\r\n }\r\n result[u] = i;\r\n }\r\n }\r\n }\r\n u = result.length;\r\n v = result[u - 1];\r\n while (u-- > 0) {\r\n result[u] = v;\r\n v = p[v];\r\n }\r\n return result;\r\n}\n\nconst isTeleport = (type) => type.__isTeleport;\r\nconst isTeleportDisabled = (props) => props && (props.disabled || props.disabled === '');\r\nconst isTargetSVG = (target) => typeof SVGElement !== 'undefined' && target instanceof SVGElement;\r\nconst resolveTarget = (props, select) => {\r\n const targetSelector = props && props.to;\r\n if (isString(targetSelector)) {\r\n if (!select) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Current renderer does not support string target for Teleports. ` +\r\n `(missing querySelector renderer option)`);\r\n return null;\r\n }\r\n else {\r\n const target = select(targetSelector);\r\n if (!target) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Failed to locate Teleport target with selector \"${targetSelector}\". ` +\r\n `Note the target element must exist before the component is mounted - ` +\r\n `i.e. the target cannot be rendered by the component itself, and ` +\r\n `ideally should be outside of the entire Vue component tree.`);\r\n }\r\n return target;\r\n }\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && !targetSelector && !isTeleportDisabled(props)) {\r\n warn(`Invalid Teleport target: ${targetSelector}`);\r\n }\r\n return targetSelector;\r\n }\r\n};\r\nconst TeleportImpl = {\r\n __isTeleport: true,\r\n process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals) {\r\n const { mc: mountChildren, pc: patchChildren, pbc: patchBlockChildren, o: { insert, querySelector, createText, createComment } } = internals;\r\n const disabled = isTeleportDisabled(n2.props);\r\n let { shapeFlag, children, dynamicChildren } = n2;\r\n // #3302\r\n // HMR updated, force full diff\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n if (n1 == null) {\r\n // insert anchors in the main view\r\n const placeholder = (n2.el = (process.env.NODE_ENV !== 'production')\r\n ? createComment('teleport start')\r\n : createText(''));\r\n const mainAnchor = (n2.anchor = (process.env.NODE_ENV !== 'production')\r\n ? createComment('teleport end')\r\n : createText(''));\r\n insert(placeholder, container, anchor);\r\n insert(mainAnchor, container, anchor);\r\n const target = (n2.target = resolveTarget(n2.props, querySelector));\r\n const targetAnchor = (n2.targetAnchor = createText(''));\r\n if (target) {\r\n insert(targetAnchor, target);\r\n // #2652 we could be teleporting from a non-SVG tree into an SVG tree\r\n isSVG = isSVG || isTargetSVG(target);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && !disabled) {\r\n warn('Invalid Teleport target on mount:', target, `(${typeof target})`);\r\n }\r\n const mount = (container, anchor) => {\r\n // Teleport *always* has Array children. This is enforced in both the\r\n // compiler and vnode children normalization.\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n if (disabled) {\r\n mount(container, mainAnchor);\r\n }\r\n else if (target) {\r\n mount(target, targetAnchor);\r\n }\r\n }\r\n else {\r\n // update content\r\n n2.el = n1.el;\r\n const mainAnchor = (n2.anchor = n1.anchor);\r\n const target = (n2.target = n1.target);\r\n const targetAnchor = (n2.targetAnchor = n1.targetAnchor);\r\n const wasDisabled = isTeleportDisabled(n1.props);\r\n const currentContainer = wasDisabled ? container : target;\r\n const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;\r\n isSVG = isSVG || isTargetSVG(target);\r\n if (dynamicChildren) {\r\n // fast path when the teleport happens to be a block root\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, currentContainer, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n // even in block tree mode we need to make sure all root-level nodes\r\n // in the teleport inherit previous DOM references so that they can\r\n // be moved in future patches.\r\n traverseStaticChildren(n1, n2, true);\r\n }\r\n else if (!optimized) {\r\n patchChildren(n1, n2, currentContainer, currentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, false);\r\n }\r\n if (disabled) {\r\n if (!wasDisabled) {\r\n // enabled -> disabled\r\n // move into main container\r\n moveTeleport(n2, container, mainAnchor, internals, 1 /* TOGGLE */);\r\n }\r\n }\r\n else {\r\n // target changed\r\n if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {\r\n const nextTarget = (n2.target = resolveTarget(n2.props, querySelector));\r\n if (nextTarget) {\r\n moveTeleport(n2, nextTarget, null, internals, 0 /* TARGET_CHANGE */);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid Teleport target on update:', target, `(${typeof target})`);\r\n }\r\n }\r\n else if (wasDisabled) {\r\n // disabled -> enabled\r\n // move into teleport target\r\n moveTeleport(n2, target, targetAnchor, internals, 1 /* TOGGLE */);\r\n }\r\n }\r\n }\r\n },\r\n remove(vnode, parentComponent, parentSuspense, optimized, { um: unmount, o: { remove: hostRemove } }, doRemove) {\r\n const { shapeFlag, children, anchor, targetAnchor, target, props } = vnode;\r\n if (target) {\r\n hostRemove(targetAnchor);\r\n }\r\n // an unmounted teleport should always remove its children if not disabled\r\n if (doRemove || !isTeleportDisabled(props)) {\r\n hostRemove(anchor);\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n unmount(child, parentComponent, parentSuspense, true, !!child.dynamicChildren);\r\n }\r\n }\r\n }\r\n },\r\n move: moveTeleport,\r\n hydrate: hydrateTeleport\r\n};\r\nfunction moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }, moveType = 2 /* REORDER */) {\r\n // move target anchor if this is a target change.\r\n if (moveType === 0 /* TARGET_CHANGE */) {\r\n insert(vnode.targetAnchor, container, parentAnchor);\r\n }\r\n const { el, anchor, shapeFlag, children, props } = vnode;\r\n const isReorder = moveType === 2 /* REORDER */;\r\n // move main view anchor if this is a re-order.\r\n if (isReorder) {\r\n insert(el, container, parentAnchor);\r\n }\r\n // if this is a re-order and teleport is enabled (content is in target)\r\n // do not move children. So the opposite is: only move children if this\r\n // is not a reorder, or the teleport is disabled\r\n if (!isReorder || isTeleportDisabled(props)) {\r\n // Teleport has either Array children or no children.\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n for (let i = 0; i < children.length; i++) {\r\n move(children[i], container, parentAnchor, 2 /* REORDER */);\r\n }\r\n }\r\n }\r\n // move main view anchor if this is a re-order.\r\n if (isReorder) {\r\n insert(anchor, container, parentAnchor);\r\n }\r\n}\r\nfunction hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, { o: { nextSibling, parentNode, querySelector } }, hydrateChildren) {\r\n const target = (vnode.target = resolveTarget(vnode.props, querySelector));\r\n if (target) {\r\n // if multiple teleports rendered to the same target element, we need to\r\n // pick up from where the last teleport finished instead of the first node\r\n const targetNode = target._lpa || target.firstChild;\r\n if (vnode.shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n if (isTeleportDisabled(vnode.props)) {\r\n vnode.anchor = hydrateChildren(nextSibling(node), vnode, parentNode(node), parentComponent, parentSuspense, slotScopeIds, optimized);\r\n vnode.targetAnchor = targetNode;\r\n }\r\n else {\r\n vnode.anchor = nextSibling(node);\r\n vnode.targetAnchor = hydrateChildren(targetNode, vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n target._lpa =\r\n vnode.targetAnchor && nextSibling(vnode.targetAnchor);\r\n }\r\n }\r\n return vnode.anchor && nextSibling(vnode.anchor);\r\n}\r\n// Force-casted public typing for h and TSX props inference\r\nconst Teleport = TeleportImpl;\n\nconst COMPONENTS = 'components';\r\nconst DIRECTIVES = 'directives';\r\n/**\r\n * @private\r\n */\r\nfunction resolveComponent(name, maybeSelfReference) {\r\n return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;\r\n}\r\nconst NULL_DYNAMIC_COMPONENT = Symbol();\r\n/**\r\n * @private\r\n */\r\nfunction resolveDynamicComponent(component) {\r\n if (isString(component)) {\r\n return resolveAsset(COMPONENTS, component, false) || component;\r\n }\r\n else {\r\n // invalid types will fallthrough to createVNode and raise warning\r\n return (component || NULL_DYNAMIC_COMPONENT);\r\n }\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction resolveDirective(name) {\r\n return resolveAsset(DIRECTIVES, name);\r\n}\r\n// implementation\r\nfunction resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {\r\n const instance = currentRenderingInstance || currentInstance;\r\n if (instance) {\r\n const Component = instance.type;\r\n // explicit self name has highest priority\r\n if (type === COMPONENTS) {\r\n const selfName = getComponentName(Component);\r\n if (selfName &&\r\n (selfName === name ||\r\n selfName === camelize(name) ||\r\n selfName === capitalize(camelize(name)))) {\r\n return Component;\r\n }\r\n }\r\n const res = \r\n // local registration\r\n // check instance[type] first which is resolved for options API\r\n resolve(instance[type] || Component[type], name) ||\r\n // global registration\r\n resolve(instance.appContext[type], name);\r\n if (!res && maybeSelfReference) {\r\n // fallback to implicit self-reference\r\n return Component;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && warnMissing && !res) {\r\n const extra = type === COMPONENTS\r\n ? `\\nIf this is a native custom element, make sure to exclude it from ` +\r\n `component resolution via compilerOptions.isCustomElement.`\r\n : ``;\r\n warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);\r\n }\r\n return res;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`resolve${capitalize(type.slice(0, -1))} ` +\r\n `can only be used in render() or setup().`);\r\n }\r\n}\r\nfunction resolve(registry, name) {\r\n return (registry &&\r\n (registry[name] ||\r\n registry[camelize(name)] ||\r\n registry[capitalize(camelize(name))]));\r\n}\n\nconst Fragment = Symbol((process.env.NODE_ENV !== 'production') ? 'Fragment' : undefined);\r\nconst Text = Symbol((process.env.NODE_ENV !== 'production') ? 'Text' : undefined);\r\nconst Comment = Symbol((process.env.NODE_ENV !== 'production') ? 'Comment' : undefined);\r\nconst Static = Symbol((process.env.NODE_ENV !== 'production') ? 'Static' : undefined);\r\n// Since v-if and v-for are the two possible ways node structure can dynamically\r\n// change, once we consider v-if branches and each v-for fragment a block, we\r\n// can divide a template into nested blocks, and within each block the node\r\n// structure would be stable. This allows us to skip most children diffing\r\n// and only worry about the dynamic nodes (indicated by patch flags).\r\nconst blockStack = [];\r\nlet currentBlock = null;\r\n/**\r\n * Open a block.\r\n * This must be called before `createBlock`. It cannot be part of `createBlock`\r\n * because the children of the block are evaluated before `createBlock` itself\r\n * is called. The generated code typically looks like this:\r\n *\r\n * ```js\r\n * function render() {\r\n * return (openBlock(),createBlock('div', null, [...]))\r\n * }\r\n * ```\r\n * disableTracking is true when creating a v-for fragment block, since a v-for\r\n * fragment always diffs its children.\r\n *\r\n * @private\r\n */\r\nfunction openBlock(disableTracking = false) {\r\n blockStack.push((currentBlock = disableTracking ? null : []));\r\n}\r\nfunction closeBlock() {\r\n blockStack.pop();\r\n currentBlock = blockStack[blockStack.length - 1] || null;\r\n}\r\n// Whether we should be tracking dynamic child nodes inside a block.\r\n// Only tracks when this value is > 0\r\n// We are not using a simple boolean because this value may need to be\r\n// incremented/decremented by nested usage of v-once (see below)\r\nlet isBlockTreeEnabled = 1;\r\n/**\r\n * Block tracking sometimes needs to be disabled, for example during the\r\n * creation of a tree that needs to be cached by v-once. The compiler generates\r\n * code like this:\r\n *\r\n * ``` js\r\n * _cache[1] || (\r\n * setBlockTracking(-1),\r\n * _cache[1] = createVNode(...),\r\n * setBlockTracking(1),\r\n * _cache[1]\r\n * )\r\n * ```\r\n *\r\n * @private\r\n */\r\nfunction setBlockTracking(value) {\r\n isBlockTreeEnabled += value;\r\n}\r\nfunction setupBlock(vnode) {\r\n // save current block children on the block vnode\r\n vnode.dynamicChildren =\r\n isBlockTreeEnabled > 0 ? currentBlock || EMPTY_ARR : null;\r\n // close block\r\n closeBlock();\r\n // a block is always going to be patched, so track it as a child of its\r\n // parent block\r\n if (isBlockTreeEnabled > 0 && currentBlock) {\r\n currentBlock.push(vnode);\r\n }\r\n return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {\r\n return setupBlock(createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, true /* isBlock */));\r\n}\r\n/**\r\n * Create a block root vnode. Takes the same exact arguments as `createVNode`.\r\n * A block root keeps track of dynamic nodes within the block in the\r\n * `dynamicChildren` array.\r\n *\r\n * @private\r\n */\r\nfunction createBlock(type, props, children, patchFlag, dynamicProps) {\r\n return setupBlock(createVNode(type, props, children, patchFlag, dynamicProps, true /* isBlock: prevent a block from tracking itself */));\r\n}\r\nfunction isVNode(value) {\r\n return value ? value.__v_isVNode === true : false;\r\n}\r\nfunction isSameVNodeType(n1, n2) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n n2.shapeFlag & 6 /* COMPONENT */ &&\r\n hmrDirtyComponents.has(n2.type)) {\r\n // HMR only: if the component has been hot-updated, force a reload.\r\n return false;\r\n }\r\n return n1.type === n2.type && n1.key === n2.key;\r\n}\r\nlet vnodeArgsTransformer;\r\n/**\r\n * Internal API for registering an arguments transform for createVNode\r\n * used for creating stubs in the test-utils\r\n * It is *internal* but needs to be exposed for test-utils to pick up proper\r\n * typings\r\n */\r\nfunction transformVNodeArgs(transformer) {\r\n vnodeArgsTransformer = transformer;\r\n}\r\nconst createVNodeWithArgsTransform = (...args) => {\r\n return _createVNode(...(vnodeArgsTransformer\r\n ? vnodeArgsTransformer(args, currentRenderingInstance)\r\n : args));\r\n};\r\nconst InternalObjectKey = `__vInternal`;\r\nconst normalizeKey = ({ key }) => key != null ? key : null;\r\nconst normalizeRef = ({ ref, ref_key, ref_for }) => {\r\n return (ref != null\r\n ? isString(ref) || isRef(ref) || isFunction(ref)\r\n ? { i: currentRenderingInstance, r: ref, k: ref_key, f: !!ref_for }\r\n : ref\r\n : null);\r\n};\r\nfunction createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1 /* ELEMENT */, isBlockNode = false, needFullChildrenNormalization = false) {\r\n const vnode = {\r\n __v_isVNode: true,\r\n __v_skip: true,\r\n type,\r\n props,\r\n key: props && normalizeKey(props),\r\n ref: props && normalizeRef(props),\r\n scopeId: currentScopeId,\r\n slotScopeIds: null,\r\n children,\r\n component: null,\r\n suspense: null,\r\n ssContent: null,\r\n ssFallback: null,\r\n dirs: null,\r\n transition: null,\r\n el: null,\r\n anchor: null,\r\n target: null,\r\n targetAnchor: null,\r\n staticCount: 0,\r\n shapeFlag,\r\n patchFlag,\r\n dynamicProps,\r\n dynamicChildren: null,\r\n appContext: null\r\n };\r\n if (needFullChildrenNormalization) {\r\n normalizeChildren(vnode, children);\r\n // normalize suspense children\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n type.normalize(vnode);\r\n }\r\n }\r\n else if (children) {\r\n // compiled element vnode - if children is passed, only possible types are\r\n // string or Array.\r\n vnode.shapeFlag |= isString(children)\r\n ? 8 /* TEXT_CHILDREN */\r\n : 16 /* ARRAY_CHILDREN */;\r\n }\r\n // validate key\r\n if ((process.env.NODE_ENV !== 'production') && vnode.key !== vnode.key) {\r\n warn(`VNode created with invalid key (NaN). VNode type:`, vnode.type);\r\n }\r\n // track vnode for block tree\r\n if (isBlockTreeEnabled > 0 &&\r\n // avoid a block node from tracking itself\r\n !isBlockNode &&\r\n // has current parent block\r\n currentBlock &&\r\n // presence of a patch flag indicates this node needs patching on updates.\r\n // component nodes also should always be patched, because even if the\r\n // component doesn't need to update, it needs to persist the instance on to\r\n // the next vnode so that it can be properly unmounted later.\r\n (vnode.patchFlag > 0 || shapeFlag & 6 /* COMPONENT */) &&\r\n // the EVENTS flag is only for hydration and if it is the only flag, the\r\n // vnode should not be considered dynamic due to handler caching.\r\n vnode.patchFlag !== 32 /* HYDRATE_EVENTS */) {\r\n currentBlock.push(vnode);\r\n }\r\n return vnode;\r\n}\r\nconst createVNode = ((process.env.NODE_ENV !== 'production') ? createVNodeWithArgsTransform : _createVNode);\r\nfunction _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {\r\n if (!type || type === NULL_DYNAMIC_COMPONENT) {\r\n if ((process.env.NODE_ENV !== 'production') && !type) {\r\n warn(`Invalid vnode type when creating vnode: ${type}.`);\r\n }\r\n type = Comment;\r\n }\r\n if (isVNode(type)) {\r\n // createVNode receiving an existing vnode. This happens in cases like\r\n // <component :is=\"vnode\"/>\r\n // #2078 make sure to merge refs during the clone instead of overwriting it\r\n const cloned = cloneVNode(type, props, true /* mergeRef: true */);\r\n if (children) {\r\n normalizeChildren(cloned, children);\r\n }\r\n return cloned;\r\n }\r\n // class component normalization.\r\n if (isClassComponent(type)) {\r\n type = type.__vccOpts;\r\n }\r\n // class & style normalization.\r\n if (props) {\r\n // for reactive or proxy objects, we need to clone it to enable mutation.\r\n props = guardReactiveProps(props);\r\n let { class: klass, style } = props;\r\n if (klass && !isString(klass)) {\r\n props.class = normalizeClass(klass);\r\n }\r\n if (isObject(style)) {\r\n // reactive state objects need to be cloned since they are likely to be\r\n // mutated\r\n if (isProxy(style) && !isArray(style)) {\r\n style = extend({}, style);\r\n }\r\n props.style = normalizeStyle(style);\r\n }\r\n }\r\n // encode the vnode type information into a bitmap\r\n const shapeFlag = isString(type)\r\n ? 1 /* ELEMENT */\r\n : isSuspense(type)\r\n ? 128 /* SUSPENSE */\r\n : isTeleport(type)\r\n ? 64 /* TELEPORT */\r\n : isObject(type)\r\n ? 4 /* STATEFUL_COMPONENT */\r\n : isFunction(type)\r\n ? 2 /* FUNCTIONAL_COMPONENT */\r\n : 0;\r\n if ((process.env.NODE_ENV !== 'production') && shapeFlag & 4 /* STATEFUL_COMPONENT */ && isProxy(type)) {\r\n type = toRaw(type);\r\n warn(`Vue received a Component which was made a reactive object. This can ` +\r\n `lead to unnecessary performance overhead, and should be avoided by ` +\r\n `marking the component with \\`markRaw\\` or using \\`shallowRef\\` ` +\r\n `instead of \\`ref\\`.`, `\\nComponent that was made reactive: `, type);\r\n }\r\n return createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, isBlockNode, true);\r\n}\r\nfunction guardReactiveProps(props) {\r\n if (!props)\r\n return null;\r\n return isProxy(props) || InternalObjectKey in props\r\n ? extend({}, props)\r\n : props;\r\n}\r\nfunction cloneVNode(vnode, extraProps, mergeRef = false) {\r\n // This is intentionally NOT using spread or extend to avoid the runtime\r\n // key enumeration cost.\r\n const { props, ref, patchFlag, children } = vnode;\r\n const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;\r\n const cloned = {\r\n __v_isVNode: true,\r\n __v_skip: true,\r\n type: vnode.type,\r\n props: mergedProps,\r\n key: mergedProps && normalizeKey(mergedProps),\r\n ref: extraProps && extraProps.ref\r\n ? // #2078 in the case of <component :is=\"vnode\" ref=\"extra\"/>\r\n // if the vnode itself already has a ref, cloneVNode will need to merge\r\n // the refs so the single vnode can be set on multiple refs\r\n mergeRef && ref\r\n ? isArray(ref)\r\n ? ref.concat(normalizeRef(extraProps))\r\n : [ref, normalizeRef(extraProps)]\r\n : normalizeRef(extraProps)\r\n : ref,\r\n scopeId: vnode.scopeId,\r\n slotScopeIds: vnode.slotScopeIds,\r\n children: (process.env.NODE_ENV !== 'production') && patchFlag === -1 /* HOISTED */ && isArray(children)\r\n ? children.map(deepCloneVNode)\r\n : children,\r\n target: vnode.target,\r\n targetAnchor: vnode.targetAnchor,\r\n staticCount: vnode.staticCount,\r\n shapeFlag: vnode.shapeFlag,\r\n // if the vnode is cloned with extra props, we can no longer assume its\r\n // existing patch flag to be reliable and need to add the FULL_PROPS flag.\r\n // note: perserve flag for fragments since they use the flag for children\r\n // fast paths only.\r\n patchFlag: extraProps && vnode.type !== Fragment\r\n ? patchFlag === -1 // hoisted node\r\n ? 16 /* FULL_PROPS */\r\n : patchFlag | 16 /* FULL_PROPS */\r\n : patchFlag,\r\n dynamicProps: vnode.dynamicProps,\r\n dynamicChildren: vnode.dynamicChildren,\r\n appContext: vnode.appContext,\r\n dirs: vnode.dirs,\r\n transition: vnode.transition,\r\n // These should technically only be non-null on mounted VNodes. However,\r\n // they *should* be copied for kept-alive vnodes. So we just always copy\r\n // them since them being non-null during a mount doesn't affect the logic as\r\n // they will simply be overwritten.\r\n component: vnode.component,\r\n suspense: vnode.suspense,\r\n ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),\r\n ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),\r\n el: vnode.el,\r\n anchor: vnode.anchor\r\n };\r\n return cloned;\r\n}\r\n/**\r\n * Dev only, for HMR of hoisted vnodes reused in v-for\r\n * https://github.com/vitejs/vite/issues/2022\r\n */\r\nfunction deepCloneVNode(vnode) {\r\n const cloned = cloneVNode(vnode);\r\n if (isArray(vnode.children)) {\r\n cloned.children = vnode.children.map(deepCloneVNode);\r\n }\r\n return cloned;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createTextVNode(text = ' ', flag = 0) {\r\n return createVNode(Text, null, text, flag);\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createStaticVNode(content, numberOfNodes) {\r\n // A static vnode can contain multiple stringified elements, and the number\r\n // of elements is necessary for hydration.\r\n const vnode = createVNode(Static, null, content);\r\n vnode.staticCount = numberOfNodes;\r\n return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createCommentVNode(text = '', \r\n// when used as the v-else branch, the comment node must be created as a\r\n// block to ensure correct updates.\r\nasBlock = false) {\r\n return asBlock\r\n ? (openBlock(), createBlock(Comment, null, text))\r\n : createVNode(Comment, null, text);\r\n}\r\nfunction normalizeVNode(child) {\r\n if (child == null || typeof child === 'boolean') {\r\n // empty placeholder\r\n return createVNode(Comment);\r\n }\r\n else if (isArray(child)) {\r\n // fragment\r\n return createVNode(Fragment, null, \r\n // #3666, avoid reference pollution when reusing vnode\r\n child.slice());\r\n }\r\n else if (typeof child === 'object') {\r\n // already vnode, this should be the most common since compiled templates\r\n // always produce all-vnode children arrays\r\n return cloneIfMounted(child);\r\n }\r\n else {\r\n // strings and numbers\r\n return createVNode(Text, null, String(child));\r\n }\r\n}\r\n// optimized normalization for template-compiled render fns\r\nfunction cloneIfMounted(child) {\r\n return child.el === null || child.memo ? child : cloneVNode(child);\r\n}\r\nfunction normalizeChildren(vnode, children) {\r\n let type = 0;\r\n const { shapeFlag } = vnode;\r\n if (children == null) {\r\n children = null;\r\n }\r\n else if (isArray(children)) {\r\n type = 16 /* ARRAY_CHILDREN */;\r\n }\r\n else if (typeof children === 'object') {\r\n if (shapeFlag & (1 /* ELEMENT */ | 64 /* TELEPORT */)) {\r\n // Normalize slot to plain children for plain element and Teleport\r\n const slot = children.default;\r\n if (slot) {\r\n // _c marker is added by withCtx() indicating this is a compiled slot\r\n slot._c && (slot._d = false);\r\n normalizeChildren(vnode, slot());\r\n slot._c && (slot._d = true);\r\n }\r\n return;\r\n }\r\n else {\r\n type = 32 /* SLOTS_CHILDREN */;\r\n const slotFlag = children._;\r\n if (!slotFlag && !(InternalObjectKey in children)) {\r\n children._ctx = currentRenderingInstance;\r\n }\r\n else if (slotFlag === 3 /* FORWARDED */ && currentRenderingInstance) {\r\n // a child component receives forwarded slots from the parent.\r\n // its slot type is determined by its parent's slot type.\r\n if (currentRenderingInstance.slots._ === 1 /* STABLE */) {\r\n children._ = 1 /* STABLE */;\r\n }\r\n else {\r\n children._ = 2 /* DYNAMIC */;\r\n vnode.patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n }\r\n }\r\n }\r\n }\r\n else if (isFunction(children)) {\r\n children = { default: children, _ctx: currentRenderingInstance };\r\n type = 32 /* SLOTS_CHILDREN */;\r\n }\r\n else {\r\n children = String(children);\r\n // force teleport children to array so it can be moved around\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n type = 16 /* ARRAY_CHILDREN */;\r\n children = [createTextVNode(children)];\r\n }\r\n else {\r\n type = 8 /* TEXT_CHILDREN */;\r\n }\r\n }\r\n vnode.children = children;\r\n vnode.shapeFlag |= type;\r\n}\r\nfunction mergeProps(...args) {\r\n const ret = {};\r\n for (let i = 0; i < args.length; i++) {\r\n const toMerge = args[i];\r\n for (const key in toMerge) {\r\n if (key === 'class') {\r\n if (ret.class !== toMerge.class) {\r\n ret.class = normalizeClass([ret.class, toMerge.class]);\r\n }\r\n }\r\n else if (key === 'style') {\r\n ret.style = normalizeStyle([ret.style, toMerge.style]);\r\n }\r\n else if (isOn(key)) {\r\n const existing = ret[key];\r\n const incoming = toMerge[key];\r\n if (existing !== incoming &&\r\n !(isArray(existing) && existing.includes(incoming))) {\r\n ret[key] = existing\r\n ? [].concat(existing, incoming)\r\n : incoming;\r\n }\r\n }\r\n else if (key !== '') {\r\n ret[key] = toMerge[key];\r\n }\r\n }\r\n }\r\n return ret;\r\n}\r\nfunction invokeVNodeHook(hook, instance, vnode, prevVNode = null) {\r\n callWithAsyncErrorHandling(hook, instance, 7 /* VNODE_HOOK */, [\r\n vnode,\r\n prevVNode\r\n ]);\r\n}\n\n/**\r\n * Actual implementation\r\n */\r\nfunction renderList(source, renderItem, cache, index) {\r\n let ret;\r\n const cached = (cache && cache[index]);\r\n if (isArray(source) || isString(source)) {\r\n ret = new Array(source.length);\r\n for (let i = 0, l = source.length; i < l; i++) {\r\n ret[i] = renderItem(source[i], i, undefined, cached && cached[i]);\r\n }\r\n }\r\n else if (typeof source === 'number') {\r\n if ((process.env.NODE_ENV !== 'production') && !Number.isInteger(source)) {\r\n warn(`The v-for range expect an integer value but got ${source}.`);\r\n return [];\r\n }\r\n ret = new Array(source);\r\n for (let i = 0; i < source; i++) {\r\n ret[i] = renderItem(i + 1, i, undefined, cached && cached[i]);\r\n }\r\n }\r\n else if (isObject(source)) {\r\n if (source[Symbol.iterator]) {\r\n ret = Array.from(source, (item, i) => renderItem(item, i, undefined, cached && cached[i]));\r\n }\r\n else {\r\n const keys = Object.keys(source);\r\n ret = new Array(keys.length);\r\n for (let i = 0, l = keys.length; i < l; i++) {\r\n const key = keys[i];\r\n ret[i] = renderItem(source[key], key, i, cached && cached[i]);\r\n }\r\n }\r\n }\r\n else {\r\n ret = [];\r\n }\r\n if (cache) {\r\n cache[index] = ret;\r\n }\r\n return ret;\r\n}\n\n/**\r\n * Compiler runtime helper for creating dynamic slots object\r\n * @private\r\n */\r\nfunction createSlots(slots, dynamicSlots) {\r\n for (let i = 0; i < dynamicSlots.length; i++) {\r\n const slot = dynamicSlots[i];\r\n // array of dynamic slot generated by <template v-for=\"...\" #[...]>\r\n if (isArray(slot)) {\r\n for (let j = 0; j < slot.length; j++) {\r\n slots[slot[j].name] = slot[j].fn;\r\n }\r\n }\r\n else if (slot) {\r\n // conditional single slot generated by <template v-if=\"...\" #foo>\r\n slots[slot.name] = slot.fn;\r\n }\r\n }\r\n return slots;\r\n}\n\n/**\r\n * Compiler runtime helper for rendering `<slot/>`\r\n * @private\r\n */\r\nfunction renderSlot(slots, name, props = {}, \r\n// this is not a user-facing function, so the fallback is always generated by\r\n// the compiler and guaranteed to be a function returning an array\r\nfallback, noSlotted) {\r\n if (currentRenderingInstance.isCE) {\r\n return createVNode('slot', name === 'default' ? null : { name }, fallback && fallback());\r\n }\r\n let slot = slots[name];\r\n if ((process.env.NODE_ENV !== 'production') && slot && slot.length > 1) {\r\n warn(`SSR-optimized slot function detected in a non-SSR-optimized render ` +\r\n `function. You need to mark this component with $dynamic-slots in the ` +\r\n `parent template.`);\r\n slot = () => [];\r\n }\r\n // a compiled slot disables block tracking by default to avoid manual\r\n // invocation interfering with template-based block tracking, but in\r\n // `renderSlot` we can be sure that it's template-based so we can force\r\n // enable it.\r\n if (slot && slot._c) {\r\n slot._d = false;\r\n }\r\n openBlock();\r\n const validSlotContent = slot && ensureValidVNode(slot(props));\r\n const rendered = createBlock(Fragment, { key: props.key || `_${name}` }, validSlotContent || (fallback ? fallback() : []), validSlotContent && slots._ === 1 /* STABLE */\r\n ? 64 /* STABLE_FRAGMENT */\r\n : -2 /* BAIL */);\r\n if (!noSlotted && rendered.scopeId) {\r\n rendered.slotScopeIds = [rendered.scopeId + '-s'];\r\n }\r\n if (slot && slot._c) {\r\n slot._d = true;\r\n }\r\n return rendered;\r\n}\r\nfunction ensureValidVNode(vnodes) {\r\n return vnodes.some(child => {\r\n if (!isVNode(child))\r\n return true;\r\n if (child.type === Comment)\r\n return false;\r\n if (child.type === Fragment &&\r\n !ensureValidVNode(child.children))\r\n return false;\r\n return true;\r\n })\r\n ? vnodes\r\n : null;\r\n}\n\n/**\r\n * For prefixing keys in v-on=\"obj\" with \"on\"\r\n * @private\r\n */\r\nfunction toHandlers(obj) {\r\n const ret = {};\r\n if ((process.env.NODE_ENV !== 'production') && !isObject(obj)) {\r\n warn(`v-on with no argument expects an object value.`);\r\n return ret;\r\n }\r\n for (const key in obj) {\r\n ret[toHandlerKey(key)] = obj[key];\r\n }\r\n return ret;\r\n}\n\n/**\r\n * #2437 In Vue 3, functional components do not have a public instance proxy but\r\n * they exist in the internal parent chain. For code that relies on traversing\r\n * public $parent chains, skip functional ones and go to the parent instead.\r\n */\r\nconst getPublicInstance = (i) => {\r\n if (!i)\r\n return null;\r\n if (isStatefulComponent(i))\r\n return getExposeProxy(i) || i.proxy;\r\n return getPublicInstance(i.parent);\r\n};\r\nconst publicPropertiesMap = extend(Object.create(null), {\r\n $: i => i,\r\n $el: i => i.vnode.el,\r\n $data: i => i.data,\r\n $props: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.props) : i.props),\r\n $attrs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.attrs) : i.attrs),\r\n $slots: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.slots) : i.slots),\r\n $refs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.refs) : i.refs),\r\n $parent: i => getPublicInstance(i.parent),\r\n $root: i => getPublicInstance(i.root),\r\n $emit: i => i.emit,\r\n $options: i => (__VUE_OPTIONS_API__ ? resolveMergedOptions(i) : i.type),\r\n $forceUpdate: i => () => queueJob(i.update),\r\n $nextTick: i => nextTick.bind(i.proxy),\r\n $watch: i => (__VUE_OPTIONS_API__ ? instanceWatch.bind(i) : NOOP)\r\n});\r\nconst PublicInstanceProxyHandlers = {\r\n get({ _: instance }, key) {\r\n const { ctx, setupState, data, props, accessCache, type, appContext } = instance;\r\n // for internal formatters to know that this is a Vue instance\r\n if ((process.env.NODE_ENV !== 'production') && key === '__isVue') {\r\n return true;\r\n }\r\n // prioritize <script setup> bindings during dev.\r\n // this allows even properties that start with _ or $ to be used - so that\r\n // it aligns with the production behavior where the render fn is inlined and\r\n // indeed has access to all declared variables.\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n setupState !== EMPTY_OBJ &&\r\n setupState.__isScriptSetup &&\r\n hasOwn(setupState, key)) {\r\n return setupState[key];\r\n }\r\n // data / props / ctx\r\n // This getter gets called for every property access on the render context\r\n // during render and is a major hotspot. The most expensive part of this\r\n // is the multiple hasOwn() calls. It's much faster to do a simple property\r\n // access on a plain object, so we use an accessCache object (with null\r\n // prototype) to memoize what access type a key corresponds to.\r\n let normalizedProps;\r\n if (key[0] !== '$') {\r\n const n = accessCache[key];\r\n if (n !== undefined) {\r\n switch (n) {\r\n case 1 /* SETUP */:\r\n return setupState[key];\r\n case 2 /* DATA */:\r\n return data[key];\r\n case 4 /* CONTEXT */:\r\n return ctx[key];\r\n case 3 /* PROPS */:\r\n return props[key];\r\n // default: just fallthrough\r\n }\r\n }\r\n else if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n accessCache[key] = 1 /* SETUP */;\r\n return setupState[key];\r\n }\r\n else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n accessCache[key] = 2 /* DATA */;\r\n return data[key];\r\n }\r\n else if (\r\n // only cache other properties when instance has declared (thus stable)\r\n // props\r\n (normalizedProps = instance.propsOptions[0]) &&\r\n hasOwn(normalizedProps, key)) {\r\n accessCache[key] = 3 /* PROPS */;\r\n return props[key];\r\n }\r\n else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n accessCache[key] = 4 /* CONTEXT */;\r\n return ctx[key];\r\n }\r\n else if (!__VUE_OPTIONS_API__ || shouldCacheAccess) {\r\n accessCache[key] = 0 /* OTHER */;\r\n }\r\n }\r\n const publicGetter = publicPropertiesMap[key];\r\n let cssModule, globalProperties;\r\n // public $xxx properties\r\n if (publicGetter) {\r\n if (key === '$attrs') {\r\n track(instance, \"get\" /* GET */, key);\r\n (process.env.NODE_ENV !== 'production') && markAttrsAccessed();\r\n }\r\n return publicGetter(instance);\r\n }\r\n else if (\r\n // css module (injected by vue-loader)\r\n (cssModule = type.__cssModules) &&\r\n (cssModule = cssModule[key])) {\r\n return cssModule;\r\n }\r\n else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n // user may set custom properties to `this` that start with `$`\r\n accessCache[key] = 4 /* CONTEXT */;\r\n return ctx[key];\r\n }\r\n else if (\r\n // global properties\r\n ((globalProperties = appContext.config.globalProperties),\r\n hasOwn(globalProperties, key))) {\r\n {\r\n return globalProperties[key];\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') &&\r\n currentRenderingInstance &&\r\n (!isString(key) ||\r\n // #1091 avoid internal isRef/isVNode checks on component instance leading\r\n // to infinite warning loop\r\n key.indexOf('__v') !== 0)) {\r\n if (data !== EMPTY_OBJ &&\r\n (key[0] === '$' || key[0] === '_') &&\r\n hasOwn(data, key)) {\r\n warn(`Property ${JSON.stringify(key)} must be accessed via $data because it starts with a reserved ` +\r\n `character (\"$\" or \"_\") and is not proxied on the render context.`);\r\n }\r\n else if (instance === currentRenderingInstance) {\r\n warn(`Property ${JSON.stringify(key)} was accessed during render ` +\r\n `but is not defined on instance.`);\r\n }\r\n }\r\n },\r\n set({ _: instance }, key, value) {\r\n const { data, setupState, ctx } = instance;\r\n if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n setupState[key] = value;\r\n }\r\n else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n data[key] = value;\r\n }\r\n else if (hasOwn(instance.props, key)) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to mutate prop \"${key}\". Props are readonly.`, instance);\r\n return false;\r\n }\r\n if (key[0] === '$' && key.slice(1) in instance) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to mutate public property \"${key}\". ` +\r\n `Properties starting with $ are reserved and readonly.`, instance);\r\n return false;\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && key in instance.appContext.config.globalProperties) {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n value\r\n });\r\n }\r\n else {\r\n ctx[key] = value;\r\n }\r\n }\r\n return true;\r\n },\r\n has({ _: { data, setupState, accessCache, ctx, appContext, propsOptions } }, key) {\r\n let normalizedProps;\r\n return (!!accessCache[key] ||\r\n (data !== EMPTY_OBJ && hasOwn(data, key)) ||\r\n (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) ||\r\n ((normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key)) ||\r\n hasOwn(ctx, key) ||\r\n hasOwn(publicPropertiesMap, key) ||\r\n hasOwn(appContext.config.globalProperties, key));\r\n }\r\n};\r\nif ((process.env.NODE_ENV !== 'production') && !false) {\r\n PublicInstanceProxyHandlers.ownKeys = (target) => {\r\n warn(`Avoid app logic that relies on enumerating keys on a component instance. ` +\r\n `The keys will be empty in production mode to avoid performance overhead.`);\r\n return Reflect.ownKeys(target);\r\n };\r\n}\r\nconst RuntimeCompiledPublicInstanceProxyHandlers = /*#__PURE__*/ extend({}, PublicInstanceProxyHandlers, {\r\n get(target, key) {\r\n // fast path for unscopables when using `with` block\r\n if (key === Symbol.unscopables) {\r\n return;\r\n }\r\n return PublicInstanceProxyHandlers.get(target, key, target);\r\n },\r\n has(_, key) {\r\n const has = key[0] !== '_' && !isGloballyWhitelisted(key);\r\n if ((process.env.NODE_ENV !== 'production') && !has && PublicInstanceProxyHandlers.has(_, key)) {\r\n warn(`Property ${JSON.stringify(key)} should not start with _ which is a reserved prefix for Vue internals.`);\r\n }\r\n return has;\r\n }\r\n});\r\n// dev only\r\n// In dev mode, the proxy target exposes the same properties as seen on `this`\r\n// for easier console inspection. In prod mode it will be an empty object so\r\n// these properties definitions can be skipped.\r\nfunction createDevRenderContext(instance) {\r\n const target = {};\r\n // expose internal instance for proxy handlers\r\n Object.defineProperty(target, `_`, {\r\n configurable: true,\r\n enumerable: false,\r\n get: () => instance\r\n });\r\n // expose public properties\r\n Object.keys(publicPropertiesMap).forEach(key => {\r\n Object.defineProperty(target, key, {\r\n configurable: true,\r\n enumerable: false,\r\n get: () => publicPropertiesMap[key](instance),\r\n // intercepted by the proxy so no need for implementation,\r\n // but needed to prevent set errors\r\n set: NOOP\r\n });\r\n });\r\n return target;\r\n}\r\n// dev only\r\nfunction exposePropsOnRenderContext(instance) {\r\n const { ctx, propsOptions: [propsOptions] } = instance;\r\n if (propsOptions) {\r\n Object.keys(propsOptions).forEach(key => {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => instance.props[key],\r\n set: NOOP\r\n });\r\n });\r\n }\r\n}\r\n// dev only\r\nfunction exposeSetupStateOnRenderContext(instance) {\r\n const { ctx, setupState } = instance;\r\n Object.keys(toRaw(setupState)).forEach(key => {\r\n if (!setupState.__isScriptSetup) {\r\n if (key[0] === '$' || key[0] === '_') {\r\n warn(`setup() return property ${JSON.stringify(key)} should not start with \"$\" or \"_\" ` +\r\n `which are reserved prefixes for Vue internals.`);\r\n return;\r\n }\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => setupState[key],\r\n set: NOOP\r\n });\r\n }\r\n });\r\n}\n\nconst emptyAppContext = createAppContext();\r\nlet uid$1 = 0;\r\nfunction createComponentInstance(vnode, parent, suspense) {\r\n const type = vnode.type;\r\n // inherit parent app context - or - if root, adopt from root vnode\r\n const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;\r\n const instance = {\r\n uid: uid$1++,\r\n vnode,\r\n type,\r\n parent,\r\n appContext,\r\n root: null,\r\n next: null,\r\n subTree: null,\r\n effect: null,\r\n update: null,\r\n scope: new EffectScope(true /* detached */),\r\n render: null,\r\n proxy: null,\r\n exposed: null,\r\n exposeProxy: null,\r\n withProxy: null,\r\n provides: parent ? parent.provides : Object.create(appContext.provides),\r\n accessCache: null,\r\n renderCache: [],\r\n // local resovled assets\r\n components: null,\r\n directives: null,\r\n // resolved props and emits options\r\n propsOptions: normalizePropsOptions(type, appContext),\r\n emitsOptions: normalizeEmitsOptions(type, appContext),\r\n // emit\r\n emit: null,\r\n emitted: null,\r\n // props default value\r\n propsDefaults: EMPTY_OBJ,\r\n // inheritAttrs\r\n inheritAttrs: type.inheritAttrs,\r\n // state\r\n ctx: EMPTY_OBJ,\r\n data: EMPTY_OBJ,\r\n props: EMPTY_OBJ,\r\n attrs: EMPTY_OBJ,\r\n slots: EMPTY_OBJ,\r\n refs: EMPTY_OBJ,\r\n setupState: EMPTY_OBJ,\r\n setupContext: null,\r\n // suspense related\r\n suspense,\r\n suspenseId: suspense ? suspense.pendingId : 0,\r\n asyncDep: null,\r\n asyncResolved: false,\r\n // lifecycle hooks\r\n // not using enums here because it results in computed properties\r\n isMounted: false,\r\n isUnmounted: false,\r\n isDeactivated: false,\r\n bc: null,\r\n c: null,\r\n bm: null,\r\n m: null,\r\n bu: null,\r\n u: null,\r\n um: null,\r\n bum: null,\r\n da: null,\r\n a: null,\r\n rtg: null,\r\n rtc: null,\r\n ec: null,\r\n sp: null\r\n };\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n instance.ctx = createDevRenderContext(instance);\r\n }\r\n else {\r\n instance.ctx = { _: instance };\r\n }\r\n instance.root = parent ? parent.root : instance;\r\n instance.emit = emit$1.bind(null, instance);\r\n // apply custom element special handling\r\n if (vnode.ce) {\r\n vnode.ce(instance);\r\n }\r\n return instance;\r\n}\r\nlet currentInstance = null;\r\nconst getCurrentInstance = () => currentInstance || currentRenderingInstance;\r\nconst setCurrentInstance = (instance) => {\r\n currentInstance = instance;\r\n instance.scope.on();\r\n};\r\nconst unsetCurrentInstance = () => {\r\n currentInstance && currentInstance.scope.off();\r\n currentInstance = null;\r\n};\r\nconst isBuiltInTag = /*#__PURE__*/ makeMap('slot,component');\r\nfunction validateComponentName(name, config) {\r\n const appIsNativeTag = config.isNativeTag || NO;\r\n if (isBuiltInTag(name) || appIsNativeTag(name)) {\r\n warn('Do not use built-in or reserved HTML elements as component id: ' + name);\r\n }\r\n}\r\nfunction isStatefulComponent(instance) {\r\n return instance.vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */;\r\n}\r\nlet isInSSRComponentSetup = false;\r\nfunction setupComponent(instance, isSSR = false) {\r\n isInSSRComponentSetup = isSSR;\r\n const { props, children } = instance.vnode;\r\n const isStateful = isStatefulComponent(instance);\r\n initProps(instance, props, isStateful, isSSR);\r\n initSlots(instance, children);\r\n const setupResult = isStateful\r\n ? setupStatefulComponent(instance, isSSR)\r\n : undefined;\r\n isInSSRComponentSetup = false;\r\n return setupResult;\r\n}\r\nfunction setupStatefulComponent(instance, isSSR) {\r\n const Component = instance.type;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (Component.name) {\r\n validateComponentName(Component.name, instance.appContext.config);\r\n }\r\n if (Component.components) {\r\n const names = Object.keys(Component.components);\r\n for (let i = 0; i < names.length; i++) {\r\n validateComponentName(names[i], instance.appContext.config);\r\n }\r\n }\r\n if (Component.directives) {\r\n const names = Object.keys(Component.directives);\r\n for (let i = 0; i < names.length; i++) {\r\n validateDirectiveName(names[i]);\r\n }\r\n }\r\n if (Component.compilerOptions && isRuntimeOnly()) {\r\n warn(`\"compilerOptions\" is only supported when using a build of Vue that ` +\r\n `includes the runtime compiler. Since you are using a runtime-only ` +\r\n `build, the options should be passed via your build tool config instead.`);\r\n }\r\n }\r\n // 0. create render proxy property access cache\r\n instance.accessCache = Object.create(null);\r\n // 1. create public instance / render proxy\r\n // also mark it raw so it's never observed\r\n instance.proxy = markRaw(new Proxy(instance.ctx, PublicInstanceProxyHandlers));\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n exposePropsOnRenderContext(instance);\r\n }\r\n // 2. call setup()\r\n const { setup } = Component;\r\n if (setup) {\r\n const setupContext = (instance.setupContext =\r\n setup.length > 1 ? createSetupContext(instance) : null);\r\n setCurrentInstance(instance);\r\n pauseTracking();\r\n const setupResult = callWithErrorHandling(setup, instance, 0 /* SETUP_FUNCTION */, [(process.env.NODE_ENV !== 'production') ? shallowReadonly(instance.props) : instance.props, setupContext]);\r\n resetTracking();\r\n unsetCurrentInstance();\r\n if (isPromise(setupResult)) {\r\n setupResult.then(unsetCurrentInstance, unsetCurrentInstance);\r\n if (isSSR) {\r\n // return the promise so server-renderer can wait on it\r\n return setupResult\r\n .then((resolvedResult) => {\r\n handleSetupResult(instance, resolvedResult, isSSR);\r\n })\r\n .catch(e => {\r\n handleError(e, instance, 0 /* SETUP_FUNCTION */);\r\n });\r\n }\r\n else {\r\n // async setup returned Promise.\r\n // bail here and wait for re-entry.\r\n instance.asyncDep = setupResult;\r\n }\r\n }\r\n else {\r\n handleSetupResult(instance, setupResult, isSSR);\r\n }\r\n }\r\n else {\r\n finishComponentSetup(instance, isSSR);\r\n }\r\n}\r\nfunction handleSetupResult(instance, setupResult, isSSR) {\r\n if (isFunction(setupResult)) {\r\n // setup returned an inline render function\r\n if (instance.type.__ssrInlineRender) {\r\n // when the function's name is `ssrRender` (compiled by SFC inline mode),\r\n // set it as ssrRender instead.\r\n instance.ssrRender = setupResult;\r\n }\r\n else {\r\n instance.render = setupResult;\r\n }\r\n }\r\n else if (isObject(setupResult)) {\r\n if ((process.env.NODE_ENV !== 'production') && isVNode(setupResult)) {\r\n warn(`setup() should not return VNodes directly - ` +\r\n `return a render function instead.`);\r\n }\r\n // setup returned bindings.\r\n // assuming a render function compiled from template is present.\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n instance.devtoolsRawSetupState = setupResult;\r\n }\r\n instance.setupState = proxyRefs(setupResult);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n exposeSetupStateOnRenderContext(instance);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && setupResult !== undefined) {\r\n warn(`setup() should return an object. Received: ${setupResult === null ? 'null' : typeof setupResult}`);\r\n }\r\n finishComponentSetup(instance, isSSR);\r\n}\r\nlet compile;\r\nlet installWithProxy;\r\n/**\r\n * For runtime-dom to register the compiler.\r\n * Note the exported method uses any to avoid d.ts relying on the compiler types.\r\n */\r\nfunction registerRuntimeCompiler(_compile) {\r\n compile = _compile;\r\n installWithProxy = i => {\r\n if (i.render._rc) {\r\n i.withProxy = new Proxy(i.ctx, RuntimeCompiledPublicInstanceProxyHandlers);\r\n }\r\n };\r\n}\r\n// dev only\r\nconst isRuntimeOnly = () => !compile;\r\nfunction finishComponentSetup(instance, isSSR, skipOptions) {\r\n const Component = instance.type;\r\n // template / render function normalization\r\n // could be already set when returned from setup()\r\n if (!instance.render) {\r\n // only do on-the-fly compile if not in SSR - SSR on-the-fly compliation\r\n // is done by server-renderer\r\n if (!isSSR && compile && !Component.render) {\r\n const template = Component.template;\r\n if (template) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `compile`);\r\n }\r\n const { isCustomElement, compilerOptions } = instance.appContext.config;\r\n const { delimiters, compilerOptions: componentCompilerOptions } = Component;\r\n const finalCompilerOptions = extend(extend({\r\n isCustomElement,\r\n delimiters\r\n }, compilerOptions), componentCompilerOptions);\r\n Component.render = compile(template, finalCompilerOptions);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `compile`);\r\n }\r\n }\r\n }\r\n instance.render = (Component.render || NOOP);\r\n // for runtime-compiled render functions using `with` blocks, the render\r\n // proxy used needs a different `has` handler which is more performant and\r\n // also only allows a whitelist of globals to fallthrough.\r\n if (installWithProxy) {\r\n installWithProxy(instance);\r\n }\r\n }\r\n // support for 2.x options\r\n if (__VUE_OPTIONS_API__ && !(false )) {\r\n setCurrentInstance(instance);\r\n pauseTracking();\r\n applyOptions(instance);\r\n resetTracking();\r\n unsetCurrentInstance();\r\n }\r\n // warn missing template/render\r\n // the runtime compilation of template in SSR is done by server-render\r\n if ((process.env.NODE_ENV !== 'production') && !Component.render && instance.render === NOOP && !isSSR) {\r\n /* istanbul ignore if */\r\n if (!compile && Component.template) {\r\n warn(`Component provided template option but ` +\r\n `runtime compilation is not supported in this build of Vue.` +\r\n (` Configure your bundler to alias \"vue\" to \"vue/dist/vue.esm-bundler.js\".`\r\n ) /* should not happen */);\r\n }\r\n else {\r\n warn(`Component is missing template or render function.`);\r\n }\r\n }\r\n}\r\nfunction createAttrsProxy(instance) {\r\n return new Proxy(instance.attrs, (process.env.NODE_ENV !== 'production')\r\n ? {\r\n get(target, key) {\r\n markAttrsAccessed();\r\n track(instance, \"get\" /* GET */, '$attrs');\r\n return target[key];\r\n },\r\n set() {\r\n warn(`setupContext.attrs is readonly.`);\r\n return false;\r\n },\r\n deleteProperty() {\r\n warn(`setupContext.attrs is readonly.`);\r\n return false;\r\n }\r\n }\r\n : {\r\n get(target, key) {\r\n track(instance, \"get\" /* GET */, '$attrs');\r\n return target[key];\r\n }\r\n });\r\n}\r\nfunction createSetupContext(instance) {\r\n const expose = exposed => {\r\n if ((process.env.NODE_ENV !== 'production') && instance.exposed) {\r\n warn(`expose() should be called only once per setup().`);\r\n }\r\n instance.exposed = exposed || {};\r\n };\r\n let attrs;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n // We use getters in dev in case libs like test-utils overwrite instance\r\n // properties (overwrites should not be done in prod)\r\n return Object.freeze({\r\n get attrs() {\r\n return attrs || (attrs = createAttrsProxy(instance));\r\n },\r\n get slots() {\r\n return shallowReadonly(instance.slots);\r\n },\r\n get emit() {\r\n return (event, ...args) => instance.emit(event, ...args);\r\n },\r\n expose\r\n });\r\n }\r\n else {\r\n return {\r\n get attrs() {\r\n return attrs || (attrs = createAttrsProxy(instance));\r\n },\r\n slots: instance.slots,\r\n emit: instance.emit,\r\n expose\r\n };\r\n }\r\n}\r\nfunction getExposeProxy(instance) {\r\n if (instance.exposed) {\r\n return (instance.exposeProxy ||\r\n (instance.exposeProxy = new Proxy(proxyRefs(markRaw(instance.exposed)), {\r\n get(target, key) {\r\n if (key in target) {\r\n return target[key];\r\n }\r\n else if (key in publicPropertiesMap) {\r\n return publicPropertiesMap[key](instance);\r\n }\r\n }\r\n })));\r\n }\r\n}\r\nconst classifyRE = /(?:^|[-_])(\\w)/g;\r\nconst classify = (str) => str.replace(classifyRE, c => c.toUpperCase()).replace(/[-_]/g, '');\r\nfunction getComponentName(Component) {\r\n return isFunction(Component)\r\n ? Component.displayName || Component.name\r\n : Component.name;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatComponentName(instance, Component, isRoot = false) {\r\n let name = getComponentName(Component);\r\n if (!name && Component.__file) {\r\n const match = Component.__file.match(/([^/\\\\]+)\\.\\w+$/);\r\n if (match) {\r\n name = match[1];\r\n }\r\n }\r\n if (!name && instance && instance.parent) {\r\n // try to infer the name based on reverse resolution\r\n const inferFromRegistry = (registry) => {\r\n for (const key in registry) {\r\n if (registry[key] === Component) {\r\n return key;\r\n }\r\n }\r\n };\r\n name =\r\n inferFromRegistry(instance.components ||\r\n instance.parent.type.components) || inferFromRegistry(instance.appContext.components);\r\n }\r\n return name ? classify(name) : isRoot ? `App` : `Anonymous`;\r\n}\r\nfunction isClassComponent(value) {\r\n return isFunction(value) && '__vccOpts' in value;\r\n}\n\nconst stack = [];\r\nfunction pushWarningContext(vnode) {\r\n stack.push(vnode);\r\n}\r\nfunction popWarningContext() {\r\n stack.pop();\r\n}\r\nfunction warn(msg, ...args) {\r\n // avoid props formatting or warn handler tracking deps that might be mutated\r\n // during patch, leading to infinite recursion.\r\n pauseTracking();\r\n const instance = stack.length ? stack[stack.length - 1].component : null;\r\n const appWarnHandler = instance && instance.appContext.config.warnHandler;\r\n const trace = getComponentTrace();\r\n if (appWarnHandler) {\r\n callWithErrorHandling(appWarnHandler, instance, 11 /* APP_WARN_HANDLER */, [\r\n msg + args.join(''),\r\n instance && instance.proxy,\r\n trace\r\n .map(({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`)\r\n .join('\\n'),\r\n trace\r\n ]);\r\n }\r\n else {\r\n const warnArgs = [`[Vue warn]: ${msg}`, ...args];\r\n /* istanbul ignore if */\r\n if (trace.length &&\r\n // avoid spamming console during tests\r\n !false) {\r\n warnArgs.push(`\\n`, ...formatTrace(trace));\r\n }\r\n console.warn(...warnArgs);\r\n }\r\n resetTracking();\r\n}\r\nfunction getComponentTrace() {\r\n let currentVNode = stack[stack.length - 1];\r\n if (!currentVNode) {\r\n return [];\r\n }\r\n // we can't just use the stack because it will be incomplete during updates\r\n // that did not start from the root. Re-construct the parent chain using\r\n // instance parent pointers.\r\n const normalizedStack = [];\r\n while (currentVNode) {\r\n const last = normalizedStack[0];\r\n if (last && last.vnode === currentVNode) {\r\n last.recurseCount++;\r\n }\r\n else {\r\n normalizedStack.push({\r\n vnode: currentVNode,\r\n recurseCount: 0\r\n });\r\n }\r\n const parentInstance = currentVNode.component && currentVNode.component.parent;\r\n currentVNode = parentInstance && parentInstance.vnode;\r\n }\r\n return normalizedStack;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatTrace(trace) {\r\n const logs = [];\r\n trace.forEach((entry, i) => {\r\n logs.push(...(i === 0 ? [] : [`\\n`]), ...formatTraceEntry(entry));\r\n });\r\n return logs;\r\n}\r\nfunction formatTraceEntry({ vnode, recurseCount }) {\r\n const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;\r\n const isRoot = vnode.component ? vnode.component.parent == null : false;\r\n const open = ` at <${formatComponentName(vnode.component, vnode.type, isRoot)}`;\r\n const close = `>` + postfix;\r\n return vnode.props\r\n ? [open, ...formatProps(vnode.props), close]\r\n : [open + close];\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProps(props) {\r\n const res = [];\r\n const keys = Object.keys(props);\r\n keys.slice(0, 3).forEach(key => {\r\n res.push(...formatProp(key, props[key]));\r\n });\r\n if (keys.length > 3) {\r\n res.push(` ...`);\r\n }\r\n return res;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProp(key, value, raw) {\r\n if (isString(value)) {\r\n value = JSON.stringify(value);\r\n return raw ? value : [`${key}=${value}`];\r\n }\r\n else if (typeof value === 'number' ||\r\n typeof value === 'boolean' ||\r\n value == null) {\r\n return raw ? value : [`${key}=${value}`];\r\n }\r\n else if (isRef(value)) {\r\n value = formatProp(key, toRaw(value.value), true);\r\n return raw ? value : [`${key}=Ref<`, value, `>`];\r\n }\r\n else if (isFunction(value)) {\r\n return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];\r\n }\r\n else {\r\n value = toRaw(value);\r\n return raw ? value : [`${key}=`, value];\r\n }\r\n}\n\nconst ErrorTypeStrings = {\r\n [\"sp\" /* SERVER_PREFETCH */]: 'serverPrefetch hook',\r\n [\"bc\" /* BEFORE_CREATE */]: 'beforeCreate hook',\r\n [\"c\" /* CREATED */]: 'created hook',\r\n [\"bm\" /* BEFORE_MOUNT */]: 'beforeMount hook',\r\n [\"m\" /* MOUNTED */]: 'mounted hook',\r\n [\"bu\" /* BEFORE_UPDATE */]: 'beforeUpdate hook',\r\n [\"u\" /* UPDATED */]: 'updated',\r\n [\"bum\" /* BEFORE_UNMOUNT */]: 'beforeUnmount hook',\r\n [\"um\" /* UNMOUNTED */]: 'unmounted hook',\r\n [\"a\" /* ACTIVATED */]: 'activated hook',\r\n [\"da\" /* DEACTIVATED */]: 'deactivated hook',\r\n [\"ec\" /* ERROR_CAPTURED */]: 'errorCaptured hook',\r\n [\"rtc\" /* RENDER_TRACKED */]: 'renderTracked hook',\r\n [\"rtg\" /* RENDER_TRIGGERED */]: 'renderTriggered hook',\r\n [0 /* SETUP_FUNCTION */]: 'setup function',\r\n [1 /* RENDER_FUNCTION */]: 'render function',\r\n [2 /* WATCH_GETTER */]: 'watcher getter',\r\n [3 /* WATCH_CALLBACK */]: 'watcher callback',\r\n [4 /* WATCH_CLEANUP */]: 'watcher cleanup function',\r\n [5 /* NATIVE_EVENT_HANDLER */]: 'native event handler',\r\n [6 /* COMPONENT_EVENT_HANDLER */]: 'component event handler',\r\n [7 /* VNODE_HOOK */]: 'vnode hook',\r\n [8 /* DIRECTIVE_HOOK */]: 'directive hook',\r\n [9 /* TRANSITION_HOOK */]: 'transition hook',\r\n [10 /* APP_ERROR_HANDLER */]: 'app errorHandler',\r\n [11 /* APP_WARN_HANDLER */]: 'app warnHandler',\r\n [12 /* FUNCTION_REF */]: 'ref function',\r\n [13 /* ASYNC_COMPONENT_LOADER */]: 'async component loader',\r\n [14 /* SCHEDULER */]: 'scheduler flush. This is likely a Vue internals bug. ' +\r\n 'Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-next'\r\n};\r\nfunction callWithErrorHandling(fn, instance, type, args) {\r\n let res;\r\n try {\r\n res = args ? fn(...args) : fn();\r\n }\r\n catch (err) {\r\n handleError(err, instance, type);\r\n }\r\n return res;\r\n}\r\nfunction callWithAsyncErrorHandling(fn, instance, type, args) {\r\n if (isFunction(fn)) {\r\n const res = callWithErrorHandling(fn, instance, type, args);\r\n if (res && isPromise(res)) {\r\n res.catch(err => {\r\n handleError(err, instance, type);\r\n });\r\n }\r\n return res;\r\n }\r\n const values = [];\r\n for (let i = 0; i < fn.length; i++) {\r\n values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));\r\n }\r\n return values;\r\n}\r\nfunction handleError(err, instance, type, throwInDev = true) {\r\n const contextVNode = instance ? instance.vnode : null;\r\n if (instance) {\r\n let cur = instance.parent;\r\n // the exposed instance is the render proxy to keep it consistent with 2.x\r\n const exposedInstance = instance.proxy;\r\n // in production the hook receives only the error code\r\n const errorInfo = (process.env.NODE_ENV !== 'production') ? ErrorTypeStrings[type] : type;\r\n while (cur) {\r\n const errorCapturedHooks = cur.ec;\r\n if (errorCapturedHooks) {\r\n for (let i = 0; i < errorCapturedHooks.length; i++) {\r\n if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {\r\n return;\r\n }\r\n }\r\n }\r\n cur = cur.parent;\r\n }\r\n // app-level handling\r\n const appErrorHandler = instance.appContext.config.errorHandler;\r\n if (appErrorHandler) {\r\n callWithErrorHandling(appErrorHandler, null, 10 /* APP_ERROR_HANDLER */, [err, exposedInstance, errorInfo]);\r\n return;\r\n }\r\n }\r\n logError(err, type, contextVNode, throwInDev);\r\n}\r\nfunction logError(err, type, contextVNode, throwInDev = true) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const info = ErrorTypeStrings[type];\r\n if (contextVNode) {\r\n pushWarningContext(contextVNode);\r\n }\r\n warn(`Unhandled error${info ? ` during execution of ${info}` : ``}`);\r\n if (contextVNode) {\r\n popWarningContext();\r\n }\r\n // crash in dev by default so it's more noticeable\r\n if (throwInDev) {\r\n throw err;\r\n }\r\n else {\r\n console.error(err);\r\n }\r\n }\r\n else {\r\n // recover in prod to reduce the impact on end-user\r\n console.error(err);\r\n }\r\n}\n\nlet isFlushing = false;\r\nlet isFlushPending = false;\r\nconst queue = [];\r\nlet flushIndex = 0;\r\nconst pendingPreFlushCbs = [];\r\nlet activePreFlushCbs = null;\r\nlet preFlushIndex = 0;\r\nconst pendingPostFlushCbs = [];\r\nlet activePostFlushCbs = null;\r\nlet postFlushIndex = 0;\r\nconst resolvedPromise = Promise.resolve();\r\nlet currentFlushPromise = null;\r\nlet currentPreFlushParentJob = null;\r\nconst RECURSION_LIMIT = 100;\r\nfunction nextTick(fn) {\r\n const p = currentFlushPromise || resolvedPromise;\r\n return fn ? p.then(this ? fn.bind(this) : fn) : p;\r\n}\r\n// #2768\r\n// Use binary-search to find a suitable position in the queue,\r\n// so that the queue maintains the increasing order of job's id,\r\n// which can prevent the job from being skipped and also can avoid repeated patching.\r\nfunction findInsertionIndex(id) {\r\n // the start index should be `flushIndex + 1`\r\n let start = flushIndex + 1;\r\n let end = queue.length;\r\n while (start < end) {\r\n const middle = (start + end) >>> 1;\r\n const middleJobId = getId(queue[middle]);\r\n middleJobId < id ? (start = middle + 1) : (end = middle);\r\n }\r\n return start;\r\n}\r\nfunction queueJob(job) {\r\n // the dedupe search uses the startIndex argument of Array.includes()\r\n // by default the search index includes the current job that is being run\r\n // so it cannot recursively trigger itself again.\r\n // if the job is a watch() callback, the search will start with a +1 index to\r\n // allow it recursively trigger itself - it is the user's responsibility to\r\n // ensure it doesn't end up in an infinite loop.\r\n if ((!queue.length ||\r\n !queue.includes(job, isFlushing && job.allowRecurse ? flushIndex + 1 : flushIndex)) &&\r\n job !== currentPreFlushParentJob) {\r\n if (job.id == null) {\r\n queue.push(job);\r\n }\r\n else {\r\n queue.splice(findInsertionIndex(job.id), 0, job);\r\n }\r\n queueFlush();\r\n }\r\n}\r\nfunction queueFlush() {\r\n if (!isFlushing && !isFlushPending) {\r\n isFlushPending = true;\r\n currentFlushPromise = resolvedPromise.then(flushJobs);\r\n }\r\n}\r\nfunction invalidateJob(job) {\r\n const i = queue.indexOf(job);\r\n if (i > flushIndex) {\r\n queue.splice(i, 1);\r\n }\r\n}\r\nfunction queueCb(cb, activeQueue, pendingQueue, index) {\r\n if (!isArray(cb)) {\r\n if (!activeQueue ||\r\n !activeQueue.includes(cb, cb.allowRecurse ? index + 1 : index)) {\r\n pendingQueue.push(cb);\r\n }\r\n }\r\n else {\r\n // if cb is an array, it is a component lifecycle hook which can only be\r\n // triggered by a job, which is already deduped in the main queue, so\r\n // we can skip duplicate check here to improve perf\r\n pendingQueue.push(...cb);\r\n }\r\n queueFlush();\r\n}\r\nfunction queuePreFlushCb(cb) {\r\n queueCb(cb, activePreFlushCbs, pendingPreFlushCbs, preFlushIndex);\r\n}\r\nfunction queuePostFlushCb(cb) {\r\n queueCb(cb, activePostFlushCbs, pendingPostFlushCbs, postFlushIndex);\r\n}\r\nfunction flushPreFlushCbs(seen, parentJob = null) {\r\n if (pendingPreFlushCbs.length) {\r\n currentPreFlushParentJob = parentJob;\r\n activePreFlushCbs = [...new Set(pendingPreFlushCbs)];\r\n pendingPreFlushCbs.length = 0;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n for (preFlushIndex = 0; preFlushIndex < activePreFlushCbs.length; preFlushIndex++) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n checkRecursiveUpdates(seen, activePreFlushCbs[preFlushIndex])) {\r\n continue;\r\n }\r\n activePreFlushCbs[preFlushIndex]();\r\n }\r\n activePreFlushCbs = null;\r\n preFlushIndex = 0;\r\n currentPreFlushParentJob = null;\r\n // recursively flush until it drains\r\n flushPreFlushCbs(seen, parentJob);\r\n }\r\n}\r\nfunction flushPostFlushCbs(seen) {\r\n if (pendingPostFlushCbs.length) {\r\n const deduped = [...new Set(pendingPostFlushCbs)];\r\n pendingPostFlushCbs.length = 0;\r\n // #1947 already has active queue, nested flushPostFlushCbs call\r\n if (activePostFlushCbs) {\r\n activePostFlushCbs.push(...deduped);\r\n return;\r\n }\r\n activePostFlushCbs = deduped;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n activePostFlushCbs.sort((a, b) => getId(a) - getId(b));\r\n for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n checkRecursiveUpdates(seen, activePostFlushCbs[postFlushIndex])) {\r\n continue;\r\n }\r\n activePostFlushCbs[postFlushIndex]();\r\n }\r\n activePostFlushCbs = null;\r\n postFlushIndex = 0;\r\n }\r\n}\r\nconst getId = (job) => job.id == null ? Infinity : job.id;\r\nfunction flushJobs(seen) {\r\n isFlushPending = false;\r\n isFlushing = true;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n flushPreFlushCbs(seen);\r\n // Sort queue before flush.\r\n // This ensures that:\r\n // 1. Components are updated from parent to child. (because parent is always\r\n // created before the child so its render effect will have smaller\r\n // priority number)\r\n // 2. If a component is unmounted during a parent component's update,\r\n // its update can be skipped.\r\n queue.sort((a, b) => getId(a) - getId(b));\r\n // conditional usage of checkRecursiveUpdate must be determined out of\r\n // try ... catch block since Rollup by default de-optimizes treeshaking\r\n // inside try-catch. This can leave all warning code unshaked. Although\r\n // they would get eventually shaken by a minifier like terser, some minifiers\r\n // would fail to do that (e.g. https://github.com/evanw/esbuild/issues/1610)\r\n const check = (process.env.NODE_ENV !== 'production')\r\n ? (job) => checkRecursiveUpdates(seen, job)\r\n : NOOP;\r\n try {\r\n for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {\r\n const job = queue[flushIndex];\r\n if (job && job.active !== false) {\r\n if ((process.env.NODE_ENV !== 'production') && check(job)) {\r\n continue;\r\n }\r\n // console.log(`running:`, job.id)\r\n callWithErrorHandling(job, null, 14 /* SCHEDULER */);\r\n }\r\n }\r\n }\r\n finally {\r\n flushIndex = 0;\r\n queue.length = 0;\r\n flushPostFlushCbs(seen);\r\n isFlushing = false;\r\n currentFlushPromise = null;\r\n // some postFlushCb queued jobs!\r\n // keep flushing until it drains.\r\n if (queue.length ||\r\n pendingPreFlushCbs.length ||\r\n pendingPostFlushCbs.length) {\r\n flushJobs(seen);\r\n }\r\n }\r\n}\r\nfunction checkRecursiveUpdates(seen, fn) {\r\n if (!seen.has(fn)) {\r\n seen.set(fn, 1);\r\n }\r\n else {\r\n const count = seen.get(fn);\r\n if (count > RECURSION_LIMIT) {\r\n const instance = fn.ownerInstance;\r\n const componentName = instance && getComponentName(instance.type);\r\n warn(`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. ` +\r\n `This means you have a reactive effect that is mutating its own ` +\r\n `dependencies and thus recursively triggering itself. Possible sources ` +\r\n `include component template, render function, updated hook or ` +\r\n `watcher source function.`);\r\n return true;\r\n }\r\n else {\r\n seen.set(fn, count + 1);\r\n }\r\n }\r\n}\n\n// Simple effect.\r\nfunction watchEffect(effect, options) {\r\n return doWatch(effect, null, options);\r\n}\r\nfunction watchPostEffect(effect, options) {\r\n return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n ? Object.assign(options || {}, { flush: 'post' })\r\n : { flush: 'post' }));\r\n}\r\nfunction watchSyncEffect(effect, options) {\r\n return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n ? Object.assign(options || {}, { flush: 'sync' })\r\n : { flush: 'sync' }));\r\n}\r\n// initial value for watchers to trigger on undefined initial values\r\nconst INITIAL_WATCHER_VALUE = {};\r\n// implementation\r\nfunction watch(source, cb, options) {\r\n if ((process.env.NODE_ENV !== 'production') && !isFunction(cb)) {\r\n warn(`\\`watch(fn, options?)\\` signature has been moved to a separate API. ` +\r\n `Use \\`watchEffect(fn, options?)\\` instead. \\`watch\\` now only ` +\r\n `supports \\`watch(source, cb, options?) signature.`);\r\n }\r\n return doWatch(source, cb, options);\r\n}\r\nfunction doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EMPTY_OBJ) {\r\n if ((process.env.NODE_ENV !== 'production') && !cb) {\r\n if (immediate !== undefined) {\r\n warn(`watch() \"immediate\" option is only respected when using the ` +\r\n `watch(source, callback, options?) signature.`);\r\n }\r\n if (deep !== undefined) {\r\n warn(`watch() \"deep\" option is only respected when using the ` +\r\n `watch(source, callback, options?) signature.`);\r\n }\r\n }\r\n const warnInvalidSource = (s) => {\r\n warn(`Invalid watch source: `, s, `A watch source can only be a getter/effect function, a ref, ` +\r\n `a reactive object, or an array of these types.`);\r\n };\r\n const instance = currentInstance;\r\n let getter;\r\n let forceTrigger = false;\r\n let isMultiSource = false;\r\n if (isRef(source)) {\r\n getter = () => source.value;\r\n forceTrigger = !!source._shallow;\r\n }\r\n else if (isReactive(source)) {\r\n getter = () => source;\r\n deep = true;\r\n }\r\n else if (isArray(source)) {\r\n isMultiSource = true;\r\n forceTrigger = source.some(isReactive);\r\n getter = () => source.map(s => {\r\n if (isRef(s)) {\r\n return s.value;\r\n }\r\n else if (isReactive(s)) {\r\n return traverse(s);\r\n }\r\n else if (isFunction(s)) {\r\n return callWithErrorHandling(s, instance, 2 /* WATCH_GETTER */);\r\n }\r\n else {\r\n (process.env.NODE_ENV !== 'production') && warnInvalidSource(s);\r\n }\r\n });\r\n }\r\n else if (isFunction(source)) {\r\n if (cb) {\r\n // getter with cb\r\n getter = () => callWithErrorHandling(source, instance, 2 /* WATCH_GETTER */);\r\n }\r\n else {\r\n // no cb -> simple effect\r\n getter = () => {\r\n if (instance && instance.isUnmounted) {\r\n return;\r\n }\r\n if (cleanup) {\r\n cleanup();\r\n }\r\n return callWithAsyncErrorHandling(source, instance, 3 /* WATCH_CALLBACK */, [onInvalidate]);\r\n };\r\n }\r\n }\r\n else {\r\n getter = NOOP;\r\n (process.env.NODE_ENV !== 'production') && warnInvalidSource(source);\r\n }\r\n if (cb && deep) {\r\n const baseGetter = getter;\r\n getter = () => traverse(baseGetter());\r\n }\r\n let cleanup;\r\n let onInvalidate = (fn) => {\r\n cleanup = effect.onStop = () => {\r\n callWithErrorHandling(fn, instance, 4 /* WATCH_CLEANUP */);\r\n };\r\n };\r\n // in SSR there is no need to setup an actual effect, and it should be noop\r\n // unless it's eager\r\n if (isInSSRComponentSetup) {\r\n // we will also not call the invalidate callback (+ runner is not set up)\r\n onInvalidate = NOOP;\r\n if (!cb) {\r\n getter();\r\n }\r\n else if (immediate) {\r\n callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n getter(),\r\n isMultiSource ? [] : undefined,\r\n onInvalidate\r\n ]);\r\n }\r\n return NOOP;\r\n }\r\n let oldValue = isMultiSource ? [] : INITIAL_WATCHER_VALUE;\r\n const job = () => {\r\n if (!effect.active) {\r\n return;\r\n }\r\n if (cb) {\r\n // watch(source, cb)\r\n const newValue = effect.run();\r\n if (deep ||\r\n forceTrigger ||\r\n (isMultiSource\r\n ? newValue.some((v, i) => hasChanged(v, oldValue[i]))\r\n : hasChanged(newValue, oldValue)) ||\r\n (false )) {\r\n // cleanup before running cb again\r\n if (cleanup) {\r\n cleanup();\r\n }\r\n callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n newValue,\r\n // pass undefined as the old value when it's changed for the first time\r\n oldValue === INITIAL_WATCHER_VALUE ? undefined : oldValue,\r\n onInvalidate\r\n ]);\r\n oldValue = newValue;\r\n }\r\n }\r\n else {\r\n // watchEffect\r\n effect.run();\r\n }\r\n };\r\n // important: mark the job as a watcher callback so that scheduler knows\r\n // it is allowed to self-trigger (#1727)\r\n job.allowRecurse = !!cb;\r\n let scheduler;\r\n if (flush === 'sync') {\r\n scheduler = job; // the scheduler function gets called directly\r\n }\r\n else if (flush === 'post') {\r\n scheduler = () => queuePostRenderEffect(job, instance && instance.suspense);\r\n }\r\n else {\r\n // default: 'pre'\r\n scheduler = () => {\r\n if (!instance || instance.isMounted) {\r\n queuePreFlushCb(job);\r\n }\r\n else {\r\n // with 'pre' option, the first call must happen before\r\n // the component is mounted so it is called synchronously.\r\n job();\r\n }\r\n };\r\n }\r\n const effect = new ReactiveEffect(getter, scheduler);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n effect.onTrack = onTrack;\r\n effect.onTrigger = onTrigger;\r\n }\r\n // initial run\r\n if (cb) {\r\n if (immediate) {\r\n job();\r\n }\r\n else {\r\n oldValue = effect.run();\r\n }\r\n }\r\n else if (flush === 'post') {\r\n queuePostRenderEffect(effect.run.bind(effect), instance && instance.suspense);\r\n }\r\n else {\r\n effect.run();\r\n }\r\n return () => {\r\n effect.stop();\r\n if (instance && instance.scope) {\r\n remove(instance.scope.effects, effect);\r\n }\r\n };\r\n}\r\n// this.$watch\r\nfunction instanceWatch(source, value, options) {\r\n const publicThis = this.proxy;\r\n const getter = isString(source)\r\n ? source.includes('.')\r\n ? createPathGetter(publicThis, source)\r\n : () => publicThis[source]\r\n : source.bind(publicThis, publicThis);\r\n let cb;\r\n if (isFunction(value)) {\r\n cb = value;\r\n }\r\n else {\r\n cb = value.handler;\r\n options = value;\r\n }\r\n const cur = currentInstance;\r\n setCurrentInstance(this);\r\n const res = doWatch(getter, cb.bind(publicThis), options);\r\n if (cur) {\r\n setCurrentInstance(cur);\r\n }\r\n else {\r\n unsetCurrentInstance();\r\n }\r\n return res;\r\n}\r\nfunction createPathGetter(ctx, path) {\r\n const segments = path.split('.');\r\n return () => {\r\n let cur = ctx;\r\n for (let i = 0; i < segments.length && cur; i++) {\r\n cur = cur[segments[i]];\r\n }\r\n return cur;\r\n };\r\n}\r\nfunction traverse(value, seen) {\r\n if (!isObject(value) || value[\"__v_skip\" /* SKIP */]) {\r\n return value;\r\n }\r\n seen = seen || new Set();\r\n if (seen.has(value)) {\r\n return value;\r\n }\r\n seen.add(value);\r\n if (isRef(value)) {\r\n traverse(value.value, seen);\r\n }\r\n else if (isArray(value)) {\r\n for (let i = 0; i < value.length; i++) {\r\n traverse(value[i], seen);\r\n }\r\n }\r\n else if (isSet(value) || isMap(value)) {\r\n value.forEach((v) => {\r\n traverse(v, seen);\r\n });\r\n }\r\n else if (isPlainObject(value)) {\r\n for (const key in value) {\r\n traverse(value[key], seen);\r\n }\r\n }\r\n return value;\r\n}\n\n// dev only\r\nconst warnRuntimeUsage = (method) => warn(`${method}() is a compiler-hint helper that is only usable inside ` +\r\n `<script setup> of a single file component. Its arguments should be ` +\r\n `compiled away and passing it at runtime has no effect.`);\r\n// implementation\r\nfunction defineProps() {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineProps`);\r\n }\r\n return null;\r\n}\r\n// implementation\r\nfunction defineEmits() {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineEmits`);\r\n }\r\n return null;\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for declaring a component's exposed\r\n * instance properties when it is accessed by a parent component via template\r\n * refs.\r\n *\r\n * `<script setup>` components are closed by default - i.e. varaibles inside\r\n * the `<script setup>` scope is not exposed to parent unless explicitly exposed\r\n * via `defineExpose`.\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the\r\n * output and should **not** be actually called at runtime.\r\n */\r\nfunction defineExpose(exposed) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineExpose`);\r\n }\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for providing props default values when\r\n * using type-based `defineProps` declaration.\r\n *\r\n * Example usage:\r\n * ```ts\r\n * withDefaults(defineProps<{\r\n * size?: number\r\n * labels?: string[]\r\n * }>(), {\r\n * size: 3,\r\n * labels: () => ['default label']\r\n * })\r\n * ```\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the output\r\n * and should **not** be actually called at runtime.\r\n */\r\nfunction withDefaults(props, defaults) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`withDefaults`);\r\n }\r\n return null;\r\n}\r\nfunction useSlots() {\r\n return getContext().slots;\r\n}\r\nfunction useAttrs() {\r\n return getContext().attrs;\r\n}\r\nfunction getContext() {\r\n const i = getCurrentInstance();\r\n if ((process.env.NODE_ENV !== 'production') && !i) {\r\n warn(`useContext() called without active instance.`);\r\n }\r\n return i.setupContext || (i.setupContext = createSetupContext(i));\r\n}\r\n/**\r\n * Runtime helper for merging default declarations. Imported by compiled code\r\n * only.\r\n * @internal\r\n */\r\nfunction mergeDefaults(raw, defaults) {\r\n const props = isArray(raw)\r\n ? raw.reduce((normalized, p) => ((normalized[p] = {}), normalized), {})\r\n : raw;\r\n for (const key in defaults) {\r\n const opt = props[key];\r\n if (opt) {\r\n if (isArray(opt) || isFunction(opt)) {\r\n props[key] = { type: opt, default: defaults[key] };\r\n }\r\n else {\r\n opt.default = defaults[key];\r\n }\r\n }\r\n else if (opt === null) {\r\n props[key] = { default: defaults[key] };\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`props default key \"${key}\" has no corresponding declaration.`);\r\n }\r\n }\r\n return props;\r\n}\r\n/**\r\n * Used to create a proxy for the rest element when destructuring props with\r\n * defineProps().\r\n * @internal\r\n */\r\nfunction createPropsRestProxy(props, excludedKeys) {\r\n const ret = {};\r\n for (const key in props) {\r\n if (!excludedKeys.includes(key)) {\r\n Object.defineProperty(ret, key, {\r\n enumerable: true,\r\n get: () => props[key]\r\n });\r\n }\r\n }\r\n return ret;\r\n}\r\n/**\r\n * `<script setup>` helper for persisting the current instance context over\r\n * async/await flows.\r\n *\r\n * `@vue/compiler-sfc` converts the following:\r\n *\r\n * ```ts\r\n * const x = await foo()\r\n * ```\r\n *\r\n * into:\r\n *\r\n * ```ts\r\n * let __temp, __restore\r\n * const x = (([__temp, __restore] = withAsyncContext(() => foo())),__temp=await __temp,__restore(),__temp)\r\n * ```\r\n * @internal\r\n */\r\nfunction withAsyncContext(getAwaitable) {\r\n const ctx = getCurrentInstance();\r\n if ((process.env.NODE_ENV !== 'production') && !ctx) {\r\n warn(`withAsyncContext called without active current instance. ` +\r\n `This is likely a bug.`);\r\n }\r\n let awaitable = getAwaitable();\r\n unsetCurrentInstance();\r\n if (isPromise(awaitable)) {\r\n awaitable = awaitable.catch(e => {\r\n setCurrentInstance(ctx);\r\n throw e;\r\n });\r\n }\r\n return [awaitable, () => setCurrentInstance(ctx)];\r\n}\n\n// Actual implementation\r\nfunction h(type, propsOrChildren, children) {\r\n const l = arguments.length;\r\n if (l === 2) {\r\n if (isObject(propsOrChildren) && !isArray(propsOrChildren)) {\r\n // single vnode without props\r\n if (isVNode(propsOrChildren)) {\r\n return createVNode(type, null, [propsOrChildren]);\r\n }\r\n // props without children\r\n return createVNode(type, propsOrChildren);\r\n }\r\n else {\r\n // omit props\r\n return createVNode(type, null, propsOrChildren);\r\n }\r\n }\r\n else {\r\n if (l > 3) {\r\n children = Array.prototype.slice.call(arguments, 2);\r\n }\r\n else if (l === 3 && isVNode(children)) {\r\n children = [children];\r\n }\r\n return createVNode(type, propsOrChildren, children);\r\n }\r\n}\n\nconst ssrContextKey = Symbol((process.env.NODE_ENV !== 'production') ? `ssrContext` : ``);\r\nconst useSSRContext = () => {\r\n {\r\n const ctx = inject(ssrContextKey);\r\n if (!ctx) {\r\n warn(`Server rendering context not provided. Make sure to only call ` +\r\n `useSSRContext() conditionally in the server build.`);\r\n }\r\n return ctx;\r\n }\r\n};\n\nfunction initCustomFormatter() {\r\n /* eslint-disable no-restricted-globals */\r\n if (!(process.env.NODE_ENV !== 'production') || typeof window === 'undefined') {\r\n return;\r\n }\r\n const vueStyle = { style: 'color:#3ba776' };\r\n const numberStyle = { style: 'color:#0b1bc9' };\r\n const stringStyle = { style: 'color:#b62e24' };\r\n const keywordStyle = { style: 'color:#9d288c' };\r\n // custom formatter for Chrome\r\n // https://www.mattzeunert.com/2016/02/19/custom-chrome-devtools-object-formatters.html\r\n const formatter = {\r\n header(obj) {\r\n // TODO also format ComponentPublicInstance & ctx.slots/attrs in setup\r\n if (!isObject(obj)) {\r\n return null;\r\n }\r\n if (obj.__isVue) {\r\n return ['div', vueStyle, `VueInstance`];\r\n }\r\n else if (isRef(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, genRefFlag(obj)],\r\n '<',\r\n formatValue(obj.value),\r\n `>`\r\n ];\r\n }\r\n else if (isReactive(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, 'Reactive'],\r\n '<',\r\n formatValue(obj),\r\n `>${isReadonly(obj) ? ` (readonly)` : ``}`\r\n ];\r\n }\r\n else if (isReadonly(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, 'Readonly'],\r\n '<',\r\n formatValue(obj),\r\n '>'\r\n ];\r\n }\r\n return null;\r\n },\r\n hasBody(obj) {\r\n return obj && obj.__isVue;\r\n },\r\n body(obj) {\r\n if (obj && obj.__isVue) {\r\n return [\r\n 'div',\r\n {},\r\n ...formatInstance(obj.$)\r\n ];\r\n }\r\n }\r\n };\r\n function formatInstance(instance) {\r\n const blocks = [];\r\n if (instance.type.props && instance.props) {\r\n blocks.push(createInstanceBlock('props', toRaw(instance.props)));\r\n }\r\n if (instance.setupState !== EMPTY_OBJ) {\r\n blocks.push(createInstanceBlock('setup', instance.setupState));\r\n }\r\n if (instance.data !== EMPTY_OBJ) {\r\n blocks.push(createInstanceBlock('data', toRaw(instance.data)));\r\n }\r\n const computed = extractKeys(instance, 'computed');\r\n if (computed) {\r\n blocks.push(createInstanceBlock('computed', computed));\r\n }\r\n const injected = extractKeys(instance, 'inject');\r\n if (injected) {\r\n blocks.push(createInstanceBlock('injected', injected));\r\n }\r\n blocks.push([\r\n 'div',\r\n {},\r\n [\r\n 'span',\r\n {\r\n style: keywordStyle.style + ';opacity:0.66'\r\n },\r\n '$ (internal): '\r\n ],\r\n ['object', { object: instance }]\r\n ]);\r\n return blocks;\r\n }\r\n function createInstanceBlock(type, target) {\r\n target = extend({}, target);\r\n if (!Object.keys(target).length) {\r\n return ['span', {}];\r\n }\r\n return [\r\n 'div',\r\n { style: 'line-height:1.25em;margin-bottom:0.6em' },\r\n [\r\n 'div',\r\n {\r\n style: 'color:#476582'\r\n },\r\n type\r\n ],\r\n [\r\n 'div',\r\n {\r\n style: 'padding-left:1.25em'\r\n },\r\n ...Object.keys(target).map(key => {\r\n return [\r\n 'div',\r\n {},\r\n ['span', keywordStyle, key + ': '],\r\n formatValue(target[key], false)\r\n ];\r\n })\r\n ]\r\n ];\r\n }\r\n function formatValue(v, asRaw = true) {\r\n if (typeof v === 'number') {\r\n return ['span', numberStyle, v];\r\n }\r\n else if (typeof v === 'string') {\r\n return ['span', stringStyle, JSON.stringify(v)];\r\n }\r\n else if (typeof v === 'boolean') {\r\n return ['span', keywordStyle, v];\r\n }\r\n else if (isObject(v)) {\r\n return ['object', { object: asRaw ? toRaw(v) : v }];\r\n }\r\n else {\r\n return ['span', stringStyle, String(v)];\r\n }\r\n }\r\n function extractKeys(instance, type) {\r\n const Comp = instance.type;\r\n if (isFunction(Comp)) {\r\n return;\r\n }\r\n const extracted = {};\r\n for (const key in instance.ctx) {\r\n if (isKeyOfType(Comp, key, type)) {\r\n extracted[key] = instance.ctx[key];\r\n }\r\n }\r\n return extracted;\r\n }\r\n function isKeyOfType(Comp, key, type) {\r\n const opts = Comp[type];\r\n if ((isArray(opts) && opts.includes(key)) ||\r\n (isObject(opts) && key in opts)) {\r\n return true;\r\n }\r\n if (Comp.extends && isKeyOfType(Comp.extends, key, type)) {\r\n return true;\r\n }\r\n if (Comp.mixins && Comp.mixins.some(m => isKeyOfType(m, key, type))) {\r\n return true;\r\n }\r\n }\r\n function genRefFlag(v) {\r\n if (v._shallow) {\r\n return `ShallowRef`;\r\n }\r\n if (v.effect) {\r\n return `ComputedRef`;\r\n }\r\n return `Ref`;\r\n }\r\n if (window.devtoolsFormatters) {\r\n window.devtoolsFormatters.push(formatter);\r\n }\r\n else {\r\n window.devtoolsFormatters = [formatter];\r\n }\r\n}\n\nfunction withMemo(memo, render, cache, index) {\r\n const cached = cache[index];\r\n if (cached && isMemoSame(cached, memo)) {\r\n return cached;\r\n }\r\n const ret = render();\r\n // shallow clone\r\n ret.memo = memo.slice();\r\n return (cache[index] = ret);\r\n}\r\nfunction isMemoSame(cached, memo) {\r\n const prev = cached.memo;\r\n if (prev.length != memo.length) {\r\n return false;\r\n }\r\n for (let i = 0; i < prev.length; i++) {\r\n if (prev[i] !== memo[i]) {\r\n return false;\r\n }\r\n }\r\n // make sure to let parent block track it when returning cached\r\n if (isBlockTreeEnabled > 0 && currentBlock) {\r\n currentBlock.push(cached);\r\n }\r\n return true;\r\n}\n\n// Core API ------------------------------------------------------------------\r\nconst version = \"3.2.26\";\r\nconst _ssrUtils = {\r\n createComponentInstance,\r\n setupComponent,\r\n renderComponentRoot,\r\n setCurrentRenderingInstance,\r\n isVNode,\r\n normalizeVNode\r\n};\r\n/**\r\n * SSR utils for \\@vue/server-renderer. Only exposed in cjs builds.\r\n * @internal\r\n */\r\nconst ssrUtils = (_ssrUtils );\r\n/**\r\n * @internal only exposed in compat builds\r\n */\r\nconst resolveFilter = null;\r\n/**\r\n * @internal only exposed in compat builds.\r\n */\r\nconst compatUtils = (null);\n\nexport { BaseTransition, Comment, Fragment, KeepAlive, Static, Suspense, Teleport, Text, callWithAsyncErrorHandling, callWithErrorHandling, cloneVNode, compatUtils, createBlock, createCommentVNode, createElementBlock, createBaseVNode as createElementVNode, createHydrationRenderer, createPropsRestProxy, createRenderer, createSlots, createStaticVNode, createTextVNode, createVNode, defineAsyncComponent, defineComponent, defineEmits, defineExpose, defineProps, devtools, getCurrentInstance, getTransitionRawChildren, guardReactiveProps, h, handleError, initCustomFormatter, inject, isMemoSame, isRuntimeOnly, isVNode, mergeDefaults, mergeProps, nextTick, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, onUpdated, openBlock, popScopeId, provide, pushScopeId, queuePostFlushCb, registerRuntimeCompiler, renderList, renderSlot, resolveComponent, resolveDirective, resolveDynamicComponent, resolveFilter, resolveTransitionHooks, setBlockTracking, setDevtoolsHook, setTransitionHooks, ssrContextKey, ssrUtils, toHandlers, transformVNodeArgs, useAttrs, useSSRContext, useSlots, useTransitionState, version, warn, watch, watchEffect, watchPostEffect, watchSyncEffect, withAsyncContext, withCtx, withDefaults, withDirectives, withMemo, withScopeId };\n","import { camelize, warn, callWithAsyncErrorHandling, defineComponent, nextTick, createVNode, getCurrentInstance, watchPostEffect, onMounted, onUnmounted, Fragment, Static, h, BaseTransition, useTransitionState, onUpdated, toRaw, getTransitionRawChildren, setTransitionHooks, resolveTransitionHooks, createRenderer, isRuntimeOnly, createHydrationRenderer } from '@vue/runtime-core';\nexport * from '@vue/runtime-core';\nimport { isString, isArray, hyphenate, capitalize, isSpecialBooleanAttr, includeBooleanAttr, isOn, isModelListener, isFunction, toNumber, camelize as camelize$1, extend, EMPTY_OBJ, isObject, invokeArrayFns, looseIndexOf, isSet, looseEqual, isHTMLTag, isSVGTag } from '@vue/shared';\n\nconst svgNS = 'http://www.w3.org/2000/svg';\r\nconst doc = (typeof document !== 'undefined' ? document : null);\r\nconst staticTemplateCache = new Map();\r\nconst nodeOps = {\r\n insert: (child, parent, anchor) => {\r\n parent.insertBefore(child, anchor || null);\r\n },\r\n remove: child => {\r\n const parent = child.parentNode;\r\n if (parent) {\r\n parent.removeChild(child);\r\n }\r\n },\r\n createElement: (tag, isSVG, is, props) => {\r\n const el = isSVG\r\n ? doc.createElementNS(svgNS, tag)\r\n : doc.createElement(tag, is ? { is } : undefined);\r\n if (tag === 'select' && props && props.multiple != null) {\r\n el.setAttribute('multiple', props.multiple);\r\n }\r\n return el;\r\n },\r\n createText: text => doc.createTextNode(text),\r\n createComment: text => doc.createComment(text),\r\n setText: (node, text) => {\r\n node.nodeValue = text;\r\n },\r\n setElementText: (el, text) => {\r\n el.textContent = text;\r\n },\r\n parentNode: node => node.parentNode,\r\n nextSibling: node => node.nextSibling,\r\n querySelector: selector => doc.querySelector(selector),\r\n setScopeId(el, id) {\r\n el.setAttribute(id, '');\r\n },\r\n cloneNode(el) {\r\n const cloned = el.cloneNode(true);\r\n // #3072\r\n // - in `patchDOMProp`, we store the actual value in the `el._value` property.\r\n // - normally, elements using `:value` bindings will not be hoisted, but if\r\n // the bound value is a constant, e.g. `:value=\"true\"` - they do get\r\n // hoisted.\r\n // - in production, hoisted nodes are cloned when subsequent inserts, but\r\n // cloneNode() does not copy the custom property we attached.\r\n // - This may need to account for other custom DOM properties we attach to\r\n // elements in addition to `_value` in the future.\r\n if (`_value` in el) {\r\n cloned._value = el._value;\r\n }\r\n return cloned;\r\n },\r\n // __UNSAFE__\r\n // Reason: innerHTML.\r\n // Static content here can only come from compiled templates.\r\n // As long as the user only uses trusted templates, this is safe.\r\n insertStaticContent(content, parent, anchor, isSVG) {\r\n // <parent> before | first ... last | anchor </parent>\r\n const before = anchor ? anchor.previousSibling : parent.lastChild;\r\n let template = staticTemplateCache.get(content);\r\n if (!template) {\r\n const t = doc.createElement('template');\r\n t.innerHTML = isSVG ? `<svg>${content}</svg>` : content;\r\n template = t.content;\r\n if (isSVG) {\r\n // remove outer svg wrapper\r\n const wrapper = template.firstChild;\r\n while (wrapper.firstChild) {\r\n template.appendChild(wrapper.firstChild);\r\n }\r\n template.removeChild(wrapper);\r\n }\r\n staticTemplateCache.set(content, template);\r\n }\r\n parent.insertBefore(template.cloneNode(true), anchor);\r\n return [\r\n // first\r\n before ? before.nextSibling : parent.firstChild,\r\n // last\r\n anchor ? anchor.previousSibling : parent.lastChild\r\n ];\r\n }\r\n};\n\n// compiler should normalize class + :class bindings on the same element\r\n// into a single binding ['staticClass', dynamic]\r\nfunction patchClass(el, value, isSVG) {\r\n // directly setting className should be faster than setAttribute in theory\r\n // if this is an element during a transition, take the temporary transition\r\n // classes into account.\r\n const transitionClasses = el._vtc;\r\n if (transitionClasses) {\r\n value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(' ');\r\n }\r\n if (value == null) {\r\n el.removeAttribute('class');\r\n }\r\n else if (isSVG) {\r\n el.setAttribute('class', value);\r\n }\r\n else {\r\n el.className = value;\r\n }\r\n}\n\nfunction patchStyle(el, prev, next) {\r\n const style = el.style;\r\n const isCssString = isString(next);\r\n if (next && !isCssString) {\r\n for (const key in next) {\r\n setStyle(style, key, next[key]);\r\n }\r\n if (prev && !isString(prev)) {\r\n for (const key in prev) {\r\n if (next[key] == null) {\r\n setStyle(style, key, '');\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n const currentDisplay = style.display;\r\n if (isCssString) {\r\n if (prev !== next) {\r\n style.cssText = next;\r\n }\r\n }\r\n else if (prev) {\r\n el.removeAttribute('style');\r\n }\r\n // indicates that the `display` of the element is controlled by `v-show`,\r\n // so we always keep the current `display` value regardless of the `style`\r\n // value, thus handing over control to `v-show`.\r\n if ('_vod' in el) {\r\n style.display = currentDisplay;\r\n }\r\n }\r\n}\r\nconst importantRE = /\\s*!important$/;\r\nfunction setStyle(style, name, val) {\r\n if (isArray(val)) {\r\n val.forEach(v => setStyle(style, name, v));\r\n }\r\n else {\r\n if (name.startsWith('--')) {\r\n // custom property definition\r\n style.setProperty(name, val);\r\n }\r\n else {\r\n const prefixed = autoPrefix(style, name);\r\n if (importantRE.test(val)) {\r\n // !important\r\n style.setProperty(hyphenate(prefixed), val.replace(importantRE, ''), 'important');\r\n }\r\n else {\r\n style[prefixed] = val;\r\n }\r\n }\r\n }\r\n}\r\nconst prefixes = ['Webkit', 'Moz', 'ms'];\r\nconst prefixCache = {};\r\nfunction autoPrefix(style, rawName) {\r\n const cached = prefixCache[rawName];\r\n if (cached) {\r\n return cached;\r\n }\r\n let name = camelize(rawName);\r\n if (name !== 'filter' && name in style) {\r\n return (prefixCache[rawName] = name);\r\n }\r\n name = capitalize(name);\r\n for (let i = 0; i < prefixes.length; i++) {\r\n const prefixed = prefixes[i] + name;\r\n if (prefixed in style) {\r\n return (prefixCache[rawName] = prefixed);\r\n }\r\n }\r\n return rawName;\r\n}\n\nconst xlinkNS = 'http://www.w3.org/1999/xlink';\r\nfunction patchAttr(el, key, value, isSVG, instance) {\r\n if (isSVG && key.startsWith('xlink:')) {\r\n if (value == null) {\r\n el.removeAttributeNS(xlinkNS, key.slice(6, key.length));\r\n }\r\n else {\r\n el.setAttributeNS(xlinkNS, key, value);\r\n }\r\n }\r\n else {\r\n // note we are only checking boolean attributes that don't have a\r\n // corresponding dom prop of the same name here.\r\n const isBoolean = isSpecialBooleanAttr(key);\r\n if (value == null || (isBoolean && !includeBooleanAttr(value))) {\r\n el.removeAttribute(key);\r\n }\r\n else {\r\n el.setAttribute(key, isBoolean ? '' : value);\r\n }\r\n }\r\n}\n\n// __UNSAFE__\r\n// functions. The user is responsible for using them with only trusted content.\r\nfunction patchDOMProp(el, key, value, \r\n// the following args are passed only due to potential innerHTML/textContent\r\n// overriding existing VNodes, in which case the old tree must be properly\r\n// unmounted.\r\nprevChildren, parentComponent, parentSuspense, unmountChildren) {\r\n if (key === 'innerHTML' || key === 'textContent') {\r\n if (prevChildren) {\r\n unmountChildren(prevChildren, parentComponent, parentSuspense);\r\n }\r\n el[key] = value == null ? '' : value;\r\n return;\r\n }\r\n if (key === 'value' &&\r\n el.tagName !== 'PROGRESS' &&\r\n // custom elements may use _value internally\r\n !el.tagName.includes('-')) {\r\n // store value as _value as well since\r\n // non-string values will be stringified.\r\n el._value = value;\r\n const newValue = value == null ? '' : value;\r\n if (el.value !== newValue ||\r\n // #4956: always set for OPTION elements because its value falls back to\r\n // textContent if no value attribute is present. And setting .value for\r\n // OPTION has no side effect\r\n el.tagName === 'OPTION') {\r\n el.value = newValue;\r\n }\r\n if (value == null) {\r\n el.removeAttribute(key);\r\n }\r\n return;\r\n }\r\n if (value === '' || value == null) {\r\n const type = typeof el[key];\r\n if (type === 'boolean') {\r\n // e.g. <select multiple> compiles to { multiple: '' }\r\n el[key] = includeBooleanAttr(value);\r\n return;\r\n }\r\n else if (value == null && type === 'string') {\r\n // e.g. <div :id=\"null\">\r\n el[key] = '';\r\n el.removeAttribute(key);\r\n return;\r\n }\r\n else if (type === 'number') {\r\n // e.g. <img :width=\"null\">\r\n // the value of some IDL attr must be greater than 0, e.g. input.size = 0 -> error\r\n try {\r\n el[key] = 0;\r\n }\r\n catch (_a) { }\r\n el.removeAttribute(key);\r\n return;\r\n }\r\n }\r\n // some properties perform value validation and throw\r\n try {\r\n el[key] = value;\r\n }\r\n catch (e) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Failed setting prop \"${key}\" on <${el.tagName.toLowerCase()}>: ` +\r\n `value ${value} is invalid.`, e);\r\n }\r\n }\r\n}\n\n// Async edge case fix requires storing an event listener's attach timestamp.\r\nlet _getNow = Date.now;\r\nlet skipTimestampCheck = false;\r\nif (typeof window !== 'undefined') {\r\n // Determine what event timestamp the browser is using. Annoyingly, the\r\n // timestamp can either be hi-res (relative to page load) or low-res\r\n // (relative to UNIX epoch), so in order to compare time we have to use the\r\n // same timestamp type when saving the flush timestamp.\r\n if (_getNow() > document.createEvent('Event').timeStamp) {\r\n // if the low-res timestamp which is bigger than the event timestamp\r\n // (which is evaluated AFTER) it means the event is using a hi-res timestamp,\r\n // and we need to use the hi-res version for event listeners as well.\r\n _getNow = () => performance.now();\r\n }\r\n // #3485: Firefox <= 53 has incorrect Event.timeStamp implementation\r\n // and does not fire microtasks in between event propagation, so safe to exclude.\r\n const ffMatch = navigator.userAgent.match(/firefox\\/(\\d+)/i);\r\n skipTimestampCheck = !!(ffMatch && Number(ffMatch[1]) <= 53);\r\n}\r\n// To avoid the overhead of repeatedly calling performance.now(), we cache\r\n// and use the same timestamp for all event listeners attached in the same tick.\r\nlet cachedNow = 0;\r\nconst p = Promise.resolve();\r\nconst reset = () => {\r\n cachedNow = 0;\r\n};\r\nconst getNow = () => cachedNow || (p.then(reset), (cachedNow = _getNow()));\r\nfunction addEventListener(el, event, handler, options) {\r\n el.addEventListener(event, handler, options);\r\n}\r\nfunction removeEventListener(el, event, handler, options) {\r\n el.removeEventListener(event, handler, options);\r\n}\r\nfunction patchEvent(el, rawName, prevValue, nextValue, instance = null) {\r\n // vei = vue event invokers\r\n const invokers = el._vei || (el._vei = {});\r\n const existingInvoker = invokers[rawName];\r\n if (nextValue && existingInvoker) {\r\n // patch\r\n existingInvoker.value = nextValue;\r\n }\r\n else {\r\n const [name, options] = parseName(rawName);\r\n if (nextValue) {\r\n // add\r\n const invoker = (invokers[rawName] = createInvoker(nextValue, instance));\r\n addEventListener(el, name, invoker, options);\r\n }\r\n else if (existingInvoker) {\r\n // remove\r\n removeEventListener(el, name, existingInvoker, options);\r\n invokers[rawName] = undefined;\r\n }\r\n }\r\n}\r\nconst optionsModifierRE = /(?:Once|Passive|Capture)$/;\r\nfunction parseName(name) {\r\n let options;\r\n if (optionsModifierRE.test(name)) {\r\n options = {};\r\n let m;\r\n while ((m = name.match(optionsModifierRE))) {\r\n name = name.slice(0, name.length - m[0].length);\r\n options[m[0].toLowerCase()] = true;\r\n }\r\n }\r\n return [hyphenate(name.slice(2)), options];\r\n}\r\nfunction createInvoker(initialValue, instance) {\r\n const invoker = (e) => {\r\n // async edge case #6566: inner click event triggers patch, event handler\r\n // attached to outer element during patch, and triggered again. This\r\n // happens because browsers fire microtask ticks between event propagation.\r\n // the solution is simple: we save the timestamp when a handler is attached,\r\n // and the handler would only fire if the event passed to it was fired\r\n // AFTER it was attached.\r\n const timeStamp = e.timeStamp || _getNow();\r\n if (skipTimestampCheck || timeStamp >= invoker.attached - 1) {\r\n callWithAsyncErrorHandling(patchStopImmediatePropagation(e, invoker.value), instance, 5 /* NATIVE_EVENT_HANDLER */, [e]);\r\n }\r\n };\r\n invoker.value = initialValue;\r\n invoker.attached = getNow();\r\n return invoker;\r\n}\r\nfunction patchStopImmediatePropagation(e, value) {\r\n if (isArray(value)) {\r\n const originalStop = e.stopImmediatePropagation;\r\n e.stopImmediatePropagation = () => {\r\n originalStop.call(e);\r\n e._stopped = true;\r\n };\r\n return value.map(fn => (e) => !e._stopped && fn(e));\r\n }\r\n else {\r\n return value;\r\n }\r\n}\n\nconst nativeOnRE = /^on[a-z]/;\r\nconst patchProp = (el, key, prevValue, nextValue, isSVG = false, prevChildren, parentComponent, parentSuspense, unmountChildren) => {\r\n if (key === 'class') {\r\n patchClass(el, nextValue, isSVG);\r\n }\r\n else if (key === 'style') {\r\n patchStyle(el, prevValue, nextValue);\r\n }\r\n else if (isOn(key)) {\r\n // ignore v-model listeners\r\n if (!isModelListener(key)) {\r\n patchEvent(el, key, prevValue, nextValue, parentComponent);\r\n }\r\n }\r\n else if (key[0] === '.'\r\n ? ((key = key.slice(1)), true)\r\n : key[0] === '^'\r\n ? ((key = key.slice(1)), false)\r\n : shouldSetAsProp(el, key, nextValue, isSVG)) {\r\n patchDOMProp(el, key, nextValue, prevChildren, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n else {\r\n // special case for <input v-model type=\"checkbox\"> with\r\n // :true-value & :false-value\r\n // store value as dom properties since non-string values will be\r\n // stringified.\r\n if (key === 'true-value') {\r\n el._trueValue = nextValue;\r\n }\r\n else if (key === 'false-value') {\r\n el._falseValue = nextValue;\r\n }\r\n patchAttr(el, key, nextValue, isSVG);\r\n }\r\n};\r\nfunction shouldSetAsProp(el, key, value, isSVG) {\r\n if (isSVG) {\r\n // most keys must be set as attribute on svg elements to work\r\n // ...except innerHTML & textContent\r\n if (key === 'innerHTML' || key === 'textContent') {\r\n return true;\r\n }\r\n // or native onclick with function values\r\n if (key in el && nativeOnRE.test(key) && isFunction(value)) {\r\n return true;\r\n }\r\n return false;\r\n }\r\n // spellcheck and draggable are numerated attrs, however their\r\n // corresponding DOM properties are actually booleans - this leads to\r\n // setting it with a string \"false\" value leading it to be coerced to\r\n // `true`, so we need to always treat them as attributes.\r\n // Note that `contentEditable` doesn't have this problem: its DOM\r\n // property is also enumerated string values.\r\n if (key === 'spellcheck' || key === 'draggable') {\r\n return false;\r\n }\r\n // #1787, #2840 form property on form elements is readonly and must be set as\r\n // attribute.\r\n if (key === 'form') {\r\n return false;\r\n }\r\n // #1526 <input list> must be set as attribute\r\n if (key === 'list' && el.tagName === 'INPUT') {\r\n return false;\r\n }\r\n // #2766 <textarea type> must be set as attribute\r\n if (key === 'type' && el.tagName === 'TEXTAREA') {\r\n return false;\r\n }\r\n // native onclick with string value, must be set as attribute\r\n if (nativeOnRE.test(key) && isString(value)) {\r\n return false;\r\n }\r\n return key in el;\r\n}\n\nfunction defineCustomElement(options, hydate) {\r\n const Comp = defineComponent(options);\r\n class VueCustomElement extends VueElement {\r\n constructor(initialProps) {\r\n super(Comp, initialProps, hydate);\r\n }\r\n }\r\n VueCustomElement.def = Comp;\r\n return VueCustomElement;\r\n}\r\nconst defineSSRCustomElement = ((options) => {\r\n // @ts-ignore\r\n return defineCustomElement(options, hydrate);\r\n});\r\nconst BaseClass = (typeof HTMLElement !== 'undefined' ? HTMLElement : class {\r\n});\r\nclass VueElement extends BaseClass {\r\n constructor(_def, _props = {}, hydrate) {\r\n super();\r\n this._def = _def;\r\n this._props = _props;\r\n /**\r\n * @internal\r\n */\r\n this._instance = null;\r\n this._connected = false;\r\n this._resolved = false;\r\n this._numberProps = null;\r\n if (this.shadowRoot && hydrate) {\r\n hydrate(this._createVNode(), this.shadowRoot);\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && this.shadowRoot) {\r\n warn(`Custom element has pre-rendered declarative shadow root but is not ` +\r\n `defined as hydratable. Use \\`defineSSRCustomElement\\`.`);\r\n }\r\n this.attachShadow({ mode: 'open' });\r\n }\r\n }\r\n connectedCallback() {\r\n this._connected = true;\r\n if (!this._instance) {\r\n this._resolveDef();\r\n }\r\n }\r\n disconnectedCallback() {\r\n this._connected = false;\r\n nextTick(() => {\r\n if (!this._connected) {\r\n render(null, this.shadowRoot);\r\n this._instance = null;\r\n }\r\n });\r\n }\r\n /**\r\n * resolve inner component definition (handle possible async component)\r\n */\r\n _resolveDef() {\r\n if (this._resolved) {\r\n return;\r\n }\r\n this._resolved = true;\r\n // set initial attrs\r\n for (let i = 0; i < this.attributes.length; i++) {\r\n this._setAttr(this.attributes[i].name);\r\n }\r\n // watch future attr changes\r\n new MutationObserver(mutations => {\r\n for (const m of mutations) {\r\n this._setAttr(m.attributeName);\r\n }\r\n }).observe(this, { attributes: true });\r\n const resolve = (def) => {\r\n const { props, styles } = def;\r\n const hasOptions = !isArray(props);\r\n const rawKeys = props ? (hasOptions ? Object.keys(props) : props) : [];\r\n // cast Number-type props set before resolve\r\n let numberProps;\r\n if (hasOptions) {\r\n for (const key in this._props) {\r\n const opt = props[key];\r\n if (opt === Number || (opt && opt.type === Number)) {\r\n this._props[key] = toNumber(this._props[key]);\r\n (numberProps || (numberProps = Object.create(null)))[key] = true;\r\n }\r\n }\r\n }\r\n this._numberProps = numberProps;\r\n // check if there are props set pre-upgrade or connect\r\n for (const key of Object.keys(this)) {\r\n if (key[0] !== '_') {\r\n this._setProp(key, this[key], true, false);\r\n }\r\n }\r\n // defining getter/setters on prototype\r\n for (const key of rawKeys.map(camelize$1)) {\r\n Object.defineProperty(this, key, {\r\n get() {\r\n return this._getProp(key);\r\n },\r\n set(val) {\r\n this._setProp(key, val);\r\n }\r\n });\r\n }\r\n // apply CSS\r\n this._applyStyles(styles);\r\n // initial render\r\n this._update();\r\n };\r\n const asyncDef = this._def.__asyncLoader;\r\n if (asyncDef) {\r\n asyncDef().then(resolve);\r\n }\r\n else {\r\n resolve(this._def);\r\n }\r\n }\r\n _setAttr(key) {\r\n let value = this.getAttribute(key);\r\n if (this._numberProps && this._numberProps[key]) {\r\n value = toNumber(value);\r\n }\r\n this._setProp(camelize$1(key), value, false);\r\n }\r\n /**\r\n * @internal\r\n */\r\n _getProp(key) {\r\n return this._props[key];\r\n }\r\n /**\r\n * @internal\r\n */\r\n _setProp(key, val, shouldReflect = true, shouldUpdate = true) {\r\n if (val !== this._props[key]) {\r\n this._props[key] = val;\r\n if (shouldUpdate && this._instance) {\r\n this._update();\r\n }\r\n // reflect\r\n if (shouldReflect) {\r\n if (val === true) {\r\n this.setAttribute(hyphenate(key), '');\r\n }\r\n else if (typeof val === 'string' || typeof val === 'number') {\r\n this.setAttribute(hyphenate(key), val + '');\r\n }\r\n else if (!val) {\r\n this.removeAttribute(hyphenate(key));\r\n }\r\n }\r\n }\r\n }\r\n _update() {\r\n render(this._createVNode(), this.shadowRoot);\r\n }\r\n _createVNode() {\r\n const vnode = createVNode(this._def, extend({}, this._props));\r\n if (!this._instance) {\r\n vnode.ce = instance => {\r\n this._instance = instance;\r\n instance.isCE = true;\r\n // HMR\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n instance.ceReload = newStyles => {\r\n // always reset styles\r\n if (this._styles) {\r\n this._styles.forEach(s => this.shadowRoot.removeChild(s));\r\n this._styles.length = 0;\r\n }\r\n this._applyStyles(newStyles);\r\n // if this is an async component, ceReload is called from the inner\r\n // component so no need to reload the async wrapper\r\n if (!this._def.__asyncLoader) {\r\n // reload\r\n this._instance = null;\r\n this._update();\r\n }\r\n };\r\n }\r\n // intercept emit\r\n instance.emit = (event, ...args) => {\r\n this.dispatchEvent(new CustomEvent(event, {\r\n detail: args\r\n }));\r\n };\r\n // locate nearest Vue custom element parent for provide/inject\r\n let parent = this;\r\n while ((parent =\r\n parent && (parent.parentNode || parent.host))) {\r\n if (parent instanceof VueElement) {\r\n instance.parent = parent._instance;\r\n break;\r\n }\r\n }\r\n };\r\n }\r\n return vnode;\r\n }\r\n _applyStyles(styles) {\r\n if (styles) {\r\n styles.forEach(css => {\r\n const s = document.createElement('style');\r\n s.textContent = css;\r\n this.shadowRoot.appendChild(s);\r\n // record for HMR\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n (this._styles || (this._styles = [])).push(s);\r\n }\r\n });\r\n }\r\n }\r\n}\n\nfunction useCssModule(name = '$style') {\r\n /* istanbul ignore else */\r\n {\r\n const instance = getCurrentInstance();\r\n if (!instance) {\r\n (process.env.NODE_ENV !== 'production') && warn(`useCssModule must be called inside setup()`);\r\n return EMPTY_OBJ;\r\n }\r\n const modules = instance.type.__cssModules;\r\n if (!modules) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Current instance does not have CSS modules injected.`);\r\n return EMPTY_OBJ;\r\n }\r\n const mod = modules[name];\r\n if (!mod) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Current instance does not have CSS module named \"${name}\".`);\r\n return EMPTY_OBJ;\r\n }\r\n return mod;\r\n }\r\n}\n\n/**\r\n * Runtime helper for SFC's CSS variable injection feature.\r\n * @private\r\n */\r\nfunction useCssVars(getter) {\r\n const instance = getCurrentInstance();\r\n /* istanbul ignore next */\r\n if (!instance) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`useCssVars is called without current active component instance.`);\r\n return;\r\n }\r\n const setVars = () => setVarsOnVNode(instance.subTree, getter(instance.proxy));\r\n watchPostEffect(setVars);\r\n onMounted(() => {\r\n const ob = new MutationObserver(setVars);\r\n ob.observe(instance.subTree.el.parentNode, { childList: true });\r\n onUnmounted(() => ob.disconnect());\r\n });\r\n}\r\nfunction setVarsOnVNode(vnode, vars) {\r\n if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n const suspense = vnode.suspense;\r\n vnode = suspense.activeBranch;\r\n if (suspense.pendingBranch && !suspense.isHydrating) {\r\n suspense.effects.push(() => {\r\n setVarsOnVNode(suspense.activeBranch, vars);\r\n });\r\n }\r\n }\r\n // drill down HOCs until it's a non-component vnode\r\n while (vnode.component) {\r\n vnode = vnode.component.subTree;\r\n }\r\n if (vnode.shapeFlag & 1 /* ELEMENT */ && vnode.el) {\r\n setVarsOnNode(vnode.el, vars);\r\n }\r\n else if (vnode.type === Fragment) {\r\n vnode.children.forEach(c => setVarsOnVNode(c, vars));\r\n }\r\n else if (vnode.type === Static) {\r\n let { el, anchor } = vnode;\r\n while (el) {\r\n setVarsOnNode(el, vars);\r\n if (el === anchor)\r\n break;\r\n el = el.nextSibling;\r\n }\r\n }\r\n}\r\nfunction setVarsOnNode(el, vars) {\r\n if (el.nodeType === 1) {\r\n const style = el.style;\r\n for (const key in vars) {\r\n style.setProperty(`--${key}`, vars[key]);\r\n }\r\n }\r\n}\n\nconst TRANSITION = 'transition';\r\nconst ANIMATION = 'animation';\r\n// DOM Transition is a higher-order-component based on the platform-agnostic\r\n// base Transition component, with DOM-specific logic.\r\nconst Transition = (props, { slots }) => h(BaseTransition, resolveTransitionProps(props), slots);\r\nTransition.displayName = 'Transition';\r\nconst DOMTransitionPropsValidators = {\r\n name: String,\r\n type: String,\r\n css: {\r\n type: Boolean,\r\n default: true\r\n },\r\n duration: [String, Number, Object],\r\n enterFromClass: String,\r\n enterActiveClass: String,\r\n enterToClass: String,\r\n appearFromClass: String,\r\n appearActiveClass: String,\r\n appearToClass: String,\r\n leaveFromClass: String,\r\n leaveActiveClass: String,\r\n leaveToClass: String\r\n};\r\nconst TransitionPropsValidators = (Transition.props =\r\n /*#__PURE__*/ extend({}, BaseTransition.props, DOMTransitionPropsValidators));\r\n/**\r\n * #3227 Incoming hooks may be merged into arrays when wrapping Transition\r\n * with custom HOCs.\r\n */\r\nconst callHook = (hook, args = []) => {\r\n if (isArray(hook)) {\r\n hook.forEach(h => h(...args));\r\n }\r\n else if (hook) {\r\n hook(...args);\r\n }\r\n};\r\n/**\r\n * Check if a hook expects a callback (2nd arg), which means the user\r\n * intends to explicitly control the end of the transition.\r\n */\r\nconst hasExplicitCallback = (hook) => {\r\n return hook\r\n ? isArray(hook)\r\n ? hook.some(h => h.length > 1)\r\n : hook.length > 1\r\n : false;\r\n};\r\nfunction resolveTransitionProps(rawProps) {\r\n const baseProps = {};\r\n for (const key in rawProps) {\r\n if (!(key in DOMTransitionPropsValidators)) {\r\n baseProps[key] = rawProps[key];\r\n }\r\n }\r\n if (rawProps.css === false) {\r\n return baseProps;\r\n }\r\n const { name = 'v', type, duration, enterFromClass = `${name}-enter-from`, enterActiveClass = `${name}-enter-active`, enterToClass = `${name}-enter-to`, appearFromClass = enterFromClass, appearActiveClass = enterActiveClass, appearToClass = enterToClass, leaveFromClass = `${name}-leave-from`, leaveActiveClass = `${name}-leave-active`, leaveToClass = `${name}-leave-to` } = rawProps;\r\n const durations = normalizeDuration(duration);\r\n const enterDuration = durations && durations[0];\r\n const leaveDuration = durations && durations[1];\r\n const { onBeforeEnter, onEnter, onEnterCancelled, onLeave, onLeaveCancelled, onBeforeAppear = onBeforeEnter, onAppear = onEnter, onAppearCancelled = onEnterCancelled } = baseProps;\r\n const finishEnter = (el, isAppear, done) => {\r\n removeTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);\r\n done && done();\r\n };\r\n const finishLeave = (el, done) => {\r\n removeTransitionClass(el, leaveToClass);\r\n removeTransitionClass(el, leaveActiveClass);\r\n done && done();\r\n };\r\n const makeEnterHook = (isAppear) => {\r\n return (el, done) => {\r\n const hook = isAppear ? onAppear : onEnter;\r\n const resolve = () => finishEnter(el, isAppear, done);\r\n callHook(hook, [el, resolve]);\r\n nextFrame(() => {\r\n removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);\r\n addTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n if (!hasExplicitCallback(hook)) {\r\n whenTransitionEnds(el, type, enterDuration, resolve);\r\n }\r\n });\r\n };\r\n };\r\n return extend(baseProps, {\r\n onBeforeEnter(el) {\r\n callHook(onBeforeEnter, [el]);\r\n addTransitionClass(el, enterFromClass);\r\n addTransitionClass(el, enterActiveClass);\r\n },\r\n onBeforeAppear(el) {\r\n callHook(onBeforeAppear, [el]);\r\n addTransitionClass(el, appearFromClass);\r\n addTransitionClass(el, appearActiveClass);\r\n },\r\n onEnter: makeEnterHook(false),\r\n onAppear: makeEnterHook(true),\r\n onLeave(el, done) {\r\n const resolve = () => finishLeave(el, done);\r\n addTransitionClass(el, leaveFromClass);\r\n // force reflow so *-leave-from classes immediately take effect (#2593)\r\n forceReflow();\r\n addTransitionClass(el, leaveActiveClass);\r\n nextFrame(() => {\r\n removeTransitionClass(el, leaveFromClass);\r\n addTransitionClass(el, leaveToClass);\r\n if (!hasExplicitCallback(onLeave)) {\r\n whenTransitionEnds(el, type, leaveDuration, resolve);\r\n }\r\n });\r\n callHook(onLeave, [el, resolve]);\r\n },\r\n onEnterCancelled(el) {\r\n finishEnter(el, false);\r\n callHook(onEnterCancelled, [el]);\r\n },\r\n onAppearCancelled(el) {\r\n finishEnter(el, true);\r\n callHook(onAppearCancelled, [el]);\r\n },\r\n onLeaveCancelled(el) {\r\n finishLeave(el);\r\n callHook(onLeaveCancelled, [el]);\r\n }\r\n });\r\n}\r\nfunction normalizeDuration(duration) {\r\n if (duration == null) {\r\n return null;\r\n }\r\n else if (isObject(duration)) {\r\n return [NumberOf(duration.enter), NumberOf(duration.leave)];\r\n }\r\n else {\r\n const n = NumberOf(duration);\r\n return [n, n];\r\n }\r\n}\r\nfunction NumberOf(val) {\r\n const res = toNumber(val);\r\n if ((process.env.NODE_ENV !== 'production'))\r\n validateDuration(res);\r\n return res;\r\n}\r\nfunction validateDuration(val) {\r\n if (typeof val !== 'number') {\r\n warn(`<transition> explicit duration is not a valid number - ` +\r\n `got ${JSON.stringify(val)}.`);\r\n }\r\n else if (isNaN(val)) {\r\n warn(`<transition> explicit duration is NaN - ` +\r\n 'the duration expression might be incorrect.');\r\n }\r\n}\r\nfunction addTransitionClass(el, cls) {\r\n cls.split(/\\s+/).forEach(c => c && el.classList.add(c));\r\n (el._vtc ||\r\n (el._vtc = new Set())).add(cls);\r\n}\r\nfunction removeTransitionClass(el, cls) {\r\n cls.split(/\\s+/).forEach(c => c && el.classList.remove(c));\r\n const { _vtc } = el;\r\n if (_vtc) {\r\n _vtc.delete(cls);\r\n if (!_vtc.size) {\r\n el._vtc = undefined;\r\n }\r\n }\r\n}\r\nfunction nextFrame(cb) {\r\n requestAnimationFrame(() => {\r\n requestAnimationFrame(cb);\r\n });\r\n}\r\nlet endId = 0;\r\nfunction whenTransitionEnds(el, expectedType, explicitTimeout, resolve) {\r\n const id = (el._endId = ++endId);\r\n const resolveIfNotStale = () => {\r\n if (id === el._endId) {\r\n resolve();\r\n }\r\n };\r\n if (explicitTimeout) {\r\n return setTimeout(resolveIfNotStale, explicitTimeout);\r\n }\r\n const { type, timeout, propCount } = getTransitionInfo(el, expectedType);\r\n if (!type) {\r\n return resolve();\r\n }\r\n const endEvent = type + 'end';\r\n let ended = 0;\r\n const end = () => {\r\n el.removeEventListener(endEvent, onEnd);\r\n resolveIfNotStale();\r\n };\r\n const onEnd = (e) => {\r\n if (e.target === el && ++ended >= propCount) {\r\n end();\r\n }\r\n };\r\n setTimeout(() => {\r\n if (ended < propCount) {\r\n end();\r\n }\r\n }, timeout + 1);\r\n el.addEventListener(endEvent, onEnd);\r\n}\r\nfunction getTransitionInfo(el, expectedType) {\r\n const styles = window.getComputedStyle(el);\r\n // JSDOM may return undefined for transition properties\r\n const getStyleProperties = (key) => (styles[key] || '').split(', ');\r\n const transitionDelays = getStyleProperties(TRANSITION + 'Delay');\r\n const transitionDurations = getStyleProperties(TRANSITION + 'Duration');\r\n const transitionTimeout = getTimeout(transitionDelays, transitionDurations);\r\n const animationDelays = getStyleProperties(ANIMATION + 'Delay');\r\n const animationDurations = getStyleProperties(ANIMATION + 'Duration');\r\n const animationTimeout = getTimeout(animationDelays, animationDurations);\r\n let type = null;\r\n let timeout = 0;\r\n let propCount = 0;\r\n /* istanbul ignore if */\r\n if (expectedType === TRANSITION) {\r\n if (transitionTimeout > 0) {\r\n type = TRANSITION;\r\n timeout = transitionTimeout;\r\n propCount = transitionDurations.length;\r\n }\r\n }\r\n else if (expectedType === ANIMATION) {\r\n if (animationTimeout > 0) {\r\n type = ANIMATION;\r\n timeout = animationTimeout;\r\n propCount = animationDurations.length;\r\n }\r\n }\r\n else {\r\n timeout = Math.max(transitionTimeout, animationTimeout);\r\n type =\r\n timeout > 0\r\n ? transitionTimeout > animationTimeout\r\n ? TRANSITION\r\n : ANIMATION\r\n : null;\r\n propCount = type\r\n ? type === TRANSITION\r\n ? transitionDurations.length\r\n : animationDurations.length\r\n : 0;\r\n }\r\n const hasTransform = type === TRANSITION &&\r\n /\\b(transform|all)(,|$)/.test(styles[TRANSITION + 'Property']);\r\n return {\r\n type,\r\n timeout,\r\n propCount,\r\n hasTransform\r\n };\r\n}\r\nfunction getTimeout(delays, durations) {\r\n while (delays.length < durations.length) {\r\n delays = delays.concat(delays);\r\n }\r\n return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));\r\n}\r\n// Old versions of Chromium (below 61.0.3163.100) formats floating pointer\r\n// numbers in a locale-dependent way, using a comma instead of a dot.\r\n// If comma is not replaced with a dot, the input will be rounded down\r\n// (i.e. acting as a floor function) causing unexpected behaviors\r\nfunction toMs(s) {\r\n return Number(s.slice(0, -1).replace(',', '.')) * 1000;\r\n}\r\n// synchronously force layout to put elements into a certain state\r\nfunction forceReflow() {\r\n return document.body.offsetHeight;\r\n}\n\nconst positionMap = new WeakMap();\r\nconst newPositionMap = new WeakMap();\r\nconst TransitionGroupImpl = {\r\n name: 'TransitionGroup',\r\n props: /*#__PURE__*/ extend({}, TransitionPropsValidators, {\r\n tag: String,\r\n moveClass: String\r\n }),\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n const state = useTransitionState();\r\n let prevChildren;\r\n let children;\r\n onUpdated(() => {\r\n // children is guaranteed to exist after initial render\r\n if (!prevChildren.length) {\r\n return;\r\n }\r\n const moveClass = props.moveClass || `${props.name || 'v'}-move`;\r\n if (!hasCSSTransform(prevChildren[0].el, instance.vnode.el, moveClass)) {\r\n return;\r\n }\r\n // we divide the work into three loops to avoid mixing DOM reads and writes\r\n // in each iteration - which helps prevent layout thrashing.\r\n prevChildren.forEach(callPendingCbs);\r\n prevChildren.forEach(recordPosition);\r\n const movedChildren = prevChildren.filter(applyTranslation);\r\n // force reflow to put everything in position\r\n forceReflow();\r\n movedChildren.forEach(c => {\r\n const el = c.el;\r\n const style = el.style;\r\n addTransitionClass(el, moveClass);\r\n style.transform = style.webkitTransform = style.transitionDuration = '';\r\n const cb = (el._moveCb = (e) => {\r\n if (e && e.target !== el) {\r\n return;\r\n }\r\n if (!e || /transform$/.test(e.propertyName)) {\r\n el.removeEventListener('transitionend', cb);\r\n el._moveCb = null;\r\n removeTransitionClass(el, moveClass);\r\n }\r\n });\r\n el.addEventListener('transitionend', cb);\r\n });\r\n });\r\n return () => {\r\n const rawProps = toRaw(props);\r\n const cssTransitionProps = resolveTransitionProps(rawProps);\r\n let tag = rawProps.tag || Fragment;\r\n prevChildren = children;\r\n children = slots.default ? getTransitionRawChildren(slots.default()) : [];\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (child.key != null) {\r\n setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`<TransitionGroup> children must be keyed.`);\r\n }\r\n }\r\n if (prevChildren) {\r\n for (let i = 0; i < prevChildren.length; i++) {\r\n const child = prevChildren[i];\r\n setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n positionMap.set(child, child.el.getBoundingClientRect());\r\n }\r\n }\r\n return createVNode(tag, null, children);\r\n };\r\n }\r\n};\r\nconst TransitionGroup = TransitionGroupImpl;\r\nfunction callPendingCbs(c) {\r\n const el = c.el;\r\n if (el._moveCb) {\r\n el._moveCb();\r\n }\r\n if (el._enterCb) {\r\n el._enterCb();\r\n }\r\n}\r\nfunction recordPosition(c) {\r\n newPositionMap.set(c, c.el.getBoundingClientRect());\r\n}\r\nfunction applyTranslation(c) {\r\n const oldPos = positionMap.get(c);\r\n const newPos = newPositionMap.get(c);\r\n const dx = oldPos.left - newPos.left;\r\n const dy = oldPos.top - newPos.top;\r\n if (dx || dy) {\r\n const s = c.el.style;\r\n s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;\r\n s.transitionDuration = '0s';\r\n return c;\r\n }\r\n}\r\nfunction hasCSSTransform(el, root, moveClass) {\r\n // Detect whether an element with the move class applied has\r\n // CSS transitions. Since the element may be inside an entering\r\n // transition at this very moment, we make a clone of it and remove\r\n // all other transition classes applied to ensure only the move class\r\n // is applied.\r\n const clone = el.cloneNode();\r\n if (el._vtc) {\r\n el._vtc.forEach(cls => {\r\n cls.split(/\\s+/).forEach(c => c && clone.classList.remove(c));\r\n });\r\n }\r\n moveClass.split(/\\s+/).forEach(c => c && clone.classList.add(c));\r\n clone.style.display = 'none';\r\n const container = (root.nodeType === 1 ? root : root.parentNode);\r\n container.appendChild(clone);\r\n const { hasTransform } = getTransitionInfo(clone);\r\n container.removeChild(clone);\r\n return hasTransform;\r\n}\n\nconst getModelAssigner = (vnode) => {\r\n const fn = vnode.props['onUpdate:modelValue'];\r\n return isArray(fn) ? value => invokeArrayFns(fn, value) : fn;\r\n};\r\nfunction onCompositionStart(e) {\r\n e.target.composing = true;\r\n}\r\nfunction onCompositionEnd(e) {\r\n const target = e.target;\r\n if (target.composing) {\r\n target.composing = false;\r\n trigger(target, 'input');\r\n }\r\n}\r\nfunction trigger(el, type) {\r\n const e = document.createEvent('HTMLEvents');\r\n e.initEvent(type, true, true);\r\n el.dispatchEvent(e);\r\n}\r\n// We are exporting the v-model runtime directly as vnode hooks so that it can\r\n// be tree-shaken in case v-model is never used.\r\nconst vModelText = {\r\n created(el, { modifiers: { lazy, trim, number } }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n const castToNumber = number || (vnode.props && vnode.props.type === 'number');\r\n addEventListener(el, lazy ? 'change' : 'input', e => {\r\n if (e.target.composing)\r\n return;\r\n let domValue = el.value;\r\n if (trim) {\r\n domValue = domValue.trim();\r\n }\r\n else if (castToNumber) {\r\n domValue = toNumber(domValue);\r\n }\r\n el._assign(domValue);\r\n });\r\n if (trim) {\r\n addEventListener(el, 'change', () => {\r\n el.value = el.value.trim();\r\n });\r\n }\r\n if (!lazy) {\r\n addEventListener(el, 'compositionstart', onCompositionStart);\r\n addEventListener(el, 'compositionend', onCompositionEnd);\r\n // Safari < 10.2 & UIWebView doesn't fire compositionend when\r\n // switching focus before confirming composition choice\r\n // this also fixes the issue where some browsers e.g. iOS Chrome\r\n // fires \"change\" instead of \"input\" on autocomplete.\r\n addEventListener(el, 'change', onCompositionEnd);\r\n }\r\n },\r\n // set value on mounted so it's after min/max for type=\"range\"\r\n mounted(el, { value }) {\r\n el.value = value == null ? '' : value;\r\n },\r\n beforeUpdate(el, { value, modifiers: { lazy, trim, number } }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n // avoid clearing unresolved text. #2302\r\n if (el.composing)\r\n return;\r\n if (document.activeElement === el) {\r\n if (lazy) {\r\n return;\r\n }\r\n if (trim && el.value.trim() === value) {\r\n return;\r\n }\r\n if ((number || el.type === 'number') && toNumber(el.value) === value) {\r\n return;\r\n }\r\n }\r\n const newValue = value == null ? '' : value;\r\n if (el.value !== newValue) {\r\n el.value = newValue;\r\n }\r\n }\r\n};\r\nconst vModelCheckbox = {\r\n // #4096 array checkboxes need to be deep traversed\r\n deep: true,\r\n created(el, _, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n addEventListener(el, 'change', () => {\r\n const modelValue = el._modelValue;\r\n const elementValue = getValue(el);\r\n const checked = el.checked;\r\n const assign = el._assign;\r\n if (isArray(modelValue)) {\r\n const index = looseIndexOf(modelValue, elementValue);\r\n const found = index !== -1;\r\n if (checked && !found) {\r\n assign(modelValue.concat(elementValue));\r\n }\r\n else if (!checked && found) {\r\n const filtered = [...modelValue];\r\n filtered.splice(index, 1);\r\n assign(filtered);\r\n }\r\n }\r\n else if (isSet(modelValue)) {\r\n const cloned = new Set(modelValue);\r\n if (checked) {\r\n cloned.add(elementValue);\r\n }\r\n else {\r\n cloned.delete(elementValue);\r\n }\r\n assign(cloned);\r\n }\r\n else {\r\n assign(getCheckboxValue(el, checked));\r\n }\r\n });\r\n },\r\n // set initial checked on mount to wait for true-value/false-value\r\n mounted: setChecked,\r\n beforeUpdate(el, binding, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n setChecked(el, binding, vnode);\r\n }\r\n};\r\nfunction setChecked(el, { value, oldValue }, vnode) {\r\n el._modelValue = value;\r\n if (isArray(value)) {\r\n el.checked = looseIndexOf(value, vnode.props.value) > -1;\r\n }\r\n else if (isSet(value)) {\r\n el.checked = value.has(vnode.props.value);\r\n }\r\n else if (value !== oldValue) {\r\n el.checked = looseEqual(value, getCheckboxValue(el, true));\r\n }\r\n}\r\nconst vModelRadio = {\r\n created(el, { value }, vnode) {\r\n el.checked = looseEqual(value, vnode.props.value);\r\n el._assign = getModelAssigner(vnode);\r\n addEventListener(el, 'change', () => {\r\n el._assign(getValue(el));\r\n });\r\n },\r\n beforeUpdate(el, { value, oldValue }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n if (value !== oldValue) {\r\n el.checked = looseEqual(value, vnode.props.value);\r\n }\r\n }\r\n};\r\nconst vModelSelect = {\r\n // <select multiple> value need to be deep traversed\r\n deep: true,\r\n created(el, { value, modifiers: { number } }, vnode) {\r\n const isSetModel = isSet(value);\r\n addEventListener(el, 'change', () => {\r\n const selectedVal = Array.prototype.filter\r\n .call(el.options, (o) => o.selected)\r\n .map((o) => number ? toNumber(getValue(o)) : getValue(o));\r\n el._assign(el.multiple\r\n ? isSetModel\r\n ? new Set(selectedVal)\r\n : selectedVal\r\n : selectedVal[0]);\r\n });\r\n el._assign = getModelAssigner(vnode);\r\n },\r\n // set value in mounted & updated because <select> relies on its children\r\n // <option>s.\r\n mounted(el, { value }) {\r\n setSelected(el, value);\r\n },\r\n beforeUpdate(el, _binding, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n },\r\n updated(el, { value }) {\r\n setSelected(el, value);\r\n }\r\n};\r\nfunction setSelected(el, value) {\r\n const isMultiple = el.multiple;\r\n if (isMultiple && !isArray(value) && !isSet(value)) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`<select multiple v-model> expects an Array or Set value for its binding, ` +\r\n `but got ${Object.prototype.toString.call(value).slice(8, -1)}.`);\r\n return;\r\n }\r\n for (let i = 0, l = el.options.length; i < l; i++) {\r\n const option = el.options[i];\r\n const optionValue = getValue(option);\r\n if (isMultiple) {\r\n if (isArray(value)) {\r\n option.selected = looseIndexOf(value, optionValue) > -1;\r\n }\r\n else {\r\n option.selected = value.has(optionValue);\r\n }\r\n }\r\n else {\r\n if (looseEqual(getValue(option), value)) {\r\n if (el.selectedIndex !== i)\r\n el.selectedIndex = i;\r\n return;\r\n }\r\n }\r\n }\r\n if (!isMultiple && el.selectedIndex !== -1) {\r\n el.selectedIndex = -1;\r\n }\r\n}\r\n// retrieve raw value set via :value bindings\r\nfunction getValue(el) {\r\n return '_value' in el ? el._value : el.value;\r\n}\r\n// retrieve raw value for true-value and false-value set via :true-value or :false-value bindings\r\nfunction getCheckboxValue(el, checked) {\r\n const key = checked ? '_trueValue' : '_falseValue';\r\n return key in el ? el[key] : checked;\r\n}\r\nconst vModelDynamic = {\r\n created(el, binding, vnode) {\r\n callModelHook(el, binding, vnode, null, 'created');\r\n },\r\n mounted(el, binding, vnode) {\r\n callModelHook(el, binding, vnode, null, 'mounted');\r\n },\r\n beforeUpdate(el, binding, vnode, prevVNode) {\r\n callModelHook(el, binding, vnode, prevVNode, 'beforeUpdate');\r\n },\r\n updated(el, binding, vnode, prevVNode) {\r\n callModelHook(el, binding, vnode, prevVNode, 'updated');\r\n }\r\n};\r\nfunction callModelHook(el, binding, vnode, prevVNode, hook) {\r\n let modelToUse;\r\n switch (el.tagName) {\r\n case 'SELECT':\r\n modelToUse = vModelSelect;\r\n break;\r\n case 'TEXTAREA':\r\n modelToUse = vModelText;\r\n break;\r\n default:\r\n switch (vnode.props && vnode.props.type) {\r\n case 'checkbox':\r\n modelToUse = vModelCheckbox;\r\n break;\r\n case 'radio':\r\n modelToUse = vModelRadio;\r\n break;\r\n default:\r\n modelToUse = vModelText;\r\n }\r\n }\r\n const fn = modelToUse[hook];\r\n fn && fn(el, binding, vnode, prevVNode);\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVModelForSSR() {\r\n vModelText.getSSRProps = ({ value }) => ({ value });\r\n vModelRadio.getSSRProps = ({ value }, vnode) => {\r\n if (vnode.props && looseEqual(vnode.props.value, value)) {\r\n return { checked: true };\r\n }\r\n };\r\n vModelCheckbox.getSSRProps = ({ value }, vnode) => {\r\n if (isArray(value)) {\r\n if (vnode.props && looseIndexOf(value, vnode.props.value) > -1) {\r\n return { checked: true };\r\n }\r\n }\r\n else if (isSet(value)) {\r\n if (vnode.props && value.has(vnode.props.value)) {\r\n return { checked: true };\r\n }\r\n }\r\n else if (value) {\r\n return { checked: true };\r\n }\r\n };\r\n}\n\nconst systemModifiers = ['ctrl', 'shift', 'alt', 'meta'];\r\nconst modifierGuards = {\r\n stop: e => e.stopPropagation(),\r\n prevent: e => e.preventDefault(),\r\n self: e => e.target !== e.currentTarget,\r\n ctrl: e => !e.ctrlKey,\r\n shift: e => !e.shiftKey,\r\n alt: e => !e.altKey,\r\n meta: e => !e.metaKey,\r\n left: e => 'button' in e && e.button !== 0,\r\n middle: e => 'button' in e && e.button !== 1,\r\n right: e => 'button' in e && e.button !== 2,\r\n exact: (e, modifiers) => systemModifiers.some(m => e[`${m}Key`] && !modifiers.includes(m))\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withModifiers = (fn, modifiers) => {\r\n return (event, ...args) => {\r\n for (let i = 0; i < modifiers.length; i++) {\r\n const guard = modifierGuards[modifiers[i]];\r\n if (guard && guard(event, modifiers))\r\n return;\r\n }\r\n return fn(event, ...args);\r\n };\r\n};\r\n// Kept for 2.x compat.\r\n// Note: IE11 compat for `spacebar` and `del` is removed for now.\r\nconst keyNames = {\r\n esc: 'escape',\r\n space: ' ',\r\n up: 'arrow-up',\r\n left: 'arrow-left',\r\n right: 'arrow-right',\r\n down: 'arrow-down',\r\n delete: 'backspace'\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withKeys = (fn, modifiers) => {\r\n return (event) => {\r\n if (!('key' in event)) {\r\n return;\r\n }\r\n const eventKey = hyphenate(event.key);\r\n if (modifiers.some(k => k === eventKey || keyNames[k] === eventKey)) {\r\n return fn(event);\r\n }\r\n };\r\n};\n\nconst vShow = {\r\n beforeMount(el, { value }, { transition }) {\r\n el._vod = el.style.display === 'none' ? '' : el.style.display;\r\n if (transition && value) {\r\n transition.beforeEnter(el);\r\n }\r\n else {\r\n setDisplay(el, value);\r\n }\r\n },\r\n mounted(el, { value }, { transition }) {\r\n if (transition && value) {\r\n transition.enter(el);\r\n }\r\n },\r\n updated(el, { value, oldValue }, { transition }) {\r\n if (!value === !oldValue)\r\n return;\r\n if (transition) {\r\n if (value) {\r\n transition.beforeEnter(el);\r\n setDisplay(el, true);\r\n transition.enter(el);\r\n }\r\n else {\r\n transition.leave(el, () => {\r\n setDisplay(el, false);\r\n });\r\n }\r\n }\r\n else {\r\n setDisplay(el, value);\r\n }\r\n },\r\n beforeUnmount(el, { value }) {\r\n setDisplay(el, value);\r\n }\r\n};\r\nfunction setDisplay(el, value) {\r\n el.style.display = value ? el._vod : 'none';\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVShowForSSR() {\r\n vShow.getSSRProps = ({ value }) => {\r\n if (!value) {\r\n return { style: { display: 'none' } };\r\n }\r\n };\r\n}\n\nconst rendererOptions = extend({ patchProp }, nodeOps);\r\n// lazy create the renderer - this makes core renderer logic tree-shakable\r\n// in case the user only imports reactivity utilities from Vue.\r\nlet renderer;\r\nlet enabledHydration = false;\r\nfunction ensureRenderer() {\r\n return (renderer ||\r\n (renderer = createRenderer(rendererOptions)));\r\n}\r\nfunction ensureHydrationRenderer() {\r\n renderer = enabledHydration\r\n ? renderer\r\n : createHydrationRenderer(rendererOptions);\r\n enabledHydration = true;\r\n return renderer;\r\n}\r\n// use explicit type casts here to avoid import() calls in rolled-up d.ts\r\nconst render = ((...args) => {\r\n ensureRenderer().render(...args);\r\n});\r\nconst hydrate = ((...args) => {\r\n ensureHydrationRenderer().hydrate(...args);\r\n});\r\nconst createApp = ((...args) => {\r\n const app = ensureRenderer().createApp(...args);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n injectNativeTagCheck(app);\r\n injectCompilerOptionsCheck(app);\r\n }\r\n const { mount } = app;\r\n app.mount = (containerOrSelector) => {\r\n const container = normalizeContainer(containerOrSelector);\r\n if (!container)\r\n return;\r\n const component = app._component;\r\n if (!isFunction(component) && !component.render && !component.template) {\r\n // __UNSAFE__\r\n // Reason: potential execution of JS expressions in in-DOM template.\r\n // The user must make sure the in-DOM template is trusted. If it's\r\n // rendered by the server, the template should not contain any user data.\r\n component.template = container.innerHTML;\r\n }\r\n // clear content before mounting\r\n container.innerHTML = '';\r\n const proxy = mount(container, false, container instanceof SVGElement);\r\n if (container instanceof Element) {\r\n container.removeAttribute('v-cloak');\r\n container.setAttribute('data-v-app', '');\r\n }\r\n return proxy;\r\n };\r\n return app;\r\n});\r\nconst createSSRApp = ((...args) => {\r\n const app = ensureHydrationRenderer().createApp(...args);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n injectNativeTagCheck(app);\r\n injectCompilerOptionsCheck(app);\r\n }\r\n const { mount } = app;\r\n app.mount = (containerOrSelector) => {\r\n const container = normalizeContainer(containerOrSelector);\r\n if (container) {\r\n return mount(container, true, container instanceof SVGElement);\r\n }\r\n };\r\n return app;\r\n});\r\nfunction injectNativeTagCheck(app) {\r\n // Inject `isNativeTag`\r\n // this is used for component name validation (dev only)\r\n Object.defineProperty(app.config, 'isNativeTag', {\r\n value: (tag) => isHTMLTag(tag) || isSVGTag(tag),\r\n writable: false\r\n });\r\n}\r\n// dev only\r\nfunction injectCompilerOptionsCheck(app) {\r\n if (isRuntimeOnly()) {\r\n const isCustomElement = app.config.isCustomElement;\r\n Object.defineProperty(app.config, 'isCustomElement', {\r\n get() {\r\n return isCustomElement;\r\n },\r\n set() {\r\n warn(`The \\`isCustomElement\\` config option is deprecated. Use ` +\r\n `\\`compilerOptions.isCustomElement\\` instead.`);\r\n }\r\n });\r\n const compilerOptions = app.config.compilerOptions;\r\n const msg = `The \\`compilerOptions\\` config option is only respected when using ` +\r\n `a build of Vue.js that includes the runtime compiler (aka \"full build\"). ` +\r\n `Since you are using the runtime-only build, \\`compilerOptions\\` ` +\r\n `must be passed to \\`@vue/compiler-dom\\` in the build setup instead.\\n` +\r\n `- For vue-loader: pass it via vue-loader's \\`compilerOptions\\` loader option.\\n` +\r\n `- For vue-cli: see https://cli.vuejs.org/guide/webpack.html#modifying-options-of-a-loader\\n` +\r\n `- For vite: pass it via @vitejs/plugin-vue options. See https://github.com/vitejs/vite/tree/main/packages/plugin-vue#example-for-passing-options-to-vuecompiler-dom`;\r\n Object.defineProperty(app.config, 'compilerOptions', {\r\n get() {\r\n warn(msg);\r\n return compilerOptions;\r\n },\r\n set() {\r\n warn(msg);\r\n }\r\n });\r\n }\r\n}\r\nfunction normalizeContainer(container) {\r\n if (isString(container)) {\r\n const res = document.querySelector(container);\r\n if ((process.env.NODE_ENV !== 'production') && !res) {\r\n warn(`Failed to mount app: mount target selector \"${container}\" returned null.`);\r\n }\r\n return res;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n window.ShadowRoot &&\r\n container instanceof window.ShadowRoot &&\r\n container.mode === 'closed') {\r\n warn(`mounting on a ShadowRoot with \\`{mode: \"closed\"}\\` may lead to unpredictable bugs`);\r\n }\r\n return container;\r\n}\r\nlet ssrDirectiveInitialized = false;\r\n/**\r\n * @internal\r\n */\r\nconst initDirectivesForSSR = () => {\r\n if (!ssrDirectiveInitialized) {\r\n ssrDirectiveInitialized = true;\r\n initVModelForSSR();\r\n initVShowForSSR();\r\n }\r\n }\r\n ;\n\nexport { Transition, TransitionGroup, VueElement, createApp, createSSRApp, defineCustomElement, defineSSRCustomElement, hydrate, initDirectivesForSSR, render, useCssModule, useCssVars, vModelCheckbox, vModelDynamic, vModelRadio, vModelSelect, vModelText, vShow, withKeys, withModifiers };\n","import { isString, hyphenate, NOOP, extend, isObject, NO, isArray, makeMap, isSymbol, EMPTY_OBJ, capitalize, camelize as camelize$1, PatchFlagNames, slotFlagsText, isOn, isReservedProp, toHandlerKey } from '@vue/shared';\nexport { generateCodeFrame } from '@vue/shared';\n\nfunction defaultOnError(error) {\r\n throw error;\r\n}\r\nfunction defaultOnWarn(msg) {\r\n (process.env.NODE_ENV !== 'production') && console.warn(`[Vue warn] ${msg.message}`);\r\n}\r\nfunction createCompilerError(code, loc, messages, additionalMessage) {\r\n const msg = (process.env.NODE_ENV !== 'production') || !true\r\n ? (messages || errorMessages)[code] + (additionalMessage || ``)\r\n : code;\r\n const error = new SyntaxError(String(msg));\r\n error.code = code;\r\n error.loc = loc;\r\n return error;\r\n}\r\nconst errorMessages = {\r\n // parse errors\r\n [0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */]: 'Illegal comment.',\r\n [1 /* CDATA_IN_HTML_CONTENT */]: 'CDATA section is allowed only in XML context.',\r\n [2 /* DUPLICATE_ATTRIBUTE */]: 'Duplicate attribute.',\r\n [3 /* END_TAG_WITH_ATTRIBUTES */]: 'End tag cannot have attributes.',\r\n [4 /* END_TAG_WITH_TRAILING_SOLIDUS */]: \"Illegal '/' in tags.\",\r\n [5 /* EOF_BEFORE_TAG_NAME */]: 'Unexpected EOF in tag.',\r\n [6 /* EOF_IN_CDATA */]: 'Unexpected EOF in CDATA section.',\r\n [7 /* EOF_IN_COMMENT */]: 'Unexpected EOF in comment.',\r\n [8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */]: 'Unexpected EOF in script.',\r\n [9 /* EOF_IN_TAG */]: 'Unexpected EOF in tag.',\r\n [10 /* INCORRECTLY_CLOSED_COMMENT */]: 'Incorrectly closed comment.',\r\n [11 /* INCORRECTLY_OPENED_COMMENT */]: 'Incorrectly opened comment.',\r\n [12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */]: \"Illegal tag name. Use '<' to print '<'.\",\r\n [13 /* MISSING_ATTRIBUTE_VALUE */]: 'Attribute value was expected.',\r\n [14 /* MISSING_END_TAG_NAME */]: 'End tag name was expected.',\r\n [15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */]: 'Whitespace was expected.',\r\n [16 /* NESTED_COMMENT */]: \"Unexpected '<!--' in comment.\",\r\n [17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */]: 'Attribute name cannot contain U+0022 (\"), U+0027 (\\'), and U+003C (<).',\r\n [18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */]: 'Unquoted attribute value cannot contain U+0022 (\"), U+0027 (\\'), U+003C (<), U+003D (=), and U+0060 (`).',\r\n [19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */]: \"Attribute name cannot start with '='.\",\r\n [21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */]: \"'<?' is allowed only in XML context.\",\r\n [20 /* UNEXPECTED_NULL_CHARACTER */]: `Unexpected null character.`,\r\n [22 /* UNEXPECTED_SOLIDUS_IN_TAG */]: \"Illegal '/' in tags.\",\r\n // Vue-specific parse errors\r\n [23 /* X_INVALID_END_TAG */]: 'Invalid end tag.',\r\n [24 /* X_MISSING_END_TAG */]: 'Element is missing end tag.',\r\n [25 /* X_MISSING_INTERPOLATION_END */]: 'Interpolation end sign was not found.',\r\n [27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */]: 'End bracket for dynamic directive argument was not found. ' +\r\n 'Note that dynamic directive argument cannot contain spaces.',\r\n [26 /* X_MISSING_DIRECTIVE_NAME */]: 'Legal directive name was expected.',\r\n // transform errors\r\n [28 /* X_V_IF_NO_EXPRESSION */]: `v-if/v-else-if is missing expression.`,\r\n [29 /* X_V_IF_SAME_KEY */]: `v-if/else branches must use unique keys.`,\r\n [30 /* X_V_ELSE_NO_ADJACENT_IF */]: `v-else/v-else-if has no adjacent v-if or v-else-if.`,\r\n [31 /* X_V_FOR_NO_EXPRESSION */]: `v-for is missing expression.`,\r\n [32 /* X_V_FOR_MALFORMED_EXPRESSION */]: `v-for has invalid expression.`,\r\n [33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */]: `<template v-for> key should be placed on the <template> tag.`,\r\n [34 /* X_V_BIND_NO_EXPRESSION */]: `v-bind is missing expression.`,\r\n [35 /* X_V_ON_NO_EXPRESSION */]: `v-on is missing expression.`,\r\n [36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */]: `Unexpected custom directive on <slot> outlet.`,\r\n [37 /* X_V_SLOT_MIXED_SLOT_USAGE */]: `Mixed v-slot usage on both the component and nested <template>.` +\r\n `When there are multiple named slots, all slots should use <template> ` +\r\n `syntax to avoid scope ambiguity.`,\r\n [38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */]: `Duplicate slot names found. `,\r\n [39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */]: `Extraneous children found when component already has explicitly named ` +\r\n `default slot. These children will be ignored.`,\r\n [40 /* X_V_SLOT_MISPLACED */]: `v-slot can only be used on components or <template> tags.`,\r\n [41 /* X_V_MODEL_NO_EXPRESSION */]: `v-model is missing expression.`,\r\n [42 /* X_V_MODEL_MALFORMED_EXPRESSION */]: `v-model value must be a valid JavaScript member expression.`,\r\n [43 /* X_V_MODEL_ON_SCOPE_VARIABLE */]: `v-model cannot be used on v-for or v-slot scope variables because they are not writable.`,\r\n [44 /* X_INVALID_EXPRESSION */]: `Error parsing JavaScript expression: `,\r\n [45 /* X_KEEP_ALIVE_INVALID_CHILDREN */]: `<KeepAlive> expects exactly one child component.`,\r\n // generic errors\r\n [46 /* X_PREFIX_ID_NOT_SUPPORTED */]: `\"prefixIdentifiers\" option is not supported in this build of compiler.`,\r\n [47 /* X_MODULE_MODE_NOT_SUPPORTED */]: `ES module mode is not supported in this build of compiler.`,\r\n [48 /* X_CACHE_HANDLER_NOT_SUPPORTED */]: `\"cacheHandlers\" option is only supported when the \"prefixIdentifiers\" option is enabled.`,\r\n [49 /* X_SCOPE_ID_NOT_SUPPORTED */]: `\"scopeId\" option is only supported in module mode.`,\r\n // just to fulfill types\r\n [50 /* __EXTEND_POINT__ */]: ``\r\n};\n\nconst FRAGMENT = Symbol((process.env.NODE_ENV !== 'production') ? `Fragment` : ``);\r\nconst TELEPORT = Symbol((process.env.NODE_ENV !== 'production') ? `Teleport` : ``);\r\nconst SUSPENSE = Symbol((process.env.NODE_ENV !== 'production') ? `Suspense` : ``);\r\nconst KEEP_ALIVE = Symbol((process.env.NODE_ENV !== 'production') ? `KeepAlive` : ``);\r\nconst BASE_TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `BaseTransition` : ``);\r\nconst OPEN_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `openBlock` : ``);\r\nconst CREATE_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createBlock` : ``);\r\nconst CREATE_ELEMENT_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createElementBlock` : ``);\r\nconst CREATE_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createVNode` : ``);\r\nconst CREATE_ELEMENT_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createElementVNode` : ``);\r\nconst CREATE_COMMENT = Symbol((process.env.NODE_ENV !== 'production') ? `createCommentVNode` : ``);\r\nconst CREATE_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `createTextVNode` : ``);\r\nconst CREATE_STATIC = Symbol((process.env.NODE_ENV !== 'production') ? `createStaticVNode` : ``);\r\nconst RESOLVE_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveComponent` : ``);\r\nconst RESOLVE_DYNAMIC_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDynamicComponent` : ``);\r\nconst RESOLVE_DIRECTIVE = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDirective` : ``);\r\nconst RESOLVE_FILTER = Symbol((process.env.NODE_ENV !== 'production') ? `resolveFilter` : ``);\r\nconst WITH_DIRECTIVES = Symbol((process.env.NODE_ENV !== 'production') ? `withDirectives` : ``);\r\nconst RENDER_LIST = Symbol((process.env.NODE_ENV !== 'production') ? `renderList` : ``);\r\nconst RENDER_SLOT = Symbol((process.env.NODE_ENV !== 'production') ? `renderSlot` : ``);\r\nconst CREATE_SLOTS = Symbol((process.env.NODE_ENV !== 'production') ? `createSlots` : ``);\r\nconst TO_DISPLAY_STRING = Symbol((process.env.NODE_ENV !== 'production') ? `toDisplayString` : ``);\r\nconst MERGE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `mergeProps` : ``);\r\nconst NORMALIZE_CLASS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeClass` : ``);\r\nconst NORMALIZE_STYLE = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeStyle` : ``);\r\nconst NORMALIZE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeProps` : ``);\r\nconst GUARD_REACTIVE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `guardReactiveProps` : ``);\r\nconst TO_HANDLERS = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlers` : ``);\r\nconst CAMELIZE = Symbol((process.env.NODE_ENV !== 'production') ? `camelize` : ``);\r\nconst CAPITALIZE = Symbol((process.env.NODE_ENV !== 'production') ? `capitalize` : ``);\r\nconst TO_HANDLER_KEY = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlerKey` : ``);\r\nconst SET_BLOCK_TRACKING = Symbol((process.env.NODE_ENV !== 'production') ? `setBlockTracking` : ``);\r\nconst PUSH_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `pushScopeId` : ``);\r\nconst POP_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `popScopeId` : ``);\r\nconst WITH_CTX = Symbol((process.env.NODE_ENV !== 'production') ? `withCtx` : ``);\r\nconst UNREF = Symbol((process.env.NODE_ENV !== 'production') ? `unref` : ``);\r\nconst IS_REF = Symbol((process.env.NODE_ENV !== 'production') ? `isRef` : ``);\r\nconst WITH_MEMO = Symbol((process.env.NODE_ENV !== 'production') ? `withMemo` : ``);\r\nconst IS_MEMO_SAME = Symbol((process.env.NODE_ENV !== 'production') ? `isMemoSame` : ``);\r\n// Name mapping for runtime helpers that need to be imported from 'vue' in\r\n// generated code. Make sure these are correctly exported in the runtime!\r\n// Using `any` here because TS doesn't allow symbols as index type.\r\nconst helperNameMap = {\r\n [FRAGMENT]: `Fragment`,\r\n [TELEPORT]: `Teleport`,\r\n [SUSPENSE]: `Suspense`,\r\n [KEEP_ALIVE]: `KeepAlive`,\r\n [BASE_TRANSITION]: `BaseTransition`,\r\n [OPEN_BLOCK]: `openBlock`,\r\n [CREATE_BLOCK]: `createBlock`,\r\n [CREATE_ELEMENT_BLOCK]: `createElementBlock`,\r\n [CREATE_VNODE]: `createVNode`,\r\n [CREATE_ELEMENT_VNODE]: `createElementVNode`,\r\n [CREATE_COMMENT]: `createCommentVNode`,\r\n [CREATE_TEXT]: `createTextVNode`,\r\n [CREATE_STATIC]: `createStaticVNode`,\r\n [RESOLVE_COMPONENT]: `resolveComponent`,\r\n [RESOLVE_DYNAMIC_COMPONENT]: `resolveDynamicComponent`,\r\n [RESOLVE_DIRECTIVE]: `resolveDirective`,\r\n [RESOLVE_FILTER]: `resolveFilter`,\r\n [WITH_DIRECTIVES]: `withDirectives`,\r\n [RENDER_LIST]: `renderList`,\r\n [RENDER_SLOT]: `renderSlot`,\r\n [CREATE_SLOTS]: `createSlots`,\r\n [TO_DISPLAY_STRING]: `toDisplayString`,\r\n [MERGE_PROPS]: `mergeProps`,\r\n [NORMALIZE_CLASS]: `normalizeClass`,\r\n [NORMALIZE_STYLE]: `normalizeStyle`,\r\n [NORMALIZE_PROPS]: `normalizeProps`,\r\n [GUARD_REACTIVE_PROPS]: `guardReactiveProps`,\r\n [TO_HANDLERS]: `toHandlers`,\r\n [CAMELIZE]: `camelize`,\r\n [CAPITALIZE]: `capitalize`,\r\n [TO_HANDLER_KEY]: `toHandlerKey`,\r\n [SET_BLOCK_TRACKING]: `setBlockTracking`,\r\n [PUSH_SCOPE_ID]: `pushScopeId`,\r\n [POP_SCOPE_ID]: `popScopeId`,\r\n [WITH_CTX]: `withCtx`,\r\n [UNREF]: `unref`,\r\n [IS_REF]: `isRef`,\r\n [WITH_MEMO]: `withMemo`,\r\n [IS_MEMO_SAME]: `isMemoSame`\r\n};\r\nfunction registerRuntimeHelpers(helpers) {\r\n Object.getOwnPropertySymbols(helpers).forEach(s => {\r\n helperNameMap[s] = helpers[s];\r\n });\r\n}\n\n// AST Utilities ---------------------------------------------------------------\r\n// Some expressions, e.g. sequence and conditional expressions, are never\r\n// associated with template nodes, so their source locations are just a stub.\r\n// Container types like CompoundExpression also don't need a real location.\r\nconst locStub = {\r\n source: '',\r\n start: { line: 1, column: 1, offset: 0 },\r\n end: { line: 1, column: 1, offset: 0 }\r\n};\r\nfunction createRoot(children, loc = locStub) {\r\n return {\r\n type: 0 /* ROOT */,\r\n children,\r\n helpers: [],\r\n components: [],\r\n directives: [],\r\n hoists: [],\r\n imports: [],\r\n cached: 0,\r\n temps: 0,\r\n codegenNode: undefined,\r\n loc\r\n };\r\n}\r\nfunction createVNodeCall(context, tag, props, children, patchFlag, dynamicProps, directives, isBlock = false, disableTracking = false, isComponent = false, loc = locStub) {\r\n if (context) {\r\n if (isBlock) {\r\n context.helper(OPEN_BLOCK);\r\n context.helper(getVNodeBlockHelper(context.inSSR, isComponent));\r\n }\r\n else {\r\n context.helper(getVNodeHelper(context.inSSR, isComponent));\r\n }\r\n if (directives) {\r\n context.helper(WITH_DIRECTIVES);\r\n }\r\n }\r\n return {\r\n type: 13 /* VNODE_CALL */,\r\n tag,\r\n props,\r\n children,\r\n patchFlag,\r\n dynamicProps,\r\n directives,\r\n isBlock,\r\n disableTracking,\r\n isComponent,\r\n loc\r\n };\r\n}\r\nfunction createArrayExpression(elements, loc = locStub) {\r\n return {\r\n type: 17 /* JS_ARRAY_EXPRESSION */,\r\n loc,\r\n elements\r\n };\r\n}\r\nfunction createObjectExpression(properties, loc = locStub) {\r\n return {\r\n type: 15 /* JS_OBJECT_EXPRESSION */,\r\n loc,\r\n properties\r\n };\r\n}\r\nfunction createObjectProperty(key, value) {\r\n return {\r\n type: 16 /* JS_PROPERTY */,\r\n loc: locStub,\r\n key: isString(key) ? createSimpleExpression(key, true) : key,\r\n value\r\n };\r\n}\r\nfunction createSimpleExpression(content, isStatic = false, loc = locStub, constType = 0 /* NOT_CONSTANT */) {\r\n return {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n loc,\r\n content,\r\n isStatic,\r\n constType: isStatic ? 3 /* CAN_STRINGIFY */ : constType\r\n };\r\n}\r\nfunction createInterpolation(content, loc) {\r\n return {\r\n type: 5 /* INTERPOLATION */,\r\n loc,\r\n content: isString(content)\r\n ? createSimpleExpression(content, false, loc)\r\n : content\r\n };\r\n}\r\nfunction createCompoundExpression(children, loc = locStub) {\r\n return {\r\n type: 8 /* COMPOUND_EXPRESSION */,\r\n loc,\r\n children\r\n };\r\n}\r\nfunction createCallExpression(callee, args = [], loc = locStub) {\r\n return {\r\n type: 14 /* JS_CALL_EXPRESSION */,\r\n loc,\r\n callee,\r\n arguments: args\r\n };\r\n}\r\nfunction createFunctionExpression(params, returns = undefined, newline = false, isSlot = false, loc = locStub) {\r\n return {\r\n type: 18 /* JS_FUNCTION_EXPRESSION */,\r\n params,\r\n returns,\r\n newline,\r\n isSlot,\r\n loc\r\n };\r\n}\r\nfunction createConditionalExpression(test, consequent, alternate, newline = true) {\r\n return {\r\n type: 19 /* JS_CONDITIONAL_EXPRESSION */,\r\n test,\r\n consequent,\r\n alternate,\r\n newline,\r\n loc: locStub\r\n };\r\n}\r\nfunction createCacheExpression(index, value, isVNode = false) {\r\n return {\r\n type: 20 /* JS_CACHE_EXPRESSION */,\r\n index,\r\n value,\r\n isVNode,\r\n loc: locStub\r\n };\r\n}\r\nfunction createBlockStatement(body) {\r\n return {\r\n type: 21 /* JS_BLOCK_STATEMENT */,\r\n body,\r\n loc: locStub\r\n };\r\n}\r\nfunction createTemplateLiteral(elements) {\r\n return {\r\n type: 22 /* JS_TEMPLATE_LITERAL */,\r\n elements,\r\n loc: locStub\r\n };\r\n}\r\nfunction createIfStatement(test, consequent, alternate) {\r\n return {\r\n type: 23 /* JS_IF_STATEMENT */,\r\n test,\r\n consequent,\r\n alternate,\r\n loc: locStub\r\n };\r\n}\r\nfunction createAssignmentExpression(left, right) {\r\n return {\r\n type: 24 /* JS_ASSIGNMENT_EXPRESSION */,\r\n left,\r\n right,\r\n loc: locStub\r\n };\r\n}\r\nfunction createSequenceExpression(expressions) {\r\n return {\r\n type: 25 /* JS_SEQUENCE_EXPRESSION */,\r\n expressions,\r\n loc: locStub\r\n };\r\n}\r\nfunction createReturnStatement(returns) {\r\n return {\r\n type: 26 /* JS_RETURN_STATEMENT */,\r\n returns,\r\n loc: locStub\r\n };\r\n}\n\nconst isStaticExp = (p) => p.type === 4 /* SIMPLE_EXPRESSION */ && p.isStatic;\r\nconst isBuiltInType = (tag, expected) => tag === expected || tag === hyphenate(expected);\r\nfunction isCoreComponent(tag) {\r\n if (isBuiltInType(tag, 'Teleport')) {\r\n return TELEPORT;\r\n }\r\n else if (isBuiltInType(tag, 'Suspense')) {\r\n return SUSPENSE;\r\n }\r\n else if (isBuiltInType(tag, 'KeepAlive')) {\r\n return KEEP_ALIVE;\r\n }\r\n else if (isBuiltInType(tag, 'BaseTransition')) {\r\n return BASE_TRANSITION;\r\n }\r\n}\r\nconst nonIdentifierRE = /^\\d|[^\\$\\w]/;\r\nconst isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);\r\nconst validFirstIdentCharRE = /[A-Za-z_$\\xA0-\\uFFFF]/;\r\nconst validIdentCharRE = /[\\.\\?\\w$\\xA0-\\uFFFF]/;\r\nconst whitespaceRE = /\\s+[.[]\\s*|\\s*[.[]\\s+/g;\r\n/**\r\n * Simple lexer to check if an expression is a member expression. This is\r\n * lax and only checks validity at the root level (i.e. does not validate exps\r\n * inside square brackets), but it's ok since these are only used on template\r\n * expressions and false positives are invalid expressions in the first place.\r\n */\r\nconst isMemberExpressionBrowser = (path) => {\r\n // remove whitespaces around . or [ first\r\n path = path.trim().replace(whitespaceRE, s => s.trim());\r\n let state = 0 /* inMemberExp */;\r\n let stateStack = [];\r\n let currentOpenBracketCount = 0;\r\n let currentOpenParensCount = 0;\r\n let currentStringType = null;\r\n for (let i = 0; i < path.length; i++) {\r\n const char = path.charAt(i);\r\n switch (state) {\r\n case 0 /* inMemberExp */:\r\n if (char === '[') {\r\n stateStack.push(state);\r\n state = 1 /* inBrackets */;\r\n currentOpenBracketCount++;\r\n }\r\n else if (char === '(') {\r\n stateStack.push(state);\r\n state = 2 /* inParens */;\r\n currentOpenParensCount++;\r\n }\r\n else if (!(i === 0 ? validFirstIdentCharRE : validIdentCharRE).test(char)) {\r\n return false;\r\n }\r\n break;\r\n case 1 /* inBrackets */:\r\n if (char === `'` || char === `\"` || char === '`') {\r\n stateStack.push(state);\r\n state = 3 /* inString */;\r\n currentStringType = char;\r\n }\r\n else if (char === `[`) {\r\n currentOpenBracketCount++;\r\n }\r\n else if (char === `]`) {\r\n if (!--currentOpenBracketCount) {\r\n state = stateStack.pop();\r\n }\r\n }\r\n break;\r\n case 2 /* inParens */:\r\n if (char === `'` || char === `\"` || char === '`') {\r\n stateStack.push(state);\r\n state = 3 /* inString */;\r\n currentStringType = char;\r\n }\r\n else if (char === `(`) {\r\n currentOpenParensCount++;\r\n }\r\n else if (char === `)`) {\r\n // if the exp ends as a call then it should not be considered valid\r\n if (i === path.length - 1) {\r\n return false;\r\n }\r\n if (!--currentOpenParensCount) {\r\n state = stateStack.pop();\r\n }\r\n }\r\n break;\r\n case 3 /* inString */:\r\n if (char === currentStringType) {\r\n state = stateStack.pop();\r\n currentStringType = null;\r\n }\r\n break;\r\n }\r\n }\r\n return !currentOpenBracketCount && !currentOpenParensCount;\r\n};\r\nconst isMemberExpressionNode = NOOP\r\n ;\r\nconst isMemberExpression = isMemberExpressionBrowser\r\n ;\r\nfunction getInnerRange(loc, offset, length) {\r\n const source = loc.source.slice(offset, offset + length);\r\n const newLoc = {\r\n source,\r\n start: advancePositionWithClone(loc.start, loc.source, offset),\r\n end: loc.end\r\n };\r\n if (length != null) {\r\n newLoc.end = advancePositionWithClone(loc.start, loc.source, offset + length);\r\n }\r\n return newLoc;\r\n}\r\nfunction advancePositionWithClone(pos, source, numberOfCharacters = source.length) {\r\n return advancePositionWithMutation(extend({}, pos), source, numberOfCharacters);\r\n}\r\n// advance by mutation without cloning (for performance reasons), since this\r\n// gets called a lot in the parser\r\nfunction advancePositionWithMutation(pos, source, numberOfCharacters = source.length) {\r\n let linesCount = 0;\r\n let lastNewLinePos = -1;\r\n for (let i = 0; i < numberOfCharacters; i++) {\r\n if (source.charCodeAt(i) === 10 /* newline char code */) {\r\n linesCount++;\r\n lastNewLinePos = i;\r\n }\r\n }\r\n pos.offset += numberOfCharacters;\r\n pos.line += linesCount;\r\n pos.column =\r\n lastNewLinePos === -1\r\n ? pos.column + numberOfCharacters\r\n : numberOfCharacters - lastNewLinePos;\r\n return pos;\r\n}\r\nfunction assert(condition, msg) {\r\n /* istanbul ignore if */\r\n if (!condition) {\r\n throw new Error(msg || `unexpected compiler condition`);\r\n }\r\n}\r\nfunction findDir(node, name, allowEmpty = false) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ &&\r\n (allowEmpty || p.exp) &&\r\n (isString(name) ? p.name === name : name.test(p.name))) {\r\n return p;\r\n }\r\n }\r\n}\r\nfunction findProp(node, name, dynamicOnly = false, allowEmpty = false) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (dynamicOnly)\r\n continue;\r\n if (p.name === name && (p.value || allowEmpty)) {\r\n return p;\r\n }\r\n }\r\n else if (p.name === 'bind' &&\r\n (p.exp || allowEmpty) &&\r\n isStaticArgOf(p.arg, name)) {\r\n return p;\r\n }\r\n }\r\n}\r\nfunction isStaticArgOf(arg, name) {\r\n return !!(arg && isStaticExp(arg) && arg.content === name);\r\n}\r\nfunction hasDynamicKeyVBind(node) {\r\n return node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n p.name === 'bind' &&\r\n (!p.arg || // v-bind=\"obj\"\r\n p.arg.type !== 4 /* SIMPLE_EXPRESSION */ || // v-bind:[_ctx.foo]\r\n !p.arg.isStatic) // v-bind:[foo]\r\n );\r\n}\r\nfunction isText(node) {\r\n return node.type === 5 /* INTERPOLATION */ || node.type === 2 /* TEXT */;\r\n}\r\nfunction isVSlot(p) {\r\n return p.type === 7 /* DIRECTIVE */ && p.name === 'slot';\r\n}\r\nfunction isTemplateNode(node) {\r\n return (node.type === 1 /* ELEMENT */ && node.tagType === 3 /* TEMPLATE */);\r\n}\r\nfunction isSlotOutlet(node) {\r\n return node.type === 1 /* ELEMENT */ && node.tagType === 2 /* SLOT */;\r\n}\r\nfunction getVNodeHelper(ssr, isComponent) {\r\n return ssr || isComponent ? CREATE_VNODE : CREATE_ELEMENT_VNODE;\r\n}\r\nfunction getVNodeBlockHelper(ssr, isComponent) {\r\n return ssr || isComponent ? CREATE_BLOCK : CREATE_ELEMENT_BLOCK;\r\n}\r\nconst propsHelperSet = new Set([NORMALIZE_PROPS, GUARD_REACTIVE_PROPS]);\r\nfunction getUnnormalizedProps(props, callPath = []) {\r\n if (props &&\r\n !isString(props) &&\r\n props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n const callee = props.callee;\r\n if (!isString(callee) && propsHelperSet.has(callee)) {\r\n return getUnnormalizedProps(props.arguments[0], callPath.concat(props));\r\n }\r\n }\r\n return [props, callPath];\r\n}\r\nfunction injectProp(node, prop, context) {\r\n let propsWithInjection;\r\n /**\r\n * 1. mergeProps(...)\r\n * 2. toHandlers(...)\r\n * 3. normalizeProps(...)\r\n * 4. normalizeProps(guardReactiveProps(...))\r\n *\r\n * we need to get the real props before normalization\r\n */\r\n let props = node.type === 13 /* VNODE_CALL */ ? node.props : node.arguments[2];\r\n let callPath = [];\r\n let parentCall;\r\n if (props &&\r\n !isString(props) &&\r\n props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n const ret = getUnnormalizedProps(props);\r\n props = ret[0];\r\n callPath = ret[1];\r\n parentCall = callPath[callPath.length - 1];\r\n }\r\n if (props == null || isString(props)) {\r\n propsWithInjection = createObjectExpression([prop]);\r\n }\r\n else if (props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // merged props... add ours\r\n // only inject key to object literal if it's the first argument so that\r\n // if doesn't override user provided keys\r\n const first = props.arguments[0];\r\n if (!isString(first) && first.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n first.properties.unshift(prop);\r\n }\r\n else {\r\n if (props.callee === TO_HANDLERS) {\r\n // #2366\r\n propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n createObjectExpression([prop]),\r\n props\r\n ]);\r\n }\r\n else {\r\n props.arguments.unshift(createObjectExpression([prop]));\r\n }\r\n }\r\n !propsWithInjection && (propsWithInjection = props);\r\n }\r\n else if (props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n let alreadyExists = false;\r\n // check existing key to avoid overriding user provided keys\r\n if (prop.key.type === 4 /* SIMPLE_EXPRESSION */) {\r\n const propKeyName = prop.key.content;\r\n alreadyExists = props.properties.some(p => p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n p.key.content === propKeyName);\r\n }\r\n if (!alreadyExists) {\r\n props.properties.unshift(prop);\r\n }\r\n propsWithInjection = props;\r\n }\r\n else {\r\n // single v-bind with expression, return a merged replacement\r\n propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n createObjectExpression([prop]),\r\n props\r\n ]);\r\n // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(props))`,\r\n // it will be rewritten as `normalizeProps(mergeProps({ key: 0 }, props))`,\r\n // the `guardReactiveProps` will no longer be needed\r\n if (parentCall && parentCall.callee === GUARD_REACTIVE_PROPS) {\r\n parentCall = callPath[callPath.length - 2];\r\n }\r\n }\r\n if (node.type === 13 /* VNODE_CALL */) {\r\n if (parentCall) {\r\n parentCall.arguments[0] = propsWithInjection;\r\n }\r\n else {\r\n node.props = propsWithInjection;\r\n }\r\n }\r\n else {\r\n if (parentCall) {\r\n parentCall.arguments[0] = propsWithInjection;\r\n }\r\n else {\r\n node.arguments[2] = propsWithInjection;\r\n }\r\n }\r\n}\r\nfunction toValidAssetId(name, type) {\r\n // see issue#4422, we need adding identifier on validAssetId if variable `name` has specific character\r\n return `_${type}_${name.replace(/[^\\w]/g, (searchValue, replaceValue) => {\r\n return searchValue === '-' ? '_' : name.charCodeAt(replaceValue).toString();\r\n })}`;\r\n}\r\n// Check if a node contains expressions that reference current context scope ids\r\nfunction hasScopeRef(node, ids) {\r\n if (!node || Object.keys(ids).length === 0) {\r\n return false;\r\n }\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ &&\r\n (hasScopeRef(p.arg, ids) || hasScopeRef(p.exp, ids))) {\r\n return true;\r\n }\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 11 /* FOR */:\r\n if (hasScopeRef(node.source, ids)) {\r\n return true;\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 9 /* IF */:\r\n return node.branches.some(b => hasScopeRef(b, ids));\r\n case 10 /* IF_BRANCH */:\r\n if (hasScopeRef(node.condition, ids)) {\r\n return true;\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n return (!node.isStatic &&\r\n isSimpleIdentifier(node.content) &&\r\n !!ids[node.content]);\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n return node.children.some(c => isObject(c) && hasScopeRef(c, ids));\r\n case 5 /* INTERPOLATION */:\r\n case 12 /* TEXT_CALL */:\r\n return hasScopeRef(node.content, ids);\r\n case 2 /* TEXT */:\r\n case 3 /* COMMENT */:\r\n return false;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) ;\r\n return false;\r\n }\r\n}\r\nfunction getMemoedVNodeCall(node) {\r\n if (node.type === 14 /* JS_CALL_EXPRESSION */ && node.callee === WITH_MEMO) {\r\n return node.arguments[1].returns;\r\n }\r\n else {\r\n return node;\r\n }\r\n}\r\nfunction makeBlock(node, { helper, removeHelper, inSSR }) {\r\n if (!node.isBlock) {\r\n node.isBlock = true;\r\n removeHelper(getVNodeHelper(inSSR, node.isComponent));\r\n helper(OPEN_BLOCK);\r\n helper(getVNodeBlockHelper(inSSR, node.isComponent));\r\n }\r\n}\n\nconst deprecationData = {\r\n [\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */]: {\r\n message: `Platform-native elements with \"is\" prop will no longer be ` +\r\n `treated as components in Vue 3 unless the \"is\" value is explicitly ` +\r\n `prefixed with \"vue:\".`,\r\n link: `https://v3.vuejs.org/guide/migration/custom-elements-interop.html`\r\n },\r\n [\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */]: {\r\n message: key => `.sync modifier for v-bind has been removed. Use v-model with ` +\r\n `argument instead. \\`v-bind:${key}.sync\\` should be changed to ` +\r\n `\\`v-model:${key}\\`.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-model.html`\r\n },\r\n [\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */]: {\r\n message: `.prop modifier for v-bind has been removed and no longer necessary. ` +\r\n `Vue 3 will automatically set a binding as DOM property when appropriate.`\r\n },\r\n [\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */]: {\r\n message: `v-bind=\"obj\" usage is now order sensitive and behaves like JavaScript ` +\r\n `object spread: it will now overwrite an existing non-mergeable attribute ` +\r\n `that appears before v-bind in the case of conflict. ` +\r\n `To retain 2.x behavior, move v-bind to make it the first attribute. ` +\r\n `You can also suppress this warning if the usage is intended.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-bind.html`\r\n },\r\n [\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */]: {\r\n message: `.native modifier for v-on has been removed as is no longer necessary.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-on-native-modifier-removed.html`\r\n },\r\n [\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */]: {\r\n message: `v-if / v-for precedence when used on the same element has changed ` +\r\n `in Vue 3: v-if now takes higher precedence and will no longer have ` +\r\n `access to v-for scope variables. It is best to avoid the ambiguity ` +\r\n `with <template> tags or use a computed property that filters v-for ` +\r\n `data source.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-if-v-for.html`\r\n },\r\n [\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */]: {\r\n message: `<template> with no special directives will render as a native template ` +\r\n `element instead of its inner content in Vue 3.`\r\n },\r\n [\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */]: {\r\n message: `\"inline-template\" has been removed in Vue 3.`,\r\n link: `https://v3.vuejs.org/guide/migration/inline-template-attribute.html`\r\n },\r\n [\"COMPILER_FILTER\" /* COMPILER_FILTERS */]: {\r\n message: `filters have been removed in Vue 3. ` +\r\n `The \"|\" symbol will be treated as native JavaScript bitwise OR operator. ` +\r\n `Use method calls or computed properties instead.`,\r\n link: `https://v3.vuejs.org/guide/migration/filters.html`\r\n }\r\n};\r\nfunction getCompatValue(key, context) {\r\n const config = context.options\r\n ? context.options.compatConfig\r\n : context.compatConfig;\r\n const value = config && config[key];\r\n if (key === 'MODE') {\r\n return value || 3; // compiler defaults to v3 behavior\r\n }\r\n else {\r\n return value;\r\n }\r\n}\r\nfunction isCompatEnabled(key, context) {\r\n const mode = getCompatValue('MODE', context);\r\n const value = getCompatValue(key, context);\r\n // in v3 mode, only enable if explicitly set to true\r\n // otherwise enable for any non-false value\r\n return mode === 3 ? value === true : value !== false;\r\n}\r\nfunction checkCompatEnabled(key, context, loc, ...args) {\r\n const enabled = isCompatEnabled(key, context);\r\n if ((process.env.NODE_ENV !== 'production') && enabled) {\r\n warnDeprecation(key, context, loc, ...args);\r\n }\r\n return enabled;\r\n}\r\nfunction warnDeprecation(key, context, loc, ...args) {\r\n const val = getCompatValue(key, context);\r\n if (val === 'suppress-warning') {\r\n return;\r\n }\r\n const { message, link } = deprecationData[key];\r\n const msg = `(deprecation ${key}) ${typeof message === 'function' ? message(...args) : message}${link ? `\\n Details: ${link}` : ``}`;\r\n const err = new SyntaxError(msg);\r\n err.code = key;\r\n if (loc)\r\n err.loc = loc;\r\n context.onWarn(err);\r\n}\n\n// The default decoder only provides escapes for characters reserved as part of\r\n// the template syntax, and is only used if the custom renderer did not provide\r\n// a platform-specific decoder.\r\nconst decodeRE = /&(gt|lt|amp|apos|quot);/g;\r\nconst decodeMap = {\r\n gt: '>',\r\n lt: '<',\r\n amp: '&',\r\n apos: \"'\",\r\n quot: '\"'\r\n};\r\nconst defaultParserOptions = {\r\n delimiters: [`{{`, `}}`],\r\n getNamespace: () => 0 /* HTML */,\r\n getTextMode: () => 0 /* DATA */,\r\n isVoidTag: NO,\r\n isPreTag: NO,\r\n isCustomElement: NO,\r\n decodeEntities: (rawText) => rawText.replace(decodeRE, (_, p1) => decodeMap[p1]),\r\n onError: defaultOnError,\r\n onWarn: defaultOnWarn,\r\n comments: (process.env.NODE_ENV !== 'production')\r\n};\r\nfunction baseParse(content, options = {}) {\r\n const context = createParserContext(content, options);\r\n const start = getCursor(context);\r\n return createRoot(parseChildren(context, 0 /* DATA */, []), getSelection(context, start));\r\n}\r\nfunction createParserContext(content, rawOptions) {\r\n const options = extend({}, defaultParserOptions);\r\n let key;\r\n for (key in rawOptions) {\r\n // @ts-ignore\r\n options[key] =\r\n rawOptions[key] === undefined\r\n ? defaultParserOptions[key]\r\n : rawOptions[key];\r\n }\r\n return {\r\n options,\r\n column: 1,\r\n line: 1,\r\n offset: 0,\r\n originalSource: content,\r\n source: content,\r\n inPre: false,\r\n inVPre: false,\r\n onWarn: options.onWarn\r\n };\r\n}\r\nfunction parseChildren(context, mode, ancestors) {\r\n const parent = last(ancestors);\r\n const ns = parent ? parent.ns : 0 /* HTML */;\r\n const nodes = [];\r\n while (!isEnd(context, mode, ancestors)) {\r\n const s = context.source;\r\n let node = undefined;\r\n if (mode === 0 /* DATA */ || mode === 1 /* RCDATA */) {\r\n if (!context.inVPre && startsWith(s, context.options.delimiters[0])) {\r\n // '{{'\r\n node = parseInterpolation(context, mode);\r\n }\r\n else if (mode === 0 /* DATA */ && s[0] === '<') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#tag-open-state\r\n if (s.length === 1) {\r\n emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 1);\r\n }\r\n else if (s[1] === '!') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#markup-declaration-open-state\r\n if (startsWith(s, '<!--')) {\r\n node = parseComment(context);\r\n }\r\n else if (startsWith(s, '<!DOCTYPE')) {\r\n // Ignore DOCTYPE by a limitation.\r\n node = parseBogusComment(context);\r\n }\r\n else if (startsWith(s, '<![CDATA[')) {\r\n if (ns !== 0 /* HTML */) {\r\n node = parseCDATA(context, ancestors);\r\n }\r\n else {\r\n emitError(context, 1 /* CDATA_IN_HTML_CONTENT */);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else {\r\n emitError(context, 11 /* INCORRECTLY_OPENED_COMMENT */);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else if (s[1] === '/') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#end-tag-open-state\r\n if (s.length === 2) {\r\n emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 2);\r\n }\r\n else if (s[2] === '>') {\r\n emitError(context, 14 /* MISSING_END_TAG_NAME */, 2);\r\n advanceBy(context, 3);\r\n continue;\r\n }\r\n else if (/[a-z]/i.test(s[2])) {\r\n emitError(context, 23 /* X_INVALID_END_TAG */);\r\n parseTag(context, 1 /* End */, parent);\r\n continue;\r\n }\r\n else {\r\n emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 2);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else if (/[a-z]/i.test(s[1])) {\r\n node = parseElement(context, ancestors);\r\n // 2.x <template> with no directive compat\r\n if (isCompatEnabled(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context) &&\r\n node &&\r\n node.tag === 'template' &&\r\n !node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n isSpecialTemplateDirective(p.name))) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warnDeprecation(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context, node.loc);\r\n node = node.children;\r\n }\r\n }\r\n else if (s[1] === '?') {\r\n emitError(context, 21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */, 1);\r\n node = parseBogusComment(context);\r\n }\r\n else {\r\n emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 1);\r\n }\r\n }\r\n }\r\n if (!node) {\r\n node = parseText(context, mode);\r\n }\r\n if (isArray(node)) {\r\n for (let i = 0; i < node.length; i++) {\r\n pushNode(nodes, node[i]);\r\n }\r\n }\r\n else {\r\n pushNode(nodes, node);\r\n }\r\n }\r\n // Whitespace handling strategy like v2\r\n let removedWhitespace = false;\r\n if (mode !== 2 /* RAWTEXT */ && mode !== 1 /* RCDATA */) {\r\n const shouldCondense = context.options.whitespace !== 'preserve';\r\n for (let i = 0; i < nodes.length; i++) {\r\n const node = nodes[i];\r\n if (!context.inPre && node.type === 2 /* TEXT */) {\r\n if (!/[^\\t\\r\\n\\f ]/.test(node.content)) {\r\n const prev = nodes[i - 1];\r\n const next = nodes[i + 1];\r\n // Remove if:\r\n // - the whitespace is the first or last node, or:\r\n // - (condense mode) the whitespace is adjacent to a comment, or:\r\n // - (condense mode) the whitespace is between two elements AND contains newline\r\n if (!prev ||\r\n !next ||\r\n (shouldCondense &&\r\n (prev.type === 3 /* COMMENT */ ||\r\n next.type === 3 /* COMMENT */ ||\r\n (prev.type === 1 /* ELEMENT */ &&\r\n next.type === 1 /* ELEMENT */ &&\r\n /[\\r\\n]/.test(node.content))))) {\r\n removedWhitespace = true;\r\n nodes[i] = null;\r\n }\r\n else {\r\n // Otherwise, the whitespace is condensed into a single space\r\n node.content = ' ';\r\n }\r\n }\r\n else if (shouldCondense) {\r\n // in condense mode, consecutive whitespaces in text are condensed\r\n // down to a single space.\r\n node.content = node.content.replace(/[\\t\\r\\n\\f ]+/g, ' ');\r\n }\r\n }\r\n // Remove comment nodes if desired by configuration.\r\n else if (node.type === 3 /* COMMENT */ && !context.options.comments) {\r\n removedWhitespace = true;\r\n nodes[i] = null;\r\n }\r\n }\r\n if (context.inPre && parent && context.options.isPreTag(parent.tag)) {\r\n // remove leading newline per html spec\r\n // https://html.spec.whatwg.org/multipage/grouping-content.html#the-pre-element\r\n const first = nodes[0];\r\n if (first && first.type === 2 /* TEXT */) {\r\n first.content = first.content.replace(/^\\r?\\n/, '');\r\n }\r\n }\r\n }\r\n return removedWhitespace ? nodes.filter(Boolean) : nodes;\r\n}\r\nfunction pushNode(nodes, node) {\r\n if (node.type === 2 /* TEXT */) {\r\n const prev = last(nodes);\r\n // Merge if both this and the previous node are text and those are\r\n // consecutive. This happens for cases like \"a < b\".\r\n if (prev &&\r\n prev.type === 2 /* TEXT */ &&\r\n prev.loc.end.offset === node.loc.start.offset) {\r\n prev.content += node.content;\r\n prev.loc.end = node.loc.end;\r\n prev.loc.source += node.loc.source;\r\n return;\r\n }\r\n }\r\n nodes.push(node);\r\n}\r\nfunction parseCDATA(context, ancestors) {\r\n advanceBy(context, 9);\r\n const nodes = parseChildren(context, 3 /* CDATA */, ancestors);\r\n if (context.source.length === 0) {\r\n emitError(context, 6 /* EOF_IN_CDATA */);\r\n }\r\n else {\r\n advanceBy(context, 3);\r\n }\r\n return nodes;\r\n}\r\nfunction parseComment(context) {\r\n const start = getCursor(context);\r\n let content;\r\n // Regular comment.\r\n const match = /--(\\!)?>/.exec(context.source);\r\n if (!match) {\r\n content = context.source.slice(4);\r\n advanceBy(context, context.source.length);\r\n emitError(context, 7 /* EOF_IN_COMMENT */);\r\n }\r\n else {\r\n if (match.index <= 3) {\r\n emitError(context, 0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */);\r\n }\r\n if (match[1]) {\r\n emitError(context, 10 /* INCORRECTLY_CLOSED_COMMENT */);\r\n }\r\n content = context.source.slice(4, match.index);\r\n // Advancing with reporting nested comments.\r\n const s = context.source.slice(0, match.index);\r\n let prevIndex = 1, nestedIndex = 0;\r\n while ((nestedIndex = s.indexOf('<!--', prevIndex)) !== -1) {\r\n advanceBy(context, nestedIndex - prevIndex + 1);\r\n if (nestedIndex + 4 < s.length) {\r\n emitError(context, 16 /* NESTED_COMMENT */);\r\n }\r\n prevIndex = nestedIndex + 1;\r\n }\r\n advanceBy(context, match.index + match[0].length - prevIndex + 1);\r\n }\r\n return {\r\n type: 3 /* COMMENT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseBogusComment(context) {\r\n const start = getCursor(context);\r\n const contentStart = context.source[1] === '?' ? 1 : 2;\r\n let content;\r\n const closeIndex = context.source.indexOf('>');\r\n if (closeIndex === -1) {\r\n content = context.source.slice(contentStart);\r\n advanceBy(context, context.source.length);\r\n }\r\n else {\r\n content = context.source.slice(contentStart, closeIndex);\r\n advanceBy(context, closeIndex + 1);\r\n }\r\n return {\r\n type: 3 /* COMMENT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseElement(context, ancestors) {\r\n // Start tag.\r\n const wasInPre = context.inPre;\r\n const wasInVPre = context.inVPre;\r\n const parent = last(ancestors);\r\n const element = parseTag(context, 0 /* Start */, parent);\r\n const isPreBoundary = context.inPre && !wasInPre;\r\n const isVPreBoundary = context.inVPre && !wasInVPre;\r\n if (element.isSelfClosing || context.options.isVoidTag(element.tag)) {\r\n // #4030 self-closing <pre> tag\r\n if (isPreBoundary) {\r\n context.inPre = false;\r\n }\r\n if (isVPreBoundary) {\r\n context.inVPre = false;\r\n }\r\n return element;\r\n }\r\n // Children.\r\n ancestors.push(element);\r\n const mode = context.options.getTextMode(element, parent);\r\n const children = parseChildren(context, mode, ancestors);\r\n ancestors.pop();\r\n // 2.x inline-template compat\r\n {\r\n const inlineTemplateProp = element.props.find(p => p.type === 6 /* ATTRIBUTE */ && p.name === 'inline-template');\r\n if (inlineTemplateProp &&\r\n checkCompatEnabled(\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */, context, inlineTemplateProp.loc)) {\r\n const loc = getSelection(context, element.loc.end);\r\n inlineTemplateProp.value = {\r\n type: 2 /* TEXT */,\r\n content: loc.source,\r\n loc\r\n };\r\n }\r\n }\r\n element.children = children;\r\n // End tag.\r\n if (startsWithEndTagOpen(context.source, element.tag)) {\r\n parseTag(context, 1 /* End */, parent);\r\n }\r\n else {\r\n emitError(context, 24 /* X_MISSING_END_TAG */, 0, element.loc.start);\r\n if (context.source.length === 0 && element.tag.toLowerCase() === 'script') {\r\n const first = children[0];\r\n if (first && startsWith(first.loc.source, '<!--')) {\r\n emitError(context, 8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */);\r\n }\r\n }\r\n }\r\n element.loc = getSelection(context, element.loc.start);\r\n if (isPreBoundary) {\r\n context.inPre = false;\r\n }\r\n if (isVPreBoundary) {\r\n context.inVPre = false;\r\n }\r\n return element;\r\n}\r\nconst isSpecialTemplateDirective = /*#__PURE__*/ makeMap(`if,else,else-if,for,slot`);\r\nfunction parseTag(context, type, parent) {\r\n // Tag open.\r\n const start = getCursor(context);\r\n const match = /^<\\/?([a-z][^\\t\\r\\n\\f />]*)/i.exec(context.source);\r\n const tag = match[1];\r\n const ns = context.options.getNamespace(tag, parent);\r\n advanceBy(context, match[0].length);\r\n advanceSpaces(context);\r\n // save current state in case we need to re-parse attributes with v-pre\r\n const cursor = getCursor(context);\r\n const currentSource = context.source;\r\n // check <pre> tag\r\n if (context.options.isPreTag(tag)) {\r\n context.inPre = true;\r\n }\r\n // Attributes.\r\n let props = parseAttributes(context, type);\r\n // check v-pre\r\n if (type === 0 /* Start */ &&\r\n !context.inVPre &&\r\n props.some(p => p.type === 7 /* DIRECTIVE */ && p.name === 'pre')) {\r\n context.inVPre = true;\r\n // reset context\r\n extend(context, cursor);\r\n context.source = currentSource;\r\n // re-parse attrs and filter out v-pre itself\r\n props = parseAttributes(context, type).filter(p => p.name !== 'v-pre');\r\n }\r\n // Tag close.\r\n let isSelfClosing = false;\r\n if (context.source.length === 0) {\r\n emitError(context, 9 /* EOF_IN_TAG */);\r\n }\r\n else {\r\n isSelfClosing = startsWith(context.source, '/>');\r\n if (type === 1 /* End */ && isSelfClosing) {\r\n emitError(context, 4 /* END_TAG_WITH_TRAILING_SOLIDUS */);\r\n }\r\n advanceBy(context, isSelfClosing ? 2 : 1);\r\n }\r\n if (type === 1 /* End */) {\r\n return;\r\n }\r\n // 2.x deprecation checks\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n isCompatEnabled(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context)) {\r\n let hasIf = false;\r\n let hasFor = false;\r\n for (let i = 0; i < props.length; i++) {\r\n const p = props[i];\r\n if (p.type === 7 /* DIRECTIVE */) {\r\n if (p.name === 'if') {\r\n hasIf = true;\r\n }\r\n else if (p.name === 'for') {\r\n hasFor = true;\r\n }\r\n }\r\n if (hasIf && hasFor) {\r\n warnDeprecation(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context, getSelection(context, start));\r\n break;\r\n }\r\n }\r\n }\r\n let tagType = 0 /* ELEMENT */;\r\n if (!context.inVPre) {\r\n if (tag === 'slot') {\r\n tagType = 2 /* SLOT */;\r\n }\r\n else if (tag === 'template') {\r\n if (props.some(p => p.type === 7 /* DIRECTIVE */ && isSpecialTemplateDirective(p.name))) {\r\n tagType = 3 /* TEMPLATE */;\r\n }\r\n }\r\n else if (isComponent(tag, props, context)) {\r\n tagType = 1 /* COMPONENT */;\r\n }\r\n }\r\n return {\r\n type: 1 /* ELEMENT */,\r\n ns,\r\n tag,\r\n tagType,\r\n props,\r\n isSelfClosing,\r\n children: [],\r\n loc: getSelection(context, start),\r\n codegenNode: undefined // to be created during transform phase\r\n };\r\n}\r\nfunction isComponent(tag, props, context) {\r\n const options = context.options;\r\n if (options.isCustomElement(tag)) {\r\n return false;\r\n }\r\n if (tag === 'component' ||\r\n /^[A-Z]/.test(tag) ||\r\n isCoreComponent(tag) ||\r\n (options.isBuiltInComponent && options.isBuiltInComponent(tag)) ||\r\n (options.isNativeTag && !options.isNativeTag(tag))) {\r\n return true;\r\n }\r\n // at this point the tag should be a native tag, but check for potential \"is\"\r\n // casting\r\n for (let i = 0; i < props.length; i++) {\r\n const p = props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (p.name === 'is' && p.value) {\r\n if (p.value.content.startsWith('vue:')) {\r\n return true;\r\n }\r\n else if (checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n return true;\r\n }\r\n }\r\n }\r\n else {\r\n // directive\r\n // v-is (TODO Deprecate)\r\n if (p.name === 'is') {\r\n return true;\r\n }\r\n else if (\r\n // :is on plain element - only treat as component in compat mode\r\n p.name === 'bind' &&\r\n isStaticArgOf(p.arg, 'is') &&\r\n true &&\r\n checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n return true;\r\n }\r\n }\r\n }\r\n}\r\nfunction parseAttributes(context, type) {\r\n const props = [];\r\n const attributeNames = new Set();\r\n while (context.source.length > 0 &&\r\n !startsWith(context.source, '>') &&\r\n !startsWith(context.source, '/>')) {\r\n if (startsWith(context.source, '/')) {\r\n emitError(context, 22 /* UNEXPECTED_SOLIDUS_IN_TAG */);\r\n advanceBy(context, 1);\r\n advanceSpaces(context);\r\n continue;\r\n }\r\n if (type === 1 /* End */) {\r\n emitError(context, 3 /* END_TAG_WITH_ATTRIBUTES */);\r\n }\r\n const attr = parseAttribute(context, attributeNames);\r\n // Trim whitespace between class\r\n // https://github.com/vuejs/vue-next/issues/4251\r\n if (attr.type === 6 /* ATTRIBUTE */ &&\r\n attr.value &&\r\n attr.name === 'class') {\r\n attr.value.content = attr.value.content.replace(/\\s+/g, ' ').trim();\r\n }\r\n if (type === 0 /* Start */) {\r\n props.push(attr);\r\n }\r\n if (/^[^\\t\\r\\n\\f />]/.test(context.source)) {\r\n emitError(context, 15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */);\r\n }\r\n advanceSpaces(context);\r\n }\r\n return props;\r\n}\r\nfunction parseAttribute(context, nameSet) {\r\n // Name.\r\n const start = getCursor(context);\r\n const match = /^[^\\t\\r\\n\\f />][^\\t\\r\\n\\f />=]*/.exec(context.source);\r\n const name = match[0];\r\n if (nameSet.has(name)) {\r\n emitError(context, 2 /* DUPLICATE_ATTRIBUTE */);\r\n }\r\n nameSet.add(name);\r\n if (name[0] === '=') {\r\n emitError(context, 19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */);\r\n }\r\n {\r\n const pattern = /[\"'<]/g;\r\n let m;\r\n while ((m = pattern.exec(name))) {\r\n emitError(context, 17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */, m.index);\r\n }\r\n }\r\n advanceBy(context, name.length);\r\n // Value\r\n let value = undefined;\r\n if (/^[\\t\\r\\n\\f ]*=/.test(context.source)) {\r\n advanceSpaces(context);\r\n advanceBy(context, 1);\r\n advanceSpaces(context);\r\n value = parseAttributeValue(context);\r\n if (!value) {\r\n emitError(context, 13 /* MISSING_ATTRIBUTE_VALUE */);\r\n }\r\n }\r\n const loc = getSelection(context, start);\r\n if (!context.inVPre && /^(v-[A-Za-z0-9-]|:|\\.|@|#)/.test(name)) {\r\n const match = /(?:^v-([a-z0-9-]+))?(?:(?::|^\\.|^@|^#)(\\[[^\\]]+\\]|[^\\.]+))?(.+)?$/i.exec(name);\r\n let isPropShorthand = startsWith(name, '.');\r\n let dirName = match[1] ||\r\n (isPropShorthand || startsWith(name, ':')\r\n ? 'bind'\r\n : startsWith(name, '@')\r\n ? 'on'\r\n : 'slot');\r\n let arg;\r\n if (match[2]) {\r\n const isSlot = dirName === 'slot';\r\n const startOffset = name.lastIndexOf(match[2]);\r\n const loc = getSelection(context, getNewPosition(context, start, startOffset), getNewPosition(context, start, startOffset + match[2].length + ((isSlot && match[3]) || '').length));\r\n let content = match[2];\r\n let isStatic = true;\r\n if (content.startsWith('[')) {\r\n isStatic = false;\r\n if (!content.endsWith(']')) {\r\n emitError(context, 27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */);\r\n content = content.slice(1);\r\n }\r\n else {\r\n content = content.slice(1, content.length - 1);\r\n }\r\n }\r\n else if (isSlot) {\r\n // #1241 special case for v-slot: vuetify relies extensively on slot\r\n // names containing dots. v-slot doesn't have any modifiers and Vue 2.x\r\n // supports such usage so we are keeping it consistent with 2.x.\r\n content += match[3] || '';\r\n }\r\n arg = {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n content,\r\n isStatic,\r\n constType: isStatic\r\n ? 3 /* CAN_STRINGIFY */\r\n : 0 /* NOT_CONSTANT */,\r\n loc\r\n };\r\n }\r\n if (value && value.isQuoted) {\r\n const valueLoc = value.loc;\r\n valueLoc.start.offset++;\r\n valueLoc.start.column++;\r\n valueLoc.end = advancePositionWithClone(valueLoc.start, value.content);\r\n valueLoc.source = valueLoc.source.slice(1, -1);\r\n }\r\n const modifiers = match[3] ? match[3].slice(1).split('.') : [];\r\n if (isPropShorthand)\r\n modifiers.push('prop');\r\n // 2.x compat v-bind:foo.sync -> v-model:foo\r\n if (dirName === 'bind' && arg) {\r\n if (modifiers.includes('sync') &&\r\n checkCompatEnabled(\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */, context, loc, arg.loc.source)) {\r\n dirName = 'model';\r\n modifiers.splice(modifiers.indexOf('sync'), 1);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && modifiers.includes('prop')) {\r\n checkCompatEnabled(\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */, context, loc);\r\n }\r\n }\r\n return {\r\n type: 7 /* DIRECTIVE */,\r\n name: dirName,\r\n exp: value && {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n content: value.content,\r\n isStatic: false,\r\n // Treat as non-constant by default. This can be potentially set to\r\n // other values by `transformExpression` to make it eligible for hoisting.\r\n constType: 0 /* NOT_CONSTANT */,\r\n loc: value.loc\r\n },\r\n arg,\r\n modifiers,\r\n loc\r\n };\r\n }\r\n // missing directive name or illegal directive name\r\n if (!context.inVPre && startsWith(name, 'v-')) {\r\n emitError(context, 26 /* X_MISSING_DIRECTIVE_NAME */);\r\n }\r\n return {\r\n type: 6 /* ATTRIBUTE */,\r\n name,\r\n value: value && {\r\n type: 2 /* TEXT */,\r\n content: value.content,\r\n loc: value.loc\r\n },\r\n loc\r\n };\r\n}\r\nfunction parseAttributeValue(context) {\r\n const start = getCursor(context);\r\n let content;\r\n const quote = context.source[0];\r\n const isQuoted = quote === `\"` || quote === `'`;\r\n if (isQuoted) {\r\n // Quoted value.\r\n advanceBy(context, 1);\r\n const endIndex = context.source.indexOf(quote);\r\n if (endIndex === -1) {\r\n content = parseTextData(context, context.source.length, 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n else {\r\n content = parseTextData(context, endIndex, 4 /* ATTRIBUTE_VALUE */);\r\n advanceBy(context, 1);\r\n }\r\n }\r\n else {\r\n // Unquoted\r\n const match = /^[^\\t\\r\\n\\f >]+/.exec(context.source);\r\n if (!match) {\r\n return undefined;\r\n }\r\n const unexpectedChars = /[\"'<=`]/g;\r\n let m;\r\n while ((m = unexpectedChars.exec(match[0]))) {\r\n emitError(context, 18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */, m.index);\r\n }\r\n content = parseTextData(context, match[0].length, 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n return { content, isQuoted, loc: getSelection(context, start) };\r\n}\r\nfunction parseInterpolation(context, mode) {\r\n const [open, close] = context.options.delimiters;\r\n const closeIndex = context.source.indexOf(close, open.length);\r\n if (closeIndex === -1) {\r\n emitError(context, 25 /* X_MISSING_INTERPOLATION_END */);\r\n return undefined;\r\n }\r\n const start = getCursor(context);\r\n advanceBy(context, open.length);\r\n const innerStart = getCursor(context);\r\n const innerEnd = getCursor(context);\r\n const rawContentLength = closeIndex - open.length;\r\n const rawContent = context.source.slice(0, rawContentLength);\r\n const preTrimContent = parseTextData(context, rawContentLength, mode);\r\n const content = preTrimContent.trim();\r\n const startOffset = preTrimContent.indexOf(content);\r\n if (startOffset > 0) {\r\n advancePositionWithMutation(innerStart, rawContent, startOffset);\r\n }\r\n const endOffset = rawContentLength - (preTrimContent.length - content.length - startOffset);\r\n advancePositionWithMutation(innerEnd, rawContent, endOffset);\r\n advanceBy(context, close.length);\r\n return {\r\n type: 5 /* INTERPOLATION */,\r\n content: {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n isStatic: false,\r\n // Set `isConstant` to false by default and will decide in transformExpression\r\n constType: 0 /* NOT_CONSTANT */,\r\n content,\r\n loc: getSelection(context, innerStart, innerEnd)\r\n },\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseText(context, mode) {\r\n const endTokens = mode === 3 /* CDATA */ ? [']]>'] : ['<', context.options.delimiters[0]];\r\n let endIndex = context.source.length;\r\n for (let i = 0; i < endTokens.length; i++) {\r\n const index = context.source.indexOf(endTokens[i], 1);\r\n if (index !== -1 && endIndex > index) {\r\n endIndex = index;\r\n }\r\n }\r\n const start = getCursor(context);\r\n const content = parseTextData(context, endIndex, mode);\r\n return {\r\n type: 2 /* TEXT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\n/**\r\n * Get text data with a given length from the current location.\r\n * This translates HTML entities in the text data.\r\n */\r\nfunction parseTextData(context, length, mode) {\r\n const rawText = context.source.slice(0, length);\r\n advanceBy(context, length);\r\n if (mode === 2 /* RAWTEXT */ ||\r\n mode === 3 /* CDATA */ ||\r\n rawText.indexOf('&') === -1) {\r\n return rawText;\r\n }\r\n else {\r\n // DATA or RCDATA containing \"&\"\". Entity decoding required.\r\n return context.options.decodeEntities(rawText, mode === 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n}\r\nfunction getCursor(context) {\r\n const { column, line, offset } = context;\r\n return { column, line, offset };\r\n}\r\nfunction getSelection(context, start, end) {\r\n end = end || getCursor(context);\r\n return {\r\n start,\r\n end,\r\n source: context.originalSource.slice(start.offset, end.offset)\r\n };\r\n}\r\nfunction last(xs) {\r\n return xs[xs.length - 1];\r\n}\r\nfunction startsWith(source, searchString) {\r\n return source.startsWith(searchString);\r\n}\r\nfunction advanceBy(context, numberOfCharacters) {\r\n const { source } = context;\r\n advancePositionWithMutation(context, source, numberOfCharacters);\r\n context.source = source.slice(numberOfCharacters);\r\n}\r\nfunction advanceSpaces(context) {\r\n const match = /^[\\t\\r\\n\\f ]+/.exec(context.source);\r\n if (match) {\r\n advanceBy(context, match[0].length);\r\n }\r\n}\r\nfunction getNewPosition(context, start, numberOfCharacters) {\r\n return advancePositionWithClone(start, context.originalSource.slice(start.offset, numberOfCharacters), numberOfCharacters);\r\n}\r\nfunction emitError(context, code, offset, loc = getCursor(context)) {\r\n if (offset) {\r\n loc.offset += offset;\r\n loc.column += offset;\r\n }\r\n context.options.onError(createCompilerError(code, {\r\n start: loc,\r\n end: loc,\r\n source: ''\r\n }));\r\n}\r\nfunction isEnd(context, mode, ancestors) {\r\n const s = context.source;\r\n switch (mode) {\r\n case 0 /* DATA */:\r\n if (startsWith(s, '</')) {\r\n // TODO: probably bad performance\r\n for (let i = ancestors.length - 1; i >= 0; --i) {\r\n if (startsWithEndTagOpen(s, ancestors[i].tag)) {\r\n return true;\r\n }\r\n }\r\n }\r\n break;\r\n case 1 /* RCDATA */:\r\n case 2 /* RAWTEXT */: {\r\n const parent = last(ancestors);\r\n if (parent && startsWithEndTagOpen(s, parent.tag)) {\r\n return true;\r\n }\r\n break;\r\n }\r\n case 3 /* CDATA */:\r\n if (startsWith(s, ']]>')) {\r\n return true;\r\n }\r\n break;\r\n }\r\n return !s;\r\n}\r\nfunction startsWithEndTagOpen(source, tag) {\r\n return (startsWith(source, '</') &&\r\n source.slice(2, 2 + tag.length).toLowerCase() === tag.toLowerCase() &&\r\n /[\\t\\r\\n\\f />]/.test(source[2 + tag.length] || '>'));\r\n}\n\nfunction hoistStatic(root, context) {\r\n walk(root, context, \r\n // Root node is unfortunately non-hoistable due to potential parent\r\n // fallthrough attributes.\r\n isSingleElementRoot(root, root.children[0]));\r\n}\r\nfunction isSingleElementRoot(root, child) {\r\n const { children } = root;\r\n return (children.length === 1 &&\r\n child.type === 1 /* ELEMENT */ &&\r\n !isSlotOutlet(child));\r\n}\r\nfunction walk(node, context, doNotHoistNode = false) {\r\n const { children } = node;\r\n const originalCount = children.length;\r\n let hoistedCount = 0;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n // only plain elements & text calls are eligible for hoisting.\r\n if (child.type === 1 /* ELEMENT */ &&\r\n child.tagType === 0 /* ELEMENT */) {\r\n const constantType = doNotHoistNode\r\n ? 0 /* NOT_CONSTANT */\r\n : getConstantType(child, context);\r\n if (constantType > 0 /* NOT_CONSTANT */) {\r\n if (constantType >= 2 /* CAN_HOIST */) {\r\n child.codegenNode.patchFlag =\r\n -1 /* HOISTED */ + ((process.env.NODE_ENV !== 'production') ? ` /* HOISTED */` : ``);\r\n child.codegenNode = context.hoist(child.codegenNode);\r\n hoistedCount++;\r\n continue;\r\n }\r\n }\r\n else {\r\n // node may contain dynamic children, but its props may be eligible for\r\n // hoisting.\r\n const codegenNode = child.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n const flag = getPatchFlag(codegenNode);\r\n if ((!flag ||\r\n flag === 512 /* NEED_PATCH */ ||\r\n flag === 1 /* TEXT */) &&\r\n getGeneratedPropsConstantType(child, context) >=\r\n 2 /* CAN_HOIST */) {\r\n const props = getNodeProps(child);\r\n if (props) {\r\n codegenNode.props = context.hoist(props);\r\n }\r\n }\r\n if (codegenNode.dynamicProps) {\r\n codegenNode.dynamicProps = context.hoist(codegenNode.dynamicProps);\r\n }\r\n }\r\n }\r\n }\r\n else if (child.type === 12 /* TEXT_CALL */ &&\r\n getConstantType(child.content, context) >= 2 /* CAN_HOIST */) {\r\n child.codegenNode = context.hoist(child.codegenNode);\r\n hoistedCount++;\r\n }\r\n // walk further\r\n if (child.type === 1 /* ELEMENT */) {\r\n const isComponent = child.tagType === 1 /* COMPONENT */;\r\n if (isComponent) {\r\n context.scopes.vSlot++;\r\n }\r\n walk(child, context);\r\n if (isComponent) {\r\n context.scopes.vSlot--;\r\n }\r\n }\r\n else if (child.type === 11 /* FOR */) {\r\n // Do not hoist v-for single child because it has to be a block\r\n walk(child, context, child.children.length === 1);\r\n }\r\n else if (child.type === 9 /* IF */) {\r\n for (let i = 0; i < child.branches.length; i++) {\r\n // Do not hoist v-if single child because it has to be a block\r\n walk(child.branches[i], context, child.branches[i].children.length === 1);\r\n }\r\n }\r\n }\r\n if (hoistedCount && context.transformHoist) {\r\n context.transformHoist(children, context, node);\r\n }\r\n // all children were hoisted - the entire children array is hoistable.\r\n if (hoistedCount &&\r\n hoistedCount === originalCount &&\r\n node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n node.codegenNode &&\r\n node.codegenNode.type === 13 /* VNODE_CALL */ &&\r\n isArray(node.codegenNode.children)) {\r\n node.codegenNode.children = context.hoist(createArrayExpression(node.codegenNode.children));\r\n }\r\n}\r\nfunction getConstantType(node, context) {\r\n const { constantCache } = context;\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n if (node.tagType !== 0 /* ELEMENT */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n const cached = constantCache.get(node);\r\n if (cached !== undefined) {\r\n return cached;\r\n }\r\n const codegenNode = node.codegenNode;\r\n if (codegenNode.type !== 13 /* VNODE_CALL */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (codegenNode.isBlock &&\r\n node.tag !== 'svg' &&\r\n node.tag !== 'foreignObject') {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n const flag = getPatchFlag(codegenNode);\r\n if (!flag) {\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n // Element itself has no patch flag. However we still need to check:\r\n // 1. Even for a node with no patch flag, it is possible for it to contain\r\n // non-hoistable expressions that refers to scope variables, e.g. compiler\r\n // injected keys or cached event handlers. Therefore we need to always\r\n // check the codegenNode's props to be sure.\r\n const generatedPropsType = getGeneratedPropsConstantType(node, context);\r\n if (generatedPropsType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (generatedPropsType < returnType) {\r\n returnType = generatedPropsType;\r\n }\r\n // 2. its children.\r\n for (let i = 0; i < node.children.length; i++) {\r\n const childType = getConstantType(node.children[i], context);\r\n if (childType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (childType < returnType) {\r\n returnType = childType;\r\n }\r\n }\r\n // 3. if the type is not already CAN_SKIP_PATCH which is the lowest non-0\r\n // type, check if any of the props can cause the type to be lowered\r\n // we can skip can_patch because it's guaranteed by the absence of a\r\n // patchFlag.\r\n if (returnType > 1 /* CAN_SKIP_PATCH */) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ && p.name === 'bind' && p.exp) {\r\n const expType = getConstantType(p.exp, context);\r\n if (expType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (expType < returnType) {\r\n returnType = expType;\r\n }\r\n }\r\n }\r\n }\r\n // only svg/foreignObject could be block here, however if they are\r\n // static then they don't need to be blocks since there will be no\r\n // nested updates.\r\n if (codegenNode.isBlock) {\r\n context.removeHelper(OPEN_BLOCK);\r\n context.removeHelper(getVNodeBlockHelper(context.inSSR, codegenNode.isComponent));\r\n codegenNode.isBlock = false;\r\n context.helper(getVNodeHelper(context.inSSR, codegenNode.isComponent));\r\n }\r\n constantCache.set(node, returnType);\r\n return returnType;\r\n }\r\n else {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n case 2 /* TEXT */:\r\n case 3 /* COMMENT */:\r\n return 3 /* CAN_STRINGIFY */;\r\n case 9 /* IF */:\r\n case 11 /* FOR */:\r\n case 10 /* IF_BRANCH */:\r\n return 0 /* NOT_CONSTANT */;\r\n case 5 /* INTERPOLATION */:\r\n case 12 /* TEXT_CALL */:\r\n return getConstantType(node.content, context);\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n return node.constType;\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (isString(child) || isSymbol(child)) {\r\n continue;\r\n }\r\n const childType = getConstantType(child, context);\r\n if (childType === 0 /* NOT_CONSTANT */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n else if (childType < returnType) {\r\n returnType = childType;\r\n }\r\n }\r\n return returnType;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) ;\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n}\r\nconst allowHoistedHelperSet = new Set([\r\n NORMALIZE_CLASS,\r\n NORMALIZE_STYLE,\r\n NORMALIZE_PROPS,\r\n GUARD_REACTIVE_PROPS\r\n]);\r\nfunction getConstantTypeOfHelperCall(value, context) {\r\n if (value.type === 14 /* JS_CALL_EXPRESSION */ &&\r\n !isString(value.callee) &&\r\n allowHoistedHelperSet.has(value.callee)) {\r\n const arg = value.arguments[0];\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n return getConstantType(arg, context);\r\n }\r\n else if (arg.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(exp))`\r\n return getConstantTypeOfHelperCall(arg, context);\r\n }\r\n }\r\n return 0 /* NOT_CONSTANT */;\r\n}\r\nfunction getGeneratedPropsConstantType(node, context) {\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n const props = getNodeProps(node);\r\n if (props && props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n const { properties } = props;\r\n for (let i = 0; i < properties.length; i++) {\r\n const { key, value } = properties[i];\r\n const keyType = getConstantType(key, context);\r\n if (keyType === 0 /* NOT_CONSTANT */) {\r\n return keyType;\r\n }\r\n if (keyType < returnType) {\r\n returnType = keyType;\r\n }\r\n let valueType;\r\n if (value.type === 4 /* SIMPLE_EXPRESSION */) {\r\n valueType = getConstantType(value, context);\r\n }\r\n else if (value.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // some helper calls can be hoisted,\r\n // such as the `normalizeProps` generated by the compiler for pre-normalize class,\r\n // in this case we need to respect the ConstantType of the helper's arguments\r\n valueType = getConstantTypeOfHelperCall(value, context);\r\n }\r\n else {\r\n valueType = 0 /* NOT_CONSTANT */;\r\n }\r\n if (valueType === 0 /* NOT_CONSTANT */) {\r\n return valueType;\r\n }\r\n if (valueType < returnType) {\r\n returnType = valueType;\r\n }\r\n }\r\n }\r\n return returnType;\r\n}\r\nfunction getNodeProps(node) {\r\n const codegenNode = node.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n return codegenNode.props;\r\n }\r\n}\r\nfunction getPatchFlag(node) {\r\n const flag = node.patchFlag;\r\n return flag ? parseInt(flag, 10) : undefined;\r\n}\n\nfunction createTransformContext(root, { filename = '', prefixIdentifiers = false, hoistStatic = false, cacheHandlers = false, nodeTransforms = [], directiveTransforms = {}, transformHoist = null, isBuiltInComponent = NOOP, isCustomElement = NOOP, expressionPlugins = [], scopeId = null, slotted = true, ssr = false, inSSR = false, ssrCssVars = ``, bindingMetadata = EMPTY_OBJ, inline = false, isTS = false, onError = defaultOnError, onWarn = defaultOnWarn, compatConfig }) {\r\n const nameMatch = filename.replace(/\\?.*$/, '').match(/([^/\\\\]+)\\.\\w+$/);\r\n const context = {\r\n // options\r\n selfName: nameMatch && capitalize(camelize$1(nameMatch[1])),\r\n prefixIdentifiers,\r\n hoistStatic,\r\n cacheHandlers,\r\n nodeTransforms,\r\n directiveTransforms,\r\n transformHoist,\r\n isBuiltInComponent,\r\n isCustomElement,\r\n expressionPlugins,\r\n scopeId,\r\n slotted,\r\n ssr,\r\n inSSR,\r\n ssrCssVars,\r\n bindingMetadata,\r\n inline,\r\n isTS,\r\n onError,\r\n onWarn,\r\n compatConfig,\r\n // state\r\n root,\r\n helpers: new Map(),\r\n components: new Set(),\r\n directives: new Set(),\r\n hoists: [],\r\n imports: [],\r\n constantCache: new Map(),\r\n temps: 0,\r\n cached: 0,\r\n identifiers: Object.create(null),\r\n scopes: {\r\n vFor: 0,\r\n vSlot: 0,\r\n vPre: 0,\r\n vOnce: 0\r\n },\r\n parent: null,\r\n currentNode: root,\r\n childIndex: 0,\r\n inVOnce: false,\r\n // methods\r\n helper(name) {\r\n const count = context.helpers.get(name) || 0;\r\n context.helpers.set(name, count + 1);\r\n return name;\r\n },\r\n removeHelper(name) {\r\n const count = context.helpers.get(name);\r\n if (count) {\r\n const currentCount = count - 1;\r\n if (!currentCount) {\r\n context.helpers.delete(name);\r\n }\r\n else {\r\n context.helpers.set(name, currentCount);\r\n }\r\n }\r\n },\r\n helperString(name) {\r\n return `_${helperNameMap[context.helper(name)]}`;\r\n },\r\n replaceNode(node) {\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!context.currentNode) {\r\n throw new Error(`Node being replaced is already removed.`);\r\n }\r\n if (!context.parent) {\r\n throw new Error(`Cannot replace root node.`);\r\n }\r\n }\r\n context.parent.children[context.childIndex] = context.currentNode = node;\r\n },\r\n removeNode(node) {\r\n if ((process.env.NODE_ENV !== 'production') && !context.parent) {\r\n throw new Error(`Cannot remove root node.`);\r\n }\r\n const list = context.parent.children;\r\n const removalIndex = node\r\n ? list.indexOf(node)\r\n : context.currentNode\r\n ? context.childIndex\r\n : -1;\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production') && removalIndex < 0) {\r\n throw new Error(`node being removed is not a child of current parent`);\r\n }\r\n if (!node || node === context.currentNode) {\r\n // current node removed\r\n context.currentNode = null;\r\n context.onNodeRemoved();\r\n }\r\n else {\r\n // sibling node removed\r\n if (context.childIndex > removalIndex) {\r\n context.childIndex--;\r\n context.onNodeRemoved();\r\n }\r\n }\r\n context.parent.children.splice(removalIndex, 1);\r\n },\r\n onNodeRemoved: () => { },\r\n addIdentifiers(exp) {\r\n },\r\n removeIdentifiers(exp) {\r\n },\r\n hoist(exp) {\r\n if (isString(exp))\r\n exp = createSimpleExpression(exp);\r\n context.hoists.push(exp);\r\n const identifier = createSimpleExpression(`_hoisted_${context.hoists.length}`, false, exp.loc, 2 /* CAN_HOIST */);\r\n identifier.hoisted = exp;\r\n return identifier;\r\n },\r\n cache(exp, isVNode = false) {\r\n return createCacheExpression(context.cached++, exp, isVNode);\r\n }\r\n };\r\n {\r\n context.filters = new Set();\r\n }\r\n return context;\r\n}\r\nfunction transform(root, options) {\r\n const context = createTransformContext(root, options);\r\n traverseNode(root, context);\r\n if (options.hoistStatic) {\r\n hoistStatic(root, context);\r\n }\r\n if (!options.ssr) {\r\n createRootCodegen(root, context);\r\n }\r\n // finalize meta information\r\n root.helpers = [...context.helpers.keys()];\r\n root.components = [...context.components];\r\n root.directives = [...context.directives];\r\n root.imports = context.imports;\r\n root.hoists = context.hoists;\r\n root.temps = context.temps;\r\n root.cached = context.cached;\r\n {\r\n root.filters = [...context.filters];\r\n }\r\n}\r\nfunction createRootCodegen(root, context) {\r\n const { helper } = context;\r\n const { children } = root;\r\n if (children.length === 1) {\r\n const child = children[0];\r\n // if the single child is an element, turn it into a block.\r\n if (isSingleElementRoot(root, child) && child.codegenNode) {\r\n // single element root is never hoisted so codegenNode will never be\r\n // SimpleExpressionNode\r\n const codegenNode = child.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n makeBlock(codegenNode, context);\r\n }\r\n root.codegenNode = codegenNode;\r\n }\r\n else {\r\n // - single <slot/>, IfNode, ForNode: already blocks.\r\n // - single text node: always patched.\r\n // root codegen falls through via genNode()\r\n root.codegenNode = child;\r\n }\r\n }\r\n else if (children.length > 1) {\r\n // root has multiple nodes - return a fragment block.\r\n let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n // check if the fragment actually contains a single valid child with\r\n // the rest being comments\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n }\r\n root.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, root.children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n }\r\n else ;\r\n}\r\nfunction traverseChildren(parent, context) {\r\n let i = 0;\r\n const nodeRemoved = () => {\r\n i--;\r\n };\r\n for (; i < parent.children.length; i++) {\r\n const child = parent.children[i];\r\n if (isString(child))\r\n continue;\r\n context.parent = parent;\r\n context.childIndex = i;\r\n context.onNodeRemoved = nodeRemoved;\r\n traverseNode(child, context);\r\n }\r\n}\r\nfunction traverseNode(node, context) {\r\n context.currentNode = node;\r\n // apply transform plugins\r\n const { nodeTransforms } = context;\r\n const exitFns = [];\r\n for (let i = 0; i < nodeTransforms.length; i++) {\r\n const onExit = nodeTransforms[i](node, context);\r\n if (onExit) {\r\n if (isArray(onExit)) {\r\n exitFns.push(...onExit);\r\n }\r\n else {\r\n exitFns.push(onExit);\r\n }\r\n }\r\n if (!context.currentNode) {\r\n // node was removed\r\n return;\r\n }\r\n else {\r\n // node may have been replaced\r\n node = context.currentNode;\r\n }\r\n }\r\n switch (node.type) {\r\n case 3 /* COMMENT */:\r\n if (!context.ssr) {\r\n // inject import for the Comment symbol, which is needed for creating\r\n // comment nodes with `createVNode`\r\n context.helper(CREATE_COMMENT);\r\n }\r\n break;\r\n case 5 /* INTERPOLATION */:\r\n // no need to traverse, but we need to inject toString helper\r\n if (!context.ssr) {\r\n context.helper(TO_DISPLAY_STRING);\r\n }\r\n break;\r\n // for container types, further traverse downwards\r\n case 9 /* IF */:\r\n for (let i = 0; i < node.branches.length; i++) {\r\n traverseNode(node.branches[i], context);\r\n }\r\n break;\r\n case 10 /* IF_BRANCH */:\r\n case 11 /* FOR */:\r\n case 1 /* ELEMENT */:\r\n case 0 /* ROOT */:\r\n traverseChildren(node, context);\r\n break;\r\n }\r\n // exit transforms\r\n context.currentNode = node;\r\n let i = exitFns.length;\r\n while (i--) {\r\n exitFns[i]();\r\n }\r\n}\r\nfunction createStructuralDirectiveTransform(name, fn) {\r\n const matches = isString(name)\r\n ? (n) => n === name\r\n : (n) => name.test(n);\r\n return (node, context) => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n const { props } = node;\r\n // structural directive transforms are not concerned with slots\r\n // as they are handled separately in vSlot.ts\r\n if (node.tagType === 3 /* TEMPLATE */ && props.some(isVSlot)) {\r\n return;\r\n }\r\n const exitFns = [];\r\n for (let i = 0; i < props.length; i++) {\r\n const prop = props[i];\r\n if (prop.type === 7 /* DIRECTIVE */ && matches(prop.name)) {\r\n // structural directives are removed to avoid infinite recursion\r\n // also we remove them *before* applying so that it can further\r\n // traverse itself in case it moves the node around\r\n props.splice(i, 1);\r\n i--;\r\n const onExit = fn(node, prop, context);\r\n if (onExit)\r\n exitFns.push(onExit);\r\n }\r\n }\r\n return exitFns;\r\n }\r\n };\r\n}\n\nconst PURE_ANNOTATION = `/*#__PURE__*/`;\r\nfunction createCodegenContext(ast, { mode = 'function', prefixIdentifiers = mode === 'module', sourceMap = false, filename = `template.vue.html`, scopeId = null, optimizeImports = false, runtimeGlobalName = `Vue`, runtimeModuleName = `vue`, ssrRuntimeModuleName = 'vue/server-renderer', ssr = false, isTS = false, inSSR = false }) {\r\n const context = {\r\n mode,\r\n prefixIdentifiers,\r\n sourceMap,\r\n filename,\r\n scopeId,\r\n optimizeImports,\r\n runtimeGlobalName,\r\n runtimeModuleName,\r\n ssrRuntimeModuleName,\r\n ssr,\r\n isTS,\r\n inSSR,\r\n source: ast.loc.source,\r\n code: ``,\r\n column: 1,\r\n line: 1,\r\n offset: 0,\r\n indentLevel: 0,\r\n pure: false,\r\n map: undefined,\r\n helper(key) {\r\n return `_${helperNameMap[key]}`;\r\n },\r\n push(code, node) {\r\n context.code += code;\r\n },\r\n indent() {\r\n newline(++context.indentLevel);\r\n },\r\n deindent(withoutNewLine = false) {\r\n if (withoutNewLine) {\r\n --context.indentLevel;\r\n }\r\n else {\r\n newline(--context.indentLevel);\r\n }\r\n },\r\n newline() {\r\n newline(context.indentLevel);\r\n }\r\n };\r\n function newline(n) {\r\n context.push('\\n' + ` `.repeat(n));\r\n }\r\n return context;\r\n}\r\nfunction generate(ast, options = {}) {\r\n const context = createCodegenContext(ast, options);\r\n if (options.onContextCreated)\r\n options.onContextCreated(context);\r\n const { mode, push, prefixIdentifiers, indent, deindent, newline, scopeId, ssr } = context;\r\n const hasHelpers = ast.helpers.length > 0;\r\n const useWithBlock = !prefixIdentifiers && mode !== 'module';\r\n // preambles\r\n // in setup() inline mode, the preamble is generated in a sub context\r\n // and returned separately.\r\n const preambleContext = context;\r\n {\r\n genFunctionPreamble(ast, preambleContext);\r\n }\r\n // enter render function\r\n const functionName = ssr ? `ssrRender` : `render`;\r\n const args = ssr ? ['_ctx', '_push', '_parent', '_attrs'] : ['_ctx', '_cache'];\r\n const signature = args.join(', ');\r\n {\r\n push(`function ${functionName}(${signature}) {`);\r\n }\r\n indent();\r\n if (useWithBlock) {\r\n push(`with (_ctx) {`);\r\n indent();\r\n // function mode const declarations should be inside with block\r\n // also they should be renamed to avoid collision with user properties\r\n if (hasHelpers) {\r\n push(`const { ${ast.helpers\r\n .map(s => `${helperNameMap[s]}: _${helperNameMap[s]}`)\r\n .join(', ')} } = _Vue`);\r\n push(`\\n`);\r\n newline();\r\n }\r\n }\r\n // generate asset resolution statements\r\n if (ast.components.length) {\r\n genAssets(ast.components, 'component', context);\r\n if (ast.directives.length || ast.temps > 0) {\r\n newline();\r\n }\r\n }\r\n if (ast.directives.length) {\r\n genAssets(ast.directives, 'directive', context);\r\n if (ast.temps > 0) {\r\n newline();\r\n }\r\n }\r\n if (ast.filters && ast.filters.length) {\r\n newline();\r\n genAssets(ast.filters, 'filter', context);\r\n newline();\r\n }\r\n if (ast.temps > 0) {\r\n push(`let `);\r\n for (let i = 0; i < ast.temps; i++) {\r\n push(`${i > 0 ? `, ` : ``}_temp${i}`);\r\n }\r\n }\r\n if (ast.components.length || ast.directives.length || ast.temps) {\r\n push(`\\n`);\r\n newline();\r\n }\r\n // generate the VNode tree expression\r\n if (!ssr) {\r\n push(`return `);\r\n }\r\n if (ast.codegenNode) {\r\n genNode(ast.codegenNode, context);\r\n }\r\n else {\r\n push(`null`);\r\n }\r\n if (useWithBlock) {\r\n deindent();\r\n push(`}`);\r\n }\r\n deindent();\r\n push(`}`);\r\n return {\r\n ast,\r\n code: context.code,\r\n preamble: ``,\r\n // SourceMapGenerator does have toJSON() method but it's not in the types\r\n map: context.map ? context.map.toJSON() : undefined\r\n };\r\n}\r\nfunction genFunctionPreamble(ast, context) {\r\n const { ssr, prefixIdentifiers, push, newline, runtimeModuleName, runtimeGlobalName, ssrRuntimeModuleName } = context;\r\n const VueBinding = runtimeGlobalName;\r\n const aliasHelper = (s) => `${helperNameMap[s]}: _${helperNameMap[s]}`;\r\n // Generate const declaration for helpers\r\n // In prefix mode, we place the const declaration at top so it's done\r\n // only once; But if we not prefixing, we place the declaration inside the\r\n // with block so it doesn't incur the `in` check cost for every helper access.\r\n if (ast.helpers.length > 0) {\r\n {\r\n // \"with\" mode.\r\n // save Vue in a separate variable to avoid collision\r\n push(`const _Vue = ${VueBinding}\\n`);\r\n // in \"with\" mode, helpers are declared inside the with block to avoid\r\n // has check cost, but hoists are lifted out of the function - we need\r\n // to provide the helper here.\r\n if (ast.hoists.length) {\r\n const staticHelpers = [\r\n CREATE_VNODE,\r\n CREATE_ELEMENT_VNODE,\r\n CREATE_COMMENT,\r\n CREATE_TEXT,\r\n CREATE_STATIC\r\n ]\r\n .filter(helper => ast.helpers.includes(helper))\r\n .map(aliasHelper)\r\n .join(', ');\r\n push(`const { ${staticHelpers} } = _Vue\\n`);\r\n }\r\n }\r\n }\r\n genHoists(ast.hoists, context);\r\n newline();\r\n push(`return `);\r\n}\r\nfunction genAssets(assets, type, { helper, push, newline, isTS }) {\r\n const resolver = helper(type === 'filter'\r\n ? RESOLVE_FILTER\r\n : type === 'component'\r\n ? RESOLVE_COMPONENT\r\n : RESOLVE_DIRECTIVE);\r\n for (let i = 0; i < assets.length; i++) {\r\n let id = assets[i];\r\n // potential component implicit self-reference inferred from SFC filename\r\n const maybeSelfReference = id.endsWith('__self');\r\n if (maybeSelfReference) {\r\n id = id.slice(0, -6);\r\n }\r\n push(`const ${toValidAssetId(id, type)} = ${resolver}(${JSON.stringify(id)}${maybeSelfReference ? `, true` : ``})${isTS ? `!` : ``}`);\r\n if (i < assets.length - 1) {\r\n newline();\r\n }\r\n }\r\n}\r\nfunction genHoists(hoists, context) {\r\n if (!hoists.length) {\r\n return;\r\n }\r\n context.pure = true;\r\n const { push, newline, helper, scopeId, mode } = context;\r\n newline();\r\n for (let i = 0; i < hoists.length; i++) {\r\n const exp = hoists[i];\r\n if (exp) {\r\n push(`const _hoisted_${i + 1} = ${``}`);\r\n genNode(exp, context);\r\n newline();\r\n }\r\n }\r\n context.pure = false;\r\n}\r\nfunction isText$1(n) {\r\n return (isString(n) ||\r\n n.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n n.type === 2 /* TEXT */ ||\r\n n.type === 5 /* INTERPOLATION */ ||\r\n n.type === 8 /* COMPOUND_EXPRESSION */);\r\n}\r\nfunction genNodeListAsArray(nodes, context) {\r\n const multilines = nodes.length > 3 ||\r\n (((process.env.NODE_ENV !== 'production')) && nodes.some(n => isArray(n) || !isText$1(n)));\r\n context.push(`[`);\r\n multilines && context.indent();\r\n genNodeList(nodes, context, multilines);\r\n multilines && context.deindent();\r\n context.push(`]`);\r\n}\r\nfunction genNodeList(nodes, context, multilines = false, comma = true) {\r\n const { push, newline } = context;\r\n for (let i = 0; i < nodes.length; i++) {\r\n const node = nodes[i];\r\n if (isString(node)) {\r\n push(node);\r\n }\r\n else if (isArray(node)) {\r\n genNodeListAsArray(node, context);\r\n }\r\n else {\r\n genNode(node, context);\r\n }\r\n if (i < nodes.length - 1) {\r\n if (multilines) {\r\n comma && push(',');\r\n newline();\r\n }\r\n else {\r\n comma && push(', ');\r\n }\r\n }\r\n }\r\n}\r\nfunction genNode(node, context) {\r\n if (isString(node)) {\r\n context.push(node);\r\n return;\r\n }\r\n if (isSymbol(node)) {\r\n context.push(context.helper(node));\r\n return;\r\n }\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n case 9 /* IF */:\r\n case 11 /* FOR */:\r\n (process.env.NODE_ENV !== 'production') &&\r\n assert(node.codegenNode != null, `Codegen node is missing for element/if/for node. ` +\r\n `Apply appropriate transforms first.`);\r\n genNode(node.codegenNode, context);\r\n break;\r\n case 2 /* TEXT */:\r\n genText(node, context);\r\n break;\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n genExpression(node, context);\r\n break;\r\n case 5 /* INTERPOLATION */:\r\n genInterpolation(node, context);\r\n break;\r\n case 12 /* TEXT_CALL */:\r\n genNode(node.codegenNode, context);\r\n break;\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n genCompoundExpression(node, context);\r\n break;\r\n case 3 /* COMMENT */:\r\n genComment(node, context);\r\n break;\r\n case 13 /* VNODE_CALL */:\r\n genVNodeCall(node, context);\r\n break;\r\n case 14 /* JS_CALL_EXPRESSION */:\r\n genCallExpression(node, context);\r\n break;\r\n case 15 /* JS_OBJECT_EXPRESSION */:\r\n genObjectExpression(node, context);\r\n break;\r\n case 17 /* JS_ARRAY_EXPRESSION */:\r\n genArrayExpression(node, context);\r\n break;\r\n case 18 /* JS_FUNCTION_EXPRESSION */:\r\n genFunctionExpression(node, context);\r\n break;\r\n case 19 /* JS_CONDITIONAL_EXPRESSION */:\r\n genConditionalExpression(node, context);\r\n break;\r\n case 20 /* JS_CACHE_EXPRESSION */:\r\n genCacheExpression(node, context);\r\n break;\r\n case 21 /* JS_BLOCK_STATEMENT */:\r\n genNodeList(node.body, context, true, false);\r\n break;\r\n // SSR only types\r\n case 22 /* JS_TEMPLATE_LITERAL */:\r\n break;\r\n case 23 /* JS_IF_STATEMENT */:\r\n break;\r\n case 24 /* JS_ASSIGNMENT_EXPRESSION */:\r\n break;\r\n case 25 /* JS_SEQUENCE_EXPRESSION */:\r\n break;\r\n case 26 /* JS_RETURN_STATEMENT */:\r\n break;\r\n /* istanbul ignore next */\r\n case 10 /* IF_BRANCH */:\r\n // noop\r\n break;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n assert(false, `unhandled codegen node type: ${node.type}`);\r\n // make sure we exhaust all possible types\r\n const exhaustiveCheck = node;\r\n return exhaustiveCheck;\r\n }\r\n }\r\n}\r\nfunction genText(node, context) {\r\n context.push(JSON.stringify(node.content), node);\r\n}\r\nfunction genExpression(node, context) {\r\n const { content, isStatic } = node;\r\n context.push(isStatic ? JSON.stringify(content) : content, node);\r\n}\r\nfunction genInterpolation(node, context) {\r\n const { push, helper, pure } = context;\r\n if (pure)\r\n push(PURE_ANNOTATION);\r\n push(`${helper(TO_DISPLAY_STRING)}(`);\r\n genNode(node.content, context);\r\n push(`)`);\r\n}\r\nfunction genCompoundExpression(node, context) {\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (isString(child)) {\r\n context.push(child);\r\n }\r\n else {\r\n genNode(child, context);\r\n }\r\n }\r\n}\r\nfunction genExpressionAsPropertyKey(node, context) {\r\n const { push } = context;\r\n if (node.type === 8 /* COMPOUND_EXPRESSION */) {\r\n push(`[`);\r\n genCompoundExpression(node, context);\r\n push(`]`);\r\n }\r\n else if (node.isStatic) {\r\n // only quote keys if necessary\r\n const text = isSimpleIdentifier(node.content)\r\n ? node.content\r\n : JSON.stringify(node.content);\r\n push(text, node);\r\n }\r\n else {\r\n push(`[${node.content}]`, node);\r\n }\r\n}\r\nfunction genComment(node, context) {\r\n const { push, helper, pure } = context;\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n push(`${helper(CREATE_COMMENT)}(${JSON.stringify(node.content)})`, node);\r\n}\r\nfunction genVNodeCall(node, context) {\r\n const { push, helper, pure } = context;\r\n const { tag, props, children, patchFlag, dynamicProps, directives, isBlock, disableTracking, isComponent } = node;\r\n if (directives) {\r\n push(helper(WITH_DIRECTIVES) + `(`);\r\n }\r\n if (isBlock) {\r\n push(`(${helper(OPEN_BLOCK)}(${disableTracking ? `true` : ``}), `);\r\n }\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n const callHelper = isBlock\r\n ? getVNodeBlockHelper(context.inSSR, isComponent)\r\n : getVNodeHelper(context.inSSR, isComponent);\r\n push(helper(callHelper) + `(`, node);\r\n genNodeList(genNullableArgs([tag, props, children, patchFlag, dynamicProps]), context);\r\n push(`)`);\r\n if (isBlock) {\r\n push(`)`);\r\n }\r\n if (directives) {\r\n push(`, `);\r\n genNode(directives, context);\r\n push(`)`);\r\n }\r\n}\r\nfunction genNullableArgs(args) {\r\n let i = args.length;\r\n while (i--) {\r\n if (args[i] != null)\r\n break;\r\n }\r\n return args.slice(0, i + 1).map(arg => arg || `null`);\r\n}\r\n// JavaScript\r\nfunction genCallExpression(node, context) {\r\n const { push, helper, pure } = context;\r\n const callee = isString(node.callee) ? node.callee : helper(node.callee);\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n push(callee + `(`, node);\r\n genNodeList(node.arguments, context);\r\n push(`)`);\r\n}\r\nfunction genObjectExpression(node, context) {\r\n const { push, indent, deindent, newline } = context;\r\n const { properties } = node;\r\n if (!properties.length) {\r\n push(`{}`, node);\r\n return;\r\n }\r\n const multilines = properties.length > 1 ||\r\n (((process.env.NODE_ENV !== 'production')) &&\r\n properties.some(p => p.value.type !== 4 /* SIMPLE_EXPRESSION */));\r\n push(multilines ? `{` : `{ `);\r\n multilines && indent();\r\n for (let i = 0; i < properties.length; i++) {\r\n const { key, value } = properties[i];\r\n // key\r\n genExpressionAsPropertyKey(key, context);\r\n push(`: `);\r\n // value\r\n genNode(value, context);\r\n if (i < properties.length - 1) {\r\n // will only reach this if it's multilines\r\n push(`,`);\r\n newline();\r\n }\r\n }\r\n multilines && deindent();\r\n push(multilines ? `}` : ` }`);\r\n}\r\nfunction genArrayExpression(node, context) {\r\n genNodeListAsArray(node.elements, context);\r\n}\r\nfunction genFunctionExpression(node, context) {\r\n const { push, indent, deindent } = context;\r\n const { params, returns, body, newline, isSlot } = node;\r\n if (isSlot) {\r\n // wrap slot functions with owner context\r\n push(`_${helperNameMap[WITH_CTX]}(`);\r\n }\r\n push(`(`, node);\r\n if (isArray(params)) {\r\n genNodeList(params, context);\r\n }\r\n else if (params) {\r\n genNode(params, context);\r\n }\r\n push(`) => `);\r\n if (newline || body) {\r\n push(`{`);\r\n indent();\r\n }\r\n if (returns) {\r\n if (newline) {\r\n push(`return `);\r\n }\r\n if (isArray(returns)) {\r\n genNodeListAsArray(returns, context);\r\n }\r\n else {\r\n genNode(returns, context);\r\n }\r\n }\r\n else if (body) {\r\n genNode(body, context);\r\n }\r\n if (newline || body) {\r\n deindent();\r\n push(`}`);\r\n }\r\n if (isSlot) {\r\n if (node.isNonScopedSlot) {\r\n push(`, undefined, true`);\r\n }\r\n push(`)`);\r\n }\r\n}\r\nfunction genConditionalExpression(node, context) {\r\n const { test, consequent, alternate, newline: needNewline } = node;\r\n const { push, indent, deindent, newline } = context;\r\n if (test.type === 4 /* SIMPLE_EXPRESSION */) {\r\n const needsParens = !isSimpleIdentifier(test.content);\r\n needsParens && push(`(`);\r\n genExpression(test, context);\r\n needsParens && push(`)`);\r\n }\r\n else {\r\n push(`(`);\r\n genNode(test, context);\r\n push(`)`);\r\n }\r\n needNewline && indent();\r\n context.indentLevel++;\r\n needNewline || push(` `);\r\n push(`? `);\r\n genNode(consequent, context);\r\n context.indentLevel--;\r\n needNewline && newline();\r\n needNewline || push(` `);\r\n push(`: `);\r\n const isNested = alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */;\r\n if (!isNested) {\r\n context.indentLevel++;\r\n }\r\n genNode(alternate, context);\r\n if (!isNested) {\r\n context.indentLevel--;\r\n }\r\n needNewline && deindent(true /* without newline */);\r\n}\r\nfunction genCacheExpression(node, context) {\r\n const { push, helper, indent, deindent, newline } = context;\r\n push(`_cache[${node.index}] || (`);\r\n if (node.isVNode) {\r\n indent();\r\n push(`${helper(SET_BLOCK_TRACKING)}(-1),`);\r\n newline();\r\n }\r\n push(`_cache[${node.index}] = `);\r\n genNode(node.value, context);\r\n if (node.isVNode) {\r\n push(`,`);\r\n newline();\r\n push(`${helper(SET_BLOCK_TRACKING)}(1),`);\r\n newline();\r\n push(`_cache[${node.index}]`);\r\n deindent();\r\n }\r\n push(`)`);\r\n}\n\nfunction walkIdentifiers(root, onIdentifier, includeAll = false, parentStack = [], knownIds = Object.create(null)) {\r\n {\r\n return;\r\n }\r\n}\r\nfunction isReferencedIdentifier(id, parent, parentStack) {\r\n {\r\n return false;\r\n }\r\n}\r\nfunction isInDestructureAssignment(parent, parentStack) {\r\n if (parent &&\r\n (parent.type === 'ObjectProperty' || parent.type === 'ArrayPattern')) {\r\n let i = parentStack.length;\r\n while (i--) {\r\n const p = parentStack[i];\r\n if (p.type === 'AssignmentExpression') {\r\n return true;\r\n }\r\n else if (p.type !== 'ObjectProperty' && !p.type.endsWith('Pattern')) {\r\n break;\r\n }\r\n }\r\n }\r\n return false;\r\n}\r\nfunction walkFunctionParams(node, onIdent) {\r\n for (const p of node.params) {\r\n for (const id of extractIdentifiers(p)) {\r\n onIdent(id);\r\n }\r\n }\r\n}\r\nfunction walkBlockDeclarations(block, onIdent) {\r\n for (const stmt of block.body) {\r\n if (stmt.type === 'VariableDeclaration') {\r\n if (stmt.declare)\r\n continue;\r\n for (const decl of stmt.declarations) {\r\n for (const id of extractIdentifiers(decl.id)) {\r\n onIdent(id);\r\n }\r\n }\r\n }\r\n else if (stmt.type === 'FunctionDeclaration' ||\r\n stmt.type === 'ClassDeclaration') {\r\n if (stmt.declare || !stmt.id)\r\n continue;\r\n onIdent(stmt.id);\r\n }\r\n }\r\n}\r\nfunction extractIdentifiers(param, nodes = []) {\r\n switch (param.type) {\r\n case 'Identifier':\r\n nodes.push(param);\r\n break;\r\n case 'MemberExpression':\r\n let object = param;\r\n while (object.type === 'MemberExpression') {\r\n object = object.object;\r\n }\r\n nodes.push(object);\r\n break;\r\n case 'ObjectPattern':\r\n for (const prop of param.properties) {\r\n if (prop.type === 'RestElement') {\r\n extractIdentifiers(prop.argument, nodes);\r\n }\r\n else {\r\n extractIdentifiers(prop.value, nodes);\r\n }\r\n }\r\n break;\r\n case 'ArrayPattern':\r\n param.elements.forEach(element => {\r\n if (element)\r\n extractIdentifiers(element, nodes);\r\n });\r\n break;\r\n case 'RestElement':\r\n extractIdentifiers(param.argument, nodes);\r\n break;\r\n case 'AssignmentPattern':\r\n extractIdentifiers(param.left, nodes);\r\n break;\r\n }\r\n return nodes;\r\n}\r\nconst isFunctionType = (node) => {\r\n return /Function(?:Expression|Declaration)$|Method$/.test(node.type);\r\n};\r\nconst isStaticProperty = (node) => node &&\r\n (node.type === 'ObjectProperty' || node.type === 'ObjectMethod') &&\r\n !node.computed;\r\nconst isStaticPropertyKey = (node, parent) => isStaticProperty(parent) && parent.key === node;\n\n// these keywords should not appear inside expressions, but operators like\r\n// typeof, instanceof and in are allowed\r\nconst prohibitedKeywordRE = new RegExp('\\\\b' +\r\n ('do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,' +\r\n 'super,throw,while,yield,delete,export,import,return,switch,default,' +\r\n 'extends,finally,continue,debugger,function,arguments,typeof,void')\r\n .split(',')\r\n .join('\\\\b|\\\\b') +\r\n '\\\\b');\r\n// strip strings in expressions\r\nconst stripStringRE = /'(?:[^'\\\\]|\\\\.)*'|\"(?:[^\"\\\\]|\\\\.)*\"|`(?:[^`\\\\]|\\\\.)*\\$\\{|\\}(?:[^`\\\\]|\\\\.)*`|`(?:[^`\\\\]|\\\\.)*`/g;\r\n/**\r\n * Validate a non-prefixed expression.\r\n * This is only called when using the in-browser runtime compiler since it\r\n * doesn't prefix expressions.\r\n */\r\nfunction validateBrowserExpression(node, context, asParams = false, asRawStatements = false) {\r\n const exp = node.content;\r\n // empty expressions are validated per-directive since some directives\r\n // do allow empty expressions.\r\n if (!exp.trim()) {\r\n return;\r\n }\r\n try {\r\n new Function(asRawStatements\r\n ? ` ${exp} `\r\n : `return ${asParams ? `(${exp}) => {}` : `(${exp})`}`);\r\n }\r\n catch (e) {\r\n let message = e.message;\r\n const keywordMatch = exp\r\n .replace(stripStringRE, '')\r\n .match(prohibitedKeywordRE);\r\n if (keywordMatch) {\r\n message = `avoid using JavaScript keyword as property name: \"${keywordMatch[0]}\"`;\r\n }\r\n context.onError(createCompilerError(44 /* X_INVALID_EXPRESSION */, node.loc, undefined, message));\r\n }\r\n}\n\nconst transformExpression = (node, context) => {\r\n if (node.type === 5 /* INTERPOLATION */) {\r\n node.content = processExpression(node.content, context);\r\n }\r\n else if (node.type === 1 /* ELEMENT */) {\r\n // handle directives on element\r\n for (let i = 0; i < node.props.length; i++) {\r\n const dir = node.props[i];\r\n // do not process for v-on & v-for since they are special handled\r\n if (dir.type === 7 /* DIRECTIVE */ && dir.name !== 'for') {\r\n const exp = dir.exp;\r\n const arg = dir.arg;\r\n // do not process exp if this is v-on:arg - we need special handling\r\n // for wrapping inline statements.\r\n if (exp &&\r\n exp.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n !(dir.name === 'on' && arg)) {\r\n dir.exp = processExpression(exp, context, \r\n // slot args must be processed as function params\r\n dir.name === 'slot');\r\n }\r\n if (arg && arg.type === 4 /* SIMPLE_EXPRESSION */ && !arg.isStatic) {\r\n dir.arg = processExpression(arg, context);\r\n }\r\n }\r\n }\r\n }\r\n};\r\n// Important: since this function uses Node.js only dependencies, it should\r\n// always be used with a leading !true check so that it can be\r\n// tree-shaken from the browser build.\r\nfunction processExpression(node, context, \r\n// some expressions like v-slot props & v-for aliases should be parsed as\r\n// function params\r\nasParams = false, \r\n// v-on handler values may contain multiple statements\r\nasRawStatements = false, localVars = Object.create(context.identifiers)) {\r\n {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n // simple in-browser validation (same logic in 2.x)\r\n validateBrowserExpression(node, context, asParams, asRawStatements);\r\n }\r\n return node;\r\n }\r\n}\n\nconst transformIf = createStructuralDirectiveTransform(/^(if|else|else-if)$/, (node, dir, context) => {\r\n return processIf(node, dir, context, (ifNode, branch, isRoot) => {\r\n // #1587: We need to dynamically increment the key based on the current\r\n // node's sibling nodes, since chained v-if/else branches are\r\n // rendered at the same depth\r\n const siblings = context.parent.children;\r\n let i = siblings.indexOf(ifNode);\r\n let key = 0;\r\n while (i-- >= 0) {\r\n const sibling = siblings[i];\r\n if (sibling && sibling.type === 9 /* IF */) {\r\n key += sibling.branches.length;\r\n }\r\n }\r\n // Exit callback. Complete the codegenNode when all children have been\r\n // transformed.\r\n return () => {\r\n if (isRoot) {\r\n ifNode.codegenNode = createCodegenNodeForBranch(branch, key, context);\r\n }\r\n else {\r\n // attach this branch's codegen node to the v-if root.\r\n const parentCondition = getParentCondition(ifNode.codegenNode);\r\n parentCondition.alternate = createCodegenNodeForBranch(branch, key + ifNode.branches.length - 1, context);\r\n }\r\n };\r\n });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processIf(node, dir, context, processCodegen) {\r\n if (dir.name !== 'else' &&\r\n (!dir.exp || !dir.exp.content.trim())) {\r\n const loc = dir.exp ? dir.exp.loc : node.loc;\r\n context.onError(createCompilerError(28 /* X_V_IF_NO_EXPRESSION */, dir.loc));\r\n dir.exp = createSimpleExpression(`true`, false, loc);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && true && dir.exp) {\r\n validateBrowserExpression(dir.exp, context);\r\n }\r\n if (dir.name === 'if') {\r\n const branch = createIfBranch(node, dir);\r\n const ifNode = {\r\n type: 9 /* IF */,\r\n loc: node.loc,\r\n branches: [branch]\r\n };\r\n context.replaceNode(ifNode);\r\n if (processCodegen) {\r\n return processCodegen(ifNode, branch, true);\r\n }\r\n }\r\n else {\r\n // locate the adjacent v-if\r\n const siblings = context.parent.children;\r\n const comments = [];\r\n let i = siblings.indexOf(node);\r\n while (i-- >= -1) {\r\n const sibling = siblings[i];\r\n if ((process.env.NODE_ENV !== 'production') && sibling && sibling.type === 3 /* COMMENT */) {\r\n context.removeNode(sibling);\r\n comments.unshift(sibling);\r\n continue;\r\n }\r\n if (sibling &&\r\n sibling.type === 2 /* TEXT */ &&\r\n !sibling.content.trim().length) {\r\n context.removeNode(sibling);\r\n continue;\r\n }\r\n if (sibling && sibling.type === 9 /* IF */) {\r\n // Check if v-else was followed by v-else-if\r\n if (dir.name === 'else-if' &&\r\n sibling.branches[sibling.branches.length - 1].condition === undefined) {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n }\r\n // move the node to the if node's branches\r\n context.removeNode();\r\n const branch = createIfBranch(node, dir);\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n comments.length &&\r\n // #3619 ignore comments if the v-if is direct child of <transition>\r\n !(context.parent &&\r\n context.parent.type === 1 /* ELEMENT */ &&\r\n isBuiltInType(context.parent.tag, 'transition'))) {\r\n branch.children = [...comments, ...branch.children];\r\n }\r\n // check if user is forcing same key on different branches\r\n if ((process.env.NODE_ENV !== 'production') || !true) {\r\n const key = branch.userKey;\r\n if (key) {\r\n sibling.branches.forEach(({ userKey }) => {\r\n if (isSameKey(userKey, key)) {\r\n context.onError(createCompilerError(29 /* X_V_IF_SAME_KEY */, branch.userKey.loc));\r\n }\r\n });\r\n }\r\n }\r\n sibling.branches.push(branch);\r\n const onExit = processCodegen && processCodegen(sibling, branch, false);\r\n // since the branch was removed, it will not be traversed.\r\n // make sure to traverse here.\r\n traverseNode(branch, context);\r\n // call on exit\r\n if (onExit)\r\n onExit();\r\n // make sure to reset currentNode after traversal to indicate this\r\n // node has been removed.\r\n context.currentNode = null;\r\n }\r\n else {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n }\r\n break;\r\n }\r\n }\r\n}\r\nfunction createIfBranch(node, dir) {\r\n return {\r\n type: 10 /* IF_BRANCH */,\r\n loc: node.loc,\r\n condition: dir.name === 'else' ? undefined : dir.exp,\r\n children: node.tagType === 3 /* TEMPLATE */ && !findDir(node, 'for')\r\n ? node.children\r\n : [node],\r\n userKey: findProp(node, `key`)\r\n };\r\n}\r\nfunction createCodegenNodeForBranch(branch, keyIndex, context) {\r\n if (branch.condition) {\r\n return createConditionalExpression(branch.condition, createChildrenCodegenNode(branch, keyIndex, context), \r\n // make sure to pass in asBlock: true so that the comment node call\r\n // closes the current block.\r\n createCallExpression(context.helper(CREATE_COMMENT), [\r\n (process.env.NODE_ENV !== 'production') ? '\"v-if\"' : '\"\"',\r\n 'true'\r\n ]));\r\n }\r\n else {\r\n return createChildrenCodegenNode(branch, keyIndex, context);\r\n }\r\n}\r\nfunction createChildrenCodegenNode(branch, keyIndex, context) {\r\n const { helper } = context;\r\n const keyProperty = createObjectProperty(`key`, createSimpleExpression(`${keyIndex}`, false, locStub, 2 /* CAN_HOIST */));\r\n const { children } = branch;\r\n const firstChild = children[0];\r\n const needFragmentWrapper = children.length !== 1 || firstChild.type !== 1 /* ELEMENT */;\r\n if (needFragmentWrapper) {\r\n if (children.length === 1 && firstChild.type === 11 /* FOR */) {\r\n // optimize away nested fragments when child is a ForNode\r\n const vnodeCall = firstChild.codegenNode;\r\n injectProp(vnodeCall, keyProperty, context);\r\n return vnodeCall;\r\n }\r\n else {\r\n let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n // check if the fragment actually contains a single valid child with\r\n // the rest being comments\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n }\r\n return createVNodeCall(context, helper(FRAGMENT), createObjectExpression([keyProperty]), children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, false, false /* isComponent */, branch.loc);\r\n }\r\n }\r\n else {\r\n const ret = firstChild.codegenNode;\r\n const vnodeCall = getMemoedVNodeCall(ret);\r\n // Change createVNode to createBlock.\r\n if (vnodeCall.type === 13 /* VNODE_CALL */) {\r\n makeBlock(vnodeCall, context);\r\n }\r\n // inject branch key\r\n injectProp(vnodeCall, keyProperty, context);\r\n return ret;\r\n }\r\n}\r\nfunction isSameKey(a, b) {\r\n if (!a || a.type !== b.type) {\r\n return false;\r\n }\r\n if (a.type === 6 /* ATTRIBUTE */) {\r\n if (a.value.content !== b.value.content) {\r\n return false;\r\n }\r\n }\r\n else {\r\n // directive\r\n const exp = a.exp;\r\n const branchExp = b.exp;\r\n if (exp.type !== branchExp.type) {\r\n return false;\r\n }\r\n if (exp.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n exp.isStatic !== branchExp.isStatic ||\r\n exp.content !== branchExp.content) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n}\r\nfunction getParentCondition(node) {\r\n while (true) {\r\n if (node.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n if (node.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n node = node.alternate;\r\n }\r\n else {\r\n return node;\r\n }\r\n }\r\n else if (node.type === 20 /* JS_CACHE_EXPRESSION */) {\r\n node = node.value;\r\n }\r\n }\r\n}\n\nconst transformFor = createStructuralDirectiveTransform('for', (node, dir, context) => {\r\n const { helper, removeHelper } = context;\r\n return processFor(node, dir, context, forNode => {\r\n // create the loop render function expression now, and add the\r\n // iterator on exit after all children have been traversed\r\n const renderExp = createCallExpression(helper(RENDER_LIST), [\r\n forNode.source\r\n ]);\r\n const memo = findDir(node, 'memo');\r\n const keyProp = findProp(node, `key`);\r\n const keyExp = keyProp &&\r\n (keyProp.type === 6 /* ATTRIBUTE */\r\n ? createSimpleExpression(keyProp.value.content, true)\r\n : keyProp.exp);\r\n const keyProperty = keyProp ? createObjectProperty(`key`, keyExp) : null;\r\n const isStableFragment = forNode.source.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n forNode.source.constType > 0 /* NOT_CONSTANT */;\r\n const fragmentFlag = isStableFragment\r\n ? 64 /* STABLE_FRAGMENT */\r\n : keyProp\r\n ? 128 /* KEYED_FRAGMENT */\r\n : 256 /* UNKEYED_FRAGMENT */;\r\n forNode.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, renderExp, fragmentFlag +\r\n ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[fragmentFlag]} */` : ``), undefined, undefined, true /* isBlock */, !isStableFragment /* disableTracking */, false /* isComponent */, node.loc);\r\n return () => {\r\n // finish the codegen now that all children have been traversed\r\n let childBlock;\r\n const isTemplate = isTemplateNode(node);\r\n const { children } = forNode;\r\n // check <template v-for> key placement\r\n if (((process.env.NODE_ENV !== 'production') || !true) && isTemplate) {\r\n node.children.some(c => {\r\n if (c.type === 1 /* ELEMENT */) {\r\n const key = findProp(c, 'key');\r\n if (key) {\r\n context.onError(createCompilerError(33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */, key.loc));\r\n return true;\r\n }\r\n }\r\n });\r\n }\r\n const needFragmentWrapper = children.length !== 1 || children[0].type !== 1 /* ELEMENT */;\r\n const slotOutlet = isSlotOutlet(node)\r\n ? node\r\n : isTemplate &&\r\n node.children.length === 1 &&\r\n isSlotOutlet(node.children[0])\r\n ? node.children[0] // api-extractor somehow fails to infer this\r\n : null;\r\n if (slotOutlet) {\r\n // <slot v-for=\"...\"> or <template v-for=\"...\"><slot/></template>\r\n childBlock = slotOutlet.codegenNode;\r\n if (isTemplate && keyProperty) {\r\n // <template v-for=\"...\" :key=\"...\"><slot/></template>\r\n // we need to inject the key to the renderSlot() call.\r\n // the props for renderSlot is passed as the 3rd argument.\r\n injectProp(childBlock, keyProperty, context);\r\n }\r\n }\r\n else if (needFragmentWrapper) {\r\n // <template v-for=\"...\"> with text or multi-elements\r\n // should generate a fragment block for each loop\r\n childBlock = createVNodeCall(context, helper(FRAGMENT), keyProperty ? createObjectExpression([keyProperty]) : undefined, node.children, 64 /* STABLE_FRAGMENT */ +\r\n ((process.env.NODE_ENV !== 'production')\r\n ? ` /* ${PatchFlagNames[64 /* STABLE_FRAGMENT */]} */`\r\n : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n }\r\n else {\r\n // Normal element v-for. Directly use the child's codegenNode\r\n // but mark it as a block.\r\n childBlock = children[0]\r\n .codegenNode;\r\n if (isTemplate && keyProperty) {\r\n injectProp(childBlock, keyProperty, context);\r\n }\r\n if (childBlock.isBlock !== !isStableFragment) {\r\n if (childBlock.isBlock) {\r\n // switch from block to vnode\r\n removeHelper(OPEN_BLOCK);\r\n removeHelper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n else {\r\n // switch from vnode to block\r\n removeHelper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n }\r\n childBlock.isBlock = !isStableFragment;\r\n if (childBlock.isBlock) {\r\n helper(OPEN_BLOCK);\r\n helper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n else {\r\n helper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n }\r\n if (memo) {\r\n const loop = createFunctionExpression(createForLoopParams(forNode.parseResult, [\r\n createSimpleExpression(`_cached`)\r\n ]));\r\n loop.body = createBlockStatement([\r\n createCompoundExpression([`const _memo = (`, memo.exp, `)`]),\r\n createCompoundExpression([\r\n `if (_cached`,\r\n ...(keyExp ? [` && _cached.key === `, keyExp] : []),\r\n ` && ${context.helperString(IS_MEMO_SAME)}(_cached, _memo)) return _cached`\r\n ]),\r\n createCompoundExpression([`const _item = `, childBlock]),\r\n createSimpleExpression(`_item.memo = _memo`),\r\n createSimpleExpression(`return _item`)\r\n ]);\r\n renderExp.arguments.push(loop, createSimpleExpression(`_cache`), createSimpleExpression(String(context.cached++)));\r\n }\r\n else {\r\n renderExp.arguments.push(createFunctionExpression(createForLoopParams(forNode.parseResult), childBlock, true /* force newline */));\r\n }\r\n };\r\n });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processFor(node, dir, context, processCodegen) {\r\n if (!dir.exp) {\r\n context.onError(createCompilerError(31 /* X_V_FOR_NO_EXPRESSION */, dir.loc));\r\n return;\r\n }\r\n const parseResult = parseForExpression(\r\n // can only be simple expression because vFor transform is applied\r\n // before expression transform.\r\n dir.exp, context);\r\n if (!parseResult) {\r\n context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, dir.loc));\r\n return;\r\n }\r\n const { addIdentifiers, removeIdentifiers, scopes } = context;\r\n const { source, value, key, index } = parseResult;\r\n const forNode = {\r\n type: 11 /* FOR */,\r\n loc: dir.loc,\r\n source,\r\n valueAlias: value,\r\n keyAlias: key,\r\n objectIndexAlias: index,\r\n parseResult,\r\n children: isTemplateNode(node) ? node.children : [node]\r\n };\r\n context.replaceNode(forNode);\r\n // bookkeeping\r\n scopes.vFor++;\r\n const onExit = processCodegen && processCodegen(forNode);\r\n return () => {\r\n scopes.vFor--;\r\n if (onExit)\r\n onExit();\r\n };\r\n}\r\nconst forAliasRE = /([\\s\\S]*?)\\s+(?:in|of)\\s+([\\s\\S]*)/;\r\n// This regex doesn't cover the case if key or index aliases have destructuring,\r\n// but those do not make sense in the first place, so this works in practice.\r\nconst forIteratorRE = /,([^,\\}\\]]*)(?:,([^,\\}\\]]*))?$/;\r\nconst stripParensRE = /^\\(|\\)$/g;\r\nfunction parseForExpression(input, context) {\r\n const loc = input.loc;\r\n const exp = input.content;\r\n const inMatch = exp.match(forAliasRE);\r\n if (!inMatch)\r\n return;\r\n const [, LHS, RHS] = inMatch;\r\n const result = {\r\n source: createAliasExpression(loc, RHS.trim(), exp.indexOf(RHS, LHS.length)),\r\n value: undefined,\r\n key: undefined,\r\n index: undefined\r\n };\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.source, context);\r\n }\r\n let valueContent = LHS.trim().replace(stripParensRE, '').trim();\r\n const trimmedOffset = LHS.indexOf(valueContent);\r\n const iteratorMatch = valueContent.match(forIteratorRE);\r\n if (iteratorMatch) {\r\n valueContent = valueContent.replace(forIteratorRE, '').trim();\r\n const keyContent = iteratorMatch[1].trim();\r\n let keyOffset;\r\n if (keyContent) {\r\n keyOffset = exp.indexOf(keyContent, trimmedOffset + valueContent.length);\r\n result.key = createAliasExpression(loc, keyContent, keyOffset);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.key, context, true);\r\n }\r\n }\r\n if (iteratorMatch[2]) {\r\n const indexContent = iteratorMatch[2].trim();\r\n if (indexContent) {\r\n result.index = createAliasExpression(loc, indexContent, exp.indexOf(indexContent, result.key\r\n ? keyOffset + keyContent.length\r\n : trimmedOffset + valueContent.length));\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.index, context, true);\r\n }\r\n }\r\n }\r\n }\r\n if (valueContent) {\r\n result.value = createAliasExpression(loc, valueContent, trimmedOffset);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.value, context, true);\r\n }\r\n }\r\n return result;\r\n}\r\nfunction createAliasExpression(range, content, offset) {\r\n return createSimpleExpression(content, false, getInnerRange(range, offset, content.length));\r\n}\r\nfunction createForLoopParams({ value, key, index }, memoArgs = []) {\r\n return createParamsList([value, key, index, ...memoArgs]);\r\n}\r\nfunction createParamsList(args) {\r\n let i = args.length;\r\n while (i--) {\r\n if (args[i])\r\n break;\r\n }\r\n return args\r\n .slice(0, i + 1)\r\n .map((arg, i) => arg || createSimpleExpression(`_`.repeat(i + 1), false));\r\n}\n\nconst defaultFallback = createSimpleExpression(`undefined`, false);\r\n// A NodeTransform that:\r\n// 1. Tracks scope identifiers for scoped slots so that they don't get prefixed\r\n// by transformExpression. This is only applied in non-browser builds with\r\n// { prefixIdentifiers: true }.\r\n// 2. Track v-slot depths so that we know a slot is inside another slot.\r\n// Note the exit callback is executed before buildSlots() on the same node,\r\n// so only nested slots see positive numbers.\r\nconst trackSlotScopes = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n (node.tagType === 1 /* COMPONENT */ ||\r\n node.tagType === 3 /* TEMPLATE */)) {\r\n // We are only checking non-empty v-slot here\r\n // since we only care about slots that introduce scope variables.\r\n const vSlot = findDir(node, 'slot');\r\n if (vSlot) {\r\n vSlot.exp;\r\n context.scopes.vSlot++;\r\n return () => {\r\n context.scopes.vSlot--;\r\n };\r\n }\r\n }\r\n};\r\n// A NodeTransform that tracks scope identifiers for scoped slots with v-for.\r\n// This transform is only applied in non-browser builds with { prefixIdentifiers: true }\r\nconst trackVForSlotScopes = (node, context) => {\r\n let vFor;\r\n if (isTemplateNode(node) &&\r\n node.props.some(isVSlot) &&\r\n (vFor = findDir(node, 'for'))) {\r\n const result = (vFor.parseResult = parseForExpression(vFor.exp, context));\r\n if (result) {\r\n const { value, key, index } = result;\r\n const { addIdentifiers, removeIdentifiers } = context;\r\n value && addIdentifiers(value);\r\n key && addIdentifiers(key);\r\n index && addIdentifiers(index);\r\n return () => {\r\n value && removeIdentifiers(value);\r\n key && removeIdentifiers(key);\r\n index && removeIdentifiers(index);\r\n };\r\n }\r\n }\r\n};\r\nconst buildClientSlotFn = (props, children, loc) => createFunctionExpression(props, children, false /* newline */, true /* isSlot */, children.length ? children[0].loc : loc);\r\n// Instead of being a DirectiveTransform, v-slot processing is called during\r\n// transformElement to build the slots object for a component.\r\nfunction buildSlots(node, context, buildSlotFn = buildClientSlotFn) {\r\n context.helper(WITH_CTX);\r\n const { children, loc } = node;\r\n const slotsProperties = [];\r\n const dynamicSlots = [];\r\n // If the slot is inside a v-for or another v-slot, force it to be dynamic\r\n // since it likely uses a scope variable.\r\n let hasDynamicSlots = context.scopes.vSlot > 0 || context.scopes.vFor > 0;\r\n // 1. Check for slot with slotProps on component itself.\r\n // <Comp v-slot=\"{ prop }\"/>\r\n const onComponentSlot = findDir(node, 'slot', true);\r\n if (onComponentSlot) {\r\n const { arg, exp } = onComponentSlot;\r\n if (arg && !isStaticExp(arg)) {\r\n hasDynamicSlots = true;\r\n }\r\n slotsProperties.push(createObjectProperty(arg || createSimpleExpression('default', true), buildSlotFn(exp, children, loc)));\r\n }\r\n // 2. Iterate through children and check for template slots\r\n // <template v-slot:foo=\"{ prop }\">\r\n let hasTemplateSlots = false;\r\n let hasNamedDefaultSlot = false;\r\n const implicitDefaultChildren = [];\r\n const seenSlotNames = new Set();\r\n for (let i = 0; i < children.length; i++) {\r\n const slotElement = children[i];\r\n let slotDir;\r\n if (!isTemplateNode(slotElement) ||\r\n !(slotDir = findDir(slotElement, 'slot', true))) {\r\n // not a <template v-slot>, skip.\r\n if (slotElement.type !== 3 /* COMMENT */) {\r\n implicitDefaultChildren.push(slotElement);\r\n }\r\n continue;\r\n }\r\n if (onComponentSlot) {\r\n // already has on-component slot - this is incorrect usage.\r\n context.onError(createCompilerError(37 /* X_V_SLOT_MIXED_SLOT_USAGE */, slotDir.loc));\r\n break;\r\n }\r\n hasTemplateSlots = true;\r\n const { children: slotChildren, loc: slotLoc } = slotElement;\r\n const { arg: slotName = createSimpleExpression(`default`, true), exp: slotProps, loc: dirLoc } = slotDir;\r\n // check if name is dynamic.\r\n let staticSlotName;\r\n if (isStaticExp(slotName)) {\r\n staticSlotName = slotName ? slotName.content : `default`;\r\n }\r\n else {\r\n hasDynamicSlots = true;\r\n }\r\n const slotFunction = buildSlotFn(slotProps, slotChildren, slotLoc);\r\n // check if this slot is conditional (v-if/v-for)\r\n let vIf;\r\n let vElse;\r\n let vFor;\r\n if ((vIf = findDir(slotElement, 'if'))) {\r\n hasDynamicSlots = true;\r\n dynamicSlots.push(createConditionalExpression(vIf.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback));\r\n }\r\n else if ((vElse = findDir(slotElement, /^else(-if)?$/, true /* allowEmpty */))) {\r\n // find adjacent v-if\r\n let j = i;\r\n let prev;\r\n while (j--) {\r\n prev = children[j];\r\n if (prev.type !== 3 /* COMMENT */) {\r\n break;\r\n }\r\n }\r\n if (prev && isTemplateNode(prev) && findDir(prev, 'if')) {\r\n // remove node\r\n children.splice(i, 1);\r\n i--;\r\n // attach this slot to previous conditional\r\n let conditional = dynamicSlots[dynamicSlots.length - 1];\r\n while (conditional.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n conditional = conditional.alternate;\r\n }\r\n conditional.alternate = vElse.exp\r\n ? createConditionalExpression(vElse.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback)\r\n : buildDynamicSlot(slotName, slotFunction);\r\n }\r\n else {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, vElse.loc));\r\n }\r\n }\r\n else if ((vFor = findDir(slotElement, 'for'))) {\r\n hasDynamicSlots = true;\r\n const parseResult = vFor.parseResult ||\r\n parseForExpression(vFor.exp, context);\r\n if (parseResult) {\r\n // Render the dynamic slots as an array and add it to the createSlot()\r\n // args. The runtime knows how to handle it appropriately.\r\n dynamicSlots.push(createCallExpression(context.helper(RENDER_LIST), [\r\n parseResult.source,\r\n createFunctionExpression(createForLoopParams(parseResult), buildDynamicSlot(slotName, slotFunction), true /* force newline */)\r\n ]));\r\n }\r\n else {\r\n context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, vFor.loc));\r\n }\r\n }\r\n else {\r\n // check duplicate static names\r\n if (staticSlotName) {\r\n if (seenSlotNames.has(staticSlotName)) {\r\n context.onError(createCompilerError(38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */, dirLoc));\r\n continue;\r\n }\r\n seenSlotNames.add(staticSlotName);\r\n if (staticSlotName === 'default') {\r\n hasNamedDefaultSlot = true;\r\n }\r\n }\r\n slotsProperties.push(createObjectProperty(slotName, slotFunction));\r\n }\r\n }\r\n if (!onComponentSlot) {\r\n const buildDefaultSlotProperty = (props, children) => {\r\n const fn = buildSlotFn(props, children, loc);\r\n if (context.compatConfig) {\r\n fn.isNonScopedSlot = true;\r\n }\r\n return createObjectProperty(`default`, fn);\r\n };\r\n if (!hasTemplateSlots) {\r\n // implicit default slot (on component)\r\n slotsProperties.push(buildDefaultSlotProperty(undefined, children));\r\n }\r\n else if (implicitDefaultChildren.length &&\r\n // #3766\r\n // with whitespace: 'preserve', whitespaces between slots will end up in\r\n // implicitDefaultChildren. Ignore if all implicit children are whitespaces.\r\n implicitDefaultChildren.some(node => isNonWhitespaceContent(node))) {\r\n // implicit default slot (mixed with named slots)\r\n if (hasNamedDefaultSlot) {\r\n context.onError(createCompilerError(39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */, implicitDefaultChildren[0].loc));\r\n }\r\n else {\r\n slotsProperties.push(buildDefaultSlotProperty(undefined, implicitDefaultChildren));\r\n }\r\n }\r\n }\r\n const slotFlag = hasDynamicSlots\r\n ? 2 /* DYNAMIC */\r\n : hasForwardedSlots(node.children)\r\n ? 3 /* FORWARDED */\r\n : 1 /* STABLE */;\r\n let slots = createObjectExpression(slotsProperties.concat(createObjectProperty(`_`, \r\n // 2 = compiled but dynamic = can skip normalization, but must run diff\r\n // 1 = compiled and static = can skip normalization AND diff as optimized\r\n createSimpleExpression(slotFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${slotFlagsText[slotFlag]} */` : ``), false))), loc);\r\n if (dynamicSlots.length) {\r\n slots = createCallExpression(context.helper(CREATE_SLOTS), [\r\n slots,\r\n createArrayExpression(dynamicSlots)\r\n ]);\r\n }\r\n return {\r\n slots,\r\n hasDynamicSlots\r\n };\r\n}\r\nfunction buildDynamicSlot(name, fn) {\r\n return createObjectExpression([\r\n createObjectProperty(`name`, name),\r\n createObjectProperty(`fn`, fn)\r\n ]);\r\n}\r\nfunction hasForwardedSlots(children) {\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n switch (child.type) {\r\n case 1 /* ELEMENT */:\r\n if (child.tagType === 2 /* SLOT */ ||\r\n hasForwardedSlots(child.children)) {\r\n return true;\r\n }\r\n break;\r\n case 9 /* IF */:\r\n if (hasForwardedSlots(child.branches))\r\n return true;\r\n break;\r\n case 10 /* IF_BRANCH */:\r\n case 11 /* FOR */:\r\n if (hasForwardedSlots(child.children))\r\n return true;\r\n break;\r\n }\r\n }\r\n return false;\r\n}\r\nfunction isNonWhitespaceContent(node) {\r\n if (node.type !== 2 /* TEXT */ && node.type !== 12 /* TEXT_CALL */)\r\n return true;\r\n return node.type === 2 /* TEXT */\r\n ? !!node.content.trim()\r\n : isNonWhitespaceContent(node.content);\r\n}\n\n// some directive transforms (e.g. v-model) may return a symbol for runtime\r\n// import, which should be used instead of a resolveDirective call.\r\nconst directiveImportMap = new WeakMap();\r\n// generate a JavaScript AST for this element's codegen\r\nconst transformElement = (node, context) => {\r\n // perform the work on exit, after all child expressions have been\r\n // processed and merged.\r\n return function postTransformElement() {\r\n node = context.currentNode;\r\n if (!(node.type === 1 /* ELEMENT */ &&\r\n (node.tagType === 0 /* ELEMENT */ ||\r\n node.tagType === 1 /* COMPONENT */))) {\r\n return;\r\n }\r\n const { tag, props } = node;\r\n const isComponent = node.tagType === 1 /* COMPONENT */;\r\n // The goal of the transform is to create a codegenNode implementing the\r\n // VNodeCall interface.\r\n let vnodeTag = isComponent\r\n ? resolveComponentType(node, context)\r\n : `\"${tag}\"`;\r\n const isDynamicComponent = isObject(vnodeTag) && vnodeTag.callee === RESOLVE_DYNAMIC_COMPONENT;\r\n let vnodeProps;\r\n let vnodeChildren;\r\n let vnodePatchFlag;\r\n let patchFlag = 0;\r\n let vnodeDynamicProps;\r\n let dynamicPropNames;\r\n let vnodeDirectives;\r\n let shouldUseBlock = \r\n // dynamic component may resolve to plain elements\r\n isDynamicComponent ||\r\n vnodeTag === TELEPORT ||\r\n vnodeTag === SUSPENSE ||\r\n (!isComponent &&\r\n // <svg> and <foreignObject> must be forced into blocks so that block\r\n // updates inside get proper isSVG flag at runtime. (#639, #643)\r\n // This is technically web-specific, but splitting the logic out of core\r\n // leads to too much unnecessary complexity.\r\n (tag === 'svg' || tag === 'foreignObject'));\r\n // props\r\n if (props.length > 0) {\r\n const propsBuildResult = buildProps(node, context);\r\n vnodeProps = propsBuildResult.props;\r\n patchFlag = propsBuildResult.patchFlag;\r\n dynamicPropNames = propsBuildResult.dynamicPropNames;\r\n const directives = propsBuildResult.directives;\r\n vnodeDirectives =\r\n directives && directives.length\r\n ? createArrayExpression(directives.map(dir => buildDirectiveArgs(dir, context)))\r\n : undefined;\r\n if (propsBuildResult.shouldUseBlock) {\r\n shouldUseBlock = true;\r\n }\r\n }\r\n // children\r\n if (node.children.length > 0) {\r\n if (vnodeTag === KEEP_ALIVE) {\r\n // Although a built-in component, we compile KeepAlive with raw children\r\n // instead of slot functions so that it can be used inside Transition\r\n // or other Transition-wrapping HOCs.\r\n // To ensure correct updates with block optimizations, we need to:\r\n // 1. Force keep-alive into a block. This avoids its children being\r\n // collected by a parent block.\r\n shouldUseBlock = true;\r\n // 2. Force keep-alive to always be updated, since it uses raw children.\r\n patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n if ((process.env.NODE_ENV !== 'production') && node.children.length > 1) {\r\n context.onError(createCompilerError(45 /* X_KEEP_ALIVE_INVALID_CHILDREN */, {\r\n start: node.children[0].loc.start,\r\n end: node.children[node.children.length - 1].loc.end,\r\n source: ''\r\n }));\r\n }\r\n }\r\n const shouldBuildAsSlots = isComponent &&\r\n // Teleport is not a real component and has dedicated runtime handling\r\n vnodeTag !== TELEPORT &&\r\n // explained above.\r\n vnodeTag !== KEEP_ALIVE;\r\n if (shouldBuildAsSlots) {\r\n const { slots, hasDynamicSlots } = buildSlots(node, context);\r\n vnodeChildren = slots;\r\n if (hasDynamicSlots) {\r\n patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n }\r\n }\r\n else if (node.children.length === 1 && vnodeTag !== TELEPORT) {\r\n const child = node.children[0];\r\n const type = child.type;\r\n // check for dynamic text children\r\n const hasDynamicTextChild = type === 5 /* INTERPOLATION */ ||\r\n type === 8 /* COMPOUND_EXPRESSION */;\r\n if (hasDynamicTextChild &&\r\n getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n patchFlag |= 1 /* TEXT */;\r\n }\r\n // pass directly if the only child is a text node\r\n // (plain / interpolation / expression)\r\n if (hasDynamicTextChild || type === 2 /* TEXT */) {\r\n vnodeChildren = child;\r\n }\r\n else {\r\n vnodeChildren = node.children;\r\n }\r\n }\r\n else {\r\n vnodeChildren = node.children;\r\n }\r\n }\r\n // patchFlag & dynamicPropNames\r\n if (patchFlag !== 0) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (patchFlag < 0) {\r\n // special flags (negative and mutually exclusive)\r\n vnodePatchFlag = patchFlag + ` /* ${PatchFlagNames[patchFlag]} */`;\r\n }\r\n else {\r\n // bitwise flags\r\n const flagNames = Object.keys(PatchFlagNames)\r\n .map(Number)\r\n .filter(n => n > 0 && patchFlag & n)\r\n .map(n => PatchFlagNames[n])\r\n .join(`, `);\r\n vnodePatchFlag = patchFlag + ` /* ${flagNames} */`;\r\n }\r\n }\r\n else {\r\n vnodePatchFlag = String(patchFlag);\r\n }\r\n if (dynamicPropNames && dynamicPropNames.length) {\r\n vnodeDynamicProps = stringifyDynamicPropNames(dynamicPropNames);\r\n }\r\n }\r\n node.codegenNode = createVNodeCall(context, vnodeTag, vnodeProps, vnodeChildren, vnodePatchFlag, vnodeDynamicProps, vnodeDirectives, !!shouldUseBlock, false /* disableTracking */, isComponent, node.loc);\r\n };\r\n};\r\nfunction resolveComponentType(node, context, ssr = false) {\r\n let { tag } = node;\r\n // 1. dynamic component\r\n const isExplicitDynamic = isComponentTag(tag);\r\n const isProp = findProp(node, 'is');\r\n if (isProp) {\r\n if (isExplicitDynamic ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))) {\r\n const exp = isProp.type === 6 /* ATTRIBUTE */\r\n ? isProp.value && createSimpleExpression(isProp.value.content, true)\r\n : isProp.exp;\r\n if (exp) {\r\n return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n exp\r\n ]);\r\n }\r\n }\r\n else if (isProp.type === 6 /* ATTRIBUTE */ &&\r\n isProp.value.content.startsWith('vue:')) {\r\n // <button is=\"vue:xxx\">\r\n // if not <component>, only is value that starts with \"vue:\" will be\r\n // treated as component by the parse phase and reach here, unless it's\r\n // compat mode where all is values are considered components\r\n tag = isProp.value.content.slice(4);\r\n }\r\n }\r\n // 1.5 v-is (TODO: Deprecate)\r\n const isDir = !isExplicitDynamic && findDir(node, 'is');\r\n if (isDir && isDir.exp) {\r\n return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n isDir.exp\r\n ]);\r\n }\r\n // 2. built-in components (Teleport, Transition, KeepAlive, Suspense...)\r\n const builtIn = isCoreComponent(tag) || context.isBuiltInComponent(tag);\r\n if (builtIn) {\r\n // built-ins are simply fallthroughs / have special handling during ssr\r\n // so we don't need to import their runtime equivalents\r\n if (!ssr)\r\n context.helper(builtIn);\r\n return builtIn;\r\n }\r\n // 5. user component (resolve)\r\n context.helper(RESOLVE_COMPONENT);\r\n context.components.add(tag);\r\n return toValidAssetId(tag, `component`);\r\n}\r\nfunction buildProps(node, context, props = node.props, ssr = false) {\r\n const { tag, loc: elementLoc, children } = node;\r\n const isComponent = node.tagType === 1 /* COMPONENT */;\r\n let properties = [];\r\n const mergeArgs = [];\r\n const runtimeDirectives = [];\r\n const hasChildren = children.length > 0;\r\n let shouldUseBlock = false;\r\n // patchFlag analysis\r\n let patchFlag = 0;\r\n let hasRef = false;\r\n let hasClassBinding = false;\r\n let hasStyleBinding = false;\r\n let hasHydrationEventBinding = false;\r\n let hasDynamicKeys = false;\r\n let hasVnodeHook = false;\r\n const dynamicPropNames = [];\r\n const analyzePatchFlag = ({ key, value }) => {\r\n if (isStaticExp(key)) {\r\n const name = key.content;\r\n const isEventHandler = isOn(name);\r\n if (!isComponent &&\r\n isEventHandler &&\r\n // omit the flag for click handlers because hydration gives click\r\n // dedicated fast path.\r\n name.toLowerCase() !== 'onclick' &&\r\n // omit v-model handlers\r\n name !== 'onUpdate:modelValue' &&\r\n // omit onVnodeXXX hooks\r\n !isReservedProp(name)) {\r\n hasHydrationEventBinding = true;\r\n }\r\n if (isEventHandler && isReservedProp(name)) {\r\n hasVnodeHook = true;\r\n }\r\n if (value.type === 20 /* JS_CACHE_EXPRESSION */ ||\r\n ((value.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n value.type === 8 /* COMPOUND_EXPRESSION */) &&\r\n getConstantType(value, context) > 0)) {\r\n // skip if the prop is a cached handler or has constant value\r\n return;\r\n }\r\n if (name === 'ref') {\r\n hasRef = true;\r\n }\r\n else if (name === 'class') {\r\n hasClassBinding = true;\r\n }\r\n else if (name === 'style') {\r\n hasStyleBinding = true;\r\n }\r\n else if (name !== 'key' && !dynamicPropNames.includes(name)) {\r\n dynamicPropNames.push(name);\r\n }\r\n // treat the dynamic class and style binding of the component as dynamic props\r\n if (isComponent &&\r\n (name === 'class' || name === 'style') &&\r\n !dynamicPropNames.includes(name)) {\r\n dynamicPropNames.push(name);\r\n }\r\n }\r\n else {\r\n hasDynamicKeys = true;\r\n }\r\n };\r\n for (let i = 0; i < props.length; i++) {\r\n // static attribute\r\n const prop = props[i];\r\n if (prop.type === 6 /* ATTRIBUTE */) {\r\n const { loc, name, value } = prop;\r\n let isStatic = true;\r\n if (name === 'ref') {\r\n hasRef = true;\r\n if (context.scopes.vFor > 0) {\r\n properties.push(createObjectProperty(createSimpleExpression('ref_for', true), createSimpleExpression('true')));\r\n }\r\n }\r\n // skip is on <component>, or is=\"vue:xxx\"\r\n if (name === 'is' &&\r\n (isComponentTag(tag) ||\r\n (value && value.content.startsWith('vue:')) ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context)))) {\r\n continue;\r\n }\r\n properties.push(createObjectProperty(createSimpleExpression(name, true, getInnerRange(loc, 0, name.length)), createSimpleExpression(value ? value.content : '', isStatic, value ? value.loc : loc)));\r\n }\r\n else {\r\n // directives\r\n const { name, arg, exp, loc } = prop;\r\n const isVBind = name === 'bind';\r\n const isVOn = name === 'on';\r\n // skip v-slot - it is handled by its dedicated transform.\r\n if (name === 'slot') {\r\n if (!isComponent) {\r\n context.onError(createCompilerError(40 /* X_V_SLOT_MISPLACED */, loc));\r\n }\r\n continue;\r\n }\r\n // skip v-once/v-memo - they are handled by dedicated transforms.\r\n if (name === 'once' || name === 'memo') {\r\n continue;\r\n }\r\n // skip v-is and :is on <component>\r\n if (name === 'is' ||\r\n (isVBind &&\r\n isStaticArgOf(arg, 'is') &&\r\n (isComponentTag(tag) ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))))) {\r\n continue;\r\n }\r\n // skip v-on in SSR compilation\r\n if (isVOn && ssr) {\r\n continue;\r\n }\r\n if (\r\n // #938: elements with dynamic keys should be forced into blocks\r\n (isVBind && isStaticArgOf(arg, 'key')) ||\r\n // inline before-update hooks need to force block so that it is invoked\r\n // before children\r\n (isVOn && hasChildren && isStaticArgOf(arg, 'vue:before-update'))) {\r\n shouldUseBlock = true;\r\n }\r\n if (isVBind && isStaticArgOf(arg, 'ref') && context.scopes.vFor > 0) {\r\n properties.push(createObjectProperty(createSimpleExpression('ref_for', true), createSimpleExpression('true')));\r\n }\r\n // special case for v-bind and v-on with no argument\r\n if (!arg && (isVBind || isVOn)) {\r\n hasDynamicKeys = true;\r\n if (exp) {\r\n if (properties.length) {\r\n mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n properties = [];\r\n }\r\n if (isVBind) {\r\n {\r\n // 2.x v-bind object order compat\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const hasOverridableKeys = mergeArgs.some(arg => {\r\n if (arg.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n return arg.properties.some(({ key }) => {\r\n if (key.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n !key.isStatic) {\r\n return true;\r\n }\r\n return (key.content !== 'class' &&\r\n key.content !== 'style' &&\r\n !isOn(key.content));\r\n });\r\n }\r\n else {\r\n // dynamic expression\r\n return true;\r\n }\r\n });\r\n if (hasOverridableKeys) {\r\n checkCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context, loc);\r\n }\r\n }\r\n if (isCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context)) {\r\n mergeArgs.unshift(exp);\r\n continue;\r\n }\r\n }\r\n mergeArgs.push(exp);\r\n }\r\n else {\r\n // v-on=\"obj\" -> toHandlers(obj)\r\n mergeArgs.push({\r\n type: 14 /* JS_CALL_EXPRESSION */,\r\n loc,\r\n callee: context.helper(TO_HANDLERS),\r\n arguments: [exp]\r\n });\r\n }\r\n }\r\n else {\r\n context.onError(createCompilerError(isVBind\r\n ? 34 /* X_V_BIND_NO_EXPRESSION */\r\n : 35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n }\r\n continue;\r\n }\r\n const directiveTransform = context.directiveTransforms[name];\r\n if (directiveTransform) {\r\n // has built-in directive transform.\r\n const { props, needRuntime } = directiveTransform(prop, node, context);\r\n !ssr && props.forEach(analyzePatchFlag);\r\n properties.push(...props);\r\n if (needRuntime) {\r\n runtimeDirectives.push(prop);\r\n if (isSymbol(needRuntime)) {\r\n directiveImportMap.set(prop, needRuntime);\r\n }\r\n }\r\n }\r\n else {\r\n // no built-in transform, this is a user custom directive.\r\n runtimeDirectives.push(prop);\r\n // custom dirs may use beforeUpdate so they need to force blocks\r\n // to ensure before-update gets called before children update\r\n if (hasChildren) {\r\n shouldUseBlock = true;\r\n }\r\n }\r\n }\r\n }\r\n let propsExpression = undefined;\r\n // has v-bind=\"object\" or v-on=\"object\", wrap with mergeProps\r\n if (mergeArgs.length) {\r\n if (properties.length) {\r\n mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n }\r\n if (mergeArgs.length > 1) {\r\n propsExpression = createCallExpression(context.helper(MERGE_PROPS), mergeArgs, elementLoc);\r\n }\r\n else {\r\n // single v-bind with nothing else - no need for a mergeProps call\r\n propsExpression = mergeArgs[0];\r\n }\r\n }\r\n else if (properties.length) {\r\n propsExpression = createObjectExpression(dedupeProperties(properties), elementLoc);\r\n }\r\n // patchFlag analysis\r\n if (hasDynamicKeys) {\r\n patchFlag |= 16 /* FULL_PROPS */;\r\n }\r\n else {\r\n if (hasClassBinding && !isComponent) {\r\n patchFlag |= 2 /* CLASS */;\r\n }\r\n if (hasStyleBinding && !isComponent) {\r\n patchFlag |= 4 /* STYLE */;\r\n }\r\n if (dynamicPropNames.length) {\r\n patchFlag |= 8 /* PROPS */;\r\n }\r\n if (hasHydrationEventBinding) {\r\n patchFlag |= 32 /* HYDRATE_EVENTS */;\r\n }\r\n }\r\n if (!shouldUseBlock &&\r\n (patchFlag === 0 || patchFlag === 32 /* HYDRATE_EVENTS */) &&\r\n (hasRef || hasVnodeHook || runtimeDirectives.length > 0)) {\r\n patchFlag |= 512 /* NEED_PATCH */;\r\n }\r\n // pre-normalize props, SSR is skipped for now\r\n if (!context.inSSR && propsExpression) {\r\n switch (propsExpression.type) {\r\n case 15 /* JS_OBJECT_EXPRESSION */:\r\n // means that there is no v-bind,\r\n // but still need to deal with dynamic key binding\r\n let classKeyIndex = -1;\r\n let styleKeyIndex = -1;\r\n let hasDynamicKey = false;\r\n for (let i = 0; i < propsExpression.properties.length; i++) {\r\n const key = propsExpression.properties[i].key;\r\n if (isStaticExp(key)) {\r\n if (key.content === 'class') {\r\n classKeyIndex = i;\r\n }\r\n else if (key.content === 'style') {\r\n styleKeyIndex = i;\r\n }\r\n }\r\n else if (!key.isHandlerKey) {\r\n hasDynamicKey = true;\r\n }\r\n }\r\n const classProp = propsExpression.properties[classKeyIndex];\r\n const styleProp = propsExpression.properties[styleKeyIndex];\r\n // no dynamic key\r\n if (!hasDynamicKey) {\r\n if (classProp && !isStaticExp(classProp.value)) {\r\n classProp.value = createCallExpression(context.helper(NORMALIZE_CLASS), [classProp.value]);\r\n }\r\n if (styleProp &&\r\n !isStaticExp(styleProp.value) &&\r\n // the static style is compiled into an object,\r\n // so use `hasStyleBinding` to ensure that it is a dynamic style binding\r\n (hasStyleBinding ||\r\n // v-bind:style and style both exist,\r\n // v-bind:style with static literal object\r\n styleProp.value.type === 17 /* JS_ARRAY_EXPRESSION */)) {\r\n styleProp.value = createCallExpression(context.helper(NORMALIZE_STYLE), [styleProp.value]);\r\n }\r\n }\r\n else {\r\n // dynamic key binding, wrap with `normalizeProps`\r\n propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [propsExpression]);\r\n }\r\n break;\r\n case 14 /* JS_CALL_EXPRESSION */:\r\n // mergeProps call, do nothing\r\n break;\r\n default:\r\n // single v-bind\r\n propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [\r\n createCallExpression(context.helper(GUARD_REACTIVE_PROPS), [\r\n propsExpression\r\n ])\r\n ]);\r\n break;\r\n }\r\n }\r\n return {\r\n props: propsExpression,\r\n directives: runtimeDirectives,\r\n patchFlag,\r\n dynamicPropNames,\r\n shouldUseBlock\r\n };\r\n}\r\n// Dedupe props in an object literal.\r\n// Literal duplicated attributes would have been warned during the parse phase,\r\n// however, it's possible to encounter duplicated `onXXX` handlers with different\r\n// modifiers. We also need to merge static and dynamic class / style attributes.\r\n// - onXXX handlers / style: merge into array\r\n// - class: merge into single expression with concatenation\r\nfunction dedupeProperties(properties) {\r\n const knownProps = new Map();\r\n const deduped = [];\r\n for (let i = 0; i < properties.length; i++) {\r\n const prop = properties[i];\r\n // dynamic keys are always allowed\r\n if (prop.key.type === 8 /* COMPOUND_EXPRESSION */ || !prop.key.isStatic) {\r\n deduped.push(prop);\r\n continue;\r\n }\r\n const name = prop.key.content;\r\n const existing = knownProps.get(name);\r\n if (existing) {\r\n if (name === 'style' || name === 'class' || isOn(name)) {\r\n mergeAsArray(existing, prop);\r\n }\r\n // unexpected duplicate, should have emitted error during parse\r\n }\r\n else {\r\n knownProps.set(name, prop);\r\n deduped.push(prop);\r\n }\r\n }\r\n return deduped;\r\n}\r\nfunction mergeAsArray(existing, incoming) {\r\n if (existing.value.type === 17 /* JS_ARRAY_EXPRESSION */) {\r\n existing.value.elements.push(incoming.value);\r\n }\r\n else {\r\n existing.value = createArrayExpression([existing.value, incoming.value], existing.loc);\r\n }\r\n}\r\nfunction buildDirectiveArgs(dir, context) {\r\n const dirArgs = [];\r\n const runtime = directiveImportMap.get(dir);\r\n if (runtime) {\r\n // built-in directive with runtime\r\n dirArgs.push(context.helperString(runtime));\r\n }\r\n else {\r\n {\r\n // inject statement for resolving directive\r\n context.helper(RESOLVE_DIRECTIVE);\r\n context.directives.add(dir.name);\r\n dirArgs.push(toValidAssetId(dir.name, `directive`));\r\n }\r\n }\r\n const { loc } = dir;\r\n if (dir.exp)\r\n dirArgs.push(dir.exp);\r\n if (dir.arg) {\r\n if (!dir.exp) {\r\n dirArgs.push(`void 0`);\r\n }\r\n dirArgs.push(dir.arg);\r\n }\r\n if (Object.keys(dir.modifiers).length) {\r\n if (!dir.arg) {\r\n if (!dir.exp) {\r\n dirArgs.push(`void 0`);\r\n }\r\n dirArgs.push(`void 0`);\r\n }\r\n const trueExpression = createSimpleExpression(`true`, false, loc);\r\n dirArgs.push(createObjectExpression(dir.modifiers.map(modifier => createObjectProperty(modifier, trueExpression)), loc));\r\n }\r\n return createArrayExpression(dirArgs, dir.loc);\r\n}\r\nfunction stringifyDynamicPropNames(props) {\r\n let propsNamesString = `[`;\r\n for (let i = 0, l = props.length; i < l; i++) {\r\n propsNamesString += JSON.stringify(props[i]);\r\n if (i < l - 1)\r\n propsNamesString += ', ';\r\n }\r\n return propsNamesString + `]`;\r\n}\r\nfunction isComponentTag(tag) {\r\n return tag === 'component' || tag === 'Component';\r\n}\n\n(process.env.NODE_ENV !== 'production')\r\n ? Object.freeze({})\r\n : {};\r\n(process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst cacheStringFunction = (fn) => {\r\n const cache = Object.create(null);\r\n return ((str) => {\r\n const hit = cache[str];\r\n return hit || (cache[str] = fn(str));\r\n });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\n\nconst transformSlotOutlet = (node, context) => {\r\n if (isSlotOutlet(node)) {\r\n const { children, loc } = node;\r\n const { slotName, slotProps } = processSlotOutlet(node, context);\r\n const slotArgs = [\r\n context.prefixIdentifiers ? `_ctx.$slots` : `$slots`,\r\n slotName,\r\n '{}',\r\n 'undefined',\r\n 'true'\r\n ];\r\n let expectedLen = 2;\r\n if (slotProps) {\r\n slotArgs[2] = slotProps;\r\n expectedLen = 3;\r\n }\r\n if (children.length) {\r\n slotArgs[3] = createFunctionExpression([], children, false, false, loc);\r\n expectedLen = 4;\r\n }\r\n if (context.scopeId && !context.slotted) {\r\n expectedLen = 5;\r\n }\r\n slotArgs.splice(expectedLen); // remove unused arguments\r\n node.codegenNode = createCallExpression(context.helper(RENDER_SLOT), slotArgs, loc);\r\n }\r\n};\r\nfunction processSlotOutlet(node, context) {\r\n let slotName = `\"default\"`;\r\n let slotProps = undefined;\r\n const nonNameProps = [];\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (p.value) {\r\n if (p.name === 'name') {\r\n slotName = JSON.stringify(p.value.content);\r\n }\r\n else {\r\n p.name = camelize(p.name);\r\n nonNameProps.push(p);\r\n }\r\n }\r\n }\r\n else {\r\n if (p.name === 'bind' && isStaticArgOf(p.arg, 'name')) {\r\n if (p.exp)\r\n slotName = p.exp;\r\n }\r\n else {\r\n if (p.name === 'bind' && p.arg && isStaticExp(p.arg)) {\r\n p.arg.content = camelize(p.arg.content);\r\n }\r\n nonNameProps.push(p);\r\n }\r\n }\r\n }\r\n if (nonNameProps.length > 0) {\r\n const { props, directives } = buildProps(node, context, nonNameProps);\r\n slotProps = props;\r\n if (directives.length) {\r\n context.onError(createCompilerError(36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */, directives[0].loc));\r\n }\r\n }\r\n return {\r\n slotName,\r\n slotProps\r\n };\r\n}\n\nconst fnExpRE = /^\\s*([\\w$_]+|(async\\s*)?\\([^)]*?\\))\\s*=>|^\\s*(async\\s+)?function(?:\\s+[\\w$]+)?\\s*\\(/;\r\nconst transformOn = (dir, node, context, augmentor) => {\r\n const { loc, modifiers, arg } = dir;\r\n if (!dir.exp && !modifiers.length) {\r\n context.onError(createCompilerError(35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n }\r\n let eventName;\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n let rawName = arg.content;\r\n // TODO deprecate @vnodeXXX usage\r\n if (rawName.startsWith('vue:')) {\r\n rawName = `vnode-${rawName.slice(4)}`;\r\n }\r\n // for all event listeners, auto convert it to camelCase. See issue #2249\r\n eventName = createSimpleExpression(toHandlerKey(camelize$1(rawName)), true, arg.loc);\r\n }\r\n else {\r\n // #2388\r\n eventName = createCompoundExpression([\r\n `${context.helperString(TO_HANDLER_KEY)}(`,\r\n arg,\r\n `)`\r\n ]);\r\n }\r\n }\r\n else {\r\n // already a compound expression.\r\n eventName = arg;\r\n eventName.children.unshift(`${context.helperString(TO_HANDLER_KEY)}(`);\r\n eventName.children.push(`)`);\r\n }\r\n // handler processing\r\n let exp = dir.exp;\r\n if (exp && !exp.content.trim()) {\r\n exp = undefined;\r\n }\r\n let shouldCache = context.cacheHandlers && !exp && !context.inVOnce;\r\n if (exp) {\r\n const isMemberExp = isMemberExpression(exp.content);\r\n const isInlineStatement = !(isMemberExp || fnExpRE.test(exp.content));\r\n const hasMultipleStatements = exp.content.includes(`;`);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(exp, context, false, hasMultipleStatements);\r\n }\r\n if (isInlineStatement || (shouldCache && isMemberExp)) {\r\n // wrap inline statement in a function expression\r\n exp = createCompoundExpression([\r\n `${isInlineStatement\r\n ? `$event`\r\n : `${``}(...args)`} => ${hasMultipleStatements ? `{` : `(`}`,\r\n exp,\r\n hasMultipleStatements ? `}` : `)`\r\n ]);\r\n }\r\n }\r\n let ret = {\r\n props: [\r\n createObjectProperty(eventName, exp || createSimpleExpression(`() => {}`, false, loc))\r\n ]\r\n };\r\n // apply extended compiler augmentor\r\n if (augmentor) {\r\n ret = augmentor(ret);\r\n }\r\n if (shouldCache) {\r\n // cache handlers so that it's always the same handler being passed down.\r\n // this avoids unnecessary re-renders when users use inline handlers on\r\n // components.\r\n ret.props[0].value = context.cache(ret.props[0].value);\r\n }\r\n // mark the key as handler for props normalization check\r\n ret.props.forEach(p => (p.key.isHandlerKey = true));\r\n return ret;\r\n};\n\n// v-bind without arg is handled directly in ./transformElements.ts due to it affecting\r\n// codegen for the entire props object. This transform here is only for v-bind\r\n// *with* args.\r\nconst transformBind = (dir, _node, context) => {\r\n const { exp, modifiers, loc } = dir;\r\n const arg = dir.arg;\r\n if (arg.type !== 4 /* SIMPLE_EXPRESSION */) {\r\n arg.children.unshift(`(`);\r\n arg.children.push(`) || \"\"`);\r\n }\r\n else if (!arg.isStatic) {\r\n arg.content = `${arg.content} || \"\"`;\r\n }\r\n // .sync is replaced by v-model:arg\r\n if (modifiers.includes('camel')) {\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n arg.content = camelize$1(arg.content);\r\n }\r\n else {\r\n arg.content = `${context.helperString(CAMELIZE)}(${arg.content})`;\r\n }\r\n }\r\n else {\r\n arg.children.unshift(`${context.helperString(CAMELIZE)}(`);\r\n arg.children.push(`)`);\r\n }\r\n }\r\n if (!context.inSSR) {\r\n if (modifiers.includes('prop')) {\r\n injectPrefix(arg, '.');\r\n }\r\n if (modifiers.includes('attr')) {\r\n injectPrefix(arg, '^');\r\n }\r\n }\r\n if (!exp ||\r\n (exp.type === 4 /* SIMPLE_EXPRESSION */ && !exp.content.trim())) {\r\n context.onError(createCompilerError(34 /* X_V_BIND_NO_EXPRESSION */, loc));\r\n return {\r\n props: [createObjectProperty(arg, createSimpleExpression('', true, loc))]\r\n };\r\n }\r\n return {\r\n props: [createObjectProperty(arg, exp)]\r\n };\r\n};\r\nconst injectPrefix = (arg, prefix) => {\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n arg.content = prefix + arg.content;\r\n }\r\n else {\r\n arg.content = `\\`${prefix}\\${${arg.content}}\\``;\r\n }\r\n }\r\n else {\r\n arg.children.unshift(`'${prefix}' + (`);\r\n arg.children.push(`)`);\r\n }\r\n};\n\n// Merge adjacent text nodes and expressions into a single expression\r\n// e.g. <div>abc {{ d }} {{ e }}</div> should have a single expression node as child.\r\nconst transformText = (node, context) => {\r\n if (node.type === 0 /* ROOT */ ||\r\n node.type === 1 /* ELEMENT */ ||\r\n node.type === 11 /* FOR */ ||\r\n node.type === 10 /* IF_BRANCH */) {\r\n // perform the transform on node exit so that all expressions have already\r\n // been processed.\r\n return () => {\r\n const children = node.children;\r\n let currentContainer = undefined;\r\n let hasText = false;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isText(child)) {\r\n hasText = true;\r\n for (let j = i + 1; j < children.length; j++) {\r\n const next = children[j];\r\n if (isText(next)) {\r\n if (!currentContainer) {\r\n currentContainer = children[i] = {\r\n type: 8 /* COMPOUND_EXPRESSION */,\r\n loc: child.loc,\r\n children: [child]\r\n };\r\n }\r\n // merge adjacent text node into current\r\n currentContainer.children.push(` + `, next);\r\n children.splice(j, 1);\r\n j--;\r\n }\r\n else {\r\n currentContainer = undefined;\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n if (!hasText ||\r\n // if this is a plain element with a single text child, leave it\r\n // as-is since the runtime has dedicated fast path for this by directly\r\n // setting textContent of the element.\r\n // for component root it's always normalized anyway.\r\n (children.length === 1 &&\r\n (node.type === 0 /* ROOT */ ||\r\n (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n // #3756\r\n // custom directives can potentially add DOM elements arbitrarily,\r\n // we need to avoid setting textContent of the element at runtime\r\n // to avoid accidentally overwriting the DOM elements added\r\n // by the user through custom directives.\r\n !node.props.find(p => p.type === 7 /* DIRECTIVE */ &&\r\n !context.directiveTransforms[p.name]) &&\r\n // in compat mode, <template> tags with no special directives\r\n // will be rendered as a fragment so its children must be\r\n // converted into vnodes.\r\n !(node.tag === 'template'))))) {\r\n return;\r\n }\r\n // pre-convert text nodes into createTextVNode(text) calls to avoid\r\n // runtime normalization.\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isText(child) || child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n const callArgs = [];\r\n // createTextVNode defaults to single whitespace, so if it is a\r\n // single space the code could be an empty call to save bytes.\r\n if (child.type !== 2 /* TEXT */ || child.content !== ' ') {\r\n callArgs.push(child);\r\n }\r\n // mark dynamic text with flag so it gets patched inside a block\r\n if (!context.ssr &&\r\n getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n callArgs.push(1 /* TEXT */ +\r\n ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[1 /* TEXT */]} */` : ``));\r\n }\r\n children[i] = {\r\n type: 12 /* TEXT_CALL */,\r\n content: child,\r\n loc: child.loc,\r\n codegenNode: createCallExpression(context.helper(CREATE_TEXT), callArgs)\r\n };\r\n }\r\n }\r\n };\r\n }\r\n};\n\nconst seen = new WeakSet();\r\nconst transformOnce = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ && findDir(node, 'once', true)) {\r\n if (seen.has(node) || context.inVOnce) {\r\n return;\r\n }\r\n seen.add(node);\r\n context.inVOnce = true;\r\n context.helper(SET_BLOCK_TRACKING);\r\n return () => {\r\n context.inVOnce = false;\r\n const cur = context.currentNode;\r\n if (cur.codegenNode) {\r\n cur.codegenNode = context.cache(cur.codegenNode, true /* isVNode */);\r\n }\r\n };\r\n }\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n const { exp, arg } = dir;\r\n if (!exp) {\r\n context.onError(createCompilerError(41 /* X_V_MODEL_NO_EXPRESSION */, dir.loc));\r\n return createTransformProps();\r\n }\r\n const rawExp = exp.loc.source;\r\n const expString = exp.type === 4 /* SIMPLE_EXPRESSION */ ? exp.content : rawExp;\r\n // im SFC <script setup> inline mode, the exp may have been transformed into\r\n // _unref(exp)\r\n context.bindingMetadata[rawExp];\r\n const maybeRef = !true /* SETUP_CONST */;\r\n if (!expString.trim() ||\r\n (!isMemberExpression(expString) && !maybeRef)) {\r\n context.onError(createCompilerError(42 /* X_V_MODEL_MALFORMED_EXPRESSION */, exp.loc));\r\n return createTransformProps();\r\n }\r\n const propName = arg ? arg : createSimpleExpression('modelValue', true);\r\n const eventName = arg\r\n ? isStaticExp(arg)\r\n ? `onUpdate:${arg.content}`\r\n : createCompoundExpression(['\"onUpdate:\" + ', arg])\r\n : `onUpdate:modelValue`;\r\n let assignmentExp;\r\n const eventArg = context.isTS ? `($event: any)` : `$event`;\r\n {\r\n assignmentExp = createCompoundExpression([\r\n `${eventArg} => ((`,\r\n exp,\r\n `) = $event)`\r\n ]);\r\n }\r\n const props = [\r\n // modelValue: foo\r\n createObjectProperty(propName, dir.exp),\r\n // \"onUpdate:modelValue\": $event => (foo = $event)\r\n createObjectProperty(eventName, assignmentExp)\r\n ];\r\n // modelModifiers: { foo: true, \"bar-baz\": true }\r\n if (dir.modifiers.length && node.tagType === 1 /* COMPONENT */) {\r\n const modifiers = dir.modifiers\r\n .map(m => (isSimpleIdentifier(m) ? m : JSON.stringify(m)) + `: true`)\r\n .join(`, `);\r\n const modifiersKey = arg\r\n ? isStaticExp(arg)\r\n ? `${arg.content}Modifiers`\r\n : createCompoundExpression([arg, ' + \"Modifiers\"'])\r\n : `modelModifiers`;\r\n props.push(createObjectProperty(modifiersKey, createSimpleExpression(`{ ${modifiers} }`, false, dir.loc, 2 /* CAN_HOIST */)));\r\n }\r\n return createTransformProps(props);\r\n};\r\nfunction createTransformProps(props = []) {\r\n return { props };\r\n}\n\nconst validDivisionCharRE = /[\\w).+\\-_$\\]]/;\r\nconst transformFilter = (node, context) => {\r\n if (!isCompatEnabled(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context)) {\r\n return;\r\n }\r\n if (node.type === 5 /* INTERPOLATION */) {\r\n // filter rewrite is applied before expression transform so only\r\n // simple expressions are possible at this stage\r\n rewriteFilter(node.content, context);\r\n }\r\n if (node.type === 1 /* ELEMENT */) {\r\n node.props.forEach((prop) => {\r\n if (prop.type === 7 /* DIRECTIVE */ &&\r\n prop.name !== 'for' &&\r\n prop.exp) {\r\n rewriteFilter(prop.exp, context);\r\n }\r\n });\r\n }\r\n};\r\nfunction rewriteFilter(node, context) {\r\n if (node.type === 4 /* SIMPLE_EXPRESSION */) {\r\n parseFilter(node, context);\r\n }\r\n else {\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (typeof child !== 'object')\r\n continue;\r\n if (child.type === 4 /* SIMPLE_EXPRESSION */) {\r\n parseFilter(child, context);\r\n }\r\n else if (child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n rewriteFilter(node, context);\r\n }\r\n else if (child.type === 5 /* INTERPOLATION */) {\r\n rewriteFilter(child.content, context);\r\n }\r\n }\r\n }\r\n}\r\nfunction parseFilter(node, context) {\r\n const exp = node.content;\r\n let inSingle = false;\r\n let inDouble = false;\r\n let inTemplateString = false;\r\n let inRegex = false;\r\n let curly = 0;\r\n let square = 0;\r\n let paren = 0;\r\n let lastFilterIndex = 0;\r\n let c, prev, i, expression, filters = [];\r\n for (i = 0; i < exp.length; i++) {\r\n prev = c;\r\n c = exp.charCodeAt(i);\r\n if (inSingle) {\r\n if (c === 0x27 && prev !== 0x5c)\r\n inSingle = false;\r\n }\r\n else if (inDouble) {\r\n if (c === 0x22 && prev !== 0x5c)\r\n inDouble = false;\r\n }\r\n else if (inTemplateString) {\r\n if (c === 0x60 && prev !== 0x5c)\r\n inTemplateString = false;\r\n }\r\n else if (inRegex) {\r\n if (c === 0x2f && prev !== 0x5c)\r\n inRegex = false;\r\n }\r\n else if (c === 0x7c && // pipe\r\n exp.charCodeAt(i + 1) !== 0x7c &&\r\n exp.charCodeAt(i - 1) !== 0x7c &&\r\n !curly &&\r\n !square &&\r\n !paren) {\r\n if (expression === undefined) {\r\n // first filter, end of expression\r\n lastFilterIndex = i + 1;\r\n expression = exp.slice(0, i).trim();\r\n }\r\n else {\r\n pushFilter();\r\n }\r\n }\r\n else {\r\n switch (c) {\r\n case 0x22:\r\n inDouble = true;\r\n break; // \"\r\n case 0x27:\r\n inSingle = true;\r\n break; // '\r\n case 0x60:\r\n inTemplateString = true;\r\n break; // `\r\n case 0x28:\r\n paren++;\r\n break; // (\r\n case 0x29:\r\n paren--;\r\n break; // )\r\n case 0x5b:\r\n square++;\r\n break; // [\r\n case 0x5d:\r\n square--;\r\n break; // ]\r\n case 0x7b:\r\n curly++;\r\n break; // {\r\n case 0x7d:\r\n curly--;\r\n break; // }\r\n }\r\n if (c === 0x2f) {\r\n // /\r\n let j = i - 1;\r\n let p;\r\n // find first non-whitespace prev char\r\n for (; j >= 0; j--) {\r\n p = exp.charAt(j);\r\n if (p !== ' ')\r\n break;\r\n }\r\n if (!p || !validDivisionCharRE.test(p)) {\r\n inRegex = true;\r\n }\r\n }\r\n }\r\n }\r\n if (expression === undefined) {\r\n expression = exp.slice(0, i).trim();\r\n }\r\n else if (lastFilterIndex !== 0) {\r\n pushFilter();\r\n }\r\n function pushFilter() {\r\n filters.push(exp.slice(lastFilterIndex, i).trim());\r\n lastFilterIndex = i + 1;\r\n }\r\n if (filters.length) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warnDeprecation(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context, node.loc);\r\n for (i = 0; i < filters.length; i++) {\r\n expression = wrapFilter(expression, filters[i], context);\r\n }\r\n node.content = expression;\r\n }\r\n}\r\nfunction wrapFilter(exp, filter, context) {\r\n context.helper(RESOLVE_FILTER);\r\n const i = filter.indexOf('(');\r\n if (i < 0) {\r\n context.filters.add(filter);\r\n return `${toValidAssetId(filter, 'filter')}(${exp})`;\r\n }\r\n else {\r\n const name = filter.slice(0, i);\r\n const args = filter.slice(i + 1);\r\n context.filters.add(name);\r\n return `${toValidAssetId(name, 'filter')}(${exp}${args !== ')' ? ',' + args : args}`;\r\n }\r\n}\n\nconst seen$1 = new WeakSet();\r\nconst transformMemo = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n const dir = findDir(node, 'memo');\r\n if (!dir || seen$1.has(node)) {\r\n return;\r\n }\r\n seen$1.add(node);\r\n return () => {\r\n const codegenNode = node.codegenNode ||\r\n context.currentNode.codegenNode;\r\n if (codegenNode && codegenNode.type === 13 /* VNODE_CALL */) {\r\n // non-component sub tree should be turned into a block\r\n if (node.tagType !== 1 /* COMPONENT */) {\r\n makeBlock(codegenNode, context);\r\n }\r\n node.codegenNode = createCallExpression(context.helper(WITH_MEMO), [\r\n dir.exp,\r\n createFunctionExpression(undefined, codegenNode),\r\n `_cache`,\r\n String(context.cached++)\r\n ]);\r\n }\r\n };\r\n }\r\n};\n\nfunction getBaseTransformPreset(prefixIdentifiers) {\r\n return [\r\n [\r\n transformOnce,\r\n transformIf,\r\n transformMemo,\r\n transformFor,\r\n ...([transformFilter] ),\r\n ...((process.env.NODE_ENV !== 'production')\r\n ? [transformExpression]\r\n : []),\r\n transformSlotOutlet,\r\n transformElement,\r\n trackSlotScopes,\r\n transformText\r\n ],\r\n {\r\n on: transformOn,\r\n bind: transformBind,\r\n model: transformModel\r\n }\r\n ];\r\n}\r\n// we name it `baseCompile` so that higher order compilers like\r\n// @vue/compiler-dom can export `compile` while re-exporting everything else.\r\nfunction baseCompile(template, options = {}) {\r\n const onError = options.onError || defaultOnError;\r\n const isModuleMode = options.mode === 'module';\r\n /* istanbul ignore if */\r\n {\r\n if (options.prefixIdentifiers === true) {\r\n onError(createCompilerError(46 /* X_PREFIX_ID_NOT_SUPPORTED */));\r\n }\r\n else if (isModuleMode) {\r\n onError(createCompilerError(47 /* X_MODULE_MODE_NOT_SUPPORTED */));\r\n }\r\n }\r\n const prefixIdentifiers = !true ;\r\n if (options.cacheHandlers) {\r\n onError(createCompilerError(48 /* X_CACHE_HANDLER_NOT_SUPPORTED */));\r\n }\r\n if (options.scopeId && !isModuleMode) {\r\n onError(createCompilerError(49 /* X_SCOPE_ID_NOT_SUPPORTED */));\r\n }\r\n const ast = isString(template) ? baseParse(template, options) : template;\r\n const [nodeTransforms, directiveTransforms] = getBaseTransformPreset();\r\n transform(ast, extend({}, options, {\r\n prefixIdentifiers,\r\n nodeTransforms: [\r\n ...nodeTransforms,\r\n ...(options.nodeTransforms || []) // user transforms\r\n ],\r\n directiveTransforms: extend({}, directiveTransforms, options.directiveTransforms || {} // user transforms\r\n )\r\n }));\r\n return generate(ast, extend({}, options, {\r\n prefixIdentifiers\r\n }));\r\n}\n\nconst noopDirectiveTransform = () => ({ props: [] });\n\nexport { BASE_TRANSITION, CAMELIZE, CAPITALIZE, CREATE_BLOCK, CREATE_COMMENT, CREATE_ELEMENT_BLOCK, CREATE_ELEMENT_VNODE, CREATE_SLOTS, CREATE_STATIC, CREATE_TEXT, CREATE_VNODE, FRAGMENT, GUARD_REACTIVE_PROPS, IS_MEMO_SAME, IS_REF, KEEP_ALIVE, MERGE_PROPS, NORMALIZE_CLASS, NORMALIZE_PROPS, NORMALIZE_STYLE, OPEN_BLOCK, POP_SCOPE_ID, PUSH_SCOPE_ID, RENDER_LIST, RENDER_SLOT, RESOLVE_COMPONENT, RESOLVE_DIRECTIVE, RESOLVE_DYNAMIC_COMPONENT, RESOLVE_FILTER, SET_BLOCK_TRACKING, SUSPENSE, TELEPORT, TO_DISPLAY_STRING, TO_HANDLERS, TO_HANDLER_KEY, UNREF, WITH_CTX, WITH_DIRECTIVES, WITH_MEMO, advancePositionWithClone, advancePositionWithMutation, assert, baseCompile, baseParse, buildProps, buildSlots, checkCompatEnabled, createArrayExpression, createAssignmentExpression, createBlockStatement, createCacheExpression, createCallExpression, createCompilerError, createCompoundExpression, createConditionalExpression, createForLoopParams, createFunctionExpression, createIfStatement, createInterpolation, createObjectExpression, createObjectProperty, createReturnStatement, createRoot, createSequenceExpression, createSimpleExpression, createStructuralDirectiveTransform, createTemplateLiteral, createTransformContext, createVNodeCall, extractIdentifiers, findDir, findProp, generate, getBaseTransformPreset, getInnerRange, getMemoedVNodeCall, getVNodeBlockHelper, getVNodeHelper, hasDynamicKeyVBind, hasScopeRef, helperNameMap, injectProp, isBuiltInType, isCoreComponent, isFunctionType, isInDestructureAssignment, isMemberExpression, isMemberExpressionBrowser, isMemberExpressionNode, isReferencedIdentifier, isSimpleIdentifier, isSlotOutlet, isStaticArgOf, isStaticExp, isStaticProperty, isStaticPropertyKey, isTemplateNode, isText, isVSlot, locStub, makeBlock, noopDirectiveTransform, processExpression, processFor, processIf, processSlotOutlet, registerRuntimeHelpers, resolveComponentType, toValidAssetId, trackSlotScopes, trackVForSlotScopes, transform, transformBind, transformElement, transformExpression, transformModel, transformOn, traverseNode, walkBlockDeclarations, walkFunctionParams, walkIdentifiers, warnDeprecation };\n","import { registerRuntimeHelpers, isBuiltInType, createSimpleExpression, createCompilerError, createObjectProperty, createCallExpression, TO_DISPLAY_STRING, transformModel as transformModel$1, findProp, hasDynamicKeyVBind, transformOn as transformOn$1, createCompoundExpression, isStaticExp, checkCompatEnabled, noopDirectiveTransform, baseCompile, baseParse } from '@vue/compiler-core';\nexport * from '@vue/compiler-core';\nimport { isVoidTag, isHTMLTag, isSVGTag, makeMap, parseStringStyle, capitalize, extend } from '@vue/shared';\n\nconst V_MODEL_RADIO = Symbol((process.env.NODE_ENV !== 'production') ? `vModelRadio` : ``);\r\nconst V_MODEL_CHECKBOX = Symbol((process.env.NODE_ENV !== 'production') ? `vModelCheckbox` : ``);\r\nconst V_MODEL_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelText` : ``);\r\nconst V_MODEL_SELECT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelSelect` : ``);\r\nconst V_MODEL_DYNAMIC = Symbol((process.env.NODE_ENV !== 'production') ? `vModelDynamic` : ``);\r\nconst V_ON_WITH_MODIFIERS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnModifiersGuard` : ``);\r\nconst V_ON_WITH_KEYS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnKeysGuard` : ``);\r\nconst V_SHOW = Symbol((process.env.NODE_ENV !== 'production') ? `vShow` : ``);\r\nconst TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `Transition` : ``);\r\nconst TRANSITION_GROUP = Symbol((process.env.NODE_ENV !== 'production') ? `TransitionGroup` : ``);\r\nregisterRuntimeHelpers({\r\n [V_MODEL_RADIO]: `vModelRadio`,\r\n [V_MODEL_CHECKBOX]: `vModelCheckbox`,\r\n [V_MODEL_TEXT]: `vModelText`,\r\n [V_MODEL_SELECT]: `vModelSelect`,\r\n [V_MODEL_DYNAMIC]: `vModelDynamic`,\r\n [V_ON_WITH_MODIFIERS]: `withModifiers`,\r\n [V_ON_WITH_KEYS]: `withKeys`,\r\n [V_SHOW]: `vShow`,\r\n [TRANSITION]: `Transition`,\r\n [TRANSITION_GROUP]: `TransitionGroup`\r\n});\n\n/* eslint-disable no-restricted-globals */\r\nlet decoder;\r\nfunction decodeHtmlBrowser(raw, asAttr = false) {\r\n if (!decoder) {\r\n decoder = document.createElement('div');\r\n }\r\n if (asAttr) {\r\n decoder.innerHTML = `<div foo=\"${raw.replace(/\"/g, '"')}\">`;\r\n return decoder.children[0].getAttribute('foo');\r\n }\r\n else {\r\n decoder.innerHTML = raw;\r\n return decoder.textContent;\r\n }\r\n}\n\nconst isRawTextContainer = /*#__PURE__*/ makeMap('style,iframe,script,noscript', true);\r\nconst parserOptions = {\r\n isVoidTag,\r\n isNativeTag: tag => isHTMLTag(tag) || isSVGTag(tag),\r\n isPreTag: tag => tag === 'pre',\r\n decodeEntities: decodeHtmlBrowser ,\r\n isBuiltInComponent: (tag) => {\r\n if (isBuiltInType(tag, `Transition`)) {\r\n return TRANSITION;\r\n }\r\n else if (isBuiltInType(tag, `TransitionGroup`)) {\r\n return TRANSITION_GROUP;\r\n }\r\n },\r\n // https://html.spec.whatwg.org/multipage/parsing.html#tree-construction-dispatcher\r\n getNamespace(tag, parent) {\r\n let ns = parent ? parent.ns : 0 /* HTML */;\r\n if (parent && ns === 2 /* MATH_ML */) {\r\n if (parent.tag === 'annotation-xml') {\r\n if (tag === 'svg') {\r\n return 1 /* SVG */;\r\n }\r\n if (parent.props.some(a => a.type === 6 /* ATTRIBUTE */ &&\r\n a.name === 'encoding' &&\r\n a.value != null &&\r\n (a.value.content === 'text/html' ||\r\n a.value.content === 'application/xhtml+xml'))) {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n else if (/^m(?:[ions]|text)$/.test(parent.tag) &&\r\n tag !== 'mglyph' &&\r\n tag !== 'malignmark') {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n else if (parent && ns === 1 /* SVG */) {\r\n if (parent.tag === 'foreignObject' ||\r\n parent.tag === 'desc' ||\r\n parent.tag === 'title') {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n if (ns === 0 /* HTML */) {\r\n if (tag === 'svg') {\r\n return 1 /* SVG */;\r\n }\r\n if (tag === 'math') {\r\n return 2 /* MATH_ML */;\r\n }\r\n }\r\n return ns;\r\n },\r\n // https://html.spec.whatwg.org/multipage/parsing.html#parsing-html-fragments\r\n getTextMode({ tag, ns }) {\r\n if (ns === 0 /* HTML */) {\r\n if (tag === 'textarea' || tag === 'title') {\r\n return 1 /* RCDATA */;\r\n }\r\n if (isRawTextContainer(tag)) {\r\n return 2 /* RAWTEXT */;\r\n }\r\n }\r\n return 0 /* DATA */;\r\n }\r\n};\n\n// Parse inline CSS strings for static style attributes into an object.\r\n// This is a NodeTransform since it works on the static `style` attribute and\r\n// converts it into a dynamic equivalent:\r\n// style=\"color: red\" -> :style='{ \"color\": \"red\" }'\r\n// It is then processed by `transformElement` and included in the generated\r\n// props.\r\nconst transformStyle = node => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n node.props.forEach((p, i) => {\r\n if (p.type === 6 /* ATTRIBUTE */ && p.name === 'style' && p.value) {\r\n // replace p with an expression node\r\n node.props[i] = {\r\n type: 7 /* DIRECTIVE */,\r\n name: `bind`,\r\n arg: createSimpleExpression(`style`, true, p.loc),\r\n exp: parseInlineCSS(p.value.content, p.loc),\r\n modifiers: [],\r\n loc: p.loc\r\n };\r\n }\r\n });\r\n }\r\n};\r\nconst parseInlineCSS = (cssText, loc) => {\r\n const normalized = parseStringStyle(cssText);\r\n return createSimpleExpression(JSON.stringify(normalized), false, loc, 3 /* CAN_STRINGIFY */);\r\n};\n\nfunction createDOMCompilerError(code, loc) {\r\n return createCompilerError(code, loc, (process.env.NODE_ENV !== 'production') || !true ? DOMErrorMessages : undefined);\r\n}\r\nconst DOMErrorMessages = {\r\n [50 /* X_V_HTML_NO_EXPRESSION */]: `v-html is missing expression.`,\r\n [51 /* X_V_HTML_WITH_CHILDREN */]: `v-html will override element children.`,\r\n [52 /* X_V_TEXT_NO_EXPRESSION */]: `v-text is missing expression.`,\r\n [53 /* X_V_TEXT_WITH_CHILDREN */]: `v-text will override element children.`,\r\n [54 /* X_V_MODEL_ON_INVALID_ELEMENT */]: `v-model can only be used on <input>, <textarea> and <select> elements.`,\r\n [55 /* X_V_MODEL_ARG_ON_ELEMENT */]: `v-model argument is not supported on plain elements.`,\r\n [56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */]: `v-model cannot be used on file inputs since they are read-only. Use a v-on:change listener instead.`,\r\n [57 /* X_V_MODEL_UNNECESSARY_VALUE */]: `Unnecessary value binding used alongside v-model. It will interfere with v-model's behavior.`,\r\n [58 /* X_V_SHOW_NO_EXPRESSION */]: `v-show is missing expression.`,\r\n [59 /* X_TRANSITION_INVALID_CHILDREN */]: `<Transition> expects exactly one child element or component.`,\r\n [60 /* X_IGNORED_SIDE_EFFECT_TAG */]: `Tags with side effect (<script> and <style>) are ignored in client component templates.`\r\n};\n\nconst transformVHtml = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(50 /* X_V_HTML_NO_EXPRESSION */, loc));\r\n }\r\n if (node.children.length) {\r\n context.onError(createDOMCompilerError(51 /* X_V_HTML_WITH_CHILDREN */, loc));\r\n node.children.length = 0;\r\n }\r\n return {\r\n props: [\r\n createObjectProperty(createSimpleExpression(`innerHTML`, true, loc), exp || createSimpleExpression('', true))\r\n ]\r\n };\r\n};\n\nconst transformVText = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(52 /* X_V_TEXT_NO_EXPRESSION */, loc));\r\n }\r\n if (node.children.length) {\r\n context.onError(createDOMCompilerError(53 /* X_V_TEXT_WITH_CHILDREN */, loc));\r\n node.children.length = 0;\r\n }\r\n return {\r\n props: [\r\n createObjectProperty(createSimpleExpression(`textContent`, true), exp\r\n ? createCallExpression(context.helperString(TO_DISPLAY_STRING), [exp], loc)\r\n : createSimpleExpression('', true))\r\n ]\r\n };\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n const baseResult = transformModel$1(dir, node, context);\r\n // base transform has errors OR component v-model (only need props)\r\n if (!baseResult.props.length || node.tagType === 1 /* COMPONENT */) {\r\n return baseResult;\r\n }\r\n if (dir.arg) {\r\n context.onError(createDOMCompilerError(55 /* X_V_MODEL_ARG_ON_ELEMENT */, dir.arg.loc));\r\n }\r\n function checkDuplicatedValue() {\r\n const value = findProp(node, 'value');\r\n if (value) {\r\n context.onError(createDOMCompilerError(57 /* X_V_MODEL_UNNECESSARY_VALUE */, value.loc));\r\n }\r\n }\r\n const { tag } = node;\r\n const isCustomElement = context.isCustomElement(tag);\r\n if (tag === 'input' ||\r\n tag === 'textarea' ||\r\n tag === 'select' ||\r\n isCustomElement) {\r\n let directiveToUse = V_MODEL_TEXT;\r\n let isInvalidType = false;\r\n if (tag === 'input' || isCustomElement) {\r\n const type = findProp(node, `type`);\r\n if (type) {\r\n if (type.type === 7 /* DIRECTIVE */) {\r\n // :type=\"foo\"\r\n directiveToUse = V_MODEL_DYNAMIC;\r\n }\r\n else if (type.value) {\r\n switch (type.value.content) {\r\n case 'radio':\r\n directiveToUse = V_MODEL_RADIO;\r\n break;\r\n case 'checkbox':\r\n directiveToUse = V_MODEL_CHECKBOX;\r\n break;\r\n case 'file':\r\n isInvalidType = true;\r\n context.onError(createDOMCompilerError(56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */, dir.loc));\r\n break;\r\n default:\r\n // text type\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n break;\r\n }\r\n }\r\n }\r\n else if (hasDynamicKeyVBind(node)) {\r\n // element has bindings with dynamic keys, which can possibly contain\r\n // \"type\".\r\n directiveToUse = V_MODEL_DYNAMIC;\r\n }\r\n else {\r\n // text type\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n }\r\n }\r\n else if (tag === 'select') {\r\n directiveToUse = V_MODEL_SELECT;\r\n }\r\n else {\r\n // textarea\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n }\r\n // inject runtime directive\r\n // by returning the helper symbol via needRuntime\r\n // the import will replaced a resolveDirective call.\r\n if (!isInvalidType) {\r\n baseResult.needRuntime = context.helper(directiveToUse);\r\n }\r\n }\r\n else {\r\n context.onError(createDOMCompilerError(54 /* X_V_MODEL_ON_INVALID_ELEMENT */, dir.loc));\r\n }\r\n // native vmodel doesn't need the `modelValue` props since they are also\r\n // passed to the runtime as `binding.value`. removing it reduces code size.\r\n baseResult.props = baseResult.props.filter(p => !(p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n p.key.content === 'modelValue'));\r\n return baseResult;\r\n};\n\nconst isEventOptionModifier = /*#__PURE__*/ makeMap(`passive,once,capture`);\r\nconst isNonKeyModifier = /*#__PURE__*/ makeMap(\r\n// event propagation management\r\n`stop,prevent,self,` +\r\n // system modifiers + exact\r\n `ctrl,shift,alt,meta,exact,` +\r\n // mouse\r\n `middle`);\r\n// left & right could be mouse or key modifiers based on event type\r\nconst maybeKeyModifier = /*#__PURE__*/ makeMap('left,right');\r\nconst isKeyboardEvent = /*#__PURE__*/ makeMap(`onkeyup,onkeydown,onkeypress`, true);\r\nconst resolveModifiers = (key, modifiers, context, loc) => {\r\n const keyModifiers = [];\r\n const nonKeyModifiers = [];\r\n const eventOptionModifiers = [];\r\n for (let i = 0; i < modifiers.length; i++) {\r\n const modifier = modifiers[i];\r\n if (modifier === 'native' &&\r\n checkCompatEnabled(\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */, context, loc)) {\r\n eventOptionModifiers.push(modifier);\r\n }\r\n else if (isEventOptionModifier(modifier)) {\r\n // eventOptionModifiers: modifiers for addEventListener() options,\r\n // e.g. .passive & .capture\r\n eventOptionModifiers.push(modifier);\r\n }\r\n else {\r\n // runtimeModifiers: modifiers that needs runtime guards\r\n if (maybeKeyModifier(modifier)) {\r\n if (isStaticExp(key)) {\r\n if (isKeyboardEvent(key.content)) {\r\n keyModifiers.push(modifier);\r\n }\r\n else {\r\n nonKeyModifiers.push(modifier);\r\n }\r\n }\r\n else {\r\n keyModifiers.push(modifier);\r\n nonKeyModifiers.push(modifier);\r\n }\r\n }\r\n else {\r\n if (isNonKeyModifier(modifier)) {\r\n nonKeyModifiers.push(modifier);\r\n }\r\n else {\r\n keyModifiers.push(modifier);\r\n }\r\n }\r\n }\r\n }\r\n return {\r\n keyModifiers,\r\n nonKeyModifiers,\r\n eventOptionModifiers\r\n };\r\n};\r\nconst transformClick = (key, event) => {\r\n const isStaticClick = isStaticExp(key) && key.content.toLowerCase() === 'onclick';\r\n return isStaticClick\r\n ? createSimpleExpression(event, true)\r\n : key.type !== 4 /* SIMPLE_EXPRESSION */\r\n ? createCompoundExpression([\r\n `(`,\r\n key,\r\n `) === \"onClick\" ? \"${event}\" : (`,\r\n key,\r\n `)`\r\n ])\r\n : key;\r\n};\r\nconst transformOn = (dir, node, context) => {\r\n return transformOn$1(dir, node, context, baseResult => {\r\n const { modifiers } = dir;\r\n if (!modifiers.length)\r\n return baseResult;\r\n let { key, value: handlerExp } = baseResult.props[0];\r\n const { keyModifiers, nonKeyModifiers, eventOptionModifiers } = resolveModifiers(key, modifiers, context, dir.loc);\r\n // normalize click.right and click.middle since they don't actually fire\r\n if (nonKeyModifiers.includes('right')) {\r\n key = transformClick(key, `onContextmenu`);\r\n }\r\n if (nonKeyModifiers.includes('middle')) {\r\n key = transformClick(key, `onMouseup`);\r\n }\r\n if (nonKeyModifiers.length) {\r\n handlerExp = createCallExpression(context.helper(V_ON_WITH_MODIFIERS), [\r\n handlerExp,\r\n JSON.stringify(nonKeyModifiers)\r\n ]);\r\n }\r\n if (keyModifiers.length &&\r\n // if event name is dynamic, always wrap with keys guard\r\n (!isStaticExp(key) || isKeyboardEvent(key.content))) {\r\n handlerExp = createCallExpression(context.helper(V_ON_WITH_KEYS), [\r\n handlerExp,\r\n JSON.stringify(keyModifiers)\r\n ]);\r\n }\r\n if (eventOptionModifiers.length) {\r\n const modifierPostfix = eventOptionModifiers.map(capitalize).join('');\r\n key = isStaticExp(key)\r\n ? createSimpleExpression(`${key.content}${modifierPostfix}`, true)\r\n : createCompoundExpression([`(`, key, `) + \"${modifierPostfix}\"`]);\r\n }\r\n return {\r\n props: [createObjectProperty(key, handlerExp)]\r\n };\r\n });\r\n};\n\nconst transformShow = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(58 /* X_V_SHOW_NO_EXPRESSION */, loc));\r\n }\r\n return {\r\n props: [],\r\n needRuntime: context.helper(V_SHOW)\r\n };\r\n};\n\nconst warnTransitionChildren = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 1 /* COMPONENT */) {\r\n const component = context.isBuiltInComponent(node.tag);\r\n if (component === TRANSITION) {\r\n return () => {\r\n if (node.children.length && hasMultipleChildren(node)) {\r\n context.onError(createDOMCompilerError(59 /* X_TRANSITION_INVALID_CHILDREN */, {\r\n start: node.children[0].loc.start,\r\n end: node.children[node.children.length - 1].loc.end,\r\n source: ''\r\n }));\r\n }\r\n };\r\n }\r\n }\r\n};\r\nfunction hasMultipleChildren(node) {\r\n // #1352 filter out potential comment nodes.\r\n const children = (node.children = node.children.filter(c => c.type !== 3 /* COMMENT */ &&\r\n !(c.type === 2 /* TEXT */ && !c.content.trim())));\r\n const child = children[0];\r\n return (children.length !== 1 ||\r\n child.type === 11 /* FOR */ ||\r\n (child.type === 9 /* IF */ && child.branches.some(hasMultipleChildren)));\r\n}\n\nconst ignoreSideEffectTags = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n (node.tag === 'script' || node.tag === 'style')) {\r\n context.onError(createDOMCompilerError(60 /* X_IGNORED_SIDE_EFFECT_TAG */, node.loc));\r\n context.removeNode();\r\n }\r\n};\n\nconst DOMNodeTransforms = [\r\n transformStyle,\r\n ...((process.env.NODE_ENV !== 'production') ? [warnTransitionChildren] : [])\r\n];\r\nconst DOMDirectiveTransforms = {\r\n cloak: noopDirectiveTransform,\r\n html: transformVHtml,\r\n text: transformVText,\r\n model: transformModel,\r\n on: transformOn,\r\n show: transformShow\r\n};\r\nfunction compile(template, options = {}) {\r\n return baseCompile(template, extend({}, parserOptions, options, {\r\n nodeTransforms: [\r\n // ignore <script> and <tag>\r\n // this is not put inside DOMNodeTransforms because that list is used\r\n // by compiler-ssr to generate vnode fallback branches\r\n ignoreSideEffectTags,\r\n ...DOMNodeTransforms,\r\n ...(options.nodeTransforms || [])\r\n ],\r\n directiveTransforms: extend({}, DOMDirectiveTransforms, options.directiveTransforms || {}),\r\n transformHoist: null \r\n }));\r\n}\r\nfunction parse(template, options = {}) {\r\n return baseParse(template, extend({}, parserOptions, options));\r\n}\n\nexport { DOMDirectiveTransforms, DOMNodeTransforms, TRANSITION, TRANSITION_GROUP, V_MODEL_CHECKBOX, V_MODEL_DYNAMIC, V_MODEL_RADIO, V_MODEL_SELECT, V_MODEL_TEXT, V_ON_WITH_KEYS, V_ON_WITH_MODIFIERS, V_SHOW, compile, createDOMCompilerError, parse, parserOptions, transformStyle };\n","import * as runtimeDom from '@vue/runtime-dom';\nimport { initCustomFormatter, warn, registerRuntimeCompiler } from '@vue/runtime-dom';\nexport * from '@vue/runtime-dom';\nimport { compile } from '@vue/compiler-dom';\nimport { isString, NOOP, extend, generateCodeFrame } from '@vue/shared';\n\nfunction initDev() {\r\n {\r\n initCustomFormatter();\r\n }\r\n}\n\n// This entry is the \"full-build\" that includes both the runtime\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n initDev();\r\n}\r\nconst compileCache = Object.create(null);\r\nfunction compileToFunction(template, options) {\r\n if (!isString(template)) {\r\n if (template.nodeType) {\r\n template = template.innerHTML;\r\n }\r\n else {\r\n (process.env.NODE_ENV !== 'production') && warn(`invalid template option: `, template);\r\n return NOOP;\r\n }\r\n }\r\n const key = template;\r\n const cached = compileCache[key];\r\n if (cached) {\r\n return cached;\r\n }\r\n if (template[0] === '#') {\r\n const el = document.querySelector(template);\r\n if ((process.env.NODE_ENV !== 'production') && !el) {\r\n warn(`Template element not found or is empty: ${template}`);\r\n }\r\n // __UNSAFE__\r\n // Reason: potential execution of JS expressions in in-DOM template.\r\n // The user must make sure the in-DOM template is trusted. If it's rendered\r\n // by the server, the template should not contain any user data.\r\n template = el ? el.innerHTML : ``;\r\n }\r\n const { code } = compile(template, extend({\r\n hoistStatic: true,\r\n onError: (process.env.NODE_ENV !== 'production') ? onError : undefined,\r\n onWarn: (process.env.NODE_ENV !== 'production') ? e => onError(e, true) : NOOP\r\n }, options));\r\n function onError(err, asWarning = false) {\r\n const message = asWarning\r\n ? err.message\r\n : `Template compilation error: ${err.message}`;\r\n const codeFrame = err.loc &&\r\n generateCodeFrame(template, err.loc.start.offset, err.loc.end.offset);\r\n warn(codeFrame ? `${message}\\n${codeFrame}` : message);\r\n }\r\n // The wildcard import results in a huge object with every export\r\n // with keys that cannot be mangled, and can be quite heavy size-wise.\r\n // In the global build we know `Vue` is available globally so we can avoid\r\n // the wildcard object.\r\n const render = (new Function('Vue', code)(runtimeDom));\r\n render._rc = true;\r\n return (compileCache[key] = render);\r\n}\r\nregisterRuntimeCompiler(compileToFunction);\n\nexport { compileToFunction as compile };\n","(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory(require(\"vue\"), require(\"sortablejs\"));\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([, \"sortablejs\"], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"vuedraggable\"] = factory(require(\"vue\"), require(\"sortablejs\"));\n\telse\n\t\troot[\"vuedraggable\"] = factory(root[\"Vue\"], root[\"Sortable\"]);\n})((typeof self !== 'undefined' ? self : this), function(__WEBPACK_EXTERNAL_MODULE__8bbf__, __WEBPACK_EXTERNAL_MODULE_a352__) {\nreturn /******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n/******/\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n/******/\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId]) {\n/******/ \t\t\treturn installedModules[moduleId].exports;\n/******/ \t\t}\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\ti: moduleId,\n/******/ \t\t\tl: false,\n/******/ \t\t\texports: {}\n/******/ \t\t};\n/******/\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n/******/\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.l = true;\n/******/\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n/******/\n/******/\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n/******/\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n/******/\n/******/ \t// define getter function for harmony exports\n/******/ \t__webpack_require__.d = function(exports, name, getter) {\n/******/ \t\tif(!__webpack_require__.o(exports, name)) {\n/******/ \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n/******/ \t\t}\n/******/ \t};\n/******/\n/******/ \t// define __esModule on exports\n/******/ \t__webpack_require__.r = function(exports) {\n/******/ \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n/******/ \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n/******/ \t\t}\n/******/ \t\tObject.defineProperty(exports, '__esModule', { value: true });\n/******/ \t};\n/******/\n/******/ \t// create a fake namespace object\n/******/ \t// mode & 1: value is a module id, require it\n/******/ \t// mode & 2: merge all properties of value into the ns\n/******/ \t// mode & 4: return value when already ns object\n/******/ \t// mode & 8|1: behave like require\n/******/ \t__webpack_require__.t = function(value, mode) {\n/******/ \t\tif(mode & 1) value = __webpack_require__(value);\n/******/ \t\tif(mode & 8) return value;\n/******/ \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n/******/ \t\tvar ns = Object.create(null);\n/******/ \t\t__webpack_require__.r(ns);\n/******/ \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n/******/ \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n/******/ \t\treturn ns;\n/******/ \t};\n/******/\n/******/ \t// getDefaultExport function for compatibility with non-harmony modules\n/******/ \t__webpack_require__.n = function(module) {\n/******/ \t\tvar getter = module && module.__esModule ?\n/******/ \t\t\tfunction getDefault() { return module['default']; } :\n/******/ \t\t\tfunction getModuleExports() { return module; };\n/******/ \t\t__webpack_require__.d(getter, 'a', getter);\n/******/ \t\treturn getter;\n/******/ \t};\n/******/\n/******/ \t// Object.prototype.hasOwnProperty.call\n/******/ \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n/******/\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n/******/\n/******/\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n/******/ })\n/************************************************************************/\n/******/ ({\n\n/***/ \"00ee\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n\n\n/***/ }),\n\n/***/ \"0366\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar aFunction = __webpack_require__(\"1c0b\");\n\n// optional / simple context binding\nmodule.exports = function (fn, that, length) {\n aFunction(fn);\n if (that === undefined) return fn;\n switch (length) {\n case 0: return function () {\n return fn.call(that);\n };\n case 1: return function (a) {\n return fn.call(that, a);\n };\n case 2: return function (a, b) {\n return fn.call(that, a, b);\n };\n case 3: return function (a, b, c) {\n return fn.call(that, a, b, c);\n };\n }\n return function (/* ...args */) {\n return fn.apply(that, arguments);\n };\n};\n\n\n/***/ }),\n\n/***/ \"057f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar nativeGetOwnPropertyNames = __webpack_require__(\"241c\").f;\n\nvar toString = {}.toString;\n\nvar windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames\n ? Object.getOwnPropertyNames(window) : [];\n\nvar getWindowNames = function (it) {\n try {\n return nativeGetOwnPropertyNames(it);\n } catch (error) {\n return windowNames.slice();\n }\n};\n\n// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window\nmodule.exports.f = function getOwnPropertyNames(it) {\n return windowNames && toString.call(it) == '[object Window]'\n ? getWindowNames(it)\n : nativeGetOwnPropertyNames(toIndexedObject(it));\n};\n\n\n/***/ }),\n\n/***/ \"06cf\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar propertyIsEnumerableModule = __webpack_require__(\"d1e7\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar toPrimitive = __webpack_require__(\"c04e\");\nvar has = __webpack_require__(\"5135\");\nvar IE8_DOM_DEFINE = __webpack_require__(\"0cfb\");\n\nvar nativeGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? nativeGetOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPrimitive(P, true);\n if (IE8_DOM_DEFINE) try {\n return nativeGetOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (has(O, P)) return createPropertyDescriptor(!propertyIsEnumerableModule.f.call(O, P), O[P]);\n};\n\n\n/***/ }),\n\n/***/ \"0cfb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar fails = __webpack_require__(\"d039\");\nvar createElement = __webpack_require__(\"cc12\");\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a != 7;\n});\n\n\n/***/ }),\n\n/***/ \"13d5\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $reduce = __webpack_require__(\"d58f\").left;\nvar arrayMethodIsStrict = __webpack_require__(\"a640\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar STRICT_METHOD = arrayMethodIsStrict('reduce');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('reduce', { 1: 0 });\n\n// `Array.prototype.reduce` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.reduce\n$({ target: 'Array', proto: true, forced: !STRICT_METHOD || !USES_TO_LENGTH }, {\n reduce: function reduce(callbackfn /* , initialValue */) {\n return $reduce(this, callbackfn, arguments.length, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"14c3\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar classof = __webpack_require__(\"c6b6\");\nvar regexpExec = __webpack_require__(\"9263\");\n\n// `RegExpExec` abstract operation\n// https://tc39.github.io/ecma262/#sec-regexpexec\nmodule.exports = function (R, S) {\n var exec = R.exec;\n if (typeof exec === 'function') {\n var result = exec.call(R, S);\n if (typeof result !== 'object') {\n throw TypeError('RegExp exec method returned something other than an Object or null');\n }\n return result;\n }\n\n if (classof(R) !== 'RegExp') {\n throw TypeError('RegExp#exec called on incompatible receiver');\n }\n\n return regexpExec.call(R, S);\n};\n\n\n\n/***/ }),\n\n/***/ \"159b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar DOMIterables = __webpack_require__(\"fdbc\");\nvar forEach = __webpack_require__(\"17c2\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\n\nfor (var COLLECTION_NAME in DOMIterables) {\n var Collection = global[COLLECTION_NAME];\n var CollectionPrototype = Collection && Collection.prototype;\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype && CollectionPrototype.forEach !== forEach) try {\n createNonEnumerableProperty(CollectionPrototype, 'forEach', forEach);\n } catch (error) {\n CollectionPrototype.forEach = forEach;\n }\n}\n\n\n/***/ }),\n\n/***/ \"17c2\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $forEach = __webpack_require__(\"b727\").forEach;\nvar arrayMethodIsStrict = __webpack_require__(\"a640\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar STRICT_METHOD = arrayMethodIsStrict('forEach');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('forEach');\n\n// `Array.prototype.forEach` method implementation\n// https://tc39.github.io/ecma262/#sec-array.prototype.foreach\nmodule.exports = (!STRICT_METHOD || !USES_TO_LENGTH) ? function forEach(callbackfn /* , thisArg */) {\n return $forEach(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n} : [].forEach;\n\n\n/***/ }),\n\n/***/ \"1be4\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar getBuiltIn = __webpack_require__(\"d066\");\n\nmodule.exports = getBuiltIn('document', 'documentElement');\n\n\n/***/ }),\n\n/***/ \"1c0b\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (it) {\n if (typeof it != 'function') {\n throw TypeError(String(it) + ' is not a function');\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"1c7e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar SAFE_CLOSING = false;\n\ntry {\n var called = 0;\n var iteratorWithReturn = {\n next: function () {\n return { done: !!called++ };\n },\n 'return': function () {\n SAFE_CLOSING = true;\n }\n };\n iteratorWithReturn[ITERATOR] = function () {\n return this;\n };\n // eslint-disable-next-line no-throw-literal\n Array.from(iteratorWithReturn, function () { throw 2; });\n} catch (error) { /* empty */ }\n\nmodule.exports = function (exec, SKIP_CLOSING) {\n if (!SKIP_CLOSING && !SAFE_CLOSING) return false;\n var ITERATION_SUPPORT = false;\n try {\n var object = {};\n object[ITERATOR] = function () {\n return {\n next: function () {\n return { done: ITERATION_SUPPORT = true };\n }\n };\n };\n exec(object);\n } catch (error) { /* empty */ }\n return ITERATION_SUPPORT;\n};\n\n\n/***/ }),\n\n/***/ \"1d80\":\n/***/ (function(module, exports) {\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.github.io/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (it == undefined) throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n\n\n/***/ }),\n\n/***/ \"1dde\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar V8_VERSION = __webpack_require__(\"2d00\");\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (METHOD_NAME) {\n // We can't use this feature detection in V8 since it causes\n // deoptimization and serious performance degradation\n // https://github.com/zloirock/core-js/issues/677\n return V8_VERSION >= 51 || !fails(function () {\n var array = [];\n var constructor = array.constructor = {};\n constructor[SPECIES] = function () {\n return { foo: 1 };\n };\n return array[METHOD_NAME](Boolean).foo !== 1;\n });\n};\n\n\n/***/ }),\n\n/***/ \"23cb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toInteger = __webpack_require__(\"a691\");\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toInteger(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n\n\n/***/ }),\n\n/***/ \"23e7\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar getOwnPropertyDescriptor = __webpack_require__(\"06cf\").f;\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar setGlobal = __webpack_require__(\"ce4e\");\nvar copyConstructorProperties = __webpack_require__(\"e893\");\nvar isForced = __webpack_require__(\"94ca\");\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.noTargetGet - prevent calling a getter on target\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var FORCED, target, key, targetProperty, sourceProperty, descriptor;\n if (GLOBAL) {\n target = global;\n } else if (STATIC) {\n target = global[TARGET] || setGlobal(TARGET, {});\n } else {\n target = (global[TARGET] || {}).prototype;\n }\n if (target) for (key in source) {\n sourceProperty = source[key];\n if (options.noTargetGet) {\n descriptor = getOwnPropertyDescriptor(target, key);\n targetProperty = descriptor && descriptor.value;\n } else targetProperty = target[key];\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contained in target\n if (!FORCED && targetProperty !== undefined) {\n if (typeof sourceProperty === typeof targetProperty) continue;\n copyConstructorProperties(sourceProperty, targetProperty);\n }\n // add a flag to not completely full polyfills\n if (options.sham || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(sourceProperty, 'sham', true);\n }\n // extend global\n redefine(target, key, sourceProperty, options);\n }\n};\n\n\n/***/ }),\n\n/***/ \"241c\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar internalObjectKeys = __webpack_require__(\"ca84\");\nvar enumBugKeys = __webpack_require__(\"7839\");\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertynames\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n\n\n/***/ }),\n\n/***/ \"25f0\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar redefine = __webpack_require__(\"6eeb\");\nvar anObject = __webpack_require__(\"825a\");\nvar fails = __webpack_require__(\"d039\");\nvar flags = __webpack_require__(\"ad6d\");\n\nvar TO_STRING = 'toString';\nvar RegExpPrototype = RegExp.prototype;\nvar nativeToString = RegExpPrototype[TO_STRING];\n\nvar NOT_GENERIC = fails(function () { return nativeToString.call({ source: 'a', flags: 'b' }) != '/a/b'; });\n// FF44- RegExp#toString has a wrong name\nvar INCORRECT_NAME = nativeToString.name != TO_STRING;\n\n// `RegExp.prototype.toString` method\n// https://tc39.github.io/ecma262/#sec-regexp.prototype.tostring\nif (NOT_GENERIC || INCORRECT_NAME) {\n redefine(RegExp.prototype, TO_STRING, function toString() {\n var R = anObject(this);\n var p = String(R.source);\n var rf = R.flags;\n var f = String(rf === undefined && R instanceof RegExp && !('flags' in RegExpPrototype) ? flags.call(R) : rf);\n return '/' + p + '/' + f;\n }, { unsafe: true });\n}\n\n\n/***/ }),\n\n/***/ \"2ca0\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar getOwnPropertyDescriptor = __webpack_require__(\"06cf\").f;\nvar toLength = __webpack_require__(\"50c4\");\nvar notARegExp = __webpack_require__(\"5a34\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\nvar correctIsRegExpLogic = __webpack_require__(\"ab13\");\nvar IS_PURE = __webpack_require__(\"c430\");\n\nvar nativeStartsWith = ''.startsWith;\nvar min = Math.min;\n\nvar CORRECT_IS_REGEXP_LOGIC = correctIsRegExpLogic('startsWith');\n// https://github.com/zloirock/core-js/pull/702\nvar MDN_POLYFILL_BUG = !IS_PURE && !CORRECT_IS_REGEXP_LOGIC && !!function () {\n var descriptor = getOwnPropertyDescriptor(String.prototype, 'startsWith');\n return descriptor && !descriptor.writable;\n}();\n\n// `String.prototype.startsWith` method\n// https://tc39.github.io/ecma262/#sec-string.prototype.startswith\n$({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_REGEXP_LOGIC }, {\n startsWith: function startsWith(searchString /* , position = 0 */) {\n var that = String(requireObjectCoercible(this));\n notARegExp(searchString);\n var index = toLength(min(arguments.length > 1 ? arguments[1] : undefined, that.length));\n var search = String(searchString);\n return nativeStartsWith\n ? nativeStartsWith.call(that, search, index)\n : that.slice(index, index + search.length) === search;\n }\n});\n\n\n/***/ }),\n\n/***/ \"2d00\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar userAgent = __webpack_require__(\"342f\");\n\nvar process = global.process;\nvar versions = process && process.versions;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n version = match[0] + match[1];\n} else if (userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = match[1];\n }\n}\n\nmodule.exports = version && +version;\n\n\n/***/ }),\n\n/***/ \"342f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar getBuiltIn = __webpack_require__(\"d066\");\n\nmodule.exports = getBuiltIn('navigator', 'userAgent') || '';\n\n\n/***/ }),\n\n/***/ \"35a1\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar classof = __webpack_require__(\"f5df\");\nvar Iterators = __webpack_require__(\"3f8c\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\n\nmodule.exports = function (it) {\n if (it != undefined) return it[ITERATOR]\n || it['@@iterator']\n || Iterators[classof(it)];\n};\n\n\n/***/ }),\n\n/***/ \"37e8\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar anObject = __webpack_require__(\"825a\");\nvar objectKeys = __webpack_require__(\"df75\");\n\n// `Object.defineProperties` method\n// https://tc39.github.io/ecma262/#sec-object.defineproperties\nmodule.exports = DESCRIPTORS ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n while (length > index) definePropertyModule.f(O, key = keys[index++], Properties[key]);\n return O;\n};\n\n\n/***/ }),\n\n/***/ \"3bbe\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\n\nmodule.exports = function (it) {\n if (!isObject(it) && it !== null) {\n throw TypeError(\"Can't set \" + String(it) + ' as a prototype');\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"3ca3\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar charAt = __webpack_require__(\"6547\").charAt;\nvar InternalStateModule = __webpack_require__(\"69f3\");\nvar defineIterator = __webpack_require__(\"7dd0\");\n\nvar STRING_ITERATOR = 'String Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);\n\n// `String.prototype[@@iterator]` method\n// https://tc39.github.io/ecma262/#sec-string.prototype-@@iterator\ndefineIterator(String, 'String', function (iterated) {\n setInternalState(this, {\n type: STRING_ITERATOR,\n string: String(iterated),\n index: 0\n });\n// `%StringIteratorPrototype%.next` method\n// https://tc39.github.io/ecma262/#sec-%stringiteratorprototype%.next\n}, function next() {\n var state = getInternalState(this);\n var string = state.string;\n var index = state.index;\n var point;\n if (index >= string.length) return { value: undefined, done: true };\n point = charAt(string, index);\n state.index += point.length;\n return { value: point, done: false };\n});\n\n\n/***/ }),\n\n/***/ \"3f8c\":\n/***/ (function(module, exports) {\n\nmodule.exports = {};\n\n\n/***/ }),\n\n/***/ \"4160\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar forEach = __webpack_require__(\"17c2\");\n\n// `Array.prototype.forEach` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.foreach\n$({ target: 'Array', proto: true, forced: [].forEach != forEach }, {\n forEach: forEach\n});\n\n\n/***/ }),\n\n/***/ \"428f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\n\nmodule.exports = global;\n\n\n/***/ }),\n\n/***/ \"44ad\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\nvar classof = __webpack_require__(\"c6b6\");\n\nvar split = ''.split;\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins\n return !Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) == 'String' ? split.call(it, '') : Object(it);\n} : Object;\n\n\n/***/ }),\n\n/***/ \"44d2\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar create = __webpack_require__(\"7c73\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\n\nvar UNSCOPABLES = wellKnownSymbol('unscopables');\nvar ArrayPrototype = Array.prototype;\n\n// Array.prototype[@@unscopables]\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\nif (ArrayPrototype[UNSCOPABLES] == undefined) {\n definePropertyModule.f(ArrayPrototype, UNSCOPABLES, {\n configurable: true,\n value: create(null)\n });\n}\n\n// add a key to Array.prototype[@@unscopables]\nmodule.exports = function (key) {\n ArrayPrototype[UNSCOPABLES][key] = true;\n};\n\n\n/***/ }),\n\n/***/ \"44e7\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\nvar classof = __webpack_require__(\"c6b6\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar MATCH = wellKnownSymbol('match');\n\n// `IsRegExp` abstract operation\n// https://tc39.github.io/ecma262/#sec-isregexp\nmodule.exports = function (it) {\n var isRegExp;\n return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classof(it) == 'RegExp');\n};\n\n\n/***/ }),\n\n/***/ \"4930\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n // Chrome 38 Symbol has incorrect toString conversion\n // eslint-disable-next-line no-undef\n return !String(Symbol());\n});\n\n\n/***/ }),\n\n/***/ \"4d64\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toAbsoluteIndex = __webpack_require__(\"23cb\");\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = toLength(O.length);\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare\n if (IS_INCLUDES && el != el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare\n if (value != value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n\n\n/***/ }),\n\n/***/ \"4de4\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $filter = __webpack_require__(\"b727\").filter;\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('filter');\n// Edge 14- issue\nvar USES_TO_LENGTH = arrayMethodUsesToLength('filter');\n\n// `Array.prototype.filter` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.filter\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n filter: function filter(callbackfn /* , thisArg */) {\n return $filter(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"4df4\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar bind = __webpack_require__(\"0366\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar callWithSafeIterationClosing = __webpack_require__(\"9bdd\");\nvar isArrayIteratorMethod = __webpack_require__(\"e95a\");\nvar toLength = __webpack_require__(\"50c4\");\nvar createProperty = __webpack_require__(\"8418\");\nvar getIteratorMethod = __webpack_require__(\"35a1\");\n\n// `Array.from` method implementation\n// https://tc39.github.io/ecma262/#sec-array.from\nmodule.exports = function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {\n var O = toObject(arrayLike);\n var C = typeof this == 'function' ? this : Array;\n var argumentsLength = arguments.length;\n var mapfn = argumentsLength > 1 ? arguments[1] : undefined;\n var mapping = mapfn !== undefined;\n var iteratorMethod = getIteratorMethod(O);\n var index = 0;\n var length, result, step, iterator, next, value;\n if (mapping) mapfn = bind(mapfn, argumentsLength > 2 ? arguments[2] : undefined, 2);\n // if the target is not iterable or it's an array with the default iterator - use a simple case\n if (iteratorMethod != undefined && !(C == Array && isArrayIteratorMethod(iteratorMethod))) {\n iterator = iteratorMethod.call(O);\n next = iterator.next;\n result = new C();\n for (;!(step = next.call(iterator)).done; index++) {\n value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value;\n createProperty(result, index, value);\n }\n } else {\n length = toLength(O.length);\n result = new C(length);\n for (;length > index; index++) {\n value = mapping ? mapfn(O[index], index) : O[index];\n createProperty(result, index, value);\n }\n }\n result.length = index;\n return result;\n};\n\n\n/***/ }),\n\n/***/ \"4fad\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar $entries = __webpack_require__(\"6f53\").entries;\n\n// `Object.entries` method\n// https://tc39.github.io/ecma262/#sec-object.entries\n$({ target: 'Object', stat: true }, {\n entries: function entries(O) {\n return $entries(O);\n }\n});\n\n\n/***/ }),\n\n/***/ \"50c4\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toInteger = __webpack_require__(\"a691\");\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.github.io/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n return argument > 0 ? min(toInteger(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n\n\n/***/ }),\n\n/***/ \"5135\":\n/***/ (function(module, exports) {\n\nvar hasOwnProperty = {}.hasOwnProperty;\n\nmodule.exports = function (it, key) {\n return hasOwnProperty.call(it, key);\n};\n\n\n/***/ }),\n\n/***/ \"5319\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar fixRegExpWellKnownSymbolLogic = __webpack_require__(\"d784\");\nvar anObject = __webpack_require__(\"825a\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toInteger = __webpack_require__(\"a691\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\nvar advanceStringIndex = __webpack_require__(\"8aa5\");\nvar regExpExec = __webpack_require__(\"14c3\");\n\nvar max = Math.max;\nvar min = Math.min;\nvar floor = Math.floor;\nvar SUBSTITUTION_SYMBOLS = /\\$([$&'`]|\\d\\d?|<[^>]*>)/g;\nvar SUBSTITUTION_SYMBOLS_NO_NAMED = /\\$([$&'`]|\\d\\d?)/g;\n\nvar maybeToString = function (it) {\n return it === undefined ? it : String(it);\n};\n\n// @@replace logic\nfixRegExpWellKnownSymbolLogic('replace', 2, function (REPLACE, nativeReplace, maybeCallNative, reason) {\n var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = reason.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE;\n var REPLACE_KEEPS_$0 = reason.REPLACE_KEEPS_$0;\n var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';\n\n return [\n // `String.prototype.replace` method\n // https://tc39.github.io/ecma262/#sec-string.prototype.replace\n function replace(searchValue, replaceValue) {\n var O = requireObjectCoercible(this);\n var replacer = searchValue == undefined ? undefined : searchValue[REPLACE];\n return replacer !== undefined\n ? replacer.call(searchValue, O, replaceValue)\n : nativeReplace.call(String(O), searchValue, replaceValue);\n },\n // `RegExp.prototype[@@replace]` method\n // https://tc39.github.io/ecma262/#sec-regexp.prototype-@@replace\n function (regexp, replaceValue) {\n if (\n (!REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE && REPLACE_KEEPS_$0) ||\n (typeof replaceValue === 'string' && replaceValue.indexOf(UNSAFE_SUBSTITUTE) === -1)\n ) {\n var res = maybeCallNative(nativeReplace, regexp, this, replaceValue);\n if (res.done) return res.value;\n }\n\n var rx = anObject(regexp);\n var S = String(this);\n\n var functionalReplace = typeof replaceValue === 'function';\n if (!functionalReplace) replaceValue = String(replaceValue);\n\n var global = rx.global;\n if (global) {\n var fullUnicode = rx.unicode;\n rx.lastIndex = 0;\n }\n var results = [];\n while (true) {\n var result = regExpExec(rx, S);\n if (result === null) break;\n\n results.push(result);\n if (!global) break;\n\n var matchStr = String(result[0]);\n if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);\n }\n\n var accumulatedResult = '';\n var nextSourcePosition = 0;\n for (var i = 0; i < results.length; i++) {\n result = results[i];\n\n var matched = String(result[0]);\n var position = max(min(toInteger(result.index), S.length), 0);\n var captures = [];\n // NOTE: This is equivalent to\n // captures = result.slice(1).map(maybeToString)\n // but for some reason `nativeSlice.call(result, 1, result.length)` (called in\n // the slice polyfill when slicing native arrays) \"doesn't work\" in safari 9 and\n // causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.\n for (var j = 1; j < result.length; j++) captures.push(maybeToString(result[j]));\n var namedCaptures = result.groups;\n if (functionalReplace) {\n var replacerArgs = [matched].concat(captures, position, S);\n if (namedCaptures !== undefined) replacerArgs.push(namedCaptures);\n var replacement = String(replaceValue.apply(undefined, replacerArgs));\n } else {\n replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);\n }\n if (position >= nextSourcePosition) {\n accumulatedResult += S.slice(nextSourcePosition, position) + replacement;\n nextSourcePosition = position + matched.length;\n }\n }\n return accumulatedResult + S.slice(nextSourcePosition);\n }\n ];\n\n // https://tc39.github.io/ecma262/#sec-getsubstitution\n function getSubstitution(matched, str, position, captures, namedCaptures, replacement) {\n var tailPos = position + matched.length;\n var m = captures.length;\n var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;\n if (namedCaptures !== undefined) {\n namedCaptures = toObject(namedCaptures);\n symbols = SUBSTITUTION_SYMBOLS;\n }\n return nativeReplace.call(replacement, symbols, function (match, ch) {\n var capture;\n switch (ch.charAt(0)) {\n case '$': return '$';\n case '&': return matched;\n case '`': return str.slice(0, position);\n case \"'\": return str.slice(tailPos);\n case '<':\n capture = namedCaptures[ch.slice(1, -1)];\n break;\n default: // \\d\\d?\n var n = +ch;\n if (n === 0) return match;\n if (n > m) {\n var f = floor(n / 10);\n if (f === 0) return match;\n if (f <= m) return captures[f - 1] === undefined ? ch.charAt(1) : captures[f - 1] + ch.charAt(1);\n return match;\n }\n capture = captures[n - 1];\n }\n return capture === undefined ? '' : capture;\n });\n }\n});\n\n\n/***/ }),\n\n/***/ \"5692\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar IS_PURE = __webpack_require__(\"c430\");\nvar store = __webpack_require__(\"c6cd\");\n\n(module.exports = function (key, value) {\n return store[key] || (store[key] = value !== undefined ? value : {});\n})('versions', []).push({\n version: '3.6.5',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2020 Denis Pushkarev (zloirock.ru)'\n});\n\n\n/***/ }),\n\n/***/ \"56ef\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar getBuiltIn = __webpack_require__(\"d066\");\nvar getOwnPropertyNamesModule = __webpack_require__(\"241c\");\nvar getOwnPropertySymbolsModule = __webpack_require__(\"7418\");\nvar anObject = __webpack_require__(\"825a\");\n\n// all object keys, includes non-enumerable and symbols\nmodule.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {\n var keys = getOwnPropertyNamesModule.f(anObject(it));\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return getOwnPropertySymbols ? keys.concat(getOwnPropertySymbols(it)) : keys;\n};\n\n\n/***/ }),\n\n/***/ \"5a34\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isRegExp = __webpack_require__(\"44e7\");\n\nmodule.exports = function (it) {\n if (isRegExp(it)) {\n throw TypeError(\"The method doesn't accept regular expressions\");\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"5c6c\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n\n\n/***/ }),\n\n/***/ \"5db7\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar flattenIntoArray = __webpack_require__(\"a2bf\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar aFunction = __webpack_require__(\"1c0b\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\n\n// `Array.prototype.flatMap` method\n// https://github.com/tc39/proposal-flatMap\n$({ target: 'Array', proto: true }, {\n flatMap: function flatMap(callbackfn /* , thisArg */) {\n var O = toObject(this);\n var sourceLen = toLength(O.length);\n var A;\n aFunction(callbackfn);\n A = arraySpeciesCreate(O, 0);\n A.length = flattenIntoArray(A, O, O, sourceLen, 0, 1, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n return A;\n }\n});\n\n\n/***/ }),\n\n/***/ \"6547\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar toInteger = __webpack_require__(\"a691\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\n\n// `String.prototype.{ codePointAt, at }` methods implementation\nvar createMethod = function (CONVERT_TO_STRING) {\n return function ($this, pos) {\n var S = String(requireObjectCoercible($this));\n var position = toInteger(pos);\n var size = S.length;\n var first, second;\n if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;\n first = S.charCodeAt(position);\n return first < 0xD800 || first > 0xDBFF || position + 1 === size\n || (second = S.charCodeAt(position + 1)) < 0xDC00 || second > 0xDFFF\n ? CONVERT_TO_STRING ? S.charAt(position) : first\n : CONVERT_TO_STRING ? S.slice(position, position + 2) : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;\n };\n};\n\nmodule.exports = {\n // `String.prototype.codePointAt` method\n // https://tc39.github.io/ecma262/#sec-string.prototype.codepointat\n codeAt: createMethod(false),\n // `String.prototype.at` method\n // https://github.com/mathiasbynens/String.prototype.at\n charAt: createMethod(true)\n};\n\n\n/***/ }),\n\n/***/ \"65f0\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar SPECIES = wellKnownSymbol('species');\n\n// `ArraySpeciesCreate` abstract operation\n// https://tc39.github.io/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray, length) {\n var C;\n if (isArray(originalArray)) {\n C = originalArray.constructor;\n // cross-realm fallback\n if (typeof C == 'function' && (C === Array || isArray(C.prototype))) C = undefined;\n else if (isObject(C)) {\n C = C[SPECIES];\n if (C === null) C = undefined;\n }\n } return new (C === undefined ? Array : C)(length === 0 ? 0 : length);\n};\n\n\n/***/ }),\n\n/***/ \"69f3\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar NATIVE_WEAK_MAP = __webpack_require__(\"7f9a\");\nvar global = __webpack_require__(\"da84\");\nvar isObject = __webpack_require__(\"861d\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar objectHas = __webpack_require__(\"5135\");\nvar sharedKey = __webpack_require__(\"f772\");\nvar hiddenKeys = __webpack_require__(\"d012\");\n\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP) {\n var store = new WeakMap();\n var wmget = store.get;\n var wmhas = store.has;\n var wmset = store.set;\n set = function (it, metadata) {\n wmset.call(store, it, metadata);\n return metadata;\n };\n get = function (it) {\n return wmget.call(store, it) || {};\n };\n has = function (it) {\n return wmhas.call(store, it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return objectHas(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return objectHas(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n\n\n/***/ }),\n\n/***/ \"6eeb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar has = __webpack_require__(\"5135\");\nvar setGlobal = __webpack_require__(\"ce4e\");\nvar inspectSource = __webpack_require__(\"8925\");\nvar InternalStateModule = __webpack_require__(\"69f3\");\n\nvar getInternalState = InternalStateModule.get;\nvar enforceInternalState = InternalStateModule.enforce;\nvar TEMPLATE = String(String).split('String');\n\n(module.exports = function (O, key, value, options) {\n var unsafe = options ? !!options.unsafe : false;\n var simple = options ? !!options.enumerable : false;\n var noTargetGet = options ? !!options.noTargetGet : false;\n if (typeof value == 'function') {\n if (typeof key == 'string' && !has(value, 'name')) createNonEnumerableProperty(value, 'name', key);\n enforceInternalState(value).source = TEMPLATE.join(typeof key == 'string' ? key : '');\n }\n if (O === global) {\n if (simple) O[key] = value;\n else setGlobal(key, value);\n return;\n } else if (!unsafe) {\n delete O[key];\n } else if (!noTargetGet && O[key]) {\n simple = true;\n }\n if (simple) O[key] = value;\n else createNonEnumerableProperty(O, key, value);\n// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n})(Function.prototype, 'toString', function toString() {\n return typeof this == 'function' && getInternalState(this).source || inspectSource(this);\n});\n\n\n/***/ }),\n\n/***/ \"6f53\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar objectKeys = __webpack_require__(\"df75\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar propertyIsEnumerable = __webpack_require__(\"d1e7\").f;\n\n// `Object.{ entries, values }` methods implementation\nvar createMethod = function (TO_ENTRIES) {\n return function (it) {\n var O = toIndexedObject(it);\n var keys = objectKeys(O);\n var length = keys.length;\n var i = 0;\n var result = [];\n var key;\n while (length > i) {\n key = keys[i++];\n if (!DESCRIPTORS || propertyIsEnumerable.call(O, key)) {\n result.push(TO_ENTRIES ? [key, O[key]] : O[key]);\n }\n }\n return result;\n };\n};\n\nmodule.exports = {\n // `Object.entries` method\n // https://tc39.github.io/ecma262/#sec-object.entries\n entries: createMethod(true),\n // `Object.values` method\n // https://tc39.github.io/ecma262/#sec-object.values\n values: createMethod(false)\n};\n\n\n/***/ }),\n\n/***/ \"73d9\":\n/***/ (function(module, exports, __webpack_require__) {\n\n// this method was added to unscopables after implementation\n// in popular engines, so it's moved to a separate module\nvar addToUnscopables = __webpack_require__(\"44d2\");\n\naddToUnscopables('flatMap');\n\n\n/***/ }),\n\n/***/ \"7418\":\n/***/ (function(module, exports) {\n\nexports.f = Object.getOwnPropertySymbols;\n\n\n/***/ }),\n\n/***/ \"746f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar path = __webpack_require__(\"428f\");\nvar has = __webpack_require__(\"5135\");\nvar wrappedWellKnownSymbolModule = __webpack_require__(\"e538\");\nvar defineProperty = __webpack_require__(\"9bf2\").f;\n\nmodule.exports = function (NAME) {\n var Symbol = path.Symbol || (path.Symbol = {});\n if (!has(Symbol, NAME)) defineProperty(Symbol, NAME, {\n value: wrappedWellKnownSymbolModule.f(NAME)\n });\n};\n\n\n/***/ }),\n\n/***/ \"7839\":\n/***/ (function(module, exports) {\n\n// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n\n\n/***/ }),\n\n/***/ \"7b0b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\n\n// `ToObject` abstract operation\n// https://tc39.github.io/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return Object(requireObjectCoercible(argument));\n};\n\n\n/***/ }),\n\n/***/ \"7c73\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar anObject = __webpack_require__(\"825a\");\nvar defineProperties = __webpack_require__(\"37e8\");\nvar enumBugKeys = __webpack_require__(\"7839\");\nvar hiddenKeys = __webpack_require__(\"d012\");\nvar html = __webpack_require__(\"1be4\");\nvar documentCreateElement = __webpack_require__(\"cc12\");\nvar sharedKey = __webpack_require__(\"f772\");\n\nvar GT = '>';\nvar LT = '<';\nvar PROTOTYPE = 'prototype';\nvar SCRIPT = 'script';\nvar IE_PROTO = sharedKey('IE_PROTO');\n\nvar EmptyConstructor = function () { /* empty */ };\n\nvar scriptTag = function (content) {\n return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;\n};\n\n// Create object with fake `null` prototype: use ActiveX Object with cleared prototype\nvar NullProtoObjectViaActiveX = function (activeXDocument) {\n activeXDocument.write(scriptTag(''));\n activeXDocument.close();\n var temp = activeXDocument.parentWindow.Object;\n activeXDocument = null; // avoid memory leak\n return temp;\n};\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar NullProtoObjectViaIFrame = function () {\n // Thrash, waste and sodomy: IE GC bug\n var iframe = documentCreateElement('iframe');\n var JS = 'java' + SCRIPT + ':';\n var iframeDocument;\n iframe.style.display = 'none';\n html.appendChild(iframe);\n // https://github.com/zloirock/core-js/issues/475\n iframe.src = String(JS);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(scriptTag('document.F=Object'));\n iframeDocument.close();\n return iframeDocument.F;\n};\n\n// Check for document.domain and active x support\n// No need to use active x approach when document.domain is not set\n// see https://github.com/es-shims/es5-shim/issues/150\n// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346\n// avoid IE GC bug\nvar activeXDocument;\nvar NullProtoObject = function () {\n try {\n /* global ActiveXObject */\n activeXDocument = document.domain && new ActiveXObject('htmlfile');\n } catch (error) { /* ignore */ }\n NullProtoObject = activeXDocument ? NullProtoObjectViaActiveX(activeXDocument) : NullProtoObjectViaIFrame();\n var length = enumBugKeys.length;\n while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];\n return NullProtoObject();\n};\n\nhiddenKeys[IE_PROTO] = true;\n\n// `Object.create` method\n// https://tc39.github.io/ecma262/#sec-object.create\nmodule.exports = Object.create || function create(O, Properties) {\n var result;\n if (O !== null) {\n EmptyConstructor[PROTOTYPE] = anObject(O);\n result = new EmptyConstructor();\n EmptyConstructor[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = NullProtoObject();\n return Properties === undefined ? result : defineProperties(result, Properties);\n};\n\n\n/***/ }),\n\n/***/ \"7dd0\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar createIteratorConstructor = __webpack_require__(\"9ed3\");\nvar getPrototypeOf = __webpack_require__(\"e163\");\nvar setPrototypeOf = __webpack_require__(\"d2bb\");\nvar setToStringTag = __webpack_require__(\"d44e\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar IS_PURE = __webpack_require__(\"c430\");\nvar Iterators = __webpack_require__(\"3f8c\");\nvar IteratorsCore = __webpack_require__(\"ae93\");\n\nvar IteratorPrototype = IteratorsCore.IteratorPrototype;\nvar BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;\nvar ITERATOR = wellKnownSymbol('iterator');\nvar KEYS = 'keys';\nvar VALUES = 'values';\nvar ENTRIES = 'entries';\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {\n createIteratorConstructor(IteratorConstructor, NAME, next);\n\n var getIterationMethod = function (KIND) {\n if (KIND === DEFAULT && defaultIterator) return defaultIterator;\n if (!BUGGY_SAFARI_ITERATORS && KIND in IterablePrototype) return IterablePrototype[KIND];\n switch (KIND) {\n case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };\n case VALUES: return function values() { return new IteratorConstructor(this, KIND); };\n case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };\n } return function () { return new IteratorConstructor(this); };\n };\n\n var TO_STRING_TAG = NAME + ' Iterator';\n var INCORRECT_VALUES_NAME = false;\n var IterablePrototype = Iterable.prototype;\n var nativeIterator = IterablePrototype[ITERATOR]\n || IterablePrototype['@@iterator']\n || DEFAULT && IterablePrototype[DEFAULT];\n var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);\n var anyNativeIterator = NAME == 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;\n var CurrentIteratorPrototype, methods, KEY;\n\n // fix native\n if (anyNativeIterator) {\n CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));\n if (IteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {\n if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {\n if (setPrototypeOf) {\n setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);\n } else if (typeof CurrentIteratorPrototype[ITERATOR] != 'function') {\n createNonEnumerableProperty(CurrentIteratorPrototype, ITERATOR, returnThis);\n }\n }\n // Set @@toStringTag to native iterators\n setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);\n if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;\n }\n }\n\n // fix Array#{values, @@iterator}.name in V8 / FF\n if (DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) {\n INCORRECT_VALUES_NAME = true;\n defaultIterator = function values() { return nativeIterator.call(this); };\n }\n\n // define iterator\n if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {\n createNonEnumerableProperty(IterablePrototype, ITERATOR, defaultIterator);\n }\n Iterators[NAME] = defaultIterator;\n\n // export additional methods\n if (DEFAULT) {\n methods = {\n values: getIterationMethod(VALUES),\n keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),\n entries: getIterationMethod(ENTRIES)\n };\n if (FORCED) for (KEY in methods) {\n if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {\n redefine(IterablePrototype, KEY, methods[KEY]);\n }\n } else $({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);\n }\n\n return methods;\n};\n\n\n/***/ }),\n\n/***/ \"7f9a\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar inspectSource = __webpack_require__(\"8925\");\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = typeof WeakMap === 'function' && /native code/.test(inspectSource(WeakMap));\n\n\n/***/ }),\n\n/***/ \"825a\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\n\nmodule.exports = function (it) {\n if (!isObject(it)) {\n throw TypeError(String(it) + ' is not an object');\n } return it;\n};\n\n\n/***/ }),\n\n/***/ \"83ab\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !fails(function () {\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;\n});\n\n\n/***/ }),\n\n/***/ \"8418\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar toPrimitive = __webpack_require__(\"c04e\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\n\nmodule.exports = function (object, key, value) {\n var propertyKey = toPrimitive(key);\n if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));\n else object[propertyKey] = value;\n};\n\n\n/***/ }),\n\n/***/ \"861d\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (it) {\n return typeof it === 'object' ? it !== null : typeof it === 'function';\n};\n\n\n/***/ }),\n\n/***/ \"8875\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (true) {\n !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),\n\t\t\t\t__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?\n\t\t\t\t(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),\n\t\t\t\t__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));\n } else {}\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n var descriptor = Object.getOwnPropertyDescriptor(document, 'currentScript')\n // for chrome\n if (!descriptor && 'currentScript' in document && document.currentScript) {\n return document.currentScript\n }\n\n // for other browsers with native support for currentScript\n if (descriptor && descriptor.get !== getCurrentScript && document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*<script>([\\\\d\\\\D]*?)<\\\\/script>[\\\\d\\\\D]*', 'i');\n inlineScriptSource = pageSource.replace(inlineScriptSourceRegExp, '$1').trim();\n }\n \n for (var i = 0; i < scripts.length; i++) {\n // If ready state is interactive, return the script tag\n if (scripts[i].readyState === 'interactive') {\n return scripts[i];\n }\n \n // If src matches, return the script tag\n if (scripts[i].src === scriptLocation) {\n return scripts[i];\n }\n \n // If inline source matches, return the script tag\n if (\n scriptLocation === currentLocation &&\n scripts[i].innerHTML &&\n scripts[i].innerHTML.trim() === inlineScriptSource\n ) {\n return scripts[i];\n }\n }\n \n // If no match, return null\n return null;\n }\n };\n\n return getCurrentScript\n}));\n\n\n/***/ }),\n\n/***/ \"8925\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar store = __webpack_require__(\"c6cd\");\n\nvar functionToString = Function.toString;\n\n// this helper broken in `3.4.1-3.4.4`, so we can't use `shared` helper\nif (typeof store.inspectSource != 'function') {\n store.inspectSource = function (it) {\n return functionToString.call(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n\n\n/***/ }),\n\n/***/ \"8aa5\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar charAt = __webpack_require__(\"6547\").charAt;\n\n// `AdvanceStringIndex` abstract operation\n// https://tc39.github.io/ecma262/#sec-advancestringindex\nmodule.exports = function (S, index, unicode) {\n return index + (unicode ? charAt(S, index).length : 1);\n};\n\n\n/***/ }),\n\n/***/ \"8bbf\":\n/***/ (function(module, exports) {\n\nmodule.exports = __WEBPACK_EXTERNAL_MODULE__8bbf__;\n\n/***/ }),\n\n/***/ \"90e3\":\n/***/ (function(module, exports) {\n\nvar id = 0;\nvar postfix = Math.random();\n\nmodule.exports = function (key) {\n return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36);\n};\n\n\n/***/ }),\n\n/***/ \"9112\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n\n\n/***/ }),\n\n/***/ \"9263\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar regexpFlags = __webpack_require__(\"ad6d\");\nvar stickyHelpers = __webpack_require__(\"9f7f\");\n\nvar nativeExec = RegExp.prototype.exec;\n// This always refers to the native implementation, because the\n// String#replace polyfill uses ./fix-regexp-well-known-symbol-logic.js,\n// which loads this file before patching the method.\nvar nativeReplace = String.prototype.replace;\n\nvar patchedExec = nativeExec;\n\nvar UPDATES_LAST_INDEX_WRONG = (function () {\n var re1 = /a/;\n var re2 = /b*/g;\n nativeExec.call(re1, 'a');\n nativeExec.call(re2, 'a');\n return re1.lastIndex !== 0 || re2.lastIndex !== 0;\n})();\n\nvar UNSUPPORTED_Y = stickyHelpers.UNSUPPORTED_Y || stickyHelpers.BROKEN_CARET;\n\n// nonparticipating capturing group, copied from es5-shim's String#split patch.\nvar NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;\n\nvar PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y;\n\nif (PATCH) {\n patchedExec = function exec(str) {\n var re = this;\n var lastIndex, reCopy, match, i;\n var sticky = UNSUPPORTED_Y && re.sticky;\n var flags = regexpFlags.call(re);\n var source = re.source;\n var charsAdded = 0;\n var strCopy = str;\n\n if (sticky) {\n flags = flags.replace('y', '');\n if (flags.indexOf('g') === -1) {\n flags += 'g';\n }\n\n strCopy = String(str).slice(re.lastIndex);\n // Support anchored sticky behavior.\n if (re.lastIndex > 0 && (!re.multiline || re.multiline && str[re.lastIndex - 1] !== '\\n')) {\n source = '(?: ' + source + ')';\n strCopy = ' ' + strCopy;\n charsAdded++;\n }\n // ^(? + rx + ) is needed, in combination with some str slicing, to\n // simulate the 'y' flag.\n reCopy = new RegExp('^(?:' + source + ')', flags);\n }\n\n if (NPCG_INCLUDED) {\n reCopy = new RegExp('^' + source + '$(?!\\\\s)', flags);\n }\n if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;\n\n match = nativeExec.call(sticky ? reCopy : re, strCopy);\n\n if (sticky) {\n if (match) {\n match.input = match.input.slice(charsAdded);\n match[0] = match[0].slice(charsAdded);\n match.index = re.lastIndex;\n re.lastIndex += match[0].length;\n } else re.lastIndex = 0;\n } else if (UPDATES_LAST_INDEX_WRONG && match) {\n re.lastIndex = re.global ? match.index + match[0].length : lastIndex;\n }\n if (NPCG_INCLUDED && match && match.length > 1) {\n // Fix browsers whose `exec` methods don't consistently return `undefined`\n // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/\n nativeReplace.call(match[0], reCopy, function () {\n for (i = 1; i < arguments.length - 2; i++) {\n if (arguments[i] === undefined) match[i] = undefined;\n }\n });\n }\n\n return match;\n };\n}\n\nmodule.exports = patchedExec;\n\n\n/***/ }),\n\n/***/ \"94ca\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value == POLYFILL ? true\n : value == NATIVE ? false\n : typeof detection == 'function' ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n\n\n/***/ }),\n\n/***/ \"99af\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar fails = __webpack_require__(\"d039\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar isObject = __webpack_require__(\"861d\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar createProperty = __webpack_require__(\"8418\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar V8_VERSION = __webpack_require__(\"2d00\");\n\nvar IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_INDEX_EXCEEDED = 'Maximum allowed index exceeded';\n\n// We can't use this feature detection in V8 since it causes\n// deoptimization and serious performance degradation\n// https://github.com/zloirock/core-js/issues/679\nvar IS_CONCAT_SPREADABLE_SUPPORT = V8_VERSION >= 51 || !fails(function () {\n var array = [];\n array[IS_CONCAT_SPREADABLE] = false;\n return array.concat()[0] !== array;\n});\n\nvar SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('concat');\n\nvar isConcatSpreadable = function (O) {\n if (!isObject(O)) return false;\n var spreadable = O[IS_CONCAT_SPREADABLE];\n return spreadable !== undefined ? !!spreadable : isArray(O);\n};\n\nvar FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !SPECIES_SUPPORT;\n\n// `Array.prototype.concat` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.concat\n// with adding support of @@isConcatSpreadable and @@species\n$({ target: 'Array', proto: true, forced: FORCED }, {\n concat: function concat(arg) { // eslint-disable-line no-unused-vars\n var O = toObject(this);\n var A = arraySpeciesCreate(O, 0);\n var n = 0;\n var i, k, length, len, E;\n for (i = -1, length = arguments.length; i < length; i++) {\n E = i === -1 ? O : arguments[i];\n if (isConcatSpreadable(E)) {\n len = toLength(E.length);\n if (n + len > MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);\n } else {\n if (n >= MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n createProperty(A, n++, E);\n }\n }\n A.length = n;\n return A;\n }\n});\n\n\n/***/ }),\n\n/***/ \"9bdd\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar anObject = __webpack_require__(\"825a\");\n\n// call something on iterator step with safe closing on error\nmodule.exports = function (iterator, fn, value, ENTRIES) {\n try {\n return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);\n // 7.4.6 IteratorClose(iterator, completion)\n } catch (error) {\n var returnMethod = iterator['return'];\n if (returnMethod !== undefined) anObject(returnMethod.call(iterator));\n throw error;\n }\n};\n\n\n/***/ }),\n\n/***/ \"9bf2\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar IE8_DOM_DEFINE = __webpack_require__(\"0cfb\");\nvar anObject = __webpack_require__(\"825a\");\nvar toPrimitive = __webpack_require__(\"c04e\");\n\nvar nativeDefineProperty = Object.defineProperty;\n\n// `Object.defineProperty` method\n// https://tc39.github.io/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? nativeDefineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPrimitive(P, true);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return nativeDefineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n\n\n/***/ }),\n\n/***/ \"9ed3\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar IteratorPrototype = __webpack_require__(\"ae93\").IteratorPrototype;\nvar create = __webpack_require__(\"7c73\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\nvar setToStringTag = __webpack_require__(\"d44e\");\nvar Iterators = __webpack_require__(\"3f8c\");\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (IteratorConstructor, NAME, next) {\n var TO_STRING_TAG = NAME + ' Iterator';\n IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(1, next) });\n setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);\n Iterators[TO_STRING_TAG] = returnThis;\n return IteratorConstructor;\n};\n\n\n/***/ }),\n\n/***/ \"9f7f\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nvar fails = __webpack_require__(\"d039\");\n\n// babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError,\n// so we use an intermediate function.\nfunction RE(s, f) {\n return RegExp(s, f);\n}\n\nexports.UNSUPPORTED_Y = fails(function () {\n // babel-minify transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError\n var re = RE('a', 'y');\n re.lastIndex = 2;\n return re.exec('abcd') != null;\n});\n\nexports.BROKEN_CARET = fails(function () {\n // https://bugzilla.mozilla.org/show_bug.cgi?id=773687\n var re = RE('^r', 'gy');\n re.lastIndex = 2;\n return re.exec('str') != null;\n});\n\n\n/***/ }),\n\n/***/ \"a2bf\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar isArray = __webpack_require__(\"e8b5\");\nvar toLength = __webpack_require__(\"50c4\");\nvar bind = __webpack_require__(\"0366\");\n\n// `FlattenIntoArray` abstract operation\n// https://tc39.github.io/proposal-flatMap/#sec-FlattenIntoArray\nvar flattenIntoArray = function (target, original, source, sourceLen, start, depth, mapper, thisArg) {\n var targetIndex = start;\n var sourceIndex = 0;\n var mapFn = mapper ? bind(mapper, thisArg, 3) : false;\n var element;\n\n while (sourceIndex < sourceLen) {\n if (sourceIndex in source) {\n element = mapFn ? mapFn(source[sourceIndex], sourceIndex, original) : source[sourceIndex];\n\n if (depth > 0 && isArray(element)) {\n targetIndex = flattenIntoArray(target, original, element, toLength(element.length), targetIndex, depth - 1) - 1;\n } else {\n if (targetIndex >= 0x1FFFFFFFFFFFFF) throw TypeError('Exceed the acceptable array length');\n target[targetIndex] = element;\n }\n\n targetIndex++;\n }\n sourceIndex++;\n }\n return targetIndex;\n};\n\nmodule.exports = flattenIntoArray;\n\n\n/***/ }),\n\n/***/ \"a352\":\n/***/ (function(module, exports) {\n\nmodule.exports = __WEBPACK_EXTERNAL_MODULE_a352__;\n\n/***/ }),\n\n/***/ \"a434\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar toAbsoluteIndex = __webpack_require__(\"23cb\");\nvar toInteger = __webpack_require__(\"a691\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\nvar createProperty = __webpack_require__(\"8418\");\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('splice');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('splice', { ACCESSORS: true, 0: 0, 1: 2 });\n\nvar max = Math.max;\nvar min = Math.min;\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_LENGTH_EXCEEDED = 'Maximum allowed length exceeded';\n\n// `Array.prototype.splice` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.splice\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n splice: function splice(start, deleteCount /* , ...items */) {\n var O = toObject(this);\n var len = toLength(O.length);\n var actualStart = toAbsoluteIndex(start, len);\n var argumentsLength = arguments.length;\n var insertCount, actualDeleteCount, A, k, from, to;\n if (argumentsLength === 0) {\n insertCount = actualDeleteCount = 0;\n } else if (argumentsLength === 1) {\n insertCount = 0;\n actualDeleteCount = len - actualStart;\n } else {\n insertCount = argumentsLength - 2;\n actualDeleteCount = min(max(toInteger(deleteCount), 0), len - actualStart);\n }\n if (len + insertCount - actualDeleteCount > MAX_SAFE_INTEGER) {\n throw TypeError(MAXIMUM_ALLOWED_LENGTH_EXCEEDED);\n }\n A = arraySpeciesCreate(O, actualDeleteCount);\n for (k = 0; k < actualDeleteCount; k++) {\n from = actualStart + k;\n if (from in O) createProperty(A, k, O[from]);\n }\n A.length = actualDeleteCount;\n if (insertCount < actualDeleteCount) {\n for (k = actualStart; k < len - actualDeleteCount; k++) {\n from = k + actualDeleteCount;\n to = k + insertCount;\n if (from in O) O[to] = O[from];\n else delete O[to];\n }\n for (k = len; k > len - actualDeleteCount + insertCount; k--) delete O[k - 1];\n } else if (insertCount > actualDeleteCount) {\n for (k = len - actualDeleteCount; k > actualStart; k--) {\n from = k + actualDeleteCount - 1;\n to = k + insertCount - 1;\n if (from in O) O[to] = O[from];\n else delete O[to];\n }\n }\n for (k = 0; k < insertCount; k++) {\n O[k + actualStart] = arguments[k + 2];\n }\n O.length = len - actualDeleteCount + insertCount;\n return A;\n }\n});\n\n\n/***/ }),\n\n/***/ \"a4d3\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar global = __webpack_require__(\"da84\");\nvar getBuiltIn = __webpack_require__(\"d066\");\nvar IS_PURE = __webpack_require__(\"c430\");\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar NATIVE_SYMBOL = __webpack_require__(\"4930\");\nvar USE_SYMBOL_AS_UID = __webpack_require__(\"fdbf\");\nvar fails = __webpack_require__(\"d039\");\nvar has = __webpack_require__(\"5135\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar isObject = __webpack_require__(\"861d\");\nvar anObject = __webpack_require__(\"825a\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar toPrimitive = __webpack_require__(\"c04e\");\nvar createPropertyDescriptor = __webpack_require__(\"5c6c\");\nvar nativeObjectCreate = __webpack_require__(\"7c73\");\nvar objectKeys = __webpack_require__(\"df75\");\nvar getOwnPropertyNamesModule = __webpack_require__(\"241c\");\nvar getOwnPropertyNamesExternal = __webpack_require__(\"057f\");\nvar getOwnPropertySymbolsModule = __webpack_require__(\"7418\");\nvar getOwnPropertyDescriptorModule = __webpack_require__(\"06cf\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\nvar propertyIsEnumerableModule = __webpack_require__(\"d1e7\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar shared = __webpack_require__(\"5692\");\nvar sharedKey = __webpack_require__(\"f772\");\nvar hiddenKeys = __webpack_require__(\"d012\");\nvar uid = __webpack_require__(\"90e3\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar wrappedWellKnownSymbolModule = __webpack_require__(\"e538\");\nvar defineWellKnownSymbol = __webpack_require__(\"746f\");\nvar setToStringTag = __webpack_require__(\"d44e\");\nvar InternalStateModule = __webpack_require__(\"69f3\");\nvar $forEach = __webpack_require__(\"b727\").forEach;\n\nvar HIDDEN = sharedKey('hidden');\nvar SYMBOL = 'Symbol';\nvar PROTOTYPE = 'prototype';\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(SYMBOL);\nvar ObjectPrototype = Object[PROTOTYPE];\nvar $Symbol = global.Symbol;\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\nvar nativeDefineProperty = definePropertyModule.f;\nvar nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f;\nvar nativePropertyIsEnumerable = propertyIsEnumerableModule.f;\nvar AllSymbols = shared('symbols');\nvar ObjectPrototypeSymbols = shared('op-symbols');\nvar StringToSymbolRegistry = shared('string-to-symbol-registry');\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\nvar WellKnownSymbolsStore = shared('wks');\nvar QObject = global.QObject;\n// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173\nvar USE_SETTER = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;\n\n// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687\nvar setSymbolDescriptor = DESCRIPTORS && fails(function () {\n return nativeObjectCreate(nativeDefineProperty({}, 'a', {\n get: function () { return nativeDefineProperty(this, 'a', { value: 7 }).a; }\n })).a != 7;\n}) ? function (O, P, Attributes) {\n var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor(ObjectPrototype, P);\n if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];\n nativeDefineProperty(O, P, Attributes);\n if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {\n nativeDefineProperty(ObjectPrototype, P, ObjectPrototypeDescriptor);\n }\n} : nativeDefineProperty;\n\nvar wrap = function (tag, description) {\n var symbol = AllSymbols[tag] = nativeObjectCreate($Symbol[PROTOTYPE]);\n setInternalState(symbol, {\n type: SYMBOL,\n tag: tag,\n description: description\n });\n if (!DESCRIPTORS) symbol.description = description;\n return symbol;\n};\n\nvar isSymbol = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n return Object(it) instanceof $Symbol;\n};\n\nvar $defineProperty = function defineProperty(O, P, Attributes) {\n if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);\n anObject(O);\n var key = toPrimitive(P, true);\n anObject(Attributes);\n if (has(AllSymbols, key)) {\n if (!Attributes.enumerable) {\n if (!has(O, HIDDEN)) nativeDefineProperty(O, HIDDEN, createPropertyDescriptor(1, {}));\n O[HIDDEN][key] = true;\n } else {\n if (has(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;\n Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });\n } return setSymbolDescriptor(O, key, Attributes);\n } return nativeDefineProperty(O, key, Attributes);\n};\n\nvar $defineProperties = function defineProperties(O, Properties) {\n anObject(O);\n var properties = toIndexedObject(Properties);\n var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));\n $forEach(keys, function (key) {\n if (!DESCRIPTORS || $propertyIsEnumerable.call(properties, key)) $defineProperty(O, key, properties[key]);\n });\n return O;\n};\n\nvar $create = function create(O, Properties) {\n return Properties === undefined ? nativeObjectCreate(O) : $defineProperties(nativeObjectCreate(O), Properties);\n};\n\nvar $propertyIsEnumerable = function propertyIsEnumerable(V) {\n var P = toPrimitive(V, true);\n var enumerable = nativePropertyIsEnumerable.call(this, P);\n if (this === ObjectPrototype && has(AllSymbols, P) && !has(ObjectPrototypeSymbols, P)) return false;\n return enumerable || !has(this, P) || !has(AllSymbols, P) || has(this, HIDDEN) && this[HIDDEN][P] ? enumerable : true;\n};\n\nvar $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {\n var it = toIndexedObject(O);\n var key = toPrimitive(P, true);\n if (it === ObjectPrototype && has(AllSymbols, key) && !has(ObjectPrototypeSymbols, key)) return;\n var descriptor = nativeGetOwnPropertyDescriptor(it, key);\n if (descriptor && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) {\n descriptor.enumerable = true;\n }\n return descriptor;\n};\n\nvar $getOwnPropertyNames = function getOwnPropertyNames(O) {\n var names = nativeGetOwnPropertyNames(toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (!has(AllSymbols, key) && !has(hiddenKeys, key)) result.push(key);\n });\n return result;\n};\n\nvar $getOwnPropertySymbols = function getOwnPropertySymbols(O) {\n var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;\n var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (has(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || has(ObjectPrototype, key))) {\n result.push(AllSymbols[key]);\n }\n });\n return result;\n};\n\n// `Symbol` constructor\n// https://tc39.github.io/ecma262/#sec-symbol-constructor\nif (!NATIVE_SYMBOL) {\n $Symbol = function Symbol() {\n if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor');\n var description = !arguments.length || arguments[0] === undefined ? undefined : String(arguments[0]);\n var tag = uid(description);\n var setter = function (value) {\n if (this === ObjectPrototype) setter.call(ObjectPrototypeSymbols, value);\n if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;\n setSymbolDescriptor(this, tag, createPropertyDescriptor(1, value));\n };\n if (DESCRIPTORS && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });\n return wrap(tag, description);\n };\n\n redefine($Symbol[PROTOTYPE], 'toString', function toString() {\n return getInternalState(this).tag;\n });\n\n redefine($Symbol, 'withoutSetter', function (description) {\n return wrap(uid(description), description);\n });\n\n propertyIsEnumerableModule.f = $propertyIsEnumerable;\n definePropertyModule.f = $defineProperty;\n getOwnPropertyDescriptorModule.f = $getOwnPropertyDescriptor;\n getOwnPropertyNamesModule.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames;\n getOwnPropertySymbolsModule.f = $getOwnPropertySymbols;\n\n wrappedWellKnownSymbolModule.f = function (name) {\n return wrap(wellKnownSymbol(name), name);\n };\n\n if (DESCRIPTORS) {\n // https://github.com/tc39/proposal-Symbol-description\n nativeDefineProperty($Symbol[PROTOTYPE], 'description', {\n configurable: true,\n get: function description() {\n return getInternalState(this).description;\n }\n });\n if (!IS_PURE) {\n redefine(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });\n }\n }\n}\n\n$({ global: true, wrap: true, forced: !NATIVE_SYMBOL, sham: !NATIVE_SYMBOL }, {\n Symbol: $Symbol\n});\n\n$forEach(objectKeys(WellKnownSymbolsStore), function (name) {\n defineWellKnownSymbol(name);\n});\n\n$({ target: SYMBOL, stat: true, forced: !NATIVE_SYMBOL }, {\n // `Symbol.for` method\n // https://tc39.github.io/ecma262/#sec-symbol.for\n 'for': function (key) {\n var string = String(key);\n if (has(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];\n var symbol = $Symbol(string);\n StringToSymbolRegistry[string] = symbol;\n SymbolToStringRegistry[symbol] = string;\n return symbol;\n },\n // `Symbol.keyFor` method\n // https://tc39.github.io/ecma262/#sec-symbol.keyfor\n keyFor: function keyFor(sym) {\n if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol');\n if (has(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];\n },\n useSetter: function () { USE_SETTER = true; },\n useSimple: function () { USE_SETTER = false; }\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL, sham: !DESCRIPTORS }, {\n // `Object.create` method\n // https://tc39.github.io/ecma262/#sec-object.create\n create: $create,\n // `Object.defineProperty` method\n // https://tc39.github.io/ecma262/#sec-object.defineproperty\n defineProperty: $defineProperty,\n // `Object.defineProperties` method\n // https://tc39.github.io/ecma262/#sec-object.defineproperties\n defineProperties: $defineProperties,\n // `Object.getOwnPropertyDescriptor` method\n // https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptors\n getOwnPropertyDescriptor: $getOwnPropertyDescriptor\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL }, {\n // `Object.getOwnPropertyNames` method\n // https://tc39.github.io/ecma262/#sec-object.getownpropertynames\n getOwnPropertyNames: $getOwnPropertyNames,\n // `Object.getOwnPropertySymbols` method\n // https://tc39.github.io/ecma262/#sec-object.getownpropertysymbols\n getOwnPropertySymbols: $getOwnPropertySymbols\n});\n\n// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives\n// https://bugs.chromium.org/p/v8/issues/detail?id=3443\n$({ target: 'Object', stat: true, forced: fails(function () { getOwnPropertySymbolsModule.f(1); }) }, {\n getOwnPropertySymbols: function getOwnPropertySymbols(it) {\n return getOwnPropertySymbolsModule.f(toObject(it));\n }\n});\n\n// `JSON.stringify` method behavior with symbols\n// https://tc39.github.io/ecma262/#sec-json.stringify\nif ($stringify) {\n var FORCED_JSON_STRINGIFY = !NATIVE_SYMBOL || fails(function () {\n var symbol = $Symbol();\n // MS Edge converts symbol values to JSON as {}\n return $stringify([symbol]) != '[null]'\n // WebKit converts symbol values to JSON as null\n || $stringify({ a: symbol }) != '{}'\n // V8 throws on boxed symbols\n || $stringify(Object(symbol)) != '{}';\n });\n\n $({ target: 'JSON', stat: true, forced: FORCED_JSON_STRINGIFY }, {\n // eslint-disable-next-line no-unused-vars\n stringify: function stringify(it, replacer, space) {\n var args = [it];\n var index = 1;\n var $replacer;\n while (arguments.length > index) args.push(arguments[index++]);\n $replacer = replacer;\n if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined\n if (!isArray(replacer)) replacer = function (key, value) {\n if (typeof $replacer == 'function') value = $replacer.call(this, key, value);\n if (!isSymbol(value)) return value;\n };\n args[1] = replacer;\n return $stringify.apply(null, args);\n }\n });\n}\n\n// `Symbol.prototype[@@toPrimitive]` method\n// https://tc39.github.io/ecma262/#sec-symbol.prototype-@@toprimitive\nif (!$Symbol[PROTOTYPE][TO_PRIMITIVE]) {\n createNonEnumerableProperty($Symbol[PROTOTYPE], TO_PRIMITIVE, $Symbol[PROTOTYPE].valueOf);\n}\n// `Symbol.prototype[@@toStringTag]` property\n// https://tc39.github.io/ecma262/#sec-symbol.prototype-@@tostringtag\nsetToStringTag($Symbol, SYMBOL);\n\nhiddenKeys[HIDDEN] = true;\n\n\n/***/ }),\n\n/***/ \"a630\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar from = __webpack_require__(\"4df4\");\nvar checkCorrectnessOfIteration = __webpack_require__(\"1c7e\");\n\nvar INCORRECT_ITERATION = !checkCorrectnessOfIteration(function (iterable) {\n Array.from(iterable);\n});\n\n// `Array.from` method\n// https://tc39.github.io/ecma262/#sec-array.from\n$({ target: 'Array', stat: true, forced: INCORRECT_ITERATION }, {\n from: from\n});\n\n\n/***/ }),\n\n/***/ \"a640\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar fails = __webpack_require__(\"d039\");\n\nmodule.exports = function (METHOD_NAME, argument) {\n var method = [][METHOD_NAME];\n return !!method && fails(function () {\n // eslint-disable-next-line no-useless-call,no-throw-literal\n method.call(null, argument || function () { throw 1; }, 1);\n });\n};\n\n\n/***/ }),\n\n/***/ \"a691\":\n/***/ (function(module, exports) {\n\nvar ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `ToInteger` abstract operation\n// https://tc39.github.io/ecma262/#sec-tointeger\nmodule.exports = function (argument) {\n return isNaN(argument = +argument) ? 0 : (argument > 0 ? floor : ceil)(argument);\n};\n\n\n/***/ }),\n\n/***/ \"ab13\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar MATCH = wellKnownSymbol('match');\n\nmodule.exports = function (METHOD_NAME) {\n var regexp = /./;\n try {\n '/./'[METHOD_NAME](regexp);\n } catch (e) {\n try {\n regexp[MATCH] = false;\n return '/./'[METHOD_NAME](regexp);\n } catch (f) { /* empty */ }\n } return false;\n};\n\n\n/***/ }),\n\n/***/ \"ac1f\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar exec = __webpack_require__(\"9263\");\n\n$({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {\n exec: exec\n});\n\n\n/***/ }),\n\n/***/ \"ad6d\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar anObject = __webpack_require__(\"825a\");\n\n// `RegExp.prototype.flags` getter implementation\n// https://tc39.github.io/ecma262/#sec-get-regexp.prototype.flags\nmodule.exports = function () {\n var that = anObject(this);\n var result = '';\n if (that.global) result += 'g';\n if (that.ignoreCase) result += 'i';\n if (that.multiline) result += 'm';\n if (that.dotAll) result += 's';\n if (that.unicode) result += 'u';\n if (that.sticky) result += 'y';\n return result;\n};\n\n\n/***/ }),\n\n/***/ \"ae40\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar fails = __webpack_require__(\"d039\");\nvar has = __webpack_require__(\"5135\");\n\nvar defineProperty = Object.defineProperty;\nvar cache = {};\n\nvar thrower = function (it) { throw it; };\n\nmodule.exports = function (METHOD_NAME, options) {\n if (has(cache, METHOD_NAME)) return cache[METHOD_NAME];\n if (!options) options = {};\n var method = [][METHOD_NAME];\n var ACCESSORS = has(options, 'ACCESSORS') ? options.ACCESSORS : false;\n var argument0 = has(options, 0) ? options[0] : thrower;\n var argument1 = has(options, 1) ? options[1] : undefined;\n\n return cache[METHOD_NAME] = !!method && !fails(function () {\n if (ACCESSORS && !DESCRIPTORS) return true;\n var O = { length: -1 };\n\n if (ACCESSORS) defineProperty(O, 1, { enumerable: true, get: thrower });\n else O[1] = 1;\n\n method.call(O, argument0, argument1);\n });\n};\n\n\n/***/ }),\n\n/***/ \"ae93\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar getPrototypeOf = __webpack_require__(\"e163\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar has = __webpack_require__(\"5135\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar IS_PURE = __webpack_require__(\"c430\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false;\n\nvar returnThis = function () { return this; };\n\n// `%IteratorPrototype%` object\n// https://tc39.github.io/ecma262/#sec-%iteratorprototype%-object\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n\nif ([].keys) {\n arrayIterator = [].keys();\n // Safari 8 has buggy iterators w/o `next`\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;\n else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nif (IteratorPrototype == undefined) IteratorPrototype = {};\n\n// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()\nif (!IS_PURE && !has(IteratorPrototype, ITERATOR)) {\n createNonEnumerableProperty(IteratorPrototype, ITERATOR, returnThis);\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};\n\n\n/***/ }),\n\n/***/ \"b041\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar TO_STRING_TAG_SUPPORT = __webpack_require__(\"00ee\");\nvar classof = __webpack_require__(\"f5df\");\n\n// `Object.prototype.toString` method implementation\n// https://tc39.github.io/ecma262/#sec-object.prototype.tostring\nmodule.exports = TO_STRING_TAG_SUPPORT ? {}.toString : function toString() {\n return '[object ' + classof(this) + ']';\n};\n\n\n/***/ }),\n\n/***/ \"b0c0\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar defineProperty = __webpack_require__(\"9bf2\").f;\n\nvar FunctionPrototype = Function.prototype;\nvar FunctionPrototypeToString = FunctionPrototype.toString;\nvar nameRE = /^\\s*function ([^ (]*)/;\nvar NAME = 'name';\n\n// Function instances `.name` property\n// https://tc39.github.io/ecma262/#sec-function-instances-name\nif (DESCRIPTORS && !(NAME in FunctionPrototype)) {\n defineProperty(FunctionPrototype, NAME, {\n configurable: true,\n get: function () {\n try {\n return FunctionPrototypeToString.call(this).match(nameRE)[1];\n } catch (error) {\n return '';\n }\n }\n });\n}\n\n\n/***/ }),\n\n/***/ \"b622\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar shared = __webpack_require__(\"5692\");\nvar has = __webpack_require__(\"5135\");\nvar uid = __webpack_require__(\"90e3\");\nvar NATIVE_SYMBOL = __webpack_require__(\"4930\");\nvar USE_SYMBOL_AS_UID = __webpack_require__(\"fdbf\");\n\nvar WellKnownSymbolsStore = shared('wks');\nvar Symbol = global.Symbol;\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!has(WellKnownSymbolsStore, name)) {\n if (NATIVE_SYMBOL && has(Symbol, name)) WellKnownSymbolsStore[name] = Symbol[name];\n else WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name);\n } return WellKnownSymbolsStore[name];\n};\n\n\n/***/ }),\n\n/***/ \"b64b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar nativeKeys = __webpack_require__(\"df75\");\nvar fails = __webpack_require__(\"d039\");\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeKeys(1); });\n\n// `Object.keys` method\n// https://tc39.github.io/ecma262/#sec-object.keys\n$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES }, {\n keys: function keys(it) {\n return nativeKeys(toObject(it));\n }\n});\n\n\n/***/ }),\n\n/***/ \"b727\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar bind = __webpack_require__(\"0366\");\nvar IndexedObject = __webpack_require__(\"44ad\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar toLength = __webpack_require__(\"50c4\");\nvar arraySpeciesCreate = __webpack_require__(\"65f0\");\n\nvar push = [].push;\n\n// `Array.prototype.{ forEach, map, filter, some, every, find, findIndex }` methods implementation\nvar createMethod = function (TYPE) {\n var IS_MAP = TYPE == 1;\n var IS_FILTER = TYPE == 2;\n var IS_SOME = TYPE == 3;\n var IS_EVERY = TYPE == 4;\n var IS_FIND_INDEX = TYPE == 6;\n var NO_HOLES = TYPE == 5 || IS_FIND_INDEX;\n return function ($this, callbackfn, that, specificCreate) {\n var O = toObject($this);\n var self = IndexedObject(O);\n var boundFunction = bind(callbackfn, that, 3);\n var length = toLength(self.length);\n var index = 0;\n var create = specificCreate || arraySpeciesCreate;\n var target = IS_MAP ? create($this, length) : IS_FILTER ? create($this, 0) : undefined;\n var value, result;\n for (;length > index; index++) if (NO_HOLES || index in self) {\n value = self[index];\n result = boundFunction(value, index, O);\n if (TYPE) {\n if (IS_MAP) target[index] = result; // map\n else if (result) switch (TYPE) {\n case 3: return true; // some\n case 5: return value; // find\n case 6: return index; // findIndex\n case 2: push.call(target, value); // filter\n } else if (IS_EVERY) return false; // every\n }\n }\n return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.forEach` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.foreach\n forEach: createMethod(0),\n // `Array.prototype.map` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.map\n map: createMethod(1),\n // `Array.prototype.filter` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.filter\n filter: createMethod(2),\n // `Array.prototype.some` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.some\n some: createMethod(3),\n // `Array.prototype.every` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.every\n every: createMethod(4),\n // `Array.prototype.find` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.find\n find: createMethod(5),\n // `Array.prototype.findIndex` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.findIndex\n findIndex: createMethod(6)\n};\n\n\n/***/ }),\n\n/***/ \"c04e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar isObject = __webpack_require__(\"861d\");\n\n// `ToPrimitive` abstract operation\n// https://tc39.github.io/ecma262/#sec-toprimitive\n// instead of the ES6 spec version, we didn't implement @@toPrimitive case\n// and the second argument - flag - preferred type is a string\nmodule.exports = function (input, PREFERRED_STRING) {\n if (!isObject(input)) return input;\n var fn, val;\n if (PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;\n if (typeof (fn = input.valueOf) == 'function' && !isObject(val = fn.call(input))) return val;\n if (!PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;\n throw TypeError(\"Can't convert object to primitive value\");\n};\n\n\n/***/ }),\n\n/***/ \"c430\":\n/***/ (function(module, exports) {\n\nmodule.exports = false;\n\n\n/***/ }),\n\n/***/ \"c6b6\":\n/***/ (function(module, exports) {\n\nvar toString = {}.toString;\n\nmodule.exports = function (it) {\n return toString.call(it).slice(8, -1);\n};\n\n\n/***/ }),\n\n/***/ \"c6cd\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar setGlobal = __webpack_require__(\"ce4e\");\n\nvar SHARED = '__core-js_shared__';\nvar store = global[SHARED] || setGlobal(SHARED, {});\n\nmodule.exports = store;\n\n\n/***/ }),\n\n/***/ \"c740\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $findIndex = __webpack_require__(\"b727\").findIndex;\nvar addToUnscopables = __webpack_require__(\"44d2\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar FIND_INDEX = 'findIndex';\nvar SKIPS_HOLES = true;\n\nvar USES_TO_LENGTH = arrayMethodUsesToLength(FIND_INDEX);\n\n// Shouldn't skip holes\nif (FIND_INDEX in []) Array(1)[FIND_INDEX](function () { SKIPS_HOLES = false; });\n\n// `Array.prototype.findIndex` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.findindex\n$({ target: 'Array', proto: true, forced: SKIPS_HOLES || !USES_TO_LENGTH }, {\n findIndex: function findIndex(callbackfn /* , that = undefined */) {\n return $findIndex(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables(FIND_INDEX);\n\n\n/***/ }),\n\n/***/ \"c8ba\":\n/***/ (function(module, exports) {\n\nvar g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n\n\n/***/ }),\n\n/***/ \"c975\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $indexOf = __webpack_require__(\"4d64\").indexOf;\nvar arrayMethodIsStrict = __webpack_require__(\"a640\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar nativeIndexOf = [].indexOf;\n\nvar NEGATIVE_ZERO = !!nativeIndexOf && 1 / [1].indexOf(1, -0) < 0;\nvar STRICT_METHOD = arrayMethodIsStrict('indexOf');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('indexOf', { ACCESSORS: true, 1: 0 });\n\n// `Array.prototype.indexOf` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.indexof\n$({ target: 'Array', proto: true, forced: NEGATIVE_ZERO || !STRICT_METHOD || !USES_TO_LENGTH }, {\n indexOf: function indexOf(searchElement /* , fromIndex = 0 */) {\n return NEGATIVE_ZERO\n // convert -0 to +0\n ? nativeIndexOf.apply(this, arguments) || 0\n : $indexOf(this, searchElement, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"ca84\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar has = __webpack_require__(\"5135\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar indexOf = __webpack_require__(\"4d64\").indexOf;\nvar hiddenKeys = __webpack_require__(\"d012\");\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !has(hiddenKeys, key) && has(O, key) && result.push(key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (has(O, key = names[i++])) {\n ~indexOf(result, key) || result.push(key);\n }\n return result;\n};\n\n\n/***/ }),\n\n/***/ \"caad\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $includes = __webpack_require__(\"4d64\").includes;\nvar addToUnscopables = __webpack_require__(\"44d2\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar USES_TO_LENGTH = arrayMethodUsesToLength('indexOf', { ACCESSORS: true, 1: 0 });\n\n// `Array.prototype.includes` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.includes\n$({ target: 'Array', proto: true, forced: !USES_TO_LENGTH }, {\n includes: function includes(el /* , fromIndex = 0 */) {\n return $includes(this, el, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('includes');\n\n\n/***/ }),\n\n/***/ \"cc12\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar isObject = __webpack_require__(\"861d\");\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n\n\n/***/ }),\n\n/***/ \"ce4e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\n\nmodule.exports = function (key, value) {\n try {\n createNonEnumerableProperty(global, key, value);\n } catch (error) {\n global[key] = value;\n } return value;\n};\n\n\n/***/ }),\n\n/***/ \"d012\":\n/***/ (function(module, exports) {\n\nmodule.exports = {};\n\n\n/***/ }),\n\n/***/ \"d039\":\n/***/ (function(module, exports) {\n\nmodule.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n\n\n/***/ }),\n\n/***/ \"d066\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar path = __webpack_require__(\"428f\");\nvar global = __webpack_require__(\"da84\");\n\nvar aFunction = function (variable) {\n return typeof variable == 'function' ? variable : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(path[namespace]) || aFunction(global[namespace])\n : path[namespace] && path[namespace][method] || global[namespace] && global[namespace][method];\n};\n\n\n/***/ }),\n\n/***/ \"d1e7\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar nativePropertyIsEnumerable = {}.propertyIsEnumerable;\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !nativePropertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.github.io/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : nativePropertyIsEnumerable;\n\n\n/***/ }),\n\n/***/ \"d28b\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar defineWellKnownSymbol = __webpack_require__(\"746f\");\n\n// `Symbol.iterator` well-known symbol\n// https://tc39.github.io/ecma262/#sec-symbol.iterator\ndefineWellKnownSymbol('iterator');\n\n\n/***/ }),\n\n/***/ \"d2bb\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar anObject = __webpack_require__(\"825a\");\nvar aPossiblePrototype = __webpack_require__(\"3bbe\");\n\n// `Object.setPrototypeOf` method\n// https://tc39.github.io/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n/* eslint-disable no-proto */\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n setter = Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set;\n setter.call(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter.call(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n\n\n/***/ }),\n\n/***/ \"d3b7\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar TO_STRING_TAG_SUPPORT = __webpack_require__(\"00ee\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar toString = __webpack_require__(\"b041\");\n\n// `Object.prototype.toString` method\n// https://tc39.github.io/ecma262/#sec-object.prototype.tostring\nif (!TO_STRING_TAG_SUPPORT) {\n redefine(Object.prototype, 'toString', toString, { unsafe: true });\n}\n\n\n/***/ }),\n\n/***/ \"d44e\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar defineProperty = __webpack_require__(\"9bf2\").f;\nvar has = __webpack_require__(\"5135\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n\nmodule.exports = function (it, TAG, STATIC) {\n if (it && !has(it = STATIC ? it : it.prototype, TO_STRING_TAG)) {\n defineProperty(it, TO_STRING_TAG, { configurable: true, value: TAG });\n }\n};\n\n\n/***/ }),\n\n/***/ \"d58f\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar aFunction = __webpack_require__(\"1c0b\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar IndexedObject = __webpack_require__(\"44ad\");\nvar toLength = __webpack_require__(\"50c4\");\n\n// `Array.prototype.{ reduce, reduceRight }` methods implementation\nvar createMethod = function (IS_RIGHT) {\n return function (that, callbackfn, argumentsLength, memo) {\n aFunction(callbackfn);\n var O = toObject(that);\n var self = IndexedObject(O);\n var length = toLength(O.length);\n var index = IS_RIGHT ? length - 1 : 0;\n var i = IS_RIGHT ? -1 : 1;\n if (argumentsLength < 2) while (true) {\n if (index in self) {\n memo = self[index];\n index += i;\n break;\n }\n index += i;\n if (IS_RIGHT ? index < 0 : length <= index) {\n throw TypeError('Reduce of empty array with no initial value');\n }\n }\n for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {\n memo = callbackfn(memo, self[index], index, O);\n }\n return memo;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.reduce` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.reduce\n left: createMethod(false),\n // `Array.prototype.reduceRight` method\n // https://tc39.github.io/ecma262/#sec-array.prototype.reduceright\n right: createMethod(true)\n};\n\n\n/***/ }),\n\n/***/ \"d784\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n// TODO: Remove from `core-js@4` since it's moved to entry points\n__webpack_require__(\"ac1f\");\nvar redefine = __webpack_require__(\"6eeb\");\nvar fails = __webpack_require__(\"d039\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar regexpExec = __webpack_require__(\"9263\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\n\nvar SPECIES = wellKnownSymbol('species');\n\nvar REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {\n // #replace needs built-in support for named groups.\n // #match works fine because it just return the exec results, even if it has\n // a \"grops\" property.\n var re = /./;\n re.exec = function () {\n var result = [];\n result.groups = { a: '7' };\n return result;\n };\n return ''.replace(re, '$<a>') !== '7';\n});\n\n// IE <= 11 replaces $0 with the whole match, as if it was $&\n// https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0\nvar REPLACE_KEEPS_$0 = (function () {\n return 'a'.replace(/./, '$0') === '$0';\n})();\n\nvar REPLACE = wellKnownSymbol('replace');\n// Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string\nvar REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {\n if (/./[REPLACE]) {\n return /./[REPLACE]('a', '$0') === '';\n }\n return false;\n})();\n\n// Chrome 51 has a buggy \"split\" implementation when RegExp#exec !== nativeExec\n// Weex JS has frozen built-in prototypes, so use try / catch wrapper\nvar SPLIT_WORKS_WITH_OVERWRITTEN_EXEC = !fails(function () {\n var re = /(?:)/;\n var originalExec = re.exec;\n re.exec = function () { return originalExec.apply(this, arguments); };\n var result = 'ab'.split(re);\n return result.length !== 2 || result[0] !== 'a' || result[1] !== 'b';\n});\n\nmodule.exports = function (KEY, length, exec, sham) {\n var SYMBOL = wellKnownSymbol(KEY);\n\n var DELEGATES_TO_SYMBOL = !fails(function () {\n // String methods call symbol-named RegEp methods\n var O = {};\n O[SYMBOL] = function () { return 7; };\n return ''[KEY](O) != 7;\n });\n\n var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {\n // Symbol-named RegExp methods call .exec\n var execCalled = false;\n var re = /a/;\n\n if (KEY === 'split') {\n // We can't use real regex here since it causes deoptimization\n // and serious performance degradation in V8\n // https://github.com/zloirock/core-js/issues/306\n re = {};\n // RegExp[@@split] doesn't call the regex's exec method, but first creates\n // a new one. We need to return the patched regex when creating the new one.\n re.constructor = {};\n re.constructor[SPECIES] = function () { return re; };\n re.flags = '';\n re[SYMBOL] = /./[SYMBOL];\n }\n\n re.exec = function () { execCalled = true; return null; };\n\n re[SYMBOL]('');\n return !execCalled;\n });\n\n if (\n !DELEGATES_TO_SYMBOL ||\n !DELEGATES_TO_EXEC ||\n (KEY === 'replace' && !(\n REPLACE_SUPPORTS_NAMED_GROUPS &&\n REPLACE_KEEPS_$0 &&\n !REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE\n )) ||\n (KEY === 'split' && !SPLIT_WORKS_WITH_OVERWRITTEN_EXEC)\n ) {\n var nativeRegExpMethod = /./[SYMBOL];\n var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {\n if (regexp.exec === regexpExec) {\n if (DELEGATES_TO_SYMBOL && !forceStringMethod) {\n // The native String method already delegates to @@method (this\n // polyfilled function), leasing to infinite recursion.\n // We avoid it by directly calling the native @@method method.\n return { done: true, value: nativeRegExpMethod.call(regexp, str, arg2) };\n }\n return { done: true, value: nativeMethod.call(str, regexp, arg2) };\n }\n return { done: false };\n }, {\n REPLACE_KEEPS_$0: REPLACE_KEEPS_$0,\n REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE: REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE\n });\n var stringMethod = methods[0];\n var regexMethod = methods[1];\n\n redefine(String.prototype, KEY, stringMethod);\n redefine(RegExp.prototype, SYMBOL, length == 2\n // 21.2.5.8 RegExp.prototype[@@replace](string, replaceValue)\n // 21.2.5.11 RegExp.prototype[@@split](string, limit)\n ? function (string, arg) { return regexMethod.call(string, this, arg); }\n // 21.2.5.6 RegExp.prototype[@@match](string)\n // 21.2.5.9 RegExp.prototype[@@search](string)\n : function (string) { return regexMethod.call(string, this); }\n );\n }\n\n if (sham) createNonEnumerableProperty(RegExp.prototype[SYMBOL], 'sham', true);\n};\n\n\n/***/ }),\n\n/***/ \"d81d\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar $map = __webpack_require__(\"b727\").map;\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('map');\n// FF49- issue\nvar USES_TO_LENGTH = arrayMethodUsesToLength('map');\n\n// `Array.prototype.map` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.map\n// with adding support of @@species\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n map: function map(callbackfn /* , thisArg */) {\n return $map(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);\n }\n});\n\n\n/***/ }),\n\n/***/ \"da84\":\n/***/ (function(module, exports, __webpack_require__) {\n\n/* WEBPACK VAR INJECTION */(function(global) {var check = function (it) {\n return it && it.Math == Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line no-undef\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n // eslint-disable-next-line no-new-func\n Function('return this')();\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(\"c8ba\")))\n\n/***/ }),\n\n/***/ \"dbb4\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar ownKeys = __webpack_require__(\"56ef\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar getOwnPropertyDescriptorModule = __webpack_require__(\"06cf\");\nvar createProperty = __webpack_require__(\"8418\");\n\n// `Object.getOwnPropertyDescriptors` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptors\n$({ target: 'Object', stat: true, sham: !DESCRIPTORS }, {\n getOwnPropertyDescriptors: function getOwnPropertyDescriptors(object) {\n var O = toIndexedObject(object);\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n var keys = ownKeys(O);\n var result = {};\n var index = 0;\n var key, descriptor;\n while (keys.length > index) {\n descriptor = getOwnPropertyDescriptor(O, key = keys[index++]);\n if (descriptor !== undefined) createProperty(result, key, descriptor);\n }\n return result;\n }\n});\n\n\n/***/ }),\n\n/***/ \"dbf1\":\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* WEBPACK VAR INJECTION */(function(global) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return console; });\nfunction getConsole() {\n if (typeof window !== \"undefined\") {\n return window.console;\n }\n\n return global.console;\n}\n\nvar console = getConsole();\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(\"c8ba\")))\n\n/***/ }),\n\n/***/ \"ddb0\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar global = __webpack_require__(\"da84\");\nvar DOMIterables = __webpack_require__(\"fdbc\");\nvar ArrayIteratorMethods = __webpack_require__(\"e260\");\nvar createNonEnumerableProperty = __webpack_require__(\"9112\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar ArrayValues = ArrayIteratorMethods.values;\n\nfor (var COLLECTION_NAME in DOMIterables) {\n var Collection = global[COLLECTION_NAME];\n var CollectionPrototype = Collection && Collection.prototype;\n if (CollectionPrototype) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[ITERATOR] !== ArrayValues) try {\n createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);\n } catch (error) {\n CollectionPrototype[ITERATOR] = ArrayValues;\n }\n if (!CollectionPrototype[TO_STRING_TAG]) {\n createNonEnumerableProperty(CollectionPrototype, TO_STRING_TAG, COLLECTION_NAME);\n }\n if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {\n createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);\n } catch (error) {\n CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];\n }\n }\n }\n}\n\n\n/***/ }),\n\n/***/ \"df75\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar internalObjectKeys = __webpack_require__(\"ca84\");\nvar enumBugKeys = __webpack_require__(\"7839\");\n\n// `Object.keys` method\n// https://tc39.github.io/ecma262/#sec-object.keys\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};\n\n\n/***/ }),\n\n/***/ \"e01a\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n// `Symbol.prototype.description` getter\n// https://tc39.github.io/ecma262/#sec-symbol.prototype.description\n\nvar $ = __webpack_require__(\"23e7\");\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\nvar global = __webpack_require__(\"da84\");\nvar has = __webpack_require__(\"5135\");\nvar isObject = __webpack_require__(\"861d\");\nvar defineProperty = __webpack_require__(\"9bf2\").f;\nvar copyConstructorProperties = __webpack_require__(\"e893\");\n\nvar NativeSymbol = global.Symbol;\n\nif (DESCRIPTORS && typeof NativeSymbol == 'function' && (!('description' in NativeSymbol.prototype) ||\n // Safari 12 bug\n NativeSymbol().description !== undefined\n)) {\n var EmptyStringDescriptionStore = {};\n // wrap Symbol constructor for correct work with undefined description\n var SymbolWrapper = function Symbol() {\n var description = arguments.length < 1 || arguments[0] === undefined ? undefined : String(arguments[0]);\n var result = this instanceof SymbolWrapper\n ? new NativeSymbol(description)\n // in Edge 13, String(Symbol(undefined)) === 'Symbol(undefined)'\n : description === undefined ? NativeSymbol() : NativeSymbol(description);\n if (description === '') EmptyStringDescriptionStore[result] = true;\n return result;\n };\n copyConstructorProperties(SymbolWrapper, NativeSymbol);\n var symbolPrototype = SymbolWrapper.prototype = NativeSymbol.prototype;\n symbolPrototype.constructor = SymbolWrapper;\n\n var symbolToString = symbolPrototype.toString;\n var native = String(NativeSymbol('test')) == 'Symbol(test)';\n var regexp = /^Symbol\\((.*)\\)[^)]+$/;\n defineProperty(symbolPrototype, 'description', {\n configurable: true,\n get: function description() {\n var symbol = isObject(this) ? this.valueOf() : this;\n var string = symbolToString.call(symbol);\n if (has(EmptyStringDescriptionStore, symbol)) return '';\n var desc = native ? string.slice(7, -1) : string.replace(regexp, '$1');\n return desc === '' ? undefined : desc;\n }\n });\n\n $({ global: true, forced: true }, {\n Symbol: SymbolWrapper\n });\n}\n\n\n/***/ }),\n\n/***/ \"e163\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar has = __webpack_require__(\"5135\");\nvar toObject = __webpack_require__(\"7b0b\");\nvar sharedKey = __webpack_require__(\"f772\");\nvar CORRECT_PROTOTYPE_GETTER = __webpack_require__(\"e177\");\n\nvar IE_PROTO = sharedKey('IE_PROTO');\nvar ObjectPrototype = Object.prototype;\n\n// `Object.getPrototypeOf` method\n// https://tc39.github.io/ecma262/#sec-object.getprototypeof\nmodule.exports = CORRECT_PROTOTYPE_GETTER ? Object.getPrototypeOf : function (O) {\n O = toObject(O);\n if (has(O, IE_PROTO)) return O[IE_PROTO];\n if (typeof O.constructor == 'function' && O instanceof O.constructor) {\n return O.constructor.prototype;\n } return O instanceof Object ? ObjectPrototype : null;\n};\n\n\n/***/ }),\n\n/***/ \"e177\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar fails = __webpack_require__(\"d039\");\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n\n\n/***/ }),\n\n/***/ \"e260\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar addToUnscopables = __webpack_require__(\"44d2\");\nvar Iterators = __webpack_require__(\"3f8c\");\nvar InternalStateModule = __webpack_require__(\"69f3\");\nvar defineIterator = __webpack_require__(\"7dd0\");\n\nvar ARRAY_ITERATOR = 'Array Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);\n\n// `Array.prototype.entries` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.entries\n// `Array.prototype.keys` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.keys\n// `Array.prototype.values` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.values\n// `Array.prototype[@@iterator]` method\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@iterator\n// `CreateArrayIterator` internal method\n// https://tc39.github.io/ecma262/#sec-createarrayiterator\nmodule.exports = defineIterator(Array, 'Array', function (iterated, kind) {\n setInternalState(this, {\n type: ARRAY_ITERATOR,\n target: toIndexedObject(iterated), // target\n index: 0, // next index\n kind: kind // kind\n });\n// `%ArrayIteratorPrototype%.next` method\n// https://tc39.github.io/ecma262/#sec-%arrayiteratorprototype%.next\n}, function () {\n var state = getInternalState(this);\n var target = state.target;\n var kind = state.kind;\n var index = state.index++;\n if (!target || index >= target.length) {\n state.target = undefined;\n return { value: undefined, done: true };\n }\n if (kind == 'keys') return { value: index, done: false };\n if (kind == 'values') return { value: target[index], done: false };\n return { value: [index, target[index]], done: false };\n}, 'values');\n\n// argumentsList[@@iterator] is %ArrayProto_values%\n// https://tc39.github.io/ecma262/#sec-createunmappedargumentsobject\n// https://tc39.github.io/ecma262/#sec-createmappedargumentsobject\nIterators.Arguments = Iterators.Array;\n\n// https://tc39.github.io/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries');\n\n\n/***/ }),\n\n/***/ \"e439\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar $ = __webpack_require__(\"23e7\");\nvar fails = __webpack_require__(\"d039\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar nativeGetOwnPropertyDescriptor = __webpack_require__(\"06cf\").f;\nvar DESCRIPTORS = __webpack_require__(\"83ab\");\n\nvar FAILS_ON_PRIMITIVES = fails(function () { nativeGetOwnPropertyDescriptor(1); });\nvar FORCED = !DESCRIPTORS || FAILS_ON_PRIMITIVES;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.github.io/ecma262/#sec-object.getownpropertydescriptor\n$({ target: 'Object', stat: true, forced: FORCED, sham: !DESCRIPTORS }, {\n getOwnPropertyDescriptor: function getOwnPropertyDescriptor(it, key) {\n return nativeGetOwnPropertyDescriptor(toIndexedObject(it), key);\n }\n});\n\n\n/***/ }),\n\n/***/ \"e538\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nexports.f = wellKnownSymbol;\n\n\n/***/ }),\n\n/***/ \"e893\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar has = __webpack_require__(\"5135\");\nvar ownKeys = __webpack_require__(\"56ef\");\nvar getOwnPropertyDescriptorModule = __webpack_require__(\"06cf\");\nvar definePropertyModule = __webpack_require__(\"9bf2\");\n\nmodule.exports = function (target, source) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n if (!has(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n};\n\n\n/***/ }),\n\n/***/ \"e8b5\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar classof = __webpack_require__(\"c6b6\");\n\n// `IsArray` abstract operation\n// https://tc39.github.io/ecma262/#sec-isarray\nmodule.exports = Array.isArray || function isArray(arg) {\n return classof(arg) == 'Array';\n};\n\n\n/***/ }),\n\n/***/ \"e95a\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar Iterators = __webpack_require__(\"3f8c\");\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar ArrayPrototype = Array.prototype;\n\n// check on default Array iterator\nmodule.exports = function (it) {\n return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);\n};\n\n\n/***/ }),\n\n/***/ \"f5df\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar TO_STRING_TAG_SUPPORT = __webpack_require__(\"00ee\");\nvar classofRaw = __webpack_require__(\"c6b6\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : result;\n};\n\n\n/***/ }),\n\n/***/ \"f772\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar shared = __webpack_require__(\"5692\");\nvar uid = __webpack_require__(\"90e3\");\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n\n\n/***/ }),\n\n/***/ \"fb15\":\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n// ESM COMPAT FLAG\n__webpack_require__.r(__webpack_exports__);\n\n// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js\n// This file is imported into lib/wc client bundles.\n\nif (typeof window !== 'undefined') {\n var currentScript = window.document.currentScript\n if (true) {\n var getCurrentScript = __webpack_require__(\"8875\")\n currentScript = getCurrentScript()\n\n // for backward compatibility, because previously we directly included the polyfill\n if (!('currentScript' in document)) {\n Object.defineProperty(document, 'currentScript', { get: getCurrentScript })\n }\n }\n\n var src = currentScript && currentScript.src.match(/(.+\\/)[^/]+\\.js(\\?.*)?$/)\n if (src) {\n __webpack_require__.p = src[1] // eslint-disable-line\n }\n}\n\n// Indicate to webpack that this file can be concatenated\n/* harmony default export */ var setPublicPath = (null);\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.concat.js\nvar es_array_concat = __webpack_require__(\"99af\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.filter.js\nvar es_array_filter = __webpack_require__(\"4de4\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.for-each.js\nvar es_array_for_each = __webpack_require__(\"4160\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.index-of.js\nvar es_array_index_of = __webpack_require__(\"c975\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.map.js\nvar es_array_map = __webpack_require__(\"d81d\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.splice.js\nvar es_array_splice = __webpack_require__(\"a434\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.for-each.js\nvar web_dom_collections_for_each = __webpack_require__(\"159b\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.js\nvar es_symbol = __webpack_require__(\"a4d3\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.get-own-property-descriptor.js\nvar es_object_get_own_property_descriptor = __webpack_require__(\"e439\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.get-own-property-descriptors.js\nvar es_object_get_own_property_descriptors = __webpack_require__(\"dbb4\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.keys.js\nvar es_object_keys = __webpack_require__(\"b64b\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/defineProperty.js\nfunction _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js\n\n\n\n\n\n\n\n\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nfunction _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n _defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js\nfunction _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.description.js\nvar es_symbol_description = __webpack_require__(\"e01a\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.iterator.js\nvar es_symbol_iterator = __webpack_require__(\"d28b\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.iterator.js\nvar es_array_iterator = __webpack_require__(\"e260\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js\nvar es_object_to_string = __webpack_require__(\"d3b7\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.iterator.js\nvar es_string_iterator = __webpack_require__(\"3ca3\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.iterator.js\nvar web_dom_collections_iterator = __webpack_require__(\"ddb0\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js\n\n\n\n\n\n\n\nfunction _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.from.js\nvar es_array_from = __webpack_require__(\"a630\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.slice.js\nvar es_array_slice = __webpack_require__(\"fb6a\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.function.name.js\nvar es_function_name = __webpack_require__(\"b0c0\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.to-string.js\nvar es_regexp_to_string = __webpack_require__(\"25f0\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js\n\n\n\n\n\n\n\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableRest.js\nfunction _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js\n\n\n\n\nfunction _slicedToArray(arr, i) {\n return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js\n\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return _arrayLikeToArray(arr);\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArray.js\n\n\n\n\n\n\n\n\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js\n\n\n\n\nfunction _toConsumableArray(arr) {\n return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();\n}\n// EXTERNAL MODULE: external {\"commonjs\":\"sortablejs\",\"commonjs2\":\"sortablejs\",\"amd\":\"sortablejs\",\"root\":\"Sortable\"}\nvar external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_ = __webpack_require__(\"a352\");\nvar external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_default = /*#__PURE__*/__webpack_require__.n(external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_);\n\n// CONCATENATED MODULE: ./src/util/htmlHelper.js\nfunction removeNode(node) {\n if (node.parentElement !== null) {\n node.parentElement.removeChild(node);\n }\n}\n\nfunction insertNodeAt(fatherNode, node, position) {\n var refNode = position === 0 ? fatherNode.children[0] : fatherNode.children[position - 1].nextSibling;\n fatherNode.insertBefore(node, refNode);\n}\n\n\n// EXTERNAL MODULE: ./src/util/console.js\nvar console = __webpack_require__(\"dbf1\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.reduce.js\nvar es_array_reduce = __webpack_require__(\"13d5\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.entries.js\nvar es_object_entries = __webpack_require__(\"4fad\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.exec.js\nvar es_regexp_exec = __webpack_require__(\"ac1f\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.replace.js\nvar es_string_replace = __webpack_require__(\"5319\");\n\n// CONCATENATED MODULE: ./src/util/string.js\n\n\n\nfunction cached(fn) {\n var cache = Object.create(null);\n return function cachedFn(str) {\n var hit = cache[str];\n return hit || (cache[str] = fn(str));\n };\n}\n\nvar regex = /-(\\w)/g;\nvar camelize = cached(function (str) {\n return str.replace(regex, function (_, c) {\n return c.toUpperCase();\n });\n});\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.flat-map.js\nvar es_array_flat_map = __webpack_require__(\"5db7\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.unscopables.flat-map.js\nvar es_array_unscopables_flat_map = __webpack_require__(\"73d9\");\n\n// CONCATENATED MODULE: ./src/core/sortableEvents.js\n\n\n\n\nvar manageAndEmit = [\"Start\", \"Add\", \"Remove\", \"Update\", \"End\"];\nvar emit = [\"Choose\", \"Unchoose\", \"Sort\", \"Filter\", \"Clone\"];\nvar manage = [\"Move\"];\nvar eventHandlerNames = [manage, manageAndEmit, emit].flatMap(function (events) {\n return events;\n}).map(function (evt) {\n return \"on\".concat(evt);\n});\nvar events = {\n manage: manage,\n manageAndEmit: manageAndEmit,\n emit: emit\n};\n\nfunction isReadOnly(eventName) {\n return eventHandlerNames.indexOf(eventName) !== -1;\n}\n\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.includes.js\nvar es_array_includes = __webpack_require__(\"caad\");\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.starts-with.js\nvar es_string_starts_with = __webpack_require__(\"2ca0\");\n\n// CONCATENATED MODULE: ./src/util/tags.js\n\n\nvar tags = [\"a\", \"abbr\", \"address\", \"area\", \"article\", \"aside\", \"audio\", \"b\", \"base\", \"bdi\", \"bdo\", \"blockquote\", \"body\", \"br\", \"button\", \"canvas\", \"caption\", \"cite\", \"code\", \"col\", \"colgroup\", \"data\", \"datalist\", \"dd\", \"del\", \"details\", \"dfn\", \"dialog\", \"div\", \"dl\", \"dt\", \"em\", \"embed\", \"fieldset\", \"figcaption\", \"figure\", \"footer\", \"form\", \"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\", \"head\", \"header\", \"hgroup\", \"hr\", \"html\", \"i\", \"iframe\", \"img\", \"input\", \"ins\", \"kbd\", \"label\", \"legend\", \"li\", \"link\", \"main\", \"map\", \"mark\", \"math\", \"menu\", \"menuitem\", \"meta\", \"meter\", \"nav\", \"noscript\", \"object\", \"ol\", \"optgroup\", \"option\", \"output\", \"p\", \"param\", \"picture\", \"pre\", \"progress\", \"q\", \"rb\", \"rp\", \"rt\", \"rtc\", \"ruby\", \"s\", \"samp\", \"script\", \"section\", \"select\", \"slot\", \"small\", \"source\", \"span\", \"strong\", \"style\", \"sub\", \"summary\", \"sup\", \"svg\", \"table\", \"tbody\", \"td\", \"template\", \"textarea\", \"tfoot\", \"th\", \"thead\", \"time\", \"title\", \"tr\", \"track\", \"u\", \"ul\", \"var\", \"video\", \"wbr\"];\n\nfunction isHtmlTag(name) {\n return tags.includes(name);\n}\n\nfunction isTransition(name) {\n return [\"transition-group\", \"TransitionGroup\"].includes(name);\n}\n\nfunction isHtmlAttribute(value) {\n return [\"id\", \"class\", \"role\", \"style\"].includes(value) || value.startsWith(\"data-\") || value.startsWith(\"aria-\") || value.startsWith(\"on\");\n}\n\n\n// CONCATENATED MODULE: ./src/core/componentBuilderHelper.js\n\n\n\n\n\n\n\n\n\n\n\n\nfunction project(entries) {\n return entries.reduce(function (res, _ref) {\n var _ref2 = _slicedToArray(_ref, 2),\n key = _ref2[0],\n value = _ref2[1];\n\n res[key] = value;\n return res;\n }, {});\n}\n\nfunction getComponentAttributes(_ref3) {\n var $attrs = _ref3.$attrs,\n _ref3$componentData = _ref3.componentData,\n componentData = _ref3$componentData === void 0 ? {} : _ref3$componentData;\n var attributes = project(Object.entries($attrs).filter(function (_ref4) {\n var _ref5 = _slicedToArray(_ref4, 2),\n key = _ref5[0],\n _ = _ref5[1];\n\n return isHtmlAttribute(key);\n }));\n return _objectSpread2(_objectSpread2({}, attributes), componentData);\n}\n\nfunction createSortableOption(_ref6) {\n var $attrs = _ref6.$attrs,\n callBackBuilder = _ref6.callBackBuilder;\n var options = project(getValidSortableEntries($attrs));\n Object.entries(callBackBuilder).forEach(function (_ref7) {\n var _ref8 = _slicedToArray(_ref7, 2),\n eventType = _ref8[0],\n eventBuilder = _ref8[1];\n\n events[eventType].forEach(function (event) {\n options[\"on\".concat(event)] = eventBuilder(event);\n });\n });\n var draggable = \"[data-draggable]\".concat(options.draggable || \"\");\n return _objectSpread2(_objectSpread2({}, options), {}, {\n draggable: draggable\n });\n}\n\nfunction getValidSortableEntries(value) {\n return Object.entries(value).filter(function (_ref9) {\n var _ref10 = _slicedToArray(_ref9, 2),\n key = _ref10[0],\n _ = _ref10[1];\n\n return !isHtmlAttribute(key);\n }).map(function (_ref11) {\n var _ref12 = _slicedToArray(_ref11, 2),\n key = _ref12[0],\n value = _ref12[1];\n\n return [camelize(key), value];\n }).filter(function (_ref13) {\n var _ref14 = _slicedToArray(_ref13, 2),\n key = _ref14[0],\n _ = _ref14[1];\n\n return !isReadOnly(key);\n });\n}\n\n\n// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.find-index.js\nvar es_array_find_index = __webpack_require__(\"c740\");\n\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js\nfunction _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}\n// CONCATENATED MODULE: ./src/core/componentStructure.js\n\n\n\n\n\n\n\n\nvar getHtmlElementFromNode = function getHtmlElementFromNode(_ref) {\n var el = _ref.el;\n return el;\n};\n\nvar addContext = function addContext(domElement, context) {\n return domElement.__draggable_context = context;\n};\n\nvar getContext = function getContext(domElement) {\n return domElement.__draggable_context;\n};\n\nvar componentStructure_ComponentStructure = /*#__PURE__*/function () {\n function ComponentStructure(_ref2) {\n var _ref2$nodes = _ref2.nodes,\n header = _ref2$nodes.header,\n defaultNodes = _ref2$nodes.default,\n footer = _ref2$nodes.footer,\n root = _ref2.root,\n realList = _ref2.realList;\n\n _classCallCheck(this, ComponentStructure);\n\n this.defaultNodes = defaultNodes;\n this.children = [].concat(_toConsumableArray(header), _toConsumableArray(defaultNodes), _toConsumableArray(footer));\n this.externalComponent = root.externalComponent;\n this.rootTransition = root.transition;\n this.tag = root.tag;\n this.realList = realList;\n }\n\n _createClass(ComponentStructure, [{\n key: \"render\",\n value: function render(h, attributes) {\n var tag = this.tag,\n children = this.children,\n _isRootComponent = this._isRootComponent;\n var option = !_isRootComponent ? children : {\n default: function _default() {\n return children;\n }\n };\n return h(tag, attributes, option);\n }\n }, {\n key: \"updated\",\n value: function updated() {\n var defaultNodes = this.defaultNodes,\n realList = this.realList;\n defaultNodes.forEach(function (node, index) {\n addContext(getHtmlElementFromNode(node), {\n element: realList[index],\n index: index\n });\n });\n }\n }, {\n key: \"getUnderlyingVm\",\n value: function getUnderlyingVm(domElement) {\n return getContext(domElement);\n }\n }, {\n key: \"getVmIndexFromDomIndex\",\n value: function getVmIndexFromDomIndex(domIndex, element) {\n var defaultNodes = this.defaultNodes;\n var length = defaultNodes.length;\n var domChildren = element.children;\n var domElement = domChildren.item(domIndex);\n\n if (domElement === null) {\n return length;\n }\n\n var context = getContext(domElement);\n\n if (context) {\n return context.index;\n }\n\n if (length === 0) {\n return 0;\n }\n\n var firstDomListElement = getHtmlElementFromNode(defaultNodes[0]);\n\n var indexFirstDomListElement = _toConsumableArray(domChildren).findIndex(function (element) {\n return element === firstDomListElement;\n });\n\n return domIndex < indexFirstDomListElement ? 0 : length;\n }\n }, {\n key: \"_isRootComponent\",\n get: function get() {\n return this.externalComponent || this.rootTransition;\n }\n }]);\n\n return ComponentStructure;\n}();\n\n\n// EXTERNAL MODULE: external {\"commonjs\":\"vue\",\"commonjs2\":\"vue\",\"root\":\"Vue\"}\nvar external_commonjs_vue_commonjs2_vue_root_Vue_ = __webpack_require__(\"8bbf\");\n\n// CONCATENATED MODULE: ./src/core/renderHelper.js\n\n\n\n\n\n\n\n\n\nfunction getSlot(slots, key) {\n var slotValue = slots[key];\n return slotValue ? slotValue() : [];\n}\n\nfunction computeNodes(_ref) {\n var $slots = _ref.$slots,\n realList = _ref.realList,\n getKey = _ref.getKey;\n var normalizedList = realList || [];\n\n var _map = [\"header\", \"footer\"].map(function (name) {\n return getSlot($slots, name);\n }),\n _map2 = _slicedToArray(_map, 2),\n header = _map2[0],\n footer = _map2[1];\n\n var item = $slots.item;\n\n if (!item) {\n throw new Error(\"draggable element must have an item slot\");\n }\n\n var defaultNodes = normalizedList.flatMap(function (element, index) {\n return item({\n element: element,\n index: index\n }).map(function (node) {\n node.key = getKey(element);\n node.props = _objectSpread2(_objectSpread2({}, node.props || {}), {}, {\n \"data-draggable\": true\n });\n return node;\n });\n });\n\n if (defaultNodes.length !== normalizedList.length) {\n throw new Error(\"Item slot must have only one child\");\n }\n\n return {\n header: header,\n footer: footer,\n default: defaultNodes\n };\n}\n\nfunction getRootInformation(tag) {\n var transition = isTransition(tag);\n var externalComponent = !isHtmlTag(tag) && !transition;\n return {\n transition: transition,\n externalComponent: externalComponent,\n tag: externalComponent ? Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"resolveComponent\"])(tag) : transition ? external_commonjs_vue_commonjs2_vue_root_Vue_[\"TransitionGroup\"] : tag\n };\n}\n\nfunction computeComponentStructure(_ref2) {\n var $slots = _ref2.$slots,\n tag = _ref2.tag,\n realList = _ref2.realList,\n getKey = _ref2.getKey;\n var nodes = computeNodes({\n $slots: $slots,\n realList: realList,\n getKey: getKey\n });\n var root = getRootInformation(tag);\n return new componentStructure_ComponentStructure({\n nodes: nodes,\n root: root,\n realList: realList\n });\n}\n\n\n// CONCATENATED MODULE: ./src/vuedraggable.js\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nfunction _emit(evtName, evtData) {\n var _this = this;\n\n Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"nextTick\"])(function () {\n return _this.$emit(evtName.toLowerCase(), evtData);\n });\n}\n\nfunction _manage(evtName) {\n var _this2 = this;\n\n return function (evtData, originalElement) {\n if (_this2.realList !== null) {\n return _this2[\"onDrag\".concat(evtName)](evtData, originalElement);\n }\n };\n}\n\nfunction _manageAndEmit(evtName) {\n var _this3 = this;\n\n var delegateCallBack = _manage.call(this, evtName);\n\n return function (evtData, originalElement) {\n delegateCallBack.call(_this3, evtData, originalElement);\n\n _emit.call(_this3, evtName, evtData);\n };\n}\n\nvar draggingElement = null;\nvar props = {\n list: {\n type: Array,\n required: false,\n default: null\n },\n modelValue: {\n type: Array,\n required: false,\n default: null\n },\n itemKey: {\n type: [String, Function],\n required: true\n },\n clone: {\n type: Function,\n default: function _default(original) {\n return original;\n }\n },\n tag: {\n type: String,\n default: \"div\"\n },\n move: {\n type: Function,\n default: null\n },\n componentData: {\n type: Object,\n required: false,\n default: null\n }\n};\nvar emits = [\"update:modelValue\", \"change\"].concat(_toConsumableArray([].concat(_toConsumableArray(events.manageAndEmit), _toConsumableArray(events.emit)).map(function (evt) {\n return evt.toLowerCase();\n})));\nvar draggableComponent = Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"defineComponent\"])({\n name: \"draggable\",\n inheritAttrs: false,\n props: props,\n emits: emits,\n data: function data() {\n return {\n error: false\n };\n },\n render: function render() {\n try {\n this.error = false;\n var $slots = this.$slots,\n $attrs = this.$attrs,\n tag = this.tag,\n componentData = this.componentData,\n realList = this.realList,\n getKey = this.getKey;\n var componentStructure = computeComponentStructure({\n $slots: $slots,\n tag: tag,\n realList: realList,\n getKey: getKey\n });\n this.componentStructure = componentStructure;\n var attributes = getComponentAttributes({\n $attrs: $attrs,\n componentData: componentData\n });\n return componentStructure.render(external_commonjs_vue_commonjs2_vue_root_Vue_[\"h\"], attributes);\n } catch (err) {\n this.error = true;\n return Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"h\"])(\"pre\", {\n style: {\n color: \"red\"\n }\n }, err.stack);\n }\n },\n created: function created() {\n if (this.list !== null && this.modelValue !== null) {\n console[\"a\" /* console */].error(\"modelValue and list props are mutually exclusive! Please set one or another.\");\n }\n },\n mounted: function mounted() {\n var _this4 = this;\n\n if (this.error) {\n return;\n }\n\n var $attrs = this.$attrs,\n $el = this.$el,\n componentStructure = this.componentStructure;\n componentStructure.updated();\n var sortableOptions = createSortableOption({\n $attrs: $attrs,\n callBackBuilder: {\n manageAndEmit: function manageAndEmit(event) {\n return _manageAndEmit.call(_this4, event);\n },\n emit: function emit(event) {\n return _emit.bind(_this4, event);\n },\n manage: function manage(event) {\n return _manage.call(_this4, event);\n }\n }\n });\n var targetDomElement = $el.nodeType === 1 ? $el : $el.parentElement;\n this._sortable = new external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_default.a(targetDomElement, sortableOptions);\n this.targetDomElement = targetDomElement;\n targetDomElement.__draggable_component__ = this;\n },\n updated: function updated() {\n this.componentStructure.updated();\n },\n beforeUnmount: function beforeUnmount() {\n if (this._sortable !== undefined) this._sortable.destroy();\n },\n computed: {\n realList: function realList() {\n var list = this.list;\n return list ? list : this.modelValue;\n },\n getKey: function getKey() {\n var itemKey = this.itemKey;\n\n if (typeof itemKey === \"function\") {\n return itemKey;\n }\n\n return function (element) {\n return element[itemKey];\n };\n }\n },\n watch: {\n $attrs: {\n handler: function handler(newOptionValue) {\n var _sortable = this._sortable;\n if (!_sortable) return;\n getValidSortableEntries(newOptionValue).forEach(function (_ref) {\n var _ref2 = _slicedToArray(_ref, 2),\n key = _ref2[0],\n value = _ref2[1];\n\n _sortable.option(key, value);\n });\n },\n deep: true\n }\n },\n methods: {\n getUnderlyingVm: function getUnderlyingVm(domElement) {\n return this.componentStructure.getUnderlyingVm(domElement) || null;\n },\n getUnderlyingPotencialDraggableComponent: function getUnderlyingPotencialDraggableComponent(htmElement) {\n //TODO check case where you need to see component children\n return htmElement.__draggable_component__;\n },\n emitChanges: function emitChanges(evt) {\n var _this5 = this;\n\n Object(external_commonjs_vue_commonjs2_vue_root_Vue_[\"nextTick\"])(function () {\n return _this5.$emit(\"change\", evt);\n });\n },\n alterList: function alterList(onList) {\n if (this.list) {\n onList(this.list);\n return;\n }\n\n var newList = _toConsumableArray(this.modelValue);\n\n onList(newList);\n this.$emit(\"update:modelValue\", newList);\n },\n spliceList: function spliceList() {\n var _arguments = arguments;\n\n var spliceList = function spliceList(list) {\n return list.splice.apply(list, _toConsumableArray(_arguments));\n };\n\n this.alterList(spliceList);\n },\n updatePosition: function updatePosition(oldIndex, newIndex) {\n var updatePosition = function updatePosition(list) {\n return list.splice(newIndex, 0, list.splice(oldIndex, 1)[0]);\n };\n\n this.alterList(updatePosition);\n },\n getRelatedContextFromMoveEvent: function getRelatedContextFromMoveEvent(_ref3) {\n var to = _ref3.to,\n related = _ref3.related;\n var component = this.getUnderlyingPotencialDraggableComponent(to);\n\n if (!component) {\n return {\n component: component\n };\n }\n\n var list = component.realList;\n var context = {\n list: list,\n component: component\n };\n\n if (to !== related && list) {\n var destination = component.getUnderlyingVm(related) || {};\n return _objectSpread2(_objectSpread2({}, destination), context);\n }\n\n return context;\n },\n getVmIndexFromDomIndex: function getVmIndexFromDomIndex(domIndex) {\n return this.componentStructure.getVmIndexFromDomIndex(domIndex, this.targetDomElement);\n },\n onDragStart: function onDragStart(evt) {\n this.context = this.getUnderlyingVm(evt.item);\n evt.item._underlying_vm_ = this.clone(this.context.element);\n draggingElement = evt.item;\n },\n onDragAdd: function onDragAdd(evt) {\n var element = evt.item._underlying_vm_;\n\n if (element === undefined) {\n return;\n }\n\n removeNode(evt.item);\n var newIndex = this.getVmIndexFromDomIndex(evt.newIndex);\n this.spliceList(newIndex, 0, element);\n var added = {\n element: element,\n newIndex: newIndex\n };\n this.emitChanges({\n added: added\n });\n },\n onDragRemove: function onDragRemove(evt) {\n insertNodeAt(this.$el, evt.item, evt.oldIndex);\n\n if (evt.pullMode === \"clone\") {\n removeNode(evt.clone);\n return;\n }\n\n var _this$context = this.context,\n oldIndex = _this$context.index,\n element = _this$context.element;\n this.spliceList(oldIndex, 1);\n var removed = {\n element: element,\n oldIndex: oldIndex\n };\n this.emitChanges({\n removed: removed\n });\n },\n onDragUpdate: function onDragUpdate(evt) {\n removeNode(evt.item);\n insertNodeAt(evt.from, evt.item, evt.oldIndex);\n var oldIndex = this.context.index;\n var newIndex = this.getVmIndexFromDomIndex(evt.newIndex);\n this.updatePosition(oldIndex, newIndex);\n var moved = {\n element: this.context.element,\n oldIndex: oldIndex,\n newIndex: newIndex\n };\n this.emitChanges({\n moved: moved\n });\n },\n computeFutureIndex: function computeFutureIndex(relatedContext, evt) {\n if (!relatedContext.element) {\n return 0;\n }\n\n var domChildren = _toConsumableArray(evt.to.children).filter(function (el) {\n return el.style[\"display\"] !== \"none\";\n });\n\n var currentDomIndex = domChildren.indexOf(evt.related);\n var currentIndex = relatedContext.component.getVmIndexFromDomIndex(currentDomIndex);\n var draggedInList = domChildren.indexOf(draggingElement) !== -1;\n return draggedInList || !evt.willInsertAfter ? currentIndex : currentIndex + 1;\n },\n onDragMove: function onDragMove(evt, originalEvent) {\n var move = this.move,\n realList = this.realList;\n\n if (!move || !realList) {\n return true;\n }\n\n var relatedContext = this.getRelatedContextFromMoveEvent(evt);\n var futureIndex = this.computeFutureIndex(relatedContext, evt);\n\n var draggedContext = _objectSpread2(_objectSpread2({}, this.context), {}, {\n futureIndex: futureIndex\n });\n\n var sendEvent = _objectSpread2(_objectSpread2({}, evt), {}, {\n relatedContext: relatedContext,\n draggedContext: draggedContext\n });\n\n return move(sendEvent, originalEvent);\n },\n onDragEnd: function onDragEnd() {\n draggingElement = null;\n }\n }\n});\n/* harmony default export */ var vuedraggable = (draggableComponent);\n// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js\n\n\n/* harmony default export */ var entry_lib = __webpack_exports__[\"default\"] = (vuedraggable);\n\n\n\n/***/ }),\n\n/***/ \"fb6a\":\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\nvar $ = __webpack_require__(\"23e7\");\nvar isObject = __webpack_require__(\"861d\");\nvar isArray = __webpack_require__(\"e8b5\");\nvar toAbsoluteIndex = __webpack_require__(\"23cb\");\nvar toLength = __webpack_require__(\"50c4\");\nvar toIndexedObject = __webpack_require__(\"fc6a\");\nvar createProperty = __webpack_require__(\"8418\");\nvar wellKnownSymbol = __webpack_require__(\"b622\");\nvar arrayMethodHasSpeciesSupport = __webpack_require__(\"1dde\");\nvar arrayMethodUsesToLength = __webpack_require__(\"ae40\");\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('slice');\nvar USES_TO_LENGTH = arrayMethodUsesToLength('slice', { ACCESSORS: true, 0: 0, 1: 2 });\n\nvar SPECIES = wellKnownSymbol('species');\nvar nativeSlice = [].slice;\nvar max = Math.max;\n\n// `Array.prototype.slice` method\n// https://tc39.github.io/ecma262/#sec-array.prototype.slice\n// fallback for not array-like ES3 strings and DOM objects\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT || !USES_TO_LENGTH }, {\n slice: function slice(start, end) {\n var O = toIndexedObject(this);\n var length = toLength(O.length);\n var k = toAbsoluteIndex(start, length);\n var fin = toAbsoluteIndex(end === undefined ? length : end, length);\n // inline `ArraySpeciesCreate` for usage native `Array#slice` where it's possible\n var Constructor, result, n;\n if (isArray(O)) {\n Constructor = O.constructor;\n // cross-realm fallback\n if (typeof Constructor == 'function' && (Constructor === Array || isArray(Constructor.prototype))) {\n Constructor = undefined;\n } else if (isObject(Constructor)) {\n Constructor = Constructor[SPECIES];\n if (Constructor === null) Constructor = undefined;\n }\n if (Constructor === Array || Constructor === undefined) {\n return nativeSlice.call(O, k, fin);\n }\n }\n result = new (Constructor === undefined ? Array : Constructor)(max(fin - k, 0));\n for (n = 0; k < fin; k++, n++) if (k in O) createProperty(result, n, O[k]);\n result.length = n;\n return result;\n }\n});\n\n\n/***/ }),\n\n/***/ \"fc6a\":\n/***/ (function(module, exports, __webpack_require__) {\n\n// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = __webpack_require__(\"44ad\");\nvar requireObjectCoercible = __webpack_require__(\"1d80\");\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n\n\n/***/ }),\n\n/***/ \"fdbc\":\n/***/ (function(module, exports) {\n\n// iterable DOM collections\n// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods\nmodule.exports = {\n CSSRuleList: 0,\n CSSStyleDeclaration: 0,\n CSSValueList: 0,\n ClientRectList: 0,\n DOMRectList: 0,\n DOMStringList: 0,\n DOMTokenList: 1,\n DataTransferItemList: 0,\n FileList: 0,\n HTMLAllCollection: 0,\n HTMLCollection: 0,\n HTMLFormElement: 0,\n HTMLSelectElement: 0,\n MediaList: 0,\n MimeTypeArray: 0,\n NamedNodeMap: 0,\n NodeList: 1,\n PaintRequestList: 0,\n Plugin: 0,\n PluginArray: 0,\n SVGLengthList: 0,\n SVGNumberList: 0,\n SVGPathSegList: 0,\n SVGPointList: 0,\n SVGStringList: 0,\n SVGTransformList: 0,\n SourceBufferList: 0,\n StyleSheetList: 0,\n TextTrackCueList: 0,\n TextTrackList: 0,\n TouchList: 0\n};\n\n\n/***/ }),\n\n/***/ \"fdbf\":\n/***/ (function(module, exports, __webpack_require__) {\n\nvar NATIVE_SYMBOL = __webpack_require__(\"4930\");\n\nmodule.exports = NATIVE_SYMBOL\n // eslint-disable-next-line no-undef\n && !Symbol.sham\n // eslint-disable-next-line no-undef\n && typeof Symbol.iterator == 'symbol';\n\n\n/***/ })\n\n/******/ })[\"default\"];\n});\n//# sourceMappingURL=vuedraggable.umd.js.map","export let createNanoEvents = () => ({\n events: {},\n emit(event, ...args) {\n ;(this.events[event] || []).forEach(i => i(...args))\n },\n on(event, cb) {\n ;(this.events[event] = this.events[event] || []).push(cb)\n return () =>\n (this.events[event] = (this.events[event] || []).filter(i => i !== cb))\n }\n})\n","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","var __defProp = Object.defineProperty;\nvar __getOwnPropSymbols = Object.getOwnPropertySymbols;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __propIsEnum = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues = (a, b) => {\n for (var prop in b || (b = {}))\n if (__hasOwnProp.call(b, prop))\n __defNormalProp(a, prop, b[prop]);\n if (__getOwnPropSymbols)\n for (var prop of __getOwnPropSymbols(b)) {\n if (__propIsEnum.call(b, prop))\n __defNormalProp(a, prop, b[prop]);\n }\n return a;\n};\n\n// src/index.ts\nimport { provide, inject, getCurrentInstance } from \"vue\";\n\n// src/ts/interface.ts\nimport { createApp, nextTick } from \"vue\";\n\n// src/ts/utils.ts\nimport { defineComponent, toRaw, unref } from \"vue\";\nvar isFunction = (value) => typeof value === \"function\";\nvar isString = (value) => typeof value === \"string\";\nvar isNonEmptyString = (value) => isString(value) && value.trim().length > 0;\nvar isNumber = (value) => typeof value === \"number\";\nvar isUndefined = (value) => typeof value === \"undefined\";\nvar isObject = (value) => typeof value === \"object\" && value !== null;\nvar isJSX = (obj) => hasProp(obj, \"tag\") && isNonEmptyString(obj.tag);\nvar isTouchEvent = (event) => window.TouchEvent && event instanceof TouchEvent;\nvar isToastComponent = (obj) => hasProp(obj, \"component\") && isToastContent(obj.component);\nvar isVueComponent = (c) => isFunction(c) || isObject(c);\nvar isToastContent = (obj) => !isUndefined(obj) && (isString(obj) || isVueComponent(obj) || isToastComponent(obj));\nvar isDOMRect = (obj) => isObject(obj) && [\"height\", \"width\", \"right\", \"left\", \"top\", \"bottom\"].every((p) => isNumber(obj[p]));\nvar hasProp = (obj, propKey) => (isObject(obj) || isFunction(obj)) && propKey in obj;\nvar getId = ((i) => () => i++)(0);\nfunction getX(event) {\n return isTouchEvent(event) ? event.targetTouches[0].clientX : event.clientX;\n}\nfunction getY(event) {\n return isTouchEvent(event) ? event.targetTouches[0].clientY : event.clientY;\n}\nvar removeElement = (el) => {\n if (!isUndefined(el.remove)) {\n el.remove();\n } else if (el.parentNode) {\n el.parentNode.removeChild(el);\n }\n};\nvar getVueComponentFromObj = (obj) => {\n if (isToastComponent(obj)) {\n return getVueComponentFromObj(obj.component);\n }\n if (isJSX(obj)) {\n return defineComponent({\n render() {\n return obj;\n }\n });\n }\n return typeof obj === \"string\" ? obj : toRaw(unref(obj));\n};\nvar normalizeToastComponent = (obj) => {\n if (typeof obj === \"string\") {\n return obj;\n }\n const props = hasProp(obj, \"props\") && isObject(obj.props) ? obj.props : {};\n const listeners = hasProp(obj, \"listeners\") && isObject(obj.listeners) ? obj.listeners : {};\n return { component: getVueComponentFromObj(obj), props, listeners };\n};\nvar isBrowser = () => typeof window !== \"undefined\";\n\n// src/ts/eventBus.ts\nvar EventBus = class {\n constructor() {\n this.allHandlers = {};\n }\n getHandlers(eventType) {\n return this.allHandlers[eventType] || [];\n }\n on(eventType, handler) {\n const handlers = this.getHandlers(eventType);\n handlers.push(handler);\n this.allHandlers[eventType] = handlers;\n }\n off(eventType, handler) {\n const handlers = this.getHandlers(eventType);\n handlers.splice(handlers.indexOf(handler) >>> 0, 1);\n }\n emit(eventType, event) {\n const handlers = this.getHandlers(eventType);\n handlers.forEach((handler) => handler(event));\n }\n};\nvar isEventBusInterface = (e) => [\"on\", \"off\", \"emit\"].every((f) => hasProp(e, f) && isFunction(e[f]));\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue?vue&type=script\nimport { defineComponent as defineComponent7 } from \"vue\";\n\n// src/ts/constants.ts\nvar TYPE;\n(function(TYPE2) {\n TYPE2[\"SUCCESS\"] = \"success\";\n TYPE2[\"ERROR\"] = \"error\";\n TYPE2[\"WARNING\"] = \"warning\";\n TYPE2[\"INFO\"] = \"info\";\n TYPE2[\"DEFAULT\"] = \"default\";\n})(TYPE || (TYPE = {}));\nvar POSITION;\n(function(POSITION2) {\n POSITION2[\"TOP_LEFT\"] = \"top-left\";\n POSITION2[\"TOP_CENTER\"] = \"top-center\";\n POSITION2[\"TOP_RIGHT\"] = \"top-right\";\n POSITION2[\"BOTTOM_LEFT\"] = \"bottom-left\";\n POSITION2[\"BOTTOM_CENTER\"] = \"bottom-center\";\n POSITION2[\"BOTTOM_RIGHT\"] = \"bottom-right\";\n})(POSITION || (POSITION = {}));\nvar EVENTS;\n(function(EVENTS2) {\n EVENTS2[\"ADD\"] = \"add\";\n EVENTS2[\"DISMISS\"] = \"dismiss\";\n EVENTS2[\"UPDATE\"] = \"update\";\n EVENTS2[\"CLEAR\"] = \"clear\";\n EVENTS2[\"UPDATE_DEFAULTS\"] = \"update_defaults\";\n})(EVENTS || (EVENTS = {}));\nvar VT_NAMESPACE = \"Vue-Toastification\";\n\n// src/ts/propValidators.ts\nvar COMMON = {\n type: {\n type: String,\n default: TYPE.DEFAULT\n },\n classNames: {\n type: [String, Array],\n default: () => []\n },\n trueBoolean: {\n type: Boolean,\n default: true\n }\n};\nvar ICON = {\n type: COMMON.type,\n customIcon: {\n type: [String, Boolean, Object, Function],\n default: true\n }\n};\nvar CLOSE_BUTTON = {\n component: {\n type: [String, Object, Function, Boolean],\n default: \"button\"\n },\n classNames: COMMON.classNames,\n showOnHover: {\n type: Boolean,\n default: false\n },\n ariaLabel: {\n type: String,\n default: \"close\"\n }\n};\nvar PROGRESS_BAR = {\n timeout: {\n type: [Number, Boolean],\n default: 5e3\n },\n hideProgressBar: {\n type: Boolean,\n default: false\n },\n isRunning: {\n type: Boolean,\n default: false\n }\n};\nvar TRANSITION = {\n transition: {\n type: [Object, String],\n default: `${VT_NAMESPACE}__bounce`\n }\n};\nvar CORE_TOAST = {\n position: {\n type: String,\n default: POSITION.TOP_RIGHT\n },\n draggable: COMMON.trueBoolean,\n draggablePercent: {\n type: Number,\n default: 0.6\n },\n pauseOnFocusLoss: COMMON.trueBoolean,\n pauseOnHover: COMMON.trueBoolean,\n closeOnClick: COMMON.trueBoolean,\n timeout: PROGRESS_BAR.timeout,\n hideProgressBar: PROGRESS_BAR.hideProgressBar,\n toastClassName: COMMON.classNames,\n bodyClassName: COMMON.classNames,\n icon: ICON.customIcon,\n closeButton: CLOSE_BUTTON.component,\n closeButtonClassName: CLOSE_BUTTON.classNames,\n showCloseButtonOnHover: CLOSE_BUTTON.showOnHover,\n accessibility: {\n type: Object,\n default: () => ({\n toastRole: \"alert\",\n closeButtonLabel: \"close\"\n })\n },\n rtl: {\n type: Boolean,\n default: false\n },\n eventBus: {\n type: Object,\n required: false,\n default: () => new EventBus()\n }\n};\nvar TOAST = {\n id: {\n type: [String, Number],\n required: true,\n default: 0\n },\n type: COMMON.type,\n content: {\n type: [String, Object, Function],\n required: true,\n default: \"\"\n },\n onClick: {\n type: Function,\n default: void 0\n },\n onClose: {\n type: Function,\n default: void 0\n }\n};\nvar CONTAINER = {\n container: {\n type: [\n Object,\n Function\n ],\n default: () => document.body\n },\n newestOnTop: COMMON.trueBoolean,\n maxToasts: {\n type: Number,\n default: 20\n },\n transition: TRANSITION.transition,\n toastDefaults: Object,\n filterBeforeCreate: {\n type: Function,\n default: (toast) => toast\n },\n filterToasts: {\n type: Function,\n default: (toasts) => toasts\n },\n containerClassName: COMMON.classNames,\n onMounted: Function,\n shareAppContext: [Boolean, Object]\n};\nvar propValidators_default = {\n CORE_TOAST,\n TOAST,\n CONTAINER,\n PROGRESS_BAR,\n ICON,\n TRANSITION,\n CLOSE_BUTTON\n};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue?vue&type=script\nimport { defineComponent as defineComponent5 } from \"vue\";\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtProgressBar.vue?vue&type=script\nimport { defineComponent as defineComponent2 } from \"vue\";\nvar VtProgressBar_default = defineComponent2({\n name: \"VtProgressBar\",\n props: propValidators_default.PROGRESS_BAR,\n data() {\n return {\n hasClass: true\n };\n },\n computed: {\n style() {\n return {\n animationDuration: `${this.timeout}ms`,\n animationPlayState: this.isRunning ? \"running\" : \"paused\",\n opacity: this.hideProgressBar ? 0 : 1\n };\n },\n cpClass() {\n return this.hasClass ? `${VT_NAMESPACE}__progress-bar` : \"\";\n }\n },\n watch: {\n timeout() {\n this.hasClass = false;\n this.$nextTick(() => this.hasClass = true);\n }\n },\n mounted() {\n this.$el.addEventListener(\"animationend\", this.animationEnded);\n },\n beforeUnmount() {\n this.$el.removeEventListener(\"animationend\", this.animationEnded);\n },\n methods: {\n animationEnded() {\n this.$emit(\"close-toast\");\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtProgressBar.vue?vue&type=template\nimport { normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\";\nfunction render(_ctx, _cache) {\n return _openBlock(), _createElementBlock(\"div\", {\n style: _normalizeStyle(_ctx.style),\n class: _normalizeClass(_ctx.cpClass)\n }, null, 6);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtProgressBar.vue\nVtProgressBar_default.render = render;\nvar VtProgressBar_default2 = VtProgressBar_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtCloseButton.vue?vue&type=script\nimport { defineComponent as defineComponent3 } from \"vue\";\nvar VtCloseButton_default = defineComponent3({\n name: \"VtCloseButton\",\n props: propValidators_default.CLOSE_BUTTON,\n computed: {\n buttonComponent() {\n if (this.component !== false) {\n return getVueComponentFromObj(this.component);\n }\n return \"button\";\n },\n classes() {\n const classes = [`${VT_NAMESPACE}__close-button`];\n if (this.showOnHover) {\n classes.push(\"show-on-hover\");\n }\n return classes.concat(this.classNames);\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtCloseButton.vue?vue&type=template\nimport { createTextVNode as _createTextVNode, resolveDynamicComponent as _resolveDynamicComponent, mergeProps as _mergeProps, withCtx as _withCtx, openBlock as _openBlock2, createBlock as _createBlock } from \"vue\";\nvar _hoisted_1 = /* @__PURE__ */ _createTextVNode(\" \\xD7 \");\nfunction render2(_ctx, _cache) {\n return _openBlock2(), _createBlock(_resolveDynamicComponent(_ctx.buttonComponent), _mergeProps({\n \"aria-label\": _ctx.ariaLabel,\n class: _ctx.classes\n }, _ctx.$attrs), {\n default: _withCtx(() => [\n _hoisted_1\n ]),\n _: 1\n }, 16, [\"aria-label\", \"class\"]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtCloseButton.vue\nVtCloseButton_default.render = render2;\nvar VtCloseButton_default2 = VtCloseButton_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue?vue&type=script\nimport { defineComponent as defineComponent4 } from \"vue\";\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtSuccessIcon.vue?vue&type=script\nvar VtSuccessIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtSuccessIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode, openBlock as _openBlock3, createElementBlock as _createElementBlock2 } from \"vue\";\nvar _hoisted_12 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"check-circle\",\n class: \"svg-inline--fa fa-check-circle fa-w-16\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 512 512\"\n};\nvar _hoisted_2 = /* @__PURE__ */ _createElementVNode(\"path\", {\n fill: \"currentColor\",\n d: \"M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z\"\n}, null, -1);\nvar _hoisted_3 = [\n _hoisted_2\n];\nfunction render3(_ctx, _cache) {\n return _openBlock3(), _createElementBlock2(\"svg\", _hoisted_12, _hoisted_3);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtSuccessIcon.vue\nVtSuccessIcon_default.render = render3;\nvar VtSuccessIcon_default2 = VtSuccessIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtInfoIcon.vue?vue&type=script\nvar VtInfoIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtInfoIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode2, openBlock as _openBlock4, createElementBlock as _createElementBlock3 } from \"vue\";\nvar _hoisted_13 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"info-circle\",\n class: \"svg-inline--fa fa-info-circle fa-w-16\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 512 512\"\n};\nvar _hoisted_22 = /* @__PURE__ */ _createElementVNode2(\"path\", {\n fill: \"currentColor\",\n d: \"M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z\"\n}, null, -1);\nvar _hoisted_32 = [\n _hoisted_22\n];\nfunction render4(_ctx, _cache) {\n return _openBlock4(), _createElementBlock3(\"svg\", _hoisted_13, _hoisted_32);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtInfoIcon.vue\nVtInfoIcon_default.render = render4;\nvar VtInfoIcon_default2 = VtInfoIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtWarningIcon.vue?vue&type=script\nvar VtWarningIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtWarningIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode3, openBlock as _openBlock5, createElementBlock as _createElementBlock4 } from \"vue\";\nvar _hoisted_14 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"exclamation-circle\",\n class: \"svg-inline--fa fa-exclamation-circle fa-w-16\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 512 512\"\n};\nvar _hoisted_23 = /* @__PURE__ */ _createElementVNode3(\"path\", {\n fill: \"currentColor\",\n d: \"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z\"\n}, null, -1);\nvar _hoisted_33 = [\n _hoisted_23\n];\nfunction render5(_ctx, _cache) {\n return _openBlock5(), _createElementBlock4(\"svg\", _hoisted_14, _hoisted_33);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtWarningIcon.vue\nVtWarningIcon_default.render = render5;\nvar VtWarningIcon_default2 = VtWarningIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtErrorIcon.vue?vue&type=script\nvar VtErrorIcon_default = {};\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtErrorIcon.vue?vue&type=template\nimport { createElementVNode as _createElementVNode4, openBlock as _openBlock6, createElementBlock as _createElementBlock5 } from \"vue\";\nvar _hoisted_15 = {\n \"aria-hidden\": \"true\",\n focusable: \"false\",\n \"data-prefix\": \"fas\",\n \"data-icon\": \"exclamation-triangle\",\n class: \"svg-inline--fa fa-exclamation-triangle fa-w-18\",\n role: \"img\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 576 512\"\n};\nvar _hoisted_24 = /* @__PURE__ */ _createElementVNode4(\"path\", {\n fill: \"currentColor\",\n d: \"M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z\"\n}, null, -1);\nvar _hoisted_34 = [\n _hoisted_24\n];\nfunction render6(_ctx, _cache) {\n return _openBlock6(), _createElementBlock5(\"svg\", _hoisted_15, _hoisted_34);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/icons/VtErrorIcon.vue\nVtErrorIcon_default.render = render6;\nvar VtErrorIcon_default2 = VtErrorIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue?vue&type=script\nvar VtIcon_default = defineComponent4({\n name: \"VtIcon\",\n props: propValidators_default.ICON,\n computed: {\n customIconChildren() {\n return hasProp(this.customIcon, \"iconChildren\") ? this.trimValue(this.customIcon.iconChildren) : \"\";\n },\n customIconClass() {\n if (isString(this.customIcon)) {\n return this.trimValue(this.customIcon);\n } else if (hasProp(this.customIcon, \"iconClass\")) {\n return this.trimValue(this.customIcon.iconClass);\n }\n return \"\";\n },\n customIconTag() {\n if (hasProp(this.customIcon, \"iconTag\")) {\n return this.trimValue(this.customIcon.iconTag, \"i\");\n }\n return \"i\";\n },\n hasCustomIcon() {\n return this.customIconClass.length > 0;\n },\n component() {\n if (this.hasCustomIcon) {\n return this.customIconTag;\n }\n if (isToastContent(this.customIcon)) {\n return getVueComponentFromObj(this.customIcon);\n }\n return this.iconTypeComponent;\n },\n iconTypeComponent() {\n const types = {\n [TYPE.DEFAULT]: VtInfoIcon_default2,\n [TYPE.INFO]: VtInfoIcon_default2,\n [TYPE.SUCCESS]: VtSuccessIcon_default2,\n [TYPE.ERROR]: VtErrorIcon_default2,\n [TYPE.WARNING]: VtWarningIcon_default2\n };\n return types[this.type];\n },\n iconClasses() {\n const classes = [`${VT_NAMESPACE}__icon`];\n if (this.hasCustomIcon) {\n return classes.concat(this.customIconClass);\n }\n return classes;\n }\n },\n methods: {\n trimValue(value, empty = \"\") {\n return isNonEmptyString(value) ? value.trim() : empty;\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue?vue&type=template\nimport { toDisplayString as _toDisplayString, createTextVNode as _createTextVNode2, resolveDynamicComponent as _resolveDynamicComponent2, normalizeClass as _normalizeClass2, withCtx as _withCtx2, openBlock as _openBlock7, createBlock as _createBlock2 } from \"vue\";\nfunction render7(_ctx, _cache) {\n return _openBlock7(), _createBlock2(_resolveDynamicComponent2(_ctx.component), {\n class: _normalizeClass2(_ctx.iconClasses)\n }, {\n default: _withCtx2(() => [\n _createTextVNode2(_toDisplayString(_ctx.customIconChildren), 1)\n ]),\n _: 1\n }, 8, [\"class\"]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtIcon.vue\nVtIcon_default.render = render7;\nvar VtIcon_default2 = VtIcon_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue?vue&type=script\nvar VtToast_default = defineComponent5({\n name: \"VtToast\",\n components: { ProgressBar: VtProgressBar_default2, CloseButton: VtCloseButton_default2, Icon: VtIcon_default2 },\n inheritAttrs: false,\n props: Object.assign({}, propValidators_default.CORE_TOAST, propValidators_default.TOAST),\n data() {\n const data = {\n isRunning: true,\n disableTransitions: false,\n beingDragged: false,\n dragStart: 0,\n dragPos: { x: 0, y: 0 },\n dragRect: {}\n };\n return data;\n },\n computed: {\n classes() {\n const classes = [\n `${VT_NAMESPACE}__toast`,\n `${VT_NAMESPACE}__toast--${this.type}`,\n `${this.position}`\n ].concat(this.toastClassName);\n if (this.disableTransitions) {\n classes.push(\"disable-transition\");\n }\n if (this.rtl) {\n classes.push(`${VT_NAMESPACE}__toast--rtl`);\n }\n return classes;\n },\n bodyClasses() {\n const classes = [\n `${VT_NAMESPACE}__toast-${isString(this.content) ? \"body\" : \"component-body\"}`\n ].concat(this.bodyClassName);\n return classes;\n },\n draggableStyle() {\n if (this.dragStart === this.dragPos.x) {\n return {};\n } else if (this.beingDragged) {\n return {\n transform: `translateX(${this.dragDelta}px)`,\n opacity: 1 - Math.abs(this.dragDelta / this.removalDistance)\n };\n } else {\n return {\n transition: \"transform 0.2s, opacity 0.2s\",\n transform: \"translateX(0)\",\n opacity: 1\n };\n }\n },\n dragDelta() {\n return this.beingDragged ? this.dragPos.x - this.dragStart : 0;\n },\n removalDistance() {\n if (isDOMRect(this.dragRect)) {\n return (this.dragRect.right - this.dragRect.left) * this.draggablePercent;\n }\n return 0;\n }\n },\n mounted() {\n if (this.draggable) {\n this.draggableSetup();\n }\n if (this.pauseOnFocusLoss) {\n this.focusSetup();\n }\n },\n beforeUnmount() {\n if (this.draggable) {\n this.draggableCleanup();\n }\n if (this.pauseOnFocusLoss) {\n this.focusCleanup();\n }\n },\n methods: {\n hasProp,\n getVueComponentFromObj,\n closeToast() {\n this.eventBus.emit(EVENTS.DISMISS, this.id);\n },\n clickHandler() {\n if (this.onClick) {\n this.onClick(this.closeToast);\n }\n if (this.closeOnClick) {\n if (!this.beingDragged || this.dragStart === this.dragPos.x) {\n this.closeToast();\n }\n }\n },\n timeoutHandler() {\n this.closeToast();\n },\n hoverPause() {\n if (this.pauseOnHover) {\n this.isRunning = false;\n }\n },\n hoverPlay() {\n if (this.pauseOnHover) {\n this.isRunning = true;\n }\n },\n focusPause() {\n this.isRunning = false;\n },\n focusPlay() {\n this.isRunning = true;\n },\n focusSetup() {\n addEventListener(\"blur\", this.focusPause);\n addEventListener(\"focus\", this.focusPlay);\n },\n focusCleanup() {\n removeEventListener(\"blur\", this.focusPause);\n removeEventListener(\"focus\", this.focusPlay);\n },\n draggableSetup() {\n const element = this.$el;\n element.addEventListener(\"touchstart\", this.onDragStart, {\n passive: true\n });\n element.addEventListener(\"mousedown\", this.onDragStart);\n addEventListener(\"touchmove\", this.onDragMove, { passive: false });\n addEventListener(\"mousemove\", this.onDragMove);\n addEventListener(\"touchend\", this.onDragEnd);\n addEventListener(\"mouseup\", this.onDragEnd);\n },\n draggableCleanup() {\n const element = this.$el;\n element.removeEventListener(\"touchstart\", this.onDragStart);\n element.removeEventListener(\"mousedown\", this.onDragStart);\n removeEventListener(\"touchmove\", this.onDragMove);\n removeEventListener(\"mousemove\", this.onDragMove);\n removeEventListener(\"touchend\", this.onDragEnd);\n removeEventListener(\"mouseup\", this.onDragEnd);\n },\n onDragStart(event) {\n this.beingDragged = true;\n this.dragPos = { x: getX(event), y: getY(event) };\n this.dragStart = getX(event);\n this.dragRect = this.$el.getBoundingClientRect();\n },\n onDragMove(event) {\n if (this.beingDragged) {\n event.preventDefault();\n if (this.isRunning) {\n this.isRunning = false;\n }\n this.dragPos = { x: getX(event), y: getY(event) };\n }\n },\n onDragEnd() {\n if (this.beingDragged) {\n if (Math.abs(this.dragDelta) >= this.removalDistance) {\n this.disableTransitions = true;\n this.$nextTick(() => this.closeToast());\n } else {\n setTimeout(() => {\n this.beingDragged = false;\n if (isDOMRect(this.dragRect) && this.pauseOnHover && this.dragRect.bottom >= this.dragPos.y && this.dragPos.y >= this.dragRect.top && this.dragRect.left <= this.dragPos.x && this.dragPos.x <= this.dragRect.right) {\n this.isRunning = false;\n } else {\n this.isRunning = true;\n }\n });\n }\n }\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue?vue&type=template\nimport { resolveComponent as _resolveComponent, openBlock as _openBlock8, createBlock as _createBlock3, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString2, createTextVNode as _createTextVNode3, Fragment as _Fragment, createElementBlock as _createElementBlock6, resolveDynamicComponent as _resolveDynamicComponent3, toHandlers as _toHandlers, mergeProps as _mergeProps2, normalizeClass as _normalizeClass3, createElementVNode as _createElementVNode5, withModifiers as _withModifiers, normalizeStyle as _normalizeStyle2 } from \"vue\";\nvar _hoisted_16 = [\"role\"];\nfunction render8(_ctx, _cache) {\n const _component_Icon = _resolveComponent(\"Icon\");\n const _component_CloseButton = _resolveComponent(\"CloseButton\");\n const _component_ProgressBar = _resolveComponent(\"ProgressBar\");\n return _openBlock8(), _createElementBlock6(\"div\", {\n class: _normalizeClass3(_ctx.classes),\n style: _normalizeStyle2(_ctx.draggableStyle),\n onClick: _cache[0] || (_cache[0] = (...args) => _ctx.clickHandler && _ctx.clickHandler(...args)),\n onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.hoverPause && _ctx.hoverPause(...args)),\n onMouseleave: _cache[2] || (_cache[2] = (...args) => _ctx.hoverPlay && _ctx.hoverPlay(...args))\n }, [\n _ctx.icon ? (_openBlock8(), _createBlock3(_component_Icon, {\n key: 0,\n \"custom-icon\": _ctx.icon,\n type: _ctx.type\n }, null, 8, [\"custom-icon\", \"type\"])) : _createCommentVNode(\"v-if\", true),\n _createElementVNode5(\"div\", {\n role: _ctx.accessibility.toastRole || \"alert\",\n class: _normalizeClass3(_ctx.bodyClasses)\n }, [\n typeof _ctx.content === \"string\" ? (_openBlock8(), _createElementBlock6(_Fragment, { key: 0 }, [\n _createTextVNode3(_toDisplayString2(_ctx.content), 1)\n ], 2112)) : (_openBlock8(), _createBlock3(_resolveDynamicComponent3(_ctx.getVueComponentFromObj(_ctx.content)), _mergeProps2({\n key: 1,\n \"toast-id\": _ctx.id\n }, _ctx.hasProp(_ctx.content, \"props\") ? _ctx.content.props : {}, _toHandlers(_ctx.hasProp(_ctx.content, \"listeners\") ? _ctx.content.listeners : {}), { onCloseToast: _ctx.closeToast }), null, 16, [\"toast-id\", \"onCloseToast\"]))\n ], 10, _hoisted_16),\n !!_ctx.closeButton ? (_openBlock8(), _createBlock3(_component_CloseButton, {\n key: 1,\n component: _ctx.closeButton,\n \"class-names\": _ctx.closeButtonClassName,\n \"show-on-hover\": _ctx.showCloseButtonOnHover,\n \"aria-label\": _ctx.accessibility.closeButtonLabel,\n onClick: _withModifiers(_ctx.closeToast, [\"stop\"])\n }, null, 8, [\"component\", \"class-names\", \"show-on-hover\", \"aria-label\", \"onClick\"])) : _createCommentVNode(\"v-if\", true),\n _ctx.timeout ? (_openBlock8(), _createBlock3(_component_ProgressBar, {\n key: 2,\n \"is-running\": _ctx.isRunning,\n \"hide-progress-bar\": _ctx.hideProgressBar,\n timeout: _ctx.timeout,\n onCloseToast: _ctx.timeoutHandler\n }, null, 8, [\"is-running\", \"hide-progress-bar\", \"timeout\", \"onCloseToast\"])) : _createCommentVNode(\"v-if\", true)\n ], 38);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToast.vue\nVtToast_default.render = render8;\nvar VtToast_default2 = VtToast_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtTransition.vue?vue&type=script\nimport { defineComponent as defineComponent6 } from \"vue\";\nvar VtTransition_default = defineComponent6({\n name: \"VtTransition\",\n props: propValidators_default.TRANSITION,\n emits: [\"leave\"],\n methods: {\n hasProp,\n leave(el) {\n if (el instanceof HTMLElement) {\n el.style.left = el.offsetLeft + \"px\";\n el.style.top = el.offsetTop + \"px\";\n el.style.width = getComputedStyle(el).width;\n el.style.position = \"absolute\";\n }\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtTransition.vue?vue&type=template\nimport { renderSlot as _renderSlot, TransitionGroup as _TransitionGroup, withCtx as _withCtx3, openBlock as _openBlock9, createBlock as _createBlock4 } from \"vue\";\nfunction render9(_ctx, _cache) {\n return _openBlock9(), _createBlock4(_TransitionGroup, {\n tag: \"div\",\n \"enter-active-class\": _ctx.transition.enter ? _ctx.transition.enter : `${_ctx.transition}-enter-active`,\n \"move-class\": _ctx.transition.move ? _ctx.transition.move : `${_ctx.transition}-move`,\n \"leave-active-class\": _ctx.transition.leave ? _ctx.transition.leave : `${_ctx.transition}-leave-active`,\n onLeave: _ctx.leave\n }, {\n default: _withCtx3(() => [\n _renderSlot(_ctx.$slots, \"default\")\n ]),\n _: 3\n }, 8, [\"enter-active-class\", \"move-class\", \"leave-active-class\", \"onLeave\"]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtTransition.vue\nVtTransition_default.render = render9;\nvar VtTransition_default2 = VtTransition_default;\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue?vue&type=script\nvar VtToastContainer_default = defineComponent7({\n name: \"VueToastification\",\n devtools: {\n hide: true\n },\n components: { Toast: VtToast_default2, VtTransition: VtTransition_default2 },\n props: Object.assign({}, propValidators_default.CORE_TOAST, propValidators_default.CONTAINER, propValidators_default.TRANSITION),\n data() {\n const data = {\n count: 0,\n positions: Object.values(POSITION),\n toasts: {},\n defaults: {}\n };\n return data;\n },\n computed: {\n toastArray() {\n return Object.values(this.toasts);\n },\n filteredToasts() {\n return this.defaults.filterToasts(this.toastArray);\n }\n },\n beforeMount() {\n const events = this.eventBus;\n events.on(EVENTS.ADD, this.addToast);\n events.on(EVENTS.CLEAR, this.clearToasts);\n events.on(EVENTS.DISMISS, this.dismissToast);\n events.on(EVENTS.UPDATE, this.updateToast);\n events.on(EVENTS.UPDATE_DEFAULTS, this.updateDefaults);\n this.defaults = this.$props;\n },\n mounted() {\n this.setup(this.container);\n },\n methods: {\n async setup(container) {\n if (isFunction(container)) {\n container = await container();\n }\n removeElement(this.$el);\n container.appendChild(this.$el);\n },\n setToast(props) {\n if (!isUndefined(props.id)) {\n this.toasts[props.id] = props;\n }\n },\n addToast(params) {\n params.content = normalizeToastComponent(params.content);\n const props = Object.assign({}, this.defaults, params.type && this.defaults.toastDefaults && this.defaults.toastDefaults[params.type], params);\n const toast = this.defaults.filterBeforeCreate(props, this.toastArray);\n toast && this.setToast(toast);\n },\n dismissToast(id) {\n const toast = this.toasts[id];\n if (!isUndefined(toast) && !isUndefined(toast.onClose)) {\n toast.onClose();\n }\n delete this.toasts[id];\n },\n clearToasts() {\n Object.keys(this.toasts).forEach((id) => {\n this.dismissToast(id);\n });\n },\n getPositionToasts(position) {\n const toasts = this.filteredToasts.filter((toast) => toast.position === position).slice(0, this.defaults.maxToasts);\n return this.defaults.newestOnTop ? toasts.reverse() : toasts;\n },\n updateDefaults(update) {\n if (!isUndefined(update.container)) {\n this.setup(update.container);\n }\n this.defaults = Object.assign({}, this.defaults, update);\n },\n updateToast({\n id,\n options,\n create\n }) {\n if (this.toasts[id]) {\n if (options.timeout && options.timeout === this.toasts[id].timeout) {\n options.timeout++;\n }\n this.setToast(Object.assign({}, this.toasts[id], options));\n } else if (create) {\n this.addToast(Object.assign({}, { id }, options));\n }\n },\n getClasses(position) {\n const classes = [`${VT_NAMESPACE}__container`, position];\n return classes.concat(this.defaults.containerClassName);\n }\n }\n});\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue?vue&type=template\nimport { renderList as _renderList, Fragment as _Fragment2, openBlock as _openBlock10, createElementBlock as _createElementBlock7, resolveComponent as _resolveComponent2, mergeProps as _mergeProps3, createBlock as _createBlock5, normalizeClass as _normalizeClass4, withCtx as _withCtx4, createVNode as _createVNode } from \"vue\";\nfunction render10(_ctx, _cache) {\n const _component_Toast = _resolveComponent2(\"Toast\");\n const _component_VtTransition = _resolveComponent2(\"VtTransition\");\n return _openBlock10(), _createElementBlock7(\"div\", null, [\n (_openBlock10(true), _createElementBlock7(_Fragment2, null, _renderList(_ctx.positions, (pos) => {\n return _openBlock10(), _createElementBlock7(\"div\", { key: pos }, [\n _createVNode(_component_VtTransition, {\n transition: _ctx.defaults.transition,\n class: _normalizeClass4(_ctx.getClasses(pos))\n }, {\n default: _withCtx4(() => [\n (_openBlock10(true), _createElementBlock7(_Fragment2, null, _renderList(_ctx.getPositionToasts(pos), (toast) => {\n return _openBlock10(), _createBlock5(_component_Toast, _mergeProps3({\n key: toast.id\n }, toast), null, 16);\n }), 128))\n ]),\n _: 2\n }, 1032, [\"transition\", \"class\"])\n ]);\n }), 128))\n ]);\n}\n\n// vue:/Users/maronato/Developer/vue-toastification/src/components/VtToastContainer.vue\nVtToastContainer_default.render = render10;\nvar VtToastContainer_default2 = VtToastContainer_default;\n\n// src/ts/interface.ts\nvar buildInterface = (globalOptions = {}, mountContainer = true) => {\n const events = globalOptions.eventBus = globalOptions.eventBus || new EventBus();\n if (mountContainer) {\n nextTick(() => {\n const app = createApp(VtToastContainer_default2, __spreadValues({}, globalOptions));\n const component = app.mount(document.createElement(\"div\"));\n const onMounted = globalOptions.onMounted;\n if (!isUndefined(onMounted)) {\n onMounted(component, app);\n }\n if (globalOptions.shareAppContext) {\n const baseApp = globalOptions.shareAppContext;\n if (baseApp === true) {\n console.warn(`[${VT_NAMESPACE}] App to share context with was not provided.`);\n } else {\n app._context.components = baseApp._context.components;\n app._context.directives = baseApp._context.directives;\n app._context.mixins = baseApp._context.mixins;\n app._context.provides = baseApp._context.provides;\n app.config.globalProperties = baseApp.config.globalProperties;\n }\n }\n });\n }\n const toast = (content, options) => {\n const props = Object.assign({}, { id: getId(), type: TYPE.DEFAULT }, options, {\n content\n });\n events.emit(EVENTS.ADD, props);\n return props.id;\n };\n toast.clear = () => events.emit(EVENTS.CLEAR, void 0);\n toast.updateDefaults = (update) => {\n events.emit(EVENTS.UPDATE_DEFAULTS, update);\n };\n toast.dismiss = (id) => {\n events.emit(EVENTS.DISMISS, id);\n };\n function updateToast(id, { content, options }, create = false) {\n const opt = Object.assign({}, options, { content });\n events.emit(EVENTS.UPDATE, {\n id,\n options: opt,\n create\n });\n }\n toast.update = updateToast;\n toast.success = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.SUCCESS }));\n toast.info = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.INFO }));\n toast.error = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.ERROR }));\n toast.warning = (content, options) => toast(content, Object.assign({}, options, { type: TYPE.WARNING }));\n return toast;\n};\n\n// src/index.ts\nvar createMockToastInterface = () => {\n const toast = () => console.warn(`[${VT_NAMESPACE}] This plugin does not support SSR!`);\n return new Proxy(toast, {\n get() {\n return toast;\n }\n });\n};\nfunction createToastInterface(optionsOrEventBus) {\n if (!isBrowser()) {\n return createMockToastInterface();\n }\n if (isEventBusInterface(optionsOrEventBus)) {\n return buildInterface({ eventBus: optionsOrEventBus }, false);\n }\n return buildInterface(optionsOrEventBus, true);\n}\nvar toastInjectionKey = Symbol(\"VueToastification\");\nvar globalEventBus = new EventBus();\nvar VueToastificationPlugin = (App, options) => {\n if ((options == null ? void 0 : options.shareAppContext) === true) {\n options.shareAppContext = App;\n }\n const inter = createToastInterface(__spreadValues({\n eventBus: globalEventBus\n }, options));\n App.provide(toastInjectionKey, inter);\n};\nvar provideToast = (options) => {\n const toast = createToastInterface(options);\n if (getCurrentInstance()) {\n provide(toastInjectionKey, toast);\n }\n};\nvar useToast = (eventBus) => {\n if (eventBus) {\n return createToastInterface(eventBus);\n }\n const toast = getCurrentInstance() ? inject(toastInjectionKey, void 0) : void 0;\n return toast ? toast : createToastInterface(globalEventBus);\n};\nvar src_default = VueToastificationPlugin;\nexport {\n EventBus,\n POSITION,\n TYPE,\n createToastInterface,\n src_default as default,\n globalEventBus,\n provideToast,\n toastInjectionKey,\n useToast\n};\n"],"names":["ENV","RENDERER_TYPE","BUFFER_BITS","BLEND_MODES","DRAW_MODES","FORMATS","TARGETS","TYPES","SAMPLER_TYPES","SCALE_MODES","WRAP_MODES","MIPMAP_MODES","ALPHA_MODES","CLEAR_MODES","GC_MODES","PRECISION","MASK_TYPES","MSAA_QUALITY","BUFFER_TYPE","INSTALLED","autoDetectResource","source","options","extension","result","exec","toLowerCase","i","length","ResourcePlugin","test","Error","extendStatics","d","b","Object","setPrototypeOf","__proto__","Array","p","hasOwnProperty","__extends","__","this","constructor","prototype","create","__assign","assign","t","s","arguments$1","arguments","n","call","apply","__rest","e","indexOf","getOwnPropertySymbols","Resource","width","height","_width","_height","destroyed","internal","onResize","R","onUpdate","onError","bind","baseTexture","add","emit","unbind","remove","resize","defineProperty","get","enumerable","configurable","update","load","Promise","resolve","style","_renderer","_baseTexture","_glTexture","dispose","destroy","removeAll","_source","_extension","BufferResource","_super","_this","_a","data","upload","renderer","glTexture","gl","pixelStorei","UNPACK_PREMULTIPLY_ALPHA_WEBGL","alphaMode","realWidth","realHeight","texSubImage2D","target","format","type","texImage2D","internalFormat","Float32Array","Uint8Array","Uint32Array","defaultBufferOptions","scaleMode","BaseTexture","resource","mipmap","anisotropicLevel","wrapMode","resolution","resourceOptions","Math","round","_mipmap","undefined","_wrapMode","_scaleMode","uid","touched","isPowerOfTwo","_refreshPOT","_glTextures","dirtyId","dirtyStyleId","cacheId","valid","textureCacheIds","_batchEnabled","_batchLocation","parentTextureArray","setResource","set","value","setStyle","dirty","setSize","desiredWidth","desiredHeight","setRealSize","setResolution","oldResolution","event","removeFromCache","castToBaseTexture","from","strict","isFrame","_pixiId","prefix","pixiIdPrefix","addToCache","fromBuffer","buffer","id","push","console","warn","baseTextureFromCache","index","splice","_globalBatch","AbstractMultiResource","items","itemDirtyIds","partTexture","_load","initFromArray","resources","addBaseTextureAt","addResourceAt","len","on","off","map","item","filter","promises","all","then","ArrayResource","urls","isArray","texture","texImage3D","TEXTURE_2D_ARRAY","texSubImage3D","BaseImageResource","sourceAny","naturalWidth","videoWidth","naturalHeight","videoHeight","noSubImage","crossOrigin","element","url","crossorigin","HTMLImageElement","complete","HTMLVideoElement","readyState","TEXTURE_2D","CanvasResource","OffscreenCanvas","globalThis","HTMLCanvasElement","CubeResource","autoLoad","linkBaseTexture","SIDES","keys","side","ImageResource","imageElement","Image","src","_process","preserveBitmap","createBitmap","createImageBitmap","bitmap","reject","completed","onload","onerror","process","cors","fetch","mode","r","blob","premultiplyAlpha","flag","glTextures","key","otherTex","close","SVGResource","sourceBase64","document","createElement","svg","scale","_overrideWidth","_overrideHeight","_resolve","_crossorigin","SVG_XML","trim","btoa","unescape","encodeURIComponent","_loadSvg","tempImage","svgWidth","svgHeight","canvas","getContext","drawImage","getSize","svgString","sizeMatch","SVG_SIZE","size","parseFloat","VideoResource","videoElement","setAttribute","firstSrc","sourceElement","mime","baseSrc","split","shift","ext","slice","lastIndexOf","MIME_TYPES","appendChild","_autoUpdate","_isConnectedToTicker","_updateFPS","updateFPS","_msToNextUpdate","autoPlay","_onCanPlay","_onError","_deltaTime","elapsedMS","playbackRate","floor","HAVE_ENOUGH_DATA","HAVE_FUTURE_DATA","addEventListener","_onPlayStart","_onPlayStop","_isSourceReady","removeEventListener","_isSourcePlaying","currentTime","paused","ended","autoUpdate","play","pause","ogv","mov","m4v","ImageBitmapResource","ImageBitmap","_resources","DepthResource","Framebuffer","stencil","depth","dirtyFormat","dirtySize","depthTexture","colorTextures","glFramebuffers","disposeRunner","multisample","addColorTexture","addDepthTexture","enableDepth","enableStencil","destroyDepthTexture","BaseRenderTexture","clearColor","framebuffer","maskStack","filterStack","TextureUvs","x0","y0","x1","y1","x2","y2","x3","y3","uvsFloat32","frame","baseFrame","rotate","tw","th","w2","h2","cX","x","cY","y","toString","DEFAULT_UVS","Texture","orig","anchor","noFrame","_frame","_uvs","uvMatrix","_rotate","Number","defaultAnchor","_updateID","onBaseTextureUpdated","once","updateUvs","destroyBase","clone","clonedFrame","clonedOrig","clonedTexture","fromURL","fromLoader","imageUrl","name","textureFromCache","xNotFit","yNotFit","relationship","errorX","errorY","createWhiteTexture","context","fillStyle","fillRect","removeAllHandlers","tex","EMPTY","WHITE","RenderTexture","baseRenderTexture","filterFrame","filterPoolKey","resizeBaseTexture","rest","_i","RenderTexturePool","textureOptions","texturePool","enableFullScreen","_pixelsWidth","_pixelsHeight","createTexture","getOptimalTexture","minWidth","minHeight","ceil","renderTexture","pop","getFilterTexture","input","filterTexture","returnTexture","returnFilterTexture","clear","destroyTextures","textures","j","setScreenSize","SCREEN_KEY","Attribute","normalized","stride","start","instance","UID","Buffer","_static","_glBuffers","static","Int32Array","interleaveTypedArrays","arrays","sizes","outSize","views","ArrayBuffer","out","littleOffset","array","indexStart","byteSizeMap","UID$1","map$1","Uint16Array","Geometry","buffers","attributes","indexBuffer","glVertexArrayObjects","instanced","instanceCount","refCount","addAttribute","ids","bufferIndex","getAttribute","getBuffer","addIndex","getIndex","interleave","interleavedBuffer","attribute","geometry","attrib","merge","geometries","geometryOut","offsets","offset","offset2","bufferIndexToCount","indexBufferData","Quad","QuadUv","vertices","uvs","vertexBuffer","uvBuffer","targetTextureFrame","destinationFrame","invalidate","UID$2","UniformGroup","uniforms","isStatic","isUbo","group","syncUniforms","ubo","autoManage","_ubo","uboFrom","FilterState","legacy","sourceFrame","bindingSourceFrame","bindingDestinationFrame","filters","transform","tempPoints","tempMatrix","FilterSystem","defaultFilterStack","view","statePool","quad","quadUv","tempRect","activeState","globalUniforms","outputFrame","inputSize","inputPixel","inputClamp","filterArea","filterClamp","forceClear","useMaxPadding","_b","state","renderTextureSystem","padding","autoFit","min","max","current","copyFrom","getBounds","pad","sourceFrameProjected","projection","transformAABB","invert","fit","roundFrame","getOptimalFilterTexture","lastState","blit","flip","flop","CLEAR","bindAndClear","clearMode","stateSystem","autoClear","stateId","applyFilter","output","uSampler","filterGlobals","shader","program","attributeData","aTextureCoord","draw","calculateSpriteMatrix","outputMatrix","sprite","_texture","mappedMatrix","worldTransform","copyTo","prepend","translate","swap","emptyPool","matrix","rect","lt","lb","rt","rb","left","top","bottom","right","a","c","abs","identity","ObjectRenderer","flush","stop","render","_object","BatchSystem","emptyRenderer","currentRenderer","setObjectRenderer","objectRenderer","reset","copyBoundTextures","arr","maxTextures","boundTextures","boundArray","texArray","batchId","elements","count","loc","bound","CONTEXT_UID_COUNTER","ContextSystem","webGLVersion","extensions","supports","uint32Indices","handleContextLost","handleContextRestored","isContextLost","contextChange","CONTEXT_UID","getExtension","restoreContext","initFromContext","validateContext","runners","initFromOptions","createContext","getExtensions","common","anisotropicFiltering","floatTextureLinear","s3tc","s3tc_sRGB","etc","etc1","pvrtc","atc","astc","drawBuffers","loseContext","vertexArrayObject","uint32ElementIndex","floatTexture","textureHalfFloat","textureHalfFloatLinear","colorBufferFloat","preventDefault","useProgram","postrender","renderingToScreen","getContextAttributes","isWebGl2","WebGL2RenderingContext","hasuint32","GLFramebuffer","msaaBuffer","blitFramebuffer","mipLevel","tempRectangle","FramebufferSystem","managedFramebuffers","unknownFramebuffer","msaaSamples","viewport","hasMRT","writeDepthTexture","disposeAll","nativeDrawBuffersExtension_1","nativeDepthTextureExtension","activeTextures","drawBuffersWEBGL","getInternalformatParameter","RENDERBUFFER","RGBA8","SAMPLES","fbo","initFramebuffer","bindFramebuffer","FRAMEBUFFER","updateFramebuffer","resizeFramebuffer","mipWidth","mipHeight","setViewport","v","g","mask","createFramebuffer","detectSamples","bindRenderbuffer","renderbufferStorageMultisample","DEPTH24_STENCIL8","renderbufferStorage","DEPTH_STENCIL","parentTexture","canMultisampleFramebuffer","createRenderbuffer","framebufferRenderbuffer","COLOR_ATTACHMENT0","deleteRenderbuffer","framebufferTexture2D","DEPTH_ATTACHMENT","DEPTH_STENCIL_ATTACHMENT","samples","res","sourcePixels","destPixels","colorTexture","sameSize","READ_FRAMEBUFFER","COLOR_BUFFER_BIT","NEAREST","LINEAR","disposeFramebuffer","contextLost","deleteFramebuffer","list","forceStencil","w","h","byteSizeMap$1","GeometrySystem","_activeGeometry","_activeVao","hasVao","hasInstance","canUseUInt32ElementIndex","managedGeometries","nativeVaoExtension_1","createVertexArray","createVertexArrayOES","bindVertexArray","vao","bindVertexArrayOES","deleteVertexArray","deleteVertexArrayOES","instanceExt_1","vertexAttribDivisor","vertexAttribDivisorANGLE","drawElementsInstanced","drawElementsInstancedANGLE","drawArraysInstanced","drawArraysInstancedANGLE","vaos","incRefCount","initGeometryVao","activateVao","updateBuffers","bufferSystem","checkCompatibility","geometryAttributes","shaderAttributes","getSignature","attribs","strings","location","join","glPrograms","generateProgram","signature","vaoObjectHash","tempStride","tempStart","attribSize","disposeGeometry","buf","vaoId","lastBuffer","glBuffer","enableVertexAttribArray","vertexAttribPointer","FLOAT","byteSize","BYTES_PER_ELEMENT","glType","UNSIGNED_SHORT","UNSIGNED_INT","drawElements","drawArrays","MaskData","maskObject","autoDetect","pooled","isMaskData","enabled","_filters","_stencilCounter","_scissorCounter","_scissorRect","_scissorRectLocal","_target","copyCountersOrReset","maskAbove","compileShader","createShader","shaderSource","logPrettyShaderError","shaderSrc","getShaderSource","line","shaderLog","getShaderInfoLog","splitShader","dedupe","lineNumbers","replace","logArgs","forEach","number","fragmentSourceToLog","error","groupCollapsed","groupEnd","logProgramError","vertexShader","fragmentShader","getProgramParameter","LINK_STATUS","getShaderParameter","COMPILE_STATUS","getProgramInfoLog","booleanArray","defaultValue","maxFragmentPrecision","unknownContext","getTestContext","getMaxFragmentPrecision","getShaderPrecisionFormat","shaderFragment","FRAGMENT_SHADER","HIGH_FLOAT","precision","setPrecision","requestedPrecision","maxSupportedPrecision","substring","GLSL_TO_SIZE","float","vec2","vec3","vec4","int","ivec2","ivec3","ivec4","uint","uvec2","uvec3","uvec4","bool","bvec2","bvec3","bvec4","mat2","mat3","mat4","sampler2D","mapSize","GL_TABLE","GL_TO_GLSL_TYPES","FLOAT_VEC2","FLOAT_VEC3","FLOAT_VEC4","INT","INT_VEC2","INT_VEC3","INT_VEC4","UNSIGNED_INT_VEC2","UNSIGNED_INT_VEC3","UNSIGNED_INT_VEC4","BOOL","BOOL_VEC2","BOOL_VEC3","BOOL_VEC4","FLOAT_MAT2","FLOAT_MAT3","FLOAT_MAT4","SAMPLER_2D","INT_SAMPLER_2D","UNSIGNED_INT_SAMPLER_2D","SAMPLER_CUBE","INT_SAMPLER_CUBE","UNSIGNED_INT_SAMPLER_CUBE","SAMPLER_2D_ARRAY","INT_SAMPLER_2D_ARRAY","UNSIGNED_INT_SAMPLER_2D_ARRAY","mapType","typeNames","tn","uniformParsers","code","uniform","codeUbo","GLSL_TO_SINGLE_SETTERS_CACHED","samplerCube","sampler2DArray","GLSL_TO_ARRAY_SETTERS","generateUniformsSync","uniformData","funcFragments","parsed","templateType","template","Function","unsafeEval","fragTemplate","generateIfTestSrc","maxIfs","checkMaxIfStatementsInShader","fragmentSrc","unsafeEvalSupported","func","defaultFragment","defaultVertex","UID$3","nameCache","Program","vertexSrc","defaultVertexSrc","defaultFragmentSrc","Shader","uniformBindCount","uniformGroup","checkUniformExists","BLEND","OFFSET","CULLING","DEPTH_TEST","WINDING","DEPTH_MASK","State","blendMode","polygonOffset","blend","depthMask","_blendMode","_polygonOffset","clockwiseFrontFace","culling","for2d","depthTest","defaultVertex$1","defaultFragment$1","Filter","filterManager","_currentState","_resolution","vertex","fragment","tempMat","TextureMatrix","clampMargin","mapCoord","uClampFrame","uClampOffset","_textureID","clampOffset","isSimple","multiplyUvs","mat","tx","ty","forceUpdate","append","texBase","margin","SpriteMaskFilter","maskSprite","maskMatrix","_maskSprite","renderable","npmAlpha","otherMatrix","alpha","worldAlpha","maskClamp","MaskSystem","enableScissor","alphaMaskPool","maskDataPool","alphaMaskIndex","setMaskStack","scissor","maskDataOrTarget","maskData","detect","pushSpriteMask","popSpriteMask","maskCurrent","isSprite","testScissor","alphaMaskFilter","stashFilterArea","AbstractMaskSystem","glConst","getStackLength","curStackLen","newStackLen","disable","enable","_useCurrent","tempMatrix$1","ScissorSystem","WebGLRenderingContext","SCISSOR_TEST","calcScissorRect","prevData","roundFrameToPixels","isMatrixRotated","isFastRect","StencilSystem","STENCIL_TEST","prevMaskCount","clearStencil","STENCIL_BUFFER_BIT","colorMask","stencilFunc","EQUAL","stencilOp","KEEP","INCR","batch","DECR","ProjectionSystem","defaultFrame","projectionMatrix","root","calculateProjection","syncUniformGroup","globals","_destinationFrame","pm","sign","setTransform","_matrix","tempRect2","RenderTextureSystem","_backgroundColorRgba","defaultMaskStack","viewportFrame","screen","clearMask","uboUpdate","_ud","_uv","_syncData","UBO_TO_SINGLE_SETTERS","GLSL_TO_STD40_SIZE","createUBOElements","uboElements","dataLen","chunkSize","uboElement","lineUpValue","getUBOData","usedUniformDatas","sort","generateUniformBufferSync","syncFunc","uniformParser","size_1","rowSize","elementSize","remainder","IGLUniformData","GLProgram","uniformGroups","uniformDirtyGroups","uniformBufferBindings","getAttributeData","totalAttributes","ACTIVE_ATTRIBUTES","attribData","getActiveAttrib","getAttribLocation","getUniformData","totalUniforms","ACTIVE_UNIFORMS","getActiveUniform","match","glVertShader","VERTEX_SHADER","glFragShader","webGLProgram","createProgram","attachShader","linkProgram","bindAttribLocation","deleteShader","getUniformLocation","glProgram","UID$4","defaultSyncData","textureCount","uboCount","ShaderSystem","systemCheck","cache","_uboCache","dontSync","setUniforms","syncData","getGlProgram","createSyncGroups","syncUniformBufferGroup","createSyncBufferGroup","bindBufferBase","uniformBlockIndex","getUniformBlockIndex","uniformBlockBinding","uboData","preFix","mapWebGLBlendModesToPixi","ONE","ONE_MINUS_SRC_ALPHA","DST_COLOR","ONE_MINUS_SRC_COLOR","SRC_ALPHA","DST_ALPHA","ZERO","ONE_MINUS_DST_ALPHA","FUNC_REVERSE_SUBTRACT","FUNC_ADD","BLEND$1","OFFSET$1","CULLING$1","DEPTH_TEST$1","WINDING$1","DEPTH_MASK$1","StateSystem","_blendEq","setBlend","setOffset","setCullFace","setDepthTest","setFrontFace","setDepthMask","checks","defaultState","blendModes","diff","forceState","updateCheck","checkBlendMode","checkPolygonOffset","POLYGON_OFFSET_FILL","CULL_FACE","frontFace","setBlendMode","blendFunc","blendFuncSeparate","blendEquationSeparate","setPolygonOffset","UNPACK_FLIP_Y_WEBGL","system","TextureGCSystem","checkCount","maxIdle","checkCountMax","run","tm","managedTextures","wasRemoved","destroyTexture","unload","displayObject","children","mapTypeAndFormatToInternalFormat","_c","_d","_e","_f","_g","_h","_j","_k","_l","_m","_o","_p","_q","_r","_s","_t","_u","_v","_w","_x","table","RGB8","RG8","R8","RGBA8UI","RGB8UI","RG8UI","R8UI","ALPHA","LUMINANCE","LUMINANCE_ALPHA","RGBA8_SNORM","RGB8_SNORM","RG8_SNORM","R8_SNORM","RGBA8I","RGB8I","RG8I","R8I","RGBA16UI","RGB16UI","RG16UI","R16UI","DEPTH_COMPONENT16","RGBA16I","RGB16I","RG16I","R16I","RGBA32UI","RGB32UI","RG32UI","R32UI","DEPTH_COMPONENT24","RGBA32I","RGB32I","RG32I","R32I","RGBA32F","RGB32F","RG32F","R32F","DEPTH_COMPONENT32F","RGBA16F","RGB16F","RG16F","R16F","RGB565","RGBA4","RGB5_A1","RGB10_A2","RGB10_A2UI","R11F_G11F_B10F","RGB9_E5","DEPTH32F_STENCIL8","RGBA","RGB","GLTexture","samplerType","TextureSystem","currentLocation","_unknownBoundTextures","unknownTexture","hasIntegerTextures","internalFormats","getParameter","MAX_TEXTURE_IMAGE_UNITS","emptyTextures","emptyTexture2D","bindTexture","UNSIGNED_BYTE","TEXTURE_CUBE_MAP","TEXTURE_CUBE_MAP_POSITIVE_X","texParameteri","TEXTURE_MAG_FILTER","TEXTURE_MIN_FILTER","textureGC","initTexture","activeTexture","TEXTURE0","updateTexture","ensureSamplerType","initTextureType","HALF_FLOAT","updateTextureStyle","skipRemove","deleteTexture","generateMipmap","TEXTURE_WRAP_S","TEXTURE_WRAP_T","LINEAR_MIPMAP_LINEAR","NEAREST_MIPMAP_NEAREST","anisotropicExt","level","MAX_TEXTURE_MAX_ANISOTROPY_EXT","texParameterf","TEXTURE_MAX_ANISOTROPY_EXT","_systems","tempMatrix$2","AbstractRenderer","useContextAlpha","autoDensity","preserveDrawingBuffer","clearBeforeRender","_backgroundColor","_backgroundColorString","backgroundColor","backgroundAlpha","transparent","_lastObjectRendered","plugins","initPlugins","staticMap","o","desiredScreenWidth","desiredScreenHeight","screenWidth","screenHeight","generateTexture","region","manualRegion","getLocalBounds","skipUpdateTransform","parent","removeView","parentNode","removeChild","thisAny","_tempDisplayObjectParent","GLBuffer","updateID","byteLength","BufferSystem","managedBuffers","boundBufferBases","createGLBuffer","bindBuffer","UNIFORM_BUFFER","bindBufferRange","bufferSubData","drawType","STATIC_DRAW","DYNAMIC_DRAW","bufferData","deleteBuffer","createBuffer","Renderer","prerender","addSystem","__plugins","antialias","premultipliedAlpha","powerPreference","FRAMEBUFFER_BINDING","DRAW_FRAMEBUFFER_BINDING","DRAW_FRAMEBUFFER","ClassRef","isLost","cacheParent","enableTempParent","updateTransform","disableTempParent","extract","registerPlugin","pluginName","ctor","autoDetectRenderer","$defaultVertex","$defaultFilterVertex","defaultVertex$2","defaultFilterVertex","BatchDrawCall","System","BatchTextureArray","ViewableBuffer","sizeOrBuffer","rawBinaryData","uint32View","float32View","_int8View","Int8Array","_uint8View","_int16View","Int16Array","_uint16View","_int32View","sizeOf","AbstractBatchRenderer","shaderGenerator","geometryClass","vertexSize","_vertexCount","_indexCount","_bufferedElements","_bufferedTextures","_bufferSize","_shader","_packedGeometries","_packedGeometryPoolSize","_flushId","_aBuffers","_iBuffers","MAX_TEXTURES","onPrerender","_dcIndex","_aIndex","_iIndex","_attributeBuffer","_indexBuffer","_tempBoundTextures","generateShader","initFlushBuffers","_drawCallPool","_textureArrayPool","MAX_SPRITES","MAX_TA","vertexData","indices","buildTexturesAndDrawCalls","textureArrays","touch","TICK","countTexArrays","buildDrawCalls","finish","drawCalls","dcIndex","aIndex","iIndex","drawCall","spriteBlendMode","packInterleavedGeometry","bindAndClearTexArray","textureSystem","updateGeometry","packedGeometries","attributeBuffer","_buffer","drawBatches","dcCount","curTexArray","getAttributeBuffer","getIndexBuffer","roundedP2","roundedSizeIndex","roundedSize","packedVertices","indicies","textureId","argb","_tintRGB","BatchShaderGenerator","programCache","defaultGroupCache","sampleValues","uSamplers","generateSampleSrc","tint","translationMatrix","default","BatchGeometry","defaultVertex$3","defaultFragment$2","BatchPluginFactory","BatchPlugin","BatchRenderer","_loop_1","systems","_loop_2","Bounds","minX","Infinity","minY","maxX","maxY","isEmpty","getRectangle","addPoint","point","addPointMatrix","addQuad","addFrame","addFrameMatrix","addVertexData","beginOffset","endOffset","addVertices","addVerticesMatrix","padX","padY","rawX","rawY","addBounds","bounds","addBoundsMask","_minX","_minY","_maxX","_maxY","addBoundsMatrix","addBoundsArea","area","paddingX","paddingY","addFramePad","DisplayObject","tempDisplayObjectParent","visible","cullable","cullArea","_lastSortedIndex","_zIndex","_enabledFilters","_bounds","_localBounds","_boundsID","_boundsRect","_localBoundsRect","_mask","_maskRefCount","_destroyed","isMask","mixin","propertyName","getOwnPropertyDescriptor","_recursivePostUpdateTransform","skipUpdate","calculateBounds","transformRef","parentRef","worldBounds","worldBoundsID","toGlobal","position","displayObjectUpdateTransform","toLocal","applyInverse","setParent","container","addChild","scaleX","scaleY","rotation","skewX","skewY","pivotX","pivotY","skew","pivot","_options","removeAllListeners","hitArea","interactive","interactiveChildren","TemporaryDisplayObject","myParent","localTransform","sortDirty","sortChildren","zIndex","Container","sortableChildren","onChildrenChange","_length","child","_parentID","addChildAt","swapChildren","child2","index1","getChildIndex","index2","setChildIndex","currentIndex","getChildAt","removeChildAt","removeChildren","beginIndex","endIndex","removed","begin","end","range","RangeError","sortRequired","_calculateBounds","skipChildrenUpdate","_renderWithCulling","_render","intersects","childCullable","renderAdvanced","NONE","destroyChildren","oldChildren","containerUpdateTransform","SHAPES","PI_2","PI","RAD_TO_DEG","DEG_TO_RAD","Point","equals","Rectangle","RECT","rectangle","contains","other","x0_1","x1_1","y0_1","y1_1","nx","ny","n00","n10","n01","n11","mx","my","m00","m10","m01","m11","eps","enlarge","Circle","radius","CIRC","r2","dx","dy","Ellipse","halfWidth","halfHeight","ELIP","normx","normy","Polygon","points","flat","il","POLY","closeStroke","polygon","inside","xi","yi","xj","yj","intersect","reduce","pointsDesc","currentPoint","RoundedRectangle","RREC","radius2","ObservablePoint","cb","scope","_y","Matrix","fromArray","toArray","transpose","pos","newPos","angle","cos","sin","a1","c1","tx1","b1","d1","decompose","atan2","delta","sqrt","ux","uy","vx","vy","rotationCayley","rotationMatrices","signum","init","row","_ux","_uy","_vx","_vy","k","groupD8","E","SE","S","SW","W","NW","N","NE","MIRROR_VERTICAL","MAIN_DIAGONAL","MIRROR_HORIZONTAL","REVERSE_DIAGONAL","uX","ind","uY","vX","vY","inv","rotationSecond","rotationFirst","sub","rotate180","isVertical","byDirection","matrixAppendRotationInv","Transform","onChange","updateSkew","_rotation","_cx","_sx","_cy","_sy","_localID","_currentLocalID","_worldID","updateLocalTransform","parentTransform","pt","wt","setFromMatrix","IDENTITY","PropertyNode","time","ease","next","isStepped","generateEase","node","first","hexToRGB","GetTextureFromString","DEG_TO_RADS","rotatePoint","xnew","ynew","combineRGBComponents","normalize","oneOverLen","scaleBy","color","charAt","substr","parseInt","segments","qty","oneOverQty","cp","getBlendMode","toUpperCase","BehaviorOrder","Particle","emitter","super","prevChild","nextChild","config","maxLife","age","agePercent","oneOverLife","prev","kill","recycle","ticker","PositionParticle","Symbol","Emitter","particleParent","initBehaviors","updateBehaviors","recycleBehaviors","minLifetime","maxLifetime","customEase","_frequency","spawnChance","maxParticles","emitterLifetime","spawnPos","particlesPerWave","ownerPos","_prevEmitterPos","_prevPosIsValid","_posChanged","_parent","addAtBack","particleCount","_emit","_spawnTimer","_emitterLife","_activeParticlesFirst","_activeParticlesLast","_poolFirst","_origConfig","_destroyWhenComplete","_completeCallback","updateSpawnPos","updateOwnerPos","knownBehaviors","frequency","cleanup","lifetime","behaviors","order","Spawn","updateParticle","recycleParticle","getBehavior","find","fillPool","particle","fromCleanup","newRot","resetPositionTracking","playOnceAndDestroy","callback","playOnce","lerp","prevX","prevY","curX","curY","emitPosX","emitPosY","waveFirst","waveLast","random","behavior","initParticles","emitNow","getRandPos","editorConfig","Torus","innerRadius","affectRotation","PolygonalChain","countingLengths","totalLength","chain","prevPoint","second","p1","p2","l","segLength","rand","chosenSeg","AccelerationBehavior","Late","minStart","maxStart","accel","maxSpeed","speed","velocity","deltaSec","vel","oldVX","oldVY","currentSpeed","intValueSimple","intColorSimple","curVal","nextVal","intValueComplex","intColorComplex","intValueStepped","intColorStepped","PropertyList","isColor","interpolate","AlphaBehavior","Normal","createList","StaticAlphaBehavior","getTextures","outTextures","dupe","RandomAnimatedTextureBehavior","anims","anim","framerate","parsedAnim","duration","loop","animElapsed","animDuration","animFramerate","SingleAnimatedTextureBehavior","BlendModeBehavior","BurstSpawnBehavior","spacing","distance","ColorBehavior","StaticColorBehavior","OrderedTextureBehavior","helperPoint","MATH_FUNCS","WHITELISTER","RegExp","concat","parsePath","pathString","matches","PathBehavior","path","minMult","initRotation","initPosition","movement","mult","speedMult","PointSpawnBehavior","_first","RandomTextureBehavior","RotationBehavior","minSpeed","rotSpeed","oldSpeed","StaticRotationBehavior","NoRotationBehavior","ScaleBehavior","scaleMult","StaticScaleBehavior","ShapeSpawnBehavior","ShapeClass","shapes","shape","typeOverride","registerShape","SingleTextureBehavior","SpeedBehavior","StaticSpeedBehavior","upgradeConfig","art","acceleration","minimumSpeedMultiplier","noRotation","extraData","minimumScaleMultiplier","rotationAcceleration","rotationSpeed","startRotation","orderedArt","spawnType","angleStart","particleSpacing","spawnCircle","minR","spawnRect","spawnPolygon","registerBehavior","Runner","_name","_aliasCount","a0","a2","a3","a4","a5","a6","a7","ensureNonAliasedItems","defineProperties","dispatch","appleIphone","appleIpod","appleTablet","appleUniversal","androidPhone","androidTablet","amazonPhone","amazonTablet","windowsPhone","windowsTablet","otherBlackBerry","otherBlackBerry10","otherOpera","otherChrome","otherFirefox","isAppleTabletOnIos13","navigator","platform","maxTouchPoints","MSStream","createMatch","userAgent","regex","isMobile","param","nav","tmp","apple","phone","ipod","tablet","universal","device","amazon","android","windows","blackberry","blackberry10","opera","firefox","chrome","any","maxRecommendedTextures","allowMax","majorVersion","canUploadSameBuffer","settings","MIPMAP_TEXTURES","POW2","ANISOTROPIC_LEVEL","RESOLUTION","FILTER_RESOLUTION","FILTER_MULTISAMPLE","SPRITE_MAX_TEXTURES","SPRITE_BATCH_SIZE","RENDER_OPTIONS","GC_MODE","AUTO","GC_MAX_IDLE","GC_MAX_CHECK_COUNT","WRAP_MODE","CLAMP","SCALE_MODE","PRECISION_VERTEX","HIGH","PRECISION_FRAGMENT","MEDIUM","CAN_UPLOAD_SAME_BUFFER","CREATE_IMAGE_BITMAP","ROUND_PIXELS","tempPoint","Sprite","_anchor","_onAnchorUpdate","_tint","_cachedTint","vertexTrimmedData","_transformID","_transformTrimmedID","_textureTrimmedID","_roundPixels","_onTextureUpdate","calculateVertices","w0","w1","h0","h1","calculateTrimmedVertices","containsPoint","destroyBaseTexture","UPDATE_PRIORITY","TickerListener","fn","priority","previous","deltaTime","redirect","connect","hard","Ticker","autoStart","lastTime","started","_requestId","_maxElapsedMS","_minElapsedMS","_protected","_lastFrame","_head","deltaMS","_tick","requestAnimationFrame","_requestIfNeeded","performance","now","_cancelIfNeeded","cancelAnimationFrame","_startIfPossible","NORMAL","_addListener","addOnce","listener","head","fps","minFPS","maxFPS","minFPMS","_shared","shared","_system","TickerPlugin","sharedTicker","_ticker","LOW","oldTicker","parse","supported","saidHello","VERSION","sayHello","args","log","isWebGLSupported","contextOptions","failIfMajorPerformanceCaveat","success","aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","goldenrod","gold","gray","green","greenyellow","grey","honeydew","hotpink","indianred","indigo","ivory","khaki","lavenderblush","lavender","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen","cssColorNames","hex2rgb","hex","hex2string","hexString","string2hex","string","mapPremultipliedBlendModes","npm","premultiplyBlendMode","correctBlendMode","premultiplied","premultiplyRgba","rgb","premultiply","premultiplyTint","G","B","premultiplyTintToRgba","createIndicesForQuads","outBuffer","totalIndices","getBufferType","nextPow2","isPow2","log2","removeItems","startIdx","removeCount","nextUid","warnings","deprecation","version","message","ignoreDepth","stack","ProgramCache","TextureCache","BaseTextureCache","CanvasRenderTarget","clearRect","val","trimCanvas","imageData","getImageData","pixels","tempAnchor","determineCrossOrigin","url$1","href","parsedUrl","samePort","port","hostname","protocol","getResolutionOfUrl","has","Events","EE","addListener","TypeError","evt","_events","_eventsCount","clearEvent","EventEmitter","eventNames","events","names","listeners","handlers","ee","listenerCount","removeListener","prefixed","module","exports","makeMap","str","expectsLowerCase","PatchFlagNames","GLOBALS_WHITE_LISTED","isGloballyWhitelisted","generateCodeFrame","lines","newlineSequences","_","idx","repeat","String","lineLength","newLineSeqLength","specialBooleanAttrs","isSpecialBooleanAttr","includeBooleanAttr","normalizeStyle","isString","parseStringStyle","isObject","listDelimiterRE","propertyDelimiterRE","cssText","ret","normalizeClass","normalizeProps","props","class","klass","HTML_TAGS","SVG_TAGS","VOID_TAGS","isHTMLTag","isSVGTag","isVoidTag","looseCompareArrays","equal","looseEqual","aValidType","isDate","bValidType","getTime","aKeysCount","bKeysCount","aHasKey","bHasKey","looseIndexOf","findIndex","toDisplayString","objectToString","isFunction","JSON","stringify","replacer","_key","__v_isRef","isMap","entries","isSet","values","isPlainObject","EMPTY_OBJ","EMPTY_ARR","NOOP","NO","onRE","isOn","isModelListener","startsWith","extend","el","hasOwn","toTypeString","Date","isSymbol","isPromise","catch","toRawType","isIntegerKey","isReservedProp","cacheStringFunction","hit","camelizeRE","camelize","hyphenateRE","hyphenate","capitalize","toHandlerKey","hasChanged","oldValue","is","invokeArrayFns","fns","arg","def","obj","toNumber","isNaN","_globalThis","getGlobalThis","self","window","beforeAppear","appear","afterAppear","appearCancelled","beforeEnter","enter","afterEnter","enterCancelled","beforeLeave","leave","afterLeave","leaveCancelled","required","dimension","validator","includes","easing","watch","clearCachedDimensions","cachedStyles","computed","transition","transitions","convertToCssProperty","methods","$emit","done","detectAndCacheDimensions","setClosedDimensions","hideOverflow","forceRepaint","setTransition","setOpenedDimensions","setTimeout","unsetOverflow","unsetTransition","unsetDimensions","visibility","display","detectRelevantDimensions","offsetHeight","paddingTop","getCssValue","paddingBottom","offsetWidth","paddingLeft","paddingRight","overflow","getComputedStyle","getPropertyValue","upperChars","__exports__","global","isCallable","tryToString","argument","isPrototypeOf","it","Prototype","toIndexedObject","toAbsoluteIndex","lengthOfArrayLike","createMethod","IS_INCLUDES","$this","fromIndex","O","uncurryThis","stringSlice","TO_STRING_TAG_SUPPORT","classofRaw","wellKnownSymbol","TO_STRING_TAG","CORRECT_ARGUMENTS","tryGet","tag","callee","TEST","V8_OR_CHAKRA_STACK_ENTRY","IS_V8_OR_CHAKRA_STACK","dropEntries","ownKeys","getOwnPropertyDescriptorModule","definePropertyModule","exceptions","f","DESCRIPTORS","createPropertyDescriptor","object","writable","fails","EXISTS","IndexSizeError","m","DOMStringSizeError","HierarchyRequestError","WrongDocumentError","InvalidCharacterError","NoDataAllowedError","NoModificationAllowedError","NotFoundError","NotSupportedError","InUseAttributeError","InvalidStateError","SyntaxError","InvalidModificationError","NamespaceError","InvalidAccessError","ValidationError","TypeMismatchError","SecurityError","NetworkError","AbortError","URLMismatchError","QuotaExceededError","TimeoutError","InvalidNodeTypeError","DataCloneError","getBuiltIn","Deno","versions","v8","createNonEnumerableProperty","redefine","setGlobal","copyConstructorProperties","isForced","FORCED","targetProperty","sourceProperty","descriptor","TARGET","GLOBAL","STATIC","stat","noTargetGet","forced","sham","FunctionPrototype","Reflect","getDescriptor","PROPER","CONFIGURABLE","aFunction","namespace","method","aCallable","V","P","check","toObject","classof","propertyIsEnumerable","dummy","Wrapper","NewTarget","NewTargetPrototype","store","functionToString","inspectSource","cause","NATIVE_WEAK_MAP","sharedKey","hiddenKeys","OBJECT_ALREADY_INITIALIZED","WeakMap","enforce","getterFor","TYPE","wmget","wmhas","wmset","metadata","facade","STATE","replacement","feature","detection","POLYFILL","NATIVE","USE_SYMBOL_AS_UID","$Symbol","toLength","V8_VERSION","symbol","$default","IE8_DOM_DEFINE","V8_PROTOTYPE_DEFINE_BUG","anObject","toPropertyKey","$defineProperty","$getOwnPropertyDescriptor","ENUMERABLE","WRITABLE","Attributes","propertyIsEnumerableModule","internalObjectKeys","enumBugKeys","getOwnPropertyNames","$propertyIsEnumerable","NASHORN_BUG","aPossiblePrototype","setter","CORRECT_SETTER","proto","pref","valueOf","getOwnPropertyNamesModule","getOwnPropertySymbolsModule","InternalStateModule","CONFIGURABLE_FUNCTION_NAME","getInternalState","enforceInternalState","TEMPLATE","unsafe","simple","SHARED","IS_PURE","copyright","toIntegerOrInfinity","integer","IndexedObject","requireObjectCoercible","getMethod","ordinaryToPrimitive","TO_PRIMITIVE","exoticToPrim","toPrimitive","postfix","NATIVE_SYMBOL","iterator","WellKnownSymbolsStore","symbolFor","createWellKnownSymbol","withoutSetter","description","inheritIfRequired","normalizeStringArgument","installErrorCause","clearErrorStack","ERROR_STACK_INSTALLABLE","FULL_NAME","wrapper","IS_AGGREGATE_ERROR","OPTIONS_POSITION","ERROR_NAME","OriginalError","OriginalErrorPrototype","BaseError","WrappedError","$","wrapErrorConstructorWithCause","WEB_ASSEMBLY","WebAssembly","exportGlobalErrorCauseWrapper","exportWebAssemblyErrorCauseWrapper","anInstance","DOMExceptionConstants","DOM_EXCEPTION","NativeDOMException","$DOMException","DOMExceptionPrototype","argumentsLength","that","ERROR_HAS_STACK","DOM_EXCEPTION_HAS_STACK","FORCED_CONSTRUCTOR","DOMException","PolyfilledDOMException","PolyfilledDOMExceptionPrototype","constant","constantName","earcut","holeIndices","dim","invSize","hasHoles","outerLen","outerNode","linkedList","triangles","eliminateHoles","earcutLinked","clockwise","last","signedArea","insertNode","removeNode","filterPoints","again","steiner","ear","pass","indexCurve","isEarHashed","isEar","cureLocalIntersections","splitEarcut","pointInTriangle","minTX","minTY","maxTX","maxTY","minZ","zOrder","maxZ","prevZ","nextZ","z","locallyInside","isValidDiagonal","splitPolygon","queue","getLeftmost","compareX","eliminateHole","hole","bridge","findHoleBridge","bridgeReverse","filteredBridge","hx","hy","qx","tanMin","sectorContainsSector","sortLinked","q","tail","numMerges","pSize","qSize","inSize","leftmost","ax","ay","bx","by","cx","cy","px","py","intersectsPolygon","middleInside","q1","q2","o1","o2","o3","o4","onSegment","num","Node","b2","an","bp","sum","deviation","polygonArea","trianglesArea","flatten","holes","dimensions","holeIndex","LZString","fromCharCode","keyStrBase64","keyStrUriSafe","baseReverseDic","getBaseValue","alphabet","character","compressToBase64","_compress","decompressFromBase64","_decompress","compressToUTF16","decompressFromUTF16","compressed","charCodeAt","compressToUint8Array","uncompressed","compress","TotalLen","current_value","decompressFromUint8Array","decompress","compressToEncodedURIComponent","decompressFromEncodedURIComponent","bitsPerChar","getCharFromInt","ii","context_dictionary","context_dictionaryToCreate","context_c","context_wc","context_w","context_enlargeIn","context_dictSize","context_numBits","context_data","context_data_val","context_data_position","pow","resetValue","getNextValue","bits","resb","maxpower","power","dictionary","enlargeIn","dictSize","numBits","entry","propIsEnumerable","shouldUseNative","test1","test2","order2","test3","letter","err","symbols","to","finallyConstructor","reason","allSettled","remaining","status","setTimeoutFunc","Boolean","noop","thisArg","_state","_handled","_value","_deferreds","doResolve","handle","deferred","_immediateFn","onFulfilled","onRejected","promise","newValue","finale","_unhandledRejectionFn","Handler","ex","prom","race","setImmediate","ONE_FRAME_TIME","startTime_1","vendors","delay","clearTimeout","isInteger","isFinite","accessibleTarget","accessible","accessibleTitle","accessibleHint","tabIndex","_accessibleActive","_accessibleDiv","accessibleType","accessiblePointerEvents","accessibleChildren","renderId","KEY_CODE_TAB","DIV_TOUCH_SIZE","DIV_TOUCH_POS_X","DIV_TOUCH_POS_Y","DIV_TOUCH_ZINDEX","DIV_HOOK_SIZE","DIV_HOOK_POS_X","DIV_HOOK_POS_Y","DIV_HOOK_ZINDEX","AccessibilityManager","debug","_isActive","_isMobileAccessibility","pool","androidUpdateCount","androidUpdateFrequency","_hookDiv","createTouchHook","div","_onKeyDown","_onMouseMove","hookDiv","title","activate","destroyTouchHook","body","deactivate","updateAccessibleObjects","getBoundingClientRect","viewWidth","viewHeight","sx","sy","capHitArea","updateDebugHTML","innerHTML","borderStyle","_onClick","_onFocus","_onFocusOut","pointerEvents","interactionManager","interaction","eventData","dispatchEvent","keyCode","movementX","movementY","InteractionData","pressure","rotationAngle","twist","tangentialPressure","originalEvent","identifier","isPrimary","button","buttons","tiltX","tiltY","pointerType","getLocalPosition","globalPos","copyEvent","which","InteractionEvent","stopped","stopsPropagatingAt","stopPropagationHint","currentTarget","stopPropagation","InteractionTrackingData","pointerId","_pointerId","_flags","FLAGS","_doSet","yn","flags","OVER","RIGHT_DOWN","LEFT_DOWN","freeze","TreeSearch","_tempPoint","recursiveFindHit","interactionEvent","hitTest","interactiveParent","hitTestChildren","childHit","findHit","interactiveTarget","buttonMode","cursor","trackedPointers","_trackedPointers","MOUSE_POINTER_ID","hitTestEvent","InteractionManager","autoPreventDefault","interactionFrequency","mouse","activeInteractionData","interactionDataPool","interactionDOMElement","moveWhenInside","eventsAdded","tickerAdded","mouseOverRenderer","supportsTouchEvents","supportsPointerEvents","PointerEvent","onPointerUp","processPointerUp","onPointerCancel","processPointerCancel","onPointerDown","processPointerDown","onPointerMove","processPointerMove","onPointerOut","processPointerOverOut","onPointerOver","cursorStyles","pointer","currentCursorMode","delayedEvents","search","_tempDisplayObject","_eventListenerOptions","capture","passive","_useSystemTicker","useSystemTicker","setTargetElement","addTickerListener","removeTickerListener","globalPoint","lastObjectRendered","processInteractive","removeEvents","addEvents","tickerUpdate","msPointerEnabled","msContentZooming","msTouchAction","touchAction","_didMove","interactionData","configureInteractionEventForDOMEvent","setCursorMode","applyStyles","eventString","delayDispatchEvent","mapPositionToPoint","parentElement","resolutionMultiplier","delayedLen","displayObject_1","normalizeToPointerData","isNormalized","cancelable","eventLen","getInteractionDataForPointerId","isRightButton","rightDown","leftDown","onPointerComplete","cancelled","eventAppend","releaseInteractionDataForPointerId","trackingData","isTouch","isMouse","isMouseTap","isDown","over","none","pointerEvent","clientX","clientY","globalX","globalY","normalizedEvents","TouchEvent","li","changedTouches","touches","radiusX","radiusY","force","layerX","offsetX","layerY","offsetY","MouseEvent","tempEvent","Application","stage","forceCanvas","_plugins","plugin","stageOptions","reverse","ResizePlugin","dom","queueResize","_resizeTo","cancelResize","_resizeId","innerWidth","innerHeight","clientWidth","clientHeight","resizeTo","TEMP_RECT","BYTES_PER_PIXEL","Extract","image","quality","base64","toDataURL","flipY","generated","canvasBuffer","webglPixels","readPixels","canvasData","arrayPostDivide","putImageData","target_1","SignalBinding","_fn","_once","_thisArg","_next","_prev","_owner","detach","_addSignalBinding","_tail","Signal","exists","detachAll","parseUri","opts","parser","loose","strictMode","uri","_t0","t1","t2","useXdr","XDomainRequest","XMLHttpRequest","STATUS_NONE","STATUS_OK","STATUS_EMPTY","STATUS_IE_BUG_EMPTY","STATUS_TYPE_OK","_noop","setExtMap","extname","reqType","xhr","LoaderResource","_dequeue","_onLoadBinding","_elementTimer","_boundComplete","_boundOnError","_boundOnProgress","_boundOnTimeout","_boundXhrOnError","_boundXhrOnTimeout","_boundXhrOnAbort","_boundXhrOnLoad","_setFlag","STATUS_FLAGS","DATA_URL","_getExtension","timeout","loadType","_determineLoadType","xhrType","UNKNOWN","progressChunk","_onProgress","_onTimeout","_xhrOnError","_xhrOnTimeout","_xhrOnAbort","_xhrOnLoad","onStart","onProgress","onComplete","onAfterMiddleware","setExtensionLoadType","_loadTypeMap","setExtensionXhrType","_xhrTypeMap","_hasFlag","COMPLETE","LOADING","_clearEvents","_finish","abort","xdr","EMPTY_GIF","firstChild","isLoading","isComplete","_determineCrossOrigin","LOAD_TYPE","IMAGE","_loadElement","AUDIO","_loadSourceElement","VIDEO","XHR","_loadXdr","_loadXhr","ontimeout","onprogress","loadElement","skipSource","Audio","isCocoonJS","mimeTypes","mimeType","_createSource","_determineXhrType","withCredentials","open","XHR_RESPONSE_TYPE","DOCUMENT","responseType","TEXT","send","nodeName","lengthComputable","loaded","total","statusText","text","responseText","BUFFER","statusType","DOMParser","domparser","parseFromString","XML","e$1","response","responseURL","origin","host","isDataUrl","slashIndex","queryStart","hashStart","_getMimeFromXhrType","BLOB","DEFAULT","_noop$1","onlyOnce","callFn","gif","png","bmp","jpg","jpeg","tif","tiff","webp","tga","mp3","ogg","wav","mp4","webm","xhtml","html","htm","xml","tmx","tsx","json","txt","ttf","otf","AsyncQueueItem","AsyncQueue","worker","concurrency","workers","saturated","unsaturated","empty","drain","_tasks","_insert","insertAtFront","idle","unshift","task","_worker","running","resume","eachSeries","deferNext","MAX_PROGRESS","rgxExtractUrlHash","Loader","baseUrl","progress","loading","defaultQueryString","_beforeMiddleware","_afterMiddleware","_resourcesParsing","_boundLoadResource","_loadResource","_queue","onLoad","pre","use","_add","parentResource","_prepareUrl","incompleteChildren","fullChunk","eachChunk","_onStart","_onComplete","numTasks","chunk","hash","dequeue","_onLoad","AppLoaderPlugin","sharedLoader","loader","TextureLoader","_keyStr","encodeBinary","inx","bytebuffer","encodedCharIndexes","jnx","paddingBytes","Url","URL","webkitURL","parsing","Blob","src_1","createObjectURL","revokeObjectURL","getResponseHeader","INTERNAL_FORMATS","INTERNAL_FORMAT_TO_BYTES_PER_PIXEL","COMPRESSED_RGB_S3TC_DXT1_EXT","COMPRESSED_RGBA_S3TC_DXT1_EXT","COMPRESSED_RGBA_S3TC_DXT3_EXT","COMPRESSED_RGBA_S3TC_DXT5_EXT","COMPRESSED_SRGB_S3TC_DXT1_EXT","COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT","COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT","COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT","COMPRESSED_R11_EAC","COMPRESSED_SIGNED_R11_EAC","COMPRESSED_RG11_EAC","COMPRESSED_SIGNED_RG11_EAC","COMPRESSED_RGB8_ETC2","COMPRESSED_RGBA8_ETC2_EAC","COMPRESSED_SRGB8_ETC2","COMPRESSED_SRGB8_ALPHA8_ETC2_EAC","COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2","COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2","COMPRESSED_RGB_PVRTC_4BPPV1_IMG","COMPRESSED_RGBA_PVRTC_4BPPV1_IMG","COMPRESSED_RGB_PVRTC_2BPPV1_IMG","COMPRESSED_RGBA_PVRTC_2BPPV1_IMG","COMPRESSED_RGB_ETC1_WEBGL","COMPRESSED_RGB_ATC_WEBGL","COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL","COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL","__awaiter","_arguments","generator","fulfilled","step","rejected","__generator","label","sent","trys","ops","verb","op","_a$1","BlobResource","onBlobLoaded","_data","arrayBuffer","CompressedTextureResource","levels","_formatToExtension","levelBuffers","_levelBuffers","_createLevelBuffers","uint8View","levelID","levelWidth","levelHeight","levelBuffer","compressedTexImage2D","blockWidth","blockHeight","imageWidth","imageHeight","byteOffset","alignedLevelWidth","alignedLevelHeight","levelSize","CompressedTextureLoader","cacheID","textureURL","fallbackURL","url_1","textureFormats","loadOptions","imageMetadata","resourcePath","resourceName","extensionName","textureExtensions","getPrototypeOf","registerCompressedTextures","DXGI_FORMAT","D3D10_RESOURCE_DIMENSION","DDS_MAGIC_SIZE","DDS_HEADER_SIZE","DDS_HEADER_PF_SIZE","DDS_HEADER_DX10_SIZE","DDS_MAGIC","DDS_FIELDS","SIZE","HEIGHT","WIDTH","MIPMAP_COUNT","PIXEL_FORMAT","DDS_PF_FIELDS","FOURCC","RGB_BITCOUNT","R_BIT_MASK","G_BIT_MASK","B_BIT_MASK","A_BIT_MASK","DDS_DX10_FIELDS","RESOURCE_DIMENSION","MISC_FLAG","ARRAY_SIZE","MISC_FLAGS2","_a$2","_b$1","PF_FLAGS","DDPF_ALPHA","DDPF_FOURCC","DDPF_RGB","DDPF_YUV","DDPF_LUMINANCE","FOURCC_DXT1","FOURCC_DXT3","FOURCC_DXT5","FOURCC_DX10","DDS_RESOURCE_MISC_TEXTURECUBE","FOURCC_TO_FORMAT","DXGI_TO_FORMAT","DXGI_FORMAT_BC1_TYPELESS","DXGI_FORMAT_BC1_UNORM","DXGI_FORMAT_BC2_TYPELESS","DXGI_FORMAT_BC2_UNORM","DXGI_FORMAT_BC3_TYPELESS","DXGI_FORMAT_BC3_UNORM","DXGI_FORMAT_BC1_UNORM_SRGB","DXGI_FORMAT_BC2_UNORM_SRGB","DXGI_FORMAT_BC3_UNORM_SRGB","DDSLoader","magicWord","header","mipmapCount","pixelFormat","formatFlags","fourCC","internalFormat_1","dataOffset_1","texData","dx10Offset","dx10Header","dxgiFormat","resourceDimension","miscFlag","arraySize","internalFormat_2","DDS_DIMENSION_TEXTURE3D","imageBuffers","dataOffset","pixelSize","imageSize","imageOffset","FILE_IDENTIFIER","ENDIANNESS","KTX_FIELDS","GL_TYPE","GL_TYPE_SIZE","GL_FORMAT","GL_INTERNAL_FORMAT","GL_BASE_INTERNAL_FORMAT","PIXEL_WIDTH","PIXEL_HEIGHT","PIXEL_DEPTH","NUMBER_OF_ARRAY_ELEMENTS","NUMBER_OF_FACES","NUMBER_OF_MIPMAP_LEVELS","BYTES_OF_KEY_VALUE_DATA","FILE_HEADER_SIZE","TYPES_TO_BYTES_PER_COMPONENT","FORMATS_TO_COMPONENTS","TYPES_TO_BYTES_PER_PIXEL","KTXLoader","textures_1","dataView","DataView","validate","littleEndian","getUint32","glFormat","glInternalFormat","pixelWidth","pixelHeight","pixelDepth","numberOfArrayElements","numberOfFaces","numberOfMipmapLevels","bytesOfKeyValueData","imagePixelByteSize","alignedWidth","alignedHeight","imagePixels","imageByteSize","mipByteSize","alignedMipWidth","alignedMipHeight","mipmapLevel","elementOffset","arrayElement","mips","convertToInt","convertFormatToInteger","getUint8","ParticleContainer","maxSize","properties","batchSize","autoResize","maxBatchSize","_properties","_maxSize","_batchSize","_buffers","_bufferUpdateIDs","roundPixels","setProperties","tintRgb","smallestChildIndex","LINE_JOIN","LINE_CAP","ParticleBuffer","dynamicPropertyFlags","dynamicProperties","staticProperties","property","attributeName","uploadFunction","staticStride","staticBuffer","staticData","staticDataUint32","dynamicStride","dynamicBuffer","dynamicData","dynamicDataUint32","initBuffers","dynamicOffset","dynBuffer","staticOffset","statBuffer","uploadDynamic","startIndex","amount","uploadStatic","ParticleRenderer","uploadVertices","uploadPosition","uploadRotation","uploadUvs","uploadTint","totalChildren","generateBuffers","uColor","updateStatic","_generateOneMoreBuffer","bid","TRIANGLES","spritePosition","spriteRotation","textureUvs","GRAPHICS_CURVES","adaptive","maxLength","minSegments","maxSegments","epsilon","_segmentsCount","defaultSegments","FillStyle","fixOrientation","i1","i2","i3","i4","buildPoly","build","graphicsData","triangulate","graphicsGeometry","verts","holeArray","vertPos","buildCircle","rx","ry","circle","ellipse","roundedRect","j1","j2","j3","j4","center","buildRectangle","rectData","getPt","n1","n2","perc","quadraticBezierCurve","fromX","fromY","cpX","cpY","toX","toY","xa","ya","xb","yb","buildRoundedRectangle","Graphics","nextRoundedRectBehavior","rrectData","vecPos","square","innerWeight","outerWeight","exx","eyy","ix","iy","ox","oy","eix","eiy","eox","eoy","ey","cx2p0x","cy2p0y","angle0","angle1","startAngle","angleDiff","absAngleDiff","segCount","angleInc","buildNonNativeLine","closePointEps","lineStyle","firstPoint","lastPoint","closedShape","closedPath","midPointX","midPointY","indexCount","widthSquared","miterLimitSquared","miterLimit","perpx","perpy","perp1x","perp1y","dist","ratio","alignment","cap","ROUND","SQUARE","dx0","dy0","dx1","dy1","cross","c2","pdist","imx","imy","omx","omy","smallerInsideSegmentSq","insideWeight","smallerInsideDiagonalSq","insideMiterOk","BEVEL","eps2","buildNativeLine","buildLine","native","TEXT_GRADIENT","ArcUtils","curveTo","mm","dd","cc","tt","k1","k2","qy","endAngle","anticlockwise","arc","_startX","_startY","_anticlockwise","sweep","theta","theta2","cTheta","sTheta","segMinus","real","BezierUtils","curveLength","cpX2","cpY2","t3","nt","nt2","nt3","dt","dt2","dt3","QuadraticUtils","a32","ba","BatchPart","attribStart","endAttrib","FILL_COMMANDS","BATCH_POOL","DRAW_CALL_POOL","GraphicsData","tmpPoint","tmpBounds","GraphicsGeometry","boundsPadding","indicesUint16","batchable","colors","textureIds","batchDirty","batches","cacheDirty","clearDirty","shapeIndex","boundsDirty","batchPart","drawShape","drawHole","lastShape","hitHole","i_1","updateBatches","allow32Indices","validateBatching","currentStyle","command","transformPoints","processHoles","nextTexture","index_1","attribIndex","processFill","processLine","_compareStyles","addUvs","need32","isBatchable","packBatches","styleA","styleB","fill","BATCHABLE_SIZE","currentGroup","currentTexture","drawMode","addColors","addTextureIds","packAttributes","glPoints","f32","u32","sequenceBounds","curMatrix","nextMatrix","lineWidth","poly","rgba","uvsStart","adjustUvs","LineStyle","BUTT","MITER","temp","DEFAULT_SHADERS","currentPath","batchTint","_fillStyle","_lineStyle","_holeMode","_geometry","finishPoly","lineTextureStyle","startPoly","moveTo","lineTo","_initCurve","quadraticCurveTo","bezierCurveTo","arcTo","radius_1","startX","startY","xDiff","yDiff","beginFill","beginTextureFill","endFill","drawRect","drawRoundedRect","drawCircle","drawEllipse","drawPolygon","_populateBatches","_renderBatched","_renderDirect","gI","_batchRGB","calculateTints","_resolveDirectShader","_renderDrawCallDirect","groupTextureCount","_TEMP_POINT","tintRGB","wtID","closePath","setMatrix","beginHole","endHole","defaultStyle","align","breakWords","dropShadow","dropShadowAlpha","dropShadowAngle","dropShadowBlur","dropShadowColor","dropShadowDistance","fillGradientType","LINEAR_VERTICAL","fillGradientStops","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","letterSpacing","lineHeight","lineJoin","stroke","strokeThickness","textBaseline","whiteSpace","wordWrap","wordWrapWidth","leading","genericFontFamilies","TextStyle","styleID","deepCopyProperties","clonedProperties","_align","_breakWords","_dropShadow","_dropShadowAlpha","_dropShadowAngle","_dropShadowBlur","_dropShadowColor","outputColor","getColor","_dropShadowDistance","_fill","_fillGradientType","_fillGradientStops","areArraysEqual","_fontFamily","_fontSize","_fontStyle","_fontVariant","_fontWeight","_letterSpacing","_lineHeight","_leading","_lineJoin","_miterLimit","_padding","_stroke","_strokeThickness","_textBaseline","_trim","_whiteSpace","_wordWrap","_wordWrapWidth","toFontString","fontSizeString","fontFamilies","getSingleColor","array1","array2","propertyObj","prop","TextMetrics","lineWidths","maxLineWidth","fontProperties","measureText","_canvas","font","measureFont","ascent","outputText","collapseSpaces","collapseNewlines","canPrependSpaces","tokens","tokenize","token","isNewline","addLine","currIsBreakingSpace","isBreakingSpace","lastIsBreakingSpace","tokenWidth","getFromCache","canBreakWords","characters","wordWrapSplit","char","nextChar","lastChar","canBreakChars","characterWidth","isLastToken","newLine","trimRight","_newlines","_nextChar","_breakingSpaces","_token","_char","_index","_fonts","descent","_context","metricsString","METRICS_STRING","BASELINE_SYMBOL","baseline","HEIGHT_MULTIPLIER","BASELINE_MULTIPLIER","fillText","imagedata","clearMetrics","defaultDestroyOptions","Text","ownCanvas","_ownCanvas","_autoResolution","_text","_style","_styleListener","_font","localStyleID","updateText","respectDirty","linePositionX","linePositionY","measured","passesCount","isShadowPass","dsOffsetText","dsOffsetShadow","strokeStyle","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","_generateFillStyle","linePositionYShift","nextLineHeightBehavior","drawLetterSpacing","isStroke","supportLetterSpacing","experimentalLetterSpacing","CanvasRenderingContext2D","textLetterSpacing","strokeText","currentPosition","stringArray","previousWidth","currentWidth","currentChar","textStr","trimmed","metrics","gradient","dropShadowCorrection","lengthPlus1","createLinearGradient","textHeight","lastLineBottom","thisLineTop","thisLineGradientStart","thisLineBottom","nextLineTop","thisLineGradientEnd","gradStopLineHeight","lineStop","globalStop","toFixed","addColorStop","totalIterations","currentIteration","CountLimiter","maxItemsPerFrame","itemsLeft","beginFrame","allowedToUpload","findMultipleBaseTextures","_textures","findBaseTexture","findTexture","drawText","_helper","calculateTextStyle","findText","findTextStyle","BasePrepare","limiter","uploadHookHelper","addHooks","uploadHooks","completes","ticking","delayedTick","prepareItems","registerFindHook","registerUploadHook","tick","uploaded","addHook","uploadHook","uploadBaseTextures","uploadGraphics","findGraphics","Prepare","Spritesheet","TimeLimiter","maxMilliseconds","frameStart","resolutionFilename","animations","_updateResolution","_frames","frames","_frameKeys","_batchIndex","_callback","meta","BATCH_SIZE","_processFrames","_processAnimations","_parseComplete","_nextBatch","initialFrameIndex","frameIndex","maxFrames","sourceSize","rotated","spriteSourceSize","animName","frameName","SpritesheetLoader","imageResourceName","multiPacks","related_multi_packs","itemName","itemUrl","some","multiPacks_1","getResourcePath","spritesheet","fragmentSimpleSrc","TilingSprite","tileTransform","uvRespectAnchor","gl1VertexSrc","gl1FragmentSrc","gl2VertexSrc","gl2FragmentSrc","TilingSpriteRenderer","simpleShader","ts","anchorX","anchorY","baseTex","uv","H","uMapCoord","uTransform","MeshBatchUvs","_bufferUpdateId","_textureUpdateId","tempPolygon","Mesh","vertexDirty","batchUvs","_renderToBatch","_renderDefault","calculateUvs","material","verticesBuffer","vertexDirtyId","geomUvs","ind0","ind1","ind2","_cachedTexture","MeshMaterial","uTextureMatrix","_colorDirty","_alpha","MeshGeometry","uvsBuffer","_updateId","BitmapFontData","info","page","kerning","distanceField","TextFormat","rawData","chars","kernings","attributeList","itemData","strValue","floatValue","face","file","xoffset","yoffset","xadvance","df","distanceRange","fieldType","XMLFormat","XMLDocument","getElementsByTagName","XMLStringFormat","xmlTxt","formats","autoDetectFormat","generateFillStyle","lastIterationStop","clampedStop","drawGlyph","splitTextToCharacters","resolveCharacters","startCode","endCode","j_1","extractCharCode","codePointAt","BitmapFont","ownsTextures","pageTextures","_ownsTextures","page_1","xOffset","yOffset","xAdvance","distanceFieldRange","distanceFieldType","install","fontData","available","uninstall","textStyle","defaultOptions","textureWidth","textureHeight","charsList","positionX","positionY","maxCharHeight","textureGlyphWidth","NUMERIC","ALPHANUMERIC","ASCII","msdfFrag","msdfVert","pageMeshDataDefaultPageMeshData","pageMeshDataMSDFPageMeshData","charRenderDataPool","BitmapFontLoader","BitmapText","styleDefaults","maxWidth","fontName","_activePagesMeshData","_textWidth","_textHeight","_fontName","_maxWidth","_maxLineHeight","_textureCache","lineSpaces","charsInput","pageMeshDataPool","prevCharCode","lastLineWidth","lastBreakPos","lastBreakWidth","spacesRemoved","maxLineHeight","spaceCount","charCode","charData","charRenderData","prevSpaces","lineAlignOffsets","alignOffset","lenChars","pagesMeshData","newPagesMeshData","activePagesMeshData","baseTextureUid","pageMeshData","meshBlendMode","uFWidth","mesh","vertexCount","uvsCount","total_1","xPos","yPos","pageMesh","textureFrame","anchorOffsetX","anchorOffsetY","i_2","textureBuffer","worldScale","fontScale","getBaseUrl","pageFile","bitmapFont","bitmapResource","resUrl","dirname","dir","AlphaFilter","uAlpha","vertTemplate","generateBlurVertSource","kernelSize","halfLength","vertSource","blurLoop","blur","GAUSSIAN_VALUES","generateBlurFragSource","kernel","fragSource","BlurFilterPass","horizontal","strength","vertSrc","fragSrc","_quality","passes","renderTarget","BLIT","BlurFilter","blurXFilter","blurYFilter","repeatEdgePixels","xStrength","yStrength","updatePadding","_repeatEdgePixels","ColorMatrixFilter","_loadMatrix","multiply","newMatrix","_multiply","_colorMatrix","brightness","greyscale","blackAndWhite","hue","cosR","sinR","sqrW","a00","a01","a02","a10","a11","a12","a20","a21","a22","contrast","saturate","desaturate","negative","sepia","technicolor","polaroid","toBGR","kodachrome","browni","vintage","colorTone","desaturation","toned","lightColor","darkColor","lR","lG","lB","dR","dG","dB","night","intensity","predator","lsd","grayscale","DisplacementFilter","mapSampler","filterMatrix","lenX","lenY","FXAAFilter","NoiseFilter","noise","seed","uNoise","uSeed","_tempMatrix","CacheData","textureCacheId","originalRender","originalRenderCanvas","originalCalculateBounds","originalGetLocalBounds","originalUpdateTransform","originalDestroy","originalMask","originalFilterArea","originalContainsPoint","cacheAsBitmapResolution","_cacheAsBitmapResolution","cacheAsBitmap","cacheAsBitmapMultisample","_cacheAsBitmapMultisample","_cacheAsBitmap","_cacheData","renderCanvas","_renderCached","_renderCachedCanvas","_cacheAsBitmapDestroy","_destroyCachedDisplayObject","_initCachedDisplayObject","cacheAlpha","cachedRenderTexture","cachedSourceFrame","cachedDestinationFrame","cachedProjectionTransform","_calculateCachedBounds","_getCachedLocalBounds","cachedSprite","_initCachedDisplayObjectCanvas","_renderCanvas","cachedRenderTarget","_projTransform","deep","getChildByName","PlaneGeometry","segWidth","segHeight","segmentsX","segmentsY","sizeX","sizeY","totalSub","xpos","ypos","value2","value3","value4","RopeGeometry","textureScale","updateVertices","nextPoint","perpX","perpY","perpLength","SimplePlane","SimpleRope","ropeGeometry","meshMaterial","verticesX","verticesY","planeGeometry","textureUpdated","DEFAULT_BORDER_SIZE","SimpleMesh","NineSlicePlane","leftWidth","topHeight","rightWidth","bottomHeight","_origWidth","_origHeight","_leftWidth","_rightWidth","_topHeight","_bottomHeight","_refresh","updateHorizontalVertices","_getMinScale","updateVerticalVertices","scaleW","scaleH","_uvw","_uvh","AnimatedSprite","_durations","animationSpeed","updateAnchor","onFrameChange","onLoop","_currentTime","_playing","_previousFrame","gotoAndStop","frameNumber","previousFrame","currentFrame","gotoAndPlay","elapsed","lag","fromFrames","fromImages","images","qs","sep","eq","regexp","maxKeys","kstr","vstr","decodeURIComponent","stringifyPrimitive","ks","decode","encode","enumerableOnly","sym","_objectSpread2","_defineProperty","getOwnPropertyDescriptors","_typeof","_extends","_objectWithoutPropertiesLoose","excluded","sourceKeys","_objectWithoutProperties","sourceSymbolKeys","_toConsumableArray","_arrayWithoutHoles","_iterableToArray","_unsupportedIterableToArray","_nonIterableSpread","_arrayLikeToArray","iter","minLen","arr2","pattern","IE11OrLess","Edge","FireFox","Safari","IOS","ChromeForAndroid","captureMode","selector","msMatchesSelector","webkitMatchesSelector","getParentOrHost","nodeType","closest","ctx","includeCTX","_throttleTimeout","R_SPACE","toggleClass","classList","className","css","defaultView","selfOnly","appliedTransforms","matrixFn","DOMMatrix","WebKitCSSMatrix","CSSMatrix","MSCSSMatrix","tagName","getWindowScrollingElement","scrollingElement","documentElement","getRect","relativeToContainingBlock","relativeToNonStaticParent","undoScale","elRect","containerRect","elMatrix","isScrolledPast","elSide","parentSide","getParentAutoScrollElement","elSideVal","parentSideVal","getChild","childNum","includeDragEl","currentChild","Sortable","ghost","dragged","draggable","lastChild","lastElementChild","previousElementSibling","getRelativeScrollOffset","offsetLeft","offsetTop","winScroller","scrollLeft","scrollTop","indexOfObject","includeSelf","elem","gotSelf","scrollWidth","scrollHeight","elemCSS","overflowX","overflowY","dst","isRectEqual","rect1","rect2","throttle","ms","cancelThrottle","scrollBy","Polymer","jQuery","Zepto","cloneNode","setRect","unsetRect","expando","AnimationStateManager","animationCallbackId","animationStates","captureAnimationState","animation","fromRect","thisAnimationDuration","childMatrix","addAnimationState","removeAnimationState","animateAll","animating","animationTime","toRect","prevFromRect","prevToRect","animatingRect","targetMatrix","calculateRealTime","animate","animationResetTimer","currentRect","translateX","translateY","animatingX","animatingY","forRepaintDummy","repaint","animated","defaults","initializeByDefault","PluginManager","mount","option","pluginEvent","eventName","sortable","eventCanceled","cancel","eventNameGlobal","initializePlugins","initialized","modified","modifyOption","getEventProperties","eventProperties","modifiedValue","optionListeners","_ref","rootEl","targetEl","cloneEl","toEl","fromEl","oldIndex","newIndex","oldDraggableIndex","newDraggableIndex","putSortable","extraEventProperties","onName","CustomEvent","createEvent","initEvent","bubbles","pullMode","lastPutMode","allEventProperties","_excluded","dragEl","parentEl","ghostEl","nextEl","lastDownEl","cloneHidden","dragStarted","moved","activeSortable","active","hideGhostForTarget","_hideGhostForTarget","unhideGhostForTarget","_unhideGhostForTarget","cloneNowHidden","cloneNowShown","dispatchSortableEvent","_dispatchEvent","activeGroup","tapEvt","touchEvt","lastDx","lastDy","tapDistanceLeft","tapDistanceTop","lastTarget","lastDirection","targetMoveDistance","ghostRelativeParent","awaitingDragStarted","ignoreNextClick","sortables","pastFirstInvertThresh","isCircumstantialInvert","ghostRelativeParentInitialScroll","_silent","savedInputChecked","documentExists","PositionGhostAbsolutely","CSSFloatProperty","supportDraggable","supportCssPointerEvents","_detectDirection","elCSS","elWidth","borderLeftWidth","borderRightWidth","child1","firstChildCSS","secondChildCSS","firstChildWidth","marginLeft","marginRight","secondChildWidth","flexDirection","gridTemplateColumns","touchingSideChild2","_dragElInRowColumn","dragRect","targetRect","vertical","dragElS1Opp","dragElS2Opp","dragElOppLength","targetS1Opp","targetS2Opp","targetOppLength","_detectNearestEmptySortable","threshold","emptyInsertThreshold","insideHorizontally","insideVertically","_prepareGroup","toFn","pull","sameGroup","otherGroup","originalGroup","checkPull","checkPut","put","revertClone","stopImmediatePropagation","nearestEmptyInsertDetectEvent","nearest","_onDragOver","_checkOutsideTargetEl","_isOutsideThisEl","disabled","swapThreshold","invertSwap","invertedSwapThreshold","removeCloneOnHide","direction","ghostClass","chosenClass","dragClass","ignore","preventOnFilter","setData","dataTransfer","textContent","dropBubble","dragoverBubble","dataIdAttr","delayOnTouchOnly","touchStartThreshold","devicePixelRatio","forceFallback","fallbackClass","fallbackOnBody","fallbackTolerance","fallbackOffset","supportPointer","nativeDraggable","_onTapStart","_globalDragOver","dropEffect","_onMove","willInsertAfter","retVal","onMoveFn","onMove","draggedRect","related","relatedRect","_disableDraggable","_unsilent","_ghostIsFirst","spacer","_ghostIsLast","_getSwapDirection","isLastTarget","mouseOnAxis","targetLength","targetS1","targetS2","_getInsertDirection","_generateId","_saveInputCheckedState","inputs","checked","_nextTick","_cancelNextTick","_getDirection","originalTarget","shadowRoot","composedPath","isContentEditable","criteria","_prepareDragStart","dragStartFn","ownerDocument","nextSibling","_lastX","_lastY","_onDrop","_disableDelayedDragEvents","_triggerDragStart","_disableDelayedDrag","_delayedDragTouchMoveHandler","_dragStartTimer","_onTouchMove","_onDragStart","selection","getSelection","removeAllRanges","_dragStarted","fallback","_appendGhost","_nulling","_emulateDragOver","elementFromPoint","inserted","ghostMatrix","relativeScrollOffset","cssMatrix","_hideClone","cloneId","insertBefore","_loopId","setInterval","effectAllowed","_dragStartId","revert","isOwner","canSort","fromSortable","completedFired","dragOverEvent","_ignoreWhileAnimating","elLastChild","changed","targetBeforeFirstSwap","sibling","differentLevel","differentRowCol","side1","scrolledPastTop","scrollBefore","dragIndex","nextElementSibling","after","moveVector","extra","axis","insertion","_showClone","_offMoveEvents","_offUpEvents","clearInterval","save","handleEvent","useAnimation","querySelectorAll","removeAttribute","utils","nextTick","cancelNextTick","detectDirection","_len","scrollEl","scrollRootEl","lastAutoScrollX","lastAutoScrollY","touchEvt$1","pointerElemChangedInterval","autoScrolls","scrolling","AutoScrollPlugin","AutoScroll","scroll","forceAutoScrollFallback","scrollSensitivity","scrollSpeed","bubbleScroll","_handleAutoScroll","_handleFallbackAutoScroll","dragOverCompleted","_ref2","dragOverBubble","drop","clearPointerElemChangedInterval","clearAutoScrolls","nulling","autoScroll","ogElemScroller","newElem","pid","lastSwapEl","isFallback","scrollCustomFn","sens","scrollThisInstance","scrollFn","layersOut","currentParent","canScrollX","canScrollY","scrollPosX","scrollPosY","layer","scrollOffsetY","scrollOffsetX","toSortable","onSpill","Revert","Remove","SwapPlugin","Swap","swapClass","dragStart","dragOverValid","prevSwapEl","_ref3","swapNodes","swapItem","isEqualNode","_ref4","parentSortable","lastMultiDragSelect","multiDragSortable","dragEl$1","clonesFromRect","clonesHidden","multiDragElements","multiDragClones","initialFolding","folding","MultiDragPlugin","MultiDrag","_deselectMultiDrag","_checkKeyDown","_checkKeyUp","selectedClass","multiDragKey","multiDragElement","multiDragKeyDown","isMultiDrag","delayStartGlobal","delayEnded","setupClone","sortableIndex","insertMultiDragClones","showClone","hideClone","_ref5","dragStartGlobal","_ref6","multiDrag","_ref7","_this2","removeMultiDragElements","dragOver","_ref8","_ref9","insertMultiDragElements","_ref10","dragRectAbsolute","clonesHiddenBefore","dragOverAnimationCapture","_ref11","dragMatrix","dragOverAnimationComplete","_ref12","originalEvt","shiftKey","lastIndex","multiDragIndex","nullingGlobal","destroyGlobal","select","deselect","_this3","oldIndicies","newIndicies","clones","clonesInserted","elementsInserted","freeGlobal","punycode","maxInt","base","tMin","tMax","damp","initialBias","initialN","delimiter","regexPunycode","regexNonASCII","regexSeparators","errors","baseMinusTMin","stringFromCharCode","mapDomain","parts","labels","encoded","ucs2decode","counter","ucs2encode","basicToDigit","codePoint","digitToBasic","digit","adapt","numPoints","firstTime","basic","oldi","baseMinusT","inputLength","bias","handledCPCount","basicLength","currentValue","handledCPCountPlusOne","qMinusT","toUnicode","toASCII","util","slashes","auth","query","pathname","urlParse","urlResolve","urlFormat","protocolPattern","portPattern","simplePathPattern","delims","unwise","autoEscape","nonHostChars","hostEndingChars","hostnameMaxLen","hostnamePartPattern","hostnamePartStart","unsafeProtocol","hostlessProtocol","slashedProtocol","querystring","parseQueryString","slashesDenoteHost","u","relative","urlResolveObject","resolveObject","queryIndex","splitter","uSplit","slashRegex","simplePath","lowerProto","atSign","hostEnd","hec","parseHost","ipv6Hostname","hostparts","part","newpart","validParts","notHost","bit","ae","esc","escape","qm","rel","tkeys","tk","tkey","rkeys","rk","rkey","relPath","isSourceAbs","isRelAbs","mustEndAbs","removeAllDots","srcPath","psychotic","isNullOrUndefined","authInHost","isNull","hasTrailingSlash","up","isAbsolute","sfc","__vccOpts","T","C","D","return","L","inheritAttrs","autocomplete","modelValue","placeholder","tabindex","autofocus","comboboxUid","emits","setup","focus","handleInput","handleChange","handleFocus","handleBlur","handleEscape","$slots","ref","onInput","onFocus","onBlur","onKeyup","__file","U","every","selected","collapseTags","dataAttrs","handleClick","collapsed","onMousedown","onClick","maxHeight","highlightedOriginalIndex","handleClickItem","handleMouseenter","role","hidden","highlighted","originalIndex","onMouseenter","valueBy","Z","Q","pointerForward","pointerBackward","pointerSet","Y","emptyModelValue","labelBy","disabledBy","groupBy","visibleOptions","multiple","searchable","searchPlaceholder","clearOnSelect","clearOnClose","taggable","closeOnSelect","hideSelected","openDirection","refs","activeElement","relatedTarget","Set","F","originalOption","A","Event","K","querySelector","$el","immediate","J","X","ne","te","isFocusing","dropdown","toggle","searchingInputValue","handleInputForInput","handleChangeForInput","handleFocusForInput","handleBlurForInput","optionsWithInfo","addOrRemoveOption","innerPlaceholder","pointerFirst","pointerLast","typeAhead","components","VInput","VTags","VDropdown","__VERSION__","le","$attrs","onKeypress","$event","onKeydown","readonly","alt","onEscape","onClickItem","script","autosize","important","maxHeightScroll","computedStyles","isResizeImportant","isOverflowImportant","imp","isHeightImportant","_val","$nextTick","contentHeight","heightVal","created","mounted","normalizeComponent","scopeId","isFunctionalTemplate","moduleIdentifier","shadowMode","createInjector","createInjectorSSR","createInjectorShadow","hook","staticRenderFns","_compiled","functional","_scopeId","$vnode","ssrContext","__VUE_SSR_CONTEXT__","_registeredComponents","_ssrRegister","$root","$options","existing","beforeCreate","normalizeComponent_1","__vue_script__","__vue_render__","_vm","$createElement","_self","directives","rawName","expression","domProps","composing","__vue_staticRenderFns__","__vue_inject_styles__","__vue_scope_id__","__vue_module_identifier__","__vue_is_functional_template__","TextareaAutosize","Vue","component","activeEffectScope","effectScopeStack","EffectScope","detached","effects","cleanups","scopes","fromParent","effectScope","recordEffectScope","effect","getCurrentScope","onScopeDispose","createDep","dep","wasTracked","trackOpBit","newTracked","initDepMarkers","deps","finalizeDepMarkers","ptr","delete","targetMap","effectTrackDepth","maxMarkerBits","effectStack","activeEffect","ITERATE_KEY","MAP_KEY_ITERATE_KEY","ReactiveEffect","scheduler","enableTracking","cleanupEffect","resetTracking","onStop","_effect","lazy","runner","shouldTrack","trackStack","pauseTracking","track","isTracking","depsMap","Map","eventInfo","trackEffects","debuggerEventExtraInfo","trigger","oldTarget","triggerEffects","allowRecurse","isNonTrackableKeys","builtInSymbols","createGetter","shallowGet","readonlyGet","shallowReadonlyGet","arrayInstrumentations","createArrayInstrumentations","instrumentations","isReadonly","shallow","receiver","shallowReadonlyMap","readonlyMap","shallowReactiveMap","reactiveMap","targetIsArray","isRef","shouldUnwrap","reactive","createSetter","shallowSet","hadKey","deleteProperty","mutableHandlers","readonlyHandlers","shallowReactiveHandlers","shallowReadonlyHandlers","toShallow","getProto","get$1","isShallow","rawTarget","rawKey","wrap","toReadonly","toReactive","has$1","set$1","deleteEntry","hadItems","createForEach","observed","createIterableMethod","targetIsMap","isPair","isKeyOnly","innerIterator","createReadonlyMethod","createInstrumentations","mutableInstrumentations","shallowInstrumentations","readonlyInstrumentations","shallowReadonlyInstrumentations","iteratorMethods","createInstrumentationGetter","mutableCollectionHandlers","shallowCollectionHandlers","readonlyCollectionHandlers","shallowReadonlyCollectionHandlers","targetTypeMap","rawType","getTargetType","isExtensible","createReactiveObject","shallowReactive","shallowReadonly","baseHandlers","collectionHandlers","proxyMap","existingProxy","targetType","proxy","Proxy","isReactive","isProxy","raw","markRaw","trackRefValue","triggerRefValue","newVal","createRef","shallowRef","rawValue","RefImpl","_shallow","_rawValue","triggerRef","unref","shallowUnwrapHandlers","proxyRefs","objectWithRefs","CustomRefImpl","factory","_get","_set","customRef","toRefs","toRef","ObjectRefImpl","_defaultValue","ComputedRefImpl","getter","_setter","_dirty","getterOrOptions","debugOptions","onlyGetter","cRef","devtools","devtoolsNotInstalled","setDevtoolsHook","HTMLElement","replay","__VUE_DEVTOOLS_HOOK_REPLAY__","newHook","emit$1","rawArgs","vnode","modelArg","modifiersKey","handlerName","handler","callWithAsyncErrorHandling","onceHandler","emitted","normalizeEmitsOptions","comp","appContext","asMixin","emitsCache","cached","hasExtends","extendEmits","normalizedFromExtend","mixins","extends","isEmitListener","currentRenderingInstance","currentScopeId","setCurrentRenderingInstance","__scopeId","pushScopeId","popScopeId","withScopeId","_id","withCtx","isNonScopedSlot","_n","renderFnWithContext","setBlockTracking","prevInstance","renderComponentRoot","Component","withProxy","propsOptions","slots","attrs","renderCache","setupState","fallthroughAttrs","shapeFlag","proxyToUse","normalizeVNode","getFunctionalFallthrough","blockStack","handleError","createVNode","Comment","filterModelListeners","cloneVNode","dirs","filterSingleRoot","singleRoot","isVNode","shouldUpdateComponent","prevVNode","nextVNode","optimized","prevProps","prevChildren","nextProps","nextChildren","patchFlag","emitsOptions","$stable","hasPropsChanged","dynamicProps","nextKeys","updateHOCHostEl","subTree","isSuspense","__isSuspense","SuspenseImpl","parentComponent","parentSuspense","isSVG","slotScopeIds","rendererInternals","mountSuspense","patchSuspense","hydrate","hydrateSuspense","createSuspenseBoundary","normalizeSuspenseChildren","Suspense","triggerEvent","eventListener","patch","hiddenContainer","suspense","pendingBranch","ssContent","ssFallback","setActiveBranch","um","unmount","newBranch","newFallback","activeBranch","isInFallback","isHydrating","isSameVNodeType","pendingId","move","isUnmounted","delayEnter","hasUnresolvedAncestor","queuePostFlushCb","fallbackVNode","mountFallback","registerDep","setupRenderEffect","isInPendingSuspense","hydratedEl","asyncDep","asyncSetupResult","suspenseId","asyncResolved","handleSetupResult","doRemove","hydrateNode","isSlotChildren","normalizeSuspenseSlot","block","trackBlock","isBlockTreeEnabled","openBlock","currentBlock","closeBlock","singleChild","dynamicChildren","queueEffectWithSuspense","branch","provide","currentInstance","provides","parentProvides","inject","treatDefaultAsFactory","useTransitionState","isMounted","isLeaving","isUnmounting","leavingVNodes","onMounted","onBeforeUnmount","TransitionHookValidator","BaseTransitionImpl","persisted","onBeforeEnter","onEnter","onAfterEnter","onEnterCancelled","onBeforeLeave","onLeave","onAfterLeave","onLeaveCancelled","onBeforeAppear","onAppear","onAfterAppear","onAppearCancelled","getCurrentInstance","prevTransitionKey","getTransitionRawChildren","rawProps","emptyPlaceholder","innerChild","getKeepAliveChild","enterHooks","resolveTransitionHooks","setTransitionHooks","oldChild","oldInnerChild","transitionKeyChanged","getTransitionKey","leavingHooks","delayLeave","earlyRemove","delayedLeave","leavingVNodesCache","getLeavingNodesForType","_leaveCb","BaseTransition","callHook","hooks","leavingVNode","afterHook","cancelHook","called","_enterCb","isKeepAlive","keepComment","keyedFragmentCount","Fragment","defineComponent","isAsyncWrapper","__asyncLoader","defineAsyncComponent","loadingComponent","errorComponent","suspensible","userOnError","resolvedComp","pendingRequest","retries","retry","thisRequest","userRetry","userFail","__esModule","toStringTag","__asyncResolved","createInnerComp","delayed","queueJob","__isKeepAlive","KeepAliveImpl","include","exclude","sharedContext","_unmount","storageContainer","resetShapeFlag","pruneCache","getComponentName","pruneCacheEntry","queuePostRenderEffect","isDeactivated","vnodeHook","onVnodeMounted","invokeVNodeHook","da","onVnodeUnmounted","pendingCacheKey","cacheSubtree","getInnerChild","onUpdated","rawVNode","cachedVNode","KeepAlive","onActivated","registerKeepAliveHook","onDeactivated","wrappedHook","__wdc","injectHook","injectToKeepAliveRoot","keepAliveRoot","injected","onUnmounted","__weh","setCurrentInstance","unsetCurrentInstance","createHook","lifecycle","isInSSRComponentSetup","onBeforeMount","onBeforeUpdate","onServerPrefetch","onRenderTriggered","onRenderTracked","onErrorCaptured","shouldCacheAccess","applyOptions","resolveMergedOptions","publicThis","dataOptions","computedOptions","watchOptions","provideOptions","injectOptions","beforeMount","beforeUpdate","updated","activated","deactivated","beforeDestroy","beforeUnmount","unmounted","renderTracked","renderTriggered","errorCaptured","serverPrefetch","expose","checkDuplicateProperties","resolveInjections","unwrapInjectedRef","methodHandler","opt","createWatcher","registerLifecycleHook","register","_hook","exposed","unwrapRef","normalizeInject","createPathGetter","extendsOptions","globalMixins","optionsCache","optionMergeStrategies","resolved","mergeOptions","strats","strat","internalOptionMergeStrats","mergeDataFn","mergeObjectOptions","mergeAsArray","mergeWatchOptions","mergeInject","merged","initProps","isStateful","isSSR","InternalObjectKey","propsDefaults","setFullProps","updateProps","rawPrevProps","rawCurrentProps","hasAttrsChanged","kebabKey","resolvePropValue","propsToUpdate","camelizedKey","needCastKeys","rawCastValues","camelKey","castValues","isAbsent","hasDefault","normalizePropsOptions","propsCache","extendProps","normalizedKey","validatePropName","booleanIndex","getTypeIndex","stringIndex","getType","isSameType","expectedTypes","isInternalKey","normalizeSlotValue","normalizeSlot","rawSlot","normalizeObjectSlots","rawSlots","_ctx","normalizeVNodeSlots","initSlots","updateSlots","needDeletionCheck","deletionComparisonTarget","withDirectives","internalInstance","bindings","modifiers","traverse","invokeDirectiveHook","oldBindings","binding","createAppContext","app","isNativeTag","globalProperties","errorHandler","warnHandler","compilerOptions","createAppAPI","rootComponent","rootProps","installedPlugins","_uid","_component","_props","_container","_instance","directive","rootContainer","isHydrate","__vue_app__","getExposeProxy","setRef","rawRef","oldRawRef","isUnmount","refValue","owner","oldRef","callWithErrorHandling","_isString","_isRef","doSet","hasMismatch","isSVGContainer","namespaceURI","isComment","createHydrationFunctions","mt","mountComponent","patchProp","insert","createComment","hasChildNodes","flushPostFlushCbs","isFragmentStart","onMismatch","handleMismatch","domType","nextNode","Static","needToAdoptContent","staticCount","outerHTML","hydrateFragment","hydrateElement","locateClosingAsyncAnchor","previousSibling","createTextVNode","hydrateChildren","forcePatchValue","endsWith","vnodeHooks","onVnodeBeforeMount","cur","parentVNode","fragmentSlotScopeIds","isFragment","initFeatureFlags","createRenderer","baseCreateRenderer","createHydrationRenderer","createHydrationFns","__VUE__","hostInsert","hostRemove","hostPatchProp","hostCreateElement","createText","hostCreateText","hostCreateComment","setText","hostSetText","setElementText","hostSetElementText","hostParentNode","hostNextSibling","setScopeId","hostSetScopeId","hostCloneNode","insertStaticContent","hostInsertStaticContent","getNextHostNode","processText","processCommentNode","mountStaticNode","processFragment","processElement","processComponent","internals","moveStaticNode","removeStaticNode","mountElement","patchElement","mountChildren","unmountChildren","needCallTransitionHooks","cloneIfMounted","oldProps","newProps","toggleRecurse","onVnodeBeforeUpdate","areChildrenSVG","patchBlockChildren","patchChildren","patchProps","onVnodeUpdated","newChildren","fallbackContainer","oldVNode","newVNode","fragmentStartAnchor","fragmentEndAnchor","traverseStaticChildren","updateComponent","initialVNode","createComponentInstance","setupComponent","updateComponentPreRender","invalidateJob","componentUpdateFn","bu","originNext","nextTree","prevTree","bm","isAsyncWrapperVNode","hydrateSubTree","scopedInitialVNode","flushPreFlushCbs","prevShapeFlag","patchKeyedChildren","patchUnkeyedChildren","oldLength","newLength","commonLength","parentAnchor","l2","e1","e2","nextPos","s1","s2","keyToNewIndexMap","patched","toBePatched","maxNewIndexSoFar","newIndexToOldIndexMap","increasingNewIndexSequence","getSequence","nextIndex","moveType","needTransition","performLeave","shouldInvokeDirs","shouldInvokeVnodeHook","onVnodeBeforeUnmount","unmountComponent","removeFragment","performRemove","bum","_vnode","mc","pc","pbc","createApp","allowed","ch1","ch2","arrI","isTeleport","__isTeleport","isTeleportDisabled","isTargetSVG","SVGElement","resolveTarget","targetSelector","TeleportImpl","mainAnchor","targetAnchor","wasDisabled","currentContainer","currentAnchor","moveTeleport","nextTarget","hydrateTeleport","isReorder","targetNode","_lpa","Teleport","COMPONENTS","DIRECTIVES","resolveComponent","maybeSelfReference","resolveAsset","NULL_DYNAMIC_COMPONENT","resolveDynamicComponent","resolveDirective","warnMissing","selfName","registry","disableTracking","vnodeArgsTransformer","setupBlock","createElementBlock","createBaseVNode","createBlock","__v_isVNode","transformVNodeArgs","transformer","normalizeKey","normalizeRef","ref_key","ref_for","isBlockNode","needFullChildrenNormalization","__v_skip","normalizeChildren","_createVNode","cloned","isClassComponent","guardReactiveProps","extraProps","mergeRef","mergedProps","mergeProps","createStaticVNode","content","numberOfNodes","createCommentVNode","asBlock","memo","slot","slotFlag","toMerge","incoming","renderList","renderItem","createSlots","dynamicSlots","renderSlot","noSlotted","isCE","validSlotContent","ensureValidVNode","rendered","vnodes","toHandlers","getPublicInstance","isStatefulComponent","publicPropertiesMap","$data","$props","$refs","$parent","$forceUpdate","$watch","instanceWatch","PublicInstanceProxyHandlers","accessCache","normalizedProps","publicGetter","cssModule","__cssModules","RuntimeCompiledPublicInstanceProxyHandlers","unscopables","emptyAppContext","uid$1","exposeProxy","setupContext","bc","rtg","rtc","ec","sp","ce","compile","installWithProxy","setupResult","setupStatefulComponent","createSetupContext","resolvedResult","finishComponentSetup","__ssrInlineRender","ssrRender","registerRuntimeCompiler","_compile","_rc","skipOptions","isCustomElement","delimiters","componentCompilerOptions","finalCompilerOptions","createAttrsProxy","classifyRE","classify","displayName","formatComponentName","isRoot","inferFromRegistry","msg","appWarnHandler","trace","getComponentTrace","warnArgs","formatTrace","currentVNode","normalizedStack","recurseCount","parentInstance","logs","formatTraceEntry","formatProps","formatProp","throwInDev","contextVNode","exposedInstance","errorInfo","errorCapturedHooks","appErrorHandler","logError","isFlushing","isFlushPending","flushIndex","pendingPreFlushCbs","activePreFlushCbs","preFlushIndex","pendingPostFlushCbs","activePostFlushCbs","postFlushIndex","resolvedPromise","currentFlushPromise","currentPreFlushParentJob","findInsertionIndex","middle","middleJobId","getId","job","queueFlush","flushJobs","queueCb","activeQueue","pendingQueue","queuePreFlushCb","seen","parentJob","deduped","watchEffect","doWatch","watchPostEffect","watchSyncEffect","INITIAL_WATCHER_VALUE","onTrack","onTrigger","forceTrigger","isMultiSource","onInvalidate","baseGetter","defineProps","defineEmits","defineExpose","withDefaults","useSlots","useAttrs","mergeDefaults","createPropsRestProxy","excludedKeys","withAsyncContext","getAwaitable","awaitable","propsOrChildren","ssrContextKey","useSSRContext","withMemo","isMemoSame","_ssrUtils","ssrUtils","resolveFilter","compatUtils","svgNS","doc","staticTemplateCache","nodeOps","createElementNS","createTextNode","nodeValue","before","patchClass","transitionClasses","_vtc","patchStyle","isCssString","currentDisplay","importantRE","setProperty","autoPrefix","prefixes","prefixCache","xlinkNS","patchAttr","removeAttributeNS","setAttributeNS","isBoolean","patchDOMProp","_getNow","skipTimestampCheck","timeStamp","ffMatch","cachedNow","getNow","patchEvent","prevValue","nextValue","invokers","_vei","existingInvoker","parseName","invoker","createInvoker","optionsModifierRE","initialValue","attached","patchStopImmediatePropagation","originalStop","_stopped","nativeOnRE","shouldSetAsProp","_trueValue","_falseValue","defineCustomElement","hydate","Comp","VueCustomElement","VueElement","initialProps","defineSSRCustomElement","BaseClass","_def","_connected","_resolved","_numberProps","attachShadow","connectedCallback","_resolveDef","disconnectedCallback","_setAttr","MutationObserver","mutations","observe","styles","hasOptions","rawKeys","numberProps","_setProp","_getProp","_applyStyles","_update","asyncDef","shouldReflect","shouldUpdate","detail","useCssModule","modules","mod","useCssVars","setVars","setVarsOnVNode","ob","childList","disconnect","vars","setVarsOnNode","TRANSITION","ANIMATION","Transition","resolveTransitionProps","DOMTransitionPropsValidators","enterFromClass","enterActiveClass","enterToClass","appearFromClass","appearActiveClass","appearToClass","leaveFromClass","leaveActiveClass","leaveToClass","TransitionPropsValidators","hasExplicitCallback","baseProps","durations","normalizeDuration","enterDuration","leaveDuration","finishEnter","isAppear","removeTransitionClass","finishLeave","makeEnterHook","nextFrame","addTransitionClass","whenTransitionEnds","forceReflow","NumberOf","cls","endId","expectedType","explicitTimeout","_endId","resolveIfNotStale","propCount","getTransitionInfo","endEvent","onEnd","getStyleProperties","transitionDelays","transitionDurations","transitionTimeout","getTimeout","animationDelays","animationDurations","animationTimeout","hasTransform","delays","toMs","positionMap","newPositionMap","TransitionGroupImpl","moveClass","hasCSSTransform","callPendingCbs","recordPosition","movedChildren","applyTranslation","webkitTransform","transitionDuration","_moveCb","cssTransitionProps","TransitionGroup","oldPos","getModelAssigner","onCompositionStart","onCompositionEnd","vModelText","_assign","castToNumber","domValue","vModelCheckbox","_modelValue","elementValue","getValue","found","filtered","getCheckboxValue","setChecked","vModelRadio","vModelSelect","isSetModel","selectedVal","setSelected","_binding","isMultiple","optionValue","selectedIndex","vModelDynamic","callModelHook","modelToUse","initVModelForSSR","getSSRProps","systemModifiers","modifierGuards","prevent","ctrl","ctrlKey","altKey","metaKey","exact","withModifiers","guard","keyNames","space","down","withKeys","eventKey","vShow","_vod","setDisplay","initVShowForSSR","rendererOptions","enabledHydration","ensureRenderer","ensureHydrationRenderer","containerOrSelector","normalizeContainer","Element","createSSRApp","ssrDirectiveInitialized","initDirectivesForSSR","defaultOnError","defaultOnWarn","createCompilerError","messages","additionalMessage","FRAGMENT","TELEPORT","SUSPENSE","KEEP_ALIVE","BASE_TRANSITION","OPEN_BLOCK","CREATE_BLOCK","CREATE_ELEMENT_BLOCK","CREATE_VNODE","CREATE_ELEMENT_VNODE","CREATE_COMMENT","CREATE_TEXT","CREATE_STATIC","RESOLVE_COMPONENT","RESOLVE_DYNAMIC_COMPONENT","RESOLVE_DIRECTIVE","RESOLVE_FILTER","WITH_DIRECTIVES","RENDER_LIST","RENDER_SLOT","CREATE_SLOTS","TO_DISPLAY_STRING","MERGE_PROPS","NORMALIZE_CLASS","NORMALIZE_STYLE","NORMALIZE_PROPS","GUARD_REACTIVE_PROPS","TO_HANDLERS","CAMELIZE","CAPITALIZE","TO_HANDLER_KEY","SET_BLOCK_TRACKING","PUSH_SCOPE_ID","POP_SCOPE_ID","WITH_CTX","UNREF","IS_REF","WITH_MEMO","IS_MEMO_SAME","helperNameMap","registerRuntimeHelpers","helpers","locStub","column","createRoot","hoists","imports","temps","codegenNode","createVNodeCall","isBlock","isComponent","helper","getVNodeBlockHelper","inSSR","getVNodeHelper","createArrayExpression","createObjectExpression","createObjectProperty","createSimpleExpression","constType","createCompoundExpression","createCallExpression","createFunctionExpression","params","returns","newline","isSlot","createConditionalExpression","consequent","alternate","createCacheExpression","createBlockStatement","isStaticExp","isBuiltInType","expected","isCoreComponent","nonIdentifierRE","isSimpleIdentifier","validFirstIdentCharRE","validIdentCharRE","whitespaceRE","isMemberExpressionBrowser","stateStack","currentOpenBracketCount","currentOpenParensCount","currentStringType","isMemberExpression","getInnerRange","newLoc","advancePositionWithClone","numberOfCharacters","advancePositionWithMutation","linesCount","lastNewLinePos","findDir","allowEmpty","exp","findProp","dynamicOnly","isStaticArgOf","hasDynamicKeyVBind","isText","isVSlot","isTemplateNode","tagType","isSlotOutlet","ssr","propsHelperSet","getUnnormalizedProps","callPath","injectProp","propsWithInjection","parentCall","alreadyExists","propKeyName","toValidAssetId","searchValue","replaceValue","getMemoedVNodeCall","makeBlock","removeHelper","getCompatValue","compatConfig","isCompatEnabled","checkCompatEnabled","decodeRE","decodeMap","gt","amp","apos","quot","defaultParserOptions","getNamespace","getTextMode","isPreTag","decodeEntities","rawText","onWarn","comments","createParserContext","getCursor","parseChildren","rawOptions","originalSource","inPre","inVPre","ancestors","ns","nodes","isEnd","parseInterpolation","emitError","parseComment","parseBogusComment","parseCDATA","advanceBy","parseTag","parseElement","isSpecialTemplateDirective","parseText","pushNode","removedWhitespace","shouldCondense","whitespace","prevIndex","nestedIndex","contentStart","closeIndex","wasInPre","wasInVPre","isPreBoundary","isVPreBoundary","isSelfClosing","inlineTemplateProp","startsWithEndTagOpen","advanceSpaces","currentSource","parseAttributes","isBuiltInComponent","attributeNames","attr","parseAttribute","nameSet","parseAttributeValue","isPropShorthand","dirName","startOffset","getNewPosition","isQuoted","valueLoc","quote","parseTextData","unexpectedChars","innerStart","innerEnd","rawContentLength","rawContent","preTrimContent","endTokens","xs","searchString","hoistStatic","walk","isSingleElementRoot","doNotHoistNode","originalCount","hoistedCount","constantType","getConstantType","hoist","getPatchFlag","getGeneratedPropsConstantType","getNodeProps","vSlot","branches","transformHoist","constantCache","returnType","generatedPropsType","childType","expType","allowHoistedHelperSet","getConstantTypeOfHelperCall","keyType","valueType","createTransformContext","filename","prefixIdentifiers","cacheHandlers","nodeTransforms","directiveTransforms","expressionPlugins","slotted","ssrCssVars","bindingMetadata","inline","isTS","nameMatch","identifiers","vFor","vPre","vOnce","currentNode","childIndex","inVOnce","currentCount","helperString","replaceNode","removalIndex","onNodeRemoved","addIdentifiers","removeIdentifiers","hoisted","traverseNode","createRootCodegen","traverseChildren","nodeRemoved","exitFns","onExit","createStructuralDirectiveTransform","PURE_ANNOTATION","createCodegenContext","ast","sourceMap","optimizeImports","runtimeGlobalName","runtimeModuleName","ssrRuntimeModuleName","indentLevel","pure","indent","deindent","withoutNewLine","generate","onContextCreated","hasHelpers","useWithBlock","preambleContext","genFunctionPreamble","functionName","genAssets","genNode","preamble","toJSON","VueBinding","aliasHelper","staticHelpers","genHoists","assets","resolver","genNodeListAsArray","multilines","genNodeList","comma","genText","genExpression","genInterpolation","genCompoundExpression","genComment","genVNodeCall","genCallExpression","genObjectExpression","genArrayExpression","genFunctionExpression","genConditionalExpression","genCacheExpression","genExpressionAsPropertyKey","callHelper","genNullableArgs","needNewline","needsParens","isNested","transformIf","processIf","ifNode","siblings","createCodegenNodeForBranch","parentCondition","getParentCondition","processCodegen","createIfBranch","condition","userKey","keyIndex","createChildrenCodegenNode","keyProperty","needFragmentWrapper","vnodeCall","transformFor","processFor","forNode","renderExp","keyProp","keyExp","isStableFragment","fragmentFlag","childBlock","isTemplate","slotOutlet","createForLoopParams","parseResult","parseForExpression","valueAlias","keyAlias","objectIndexAlias","forAliasRE","forIteratorRE","stripParensRE","inMatch","LHS","RHS","createAliasExpression","valueContent","trimmedOffset","iteratorMatch","keyContent","keyOffset","indexContent","memoArgs","createParamsList","defaultFallback","trackSlotScopes","buildClientSlotFn","buildSlots","buildSlotFn","slotsProperties","hasDynamicSlots","onComponentSlot","hasTemplateSlots","hasNamedDefaultSlot","implicitDefaultChildren","seenSlotNames","slotElement","slotDir","slotChildren","slotLoc","slotName","slotProps","dirLoc","staticSlotName","slotFunction","vIf","vElse","buildDynamicSlot","conditional","buildDefaultSlotProperty","isNonWhitespaceContent","hasForwardedSlots","directiveImportMap","transformElement","vnodeTag","resolveComponentType","isDynamicComponent","vnodeProps","vnodeChildren","vnodePatchFlag","vnodeDynamicProps","dynamicPropNames","vnodeDirectives","shouldUseBlock","propsBuildResult","buildProps","buildDirectiveArgs","shouldBuildAsSlots","hasDynamicTextChild","stringifyDynamicPropNames","isExplicitDynamic","isComponentTag","isProp","isDir","builtIn","elementLoc","mergeArgs","runtimeDirectives","hasChildren","hasRef","hasClassBinding","hasStyleBinding","hasHydrationEventBinding","hasDynamicKeys","hasVnodeHook","analyzePatchFlag","isEventHandler","isVBind","isVOn","dedupeProperties","directiveTransform","needRuntime","propsExpression","classKeyIndex","styleKeyIndex","hasDynamicKey","isHandlerKey","classProp","styleProp","knownProps","dirArgs","runtime","trueExpression","modifier","propsNamesString","transformSlotOutlet","processSlotOutlet","slotArgs","expectedLen","nonNameProps","fnExpRE","transformOn","augmentor","shouldCache","isMemberExp","isInlineStatement","hasMultipleStatements","transformBind","_node","injectPrefix","transformText","hasText","callArgs","WeakSet","transformOnce","transformModel","createTransformProps","rawExp","expString","maybeRef","propName","assignmentExp","eventArg","validDivisionCharRE","transformFilter","rewriteFilter","parseFilter","inSingle","inDouble","inTemplateString","inRegex","curly","paren","lastFilterIndex","pushFilter","wrapFilter","seen$1","transformMemo","getBaseTransformPreset","model","baseCompile","isModuleMode","noopDirectiveTransform","V_MODEL_RADIO","V_MODEL_CHECKBOX","V_MODEL_TEXT","V_MODEL_SELECT","V_MODEL_DYNAMIC","V_ON_WITH_MODIFIERS","V_ON_WITH_KEYS","V_SHOW","TRANSITION_GROUP","decoder","decodeHtmlBrowser","asAttr","isRawTextContainer","parserOptions","transformStyle","parseInlineCSS","createDOMCompilerError","transformVHtml","transformVText","baseResult","directiveToUse","isInvalidType","isEventOptionModifier","isNonKeyModifier","maybeKeyModifier","isKeyboardEvent","resolveModifiers","keyModifiers","nonKeyModifiers","eventOptionModifiers","transformClick","isStaticClick","handlerExp","modifierPostfix","transformShow","ignoreSideEffectTags","DOMNodeTransforms","DOMDirectiveTransforms","cloak","show","compileCache","compileToFunction","__WEBPACK_EXTERNAL_MODULE__8bbf__","__WEBPACK_EXTERNAL_MODULE_a352__","installedModules","moduleId","nativeGetOwnPropertyNames","windowNames","getWindowNames","nativeGetOwnPropertyDescriptor","$reduce","arrayMethodIsStrict","arrayMethodUsesToLength","STRICT_METHOD","USES_TO_LENGTH","callbackfn","regexpExec","DOMIterables","COLLECTION_NAME","Collection","CollectionPrototype","$forEach","ITERATOR","SAFE_CLOSING","iteratorWithReturn","SKIP_CLOSING","ITERATION_SUPPORT","SPECIES","METHOD_NAME","foo","toInteger","TO_STRING","RegExpPrototype","nativeToString","NOT_GENERIC","INCORRECT_NAME","rf","notARegExp","correctIsRegExpLogic","nativeStartsWith","CORRECT_IS_REGEXP_LOGIC","MDN_POLYFILL_BUG","Iterators","objectKeys","Properties","defineIterator","STRING_ITERATOR","setInternalState","iterated","UNSCOPABLES","ArrayPrototype","MATCH","isRegExp","$filter","arrayMethodHasSpeciesSupport","HAS_SPECIES_SUPPORT","callWithSafeIterationClosing","isArrayIteratorMethod","createProperty","getIteratorMethod","arrayLike","mapfn","mapping","iteratorMethod","$entries","fixRegExpWellKnownSymbolLogic","advanceStringIndex","regExpExec","SUBSTITUTION_SYMBOLS","SUBSTITUTION_SYMBOLS_NO_NAMED","maybeToString","REPLACE","nativeReplace","maybeCallNative","REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE","REPLACE_KEEPS_$0","UNSAFE_SUBSTITUTE","functionalReplace","fullUnicode","unicode","results","matchStr","accumulatedResult","nextSourcePosition","matched","captures","namedCaptures","groups","replacerArgs","getSubstitution","tailPos","ch","flattenIntoArray","arraySpeciesCreate","flatMap","sourceLen","CONVERT_TO_STRING","codeAt","originalArray","objectHas","TO_ENTRIES","addToUnscopables","wrappedWellKnownSymbolModule","NAME","activeXDocument","documentCreateElement","GT","LT","PROTOTYPE","SCRIPT","IE_PROTO","EmptyConstructor","scriptTag","NullProtoObjectViaActiveX","write","parentWindow","NullProtoObjectViaIFrame","iframeDocument","iframe","JS","contentWindow","NullProtoObject","domain","ActiveXObject","createIteratorConstructor","setToStringTag","IteratorsCore","IteratorPrototype","BUGGY_SAFARI_ITERATORS","KEYS","VALUES","ENTRIES","returnThis","Iterable","IteratorConstructor","IS_SET","CurrentIteratorPrototype","KEY","getIterationMethod","KIND","defaultIterator","IterablePrototype","INCORRECT_VALUES_NAME","nativeIterator","anyNativeIterator","propertyKey","__webpack_require__","__WEBPACK_AMD_DEFINE_FACTORY__","__WEBPACK_AMD_DEFINE_ARRAY__","__WEBPACK_AMD_DEFINE_RESULT__","getCurrentScript","currentScript","pageSource","inlineScriptSourceRegExp","inlineScriptSource","ieStackRegExp","ffStackRegExp","stackDetails","scriptLocation","scripts","regexpFlags","stickyHelpers","nativeExec","patchedExec","UPDATES_LAST_INDEX_WRONG","re1","re2","UNSUPPORTED_Y","BROKEN_CARET","NPCG_INCLUDED","PATCH","reCopy","re","sticky","charsAdded","strCopy","multiline","IS_CONCAT_SPREADABLE","MAX_SAFE_INTEGER","MAXIMUM_ALLOWED_INDEX_EXCEEDED","IS_CONCAT_SPREADABLE_SUPPORT","SPECIES_SUPPORT","isConcatSpreadable","spreadable","returnMethod","nativeDefineProperty","RE","original","mapper","targetIndex","sourceIndex","mapFn","ACCESSORS","MAXIMUM_ALLOWED_LENGTH_EXCEEDED","deleteCount","insertCount","actualDeleteCount","actualStart","nativeObjectCreate","getOwnPropertyNamesExternal","defineWellKnownSymbol","HIDDEN","SYMBOL","ObjectPrototype","$stringify","nativePropertyIsEnumerable","AllSymbols","ObjectPrototypeSymbols","StringToSymbolRegistry","SymbolToStringRegistry","QObject","USE_SETTER","findChild","setSymbolDescriptor","ObjectPrototypeDescriptor","$defineProperties","$getOwnPropertySymbols","$create","$getOwnPropertyNames","IS_OBJECT_PROTOTYPE","keyFor","useSetter","useSimple","FORCED_JSON_STRINGIFY","$replacer","checkCorrectnessOfIteration","INCORRECT_ITERATION","iterable","ignoreCase","dotAll","thrower","argument0","argument1","PrototypeOfArrayIteratorPrototype","arrayIterator","FunctionPrototypeToString","nameRE","nativeKeys","FAILS_ON_PRIMITIVES","IS_MAP","IS_FILTER","IS_SOME","IS_EVERY","IS_FIND_INDEX","NO_HOLES","specificCreate","boundFunction","PREFERRED_STRING","$findIndex","FIND_INDEX","SKIPS_HOLES","$indexOf","nativeIndexOf","NEGATIVE_ZERO","searchElement","$includes","variable","TAG","IS_RIGHT","REPLACE_SUPPORTS_NAMED_GROUPS","SPLIT_WORKS_WITH_OVERWRITTEN_EXEC","originalExec","DELEGATES_TO_SYMBOL","DELEGATES_TO_EXEC","execCalled","nativeRegExpMethod","nativeMethod","arg2","forceStringMethod","stringMethod","regexMethod","$map","__webpack_exports__","getConsole","ArrayIteratorMethods","ArrayValues","NativeSymbol","EmptyStringDescriptionStore","SymbolWrapper","symbolPrototype","symbolToString","desc","CORRECT_PROTOTYPE_GETTER","ARRAY_ITERATOR","kind","Arguments","_arrayWithHoles","_iterableToArrayLimit","_arr","_nonIterableRest","_slicedToArray","external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_","external_commonjs_sortablejs_commonjs2_sortablejs_amd_sortablejs_root_Sortable_default","insertNodeAt","fatherNode","refNode","manageAndEmit","manage","eventHandlerNames","isReadOnly","tags","isHtmlTag","isTransition","isHtmlAttribute","project","getComponentAttributes","_ref3$componentData","componentData","createSortableOption","callBackBuilder","getValidSortableEntries","eventType","eventBuilder","_ref13","_ref14","_classCallCheck","Constructor","_defineProperties","_createClass","protoProps","staticProps","getHtmlElementFromNode","addContext","domElement","__draggable_context","componentStructure_ComponentStructure","ComponentStructure","_ref2$nodes","defaultNodes","footer","realList","externalComponent","rootTransition","_isRootComponent","domIndex","domChildren","firstDomListElement","indexFirstDomListElement","external_commonjs_vue_commonjs2_vue_root_Vue_","getSlot","slotValue","computeNodes","getKey","normalizedList","_map","_map2","getRootInformation","computeComponentStructure","evtName","evtData","_manage","originalElement","_manageAndEmit","delegateCallBack","draggingElement","itemKey","draggableComponent","componentStructure","_this4","sortableOptions","targetDomElement","_sortable","__draggable_component__","newOptionValue","getUnderlyingVm","getUnderlyingPotencialDraggableComponent","htmElement","emitChanges","_this5","alterList","onList","newList","spliceList","updatePosition","getRelatedContextFromMoveEvent","destination","getVmIndexFromDomIndex","onDragStart","_underlying_vm_","onDragAdd","added","onDragRemove","_this$context","onDragUpdate","computeFutureIndex","relatedContext","currentDomIndex","draggedInList","onDragMove","futureIndex","draggedContext","sendEvent","onDragEnd","vuedraggable","nativeSlice","fin","CSSRuleList","CSSStyleDeclaration","CSSValueList","ClientRectList","DOMRectList","DOMStringList","DOMTokenList","DataTransferItemList","FileList","HTMLAllCollection","HTMLCollection","HTMLFormElement","HTMLSelectElement","MediaList","MimeTypeArray","NamedNodeMap","NodeList","PaintRequestList","Plugin","PluginArray","SVGLengthList","SVGNumberList","SVGPathSegList","SVGPointList","SVGStringList","SVGTransformList","SourceBufferList","StyleSheetList","TextTrackCueList","TextTrackList","TouchList","createNanoEvents","__defProp","__getOwnPropSymbols","__hasOwnProp","__propIsEnum","__defNormalProp","__spreadValues","isNonEmptyString","isNumber","isUndefined","isJSX","hasProp","isTouchEvent","isToastComponent","isToastContent","isVueComponent","isDOMRect","propKey","getX","targetTouches","getY","POSITION","EVENTS","removeElement","getVueComponentFromObj","toRaw","normalizeToastComponent","isBrowser","EventBus","allHandlers","getHandlers","isEventBusInterface","TYPE2","POSITION2","EVENTS2","VT_NAMESPACE","COMMON","classNames","trueBoolean","ICON","customIcon","CLOSE_BUTTON","showOnHover","ariaLabel","PROGRESS_BAR","hideProgressBar","isRunning","CORE_TOAST","TOP_RIGHT","draggablePercent","pauseOnFocusLoss","pauseOnHover","closeOnClick","toastClassName","bodyClassName","icon","closeButton","closeButtonClassName","showCloseButtonOnHover","accessibility","toastRole","closeButtonLabel","rtl","eventBus","TOAST","onClose","CONTAINER","newestOnTop","maxToasts","toastDefaults","filterBeforeCreate","toast","filterToasts","toasts","containerClassName","shareAppContext","propValidators_default","VtProgressBar_default","hasClass","animationDuration","animationPlayState","opacity","cpClass","animationEnded","_cache","VtProgressBar_default2","VtCloseButton_default","buttonComponent","classes","_hoisted_1","render2","VtCloseButton_default2","VtSuccessIcon_default","_hoisted_12","focusable","xmlns","viewBox","_hoisted_2","_hoisted_3","render3","VtSuccessIcon_default2","VtInfoIcon_default","_hoisted_13","_hoisted_22","_hoisted_32","render4","VtInfoIcon_default2","VtWarningIcon_default","_hoisted_14","_hoisted_23","_hoisted_33","render5","VtWarningIcon_default2","VtErrorIcon_default","_hoisted_15","_hoisted_24","_hoisted_34","render6","VtErrorIcon_default2","VtIcon_default","customIconChildren","trimValue","iconChildren","customIconClass","iconClass","customIconTag","iconTag","hasCustomIcon","iconTypeComponent","types","INFO","SUCCESS","ERROR","WARNING","iconClasses","render7","VtIcon_default2","VtToast_default","ProgressBar","CloseButton","Icon","disableTransitions","beingDragged","dragPos","bodyClasses","draggableStyle","dragDelta","removalDistance","draggableSetup","focusSetup","draggableCleanup","focusCleanup","closeToast","DISMISS","clickHandler","timeoutHandler","hoverPause","hoverPlay","focusPause","focusPlay","_hoisted_16","render8","_component_Icon","_component_CloseButton","_component_ProgressBar","onMouseleave","onCloseToast","VtToast_default2","VtTransition_default","render9","VtTransition_default2","VtToastContainer_default","hide","Toast","VtTransition","positions","toastArray","filteredToasts","ADD","addToast","clearToasts","dismissToast","UPDATE","updateToast","UPDATE_DEFAULTS","updateDefaults","async","setToast","getPositionToasts","getClasses","render10","_component_Toast","_component_VtTransition","VtToastContainer_default2","buildInterface","globalOptions","mountContainer","baseApp","dismiss","warning","createMockToastInterface","createToastInterface","optionsOrEventBus","toastInjectionKey","globalEventBus","VueToastificationPlugin","App","inter","useToast","src_default"],"sourceRoot":""} \ No newline at end of file diff --git a/manifest.webmanifest b/manifest.webmanifest new file mode 100644 index 0000000..7adc186 --- /dev/null +++ b/manifest.webmanifest @@ -0,0 +1 @@ +{"name":"Profectus Demo","short_name":"Profectus Demo","start_url":"/","display":"standalone","background_color":"#ffffff","lang":"en","scope":"/","description":"A demo project made in Profectus","theme_color":"#2E3440","icons":[{"src":"pwa-192x192.png","sizes":"192x192","type":"image/png"},{"src":"pwa-512x512.png","sizes":"512x512","type":"image/png"},{"src":"pwa-512x512.png","sizes":"512x512","type":"image/png","purpose":"any maskable"}]} diff --git a/android-chrome-192x192.png b/pwa-192x192.png similarity index 100% rename from android-chrome-192x192.png rename to pwa-192x192.png diff --git a/android-chrome-512x512.png b/pwa-512x512.png similarity index 100% rename from android-chrome-512x512.png rename to pwa-512x512.png diff --git a/robots.txt b/robots.txt new file mode 100644 index 0000000..c2a49f4 --- /dev/null +++ b/robots.txt @@ -0,0 +1,2 @@ +User-agent: * +Allow: / diff --git a/site.webmanifest b/site.webmanifest deleted file mode 100644 index 87d8130..0000000 --- a/site.webmanifest +++ /dev/null @@ -1 +0,0 @@ -{"name":"Profectus","short_name":"Profectus","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#2E3440","background_color":"#2E3440","display":"standalone"} \ No newline at end of file diff --git a/sw.js b/sw.js new file mode 100644 index 0000000..dbcefd0 --- /dev/null +++ b/sw.js @@ -0,0 +1 @@ +if(!self.define){let e,i={};const n=(n,s)=>(n=new URL(n+".js",s).href,i[n]||new Promise((i=>{if("document"in self){const e=document.createElement("script");e.src=n,e.onload=i,document.head.appendChild(e)}else e=n,importScripts(n),i()})).then((()=>{let e=i[n];if(!e)throw new Error(`Module ${n} didn’t register its module`);return e})));self.define=(s,r)=>{const o=e||("document"in self?document.currentScript.src:"")||location.href;if(i[o])return;let t={};const f=e=>n(e,o),c={module:{uri:o},exports:t,require:f};i[o]=Promise.all(s.map((e=>c[e]||f(e)))).then((e=>(r(...e),t)))}}define(["./workbox-b3e22772"],(function(e){"use strict";self.addEventListener("message",(e=>{e.data&&"SKIP_WAITING"===e.data.type&&self.skipWaiting()})),e.precacheAndRoute([{url:"assets/index.2bb81304.js",revision:null},{url:"assets/index.f4e7ecfe.css",revision:null},{url:"index.html",revision:"19863bbaafe79c9088cc06848e2fd8d2"},{url:"favicon.ico",revision:"eead31eb5b19fa3bdc34af83d898c0b7"},{url:"robots.txt",revision:"5e0bd1c281a62a380d7a948085bfe2d1"},{url:"apple-touch-icon.png",revision:"26e53bb981d06c8069ffd9d2a14fce0e"},{url:"pwa-192x192.png",revision:"a16785d9e890858c5b508e0ef6954aaf"},{url:"pwa-512x512.png",revision:"b84004b93fd62ef6599ff179372861a1"},{url:"manifest.webmanifest",revision:"260d2d896ecb4e61a05146a620428bf9"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))})); diff --git a/workbox-b3e22772.js b/workbox-b3e22772.js new file mode 100644 index 0000000..c46ed19 --- /dev/null +++ b/workbox-b3e22772.js @@ -0,0 +1 @@ +define(["exports"],(function(t){"use strict";try{self["workbox:core:6.5.2"]&&_()}catch(t){}const e=(t,...e)=>{let s=t;return e.length>0&&(s+=` :: ${JSON.stringify(e)}`),s};class s extends Error{constructor(t,s){super(e(t,s)),this.name=t,this.details=s}}try{self["workbox:routing:6.5.2"]&&_()}catch(t){}const n=t=>t&&"object"==typeof t?t:{handle:t};class i{constructor(t,e,s="GET"){this.handler=n(e),this.match=t,this.method=s}setCatchHandler(t){this.catchHandler=n(t)}}class r extends i{constructor(t,e,s){super((({url:e})=>{const s=t.exec(e.href);if(s&&(e.origin===location.origin||0===s.index))return s.slice(1)}),e,s)}}class o{constructor(){this.t=new Map,this.i=new Map}get routes(){return this.t}addFetchListener(){self.addEventListener("fetch",(t=>{const{request:e}=t,s=this.handleRequest({request:e,event:t});s&&t.respondWith(s)}))}addCacheListener(){self.addEventListener("message",(t=>{if(t.data&&"CACHE_URLS"===t.data.type){const{payload:e}=t.data,s=Promise.all(e.urlsToCache.map((e=>{"string"==typeof e&&(e=[e]);const s=new Request(...e);return this.handleRequest({request:s,event:t})})));t.waitUntil(s),t.ports&&t.ports[0]&&s.then((()=>t.ports[0].postMessage(!0)))}}))}handleRequest({request:t,event:e}){const s=new URL(t.url,location.href);if(!s.protocol.startsWith("http"))return;const n=s.origin===location.origin,{params:i,route:r}=this.findMatchingRoute({event:e,request:t,sameOrigin:n,url:s});let o=r&&r.handler;const c=t.method;if(!o&&this.i.has(c)&&(o=this.i.get(c)),!o)return;let a;try{a=o.handle({url:s,request:t,event:e,params:i})}catch(t){a=Promise.reject(t)}const h=r&&r.catchHandler;return a instanceof Promise&&(this.o||h)&&(a=a.catch((async n=>{if(h)try{return await h.handle({url:s,request:t,event:e,params:i})}catch(t){t instanceof Error&&(n=t)}if(this.o)return this.o.handle({url:s,request:t,event:e});throw n}))),a}findMatchingRoute({url:t,sameOrigin:e,request:s,event:n}){const i=this.t.get(s.method)||[];for(const r of i){let i;const o=r.match({url:t,sameOrigin:e,request:s,event:n});if(o)return i=o,(Array.isArray(i)&&0===i.length||o.constructor===Object&&0===Object.keys(o).length||"boolean"==typeof o)&&(i=void 0),{route:r,params:i}}return{}}setDefaultHandler(t,e="GET"){this.i.set(e,n(t))}setCatchHandler(t){this.o=n(t)}registerRoute(t){this.t.has(t.method)||this.t.set(t.method,[]),this.t.get(t.method).push(t)}unregisterRoute(t){if(!this.t.has(t.method))throw new s("unregister-route-but-not-found-with-method",{method:t.method});const e=this.t.get(t.method).indexOf(t);if(!(e>-1))throw new s("unregister-route-route-not-registered");this.t.get(t.method).splice(e,1)}}let c;const a=()=>(c||(c=new o,c.addFetchListener(),c.addCacheListener()),c);function h(t,e,n){let o;if("string"==typeof t){const s=new URL(t,location.href);o=new i((({url:t})=>t.href===s.href),e,n)}else if(t instanceof RegExp)o=new r(t,e,n);else if("function"==typeof t)o=new i(t,e,n);else{if(!(t instanceof i))throw new s("unsupported-route-type",{moduleName:"workbox-routing",funcName:"registerRoute",paramName:"capture"});o=t}return a().registerRoute(o),o}const u={googleAnalytics:"googleAnalytics",precache:"precache-v2",prefix:"workbox",runtime:"runtime",suffix:"undefined"!=typeof registration?registration.scope:""},l=t=>[u.prefix,t,u.suffix].filter((t=>t&&t.length>0)).join("-"),f=t=>t||l(u.precache),w=t=>t||l(u.runtime);function d(t,e){const s=e();return t.waitUntil(s),s}try{self["workbox:precaching:6.5.2"]&&_()}catch(t){}function p(t){if(!t)throw new s("add-to-cache-list-unexpected-type",{entry:t});if("string"==typeof t){const e=new URL(t,location.href);return{cacheKey:e.href,url:e.href}}const{revision:e,url:n}=t;if(!n)throw new s("add-to-cache-list-unexpected-type",{entry:t});if(!e){const t=new URL(n,location.href);return{cacheKey:t.href,url:t.href}}const i=new URL(n,location.href),r=new URL(n,location.href);return i.searchParams.set("__WB_REVISION__",e),{cacheKey:i.href,url:r.href}}class y{constructor(){this.updatedURLs=[],this.notUpdatedURLs=[],this.handlerWillStart=async({request:t,state:e})=>{e&&(e.originalRequest=t)},this.cachedResponseWillBeUsed=async({event:t,state:e,cachedResponse:s})=>{if("install"===t.type&&e&&e.originalRequest&&e.originalRequest instanceof Request){const t=e.originalRequest.url;s?this.notUpdatedURLs.push(t):this.updatedURLs.push(t)}return s}}}class g{constructor({precacheController:t}){this.cacheKeyWillBeUsed=async({request:t,params:e})=>{const s=(null==e?void 0:e.cacheKey)||this.h.getCacheKeyForURL(t.url);return s?new Request(s,{headers:t.headers}):t},this.h=t}}let R;async function m(t,e){let n=null;if(t.url){n=new URL(t.url).origin}if(n!==self.location.origin)throw new s("cross-origin-copy-response",{origin:n});const i=t.clone(),r={headers:new Headers(i.headers),status:i.status,statusText:i.statusText},o=e?e(r):r,c=function(){if(void 0===R){const t=new Response("");if("body"in t)try{new Response(t.body),R=!0}catch(t){R=!1}R=!1}return R}()?i.body:await i.blob();return new Response(c,o)}function v(t,e){const s=new URL(t);for(const t of e)s.searchParams.delete(t);return s.href}class q{constructor(){this.promise=new Promise(((t,e)=>{this.resolve=t,this.reject=e}))}}const U=new Set;try{self["workbox:strategies:6.5.2"]&&_()}catch(t){}function L(t){return"string"==typeof t?new Request(t):t}class b{constructor(t,e){this.u={},Object.assign(this,e),this.event=e.event,this.l=t,this.p=new q,this.g=[],this.R=[...t.plugins],this.m=new Map;for(const t of this.R)this.m.set(t,{});this.event.waitUntil(this.p.promise)}async fetch(t){const{event:e}=this;let n=L(t);if("navigate"===n.mode&&e instanceof FetchEvent&&e.preloadResponse){const t=await e.preloadResponse;if(t)return t}const i=this.hasCallback("fetchDidFail")?n.clone():null;try{for(const t of this.iterateCallbacks("requestWillFetch"))n=await t({request:n.clone(),event:e})}catch(t){if(t instanceof Error)throw new s("plugin-error-request-will-fetch",{thrownErrorMessage:t.message})}const r=n.clone();try{let t;t=await fetch(n,"navigate"===n.mode?void 0:this.l.fetchOptions);for(const s of this.iterateCallbacks("fetchDidSucceed"))t=await s({event:e,request:r,response:t});return t}catch(t){throw i&&await this.runCallbacks("fetchDidFail",{error:t,event:e,originalRequest:i.clone(),request:r.clone()}),t}}async fetchAndCachePut(t){const e=await this.fetch(t),s=e.clone();return this.waitUntil(this.cachePut(t,s)),e}async cacheMatch(t){const e=L(t);let s;const{cacheName:n,matchOptions:i}=this.l,r=await this.getCacheKey(e,"read"),o=Object.assign(Object.assign({},i),{cacheName:n});s=await caches.match(r,o);for(const t of this.iterateCallbacks("cachedResponseWillBeUsed"))s=await t({cacheName:n,matchOptions:i,cachedResponse:s,request:r,event:this.event})||void 0;return s}async cachePut(t,e){const n=L(t);var i;await(i=0,new Promise((t=>setTimeout(t,i))));const r=await this.getCacheKey(n,"write");if(!e)throw new s("cache-put-with-no-response",{url:(o=r.url,new URL(String(o),location.href).href.replace(new RegExp(`^${location.origin}`),""))});var o;const c=await this.v(e);if(!c)return!1;const{cacheName:a,matchOptions:h}=this.l,u=await self.caches.open(a),l=this.hasCallback("cacheDidUpdate"),f=l?await async function(t,e,s,n){const i=v(e.url,s);if(e.url===i)return t.match(e,n);const r=Object.assign(Object.assign({},n),{ignoreSearch:!0}),o=await t.keys(e,r);for(const e of o)if(i===v(e.url,s))return t.match(e,n)}(u,r.clone(),["__WB_REVISION__"],h):null;try{await u.put(r,l?c.clone():c)}catch(t){if(t instanceof Error)throw"QuotaExceededError"===t.name&&await async function(){for(const t of U)await t()}(),t}for(const t of this.iterateCallbacks("cacheDidUpdate"))await t({cacheName:a,oldResponse:f,newResponse:c.clone(),request:r,event:this.event});return!0}async getCacheKey(t,e){const s=`${t.url} | ${e}`;if(!this.u[s]){let n=t;for(const t of this.iterateCallbacks("cacheKeyWillBeUsed"))n=L(await t({mode:e,request:n,event:this.event,params:this.params}));this.u[s]=n}return this.u[s]}hasCallback(t){for(const e of this.l.plugins)if(t in e)return!0;return!1}async runCallbacks(t,e){for(const s of this.iterateCallbacks(t))await s(e)}*iterateCallbacks(t){for(const e of this.l.plugins)if("function"==typeof e[t]){const s=this.m.get(e),n=n=>{const i=Object.assign(Object.assign({},n),{state:s});return e[t](i)};yield n}}waitUntil(t){return this.g.push(t),t}async doneWaiting(){let t;for(;t=this.g.shift();)await t}destroy(){this.p.resolve(null)}async v(t){let e=t,s=!1;for(const t of this.iterateCallbacks("cacheWillUpdate"))if(e=await t({request:this.request,response:e,event:this.event})||void 0,s=!0,!e)break;return s||e&&200!==e.status&&(e=void 0),e}}class C extends class{constructor(t={}){this.cacheName=w(t.cacheName),this.plugins=t.plugins||[],this.fetchOptions=t.fetchOptions,this.matchOptions=t.matchOptions}handle(t){const[e]=this.handleAll(t);return e}handleAll(t){t instanceof FetchEvent&&(t={event:t,request:t.request});const e=t.event,s="string"==typeof t.request?new Request(t.request):t.request,n="params"in t?t.params:void 0,i=new b(this,{event:e,request:s,params:n}),r=this.q(i,s,e);return[r,this.U(r,i,s,e)]}async q(t,e,n){let i;await t.runCallbacks("handlerWillStart",{event:n,request:e});try{if(i=await this.L(e,t),!i||"error"===i.type)throw new s("no-response",{url:e.url})}catch(s){if(s instanceof Error)for(const r of t.iterateCallbacks("handlerDidError"))if(i=await r({error:s,event:n,request:e}),i)break;if(!i)throw s}for(const s of t.iterateCallbacks("handlerWillRespond"))i=await s({event:n,request:e,response:i});return i}async U(t,e,s,n){let i,r;try{i=await t}catch(r){}try{await e.runCallbacks("handlerDidRespond",{event:n,request:s,response:i}),await e.doneWaiting()}catch(t){t instanceof Error&&(r=t)}if(await e.runCallbacks("handlerDidComplete",{event:n,request:s,response:i,error:r}),e.destroy(),r)throw r}}{constructor(t={}){t.cacheName=f(t.cacheName),super(t),this._=!1!==t.fallbackToNetwork,this.plugins.push(C.copyRedirectedCacheableResponsesPlugin)}async L(t,e){const s=await e.cacheMatch(t);return s||(e.event&&"install"===e.event.type?await this.C(t,e):await this.O(t,e))}async O(t,e){let n;const i=e.params||{};if(!this._)throw new s("missing-precache-entry",{cacheName:this.cacheName,url:t.url});{const s=i.integrity,r=t.integrity,o=!r||r===s;n=await e.fetch(new Request(t,{integrity:r||s})),s&&o&&(this.N(),await e.cachePut(t,n.clone()))}return n}async C(t,e){this.N();const n=await e.fetch(t);if(!await e.cachePut(t,n.clone()))throw new s("bad-precaching-response",{url:t.url,status:n.status});return n}N(){let t=null,e=0;for(const[s,n]of this.plugins.entries())n!==C.copyRedirectedCacheableResponsesPlugin&&(n===C.defaultPrecacheCacheabilityPlugin&&(t=s),n.cacheWillUpdate&&e++);0===e?this.plugins.push(C.defaultPrecacheCacheabilityPlugin):e>1&&null!==t&&this.plugins.splice(t,1)}}C.defaultPrecacheCacheabilityPlugin={cacheWillUpdate:async({response:t})=>!t||t.status>=400?null:t},C.copyRedirectedCacheableResponsesPlugin={cacheWillUpdate:async({response:t})=>t.redirected?await m(t):t};class E{constructor({cacheName:t,plugins:e=[],fallbackToNetwork:s=!0}={}){this.k=new Map,this.K=new Map,this.P=new Map,this.l=new C({cacheName:f(t),plugins:[...e,new g({precacheController:this})],fallbackToNetwork:s}),this.install=this.install.bind(this),this.activate=this.activate.bind(this)}get strategy(){return this.l}precache(t){this.addToCacheList(t),this.T||(self.addEventListener("install",this.install),self.addEventListener("activate",this.activate),this.T=!0)}addToCacheList(t){const e=[];for(const n of t){"string"==typeof n?e.push(n):n&&void 0===n.revision&&e.push(n.url);const{cacheKey:t,url:i}=p(n),r="string"!=typeof n&&n.revision?"reload":"default";if(this.k.has(i)&&this.k.get(i)!==t)throw new s("add-to-cache-list-conflicting-entries",{firstEntry:this.k.get(i),secondEntry:t});if("string"!=typeof n&&n.integrity){if(this.P.has(t)&&this.P.get(t)!==n.integrity)throw new s("add-to-cache-list-conflicting-integrities",{url:i});this.P.set(t,n.integrity)}if(this.k.set(i,t),this.K.set(i,r),e.length>0){const t=`Workbox is precaching URLs without revision info: ${e.join(", ")}\nThis is generally NOT safe. Learn more at https://bit.ly/wb-precache`;console.warn(t)}}}install(t){return d(t,(async()=>{const e=new y;this.strategy.plugins.push(e);for(const[e,s]of this.k){const n=this.P.get(s),i=this.K.get(e),r=new Request(e,{integrity:n,cache:i,credentials:"same-origin"});await Promise.all(this.strategy.handleAll({params:{cacheKey:s},request:r,event:t}))}const{updatedURLs:s,notUpdatedURLs:n}=e;return{updatedURLs:s,notUpdatedURLs:n}}))}activate(t){return d(t,(async()=>{const t=await self.caches.open(this.strategy.cacheName),e=await t.keys(),s=new Set(this.k.values()),n=[];for(const i of e)s.has(i.url)||(await t.delete(i),n.push(i.url));return{deletedURLs:n}}))}getURLsToCacheKeys(){return this.k}getCachedURLs(){return[...this.k.keys()]}getCacheKeyForURL(t){const e=new URL(t,location.href);return this.k.get(e.href)}getIntegrityForCacheKey(t){return this.P.get(t)}async matchPrecache(t){const e=t instanceof Request?t.url:t,s=this.getCacheKeyForURL(e);if(s){return(await self.caches.open(this.strategy.cacheName)).match(s)}}createHandlerBoundToURL(t){const e=this.getCacheKeyForURL(t);if(!e)throw new s("non-precached-url",{url:t});return s=>(s.request=new Request(t),s.params=Object.assign({cacheKey:e},s.params),this.strategy.handle(s))}}let O;const x=()=>(O||(O=new E),O);class N extends i{constructor(t,e){super((({request:s})=>{const n=t.getURLsToCacheKeys();for(const i of function*(t,{ignoreURLParametersMatching:e=[/^utm_/,/^fbclid$/],directoryIndex:s="index.html",cleanURLs:n=!0,urlManipulation:i}={}){const r=new URL(t,location.href);r.hash="",yield r.href;const o=function(t,e=[]){for(const s of[...t.searchParams.keys()])e.some((t=>t.test(s)))&&t.searchParams.delete(s);return t}(r,e);if(yield o.href,s&&o.pathname.endsWith("/")){const t=new URL(o.href);t.pathname+=s,yield t.href}if(n){const t=new URL(o.href);t.pathname+=".html",yield t.href}if(i){const t=i({url:r});for(const e of t)yield e.href}}(s.url,e)){const e=n.get(i);if(e){return{cacheKey:e,integrity:t.getIntegrityForCacheKey(e)}}}}),t.strategy)}}t.NavigationRoute=class extends i{constructor(t,{allowlist:e=[/./],denylist:s=[]}={}){super((t=>this.W(t)),t),this.j=e,this.M=s}W({url:t,request:e}){if(e&&"navigate"!==e.mode)return!1;const s=t.pathname+t.search;for(const t of this.M)if(t.test(s))return!1;return!!this.j.some((t=>t.test(s)))}},t.cleanupOutdatedCaches=function(){self.addEventListener("activate",(t=>{const e=f();t.waitUntil((async(t,e="-precache-")=>{const s=(await self.caches.keys()).filter((s=>s.includes(e)&&s.includes(self.registration.scope)&&s!==t));return await Promise.all(s.map((t=>self.caches.delete(t)))),s})(e).then((t=>{})))}))},t.createHandlerBoundToURL=function(t){return x().createHandlerBoundToURL(t)},t.precacheAndRoute=function(t,e){!function(t){x().precache(t)}(t),function(t){const e=x();h(new N(e,t))}(e)},t.registerRoute=h}));