修改粒子命名规则

This commit is contained in:
tianmo committed 2026-10-14 18:35:26 +08:00
1 parent 1ecbb6fc48
commit aabf4ff693
10 files changed
+235 -97

No files matched your search

@@ -1,2 +1,2 @@
var ft=Object.defineProperty;var gt=(W,t,e)=>t in W?ft(W,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):W[t]=e;var T=(W,t,e)=>gt(W,typeof t!="symbol"?t+"":t,e);import{f as ht,R as pt,N as dt,ac as ut,Z as mt,b4 as yt,O as rt,b5 as at,U as D,B as Tt}from"./index-DcKlG1-Y.js";import{$ as Rt,a0 as Yt,a1 as Ft,a2 as Et,y as _t,a3 as Ot,a4 as kt,a5 as Xt,a6 as Bt,a7 as Nt,a8 as Dt,a9 as $t,aa as zt,ab as Wt,ad as qt,H as Gt,ae as Jt,af as Ht,ag as Zt,ah as Kt,ai as Qt,aj as jt,ak as te,al as ee,am as se,an as ne,ao as ie,ap as oe,aq as re,ar as ae,as as le,at as ce,au as he,av as pe,aw as de,ax as ue,ay as fe,az as ge,aA as me,aB as ye,aC as Te,aD as be,aE as we,aF as xe,aG as Ae,aH as Pe,aI as Ie,aJ as Ce,aK as Ve,aL as Le,aM as Se,aN as Me,aO as ve,aP as Ue,aQ as Re,aR as Ye,aS as Fe,aT as Ee,x as _e,aU as Oe,aV as ke,aW as Xe,aX as Be,aY as Ne,aZ as De,a_ as $e,a$ as ze,b0 as We,b1 as qe,b2 as Ge,b3 as Je,b6 as He,b7 as Ze,b8 as Ke,b9 as Qe,ba as je,bb as ts,bc as es,bd as ss,be as ns,bf as is,bg as os,bh as rs,bi as as,bj as ls,bk as cs,bl as hs,bm as ps,bn as ds,bo as us,bp as fs,bq as gs,br as ms,bs as ys,bt as Ts,bu as bs,w as ws,X as xs,J as As,Y as Ps,z as Is,bv as Cs,bw as Vs,bx as Ls,by as Ss,bz as Ms,bA as vs,bB as Us,bC as Rs,bD as Ys,bE as Fs,bF as Es,bG as _s,T as Os,bH as ks,bI as Xs,b as Bs,bJ as Ns,c as Ds,bK as $s,bL as zs,bM as Ws,bN as qs,bO as Gs,bP as Js,bQ as Hs,bR as Zs,bS as Ks,bT as Qs,bU as js,bV as tn,bW as en,bX as sn,bY as nn,bZ as on,b_ as rn,V as an,b$ as ln,c0 as cn,c1 as hn,c2 as pn,c3 as dn}from"./index-DcKlG1-Y.js";class It{constructor(t){T(this,"skeletonData");T(this,"animationToMixTime",{});T(this,"defaultMix",0);if(!t)throw new Error("skeletonData cannot be null.");this.skeletonData=t}setMix(t,e,n){return typeof t=="string"?this.setMix1(t,e,n):this.setMix2(t,e,n)}setMix1(t,e,n){const s=this.skeletonData.findAnimation(t);if(!s)throw new Error(`Animation not found: ${t}`);const i=this.skeletonData.findAnimation(e);if(!i)throw new Error(`Animation not found: ${e}`);this.setMix2(s,i,n)}setMix2(t,e,n){if(!t)throw new Error("from cannot be null.");if(!e)throw new Error("to cannot be null.");const s=`${t.name}.${e.name}`;this.animationToMixTime[s]=n}getMix(t,e){const n=`${t.name}.${e.name}`,s=this.animationToMixTime[n];return s===void 0?this.defaultMix:s}}class Ct{constructor(t,e="",n=new bt,s=new lt){T(this,"textureLoader");T(this,"pathPrefix");T(this,"downloader");T(this,"cache");T(this,"errors",{});T(this,"toLoad",0);T(this,"loaded",0);T(this,"texturePmaInfo",{});this.textureLoader=t,this.pathPrefix=e,this.downloader=n,this.cache=s}start(t){return this.toLoad++,this.pathPrefix+t}success(t,e,n){this.toLoad--,this.loaded++,this.cache.assets[e]=n,this.cache.assetsRefCount[e]=(this.cache.assetsRefCount[e]||0)+1,t&&t(e,n)}error(t,e,n){this.toLoad--,this.loaded++,this.errors[e]=n,t&&t(e,n)}loadAll(){return new Promise((e,n)=>{const s=()=>{if(this.isLoadingComplete()){this.hasErrors()?n(this.errors):e(this);return}requestAnimationFrame(s)};requestAnimationFrame(s)})}setRawDataURI(t,e){this.downloader.rawDataUris[this.pathPrefix+t]=e}loadBinary(t,e=()=>{},n=()=>{}){t=this.start(t),!this.reuseAssets(t,e,n)&&(this.cache.assetsLoaded[t]=new Promise((s,i)=>{this.downloader.downloadBinary(t,o=>{this.success(e,t,o),s(o)},(o,r)=>{const l=`Couldn't load binary ${t}: status ${o}, ${r}`;this.error(n,t,l),i(l)})}))}loadText(t,e=()=>{},n=()=>{}){t=this.start(t),this.downloader.downloadText(t,s=>{this.success(e,t,s)},(s,i)=>{this.error(n,t,`Couldn't load text ${t}: status ${s}, ${i}`)})}loadJson(t,e=()=>{},n=()=>{}){t=this.start(t),!this.reuseAssets(t,e,n)&&(this.cache.assetsLoaded[t]=new Promise((s,i)=>{this.downloader.downloadJson(t,o=>{this.success(e,t,o),s(o)},(o,r)=>{const l=`Couldn't load JSON ${t}: status ${o}, ${r}`;this.error(n,t,l),i(l)})}))}reuseAssets(t,e=()=>{},n=()=>{}){const s=this.cache.getAsset(t),i=s!==void 0;return i&&(this.cache.assetsLoaded[t]=s.then(o=>(o=o instanceof Image||o instanceof ImageBitmap?this.textureLoader(o):o,this.success(e,t,o),o)).catch(o=>{this.error(n,t,o)})),i}loadTexture(t,e=()=>{},n=()=>{}){if(t=this.start(t),this.reuseAssets(t,e,n))return;const s=this.texturePmaInfo[t];this.cache.assetsLoaded[t]=new Promise((i,o)=>{if(!!!(typeof window<"u"&&typeof navigator<"u"&&window.document))fetch(t,{mode:"cors"}).then(c=>{if(c.ok)return c.blob();const a=`Couldn't load image: ${t}`;this.error(n,t,`Couldn't load image: ${t}`),o(a)}).then(c=>c?createImageBitmap(c,{premultiplyAlpha:"none",colorSpaceConversion:"none"}):null).then(c=>{if(c){const a=this.createTexture(t,s,c);this.success(e,t,a),i(a)}});else{const c=new Image;c.crossOrigin="anonymous",c.onload=()=>{const a=this.createTexture(t,s,c);this.success(e,t,a),i(a)},c.onerror=()=>{const a=`Couldn't load image: ${t}`;this.error(n,t,a),o(a)},this.downloader.rawDataUris[t]&&(t=this.downloader.rawDataUris[t]),c.src=t}})}loadTextureAtlas(t,e=()=>{},n=()=>{},s){const i=t.lastIndexOf("/"),o=i>=0?t.substring(0,i+1)Line truncated
var ft=Object.defineProperty;var gt=(W,t,e)=>t in W?ft(W,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):W[t]=e;var T=(W,t,e)=>gt(W,typeof t!="symbol"?t+"":t,e);import{f as ht,R as pt,N as dt,ac as ut,Z as mt,b4 as yt,O as rt,b5 as at,U as D,B as Tt}from"./index-CBAQrWSZ.js";import{$ as Rt,a0 as Yt,a1 as Ft,a2 as Et,y as _t,a3 as Ot,a4 as kt,a5 as Xt,a6 as Bt,a7 as Nt,a8 as Dt,a9 as $t,aa as zt,ab as Wt,ad as qt,H as Gt,ae as Jt,af as Ht,ag as Zt,ah as Kt,ai as Qt,aj as jt,ak as te,al as ee,am as se,an as ne,ao as ie,ap as oe,aq as re,ar as ae,as as le,at as ce,au as he,av as pe,aw as de,ax as ue,ay as fe,az as ge,aA as me,aB as ye,aC as Te,aD as be,aE as we,aF as xe,aG as Ae,aH as Pe,aI as Ie,aJ as Ce,aK as Ve,aL as Le,aM as Se,aN as Me,aO as ve,aP as Ue,aQ as Re,aR as Ye,aS as Fe,aT as Ee,x as _e,aU as Oe,aV as ke,aW as Xe,aX as Be,aY as Ne,aZ as De,a_ as $e,a$ as ze,b0 as We,b1 as qe,b2 as Ge,b3 as Je,b6 as He,b7 as Ze,b8 as Ke,b9 as Qe,ba as je,bb as ts,bc as es,bd as ss,be as ns,bf as is,bg as os,bh as rs,bi as as,bj as ls,bk as cs,bl as hs,bm as ps,bn as ds,bo as us,bp as fs,bq as gs,br as ms,bs as ys,bt as Ts,bu as bs,w as ws,X as xs,J as As,Y as Ps,z as Is,bv as Cs,bw as Vs,bx as Ls,by as Ss,bz as Ms,bA as vs,bB as Us,bC as Rs,bD as Ys,bE as Fs,bF as Es,bG as _s,T as Os,bH as ks,bI as Xs,b as Bs,bJ as Ns,c as Ds,bK as $s,bL as zs,bM as Ws,bN as qs,bO as Gs,bP as Js,bQ as Hs,bR as Zs,bS as Ks,bT as Qs,bU as js,bV as tn,bW as en,bX as sn,bY as nn,bZ as on,b_ as rn,V as an,b$ as ln,c0 as cn,c1 as hn,c2 as pn,c3 as dn}from"./index-CBAQrWSZ.js";class It{constructor(t){T(this,"skeletonData");T(this,"animationToMixTime",{});T(this,"defaultMix",0);if(!t)throw new Error("skeletonData cannot be null.");this.skeletonData=t}setMix(t,e,n){return typeof t=="string"?this.setMix1(t,e,n):this.setMix2(t,e,n)}setMix1(t,e,n){const s=this.skeletonData.findAnimation(t);if(!s)throw new Error(`Animation not found: ${t}`);const i=this.skeletonData.findAnimation(e);if(!i)throw new Error(`Animation not found: ${e}`);this.setMix2(s,i,n)}setMix2(t,e,n){if(!t)throw new Error("from cannot be null.");if(!e)throw new Error("to cannot be null.");const s=`${t.name}.${e.name}`;this.animationToMixTime[s]=n}getMix(t,e){const n=`${t.name}.${e.name}`,s=this.animationToMixTime[n];return s===void 0?this.defaultMix:s}}class Ct{constructor(t,e="",n=new bt,s=new lt){T(this,"textureLoader");T(this,"pathPrefix");T(this,"downloader");T(this,"cache");T(this,"errors",{});T(this,"toLoad",0);T(this,"loaded",0);T(this,"texturePmaInfo",{});this.textureLoader=t,this.pathPrefix=e,this.downloader=n,this.cache=s}start(t){return this.toLoad++,this.pathPrefix+t}success(t,e,n){this.toLoad--,this.loaded++,this.cache.assets[e]=n,this.cache.assetsRefCount[e]=(this.cache.assetsRefCount[e]||0)+1,t&&t(e,n)}error(t,e,n){this.toLoad--,this.loaded++,this.errors[e]=n,t&&t(e,n)}loadAll(){return new Promise((e,n)=>{const s=()=>{if(this.isLoadingComplete()){this.hasErrors()?n(this.errors):e(this);return}requestAnimationFrame(s)};requestAnimationFrame(s)})}setRawDataURI(t,e){this.downloader.rawDataUris[this.pathPrefix+t]=e}loadBinary(t,e=()=>{},n=()=>{}){t=this.start(t),!this.reuseAssets(t,e,n)&&(this.cache.assetsLoaded[t]=new Promise((s,i)=>{this.downloader.downloadBinary(t,o=>{this.success(e,t,o),s(o)},(o,r)=>{const l=`Couldn't load binary ${t}: status ${o}, ${r}`;this.error(n,t,l),i(l)})}))}loadText(t,e=()=>{},n=()=>{}){t=this.start(t),this.downloader.downloadText(t,s=>{this.success(e,t,s)},(s,i)=>{this.error(n,t,`Couldn't load text ${t}: status ${s}, ${i}`)})}loadJson(t,e=()=>{},n=()=>{}){t=this.start(t),!this.reuseAssets(t,e,n)&&(this.cache.assetsLoaded[t]=new Promise((s,i)=>{this.downloader.downloadJson(t,o=>{this.success(e,t,o),s(o)},(o,r)=>{const l=`Couldn't load JSON ${t}: status ${o}, ${r}`;this.error(n,t,l),i(l)})}))}reuseAssets(t,e=()=>{},n=()=>{}){const s=this.cache.getAsset(t),i=s!==void 0;return i&&(this.cache.assetsLoaded[t]=s.then(o=>(o=o instanceof Image||o instanceof ImageBitmap?this.textureLoader(o):o,this.success(e,t,o),o)).catch(o=>{this.error(n,t,o)})),i}loadTexture(t,e=()=>{},n=()=>{}){if(t=this.start(t),this.reuseAssets(t,e,n))return;const s=this.texturePmaInfo[t];this.cache.assetsLoaded[t]=new Promise((i,o)=>{if(!!!(typeof window<"u"&&typeof navigator<"u"&&window.document))fetch(t,{mode:"cors"}).then(c=>{if(c.ok)return c.blob();const a=`Couldn't load image: ${t}`;this.error(n,t,`Couldn't load image: ${t}`),o(a)}).then(c=>c?createImageBitmap(c,{premultiplyAlpha:"none",colorSpaceConversion:"none"}):null).then(c=>{if(c){const a=this.createTexture(t,s,c);this.success(e,t,a),i(a)}});else{const c=new Image;c.crossOrigin="anonymous",c.onload=()=>{const a=this.createTexture(t,s,c);this.success(e,t,a),i(a)},c.onerror=()=>{const a=`Couldn't load image: ${t}`;this.error(n,t,a),o(a)},this.downloader.rawDataUris[t]&&(t=this.downloader.rawDataUris[t]),c.src=t}})}loadTextureAtlas(t,e=()=>{},n=()=>{},s){const i=t.lastIndexOf("/"),o=i>=0?t.substring(0,i+1)Line truncated
${n}`:""}`)}remove(t){t=this.pathPrefix+t;const e=this.cache.assets[t];return e.dispose&&e.dispose(),delete this.cache.assets[t],delete this.cache.assetsRefCount[t],delete this.cache.assetsLoaded[t],e}removeAll(){for(const t in this.cache.assets){const e=this.cache.assets[t];e.dispose&&e.dispose()}this.cache.assets={},this.cache.assetsLoaded={},this.cache.assetsRefCount={}}isLoadingComplete(){return this.toLoad===0}getToLoad(){return this.toLoad}getLoaded(){return this.loaded}dispose(){this.removeAll()}disposeAsset(t){const e=this.cache.assets[t];if(e instanceof ht){e.dispose();return}this.disposeAssetInternal(t)}hasErrors(){return Object.keys(this.errors).length>0}getErrors(){return this.errors}disposeAssetInternal(t){if(this.cache.assetsRefCount[t]>0&&--this.cache.assetsRefCount[t]===0)return this.remove(t)}createTextureAtlas(t,e,n,s){const i=new ht(t);i.dispose=()=>{var o;if(!(this.cache.assetsRefCount[n]<=0)){this.disposeAssetInternal(n);for(const r of i.pages)(o=r.texture)==null||o.dispose()}};for(const o of i.pages){const r=this.texturePath(e,o.name,s);this.texturePmaInfo[this.pathPrefix+r]=o.pma}return i}createTexture(t,e,n){const s=this.textureLoader(n,e),i=s.dispose.bind(s);return s.dispose=()=>{this.disposeAssetInternal(t)&&i()},s}texturePath(t,e,n){return n?n[e]:t+e}}const nt=class nt{constructor(){T(this,"assets",{});T(this,"assetsRefCount",{});T(this,"assetsLoaded",{})}static getCache(t){const e=nt.AVAILABLE_CACHES.get(t);if(e)return e;const n=new nt;return nt.AVAILABLE_CACHES.set(t,n),n}async addAsset(t,e){return this.assetsLoaded[t]=Promise.resolve(e),this.assets[t]=e,e}getAsset(t){return this.assetsLoaded[t]}};T(nt,"AVAILABLE_CACHES",new Map);let lt=nt;class bt{constructor(){T(this,"callbacks",{});T(this,"rawDataUris",{})}dataUriToString(t){if(!t.startsWith("data:"))throw new Error("Not a data URI.");let e=t.indexOf("base64,");return e!==-1?(e+=7,atob(t.substr(e))):t.substr(t.indexOf(",")+1)}base64ToUint8Array(t){var e=window.atob(t),n=e.length,s=new Uint8Array(n);for(let i=0;i<n;i++)s[i]=e.charCodeAt(i);return s}dataUriToUint8Array(t){if(!t.startsWith("data:"))throw new Error("Not a data URI.");let e=t.indexOf("base64,");if(e===-1)throw new Error("Not a binary data URI.");return e+=7,this.base64ToUint8Array(t.substr(e))}downloadText(t,e,n){if(this.start(t,e,n))return;const s=this.rawDataUris[t];if(s&&!s.includes(".")){try{this.finish(t,200,this.dataUriToString(s))}catch(r){this.finish(t,400,JSON.stringify(r))}return}const i=new XMLHttpRequest;i.overrideMimeType("text/html"),i.open("GET",s||t,!0);const o=()=>{this.finish(t,i.status,i.responseText)};i.onload=o,i.onerror=o,i.send()}downloadJson(t,e,n){this.downloadText(t,s=>{e(JSON.parse(s))},n)}downloadBinary(t,e,n){if(this.start(t,e,n))return;const s=this.rawDataUris[t];if(s&&!s.includes(".")){try{this.finish(t,200,this.dataUriToUint8Array(s))}catch(r){this.finish(t,400,JSON.stringify(r))}return}const i=new XMLHttpRequest;i.open("GET",s||t,!0),i.responseType="arraybuffer";const o=()=>{this.finish(t,i.status,i.response)};i.onload=()=>{i.status===200||i.status===0?this.finish(t,200,new Uint8Array(i.response)):o()},i.onerror=o,i.send()}start(t,e,n){let s=this.callbacks[t];try{if(s)return!0;this.callbacks[t]=s=[]}finally{s.push(e,n)}}finish(t,e,n){const s=this.callbacks[t];if(delete this.callbacks[t],e===200||e===0)for(let i=0,o=s.length;i<o;i+=2)s[i](n);else for(let i=1,o=s.length;i<o;i+=2)s[i](e,n)}}class Vt{constructor(t,e=!1){T(this,"atlas");T(this,"allowMissingRegions");this.atlas=t,this.allowMissingRegions=e}findRegions(t,e,n){const s=n.regions;for(let i=0,o=s.length;i<o;i++)s[i]=this.findRegion(t,n.getPath(e,i))}findRegion(t,e){const n=this.atlas.findRegion(e);if(!n&&!this.allowMissingRegions)throw new Error(`Region not found in atlas: ${e} (attachment: ${t})`);return n}newRegionAttachment(t,e,n,s,i){return this.findRegions(n,s,i),new pt(n,i)}newMeshAttachment(t,e,n,s,i){return this.findRegions(n,s,i),new dt(n,i)}newBoundingBoxAttachment(t,e,n){return new ut(n)}newPathAttachment(t,e,n){return new mt(n)}newPointAttachment(t,e,n){return new yt(n)}newClippingAttachment(t,e,n){return new rt(n)}}class Lt{constructor(){T(this,"minX",0);T(this,"minY",0);T(this,"maxX",0);T(this,"maxY",0);T(this,"boundingBoxes",[]);T(this,"polygons",[]);T(this,"polygonPool",new at(()=>D.newFloatArray(16)))}update(t,e){if(!t)throw new Error("skeleton cannot be null.");const n=this.boundingBoxes,s=this.polygons,i=this.polygonPool,o=t.slots,r=o.length;n.length=0,i.freeAll(s),s.length=0;for(let l=0;l<r;l++){const c=o[l];if(!c.bone.active)continue;const a=c.appliedPose.attachment;if(a instanceof ut){n.push(a);let h=i.obtain();h.length!==a.worldVerticesLength&&(h=D.newFloatArray(a.worldVerticesLength)),s.push(h),a.computeWorldVertices(t,c,0,a.worldVerticesLength,h,0,2)}}e?this.aabbCompute():(this.minX=Number.POSITIVE_INFINITY,this.minY=Number.POSITIVE_INFINITY,this.maxX=Number.NEGATIVE_INFINITY,this.maxY=Number.NEGATIVE_INFINITY)}aabbCompute(){let t=Number.POSITIVE_INFLine truncated
@@ -1,43 +1,43 @@
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-Dm5YZAxK.js","assets/index-D40Mzcwz.js"])))=>i.map(i=>d[i]);
var bS=Object.defineProperty;var wS=(s,e,t)=>e in s?bS(s,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):s[e]=t;var w=(s,e,t)=>wS(s,typeof e!="symbol"?e+"":e,t);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))i(n);new MutationObserver(n=>{for(const r of n)if(r.type==="childList")for(const o of r.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&i(o)}).observe(document,{childList:!0,subtree:!0});function t(n){const r={};return n.integrity&&(r.integrity=n.integrity),n.referrerPolicy&&(r.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?r.credentials="include":n.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function i(n){if(n.ep)return;n.ep=!0;const r=t(n);fetch(n.href,r)}})();/**
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-DbmHfkuV.js","assets/index-3evwjaUy.js"])))=>i.map(i=>d[i]);
var SS=Object.defineProperty;var TS=(s,e,t)=>e in s?SS(s,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):s[e]=t;var w=(s,e,t)=>TS(s,typeof e!="symbol"?e+"":e,t);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))i(n);new MutationObserver(n=>{for(const r of n)if(r.type==="childList")for(const o of r.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&i(o)}).observe(document,{childList:!0,subtree:!0});function t(n){const r={};return n.integrity&&(r.integrity=n.integrity),n.referrerPolicy&&(r.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?r.credentials="include":n.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function i(n){if(n.ep)return;n.ep=!0;const r=t(n);fetch(n.href,r)}})();/**
* @vue/shared v3.5.41
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/function km(s){const e=Object.create(null);for(const t of s.split(","))e[t]=1;return t=>t in e}const Pt={},Lo=[],sn=()=>{},rx=()=>!1,Rh=s=>s.charCodeAt(0)===111&&s.charCodeAt(1)===110&&(s.charCodeAt(2)>122||s.charCodeAt(2)<97),Ph=s=>s.startsWith("onUpdate:"),fi=Object.assign,Fm=(s,e)=>{const t=s.indexOf(e);t>-1&&s.splice(t,1)},SS=Object.prototype.hasOwnProperty,Ct=(s,e)=>SS.call(s,e),We=Array.isArray,Do=s=>ml(s)==="[object Map]",ra=s=>ml(s)==="[object Set]",Cp=s=>ml(s)==="[object Date]",tt=s=>typeof s=="function",jt=s=>typeof s=="string",ns=s=>typeof s=="symbol",At=s=>s!==null&&typeof s=="object",ox=s=>(At(s)||tt(s))&&tt(s.then)&&tt(s.catch),ax=Object.prototype.toString,ml=s=>ax.call(s),TS=s=>ml(s).slice(8,-1),lx=s=>ml(s)==="[object Object]",kh=s=>jt(s)&&s!=="NaN"&&s[0]!=="-"&&""+parseInt(s,10)===s,Da=km(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Fh=s=>{const e=Object.create(null);return(t=>e[t]||(e[t]=s(t)))},MS=/-\w/g,Cs=Fh(s=>s.replace(MS,e=>e.slice(1).toUpperCase())),_S=/\B([A-Z])/g,vr=Fh(s=>s.replace(_S,"-$1").toLowerCase()),cx=Fh(s=>s.charAt(0).toUpperCase()+s.slice(1)),fu=Fh(s=>s?`on${cx(s)}`:""),Ks=(s,e)=>!Object.is(s,e),pc=(s,...e)=>{for(let t=0;t<s.length;t++)s[t](...e)},hx=(s,e,t,i=!1)=>{Object.defineProperty(s,e,{configurable:!0,enumerable:!1,writable:i,value:t})},Oh=s=>{const e=parseFloat(s);return isNaN(e)?s:e},CS=s=>{const e=jt(s)?Number(s):NaN;return isNaN(e)?s:e};let Ap;const Bh=()=>Ap||(Ap=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function pi(s){if(We(s)){const e={};for(let t=0;t<s.length;t++){const i=s[t],n=jt(i)?RS(i):pi(i);if(n)for(const r in n)e[r]=n[r]}return e}else if(jt(s)||At(s))return s}const AS=/;(?![^(]*\))/g,ES=/:([^]+)/,IS=/\/\*[^]*?\*\//g;function RS(s){const e={};return s.replace(IS,"").split(AS).forEach(t=>{if(t){const i=t.split(ES);i.length>1&&(e[i[0].trim()]=i[1].trim())}}),e}function De(s){let e="";if(jt(s))e=s;else if(We(s))for(let t=0;t<s.length;t++){const i=De(s[t]);i&&(e+=i+" ")}else if(At(s))for(const t in s)s[t]&&(e+=t+" ");return e.trim()}const PS="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",kS=km(PS);function ux(s){return!!s||s===""}function FS(s,e){if(s.length!==e.length)return!1;let t=!0;for(let i=0;t&&i<s.length;i++)t=oa(s[i],e[i]);return t}function oa(s,e){if(s===e)return!0;let t=Cp(s),i=Cp(e);if(t||i)return t&&i?s.getTime()===e.getTime():!1;if(t=ns(s),i=ns(e),t||i)return s===e;if(t=We(s),i=We(e),t||i)return t&&i?FS(s,e):!1;if(t=At(s),i=At(e),t||i){if(!t||!i)return!1;const n=Object.keys(s).length,r=Object.keys(e).length;if(n!==r)return!1;for(const o in s){const a=s.hasOwnProperty(o),c=e.hasOwnProperty(o);if(a&&!c||!a&&c||!oa(s[o],e[o]))return!1}}return String(s)===String(e)}function Om(s,e){return s.findIndex(t=>oa(t,e))}const dx=s=>!!(s&&s.__v_isRef===!0),Me=s=>jt(s)?s:s==null?"":We(s)||At(s)&&(s.toString===ax||!tt(s.toString))?dx(s)?Me(s.value):JSON.stringify(s,fx,2):String(s),fx=(s,e)=>dx(e)?fx(s,e.value):Do(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((t,[i,n],r)=>(t[mu(i,r)+" =>"]=n,t),{})}:ra(e)?{[`Set(${e.size})`]:[...e.values()].map(t=>mu(t))}:ns(e)?mu(e):At(e)&&!We(e)&&!lx(e)?String(e):e,mu=(s,e="")=>{var t;return ns(s)?`Symbol(${(t=s.description)!=null?t:e})`:s};/**
**/function km(s){const e=Object.create(null);for(const t of s.split(","))e[t]=1;return t=>t in e}const Ft={},No=[],on=()=>{},ax=()=>!1,Rh=s=>s.charCodeAt(0)===111&&s.charCodeAt(1)===110&&(s.charCodeAt(2)>122||s.charCodeAt(2)<97),Ph=s=>s.startsWith("onUpdate:"),fi=Object.assign,Fm=(s,e)=>{const t=s.indexOf(e);t>-1&&s.splice(t,1)},MS=Object.prototype.hasOwnProperty,Et=(s,e)=>MS.call(s,e),je=Array.isArray,Uo=s=>pl(s)==="[object Map]",aa=s=>pl(s)==="[object Set]",Cp=s=>pl(s)==="[object Date]",st=s=>typeof s=="function",Wt=s=>typeof s=="string",ss=s=>typeof s=="symbol",It=s=>s!==null&&typeof s=="object",lx=s=>(It(s)||st(s))&&st(s.then)&&st(s.catch),cx=Object.prototype.toString,pl=s=>cx.call(s),_S=s=>pl(s).slice(8,-1),hx=s=>pl(s)==="[object Object]",kh=s=>Wt(s)&&s!=="NaN"&&s[0]!=="-"&&""+parseInt(s,10)===s,Na=km(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Fh=s=>{const e=Object.create(null);return(t=>e[t]||(e[t]=s(t)))},CS=/-\w/g,As=Fh(s=>s.replace(CS,e=>e.slice(1).toUpperCase())),AS=/\B([A-Z])/g,wr=Fh(s=>s.replace(AS,"-$1").toLowerCase()),ux=Fh(s=>s.charAt(0).toUpperCase()+s.slice(1)),fu=Fh(s=>s?`on${ux(s)}`:""),Qs=(s,e)=>!Object.is(s,e),pc=(s,...e)=>{for(let t=0;t<s.length;t++)s[t](...e)},dx=(s,e,t,i=!1)=>{Object.defineProperty(s,e,{configurable:!0,enumerable:!1,writable:i,value:t})},Oh=s=>{const e=parseFloat(s);return isNaN(e)?s:e},ES=s=>{const e=Wt(s)?Number(s):NaN;return isNaN(e)?s:e};let Ap;const Bh=()=>Ap||(Ap=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function gi(s){if(je(s)){const e={};for(let t=0;t<s.length;t++){const i=s[t],n=Wt(i)?kS(i):gi(i);if(n)for(const r in n)e[r]=n[r]}return e}else if(Wt(s)||It(s))return s}const IS=/;(?![^(]*\))/g,RS=/:([^]+)/,PS=/\/\*[^]*?\*\//g;function kS(s){const e={};return s.replace(PS,"").split(IS).forEach(t=>{if(t){const i=t.split(RS);i.length>1&&(e[i[0].trim()]=i[1].trim())}}),e}function Be(s){let e="";if(Wt(s))e=s;else if(je(s))for(let t=0;t<s.length;t++){const i=Be(s[t]);i&&(e+=i+" ")}else if(It(s))for(const t in s)s[t]&&(e+=t+" ");return e.trim()}const FS="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",OS=km(FS);function fx(s){return!!s||s===""}function BS(s,e){if(s.length!==e.length)return!1;let t=!0;for(let i=0;t&&i<s.length;i++)t=la(s[i],e[i]);return t}function la(s,e){if(s===e)return!0;let t=Cp(s),i=Cp(e);if(t||i)return t&&i?s.getTime()===e.getTime():!1;if(t=ss(s),i=ss(e),t||i)return s===e;if(t=je(s),i=je(e),t||i)return t&&i?BS(s,e):!1;if(t=It(s),i=It(e),t||i){if(!t||!i)return!1;const n=Object.keys(s).length,r=Object.keys(e).length;if(n!==r)return!1;for(const o in s){const a=s.hasOwnProperty(o),c=e.hasOwnProperty(o);if(a&&!c||!a&&c||!la(s[o],e[o]))return!1}}return String(s)===String(e)}function Om(s,e){return s.findIndex(t=>la(t,e))}const mx=s=>!!(s&&s.__v_isRef===!0),Me=s=>Wt(s)?s:s==null?"":je(s)||It(s)&&(s.toString===cx||!st(s.toString))?mx(s)?Me(s.value):JSON.stringify(s,px,2):String(s),px=(s,e)=>mx(e)?px(s,e.value):Uo(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((t,[i,n],r)=>(t[mu(i,r)+" =>"]=n,t),{})}:aa(e)?{[`Set(${e.size})`]:[...e.values()].map(t=>mu(t))}:ss(e)?mu(e):It(e)&&!je(e)&&!hx(e)?String(e):e,mu=(s,e="")=>{var t;return ss(s)?`Symbol(${(t=s.description)!=null?t:e})`:s};/**
* @vue/reactivity v3.5.41
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/let hi;class mx{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&hi&&(hi.active?(this.parent=hi,this.index=(hi.scopes||(hi.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){const i=this.scopes.slice();for(e=0,t=i.length;e<t;e++)i[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){const n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}const i=this.effects.slice();for(e=0,t=i.length;e<t;e++)i[e].resume()}}run(e){if(this._active){const t=hi;try{return hi=this,e()}finally{hi=t}}}on(){++this._on===1&&(this.prevScope=hi,hi=this)}off(){if(this._on>0&&--this._on===0){if(hi===this)hi=this.prevScope;else{let e=hi;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,i;for(t=0,i=this.effects.length;t<i;t++)this.effects[t].stop();for(this.effects.length=0,t=0,i=this.cleanups.length;t<i;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){const n=this.scopes.slice();for(t=0,i=n.length;t<i;t++)n[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){const n=this.parent.scopes.pop();n&&n!==this&&(this.parent.scopes[this.index]=n,n.index=this.index)}this.parent=void 0}}}function px(s){return new mx(s)}function gx(){return hi}function OS(s,e=!1){hi&&hi.cleanups.push(s)}let Bt;const pu=new WeakSet;class vx{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,hi&&(hi.active?hi.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,pu.has(this)&&(pu.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||yx(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Ep(this),bx(this);const e=Bt,t=As;Bt=this,As=!0;try{return this.fn()}finally{wx(this),Bt=e,As=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Dm(e);this.deps=this.depsTail=void 0,Ep(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?pu.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){af(this)&&this.run()}get dirty(){return af(this)}}let xx=0,Na,Ua;function yx(s,e=!1){if(s.flags|=8,e){s.next=Ua,Ua=s;return}s.next=Na,Na=s}function Bm(){xx++}function Lm(){if(--xx>0)return;if(Ua){let e=Ua;for(Ua=void 0;e;){const t=e.next;e.next=void 0,e.flags&=-9,e=t}}let s;for(;Na;){let e=Na;for(Na=void 0;e;){const t=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(i){s||(s=i)}e=t}}if(s)throw s}function bx(s){for(let e=s.deps;e;e=e.nextDep)e.version=-1,e.prevActiveLink=e.dep.activeLink,e.dep.activeLink=e}function wx(s){let e,t=s.depsTail,i=t;for(;i;){const n=i.prevDep;i.version===-1?(i===t&&(t=n),Dm(i),BS(i)):e=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=n}s.deps=e,s.depsTail=t}function af(s){for(let e=s.deps;e;e=e.nextDep)if(e.dep.version!==e.version||e.dep.computed&&(Sx(e.dep.computed)||e.dep.version!==e.version))return!0;return!!s._dirty}function Sx(s){if(s.flags&4&&!(s.flags&16)||(s.flags&=-17,s.globalVersion===Za)||(s.globalVersion=Za,!s.isSSR&&s.flags&128&&(!s.deps&&!s._dirty||!af(s))))return;s.flags|=2;const e=s.dep,t=Bt,i=As;Bt=s,As=!0;try{bx(s);const n=s.fn(s._value);(e.version===0||Ks(n,s._value))&&(s.flags|=128,s._value=n,e.version++)}catch(n){throw e.version++,n}finally{Bt=t,As=i,wx(s),s.flags&=-3}}function Dm(s,e=!1){const{dep:t,prevSub:i,nextSub:n}=s;if(i&&(i.nextSub=n,s.prevSub=void 0),n&&(n.prevSub=i,s.nextSub=void 0),t.subs===s&&(t.subs=i,!i&&t.computed)){t.computed.flags&=-5;for(let r=t.computed.deps;r;r=r.nextDep)Dm(r,!0)}!e&&!--t.sc&&t.map&&t.map.delete(t.key)}function BS(s){const{prevDep:e,nextDep:t}=s;e&&(e.nextDep=t,s.prevDep=void 0),t&&(t.prevDep=e,s.nextDep=void 0)}let As=!0;const Tx=[];function On(){Tx.push(As),As=!1}function Bn(){const s=Tx.pop();As=s===void 0?!0:s}function Ep(s){const{cleanup:e}=s;if(s.cleanup=void 0,e){const t=Bt;Bt=void 0;try{e()}finally{Bt=t}}}let Za=0;class LS{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Nm{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!Bt||!As||Bt===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==Bt)t=this.activeLink=new LS(Bt,this),Bt.deps?(t.prevDep=Bt.depsTail,Bt.depsTail.nextDep=t,Bt.depsTail=t):Bt.deps=Bt.depsTail=t,Mx(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){const i=t.nextDep;i.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=i),t.prevDep=Bt.depsTailLine truncated
**/let hi;class gx{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&hi&&(hi.active?(this.parent=hi,this.index=(hi.scopes||(hi.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){const i=this.scopes.slice();for(e=0,t=i.length;e<t;e++)i[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){const n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}const i=this.effects.slice();for(e=0,t=i.length;e<t;e++)i[e].resume()}}run(e){if(this._active){const t=hi;try{return hi=this,e()}finally{hi=t}}}on(){++this._on===1&&(this.prevScope=hi,hi=this)}off(){if(this._on>0&&--this._on===0){if(hi===this)hi=this.prevScope;else{let e=hi;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,i;for(t=0,i=this.effects.length;t<i;t++)this.effects[t].stop();for(this.effects.length=0,t=0,i=this.cleanups.length;t<i;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){const n=this.scopes.slice();for(t=0,i=n.length;t<i;t++)n[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){const n=this.parent.scopes.pop();n&&n!==this&&(this.parent.scopes[this.index]=n,n.index=this.index)}this.parent=void 0}}}function vx(s){return new gx(s)}function xx(){return hi}function LS(s,e=!1){hi&&hi.cleanups.push(s)}let Dt;const pu=new WeakSet;class yx{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,hi&&(hi.active?hi.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,pu.has(this)&&(pu.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||wx(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Ep(this),Sx(this);const e=Dt,t=Es;Dt=this,Es=!0;try{return this.fn()}finally{Tx(this),Dt=e,Es=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Dm(e);this.deps=this.depsTail=void 0,Ep(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?pu.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){af(this)&&this.run()}get dirty(){return af(this)}}let bx=0,Ua,$a;function wx(s,e=!1){if(s.flags|=8,e){s.next=$a,$a=s;return}s.next=Ua,Ua=s}function Bm(){bx++}function Lm(){if(--bx>0)return;if($a){let e=$a;for($a=void 0;e;){const t=e.next;e.next=void 0,e.flags&=-9,e=t}}let s;for(;Ua;){let e=Ua;for(Ua=void 0;e;){const t=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(i){s||(s=i)}e=t}}if(s)throw s}function Sx(s){for(let e=s.deps;e;e=e.nextDep)e.version=-1,e.prevActiveLink=e.dep.activeLink,e.dep.activeLink=e}function Tx(s){let e,t=s.depsTail,i=t;for(;i;){const n=i.prevDep;i.version===-1?(i===t&&(t=n),Dm(i),DS(i)):e=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=n}s.deps=e,s.depsTail=t}function af(s){for(let e=s.deps;e;e=e.nextDep)if(e.dep.version!==e.version||e.dep.computed&&(Mx(e.dep.computed)||e.dep.version!==e.version))return!0;return!!s._dirty}function Mx(s){if(s.flags&4&&!(s.flags&16)||(s.flags&=-17,s.globalVersion===Ja)||(s.globalVersion=Ja,!s.isSSR&&s.flags&128&&(!s.deps&&!s._dirty||!af(s))))return;s.flags|=2;const e=s.dep,t=Dt,i=Es;Dt=s,Es=!0;try{Sx(s);const n=s.fn(s._value);(e.version===0||Qs(n,s._value))&&(s.flags|=128,s._value=n,e.version++)}catch(n){throw e.version++,n}finally{Dt=t,Es=i,Tx(s),s.flags&=-3}}function Dm(s,e=!1){const{dep:t,prevSub:i,nextSub:n}=s;if(i&&(i.nextSub=n,s.prevSub=void 0),n&&(n.prevSub=i,s.nextSub=void 0),t.subs===s&&(t.subs=i,!i&&t.computed)){t.computed.flags&=-5;for(let r=t.computed.deps;r;r=r.nextDep)Dm(r,!0)}!e&&!--t.sc&&t.map&&t.map.delete(t.key)}function DS(s){const{prevDep:e,nextDep:t}=s;e&&(e.nextDep=t,s.prevDep=void 0),t&&(t.prevDep=e,s.nextDep=void 0)}let Es=!0;const _x=[];function Nn(){_x.push(Es),Es=!1}function Un(){const s=_x.pop();Es=s===void 0?!0:s}function Ep(s){const{cleanup:e}=s;if(s.cleanup=void 0,e){const t=Dt;Dt=void 0;try{e()}finally{Dt=t}}}let Ja=0;class NS{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Nm{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!Dt||!Es||Dt===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==Dt)t=this.activeLink=new NS(Dt,this),Dt.deps?(t.prevDep=Dt.depsTail,Dt.depsTail.nextDep=t,Dt.depsTail=t):Dt.deps=Dt.depsTail=t,Cx(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){const i=t.nextDep;i.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=i),t.prevDep=Dt.depsTailLine truncated
* @vue/runtime-core v3.5.41
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/function pl(s,e,t,i){try{return i?s(...i):s()}catch(n){Nh(n,e,t)}}function ps(s,e,t,i){if(tt(s)){const n=pl(s,e,t,i);return n&&ox(n)&&n.catch(r=>{Nh(r,e,t)}),n}if(We(s)){const n=[];for(let r=0;r<s.length;r++)n.push(ps(s[r],e,t,i));return n}}function Nh(s,e,t,i=!0){const n=e?e.vnode:null,{errorHandler:r,throwUnhandledErrorInProduction:o}=e&&e.appContext.config||Pt;if(e){let a=e.parent;const c=e.proxy,l=`https://vuejs.org/error-reference/#runtime-${t}`;for(;a;){const h=a.ec;if(h){for(let u=0;u<h.length;u++)if(h[u](s,c,l)===!1)return}a=a.parent}if(r){On(),pl(r,null,10,[s,c,l]),Bn();return}}hT(s,t,n,i,o)}function hT(s,e,t,i=!0,n=!1){if(n)throw s;console.error(s)}const Ni=[];let Xs=-1;const No=[];let qn=null,_o=0;const kx=Promise.resolve();let Bc=null;function Uh(s){const e=Bc||kx;return s?e.then(this?s.bind(this):s):e}function uT(s){let e=Xs+1,t=Ni.length;for(;e<t;){const i=e+t>>>1,n=Ni[i],r=Qa(n);r<s||r===s&&n.flags&2?e=i+1:t=i}return e}function Xm(s){if(!(s.flags&1)){const e=Qa(s),t=Ni[Ni.length-1];!t||!(s.flags&2)&&e>=Qa(t)?Ni.push(s):Ni.splice(uT(e),0,s),s.flags|=1,Fx()}}function Fx(){Bc||(Bc=kx.then(Bx))}function dT(s){if(!We(s))qn&&s.id===-1?qn.splice(_o+1,0,s):s.flags&1||(No.push(s),s.flags|=1);else for(let e=0;e<s.length;e++)No.push(s[e]);Fx()}function Rp(s,e,t=Xs+1){for(;t<Ni.length;t++){const i=Ni[t];if(i&&i.flags&2){if(s&&i.id!==s.uid)continue;Ni.splice(t,1),t--,i.flags&4&&(i.flags&=-2),i(),i.flags&4||(i.flags&=-2)}}}function Ox(s){if(No.length){const e=[...new Set(No)].sort((t,i)=>Qa(t)-Qa(i));if(No.length=0,qn){for(let t=0;t<e.length;t++)qn.push(e[t]);return}for(qn=e,_o=0;_o<qn.length;_o++){const t=qn[_o];t.flags&4&&(t.flags&=-2),t.flags&8||t(),t.flags&=-2}qn=null,_o=0}}const Qa=s=>s.id==null?s.flags&2?-1:1/0:s.id;function Bx(s){try{for(Xs=0;Xs<Ni.length;Xs++){const e=Ni[Xs];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),pl(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;Xs<Ni.length;Xs++){const e=Ni[Xs];e&&(e.flags&=-2)}Xs=-1,Ni.length=0,Ox(),Bc=null,(Ni.length||No.length)&&Bx()}}let Fi=null,Lx=null;function Lc(s){const e=Fi;return Fi=s,Lx=s&&s.type.__scopeId||null,e}function $h(s,e=Fi,t){if(!e||s._n)return s;const i=(...n)=>{i._d&&$c(-1);const r=Lc(e),o=kn.length;let a;try{a=s(...n)}finally{for(let c=kn.length;c>o;c--)Hm();Lc(r),i._d&&$c(1)}return a};return i._n=!0,i._c=!0,i._d=!0,i}function ce(s,e){if(Fi===null)return s;const t=jh(Fi),i=s.dirs||(s.dirs=[]);for(let n=0;n<e.length;n++){let[r,o,a,c=Pt]=e[n];r&&(tt(r)&&(r={mounted:r,updated:r}),r.deep&&Sn(o),i.push({dir:r,instance:t,value:o,oldValue:void 0,arg:a,modifiers:c}))}return s}function Mr(s,e,t,i){const n=s.dirs,r=e&&e.dirs;for(let o=0;o<n.length;o++){const a=n[o];r&&(a.oldValue=r[o].value);let c=a.dir[i];c&&(On(),ps(c,t,8,[s.el,a,s,e]),Bn())}}function Dx(s,e){if(Ui){let t=Ui.provides;const i=Ui.parent&&Ui.parent.provides;i===t&&(t=Ui.provides=Object.create(i)),t[s]=e}}function Uo(s,e,t=!1){const i=jm();if(i||qr){let n=qr?qr._context.provides:i?i.parent==null||i.ce?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(n&&s in n)return n[s];if(arguments.length>1)return t&&tt(e)?e.call(i&&i.proxy):e}}function fT(){return!!(jm()||qr)}const mT=Symbol.for("v-scx"),pT=()=>Uo(mT);function Ca(s,e){return Vm(s,null,e)}function Yi(s,e,t){return Vm(s,e,t)}function Vm(s,e,t=Pt){const{immediate:i,deep:n,flush:r,once:o}=t,a=fi({},t),c=e&&i||!e&&r!=="post";let l;if(nl){if(r==="sync"){const f=pT();l=f.__watcherHandles||(f.__watcherHandles=[])}else if(!c){const f=()=>{};return f.stop=sn,f.resume=sn,f.pause=sn,f}}const h=Ui;a.call=(f,p,m)=>ps(f,h,p,m);let u=!1;r==="post"?a.scheduler=f=>{ji(f,h&&h.suspense)}:r!=="sync"&&(u=!0,a.scheduler=(f,p)=>{p?f():Xm(f)}),a.augmentJob=f=>{e&&(f.flags|=4),u&&(f.flags|=2,h&&(f.id=h.uid,f.i=h))};const d=cT(s,e,a);return nl&&(l?l.push(d):c&&d()),d}function gT(s,e,t){const i=this.proxy,n=jt(s)?s.includes(".")?Nx(i,s):()=>i[s]:s.bind(i,i);let r;tt(e)?r=e:(r=e.handler,t=e);const o=xl(this),a=Vm(n,r.bind(i),t);return o(),a}function Nx(s,e){const t=e.split(".");return()=>{let i=s;for(let n=0;n<t.length&&i;n++)i=i[t[n]];return i}}const vT=Symbol("_vte"),Xh=s=>s.__isTeleport,hs=Symbol("_leaveCb"),va=Symbol("_enterCb");function xT(){const s={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Vn(()=>{s.isMounted=!0}),gl(()=>{s.isUnmounting=!0}),s}const os=[Function,Array],Ux={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:os,onEnter:os,onAfterEnter:os,onEnterCancelled:os,onBeforeLeave:os,onLeave:os,onAfterLeave:os,onLeaveCancelled:os,onBeforeAppear:os,onAppear:os,onAfterAppear:os,onAppearCancelled:os},$x=s=>{const e=s.subTree;return e.component?$x(e.component):e},yT={name:"BaseTransition",props:Ux,setup(s,{slots:e}){const t=jm(),i=xT();return()=>{const n=e.default&&Yx(e.default(),!0),r=n&&n.length?Xx(n):t.subTree?Te():void 0;if(!r)return;const o=xt(s),{mode:a}=o;if(i.isLeaving)return xu(r);const c=Dc(r);if(!c)return xu(r);let l=uf(c,o,i,t,u=>l=u);c.type!==ki&&el(c,l);let Line truncated
**/function gl(s,e,t,i){try{return i?s(...i):s()}catch(n){Nh(n,e,t)}}function ps(s,e,t,i){if(st(s)){const n=gl(s,e,t,i);return n&&lx(n)&&n.catch(r=>{Nh(r,e,t)}),n}if(je(s)){const n=[];for(let r=0;r<s.length;r++)n.push(ps(s[r],e,t,i));return n}}function Nh(s,e,t,i=!0){const n=e?e.vnode:null,{errorHandler:r,throwUnhandledErrorInProduction:o}=e&&e.appContext.config||Ft;if(e){let a=e.parent;const c=e.proxy,l=`https://vuejs.org/error-reference/#runtime-${t}`;for(;a;){const h=a.ec;if(h){for(let u=0;u<h.length;u++)if(h[u](s,c,l)===!1)return}a=a.parent}if(r){Nn(),gl(r,null,10,[s,c,l]),Un();return}}dT(s,t,n,i,o)}function dT(s,e,t,i=!0,n=!1){if(n)throw s;console.error(s)}const Ni=[];let Gs=-1;const $o=[];let Qn=null,Ao=0;const Ox=Promise.resolve();let Bc=null;function Uh(s){const e=Bc||Ox;return s?e.then(this?s.bind(this):s):e}function fT(s){let e=Gs+1,t=Ni.length;for(;e<t;){const i=e+t>>>1,n=Ni[i],r=el(n);r<s||r===s&&n.flags&2?e=i+1:t=i}return e}function Xm(s){if(!(s.flags&1)){const e=el(s),t=Ni[Ni.length-1];!t||!(s.flags&2)&&e>=el(t)?Ni.push(s):Ni.splice(fT(e),0,s),s.flags|=1,Bx()}}function Bx(){Bc||(Bc=Ox.then(Dx))}function mT(s){if(!je(s))Qn&&s.id===-1?Qn.splice(Ao+1,0,s):s.flags&1||($o.push(s),s.flags|=1);else for(let e=0;e<s.length;e++)$o.push(s[e]);Bx()}function Rp(s,e,t=Gs+1){for(;t<Ni.length;t++){const i=Ni[t];if(i&&i.flags&2){if(s&&i.id!==s.uid)continue;Ni.splice(t,1),t--,i.flags&4&&(i.flags&=-2),i(),i.flags&4||(i.flags&=-2)}}}function Lx(s){if($o.length){const e=[...new Set($o)].sort((t,i)=>el(t)-el(i));if($o.length=0,Qn){for(let t=0;t<e.length;t++)Qn.push(e[t]);return}for(Qn=e,Ao=0;Ao<Qn.length;Ao++){const t=Qn[Ao];t.flags&4&&(t.flags&=-2),t.flags&8||t(),t.flags&=-2}Qn=null,Ao=0}}const el=s=>s.id==null?s.flags&2?-1:1/0:s.id;function Dx(s){try{for(Gs=0;Gs<Ni.length;Gs++){const e=Ni[Gs];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),gl(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;Gs<Ni.length;Gs++){const e=Ni[Gs];e&&(e.flags&=-2)}Gs=-1,Ni.length=0,Lx(),Bc=null,(Ni.length||$o.length)&&Dx()}}let Oi=null,Nx=null;function Lc(s){const e=Oi;return Oi=s,Nx=s&&s.type.__scopeId||null,e}function $h(s,e=Oi,t){if(!e||s._n)return s;const i=(...n)=>{i._d&&$c(-1);const r=Lc(e),o=Ln.length;let a;try{a=s(...n)}finally{for(let c=Ln.length;c>o;c--)Hm();Lc(r),i._d&&$c(1)}return a};return i._n=!0,i._c=!0,i._d=!0,i}function le(s,e){if(Oi===null)return s;const t=jh(Oi),i=s.dirs||(s.dirs=[]);for(let n=0;n<e.length;n++){let[r,o,a,c=Ft]=e[n];r&&(st(r)&&(r={mounted:r,updated:r}),r.deep&&Cn(o),i.push({dir:r,instance:t,value:o,oldValue:void 0,arg:a,modifiers:c}))}return s}function Ar(s,e,t,i){const n=s.dirs,r=e&&e.dirs;for(let o=0;o<n.length;o++){const a=n[o];r&&(a.oldValue=r[o].value);let c=a.dir[i];c&&(Nn(),ps(c,t,8,[s.el,a,s,e]),Un())}}function Ux(s,e){if(Ui){let t=Ui.provides;const i=Ui.parent&&Ui.parent.provides;i===t&&(t=Ui.provides=Object.create(i)),t[s]=e}}function Xo(s,e,t=!1){const i=jm();if(i||Jr){let n=Jr?Jr._context.provides:i?i.parent==null||i.ce?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(n&&s in n)return n[s];if(arguments.length>1)return t&&st(e)?e.call(i&&i.proxy):e}}function pT(){return!!(jm()||Jr)}const gT=Symbol.for("v-scx"),vT=()=>Xo(gT);function Aa(s,e){return Vm(s,null,e)}function Yi(s,e,t){return Vm(s,e,t)}function Vm(s,e,t=Ft){const{immediate:i,deep:n,flush:r,once:o}=t,a=fi({},t),c=e&&i||!e&&r!=="post";let l;if(rl){if(r==="sync"){const f=vT();l=f.__watcherHandles||(f.__watcherHandles=[])}else if(!c){const f=()=>{};return f.stop=on,f.resume=on,f.pause=on,f}}const h=Ui;a.call=(f,p,m)=>ps(f,h,p,m);let u=!1;r==="post"?a.scheduler=f=>{Hi(f,h&&h.suspense)}:r!=="sync"&&(u=!0,a.scheduler=(f,p)=>{p?f():Xm(f)}),a.augmentJob=f=>{e&&(f.flags|=4),u&&(f.flags|=2,h&&(f.id=h.uid,f.i=h))};const d=uT(s,e,a);return rl&&(l?l.push(d):c&&d()),d}function xT(s,e,t){const i=this.proxy,n=Wt(s)?s.includes(".")?$x(i,s):()=>i[s]:s.bind(i,i);let r;st(e)?r=e:(r=e.handler,t=e);const o=yl(this),a=Vm(n,r.bind(i),t);return o(),a}function $x(s,e){const t=e.split(".");return()=>{let i=s;for(let n=0;n<t.length&&i;n++)i=i[t[n]];return i}}const yT=Symbol("_vte"),Xh=s=>s.__isTeleport,hs=Symbol("_leaveCb"),xa=Symbol("_enterCb");function bT(){const s={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return jn(()=>{s.isMounted=!0}),vl(()=>{s.isUnmounting=!0}),s}const os=[Function,Array],Xx={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:os,onEnter:os,onAfterEnter:os,onEnterCancelled:os,onBeforeLeave:os,onLeave:os,onAfterLeave:os,onLeaveCancelled:os,onBeforeAppear:os,onAppear:os,onAfterAppear:os,onAppearCancelled:os},Vx=s=>{const e=s.subTree;return e.component?Vx(e.component):e},wT={name:"BaseTransition",props:Xx,setup(s,{slots:e}){const t=jm(),i=bT();return()=>{const n=e.default&&Hx(e.default(),!0),r=n&&n.length?Yx(n):t.subTree?Te():void 0;if(!r)return;const o=yt(s),{mode:a}=o;if(i.isLeaving)return xu(r);const c=Dc(r);if(!c)return xu(r);let l=uf(c,o,i,t,u=>l=u);c.type!==Fi&&tl(c,l);let Line truncated
* @vue/runtime-dom v3.5.41
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/let gf;const Yp=typeof window<"u"&&window.trustedTypes;if(Yp)try{gf=Yp.createPolicy("vue",{createHTML:s=>s})}catch{}const my=gf?s=>gf.createHTML(s):s=>s,xM="http://www.w3.org/2000/svg",yM="http://www.w3.org/1998/Math/MathML",pn=typeof document<"u"?document:null,Gp=pn&&pn.createElement("template"),bM={insert:(s,e,t)=>{e.insertBefore(s,t||null)},remove:s=>{const e=s.parentNode;e&&e.removeChild(s)},createElement:(s,e,t,i)=>{const n=e==="svg"?pn.createElementNS(xM,s):e==="mathml"?pn.createElementNS(yM,s):t?pn.createElement(s,{is:t}):pn.createElement(s);return s==="select"&&i&&i.multiple!=null&&n.setAttribute("multiple",i.multiple),n},createText:s=>pn.createTextNode(s),createComment:s=>pn.createComment(s),setText:(s,e)=>{s.nodeValue=e},setElementText:(s,e)=>{s.textContent=e},parentNode:s=>s.parentNode,nextSibling:s=>s.nextSibling,querySelector:s=>pn.querySelector(s),setScopeId(s,e){s.setAttribute(e,"")},insertStaticContent(s,e,t,i,n,r){const o=t?t.previousSibling:e.lastChild;if(n&&(n===r||n.nextSibling))for(;e.insertBefore(n.cloneNode(!0),t),!(n===r||!(n=n.nextSibling)););else{Gp.innerHTML=my(i==="svg"?`<svg>${s}</svg>`:i==="mathml"?`<math>${s}</math>`:s);const a=Gp.content;if(i==="svg"||i==="mathml"){const c=a.firstChild;for(;c.firstChild;)a.appendChild(c.firstChild);a.removeChild(c)}e.insertBefore(a,t)}return[o?o.nextSibling:e.firstChild,t?t.previousSibling:e.lastChild]}},Yn="transition",xa="animation",rl=Symbol("_vtc"),py={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},wM=fi({},Ux,py),SM=s=>(s.displayName="Transition",s.props=wM,s),TM=SM((s,{slots:e})=>gM(bT,MM(s),e)),Cr=(s,e=[])=>{We(s)?s.forEach(t=>t(...e)):s&&s(...e)},Hp=s=>s?We(s)?s.some(e=>e.length>1):s.length>1:!1;function MM(s){const e={};for(const k in s)k in py||(e[k]=s[k]);if(s.css===!1)return e;const{name:t="v",type:i,duration:n,enterFromClass:r=`${t}-enter-from`,enterActiveClass:o=`${t}-enter-active`,enterToClass:a=`${t}-enter-to`,appearFromClass:c=r,appearActiveClass:l=o,appearToClass:h=a,leaveFromClass:u=`${t}-leave-from`,leaveActiveClass:d=`${t}-leave-active`,leaveToClass:f=`${t}-leave-to`}=s,p=_M(n),m=p&&p[0],g=p&&p[1],{onBeforeEnter:v,onEnter:y,onEnterCancelled:x,onLeave:T,onLeaveCancelled:A,onBeforeAppear:S=v,onAppear:b=y,onAppearCancelled:_=x}=e,I=(k,O,L,$)=>{k._enterCancelled=$,Ar(k,O?h:a),Ar(k,O?l:o),L&&L()},F=(k,O)=>{k._isLeaving=!1,Ar(k,u),Ar(k,f),Ar(k,d),O&&O()},E=k=>(O,L)=>{const $=k?b:y,D=()=>I(O,k,L);Cr($,[O,D]),jp(()=>{Ar(O,k?c:r),un(O,k?h:a),Hp($)||Wp(O,i,m,D)})};return fi(e,{onBeforeEnter(k){Cr(v,[k]),un(k,r),un(k,o)},onBeforeAppear(k){Cr(S,[k]),un(k,c),un(k,l)},onEnter:E(!1),onAppear:E(!0),onLeave(k,O){k._isLeaving=!0;const L=()=>F(k,O);un(k,u),k._enterCancelled?(un(k,d),Kp(k)):(Kp(k),un(k,d)),jp(()=>{k._isLeaving&&(Ar(k,u),un(k,f),Hp(T)||Wp(k,i,g,L))}),Cr(T,[k,L])},onEnterCancelled(k){I(k,!1,void 0,!0),Cr(x,[k])},onAppearCancelled(k){I(k,!0,void 0,!0),Cr(_,[k])},onLeaveCancelled(k){F(k),Cr(A,[k])}})}function _M(s){if(s==null)return null;if(At(s))return[wu(s.enter),wu(s.leave)];{const e=wu(s);return[e,e]}}function wu(s){return CS(s)}function un(s,e){e.split(/\s+/).forEach(t=>t&&s.classList.add(t)),(s[rl]||(s[rl]=new Set)).add(e)}function Ar(s,e){e.split(/\s+/).forEach(i=>i&&s.classList.remove(i));const t=s[rl];t&&(t.delete(e),t.size||(s[rl]=void 0))}function jp(s){requestAnimationFrame(()=>{requestAnimationFrame(s)})}let CM=0;function Wp(s,e,t,i){const n=s._endId=++CM,r=()=>{n===s._endId&&i()};if(t!=null)return setTimeout(r,t);const{type:o,timeout:a,propCount:c}=AM(s,e);if(!o)return i();const l=o+"end";let h=0;const u=()=>{s.removeEventListener(l,d),r()},d=f=>{f.target===s&&++h>=c&&u()};setTimeout(()=>{h<c&&u()},a+1),s.addEventListener(l,d)}function AM(s,e){const t=window.getComputedStyle(s),i=p=>(t[p]||"").split(", "),n=i(`${Yn}Delay`),r=i(`${Yn}Duration`),o=zp(n,r),a=i(`${xa}Delay`),c=i(`${xa}Duration`),l=zp(a,c);let h=null,u=0,d=0;e===Yn?o>0&&(h=Yn,u=o,d=r.length):e===xa?l>0&&(h=xa,u=l,d=c.length):(u=Math.max(o,l),h=u>0?o>l?Yn:xa:null,d=h?h===Yn?r.length:c.length:0);const f=h===Yn&&/\b(?:transform|all)(?:,|$)/.test(i(`${Yn}Property`).toString());return{type:h,timeout:u,propCount:d,hasTransform:f}}function zp(s,e){for(;s.length<e.length;)s=s.concat(s);return Math.max(...e.map((t,i)=>qp(t)+qp(s[i])))}function qp(s){return s==="auto"?0:Number(s.slice(0,-1).replace(",","."))*1e3}function Kp(s){return(s?s.ownerDocument:document).body.offsetHeight}function EM(s,e,t){const i=s[rl];i&&(e=(e?[e,...i]:[...i]).join(" ")),e==null?s.removeAttribute("class"):t?s.setAttribute("class",e):s.className=e}const Yc=Symbol("_vod"),gy=Symbol("_vsh"),bi={name:"show",beforeMount(s,{value:e},{transition:t}){s[Yc]=s.style.display==="none"?"":s.style.display,t&&e?t.beforeEnter(s):ya(s,e)},mounted(s,{value:e},{tra Line truncated
`))),s[Js]=Jo(n);const r=i||n.props&&n.props.type==="number";er(s,e?"change":"input",o=>{o.target.composing||s[Js](Mu(s.value,t,r))}),(t||r)&&er(s,"change",()=>{s.value=Mu(s.value,t,r)}),e||(er(s,"compositionstart",HM),er(s,"compositionend",ng),er(s,"change",ng))},mounted(s,{value:e,modifiers:{trim:t,number:i}}){const n=e??"",r=s[Bl];delete s[Bl],r!==void 0&&(s.type==="text"||s.type==="textarea")&&s.value!==r?s[Js](Mu(s.value,t,i)):s.value=n},beforeUpdate(s,{value:e,oldValue:t,modifiers:{lazy:i,trim:n,number:r}},o){if(s[Js]=Jo(o),s.composing)return;const a=(r||s.type==="number")&&!/^0\d/.test(s.value)?Oh(s.value):s.value,c=e??"";if(a===c)return;const l=s.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===s&&s.type!=="range"&&(i&&e===t||n&&s.value.trim()===c)||(s.value=c)}},wt={deep:!0,created(s,e,t){s[Js]=Jo(t),er(s,"change",()=>{const i=s._modelValue,n=ol(s),r=s.checked,o=s[Js];if(We(i)){const a=Om(i,n),c=a!==-1;if(r&&!c)o(i.concat(n));else if(!r&&c){const l=[...i];l.splice(a,1),o(l)}}else if(ra(i)){const a=new Set(i);r?a.add(n):a.delete(n),o(a)}else o(vy(s,r))})},mounted:rg,beforeUpdate(s,e,t){s[Js]=Jo(t),rg(s,e,t)}};function rg(s,{value:e,oldValue:t},i){s._modelValue=e;let n;if(We(e))n=Om(e,i.props.value)>-1;else if(ra(e))n=e.has(i.props.value);else{if(e===t)return;n=oa(e,vy(s,!0))}s.checked!==n&&(s.checked=n)}const St={deep:!0,created(s,{value:e,modifiers:{number:t}},i){s._modelValue=e,er(s,"change",()=>{const n=Array.prototype.filter.call(s.options,r=>r.selected).map(r=>t?Oh(ol(r)):ol(r));s[Js](s.multiple?ra(s._modelValue)?new Set(n):n:n[0]),s._assigning=!0,Uh(()=>{s._assigning=!1})}),s[Js]=Jo(i)},mounted(s,{value:e}){og(s,e)},beforeUpdate(s,{value:e},t){s._modelValue=e,s[Js]=Jo(t)},updated(s,{value:e}){s._assigning||og(s,e)}};function og(s,e){const t=s.multiple,i=We(e);if(!(t&&!i&&!ra(e))){for(let n=0,r=s.options.length;n<r;n++){const o=s.options[n],a=ol(o);if(t)if(i){const c=typeof a;c==="string"||c==="number"?o.selected=e.some(l=>String(l)===String(a)):o.selected=Om(e,a)>-1}else o.selected=e.has(a);else if(oa(ol(o),e)){s.selectedIndex!==n&&(s.selectedIndex=n);return}}!t&&s.selectedIndex!==-1&&(s.selectedIndex=-1)}}function ol(s){return"_value"in s?s._value:s.value}function vy(s,e){const t=e?"_trueValue":"_falseValue";return t in s?s[t]:e}const jM=["ctrl","shift","alt","meta"],WM={stop:s=>s.stopPropagation(),prevent:s=>s.preventDefault(),self:s=>s.target!==s.currentTarget,ctrl:s=>!s.ctrlKey,shift:s=>!s.shiftKey,alt:s=>!s.altKey,meta:s=>!s.metaKey,left:s=>"button"in s&&s.button!==0,middle:s=>"button"in s&&s.button!==1,right:s=>"button"in s&&s.button!==2,exact:(s,e)=>jM.some(t=>s[`${t}Key`]&&!e.includes(t))},Qe=(s,e)=>{if(!s)return s;const t=s._withMods||(s._withMods={}),i=e.join(".");return t[i]||(t[i]=((n,...r)=>{for(let o=0;o<e.length;o++){const a=WM[e[o]];if(a&&a(n,e))return}return s(n,...r)}))},zM={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Kr=(s,e)=>{const t=s._withKeys||(s._withKeys={}),i=e.join(".");return t[i]||(t[i]=(n=>{if(!("key"in n))return;const r=vr(n.key);if(e.some(o=>o===r||zM[o]===r))return s(n)}))},qM=fi({patchProp:VM},bM);let ag;function KM(){return ag||(ag=eM(qM))}const ZM=((...s)=>{const e=KM().createApp(...s),{mount:t}=e;return e.mount=i=>{const n=QM(i);if(!n)return;const r=e._component;!tt(r)&&!r.render&&!r.template&&(r.template=n.innerHTML),n.nodeType===1&&(n.textContent="");const o=t(n,!1,JM(n));return n instanceof Element&&(n.removeAttribute("v-cloak"),n.setAttribute("data-v-app","")),o},e});function JM(s){if(s instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&s instanceof MathMLElement)return"mathml"}function QM(s){return jt(s)?document.querySelector(s):s}/*!
**/let gf;const Yp=typeof window<"u"&&window.trustedTypes;if(Yp)try{gf=Yp.createPolicy("vue",{createHTML:s=>s})}catch{}const gy=gf?s=>gf.createHTML(s):s=>s,bM="http://www.w3.org/2000/svg",wM="http://www.w3.org/1998/Math/MathML",yn=typeof document<"u"?document:null,Gp=yn&&yn.createElement("template"),SM={insert:(s,e,t)=>{e.insertBefore(s,t||null)},remove:s=>{const e=s.parentNode;e&&e.removeChild(s)},createElement:(s,e,t,i)=>{const n=e==="svg"?yn.createElementNS(bM,s):e==="mathml"?yn.createElementNS(wM,s):t?yn.createElement(s,{is:t}):yn.createElement(s);return s==="select"&&i&&i.multiple!=null&&n.setAttribute("multiple",i.multiple),n},createText:s=>yn.createTextNode(s),createComment:s=>yn.createComment(s),setText:(s,e)=>{s.nodeValue=e},setElementText:(s,e)=>{s.textContent=e},parentNode:s=>s.parentNode,nextSibling:s=>s.nextSibling,querySelector:s=>yn.querySelector(s),setScopeId(s,e){s.setAttribute(e,"")},insertStaticContent(s,e,t,i,n,r){const o=t?t.previousSibling:e.lastChild;if(n&&(n===r||n.nextSibling))for(;e.insertBefore(n.cloneNode(!0),t),!(n===r||!(n=n.nextSibling)););else{Gp.innerHTML=gy(i==="svg"?`<svg>${s}</svg>`:i==="mathml"?`<math>${s}</math>`:s);const a=Gp.content;if(i==="svg"||i==="mathml"){const c=a.firstChild;for(;c.firstChild;)a.appendChild(c.firstChild);a.removeChild(c)}e.insertBefore(a,t)}return[o?o.nextSibling:e.firstChild,t?t.previousSibling:e.lastChild]}},Wn="transition",ya="animation",ol=Symbol("_vtc"),vy={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},TM=fi({},Xx,vy),MM=s=>(s.displayName="Transition",s.props=TM,s),_M=MM((s,{slots:e})=>xM(ST,CM(s),e)),Ir=(s,e=[])=>{je(s)?s.forEach(t=>t(...e)):s&&s(...e)},Hp=s=>s?je(s)?s.some(e=>e.length>1):s.length>1:!1;function CM(s){const e={};for(const k in s)k in vy||(e[k]=s[k]);if(s.css===!1)return e;const{name:t="v",type:i,duration:n,enterFromClass:r=`${t}-enter-from`,enterActiveClass:o=`${t}-enter-active`,enterToClass:a=`${t}-enter-to`,appearFromClass:c=r,appearActiveClass:l=o,appearToClass:h=a,leaveFromClass:u=`${t}-leave-from`,leaveActiveClass:d=`${t}-leave-active`,leaveToClass:f=`${t}-leave-to`}=s,p=AM(n),m=p&&p[0],g=p&&p[1],{onBeforeEnter:v,onEnter:y,onEnterCancelled:x,onLeave:T,onLeaveCancelled:A,onBeforeAppear:S=v,onAppear:b=y,onAppearCancelled:_=x}=e,I=(k,B,N,$)=>{k._enterCancelled=$,Rr(k,B?h:a),Rr(k,B?l:o),N&&N()},F=(k,B)=>{k._isLeaving=!1,Rr(k,u),Rr(k,f),Rr(k,d),B&&B()},E=k=>(B,N)=>{const $=k?b:y,L=()=>I(B,k,N);Ir($,[B,L]),jp(()=>{Rr(B,k?c:r),pn(B,k?h:a),Hp($)||Wp(B,i,m,L)})};return fi(e,{onBeforeEnter(k){Ir(v,[k]),pn(k,r),pn(k,o)},onBeforeAppear(k){Ir(S,[k]),pn(k,c),pn(k,l)},onEnter:E(!1),onAppear:E(!0),onLeave(k,B){k._isLeaving=!0;const N=()=>F(k,B);pn(k,u),k._enterCancelled?(pn(k,d),Kp(k)):(Kp(k),pn(k,d)),jp(()=>{k._isLeaving&&(Rr(k,u),pn(k,f),Hp(T)||Wp(k,i,g,N))}),Ir(T,[k,N])},onEnterCancelled(k){I(k,!1,void 0,!0),Ir(x,[k])},onAppearCancelled(k){I(k,!0,void 0,!0),Ir(_,[k])},onLeaveCancelled(k){F(k),Ir(A,[k])}})}function AM(s){if(s==null)return null;if(It(s))return[wu(s.enter),wu(s.leave)];{const e=wu(s);return[e,e]}}function wu(s){return ES(s)}function pn(s,e){e.split(/\s+/).forEach(t=>t&&s.classList.add(t)),(s[ol]||(s[ol]=new Set)).add(e)}function Rr(s,e){e.split(/\s+/).forEach(i=>i&&s.classList.remove(i));const t=s[ol];t&&(t.delete(e),t.size||(s[ol]=void 0))}function jp(s){requestAnimationFrame(()=>{requestAnimationFrame(s)})}let EM=0;function Wp(s,e,t,i){const n=s._endId=++EM,r=()=>{n===s._endId&&i()};if(t!=null)return setTimeout(r,t);const{type:o,timeout:a,propCount:c}=IM(s,e);if(!o)return i();const l=o+"end";let h=0;const u=()=>{s.removeEventListener(l,d),r()},d=f=>{f.target===s&&++h>=c&&u()};setTimeout(()=>{h<c&&u()},a+1),s.addEventListener(l,d)}function IM(s,e){const t=window.getComputedStyle(s),i=p=>(t[p]||"").split(", "),n=i(`${Wn}Delay`),r=i(`${Wn}Duration`),o=zp(n,r),a=i(`${ya}Delay`),c=i(`${ya}Duration`),l=zp(a,c);let h=null,u=0,d=0;e===Wn?o>0&&(h=Wn,u=o,d=r.length):e===ya?l>0&&(h=ya,u=l,d=c.length):(u=Math.max(o,l),h=u>0?o>l?Wn:ya:null,d=h?h===Wn?r.length:c.length:0);const f=h===Wn&&/\b(?:transform|all)(?:,|$)/.test(i(`${Wn}Property`).toString());return{type:h,timeout:u,propCount:d,hasTransform:f}}function zp(s,e){for(;s.length<e.length;)s=s.concat(s);return Math.max(...e.map((t,i)=>qp(t)+qp(s[i])))}function qp(s){return s==="auto"?0:Number(s.slice(0,-1).replace(",","."))*1e3}function Kp(s){return(s?s.ownerDocument:document).body.offsetHeight}function RM(s,e,t){const i=s[ol];i&&(e=(e?[e,...i]:[...i]).join(" ")),e==null?s.removeAttribute("class"):t?s.setAttribute("class",e):s.className=e}const Yc=Symbol("_vod"),xy=Symbol("_vsh"),bi={name:"show",beforeMount(s,{value:e},{transition:t}){s[Yc]=s.style.display==="none"?"":s.style.display,t&&e?t.beforeEnter(s):ba(s,e)},mounted(s,{value:e},{tra Line truncated
`))),s[tn]=ea(n);const r=i||n.props&&n.props.type==="number";nr(s,e?"change":"input",o=>{o.target.composing||s[tn](Mu(s.value,t,r))}),(t||r)&&nr(s,"change",()=>{s.value=Mu(s.value,t,r)}),e||(nr(s,"compositionstart",WM),nr(s,"compositionend",ng),nr(s,"change",ng))},mounted(s,{value:e,modifiers:{trim:t,number:i}}){const n=e??"",r=s[Bl];delete s[Bl],r!==void 0&&(s.type==="text"||s.type==="textarea")&&s.value!==r?s[tn](Mu(s.value,t,i)):s.value=n},beforeUpdate(s,{value:e,oldValue:t,modifiers:{lazy:i,trim:n,number:r}},o){if(s[tn]=ea(o),s.composing)return;const a=(r||s.type==="number")&&!/^0\d/.test(s.value)?Oh(s.value):s.value,c=e??"";if(a===c)return;const l=s.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===s&&s.type!=="range"&&(i&&e===t||n&&s.value.trim()===c)||(s.value=c)}},St={deep:!0,created(s,e,t){s[tn]=ea(t),nr(s,"change",()=>{const i=s._modelValue,n=al(s),r=s.checked,o=s[tn];if(je(i)){const a=Om(i,n),c=a!==-1;if(r&&!c)o(i.concat(n));else if(!r&&c){const l=[...i];l.splice(a,1),o(l)}}else if(aa(i)){const a=new Set(i);r?a.add(n):a.delete(n),o(a)}else o(yy(s,r))})},mounted:rg,beforeUpdate(s,e,t){s[tn]=ea(t),rg(s,e,t)}};function rg(s,{value:e,oldValue:t},i){s._modelValue=e;let n;if(je(e))n=Om(e,i.props.value)>-1;else if(aa(e))n=e.has(i.props.value);else{if(e===t)return;n=la(e,yy(s,!0))}s.checked!==n&&(s.checked=n)}const Tt={deep:!0,created(s,{value:e,modifiers:{number:t}},i){s._modelValue=e,nr(s,"change",()=>{const n=Array.prototype.filter.call(s.options,r=>r.selected).map(r=>t?Oh(al(r)):al(r));s[tn](s.multiple?aa(s._modelValue)?new Set(n):n:n[0]),s._assigning=!0,Uh(()=>{s._assigning=!1})}),s[tn]=ea(i)},mounted(s,{value:e}){og(s,e)},beforeUpdate(s,{value:e},t){s._modelValue=e,s[tn]=ea(t)},updated(s,{value:e}){s._assigning||og(s,e)}};function og(s,e){const t=s.multiple,i=je(e);if(!(t&&!i&&!aa(e))){for(let n=0,r=s.options.length;n<r;n++){const o=s.options[n],a=al(o);if(t)if(i){const c=typeof a;c==="string"||c==="number"?o.selected=e.some(l=>String(l)===String(a)):o.selected=Om(e,a)>-1}else o.selected=e.has(a);else if(la(al(o),e)){s.selectedIndex!==n&&(s.selectedIndex=n);return}}!t&&s.selectedIndex!==-1&&(s.selectedIndex=-1)}}function al(s){return"_value"in s?s._value:s.value}function yy(s,e){const t=e?"_trueValue":"_falseValue";return t in s?s[t]:e}const zM=["ctrl","shift","alt","meta"],qM={stop:s=>s.stopPropagation(),prevent:s=>s.preventDefault(),self:s=>s.target!==s.currentTarget,ctrl:s=>!s.ctrlKey,shift:s=>!s.shiftKey,alt:s=>!s.altKey,meta:s=>!s.metaKey,left:s=>"button"in s&&s.button!==0,middle:s=>"button"in s&&s.button!==1,right:s=>"button"in s&&s.button!==2,exact:(s,e)=>zM.some(t=>s[`${t}Key`]&&!e.includes(t))},tt=(s,e)=>{if(!s)return s;const t=s._withMods||(s._withMods={}),i=e.join(".");return t[i]||(t[i]=((n,...r)=>{for(let o=0;o<e.length;o++){const a=qM[e[o]];if(a&&a(n,e))return}return s(n,...r)}))},KM={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Qr=(s,e)=>{const t=s._withKeys||(s._withKeys={}),i=e.join(".");return t[i]||(t[i]=(n=>{if(!("key"in n))return;const r=wr(n.key);if(e.some(o=>o===r||KM[o]===r))return s(n)}))},ZM=fi({patchProp:GM},SM);let ag;function JM(){return ag||(ag=iM(ZM))}const QM=((...s)=>{const e=JM().createApp(...s),{mount:t}=e;return e.mount=i=>{const n=t_(i);if(!n)return;const r=e._component;!st(r)&&!r.render&&!r.template&&(r.template=n.innerHTML),n.nodeType===1&&(n.textContent="");const o=t(n,!1,e_(n));return n instanceof Element&&(n.removeAttribute("v-cloak"),n.setAttribute("data-v-app","")),o},e});function e_(s){if(s instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&s instanceof MathMLElement)return"mathml"}function t_(s){return Wt(s)?document.querySelector(s):s}/*!
* pinia v4.0.3
* (c) 2026 Eduardo San Martin Morote
* @license MIT
*/let xy;const Wh=s=>xy=s,yy=Symbol();function lg(s){return s&&typeof s=="object"&&Object.prototype.toString.call(s)==="[object Object]"&&typeof s.toJSON!="function"}function e_(){const s=px(!0),e=s.run(()=>Ge({}));let t=[],i=[];const n=nr({install(r){Wh(n),n._a=r,r.provide(yy,n),r.config.globalProperties.$pinia=n,i.forEach(o=>t.push(o)),i=[]},use(r){return this._a?t.push(r):i.push(r),this},_p:t,_a:null,_e:s,_s:new Map,state:e});return n}const vf=()=>{};function cg(s,e,t,i=vf){s.add(e);const n=()=>{s.delete(e)&&i()};return!t&&gx()&&OS(n),n}function vo(s,...e){s.forEach(t=>{t(...e)})}const t_=s=>s(),hg=Symbol(),_u=Symbol();function xf(s,e){s instanceof Map&&e instanceof Map?e.forEach((t,i)=>s.set(i,t)):s instanceof Set&&e instanceof Set&&e.forEach(s.add,s);for(const t in e){if(!Object.hasOwn(e,t))continue;const i=e[t],n=s[t];lg(n)&&lg(i)&&Object.hasOwn(s,t)&&!Wt(i)&&!Pn(i)?s[t]=xf(n,i):s[t]=i}return s}const i_=Symbol();function s_(s){return!s||typeof s!="object"||!Object.hasOwn(s,i_)}const{assign:jn}=Object;function n_(s){return!!(Wt(s)&&s.effect)}function r_(s,e,t,i){const{state:n,actions:r,getters:o}=e,a=t.state.value[s];let c;function l(){a||(t.state.value[s]=n?n():{});const h=sT(t.state.value[s]);return jn(h,r,Object.keys(o||{}).reduce((u,d)=>(u[d]=nr(qe(()=>{Wh(t);const f=t._s.get(s);return o[d].call(f,f)})),u),{}))}return c=by(s,l,e,t,i,!0),c}function by(s,e,t={},i,n,r){let o;const a=jn({actions:{}},t),c={deep:!0};let l,h,u=new Set,d=new Set,f;const p=i.state.value[s];!r&&!p&&(i.state.value[s]={});let m;function g(b){let _;l=h=!1,typeof b=="function"?(b(i.state.value[s]),_={type:"patch function",storeId:s,events:f}):(xf(i.state.value[s],b),_={type:"patch object",payload:b,storeId:s,events:f});const I=m=Symbol();Uh().then(()=>{m===I&&(l=!0)}),h=!0,vo(u,_,i.state.value[s])}const v=r?function(){const{state:_}=t,I=_?_():{};this.$patch(F=>{jn(F,I)})}:vf;function y(){o.stop(),u.clear(),d.clear(),i._s.delete(s)}const x=(b,_="")=>{if(hg in b)return b[_u]=_,b;const I=function(){Wh(i);const F=Array.from(arguments),E=new Set,k=new Set;function O(D){E.add(D)}function L(D){k.add(D)}vo(d,{args:F,name:I[_u],store:A,after:O,onError:L});let $;try{$=b.apply(this&&this.$id===s?this:A,F)}catch(D){throw vo(k,D),D}return $ instanceof Promise?$.then(D=>(vo(E,D),D)).catch(D=>(vo(k,D),Promise.reject(D))):(vo(E,$),$)};return I[hg]=!0,I[_u]=_,I},T={_p:i,$id:s,$onAction:cg.bind(null,d),$patch:g,$reset:v,$subscribe(b,_={}){if(u.has(b))return vf;const I=cg(u,b,_.detached,()=>F()),F=o.run(()=>Yi(()=>i.state.value[s],E=>{(_.flush==="sync"?h:l)&&b({storeId:s,type:"direct",events:f},E)},jn({},c,_)));return I},$dispose:y},A=oo(T);i._s.set(s,A);const S=(i._a&&i._a.runWithContext||t_)(()=>i._e.run(()=>(o=px()).run(()=>e({action:x}))));for(const b in S){const _=S[b];Wt(_)&&!n_(_)||Pn(_)?r||(p&&s_(_)&&(Wt(_)?_.value=p[b]:((_ instanceof Set||_ instanceof Map)&&_.clear(),xf(_,p[b]))),i.state.value[s][b]=_):typeof _=="function"&&(S[b]=x(_,b),a.actions[b]=_)}return jn(A,S),jn(xt(A),S),Object.defineProperty(A,"$state",{get:()=>i.state.value[s],set:b=>{g(_=>{jn(_,b)})}}),i._p.forEach(b=>{const _=o.run(()=>b({store:A,app:i._a,pinia:i,options:a}));jn(A,_)}),p&&r&&t.hydrate&&t.hydrate(A.$state,p),l=!0,h=!0,A}/*! #__NO_SIDE_EFFECTS__ */function o_(s,e,t){let i;const n=typeof e=="function";i=n?t:e;function r(o,a){const c=fT();return o=o||(c?Uo(yy,null):null),o&&Wh(o),o=xy,o._s.has(s)||(n?by(s,e,i,o):r_(s,i,o)),o._s.get(s)}return r.$id=s,r}var ao=(s=>(s[s.WEBGL_LEGACY=0]="WEBGL_LEGACY",s[s.WEBGL=1]="WEBGL",s[s.WEBGL2=2]="WEBGL2",s))(ao||{}),wy=(s=>(s[s.UNKNOWN=0]="UNKNOWN",s[s.WEBGL=1]="WEBGL",s[s.CANVAS=2]="CANVAS",s))(wy||{}),yf=(s=>(s[s.COLOR=16384]="COLOR",s[s.DEPTH=256]="DEPTH",s[s.STENCIL=1024]="STENCIL",s))(yf||{}),je=(s=>(s[s.NORMAL=0]="NORMAL",s[s.ADD=1]="ADD",s[s.MULTIPLY=2]="MULTIPLY",s[s.SCREEN=3]="SCREEN",s[s.OVERLAY=4]="OVERLAY",s[s.DARKEN=5]="DARKEN",s[s.LIGHTEN=6]="LIGHTEN",s[s.COLOR_DODGE=7]="COLOR_DODGE",s[s.COLOR_BURN=8]="COLOR_BURN",s[s.HARD_LIGHT=9]="HARD_LIGHT",s[s.SOFT_LIGHT=10]="SOFT_LIGHT",s[s.DIFFERENCE=11]="DIFFERENCE",s[s.EXCLUSION=12]="EXCLUSION",s[s.HUE=13]="HUE",s[s.SATURATION=14]="SATURATION",s[s.COLOR=15]="COLOR",s[s.LUMINOSITY=16]="LUMINOSITY",s[s.NORMAL_NPM=17]="NORMAL_NPM",s[s.ADD_NPM=18]="ADD_NPM",s[s.SCREEN_NPM=19]="SCREEN_NPM",s[s.NONE=20]="NONE",s[s.SRC_OVER=0]="SRC_OVER",s[s.SRC_IN=21]="SRC_IN",s[s.SRC_OUT=22]="SRC_OUT",s[s.SRC_ATOP=23]="SRC_ATOP",s[s.DST_OVER=24]="DST_OVER",s[s.DST_IN=25]="DST_IN",s[s.DST_OUT=26]="DST_OUT",s[s.DST_ATOP=27]="DST_ATOP",s[s.ERASE=26]="ERASE",s[s.SUBTRACT=28]="SUBTRACT",s[s.XOR=29]="XOR",s))(je||{}),Qs=(s=>(s[s.POINTS=0]="POINTS",s[s.LINES=1]="LINES",s[s.LINE_LOOP=2]="LINE_LOOP",s[s.LINE_STRIP=3]="LINE_STRIP",s[s.TRIANGLES=4]="TRIANGLES",s[s.TRIANGLE_STRIP=5]="TRIANGLE_STRIP",s[s.TRIANGLE_FAN=6]="TRIANGLE_FAN",s))(Qs||{}),Se=(s=>(s[s.RGBA=6408]="RGBA",s[s.RGB=6407]="RGB",s[s.RG=33319]="RG",s[s.RED=6403]="RED",s[s.RGBA_INTEGER=36249]="RGBA_INTEGER",s[s.RGB_INTEGER=36248]="RGB_INTELine truncated
`)>=0)return!1;return!0}function ni(re,le){var nt;if(re.indent===" ")nt=" ";else if(typeof re.indent=="number"&&re.indent>0)nt=_.call(Array(re.indent+1)," ");else return null;return{base:nt,prev:_.call(Array(le+1),nt)}}function ti(re,le){if(re.length===0)return"";var nt=`
`+le.prev+le.base;return nt+_.call(re,","+nt)+`
`+le.prev}function qt(re,le){var nt=ae(re),Mt=[];if(nt){Mt.length=re.length;for(var ot=0;ot<re.length;ot++)Mt[ot]=se(re,ot)?le(re[ot],re):""}var Ke=typeof k=="function"?k(re):[],_t;if(L){_t={};for(var Oi=0;Oi<Ke.length;Oi++)_t["$"+Ke[Oi]]=Ke[Oi]}for(var Xt in re)se(re,Xt)&&(nt&&String(Number(Xt))===Xt&&Xt<re.length||L&&_t["$"+Xt]instanceof Symbol||(S.call(/[^\w$]/,Xt)?Mt.push(le(Xt,re)+": "+le(re[Xt],re)):Mt.push(Xt+": "+le(re[Xt],re))));if(typeof k=="function")for(var xi=0;xi<Ke.length;xi++)D.call(re,Ke[xi])&&Mt.push("["+le(Ke[xi])+"]: "+le(re[Ke[xi]],re));return Mt}return Ru}var Pu,Eg;function w_(){if(Eg)return Pu;Eg=1;var s=zh(),e=aa(),t=function(a,c,l){for(var h=a,u;(u=h.next)!=null;h=u)if(u.key===c)return h.next=u.next,l||(u.next=a.next,a.next=u),u},i=function(a,c){if(a){var l=t(a,c);return l&&l.value}},n=function(a,c,l){var h=t(a,c);h?h.value=l:a.next={key:c,next:a.next,value:l}},r=function(a,c){return a?!!t(a,c):!1},o=function(a,c){if(a)return t(a,c,!0)};return Pu=function(){var c,l={assert:function(h){if(!l.has(h))throw new e("Side channel does not contain "+s(h))},delete:function(h){var u=o(c,h);return u&&c&&!c.next&&(c=void 0),!!u},get:function(h){return i(c,h)},has:function(h){return r(c,h)},set:function(h,u){c||(c={next:void 0}),n(c,h,u)}};return l},Pu}var ku,Ig;function Ty(){return Ig||(Ig=1,ku=Object),ku}var Fu,Rg;function S_(){return Rg||(Rg=1,Fu=Error),Fu}var Ou,Pg;function T_(){return Pg||(Pg=1,Ou=EvalError),Ou}var Bu,kg;function M_(){return kg||(kg=1,Bu=RangeError),Bu}var Lu,Fg;function __(){return Fg||(Fg=1,Lu=ReferenceError),Lu}var Du,Og;function C_(){return Og||(Og=1,Du=SyntaxError),Du}var Nu,Bg;function A_(){return Bg||(Bg=1,Nu=URIError),Nu}var Uu,Lg;function E_(){return Lg||(Lg=1,Uu=Math.abs),Uu}var $u,Dg;function I_(){return Dg||(Dg=1,$u=Math.floor),$u}var Xu,Ng;function R_(){return Ng||(Ng=1,Xu=Math.max),Xu}var Vu,Ug;function P_(){return Ug||(Ug=1,Vu=Math.min),Vu}var Yu,$g;function k_(){return $g||($g=1,Yu=Math.pow),Yu}var Gu,Xg;function F_(){return Xg||(Xg=1,Gu=Math.round),Gu}var Hu,Vg;function O_(){return Vg||(Vg=1,Hu=Number.isNaN||function(e){return e!==e}),Hu}var ju,Yg;function B_(){if(Yg)return ju;Yg=1;var s=O_();return ju=function(t){return s(t)||t===0?t:t<0?-1:1},ju}var Wu,Gg;function L_(){return Gg||(Gg=1,Wu=Object.getOwnPropertyDescriptor),Wu}var zu,Hg;function My(){if(Hg)return zu;Hg=1;var s=L_();if(s)try{s([],"length")}catch{s=null}return zu=s,zu}var qu,jg;function _y(){if(jg)return qu;jg=1;var s=Object.defineProperty||!1;if(s)try{s({},"a",{value:1})}catch{s=!1}return qu=s,qu}var Ku,Wg;function D_(){return Wg||(Wg=1,Ku=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},t=Symbol("test"),i=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(i)!=="[object Symbol]")return!1;var n=42;e[t]=n;for(var r in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var o=Object.getOwnPropertySymbols(e);if(o.length!==1||o[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var a=Object.getOwnPropertyDescriptor(e,t);if(a.value!==n||a.enumerable!==!0)return!1}return!0}),Ku}var Zu,zg;function N_(){if(zg)return Zu;zg=1;var s=typeof Symbol<"u"&&Symbol,e=D_();return Zu=function(){return typeof s!="function"||typeof Symbol!="function"||typeof s("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:e()},Zu}var Ju,qg;function Cy(){return qg||(qg=1,Ju=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),Ju}var Qu,Kg;function Ay(){if(Kg)return Qu;Kg=1;var s=Ty();return Qu=s.getPrototypeOf||null,Qu}var ed,Zg;function U_(){if(Zg)return ed;Zg=1;var s="Function.prototype.bind called on incompatible ",e=Object.prototype.toString,t=Math.max,i="[object Function]",n=function(c,l){for(var h=[],u=0;u<c.length;u+=1)h[u]=c[u];for(var d=0;d<l.length;d+=1)h[d+c.length]=l[d];return h},r=function(c,l){for(var h=[],u=l,d=0;u<c.length;u+=1,d+=1)h[d]=c[u];return h},o=function(a,c){for(var l="",h=0;h<a.length;h+=1)l+=a[h],h+1<a.length&&(l+=c);return l};return ed=function(c){var l=this;if(typeof l!="function"||e.apply(l)!==i)throw new TypeError(s+l);for(var h=r(arguments,1),u,d=function(){if(this instanceof u){var v=l.apply(this,n(h,arguments));return Object(v)===v?v:this}return l.apply(c,n(h,arguments))},f=t(0,l.length-h.length),p=[],m=0;m<f;m++)p[m]="$"+m;if(u=Function("binder","return function ("+o(p,",")+"){ return binder.apply(this,arguments); }")(d),l.prototype){var g=function(){};g.prototype=l.prototype,u.prototype=new g,g.prototype=null}return u},ed}var td,Jg;function qh(){if(Jg)return td;Jg=1;var s=U_();return td=Function.prototype.bind||s,td}var id,Qg;function zm(){return Qg||(Qg=1,id=Function.prototype.call),id}var sd,e0;function Ey(){return e0||(e0=1,sd=Function.p Line truncated
`," "],o=["{","}","|","\\","^","`"].concat(r),a=["'"].concat(o),c=["%","/","?",";","#"].concat(a),l=["/","?","#"],h=255,u=/^[+a-z0-9A-Z_-]{0,63}$/,d=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,f={javascript:!0,"javascript:":!0},p={javascript:!0,"javascript:":!0},m={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},g=z_();function v(A,S,b){if(A&&typeof A=="object"&&A instanceof e)return A;var _=new e;return _.parse(A,S,b),_}e.prototype.parse=function(A,S,b){if(typeof A!="string")throw new TypeError("Parameter 'url' must be a string, not "+typeof A);var _=A.indexOf("?"),I=_!==-1&&_<A.indexOf("#")?"?":"#",F=A.split(I),E=/\\/g;F[0]=F[0].replace(E,"/"),A=F.join(I);var k=A;if(k=k.trim(),!b&&A.split("#").length===1){var O=n.exec(k);if(O)return this.path=k,this.href=k,this.pathname=O[1],O[2]?(this.search=O[2],S?this.query=g.parse(this.search.substr(1)):this.query=this.search.substr(1)):S&&(this.search="",this.query={}),this}var L=t.exec(k);if(L){L=L[0];var $=L.toLowerCase();this.protocol=$,k=k.substr(L.length)}if(b||L||k.match(/^\/\/[^@/]+@[^@/]+/)){var D=k.substr(0,2)==="//";D&&!(L&&p[L])&&(k=k.substr(2),this.slashes=!0)}if(!p[L]&&(D||L&&!m[L])){for(var U=-1,C=0;C<l.length;C++){var P=k.indexOf(l[C]);P!==-1&&(U===-1||P<U)&&(U=P)}var B,N;U===-1?N=k.lastIndexOf("@"):N=k.lastIndexOf("@",U),N!==-1&&(B=k.slice(0,N),k=k.slice(N+1),this.auth=decodeURIComponent(B)),U=-1;for(var C=0;C<c.length;C++){var P=k.indexOf(c[C]);P!==-1&&(U===-1||P<U)&&(U=P)}U===-1&&(U=k.length),this.host=k.slice(0,U),k=k.slice(U),this.parseHost(),this.hostname=this.hostname||"";var V=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!V)for(var X=this.hostname.split(/\./),C=0,z=X.length;C<z;C++){var W=X[C];if(W&&!W.match(u)){for(var oe="",ae=0,fe=W.length;ae<fe;ae++)W.charCodeAt(ae)>127?oe+="x":oe+=W[ae];if(!oe.match(u)){var ue=X.slice(0,C),ne=X.slice(C+1),me=W.match(d);me&&(ue.push(me[1]),ne.unshift(me[2])),ne.length&&(k="/"+ne.join(".")+k),this.hostname=ue.join(".");break}}}this.hostname.length>h?this.hostname="":this.hostname=this.hostname.toLowerCase(),V||(this.hostname=s.toASCII(this.hostname));var Y=this.port?":"+this.port:"",j=this.hostname||"";this.host=j+Y,this.href+=this.host,V&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),k[0]!=="/"&&(k="/"+k))}if(!f[$])for(var C=0,z=a.length;C<z;C++){var H=a[C];if(k.indexOf(H)!==-1){var G=encodeURIComponent(H);G===H&&(G=escape(H)),k=k.split(H).join(G)}}var q=k.indexOf("#");q!==-1&&(this.hash=k.substr(q),k=k.slice(0,q));var se=k.indexOf("?");if(se!==-1?(this.search=k.substr(se),this.query=k.substr(se+1),S&&(this.query=g.parse(this.query)),k=k.slice(0,se)):S&&(this.search="",this.query={}),k&&(this.pathname=k),m[$]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var Y=this.pathname||"",he=this.search||"";this.path=Y+he}return this.href=this.format(),this};function y(A){return typeof A=="string"&&(A=v(A)),A instanceof e?A.format():e.prototype.format.call(A)}e.prototype.format=function(){var A=this.auth||"";A&&(A=encodeURIComponent(A),A=A.replace(/%3A/i,":"),A+="@");var S=this.protocol||"",b=this.pathname||"",_=this.hash||"",I=!1,F="";this.host?I=A+this.host:this.hostname&&(I=A+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(I+=":"+this.port)),this.query&&typeof this.query=="object"&&Object.keys(this.query).length&&(F=g.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var E=this.search||F&&"?"+F||"";return S&&S.substr(-1)!==":"&&(S+=":"),this.slashes||(!S||m[S])&&I!==!1?(I="//"+(I||""),b&&b.charAt(0)!=="/"&&(b="/"+b)):I||(I=""),_&&_.charAt(0)!=="#"&&(_="#"+_),E&&E.charAt(0)!=="?"&&(E="?"+E),b=b.replace(/[?#]/g,function(k){return encodeURIComponent(k)}),E=E.replace("#","%23"),S+I+b+E+_};function x(A,S){return v(A,!1,!0).resolve(S)}e.prototype.resolve=function(A){return this.resolveObject(v(A,!1,!0)).format()};function T(A,S){return A?v(A,!1,!0).resolveObject(S):S}return e.prototype.resolveObject=function(A){if(typeof A=="string"){var S=new e;S.parse(A,!1,!0),A=S}for(var b=new e,_=Object.keys(this),I=0;I<_.length;I++){var F=_[I];b[F]=this[F]}if(b.hash=A.hash,A.href==="")return b.href=b.format(),b;if(A.slashes&&!A.protocol){for(var E=Object.keys(A),k=0;k<E.length;k++){var O=E[k];O!=="protocol"&&(b[O]=A[O])}return m[b.protocol]&&b.hostname&&!b.pathname&&(b.pathname="/",b.path=b.pathname),b.href=b.format(),b}if(A.protocol&&A.protocol!==b.protocol){if(!m[A.protocol]){for(var L=Object.keys(A),$=0;$<L.length;$++){var D=L[$];b[D]=A[D]}return b.href=b.format(),b}if(b.protocol=A.protocol,!A.host&&!p[A.protocol]){for(var z=(A.pathname||"").split("/");z.length&&!(A.host=z.shift()););A.host||(A.host=""),A.hostname||(A.hostname=""),z[0]!==""&&z.unshift(""),z.length<2&&z.unshift(""),b.pathname=z.join("/")}else b.pathname=A.pathname;if(b.search=A.search,b.query=A.query,b.host=A.host||"",b.auth=A.auth,b.hostname=A.hostname||A.host,b.port=A.port,b.pathname||b.search){var U= Line truncated
*/let by;const Wh=s=>by=s,wy=Symbol();function lg(s){return s&&typeof s=="object"&&Object.prototype.toString.call(s)==="[object Object]"&&typeof s.toJSON!="function"}function i_(){const s=vx(!0),e=s.run(()=>Ye({}));let t=[],i=[];const n=lr({install(r){Wh(n),n._a=r,r.provide(wy,n),r.config.globalProperties.$pinia=n,i.forEach(o=>t.push(o)),i=[]},use(r){return this._a?t.push(r):i.push(r),this},_p:t,_a:null,_e:s,_s:new Map,state:e});return n}const vf=()=>{};function cg(s,e,t,i=vf){s.add(e);const n=()=>{s.delete(e)&&i()};return!t&&xx()&&LS(n),n}function yo(s,...e){s.forEach(t=>{t(...e)})}const s_=s=>s(),hg=Symbol(),_u=Symbol();function xf(s,e){s instanceof Map&&e instanceof Map?e.forEach((t,i)=>s.set(i,t)):s instanceof Set&&e instanceof Set&&e.forEach(s.add,s);for(const t in e){if(!Object.hasOwn(e,t))continue;const i=e[t],n=s[t];lg(n)&&lg(i)&&Object.hasOwn(s,t)&&!zt(i)&&!Bn(i)?s[t]=xf(n,i):s[t]=i}return s}const n_=Symbol();function r_(s){return!s||typeof s!="object"||!Object.hasOwn(s,n_)}const{assign:Kn}=Object;function o_(s){return!!(zt(s)&&s.effect)}function a_(s,e,t,i){const{state:n,actions:r,getters:o}=e,a=t.state.value[s];let c;function l(){a||(t.state.value[s]=n?n():{});const h=rT(t.state.value[s]);return Kn(h,r,Object.keys(o||{}).reduce((u,d)=>(u[d]=lr(qe(()=>{Wh(t);const f=t._s.get(s);return o[d].call(f,f)})),u),{}))}return c=Sy(s,l,e,t,i,!0),c}function Sy(s,e,t={},i,n,r){let o;const a=Kn({actions:{}},t),c={deep:!0};let l,h,u=new Set,d=new Set,f;const p=i.state.value[s];!r&&!p&&(i.state.value[s]={});let m;function g(b){let _;l=h=!1,typeof b=="function"?(b(i.state.value[s]),_={type:"patch function",storeId:s,events:f}):(xf(i.state.value[s],b),_={type:"patch object",payload:b,storeId:s,events:f});const I=m=Symbol();Uh().then(()=>{m===I&&(l=!0)}),h=!0,yo(u,_,i.state.value[s])}const v=r?function(){const{state:_}=t,I=_?_():{};this.$patch(F=>{Kn(F,I)})}:vf;function y(){o.stop(),u.clear(),d.clear(),i._s.delete(s)}const x=(b,_="")=>{if(hg in b)return b[_u]=_,b;const I=function(){Wh(i);const F=Array.from(arguments),E=new Set,k=new Set;function B(L){E.add(L)}function N(L){k.add(L)}yo(d,{args:F,name:I[_u],store:A,after:B,onError:N});let $;try{$=b.apply(this&&this.$id===s?this:A,F)}catch(L){throw yo(k,L),L}return $ instanceof Promise?$.then(L=>(yo(E,L),L)).catch(L=>(yo(k,L),Promise.reject(L))):(yo(E,$),$)};return I[hg]=!0,I[_u]=_,I},T={_p:i,$id:s,$onAction:cg.bind(null,d),$patch:g,$reset:v,$subscribe(b,_={}){if(u.has(b))return vf;const I=cg(u,b,_.detached,()=>F()),F=o.run(()=>Yi(()=>i.state.value[s],E=>{(_.flush==="sync"?h:l)&&b({storeId:s,type:"direct",events:f},E)},Kn({},c,_)));return I},$dispose:y},A=co(T);i._s.set(s,A);const S=(i._a&&i._a.runWithContext||s_)(()=>i._e.run(()=>(o=vx()).run(()=>e({action:x}))));for(const b in S){const _=S[b];zt(_)&&!o_(_)||Bn(_)?r||(p&&r_(_)&&(zt(_)?_.value=p[b]:((_ instanceof Set||_ instanceof Map)&&_.clear(),xf(_,p[b]))),i.state.value[s][b]=_):typeof _=="function"&&(S[b]=x(_,b),a.actions[b]=_)}return Kn(A,S),Kn(yt(A),S),Object.defineProperty(A,"$state",{get:()=>i.state.value[s],set:b=>{g(_=>{Kn(_,b)})}}),i._p.forEach(b=>{const _=o.run(()=>b({store:A,app:i._a,pinia:i,options:a}));Kn(A,_)}),p&&r&&t.hydrate&&t.hydrate(A.$state,p),l=!0,h=!0,A}/*! #__NO_SIDE_EFFECTS__ */function l_(s,e,t){let i;const n=typeof e=="function";i=n?t:e;function r(o,a){const c=pT();return o=o||(c?Xo(wy,null):null),o&&Wh(o),o=by,o._s.has(s)||(n?Sy(s,e,i,o):a_(s,i,o)),o._s.get(s)}return r.$id=s,r}var ho=(s=>(s[s.WEBGL_LEGACY=0]="WEBGL_LEGACY",s[s.WEBGL=1]="WEBGL",s[s.WEBGL2=2]="WEBGL2",s))(ho||{}),Ty=(s=>(s[s.UNKNOWN=0]="UNKNOWN",s[s.WEBGL=1]="WEBGL",s[s.CANVAS=2]="CANVAS",s))(Ty||{}),yf=(s=>(s[s.COLOR=16384]="COLOR",s[s.DEPTH=256]="DEPTH",s[s.STENCIL=1024]="STENCIL",s))(yf||{}),He=(s=>(s[s.NORMAL=0]="NORMAL",s[s.ADD=1]="ADD",s[s.MULTIPLY=2]="MULTIPLY",s[s.SCREEN=3]="SCREEN",s[s.OVERLAY=4]="OVERLAY",s[s.DARKEN=5]="DARKEN",s[s.LIGHTEN=6]="LIGHTEN",s[s.COLOR_DODGE=7]="COLOR_DODGE",s[s.COLOR_BURN=8]="COLOR_BURN",s[s.HARD_LIGHT=9]="HARD_LIGHT",s[s.SOFT_LIGHT=10]="SOFT_LIGHT",s[s.DIFFERENCE=11]="DIFFERENCE",s[s.EXCLUSION=12]="EXCLUSION",s[s.HUE=13]="HUE",s[s.SATURATION=14]="SATURATION",s[s.COLOR=15]="COLOR",s[s.LUMINOSITY=16]="LUMINOSITY",s[s.NORMAL_NPM=17]="NORMAL_NPM",s[s.ADD_NPM=18]="ADD_NPM",s[s.SCREEN_NPM=19]="SCREEN_NPM",s[s.NONE=20]="NONE",s[s.SRC_OVER=0]="SRC_OVER",s[s.SRC_IN=21]="SRC_IN",s[s.SRC_OUT=22]="SRC_OUT",s[s.SRC_ATOP=23]="SRC_ATOP",s[s.DST_OVER=24]="DST_OVER",s[s.DST_IN=25]="DST_IN",s[s.DST_OUT=26]="DST_OUT",s[s.DST_ATOP=27]="DST_ATOP",s[s.ERASE=26]="ERASE",s[s.SUBTRACT=28]="SUBTRACT",s[s.XOR=29]="XOR",s))(He||{}),sn=(s=>(s[s.POINTS=0]="POINTS",s[s.LINES=1]="LINES",s[s.LINE_LOOP=2]="LINE_LOOP",s[s.LINE_STRIP=3]="LINE_STRIP",s[s.TRIANGLES=4]="TRIANGLES",s[s.TRIANGLE_STRIP=5]="TRIANGLE_STRIP",s[s.TRIANGLE_FAN=6]="TRIANGLE_FAN",s))(sn||{}),Se=(s=>(s[s.RGBA=6408]="RGBA",s[s.RGB=6407]="RGB",s[s.RG=33319]="RG",s[s.RED=6403]="RED",s[s.RGBA_INTEGER=36249]="RGBA_INTEGER",s[s.RGB_INTEGER=36248]="RGB_INTELine truncated
`)>=0)return!1;return!0}function mi(ie,oe){var lt;if(ie.indent===" ")lt=" ";else if(typeof ie.indent=="number"&&ie.indent>0)lt=_.call(Array(ie.indent+1)," ");else return null;return{base:lt,prev:_.call(Array(oe+1),lt)}}function Rt(ie,oe){if(ie.length===0)return"";var lt=`
`+oe.prev+oe.base;return lt+_.call(ie,","+lt)+`
`+oe.prev}function vt(ie,oe){var lt=re(ie),_t=[];if(lt){_t.length=ie.length;for(var Ct=0;Ct<ie.length;Ct++)_t[Ct]=te(ie,Ct)?oe(ie[Ct],ie):""}var et=typeof k=="function"?k(ie):[],rs;if(N){rs={};for(var ni=0;ni<et.length;ni++)rs["$"+et[ni]]=et[ni]}for(var Kt in ie)te(ie,Kt)&&(lt&&String(Number(Kt))===Kt&&Kt<ie.length||N&&rs["$"+Kt]instanceof Symbol||(S.call(/[^\w$]/,Kt)?_t.push(oe(Kt,ie)+": "+oe(ie[Kt],ie)):_t.push(Kt+": "+oe(ie[Kt],ie))));if(typeof k=="function")for(var At=0;At<et.length;At++)L.call(ie,et[At])&&_t.push("["+oe(et[At])+"]: "+oe(ie[et[At]],ie));return _t}return Ru}var Pu,Eg;function T_(){if(Eg)return Pu;Eg=1;var s=zh(),e=ca(),t=function(a,c,l){for(var h=a,u;(u=h.next)!=null;h=u)if(u.key===c)return h.next=u.next,l||(u.next=a.next,a.next=u),u},i=function(a,c){if(a){var l=t(a,c);return l&&l.value}},n=function(a,c,l){var h=t(a,c);h?h.value=l:a.next={key:c,next:a.next,value:l}},r=function(a,c){return a?!!t(a,c):!1},o=function(a,c){if(a)return t(a,c,!0)};return Pu=function(){var c,l={assert:function(h){if(!l.has(h))throw new e("Side channel does not contain "+s(h))},delete:function(h){var u=o(c,h);return u&&c&&!c.next&&(c=void 0),!!u},get:function(h){return i(c,h)},has:function(h){return r(c,h)},set:function(h,u){c||(c={next:void 0}),n(c,h,u)}};return l},Pu}var ku,Ig;function _y(){return Ig||(Ig=1,ku=Object),ku}var Fu,Rg;function M_(){return Rg||(Rg=1,Fu=Error),Fu}var Ou,Pg;function __(){return Pg||(Pg=1,Ou=EvalError),Ou}var Bu,kg;function C_(){return kg||(kg=1,Bu=RangeError),Bu}var Lu,Fg;function A_(){return Fg||(Fg=1,Lu=ReferenceError),Lu}var Du,Og;function E_(){return Og||(Og=1,Du=SyntaxError),Du}var Nu,Bg;function I_(){return Bg||(Bg=1,Nu=URIError),Nu}var Uu,Lg;function R_(){return Lg||(Lg=1,Uu=Math.abs),Uu}var $u,Dg;function P_(){return Dg||(Dg=1,$u=Math.floor),$u}var Xu,Ng;function k_(){return Ng||(Ng=1,Xu=Math.max),Xu}var Vu,Ug;function F_(){return Ug||(Ug=1,Vu=Math.min),Vu}var Yu,$g;function O_(){return $g||($g=1,Yu=Math.pow),Yu}var Gu,Xg;function B_(){return Xg||(Xg=1,Gu=Math.round),Gu}var Hu,Vg;function L_(){return Vg||(Vg=1,Hu=Number.isNaN||function(e){return e!==e}),Hu}var ju,Yg;function D_(){if(Yg)return ju;Yg=1;var s=L_();return ju=function(t){return s(t)||t===0?t:t<0?-1:1},ju}var Wu,Gg;function N_(){return Gg||(Gg=1,Wu=Object.getOwnPropertyDescriptor),Wu}var zu,Hg;function Cy(){if(Hg)return zu;Hg=1;var s=N_();if(s)try{s([],"length")}catch{s=null}return zu=s,zu}var qu,jg;function Ay(){if(jg)return qu;jg=1;var s=Object.defineProperty||!1;if(s)try{s({},"a",{value:1})}catch{s=!1}return qu=s,qu}var Ku,Wg;function U_(){return Wg||(Wg=1,Ku=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},t=Symbol("test"),i=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(i)!=="[object Symbol]")return!1;var n=42;e[t]=n;for(var r in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var o=Object.getOwnPropertySymbols(e);if(o.length!==1||o[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var a=Object.getOwnPropertyDescriptor(e,t);if(a.value!==n||a.enumerable!==!0)return!1}return!0}),Ku}var Zu,zg;function $_(){if(zg)return Zu;zg=1;var s=typeof Symbol<"u"&&Symbol,e=U_();return Zu=function(){return typeof s!="function"||typeof Symbol!="function"||typeof s("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:e()},Zu}var Ju,qg;function Ey(){return qg||(qg=1,Ju=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),Ju}var Qu,Kg;function Iy(){if(Kg)return Qu;Kg=1;var s=_y();return Qu=s.getPrototypeOf||null,Qu}var ed,Zg;function X_(){if(Zg)return ed;Zg=1;var s="Function.prototype.bind called on incompatible ",e=Object.prototype.toString,t=Math.max,i="[object Function]",n=function(c,l){for(var h=[],u=0;u<c.length;u+=1)h[u]=c[u];for(var d=0;d<l.length;d+=1)h[d+c.length]=l[d];return h},r=function(c,l){for(var h=[],u=l,d=0;u<c.length;u+=1,d+=1)h[d]=c[u];return h},o=function(a,c){for(var l="",h=0;h<a.length;h+=1)l+=a[h],h+1<a.length&&(l+=c);return l};return ed=function(c){var l=this;if(typeof l!="function"||e.apply(l)!==i)throw new TypeError(s+l);for(var h=r(arguments,1),u,d=function(){if(this instanceof u){var v=l.apply(this,n(h,arguments));return Object(v)===v?v:this}return l.apply(c,n(h,arguments))},f=t(0,l.length-h.length),p=[],m=0;m<f;m++)p[m]="$"+m;if(u=Function("binder","return function ("+o(p,",")+"){ return binder.apply(this,arguments); }")(d),l.prototype){var g=function(){};g.prototype=l.prototype,u.prototype=new g,g.prototype=null}return u},ed}var td,Jg;function qh(){if(Jg)return td;Jg=1;var s=X_();return td=Function.prototype.bind||s,td}var id,Qg;function zm(){return Qg||(Qg=1,id=Function.prototype.call),id}var sd,e0;function Ry(){return e0||(e0=1,sd=Function.p Line truncated
`," "],o=["{","}","|","\\","^","`"].concat(r),a=["'"].concat(o),c=["%","/","?",";","#"].concat(a),l=["/","?","#"],h=255,u=/^[+a-z0-9A-Z_-]{0,63}$/,d=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,f={javascript:!0,"javascript:":!0},p={javascript:!0,"javascript:":!0},m={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},g=K_();function v(A,S,b){if(A&&typeof A=="object"&&A instanceof e)return A;var _=new e;return _.parse(A,S,b),_}e.prototype.parse=function(A,S,b){if(typeof A!="string")throw new TypeError("Parameter 'url' must be a string, not "+typeof A);var _=A.indexOf("?"),I=_!==-1&&_<A.indexOf("#")?"?":"#",F=A.split(I),E=/\\/g;F[0]=F[0].replace(E,"/"),A=F.join(I);var k=A;if(k=k.trim(),!b&&A.split("#").length===1){var B=n.exec(k);if(B)return this.path=k,this.href=k,this.pathname=B[1],B[2]?(this.search=B[2],S?this.query=g.parse(this.search.substr(1)):this.query=this.search.substr(1)):S&&(this.search="",this.query={}),this}var N=t.exec(k);if(N){N=N[0];var $=N.toLowerCase();this.protocol=$,k=k.substr(N.length)}if(b||N||k.match(/^\/\/[^@/]+@[^@/]+/)){var L=k.substr(0,2)==="//";L&&!(N&&p[N])&&(k=k.substr(2),this.slashes=!0)}if(!p[N]&&(L||N&&!m[N])){for(var U=-1,C=0;C<l.length;C++){var P=k.indexOf(l[C]);P!==-1&&(U===-1||P<U)&&(U=P)}var O,D;U===-1?D=k.lastIndexOf("@"):D=k.lastIndexOf("@",U),D!==-1&&(O=k.slice(0,D),k=k.slice(D+1),this.auth=decodeURIComponent(O)),U=-1;for(var C=0;C<c.length;C++){var P=k.indexOf(c[C]);P!==-1&&(U===-1||P<U)&&(U=P)}U===-1&&(U=k.length),this.host=k.slice(0,U),k=k.slice(U),this.parseHost(),this.hostname=this.hostname||"";var V=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!V)for(var Y=this.hostname.split(/\./),C=0,W=Y.length;C<W;C++){var q=Y[C];if(q&&!q.match(u)){for(var ne="",re=0,me=q.length;re<me;re++)q.charCodeAt(re)>127?ne+="x":ne+=q[re];if(!ne.match(u)){var ve=Y.slice(0,C),ce=Y.slice(C+1),de=q.match(d);de&&(ve.push(de[1]),ce.unshift(de[2])),ce.length&&(k="/"+ce.join(".")+k),this.hostname=ve.join(".");break}}}this.hostname.length>h?this.hostname="":this.hostname=this.hostname.toLowerCase(),V||(this.hostname=s.toASCII(this.hostname));var X=this.port?":"+this.port:"",j=this.hostname||"";this.host=j+X,this.href+=this.host,V&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),k[0]!=="/"&&(k="/"+k))}if(!f[$])for(var C=0,W=a.length;C<W;C++){var H=a[C];if(k.indexOf(H)!==-1){var G=encodeURIComponent(H);G===H&&(G=escape(H)),k=k.split(H).join(G)}}var z=k.indexOf("#");z!==-1&&(this.hash=k.substr(z),k=k.slice(0,z));var te=k.indexOf("?");if(te!==-1?(this.search=k.substr(te),this.query=k.substr(te+1),S&&(this.query=g.parse(this.query)),k=k.slice(0,te)):S&&(this.search="",this.query={}),k&&(this.pathname=k),m[$]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var X=this.pathname||"",he=this.search||"";this.path=X+he}return this.href=this.format(),this};function y(A){return typeof A=="string"&&(A=v(A)),A instanceof e?A.format():e.prototype.format.call(A)}e.prototype.format=function(){var A=this.auth||"";A&&(A=encodeURIComponent(A),A=A.replace(/%3A/i,":"),A+="@");var S=this.protocol||"",b=this.pathname||"",_=this.hash||"",I=!1,F="";this.host?I=A+this.host:this.hostname&&(I=A+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(I+=":"+this.port)),this.query&&typeof this.query=="object"&&Object.keys(this.query).length&&(F=g.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var E=this.search||F&&"?"+F||"";return S&&S.substr(-1)!==":"&&(S+=":"),this.slashes||(!S||m[S])&&I!==!1?(I="//"+(I||""),b&&b.charAt(0)!=="/"&&(b="/"+b)):I||(I=""),_&&_.charAt(0)!=="#"&&(_="#"+_),E&&E.charAt(0)!=="?"&&(E="?"+E),b=b.replace(/[?#]/g,function(k){return encodeURIComponent(k)}),E=E.replace("#","%23"),S+I+b+E+_};function x(A,S){return v(A,!1,!0).resolve(S)}e.prototype.resolve=function(A){return this.resolveObject(v(A,!1,!0)).format()};function T(A,S){return A?v(A,!1,!0).resolveObject(S):S}return e.prototype.resolveObject=function(A){if(typeof A=="string"){var S=new e;S.parse(A,!1,!0),A=S}for(var b=new e,_=Object.keys(this),I=0;I<_.length;I++){var F=_[I];b[F]=this[F]}if(b.hash=A.hash,A.href==="")return b.href=b.format(),b;if(A.slashes&&!A.protocol){for(var E=Object.keys(A),k=0;k<E.length;k++){var B=E[k];B!=="protocol"&&(b[B]=A[B])}return m[b.protocol]&&b.hostname&&!b.pathname&&(b.pathname="/",b.path=b.pathname),b.href=b.format(),b}if(A.protocol&&A.protocol!==b.protocol){if(!m[A.protocol]){for(var N=Object.keys(A),$=0;$<N.length;$++){var L=N[$];b[L]=A[L]}return b.href=b.format(),b}if(b.protocol=A.protocol,!A.host&&!p[A.protocol]){for(var W=(A.pathname||"").split("/");W.length&&!(A.host=W.shift()););A.host||(A.host=""),A.hostname||(A.hostname=""),W[0]!==""&&W.unshift(""),W.length<2&&W.unshift(""),b.pathname=W.join("/")}else b.pathname=A.pathname;if(b.search=A.search,b.query=A.query,b.host=A.host||"",b.auth=A.auth,b.hostname=A.hostname||A.host,b.port=A.port,b.pathname||b.search){var U= Line truncated
Deprecated since v${s}`):(i=i.split(`
`).splice(t).join(`
`),console.groupCollapsed?(console.groupCollapsed("%cPixiJS Deprecation Warning: %c%s","color:#614108;background:#fffbe6","font-weight:normal;color:#614108;background:#fffbe6",`${e}
Deprecated since v${s}`),console.warn(i),console.groupEnd()):(console.warn("PixiJS Deprecation Warning: ",`${e}
Deprecated since v${s}`),console.warn(i))),x0[e]=!0}function vs(s){if(typeof s!="string")throw new TypeError(`Path must be a string. Received ${JSON.stringify(s)}`)}function ba(s){return s.split("?")[0].split("#")[0]}function K_(s){return s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Z_(s,e,t){return s.replace(new RegExp(K_(e),"g"),t)}function J_(s,e){let t="",i=0,n=-1,r=0,o=-1;for(let a=0;a<=s.length;++a){if(a<s.length)o=s.charCodeAt(a);else{if(o===47)break;o=47}if(o===47){if(!(n===a-1||r===1))if(n!==a-1&&r===2){if(t.length<2||i!==2||t.charCodeAt(t.length-1)!==46||t.charCodeAt(t.length-2)!==46){if(t.length>2){const c=t.lastIndexOf("/");if(c!==t.length-1){c===-1?(t="",i=0):(t=t.slice(0,c),i=t.length-1-t.lastIndexOf("/")),n=a,r=0;continue}}else if(t.length===2||t.length===1){t="",i=0,n=a,r=0;continue}}}else t.length>0?t+=`/${s.slice(n+1,a)}`:t=s.slice(n+1,a),i=a-n-1;n=a,r=0}else o===46&&r!==-1?++r:r=-1}return t}const Jt={toPosix(s){return Z_(s,"\\","/")},isUrl(s){return/^https?:/.test(this.toPosix(s))},isDataUrl(s){return/^data:([a-z]+\/[a-z0-9-+.]+(;[a-z0-9-.!#$%*+.{}|~`]+=[a-z0-9-.!#$%*+.{}()_|~`]+)*)?(;base64)?,([a-z0-9!$&',()*+;=\-._~:@\/?%\s<>]*?)$/i.test(s)},isBlobUrl(s){return s.startsWith("blob:")},hasProtocol(s){return/^[^/:]+:/.test(this.toPosix(s))},getProtocol(s){vs(s),s=this.toPosix(s);const e=/^file:\/\/\//.exec(s);if(e)return e[0];const t=/^[^/:]+:\/{0,2}/.exec(s);return t?t[0]:""},toAbsolute(s,e,t){if(vs(s),this.isDataUrl(s)||this.isBlobUrl(s))return s;const i=ba(this.toPosix(e??ke.ADAPTER.getBaseUrl())),n=ba(this.toPosix(t??this.rootname(i)));return s=this.toPosix(s),s.startsWith("/")?Jt.join(n,s.slice(1)):this.isAbsolute(s)?s:this.join(i,s)},normalize(s){if(vs(s),s.length===0)return".";if(this.isDataUrl(s)||this.isBlobUrl(s))return s;s=this.toPosix(s);let e="";const t=s.startsWith("/");this.hasProtocol(s)&&(e=this.rootname(s),s=s.slice(e.length));const i=s.endsWith("/");return s=J_(s),s.length>0&&i&&(s+="/"),t?`/${s}`:e+s},isAbsolute(s){return vs(s),s=this.toPosix(s),this.hasProtocol(s)?!0:s.startsWith("/")},join(...s){if(s.length===0)return".";let e;for(let t=0;t<s.length;++t){const i=s[t];if(vs(i),i.length>0)if(e===void 0)e=i;else{const n=s[t-1]??"";this.joinExtensions.includes(this.extname(n).toLowerCase())?e+=`/../${i}`:e+=`/${i}`}}return e===void 0?".":this.normalize(e)},dirname(s){if(vs(s),s.length===0)return".";s=this.toPosix(s);let e=s.charCodeAt(0);const t=e===47;let i=-1,n=!0;const r=this.getProtocol(s),o=s;s=s.slice(r.length);for(let a=s.length-1;a>=1;--a)if(e=s.charCodeAt(a),e===47){if(!n){i=a;break}}else n=!1;return i===-1?t?"/":this.isUrl(o)?r+s:r:t&&i===1?"//":r+s.slice(0,i)},rootname(s){vs(s),s=this.toPosix(s);let e="";if(s.startsWith("/")?e="/":e=this.getProtocol(s),this.isUrl(s)){const t=s.indexOf("/",e.length);t!==-1?e=s.slice(0,t):e=s,e.endsWith("/")||(e+="/")}return e},basename(s,e){vs(s),e&&vs(e),s=ba(this.toPosix(s));let t=0,i=-1,n=!0,r;if(e!==void 0&&e.length>0&&e.length<=s.length){if(e.length===s.length&&e===s)return"";let o=e.length-1,a=-1;for(r=s.length-1;r>=0;--r){const c=s.charCodeAt(r);if(c===47){if(!n){t=r+1;break}}else a===-1&&(n=!1,a=r+1),o>=0&&(c===e.charCodeAt(o)?--o===-1&&(i=r):(o=-1,i=a))}return t===i?i=a:i===-1&&(i=s.length),s.slice(t,i)}for(r=s.length-1;r>=0;--r)if(s.charCodeAt(r)===47){if(!n){t=r+1;break}}else i===-1&&(n=!1,i=r+1);return i===-1?"":s.slice(t,i)},extname(s){vs(s),s=ba(this.toPosix(s));let e=-1,t=0,i=-1,n=!0,r=0;for(let o=s.length-1;o>=0;--o){const a=s.charCodeAt(o);if(a===47){if(!n){t=o+1;break}continue}i===-1&&(n=!1,i=o+1),a===46?e===-1?e=o:r!==1&&(r=1):e!==-1&&(r=-1)}return e===-1||i===-1||r===0||r===1&&e===i-1&&e===t+1?"":s.slice(e,i)},parse(s){vs(s);const e={root:"",dir:"",base:"",ext:"",name:""};if(s.length===0)return e;s=ba(this.toPosix(s));let t=s.charCodeAt(0);const i=this.isAbsolute(s);let n;e.root=this.rootname(s),i||this.hasProtocol(s)?n=1:n=0;let r=-1,o=0,a=-1,c=!0,l=s.length-1,h=0;for(;l>=n;--l){if(t=s.charCodeAt(l),t===47){if(!c){o=l+1;break}continue}a===-1&&(c=!1,a=l+1),t===46?r===-1?r=l:h!==1&&(h=1):r!==-1&&(h=-1)}return r===-1||a===-1||h===0||h===1&&r===a-1&&r===o+1?a!==-1&&(o===0&&i?e.base=e.name=s.slice(1,a):e.base=e.name=s.slice(o,a)):(o===0&&i?(e.name=s.slice(1,r),e.base=s.slice(1,a)):(e.name=s.slice(o,r),e.base=s.slice(o,a)),e.ext=s.slice(r,a)),e.dir=this.dirname(s),e},sep:"/",delimiter:":",joinExtensions:[".html"]};let bd;async function Q_(){return bd??(bd=(async()=>{var r;const s=document.createElement("canvas").getContext("webgl");if(!s)return vi.UNPACK;const e=await new Promise(o=>{const a=document.createElement("video");a.onloadeddata=()=>o(a),a.onerror=()=>o(null),a.autoplay=!1,a.crossOrigin="anonymous",a.preload="auto",a.src="data:video/webm;base64,GkXfo59ChoEBQveBAULygQRC84EIQoKEd2VibUKHgQJChYECGFOAZwEAAAAAAAHTEU2bdLpNu4tTq4QVSalmU6yBoU27i1OrhBZUrmtTrIHGTbuMU6uEElTDZ1OsggEXTbuMU6uEHFO7a1OsggG97AEAAAAAAABZAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA Line truncated
`);function bC(s){let e="";for(let t=0;t<s;++t)t>0&&(e+=`
else `),t<s-1&&(e+=`if(test == ${t}.0){}`);return e}function wC(s,e){if(s===0)throw new Error("Invalid value of `0` passed to `checkMaxIfStatementsInShader`");const t=e.createShader(e.FRAGMENT_SHADER);for(;;){const i=yC.replace(/%forloop%/gi,bC(s));if(e.shaderSource(t,i),e.compileShader(t),!e.getShaderParameter(t,e.COMPILE_STATUS))s=s/2|0;else break}return s}const _d=0,Cd=1,Ad=2,Ed=3,Id=4,Rd=5;class ln{constructor(){this.data=0,this.blendMode=je.NORMAL,this.polygonOffset=0,this.blend=!0,this.depthMask=!0}get blend(){return!!(this.data&1<<_d)}set blend(e){!!(this.data&1<<_d)!==e&&(this.data^=1<<_d)}get offsets(){return!!(this.data&1<<Cd)}set offsets(e){!!(this.data&1<<Cd)!==e&&(this.data^=1<<Cd)}get culling(){return!!(this.data&1<<Ad)}set culling(e){!!(this.data&1<<Ad)!==e&&(this.data^=1<<Ad)}get depthTest(){return!!(this.data&1<<Ed)}set depthTest(e){!!(this.data&1<<Ed)!==e&&(this.data^=1<<Ed)}get depthMask(){return!!(this.data&1<<Rd)}set depthMask(e){!!(this.data&1<<Rd)!==e&&(this.data^=1<<Rd)}get clockwiseFrontFace(){return!!(this.data&1<<Id)}set clockwiseFrontFace(e){!!(this.data&1<<Id)!==e&&(this.data^=1<<Id)}get blendMode(){return this._blendMode}set blendMode(e){this.blend=e!==je.NONE,this._blendMode=e}get polygonOffset(){return this._polygonOffset}set polygonOffset(e){this.offsets=!!e,this._polygonOffset=e}static for2d(){const e=new ln;return e.depthTest=!1,e.blend=!0,e}}ln.prototype.toString=function(){return`[@pixi/core:State blendMode=${this.blendMode} clockwiseFrontFace=${this.clockwiseFrontFace} culling=${this.culling} depthMask=${this.depthMask} polygonOffset=${this.polygonOffset}]`};const _f=[];function $y(s,e){if(!s)return null;let t="";if(typeof s=="string"){const i=/\.(\w{3,4})(?:$|\?|#)/i.exec(s);i&&(t=i[1].toLowerCase())}for(let i=_f.length-1;i>=0;--i){const n=_f[i];if(n.test&&n.test(s,t))return new n(s,e)}throw new Error("Unrecognized source type to auto-detect Resource")}class Is{constructor(e){this.items=[],this._name=e,this._aliasCount=0}emit(e,t,i,n,r,o,a,c){if(arguments.length>8)throw new Error("max arguments reached");const{name:l,items:h}=this;this._aliasCount++;for(let u=0,d=h.length;u<d;u++)h[u][l](e,t,i,n,r,o,a,c);return h===this.items&&this._aliasCount--,this}ensureNonAliasedItems(){this._aliasCount>0&&this.items.length>1&&(this._aliasCount=0,this.items=this.items.slice(0))}add(e){return e[this._name]&&(this.ensureNonAliasedItems(),this.remove(e),this.items.push(e)),this}remove(e){const t=this.items.indexOf(e);return t!==-1&&(this.ensureNonAliasedItems(),this.items.splice(t,1)),this}contains(e){return this.items.includes(e)}removeAll(){return this.ensureNonAliasedItems(),this.items.length=0,this}destroy(){this.removeAll(),this.items.length=0,this._name=""}get empty(){return this.items.length===0}get name(){return this._name}}Object.defineProperties(Is.prototype,{dispatch:{value:Is.prototype.emit},run:{value:Is.prototype.emit}});class al{constructor(e=0,t=0){this._width=e,this._height=t,this.destroyed=!1,this.internal=!1,this.onResize=new Is("setRealSize"),this.onUpdate=new Is("update"),this.onError=new Is("onError")}bind(e){this.onResize.add(e),this.onUpdate.add(e),this.onError.add(e),(this._width||this._height)&&this.onResize.emit(this._width,this._height)}unbind(e){this.onResize.remove(e),this.onUpdate.remove(e),this.onError.remove(e)}resize(e,t){(e!==this._width||t!==this._height)&&(this._width=e,this._height=t,this.onResize.emit(e,t))}get valid(){return!!this._width&&!!this._height}update(){this.destroyed||this.onUpdate.emit()}load(){return Promise.resolve(this)}get width(){return this._width}get height(){return this._height}style(e,t,i){return!1}dispose(){}destroy(){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)}static test(e,t){return!1}}class Kh extends al{constructor(e,t){const{width:i,height:n}=t||{};if(!i||!n)throw new Error("BufferResource width or height invalid");super(i,n),this.data=e,this.unpackAlignment=t.unpackAlignment??4}upload(e,t,i){const n=e.gl;n.pixelStorei(n.UNPACK_ALIGNMENT,this.unpackAlignment),n.pixelStorei(n.UNPACK_PREMULTIPLY_ALPHA_WEBGL,t.alphaMode===vi.UNPACK);const r=t.realWidth,o=t.realHeight;return i.width===r&&i.height===o?n.texSubImage2D(t.target,0,0,0,r,o,t.format,i.type,this.data):(i.width=r,i.height=o,n.texImage2D(t.target,0,i.internalFormat,r,o,0,t.format,i.type,this.data)),!0}dispose(){this.data=null}static test(e){return e===null||e instanceof Int8Array||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Float32Array}}const SC={scaleMode:_s.NEAREST,alphaMode:vi.NPM},Cf=class Ao extends yl{constructor(e=null,t=null){super(),t=Object.assign({},Ao.defaultOptions,t);const{alphaMode:i,mipmap:n,anisotropicLevel:r,scaleMode:o,width:a,height:c,wrapMode:l,format:h,type:u,target:d,resolution: Line truncated
Deprecated since v${s}`),console.warn(i))),x0[e]=!0}function xs(s){if(typeof s!="string")throw new TypeError(`Path must be a string. Received ${JSON.stringify(s)}`)}function wa(s){return s.split("?")[0].split("#")[0]}function J_(s){return s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Q_(s,e,t){return s.replace(new RegExp(J_(e),"g"),t)}function eC(s,e){let t="",i=0,n=-1,r=0,o=-1;for(let a=0;a<=s.length;++a){if(a<s.length)o=s.charCodeAt(a);else{if(o===47)break;o=47}if(o===47){if(!(n===a-1||r===1))if(n!==a-1&&r===2){if(t.length<2||i!==2||t.charCodeAt(t.length-1)!==46||t.charCodeAt(t.length-2)!==46){if(t.length>2){const c=t.lastIndexOf("/");if(c!==t.length-1){c===-1?(t="",i=0):(t=t.slice(0,c),i=t.length-1-t.lastIndexOf("/")),n=a,r=0;continue}}else if(t.length===2||t.length===1){t="",i=0,n=a,r=0;continue}}}else t.length>0?t+=`/${s.slice(n+1,a)}`:t=s.slice(n+1,a),i=a-n-1;n=a,r=0}else o===46&&r!==-1?++r:r=-1}return t}const Qt={toPosix(s){return Q_(s,"\\","/")},isUrl(s){return/^https?:/.test(this.toPosix(s))},isDataUrl(s){return/^data:([a-z]+\/[a-z0-9-+.]+(;[a-z0-9-.!#$%*+.{}|~`]+=[a-z0-9-.!#$%*+.{}()_|~`]+)*)?(;base64)?,([a-z0-9!$&',()*+;=\-._~:@\/?%\s<>]*?)$/i.test(s)},isBlobUrl(s){return s.startsWith("blob:")},hasProtocol(s){return/^[^/:]+:/.test(this.toPosix(s))},getProtocol(s){xs(s),s=this.toPosix(s);const e=/^file:\/\/\//.exec(s);if(e)return e[0];const t=/^[^/:]+:\/{0,2}/.exec(s);return t?t[0]:""},toAbsolute(s,e,t){if(xs(s),this.isDataUrl(s)||this.isBlobUrl(s))return s;const i=wa(this.toPosix(e??ke.ADAPTER.getBaseUrl())),n=wa(this.toPosix(t??this.rootname(i)));return s=this.toPosix(s),s.startsWith("/")?Qt.join(n,s.slice(1)):this.isAbsolute(s)?s:this.join(i,s)},normalize(s){if(xs(s),s.length===0)return".";if(this.isDataUrl(s)||this.isBlobUrl(s))return s;s=this.toPosix(s);let e="";const t=s.startsWith("/");this.hasProtocol(s)&&(e=this.rootname(s),s=s.slice(e.length));const i=s.endsWith("/");return s=eC(s),s.length>0&&i&&(s+="/"),t?`/${s}`:e+s},isAbsolute(s){return xs(s),s=this.toPosix(s),this.hasProtocol(s)?!0:s.startsWith("/")},join(...s){if(s.length===0)return".";let e;for(let t=0;t<s.length;++t){const i=s[t];if(xs(i),i.length>0)if(e===void 0)e=i;else{const n=s[t-1]??"";this.joinExtensions.includes(this.extname(n).toLowerCase())?e+=`/../${i}`:e+=`/${i}`}}return e===void 0?".":this.normalize(e)},dirname(s){if(xs(s),s.length===0)return".";s=this.toPosix(s);let e=s.charCodeAt(0);const t=e===47;let i=-1,n=!0;const r=this.getProtocol(s),o=s;s=s.slice(r.length);for(let a=s.length-1;a>=1;--a)if(e=s.charCodeAt(a),e===47){if(!n){i=a;break}}else n=!1;return i===-1?t?"/":this.isUrl(o)?r+s:r:t&&i===1?"//":r+s.slice(0,i)},rootname(s){xs(s),s=this.toPosix(s);let e="";if(s.startsWith("/")?e="/":e=this.getProtocol(s),this.isUrl(s)){const t=s.indexOf("/",e.length);t!==-1?e=s.slice(0,t):e=s,e.endsWith("/")||(e+="/")}return e},basename(s,e){xs(s),e&&xs(e),s=wa(this.toPosix(s));let t=0,i=-1,n=!0,r;if(e!==void 0&&e.length>0&&e.length<=s.length){if(e.length===s.length&&e===s)return"";let o=e.length-1,a=-1;for(r=s.length-1;r>=0;--r){const c=s.charCodeAt(r);if(c===47){if(!n){t=r+1;break}}else a===-1&&(n=!1,a=r+1),o>=0&&(c===e.charCodeAt(o)?--o===-1&&(i=r):(o=-1,i=a))}return t===i?i=a:i===-1&&(i=s.length),s.slice(t,i)}for(r=s.length-1;r>=0;--r)if(s.charCodeAt(r)===47){if(!n){t=r+1;break}}else i===-1&&(n=!1,i=r+1);return i===-1?"":s.slice(t,i)},extname(s){xs(s),s=wa(this.toPosix(s));let e=-1,t=0,i=-1,n=!0,r=0;for(let o=s.length-1;o>=0;--o){const a=s.charCodeAt(o);if(a===47){if(!n){t=o+1;break}continue}i===-1&&(n=!1,i=o+1),a===46?e===-1?e=o:r!==1&&(r=1):e!==-1&&(r=-1)}return e===-1||i===-1||r===0||r===1&&e===i-1&&e===t+1?"":s.slice(e,i)},parse(s){xs(s);const e={root:"",dir:"",base:"",ext:"",name:""};if(s.length===0)return e;s=wa(this.toPosix(s));let t=s.charCodeAt(0);const i=this.isAbsolute(s);let n;e.root=this.rootname(s),i||this.hasProtocol(s)?n=1:n=0;let r=-1,o=0,a=-1,c=!0,l=s.length-1,h=0;for(;l>=n;--l){if(t=s.charCodeAt(l),t===47){if(!c){o=l+1;break}continue}a===-1&&(c=!1,a=l+1),t===46?r===-1?r=l:h!==1&&(h=1):r!==-1&&(h=-1)}return r===-1||a===-1||h===0||h===1&&r===a-1&&r===o+1?a!==-1&&(o===0&&i?e.base=e.name=s.slice(1,a):e.base=e.name=s.slice(o,a)):(o===0&&i?(e.name=s.slice(1,r),e.base=s.slice(1,a)):(e.name=s.slice(o,r),e.base=s.slice(o,a)),e.ext=s.slice(r,a)),e.dir=this.dirname(s),e},sep:"/",delimiter:":",joinExtensions:[".html"]};let bd;async function tC(){return bd??(bd=(async()=>{var r;const s=document.createElement("canvas").getContext("webgl");if(!s)return xi.UNPACK;const e=await new Promise(o=>{const a=document.createElement("video");a.onloadeddata=()=>o(a),a.onerror=()=>o(null),a.autoplay=!1,a.crossOrigin="anonymous",a.preload="auto",a.src="data:video/webm;base64,GkXfo59ChoEBQveBAULygQRC84EIQoKEd2VibUKHgQJChYECGFOAZwEAAAAAAAHTEU2bdLpNu4tTq4QVSalmU6yBoU27i1OrhBZUrmtTrIHGTbuMU6uEElTDZ1OsggEXTbuMU6uEHFO7a1OsggG97AEAAAAAAABZAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA Line truncated
`);function SC(s){let e="";for(let t=0;t<s;++t)t>0&&(e+=`
else `),t<s-1&&(e+=`if(test == ${t}.0){}`);return e}function TC(s,e){if(s===0)throw new Error("Invalid value of `0` passed to `checkMaxIfStatementsInShader`");const t=e.createShader(e.FRAGMENT_SHADER);for(;;){const i=wC.replace(/%forloop%/gi,SC(s));if(e.shaderSource(t,i),e.compileShader(t),!e.getShaderParameter(t,e.COMPILE_STATUS))s=s/2|0;else break}return s}const _d=0,Cd=1,Ad=2,Ed=3,Id=4,Rd=5;class un{constructor(){this.data=0,this.blendMode=He.NORMAL,this.polygonOffset=0,this.blend=!0,this.depthMask=!0}get blend(){return!!(this.data&1<<_d)}set blend(e){!!(this.data&1<<_d)!==e&&(this.data^=1<<_d)}get offsets(){return!!(this.data&1<<Cd)}set offsets(e){!!(this.data&1<<Cd)!==e&&(this.data^=1<<Cd)}get culling(){return!!(this.data&1<<Ad)}set culling(e){!!(this.data&1<<Ad)!==e&&(this.data^=1<<Ad)}get depthTest(){return!!(this.data&1<<Ed)}set depthTest(e){!!(this.data&1<<Ed)!==e&&(this.data^=1<<Ed)}get depthMask(){return!!(this.data&1<<Rd)}set depthMask(e){!!(this.data&1<<Rd)!==e&&(this.data^=1<<Rd)}get clockwiseFrontFace(){return!!(this.data&1<<Id)}set clockwiseFrontFace(e){!!(this.data&1<<Id)!==e&&(this.data^=1<<Id)}get blendMode(){return this._blendMode}set blendMode(e){this.blend=e!==He.NONE,this._blendMode=e}get polygonOffset(){return this._polygonOffset}set polygonOffset(e){this.offsets=!!e,this._polygonOffset=e}static for2d(){const e=new un;return e.depthTest=!1,e.blend=!0,e}}un.prototype.toString=function(){return`[@pixi/core:State blendMode=${this.blendMode} clockwiseFrontFace=${this.clockwiseFrontFace} culling=${this.culling} depthMask=${this.depthMask} polygonOffset=${this.polygonOffset}]`};const _f=[];function Vy(s,e){if(!s)return null;let t="";if(typeof s=="string"){const i=/\.(\w{3,4})(?:$|\?|#)/i.exec(s);i&&(t=i[1].toLowerCase())}for(let i=_f.length-1;i>=0;--i){const n=_f[i];if(n.test&&n.test(s,t))return new n(s,e)}throw new Error("Unrecognized source type to auto-detect Resource")}class Rs{constructor(e){this.items=[],this._name=e,this._aliasCount=0}emit(e,t,i,n,r,o,a,c){if(arguments.length>8)throw new Error("max arguments reached");const{name:l,items:h}=this;this._aliasCount++;for(let u=0,d=h.length;u<d;u++)h[u][l](e,t,i,n,r,o,a,c);return h===this.items&&this._aliasCount--,this}ensureNonAliasedItems(){this._aliasCount>0&&this.items.length>1&&(this._aliasCount=0,this.items=this.items.slice(0))}add(e){return e[this._name]&&(this.ensureNonAliasedItems(),this.remove(e),this.items.push(e)),this}remove(e){const t=this.items.indexOf(e);return t!==-1&&(this.ensureNonAliasedItems(),this.items.splice(t,1)),this}contains(e){return this.items.includes(e)}removeAll(){return this.ensureNonAliasedItems(),this.items.length=0,this}destroy(){this.removeAll(),this.items.length=0,this._name=""}get empty(){return this.items.length===0}get name(){return this._name}}Object.defineProperties(Rs.prototype,{dispatch:{value:Rs.prototype.emit},run:{value:Rs.prototype.emit}});class ll{constructor(e=0,t=0){this._width=e,this._height=t,this.destroyed=!1,this.internal=!1,this.onResize=new Rs("setRealSize"),this.onUpdate=new Rs("update"),this.onError=new Rs("onError")}bind(e){this.onResize.add(e),this.onUpdate.add(e),this.onError.add(e),(this._width||this._height)&&this.onResize.emit(this._width,this._height)}unbind(e){this.onResize.remove(e),this.onUpdate.remove(e),this.onError.remove(e)}resize(e,t){(e!==this._width||t!==this._height)&&(this._width=e,this._height=t,this.onResize.emit(e,t))}get valid(){return!!this._width&&!!this._height}update(){this.destroyed||this.onUpdate.emit()}load(){return Promise.resolve(this)}get width(){return this._width}get height(){return this._height}style(e,t,i){return!1}dispose(){}destroy(){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)}static test(e,t){return!1}}class Kh extends ll{constructor(e,t){const{width:i,height:n}=t||{};if(!i||!n)throw new Error("BufferResource width or height invalid");super(i,n),this.data=e,this.unpackAlignment=t.unpackAlignment??4}upload(e,t,i){const n=e.gl;n.pixelStorei(n.UNPACK_ALIGNMENT,this.unpackAlignment),n.pixelStorei(n.UNPACK_PREMULTIPLY_ALPHA_WEBGL,t.alphaMode===xi.UNPACK);const r=t.realWidth,o=t.realHeight;return i.width===r&&i.height===o?n.texSubImage2D(t.target,0,0,0,r,o,t.format,i.type,this.data):(i.width=r,i.height=o,n.texImage2D(t.target,0,i.internalFormat,r,o,0,t.format,i.type,this.data)),!0}dispose(){this.data=null}static test(e){return e===null||e instanceof Int8Array||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Float32Array}}const MC={scaleMode:Cs.NEAREST,alphaMode:xi.NPM},Cf=class Io extends bl{constructor(e=null,t=null){super(),t=Object.assign({},Io.defaultOptions,t);const{alphaMode:i,mipmap:n,anisotropicLevel:r,scaleMode:o,width:a,height:c,wrapMode:l,format:h,type:u,target:d,resolution: Line truncated
uniform sampler2D uSampler;
void main(void){
gl_FragColor *= texture2D(uSampler, vTextureCoord);
}`,kC=`attribute vec2 aVertexPosition;
}`,OC=`attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
uniform mat3 projectionMatrix;
@@ -48,7 +48,7 @@ void main(void){
gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);
vTextureCoord = aTextureCoord;
}
`;function O0(s,e,t){const i=s.createShader(e);return s.shaderSource(i,t),s.compileShader(i),i}function Pd(s){const e=new Array(s);for(let t=0;t<e.length;t++)e[t]=!1;return e}function Yy(s,e){switch(s){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 Pd(2*e);case"bvec3":return Pd(3*e);case"bvec4":return Pd(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}const Yo=[{test:s=>s.type==="float"&&s.size===1&&!s.isArray,code:s=>`
`;function O0(s,e,t){const i=s.createShader(e);return s.shaderSource(i,t),s.compileShader(i),i}function Pd(s){const e=new Array(s);for(let t=0;t<e.length;t++)e[t]=!1;return e}function Hy(s,e){switch(s){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 Pd(2*e);case"bvec3":return Pd(3*e);case"bvec4":return Pd(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}const Ho=[{test:s=>s.type==="float"&&s.size===1&&!s.isArray,code:s=>`
if(uv["${s}"] !== ud["${s}"].value)
{
ud["${s}"].value = uv["${s}"]
@@ -168,7 +168,7 @@ void main(void){
cv[3] = v[3];
gl.uniform4f(ud["${s}"].location, v[0], v[1], v[2], v[3])
}`}],FC={float:`
}`}],BC={float:`
if (cv !== v)
{
cu.value = v;
@@ -304,7 +304,7 @@ void main(void){
cu.value = v;
gl.uniform1i(location, v);
}`},OC={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 BC(s,e){var i;const t=[`
}`},LC={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 DC(s,e){var i;const t=[`
var v = null;
var cv = null;
var cu = null;
@@ -314,18 +314,18 @@ void main(void){
renderer.shader.syncUniformBufferGroup(uv.${n}, '${n}');
`):t.push(`
renderer.shader.syncUniformGroup(uv.${n}, syncData);
`));continue}const o=s.uniforms[n];let a=!1;for(let c=0;c<Yo.length;c++)if(Yo[c].test(r,o)){t.push(Yo[c].code(n,o)),a=!0;break}if(!a){const c=(r.size===1&&!r.isArray?FC:OC)[r.type].replace("location",`ud["${n}"].location`);t.push(`
`));continue}const o=s.uniforms[n];let a=!1;for(let c=0;c<Ho.length;c++)if(Ho[c].test(r,o)){t.push(Ho[c].code(n,o)),a=!0;break}if(!a){const c=(r.size===1&&!r.isArray?BC:LC)[r.type].replace("location",`ud["${n}"].location`);t.push(`
cu = ud["${n}"];
cv = cu.value;
v = uv["${n}"];
${c};`)}}return new Function("ud","uv","renderer","syncData",t.join(`
`))}const Gy={};let yo=Gy;function LC(){if(yo===Gy||yo!=null&&yo.isContextLost()){const s=ke.ADAPTER.createCanvas();let e;ke.PREFER_ENV>=ao.WEBGL2&&(e=s.getContext("webgl2",{})),e||(e=s.getContext("webgl",{})||s.getContext("experimental-webgl",{}),e?e.getExtension("WEBGL_draw_buffers"):e=null),yo=e}return yo}let Xl;function DC(){if(!Xl){Xl=fs.MEDIUM;const s=LC();if(s&&s.getShaderPrecisionFormat){const e=s.getShaderPrecisionFormat(s.FRAGMENT_SHADER,s.HIGH_FLOAT);e&&(Xl=e.precision?fs.HIGH:fs.MEDIUM)}}return Xl}function B0(s,e){const t=s.getShaderSource(e).split(`
`))}const jy={};let wo=jy;function NC(){if(wo===jy||wo!=null&&wo.isContextLost()){const s=ke.ADAPTER.createCanvas();let e;ke.PREFER_ENV>=ho.WEBGL2&&(e=s.getContext("webgl2",{})),e||(e=s.getContext("webgl",{})||s.getContext("experimental-webgl",{}),e?e.getExtension("WEBGL_draw_buffers"):e=null),wo=e}return wo}let Xl;function UC(){if(!Xl){Xl=fs.MEDIUM;const s=NC();if(s&&s.getShaderPrecisionFormat){const e=s.getShaderPrecisionFormat(s.FRAGMENT_SHADER,s.HIGH_FLOAT);e&&(Xl=e.precision?fs.HIGH:fs.MEDIUM)}}return Xl}function B0(s,e){const t=s.getShaderSource(e).split(`
`).map((l,h)=>`${h}: ${l}`),i=s.getShaderInfoLog(e),n=i.split(`
`),r={},o=n.map(l=>parseFloat(l.replace(/^ERROR\: 0\:([\d]+)\:.*$/,"$1"))).filter(l=>l&&!r[l]?(r[l]=!0,!0):!1),a=[""];o.forEach(l=>{t[l-1]=`%c${t[l-1]}%c`,a.push("background: #FF0000; color:#FFFFFF; font-size: 10px","font-size: 10px")});const c=t.join(`
`);a[0]=c,console.error(i),console.groupCollapsed("click to view full shader code"),console.warn(...a),console.groupEnd()}function NC(s,e,t,i){s.getProgramParameter(e,s.LINK_STATUS)||(s.getShaderParameter(t,s.COMPILE_STATUS)||B0(s,t),s.getShaderParameter(i,s.COMPILE_STATUS)||B0(s,i),console.error("PixiJS Error: Could not initialize shader."),s.getProgramInfoLog(e)!==""&&console.warn("PixiJS Warning: gl.getProgramInfoLog()",s.getProgramInfoLog(e)))}const UC={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 Hy(s){return UC[s]}let Vl=null;const L0={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 jy(s,e){if(!Vl){const t=Object.keys(L0);Vl={};for(let i=0;i<t.length;++i){const n=t[i];Vl[s[n]]=L0[n]}}return Vl[e]}function D0(s,e,t){if(s.substring(0,9)!=="precision"){let i=e;return e===fs.HIGH&&t!==fs.HIGH&&(i=fs.MEDIUM),`precision ${i} float;
${s}`}else if(t!==fs.HIGH&&s.substring(0,15)==="precision highp")return s.replace("precision highp","precision mediump");return s}let wa;function $C(){if(typeof wa=="boolean")return wa;try{wa=new Function("param1","param2","param3","return param1[param2] === param3;")({a:"b"},"a","b")===!0}catch{wa=!1}return wa}let XC=0;const Yl={},Rf=class Eo{constructor(e,t,i="pixi-shader",n={}){this.extra={},this.id=XC++,this.vertexSrc=e||Eo.defaultVertexSrc,this.fragmentSrc=t||Eo.defaultFragmentSrc,this.vertexSrc=this.vertexSrc.trim(),this.fragmentSrc=this.fragmentSrc.trim(),this.extra=n,this.vertexSrc.substring(0,8)!=="#version"&&(i=i.replace(/\s+/g,"-"),Yl[i]?(Yl[i]++,i+=`-${Yl[i]}`):Yl[i]=1,this.vertexSrc=`#define SHADER_NAME ${i}
`);a[0]=c,console.error(i),console.groupCollapsed("click to view full shader code"),console.warn(...a),console.groupEnd()}function $C(s,e,t,i){s.getProgramParameter(e,s.LINK_STATUS)||(s.getShaderParameter(t,s.COMPILE_STATUS)||B0(s,t),s.getShaderParameter(i,s.COMPILE_STATUS)||B0(s,i),console.error("PixiJS Error: Could not initialize shader."),s.getProgramInfoLog(e)!==""&&console.warn("PixiJS Warning: gl.getProgramInfoLog()",s.getProgramInfoLog(e)))}const XC={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 Wy(s){return XC[s]}let Vl=null;const L0={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 zy(s,e){if(!Vl){const t=Object.keys(L0);Vl={};for(let i=0;i<t.length;++i){const n=t[i];Vl[s[n]]=L0[n]}}return Vl[e]}function D0(s,e,t){if(s.substring(0,9)!=="precision"){let i=e;return e===fs.HIGH&&t!==fs.HIGH&&(i=fs.MEDIUM),`precision ${i} float;
${s}`}else if(t!==fs.HIGH&&s.substring(0,15)==="precision highp")return s.replace("precision highp","precision mediump");return s}let Sa;function VC(){if(typeof Sa=="boolean")return Sa;try{Sa=new Function("param1","param2","param3","return param1[param2] === param3;")({a:"b"},"a","b")===!0}catch{Sa=!1}return Sa}let YC=0;const Yl={},Rf=class Ro{constructor(e,t,i="pixi-shader",n={}){this.extra={},this.id=YC++,this.vertexSrc=e||Ro.defaultVertexSrc,this.fragmentSrc=t||Ro.defaultFragmentSrc,this.vertexSrc=this.vertexSrc.trim(),this.fragmentSrc=this.fragmentSrc.trim(),this.extra=n,this.vertexSrc.substring(0,8)!=="#version"&&(i=i.replace(/\s+/g,"-"),Yl[i]?(Yl[i]++,i+=`-${Yl[i]}`):Yl[i]=1,this.vertexSrc=`#define SHADER_NAME ${i}
${this.vertexSrc}`,this.fragmentSrc=`#define SHADER_NAME ${i}
${this.fragmentSrc}`,this.vertexSrc=D0(this.vertexSrc,Eo.defaultVertexPrecision,fs.HIGH),this.fragmentSrc=D0(this.fragmentSrc,Eo.defaultFragmentPrecision,DC())),this.glPrograms={},this.syncUniforms=null}static get defaultVertexSrc(){return kC}static get defaultFragmentSrc(){return PC}static from(e,t,i){const n=e+t;let r=I0[n];return r||(I0[n]=r=new Eo(e,t,i)),r}};Rf.defaultVertexPrecision=fs.HIGH,Rf.defaultFragmentPrecision=Mn.apple.device?fs.HIGH:fs.MEDIUM;let en=Rf,VC=0;class Rs{constructor(e,t,i){this.group=!0,this.syncUniforms={},this.dirtyId=0,this.id=VC++,this.static=!!t,this.ubo=!!i,e instanceof Lt?(this.buffer=e,this.buffer.type=nn.UNIFORM_BUFFER,this.autoManage=!1,this.ubo=!0):(this.uniforms=e,this.ubo&&(this.buffer=new Lt(new Float32Array(1)),this.buffer.type=nn.UNIFORM_BUFFER,this.autoManage=!0))}update(){this.dirtyId++,!this.autoManage&&this.buffer&&this.buffer.update()}add(e,t,i){if(!this.ubo)this.uniforms[e]=new Rs(t,i);else throw new Error("[UniformGroup] uniform groups in ubo mode cannot be modified, or have uniform groups nested in them")}static from(e,t,i){return new Rs(e,t,i)}static uboFrom(e,t){return new Rs(e,t??!0,!0)}}class Ps{constructor(e,t){this.uniformBindCount=0,this.program=e,t?t instanceof Rs?this.uniformGroup=t:this.uniformGroup=new Rs(t):this.uniformGroup=new Rs({}),this.disposeRunner=new Is("disposeShader")}checkUniformExists(e,t){if(t.uniforms[e])return!0;for(const i in t.uniforms){const n=t.uniforms[i];if(n.group===!0&&this.checkUniformExists(e,n))return!0}return!1}destroy(){this.uniformGroup=null,this.disposeRunner.emit(this),this.disposeRunner.destroy()}get uniforms(){return this.uniformGroup.uniforms}static from(e,t,i){const n=en.from(e,t);return new Ps(n,i)}}class Wy{constructor(e,t){if(this.vertexSrc=e,this.fragTemplate=t,this.programCache={},this.defaultGroupCache={},!t.includes("%count%"))throw new Error('Fragment template must contain "%count%".');if(!t.includes("%forloop%"))throw new Error('Fragment template must contain "%forloop%".')}generateShader(e){if(!this.programCache[e]){const i=new Int32Array(e);for(let r=0;r<e;r++)i[r]=r;this.defaultGroupCache[e]=Rs.from({uSamplers:i},!0);let n=this.fragTemplate;n=n.replace(/%count%/gi,`${e}`),n=n.replace(/%forloop%/gi,this.generateSampleSrc(e)),this.programCache[e]=new en(this.vertexSrc,n)}const t={tint:new Float32Array([1,1,1,1]),translationMatrix:new Dt,default:this.defaultGroupCache[e]};return new Ps(this.programCache[e],t)}generateSampleSrc(e){let t="";t+=`
${this.fragmentSrc}`,this.vertexSrc=D0(this.vertexSrc,Ro.defaultVertexPrecision,fs.HIGH),this.fragmentSrc=D0(this.fragmentSrc,Ro.defaultFragmentPrecision,UC())),this.glPrograms={},this.syncUniforms=null}static get defaultVertexSrc(){return OC}static get defaultFragmentSrc(){return FC}static from(e,t,i){const n=e+t;let r=I0[n];return r||(I0[n]=r=new Ro(e,t,i)),r}};Rf.defaultVertexPrecision=fs.HIGH,Rf.defaultFragmentPrecision=En.apple.device?fs.HIGH:fs.MEDIUM;let nn=Rf,GC=0;class Ps{constructor(e,t,i){this.group=!0,this.syncUniforms={},this.dirtyId=0,this.id=GC++,this.static=!!t,this.ubo=!!i,e instanceof Nt?(this.buffer=e,this.buffer.type=an.UNIFORM_BUFFER,this.autoManage=!1,this.ubo=!0):(this.uniforms=e,this.ubo&&(this.buffer=new Nt(new Float32Array(1)),this.buffer.type=an.UNIFORM_BUFFER,this.autoManage=!0))}update(){this.dirtyId++,!this.autoManage&&this.buffer&&this.buffer.update()}add(e,t,i){if(!this.ubo)this.uniforms[e]=new Ps(t,i);else throw new Error("[UniformGroup] uniform groups in ubo mode cannot be modified, or have uniform groups nested in them")}static from(e,t,i){return new Ps(e,t,i)}static uboFrom(e,t){return new Ps(e,t??!0,!0)}}class ks{constructor(e,t){this.uniformBindCount=0,this.program=e,t?t instanceof Ps?this.uniformGroup=t:this.uniformGroup=new Ps(t):this.uniformGroup=new Ps({}),this.disposeRunner=new Rs("disposeShader")}checkUniformExists(e,t){if(t.uniforms[e])return!0;for(const i in t.uniforms){const n=t.uniforms[i];if(n.group===!0&&this.checkUniformExists(e,n))return!0}return!1}destroy(){this.uniformGroup=null,this.disposeRunner.emit(this),this.disposeRunner.destroy()}get uniforms(){return this.uniformGroup.uniforms}static from(e,t,i){const n=nn.from(e,t);return new ks(n,i)}}class qy{constructor(e,t){if(this.vertexSrc=e,this.fragTemplate=t,this.programCache={},this.defaultGroupCache={},!t.includes("%count%"))throw new Error('Fragment template must contain "%count%".');if(!t.includes("%forloop%"))throw new Error('Fragment template must contain "%forloop%".')}generateShader(e){if(!this.programCache[e]){const i=new Int32Array(e);for(let r=0;r<e;r++)i[r]=r;this.defaultGroupCache[e]=Ps.from({uSamplers:i},!0);let n=this.fragTemplate;n=n.replace(/%count%/gi,`${e}`),n=n.replace(/%forloop%/gi,this.generateSampleSrc(e)),this.programCache[e]=new nn(this.vertexSrc,n)}const t={tint:new Float32Array([1,1,1,1]),translationMatrix:new Ut,default:this.defaultGroupCache[e]};return new ks(this.programCache[e],t)}generateSampleSrc(e){let t="";t+=`
`,t+=`
`;for(let i=0;i<e;i++)i>0&&(t+=`
else `),i<e-1&&(t+=`if(vTextureId < ${i}.5)`),t+=`
@@ -333,7 +333,7 @@ else `),i<e-1&&(t+=`if(vTextureId < ${i}.5)`),t+=`
color = texture2D(uSamplers[${i}], vTextureCoord);`,t+=`
}`;return t+=`
`,t+=`
`,t}}class Pf{constructor(){this.elements=[],this.ids=[],this.count=0}clear(){for(let e=0;e<this.count;e++)this.elements[e]=null;this.count=0}}function YC(){return!Mn.apple.device}function GC(s){let e=!0;const t=ke.ADAPTER.getNavigator();if(Mn.tablet||Mn.phone){if(Mn.apple.device){const i=t.userAgent.match(/OS (\d+)_(\d+)?/);i&&parseInt(i[1],10)<11&&(e=!1)}if(Mn.android.device){const i=t.userAgent.match(/Android\s([0-9.]*)/);i&&parseInt(i[1],10)<7&&(e=!1)}}return e?s:4}class eu{constructor(e){this.renderer=e}flush(){}destroy(){this.renderer=null}start(){}stop(){this.flush()}render(e){}}var HC=`varying vec2 vTextureCoord;
`,t}}class Pf{constructor(){this.elements=[],this.ids=[],this.count=0}clear(){for(let e=0;e<this.count;e++)this.elements[e]=null;this.count=0}}function HC(){return!En.apple.device}function jC(s){let e=!0;const t=ke.ADAPTER.getNavigator();if(En.tablet||En.phone){if(En.apple.device){const i=t.userAgent.match(/OS (\d+)_(\d+)?/);i&&parseInt(i[1],10)<11&&(e=!1)}if(En.android.device){const i=t.userAgent.match(/Android\s([0-9.]*)/);i&&parseInt(i[1],10)<7&&(e=!1)}}return e?s:4}class eu{constructor(e){this.renderer=e}flush(){}destroy(){this.renderer=null}start(){}stop(){this.flush()}render(e){}}var WC=`varying vec2 vTextureCoord;
varying vec4 vColor;
varying float vTextureId;
uniform sampler2D uSamplers[%count%];
@@ -343,7 +343,7 @@ void main(void){
%forloop%
gl_FragColor = color * vColor;
}
`,jC=`precision highp float;
`,zC=`precision highp float;
attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
attribute vec4 aColor;
@@ -364,14 +364,14 @@ void main(void){
vTextureId = aTextureId;
vColor = aColor * tint;
}
`;const Ra=class bs extends eu{constructor(e){super(e),this.setShaderGenerator(),this.geometryClass=Xy,this.vertexSize=6,this.state=ln.for2d(),this.size=bs.defaultBatchSize*4,this._vertexCount=0,this._indexCount=0,this._bufferedElements=[],this._bufferedTextures=[],this._bufferSize=0,this._shader=null,this._packedGeometries=[],this._packedGeometryPoolSize=2,this._flushId=0,this._aBuffers={},this._iBuffers={},this.maxTextures=1,this.renderer.on("prerender",this.onPrerender,this),e.runners.contextChange.add(this),this._dcIndex=0,this._aIndex=0,this._iIndex=0,this._attributeBuffer=null,this._indexBuffer=null,this._tempBoundTextures=[]}static get defaultMaxTextures(){return this._defaultMaxTextures=this._defaultMaxTextures??GC(32),this._defaultMaxTextures}static set defaultMaxTextures(e){this._defaultMaxTextures=e}static get canUploadSameBuffer(){return this._canUploadSameBuffer=this._canUploadSameBuffer??YC(),this._canUploadSameBuffer}static set canUploadSameBuffer(e){this._canUploadSameBuffer=e}get MAX_TEXTURES(){return lt("7.1.0","BatchRenderer#MAX_TEXTURES renamed to BatchRenderer#maxTextures"),this.maxTextures}static get defaultVertexSrc(){return jC}static get defaultFragmentTemplate(){return HC}setShaderGenerator({vertex:e=bs.defaultVertexSrc,fragment:t=bs.defaultFragmentTemplate}={}){this.shaderGenerator=new Wy(e,t)}contextChange(){const e=this.renderer.gl;ke.PREFER_ENV===ao.WEBGL_LEGACY?this.maxTextures=1:(this.maxTextures=Math.min(e.getParameter(e.MAX_TEXTURE_IMAGE_UNITS),bs.defaultMaxTextures),this.maxTextures=wC(this.maxTextures,e)),this._shader=this.shaderGenerator.generateShader(this.maxTextures);for(let t=0;t<this._packedGeometryPoolSize;t++)this._packedGeometries[t]=new this.geometryClass;this.initFlushBuffers()}initFlushBuffers(){const{_drawCallPool:e,_textureArrayPool:t}=bs,i=this.size/4,n=Math.floor(i/this.maxTextures)+1;for(;e.length<i;)e.push(new Af);for(;t.length<n;)t.push(new Pf);for(let r=0;r<this.maxTextures;r++)this._tempBoundTextures[r]=null}onPrerender(){this._flushId=0}render(e){e._texture.valid&&(this._vertexCount+e.vertexData.length/2>this.size&&this.flush(),this._vertexCount+=e.vertexData.length/2,this._indexCount+=e.indices.length,this._bufferedTextures[this._bufferSize]=e._texture.baseTexture,this._bufferedElements[this._bufferSize++]=e)}buildTexturesAndDrawCalls(){const{_bufferedTextures:e,maxTextures:t}=this,i=bs._textureArrayPool,n=this.renderer.batch,r=this._tempBoundTextures,o=this.renderer.textureGC.count;let a=++Ze._globalBatch,c=0,l=i[0],h=0;n.copyBoundTextures(r,t);for(let u=0;u<this._bufferSize;++u){const d=e[u];e[u]=null,d._batchEnabled!==a&&(l.count>=t&&(n.boundArray(l,r,a,t),this.buildDrawCalls(l,h,u),h=u,l=i[++c],++a),d._batchEnabled=a,d.touched=o,l.elements[l.count++]=d)}l.count>0&&(n.boundArray(l,r,a,t),this.buildDrawCalls(l,h,this._bufferSize),++c,++a);for(let u=0;u<r.length;u++)r[u]=null;Ze._globalBatch=a}buildDrawCalls(e,t,i){const{_bufferedElements:n,_attributeBuffer:r,_indexBuffer:o,vertexSize:a}=this,c=bs._drawCallPool;let l=this._dcIndex,h=this._aIndex,u=this._iIndex,d=c[l];d.start=this._iIndex,d.texArray=e;for(let f=t;f<i;++f){const p=n[f],m=p._texture.baseTexture,g=Dy[m.alphaMode?1:0][p.blendMode];n[f]=null,t<f&&d.blend!==g&&(d.size=u-d.start,t=f,d=c[++l],d.texArray=e,d.start=u),this.packInterleavedGeometry(p,r,o,h,u),h+=p.vertexData.length/2*a,u+=p.indices.length,d.blend=g}t<i&&(d.size=u-d.start,++l),this._dcIndex=l,this._aIndex=h,this._iIndex=u}bindAndClearTexArray(e){const t=this.renderer.texture;for(let i=0;i<e.count;i++)t.bind(e.elements[i],e.ids[i]),e.elements[i]=null;e.count=0}updateGeometry(){const{_packedGeometries:e,_attributeBuffer:t,_indexBuffer:i}=this;bs.canUploadSameBuffer?(e[this._flushId]._buffer.update(t.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(t.rawBinaryData),e[this._flushId]._indexBuffer.update(i),this.renderer.geometry.bind(e[this._flushId]),this.renderer.geometry.updateBuffers(),this._flushId++)}drawBatches(){const e=this._dcIndex,{gl:t,state:i}=this.renderer,n=bs._drawCallPool;let r=null;for(let o=0;o<e;o++){const{texArray:a,type:c,size:l,start:h,blend:u}=n[o];r!==a&&(r=a,this.bindAndClearTexArray(a)),this.state.blendMode=u,i.set(this.state),t.drawElements(c,l,t.UNSIGNED_SHORT,h*2)}}flush(){this._vertexCount!==0&&(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)}start(){this.renderer.state.set(this.state),this.renderer.texture.ensureSamplerType(this.maxTextures),this.renderer.shader.bind(this._shader),bs.canUploadSameBuffer&&this.renderer.geometry.bind(this._packedGeometries[this._f Line truncated
`;const Pa=class ws extends eu{constructor(e){super(e),this.setShaderGenerator(),this.geometryClass=Yy,this.vertexSize=6,this.state=un.for2d(),this.size=ws.defaultBatchSize*4,this._vertexCount=0,this._indexCount=0,this._bufferedElements=[],this._bufferedTextures=[],this._bufferSize=0,this._shader=null,this._packedGeometries=[],this._packedGeometryPoolSize=2,this._flushId=0,this._aBuffers={},this._iBuffers={},this.maxTextures=1,this.renderer.on("prerender",this.onPrerender,this),e.runners.contextChange.add(this),this._dcIndex=0,this._aIndex=0,this._iIndex=0,this._attributeBuffer=null,this._indexBuffer=null,this._tempBoundTextures=[]}static get defaultMaxTextures(){return this._defaultMaxTextures=this._defaultMaxTextures??jC(32),this._defaultMaxTextures}static set defaultMaxTextures(e){this._defaultMaxTextures=e}static get canUploadSameBuffer(){return this._canUploadSameBuffer=this._canUploadSameBuffer??HC(),this._canUploadSameBuffer}static set canUploadSameBuffer(e){this._canUploadSameBuffer=e}get MAX_TEXTURES(){return ht("7.1.0","BatchRenderer#MAX_TEXTURES renamed to BatchRenderer#maxTextures"),this.maxTextures}static get defaultVertexSrc(){return zC}static get defaultFragmentTemplate(){return WC}setShaderGenerator({vertex:e=ws.defaultVertexSrc,fragment:t=ws.defaultFragmentTemplate}={}){this.shaderGenerator=new qy(e,t)}contextChange(){const e=this.renderer.gl;ke.PREFER_ENV===ho.WEBGL_LEGACY?this.maxTextures=1:(this.maxTextures=Math.min(e.getParameter(e.MAX_TEXTURE_IMAGE_UNITS),ws.defaultMaxTextures),this.maxTextures=TC(this.maxTextures,e)),this._shader=this.shaderGenerator.generateShader(this.maxTextures);for(let t=0;t<this._packedGeometryPoolSize;t++)this._packedGeometries[t]=new this.geometryClass;this.initFlushBuffers()}initFlushBuffers(){const{_drawCallPool:e,_textureArrayPool:t}=ws,i=this.size/4,n=Math.floor(i/this.maxTextures)+1;for(;e.length<i;)e.push(new Af);for(;t.length<n;)t.push(new Pf);for(let r=0;r<this.maxTextures;r++)this._tempBoundTextures[r]=null}onPrerender(){this._flushId=0}render(e){e._texture.valid&&(this._vertexCount+e.vertexData.length/2>this.size&&this.flush(),this._vertexCount+=e.vertexData.length/2,this._indexCount+=e.indices.length,this._bufferedTextures[this._bufferSize]=e._texture.baseTexture,this._bufferedElements[this._bufferSize++]=e)}buildTexturesAndDrawCalls(){const{_bufferedTextures:e,maxTextures:t}=this,i=ws._textureArrayPool,n=this.renderer.batch,r=this._tempBoundTextures,o=this.renderer.textureGC.count;let a=++Je._globalBatch,c=0,l=i[0],h=0;n.copyBoundTextures(r,t);for(let u=0;u<this._bufferSize;++u){const d=e[u];e[u]=null,d._batchEnabled!==a&&(l.count>=t&&(n.boundArray(l,r,a,t),this.buildDrawCalls(l,h,u),h=u,l=i[++c],++a),d._batchEnabled=a,d.touched=o,l.elements[l.count++]=d)}l.count>0&&(n.boundArray(l,r,a,t),this.buildDrawCalls(l,h,this._bufferSize),++c,++a);for(let u=0;u<r.length;u++)r[u]=null;Je._globalBatch=a}buildDrawCalls(e,t,i){const{_bufferedElements:n,_attributeBuffer:r,_indexBuffer:o,vertexSize:a}=this,c=ws._drawCallPool;let l=this._dcIndex,h=this._aIndex,u=this._iIndex,d=c[l];d.start=this._iIndex,d.texArray=e;for(let f=t;f<i;++f){const p=n[f],m=p._texture.baseTexture,g=Uy[m.alphaMode?1:0][p.blendMode];n[f]=null,t<f&&d.blend!==g&&(d.size=u-d.start,t=f,d=c[++l],d.texArray=e,d.start=u),this.packInterleavedGeometry(p,r,o,h,u),h+=p.vertexData.length/2*a,u+=p.indices.length,d.blend=g}t<i&&(d.size=u-d.start,++l),this._dcIndex=l,this._aIndex=h,this._iIndex=u}bindAndClearTexArray(e){const t=this.renderer.texture;for(let i=0;i<e.count;i++)t.bind(e.elements[i],e.ids[i]),e.elements[i]=null;e.count=0}updateGeometry(){const{_packedGeometries:e,_attributeBuffer:t,_indexBuffer:i}=this;ws.canUploadSameBuffer?(e[this._flushId]._buffer.update(t.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(t.rawBinaryData),e[this._flushId]._indexBuffer.update(i),this.renderer.geometry.bind(e[this._flushId]),this.renderer.geometry.updateBuffers(),this._flushId++)}drawBatches(){const e=this._dcIndex,{gl:t,state:i}=this.renderer,n=ws._drawCallPool;let r=null;for(let o=0;o<e;o++){const{texArray:a,type:c,size:l,start:h,blend:u}=n[o];r!==a&&(r=a,this.bindAndClearTexArray(a)),this.state.blendMode=u,i.set(this.state),t.drawElements(c,l,t.UNSIGNED_SHORT,h*2)}}flush(){this._vertexCount!==0&&(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)}start(){this.renderer.state.set(this.state),this.renderer.texture.ensureSamplerType(this.maxTextures),this.renderer.shader.bind(this._shader),ws.canUploadSameBuffer&&this.renderer.geometry.bind(this._packedGeometries[this._f Line truncated
uniform sampler2D uSampler;
void main(void){
gl_FragColor = texture2D(uSampler, vTextureCoord);
}
`,zC=`attribute vec2 aVertexPosition;
`,KC=`attribute vec2 aVertexPosition;
uniform mat3 projectionMatrix;
@@ -397,7 +397,7 @@ void main(void)
gl_Position = filterVertexPosition();
vTextureCoord = filterTextureCoord();
}
`;const kf=class Pa extends Ps{constructor(e,t,i){const n=en.from(e||Pa.defaultVertexSrc,t||Pa.defaultFragmentSrc);super(n,i),this.padding=0,this.resolution=Pa.defaultResolution,this.multisample=Pa.defaultMultisample,this.enabled=!0,this.autoFit=!0,this.state=new ln}apply(e,t,i,n,r){e.applyFilter(this,t,i,n)}get blendMode(){return this.state.blendMode}set blendMode(e){this.state.blendMode=e}get resolution(){return this._resolution}set resolution(e){this._resolution=e}static get defaultVertexSrc(){return zC}static get defaultFragmentSrc(){return WC}};kf.defaultResolution=1,kf.defaultMultisample=oi.NONE;let Xi=kf;class zc{constructor(){this.clearBeforeRender=!0,this._backgroundColor=new Tt(0),this.alpha=1}init(e){this.clearBeforeRender=e.clearBeforeRender;const{backgroundColor:t,background:i,backgroundAlpha:n}=e,r=i??t;r!==void 0&&(this.color=r),this.alpha=n}get color(){return this._backgroundColor.value}set color(e){this._backgroundColor.setValue(e)}get alpha(){return this._backgroundColor.alpha}set alpha(e){this._backgroundColor.setAlpha(e)}get backgroundColor(){return this._backgroundColor}destroy(){}}zc.defaultOptions={backgroundAlpha:1,backgroundColor:0,clearBeforeRender:!0},zc.extension={type:[Re.RendererSystem,Re.CanvasRendererSystem],name:"background"};$e.add(zc);class zy{constructor(e){this.renderer=e,this.emptyRenderer=new eu(e),this.currentRenderer=this.emptyRenderer}setObjectRenderer(e){this.currentRenderer!==e&&(this.currentRenderer.stop(),this.currentRenderer=e,this.currentRenderer.start())}flush(){this.setObjectRenderer(this.emptyRenderer)}reset(){this.setObjectRenderer(this.emptyRenderer)}copyBoundTextures(e,t){const{boundTextures:i}=this.renderer.texture;for(let n=t-1;n>=0;--n)e[n]=i[n]||null,e[n]&&(e[n]._batchLocation=n)}boundArray(e,t,i,n){const{elements:r,ids:o,count:a}=e;let c=0;for(let l=0;l<a;l++){const h=r[l],u=h._batchLocation;if(u>=0&&u<n&&t[u]===h){o[l]=u;continue}for(;c<n;){const d=t[c];if(d&&d._batchEnabled===i&&d._batchLocation===c){c++;continue}o[l]=c,h._batchLocation=c,t[c]=h;break}}}destroy(){this.renderer=null}}zy.extension={type:Re.RendererSystem,name:"batch"};$e.add(zy);let N0=0;class qc{constructor(e){this.renderer=e,this.webGLVersion=1,this.extensions={},this.supports={uint32Indices:!1},this.handleContextLost=this.handleContextLost.bind(this),this.handleContextRestored=this.handleContextRestored.bind(this)}get isLost(){return!this.gl||this.gl.isContextLost()}contextChange(e){this.gl=e,this.renderer.gl=e,this.renderer.CONTEXT_UID=N0++}init(e){if(e.context)this.initFromContext(e.context);else{const t=this.renderer.background.alpha<1,i=e.premultipliedAlpha;this.preserveDrawingBuffer=e.preserveDrawingBuffer,this.useContextAlpha=e.useContextAlpha,this.powerPreference=e.powerPreference,this.initFromOptions({alpha:t,premultipliedAlpha:i,antialias:e.antialias,stencil:!0,preserveDrawingBuffer:e.preserveDrawingBuffer,powerPreference:e.powerPreference})}}initFromContext(e){this.gl=e,this.validateContext(e),this.renderer.gl=e,this.renderer.CONTEXT_UID=N0++,this.renderer.runners.contextChange.emit(e);const t=this.renderer.view;t.addEventListener!==void 0&&(t.addEventListener("webglcontextlost",this.handleContextLost,!1),t.addEventListener("webglcontextrestored",this.handleContextRestored,!1))}initFromOptions(e){const t=this.createContext(this.renderer.view,e);this.initFromContext(t)}createContext(e,t){let i;if(ke.PREFER_ENV>=ao.WEBGL2&&(i=e.getContext("webgl2",t)),i)this.webGLVersion=2;else if(this.webGLVersion=1,i=e.getContext("webgl",t)||e.getContext("experimental-webgl",t),!i)throw new Error("This browser does not support WebGL. Try using the canvas renderer");return this.gl=i,this.getExtensions(),this.gl}getExtensions(){const{gl:e}=this,t={loseContext:e.getExtension("WEBGL_lose_context"),anisotropicFiltering:e.getExtension("EXT_texture_filter_anisotropic"),floatTextureLinear:e.getExtension("OES_texture_float_linear"),s3tc:e.getExtension("WEBGL_compressed_texture_s3tc"),s3tc_sRGB:e.getExtension("WEBGL_compressed_texture_s3tc_srgb"),etc:e.getExtension("WEBGL_compressed_texture_etc"),etc1:e.getExtension("WEBGL_compressed_texture_etc1"),pvrtc:e.getExtension("WEBGL_compressed_texture_pvrtc")||e.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc"),atc:e.getExtension("WEBGL_compressed_texture_atc"),astc:e.getExtension("WEBGL_compressed_texture_astc"),bptc:e.getExtension("EXT_texture_compression_bptc")};this.webGLVersion===1?Object.assign(this.extensions,t,{drawBuffers:e.getExtension("WEBGL_draw_buffers"),depthTexture:e.getExtension("WEBGL_depth_texture"),vertexArrayObject:e.getExtension("OES_vertex_array_object")||e.getExtension("MOZ_OES_vertex_array_object")||e.getExtension("WEBKIT_OES_vertex_array_object"),uint32ElementIndex:e.getExtension("OES_element_index_uint"),floatTexture:e.getExtension("OES_texture_float"),floatTextureLinear:e.getExtension("OES_texture_float_linear"),textureHalfFloat:e.getExtension("OES_texture_half_float"),textureHalfFloatLinear:e.getExtension("OES_texture_ha Line truncated
`;const kf=class ka extends ks{constructor(e,t,i){const n=nn.from(e||ka.defaultVertexSrc,t||ka.defaultFragmentSrc);super(n,i),this.padding=0,this.resolution=ka.defaultResolution,this.multisample=ka.defaultMultisample,this.enabled=!0,this.autoFit=!0,this.state=new un}apply(e,t,i,n,r){e.applyFilter(this,t,i,n)}get blendMode(){return this.state.blendMode}set blendMode(e){this.state.blendMode=e}get resolution(){return this._resolution}set resolution(e){this._resolution=e}static get defaultVertexSrc(){return KC}static get defaultFragmentSrc(){return qC}};kf.defaultResolution=1,kf.defaultMultisample=ai.NONE;let Xi=kf;class zc{constructor(){this.clearBeforeRender=!0,this._backgroundColor=new Mt(0),this.alpha=1}init(e){this.clearBeforeRender=e.clearBeforeRender;const{backgroundColor:t,background:i,backgroundAlpha:n}=e,r=i??t;r!==void 0&&(this.color=r),this.alpha=n}get color(){return this._backgroundColor.value}set color(e){this._backgroundColor.setValue(e)}get alpha(){return this._backgroundColor.alpha}set alpha(e){this._backgroundColor.setAlpha(e)}get backgroundColor(){return this._backgroundColor}destroy(){}}zc.defaultOptions={backgroundAlpha:1,backgroundColor:0,clearBeforeRender:!0},zc.extension={type:[Re.RendererSystem,Re.CanvasRendererSystem],name:"background"};Ue.add(zc);class Ky{constructor(e){this.renderer=e,this.emptyRenderer=new eu(e),this.currentRenderer=this.emptyRenderer}setObjectRenderer(e){this.currentRenderer!==e&&(this.currentRenderer.stop(),this.currentRenderer=e,this.currentRenderer.start())}flush(){this.setObjectRenderer(this.emptyRenderer)}reset(){this.setObjectRenderer(this.emptyRenderer)}copyBoundTextures(e,t){const{boundTextures:i}=this.renderer.texture;for(let n=t-1;n>=0;--n)e[n]=i[n]||null,e[n]&&(e[n]._batchLocation=n)}boundArray(e,t,i,n){const{elements:r,ids:o,count:a}=e;let c=0;for(let l=0;l<a;l++){const h=r[l],u=h._batchLocation;if(u>=0&&u<n&&t[u]===h){o[l]=u;continue}for(;c<n;){const d=t[c];if(d&&d._batchEnabled===i&&d._batchLocation===c){c++;continue}o[l]=c,h._batchLocation=c,t[c]=h;break}}}destroy(){this.renderer=null}}Ky.extension={type:Re.RendererSystem,name:"batch"};Ue.add(Ky);let N0=0;class qc{constructor(e){this.renderer=e,this.webGLVersion=1,this.extensions={},this.supports={uint32Indices:!1},this.handleContextLost=this.handleContextLost.bind(this),this.handleContextRestored=this.handleContextRestored.bind(this)}get isLost(){return!this.gl||this.gl.isContextLost()}contextChange(e){this.gl=e,this.renderer.gl=e,this.renderer.CONTEXT_UID=N0++}init(e){if(e.context)this.initFromContext(e.context);else{const t=this.renderer.background.alpha<1,i=e.premultipliedAlpha;this.preserveDrawingBuffer=e.preserveDrawingBuffer,this.useContextAlpha=e.useContextAlpha,this.powerPreference=e.powerPreference,this.initFromOptions({alpha:t,premultipliedAlpha:i,antialias:e.antialias,stencil:!0,preserveDrawingBuffer:e.preserveDrawingBuffer,powerPreference:e.powerPreference})}}initFromContext(e){this.gl=e,this.validateContext(e),this.renderer.gl=e,this.renderer.CONTEXT_UID=N0++,this.renderer.runners.contextChange.emit(e);const t=this.renderer.view;t.addEventListener!==void 0&&(t.addEventListener("webglcontextlost",this.handleContextLost,!1),t.addEventListener("webglcontextrestored",this.handleContextRestored,!1))}initFromOptions(e){const t=this.createContext(this.renderer.view,e);this.initFromContext(t)}createContext(e,t){let i;if(ke.PREFER_ENV>=ho.WEBGL2&&(i=e.getContext("webgl2",t)),i)this.webGLVersion=2;else if(this.webGLVersion=1,i=e.getContext("webgl",t)||e.getContext("experimental-webgl",t),!i)throw new Error("This browser does not support WebGL. Try using the canvas renderer");return this.gl=i,this.getExtensions(),this.gl}getExtensions(){const{gl:e}=this,t={loseContext:e.getExtension("WEBGL_lose_context"),anisotropicFiltering:e.getExtension("EXT_texture_filter_anisotropic"),floatTextureLinear:e.getExtension("OES_texture_float_linear"),s3tc:e.getExtension("WEBGL_compressed_texture_s3tc"),s3tc_sRGB:e.getExtension("WEBGL_compressed_texture_s3tc_srgb"),etc:e.getExtension("WEBGL_compressed_texture_etc"),etc1:e.getExtension("WEBGL_compressed_texture_etc1"),pvrtc:e.getExtension("WEBGL_compressed_texture_pvrtc")||e.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc"),atc:e.getExtension("WEBGL_compressed_texture_atc"),astc:e.getExtension("WEBGL_compressed_texture_astc"),bptc:e.getExtension("EXT_texture_compression_bptc")};this.webGLVersion===1?Object.assign(this.extensions,t,{drawBuffers:e.getExtension("WEBGL_draw_buffers"),depthTexture:e.getExtension("WEBGL_depth_texture"),vertexArrayObject:e.getExtension("OES_vertex_array_object")||e.getExtension("MOZ_OES_vertex_array_object")||e.getExtension("WEBKIT_OES_vertex_array_object"),uint32ElementIndex:e.getExtension("OES_element_index_uint"),floatTexture:e.getExtension("OES_texture_float"),floatTextureLinear:e.getExtension("OES_texture_float_linear"),textureHalfFloat:e.getExtension("OES_texture_half_float"),textureHalfFloatLinear:e.getExtension("OES_texture_ha Line truncated
varying vec2 vTextureCoord;
uniform sampler2D uSampler;
@@ -422,7 +422,7 @@ void main(void)
gl_FragColor = original;
}
`,eA=`attribute vec2 aVertexPosition;
`,iA=`attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
uniform mat3 projectionMatrix;
@@ -438,7 +438,7 @@ void main(void)
vTextureCoord = aTextureCoord;
vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;
}
`;class tA extends Xi{constructor(e,t,i){let n=null;typeof e!="string"&&t===void 0&&i===void 0&&(n=e,e=void 0,t=void 0,i=void 0),super(e||eA,t||QC,i),this.maskSprite=n,this.maskMatrix=new Dt}get maskSprite(){return this._maskSprite}set maskSprite(e){this._maskSprite=e,this._maskSprite&&(this._maskSprite.renderable=!1)}apply(e,t,i,n){const r=this._maskSprite,o=r._texture;o.valid&&(o.uvMatrix||(o.uvMatrix=new Qm(o,0)),o.uvMatrix.update(),this.uniforms.npmAlpha=o.baseTexture.alphaMode?0:1,this.uniforms.mask=o,this.uniforms.otherMatrix=e.calculateSpriteMatrix(this.maskMatrix,r).prepend(o.uvMatrix.mapCoord),this.uniforms.alpha=r.worldAlpha,this.uniforms.maskClamp=o.uvMatrix.uClampFrame,e.applyFilter(this,t,i,n))}}class iA{constructor(e=null){this.type=ci.NONE,this.autoDetect=!0,this.maskObject=e||null,this.pooled=!1,this.isMaskData=!0,this.resolution=null,this.multisample=Xi.defaultMultisample,this.enabled=!0,this.colorMask=15,this._filters=null,this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null,this._scissorRectLocal=null,this._colorMask=15,this._target=null}get filter(){return this._filters?this._filters[0]:null}set filter(e){e?this._filters?this._filters[0]=e:this._filters=[e]:this._filters=null}reset(){this.pooled&&(this.maskObject=null,this.type=ci.NONE,this.autoDetect=!0),this._target=null,this._scissorRectLocal=null}copyCountersOrReset(e){e?(this._stencilCounter=e._stencilCounter,this._scissorCounter=e._scissorCounter,this._scissorRect=e._scissorRect):(this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null)}}class ib{constructor(e){this.renderer=e,this.enableScissor=!0,this.alphaMaskPool=[],this.maskDataPool=[],this.maskStack=[],this.alphaMaskIndex=0}setMaskStack(e){this.maskStack=e,this.renderer.scissor.setMaskStack(e),this.renderer.stencil.setMaskStack(e)}push(e,t){let i=t;if(!i.isMaskData){const r=this.maskDataPool.pop()||new iA;r.pooled=!0,r.maskObject=t,i=r}const n=this.maskStack.length!==0?this.maskStack[this.maskStack.length-1]:null;if(i.copyCountersOrReset(n),i._colorMask=n?n._colorMask:15,i.autoDetect&&this.detect(i),i._target=e,i.type!==ci.SPRITE&&this.maskStack.push(i),i.enabled)switch(i.type){case ci.SCISSOR:this.renderer.scissor.push(i);break;case ci.STENCIL:this.renderer.stencil.push(i);break;case ci.SPRITE:i.copyCountersOrReset(null),this.pushSpriteMask(i);break;case ci.COLOR:this.pushColorMask(i);break}i.type===ci.SPRITE&&this.maskStack.push(i)}pop(e){const t=this.maskStack.pop();if(!(!t||t._target!==e)){if(t.enabled)switch(t.type){case ci.SCISSOR:this.renderer.scissor.pop(t);break;case ci.STENCIL:this.renderer.stencil.pop(t.maskObject);break;case ci.SPRITE:this.popSpriteMask(t);break;case ci.COLOR:this.popColorMask(t);break}if(t.reset(),t.pooled&&this.maskDataPool.push(t),this.maskStack.length!==0){const i=this.maskStack[this.maskStack.length-1];i.type===ci.SPRITE&&i._filters&&(i._filters[0].maskSprite=i.maskObject)}}}detect(e){const t=e.maskObject;t?t.isSprite?e.type=ci.SPRITE:this.enableScissor&&this.renderer.scissor.testScissor(e)?e.type=ci.SCISSOR:e.type=ci.STENCIL:e.type=ci.COLOR}pushSpriteMask(e){const{maskObject:t}=e,i=e._target;let n=e._filters;n||(n=this.alphaMaskPool[this.alphaMaskIndex],n||(n=this.alphaMaskPool[this.alphaMaskIndex]=[new tA])),n[0].resolution=e.resolution,n[0].multisample=e.multisample,n[0].maskSprite=t;const r=i.filterArea;i.filterArea=t.getBounds(!0),this.renderer.filter.push(i,n),i.filterArea=r,e._filters||this.alphaMaskIndex++}popSpriteMask(e){this.renderer.filter.pop(),e._filters?e._filters[0].maskSprite=null:(this.alphaMaskIndex--,this.alphaMaskPool[this.alphaMaskIndex][0].maskSprite=null)}pushColorMask(e){const t=e._colorMask,i=e._colorMask=t&e.colorMask;i!==t&&this.renderer.gl.colorMask((i&1)!==0,(i&2)!==0,(i&4)!==0,(i&8)!==0)}popColorMask(e){const t=e._colorMask,i=this.maskStack.length>0?this.maskStack[this.maskStack.length-1]._colorMask:15;i!==t&&this.renderer.gl.colorMask((i&1)!==0,(i&2)!==0,(i&4)!==0,(i&8)!==0)}destroy(){this.renderer=null}}ib.extension={type:Re.RendererSystem,name:"mask"};$e.add(ib);class sb{constructor(e){this.renderer=e,this.maskStack=[],this.glConst=0}getStackLength(){return this.maskStack.length}setMaskStack(e){const{gl:t}=this.renderer,i=this.getStackLength();this.maskStack=e;const n=this.getStackLength();n!==i&&(n===0?t.disable(this.glConst):(t.enable(this.glConst),this._useCurrent()))}_useCurrent(){}destroy(){this.renderer=null,this.maskStack=null}}const X0=new Dt,V0=[],nb=class yc extends sb{constructor(e){super(e),this.glConst=ke.ADAPTER.getWebGLRenderingContext().SCISSOR_TEST}getStackLength(){const e=this.maskStack[this.maskStack.length-1];return e?e._scissorCounter:0}calcScissorRect(e){if(e._scissorRectLocal)return;const t=e._scissorRect,{maskObject:i}=e,{renderer:n}=this,r=n.renderTexture,o=i.getBounds(!0,V0.pop()??new st);this.roundFrameToPixels(o,r.current?r.current.resolution:n.resolution,r.sourceFrame,r.destinationFrame,n.projection.transform),t&&o.fit(t),e._scissorRectLocal=o}static Line truncated
`;class sA extends Xi{constructor(e,t,i){let n=null;typeof e!="string"&&t===void 0&&i===void 0&&(n=e,e=void 0,t=void 0,i=void 0),super(e||iA,t||tA,i),this.maskSprite=n,this.maskMatrix=new Ut}get maskSprite(){return this._maskSprite}set maskSprite(e){this._maskSprite=e,this._maskSprite&&(this._maskSprite.renderable=!1)}apply(e,t,i,n){const r=this._maskSprite,o=r._texture;o.valid&&(o.uvMatrix||(o.uvMatrix=new Qm(o,0)),o.uvMatrix.update(),this.uniforms.npmAlpha=o.baseTexture.alphaMode?0:1,this.uniforms.mask=o,this.uniforms.otherMatrix=e.calculateSpriteMatrix(this.maskMatrix,r).prepend(o.uvMatrix.mapCoord),this.uniforms.alpha=r.worldAlpha,this.uniforms.maskClamp=o.uvMatrix.uClampFrame,e.applyFilter(this,t,i,n))}}class nA{constructor(e=null){this.type=ci.NONE,this.autoDetect=!0,this.maskObject=e||null,this.pooled=!1,this.isMaskData=!0,this.resolution=null,this.multisample=Xi.defaultMultisample,this.enabled=!0,this.colorMask=15,this._filters=null,this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null,this._scissorRectLocal=null,this._colorMask=15,this._target=null}get filter(){return this._filters?this._filters[0]:null}set filter(e){e?this._filters?this._filters[0]=e:this._filters=[e]:this._filters=null}reset(){this.pooled&&(this.maskObject=null,this.type=ci.NONE,this.autoDetect=!0),this._target=null,this._scissorRectLocal=null}copyCountersOrReset(e){e?(this._stencilCounter=e._stencilCounter,this._scissorCounter=e._scissorCounter,this._scissorRect=e._scissorRect):(this._stencilCounter=0,this._scissorCounter=0,this._scissorRect=null)}}class nb{constructor(e){this.renderer=e,this.enableScissor=!0,this.alphaMaskPool=[],this.maskDataPool=[],this.maskStack=[],this.alphaMaskIndex=0}setMaskStack(e){this.maskStack=e,this.renderer.scissor.setMaskStack(e),this.renderer.stencil.setMaskStack(e)}push(e,t){let i=t;if(!i.isMaskData){const r=this.maskDataPool.pop()||new nA;r.pooled=!0,r.maskObject=t,i=r}const n=this.maskStack.length!==0?this.maskStack[this.maskStack.length-1]:null;if(i.copyCountersOrReset(n),i._colorMask=n?n._colorMask:15,i.autoDetect&&this.detect(i),i._target=e,i.type!==ci.SPRITE&&this.maskStack.push(i),i.enabled)switch(i.type){case ci.SCISSOR:this.renderer.scissor.push(i);break;case ci.STENCIL:this.renderer.stencil.push(i);break;case ci.SPRITE:i.copyCountersOrReset(null),this.pushSpriteMask(i);break;case ci.COLOR:this.pushColorMask(i);break}i.type===ci.SPRITE&&this.maskStack.push(i)}pop(e){const t=this.maskStack.pop();if(!(!t||t._target!==e)){if(t.enabled)switch(t.type){case ci.SCISSOR:this.renderer.scissor.pop(t);break;case ci.STENCIL:this.renderer.stencil.pop(t.maskObject);break;case ci.SPRITE:this.popSpriteMask(t);break;case ci.COLOR:this.popColorMask(t);break}if(t.reset(),t.pooled&&this.maskDataPool.push(t),this.maskStack.length!==0){const i=this.maskStack[this.maskStack.length-1];i.type===ci.SPRITE&&i._filters&&(i._filters[0].maskSprite=i.maskObject)}}}detect(e){const t=e.maskObject;t?t.isSprite?e.type=ci.SPRITE:this.enableScissor&&this.renderer.scissor.testScissor(e)?e.type=ci.SCISSOR:e.type=ci.STENCIL:e.type=ci.COLOR}pushSpriteMask(e){const{maskObject:t}=e,i=e._target;let n=e._filters;n||(n=this.alphaMaskPool[this.alphaMaskIndex],n||(n=this.alphaMaskPool[this.alphaMaskIndex]=[new sA])),n[0].resolution=e.resolution,n[0].multisample=e.multisample,n[0].maskSprite=t;const r=i.filterArea;i.filterArea=t.getBounds(!0),this.renderer.filter.push(i,n),i.filterArea=r,e._filters||this.alphaMaskIndex++}popSpriteMask(e){this.renderer.filter.pop(),e._filters?e._filters[0].maskSprite=null:(this.alphaMaskIndex--,this.alphaMaskPool[this.alphaMaskIndex][0].maskSprite=null)}pushColorMask(e){const t=e._colorMask,i=e._colorMask=t&e.colorMask;i!==t&&this.renderer.gl.colorMask((i&1)!==0,(i&2)!==0,(i&4)!==0,(i&8)!==0)}popColorMask(e){const t=e._colorMask,i=this.maskStack.length>0?this.maskStack[this.maskStack.length-1]._colorMask:15;i!==t&&this.renderer.gl.colorMask((i&1)!==0,(i&2)!==0,(i&4)!==0,(i&8)!==0)}destroy(){this.renderer=null}}nb.extension={type:Re.RendererSystem,name:"mask"};Ue.add(nb);class rb{constructor(e){this.renderer=e,this.maskStack=[],this.glConst=0}getStackLength(){return this.maskStack.length}setMaskStack(e){const{gl:t}=this.renderer,i=this.getStackLength();this.maskStack=e;const n=this.getStackLength();n!==i&&(n===0?t.disable(this.glConst):(t.enable(this.glConst),this._useCurrent()))}_useCurrent(){}destroy(){this.renderer=null,this.maskStack=null}}const X0=new Ut,V0=[],ob=class yc extends rb{constructor(e){super(e),this.glConst=ke.ADAPTER.getWebGLRenderingContext().SCISSOR_TEST}getStackLength(){const e=this.maskStack[this.maskStack.length-1];return e?e._scissorCounter:0}calcScissorRect(e){if(e._scissorRectLocal)return;const t=e._scissorRect,{maskObject:i}=e,{renderer:n}=this,r=n.renderTexture,o=i.getBounds(!0,V0.pop()??new rt);this.roundFrameToPixels(o,r.current?r.current.resolution:n.resolution,r.sourceFrame,r.destinationFrame,n.projection.transform),t&&o.fit(t),e._scissorRectLocal=o}static Line truncated
data[offset] = v;
`,vec2:`
data[offset] = v[0];
@@ -476,7 +476,7 @@ void main(void)
{
data[offset + i] = v[i];
}
`},hb={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 uA(s){const e=s.map(r=>({data:r,offset:0,dataLen:0,dirty:0}));let t=0,i=0,n=0;for(let r=0;r<e.length;r++){const o=e[r];if(t=hb[o.data.type],o.data.size>1&&(t=Math.max(t,16)*o.data.size),o.dataLen=t,i%t!==0&&i<16){const a=i%t%16;i+=a,n+=a}i+t>16?(n=Math.ceil(n/16)*16,o.offset=n,n+=t,i=t):(o.offset=n,i+=t,n+=t)}return n=Math.ceil(n/16)*16,{uboElements:e,size:n}}function dA(s,e){const t=[];for(const i in s)e[i]&&t.push(e[i]);return t.sort((i,n)=>i.index-n.index),t}function fA(s,e){if(!s.autoManage)return{size:0,syncFunc:cA};const t=dA(s.uniforms,e),{uboElements:i,size:n}=uA(t),r=[`
`},db={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 fA(s){const e=s.map(r=>({data:r,offset:0,dataLen:0,dirty:0}));let t=0,i=0,n=0;for(let r=0;r<e.length;r++){const o=e[r];if(t=db[o.data.type],o.data.size>1&&(t=Math.max(t,16)*o.data.size),o.dataLen=t,i%t!==0&&i<16){const a=i%t%16;i+=a,n+=a}i+t>16?(n=Math.ceil(n/16)*16,o.offset=n,n+=t,i=t):(o.offset=n,i+=t,n+=t)}return n=Math.ceil(n/16)*16,{uboElements:e,size:n}}function mA(s,e){const t=[];for(const i in s)e[i]&&t.push(e[i]);return t.sort((i,n)=>i.index-n.index),t}function pA(s,e){if(!s.autoManage)return{size:0,syncFunc:uA};const t=mA(s.uniforms,e),{uboElements:i,size:n}=fA(t),r=[`
var v = null;
var v2 = null;
var cv = null;
@@ -484,7 +484,7 @@ void main(void)
var gl = renderer.gl
var index = 0;
var data = buffer.data;
`];for(let o=0;o<i.length;o++){const a=i[o],c=s.uniforms[a.data.name],l=a.data.name;let h=!1;for(let u=0;u<Yo.length;u++){const d=Yo[u];if(d.codeUbo&&d.test(a.data,c)){r.push(`offset = ${a.offset/4};`,Yo[u].codeUbo(a.data.name,c)),h=!0;break}}if(!h)if(a.data.size>1){const u=Hy(a.data.type),d=Math.max(hb[a.data.type]/16,1),f=u/d,p=(4-f%4)%4;r.push(`
`];for(let o=0;o<i.length;o++){const a=i[o],c=s.uniforms[a.data.name],l=a.data.name;let h=!1;for(let u=0;u<Ho.length;u++){const d=Ho[u];if(d.codeUbo&&d.test(a.data,c)){r.push(`offset = ${a.offset/4};`,Ho[u].codeUbo(a.data.name,c)),h=!0;break}}if(!h)if(a.data.size>1){const u=Wy(a.data.type),d=Math.max(db[a.data.type]/16,1),f=u/d,p=(4-f%4)%4;r.push(`
cv = ud.${l}.value;
v = uv.${l};
offset = ${a.offset/4};
@@ -500,7 +500,7 @@ void main(void)
offset += ${p};
}
`)}else{const u=hA[a.data.type];r.push(`
`)}else{const u=dA[a.data.type];r.push(`
cv = ud.${l}.value;
v = uv.${l};
offset = ${a.offset/4};
@@ -508,7 +508,7 @@ void main(void)
`)}}return r.push(`
renderer.buffer.update(buffer);
`),{size:n,syncFunc:new Function("ud","uv","renderer","syncData","buffer",r.join(`
`))}}let mA=0;const jl={textureCount:0,uboCount:0};class ub{constructor(e){this.destroyed=!1,this.renderer=e,this.systemCheck(),this.gl=null,this.shader=null,this.program=null,this.cache={},this._uboCache={},this.id=mA++}systemCheck(){if(!$C())throw new Error("Current environment does not allow unsafe-eval, please use @pixi/unsafe-eval module to enable support.")}contextChange(e){this.gl=e,this.reset()}bind(e,t){e.disposeRunner.add(this),e.uniforms.globals=this.renderer.globalUniforms;const i=e.program,n=i.glPrograms[this.renderer.CONTEXT_UID]||this.generateProgram(e);return this.shader=e,this.program!==i&&(this.program=i,this.gl.useProgram(n.program)),t||(jl.textureCount=0,jl.uboCount=0,this.syncUniformGroup(e.uniformGroup,jl)),n}setUniforms(e){const t=this.shader.program,i=t.glPrograms[this.renderer.CONTEXT_UID];t.syncUniforms(i.uniformData,e,this.renderer)}syncUniformGroup(e,t){const i=this.getGlProgram();(!e.static||e.dirtyId!==i.uniformDirtyGroups[e.id])&&(i.uniformDirtyGroups[e.id]=e.dirtyId,this.syncUniforms(e,i,t))}syncUniforms(e,t,i){(e.syncUniforms[this.shader.program.id]||this.createSyncGroups(e))(t.uniformData,e.uniforms,this.renderer,i)}createSyncGroups(e){const t=this.getSignature(e,this.shader.program.uniformData,"u");return this.cache[t]||(this.cache[t]=BC(e,this.shader.program.uniformData)),e.syncUniforms[this.shader.program.id]=this.cache[t],e.syncUniforms[this.shader.program.id]}syncUniformBufferGroup(e,t){const i=this.getGlProgram();if(!e.static||e.dirtyId!==0||!i.uniformGroups[e.id]){e.dirtyId=0;const n=i.uniformGroups[e.id]||this.createSyncBufferGroup(e,i,t);e.buffer.update(),n(i.uniformData,e.uniforms,this.renderer,jl,e.buffer)}this.renderer.buffer.bindBufferBase(e.buffer,i.uniformBufferBindings[t])}createSyncBufferGroup(e,t,i){const{gl:n}=this.renderer;this.renderer.buffer.bind(e.buffer);const r=this.gl.getUniformBlockIndex(t.program,i);t.uniformBufferBindings[i]=this.shader.uniformBindCount,n.uniformBlockBinding(t.program,r,this.shader.uniformBindCount),this.shader.uniformBindCount++;const o=this.getSignature(e,this.shader.program.uniformData,"ubo");let a=this._uboCache[o];if(a||(a=this._uboCache[o]=fA(e,this.shader.program.uniformData)),e.autoManage){const c=new Float32Array(a.size/4);e.buffer.update(c)}return t.uniformGroups[e.id]=a.syncFunc,t.uniformGroups[e.id]}getSignature(e,t,i){const n=e.uniforms,r=[`${i}-`];for(const o in n)r.push(o),t[o]&&r.push(t[o].type);return r.join("-")}getGlProgram(){return this.shader?this.shader.program.glPrograms[this.renderer.CONTEXT_UID]:null}generateProgram(e){const t=this.gl,i=e.program,n=lA(t,i);return i.glPrograms[this.renderer.CONTEXT_UID]=n,n}reset(){this.program=null,this.shader=null}disposeShader(e){this.shader===e&&(this.shader=null)}destroy(){this.renderer=null,this.destroyed=!0}}ub.extension={type:Re.RendererSystem,name:"shader"};$e.add(ub);class Kc{constructor(e){this.renderer=e}run(e){const{renderer:t}=this;t.runners.init.emit(t.options),e.hello&&console.log(`PixiJS 7.4.3 - ${t.rendererLogId} - https://pixijs.com`),t.resize(t.screen.width,t.screen.height)}destroy(){}}Kc.defaultOptions={hello:!1},Kc.extension={type:[Re.RendererSystem,Re.CanvasRendererSystem],name:"startup"};$e.add(Kc);function pA(s,e=[]){return e[je.NORMAL]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.ADD]=[s.ONE,s.ONE],e[je.MULTIPLY]=[s.DST_COLOR,s.ONE_MINUS_SRC_ALPHA,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.SCREEN]=[s.ONE,s.ONE_MINUS_SRC_COLOR,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.OVERLAY]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.DARKEN]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.LIGHTEN]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.COLOR_DODGE]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.COLOR_BURN]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.HARD_LIGHT]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.SOFT_LIGHT]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.DIFFERENCE]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.EXCLUSION]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.HUE]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.SATURATION]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.COLOR]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.LUMINOSITY]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.NONE]=[0,0],e[je.NORMAL_NPM]=[s.SRC_ALPHA,s.ONE_MINUS_SRC_ALPHA,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.ADD_NPM]=[s.SRC_ALPHA,s.ONE,s.ONE,s.ONE],e[je.SCREEN_NPM]=[s.SRC_ALPHA,s.ONE_MINUS_SRC_COLOR,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[je.SRC_IN]=[s.DST_ALPHA,s.ZERO],e[je.SRC_OUT]=[s.ONE_MINUS_DST_ALPHA,s.ZERO],e[je.SRC_ATOP]=[s.DST_ALPHA,s.ONE_MINUS_SRC_ALPHA],e[je.DST_OVER]=[s.ONE_MINUS_DST_ALPHA,s.ONE],e[je.DST_IN]=[s.ZERO,s.SRC_ALPHA],e[je.DST_OUT]=[s.ZERO,s.ONE_MINUS_SRC_ALPHA],e[je.DST_ATOP]=[s.ONE_MINUS_DST_ALPHA,s.SRC_ALPHA],e[je.XOR]=[s.ONE_MINUS_DST_ALPHA,s.ONE_MINUS_SRC_ALPHA],e[je.SUBTRACT]=[s.ONE,s.ONE,s.ONE,s.ONE,s.FUNC_REVERSE_SUBTRACT,s.FUNC_ADD],e}const gA=0,vA=1,xA=2,yA=3,bA=4,wA=5,db=class Of{constructor(){this.gl=null,this.stateId=0,this.polygonOffset=0,this.blendMode=je.NONE,this._blendEq=!1,this.map=[],this.map[gA]=this.setBlend,this.map[vA]=this.setOffset,this.map[xA]=this.setCullFace,this.map[yA]=this.setDepthTest,this.ma Line truncated
`))}}let gA=0;const jl={textureCount:0,uboCount:0};class fb{constructor(e){this.destroyed=!1,this.renderer=e,this.systemCheck(),this.gl=null,this.shader=null,this.program=null,this.cache={},this._uboCache={},this.id=gA++}systemCheck(){if(!VC())throw new Error("Current environment does not allow unsafe-eval, please use @pixi/unsafe-eval module to enable support.")}contextChange(e){this.gl=e,this.reset()}bind(e,t){e.disposeRunner.add(this),e.uniforms.globals=this.renderer.globalUniforms;const i=e.program,n=i.glPrograms[this.renderer.CONTEXT_UID]||this.generateProgram(e);return this.shader=e,this.program!==i&&(this.program=i,this.gl.useProgram(n.program)),t||(jl.textureCount=0,jl.uboCount=0,this.syncUniformGroup(e.uniformGroup,jl)),n}setUniforms(e){const t=this.shader.program,i=t.glPrograms[this.renderer.CONTEXT_UID];t.syncUniforms(i.uniformData,e,this.renderer)}syncUniformGroup(e,t){const i=this.getGlProgram();(!e.static||e.dirtyId!==i.uniformDirtyGroups[e.id])&&(i.uniformDirtyGroups[e.id]=e.dirtyId,this.syncUniforms(e,i,t))}syncUniforms(e,t,i){(e.syncUniforms[this.shader.program.id]||this.createSyncGroups(e))(t.uniformData,e.uniforms,this.renderer,i)}createSyncGroups(e){const t=this.getSignature(e,this.shader.program.uniformData,"u");return this.cache[t]||(this.cache[t]=DC(e,this.shader.program.uniformData)),e.syncUniforms[this.shader.program.id]=this.cache[t],e.syncUniforms[this.shader.program.id]}syncUniformBufferGroup(e,t){const i=this.getGlProgram();if(!e.static||e.dirtyId!==0||!i.uniformGroups[e.id]){e.dirtyId=0;const n=i.uniformGroups[e.id]||this.createSyncBufferGroup(e,i,t);e.buffer.update(),n(i.uniformData,e.uniforms,this.renderer,jl,e.buffer)}this.renderer.buffer.bindBufferBase(e.buffer,i.uniformBufferBindings[t])}createSyncBufferGroup(e,t,i){const{gl:n}=this.renderer;this.renderer.buffer.bind(e.buffer);const r=this.gl.getUniformBlockIndex(t.program,i);t.uniformBufferBindings[i]=this.shader.uniformBindCount,n.uniformBlockBinding(t.program,r,this.shader.uniformBindCount),this.shader.uniformBindCount++;const o=this.getSignature(e,this.shader.program.uniformData,"ubo");let a=this._uboCache[o];if(a||(a=this._uboCache[o]=pA(e,this.shader.program.uniformData)),e.autoManage){const c=new Float32Array(a.size/4);e.buffer.update(c)}return t.uniformGroups[e.id]=a.syncFunc,t.uniformGroups[e.id]}getSignature(e,t,i){const n=e.uniforms,r=[`${i}-`];for(const o in n)r.push(o),t[o]&&r.push(t[o].type);return r.join("-")}getGlProgram(){return this.shader?this.shader.program.glPrograms[this.renderer.CONTEXT_UID]:null}generateProgram(e){const t=this.gl,i=e.program,n=hA(t,i);return i.glPrograms[this.renderer.CONTEXT_UID]=n,n}reset(){this.program=null,this.shader=null}disposeShader(e){this.shader===e&&(this.shader=null)}destroy(){this.renderer=null,this.destroyed=!0}}fb.extension={type:Re.RendererSystem,name:"shader"};Ue.add(fb);class Kc{constructor(e){this.renderer=e}run(e){const{renderer:t}=this;t.runners.init.emit(t.options),e.hello&&console.log(`PixiJS 7.4.3 - ${t.rendererLogId} - https://pixijs.com`),t.resize(t.screen.width,t.screen.height)}destroy(){}}Kc.defaultOptions={hello:!1},Kc.extension={type:[Re.RendererSystem,Re.CanvasRendererSystem],name:"startup"};Ue.add(Kc);function vA(s,e=[]){return e[He.NORMAL]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.ADD]=[s.ONE,s.ONE],e[He.MULTIPLY]=[s.DST_COLOR,s.ONE_MINUS_SRC_ALPHA,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.SCREEN]=[s.ONE,s.ONE_MINUS_SRC_COLOR,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.OVERLAY]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.DARKEN]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.LIGHTEN]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.COLOR_DODGE]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.COLOR_BURN]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.HARD_LIGHT]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.SOFT_LIGHT]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.DIFFERENCE]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.EXCLUSION]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.HUE]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.SATURATION]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.COLOR]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.LUMINOSITY]=[s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.NONE]=[0,0],e[He.NORMAL_NPM]=[s.SRC_ALPHA,s.ONE_MINUS_SRC_ALPHA,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.ADD_NPM]=[s.SRC_ALPHA,s.ONE,s.ONE,s.ONE],e[He.SCREEN_NPM]=[s.SRC_ALPHA,s.ONE_MINUS_SRC_COLOR,s.ONE,s.ONE_MINUS_SRC_ALPHA],e[He.SRC_IN]=[s.DST_ALPHA,s.ZERO],e[He.SRC_OUT]=[s.ONE_MINUS_DST_ALPHA,s.ZERO],e[He.SRC_ATOP]=[s.DST_ALPHA,s.ONE_MINUS_SRC_ALPHA],e[He.DST_OVER]=[s.ONE_MINUS_DST_ALPHA,s.ONE],e[He.DST_IN]=[s.ZERO,s.SRC_ALPHA],e[He.DST_OUT]=[s.ZERO,s.ONE_MINUS_SRC_ALPHA],e[He.DST_ATOP]=[s.ONE_MINUS_DST_ALPHA,s.SRC_ALPHA],e[He.XOR]=[s.ONE_MINUS_DST_ALPHA,s.ONE_MINUS_SRC_ALPHA],e[He.SUBTRACT]=[s.ONE,s.ONE,s.ONE,s.ONE,s.FUNC_REVERSE_SUBTRACT,s.FUNC_ADD],e}const xA=0,yA=1,bA=2,wA=3,SA=4,TA=5,mb=class Of{constructor(){this.gl=null,this.stateId=0,this.polygonOffset=0,this.blendMode=He.NONE,this._blendEq=!1,this.map=[],this.map[xA]=this.setBlend,this.map[yA]=this.setOffset,this.map[bA]=this.setCullFace,this.map[wA]=this.setDepthTest,this.ma Line truncated
attribute vec2 aTextureCoord;
uniform mat3 projectionMatrix;
@@ -519,7 +519,7 @@ void main(void)
{
gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);
vTextureCoord = aTextureCoord;
}`,EA=`attribute vec2 aVertexPosition;
}`,RA=`attribute vec2 aVertexPosition;
uniform mat3 projectionMatrix;
@@ -545,7 +545,7 @@ void main(void)
gl_Position = filterVertexPosition();
vTextureCoord = filterTextureCoord();
}
`;const IA=AA,xb=EA;class yb{constructor(e){this.renderer=e}contextChange(e){let t;if(this.renderer.context.webGLVersion===1){const i=e.getParameter(e.FRAMEBUFFER_BINDING);e.bindFramebuffer(e.FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.FRAMEBUFFER,i)}else{const i=e.getParameter(e.DRAW_FRAMEBUFFER_BINDING);e.bindFramebuffer(e.DRAW_FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.DRAW_FRAMEBUFFER,i)}t>=oi.HIGH?this.multisample=oi.HIGH:t>=oi.MEDIUM?this.multisample=oi.MEDIUM:t>=oi.LOW?this.multisample=oi.LOW:this.multisample=oi.NONE}destroy(){}}yb.extension={type:Re.RendererSystem,name:"_multisample"};$e.add(yb);class RA{constructor(e){this.buffer=e||null,this.updateID=-1,this.byteLength=-1,this.refCount=0}}class bb{constructor(e){this.renderer=e,this.managedBuffers={},this.boundBufferBases={}}destroy(){this.renderer=null}contextChange(){this.disposeAll(!0),this.gl=this.renderer.gl,this.CONTEXT_UID=this.renderer.CONTEXT_UID}bind(e){const{gl:t,CONTEXT_UID:i}=this,n=e._glBuffers[i]||this.createGLBuffer(e);t.bindBuffer(e.type,n.buffer)}unbind(e){const{gl:t}=this;t.bindBuffer(e,null)}bindBufferBase(e,t){const{gl:i,CONTEXT_UID:n}=this;if(this.boundBufferBases[t]!==e){const r=e._glBuffers[n]||this.createGLBuffer(e);this.boundBufferBases[t]=e,i.bindBufferBase(i.UNIFORM_BUFFER,t,r.buffer)}}bindBufferRange(e,t,i){const{gl:n,CONTEXT_UID:r}=this;i=i||0;const o=e._glBuffers[r]||this.createGLBuffer(e);n.bindBufferRange(n.UNIFORM_BUFFER,t||0,o.buffer,i*256,256)}update(e){const{gl:t,CONTEXT_UID:i}=this,n=e._glBuffers[i]||this.createGLBuffer(e);if(e._updateID!==n.updateID)if(n.updateID=e._updateID,t.bindBuffer(e.type,n.buffer),n.byteLength>=e.data.byteLength)t.bufferSubData(e.type,0,e.data);else{const r=e.static?t.STATIC_DRAW:t.DYNAMIC_DRAW;n.byteLength=e.data.byteLength,t.bufferData(e.type,e.data,r)}}dispose(e,t){if(!this.managedBuffers[e.id])return;delete this.managedBuffers[e.id];const i=e._glBuffers[this.CONTEXT_UID],n=this.gl;e.disposeRunner.remove(this),i&&(t||n.deleteBuffer(i.buffer),delete e._glBuffers[this.CONTEXT_UID])}disposeAll(e){const t=Object.keys(this.managedBuffers);for(let i=0;i<t.length;i++)this.dispose(this.managedBuffers[t[i]],e)}createGLBuffer(e){const{CONTEXT_UID:t,gl:i}=this;return e._glBuffers[t]=new RA(i.createBuffer()),this.managedBuffers[e.id]=e,e.disposeRunner.add(this),e._glBuffers[t]}}bb.extension={type:Re.RendererSystem,name:"buffer"};$e.add(bb);class wb{constructor(e){this.renderer=e}render(e,t){const i=this.renderer;let n,r,o,a;if(t&&(n=t.renderTexture,r=t.clear,o=t.transform,a=t.skipUpdateTransform),this.renderingToScreen=!n,i.runners.prerender.emit(),i.emit("prerender"),i.projection.transform=o,!i.context.isLost){if(n||(this.lastObjectRendered=e),!a){const c=e.enableTempParent();e.updateTransform(),e.disableTempParent(c)}i.renderTexture.bind(n),i.batch.currentRenderer.start(),(r??i.background.clearBeforeRender)&&i.renderTexture.clear(),e.render(i),i.batch.currentRenderer.flush(),n&&(t.blit&&i.framebuffer.blit(),n.baseTexture.update()),i.runners.postrender.emit(),i.projection.transform=null,i.emit("postrender")}}destroy(){this.renderer=null,this.lastObjectRendered=null}}wb.extension={type:Re.RendererSystem,name:"objectRenderer"};$e.add(wb);const wc=class Bf extends TA{constructor(e){super(),this.type=wy.WEBGL,e=Object.assign({},ke.RENDER_OPTIONS,e),this.gl=null,this.CONTEXT_UID=0,this.globalUniforms=new Rs({projectionMatrix:new Dt},!0);const t={runners:["init","destroy","contextChange","resolutionChange","reset","update","postrender","prerender","resize"],systems:Bf.__systems,priority:["_view","textureGenerator","background","_plugin","startup","context","state","texture","buffer","geometry","framebuffer","transformFeedback","mask","scissor","stencil","projection","textureGC","filter","renderTexture","batch","objectRenderer","_multisample"]};this.setup(t),"useContextAlpha"in e&&(lt("7.0.0","options.useContextAlpha is deprecated, use options.premultipliedAlpha and options.backgroundAlpha instead"),e.premultipliedAlpha=e.useContextAlpha&&e.useContextAlpha!=="notMultiplied",e.backgroundAlpha=e.useContextAlpha===!1?1:e.backgroundAlpha),this._plugin.rendererPlugins=Bf.__plugins,this.options=e,this.startup.run(this.options)}static test(e){return e!=null&&e.forceCanvas?!1:eC()}render(e,t){this.objectRenderer.render(e,t)}resize(e,t){this._view.resizeView(e,t)}reset(){return this.runners.reset.emit(),this}clear(){this.renderTexture.bind(),this.renderTexture.clear()}destroy(e=!1){this.runners.destroy.items.reverse(),this.emitWithCustomOptions(this.runners.destroy,{_view:e}),super.destroy()}get plugins(){return this._plugin.plugins}get multisample(){return this._multisample.multisample}get width(){return this._view.element.width}get height(){return this._view.element.height}get resolution(){return this._view.resolution}set resolution(e){this._view.resolution=e,this.runners.resolutionChange.emit(e)}get autoDensity(){return this._view.autoDensity}get view(){return Line truncated
`;const PA=IA,bb=RA;class wb{constructor(e){this.renderer=e}contextChange(e){let t;if(this.renderer.context.webGLVersion===1){const i=e.getParameter(e.FRAMEBUFFER_BINDING);e.bindFramebuffer(e.FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.FRAMEBUFFER,i)}else{const i=e.getParameter(e.DRAW_FRAMEBUFFER_BINDING);e.bindFramebuffer(e.DRAW_FRAMEBUFFER,null),t=e.getParameter(e.SAMPLES),e.bindFramebuffer(e.DRAW_FRAMEBUFFER,i)}t>=ai.HIGH?this.multisample=ai.HIGH:t>=ai.MEDIUM?this.multisample=ai.MEDIUM:t>=ai.LOW?this.multisample=ai.LOW:this.multisample=ai.NONE}destroy(){}}wb.extension={type:Re.RendererSystem,name:"_multisample"};Ue.add(wb);class kA{constructor(e){this.buffer=e||null,this.updateID=-1,this.byteLength=-1,this.refCount=0}}class Sb{constructor(e){this.renderer=e,this.managedBuffers={},this.boundBufferBases={}}destroy(){this.renderer=null}contextChange(){this.disposeAll(!0),this.gl=this.renderer.gl,this.CONTEXT_UID=this.renderer.CONTEXT_UID}bind(e){const{gl:t,CONTEXT_UID:i}=this,n=e._glBuffers[i]||this.createGLBuffer(e);t.bindBuffer(e.type,n.buffer)}unbind(e){const{gl:t}=this;t.bindBuffer(e,null)}bindBufferBase(e,t){const{gl:i,CONTEXT_UID:n}=this;if(this.boundBufferBases[t]!==e){const r=e._glBuffers[n]||this.createGLBuffer(e);this.boundBufferBases[t]=e,i.bindBufferBase(i.UNIFORM_BUFFER,t,r.buffer)}}bindBufferRange(e,t,i){const{gl:n,CONTEXT_UID:r}=this;i=i||0;const o=e._glBuffers[r]||this.createGLBuffer(e);n.bindBufferRange(n.UNIFORM_BUFFER,t||0,o.buffer,i*256,256)}update(e){const{gl:t,CONTEXT_UID:i}=this,n=e._glBuffers[i]||this.createGLBuffer(e);if(e._updateID!==n.updateID)if(n.updateID=e._updateID,t.bindBuffer(e.type,n.buffer),n.byteLength>=e.data.byteLength)t.bufferSubData(e.type,0,e.data);else{const r=e.static?t.STATIC_DRAW:t.DYNAMIC_DRAW;n.byteLength=e.data.byteLength,t.bufferData(e.type,e.data,r)}}dispose(e,t){if(!this.managedBuffers[e.id])return;delete this.managedBuffers[e.id];const i=e._glBuffers[this.CONTEXT_UID],n=this.gl;e.disposeRunner.remove(this),i&&(t||n.deleteBuffer(i.buffer),delete e._glBuffers[this.CONTEXT_UID])}disposeAll(e){const t=Object.keys(this.managedBuffers);for(let i=0;i<t.length;i++)this.dispose(this.managedBuffers[t[i]],e)}createGLBuffer(e){const{CONTEXT_UID:t,gl:i}=this;return e._glBuffers[t]=new kA(i.createBuffer()),this.managedBuffers[e.id]=e,e.disposeRunner.add(this),e._glBuffers[t]}}Sb.extension={type:Re.RendererSystem,name:"buffer"};Ue.add(Sb);class Tb{constructor(e){this.renderer=e}render(e,t){const i=this.renderer;let n,r,o,a;if(t&&(n=t.renderTexture,r=t.clear,o=t.transform,a=t.skipUpdateTransform),this.renderingToScreen=!n,i.runners.prerender.emit(),i.emit("prerender"),i.projection.transform=o,!i.context.isLost){if(n||(this.lastObjectRendered=e),!a){const c=e.enableTempParent();e.updateTransform(),e.disableTempParent(c)}i.renderTexture.bind(n),i.batch.currentRenderer.start(),(r??i.background.clearBeforeRender)&&i.renderTexture.clear(),e.render(i),i.batch.currentRenderer.flush(),n&&(t.blit&&i.framebuffer.blit(),n.baseTexture.update()),i.runners.postrender.emit(),i.projection.transform=null,i.emit("postrender")}}destroy(){this.renderer=null,this.lastObjectRendered=null}}Tb.extension={type:Re.RendererSystem,name:"objectRenderer"};Ue.add(Tb);const wc=class Bf extends _A{constructor(e){super(),this.type=Ty.WEBGL,e=Object.assign({},ke.RENDER_OPTIONS,e),this.gl=null,this.CONTEXT_UID=0,this.globalUniforms=new Ps({projectionMatrix:new Ut},!0);const t={runners:["init","destroy","contextChange","resolutionChange","reset","update","postrender","prerender","resize"],systems:Bf.__systems,priority:["_view","textureGenerator","background","_plugin","startup","context","state","texture","buffer","geometry","framebuffer","transformFeedback","mask","scissor","stencil","projection","textureGC","filter","renderTexture","batch","objectRenderer","_multisample"]};this.setup(t),"useContextAlpha"in e&&(ht("7.0.0","options.useContextAlpha is deprecated, use options.premultipliedAlpha and options.backgroundAlpha instead"),e.premultipliedAlpha=e.useContextAlpha&&e.useContextAlpha!=="notMultiplied",e.backgroundAlpha=e.useContextAlpha===!1?1:e.backgroundAlpha),this._plugin.rendererPlugins=Bf.__plugins,this.options=e,this.startup.run(this.options)}static test(e){return e!=null&&e.forceCanvas?!1:iC()}render(e,t){this.objectRenderer.render(e,t)}resize(e,t){this._view.resizeView(e,t)}reset(){return this.runners.reset.emit(),this}clear(){this.renderTexture.bind(),this.renderTexture.clear()}destroy(e=!1){this.runners.destroy.items.reverse(),this.emitWithCustomOptions(this.runners.destroy,{_view:e}),super.destroy()}get plugins(){return this._plugin.plugins}get multisample(){return this._multisample.multisample}get width(){return this._view.element.width}get height(){return this._view.element.height}get resolution(){return this._view.resolution}set resolution(e){this._view.resolution=e,this.runners.resolutionChange.emit(e)}get autoDensity(){return this._view.autoDensity}get view(){return Line truncated
uniform sampler2D uSampler;
uniform float uAlpha;
@@ -554,9 +554,9 @@ void main(void)
{
gl_FragColor = texture2D(uSampler, vTextureCoord) * uAlpha;
}
`;class XA extends Xi{constructor(e=1){super(IA,$A,{uAlpha:1}),this.alpha=e}get alpha(){return this.uniforms.uAlpha}set alpha(e){this.uniforms.uAlpha=e}}const VA={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]},YA=["varying vec2 vBlurTexCoords[%size%];","uniform sampler2D uSampler;","void main(void)","{"," gl_FragColor = vec4(0.0);"," %blur%","}"].join(`
`);function GA(s){const e=VA[s],t=e.length;let i=YA,n="";const r="gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;";let o;for(let a=0;a<s;a++){let c=r.replace("%index%",a.toString());o=a,a>=t&&(o=s-a-1),c=c.replace("%value%",e[o].toString()),n+=c,n+=`
`}return i=i.replace("%blur%",n),i=i.replace("%size%",s.toString()),i}const HA=`
`;class YA extends Xi{constructor(e=1){super(PA,VA,{uAlpha:1}),this.alpha=e}get alpha(){return this.uniforms.uAlpha}set alpha(e){this.uniforms.uAlpha=e}}const GA={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]},HA=["varying vec2 vBlurTexCoords[%size%];","uniform sampler2D uSampler;","void main(void)","{"," gl_FragColor = vec4(0.0);"," %blur%","}"].join(`
`);function jA(s){const e=GA[s],t=e.length;let i=HA,n="";const r="gl_FragColor += texture2D(uSampler, vBlurTexCoords[%index%]) * %value%;";let o;for(let a=0;a<s;a++){let c=r.replace("%index%",a.toString());o=a,a>=t&&(o=s-a-1),c=c.replace("%value%",e[o].toString()),n+=c,n+=`
`}return i=i.replace("%blur%",n),i=i.replace("%size%",s.toString()),i}const WA=`
attribute vec2 aVertexPosition;
uniform mat3 projectionMatrix;
@@ -586,8 +586,8 @@ void main(void)
vec2 textureCoord = filterTextureCoord();
%blur%
}`;function jA(s,e){const t=Math.ceil(s/2);let i=HA,n="",r;e?r="vBlurTexCoords[%index%] = textureCoord + vec2(%sampleIndex% * strength, 0.0);":r="vBlurTexCoords[%index%] = textureCoord + vec2(0.0, %sampleIndex% * strength);";for(let o=0;o<s;o++){let a=r.replace("%index%",o.toString());a=a.replace("%sampleIndex%",`${o-(t-1)}.0`),n+=a,n+=`
`}return i=i.replace("%blur%",n),i=i.replace("%size%",s.toString()),i}class Xf extends Xi{constructor(e,t=8,i=4,n=Xi.defaultResolution,r=5){const o=jA(r,e),a=GA(r);super(o,a),this.horizontal=e,this.resolution=n,this._quality=0,this.quality=i,this.blur=t}apply(e,t,i,n){if(i?this.horizontal?this.uniforms.strength=1/i.width*(i.width/t.width):this.uniforms.strength=1/i.height*(i.height/t.height):this.horizontal?this.uniforms.strength=1/e.renderer.width*(e.renderer.width/t.width):this.uniforms.strength=1/e.renderer.height*(e.renderer.height/t.height),this.uniforms.strength*=this.strength,this.uniforms.strength/=this.passes,this.passes===1)e.applyFilter(this,t,i,n);else{const r=e.getFilterTexture(),o=e.renderer;let a=t,c=r;this.state.blend=!1,e.applyFilter(this,a,c,zs.CLEAR);for(let l=1;l<this.passes-1;l++){e.bindAndClear(a,zs.BLIT),this.uniforms.uSampler=c;const h=c;c=a,a=h,o.shader.bind(this),o.geometry.draw(5)}this.state.blend=!0,e.applyFilter(this,c,i,n),e.returnFilterTexture(r)}}get blur(){return this.strength}set blur(e){this.padding=1+Math.abs(e)*2,this.strength=e}get quality(){return this._quality}set quality(e){this._quality=e,this.passes=e}}class WA extends Xi{constructor(e=8,t=4,i=Xi.defaultResolution,n=5){super(),this._repeatEdgePixels=!1,this.blurXFilter=new Xf(!0,e,t,i,n),this.blurYFilter=new Xf(!1,e,t,i,n),this.resolution=i,this.quality=t,this.blur=e,this.repeatEdgePixels=!1}apply(e,t,i,n){const r=Math.abs(this.blurXFilter.strength),o=Math.abs(this.blurYFilter.strength);if(r&&o){const a=e.getFilterTexture();this.blurXFilter.apply(e,t,a,zs.CLEAR),this.blurYFilter.apply(e,a,i,n),e.returnFilterTexture(a)}else o?this.blurYFilter.apply(e,t,i,n):this.blurXFilter.apply(e,t,i,n)}updatePadding(){this._repeatEdgePixels?this.padding=0:this.padding=Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))*2}get blur(){return this.blurXFilter.blur}set blur(e){this.blurXFilter.blur=this.blurYFilter.blur=e,this.updatePadding()}get quality(){return this.blurXFilter.quality}set quality(e){this.blurXFilter.quality=this.blurYFilter.quality=e}get blurX(){return this.blurXFilter.blur}set blurX(e){this.blurXFilter.blur=e,this.updatePadding()}get blurY(){return this.blurYFilter.blur}set blurY(e){this.blurYFilter.blur=e,this.updatePadding()}get blendMode(){return this.blurYFilter.blendMode}set blendMode(e){this.blurYFilter.blendMode=e}get repeatEdgePixels(){return this._repeatEdgePixels}set repeatEdgePixels(e){this._repeatEdgePixels=e,this.updatePadding()}}var zA=`varying vec2 vTextureCoord;
}`;function zA(s,e){const t=Math.ceil(s/2);let i=WA,n="",r;e?r="vBlurTexCoords[%index%] = textureCoord + vec2(%sampleIndex% * strength, 0.0);":r="vBlurTexCoords[%index%] = textureCoord + vec2(0.0, %sampleIndex% * strength);";for(let o=0;o<s;o++){let a=r.replace("%index%",o.toString());a=a.replace("%sampleIndex%",`${o-(t-1)}.0`),n+=a,n+=`
`}return i=i.replace("%blur%",n),i=i.replace("%size%",s.toString()),i}class Xf extends Xi{constructor(e,t=8,i=4,n=Xi.defaultResolution,r=5){const o=zA(r,e),a=jA(r);super(o,a),this.horizontal=e,this.resolution=n,this._quality=0,this.quality=i,this.blur=t}apply(e,t,i,n){if(i?this.horizontal?this.uniforms.strength=1/i.width*(i.width/t.width):this.uniforms.strength=1/i.height*(i.height/t.height):this.horizontal?this.uniforms.strength=1/e.renderer.width*(e.renderer.width/t.width):this.uniforms.strength=1/e.renderer.height*(e.renderer.height/t.height),this.uniforms.strength*=this.strength,this.uniforms.strength/=this.passes,this.passes===1)e.applyFilter(this,t,i,n);else{const r=e.getFilterTexture(),o=e.renderer;let a=t,c=r;this.state.blend=!1,e.applyFilter(this,a,c,Zs.CLEAR);for(let l=1;l<this.passes-1;l++){e.bindAndClear(a,Zs.BLIT),this.uniforms.uSampler=c;const h=c;c=a,a=h,o.shader.bind(this),o.geometry.draw(5)}this.state.blend=!0,e.applyFilter(this,c,i,n),e.returnFilterTexture(r)}}get blur(){return this.strength}set blur(e){this.padding=1+Math.abs(e)*2,this.strength=e}get quality(){return this._quality}set quality(e){this._quality=e,this.passes=e}}class qA extends Xi{constructor(e=8,t=4,i=Xi.defaultResolution,n=5){super(),this._repeatEdgePixels=!1,this.blurXFilter=new Xf(!0,e,t,i,n),this.blurYFilter=new Xf(!1,e,t,i,n),this.resolution=i,this.quality=t,this.blur=e,this.repeatEdgePixels=!1}apply(e,t,i,n){const r=Math.abs(this.blurXFilter.strength),o=Math.abs(this.blurYFilter.strength);if(r&&o){const a=e.getFilterTexture();this.blurXFilter.apply(e,t,a,Zs.CLEAR),this.blurYFilter.apply(e,a,i,n),e.returnFilterTexture(a)}else o?this.blurYFilter.apply(e,t,i,n):this.blurXFilter.apply(e,t,i,n)}updatePadding(){this._repeatEdgePixels?this.padding=0:this.padding=Math.max(Math.abs(this.blurXFilter.strength),Math.abs(this.blurYFilter.strength))*2}get blur(){return this.blurXFilter.blur}set blur(e){this.blurXFilter.blur=this.blurYFilter.blur=e,this.updatePadding()}get quality(){return this.blurXFilter.quality}set quality(e){this.blurXFilter.quality=this.blurYFilter.quality=e}get blurX(){return this.blurXFilter.blur}set blurX(e){this.blurXFilter.blur=e,this.updatePadding()}get blurY(){return this.blurYFilter.blur}set blurY(e){this.blurYFilter.blur=e,this.updatePadding()}get blendMode(){return this.blurYFilter.blendMode}set blendMode(e){this.blurYFilter.blendMode=e}get repeatEdgePixels(){return this._repeatEdgePixels}set repeatEdgePixels(e){this._repeatEdgePixels=e,this.updatePadding()}}var KA=`varying vec2 vTextureCoord;
uniform sampler2D uSampler;
uniform float m[20];
uniform float uAlpha;
@@ -639,7 +639,7 @@ void main(void)
gl_FragColor = vec4(rgb, result.a);
}
`;class Vf extends Xi{constructor(){const e={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};super(xb,zA,e),this.alpha=1}_loadMatrix(e,t=!1){let i=e;t&&(this._multiply(i,this.uniforms.m,e),i=this._colorMatrix(i)),this.uniforms.m=i}_multiply(e,t,i){return e[0]=t[0]*i[0]+t[1]*i[5]+t[2]*i[10]+t[3]*i[15],e[1]=t[0]*i[1]+t[1]*i[6]+t[2]*i[11]+t[3]*i[16],e[2]=t[0]*i[2]+t[1]*i[7]+t[2]*i[12]+t[3]*i[17],e[3]=t[0]*i[3]+t[1]*i[8]+t[2]*i[13]+t[3]*i[18],e[4]=t[0]*i[4]+t[1]*i[9]+t[2]*i[14]+t[3]*i[19]+t[4],e[5]=t[5]*i[0]+t[6]*i[5]+t[7]*i[10]+t[8]*i[15],e[6]=t[5]*i[1]+t[6]*i[6]+t[7]*i[11]+t[8]*i[16],e[7]=t[5]*i[2]+t[6]*i[7]+t[7]*i[12]+t[8]*i[17],e[8]=t[5]*i[3]+t[6]*i[8]+t[7]*i[13]+t[8]*i[18],e[9]=t[5]*i[4]+t[6]*i[9]+t[7]*i[14]+t[8]*i[19]+t[9],e[10]=t[10]*i[0]+t[11]*i[5]+t[12]*i[10]+t[13]*i[15],e[11]=t[10]*i[1]+t[11]*i[6]+t[12]*i[11]+t[13]*i[16],e[12]=t[10]*i[2]+t[11]*i[7]+t[12]*i[12]+t[13]*i[17],e[13]=t[10]*i[3]+t[11]*i[8]+t[12]*i[13]+t[13]*i[18],e[14]=t[10]*i[4]+t[11]*i[9]+t[12]*i[14]+t[13]*i[19]+t[14],e[15]=t[15]*i[0]+t[16]*i[5]+t[17]*i[10]+t[18]*i[15],e[16]=t[15]*i[1]+t[16]*i[6]+t[17]*i[11]+t[18]*i[16],e[17]=t[15]*i[2]+t[16]*i[7]+t[17]*i[12]+t[18]*i[17],e[18]=t[15]*i[3]+t[16]*i[8]+t[17]*i[13]+t[18]*i[18],e[19]=t[15]*i[4]+t[16]*i[9]+t[17]*i[14]+t[18]*i[19]+t[19],e}_colorMatrix(e){const t=new Float32Array(e);return t[4]/=255,t[9]/=255,t[14]/=255,t[19]/=255,t}brightness(e,t){const i=[e,0,0,0,0,0,e,0,0,0,0,0,e,0,0,0,0,0,1,0];this._loadMatrix(i,t)}tint(e,t){const[i,n,r]=Tt.shared.setValue(e).toArray(),o=[i,0,0,0,0,0,n,0,0,0,0,0,r,0,0,0,0,0,1,0];this._loadMatrix(o,t)}greyscale(e,t){const i=[e,e,e,0,0,e,e,e,0,0,e,e,e,0,0,0,0,0,1,0];this._loadMatrix(i,t)}blackAndWhite(e){const t=[.3,.6,.1,0,0,.3,.6,.1,0,0,.3,.6,.1,0,0,0,0,0,1,0];this._loadMatrix(t,e)}hue(e,t){e=(e||0)/180*Math.PI;const i=Math.cos(e),n=Math.sin(e),r=Math.sqrt,o=1/3,a=r(o),c=i+(1-i)*o,l=o*(1-i)-a*n,h=o*(1-i)+a*n,u=o*(1-i)+a*n,d=i+o*(1-i),f=o*(1-i)-a*n,p=o*(1-i)-a*n,m=o*(1-i)+a*n,g=i+o*(1-i),v=[c,l,h,0,0,u,d,f,0,0,p,m,g,0,0,0,0,0,1,0];this._loadMatrix(v,t)}contrast(e,t){const i=(e||0)+1,n=-.5*(i-1),r=[i,0,0,0,n,0,i,0,0,n,0,0,i,0,n,0,0,0,1,0];this._loadMatrix(r,t)}saturate(e=0,t){const i=e*2/3+1,n=(i-1)*-.5,r=[i,n,n,0,0,n,i,n,0,0,n,n,i,0,0,0,0,0,1,0];this._loadMatrix(r,t)}desaturate(){this.saturate(-1)}negative(e){const t=[-1,0,0,1,0,0,-1,0,1,0,0,0,-1,1,0,0,0,0,1,0];this._loadMatrix(t,e)}sepia(e){const t=[.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0];this._loadMatrix(t,e)}technicolor(e){const t=[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(t,e)}polaroid(e){const t=[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(t,e)}toBGR(e){const t=[0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0];this._loadMatrix(t,e)}kodachrome(e){const t=[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(t,e)}browni(e){const t=[.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(t,e)}vintage(e){const t=[.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(t,e)}colorTone(e,t,i,n,r){e=e||.2,t=t||.15,i=i||16770432,n=n||3375104;const o=Tt.shared,[a,c,l]=o.setValue(i).toArray(),[h,u,d]=o.setValue(n).toArray(),f=[.3,.59,.11,0,0,a,c,l,e,0,h,u,d,t,0,a-h,c-u,l-d,0,0];this._loadMatrix(f,r)}night(e,t){e=e||.1;const i=[e*-2,-e,0,0,0,-e,0,e,0,0,0,e,e*2,0,0,0,0,0,1,0];this._loadMatrix(i,t)}predator(e,t){const i=[11.224130630493164*e,-4.794486999511719*e,-2.8746118545532227*e,0*e,.40342438220977783*e,-3.6330697536468506*e,9.193157196044922*e,-2.951810836791992*e,0*e,-1.316135048866272*e,-3.2184197902679443*e,-4.2375030517578125*e,7.476448059082031*e,0*e,.8044459223747253*e,0,0,0,1,0];this._loadMatrix(i,t)}lsd(e){const t=[2,-.4,.5,0,0,-.5,2,-.4,0,0,-.4,-.5,3,0,0,0,0,0,1,0];this._loadMatrix(t,e)}reset(){const e=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0];this._loadMatrix(e,!1)}get matrix(){return this.uniforms.m}set matrix(e){this.uniforms.m=e}get alpha(){return this.uniforms.uAlpha}set alpha(e){this.uniforms.uAlpha=e}}Vf.prototype.grayscale=Vf.prototype.greyscale;var qA=`varying vec2 vFilterCoord;
`;class Vf extends Xi{constructor(){const e={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};super(bb,KA,e),this.alpha=1}_loadMatrix(e,t=!1){let i=e;t&&(this._multiply(i,this.uniforms.m,e),i=this._colorMatrix(i)),this.uniforms.m=i}_multiply(e,t,i){return e[0]=t[0]*i[0]+t[1]*i[5]+t[2]*i[10]+t[3]*i[15],e[1]=t[0]*i[1]+t[1]*i[6]+t[2]*i[11]+t[3]*i[16],e[2]=t[0]*i[2]+t[1]*i[7]+t[2]*i[12]+t[3]*i[17],e[3]=t[0]*i[3]+t[1]*i[8]+t[2]*i[13]+t[3]*i[18],e[4]=t[0]*i[4]+t[1]*i[9]+t[2]*i[14]+t[3]*i[19]+t[4],e[5]=t[5]*i[0]+t[6]*i[5]+t[7]*i[10]+t[8]*i[15],e[6]=t[5]*i[1]+t[6]*i[6]+t[7]*i[11]+t[8]*i[16],e[7]=t[5]*i[2]+t[6]*i[7]+t[7]*i[12]+t[8]*i[17],e[8]=t[5]*i[3]+t[6]*i[8]+t[7]*i[13]+t[8]*i[18],e[9]=t[5]*i[4]+t[6]*i[9]+t[7]*i[14]+t[8]*i[19]+t[9],e[10]=t[10]*i[0]+t[11]*i[5]+t[12]*i[10]+t[13]*i[15],e[11]=t[10]*i[1]+t[11]*i[6]+t[12]*i[11]+t[13]*i[16],e[12]=t[10]*i[2]+t[11]*i[7]+t[12]*i[12]+t[13]*i[17],e[13]=t[10]*i[3]+t[11]*i[8]+t[12]*i[13]+t[13]*i[18],e[14]=t[10]*i[4]+t[11]*i[9]+t[12]*i[14]+t[13]*i[19]+t[14],e[15]=t[15]*i[0]+t[16]*i[5]+t[17]*i[10]+t[18]*i[15],e[16]=t[15]*i[1]+t[16]*i[6]+t[17]*i[11]+t[18]*i[16],e[17]=t[15]*i[2]+t[16]*i[7]+t[17]*i[12]+t[18]*i[17],e[18]=t[15]*i[3]+t[16]*i[8]+t[17]*i[13]+t[18]*i[18],e[19]=t[15]*i[4]+t[16]*i[9]+t[17]*i[14]+t[18]*i[19]+t[19],e}_colorMatrix(e){const t=new Float32Array(e);return t[4]/=255,t[9]/=255,t[14]/=255,t[19]/=255,t}brightness(e,t){const i=[e,0,0,0,0,0,e,0,0,0,0,0,e,0,0,0,0,0,1,0];this._loadMatrix(i,t)}tint(e,t){const[i,n,r]=Mt.shared.setValue(e).toArray(),o=[i,0,0,0,0,0,n,0,0,0,0,0,r,0,0,0,0,0,1,0];this._loadMatrix(o,t)}greyscale(e,t){const i=[e,e,e,0,0,e,e,e,0,0,e,e,e,0,0,0,0,0,1,0];this._loadMatrix(i,t)}blackAndWhite(e){const t=[.3,.6,.1,0,0,.3,.6,.1,0,0,.3,.6,.1,0,0,0,0,0,1,0];this._loadMatrix(t,e)}hue(e,t){e=(e||0)/180*Math.PI;const i=Math.cos(e),n=Math.sin(e),r=Math.sqrt,o=1/3,a=r(o),c=i+(1-i)*o,l=o*(1-i)-a*n,h=o*(1-i)+a*n,u=o*(1-i)+a*n,d=i+o*(1-i),f=o*(1-i)-a*n,p=o*(1-i)-a*n,m=o*(1-i)+a*n,g=i+o*(1-i),v=[c,l,h,0,0,u,d,f,0,0,p,m,g,0,0,0,0,0,1,0];this._loadMatrix(v,t)}contrast(e,t){const i=(e||0)+1,n=-.5*(i-1),r=[i,0,0,0,n,0,i,0,0,n,0,0,i,0,n,0,0,0,1,0];this._loadMatrix(r,t)}saturate(e=0,t){const i=e*2/3+1,n=(i-1)*-.5,r=[i,n,n,0,0,n,i,n,0,0,n,n,i,0,0,0,0,0,1,0];this._loadMatrix(r,t)}desaturate(){this.saturate(-1)}negative(e){const t=[-1,0,0,1,0,0,-1,0,1,0,0,0,-1,1,0,0,0,0,1,0];this._loadMatrix(t,e)}sepia(e){const t=[.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0];this._loadMatrix(t,e)}technicolor(e){const t=[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(t,e)}polaroid(e){const t=[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(t,e)}toBGR(e){const t=[0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0];this._loadMatrix(t,e)}kodachrome(e){const t=[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(t,e)}browni(e){const t=[.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(t,e)}vintage(e){const t=[.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(t,e)}colorTone(e,t,i,n,r){e=e||.2,t=t||.15,i=i||16770432,n=n||3375104;const o=Mt.shared,[a,c,l]=o.setValue(i).toArray(),[h,u,d]=o.setValue(n).toArray(),f=[.3,.59,.11,0,0,a,c,l,e,0,h,u,d,t,0,a-h,c-u,l-d,0,0];this._loadMatrix(f,r)}night(e,t){e=e||.1;const i=[e*-2,-e,0,0,0,-e,0,e,0,0,0,e,e*2,0,0,0,0,0,1,0];this._loadMatrix(i,t)}predator(e,t){const i=[11.224130630493164*e,-4.794486999511719*e,-2.8746118545532227*e,0*e,.40342438220977783*e,-3.6330697536468506*e,9.193157196044922*e,-2.951810836791992*e,0*e,-1.316135048866272*e,-3.2184197902679443*e,-4.2375030517578125*e,7.476448059082031*e,0*e,.8044459223747253*e,0,0,0,1,0];this._loadMatrix(i,t)}lsd(e){const t=[2,-.4,.5,0,0,-.5,2,-.4,0,0,-.4,-.5,3,0,0,0,0,0,1,0];this._loadMatrix(t,e)}reset(){const e=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0];this._loadMatrix(e,!1)}get matrix(){return this.uniforms.m}set matrix(e){this.uniforms.m=e}get alpha(){return this.uniforms.uAlpha}set alpha(e){this.uniforms.uAlpha=e}}Vf.prototype.grayscale=Vf.prototype.greyscale;var ZA=`varying vec2 vFilterCoord;
varying vec2 vTextureCoord;
uniform vec2 scale;
@@ -659,7 +659,7 @@ void main(void)
gl_FragColor = texture2D(uSampler, clamp(vec2(vTextureCoord.x + map.x, vTextureCoord.y + map.y), inputClamp.xy, inputClamp.zw));
}
`,KA=`attribute vec2 aVertexPosition;
`,JA=`attribute vec2 aVertexPosition;
uniform mat3 projectionMatrix;
uniform mat3 filterMatrix;
@@ -688,7 +688,7 @@ void main(void)
vTextureCoord = filterTextureCoord();
vFilterCoord = ( filterMatrix * vec3( vTextureCoord, 1.0) ).xy;
}
`;class ZA extends Xi{constructor(e,t){const i=new Dt;e.renderable=!1,super(KA,qA,{mapSampler:e._texture,filterMatrix:i,scale:{x:1,y:1},rotation:new Float32Array([1,0,0,1])}),this.maskSprite=e,this.maskMatrix=i,t==null&&(t=20),this.scale=new pt(t,t)}apply(e,t,i,n){this.uniforms.filterMatrix=e.calculateSpriteMatrix(this.maskMatrix,this.maskSprite),this.uniforms.scale.x=this.scale.x,this.uniforms.scale.y=this.scale.y;const r=this.maskSprite.worldTransform,o=Math.sqrt(r.a*r.a+r.b*r.b),a=Math.sqrt(r.c*r.c+r.d*r.d);o!==0&&a!==0&&(this.uniforms.rotation[0]=r.a/o,this.uniforms.rotation[1]=r.b/o,this.uniforms.rotation[2]=r.c/a,this.uniforms.rotation[3]=r.d/a),e.applyFilter(this,t,i,n)}get map(){return this.uniforms.mapSampler}set map(e){this.uniforms.mapSampler=e}}var JA=`varying vec2 v_rgbNW;
`;class QA extends Xi{constructor(e,t){const i=new Ut;e.renderable=!1,super(JA,ZA,{mapSampler:e._texture,filterMatrix:i,scale:{x:1,y:1},rotation:new Float32Array([1,0,0,1])}),this.maskSprite=e,this.maskMatrix=i,t==null&&(t=20),this.scale=new gt(t,t)}apply(e,t,i,n){this.uniforms.filterMatrix=e.calculateSpriteMatrix(this.maskMatrix,this.maskSprite),this.uniforms.scale.x=this.scale.x,this.uniforms.scale.y=this.scale.y;const r=this.maskSprite.worldTransform,o=Math.sqrt(r.a*r.a+r.b*r.b),a=Math.sqrt(r.c*r.c+r.d*r.d);o!==0&&a!==0&&(this.uniforms.rotation[0]=r.a/o,this.uniforms.rotation[1]=r.b/o,this.uniforms.rotation[2]=r.c/a,this.uniforms.rotation[3]=r.d/a),e.applyFilter(this,t,i,n)}get map(){return this.uniforms.mapSampler}set map(e){this.uniforms.mapSampler=e}}var e2=`varying vec2 v_rgbNW;
varying vec2 v_rgbNE;
varying vec2 v_rgbSW;
varying vec2 v_rgbSE;
@@ -809,7 +809,7 @@ void main() {
gl_FragColor = color;
}
`,QA=`
`,t2=`
attribute vec2 aVertexPosition;
uniform mat3 projectionMatrix;
@@ -851,7 +851,7 @@ void main(void) {
texcoords(vFragCoord, inputSize.zw, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);
}
`;class e2 extends Xi{constructor(){super(QA,JA)}}var t2=`precision highp float;
`;class i2 extends Xi{constructor(){super(t2,e2)}}var s2=`precision highp float;
varying vec2 vTextureCoord;
varying vec4 vColor;
@@ -885,8 +885,8 @@ void main()
gl_FragColor = color;
}
`;class i2 extends Xi{constructor(e=.5,t=Math.random()){super(xb,t2,{uNoise:0,uSeed:0}),this.noise=e,this.seed=t}get noise(){return this.uniforms.uNoise}set noise(e){this.uniforms.uNoise=e}get seed(){return this.uniforms.uSeed}set seed(e){this.uniforms.uSeed=e}}const G0={AlphaFilter:XA,BlurFilter:WA,BlurFilterPass:Xf,ColorMatrixFilter:Vf,DisplacementFilter:ZA,FXAAFilter:e2,NoiseFilter:i2};Object.entries(G0).forEach(([s,e])=>{Object.defineProperty(G0,s,{get(){return lt("7.1.0",`filters.${s} has moved to ${s}`),e}})});class s2{constructor(){this.interactionFrequency=10,this._deltaTime=0,this._didMove=!1,this.tickerAdded=!1,this._pauseUpdate=!0}init(e){this.removeTickerListener(),this.events=e,this.interactionFrequency=10,this._deltaTime=0,this._didMove=!1,this.tickerAdded=!1,this._pauseUpdate=!0}get pauseUpdate(){return this._pauseUpdate}set pauseUpdate(e){this._pauseUpdate=e}addTickerListener(){this.tickerAdded||!this.domElement||(Vi.system.add(this.tickerUpdate,this,so.INTERACTION),this.tickerAdded=!0)}removeTickerListener(){this.tickerAdded&&(Vi.system.remove(this.tickerUpdate,this),this.tickerAdded=!1)}pointerMoved(){this._didMove=!0}update(){if(!this.domElement||this._pauseUpdate)return;if(this._didMove){this._didMove=!1;return}const e=this.events.rootPointerEvent;this.events.supportsTouchEvents&&e.pointerType==="touch"||globalThis.document.dispatchEvent(new PointerEvent("pointermove",{clientX:e.clientX,clientY:e.clientY}))}tickerUpdate(e){this._deltaTime+=e,!(this._deltaTime<this.interactionFrequency)&&(this._deltaTime=0,this.update())}}const tr=new s2;class bl{constructor(e){this.bubbles=!0,this.cancelBubble=!0,this.cancelable=!1,this.composed=!1,this.defaultPrevented=!1,this.eventPhase=bl.prototype.NONE,this.propagationStopped=!1,this.propagationImmediatelyStopped=!1,this.layer=new pt,this.page=new pt,this.NONE=0,this.CAPTURING_PHASE=1,this.AT_TARGET=2,this.BUBBLING_PHASE=3,this.manager=e}get layerX(){return this.layer.x}get layerY(){return this.layer.y}get pageX(){return this.page.x}get pageY(){return this.page.y}get data(){return this}composedPath(){return this.manager&&(!this.path||this.path[this.path.length-1]!==this.target)&&(this.path=this.target?this.manager.propagationPath(this.target):[]),this.path}initEvent(e,t,i){throw new Error("initEvent() is a legacy DOM API. It is not implemented in the Federated Events API.")}initUIEvent(e,t,i,n,r){throw new Error("initUIEvent() is a legacy DOM API. It is not implemented in the Federated Events API.")}preventDefault(){this.nativeEvent instanceof Event&&this.nativeEvent.cancelable&&this.nativeEvent.preventDefault(),this.defaultPrevented=!0}stopImmediatePropagation(){this.propagationImmediatelyStopped=!0}stopPropagation(){this.propagationStopped=!0}}class Jc extends bl{constructor(){super(...arguments),this.client=new pt,this.movement=new pt,this.offset=new pt,this.global=new pt,this.screen=new pt}get clientX(){return this.client.x}get clientY(){return this.client.y}get x(){return this.clientX}get y(){return this.clientY}get movementX(){return this.movement.x}get movementY(){return this.movement.y}get offsetX(){return this.offset.x}get offsetY(){return this.offset.y}get globalX(){return this.global.x}get globalY(){return this.global.y}get screenX(){return this.screen.x}get screenY(){return this.screen.y}getLocalPosition(e,t,i){return e.worldTransform.applyInverse(i||this.global,t)}getModifierState(e){return"getModifierState"in this.nativeEvent&&this.nativeEvent.getModifierState(e)}initMouseEvent(e,t,i,n,r,o,a,c,l,h,u,d,f,p,m){throw new Error("Method not implemented.")}}class ws extends Jc{constructor(){super(...arguments),this.width=0,this.height=0,this.isPrimary=!1}getCoalescedEvents(){return this.type==="pointermove"||this.type==="mousemove"||this.type==="touchmove"?[this]:[]}getPredictedEvents(){throw new Error("getPredictedEvents is not supported!")}}class Go extends Jc{constructor(){super(...arguments),this.DOM_DELTA_PIXEL=0,this.DOM_DELTA_LINE=1,this.DOM_DELTA_PAGE=2}}Go.DOM_DELTA_PIXEL=0,Go.DOM_DELTA_LINE=1,Go.DOM_DELTA_PAGE=2;const n2=2048,r2=new pt,Ld=new pt;class o2{constructor(e){this.dispatch=new yl,this.moveOnAll=!1,this.enableGlobalMoveEvents=!0,this.mappingState={trackingData:{}},this.eventPool=new Map,this._allInteractiveElements=[],this._hitElements=[],this._isPointerMoveEvent=!1,this.rootTarget=e,this.hitPruneFn=this.hitPruneFn.bind(this),this.hitTestFn=this.hitTestFn.bind(this),this.mapPointerDown=this.mapPointerDown.bind(this),this.mapPointerMove=this.mapPointerMove.bind(this),this.mapPointerOut=this.mapPointerOut.bind(this),this.mapPointerOver=this.mapPointerOver.bind(this),this.mapPointerUp=this.mapPointerUp.bind(this),this.mapPointerUpOutside=this.mapPointerUpOutside.bind(this),this.mapWheel=this.mapWheel.bind(this),this.mappingTable={},this.addEventMapping("pointerdown",this.mapPointerDown),this.addEventMapping("pointermove",this.mapPointerMove),this.addEventMapping("pointerout",this.mapPointerOut),this.addEventMapping("pointerle Line truncated
${u}`)}});return await Promise.all(c),r?n[o[0].src]:n}async unload(e){const t=Ts(e,i=>({alias:[i],src:i})).map(async i=>{var o,a;const n=Jt.toAbsolute(i.src),r=this.promiseCache[n];if(r){const c=await r.promise;delete this.promiseCache[n],(a=(o=r.parser)==null?void 0:o.unload)==null||a.call(o,c,i,this)}});await Promise.all(t)}_validateParsers(){this._parsersValidated=!0,this._parserHash=this._parsers.filter(e=>e.name).reduce((e,t)=>(e[t.name]&&console.warn(`[Assets] loadParser name conflict "${t.name}"`),{...e,[t.name]:t}),{})}}var rs=(s=>(s[s.Low=0]="Low",s[s.Normal=1]="Normal",s[s.High=2]="High",s))(rs||{});const w2=".json",S2="application/json",T2={extension:{type:Re.LoadParser,priority:rs.Low},name:"loadJson",test(s){return la(s,S2)||Zi(s,w2)},async load(s){return await(await ke.ADAPTER.fetch(s)).json()}};$e.add(T2);const M2=".txt",_2="text/plain",C2={name:"loadTxt",extension:{type:Re.LoadParser,priority:rs.Low},test(s){return la(s,_2)||Zi(s,M2)},async load(s){return await(await ke.ADAPTER.fetch(s)).text()}};$e.add(C2);const A2=["normal","bold","100","200","300","400","500","600","700","800","900"],E2=[".ttf",".otf",".woff",".woff2"],I2=["font/ttf","font/otf","font/woff","font/woff2"],R2=/^(--|-?[A-Z_])[0-9A-Z_-]*$/i;function P2(s){const e=Jt.extname(s),t=Jt.basename(s,e).replace(/(-|_)/g," ").toLowerCase().split(" ").map(r=>r.charAt(0).toUpperCase()+r.slice(1));let i=t.length>0;for(const r of t)if(!r.match(R2)){i=!1;break}let n=t.join(" ");return i||(n=`"${n.replace(/[\\"]/g,"\\$&")}"`),n}const k2=/^[0-9A-Za-z%:/?#\[\]@!\$&'()\*\+,;=\-._~]*$/;function F2(s){return k2.test(s)?s:encodeURI(s)}const O2={extension:{type:Re.LoadParser,priority:rs.Low},name:"loadWebFont",test(s){return la(s,I2)||Zi(s,E2)},async load(s,e){var i,n,r;const t=ke.ADAPTER.getFontFaceSet();if(t){const o=[],a=((i=e.data)==null?void 0:i.family)??P2(s),c=((r=(n=e.data)==null?void 0:n.weights)==null?void 0:r.filter(h=>A2.includes(h)))??["normal"],l=e.data??{};for(let h=0;h<c.length;h++){const u=c[h],d=new FontFace(a,`url(${F2(s)})`,{...l,weight:u});await d.load(),t.add(d),o.push(d)}return o.length===1?o[0]:o}return console.warn("[loadWebFont] FontFace API is not supported. Skipping loading font"),null},unload(s){(Array.isArray(s)?s:[s]).forEach(e=>ke.ADAPTER.getFontFaceSet().delete(e))}};$e.add(O2);const B2=`(function() {
`;class n2 extends Xi{constructor(e=.5,t=Math.random()){super(bb,s2,{uNoise:0,uSeed:0}),this.noise=e,this.seed=t}get noise(){return this.uniforms.uNoise}set noise(e){this.uniforms.uNoise=e}get seed(){return this.uniforms.uSeed}set seed(e){this.uniforms.uSeed=e}}const G0={AlphaFilter:YA,BlurFilter:qA,BlurFilterPass:Xf,ColorMatrixFilter:Vf,DisplacementFilter:QA,FXAAFilter:i2,NoiseFilter:n2};Object.entries(G0).forEach(([s,e])=>{Object.defineProperty(G0,s,{get(){return ht("7.1.0",`filters.${s} has moved to ${s}`),e}})});class r2{constructor(){this.interactionFrequency=10,this._deltaTime=0,this._didMove=!1,this.tickerAdded=!1,this._pauseUpdate=!0}init(e){this.removeTickerListener(),this.events=e,this.interactionFrequency=10,this._deltaTime=0,this._didMove=!1,this.tickerAdded=!1,this._pauseUpdate=!0}get pauseUpdate(){return this._pauseUpdate}set pauseUpdate(e){this._pauseUpdate=e}addTickerListener(){this.tickerAdded||!this.domElement||(Vi.system.add(this.tickerUpdate,this,oo.INTERACTION),this.tickerAdded=!0)}removeTickerListener(){this.tickerAdded&&(Vi.system.remove(this.tickerUpdate,this),this.tickerAdded=!1)}pointerMoved(){this._didMove=!0}update(){if(!this.domElement||this._pauseUpdate)return;if(this._didMove){this._didMove=!1;return}const e=this.events.rootPointerEvent;this.events.supportsTouchEvents&&e.pointerType==="touch"||globalThis.document.dispatchEvent(new PointerEvent("pointermove",{clientX:e.clientX,clientY:e.clientY}))}tickerUpdate(e){this._deltaTime+=e,!(this._deltaTime<this.interactionFrequency)&&(this._deltaTime=0,this.update())}}const rr=new r2;class wl{constructor(e){this.bubbles=!0,this.cancelBubble=!0,this.cancelable=!1,this.composed=!1,this.defaultPrevented=!1,this.eventPhase=wl.prototype.NONE,this.propagationStopped=!1,this.propagationImmediatelyStopped=!1,this.layer=new gt,this.page=new gt,this.NONE=0,this.CAPTURING_PHASE=1,this.AT_TARGET=2,this.BUBBLING_PHASE=3,this.manager=e}get layerX(){return this.layer.x}get layerY(){return this.layer.y}get pageX(){return this.page.x}get pageY(){return this.page.y}get data(){return this}composedPath(){return this.manager&&(!this.path||this.path[this.path.length-1]!==this.target)&&(this.path=this.target?this.manager.propagationPath(this.target):[]),this.path}initEvent(e,t,i){throw new Error("initEvent() is a legacy DOM API. It is not implemented in the Federated Events API.")}initUIEvent(e,t,i,n,r){throw new Error("initUIEvent() is a legacy DOM API. It is not implemented in the Federated Events API.")}preventDefault(){this.nativeEvent instanceof Event&&this.nativeEvent.cancelable&&this.nativeEvent.preventDefault(),this.defaultPrevented=!0}stopImmediatePropagation(){this.propagationImmediatelyStopped=!0}stopPropagation(){this.propagationStopped=!0}}class Jc extends wl{constructor(){super(...arguments),this.client=new gt,this.movement=new gt,this.offset=new gt,this.global=new gt,this.screen=new gt}get clientX(){return this.client.x}get clientY(){return this.client.y}get x(){return this.clientX}get y(){return this.clientY}get movementX(){return this.movement.x}get movementY(){return this.movement.y}get offsetX(){return this.offset.x}get offsetY(){return this.offset.y}get globalX(){return this.global.x}get globalY(){return this.global.y}get screenX(){return this.screen.x}get screenY(){return this.screen.y}getLocalPosition(e,t,i){return e.worldTransform.applyInverse(i||this.global,t)}getModifierState(e){return"getModifierState"in this.nativeEvent&&this.nativeEvent.getModifierState(e)}initMouseEvent(e,t,i,n,r,o,a,c,l,h,u,d,f,p,m){throw new Error("Method not implemented.")}}class Ss extends Jc{constructor(){super(...arguments),this.width=0,this.height=0,this.isPrimary=!1}getCoalescedEvents(){return this.type==="pointermove"||this.type==="mousemove"||this.type==="touchmove"?[this]:[]}getPredictedEvents(){throw new Error("getPredictedEvents is not supported!")}}class jo extends Jc{constructor(){super(...arguments),this.DOM_DELTA_PIXEL=0,this.DOM_DELTA_LINE=1,this.DOM_DELTA_PAGE=2}}jo.DOM_DELTA_PIXEL=0,jo.DOM_DELTA_LINE=1,jo.DOM_DELTA_PAGE=2;const o2=2048,a2=new gt,Ld=new gt;class l2{constructor(e){this.dispatch=new bl,this.moveOnAll=!1,this.enableGlobalMoveEvents=!0,this.mappingState={trackingData:{}},this.eventPool=new Map,this._allInteractiveElements=[],this._hitElements=[],this._isPointerMoveEvent=!1,this.rootTarget=e,this.hitPruneFn=this.hitPruneFn.bind(this),this.hitTestFn=this.hitTestFn.bind(this),this.mapPointerDown=this.mapPointerDown.bind(this),this.mapPointerMove=this.mapPointerMove.bind(this),this.mapPointerOut=this.mapPointerOut.bind(this),this.mapPointerOver=this.mapPointerOver.bind(this),this.mapPointerUp=this.mapPointerUp.bind(this),this.mapPointerUpOutside=this.mapPointerUpOutside.bind(this),this.mapWheel=this.mapWheel.bind(this),this.mappingTable={},this.addEventMapping("pointerdown",this.mapPointerDown),this.addEventMapping("pointermove",this.mapPointerMove),this.addEventMapping("pointerout",this.mapPointerOut),this.addEventMapping("pointerle Line truncated
${u}`)}});return await Promise.all(c),r?n[o[0].src]:n}async unload(e){const t=Ms(e,i=>({alias:[i],src:i})).map(async i=>{var o,a;const n=Qt.toAbsolute(i.src),r=this.promiseCache[n];if(r){const c=await r.promise;delete this.promiseCache[n],(a=(o=r.parser)==null?void 0:o.unload)==null||a.call(o,c,i,this)}});await Promise.all(t)}_validateParsers(){this._parsersValidated=!0,this._parserHash=this._parsers.filter(e=>e.name).reduce((e,t)=>(e[t.name]&&console.warn(`[Assets] loadParser name conflict "${t.name}"`),{...e,[t.name]:t}),{})}}var ns=(s=>(s[s.Low=0]="Low",s[s.Normal=1]="Normal",s[s.High=2]="High",s))(ns||{});const T2=".json",M2="application/json",_2={extension:{type:Re.LoadParser,priority:ns.Low},name:"loadJson",test(s){return ha(s,M2)||Ki(s,T2)},async load(s){return await(await ke.ADAPTER.fetch(s)).json()}};Ue.add(_2);const C2=".txt",A2="text/plain",E2={name:"loadTxt",extension:{type:Re.LoadParser,priority:ns.Low},test(s){return ha(s,A2)||Ki(s,C2)},async load(s){return await(await ke.ADAPTER.fetch(s)).text()}};Ue.add(E2);const I2=["normal","bold","100","200","300","400","500","600","700","800","900"],R2=[".ttf",".otf",".woff",".woff2"],P2=["font/ttf","font/otf","font/woff","font/woff2"],k2=/^(--|-?[A-Z_])[0-9A-Z_-]*$/i;function F2(s){const e=Qt.extname(s),t=Qt.basename(s,e).replace(/(-|_)/g," ").toLowerCase().split(" ").map(r=>r.charAt(0).toUpperCase()+r.slice(1));let i=t.length>0;for(const r of t)if(!r.match(k2)){i=!1;break}let n=t.join(" ");return i||(n=`"${n.replace(/[\\"]/g,"\\$&")}"`),n}const O2=/^[0-9A-Za-z%:/?#\[\]@!\$&'()\*\+,;=\-._~]*$/;function B2(s){return O2.test(s)?s:encodeURI(s)}const L2={extension:{type:Re.LoadParser,priority:ns.Low},name:"loadWebFont",test(s){return ha(s,P2)||Ki(s,R2)},async load(s,e){var i,n,r;const t=ke.ADAPTER.getFontFaceSet();if(t){const o=[],a=((i=e.data)==null?void 0:i.family)??F2(s),c=((r=(n=e.data)==null?void 0:n.weights)==null?void 0:r.filter(h=>I2.includes(h)))??["normal"],l=e.data??{};for(let h=0;h<c.length;h++){const u=c[h],d=new FontFace(a,`url(${B2(s)})`,{...l,weight:u});await d.load(),t.add(d),o.push(d)}return o.length===1?o[0]:o}return console.warn("[loadWebFont] FontFace API is not supported. Skipping loading font"),null},unload(s){(Array.isArray(s)?s:[s]).forEach(e=>ke.ADAPTER.getFontFaceSet().delete(e))}};Ue.add(L2);const D2=`(function() {
"use strict";
const WHITE_PNG = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP8/x8AAwMCAO+ip1sAAAAASUVORK5CYII=";
async function checkImageBitmap() {
@@ -903,7 +903,7 @@ ${u}`)}});return await Promise.all(c),r?n[o[0].src]:n}async unload(e){const t=Ts
self.postMessage(result);
});
})();
`;let Ho=null,Wf=class{constructor(){Ho||(Ho=URL.createObjectURL(new Blob([B2],{type:"application/javascript"}))),this.worker=new Worker(Ho)}};Wf.revokeObjectURL=function(){Ho&&(URL.revokeObjectURL(Ho),Ho=null)};const L2=`(function() {
`;let Wo=null,Wf=class{constructor(){Wo||(Wo=URL.createObjectURL(new Blob([D2],{type:"application/javascript"}))),this.worker=new Worker(Wo)}};Wf.revokeObjectURL=function(){Wo&&(URL.revokeObjectURL(Wo),Wo=null)};const N2=`(function() {
"use strict";
async function loadImageBitmap(url) {
const response = await fetch(url);
@@ -929,8 +929,8 @@ ${u}`)}});return await Promise.all(c),r?n[o[0].src]:n}async unload(e){const t=Ts
}
};
})();
`;let jo=null;class kb{constructor(){jo||(jo=URL.createObjectURL(new Blob([L2],{type:"application/javascript"}))),this.worker=new Worker(jo)}}kb.revokeObjectURL=function(){jo&&(URL.revokeObjectURL(jo),jo=null)};let q0=0,Dd;class D2{constructor(){this._initialized=!1,this._createdWorkers=0,this.workerPool=[],this.queue=[],this.resolveHash={}}isImageBitmapSupported(){return this._isImageBitmapSupported!==void 0?this._isImageBitmapSupported:(this._isImageBitmapSupported=new Promise(e=>{const{worker:t}=new Wf;t.addEventListener("message",i=>{t.terminate(),Wf.revokeObjectURL(),e(i.data)})}),this._isImageBitmapSupported)}loadImageBitmap(e){return this._run("loadImageBitmap",[e])}async _initWorkers(){this._initialized||(this._initialized=!0)}getWorker(){Dd===void 0&&(Dd=navigator.hardwareConcurrency||4);let e=this.workerPool.pop();return!e&&this._createdWorkers<Dd&&(this._createdWorkers++,e=new kb().worker,e.addEventListener("message",t=>{this.complete(t.data),this.returnWorker(t.target),this.next()})),e}returnWorker(e){this.workerPool.push(e)}complete(e){e.error!==void 0?this.resolveHash[e.uuid].reject(e.error):this.resolveHash[e.uuid].resolve(e.data),this.resolveHash[e.uuid]=null}async _run(e,t){await this._initWorkers();const i=new Promise((n,r)=>{this.queue.push({id:e,arguments:t,resolve:n,reject:r})});return this.next(),i}next(){if(!this.queue.length)return;const e=this.getWorker();if(!e)return;const t=this.queue.pop(),i=t.id;this.resolveHash[q0]={resolve:t.resolve,reject:t.reject},e.postMessage({data:t.arguments,uuid:q0++,id:i})}}const K0=new D2;function wl(s,e,t){s.resource.internal=!0;const i=new ze(s),n=()=>{delete e.promiseCache[t],$r.has(t)&&$r.remove(t)};return i.baseTexture.once("destroyed",()=>{t in e.promiseCache&&(console.warn("[Assets] A BaseTexture managed by Assets was destroyed instead of unloaded! Use Assets.unload() instead of destroying the BaseTexture."),n())}),i.once("destroyed",()=>{s.destroyed||(console.warn("[Assets] A Texture managed by Assets was destroyed instead of unloaded! Use Assets.unload() instead of destroying the Texture."),n())}),i}const N2=[".jpeg",".jpg",".png",".webp",".avif"],U2=["image/jpeg","image/png","image/webp","image/avif"];async function $2(s){const e=await ke.ADAPTER.fetch(s);if(!e.ok)throw new Error(`[loadImageBitmap] Failed to fetch ${s}: ${e.status} ${e.statusText}`);const t=await e.blob();return await createImageBitmap(t)}const tu={name:"loadTextures",extension:{type:Re.LoadParser,priority:rs.High},config:{preferWorkers:!0,preferCreateImageBitmap:!0,crossOrigin:"anonymous"},test(s){return la(s,U2)||Zi(s,N2)},async load(s,e,t){var a;const i=globalThis.createImageBitmap&&this.config.preferCreateImageBitmap;let n;i?this.config.preferWorkers&&await K0.isImageBitmapSupported()?n=await K0.loadImageBitmap(s):n=await $2(s):n=await new Promise((c,l)=>{const h=new Image;h.crossOrigin=this.config.crossOrigin,h.src=s,h.complete?c(h):(h.onload=()=>c(h),h.onerror=u=>l(u))});const r={...e.data};r.resolution??(r.resolution=Dn(s)),i&&((a=r.resourceOptions)==null?void 0:a.ownsImageBitmap)===void 0&&(r.resourceOptions={...r.resourceOptions},r.resourceOptions.ownsImageBitmap=!0);const o=new Ze(n,r);return o.resource.src=s,wl(o,t,s)},unload(s){s.destroy(!0)}};$e.add(tu);const X2=".svg",V2="image/svg+xml",Y2={extension:{type:Re.LoadParser,priority:rs.High},name:"loadSVG",test(s){return la(s,V2)||Zi(s,X2)},async testParse(s){return Df.test(s)},async parse(s,e,t){var r;const i=new Df(s,(r=e==null?void 0:e.data)==null?void 0:r.resourceOptions);await i.load();const n=new Ze(i,{resolution:Dn(s),...e==null?void 0:e.data});return n.resource.src=e.src,wl(n,t,e.src)},async load(s,e){return(await ke.ADAPTER.fetch(s)).text()},unload:tu.unload};$e.add(Y2);const G2=[".mp4",".m4v",".webm",".ogv"],H2=["video/mp4","video/webm","video/ogg"],j2={name:"loadVideo",extension:{type:Re.LoadParser,priority:rs.High},config:{defaultAutoPlay:!0,defaultUpdateFPS:0,defaultLoop:!1,defaultMuted:!1,defaultPlaysinline:!0},test(s){return la(s,H2)||Zi(s,G2)},async load(s,e,t){var o;let i;const n=await(await ke.ADAPTER.fetch(s)).blob(),r=URL.createObjectURL(n);try{const a={autoPlay:this.config.defaultAutoPlay,updateFPS:this.config.defaultUpdateFPS,loop:this.config.defaultLoop,muted:this.config.defaultMuted,playsinline:this.config.defaultPlaysinline,...(o=e==null?void 0:e.data)==null?void 0:o.resourceOptions,autoLoad:!0},c=new Mb(r,a);await c.load();const l=new Ze(c,{alphaMode:await Q_(),resolution:Dn(s),...e==null?void 0:e.data});l.resource.src=s,i=wl(l,t,s),i.baseTexture.once("destroyed",()=>{URL.revokeObjectURL(r)})}catch(a){throw URL.revokeObjectURL(r),a}return i},unload(s){s.destroy(!0)}};$e.add(j2);class W2{constructor(){this._defaultBundleIdentifierOptions={connector:"-",createBundleAssetId:(e,t)=>`${e}${this._bundleIdConnector}${t}`,extractAssetIdFromBundle:(e,t)=>t.replace(`${e}${this._bundleIdConnector}`,"")},this._bundleIdConnector=this._defaultBundleIdentifierOptions.connector,this._createBundleAssetId= Line truncated
Please use Assets.add({ alias, src, data, format, loadParser }) instead.`),o.push({alias:e,src:t,data:i,format:n,loadParser:r})):Array.isArray(e)?o.push(...e):o.push(e);let a;a=c=>{this.hasKey(c)&&console.warn(`[Resolver] already has key: ${c} overwriting`)},Ts(o).forEach(c=>{const{src:l,srcs:h}=c;let{data:u,format:d,loadParser:f}=c;const p=Ts(l||h).map(v=>typeof v=="string"?x2(v):Array.isArray(v)?v:[v]),m=this.getAlias(c);Array.isArray(m)?m.forEach(a):a(m);const g=[];p.forEach(v=>{v.forEach(y=>{let x={};if(typeof y!="object"){x.src=y;for(let T=0;T<this._parsers.length;T++){const A=this._parsers[T];if(A.test(y)){x=A.parse(y);break}}}else u=y.data??u,d=y.format??d,f=y.loadParser??f,x={...x,...y};if(!m)throw new Error(`[Resolver] alias is undefined for this asset: ${x.src}`);x=this.buildResolvedAsset(x,{aliases:m,data:u,format:d,loadParser:f}),g.push(x)})}),m.forEach(v=>{this._assetMap[v]=g})})}resolveBundle(e){const t=eh(e);e=Ts(e);const i={};return e.forEach(n=>{const r=this._bundles[n];if(r){const o=this.resolve(r),a={};for(const c in o){const l=o[c];a[this._extractAssetIdFromBundle(n,c)]=l}i[n]=a}}),t?i[e[0]]:i}resolveUrl(e){const t=this.resolve(e);if(typeof e!="string"){const i={};for(const n in t)i[n]=t[n].src;return i}return t.src}resolve(e){const t=eh(e);e=Ts(e);const i={};return e.forEach(n=>{if(!this._resolverHash[n])if(this._assetMap[n]){let r=this._assetMap[n];const o=r[0],a=this._getPreferredOrder(r);a==null||a.priority.forEach(c=>{a.params[c].forEach(l=>{const h=r.filter(u=>u[c]?u[c]===l:!1);h.length&&(r=h)})}),this._resolverHash[n]=r[0]??o}else this._resolverHash[n]=this.buildResolvedAsset({alias:[n],src:n},{});i[n]=this._resolverHash[n]}),t?i[e[0]]:i}hasKey(e){return!!this._assetMap[e]}hasBundle(e){return!!this._bundles[e]}_getPreferredOrder(e){for(let t=0;t<e.length;t++){const i=e[0],n=this._preferredOrder.find(r=>r.params.format.includes(i.format));if(n)return n}return this._preferredOrder[0]}_appendDefaultSearchParams(e){if(!this._defaultSearchParams)return e;const t=/\?/.test(e)?"&":"?";return`${e}${t}${this._defaultSearchParams}`}buildResolvedAsset(e,t){const{aliases:i,data:n,loadParser:r,format:o}=t;return(this._basePath||this._rootPath)&&(e.src=Jt.toAbsolute(e.src,this._basePath,this._rootPath)),e.alias=i??e.alias??[e.src],e.src=this._appendDefaultSearchParams(e.src),e.data={...n||{},...e.data},e.loadParser=r??e.loadParser,e.format=o??e.format??Jt.extname(e.src).slice(1),e.srcs=e.src,e.name=e.alias,e}}class z2{constructor(){this._detections=[],this._initialized=!1,this.resolver=new W2,this.loader=new b2,this.cache=$r,this._backgroundLoader=new v2(this.loader),this._backgroundLoader.active=!0,this.reset()}async init(e={}){var r,o;if(this._initialized){console.warn("[Assets]AssetManager already initialized, did you load before calling this Assets.init()?");return}if(this._initialized=!0,e.defaultSearchParams&&this.resolver.setDefaultSearchParams(e.defaultSearchParams),e.basePath&&(this.resolver.basePath=e.basePath),e.bundleIdentifier&&this.resolver.setBundleIdentifier(e.bundleIdentifier),e.manifest){let a=e.manifest;typeof a=="string"&&(a=await this.load(a)),this.resolver.addManifest(a)}const t=((r=e.texturePreference)==null?void 0:r.resolution)??1,i=typeof t=="number"?[t]:t,n=await this._detectFormats({preferredFormats:(o=e.texturePreference)==null?void 0:o.format,skipDetections:e.skipDetections,detections:this._detections});this.resolver.prefer({params:{format:n,resolution:i}}),e.preferences&&this.setPreferences(e.preferences)}add(e,t,i,n,r){this.resolver.add(e,t,i,n,r)}async load(e,t){this._initialized||await this.init();const i=eh(e),n=Ts(e).map(a=>{if(typeof a!="string"){const c=this.resolver.getAlias(a);return c.some(l=>!this.resolver.hasKey(l))&&this.add(a),Array.isArray(c)?c[0]:c}return this.resolver.hasKey(a)||this.add({alias:a,src:a}),a}),r=this.resolver.resolve(n),o=await this._mapLoadToResolve(r,t);return i?o[n[0]]:o}addBundle(e,t){this.resolver.addBundle(e,t)}async loadBundle(e,t){this._initialized||await this.init();let i=!1;typeof e=="string"&&(i=!0,e=[e]);const n=this.resolver.resolveBundle(e),r={},o=Object.keys(n);let a=0,c=0;const l=()=>{t==null||t(++a/c)},h=o.map(u=>{const d=n[u];return c+=Object.keys(d).length,this._mapLoadToResolve(d,l).then(f=>{r[u]=f})});return await Promise.all(h),i?r[e[0]]:r}async backgroundLoad(e){this._initialized||await this.init(),typeof e=="string"&&(e=[e]);const t=this.resolver.resolve(e);this._backgroundLoader.add(Object.values(t))}async backgroundLoadBundle(e){this._initialized||await this.init(),typeof e=="string"&&(e=[e]);const t=this.resolver.resolveBundle(e);Object.values(t).forEach(i=>{this._backgroundLoader.add(Object.values(i))})}reset(){this.resolver.reset(),this.loader.reset(),this.cache.reset(),this._initialized=!1}get(e){if(typeof e=="string")return $r.get(e);const t={};for(let i=0;i<e.length;i++)t[i]=$r.get(e[i]);return t}async _mapLoadToResolve(e,t){const i=Object.values(e),n=Object.keys(e);this._backgroundLoader.active=!1;co Line truncated
`;let zo=null;class Ob{constructor(){zo||(zo=URL.createObjectURL(new Blob([N2],{type:"application/javascript"}))),this.worker=new Worker(zo)}}Ob.revokeObjectURL=function(){zo&&(URL.revokeObjectURL(zo),zo=null)};let q0=0,Dd;class U2{constructor(){this._initialized=!1,this._createdWorkers=0,this.workerPool=[],this.queue=[],this.resolveHash={}}isImageBitmapSupported(){return this._isImageBitmapSupported!==void 0?this._isImageBitmapSupported:(this._isImageBitmapSupported=new Promise(e=>{const{worker:t}=new Wf;t.addEventListener("message",i=>{t.terminate(),Wf.revokeObjectURL(),e(i.data)})}),this._isImageBitmapSupported)}loadImageBitmap(e){return this._run("loadImageBitmap",[e])}async _initWorkers(){this._initialized||(this._initialized=!0)}getWorker(){Dd===void 0&&(Dd=navigator.hardwareConcurrency||4);let e=this.workerPool.pop();return!e&&this._createdWorkers<Dd&&(this._createdWorkers++,e=new Ob().worker,e.addEventListener("message",t=>{this.complete(t.data),this.returnWorker(t.target),this.next()})),e}returnWorker(e){this.workerPool.push(e)}complete(e){e.error!==void 0?this.resolveHash[e.uuid].reject(e.error):this.resolveHash[e.uuid].resolve(e.data),this.resolveHash[e.uuid]=null}async _run(e,t){await this._initWorkers();const i=new Promise((n,r)=>{this.queue.push({id:e,arguments:t,resolve:n,reject:r})});return this.next(),i}next(){if(!this.queue.length)return;const e=this.getWorker();if(!e)return;const t=this.queue.pop(),i=t.id;this.resolveHash[q0]={resolve:t.resolve,reject:t.reject},e.postMessage({data:t.arguments,uuid:q0++,id:i})}}const K0=new U2;function Sl(s,e,t){s.resource.internal=!0;const i=new We(s),n=()=>{delete e.promiseCache[t],Yr.has(t)&&Yr.remove(t)};return i.baseTexture.once("destroyed",()=>{t in e.promiseCache&&(console.warn("[Assets] A BaseTexture managed by Assets was destroyed instead of unloaded! Use Assets.unload() instead of destroying the BaseTexture."),n())}),i.once("destroyed",()=>{s.destroyed||(console.warn("[Assets] A Texture managed by Assets was destroyed instead of unloaded! Use Assets.unload() instead of destroying the Texture."),n())}),i}const $2=[".jpeg",".jpg",".png",".webp",".avif"],X2=["image/jpeg","image/png","image/webp","image/avif"];async function V2(s){const e=await ke.ADAPTER.fetch(s);if(!e.ok)throw new Error(`[loadImageBitmap] Failed to fetch ${s}: ${e.status} ${e.statusText}`);const t=await e.blob();return await createImageBitmap(t)}const tu={name:"loadTextures",extension:{type:Re.LoadParser,priority:ns.High},config:{preferWorkers:!0,preferCreateImageBitmap:!0,crossOrigin:"anonymous"},test(s){return ha(s,X2)||Ki(s,$2)},async load(s,e,t){var a;const i=globalThis.createImageBitmap&&this.config.preferCreateImageBitmap;let n;i?this.config.preferWorkers&&await K0.isImageBitmapSupported()?n=await K0.loadImageBitmap(s):n=await V2(s):n=await new Promise((c,l)=>{const h=new Image;h.crossOrigin=this.config.crossOrigin,h.src=s,h.complete?c(h):(h.onload=()=>c(h),h.onerror=u=>l(u))});const r={...e.data};r.resolution??(r.resolution=Xn(s)),i&&((a=r.resourceOptions)==null?void 0:a.ownsImageBitmap)===void 0&&(r.resourceOptions={...r.resourceOptions},r.resourceOptions.ownsImageBitmap=!0);const o=new Je(n,r);return o.resource.src=s,Sl(o,t,s)},unload(s){s.destroy(!0)}};Ue.add(tu);const Y2=".svg",G2="image/svg+xml",H2={extension:{type:Re.LoadParser,priority:ns.High},name:"loadSVG",test(s){return ha(s,G2)||Ki(s,Y2)},async testParse(s){return Df.test(s)},async parse(s,e,t){var r;const i=new Df(s,(r=e==null?void 0:e.data)==null?void 0:r.resourceOptions);await i.load();const n=new Je(i,{resolution:Xn(s),...e==null?void 0:e.data});return n.resource.src=e.src,Sl(n,t,e.src)},async load(s,e){return(await ke.ADAPTER.fetch(s)).text()},unload:tu.unload};Ue.add(H2);const j2=[".mp4",".m4v",".webm",".ogv"],W2=["video/mp4","video/webm","video/ogg"],z2={name:"loadVideo",extension:{type:Re.LoadParser,priority:ns.High},config:{defaultAutoPlay:!0,defaultUpdateFPS:0,defaultLoop:!1,defaultMuted:!1,defaultPlaysinline:!0},test(s){return ha(s,W2)||Ki(s,j2)},async load(s,e,t){var o;let i;const n=await(await ke.ADAPTER.fetch(s)).blob(),r=URL.createObjectURL(n);try{const a={autoPlay:this.config.defaultAutoPlay,updateFPS:this.config.defaultUpdateFPS,loop:this.config.defaultLoop,muted:this.config.defaultMuted,playsinline:this.config.defaultPlaysinline,...(o=e==null?void 0:e.data)==null?void 0:o.resourceOptions,autoLoad:!0},c=new Cb(r,a);await c.load();const l=new Je(c,{alphaMode:await tC(),resolution:Xn(s),...e==null?void 0:e.data});l.resource.src=s,i=Sl(l,t,s),i.baseTexture.once("destroyed",()=>{URL.revokeObjectURL(r)})}catch(a){throw URL.revokeObjectURL(r),a}return i},unload(s){s.destroy(!0)}};Ue.add(z2);class q2{constructor(){this._defaultBundleIdentifierOptions={connector:"-",createBundleAssetId:(e,t)=>`${e}${this._bundleIdConnector}${t}`,extractAssetIdFromBundle:(e,t)=>t.replace(`${e}${this._bundleIdConnector}`,"")},this._bundleIdConnector=this._defaultBundleIdentifierOptions.connector,this._createBundleAssetId= Line truncated
Please use Assets.add({ alias, src, data, format, loadParser }) instead.`),o.push({alias:e,src:t,data:i,format:n,loadParser:r})):Array.isArray(e)?o.push(...e):o.push(e);let a;a=c=>{this.hasKey(c)&&console.warn(`[Resolver] already has key: ${c} overwriting`)},Ms(o).forEach(c=>{const{src:l,srcs:h}=c;let{data:u,format:d,loadParser:f}=c;const p=Ms(l||h).map(v=>typeof v=="string"?b2(v):Array.isArray(v)?v:[v]),m=this.getAlias(c);Array.isArray(m)?m.forEach(a):a(m);const g=[];p.forEach(v=>{v.forEach(y=>{let x={};if(typeof y!="object"){x.src=y;for(let T=0;T<this._parsers.length;T++){const A=this._parsers[T];if(A.test(y)){x=A.parse(y);break}}}else u=y.data??u,d=y.format??d,f=y.loadParser??f,x={...x,...y};if(!m)throw new Error(`[Resolver] alias is undefined for this asset: ${x.src}`);x=this.buildResolvedAsset(x,{aliases:m,data:u,format:d,loadParser:f}),g.push(x)})}),m.forEach(v=>{this._assetMap[v]=g})})}resolveBundle(e){const t=eh(e);e=Ms(e);const i={};return e.forEach(n=>{const r=this._bundles[n];if(r){const o=this.resolve(r),a={};for(const c in o){const l=o[c];a[this._extractAssetIdFromBundle(n,c)]=l}i[n]=a}}),t?i[e[0]]:i}resolveUrl(e){const t=this.resolve(e);if(typeof e!="string"){const i={};for(const n in t)i[n]=t[n].src;return i}return t.src}resolve(e){const t=eh(e);e=Ms(e);const i={};return e.forEach(n=>{if(!this._resolverHash[n])if(this._assetMap[n]){let r=this._assetMap[n];const o=r[0],a=this._getPreferredOrder(r);a==null||a.priority.forEach(c=>{a.params[c].forEach(l=>{const h=r.filter(u=>u[c]?u[c]===l:!1);h.length&&(r=h)})}),this._resolverHash[n]=r[0]??o}else this._resolverHash[n]=this.buildResolvedAsset({alias:[n],src:n},{});i[n]=this._resolverHash[n]}),t?i[e[0]]:i}hasKey(e){return!!this._assetMap[e]}hasBundle(e){return!!this._bundles[e]}_getPreferredOrder(e){for(let t=0;t<e.length;t++){const i=e[0],n=this._preferredOrder.find(r=>r.params.format.includes(i.format));if(n)return n}return this._preferredOrder[0]}_appendDefaultSearchParams(e){if(!this._defaultSearchParams)return e;const t=/\?/.test(e)?"&":"?";return`${e}${t}${this._defaultSearchParams}`}buildResolvedAsset(e,t){const{aliases:i,data:n,loadParser:r,format:o}=t;return(this._basePath||this._rootPath)&&(e.src=Qt.toAbsolute(e.src,this._basePath,this._rootPath)),e.alias=i??e.alias??[e.src],e.src=this._appendDefaultSearchParams(e.src),e.data={...n||{},...e.data},e.loadParser=r??e.loadParser,e.format=o??e.format??Qt.extname(e.src).slice(1),e.srcs=e.src,e.name=e.alias,e}}class K2{constructor(){this._detections=[],this._initialized=!1,this.resolver=new q2,this.loader=new S2,this.cache=Yr,this._backgroundLoader=new y2(this.loader),this._backgroundLoader.active=!0,this.reset()}async init(e={}){var r,o;if(this._initialized){console.warn("[Assets]AssetManager already initialized, did you load before calling this Assets.init()?");return}if(this._initialized=!0,e.defaultSearchParams&&this.resolver.setDefaultSearchParams(e.defaultSearchParams),e.basePath&&(this.resolver.basePath=e.basePath),e.bundleIdentifier&&this.resolver.setBundleIdentifier(e.bundleIdentifier),e.manifest){let a=e.manifest;typeof a=="string"&&(a=await this.load(a)),this.resolver.addManifest(a)}const t=((r=e.texturePreference)==null?void 0:r.resolution)??1,i=typeof t=="number"?[t]:t,n=await this._detectFormats({preferredFormats:(o=e.texturePreference)==null?void 0:o.format,skipDetections:e.skipDetections,detections:this._detections});this.resolver.prefer({params:{format:n,resolution:i}}),e.preferences&&this.setPreferences(e.preferences)}add(e,t,i,n,r){this.resolver.add(e,t,i,n,r)}async load(e,t){this._initialized||await this.init();const i=eh(e),n=Ms(e).map(a=>{if(typeof a!="string"){const c=this.resolver.getAlias(a);return c.some(l=>!this.resolver.hasKey(l))&&this.add(a),Array.isArray(c)?c[0]:c}return this.resolver.hasKey(a)||this.add({alias:a,src:a}),a}),r=this.resolver.resolve(n),o=await this._mapLoadToResolve(r,t);return i?o[n[0]]:o}addBundle(e,t){this.resolver.addBundle(e,t)}async loadBundle(e,t){this._initialized||await this.init();let i=!1;typeof e=="string"&&(i=!0,e=[e]);const n=this.resolver.resolveBundle(e),r={},o=Object.keys(n);let a=0,c=0;const l=()=>{t==null||t(++a/c)},h=o.map(u=>{const d=n[u];return c+=Object.keys(d).length,this._mapLoadToResolve(d,l).then(f=>{r[u]=f})});return await Promise.all(h),i?r[e[0]]:r}async backgroundLoad(e){this._initialized||await this.init(),typeof e=="string"&&(e=[e]);const t=this.resolver.resolve(e);this._backgroundLoader.add(Object.values(t))}async backgroundLoadBundle(e){this._initialized||await this.init(),typeof e=="string"&&(e=[e]);const t=this.resolver.resolveBundle(e);Object.values(t).forEach(i=>{this._backgroundLoader.add(Object.values(i))})}reset(){this.resolver.reset(),this.loader.reset(),this.cache.reset(),this._initialized=!1}get(e){if(typeof e=="string")return Yr.get(e);const t={};for(let i=0;i<e.length;i++)t[i]=Yr.get(e[i]);return t}async _mapLoadToResolve(e,t){const i=Object.values(e),n=Object.keys(e);this._backgroundLoader.active=!1;co Line truncated
uniform vec4 uColor;
uniform sampler2D uSampler;
@@ -939,7 +939,7 @@ void main(void)
{
gl_FragColor = texture2D(uSampler, vTextureCoord) * uColor;
}
`,GE=`attribute vec2 aVertexPosition;
`,jE=`attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
uniform mat3 projectionMatrix;
@@ -954,7 +954,7 @@ void main(void)
vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;
}
`;class nh extends Ps{constructor(e,t){const i={uSampler:e,alpha:1,uTextureMatrix:Dt.IDENTITY,uColor:new Float32Array([1,1,1,1])};t=Object.assign({tint:16777215,alpha:1,pluginName:"batch"},t),t.uniforms&&Object.assign(i,t.uniforms),super(t.program||en.from(GE,YE),i),this._colorDirty=!1,this.uvMatrix=new Qm(e),this.batchable=t.program===void 0,this.pluginName=t.pluginName,this._tintColor=new Tt(t.tint),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._colorDirty=!0,this.alpha=t.alpha}get texture(){return this.uniforms.uSampler}set texture(e){this.uniforms.uSampler!==e&&(!this.uniforms.uSampler.baseTexture.alphaMode!=!e.baseTexture.alphaMode&&(this._colorDirty=!0),this.uniforms.uSampler=e,this.uvMatrix.texture=e)}set alpha(e){e!==this._alpha&&(this._alpha=e,this._colorDirty=!0)}get alpha(){return this._alpha}set tint(e){e!==this.tint&&(this._tintColor.setValue(e),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._colorDirty=!0)}get tint(){return this._tintColor.value}get tintValue(){return this._tintColor.toNumber()}update(){if(this._colorDirty){this._colorDirty=!1;const e=this.texture.baseTexture.alphaMode;Tt.shared.setValue(this._tintColor).premultiply(this._alpha,e).toArray(this.uniforms.uColor)}this.uvMatrix.update()&&(this.uniforms.uTextureMatrix=this.uvMatrix.mapCoord)}}class HE extends cl{constructor(e=ze.EMPTY,t,i,n,r){const o=new rp(t,i,n);o.getBuffer("aVertexPosition").static=!1;const a=new nh(e);super(o,a,null,r),this.autoUpdate=!0}get vertices(){return this.geometry.getBuffer("aVertexPosition").data}set vertices(e){this.geometry.getBuffer("aVertexPosition").data=e}_render(e){this.autoUpdate&&this.geometry.getBuffer("aVertexPosition").update(),super._render(e)}}class lv{constructor(e,t,i){this.geometry=new an,this.indexBuffer=null,this.size=i,this.dynamicProperties=[],this.staticProperties=[];for(let n=0;n<e.length;++n){let r=e[n];r={attributeName:r.attributeName,size:r.size,uploadFunction:r.uploadFunction,type:r.type||Ue.FLOAT,offset:r.offset},t[n]?this.dynamicProperties.push(r):this.staticProperties.push(r)}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()}initBuffers(){const e=this.geometry;let t=0;this.indexBuffer=new Lt(fC(this.size),!0,!0),e.addIndex(this.indexBuffer),this.dynamicStride=0;for(let o=0;o<this.dynamicProperties.length;++o){const a=this.dynamicProperties[o];a.offset=t,t+=a.size,this.dynamicStride+=a.size}const i=new ArrayBuffer(this.size*this.dynamicStride*4*4);this.dynamicData=new Float32Array(i),this.dynamicDataUint32=new Uint32Array(i),this.dynamicBuffer=new Lt(this.dynamicData,!1,!1);let n=0;this.staticStride=0;for(let o=0;o<this.staticProperties.length;++o){const a=this.staticProperties[o];a.offset=n,n+=a.size,this.staticStride+=a.size}const r=new ArrayBuffer(this.size*this.staticStride*4*4);this.staticData=new Float32Array(r),this.staticDataUint32=new Uint32Array(r),this.staticBuffer=new Lt(this.staticData,!0,!1);for(let o=0;o<this.dynamicProperties.length;++o){const a=this.dynamicProperties[o];e.addAttribute(a.attributeName,this.dynamicBuffer,0,a.type===Ue.UNSIGNED_BYTE,a.type,this.dynamicStride*4,a.offset*4)}for(let o=0;o<this.staticProperties.length;++o){const a=this.staticProperties[o];e.addAttribute(a.attributeName,this.staticBuffer,0,a.type===Ue.UNSIGNED_BYTE,a.type,this.staticStride*4,a.offset*4)}}uploadDynamic(e,t,i){for(let n=0;n<this.dynamicProperties.length;n++){const r=this.dynamicProperties[n];r.uploadFunction(e,t,i,r.type===Ue.UNSIGNED_BYTE?this.dynamicDataUint32:this.dynamicData,this.dynamicStride,r.offset)}this.dynamicBuffer._updateID++}uploadStatic(e,t,i){for(let n=0;n<this.staticProperties.length;n++){const r=this.staticProperties[n];r.uploadFunction(e,t,i,r.type===Ue.UNSIGNED_BYTE?this.staticDataUint32:this.staticData,this.staticStride,r.offset)}this.staticBuffer._updateID++}destroy(){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()}}var jE=`varying vec2 vTextureCoord;
`;class nh extends ks{constructor(e,t){const i={uSampler:e,alpha:1,uTextureMatrix:Ut.IDENTITY,uColor:new Float32Array([1,1,1,1])};t=Object.assign({tint:16777215,alpha:1,pluginName:"batch"},t),t.uniforms&&Object.assign(i,t.uniforms),super(t.program||nn.from(jE,HE),i),this._colorDirty=!1,this.uvMatrix=new Qm(e),this.batchable=t.program===void 0,this.pluginName=t.pluginName,this._tintColor=new Mt(t.tint),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._colorDirty=!0,this.alpha=t.alpha}get texture(){return this.uniforms.uSampler}set texture(e){this.uniforms.uSampler!==e&&(!this.uniforms.uSampler.baseTexture.alphaMode!=!e.baseTexture.alphaMode&&(this._colorDirty=!0),this.uniforms.uSampler=e,this.uvMatrix.texture=e)}set alpha(e){e!==this._alpha&&(this._alpha=e,this._colorDirty=!0)}get alpha(){return this._alpha}set tint(e){e!==this.tint&&(this._tintColor.setValue(e),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._colorDirty=!0)}get tint(){return this._tintColor.value}get tintValue(){return this._tintColor.toNumber()}update(){if(this._colorDirty){this._colorDirty=!1;const e=this.texture.baseTexture.alphaMode;Mt.shared.setValue(this._tintColor).premultiply(this._alpha,e).toArray(this.uniforms.uColor)}this.uvMatrix.update()&&(this.uniforms.uTextureMatrix=this.uvMatrix.mapCoord)}}class WE extends hl{constructor(e=We.EMPTY,t,i,n,r){const o=new rp(t,i,n);o.getBuffer("aVertexPosition").static=!1;const a=new nh(e);super(o,a,null,r),this.autoUpdate=!0}get vertices(){return this.geometry.getBuffer("aVertexPosition").data}set vertices(e){this.geometry.getBuffer("aVertexPosition").data=e}_render(e){this.autoUpdate&&this.geometry.getBuffer("aVertexPosition").update(),super._render(e)}}class lv{constructor(e,t,i){this.geometry=new hn,this.indexBuffer=null,this.size=i,this.dynamicProperties=[],this.staticProperties=[];for(let n=0;n<e.length;++n){let r=e[n];r={attributeName:r.attributeName,size:r.size,uploadFunction:r.uploadFunction,type:r.type||Ne.FLOAT,offset:r.offset},t[n]?this.dynamicProperties.push(r):this.staticProperties.push(r)}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()}initBuffers(){const e=this.geometry;let t=0;this.indexBuffer=new Nt(pC(this.size),!0,!0),e.addIndex(this.indexBuffer),this.dynamicStride=0;for(let o=0;o<this.dynamicProperties.length;++o){const a=this.dynamicProperties[o];a.offset=t,t+=a.size,this.dynamicStride+=a.size}const i=new ArrayBuffer(this.size*this.dynamicStride*4*4);this.dynamicData=new Float32Array(i),this.dynamicDataUint32=new Uint32Array(i),this.dynamicBuffer=new Nt(this.dynamicData,!1,!1);let n=0;this.staticStride=0;for(let o=0;o<this.staticProperties.length;++o){const a=this.staticProperties[o];a.offset=n,n+=a.size,this.staticStride+=a.size}const r=new ArrayBuffer(this.size*this.staticStride*4*4);this.staticData=new Float32Array(r),this.staticDataUint32=new Uint32Array(r),this.staticBuffer=new Nt(this.staticData,!0,!1);for(let o=0;o<this.dynamicProperties.length;++o){const a=this.dynamicProperties[o];e.addAttribute(a.attributeName,this.dynamicBuffer,0,a.type===Ne.UNSIGNED_BYTE,a.type,this.dynamicStride*4,a.offset*4)}for(let o=0;o<this.staticProperties.length;++o){const a=this.staticProperties[o];e.addAttribute(a.attributeName,this.staticBuffer,0,a.type===Ne.UNSIGNED_BYTE,a.type,this.staticStride*4,a.offset*4)}}uploadDynamic(e,t,i){for(let n=0;n<this.dynamicProperties.length;n++){const r=this.dynamicProperties[n];r.uploadFunction(e,t,i,r.type===Ne.UNSIGNED_BYTE?this.dynamicDataUint32:this.dynamicData,this.dynamicStride,r.offset)}this.dynamicBuffer._updateID++}uploadStatic(e,t,i){for(let n=0;n<this.staticProperties.length;n++){const r=this.staticProperties[n];r.uploadFunction(e,t,i,r.type===Ne.UNSIGNED_BYTE?this.staticDataUint32:this.staticData,this.staticStride,r.offset)}this.staticBuffer._updateID++}destroy(){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()}}var zE=`varying vec2 vTextureCoord;
varying vec4 vColor;
uniform sampler2D uSampler;
@@ -962,7 +962,7 @@ uniform sampler2D uSampler;
void main(void){
vec4 color = texture2D(uSampler, vTextureCoord) * vColor;
gl_FragColor = color;
}`,WE=`attribute vec2 aVertexPosition;
}`,qE=`attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
attribute vec4 aColor;
@@ -987,8 +987,8 @@ void main(void){
vTextureCoord = aTextureCoord;
vColor = aColor * uColor;
}
`;class $b extends eu{constructor(e){super(e),this.shader=null,this.properties=null,this.tempMatrix=new Dt,this.properties=[{attributeName:"aVertexPosition",size:2,uploadFunction:this.uploadVertices,offset:0},{attributeName:"aPositionCoord",size:2,uploadFunction:this.uploadPosition,offset:0},{attributeName:"aRotation",size:1,uploadFunction:this.uploadRotation,offset:0},{attributeName:"aTextureCoord",size:2,uploadFunction:this.uploadUvs,offset:0},{attributeName:"aColor",size:1,type:Ue.UNSIGNED_BYTE,uploadFunction:this.uploadTint,offset:0}],this.shader=Ps.from(WE,jE,{}),this.state=ln.for2d()}render(e){const t=e.children,i=e._maxSize,n=e._batchSize,r=this.renderer;let o=t.length;if(o===0)return;o>i&&!e.autoResize&&(o=i);let a=e._buffers;a||(a=e._buffers=this.generateBuffers(e));const c=t[0]._texture.baseTexture,l=c.alphaMode>0;this.state.blendMode=Ny(e.blendMode,l),r.state.set(this.state);const h=r.gl,u=e.worldTransform.copyTo(this.tempMatrix);u.prepend(r.globalUniforms.uniforms.projectionMatrix),this.shader.uniforms.translationMatrix=u.toArray(!0),this.shader.uniforms.uColor=Tt.shared.setValue(e.tintRgb).premultiply(e.worldAlpha,l).toArray(this.shader.uniforms.uColor),this.shader.uniforms.uSampler=c,this.renderer.shader.bind(this.shader);let d=!1;for(let f=0,p=0;f<o;f+=n,p+=1){let m=o-f;m>n&&(m=n),p>=a.length&&a.push(this._generateOneMoreBuffer(e));const g=a[p];g.uploadDynamic(t,f,m);const v=e._bufferUpdateIDs[p]||0;d=d||g._updateID<v,d&&(g._updateID=e._updateID,g.uploadStatic(t,f,m)),r.geometry.bind(g.geometry),h.drawElements(h.TRIANGLES,m*6,h.UNSIGNED_SHORT,0)}}generateBuffers(e){const t=[],i=e._maxSize,n=e._batchSize,r=e._properties;for(let o=0;o<i;o+=n)t.push(new lv(this.properties,r,n));return t}_generateOneMoreBuffer(e){const t=e._batchSize,i=e._properties;return new lv(this.properties,i,t)}uploadVertices(e,t,i,n,r,o){let a=0,c=0,l=0,h=0;for(let u=0;u<i;++u){const d=e[t+u],f=d._texture,p=d.scale.x,m=d.scale.y,g=f.trim,v=f.orig;g?(c=g.x-d.anchor.x*v.width,a=c+g.width,h=g.y-d.anchor.y*v.height,l=h+g.height):(a=v.width*(1-d.anchor.x),c=v.width*-d.anchor.x,l=v.height*(1-d.anchor.y),h=v.height*-d.anchor.y),n[o]=c*p,n[o+1]=h*m,n[o+r]=a*p,n[o+r+1]=h*m,n[o+r*2]=a*p,n[o+r*2+1]=l*m,n[o+r*3]=c*p,n[o+r*3+1]=l*m,o+=r*4}}uploadPosition(e,t,i,n,r,o){for(let a=0;a<i;a++){const c=e[t+a].position;n[o]=c.x,n[o+1]=c.y,n[o+r]=c.x,n[o+r+1]=c.y,n[o+r*2]=c.x,n[o+r*2+1]=c.y,n[o+r*3]=c.x,n[o+r*3+1]=c.y,o+=r*4}}uploadRotation(e,t,i,n,r,o){for(let a=0;a<i;a++){const c=e[t+a].rotation;n[o]=c,n[o+r]=c,n[o+r*2]=c,n[o+r*3]=c,o+=r*4}}uploadUvs(e,t,i,n,r,o){for(let a=0;a<i;++a){const c=e[t+a]._texture._uvs;c?(n[o]=c.x0,n[o+1]=c.y0,n[o+r]=c.x1,n[o+r+1]=c.y1,n[o+r*2]=c.x2,n[o+r*2+1]=c.y2,n[o+r*3]=c.x3,n[o+r*3+1]=c.y3,o+=r*4):(n[o]=0,n[o+1]=0,n[o+r]=0,n[o+r+1]=0,n[o+r*2]=0,n[o+r*2+1]=0,n[o+r*3]=0,n[o+r*3+1]=0,o+=r*4)}}uploadTint(e,t,i,n,r,o){for(let a=0;a<i;++a){const c=e[t+a],l=Tt.shared.setValue(c._tintRGB).toPremultiplied(c.alpha,c.texture.baseTexture.alphaMode>0);n[o]=l,n[o+r]=l,n[o+r*2]=l,n[o+r*3]=l,o+=r*4}}destroy(){super.destroy(),this.shader&&(this.shader.destroy(),this.shader=null),this.tempMatrix=null}}$b.extension={name:"particle",type:Re.RendererPlugin};$e.add($b);var su=(s=>(s[s.LINEAR_VERTICAL=0]="LINEAR_VERTICAL",s[s.LINEAR_HORIZONTAL=1]="LINEAR_HORIZONTAL",s))(su||{});const Ql={willReadFrequently:!0},Us=class Ve{static get experimentalLetterSpacingSupported(){let e=Ve._experimentalLetterSpacingSupported;if(e!==void 0){const t=ke.ADAPTER.getCanvasRenderingContext2D().prototype;e=Ve._experimentalLetterSpacingSupported="letterSpacing"in t||"textLetterSpacing"in t}return e}constructor(e,t,i,n,r,o,a,c,l){this.text=e,this.style=t,this.width=i,this.height=n,this.lines=r,this.lineWidths=o,this.lineHeight=a,this.maxLineWidth=c,this.fontProperties=l}static measureText(e,t,i,n=Ve._canvas){i=i??t.wordWrap;const r=t.toFontString(),o=Ve.measureFont(r);o.fontSize===0&&(o.fontSize=t.fontSize,o.ascent=t.fontSize);const a=n.getContext("2d",Ql);a.font=r;const c=(i?Ve.wordWrap(e,t,n):e).split(/(?:\r\n|\r|\n)/),l=new Array(c.length);let h=0;for(let p=0;p<c.length;p++){const m=Ve._measureText(c[p],t.letterSpacing,a);l[p]=m,h=Math.max(h,m)}let u=h+t.strokeThickness;t.dropShadow&&(u+=t.dropShadowDistance);const d=t.lineHeight||o.fontSize+t.strokeThickness;let f=Math.max(d,o.fontSize+t.strokeThickness*2)+t.leading+(c.length-1)*(d+t.leading);return t.dropShadow&&(f+=t.dropShadowDistance),new Ve(e,t,u,f,c,l,d+t.leading,h,o)}static _measureText(e,t,i){let n=!1;Ve.experimentalLetterSpacingSupported&&(Ve.experimentalLetterSpacing?(i.letterSpacing=`${t}px`,i.textLetterSpacing=`${t}px`,n=!0):(i.letterSpacing="0px",i.textLetterSpacing="0px"));let r=i.measureText(e).width;return r>0&&(n?r-=t:r+=(Ve.graphemeSegmenter(e).length-1)*t),r}static wordWrap(e,t,i=Ve._canvas){const n=i.getContext("2d",Ql);let r=0,o="",a="";const c=Object.create(null),{letterSpacing:l,whiteSpace:h}=t,u=Ve.collapseSpaces(h),d=Ve.collapseNewlines(h);let f=!u;const p=t.wordWrapWidth+l, Line truncated
`:e,e}static getFromCache(e,t,i,n){let r=i[e];return typeof r!="number"&&(r=Ve._measureText(e,t,n)+t,i[e]=r),r}static collapseSpaces(e){return e==="normal"||e==="pre-line"}static collapseNewlines(e){return e==="normal"}static trimRight(e){if(typeof e!="string")return"";for(let t=e.length-1;t>=0;t--){const i=e[t];if(!Ve.isBreakingSpace(i))break;e=e.slice(0,-1)}return e}static isNewline(e){return typeof e!="string"?!1:Ve._newlines.includes(e.charCodeAt(0))}static isBreakingSpace(e,t){return typeof e!="string"?!1:Ve._breakingSpaces.includes(e.charCodeAt(0))}static tokenize(e){const t=[];let i="";if(typeof e!="string")return t;for(let n=0;n<e.length;n++){const r=e[n],o=e[n+1];if(Ve.isBreakingSpace(r,o)||Ve.isNewline(r)){i!==""&&(t.push(i),i=""),t.push(r);continue}i+=r}return i!==""&&t.push(i),t}static canBreakWords(e,t){return t}static canBreakChars(e,t,i,n,r){return!0}static wordWrapSplit(e){return Ve.graphemeSegmenter(e)}static measureFont(e){if(Ve._fonts[e])return Ve._fonts[e];const t={ascent:0,descent:0,fontSize:0},i=Ve._canvas,n=Ve._context;n.font=e;const r=Ve.METRICS_STRING+Ve.BASELINE_SYMBOL,o=Math.ceil(n.measureText(r).width);let a=Math.ceil(n.measureText(Ve.BASELINE_SYMBOL).width);const c=Math.ceil(Ve.HEIGHT_MULTIPLIER*a);if(a=a*Ve.BASELINE_MULTIPLIER|0,o===0||c===0)return Ve._fonts[e]=t,t;i.width=o,i.height=c,n.fillStyle="#f00",n.fillRect(0,0,o,c),n.font=e,n.textBaseline="alphabetic",n.fillStyle="#000",n.fillText(r,0,a);const l=n.getImageData(0,0,o,c).data,h=l.length,u=o*4;let d=0,f=0,p=!1;for(d=0;d<a;++d){for(let m=0;m<u;m+=4)if(l[f+m]!==255){p=!0;break}if(!p)f+=u;else break}for(t.ascent=a-d,f=h-u,p=!1,d=c;d>a;--d){for(let m=0;m<u;m+=4)if(l[f+m]!==255){p=!0;break}if(!p)f-=u;else break}return t.descent=d-a,t.fontSize=t.ascent+t.descent,Ve._fonts[e]=t,t}static clearMetrics(e=""){e?delete Ve._fonts[e]:Ve._fonts={}}static get _canvas(){var e;if(!Ve.__canvas){let t;try{const i=new OffscreenCanvas(0,0);if((e=i.getContext("2d",Ql))!=null&&e.measureText)return Ve.__canvas=i,i;t=ke.ADAPTER.createCanvas()}catch{t=ke.ADAPTER.createCanvas()}t.width=t.height=10,Ve.__canvas=t}return Ve.__canvas}static get _context(){return Ve.__context||(Ve.__context=Ve._canvas.getContext("2d",Ql)),Ve.__context}};Us.METRICS_STRING="|ÉqÅ",Us.BASELINE_SYMBOL="M",Us.BASELINE_MULTIPLIER=1.4,Us.HEIGHT_MULTIPLIER=2,Us.graphemeSegmenter=(()=>{if(typeof(Intl==null?void 0:Intl.Segmenter)=="function"){const s=new Intl.Segmenter;return e=>[...s.segment(e)].map(t=>t.segment)}return s=>[...s]})(),Us.experimentalLetterSpacing=!1,Us._fonts={},Us._newlines=[10,13],Us._breakingSpaces=[9,32,8192,8193,8194,8195,8196,8197,8198,8200,8201,8202,8287,12288];let Zn=Us;const zE=["serif","sans-serif","monospace","cursive","fantasy","system-ui"],Xb=class Ba{constructor(e){this.styleID=0,this.reset(),Yd(this,e,e)}clone(){const e={};return Yd(e,this,Ba.defaultStyle),new Ba(e)}reset(){Yd(this,Ba.defaultStyle,Ba.defaultStyle)}get align(){return this._align}set align(e){this._align!==e&&(this._align=e,this.styleID++)}get breakWords(){return this._breakWords}set breakWords(e){this._breakWords!==e&&(this._breakWords=e,this.styleID++)}get dropShadow(){return this._dropShadow}set dropShadow(e){this._dropShadow!==e&&(this._dropShadow=e,this.styleID++)}get dropShadowAlpha(){return this._dropShadowAlpha}set dropShadowAlpha(e){this._dropShadowAlpha!==e&&(this._dropShadowAlpha=e,this.styleID++)}get dropShadowAngle(){return this._dropShadowAngle}set dropShadowAngle(e){this._dropShadowAngle!==e&&(this._dropShadowAngle=e,this.styleID++)}get dropShadowBlur(){return this._dropShadowBlur}set dropShadowBlur(e){this._dropShadowBlur!==e&&(this._dropShadowBlur=e,this.styleID++)}get dropShadowColor(){return this._dropShadowColor}set dropShadowColor(e){const t=Vd(e);this._dropShadowColor!==t&&(this._dropShadowColor=t,this.styleID++)}get dropShadowDistance(){return this._dropShadowDistance}set dropShadowDistance(e){this._dropShadowDistance!==e&&(this._dropShadowDistance=e,this.styleID++)}get fill(){return this._fill}set fill(e){const t=Vd(e);this._fill!==t&&(this._fill=t,this.styleID++)}get fillGradientType(){return this._fillGradientType}set fillGradientType(e){this._fillGradientType!==e&&(this._fillGradientType=e,this.styleID++)}get fillGradientStops(){return this._fillGradientStops}set fillGradientStops(e){qE(this._fillGradientStops,e)||(this._fillGradientStops=e,this.styleID++)}get fontFamily(){return this._fontFamily}set fontFamily(e){this.fontFamily!==e&&(this._fontFamily=e,this.styleID++)}get fontSize(){return this._fontSize}set fontSize(e){this._fontSize!==e&&(this._fontSize=e,this.styleID++)}get fontStyle(){return this._fontStyle}set fontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.styleID++)}get fontVariant(){return this._fontVariant}set fontVariant(e){this._fontVariant!==e&&(this._fontVariant=e,this.styleID++)}get fontWeight(){return this._fontWeight}set fontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.styleID++)}get letterSpacing(){return this._lett Line truncated
`;class Vb extends eu{constructor(e){super(e),this.shader=null,this.properties=null,this.tempMatrix=new Ut,this.properties=[{attributeName:"aVertexPosition",size:2,uploadFunction:this.uploadVertices,offset:0},{attributeName:"aPositionCoord",size:2,uploadFunction:this.uploadPosition,offset:0},{attributeName:"aRotation",size:1,uploadFunction:this.uploadRotation,offset:0},{attributeName:"aTextureCoord",size:2,uploadFunction:this.uploadUvs,offset:0},{attributeName:"aColor",size:1,type:Ne.UNSIGNED_BYTE,uploadFunction:this.uploadTint,offset:0}],this.shader=ks.from(qE,zE,{}),this.state=un.for2d()}render(e){const t=e.children,i=e._maxSize,n=e._batchSize,r=this.renderer;let o=t.length;if(o===0)return;o>i&&!e.autoResize&&(o=i);let a=e._buffers;a||(a=e._buffers=this.generateBuffers(e));const c=t[0]._texture.baseTexture,l=c.alphaMode>0;this.state.blendMode=$y(e.blendMode,l),r.state.set(this.state);const h=r.gl,u=e.worldTransform.copyTo(this.tempMatrix);u.prepend(r.globalUniforms.uniforms.projectionMatrix),this.shader.uniforms.translationMatrix=u.toArray(!0),this.shader.uniforms.uColor=Mt.shared.setValue(e.tintRgb).premultiply(e.worldAlpha,l).toArray(this.shader.uniforms.uColor),this.shader.uniforms.uSampler=c,this.renderer.shader.bind(this.shader);let d=!1;for(let f=0,p=0;f<o;f+=n,p+=1){let m=o-f;m>n&&(m=n),p>=a.length&&a.push(this._generateOneMoreBuffer(e));const g=a[p];g.uploadDynamic(t,f,m);const v=e._bufferUpdateIDs[p]||0;d=d||g._updateID<v,d&&(g._updateID=e._updateID,g.uploadStatic(t,f,m)),r.geometry.bind(g.geometry),h.drawElements(h.TRIANGLES,m*6,h.UNSIGNED_SHORT,0)}}generateBuffers(e){const t=[],i=e._maxSize,n=e._batchSize,r=e._properties;for(let o=0;o<i;o+=n)t.push(new lv(this.properties,r,n));return t}_generateOneMoreBuffer(e){const t=e._batchSize,i=e._properties;return new lv(this.properties,i,t)}uploadVertices(e,t,i,n,r,o){let a=0,c=0,l=0,h=0;for(let u=0;u<i;++u){const d=e[t+u],f=d._texture,p=d.scale.x,m=d.scale.y,g=f.trim,v=f.orig;g?(c=g.x-d.anchor.x*v.width,a=c+g.width,h=g.y-d.anchor.y*v.height,l=h+g.height):(a=v.width*(1-d.anchor.x),c=v.width*-d.anchor.x,l=v.height*(1-d.anchor.y),h=v.height*-d.anchor.y),n[o]=c*p,n[o+1]=h*m,n[o+r]=a*p,n[o+r+1]=h*m,n[o+r*2]=a*p,n[o+r*2+1]=l*m,n[o+r*3]=c*p,n[o+r*3+1]=l*m,o+=r*4}}uploadPosition(e,t,i,n,r,o){for(let a=0;a<i;a++){const c=e[t+a].position;n[o]=c.x,n[o+1]=c.y,n[o+r]=c.x,n[o+r+1]=c.y,n[o+r*2]=c.x,n[o+r*2+1]=c.y,n[o+r*3]=c.x,n[o+r*3+1]=c.y,o+=r*4}}uploadRotation(e,t,i,n,r,o){for(let a=0;a<i;a++){const c=e[t+a].rotation;n[o]=c,n[o+r]=c,n[o+r*2]=c,n[o+r*3]=c,o+=r*4}}uploadUvs(e,t,i,n,r,o){for(let a=0;a<i;++a){const c=e[t+a]._texture._uvs;c?(n[o]=c.x0,n[o+1]=c.y0,n[o+r]=c.x1,n[o+r+1]=c.y1,n[o+r*2]=c.x2,n[o+r*2+1]=c.y2,n[o+r*3]=c.x3,n[o+r*3+1]=c.y3,o+=r*4):(n[o]=0,n[o+1]=0,n[o+r]=0,n[o+r+1]=0,n[o+r*2]=0,n[o+r*2+1]=0,n[o+r*3]=0,n[o+r*3+1]=0,o+=r*4)}}uploadTint(e,t,i,n,r,o){for(let a=0;a<i;++a){const c=e[t+a],l=Mt.shared.setValue(c._tintRGB).toPremultiplied(c.alpha,c.texture.baseTexture.alphaMode>0);n[o]=l,n[o+r]=l,n[o+r*2]=l,n[o+r*3]=l,o+=r*4}}destroy(){super.destroy(),this.shader&&(this.shader.destroy(),this.shader=null),this.tempMatrix=null}}Vb.extension={name:"particle",type:Re.RendererPlugin};Ue.add(Vb);var su=(s=>(s[s.LINEAR_VERTICAL=0]="LINEAR_VERTICAL",s[s.LINEAR_HORIZONTAL=1]="LINEAR_HORIZONTAL",s))(su||{});const Ql={willReadFrequently:!0},Vs=class Xe{static get experimentalLetterSpacingSupported(){let e=Xe._experimentalLetterSpacingSupported;if(e!==void 0){const t=ke.ADAPTER.getCanvasRenderingContext2D().prototype;e=Xe._experimentalLetterSpacingSupported="letterSpacing"in t||"textLetterSpacing"in t}return e}constructor(e,t,i,n,r,o,a,c,l){this.text=e,this.style=t,this.width=i,this.height=n,this.lines=r,this.lineWidths=o,this.lineHeight=a,this.maxLineWidth=c,this.fontProperties=l}static measureText(e,t,i,n=Xe._canvas){i=i??t.wordWrap;const r=t.toFontString(),o=Xe.measureFont(r);o.fontSize===0&&(o.fontSize=t.fontSize,o.ascent=t.fontSize);const a=n.getContext("2d",Ql);a.font=r;const c=(i?Xe.wordWrap(e,t,n):e).split(/(?:\r\n|\r|\n)/),l=new Array(c.length);let h=0;for(let p=0;p<c.length;p++){const m=Xe._measureText(c[p],t.letterSpacing,a);l[p]=m,h=Math.max(h,m)}let u=h+t.strokeThickness;t.dropShadow&&(u+=t.dropShadowDistance);const d=t.lineHeight||o.fontSize+t.strokeThickness;let f=Math.max(d,o.fontSize+t.strokeThickness*2)+t.leading+(c.length-1)*(d+t.leading);return t.dropShadow&&(f+=t.dropShadowDistance),new Xe(e,t,u,f,c,l,d+t.leading,h,o)}static _measureText(e,t,i){let n=!1;Xe.experimentalLetterSpacingSupported&&(Xe.experimentalLetterSpacing?(i.letterSpacing=`${t}px`,i.textLetterSpacing=`${t}px`,n=!0):(i.letterSpacing="0px",i.textLetterSpacing="0px"));let r=i.measureText(e).width;return r>0&&(n?r-=t:r+=(Xe.graphemeSegmenter(e).length-1)*t),r}static wordWrap(e,t,i=Xe._canvas){const n=i.getContext("2d",Ql);let r=0,o="",a="";const c=Object.create(null),{letterSpacing:l,whiteSpace:h}=t,u=Xe.collapseSpaces(h),d=Xe.collapseNewlines(h);let f=!u;const p=t.wordWrapWidth+l, Line truncated
`:e,e}static getFromCache(e,t,i,n){let r=i[e];return typeof r!="number"&&(r=Xe._measureText(e,t,n)+t,i[e]=r),r}static collapseSpaces(e){return e==="normal"||e==="pre-line"}static collapseNewlines(e){return e==="normal"}static trimRight(e){if(typeof e!="string")return"";for(let t=e.length-1;t>=0;t--){const i=e[t];if(!Xe.isBreakingSpace(i))break;e=e.slice(0,-1)}return e}static isNewline(e){return typeof e!="string"?!1:Xe._newlines.includes(e.charCodeAt(0))}static isBreakingSpace(e,t){return typeof e!="string"?!1:Xe._breakingSpaces.includes(e.charCodeAt(0))}static tokenize(e){const t=[];let i="";if(typeof e!="string")return t;for(let n=0;n<e.length;n++){const r=e[n],o=e[n+1];if(Xe.isBreakingSpace(r,o)||Xe.isNewline(r)){i!==""&&(t.push(i),i=""),t.push(r);continue}i+=r}return i!==""&&t.push(i),t}static canBreakWords(e,t){return t}static canBreakChars(e,t,i,n,r){return!0}static wordWrapSplit(e){return Xe.graphemeSegmenter(e)}static measureFont(e){if(Xe._fonts[e])return Xe._fonts[e];const t={ascent:0,descent:0,fontSize:0},i=Xe._canvas,n=Xe._context;n.font=e;const r=Xe.METRICS_STRING+Xe.BASELINE_SYMBOL,o=Math.ceil(n.measureText(r).width);let a=Math.ceil(n.measureText(Xe.BASELINE_SYMBOL).width);const c=Math.ceil(Xe.HEIGHT_MULTIPLIER*a);if(a=a*Xe.BASELINE_MULTIPLIER|0,o===0||c===0)return Xe._fonts[e]=t,t;i.width=o,i.height=c,n.fillStyle="#f00",n.fillRect(0,0,o,c),n.font=e,n.textBaseline="alphabetic",n.fillStyle="#000",n.fillText(r,0,a);const l=n.getImageData(0,0,o,c).data,h=l.length,u=o*4;let d=0,f=0,p=!1;for(d=0;d<a;++d){for(let m=0;m<u;m+=4)if(l[f+m]!==255){p=!0;break}if(!p)f+=u;else break}for(t.ascent=a-d,f=h-u,p=!1,d=c;d>a;--d){for(let m=0;m<u;m+=4)if(l[f+m]!==255){p=!0;break}if(!p)f-=u;else break}return t.descent=d-a,t.fontSize=t.ascent+t.descent,Xe._fonts[e]=t,t}static clearMetrics(e=""){e?delete Xe._fonts[e]:Xe._fonts={}}static get _canvas(){var e;if(!Xe.__canvas){let t;try{const i=new OffscreenCanvas(0,0);if((e=i.getContext("2d",Ql))!=null&&e.measureText)return Xe.__canvas=i,i;t=ke.ADAPTER.createCanvas()}catch{t=ke.ADAPTER.createCanvas()}t.width=t.height=10,Xe.__canvas=t}return Xe.__canvas}static get _context(){return Xe.__context||(Xe.__context=Xe._canvas.getContext("2d",Ql)),Xe.__context}};Vs.METRICS_STRING="|ÉqÅ",Vs.BASELINE_SYMBOL="M",Vs.BASELINE_MULTIPLIER=1.4,Vs.HEIGHT_MULTIPLIER=2,Vs.graphemeSegmenter=(()=>{if(typeof(Intl==null?void 0:Intl.Segmenter)=="function"){const s=new Intl.Segmenter;return e=>[...s.segment(e)].map(t=>t.segment)}return s=>[...s]})(),Vs.experimentalLetterSpacing=!1,Vs._fonts={},Vs._newlines=[10,13],Vs._breakingSpaces=[9,32,8192,8193,8194,8195,8196,8197,8198,8200,8201,8202,8287,12288];let tr=Vs;const KE=["serif","sans-serif","monospace","cursive","fantasy","system-ui"],Yb=class La{constructor(e){this.styleID=0,this.reset(),Yd(this,e,e)}clone(){const e={};return Yd(e,this,La.defaultStyle),new La(e)}reset(){Yd(this,La.defaultStyle,La.defaultStyle)}get align(){return this._align}set align(e){this._align!==e&&(this._align=e,this.styleID++)}get breakWords(){return this._breakWords}set breakWords(e){this._breakWords!==e&&(this._breakWords=e,this.styleID++)}get dropShadow(){return this._dropShadow}set dropShadow(e){this._dropShadow!==e&&(this._dropShadow=e,this.styleID++)}get dropShadowAlpha(){return this._dropShadowAlpha}set dropShadowAlpha(e){this._dropShadowAlpha!==e&&(this._dropShadowAlpha=e,this.styleID++)}get dropShadowAngle(){return this._dropShadowAngle}set dropShadowAngle(e){this._dropShadowAngle!==e&&(this._dropShadowAngle=e,this.styleID++)}get dropShadowBlur(){return this._dropShadowBlur}set dropShadowBlur(e){this._dropShadowBlur!==e&&(this._dropShadowBlur=e,this.styleID++)}get dropShadowColor(){return this._dropShadowColor}set dropShadowColor(e){const t=Vd(e);this._dropShadowColor!==t&&(this._dropShadowColor=t,this.styleID++)}get dropShadowDistance(){return this._dropShadowDistance}set dropShadowDistance(e){this._dropShadowDistance!==e&&(this._dropShadowDistance=e,this.styleID++)}get fill(){return this._fill}set fill(e){const t=Vd(e);this._fill!==t&&(this._fill=t,this.styleID++)}get fillGradientType(){return this._fillGradientType}set fillGradientType(e){this._fillGradientType!==e&&(this._fillGradientType=e,this.styleID++)}get fillGradientStops(){return this._fillGradientStops}set fillGradientStops(e){ZE(this._fillGradientStops,e)||(this._fillGradientStops=e,this.styleID++)}get fontFamily(){return this._fontFamily}set fontFamily(e){this.fontFamily!==e&&(this._fontFamily=e,this.styleID++)}get fontSize(){return this._fontSize}set fontSize(e){this._fontSize!==e&&(this._fontSize=e,this.styleID++)}get fontStyle(){return this._fontStyle}set fontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.styleID++)}get fontVariant(){return this._fontVariant}set fontVariant(e){this._fontVariant!==e&&(this._fontVariant=e,this.styleID++)}get fontWeight(){return this._fontWeight}set fontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.styleID++)}get letterSpacing(){return this._lett Line truncated
#define SHADER_NAME Tiling-Sprite-100
precision lowp float;
@@ -1014,7 +1014,7 @@ void main(void)
fragmentColor = texSample * uColor;
}
`,lI=`#version 300 es
`,hI=`#version 300 es
#define SHADER_NAME Tiling-Sprite-300
precision lowp float;
@@ -1034,7 +1034,7 @@ void main(void)
vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;
}
`,cI=`#version 100
`,uI=`#version 100
#ifdef GL_EXT_shader_texture_lod
#extension GL_EXT_shader_texture_lod : enable
#endif
@@ -1087,7 +1087,7 @@ void main(void)
vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;
}
`,hI=`#version 100
`,dI=`#version 100
#define SHADER_NAME Tiling-Sprite-Simple-100
precision lowp float;
@@ -1102,7 +1102,7 @@ void main(void)
vec4 texSample = texture2D(uSampler, vTextureCoord);
gl_FragColor = texSample * uColor;
}
`;const ec=new Dt;class Wb extends eu{constructor(e){super(e),e.runners.contextChange.add(this),this.quad=new Jy,this.state=ln.for2d()}contextChange(){const e=this.renderer,t={globals:e.globalUniforms};this.simpleShader=Ps.from(cv,hI,t),this.shader=e.context.webGLVersion>1?Ps.from(lI,aI,t):Ps.from(cv,cI,t)}render(e){const t=this.renderer,i=this.quad;let n=i.vertices;n[0]=n[6]=e._width*-e.anchor.x,n[1]=n[3]=e._height*-e.anchor.y,n[2]=n[4]=e._width*(1-e.anchor.x),n[5]=n[7]=e._height*(1-e.anchor.y);const r=e.uvRespectAnchor?e.anchor.x:0,o=e.uvRespectAnchor?e.anchor.y:0;n=i.uvs,n[0]=n[6]=-r,n[1]=n[3]=-o,n[2]=n[4]=1-r,n[5]=n[7]=1-o,i.invalidate();const a=e._texture,c=a.baseTexture,l=c.alphaMode>0,h=e.tileTransform.localTransform,u=e.uvMatrix;let d=c.isPowerOfTwo&&a.frame.width===c.width&&a.frame.height===c.height;d&&(c._glTextures[t.CONTEXT_UID]?d=c.wrapMode!==Es.CLAMP:c.wrapMode===Es.CLAMP&&(c.wrapMode=Es.REPEAT));const f=d?this.simpleShader:this.shader,p=a.width,m=a.height,g=e._width,v=e._height;ec.set(h.a*p/g,h.b*p/v,h.c*m/g,h.d*m/v,h.tx/g,h.ty/v),ec.invert(),d?ec.prepend(u.mapCoord):(f.uniforms.uMapCoord=u.mapCoord.toArray(!0),f.uniforms.uClampFrame=u.uClampFrame,f.uniforms.uClampOffset=u.uClampOffset),f.uniforms.uTransform=ec.toArray(!0),f.uniforms.uColor=Tt.shared.setValue(e.tint).premultiply(e.worldAlpha,l).toArray(f.uniforms.uColor),f.uniforms.translationMatrix=e.transform.worldTransform.toArray(!0),f.uniforms.uSampler=a,t.shader.bind(f),t.geometry.bind(i),this.state.blendMode=Ny(e.blendMode,l),t.state.set(this.state),t.geometry.draw(this.renderer.gl.TRIANGLES,6,0)}}Wb.extension={name:"tilingSprite",type:Re.RendererPlugin};$e.add(Wb);const zb=class La{constructor(e,t,i){this.linkedSheets=[],(e instanceof Ze||e instanceof ze)&&(e={texture:e,data:t,resolutionFilename:i});const{texture:n,data:r,resolutionFilename:o=null,cachePrefix:a=""}=e;this.cachePrefix=a,this._texture=n instanceof ze?n:null,this.baseTexture=n instanceof Ze?n:this._texture.baseTexture,this.textures={},this.animations={},this.data=r;const c=this.baseTexture.resource;this.resolution=this._updateResolution(o||(c?c.url:null)),this._frames=this.data.frames,this._frameKeys=Object.keys(this._frames),this._batchIndex=0,this._callback=null}_updateResolution(e=null){const{scale:t}=this.data.meta;let i=Dn(e,null);return i===null&&(i=typeof t=="number"?t:parseFloat(t??"1")),i!==1&&this.baseTexture.setResolution(i),i}parse(){return new Promise(e=>{this._callback=e,this._batchIndex=0,this._frameKeys.length<=La.BATCH_SIZE?(this._processFrames(0),this._processAnimations(),this._parseComplete()):this._nextBatch()})}_processFrames(e){let t=e;const i=La.BATCH_SIZE;for(;t-e<i&&t<this._frameKeys.length;){const n=this._frameKeys[t],r=this._frames[n],o=r.frame;if(o){let a=null,c=null;const l=r.trimmed!==!1&&r.sourceSize?r.sourceSize:r.frame,h=new st(0,0,Math.floor(l.w)/this.resolution,Math.floor(l.h)/this.resolution);r.rotated?a=new st(Math.floor(o.x)/this.resolution,Math.floor(o.y)/this.resolution,Math.floor(o.h)/this.resolution,Math.floor(o.w)/this.resolution):a=new st(Math.floor(o.x)/this.resolution,Math.floor(o.y)/this.resolution,Math.floor(o.w)/this.resolution,Math.floor(o.h)/this.resolution),r.trimmed!==!1&&r.spriteSourceSize&&(c=new st(Math.floor(r.spriteSourceSize.x)/this.resolution,Math.floor(r.spriteSourceSize.y)/this.resolution,Math.floor(o.w)/this.resolution,Math.floor(o.h)/this.resolution)),this.textures[n]=new ze(this.baseTexture,a,h,c,r.rotated?2:0,r.anchor,r.borders),ze.addToCache(this.textures[n],this.cachePrefix+n.toString())}t++}}_processAnimations(){const e=this.data.animations||{};for(const t in e){this.animations[t]=[];for(let i=0;i<e[t].length;i++){const n=e[t][i];this.animations[t].push(this.textures[n])}}}_parseComplete(){const e=this._callback;this._callback=null,this._batchIndex=0,e.call(this,this.textures)}_nextBatch(){this._processFrames(this._batchIndex*La.BATCH_SIZE),this._batchIndex++,setTimeout(()=>{this._batchIndex*La.BATCH_SIZE<this._frameKeys.length?this._nextBatch():(this._processAnimations(),this._parseComplete())},0)}destroy(e=!1){var t;for(const i in this.textures)this.textures[i].destroy();this._frames=null,this._frameKeys=null,this.data=null,this.textures=null,e&&((t=this._texture)==null||t.destroy(),this.baseTexture.destroy()),this._texture=null,this.baseTexture=null,this.linkedSheets=[]}};zb.BATCH_SIZE=1e3;let hv=zb;const uI=["jpg","png","jpeg","avif","webp","s3tc","s3tc_sRGB","etc","etc1","pvrtc","atc","astc","bptc"];function qb(s,e,t){const i={};if(s.forEach(n=>{i[n]=e}),Object.keys(e.textures).forEach(n=>{i[`${e.cachePrefix}${n}`]=e.textures[n]}),!t){const n=Jt.dirname(s[0]);e.linkedSheets.forEach((r,o)=>{Object.assign(i,qb([`${n}/${e.data.meta.related_multi_packs[o]}`],r,!0))})}return i}const dI={extension:Re.Asset,cache:{test:s=>s instanceof hv,getCacheableAssets:(s,e)=>qb(s,e,!1)},resolver:{test:s=>{const e=s.split("?")[0].split("."),t=e.pop(),i=e.pop();return t==="json"&&uI.includes(i)},parse:s=>{var t;const Line truncated
`;const ec=new Ut;class qb extends eu{constructor(e){super(e),e.runners.contextChange.add(this),this.quad=new eb,this.state=un.for2d()}contextChange(){const e=this.renderer,t={globals:e.globalUniforms};this.simpleShader=ks.from(cv,dI,t),this.shader=e.context.webGLVersion>1?ks.from(hI,cI,t):ks.from(cv,uI,t)}render(e){const t=this.renderer,i=this.quad;let n=i.vertices;n[0]=n[6]=e._width*-e.anchor.x,n[1]=n[3]=e._height*-e.anchor.y,n[2]=n[4]=e._width*(1-e.anchor.x),n[5]=n[7]=e._height*(1-e.anchor.y);const r=e.uvRespectAnchor?e.anchor.x:0,o=e.uvRespectAnchor?e.anchor.y:0;n=i.uvs,n[0]=n[6]=-r,n[1]=n[3]=-o,n[2]=n[4]=1-r,n[5]=n[7]=1-o,i.invalidate();const a=e._texture,c=a.baseTexture,l=c.alphaMode>0,h=e.tileTransform.localTransform,u=e.uvMatrix;let d=c.isPowerOfTwo&&a.frame.width===c.width&&a.frame.height===c.height;d&&(c._glTextures[t.CONTEXT_UID]?d=c.wrapMode!==Is.CLAMP:c.wrapMode===Is.CLAMP&&(c.wrapMode=Is.REPEAT));const f=d?this.simpleShader:this.shader,p=a.width,m=a.height,g=e._width,v=e._height;ec.set(h.a*p/g,h.b*p/v,h.c*m/g,h.d*m/v,h.tx/g,h.ty/v),ec.invert(),d?ec.prepend(u.mapCoord):(f.uniforms.uMapCoord=u.mapCoord.toArray(!0),f.uniforms.uClampFrame=u.uClampFrame,f.uniforms.uClampOffset=u.uClampOffset),f.uniforms.uTransform=ec.toArray(!0),f.uniforms.uColor=Mt.shared.setValue(e.tint).premultiply(e.worldAlpha,l).toArray(f.uniforms.uColor),f.uniforms.translationMatrix=e.transform.worldTransform.toArray(!0),f.uniforms.uSampler=a,t.shader.bind(f),t.geometry.bind(i),this.state.blendMode=$y(e.blendMode,l),t.state.set(this.state),t.geometry.draw(this.renderer.gl.TRIANGLES,6,0)}}qb.extension={name:"tilingSprite",type:Re.RendererPlugin};Ue.add(qb);const Kb=class Da{constructor(e,t,i){this.linkedSheets=[],(e instanceof Je||e instanceof We)&&(e={texture:e,data:t,resolutionFilename:i});const{texture:n,data:r,resolutionFilename:o=null,cachePrefix:a=""}=e;this.cachePrefix=a,this._texture=n instanceof We?n:null,this.baseTexture=n instanceof Je?n:this._texture.baseTexture,this.textures={},this.animations={},this.data=r;const c=this.baseTexture.resource;this.resolution=this._updateResolution(o||(c?c.url:null)),this._frames=this.data.frames,this._frameKeys=Object.keys(this._frames),this._batchIndex=0,this._callback=null}_updateResolution(e=null){const{scale:t}=this.data.meta;let i=Xn(e,null);return i===null&&(i=typeof t=="number"?t:parseFloat(t??"1")),i!==1&&this.baseTexture.setResolution(i),i}parse(){return new Promise(e=>{this._callback=e,this._batchIndex=0,this._frameKeys.length<=Da.BATCH_SIZE?(this._processFrames(0),this._processAnimations(),this._parseComplete()):this._nextBatch()})}_processFrames(e){let t=e;const i=Da.BATCH_SIZE;for(;t-e<i&&t<this._frameKeys.length;){const n=this._frameKeys[t],r=this._frames[n],o=r.frame;if(o){let a=null,c=null;const l=r.trimmed!==!1&&r.sourceSize?r.sourceSize:r.frame,h=new rt(0,0,Math.floor(l.w)/this.resolution,Math.floor(l.h)/this.resolution);r.rotated?a=new rt(Math.floor(o.x)/this.resolution,Math.floor(o.y)/this.resolution,Math.floor(o.h)/this.resolution,Math.floor(o.w)/this.resolution):a=new rt(Math.floor(o.x)/this.resolution,Math.floor(o.y)/this.resolution,Math.floor(o.w)/this.resolution,Math.floor(o.h)/this.resolution),r.trimmed!==!1&&r.spriteSourceSize&&(c=new rt(Math.floor(r.spriteSourceSize.x)/this.resolution,Math.floor(r.spriteSourceSize.y)/this.resolution,Math.floor(o.w)/this.resolution,Math.floor(o.h)/this.resolution)),this.textures[n]=new We(this.baseTexture,a,h,c,r.rotated?2:0,r.anchor,r.borders),We.addToCache(this.textures[n],this.cachePrefix+n.toString())}t++}}_processAnimations(){const e=this.data.animations||{};for(const t in e){this.animations[t]=[];for(let i=0;i<e[t].length;i++){const n=e[t][i];this.animations[t].push(this.textures[n])}}}_parseComplete(){const e=this._callback;this._callback=null,this._batchIndex=0,e.call(this,this.textures)}_nextBatch(){this._processFrames(this._batchIndex*Da.BATCH_SIZE),this._batchIndex++,setTimeout(()=>{this._batchIndex*Da.BATCH_SIZE<this._frameKeys.length?this._nextBatch():(this._processAnimations(),this._parseComplete())},0)}destroy(e=!1){var t;for(const i in this.textures)this.textures[i].destroy();this._frames=null,this._frameKeys=null,this.data=null,this.textures=null,e&&((t=this._texture)==null||t.destroy(),this.baseTexture.destroy()),this._texture=null,this.baseTexture=null,this.linkedSheets=[]}};Kb.BATCH_SIZE=1e3;let hv=Kb;const fI=["jpg","png","jpeg","avif","webp","s3tc","s3tc_sRGB","etc","etc1","pvrtc","atc","astc","bptc"];function Zb(s,e,t){const i={};if(s.forEach(n=>{i[n]=e}),Object.keys(e.textures).forEach(n=>{i[`${e.cachePrefix}${n}`]=e.textures[n]}),!t){const n=Qt.dirname(s[0]);e.linkedSheets.forEach((r,o)=>{Object.assign(i,Zb([`${n}/${e.data.meta.related_multi_packs[o]}`],r,!0))})}return i}const mI={extension:Re.Asset,cache:{test:s=>s instanceof hv,getCacheableAssets:(s,e)=>Zb(s,e,!1)},resolver:{test:s=>{const e=s.split("?")[0].split("."),t=e.pop(),i=e.pop();return t==="json"&&fI.includes(i)},parse:s=>{var t;const Line truncated
varying vec2 vTextureCoord;\r
uniform sampler2D uSampler;\r
\r
@@ -1140,7 +1140,7 @@ void main(void) {\r
// NPM Textures, NPM outputs\r
gl_FragColor = vec4(uColor.rgb, coverage);\r
}\r
`,xI=`// Mesh material default fragment\r
`,bI=`// Mesh material default fragment\r
attribute vec2 aVertexPosition;\r
attribute vec2 aTextureCoord;\r
\r
@@ -1156,17 +1156,17 @@ void main(void)\r
\r
vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;\r
}\r
`;const uv=[],dv=[],fv=[],yI=class Zb extends _i{constructor(e,t={}){super();const{align:i,tint:n,maxWidth:r,letterSpacing:o,fontName:a,fontSize:c}=Object.assign({},Zb.styleDefaults,t);if(!zn.available[a])throw new Error(`Missing BitmapFont "${a}"`);this._activePagesMeshData=[],this._textWidth=0,this._textHeight=0,this._align=i,this._tintColor=new Tt(n),this._font=void 0,this._fontName=a,this._fontSize=c,this.text=e,this._maxWidth=r,this._maxLineHeight=0,this._letterSpacing=o,this._anchor=new _n(()=>{this.dirty=!0},this,0,0),this._roundPixels=ke.ROUND_PIXELS,this.dirty=!0,this._resolution=ke.RESOLUTION,this._autoResolution=!0,this._textureCache={}}updateText(){var E;const e=zn.available[this._fontName],t=this.fontSize,i=t/e.size,n=new pt,r=[],o=[],a=[],c=this._text.replace(/(?:\r\n|\r)/g,`
`)||" ",l=Kb(c),h=this._maxWidth*e.size/t,u=e.distanceFieldType==="none"?uv:dv;let d=null,f=0,p=0,m=0,g=-1,v=0,y=0,x=0,T=0;for(let k=0;k<l.length;k++){const O=l[k],L=_c(O);if(/(?:\s)/.test(O)&&(g=k,v=f,T++),O==="\r"||O===`
`){o.push(f),a.push(-1),p=Math.max(p,f),++m,++y,n.x=0,n.y+=e.lineHeight,d=null,T=0;continue}const $=e.chars[L];if(!$)continue;d&&$.kerning[d]&&(n.x+=$.kerning[d]);const D=fv.pop()||{texture:ze.EMPTY,line:0,charCode:0,prevSpaces:0,position:new pt};D.texture=$.texture,D.line=m,D.charCode=L,D.position.x=Math.round(n.x+$.xOffset+this._letterSpacing/2),D.position.y=Math.round(n.y+$.yOffset),D.prevSpaces=T,r.push(D),f=D.position.x+Math.max($.xAdvance-$.xOffset,$.texture.orig.width),n.x+=$.xAdvance+this._letterSpacing,x=Math.max(x,$.yOffset+$.texture.height),d=L,g!==-1&&h>0&&n.x>h&&(++y,Vo(r,1+g-y,1+k-g),k=g,g=-1,o.push(v),a.push(r.length>0?r[r.length-1].prevSpaces:0),p=Math.max(p,v),m++,n.x=0,n.y+=e.lineHeight,d=null,T=0)}const A=l[l.length-1];A!=="\r"&&A!==`
`&&(/(?:\s)/.test(A)&&(f=v),o.push(f),p=Math.max(p,f),a.push(-1));const S=[];for(let k=0;k<=m;k++){let O=0;this._align==="right"?O=p-o[k]:this._align==="center"?O=(p-o[k])/2:this._align==="justify"&&(O=a[k]<0?0:(p-o[k])/a[k]),S.push(O)}const b=r.length,_={},I=[],F=this._activePagesMeshData;u.push(...F);for(let k=0;k<b;k++){const O=r[k].texture,L=O.baseTexture.uid;if(!_[L]){let $=u.pop();if(!$){const U=new rp;let C,P;e.distanceFieldType==="none"?(C=new nh(ze.EMPTY),P=je.NORMAL):(C=new nh(ze.EMPTY,{program:en.from(xI,vI),uniforms:{uFWidth:0}}),P=je.NORMAL_NPM);const B=new cl(U,C);B.blendMode=P,$={index:0,indexCount:0,vertexCount:0,uvsCount:0,total:0,mesh:B,vertices:null,uvs:null,indices:null}}$.index=0,$.indexCount=0,$.vertexCount=0,$.uvsCount=0,$.total=0;const{_textureCache:D}=this;D[L]=D[L]||new ze(O.baseTexture),$.mesh.texture=D[L],$.mesh.tint=this._tintColor.value,I.push($),_[L]=$}_[L].total++}for(let k=0;k<F.length;k++)I.includes(F[k])||this.removeChild(F[k].mesh);for(let k=0;k<I.length;k++)I[k].mesh.parent!==this&&this.addChild(I[k].mesh);this._activePagesMeshData=I;for(const k in _){const O=_[k],L=O.total;if(!(((E=O.indices)==null?void 0:E.length)>6*L)||O.vertices.length<cl.BATCHABLE_SIZE*2)O.vertices=new Float32Array(8*L),O.uvs=new Float32Array(8*L),O.indices=new Uint16Array(6*L);else{const $=O.total,D=O.vertices;for(let U=$*4*2;U<D.length;U++)D[U]=0}O.mesh.size=6*L}for(let k=0;k<b;k++){const O=r[k];let L=O.position.x+S[O.line]*(this._align==="justify"?O.prevSpaces:1);this._roundPixels&&(L=Math.round(L));const $=L*i,D=O.position.y*i,U=O.texture,C=_[U.baseTexture.uid],P=U.frame,B=U._uvs,N=C.index++;C.indices[N*6+0]=0+N*4,C.indices[N*6+1]=1+N*4,C.indices[N*6+2]=2+N*4,C.indices[N*6+3]=0+N*4,C.indices[N*6+4]=2+N*4,C.indices[N*6+5]=3+N*4,C.vertices[N*8+0]=$,C.vertices[N*8+1]=D,C.vertices[N*8+2]=$+P.width*i,C.vertices[N*8+3]=D,C.vertices[N*8+4]=$+P.width*i,C.vertices[N*8+5]=D+P.height*i,C.vertices[N*8+6]=$,C.vertices[N*8+7]=D+P.height*i,C.uvs[N*8+0]=B.x0,C.uvs[N*8+1]=B.y0,C.uvs[N*8+2]=B.x1,C.uvs[N*8+3]=B.y1,C.uvs[N*8+4]=B.x2,C.uvs[N*8+5]=B.y2,C.uvs[N*8+6]=B.x3,C.uvs[N*8+7]=B.y3}this._textWidth=p*i,this._textHeight=(n.y+e.lineHeight)*i;for(const k in _){const O=_[k];if(this.anchor.x!==0||this.anchor.y!==0){let U=0;const C=this._textWidth*this.anchor.x,P=this._textHeight*this.anchor.y;for(let B=0;B<O.total;B++)O.vertices[U++]-=C,O.vertices[U++]-=P,O.vertices[U++]-=C,O.vertices[U++]-=P,O.vertices[U++]-=C,O.vertices[U++]-=P,O.vertices[U++]-=C,O.vertices[U++]-=P}this._maxLineHeight=x*i;const L=O.mesh.geometry.getBuffer("aVertexPosition"),$=O.mesh.geometry.getBuffer("aTextureCoord"),D=O.mesh.geometry.getIndex();L.data=O.vertices,$.data=O.uvs,D.data=O.indices,L.update(),$.update(),D.update()}for(let k=0;k<r.length;k++)fv.push(r[k]);this._font=e,this.dirty=!1}updateTransform(){this.validate(),this.containerUpdateTransform()}_render(e){this._autoResolution&&this._resolution!==e.resolution&&(this._resolution=e.resolution,this.dirty=!0);const{distanceFieldRange:t,distanceFieldType:i,size:n}=zn.available[this._fontName];if(i!=="none"){const{a:r,b:o,c:a,d:c}=this.worldTransform,l=Math.sqrt(r*r+o*o),h=Math.sqrt(a*a+c*c),u=(Math.abs(l)+Math.abs(h))/2,d=this.fontSize/n,f=e._view.resolution;for(const p of this._activePagesMeshData)p.mesh.shader.uniforms.uFWidth=u*t*d*f}super._render(e)}getLocalBounds(){return this.validate(),super.getLocalBounds()}validate(){const e=zn.available[this._fontName];if(!e)throw new Error(`Missing BitmapFont "${this._fontName}"`);this._font!==e&&(this.dirty=!0),this.dirty&&this.updateText()}get tint(){return this._tintColor.value}set tint(e){if(this.tint!==e){this._tintColor.setValue(e);for(let t=0;t<this._activePagesMeshData.length;t++)this._activePagesMeshData[t].mesh.tint=e}}get align(){return this._align}set align(e){this._align!==e&&(this._align=e,this.dirty=!0)}get fontName(){return this._fontName}set fontName(e){if(!zn.available[e])throw new Error(`Missing BitmapFont "${e}"`);this._fontName!==e&&(this._fontName=e,this.dirty=!0)}get fontSize(){return this._fontSize??zn.available[this._fontName].size}set fontSize(e){this._fontSize!==e&&(this._fontSize=e,this.dirty=!0)}get anchor(){return this._anchor}set anchor(e){typeof e=="number"?this._anchor.set(e):this._anchor.copyFrom(e)}get text(){return this._text}set text(e){e=String(e??""),this._text!==e&&(this._text=e,this.dirty=!0)}get maxWidth(){return this._maxWidth}set maxWidth(e){this._maxWidth!==e&&(this._maxWidth=e,this.dirty=!0)}get maxLineHeight(){return this.validate(),this._maxLineHeight}get textWidth(){return this.validate(),this._textWidth}get letterSpacing(){return this._letterSpacing}set letterSpacing(e){this._letterSpacing!==e&&(this._letterSpacing=e,this.dirty=!0)}get roundPixels(){return this._roundPixels}set roundPixels(e){e!==this._roundPixels&&(this._roundPixels=e,this.dirty=!0)}get textHeight(){return this.validate(),this._textHeight}get resolution(){return this._resolution}set resolution(e){this._autoResolution=!1,this._res Line truncated
`;const uv=[],dv=[],fv=[],wI=class Qb extends _i{constructor(e,t={}){super();const{align:i,tint:n,maxWidth:r,letterSpacing:o,fontName:a,fontSize:c}=Object.assign({},Qb.styleDefaults,t);if(!Jn.available[a])throw new Error(`Missing BitmapFont "${a}"`);this._activePagesMeshData=[],this._textWidth=0,this._textHeight=0,this._align=i,this._tintColor=new Mt(n),this._font=void 0,this._fontName=a,this._fontSize=c,this.text=e,this._maxWidth=r,this._maxLineHeight=0,this._letterSpacing=o,this._anchor=new In(()=>{this.dirty=!0},this,0,0),this._roundPixels=ke.ROUND_PIXELS,this.dirty=!0,this._resolution=ke.RESOLUTION,this._autoResolution=!0,this._textureCache={}}updateText(){var E;const e=Jn.available[this._fontName],t=this.fontSize,i=t/e.size,n=new gt,r=[],o=[],a=[],c=this._text.replace(/(?:\r\n|\r)/g,`
`)||" ",l=Jb(c),h=this._maxWidth*e.size/t,u=e.distanceFieldType==="none"?uv:dv;let d=null,f=0,p=0,m=0,g=-1,v=0,y=0,x=0,T=0;for(let k=0;k<l.length;k++){const B=l[k],N=_c(B);if(/(?:\s)/.test(B)&&(g=k,v=f,T++),B==="\r"||B===`
`){o.push(f),a.push(-1),p=Math.max(p,f),++m,++y,n.x=0,n.y+=e.lineHeight,d=null,T=0;continue}const $=e.chars[N];if(!$)continue;d&&$.kerning[d]&&(n.x+=$.kerning[d]);const L=fv.pop()||{texture:We.EMPTY,line:0,charCode:0,prevSpaces:0,position:new gt};L.texture=$.texture,L.line=m,L.charCode=N,L.position.x=Math.round(n.x+$.xOffset+this._letterSpacing/2),L.position.y=Math.round(n.y+$.yOffset),L.prevSpaces=T,r.push(L),f=L.position.x+Math.max($.xAdvance-$.xOffset,$.texture.orig.width),n.x+=$.xAdvance+this._letterSpacing,x=Math.max(x,$.yOffset+$.texture.height),d=N,g!==-1&&h>0&&n.x>h&&(++y,Go(r,1+g-y,1+k-g),k=g,g=-1,o.push(v),a.push(r.length>0?r[r.length-1].prevSpaces:0),p=Math.max(p,v),m++,n.x=0,n.y+=e.lineHeight,d=null,T=0)}const A=l[l.length-1];A!=="\r"&&A!==`
`&&(/(?:\s)/.test(A)&&(f=v),o.push(f),p=Math.max(p,f),a.push(-1));const S=[];for(let k=0;k<=m;k++){let B=0;this._align==="right"?B=p-o[k]:this._align==="center"?B=(p-o[k])/2:this._align==="justify"&&(B=a[k]<0?0:(p-o[k])/a[k]),S.push(B)}const b=r.length,_={},I=[],F=this._activePagesMeshData;u.push(...F);for(let k=0;k<b;k++){const B=r[k].texture,N=B.baseTexture.uid;if(!_[N]){let $=u.pop();if(!$){const U=new rp;let C,P;e.distanceFieldType==="none"?(C=new nh(We.EMPTY),P=He.NORMAL):(C=new nh(We.EMPTY,{program:nn.from(bI,yI),uniforms:{uFWidth:0}}),P=He.NORMAL_NPM);const O=new hl(U,C);O.blendMode=P,$={index:0,indexCount:0,vertexCount:0,uvsCount:0,total:0,mesh:O,vertices:null,uvs:null,indices:null}}$.index=0,$.indexCount=0,$.vertexCount=0,$.uvsCount=0,$.total=0;const{_textureCache:L}=this;L[N]=L[N]||new We(B.baseTexture),$.mesh.texture=L[N],$.mesh.tint=this._tintColor.value,I.push($),_[N]=$}_[N].total++}for(let k=0;k<F.length;k++)I.includes(F[k])||this.removeChild(F[k].mesh);for(let k=0;k<I.length;k++)I[k].mesh.parent!==this&&this.addChild(I[k].mesh);this._activePagesMeshData=I;for(const k in _){const B=_[k],N=B.total;if(!(((E=B.indices)==null?void 0:E.length)>6*N)||B.vertices.length<hl.BATCHABLE_SIZE*2)B.vertices=new Float32Array(8*N),B.uvs=new Float32Array(8*N),B.indices=new Uint16Array(6*N);else{const $=B.total,L=B.vertices;for(let U=$*4*2;U<L.length;U++)L[U]=0}B.mesh.size=6*N}for(let k=0;k<b;k++){const B=r[k];let N=B.position.x+S[B.line]*(this._align==="justify"?B.prevSpaces:1);this._roundPixels&&(N=Math.round(N));const $=N*i,L=B.position.y*i,U=B.texture,C=_[U.baseTexture.uid],P=U.frame,O=U._uvs,D=C.index++;C.indices[D*6+0]=0+D*4,C.indices[D*6+1]=1+D*4,C.indices[D*6+2]=2+D*4,C.indices[D*6+3]=0+D*4,C.indices[D*6+4]=2+D*4,C.indices[D*6+5]=3+D*4,C.vertices[D*8+0]=$,C.vertices[D*8+1]=L,C.vertices[D*8+2]=$+P.width*i,C.vertices[D*8+3]=L,C.vertices[D*8+4]=$+P.width*i,C.vertices[D*8+5]=L+P.height*i,C.vertices[D*8+6]=$,C.vertices[D*8+7]=L+P.height*i,C.uvs[D*8+0]=O.x0,C.uvs[D*8+1]=O.y0,C.uvs[D*8+2]=O.x1,C.uvs[D*8+3]=O.y1,C.uvs[D*8+4]=O.x2,C.uvs[D*8+5]=O.y2,C.uvs[D*8+6]=O.x3,C.uvs[D*8+7]=O.y3}this._textWidth=p*i,this._textHeight=(n.y+e.lineHeight)*i;for(const k in _){const B=_[k];if(this.anchor.x!==0||this.anchor.y!==0){let U=0;const C=this._textWidth*this.anchor.x,P=this._textHeight*this.anchor.y;for(let O=0;O<B.total;O++)B.vertices[U++]-=C,B.vertices[U++]-=P,B.vertices[U++]-=C,B.vertices[U++]-=P,B.vertices[U++]-=C,B.vertices[U++]-=P,B.vertices[U++]-=C,B.vertices[U++]-=P}this._maxLineHeight=x*i;const N=B.mesh.geometry.getBuffer("aVertexPosition"),$=B.mesh.geometry.getBuffer("aTextureCoord"),L=B.mesh.geometry.getIndex();N.data=B.vertices,$.data=B.uvs,L.data=B.indices,N.update(),$.update(),L.update()}for(let k=0;k<r.length;k++)fv.push(r[k]);this._font=e,this.dirty=!1}updateTransform(){this.validate(),this.containerUpdateTransform()}_render(e){this._autoResolution&&this._resolution!==e.resolution&&(this._resolution=e.resolution,this.dirty=!0);const{distanceFieldRange:t,distanceFieldType:i,size:n}=Jn.available[this._fontName];if(i!=="none"){const{a:r,b:o,c:a,d:c}=this.worldTransform,l=Math.sqrt(r*r+o*o),h=Math.sqrt(a*a+c*c),u=(Math.abs(l)+Math.abs(h))/2,d=this.fontSize/n,f=e._view.resolution;for(const p of this._activePagesMeshData)p.mesh.shader.uniforms.uFWidth=u*t*d*f}super._render(e)}getLocalBounds(){return this.validate(),super.getLocalBounds()}validate(){const e=Jn.available[this._fontName];if(!e)throw new Error(`Missing BitmapFont "${this._fontName}"`);this._font!==e&&(this.dirty=!0),this.dirty&&this.updateText()}get tint(){return this._tintColor.value}set tint(e){if(this.tint!==e){this._tintColor.setValue(e);for(let t=0;t<this._activePagesMeshData.length;t++)this._activePagesMeshData[t].mesh.tint=e}}get align(){return this._align}set align(e){this._align!==e&&(this._align=e,this.dirty=!0)}get fontName(){return this._fontName}set fontName(e){if(!Jn.available[e])throw new Error(`Missing BitmapFont "${e}"`);this._fontName!==e&&(this._fontName=e,this.dirty=!0)}get fontSize(){return this._fontSize??Jn.available[this._fontName].size}set fontSize(e){this._fontSize!==e&&(this._fontSize=e,this.dirty=!0)}get anchor(){return this._anchor}set anchor(e){typeof e=="number"?this._anchor.set(e):this._anchor.copyFrom(e)}get text(){return this._text}set text(e){e=String(e??""),this._text!==e&&(this._text=e,this.dirty=!0)}get maxWidth(){return this._maxWidth}set maxWidth(e){this._maxWidth!==e&&(this._maxWidth=e,this.dirty=!0)}get maxLineHeight(){return this.validate(),this._maxLineHeight}get textWidth(){return this.validate(),this._textWidth}get letterSpacing(){return this._letterSpacing}set letterSpacing(e){this._letterSpacing!==e&&(this._letterSpacing=e,this.dirty=!0)}get roundPixels(){return this._roundPixels}set roundPixels(e){e!==this._roundPixels&&(this._roundPixels=e,this.dirty=!0)}get textHeight(){return this.validate(),this._textHeight}get resolution(){return this._resolution}set resolution(e){this._autoResolution=!1,this._res Line truncated
@font-face {
font-family: "${t.family}";
src: url('${t.dataSrc}');
font-weight: ${t.weight};
font-style: ${t.style};
font-display: ${t.display};
}`,this._stylesheet)}get stylesheet(){return this._stylesheet}set stylesheet(e){this._stylesheet!==e&&(this._stylesheet=e,this.styleID++)}normalizeColor(e){return Array.isArray(e)&&(e=uC(e)),typeof e=="number"?hC(e):e}dropShadowToCSS(){let e=this.normalizeColor(this.dropShadowColor);const t=this.dropShadowAlpha,i=Math.round(Math.cos(this.dropShadowAngle)*this.dropShadowDistance),n=Math.round(Math.sin(this.dropShadowAngle)*this.dropShadowDistance);e.startsWith("#")&&t<1&&(e+=(t*255|0).toString(16).padStart(2,"0"));const r=`${i}px ${n}px`;return this.dropShadowBlur>0?`text-shadow: ${r} ${this.dropShadowBlur}px ${e}`:`text-shadow: ${r} ${e}`}reset(){Object.assign(this,Ro.defaultOptions)}onBeforeDraw(){const{fontsDirty:e}=this;return this.fontsDirty=!1,this.isSafari&&this._fonts.length>0&&e?new Promise(t=>setTimeout(t,100)):Promise.resolve()}get isSafari(){const{userAgent:e}=ke.ADAPTER.getNavigator();return/^((?!chrome|android).)*safari/i.test(e)}set fillGradientStops(e){console.warn("[HTMLTextStyle] fillGradientStops is not supported by HTMLText")}get fillGradientStops(){return super.fillGradientStops}set fillGradientType(e){console.warn("[HTMLTextStyle] fillGradientType is not supported by HTMLText")}get fillGradientType(){return super.fillGradientType}set miterLimit(e){console.warn("[HTMLTextStyle] miterLimit is not supported by HTMLText")}get miterLimit(){return super.miterLimit}set trim(e){console.warn("[HTMLTextStyle] trim is not supported by HTMLText")}get trim(){return super.trim}set textBaseline(e){console.warn("[HTMLTextStyle] textBaseline is not supported by HTMLText")}get textBaseline(){return super.textBaseline}set leading(e){console.warn("[HTMLTextStyle] leading is not supported by HTMLText")}get leading(){return super.leading}set lineJoin(e){console.warn("[HTMLTextStyle] lineJoin is not supported by HTMLText")}get lineJoin(){return super.lineJoin}};em.availableFonts={},em.defaultOptions={align:"left",breakWords:!1,dropShadow:!1,dropShadowAlpha:1,dropShadowAngle:Math.PI/6,dropShadowBlur:0,dropShadowColor:"black",dropShadowDistance:5,fill:"black",fontFamily:"Arial",fontSize:26,fontStyle:"normal",fontVariant:"normal",fontWeight:"normal",letterSpacing:0,lineHeight:0,padding:0,stroke:"black",strokeThickness:0,whiteSpace:"normal",wordWrap:!1,wordWrapWidth:100};let Hd=em;const tc=class Po extends xr{constructor(e="",t={}){super(ze.EMPTY),this._text=null,this._style=null,this._autoResolution=!0,this.localStyleID=-1,this.dirty=!1,this._updateID=0,this.ownsStyle=!1;const i=new Image,n=ze.from(i,{scaleMode:ke.SCALE_MODE,resourceOptions:{autoLoad:!1}});n.orig=new st,n.trim=new st,this.texture=n;const r="http://www.w3.org/2000/svg",o="http://www.w3.org/1999/xhtml",a=document.createElementNS(r,"svg"),c=document.createElementNS(r,"foreignObject"),l=document.createElementNS(o,"div"),h=document.createElementNS(o,"style");c.setAttribute("width","10000"),c.setAttribute("height","10000"),c.style.overflow="hidden",a.appendChild(c),this.maxWidth=Po.defaultMaxWidth,this.maxHeight=Po.defaultMaxHeight,this._domElement=l,this._styleElement=h,this._svgRoot=a,this._foreignObject=c,this._foreignObject.appendChild(h),this._foreignObject.appendChild(l),this._image=i,this._loadImage=new Image,this._autoResolution=Po.defaultAutoResolution,this._resolution=Po.defaultResolution??ke.RESOLUTION,this.text=e,this.style=t}measureText(e){var h,u;const{text:t,style:i,resolution:n}=Object.assign({text:this._text,style:this._style,resolution:this._resolution},e);Object.assign(this._domElement,{innerHTML:t,style:i.toCSS(n)}),this._styleElement.textContent=i.toGlobalCSS(),document.body.appendChild(this._svgRoot);const r=this._domElement.getBoundingClientRect();this._svgRoot.remove();const{width:o,height:a}=r;(o>this.maxWidth||a>this.maxHeight)&&console.warn("[HTMLText] Large expanse of text, increase HTMLText.maxWidth or HTMLText.maxHeight property.");const c=Math.min(this.maxWidth,Math.ceil(o)),l=Math.min(this.maxHeight,Math.ceil(a));return this._svgRoot.setAttribute("width",c.toString()),this._svgRoot.setAttribute("height",l.toString()),t!==this._text&&(this._domElement.innerHTML=this._text),i!==this._style&&(Object.assign(this._domElement,{style:(h=this._style)==null?void 0:h.toCSS(n)}),this._styleElement.textContent=(u=this._style)==null?void 0:u.toGlobalCSS()),{width:c+i.padding*2,height:l+i.padding*2}}async updateText(e=!0){const{style:t,_image:i,_loadImage:n}=this;if(this.localStyleID!==t.styleID&&(this.dirty=!0,this.localStyleID=t.styleID),!this.dirty&&e)return;const{width:r,height:o}=this.measureText();i.width=n.width=Math.ceil(Math.max(1,r)),i.height=n.height=Math.ceil(Math.max(1,o)),this._updateID++;const a=this._updateID;await new Promise(c=>{n.onload=async()=>{if(a<this._updateID){c();return}await t.onBeforeDraw(),i.src=n.src,n.onload=null,n.src="",this.updateTexture(),c()};const l=new XMLSerializer().serializeToString(this._svgRoot);n.src=`data:image/svg+xml;charset=utf8,${encodeURIComponent(l)}`})}get source(){ret Line truncated
}`,this._stylesheet)}get stylesheet(){return this._stylesheet}set stylesheet(e){this._stylesheet!==e&&(this._stylesheet=e,this.styleID++)}normalizeColor(e){return Array.isArray(e)&&(e=fC(e)),typeof e=="number"?dC(e):e}dropShadowToCSS(){let e=this.normalizeColor(this.dropShadowColor);const t=this.dropShadowAlpha,i=Math.round(Math.cos(this.dropShadowAngle)*this.dropShadowDistance),n=Math.round(Math.sin(this.dropShadowAngle)*this.dropShadowDistance);e.startsWith("#")&&t<1&&(e+=(t*255|0).toString(16).padStart(2,"0"));const r=`${i}px ${n}px`;return this.dropShadowBlur>0?`text-shadow: ${r} ${this.dropShadowBlur}px ${e}`:`text-shadow: ${r} ${e}`}reset(){Object.assign(this,ko.defaultOptions)}onBeforeDraw(){const{fontsDirty:e}=this;return this.fontsDirty=!1,this.isSafari&&this._fonts.length>0&&e?new Promise(t=>setTimeout(t,100)):Promise.resolve()}get isSafari(){const{userAgent:e}=ke.ADAPTER.getNavigator();return/^((?!chrome|android).)*safari/i.test(e)}set fillGradientStops(e){console.warn("[HTMLTextStyle] fillGradientStops is not supported by HTMLText")}get fillGradientStops(){return super.fillGradientStops}set fillGradientType(e){console.warn("[HTMLTextStyle] fillGradientType is not supported by HTMLText")}get fillGradientType(){return super.fillGradientType}set miterLimit(e){console.warn("[HTMLTextStyle] miterLimit is not supported by HTMLText")}get miterLimit(){return super.miterLimit}set trim(e){console.warn("[HTMLTextStyle] trim is not supported by HTMLText")}get trim(){return super.trim}set textBaseline(e){console.warn("[HTMLTextStyle] textBaseline is not supported by HTMLText")}get textBaseline(){return super.textBaseline}set leading(e){console.warn("[HTMLTextStyle] leading is not supported by HTMLText")}get leading(){return super.leading}set lineJoin(e){console.warn("[HTMLTextStyle] lineJoin is not supported by HTMLText")}get lineJoin(){return super.lineJoin}};em.availableFonts={},em.defaultOptions={align:"left",breakWords:!1,dropShadow:!1,dropShadowAlpha:1,dropShadowAngle:Math.PI/6,dropShadowBlur:0,dropShadowColor:"black",dropShadowDistance:5,fill:"black",fontFamily:"Arial",fontSize:26,fontStyle:"normal",fontVariant:"normal",fontWeight:"normal",letterSpacing:0,lineHeight:0,padding:0,stroke:"black",strokeThickness:0,whiteSpace:"normal",wordWrap:!1,wordWrapWidth:100};let Hd=em;const tc=class Fo extends Sr{constructor(e="",t={}){super(We.EMPTY),this._text=null,this._style=null,this._autoResolution=!0,this.localStyleID=-1,this.dirty=!1,this._updateID=0,this.ownsStyle=!1;const i=new Image,n=We.from(i,{scaleMode:ke.SCALE_MODE,resourceOptions:{autoLoad:!1}});n.orig=new rt,n.trim=new rt,this.texture=n;const r="http://www.w3.org/2000/svg",o="http://www.w3.org/1999/xhtml",a=document.createElementNS(r,"svg"),c=document.createElementNS(r,"foreignObject"),l=document.createElementNS(o,"div"),h=document.createElementNS(o,"style");c.setAttribute("width","10000"),c.setAttribute("height","10000"),c.style.overflow="hidden",a.appendChild(c),this.maxWidth=Fo.defaultMaxWidth,this.maxHeight=Fo.defaultMaxHeight,this._domElement=l,this._styleElement=h,this._svgRoot=a,this._foreignObject=c,this._foreignObject.appendChild(h),this._foreignObject.appendChild(l),this._image=i,this._loadImage=new Image,this._autoResolution=Fo.defaultAutoResolution,this._resolution=Fo.defaultResolution??ke.RESOLUTION,this.text=e,this.style=t}measureText(e){var h,u;const{text:t,style:i,resolution:n}=Object.assign({text:this._text,style:this._style,resolution:this._resolution},e);Object.assign(this._domElement,{innerHTML:t,style:i.toCSS(n)}),this._styleElement.textContent=i.toGlobalCSS(),document.body.appendChild(this._svgRoot);const r=this._domElement.getBoundingClientRect();this._svgRoot.remove();const{width:o,height:a}=r;(o>this.maxWidth||a>this.maxHeight)&&console.warn("[HTMLText] Large expanse of text, increase HTMLText.maxWidth or HTMLText.maxHeight property.");const c=Math.min(this.maxWidth,Math.ceil(o)),l=Math.min(this.maxHeight,Math.ceil(a));return this._svgRoot.setAttribute("width",c.toString()),this._svgRoot.setAttribute("height",l.toString()),t!==this._text&&(this._domElement.innerHTML=this._text),i!==this._style&&(Object.assign(this._domElement,{style:(h=this._style)==null?void 0:h.toCSS(n)}),this._styleElement.textContent=(u=this._style)==null?void 0:u.toGlobalCSS()),{width:c+i.padding*2,height:l+i.padding*2}}async updateText(e=!0){const{style:t,_image:i,_loadImage:n}=this;if(this.localStyleID!==t.styleID&&(this.dirty=!0,this.localStyleID=t.styleID),!this.dirty&&e)return;const{width:r,height:o}=this.measureText();i.width=n.width=Math.ceil(Math.max(1,r)),i.height=n.height=Math.ceil(Math.max(1,o)),this._updateID++;const a=this._updateID;await new Promise(c=>{n.onload=async()=>{if(a<this._updateID){c();return}await t.onBeforeDraw(),i.src=n.src,n.onload=null,n.src="",this.updateTexture(),c()};const l=new XMLSerializer().serializeToString(this._svgRoot);n.src=`data:image/svg+xml;charset=utf8,${encodeURIComponent(l)}`})}get source(){ret Line truncated
attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
@@ -1182,7 +1182,7 @@ void main(void)
vTextureCoord = (uTextureMatrix * vec3(aTextureCoord, 1.0)).xy;
}
`,vP=`
`,xP=`
varying vec2 vTextureCoord;
uniform vec4 uColor;
uniform vec4 uDarkColor;
@@ -1195,7 +1195,7 @@ void main(void)
gl_FragColor.a = texColor.a * uColor.a;
gl_FragColor.rgb = ((texColor.a - 1.0) * uDarkColor.a + 1.0 - texColor.rgb) * uDarkColor.rgb + texColor.rgb * uColor.rgb;
}
`;class xP extends Ps{constructor(t){const i={uSampler:t??ze.EMPTY,alpha:1,uTextureMatrix:Dt.IDENTITY,uColor:new Float32Array([1,1,1,1]),uDarkColor:new Float32Array([0,0,0,0])},n={tint:16777215,darkTint:0,alpha:1,pluginName:"darkTintBatch"};super(en.from(gP,vP),i);w(this,"uvMatrix");w(this,"batchable");w(this,"pluginName");w(this,"_tintRGB");w(this,"_darkTintRGB");w(this,"_colorDirty");w(this,"_alpha");w(this,"_tintColor");w(this,"_darkTintColor");this._colorDirty=!1,this.uvMatrix=new Qm(i.uSampler),this.batchable=!0,this.pluginName=n.pluginName,this._tintColor=new Tt(n.tint),this._darkTintColor=new Tt(n.darkTint),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._darkTintRGB=this._darkTintColor.toLittleEndianNumber(),this._alpha=n.alpha,this._colorDirty=!0}get texture(){return this.uniforms.uSampler}set texture(t){this.uniforms.uSampler!==t&&(!this.uniforms.uSampler.baseTexture.alphaMode!=!t.baseTexture.alphaMode&&(this._colorDirty=!0),this.uniforms.uSampler=t,this.uvMatrix.texture=t)}set alpha(t){t!==this._alpha&&(this._alpha=t,this._colorDirty=!0)}get alpha(){return this._alpha}set tint(t){t!==this.tint&&(this._tintColor.setValue(t),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._colorDirty=!0)}get tint(){return this._tintColor.value}set darkTint(t){t!==this.darkTint&&(this._darkTintColor.setValue(t),this._darkTintRGB=this._darkTintColor.toLittleEndianNumber(),this._colorDirty=!0)}get darkTint(){return this._darkTintColor.value}get tintValue(){return this._tintColor.toNumber()}get darkTintValue(){return this._darkTintColor.toNumber()}update(){this._colorDirty&&(this._colorDirty=!1,Tt.shared.setValue(this._tintColor).premultiply(this._alpha,!0).toArray(this.uniforms.uColor),Tt.shared.setValue(this._darkTintColor).premultiply(this._alpha,!0).premultiply(1,!1).toArray(this.uniforms.uDarkColor)),this.uvMatrix.update()&&(this.uniforms.uTextureMatrix=this.uvMatrix.mapCoord)}}class yP extends cl{constructor(t){super(new pP,new xP(t),void 0,void 0);w(this,"_darkTintRGB",0)}get darkTint(){return"darkTint"in this.shader?this.shader.darkTint:null}set darkTint(t){this.shader.darkTint=t}get darkTintValue(){return this.shader.darkTintValue}_renderToBatch(t){const i=this.geometry,n=this.shader;n.uvMatrix&&(n.uvMatrix.update(),this.calculateUvs()),this.calculateVertices(),this.indices=i.indexBuffer.data,this._tintRGB=n._tintRGB,this._darkTintRGB=n._darkTintRGB,this._texture=n.texture;const r=this.material.pluginName;t.batch.setObjectRenderer(t.plugins[r]),t.plugins[r].render(this)}}const li=class li extends yP{constructor(){super();w(this,"name","")}updateFromSpineData(t,i,n,r,o,a,c,l){var v,y;this.texture=t.texture;const h=o/(l?12:8)*2,u=this.geometry.getBuffer("aTextureCoord");((v=u.data)==null?void 0:v.length)!==h&&(u.data=new Float32Array(h));const d=this.geometry.getBuffer("aVertexPosition");((y=d.data)==null?void 0:y.length)!==h&&(d.data=new Float32Array(h));let f=0,p=u.data,m=d.data;for(let x=0;x<o;x+=l?12:8){let T=x;m[f]=r[T++],m[f+1]=r[T++],T+=4,p[f]=r[T++],p[f+1]=r[T++],f+=2}l?(li.auxColor[0]=r[8],li.auxColor[1]=r[9],li.auxColor[2]=r[10],li.auxColor[3]=r[11],this.darkTint=li.auxColor,li.auxColor[0]=r[2],li.auxColor[1]=r[3],li.auxColor[2]=r[4],li.auxColor[3]=r[5],this.tint=li.auxColor):(li.auxColor[0]=r[2],li.auxColor[1]=r[3],li.auxColor[2]=r[4],li.auxColor[3]=r[5],this.tint=li.auxColor),this.blendMode=ro.toPixiBlending(i),this.alpha=li.auxColor[3];const g=this.geometry.indexBuffer;if(g.data.length!==a.length)g.data=new Uint32Array(a);else{const x=g.data;for(let T=0;T<c;T++)x[T]=a[T]}this.name=n,u.update(),d.update(),g.update()}};w(li,"auxColor",[0,0,0,0]);let Ga=li;const vt=class vt extends _i{constructor(t,i){if(t instanceof uh)t={...i,skeletonData:t};else if(i)throw new Error("You cannot use options and oldOptions together.");super();w(this,"skeleton");w(this,"state");w(this,"darkTint",!1);w(this,"hasNeverUpdated",!0);w(this,"_debug");w(this,"slotMeshFactory",()=>new lm);w(this,"beforeUpdateWorldTransforms",()=>{});w(this,"afterUpdateWorldTransforms",()=>{});w(this,"_autoUpdate",!1);w(this,"_ticker",Vi.shared);w(this,"meshesCache",new Map);w(this,"lightColor",new it);w(this,"darkColor",new it);w(this,"_boundsProvider");w(this,"_boundsPoint",new pt);w(this,"_boundsSpineID",-1);w(this,"_boundsSpineDirty",!0);w(this,"slotsObject",new Map);w(this,"verticesCache",Ie.newFloatArray(1024));w(this,"clippingSlotToPixiMasks",{});w(this,"currentClippingSlot");const n=t instanceof uh?t:t.skeletonData;this.skeleton=new dp(n);const r=new _R(n);this.state=new bR(r),(t==null?void 0:t.darkTint)!==void 0||(i==null?void 0:i.slotMeshFactory)===void 0?(this.darkTint=(t==null?void 0:t.darkTint)===void 0?this.skeleton.slots.some(o=>!!o.data.darkColor):t==null?void 0:t.darkTint,this.darkTint&&(this.slotMeshFactory=()=>new Ga)):this.initializeMeshFactory(i==null?void 0:i.slotMeshFactory),t!=null&&t.ticker&&(this._ticker=t.ticker),this.autoUpdate=(t==null?void 0:t.autoUpdate)??!0,this.boundsProvider=t.boundsProvide Line truncated
`;class yP extends ks{constructor(t){const i={uSampler:t??We.EMPTY,alpha:1,uTextureMatrix:Ut.IDENTITY,uColor:new Float32Array([1,1,1,1]),uDarkColor:new Float32Array([0,0,0,0])},n={tint:16777215,darkTint:0,alpha:1,pluginName:"darkTintBatch"};super(nn.from(vP,xP),i);w(this,"uvMatrix");w(this,"batchable");w(this,"pluginName");w(this,"_tintRGB");w(this,"_darkTintRGB");w(this,"_colorDirty");w(this,"_alpha");w(this,"_tintColor");w(this,"_darkTintColor");this._colorDirty=!1,this.uvMatrix=new Qm(i.uSampler),this.batchable=!0,this.pluginName=n.pluginName,this._tintColor=new Mt(n.tint),this._darkTintColor=new Mt(n.darkTint),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._darkTintRGB=this._darkTintColor.toLittleEndianNumber(),this._alpha=n.alpha,this._colorDirty=!0}get texture(){return this.uniforms.uSampler}set texture(t){this.uniforms.uSampler!==t&&(!this.uniforms.uSampler.baseTexture.alphaMode!=!t.baseTexture.alphaMode&&(this._colorDirty=!0),this.uniforms.uSampler=t,this.uvMatrix.texture=t)}set alpha(t){t!==this._alpha&&(this._alpha=t,this._colorDirty=!0)}get alpha(){return this._alpha}set tint(t){t!==this.tint&&(this._tintColor.setValue(t),this._tintRGB=this._tintColor.toLittleEndianNumber(),this._colorDirty=!0)}get tint(){return this._tintColor.value}set darkTint(t){t!==this.darkTint&&(this._darkTintColor.setValue(t),this._darkTintRGB=this._darkTintColor.toLittleEndianNumber(),this._colorDirty=!0)}get darkTint(){return this._darkTintColor.value}get tintValue(){return this._tintColor.toNumber()}get darkTintValue(){return this._darkTintColor.toNumber()}update(){this._colorDirty&&(this._colorDirty=!1,Mt.shared.setValue(this._tintColor).premultiply(this._alpha,!0).toArray(this.uniforms.uColor),Mt.shared.setValue(this._darkTintColor).premultiply(this._alpha,!0).premultiply(1,!1).toArray(this.uniforms.uDarkColor)),this.uvMatrix.update()&&(this.uniforms.uTextureMatrix=this.uvMatrix.mapCoord)}}class bP extends hl{constructor(t){super(new gP,new yP(t),void 0,void 0);w(this,"_darkTintRGB",0)}get darkTint(){return"darkTint"in this.shader?this.shader.darkTint:null}set darkTint(t){this.shader.darkTint=t}get darkTintValue(){return this.shader.darkTintValue}_renderToBatch(t){const i=this.geometry,n=this.shader;n.uvMatrix&&(n.uvMatrix.update(),this.calculateUvs()),this.calculateVertices(),this.indices=i.indexBuffer.data,this._tintRGB=n._tintRGB,this._darkTintRGB=n._darkTintRGB,this._texture=n.texture;const r=this.material.pluginName;t.batch.setObjectRenderer(t.plugins[r]),t.plugins[r].render(this)}}const li=class li extends bP{constructor(){super();w(this,"name","")}updateFromSpineData(t,i,n,r,o,a,c,l){var v,y;this.texture=t.texture;const h=o/(l?12:8)*2,u=this.geometry.getBuffer("aTextureCoord");((v=u.data)==null?void 0:v.length)!==h&&(u.data=new Float32Array(h));const d=this.geometry.getBuffer("aVertexPosition");((y=d.data)==null?void 0:y.length)!==h&&(d.data=new Float32Array(h));let f=0,p=u.data,m=d.data;for(let x=0;x<o;x+=l?12:8){let T=x;m[f]=r[T++],m[f+1]=r[T++],T+=4,p[f]=r[T++],p[f+1]=r[T++],f+=2}l?(li.auxColor[0]=r[8],li.auxColor[1]=r[9],li.auxColor[2]=r[10],li.auxColor[3]=r[11],this.darkTint=li.auxColor,li.auxColor[0]=r[2],li.auxColor[1]=r[3],li.auxColor[2]=r[4],li.auxColor[3]=r[5],this.tint=li.auxColor):(li.auxColor[0]=r[2],li.auxColor[1]=r[3],li.auxColor[2]=r[4],li.auxColor[3]=r[5],this.tint=li.auxColor),this.blendMode=lo.toPixiBlending(i),this.alpha=li.auxColor[3];const g=this.geometry.indexBuffer;if(g.data.length!==a.length)g.data=new Uint32Array(a);else{const x=g.data;for(let T=0;T<c;T++)x[T]=a[T]}this.name=n,u.update(),d.update(),g.update()}};w(li,"auxColor",[0,0,0,0]);let Ha=li;const xt=class xt extends _i{constructor(t,i){if(t instanceof uh)t={...i,skeletonData:t};else if(i)throw new Error("You cannot use options and oldOptions together.");super();w(this,"skeleton");w(this,"state");w(this,"darkTint",!1);w(this,"hasNeverUpdated",!0);w(this,"_debug");w(this,"slotMeshFactory",()=>new lm);w(this,"beforeUpdateWorldTransforms",()=>{});w(this,"afterUpdateWorldTransforms",()=>{});w(this,"_autoUpdate",!1);w(this,"_ticker",Vi.shared);w(this,"meshesCache",new Map);w(this,"lightColor",new nt);w(this,"darkColor",new nt);w(this,"_boundsProvider");w(this,"_boundsPoint",new gt);w(this,"_boundsSpineID",-1);w(this,"_boundsSpineDirty",!0);w(this,"slotsObject",new Map);w(this,"verticesCache",Ie.newFloatArray(1024));w(this,"clippingSlotToPixiMasks",{});w(this,"currentClippingSlot");const n=t instanceof uh?t:t.skeletonData;this.skeleton=new dp(n);const r=new CR(n);this.state=new wR(r),(t==null?void 0:t.darkTint)!==void 0||(i==null?void 0:i.slotMeshFactory)===void 0?(this.darkTint=(t==null?void 0:t.darkTint)===void 0?this.skeleton.slots.some(o=>!!o.data.darkColor):t==null?void 0:t.darkTint,this.darkTint&&(this.slotMeshFactory=()=>new Ha)):this.initializeMeshFactory(i==null?void 0:i.slotMeshFactory),t!=null&&t.ticker&&(this._ticker=t.ticker),this.autoUpdate=(t==null?void 0:t.autoUpdate)??!0,this.boundsProvider=t.boundsProvide Line truncated
precision highp float;
attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
@@ -1221,7 +1221,7 @@ void main(void){
vDarkColor = aDarkColor * tint;
}
`,CP=`
`,AP=`
varying vec2 vTextureCoord;
varying vec4 vColor;
varying vec4 vDarkColor;
@@ -1236,4 +1236,4 @@ void main(void){
gl_FragColor.a = color.a * vColor.a;
gl_FragColor.rgb = ((color.a - 1.0) * vDarkColor.a + 1.0 - color.rgb) * vDarkColor.rgb + color.rgb * vColor.rgb;
}
`;class sw extends Kn{constructor(e){super(e),this.shaderGenerator=new Wy(_P,CP),this.geometryClass=MP,this.vertexSize=7}packInterleavedGeometry(e,t,i,n,r){const{uint32View:o,float32View:a}=t,c=n/this.vertexSize,l=e.uvs,h=e.indices,u=e.vertexData,d=e._texture.baseTexture._batchLocation,f=Math.min(e.worldAlpha,1),p=Tt.shared.setValue(e._tintRGB).toPremultiplied(f,!0),m=Tt.shared.setValue(e._darkTintRGB).premultiply(f,!0).toPremultiplied(1,!1);for(let g=0;g<u.length;g+=2)a[n++]=u[g],a[n++]=u[g+1],a[n++]=l[g],a[n++]=l[g+1],o[n++]=p,o[n++]=m,a[n++]=d;for(let g=0;g<h.length;g++)i[r++]=c+h[g]}}w(sw,"extension",{name:"darkTintBatch",type:Re.RendererPlugin});$e.add(sw);function AP(s){return s.replace(/\\/g,"/").split("/").pop()||s}function fp(s,e,t){for(const i of s.pages){const n=e.get(AP(i.name).toLowerCase());if(!n)throw new Error(`Atlas 引用的纹理未选择:${i.name}`);n.baseTexture.alphaMode=i.pma?vi.PMA:vi.UNPACK,i.setTexture(t.from(n.baseTexture))}}function nw(s,e){const t=new G1(s);return fp(t,e,ro),new rm(t)}function EP(s,e,t){return{skeletonData:new fh(nw(e,t)).readSkeletonData(s),SpineClass:mh}}function IP(s,e,t){return{skeletonData:new am(nw(e,t)).readSkeletonData(s),SpineClass:mh}}const RP="modulepreload",PP=function(s){return"/"+s},Rv={},Pv=function(e,t,i){let n=Promise.resolve();if(t&&t.length>0){let o=function(l){return Promise.all(l.map(h=>Promise.resolve(h).then(u=>({status:"fulfilled",value:u}),u=>({status:"rejected",reason:u}))))};document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),c=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));n=o(t.map(l=>{if(l=PP(l),l in Rv)return;Rv[l]=!0;const h=l.endsWith(".css"),u=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${u}`))return;const d=document.createElement("link");if(d.rel=h?"stylesheet":RP,h||(d.as="script"),d.crossOrigin="",d.href=l,c&&d.setAttribute("nonce",c),document.head.appendChild(d),h)return new Promise((f,p)=>{d.addEventListener("load",f),d.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${l}`)))})}))}function r(o){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o}return n.then(o=>{for(const a of o||[])a.status==="rejected"&&r(a.reason);return e().catch(r)})};async function rw(){const[s,e]=await Promise.all([Pv(()=>import("./index-D40Mzcwz.js"),[]),Pv(()=>import("./index-Dm5YZAxK.js"),__vite__mapDeps([0,1]))]);return{core:s,pixi:e}}async function kP(s,e,t){const{core:i,pixi:n}=await rw(),r=new i.TextureAtlas(e);return fp(r,t,n.SpineTexture),{skeletonData:new i.SkeletonJson(new i.AtlasAttachmentLoader(r)).readSkeletonData(s),SpineClass:n.Spine}}async function FP(s,e,t){const{core:i,pixi:n}=await rw(),r=new i.TextureAtlas(e);return fp(r,t,n.SpineTexture),{skeletonData:new i.SkeletonBinary(new i.AtlasAttachmentLoader(r)).readSkeletonData(s),SpineClass:n.Spine}}function sr(s,e,t){const i=Number(s[e]);return Number.isFinite(i)?i:t}function Ki(s,e,t,i){s[e]==null&&(s[e]=sr(s,t,i))}function mp(s,e,t){if(typeof s.curve!="number")return;const i=sr(s,"time",0),r=sr(e,"time",0)-i,o=s.curve,a=sr(s,"c2",0),c=sr(s,"c3",1),l=sr(s,"c4",1);s.curve=t.flatMap(([h,u])=>[i+r*o,h+(u-h)*a,i+r*c,h+(u-h)*l]),delete s.c2,delete s.c3,delete s.c4}function hr(s,e){if(Array.isArray(s))for(let t=0;t<s.length-1;t++){const i=s[t],n=s[t+1];mp(i,n,e.map(({key:r,fallback:o})=>[sr(i,r,o),sr(n,r,o)]))}}function OP(s){if(Array.isArray(s))for(let e=0;e<s.length-1;e++)mp(s[e],s[e+1],[[0,1]])}function To(s,e){const t=typeof s=="string"?s.replace(/^#/,""):"",i=t.length===6?`${t}ff`:t.padEnd(8,"f").slice(0,8),n=[0,2,4,6].map(r=>Number.parseInt(i.slice(r,r+2),16)/255);return e?n:n.slice(0,3)}function kv(s,e){if(Array.isArray(s))for(let t=0;t<s.length-1;t++){const i=s[t],n=s[t+1],r=e?[...To(i.light,!0),...To(i.dark,!1)]:To(i.color,!0),o=e?[...To(n.light,!0),...To(n.dark,!1)]:To(n.color,!0);mp(i,n,r.map((a,c)=>[a,o[c]]))}}function BP(s){for(const e of s.bones||[])e.inherit==null&&e.transform!=null&&(e.inherit=e.transform);for(const e of s.transform||[])Ki(e,"mixRotate","rotateMix",1),Ki(e,"mixX","translateMix",1),e.mixY==null&&(e.mixY=e.mixX),Ki(e,"mixScaleX","scaleMix",1),e.mixScaleY==null&&(e.mixScaleY=e.mixScaleX),Ki(e,"mixShearY","shearMix",1);for(const e of s.path||[])Ki(e,"mixRotate","rotateMix",1),Ki(e,"mixX","translateMix",1),e.mixY==null&&(e.mixY=e.mixX)}function LP(s){for(const e of s.skins||[])for(const t of Object.values(e.attachments||{}))for(const i of Object.values(t||{}))i.parent!=null&&i.timelines==null&&i.deform!=null&&(i.timelines=i.deform)}function DP(s){for(const e of Object.values(s.slots||{}))e.color&&!e.rgba&&(e.rgba=e.color,delete e.color),e.twoColor&&!e.rgba2&&(e.rgba2=e.twoColor,delete e.twoColor),kv(e.rgba,!1),kv(e.rgba2,!0)}function NP(s){for(const e of Object.values(s.bones||{})){for(const t of e.rotate||[])Ki(t,"value","angle",0);hr(e.rotate,[{key:"value",fallback:0}]),hr(e.tra Line truncated
`;class rw extends er{constructor(e){super(e),this.shaderGenerator=new qy(CP,AP),this.geometryClass=_P,this.vertexSize=7}packInterleavedGeometry(e,t,i,n,r){const{uint32View:o,float32View:a}=t,c=n/this.vertexSize,l=e.uvs,h=e.indices,u=e.vertexData,d=e._texture.baseTexture._batchLocation,f=Math.min(e.worldAlpha,1),p=Mt.shared.setValue(e._tintRGB).toPremultiplied(f,!0),m=Mt.shared.setValue(e._darkTintRGB).premultiply(f,!0).toPremultiplied(1,!1);for(let g=0;g<u.length;g+=2)a[n++]=u[g],a[n++]=u[g+1],a[n++]=l[g],a[n++]=l[g+1],o[n++]=p,o[n++]=m,a[n++]=d;for(let g=0;g<h.length;g++)i[r++]=c+h[g]}}w(rw,"extension",{name:"darkTintBatch",type:Re.RendererPlugin});Ue.add(rw);function EP(s){return s.replace(/\\/g,"/").split("/").pop()||s}function fp(s,e,t){for(const i of s.pages){const n=e.get(EP(i.name).toLowerCase());if(!n)throw new Error(`Atlas 引用的纹理未选择:${i.name}`);n.baseTexture.alphaMode=i.pma?xi.PMA:xi.UNPACK,i.setTexture(t.from(n.baseTexture))}}function ow(s,e){const t=new j1(s);return fp(t,e,lo),new rm(t)}function IP(s,e,t){return{skeletonData:new fh(ow(e,t)).readSkeletonData(s),SpineClass:mh}}function RP(s,e,t){return{skeletonData:new am(ow(e,t)).readSkeletonData(s),SpineClass:mh}}const PP="modulepreload",kP=function(s){return"/"+s},Pv={},kv=function(e,t,i){let n=Promise.resolve();if(t&&t.length>0){let o=function(l){return Promise.all(l.map(h=>Promise.resolve(h).then(u=>({status:"fulfilled",value:u}),u=>({status:"rejected",reason:u}))))};document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),c=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));n=o(t.map(l=>{if(l=kP(l),l in Pv)return;Pv[l]=!0;const h=l.endsWith(".css"),u=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${u}`))return;const d=document.createElement("link");if(d.rel=h?"stylesheet":PP,h||(d.as="script"),d.crossOrigin="",d.href=l,c&&d.setAttribute("nonce",c),document.head.appendChild(d),h)return new Promise((f,p)=>{d.addEventListener("load",f),d.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${l}`)))})}))}function r(o){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o}return n.then(o=>{for(const a of o||[])a.status==="rejected"&&r(a.reason);return e().catch(r)})};async function aw(){const[s,e]=await Promise.all([kv(()=>import("./index-3evwjaUy.js"),[]),kv(()=>import("./index-DbmHfkuV.js"),__vite__mapDeps([0,1]))]);return{core:s,pixi:e}}async function FP(s,e,t){const{core:i,pixi:n}=await aw(),r=new i.TextureAtlas(e);return fp(r,t,n.SpineTexture),{skeletonData:new i.SkeletonJson(new i.AtlasAttachmentLoader(r)).readSkeletonData(s),SpineClass:n.Spine}}async function OP(s,e,t){const{core:i,pixi:n}=await aw(),r=new i.TextureAtlas(e);return fp(r,t,n.SpineTexture),{skeletonData:new i.SkeletonBinary(new i.AtlasAttachmentLoader(r)).readSkeletonData(s),SpineClass:n.Spine}}function ar(s,e,t){const i=Number(s[e]);return Number.isFinite(i)?i:t}function qi(s,e,t,i){s[e]==null&&(s[e]=ar(s,t,i))}function mp(s,e,t){if(typeof s.curve!="number")return;const i=ar(s,"time",0),r=ar(e,"time",0)-i,o=s.curve,a=ar(s,"c2",0),c=ar(s,"c3",1),l=ar(s,"c4",1);s.curve=t.flatMap(([h,u])=>[i+r*o,h+(u-h)*a,i+r*c,h+(u-h)*l]),delete s.c2,delete s.c3,delete s.c4}function mr(s,e){if(Array.isArray(s))for(let t=0;t<s.length-1;t++){const i=s[t],n=s[t+1];mp(i,n,e.map(({key:r,fallback:o})=>[ar(i,r,o),ar(n,r,o)]))}}function BP(s){if(Array.isArray(s))for(let e=0;e<s.length-1;e++)mp(s[e],s[e+1],[[0,1]])}function _o(s,e){const t=typeof s=="string"?s.replace(/^#/,""):"",i=t.length===6?`${t}ff`:t.padEnd(8,"f").slice(0,8),n=[0,2,4,6].map(r=>Number.parseInt(i.slice(r,r+2),16)/255);return e?n:n.slice(0,3)}function Fv(s,e){if(Array.isArray(s))for(let t=0;t<s.length-1;t++){const i=s[t],n=s[t+1],r=e?[..._o(i.light,!0),..._o(i.dark,!1)]:_o(i.color,!0),o=e?[..._o(n.light,!0),..._o(n.dark,!1)]:_o(n.color,!0);mp(i,n,r.map((a,c)=>[a,o[c]]))}}function LP(s){for(const e of s.bones||[])e.inherit==null&&e.transform!=null&&(e.inherit=e.transform);for(const e of s.transform||[])qi(e,"mixRotate","rotateMix",1),qi(e,"mixX","translateMix",1),e.mixY==null&&(e.mixY=e.mixX),qi(e,"mixScaleX","scaleMix",1),e.mixScaleY==null&&(e.mixScaleY=e.mixScaleX),qi(e,"mixShearY","shearMix",1);for(const e of s.path||[])qi(e,"mixRotate","rotateMix",1),qi(e,"mixX","translateMix",1),e.mixY==null&&(e.mixY=e.mixX)}function DP(s){for(const e of s.skins||[])for(const t of Object.values(e.attachments||{}))for(const i of Object.values(t||{}))i.parent!=null&&i.timelines==null&&i.deform!=null&&(i.timelines=i.deform)}function NP(s){for(const e of Object.values(s.slots||{}))e.color&&!e.rgba&&(e.rgba=e.color,delete e.color),e.twoColor&&!e.rgba2&&(e.rgba2=e.twoColor,delete e.twoColor),Fv(e.rgba,!1),Fv(e.rgba2,!0)}function UP(s){for(const e of Object.values(s.bones||{})){for(const t of e.rotate||[])qi(t,"value","angle",0);mr(e.rotate,[{key:"value",fallback:0}]),mr(e.tra Line truncated
@@ -1 +1 @@
.help-overlay[data-v-78204b9d]{position:absolute;top:0;right:0;bottom:0;left:0;z-index:40;display:flex;align-items:center;justify-content:center;padding:72px 24px 28px;box-sizing:border-box;background:#05080fb8;-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}.help-dialog[data-v-78204b9d]{width:min(820px,100%);max-height:100%;display:flex;flex-direction:column;overflow:hidden;border:1px solid #3a4864;border-radius:14px;background:#141a27;color:#b8c3d8;box-shadow:0 22px 70px #0000009e}.help-head[data-v-78204b9d]{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;padding:18px 20px 15px;border-bottom:1px solid #2b354a;background:linear-gradient(135deg,#202942,#181e2d)}.help-head h2[data-v-78204b9d]{margin:0;color:#eef2ff;font-size:19px}.help-head p[data-v-78204b9d]{margin:5px 0 0;color:#7786a3;font-size:11px}.help-close[data-v-78204b9d]{width:28px;height:28px;flex:0 0 28px;border:1px solid #43516b;border-radius:6px;background:#273249;color:#ccd7ed;cursor:pointer}.help-close[data-v-78204b9d]:hover{border-color:#7774ff;background:#3b4670;color:#fff}.help-body[data-v-78204b9d]{min-height:0;overflow:auto;padding:18px 20px 21px}.help-section[data-v-78204b9d]{padding:14px 15px;border:1px solid #2c3850;border-radius:10px;background:#181f2e}.help-section h3[data-v-78204b9d]{margin:0 0 11px;color:#9fb2ff;font-size:13px}.help-start ol[data-v-78204b9d]{margin:0;padding-left:21px;color:#aab6cc;font-size:12px;line-height:1.75}.help-start li[data-v-78204b9d]::marker{color:#7774ff;font-weight:700}.help-section b[data-v-78204b9d]{color:#dce4f7}.help-grid[data-v-78204b9d]{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(250px,.85fr);gap:12px;margin-top:12px}.help-list[data-v-78204b9d]{display:grid;gap:0;margin:0}.help-list>div[data-v-78204b9d]{display:grid;grid-template-columns:78px 1fr;gap:9px;padding:7px 0;border-bottom:1px solid #263146}.help-list>div[data-v-78204b9d]:last-child{border-bottom:0}.help-list dt[data-v-78204b9d]{color:#d3dcf0;font-size:11px;font-weight:700}.help-list dd[data-v-78204b9d]{margin:0;color:#8795ae;font-size:11px;line-height:1.5}.shortcut-list[data-v-78204b9d]{display:grid;gap:7px}.shortcut-list>div[data-v-78204b9d]{display:flex;align-items:center;min-height:25px;gap:5px}.shortcut-list kbd[data-v-78204b9d]{min-width:24px;box-sizing:border-box;padding:3px 6px;border:1px solid #465470;border-bottom-width:2px;border-radius:5px;background:#101623;color:#e0e7f6;font:10px/1.2 ui-monospace,SFMono-Regular,Menlo,monospace;text-align:center}.shortcut-list span[data-v-78204b9d]{color:#65728b;font-size:10px}.shortcut-list em[data-v-78204b9d]{margin-left:auto;color:#9ca9c1;font-size:11px;font-style:normal}.help-note[data-v-78204b9d]{margin:11px 0 0;padding-top:9px;border-top:1px solid #2a3549;color:#697791;font-size:10px;line-height:1.55}.help-export[data-v-78204b9d]{margin-top:12px}.help-export p[data-v-78204b9d]{margin:0;color:#8997b0;font-size:11px;line-height:1.65}.help-doc-title[data-v-78204b9d]{margin:16px 2px 2px;color:#9fb2ff;font-size:13px;font-weight:700;letter-spacing:.5px}.help-module[data-v-78204b9d]{margin-top:12px}.help-module-head[data-v-78204b9d]{display:flex;align-items:center;gap:8px;width:100%;padding:0;border:0;background:transparent;color:#9fb2ff;font:inherit;font-size:13px;font-weight:700;text-align:left;cursor:pointer}.help-module-head[data-v-78204b9d]:hover{color:#fff}.help-module-head .mtitle[data-v-78204b9d]{flex:1;min-width:0}.help-module-head .caret[data-v-78204b9d]{flex:0 0 auto;color:#7b86a2;font-size:12px}.help-module.open .help-module-head[data-v-78204b9d]{color:#fff}.help-module.open .help-module-head .caret[data-v-78204b9d]{color:#9fb2ff}.help-module .mnum[data-v-78204b9d]{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:6px;background:linear-gradient(135deg,#4a53b8,#6a5fd0);color:#fff;font-size:12px;font-weight:700}.help-module.help-connector[data-v-78204b9d]{border-color:#4a4f8a;background:linear-gradient(135deg,#1d2442,#181d2f)}.help-module.help-connector .help-module-head[data-v-78204b9d]{color:#b8c2ff}.help-module .connector-intro[data-v-78204b9d]{margin:0 0 10px;color:#9aa8c4;font-size:11px;line-height:1.6}.help-module .connector-intro b[data-v-78204b9d]{color:#dce4f7}.help-module .dl-link[data-v-78204b9d]{display:inline-flex;flex-direction:column;align-items:flex-start;gap:2px;margin:0 10px 6px 0;padding:6px 12px;border:1px solid #5652b5;border-radius:6px;background:#4540a0;color:#fff;font-size:12px;font-weight:700;text-decoration:none}.help-module .dl-link[data-v-78204b9d]:hover{border-color:#8982ff;background:#554dc2}.help-module .dl-link small[data-v-78204b9d]{color:#cfe0ff;font-weight:500;font-size:9px}.help-module-body[data-v-78204b9d]{padding-top:10px}@media(max-width:760px){.help-overlay[data-v-78204b9d]{padding:66px 12px 14px}.help-grid[data-v-78204b9d]{grid-template-columns:1fr}}.topbar[data-v-4749834a]{position:absolute;top:10px;left:10px;right:10px;dispLine truncated
.help-overlay[data-v-78204b9d]{position:absolute;top:0;right:0;bottom:0;left:0;z-index:40;display:flex;align-items:center;justify-content:center;padding:72px 24px 28px;box-sizing:border-box;background:#05080fb8;-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}.help-dialog[data-v-78204b9d]{width:min(820px,100%);max-height:100%;display:flex;flex-direction:column;overflow:hidden;border:1px solid #3a4864;border-radius:14px;background:#141a27;color:#b8c3d8;box-shadow:0 22px 70px #0000009e}.help-head[data-v-78204b9d]{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;padding:18px 20px 15px;border-bottom:1px solid #2b354a;background:linear-gradient(135deg,#202942,#181e2d)}.help-head h2[data-v-78204b9d]{margin:0;color:#eef2ff;font-size:19px}.help-head p[data-v-78204b9d]{margin:5px 0 0;color:#7786a3;font-size:11px}.help-close[data-v-78204b9d]{width:28px;height:28px;flex:0 0 28px;border:1px solid #43516b;border-radius:6px;background:#273249;color:#ccd7ed;cursor:pointer}.help-close[data-v-78204b9d]:hover{border-color:#7774ff;background:#3b4670;color:#fff}.help-body[data-v-78204b9d]{min-height:0;overflow:auto;padding:18px 20px 21px}.help-section[data-v-78204b9d]{padding:14px 15px;border:1px solid #2c3850;border-radius:10px;background:#181f2e}.help-section h3[data-v-78204b9d]{margin:0 0 11px;color:#9fb2ff;font-size:13px}.help-start ol[data-v-78204b9d]{margin:0;padding-left:21px;color:#aab6cc;font-size:12px;line-height:1.75}.help-start li[data-v-78204b9d]::marker{color:#7774ff;font-weight:700}.help-section b[data-v-78204b9d]{color:#dce4f7}.help-grid[data-v-78204b9d]{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(250px,.85fr);gap:12px;margin-top:12px}.help-list[data-v-78204b9d]{display:grid;gap:0;margin:0}.help-list>div[data-v-78204b9d]{display:grid;grid-template-columns:78px 1fr;gap:9px;padding:7px 0;border-bottom:1px solid #263146}.help-list>div[data-v-78204b9d]:last-child{border-bottom:0}.help-list dt[data-v-78204b9d]{color:#d3dcf0;font-size:11px;font-weight:700}.help-list dd[data-v-78204b9d]{margin:0;color:#8795ae;font-size:11px;line-height:1.5}.shortcut-list[data-v-78204b9d]{display:grid;gap:7px}.shortcut-list>div[data-v-78204b9d]{display:flex;align-items:center;min-height:25px;gap:5px}.shortcut-list kbd[data-v-78204b9d]{min-width:24px;box-sizing:border-box;padding:3px 6px;border:1px solid #465470;border-bottom-width:2px;border-radius:5px;background:#101623;color:#e0e7f6;font:10px/1.2 ui-monospace,SFMono-Regular,Menlo,monospace;text-align:center}.shortcut-list span[data-v-78204b9d]{color:#65728b;font-size:10px}.shortcut-list em[data-v-78204b9d]{margin-left:auto;color:#9ca9c1;font-size:11px;font-style:normal}.help-note[data-v-78204b9d]{margin:11px 0 0;padding-top:9px;border-top:1px solid #2a3549;color:#697791;font-size:10px;line-height:1.55}.help-export[data-v-78204b9d]{margin-top:12px}.help-export p[data-v-78204b9d]{margin:0;color:#8997b0;font-size:11px;line-height:1.65}.help-doc-title[data-v-78204b9d]{margin:16px 2px 2px;color:#9fb2ff;font-size:13px;font-weight:700;letter-spacing:.5px}.help-module[data-v-78204b9d]{margin-top:12px}.help-module-head[data-v-78204b9d]{display:flex;align-items:center;gap:8px;width:100%;padding:0;border:0;background:transparent;color:#9fb2ff;font:inherit;font-size:13px;font-weight:700;text-align:left;cursor:pointer}.help-module-head[data-v-78204b9d]:hover{color:#fff}.help-module-head .mtitle[data-v-78204b9d]{flex:1;min-width:0}.help-module-head .caret[data-v-78204b9d]{flex:0 0 auto;color:#7b86a2;font-size:12px}.help-module.open .help-module-head[data-v-78204b9d]{color:#fff}.help-module.open .help-module-head .caret[data-v-78204b9d]{color:#9fb2ff}.help-module .mnum[data-v-78204b9d]{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:6px;background:linear-gradient(135deg,#4a53b8,#6a5fd0);color:#fff;font-size:12px;font-weight:700}.help-module.help-connector[data-v-78204b9d]{border-color:#4a4f8a;background:linear-gradient(135deg,#1d2442,#181d2f)}.help-module.help-connector .help-module-head[data-v-78204b9d]{color:#b8c2ff}.help-module .connector-intro[data-v-78204b9d]{margin:0 0 10px;color:#9aa8c4;font-size:11px;line-height:1.6}.help-module .connector-intro b[data-v-78204b9d]{color:#dce4f7}.help-module .dl-link[data-v-78204b9d]{display:inline-flex;flex-direction:column;align-items:flex-start;gap:2px;margin:0 10px 6px 0;padding:6px 12px;border:1px solid #5652b5;border-radius:6px;background:#4540a0;color:#fff;font-size:12px;font-weight:700;text-decoration:none}.help-module .dl-link[data-v-78204b9d]:hover{border-color:#8982ff;background:#554dc2}.help-module .dl-link small[data-v-78204b9d]{color:#cfe0ff;font-weight:500;font-size:9px}.help-module-body[data-v-78204b9d]{padding-top:10px}@media(max-width:760px){.help-overlay[data-v-78204b9d]{padding:66px 12px 14px}.help-grid[data-v-78204b9d]{grid-template-columns:1fr}}.topbar[data-v-4749834a]{position:absolute;top:10px;left:10px;right:10px;dispLine truncated
@@ -1,4 +1,4 @@
var Ae=Object.defineProperty;var Be=(m,o,e)=>o in m?Ae(m,o,{enumerable:!0,configurable:!0,writable:!0,value:e}):m[o]=e;var a=(m,o,e)=>Be(m,typeof o!="symbol"?o+"":o,e);import{T as Fe,a as he,b as F,S as ue,M as pe,c as oe,W as ne,B as H,d as z,L as Te,E as O,e as ce,p as q,f as Ee,g as fe,A as Q,h as me,i as De,j as V,s as re,G as we,k as $,l as Y,m as Le,P as Ie,n as Re,o as Ne,C as X,q as be,r as _e,t as Ue,u as Ye,v as Xe,w as ee,x as j,y as ke,z as Ve,D as J,F as ge,V as Ge,H as ae,I as We,J as $e,U as xe,K as E,R as ve,N as ye,O as Pe,Q as Oe,X as He,Y as ze,Z as qe,_ as Ke}from"./index-DcKlG1-Y.js";import{$ as bt,a0 as kt,a1 as vt,a2 as yt,a3 as Pt,a4 as St,a5 as Mt,a6 as At,a7 as Bt,a8 as Ft,a9 as Et,aa as Dt,ab as Lt,ac as It,ad as Rt,ae as Nt,af as _t,ag as Ut,ah as Yt,ai as Xt,aj as Vt,ak as Gt,al as Wt,am as $t,an as Ot,ao as Ht,ap as zt,aq as qt,ar as Kt,as as Zt,at as Jt,au as Qt,av as jt,aw as es,ax as ts,ay as ss,az as os,aA as ns,aB as as,aC as rs,aD as is,aE as ls,aF as hs,aG as cs,aH as ds,aI as us,aJ as ps,aK as fs,aL as ms,aM as gs,aN as xs,aO as Cs,aP as Ts,aQ as ws,aR as bs,aS as ks,aT as vs,aU as ys,aV as Ps,aW as Ss,aX as Ms,aY as As,aZ as Bs,a_ as Fs,a$ as Es,b0 as Ds,b1 as Ls,b2 as Is,b3 as Rs,b4 as Ns,b5 as _s,b6 as Us,b7 as Ys,b8 as Xs,b9 as Vs,ba as Gs,bb as Ws,bc as $s,bd as Os,be as Hs,bf as zs,bg as qs,bh as Ks,bi as Zs,bj as Js,bk as Qs,bl as js,bm as eo,bn as to,bo as so,bp as oo,bq as no,br as ao,bs as ro,bt as io,bu as lo,bv as ho,bw as co,bx as uo,by as po,bz as fo,bA as mo,bB as go,bC as xo,bD as Co,bE as To,bF as wo,bG as bo,bH as ko,bI as vo,bJ as yo,bK as Po,bL as So,bM as Mo,bN as Ao,bO as Bo,bP as Fo,bQ as Eo,bR as Do,bS as Lo,bT as Io,bU as Ro,bV as No,bW as _o,bX as Uo,bY as Yo,bZ as Xo,b_ as Vo,b$ as Go,c0 as Wo,c1 as $o,c2 as Oo,c3 as Ho}from"./index-DcKlG1-Y.js";import{SkeletonClipping as de,SkeletonPhysicsMovement as Ze,AnimationStateData as Je,AtlasAttachmentLoader as Qe,SkeletonBounds as je}from"./index-D40Mzcwz.js";import{AssetCache as qo,AssetManagerBase as Ko,Downloader as Zo,SkeletonRendererCore as Jo,Triangulator as Qo}from"./index-D40Mzcwz.js";if(typeof window<"u"&&window.PIXI){const m=window.require;window.require=o=>{if(m)return m(o);if(o.startsWith("@pixi/"))return window.PIXI}}const _=class _ extends Fe{constructor(e){super(e.resource.source);a(this,"texture");this.texture=he.from(e)}static from(e){return _.textureMap.has(e)?_.textureMap.get(e):new _(e)}setFilters(e,t){this.texture.baseTexture.scaleMode=_.toPixiTextureFilter(e),this.texture.baseTexture.mipmap=_.toPixiMipMap(e)}setWraps(e,t){this.texture.baseTexture.wrapMode=_.toPixiTextureWrap(e)}dispose(){this.texture.destroy()}static toPixiTextureFilter(e){switch(e){case F.Nearest:case F.MipMapNearestLinear:case F.MipMapNearestNearest:return ue.NEAREST;case F.Linear:case F.MipMapLinearLinear:case F.MipMapLinearNearest:return ue.LINEAR;default:throw new Error(`Unknown texture filter: ${String(e)}`)}}static toPixiMipMap(e){switch(e){case F.Nearest:case F.Linear:return pe.OFF;case F.MipMapNearestLinear:case F.MipMapNearestNearest:case F.MipMapLinearLinear:case F.MipMapLinearNearest:return pe.ON;default:throw new Error(`Unknown texture filter: ${String(e)}`)}}static toPixiTextureWrap(e){switch(e){case oe.ClampToEdge:return ne.CLAMP;case oe.MirroredRepeat:return ne.MIRRORED_REPEAT;case oe.Repeat:return ne.REPEAT;default:throw new Error(`Unknown texture wrap: ${String(e)}`)}}static toPixiBlending(e){switch(e){case H.Normal:return z.NORMAL;case H.Additive:return z.ADD;case H.Multiply:return z.MULTIPLY;case H.Screen:return z.SCREEN;default:throw new Error(`Unknown blendMode: ${String(e)}`)}}};a(_,"textureMap",new Map);let G=_;const K="spineTextureAtlasLoader",et={extension:O.Asset,resolver:{test:m=>V(m,".atlas"),parse:m=>{var e,t;const o=m.split(".");return{resolution:parseFloat(((t=(e=re.RETINA_PREFIX)==null?void 0:e.exec(m))==null?void 0:t[1])??"1"),format:o[o.length-2],src:m}}},loader:{name:K,extension:{type:O.LoadParser,priority:Te.Normal,name:K},test(m){return V(m,".atlas")},async load(m){const o=await re.ADAPTER.fetch(m);if(!o.ok)throw new Error(`[${K}] Failed to fetch ${m}: ${o.status} ${o.statusText}`);return await o.text()},testParse(m,o){const e=V(o.src,".atlas"),t=typeof m=="string",s=o.loadParser===K;return Promise.resolve((e||s)&&t)},unload(m){m.dispose()},async parse(m,o,e){var p;const t=o.data||{};let s=q.dirname(o.src);s&&s.lastIndexOf("/")!==s.length-1&&(s+="/");const n=new Ee(m);if(t.images instanceof fe||typeof t.images=="string"){const h=t.images;t.images={},t.images[n.pages[0].name]=h}const r=[];let l=!0;for(const h of e.parsers)if(h.name==="loadTextures"){l=(p=h.config)==null?void 0:p.preferCreateImageBitmap;break}Q.setPreferences({preferCreateImageBitmap:!1});for(const h of n.pages){const u=h.name,c=t!=null&&t.images?t.images[u]:void 0;if(c instanceof fe)h.setTexture(G.from(c));else{const i=c??q.normalize([...s.split(q.sep),u].join(q.sep)),g={src:De(i,o.src),data:{...t.imageMetadLine truncated
var Ae=Object.defineProperty;var Be=(m,o,e)=>o in m?Ae(m,o,{enumerable:!0,configurable:!0,writable:!0,value:e}):m[o]=e;var a=(m,o,e)=>Be(m,typeof o!="symbol"?o+"":o,e);import{T as Fe,a as he,b as F,S as ue,M as pe,c as oe,W as ne,B as H,d as z,L as Te,E as O,e as ce,p as q,f as Ee,g as fe,A as Q,h as me,i as De,j as V,s as re,G as we,k as $,l as Y,m as Le,P as Ie,n as Re,o as Ne,C as X,q as be,r as _e,t as Ue,u as Ye,v as Xe,w as ee,x as j,y as ke,z as Ve,D as J,F as ge,V as Ge,H as ae,I as We,J as $e,U as xe,K as E,R as ve,N as ye,O as Pe,Q as Oe,X as He,Y as ze,Z as qe,_ as Ke}from"./index-CBAQrWSZ.js";import{$ as bt,a0 as kt,a1 as vt,a2 as yt,a3 as Pt,a4 as St,a5 as Mt,a6 as At,a7 as Bt,a8 as Ft,a9 as Et,aa as Dt,ab as Lt,ac as It,ad as Rt,ae as Nt,af as _t,ag as Ut,ah as Yt,ai as Xt,aj as Vt,ak as Gt,al as Wt,am as $t,an as Ot,ao as Ht,ap as zt,aq as qt,ar as Kt,as as Zt,at as Jt,au as Qt,av as jt,aw as es,ax as ts,ay as ss,az as os,aA as ns,aB as as,aC as rs,aD as is,aE as ls,aF as hs,aG as cs,aH as ds,aI as us,aJ as ps,aK as fs,aL as ms,aM as gs,aN as xs,aO as Cs,aP as Ts,aQ as ws,aR as bs,aS as ks,aT as vs,aU as ys,aV as Ps,aW as Ss,aX as Ms,aY as As,aZ as Bs,a_ as Fs,a$ as Es,b0 as Ds,b1 as Ls,b2 as Is,b3 as Rs,b4 as Ns,b5 as _s,b6 as Us,b7 as Ys,b8 as Xs,b9 as Vs,ba as Gs,bb as Ws,bc as $s,bd as Os,be as Hs,bf as zs,bg as qs,bh as Ks,bi as Zs,bj as Js,bk as Qs,bl as js,bm as eo,bn as to,bo as so,bp as oo,bq as no,br as ao,bs as ro,bt as io,bu as lo,bv as ho,bw as co,bx as uo,by as po,bz as fo,bA as mo,bB as go,bC as xo,bD as Co,bE as To,bF as wo,bG as bo,bH as ko,bI as vo,bJ as yo,bK as Po,bL as So,bM as Mo,bN as Ao,bO as Bo,bP as Fo,bQ as Eo,bR as Do,bS as Lo,bT as Io,bU as Ro,bV as No,bW as _o,bX as Uo,bY as Yo,bZ as Xo,b_ as Vo,b$ as Go,c0 as Wo,c1 as $o,c2 as Oo,c3 as Ho}from"./index-CBAQrWSZ.js";import{SkeletonClipping as de,SkeletonPhysicsMovement as Ze,AnimationStateData as Je,AtlasAttachmentLoader as Qe,SkeletonBounds as je}from"./index-3evwjaUy.js";import{AssetCache as qo,AssetManagerBase as Ko,Downloader as Zo,SkeletonRendererCore as Jo,Triangulator as Qo}from"./index-3evwjaUy.js";if(typeof window<"u"&&window.PIXI){const m=window.require;window.require=o=>{if(m)return m(o);if(o.startsWith("@pixi/"))return window.PIXI}}const _=class _ extends Fe{constructor(e){super(e.resource.source);a(this,"texture");this.texture=he.from(e)}static from(e){return _.textureMap.has(e)?_.textureMap.get(e):new _(e)}setFilters(e,t){this.texture.baseTexture.scaleMode=_.toPixiTextureFilter(e),this.texture.baseTexture.mipmap=_.toPixiMipMap(e)}setWraps(e,t){this.texture.baseTexture.wrapMode=_.toPixiTextureWrap(e)}dispose(){this.texture.destroy()}static toPixiTextureFilter(e){switch(e){case F.Nearest:case F.MipMapNearestLinear:case F.MipMapNearestNearest:return ue.NEAREST;case F.Linear:case F.MipMapLinearLinear:case F.MipMapLinearNearest:return ue.LINEAR;default:throw new Error(`Unknown texture filter: ${String(e)}`)}}static toPixiMipMap(e){switch(e){case F.Nearest:case F.Linear:return pe.OFF;case F.MipMapNearestLinear:case F.MipMapNearestNearest:case F.MipMapLinearLinear:case F.MipMapLinearNearest:return pe.ON;default:throw new Error(`Unknown texture filter: ${String(e)}`)}}static toPixiTextureWrap(e){switch(e){case oe.ClampToEdge:return ne.CLAMP;case oe.MirroredRepeat:return ne.MIRRORED_REPEAT;case oe.Repeat:return ne.REPEAT;default:throw new Error(`Unknown texture wrap: ${String(e)}`)}}static toPixiBlending(e){switch(e){case H.Normal:return z.NORMAL;case H.Additive:return z.ADD;case H.Multiply:return z.MULTIPLY;case H.Screen:return z.SCREEN;default:throw new Error(`Unknown blendMode: ${String(e)}`)}}};a(_,"textureMap",new Map);let G=_;const K="spineTextureAtlasLoader",et={extension:O.Asset,resolver:{test:m=>V(m,".atlas"),parse:m=>{var e,t;const o=m.split(".");return{resolution:parseFloat(((t=(e=re.RETINA_PREFIX)==null?void 0:e.exec(m))==null?void 0:t[1])??"1"),format:o[o.length-2],src:m}}},loader:{name:K,extension:{type:O.LoadParser,priority:Te.Normal,name:K},test(m){return V(m,".atlas")},async load(m){const o=await re.ADAPTER.fetch(m);if(!o.ok)throw new Error(`[${K}] Failed to fetch ${m}: ${o.status} ${o.statusText}`);return await o.text()},testParse(m,o){const e=V(o.src,".atlas"),t=typeof m=="string",s=o.loadParser===K;return Promise.resolve((e||s)&&t)},unload(m){m.dispose()},async parse(m,o,e){var p;const t=o.data||{};let s=q.dirname(o.src);s&&s.lastIndexOf("/")!==s.length-1&&(s+="/");const n=new Ee(m);if(t.images instanceof fe||typeof t.images=="string"){const h=t.images;t.images={},t.images[n.pages[0].name]=h}const r=[];let l=!0;for(const h of e.parsers)if(h.name==="loadTextures"){l=(p=h.config)==null?void 0:p.preferCreateImageBitmap;break}Q.setPreferences({preferCreateImageBitmap:!1});for(const h of n.pages){const u=h.name,c=t!=null&&t.images?t.images[u]:void 0;if(c instanceof fe)h.setTexture(G.from(c));else{const i=c??q.normalize([...s.split(q.sep),u].join(q.sep)),g={src:De(i,o.src),data:{...t.imageMetadLine truncated
attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
+2 -2
View File
@@ -8,8 +8,8 @@
html, body { margin: 0; padding: 0; background: #111; color: #eee; font-family: system-ui, -apple-system, sans-serif; }
#app { display: flex; flex-direction: column; height: 100vh; }
</style>
<script type="module" crossorigin src="/assets/index-DcKlG1-Y.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-BRJ6rx0Q.css">
<script type="module" crossorigin src="/assets/index-CBAQrWSZ.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-D9S6kMFu.css">
</head>
<body>
<div id="app"></div>